diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE b/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE deleted file mode 100644 index 644800f2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/LICENSE +++ /dev/null @@ -1,22 +0,0 @@ -MIT License - -Copyright (c) 2019 Matthias Pfefferle -Copyright (c) 2023 Automattic - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php b/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php deleted file mode 100644 index a6dca243..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/activitypub.php +++ /dev/null @@ -1,206 +0,0 @@ -register_routes(); - ( new Rest\Actors_Inbox_Controller() )->register_routes(); - ( new Rest\Application_Controller() )->register_routes(); - ( new Rest\Collections_Controller() )->register_routes(); - ( new Rest\Comments_Controller() )->register_routes(); - ( new Rest\Followers_Controller() )->register_routes(); - ( new Rest\Following_Controller() )->register_routes(); - ( new Rest\Inbox_Controller() )->register_routes(); - ( new Rest\Interaction_Controller() )->register_routes(); - ( new Rest\Moderators_Controller() )->register_routes(); - ( new Rest\Outbox_Controller() )->register_routes(); - ( new Rest\Replies_Controller() )->register_routes(); - ( new Rest\URL_Validator_Controller() )->register_routes(); - ( new Rest\Webfinger_Controller() )->register_routes(); - - // Load NodeInfo endpoints only if blog is public. - if ( is_blog_public() ) { - ( new Rest\Nodeinfo_Controller() )->register_routes(); - } -} -\add_action( 'rest_api_init', __NAMESPACE__ . '\rest_init' ); - -/** - * Initialize plugin. - */ -function plugin_init() { - \add_action( 'init', array( __NAMESPACE__ . '\Activitypub', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Comment', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Dispatcher', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Handler', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Hashtag', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Link', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Mailer', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Mention', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Migration', 'init' ), 1 ); - \add_action( 'init', array( __NAMESPACE__ . '\Move', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Options', 'init' ) ); - \add_action( 'init', array( __NAMESPACE__ . '\Scheduler', 'init' ) ); - - if ( site_supports_blocks() ) { - \add_action( 'init', array( __NAMESPACE__ . '\Blocks', 'init' ) ); - } - - $debug_file = __DIR__ . '/includes/debug.php'; - if ( \WP_DEBUG && file_exists( $debug_file ) && is_readable( $debug_file ) ) { - require_once $debug_file; - Debug::init(); - } -} -\add_action( 'plugins_loaded', __NAMESPACE__ . '\plugin_init' ); - -/** - * Initialize plugin admin. - */ -function plugin_admin_init() { - // Menus are registered before `admin_init`, because of course they are. - \add_action( 'admin_menu', array( __NAMESPACE__ . '\WP_Admin\Menu', 'admin_menu' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Admin', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Health_Check', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Settings', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Settings_Fields', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Welcome_Fields', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Advanced_Settings_Fields', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\Blog_Settings_Fields', 'init' ) ); - \add_action( 'admin_init', array( __NAMESPACE__ . '\WP_Admin\User_Settings_Fields', 'init' ) ); - - if ( defined( 'WP_LOAD_IMPORTERS' ) && WP_LOAD_IMPORTERS ) { - require_once __DIR__ . '/includes/wp-admin/import/load.php'; - \add_action( 'admin_init', __NAMESPACE__ . '\WP_Admin\Import\load' ); - } -} -\add_action( 'plugins_loaded', __NAMESPACE__ . '\plugin_admin_init' ); - -\register_activation_hook( - __FILE__, - array( - __NAMESPACE__ . '\Activitypub', - 'activate', - ) -); - -/** - * Redirect to the welcome page after plugin activation. - * - * @param string $plugin The plugin basename. - */ -function activation_redirect( $plugin ) { - if ( ACTIVITYPUB_PLUGIN_BASENAME === $plugin ) { - \wp_safe_redirect( \admin_url( 'options-general.php?page=activitypub' ) ); - exit; - } -} -\add_action( 'activated_plugin', __NAMESPACE__ . '\activation_redirect' ); - -\register_deactivation_hook( - __FILE__, - array( - __NAMESPACE__ . '\Activitypub', - 'deactivate', - ) -); - -\register_uninstall_hook( - __FILE__, - array( - __NAMESPACE__ . '\Activitypub', - 'uninstall', - ) -); - - -/** - * `get_plugin_data` wrapper. - * - * @deprecated 4.2.0 Use `get_plugin_data` instead. - * - * @param array $default_headers Optional. The default plugin headers. Default empty array. - * @return array The plugin metadata array. - */ -function get_plugin_meta( $default_headers = array() ) { - _deprecated_function( __FUNCTION__, '4.2.0', 'get_plugin_data' ); - - if ( ! $default_headers ) { - $default_headers = array( - 'Name' => 'Plugin Name', - 'PluginURI' => 'Plugin URI', - 'Version' => 'Version', - 'Description' => 'Description', - 'Author' => 'Author', - 'AuthorURI' => 'Author URI', - 'TextDomain' => 'Text Domain', - 'DomainPath' => 'Domain Path', - 'Network' => 'Network', - 'RequiresWP' => 'Requires at least', - 'RequiresPHP' => 'Requires PHP', - 'UpdateURI' => 'Update URI', - ); - } - - return \get_file_data( __FILE__, $default_headers, 'plugin' ); -} - -/** - * Plugin Version Number used for caching. - * - * @deprecated 4.2.0 Use constant ACTIVITYPUB_PLUGIN_VERSION directly. - */ -function get_plugin_version() { - _deprecated_function( __FUNCTION__, '4.2.0', 'ACTIVITYPUB_PLUGIN_VERSION' ); - - return ACTIVITYPUB_PLUGIN_VERSION; -} - -// Check for CLI env, to add the CLI commands. -if ( defined( 'WP_CLI' ) && WP_CLI ) { - WP_CLI::add_command( - 'activitypub', - '\Activitypub\Cli', - array( - 'shortdesc' => 'ActivityPub related commands to manage plugin functionality and the federation of posts and comments.', - ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/css/activitypub-admin.css b/wp-content/upgrade-temp-backup/plugins/activitypub/assets/css/activitypub-admin.css deleted file mode 100644 index 2e181f2a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/css/activitypub-admin.css +++ /dev/null @@ -1,272 +0,0 @@ -.activitypub-settings { - max-width: 800px; - margin: 0 auto; - position: relative; -} - -.settings_page_activitypub .notice { - max-width: 800px; - margin: 0 auto 30px; -} - -.settings_page_activitypub .update-nag { - margin: 25px 20px 15px 22px; -} - -.settings_page_activitypub .wrap { - padding-left: 22px; -} - -.activitypub-settings-header { - text-align: center; - margin: 0 0 1rem; - background: #fff; - border-bottom: 1px solid #dcdcde; -} - -.activitypub-settings-header h1 { - display: inline-block; - font-weight: 600; - margin: 0 0.8rem 1rem; - font-size: 23px; - padding: 9px 0 4px; - line-height: 1.3; -} - -.activitypub-settings-title-section { - display: flex; - align-items: center; - justify-content: center; - clear: both; - padding-top: 8px; -} - -.settings_page_activitypub #wpcontent { - padding-left: 0; -} - -.activitypub-settings-tabs-wrapper { - display: inline-flex; - vertical-align: top; - flex-wrap: nowrap; - gap: 0; -} - -.activitypub-settings-tab.active { - box-shadow: inset 0 -3px #3582c4; - font-weight: 600; -} - -.activitypub-settings-tab { - display: block; - text-decoration: none; - color: inherit; - padding: .5rem 1rem 1rem; - margin: 0 1rem; - transition: box-shadow .5s ease-in-out; -} - -.activitypub-settings .row { - margin-bottom: 16px; -} - -.activitypub-settings .row > div { - max-width: calc(100% - 24px); - display: inline-flex; - flex-direction: column; -} - -.activitypub-settings .row .description { - margin-top: 0; -} - -.wp-header-end { - visibility: hidden; - margin: -2px 0 0; -} - -summary { - cursor: pointer; - text-decoration: underline; - color: #2271b1; -} - -.activitypub-settings-accordion { - border: 1px solid #c3c4c7; -} - -.activitypub-settings-accordion-heading { - margin: 0; - border-top: 1px solid #c3c4c7; - font-size: inherit; - line-height: inherit; - font-weight: 600; - color: inherit; -} - -.activitypub-settings-accordion-heading:first-child { - border-top: none; -} - -.activitypub-settings-accordion-panel { - margin: 0; - padding: 1em 1.5em; - background: #fff; -} - -.activitypub-settings-accordion-trigger { - background: #fff; - border: 0; - color: #2c3338; - cursor: pointer; - display: flex; - font-weight: 400; - margin: 0; - padding: 1em 3.5em 1em 1.5em; - min-height: 46px; - position: relative; - text-align: left; - width: 100%; - align-items: center; - justify-content: space-between; - -webkit-user-select: auto; - user-select: auto; -} - -.activitypub-settings-accordion-trigger { - color: #2c3338; - cursor: pointer; - font-weight: 400; - text-align: left; -} - -.activitypub-settings-accordion-trigger .title { - pointer-events: none; - font-weight: 600; - flex-grow: 1; -} - -.activitypub-settings-accordion-trigger .icon, -.activitypub-settings-accordion-viewed .icon { - border: solid #50575e medium; - border-width: 0 2px 2px 0; - height: .5rem; - pointer-events: none; - position: absolute; - right: 1.5em; - top: 50%; - transform: translateY(-70%) rotate(45deg); - width: .5rem; -} - -.activitypub-settings-accordion-trigger[aria-expanded="true"] .icon { - transform: translateY(-30%) rotate(-135deg); -} - -.activitypub-settings-accordion-trigger:active, -.activitypub-settings-accordion-trigger:hover { - background: #f6f7f7; -} - -.activitypub-settings-accordion-trigger:focus { - color: #1d2327; - border: none; - box-shadow: none; - outline-offset: -1px; - outline: 2px solid #2271b1; - background-color: #f6f7f7; -} - -.activitypub-settings -input.blog-user-identifier { - text-align: right; -} - -.activitypub-settings -.header-image { - width: 100%; - height: 80px; - position: relative; - display: block; - margin-bottom: 40px; - background-image: rgb(168,165,175); - background-image: linear-gradient(180deg, red, yellow); - background-size: cover; -} - -.activitypub-settings .logo { - height: 80px; - width: 80px; - position: relative; - top: 40px; - left: 40px; -} - -.settings_page_activitypub .plugin-recommendations { - border-bottom: none; - margin-bottom: 0; -} - -#dashboard_right_now li a.activitypub-followers::before { - content: "\f307"; - font-family: dashicons; -} - -.repost .dashboard-comment-wrap, -.like .dashboard-comment-wrap { - padding-inline-start: 63px; -} - -.repost .dashboard-comment-wrap .comment-author, -.like .dashboard-comment-wrap .comment-author { - margin-block: 0; -} - -.activitypub-settings .welcome-tab-close { - position: absolute; - top: 0px; - right: 0px; - font-size: 13px; - padding: 0 5px 0 20px; - text-decoration: none; - z-index: 1; -} - -.activitypub-settings .welcome-tab-close::before { - position: absolute; - top: 0px; - left: 0; - transition: all .1s ease-in-out; - font: normal 16px/20px dashicons; - content: '\f335'; - font-size: 20px; -} - -.activitypub-notice .count { - display: inline-block; - vertical-align: top; - box-sizing: border-box; - margin: 1px 0 -1px 2px; - padding: 0 5px; - min-width: 18px; - height: 18px; - border-radius: 9px; - background-color: #dba617; - color: #fff; - font-size: 11px; - line-height: 1.6; - text-align: center; - z-index: 26; -} - -.activitypub-notice .dashicons-warning { - color: #dba617; -} - -.extra-fields-nav a + a { - margin-left: 8px; -} -.rtl .extra-fields-nav a + a { - margin-left: auto; - margin-right: 8px; -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/css/activitypub-embed.css b/wp-content/upgrade-temp-backup/plugins/activitypub/assets/css/activitypub-embed.css deleted file mode 100644 index 0422fb40..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/css/activitypub-embed.css +++ /dev/null @@ -1,115 +0,0 @@ -/** - * ActivityPub embed styles. - */ - -.activitypub-embed { - background: #fff; - border: 1px solid #e6e6e6; - border-radius: 12px; - padding: 0; - max-width: 100%; - font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; -} - -.activitypub-reply-block .activitypub-embed { - margin: 1em 0; -} - -.activitypub-embed-header { - padding: 15px; - display: flex; - align-items: center; - gap: 10px; -} - -.activitypub-embed-header img { - width: 48px; - height: 48px; - border-radius: 50%; -} - -.activitypub-embed-header-text { - flex-grow: 1; -} - -.activitypub-embed-header-text h2 { - color: #000; - font-size: 15px; - font-weight: 600; - margin: 0; - padding: 0; -} - -.activitypub-embed-header-text .ap-account { - color: #687684; - font-size: 14px; - text-decoration: none; -} - -.activitypub-embed-content { - padding: 0 15px 15px; -} - -.activitypub-embed-content .ap-title { - font-size: 23px; - font-weight: 600; - margin: 0 0 10px; - padding: 0; - color: #000; -} - -.activitypub-embed-content .ap-subtitle { - font-size: 15px; - color: #000; - margin: 0 0 15px; -} - -.activitypub-embed-content .ap-preview { - border: 1px solid #e6e6e6; - border-radius: 8px; - overflow: hidden; -} - -.activitypub-embed-content .ap-preview img { - width: 100%; - height: auto; - display: block; -} - -.activitypub-embed-content .ap-preview-text { - padding: 15px; -} - -.activitypub-embed-meta { - padding: 15px; - border-top: 1px solid #e6e6e6; - color: #687684; - font-size: 13px; - display: flex; - gap: 15px; -} - -.activitypub-embed-meta .ap-stat { - display: flex; - align-items: center; - gap: 5px; -} -@media only screen and (max-width: 399px) { - .activitypub-embed-meta span.ap-stat { - display: none !important; - } -} - -.activitypub-embed-meta a.ap-stat { - color: inherit; - text-decoration: none; -} - -.activitypub-embed-meta strong { - font-weight: 600; - color: #000; -} - -.activitypub-embed-meta .ap-stat-label { - color: #687684; -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/img/mp.jpg b/wp-content/upgrade-temp-backup/plugins/activitypub/assets/img/mp.jpg deleted file mode 100644 index 05964b49..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/img/mp.jpg and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/img/wp-logo.png b/wp-content/upgrade-temp-backup/plugins/activitypub/assets/img/wp-logo.png deleted file mode 100644 index b48f08e8..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/img/wp-logo.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/js/activitypub-admin.js b/wp-content/upgrade-temp-backup/plugins/activitypub/assets/js/activitypub-admin.js deleted file mode 100644 index 37117cab..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/js/activitypub-admin.js +++ /dev/null @@ -1,21 +0,0 @@ -jQuery( function( $ ) { - // Accordion handling in various areas. - $( '.activitypub-settings-accordion' ).on( 'click', '.activitypub-settings-accordion-trigger', function() { - var isExpanded = ( 'true' === $( this ).attr( 'aria-expanded' ) ); - - if ( isExpanded ) { - $( this ).attr( 'aria-expanded', 'false' ); - $( '#' + $( this ).attr( 'aria-controls' ) ).attr( 'hidden', true ); - } else { - $( this ).attr( 'aria-expanded', 'true' ); - $( '#' + $( this ).attr( 'aria-controls' ) ).attr( 'hidden', false ); - } - } ); - - $(document).on( 'wp-plugin-install-success', function( event, response ) { - setTimeout( function() { - $( '.activate-now' ).removeClass( 'thickbox open-plugin-details-modal' ); - }, 1200 ); - } ); - -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/js/activitypub-header-image.js b/wp-content/upgrade-temp-backup/plugins/activitypub/assets/js/activitypub-header-image.js deleted file mode 100644 index d43af9e9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/assets/js/activitypub-header-image.js +++ /dev/null @@ -1,271 +0,0 @@ -/** - * Handle the header image setting in - * - * This is based on site-icon.js - * - * @see wp-admin/js/site-icon.js - */ - -/* global jQuery, wp */ - -( function ( $ ) { - var $chooseButton = $( '#activitypub-choose-from-library-button' ), - $headerImagePreviewWrapper = $( '#activitypub-header-image-preview-wrapper' ), - $headerImagePreview = $( '#activitypub-header-image-preview' ), - $hiddenDataField = $( '#activitypub_header_image' ), - $removeButton = $( '#activitypub-remove-header-image' ), - frame, - ImageCropperNoCustomizer; - - /** - * We register our own handler because the Core one invokes the Customizer, which fails the request unnecessarily - * for users who don't have the 'customize' capability. - * See https://github.com/Automattic/wordpress-activitypub/issues/846 - */ - ImageCropperNoCustomizer = wp.media.controller.CustomizeImageCropper.extend( { - doCrop: function( attachment ) { - var cropDetails = attachment.get( 'cropDetails' ), - control = this.get( 'control' ), - ratio = cropDetails.width / cropDetails.height; - - // Use crop measurements when flexible in both directions. - if ( control.params.flex_width && control.params.flex_height ) { - cropDetails.dst_width = cropDetails.width; - cropDetails.dst_height = cropDetails.height; - - // Constrain flexible side based on image ratio and size of the fixed side. - } else { - cropDetails.dst_width = control.params.flex_width ? control.params.height * ratio : control.params.width; - cropDetails.dst_height = control.params.flex_height ? control.params.width / ratio : control.params.height; - } - - return wp.ajax.post( 'crop-image', { - // where wp_customize: 'on' would be in Core, for no good reason I understand. - nonce: attachment.get( 'nonces' ).edit, - id: attachment.get( 'id' ), - context: control.id, - cropDetails: cropDetails - } ); - } - } ); - - - - /** - * Calculate image selection options based on the attachment dimensions. - * - * @since 6.5.0 - * - * @param {Object} attachment The attachment object representing the image. - * @return {Object} The image selection options. - */ - function calculateImageSelectOptions( attachment ) { - var realWidth = attachment.get( 'width' ), - realHeight = attachment.get( 'height' ), - xInit = 1500, - yInit = 500, - ratio = xInit / yInit, - xImg = xInit, - yImg = yInit, - x1, - y1, - imgSelectOptions; - - if ( realWidth / realHeight > ratio ) { - yInit = realHeight; - xInit = yInit * ratio; - } else { - xInit = realWidth; - yInit = xInit / ratio; - } - - x1 = ( realWidth - xInit ) / 2; - y1 = ( realHeight - yInit ) / 2; - - imgSelectOptions = { - aspectRatio: xInit + ':' + yInit, - handles: true, - keys: true, - instance: true, - persistent: true, - imageWidth: realWidth, - imageHeight: realHeight, - minWidth: xImg > xInit ? xInit : xImg, - minHeight: yImg > yInit ? yInit : yImg, - x1: x1, - y1: y1, - x2: xInit + x1, - y2: yInit + y1, - }; - - return imgSelectOptions; - } - - /** - * Initializes the media frame for selecting or cropping an image. - * - * @since 6.5.0 - */ - $chooseButton.on( 'click', function () { - var $el = $( this ); - var userId = $el.data( 'userId' ); - var mediaQuery = { type: 'image' }; - if ( userId ) { - mediaQuery.author = userId; - } - - // Create the media frame. - frame = wp.media( { - button: { - // Set the text of the button. - text: $el.data( 'update' ), - - // Don't close, we might need to crop. - close: false, - }, - states: [ - new wp.media.controller.Library( { - title: $el.data( 'choose-text' ), - library: wp.media.query( mediaQuery ), - date: false, - suggestedWidth: $el.data( 'width' ), - suggestedHeight: $el.data( 'height' ), - } ), - new ImageCropperNoCustomizer( { - control: { - id: 'activitypub-header-image', - params: { - width: $el.data( 'width' ), - height: $el.data( 'height' ), - }, - }, - imgSelectOptions: calculateImageSelectOptions, - } ), - ], - } ); - - frame.on( 'cropped', function ( attachment ) { - $hiddenDataField.val( attachment.id ); - switchToUpdate( attachment ); - frame.close(); - - // Start over with a frame that is so fresh and so clean clean. - frame = null; - } ); - - // When an image is selected, run a callback. - frame.on( 'select', function () { - // Grab the selected attachment. - var attachment = frame.state().get( 'selection' ).first(), - targetRatio = $el.data( 'width' ) / $el.data( 'height' ), - currentRatio = attachment.attributes.width / attachment.attributes.height, - alreadyCropped = false; - - // Check if the image already has the correct aspect ratio (with a small tolerance). - if ( Math.abs( currentRatio - targetRatio ) < 0.01 ) { - // Check if this is the same image that was already selected. - if ( attachment.id !== parseInt( $hiddenDataField.val(), 10 ) ) { - // This is a new image with the correct aspect ratio. - $hiddenDataField.val( attachment.id ); - } - - alreadyCropped = true; - } - - if ( alreadyCropped ) { - // Skip cropping for already cropped images. - switchToUpdate( attachment.attributes ); - frame.close(); - } else { - frame.setState( 'cropper' ); - } - } ); - - frame.open(); - } ); - - /** - * Update the UI when a header is selected. - * - * @since 6.5.0 - * - * @param {array} attributes The attributes for the attachment. - */ - function switchToUpdate( attributes ) { - var i18nAppAlternativeString, i18nBrowserAlternativeString; - - if ( attributes.alt ) { - i18nBrowserAlternativeString = wp.i18n.sprintf( - /* translators: %s: The selected image alt text. */ - wp.i18n.__( 'Header Image preview: Current image: %s' ), - attributes.alt - ); - } else { - i18nAppAlternativeString = wp.i18n.sprintf( - /* translators: %s: The selected image filename. */ - wp.i18n.__( - 'Header Image preview: The current image has no alternative text. The file name is: %s' - ), - attributes.filename - ); - i18nBrowserAlternativeString = wp.i18n.sprintf( - /* translators: %s: The selected image filename. */ - wp.i18n.__( - 'Header Image preview: The current image has no alternative text. The file name is: %s' - ), - attributes.filename - ); - } - - // Set activitypub-header-image-preview src. - $headerImagePreview.attr( { - src: attributes.url, - alt: i18nAppAlternativeString, - } ); - - // Remove hidden class from header image preview div and remove button. - $headerImagePreviewWrapper.removeClass( 'hidden' ); - $removeButton.removeClass( 'hidden' ); - - // If the choose button is not in the update state, swap the classes. - if ( $chooseButton.attr( 'data-state' ) !== '1' ) { - $chooseButton.attr( { - class: $chooseButton.attr( 'data-alt-classes' ), - 'data-alt-classes': $chooseButton.attr( 'class' ), - 'data-state': '1', - } ); - } - - // Swap the text of the choose button. - $chooseButton.text( $chooseButton.attr( 'data-update-text' ) ); - } - - /** - * Handles the click event of the remove button. - * - * @since 6.5.0 - */ - $removeButton.on( 'click', function () { - $hiddenDataField.val( 'false' ); - $( this ).toggleClass( 'hidden' ); - $headerImagePreviewWrapper.toggleClass( 'hidden' ); - $headerImagePreview.attr( { - src: '', - alt: '', - } ); - - /** - * Resets state to the button, for correct visual style and state. - * Updates the text of the button. - * Sets focus state to the button. - */ - $chooseButton - .attr( { - class: $chooseButton.attr( 'data-alt-classes' ), - 'data-alt-classes': $chooseButton.attr( 'class' ), - 'data-state': '', - } ) - .text( $chooseButton.attr( 'data-choose-text' ) ) - .trigger( 'focus' ); - } ); -} )( jQuery ); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/block.json deleted file mode 100644 index f41effc5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/block.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "name": "editor-plugin", - "title": "Editor Plugin: not a block, but block.json is very useful.", - "category": "widgets", - "icon": "admin-comments", - "keywords": [], - "editorScript": "file:./plugin.js" -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/plugin.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/plugin.asset.php deleted file mode 100644 index b753ae85..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/plugin.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-components', 'wp-core-data', 'wp-data', 'wp-editor', 'wp-element', 'wp-i18n', 'wp-plugins', 'wp-primitives', 'wp-url'), 'version' => '293b8e75ac7a589c5096'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/plugin.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/plugin.js deleted file mode 100644 index cad41787..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/editor-plugin/plugin.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";var e={20:(e,t,i)=>{var n=i(609),o=Symbol.for("react.element"),r=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),l=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,i){var n,c={},s=null,p=null;for(n in void 0!==i&&(s=""+i),void 0!==t.key&&(s=""+t.key),void 0!==t.ref&&(p=t.ref),t)r.call(t,n)&&!a.hasOwnProperty(n)&&(c[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===c[n]&&(c[n]=t[n]);return{$$typeof:o,type:e,key:s,ref:p,props:c,_owner:l.current}}},848:(e,t,i)=>{e.exports=i(20)},609:e=>{e.exports=window.React}},t={};function i(n){var o=t[n];if(void 0!==o)return o.exports;var r=t[n]={exports:{}};return e[n](r,r.exports,i),r.exports}var n=i(609);const o=window.wp.editor,r=window.wp.plugins,l=window.wp.components,a=window.wp.element,c=(0,a.forwardRef)((function({icon:e,size:t=24,...i},n){return(0,a.cloneElement)(e,{width:t,height:t,...i,ref:n})})),s=window.wp.primitives;var p=i(848);const u=(0,p.jsx)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,p.jsx)(s.Path,{d:"M12 3.3c-4.8 0-8.8 3.9-8.8 8.8 0 4.8 3.9 8.8 8.8 8.8 4.8 0 8.8-3.9 8.8-8.8s-4-8.8-8.8-8.8zm6.5 5.5h-2.6C15.4 7.3 14.8 6 14 5c2 .6 3.6 2 4.5 3.8zm.7 3.2c0 .6-.1 1.2-.2 1.8h-2.9c.1-.6.1-1.2.1-1.8s-.1-1.2-.1-1.8H19c.2.6.2 1.2.2 1.8zM12 18.7c-1-.7-1.8-1.9-2.3-3.5h4.6c-.5 1.6-1.3 2.9-2.3 3.5zm-2.6-4.9c-.1-.6-.1-1.1-.1-1.8 0-.6.1-1.2.1-1.8h5.2c.1.6.1 1.1.1 1.8s-.1 1.2-.1 1.8H9.4zM4.8 12c0-.6.1-1.2.2-1.8h2.9c-.1.6-.1 1.2-.1 1.8 0 .6.1 1.2.1 1.8H5c-.2-.6-.2-1.2-.2-1.8zM12 5.3c1 .7 1.8 1.9 2.3 3.5H9.7c.5-1.6 1.3-2.9 2.3-3.5zM10 5c-.8 1-1.4 2.3-1.8 3.8H5.5C6.4 7 8 5.6 10 5zM5.5 15.3h2.6c.4 1.5 1 2.8 1.8 3.7-1.8-.6-3.5-2-4.4-3.7zM14 19c.8-1 1.4-2.2 1.8-3.7h2.6C17.6 17 16 18.4 14 19z"})}),v=(0,p.jsx)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,p.jsx)(s.Path,{d:"M15.5 9.5a1 1 0 100-2 1 1 0 000 2zm0 1.5a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm-2.25 6v-2a2.75 2.75 0 00-2.75-2.75h-4A2.75 2.75 0 003.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0120.25 15zM9.5 8.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0z",fillRule:"evenodd"})}),w=(0,p.jsx)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,p.jsx)(s.Path,{d:"M19.5 4.5h-7V6h4.44l-5.97 5.97 1.06 1.06L18 7.06v4.44h1.5v-7Zm-13 1a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-3H17v3a.5.5 0 0 1-.5.5h-10a.5.5 0 0 1-.5-.5v-10a.5.5 0 0 1 .5-.5h3V5.5h-3Z"})}),d=window.wp.data,_=window.wp.coreData,b=window.wp.url,h=window.wp.i18n,y=(0,n.createElement)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,n.createElement)(s.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5A6.5 6.5 0 0 1 6.93 7.931l9.139 9.138A6.473 6.473 0 0 1 12 18.5Zm5.123-2.498a6.5 6.5 0 0 0-9.124-9.124l9.124 9.124ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Z"}));(0,r.registerPlugin)("activitypub-editor-plugin",{render:()=>{const e=(0,d.useSelect)((e=>e("core/editor").getCurrentPostType()),[]),[t,i]=(0,_.useEntityProp)("postType",e,"meta"),r={verticalAlign:"middle",gap:"4px",justifyContent:"start",display:"inline-flex",alignItems:"center"},a=(e,t,i)=>(0,n.createElement)(l.Tooltip,{text:i},(0,n.createElement)(l.__experimentalText,{style:r},(0,n.createElement)(c,{icon:e}),t));return"wp_block"===e?null:(0,n.createElement)(o.PluginDocumentSettingPanel,{name:"activitypub",title:(0,h.__)("Fediverse ⁂","activitypub")},(0,n.createElement)(l.TextControl,{label:(0,h.__)("Content Warning","activitypub"),value:t?.activitypub_content_warning,onChange:e=>{i({...t,activitypub_content_warning:e})},placeholder:(0,h.__)("Optional content warning","activitypub"),help:(0,h.__)("Content warnings do not change the content on your site, only in the fediverse.","activitypub")}),(0,n.createElement)(l.RadioControl,{label:(0,h.__)("Visibility","activitypub"),help:(0,h.__)("This adjusts the visibility of a post in the fediverse, but note that it won't affect how the post appears on the blog.","activitypub"),selected:t?.activitypub_content_visibility||"public",options:[{label:a(u,(0,h.__)("Public","activitypub"),(0,h.__)("Post will be visible to everyone and appear in public timelines.","activitypub")),value:"public"},{label:a(v,(0,h.__)("Quiet public","activitypub"),(0,h.__)("Post will be visible to everyone but will not appear in public timelines.","activitypub")),value:"quiet_public"},{label:a(y,(0,h.__)("Do not federate","activitypub"),(0,h.__)("Post will not be shared to the Fediverse.","activitypub")),value:"local"}],onChange:e=>{i({...t,activitypub_content_visibility:e})},className:"activitypub-visibility"}))}}),(0,r.registerPlugin)("activitypub-editor-preview",{render:()=>{const e=(0,d.useSelect)((e=>e("core/editor").getCurrentPost().status));return(0,n.createElement)(n.Fragment,null,o.PluginPreviewMenuItem?(0,n.createElement)(o.PluginPreviewMenuItem,{onClick:()=>function(){const e=(0,d.select)("core/editor").getEditedPostPreviewLink(),t=(0,b.addQueryArgs)(e,{activitypub:"true"});window.open(t,"_blank")}(),icon:w,disabled:"auto-draft"===e},(0,h.__)("Fediverse preview ⁂","activitypub")):null)}})})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/block.json deleted file mode 100644 index e799fbb5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/block.json +++ /dev/null @@ -1,68 +0,0 @@ -{ - "$schema": "https://schemas.wp.org/trunk/block.json", - "name": "activitypub/follow-me", - "apiVersion": 3, - "version": "1.0.0", - "title": "Follow me on the Fediverse", - "category": "widgets", - "description": "Display your Fediverse profile so that visitors can follow you.", - "textdomain": "activitypub", - "icon": "groups", - "supports": { - "html": false, - "color": { - "gradients": true, - "link": true, - "__experimentalDefaultControls": { - "background": true, - "text": true, - "link": true - } - }, - "__experimentalBorder": { - "radius": true, - "width": true, - "color": true, - "style": true - }, - "typography": { - "fontSize": true, - "__experimentalDefaultControls": { - "fontSize": true - } - } - }, - "attributes": { - "selectedUser": { - "type": "string", - "default": "site" - }, - "buttonOnly": { - "type": "boolean", - "default": false - }, - "buttonText": { - "type": "string", - "default": "Follow" - }, - "buttonSize": { - "type": "string", - "default": "default", - "enum": [ - "small", - "default", - "compact" - ] - } - }, - "usesContext": [ - "postType", - "postId" - ], - "editorScript": "file:./index.js", - "viewScript": "file:./view.js", - "style": [ - "file:./style-view.css", - "wp-components" - ] -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/index.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/index.asset.php deleted file mode 100644 index 48631347..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-primitives'), 'version' => '8f1a6f7e5f76d58a3204'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/index.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/index.js deleted file mode 100644 index e6dae559..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/index.js +++ /dev/null @@ -1,3 +0,0 @@ -(()=>{"use strict";var e,t={919:(e,t,o)=>{const r=window.wp.blocks,n=window.wp.primitives;var l=o(848);const a=(0,l.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,l.jsx)(n.Path,{d:"M15.5 9.5a1 1 0 100-2 1 1 0 000 2zm0 1.5a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm-2.25 6v-2a2.75 2.75 0 00-2.75-2.75h-4A2.75 2.75 0 003.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0120.25 15zM9.5 8.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0z",fillRule:"evenodd"})});var i=o(609);const c=window.wp.blockEditor,u=window.wp.i18n,s=window.wp.data,p=window.wp.coreData,d=window.wp.components,m=window.wp.element;function v(){return window._activityPubOptions||{}}const b=window.wp.apiFetch;var f=o.n(b);function y(e){return`var(--wp--preset--color--${e})`}function _(e){if("string"!=typeof e)return null;if(e.match(/^#/))return e.substring(0,7);const[,,t]=e.split("|");return y(t)}function h(e,t,o=null,r=""){return o?`${e}${r} { ${t}: ${o}; }\n`:""}function w(e,t,o,r){return h(e,"background-color",t)+h(e,"color",o)+h(e,"background-color",r,":hover")+h(e,"background-color",r,":focus")}function g({selector:e,style:t,backgroundColor:o}){const r=function(e,t,o){const r=`${e} .components-button`,n=("string"==typeof(l=o)?y(l):l?.color?.background||null)||t?.color?.background;var l;return w(r,_(t?.elements?.link?.color?.text),n,_(t?.elements?.link?.[":hover"]?.color?.text))}(e,t,o);return(0,i.createElement)("style",null,r)}const E=(0,l.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,l.jsx)(n.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5 4.5h11a.5.5 0 0 1 .5.5v11a.5.5 0 0 1-.5.5H5a.5.5 0 0 1-.5-.5V5a.5.5 0 0 1 .5-.5ZM3 5a2 2 0 0 1 2-2h11a2 2 0 0 1 2 2v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5Zm17 3v10.75c0 .69-.56 1.25-1.25 1.25H6v1.5h12.75a2.75 2.75 0 0 0 2.75-2.75V8H20Z"})}),x=(0,l.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,l.jsx)(n.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})}),S=(0,m.forwardRef)((function({icon:e,size:t=24,...o},r){return(0,m.cloneElement)(e,{width:t,height:t,...o,ref:r})})),k=window.wp.compose,C="fediverse-remote-user";function O(e){try{return new URL(e),!0}catch(e){return!1}}function T({actionText:e,copyDescription:t,handle:o,resourceUrl:r,myProfile:n="",rememberProfile:l=!1}){const c=(0,u.__)("Loading...","activitypub"),s=(0,u.__)("Opening...","activitypub"),p=(0,u.__)("Error","activitypub"),v=(0,u.__)("Invalid","activitypub"),b=n||(0,u.__)("My Profile","activitypub"),[y,_]=(0,m.useState)(e),[h,w]=(0,m.useState)(E),g=(0,k.useCopyToClipboard)(o,(()=>{w(x),setTimeout((()=>w(E)),1e3)})),[T,N]=(0,m.useState)(""),[I,R]=(0,m.useState)(!0),{setRemoteUser:U}=function(){const[e,t]=(0,m.useState)(function(){const e=localStorage.getItem(C);return e?JSON.parse(e):{}}()),o=(0,m.useCallback)((e=>{!function(e){localStorage.setItem(C,JSON.stringify(e))}(e),t(e)}),[]),r=(0,m.useCallback)((()=>{localStorage.removeItem(C),t({})}),[]);return{template:e?.template||!1,profileURL:e?.profileURL||!1,setRemoteUser:o,deleteRemoteUser:r}}(),z=(0,m.useCallback)((()=>{let t;if(!O(T)&&!function(e){const t=e.replace(/^@/,"").split("@");return 2===t.length&&O(`https://${t[1]}`)}(T))return _(v),t=setTimeout((()=>_(e)),2e3),()=>clearTimeout(t);const o=r+T;_(c),f()({path:o}).then((({url:t,template:o})=>{I&&U({profileURL:T,template:o}),_(s),setTimeout((()=>{window.open(t,"_blank"),_(e)}),200)})).catch((()=>{_(p),setTimeout((()=>_(e)),2e3)}))}),[T]);return(0,i.createElement)("div",{className:"activitypub__dialog",role:"dialog","aria-labelledby":"dialog-title"},(0,i.createElement)("div",{className:"activitypub-dialog__section"},(0,i.createElement)("h4",{id:"dialog-title"},b),(0,i.createElement)("div",{className:"activitypub-dialog__description",id:"copy-description"},t),(0,i.createElement)("div",{className:"activitypub-dialog__button-group"},(0,i.createElement)("label",{htmlFor:"profile-handle",className:"screen-reader-text"},t),(0,i.createElement)("input",{type:"text",id:"profile-handle",value:o,readOnly:!0}),(0,i.createElement)(d.Button,{ref:g,"aria-label":(0,u.__)("Copy handle to clipboard","activitypub")},(0,i.createElement)(S,{icon:h}),(0,u.__)("Copy","activitypub")))),(0,i.createElement)("div",{className:"activitypub-dialog__section"},(0,i.createElement)("h4",{id:"remote-profile-title"},(0,u.__)("Your Profile","activitypub")),(0,i.createElement)("div",{className:"activitypub-dialog__description",id:"remote-profile-description"},(0,m.createInterpolateElement)((0,u.__)("Or, if you know your own profile, we can start things that way! (eg @yourusername@example.com)","activitypub"),{code:(0,i.createElement)("code",null)})),(0,i.createElement)("div",{className:"activitypub-dialog__button-group"},(0,i.createElement)("label",{htmlFor:"remote-profile",className:"screen-reader-text"},(0,u.__)("Enter your ActivityPub profile","activitypub")),(0,i.createElement)("input",{type:"text",id:"remote-profile",value:T,onKeyDown:e=>{"Enter"===e?.code&&z()},onChange:e=>N(e.target.value),"aria-invalid":y===v}),(0,i.createElement)(d.Button,{onClick:z,"aria-label":(0,u.__)("Submit profile","activitypub")},(0,i.createElement)(S,{icon:a}),y)),l&&(0,i.createElement)("div",{className:"activitypub-dialog__remember"},(0,i.createElement)(d.CheckboxControl,{checked:I,label:(0,u.__)("Remember me for easier comments","activitypub"),onChange:()=>{R(!I)}}))))}const N={avatar:"",webfinger:"@well@hello.dolly",name:(0,u.__)("Hello Dolly Fan Account","activitypub"),url:"#"};function I(e){if(!e)return N;const t={...N,...e};return t.avatar=t?.icon?.url,t}function R({profile:e,popupStyles:t,userId:o,buttonText:r,buttonOnly:n,buttonSize:l}){const{webfinger:a,avatar:c,name:u}=e,s=a.startsWith("@")?a:`@${a}`;return n?(0,i.createElement)("div",{className:"activitypub-profile"},(0,i.createElement)(U,{profile:e,popupStyles:t,userId:o,buttonText:r,buttonSize:l})):(0,i.createElement)("div",{className:"activitypub-profile"},(0,i.createElement)("img",{className:"activitypub-profile__avatar",src:c,alt:u}),(0,i.createElement)("div",{className:"activitypub-profile__content"},(0,i.createElement)("div",{className:"activitypub-profile__name"},u),(0,i.createElement)("div",{className:"activitypub-profile__handle",title:s},s)),(0,i.createElement)(U,{profile:e,popupStyles:t,userId:o,buttonText:r,buttonSize:l}))}function U({profile:e,popupStyles:t,userId:o,buttonText:r,buttonSize:n}){const[l,a]=(0,m.useState)(!1),c=(0,u.sprintf)(/* translators: %s: profile name */ /* translators: %s: profile name */ -(0,u.__)("Follow %s","activitypub"),e?.name);return(0,i.createElement)(i.Fragment,null,(0,i.createElement)(d.Button,{className:"activitypub-profile__follow",onClick:()=>a(!0),"aria-haspopup":"dialog","aria-expanded":l,"aria-label":(0,u.__)("Follow me on the Fediverse","activitypub"),size:n},r),l&&(0,i.createElement)(d.Modal,{className:"activitypub-profile__confirm activitypub__modal",onRequestClose:()=>a(!1),title:c,"aria-label":c,role:"dialog"},(0,i.createElement)(z,{profile:e,userId:o}),(0,i.createElement)("style",null,t)))}function z({profile:e,userId:t}){const{namespace:o}=v(),{webfinger:r}=e,n=(0,u.__)("Follow","activitypub"),l=`/${o}/actors/${t}/remote-follow?resource=`,a=(0,u.__)("Copy and paste my profile into the search field of your favorite fediverse app or server.","activitypub"),c=r.startsWith("@")?r:`@${r}`;return(0,i.createElement)(T,{actionText:n,copyDescription:a,handle:c,resourceUrl:l})}function $({selectedUser:e,style:t,backgroundColor:o,id:r,useId:n=!1,profileData:l=!1,buttonOnly:a=!1,buttonText:c=(0,u.__)("Follow","activitypub"),buttonSize:s="default"}){const[p,d]=(0,m.useState)(I()),b="site"===e?0:e,y=function(e){return w(".apfmd__button-group .components-button",_(e?.elements?.link?.color?.text)||"#111","#fff",_(e?.elements?.link?.[":hover"]?.color?.text)||"#333")}(t),h=n?{id:r}:{};return(0,m.useEffect)((()=>{l?d(I(l)):function(e){const{namespace:t}=v(),o={headers:{Accept:"application/activity+json"},path:`/${t}/actors/${e}`};return f()(o)}(b).then((e=>{d(I(e))}))}),[b,l]),(0,i.createElement)("div",{...h,className:"activitypub-follow-me-block-wrapper"},(0,i.createElement)(g,{selector:`#${r}`,style:t,backgroundColor:o}),(0,i.createElement)(R,{profile:p,userId:b,popupStyles:y,buttonText:c,buttonOnly:a,buttonSize:s}))}function P({name:e}){const{enabled:t}=v(),o=t?.site?"":(0,u.__)("It will be empty in other non-author contexts.","activitypub"),r=(0,u.sprintf)(/* translators: %1$s: block name, %2$s: extra information for non-author context */ /* translators: %1$s: block name, %2$s: extra information for non-author context */ -(0,u.__)("This %1$s block will adapt to the page it is on, displaying the user profile associated with a post author (in a loop) or a user archive. %2$s","activitypub"),e,o).trim();return(0,i.createElement)(d.Card,null,(0,i.createElement)(d.CardBody,null,(0,m.createInterpolateElement)(r,{strong:(0,i.createElement)("strong",null)})))}(0,r.registerBlockType)("activitypub/follow-me",{edit:function({attributes:e,setAttributes:t,context:{postType:o,postId:r}}){const n=(0,c.useBlockProps)({className:"activitypub-follow-me-block-wrapper"}),l=function({withInherit:e=!1}){const{enabled:t}=v(),o=t?.users?(0,s.useSelect)((e=>e("core").getUsers({who:"authors"}))):[];return(0,m.useMemo)((()=>{if(!o)return[];const r=[];return t?.site&&r.push({label:(0,u.__)("Site","activitypub"),value:"site"}),e&&t?.users&&r.push({label:(0,u.__)("Dynamic User","activitypub"),value:"inherit"}),o.reduce(((e,t)=>(e.push({label:t.name,value:`${t.id}`}),e)),r)}),[o])}({withInherit:!0}),{selectedUser:a,buttonOnly:b,buttonText:f,buttonSize:y}=e,_="inherit"===a,h=(0,s.useSelect)((e=>{const{getEditedEntityRecord:t}=e(p.store),n=t("postType",o,r)?.author;return null!=n?n:null}),[o,r]);return(0,m.useEffect)((()=>{l.length&&(l.find((({value:e})=>e===a))||t({selectedUser:l[0].value}))}),[a,l]),(0,i.createElement)("div",{...n},(0,i.createElement)(c.InspectorControls,{key:"activitypub-follow-me"},(0,i.createElement)(d.PanelBody,{title:(0,u.__)("Follow Me Options","activitypub")},l.length>1&&(0,i.createElement)(d.SelectControl,{label:(0,u.__)("Select User","activitypub"),value:e.selectedUser,options:l,onChange:e=>t({selectedUser:e})}),(0,i.createElement)(d.ToggleControl,{label:(0,u.__)("Button Only Mode","activitypub"),checked:b,onChange:e=>t({buttonOnly:e}),help:(0,u.__)("Only show the follow button without profile information","activitypub")}),(0,i.createElement)(d.TextControl,{label:(0,u.__)("Button Text","activitypub"),value:f,onChange:e=>t({buttonText:e})}),(0,i.createElement)(d.SelectControl,{label:(0,u.__)("Button Size","activitypub"),value:y,options:[{label:(0,u.__)("Default","activitypub"),value:"default"},{label:(0,u.__)("Compact","activitypub"),value:"compact"},{label:(0,u.__)("Small","activitypub"),value:"small"}],onChange:e=>t({buttonSize:e}),help:(0,u.__)("Choose the size of the follow button","activitypub")}))),_?h?(0,i.createElement)($,{...e,id:n.id,selectedUser:h}):(0,i.createElement)(P,{name:(0,u.__)("Follow Me","activitypub")}):(0,i.createElement)($,{...e,id:n.id}))},save:()=>null,icon:a})},20:(e,t,o)=>{var r=o(609),n=Symbol.for("react.element"),l=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),a=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,o){var r,c={},u=null,s=null;for(r in void 0!==o&&(u=""+o),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(s=t.ref),t)l.call(t,r)&&!i.hasOwnProperty(r)&&(c[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===c[r]&&(c[r]=t[r]);return{$$typeof:n,type:e,key:u,ref:s,props:c,_owner:a.current}}},848:(e,t,o)=>{e.exports=o(20)},609:e=>{e.exports=window.React}},o={};function r(e){var n=o[e];if(void 0!==n)return n.exports;var l=o[e]={exports:{}};return t[e](l,l.exports,r),l.exports}r.m=t,e=[],r.O=(t,o,n,l)=>{if(!o){var a=1/0;for(s=0;s=l)&&Object.keys(r.O).every((e=>r.O[e](o[c])))?o.splice(c--,1):(i=!1,l0&&e[s-1][2]>l;s--)e[s]=e[s-1];e[s]=[o,n,l]},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var o in t)r.o(t,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={338:0,301:0};r.O.j=t=>0===e[t];var t=(t,o)=>{var n,l,a=o[0],i=o[1],c=o[2],u=0;if(a.some((t=>0!==e[t]))){for(n in i)r.o(i,n)&&(r.m[n]=i[n]);if(c)var s=c(r)}for(t&&t(o);ur(919)));n=r.O(n)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/style-view-rtl.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/style-view-rtl.css deleted file mode 100644 index eb3c8508..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/style-view-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub__modal.components-modal__frame{background-color:#f7f7f7;color:#333}.activitypub__modal.components-modal__frame .components-modal__header-heading,.activitypub__modal.components-modal__frame h4{color:#333;letter-spacing:inherit;word-spacing:inherit}.activitypub__modal.components-modal__frame .components-modal__header .components-button:hover{color:var(--color-white)}.activitypub__dialog{max-width:40em}.activitypub__dialog h4{line-height:1;margin:0}.activitypub__dialog .activitypub-dialog__section{margin-bottom:2em}.activitypub__dialog .activitypub-dialog__remember{margin-top:1em}.activitypub__dialog .activitypub-dialog__description{font-size:var(--wp--preset--font-size--normal,.75rem);margin:.33em 0 1em}.activitypub__dialog .activitypub-dialog__button-group{align-items:flex-end;display:flex;justify-content:flex-end}.activitypub__dialog .activitypub-dialog__button-group svg{height:21px;margin-left:.5em;width:21px}.activitypub__dialog .activitypub-dialog__button-group input{background-color:var(--wp--preset--color--white);border-radius:0 50px 50px 0;border-width:1px;border:1px solid var(--wp--preset--color--black);color:var(--wp--preset--color--black);flex:1;font-size:16px;height:inherit;line-height:1;margin-left:0;padding:15px 23px}.activitypub__dialog .activitypub-dialog__button-group button{align-self:center;background-color:var(--wp--preset--color--black);border-radius:50px 0 0 50px;border-width:1px;color:var(--wp--preset--color--white);font-size:16px;height:inherit;line-height:1;margin-right:0;padding:15px 23px;text-decoration:none}.activitypub__dialog .activitypub-dialog__button-group button:hover{border:inherit}.activitypub-follow-me-block-wrapper{width:100%}.activitypub-follow-me-block-wrapper.has-background .activitypub-profile,.activitypub-follow-me-block-wrapper.has-border-color .activitypub-profile{padding-right:1rem;padding-left:1rem}.activitypub-follow-me-block-wrapper .activitypub-profile{align-items:center;display:flex;padding:1rem 0}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__avatar{border-radius:50%;height:75px;margin-left:1rem;width:75px}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__content{flex:1;min-width:0}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__handle,.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__name{line-height:1.2;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__name{font-size:1.25em}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__follow{align-self:center;background-color:var(--wp--preset--color--black);color:var(--wp--preset--color--white)}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__follow:not(:only-child){margin-right:1rem} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/style-view.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/style-view.css deleted file mode 100644 index 1c28cab0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/style-view.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub__modal.components-modal__frame{background-color:#f7f7f7;color:#333}.activitypub__modal.components-modal__frame .components-modal__header-heading,.activitypub__modal.components-modal__frame h4{color:#333;letter-spacing:inherit;word-spacing:inherit}.activitypub__modal.components-modal__frame .components-modal__header .components-button:hover{color:var(--color-white)}.activitypub__dialog{max-width:40em}.activitypub__dialog h4{line-height:1;margin:0}.activitypub__dialog .activitypub-dialog__section{margin-bottom:2em}.activitypub__dialog .activitypub-dialog__remember{margin-top:1em}.activitypub__dialog .activitypub-dialog__description{font-size:var(--wp--preset--font-size--normal,.75rem);margin:.33em 0 1em}.activitypub__dialog .activitypub-dialog__button-group{align-items:flex-end;display:flex;justify-content:flex-end}.activitypub__dialog .activitypub-dialog__button-group svg{height:21px;margin-right:.5em;width:21px}.activitypub__dialog .activitypub-dialog__button-group input{background-color:var(--wp--preset--color--white);border-radius:50px 0 0 50px;border-width:1px;border:1px solid var(--wp--preset--color--black);color:var(--wp--preset--color--black);flex:1;font-size:16px;height:inherit;line-height:1;margin-right:0;padding:15px 23px}.activitypub__dialog .activitypub-dialog__button-group button{align-self:center;background-color:var(--wp--preset--color--black);border-radius:0 50px 50px 0;border-width:1px;color:var(--wp--preset--color--white);font-size:16px;height:inherit;line-height:1;margin-left:0;padding:15px 23px;text-decoration:none}.activitypub__dialog .activitypub-dialog__button-group button:hover{border:inherit}.activitypub-follow-me-block-wrapper{width:100%}.activitypub-follow-me-block-wrapper.has-background .activitypub-profile,.activitypub-follow-me-block-wrapper.has-border-color .activitypub-profile{padding-left:1rem;padding-right:1rem}.activitypub-follow-me-block-wrapper .activitypub-profile{align-items:center;display:flex;padding:1rem 0}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__avatar{border-radius:50%;height:75px;margin-right:1rem;width:75px}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__content{flex:1;min-width:0}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__handle,.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__name{line-height:1.2;margin:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__name{font-size:1.25em}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__follow{align-self:center;background-color:var(--wp--preset--color--black);color:var(--wp--preset--color--white)}.activitypub-follow-me-block-wrapper .activitypub-profile .activitypub-profile__follow:not(:only-child){margin-left:1rem} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/view.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/view.asset.php deleted file mode 100644 index 2f83bf76..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/view.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-dom-ready', 'wp-element', 'wp-i18n', 'wp-primitives'), 'version' => '635ed3e6db3230ae865f'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/view.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/view.js deleted file mode 100644 index fd9c268e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/follow-me/view.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{"use strict";var e,t={5:(e,t,r)=>{var o=r(609);const a=window.wp.element,n=window.wp.domReady;var i=r.n(n);const l=window.wp.apiFetch;var c=r.n(l);const u=window.wp.components,s=window.wp.i18n;function p(e){return`var(--wp--preset--color--${e})`}function m(e){if("string"!=typeof e)return null;if(e.match(/^#/))return e.substring(0,7);const[,,t]=e.split("|");return p(t)}function d(e,t,r=null,o=""){return r?`${e}${o} { ${t}: ${r}; }\n`:""}function v(e,t,r,o){return d(e,"background-color",t)+d(e,"color",r)+d(e,"background-color",o,":hover")+d(e,"background-color",o,":focus")}function f({selector:e,style:t,backgroundColor:r}){const a=function(e,t,r){const o=`${e} .components-button`,a=("string"==typeof(n=r)?p(n):n?.color?.background||null)||t?.color?.background;var n;return v(o,m(t?.elements?.link?.color?.text),a,m(t?.elements?.link?.[":hover"]?.color?.text))}(e,t,r);return(0,o.createElement)("style",null,a)}const b=window.wp.primitives;var y=r(848);const _=(0,y.jsx)(b.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,y.jsx)(b.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5 4.5h11a.5.5 0 0 1 .5.5v11a.5.5 0 0 1-.5.5H5a.5.5 0 0 1-.5-.5V5a.5.5 0 0 1 .5-.5ZM3 5a2 2 0 0 1 2-2h11a2 2 0 0 1 2 2v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5Zm17 3v10.75c0 .69-.56 1.25-1.25 1.25H6v1.5h12.75a2.75 2.75 0 0 0 2.75-2.75V8H20Z"})}),w=(0,y.jsx)(b.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,y.jsx)(b.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})}),h=(0,a.forwardRef)((function({icon:e,size:t=24,...r},o){return(0,a.cloneElement)(e,{width:t,height:t,...r,ref:o})})),g=(0,y.jsx)(b.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,y.jsx)(b.Path,{d:"M15.5 9.5a1 1 0 100-2 1 1 0 000 2zm0 1.5a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm-2.25 6v-2a2.75 2.75 0 00-2.75-2.75h-4A2.75 2.75 0 003.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0120.25 15zM9.5 8.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0z",fillRule:"evenodd"})}),E=window.wp.compose,x="fediverse-remote-user";function S(e){try{return new URL(e),!0}catch(e){return!1}}function k({actionText:e,copyDescription:t,handle:r,resourceUrl:n,myProfile:i="",rememberProfile:l=!1}){const p=(0,s.__)("Loading...","activitypub"),m=(0,s.__)("Opening...","activitypub"),d=(0,s.__)("Error","activitypub"),v=(0,s.__)("Invalid","activitypub"),f=i||(0,s.__)("My Profile","activitypub"),[b,y]=(0,a.useState)(e),[k,O]=(0,a.useState)(_),N=(0,E.useCopyToClipboard)(r,(()=>{O(w),setTimeout((()=>O(_)),1e3)})),[C,R]=(0,a.useState)(""),[I,T]=(0,a.useState)(!0),{setRemoteUser:$}=function(){const[e,t]=(0,a.useState)(function(){const e=localStorage.getItem(x);return e?JSON.parse(e):{}}()),r=(0,a.useCallback)((e=>{!function(e){localStorage.setItem(x,JSON.stringify(e))}(e),t(e)}),[]),o=(0,a.useCallback)((()=>{localStorage.removeItem(x),t({})}),[]);return{template:e?.template||!1,profileURL:e?.profileURL||!1,setRemoteUser:r,deleteRemoteUser:o}}(),z=(0,a.useCallback)((()=>{let t;if(!S(C)&&!function(e){const t=e.replace(/^@/,"").split("@");return 2===t.length&&S(`https://${t[1]}`)}(C))return y(v),t=setTimeout((()=>y(e)),2e3),()=>clearTimeout(t);const r=n+C;y(p),c()({path:r}).then((({url:t,template:r})=>{I&&$({profileURL:C,template:r}),y(m),setTimeout((()=>{window.open(t,"_blank"),y(e)}),200)})).catch((()=>{y(d),setTimeout((()=>y(e)),2e3)}))}),[C]);return(0,o.createElement)("div",{className:"activitypub__dialog",role:"dialog","aria-labelledby":"dialog-title"},(0,o.createElement)("div",{className:"activitypub-dialog__section"},(0,o.createElement)("h4",{id:"dialog-title"},f),(0,o.createElement)("div",{className:"activitypub-dialog__description",id:"copy-description"},t),(0,o.createElement)("div",{className:"activitypub-dialog__button-group"},(0,o.createElement)("label",{htmlFor:"profile-handle",className:"screen-reader-text"},t),(0,o.createElement)("input",{type:"text",id:"profile-handle",value:r,readOnly:!0}),(0,o.createElement)(u.Button,{ref:N,"aria-label":(0,s.__)("Copy handle to clipboard","activitypub")},(0,o.createElement)(h,{icon:k}),(0,s.__)("Copy","activitypub")))),(0,o.createElement)("div",{className:"activitypub-dialog__section"},(0,o.createElement)("h4",{id:"remote-profile-title"},(0,s.__)("Your Profile","activitypub")),(0,o.createElement)("div",{className:"activitypub-dialog__description",id:"remote-profile-description"},(0,a.createInterpolateElement)((0,s.__)("Or, if you know your own profile, we can start things that way! (eg @yourusername@example.com)","activitypub"),{code:(0,o.createElement)("code",null)})),(0,o.createElement)("div",{className:"activitypub-dialog__button-group"},(0,o.createElement)("label",{htmlFor:"remote-profile",className:"screen-reader-text"},(0,s.__)("Enter your ActivityPub profile","activitypub")),(0,o.createElement)("input",{type:"text",id:"remote-profile",value:C,onKeyDown:e=>{"Enter"===e?.code&&z()},onChange:e=>R(e.target.value),"aria-invalid":b===v}),(0,o.createElement)(u.Button,{onClick:z,"aria-label":(0,s.__)("Submit profile","activitypub")},(0,o.createElement)(h,{icon:g}),b)),l&&(0,o.createElement)("div",{className:"activitypub-dialog__remember"},(0,o.createElement)(u.CheckboxControl,{checked:I,label:(0,s.__)("Remember me for easier comments","activitypub"),onChange:()=>{T(!I)}}))))}function O(){return window._activityPubOptions||{}}const N={avatar:"",webfinger:"@well@hello.dolly",name:(0,s.__)("Hello Dolly Fan Account","activitypub"),url:"#"};function C(e){if(!e)return N;const t={...N,...e};return t.avatar=t?.icon?.url,t}function R({profile:e,popupStyles:t,userId:r,buttonText:a,buttonOnly:n,buttonSize:i}){const{webfinger:l,avatar:c,name:u}=e,s=l.startsWith("@")?l:`@${l}`;return n?(0,o.createElement)("div",{className:"activitypub-profile"},(0,o.createElement)(I,{profile:e,popupStyles:t,userId:r,buttonText:a,buttonSize:i})):(0,o.createElement)("div",{className:"activitypub-profile"},(0,o.createElement)("img",{className:"activitypub-profile__avatar",src:c,alt:u}),(0,o.createElement)("div",{className:"activitypub-profile__content"},(0,o.createElement)("div",{className:"activitypub-profile__name"},u),(0,o.createElement)("div",{className:"activitypub-profile__handle",title:s},s)),(0,o.createElement)(I,{profile:e,popupStyles:t,userId:r,buttonText:a,buttonSize:i}))}function I({profile:e,popupStyles:t,userId:r,buttonText:n,buttonSize:i}){const[l,c]=(0,a.useState)(!1),p=(0,s.sprintf)(/* translators: %s: profile name */ /* translators: %s: profile name */ -(0,s.__)("Follow %s","activitypub"),e?.name);return(0,o.createElement)(o.Fragment,null,(0,o.createElement)(u.Button,{className:"activitypub-profile__follow",onClick:()=>c(!0),"aria-haspopup":"dialog","aria-expanded":l,"aria-label":(0,s.__)("Follow me on the Fediverse","activitypub"),size:i},n),l&&(0,o.createElement)(u.Modal,{className:"activitypub-profile__confirm activitypub__modal",onRequestClose:()=>c(!1),title:p,"aria-label":p,role:"dialog"},(0,o.createElement)(T,{profile:e,userId:r}),(0,o.createElement)("style",null,t)))}function T({profile:e,userId:t}){const{namespace:r}=O(),{webfinger:a}=e,n=(0,s.__)("Follow","activitypub"),i=`/${r}/actors/${t}/remote-follow?resource=`,l=(0,s.__)("Copy and paste my profile into the search field of your favorite fediverse app or server.","activitypub"),c=a.startsWith("@")?a:`@${a}`;return(0,o.createElement)(k,{actionText:n,copyDescription:l,handle:c,resourceUrl:i})}function $({selectedUser:e,style:t,backgroundColor:r,id:n,useId:i=!1,profileData:l=!1,buttonOnly:u=!1,buttonText:p=(0,s.__)("Follow","activitypub"),buttonSize:d="default"}){const[b,y]=(0,a.useState)(C()),_="site"===e?0:e,w=function(e){return v(".apfmd__button-group .components-button",m(e?.elements?.link?.color?.text)||"#111","#fff",m(e?.elements?.link?.[":hover"]?.color?.text)||"#333")}(t),h=i?{id:n}:{};return(0,a.useEffect)((()=>{l?y(C(l)):function(e){const{namespace:t}=O(),r={headers:{Accept:"application/activity+json"},path:`/${t}/actors/${e}`};return c()(r)}(_).then((e=>{y(C(e))}))}),[_,l]),(0,o.createElement)("div",{...h,className:"activitypub-follow-me-block-wrapper"},(0,o.createElement)(f,{selector:`#${n}`,style:t,backgroundColor:r}),(0,o.createElement)(R,{profile:b,userId:_,popupStyles:w,buttonText:p,buttonOnly:u,buttonSize:d}))}let z=1;i()((()=>{[].forEach.call(document.querySelectorAll(".activitypub-follow-me-block-wrapper"),(e=>{const t=JSON.parse(e.dataset.attrs);(0,a.createRoot)(e).render((0,o.createElement)($,{...t,id:"activitypub-follow-me-block-"+z++,useId:!0}))}))}))},20:(e,t,r)=>{var o=r(609),a=Symbol.for("react.element"),n=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),i=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,r){var o,c={},u=null,s=null;for(o in void 0!==r&&(u=""+r),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(s=t.ref),t)n.call(t,o)&&!l.hasOwnProperty(o)&&(c[o]=t[o]);if(e&&e.defaultProps)for(o in t=e.defaultProps)void 0===c[o]&&(c[o]=t[o]);return{$$typeof:a,type:e,key:u,ref:s,props:c,_owner:i.current}}},848:(e,t,r)=>{e.exports=r(20)},609:e=>{e.exports=window.React}},r={};function o(e){var a=r[e];if(void 0!==a)return a.exports;var n=r[e]={exports:{}};return t[e](n,n.exports,o),n.exports}o.m=t,e=[],o.O=(t,r,a,n)=>{if(!r){var i=1/0;for(s=0;s=n)&&Object.keys(o.O).every((e=>o.O[e](r[c])))?r.splice(c--,1):(l=!1,n0&&e[s-1][2]>n;s--)e[s]=e[s-1];e[s]=[r,a,n]},o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={41:0,301:0};o.O.j=t=>0===e[t];var t=(t,r)=>{var a,n,i=r[0],l=r[1],c=r[2],u=0;if(i.some((t=>0!==e[t]))){for(a in l)o.o(l,a)&&(o.m[a]=l[a]);if(c)var s=c(o)}for(t&&t(r);uo(5)));a=o.O(a)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/block.json deleted file mode 100644 index 078b82f3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/block.json +++ /dev/null @@ -1,61 +0,0 @@ -{ - "$schema": "https://schemas.wp.org/trunk/block.json", - "name": "activitypub/followers", - "apiVersion": 3, - "version": "1.0.0", - "title": "Fediverse Followers", - "category": "widgets", - "description": "Display your followers from the Fediverse on your website.", - "textdomain": "activitypub", - "icon": "groups", - "supports": { - "html": false - }, - "attributes": { - "title": { - "type": "string", - "default": "Fediverse Followers" - }, - "selectedUser": { - "type": "string", - "default": "site" - }, - "per_page": { - "type": "number", - "default": 10 - }, - "order": { - "type": "string", - "default": "desc", - "enum": [ - "asc", - "desc" - ] - } - }, - "usesContext": [ - "postType", - "postId" - ], - "styles": [ - { - "name": "default", - "label": "No Lines", - "isDefault": true - }, - { - "name": "with-lines", - "label": "Lines" - }, - { - "name": "compact", - "label": "Compact" - } - ], - "editorScript": "file:./index.js", - "viewScript": "file:./view.js", - "style": [ - "file:./style-view.css", - "wp-block-query-pagination" - ] -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/index.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/index.asset.php deleted file mode 100644 index 9b0afcfa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-primitives', 'wp-url'), 'version' => 'e98a40c18060cbb88187'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/index.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/index.js deleted file mode 100644 index 9bec7474..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/index.js +++ /dev/null @@ -1,4 +0,0 @@ -(()=>{var e={20:(e,t,a)=>{"use strict";var r=a(609),n=Symbol.for("react.element"),l=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),o=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,i={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,a){var r,c={},s=null,p=null;for(r in void 0!==a&&(s=""+a),void 0!==t.key&&(s=""+t.key),void 0!==t.ref&&(p=t.ref),t)l.call(t,r)&&!i.hasOwnProperty(r)&&(c[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===c[r]&&(c[r]=t[r]);return{$$typeof:n,type:e,key:s,ref:p,props:c,_owner:o.current}}},848:(e,t,a)=>{"use strict";e.exports=a(20)},609:e=>{"use strict";e.exports=window.React},942:(e,t)=>{var a;!function(){"use strict";var r={}.hasOwnProperty;function n(){for(var e="",t=0;t{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t},a.d=(e,t)=>{for(var r in t)a.o(t,r)&&!a.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.wp.blocks,t=window.wp.primitives;var r=a(848);const n=(0,r.jsx)(t.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(t.Path,{d:"M15.5 9.5a1 1 0 100-2 1 1 0 000 2zm0 1.5a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm-2.25 6v-2a2.75 2.75 0 00-2.75-2.75h-4A2.75 2.75 0 003.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0120.25 15zM9.5 8.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0z",fillRule:"evenodd"})});var l=a(609);const o=window.wp.components,i=window.wp.element,c=window.wp.blockEditor,s=window.wp.data,p=window.wp.coreData,u=window.wp.i18n,m=window.wp.apiFetch;var v=a.n(m);const d=window.wp.url;var w=a(942),b=a.n(w);function f({active:e,children:t,page:a,pageClick:r,className:n}){const o=b()("wp-block activitypub-pager",n,{current:e});return(0,l.createElement)("a",{className:o,onClick:t=>{t.preventDefault(),!e&&r(a)}},t)}function y({compact:e,nextLabel:t,page:a,pageClick:r,perPage:n,prevLabel:o,total:i,variant:c="outlined"}){const s=((e,t)=>{let a=[1,e-2,e-1,e,e+1,e+2,t];a.sort(((e,t)=>e-t)),a=a.filter(((e,a,r)=>e>=1&&e<=t&&r.lastIndexOf(e)===a));for(let e=a.length-2;e>=0;e--)a[e]===a[e+1]&&a.splice(e+1,1);return a})(a,Math.ceil(i/n)),p=b()("alignwide wp-block-query-pagination is-content-justification-space-between is-layout-flex wp-block-query-pagination-is-layout-flex",`is-${c}`,{"is-compact":e});return(0,l.createElement)("nav",{className:p},o&&(0,l.createElement)(f,{key:"prev",page:a-1,pageClick:r,active:1===a,"aria-label":o,className:"wp-block-query-pagination-previous block-editor-block-list__block"},o),!e&&(0,l.createElement)("div",{className:"block-editor-block-list__block wp-block wp-block-query-pagination-numbers"},s.map((e=>(0,l.createElement)(f,{key:e,page:e,pageClick:r,active:e===a,className:"page-numbers"},e)))),t&&(0,l.createElement)(f,{key:"next",page:a+1,pageClick:r,active:a===Math.ceil(i/n),"aria-label":t,className:"wp-block-query-pagination-next block-editor-block-list__block"},t))}function g(){return window._activityPubOptions||{}}function h({selectedUser:e,per_page:t,order:a,title:r,page:n,setPage:o,className:c="",followLinks:s=!0,followerData:p=!1}){const m="site"===e?0:e,[w,b]=(0,l.useState)([]),[f,h]=(0,l.useState)(0),[k,E]=(0,l.useState)(0),[x,S]=function(){const[e,t]=(0,l.useState)(1);return[e,t]}(),N=n||x,C=o||S,O=(0,i.createInterpolateElement)(/* translators: arrow for previous followers link */ /* translators: arrow for previous followers link */ -(0,u.__)(" Less","activitypub"),{span:(0,l.createElement)("span",{className:"wp-block-query-pagination-previous-arrow is-arrow-arrow","aria-hidden":"true"})}),P=(0,i.createInterpolateElement)(/* translators: arrow for next followers link */ /* translators: arrow for next followers link */ -(0,u.__)("More ","activitypub"),{span:(0,l.createElement)("span",{className:"wp-block-query-pagination-next-arrow is-arrow-arrow","aria-hidden":"true"})}),I=(e,a)=>{b(e),E(a),h(Math.ceil(a/t))};return(0,l.useEffect)((()=>{if(p&&1===N)return I(p.followers,p.total);const e=function(e,t,a,r){const{namespace:n}=g(),l=`/${n}/actors/${e}/followers`,o={per_page:t,order:a,page:r,context:"full"};return(0,d.addQueryArgs)(l,o)}(m,t,a,N);v()({path:e}).then((e=>I(e.orderedItems,e.totalItems))).catch((()=>{}))}),[m,t,a,N,p]),(0,l.createElement)("div",{className:"activitypub-follower-block "+c},(0,l.createElement)("h3",null,r),(0,l.createElement)("ul",null,w&&w.map((e=>(0,l.createElement)("li",{key:e.url},(0,l.createElement)(_,{...e,followLinks:s}))))),f>1&&(0,l.createElement)(y,{page:N,perPage:t,total:k,pageClick:C,nextLabel:P,prevLabel:O,compact:"is-style-compact"===c}))}function _({name:e,icon:t,url:a,preferredUsername:r,followLinks:n=!0}){const i=`@${r}`,c={};return n||(c.onClick=e=>e.preventDefault()),(0,l.createElement)(o.ExternalLink,{className:"activitypub-link",href:a,title:i,...c},(0,l.createElement)("img",{width:"40",height:"40",src:t.url,className:"avatar activitypub-avatar",alt:e}),(0,l.createElement)("span",{className:"activitypub-actor"},(0,l.createElement)("strong",{className:"activitypub-name"},e),(0,l.createElement)("span",{className:"sep"},"/"),(0,l.createElement)("span",{className:"activitypub-handle"},i)))}function k({name:e}){const{enabled:t}=g(),a=t?.site?"":(0,u.__)("It will be empty in other non-author contexts.","activitypub"),r=(0,u.sprintf)(/* translators: %1$s: block name, %2$s: extra information for non-author context */ /* translators: %1$s: block name, %2$s: extra information for non-author context */ -(0,u.__)("This %1$s block will adapt to the page it is on, displaying the user profile associated with a post author (in a loop) or a user archive. %2$s","activitypub"),e,a).trim();return(0,l.createElement)(o.Card,null,(0,l.createElement)(o.CardBody,null,(0,i.createInterpolateElement)(r,{strong:(0,l.createElement)("strong",null)})))}(0,e.registerBlockType)("activitypub/followers",{edit:function({attributes:e,setAttributes:t,context:{postType:a,postId:r}}){const{order:n,per_page:m,selectedUser:v,title:d}=e,w=(0,c.useBlockProps)(),[b,f]=(0,i.useState)(1),y=[{label:(0,u.__)("New to old","activitypub"),value:"desc"},{label:(0,u.__)("Old to new","activitypub"),value:"asc"}],_=function({withInherit:e=!1}){const{enabled:t}=g(),a=t?.users?(0,s.useSelect)((e=>e("core").getUsers({who:"authors"}))):[];return(0,i.useMemo)((()=>{if(!a)return[];const r=[];return t?.site&&r.push({label:(0,u.__)("Site","activitypub"),value:"site"}),e&&t?.users&&r.push({label:(0,u.__)("Dynamic User","activitypub"),value:"inherit"}),a.reduce(((e,t)=>(e.push({label:t.name,value:`${t.id}`}),e)),r)}),[a])}({withInherit:!0}),E=e=>a=>{f(1),t({[e]:a})},x=(0,s.useSelect)((e=>{const{getEditedEntityRecord:t}=e(p.store),n=t("postType",a,r)?.author;return null!=n?n:null}),[a,r]);return(0,i.useEffect)((()=>{_.length&&(_.find((({value:e})=>e===v))||t({selectedUser:_[0].value}))}),[v,_]),(0,l.createElement)("div",{...w},(0,l.createElement)(c.InspectorControls,{key:"setting"},(0,l.createElement)(o.PanelBody,{title:(0,u.__)("Followers Options","activitypub")},(0,l.createElement)(o.TextControl,{label:(0,u.__)("Title","activitypub"),help:(0,u.__)("Title to display above the list of followers. Blank for none.","activitypub"),value:d,onChange:e=>t({title:e})}),_.length>1&&(0,l.createElement)(o.SelectControl,{label:(0,u.__)("Select User","activitypub"),value:v,options:_,onChange:E("selectedUser")}),(0,l.createElement)(o.SelectControl,{label:(0,u.__)("Sort","activitypub"),value:n,options:y,onChange:E("order")}),(0,l.createElement)(o.RangeControl,{label:(0,u.__)("Number of Followers","activitypub"),value:m,onChange:E("per_page"),min:1,max:10}))),"inherit"===v?x?(0,l.createElement)(h,{...e,page:b,setPage:f,followLinks:!1,selectedUser:x}):(0,l.createElement)(k,{name:(0,u.__)("Followers","activitypub")}):(0,l.createElement)(h,{...e,page:b,setPage:f,followLinks:!1}))},save:()=>null,icon:n})})()})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/style-view-rtl.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/style-view-rtl.css deleted file mode 100644 index d6e565ff..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/style-view-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-follower-block.is-style-compact .activitypub-handle,.activitypub-follower-block.is-style-compact .sep{display:none}.activitypub-follower-block.is-style-with-lines ul li{border-bottom:.5px solid;margin-bottom:.5rem;padding-bottom:.5rem}.activitypub-follower-block.is-style-with-lines ul li:last-child{border-bottom:none}.activitypub-follower-block.is-style-with-lines .activitypub-handle,.activitypub-follower-block.is-style-with-lines .activitypub-name{text-decoration:none}.activitypub-follower-block.is-style-with-lines .activitypub-handle:hover,.activitypub-follower-block.is-style-with-lines .activitypub-name:hover{text-decoration:underline}.activitypub-follower-block ul{margin:0!important;padding:0!important}.activitypub-follower-block li{display:flex;margin-bottom:1rem}.activitypub-follower-block img{border-radius:50%;height:40px;margin-left:var(--wp--preset--spacing--20,.5rem);width:40px}.activitypub-follower-block .activitypub-link{align-items:center;color:inherit!important;display:flex;flex-flow:row nowrap;max-width:100%;text-decoration:none!important}.activitypub-follower-block .activitypub-handle,.activitypub-follower-block .activitypub-name{text-decoration:underline;text-decoration-thickness:.8px;text-underline-position:under}.activitypub-follower-block .activitypub-handle:hover,.activitypub-follower-block .activitypub-name:hover{text-decoration:none}.activitypub-follower-block .activitypub-name{font-size:var(--wp--preset--font-size--normal,16px)}.activitypub-follower-block .activitypub-actor{font-size:var(--wp--preset--font-size--small,13px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.activitypub-follower-block .sep{padding:0 .2rem}.activitypub-follower-block .wp-block-query-pagination{margin-top:1.5rem}.activitypub-follower-block .activitypub-pager{cursor:default}.activitypub-follower-block .activitypub-pager.current{opacity:.33}.activitypub-follower-block .page-numbers{padding:0 .2rem}.activitypub-follower-block .page-numbers.current{font-weight:700;opacity:1} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/style-view.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/style-view.css deleted file mode 100644 index 824879e9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/style-view.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-follower-block.is-style-compact .activitypub-handle,.activitypub-follower-block.is-style-compact .sep{display:none}.activitypub-follower-block.is-style-with-lines ul li{border-bottom:.5px solid;margin-bottom:.5rem;padding-bottom:.5rem}.activitypub-follower-block.is-style-with-lines ul li:last-child{border-bottom:none}.activitypub-follower-block.is-style-with-lines .activitypub-handle,.activitypub-follower-block.is-style-with-lines .activitypub-name{text-decoration:none}.activitypub-follower-block.is-style-with-lines .activitypub-handle:hover,.activitypub-follower-block.is-style-with-lines .activitypub-name:hover{text-decoration:underline}.activitypub-follower-block ul{margin:0!important;padding:0!important}.activitypub-follower-block li{display:flex;margin-bottom:1rem}.activitypub-follower-block img{border-radius:50%;height:40px;margin-right:var(--wp--preset--spacing--20,.5rem);width:40px}.activitypub-follower-block .activitypub-link{align-items:center;color:inherit!important;display:flex;flex-flow:row nowrap;max-width:100%;text-decoration:none!important}.activitypub-follower-block .activitypub-handle,.activitypub-follower-block .activitypub-name{text-decoration:underline;text-decoration-thickness:.8px;text-underline-position:under}.activitypub-follower-block .activitypub-handle:hover,.activitypub-follower-block .activitypub-name:hover{text-decoration:none}.activitypub-follower-block .activitypub-name{font-size:var(--wp--preset--font-size--normal,16px)}.activitypub-follower-block .activitypub-actor{font-size:var(--wp--preset--font-size--small,13px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.activitypub-follower-block .sep{padding:0 .2rem}.activitypub-follower-block .wp-block-query-pagination{margin-top:1.5rem}.activitypub-follower-block .activitypub-pager{cursor:default}.activitypub-follower-block .activitypub-pager.current{opacity:.33}.activitypub-follower-block .page-numbers{padding:0 .2rem}.activitypub-follower-block .page-numbers.current{font-weight:700;opacity:1} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/view.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/view.asset.php deleted file mode 100644 index 88e18217..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/view.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-dom-ready', 'wp-element', 'wp-i18n', 'wp-url'), 'version' => '34299fc181d49292ada0'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/view.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/view.js deleted file mode 100644 index 227bb012..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/followers/view.js +++ /dev/null @@ -1,3 +0,0 @@ -(()=>{var e,t={73:(e,t,a)=>{"use strict";const r=window.React,n=window.wp.apiFetch;var l=a.n(n);const o=window.wp.url,c=window.wp.element,i=window.wp.i18n;var s=a(942),p=a.n(s);function u({active:e,children:t,page:a,pageClick:n,className:l}){const o=p()("wp-block activitypub-pager",l,{current:e});return(0,r.createElement)("a",{className:o,onClick:t=>{t.preventDefault(),!e&&n(a)}},t)}function m({compact:e,nextLabel:t,page:a,pageClick:n,perPage:l,prevLabel:o,total:c,variant:i="outlined"}){const s=((e,t)=>{let a=[1,e-2,e-1,e,e+1,e+2,t];a.sort(((e,t)=>e-t)),a=a.filter(((e,a,r)=>e>=1&&e<=t&&r.lastIndexOf(e)===a));for(let e=a.length-2;e>=0;e--)a[e]===a[e+1]&&a.splice(e+1,1);return a})(a,Math.ceil(c/l)),m=p()("alignwide wp-block-query-pagination is-content-justification-space-between is-layout-flex wp-block-query-pagination-is-layout-flex",`is-${i}`,{"is-compact":e});return(0,r.createElement)("nav",{className:m},o&&(0,r.createElement)(u,{key:"prev",page:a-1,pageClick:n,active:1===a,"aria-label":o,className:"wp-block-query-pagination-previous block-editor-block-list__block"},o),!e&&(0,r.createElement)("div",{className:"block-editor-block-list__block wp-block wp-block-query-pagination-numbers"},s.map((e=>(0,r.createElement)(u,{key:e,page:e,pageClick:n,active:e===a,className:"page-numbers"},e)))),t&&(0,r.createElement)(u,{key:"next",page:a+1,pageClick:n,active:a===Math.ceil(c/l),"aria-label":t,className:"wp-block-query-pagination-next block-editor-block-list__block"},t))}const f=window.wp.components;function v({selectedUser:e,per_page:t,order:a,title:n,page:s,setPage:p,className:u="",followLinks:f=!0,followerData:v=!1}){const w="site"===e?0:e,[d,g]=(0,r.useState)([]),[y,k]=(0,r.useState)(0),[h,E]=(0,r.useState)(0),[N,x]=function(){const[e,t]=(0,r.useState)(1);return[e,t]}(),_=s||N,O=p||x,S=(0,c.createInterpolateElement)(/* translators: arrow for previous followers link */ /* translators: arrow for previous followers link */ -(0,i.__)(" Less","activitypub"),{span:(0,r.createElement)("span",{className:"wp-block-query-pagination-previous-arrow is-arrow-arrow","aria-hidden":"true"})}),C=(0,c.createInterpolateElement)(/* translators: arrow for next followers link */ /* translators: arrow for next followers link */ -(0,i.__)("More ","activitypub"),{span:(0,r.createElement)("span",{className:"wp-block-query-pagination-next-arrow is-arrow-arrow","aria-hidden":"true"})}),L=(e,a)=>{g(e),E(a),k(Math.ceil(a/t))};return(0,r.useEffect)((()=>{if(v&&1===_)return L(v.followers,v.total);const e=function(e,t,a,r){const{namespace:n}=window._activityPubOptions||{},l=`/${n}/actors/${e}/followers`,c={per_page:t,order:a,page:r,context:"full"};return(0,o.addQueryArgs)(l,c)}(w,t,a,_);l()({path:e}).then((e=>L(e.orderedItems,e.totalItems))).catch((()=>{}))}),[w,t,a,_,v]),(0,r.createElement)("div",{className:"activitypub-follower-block "+u},(0,r.createElement)("h3",null,n),(0,r.createElement)("ul",null,d&&d.map((e=>(0,r.createElement)("li",{key:e.url},(0,r.createElement)(b,{...e,followLinks:f}))))),y>1&&(0,r.createElement)(m,{page:_,perPage:t,total:h,pageClick:O,nextLabel:C,prevLabel:S,compact:"is-style-compact"===u}))}function b({name:e,icon:t,url:a,preferredUsername:n,followLinks:l=!0}){const o=`@${n}`,c={};return l||(c.onClick=e=>e.preventDefault()),(0,r.createElement)(f.ExternalLink,{className:"activitypub-link",href:a,title:o,...c},(0,r.createElement)("img",{width:"40",height:"40",src:t.url,className:"avatar activitypub-avatar",alt:e}),(0,r.createElement)("span",{className:"activitypub-actor"},(0,r.createElement)("strong",{className:"activitypub-name"},e),(0,r.createElement)("span",{className:"sep"},"/"),(0,r.createElement)("span",{className:"activitypub-handle"},o)))}const w=window.wp.domReady;a.n(w)()((()=>{[].forEach.call(document.querySelectorAll(".activitypub-follower-block"),(e=>{const t=JSON.parse(e.dataset.attrs);(0,c.createRoot)(e).render((0,r.createElement)(v,{...t}))}))}))},942:(e,t)=>{var a;!function(){"use strict";var r={}.hasOwnProperty;function n(){for(var e="",t=0;t{if(!a){var o=1/0;for(p=0;p=l)&&Object.keys(r.O).every((e=>r.O[e](a[i])))?a.splice(i--,1):(c=!1,l0&&e[p-1][2]>l;p--)e[p]=e[p-1];e[p]=[a,n,l]},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var a in t)r.o(t,a)&&!r.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={996:0,528:0};r.O.j=t=>0===e[t];var t=(t,a)=>{var n,l,o=a[0],c=a[1],i=a[2],s=0;if(o.some((t=>0!==e[t]))){for(n in c)r.o(c,n)&&(r.m[n]=c[n]);if(i)var p=i(r)}for(t&&t(a);sr(73)));n=r.O(n)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/block.json deleted file mode 100644 index e489c0f8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/block.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "$schema": "https://schemas.wp.org/trunk/block.json", - "name": "activitypub/reactions", - "apiVersion": 2, - "version": "1.0.0", - "title": "Fediverse Reactions", - "category": "widgets", - "icon": "heart", - "description": "Display Fediverse likes and reposts", - "supports": { - "html": false, - "align": true, - "layout": { - "default": { - "type": "constrained", - "orientation": "vertical", - "justifyContent": "center" - } - } - }, - "attributes": { - "title": { - "type": "string", - "default": "Fediverse reactions" - } - }, - "blockHooks": { - "core/post-content": "after" - }, - "textdomain": "activitypub", - "editorScript": "file:./index.js", - "style": [ - "file:./style-index.css", - "wp-components" - ], - "viewScript": "file:./view.js" -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/index.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/index.asset.php deleted file mode 100644 index 6ac7d749..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-element', 'wp-i18n'), 'version' => '32631215c76c36b38e5e'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/index.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/index.js deleted file mode 100644 index 7ab57c58..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/index.js +++ /dev/null @@ -1,3 +0,0 @@ -(()=>{"use strict";var e,t={373:(e,t,a)=>{const n=window.wp.blocks,r=window.React,l=window.wp.blockEditor,o=window.wp.element,s=window.wp.i18n,i=window.wp.components,c=window.wp.apiFetch;var u=a.n(c);function m(){return window._activityPubOptions||{}}const p=({reactions:e})=>{const{defaultAvatarUrl:t}=m(),[a,n]=(0,o.useState)(new Set),[l,s]=(0,o.useState)(new Map),i=(0,o.useRef)([]),c=()=>{i.current.forEach((e=>clearTimeout(e))),i.current=[]},u=(t,a)=>{c();const r=100,l=e.length;a&&s((e=>{const a=new Map(e);return a.set(t,"clockwise"),a}));const o=e=>{const o="right"===e,c=o?l-1:0,u=o?1:-1;for(let e=o?t:t-1;o?e<=c:e>=c;e+=u){const l=Math.abs(e-t),o=setTimeout((()=>{n((t=>{const n=new Set(t);return a?n.add(e):n.delete(e),n})),a&&e!==t&&s((t=>{const a=new Map(t),n=e-u,r=a.get(n);return a.set(e,"clockwise"===r?"counter":"clockwise"),a}))}),l*r);i.current.push(o)}};if(o("right"),o("left"),!a){const e=Math.max((l-t)*r,t*r),a=setTimeout((()=>{s(new Map)}),e+r);i.current.push(a)}};return(0,o.useEffect)((()=>()=>c()),[]),(0,r.createElement)("ul",{className:"reaction-avatars"},e.map(((e,n)=>{const o=l.get(n),s=["reaction-avatar",a.has(n)?"wave-active":"",o?`rotate-${o}`:""].filter(Boolean).join(" "),i=e.avatar||t;return(0,r.createElement)("li",{key:n},(0,r.createElement)("a",{href:e.url,target:"_blank",rel:"noopener noreferrer",onMouseEnter:()=>u(n,!0),onMouseLeave:()=>u(n,!1)},(0,r.createElement)("img",{src:i,alt:e.name,className:s,width:"32",height:"32"})))})))},f=({reactions:e,type:t})=>(0,r.createElement)("ul",{className:"activitypub-reaction-list"},e.map(((e,t)=>(0,r.createElement)("li",{key:t},(0,r.createElement)("a",{href:e.url,className:"reaction-item",target:"_blank",rel:"noopener noreferrer"},(0,r.createElement)("img",{src:e.avatar,alt:e.name,width:"32",height:"32"}),(0,r.createElement)("span",null,e.name)))))),h=({items:e,label:t})=>{const[a,n]=(0,o.useState)(!1),[l,s]=(0,o.useState)(null),[c,u]=(0,o.useState)(e.length),m=(0,o.useRef)(null);(0,o.useEffect)((()=>{if(!m.current)return;const t=()=>{const t=m.current;if(!t)return;const a=t.offsetWidth-(l?.offsetWidth||0)-12,n=Math.max(1,Math.floor((a-32)/22));u(Math.min(n,e.length))};t();const a=new ResizeObserver(t);return a.observe(m.current),()=>{a.disconnect()}}),[l,e.length]);const h=e.slice(0,c);return(0,r.createElement)("div",{className:"reaction-group",ref:m},(0,r.createElement)(p,{reactions:h}),(0,r.createElement)(i.Button,{ref:s,className:"reaction-label is-link",onClick:()=>n(!a),"aria-expanded":a},t),a&&l&&(0,r.createElement)(i.Popover,{anchor:l,onClose:()=>n(!1)},(0,r.createElement)(f,{reactions:e})))};function d({title:e="",postId:t=null,reactions:a=null,titleComponent:n=null}){const{namespace:l}=m(),[s,i]=(0,o.useState)(a),[c,p]=(0,o.useState)(!a);return(0,o.useEffect)((()=>{if(a)return i(a),void p(!1);t?(p(!0),u()({path:`/${l}/posts/${t}/reactions`}).then((e=>{i(e),p(!1)})).catch((()=>p(!1)))):p(!1)}),[t,a]),c?null:s&&Object.values(s).some((e=>e.items?.length>0))?(0,r.createElement)("div",{className:"activitypub-reactions"},n||e&&(0,r.createElement)("h6",null,e),Object.entries(s).map((([e,t])=>t.items?.length?(0,r.createElement)(h,{key:e,items:t.items,label:t.label}):null))):null}const v=e=>{const t=["#FF6B6B","#4ECDC4","#45B7D1","#96CEB4","#FFEEAD","#D4A5A5","#9B59B6","#3498DB","#E67E22"],a=(()=>{const e=["Bouncy","Cosmic","Dancing","Fluffy","Giggly","Hoppy","Jazzy","Magical","Nifty","Perky","Quirky","Sparkly","Twirly","Wiggly","Zippy"],t=["Badger","Capybara","Dolphin","Echidna","Flamingo","Giraffe","Hedgehog","Iguana","Jellyfish","Koala","Lemur","Manatee","Narwhal","Octopus","Penguin"];return`${e[Math.floor(Math.random()*e.length)]} ${t[Math.floor(Math.random()*t.length)]}`})(),n=t[Math.floor(Math.random()*t.length)],r=a.charAt(0),l=document.createElement("canvas");l.width=64,l.height=64;const o=l.getContext("2d");return o.fillStyle=n,o.beginPath(),o.arc(32,32,32,0,2*Math.PI),o.fill(),o.fillStyle="#FFFFFF",o.font="32px sans-serif",o.textAlign="center",o.textBaseline="middle",o.fillText(r,32,32),{name:a,url:"#",avatar:l.toDataURL()}},g=JSON.parse('{"UU":"activitypub/reactions"}');(0,n.registerBlockType)(g.UU,{edit:function({attributes:e,setAttributes:t,__unstableLayoutClassNames:a}){const n=(0,l.useBlockProps)({className:a}),[i]=(0,o.useState)({likes:{label:(0,s.sprintf)(/* translators: %d: Number of likes */ /* translators: %d: Number of likes */ -(0,s._x)("%d likes","number of likes","activitypub"),9),items:Array.from({length:9},((e,t)=>v()))},reposts:{label:(0,s.sprintf)(/* translators: %d: Number of reposts */ /* translators: %d: Number of reposts */ -(0,s._x)("%d reposts","number of reposts","activitypub"),6),items:Array.from({length:6},((e,t)=>v()))}}),c=(0,r.createElement)(l.RichText,{tagName:"h6",value:e.title,onChange:e=>t({title:e}),placeholder:(0,s.__)("Fediverse Reactions","activitypub"),disableLineBreaks:!0,allowedFormats:[]});return(0,r.createElement)("div",{...n},(0,r.createElement)(d,{titleComponent:c,reactions:i}))}})}},a={};function n(e){var r=a[e];if(void 0!==r)return r.exports;var l=a[e]={exports:{}};return t[e](l,l.exports,n),l.exports}n.m=t,e=[],n.O=(t,a,r,l)=>{if(!a){var o=1/0;for(u=0;u=l)&&Object.keys(n.O).every((e=>n.O[e](a[i])))?a.splice(i--,1):(s=!1,l0&&e[u-1][2]>l;u--)e[u]=e[u-1];e[u]=[a,r,l]},n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={608:0,104:0};n.O.j=t=>0===e[t];var t=(t,a)=>{var r,l,o=a[0],s=a[1],i=a[2],c=0;if(o.some((t=>0!==e[t]))){for(r in s)n.o(s,r)&&(n.m[r]=s[r]);if(i)var u=i(n)}for(t&&t(a);cn(373)));r=n.O(r)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/style-index-rtl.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/style-index-rtl.css deleted file mode 100644 index 593e3174..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/style-index-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-reactions h6{border-top:1px solid;border-top-color:var(--wp--preset--color--contrast-2);display:inline-block;padding-top:.5em}.activitypub-reactions .reaction-group{align-items:center;display:flex;gap:.75em;justify-content:flex-start;margin:.5em 0;position:relative;width:100%}@media(max-width:782px){.activitypub-reactions .reaction-group:has(.reaction-avatars:not(:empty)){justify-content:space-between}}.activitypub-reactions .reaction-avatars{align-items:center;display:flex;flex-direction:row;list-style:none;margin:0;padding:0}.activitypub-reactions .reaction-avatars li{margin:0 0 0 -10px;padding:0}.activitypub-reactions .reaction-avatars li:last-child{margin-left:0}.activitypub-reactions .reaction-avatars li a{display:block;text-decoration:none}.activitypub-reactions .reaction-avatars .reaction-avatar{border:.5px solid var(--wp--preset--color--contrast,hsla(0,0%,100%,.8));border-radius:50%;box-shadow:0 0 0 .5px hsla(0,0%,100%,.8),0 1px 3px rgba(0,0,0,.2);height:32px;transition:transform .6s cubic-bezier(.34,1.56,.64,1);width:32px;will-change:transform}.activitypub-reactions .reaction-avatars .reaction-avatar.wave-active{transform:translateY(-5px)}.activitypub-reactions .reaction-avatars .reaction-avatar.wave-active.rotate-clockwise{transform:translateY(-5px) rotate(-30deg)}.activitypub-reactions .reaction-avatars .reaction-avatar.wave-active.rotate-counter{transform:translateY(-5px) rotate(30deg)}.activitypub-reactions .reaction-avatars .reaction-avatar:hover{position:relative;z-index:1}.activitypub-reactions .reaction-label.components-button{color:var(--wp--preset--color--contrast,--wp--preset--color--secondary,#2271b1);flex:0 0 auto;height:auto;padding:0;text-decoration:none;white-space:nowrap}.activitypub-reactions .reaction-label.components-button:hover{color:var(--wp--preset--color--contrast,--wp--preset--color--secondary,#135e96);text-decoration:underline}.activitypub-reactions .reaction-label.components-button:focus:not(:disabled){box-shadow:none;outline:1px solid var(--wp--preset--color--contrast,#135e96);outline-offset:2px}.activitypub-reaction-list{background-color:var(--wp--preset--color--background,var(--wp--preset--color--custom-background,var(--wp--preset--color--base)));list-style:none;margin:0;max-width:300px;padding:.25em .7em .25em 1.3em;width:-moz-max-content;width:max-content}.activitypub-reaction-list ul{margin:0;padding:0}.activitypub-reaction-list li{font-size:var(--wp--preset--font-size--small);margin:0;padding:0}.activitypub-reaction-list a{align-items:center;color:var(--wp--preset--color--contrast,var(--wp--preset--color--secondary));display:flex;font-size:var(--wp--preset--font-size--small,.75rem);gap:.5em;justify-content:flex-start;padding:.5em;text-decoration:none}.activitypub-reaction-list a:hover{text-decoration:underline}.activitypub-reaction-list a img{border-radius:50%;flex:none;height:24px;width:24px} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/style-index.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/style-index.css deleted file mode 100644 index 769742af..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/style-index.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-reactions h6{border-top:1px solid;border-top-color:var(--wp--preset--color--contrast-2);display:inline-block;padding-top:.5em}.activitypub-reactions .reaction-group{align-items:center;display:flex;gap:.75em;justify-content:flex-start;margin:.5em 0;position:relative;width:100%}@media(max-width:782px){.activitypub-reactions .reaction-group:has(.reaction-avatars:not(:empty)){justify-content:space-between}}.activitypub-reactions .reaction-avatars{align-items:center;display:flex;flex-direction:row;list-style:none;margin:0;padding:0}.activitypub-reactions .reaction-avatars li{margin:0 -10px 0 0;padding:0}.activitypub-reactions .reaction-avatars li:last-child{margin-right:0}.activitypub-reactions .reaction-avatars li a{display:block;text-decoration:none}.activitypub-reactions .reaction-avatars .reaction-avatar{border:.5px solid var(--wp--preset--color--contrast,hsla(0,0%,100%,.8));border-radius:50%;box-shadow:0 0 0 .5px hsla(0,0%,100%,.8),0 1px 3px rgba(0,0,0,.2);height:32px;transition:transform .6s cubic-bezier(.34,1.56,.64,1);width:32px;will-change:transform}.activitypub-reactions .reaction-avatars .reaction-avatar.wave-active{transform:translateY(-5px)}.activitypub-reactions .reaction-avatars .reaction-avatar.wave-active.rotate-clockwise{transform:translateY(-5px) rotate(30deg)}.activitypub-reactions .reaction-avatars .reaction-avatar.wave-active.rotate-counter{transform:translateY(-5px) rotate(-30deg)}.activitypub-reactions .reaction-avatars .reaction-avatar:hover{position:relative;z-index:1}.activitypub-reactions .reaction-label.components-button{color:var(--wp--preset--color--contrast,--wp--preset--color--secondary,#2271b1);flex:0 0 auto;height:auto;padding:0;text-decoration:none;white-space:nowrap}.activitypub-reactions .reaction-label.components-button:hover{color:var(--wp--preset--color--contrast,--wp--preset--color--secondary,#135e96);text-decoration:underline}.activitypub-reactions .reaction-label.components-button:focus:not(:disabled){box-shadow:none;outline:1px solid var(--wp--preset--color--contrast,#135e96);outline-offset:2px}.activitypub-reaction-list{background-color:var(--wp--preset--color--background,var(--wp--preset--color--custom-background,var(--wp--preset--color--base)));list-style:none;margin:0;max-width:300px;padding:.25em 1.3em .25em .7em;width:-moz-max-content;width:max-content}.activitypub-reaction-list ul{margin:0;padding:0}.activitypub-reaction-list li{font-size:var(--wp--preset--font-size--small);margin:0;padding:0}.activitypub-reaction-list a{align-items:center;color:var(--wp--preset--color--contrast,var(--wp--preset--color--secondary));display:flex;font-size:var(--wp--preset--font-size--small,.75rem);gap:.5em;justify-content:flex-start;padding:.5em;text-decoration:none}.activitypub-reaction-list a:hover{text-decoration:underline}.activitypub-reaction-list a img{border-radius:50%;flex:none;height:24px;width:24px} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/view.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/view.asset.php deleted file mode 100644 index 814279a1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/view.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-dom-ready', 'wp-element', 'wp-i18n'), 'version' => 'd5cb95d9bd6062974b3c'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/view.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/view.js deleted file mode 100644 index 4e4ff64e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reactions/view.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";var e={n:t=>{var n=t&&t.__esModule?()=>t.default:()=>t;return e.d(n,{a:n}),n},d:(t,n)=>{for(var a in n)e.o(n,a)&&!e.o(t,a)&&Object.defineProperty(t,a,{enumerable:!0,get:n[a]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t)};const t=window.React,n=window.wp.element,a=window.wp.domReady;var r=e.n(a);const c=window.wp.components,o=window.wp.apiFetch;var l=e.n(o);function s(){return window._activityPubOptions||{}}window.wp.i18n;const i=({reactions:e})=>{const{defaultAvatarUrl:a}=s(),[r,c]=(0,n.useState)(new Set),[o,l]=(0,n.useState)(new Map),i=(0,n.useRef)([]),u=()=>{i.current.forEach((e=>clearTimeout(e))),i.current=[]},m=(t,n)=>{u();const a=100,r=e.length;n&&l((e=>{const n=new Map(e);return n.set(t,"clockwise"),n}));const o=e=>{const o="right"===e,s=o?r-1:0,u=o?1:-1;for(let e=o?t:t-1;o?e<=s:e>=s;e+=u){const r=Math.abs(e-t),o=setTimeout((()=>{c((t=>{const a=new Set(t);return n?a.add(e):a.delete(e),a})),n&&e!==t&&l((t=>{const n=new Map(t),a=e-u,r=n.get(a);return n.set(e,"clockwise"===r?"counter":"clockwise"),n}))}),r*a);i.current.push(o)}};if(o("right"),o("left"),!n){const e=Math.max((r-t)*a,t*a),n=setTimeout((()=>{l(new Map)}),e+a);i.current.push(n)}};return(0,n.useEffect)((()=>()=>u()),[]),(0,t.createElement)("ul",{className:"reaction-avatars"},e.map(((e,n)=>{const c=o.get(n),l=["reaction-avatar",r.has(n)?"wave-active":"",c?`rotate-${c}`:""].filter(Boolean).join(" "),s=e.avatar||a;return(0,t.createElement)("li",{key:n},(0,t.createElement)("a",{href:e.url,target:"_blank",rel:"noopener noreferrer",onMouseEnter:()=>m(n,!0),onMouseLeave:()=>m(n,!1)},(0,t.createElement)("img",{src:s,alt:e.name,className:l,width:"32",height:"32"})))})))},u=({reactions:e,type:n})=>(0,t.createElement)("ul",{className:"activitypub-reaction-list"},e.map(((e,n)=>(0,t.createElement)("li",{key:n},(0,t.createElement)("a",{href:e.url,className:"reaction-item",target:"_blank",rel:"noopener noreferrer"},(0,t.createElement)("img",{src:e.avatar,alt:e.name,width:"32",height:"32"}),(0,t.createElement)("span",null,e.name)))))),m=({items:e,label:a})=>{const[r,o]=(0,n.useState)(!1),[l,s]=(0,n.useState)(null),[m,p]=(0,n.useState)(e.length),h=(0,n.useRef)(null);(0,n.useEffect)((()=>{if(!h.current)return;const t=()=>{const t=h.current;if(!t)return;const n=t.offsetWidth-(l?.offsetWidth||0)-12,a=Math.max(1,Math.floor((n-32)/22));p(Math.min(a,e.length))};t();const n=new ResizeObserver(t);return n.observe(h.current),()=>{n.disconnect()}}),[l,e.length]);const f=e.slice(0,m);return(0,t.createElement)("div",{className:"reaction-group",ref:h},(0,t.createElement)(i,{reactions:f}),(0,t.createElement)(c.Button,{ref:s,className:"reaction-label is-link",onClick:()=>o(!r),"aria-expanded":r},a),r&&l&&(0,t.createElement)(c.Popover,{anchor:l,onClose:()=>o(!1)},(0,t.createElement)(u,{reactions:e})))};function p({title:e="",postId:a=null,reactions:r=null,titleComponent:c=null}){const{namespace:o}=s(),[i,u]=(0,n.useState)(r),[p,h]=(0,n.useState)(!r);return(0,n.useEffect)((()=>{if(r)return u(r),void h(!1);a?(h(!0),l()({path:`/${o}/posts/${a}/reactions`}).then((e=>{u(e),h(!1)})).catch((()=>h(!1)))):h(!1)}),[a,r]),p?null:i&&Object.values(i).some((e=>e.items?.length>0))?(0,t.createElement)("div",{className:"activitypub-reactions"},c||e&&(0,t.createElement)("h6",null,e),Object.entries(i).map((([e,n])=>n.items?.length?(0,t.createElement)(m,{key:e,items:n.items,label:n.label}):null))):null}r()((()=>{[].forEach.call(document.querySelectorAll(".activitypub-reactions-block"),(e=>{const a=JSON.parse(e.dataset.attrs);(0,n.createRoot)(e).render((0,t.createElement)(p,{...a}))}))}))})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/block.json deleted file mode 100644 index b7d0b495..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/block.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "$schema": "https://schemas.wp.org/trunk/block.json", - "name": "activitypub/remote-reply", - "apiVersion": 3, - "version": "1.0.0", - "title": "Reply on the Fediverse", - "category": "widgets", - "description": "", - "textdomain": "activitypub", - "viewScript": "file:./index.js" -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/index.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/index.asset.php deleted file mode 100644 index 70196da8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-dom-ready', 'wp-element', 'wp-i18n', 'wp-primitives'), 'version' => '7160b6399cd924e1c7be'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/index.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/index.js deleted file mode 100644 index 1494b656..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/index.js +++ /dev/null @@ -1,2 +0,0 @@ -(()=>{"use strict";var e,t={170:(e,t,r)=>{var o=r(609);const a=window.wp.element,i=window.wp.domReady;var n=r.n(i);const l=window.wp.components,c=window.wp.i18n,s=(0,a.forwardRef)((function({icon:e,size:t=24,...r},o){return(0,a.cloneElement)(e,{width:t,height:t,...r,ref:o})})),m=window.wp.primitives;var p=r(848);const u=(0,p.jsx)(m.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,p.jsx)(m.Path,{d:"M12 21C16.9706 21 21 16.9706 21 12C21 7.02944 16.9706 3 12 3C7.02944 3 3 7.02944 3 12C3 16.9706 7.02944 21 12 21ZM15.5303 8.46967C15.8232 8.76256 15.8232 9.23744 15.5303 9.53033L13.0607 12L15.5303 14.4697C15.8232 14.7626 15.8232 15.2374 15.5303 15.5303C15.2374 15.8232 14.7626 15.8232 14.4697 15.5303L12 13.0607L9.53033 15.5303C9.23744 15.8232 8.76256 15.8232 8.46967 15.5303C8.17678 15.2374 8.17678 14.7626 8.46967 14.4697L10.9393 12L8.46967 9.53033C8.17678 9.23744 8.17678 8.76256 8.46967 8.46967C8.76256 8.17678 9.23744 8.17678 9.53033 8.46967L12 10.9393L14.4697 8.46967C14.7626 8.17678 15.2374 8.17678 15.5303 8.46967Z"})}),d=window.wp.apiFetch;var v=r.n(d);const y=(0,p.jsx)(m.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,p.jsx)(m.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5 4.5h11a.5.5 0 0 1 .5.5v11a.5.5 0 0 1-.5.5H5a.5.5 0 0 1-.5-.5V5a.5.5 0 0 1 .5-.5ZM3 5a2 2 0 0 1 2-2h11a2 2 0 0 1 2 2v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5Zm17 3v10.75c0 .69-.56 1.25-1.25 1.25H6v1.5h12.75a2.75 2.75 0 0 0 2.75-2.75V8H20Z"})}),_=(0,p.jsx)(m.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,p.jsx)(m.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})}),f=(0,p.jsx)(m.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,p.jsx)(m.Path,{d:"M15.5 9.5a1 1 0 100-2 1 1 0 000 2zm0 1.5a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm-2.25 6v-2a2.75 2.75 0 00-2.75-2.75h-4A2.75 2.75 0 003.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0120.25 15zM9.5 8.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0z",fillRule:"evenodd"})}),b=window.wp.compose,w="fediverse-remote-user";function h(){const[e,t]=(0,a.useState)(function(){const e=localStorage.getItem(w);return e?JSON.parse(e):{}}()),r=(0,a.useCallback)((e=>{!function(e){localStorage.setItem(w,JSON.stringify(e))}(e),t(e)}),[]),o=(0,a.useCallback)((()=>{localStorage.removeItem(w),t({})}),[]);return{template:e?.template||!1,profileURL:e?.profileURL||!1,setRemoteUser:r,deleteRemoteUser:o}}function g(e){try{return new URL(e),!0}catch(e){return!1}}function E({actionText:e,copyDescription:t,handle:r,resourceUrl:i,myProfile:n="",rememberProfile:m=!1}){const p=(0,c.__)("Loading...","activitypub"),u=(0,c.__)("Opening...","activitypub"),d=(0,c.__)("Error","activitypub"),w=(0,c.__)("Invalid","activitypub"),E=n||(0,c.__)("My Profile","activitypub"),[C,R]=(0,a.useState)(e),[x,O]=(0,a.useState)(y),k=(0,b.useCopyToClipboard)(r,(()=>{O(_),setTimeout((()=>O(y)),1e3)})),[L,S]=(0,a.useState)(""),[U,N]=(0,a.useState)(!0),{setRemoteUser:P}=h(),j=(0,a.useCallback)((()=>{let t;if(!g(L)&&!function(e){const t=e.replace(/^@/,"").split("@");return 2===t.length&&g(`https://${t[1]}`)}(L))return R(w),t=setTimeout((()=>R(e)),2e3),()=>clearTimeout(t);const r=i+L;R(p),v()({path:r}).then((({url:t,template:r})=>{U&&P({profileURL:L,template:r}),R(u),setTimeout((()=>{window.open(t,"_blank"),R(e)}),200)})).catch((()=>{R(d),setTimeout((()=>R(e)),2e3)}))}),[L]);return(0,o.createElement)("div",{className:"activitypub__dialog",role:"dialog","aria-labelledby":"dialog-title"},(0,o.createElement)("div",{className:"activitypub-dialog__section"},(0,o.createElement)("h4",{id:"dialog-title"},E),(0,o.createElement)("div",{className:"activitypub-dialog__description",id:"copy-description"},t),(0,o.createElement)("div",{className:"activitypub-dialog__button-group"},(0,o.createElement)("label",{htmlFor:"profile-handle",className:"screen-reader-text"},t),(0,o.createElement)("input",{type:"text",id:"profile-handle",value:r,readOnly:!0}),(0,o.createElement)(l.Button,{ref:k,"aria-label":(0,c.__)("Copy handle to clipboard","activitypub")},(0,o.createElement)(s,{icon:x}),(0,c.__)("Copy","activitypub")))),(0,o.createElement)("div",{className:"activitypub-dialog__section"},(0,o.createElement)("h4",{id:"remote-profile-title"},(0,c.__)("Your Profile","activitypub")),(0,o.createElement)("div",{className:"activitypub-dialog__description",id:"remote-profile-description"},(0,a.createInterpolateElement)((0,c.__)("Or, if you know your own profile, we can start things that way! (eg @yourusername@example.com)","activitypub"),{code:(0,o.createElement)("code",null)})),(0,o.createElement)("div",{className:"activitypub-dialog__button-group"},(0,o.createElement)("label",{htmlFor:"remote-profile",className:"screen-reader-text"},(0,c.__)("Enter your ActivityPub profile","activitypub")),(0,o.createElement)("input",{type:"text",id:"remote-profile",value:L,onKeyDown:e=>{"Enter"===e?.code&&j()},onChange:e=>S(e.target.value),"aria-invalid":C===w}),(0,o.createElement)(l.Button,{onClick:j,"aria-label":(0,c.__)("Submit profile","activitypub")},(0,o.createElement)(s,{icon:f}),C)),m&&(0,o.createElement)("div",{className:"activitypub-dialog__remember"},(0,o.createElement)(l.CheckboxControl,{checked:U,label:(0,c.__)("Remember me for easier comments","activitypub"),onChange:()=>{N(!U)}}))))}function C({selectedComment:e,commentId:t}){const{namespace:r}=window._activityPubOptions||{},a=(0,c.__)("Reply","activitypub"),i=`/${r}/comments/${t}/remote-reply?resource=`,n=(0,c.__)("Copy and paste the Comment URL into the search field of your favorite fediverse app or server.","activitypub");return(0,o.createElement)(E,{actionText:a,copyDescription:n,handle:e,resourceUrl:i,myProfile:(0,c.__)("Original Comment URL","activitypub"),rememberProfile:!0})}function R({profileURL:e,template:t,commentURL:r,deleteRemoteUser:a}){return(0,o.createElement)(o.Fragment,null,(0,o.createElement)(l.Button,{variant:"link",className:"comment-reply-link activitypub-remote-reply__button",onClick:()=>{const e=t.replace("{uri}",r);window.open(e,"_blank")}},/* translators: %s: profile name */ /* translators: %s: profile name */ -(0,c.sprintf)((0,c.__)("Reply as %s","activitypub"),e)),(0,o.createElement)(l.Button,{className:"activitypub-remote-profile-delete",onClick:a,title:(0,c.__)("Delete Remote Profile","activitypub")},(0,o.createElement)(s,{icon:u,size:18})))}function x({selectedComment:e,commentId:t}){const[r,i]=(0,a.useState)(!1),n=(0,c.__)("Remote Reply","activitypub"),{profileURL:s,template:m,deleteRemoteUser:p}=h(),u=s&&m;return(0,o.createElement)(o.Fragment,null,u?(0,o.createElement)(R,{profileURL:s,template:m,commentURL:e,deleteRemoteUser:p}):(0,o.createElement)(l.Button,{variant:"link",className:"comment-reply-link activitypub-remote-reply__button",onClick:()=>i(!0)},(0,c.__)("Reply on the Fediverse","activitypub")),r&&(0,o.createElement)(l.Modal,{className:"activitypub-remote-reply__modal activitypub__modal",onRequestClose:()=>i(!1),title:n},(0,o.createElement)(C,{selectedComment:e,commentId:t})))}let O=1;n()((()=>{[].forEach.call(document.querySelectorAll(".activitypub-remote-reply"),(e=>{const t=JSON.parse(e.dataset.attrs);(0,a.createRoot)(e).render((0,o.createElement)(x,{...t,id:"activitypub-remote-reply-link-"+O++,useId:!0}))}))}))},20:(e,t,r)=>{var o=r(609),a=Symbol.for("react.element"),i=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),n=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,r){var o,c={},s=null,m=null;for(o in void 0!==r&&(s=""+r),void 0!==t.key&&(s=""+t.key),void 0!==t.ref&&(m=t.ref),t)i.call(t,o)&&!l.hasOwnProperty(o)&&(c[o]=t[o]);if(e&&e.defaultProps)for(o in t=e.defaultProps)void 0===c[o]&&(c[o]=t[o]);return{$$typeof:a,type:e,key:s,ref:m,props:c,_owner:n.current}}},848:(e,t,r)=>{e.exports=r(20)},609:e=>{e.exports=window.React}},r={};function o(e){var a=r[e];if(void 0!==a)return a.exports;var i=r[e]={exports:{}};return t[e](i,i.exports,o),i.exports}o.m=t,e=[],o.O=(t,r,a,i)=>{if(!r){var n=1/0;for(m=0;m=i)&&Object.keys(o.O).every((e=>o.O[e](r[c])))?r.splice(c--,1):(l=!1,i0&&e[m-1][2]>i;m--)e[m]=e[m-1];e[m]=[r,a,i]},o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={227:0,739:0};o.O.j=t=>0===e[t];var t=(t,r)=>{var a,i,n=r[0],l=r[1],c=r[2],s=0;if(n.some((t=>0!==e[t]))){for(a in l)o.o(l,a)&&(o.m[a]=l[a]);if(c)var m=c(o)}for(t&&t(r);so(170)));a=o.O(a)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/style-index-rtl.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/style-index-rtl.css deleted file mode 100644 index 04857b9b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/style-index-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub__modal.components-modal__frame{background-color:#f7f7f7;color:#333}.activitypub__modal.components-modal__frame .components-modal__header-heading,.activitypub__modal.components-modal__frame h4{color:#333;letter-spacing:inherit;word-spacing:inherit}.activitypub__modal.components-modal__frame .components-modal__header .components-button:hover{color:var(--color-white)}.activitypub__dialog{max-width:40em}.activitypub__dialog h4{line-height:1;margin:0}.activitypub__dialog .activitypub-dialog__section{margin-bottom:2em}.activitypub__dialog .activitypub-dialog__remember{margin-top:1em}.activitypub__dialog .activitypub-dialog__description{font-size:var(--wp--preset--font-size--normal,.75rem);margin:.33em 0 1em}.activitypub__dialog .activitypub-dialog__button-group{align-items:flex-end;display:flex;justify-content:flex-end}.activitypub__dialog .activitypub-dialog__button-group svg{height:21px;margin-left:.5em;width:21px}.activitypub__dialog .activitypub-dialog__button-group input{background-color:var(--wp--preset--color--white);border-radius:0 50px 50px 0;border-width:1px;border:1px solid var(--wp--preset--color--black);color:var(--wp--preset--color--black);flex:1;font-size:16px;height:inherit;line-height:1;margin-left:0;padding:15px 23px}.activitypub__dialog .activitypub-dialog__button-group button{align-self:center;background-color:var(--wp--preset--color--black);border-radius:50px 0 0 50px;border-width:1px;color:var(--wp--preset--color--white);font-size:16px;height:inherit;line-height:1;margin-right:0;padding:15px 23px;text-decoration:none}.activitypub__dialog .activitypub-dialog__button-group button:hover{border:inherit}.activitypub-remote-profile-delete{align-self:center;color:inherit;font-size:inherit;height:inherit;padding:0 5px}.activitypub-remote-profile-delete:hover{background:inherit;border:inherit}.activitypub-remote-reply{display:flex} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/style-index.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/style-index.css deleted file mode 100644 index c07d1493..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/remote-reply/style-index.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub__modal.components-modal__frame{background-color:#f7f7f7;color:#333}.activitypub__modal.components-modal__frame .components-modal__header-heading,.activitypub__modal.components-modal__frame h4{color:#333;letter-spacing:inherit;word-spacing:inherit}.activitypub__modal.components-modal__frame .components-modal__header .components-button:hover{color:var(--color-white)}.activitypub__dialog{max-width:40em}.activitypub__dialog h4{line-height:1;margin:0}.activitypub__dialog .activitypub-dialog__section{margin-bottom:2em}.activitypub__dialog .activitypub-dialog__remember{margin-top:1em}.activitypub__dialog .activitypub-dialog__description{font-size:var(--wp--preset--font-size--normal,.75rem);margin:.33em 0 1em}.activitypub__dialog .activitypub-dialog__button-group{align-items:flex-end;display:flex;justify-content:flex-end}.activitypub__dialog .activitypub-dialog__button-group svg{height:21px;margin-right:.5em;width:21px}.activitypub__dialog .activitypub-dialog__button-group input{background-color:var(--wp--preset--color--white);border-radius:50px 0 0 50px;border-width:1px;border:1px solid var(--wp--preset--color--black);color:var(--wp--preset--color--black);flex:1;font-size:16px;height:inherit;line-height:1;margin-right:0;padding:15px 23px}.activitypub__dialog .activitypub-dialog__button-group button{align-self:center;background-color:var(--wp--preset--color--black);border-radius:0 50px 50px 0;border-width:1px;color:var(--wp--preset--color--white);font-size:16px;height:inherit;line-height:1;margin-left:0;padding:15px 23px;text-decoration:none}.activitypub__dialog .activitypub-dialog__button-group button:hover{border:inherit}.activitypub-remote-profile-delete{align-self:center;color:inherit;font-size:inherit;height:inherit;padding:0 5px}.activitypub-remote-profile-delete:hover{background:inherit;border:inherit}.activitypub-remote-reply{display:flex} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/block.json deleted file mode 100644 index c2817199..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/block.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "name": "reply-handler", - "title": "Reply Handler: not a block, but block.json is very useful.", - "category": "widgets", - "icon": "admin-comments", - "keywords": [ - "reply", - "handler", - "comments" - ], - "editorScript": "file:./plugin.js" -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/plugin.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/plugin.asset.php deleted file mode 100644 index 72bbe977..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/plugin.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('wp-block-editor', 'wp-blocks', 'wp-data', 'wp-element', 'wp-plugins'), 'version' => 'f65a7269b5abb57d3e73'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/plugin.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/plugin.js deleted file mode 100644 index b4a7e993..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply-intent/plugin.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";const e=window.wp.plugins,t=window.wp.blocks,i=window.wp.data,n=window.wp.blockEditor,o=window.wp.element;let r=!1;(0,e.registerPlugin)("activitypub-reply-intent",{render:()=>((0,o.useEffect)((()=>{if(r)return;const e=new URLSearchParams(window.location.search).get("in_reply_to");e&&!r&&setTimeout((()=>{const o=(0,t.createBlock)("activitypub/reply",{url:e,embedPost:!0}),r=(0,i.dispatch)(n.store);r.insertBlock(o),r.insertAfterBlock(o.clientId)}),200),r=!0})),null)})})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/block.json b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/block.json deleted file mode 100644 index c3a57338..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/block.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "$schema": "https://schemas.wp.org/trunk/block.json", - "apiVersion": 3, - "name": "activitypub/reply", - "version": "0.1.0", - "title": "Federated Reply", - "category": "widgets", - "icon": "commentReplyLink", - "description": "Respond to posts, notes, videos, and other content on the fediverse. Ensure the URL originates from a federated social network like Mastodon, as other URLs might not function as expected.", - "supports": { - "html": false, - "inserter": true, - "reusable": false, - "lock": false - }, - "textdomain": "activitypub", - "editorScript": "file:./index.js", - "editorStyle": "file:./style-index.css", - "style": "file:./index.css", - "attributes": { - "url": { - "type": "string" - }, - "embedPost": { - "type": "boolean", - "default": null - } - } -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index-rtl.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index-rtl.css deleted file mode 100644 index 0a5e5c51..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-embed{background:#fff;border:1px solid #e6e6e6;border-radius:12px;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;max-width:100%;padding:0}.activitypub-reply-block .activitypub-embed{margin:1em 0}.activitypub-embed-header{align-items:center;display:flex;gap:10px;padding:15px}.activitypub-embed-header img{border-radius:50%;height:48px;width:48px}.activitypub-embed-header-text{flex-grow:1}.activitypub-embed-header-text h2{color:#000;font-size:15px;font-weight:600;margin:0;padding:0}.activitypub-embed-header-text .ap-account{color:#687684;font-size:14px;text-decoration:none}.activitypub-embed-content{padding:0 15px 15px}.activitypub-embed-content .ap-title{color:#000;font-size:23px;font-weight:600;margin:0 0 10px;padding:0}.activitypub-embed-content .ap-subtitle{color:#000;font-size:15px;margin:0 0 15px}.activitypub-embed-content .ap-preview{border:1px solid #e6e6e6;border-radius:8px;overflow:hidden}.activitypub-embed-content .ap-preview img{display:block;height:auto;width:100%}.activitypub-embed-content .ap-preview-text{padding:15px}.activitypub-embed-meta{border-top:1px solid #e6e6e6;color:#687684;display:flex;font-size:13px;gap:15px;padding:15px}.activitypub-embed-meta .ap-stat{align-items:center;display:flex;gap:5px}@media only screen and (max-width:399px){.activitypub-embed-meta .ap-stat{display:none!important}}.activitypub-embed-meta a.ap-stat{color:inherit;text-decoration:none}.activitypub-embed-meta strong{color:#000;font-weight:600}.activitypub-embed-meta .ap-stat-label{color:#687684}.wp-block-activitypub-reply .components-spinner{height:12px;margin-bottom:0;margin-top:0;width:12px} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.asset.php b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.asset.php deleted file mode 100644 index f82365da..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-data', 'wp-element', 'wp-i18n', 'wp-primitives', 'wp-url'), 'version' => 'fcd855ff6f64b21029be'); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.css deleted file mode 100644 index 0a5e5c51..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-embed{background:#fff;border:1px solid #e6e6e6;border-radius:12px;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica,Arial,sans-serif;max-width:100%;padding:0}.activitypub-reply-block .activitypub-embed{margin:1em 0}.activitypub-embed-header{align-items:center;display:flex;gap:10px;padding:15px}.activitypub-embed-header img{border-radius:50%;height:48px;width:48px}.activitypub-embed-header-text{flex-grow:1}.activitypub-embed-header-text h2{color:#000;font-size:15px;font-weight:600;margin:0;padding:0}.activitypub-embed-header-text .ap-account{color:#687684;font-size:14px;text-decoration:none}.activitypub-embed-content{padding:0 15px 15px}.activitypub-embed-content .ap-title{color:#000;font-size:23px;font-weight:600;margin:0 0 10px;padding:0}.activitypub-embed-content .ap-subtitle{color:#000;font-size:15px;margin:0 0 15px}.activitypub-embed-content .ap-preview{border:1px solid #e6e6e6;border-radius:8px;overflow:hidden}.activitypub-embed-content .ap-preview img{display:block;height:auto;width:100%}.activitypub-embed-content .ap-preview-text{padding:15px}.activitypub-embed-meta{border-top:1px solid #e6e6e6;color:#687684;display:flex;font-size:13px;gap:15px;padding:15px}.activitypub-embed-meta .ap-stat{align-items:center;display:flex;gap:5px}@media only screen and (max-width:399px){.activitypub-embed-meta .ap-stat{display:none!important}}.activitypub-embed-meta a.ap-stat{color:inherit;text-decoration:none}.activitypub-embed-meta strong{color:#000;font-weight:600}.activitypub-embed-meta .ap-stat-label{color:#687684}.wp-block-activitypub-reply .components-spinner{height:12px;margin-bottom:0;margin-top:0;width:12px} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.js b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.js deleted file mode 100644 index 0e1c337b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/index.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";var e,t={238:(e,t,r)=>{const n=window.wp.blocks,o=window.wp.primitives;var a=r(848);const i=(0,a.jsx)(o.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,a.jsx)(o.Path,{d:"M6.68822 10.625L6.24878 11.0649L5.5 11.8145L5.5 5.5L12.5 5.5V8L14 6.5V5C14 4.44772 13.5523 4 13 4H5C4.44772 4 4 4.44771 4 5V13.5247C4 13.8173 4.16123 14.086 4.41935 14.2237C4.72711 14.3878 5.10601 14.3313 5.35252 14.0845L7.31 12.125H8.375L9.875 10.625H7.31H6.68822ZM14.5605 10.4983L11.6701 13.75H16.9975C17.9963 13.75 18.7796 14.1104 19.3553 14.7048C19.9095 15.2771 20.2299 16.0224 20.4224 16.7443C20.7645 18.0276 20.7543 19.4618 20.7487 20.2544C20.7481 20.345 20.7475 20.4272 20.7475 20.4999L19.2475 20.5001C19.2475 20.4191 19.248 20.3319 19.2484 20.2394V20.2394C19.2526 19.4274 19.259 18.2035 18.973 17.1307C18.8156 16.5401 18.586 16.0666 18.2778 15.7483C17.9909 15.4521 17.5991 15.25 16.9975 15.25H11.8106L14.5303 17.9697L13.4696 19.0303L8.96956 14.5303L13.4394 9.50171L14.5605 10.4983Z"})});var l=r(609);const c=window.wp.blockEditor,s=window.wp.components,d=window.wp.i18n,u=window.wp.element,m=window.wp.compose,p=window.wp.apiFetch;var f=r.n(p);const h=window.wp.url,w=window.wp.data;function b({html:e}){const t=(0,u.useRef)(null),[r,n]=(0,u.useState)(300),o=(0,u.useRef)(300),a=(0,u.useCallback)((()=>{if(t.current)try{const e=t.current;let r=300;try{e.contentDocument&&e.contentDocument.body?r=e.contentDocument.body.scrollHeight:e.contentWindow&&e.contentWindow.document&&e.contentWindow.document.body&&(r=e.contentWindow.document.body.scrollHeight)}catch(e){console.log("Could not access iframe content document:",e)}r+=5,Math.abs(r-o.current)>5&&(o.current=r,n(r))}catch(e){console.error("Error adjusting iframe height:",e)}}),[]),i=(0,u.useCallback)((()=>{if(t.current)try{a()}catch(e){console.error("Error setting up iframe height adjustment:",e)}}),[a]);return(0,u.useEffect)((()=>{t.current&&t.current.addEventListener("load",i);const e=setInterval(a,1e3);return()=>{clearInterval(e),t.current&&t.current.removeEventListener("load",i)}}),[i,a]),(0,u.useEffect)((()=>{if(t.current){const e=setTimeout((()=>{a()}),100);return()=>clearTimeout(e)}}),[e,a]),{iframeRef:t,iframeHeight:r,adjustIframeHeight:a,handleIframeLoad:i}}const v={class:"className",frameborder:"frameBorder",allowfullscreen:"allowFullScreen",allowtransparency:"allowTransparency",marginheight:"marginHeight",marginwidth:"marginWidth"};function y({onClick:e}){return(0,l.createElement)("div",{className:"activitypub-embed-overlay",onClick:e,style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",cursor:"pointer",zIndex:1}})}function g({html:e,onSelectBlock:t}){const r=(0,u.useRef)(),[n,o]=(0,u.useState)(282),[a,i]=(0,u.useState)(!1),c=(0,u.useCallback)((()=>{const t=(new window.DOMParser).parseFromString(e,"text/html").querySelector("iframe"),r={};return t?(Array.from(t.attributes).forEach((({name:e,value:t})=>{"style"!==e&&(r[v[e]||e]=t)})),r):r}),[e]),s=c();return(0,u.useEffect)((()=>{if(!r.current)return;const{ownerDocument:e}=r.current,{defaultView:t}=e;function n({data:{secret:e,message:t,value:r}={}}){"height"===t&&e===s["data-secret"]&&o(r)}return t.addEventListener("message",n),()=>{t.removeEventListener("message",n)}}),[s]),s.src?(0,l.createElement)("div",{className:"wp-block-embed__wrapper",style:{position:"relative"}},(0,l.createElement)("iframe",{ref:r,title:s.title||(0,d.__)("Embedded WordPress content","activitypub"),...s,height:n,style:{width:"100%",maxWidth:"100%"}}),!a&&(0,l.createElement)(y,{onClick:t})):(0,l.createElement)("div",{className:"wp-block-embed__wrapper",style:{position:"relative"}},(0,l.createElement)("div",{dangerouslySetInnerHTML:{__html:e}}),(0,l.createElement)(y,{onClick:t}))}function _({html:e,onClick:t,isSelected:r}){const{iframeRef:n,iframeHeight:o,adjustIframeHeight:a,handleIframeLoad:i}=b({html:e}),c=(0,u.useCallback)((()=>`\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t${e}\n\t\t\t\n\t\t\t\n\t\t`),[e]);return(0,l.createElement)("div",{className:"wp-block-embed__wrapper",style:{position:"relative"}},(0,l.createElement)("iframe",{ref:n,srcDoc:c(),sandbox:"allow-scripts allow-same-origin allow-popups allow-forms",style:{width:"100%",height:`${o}px`,border:"none",overflow:"hidden"},onLoad:i}),r&&(0,l.createElement)("div",{onClick:t,style:{position:"absolute",top:0,left:0,width:"100%",height:"100%",cursor:"pointer",zIndex:1,display:r?"block":"none"}}))}const E={default:(0,d.__)("Enter the URL of a post from the Fediverse (Mastodon, Pixelfed, etc.) that you want to reply to.","activitypub"),checking:()=>(0,l.createElement)(l.Fragment,null,(0,l.createElement)(s.Spinner,null)," "+(0,d.__)("Checking if this URL supports ActivityPub replies...","activitypub")),valid:(0,d.__)("The author will be notified of your response.","activitypub"),error:(0,d.__)("This URL probably won't receive your reply. We'll still try.","activitypub")},k={valid:(0,d.__)("This post can be embedded with your reply.","activitypub"),invalid:(0,d.__)("This post cannot be embedded.","activitypub")};(0,n.registerBlockType)("activitypub/reply",{edit:function({attributes:e,setAttributes:t,clientId:r,isSelected:n}){const{url:o}=e,{namespace:a}=window._activityPubOptions||{},[i,p]=(0,u.useState)(E.default),[v,y]=(0,u.useState)(!1),[C,L]=(0,u.useState)(!1),[S,O]=(0,u.useState)(!1),[P,x]=(0,u.useState)(!0===e.embedPost||!o),[R,T]=(0,u.useState)(null),{iframeRef:H,iframeHeight:I,adjustIframeHeight:j,handleIframeLoad:D}=b({html:R}),{insertAfterBlock:B,removeBlock:N}=(0,w.useDispatch)("core/block-editor"),W=(0,c.useBlockProps)(),F=(0,u.useRef)(),M=((0,u.useRef)(),(0,u.useRef)(P)),U=()=>{setTimeout((()=>F.current?.focus()),50)};(0,u.useEffect)((()=>{M.current=P}),[P]);const A=(0,u.useCallback)((e=>{y(e),M.current&&e&&t({embedPost:!0})}),[t]),V=(e=!1)=>{O(e),y(!1),L(!1),T("")},$=(0,m.useDebounce)((async e=>{if(e)try{V(!0),p(E.checking());const t=await f()({path:(0,h.addQueryArgs)(`${a}/url/validate`,{url:e})});A(t.is_activitypub),L(t.is_real_oembed),T(t.html||""),p(E.valid)}catch(e){V(),p(E.error)}finally{O(!1)}else V()}),250);return(0,u.useEffect)((()=>{o&&$(o)}),[o]),(0,l.createElement)(l.Fragment,null,(0,l.createElement)(c.InspectorControls,null,(0,l.createElement)(s.PanelBody,{title:(0,d.__)("Settings","activitypub")},(0,l.createElement)(s.ToggleControl,{label:(0,d.__)("Embed Post","activitypub"),checked:e.embedPost,onChange:e=>{t({embedPost:e}),x(e)},disabled:!v,help:v?k.valid:k.invalid}))),(0,l.createElement)("div",{...W},n&&(0,l.createElement)(s.TextControl,{label:(0,d.__)("Your post is a reply to the following URL","activitypub"),value:o,onChange:e=>t({url:e}),help:i,onKeyDown:t=>{"Enter"===t.key&&B(r),!e.url&&["Backspace","Delete"].includes(t.key)&&N(r)},ref:F}),v&&e.embedPost&&R&&(0,l.createElement)("div",{className:"activitypub-embed-container"},C&&(Y=R)&&(Y.includes("wp-embedded-content")||Y.includes("wp-embed/")||Y.includes('class="wp-embed"'))?(0,l.createElement)(g,{html:R,onSelectBlock:U}):(0,l.createElement)(_,{html:R,onClick:U,isSelected:n})),o&&(!e.embedPost||!R)&&(0,l.createElement)("div",{className:"activitypub-reply-block-editor__preview",contentEditable:!1,onClick:U,style:{cursor:"pointer"}},(0,l.createElement)("a",{href:o,className:"u-in-reply-to",target:"_blank",rel:"noreferrer"},"↬"+o.replace(/^https?:\/\//,"")))));var Y},save:()=>null,icon:i})},20:(e,t,r)=>{var n=r(609),o=Symbol.for("react.element"),a=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),i=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,r){var n,c={},s=null,d=null;for(n in void 0!==r&&(s=""+r),void 0!==t.key&&(s=""+t.key),void 0!==t.ref&&(d=t.ref),t)a.call(t,n)&&!l.hasOwnProperty(n)&&(c[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===c[n]&&(c[n]=t[n]);return{$$typeof:o,type:e,key:s,ref:d,props:c,_owner:i.current}}},848:(e,t,r)=>{e.exports=r(20)},609:e=>{e.exports=window.React}},r={};function n(e){var o=r[e];if(void 0!==o)return o.exports;var a=r[e]={exports:{}};return t[e](a,a.exports,n),a.exports}n.m=t,e=[],n.O=(t,r,o,a)=>{if(!r){var i=1/0;for(d=0;d=a)&&Object.keys(n.O).every((e=>n.O[e](r[c])))?r.splice(c--,1):(l=!1,a0&&e[d-1][2]>a;d--)e[d]=e[d-1];e[d]=[r,o,a]},n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={780:0,356:0};n.O.j=t=>0===e[t];var t=(t,r)=>{var o,a,i=r[0],l=r[1],c=r[2],s=0;if(i.some((t=>0!==e[t]))){for(o in l)n.o(l,o)&&(n.m[o]=l[o]);if(c)var d=c(n)}for(t&&t(r);sn(238)));o=n.O(o)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/style-index-rtl.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/style-index-rtl.css deleted file mode 100644 index ec651ab6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/style-index-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-embed-container{margin-top:1em;min-height:100px;pointer-events:none;position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none}.activitypub-embed-loading{align-items:center;display:flex;justify-content:center}.activitypub-embed-container .wp-block-embed{pointer-events:none!important}.activitypub-embed-preview,.activitypub-embed-preview iframe{pointer-events:none}.activitypub-reply-display{margin:1em 0}.activitypub-reply-display p{margin:0}.activitypub-reply-display a{color:#2271b1;text-decoration:none}.activitypub-reply-display a:hover{color:#135e96;text-decoration:underline} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/style-index.css b/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/style-index.css deleted file mode 100644 index ec651ab6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/build/reply/style-index.css +++ /dev/null @@ -1 +0,0 @@ -.activitypub-embed-container{margin-top:1em;min-height:100px;pointer-events:none;position:relative;-webkit-user-select:none;-moz-user-select:none;user-select:none}.activitypub-embed-loading{align-items:center;display:flex;justify-content:center}.activitypub-embed-container .wp-block-embed{pointer-events:none!important}.activitypub-embed-preview,.activitypub-embed-preview iframe{pointer-events:none}.activitypub-reply-display{margin:1em 0}.activitypub-reply-display p{margin:0}.activitypub-reply-display a{color:#2271b1;text-decoration:none}.activitypub-reply-display a:hover{color:#135e96;text-decoration:underline} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-activity.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-activity.php deleted file mode 100644 index b4623ac2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-activity.php +++ /dev/null @@ -1,269 +0,0 @@ -set( 'object', $object ); - $this->pre_fill_activity_from_object(); - } - - /** - * Fills the Activity with the specified activity object. - */ - public function pre_fill_activity_from_object() { - $object = $this->get_object(); - - // Check if `$data` is a URL and use it to generate an ID then. - if ( is_string( $object ) && filter_var( $object, FILTER_VALIDATE_URL ) && ! $this->get_id() ) { - $this->set( 'id', $object . '#activity-' . strtolower( $this->get_type() ) . '-' . time() ); - - return; - } - - // Check if `$data` is an object and copy some properties otherwise do nothing. - if ( ! is_object( $object ) ) { - return; - } - - foreach ( array( 'to', 'bto', 'cc', 'bcc', 'audience' ) as $i ) { - $value = $object->get( $i ); - if ( $value && ! $this->get( $i ) ) { - $this->set( $i, $value ); - } - } - - if ( $object->get_published() && ! $this->get_published() ) { - $this->set( 'published', $object->get_published() ); - } - - if ( $object->get_updated() && ! $this->get_updated() ) { - $this->set( 'updated', $object->get_updated() ); - } - - if ( $object->get_attributed_to() && ! $this->get_actor() ) { - $this->set( 'actor', $object->get_attributed_to() ); - } - - if ( $this->get_type() !== 'Announce' && $object->get_in_reply_to() && ! $this->get_in_reply_to() ) { - $this->set( 'in_reply_to', $object->get_in_reply_to() ); - } - - if ( $object->get_id() && ! $this->get_id() ) { - $id = strtok( $object->get_id(), '#' ); - if ( $object->get_updated() ) { - $updated = $object->get_updated(); - } elseif ( $object->get_published() ) { - $updated = $object->get_published(); - } else { - $updated = time(); - } - $this->set( 'id', $id . '#activity-' . strtolower( $this->get_type() ) . '-' . $updated ); - } - } - - /** - * The context of an Activity is usually just the context of the object it contains. - * - * @return array $context A compacted JSON-LD context. - */ - public function get_json_ld_context() { - if ( $this->object instanceof Base_Object ) { - $class = get_class( $this->object ); - if ( $class && $class::JSON_LD_CONTEXT ) { - // Without php 5.6 support this could be just: 'return $this->object::JSON_LD_CONTEXT;'. - return $class::JSON_LD_CONTEXT; - } - } - - return static::JSON_LD_CONTEXT; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-actor.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-actor.php deleted file mode 100644 index bbf2128b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-actor.php +++ /dev/null @@ -1,225 +0,0 @@ - 'http://schema.org#', - 'toot' => 'http://joinmastodon.org/ns#', - 'lemmy' => 'https://join-lemmy.org/ns#', - 'manuallyApprovesFollowers' => 'as:manuallyApprovesFollowers', - 'PropertyValue' => 'schema:PropertyValue', - 'value' => 'schema:value', - 'Hashtag' => 'as:Hashtag', - 'featured' => array( - '@id' => 'toot:featured', - '@type' => '@id', - ), - 'featuredTags' => array( - '@id' => 'toot:featuredTags', - '@type' => '@id', - ), - 'moderators' => array( - '@id' => 'lemmy:moderators', - '@type' => '@id', - ), - 'alsoKnownAs' => array( - '@id' => 'as:alsoKnownAs', - '@type' => '@id', - ), - 'movedTo' => array( - '@id' => 'as:movedTo', - '@type' => '@id', - ), - 'attributionDomains' => array( - '@id' => 'toot:attributionDomains', - '@type' => '@id', - ), - 'postingRestrictedToMods' => 'lemmy:postingRestrictedToMods', - 'discoverable' => 'toot:discoverable', - 'indexable' => 'toot:indexable', - ), - ); - - /** - * The default types for Actors. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#actor-types - * - * @var array - */ - const TYPES = array( - 'Application', - 'Group', - 'Organization', - 'Person', - 'Service', - ); - - /** - * The type of the object. - * - * @var string - */ - protected $type; - - /** - * A reference to an ActivityStreams OrderedCollection comprised of - * all the messages received by the actor. - * - * @see https://www.w3.org/TR/activitypub/#inbox - * - * @var string|null - */ - protected $inbox; - - /** - * A reference to an ActivityStreams OrderedCollection comprised of - * all the messages produced by the actor. - * - * @see https://www.w3.org/TR/activitypub/#outbox - * - * @var string|null - */ - protected $outbox; - - /** - * A link to an ActivityStreams collection of the actors that this - * actor is following. - * - * @see https://www.w3.org/TR/activitypub/#following - * - * @var string - */ - protected $following; - - /** - * A link to an ActivityStreams collection of the actors that - * follow this actor. - * - * @see https://www.w3.org/TR/activitypub/#followers - * - * @var string - */ - protected $followers; - - /** - * A link to an ActivityStreams collection of objects this actor has - * liked. - * - * @see https://www.w3.org/TR/activitypub/#liked - * - * @var string - */ - protected $liked; - - /** - * A list of supplementary Collections which may be of interest. - * - * @see https://www.w3.org/TR/activitypub/#streams-property - * - * @var array - */ - protected $streams = array(); - - /** - * A short username which may be used to refer to the actor, with no - * uniqueness guarantees. - * - * @see https://www.w3.org/TR/activitypub/#preferredUsername - * - * @var string|null - */ - protected $preferred_username; - - /** - * A JSON object which maps additional typically server/domain-wide - * endpoints which may be useful either for this actor or someone - * referencing this actor. This mapping may be nested inside the - * actor document as the value or may be a link to a JSON-LD - * document with these properties. - * - * @see https://www.w3.org/TR/activitypub/#endpoints - * - * @var string|array|null - */ - protected $endpoints; - - /** - * It's not part of the ActivityPub protocol but it's a quite common - * practice to handle an actor public key with a publicKey array: - * [ - * 'id' => 'https://my-example.com/actor#main-key' - * 'owner' => 'https://my-example.com/actor', - * 'publicKeyPem' => '-----BEGIN PUBLIC KEY----- - * MIIBI [...] - * DQIDAQAB - * -----END PUBLIC KEY-----' - * ] - * - * @see https://www.w3.org/wiki/SocialCG/ActivityPub/Authentication_Authorization#Signing_requests_using_HTTP_Signatures - * - * @var string|array|null - */ - protected $public_key; - - /** - * It's not part of the ActivityPub protocol but it's a quite common - * practice to lock an account. If anabled, new followers will not be - * automatically accepted, but will instead require you to manually - * approve them. - * - * WordPress does only support 'false' at the moment. - * - * @see https://docs.joinmastodon.org/spec/activitypub/#as - * - * @context as:manuallyApprovesFollowers - * - * @var boolean - */ - protected $manually_approves_followers = false; - - /** - * Domains allowed to use `fediverse:creator` for this actor in - * published articles. - * - * @see https://blog.joinmastodon.org/2024/07/highlighting-journalism-on-mastodon/ - * - * @var array - */ - protected $attribution_domains = null; - - /** - * The target of the actor. - * - * @var string|null - */ - protected $moved_to; - - /** - * The alsoKnownAs of the actor. - * - * @var array - */ - protected $also_known_as; -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-base-object.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-base-object.php deleted file mode 100644 index cc1d885e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-base-object.php +++ /dev/null @@ -1,508 +0,0 @@ - 'as:Hashtag', - 'sensitive' => 'as:sensitive', - ), - ); - - /** - * The default types for Objects. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#object-types - * - * @var array - */ - const TYPES = array( - 'Article', - 'Audio', - 'Document', - 'Event', - 'Image', - 'Note', - 'Page', - 'Place', - 'Profile', - 'Relationship', - 'Tombstone', - 'Video', - ); - - /** - * The type of the object. - * - * @var string - */ - protected $type = 'Object'; - - /** - * A resource attached or related to an object that potentially - * requires special handling. - * The intent is to provide a model that is at least semantically - * similar to attachments in email. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-attachment - * - * @var string|null - */ - protected $attachment; - - /** - * One or more entities to which this object is attributed. - * The attributed entities might not be Actors. For instance, an - * object might be attributed to the completion of another activity. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-attributedto - * - * @var string|null - */ - protected $attributed_to; - - /** - * One or more entities that represent the total population of - * entities for which the object can considered to be relevant. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-audience - * - * @var string|null - */ - protected $audience; - - /** - * The content or textual representation of the Object encoded as a - * JSON string. By default, the value of content is HTML. - * The mediaType property can be used in the object to indicate a - * different content type. - * - * The content MAY be expressed using multiple language-tagged - * values. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-content - * - * @var string|null - */ - protected $content; - - /** - * The context within which the object exists or an activity was - * performed. - * The notion of "context" used is intentionally vague. - * The intended function is to serve as a means of grouping objects - * and activities that share a common originating context or - * purpose. An example could be all activities relating to a common - * project or event. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-context - * - * @var string|null - */ - protected $context; - - /** - * The content MAY be expressed using multiple language-tagged - * values. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-content - * - * @var array|null - */ - protected $content_map; - - /** - * A simple, human-readable, plain-text name for the object. - * HTML markup MUST NOT be included. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-name - * - * @var string|null xsd:string - */ - protected $name; - - /** - * The name MAY be expressed using multiple language-tagged values. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-name - * - * @var array|null rdf:langString - */ - protected $name_map; - - /** - * The date and time describing the actual or expected ending time - * of the object. - * When used with an Activity object, for instance, the endTime - * property specifies the moment the activity concluded or - * is expected to conclude. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-endtime - * - * @var string|null - */ - protected $end_time; - - /** - * The entity (e.g. an application) that generated the object. - * - * @var string|null - */ - protected $generator; - - /** - * An entity that describes an icon for this object. - * The image should have an aspect ratio of one (horizontal) - * to one (vertical) and should be suitable for presentation - * at a small size. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-icon - * - * @var string|array|null - */ - protected $icon; - - /** - * An entity that describes an image for this object. - * Unlike the icon property, there are no aspect ratio - * or display size limitations assumed. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-image-term - * - * @var string|array|null - */ - protected $image; - - /** - * One or more entities for which this object is considered a - * response. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-inreplyto - * - * @var string|null - */ - protected $in_reply_to; - - /** - * One or more physical or logical locations associated with the - * object. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-location - * - * @var string|null - */ - protected $location; - - /** - * An entity that provides a preview of this object. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-preview - * - * @var string|null - */ - protected $preview; - - /** - * The date and time at which the object was published - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-published - * - * @var string|null xsd:dateTime - */ - protected $published; - - /** - * The date and time describing the actual or expected starting time - * of the object. - * When used with an Activity object, for instance, the startTime - * property specifies the moment the activity began - * or is scheduled to begin. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-starttime - * - * @var string|null xsd:dateTime - */ - protected $start_time; - - /** - * A natural language summarization of the object encoded as HTML. - * Multiple language tagged summaries MAY be provided. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-summary - * - * @var string|null - */ - protected $summary; - - /** - * The content MAY be expressed using multiple language-tagged - * values. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-summary - * - * @var string[]|null - */ - protected $summary_map; - - /** - * One or more "tags" that have been associated with an objects. - * A tag can be any kind of Object. - * The key difference between attachment and tag is that the former - * implies association by inclusion, while the latter implies - * associated by reference. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-tag - * - * @var string|null - */ - protected $tag; - - /** - * The date and time at which the object was updated - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-updated - * - * @var string|null xsd:dateTime - */ - protected $updated; - - /** - * One or more links to representations of the object. - * - * @var string|null - */ - protected $url; - - /** - * An entity considered to be part of the public primary audience - * of an Object - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-to - * - * @var string|array|null - */ - protected $to; - - /** - * An Object that is part of the private primary audience of this - * Object. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-bto - * - * @var string|array|null - */ - protected $bto; - - /** - * An Object that is part of the public secondary audience of this - * Object. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-cc - * - * @var string|array|null - */ - protected $cc; - - /** - * One or more Objects that are part of the private secondary - * audience of this Object. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-bcc - * - * @var string|array|null - */ - protected $bcc; - - /** - * The MIME media type of the value of the content property. - * If not specified, the content property is assumed to contain - * text/html content. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-mediatype - * - * @var string|null - */ - protected $media_type; - - /** - * When the object describes a time-bound resource, such as an audio - * or video, a meeting, etc, the duration property indicates the - * object's approximate duration. - * The value MUST be expressed as an xsd:duration as defined by - * xmlschema11-2, section 3.3.6 (e.g. a period of 5 seconds is - * represented as "PT5S"). - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-duration - * - * @var string|null - */ - protected $duration; - - /** - * Intended to convey some sort of source from which the content - * markup was derived, as a form of provenance, or to support - * future editing by clients. - * - * @see https://www.w3.org/TR/activitypub/#source-property - * - * @var array - */ - protected $source; - - /** - * A Collection containing objects considered to be responses to - * this object. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-replies - * - * @var string|array|null - */ - protected $replies; - - /** - * A Collection containing objects considered to be likes for - * this object. - * - * @see https://www.w3.org/TR/activitypub/#likes - * - * @var array - */ - protected $likes; - - /** - * A Collection containing objects considered to be shares for - * this object. - * - * @see https://www.w3.org/TR/activitypub/#shares - * - * @var array - */ - protected $shares; - - /** - * Used to mark an object as containing sensitive content. - * Mastodon displays a content warning, requiring users to click - * through to view the content. - * - * @see https://docs.joinmastodon.org/spec/activitypub/#sensitive - * - * @var boolean - */ - protected $sensitive; - - /** - * Generic getter. - * - * @param string $key The key to get. - * - * @return mixed The value. - */ - public function get( $key ) { - if ( ! $this->has( $key ) ) { - return new \WP_Error( 'invalid_key', __( 'Invalid key', 'activitypub' ), array( 'status' => 404 ) ); - } - - return parent::get( $key ); - } - - /** - * Generic setter. - * - * @param string $key The key to set. - * @param string $value The value to set. - * - * @return mixed The value. - */ - public function set( $key, $value ) { - if ( ! $this->has( $key ) ) { - return new \WP_Error( 'invalid_key', __( 'Invalid key', 'activitypub' ), array( 'status' => 404 ) ); - } - - return parent::set( $key, $value ); - } - - /** - * Generic adder. - * - * @param string $key The key to set. - * @param mixed $value The value to add. - * - * @return mixed The value. - */ - public function add( $key, $value ) { - if ( ! $this->has( $key ) ) { - return new \WP_Error( 'invalid_key', __( 'Invalid key', 'activitypub' ), array( 'status' => 404 ) ); - } - - return parent::add( $key, $value ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-generic-object.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-generic-object.php deleted file mode 100644 index eceff1e8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/class-generic-object.php +++ /dev/null @@ -1,325 +0,0 @@ -to_string(); - } - - /** - * Function to transform the object to string. - * - * @return string The object id. - */ - public function to_string() { - return $this->get_id(); - } - - /** - * Magic function to implement getter and setter. - * - * @param string $method The method name. - * @param string $params The method params. - */ - public function __call( $method, $params ) { - $var = \strtolower( \substr( $method, 4 ) ); - - if ( \strncasecmp( $method, 'get', 3 ) === 0 ) { - if ( ! $this->has( $var ) ) { - return null; - } - - return $this->$var; - } - - if ( \strncasecmp( $method, 'set', 3 ) === 0 ) { - return $this->set( $var, $params[0] ); - } - - if ( \strncasecmp( $method, 'add', 3 ) === 0 ) { - return $this->add( $var, $params[0] ); - } - } - - /** - * Generic getter. - * - * @param string $key The key to get. - * - * @return mixed The value. - */ - public function get( $key ) { - return call_user_func( array( $this, 'get_' . $key ) ); - } - - /** - * Generic setter. - * - * @param string $key The key to set. - * @param string $value The value to set. - * - * @return mixed The value. - */ - public function set( $key, $value ) { - $this->$key = $value; - - return $this; - } - - /** - * Generic adder. - * - * @param string $key The key to set. - * @param mixed $value The value to add. - * - * @return mixed The value. - */ - public function add( $key, $value ) { - if ( empty( $value ) ) { - return; - } - - if ( ! isset( $this->$key ) ) { - $this->$key = array(); - } - - if ( is_string( $this->$key ) ) { - $this->$key = array( $this->$key ); - } - - $attributes = $this->$key; - - if ( is_array( $value ) ) { - $attributes = array_merge( $attributes, $value ); - } else { - $attributes[] = $value; - } - - $this->$key = array_unique( $attributes ); - - return $this->$key; - } - - /** - * Check if the object has a key - * - * @param string $key The key to check. - * - * @return boolean True if the object has the key. - */ - public function has( $key ) { - return property_exists( $this, $key ); - } - - /** - * Convert JSON input to an array. - * - * @param string $json The JSON string. - * - * @return Generic_Object|\WP_Error An Object built from the JSON string or WP_Error when it's not a JSON string. - */ - public static function init_from_json( $json ) { - $array = \json_decode( $json, true ); - - if ( ! is_array( $array ) ) { - return new \WP_Error( 'invalid_json', __( 'Invalid JSON', 'activitypub' ), array( 'status' => 400 ) ); - } - - return self::init_from_array( $array ); - } - - /** - * Convert input array to a Base_Object. - * - * @param array $data The object array. - * - * @return Generic_Object|\WP_Error An Object built from the input array or WP_Error when it's not an array. - */ - public static function init_from_array( $data ) { - if ( ! is_array( $data ) ) { - return new \WP_Error( 'invalid_array', __( 'Invalid array', 'activitypub' ), array( 'status' => 400 ) ); - } - - $object = new static(); - $object->from_array( $data ); - - return $object; - } - - /** - * Convert JSON input to an array and pre-fill the object. - * - * @param array $data The array. - */ - public function from_array( $data ) { - foreach ( $data as $key => $value ) { - if ( null !== $value ) { - $key = camel_to_snake_case( $key ); - call_user_func( array( $this, 'set_' . $key ), $value ); - } - } - } - - /** - * Convert JSON input to an array and pre-fill the object. - * - * @param string $json The JSON string. - */ - public function from_json( $json ) { - $array = \json_decode( $json, true ); - - $this->from_array( $array ); - } - - /** - * Convert Object to an array. - * - * It tries to get the object attributes if they exist - * and falls back to the getters. Empty values are ignored. - * - * @param bool $include_json_ld_context Whether to include the JSON-LD context. Default true. - * - * @return array An array built from the Object. - */ - public function to_array( $include_json_ld_context = true ) { - $array = array(); - $vars = get_object_vars( $this ); - - foreach ( $vars as $key => $value ) { - if ( \is_wp_error( $value ) ) { - continue; - } - - // Ignore all _prefixed keys. - if ( '_' === substr( $key, 0, 1 ) ) { - continue; - } - - // If value is empty, try to get it from a getter. - if ( ! $value ) { - $value = call_user_func( array( $this, 'get_' . $key ) ); - } - - if ( is_object( $value ) ) { - $value = $value->to_array( false ); - } - - // If value is still empty, ignore it for the array and continue. - if ( isset( $value ) ) { - $array[ snake_to_camel_case( $key ) ] = $value; - } - } - - if ( $include_json_ld_context ) { - // Get JsonLD context and move it to '@context' at the top. - $array = array_merge( array( '@context' => $this->get_json_ld_context() ), $array ); - } - - $class = new \ReflectionClass( $this ); - $class = strtolower( $class->getShortName() ); - - /** - * Filter the array of the ActivityPub object. - * - * @param array $array The array of the ActivityPub object. - * @param string $class The class of the ActivityPub object. - * @param string $id The ID of the ActivityPub object. - * @param Generic_Object $object The ActivityPub object. - * - * @return array The filtered array of the ActivityPub object. - */ - $array = \apply_filters( 'activitypub_activity_object_array', $array, $class, $this->id, $this ); - - /** - * Filter the array of the ActivityPub object by class. - * - * @param array $array The array of the ActivityPub object. - * @param string $id The ID of the ActivityPub object. - * @param Generic_Object $object The ActivityPub object. - * - * @return array The filtered array of the ActivityPub object. - */ - return \apply_filters( "activitypub_activity_{$class}_object_array", $array, $this->id, $this ); - } - - /** - * Convert Object to JSON. - * - * @param bool $include_json_ld_context Whether to include the JSON-LD context. Default true. - * - * @return string The JSON string. - */ - public function to_json( $include_json_ld_context = true ) { - $array = $this->to_array( $include_json_ld_context ); - $options = \JSON_HEX_TAG | \JSON_HEX_AMP | \JSON_HEX_QUOT | \JSON_UNESCAPED_SLASHES; - - /** - * Options to be passed to json_encode(). - * - * @param int $options The current options flags. - */ - $options = \apply_filters( 'activitypub_json_encode_options', $options ); - - return \wp_json_encode( $array, $options ); - } - - /** - * Returns the keys of the object vars. - * - * @return array The keys of the object vars. - */ - public function get_object_var_keys() { - return \array_keys( \get_object_vars( $this ) ); - } - - /** - * Returns the JSON-LD context of this object. - * - * @return array $context A compacted JSON-LD context for the ActivityPub object. - */ - public function get_json_ld_context() { - return static::JSON_LD_CONTEXT; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/extended-object/class-event.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/extended-object/class-event.php deleted file mode 100644 index a44c2c66..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/extended-object/class-event.php +++ /dev/null @@ -1,379 +0,0 @@ - 'https://joinpeertube.org/ns#', - 'mz' => 'https://joinmobilizon.org/ns#', - 'status' => 'http://www.w3.org/2002/12/cal/ical#status', - 'commentsEnabled' => 'pt:commentsEnabled', - 'isOnline' => 'mz:isOnline', - 'timezone' => 'mz:timezone', - 'participantCount' => 'mz:participantCount', - 'anonymousParticipationEnabled' => 'mz:anonymousParticipationEnabled', - 'joinMode' => array( - '@id' => 'mz:joinMode', - '@type' => 'mz:joinModeType', - ), - 'externalParticipationUrl' => array( - '@id' => 'mz:externalParticipationUrl', - '@type' => 'schema:URL', - ), - 'repliesModerationOption' => array( - '@id' => 'mz:repliesModerationOption', - '@type' => '@vocab', - ), - 'contacts' => array( - '@id' => 'mz:contacts', - '@type' => '@id', - ), - ), - ); - - /** - * Mobilizon compatible values for repliesModerationOption. - * - * @var array - */ - const REPLIES_MODERATION_OPTION_TYPES = array( 'allow_all', 'closed' ); - - /** - * Mobilizon compatible values for joinModeTypes. - */ - const JOIN_MODE_TYPES = array( 'free', 'restricted', 'external' ); // and 'invite', but not used by mobilizon atm. - - /** - * Allowed values for ical VEVENT STATUS. - * - * @var array - */ - const ICAL_EVENT_STATUS_TYPES = array( 'TENTATIVE', 'CONFIRMED', 'CANCELLED' ); - - /** - * Default event categories. - * - * These values currently reflect the default set as proposed by Mobilizon to maximize interoperability. - * - * @var array - */ - const DEFAULT_EVENT_CATEGORIES = array( - 'ARTS', - 'BOOK_CLUBS', - 'BUSINESS', - 'CAUSES', - 'COMEDY', - 'CRAFTS', - 'FOOD_DRINK', - 'HEALTH', - 'MUSIC', - 'AUTO_BOAT_AIR', - 'COMMUNITY', - 'FAMILY_EDUCATION', - 'FASHION_BEAUTY', - 'FILM_MEDIA', - 'GAMES', - 'LANGUAGE_CULTURE', - 'LEARNING', - 'LGBTQ', - 'MOVEMENTS_POLITICS', - 'NETWORKING', - 'PARTY', - 'PERFORMING_VISUAL_ARTS', - 'PETS', - 'PHOTOGRAPHY', - 'OUTDOORS_ADVENTURE', - 'SPIRITUALITY_RELIGION_BELIEFS', - 'SCIENCE_TECH', - 'SPORTS', - 'THEATRE', - 'MEETING', // Default value. - ); - - /** - * Event is an implementation of one of the Activity Streams. - * - * @var string - */ - protected $type = 'Event'; - - /** - * The Title of the event. - * - * @var string - */ - protected $name; - - /** - * The events contacts. - * - * @context { - * '@id' => 'mz:contacts', - * '@type' => '@id', - * } - * - * @var array Array of contacts (ActivityPub actor IDs). - */ - protected $contacts; - - /** - * Extension invented by PeerTube whether comments/replies are - * Mobilizon also implemented this as a fallback to their own - * repliesModerationOption. - * - * @see https://docs.joinpeertube.org/api/activitypub#video - * @see https://docs.joinmobilizon.org/contribute/activity_pub/ - * @var bool|null - */ - protected $comments_enabled; - - /** - * Timezone of the event. - * - * @context https://joinmobilizon.org/ns#timezone - * @var string - */ - protected $timezone; - - /** - * Moderation option for replies. - * - * @context https://joinmobilizon.org/ns#repliesModerationOption - * @see https://docs.joinmobilizon.org/contribute/activity_pub/#repliesmoderation - * @var string - */ - protected $replies_moderation_option; - - /** - * Whether anonymous participation is enabled. - * - * @context https://joinmobilizon.org/ns#anonymousParticipationEnabled - * @see https://docs.joinmobilizon.org/contribute/activity_pub/#anonymousparticipationenabled - * @var bool - */ - protected $anonymous_participation_enabled; - - /** - * The event's category. - * - * @context https://schema.org/category - * @var string - */ - protected $category; - - /** - * Language of the event. - * - * @context https://schema.org/inLanguage - * @var string - */ - protected $in_language; - - /** - * Whether the event is online. - * - * @context https://joinmobilizon.org/ns#isOnline - * @var bool - */ - protected $is_online; - - /** - * The event's status. - * - * @context https://www.w3.org/2002/12/cal/ical#status - * @var string - */ - protected $status; - - /** - * Which actor created the event. - * - * This field is needed due to the current group structure of Mobilizon. - * - * @todo this seems to not be a default property of an Object but needed by mobilizon. - * @var string - */ - protected $actor; - - /** - * The external participation URL. - * - * @context https://joinmobilizon.org/ns#externalParticipationUrl - * @var string - */ - protected $external_participation_url; - - /** - * Indicator of how new members may be able to join. - * - * @context https://joinmobilizon.org/ns#joinMode - * @see https://docs.joinmobilizon.org/contribute/activity_pub/#joinmode - * @var string - */ - protected $join_mode; - - /** - * The participant count of the event. - * - * @context https://joinmobilizon.org/ns#participantCount - * @var int - */ - protected $participant_count; - - /** - * How many places there can be for an event. - * - * @context https://schema.org/maximumAttendeeCapacity - * @see https://docs.joinmobilizon.org/contribute/activity_pub/#maximumattendeecapacity - * @var int - */ - protected $maximum_attendee_capacity; - - /** - * The number of attendee places for an event that remain unallocated. - * - * @context https://schema.org/remainingAttendeeCapacity - * @see https://docs.joinmobilizon.org/contribute/activity_pub/#remainignattendeecapacity - * @var int - */ - protected $remaining_attendee_capacity; - - /** - * Setter for the timezone. - * - * The passed timezone is only set when it is a valid one, otherwise the site's timezone is used. - * - * @param string $timezone The timezone string to be set, e.g. 'Europe/Berlin'. - * @return Event - */ - public function set_timezone( $timezone ) { - if ( in_array( $timezone, timezone_identifiers_list(), true ) ) { - $this->timezone = $timezone; - } else { - $this->timezone = wp_timezone_string(); - } - - return $this; - } - - /** - * Custom setter for repliesModerationOption which also directly sets commentsEnabled accordingly. - * - * @param string $type The type of the replies moderation option. - * - * @return Event - */ - public function set_replies_moderation_option( $type ) { - if ( in_array( $type, self::REPLIES_MODERATION_OPTION_TYPES, true ) ) { - $this->replies_moderation_option = $type; - $this->comments_enabled = ( 'allow_all' === $type ) ? true : false; - } else { - _doing_it_wrong( - __METHOD__, - 'The replies moderation option must be either allow_all or closed.', - '' - ); - } - - return $this; - } - - /** - * Custom setter for commentsEnabled which also directly sets repliesModerationOption accordingly. - * - * @param bool $comments_enabled Whether comments are enabled. - * - * @return Event - */ - public function set_comments_enabled( $comments_enabled ) { - if ( is_bool( $comments_enabled ) ) { - $this->comments_enabled = $comments_enabled; - $this->replies_moderation_option = $comments_enabled ? 'allow_all' : 'closed'; - } else { - _doing_it_wrong( - __METHOD__, - 'The commentsEnabled must be boolean.', - '' - ); - } - - return $this; - } - - /** - * Custom setter for the ical status that checks whether the status is an ical event status. - * - * @param string $status The status of the event. - * - * @return Event - */ - public function set_status( $status ) { - if ( in_array( $status, self::ICAL_EVENT_STATUS_TYPES, true ) ) { - $this->status = $status; - } else { - _doing_it_wrong( - __METHOD__, - 'The status of the event must be a VEVENT iCal status.', - '' - ); - } - - return $this; - } - - /** - * Custom setter for the event category. - * - * Falls back to Mobilizon's default category. - * - * @param string $category The category of the event. - * @param bool $mobilizon_compatibility Optional. Whether the category must be compatibly with Mobilizon. Default true. - * - * @return Event - */ - public function set_category( $category, $mobilizon_compatibility = true ) { - if ( $mobilizon_compatibility ) { - $this->category = in_array( $category, self::DEFAULT_EVENT_CATEGORIES, true ) ? $category : 'MEETING'; - } else { - $this->category = $category; - } - - return $this; - } - - /** - * Custom setter for an external participation url. - * - * Automatically sets the joinMode to true if called. - * - * @param string $url The URL for external participation. - * - * @return Event - */ - public function set_external_participation_url( $url ) { - if ( preg_match( '/^https?:\/\/.*/i', $url ) ) { - $this->external_participation_url = $url; - $this->join_mode = 'external'; - } - - return $this; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/extended-object/class-place.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/extended-object/class-place.php deleted file mode 100644 index 1bf7419b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/activity/extended-object/class-place.php +++ /dev/null @@ -1,105 +0,0 @@ -= 0.0f, <= 100.0f] - */ - protected $accuracy; - - /** - * Indicates the altitude of a place. The measurement unit is indicated using the unit's property. - * If unit is not specified, the default is assumed to be "m" indicating meters. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-altitude - * @var float xsd:float - */ - protected $altitude; - - /** - * The latitude of a place. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-latitude - * @var float xsd:float - */ - protected $latitude; - - /** - * The longitude of a place. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-longitude - * @var float xsd:float - */ - protected $longitude; - - /** - * The radius from the given latitude and longitude for a Place. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-radius - * @var float - */ - protected $radius; - - /** - * Specifies the measurement units for the `radius` and `altitude` properties. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-units - * @var string - */ - protected $units; - - /** - * The address of the place. - * - * @see https://schema.org/PostalAddress - * @var array|string - */ - protected $address; - - /** - * Set the address of the place. - * - * @param array|string $address The address of the place. - */ - public function set_address( $address ) { - if ( is_string( $address ) || is_array( $address ) ) { - $this->address = $address; - } else { - _doing_it_wrong( - __METHOD__, - 'The address must be either a string or an array like schema.org/PostalAddress.', - '' - ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-activitypub.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-activitypub.php deleted file mode 100644 index 9299dc09..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-activitypub.php +++ /dev/null @@ -1,898 +0,0 @@ -get_activitypub_object(); - - if ( $activitypub_object ) { - if ( \get_query_var( 'preview' ) ) { - \define( 'ACTIVITYPUB_PREVIEW', true ); - - /** - * Filter the template used for the ActivityPub preview. - * - * @param string $activitypub_template Absolute path to the template file. - */ - $activitypub_template = apply_filters( 'activitypub_preview_template', ACTIVITYPUB_PLUGIN_DIR . '/templates/post-preview.php' ); - } else { - $activitypub_template = ACTIVITYPUB_PLUGIN_DIR . 'templates/activitypub-json.php'; - } - } - - /* - * Check if the request is authorized. - * - * @see https://www.w3.org/wiki/SocialCG/ActivityPub/Primer/Authentication_Authorization#Authorized_fetch - * @see https://swicg.github.io/activitypub-http-signature/#authorized-fetch - */ - if ( $activitypub_template && use_authorized_fetch() ) { - $verification = Signature::verify_http_signature( $_SERVER ); - if ( \is_wp_error( $verification ) ) { - header( 'HTTP/1.1 401 Unauthorized' ); - - // Fallback as template_loader can't return http headers. - return $template; - } - } - - if ( $activitypub_template ) { - \set_query_var( 'is_404', false ); - - // Check if header already sent. - if ( ! \headers_sent() ) { - // Send 200 status header. - \status_header( 200 ); - } - - return $activitypub_template; - } - - return $template; - } - - /** - * Add the 'self' link to the header. - */ - public static function add_headers() { - $id = Query::get_instance()->get_activitypub_object_id(); - - if ( ! $id ) { - return; - } - - if ( ! headers_sent() ) { - \header( 'Link: <' . esc_url( $id ) . '>; title="ActivityPub (JSON)"; rel="alternate"; type="application/activity+json"', false ); - - if ( \get_option( 'activitypub_vary_header' ) ) { - // Send Vary header for Accept header. - \header( 'Vary: Accept', false ); - } - } - - add_action( - 'wp_head', - function () use ( $id ) { - echo PHP_EOL . '' . PHP_EOL; - } - ); - } - - /** - * Remove trailing slash from ActivityPub @username requests. - * - * @param string $redirect_url The URL to redirect to. - * @param string $requested_url The requested URL. - * - * @return string $redirect_url The possibly-unslashed redirect URL. - */ - public static function no_trailing_redirect( $redirect_url, $requested_url ) { - if ( get_query_var( 'actor' ) ) { - return $requested_url; - } - - return $redirect_url; - } - - /** - * Add support for `p` and `author` query vars. - * - * @param string $redirect_url The URL to redirect to. - * @param string $requested_url The requested URL. - * - * @return string $redirect_url - */ - public static function redirect_canonical( $redirect_url, $requested_url ) { - if ( ! is_activitypub_request() ) { - return $redirect_url; - } - - $query = \wp_parse_url( $requested_url, PHP_URL_QUERY ); - - if ( ! $query ) { - return $redirect_url; - } - - $query_params = \wp_parse_args( $query ); - unset( $query_params['activitypub'] ); - - if ( 1 !== count( $query_params ) ) { - return $redirect_url; - } - - if ( isset( $query_params['p'] ) ) { - return null; - } - - if ( isset( $query_params['author'] ) ) { - return null; - } - - return $requested_url; - } - - /** - * Custom redirects for ActivityPub requests. - * - * @return void - */ - public static function template_redirect() { - global $wp_query; - - $comment_id = get_query_var( 'c', null ); - - // Check if it seems to be a comment. - if ( $comment_id ) { - $comment = get_comment( $comment_id ); - - // Load a 404-page if `c` is set but not valid. - if ( ! $comment ) { - $wp_query->set_404(); - return; - } - - // Stop if it's not an ActivityPub comment. - if ( is_activitypub_request() && ! is_local_comment( $comment ) ) { - return; - } - - wp_safe_redirect( get_comment_link( $comment ) ); - exit; - } - - $actor = get_query_var( 'actor', null ); - if ( $actor ) { - $actor = Actors::get_by_username( $actor ); - if ( ! $actor || \is_wp_error( $actor ) ) { - $wp_query->set_404(); - return; - } - - if ( is_activitypub_request() ) { - return; - } - - if ( $actor->get__id() > 0 ) { - $redirect_url = $actor->get_url(); - } else { - $redirect_url = get_bloginfo( 'url' ); - } - - wp_safe_redirect( $redirect_url, 301 ); - exit; - } - } - - /** - * Add the 'activitypub' query variable so WordPress won't mangle it. - * - * @param array $vars The query variables. - * - * @return array The query variables. - */ - public static function add_query_vars( $vars ) { - $vars[] = 'activitypub'; - $vars[] = 'preview'; - $vars[] = 'author'; - $vars[] = 'actor'; - $vars[] = 'c'; - $vars[] = 'p'; - - return $vars; - } - - /** - * Replaces the default avatar. - * - * @param array $args Arguments passed to get_avatar_data(), after processing. - * @param int|string|object $id_or_email A user ID, email address, or comment object. - * - * @return array $args - */ - public static function pre_get_avatar_data( $args, $id_or_email ) { - if ( - ! $id_or_email instanceof \WP_Comment || - ! isset( $id_or_email->comment_type ) || - $id_or_email->user_id - ) { - return $args; - } - - $allowed_comment_types = \apply_filters( 'get_avatar_comment_types', array( 'comment' ) ); - if ( - ! empty( $id_or_email->comment_type ) && - ! \in_array( - $id_or_email->comment_type, - (array) $allowed_comment_types, - true - ) - ) { - $args['url'] = false; - /** This filter is documented in wp-includes/link-template.php */ - return \apply_filters( 'get_avatar_data', $args, $id_or_email ); - } - - // Check if comment has an avatar. - $avatar = \get_comment_meta( $id_or_email->comment_ID, 'avatar_url', true ); - - if ( $avatar ) { - if ( empty( $args['class'] ) ) { - $args['class'] = array(); - } elseif ( \is_string( $args['class'] ) ) { - $args['class'] = \explode( ' ', $args['class'] ); - } - - $args['url'] = $avatar; - $args['class'][] = 'avatar-activitypub'; - $args['class'][] = 'u-photo'; - $args['class'] = \array_unique( $args['class'] ); - } - - return $args; - } - - /** - * Store permalink in meta, to send delete Activity. - * - * @param string $post_id The Post ID. - */ - public static function trash_post( $post_id ) { - \add_post_meta( - $post_id, - '_activitypub_canonical_url', - \get_permalink( $post_id ), - true - ); - } - - /** - * Delete permalink from meta. - * - * @param string $post_id The Post ID. - */ - public static function untrash_post( $post_id ) { - \delete_post_meta( $post_id, '_activitypub_canonical_url' ); - } - - /** - * Add rewrite rules. - */ - public static function add_rewrite_rules() { - /* - * If another system needs to take precedence over the ActivityPub rewrite rules, - * they can define their own and will manually call the appropriate functions as required. - */ - if ( ACTIVITYPUB_DISABLE_REWRITES ) { - return; - } - - if ( ! \class_exists( 'Webfinger' ) ) { - \add_rewrite_rule( - '^.well-known/webfinger', - 'index.php?rest_route=/' . ACTIVITYPUB_REST_NAMESPACE . '/webfinger', - 'top' - ); - } - - if ( ! \class_exists( 'Nodeinfo_Endpoint' ) && true === (bool) \get_option( 'blog_public', 1 ) ) { - \add_rewrite_rule( - '^.well-known/nodeinfo', - 'index.php?rest_route=/' . ACTIVITYPUB_REST_NAMESPACE . '/nodeinfo', - 'top' - ); - } - - \add_rewrite_rule( '^@([\w\-\.]+)\/?$', 'index.php?actor=$matches[1]', 'top' ); - \add_rewrite_endpoint( 'activitypub', EP_AUTHORS | EP_PERMALINK | EP_PAGES ); - } - - /** - * Flush rewrite rules. - */ - public static function flush_rewrite_rules() { - self::add_rewrite_rules(); - \flush_rewrite_rules(); - } - - /** - * Theme compatibility stuff. - */ - public static function theme_compat() { - // We assume that you want to use Post-Formats when enabling the setting. - if ( 'wordpress-post-format' === \get_option( 'activitypub_object_type', ACTIVITYPUB_DEFAULT_OBJECT_TYPE ) ) { - if ( ! get_theme_support( 'post-formats' ) ) { - // Add support for the Aside, Gallery Post Formats... - add_theme_support( - 'post-formats', - array( - 'gallery', - 'status', - 'image', - 'video', - 'audio', - ) - ); - } - } - } - - /** - * Register Custom Post Types. - */ - private static function register_post_types() { - \register_post_type( - Followers::POST_TYPE, - array( - 'labels' => array( - 'name' => _x( 'Followers', 'post_type plural name', 'activitypub' ), - 'singular_name' => _x( 'Follower', 'post_type single name', 'activitypub' ), - ), - 'public' => false, - 'hierarchical' => false, - 'rewrite' => false, - 'query_var' => false, - 'delete_with_user' => false, - 'can_export' => true, - 'supports' => array(), - ) - ); - - \register_post_meta( - Followers::POST_TYPE, - '_activitypub_inbox', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => 'sanitize_url', - ) - ); - - \register_post_meta( - Followers::POST_TYPE, - '_activitypub_errors', - array( - 'type' => 'string', - 'single' => false, - 'sanitize_callback' => function ( $value ) { - if ( ! is_string( $value ) ) { - throw new Exception( 'Error message is no valid string' ); - } - - return esc_sql( $value ); - }, - ) - ); - - \register_post_meta( - Followers::POST_TYPE, - '_activitypub_user_id', - array( - 'type' => 'string', - 'single' => false, - 'sanitize_callback' => function ( $value ) { - return esc_sql( $value ); - }, - ) - ); - - \register_post_meta( - Followers::POST_TYPE, - '_activitypub_actor_json', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => function ( $value ) { - return sanitize_text_field( $value ); - }, - ) - ); - - // Register Outbox Post-Type. - register_post_type( - Outbox::POST_TYPE, - array( - 'labels' => array( - 'name' => _x( 'Outbox', 'post_type plural name', 'activitypub' ), - 'singular_name' => _x( 'Outbox Item', 'post_type single name', 'activitypub' ), - ), - 'capabilities' => array( - 'create_posts' => false, - ), - 'map_meta_cap' => true, - 'public' => false, - 'show_in_rest' => true, - 'rewrite' => false, - 'query_var' => false, - 'supports' => array( 'title', 'editor', 'author', 'custom-fields' ), - 'delete_with_user' => true, - 'can_export' => true, - 'exclude_from_search' => true, - ) - ); - - /** - * Register Activity Type meta for Outbox items. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#activity-types - */ - \register_post_meta( - Outbox::POST_TYPE, - '_activitypub_activity_type', - array( - 'type' => 'string', - 'description' => 'The type of the activity', - 'single' => true, - 'show_in_rest' => true, - 'sanitize_callback' => function ( $value ) { - $value = ucfirst( strtolower( $value ) ); - $schema = array( - 'type' => 'string', - 'enum' => array( 'Accept', 'Add', 'Announce', 'Arrive', 'Block', 'Create', 'Delete', 'Dislike', 'Flag', 'Follow', 'Ignore', 'Invite', 'Join', 'Leave', 'Like', 'Listen', 'Move', 'Offer', 'Question', 'Reject', 'Read', 'Remove', 'TentativeReject', 'TentativeAccept', 'Travel', 'Undo', 'Update', 'View' ), - 'default' => 'Announce', - ); - - if ( is_wp_error( rest_validate_enum( $value, $schema, '' ) ) ) { - return $schema['default']; - } - - return $value; - }, - ) - ); - - \register_post_meta( - Outbox::POST_TYPE, - '_activitypub_activity_actor', - array( - 'type' => 'string', - 'single' => true, - 'show_in_rest' => true, - 'sanitize_callback' => function ( $value ) { - $schema = array( - 'type' => 'string', - 'enum' => array( 'application', 'blog', 'user' ), - 'default' => 'user', - ); - - if ( is_wp_error( rest_validate_enum( $value, $schema, '' ) ) ) { - return $schema['default']; - } - - return $value; - }, - ) - ); - - \register_post_meta( - Outbox::POST_TYPE, - '_activitypub_outbox_offset', - array( - 'type' => 'integer', - 'single' => true, - 'description' => 'Keeps track of the followers offset when processing outbox items.', - 'sanitize_callback' => 'absint', - 'default' => 0, - ) - ); - - \register_post_meta( - Outbox::POST_TYPE, - '_activitypub_object_id', - array( - 'type' => 'string', - 'single' => true, - 'description' => 'The ID (ActivityPub URI) of the object that the outbox item is about.', - 'sanitize_callback' => 'sanitize_url', - ) - ); - - \register_post_meta( - Outbox::POST_TYPE, - 'activitypub_content_visibility', - array( - 'type' => 'string', - 'single' => true, - 'show_in_rest' => true, - 'sanitize_callback' => function ( $value ) { - $schema = array( - 'type' => 'string', - 'enum' => array( ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC, ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC, ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE, ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL ), - 'default' => ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC, - ); - - if ( is_wp_error( rest_validate_enum( $value, $schema, '' ) ) ) { - return $schema['default']; - } - - return $value; - }, - ) - ); - - // Both User and Blog Extra Fields types have the same args. - $args = array( - 'labels' => array( - 'name' => _x( 'Extra fields', 'post_type plural name', 'activitypub' ), - 'singular_name' => _x( 'Extra field', 'post_type single name', 'activitypub' ), - 'add_new' => __( 'Add new', 'activitypub' ), - 'add_new_item' => __( 'Add new extra field', 'activitypub' ), - 'new_item' => __( 'New extra field', 'activitypub' ), - 'edit_item' => __( 'Edit extra field', 'activitypub' ), - 'view_item' => __( 'View extra field', 'activitypub' ), - 'all_items' => __( 'All extra fields', 'activitypub' ), - ), - 'public' => false, - 'hierarchical' => false, - 'query_var' => false, - 'has_archive' => false, - 'publicly_queryable' => false, - 'show_in_menu' => false, - 'delete_with_user' => true, - 'can_export' => true, - 'exclude_from_search' => true, - 'show_in_rest' => true, - 'map_meta_cap' => true, - 'show_ui' => true, - 'supports' => array( 'title', 'editor', 'page-attributes' ), - ); - - \register_post_type( Extra_Fields::USER_POST_TYPE, $args ); - \register_post_type( Extra_Fields::BLOG_POST_TYPE, $args ); - - /** - * Fires after ActivityPub custom post types have been registered. - */ - \do_action( 'activitypub_after_register_post_type' ); - } - - /** - * Add the 'activitypub' capability to users who can publish posts. - * - * @param int $user_id User ID. - */ - public static function user_register( $user_id ) { - if ( \user_can( $user_id, 'publish_posts' ) ) { - $user = \get_user_by( 'id', $user_id ); - $user->add_cap( 'activitypub' ); - } - } - - /** - * Delete `activitypub_content_visibility` when updated to an empty value. - * - * @param int $meta_id ID of updated metadata entry. - * @param int $object_id Post ID. - * @param string $meta_key Metadata key. - * @param mixed $meta_value Metadata value. This will be a PHP-serialized string representation of the value - * if the value is an array, an object, or itself a PHP-serialized string. - */ - public static function updated_postmeta( $meta_id, $object_id, $meta_key, $meta_value ) { - if ( 'activitypub_content_visibility' === $meta_key && empty( $meta_value ) ) { - \delete_post_meta( $object_id, 'activitypub_content_visibility' ); - } - } - - /** - * Register some Mastodon oEmbed providers. - */ - public static function register_oembed_providers() { - \wp_oembed_add_provider( '#https?://mastodon\.social/(@.+)/([0-9]+)#i', 'https://mastodon.social/api/oembed', true ); - \wp_oembed_add_provider( '#https?://mastodon\.online/(@.+)/([0-9]+)#i', 'https://mastodon.online/api/oembed', true ); - \wp_oembed_add_provider( '#https?://mastodon\.cloud/(@.+)/([0-9]+)#i', 'https://mastodon.cloud/api/oembed', true ); - \wp_oembed_add_provider( '#https?://mstdn\.social/(@.+)/([0-9]+)#i', 'https://mstdn.social/api/oembed', true ); - \wp_oembed_add_provider( '#https?://mastodon\.world/(@.+)/([0-9]+)#i', 'https://mastodon.world/api/oembed', true ); - \wp_oembed_add_provider( '#https?://mas\.to/(@.+)/([0-9]+)#i', 'https://mas.to/api/oembed', true ); - } - - /** - * Register user meta. - */ - public static function register_user_meta() { - $blog_prefix = $GLOBALS['wpdb']->get_blog_prefix(); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_also_known_as', - array( - 'type' => 'array', - 'description' => 'An array of URLs that the user is known by.', - 'single' => true, - 'default' => array(), - 'sanitize_callback' => array( Sanitize::class, 'url_list' ), - ) - ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_old_host_data', - array( - 'description' => 'Actor object for the user on the old host.', - 'single' => true, - ) - ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_moved_to', - array( - 'type' => 'string', - 'description' => 'The new URL of the user.', - 'single' => true, - 'sanitize_callback' => 'sanitize_url', - ) - ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_description', - array( - 'type' => 'string', - 'description' => 'The user’s description.', - 'single' => true, - 'default' => '', - 'sanitize_callback' => function ( $value ) { - return wp_kses( $value, 'user_description' ); - }, - ) - ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_icon', - array( - 'type' => 'integer', - 'description' => 'The attachment ID for user’s profile image.', - 'single' => true, - 'default' => 0, - 'sanitize_callback' => 'absint', - ) - ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_header_image', - array( - 'type' => 'integer', - 'description' => 'The attachment ID for the user’s header image.', - 'single' => true, - 'default' => 0, - 'sanitize_callback' => 'absint', - ) - ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_mailer_new_dm', - array( - 'type' => 'integer', - 'description' => 'Send a notification when someone sends this user a direct message.', - 'single' => true, - 'sanitize_callback' => 'absint', - ) - ); - \add_filter( 'get_user_option_activitypub_mailer_new_dm', array( self::class, 'user_options_default' ) ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_mailer_new_follower', - array( - 'type' => 'integer', - 'description' => 'Send a notification when someone starts to follow this user.', - 'single' => true, - 'sanitize_callback' => 'absint', - ) - ); - \add_filter( 'get_user_option_activitypub_mailer_new_follower', array( self::class, 'user_options_default' ) ); - - \register_meta( - 'user', - $blog_prefix . 'activitypub_mailer_new_mention', - array( - 'type' => 'integer', - 'description' => 'Send a notification when someone mentions this user.', - 'single' => true, - 'sanitize_callback' => 'absint', - ) - ); - \add_filter( 'get_user_option_activitypub_mailer_new_mention', array( self::class, 'user_options_default' ) ); - - \register_meta( - 'user', - 'activitypub_show_welcome_tab', - array( - 'type' => 'integer', - 'description' => 'Whether to show the welcome tab.', - 'single' => true, - 'default' => 1, - 'sanitize_callback' => 'absint', - ) - ); - - \register_meta( - 'user', - 'activitypub_show_advanced_tab', - array( - 'type' => 'integer', - 'description' => 'Whether to show the advanced tab.', - 'single' => true, - 'default' => 0, - 'sanitize_callback' => 'absint', - ) - ); - } - - /** - * Set default values for user options. - * - * @param bool|string $value Option value. - * @return bool|string - */ - public static function user_options_default( $value ) { - if ( false === $value ) { - return '1'; - } - - return $value; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-autoloader.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-autoloader.php deleted file mode 100644 index 232a8323..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-autoloader.php +++ /dev/null @@ -1,106 +0,0 @@ -prefix = $prefix; - $this->prefix_length = \strlen( $prefix ); - $this->path = \rtrim( $path . '/' ); - } - - /** - * Registers Autoloader's autoload function. - * - * @throws \Exception When autoload_function cannot be registered. - * - * @param string $prefix Namespace prefix all classes have in common. - * @param string $path Path to the files to be loaded. - */ - public static function register_path( $prefix, $path ) { - $loader = new self( $prefix, $path ); - \spl_autoload_register( array( $loader, 'load' ) ); - } - - /** - * Loads a class if its namespace starts with `$this->prefix`. - * - * @param string $class_name The class to be loaded. - */ - public function load( $class_name ) { - if ( \strpos( $class_name, $this->prefix . self::NS_SEPARATOR ) !== 0 ) { - return; - } - - // Strip prefix from the start (ala PSR-4). - $class_name = \substr( $class_name, $this->prefix_length + 1 ); - $class_name = \strtolower( $class_name ); - $dir = ''; - - $last_ns_pos = \strripos( $class_name, self::NS_SEPARATOR ); - if ( false !== $last_ns_pos ) { - $namespace = \substr( $class_name, 0, $last_ns_pos ); - $namespace = \str_replace( '_', '-', $namespace ); - $class_name = \substr( $class_name, $last_ns_pos + 1 ); - $dir = \str_replace( self::NS_SEPARATOR, DIRECTORY_SEPARATOR, $namespace ) . DIRECTORY_SEPARATOR; - } - - $path = $this->path . $dir . 'class-' . \str_replace( '_', '-', $class_name ) . '.php'; - - if ( ! \file_exists( $path ) ) { - $path = $this->path . $dir . 'interface-' . \str_replace( '_', '-', $class_name ) . '.php'; - } - - if ( ! \file_exists( $path ) ) { - $path = $this->path . $dir . 'trait-' . \str_replace( '_', '-', $class_name ) . '.php'; - } - - if ( \file_exists( $path ) ) { - require_once $path; - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-blocks.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-blocks.php deleted file mode 100644 index 80989af2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-blocks.php +++ /dev/null @@ -1,446 +0,0 @@ - true, - 'single' => true, - 'type' => 'string', - 'sanitize_callback' => function ( $warning ) { - if ( $warning ) { - return \sanitize_text_field( $warning ); - } - - return null; - }, - ) - ); - - \register_post_meta( - $post_type, - 'activitypub_content_visibility', - array( - 'type' => 'string', - 'single' => true, - 'show_in_rest' => true, - 'sanitize_callback' => function ( $value ) { - $schema = array( - 'type' => 'string', - 'enum' => array( ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC, ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC, ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE, ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL ), - 'default' => ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC, - ); - - if ( is_wp_error( rest_validate_enum( $value, $schema, '' ) ) ) { - return $schema['default']; - } - - return $value; - }, - ) - ); - } - } - - /** - * Enqueue the block editor assets. - */ - public static function enqueue_editor_assets() { - // Check for our supported post types. - $current_screen = \get_current_screen(); - $ap_post_types = \get_post_types_by_support( 'activitypub' ); - if ( ! $current_screen || ! in_array( $current_screen->post_type, $ap_post_types, true ) ) { - return; - } - $asset_data = include ACTIVITYPUB_PLUGIN_DIR . 'build/editor-plugin/plugin.asset.php'; - $plugin_url = plugins_url( 'build/editor-plugin/plugin.js', ACTIVITYPUB_PLUGIN_FILE ); - wp_enqueue_script( 'activitypub-block-editor', $plugin_url, $asset_data['dependencies'], $asset_data['version'], true ); - } - - /** - * Enqueue the reply handle script if the in_reply_to GET param is set. - */ - public static function handle_in_reply_to_get_param() { - // Only load the script if the in_reply_to GET param is set, action happens there, not here. - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! isset( $_GET['in_reply_to'] ) ) { - return; - } - - $asset_data = include ACTIVITYPUB_PLUGIN_DIR . 'build/reply-intent/plugin.asset.php'; - $plugin_url = plugins_url( 'build/reply-intent/plugin.js', ACTIVITYPUB_PLUGIN_FILE ); - wp_enqueue_script( 'activitypub-reply-intent', $plugin_url, $asset_data['dependencies'], $asset_data['version'], true ); - } - - /** - * Output ActivityPub options as a script tag. - */ - public static function inject_activitypub_options() { - $data = array( - 'namespace' => ACTIVITYPUB_REST_NAMESPACE, - 'defaultAvatarUrl' => ACTIVITYPUB_PLUGIN_URL . 'assets/img/mp.jpg', - 'enabled' => array( - 'site' => ! is_user_type_disabled( 'blog' ), - 'users' => ! is_user_type_disabled( 'user' ), - ), - ); - - printf( - "\n", - wp_json_encode( $data ) - ); - } - - /** - * Register the blocks. - */ - public static function register_blocks() { - \register_block_type_from_metadata( - ACTIVITYPUB_PLUGIN_DIR . '/build/followers', - array( - 'render_callback' => array( self::class, 'render_follower_block' ), - ) - ); - \register_block_type_from_metadata( - ACTIVITYPUB_PLUGIN_DIR . '/build/follow-me', - array( - 'render_callback' => array( self::class, 'render_follow_me_block' ), - ) - ); - \register_block_type_from_metadata( - ACTIVITYPUB_PLUGIN_DIR . '/build/reply', - array( - 'render_callback' => array( self::class, 'render_reply_block' ), - ) - ); - - \register_block_type_from_metadata( - ACTIVITYPUB_PLUGIN_DIR . '/build/reactions', - array( - 'render_callback' => array( self::class, 'render_post_reactions_block' ), - ) - ); - } - - /** - * Render the post reactions block. - * - * @param array $attrs The block attributes. - * - * @return string The HTML to render. - */ - public static function render_post_reactions_block( $attrs ) { - if ( ! isset( $attrs['postId'] ) ) { - $attrs['postId'] = get_the_ID(); - } - - $wrapper_attributes = get_block_wrapper_attributes( - array( - 'class' => 'activitypub-reactions-block', - 'data-attrs' => wp_json_encode( $attrs ), - ) - ); - - return sprintf( - '
', - $wrapper_attributes - ); - } - - /** - * Get the user ID from a user string. - * - * @param string $user_string The user string. Can be a user ID, 'site', or 'inherit'. - * @return int|null The user ID, or null if the 'inherit' string is not supported in this context. - */ - private static function get_user_id( $user_string ) { - if ( is_numeric( $user_string ) ) { - return absint( $user_string ); - } - - // If the user string is 'site', return the Blog User ID. - if ( 'site' === $user_string ) { - return Actors::BLOG_USER_ID; - } - - // The only other value should be 'inherit', which means to use the query context to determine the User. - if ( 'inherit' !== $user_string ) { - return null; - } - - // For a homepage/front page, if the Blog User is active, use it. - if ( ( is_front_page() || is_home() ) && ! is_user_type_disabled( 'blog' ) ) { - return Actors::BLOG_USER_ID; - } - - // If we're in a loop, use the post author. - $author_id = get_the_author_meta( 'ID' ); - if ( $author_id ) { - return $author_id; - } - - // For other pages, the queried object will clue us in. - $queried_object = get_queried_object(); - if ( ! $queried_object ) { - return null; - } - - // If we're on a user archive page, use that user's ID. - if ( is_a( $queried_object, 'WP_User' ) ) { - return $queried_object->ID; - } - - // For a single post, use the post author's ID. - if ( is_a( $queried_object, 'WP_Post' ) ) { - return get_the_author_meta( 'ID' ); - } - - // We won't properly account for some conditions, like tag archives. - return null; - } - - /** - * Filter an array by a list of keys. - * - * @param array $data The array to filter. - * @param array $keys The keys to keep. - * @return array The filtered array. - */ - protected static function filter_array_by_keys( $data, $keys ) { - return array_intersect_key( $data, array_flip( $keys ) ); - } - - /** - * Render the follow me block. - * - * @param array $attrs The block attributes. - * @return string The HTML to render. - */ - public static function render_follow_me_block( $attrs ) { - $user_id = self::get_user_id( $attrs['selectedUser'] ); - $user = Actors::get_by_id( $user_id ); - if ( is_wp_error( $user ) ) { - if ( 'inherit' === $attrs['selectedUser'] ) { - // If the user is 'inherit' and we couldn't determine the user, don't render anything. - return ''; - } else { - // If the user is a specific ID and we couldn't find it, render an error message. - return ''; - } - } - - $attrs['profileData'] = self::filter_array_by_keys( - $user->to_array(), - array( 'icon', 'name', 'webfinger' ) - ); - - $wrapper_attributes = get_block_wrapper_attributes( - array( - 'class' => 'activitypub-follow-me-block-wrapper', - 'data-attrs' => wp_json_encode( $attrs ), - ) - ); - // todo: render more than an empty div? - return '
'; - } - - /** - * Render the follower block. - * - * @param array $attrs The block attributes. - * - * @return string The HTML to render. - */ - public static function render_follower_block( $attrs ) { - $followee_user_id = self::get_user_id( $attrs['selectedUser'] ); - if ( is_null( $followee_user_id ) ) { - return ''; - } - - $user = Actors::get_by_id( $followee_user_id ); - if ( is_wp_error( $user ) ) { - return ''; - } - - $per_page = absint( $attrs['per_page'] ); - $follower_data = Followers::get_followers_with_count( $followee_user_id, $per_page ); - - $attrs['followerData']['total'] = $follower_data['total']; - $attrs['followerData']['followers'] = array_map( - function ( $follower ) { - return self::filter_array_by_keys( - $follower->to_array(), - array( 'icon', 'name', 'preferredUsername', 'url' ) - ); - }, - $follower_data['followers'] - ); - $wrapper_attributes = get_block_wrapper_attributes( - array( - 'aria-label' => __( 'Fediverse Followers', 'activitypub' ), - 'class' => 'activitypub-follower-block', - 'data-attrs' => wp_json_encode( $attrs ), - ) - ); - - $html = '
'; - if ( $attrs['title'] ) { - $html .= '

' . esc_html( $attrs['title'] ) . '

'; - } - $html .= '
    '; - foreach ( $follower_data['followers'] as $follower ) { - $html .= '
  • ' . self::render_follower( $follower ) . '
  • '; - } - // We are only pagination on the JS side. Could be revisited but we gotta ship! - $html .= '
'; - return $html; - } - - /** - * Render the reply block. - * - * @param array $attrs The block attributes. - * - * @return string The HTML to render. - */ - public static function render_reply_block( $attrs ) { - // Return early if no URL is provided. - if ( empty( $attrs['url'] ) ) { - return null; - } - - $show_embed = isset( $attrs['embedPost'] ) && $attrs['embedPost']; - - $wrapper_attrs = get_block_wrapper_attributes( - array( - 'aria-label' => __( 'Reply', 'activitypub' ), - 'class' => 'activitypub-reply-block', - 'data-in-reply-to' => $attrs['url'], - ) - ); - - $html = '
'; - - // Try to get and append the embed if requested. - if ( $show_embed ) { - $embed = wp_oembed_get( $attrs['url'] ); - if ( $embed ) { - $html .= $embed; - } - } - - // Only show the link if we're not showing the embed. - if ( ! $show_embed ) { - $html .= sprintf( - '

%3$s

', - esc_url( $attrs['url'] ), - esc_attr__( 'This post is a response to the referenced content.', 'activitypub' ), - // translators: %s is the URL of the post being replied to. - sprintf( __( '↬%s', 'activitypub' ), \str_replace( array( 'https://', 'http://' ), '', esc_url( $attrs['url'] ) ) ) - ); - } - - $html .= '
'; - - return $html; - } - - /** - * Render a follower. - * - * @param \Activitypub\Model\Follower $follower The follower to render. - * - * @return string The HTML to render. - */ - public static function render_follower( $follower ) { - $external_svg = ''; - $template = - ' - - - %s - / - @%s - - %s - '; - - $data = $follower->to_array(); - - return sprintf( - $template, - esc_url( object_to_uri( $data['url'] ) ), - esc_attr( $data['name'] ), - esc_attr( $data['icon']['url'] ), - esc_html( $data['name'] ), - esc_html( $data['preferredUsername'] ), - $external_svg - ); - } - - /** - * Converts content to blocks before saving to the database. - * - * @param array $data The post data to be inserted. - * @param object $post The Mastodon Create activity. - * - * @return array - */ - public static function filter_import_mastodon_post_data( $data, $post ) { - // Convert paragraphs to blocks. - \preg_match_all( '#

.*?

#is', $data['post_content'], $matches ); - $blocks = \array_map( - function ( $paragraph ) { - return '' . PHP_EOL . $paragraph . PHP_EOL . '' . PHP_EOL; - }, - $matches[0] ?? array() - ); - - $data['post_content'] = \rtrim( \implode( PHP_EOL, $blocks ), PHP_EOL ); - - // Add reply block if it's a reply. - if ( null !== $post->object->inReplyTo ) { - $reply_block = \sprintf( '' . PHP_EOL, \esc_url( $post->object->inReplyTo ) ); - $data['post_content'] = $reply_block . $data['post_content']; - } - - return $data; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-cli.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-cli.php deleted file mode 100644 index b5c9d224..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-cli.php +++ /dev/null @@ -1,230 +0,0 @@ - - * : The action to perform. Either `delete` or `update`. - * --- - * options: - * - delete - * - update - * --- - * - * - * : The id of the Post, Page, Custom Post Type or Attachment. - * - * ## EXAMPLES - * - * $ wp activitypub post delete 1 - * - * @synopsis - * - * @param array $args The arguments. - */ - public function post( $args ) { - $post = get_post( $args[1] ); - - if ( ! $post ) { - \WP_CLI::error( 'Post not found.' ); - } - - switch ( $args[0] ) { - case 'delete': - \WP_CLI::confirm( 'Do you really want to delete the (Custom) Post with the ID: ' . $args[1] ); - add_to_outbox( $post, 'Delete', $post->post_author ); - \WP_CLI::success( '"Delete" activity is queued.' ); - break; - case 'update': - add_to_outbox( $post, 'Update', $post->post_author ); - \WP_CLI::success( '"Update" activity is queued.' ); - break; - default: - \WP_CLI::error( 'Unknown action.' ); - } - } - - /** - * Delete or Update a Comment. - * - * ## OPTIONS - * - * - * : The action to perform. Either `delete` or `update`. - * --- - * options: - * - delete - * - update - * --- - * - * - * : The id of the Comment. - * - * ## EXAMPLES - * - * $ wp activitypub comment delete 1 - * - * @synopsis - * - * @param array $args The arguments. - */ - public function comment( $args ) { - $comment = get_comment( $args[1] ); - - if ( ! $comment ) { - \WP_CLI::error( 'Comment not found.' ); - } - - if ( was_comment_received( $comment ) ) { - \WP_CLI::error( 'This comment was received via ActivityPub and cannot be deleted or updated.' ); - } - - switch ( $args[0] ) { - case 'delete': - \WP_CLI::confirm( 'Do you really want to delete the Comment with the ID: ' . $args[1] ); - add_to_outbox( $comment, 'Delete', $comment->user_id ); - \WP_CLI::success( '"Delete" activity is queued.' ); - break; - case 'update': - add_to_outbox( $comment, 'Update', $comment->user_id ); - \WP_CLI::success( '"Update" activity is queued.' ); - break; - default: - \WP_CLI::error( 'Unknown action.' ); - } - } - - /** - * Undo an activity that was sent to the Fediverse. - * - * ## OPTIONS - * - * - * The ID or URL of the outbox item to undo. - * - * ## EXAMPLES - * - * $ wp activitypub undo 123 - * $ wp activitypub undo "https://example.com/?post_type=ap_outbox&p=123" - * - * @synopsis - * - * @param array $args The arguments. - */ - public function undo( $args ) { - $outbox_item_id = $args[0]; - if ( ! is_numeric( $outbox_item_id ) ) { - $outbox_item_id = url_to_postid( $outbox_item_id ); - } - - $outbox_item_id = get_post( $outbox_item_id ); - if ( ! $outbox_item_id ) { - \WP_CLI::error( 'Activity not found.' ); - } - - $undo_id = Outbox::undo( $outbox_item_id ); - if ( ! $undo_id ) { - \WP_CLI::error( 'Failed to undo activity.' ); - } - \WP_CLI::success( 'Undo activity scheduled.' ); - } - - /** - * Re-Schedule an activity that was sent to the Fediverse before. - * - * ## OPTIONS - * - * - * The ID or URL of the outbox item to reschedule. - * - * ## EXAMPLES - * - * $ wp activitypub reschedule 123 - * $ wp activitypub reschedule "https://example.com/?post_type=ap_outbox&p=123" - * - * @synopsis - * - * @param array $args The arguments. - */ - public function reschedule( $args ) { - $outbox_item_id = $args[0]; - if ( ! is_numeric( $outbox_item_id ) ) { - $outbox_item_id = url_to_postid( $outbox_item_id ); - } - - $outbox_item_id = get_post( $outbox_item_id ); - if ( ! $outbox_item_id ) { - \WP_CLI::error( 'Activity not found.' ); - } - - Outbox::reschedule( $outbox_item_id ); - - \WP_CLI::success( 'Rescheduled activity.' ); - } - - /** - * Move the blog to a new URL. - * - * ## OPTIONS - * - * - * The current URL of the blog. - * - * - * The new URL of the blog. - * - * ## EXAMPLES - * - * $ wp activitypub move https://example.com/ https://newsite.com/ - * - * @synopsis - * - * @param array $args The arguments. - */ - public function move( $args ) { - $from = $args[0]; - $to = $args[1]; - - $outbox_item_id = Move::account( $from, $to ); - - if ( is_wp_error( $outbox_item_id ) ) { - \WP_CLI::error( $outbox_item_id->get_error_message() ); - } else { - \WP_CLI::success( 'Move Scheduled.' ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-comment.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-comment.php deleted file mode 100644 index bfa8537e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-comment.php +++ /dev/null @@ -1,817 +0,0 @@ - self::generate_id( $comment ), - 'commentId' => $comment->comment_ID, - ); - - $div = sprintf( - '
', - esc_attr( wp_json_encode( $attrs ) ) - ); - - /** - * Filters the HTML markup for the ActivityPub remote comment reply container. - * - * @param string $div The HTML markup for the remote reply container. Default is a div - * with class 'activitypub-remote-reply' and data attributes for - * the selected comment ID and internal comment ID. - */ - return apply_filters( 'activitypub_comment_reply_link', $div ); - } - - /** - * Create a link to reply to a federated comment. - * - * This function adds a title attribute to the reply link to inform the user - * that the comment was received from the fediverse and the reply will be sent - * to the original author. - * - * @param string $link The HTML markup for the comment reply link. - * @param array $args The args provided by the `comment_reply_link` filter. - * - * @return string The modified HTML markup for the comment reply link. - */ - private static function create_fediverse_reply_link( $link, $args ) { - $str_to_replace = sprintf( '>%s<', $args['reply_text'] ); - $replace_with = sprintf( - ' title="%s">%s<', - esc_attr__( 'This comment was received from the fediverse and your reply will be sent to the original author', 'activitypub' ), - esc_html__( 'Reply with federation', 'activitypub' ) - ); - return str_replace( $str_to_replace, $replace_with, $link ); - } - - /** - * Check if it is allowed to comment to a comment. - * - * Checks if the comment is local only or if the user can comment federated comments. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the user can comment, false otherwise. - */ - public static function are_comments_allowed( $comment ) { - $comment = \get_comment( $comment ); - - if ( ! self::was_received( $comment ) ) { - return true; - } - - $current_user = get_current_user_id(); - - if ( ! $current_user ) { - return false; - } - - if ( is_single_user() && \user_can( $current_user, 'publish_posts' ) ) { - // On a single user site, comments by users with the `publish_posts` capability will be federated as the blog user. - $current_user = Actors::BLOG_USER_ID; - } - - return user_can_activitypub( $current_user ); - } - - /** - * Check if a comment is federated. - * - * We consider a comment federated if comment was received via ActivityPub. - * - * Use this function to check if it is comment that was received via ActivityPub. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment is federated, false otherwise. - */ - public static function was_received( $comment ) { - $comment = \get_comment( $comment ); - - if ( ! $comment ) { - return false; - } - - $protocol = \get_comment_meta( $comment->comment_ID, 'protocol', true ); - - if ( 'activitypub' === $protocol ) { - return true; - } - - return false; - } - - /** - * Check if a comment was federated. - * - * This function checks if a comment was federated via ActivityPub. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment was federated, false otherwise. - */ - public static function was_sent( $comment ) { - $comment = \get_comment( $comment ); - - if ( ! $comment ) { - return false; - } - - $status = \get_comment_meta( $comment->comment_ID, 'activitypub_status', true ); - - if ( $status ) { - return true; - } - - return false; - } - - /** - * Check if a comment is local only. - * - * This function checks if a comment is local only and was not sent or received via ActivityPub. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment is local only, false otherwise. - */ - public static function is_local( $comment ) { - if ( self::was_sent( $comment ) || self::was_received( $comment ) ) { - return false; - } - - return true; - } - - /** - * Check if a comment should be federated. - * - * We consider a comment should be federated if it is authored by a user that is - * not disabled for federation and if it is a reply directly to the post or to a - * federated comment. - * - * Use this function to check if a comment should be federated. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment should be federated, false otherwise. - */ - public static function should_be_federated( $comment ) { - // We should not federate federated comments. - if ( self::was_received( $comment ) ) { - return false; - } - - $comment = \get_comment( $comment ); - $user_id = $comment->user_id; - - // Comments without user can't be federated. - if ( ! $user_id ) { - return false; - } - - if ( is_single_user() && \user_can( $user_id, 'activitypub' ) ) { - // On a single user site, comments by users with the `publish_posts` capability will be federated as the blog user. - $user_id = Actors::BLOG_USER_ID; - } - - // User is not allowed to federate comments. - if ( ! user_can_activitypub( $user_id ) ) { - return false; - } - - // It is a comment to the post and can be federated. - if ( empty( $comment->comment_parent ) ) { - return true; - } - - // Check if parent comment is federated. - $parent_comment = \get_comment( $comment->comment_parent ); - - return ! self::is_local( $parent_comment ); - } - - /** - * Examine a comment ID and look up an existing comment it represents. - * - * @param string $id ActivityPub object ID (usually a URL) to check. - * - * @return \WP_Comment|false Comment object, or false on failure. - */ - public static function object_id_to_comment( $id ) { - $comment_query = new WP_Comment_Query( - array( - 'meta_key' => 'source_id', // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_key - 'meta_value' => $id, // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_value - 'orderby' => 'comment_date', - 'order' => 'DESC', - ) - ); - - if ( ! $comment_query->comments ) { - return false; - } - - return $comment_query->comments[0]; - } - - /** - * Verify if URL is a local comment, or if it is a previously received - * remote comment (For threading comments locally). - * - * @param string $url The URL to check. - * - * @return string|null Comment ID or null if not found. - */ - public static function url_to_commentid( $url ) { - if ( ! $url || ! filter_var( $url, \FILTER_VALIDATE_URL ) ) { - return null; - } - - // Check for local comment. - if ( \wp_parse_url( \home_url(), \PHP_URL_HOST ) === \wp_parse_url( $url, \PHP_URL_HOST ) ) { - $query = \wp_parse_url( $url, \PHP_URL_QUERY ); - - if ( $query ) { - parse_str( $query, $params ); - - if ( ! empty( $params['c'] ) ) { - $comment = \get_comment( $params['c'] ); - - if ( $comment ) { - return $comment->comment_ID; - } - } - } - } - - $args = array( - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'OR', - array( - 'key' => 'source_url', - 'value' => $url, - ), - array( - 'key' => 'source_id', - 'value' => $url, - ), - ), - ); - - $query = new WP_Comment_Query(); - $comments = $query->query( $args ); - - if ( $comments && is_array( $comments ) ) { - return $comments[0]->comment_ID; - } - - return null; - } - - /** - * Filters the CSS classes to add an ActivityPub class. - * - * @param string[] $classes An array of comment classes. - * @param string[] $css_class An array of additional classes added to the list. - * @param string $comment_id The comment ID as a numeric string. - * - * @return string[] An array of classes. - */ - public static function comment_class( $classes, $css_class, $comment_id ) { - // Check if ActivityPub comment. - if ( 'activitypub' === get_comment_meta( $comment_id, 'protocol', true ) ) { - $classes[] = 'activitypub-comment'; - } - - return $classes; - } - - /** - * Gets the public comment id via the WordPress comments meta. - * - * @param int $wp_comment_id The internal WordPress comment ID. - * @param bool $fallback Whether the code should fall back to `source_url` if `source_id` is not set. - * - * @return string|null The ActivityPub id/url of the comment. - */ - public static function get_source_id( $wp_comment_id, $fallback = true ) { - $comment_meta = \get_comment_meta( $wp_comment_id ); - - if ( ! empty( $comment_meta['source_id'][0] ) ) { - return $comment_meta['source_id'][0]; - } elseif ( ! empty( $comment_meta['source_url'][0] ) && $fallback ) { - return $comment_meta['source_url'][0]; - } - - return null; - } - - /** - * Gets the public comment url via the WordPress comments meta. - * - * @param int $wp_comment_id The internal WordPress comment ID. - * @param bool $fallback Whether the code should fall back to `source_id` if `source_url` is not set. - * - * @return string|null The ActivityPub id/url of the comment. - */ - public static function get_source_url( $wp_comment_id, $fallback = true ) { - $comment_meta = \get_comment_meta( $wp_comment_id ); - - if ( ! empty( $comment_meta['source_url'][0] ) ) { - return $comment_meta['source_url'][0]; - } elseif ( ! empty( $comment_meta['source_id'][0] ) && $fallback ) { - return $comment_meta['source_id'][0]; - } - - return null; - } - - /** - * Link remote comments to source url. - * - * @param string $comment_link The comment link. - * @param object|\WP_Comment $comment The comment object. - * - * @return string $url - */ - public static function remote_comment_link( $comment_link, $comment ) { - if ( ! $comment || is_admin() ) { - return $comment_link; - } - - $public_comment_link = self::get_source_url( $comment->comment_ID ); - - return $public_comment_link ?? $comment_link; - } - - - /** - * Generates an ActivityPub URI for a comment - * - * @param \WP_Comment|int $comment A comment object or comment ID. - * - * @return string ActivityPub URI for comment - */ - public static function generate_id( $comment ) { - $comment = \get_comment( $comment ); - - // Show external comment ID if it exists. - $public_comment_link = self::get_source_id( $comment->comment_ID ); - - if ( $public_comment_link ) { - return $public_comment_link; - } - - // Generate URI based on comment ID. - return \add_query_arg( 'c', $comment->comment_ID, \trailingslashit( \home_url() ) ); - } - - /** - * Check if a post has remote comments - * - * @param int $post_id The post ID. - * - * @return bool True if the post has remote comments, false otherwise. - */ - private static function post_has_remote_comments( $post_id ) { - $comments = \get_comments( - array( - 'post_id' => $post_id, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'AND', - array( - 'key' => 'protocol', - 'value' => 'activitypub', - 'compare' => '=', - ), - array( - 'key' => 'source_id', - 'compare' => 'EXISTS', - ), - ), - ) - ); - - return ! empty( $comments ); - } - - /** - * Enqueue scripts for remote comments - */ - public static function enqueue_scripts() { - if ( ! \is_singular() || \is_user_logged_in() ) { - // Only on single pages, only for logged-out users. - return; - } - - if ( ! \post_type_supports( \get_post_type(), 'activitypub' ) ) { - // Post type does not support ActivityPub. - return; - } - - if ( ! \comments_open() || ! \get_comments_number() ) { - // No comments, no need to load the script. - return; - } - - if ( ! self::post_has_remote_comments( \get_the_ID() ) ) { - // No remote comments, no need to load the script. - return; - } - - $handle = 'activitypub-remote-reply'; - $data = array( - 'namespace' => ACTIVITYPUB_REST_NAMESPACE, - 'defaultAvatarUrl' => ACTIVITYPUB_PLUGIN_URL . 'assets/img/mp.jpg', - ); - $js = sprintf( 'var _activityPubOptions = %s;', wp_json_encode( $data ) ); - $asset_file = ACTIVITYPUB_PLUGIN_DIR . 'build/remote-reply/index.asset.php'; - - if ( \file_exists( $asset_file ) ) { - $assets = require_once $asset_file; - - \wp_enqueue_script( - $handle, - \plugins_url( 'build/remote-reply/index.js', __DIR__ ), - $assets['dependencies'], - $assets['version'], - true - ); - \wp_add_inline_script( $handle, $js, 'before' ); - \wp_set_script_translations( $handle, 'activitypub' ); - - \wp_enqueue_style( - $handle, - \plugins_url( 'build/remote-reply/style-index.css', __DIR__ ), - array( 'wp-components' ), - $assets['version'] - ); - } - } - - /** - * Get the comment type by activity type. - * - * @param string $activity_type The activity type. - * - * @return array|null The comment type. - */ - public static function get_comment_type_by_activity_type( $activity_type ) { - $activity_type = \strtolower( $activity_type ); - $activity_type = \sanitize_key( $activity_type ); - $comment_types = self::get_comment_types(); - - foreach ( $comment_types as $comment_type ) { - if ( in_array( $activity_type, $comment_type['activity_types'], true ) ) { - return $comment_type; - } - } - - return null; - } - - /** - * Return the registered custom comment types. - * - * @return array The registered custom comment types - */ - public static function get_comment_types() { - global $activitypub_comment_types; - - return $activitypub_comment_types; - } - - /** - * Is this a registered comment type. - * - * @param string $slug The slug of the type. - * - * @return boolean True if registered. - */ - public static function is_registered_comment_type( $slug ) { - $slug = \strtolower( $slug ); - $slug = \sanitize_key( $slug ); - - $comment_types = self::get_comment_types(); - - return isset( $comment_types[ $slug ] ); - } - - /** - * Return the registered custom comment type slugs. - * - * @return array The registered custom comment type slugs. - */ - public static function get_comment_type_slugs() { - return array_keys( self::get_comment_types() ); - } - - /** - * Return the registered custom comment type slugs. - * - * @deprecated 4.5.0 Use get_comment_type_slugs instead. - * - * @return array The registered custom comment type slugs. - */ - public static function get_comment_type_names() { - _deprecated_function( __METHOD__, '4.5.0', 'get_comment_type_slugs' ); - - return self::get_comment_type_slugs(); - } - - /** - * Get the custom comment type. - * - * Check if the type is registered, if not, check if it is a custom type. - * - * It looks for the array key in the registered types and returns the array. - * If it is not found, it looks for the type in the custom types and returns the array. - * - * @param string $type The comment type. - * - * @return array The comment type. - */ - public static function get_comment_type( $type ) { - $type = strtolower( $type ); - $type = sanitize_key( $type ); - - $comment_types = self::get_comment_types(); - $type_array = array(); - - // Check array keys. - if ( in_array( $type, array_keys( $comment_types ), true ) ) { - $type_array = $comment_types[ $type ]; - } - - /** - * Filter the comment type. - * - * @param array $type_array The comment type. - */ - return apply_filters( "activitypub_comment_type_{$type}", $type_array ); - } - - /** - * Get a comment type attribute. - * - * @param string $type The comment type. - * @param string $attr The attribute to get. - * - * @return mixed The value of the attribute. - */ - public static function get_comment_type_attr( $type, $attr ) { - $type_array = self::get_comment_type( $type ); - - if ( $type_array && isset( $type_array[ $attr ] ) ) { - $value = $type_array[ $attr ]; - } else { - $value = ''; - } - - /** - * Filter the comment type attribute. - * - * @param mixed $value The value of the attribute. - * @param string $type The comment type. - */ - return apply_filters( "activitypub_comment_type_{$attr}", $value, $type ); - } - - /** - * Register the comment types used by the ActivityPub plugin. - */ - public static function register_comment_types() { - register_comment_type( - 'repost', - array( - 'label' => __( 'Reposts', 'activitypub' ), - 'singular' => __( 'Repost', 'activitypub' ), - 'description' => __( 'A repost on the indieweb is a post that is purely a 100% re-publication of another (typically someone else\'s) post.', 'activitypub' ), - 'icon' => '♻️', - 'class' => 'p-repost', - 'type' => 'repost', - 'collection' => 'reposts', - 'activity_types' => array( 'announce' ), - 'excerpt' => html_entity_decode( \__( '… reposted this!', 'activitypub' ) ), - /* translators: %d: Number of reposts */ - 'count_single' => _x( '%d repost', 'number of reposts', 'activitypub' ), - /* translators: %d: Number of reposts */ - 'count_plural' => _x( '%d reposts', 'number of reposts', 'activitypub' ), - ) - ); - - register_comment_type( - 'like', - array( - 'label' => __( 'Likes', 'activitypub' ), - 'singular' => __( 'Like', 'activitypub' ), - 'description' => __( 'A like is a popular webaction button and in some cases post type on various silos such as Facebook and Instagram.', 'activitypub' ), - 'icon' => '👍', - 'class' => 'p-like', - 'type' => 'like', - 'collection' => 'likes', - 'activity_types' => array( 'like' ), - 'excerpt' => html_entity_decode( \__( '… liked this!', 'activitypub' ) ), - /* translators: %d: Number of likes */ - 'count_single' => _x( '%d like', 'number of likes', 'activitypub' ), - /* translators: %d: Number of likes */ - 'count_plural' => _x( '%d likes', 'number of likes', 'activitypub' ), - ) - ); - } - - /** - * Show avatars on Activities if set. - * - * @param array $types List of avatar enabled comment types. - * - * @return array show avatars on Activities - */ - public static function get_avatar_comment_types( $types ) { - $comment_types = self::get_comment_type_slugs(); - $types = array_merge( $types, $comment_types ); - - return array_unique( $types ); - } - - /** - * Excludes likes and reposts from comment queries. - * - * @author Jan Boddez - * - * @see https://github.com/janboddez/indieblocks/blob/a2d59de358031056a649ee47a1332ce9e39d4ce2/includes/functions.php#L423-L432 - * - * @param WP_Comment_Query $query Comment count. - */ - public static function comment_query( $query ) { - if ( ! $query instanceof WP_Comment_Query ) { - return; - } - - // Do not exclude likes and reposts on ActivityPub requests. - if ( defined( 'ACTIVITYPUB_REQUEST' ) && ACTIVITYPUB_REQUEST ) { - return; - } - - // Do not exclude likes and reposts on REST requests. - if ( \wp_is_serving_rest_request() ) { - return; - } - - // Do not exclude likes and reposts on admin pages or on non-singular pages. - if ( is_admin() || ! is_singular() ) { - return; - } - - // Do not exclude likes and reposts if the query is for comments. - if ( ! empty( $query->query_vars['type__in'] ) || ! empty( $query->query_vars['type'] ) ) { - return; - } - - // Exclude likes and reposts by the ActivityPub plugin. - $query->query_vars['type__not_in'] = self::get_comment_type_slugs(); - } - - /** - * Filter the comment status before it is set. - * - * @param string $approved The approved comment status. - * @param array $commentdata The comment data. - * - * @return boolean `true` if the comment is approved, `false` otherwise. - */ - public static function pre_comment_approved( $approved, $commentdata ) { - if ( $approved || \is_wp_error( $approved ) ) { - return $approved; - } - - if ( '1' !== \get_option( 'comment_previously_approved' ) ) { - return $approved; - } - - if ( - empty( $commentdata['comment_meta']['protocol'] ) || - 'activitypub' !== $commentdata['comment_meta']['protocol'] - ) { - return $approved; - } - - global $wpdb; - - $author = $commentdata['comment_author']; - $author_url = $commentdata['comment_author_url']; - // phpcs:ignore - $ok_to_comment = $wpdb->get_var( $wpdb->prepare( "SELECT comment_approved FROM $wpdb->comments WHERE comment_author = %s AND comment_author_url = %s and comment_approved = '1' LIMIT 1", $author, $author_url ) ); - - if ( 1 === (int) $ok_to_comment ) { - return 1; - } - - return $approved; - } - - /** - * Update comment counts when interaction settings are disabled. - * - * Triggers a recount when likes or reposts are disabled to ensure accurate comment counts. - * - * @param mixed $old_value The old option value. - * @param mixed $value The new option value. - */ - public static function maybe_update_comment_counts( $old_value, $value ) { - if ( '1' === $old_value && '1' !== $value ) { - Migration::update_comment_counts(); - } - } - - /** - * Filters the comment count to exclude ActivityPub comment types. - * - * @param int|null $new_count The new comment count. Default null. - * @param int $old_count The old comment count. - * @param int $post_id Post ID. - * - * @return int|null The updated comment count, or null to use the default query. - */ - public static function pre_wp_update_comment_count_now( $new_count, $old_count, $post_id ) { - if ( null === $new_count ) { - $excluded_types = array_filter( self::get_comment_type_slugs(), array( self::class, 'is_comment_type_enabled' ) ); - - if ( ! empty( $excluded_types ) ) { - global $wpdb; - - // phpcs:ignore WordPress.DB - $new_count = (int) $wpdb->get_var( $wpdb->prepare( "SELECT COUNT(*) FROM $wpdb->comments WHERE comment_post_ID = %d AND comment_approved = '1' AND comment_type NOT IN ('" . implode( "','", $excluded_types ) . "')", $post_id ) ); - } - } - - return $new_count; - } - - /** - * Check if a comment type is enabled. - * - * @param string $comment_type The comment type. - * @return bool True if the comment type is enabled. - */ - public static function is_comment_type_enabled( $comment_type ) { - return '1' === get_option( "activitypub_allow_{$comment_type}s", '1' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-debug.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-debug.php deleted file mode 100644 index af7608dd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-debug.php +++ /dev/null @@ -1,79 +0,0 @@ -get__id(), $outbox_item ); - - if ( self::should_send_to_followers( $activity, $actor, $outbox_item ) ) { - Scheduler::async_batch( - self::$callback, - $outbox_item->ID, - self::$batch_size, - \get_post_meta( $outbox_item->ID, '_activitypub_outbox_offset', true ) ?: 0 // phpcs:ignore - ); - } else { - // No followers to process for this update. We're done. - \wp_publish_post( $outbox_item ); - \delete_post_meta( $outbox_item->ID, '_activitypub_outbox_offset' ); - } - } - - /** - * Asynchronously runs batch processing routines. - * - * @param int $outbox_item_id The Outbox item ID. - * @param int $batch_size Optional. The batch size. Default ACTIVITYPUB_OUTBOX_PROCESSING_BATCH_SIZE. - * @param int $offset Optional. The offset. Default 0. - * - * @return array|void The next batch of followers to process, or void if done. - */ - public static function send_to_followers( $outbox_item_id, $batch_size = ACTIVITYPUB_OUTBOX_PROCESSING_BATCH_SIZE, $offset = 0 ) { - $json = Outbox::get_activity( $outbox_item_id )->to_json(); - $actor = Outbox::get_actor( \get_post( $outbox_item_id ) ); - $inboxes = Followers::get_inboxes_for_activity( $json, $actor->get__id(), $batch_size, $offset ); - - $retries = self::send_to_inboxes( $inboxes, $outbox_item_id ); - - // Retry failed inboxes. - if ( ! empty( $retries ) ) { - self::schedule_retry( $retries, $outbox_item_id ); - } - - if ( is_countable( $inboxes ) && count( $inboxes ) < $batch_size ) { - \delete_post_meta( $outbox_item_id, '_activitypub_outbox_offset' ); - - /** - * Fires when the followers are complete. - * - * @param array $inboxes The inboxes. - * @param string $json The ActivityPub Activity JSON - * @param int $actor_id The actor ID. - * @param int $outbox_item_id The Outbox item ID. - * @param int $batch_size The batch size. - * @param int $offset The offset. - */ - \do_action( 'activitypub_outbox_processing_complete', $inboxes, $json, $actor->get__id(), $outbox_item_id, $batch_size, $offset ); - - // No more followers to process for this update. - \wp_publish_post( $outbox_item_id ); - } else { - \update_post_meta( $outbox_item_id, '_activitypub_outbox_offset', $offset + $batch_size ); - - /** - * Fires when the batch of followers is complete. - * - * @param array $inboxes The inboxes. - * @param string $json The ActivityPub Activity JSON - * @param int $actor_id The actor ID. - * @param int $outbox_item_id The Outbox item ID. - * @param int $batch_size The batch size. - * @param int $offset The offset. - */ - \do_action( 'activitypub_outbox_processing_batch_complete', $inboxes, $json, $actor->get__id(), $outbox_item_id, $batch_size, $offset ); - - return array( $outbox_item_id, $batch_size, $offset + $batch_size ); - } - } - - /** - * Retry sending to followers. - * - * @param string $transient_key The key to retrieve retry inboxes. - * @param int $outbox_item_id The Outbox item ID. - * @param int $attempt The attempt number. - */ - public static function retry_send_to_followers( $transient_key, $outbox_item_id, $attempt = 1 ) { - $inboxes = \get_transient( $transient_key ); - if ( false === $inboxes ) { - return; - } - - // Delete the transient as we no longer need it. - \delete_transient( $transient_key ); - - $retries = self::send_to_inboxes( $inboxes, $outbox_item_id ); - - // Retry failed inboxes. - if ( ++$attempt < 3 && ! empty( $retries ) ) { - self::schedule_retry( $retries, $outbox_item_id, $attempt ); - } - } - - /** - * Send to inboxes. - * - * @param array $inboxes The inboxes to notify. - * @param int $outbox_item_id The Outbox item ID. - * @return array The failed inboxes. - */ - private static function send_to_inboxes( $inboxes, $outbox_item_id ) { - $json = Outbox::get_activity( $outbox_item_id )->to_json(); - $actor = Outbox::get_actor( \get_post( $outbox_item_id ) ); - $retries = array(); - - /** - * Fires before sending an Activity to inboxes. - * - * @param string $json The ActivityPub Activity JSON. - * @param array $inboxes The inboxes to send to. - * @param int $outbox_item_id The Outbox item ID. - */ - \do_action( 'activitypub_pre_send_to_inboxes', $json, $inboxes, $outbox_item_id ); - - foreach ( $inboxes as $inbox ) { - $result = safe_remote_post( $inbox, $json, $actor->get__id() ); - - if ( is_wp_error( $result ) && in_array( $result->get_error_code(), self::$retry_error_codes, true ) ) { - $retries[] = $inbox; - } - - /** - * Fires after an Activity has been sent to an inbox. - * - * @param array $result The result of the remote post request. - * @param string $inbox The inbox URL. - * @param string $json The ActivityPub Activity JSON. - * @param int $actor_id The actor ID. - * @param int $outbox_item_id The Outbox item ID. - */ - \do_action( 'activitypub_sent_to_inbox', $result, $inbox, $json, $actor->get__id(), $outbox_item_id ); - } - - return $retries; - } - - /** - * Schedule a retry. - * - * @param array $retries The inboxes to retry. - * @param int $outbox_item_id The Outbox item ID. - * @param int $attempt Optional. The attempt number. Default 1. - */ - private static function schedule_retry( $retries, $outbox_item_id, $attempt = 1 ) { - $transient_key = 'activitypub_retry_' . \wp_generate_password( 12, false ); - \set_transient( $transient_key, $retries, WEEK_IN_SECONDS ); - - \wp_schedule_single_event( - \time() + ( $attempt * $attempt * HOUR_IN_SECONDS ), - 'activitypub_async_batch', - array( - array( self::class, 'retry_send_to_followers' ), - $transient_key, - $outbox_item_id, - $attempt, - ) - ); - } - - /** - * Send an Activity to a custom list of inboxes, like mentioned users or replied-to posts. - * - * For all custom implementations, please use the `activitypub_additional_inboxes` filter. - * - * @param Activity $activity The ActivityPub Activity. - * @param int $actor_id The actor ID. - * @param \WP_Post $outbox_item The WordPress object. - */ - private static function send_to_additional_inboxes( $activity, $actor_id, $outbox_item = null ) { - /** - * Filters the list of inboxes to send the Activity to. - * - * @param array $inboxes The list of inboxes to send to. - * @param int $actor_id The actor ID. - * @param Activity $activity The ActivityPub Activity. - */ - $inboxes = apply_filters( 'activitypub_additional_inboxes', array(), $actor_id, $activity ); - $inboxes = array_unique( $inboxes ); - - $retries = self::send_to_inboxes( $inboxes, $outbox_item->ID ); - - // Retry failed inboxes. - if ( ! empty( $retries ) ) { - self::schedule_retry( $retries, $outbox_item->ID ); - } - } - - /** - * Default filter to add Inboxes of Mentioned Actors - * - * @param array $inboxes The list of Inboxes. - * @param int $actor_id The WordPress Actor-ID. - * @param Activity $activity The ActivityPub Activity. - * - * @return array The filtered Inboxes. - */ - public static function add_inboxes_by_mentioned_actors( $inboxes, $actor_id, $activity ) { - $cc = $activity->get_cc() ?? array(); - $to = $activity->get_to() ?? array(); - - $audience = array_merge( $cc, $to ); - - // Remove "public placeholder" and "same domain" from the audience. - $audience = array_filter( - $audience, - function ( $actor ) { - return 'https://www.w3.org/ns/activitystreams#Public' !== $actor && ! is_same_domain( $actor ); - } - ); - - if ( $audience ) { - $mentioned_inboxes = Mention::get_inboxes( $audience ); - - return array_merge( $inboxes, $mentioned_inboxes ); - } - - return $inboxes; - } - - /** - * Default filter to add Inboxes of Posts that are set as `in-reply-to` - * - * @param array $inboxes The list of Inboxes. - * @param int $actor_id The WordPress Actor-ID. - * @param Activity $activity The ActivityPub Activity. - * - * @return array The filtered Inboxes - */ - public static function add_inboxes_of_replied_urls( $inboxes, $actor_id, $activity ) { - $in_reply_to = $activity->get_in_reply_to(); - - if ( ! $in_reply_to ) { - return $inboxes; - } - - if ( ! is_array( $in_reply_to ) ) { - $in_reply_to = array( $in_reply_to ); - } - - foreach ( $in_reply_to as $url ) { - // No need to self-notify. - if ( is_same_domain( $url ) ) { - continue; - } - - $object = Http::get_remote_object( $url ); - - if ( - ! $object || - \is_wp_error( $object ) || - empty( $object['attributedTo'] ) - ) { - continue; - } - - $actor = object_to_uri( $object['attributedTo'] ); - $actor = Http::get_remote_object( $actor ); - - if ( ! $actor || \is_wp_error( $actor ) ) { - continue; - } - - if ( ! empty( $actor['endpoints']['sharedInbox'] ) ) { - $inboxes[] = $actor['endpoints']['sharedInbox']; - } elseif ( ! empty( $actor['inbox'] ) ) { - $inboxes[] = $actor['inbox']; - } - } - - return $inboxes; - } - - /** - * Adds Blog Actor inboxes to Updates so the Blog User's followers are notified of edits. - * - * @deprecated 5.2.0 Use {@see Followers::maybe_add_inboxes_of_blog_user} instead. - * - * @param array $inboxes The list of Inboxes. - * @param int $actor_id The WordPress Actor-ID. - * @param Activity $activity The ActivityPub Activity. - * - * @return array The filtered Inboxes. - */ - public static function maybe_add_inboxes_of_blog_user( $inboxes, $actor_id, $activity ) { // phpcs:ignore - _deprecated_function( __METHOD__, '5.2.0', 'Followers::maybe_add_inboxes_of_blog_user' ); - - return $inboxes; - } - - /** - * Check if passed Activity is public. - * - * @param Activity $activity The Activity object. - * @param \Activitypub\Model\User|\Activitypub\Model\Blog $actor The Actor object. - * @param \WP_Post $outbox_item The Outbox item. - * - * @return boolean True if public, false if not. - */ - protected static function should_send_to_followers( $activity, $actor, $outbox_item ) { - // Check if follower endpoint is set. - $cc = $activity->get_cc() ?? array(); - $to = $activity->get_to() ?? array(); - - $audience = array_merge( $cc, $to ); - - $send = ( - // Check if activity is public. - in_array( 'https://www.w3.org/ns/activitystreams#Public', $audience, true ) || - // ...or check if follower endpoint is set. - in_array( $actor->get_followers(), $audience, true ) - ); - - if ( $send ) { - $followers = Followers::get_inboxes_for_activity( $activity->to_json(), $actor->get__id() ); - - // Only send if there are followers to send to. - $send = ! is_countable( $followers ) || 0 < count( $followers ); - } - - /** - * Filters whether to send an Activity to followers. - * - * @param bool $send_activity_to_followers Whether to send the Activity to followers. - * @param Activity $activity The ActivityPub Activity. - * @param int $actor_id The actor ID. - * @param \WP_Post $outbox_item The WordPress object. - */ - return apply_filters( 'activitypub_send_activity_to_followers', $send, $activity, $actor->get__id(), $outbox_item ); - } - - /** - * Add Inboxes of Relays. - * - * @param array $inboxes The list of Inboxes. - * @param int $actor_id The Actor-ID. - * @param Activity $activity The ActivityPub Activity. - * - * @return array The filtered Inboxes. - */ - public static function add_inboxes_of_relays( $inboxes, $actor_id, $activity ) { - // Check if follower endpoint is set. - $cc = $activity->get_cc() ?? array(); - $to = $activity->get_to() ?? array(); - - $audience = array_merge( $cc, $to ); - - // Check if activity is public. - if ( ! in_array( 'https://www.w3.org/ns/activitystreams#Public', $audience, true ) ) { - return $inboxes; - } - - $relays = \get_option( 'activitypub_relays', array() ); - - if ( empty( $relays ) ) { - return $inboxes; - } - - return array_merge( $inboxes, $relays ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-embed.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-embed.php deleted file mode 100644 index 978e66f4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-embed.php +++ /dev/null @@ -1,263 +0,0 @@ - $author_name, - 'author_url' => $author_url, - 'avatar_url' => $avatar_url, - 'published' => $published, - 'title' => $title, - 'content' => $content, - 'image' => $image, - 'boosts' => $boosts, - 'favorites' => $favorites, - 'url' => $activity_object['id'], - 'webfinger' => $author['webfinger'], - ) - ); - - if ( $inline_css ) { - // Grab the CSS. - $css = \file_get_contents( ACTIVITYPUB_PLUGIN_DIR . 'assets/css/activitypub-embed.css' ); // phpcs:ignore WordPress.WP.AlternativeFunctions.file_get_contents_file_get_contents - // We embed CSS directly because this may be in an iframe. - printf( '', $css ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped - } - - // A little light whitespace cleanup. - return preg_replace( '/\s+/', ' ', ob_get_clean() ); - } - - /** - * Check if a real oEmbed result exists for the given URL. - * - * @param string $url The URL to check. - * @param array $args Additional arguments passed to wp_oembed_get(). - * @return bool True if a real oEmbed result exists, false otherwise. - */ - public static function has_real_oembed( $url, $args = array() ) { - // Temporarily remove our filter to avoid infinite loops. - \remove_filter( 'pre_oembed_result', array( self::class, 'maybe_use_activitypub_embed' ), 10, 3 ); - - // Try to get a "real" oEmbed result. If found, it'll be cached to avoid unnecessary HTTP requests in `wp_oembed_get`. - $oembed_result = \wp_oembed_get( $url, $args ); - - // Add our filter back. - \add_filter( 'pre_oembed_result', array( self::class, 'maybe_use_activitypub_embed' ), 10, 3 ); - - return false !== $oembed_result; - } - - /** - * Filter the oembed result to handle ActivityPub content when no oEmbed is found. - * Implementation is a bit weird because there's no way to filter on a false result, we have to use `pre_oembed_result`. - * - * @param null|string $result The UNSANITIZED (and potentially unsafe) HTML that should be used to embed. - * @param string $url The URL to the content that should be attempted to be embedded. - * @param array $args Additional arguments passed to wp_oembed_get(). - * @return null|string Return null to allow normal oEmbed processing, or string for ActivityPub embed. - */ - public static function maybe_use_activitypub_embed( $result, $url, $args ) { - // If we already have a result, return it. - if ( null !== $result ) { - return $result; - } - - // If we found a real oEmbed, return null to allow normal processing. - if ( self::has_real_oembed( $url, $args ) ) { - return null; - } - - // No oEmbed found, try to get ActivityPub representation. - $html = get_embed_html( $url ); - - // If we couldn't get an ActivityPub embed either, return null to allow normal processing. - if ( ! $html ) { - return null; - } - - // Return the ActivityPub embed HTML. - return $html; - } - - /** - * Handle cases where WordPress has filtered out the oEmbed result for security reasons, - * but we can provide a safe ActivityPub-specific markup. - * - * This runs after wp_filter_oembed_result has potentially nullified the result. - * - * @param string|false $html The returned oEmbed HTML. - * @param object $data A data object result from an oEmbed provider. - * @param string $url The URL of the content to be embedded. - * @return string|false The filtered oEmbed HTML or our ActivityPub embed. - */ - public static function handle_filtered_oembed_result( $html, $data, $url ) { - // If we already have valid HTML, return it. - if ( $html ) { - return $html; - } - - // If this isn't a rich or video type, we can't help. - if ( ! isset( $data->type ) || ! \in_array( $data->type, array( 'rich', 'video' ), true ) ) { - return $html; - } - - // If there's no HTML in the data, we can't help. - if ( empty( $data->html ) || ! \is_string( $data->html ) ) { - return $html; - } - - // Try to get ActivityPub representation. - $activitypub_html = get_embed_html( $url ); - if ( ! $activitypub_html ) { - return $html; - } - - // Return our safer ActivityPub embed HTML. - return $activitypub_html; - } - - /** - * Register the fallback hook for oEmbed requests. - * - * Avoids filtering every single API request. - * - * @param int $post_id The post ID. - * @return int The post ID. - */ - public static function register_fallback_hook( $post_id ) { - \add_filter( 'rest_request_after_callbacks', array( self::class, 'oembed_fediverse_fallback' ), 10, 3 ); - - return $post_id; - } - - /** - * Fallback for oEmbed requests to the Fediverse. - * - * @param \WP_REST_Response|\WP_Error $response Result to send to the client. - * @param array $handler Route handler used for the request. - * @param \WP_REST_Request $request Request used to generate the response. - * - * @return \WP_REST_Response|\WP_Error The response to send to the client. - */ - public static function oembed_fediverse_fallback( $response, $handler, $request ) { - if ( is_wp_error( $response ) && 'oembed_invalid_url' === $response->get_error_code() ) { - $url = $request->get_param( 'url' ); - $html = get_embed_html( $url ); - - if ( $html ) { - $args = $request->get_params(); - $data = (object) array( - 'provider_name' => 'Embed Handler', - 'html' => $html, - 'scripts' => array(), - ); - - /** This filter is documented in wp-includes/class-wp-oembed.php */ - $data->html = apply_filters( 'oembed_result', $data->html, $url, $args ); - - /** This filter is documented in wp-includes/class-wp-oembed-controller.php */ - $ttl = apply_filters( 'rest_oembed_ttl', DAY_IN_SECONDS, $url, $args ); - - set_transient( 'oembed_' . md5( serialize( $args ) ), $data, $ttl ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - - $response = new \WP_REST_Response( $data ); - } - } - - return $response; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-handler.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-handler.php deleted file mode 100644 index b0ead9b4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-handler.php +++ /dev/null @@ -1,50 +0,0 @@ -post_content . "\n" . $post->post_excerpt ); - - if ( \preg_match_all( '/' . ACTIVITYPUB_HASHTAGS_REGEXP . '/i', $content, $match ) ) { - $tags = array_unique( $match[1] ); - } - - \wp_add_post_tags( $post->ID, \implode( ', ', $tags ) ); - } - - /** - * Filter to replace the #tags in the content with links. - * - * @param string $the_content The post content. - * - * @return string The filtered post content. - */ - public static function the_content( $the_content ) { - return enrich_content_data( $the_content, '/' . ACTIVITYPUB_HASHTAGS_REGEXP . '/i', array( self::class, 'replace_with_links' ) ); - } - - /** - * A callback for preg_replace to build the term links. - * - * @param array $result The preg_match results. - * @return string the final string - */ - public static function replace_with_links( $result ) { - $tag = $result[1]; - $tag_object = \get_term_by( 'name', $tag, 'post_tag' ); - if ( ! $tag_object ) { - $tag_object = \get_term_by( 'name', $tag, 'category' ); - } - - if ( $tag_object ) { - $link = \get_term_link( $tag_object, 'post_tag' ); - return \sprintf( '', esc_url( $link ), $tag ); - } - - return '#' . $tag; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-http.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-http.php deleted file mode 100644 index 9f9a8dd0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-http.php +++ /dev/null @@ -1,305 +0,0 @@ - 100, - 'limit_response_size' => 1048576, - 'redirection' => 3, - 'user-agent' => "$user_agent; ActivityPub", - 'headers' => array( - 'Accept' => 'application/activity+json', - 'Content-Type' => 'application/activity+json', - 'Digest' => $digest, - 'Signature' => $signature, - 'Date' => $date, - ), - 'body' => $body, - ); - - $response = \wp_safe_remote_post( $url, $args ); - $code = \wp_remote_retrieve_response_code( $response ); - - if ( $code >= 400 ) { - $response = new WP_Error( - $code, - __( 'Failed HTTP Request', 'activitypub' ), - array( - 'status' => $code, - 'response' => $response, - ) - ); - } - - /** - * Action to save the response of the remote POST request. - * - * @param array|WP_Error $response The response of the remote POST request. - * @param string $url The URL endpoint. - * @param string $body The Post Body. - * @param int $user_id The WordPress User-ID. - */ - \do_action( 'activitypub_safe_remote_post_response', $response, $url, $body, $user_id ); - - return $response; - } - - /** - * Send a GET Request with the needed HTTP Headers. - * - * @param string $url The URL endpoint. - * @param bool|int $cached Optional. Whether the result should be cached, or its duration. Default false. - * - * @return array|WP_Error The GET Response or a WP_Error. - */ - public static function get( $url, $cached = false ) { - /** - * Fires before an HTTP GET request is made. - * - * @param string $url The URL endpoint. - */ - \do_action( 'activitypub_pre_http_get', $url ); - - if ( $cached ) { - $transient_key = self::generate_cache_key( $url ); - - $response = \get_transient( $transient_key ); - - if ( $response ) { - /** - * Action to save the response of the remote GET request. - * - * @param array|WP_Error $response The response of the remote GET request. - * @param string $url The URL endpoint. - */ - \do_action( 'activitypub_safe_remote_get_response', $response, $url ); - - return $response; - } - } - - $date = \gmdate( 'D, d M Y H:i:s T' ); - $signature = Signature::generate_signature( Actors::APPLICATION_USER_ID, 'get', $url, $date ); - - $wp_version = get_masked_wp_version(); - - /** - * Filters the HTTP headers user agent string. - * - * This filter allows developers to modify the user agent string that is - * sent with HTTP requests. - * - * @param string $user_agent The user agent string. - */ - $user_agent = \apply_filters( 'http_headers_useragent', 'WordPress/' . $wp_version . '; ' . \get_bloginfo( 'url' ) ); - - /** - * Filters the timeout duration for remote GET requests in ActivityPub. - * - * @param int $timeout The timeout value in seconds. Default 100 seconds. - */ - $timeout = \apply_filters( 'activitypub_remote_get_timeout', 100 ); - - $args = array( - 'timeout' => $timeout, - 'limit_response_size' => 1048576, - 'redirection' => 3, - 'user-agent' => "$user_agent; ActivityPub", - 'headers' => array( - 'Accept' => 'application/activity+json', - 'Content-Type' => 'application/activity+json', - 'Signature' => $signature, - 'Date' => $date, - ), - ); - - $response = \wp_safe_remote_get( $url, $args ); - $code = \wp_remote_retrieve_response_code( $response ); - - if ( $code >= 400 ) { - $response = new WP_Error( $code, __( 'Failed HTTP Request', 'activitypub' ), array( 'status' => $code ) ); - } - - /** - * Action to save the response of the remote GET request. - * - * @param array|WP_Error $response The response of the remote GET request. - * @param string $url The URL endpoint. - */ - \do_action( 'activitypub_safe_remote_get_response', $response, $url ); - - if ( $cached ) { - $cache_duration = $cached; - if ( ! is_int( $cache_duration ) ) { - $cache_duration = HOUR_IN_SECONDS; - } - \set_transient( $transient_key, $response, $cache_duration ); - } - - return $response; - } - - /** - * Check for URL for Tombstone. - * - * @param string $url The URL to check. - * - * @return bool True if the URL is a tombstone. - */ - public static function is_tombstone( $url ) { - /** - * Fires before checking if the URL is a tombstone. - * - * @param string $url The URL to check. - */ - \do_action( 'activitypub_pre_http_is_tombstone', $url ); - - $response = \wp_safe_remote_get( $url, array( 'headers' => array( 'Accept' => 'application/activity+json' ) ) ); - $code = \wp_remote_retrieve_response_code( $response ); - - if ( in_array( (int) $code, array( 404, 410 ), true ) ) { - return true; - } - - $data = \wp_remote_retrieve_body( $response ); - $data = \json_decode( $data, true ); - if ( $data && isset( $data['type'] ) && 'Tombstone' === $data['type'] ) { - return true; - } - - return false; - } - - /** - * Generate a cache key for the URL. - * - * @param string $url The URL to generate the cache key for. - * - * @return string The cache key. - */ - public static function generate_cache_key( $url ) { - return 'activitypub_http_' . \md5( $url ); - } - - /** - * Requests the Data from the Object-URL or Object-Array. - * - * @param array|string $url_or_object The Object or the Object URL. - * @param bool $cached Optional. Whether the result should be cached. Default true. - * - * @return array|WP_Error The Object data as array or WP_Error on failure. - */ - public static function get_remote_object( $url_or_object, $cached = true ) { - $url = object_to_uri( $url_or_object ); - - if ( preg_match( '/^@?' . ACTIVITYPUB_USERNAME_REGEXP . '$/i', $url ) ) { - $url = Webfinger::resolve( $url ); - } - - if ( ! $url ) { - return new WP_Error( - 'activitypub_no_valid_actor_identifier', - \__( 'The "actor" identifier is not valid', 'activitypub' ), - array( - 'status' => 404, - 'object' => $url, - ) - ); - } - - if ( is_wp_error( $url ) ) { - return $url; - } - - $transient_key = self::generate_cache_key( $url ); - - // Only check the cache if needed. - if ( $cached ) { - $data = \get_transient( $transient_key ); - - if ( $data ) { - return $data; - } - } - - if ( ! \wp_http_validate_url( $url ) ) { - return new WP_Error( - 'activitypub_no_valid_object_url', - \__( 'The "object" is/has no valid URL', 'activitypub' ), - array( - 'status' => 400, - 'object' => $url, - ) - ); - } - - $response = self::get( $url ); - - if ( \is_wp_error( $response ) ) { - return $response; - } - - $data = \wp_remote_retrieve_body( $response ); - $data = \json_decode( $data, true ); - - if ( ! $data ) { - return new WP_Error( - 'activitypub_invalid_json', - \__( 'No valid JSON data', 'activitypub' ), - array( - 'status' => 400, - 'object' => $url, - ) - ); - } - - \set_transient( $transient_key, $data, WEEK_IN_SECONDS ); - - return $data; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-link.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-link.php deleted file mode 100644 index 783f1fec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-link.php +++ /dev/null @@ -1,132 +0,0 @@ -%s', - esc_url( $result[0] ), - $rel, - esc_html( $invisible_prefix ), - $display_class, - esc_html( $display ), - esc_html( $invisible_suffix ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-mailer.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-mailer.php deleted file mode 100644 index 095d8396..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-mailer.php +++ /dev/null @@ -1,337 +0,0 @@ -comment_ID, 'protocol', true ); - - if ( 'activitypub' !== $type ) { - return $subject; - } - - $singular = Comment::get_comment_type_attr( $comment->comment_type, 'singular' ); - - if ( ! $singular ) { - return $subject; - } - - $post = \get_post( $comment->comment_post_ID ); - - /* translators: 1: Blog name, 2: Like or Repost, 3: Post title */ - return \sprintf( \esc_html__( '[%1$s] %2$s: %3$s', 'activitypub' ), \esc_html( get_option( 'blogname' ) ), \esc_html( $singular ), \esc_html( $post->post_title ) ); - } - - /** - * Filter the notification text for Like and Announce notifications. - * - * @param string $message The default notification text. - * @param int|string $comment_id The comment ID. - * - * @return string The filtered notification text. - */ - public static function comment_notification_text( $message, $comment_id ) { - $comment = \get_comment( $comment_id ); - - if ( ! $comment ) { - return $message; - } - - $type = \get_comment_meta( $comment->comment_ID, 'protocol', true ); - - if ( 'activitypub' !== $type ) { - return $message; - } - - $comment_type = Comment::get_comment_type( $comment->comment_type ); - - if ( ! $comment_type ) { - return $message; - } - - $post = \get_post( $comment->comment_post_ID ); - $comment_author_domain = \gethostbyaddr( $comment->comment_author_IP ); - - /* translators: 1: Comment type, 2: Post title */ - $notify_message = \sprintf( html_entity_decode( esc_html__( 'New %1$s on your post “%2$s”.', 'activitypub' ) ), \esc_html( $comment_type['singular'] ), \esc_html( $post->post_title ) ) . "\r\n\r\n"; - /* translators: 1: Website name, 2: Website IP address, 3: Website hostname. */ - $notify_message .= \sprintf( \esc_html__( 'From: %1$s (IP address: %2$s, %3$s)', 'activitypub' ), \esc_html( $comment->comment_author ), \esc_html( $comment->comment_author_IP ), \esc_html( $comment_author_domain ) ) . "\r\n"; - /* translators: Reaction author URL. */ - $notify_message .= \sprintf( \esc_html__( 'URL: %s', 'activitypub' ), \esc_url( $comment->comment_author_url ) ) . "\r\n\r\n"; - /* translators: Comment type label */ - $notify_message .= \sprintf( \esc_html__( 'You can see all %s on this post here:', 'activitypub' ), \esc_html( $comment_type['label'] ) ) . "\r\n"; - $notify_message .= \get_permalink( $comment->comment_post_ID ) . '#' . \esc_attr( $comment_type['type'] ) . "\r\n\r\n"; - - return $notify_message; - } - - /** - * Send a notification email for every new follower. - * - * @param array $activity The activity object. - * @param int $user_id The id of the local blog-user. - */ - public static function new_follower( $activity, $user_id ) { - if ( $user_id > Actors::BLOG_USER_ID ) { - if ( ! \get_user_option( 'activitypub_mailer_new_follower', $user_id ) ) { - return; - } - - $email = \get_userdata( $user_id )->user_email; - $admin_url = '/users.php?page=activitypub-followers-list'; - } else { - if ( '1' !== \get_option( 'activitypub_blog_user_mailer_new_follower', '1' ) ) { - return; - } - - $email = \get_option( 'admin_email' ); - $admin_url = '/options-general.php?page=activitypub&tab=followers'; - } - - $actor = get_remote_metadata_by_actor( $activity['actor'] ); - if ( ! $actor || \is_wp_error( $actor ) ) { - return; - } - - if ( empty( $actor['webfinger'] ) ) { - $actor['webfinger'] = '@' . ( $actor['preferredUsername'] ?? $actor['name'] ) . '@' . \wp_parse_url( $actor['url'], PHP_URL_HOST ); - } - - $template_args = array_merge( - $actor, - array( - 'admin_url' => $admin_url, - 'user_id' => $user_id, - 'stats' => array( - 'outbox' => null, - 'followers' => null, - 'following' => null, - ), - ) - ); - - foreach ( $template_args['stats'] as $field => $value ) { - if ( empty( $actor[ $field ] ) ) { - continue; - } - - $result = Http::get( $actor[ $field ], true ); - if ( 200 === \wp_remote_retrieve_response_code( $result ) ) { - $body = \json_decode( \wp_remote_retrieve_body( $result ), true ); - if ( isset( $body['totalItems'] ) ) { - $template_args['stats'][ $field ] = $body['totalItems']; - } - } - } - - /* translators: 1: Blog name, 2: Follower name */ - $subject = \sprintf( \__( '[%1$s] New Follower: %2$s', 'activitypub' ), \get_option( 'blogname' ), $actor['name'] ); - - \ob_start(); - \load_template( ACTIVITYPUB_PLUGIN_DIR . 'templates/emails/new-follower.php', false, $template_args ); - $html_message = \ob_get_clean(); - - $alt_function = function ( $mailer ) use ( $actor, $admin_url ) { - /* translators: 1: Follower name */ - $message = \sprintf( \__( 'New Follower: %1$s.', 'activitypub' ), $actor['name'] ) . "\r\n\r\n"; - /* translators: Follower URL */ - $message .= \sprintf( \__( 'URL: %s', 'activitypub' ), \esc_url( $actor['url'] ) ) . "\r\n\r\n"; - $message .= \__( 'You can see all followers here:', 'activitypub' ) . "\r\n"; - $message .= \esc_url( \admin_url( $admin_url ) ) . "\r\n\r\n"; - $mailer->{'AltBody'} = $message; - }; - \add_action( 'phpmailer_init', $alt_function ); - - \wp_mail( $email, $subject, $html_message, array( 'Content-type: text/html' ) ); - - \remove_action( 'phpmailer_init', $alt_function ); - } - - /** - * Send a direct message. - * - * @param array $activity The activity object. - * @param int $user_id The id of the local blog-user. - */ - public static function direct_message( $activity, $user_id ) { - if ( - is_activity_public( $activity ) || - // Only accept messages that have the user in the "to" field. - empty( $activity['to'] ) || - ! in_array( Actors::get_by_id( $user_id )->get_id(), (array) $activity['to'], true ) - ) { - return; - } - - if ( $user_id > Actors::BLOG_USER_ID ) { - if ( ! \get_user_option( 'activitypub_mailer_new_dm', $user_id ) ) { - return; - } - - $email = \get_userdata( $user_id )->user_email; - } else { - if ( '1' !== \get_option( 'activitypub_blog_user_mailer_new_dm', '1' ) ) { - return; - } - - $email = \get_option( 'admin_email' ); - } - - $actor = get_remote_metadata_by_actor( $activity['actor'] ); - - if ( ! $actor || \is_wp_error( $actor ) || empty( $activity['object']['content'] ) ) { - return; - } - - if ( empty( $actor['webfinger'] ) ) { - $actor['webfinger'] = '@' . ( $actor['preferredUsername'] ?? $actor['name'] ) . '@' . \wp_parse_url( $actor['url'], PHP_URL_HOST ); - } - - $template_args = array( - 'activity' => $activity, - 'actor' => $actor, - 'user_id' => $user_id, - ); - - /* translators: 1: Blog name, 2 Actor name */ - $subject = \sprintf( \esc_html__( '[%1$s] Direct Message from: %2$s', 'activitypub' ), \esc_html( \get_option( 'blogname' ) ), \esc_html( $actor['name'] ) ); - - \ob_start(); - \load_template( ACTIVITYPUB_PLUGIN_DIR . 'templates/emails/new-dm.php', false, $template_args ); - $html_message = \ob_get_clean(); - - $alt_function = function ( $mailer ) use ( $actor, $activity ) { - $content = \html_entity_decode( - \wp_strip_all_tags( - str_replace( '

', PHP_EOL . PHP_EOL, $activity['object']['content'] ) - ), - ENT_QUOTES | ENT_SUBSTITUTE | ENT_HTML401 - ); - - /* translators: Actor name */ - $message = \sprintf( \esc_html__( 'New Direct Message: %s', 'activitypub' ), $content ) . "\r\n\r\n"; - /* translators: Actor name */ - $message .= \sprintf( \esc_html__( 'From: %s', 'activitypub' ), \esc_html( $actor['name'] ) ) . "\r\n"; - /* translators: Message URL */ - $message .= \sprintf( \esc_html__( 'URL: %s', 'activitypub' ), \esc_url( $activity['object']['id'] ) ) . "\r\n\r\n"; - - $mailer->{'AltBody'} = $message; - }; - \add_action( 'phpmailer_init', $alt_function ); - - \wp_mail( $email, $subject, $html_message, array( 'Content-type: text/html' ) ); - - \remove_action( 'phpmailer_init', $alt_function ); - } - - /** - * Send a mention notification. - * - * @param array $activity The activity object. - * @param int $user_id The id of the local blog-user. - */ - public static function mention( $activity, $user_id ) { - if ( - // Only accept messages that have the user in the "cc" field. - empty( $activity['cc'] ) || - ! in_array( Actors::get_by_id( $user_id )->get_id(), (array) $activity['cc'], true ) - ) { - return; - } - - if ( $user_id > Actors::BLOG_USER_ID ) { - if ( ! \get_user_option( 'activitypub_mailer_new_mention', $user_id ) ) { - return; - } - - $email = \get_userdata( $user_id )->user_email; - } else { - if ( '1' !== \get_option( 'activitypub_blog_user_mailer_new_mention', '1' ) ) { - return; - } - - $email = \get_option( 'admin_email' ); - } - - $actor = get_remote_metadata_by_actor( $activity['actor'] ); - if ( \is_wp_error( $actor ) ) { - return; - } - - if ( empty( $actor['webfinger'] ) ) { - $actor['webfinger'] = '@' . ( $actor['preferredUsername'] ?? $actor['name'] ) . '@' . \wp_parse_url( $actor['url'], PHP_URL_HOST ); - } - - $template_args = array( - 'activity' => $activity, - 'actor' => $actor, - 'user_id' => $user_id, - ); - - /* translators: 1: Blog name, 2 Actor name */ - $subject = \sprintf( \esc_html__( '[%1$s] Mention from: %2$s', 'activitypub' ), \esc_html( \get_option( 'blogname' ) ), \esc_html( $actor['name'] ) ); - - \ob_start(); - \load_template( ACTIVITYPUB_PLUGIN_DIR . 'templates/emails/new-mention.php', false, $template_args ); - $html_message = \ob_get_clean(); - - $alt_function = function ( $mailer ) use ( $actor, $activity ) { - $content = \html_entity_decode( - \wp_strip_all_tags( - str_replace( '

', PHP_EOL . PHP_EOL, $activity['object']['content'] ) - ), - ENT_QUOTES | ENT_SUBSTITUTE | ENT_HTML401 - ); - - /* translators: Message content */ - $message = \sprintf( \esc_html__( 'New Mention: %s', 'activitypub' ), $content ) . "\r\n\r\n"; - /* translators: Actor name */ - $message .= \sprintf( \esc_html__( 'From: %s', 'activitypub' ), \esc_html( $actor['name'] ) ) . "\r\n"; - /* translators: Message URL */ - $message .= \sprintf( \esc_html__( 'URL: %s', 'activitypub' ), \esc_url( $activity['object']['id'] ) ) . "\r\n\r\n"; - - $mailer->{'AltBody'} = $message; - }; - \add_action( 'phpmailer_init', $alt_function ); - - \wp_mail( $email, $subject, $html_message, array( 'Content-type: text/html' ) ); - - \remove_action( 'phpmailer_init', $alt_function ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-mention.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-mention.php deleted file mode 100644 index 93ada0bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-mention.php +++ /dev/null @@ -1,155 +0,0 @@ -@%2$s', esc_url( $url ), esc_html( $username ) ); - } - - return $result[0]; - } - - /** - * Get the Inboxes for the mentioned Actors. - * - * @param array $mentioned The list of Actors that were mentioned. - * - * @return array The list of Inboxes. - */ - public static function get_inboxes( $mentioned ) { - $inboxes = array(); - - foreach ( $mentioned as $actor ) { - $inbox = self::get_inbox_by_mentioned_actor( $actor ); - - if ( ! is_wp_error( $inbox ) && $inbox ) { - $inboxes[] = $inbox; - } - } - - return $inboxes; - } - - /** - * Get the inbox from the Remote-Profile of a mentioned Actor. - * - * @param string $actor The Actor URL. - * - * @return string|WP_Error The Inbox-URL or WP_Error if not found. - */ - public static function get_inbox_by_mentioned_actor( $actor ) { - $metadata = get_remote_metadata_by_actor( $actor ); - - if ( \is_wp_error( $metadata ) ) { - return $metadata; - } - - if ( isset( $metadata['endpoints']['sharedInbox'] ) ) { - return $metadata['endpoints']['sharedInbox']; - } - - if ( \array_key_exists( 'inbox', $metadata ) ) { - return $metadata['inbox']; - } - - return new WP_Error( 'activitypub_no_inbox', \__( 'No "Inbox" found', 'activitypub' ), $metadata ); - } - - /** - * Extract the mentions from the post_content. - * - * @param array $mentions The already found mentions. - * @param string $post_content The post content. - * - * @return array The discovered mentions. - */ - public static function extract_mentions( $mentions, $post_content ) { - \preg_match_all( '/@' . ACTIVITYPUB_USERNAME_REGEXP . '/i', $post_content, $matches ); - foreach ( $matches[0] as $match ) { - $link = Webfinger::resolve( $match ); - if ( ! is_wp_error( $link ) ) { - $mentions[ $match ] = $link; - } - } - return \array_unique( $mentions ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-migration.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-migration.php deleted file mode 100644 index 9132f6b6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-migration.php +++ /dev/null @@ -1,944 +0,0 @@ -query( $wpdb->prepare( "INSERT IGNORE INTO `$wpdb->options` ( `option_name`, `option_value`, `autoload` ) VALUES (%s, %s, 'no') /* LOCK */", 'activitypub_migration_lock', \time() ) ); // phpcs:ignore WordPress.DB - - if ( ! $lock_result ) { - $lock_result = \get_option( 'activitypub_migration_lock' ); - } - - return $lock_result; - } - - /** - * Unlocks the database migration process. - */ - public static function unlock() { - \delete_option( 'activitypub_migration_lock' ); - } - - /** - * Whether the database migration process is locked. - * - * @return boolean - */ - public static function is_locked() { - $lock = \get_option( 'activitypub_migration_lock' ); - - if ( ! $lock ) { - return false; - } - - $lock = (int) $lock; - - if ( $lock < \time() - 1800 ) { - self::unlock(); - return false; - } - - return true; - } - - /** - * Whether the database structure is up to date. - * - * @return bool True if the database structure is up to date, false otherwise. - */ - public static function is_latest_version() { - return (bool) \version_compare( - self::get_version(), - ACTIVITYPUB_PLUGIN_VERSION, - '==' - ); - } - - /** - * Updates the database structure if necessary. - */ - public static function maybe_migrate() { - if ( self::is_latest_version() ) { - return; - } - - if ( self::is_locked() ) { - return; - } - - self::lock(); - - $version_from_db = self::get_version(); - - // Check for initial migration. - if ( ! $version_from_db ) { - self::add_default_settings(); - $version_from_db = ACTIVITYPUB_PLUGIN_VERSION; - } - - // Schedule the async migration. - if ( ! \wp_next_scheduled( 'activitypub_migrate', $version_from_db ) ) { - \wp_schedule_single_event( \time(), 'activitypub_migrate', array( $version_from_db ) ); - } - if ( \version_compare( $version_from_db, '0.17.0', '<' ) ) { - self::migrate_from_0_16(); - } - if ( \version_compare( $version_from_db, '1.3.0', '<' ) ) { - self::migrate_from_1_2_0(); - } - if ( \version_compare( $version_from_db, '2.1.0', '<' ) ) { - self::migrate_from_2_0_0(); - } - if ( \version_compare( $version_from_db, '2.3.0', '<' ) ) { - self::migrate_from_2_2_0(); - } - if ( \version_compare( $version_from_db, '3.0.0', '<' ) ) { - self::migrate_from_2_6_0(); - } - if ( \version_compare( $version_from_db, '4.0.0', '<' ) ) { - self::migrate_to_4_0_0(); - } - if ( \version_compare( $version_from_db, '4.1.0', '<' ) ) { - self::migrate_to_4_1_0(); - } - if ( \version_compare( $version_from_db, '4.5.0', '<' ) ) { - \wp_schedule_single_event( \time() + MINUTE_IN_SECONDS, 'activitypub_update_comment_counts' ); - } - if ( \version_compare( $version_from_db, '4.7.1', '<' ) ) { - self::migrate_to_4_7_1(); - } - if ( \version_compare( $version_from_db, '4.7.2', '<' ) ) { - self::migrate_to_4_7_2(); - } - if ( \version_compare( $version_from_db, '4.7.3', '<' ) ) { - add_action( 'init', 'flush_rewrite_rules', 20 ); - } - if ( \version_compare( $version_from_db, '5.0.0', '<' ) ) { - Scheduler::register_schedules(); - \wp_schedule_single_event( \time(), 'activitypub_upgrade', array( 'create_post_outbox_items' ) ); - \wp_schedule_single_event( \time() + 15, 'activitypub_upgrade', array( 'create_comment_outbox_items' ) ); - add_action( 'init', 'flush_rewrite_rules', 20 ); - } - if ( \version_compare( $version_from_db, '5.2.0', '<' ) ) { - Scheduler::register_schedules(); - } - if ( \version_compare( $version_from_db, '5.4.0', '<' ) ) { - \wp_schedule_single_event( \time(), 'activitypub_upgrade', array( 'update_actor_json_slashing' ) ); - \wp_schedule_single_event( \time(), 'activitypub_upgrade', array( 'update_comment_author_emails' ) ); - \add_action( 'init', 'flush_rewrite_rules', 20 ); - } - if ( \version_compare( $version_from_db, '5.7.0', '<' ) ) { - self::delete_mastodon_api_orphaned_extra_fields(); - } - if ( \version_compare( $version_from_db, '5.8.0', '<' ) ) { - self::update_notification_options(); - } - - /* - * Add new update routines above this comment. ^ - * - * Use 'unreleased' as the version number for new migrations and add tests for the callback directly. - * The release script will automatically replace it with the actual version number. - * Example: - * - * if ( \version_compare( $version_from_db, 'unreleased', '<' ) ) { - * // Update routine. - * } - */ - - /** - * Fires when the system has to be migrated. - * - * @param string $version_from_db The version from which to migrate. - * @param string $target_version The target version to migrate to. - */ - \do_action( 'activitypub_migrate', $version_from_db, ACTIVITYPUB_PLUGIN_VERSION ); - - \update_option( 'activitypub_db_version', ACTIVITYPUB_PLUGIN_VERSION ); - - self::unlock(); - } - - /** - * Asynchronously migrates the database structure. - * - * @param string $version_from_db The version from which to migrate. - */ - public static function async_migration( $version_from_db ) { - if ( \version_compare( $version_from_db, '1.0.0', '<' ) ) { - self::migrate_from_0_17(); - } - } - - /** - * Asynchronously runs upgrade routines. - * - * @param callable $callback Callable upgrade routine. Must be a method of this class. - * @params mixed ...$args Optional. Parameters that get passed to the callback. - */ - public static function async_upgrade( $callback ) { - $args = \func_get_args(); - - // Bail if the existing lock is still valid. - if ( self::is_locked() ) { - \wp_schedule_single_event( time() + MINUTE_IN_SECONDS, 'activitypub_upgrade', $args ); - return; - } - - self::lock(); - - $callback = array_shift( $args ); // Remove $callback from arguments. - $next = \call_user_func_array( array( self::class, $callback ), $args ); - - self::unlock(); - - if ( ! empty( $next ) ) { - // Schedule the next run, adding the result to the arguments. - \wp_schedule_single_event( - \time() + 30, - 'activitypub_upgrade', - \array_merge( array( $callback ), \array_values( $next ) ) - ); - } - } - - /** - * Updates the custom template to use shortcodes instead of the deprecated templates. - */ - private static function migrate_from_0_16() { - // Get the custom template. - $old_content = \get_option( 'activitypub_custom_post_content', ACTIVITYPUB_CUSTOM_POST_CONTENT ); - - /* - * If the old content exists but is a blank string, we're going to need a flag to updated it even - * after setting it to the default contents. - */ - $need_update = false; - - // If the old contents is blank, use the defaults. - if ( '' === $old_content ) { - $old_content = ACTIVITYPUB_CUSTOM_POST_CONTENT; - $need_update = true; - } - - // Set the new content to be the old content. - $content = $old_content; - - // Convert old templates to shortcodes. - $content = \str_replace( '%title%', '[ap_title]', $content ); - $content = \str_replace( '%excerpt%', '[ap_excerpt]', $content ); - $content = \str_replace( '%content%', '[ap_content]', $content ); - $content = \str_replace( '%permalink%', '[ap_permalink type="html"]', $content ); - $content = \str_replace( '%shortlink%', '[ap_shortlink type="html"]', $content ); - $content = \str_replace( '%hashtags%', '[ap_hashtags]', $content ); - $content = \str_replace( '%tags%', '[ap_hashtags]', $content ); - - // Store the new template if required. - if ( $content !== $old_content || $need_update ) { - \update_option( 'activitypub_custom_post_content', $content ); - } - } - - /** - * Updates the DB-schema of the followers-list. - */ - public static function migrate_from_0_17() { - // Migrate followers. - foreach ( get_users( array( 'fields' => 'ID' ) ) as $user_id ) { - $followers = get_user_meta( $user_id, 'activitypub_followers', true ); - - if ( $followers ) { - foreach ( $followers as $actor ) { - Followers::add_follower( $user_id, $actor ); - } - } - } - - Activitypub::flush_rewrite_rules(); - } - - /** - * Clear the cache after updating to 1.3.0. - */ - private static function migrate_from_1_2_0() { - $user_ids = \get_users( - array( - 'fields' => 'ID', - 'capability__in' => array( 'publish_posts' ), - ) - ); - - foreach ( $user_ids as $user_id ) { - wp_cache_delete( sprintf( Followers::CACHE_KEY_INBOXES, $user_id ), 'activitypub' ); - } - } - - /** - * Unschedule Hooks after updating to 2.0.0. - */ - private static function migrate_from_2_0_0() { - wp_clear_scheduled_hook( 'activitypub_send_post_activity' ); - wp_clear_scheduled_hook( 'activitypub_send_update_activity' ); - wp_clear_scheduled_hook( 'activitypub_send_delete_activity' ); - - wp_unschedule_hook( 'activitypub_send_post_activity' ); - wp_unschedule_hook( 'activitypub_send_update_activity' ); - wp_unschedule_hook( 'activitypub_send_delete_activity' ); - - $object_type = \get_option( 'activitypub_object_type', ACTIVITYPUB_DEFAULT_OBJECT_TYPE ); - if ( 'article' === $object_type ) { - \update_option( 'activitypub_object_type', 'wordpress-post-format' ); - } - } - - /** - * Add the ActivityPub capability to all users that can publish posts - * Delete old meta to store followers. - */ - private static function migrate_from_2_2_0() { - // Add the ActivityPub capability to all users that can publish posts. - self::add_activitypub_capability(); - } - - /** - * Rename DB fields. - */ - private static function migrate_from_2_6_0() { - wp_cache_flush(); - - self::update_usermeta_key( 'activitypub_user_description', 'activitypub_description' ); - - self::update_options_key( 'activitypub_blog_user_description', 'activitypub_blog_description' ); - self::update_options_key( 'activitypub_blog_user_identifier', 'activitypub_blog_identifier' ); - } - - /** - * * Update actor-mode settings. - * * Get the ID of the latest blog post and save it to the options table. - */ - private static function migrate_to_4_0_0() { - $latest_post_id = 0; - - // Get the ID of the latest blog post and save it to the options table. - $latest_post = get_posts( - array( - 'numberposts' => 1, - 'orderby' => 'ID', - 'order' => 'DESC', - 'post_type' => 'any', - 'post_status' => 'publish', - ) - ); - - if ( $latest_post ) { - $latest_post_id = $latest_post[0]->ID; - } - - \update_option( 'activitypub_last_post_with_permalink_as_id', $latest_post_id ); - - $users = \get_users( - array( - 'capability__in' => array( 'activitypub' ), - ) - ); - - foreach ( $users as $user ) { - $followers = Followers::get_followers( $user->ID ); - - if ( $followers ) { - \update_user_option( $user->ID, 'activitypub_use_permalink_as_id', '1' ); - } - } - - $followers = Followers::get_followers( Actors::BLOG_USER_ID ); - - if ( $followers ) { - \update_option( 'activitypub_use_permalink_as_id_for_blog', '1' ); - } - - self::migrate_actor_mode(); - } - - /** - * Upate to 4.1.0 - * - * * Migrate the `activitypub_post_content_type` to only use `activitypub_custom_post_content`. - */ - public static function migrate_to_4_1_0() { - $content_type = \get_option( 'activitypub_post_content_type' ); - - switch ( $content_type ) { - case 'excerpt': - $template = "[ap_excerpt]\n\n[ap_permalink type=\"html\"]"; - break; - case 'title': - $template = "[ap_title type=\"html\"]\n\n[ap_permalink type=\"html\"]"; - break; - case 'content': - $template = "[ap_content]\n\n[ap_permalink type=\"html\"]\n\n[ap_hashtags]"; - break; - case 'custom': - $template = \get_option( 'activitypub_custom_post_content', ACTIVITYPUB_CUSTOM_POST_CONTENT ); - break; - default: - $template = ACTIVITYPUB_CUSTOM_POST_CONTENT; - break; - } - - \update_option( 'activitypub_custom_post_content', $template ); - - \delete_option( 'activitypub_post_content_type' ); - - $object_type = \get_option( 'activitypub_object_type', false ); - if ( ! $object_type ) { - \update_option( 'activitypub_object_type', 'note' ); - } - - // Clean up empty visibility meta. - global $wpdb; - $wpdb->query( // phpcs:ignore WordPress.DB.DirectDatabaseQuery - "DELETE FROM $wpdb->postmeta - WHERE meta_key = 'activitypub_content_visibility' - AND (meta_value IS NULL OR meta_value = '')" - ); - } - - /** - * Updates post meta keys to be prefixed with an underscore. - */ - public static function migrate_to_4_7_1() { - global $wpdb; - - $meta_keys = array( - 'activitypub_actor_json', - 'activitypub_canonical_url', - 'activitypub_errors', - 'activitypub_inbox', - 'activitypub_user_id', - ); - - foreach ( $meta_keys as $meta_key ) { - // phpcs:ignore WordPress.DB - $wpdb->update( $wpdb->postmeta, array( 'meta_key' => '_' . $meta_key ), array( 'meta_key' => $meta_key ) ); - } - } - - /** - * Clears the post cache for Followers, we should have done this in 4.7.1 when we renamed those keys. - */ - public static function migrate_to_4_7_2() { - global $wpdb; - // phpcs:ignore WordPress.DB - $followers = $wpdb->get_col( - $wpdb->prepare( "SELECT ID FROM {$wpdb->posts} WHERE post_type = %s", Followers::POST_TYPE ) - ); - foreach ( $followers as $id ) { - clean_post_cache( $id ); - } - } - - /** - * Update comment counts for posts in batches. - * - * @see Comment::pre_wp_update_comment_count_now() - * @param int $batch_size Optional. Number of posts to process per batch. Default 100. - * @param int $offset Optional. Number of posts to skip. Default 0. - */ - public static function update_comment_counts( $batch_size = 100, $offset = 0 ) { - global $wpdb; - - // Bail if the existing lock is still valid. - if ( self::is_locked() ) { - \wp_schedule_single_event( - time() + ( 5 * MINUTE_IN_SECONDS ), - 'activitypub_update_comment_counts', - array( - 'batch_size' => $batch_size, - 'offset' => $offset, - ) - ); - return; - } - - self::lock(); - - Comment::register_comment_types(); - $comment_types = Comment::get_comment_type_slugs(); - $type_inclusion = "AND comment_type IN ('" . implode( "','", $comment_types ) . "')"; - - // Get and process this batch. - $post_ids = $wpdb->get_col( // phpcs:ignore WordPress.DB - $wpdb->prepare( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT DISTINCT comment_post_ID FROM {$wpdb->comments} WHERE comment_approved = '1' {$type_inclusion} ORDER BY comment_post_ID LIMIT %d OFFSET %d", - $batch_size, - $offset - ) - ); - - foreach ( $post_ids as $post_id ) { - \wp_update_comment_count_now( $post_id ); - } - - if ( count( $post_ids ) === $batch_size ) { - // Schedule next batch. - \wp_schedule_single_event( - time() + MINUTE_IN_SECONDS, - 'activitypub_update_comment_counts', - array( - 'batch_size' => $batch_size, - 'offset' => $offset + $batch_size, - ) - ); - } - - self::unlock(); - } - - /** - * Create outbox items for posts in batches. - * - * @param int $batch_size Optional. Number of posts to process per batch. Default 50. - * @param int $offset Optional. Number of posts to skip. Default 0. - * @return array|null Array with batch size and offset if there are more posts to process, null otherwise. - */ - public static function create_post_outbox_items( $batch_size = 50, $offset = 0 ) { - $posts = \get_posts( - array( - // our own `ap_outbox` will be excluded from `any` by virtue of its `exclude_from_search` arg. - 'post_type' => 'any', - 'posts_per_page' => $batch_size, - 'offset' => $offset, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => 'activitypub_status', - 'value' => 'federated', - ), - ), - ) - ); - - // Avoid multiple queries for post meta. - \update_postmeta_cache( \wp_list_pluck( $posts, 'ID' ) ); - - foreach ( $posts as $post ) { - $visibility = \get_post_meta( $post->ID, 'activitypub_content_visibility', true ); - - self::add_to_outbox( $post, 'Create', $post->post_author, $visibility ); - - // Add Update activity when the post has been modified. - if ( $post->post_modified !== $post->post_date ) { - self::add_to_outbox( $post, 'Update', $post->post_author, $visibility ); - } - } - - if ( count( $posts ) === $batch_size ) { - return array( - 'batch_size' => $batch_size, - 'offset' => $offset + $batch_size, - ); - } - - return null; - } - - /** - * Create outbox items for comments in batches. - * - * @param int $batch_size Optional. Number of posts to process per batch. Default 50. - * @param int $offset Optional. Number of posts to skip. Default 0. - * @return array|null Array with batch size and offset if there are more posts to process, null otherwise. - */ - public static function create_comment_outbox_items( $batch_size = 50, $offset = 0 ) { - $comments = \get_comments( - array( - 'author__not_in' => array( 0 ), // Limit to comments by registered users. - 'number' => $batch_size, - 'offset' => $offset, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => 'activitypub_status', - 'value' => 'federated', - ), - ), - ) - ); - - foreach ( $comments as $comment ) { - self::add_to_outbox( $comment, 'Create', $comment->user_id ); - } - - if ( count( $comments ) === $batch_size ) { - return array( - 'batch_size' => $batch_size, - 'offset' => $offset + $batch_size, - ); - } - - return null; - } - - /** - * Update _activitypub_actor_json meta values to ensure they are properly slashed. - * - * @param int $batch_size Optional. Number of meta values to process per batch. Default 100. - * @param int $offset Optional. Number of meta values to skip. Default 0. - * @return array|null Array with batch size and offset if there are more meta values to process, null otherwise. - */ - public static function update_actor_json_slashing( $batch_size = 100, $offset = 0 ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $meta_values = $wpdb->get_results( - $wpdb->prepare( - "SELECT post_id, meta_value FROM {$wpdb->postmeta} WHERE meta_key = '_activitypub_actor_json' LIMIT %d OFFSET %d", - $batch_size, - $offset - ) - ); - - foreach ( $meta_values as $meta ) { - $json = \json_decode( $meta->meta_value, true ); - - // If json_decode fails, try adding slashes. - if ( null === $json && \json_last_error() !== JSON_ERROR_NONE ) { - $escaped_value = \preg_replace( '#\\\\(?!["\\\\/bfnrtu])#', '\\\\\\\\', $meta->meta_value ); - $json = \json_decode( $escaped_value, true ); - - // Update the meta if json_decode succeeds with slashes. - if ( null !== $json && \json_last_error() === JSON_ERROR_NONE ) { - \update_post_meta( $meta->post_id, '_activitypub_actor_json', \wp_slash( $escaped_value ) ); - } - } - } - - if ( \count( $meta_values ) === $batch_size ) { - return array( - 'batch_size' => $batch_size, - 'offset' => $offset + $batch_size, - ); - } - - return null; - } - - /** - * Update comment author emails with webfinger addresses for ActivityPub comments. - * - * @param int $batch_size Optional. Number of comments to process per batch. Default 50. - * @param int $offset Optional. Number of comments to skip. Default 0. - * @return array|null Array with batch size and offset if there are more comments to process, null otherwise. - */ - public static function update_comment_author_emails( $batch_size = 50, $offset = 0 ) { - $comments = \get_comments( - array( - 'number' => $batch_size, - 'offset' => $offset, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => 'protocol', - 'value' => 'activitypub', - ), - ), - ) - ); - - foreach ( $comments as $comment ) { - $comment_author_url = $comment->comment_author_url; - if ( empty( $comment_author_url ) ) { - continue; - } - - $webfinger = Webfinger::uri_to_acct( $comment_author_url ); - if ( \is_wp_error( $webfinger ) ) { - continue; - } - - \wp_update_comment( - array( - 'comment_ID' => $comment->comment_ID, - 'comment_author_email' => \str_replace( 'acct:', '', $webfinger ), - ) - ); - } - - if ( count( $comments ) === $batch_size ) { - return array( - 'batch_size' => $batch_size, - 'offset' => $offset + $batch_size, - ); - } - - return null; - } - - /** - * Set the defaults needed for the plugin to work. - * - * Add the ActivityPub capability to all users that can publish posts. - */ - public static function add_default_settings() { - self::add_activitypub_capability(); - self::add_default_extra_field(); - } - - /** - * Add an activity to the outbox without federating it. - * - * @param \WP_Post|\WP_Comment $comment The comment or post object. - * @param string $activity_type The type of activity. - * @param int $user_id The user ID. - * @param string $visibility Optional. The visibility of the content. Default 'public'. - */ - private static function add_to_outbox( $comment, $activity_type, $user_id, $visibility = ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC ) { - $transformer = Factory::get_transformer( $comment ); - if ( ! $transformer || \is_wp_error( $transformer ) ) { - return; - } - - $activity = $transformer->to_activity( $activity_type ); - if ( ! $activity || \is_wp_error( $activity ) ) { - return; - } - - // If the user is disabled, fall back to the blog user when available. - if ( ! user_can_activitypub( $user_id ) ) { - if ( user_can_activitypub( Actors::BLOG_USER_ID ) ) { - $user_id = Actors::BLOG_USER_ID; - } else { - return; - } - } - - $post_id = Outbox::add( $activity, $user_id, $visibility ); - - // Immediately set to publish, no federation needed. - \wp_publish_post( $post_id ); - } - - /** - * Add the ActivityPub capability to all users that can publish posts. - */ - private static function add_activitypub_capability() { - // Get all WP_User objects that can publish posts. - $users = \get_users( - array( - 'capability__in' => array( 'publish_posts' ), - ) - ); - - // Add ActivityPub capability to all users that can publish posts. - foreach ( $users as $user ) { - $user->add_cap( 'activitypub' ); - } - } - - /** - * Add a default extra field for the user. - */ - private static function add_default_extra_field() { - $users = \get_users( - array( - 'capability__in' => array( 'activitypub' ), - ) - ); - - $title = \__( 'Powered by', 'activitypub' ); - $content = 'WordPress'; - - // Add a default extra field for each user. - foreach ( $users as $user ) { - \wp_insert_post( - array( - 'post_type' => Extra_Fields::USER_POST_TYPE, - 'post_author' => $user->ID, - 'post_status' => 'publish', - 'post_title' => $title, - 'post_content' => $content, - ) - ); - } - - \wp_insert_post( - array( - 'post_type' => Extra_Fields::BLOG_POST_TYPE, - 'post_author' => 0, - 'post_status' => 'publish', - 'post_title' => $title, - 'post_content' => $content, - ) - ); - } - - /** - * Rename meta keys. - * - * @param string $old_key The old comment meta key. - * @param string $new_key The new comment meta key. - */ - private static function update_usermeta_key( $old_key, $new_key ) { - global $wpdb; - - $wpdb->update( // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $wpdb->usermeta, - array( 'meta_key' => $new_key ), // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_key - array( 'meta_key' => $old_key ), // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_key - array( '%s' ), - array( '%s' ) - ); - } - - /** - * Rename option keys. - * - * @param string $old_key The old option key. - * @param string $new_key The new option key. - */ - private static function update_options_key( $old_key, $new_key ) { - global $wpdb; - - $wpdb->update( // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $wpdb->options, - array( 'option_name' => $new_key ), // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_key - array( 'option_name' => $old_key ), // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_key - array( '%s' ), - array( '%s' ) - ); - } - - /** - * Migrate the actor mode settings. - */ - public static function migrate_actor_mode() { - $blog_profile = \get_option( 'activitypub_enable_blog_user', '0' ); - $author_profiles = \get_option( 'activitypub_enable_users', '1' ); - - if ( - '1' === $blog_profile && - '1' === $author_profiles - ) { - \update_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_AND_BLOG_MODE ); - } elseif ( - '1' === $blog_profile && - '1' !== $author_profiles - ) { - \update_option( 'activitypub_actor_mode', ACTIVITYPUB_BLOG_MODE ); - } elseif ( - '1' !== $blog_profile && - '1' === $author_profiles - ) { - \update_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_MODE ); - } - } - - /** - * Deletes user extra fields where the author is the blog user. - * - * These extra fields were created when the Enable Mastodon Apps integration passed - * an author_url instead of a user_id to the mastodon_api_account filter. This caused - * Extra_Fields::default_actor_extra_fields() to run but fail to cache the fact it ran - * for non-existent users. The result is a number of user extra fields with no author. - * - * @ticket https://github.com/Automattic/wordpress-activitypub/pull/1554 - */ - public static function delete_mastodon_api_orphaned_extra_fields() { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $wpdb->delete( - $wpdb->posts, - array( - 'post_type' => Extra_Fields::USER_POST_TYPE, - 'post_author' => Actors::BLOG_USER_ID, - ) - ); - } - - /** - * Update notification options. - */ - public static function update_notification_options() { - $new_dm = \get_option( 'activitypub_mailer_new_dm', '1' ); - $new_follower = \get_option( 'activitypub_mailer_new_follower', '1' ); - - // Add the blog user notification options. - \add_option( 'activitypub_blog_user_mailer_new_dm', $new_dm ); - \add_option( 'activitypub_blog_user_mailer_new_follower', $new_follower ); - \add_option( 'activitypub_blog_user_mailer_new_mention', '1' ); - - // Add the actor notification options. - foreach ( Actors::get_collection() as $actor ) { - \update_user_option( $actor->get__id(), 'activitypub_mailer_new_dm', $new_dm ); - \update_user_option( $actor->get__id(), 'activitypub_mailer_new_follower', $new_follower ); - \update_user_option( $actor->get__id(), 'activitypub_mailer_new_mention', '1' ); - } - - // Delete the old notification options. - \delete_option( 'activitypub_mailer_new_dm' ); - \delete_option( 'activitypub_mailer_new_follower' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-move.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-move.php deleted file mode 100644 index 18e54ad4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-move.php +++ /dev/null @@ -1,313 +0,0 @@ -get__id() > 0 ) { - \update_user_option( $user->get__id(), 'activitypub_moved_to', $to ); - } else { - \update_option( 'activitypub_blog_user_moved_to', $to ); - } - - $response = Http::get_remote_object( $to ); - - if ( \is_wp_error( $response ) ) { - return $response; - } - - $target_actor = new Actor(); - $target_actor->from_array( $response ); - - // Check if the `Move` Activity is valid. - $also_known_as = $target_actor->get_also_known_as() ?? array(); - if ( ! in_array( $from, $also_known_as, true ) ) { - return new \WP_Error( 'invalid_target', __( 'Invalid target', 'activitypub' ) ); - } - - $activity = new Activity(); - $activity->set_type( 'Move' ); - $activity->set_actor( $user->get_id() ); - $activity->set_origin( $user->get_id() ); - $activity->set_object( $user->get_id() ); - $activity->set_target( $target_actor->get_id() ); - - // Add to outbox. - return add_to_outbox( $activity, null, $user->get__id(), ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC ); - } - - /** - * Internal Move. - * - * Move an ActivityPub Actor from one location (internal) to another (internal). - * - * This helps migrating abandoned profiles to `Move` to other profiles: - * - * `Move::internally( 'https://example.com/?author=123', 'https://example.com/?author=321' );` - * - * ... or to change Actor-IDs like: - * - * `Move::internally( 'https://example.com/author/foo', 'https://example.com/?author=123' );` - * - * @param string $from The current account URL. - * @param string $to The new account URL. - * - * @return int|bool|\WP_Error The ID of the outbox item or false or WP_Error on failure. - */ - public static function internally( $from, $to ) { - $user = Actors::get_by_various( $from ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - // Add the old account URL to alsoKnownAs. - if ( $user->get__id() > 0 ) { - self::update_user_also_known_as( $user->get__id(), $from ); - \update_user_option( $user->get__id(), 'activitypub_moved_to', $to ); - } else { - self::update_blog_also_known_as( $from ); - \update_option( 'activitypub_blog_user_moved_to', $to ); - } - - // check if `$from` is a URL or an ID. - if ( \filter_var( $from, FILTER_VALIDATE_URL ) ) { - $actor = $from; - } else { - $actor = $user->get_id(); - } - - $activity = new Activity(); - $activity->set_type( 'Move' ); - $activity->set_actor( $actor ); - $activity->set_origin( $actor ); - $activity->set_object( $actor ); - $activity->set_target( $to ); - - return add_to_outbox( $activity, null, $user->get__id(), ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC ); - } - - /** - * Update the alsoKnownAs property of a user. - * - * @param int $user_id The user ID. - * @param string $from The current account URL. - */ - private static function update_user_also_known_as( $user_id, $from ) { - // phpcs:ignore Universal.Operators.DisallowShortTernary.Found - $also_known_as = \get_user_option( 'activitypub_also_known_as', $user_id ) ?: array(); - $also_known_as[] = $from; - - \update_user_option( $user_id, 'activitypub_also_known_as', $also_known_as ); - } - - /** - * Update the alsoKnownAs property of the blog. - * - * @param string $from The current account URL. - */ - private static function update_blog_also_known_as( $from ) { - $also_known_as = \get_option( 'activitypub_blog_user_also_known_as', array() ); - $also_known_as[] = $from; - - \update_option( 'activitypub_blog_user_also_known_as', $also_known_as ); - } - - /** - * Change domain for all ActivityPub Actors. - * - * This method handles domain migration according to the ActivityPub Data Portability spec. - * It stores the old host and calls Move::internally for each available profile. - * It also caches the JSON representation of the old Actor for future lookups. - * - * @param string $from The old domain. - * @param string $to The new domain. - * - * @return array Array of results from Move::internally calls. - */ - public static function change_domain( $from, $to ) { - // Get all actors that need to be migrated. - $actors = Actors::get_all(); - - $results = array(); - $to_host = \wp_parse_url( $to, \PHP_URL_HOST ); - $from_host = \wp_parse_url( $from, \PHP_URL_HOST ); - - // Store the old host for future reference. - \update_option( 'activitypub_old_host', $from_host ); - - // Process each actor. - foreach ( $actors as $actor ) { - $actor_id = $actor->get_id(); - - // Replace the new host with the old host in the actor ID. - $old_actor_id = str_replace( $to_host, $from_host, $actor_id ); - - // Call Move::internally for this actor. - $result = self::internally( $old_actor_id, $actor_id ); - - if ( \is_wp_error( $result ) ) { - // Log the error and continue with the next actor. - Debug::write_log( 'Error moving actor: ' . $actor_id . ' - ' . $result->get_error_message() ); - continue; - } - - $json = str_replace( $to_host, $from_host, $actor->to_json() ); - - // Save the current actor data after migration. - if ( $actor instanceof Blog ) { - \update_option( 'activitypub_blog_user_old_host_data', $json, false ); - } else { - \update_user_option( $actor->get__id(), 'activitypub_old_host_data', $json, false ); - } - - $results[] = array( - 'actor' => $actor_id, - 'result' => $result, - ); - } - - return $results; - } - - /** - * Maybe initiate old user. - * - * This method checks if the current request domain matches the old host. - * If it does, it retrieves the cached data for the user and populates the instance. - * - * @param Blog|User $instance The Blog or User instance to populate. - */ - public static function maybe_initiate_old_user( $instance ) { - if ( ! Query::get_instance()->is_old_host_request() ) { - return; - } - - if ( $instance instanceof Blog ) { - $cached_data = \get_option( 'activitypub_blog_user_old_host_data' ); - } elseif ( $instance instanceof User ) { - $cached_data = \get_user_option( 'activitypub_old_host_data', $instance->get__id() ); - } - - if ( ! empty( $cached_data ) ) { - $instance->from_json( $cached_data ); - } - } - - /** - * Pre-send to inboxes. - * - * @param string $json The ActivityPub Activity JSON. - */ - public static function pre_send_to_inboxes( $json ) { - $json = json_decode( $json, true ); - - if ( 'Move' !== $json['type'] ) { - return; - } - - if ( is_same_domain( $json['object'] ) ) { - return; - } - - Query::get_instance()->set_old_host_request(); - } - - /** - * Filter to return the old blog username. - * - * @param null $pre The pre-existing value. - * @param string $username The username to check. - * - * @return Blog|null The old blog instance or null. - */ - public static function old_blog_username( $pre, $username ) { - $old_host = \get_option( 'activitypub_old_host' ); - - // Special case for Blog Actor on old host. - if ( $old_host === $username && Query::get_instance()->is_old_host_request() ) { - // Return a new Blog instance which will load the cached data in its constructor. - $pre = new Blog(); - } - - return $pre; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-notification.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-notification.php deleted file mode 100644 index 68283133..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-notification.php +++ /dev/null @@ -1,77 +0,0 @@ -type = $type; - $this->actor = $actor; - $this->object = $activity; - $this->target = $target; - } - - /** - * Send the notification. - */ - public function send() { - $type = \strtolower( $this->type ); - - /** - * Action to send ActivityPub notifications. - * - * @param Notification $instance The notification object. - */ - do_action( 'activitypub_notification', $this ); - - /** - * Type-specific action to send ActivityPub notifications. - * - * @param Notification $instance The notification object. - */ - do_action( "activitypub_notification_{$type}", $this ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-options.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-options.php deleted file mode 100644 index d30ef9ad..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-options.php +++ /dev/null @@ -1,124 +0,0 @@ -activitypub_object ) { - return $this->activitypub_object; - } - - if ( $this->prepare_activitypub_data() ) { - return $this->activitypub_object; - } - - $queried_object = $this->get_queried_object(); - $transformer = Factory::get_transformer( $queried_object ); - - if ( $transformer && ! \is_wp_error( $transformer ) ) { - $this->activitypub_object = $transformer->to_object(); - } - - return $this->activitypub_object; - } - - /** - * Get the ActivityPub object ID. - * - * @return string The ActivityPub object ID. - */ - public function get_activitypub_object_id() { - if ( $this->activitypub_object_id ) { - return $this->activitypub_object_id; - } - - if ( $this->prepare_activitypub_data() ) { - return $this->activitypub_object_id; - } - - $queried_object = $this->get_queried_object(); - $transformer = Factory::get_transformer( $queried_object ); - - if ( $transformer && ! \is_wp_error( $transformer ) ) { - $this->activitypub_object_id = $transformer->to_id(); - } - - return $this->activitypub_object_id; - } - - /** - * Prepare and set both ActivityPub object and ID for Outbox activities and virtual objects. - * - * @return bool True if an object was found and set, false otherwise. - */ - private function prepare_activitypub_data() { - $queried_object = $this->get_queried_object(); - - // Check for Outbox Activity. - if ( - $queried_object instanceof \WP_Post && - Outbox::POST_TYPE === $queried_object->post_type - ) { - $activitypub_object = Outbox::maybe_get_activity( $queried_object ); - - // Check if the Outbox Activity is public. - if ( ! \is_wp_error( $activitypub_object ) ) { - $this->activitypub_object = $activitypub_object; - $this->activitypub_object_id = $this->activitypub_object->get_id(); - return true; - } - } - - if ( ! $queried_object ) { - // If the object is not a valid ActivityPub object, try to get a virtual object. - $activitypub_object = $this->maybe_get_virtual_object(); - - if ( $activitypub_object ) { - $this->activitypub_object = $activitypub_object; - $this->activitypub_object_id = $this->activitypub_object->get_id(); - return true; - } - } - - return false; - } - - /** - * Get the queried object. - * - * This adds support for Comments by `?c=123` IDs and Users by `?author=123` and `@username` IDs. - * - * @return \WP_Term|\WP_Post_Type|\WP_Post|\WP_User|\WP_Comment|null The queried object. - */ - public function get_queried_object() { - $queried_object = \get_queried_object(); - - // Check Comment by ID. - if ( ! $queried_object ) { - $comment_id = \get_query_var( 'c' ); - if ( $comment_id ) { - $queried_object = \get_comment( $comment_id ); - } - } - - // Check Post by ID (works for custom post types). - if ( ! $queried_object ) { - $post_id = \get_query_var( 'p' ); - if ( $post_id ) { - $queried_object = \get_post( $post_id ); - } - } - - // Try to get Author by ID. - if ( ! $queried_object ) { - $url = $this->get_request_url(); - $author_id = url_to_authorid( $url ); - if ( $author_id ) { - $queried_object = \get_user_by( 'id', $author_id ); - } - } - - /** - * Filters the queried object. - * - * @param \WP_Term|\WP_Post_Type|\WP_Post|\WP_User|\WP_Comment|null $queried_object The queried object. - */ - return apply_filters( 'activitypub_queried_object', $queried_object ); - } - - /** - * Get the virtual object. - * - * Virtual objects are objects that are not stored in the database, but are created on the fly. - * The plugins currently supports two virtual objects: The Blog-Actor and the Application-Actor. - * - * @see \Activitypub\Model\Blog - * @see \Activitypub\Model\Application - * - * @return object|null The virtual object. - */ - protected function maybe_get_virtual_object() { - $url = $this->get_request_url(); - - if ( ! $url ) { - return null; - } - - $author_id = url_to_authorid( $url ); - - if ( ! is_numeric( $author_id ) ) { - $author_id = $url; - } - - $user = Actors::get_by_various( $author_id ); - - if ( \is_wp_error( $user ) || ! $user ) { - return null; - } - - return $user; - } - - /** - * Get the request URL. - * - * @return string|null The request URL. - */ - protected function get_request_url() { - if ( ! isset( $_SERVER['REQUEST_URI'] ) ) { - return null; - } - - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - $url = \wp_unslash( $_SERVER['REQUEST_URI'] ); - $url = \WP_Http::make_absolute_url( $url, \home_url() ); - $url = \sanitize_url( $url ); - - return $url; - } - - /** - * Check if the current request is an ActivityPub request. - * - * @return bool True if the request is an ActivityPub request, false otherwise. - */ - public function is_activitypub_request() { - if ( isset( $this->is_activitypub_request ) ) { - return $this->is_activitypub_request; - } - - global $wp_query; - - // One can trigger an ActivityPub request by adding `?activitypub` to the URL. - if ( - isset( $wp_query->query_vars['activitypub'] ) || - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - isset( $_GET['activitypub'] ) - ) { - \defined( 'ACTIVITYPUB_REQUEST' ) || \define( 'ACTIVITYPUB_REQUEST', true ); - $this->is_activitypub_request = true; - - return true; - } - - /* - * The other (more common) option to make an ActivityPub request - * is to send an Accept header. - */ - if ( isset( $_SERVER['HTTP_ACCEPT'] ) ) { - $accept = \sanitize_text_field( \wp_unslash( $_SERVER['HTTP_ACCEPT'] ) ); - - /* - * $accept can be a single value, or a comma separated list of values. - * We want to support both scenarios, - * and return true when the header includes at least one of the following: - * - application/activity+json - * - application/ld+json - * - application/json - */ - if ( \preg_match( '/(application\/(ld\+json|activity\+json|json))/i', $accept ) ) { - \defined( 'ACTIVITYPUB_REQUEST' ) || \define( 'ACTIVITYPUB_REQUEST', true ); - $this->is_activitypub_request = true; - - return true; - } - } - - $this->is_activitypub_request = false; - - return false; - } - - /** - * Check if the current request is from the old host. - * - * @return bool True if the request is from the old host, false otherwise. - */ - public function is_old_host_request() { - if ( isset( $this->is_old_host_request ) ) { - return $this->is_old_host_request; - } - - $old_host = \get_option( 'activitypub_old_host' ); - - if ( ! $old_host ) { - $this->is_old_host_request = false; - return false; - } - - $request_host = isset( $_SERVER['HTTP_HOST'] ) ? \sanitize_text_field( \wp_unslash( $_SERVER['HTTP_HOST'] ) ) : ''; - $referer_host = isset( $_SERVER['HTTP_REFERER'] ) ? \wp_parse_url( \sanitize_text_field( \wp_unslash( $_SERVER['HTTP_REFERER'] ) ), PHP_URL_HOST ) : ''; - - // Check if the domain matches either the request domain or referer. - $check = $old_host === $request_host || $old_host === $referer_host; - $this->is_old_host_request = $check; - - return $check; - } - - /** - * Fake an old host request. - * - * @param bool $state Optional. The state to set. Default true. - */ - public function set_old_host_request( $state = true ) { - $this->is_old_host_request = $state; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-sanitize.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-sanitize.php deleted file mode 100644 index 42d32491..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-sanitize.php +++ /dev/null @@ -1,122 +0,0 @@ - $sanitized, - 'search_columns' => array( 'user_login', 'user_nicename' ), - 'number' => 1, - 'hide_empty' => true, - 'fields' => 'ID', - ) - ); - - if ( $user->get_results() ) { - \add_settings_error( - 'activitypub_blog_identifier', - 'activitypub_blog_identifier', - \esc_html__( 'You cannot use an existing author’s name for the blog profile ID.', 'activitypub' ) - ); - - return Blog::get_default_username(); - } - - return $sanitized; - } - - /** - * Get the sanitized value of a constant. - * - * @param mixed $value The constant value. - * - * @return string The sanitized value. - */ - public static function constant_value( $value ) { - if ( is_bool( $value ) ) { - return $value ? 'true' : 'false'; - } - - if ( is_string( $value ) ) { - return esc_attr( $value ); - } - - if ( is_array( $value ) ) { - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_print_r - return print_r( $value, true ); - } - - return $value; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-scheduler.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-scheduler.php deleted file mode 100644 index 2e2ca070..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-scheduler.php +++ /dev/null @@ -1,444 +0,0 @@ -get_id(), false ); - - if ( empty( $meta ) || ! is_array( $meta ) || is_wp_error( $meta ) ) { - Followers::add_error( $follower->get__id(), $meta ); - } else { - $follower->from_array( $meta ); - $follower->update(); - } - } - } - - /** - * Cleanup followers. - */ - public static function cleanup_followers() { - $number = 5; - - if ( defined( 'DISABLE_WP_CRON' ) && DISABLE_WP_CRON ) { - $number = 50; - } - - /** - * Filter the number of followers to clean up. - * - * @param int $number The number of followers to clean up. - */ - $number = apply_filters( 'activitypub_update_followers_number', $number ); - $followers = Followers::get_faulty_followers( $number ); - - foreach ( $followers as $follower ) { - $meta = get_remote_metadata_by_actor( $follower->get_url(), false ); - - if ( is_tombstone( $meta ) ) { - $follower->delete(); - } elseif ( empty( $meta ) || ! is_array( $meta ) || is_wp_error( $meta ) ) { - if ( $follower->count_errors() >= 5 ) { - $follower->delete(); - \wp_schedule_single_event( - \time(), - 'activitypub_delete_actor_interactions', - array( $follower->get_id() ) - ); - } else { - Followers::add_error( $follower->get__id(), $meta ); - } - } else { - $follower->reset_errors(); - } - } - } - - /** - * Schedule the outbox item for federation. - * - * @param int $id The ID of the outbox item. - * @param int $offset The offset to add to the scheduled time. - */ - public static function schedule_outbox_activity_for_federation( $id, $offset = 0 ) { - $hook = 'activitypub_process_outbox'; - $args = array( $id ); - - if ( false === wp_next_scheduled( $hook, $args ) ) { - \wp_schedule_single_event( - \time() + $offset, - $hook, - $args - ); - } - } - - /** - * Reprocess the outbox. - */ - public static function reprocess_outbox() { - // Bail if there is a pending batch. - if ( self::next_scheduled_hook( 'activitypub_async_batch' ) ) { - return; - } - - // Bail if there is a batch in progress. - $key = \md5( \serialize( Dispatcher::$callback ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - if ( self::is_locked( $key ) ) { - return; - } - - $ids = \get_posts( - array( - 'post_type' => Outbox::POST_TYPE, - 'post_status' => 'pending', - 'posts_per_page' => 10, - 'fields' => 'ids', - ) - ); - - foreach ( $ids as $id ) { - self::schedule_outbox_activity_for_federation( $id ); - } - } - - /** - * Purge outbox items based on a schedule. - */ - public static function purge_outbox() { - $total_posts = (int) wp_count_posts( Outbox::POST_TYPE )->publish; - if ( $total_posts <= 20 ) { - return; - } - - $days = (int) get_option( 'activitypub_outbox_purge_days', 180 ); - $timezone = new \DateTimeZone( 'UTC' ); - $date = new \DateTime( 'now', $timezone ); - - $date->sub( \DateInterval::createFromDateString( "$days days" ) ); - - $post_ids = get_posts( - array( - 'post_type' => Outbox::POST_TYPE, - 'post_status' => 'any', - 'fields' => 'ids', - 'numberposts' => -1, - 'date_query' => array( - array( - 'before' => $date->format( 'Y-m-d' ), - ), - ), - ) - ); - - foreach ( $post_ids as $post_id ) { - \wp_delete_post( $post_id, true ); - } - } - - /** - * Update schedules when outbox purge days settings change. - * - * @param int $old_value The old value. - * @param int $value The new value. - */ - public static function handle_outbox_purge_days_update( $old_value, $value ) { - if ( 0 === (int) $value ) { - wp_clear_scheduled_hook( 'activitypub_outbox_purge' ); - } elseif ( ! wp_next_scheduled( 'activitypub_outbox_purge' ) ) { - wp_schedule_event( time(), 'daily', 'activitypub_outbox_purge' ); - } - } - - /** - * Asynchronously runs batch processing routines. - * - * The batching part is optional and only comes into play if the callback returns anything. - * Beyond that it's a helper to run a callback asynchronously with locking to prevent simultaneous processing. - * - * @param callable $callback Callable processing routine. - * @params mixed ...$args Optional. Parameters that get passed to the callback. - */ - public static function async_batch( $callback ) { - if ( ! in_array( $callback, self::$batch_callbacks, true ) || ! \is_callable( $callback ) ) { - _doing_it_wrong( __METHOD__, 'The first argument must be a valid callback.', '5.2.0' ); - return; - } - - $args = \func_get_args(); // phpcs:ignore PHPCompatibility.FunctionUse.ArgumentFunctionsReportCurrentValue - $key = \md5( \serialize( $callback ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - - // Bail if the existing lock is still valid. - if ( self::is_locked( $key ) ) { - \wp_schedule_single_event( time() + MINUTE_IN_SECONDS, 'activitypub_async_batch', $args ); - return; - } - - self::lock( $key ); - - $callback = array_shift( $args ); // Remove $callback from arguments. - $next = \call_user_func_array( $callback, $args ); - - self::unlock( $key ); - - if ( ! empty( $next ) ) { - // Schedule the next run, adding the result to the arguments. - \wp_schedule_single_event( - \time() + 30, - 'activitypub_async_batch', - \array_merge( array( $callback ), \array_values( $next ) ) - ); - } - } - - - /** - * Locks the async batch process for individual callbacks to prevent simultaneous processing. - * - * @param string $key Serialized callback name. - * @return bool|int True if the lock was successful, timestamp of existing lock otherwise. - */ - public static function lock( $key ) { - global $wpdb; - - // Try to lock. - $lock_result = (bool) $wpdb->query( $wpdb->prepare( "INSERT IGNORE INTO `$wpdb->options` ( `option_name`, `option_value`, `autoload` ) VALUES (%s, %s, 'no') /* LOCK */", 'activitypub_async_batch_' . $key, \time() ) ); // phpcs:ignore WordPress.DB - - if ( ! $lock_result ) { - $lock_result = \get_option( 'activitypub_async_batch_' . $key ); - } - - return $lock_result; - } - - /** - * Unlocks processing for the async batch callback. - * - * @param string $key Serialized callback name. - */ - public static function unlock( $key ) { - \delete_option( 'activitypub_async_batch_' . $key ); - } - - /** - * Whether the async batch callback is locked. - * - * @param string $key Serialized callback name. - * @return boolean - */ - public static function is_locked( $key ) { - $lock = \get_option( 'activitypub_async_batch_' . $key ); - - if ( ! $lock ) { - return false; - } - - $lock = (int) $lock; - - if ( $lock < \time() - 1800 ) { - self::unlock( $key ); - return false; - } - - return true; - } - - /** - * Get the next scheduled hook. - * - * @param string $hook The hook name. - * @return int|bool The timestamp of the next scheduled hook, or false if none found. - */ - private static function next_scheduled_hook( $hook ) { - $crons = _get_cron_array(); - if ( empty( $crons ) ) { - return false; - } - - // Get next event. - $next = false; - foreach ( $crons as $timestamp => $cron ) { - if ( isset( $cron[ $hook ] ) ) { - $next = $timestamp; - break; - } - } - - return $next; - } - - /** - * Send announces. - * - * @param int $outbox_activity_id The outbox activity ID. - * @param \Activitypub\Activity\Activity $activity The activity object. - * @param int $actor_id The actor ID. - * @param int $content_visibility The content visibility. - */ - public static function schedule_announce_activity( $outbox_activity_id, $activity, $actor_id, $content_visibility ) { - // Only if we're in both Blog and User modes. - if ( ACTIVITYPUB_ACTOR_AND_BLOG_MODE !== \get_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_MODE ) ) { - return; - } - - // Only if this isn't the Blog Actor. - if ( Actors::BLOG_USER_ID === $actor_id ) { - return; - } - - // Only if the content is public or quiet public. - if ( ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC !== $content_visibility ) { - return; - } - - // Only if the activity is a Create. - if ( 'Create' !== $activity->get_type() ) { - return; - } - - if ( ! is_object( $activity->get_object() ) ) { - return; - } - - // Check if the object is an article, image, audio, video, event, or document and ignore profile updates and other activities. - if ( ! in_array( $activity->get_object()->get_type(), Base_Object::TYPES, true ) ) { - return; - } - - $announce = new Activity(); - $announce->set_type( 'Announce' ); - $announce->set_actor( Actors::get_by_id( Actors::BLOG_USER_ID )->get_id() ); - $announce->set_object( $activity ); - - $outbox_activity_id = Outbox::add( $announce, Actors::BLOG_USER_ID ); - - if ( ! $outbox_activity_id ) { - return; - } - - // Schedule the outbox item for federation. - self::schedule_outbox_activity_for_federation( $outbox_activity_id, 120 ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-shortcodes.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-shortcodes.php deleted file mode 100644 index 63d7e6de..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-shortcodes.php +++ /dev/null @@ -1,516 +0,0 @@ -ID ); - - if ( ! $tags ) { - return ''; - } - - $hash_tags = array(); - - foreach ( $tags as $tag ) { - // Tag can be empty. - if ( ! $tag ) { - continue; - } - - $hash_tags[] = \sprintf( - '', - \esc_url( \get_tag_link( $tag ) ), - esc_hashtag( $tag->name ) - ); - } - - return \implode( ' ', $hash_tags ); - } - - /** - * Generates output for the 'ap_title' Shortcode - * - * @param array $atts The Shortcode attributes. - * @param string $content The ActivityPub post-content. - * @param string $tag The tag/name of the Shortcode. - * - * @return string The post title. - */ - public static function title( $atts, $content, $tag ) { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $title = \wp_strip_all_tags( \get_the_title( $item->ID ), true ); - - if ( ! $title ) { - return ''; - } - - $atts = shortcode_atts( - array( 'type' => 'plain' ), - $atts, - $tag - ); - - if ( 'html' !== $atts['type'] ) { - return $title; - } - - return sprintf( '

%s

', $title ); - } - - /** - * Generates output for the 'ap_excerpt' Shortcode - * - * @param array $atts The Shortcode attributes. - * @param string $content The ActivityPub post-content. - * @param string $tag The tag/name of the Shortcode. - * - * @return string The post excerpt. - */ - public static function excerpt( $atts, $content, $tag ) { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $atts = shortcode_atts( - array( 'length' => ACTIVITYPUB_EXCERPT_LENGTH ), - $atts, - $tag - ); - - $excerpt_length = intval( $atts['length'] ); - - if ( 0 === $excerpt_length ) { - $excerpt_length = ACTIVITYPUB_EXCERPT_LENGTH; - } - - $excerpt = generate_post_summary( $item, $excerpt_length ); - - /** This filter is documented in wp-includes/post-template.php */ - return \apply_filters( 'the_excerpt', $excerpt ); - } - - /** - * Generates output for the 'ap_content' Shortcode. - * - * @param array $atts The Shortcode attributes. - * @param string $content The ActivityPub post-content. - * @param string $tag The tag/name of the Shortcode. - * - * @return string The post content. - */ - public static function content( $atts, $content, $tag ) { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - // Prevent inception. - remove_shortcode( 'ap_content' ); - - $atts = shortcode_atts( - array( 'apply_filters' => 'yes' ), - $atts, - $tag - ); - - $content = ''; - - if ( 'attachment' === $item->post_type ) { - // Get title of attachment with fallback to alt text. - $content = wp_get_attachment_caption( $item->ID ); - if ( empty( $content ) ) { - $content = get_post_meta( $item->ID, '_wp_attachment_image_alt', true ); - } - } - - if ( empty( $content ) ) { - $content = \get_post_field( 'post_content', $item ); - } - - if ( 'yes' === $atts['apply_filters'] ) { - /** This filter is documented in wp-includes/post-template.php */ - $content = \apply_filters( 'the_content', $content ); - } else { - if ( site_supports_blocks() ) { - $content = \do_blocks( $content ); - } - $content = \wptexturize( $content ); - $content = \wp_filter_content_tags( $content ); - } - - // Replace script and style elements. - $content = \preg_replace( '@<(script|style)[^>]*?>.*?@si', '', $content ); - $content = \strip_shortcodes( $content ); - $content = \trim( \preg_replace( '/[\n\r\t]/', '', $content ) ); - - add_shortcode( 'ap_content', array( 'Activitypub\Shortcodes', 'content' ) ); - - return $content; - } - - /** - * Generates output for the 'ap_permalink' Shortcode. - * - * @param array $atts The Shortcode attributes. - * @param string $content The ActivityPub post-content. - * @param string $tag The tag/name of the Shortcode. - * - * @return string The post permalink. - */ - public static function permalink( $atts, $content, $tag ) { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $atts = shortcode_atts( - array( - 'type' => 'url', - ), - $atts, - $tag - ); - - if ( 'html' !== $atts['type'] ) { - return \esc_url( \get_permalink( $item->ID ) ); - } - - return \sprintf( - '%1$s', - \esc_url( \get_permalink( $item->ID ) ) - ); - } - - /** - * Generates output for the 'ap_shortlink' Shortcode. - * - * @param array $atts The Shortcode attributes. - * @param string $content The ActivityPub post-content. - * @param string $tag The tag/name of the Shortcode. - * - * @return string The post shortlink. - */ - public static function shortlink( $atts, $content, $tag ) { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $atts = shortcode_atts( - array( - 'type' => 'url', - ), - $atts, - $tag - ); - - if ( 'html' !== $atts['type'] ) { - return \esc_url( \wp_get_shortlink( $item->ID ) ); - } - - return \sprintf( - '%1$s', - \esc_url( \wp_get_shortlink( $item->ID ) ) - ); - } - - /** - * Generates output for the 'ap_image' Shortcode. - * - * @param array $atts The Shortcode attributes. - * @param string $content The ActivityPub post-content. - * @param string $tag The tag/name of the Shortcode. - * - * @return string - */ - public static function image( $atts, $content, $tag ) { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $atts = shortcode_atts( - array( - 'type' => 'full', - ), - $atts, - $tag - ); - - $size = 'full'; - - if ( in_array( - $atts['type'], - array( 'thumbnail', 'medium', 'large', 'full' ), - true - ) ) { - $size = $atts['type']; - } - - $image = \get_the_post_thumbnail_url( $item->ID, $size ); - - if ( ! $image ) { - return ''; - } - - return \esc_url( $image ); - } - - /** - * Generates output for the 'ap_hashcats' Shortcode. - * - * @return string The post categories as hashtags. - */ - public static function hashcats() { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $categories = \get_the_category( $item->ID ); - - if ( ! $categories ) { - return ''; - } - - $hash_tags = array(); - - foreach ( $categories as $category ) { - $hash_tags[] = \sprintf( - '', - \esc_url( \get_category_link( $category ) ), - esc_hashtag( $category->name ) - ); - } - - return \implode( ' ', $hash_tags ); - } - - /** - * Generates output for the 'ap_author' Shortcode. - * - * @return string The author name. - */ - public static function author() { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $author_id = \get_post_field( 'post_author', $item->ID ); - $name = \get_the_author_meta( 'display_name', $author_id ); - - if ( ! $name ) { - return ''; - } - - return wp_strip_all_tags( $name ); - } - - /** - * Generates output for the 'ap_authorurl' Shortcode. - * - * @return string The author URL. - */ - public static function authorurl() { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $author_id = \get_post_field( 'post_author', $item->ID ); - $url = \get_the_author_meta( 'user_url', $author_id ); - - if ( ! $url ) { - return ''; - } - - return \esc_url( $url ); - } - - /** - * Generates output for the 'ap_blogurl' Shortcode. - * - * @return string The site URL. - */ - public static function blogurl() { - return \esc_url( \get_bloginfo( 'url' ) ); - } - - /** - * Generates output for the 'ap_blogname' Shortcode. - * - * @return string - */ - public static function blogname() { - return \wp_strip_all_tags( \get_bloginfo( 'name' ) ); - } - - /** - * Generates output for the 'ap_blogdesc' Shortcode. - * - * @return string The site description. - */ - public static function blogdesc() { - return \wp_strip_all_tags( \get_bloginfo( 'description' ) ); - } - - /** - * Generates output for the 'ap_date' Shortcode. - * - * @return string The post date. - */ - public static function date() { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $datetime = \get_post_datetime( $item ); - $dateformat = \get_option( 'date_format' ); - - $date = $datetime->format( $dateformat ); - - if ( ! $date ) { - return ''; - } - - return $date; - } - - /** - * Generates output for the 'ap_time' Shortcode. - * - * @return string The post time. - */ - public static function time() { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $datetime = \get_post_datetime( $item ); - $timeformat = \get_option( 'time_format' ); - - $date = $datetime->format( $timeformat ); - - if ( ! $date ) { - return ''; - } - - return $date; - } - - /** - * Generates output for the 'ap_datetime' Shortcode. - * - * @return string The post date/time. - */ - public static function datetime() { - $item = self::get_item(); - - if ( ! $item ) { - return ''; - } - - $datetime = \get_post_datetime( $item ); - $dateformat = \get_option( 'date_format' ); - $timeformat = \get_option( 'time_format' ); - - $date = $datetime->format( $dateformat . ' @ ' . $timeformat ); - - if ( ! $date ) { - return ''; - } - - return $date; - } - - /** - * Get a WordPress item to federate. - * - * Checks if item (WP_Post) is "public", a supported post type - * and not password protected. - * - * @return null|\WP_Post The WordPress item. - */ - protected static function get_item() { - $post = \get_post(); - - if ( ! $post ) { - return null; - } - - if ( 'publish' !== \get_post_status( $post ) ) { - return null; - } - - if ( \post_password_required( $post ) ) { - return null; - } - - if ( ! \in_array( \get_post_type( $post ), \get_post_types_by_support( 'activitypub' ), true ) ) { - return null; - } - - return $post; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-signature.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-signature.php deleted file mode 100644 index 350c4d3b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-signature.php +++ /dev/null @@ -1,521 +0,0 @@ - 'sha512', - 'private_key_bits' => 2048, - 'private_key_type' => \OPENSSL_KEYTYPE_RSA, - ); - - $key = \openssl_pkey_new( $config ); - $priv_key = null; - $detail = array(); - if ( $key ) { - \openssl_pkey_export( $key, $priv_key ); - - $detail = \openssl_pkey_get_details( $key ); - } - - // Check if keys are valid. - if ( - empty( $priv_key ) || ! is_string( $priv_key ) || - ! isset( $detail['key'] ) || ! is_string( $detail['key'] ) - ) { - return array( - 'private_key' => null, - 'public_key' => null, - ); - } - - $key_pair = array( - 'private_key' => $priv_key, - 'public_key' => $detail['key'], - ); - - // Persist keys. - \add_option( $option_key, $key_pair ); - - return $key_pair; - } - - /** - * Return the option key for a given user. - * - * @param int $user_id The WordPress User ID. - * - * @return string The option key. - */ - protected static function get_signature_options_key_for( $user_id ) { - $id = $user_id; - - if ( $user_id > 0 ) { - $user = \get_userdata( $user_id ); - // Sanitize username because it could include spaces and special chars. - $id = sanitize_title( $user->user_login ); - } - - return 'activitypub_keypair_for_' . $id; - } - - /** - * Check if there is a legacy key pair - * - * @param int $user_id The WordPress User ID. - * - * @return array|bool The key pair or false. - */ - protected static function check_legacy_key_pair_for( $user_id ) { - switch ( $user_id ) { - case 0: - $public_key = \get_option( 'activitypub_blog_user_public_key' ); - $private_key = \get_option( 'activitypub_blog_user_private_key' ); - break; - case -1: - $public_key = \get_option( 'activitypub_application_user_public_key' ); - $private_key = \get_option( 'activitypub_application_user_private_key' ); - break; - default: - $public_key = \get_user_meta( $user_id, 'magic_sig_public_key', true ); - $private_key = \get_user_meta( $user_id, 'magic_sig_private_key', true ); - break; - } - - if ( ! empty( $public_key ) && is_string( $public_key ) && ! empty( $private_key ) && is_string( $private_key ) ) { - return array( - 'private_key' => $private_key, - 'public_key' => $public_key, - ); - } - - return false; - } - - /** - * Generates the Signature for an HTTP Request. - * - * @param int $user_id The WordPress User ID. - * @param string $http_method The HTTP method. - * @param string $url The URL to send the request to. - * @param string $date The date the request is sent. - * @param string $digest Optional. The digest of the request body. Default null. - * - * @return string The signature. - */ - public static function generate_signature( $user_id, $http_method, $url, $date, $digest = null ) { - $user = Actors::get_by_id( $user_id ); - $key = self::get_private_key_for( $user->get__id() ); - - $url_parts = \wp_parse_url( $url ); - - $host = $url_parts['host']; - $path = '/'; - - // Add path. - if ( ! empty( $url_parts['path'] ) ) { - $path = $url_parts['path']; - } - - // Add query. - if ( ! empty( $url_parts['query'] ) ) { - $path .= '?' . $url_parts['query']; - } - - $http_method = \strtolower( $http_method ); - - if ( ! empty( $digest ) ) { - $signed_string = "(request-target): $http_method $path\nhost: $host\ndate: $date\ndigest: $digest"; - } else { - $signed_string = "(request-target): $http_method $path\nhost: $host\ndate: $date"; - } - - $signature = null; - \openssl_sign( $signed_string, $signature, $key, \OPENSSL_ALGO_SHA256 ); - $signature = \base64_encode( $signature ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - - $key_id = $user->get_id() . '#main-key'; - - if ( ! empty( $digest ) ) { - return \sprintf( 'keyId="%s",algorithm="rsa-sha256",headers="(request-target) host date digest",signature="%s"', $key_id, $signature ); - } else { - return \sprintf( 'keyId="%s",algorithm="rsa-sha256",headers="(request-target) host date",signature="%s"', $key_id, $signature ); - } - } - - /** - * Verifies the http signatures - * - * @param WP_REST_Request|array $request The request object or $_SERVER array. - * - * @return bool|WP_Error A boolean or WP_Error. - */ - public static function verify_http_signature( $request ) { - if ( is_object( $request ) ) { // REST Request object. - // Check if route starts with "index.php". - if ( str_starts_with( $request->get_route(), '/index.php' ) || ! rest_get_url_prefix() ) { - $route = $request->get_route(); - } else { - $route = '/' . rest_get_url_prefix() . '/' . ltrim( $request->get_route(), '/' ); - } - - // Fix route for subdirectory installs. - $path = \wp_parse_url( \get_home_url(), PHP_URL_PATH ); - - if ( \is_string( $path ) ) { - $path = trim( $path, '/' ); - } - - if ( $path ) { - $route = '/' . $path . $route; - } - - $headers = $request->get_headers(); - $headers['(request-target)'][0] = strtolower( $request->get_method() ) . ' ' . $route; - } else { - $request = self::format_server_request( $request ); - $headers = $request['headers']; // $_SERVER array - $headers['(request-target)'][0] = strtolower( $headers['request_method'][0] ) . ' ' . $headers['request_uri'][0]; - } - - if ( array_key_exists( 'signature', $headers ) ) { - $signature_block = self::parse_signature_header( $headers['signature'][0] ); - } elseif ( array_key_exists( 'authorization', $headers ) ) { - $signature_block = self::parse_signature_header( $headers['authorization'][0] ); - } else { - return new WP_Error( 'activitypub_signature', __( 'Incompatible request signature. keyId and signature are required', 'activitypub' ), array( 'status' => 401 ) ); - } - - $signed_headers = $signature_block['headers']; - - $signed_data = self::get_signed_data( $signed_headers, $signature_block, $headers ); - if ( ! $signed_data ) { - return new WP_Error( 'activitypub_signature', __( 'Signed request date outside acceptable time window', 'activitypub' ), array( 'status' => 401 ) ); - } - - $algorithm = self::get_signature_algorithm( $signature_block ); - if ( ! $algorithm ) { - return new WP_Error( 'activitypub_signature', __( 'Unsupported signature algorithm (only rsa-sha256 and hs2019 are supported)', 'activitypub' ), array( 'status' => 401 ) ); - } - - if ( \in_array( 'digest', $signed_headers, true ) && isset( $body ) ) { - if ( is_array( $headers['digest'] ) ) { - $headers['digest'] = $headers['digest'][0]; - } - $hashalg = 'sha256'; - $digest = explode( '=', $headers['digest'], 2 ); - if ( 'SHA-256' === $digest[0] ) { - $hashalg = 'sha256'; - } - if ( 'SHA-512' === $digest[0] ) { - $hashalg = 'sha512'; - } - - if ( \base64_encode( \hash( $hashalg, $body, true ) ) !== $digest[1] ) { // phpcs:ignore - return new WP_Error( 'activitypub_signature', __( 'Invalid Digest header', 'activitypub' ), array( 'status' => 401 ) ); - } - } - - $public_key = self::get_remote_key( $signature_block['keyId'] ); - - if ( \is_wp_error( $public_key ) ) { - return $public_key; - } - - $verified = \openssl_verify( $signed_data, $signature_block['signature'], $public_key, $algorithm ) > 0; - if ( ! $verified ) { - return new WP_Error( 'activitypub_signature', __( 'Invalid signature', 'activitypub' ), array( 'status' => 401 ) ); - } - return $verified; - } - - /** - * Get public key from key_id. - * - * @param string $key_id The URL to the public key. - * - * @return resource|WP_Error The public key resource or WP_Error. - */ - public static function get_remote_key( $key_id ) { - $actor = get_remote_metadata_by_actor( strip_fragment_from_url( $key_id ) ); - if ( \is_wp_error( $actor ) ) { - return new WP_Error( - 'activitypub_no_remote_profile_found', - __( 'No Profile found or Profile not accessible', 'activitypub' ), - array( 'status' => 401 ) - ); - } - - if ( isset( $actor['publicKey']['publicKeyPem'] ) ) { - $key_resource = \openssl_pkey_get_public( \rtrim( $actor['publicKey']['publicKeyPem'] ) ); - if ( $key_resource ) { - return $key_resource; - } - } - - return new WP_Error( - 'activitypub_no_remote_key_found', - __( 'No Public-Key found', 'activitypub' ), - array( 'status' => 401 ) - ); - } - - /** - * Gets the signature algorithm from the signature header. - * - * @param array $signature_block The signature block. - * - * @return string The signature algorithm. - */ - public static function get_signature_algorithm( $signature_block ) { - if ( $signature_block['algorithm'] ) { - switch ( $signature_block['algorithm'] ) { - case 'rsa-sha-512': - return 'sha512'; // hs2019 https://datatracker.ietf.org/doc/html/draft-cavage-http-signatures-12. - default: - return 'sha256'; - } - } - return false; - } - - /** - * Parses the Signature header. - * - * @param string $signature The signature header. - * - * @return array Signature parts. - */ - public static function parse_signature_header( $signature ) { - $parsed_header = array(); - $matches = array(); - - if ( \preg_match( '/keyId="(.*?)"/ism', $signature, $matches ) ) { - $parsed_header['keyId'] = trim( $matches[1] ); - } - if ( \preg_match( '/created=["|\']*([0-9]*)["|\']*/ism', $signature, $matches ) ) { - $parsed_header['(created)'] = trim( $matches[1] ); - } - if ( \preg_match( '/expires=["|\']*([0-9]*)["|\']*/ism', $signature, $matches ) ) { - $parsed_header['(expires)'] = trim( $matches[1] ); - } - if ( \preg_match( '/algorithm="(.*?)"/ism', $signature, $matches ) ) { - $parsed_header['algorithm'] = trim( $matches[1] ); - } - if ( \preg_match( '/headers="(.*?)"/ism', $signature, $matches ) ) { - $parsed_header['headers'] = \explode( ' ', trim( $matches[1] ) ); - } - if ( \preg_match( '/signature="(.*?)"/ism', $signature, $matches ) ) { - $parsed_header['signature'] = \base64_decode( preg_replace( '/\s+/', '', trim( $matches[1] ) ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - } - - if ( empty( $parsed_header['headers'] ) ) { - $parsed_header['headers'] = array( 'date' ); - } - - return $parsed_header; - } - - /** - * Gets the header data from the included pseudo headers. - * - * @param array $signed_headers The signed headers. - * @param array $signature_block The signature block. - * @param array $headers The HTTP headers. - * - * @return string signed headers for comparison - */ - public static function get_signed_data( $signed_headers, $signature_block, $headers ) { - $signed_data = ''; - - // This also verifies time-based values by returning false if any of these are out of range. - foreach ( $signed_headers as $header ) { - if ( 'host' === $header ) { - if ( isset( $headers['x_original_host'] ) ) { - $signed_data .= $header . ': ' . $headers['x_original_host'][0] . "\n"; - continue; - } - } - if ( '(request-target)' === $header ) { - $signed_data .= $header . ': ' . $headers[ $header ][0] . "\n"; - continue; - } - if ( str_contains( $header, '-' ) ) { - $signed_data .= $header . ': ' . $headers[ str_replace( '-', '_', $header ) ][0] . "\n"; - continue; - } - if ( '(created)' === $header ) { - if ( ! empty( $signature_block['(created)'] ) && \intval( $signature_block['(created)'] ) > \time() ) { - // Created in the future. - return false; - } - - if ( ! array_key_exists( '(created)', $headers ) ) { - $signed_data .= $header . ': ' . $signature_block['(created)'] . "\n"; - continue; - } - } - if ( '(expires)' === $header ) { - if ( ! empty( $signature_block['(expires)'] ) && \intval( $signature_block['(expires)'] ) < \time() ) { - // Expired in the past. - return false; - } - - if ( ! array_key_exists( '(expires)', $headers ) ) { - $signed_data .= $header . ': ' . $signature_block['(expires)'] . "\n"; - continue; - } - } - if ( 'date' === $header ) { - if ( empty( $headers[ $header ][0] ) ) { - continue; - } - - // Allow a bit of leeway for misconfigured clocks. - $d = new DateTime( $headers[ $header ][0] ); - $d->setTimeZone( new DateTimeZone( 'UTC' ) ); - $c = $d->format( 'U' ); - - $dplus = time() + ( 3 * HOUR_IN_SECONDS ); - $dminus = time() - ( 3 * HOUR_IN_SECONDS ); - - if ( $c > $dplus || $c < $dminus ) { - // Time out of range. - return false; - } - } - - if ( ! empty( $headers[ $header ][0] ) ) { - $signed_data .= $header . ': ' . $headers[ $header ][0] . "\n"; - } - } - return \rtrim( $signed_data, "\n" ); - } - - /** - * Generates the digest for an HTTP Request. - * - * @param string $body The body of the request. - * - * @return string The digest. - */ - public static function generate_digest( $body ) { - $digest = \base64_encode( \hash( 'sha256', $body, true ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - return "SHA-256=$digest"; - } - - /** - * Formats the $_SERVER to resemble the WP_REST_REQUEST array, - * for use with verify_http_signature(). - * - * @param array $server The $_SERVER array. - * - * @return array $request The formatted request array. - */ - public static function format_server_request( $server ) { - $request = array(); - foreach ( $server as $param_key => $param_val ) { - $req_param = strtolower( $param_key ); - if ( 'REQUEST_URI' === $req_param ) { - $request['headers']['route'][] = $param_val; - } else { - $header_key = str_replace( - 'http_', - '', - $req_param - ); - $request['headers'][ $header_key ][] = \wp_unslash( $param_val ); - } - } - return $request; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-webfinger.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-webfinger.php deleted file mode 100644 index b53aa285..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/class-webfinger.php +++ /dev/null @@ -1,300 +0,0 @@ -get_webfinger(); - } - - /** - * Resolve a WebFinger resource. - * - * @param string $uri The WebFinger Resource. - * - * @return string|WP_Error The URL or WP_Error. - */ - public static function resolve( $uri ) { - $data = self::get_data( $uri ); - - if ( \is_wp_error( $data ) ) { - return $data; - } - - if ( ! is_array( $data ) || empty( $data['links'] ) ) { - return new WP_Error( - 'webfinger_missing_links', - __( 'No valid Link elements found.', 'activitypub' ), - array( - 'status' => 400, - 'data' => $data, - ) - ); - } - - foreach ( $data['links'] as $link ) { - if ( - 'self' === $link['rel'] && - isset( $link['type'] ) && - ( - 'application/activity+json' === $link['type'] || - 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"' === $link['type'] - ) - ) { - return $link['href']; - } - } - - return new WP_Error( - 'webfinger_url_no_activitypub', - __( 'The Site supports WebFinger but not ActivityPub', 'activitypub' ), - array( - 'status' => 400, - 'data' => $data, - ) - ); - } - - /** - * Transform a URI to an acct @. - * - * @see https://swicg.github.io/activitypub-webfinger/#reverse-discovery - * - * @param string $uri The URI (acct:, mailto:, http:, https:). - * - * @return string|WP_Error Error or acct URI. - */ - public static function uri_to_acct( $uri ) { - $data = self::get_data( $uri ); - - if ( is_wp_error( $data ) ) { - return $data; - } - - // Check if subject is an acct URI. - if ( - isset( $data['subject'] ) && - \str_starts_with( $data['subject'], 'acct:' ) - ) { - return $data['subject']; - } - - // Search for an acct URI in the aliases. - if ( isset( $data['aliases'] ) ) { - foreach ( $data['aliases'] as $alias ) { - if ( \str_starts_with( $alias, 'acct:' ) ) { - return $alias; - } - } - } - - return new WP_Error( - 'webfinger_url_no_acct', - __( 'No acct URI found.', 'activitypub' ), - array( - 'status' => 400, - 'data' => $data, - ) - ); - } - - /** - * Convert a URI string to an identifier and its host. - * Automatically adds acct: if it's missing. - * - * @param string $url The URI (acct:, mailto:, http:, https:). - * - * @return WP_Error|array Error reaction or array with identifier and host as values. - */ - public static function get_identifier_and_host( $url ) { - if ( ! $url ) { - return new WP_Error( - 'webfinger_invalid_identifier', - __( 'Invalid Identifier', 'activitypub' ), - array( - 'status' => 400, - 'data' => $url, - ) - ); - } - - // Remove leading @. - $url = ltrim( $url, '@' ); - - if ( ! preg_match( '/^([a-zA-Z+]+):/', $url, $match ) ) { - $identifier = 'acct:' . $url; - $scheme = 'acct'; - } else { - $identifier = $url; - $scheme = $match[1]; - } - - $host = null; - - switch ( $scheme ) { - case 'acct': - case 'mailto': - case 'xmpp': - if ( strpos( $identifier, '@' ) !== false ) { - $host = substr( $identifier, strpos( $identifier, '@' ) + 1 ); - } - break; - default: - $host = wp_parse_url( $identifier, PHP_URL_HOST ); - break; - } - - if ( empty( $host ) ) { - return new WP_Error( - 'webfinger_invalid_identifier', - __( 'Invalid Identifier', 'activitypub' ), - array( - 'status' => 400, - 'data' => $url, - ) - ); - } - - return array( $identifier, $host ); - } - - /** - * Get the WebFinger data for a given URI. - * - * @param string $uri The Identifier: @ or URI. - * - * @return WP_Error|array Error reaction or array with identifier and host as values. - */ - public static function get_data( $uri ) { - $identifier_and_host = self::get_identifier_and_host( $uri ); - - if ( is_wp_error( $identifier_and_host ) ) { - return $identifier_and_host; - } - - $transient_key = self::generate_cache_key( $uri ); - - list( $identifier, $host ) = $identifier_and_host; - - $data = \get_transient( $transient_key ); - if ( $data ) { - return $data; - } - - $webfinger_url = sprintf( - 'https://%s/.well-known/webfinger?resource=%s', - $host, - rawurlencode( $identifier ) - ); - - $response = wp_safe_remote_get( - $webfinger_url, - array( - 'headers' => array( 'Accept' => 'application/jrd+json' ), - ) - ); - - if ( is_wp_error( $response ) ) { - return new WP_Error( - 'webfinger_url_not_accessible', - __( 'The WebFinger Resource is not accessible.', 'activitypub' ), - array( - 'status' => 400, - 'data' => $webfinger_url, - ) - ); - } - - $body = wp_remote_retrieve_body( $response ); - $data = json_decode( $body, true ); - - \set_transient( $transient_key, $data, WEEK_IN_SECONDS ); - - return $data; - } - - /** - * Get the Remote-Follow endpoint for a given URI. - * - * @param string $uri The WebFinger Resource URI. - * - * @return string|WP_Error Error or the Remote-Follow endpoint URI. - */ - public static function get_remote_follow_endpoint( $uri ) { - $data = self::get_data( $uri ); - - if ( is_wp_error( $data ) ) { - return $data; - } - - if ( empty( $data['links'] ) ) { - return new WP_Error( - 'webfinger_missing_links', - __( 'No valid Link elements found.', 'activitypub' ), - array( - 'status' => 400, - 'data' => $data, - ) - ); - } - - foreach ( $data['links'] as $link ) { - if ( 'http://ostatus.org/schema/1.0/subscribe' === $link['rel'] ) { - return $link['template']; - } - } - - return new WP_Error( - 'webfinger_missing_remote_follow_endpoint', - __( 'No valid Remote-Follow endpoint found.', 'activitypub' ), - array( - 'status' => 400, - 'data' => $data, - ) - ); - } - - /** - * Generate a cache key for a given URI. - * - * @param string $uri A WebFinger Resource URI. - * - * @return string The cache key. - */ - public static function generate_cache_key( $uri ) { - $uri = ltrim( $uri, '@' ); - - if ( filter_var( $uri, FILTER_VALIDATE_EMAIL ) ) { - $uri = 'acct:' . $uri; - } - - return 'webfinger_' . md5( $uri ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-actors.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-actors.php deleted file mode 100644 index d4dbd6ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-actors.php +++ /dev/null @@ -1,378 +0,0 @@ - 404 ) - ); - } - - switch ( $user_id ) { - case self::BLOG_USER_ID: - return new Blog(); - case self::APPLICATION_USER_ID: - return new Application(); - default: - return User::from_wp_user( $user_id ); - } - } - - /** - * Get the Actor by username. - * - * @param string $username Name of the Actor. - * - * @return User|Blog|Application|WP_Error The Actor or WP_Error if user not found. - */ - public static function get_by_username( $username ) { - /** - * Filter the username before we do anything else. - * - * @param null $pre The pre-existing value. - * @param string $username The username. - */ - $pre = apply_filters( 'activitypub_pre_get_by_username', null, $username ); - if ( null !== $pre ) { - return $pre; - } - - // Check for blog user. - if ( Blog::get_default_username() === $username ) { - return new Blog(); - } - - if ( get_option( 'activitypub_blog_identifier' ) === $username ) { - return new Blog(); - } - - // Check for application user. - if ( 'application' === $username ) { - return new Application(); - } - - // Check for 'activitypub_username' meta. - $user = new WP_User_Query( - array( - 'count_total' => false, - 'number' => 1, - 'hide_empty' => true, - 'fields' => 'ID', - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'OR', - array( - 'key' => '_activitypub_user_identifier', - 'value' => $username, - 'compare' => 'LIKE', - ), - ), - ) - ); - - if ( $user->results ) { - $actor = self::get_by_id( $user->results[0] ); - if ( ! \is_wp_error( $actor ) ) { - return $actor; - } - } - - $username = str_replace( array( '*', '%' ), '', $username ); - - // Check for login or nicename. - $user = new WP_User_Query( - array( - 'count_total' => false, - 'search' => $username, - 'search_columns' => array( 'user_login', 'user_nicename' ), - 'number' => 1, - 'hide_empty' => true, - 'fields' => 'ID', - ) - ); - - if ( $user->results ) { - $actor = self::get_by_id( $user->results[0] ); - if ( ! \is_wp_error( $actor ) ) { - return $actor; - } - } - - return new WP_Error( - 'activitypub_user_not_found', - \__( 'Actor not found', 'activitypub' ), - array( 'status' => 404 ) - ); - } - - /** - * Get the Actor by resource. - * - * @param string $uri The Actor resource. - * - * @return User|Blog|Application|WP_Error The Actor or WP_Error if user not found. - */ - public static function get_by_resource( $uri ) { - $uri = object_to_uri( $uri ); - - if ( ! $uri ) { - return new WP_Error( - 'activitypub_no_uri', - \__( 'No URI provided', 'activitypub' ), - array( 'status' => 404 ) - ); - } - - $scheme = 'acct'; - $match = array(); - // Try to extract the scheme and the host. - if ( preg_match( '/^([a-zA-Z^:]+):(.*)$/i', $uri, $match ) ) { - // Extract the scheme. - $scheme = \esc_attr( $match[1] ); - } - - // @todo: handle old domain URIs here before we serve a new domain below when we shouldn't. - // Although maybe passing through to ::get_by_username() is enough? - - switch ( $scheme ) { - // Check for http(s) URIs. - case 'http': - case 'https': - $resource_path = \wp_parse_url( $uri, PHP_URL_PATH ); - - if ( $resource_path ) { - $blog_path = \wp_parse_url( \home_url(), PHP_URL_PATH ); - - if ( $blog_path ) { - $resource_path = \str_replace( $blog_path, '', $resource_path ); - } - - $resource_path = \trim( $resource_path, '/' ); - - // Check for http(s)://blog.example.com/@username. - if ( str_starts_with( $resource_path, '@' ) ) { - $identifier = \str_replace( '@', '', $resource_path ); - $identifier = \trim( $identifier, '/' ); - - return self::get_by_username( $identifier ); - } - } - - // Check for http(s)://blog.example.com/author/username. - $user_id = url_to_authorid( $uri ); - - if ( \is_int( $user_id ) ) { - return self::get_by_id( $user_id ); - } - - // Check for http(s)://blog.example.com/. - $normalized_uri = normalize_url( $uri ); - - if ( - normalize_url( site_url() ) === $normalized_uri || - normalize_url( home_url() ) === $normalized_uri - ) { - return self::get_by_id( self::BLOG_USER_ID ); - } - - return new WP_Error( - 'activitypub_no_user_found', - \__( 'Actor not found', 'activitypub' ), - array( 'status' => 404 ) - ); - // Check for acct URIs. - case 'acct': - $uri = \str_replace( 'acct:', '', $uri ); - $identifier = \substr( $uri, 0, \strrpos( $uri, '@' ) ); - $host = normalize_host( \substr( \strrchr( $uri, '@' ), 1 ) ); - $blog_host = normalize_host( \wp_parse_url( \home_url( '/' ), \PHP_URL_HOST ) ); - - if ( $blog_host !== $host && get_option( 'activitypub_old_host' ) !== $host ) { - return new WP_Error( - 'activitypub_wrong_host', - \__( 'Resource host does not match blog host', 'activitypub' ), - array( 'status' => 404 ) - ); - } - - // Prepare wildcards https://github.com/mastodon/mastodon/issues/22213. - if ( in_array( $identifier, array( '_', '*', '' ), true ) ) { - return self::get_by_id( self::BLOG_USER_ID ); - } - - return self::get_by_username( $identifier ); - default: - return new WP_Error( - 'activitypub_wrong_scheme', - \__( 'Wrong scheme', 'activitypub' ), - array( 'status' => 404 ) - ); - } - } - - /** - * Get the Actor by resource. - * - * @param string $id The Actor resource. - * - * @return User|Blog|Application|WP_Error The Actor or WP_Error if user not found. - */ - public static function get_by_various( $id ) { - $user = null; - - if ( is_numeric( $id ) ) { - $user = self::get_by_id( $id ); - } elseif ( - // Is URL. - filter_var( $id, FILTER_VALIDATE_URL ) || - // Is acct. - str_starts_with( $id, 'acct:' ) || - // Is email. - filter_var( $id, FILTER_VALIDATE_EMAIL ) - ) { - $user = self::get_by_resource( $id ); - } else { - $user = self::get_by_username( $id ); - } - - return $user; - } - - /** - * Get the Actor collection. - * - * @return array The Actor collection. - */ - public static function get_collection() { - if ( is_user_type_disabled( 'user' ) ) { - return array(); - } - - $users = \get_users( - array( - 'capability__in' => array( 'activitypub' ), - ) - ); - - $return = array(); - - foreach ( $users as $user ) { - $actor = User::from_wp_user( $user->ID ); - - if ( \is_wp_error( $actor ) ) { - continue; - } - - $return[] = $actor; - } - - return $return; - } - - /** - * Get all active Actors including the Blog Actor. - * - * @return array The actor collection. - */ - public static function get_all() { - $return = array(); - - if ( ! is_user_type_disabled( 'user' ) ) { - $users = \get_users( - array( - 'capability__in' => array( 'activitypub' ), - ) - ); - - foreach ( $users as $user ) { - $actor = User::from_wp_user( $user->ID ); - - if ( \is_wp_error( $actor ) ) { - continue; - } - - $return[] = $actor; - } - } - - // Also include the blog actor if active. - if ( ! is_user_type_disabled( 'blog' ) ) { - $blog_actor = self::get_by_id( self::BLOG_USER_ID ); - if ( ! \is_wp_error( $blog_actor ) ) { - $return[] = $blog_actor; - } - } - - return $return; - } - - /** - * Returns the actor type based on the user ID. - * - * @param int $user_id The user ID to check. - * @return string The user type. - */ - public static function get_type_by_id( $user_id ) { - $user_id = (int) $user_id; - - if ( self::APPLICATION_USER_ID === $user_id ) { - return 'application'; - } - - if ( self::BLOG_USER_ID === $user_id ) { - return 'blog'; - } - - return 'user'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-extra-fields.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-extra-fields.php deleted file mode 100644 index 417f24ea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-extra-fields.php +++ /dev/null @@ -1,300 +0,0 @@ - $post_type, - 'nopaging' => true, - 'orderby' => 'menu_order', - 'order' => 'ASC', - ); - if ( ! $is_blog ) { - $args['author'] = $user_id; - } - - $query = new \WP_Query( $args ); - $fields = $query->posts ?? array(); - - /** - * Filters the extra fields for an ActivityPub actor. - * - * This filter allows developers to modify or add custom fields to an actor's - * profile. - * - * @param \WP_Post[] $fields Array of WP_Post objects representing the extra fields. - * @param int $user_id The ID of the user whose fields are being retrieved. - */ - return apply_filters( 'activitypub_get_actor_extra_fields', $fields, $user_id ); - } - - /** - * Get formatted content for an extra field. - * - * @param \WP_Post $post The post. - * - * @return string The formatted content. - */ - public static function get_formatted_content( $post ) { - $content = \get_the_content( null, false, $post ); - $content = Link::the_content( $content ); - if ( site_supports_blocks() ) { - $content = \do_blocks( $content ); - } - $content = \wptexturize( $content ); - $content = \wp_filter_content_tags( $content ); - - // Replace script and style elements. - $content = \preg_replace( '@<(script|style)[^>]*?>.*?@si', '', $content ); - $content = \strip_shortcodes( $content ); - $content = \trim( \preg_replace( '/[\n\r\t]/', '', $content ) ); - - /** - * Filters the content of an extra field. - * - * @param string $content The content. - * @param \WP_Post $post The post. - */ - return \apply_filters( 'activitypub_extra_field_content', $content, $post ); - } - - /** - * Transforms the Extra Fields (Custom Post Types) to ActivityPub Actor-Attachments. - * - * @param \WP_Post[] $fields The extra fields. - * - * @return array ActivityPub attachments. - */ - public static function fields_to_attachments( $fields ) { - $attachments = array(); - \add_filter( 'activitypub_link_rel', array( self::class, 'add_rel_me' ) ); - - foreach ( $fields as $post ) { - $content = self::get_formatted_content( $post ); - $attachments[] = array( - 'type' => 'PropertyValue', - 'name' => \get_the_title( $post ), - 'value' => \html_entity_decode( - $content, - \ENT_QUOTES, - 'UTF-8' - ), - ); - - $attachment = false; - - // Add support for FEP-fb2a, for more information see FEDERATION.md. - $link_content = \trim( \strip_tags( $content, '' ) ); - if ( - \stripos( $link_content, '', \strlen( $link_content ) - 4 ) !== false && - \class_exists( '\WP_HTML_Tag_Processor' ) - ) { - $tags = new \WP_HTML_Tag_Processor( $link_content ); - $tags->next_tag( 'A' ); - - if ( 'A' === $tags->get_tag() ) { - $attachment = array( - 'type' => 'Link', - 'name' => \get_the_title( $post ), - 'href' => \esc_url( $tags->get_attribute( 'href' ) ), - ); - - $rel = $tags->get_attribute( 'rel' ); - - if ( $rel && \is_string( $rel ) ) { - $attachment['rel'] = \explode( ' ', $rel ); - } - } - } - - if ( ! $attachment ) { - $attachment = array( - 'type' => 'Note', - 'name' => \get_the_title( $post ), - 'content' => \html_entity_decode( - $content, - \ENT_QUOTES, - 'UTF-8' - ), - ); - } - - $attachments[] = $attachment; - } - - \remove_filter( 'activitypub_link_rel', array( self::class, 'add_rel_me' ) ); - - return $attachments; - } - - /** - * Check if a post type is an extra fields post type. - * - * @param string $post_type The post type. - * - * @return bool True if the post type is an extra fields post type, otherwise false. - */ - public static function is_extra_fields_post_type( $post_type ) { - return \in_array( $post_type, array( self::USER_POST_TYPE, self::BLOG_POST_TYPE ), true ); - } - - /** - * Check if a post type is the `ap_extrafield` post type. - * - * @param string $post_type The post type. - * - * @return bool True if the post type is `ap_extrafield`, otherwise false. - */ - public static function is_extra_field_post_type( $post_type ) { - return self::USER_POST_TYPE === $post_type; - } - - /** - * Check if a post type is the `ap_extrafield_blog` post type. - * - * @param string $post_type The post type. - * - * @return bool True if the post type is `ap_extrafield_blog`, otherwise false. - */ - public static function is_extra_field_blog_post_type( $post_type ) { - return self::BLOG_POST_TYPE === $post_type; - } - - /** - * Add default extra fields to an actor. - * - * @param array $extra_fields The extra fields. - * @param int $user_id The User-ID. - * - * @return array The extra fields. - */ - public static function default_actor_extra_fields( $extra_fields, $user_id ) { - // We'll only take action when there are none yet. - if ( ! empty( $extra_fields ) ) { - return $extra_fields; - } - - $is_blog = self::is_blog( $user_id ); - $already_migrated = $is_blog - ? \get_option( 'activitypub_default_extra_fields' ) - : \get_user_meta( $user_id, 'activitypub_default_extra_fields', true ); - - if ( $already_migrated ) { - return $extra_fields; - } - - \add_filter( - 'activitypub_link_rel', - function ( $rel ) { - $rel .= ' me'; - - return $rel; - } - ); - - $defaults = array( - \__( 'Blog', 'activitypub' ) => \home_url( '/' ), - ); - - if ( ! $is_blog ) { - $author_url = \get_the_author_meta( 'user_url', $user_id ); - $author_posts_url = \get_author_posts_url( $user_id ); - - $defaults[ \__( 'Profile', 'activitypub' ) ] = $author_posts_url; - if ( $author_url !== $author_posts_url ) { - $defaults[ \__( 'Homepage', 'activitypub' ) ] = $author_url; - } - } - - $post_type = $is_blog ? self::BLOG_POST_TYPE : self::USER_POST_TYPE; - $menu_order = 10; - - foreach ( $defaults as $title => $url ) { - if ( ! $url ) { - continue; - } - - $extra_field = array( - 'post_type' => $post_type, - 'post_title' => $title, - 'post_status' => 'publish', - 'post_author' => $user_id, - 'post_content' => self::make_paragraph_block( Link::the_content( $url ) ), - 'comment_status' => 'closed', - 'menu_order' => $menu_order, - ); - - $menu_order += 10; - $extra_field_id = wp_insert_post( $extra_field ); - $extra_fields[] = get_post( $extra_field_id ); - } - - $is_blog - ? \update_option( 'activitypub_default_extra_fields', true ) - : \update_user_meta( $user_id, 'activitypub_default_extra_fields', true ); - - return $extra_fields; - } - - /** - * Create a paragraph block. - * - * @param string $content The content. - * - * @return string The paragraph block. - */ - public static function make_paragraph_block( $content ) { - if ( ! site_supports_blocks() ) { - return $content; - } - return '

' . $content . '

'; - } - - /** - * Add the 'me' rel to the link. - * - * @param string $rel The rel attribute. - * @return string The modified rel attribute. - */ - public static function add_rel_me( $rel ) { - return $rel . ' me'; - } - - /** - * Checks if the user is the blog user. - * - * @param int $user_id The user ID. - * @return bool True if the user is the blog user, otherwise false. - */ - private static function is_blog( $user_id ) { - return Actors::BLOG_USER_ID === $user_id; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-followers.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-followers.php deleted file mode 100644 index 24be3507..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-followers.php +++ /dev/null @@ -1,482 +0,0 @@ - 400 ) ); - } - - $follower = new Follower(); - $follower->from_array( $meta ); - - $id = $follower->upsert(); - - if ( is_wp_error( $id ) ) { - return $id; - } - - $post_meta = get_post_meta( $id, '_activitypub_user_id', false ); - - // phpcs:ignore WordPress.PHP.StrictInArray.MissingTrueStrict - if ( is_array( $post_meta ) && ! in_array( $user_id, $post_meta ) ) { - add_post_meta( $id, '_activitypub_user_id', $user_id ); - wp_cache_delete( sprintf( self::CACHE_KEY_INBOXES, $user_id ), 'activitypub' ); - } - - return $follower; - } - - /** - * Remove a Follower. - * - * @param int $user_id The ID of the WordPress User. - * @param string $actor The Actor URL. - * - * @return bool True on success, false on failure. - */ - public static function remove_follower( $user_id, $actor ) { - wp_cache_delete( sprintf( self::CACHE_KEY_INBOXES, $user_id ), 'activitypub' ); - - $follower = self::get_follower( $user_id, $actor ); - - if ( ! $follower ) { - return false; - } - - /** - * Fires before a Follower is removed. - * - * @param Follower $follower The Follower object. - * @param int $user_id The ID of the WordPress User. - * @param string $actor The Actor URL. - */ - do_action( 'activitypub_followers_pre_remove_follower', $follower, $user_id, $actor ); - - return delete_post_meta( $follower->get__id(), '_activitypub_user_id', $user_id ); - } - - /** - * Get a Follower. - * - * @param int $user_id The ID of the WordPress User. - * @param string $actor The Actor URL. - * - * @return Follower|false|null The Follower object or null - */ - public static function get_follower( $user_id, $actor ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $post_id = $wpdb->get_var( - $wpdb->prepare( - "SELECT DISTINCT p.ID FROM $wpdb->posts p INNER JOIN $wpdb->postmeta pm ON p.ID = pm.post_id WHERE p.post_type = %s AND pm.meta_key = '_activitypub_user_id' AND pm.meta_value = %d AND p.guid = %s", - array( - esc_sql( self::POST_TYPE ), - esc_sql( $user_id ), - esc_sql( $actor ), - ) - ) - ); - - if ( $post_id ) { - $post = get_post( $post_id ); - return Follower::init_from_cpt( $post ); - } - - return null; - } - - /** - * Get a Follower by Actor independent of the User. - * - * @param string $actor The Actor URL. - * - * @return Follower|false|null The Follower object or false on failure. - */ - public static function get_follower_by_actor( $actor ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $post_id = $wpdb->get_var( - $wpdb->prepare( - "SELECT ID FROM $wpdb->posts WHERE guid=%s", - esc_sql( $actor ) - ) - ); - - if ( $post_id ) { - $post = get_post( $post_id ); - return Follower::init_from_cpt( $post ); - } - - return null; - } - - /** - * Get the Followers of a given user. - * - * @param int $user_id The ID of the WordPress User. - * @param int $number Maximum number of results to return. - * @param int $page Page number. - * @param array $args The WP_Query arguments. - * @return Follower[] List of `Follower` objects. - */ - public static function get_followers( $user_id, $number = -1, $page = null, $args = array() ) { - $data = self::get_followers_with_count( $user_id, $number, $page, $args ); - return $data['followers']; - } - - /** - * Get the Followers of a given user, along with a total count for pagination purposes. - * - * @param int $user_id The ID of the WordPress User. - * @param int $number Maximum number of results to return. - * @param int $page Page number. - * @param array $args The WP_Query arguments. - * - * @return array { - * Data about the followers. - * - * @type Follower[] $followers List of `Follower` objects. - * @type int $total Total number of followers. - * } - */ - public static function get_followers_with_count( $user_id, $number = -1, $page = null, $args = array() ) { - $defaults = array( - 'post_type' => self::POST_TYPE, - 'posts_per_page' => $number, - 'paged' => $page, - 'orderby' => 'ID', - 'order' => 'DESC', - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => '_activitypub_user_id', - 'value' => $user_id, - ), - ), - ); - - $args = wp_parse_args( $args, $defaults ); - $query = new WP_Query( $args ); - $total = $query->found_posts; - $followers = array_map( array( Follower::class, 'init_from_cpt' ), $query->get_posts() ); - $followers = array_filter( $followers ); - - return compact( 'followers', 'total' ); - } - - /** - * Get all Followers. - * - * @return Follower[] The Term list of Followers. - */ - public static function get_all_followers() { - $args = array( - 'nopaging' => true, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'AND', - array( - 'key' => '_activitypub_inbox', - 'compare' => 'EXISTS', - ), - array( - 'key' => '_activitypub_actor_json', - 'compare' => 'EXISTS', - ), - ), - ); - return self::get_followers( null, null, null, $args ); - } - - /** - * Count the total number of followers - * - * @param int $user_id The ID of the WordPress User. - * - * @return int The number of Followers - */ - public static function count_followers( $user_id ) { - $query = new WP_Query( - array( - 'post_type' => self::POST_TYPE, - 'fields' => 'ids', - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'AND', - array( - 'key' => '_activitypub_user_id', - 'value' => $user_id, - ), - array( - 'key' => '_activitypub_inbox', - 'compare' => 'EXISTS', - ), - array( - 'key' => '_activitypub_actor_json', - 'compare' => 'EXISTS', - ), - ), - ) - ); - - return $query->found_posts; - } - - /** - * Returns all Inboxes for an Actor's Followers. - * - * @param int $user_id The ID of the WordPress User. - * - * @return array The list of Inboxes. - */ - public static function get_inboxes( $user_id ) { - $cache_key = sprintf( self::CACHE_KEY_INBOXES, $user_id ); - $inboxes = wp_cache_get( $cache_key, 'activitypub' ); - - if ( $inboxes ) { - return $inboxes; - } - - // Get all Followers of an ID of the WordPress User. - $posts = new WP_Query( - array( - 'nopaging' => true, - 'post_type' => self::POST_TYPE, - 'fields' => 'ids', - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'AND', - array( - 'key' => '_activitypub_inbox', - 'compare' => 'EXISTS', - ), - array( - 'key' => '_activitypub_user_id', - 'value' => $user_id, - ), - array( - 'key' => '_activitypub_inbox', - 'value' => '', - 'compare' => '!=', - ), - ), - ) - ); - - $posts = $posts->get_posts(); - - if ( ! $posts ) { - return array(); - } - - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery - $results = $wpdb->get_col( - $wpdb->prepare( - "SELECT DISTINCT meta_value FROM {$wpdb->postmeta} - WHERE post_id IN (" . implode( ', ', array_fill( 0, count( $posts ), '%d' ) ) . ") - AND meta_key = '_activitypub_inbox' - AND meta_value IS NOT NULL", - $posts - ) - ); - - $inboxes = array_filter( $results ); - wp_cache_set( $cache_key, $inboxes, 'activitypub' ); - - return $inboxes; - } - - /** - * Get all Inboxes for a given Activity. - * - * @param string $json The ActivityPub Activity JSON. - * @param int $actor_id The WordPress Actor ID. - * @param int $batch_size Optional. The batch size. Default 50. - * @param int $offset Optional. The offset. Default 0. - * - * @return array The list of Inboxes. - */ - public static function get_inboxes_for_activity( $json, $actor_id, $batch_size = 50, $offset = 0 ) { - $inboxes = self::get_inboxes( $actor_id ); - - if ( self::maybe_add_inboxes_of_blog_user( $json, $actor_id ) ) { - $inboxes = array_fill_keys( $inboxes, 1 ); - foreach ( self::get_inboxes( Actors::BLOG_USER_ID ) as $inbox ) { - $inboxes[ $inbox ] = 1; - } - $inboxes = array_keys( $inboxes ); - } - - return array_slice( $inboxes, $offset, $batch_size ); - } - - /** - * Maybe add Inboxes of the Blog User. - * - * @param string $json The ActivityPub Activity JSON. - * @param int $actor_id The WordPress Actor ID. - * @return bool True if the Inboxes of the Blog User should be added, false otherwise. - */ - public static function maybe_add_inboxes_of_blog_user( $json, $actor_id ) { - // Only if we're in both Blog and User modes. - if ( ACTIVITYPUB_ACTOR_AND_BLOG_MODE !== \get_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_MODE ) ) { - return false; - } - // Only if this isn't the Blog Actor. - if ( Actors::BLOG_USER_ID === $actor_id ) { - return false; - } - - $activity = json_decode( $json, true ); - // Only if this is an Update or Delete. Create handles its own "Announce" in dual user mode. - if ( ! in_array( $activity['type'] ?? null, array( 'Update', 'Delete' ), true ) ) { - return false; - } - - return true; - } - - /** - * Get all Followers that have not been updated for a given time. - * - * @param int $number Optional. Limits the result. Default 50. - * @param int $older_than Optional. The time in seconds. Default 86400 (1 day). - * - * @return Follower[] The Term list of Followers. - */ - public static function get_outdated_followers( $number = 50, $older_than = 86400 ) { - $args = array( - 'post_type' => self::POST_TYPE, - 'posts_per_page' => $number, - 'orderby' => 'modified', - 'order' => 'ASC', - 'post_status' => 'any', // 'any' includes 'trash'. - 'date_query' => array( - array( - 'column' => 'post_modified_gmt', - 'before' => gmdate( 'Y-m-d', \time() - $older_than ), - ), - ), - ); - - $posts = new WP_Query( $args ); - $items = array_map( array( Follower::class, 'init_from_cpt' ), $posts->get_posts() ); - - return array_filter( $items ); - } - - /** - * Get all Followers that had errors. - * - * @param int $number Optional. The number of Followers to return. Default 20. - * - * @return Follower[] The Term list of Followers. - */ - public static function get_faulty_followers( $number = 20 ) { - $args = array( - 'post_type' => self::POST_TYPE, - 'posts_per_page' => $number, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'OR', - array( - 'key' => '_activitypub_errors', - 'compare' => 'EXISTS', - ), - array( - 'key' => '_activitypub_inbox', - 'compare' => 'NOT EXISTS', - ), - array( - 'key' => '_activitypub_actor_json', - 'compare' => 'NOT EXISTS', - ), - array( - 'key' => '_activitypub_inbox', - 'value' => '', - 'compare' => '=', - ), - array( - 'key' => '_activitypub_actor_json', - 'value' => '', - 'compare' => '=', - ), - ), - ); - - $posts = new WP_Query( $args ); - $items = array_map( array( Follower::class, 'init_from_cpt' ), $posts->get_posts() ); - - return array_filter( $items ); - } - - /** - * This function is used to store errors that occur when - * sending an ActivityPub message to a Follower. - * - * The error will be stored in post meta. - * - * @param int $post_id The ID of the WordPress Custom-Post-Type. - * @param mixed $error The error message. Can be a string or a WP_Error. - * - * @return int|false The meta ID on success, false on failure. - */ - public static function add_error( $post_id, $error ) { - if ( is_string( $error ) ) { - $error_message = $error; - } elseif ( is_wp_error( $error ) ) { - $error_message = $error->get_error_message(); - } else { - $error_message = __( - 'Unknown Error or misconfigured Error-Message', - 'activitypub' - ); - } - - return add_post_meta( - $post_id, - '_activitypub_errors', - $error_message - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-interactions.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-interactions.php deleted file mode 100644 index dc1f9417..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-interactions.php +++ /dev/null @@ -1,349 +0,0 @@ -comment_post_ID; - } - - if ( is_post_disabled( $comment_post_id ) ) { - return false; - } - - $commentdata['comment_post_ID'] = $comment_post_id; - $commentdata['comment_parent'] = $parent_comment_id ? $parent_comment_id : 0; - - return self::persist( $commentdata, self::INSERT ); - } - - /** - * Update a comment. - * - * @param array $activity The activity object. - * - * @return array|string|int|\WP_Error|false The comment data or false on failure. - */ - public static function update_comment( $activity ) { - $meta = get_remote_metadata_by_actor( $activity['actor'] ); - - // Determine comment_ID. - $comment = object_id_to_comment( \esc_url_raw( $activity['object']['id'] ) ); - $commentdata = \get_comment( $comment, ARRAY_A ); - - if ( ! $commentdata ) { - return false; - } - - // Found a local comment id. - $commentdata['comment_author'] = \esc_attr( $meta['name'] ? $meta['name'] : $meta['preferredUsername'] ); - $commentdata['comment_content'] = \addslashes( $activity['object']['content'] ); - - return self::persist( $commentdata, self::UPDATE ); - } - - /** - * Adds an incoming Like, Announce, ... as a comment to a post. - * - * @param array $activity Activity array. - * - * @return array|false Comment data or `false` on failure. - */ - public static function add_reaction( $activity ) { - $commentdata = self::activity_to_comment( $activity ); - - if ( ! $commentdata ) { - return false; - } - - $url = object_to_uri( $activity['object'] ); - $comment_post_id = \url_to_postid( $url ); - $parent_comment_id = url_to_commentid( $url ); - - if ( ! $comment_post_id && $parent_comment_id ) { - $parent_comment = \get_comment( $parent_comment_id ); - $comment_post_id = $parent_comment->comment_post_ID; - } - - if ( ! $comment_post_id || is_post_disabled( $comment_post_id ) ) { - // Not a reply to a post or comment. - return false; - } - - $comment_type = Comment::get_comment_type_by_activity_type( $activity['type'] ); - - if ( ! $comment_type ) { - // Not a valid comment type. - return false; - } - - $comment_content = $comment_type['excerpt']; - - $commentdata['comment_post_ID'] = $comment_post_id; - $commentdata['comment_content'] = \esc_html( $comment_content ); - $commentdata['comment_type'] = \esc_attr( $comment_type['type'] ); - $commentdata['comment_meta']['source_id'] = \esc_url_raw( $activity['id'] ); - - return self::persist( $commentdata, self::INSERT ); - } - - /** - * Get interaction(s) for a given URL/ID. - * - * @param string $url The URL/ID to get interactions for. - * - * @return array The interactions as WP_Comment objects. - */ - public static function get_interaction_by_id( $url ) { - $args = array( - 'nopaging' => true, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - 'relation' => 'AND', - array( - 'key' => 'protocol', - 'value' => 'activitypub', - ), - array( - 'relation' => 'OR', - array( - 'key' => 'source_url', - 'value' => $url, - ), - array( - 'key' => 'source_id', - 'value' => $url, - ), - ), - ), - ); - - $query = new WP_Comment_Query( $args ); - return $query->comments; - } - - /** - * Get interaction(s) for a given actor. - * - * @param string $actor The Actor-URL. - * - * @return array The interactions as WP_Comment objects. - */ - public static function get_interactions_by_actor( $actor ) { - $meta = get_remote_metadata_by_actor( $actor ); - - // Get URL, because $actor seems to be the ID. - if ( $meta && ! is_wp_error( $meta ) && isset( $meta['url'] ) ) { - $actor = object_to_uri( $meta['url'] ); - } - - $args = array( - 'nopaging' => true, - 'author_url' => $actor, - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => 'protocol', - 'value' => 'activitypub', - ), - ), - ); - - return get_comments( $args ); - } - - /** - * Adds line breaks to the list of allowed comment tags. - * - * @param array $allowed_tags Allowed HTML tags. - * @param string $context Optional. Context. Default empty. - * - * @return array Filtered tag list. - */ - public static function allowed_comment_html( $allowed_tags, $context = '' ) { - if ( 'pre_comment_content' !== $context ) { - // Do nothing. - return $allowed_tags; - } - - // Add `p` and `br` to the list of allowed tags. - if ( ! array_key_exists( 'br', $allowed_tags ) ) { - $allowed_tags['br'] = array(); - } - - if ( ! array_key_exists( 'p', $allowed_tags ) ) { - $allowed_tags['p'] = array(); - } - - return $allowed_tags; - } - - /** - * Convert an Activity to a WP_Comment - * - * @param array $activity The Activity array. - * - * @return array|false The comment data or false on failure. - */ - public static function activity_to_comment( $activity ) { - $comment_content = null; - $actor = object_to_uri( $activity['actor'] ?? null ); - $actor = get_remote_metadata_by_actor( $actor ); - - // Check Actor-Meta. - if ( ! $actor || is_wp_error( $actor ) ) { - return false; - } - - // Check Actor-Name. - if ( isset( $actor['name'] ) ) { - $comment_author = $actor['name']; - } elseif ( isset( $actor['preferredUsername'] ) ) { - $comment_author = $actor['preferredUsername']; - } else { - return false; - } - - $url = object_to_uri( $actor['url'] ?? $actor['id'] ); - - if ( ! $url ) { - $url = object_to_uri( $actor['id'] ); - } - - if ( isset( $activity['object']['content'] ) ) { - $comment_content = \addslashes( $activity['object']['content'] ); - } - - $webfinger = Webfinger::uri_to_acct( $url ); - if ( is_wp_error( $webfinger ) ) { - $webfinger = ''; - } else { - $webfinger = str_replace( 'acct:', '', $webfinger ); - } - - $commentdata = array( - 'comment_author' => \esc_attr( $comment_author ), - 'comment_author_url' => \esc_url_raw( $url ), - 'comment_content' => $comment_content, - 'comment_type' => 'comment', - 'comment_author_email' => $webfinger, - 'comment_meta' => array( - 'source_id' => \esc_url_raw( object_to_uri( $activity['object'] ) ), - 'protocol' => 'activitypub', - ), - ); - - if ( isset( $actor['icon']['url'] ) ) { - $commentdata['comment_meta']['avatar_url'] = \esc_url_raw( $actor['icon']['url'] ); - } - - if ( isset( $activity['object']['url'] ) ) { - $commentdata['comment_meta']['source_url'] = \esc_url_raw( object_to_uri( $activity['object']['url'] ) ); - } - - return $commentdata; - } - - /** - * Persist a comment. - * - * @param array $commentdata The commentdata array. - * @param string $action Optional. Either 'insert' or 'update'. Default 'insert'. - * - * @return array|string|int|\WP_Error|false The comment data or false on failure - */ - public static function persist( $commentdata, $action = self::INSERT ) { - // Disable flood control. - \remove_action( 'check_comment_flood', 'check_comment_flood_db' ); - // Do not require email for AP entries. - \add_filter( 'pre_option_require_name_email', '__return_false' ); - // No nonce possible for this submission route. - \add_filter( - 'akismet_comment_nonce', - function () { - return 'inactive'; - } - ); - \add_filter( 'wp_kses_allowed_html', array( self::class, 'allowed_comment_html' ), 10, 2 ); - - if ( self::INSERT === $action ) { - $state = \wp_new_comment( $commentdata, true ); - } else { - $state = \wp_update_comment( $commentdata, true ); - } - - \remove_filter( 'wp_kses_allowed_html', array( self::class, 'allowed_comment_html' ) ); - \remove_filter( 'pre_option_require_name_email', '__return_false' ); - // Restore flood control. - \add_action( 'check_comment_flood', 'check_comment_flood_db', 10, 4 ); - - if ( 1 === $state ) { - return $commentdata; - } else { - return $state; // Either WP_Comment, false, a WP_Error, 0, or 1! - } - } - - /** - * Get the total number of interactions by type for a given ID. - * - * @param int $post_id The post ID. - * @param string $type The type of interaction to count. - * - * @return int The total number of interactions. - */ - public static function count_by_type( $post_id, $type ) { - return \get_comments( - array( - 'post_id' => $post_id, - 'status' => 'approve', - 'type' => $type, - 'count' => true, - 'paging' => false, - 'fields' => 'ids', - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-outbox.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-outbox.php deleted file mode 100644 index cf1dff89..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-outbox.php +++ /dev/null @@ -1,351 +0,0 @@ -get_object() ); - - if ( ! $activity->get_actor() ) { - $activity->set_actor( Actors::get_by_id( $user_id )->get_id() ); - } - - $outbox_item = array( - 'post_type' => self::POST_TYPE, - 'post_title' => sprintf( - /* translators: 1. Activity type, 2. Object Title or Excerpt */ - __( '[%1$s] %2$s', 'activitypub' ), - $activity->get_type(), - \wp_trim_words( $title, 5 ) - ), - 'post_content' => wp_slash( $activity->to_json() ), - // ensure that user ID is not below 0. - 'post_author' => \max( $user_id, 0 ), - 'post_status' => 'pending', - 'meta_input' => array( - '_activitypub_object_id' => $object_id, - '_activitypub_activity_type' => $activity->get_type(), - '_activitypub_activity_actor' => $actor_type, - 'activitypub_content_visibility' => $visibility, - ), - ); - - $has_kses = false !== \has_filter( 'content_save_pre', 'wp_filter_post_kses' ); - if ( $has_kses ) { - // Prevent KSES from corrupting JSON in post_content. - \kses_remove_filters(); - } - - $id = \wp_insert_post( $outbox_item, true ); - - // Update the activity ID if the post was inserted successfully. - if ( $id && ! \is_wp_error( $id ) ) { - $activity->set_id( \get_the_guid( $id ) ); - - \wp_update_post( - array( - 'ID' => $id, - 'post_content' => \wp_slash( $activity->to_json() ), - ) - ); - } - - if ( $has_kses ) { - \kses_init_filters(); - } - - if ( \is_wp_error( $id ) ) { - return $id; - } - - if ( ! $id ) { - return false; - } - - self::invalidate_existing_items( $object_id, $activity->get_type(), $id ); - - return $id; - } - - /** - * Invalidate existing outbox items with the same activity type and object ID - * by setting their status to 'publish'. - * - * @param string $object_id The ID of the activity object. - * @param string $activity_type The type of the activity. - * @param int $current_id The ID of the current outbox item to exclude. - * - * @return void - */ - private static function invalidate_existing_items( $object_id, $activity_type, $current_id ) { - // Do not invalidate items for Announce activities. - if ( 'Announce' === $activity_type ) { - return; - } - - $meta_query = array( - array( - 'key' => '_activitypub_object_id', - 'value' => $object_id, - ), - ); - - // For non-Delete activities, only invalidate items of the same type. - if ( 'Delete' !== $activity_type ) { - $meta_query[] = array( - 'key' => '_activitypub_activity_type', - 'value' => $activity_type, - ); - } - - $existing_items = get_posts( - array( - 'post_type' => self::POST_TYPE, - 'post_status' => 'pending', - 'exclude' => array( $current_id ), - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => $meta_query, - 'fields' => 'ids', - ) - ); - - foreach ( $existing_items as $existing_item_id ) { - $event_args = array( - Dispatcher::$callback, - $existing_item_id, - Dispatcher::$batch_size, - \get_post_meta( $existing_item_id, '_activitypub_outbox_offset', true ) ?: 0, // phpcs:ignore - ); - - $timestamp = \wp_next_scheduled( 'activitypub_async_batch', $event_args ); - \wp_unschedule_event( $timestamp, 'activitypub_async_batch', $event_args ); - - $timestamp = \wp_next_scheduled( 'activitypub_process_outbox', array( $existing_item_id ) ); - \wp_unschedule_event( $timestamp, 'activitypub_process_outbox', array( $existing_item_id ) ); - - \wp_publish_post( $existing_item_id ); - \delete_post_meta( $existing_item_id, '_activitypub_outbox_offset' ); - } - } - - /** - * Creates an Undo activity. - * - * @param int|\WP_Post $outbox_item The Outbox post or post ID. - * - * @return int|bool The ID of the outbox item or false on failure. - */ - public static function undo( $outbox_item ) { - $outbox_item = get_post( $outbox_item ); - $activity = self::get_activity( $outbox_item ); - - $type = 'Undo'; - if ( 'Create' === $activity->get_type() ) { - $type = 'Delete'; - } elseif ( 'Add' === $activity->get_type() ) { - $type = 'Remove'; - } - - return add_to_outbox( $activity, $type, $outbox_item->post_author ); - } - - /** - * Reschedule an activity. - * - * @param int|\WP_Post $outbox_item The Outbox post or post ID. - * - * @return bool True if the activity was rescheduled, false otherwise. - */ - public static function reschedule( $outbox_item ) { - $outbox_item = get_post( $outbox_item ); - - $outbox_item->post_status = 'pending'; - $outbox_item->post_date = current_time( 'mysql' ); - - wp_update_post( $outbox_item ); - - Scheduler::schedule_outbox_activity_for_federation( $outbox_item->ID ); - - return true; - } - - /** - * Get the Activity object from the Outbox item. - * - * @param int|\WP_Post $outbox_item The Outbox post or post ID. - * @return Activity|\WP_Error The Activity object or WP_Error. - */ - public static function get_activity( $outbox_item ) { - $outbox_item = get_post( $outbox_item ); - $actor = self::get_actor( $outbox_item ); - if ( is_wp_error( $actor ) ) { - return $actor; - } - - $activity_object = \json_decode( $outbox_item->post_content, true ); - $type = \get_post_meta( $outbox_item->ID, '_activitypub_activity_type', true ); - - if ( $activity_object['type'] === $type ) { - $activity = Activity::init_from_array( $activity_object ); - if ( ! $activity->get_actor() ) { - $activity->set_actor( $actor->get_id() ); - } - } else { - $activity = new Activity(); - $activity->set_type( $type ); - $activity->set_id( $outbox_item->guid ); - $activity->set_actor( $actor->get_id() ); - // Pre-fill the Activity with data (for example cc and to). - $activity->set_object( $activity_object ); - } - - if ( 'Update' === $type ) { - $activity->set_updated( gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, strtotime( $outbox_item->post_modified ) ) ); - } - - /** - * Filters the Activity object before it is returned. - * - * @param Activity $activity The Activity object. - * @param \WP_Post $outbox_item The outbox item post object. - */ - return apply_filters( 'activitypub_get_outbox_activity', $activity, $outbox_item ); - } - - /** - * Get the Actor object from the Outbox item. - * - * @param \WP_Post $outbox_item The Outbox post. - * - * @return \Activitypub\Model\User|\Activitypub\Model\Blog|\WP_Error The Actor object or WP_Error. - */ - public static function get_actor( $outbox_item ) { - $actor_type = \get_post_meta( $outbox_item->ID, '_activitypub_activity_actor', true ); - - switch ( $actor_type ) { - case 'blog': - $actor_id = Actors::BLOG_USER_ID; - break; - case 'application': - $actor_id = Actors::APPLICATION_USER_ID; - break; - case 'user': - default: - $actor_id = $outbox_item->post_author; - break; - } - - return Actors::get_by_id( $actor_id ); - } - - /** - * Get the Activity object from the Outbox item. - * - * @param \WP_Post $outbox_item The Outbox post. - * - * @return Activity|\WP_Error The Activity object or WP_Error. - */ - public static function maybe_get_activity( $outbox_item ) { - if ( ! $outbox_item instanceof \WP_Post ) { - return new \WP_Error( 'invalid_outbox_item', 'Invalid Outbox item.' ); - } - - if ( 'ap_outbox' !== $outbox_item->post_type ) { - return new \WP_Error( 'invalid_outbox_item', 'Invalid Outbox item.' ); - } - - // Check if Outbox Activity is public. - $visibility = \get_post_meta( $outbox_item->ID, 'activitypub_content_visibility', true ); - - if ( ! in_array( $visibility, array( ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC, ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC ), true ) ) { - return new \WP_Error( 'private_outbox_item', 'Not a public Outbox item.' ); - } - - $activity_types = \apply_filters( 'rest_activitypub_outbox_activity_types', array( 'Announce', 'Create', 'Like', 'Update' ) ); - $activity_type = \get_post_meta( $outbox_item->ID, '_activitypub_activity_type', true ); - - if ( ! in_array( $activity_type, $activity_types, true ) ) { - return new \WP_Error( 'private_outbox_item', 'Not public Outbox item type.' ); - } - - return self::get_activity( $outbox_item ); - } - - /** - * Get the object ID of an activity. - * - * @param Activity|Base_Object|string $data The activity object. - * - * @return string The object ID. - */ - private static function get_object_id( $data ) { - $object = $data->get_object(); - - if ( is_object( $object ) ) { - return self::get_object_id( $object ); - } - - if ( is_string( $object ) ) { - return $object; - } - - return $data->get_id() ?? $data->get_actor(); - } - - /** - * Get the title of an activity recursively. - * - * @param Base_Object $activity_object The activity object. - * - * @return string The title. - */ - private static function get_object_title( $activity_object ) { - if ( ! $activity_object ) { - return ''; - } - - if ( is_string( $activity_object ) ) { - $post_id = url_to_postid( $activity_object ); - - return $post_id ? get_the_title( $post_id ) : ''; - } - - $title = $activity_object->get_name() ?? $activity_object->get_content(); - - if ( ! $title && $activity_object->get_object() instanceof Base_Object ) { - $title = $activity_object->get_object()->get_name() ?? $activity_object->get_object()->get_content(); - } - - return $title; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-replies.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-replies.php deleted file mode 100644 index 25b47d21..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-replies.php +++ /dev/null @@ -1,226 +0,0 @@ - 'approve', - 'orderby' => 'comment_date_gmt', - 'order' => 'ASC', - 'type' => 'comment', - ); - - if ( $wp_object instanceof WP_Post ) { - $args['parent'] = 0; // TODO: maybe this is unnecessary. - $args['post_id'] = $wp_object->ID; - } elseif ( $wp_object instanceof WP_Comment ) { - $args['parent'] = $wp_object->comment_ID; - } else { - return new WP_Error(); - } - - return $args; - } - - /** - * Get the replies collections ID. - * - * @param WP_Post|WP_Comment $wp_object The post or comment to fetch replies for. - * - * @return string|WP_Error The rest URL of the replies collection or WP_Error if the object is not a post or comment. - */ - private static function get_id( $wp_object ) { - if ( $wp_object instanceof WP_Post ) { - return get_rest_url_by_path( sprintf( 'posts/%d/replies', $wp_object->ID ) ); - } elseif ( $wp_object instanceof WP_Comment ) { - return get_rest_url_by_path( sprintf( 'comments/%d/replies', $wp_object->comment_ID ) ); - } else { - return new WP_Error( 'unsupported_object', 'The object is not a post or comment.' ); - } - } - - /** - * Get the Replies collection. - * - * @param WP_Post|WP_Comment $wp_object The post or comment to fetch replies for. - * - * @return array|\WP_Error|null An associative array containing the replies collection without JSON-LD context on success. - */ - public static function get_collection( $wp_object ) { - $id = self::get_id( $wp_object ); - - if ( is_wp_error( $id ) ) { - return \wp_is_serving_rest_request() ? $id : null; - } - - $replies = array( - 'id' => $id, - 'type' => 'Collection', - ); - - $replies['first'] = self::get_collection_page( $wp_object, 1, $replies['id'] ); - - return $replies; - } - - /** - * Returns a replies collection page as an associative array. - * - * @link https://www.w3.org/TR/activitystreams-vocabulary/#dfn-collectionpage - * - * @param WP_Post|WP_Comment $wp_object The post of comment the replies are for. - * @param int $page The current pagination page. - * @param string $part_of Optional. The collection id/url the returned CollectionPage belongs to. Default null. - * - * @return array|WP_Error|null A CollectionPage as an associative array on success, WP_Error or null on failure. - */ - public static function get_collection_page( $wp_object, $page, $part_of = null ) { - // Build initial arguments for fetching approved comments. - $args = self::build_args( $wp_object ); - if ( is_wp_error( $args ) ) { - return \wp_is_serving_rest_request() ? $args : null; - } - - // Retrieve the partOf if not already given. - $part_of = $part_of ?? self::get_id( $wp_object ); - - // If the collection page does not exist. - if ( is_wp_error( $part_of ) ) { - return \wp_is_serving_rest_request() ? $part_of : null; - } - - // Get to total replies count. - $total_replies = \get_comments( array_merge( $args, array( 'count' => true ) ) ); - - // If set to zero, we get errors below. You need at least one comment per page, here. - $args['number'] = max( (int) \get_option( 'comments_per_page' ), 1 ); - $args['offset'] = intval( $page - 1 ) * $args['number']; - - // Get the ActivityPub ID's of the comments, without local-only comments. - $comment_ids = self::get_reply_ids( \get_comments( $args ) ); - - // Build the associative CollectionPage array. - $collection_page = array( - 'id' => \add_query_arg( 'page', $page, $part_of ), - 'type' => 'CollectionPage', - 'partOf' => $part_of, - 'items' => $comment_ids, - ); - - if ( ( $total_replies / $args['number'] ) > $page ) { - $collection_page['next'] = \add_query_arg( 'page', $page + 1, $part_of ); - } - - if ( $page > 1 ) { - $collection_page['prev'] = \add_query_arg( 'page', $page - 1, $part_of ); - } - - return $collection_page; - } - - /** - * Get the context collection for a post. - * - * @param int $post_id The post ID. - * - * @return array|false The context for the post or false if the post is not found or disabled. - */ - public static function get_context_collection( $post_id ) { - $post = \get_post( $post_id ); - - if ( ! $post || is_post_disabled( $post_id ) ) { - return false; - } - - $comments = \get_comments( - array( - 'post_id' => $post_id, - 'type' => 'comment', - 'status' => 'approve', - 'orderby' => 'comment_date_gmt', - 'order' => 'ASC', - ) - ); - $ids = self::get_reply_ids( $comments, true ); - $post_uri = ( new PostTransformer( $post ) )->to_id(); - \array_unshift( $ids, $post_uri ); - - $author = Actors::get_by_id( $post->post_author ); - if ( is_wp_error( $author ) ) { - if ( is_user_type_disabled( 'blog' ) ) { - return false; - } - - $author = new Blog(); - } - - return array( - 'type' => 'OrderedCollection', - 'url' => \get_permalink( $post_id ), - 'attributedTo' => $author->get_id(), - 'totalItems' => count( $ids ), - 'items' => $ids, - ); - } - - /** - * Get the ActivityPub ID's from a list of comments. - * - * It takes only federated/non-local comments into account, others also do not have an - * ActivityPub ID available. - * - * @param WP_Comment[] $comments The comments to retrieve the ActivityPub ids from. - * @param boolean $include_blog_comments Optional. Include blog comments in the returned array. Default false. - * - * @return string[] A list of the ActivityPub ID's. - */ - private static function get_reply_ids( $comments, $include_blog_comments = false ) { - $comment_ids = array(); - - foreach ( $comments as $comment ) { - if ( is_local_comment( $comment ) ) { - continue; - } - - $public_comment_id = Comment::get_source_id( $comment->comment_ID ); - if ( $public_comment_id ) { - $comment_ids[] = $public_comment_id; - continue; - } - - if ( $include_blog_comments ) { - $comment_ids[] = ( new CommentTransformer( $comment ) )->to_id(); - } - } - - return \array_unique( $comment_ids ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-users.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-users.php deleted file mode 100644 index 12194903..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/collection/class-users.php +++ /dev/null @@ -1,78 +0,0 @@ - $v ) { - if ( ++$next_key !== $k ) { - return false; - } - } - - return true; - } -} - -if ( ! function_exists( 'str_contains' ) ) { - /** - * Polyfill for `str_contains()` function added in PHP 8.0. - * - * Performs a case-sensitive check indicating if needle is - * contained in haystack. - * - * @param string $haystack The string to search in. - * @param string $needle The substring to search for in the `$haystack`. - * - * @return bool True if `$needle` is in `$haystack`, otherwise false. - */ - function str_contains( $haystack, $needle ) { - if ( '' === $needle ) { - return true; - } - - return false !== strpos( $haystack, $needle ); - } -} - -if ( ! function_exists( 'wp_is_serving_rest_request' ) ) { - /** - * Polyfill for `wp_is_serving_rest_request()` function added in WordPress 6.5. - * - * @see https://developer.wordpress.org/reference/functions/wp_is_serving_rest_request/ - * - * @return bool True if it's a WordPress REST API request, false otherwise. - */ - function wp_is_serving_rest_request() { - return defined( 'REST_REQUEST' ) && REST_REQUEST; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/constants.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/constants.php deleted file mode 100644 index 8b6c92d0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/constants.php +++ /dev/null @@ -1,76 +0,0 @@ -)|(?<=
)|^)#([A-Za-z0-9_]+)(?:(?=\s|[[:punct:]]|$))' ); -\defined( 'ACTIVITYPUB_USERNAME_REGEXP' ) || \define( 'ACTIVITYPUB_USERNAME_REGEXP', '(?:([A-Za-z0-9\._-]+)@((?:[A-Za-z0-9_-]+\.)+[A-Za-z]+))' ); -\defined( 'ACTIVITYPUB_URL_REGEXP' ) || \define( 'ACTIVITYPUB_URL_REGEXP', '(https?:|www\.)\S+[\w\/]' ); -\defined( 'ACTIVITYPUB_CUSTOM_POST_CONTENT' ) || \define( 'ACTIVITYPUB_CUSTOM_POST_CONTENT', "[ap_title type=\"html\"]\n\n[ap_content]\n\n[ap_hashtags]" ); -\defined( 'ACTIVITYPUB_DISABLE_REWRITES' ) || \define( 'ACTIVITYPUB_DISABLE_REWRITES', false ); -\defined( 'ACTIVITYPUB_DISABLE_INCOMING_INTERACTIONS' ) || \define( 'ACTIVITYPUB_DISABLE_INCOMING_INTERACTIONS', false ); -\defined( 'ACTIVITYPUB_DISABLE_OUTGOING_INTERACTIONS' ) || \define( 'ACTIVITYPUB_DISABLE_OUTGOING_INTERACTIONS', false ); -\defined( 'ACTIVITYPUB_DEFAULT_OBJECT_TYPE' ) || \define( 'ACTIVITYPUB_DEFAULT_OBJECT_TYPE', 'wordpress-post-format' ); -\defined( 'ACTIVITYPUB_OUTBOX_PROCESSING_BATCH_SIZE' ) || \define( 'ACTIVITYPUB_OUTBOX_PROCESSING_BATCH_SIZE', 100 ); - -// The following constants are invariable and define values used throughout the plugin. - -/* - * Mastodon HTML sanitizer. - * - * @see https://docs.joinmastodon.org/spec/activitypub/#sanitization - */ -\define( - 'ACTIVITYPUB_MASTODON_HTML_SANITIZER', - array( - 'p' => array(), - 'span' => array( 'class' => true ), - 'br' => array(), - 'a' => array( - 'href' => true, - 'rel' => true, - 'class' => true, - ), - 'del' => array(), - 'pre' => array(), - 'code' => array(), - 'em' => array(), - 'strong' => array(), - 'b' => array(), - 'i' => array(), - 'u' => array(), - 'ul' => array(), - 'ol' => array( - 'start' => true, - 'reversed' => true, - ), - 'li' => array( 'value' => true ), - 'blockquote' => array(), - 'h1' => array(), - 'h2' => array(), - 'h3' => array(), - 'h4' => array(), - ) -); - -\define( 'ACTIVITYPUB_DATE_TIME_RFC3339', 'Y-m-d\TH:i:s\Z' ); - -// Define Actor-Modes for the plugin. -\define( 'ACTIVITYPUB_ACTOR_MODE', 'actor' ); -\define( 'ACTIVITYPUB_BLOG_MODE', 'blog' ); -\define( 'ACTIVITYPUB_ACTOR_AND_BLOG_MODE', 'actor_blog' ); - -// Post visibility constants. -\define( 'ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC', '' ); -\define( 'ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC', 'quiet_public' ); -\define( 'ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE', 'private' ); -\define( 'ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL', 'local' ); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/debug.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/debug.php deleted file mode 100644 index bc96e969..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/debug.php +++ /dev/null @@ -1,79 +0,0 @@ - $value ) { - echo \esc_attr( $key ) . ': ' . \esc_html( $value[0] ) . '
'; - } - } -} -\add_action( 'manage_posts_custom_column', '\Activitypub\manage_posts_custom_column', 10, 2 ); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/functions.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/functions.php deleted file mode 100644 index 084ea546..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/functions.php +++ /dev/null @@ -1,1606 +0,0 @@ -wp_rewrite_rules(); - - // Not using rewrite rules, and 'author=N' method failed, so we're out of options. - if ( empty( $rewrite ) ) { - return null; - } - - // Generate rewrite rule for the author url. - $author_rewrite = $wp_rewrite->get_author_permastruct(); - $author_regexp = \str_replace( '%author%', '', $author_rewrite ); - - // Match the rewrite rule with the passed url. - if ( \preg_match( '/https?:\/\/(.+)' . \preg_quote( $author_regexp, '/' ) . '([^\/]+)/i', $url, $match ) ) { - $user = \get_user_by( 'slug', $match[2] ); - if ( $user ) { - return $user->ID; - } - } - - return null; -} - -/** - * Verify that url is a wp_ap_comment or a previously received remote comment. - * - * @return int|bool Comment ID or false if not found. - */ -function is_comment() { - $comment_id = get_query_var( 'c', null ); - - if ( ! is_null( $comment_id ) ) { - $comment = \get_comment( $comment_id ); - - if ( $comment ) { - return $comment_id; - } - } - - return false; -} - -/** - * Check for Tombstone Objects. - * - * @see https://www.w3.org/TR/activitypub/#delete-activity-outbox - * - * @param WP_Error $wp_error A WP_Error-Response of an HTTP-Request. - * - * @return boolean True if HTTP-Code is 410 or 404. - */ -function is_tombstone( $wp_error ) { - if ( ! is_wp_error( $wp_error ) ) { - return false; - } - - if ( in_array( (int) $wp_error->get_error_code(), array( 404, 410 ), true ) ) { - return true; - } - - return false; -} - -/** - * Get the REST URL relative to this plugin's namespace. - * - * @param string $path Optional. REST route path. Default ''. - * - * @return string REST URL relative to this plugin's namespace. - */ -function get_rest_url_by_path( $path = '' ) { - // We'll handle the leading slash. - $path = ltrim( $path, '/' ); - $namespaced_path = sprintf( '/%s/%s', ACTIVITYPUB_REST_NAMESPACE, $path ); - return \get_rest_url( null, $namespaced_path ); -} - -/** - * Convert a string from camelCase to snake_case. - * - * @param string $input The string to convert. - * - * @return string The converted string. - */ -function camel_to_snake_case( $input ) { - return strtolower( preg_replace( '/(?is_activitypub_request(); -} - -/** - * Check if a post is disabled for ActivityPub. - * - * This function checks if the post type supports ActivityPub and if the post is set to be local. - * - * @param mixed $post The post object or ID. - * - * @return boolean True if the post is disabled, false otherwise. - */ -function is_post_disabled( $post ) { - $post = \get_post( $post ); - $disabled = false; - - if ( ! $post ) { - return true; - } - - $visibility = \get_post_meta( $post->ID, 'activitypub_content_visibility', true ); - - if ( - ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL === $visibility || - ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE === $visibility || - ! \post_type_supports( $post->post_type, 'activitypub' ) || - 'private' === $post->post_status || - ! empty( $post->post_password ) - ) { - $disabled = true; - } - - /** - * Allow plugins to disable posts for ActivityPub. - * - * @param boolean $disabled True if the post is disabled, false otherwise. - * @param \WP_Post $post The post object. - */ - return \apply_filters( 'activitypub_is_post_disabled', $disabled, $post ); -} - -/** - * This function checks if a user is enabled for ActivityPub. - * - * @param int|string $user_id The user ID. - * @return boolean True if the user is enabled, false otherwise. - */ -function user_can_activitypub( $user_id ) { - if ( ! is_numeric( $user_id ) ) { - return false; - } - - switch ( $user_id ) { - case Actors::APPLICATION_USER_ID: - $enabled = true; // Application user is always enabled. - break; - - case Actors::BLOG_USER_ID: - $enabled = ! is_user_type_disabled( 'blog' ); - break; - - default: - if ( ! \get_user_by( 'id', $user_id ) ) { - $enabled = false; - break; - } - - if ( is_user_type_disabled( 'user' ) ) { - $enabled = false; - break; - } - - $enabled = \user_can( $user_id, 'activitypub' ); - } - - /** - * Allow plugins to disable users for ActivityPub. - * - * @deprecated 5.7.0 Use the `activitypub_user_can_activitypub` filter instead. - * - * @param boolean $disabled True if the user is disabled, false otherwise. - * @param int $user_id The user ID. - */ - $enabled = ! \apply_filters_deprecated( 'activitypub_is_user_disabled', array( ! $enabled, $user_id ), '5.7.0', 'activitypub_user_can_activitypub' ); - - /** - * Allow plugins to enable/disable users for ActivityPub. - * - * @param boolean $enabled True if the user is enabled, false otherwise. - * @param int $user_id The user ID. - */ - return apply_filters( 'activitypub_user_can_activitypub', $enabled, $user_id ); -} - -/** - * This function checks if a user is disabled for ActivityPub. - * - * @deprecated 5.7.0 Use the `user_can_activitypub` function instead. - * - * @param int $user_id The user ID. - * - * @return boolean True if the user is disabled, false otherwise. - */ -function is_user_disabled( $user_id ) { - _deprecated_function( __FUNCTION__, 'unreleased', 'user_can_activitypub' ); - - return ! user_can_activitypub( $user_id ); -} - -/** - * Checks if a User-Type is disabled for ActivityPub. - * - * This function is used to check if the 'blog' or 'user' - * type is disabled for ActivityPub. - * - * @param string $type User type. 'blog' or 'user'. - * - * @return boolean True if the user type is disabled, false otherwise. - */ -function is_user_type_disabled( $type ) { - switch ( $type ) { - case 'blog': - if ( \defined( 'ACTIVITYPUB_SINGLE_USER_MODE' ) ) { - if ( ACTIVITYPUB_SINGLE_USER_MODE ) { - $disabled = false; - break; - } - } - - if ( \defined( 'ACTIVITYPUB_DISABLE_BLOG_USER' ) ) { - $disabled = ACTIVITYPUB_DISABLE_BLOG_USER; - break; - } - - if ( ACTIVITYPUB_ACTOR_MODE === \get_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_MODE ) ) { - $disabled = true; - break; - } - - $disabled = false; - break; - case 'user': - if ( \defined( 'ACTIVITYPUB_SINGLE_USER_MODE' ) ) { - if ( ACTIVITYPUB_SINGLE_USER_MODE ) { - $disabled = true; - break; - } - } - - if ( \defined( 'ACTIVITYPUB_DISABLE_USER' ) ) { - $disabled = ACTIVITYPUB_DISABLE_USER; - break; - } - - if ( ACTIVITYPUB_BLOG_MODE === \get_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_MODE ) ) { - $disabled = true; - break; - } - - $disabled = false; - break; - default: - $disabled = new WP_Error( - 'activitypub_wrong_user_type', - __( 'Wrong user type', 'activitypub' ), - array( 'status' => 400 ) - ); - break; - } - - /** - * Allow plugins to disable user types for ActivityPub. - * - * @param boolean $disabled True if the user type is disabled, false otherwise. - * @param string $type The User-Type. - */ - return apply_filters( 'activitypub_is_user_type_disabled', $disabled, $type ); -} - -/** - * Check if the blog is in single-user mode. - * - * @return boolean True if the blog is in single-user mode, false otherwise. - */ -function is_single_user() { - if ( - false === is_user_type_disabled( 'blog' ) && - true === is_user_type_disabled( 'user' ) - ) { - return true; - } - - return false; -} - -/** - * Check if a site supports the block editor. - * - * @return boolean True if the site supports the block editor, false otherwise. - */ -function site_supports_blocks() { - /** - * Allow plugins to disable block editor support, - * thus disabling blocks registered by the ActivityPub plugin. - * - * @param boolean $supports_blocks True if the site supports the block editor, false otherwise. - */ - return apply_filters( 'activitypub_site_supports_blocks', true ); -} - -/** - * Check if data is valid JSON. - * - * @param string $data The data to check. - * - * @return boolean True if the data is JSON, false otherwise. - */ -function is_json( $data ) { - return \is_array( \json_decode( $data, true ) ) ? true : false; -} - -/** - * Check whether a blog is public based on the `blog_public` option. - * - * @return bool True if public, false if not - */ -function is_blog_public() { - /** - * Filter whether the blog is public. - * - * @param bool $public Whether the blog is public. - */ - return (bool) apply_filters( 'activitypub_is_blog_public', \get_option( 'blog_public', 1 ) ); -} - -/** - * Extract recipient URLs from Activity object. - * - * @param array $data The Activity object as array. - * - * @return array The list of user URLs. - */ -function extract_recipients_from_activity( $data ) { - $recipient_items = array(); - - foreach ( array( 'to', 'bto', 'cc', 'bcc', 'audience' ) as $i ) { - if ( array_key_exists( $i, $data ) ) { - if ( is_array( $data[ $i ] ) ) { - $recipient = $data[ $i ]; - } else { - $recipient = array( $data[ $i ] ); - } - $recipient_items = array_merge( $recipient_items, $recipient ); - } - - if ( is_array( $data['object'] ) && array_key_exists( $i, $data['object'] ) ) { - if ( is_array( $data['object'][ $i ] ) ) { - $recipient = $data['object'][ $i ]; - } else { - $recipient = array( $data['object'][ $i ] ); - } - $recipient_items = array_merge( $recipient_items, $recipient ); - } - } - - $recipients = array(); - - // Flatten array. - foreach ( $recipient_items as $recipient ) { - if ( is_array( $recipient ) ) { - // Check if recipient is an object. - if ( array_key_exists( 'id', $recipient ) ) { - $recipients[] = $recipient['id']; - } - } else { - $recipients[] = $recipient; - } - } - - return array_unique( $recipients ); -} - -/** - * Check if passed Activity is Public. - * - * @param array $data The Activity object as array. - * - * @return boolean True if public, false if not. - */ -function is_activity_public( $data ) { - $recipients = extract_recipients_from_activity( $data ); - - return in_array( 'https://www.w3.org/ns/activitystreams#Public', $recipients, true ); -} - -/** - * Check if passed Activity is a reply. - * - * @param array $data The Activity object as array. - * - * @return boolean True if a reply, false if not. - */ -function is_activity_reply( $data ) { - return ! empty( $data['object']['inReplyTo'] ); -} - -/** - * Get active users based on a given duration. - * - * @param int $duration Optional. The duration to check in month(s). Default 1. - * - * @return int The number of active users. - */ -function get_active_users( $duration = 1 ) { - - $duration = intval( $duration ); - $transient_key = sprintf( 'monthly_active_users_%d', $duration ); - $count = get_transient( $transient_key ); - - if ( false === $count ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $count = $wpdb->get_var( - $wpdb->prepare( - "SELECT COUNT( DISTINCT post_author ) FROM {$wpdb->posts} WHERE post_type = 'post' AND post_status = 'publish' AND post_date <= DATE_SUB( NOW(), INTERVAL %d MONTH )", - $duration - ) - ); - - set_transient( $transient_key, $count, DAY_IN_SECONDS ); - } - - // If 0 authors where active. - if ( 0 === $count ) { - return 0; - } - - // If single user mode. - if ( is_single_user() ) { - return 1; - } - - // If blog user is disabled. - if ( ! user_can_activitypub( Actors::BLOG_USER_ID ) ) { - return (int) $count; - } - - // Also count blog user. - return (int) $count + 1; -} - -/** - * Get the total number of users. - * - * @return int The total number of users. - */ -function get_total_users() { - // If single user mode. - if ( is_single_user() ) { - return 1; - } - - $users = \get_users( - array( - 'capability__in' => array( 'activitypub' ), - ) - ); - - if ( is_array( $users ) ) { - $users = count( $users ); - } else { - $users = 1; - } - - // If blog user is disabled. - if ( ! user_can_activitypub( Actors::BLOG_USER_ID ) ) { - return (int) $users; - } - - return (int) $users + 1; -} - -/** - * Examine a comment ID and look up an existing comment it represents. - * - * @param string $id ActivityPub object ID (usually a URL) to check. - * - * @return \WP_Comment|boolean Comment, or false on failure. - */ -function object_id_to_comment( $id ) { - return Comment::object_id_to_comment( $id ); -} - -/** - * Verify that URL is a local comment or a previously received remote comment. - * (For threading comments locally) - * - * @param string $url The URL to check. - * - * @return string|null Comment ID or null if not found - */ -function url_to_commentid( $url ) { - return Comment::url_to_commentid( $url ); -} - -/** - * Get the URI of an ActivityPub object. - * - * @param array|string $data The ActivityPub object. - * - * @return string The URI of the ActivityPub object - */ -function object_to_uri( $data ) { - // Check whether it is already simple. - if ( ! $data || is_string( $data ) ) { - return $data; - } - - if ( is_object( $data ) ) { - $data = $data->to_array(); - } - - /* - * Check if it is a list, then take first item. - * This plugin does not support collections. - */ - if ( array_is_list( $data ) ) { - $data = $data[0]; - } - - // Check if it is simplified now. - if ( is_string( $data ) ) { - return $data; - } - - $type = 'Object'; - if ( isset( $data['type'] ) ) { - $type = $data['type']; - } - - // Return part of Object that makes most sense. - switch ( $type ) { - case 'Image': - $data = $data['url']; - break; - case 'Link': - $data = $data['href']; - break; - default: - $data = $data['id']; - break; - } - - return $data; -} - -/** - * Check if a comment should be federated. - * - * We consider a comment should be federated if it is authored by a user that is - * not disabled for federation and if it is a reply directly to the post or to a - * federated comment. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment should be federated, false otherwise. - */ -function should_comment_be_federated( $comment ) { - return Comment::should_be_federated( $comment ); -} - -/** - * Check if a comment was federated. - * - * This function checks if a comment was federated via ActivityPub. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment was federated, false otherwise. - */ -function was_comment_sent( $comment ) { - return Comment::was_sent( $comment ); -} - -/** - * Check if a comment is federated. - * - * We consider a comment federated if comment was received via ActivityPub. - * - * Use this function to check if it is comment that was received via ActivityPub. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment is federated, false otherwise. - */ -function was_comment_received( $comment ) { - return Comment::was_received( $comment ); -} - -/** - * Check if a comment is local only. - * - * This function checks if a comment is local only and was not sent or received via ActivityPub. - * - * @param mixed $comment Comment object or ID. - * - * @return boolean True if the comment is local only, false otherwise. - */ -function is_local_comment( $comment ) { - return Comment::is_local( $comment ); -} - -/** - * Mark a WordPress object as federated. - * - * @param \WP_Comment|\WP_Post $wp_object The WordPress object. - * @param string $state The state of the object. - */ -function set_wp_object_state( $wp_object, $state ) { - $meta_key = 'activitypub_status'; - - if ( $wp_object instanceof \WP_Post ) { - \update_post_meta( $wp_object->ID, $meta_key, $state ); - } elseif ( $wp_object instanceof \WP_Comment ) { - \update_comment_meta( $wp_object->comment_ID, $meta_key, $state ); - } else { - /** - * Allow plugins to mark WordPress objects as federated. - * - * @param \WP_Comment|\WP_Post $wp_object The WordPress object. - */ - \apply_filters( 'activitypub_mark_wp_object_as_federated', $wp_object ); - } -} - -/** - * Get the federation state of a WordPress object. - * - * @param \WP_Comment|\WP_Post $wp_object The WordPress object. - * - * @return string|false The state of the object or false if not found. - */ -function get_wp_object_state( $wp_object ) { - $meta_key = 'activitypub_status'; - - if ( $wp_object instanceof \WP_Post ) { - return \get_post_meta( $wp_object->ID, $meta_key, true ); - } elseif ( $wp_object instanceof \WP_Comment ) { - return \get_comment_meta( $wp_object->comment_ID, $meta_key, true ); - } else { - /** - * Allow plugins to get the federation state of a WordPress object. - * - * @param false $state The state of the object. - * @param \WP_Comment|\WP_Post $wp_object The WordPress object. - */ - return \apply_filters( 'activitypub_get_wp_object_state', false, $wp_object ); - } -} - -/** - * Get the description of a post type. - * - * Set some default descriptions for the default post types. - * - * @param \WP_Post_Type $post_type The post type object. - * - * @return string The description of the post type. - */ -function get_post_type_description( $post_type ) { - $description = ''; - - switch ( $post_type->name ) { - case 'post': - $description = ''; - break; - case 'page': - $description = ''; - break; - case 'attachment': - $description = ' - ' . __( 'The attachments that you have uploaded to a post (images, videos, documents or other files).', 'activitypub' ); - break; - default: - if ( ! empty( $post_type->description ) ) { - $description = ' - ' . $post_type->description; - } - } - - /** - * Allow plugins to get the description of a post type. - * - * @param string $description The description of the post type. - * @param string $post_type_name The post type name. - * @param \WP_Post_Type $post_type The post type object. - */ - return apply_filters( 'activitypub_post_type_description', $description, $post_type->name, $post_type ); -} - -/** - * Get the masked WordPress version to only show the major and minor version. - * - * @return string The masked version. - */ -function get_masked_wp_version() { - // Only show the major and minor version. - $version = get_bloginfo( 'version' ); - // Strip the RC or beta part. - $version = preg_replace( '/-.*$/', '', $version ); - $version = explode( '.', $version ); - $version = array_slice( $version, 0, 2 ); - - return implode( '.', $version ); -} - -/** - * Get the enclosures of a post. - * - * @param int $post_id The post ID. - * - * @return array The enclosures. - */ -function get_enclosures( $post_id ) { - $enclosures = get_post_meta( $post_id, 'enclosure', false ); - - if ( ! $enclosures ) { - return array(); - } - - $enclosures = array_map( - function ( $enclosure ) { - // Check if the enclosure is a string. - if ( ! $enclosure || ! is_string( $enclosure ) ) { - return false; - } - - $attributes = explode( "\n", $enclosure ); - - if ( ! isset( $attributes[0] ) || ! \wp_http_validate_url( $attributes[0] ) ) { - return false; - } - - return array( - 'url' => $attributes[0], - 'length' => $attributes[1] ?? null, - 'mediaType' => $attributes[2] ?? 'application/octet-stream', - ); - }, - $enclosures - ); - - return array_filter( $enclosures ); -} - -/** - * Retrieves the IDs of the ancestors of a comment. - * - * Adaption of `get_post_ancestors` from WordPress core. - * - * @see https://developer.wordpress.org/reference/functions/get_post_ancestors/ - * - * @param int|\WP_Comment $comment Comment ID or comment object. - * - * @return int[] Array of ancestor IDs. - */ -function get_comment_ancestors( $comment ) { - $comment = \get_comment( $comment ); - - if ( ! $comment || empty( $comment->comment_parent ) || (int) $comment->comment_parent === (int) $comment->comment_ID ) { - return array(); - } - - $ancestors = array(); - - $id = (int) $comment->comment_parent; - $ancestors[] = $id; - - while ( $id > 0 ) { - $ancestor = \get_comment( $id ); - $parent_id = (int) $ancestor->comment_parent; - - // Loop detection: If the ancestor has been seen before, break. - if ( empty( $parent_id ) || ( $parent_id === (int) $comment->comment_ID ) || in_array( $parent_id, $ancestors, true ) ) { - break; - } - - $id = $parent_id; - $ancestors[] = $id; - } - - return $ancestors; -} - -/** - * Change the display of large numbers on the site. - * - * @author Jeremy Herve - * - * @see https://wordpress.org/support/topic/abbreviate-numbers-with-k/ - * - * @param string $formatted Converted number in string format. - * @param float $number The number to convert based on locale. - * @param int $decimals Precision of the number of decimal places. - * - * @return string Converted number in string format. - */ -function custom_large_numbers( $formatted, $number, $decimals ) { - global $wp_locale; - - $decimals = 0; - $decimal_point = '.'; - $thousands_sep = ','; - - if ( isset( $wp_locale ) ) { - $decimals = (int) $wp_locale->number_format['decimal_point']; - $decimal_point = $wp_locale->number_format['decimal_point']; - $thousands_sep = $wp_locale->number_format['thousands_sep']; - } - - if ( $number < 1000 ) { // Any number less than a Thousand. - return \number_format( $number, $decimals, $decimal_point, $thousands_sep ); - } elseif ( $number < 1000000 ) { // Any number less than a million. - return \number_format( $number / 1000, $decimals, $decimal_point, $thousands_sep ) . 'K'; - } elseif ( $number < 1000000000 ) { // Any number less than a billion. - return \number_format( $number / 1000000, $decimals, $decimal_point, $thousands_sep ) . 'M'; - } else { // At least a billion. - return \number_format( $number / 1000000000, $decimals, $decimal_point, $thousands_sep ) . 'B'; - } - - // Default fallback. We should not get here. - return $formatted; -} - -/** - * Registers a ActivityPub comment type. - * - * @param string $comment_type Key for comment type. - * @param array $args Optional. Array of arguments for registering a comment type. Default empty array. - * - * @return array The registered Activitypub comment type. - */ -function register_comment_type( $comment_type, $args = array() ) { - global $activitypub_comment_types; - - if ( ! is_array( $activitypub_comment_types ) ) { - $activitypub_comment_types = array(); - } - - // Sanitize comment type name. - $comment_type = sanitize_key( $comment_type ); - - $activitypub_comment_types[ $comment_type ] = $args; - - /** - * Fires after a ActivityPub comment type is registered. - * - * @param string $comment_type Comment type. - * @param array $args Arguments used to register the comment type. - */ - do_action( 'activitypub_registered_comment_type', $comment_type, $args ); - - return $args; -} - -/** - * Normalize a URL. - * - * @param string $url The URL. - * - * @return string The normalized URL. - */ -function normalize_url( $url ) { - $url = \untrailingslashit( $url ); - $url = \str_replace( 'https://', '', $url ); - $url = \str_replace( 'http://', '', $url ); - $url = \str_replace( 'www.', '', $url ); - - return $url; -} - -/** - * Normalize a host. - * - * @param string $host The host. - * - * @return string The normalized host. - */ -function normalize_host( $host ) { - return \str_replace( 'www.', '', $host ); -} - -/** - * Get the reply intent URI as a JavaScript URI. - * - * @return string The reply intent URI. - */ -function get_reply_intent_js() { - return sprintf( - 'javascript:(()=>{window.open(\'%s\'+encodeURIComponent(window.location.href));})();', - get_reply_intent_url() - ); -} - -/** - * Get the reply intent URI. - * - * @return string The reply intent URI. - */ -function get_reply_intent_url() { - /** - * Filters the reply intent parameters. - * - * @param array $params The reply intent parameters. - */ - $params = \apply_filters( 'activitypub_reply_intent_params', array() ); - - $params += array( 'in_reply_to' => '' ); - $query = \http_build_query( $params ); - $path = 'post-new.php?' . $query; - $url = \admin_url( $path ); - - /** - * Filters the reply intent URL. - * - * @param string $url The reply intent URL. - */ - $url = \apply_filters( 'activitypub_reply_intent_url', $url ); - - return esc_url_raw( $url ); -} - -/** - * Replace content with links, mentions or hashtags by Regex callback and not affect protected tags. - * - * @param string $content The content that should be changed. - * @param string $regex The regex to use. - * @param callable $regex_callback Callback for replacement logic. - * - * @return string The content with links, mentions, hashtags, etc. - */ -function enrich_content_data( $content, $regex, $regex_callback ) { - // Small protection against execution timeouts: limit to 1 MB. - if ( mb_strlen( $content ) > MB_IN_BYTES ) { - return $content; - } - $tag_stack = array(); - $protected_tags = array( - 'pre', - 'code', - 'textarea', - 'style', - 'a', - ); - $content_with_links = ''; - $in_protected_tag = false; - foreach ( wp_html_split( $content ) as $chunk ) { - if ( preg_match( '#^$#i', $chunk, $m ) ) { - $content_with_links .= $chunk; - continue; - } - - if ( preg_match( '#^<(/)?([a-z-]+)\b[^>]*>$#i', $chunk, $m ) ) { - $tag = strtolower( $m[2] ); - if ( '/' === $m[1] ) { - // Closing tag. - $i = array_search( $tag, $tag_stack, true ); - // We can only remove the tag from the stack if it is in the stack. - if ( false !== $i ) { - $tag_stack = array_slice( $tag_stack, 0, $i ); - } - } else { - // Opening tag, add it to the stack. - $tag_stack[] = $tag; - } - - // If we're in a protected tag, the tag_stack contains at least one protected tag string. - // The protected tag state can only change when we encounter a start or end tag. - $in_protected_tag = array_intersect( $tag_stack, $protected_tags ); - - // Never inspect tags. - $content_with_links .= $chunk; - continue; - } - - if ( $in_protected_tag ) { - // Don't inspect a chunk inside an inspected tag. - $content_with_links .= $chunk; - continue; - } - - // Only reachable when there is no protected tag in the stack. - $content_with_links .= \preg_replace_callback( $regex, $regex_callback, $chunk ); - } - - return $content_with_links; -} - -/** - * Generate a summary of a post. - * - * This function generates a summary of a post by extracting: - * - * 1. The post excerpt if it exists. - * 2. The first part of the post content if it contains the tag. - * 3. An excerpt of the post content if it is longer than the specified length. - * - * @param int|\WP_Post $post The post ID or post object. - * @param integer $length The maximum length of the summary. - * Default is 500. It will be ignored if the post excerpt - * and the content above the tag. - * - * @return string The generated post summary. - */ -function generate_post_summary( $post, $length = 500 ) { - $post = get_post( $post ); - - if ( ! $post ) { - return ''; - } - - $content = \sanitize_post_field( 'post_excerpt', $post->post_excerpt, $post->ID ); - - if ( $content ) { - /** This filter is documented in wp-includes/post-template.php */ - return \apply_filters( 'the_excerpt', $content ); - } - - $content = \sanitize_post_field( 'post_content', $post->post_content, $post->ID ); - $content_parts = \get_extended( $content ); - - /** - * Filters the excerpt more value. - * - * @param string $excerpt_more The excerpt more. - */ - $excerpt_more = \apply_filters( 'activitypub_excerpt_more', '[…]' ); - $length = $length - strlen( $excerpt_more ); - - // Check for the tag. - if ( - ! empty( $content_parts['extended'] ) && - ! empty( $content_parts['main'] ) - ) { - $content = $content_parts['main'] . ' ' . $excerpt_more; - $length = null; - } - - $content = \html_entity_decode( $content ); - $content = \wp_strip_all_tags( $content ); - $content = \trim( $content ); - $content = \preg_replace( '/\R+/m', "\n\n", $content ); - $content = \preg_replace( '/[\r\t]/', '', $content ); - - if ( $length && \strlen( $content ) > $length ) { - $content = \wordwrap( $content, $length, '' ); - $content = \explode( '', $content, 2 ); - $content = $content[0] . ' ' . $excerpt_more; - } - - /* - Removed until this is merged: https://github.com/mastodon/mastodon/pull/28629 - /** This filter is documented in wp-includes/post-template.php - return \apply_filters( 'the_excerpt', $content ); - */ - return $content; -} - -/** - * Get the content warning of a post. - * - * @param int|\WP_Post $post_id The post ID or post object. - * - * @return string|false The content warning or false if not found. - */ -function get_content_warning( $post_id ) { - $post = get_post( $post_id ); - if ( ! $post ) { - return false; - } - - $warning = get_post_meta( $post->ID, 'activitypub_content_warning', true ); - if ( empty( $warning ) ) { - return false; - } - - return $warning; -} - -/** - * Get the ActivityPub ID of a User by the WordPress User ID. - * - * @param int $id The WordPress User ID. - * - * @return string The ActivityPub ID (a URL) of the User. - */ -function get_user_id( $id ) { - $user = Actors::get_by_id( $id ); - - if ( ! $user ) { - return false; - } - - return $user->get_id(); -} - -/** - * Get the ActivityPub ID of a Post by the WordPress Post ID. - * - * @param int $id The WordPress Post ID. - * - * @return string The ActivityPub ID (a URL) of the Post. - */ -function get_post_id( $id ) { - $post = get_post( $id ); - - if ( ! $post ) { - return false; - } - - $transformer = new Post( $post ); - return $transformer->get_id(); -} - -/** - * Check if a URL is from the same domain as the site. - * - * @param string $url The URL to check. - * - * @return boolean True if the URL is from the same domain, false otherwise. - */ -function is_same_domain( $url ) { - $remote = \wp_parse_url( $url, PHP_URL_HOST ); - - if ( ! $remote ) { - return false; - } - - $remote = normalize_host( $remote ); - $self = normalize_host( home_host() ); - - return $remote === $self; -} - -/** - * Get the visibility of a post. - * - * @param int $post_id The post ID. - * - * @return string|false The visibility of the post or false if not found. - */ -function get_content_visibility( $post_id ) { - $post = get_post( $post_id ); - if ( ! $post ) { - return false; - } - - $visibility = \get_post_meta( $post->ID, 'activitypub_content_visibility', true ); - $_visibility = ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC; - $options = array( - ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC, - ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE, - ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL, - ); - - if ( in_array( $visibility, $options, true ) ) { - $_visibility = $visibility; - } - - /** - * Filters the visibility of a post. - * - * @param string $_visibility The visibility of the post. Possible values are: - * - 'public': Post is public and federated. - * - 'quiet_public': Post is public but not federated. - * - 'local': Post is only visible locally. - * @param \WP_Post $post The post object. - */ - return \apply_filters( 'activitypub_content_visibility', $_visibility, $post ); -} - -/** - * Retrieves the Host for the current site where the front end is accessible. - * - * @return string The host for the current site. - */ -function home_host() { - return \wp_parse_url( \home_url(), PHP_URL_HOST ); -} - -/** - * Returns the website hosts allowed to credit this blog. - * - * @return array|null The attribution domains or null if not found. - */ -function get_attribution_domains() { - if ( '1' !== \get_option( 'activitypub_use_opengraph', '1' ) ) { - return null; - } - - $domains = \get_option( 'activitypub_attribution_domains', home_host() ); - $domains = explode( PHP_EOL, $domains ); - - if ( ! $domains ) { - $domains = null; - } - - return $domains; -} - -/** - * Get the base URL for uploads. - * - * @return string The upload base URL. - */ -function get_upload_baseurl() { - /** - * Early filter to allow plugins to set the upload base URL. - * - * @param string|false $maybe_upload_dir The upload base URL or false if not set. - */ - $maybe_upload_dir = apply_filters( 'pre_activitypub_get_upload_baseurl', false ); - if ( false !== $maybe_upload_dir ) { - return $maybe_upload_dir; - } - - $upload_dir = \wp_get_upload_dir(); - - /** - * Filters the upload base URL. - * - * @param string $upload_dir The upload base URL. Default \wp_get_upload_dir()['baseurl'] - */ - return apply_filters( 'activitypub_get_upload_baseurl', $upload_dir['baseurl'] ); -} - -/** - * Check if Authorized-Fetch is enabled. - * - * @see https://docs.joinmastodon.org/admin/config/#authorized_fetch - * - * @return boolean True if Authorized-Fetch is enabled, false otherwise. - */ -function use_authorized_fetch() { - $use = (bool) \get_option( 'activitypub_authorized_fetch' ); - - /** - * Filters whether to use Authorized-Fetch. - * - * @param boolean $use_authorized_fetch True if Authorized-Fetch is enabled, false otherwise. - */ - return apply_filters( 'activitypub_use_authorized_fetch', $use ); -} - -/** - * Check if an ID is from the same domain as the site. - * - * @param string $id The ID URI to check. - * - * @return boolean True if the ID is a self-pint, false otherwise. - */ -function is_self_ping( $id ) { - $query_string = \wp_parse_url( $id, PHP_URL_QUERY ); - - if ( ! $query_string ) { - return false; - } - - $query = array(); - \parse_str( $query_string, $query ); - - if ( - is_same_domain( $id ) && - in_array( 'c', array_keys( $query ), true ) - ) { - return true; - } - - return false; -} - -/** - * Add an object to the outbox. - * - * @param mixed $data The object to add to the outbox. - * @param string|null $activity_type Optional. The type of the Activity or null if `$data` is an Activity. Default null. - * @param integer $user_id Optional. The User-ID. Default 0. - * @param string $content_visibility Optional. The visibility of the content. See `constants.php` for possible values: `ACTIVITYPUB_CONTENT_VISIBILITY_*`. Default null. - * - * @return boolean|int The ID of the outbox item or false on failure. - */ -function add_to_outbox( $data, $activity_type = null, $user_id = 0, $content_visibility = null ) { - $transformer = Transformer_Factory::get_transformer( $data ); - - if ( ! $transformer || is_wp_error( $transformer ) ) { - return false; - } - - if ( $content_visibility ) { - $transformer->set_content_visibility( $content_visibility ); - } else { - $content_visibility = $transformer->get_content_visibility(); - } - - if ( $activity_type ) { - $activity = $transformer->to_activity( $activity_type ); - } else { - $activity = $transformer->to_object(); - } - - if ( ! $activity || \is_wp_error( $activity ) ) { - return false; - } - - // If the user is disabled, fall back to the blog user when available. - if ( ! user_can_activitypub( $user_id ) ) { - if ( user_can_activitypub( Actors::BLOG_USER_ID ) ) { - $user_id = Actors::BLOG_USER_ID; - } else { - return false; - } - } - - $outbox_activity_id = Outbox::add( $activity, $user_id, $content_visibility ); - - if ( ! $outbox_activity_id ) { - return false; - } - - /** - * Action triggered after an object has been added to the outbox. - * - * @param int $outbox_activity_id The ID of the outbox item. - * @param Activity $activity The activity object. - * @param int $user_id The User-ID. - * @param string $content_visibility The visibility of the content. See `constants.php` for possible values: `ACTIVITYPUB_CONTENT_VISIBILITY_*`. - */ - \do_action( 'post_activitypub_add_to_outbox', $outbox_activity_id, $activity, $user_id, $content_visibility ); - - set_wp_object_state( $data, 'federated' ); - - return $outbox_activity_id; -} - -/** - * Check if an `$data` is an Activity. - * - * @see https://www.w3.org/ns/activitystreams#activities - * - * @param array|object|string $data The data to check. - * - * @return boolean True if the `$data` is an Activity, false otherwise. - */ -function is_activity( $data ) { - /** - * Filters the activity types. - * - * @param array $types The activity types. - */ - $types = apply_filters( 'activitypub_activity_types', Activity::TYPES ); - - if ( is_string( $data ) ) { - return in_array( $data, $types, true ); - } - - if ( is_array( $data ) && isset( $data['type'] ) ) { - return in_array( $data['type'], $types, true ); - } - - if ( is_object( $data ) && $data instanceof Base_Object ) { - return in_array( $data->get_type(), $types, true ); - } - - return false; -} - -/** - * Check if an `$data` is an Actor. - * - * @see https://www.w3.org/ns/activitystreams#actor - * - * @param array|object|string $data The data to check. - * - * @return boolean True if the `$data` is an Actor, false otherwise. - */ -function is_actor( $data ) { - /** - * Filters the actor types. - * - * @param array $types The actor types. - */ - $types = apply_filters( 'activitypub_actor_types', Actor::TYPES ); - - if ( is_string( $data ) ) { - return in_array( $data, $types, true ); - } - - if ( is_array( $data ) && isset( $data['type'] ) ) { - return in_array( $data['type'], $types, true ); - } - - if ( is_object( $data ) && $data instanceof Base_Object ) { - return in_array( $data->get_type(), $types, true ); - } - - return false; -} - -/** - * Get an ActivityPub embed HTML for a URL. - * - * @param string $url The URL to get the embed for. - * @param boolean $inline_css Whether to inline CSS. Default true. - * - * @return string|false The embed HTML or false if not found. - */ -function get_embed_html( $url, $inline_css = true ) { - return Embed::get_html( $url, $inline_css ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-announce.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-announce.php deleted file mode 100644 index 660bd028..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-announce.php +++ /dev/null @@ -1,125 +0,0 @@ -get_json_params(); - - if ( empty( $json_params['type'] ) ) { - return false; - } - - if ( - 'Create' !== $json_params['type'] || - is_wp_error( $request ) - ) { - return $valid; - } - - $object = $json_params['object']; - - if ( ! is_array( $object ) ) { - return false; - } - - $required = array( - 'id', - 'content', - ); - - if ( array_intersect( $required, array_keys( $object ) ) !== $required ) { - return false; - } - - return $valid; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-delete.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-delete.php deleted file mode 100644 index 94faf57d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-delete.php +++ /dev/null @@ -1,196 +0,0 @@ -delete(); - self::maybe_delete_interactions( $activity ); - } - } - - /** - * Delete Reactions if Actor-URL is a Tombstone. - * - * @param array $activity The delete activity. - */ - public static function maybe_delete_interactions( $activity ) { - // Verify that Actor is deleted. - if ( Http::is_tombstone( $activity['actor'] ) ) { - \wp_schedule_single_event( - \time(), - 'activitypub_delete_actor_interactions', - array( $activity['actor'] ) - ); - } - } - - /** - * Delete comments from an Actor. - * - * @param string $actor The URL of the actor whose comments to delete. - */ - public static function delete_interactions( $actor ) { - $comments = Interactions::get_interactions_by_actor( $actor ); - - foreach ( $comments as $comment ) { - wp_delete_comment( $comment, true ); - } - } - - /** - * Delete a Reaction if URL is a Tombstone. - * - * @param array $activity The delete activity. - */ - public static function maybe_delete_interaction( $activity ) { - if ( is_array( $activity['object'] ) ) { - $id = $activity['object']['id']; - } else { - $id = $activity['object']; - } - - $comments = Interactions::get_interaction_by_id( $id ); - - if ( $comments && Http::is_tombstone( $id ) ) { - foreach ( $comments as $comment ) { - wp_delete_comment( $comment->comment_ID, true ); - } - } - } - - /** - * Defer signature verification for `Delete` requests. - * - * @param bool $defer Whether to defer signature verification. - * @param WP_REST_Request $request The request object. - * - * @return bool Whether to defer signature verification. - */ - public static function defer_signature_verification( $defer, $request ) { - $json = $request->get_json_params(); - - if ( isset( $json['type'] ) && 'Delete' === $json['type'] ) { - return true; - } - - return false; - } - - /** - * Set the object to the object ID. - * - * @param \Activitypub\Activity\Activity $activity The Activity object. - * @return \Activitypub\Activity\Activity The filtered Activity object. - */ - public static function outbox_activity( $activity ) { - if ( 'Delete' === $activity->get_type() ) { - $activity->set_object( object_to_uri( $activity->get_object() ) ); - } - - return $activity; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-follow.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-follow.php deleted file mode 100644 index a1942211..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-follow.php +++ /dev/null @@ -1,114 +0,0 @@ -get__id(); - - // Save follower. - $follower = Followers::add_follower( - $user_id, - $activity['actor'] - ); - - /** - * Fires after a new follower has been added. - * - * @param string $actor The URL of the actor (follower) who initiated the follow. - * @param array $activity The complete activity data of the follow request. - * @param int $user_id The ID of the WordPress user being followed. - * @param \Activitypub\Model\Follower|\WP_Error $follower The Follower object containing the new follower's data. - */ - do_action( 'activitypub_followers_post_follow', $activity['actor'], $activity, $user_id, $follower ); - - // Send notification. - $notification = new Notification( - 'follow', - $activity['actor'], - $activity, - $user_id - ); - $notification->send(); - } - - /** - * Send Accept response. - * - * @param string $actor The Actor URL. - * @param array $activity_object The Activity object. - * @param int $user_id The ID of the WordPress User. - * @param \Activitypub\Model\Follower|\WP_Error $follower The Follower object. - */ - public static function queue_accept( $actor, $activity_object, $user_id, $follower ) { - if ( \is_wp_error( $follower ) ) { - // Impossible to send a "Reject" because we can not get the Remote-Inbox. - return; - } - - // Only send minimal data. - $activity_object = array_intersect_key( - $activity_object, - array_flip( - array( - 'id', - 'type', - 'actor', - 'object', - ) - ) - ); - - $activity = new Activity(); - $activity->set_type( 'Accept' ); - $activity->set_actor( Actors::get_by_id( $user_id )->get_id() ); - $activity->set_object( $activity_object ); - $activity->set_to( array( $actor ) ); - - add_to_outbox( $activity, null, $user_id, ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-like.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-like.php deleted file mode 100644 index 10cbce85..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-like.php +++ /dev/null @@ -1,80 +0,0 @@ -get_type() ) { - $activity->set_object( object_to_uri( $activity->get_object() ) ); - } - - return $activity; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-move.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-move.php deleted file mode 100644 index 71032a45..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-move.php +++ /dev/null @@ -1,213 +0,0 @@ -from_array( $target_object ); - $origin_follower->set_id( $target ); - $origin_id = $origin_follower->upsert(); - - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery - $wpdb->update( - $wpdb->posts, - array( 'guid' => sanitize_url( $target ) ), - array( 'ID' => sanitize_key( $origin_id ) ) - ); - - // Clear the cache. - wp_cache_delete( $origin_id, 'posts' ); - return; - } - - /* - * If the new target is followed, and the origin is followed, - * move users and delete the origin follower. - */ - if ( $target_follower && $origin_follower ) { - $origin_users = \get_post_meta( $origin_follower->get__id(), '_activitypub_user_id', false ); - $target_users = \get_post_meta( $target_follower->get__id(), '_activitypub_user_id', false ); - - // Get all user ids from $origin_users that are not in $target_users. - $users = \array_diff( $origin_users, $target_users ); - - foreach ( $users as $user_id ) { - \add_post_meta( $target_follower->get__id(), '_activitypub_user_id', $user_id ); - } - - $origin_follower->delete(); - } - } - - /** - * Convert the object and origin to the correct format. - * - * @param \Activitypub\Activity\Activity $activity The Activity object. - * @return \Activitypub\Activity\Activity The filtered Activity object. - */ - public static function outbox_activity( $activity ) { - if ( 'Move' === $activity->get_type() ) { - $activity->set_object( object_to_uri( $activity->get_object() ) ); - $activity->set_origin( $activity->get_actor() ); - $activity->set_target( $activity->get_object() ); - } - - return $activity; - } - - /** - * Extract the target from the activity. - * - * The ActivityStreams spec define the `target` attribute as the - * destination of the activity, but Mastodon uses the `object` - * attribute to move profiles. - * - * @param array $activity The JSON "Move" Activity. - * - * @return string|null The target URI or null if not found. - */ - private static function extract_target( $activity ) { - if ( ! empty( $activity['target'] ) ) { - return object_to_uri( $activity['target'] ); - } - - if ( ! empty( $activity['object'] ) ) { - return object_to_uri( $activity['object'] ); - } - - return null; - } - - /** - * Extract the origin from the activity. - * - * The ActivityStreams spec define the `origin` attribute as source - * of the activity, but Mastodon uses the `actor` attribute as source - * to move profiles. - * - * @param array $activity The JSON "Move" Activity. - * - * @return string|null The origin URI or null if not found. - */ - private static function extract_origin( $activity ) { - if ( ! empty( $activity['origin'] ) ) { - return object_to_uri( $activity['origin'] ); - } - - if ( ! empty( $activity['actor'] ) ) { - return object_to_uri( $activity['actor'] ); - } - - return null; - } - - /** - * Verify the move. - * - * @param array $target_object The target object. - * @param array $origin_object The origin object. - * - * @return bool True if the move is verified, false otherwise. - */ - private static function verify_move( $target_object, $origin_object ) { - // Check if both objects are valid. - if ( \is_wp_error( $target_object ) || \is_wp_error( $origin_object ) ) { - return false; - } - - // Check if both objects are persons. - if ( 'Person' !== $target_object['type'] || 'Person' !== $origin_object['type'] ) { - return false; - } - - // Check if the target and origin are not the same. - if ( $target_object['id'] === $origin_object['id'] ) { - return false; - } - - // Check if the target has an alsoKnownAs property. - if ( empty( $target_object['also_known_as'] ) ) { - return false; - } - - // Check if the origin is in the alsoKnownAs property of the target. - if ( ! in_array( $origin_object['id'], $target_object['also_known_as'], true ) ) { - return false; - } - - // Check if the origin has a movedTo property. - if ( empty( $origin_object['movedTo'] ) ) { - return false; - } - - // Check if the movedTo property of the origin is the target. - if ( $origin_object['movedTo'] !== $target_object['id'] ) { - return false; - } - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-undo.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-undo.php deleted file mode 100644 index dcbc6f72..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-undo.php +++ /dev/null @@ -1,90 +0,0 @@ -get__id(); - $actor = object_to_uri( $activity['actor'] ); - - $state = Followers::remove_follower( $user_id, $actor ); - } - - // Handle "Undo" requests for "Like" and "Create" activities. - if ( in_array( $type, array( 'Like', 'Create', 'Announce' ), true ) ) { - if ( ACTIVITYPUB_DISABLE_INCOMING_INTERACTIONS ) { - return; - } - - $object_id = object_to_uri( $activity['object'] ); - $comment = Comment::object_id_to_comment( esc_url_raw( $object_id ) ); - - if ( empty( $comment ) ) { - return; - } - - $state = wp_delete_comment( $comment, true ); - } - - /** - * Fires after an "Undo" activity has been handled. - * - * @param array $activity The JSON "Undo" Activity. - * @param int|null $user_id The ID of the user who initiated the "Undo" activity otherwise null. - * @param mixed $state The state of the "Undo" activity. - */ - do_action( 'activitypub_handled_undo', $activity, $user_id, $state ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-update.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-update.php deleted file mode 100644 index 2a068b29..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/handler/class-update.php +++ /dev/null @@ -1,125 +0,0 @@ -from_array( $actor ); - $follower->upsert(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-application.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-application.php deleted file mode 100644 index 0309941e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-application.php +++ /dev/null @@ -1,255 +0,0 @@ -get_id(); - } - - /** - * Returns the User-URL with @-Prefix for the username. - * - * @return string The User-URL with @-Prefix for the username. - */ - public function get_alternate_url() { - return $this->get_id(); - } - - /** - * Get the Username. - * - * @return string The Username. - */ - public function get_name() { - return 'application'; - } - - /** - * Get the preferred username. - * - * @return string The preferred username. - */ - public function get_preferred_username() { - return $this->get_name(); - } - - /** - * Get the User-Icon. - * - * @return string[] The User-Icon. - */ - public function get_icon() { - // Try site icon first. - $icon_id = get_option( 'site_icon' ); - - // Try custom logo second. - if ( ! $icon_id ) { - $icon_id = get_theme_mod( 'custom_logo' ); - } - - $icon_url = false; - - if ( $icon_id ) { - $icon = wp_get_attachment_image_src( $icon_id, 'full' ); - if ( $icon ) { - $icon_url = $icon[0]; - } - } - - if ( ! $icon_url ) { - // Fallback to default icon. - $icon_url = plugins_url( '/assets/img/wp-logo.png', ACTIVITYPUB_PLUGIN_FILE ); - } - - return array( - 'type' => 'Image', - 'url' => esc_url( $icon_url ), - ); - } - - /** - * Get the User-Header-Image. - * - * @return string[]|null The User-Header-Image. - */ - public function get_header_image() { - if ( \has_header_image() ) { - return array( - 'type' => 'Image', - 'url' => esc_url( \get_header_image() ), - ); - } - - return null; - } - - /** - * Get the first published date. - * - * @return string The published date. - */ - public function get_published() { - $first_post = new WP_Query( - array( - 'orderby' => 'date', - 'order' => 'ASC', - 'number' => 1, - ) - ); - - if ( ! empty( $first_post->posts[0] ) ) { - $time = \strtotime( $first_post->posts[0]->post_date_gmt ); - } else { - $time = \time(); - } - - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $time ); - } - - /** - * Returns the Inbox-API-Endpoint. - * - * @return string The Inbox-Endpoint. - */ - public function get_inbox() { - return get_rest_url_by_path( sprintf( 'actors/%d/inbox', $this->get__id() ) ); - } - - /** - * Returns the Outbox-API-Endpoint. - * - * @return string The Outbox-Endpoint. - */ - public function get_outbox() { - return get_rest_url_by_path( sprintf( 'actors/%d/outbox', $this->get__id() ) ); - } - - /** - * Returns a user@domain type of identifier for the user. - * - * @return string The Webfinger-Identifier. - */ - public function get_webfinger() { - return $this->get_preferred_username() . '@' . \wp_parse_url( \home_url(), \PHP_URL_HOST ); - } - - /** - * Returns the public key. - * - * @return string[] The public key. - */ - public function get_public_key() { - return array( - 'id' => $this->get_id() . '#main-key', - 'owner' => $this->get_id(), - 'publicKeyPem' => Signature::get_public_key_for( Actors::APPLICATION_USER_ID ), - ); - } - - /** - * Get the User description. - * - * @return string The User description. - */ - public function get_summary() { - return \wpautop( - \wp_kses( - \get_bloginfo( 'description' ), - 'default' - ) - ); - } - - /** - * Returns the canonical URL of the object. - * - * @return string|null The canonical URL of the object. - */ - public function get_canonical_url() { - return \home_url(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-blog.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-blog.php deleted file mode 100644 index e46e5b02..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-blog.php +++ /dev/null @@ -1,600 +0,0 @@ -get_url(); - } - - return \add_query_arg( 'author', $this->_id, \trailingslashit( \home_url() ) ); - } - - /** - * Get the type of the object. - * - * If the Blog is in "single user" mode, return "Person" instead of "Group". - * - * @return string The type of the object. - */ - public function get_type() { - if ( is_single_user() ) { - return 'Person'; - } else { - return 'Group'; - } - } - - /** - * Get the Username. - * - * @return string The Username. - */ - public function get_name() { - return \wp_strip_all_tags( - \html_entity_decode( - \get_bloginfo( 'name' ), - \ENT_QUOTES, - 'UTF-8' - ) - ); - } - - /** - * Get the User description. - * - * @return string The User description. - */ - public function get_summary() { - $summary = \get_option( 'activitypub_blog_description', null ); - - if ( ! $summary ) { - $summary = \get_bloginfo( 'description' ); - } - - return \wpautop( - \wp_kses( - $summary, - 'default' - ) - ); - } - - /** - * Get the User url. - * - * @return string The User url. - */ - public function get_url() { - return \esc_url( \trailingslashit( get_home_url() ) . '@' . $this->get_preferred_username() ); - } - - /** - * Get blog's homepage URL. - * - * @return string The User-Url. - */ - public function get_alternate_url() { - return \esc_url( \trailingslashit( get_home_url() ) ); - } - - /** - * Generate a default Username. - * - * @return string The auto-generated Username. - */ - public static function get_default_username() { - // Check if domain host has a subdomain. - $host = \wp_parse_url( \get_home_url(), \PHP_URL_HOST ); - $host = \preg_replace( '/^www\./i', '', $host ); - - /** - * Filters the default blog username. - * - * This filter allows developers to modify the default username that is - * generated for the blog, which by default is the site's host name - * without the 'www.' prefix. - * - * @param string $host The default username (site's host name). - */ - return apply_filters( 'activitypub_default_blog_username', $host ); - } - - /** - * Get the preferred Username. - * - * @return string The Username. - */ - public function get_preferred_username() { - $username = \get_option( 'activitypub_blog_identifier' ); - - if ( $username ) { - return $username; - } - - return self::get_default_username(); - } - - /** - * Get the User icon. - * - * @return string[] The User icon. - */ - public function get_icon() { - // Try site_logo, falling back to site_icon, first. - $icon_id = get_option( 'site_icon' ); - - // Try custom logo second. - if ( ! $icon_id ) { - $icon_id = get_theme_mod( 'custom_logo' ); - } - - $icon_url = false; - - if ( $icon_id ) { - $icon = wp_get_attachment_image_src( $icon_id, 'full' ); - if ( $icon ) { - $icon_url = $icon[0]; - } - } - - if ( ! $icon_url ) { - // Fallback to default icon. - $icon_url = plugins_url( '/assets/img/wp-logo.png', ACTIVITYPUB_PLUGIN_FILE ); - } - - return array( - 'type' => 'Image', - 'url' => esc_url( $icon_url ), - ); - } - - /** - * Get the User-Header-Image. - * - * @return string[]|null The User-Header-Image. - */ - public function get_image() { - $header_image = get_option( 'activitypub_header_image' ); - $image_url = null; - - if ( $header_image ) { - $image_url = \wp_get_attachment_url( $header_image ); - } - - if ( ! $image_url && \has_header_image() ) { - $image_url = \get_header_image(); - } - - if ( $image_url ) { - return array( - 'type' => 'Image', - 'url' => esc_url( $image_url ), - ); - } - - return null; - } - - /** - * Get the published date. - * - * @return string The published date. - */ - public function get_published() { - $first_post = new WP_Query( - array( - 'orderby' => 'date', - 'order' => 'ASC', - 'number' => 1, - ) - ); - - if ( ! empty( $first_post->posts[0] ) ) { - $time = \strtotime( $first_post->posts[0]->post_date_gmt ); - } else { - $time = \time(); - } - - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $time ); - } - - /** - * Get the canonical URL. - * - * @return string|null The canonical URL. - */ - public function get_canonical_url() { - return \home_url(); - } - - /** - * Get the Moderators endpoint. - * - * @return string|null The Moderators endpoint. - */ - public function get_moderators() { - if ( is_single_user() || 'Group' !== $this->get_type() ) { - return null; - } - - return get_rest_url_by_path( 'collections/moderators' ); - } - - /** - * Get attributedTo value. - * - * @return string|null The attributedTo value. - */ - public function get_attributed_to() { - if ( is_single_user() || 'Group' !== $this->get_type() ) { - return null; - } - - return get_rest_url_by_path( 'collections/moderators' ); - } - - /** - * Get the public key information. - * - * @return string[] The public key. - */ - public function get_public_key() { - return array( - 'id' => $this->get_id() . '#main-key', - 'owner' => $this->get_id(), - 'publicKeyPem' => Signature::get_public_key_for( $this->get__id() ), - ); - } - - /** - * Returns whether posting is restricted to mods. - * - * @return bool|null True if posting is restricted to mods, null if not applicable. - */ - public function get_posting_restricted_to_mods() { - if ( 'Group' === $this->get_type() ) { - return true; - } - - return null; - } - - /** - * Returns the Inbox-API-Endpoint. - * - * @return string The Inbox-Endpoint. - */ - public function get_inbox() { - return get_rest_url_by_path( sprintf( 'actors/%d/inbox', $this->get__id() ) ); - } - - /** - * Returns the Outbox-API-Endpoint. - * - * @return string The Outbox-Endpoint. - */ - public function get_outbox() { - return get_rest_url_by_path( sprintf( 'actors/%d/outbox', $this->get__id() ) ); - } - - /** - * Returns the Followers-API-Endpoint. - * - * @return string The Followers-Endpoint. - */ - public function get_followers() { - return get_rest_url_by_path( sprintf( 'actors/%d/followers', $this->get__id() ) ); - } - - /** - * Returns the Following-API-Endpoint. - * - * @return string The Following-Endpoint. - */ - public function get_following() { - return get_rest_url_by_path( sprintf( 'actors/%d/following', $this->get__id() ) ); - } - - /** - * Returns endpoints. - * - * @return string[]|null The endpoints. - */ - public function get_endpoints() { - $endpoints = null; - - if ( \get_option( 'activitypub_shared_inbox' ) ) { - $endpoints = array( - 'sharedInbox' => get_rest_url_by_path( 'inbox' ), - ); - } - - return $endpoints; - } - - /** - * Returns a user@domain type of identifier for the user. - * - * @return string The Webfinger-Identifier. - */ - public function get_webfinger() { - return $this->get_preferred_username() . '@' . \wp_parse_url( \home_url(), \PHP_URL_HOST ); - } - - /** - * Returns the Featured-API-Endpoint. - * - * @return string The Featured-Endpoint. - */ - public function get_featured() { - return get_rest_url_by_path( sprintf( 'actors/%d/collections/featured', $this->get__id() ) ); - } - - /** - * Returns whether the site is indexable. - * - * @return bool Whether the site is indexable. - */ - public function get_indexable() { - if ( is_blog_public() ) { - return true; - } else { - return false; - } - } - - /** - * Update the Username. - * - * @param mixed $value The new value. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_name( $value ) { - return \update_option( 'blogname', $value ); - } - - /** - * Update the User description. - * - * @param mixed $value The new value. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_summary( $value ) { - return \update_option( 'blogdescription', $value ); - } - - /** - * Update the User icon. - * - * @param mixed $value The new value. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_icon( $value ) { - if ( ! wp_attachment_is_image( $value ) ) { - return false; - } - return \update_option( 'site_icon', $value ); - } - - /** - * Update the User-Header-Image. - * - * @param mixed $value The new value. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_header( $value ) { - if ( ! wp_attachment_is_image( $value ) ) { - return false; - } - return \update_option( 'activitypub_header_image', $value ); - } - - /** - * Get the User - Hashtags. - * - * @see https://docs.joinmastodon.org/spec/activitypub/#Hashtag - * - * @return string[] The User - Hashtags. - */ - public function get_tag() { - $hashtags = array(); - - $args = array( - 'orderby' => 'count', - 'order' => 'DESC', - 'number' => 10, - ); - - $tags = get_tags( $args ); - - foreach ( $tags as $tag ) { - $hashtags[] = array( - 'type' => 'Hashtag', - 'href' => \get_tag_link( $tag->term_id ), - 'name' => esc_hashtag( $tag->name ), - ); - } - - return $hashtags; - } - - /** - * Extend the User-Output with Attachments. - * - * @return array The extended User-Output. - */ - public function get_attachment() { - $extra_fields = Extra_Fields::get_actor_fields( $this->_id ); - return Extra_Fields::fields_to_attachments( $extra_fields ); - } - - /** - * Returns the website hosts allowed to credit this blog. - * - * @return string[]|null The attribution domains or null if not found. - */ - public function get_attribution_domains() { - return get_attribution_domains(); - } - - /** - * Returns the alsoKnownAs. - * - * @return string[] The alsoKnownAs. - */ - public function get_also_known_as() { - $also_known_as = array( - \add_query_arg( 'author', $this->_id, \home_url( '/' ) ), - $this->get_url(), - $this->get_alternate_url(), - ); - - $also_known_as = array_merge( $also_known_as, \get_option( 'activitypub_blog_user_also_known_as', array() ) ); - - return array_unique( $also_known_as ); - } - - /** - * Returns the movedTo. - * - * @return string The movedTo. - */ - public function get_moved_to() { - $moved_to = \get_option( 'activitypub_blog_user_moved_to' ); - - return $moved_to && $moved_to !== $this->get_id() ? $moved_to : null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-follower.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-follower.php deleted file mode 100644 index c7d50ea2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-follower.php +++ /dev/null @@ -1,410 +0,0 @@ -_id, '_activitypub_errors', false ); - } - - /** - * Get the Summary. - * - * @return string The Summary. - */ - public function get_summary() { - if ( isset( $this->summary ) ) { - return $this->summary; - } - - return ''; - } - - /** - * Getter for URL attribute. - * - * Falls back to ID, if no URL is set. This is relevant for - * Platforms like Lemmy, where the ID is the URL. - * - * @return string The URL. - */ - public function get_url() { - if ( $this->url ) { - return $this->url; - } - - return $this->id; - } - - /** - * Reset (delete) all errors. - */ - public function reset_errors() { - delete_post_meta( $this->_id, '_activitypub_errors' ); - } - - /** - * Count the errors. - * - * @return int The number of errors. - */ - public function count_errors() { - $errors = $this->get_errors(); - - if ( is_array( $errors ) && ! empty( $errors ) ) { - return count( $errors ); - } - - return 0; - } - - /** - * Return the latest error message. - * - * @return string The error message. - */ - public function get_latest_error_message() { - $errors = $this->get_errors(); - - if ( is_array( $errors ) && ! empty( $errors ) ) { - return reset( $errors ); - } - - return ''; - } - - /** - * Update the current Follower object. - */ - public function update() { - $this->save(); - } - - /** - * Validate the current Follower object. - * - * @return boolean True if the verification was successful. - */ - public function is_valid() { - // The minimum required attributes. - $required_attributes = array( - 'id', - 'preferredUsername', - 'inbox', - 'publicKey', - 'publicKeyPem', - ); - - foreach ( $required_attributes as $attribute ) { - if ( ! $this->get( $attribute ) ) { - return false; - } - } - - return true; - } - - /** - * Save the current Follower object. - * - * @return int|WP_Error The post ID or an WP_Error. - */ - public function save() { - if ( ! $this->is_valid() ) { - return new WP_Error( 'activitypub_invalid_follower', __( 'Invalid Follower', 'activitypub' ), array( 'status' => 400 ) ); - } - - if ( ! $this->get__id() ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $post_id = $wpdb->get_var( - $wpdb->prepare( - "SELECT ID FROM $wpdb->posts WHERE guid=%s", - esc_sql( $this->get_id() ) - ) - ); - - if ( $post_id ) { - $post = get_post( $post_id ); - $this->set__id( $post->ID ); - } - } - - $post_id = $this->get__id(); - - $args = array( - 'ID' => $post_id, - 'guid' => esc_url_raw( $this->get_id() ), - 'post_title' => wp_strip_all_tags( sanitize_text_field( $this->get_name() ) ), - 'post_author' => 0, - 'post_type' => Followers::POST_TYPE, - 'post_name' => esc_url_raw( $this->get_id() ), - 'post_excerpt' => sanitize_text_field( wp_kses( $this->get_summary(), 'user_description' ) ), - 'post_status' => 'publish', - 'meta_input' => $this->get_post_meta_input(), - ); - - if ( ! empty( $post_id ) ) { - // If this is an update, prevent the "followed" date from being overwritten by the current date. - $post = get_post( $post_id ); - $args['post_date'] = $post->post_date; - $args['post_date_gmt'] = $post->post_date_gmt; - } - - $post_id = wp_insert_post( $args ); - $this->_id = $post_id; - - return $post_id; - } - - /** - * Upsert the current Follower object. - * - * @return int|WP_Error The post ID or an WP_Error. - */ - public function upsert() { - return $this->save(); - } - - /** - * Delete the current Follower object. - * - * Beware that this os deleting a Follower for ALL users!!! - * - * To delete only the User connection (unfollow) - * - * @see \Activitypub\Rest\Followers::remove_follower() - */ - public function delete() { - wp_delete_post( $this->_id ); - } - - /** - * Update the post meta. - */ - protected function get_post_meta_input() { - $meta_input = array(); - $meta_input['_activitypub_inbox'] = $this->get_shared_inbox(); - $meta_input['_activitypub_actor_json'] = wp_slash( $this->to_json() ); - - return $meta_input; - } - - /** - * Get the icon. - * - * Sets a fallback to better handle API and HTML outputs. - * - * @return string[] The icon. - */ - public function get_icon() { - if ( isset( $this->icon['url'] ) ) { - return $this->icon; - } - - return array( - 'type' => 'Image', - 'mediaType' => 'image/jpeg', - 'url' => ACTIVITYPUB_PLUGIN_URL . 'assets/img/mp.jpg', - ); - } - - /** - * Get Name. - * - * Tries to extract a name from the URL or ID if not set. - * - * @return string The name. - */ - public function get_name() { - if ( $this->name ) { - return $this->name; - } elseif ( $this->preferred_username ) { - return $this->preferred_username; - } - - return $this->extract_name_from_uri(); - } - - /** - * The preferred Username. - * - * Tries to extract a name from the URL or ID if not set. - * - * @return string The preferred Username. - */ - public function get_preferred_username() { - if ( $this->preferred_username ) { - return $this->preferred_username; - } - - return $this->extract_name_from_uri(); - } - - /** - * Get the Icon URL (Avatar). - * - * @return string The URL to the Avatar. - */ - public function get_icon_url() { - $icon = $this->get_icon(); - - if ( ! $icon ) { - return ''; - } - - if ( is_array( $icon ) ) { - return $icon['url']; - } - - return $icon; - } - - /** - * Get the Icon URL (Avatar). - * - * @return string The URL to the Avatar. - */ - public function get_image_url() { - $image = $this->get_image(); - - if ( ! $image ) { - return ''; - } - - if ( is_array( $image ) ) { - return $image['url']; - } - - return $image; - } - - /** - * Get the shared inbox, with a fallback to the inbox. - * - * @return string|null The URL to the shared inbox, the inbox or null. - */ - public function get_shared_inbox() { - if ( ! empty( $this->get_endpoints()['sharedInbox'] ) ) { - return $this->get_endpoints()['sharedInbox']; - } elseif ( ! empty( $this->get_inbox() ) ) { - return $this->get_inbox(); - } - - return null; - } - - /** - * Convert a Custom-Post-Type input to an Activitypub\Model\Follower. - * - * @param \WP_Post $post The post object. - * @return Follower|false The Follower object or false on failure. - */ - public static function init_from_cpt( $post ) { - $actor_json = get_post_meta( $post->ID, '_activitypub_actor_json', true ); - - /* @var Follower $object Follower object. */ - $object = self::init_from_json( $actor_json ); - - if ( is_wp_error( $object ) ) { - return false; - } - - $object->set__id( $post->ID ); - $object->set_id( $post->guid ); - $object->set_name( $post->post_title ); - $object->set_summary( $post->post_excerpt ); - $object->set_published( gmdate( 'Y-m-d H:i:s', strtotime( $post->post_date ) ) ); - $object->set_updated( gmdate( 'Y-m-d H:i:s', strtotime( $post->post_modified ) ) ); - - return $object; - } - - /** - * Infer a shortname from the Actor ID or URL. Used only for fallbacks, - * we will try to use what's supplied. - * - * @return string Hopefully the name of the Follower. - */ - protected function extract_name_from_uri() { - // prefer the URL, but fall back to the ID. - if ( $this->url ) { - $name = $this->url; - } else { - $name = $this->id; - } - - if ( \filter_var( $name, FILTER_VALIDATE_URL ) ) { - $name = \rtrim( $name, '/' ); - $path = \wp_parse_url( $name, PHP_URL_PATH ); - - if ( $path ) { - if ( \strpos( $name, '@' ) !== false ) { - // Expected: https://example.com/@user (default URL pattern). - $name = \preg_replace( '|^/@?|', '', $path ); - } else { - // Expected: https://example.com/users/user (default ID pattern). - $parts = \explode( '/', $path ); - $name = \array_pop( $parts ); - } - } - } elseif ( - \is_email( $name ) || - \strpos( $name, 'acct' ) === 0 || - \strpos( $name, '@' ) === 0 - ) { - // Expected: user@example.com or acct:user@example (WebFinger). - $name = \ltrim( $name, '@' ); - $name = \ltrim( $name, 'acct:' ); - $parts = \explode( '@', $name ); - $name = $parts[0]; - } - - return $name; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-user.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-user.php deleted file mode 100644 index 964c7867..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/model/class-user.php +++ /dev/null @@ -1,474 +0,0 @@ -_id = $user_id; - - /** - * Fires when a model actor is constructed. - * - * @param User $this The User object. - */ - \do_action( 'activitypub_construct_model_actor', $this ); - } - } - - /** - * The type of the object. - * - * @return string The type of the object. - */ - public function get_type() { - return 'Person'; - } - - /** - * Generate a User object from a WP_User. - * - * @param int $user_id The user ID. - * - * @return \WP_Error|User The User object or \WP_Error if user not found. - */ - public static function from_wp_user( $user_id ) { - if ( ! user_can_activitypub( $user_id ) ) { - return new \WP_Error( - 'activitypub_user_not_found', - \__( 'User not found', 'activitypub' ), - array( 'status' => 404 ) - ); - } - - return new static( $user_id ); - } - - /** - * Get the user ID. - * - * @return string The user ID. - */ - public function get_id() { - $id = parent::get_id(); - - if ( $id ) { - return $id; - } - - $permalink = \get_user_option( 'activitypub_use_permalink_as_id', $this->_id ); - - if ( '1' === $permalink ) { - return $this->get_url(); - } - - return \add_query_arg( 'author', $this->_id, \trailingslashit( \home_url() ) ); - } - - /** - * Get the Username. - * - * @return string The Username. - */ - public function get_name() { - return \get_the_author_meta( 'display_name', $this->_id ); - } - - /** - * Get the User description. - * - * @return string The User description. - */ - public function get_summary() { - $description = get_user_option( 'activitypub_description', $this->_id ); - if ( empty( $description ) ) { - $description = get_user_meta( $this->_id, 'description', true ); - } - return \wpautop( \wp_kses( $description, 'default' ) ); - } - - /** - * Get the User url. - * - * @return string The User url. - */ - public function get_url() { - return \esc_url( \get_author_posts_url( $this->_id ) ); - } - - /** - * Returns the User URL with @-Prefix for the username. - * - * @return string The User URL with @-Prefix for the username. - */ - public function get_alternate_url() { - return \esc_url( \trailingslashit( get_home_url() ) . '@' . $this->get_preferred_username() ); - } - - /** - * Get the preferred username. - * - * @return string The preferred username. - */ - public function get_preferred_username() { - return \get_the_author_meta( 'login', $this->_id ); - } - - /** - * Get the User icon. - * - * @return string[] The User icon. - */ - public function get_icon() { - $icon = \get_user_option( 'activitypub_icon', $this->_id ); - if ( false !== $icon && wp_attachment_is_image( $icon ) ) { - return array( - 'type' => 'Image', - 'url' => esc_url( wp_get_attachment_url( $icon ) ), - ); - } - - $icon = \esc_url( - \get_avatar_url( - $this->_id, - array( 'size' => 120 ) - ) - ); - - return array( - 'type' => 'Image', - 'url' => $icon, - ); - } - - /** - * Returns the header image. - * - * @return string[]|null The header image. - */ - public function get_image() { - $header_image = get_user_option( 'activitypub_header_image', $this->_id ); - $image_url = null; - - if ( ! $header_image && \has_header_image() ) { - $image_url = \get_header_image(); - } - - if ( $header_image ) { - $image_url = \wp_get_attachment_url( $header_image ); - } - - if ( $image_url ) { - return array( - 'type' => 'Image', - 'url' => esc_url( $image_url ), - ); - } - - return null; - } - - /** - * Returns the date the user was created. - * - * @return false|string The date the user was created. - */ - public function get_published() { - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, \strtotime( \get_the_author_meta( 'registered', $this->_id ) ) ); - } - - /** - * Returns the public key. - * - * @return string[] The public key. - */ - public function get_public_key() { - return array( - 'id' => $this->get_id() . '#main-key', - 'owner' => $this->get_id(), - 'publicKeyPem' => Signature::get_public_key_for( $this->get__id() ), - ); - } - - /** - * Returns the Inbox-API-Endpoint. - * - * @return string The Inbox-Endpoint. - */ - public function get_inbox() { - return get_rest_url_by_path( sprintf( 'actors/%d/inbox', $this->get__id() ) ); - } - - /** - * Returns the Outbox-API-Endpoint. - * - * @return string The Outbox-Endpoint. - */ - public function get_outbox() { - return get_rest_url_by_path( sprintf( 'actors/%d/outbox', $this->get__id() ) ); - } - - /** - * Returns the Followers-API-Endpoint. - * - * @return string The Followers-Endpoint. - */ - public function get_followers() { - return get_rest_url_by_path( sprintf( 'actors/%d/followers', $this->get__id() ) ); - } - - /** - * Returns the Following-API-Endpoint. - * - * @return string The Following-Endpoint. - */ - public function get_following() { - return get_rest_url_by_path( sprintf( 'actors/%d/following', $this->get__id() ) ); - } - - /** - * Returns the Featured-API-Endpoint. - * - * @return string The Featured-Endpoint. - */ - public function get_featured() { - return get_rest_url_by_path( sprintf( 'actors/%d/collections/featured', $this->get__id() ) ); - } - - /** - * Returns the endpoints. - * - * @return string[]|null The endpoints. - */ - public function get_endpoints() { - $endpoints = null; - - if ( \get_option( 'activitypub_shared_inbox' ) ) { - $endpoints = array( - 'sharedInbox' => get_rest_url_by_path( 'inbox' ), - ); - } - - return $endpoints; - } - - /** - * Extend the User-Output with Attachments. - * - * @return array The extended User-Output. - */ - public function get_attachment() { - $extra_fields = Extra_Fields::get_actor_fields( $this->_id ); - return Extra_Fields::fields_to_attachments( $extra_fields ); - } - - /** - * Returns a user@domain type of identifier for the user. - * - * @return string The Webfinger-Identifier. - */ - public function get_webfinger() { - return $this->get_preferred_username() . '@' . \wp_parse_url( \home_url(), \PHP_URL_HOST ); - } - - /** - * Returns the canonical URL. - * - * @return string The canonical URL. - */ - public function get_canonical_url() { - return $this->get_url(); - } - - /** - * Returns the streams. - * - * @return null The streams. - */ - public function get_streams() { - return null; - } - - /** - * Returns the tag. - * - * @return array The tag. - */ - public function get_tag() { - return array(); - } - - /** - * Returns the indexable state. - * - * @return bool Whether the user is indexable. - */ - public function get_indexable() { - if ( is_blog_public() ) { - return true; - } else { - return false; - } - } - - /** - * Update the username. - * - * @param string $value The new value. - * @return int|\WP_Error The updated user ID or \WP_Error on failure. - */ - public function update_name( $value ) { - $userdata = array( - 'ID' => $this->_id, - 'display_name' => $value, - ); - return \wp_update_user( $userdata ); - } - - /** - * Update the User description. - * - * @param string $value The new value. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_summary( $value ) { - return \update_user_option( $this->_id, 'activitypub_description', $value ); - } - - /** - * Update the User icon. - * - * @param int $value The new value. Should be an attachment ID. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_icon( $value ) { - if ( ! wp_attachment_is_image( $value ) ) { - return false; - } - return update_user_option( $this->_id, 'activitypub_icon', $value ); - } - - /** - * Update the User-Header-Image. - * - * @param int $value The new value. Should be an attachment ID. - * @return bool True if the attribute was updated, false otherwise. - */ - public function update_header( $value ) { - if ( ! wp_attachment_is_image( $value ) ) { - return false; - } - return \update_user_option( $this->_id, 'activitypub_header_image', $value ); - } - - /** - * Returns the website hosts allowed to credit this blog. - * - * @return string[]|null The attribution domains or null if not found. - */ - public function get_attribution_domains() { - return get_attribution_domains(); - } - - /** - * Returns the alsoKnownAs. - * - * @return string[] The alsoKnownAs. - */ - public function get_also_known_as() { - $also_known_as = array( - \add_query_arg( 'author', $this->_id, \home_url( '/' ) ), - $this->get_url(), - $this->get_alternate_url(), - ); - - // phpcs:ignore Universal.Operators.DisallowShortTernary.Found - $also_known_as = array_merge( $also_known_as, \get_user_option( 'activitypub_also_known_as', $this->_id ) ?: array() ); - - return array_unique( $also_known_as ); - } - - /** - * Returns the movedTo. - * - * @return string The movedTo. - */ - public function get_moved_to() { - $moved_to = \get_user_option( 'activitypub_moved_to', $this->_id ); - - return $moved_to && $moved_to !== $this->get_id() ? $moved_to : null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-actors-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-actors-controller.php deleted file mode 100644 index 15cd0c5c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-actors-controller.php +++ /dev/null @@ -1,359 +0,0 @@ -[\w\-\.]+)'; - - /** - * Register routes. - */ - public function register_routes() { - \register_rest_route( - $this->namespace, - '/' . $this->rest_base, - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The ID or username of the actor.', - 'type' => 'string', - 'required' => true, - 'pattern' => '[\w\-\.]+', - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_item' ), - 'permission_callback' => array( 'Activitypub\Rest\Server', 'verify_signature' ), - ), - 'schema' => array( $this, 'get_public_item_schema' ), - ) - ); - - \register_rest_route( - $this->namespace, - '/' . $this->rest_base . '/remote-follow', - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The ID or username of the actor.', - 'type' => 'string', - 'required' => true, - 'pattern' => '[\w\-\.]+', - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_remote_follow_item' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'resource' => array( - 'description' => 'The resource to follow.', - 'type' => 'string', - 'required' => true, - ), - ), - ), - ) - ); - } - - /** - * Retrieves a single actor. - * - * @param \WP_REST_Request $request Full details about the request. - * @return \WP_REST_Response|\WP_Error Response object on success, or WP_Error object on failure. - */ - public function get_item( $request ) { - $user_id = $request->get_param( 'user_id' ); - $user = Actor_Collection::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - /** - * Action triggered prior to the ActivityPub profile being created and sent to the client. - */ - \do_action( 'activitypub_rest_users_pre' ); - - $data = $user->to_array(); - - $response = \rest_ensure_response( $data ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - $response->header( 'Link', \sprintf( '<%1$s>; rel="alternate"; type="application/activity+json"', $user->get_id() ) ); - - return $response; - } - - /** - * Retrieves the remote follow endpoint. - * - * @param \WP_REST_Request $request Full details about the request. - * @return \WP_REST_Response|\WP_Error Response object on success, or WP_Error object on failure. - */ - public function get_remote_follow_item( $request ) { - $resource = $request->get_param( 'resource' ); - $user_id = $request->get_param( 'user_id' ); - $user = Actor_Collection::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - $template = Webfinger::get_remote_follow_endpoint( $resource ); - - if ( \is_wp_error( $template ) ) { - return $template; - } - - $resource = $user->get_webfinger(); - $url = \str_replace( '{uri}', $resource, $template ); - - return \rest_ensure_response( - array( - 'url' => $url, - 'template' => $template, - ) - ); - } - - /** - * Retrieves the actor schema, conforming to JSON Schema. - * - * @return array Item schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $this->schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'actor', - 'type' => 'object', - 'properties' => array( - '@context' => array( - 'description' => 'The JSON-LD context for the response.', - 'type' => array( 'array', 'object' ), - 'readonly' => true, - ), - 'id' => array( - 'description' => 'The unique identifier for the actor.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'type' => array( - 'description' => 'The type of the actor.', - 'type' => 'string', - 'enum' => array( 'Person', 'Service', 'Organization', 'Application', 'Group' ), - 'readonly' => true, - ), - 'attachment' => array( - 'description' => 'Additional information attached to the actor.', - 'type' => 'array', - 'items' => array( - 'type' => 'object', - 'properties' => array( - 'type' => array( - 'type' => 'string', - 'enum' => array( 'PropertyValue', 'Link' ), - ), - 'name' => array( - 'type' => 'string', - ), - 'value' => array( - 'type' => 'string', - ), - 'href' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'rel' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'string', - ), - ), - ), - ), - 'readonly' => true, - ), - 'name' => array( - 'description' => 'The display name of the actor.', - 'type' => 'string', - 'readonly' => true, - ), - 'icon' => array( - 'description' => 'The icon/avatar of the actor.', - 'type' => 'object', - 'properties' => array( - 'type' => array( - 'type' => 'string', - ), - 'url' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - 'readonly' => true, - ), - 'published' => array( - 'description' => 'The date the actor was published.', - 'type' => 'string', - 'format' => 'date-time', - 'readonly' => true, - ), - 'summary' => array( - 'description' => 'A summary about the actor.', - 'type' => 'string', - 'readonly' => true, - ), - 'tag' => array( - 'description' => 'Tags associated with the actor.', - 'type' => 'array', - 'items' => array( - 'type' => 'object', - 'properties' => array( - 'type' => array( - 'type' => 'string', - ), - 'href' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'name' => array( - 'type' => 'string', - ), - ), - ), - 'readonly' => true, - ), - 'url' => array( - 'description' => 'The URL to the actor\'s profile page.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'inbox' => array( - 'description' => 'The inbox endpoint for the actor.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'outbox' => array( - 'description' => 'The outbox endpoint for the actor.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'following' => array( - 'description' => 'The following endpoint for the actor.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'followers' => array( - 'description' => 'The followers endpoint for the actor.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'streams' => array( - 'description' => 'The streams associated with the actor.', - 'type' => 'array', - 'readonly' => true, - ), - 'preferredUsername' => array( - 'description' => 'The preferred username of the actor.', - 'type' => 'string', - 'readonly' => true, - ), - 'publicKey' => array( - 'description' => 'The public key information for the actor.', - 'type' => 'object', - 'properties' => array( - 'id' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'owner' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'publicKeyPem' => array( - 'type' => 'string', - ), - ), - 'readonly' => true, - ), - 'manuallyApprovesFollowers' => array( - 'description' => 'Whether the actor manually approves followers.', - 'type' => 'boolean', - 'readonly' => true, - ), - 'attributionDomains' => array( - 'description' => 'The attribution domains for the actor.', - 'type' => 'array', - 'items' => array( - 'type' => 'string', - ), - 'readonly' => true, - ), - 'featured' => array( - 'description' => 'The featured collection endpoint for the actor.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ), - 'indexable' => array( - 'description' => 'Whether the actor is indexable.', - 'type' => 'boolean', - 'readonly' => true, - ), - 'webfinger' => array( - 'description' => 'The webfinger identifier for the actor.', - 'type' => 'string', - 'readonly' => true, - ), - 'discoverable' => array( - 'description' => 'Whether the actor is discoverable.', - 'type' => 'boolean', - 'readonly' => true, - ), - ), - ); - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-actors-inbox-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-actors-inbox-controller.php deleted file mode 100644 index 99fb5b9a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-actors-inbox-controller.php +++ /dev/null @@ -1,238 +0,0 @@ -namespace, - '/' . $this->rest_base . '/inbox', - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The ID or username of the actor.', - 'type' => 'string', - 'required' => true, - 'pattern' => '[\w\-\.]+', - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'page' => array( - 'description' => 'Current page of the collection.', - 'type' => 'integer', - 'minimum' => 1, - // No default so we can differentiate between Collection and CollectionPage requests. - ), - 'per_page' => array( - 'description' => 'Maximum number of items to be returned in result set.', - 'type' => 'integer', - 'default' => 20, - 'minimum' => 1, - ), - ), - 'schema' => array( $this, 'get_collection_schema' ), - ), - array( - 'methods' => \WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'create_item' ), - 'permission_callback' => array( 'Activitypub\Rest\Server', 'verify_signature' ), - 'args' => array( - 'id' => array( - 'description' => 'The unique identifier for the activity.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'actor' => array( - 'description' => 'The actor performing the activity.', - 'type' => 'string', - 'required' => true, - 'sanitize_callback' => '\Activitypub\object_to_uri', - ), - 'type' => array( - 'description' => 'The type of the activity.', - 'type' => 'string', - 'required' => true, - ), - 'object' => array( - 'description' => 'The object of the activity.', - 'required' => true, - 'validate_callback' => function ( $param, $request, $key ) { - /** - * Filter the ActivityPub object validation. - * - * @param bool $validate The validation result. - * @param array $param The object data. - * @param object $request The request object. - * @param string $key The key. - */ - return \apply_filters( 'activitypub_validate_object', true, $param, $request, $key ); - }, - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Renders the user-inbox. - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response|\WP_Error Response object or WP_Error. - */ - public function get_items( $request ) { - $user_id = $request->get_param( 'user_id' ); - $user = Actors::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - /** - * Fires before the ActivityPub inbox is created and sent to the client. - */ - \do_action( 'activitypub_rest_inbox_pre' ); - - $response = array( - '@context' => get_context(), - 'id' => get_rest_url_by_path( \sprintf( 'actors/%d/inbox', $user->get__id() ) ), - 'generator' => 'https://wordpress.org/?v=' . get_masked_wp_version(), - 'type' => 'OrderedCollection', - 'totalItems' => 0, - 'orderedItems' => array(), - ); - - /** - * Filters the ActivityPub inbox data before it is sent to the client. - * - * @param array $response The ActivityPub inbox array. - */ - $response = \apply_filters( 'activitypub_rest_inbox_array', $response ); - - $response = $this->prepare_collection_response( $response, $request ); - if ( \is_wp_error( $response ) ) { - return $response; - } - - /** - * Fires after the ActivityPub inbox has been created and sent to the client. - */ - \do_action( 'activitypub_inbox_post' ); - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Handles user-inbox requests. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response|\WP_Error Response object or WP_Error. - */ - public function create_item( $request ) { - $user_id = $request->get_param( 'user_id' ); - $user = Actors::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - $data = $request->get_json_params(); - $activity = Activity::init_from_array( $data ); - $type = $request->get_param( 'type' ); - $type = \strtolower( $type ); - - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput - if ( \wp_check_comment_disallowed_list( $activity->to_json( false ), '', '', '', $_SERVER['REMOTE_ADDR'], $_SERVER['HTTP_USER_AGENT'] ?? '' ) ) { - Debug::write_log( 'Blocked activity from: ' . $activity->get_actor() ); - } else { - /** - * ActivityPub inbox action. - * - * @param array $data The data array. - * @param int|null $user_id The user ID. - * @param string $type The type of the activity. - * @param Activity|\WP_Error $activity The Activity object. - */ - \do_action( 'activitypub_inbox', $data, $user->get__id(), $type, $activity ); - - /** - * ActivityPub inbox action for specific activity types. - * - * @param array $data The data array. - * @param int|null $user_id The user ID. - * @param Activity|\WP_Error $activity The Activity object. - */ - \do_action( 'activitypub_inbox_' . $type, $data, $user->get__id(), $activity ); - } - - $response = \rest_ensure_response( array() ); - $response->set_status( 202 ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Retrieves the schema for the inbox collection, conforming to JSON Schema. - * - * @return array Collection schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $item_schema = array( - 'type' => 'object', - ); - - $schema = $this->get_collection_schema( $item_schema ); - - // Add inbox-specific properties. - $schema['title'] = 'inbox'; - $schema['properties']['generator'] = array( - 'description' => 'The software used to generate the collection.', - 'type' => 'string', - 'format' => 'uri', - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-application-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-application-controller.php deleted file mode 100644 index ad3c1b80..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-application-controller.php +++ /dev/null @@ -1,168 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_item' ), - 'permission_callback' => '__return_true', - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Retrieves the application actor profile. - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response Response object. - */ - public function get_item( $request ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $json = ( new Application() )->to_array(); - - $rest_response = new \WP_REST_Response( $json, 200 ); - $rest_response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $rest_response; - } - - /** - * Retrieves the schema for the application endpoint. - * - * @return array Schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $this->schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'application', - 'type' => 'object', - 'properties' => array( - '@context' => array( - 'type' => 'array', - 'items' => array( - 'type' => array( 'string', 'object' ), - ), - ), - 'id' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'type' => array( - 'type' => 'string', - 'enum' => array( 'Application' ), - ), - 'name' => array( - 'type' => 'string', - ), - 'icon' => array( - 'type' => 'object', - 'properties' => array( - 'type' => array( - 'type' => 'string', - ), - 'url' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - ), - 'published' => array( - 'type' => 'string', - 'format' => 'date-time', - ), - 'summary' => array( - 'type' => 'string', - ), - 'url' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'inbox' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'outbox' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'streams' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'string', - ), - ), - 'preferredUsername' => array( - 'type' => 'string', - ), - 'publicKey' => array( - 'type' => 'object', - 'properties' => array( - 'id' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'owner' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'publicKeyPem' => array( - 'type' => 'string', - ), - ), - ), - 'manuallyApprovesFollowers' => array( - 'type' => 'boolean', - ), - 'discoverable' => array( - 'type' => 'boolean', - ), - 'indexable' => array( - 'type' => 'boolean', - ), - 'webfinger' => array( - 'type' => 'string', - ), - ), - ); - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-collections-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-collections-controller.php deleted file mode 100644 index 199feabd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-collections-controller.php +++ /dev/null @@ -1,272 +0,0 @@ -namespace, - '/' . $this->rest_base . '/collections/(?P[\w\-\.]+)', - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The user ID or username.', - 'type' => 'string', - 'required' => true, - ), - 'type' => array( - 'description' => 'The type of collection to query.', - 'type' => 'string', - 'enum' => array( 'tags', 'featured' ), - 'required' => true, - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'page' => array( - 'description' => 'Current page of the collection.', - 'type' => 'integer', - 'minimum' => 1, - // No default so we can differentiate between Collection and CollectionPage requests. - ), - 'per_page' => array( - 'description' => 'Maximum number of items to be returned in result set.', - 'type' => 'integer', - 'default' => 20, - 'minimum' => 1, - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Retrieves a collection of featured tags. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response|\WP_Error Response object or WP_Error object. - */ - public function get_items( $request ) { - $user_id = $request->get_param( 'user_id' ); - $user = Actors::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - switch ( $request->get_param( 'type' ) ) { - case 'tags': - $response = $this->get_tags( $request, $user ); - break; - - case 'featured': - $response = $this->get_featured( $request, $user ); - break; - - default: - $response = new \WP_Error( 'rest_unknown_collection_type', 'Unknown collection type.', array( 'status' => 404 ) ); - } - - if ( \is_wp_error( $response ) ) { - return $response; - } - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Retrieves a collection of featured tags. - * - * @param \WP_REST_Request $request The request object. - * @param User|Blog|Application $user Actor. - * - * @return array Collection of featured tags. - */ - public function get_tags( $request, $user ) { - $tags = \get_terms( - array( - 'taxonomy' => 'post_tag', - 'orderby' => 'count', - 'order' => 'DESC', - 'number' => 4, - ) - ); - - if ( \is_wp_error( $tags ) ) { - $tags = array(); - } - - $response = array( - '@context' => Base_Object::JSON_LD_CONTEXT, - 'id' => get_rest_url_by_path( sprintf( 'actors/%d/collections/tags', $user->get__id() ) ), - 'type' => 'Collection', - 'totalItems' => \is_countable( $tags ) ? \count( $tags ) : 0, - 'items' => array(), - ); - - foreach ( $tags as $tag ) { - $response['items'][] = array( - 'type' => 'Hashtag', - 'href' => \esc_url( \get_tag_link( $tag ) ), - 'name' => esc_hashtag( $tag->name ), - ); - } - - return $this->prepare_collection_response( $response, $request ); - } - - /** - * Retrieves a collection of featured posts. - * - * @param \WP_REST_Request $request The request object. - * @param User|Blog|Application $user Actor. - * - * @return array Collection of featured posts. - */ - public function get_featured( $request, $user ) { - $posts = array(); - - if ( is_single_user() || Actors::BLOG_USER_ID !== $user->get__id() ) { - $sticky_posts = \get_option( 'sticky_posts' ); - - if ( $sticky_posts && is_array( $sticky_posts ) ) { - // Only show public posts. - $args = array( - 'post__in' => $sticky_posts, - 'ignore_sticky_posts' => 1, - 'orderby' => 'date', - 'order' => 'DESC', - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => 'activitypub_content_visibility', - 'compare' => 'NOT EXISTS', - ), - ), - ); - - if ( $user->get__id() > 0 ) { - $args['author'] = $user->get__id(); - } - - $posts = \get_posts( $args ); - } - } - - $response = array( - '@context' => Base_Object::JSON_LD_CONTEXT, - 'id' => get_rest_url_by_path( sprintf( 'actors/%d/collections/featured', $request->get_param( 'user_id' ) ) ), - 'type' => 'OrderedCollection', - 'totalItems' => \is_countable( $posts ) ? \count( $posts ) : 0, - 'orderedItems' => array(), - ); - - foreach ( $posts as $post ) { - $transformer = Factory::get_transformer( $post ); - - if ( \is_wp_error( $transformer ) ) { - continue; - } - - $response['orderedItems'][] = $transformer->to_object()->to_array( false ); - } - - return $this->prepare_collection_response( $response, $request ); - } - - /** - * Retrieves the schema for the Collections endpoint. - * - * @return array Schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $schema = $this->get_collection_schema(); - - // Add collections-specific properties. - $schema['title'] = 'featured'; - $schema['properties']['generator'] = array( - 'description' => 'The software used to generate the collection.', - 'type' => 'string', - 'format' => 'uri', - ); - $schema['properties']['oneOf'] = array( - 'orderedItems' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'object', - ), - ), - 'items' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'object', - 'properties' => array( - 'type' => array( - 'type' => 'string', - 'enum' => array( 'Hashtag' ), - 'required' => true, - ), - 'href' => array( - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'name' => array( - 'type' => 'string', - 'required' => true, - ), - ), - ), - ), - ); - - unset( $schema['properties']['orderedItems'] ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-comments-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-comments-controller.php deleted file mode 100644 index adcfcfd5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-comments-controller.php +++ /dev/null @@ -1,156 +0,0 @@ -\d+)'; - - /** - * Register routes. - */ - public function register_routes() { - \register_rest_route( - $this->namespace, - '/' . $this->rest_base . '/remote-reply', - array( - 'args' => array( - 'comment_id' => array( - 'description' => 'The ID of the comment.', - 'type' => 'integer', - 'required' => true, - 'validate_callback' => array( $this, 'validate_comment' ), - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_item' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'resource' => array( - 'description' => 'The resource to reply to.', - 'type' => 'string', - 'required' => true, - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Validates if a comment can be replied to remotely. - * - * @param mixed $param The parameter to validate. - * - * @return true|\WP_Error True if the comment can be replied to, WP_Error otherwise. - */ - public function validate_comment( $param ) { - $comment = \get_comment( $param ); - - if ( ! $comment ) { - return new \WP_Error( 'activitypub_comment_not_found', \__( 'Comment not found', 'activitypub' ), array( 'status' => 404 ) ); - } - - $is_local = Comment::is_local( $comment ); - - if ( $is_local ) { - return new \WP_Error( 'activitypub_local_only_comment', \__( 'Comment is local only', 'activitypub' ), array( 'status' => 403 ) ); - } - - return true; - } - - /** - * Retrieves the remote reply URL for a comment. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response|\WP_Error Response object or WP_Error object. - */ - public function get_item( $request ) { - $resource = $request->get_param( 'resource' ); - $comment_id = $request->get_param( 'comment_id' ); - - $template = Webfinger::get_remote_follow_endpoint( $resource ); - - if ( \is_wp_error( $template ) ) { - return $template; - } - - $resource = Comment::get_source_id( $comment_id ); - - if ( ! $resource ) { - $resource = Comment::generate_id( \get_comment( $comment_id ) ); - } - - $url = \str_replace( '{uri}', $resource, $template ); - - return \rest_ensure_response( - array( - 'url' => $url, - 'template' => $template, - ) - ); - } - - /** - * Retrieves the schema for the remote reply endpoint. - * - * @return array Schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $this->schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'remote-reply', - 'type' => 'object', - 'properties' => array( - 'url' => array( - 'description' => 'The URL to the remote reply page.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'template' => array( - 'description' => 'The template URL for remote replies.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - ), - ); - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-followers-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-followers-controller.php deleted file mode 100644 index 1f09ad45..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-followers-controller.php +++ /dev/null @@ -1,226 +0,0 @@ -namespace, - '/' . $this->rest_base . '/followers', - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The ID or username of the actor.', - 'type' => 'string', - 'required' => true, - 'pattern' => '[\w\-\.]+', - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => array( 'Activitypub\Rest\Server', 'verify_signature' ), - 'args' => array( - 'page' => array( - 'description' => 'Current page of the collection.', - 'type' => 'integer', - 'minimum' => 1, - // No default so we can differentiate between Collection and CollectionPage requests. - ), - 'per_page' => array( - 'description' => 'Maximum number of items to be returned in result set.', - 'type' => 'integer', - 'default' => 20, - 'minimum' => 1, - ), - 'order' => array( - 'description' => 'Order sort attribute ascending or descending.', - 'type' => 'string', - 'default' => 'desc', - 'enum' => array( 'asc', 'desc' ), - ), - 'context' => array( - 'description' => 'The context in which the request is made.', - 'type' => 'string', - 'default' => 'simple', - 'enum' => array( 'simple', 'full' ), - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Retrieves followers list. - * - * @param \WP_REST_Request $request Full details about the request. - * @return \WP_REST_Response|\WP_Error Response object on success, or WP_Error object on failure. - */ - public function get_items( $request ) { - $user_id = $request->get_param( 'user_id' ); - $user = Actors::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - /** - * Action triggered prior to the ActivityPub profile being created and sent to the client. - */ - \do_action( 'activitypub_rest_followers_pre' ); - - $order = $request->get_param( 'order' ); - $per_page = $request->get_param( 'per_page' ); - $page = $request->get_param( 'page' ) ?? 1; - $context = $request->get_param( 'context' ); - - $data = Followers::get_followers_with_count( $user_id, $per_page, $page, array( 'order' => \ucwords( $order ) ) ); - - $response = array( - '@context' => get_context(), - 'id' => get_rest_url_by_path( \sprintf( 'actors/%d/followers', $user->get__id() ) ), - 'generator' => 'https://wordpress.org/?v=' . get_masked_wp_version(), - 'actor' => $user->get_id(), - 'type' => 'OrderedCollection', - 'totalItems' => $data['total'], - 'orderedItems' => array_map( - function ( $item ) use ( $context ) { - if ( 'full' === $context ) { - return $item->to_array( false ); - } - return $item->get_id(); - }, - $data['followers'] - ), - ); - - $response = $this->prepare_collection_response( $response, $request ); - if ( is_wp_error( $response ) ) { - return $response; - } - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Retrieves the followers schema, conforming to JSON Schema. - * - * @return array Item schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - // Define the schema for items in the followers collection. - $item_schema = array( - 'oneOf' => array( - array( - 'type' => 'string', - 'format' => 'uri', - ), - array( - 'type' => 'object', - 'properties' => array( - 'id' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'type' => array( - 'type' => 'string', - ), - 'name' => array( - 'type' => 'string', - ), - 'icon' => array( - 'type' => 'object', - 'properties' => array( - 'type' => array( - 'type' => 'string', - ), - 'mediaType' => array( - 'type' => 'string', - ), - 'url' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - ), - 'published' => array( - 'type' => 'string', - 'format' => 'date-time', - ), - 'summary' => array( - 'type' => 'string', - ), - 'updated' => array( - 'type' => 'string', - 'format' => 'date-time', - ), - 'url' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'streams' => array( - 'type' => 'array', - ), - 'preferredUsername' => array( - 'type' => 'string', - ), - ), - ), - ), - ); - - $schema = $this->get_collection_schema( $item_schema ); - - // Add followers-specific properties. - $schema['title'] = 'followers'; - $schema['properties']['actor'] = array( - 'description' => 'The actor who owns the followers collection.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ); - $schema['properties']['generator'] = array( - 'description' => 'The generator of the followers collection.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-following-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-following-controller.php deleted file mode 100644 index 19c9aede..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-following-controller.php +++ /dev/null @@ -1,183 +0,0 @@ -namespace, - '/' . $this->rest_base . '/following', - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The ID or username of the actor.', - 'type' => 'string', - 'required' => true, - 'pattern' => '[\w\-\.]+', - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => array( 'Activitypub\Rest\Server', 'verify_signature' ), - 'args' => array( - 'page' => array( - 'description' => 'Current page of the collection.', - 'type' => 'integer', - 'minimum' => 1, - // No default so we can differentiate between Collection and CollectionPage requests. - ), - 'per_page' => array( - 'description' => 'Maximum number of items to be returned in result set.', - 'type' => 'integer', - 'default' => 10, - 'minimum' => 1, - 'maximum' => 100, - ), - ), - ), - 'schema' => array( $this, 'get_public_item_schema' ), - ) - ); - } - - /** - * Retrieves following list. - * - * @param \WP_REST_Request $request Full details about the request. - * @return \WP_REST_Response|\WP_Error Response object on success, or WP_Error object on failure. - */ - public function get_items( $request ) { - $user_id = $request->get_param( 'user_id' ); - $user = Actors::get_by_various( $user_id ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - /** - * Action triggered prior to the ActivityPub profile being created and sent to the client. - */ - \do_action( 'activitypub_rest_following_pre' ); - - $response = array( - '@context' => get_context(), - 'id' => get_rest_url_by_path( \sprintf( 'actors/%d/following', $user->get__id() ) ), - 'generator' => 'https://wordpress.org/?v=' . get_masked_wp_version(), - 'actor' => $user->get_id(), - 'type' => 'OrderedCollection', - ); - - /** - * Filter the list of following urls. - * - * @param array $items The array of following urls. - * @param \Activitypub\Model\User $user The user object. - */ - $items = \apply_filters( 'activitypub_rest_following', array(), $user ); - - $response['totalItems'] = \is_countable( $items ) ? \count( $items ) : 0; - $response['orderedItems'] = $items; - - $response = $this->prepare_collection_response( $response, $request ); - if ( is_wp_error( $response ) ) { - return $response; - } - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Add the Blog Authors to the following list of the Blog Actor - * if Blog not in single mode. - * - * @param array $follow_list The array of following urls. - * @param \Activitypub\Model\User $user The user object. - * - * @return array The array of following urls. - */ - public static function default_following( $follow_list, $user ) { - if ( 0 !== $user->get__id() || is_single_user() ) { - return $follow_list; - } - - $users = Actors::get_collection(); - - foreach ( $users as $user ) { - $follow_list[] = $user->get_id(); - } - - return $follow_list; - } - - /** - * Retrieves the following schema, conforming to JSON Schema. - * - * @return array Item schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $item_schema = array( - 'type' => 'string', - 'format' => 'uri', - ); - - $schema = $this->get_collection_schema( $item_schema ); - - // Add following-specific properties. - $schema['title'] = 'following'; - $schema['properties']['actor'] = array( - 'description' => 'The actor who owns the following collection.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ); - $schema['properties']['generator'] = array( - 'description' => 'The generator of the following collection.', - 'type' => 'string', - 'format' => 'uri', - 'readonly' => true, - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-inbox-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-inbox-controller.php deleted file mode 100644 index 4fdd2a62..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-inbox-controller.php +++ /dev/null @@ -1,255 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'create_item' ), - 'permission_callback' => array( 'Activitypub\Rest\Server', 'verify_signature' ), - 'args' => array( - 'id' => array( - 'description' => 'The unique identifier for the activity.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'actor' => array( - 'description' => 'The actor performing the activity.', - 'type' => 'string', - 'required' => true, - 'sanitize_callback' => '\Activitypub\object_to_uri', - ), - 'type' => array( - 'description' => 'The type of the activity.', - 'type' => 'string', - 'required' => true, - ), - 'object' => array( - 'description' => 'The object of the activity.', - 'required' => true, - 'validate_callback' => function ( $param, $request, $key ) { - /** - * Filter the ActivityPub object validation. - * - * @param bool $validate The validation result. - * @param array $param The object data. - * @param object $request The request object. - * @param string $key The key. - */ - return \apply_filters( 'activitypub_validate_object', true, $param, $request, $key ); - }, - ), - 'to' => array( - 'description' => 'The primary recipients of the activity.', - 'type' => array( 'string', 'array' ), - 'required' => false, - 'sanitize_callback' => function ( $param ) { - if ( \is_string( $param ) ) { - $param = array( $param ); - } - - return $param; - }, - ), - 'cc' => array( - 'description' => 'The secondary recipients of the activity.', - 'type' => array( 'string', 'array' ), - 'sanitize_callback' => function ( $param ) { - if ( \is_string( $param ) ) { - $param = array( $param ); - } - - return $param; - }, - ), - 'bcc' => array( - 'description' => 'The private recipients of the activity.', - 'type' => array( 'string', 'array' ), - 'sanitize_callback' => function ( $param ) { - if ( \is_string( $param ) ) { - $param = array( $param ); - } - - return $param; - }, - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * The shared inbox. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response|\WP_Error Response object or WP_Error. - */ - public function create_item( $request ) { - $data = $request->get_json_params(); - $activity = Activity::init_from_array( $data ); - $type = \strtolower( $request->get_param( 'type' ) ); - - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput - if ( \wp_check_comment_disallowed_list( $activity->to_json( false ), '', '', '', $_SERVER['REMOTE_ADDR'], $_SERVER['HTTP_USER_AGENT'] ?? '' ) ) { - Debug::write_log( 'Blocked activity from: ' . $activity->get_actor() ); - } else { - $recipients = extract_recipients_from_activity( $data ); - - foreach ( $recipients as $recipient ) { - if ( ! is_same_domain( $recipient ) ) { - continue; - } - - $actor = Actors::get_by_various( $recipient ); - - if ( ! $actor || \is_wp_error( $actor ) ) { - continue; - } - - /** - * ActivityPub inbox action. - * - * @param array $data The data array. - * @param int $user_id The user ID. - * @param string $type The type of the activity. - * @param Activity|\WP_Error $activity The Activity object. - */ - \do_action( 'activitypub_inbox', $data, $actor->get__id(), $type, $activity ); - - /** - * ActivityPub inbox action for specific activity types. - * - * @param array $data The data array. - * @param int $user_id The user ID. - * @param Activity|\WP_Error $activity The Activity object. - */ - \do_action( 'activitypub_inbox_' . $type, $data, $actor->get__id(), $activity ); - } - } - - $response = \rest_ensure_response( array() ); - $response->set_status( 202 ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Retrieves the schema for a single inbox item, conforming to JSON Schema. - * - * @return array Item schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $schema = array( - '$schema' => 'https://json-schema.org/draft-04/schema#', - 'title' => 'activity', - 'type' => 'object', - 'properties' => array( - '@context' => array( - 'description' => 'The JSON-LD context for the activity.', - 'type' => array( 'string', 'array', 'object' ), - 'required' => true, - ), - 'id' => array( - 'description' => 'The unique identifier for the activity.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'type' => array( - 'description' => 'The type of the activity.', - 'type' => 'string', - 'required' => true, - ), - 'actor' => array( - 'description' => 'The actor performing the activity.', - 'type' => array( 'string', 'object' ), - 'format' => 'uri', - 'required' => true, - ), - 'object' => array( - 'description' => 'The object of the activity.', - 'type' => array( 'string', 'object' ), - 'required' => true, - ), - 'to' => array( - 'description' => 'The primary recipients of the activity.', - 'type' => 'array', - 'items' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - 'cc' => array( - 'description' => 'The secondary recipients of the activity.', - 'type' => 'array', - 'items' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - 'bcc' => array( - 'description' => 'The private recipients of the activity.', - 'type' => 'array', - 'items' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - ), - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-interaction-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-interaction-controller.php deleted file mode 100644 index f4ba270a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-interaction-controller.php +++ /dev/null @@ -1,139 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_item' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'uri' => array( - 'description' => 'The URI of the object to interact with.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - ), - ), - ) - ); - } - - /** - * Retrieves the interaction URL for a given URI. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response Response object on success, dies on failure. - */ - public function get_item( $request ) { - $uri = $request->get_param( 'uri' ); - $redirect_url = ''; - $object = Http::get_remote_object( $uri ); - - if ( \is_wp_error( $object ) || ! isset( $object['type'] ) ) { - // Use wp_die as this can be called from the front-end. See https://github.com/Automattic/wordpress-activitypub/pull/1149/files#r1915297109. - \wp_die( - esc_html__( 'The URL is not supported!', 'activitypub' ), - '', - array( - 'response' => 400, - 'back_link' => true, - ) - ); - } - - if ( ! empty( $object['url'] ) ) { - $uri = \esc_url( $object['url'] ); - } - - switch ( $object['type'] ) { - case 'Group': - case 'Person': - case 'Service': - case 'Application': - case 'Organization': - /** - * Filters the URL used for following an ActivityPub actor. - * - * @param string $redirect_url The URL to redirect to. - * @param string $uri The URI of the actor to follow. - * @param array $object The full actor object data. - */ - $redirect_url = \apply_filters( 'activitypub_interactions_follow_url', $redirect_url, $uri, $object ); - break; - default: - $redirect_url = \admin_url( 'post-new.php?in_reply_to=' . $uri ); - /** - * Filters the URL used for replying to an ActivityPub object. - * - * By default, this redirects to the WordPress post editor with the in_reply_to parameter set. - * - * @param string $redirect_url The URL to redirect to. - * @param string $uri The URI of the object to reply to. - * @param array $object The full object data being replied to. - */ - $redirect_url = \apply_filters( 'activitypub_interactions_reply_url', $redirect_url, $uri, $object ); - } - - /** - * Filters the redirect URL. - * - * This filter runs after the type-specific filters and allows for final modifications - * to the interaction URL regardless of the object type. - * - * @param string $redirect_url The URL to redirect to. - * @param string $uri The URI of the object. - * @param array $object The object being interacted with. - */ - $redirect_url = \apply_filters( 'activitypub_interactions_url', $redirect_url, $uri, $object ); - - // Check if hook is implemented. - if ( ! $redirect_url ) { - // Use wp_die as this can be called from the front-end. See https://github.com/Automattic/wordpress-activitypub/pull/1149/files#r1915297109. - \wp_die( - esc_html__( 'This Interaction type is not supported yet!', 'activitypub' ), - '', - array( - 'response' => 400, - 'back_link' => true, - ) - ); - } - - return new \WP_REST_Response( null, 302, array( 'Location' => \esc_url( $redirect_url ) ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-moderators-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-moderators-controller.php deleted file mode 100644 index eba84725..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-moderators-controller.php +++ /dev/null @@ -1,132 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => '__return_true', - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Retrieves a collection of moderators. - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response|\WP_Error Response object or WP_Error object. - */ - public function get_items( $request ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $actors = array(); - - foreach ( Actors::get_collection() as $user ) { - $actors[] = $user->get_id(); - } - - /** - * Filter the list of moderators. - * - * @param array $actors The list of moderators. - */ - $actors = apply_filters( 'activitypub_rest_moderators', $actors ); - - $response = array( - '@context' => get_context(), - 'id' => get_rest_url_by_path( 'collections/moderators' ), - 'type' => 'OrderedCollection', - 'orderedItems' => $actors, - ); - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Retrieves the schema for the Moderators endpoint. - * - * @return array Schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'moderators', - 'type' => 'object', - 'properties' => array( - '@context' => array( - 'type' => 'array', - 'items' => array( - 'type' => array( 'string', 'object' ), - ), - 'required' => true, - ), - 'id' => array( - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'type' => array( - 'type' => 'string', - 'enum' => array( 'OrderedCollection' ), - 'required' => true, - ), - 'orderedItems' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'required' => true, - ), - ), - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-nodeinfo-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-nodeinfo-controller.php deleted file mode 100644 index 4bd19e04..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-nodeinfo-controller.php +++ /dev/null @@ -1,172 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => '__return_true', - ), - ) - ); - - \register_rest_route( - $this->namespace, - '/' . $this->rest_base . '/(?P\d\.\d)', - array( - 'args' => array( - 'version' => array( - 'description' => 'The version of the NodeInfo schema.', - 'type' => 'string', - 'required' => true, - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_item' ), - 'permission_callback' => '__return_true', - ), - ) - ); - } - - /** - * Retrieves the NodeInfo discovery profile. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response Response object. - */ - public function get_items( $request ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $response = array( - 'links' => array( - - /* - * Needs http protocol for spec compliance. - * @ticket https://github.com/Automattic/wordpress-activitypub/pull/1275 - */ - array( - 'rel' => 'http://nodeinfo.diaspora.software/ns/schema/2.0', - 'href' => get_rest_url_by_path( '/nodeinfo/2.0' ), - ), - array( - 'rel' => 'https://nodeinfo.diaspora.software/ns/schema/2.0', - 'href' => get_rest_url_by_path( '/nodeinfo/2.0' ), - ), - array( - 'rel' => 'https://www.w3.org/ns/activitystreams#Application', - 'href' => get_rest_url_by_path( 'application' ), - ), - ), - ); - - return \rest_ensure_response( $response ); - } - - /** - * Retrieves the NodeInfo profile. - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response Response object. - */ - public function get_item( $request ) { - $version = $request->get_param( 'version' ); - - /** - * Fires before the NodeInfo data is created and sent to the client. - * - * @param string $version The NodeInfo version. - */ - \do_action( 'activitypub_rest_nodeinfo_pre', $version ); - - switch ( $version ) { - case '2.0': - $response = $this->get_version_2_0(); - break; - - default: - $response = new \WP_Error( 'activitypub_rest_nodeinfo_invalid_version', 'Unsupported NodeInfo version.', array( 'status' => 405 ) ); - break; - } - - return \rest_ensure_response( $response ); - } - - /** - * Get the NodeInfo 2.0 data. - * - * @return array - */ - public function get_version_2_0() { - $posts = \wp_count_posts(); - $comments = \wp_count_comments(); - - return array( - 'version' => '2.0', - 'software' => array( - 'name' => 'wordpress', - 'version' => get_masked_wp_version(), - ), - 'protocols' => array( 'activitypub' ), - 'services' => array( - 'inbound' => array(), - 'outbound' => array(), - ), - 'openRegistrations' => (bool) get_option( 'users_can_register' ), - 'usage' => array( - 'users' => array( - 'total' => get_total_users(), - 'activeHalfyear' => get_active_users( 6 ), - 'activeMonth' => get_active_users(), - ), - 'localPosts' => $posts->publish, - 'localComments' => $comments->approved, - ), - 'metadata' => array( - 'nodeName' => \get_bloginfo( 'name' ), - 'nodeDescription' => \get_bloginfo( 'description' ), - 'nodeIcon' => \get_site_icon_url(), - ), - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-outbox-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-outbox-controller.php deleted file mode 100644 index 001eefdd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-outbox-controller.php +++ /dev/null @@ -1,257 +0,0 @@ -[\w\-\.]+)/outbox'; - - /** - * Register routes. - */ - public function register_routes() { - \register_rest_route( - $this->namespace, - '/' . $this->rest_base, - array( - 'args' => array( - 'user_id' => array( - 'description' => 'The ID of the user or actor.', - 'type' => 'string', - 'validate_callback' => array( $this, 'validate_user_id' ), - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => array( 'Activitypub\Rest\Server', 'verify_signature' ), - 'args' => array( - 'page' => array( - 'description' => 'Current page of the collection.', - 'type' => 'integer', - 'minimum' => 1, - // No default so we can differentiate between Collection and CollectionPage requests. - ), - 'per_page' => array( - 'description' => 'Maximum number of items to be returned in result set.', - 'type' => 'integer', - 'default' => 20, - 'minimum' => 1, - 'maximum' => 100, - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Validates the user_id parameter. - * - * @param mixed $user_id The user_id parameter. - * @return bool|\WP_Error True if the user_id is valid, WP_Error otherwise. - */ - public function validate_user_id( $user_id ) { - $user = Actors::get_by_various( $user_id ); - if ( \is_wp_error( $user ) ) { - return $user; - } - - return true; - } - - /** - * Retrieves a collection of outbox items. - * - * @param \WP_REST_Request $request Full details about the request. - * @return \WP_REST_Response|\WP_Error Response object on success, or WP_Error object on failure. - */ - public function get_items( $request ) { - $page = $request->get_param( 'page' ) ?? 1; - $user = Actors::get_by_various( $request->get_param( 'user_id' ) ); - $user_id = $user->get__id(); - - /** - * Action triggered prior to the ActivityPub profile being created and sent to the client. - * - * @param \WP_REST_Request $request The request object. - */ - \do_action( 'activitypub_rest_outbox_pre', $request ); - - /** - * Filters the list of activity types to include in the outbox. - * - * @param string[] $activity_types The list of activity types. - */ - $activity_types = apply_filters( 'rest_activitypub_outbox_activity_types', array( 'Announce', 'Create', 'Like', 'Update' ) ); - - $args = array( - 'posts_per_page' => $request->get_param( 'per_page' ), - 'author' => $user_id > 0 ? $user_id : null, - 'paged' => $page, - 'post_type' => Outbox::POST_TYPE, - 'post_status' => 'any', - - // phpcs:ignore WordPress.DB.SlowDBQuery.slow_db_query_meta_query - 'meta_query' => array( - array( - 'key' => '_activitypub_activity_actor', - 'value' => Actors::get_type_by_id( $user_id ), - ), - ), - ); - - if ( get_current_user_id() !== $user_id && ! current_user_can( 'activitypub' ) ) { - $args['meta_query'][] = array( - 'key' => '_activitypub_activity_type', - 'value' => $activity_types, - 'compare' => 'IN', - ); - - $args['meta_query'][] = array( - 'relation' => 'OR', - array( - 'key' => 'activitypub_content_visibility', - 'compare' => 'NOT EXISTS', - ), - array( - 'key' => 'activitypub_content_visibility', - 'value' => ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC, - ), - ); - } - - /** - * Filters WP_Query arguments when querying Outbox items via the REST API. - * - * Enables adding extra arguments or setting defaults for an outbox collection request. - * - * @param array $args Array of arguments for WP_Query. - * @param \WP_REST_Request $request The REST API request. - */ - $args = apply_filters( 'rest_activitypub_outbox_query', $args, $request ); - - $outbox_query = new \WP_Query(); - $query_result = $outbox_query->query( $args ); - - $response = array( - '@context' => Base_Object::JSON_LD_CONTEXT, - 'id' => get_rest_url_by_path( sprintf( 'actors/%d/outbox', $user_id ) ), - 'generator' => 'https://wordpress.org/?v=' . get_masked_wp_version(), - 'actor' => $user->get_id(), - 'type' => 'OrderedCollection', - 'totalItems' => $outbox_query->found_posts, - 'orderedItems' => array(), - ); - - \update_postmeta_cache( \wp_list_pluck( $query_result, 'ID' ) ); - foreach ( $query_result as $outbox_item ) { - $response['orderedItems'][] = $this->prepare_item_for_response( $outbox_item, $request ); - } - - $response = $this->prepare_collection_response( $response, $request ); - if ( is_wp_error( $response ) ) { - return $response; - } - - /** - * Filter the ActivityPub outbox array. - * - * @param array $response The ActivityPub outbox array. - * @param \WP_REST_Request $request The request object. - */ - $response = \apply_filters( 'activitypub_rest_outbox_array', $response, $request ); - - /** - * Action triggered after the ActivityPub profile has been created and sent to the client. - * - * @param \WP_REST_Request $request The request object. - */ - \do_action( 'activitypub_outbox_post', $request ); - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Prepares the item for the REST response. - * - * @param mixed $item WordPress representation of the item. - * @param \WP_REST_Request $request Request object. - * @return array Response object on success, or WP_Error object on failure. - */ - public function prepare_item_for_response( $item, $request ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $activity = Outbox::get_activity( $item->ID ); - - return $activity->to_array( false ); - } - - /** - * Retrieves the outbox schema, conforming to JSON Schema. - * - * @return array Collection schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $item_schema = array( - 'type' => 'object', - ); - - $schema = $this->get_collection_schema( $item_schema ); - - // Add outbox-specific properties. - $schema['title'] = 'outbox'; - $schema['properties']['actor'] = array( - 'description' => 'The actor who owns this outbox.', - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ); - $schema['properties']['generator'] = array( - 'description' => 'The software used to generate the collection.', - 'type' => 'string', - 'format' => 'uri', - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-post.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-post.php deleted file mode 100644 index 182ea69d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-post.php +++ /dev/null @@ -1,160 +0,0 @@ -\d+)/reactions', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( static::class, 'get_reactions' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'id' => array( - 'required' => true, - 'type' => 'integer', - ), - ), - ) - ); - - register_rest_route( - ACTIVITYPUB_REST_NAMESPACE, - '/posts/(?P\d+)/context', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( static::class, 'get_context' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'id' => array( - 'required' => true, - 'type' => 'integer', - ), - ), - ) - ); - } - - /** - * Get reactions for a post. - * - * @param \WP_REST_Request $request The request. - * - * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. - */ - public static function get_reactions( $request ) { - $post_id = $request->get_param( 'id' ); - $post = get_post( $post_id ); - - if ( ! $post ) { - return new WP_Error( 'post_not_found', 'Post not found', array( 'status' => 404 ) ); - } - - $reactions = array(); - - foreach ( Comment::get_comment_types() as $type_object ) { - $comments = get_comments( - array( - 'post_id' => $post_id, - 'type' => $type_object['type'], - 'status' => 'approve', - ) - ); - - if ( empty( $comments ) ) { - continue; - } - - $count = count( $comments ); - // phpcs:disable WordPress.WP.I18n - $label = sprintf( - _n( - $type_object['count_single'], - $type_object['count_plural'], - $count, - 'activitypub' - ), - number_format_i18n( $count ) - ); - // phpcs:enable WordPress.WP.I18n - - $reactions[ $type_object['collection'] ] = array( - 'label' => $label, - 'items' => array_map( - function ( $comment ) { - return array( - 'name' => $comment->comment_author, - 'url' => $comment->comment_author_url, - 'avatar' => get_comment_meta( $comment->comment_ID, 'avatar_url', true ), - ); - }, - $comments - ), - ); - } - - return new WP_REST_Response( $reactions ); - } - - /** - * Get the context for a post. - * - * @param \WP_REST_Request $request The request. - * - * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. - */ - public static function get_context( $request ) { - $post_id = $request->get_param( 'id' ); - - $collection = Replies::get_context_collection( $post_id ); - - if ( false === $collection ) { - return new WP_Error( 'post_not_found', 'Post not found', array( 'status' => 404 ) ); - } - - $response = array_merge( - array( - '@context' => Base_Object::JSON_LD_CONTEXT, - 'id' => get_rest_url_by_path( sprintf( 'posts/%d/context', $post_id ) ), - ), - $collection - ); - - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-replies-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-replies-controller.php deleted file mode 100644 index 27e97920..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-replies-controller.php +++ /dev/null @@ -1,256 +0,0 @@ -[\w\-\.]+)s/(?P[\w\-\.]+)/(?P[\w\-\.]+)'; - - /** - * Register routes. - */ - public function register_routes() { - \register_rest_route( - $this->namespace, - '/' . $this->rest_base, - array( - 'args' => array( - 'object_type' => array( - 'description' => 'The type of object to get replies for.', - 'type' => 'string', - 'enum' => array( 'post', 'comment' ), - 'required' => true, - ), - 'id' => array( - 'description' => 'The ID of the object.', - 'type' => 'string', - 'required' => true, - ), - 'type' => array( - 'description' => 'The type of collection to query.', - 'type' => 'string', - 'enum' => array( 'replies', 'likes', 'shares' ), - 'required' => true, - ), - ), - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'page' => array( - 'description' => 'Current page of the collection.', - 'type' => 'integer', - 'minimum' => 1, - // No default so we can differentiate between Collection and CollectionPage requests. - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Retrieves a collection of replies. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response|\WP_Error Response object or WP_Error object. - */ - public function get_items( $request ) { - $object_type = $request->get_param( 'object_type' ); - $id = (int) $request->get_param( 'id' ); - - if ( 'comment' === $object_type ) { - $wp_object = \get_comment( $id ); - } else { - $wp_object = \get_post( $id ); - } - - if ( ! isset( $wp_object ) || \is_wp_error( $wp_object ) ) { - return new \WP_Error( - 'activitypub_replies_collection_does_not_exist', - \sprintf( - // translators: %s: The type (post, comment, etc.) for which no replies collection exists. - \__( 'No reply collection exists for the type %s.', 'activitypub' ), - $object_type - ), - array( 'status' => 404 ) - ); - } - - switch ( $request->get_param( 'type' ) ) { - case 'replies': - $response = $this->get_replies( $request, $wp_object ); - break; - - case 'likes': - $response = $this->get_likes( $request, $wp_object ); - break; - - case 'shares': - $response = $this->get_shares( $request, $wp_object ); - break; - - default: - $response = new \WP_Error( 'rest_unknown_collection_type', 'Unknown collection type.', array( 'status' => 404 ) ); - } - - // Prepend ActivityPub Context. - $response = array_merge( array( '@context' => Base_Object::JSON_LD_CONTEXT ), $response ); - $response = \rest_ensure_response( $response ); - $response->header( 'Content-Type', 'application/activity+json; charset=' . \get_option( 'blog_charset' ) ); - - return $response; - } - - /** - * Retrieves a collection of replies. - * - * @param \WP_REST_Request $request The request object. - * @param \WP_Post|\WP_Comment $wp_object The WordPress object. - * - * @return array Response collection of replies. - */ - public function get_replies( $request, $wp_object ) { - $page = $request->get_param( 'page' ); - - // If the request parameter page is present get the CollectionPage otherwise the Replies collection. - if ( null === $page ) { - $response = Replies::get_collection( $wp_object ); - } else { - $response = Replies::get_collection_page( $wp_object, $page ); - } - - return $response; - } - - /** - * Retrieves a collection of likes. - * - * @param \WP_REST_Request $request The request object. - * @param \WP_Post|\WP_Comment $wp_object The WordPress object. - * - * @return array Response collection of likes. - */ - public function get_likes( $request, $wp_object ) { - if ( $wp_object instanceof \WP_Post ) { - $likes = Interactions::count_by_type( $wp_object->ID, 'like' ); - } else { - $likes = 0; - } - - $response = array( - 'id' => get_rest_url_by_path( sprintf( 'posts/%d/likes', $wp_object->ID ) ), - 'type' => 'Collection', - 'totalItems' => $likes, - ); - - return $response; - } - - /** - * Retrieves a collection of shares. - * - * @param \WP_REST_Request $request The request object. - * @param \WP_Post|\WP_Comment $wp_object The WordPress object. - * - * @return array Response collection of shares. - */ - public function get_shares( $request, $wp_object ) { - if ( $wp_object instanceof \WP_Post ) { - $shares = Interactions::count_by_type( $wp_object->ID, 'repost' ); - } else { - $shares = 0; - } - - $response = array( - 'id' => get_rest_url_by_path( sprintf( 'posts/%d/shares', $wp_object->ID ) ), - 'type' => 'Collection', - 'totalItems' => $shares, - ); - - return $response; - } - - /** - * Retrieves the schema for the Replies endpoint. - * - * @return array Schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'replies', - 'type' => 'object', - 'properties' => array( - '@context' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'string', - ), - 'required' => true, - ), - 'id' => array( - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - 'type' => array( - 'type' => 'string', - 'enum' => array( 'Collection', 'OrderedCollection', 'CollectionPage', 'OrderedCollectionPage' ), - 'required' => true, - ), - 'first' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'last' => array( - 'type' => 'string', - 'format' => 'uri', - ), - 'items' => array( - 'type' => 'array', - 'items' => array( - 'type' => 'object', - ), - ), - ), - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-server.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-server.php deleted file mode 100644 index ecc4a905..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-server.php +++ /dev/null @@ -1,173 +0,0 @@ -get_method() ) { - return true; - } - - /** - * Filter to defer signature verification. - * - * Skip signature verification for debugging purposes or to reduce load for - * certain Activity-Types, like "Delete". - * - * @param bool $defer Whether to defer signature verification. - * @param \WP_REST_Request $request The request used to generate the response. - * - * @return bool Whether to defer signature verification. - */ - $defer = \apply_filters( 'activitypub_defer_signature_verification', false, $request ); - - if ( $defer ) { - return true; - } - - if ( - // POST-Requests always have to be signed. - 'GET' !== $request->get_method() || - // GET-Requests only require a signature in secure mode. - ( 'GET' === $request->get_method() && use_authorized_fetch() ) - ) { - $verified_request = Signature::verify_http_signature( $request ); - if ( \is_wp_error( $verified_request ) ) { - return new WP_Error( - 'activitypub_signature_verification', - $verified_request->get_error_message(), - array( 'status' => 401 ) - ); - } - } - - return true; - } - - /** - * Callback function to validate incoming ActivityPub requests - * - * @param WP_REST_Response|\WP_HTTP_Response|WP_Error|mixed $response Result to send to the client. - * Usually a WP_REST_Response or WP_Error. - * @param array $handler Route handler used for the request. - * @param \WP_REST_Request $request Request used to generate the response. - * - * @return mixed|WP_Error The response, error, or modified response. - */ - public static function validate_requests( $response, $handler, $request ) { - if ( 'HEAD' === $request->get_method() ) { - return $response; - } - - $route = $request->get_route(); - - if ( - \is_wp_error( $response ) || - ! \str_starts_with( $route, '/' . ACTIVITYPUB_REST_NAMESPACE ) - ) { - return $response; - } - - $params = $request->get_json_params(); - - // Type is required for ActivityPub requests, so it fail later in the process. - if ( ! isset( $params['type'] ) ) { - return $response; - } - - if ( - ACTIVITYPUB_DISABLE_INCOMING_INTERACTIONS && - in_array( $params['type'], array( 'Create', 'Like', 'Announce' ), true ) - ) { - return new WP_Error( - 'activitypub_server_does_not_accept_incoming_interactions', - \__( 'This server does not accept incoming interactions.', 'activitypub' ), - // We have to use a 2XX status code here, because otherwise the response will be - // treated as an error and Mastodon might block this WordPress instance. - array( 'status' => 202 ) - ); - } - - return $response; - } - - /** - * Modify the parameter priority order for a REST API request. - * - * @param string[] $order Array of types to check, in order of priority. - * @param \WP_REST_Request $request The request object. - * - * @return string[] The modified order of types to check. - */ - public static function request_parameter_order( $order, $request ) { - $route = $request->get_route(); - - // Check if it is an activitypub request and exclude webfinger and nodeinfo endpoints. - if ( ! \str_starts_with( $route, '/' . ACTIVITYPUB_REST_NAMESPACE ) ) { - return $order; - } - - $method = $request->get_method(); - - if ( WP_REST_Server::CREATABLE !== $method ) { - return $order; - } - - return array( - 'JSON', - 'POST', - 'URL', - 'defaults', - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-url-validator-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-url-validator-controller.php deleted file mode 100644 index 9c9474eb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-url-validator-controller.php +++ /dev/null @@ -1,133 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_items' ), - 'permission_callback' => array( $this, 'get_items_permissions_check' ), - 'args' => array( - 'url' => array( - 'type' => 'string', - 'format' => 'uri', - 'required' => true, - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Check if a given request has access to validate URLs. - * - * @param \WP_REST_Request $request The request. - * - * @return bool True if the request has access to validate URLs, false otherwise. - */ - public function get_items_permissions_check( $request ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return current_user_can( 'edit_posts' ); - } - - /** - * Check if URL is a valid ActivityPub endpoint. - * - * @param \WP_REST_Request $request The request. - * - * @return \WP_REST_Response|\WP_Error - */ - public function get_items( $request ) { - $url = $request->get_param( 'url' ); - $object = Http::get_remote_object( $url ); - - if ( is_wp_error( $object ) ) { - return new \WP_Error( - 'activitypub_invalid_url', - __( 'Invalid URL.', 'activitypub' ), - array( 'status' => 400 ) - ); - } - - $response = array( - 'is_activitypub' => ! empty( $object['type'] ), - 'is_real_oembed' => Embed::has_real_oembed( $url ), - 'html' => false, - ); - - if ( $response['is_activitypub'] ) { - $response['html'] = wp_oembed_get( $url ); - } - - return rest_ensure_response( $response ); - } - - /** - * Get the URL validation schema. - * - * @return array - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'validated-url', - 'type' => 'object', - 'properties' => array( - 'is_activitypub' => array( - 'type' => 'boolean', - 'default' => false, - ), - 'is_real_oembed' => array( - 'type' => 'boolean', - 'default' => false, - ), - 'html' => array( - 'type' => 'string', - 'default' => false, - ), - ), - ); - - $this->schema = $schema; - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-webfinger-controller.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-webfinger-controller.php deleted file mode 100644 index ee75e7ad..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/class-webfinger-controller.php +++ /dev/null @@ -1,173 +0,0 @@ -namespace, - '/' . $this->rest_base, - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_item' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'resource' => array( - 'description' => 'The WebFinger resource.', - 'type' => 'string', - 'required' => true, - 'pattern' => '^(acct:)|^(https?://)(.+)$', - ), - ), - ), - 'schema' => array( $this, 'get_item_schema' ), - ) - ); - } - - /** - * Retrieves the WebFinger profile. - * - * @param \WP_REST_Request $request The request object. - * - * @return \WP_REST_Response Response object. - */ - public function get_item( $request ) { - /** - * Action triggered prior to the ActivityPub profile being created and sent to the client. - */ - \do_action( 'activitypub_rest_webfinger_pre' ); - - $resource = $request->get_param( 'resource' ); - $response = $this->get_profile( $resource ); - $code = 200; - - if ( \is_wp_error( $response ) ) { - $code = 400; - $error_data = $response->get_error_data(); - - if ( isset( $error_data['status'] ) ) { - $code = $error_data['status']; - } - } - - return new \WP_REST_Response( - $response, - $code, - array( - 'Access-Control-Allow-Origin' => '*', - 'Content-Type' => 'application/jrd+json; charset=' . \get_option( 'blog_charset' ), - ) - ); - } - - /** - * Get the WebFinger profile. - * - * @param string $webfinger The WebFinger resource. - * - * @return array|\WP_Error The WebFinger profile or WP_Error if not found. - */ - public function get_profile( $webfinger ) { - /** - * Filter the WebFinger data. - * - * @param array $data The WebFinger data. - * @param string $webfinger The WebFinger resource. - */ - return \apply_filters( 'webfinger_data', array(), $webfinger ); - } - - /** - * Retrieves the schema for the WebFinger endpoint. - * - * @return array Schema data. - */ - public function get_item_schema() { - if ( $this->schema ) { - return $this->add_additional_fields_schema( $this->schema ); - } - - $this->schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'webfinger', - 'type' => 'object', - 'required' => array( 'subject', 'links' ), - 'properties' => array( - 'subject' => array( - 'description' => 'The subject of this WebFinger record.', - 'type' => 'string', - 'format' => 'uri', - ), - 'aliases' => array( - 'description' => 'Alternative identifiers for the subject.', - 'type' => 'array', - 'items' => array( - 'type' => 'string', - 'format' => 'uri', - ), - ), - 'links' => array( - 'description' => 'Links associated with the subject.', - 'type' => 'array', - 'items' => array( - 'type' => 'object', - 'properties' => array( - 'rel' => array( - 'description' => 'The relation type of the link.', - 'type' => 'string', - 'required' => true, - ), - 'type' => array( - 'description' => 'The content type of the link.', - 'type' => 'string', - ), - 'href' => array( - 'description' => 'The target URL of the link.', - 'type' => 'string', - 'format' => 'uri', - ), - 'template' => array( - 'description' => 'A URI template for the link.', - 'type' => 'string', - 'format' => 'uri', - ), - ), - ), - ), - ), - ); - - return $this->add_additional_fields_schema( $this->schema ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/trait-collection.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/trait-collection.php deleted file mode 100644 index d1757cd0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/rest/trait-collection.php +++ /dev/null @@ -1,146 +0,0 @@ -get_param( 'page' ); - $per_page = $request->get_param( 'per_page' ); - $max_pages = \ceil( $response['totalItems'] / $per_page ); - - if ( $page > $max_pages ) { - return new \WP_Error( - 'rest_post_invalid_page_number', - 'The page number requested is larger than the number of pages available.', - array( 'status' => 400 ) - ); - } - - // No need to add links if there's only one page. - if ( 1 >= $max_pages && null === $page ) { - return $response; - } - - $response['first'] = \add_query_arg( 'page', 1, $response['id'] ); - $response['last'] = \add_query_arg( 'page', $max_pages, $response['id'] ); - - // If this is a Collection request, return early. - if ( null === $page ) { - // No items in Collections, only links to CollectionPages. - unset( $response['items'], $response['orderedItems'] ); - - return $response; - } - - // Still here, so this is a Page request. Append the type. - $response['type'] .= 'Page'; - $response['partOf'] = $response['id']; - $response['id'] .= '?page=' . $page; - - if ( $max_pages > $page ) { - $response['next'] = \add_query_arg( 'page', $page + 1, $response['id'] ); - } - - if ( $page > 1 ) { - $response['prev'] = \add_query_arg( 'page', $page - 1, $response['id'] ); - } - - return $response; - } - - /** - * Get the schema for an ActivityPub Collection. - * - * Returns a schema definition for ActivityPub (Ordered)Collection and (Ordered)CollectionPage - * that controllers can use to compose their full schema by passing in their item schema. - * - * @param array $item_schema Optional. The schema for the items in the collection. Default empty array. - * @return array The collection schema. - */ - public function get_collection_schema( $item_schema = array() ) { - $collection_schema = array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'collection', - 'type' => 'object', - 'properties' => array( - '@context' => array( - 'description' => 'The JSON-LD context of the OrderedCollection.', - 'type' => array( 'string', 'array', 'object' ), - ), - 'id' => array( - 'description' => 'The unique identifier for the OrderedCollection.', - 'type' => 'string', - 'format' => 'uri', - ), - 'type' => array( - 'description' => 'The type of the object. Either OrderedCollection or OrderedCollectionPage.', - 'type' => 'string', - 'enum' => array( 'Collection', 'CollectionPage', 'OrderedCollection', 'OrderedCollectionPage' ), - ), - 'totalItems' => array( - 'description' => 'The total number of items in the collection.', - 'type' => 'integer', - 'minimum' => 0, - ), - 'orderedItems' => array( - 'description' => 'The ordered items in the collection.', - 'type' => 'array', - ), - 'first' => array( - 'description' => 'Link to the first page of the collection.', - 'type' => 'string', - 'format' => 'uri', - ), - 'last' => array( - 'description' => 'Link to the last page of the collection.', - 'type' => 'string', - 'format' => 'uri', - ), - 'next' => array( - 'description' => 'Link to the next page of the collection.', - 'type' => 'string', - 'format' => 'uri', - ), - 'prev' => array( - 'description' => 'Link to the previous page of the collection.', - 'type' => 'string', - 'format' => 'uri', - ), - 'partOf' => array( - 'description' => 'The OrderedCollection to which this OrderedCollectionPage belongs.', - 'type' => 'string', - 'format' => 'uri', - ), - ), - ); - - // Add the orderedItems property based on the provided item schema. - if ( ! empty( $item_schema ) ) { - $collection_schema['properties']['orderedItems']['items'] = $item_schema; - } - - return $collection_schema; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-actor.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-actor.php deleted file mode 100644 index 80b90b52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-actor.php +++ /dev/null @@ -1,146 +0,0 @@ -get_blog_prefix(); - - // The user meta fields that affect a profile. - $fields = array( - $blog_prefix . 'activitypub_description', - $blog_prefix . 'activitypub_header_image', - $blog_prefix . 'activitypub_icon', - 'description', - 'display_name', - 'user_url', - ); - - if ( in_array( $meta_key, $fields, true ) ) { - self::schedule_profile_update( $user_id ); - } - } - - /** - * Send a profile update when a user is updated. - * - * @param int $user_id User ID being updated. - */ - public static function user_update( $user_id ) { - // Don't bother if the user can't publish. - if ( ! \user_can( $user_id, 'activitypub' ) ) { - return; - } - - self::schedule_profile_update( $user_id ); - } - - /** - * Theme mods only have a dynamic filter so we fudge it like this. - * - * @param mixed $value Optional. The value to be updated. Default null. - * - * @return mixed - */ - public static function blog_user_update( $value = null ) { - self::schedule_profile_update( Actors::BLOG_USER_ID ); - return $value; - } - - /** - * Schedule Activities. - * - * @param string $new_status New post status. - * @param string $old_status Old post status. - * @param \WP_Post $post Post object. - */ - public static function schedule_post_activity( $new_status, $old_status, $post ) { - if ( $post instanceof \WP_Post ) { - if ( Extra_Fields::USER_POST_TYPE === $post->post_type ) { - self::schedule_profile_update( $post->post_author ); - } elseif ( Extra_Fields::BLOG_POST_TYPE === $post->post_type ) { - self::schedule_profile_update( Actors::BLOG_USER_ID ); - } - } - } - - /** - * Send a profile update to all followers. Gets hooked into all relevant options/meta etc. - * - * @param int $user_id The user ID to update (Could be 0 for Blog-User). - */ - public static function schedule_profile_update( $user_id ) { - if ( defined( 'WP_IMPORTING' ) && WP_IMPORTING ) { - return; - } - - $actor = Actors::get_by_id( $user_id ); - - if ( ! $actor || \is_wp_error( $actor ) ) { - return; - } - - $actor->set_updated( gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, time() ) ); - - add_to_outbox( $actor, 'Update', $user_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-comment.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-comment.php deleted file mode 100644 index 1d63f01e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-comment.php +++ /dev/null @@ -1,91 +0,0 @@ -user_id ) { - return; - } - - $type = false; - - if ( - 'approved' === $new_status && - 'approved' !== $old_status - ) { - $type = 'Create'; - } elseif ( 'approved' === $new_status ) { - $type = 'Update'; - \update_comment_meta( $comment->comment_ID, 'activitypub_comment_modified', time(), true ); - } elseif ( - 'trash' === $new_status || - 'spam' === $new_status - ) { - $type = 'Delete'; - } - - if ( empty( $type ) ) { - return; - } - - // Check if comment should be federated or not. - if ( ! should_comment_be_federated( $comment ) ) { - return; - } - - add_to_outbox( $comment, $type, $comment->user_id ); - } - - /** - * Schedule Comment Activities on insert. - * - * @param int $comment_id Comment ID. - * @param \WP_Comment $comment Comment object. - */ - public static function schedule_comment_activity_on_insert( $comment_id, $comment ) { - if ( 1 === (int) $comment->comment_approved ) { - self::schedule_comment_activity( 'approved', '', $comment ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-post.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-post.php deleted file mode 100644 index 8ae694f3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/scheduler/class-post.php +++ /dev/null @@ -1,113 +0,0 @@ -post_author ); - } - - /** - * Schedules Activities for attachment transitions. - * - * @param int $post_id Attachment ID. - */ - public static function transition_attachment_status( $post_id ) { - if ( \defined( 'WP_IMPORTING' ) && WP_IMPORTING ) { - return; - } - - if ( ! \post_type_supports( 'attachment', 'activitypub' ) ) { - return; - } - - $post = \get_post( $post_id ); - - switch ( \current_action() ) { - case 'add_attachment': - // Add the post to the outbox. - add_to_outbox( $post, 'Create', $post->post_author ); - break; - case 'edit_attachment': - // Update the post to the outbox. - add_to_outbox( $post, 'Update', $post->post_author ); - break; - case 'delete_attachment': - // Delete the post from the outbox. - add_to_outbox( $post, 'Delete', $post->post_author ); - break; - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/table/class-followers.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/table/class-followers.php deleted file mode 100644 index 93a89271..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/table/class-followers.php +++ /dev/null @@ -1,238 +0,0 @@ -id === 'settings_page_activitypub' ) { - $this->user_id = Actors::BLOG_USER_ID; - } else { - $this->user_id = \get_current_user_id(); - } - - parent::__construct( - array( - 'singular' => \__( 'Follower', 'activitypub' ), - 'plural' => \__( 'Followers', 'activitypub' ), - 'ajax' => false, - ) - ); - } - - /** - * Get columns. - * - * @return array - */ - public function get_columns() { - return array( - 'cb' => '', - 'post_title' => \__( 'Name', 'activitypub' ), - 'avatar' => \__( 'Avatar', 'activitypub' ), - 'username' => \__( 'Username', 'activitypub' ), - 'url' => \__( 'URL', 'activitypub' ), - 'published' => \__( 'Followed', 'activitypub' ), - 'modified' => \__( 'Last updated', 'activitypub' ), - ); - } - - /** - * Returns sortable columns. - * - * @return array - */ - public function get_sortable_columns() { - return array( - 'post_title' => array( 'post_title', true ), - 'modified' => array( 'modified', false ), - 'published' => array( 'published', false ), - ); - } - - /** - * Prepare items. - */ - public function prepare_items() { - $columns = $this->get_columns(); - $hidden = array(); - - $this->process_action(); - $this->_column_headers = array( $columns, $hidden, $this->get_sortable_columns() ); - - $page_num = $this->get_pagenum(); - $per_page = 20; - - $args = array(); - - // phpcs:disable WordPress.Security.NonceVerification.Recommended - if ( isset( $_GET['orderby'] ) ) { - $args['orderby'] = sanitize_text_field( wp_unslash( $_GET['orderby'] ) ); - } - - if ( isset( $_GET['order'] ) ) { - $args['order'] = sanitize_text_field( wp_unslash( $_GET['order'] ) ); - } - - if ( isset( $_GET['s'] ) && isset( $_REQUEST['_wpnonce'] ) ) { - $nonce = sanitize_text_field( wp_unslash( $_REQUEST['_wpnonce'] ) ); - if ( wp_verify_nonce( $nonce, 'bulk-' . $this->_args['plural'] ) ) { - $args['s'] = sanitize_text_field( wp_unslash( $_GET['s'] ) ); - } - } - // phpcs:enable WordPress.Security.NonceVerification.Recommended - - $followers_with_count = FollowerCollection::get_followers_with_count( $this->user_id, $per_page, $page_num, $args ); - $followers = $followers_with_count['followers']; - $counter = $followers_with_count['total']; - - $this->items = array(); - $this->set_pagination_args( - array( - 'total_items' => $counter, - 'total_pages' => ceil( $counter / $per_page ), - 'per_page' => $per_page, - ) - ); - - foreach ( $followers as $follower ) { - $item = array( - 'icon' => esc_attr( $follower->get_icon_url() ), - 'post_title' => esc_attr( $follower->get_name() ), - 'username' => esc_attr( $follower->get_preferred_username() ), - 'url' => esc_attr( object_to_uri( $follower->get_url() ) ), - 'identifier' => esc_attr( $follower->get_id() ), - 'published' => esc_attr( $follower->get_published() ), - 'modified' => esc_attr( $follower->get_updated() ), - ); - - $this->items[] = $item; - } - } - - /** - * Returns bulk actions. - * - * @return array - */ - public function get_bulk_actions() { - return array( - 'delete' => __( 'Delete', 'activitypub' ), - ); - } - - /** - * Column default. - * - * @param array $item Item. - * @param string $column_name Column name. - * @return string - */ - public function column_default( $item, $column_name ) { - if ( ! array_key_exists( $column_name, $item ) ) { - return __( 'None', 'activitypub' ); - } - return $item[ $column_name ]; - } - - /** - * Column avatar. - * - * @param array $item Item. - * @return string - */ - public function column_avatar( $item ) { - return sprintf( - '', - $item['icon'] - ); - } - - /** - * Column url. - * - * @param array $item Item. - * @return string - */ - public function column_url( $item ) { - return sprintf( - '
%s', - esc_url( $item['url'] ), - $item['url'] - ); - } - - /** - * Column cb. - * - * @param array $item Item. - * @return string - */ - public function column_cb( $item ) { - return sprintf( '', esc_attr( $item['identifier'] ) ); - } - - /** - * Process action. - */ - public function process_action() { - if ( ! isset( $_REQUEST['followers'] ) || ! isset( $_REQUEST['_wpnonce'] ) ) { - return; - } - $nonce = sanitize_text_field( wp_unslash( $_REQUEST['_wpnonce'] ) ); - if ( ! wp_verify_nonce( $nonce, 'bulk-' . $this->_args['plural'] ) ) { - return; - } - - if ( ! current_user_can( 'edit_user', $this->user_id ) ) { - return; - } - - $followers = $_REQUEST['followers']; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput - - if ( $this->current_action() === 'delete' ) { - if ( ! is_array( $followers ) ) { - $followers = array( $followers ); - } - foreach ( $followers as $follower ) { - FollowerCollection::remove_follower( $this->user_id, $follower ); - } - } - } - - /** - * Returns user count. - * - * @return int - */ - public function get_user_count() { - return FollowerCollection::count_followers( $this->user_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-activity-object.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-activity-object.php deleted file mode 100644 index 79f0983a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-activity-object.php +++ /dev/null @@ -1,159 +0,0 @@ -transform_object_properties( $this->item ); - - if ( \is_wp_error( $activity_object ) ) { - return $activity_object; - } - - $activity_object = $this->set_audience( $activity_object ); - - return $activity_object; - } - - /** - * Get the ID of the object. - * - * @return string The ID of the object. - */ - public function get_id() { - return $this->item->get_id(); - } - - /** - * Get the attributed to. - * - * @return string The attributed to. - */ - public function get_attributed_to() { - return $this->item->get_attributed_to(); - } - - /** - * Helper function to get the @-Mentions from the post content. - * - * @return array The list of @-Mentions. - */ - protected function get_mentions() { - /** - * Filter the mentions in the post content. - * - * @param array $mentions The mentions. - * @param string $content The post content. - * @param \Activitypub\Activity\Activity $item The Activity object. - * - * @return array The filtered mentions. - */ - return apply_filters( - 'activitypub_extract_mentions', - array(), - $this->item->get_content() . ' ' . $this->item->get_summary(), - $this->item - ); - } - - /** - * Returns the content map for the post. - * - * @return array The content map for the post. - */ - protected function get_content_map() { - $content = $this->item->get_content(); - - if ( ! $content ) { - return null; - } - - return array( - $this->get_locale() => $content, - ); - } - - /** - * Returns the name map for the post. - * - * @return array The name map for the post. - */ - protected function get_name_map() { - $name = $this->item->get_name(); - - if ( ! $name ) { - return null; - } - - return array( - $this->get_locale() => $name, - ); - } - - /** - * Returns the summary map for the post. - * - * @return array The summary map for the post. - */ - protected function get_summary_map() { - $summary = $this->item->get_summary(); - - if ( ! $summary ) { - return null; - } - - return array( - $this->get_locale() => $summary, - ); - } - - /** - * Returns a list of Tags, used in the Comment. - * - * This includes Hash-Tags and Mentions. - * - * @return array The list of Tags. - */ - protected function get_tag() { - $tags = $this->item->get_tag(); - - if ( ! $tags ) { - $tags = array(); - } - - $mentions = $this->get_mentions(); - - if ( $mentions ) { - foreach ( $mentions as $mention => $url ) { - $tag = array( - 'type' => 'Mention', - 'href' => \esc_url( $url ), - 'name' => \esc_html( $mention ), - ); - $tags[] = $tag; - } - } - - return \array_unique( $tags, SORT_REGULAR ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-attachment.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-attachment.php deleted file mode 100644 index 65f500ca..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-attachment.php +++ /dev/null @@ -1,66 +0,0 @@ -item->ID ); - $mime_type_parts = \explode( '/', $mime_type ); - $type = ''; - - switch ( $mime_type_parts[0] ) { - case 'audio': - case 'video': - $type = 'Document'; - break; - case 'image': - $type = 'Image'; - break; - } - - $attachment = array( - 'type' => $type, - 'url' => wp_get_attachment_url( $this->item->ID ), - 'mediaType' => $mime_type, - ); - - $alt = \get_post_meta( $this->item->ID, '_wp_attachment_image_alt', true ); - if ( $alt ) { - $attachment['name'] = $alt; - } - - return $attachment; - } - - /** - * Returns the ActivityStreams 2.0 Object-Type for a Post based on the - * settings and the Post-Type. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#activity-types - * - * @return string The Object-Type. - */ - protected function get_type() { - return 'Note'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-base.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-base.php deleted file mode 100644 index 792c8606..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-base.php +++ /dev/null @@ -1,388 +0,0 @@ -item = $item; - $this->wp_object = $item; - } - - /** - * Transform all properties with available get(ter) functions. - * - * @param Base_Object $activity_object The ActivityPub Object. - * - * @return Base_Object|\WP_Error The transformed ActivityPub Object or WP_Error on failure. - */ - protected function transform_object_properties( $activity_object ) { - if ( ! $activity_object || \is_wp_error( $activity_object ) ) { - return $activity_object; - } - - $vars = $activity_object->get_object_var_keys(); - - foreach ( $vars as $var ) { - $getter = 'get_' . $var; - - if ( \method_exists( $this, $getter ) ) { - $value = \call_user_func( array( $this, $getter ) ); - - if ( null !== $value ) { - $setter = 'set_' . $var; - - /** - * Filter the value before it is set to the Activity-Object `$activity_object`. - * - * @param mixed $value The value that should be set. - * @param mixed $item The Object. - */ - $value = \apply_filters( "activitypub_transform_{$setter}", $value, $this->item ); - - /** - * Filter the value before it is set to the Activity-Object `$activity_object`. - * - * @param mixed $value The value that should be set. - * @param string $var The variable name. - * @param mixed $item The Object. - */ - $value = \apply_filters( 'activitypub_transform_set', $value, $var, $this->item ); - - \call_user_func( array( $activity_object, $setter ), $value ); - } - } - } - - return $activity_object; - } - - /** - * Transform the item into an ActivityPub Object. - * - * @return Base_Object|object The Activity-Object. - */ - public function to_object() { - $activity_object = new Base_Object(); - $activity_object = $this->transform_object_properties( $activity_object ); - - if ( \is_wp_error( $activity_object ) ) { - return $activity_object; - } - - $activity_object = $this->set_audience( $activity_object ); - - return $activity_object; - } - - /** - * Get the content visibility. - * - * @return string The content visibility. - */ - public function get_content_visibility() { - if ( ! $this->content_visibility ) { - return ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC; - } - - return $this->content_visibility; - } - - /** - * Set the content visibility. - * - * @param string $content_visibility The content visibility. - */ - public function set_content_visibility( $content_visibility ) { - $this->content_visibility = $content_visibility; - - return $this; - } - - /** - * Set the audience. - * - * @param Base_Object $activity_object The ActivityPub Object. - * - * @return Base_Object The ActivityPub Object. - */ - protected function set_audience( $activity_object ) { - $public = 'https://www.w3.org/ns/activitystreams#Public'; - $actor = Actors::get_by_resource( $this->get_attributed_to() ); - if ( ! $actor || is_wp_error( $actor ) ) { - $followers = null; - } else { - $followers = $actor->get_followers(); - } - $mentions = array_values( $this->get_mentions() ); - - switch ( $this->get_content_visibility() ) { - case ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC: - $activity_object->add_to( $public ); - $activity_object->add_cc( $followers ); - $activity_object->add_cc( $mentions ); - break; - case ACTIVITYPUB_CONTENT_VISIBILITY_QUIET_PUBLIC: - $activity_object->add_to( $followers ); - $activity_object->add_to( $mentions ); - $activity_object->add_cc( $public ); - break; - case ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE: - $activity_object->add_to( $mentions ); - } - - return $activity_object; - } - - /** - * Transform the item to an ActivityPub ID. - * - * @return string The ID of the WordPress Object. - */ - public function to_id() { - /* @var Attachment|Comment|Json|Post|User $this Object transformer. */ - return $this->get_id(); - } - - /** - * Transforms the ActivityPub Object to an Activity - * - * @param string $type The Activity-Type. - * - * @return Activity The Activity. - */ - public function to_activity( $type ) { - $object = $this->to_object(); - - $activity = new Activity(); - $activity->set_type( $type ); - - // Pre-fill the Activity with data (for example cc and to). - $activity->set_object( $object ); - - // Use simple Object (only ID-URI) for Like and Announce. - if ( 'Like' === $type ) { - $activity->set_object( $object->get_id() ); - } - - return $activity; - } - - /** - * Returns a generic locale based on the Blog settings. - * - * @return string The locale of the blog. - */ - protected function get_locale() { - $lang = \strtolower( \strtok( \get_locale(), '_-' ) ); - - if ( $this->item instanceof \WP_Post ) { - /** - * Deprecates the `activitypub_post_locale` filter. - * - * @param string $lang The locale of the post. - * @param mixed $item The post object. - * - * @return string The filtered locale of the post. - */ - $lang = apply_filters_deprecated( - 'activitypub_post_locale', - array( - $lang, - $this->item->ID, - $this->item, - ), - '5.4.0', - 'activitypub_locale', - 'Use the `activitypub_locale` filter instead.' - ); - } - - /** - * Filter the locale of the post. - * - * @param string $lang The locale of the post. - * @param mixed $item The post object. - * - * @return string The filtered locale of the post. - */ - return apply_filters( 'activitypub_locale', $lang, $this->item ); - } - - /** - * Returns the default media type for an Object. - * - * @return string The media type. - */ - public function get_media_type() { - return 'text/html'; - } - - /** - * Returns the content map for the post. - * - * @return array|null The content map for the post or null if not set. - */ - protected function get_content_map() { - if ( ! \method_exists( $this, 'get_content' ) || ! $this->get_content() ) { - return null; - } - - return array( - $this->get_locale() => $this->get_content(), - ); - } - - /** - * Returns the name map for the post. - * - * @return array|null The name map for the post or null if not set. - */ - protected function get_name_map() { - if ( ! \method_exists( $this, 'get_name' ) || ! $this->get_name() ) { - return null; - } - - return array( - $this->get_locale() => $this->get_name(), - ); - } - - /** - * Returns the summary map for the post. - * - * @return array|null The summary map for the post or null if not set. - */ - protected function get_summary_map() { - if ( ! \method_exists( $this, 'get_summary' ) || ! $this->get_summary() ) { - return null; - } - - return array( - $this->get_locale() => $this->get_summary(), - ); - } - - /** - * Returns the tags for the post. - * - * @return array The tags for the post. - */ - protected function get_tag() { - $tags = array(); - $mentions = $this->get_mentions(); - - foreach ( $mentions as $mention => $url ) { - $tags[] = array( - 'type' => 'Mention', - 'href' => \esc_url( $url ), - 'name' => \esc_html( $mention ), - ); - } - - return \array_unique( $tags, SORT_REGULAR ); - } - - /** - * Get the attributed to. - * - * @return string The attributed to. - */ - protected function get_attributed_to() { - return null; - } - - /** - * Extracts mentions from the content. - * - * @return array The mentions. - */ - protected function get_mentions() { - $content = ''; - - if ( method_exists( $this, 'get_content' ) ) { - $content = $content . ' ' . $this->get_content(); - } - - if ( method_exists( $this, 'get_summary' ) ) { - $content = $content . ' ' . $this->get_summary(); - } - - /** - * Filter the mentions in the post content. - * - * @param array $mentions The mentions. - * @param string $content The post content. - * @param WP_Post $post The post object. - * - * @return array The filtered mentions. - */ - return apply_filters( - 'activitypub_extract_mentions', - array(), - $content, - $this->item - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-comment.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-comment.php deleted file mode 100644 index 5e9562dd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-comment.php +++ /dev/null @@ -1,361 +0,0 @@ -item; - $object = parent::to_object(); - - $object->set_url( $this->get_id() ); - $object->set_type( 'Note' ); - - $published = \strtotime( $comment->comment_date_gmt ); - $object->set_published( \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $published ) ); - - $updated = \get_comment_meta( $comment->comment_ID, 'activitypub_comment_modified', true ); - if ( $updated > $published ) { - $object->set_updated( \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $updated ) ); - } - - $object->set_content_map( - array( - $this->get_locale() => $this->get_content(), - ) - ); - - return $object; - } - - /** - * Get the content visibility. - * - * @return string The content visibility. - */ - public function get_content_visibility() { - if ( $this->content_visibility ) { - return $this->content_visibility; - } - - $comment = $this->item; - $post = \get_post( $comment->comment_post_ID ); - - if ( ! $post ) { - return ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC; - } - - $content_visibility = \get_post_meta( $post->ID, 'activitypub_content_visibility', true ); - - if ( ! $content_visibility ) { - return ACTIVITYPUB_CONTENT_VISIBILITY_PUBLIC; - } - - $this->content_visibility = $content_visibility; - - return $this->content_visibility; - } - - /** - * Returns the User-URL of the Author of the Post. - * - * If `single_user` mode is enabled, the URL of the Blog-User is returned. - * - * @return string The User-URL. - */ - protected function get_attributed_to() { - // If the comment was received via ActivityPub, return the author URL. - if ( was_comment_received( $this->item ) ) { - return $this->item->comment_author_url; - } - - return $this->get_actor_object()->get_id(); - } - - /** - * Returns the content for the ActivityPub Item. - * - * The content will be generated based on the user settings. - * - * @return string The content. - */ - protected function get_content() { - $comment = $this->item; - $content = $comment->comment_content; - $mentions = ''; - - foreach ( $this->extract_reply_context() as $acct => $url ) { - $mentions .= sprintf( - '%3$s ', - esc_url( $url ), - esc_attr( $acct ), - esc_html( '@' . strtok( $acct, '@' ) ) - ); - } - $content = $mentions . $content; - - /** - * Filter the content of the comment. - * - * @param string $content The content of the comment. - * @param \WP_Comment $comment The comment object. - * @param array $args The arguments. - * - * @return string The filtered content of the comment. - */ - $content = \apply_filters( 'comment_text', $content, $comment, array() ); - $content = \preg_replace( '/[\n\r\t]/', '', $content ); - $content = \trim( $content ); - - /** - * Filter the content of the comment. - * - * @param string $content The content of the comment. - * @param \WP_Comment $comment The comment object. - * - * @return string The filtered content of the comment. - */ - return \apply_filters( 'activitypub_the_content', $content, $comment ); - } - - /** - * Returns the in-reply-to for the ActivityPub Item. - * - * @return false|string|null The URL of the in-reply-to. - */ - protected function get_in_reply_to() { - $comment = $this->item; - $parent_comment = null; - - if ( $comment->comment_parent ) { - $parent_comment = \get_comment( $comment->comment_parent ); - } - - if ( $parent_comment ) { - $in_reply_to = Comment_Utils::get_source_id( $parent_comment->comment_ID ); - if ( ! $in_reply_to && ! empty( $parent_comment->user_id ) ) { - $in_reply_to = Comment_Utils::generate_id( $parent_comment ); - } - } else { - $in_reply_to = \get_permalink( $comment->comment_post_ID ); - } - - return $in_reply_to; - } - - /** - * Returns the ID of the ActivityPub Object. - * - * @see https://www.w3.org/TR/activitypub/#obj-id - * @see https://github.com/tootsuite/mastodon/issues/13879 - * - * @return string ActivityPub URI for comment - */ - protected function get_id() { - $comment = $this->item; - return Comment_Utils::generate_id( $comment ); - } - - /** - * Returns the User-Object of the Author of the Post. - * - * If `single_user` mode is enabled, the Blog-User is returned. - * - * @return \Activitypub\Activity\Actor The User-Object. - */ - protected function get_actor_object() { - if ( $this->actor_object ) { - return $this->actor_object; - } - - $blog_user = new Blog(); - $this->actor_object = $blog_user; - - if ( is_single_user() ) { - return $blog_user; - } - - $user = Actors::get_by_id( $this->item->user_id ); - - if ( $user && ! is_wp_error( $user ) ) { - $this->actor_object = $user; - return $user; - } - - return $blog_user; - } - - /** - * Helper function to get the @-Mentions from the comment content. - * - * @return array The list of @-Mentions. - */ - protected function get_mentions() { - \add_filter( 'activitypub_extract_mentions', array( $this, 'extract_reply_context' ) ); - - /** - * Filter the mentions in the comment. - * - * @param array $mentions The list of mentions. - * @param string $content The content of the comment. - * @param \WP_Comment $comment The comment object. - * - * @return array The filtered list of mentions. - */ - return apply_filters( 'activitypub_extract_mentions', array(), $this->item->comment_content, $this->item ); - } - - /** - * Gets the ancestors of the comment, but only the ones that are ActivityPub comments. - * - * @return array The list of ancestors. - */ - protected function get_comment_ancestors() { - $ancestors = get_comment_ancestors( $this->item ); - - // Now that we have the full tree of ancestors, only return the ones received from the fediverse. - return array_filter( - $ancestors, - function ( $comment_id ) { - return \get_comment_meta( $comment_id, 'protocol', true ) === 'activitypub'; - } - ); - } - - /** - * Collect all other Users that participated in this comment-thread - * to send them a notification about the new reply. - * - * @param array $mentions Optional. The already mentioned ActivityPub users. Default empty array. - * - * @return array The list of all Repliers. - */ - public function extract_reply_context( $mentions = array() ) { - // Check if `$this->item` is a WP_Comment. - if ( 'WP_Comment' !== get_class( $this->item ) ) { - return $mentions; - } - - $ancestors = $this->get_comment_ancestors(); - if ( ! $ancestors ) { - return $mentions; - } - - foreach ( $ancestors as $comment_id ) { - $comment = \get_comment( $comment_id ); - if ( $comment && ! empty( $comment->comment_author_url ) ) { - $acct = Webfinger::uri_to_acct( $comment->comment_author_url ); - if ( $acct && ! is_wp_error( $acct ) ) { - $acct = str_replace( 'acct:', '@', $acct ); - $mentions[ $acct ] = $comment->comment_author_url; - } - } - } - - return $mentions; - } - - /** - * Returns the updated date of the comment. - * - * @return string|null The updated date of the comment. - */ - public function get_updated() { - $updated = \get_comment_meta( $this->item->comment_ID, 'activitypub_comment_modified', true ); - $published = \get_comment_meta( $this->item->comment_ID, 'activitypub_comment_published', true ); - - if ( $updated > $published ) { - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $updated ); - } - - return null; - } - - /** - * Returns the published date of the comment. - * - * @return string The published date of the comment. - */ - public function get_published() { - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, \strtotime( $this->item->comment_date_gmt ) ); - } - - /** - * Returns the URL of the comment. - * - * @return string The URL of the comment. - */ - public function get_url() { - return $this->get_id(); - } - - /** - * Returns the type of the comment. - * - * @return string The type of the comment. - */ - public function get_type() { - return 'Note'; - } - - /** - * Get the context of the post. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-context - * - * @return string The context of the post. - */ - protected function get_context() { - if ( $this->item->comment_post_ID ) { - return get_rest_url_by_path( sprintf( 'posts/%d/context', $this->item->comment_post_ID ) ); - } - - return null; - } - - /** - * Get the replies Collection. - * - * @return array|null The replies collection on success or null on failure. - */ - public function get_replies() { - return Replies::get_collection( $this->item ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-factory.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-factory.php deleted file mode 100644 index a24300d0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-factory.php +++ /dev/null @@ -1,117 +0,0 @@ -post_type === 'event' ) { - * return new My_Event_Transformer( $object ); - * } - * return $transformer; - * }, 10, 3 ); - * - * @param null|Base $transformer The transformer to use. Default null. - * @param mixed $data The object to transform. - * @param string $object_class The class of the object to transform. - * - * @return mixed The transformer to use. - */ - $transformer = \apply_filters( 'activitypub_transformer', null, $data, $class ); - - if ( $transformer ) { - if ( - ! \is_object( $transformer ) || - ! $transformer instanceof Base - ) { - return new WP_Error( 'invalid_transformer', __( 'Invalid transformer', 'activitypub' ) ); - } - - return $transformer; - } - - // Use default transformer. - switch ( $class ) { - case 'WP_Post': - if ( 'attachment' === $data->post_type && ! is_post_disabled( $data ) ) { - return new Attachment( $data ); - } elseif ( ! is_post_disabled( $data ) ) { - return new Post( $data ); - } - break; - case 'WP_Comment': - if ( Comment_Helper::should_be_federated( $data ) ) { - return new Comment( $data ); - } - break; - case 'WP_User': - if ( user_can_activitypub( $data->ID ) ) { - return new User( $data ); - } - break; - case 'json': - return new Json( $data ); - } - - if ( $data instanceof \Activitypub\Activity\Base_Object ) { - return new Activity_Object( $data ); - } - - return new WP_Error( 'invalid_object', __( 'Invalid object', 'activitypub' ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-json.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-json.php deleted file mode 100644 index 9829c220..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-json.php +++ /dev/null @@ -1,41 +0,0 @@ -item; - $object = parent::to_object(); - - $content_warning = get_content_warning( $post ); - if ( ! empty( $content_warning ) ) { - $object->set_sensitive( true ); - $object->set_summary( $content_warning ); - $object->set_summary_map( null ); - } - - return $object; - } - - /** - * Get the content visibility. - * - * @return string The content visibility. - */ - public function get_content_visibility() { - if ( ! $this->content_visibility ) { - return get_content_visibility( $this->item ); - } - - return $this->content_visibility; - } - - /** - * Returns the User-Object of the Author of the Post. - * - * If `single_user` mode is enabled, the Blog-User is returned. - * - * @return \Activitypub\Activity\Actor The User-Object. - */ - public function get_actor_object() { - if ( $this->actor_object ) { - return $this->actor_object; - } - - $blog_user = new Blog(); - $this->actor_object = $blog_user; - - if ( is_single_user() ) { - return $blog_user; - } - - $user = Actors::get_by_id( $this->item->post_author ); - - if ( $user && ! is_wp_error( $user ) ) { - $this->actor_object = $user; - return $user; - } - - return $blog_user; - } - - /** - * Returns the ID of the Post. - * - * @return string The Posts ID. - */ - public function get_id() { - $last_legacy_id = (int) \get_option( 'activitypub_last_post_with_permalink_as_id', 0 ); - $post_id = (int) $this->item->ID; - - if ( $post_id > $last_legacy_id ) { - // Generate URI based on post ID. - return \add_query_arg( 'p', $post_id, \trailingslashit( \home_url() ) ); - } - - return $this->get_url(); - } - - /** - * Returns the URL of the Post. - * - * @return string The Posts URL. - */ - public function get_url() { - $post = $this->item; - - switch ( \get_post_status( $post ) ) { - case 'trash': - $permalink = \get_post_meta( $post->ID, '_activitypub_canonical_url', true ); - break; - case 'draft': - // Get_sample_permalink is in wp-admin, not always loaded. - if ( ! \function_exists( '\get_sample_permalink' ) ) { - require_once ABSPATH . 'wp-admin/includes/post.php'; - } - $sample = \get_sample_permalink( $post->ID ); - $permalink = \str_replace( array( '%pagename%', '%postname%' ), $sample[1], $sample[0] ); - break; - default: - $permalink = \get_permalink( $post ); - break; - } - - return \esc_url( $permalink ); - } - - /** - * Returns the User-URL of the Author of the Post. - * - * If `single_user` mode is enabled, the URL of the Blog-User is returned. - * - * @return string The User-URL. - */ - protected function get_attributed_to() { - return $this->get_actor_object()->get_id(); - } - - /** - * Returns the featured image as `Image`. - * - * @return array|null The Image or null if no image is available. - */ - protected function get_image() { - $post_id = $this->item->ID; - - // List post thumbnail first if this post has one. - if ( - ! \function_exists( 'has_post_thumbnail' ) || - ! \has_post_thumbnail( $post_id ) - ) { - return null; - } - - $id = \get_post_thumbnail_id( $post_id ); - $image_size = 'large'; - - /** - * Filter the image URL returned for each post. - * - * @param array|false $thumbnail The image URL, or false if no image is available. - * @param int $id The attachment ID. - * @param string $image_size The image size to retrieve. Set to 'large' by default. - */ - $thumbnail = apply_filters( - 'activitypub_get_image', - $this->get_wordpress_attachment( $id, $image_size ), - $id, - $image_size - ); - - if ( ! $thumbnail ) { - return null; - } - - $mime_type = \get_post_mime_type( $id ); - - $image = array( - 'type' => 'Image', - 'url' => \esc_url( $thumbnail[0] ), - 'mediaType' => \esc_attr( $mime_type ), - ); - - $alt = \get_post_meta( $id, '_wp_attachment_image_alt', true ); - if ( $alt ) { - $image['name'] = \wp_strip_all_tags( \html_entity_decode( $alt ) ); - } - - return $image; - } - - /** - * Returns an Icon, based on the Featured Image with a fallback to the site-icon. - * - * @return array|null The Icon or null if no icon is available. - */ - protected function get_icon() { - $post_id = $this->item->ID; - - // List post thumbnail first if this post has one. - if ( \has_post_thumbnail( $post_id ) ) { - $id = \get_post_thumbnail_id( $post_id ); - } else { - // Try site_logo, falling back to site_icon, first. - $id = get_option( 'site_icon' ); - } - - if ( ! $id ) { - return null; - } - - $image_size = 'thumbnail'; - - /** - * Filter the image URL returned for each post. - * - * @param array|false $thumbnail The image URL, or false if no image is available. - * @param int $id The attachment ID. - * @param string $image_size The image size to retrieve. Set to 'large' by default. - */ - $thumbnail = apply_filters( - 'activitypub_get_image', - $this->get_wordpress_attachment( $id, $image_size ), - $id, - $image_size - ); - - if ( ! $thumbnail ) { - return null; - } - - $mime_type = \get_post_mime_type( $id ); - - $image = array( - 'type' => 'Image', - 'url' => \esc_url( $thumbnail[0] ), - 'mediaType' => \esc_attr( $mime_type ), - ); - - $alt = \get_post_meta( $id, '_wp_attachment_image_alt', true ); - if ( $alt ) { - $image['name'] = \wp_strip_all_tags( \html_entity_decode( $alt ) ); - } - - return $image; - } - - /** - * Generates all Media Attachments for a Post. - * - * @return array The Attachments. - */ - protected function get_attachment() { - // Remove attachments from drafts. - if ( 'draft' === \get_post_status( $this->item ) ) { - return array(); - } - - /** - * Filters the maximum number of media attachments allowed in a post. - * - * Despite the name suggesting only images, this filter controls the maximum number - * of all media attachments (images, audio, and video) that can be included in an - * ActivityPub post. The name is maintained for backwards compatibility. - * - * @param int $max_media Maximum number of media attachments. Default ACTIVITYPUB_MAX_IMAGE_ATTACHMENTS. - */ - $max_media = \intval( - \apply_filters( - 'activitypub_max_image_attachments', - \get_option( 'activitypub_max_image_attachments', ACTIVITYPUB_MAX_IMAGE_ATTACHMENTS ) - ) - ); - - $media = array( - 'image' => array(), - 'audio' => array(), - 'video' => array(), - ); - $id = $this->item->ID; - - // List post thumbnail first if this post has one. - if ( \function_exists( 'has_post_thumbnail' ) && \has_post_thumbnail( $id ) ) { - $media['image'][] = array( 'id' => \get_post_thumbnail_id( $id ) ); - } - - $media = $this->get_enclosures( $media ); - - if ( site_supports_blocks() && \has_blocks( $this->item->post_content ) ) { - $media = $this->get_block_attachments( $media, $max_media ); - } else { - $media = $this->get_classic_editor_image_embeds( $media, $max_media ); - } - - $media = $this->filter_media_by_object_type( $media, \get_post_format( $this->item ), $this->item ); - $unique_ids = \array_unique( \array_column( $media, 'id' ) ); - $media = \array_intersect_key( $media, $unique_ids ); - $media = \array_slice( $media, 0, $max_media ); - - /** - * Filter the attachment IDs for a post. - * - * @param array $media The media array grouped by type. - * @param WP_Post $item The post object. - * - * @return array The filtered attachment IDs. - */ - $media = \apply_filters( 'activitypub_attachment_ids', $media, $this->item ); - - $attachments = \array_filter( \array_map( array( $this, 'wp_attachment_to_activity_attachment' ), $media ) ); - - /** - * Filter the attachments for a post. - * - * @param array $attachments The attachments. - * @param WP_Post $item The post object. - * - * @return array The filtered attachments. - */ - return \apply_filters( 'activitypub_attachments', $attachments, $this->item ); - } - - /** - * Returns the ActivityStreams 2.0 Object-Type for a Post based on the - * settings and the Post-Type. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#activity-types - * - * @return string The Object-Type. - */ - protected function get_type() { - $post_format_setting = \get_option( 'activitypub_object_type', ACTIVITYPUB_DEFAULT_OBJECT_TYPE ); - - if ( 'wordpress-post-format' !== $post_format_setting ) { - return \ucfirst( $post_format_setting ); - } - - $has_title = \post_type_supports( $this->item->post_type, 'title' ); - $content = \wp_strip_all_tags( $this->item->post_content ); - - // Check if the post has a title. - if ( - ! $has_title || - ! $this->item->post_title || - \strlen( $content ) <= ACTIVITYPUB_NOTE_LENGTH - ) { - return 'Note'; - } - - // Default to Note. - $object_type = 'Note'; - $post_type = \get_post_type( $this->item ); - - if ( 'page' === $post_type ) { - $object_type = 'Page'; - } elseif ( ! \get_post_format( $this->item ) ) { - $object_type = 'Article'; - } - - return $object_type; - } - - /** - * Returns the Audience for the Post. - * - * @return string|null The audience. - */ - public function get_audience() { - $actor_mode = \get_option( 'activitypub_actor_mode', ACTIVITYPUB_ACTOR_MODE ); - - if ( ACTIVITYPUB_ACTOR_AND_BLOG_MODE === $actor_mode ) { - $blog = new Blog(); - return $blog->get_id(); - } - - return null; - } - - /** - * Returns a list of Tags, used in the Post. - * - * This includes Hash-Tags and Mentions. - * - * @return array The list of Tags. - */ - protected function get_tag() { - $tags = parent::get_tag(); - - $post_tags = \get_the_tags( $this->item->ID ); - if ( $post_tags ) { - foreach ( $post_tags as $post_tag ) { - // Tag can be empty. - if ( ! $post_tag ) { - continue; - } - - $tags[] = array( - 'type' => 'Hashtag', - 'href' => \esc_url( \get_tag_link( $post_tag->term_id ) ), - 'name' => esc_hashtag( $post_tag->name ), - ); - } - } - - return \array_unique( $tags, SORT_REGULAR ); - } - - /** - * Returns the summary for the ActivityPub Item. - * - * The summary will be generated based on the user settings and only if the - * object type is not set to `note`. - * - * @return string|null The summary or null if the object type is `note`. - */ - protected function get_summary() { - if ( 'Note' === $this->get_type() ) { - return null; - } - - // Remove Teaser from drafts. - if ( ! $this->is_preview() && 'draft' === \get_post_status( $this->item ) ) { - return \__( '(This post is being modified)', 'activitypub' ); - } - - return generate_post_summary( $this->item ); - } - - /** - * Returns the title for the ActivityPub Item. - * - * The title will be generated based on the user settings and only if the - * object type is not set to `note`. - * - * @return string|null The title or null if the object type is `note`. - */ - protected function get_name() { - if ( 'Note' === $this->get_type() ) { - return null; - } - - $title = \get_the_title( $this->item->ID ); - - if ( ! $title ) { - return null; - } - - return \wp_strip_all_tags( - \html_entity_decode( - $title - ) - ); - } - - /** - * Returns the content for the ActivityPub Item. - * - * The content will be generated based on the user settings. - * - * @return string The content. - */ - protected function get_content() { - \add_filter( 'activitypub_reply_block', '__return_empty_string' ); - - // Remove Content from drafts. - if ( ! $this->is_preview() && 'draft' === \get_post_status( $this->item ) ) { - return \__( '(This post is being modified)', 'activitypub' ); - } - - global $post; - - /** - * Provides an action hook so plugins can add their own hooks/filters before AP content is generated. - * - * Example: if a plugin adds a filter to `the_content` to add a button to the end of posts, it can also remove that filter here. - * - * @param WP_Post $post The post object. - */ - \do_action( 'activitypub_before_get_content', $post ); - - \add_filter( 'render_block_core/embed', array( $this, 'revert_embed_links' ), 10, 2 ); - \add_filter( 'render_block_activitypub/reply', array( $this, 'generate_reply_link' ), 10, 2 ); - - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $post = $this->item; - $content = $this->get_post_content_template(); - - // It seems that shortcodes are only applied to published posts. - if ( is_preview() ) { - $post->post_status = 'publish'; - } - - // Register our shortcodes just in time. - Shortcodes::register(); - // Fill in the shortcodes. - \setup_postdata( $post ); - $content = \do_shortcode( $content ); - \wp_reset_postdata(); - - $content = \wpautop( $content ); - $content = \preg_replace( '/[\n\r\t]/', '', $content ); - $content = \trim( $content ); - - /** - * Filters the post content before it is transformed for ActivityPub. - * - * @param string $content The post content to be transformed. - * @param WP_Post $post The post object being transformed. - */ - $content = \apply_filters( 'activitypub_the_content', $content, $post ); - - // Don't need these anymore, should never appear in a post. - Shortcodes::unregister(); - - // Get rid of the reply block filter. - \remove_filter( 'render_block_activitypub/reply', array( $this, 'generate_reply_link' ), 10, 2 ); - \remove_filter( 'render_block_core/embed', array( $this, 'revert_embed_links' ) ); - \remove_filter( 'activitypub_reply_block', '__return_empty_string' ); - - return $content; - } - - /** - * Generate HTML @ link for reply block. - * - * @param string $block_content The block content. - * @param array $block The block data. - * - * @return string The HTML @ link. - */ - public function generate_reply_link( $block_content, $block ) { - // Return empty string if no URL is provided. - if ( empty( $block['attrs']['url'] ) ) { - return ''; - } - - $url = $block['attrs']['url']; - - // Try to get ActivityPub representation. Is likely already cached. - $object = \Activitypub\Http::get_remote_object( $url ); - if ( \is_wp_error( $object ) ) { - return ''; - } - - $author_url = $object['attributedTo'] ?? ''; - if ( ! $author_url ) { - return ''; - } - - // Fetch author information. - $author = \Activitypub\Http::get_remote_object( $author_url ); - if ( \is_wp_error( $author ) ) { - return ''; - } - - // Get webfinger identifier. - $webfinger = ''; - if ( ! empty( $author['webfinger'] ) ) { - $webfinger = $author['webfinger']; - } elseif ( ! empty( $author['preferredUsername'] ) && ! empty( $author['url'] ) ) { - // Construct webfinger-style identifier from username and domain. - $domain = \wp_parse_url( $author['url'], PHP_URL_HOST ); - $webfinger = '@' . $author['preferredUsername'] . '@' . $domain; - } - - if ( ! $webfinger ) { - return ''; - } - - // Generate HTML @ link. - return \sprintf( - '

%3$s

', - \esc_url( $url ), - \esc_attr( $webfinger ), - \esc_html( '@' . strtok( $webfinger, '@' ) ) - ); - } - - /** - * Returns the in-reply-to URL of the post. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-inreplyto - * - * @return string|null The in-reply-to URL of the post. - */ - protected function get_in_reply_to() { - if ( ! site_supports_blocks() ) { - return null; - } - - $blocks = \parse_blocks( $this->item->post_content ); - - foreach ( $blocks as $block ) { - if ( 'activitypub/reply' === $block['blockName'] && isset( $block['attrs']['url'] ) ) { - // We only support one reply block per post for now. - return $block['attrs']['url']; - } - } - - return null; - } - - /** - * Returns the published date of the post. - * - * @return string The published date of the post. - */ - protected function get_published() { - $published = \strtotime( $this->item->post_date_gmt ); - - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $published ); - } - - /** - * Returns the updated date of the post. - * - * @return string|null The updated date of the post. - */ - protected function get_updated() { - $published = \strtotime( $this->item->post_date_gmt ); - $updated = \strtotime( $this->item->post_modified_gmt ); - - if ( $updated > $published ) { - return \gmdate( ACTIVITYPUB_DATE_TIME_RFC3339, $updated ); - } - - return null; - } - - /** - * Helper function to extract the @-Mentions from the post content. - * - * @return array The list of @-Mentions. - */ - protected function get_mentions() { - /** - * Filter the mentions in the post content. - * - * @param array $mentions The mentions. - * @param string $content The post content. - * @param WP_Post $post The post object. - * - * @return array The filtered mentions. - */ - return apply_filters( - 'activitypub_extract_mentions', - array(), - $this->item->post_content . ' ' . $this->item->post_excerpt, - $this->item - ); - } - - /** - * Transform Embed blocks to block level link. - * - * Remote servers will simply drop iframe elements, rendering incomplete content. - * - * @see https://www.w3.org/TR/activitypub/#security-sanitizing-content - * @see https://www.w3.org/wiki/ActivityPub/Primer/HTML - * - * @param string $block_content The block content (html). - * @param object $block The block object. - * - * @return string A block level link - */ - public function revert_embed_links( $block_content, $block ) { - if ( ! isset( $block['attrs']['url'] ) ) { - return $block_content; - } - return '

' . $block['attrs']['url'] . '

'; - } - - /** - * Check if the post is a preview. - * - * @return boolean True if the post is a preview, false otherwise. - */ - private function is_preview() { - return defined( 'ACTIVITYPUB_PREVIEW' ) && ACTIVITYPUB_PREVIEW; - } - - /** - * Get enclosures for a post. - * - * @param array $media The media array grouped by type. - * - * @return array The media array extended with enclosures. - */ - protected function get_enclosures( $media ) { - $enclosures = get_enclosures( $this->item->ID ); - - if ( ! $enclosures ) { - return $media; - } - - foreach ( $enclosures as $enclosure ) { - // Check if URL is an attachment. - $attachment_id = \attachment_url_to_postid( $enclosure['url'] ); - - if ( $attachment_id ) { - $enclosure['id'] = $attachment_id; - $enclosure['url'] = \wp_get_attachment_url( $attachment_id ); - $enclosure['mediaType'] = \get_post_mime_type( $attachment_id ); - } - - $mime_type = $enclosure['mediaType']; - $mime_type_parts = \explode( '/', $mime_type ); - $enclosure['type'] = \ucfirst( $mime_type_parts[0] ); - - switch ( $mime_type_parts[0] ) { - case 'image': - $media['image'][] = $enclosure; - break; - case 'audio': - $media['audio'][] = $enclosure; - break; - case 'video': - $media['video'][] = $enclosure; - break; - } - } - - return $media; - } - - /** - * Get media attachments from blocks. They will be formatted as ActivityPub attachments, not as WP attachments. - * - * @param array $media The media array grouped by type. - * @param int $max_media The maximum number of attachments to return. - * - * @return array The attachments. - */ - protected function get_block_attachments( $media, $max_media ) { - // Max media can't be negative or zero. - if ( $max_media <= 0 ) { - return array(); - } - - $blocks = \parse_blocks( $this->item->post_content ); - - return $this->get_media_from_blocks( $blocks, $media ); - } - - /** - * Recursively get media IDs from blocks. - * - * @param array $blocks The blocks to search for media IDs. - * @param array $media The media IDs to append new IDs to. - * - * @return array The image IDs. - */ - protected function get_media_from_blocks( $blocks, $media ) { - foreach ( $blocks as $block ) { - // Recurse into inner blocks. - if ( ! empty( $block['innerBlocks'] ) ) { - $media = $this->get_media_from_blocks( $block['innerBlocks'], $media ); - } - - switch ( $block['blockName'] ) { - case 'core/image': - case 'core/cover': - if ( ! empty( $block['attrs']['id'] ) ) { - $alt = ''; - $check = preg_match( '//i', $block['innerHTML'], $match ); - - if ( $check ) { - $alt = $match[2]; - } - - $found = false; - foreach ( $media['image'] as $i => $image ) { - if ( isset( $image['id'] ) && $image['id'] === $block['attrs']['id'] ) { - $media['image'][ $i ]['alt'] = $alt; - $found = true; - break; - } - } - - if ( ! $found ) { - $media['image'][] = array( - 'id' => $block['attrs']['id'], - 'alt' => $alt, - ); - } - } - break; - case 'core/audio': - if ( ! empty( $block['attrs']['id'] ) ) { - $media['audio'][] = array( 'id' => $block['attrs']['id'] ); - } - break; - case 'core/video': - case 'videopress/video': - if ( ! empty( $block['attrs']['id'] ) ) { - $media['video'][] = array( 'id' => $block['attrs']['id'] ); - } - break; - case 'jetpack/slideshow': - case 'jetpack/tiled-gallery': - if ( ! empty( $block['attrs']['ids'] ) ) { - $media['image'] = array_merge( - $media['image'], - array_map( - function ( $id ) { - return array( 'id' => $id ); - }, - $block['attrs']['ids'] - ) - ); - } - break; - case 'jetpack/image-compare': - if ( ! empty( $block['attrs']['beforeImageId'] ) ) { - $media['image'][] = array( 'id' => $block['attrs']['beforeImageId'] ); - } - if ( ! empty( $block['attrs']['afterImageId'] ) ) { - $media['image'][] = array( 'id' => $block['attrs']['afterImageId'] ); - } - break; - } - } - - return $media; - } - - /** - * Get image embeds from the classic editor by parsing HTML. - * - * @param array $media The media array grouped by type. - * @param int $max_images The maximum number of images to return. - * - * @return array The attachments. - */ - protected function get_classic_editor_image_embeds( $media, $max_images ) { - // If someone calls that function directly, bail. - if ( ! \class_exists( '\WP_HTML_Tag_Processor' ) ) { - return $media; - } - - // Max images can't be negative or zero. - if ( $max_images <= 0 ) { - return $media; - } - - $images = array(); - $base = get_upload_baseurl(); - $content = \get_post_field( 'post_content', $this->item ); - $tags = new \WP_HTML_Tag_Processor( $content ); - - // This linter warning is a false positive - we have to re-count each time here as we modify $images. - // phpcs:ignore Squiz.PHP.DisallowSizeFunctionsInLoops.Found - while ( $tags->next_tag( 'img' ) && ( \count( $images ) <= $max_images ) ) { - /** - * Filter the image source URL. - * - * This can be used to modify the image source URL before it is used to - * determine the attachment ID. - * - * @param string $src The image source URL. - */ - $src = \apply_filters( 'activitypub_image_src', $tags->get_attribute( 'src' ) ); - - /* - * If the img source is in our uploads dir, get the - * associated ID. Note: if there's a -500x500 - * type suffix, we remove it, but we try the original - * first in case the original image is actually called - * that. Likewise, we try adding the -scaled suffix for - * the case that this is a small version of an image - * that was big enough to get scaled down on upload: - * https://make.wordpress.org/core/2019/10/09/introducing-handling-of-big-images-in-wordpress-5-3/ - */ - if ( null !== $src && \str_starts_with( $src, $base ) ) { - $img_id = \attachment_url_to_postid( $src ); - - if ( 0 === $img_id ) { - $count = 0; - $src = \strtok( $src, '?' ); - $img_id = \attachment_url_to_postid( $src ); - } - - if ( 0 === $img_id ) { - $count = 0; - $src = \preg_replace( '/-(?:\d+x\d+)(\.[a-zA-Z]+)$/', '$1', $src, 1, $count ); - if ( $count > 0 ) { - $img_id = \attachment_url_to_postid( $src ); - } - } - - if ( 0 === $img_id ) { - $src = \preg_replace( '/(\.[a-zA-Z]+)$/', '-scaled$1', $src ); - $img_id = \attachment_url_to_postid( $src ); - } - - if ( 0 !== $img_id ) { - $images[] = array( - 'id' => $img_id, - 'alt' => $tags->get_attribute( 'alt' ), - ); - } - } - } - - if ( \count( $media['image'] ) <= $max_images ) { - $media['image'] = \array_merge( $media['image'], $images ); - } - - return $media; - } - - /** - * Filter media IDs by object type. - * - * @param array $media The media array grouped by type. - * @param string $type The object type. - * @param WP_Post $item The post object. - * - * @return array The filtered media IDs. - */ - protected function filter_media_by_object_type( $media, $type, $item ) { - /** - * Filter the object type for media attachments. - * - * @param string $type The object type. - * @param WP_Post $item The post object. - * - * @return string The filtered object type. - */ - $type = \apply_filters( 'filter_media_by_object_type', \strtolower( $type ), $item ); - - if ( ! empty( $media[ $type ] ) ) { - return $media[ $type ]; - } - - return array_filter( array_merge( ...array_values( $media ) ) ); - } - - /** - * Converts a WordPress Attachment to an ActivityPub Attachment. - * - * @param array $media The Attachment array. - * - * @return array The ActivityPub Attachment. - */ - public function wp_attachment_to_activity_attachment( $media ) { - if ( ! isset( $media['id'] ) ) { - return $media; - } - - $id = $media['id']; - $attachment = array(); - $mime_type = \get_post_mime_type( $id ); - $mime_type_parts = \explode( '/', $mime_type ); - // Switching on image/audio/video. - switch ( $mime_type_parts[0] ) { - case 'image': - $image_size = 'large'; - - /** - * Filter the image URL returned for each post. - * - * @param array|false $thumbnail The image URL, or false if no image is available. - * @param int $id The attachment ID. - * @param string $image_size The image size to retrieve. Set to 'large' by default. - */ - $thumbnail = apply_filters( - 'activitypub_get_image', - $this->get_wordpress_attachment( $id, $image_size ), - $id, - $image_size - ); - - if ( $thumbnail ) { - $image = array( - 'type' => 'Image', - 'url' => \esc_url( $thumbnail[0] ), - 'mediaType' => \esc_attr( $mime_type ), - ); - - if ( ! empty( $media['alt'] ) ) { - $image['name'] = \wp_strip_all_tags( \html_entity_decode( $media['alt'] ) ); - } else { - $alt = \get_post_meta( $id, '_wp_attachment_image_alt', true ); - if ( $alt ) { - $image['name'] = \wp_strip_all_tags( \html_entity_decode( $alt ) ); - } - } - - $attachment = $image; - } - break; - - case 'audio': - case 'video': - $attachment = array( - 'type' => 'Document', - 'mediaType' => \esc_attr( $mime_type ), - 'url' => \esc_url( \wp_get_attachment_url( $id ) ), - 'name' => \esc_attr( \get_the_title( $id ) ), - ); - $meta = wp_get_attachment_metadata( $id ); - // Height and width for videos. - if ( isset( $meta['width'] ) && isset( $meta['height'] ) ) { - $attachment['width'] = \esc_attr( $meta['width'] ); - $attachment['height'] = \esc_attr( $meta['height'] ); - } - - if ( $this->get_icon() ) { - $attachment['icon'] = object_to_uri( $this->get_icon() ); - } - - break; - } - - /** - * Filter the attachment for a post. - * - * @param array $attachment The attachment. - * @param int $id The attachment ID. - * - * @return array The filtered attachment. - */ - return \apply_filters( 'activitypub_attachment', $attachment, $id ); - } - - /** - * Return details about an image attachment. - * - * @param int $id The attachment ID. - * @param string $image_size The image size to retrieve. Set to 'large' by default. - * - * @return array|false Array of image data, or boolean false if no image is available. - */ - protected function get_wordpress_attachment( $id, $image_size = 'large' ) { - /** - * Hook into the image retrieval process. Before image retrieval. - * - * @param int $id The attachment ID. - * @param string $image_size The image size to retrieve. Set to 'large' by default. - */ - do_action( 'activitypub_get_image_pre', $id, $image_size ); - - $image = \wp_get_attachment_image_src( $id, $image_size ); - - /** - * Hook into the image retrieval process. After image retrieval. - * - * @param int $id The attachment ID. - * @param string $image_size The image size to retrieve. Set to 'large' by default. - */ - do_action( 'activitypub_get_image_post', $id, $image_size ); - - return $image; - } - - /** - * Get the context of the post. - * - * @see https://www.w3.org/TR/activitystreams-vocabulary/#dfn-context - * - * @return string The context of the post. - */ - protected function get_context() { - return get_rest_url_by_path( sprintf( 'posts/%d/context', $this->item->ID ) ); - } - - /** - * Gets the template to use to generate the content of the activitypub item. - * - * @return string The Template. - */ - protected function get_post_content_template() { - $content = \get_option( 'activitypub_custom_post_content', ACTIVITYPUB_CUSTOM_POST_CONTENT ); - $template = $content ?? ACTIVITYPUB_CUSTOM_POST_CONTENT; - - $post_format_setting = \get_option( 'activitypub_object_type', ACTIVITYPUB_DEFAULT_OBJECT_TYPE ); - - if ( 'wordpress-post-format' === $post_format_setting ) { - $template = ''; - - if ( 'Note' === $this->get_type() ) { - $template .= "[ap_title type=\"html\"]\n\n"; - } - - $template .= '[ap_content]'; - } - - /** - * Filters the template used to generate ActivityPub object content. - * - * This filter allows developers to modify the template that determines how post - * content is formatted in ActivityPub objects. The template can include special - * shortcodes like [ap_title] and [ap_content] that are processed during content - * generation. - * - * @param string $template The template string containing shortcodes. - * @param WP_Post $item The WordPress post object being transformed. - */ - return apply_filters( 'activitypub_object_content_template', $template, $this->item ); - } - - /** - * Get the replies Collection. - * - * @return array|null The replies collection on success or null on failure. - */ - public function get_replies() { - return Replies::get_collection( $this->item ); - } - - /** - * Get the likes Collection. - * - * @return array The likes collection. - */ - public function get_likes() { - return array( - 'id' => get_rest_url_by_path( sprintf( 'posts/%d/likes', $this->item->ID ) ), - 'type' => 'Collection', - 'totalItems' => Interactions::count_by_type( $this->item->ID, 'like' ), - ); - } - - /** - * Get the shares Collection. - * - * @return array The Shares collection. - */ - public function get_shares() { - return array( - 'id' => get_rest_url_by_path( sprintf( 'posts/%d/shares', $this->item->ID ) ), - 'type' => 'Collection', - 'totalItems' => Interactions::count_by_type( $this->item->ID, 'repost' ), - ); - } - - /** - * Get the preview of the post. - * - * @return array|null The preview of the post or null if the post is not an Article. - */ - public function get_preview() { - if ( 'Article' !== $this->get_type() ) { - return null; - } - - return array( - 'type' => 'Note', - 'content' => $this->get_summary(), - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-user.php b/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-user.php deleted file mode 100644 index 418913be..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/includes/transformer/class-user.php +++ /dev/null @@ -1,41 +0,0 @@ -transform_object_properties( Actors::get_by_id( $this->item->ID ) ); - - if ( \is_wp_error( $activity_object ) ) { - return $activity_object; - } - - return $activity_object; - } - - /** - * Get the Actor ID. - * - * @return string The Actor ID. - */ - public function to_id() { - return Actors::get_by_id( $this->item->ID )->get_id(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-akismet.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-akismet.php deleted file mode 100644 index 511cef39..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-akismet.php +++ /dev/null @@ -1,40 +0,0 @@ -url = bp_core_get_user_domain( $author_id ); // Add BP member profile URL as user URL. - - // Add BuddyPress' cover_image instead of WordPress' header_image. - $cover_image_url = bp_attachments_get_attachment( 'url', array( 'item_id' => $author_id ) ); - - if ( $cover_image_url ) { - $author->image = array( - 'type' => 'Image', - 'url' => $cover_image_url, - ); - } - - // Change profile URL to BuddyPress' profile URL. - $author->attachment['profile_url'] = array( - 'type' => 'PropertyValue', - 'name' => \__( 'Profile', 'activitypub' ), - 'value' => \html_entity_decode( - sprintf( - '%s', - \esc_attr( bp_core_get_user_domain( $author_id ) ), - \bp_core_get_user_domain( $author_id ), - \wp_parse_url( \bp_core_get_user_domain( $author_id ), \PHP_URL_HOST ) - ), - \ENT_QUOTES, - 'UTF-8' - ), - ); - - // Replace blog URL on multisite. - if ( is_multisite() ) { - $user_blogs = get_blogs_of_user( $author_id ); // Get sites of user to send as AP metadata. - - if ( ! empty( $user_blogs ) ) { - unset( $author->attachment['blog_url'] ); - - foreach ( $user_blogs as $blog ) { - if ( 1 !== $blog->userblog_id ) { - $author->attachment[] = array( - 'type' => 'PropertyValue', - 'name' => $blog->blogname, - 'value' => \html_entity_decode( - sprintf( - '%s', - \esc_attr( $blog->siteurl ), - $blog->siteurl, - \wp_parse_url( $blog->siteurl, \PHP_URL_HOST ) - ), - \ENT_QUOTES, - 'UTF-8' - ), - ); - } - } - } - } - - return $author; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-enable-mastodon-apps.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-enable-mastodon-apps.php deleted file mode 100644 index 466d7bb5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-enable-mastodon-apps.php +++ /dev/null @@ -1,740 +0,0 @@ -update_icon( $data['avatar'] ) ) { - // Unset the avatar so it doesn't get saved again by other plugins. - // Ditto for all other fields below. - unset( $data['avatar'] ); - } - - if ( isset( $data['header'] ) && $user->update_header( $data['header'] ) ) { - unset( $data['header'] ); - } - - if ( isset( $data['display_name'] ) && $user->update_name( $data['display_name'] ) ) { - unset( $data['display_name'] ); - } - - if ( isset( $data['note'] ) && $user->update_summary( $data['note'] ) ) { - unset( $data['note'] ); - } - - if ( isset( $data['fields_attributes'] ) ) { - self::set_extra_fields( $user_id, $data['fields_attributes'] ); - unset( $data['fields_attributes'] ); - } - - return $data; - } - - /** - * Get extra fields for Mastodon API. - * - * @param int $user_id The user id to act on. - * @return array The extra fields. - */ - private static function get_extra_fields( $user_id ) { - $ret = array(); - $fields = Extra_Fields::get_actor_fields( $user_id ); - - foreach ( $fields as $field ) { - $ret[] = array( - 'name' => $field->post_title, - 'value' => Extra_Fields::get_formatted_content( $field ), - ); - } - - return $ret; - } - - /** - * Set extra fields for Mastodon API. - * - * @param int $user_id The user id to act on. - * @param array $fields The fields to set. It is assumed to be the entire set of desired fields. - */ - private static function set_extra_fields( $user_id, $fields ) { - // The Mastodon API submits a simple hash for every field. - // We can reasonably assume a similar order for our operations below. - $ids = wp_list_pluck( Extra_Fields::get_actor_fields( $user_id ), 'ID' ); - $is_blog = Actors::BLOG_USER_ID === $user_id; - $post_type = $is_blog ? Extra_Fields::BLOG_POST_TYPE : Extra_Fields::USER_POST_TYPE; - - foreach ( $fields as $i => $field ) { - $post_id = $ids[ $i ] ?? null; - $has_post = $post_id && \get_post( $post_id ); - $args = array( - 'post_title' => $field['name'], - 'post_content' => Extra_Fields::make_paragraph_block( $field['value'] ), - ); - - if ( $has_post ) { - $args['ID'] = $ids[ $i ]; - \wp_update_post( $args ); - } else { - $args['post_type'] = $post_type; - $args['post_status'] = 'publish'; - if ( ! $is_blog ) { - $args['post_author'] = $user_id; - } - \wp_insert_post( $args ); - } - } - - // Delete any remaining fields. - if ( \count( $fields ) < \count( $ids ) ) { - $to_delete = \array_slice( $ids, \count( $fields ) ); - foreach ( $to_delete as $id ) { - \wp_delete_post( $id, true ); - } - } - } - - /** - * Add followers to Mastodon API. - * - * @param array $followers An array of followers. - * @param string $user_id The user id. - * - * @return array The filtered followers - */ - public static function api_account_followers( $followers, $user_id ) { - $user_id = self::maybe_map_user_to_blog( $user_id ); - $activitypub_followers = Followers::get_followers( $user_id, 40 ); - $mastodon_followers = array_map( - function ( $item ) { - $acct = Webfinger_Util::uri_to_acct( $item->get_id() ); - - if ( $acct && ! is_wp_error( $acct ) ) { - $acct = \str_replace( 'acct:', '', $acct ); - } else { - $acct = $item->get_id(); - } - - $account = new Account(); - $account->id = \strval( $item->get__id() ); - $account->username = $item->get_preferred_username(); - $account->acct = $acct; - $account->display_name = $item->get_name(); - $account->url = $item->get_url(); - $account->avatar = $item->get_icon_url(); - $account->avatar_static = $item->get_icon_url(); - $account->created_at = new DateTime( $item->get_published() ); - $account->last_status_at = new DateTime( $item->get_published() ); - $account->note = $item->get_summary(); - $account->header = $item->get_image_url(); - $account->header_static = $item->get_image_url(); - $account->followers_count = 0; - $account->following_count = 0; - $account->statuses_count = 0; - $account->bot = false; - $account->locked = false; - $account->group = false; - $account->discoverable = false; - $account->noindex = false; - $account->fields = array(); - $account->emojis = array(); - - return $account; - }, - $activitypub_followers - ); - - return array_merge( $mastodon_followers, $followers ); - } - - /** - * Resolve external accounts for Mastodon API - * - * @param Account $user_data The user data. - * @param string $user_id The user id. - * - * @return Account The filtered Account. - */ - public static function api_account_external( $user_data, $user_id ) { - if ( $user_data || ( is_numeric( $user_id ) && $user_id ) ) { - // Only augment. - return $user_data; - } - - $user = Actors::get_by_various( $user_id ); - - if ( $user && ! is_wp_error( $user ) ) { - return $user_data; - } - - $uri = Webfinger_Util::resolve( $user_id ); - - if ( ! $uri || is_wp_error( $uri ) ) { - return $user_data; - } - - $account = self::get_account_for_actor( $uri ); - if ( $account ) { - return $account; - } - - return $user_data; - } - - /** - * Resolve internal accounts for Mastodon API - * - * @param Account $user_data The user data. - * @param string $user_id The user id. - * - * @return Account The filtered Account. - */ - public static function api_account_internal( $user_data, $user_id ) { - $user_id_to_use = self::maybe_map_user_to_blog( $user_id ); - $user = Actors::get_by_id( $user_id_to_use ); - - if ( ! $user || is_wp_error( $user ) ) { - return $user_data; - } - - // Convert user to account. - $account = new Account(); - // Even if we have a blog user, maintain the provided user_id so as not to confuse clients. - $account->id = (int) $user_id; - $account->username = $user->get_preferred_username(); - $account->acct = $account->username; - $account->display_name = $user->get_name(); - $account->note = $user->get_summary(); - $account->source['note'] = wp_strip_all_tags( $account->note, true ); - $account->url = $user->get_url(); - - $icon = $user->get_icon(); - $account->avatar = $icon['url']; - $account->avatar_static = $account->avatar; - - $header = $user->get_image(); - if ( $header ) { - $account->header = $header['url']; - $account->header_static = $account->header; - } - - $account->created_at = new DateTime( $user->get_published() ); - - $post_types = \get_option( 'activitypub_support_post_types', array( 'post' ) ); - $query_args = array( - 'post_type' => $post_types, - 'posts_per_page' => 1, - ); - if ( $user_id > 0 ) { - $query_args['author'] = $user_id; - } - $posts = \get_posts( $query_args ); - $account->last_status_at = ! empty( $posts ) ? new DateTime( $posts[0]->post_date_gmt ) : $account->created_at; - - $account->fields = self::get_extra_fields( $user_id_to_use ); - // Now do it in source['fields'] with stripped tags. - $account->source['fields'] = \array_map( - function ( $field ) { - $field['value'] = \wp_strip_all_tags( $field['value'], true ); - return $field; - }, - $account->fields - ); - - $account->followers_count = Followers::count_followers( $user->get__id() ); - - return $account; - } - - /** - * Use our representation of posts to power each status item. - * Includes proper referncing of 3rd party comments that arrived via federation. - * - * @param null|Status $status The status, typically null to allow later filters their shot. - * @param int $post_id The post ID. - * @return Status|null The status. - */ - public static function api_status( $status, $post_id ) { - $post = \get_post( $post_id ); - if ( ! $post ) { - return $status; - } - - return self::api_post_status( $post_id ); - } - - /** - * Transforms a WordPress post into a Mastodon-compatible status object. - * - * Takes a post ID, transforms it into an ActivityPub object, and converts - * it to a Mastodon API status format including the author's account info. - * - * @param int $post_id The WordPress post ID to transform. - * @return Status|null The Mastodon API status object, or null if the post is not found - */ - private static function api_post_status( $post_id ) { - $post = Factory::get_transformer( get_post( $post_id ) ); - if ( is_wp_error( $post ) ) { - return null; - } - - $data = $post->to_object()->to_array(); - $account = self::api_account_internal( null, get_post_field( 'post_author', $post_id ) ); - - return self::activity_to_status( $data, $account, $post_id ); - } - - /** - * Get account for actor. - * - * @param string $uri The URI. - * - * @return Account|null The account. - */ - private static function get_account_for_actor( $uri ) { - if ( ! is_string( $uri ) || empty( $uri ) ) { - return null; - } - $data = get_remote_metadata_by_actor( $uri ); - - if ( ! $data || is_wp_error( $data ) ) { - return null; - } - $account = new Account(); - - $acct = Webfinger_Util::uri_to_acct( $uri ); - if ( ! $acct || is_wp_error( $acct ) ) { - return null; - } - - if ( str_starts_with( $acct, 'acct:' ) ) { - $acct = substr( $acct, 5 ); - } - - $account->id = $acct; - $account->username = $acct; - $account->acct = $acct; - $account->display_name = $data['name']; - $account->url = $uri; - - if ( ! empty( $data['summary'] ) ) { - $account->note = $data['summary']; - } - - if ( - isset( $data['icon']['type'] ) && - isset( $data['icon']['url'] ) && - 'Image' === $data['icon']['type'] - ) { - $account->avatar = $data['icon']['url']; - $account->avatar_static = $data['icon']['url']; - } - - if ( isset( $data['image'] ) ) { - $account->header = $data['image']['url']; - $account->header_static = $data['image']['url']; - } - if ( ! isset( $data['published'] ) ) { - $data['published'] = 'now'; - } - $account->created_at = new DateTime( $data['published'] ); - - return $account; - } - - /** - * Search by URL for Mastodon API. - * - * @param array $search_data The search data. - * @param object $request The request object. - * - * @return array The filtered search data. - */ - public static function api_search_by_url( $search_data, $request ) { - $p = \wp_parse_url( $request->get_param( 'q' ) ); - if ( ! $p || ! isset( $p['host'] ) ) { - return $search_data; - } - - $object = Http::get_remote_object( $request->get_param( 'q' ), true ); - if ( is_wp_error( $object ) || ! isset( $object['attributedTo'] ) ) { - return $search_data; - } - - $account = self::get_account_for_actor( $object['attributedTo'] ); - if ( ! $account ) { - return $search_data; - } - - $status = self::activity_to_status( $object, $account ); - if ( $status ) { - $search_data['statuses'][] = $status; - } - - return $search_data; - } - - /** - * Search for Mastodon API. - * - * @param array $search_data The search data. - * @param object $request The request object. - * - * @return array The filtered search data. - */ - public static function api_search( $search_data, $request ) { - $user_id = \get_current_user_id(); - if ( ! $user_id ) { - return $search_data; - } - - $q = $request->get_param( 'q' ); - if ( ! $q ) { - return $search_data; - } - $q = sanitize_text_field( wp_unslash( $q ) ); - - $followers = Followers::get_followers( $user_id, 40, null, array( 's' => $q ) ); - if ( ! $followers ) { - return $search_data; - } - - foreach ( $followers as $follower ) { - $acct = Webfinger_Util::uri_to_acct( $follower->get_id() ); - - if ( $acct && ! is_wp_error( $acct ) ) { - $acct = \str_replace( 'acct:', '', $acct ); - } else { - $acct = $follower->get_url(); - } - - $account = new Account(); - $account->id = \strval( $follower->get__id() ); - $account->username = $follower->get_preferred_username(); - $account->acct = $acct; - $account->display_name = $follower->get_name(); - $account->url = $follower->get_url(); - $account->uri = $follower->get_id(); - $account->avatar = $follower->get_icon_url(); - $account->avatar_static = $follower->get_icon_url(); - $account->created_at = new DateTime( $follower->get_published() ); - $account->last_status_at = new DateTime( $follower->get_published() ); - $account->note = $follower->get_summary(); - $account->header = $follower->get_image_url(); - $account->header_static = $follower->get_image_url(); - - $search_data['accounts'][] = $account; - } - - return $search_data; - } - - /** - * Get posts query args for Mastodon API. - * - * @param array $args The query arguments. - * - * @return array The filtered args. - */ - public static function api_get_posts_query_args( $args ) { - if ( isset( $args['author'] ) && is_string( $args['author'] ) ) { - $uri = Webfinger_Util::resolve( $args['author'] ); - if ( $uri && ! is_wp_error( $uri ) ) { - $args['activitypub'] = $uri; - unset( $args['author'] ); - } - } - - return $args; - } - - /** - * Convert an activity to a status. - * - * @param array $item The activity. - * @param Account $account The account. - * @param int $post_id The post ID. Optional, but will be preferred in the Status. - * - * @return Status|null The status. - */ - private static function activity_to_status( $item, $account, $post_id = null ) { - if ( isset( $item['object'] ) ) { - $object = $item['object']; - } else { - $object = $item; - } - - if ( ! isset( $object['type'] ) || 'Note' !== $object['type'] || ! $account ) { - return null; - } - - $status = new Status(); - $status->id = $post_id ?? $object['id']; - $status->created_at = new DateTime( $object['published'] ); - $status->content = $object['content']; - $status->account = $account; - - if ( ! empty( $object['inReplyTo'] ) ) { - $status->in_reply_to_id = $object['inReplyTo']; - } - - if ( ! empty( $object['visibility'] ) ) { - $status->visibility = $object['visibility']; - } - if ( ! empty( $object['url'] ) ) { - $status->url = $object['url']; - $status->uri = $object['url']; - } else { - $status->uri = $object['id']; - } - - if ( ! empty( $object['attachment'] ) ) { - $status->media_attachments = array_map( - function ( $attachment ) { - $default_attachment = array( - 'url' => null, - 'mediaType' => null, - 'name' => null, - 'width' => 0, - 'height' => 0, - 'blurhash' => null, - ); - - $attachment = array_merge( $default_attachment, $attachment ); - - $media_attachment = new Media_Attachment(); - $media_attachment->id = $attachment['url']; - $media_attachment->type = strtok( $attachment['mediaType'], '/' ); - $media_attachment->url = $attachment['url']; - $media_attachment->preview_url = $attachment['url']; - $media_attachment->description = $attachment['name']; - if ( $attachment['blurhash'] ) { - $media_attachment->blurhash = $attachment['blurhash']; - } - if ( $attachment['width'] > 0 && $attachment['height'] > 0 ) { - $media_attachment->meta = array( - 'original' => array( - 'width' => $attachment['width'], - 'height' => $attachment['height'], - 'size' => $attachment['width'] . 'x' . $attachment['height'], - 'aspect' => $attachment['width'] / $attachment['height'], - ), - );} - return $media_attachment; - }, - $object['attachment'] - ); - } - - return $status; - } - - /** - * Get posts for Mastodon API. - * - * @param array $statuses The statuses. - * @param array $args The arguments. - * - * @return array The filtered statuses. - */ - public static function api_statuses_external( $statuses, $args ) { - if ( ! isset( $args['activitypub'] ) ) { - return $statuses; - } - - $data = get_remote_metadata_by_actor( $args['activitypub'] ); - - if ( ! $data || is_wp_error( $data ) || ! isset( $data['outbox'] ) ) { - return $statuses; - } - - $outbox = Http::get_remote_object( $data['outbox'], true ); - if ( is_wp_error( $outbox ) || ! isset( $outbox['first'] ) ) { - return $statuses; - } - - $account = self::get_account_for_actor( $args['activitypub'] ); - if ( ! $account ) { - return $statuses; - } - $limit = 10; - if ( isset( $args['posts_per_page'] ) ) { - $limit = $args['posts_per_page']; - } - if ( $limit > 40 ) { - $limit = 40; - } - $activitypub_statuses = array(); - $url = $outbox['first']; - $tries = 0; - while ( $url ) { - if ( ++$tries > 3 ) { - break; - } - - $posts = Http::get_remote_object( $url, true ); - if ( is_wp_error( $posts ) ) { - return $statuses; - } - - $new_statuses = array_map( - function ( $item ) use ( $account, $args ) { - if ( $args['exclude_replies'] ) { - if ( isset( $item['object']['inReplyTo'] ) && $item['object']['inReplyTo'] ) { - return null; - } - } - return self::activity_to_status( $item, $account ); - }, - $posts['orderedItems'] - ); - $activitypub_statuses = array_merge( $activitypub_statuses, array_filter( $new_statuses ) ); - $url = $posts['next'] ?? null; - - if ( count( $activitypub_statuses ) >= $limit ) { - break; - } - } - - return array_slice( $activitypub_statuses, 0, $limit ); - } - - /** - * Get replies for Mastodon API. - * - * @param array $context The context. - * @param int $post_id The post id. - * @param string $url The URL. - * - * @return array The filtered context. - */ - public static function api_get_replies( $context, $post_id, $url ) { - $meta = Http::get_remote_object( $url, true ); - if ( is_wp_error( $meta ) || ! isset( $meta['replies']['first']['next'] ) ) { - return $context; - } - - if ( ! empty( $meta['replies']['first']['items'] ) ) { - $replies = $meta['replies']['first']; - } elseif ( isset( $meta['replies']['first']['next'] ) ) { - $replies_url = $meta['replies']['first']['next']; - $replies = Http::get_remote_object( $replies_url, true ); - if ( is_wp_error( $replies ) || ! isset( $replies['items'] ) ) { - return $context; - } - } else { - return $context; - } - - foreach ( $replies['items'] as $reply ) { - if ( isset( $reply['id'] ) && is_string( $reply['id'] ) && isset( $reply['content'] ) && is_string( $reply['content'] ) ) { - $status = $reply; - } else { - if ( is_string( $reply ) ) { - $url = $reply; - } elseif ( isset( $reply['url'] ) && is_string( $reply['url'] ) ) { - $url = $reply['url']; - } else { - continue; - } - $response = Http::get( $url, true ); - if ( is_wp_error( $response ) || wp_remote_retrieve_response_code( $response ) !== 200 ) { - continue; - } - $status = json_decode( wp_remote_retrieve_body( $response ), true ); - if ( ! $status || is_wp_error( $status ) ) { - continue; - } - } - - $account = self::get_account_for_actor( $status['attributedTo'] ); - $status = self::activity_to_status( $status, $account ); - if ( $status ) { - $context['descendants'][ $status->id ] = $status; - } - } - - return $context; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-jetpack.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-jetpack.php deleted file mode 100644 index 5586cf79..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-jetpack.php +++ /dev/null @@ -1,54 +0,0 @@ -post_type ) { - \add_action( 'msls_main_save', '__return_null' ); - } - } - - /** - * Remove short-circuit for Multisite Language Switcher data. - * - * @param int $post_id The post id. - * @param WP_Post $post The post object. - */ - public static function unignore_outbox_post( $post_id, $post ) { - if ( Outbox::POST_TYPE === $post->post_type ) { - \remove_action( 'msls_main_save', '__return_null' ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-nodeinfo.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-nodeinfo.php deleted file mode 100644 index dfbedcbf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-nodeinfo.php +++ /dev/null @@ -1,89 +0,0 @@ -= '2.0' ) { - $nodeinfo['protocols'][] = 'activitypub'; - } else { - $nodeinfo['protocols']['inbound'][] = 'activitypub'; - $nodeinfo['protocols']['outbound'][] = 'activitypub'; - } - - $nodeinfo['usage']['users'] = array( - 'total' => get_total_users(), - 'activeMonth' => get_active_users(), - 'activeHalfyear' => get_active_users( 6 ), - ); - - return $nodeinfo; - } - - /** - * Extend NodeInfo2 data. - * - * @param array $nodeinfo NodeInfo2 data. - * - * @return array The extended array. - */ - public static function add_nodeinfo2_data( $nodeinfo ) { - $nodeinfo['protocols'][] = 'activitypub'; - - $nodeinfo['usage']['users'] = array( - 'total' => get_total_users(), - 'activeMonth' => get_active_users(), - 'activeHalfyear' => get_active_users( 6 ), - ); - - return $nodeinfo; - } - - /** - * Extend the well-known nodeinfo data. - * - * @param array $data The well-known nodeinfo data. - * - * @return array The extended array. - */ - public static function add_wellknown_nodeinfo_data( $data ) { - $data['links'][] = array( - 'rel' => 'https://www.w3.org/ns/activitystreams#Application', - 'href' => get_rest_url_by_path( 'application' ), - ); - - return $data; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-opengraph.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-opengraph.php deleted file mode 100644 index c22e2958..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-opengraph.php +++ /dev/null @@ -1,113 +0,0 @@ -get_webfinger(); - - return $metadata; - } - - if ( \is_author() ) { - // Use the Author of the Archive-Page. - $user_id = \get_queried_object_id(); - } elseif ( \is_singular() ) { - // Use the Author of the Post. - $user_id = \get_post_field( 'post_author', \get_queried_object_id() ); - } elseif ( ! is_user_type_disabled( 'blog' ) ) { - // Use the Blog-User for any other page, if the Blog-User is not disabled. - $user_id = Actors::BLOG_USER_ID; - } else { - // Do not add any metadata otherwise. - return $metadata; - } - - $user = Actors::get_by_id( $user_id ); - - if ( ! $user || \is_wp_error( $user ) ) { - return $metadata; - } - - // Add WebFinger resource. - $metadata['fediverse:creator'] = $user->get_webfinger(); - - return $metadata; - } - - /** - * Output Open Graph tags in the page header. - */ - public static function add_meta_tags() { - $metadata = apply_filters( 'opengraph_metadata', array() ); - foreach ( $metadata as $key => $value ) { - if ( empty( $key ) || empty( $value ) ) { - continue; - } - $value = (array) $value; - - foreach ( $value as $v ) { - printf( - '' . PHP_EOL, - esc_attr( $key ), - esc_attr( $v ) - ); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-seriously-simple-podcasting.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-seriously-simple-podcasting.php deleted file mode 100644 index 7533db98..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-seriously-simple-podcasting.php +++ /dev/null @@ -1,72 +0,0 @@ -item; - $attachment = array( - 'type' => \esc_attr( ucfirst( \get_post_meta( $post->ID, 'episode_type', true ) ?? 'Audio' ) ), - 'url' => \esc_url( \get_post_meta( $post->ID, 'audio_file', true ) ), - 'name' => \esc_attr( \get_the_title( $post->ID ) ?? '' ), - ); - - $icon = \get_post_meta( $post->ID, 'cover_image', true ); - if ( ! $icon ) { - $icon = $this->get_icon(); - } - - if ( $icon ) { - $attachment['icon'] = \esc_url( object_to_uri( $icon ) ); - } - - return array( $attachment ); - } - - /** - * Gets the object type for a podcast episode. - * - * Always returns 'Note' for the best possible compatibility with ActivityPub. - * - * @return string The object type. - */ - public function get_type() { - return 'Note'; - } - - /** - * Returns the content for the ActivityPub Item. - * - * The content will be generated based on the user settings. - * - * @return string The content. - */ - public function get_content() { - return generate_post_summary( $this->item ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-stream-connector.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-stream-connector.php deleted file mode 100644 index e59c6009..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-stream-connector.php +++ /dev/null @@ -1,250 +0,0 @@ - __( 'Processed', 'activitypub' ), - ); - } - - /** - * Add action links to Stream drop row in admin list screen - * - * @filter wp_stream_action_links_{connector} - * - * @param array $links Previous links registered. - * @param Record $record Stream record. - * - * @return array Action links - */ - public function action_links( $links, $record ) { - if ( 'processed' === $record->action ) { - $error = json_decode( $record->get_meta( 'error', true ), true ); - - if ( $error ) { - $message = sprintf( - '
%1$s
%2$s
', - __( 'Inbox Error', 'activitypub' ), - wp_json_encode( $error ) - ); - - $links[ $message ] = ''; - } - - $debug = json_decode( $record->get_meta( 'debug', true ), true ); - - if ( $debug ) { - $message = sprintf( - '
%1$s
%2$s
', - __( 'Debug', 'activitypub' ), - wp_json_encode( $debug ) - ); - - $links[ $message ] = ''; - } - } - - return $links; - } - - /** - * Callback for activitypub_notification_follow. - * - * @param \Activitypub\Notification $notification The notification object. - */ - public function callback_activitypub_notification_follow( $notification ) { - $this->log( - sprintf( - // translators: %s is a URL. - __( 'New Follower: %s', 'activitypub' ), - $notification->actor - ), - array( - 'notification' => \wp_json_encode( $notification, JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE ), - ), - null, - 'notification', - $notification->type, - $notification->target - ); - } - - /** - * Callback for activitypub_outbox_processing_complete. - * - * @param array $inboxes The inboxes. - * @param string $json The ActivityPub Activity JSON. - * @param int $actor_id The actor ID. - * @param int $outbox_item_id The Outbox item ID. - */ - public function callback_activitypub_outbox_processing_complete( $inboxes, $json, $actor_id, $outbox_item_id ) { - $outbox_item = \get_post( $outbox_item_id ); - $outbox_data = $this->prepare_outbox_data_for_response( $outbox_item ); - - $this->log( - sprintf( - // translators: %s is a URL. - __( 'Outbox processing complete: %s', 'activitypub' ), - $outbox_data['title'] - ), - array( - 'debug' => wp_json_encode( - array( - 'actor_id' => $actor_id, - 'outbox_item_id' => $outbox_item_id, - ) - ), - ), - $outbox_data['id'], - $outbox_data['type'], - 'processed' - ); - } - - /** - * Callback for activitypub_outbox_processing_batch_complete. - * - * @param array $inboxes The inboxes. - * @param string $json The ActivityPub Activity JSON. - * @param int $actor_id The actor ID. - * @param int $outbox_item_id The Outbox item ID. - * @param int $batch_size The batch size. - * @param int $offset The offset. - */ - public function callback_activitypub_outbox_processing_batch_complete( $inboxes, $json, $actor_id, $outbox_item_id, $batch_size, $offset ) { - $outbox_item = \get_post( $outbox_item_id ); - $outbox_data = $this->prepare_outbox_data_for_response( $outbox_item ); - - $this->log( - sprintf( - // translators: %s is a URL. - __( 'Outbox processing batch complete: %s', 'activitypub' ), - $outbox_data['title'] - ), - array( - 'debug' => wp_json_encode( - array( - 'actor_id' => $actor_id, - 'outbox_item_id' => $outbox_item_id, - 'batch_size' => $batch_size, - 'offset' => $offset, - ) - ), - ), - $outbox_data['id'], - $outbox_data['type'], - 'processed' - ); - } - - /** - * Get the title of the outbox object. - * - * @param \WP_Post $outbox_item The outbox item. - * - * @return array The title, object ID, and object type of the outbox object. - */ - protected function prepare_outbox_data_for_response( $outbox_item ) { - $object_id = $outbox_item->ID; - $object_type = $outbox_item->post_type; - $object_title = $outbox_item->post_title; - - $post_id = url_to_postid( $outbox_item->post_title ); - if ( $post_id ) { - $post = get_post( $post_id ); - - $object_id = $post_id; - $object_type = $post->post_type; - $object_title = $post->post_title; - } else { - $comment_id = url_to_commentid( $outbox_item->post_title ); - if ( $comment_id ) { - $comment = get_comment( $comment_id ); - - $object_id = $comment_id; - $object_type = 'comments'; - $object_title = $comment->comment_content; - } else { - $author_id = url_to_authorid( $outbox_item->post_title ); - if ( null !== $author_id ) { - $object_id = $author_id; - $object_type = 'profiles'; - - if ( $author_id ) { - $object_title = get_userdata( $author_id )->display_name; - } elseif ( Actors::BLOG_USER_ID === $author_id ) { - $object_title = __( 'Blog User', 'activitypub' ); - } elseif ( Actors::APPLICATION_USER_ID === $author_id ) { - $object_title = __( 'Application User', 'activitypub' ); - } - } - } - } - - return array( - 'id' => $object_id, - 'type' => $object_type, - 'title' => $object_title, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-webfinger.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-webfinger.php deleted file mode 100644 index 6b6ed537..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-webfinger.php +++ /dev/null @@ -1,119 +0,0 @@ -ID ); - - if ( ! $user || is_wp_error( $user ) ) { - return $jrd; - } - - $jrd['subject'] = sprintf( 'acct:%s', $user->get_webfinger() ); - - $jrd['aliases'][] = $user->get_id(); - $jrd['aliases'][] = $user->get_url(); - $jrd['aliases'][] = $user->get_alternate_url(); - $jrd['aliases'] = array_unique( $jrd['aliases'] ); - $jrd['aliases'] = array_values( $jrd['aliases'] ); - - $jrd['links'][] = array( - 'rel' => 'self', - 'type' => 'application/activity+json', - 'href' => $user->get_id(), - ); - - $jrd['links'][] = array( - 'rel' => 'http://ostatus.org/schema/1.0/subscribe', - 'template' => get_rest_url_by_path( 'interactions?uri={uri}' ), - ); - - return $jrd; - } - - /** - * Add WebFinger discovery links. - * - * @param array $jrd The jrd array. - * @param string $uri The WebFinger resource. - * - * @return array|\WP_Error The jrd array or WP_Error. - */ - public static function add_pseudo_user_discovery( $jrd, $uri ) { - $user = Actors::get_by_resource( $uri ); - - if ( \is_wp_error( $user ) ) { - return $user; - } - - $aliases = array( - $user->get_id(), - $user->get_url(), - $user->get_alternate_url(), - ); - - $aliases = array_unique( $aliases ); - $aliases = array_values( $aliases ); - - $profile = array( - 'subject' => sprintf( 'acct:%s', $user->get_webfinger() ), - 'aliases' => $aliases, - 'links' => array( - array( - 'rel' => 'self', - 'type' => 'application/activity+json', - 'href' => $user->get_id(), - ), - array( - 'rel' => 'http://webfinger.net/rel/profile-page', - 'type' => 'text/html', - 'href' => $user->get_id(), - ), - array( - 'rel' => 'http://ostatus.org/schema/1.0/subscribe', - 'template' => get_rest_url_by_path( 'interactions?uri={uri}' ), - ), - ), - ); - - if ( 'Person' !== $user->get_type() ) { - $profile['links'][0]['properties'] = array( - 'https://www.w3.org/ns/activitystreams#type' => $user->get_type(), - ); - } - - return $profile; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-wpml.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-wpml.php deleted file mode 100644 index 3bef729f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/class-wpml.php +++ /dev/null @@ -1,44 +0,0 @@ -ID ); - - if ( is_array( $language_details ) && isset( $language_details['language_code'] ) ) { - $lang = $language_details['language_code']; - } - - return $lang; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/load.php b/wp-content/upgrade-temp-backup/plugins/activitypub/integration/load.php deleted file mode 100644 index fcb75467..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/integration/load.php +++ /dev/null @@ -1,164 +0,0 @@ -ID, 'audio_file', true ) - ) { - return new Seriously_Simple_Podcasting( $data ); - } - return $transformer; - }, - 10, - 3 - ); - } - - /** - * Adds WPML Multilingual CMS (plugin) support. - * - * This class handles the compatibility with the WPML plugin. - * - * @see https://wpml.org/ - */ - if ( \defined( 'ICL_SITEPRESS_VERSION' ) ) { - WPML::init(); - } -} -\add_action( 'plugins_loaded', __NAMESPACE__ . '\plugin_init' ); - -/** - * Register the Stream Connector for ActivityPub. - * - * @param array $classes The Stream connectors. - * - * @return array The Stream connectors with the ActivityPub connector. - */ -function register_stream_connector( $classes ) { - $class = new Stream_Connector(); - - if ( method_exists( $class, 'is_dependency_satisfied' ) && $class->is_dependency_satisfied() ) { - $classes[] = $class; - } - - return $classes; -} -add_filter( 'wp_stream_connectors', __NAMESPACE__ . '\register_stream_connector' ); - -// Excluded ActivityPub post types from the Stream. -add_filter( - 'wp_stream_posts_exclude_post_types', - function ( $post_types ) { - $post_types[] = 'ap_follower'; - $post_types[] = 'ap_extrafield'; - $post_types[] = 'ap_extrafield_blog'; - return $post_types; - } -); - -/** - * Load the BuddyPress integration. - * - * Only load code that needs BuddyPress to run once BP is loaded and initialized. - * - * @see https://buddypress.org/ - */ -add_action( 'bp_include', array( __NAMESPACE__ . '\Buddypress', 'init' ), 0 ); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/readme.txt b/wp-content/upgrade-temp-backup/plugins/activitypub/readme.txt deleted file mode 100644 index 12be8545..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/readme.txt +++ /dev/null @@ -1,413 +0,0 @@ -=== ActivityPub === -Contributors: automattic, pfefferle, mattwiebe, obenland, akirk, jeherve, mediaformat, nuriapena, cavalierlife, andremenrath -Tags: OStatus, fediverse, activitypub, activitystream -Requires at least: 6.4 -Tested up to: 6.8 -Stable tag: 5.8.0 -Requires PHP: 7.2 -License: MIT -License URI: http://opensource.org/licenses/MIT - -The ActivityPub protocol is a decentralized social networking protocol based upon the ActivityStreams 2.0 data format. - -== Description == - -Enter the fediverse with **ActivityPub**, broadcasting your blog to a wider audience! Attract followers, deliver updates, and receive comments from a diverse user base of **ActivityPub**\-compliant platforms. - -https://www.youtube.com/watch?v=QzYozbNneVc - -With the ActivityPub plugin installed, your WordPress blog itself function as a federated profile, along with profiles for each author. For instance, if your website is `example.com`, then the blog-wide profile can be found at `@example.com@example.com`, and authors like Jane and Bob would have their individual profiles at `@jane@example.com` and `@bobz@example.com`, respectively. - -An example: I give you my Mastodon profile name: `@pfefferle@mastodon.social`. You search, see my profile, and hit follow. Now, any post I make appears in your Home feed. Similarly, with the ActivityPub plugin, you can find and follow Jane's profile at `@jane@example.com`. - -Once you follow Jane's `@jane@example.com` profile, any blog post she crafts on `example.com` will land in your Home feed. Simultaneously, by following the blog-wide profile `@example.com@example.com`, you'll receive updates from all authors. - -**Note**: If no one follows your author or blog instance, your posts remain unseen. The simplest method to verify the plugin's operation is by following your profile. If you possess a Mastodon profile, initiate by following your new one. - -The plugin works with the following tested federated platforms, but there may be more that it works with as well: - -* [Mastodon](https://joinmastodon.org/) -* [Pleroma](https://pleroma.social/)/[Akkoma](https://akkoma.social/) -* [friendica](https://friendi.ca/) -* [Hubzilla](https://hubzilla.org/) -* [Pixelfed](https://pixelfed.org/) -* [Socialhome](https://socialhome.network/) -* [Misskey](https://join.misskey.page/) - -Some things to note: - -1. The blog-wide profile is only compatible with sites with rewrite rules enabled. If your site does not have rewrite rules enabled, the author-specific profiles may still work. -1. Many single-author blogs have chosen to turn off or redirect their author profile pages, usually via an SEO plugin like Yoast or Rank Math. This is usually done to avoid duplicate content with your blog’s home page. If your author page has been deactivated in this way, then ActivityPub author profiles won’t work for you. Instead, you can turn your author profile page back on, and then use the option in your SEO plugin to noindex the author page. This will still resolve duplicate content issues with search engines and will enable ActivityPub author profiles to work. -1. Once ActivityPub is installed, *only new posts going forward* will be available in the fediverse. Likewise, even if you’ve been using ActivityPub for a while, anyone who follows your site will only see new posts you publish from that moment on. They will never see previously-published posts in their Home feed. This process is very similar to subscribing to a newsletter. If you subscribe to a newsletter, you will only receive future emails, but not the old archived ones. With ActivityPub, if someone follows your site, they will only receive new blog posts you publish from then on. - -So what’s the process? - -1. Install the ActivityPub plugin. -1. Go to the plugin’s settings page and adjust the settings to your liking. Click the Save button when ready. -1. Make sure your blog’s author profile page is active if you are using author profiles. -1. Go to Mastodon or any other federated platform, and search for your profile, and follow it. Your new profile will be in the form of either `@your_username@example.com` or `@example.com@example.com`, so that is what you’ll search for. -1. On your blog, publish a new post. -1. From Mastodon, check to see if the new post appears in your Home feed. - -**Note**: It may take up to 15 minutes or so for the new post to show up in your federated feed. This is because the messages are sent to the federated platforms using a delayed cron. This avoids breaking the publishing process for those cases where users might have lots of followers. So please don’t assume that just because you didn’t see it show up right away that something is broken. Give it some time. In most cases, it will show up within a few minutes, and you’ll know everything is working as expected. - -== Frequently Asked Questions == - -= tl;dr = - -This plugin connects your WordPress blog to popular social platforms like Mastodon, making your posts more accessible to a wider audience. Once installed, your blog can be followed by users on these platforms, allowing them to receive your new posts in their feeds. - -= What is "ActivityPub for WordPress" = - -*ActivityPub for WordPress* extends WordPress with some Fediverse features, but it does not compete with platforms like Friendica or Mastodon. If you want to run a **decentralized social network**, please use [Mastodon](https://joinmastodon.org/) or [GNU social](https://gnusocial.network/). - -= What if you are running your blog in a subdirectory? = - -In order for webfinger to work, it must be mapped to the root directory of the URL on which your blog resides. - -**Apache** - -Add the following to the .htaccess file in the root directory: - - RedirectMatch "^\/\.well-known/(webfinger|nodeinfo)(.*)$" /blog/.well-known/$1$2 - -Where 'blog' is the path to the subdirectory at which your blog resides. - -**Nginx** - -Add the following to the site.conf in sites-available: - - location ~* /.well-known { - allow all; - try_files $uri $uri/ /blog/?$args; - } - -Where 'blog' is the path to the subdirectory at which your blog resides. - -If you are running your blog in a subdirectory, but have a different [wp_siteurl](https://wordpress.org/documentation/article/giving-wordpress-its-own-directory/), you don't need the redirect, because the index.php will take care of that. - -= What if you are running your blog behind a reverse proxy with Apache? = - -If you are using a reverse proxy with Apache to run your host you may encounter that you are unable to have followers join the blog. This will occur because the proxy system rewrites the host headers to be the internal DNS name of your server, which the plugin then uses to attempt to sign the replies. The remote site attempting to follow your users is expecting the public DNS name on the replies. In these cases you will need to use the 'ProxyPreserveHost On' directive to ensure the external host name is passed to your internal host. - -If you are using SSL between the proxy and internal host you may also need to `SSLProxyCheckPeerName off` if your internal host can not answer with the correct SSL name. This may present a security issue in some environments. - -= Constants = - -The plugin uses PHP Constants to enable, disable or change its default behaviour. Please use them with caution and only if you know what you are doing. - -* `ACTIVITYPUB_REST_NAMESPACE` - Change the default Namespace of the REST endpoint. Default: `activitypub/1.0`. -* `ACTIVITYPUB_EXCERPT_LENGTH` - Change the length of the Excerpt. Default: `400`. -* `ACTIVITYPUB_SHOW_PLUGIN_RECOMMENDATIONS` - show plugin recommendations in the ActivityPub settings. Default: `true`. -* `ACTIVITYPUB_MAX_IMAGE_ATTACHMENTS` - Change the number of attachments, that should be federated. Default: `3`. -* `ACTIVITYPUB_HASHTAGS_REGEXP` - Change the default regex to detect hashtext in a text. Default: `(?:(?<=\s)|(?<=

)|(?<=
)|^)#([A-Za-z0-9_]+)(?:(?=\s|[[:punct:]]|$))`. -* `ACTIVITYPUB_USERNAME_REGEXP` - Change the default regex to detect @-replies in a text. Default: `(?:([A-Za-z0-9\._-]+)@((?:[A-Za-z0-9_-]+\.)+[A-Za-z]+))`. -* `ACTIVITYPUB_URL_REGEXP` - Change the default regex to detect urls in a text. Default: `(www.|http:|https:)+[^\s]+[\w\/]`. -* `ACTIVITYPUB_CUSTOM_POST_CONTENT` - Change the default template for Activities. Default: `[ap_title]\n\n[ap_content]\n\n[ap_hashtags]\n\n[ap_shortlink]`. -* `ACTIVITYPUB_AUTHORIZED_FETCH` - Enable AUTHORIZED_FETCH. -* `ACTIVITYPUB_DISABLE_REWRITES` - Disable auto generation of `mod_rewrite` rules. Default: `false`. -* `ACTIVITYPUB_DISABLE_INCOMING_INTERACTIONS` - Block incoming replies/comments/likes. Default: `false`. -* `ACTIVITYPUB_DISABLE_OUTGOING_INTERACTIONS` - Disable outgoing replies/comments/likes. Default: `false`. -* `ACTIVITYPUB_SHARED_INBOX_FEATURE` - Enable the shared inbox. Default: `false`. -* `ACTIVITYPUB_SEND_VARY_HEADER` - Enable to send the `Vary: Accept` header. Default: `false`. - -= Where can you manage your followers? = - -If you have activated the blog user, you will find the list of his followers in the settings under `/wp-admin/options-general.php?page=activitypub&tab=followers`. - -The followers of a user can be found in the menu under "Users" -> "Followers" or under `wp-admin/users.php?page=activitypub-followers-list`. - -For reasons of data protection, it is not possible to see the followers of other users. - -== Screenshots == - -1. The "Follow me"-Block in the Block-Editor -2. The "Followers"-Block in the Block-Editor -3. The "Federated Reply"-Block in the Block-Editor -4. A "Federated Reply" in a Post -5. A Blog-Profile on Mastodon - -== Changelog == - -### 5.8.0 - 2025-04-24 -#### Added -- An option to receive notification emails when an Actor was mentioned in the Fediverse. -- Enable direct linking to Help Tabs. -- Fallback embed support for Fediverse content that lacks native oEmbed responses. -- Support for all media types in the Mastodon Importer. - -#### Changed -- Added WordPress disallowed list filtering to block unwanted ActivityPub interactions. -- Mastodon imports now support blocks, with automatic reply embedding for conversations. -- Tested and compatible with the latest version of WordPress. -- Updated design of new follower notification email and added meta information. -- Update DM email notification to include an embed display of the DM. -- Updated notification settings to be user-specific for more personalization. - -#### Fixed -- Add support for Multisite Language Switcher -- Better check for an empty `headers` array key in the Signature class. -- Include user context in Global-Inbox actions. -- No more PHP warning when Mastodon Apps run out of posts to process. -- Reply links and popup modals are now properly translated for logged-out visitors. - -### 5.7.0 - 2025-04-11 -#### Added -- Advanced Settings tab, with special settings for advanced users. -- Check if pretty permalinks are enabled and recommend to use threaded comments. -- Reply block: show embeds where available. -- Support same-server domain migrations. -- Upgrade routine that removes any erroneously created extra field entries. - -#### Changed -- Add option to enable/disable the "shared inbox" to the "Advanced Settings". -- Add option to enable/disable the `Vary` Header to the "Advanced Settings". -- Configure the "Follow Me" button to have a button-only mode. -- Importers are loaded on admin-specific hook. -- Improve the troubleshooting UI and show Site-Health stats in ActivityPub settings. -- Increased compatibility with Mobilizon and other platforms by improving signature verification for different key formats. - -#### Fixed -- Ensure that an `Activity` has an `Actor` before adding it to the Outbox. -- Fixed some bugs and added additional information on the Debug tab of the Site-Health page. -- Follow-up to the reply block changes that makes sure Mastodon embeds are displayed in the editor. -- Outbox endpoint bug where non-numeric usernames caused errors when querying Outbox data. -- Show Site Health error if site uses old "Almost Pretty Permalinks" structure. -- Sites with comments from the Fediverse no longer create uncached extra fields posts that flood the Outbox. -- Transformers allow settings values to false again, a regression from 5.5.0. - -### 5.6.1 - 2025-04-02 -#### Fixed -- "Post Interactions" settings will now be saved to the options table. -- So not show `movedTo` attribute instead of setting it to `false` if empty. -- Use specified date format for `updated` field in Outbox-Activites. - -### 5.6.0 - 2025-04-01 -#### Added -- Added a Mastodon importer to move your Mastodon posts to your WordPress site. -- A default Extra-Field to do a little advertising for WordPress. -- Move: Differentiate between `internal` and 'external' Move. -- Redirect user to the welcome page after ActivityPub plugin is activated. -- The option to show/hide the "Welcome Page". -- User setting to enable/disable Likes and Reblogs - -#### Changed -- Logged-out remote reply button markup to look closer to logged-in version. -- No longer federates `Delete` activities for posts that were not federated. -- OrderedCollection and OrderedCollectionPage behave closer to spec now. -- Outbox items now contain the full activity, not just activity objects. -- Standardized mentions to use usernames only in comments and posts. - -#### Fixed -- Changelog entries: allow automating changelog entry generation from forks as well. -- Comments from Fediverse actors will now be purged as expected. -- Importing attachments no longer creates Outbox items for them. -- Improved readability in Mastodon Apps plugin string. -- No more PHP warnings when previewing posts without attachments. -- Outbox batch processing adheres to passed batch size. -- Permanently delete reactions that were `Undo` instead of trashing them. -- PHP warnings when scheduling post activities for an invalid post. -- PHP Warning when there's no actor information in comment activities. -- Prevent self-replies on local comments. -- Properly set `to` audience of `Activity` instead of changing the `Follow` Object. -- Run all Site-Health checks with the required headers and a valid signature. -- Set `updated` field for profile updates, otherwise the `Update`-`Activity` wouldn't be handled by Mastodon. -- Support multiple layers of nested Outbox activities when searching for the Object ID. -- The Custom-Avatar getter on WP.com. -- Use the $from account for the object in Move activity for external Moves -- Use the `$from` account for the object in Move activity for internal Moves -- Use `add_to_outbox` instead of the changed scheduler hooks. -- Use `JSON_UNESCAPED_SLASHES` because Mastodon seems to have problems with encoded URLs. -- `Scheduler::schedule_announce_activity` to handle Activities instead of Activity-Objects. - -### 5.5.0 - 2025-03-19 -#### Added -- Added "Enable Mastodon Apps" and "Event Bridge for ActivityPub" to the recommended plugins section. -- Added Constants to the Site-Health debug informations. -- Development environment: add Changelogger tool to environment dependencies. -- Development environment: allow contributors to specify a changelog entry directly from their Pull Request description. -- Documentation for migrating from a Mastodon instance to WordPress. -- Support for sending Activities to ActivityPub Relays, to improve discoverability of public content. - -#### Changed -- Documentation: expand Pull Request process docs, and mention the new changelog process as well as the updated release process. -- Don't redirect @-name URLs to trailing slashed versions -- Improved and simplified Query code. -- Improved readability for actor mode setting. -- Improved title case for NodeInfo settings. -- Introduced utility function to determine actor type based on user ID. -- Outbox items only get sent to followers when there are any. -- Restricted modifications to settings if they are predefined as constants. -- The Welcome page now uses WordPress's Settings API and the classic design of the WP Admin. -- Uses two-digit version numbers in Outbox and NodeInfo responses. - -#### Removed -- Our version of `sanitize_url()` was unused—use Core's `sanitize_url()` instead. - -#### Fixed -- Ensured that Query::get_object_id() returns an ID instead of an Object. -- Fix a fatal error in the Preview when a post contains no (hash)tags. -- Fixed an issue with the Content Carousel and Blog Posts block: https://github.com/Automattic/wp-calypso/issues/101220 -- Fixed default value for `activitypub_authorized_fetch` option. -- Follow-Me blocks now show the correct avatar on attachment pages. -- Images with the correct aspect ratio no longer get sent through the crop step again. -- No more PHP warnings when a header image gets cropped. -- PHP warnings when trying to process empty tags or image blocks without ID attributes. -- Properly re-added support for `Update` and `Delete` `Announce`ments. -- Updates to certain user meta fields did not trigger an Update activity. -- When viewing Reply Contexts, we'll now attribute the post to the blog user when the post author is disabled. - -### 5.4.1 - 2025-03-04 -#### Fixed -- Fixed transition handling of posts to ensure that `Create` and `Update` activities are properly processed. -- Show "full content" preview even if post is in still in draft mode. - -### 5.4.0 - 2025-03-03 -#### Added -- Upgrade script to fix Follower json representations with unescaped backslashes. -- Centralized place for sanitization functions. - -#### Changed -- Bumped minimum required WordPress version to 6.4. -- Use a later hook for Posts to get published to the Outbox, to get sure all `post_meta`s and `taxonomy`s are set stored properly. -- Use webfinger as author email for comments from the Fediverse. -- Remove the special handling of comments from Enable Mastodon Apps. - -#### Fixed -- Do not redirect `/@username` URLs to the API any more, to improve `AUTHORIZED_FETCH` handling. - -### 5.3.2 - 2025-02-27 -#### Fixed -- Remove `activitypub_reply_block` filter after Activity-JSON is rendered, to not affect the HTML representation. -- Remove `render_block_core/embed` filter after Activity-JSON is rendered, to not affect the HTML representation. - -### 5.3.1 - 2025-02-26 -#### Fixed -- Blog profile settings can be saved again without errors. -- Followers with backslashes in their descriptions no longer break their actor representation. - -### 5.3.0 - 2025-02-25 -#### Added -- A fallback `Note` for `Article` objects to improve previews on services that don't support Articles yet. -- A reply `context` for Posts and Comments to allow relying parties to discover the whole conversation of a thread. -- Setting to adjust the number of days Outbox items are kept before being purged. -- Failed Follower notifications for Outbox items now get retried for two more times. -- Undo API for Outbox items. -- Metadata to New Follower E-Mail. -- Allow Activities on URLs instead of requiring Activity-Objects. This is useful especially for sending Announces and Likes. -- Outbox Activity IDs can now be resolved when the ActivityPub `Accept header is used. -- Support for incoming `Move` activities and ensure that followed persons are updated accordingly. -- Labels to add context to visibility settings in the block editor. -- WP CLI command to reschedule Outbox-Activities. - -#### Changed -- Outbox now precesses the first batch of followers right away to avoid delays in processing new Activities. -- Post bulk edits no longer create Outbox items, unless author or post status change. -- Properly process `Update` activities on profiles and ensure all properties of a followed person are updated accordingly. -- Outbox processing accounts for shared inboxes again. -- Improved check for `?activitypub` query-var. -- Rewrite rules: be more specific in author rewrite rules to avoid conflicts on sites that use the "@author" pattern in their permalinks. -- Deprecate the `activitypub_post_locale` filter in favor of the `activitypub_locale` filter. - -#### Fixed -- The Outbox purging routine no longer is limited to deleting 5 items at a time. -- Ellipses now display correctly in notification emails for Likes and Reposts. -- Send Update-Activity when "Actor-Mode" is changed. -- Added delay to `Announce` Activity from the Blog-Actor, to not have race conditions. -- `Actor` validation in several REST API endpoints. -- Bring back the `activitypub_post_locale` filter to allow overriding the post's locale. - -### 5.2.0 - 2025-02-13 -#### Added -- Batch Outbox-Processing. -- Outbox processed events get logged in Stream and show any errors returned from inboxes. -- Outbox items older than 6 months will be purged to avoid performance issues. -- REST API endpoints for likes and shares. - -#### Changed -- Increased probability of Outbox items being processed with the correct author. -- Enabled querying of Outbox posts through the REST API to improve troubleshooting and debugging. -- Updated terminology to be client-neutral in the Federated Reply block. - -#### Fixed -- Fixed an issue where the outbox could not send object types other than `Base_Object` (introduced in 5.0.0). -- Enforce 200 status header for valid ActivityPub requests. -- `object_id_to_comment` returns a commment now, even if there are more than one matching comment in the DB. -- Integration of content-visibility setup in the block editor. -- Update CLI commands to the new scheduler refactorings. -- Do not add an audience to the Actor-Profiles. -- `Activity::set_object` falsely overwrites the Activity-ID with a default. - -### 5.1.0 - 2025-02-06 -#### Added -- Cleanup of option values when the plugin is uninstalled. -- Third-party plugins can filter settings tabs to add their own settings pages for ActivityPub. -- Show ActivityPub preview in row actions when Block Editor is enabled but not used for the post type. - -#### Changed -- Manually granting `activitypub` cap no longer requires the receiving user to have `publish_post`. -- Allow omitting replies in ActivityPub representations instead of setting them as empty. -- Allow Base Transformer to handle WP_Term objects for transformation. -- Improved Query extensibility for third party plugins. - -#### Fixed -- Negotiation of ActivityPub requests for custom post types when queried by the ActivityPub ID. -- Avoid PHP warnings when using Debug mode and when the `actor` is not set. -- No longer creates Outbox items when importing content/users. -- Fix NodeInfo 2.0 URL to be HTTP instead of HTTPS. - -### 5.0.0 - 2025-02-03 -#### Changed -- Improved content negotiation and AUTHORIZED_FETCH support for third-party plugins. -- Moved password check to `is_post_disabled` function. - -#### Fixed -- Handle deletes from remote servers that leave behind an accessible Tombstone object. -- No longer parses tags for post types that don't support Activitypub. -- rel attribute will now contain no more than one "me" value. - -See full Changelog on [GitHub](https://github.com/Automattic/wordpress-activitypub/blob/trunk/CHANGELOG.md). - -== Upgrade Notice == - -= 5.4.0 = - -Note: This update requires WordPress 6.4+. Please ensure your site meets this requirement before upgrading. - -== Installation == - -Follow the normal instructions for [installing WordPress plugins](https://wordpress.org/support/article/managing-plugins/). - -= Automatic Plugin Installation = - -To add a WordPress Plugin using the [built-in plugin installer](https://codex.wordpress.org/Administration_Screens#Add_New_Plugins): - -1. Go to [Plugins](https://codex.wordpress.org/Administration_Screens#Plugins) > [Add New](https://codex.wordpress.org/Plugins_Add_New_Screen). -1. Type "`activitypub`" into the **Search Plugins** box. -1. Find the WordPress Plugin you wish to install. - 1. Click **Details** for more information about the Plugin and instructions you may wish to print or save to help setup the Plugin. - 1. Click **Install Now** to install the WordPress Plugin. -1. The resulting installation screen will list the installation as successful or note any problems during the install. -1. If successful, click **Activate Plugin** to activate it, or **Return to Plugin Installer** for further actions. - -= Manual Plugin Installation = - -There are a few cases when manually installing a WordPress Plugin is appropriate. - -* If you wish to control the placement and the process of installing a WordPress Plugin. -* If your server does not permit automatic installation of a WordPress Plugin. -* If you want to try the [latest development version](https://github.com/pfefferle/wordpress-activitypub). - -Installation of a WordPress Plugin manually requires FTP familiarity and the awareness that you may put your site at risk if you install a WordPress Plugin incompatible with the current version or from an unreliable source. - -Backup your site completely before proceeding. - -To install a WordPress Plugin manually: - -* Download your WordPress Plugin to your desktop. - * Download from [the WordPress directory](https://wordpress.org/plugins/activitypub/) - * Download from [GitHub](https://github.com/pfefferle/wordpress-activitypub/releases) -* If downloaded as a zip archive, extract the Plugin folder to your desktop. -* With your FTP program, upload the Plugin folder to the `wp-content/plugins` folder in your WordPress directory online. -* Go to [Plugins screen](https://codex.wordpress.org/Administration_Screens#Plugins) and find the newly uploaded Plugin in the list. -* Click **Activate** to activate it. diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/activitypub-json.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/activitypub-json.php deleted file mode 100644 index 036a99b8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/activitypub-json.php +++ /dev/null @@ -1,25 +0,0 @@ -get_activitypub_object(); - -/** - * Fires before an ActivityPub object is generated and sent to the client. - * - * @param object $object The ActivityPub object. - */ -\do_action( 'activitypub_json_pre', $object ); - -\header( 'Content-Type: application/activity+json' ); -echo $object->to_json(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped - -/** - * Fires after an ActivityPub object is generated and sent to the client. - * - * @param object $object The ActivityPub object. - */ -\do_action( 'activitypub_json_post', $object ); diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/admin-header.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/admin-header.php deleted file mode 100644 index 0c655dca..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/admin-header.php +++ /dev/null @@ -1,34 +0,0 @@ - -

-
-

-
- - -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/advanced-settings.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/advanced-settings.php deleted file mode 100644 index 47c1e84c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/advanced-settings.php +++ /dev/null @@ -1,16 +0,0 @@ - - -
-
- - - -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-followers-list.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-followers-list.php deleted file mode 100644 index 74273630..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-followers-list.php +++ /dev/null @@ -1,25 +0,0 @@ -get_user_count(); -// translators: The follower count. -$followers_template = _n( 'Your blog profile currently has %s follower.', 'Your blog profile currently has %s followers.', $follower_count, 'activitypub' ); -?> -
-

- -
- - - prepare_items(); - $table->search_box( 'Search', 'search' ); - $table->display(); - ?> -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-settings.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-settings.php deleted file mode 100644 index 078c7d0c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/blog-settings.php +++ /dev/null @@ -1,16 +0,0 @@ - - -
-
- - - -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/emails/new-dm.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/emails/new-dm.php deleted file mode 100644 index a0dd32d8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/emails/new-dm.php +++ /dev/null @@ -1,49 +0,0 @@ - - -

-

- ' . esc_html( $args['actor']['webfinger'] ) . '' ); - ?> -

- -
- -
- - - -

- -

- -

- ' . esc_html( $args['webfinger'] ) . '' ); - ?> -

- -
- -
- - -
- - <?php echo esc_attr( $args['name'] ); ?> - -
-

- - -

- - - -
- -
- ' . esc_html( number_format_i18n( $args['stats']['outbox'] ) ) . '' - ); - ?> -
- - -
- ' . esc_html( number_format_i18n( $args['stats']['followers'] ) ) . '' - ); - ?> -
- - -
- ' . esc_html( number_format_i18n( $args['stats']['following'] ) ) . '' - ); - ?> -
- -
- -
-
-
- -

- - - -

- -

- followers list to see all followers.', 'activitypub' ), array( 'a' => array( 'href' => array() ) ) ), - esc_url( admin_url( $args['admin_url'] ) ) - ); - ?> -

- - - -

- -

- -

- ' . esc_html( $args['actor']['webfinger'] ) . '' ); - ?> -

- -
- -
- -

- - - -

- - - - diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/emails/parts/header.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/emails/parts/header.php deleted file mode 100644 index 6ea7e471..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/emails/parts/header.php +++ /dev/null @@ -1,60 +0,0 @@ - - - -
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/post-preview.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/post-preview.php deleted file mode 100644 index f88e82db..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/post-preview.php +++ /dev/null @@ -1,265 +0,0 @@ -get_error_message() ), - 404 - ); -} - -$object = $transformer->to_object(); -$user = $transformer->get_actor_object(); - -?> - - - - - <?php echo esc_html( $object->get_name() ); ?> - - - -
- -
-

- Home -

-
-
- <?php echo esc_attr( $user->get_name() ); ?> -
-
- get_name() ); ?> -
-
- get_webfinger() ); ?> -
-
-
-
- get_type() && $object->get_name() ) : ?> -

get_name() ); ?>

- - get_type() ? $object->get_summary() : $object->get_content(), ACTIVITYPUB_MASTODON_HTML_SANITIZER ); ?> -
- get_attachment() ) : ?> -
- get_attachment() as $attachment ) : ?> - - <?php echo esc_attr( $attachment['name'] ?? '' ); ?> - - -
- - get_tag() ) : ?> -
- get_tag() as $hashtag ) : ?> - - - - -
- -
-
- -
- - diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/reply-embed.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/reply-embed.php deleted file mode 100644 index a948195b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/reply-embed.php +++ /dev/null @@ -1,81 +0,0 @@ - '', - 'author_name' => '', - 'author_url' => '', - 'title' => '', - 'content' => '', - 'image' => '', - 'published' => '', - 'url' => '', - 'boosts' => null, - 'favorites' => null, - 'webfinger' => '', - ) -); - -\wp_enqueue_style( 'activitypub-embed', ACTIVITYPUB_PLUGIN_URL . 'assets/css/activitypub-embed.css', array(), ACTIVITYPUB_PLUGIN_VERSION ); -?> - -
-
- - - -
-

- - - -
-
- -
- -

- - - -
- - - -
- -
- -
- -
- - - - - - - ' . \esc_html( \number_format_i18n( $args['boosts'] ) ) . '' ); - ?> - - - - - - ' . \esc_html( \number_format_i18n( $args['favorites'] ) ) . '' ); - ?> - - -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/settings.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/settings.php deleted file mode 100644 index e4a61c96..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/settings.php +++ /dev/null @@ -1,16 +0,0 @@ - - -
-
- - - -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/toolbox.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/toolbox.php deleted file mode 100644 index 19fa797d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/toolbox.php +++ /dev/null @@ -1,78 +0,0 @@ - - -
-

-

- -

-
-

-

-

- - - - -

-
-

- -

-

- -

-

-
- -
-

-

-

-

-

- - - - - - - - - - - - - - - - - -
- - - -
in_reply_to
post_type
-

-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/user-followers-list.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/user-followers-list.php deleted file mode 100644 index 1bf0ca29..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/user-followers-list.php +++ /dev/null @@ -1,26 +0,0 @@ - -
-

-

- - - -
- - prepare_items(); - $table->search_box( 'Search', 'search' ); - $table->display(); - ?> -
-
diff --git a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/welcome.php b/wp-content/upgrade-temp-backup/plugins/activitypub/templates/welcome.php deleted file mode 100644 index 35782a90..00000000 --- a/wp-content/upgrade-temp-backup/plugins/activitypub/templates/welcome.php +++ /dev/null @@ -1,12 +0,0 @@ - - -
- -
diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin-styles.css b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin-styles.css deleted file mode 100644 index 583d74ef..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin-styles.css +++ /dev/null @@ -1,640 +0,0 @@ -@charset "UTF-8"; - -@keyframes ai-spin { - 0% { - transform: rotate(0deg); - } - - 100% { - transform: rotate(360deg); - } -} - -@keyframes backgroundPosition { - 0% { - background-position: -140px 0; - } - - 100% { - background-position: 140px 0; - } -} - -.sr-only { - position: absolute; - width: 1px; - height: 1px; - padding: 0; - margin: -1px; - overflow: hidden; - clip: rect(0, 0, 0, 0); - border: 0; -} - -.ai-row { - margin-left: -15px; - margin-right: -15px; - box-sizing: border-box; -} - -.ai-row::after { - content: ""; - display: table; - clear: both; -} - -[class^="ai-col"] { - float: left; - padding-left: 15px; - padding-right: 15px; - width: 50%; - box-sizing: border-box; -} - -.ai-btn { - display: inline-block; - font-weight: normal; - margin: 0; - line-height: normal; - border: 0; - box-shadow: none; - text-align: center; - vertical-align: middle; - cursor: pointer; - white-space: nowrap; - -ms-user-select: none; - user-select: none; - border-radius: 2px; - width: auto; - height: auto; - background-image: none; - padding: 11px 20px 11px; - font-size: 12px; - text-transform: uppercase; - background-color: #1c4866; - color: #ffffff; - text-decoration: none; -} - -.ai-btn:hover, -.ai-btn:focus { - color: #ffffff; - background-color: #173a52; -} - -.ai-btn-green { - background-color: #14b552; -} - -.ai-btn-green:hover, -.ai-btn-green:focus { - color: #ffffff; - background-color: #119e48; -} - -.ai-brand-module { - background-color: #1c4866; - padding: 15px; - color: #ffffff; - font-size: 12px; -} - -.ai-brand-module p { - font-size: 12px; -} - -.ai-brand-module a:not(.ai-btn) { - color: #ffcc00; - text-decoration: none; -} - -.ai-brand-module-actions { - text-align: right; -} - -.ai-brand-module-actions p { - margin: 0; -} - -.ai-header { - margin: 12px 0 -12px; - height: 40px; -} - -.ai-header-actions { - text-align: right; -} - -.ai-logo { - display: inline-block; - position: relative; - top: -2px; -} - -.ai-logo img { - height: 44px; -} - -.ai-note { - font-style: italic; -} - -.ai-list-inline { - margin: 0; - padding: 0; - list-style: none; -} - -.ai-list-inline li { - display: inline-block; - margin: 0; -} - -.ai-footer-links a::after { - content: "\007c"; - color: #ffffff; - opacity: .5; - margin: 0 7px; -} - -.ai-footer-links li:last-child a::after { - display: none; -} - -.ai-module { - border: 1px solid #eeeeee; - margin-top: 12px; - padding: 15px; -} - -.ai-module::after { - content: ""; - display: table; - clear: both; -} - -.ai-container { - margin-top: 12px; -} - -.ai-field-controls-wrap { - padding: 15px; - border: 1px solid #eeeeee; -} - -.ai-field-controls-wrap::after { - content: ""; - display: table; - clear: both; -} - -.ai-field-controls { - float: left; -} - -.ai-field-controls .button { - margin-right: 5px; -} - -.ai-field-controls-visibility { - float: right; - padding-top: 4px; -} - -.ai-field-controls-visibility a { - text-decoration: none; -} - -.ai-fields-expand-all { - margin-right: 8px; - padding-right: 6px; - border-right: 1px solid #f1f1f1; -} - -.ai-fields-container { - padding: 15px; - border-left: 1px solid #eeeeee; - border-right: 1px solid #eeeeee; -} - -.ai-field-repeatable { - margin-bottom: 15px; - border: 1px solid #d7d7d7; - box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.07); -} - -.ai-field-repeatable:last-child { - margin-bottom: 0; -} - -.ai-field-repeatable:only-child .ai-remove-field { - display: none; -} - -.ai-field-container { - padding: 15px; - background-color: #ffffff; -} - -.ai-field-container::after { - content: ""; - display: table; - clear: both; -} - -.ai-field-container-links { - display: flex; - grid-gap: 20px; -} - -.ai-field-container-links .ai-field-split { - width: 50%; - float: none; -} - -.ai-field-head { - padding: 8px 15px 5px; - line-height: normal; - background-color: #d7d7d7; - background: linear-gradient(to bottom, #f1f1f1, #d7d7d7); - border-bottom: 1px solid #cccccc; -} - -.ai-field-head::after { - content: ""; - display: table; - clear: both; -} - -.ai-field-head .toggle-indicator { - border-radius: 50%; -} - -.ai-fields-sortable .ai-field-head { - cursor: move; -} - -.ai-field-sort-handle { - position: relative; - top: 1px; - color: #0073aa; -} - -.ai-field-sort-handle .dashicons { - font-size: 18px; -} - -.ai-field-title { - font-weight: bold; - font-size: 1.05em; - margin-left: 8px; - padding-top: 3px; - white-space: nowrap; - text-overflow: ellipsis; - overflow: hidden; - max-width: 80%; - display: inline-block; -} - -.ai-field-toggle { - float: right; -} - -.ai-field-cover { - float: left; - width: 100px; - height: 100px; - margin-right: 15px; - background-color: #eeeeee; - border: 1px solid #cccccc; -} - -.ai-field-split { - float: left; - width: calc(50% - 71px); - margin-right: 15px; -} - -.ai-field-split:nth-child(2n + 1) { - margin-right: 0; -} - -.ai-container .button .dashicons, -.ai-module .button .dashicons { - font-size: 1.2em; - line-height: 1.7em; -} - -.ai-form-field-group { - padding: 15px; - border: 1px solid #f1f1f1; - margin-bottom: 15px; -} - -.ai-form-field-group :last-child { - margin-bottom: 0; -} - -.ai-form-field-group-title { - margin-top: 0; -} - -.ai-form-field { - margin-bottom: 15px; -} - -.ai-form-field label { - display: inline-block; - font-weight: bold; - margin-bottom: 3px; -} - -.ai-form-field input[type="text"], -.ai-form-field input[type="url"], -.ai-form-field input[type="search"], -.ai-form-field input[type="email"], -.ai-form-field input[type="password"], -.ai-form-field input[type="number"], -.ai-form-field input[type="tel"], -.ai-form-field input[type="date"], -.ai-form-field textarea, -.ai-form-field select { - width: 100%; -} - -.ai-form-field input[type="checkbox"], -.ai-form-field input[type="radio"] { - display: inline-block; - position: relative; - top: 1px; -} - -.ai-module-settings .ai-form-field input[type="text"], -.ai-module-settings .ai-form-field input[type="url"], -.ai-module-settings .ai-form-field input[type="search"], -.ai-module-settings .ai-form-field input[type="email"], -.ai-module-settings .ai-form-field input[type="password"], -.ai-module-settings .ai-form-field input[type="number"], -.ai-module-settings .ai-form-field input[type="tel"], -.ai-module-settings .ai-form-field input[type="date"], -.ai-module-settings .ai-form-field textarea, -.ai-module-settings .ai-form-field select { - width: 200px; - max-width: 100%; - display: block; -} - -.ai-form-field-addon { - position: relative; -} - -.ai-form-field-addon input { - padding-right: 80px; -} - -.ai-form-field-addon button { - position: absolute; - top: 0; - right: -2px; -} - -.ai-field-help { - margin: 5px 0 0; - font-style: italic; - color: #999; -} - -.ai-form-field-checkbox-secondary { - margin-top: 7px; -} - -.ai-remove-field { - float: right; -} - -.ai-field-upload-cover { - display: block; - position: relative; - width: 100px; - height: 100px; - text-decoration: none; - color: initial; - overflow: hidden; -} - -.ai-field-upload-cover img { - max-width: 100%; - display: none; -} - -.ai-has-cover .ai-remove-cover { - display: block; -} - -.ai-has-cover .ai-field-cover-placeholder { - display: none; -} - -.ai-has-cover img { - display: inline-block; -} - -.ai-field-cover-placeholder { - text-align: center; - font-style: normal; - font-size: .9em; - opacity: .8; - padding-top: 28px; -} - -.ai-field-cover-placeholder::before { - content: ""; - display: inline-block; - font: 400 20px/1 dashicons; - speak: none; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - text-decoration: none !important; - display: block; -} - -.ai-track-loading .ai-field-cover-placeholder::before { - content: "\f463"; - animation: rotation 1.2s infinite linear; -} - -.ai-remove-cover { - color: #ffffff; - background-color: #ff0000; - width: 16px; - height: 16px; - font-size: 12px; - cursor: pointer; - position: absolute; - top: 0; - right: 0; - opacity: .9; - transition: opacity 0.18s ease-in; - display: none; - text-align: center; -} - -.ai-remove-cover:hover { - opacity: 1; -} - -.ai-remove-cover .dashicons { - font-size: 16px; - width: 100%; - height: 100%; -} - -.ai-remove-all-fields .dashicons, -.ai-remove-field .dashicons { - color: #ff0000; -} - -.ai-add-field-batch .dashicons, -.ai-add-field .dashicons { - color: #0073aa; -} - -.ai-info-box { - background: #fffce6; - color: #948832; - font-size: 12px; - border: solid 1px #eeeac9; - padding: 15px; - margin: 0 0 15px 0; -} - -.ai-player-type-message { - display: none; -} - -.ai-drop-placeholder { - background-color: #f1f1f1; - border: 2px dashed #cccccc; - opacity: 0.5; - margin-bottom: 15px; -} - -.ai-collapsed .ai-field-container { - display: none; -} - -.ai-collapsed .toggle-indicator::before { - content: "\f140" !important; -} - -.ai-module-shortcode .code { - display: block; - width: 100%; - margin-top: 3px; - padding: 10px 10px 8px; - font-weight: bold; - background: #f1f1f1; -} - -.ai-sync-soundcloud.button { - display: none; -} - -.ai-sync-soundcloud.button::before { - content: "\f463"; - color: #d54e21; - display: inline-block; - font: 400 19px/1 dashicons; - speak: none; - position: relative; - left: -1px; - top: 4px; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; - vertical-align: top; -} - -.ai-track-loading .ai-sync-soundcloud.button::before { - animation: rotation 1.2s infinite linear; -} - -.ai-soundcloud-track .ai-sync-soundcloud { - display: inline-block; -} - -.ai-soundcloud-track .ai-upload { - display: none; -} - -@media (max-width: 1100px) { - .ai-field-controls, - .ai-field-controls-visibility { - margin: 0; - float: none; - width: 100%; - } - - .ai-field-controls { - margin-bottom: 5px; - } - - .ai-field-container-links { - display: block; - } - - .ai-field-container-links .ai-field-split, - .ai-field-split { - float: none; - width: 100%; - } - - .ai-field-cover { - margin-bottom: 15px; - } - - .ai-footer { - text-align: center; - } - - .ai-footer .ai-brand-module-actions { - text-align: center; - margin-top: 10px; - } - - .ai-footer [class^="ai-col"] { - width: 100%; - } -} - -@media (max-width: 782px) { - .ai-container .button .dashicons, - .ai-module .button .dashicons { - line-height: 1.2em; - } - - .ai-form-field-addon .button { - top: 2px; - } -} - -@media (max-width: 600px) { - .ai-field-controls .button { - width: 100%; - } - - .ai-header { - text-align: center; - } - - .ai-header .ai-brand-module-actions { - margin-top: 10px; - } - - .ai-header .ai-btn { - display: block; - } - - .ai-header [class^="ai-col"] { - width: 100%; - } -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin-styles.min.css b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin-styles.min.css deleted file mode 100644 index 71afa9a5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin-styles.min.css +++ /dev/null @@ -1 +0,0 @@ -@charset "UTF-8";@keyframes ai-spin{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}@keyframes backgroundPosition{0%{background-position:-140px 0}100%{background-position:140px 0}}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.ai-row{margin-left:-15px;margin-right:-15px;box-sizing:border-box}.ai-row::after{content:"";display:table;clear:both}[class^=ai-col]{float:left;padding-left:15px;padding-right:15px;width:50%;box-sizing:border-box}.ai-btn{display:inline-block;font-weight:400;margin:0;line-height:normal;border:0;box-shadow:none;text-align:center;vertical-align:middle;cursor:pointer;white-space:nowrap;-ms-user-select:none;user-select:none;border-radius:2px;width:auto;height:auto;background-image:none;padding:11px 20px 11px;font-size:12px;text-transform:uppercase;background-color:#1c4866;color:#fff;text-decoration:none}.ai-btn:focus,.ai-btn:hover{color:#fff;background-color:#173a52}.ai-btn-green{background-color:#14b552}.ai-btn-green:focus,.ai-btn-green:hover{color:#fff;background-color:#119e48}.ai-brand-module{background-color:#1c4866;padding:15px;color:#fff;font-size:12px}.ai-brand-module p{font-size:12px}.ai-brand-module a:not(.ai-btn){color:#fc0;text-decoration:none}.ai-brand-module-actions{text-align:right}.ai-brand-module-actions p{margin:0}.ai-header{margin:12px 0 -12px;height:40px}.ai-header-actions{text-align:right}.ai-logo{display:inline-block;position:relative;top:-2px}.ai-logo img{height:44px}.ai-note{font-style:italic}.ai-list-inline{margin:0;padding:0;list-style:none}.ai-list-inline li{display:inline-block;margin:0}.ai-footer-links a::after{content:"\007c";color:#fff;opacity:.5;margin:0 7px}.ai-footer-links li:last-child a::after{display:none}.ai-module{border:1px solid #eee;margin-top:12px;padding:15px}.ai-module::after{content:"";display:table;clear:both}.ai-container{margin-top:12px}.ai-field-controls-wrap{padding:15px;border:1px solid #eee}.ai-field-controls-wrap::after{content:"";display:table;clear:both}.ai-field-controls{float:left}.ai-field-controls .button{margin-right:5px}.ai-field-controls-visibility{float:right;padding-top:4px}.ai-field-controls-visibility a{text-decoration:none}.ai-fields-expand-all{margin-right:8px;padding-right:6px;border-right:1px solid #f1f1f1}.ai-fields-container{padding:15px;border-left:1px solid #eee;border-right:1px solid #eee}.ai-field-repeatable{margin-bottom:15px;border:1px solid #d7d7d7;box-shadow:1px 1px 2px rgba(0,0,0,.07)}.ai-field-repeatable:last-child{margin-bottom:0}.ai-field-repeatable:only-child .ai-remove-field{display:none}.ai-field-container{padding:15px;background-color:#fff}.ai-field-container::after{content:"";display:table;clear:both}.ai-field-container-links{display:flex;grid-gap:20px}.ai-field-container-links .ai-field-split{width:50%;float:none}.ai-field-head{padding:8px 15px 5px;line-height:normal;background-color:#d7d7d7;background:linear-gradient(to bottom,#f1f1f1,#d7d7d7);border-bottom:1px solid #ccc}.ai-field-head::after{content:"";display:table;clear:both}.ai-field-head .toggle-indicator{border-radius:50%}.ai-fields-sortable .ai-field-head{cursor:move}.ai-field-sort-handle{position:relative;top:1px;color:#0073aa}.ai-field-sort-handle .dashicons{font-size:18px}.ai-field-title{font-weight:700;font-size:1.05em;margin-left:8px;padding-top:3px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;max-width:80%;display:inline-block}.ai-field-toggle{float:right}.ai-field-cover{float:left;width:100px;height:100px;margin-right:15px;background-color:#eee;border:1px solid #ccc}.ai-field-split{float:left;width:calc(50% - 71px);margin-right:15px}.ai-field-split:nth-child(2n+1){margin-right:0}.ai-container .button .dashicons,.ai-module .button .dashicons{font-size:1.2em;line-height:1.7em}.ai-form-field-group{padding:15px;border:1px solid #f1f1f1;margin-bottom:15px}.ai-form-field-group :last-child{margin-bottom:0}.ai-form-field-group-title{margin-top:0}.ai-form-field{margin-bottom:15px}.ai-form-field label{display:inline-block;font-weight:700;margin-bottom:3px}.ai-form-field input[type=date],.ai-form-field input[type=email],.ai-form-field input[type=number],.ai-form-field input[type=password],.ai-form-field input[type=search],.ai-form-field input[type=tel],.ai-form-field input[type=text],.ai-form-field input[type=url],.ai-form-field select,.ai-form-field textarea{width:100%}.ai-form-field input[type=checkbox],.ai-form-field input[type=radio]{display:inline-block;position:relative;top:1px}.ai-module-settings .ai-form-field input[type=date],.ai-module-settings .ai-form-field input[type=email],.ai-module-settings .ai-form-field input[type=number],.ai-module-settings .ai-form-field input[type=password],.ai-module-settings .ai-form-field input[type=search],.ai-module-settings .ai-form-field input[type=tel],.ai-module-settings .ai-form-field input[type=text],.ai-module-settings .ai-form-field input[type=url],.ai-module-settings .ai-form-field select,.ai-module-settings .ai-form-field textarea{width:200px;max-width:100%;display:block}.ai-form-field-addon{position:relative}.ai-form-field-addon input{padding-right:80px}.ai-form-field-addon button{position:absolute;top:0;right:-2px}.ai-field-help{margin:5px 0 0;font-style:italic;color:#999}.ai-form-field-checkbox-secondary{margin-top:7px}.ai-remove-field{float:right}.ai-field-upload-cover{display:block;position:relative;width:100px;height:100px;text-decoration:none;color:initial;overflow:hidden}.ai-field-upload-cover img{max-width:100%;display:none}.ai-has-cover .ai-remove-cover{display:block}.ai-has-cover .ai-field-cover-placeholder{display:none}.ai-has-cover img{display:inline-block}.ai-field-cover-placeholder{text-align:center;font-style:normal;font-size:.9em;opacity:.8;padding-top:28px}.ai-field-cover-placeholder::before{content:"";display:inline-block;font:400 20px/1 dashicons;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-decoration:none!important;display:block}.ai-track-loading .ai-field-cover-placeholder::before{content:"\f463";animation:rotation 1.2s infinite linear}.ai-remove-cover{color:#fff;background-color:red;width:16px;height:16px;font-size:12px;cursor:pointer;position:absolute;top:0;right:0;opacity:.9;transition:opacity .18s ease-in;display:none;text-align:center}.ai-remove-cover:hover{opacity:1}.ai-remove-cover .dashicons{font-size:16px;width:100%;height:100%}.ai-remove-all-fields .dashicons,.ai-remove-field .dashicons{color:red}.ai-add-field .dashicons,.ai-add-field-batch .dashicons{color:#0073aa}.ai-info-box{background:#fffce6;color:#948832;font-size:12px;border:solid 1px #eeeac9;padding:15px;margin:0 0 15px 0}.ai-player-type-message{display:none}.ai-drop-placeholder{background-color:#f1f1f1;border:2px dashed #ccc;opacity:.5;margin-bottom:15px}.ai-collapsed .ai-field-container{display:none}.ai-collapsed .toggle-indicator::before{content:"\f140"!important}.ai-module-shortcode .code{display:block;width:100%;margin-top:3px;padding:10px 10px 8px;font-weight:700;background:#f1f1f1}.ai-sync-soundcloud.button{display:none}.ai-sync-soundcloud.button::before{content:"\f463";color:#d54e21;display:inline-block;font:400 19px/1 dashicons;speak:none;position:relative;left:-1px;top:4px;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;vertical-align:top}.ai-track-loading .ai-sync-soundcloud.button::before{animation:rotation 1.2s infinite linear}.ai-soundcloud-track .ai-sync-soundcloud{display:inline-block}.ai-soundcloud-track .ai-upload{display:none}@media (max-width:1100px){.ai-field-controls,.ai-field-controls-visibility{margin:0;float:none;width:100%}.ai-field-controls{margin-bottom:5px}.ai-field-container-links{display:block}.ai-field-container-links .ai-field-split,.ai-field-split{float:none;width:100%}.ai-field-cover{margin-bottom:15px}.ai-footer{text-align:center}.ai-footer .ai-brand-module-actions{text-align:center;margin-top:10px}.ai-footer [class^=ai-col]{width:100%}}@media (max-width:782px){.ai-container .button .dashicons,.ai-module .button .dashicons{line-height:1.2em}.ai-form-field-addon .button{top:2px}}@media (max-width:600px){.ai-field-controls .button{width:100%}.ai-header{text-align:center}.ai-header .ai-brand-module-actions{margin-top:10px}.ai-header .ai-btn{display:block}.ai-header [class^=ai-col]{width:100%}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin/settings.css b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin/settings.css deleted file mode 100644 index 8af5559c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin/settings.css +++ /dev/null @@ -1,44 +0,0 @@ -/* General */ - -.ai-settings-box { - background-color: #ffffff; - padding: 25px; - border: 1px solid #D8D8D8; - box-shadow: 0px 2px 0px rgba(0, 0, 0, 0.04); -} - -.ai-settings-box > :last-child { - margin-bottom: 0; -} - -/* Header / Nav */ - -.ai-settings-main-content-nav-header { - margin: 15px 0 40px; - display: flex; - align-items: center; -} - -.ai-settings-main-content-nav { - display: flex; - grid-gap: 20px; -} - -.ai-settings-main-content-nav-link { - color: #646970; - text-decoration: none; - font-size: 16px; -} - -.ai-settings-main-content-nav-link.is-active { - font-weight: 700; -} - -.ai-settings-main-content-nav-link.is-active, -.ai-settings-main-content-nav-link:hover { - color: #1D2327; -} - -.ai-settings-main-content-nav-filters { - margin-left: auto; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin/settings.min.css b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin/settings.min.css deleted file mode 100644 index bc7acbab..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/css/admin/settings.min.css +++ /dev/null @@ -1 +0,0 @@ -.ai-settings-box{background-color:#fff;padding:25px;border:1px solid #d8d8d8;box-shadow:0 2px 0 rgba(0,0,0,.04)}.ai-settings-box>:last-child{margin-bottom:0}.ai-settings-main-content-nav-header{margin:15px 0 40px;display:flex;align-items:center}.ai-settings-main-content-nav{display:flex;grid-gap:20px}.ai-settings-main-content-nav-link{color:#646970;text-decoration:none;font-size:16px}.ai-settings-main-content-nav-link.is-active{font-weight:700}.ai-settings-main-content-nav-link.is-active,.ai-settings-main-content-nav-link:hover{color:#1d2327}.ai-settings-main-content-nav-filters{margin-left:auto} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/images/logo.svg b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/images/logo.svg deleted file mode 100644 index f2722937..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/images/logo.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/images/vc_icon.png b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/images/vc_icon.png deleted file mode 100644 index 5d44eb65..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/images/vc_icon.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/js/audioigniter.js b/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/js/audioigniter.js deleted file mode 100644 index 3c115e5d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/assets/js/audioigniter.js +++ /dev/null @@ -1,560 +0,0 @@ -/* eslint-env browser, jquery */ -/* eslint-disable prefer-arrow-callback, prefer-template, func-names, no-var, object-shorthand, no-alert */ -/* global wp ai_scripts */ - -jQuery(function($) { - // Return early if ai_scripts are not available - if (!ai_scripts) { - // eslint-disable-line camelcase - return; - } - - // eslint-disable-next-line vars-on-top - var AudioIgniter = (function() { - var el = { - $trackContainer: $(".ai-fields-container"), - trackFieldClassName: ".ai-field-repeatable", - $addTrackButtonTop: $(".ai-add-field-top"), - $addTrackButtonBottom: $(".ai-add-field-bottom"), - removeFieldButtonClassName: ".ai-remove-field", - $removeAllTracksButton: $(".ai-remove-all-fields"), - $batchUploadButton: $(".ai-add-field-batch"), - $trackDownloadUsesTrackUrlButton: $(".ai-use-track-url-download"), - audioUploadButtonClassName: ".ai-upload", - coverUploadButtonClassName: ".ai-field-upload-cover", - coverRemoveClassName: ".ai-remove-cover", - fieldTitleClassName: ".ai-field-title", - trackTitleClassName: ".ai-track-title", - trackArtistClassName: ".ai-track-artist", - trackLyricsClassName: ".ai-track-lyrics", - trackUrlClassName: ".ai-track-url", - trackDownloadUrlClassName: ".ai-track-download-url", - trackDownloadUsesTrackUrlClassName: ".ai-track-download-uses-track-url", - hasCoverClass: "ai-has-cover", - fieldHeadClassName: ".ai-field-head", - fieldCollapsedClass: "ai-collapsed", - $expandAllButton: $(".ai-fields-expand-all"), - $collapseAllButton: $(".ai-fields-collapse-all"), - $shortcodeInputField: $("#ai_shortcode"), - soundCloudTrackClass: "ai-soundcloud-track" - }; - - /** - * Generate a rfc4122 version 4 compliant UUID - * http://stackoverflow.com/a/2117523 - * - * @returns {string} - UUID - */ - function uuid() { - return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, function( - c - ) { - var r = (Math.random() * 16) | 0; - var v = c === "x" ? r : (r & 0x3) | 0x8; - return v.toString(16); - }); - } - - /** - * Check if field is collapsed - * - * @param {Object} $field - jQuery object - * @returns {*|boolean} - */ - function isFieldCollapsed($field) { - return $field.hasClass(el.fieldCollapsedClass); - } - - /** - * Collapse a field - * - * @param {Object} $field - jQuery object - */ - function collapseField($field) { - $field.addClass(el.fieldCollapsedClass); - } - - /** - * Expand a field - * - * @param {Object} $field - jQuery object - */ - function expandField($field) { - $field.removeClass(el.fieldCollapsedClass); - } - - /** - * Resets the cover image placeholder state - * - * @param {Object} $field - the remove button jQuery object - */ - function resetCoverImage($field) { - var $coverWrap = $field.find("." + el.hasCoverClass); - - $coverWrap - .removeClass(el.hasCoverClass) - .find("img") - .attr("src", "") - .attr("alt", ""); - $coverWrap - .parent() - .find("input") - .val(""); - } - - /** - * Resets a form field - * - Clears input values - * - Clears thumbnail - * - * @param {object} $field - the field's jQuery object - * @param {string} [hash] - UUID or random hash - */ - function resetField($field, hash) { - var fieldHash = $field.data("uid"); - var newHash = hash || uuid(); - - $field.attr("data-uid", newHash); - $field - .find("input, textarea, select") - .not(":button") - .each(function() { - var $this = $(this); - $this.attr("id", $this.attr("id").replace(fieldHash, newHash)); - $this.attr("name", $this.attr("name").replace(fieldHash, newHash)); - $this.val(""); - }); - $field.find("label").each(function() { - var $this = $(this); - $this.attr("for", $this.attr("for").replace(fieldHash, newHash)); - }); - $field.find(el.fieldTitleClassName).text(""); - $field.removeClass(el.soundCloudTrackClass); - expandField($field); - resetCoverImage($field); - } - - /** - * Checks if a track field is clear of values - * - * @param {object} $field - Track field jQuery object - * @returns {boolean} - */ - function isTrackFieldEmpty($field) { - var isEmpty = true; - var $inputs = $field.find("input"); - $inputs.each(function() { - if ($(this).val()) { - isEmpty = false; - } - }); - - return isEmpty; - } - - /** - * Gets the first field from $trackContainer - * and appends it back after resetting it - * - * @param {string} [hash] - UUID or random hash - * @param {jQuery} [$container] - A jQuery element as the container - * - * return {Object} - jQuery object - */ - function getNewTrackField(hash, $container) { - var newHash = hash || uuid(); - var $parent = $container || el.$trackContainer; - - var $clone = $parent - .find(el.trackFieldClassName) - .first() - .clone() - .hide() - .show(); - resetField($clone, newHash); - - return $clone; - } - - /** - * Removes an element (or many) from the DOM - * by fading it out first - * - * @param {Object} $el - jQuery object of the element(s) to be removed - * @param {Function} [callback] - Optional callback - */ - function removeElement($el, callback) { - $el.fadeOut("fast", function() { - $(this).remove(); - - if (callback && typeof callback === "function") { - callback(); - } - }); - } - - /** - * Populates a track field - * - * @param {Object} $field - The field's jQuery object - * @param {Object} media - WP Media Manager media object - */ - function populateTrackField($field, media) { - var $urlInput = $field.find(el.trackUrlClassName); - var $titleInput = $field.find(el.trackTitleClassName); - var $artistInput = $field.find(el.trackArtistClassName); - var $fieldTitle = $field.find(el.fieldTitleClassName); - - if (media.url) { - $urlInput.val(media.url); - } - - if (media.title && $titleInput.val() === "") { - $titleInput.val(media.title); - $fieldTitle.text(media.title); - } - - if (media.meta && media.meta.artist && $artistInput.val() === "") { - $artistInput.val(media.meta.artist); - } - } - - /** - * Sets a cover image for the field - * - * @param $field - The field's jQuery object - * @param {Object} cover - Cover object - * @param {number} cover.id - Image ID - * @param {string} cover.url - Image URL - * @param {string} [cover.alt] - Image alt text - */ - function setTrackFieldCover($field, cover) { - var $coverField = $field.find(el.coverUploadButtonClassName); - - if (!cover || !cover.url || !cover.id) { - return; - } - - $coverField - .find("img") - .attr("src", cover.url) - .attr("alt", cover.alt || ""); - - $coverField - .addClass(el.hasCoverClass) - .siblings("input") - .val(cover.id); - } - - /** - * Initializes the WordPress Media Manager - * - * @param {Object} opts - Options object - * @param {string} opts.handler - Handler identifier of the media frame, - * this allows multiple media manager frames with different functionalities - * @param {string} [opts.type] - Filter media manager by type (audio, image etc) - * @param {string} [opts.title=Select Media] - Title of the media manager frame - * @param {boolean} [opts.multiple=false] - Accept multiple selections - * @param {Function} [opts.onMediaSelect] - Do something after media selection - */ - function wpMediaInit(opts) { - if (!opts.handler) { - throw new Error("Missing `handler` option"); - } - - /* eslint-disable */ - var multiple = opts.multiple || false; - var title = opts.title || "Select media"; - var mediaManager = wp.media.frames[opts.handler]; - /* eslint-enable */ - - if (mediaManager) { - mediaManager.open(); - return; - } - - mediaManager = wp.media({ - title: title, - multiple: multiple, - library: { - type: opts.type - } - }); - - mediaManager.open(); - - mediaManager.on("select", function() { - var attachments; - var attachmentModels = mediaManager.state().get("selection"); - - if (multiple) { - attachments = attachmentModels.map(function(attachment) { - return attachment.toJSON(); - }); - } else { - attachments = attachmentModels.first().toJSON(); - } - - if (opts.onMediaSelect && typeof opts.onMediaSelect === "function") { - opts.onMediaSelect(attachments); - } - }); - } - - /** - * Collapsible bindings - */ - el.$trackContainer.on("click", el.fieldHeadClassName, function(e) { - var $this = $(this); - var $parentField = $this.parents(el.trackFieldClassName); - - if (isFieldCollapsed($parentField)) { - expandField($parentField); - } else { - collapseField($parentField); - } - - e.preventDefault(); - }); - - el.$expandAllButton.on("click", function(e) { - var $this = $(this); - var $container = $this - .closest(".ai-container") - .find(".ai-fields-container"); - - expandField($container.find(el.trackFieldClassName)); - e.preventDefault(); - }); - - el.$collapseAllButton.on("click", function(e) { - var $this = $(this); - var $container = $this - .closest(".ai-container") - .find(".ai-fields-container"); - - collapseField($container.find(el.trackFieldClassName)); - e.preventDefault(); - }); - - /** - * Field control bindings - * (Add, remove buttons etc) - */ - - /* Bind track title to title input value */ - el.$trackContainer.on("keyup", el.trackTitleClassName, function() { - var $this = $(this); - var $fieldTitle = $this - .parents(el.trackFieldClassName) - .find(el.fieldTitleClassName); - $fieldTitle.text($this.val()); - }); - - /* Add Field Top */ - el.$addTrackButtonTop.on("click", function() { - var $this = $(this); - var $container = $this - .closest(".ai-container") - .find(".ai-fields-container"); - $container.prepend(getNewTrackField(undefined, $container)); - }); - - /* Add Field Bottom */ - el.$addTrackButtonBottom.on("click", function() { - var $this = $(this); - var $container = $this - .closest(".ai-container") - .find(".ai-fields-container"); - - $container.append(getNewTrackField(undefined, $container)); - }); - - /* Remove Track */ - el.$trackContainer.on("click", el.removeFieldButtonClassName, function() { - var $this = $(this); - removeElement($this.parents(".ai-field-repeatable")); - }); - - /* Remove All Tracks */ - el.$removeAllTracksButton.on("click", function() { - var $this = $(this); - var $container = $this - .closest(".ai-container") - .find(".ai-fields-container"); - var $trackFields = $container.find(el.trackFieldClassName); - - if (window.confirm(ai_scripts.messages.confirm_clear_tracks)) { - if ($trackFields.length > 1) { - removeElement($trackFields.slice(1)); - resetField($trackFields); - } else { - resetField($trackFields); - } - } - }); - - /** - * Bind media uploaders - */ - - /* Audio upload */ - el.$trackContainer.on("click", el.audioUploadButtonClassName, function() { - var $this = $(this); - var $parentTrackField = $this.parents(el.trackFieldClassName); - - wpMediaInit({ - handler: "ai-audio", - title: ai_scripts.messages.media_title_upload, - type: "audio", - onMediaSelect: function(media) { - populateTrackField($parentTrackField, media); - } - }); - }); - - /** - * Cover image upload - * - * Element `coverUploadButtonClassName` *must* have - * an `img` and `coverRemoveClassName` elements - * as children - */ - el.$trackContainer - .on("click", el.coverUploadButtonClassName, function(e) { - var $this = $(this); - - wpMediaInit({ - handler: "ai-cover", - title: ai_scripts.messages.media_title_upload_cover, - type: "image", - onMediaSelect: function(media) { - setTrackFieldCover($this.parents(el.trackFieldClassName), { - id: media.id, - url: media.sizes.thumbnail - ? media.sizes.thumbnail.url - : media.sizes.full.url, - alt: media.alt - }); - } - }); - - e.preventDefault(); - }) - /* Remove Image */ - .on("click", el.coverRemoveClassName, function(e) { - var $this = $(this); - resetCoverImage($this.parents(el.trackFieldClassName)); - e.stopPropagation(); - e.preventDefault(); - }); - - /** - * Hide / show options based on player type - * - * Different player types support different kind of options. - * E.g. "Simple Player" doesn't support tracklist height, etc. - */ - var $settingsWrap = $(".ai-module-settings"); - var $typeSelect = $(".ai-form-select-player-type"); - - function getUnsupportedSettings($el) { - var settingsString = $el.data("no-support"); - - if (typeof settingsString !== "string") { - return []; - } - - return settingsString - .replace(/\s/g, "") // remove all whitespace - .split(",") - .map(function(x) { - return "_audioigniter_" + x; - }); - } - - function filterUIBasedOnPlayerType($el) { - var type = $el.val(); - - // Reset styles - var $shortcodeMetaBox = $("#ai-meta-box-shortcode"); - var $messageBox = $(".ai-player-type-message"); - var info = $el.data("info"); - - $shortcodeMetaBox.show(); - - if (info) { - $messageBox.text(info).show(); - } else { - $messageBox.text("").hide(); - } - - // Player specific controls - switch (type) { - case "global-footer": - $shortcodeMetaBox.hide(); - break; - default: - return; - } - } - - function filterSettings() { - var $formFields; - var $type = $typeSelect.find(":selected"); - var unsupportedSettings = getUnsupportedSettings($type); - - filterUIBasedOnPlayerType($type); - - if (unsupportedSettings.length === 0) { - $formFields = $settingsWrap.find(".ai-form-field"); - $formFields.show(); - return; - } - - $settingsWrap.find("input", "select", "textarea").each(function() { - var $this = $(this); - var $parent = $this.parents(".ai-form-field"); - if (unsupportedSettings.indexOf($this.attr("name")) > -1) { - $parent.hide(); - } else { - $parent.show(); - } - }); - } - - filterSettings(); - $typeSelect.on("change", filterSettings); - - /** - * Shortcode select on click - */ - el.$shortcodeInputField.on("click", function() { - $(this).select(); - }); - - /** - * Export public methods and variables - */ - return { - elements: el, - uuid: uuid, - collapseField: collapseField, - expandField: expandField, - isFieldCollapsed: isFieldCollapsed, - isTrackFieldEmpty: isTrackFieldEmpty, - resetField: resetField, - resetCoverImage: resetCoverImage, - getNewTrackField: getNewTrackField, - removeElement: removeElement, - populateTrackField: populateTrackField, - setTrackFieldCover: setTrackFieldCover, - wpMediaInit: wpMediaInit - }; - })(); - - // Expose the AudioIgniter instance as a global - if (!window.AudioIgniter) { - window.AudioIgniter = AudioIgniter; - } -}); diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/audioigniter.php b/wp-content/upgrade-temp-backup/plugins/audioigniter/audioigniter.php deleted file mode 100644 index e1cdcf91..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/audioigniter.php +++ /dev/null @@ -1,1422 +0,0 @@ -. - * - */ - -if ( ! defined( 'ABSPATH' ) ) { - exit; -} - - -class AudioIgniter { - - /** - * AudioIgniter version. - * - * @var string - * @since 1.0.0 - * @since 1.7.0 Changed from static to non-static. - */ - public $version = null; - - /** - * Instance of this class. - * - * @var AudioIgniter - * @since 1.0.0 - */ - protected static $instance = null; - - /** - * Sanitizer instance. - * - * @var AudioIgniter_Sanitizer - * @since 1.0.0 - */ - public $sanitizer = null; - - /** - * The URL directory path (with trailing slash) of the main plugin file. - * - * @var string - * @since 1.0.0 - */ - protected static $plugin_url = ''; - - /** - * The filesystem directory path (with trailing slash) of the main plugin file. - * - * @var string - * @since 1.0.0 - */ - protected static $plugin_path = ''; - - - /** - * Playlist post type name. - * - * @var string - * @since 1.0.0 - */ - public $post_type = 'ai_playlist'; - - - - /** - * AudioIgniter Instance. - * - * Instantiates or reuses an instance of AudioIgniter. - * - * @since 1.0.0 - * @static - * @see AudioIgniter() - * @return AudioIgniter - Single instance. - */ - public static function instance() { - if ( is_null( self::$instance ) ) { - self::$instance = new self(); - } - return self::$instance; - } - - - /** - * AudioIgniter constructor. Intentionally left empty so that instances can be created without - * re-loading of resources (e.g. scripts/styles), or re-registering hooks. - * http://wordpress.stackexchange.com/questions/70055/best-way-to-initiate-a-class-in-a-wp-plugin - * https://gist.github.com/toscho/3804204 - * - * @since 1.0.0 - */ - public function __construct() {} - - /** - * Kickstarts plugin loading. - * - * @since 1.0.0 - */ - public function plugin_setup() { - if ( is_null( $this->version ) ) { - if ( ! function_exists( 'get_plugin_data' ) ) { - include_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - $plugin_data = get_plugin_data( __FILE__, true, false ); - - $this->version = $plugin_data['Version']; - } - - self::$plugin_url = plugin_dir_url( __FILE__ ); - self::$plugin_path = plugin_dir_path( __FILE__ ); - - add_action( 'init', function() { - load_plugin_textdomain( 'audioigniter', false, dirname( self::plugin_basename() ) . '/languages' ); - } ); - - require_once untrailingslashit( $this->plugin_path() ) . '/inc/class-audioigniter-sanitizer.php'; - $this->sanitizer = new AudioIgniter_Sanitizer(); - -// if ( ! class_exists( 'AudioIgniter_Pro', false ) ) { -// require_once untrailingslashit( $this->plugin_path() ) . '/inc/class-audioigniter-admin-page-upsell.php'; -// new AudioIgniter_Admin_Page_Upsell(); -// } - - // Initialization needed in every request. - $this->init(); - - // Initialization needed in admin requests. - $this->admin_init(); - - // Initialization needed in frontend requests. - $this->frontend_init(); - - do_action( 'audioigniter_loaded' ); - } - - /** - * Registers actions that need to be run on both admin and frontend - * - * @since 1.0.0 - */ - protected function init() { - add_action( 'init', array( $this, 'register_post_types' ) ); - add_action( 'init', array( $this, 'register_scripts' ) ); - add_action( 'init', array( $this, 'register_playlist_endpoint' ) ); - add_action( 'init', array( $this, 'register_image_sizes' ) ); - add_action( 'init', array( $this, 'register_shortcodes' ) ); - add_action( 'widgets_init', array( $this, 'register_widgets' ) ); - - do_action( 'audioigniter_init' ); - } - - - /** - * Registers actions that need to be run on admin only. - * - * @since 1.0.0 - */ - protected function admin_init() { - if ( ! is_admin() ) { - return; - } - - add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_admin_scripts' ) ); - add_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) ); - add_action( 'save_post', array( $this, 'save_post' ) ); - - add_filter( "manage_{$this->post_type}_posts_columns", array( $this, 'filter_posts_columns' ) ); - add_action( "manage_{$this->post_type}_posts_custom_column", array( $this, 'add_custom_columns' ), 10, 2 ); - - do_action( 'audioigniter_admin_init' ); - } - - /** - * Registers actions that need to be run on frontend only. - * - * @since 1.0.0 - */ - protected function frontend_init() { - if ( is_admin() ) { - return; - } - - add_action( 'wp_enqueue_scripts', array( $this, 'enqueue_scripts' ) ); - add_action( 'template_redirect', array( $this, 'handle_playlist_endpoint' ) ); - - do_action( 'audioigniter_frontend_init' ); - } - - /** - * Register (but not enqueue) all scripts and styles to be used throughout the plugin. - * - * @since 1.0.0 - */ - public function register_scripts() { - wp_register_style( 'audioigniter', untrailingslashit( $this->plugin_url() ) . '/player/build/style.css', array(), $this->version ); - wp_register_script( 'audioigniter', untrailingslashit( $this->plugin_url() ) . '/player/build/app.js', array(), $this->version, true ); - - wp_localize_script( 'audioigniter', 'aiStrings', apply_filters( 'audioigniter_aiStrings', array( - /* translators: %s is the track's title. */ - 'play_title' => esc_html__( 'Play %s', 'audioigniter' ), - /* translators: %s is the track's title. */ - 'pause_title' => esc_html__( 'Pause %s', 'audioigniter' ), - 'previous' => esc_html__( 'Previous track', 'audioigniter' ), - 'next' => esc_html__( 'Next track', 'audioigniter' ), - 'toggle_list_repeat' => esc_html__( 'Toggle track listing repeat', 'audioigniter' ), - 'toggle_track_repeat' => esc_html__( 'Toggle track repeat' ), - 'toggle_list_visible' => esc_html__( 'Toggle track listing visibility', 'audioigniter' ), - 'buy_track' => esc_html__( 'Buy this track', 'audioigniter' ), - 'download_track' => esc_html__( 'Download this track', 'audioigniter' ), - 'volume_up' => esc_html__( 'Volume Up', 'audioigniter' ), - 'volume_down' => esc_html__( 'Volume Down', 'audioigniter' ), - 'open_track_lyrics' => esc_html__( 'Open track lyrics', 'audioigniter' ), - 'set_playback_rate' => esc_html__( 'Set playback rate', 'audioigniter' ), - 'skip_forward' => esc_html__( 'Skip forward', 'audioigniter' ), - 'skip_backward' => esc_html__( 'Skip backward', 'audioigniter' ), - 'shuffle' => esc_html__( 'Shuffle', 'audioigniter' ), - ) ) ); - - wp_localize_script( 'audioigniter', 'aiStats', array( - 'enabled' => get_option( 'audioigniter_stats_enabled' ) && class_exists( 'AudioIgniter_Pro' ), - 'apiUrl' => get_rest_url( null, 'audioigniter/v1' ), - ) ); - - wp_register_style( 'audioigniter-admin', untrailingslashit( $this->plugin_url() ) . '/assets/css/admin-styles.css', array(), $this->version ); - wp_register_script( 'audioigniter-admin', untrailingslashit( $this->plugin_url() ) . '/assets/js/audioigniter.js', array(), $this->version, true ); - - wp_localize_script( 'audioigniter-admin', 'ai_scripts', array( - 'messages' => array( - 'confirm_clear_tracks' => esc_html__( 'Do you really want to remove all tracks? (This will not delete your audio files).', 'audioigniter' ), - 'media_title_upload' => esc_html__( 'Select or upload audio media', 'audioigniter' ), - 'media_title_upload_cover' => esc_html__( 'Select a cover image', 'audioigniter' ), - ), - ) ); - - wp_register_style( 'audioigniter-admin-settings', untrailingslashit( $this->plugin_url() ) . '/assets/css/admin/settings.css', array(), $this->version ); - } - - /** - * Enqueues frontend scripts and styles. - * - * @since 1.0.0 - */ - public function enqueue_scripts() { - wp_enqueue_style( 'audioigniter' ); - wp_enqueue_script( 'audioigniter' ); - } - - /** - * Enqueues admin scripts and styles. - * - * @since 1.0.0 - */ - public function enqueue_admin_scripts( $hook ) { - $screen = get_current_screen(); - - if ( 'post' === $screen->base && $screen->post_type === $this->post_type ) { - wp_enqueue_media(); - wp_enqueue_style( 'audioigniter-admin' ); - wp_enqueue_script( 'audioigniter-admin' ); - } - -// if ( 'ai_playlist_page_audioigniter-upsell' === $screen->id ) { -// wp_enqueue_style( 'audioigniter-admin-settings' ); -// } - } - - /** - * Post types registration. - * - * @since 1.0.0 - */ - public function register_post_types() { - $labels = array( - 'name' => esc_html_x( 'Playlists', 'post type general name', 'audioigniter' ), - 'singular_name' => esc_html_x( 'Playlist', 'post type singular name', 'audioigniter' ), - 'menu_name' => esc_html_x( 'AudioIgniter', 'admin menu', 'audioigniter' ), - 'all_items' => esc_html_x( 'All Playlists', 'admin menu', 'audioigniter' ), - 'name_admin_bar' => esc_html_x( 'Playlist', 'add new on admin bar', 'audioigniter' ), - 'add_new' => esc_html__( 'Add New Playlist', 'audioigniter' ), - 'add_new_item' => esc_html__( 'Add New Playlist', 'audioigniter' ), - 'edit_item' => esc_html__( 'Edit Playlist', 'audioigniter' ), - 'new_item' => esc_html__( 'New Playlist', 'audioigniter' ), - 'view_item' => esc_html__( 'View Playlist', 'audioigniter' ), - 'search_items' => esc_html__( 'Search Playlists', 'audioigniter' ), - 'not_found' => esc_html__( 'No playlists found', 'audioigniter' ), - 'not_found_in_trash' => esc_html__( 'No playlists found in the trash', 'audioigniter' ), - ); - - $args = array( - 'labels' => $labels, - 'singular_label' => esc_html_x( 'Playlist', 'post type singular name', 'audioigniter' ), - 'public' => false, - 'show_ui' => true, - 'capability_type' => 'post', - 'hierarchical' => false, - 'has_archive' => false, - 'supports' => array( 'title' ), - 'menu_icon' => 'dashicons-controls-volumeon', - ); - - register_post_type( $this->post_type, $args ); - } - - - /** - * Registers metaboxes for the ai_playlist post type. - * - * @since 1.0.0 - */ - public function add_meta_boxes() { - add_meta_box( 'ai-meta-box-tracks', esc_html__( 'Tracks', 'audioigniter' ), array( $this, 'metabox_tracks' ), $this->post_type, 'normal', 'high' ); - add_meta_box( 'ai-meta-box-settings', esc_html__( 'Settings', 'audioigniter' ), array( $this, 'metabox_settings' ), $this->post_type, 'normal', 'high' ); - add_meta_box( 'ai-meta-box-shortcode', esc_html__( 'Shortcode', 'audioigniter' ), array( $this, 'metabox_shortcode' ), $this->post_type, 'side', 'default' ); - } - - /** - * Echoes the Tracks metabox markup. - * - * @since 1.0.0 - * - * @param WP_Post $object - * @param array $box - */ - public function metabox_tracks( $object, $box ) { - $tracks = $this->get_post_meta( $object->ID, '_audioigniter_tracks', array() ); - - wp_nonce_field( basename( __FILE__ ), $object->post_type . '_nonce' ); - ?> - - metabox_tracks_header(); ?> - -
- metabox_tracks_field_controls( 'top', $object->ID ); ?> - - - -
- metabox_tracks_repeatable_track_field( $track ); - } - } else { - $this->metabox_tracks_repeatable_track_field(); - } - ?> -
- - metabox_tracks_field_controls( 'bottom', $object->ID ); ?> -
- - metabox_tracks_footer(); ?> - - -
-
-
- -
- - -
-
- - - -
-
- -
-
- - - -
-
- - - - - - -
- -
- - -
-
- - -
-
- - -
- -
- - -
- - -
- -
-
- - -
- - - - -
-
- -
- - - disabled - - /> - - -
- - - - -
- -
-
- -
-
- - - - - -
- - -
- get_post_meta( $object->ID, '_audioigniter_player_type', 'full' ); - $numbers = $this->get_post_meta( $object->ID, '_audioigniter_show_numbers', 1 ); - $numbers_reverse = $this->get_post_meta( $object->ID, '_audioigniter_show_numbers_reverse', 0 ); - $thumb = $this->get_post_meta( $object->ID, '_audioigniter_show_covers', 1 ); - $active_thumb = $this->get_post_meta( $object->ID, '_audioigniter_show_active_cover', 1 ); - $artist = $this->get_post_meta( $object->ID, '_audioigniter_show_artist', 1 ); - $buy_links = $this->get_post_meta( $object->ID, '_audioigniter_show_buy_links', 1 ); - $buy_links_new_target = $this->get_post_meta( $object->ID, '_audioigniter_buy_links_new_target', 1 ); - $cycle_tracks = $this->get_post_meta( $object->ID, '_audioigniter_cycle_tracks', 0 ); - $track_listing = $this->get_post_meta( $object->ID, '_audioigniter_show_track_listing', 1 ); - $track_listing_allow_toggle = $this->get_post_meta( $object->ID, '_audioigniter_allow_track_listing_toggle', 1 ); - $track_listing_allow_loop = $this->get_post_meta( $object->ID, '_audioigniter_allow_track_listing_loop', 1 ); - $credit = $this->get_post_meta( $object->ID, '_audioigniter_show_credit', 0 ); - $limit_tracklisting_height = $this->get_post_meta( $object->ID, '_audioigniter_limit_tracklisting_height', 1 ); - $tracklisting_height = $this->get_post_meta( $object->ID, '_audioigniter_tracklisting_height', 185 ); - $volume = $this->get_post_meta( $object->ID, '_audioigniter_volume', 100 ); - $max_width = $this->get_post_meta( $object->ID, '_audioigniter_max_width' ); - - wp_nonce_field( basename( __FILE__ ), $object->post_type . '_nonce' ); - ?> -
-
-

- -
-
- - - -
- -
- - /> - - -
- -
- - /> - - -
- -
- - /> - - -
- -
- - - - -

- -

-
- -
- - /> - - -
- -
- - - - -

- -

-
- -
- - - - -

- -

-
- - -
- -
-

- -
- - /> - - -
- -
- - /> - - -
- -
- - /> - - -
- -
- - /> - - -
- -
- - /> - - -
- -
- - /> - - -
- - -
- -
-

- -
- - /> - - -
- -
- - /> - - -
- - -
- -
- - /> - - - -

- -

-
-
- -
-
- - - ID ) ); ?>" - /> - -
-
- array( - 'label' => __( 'Full Player', 'audioigniter' ), - 'no-support' => array(), - 'info' => '', - ), - 'simple' => array( - 'label' => __( 'Simple Player', 'audioigniter' ), - 'no-support' => array( - 'show_track_listing', - 'show_covers', - 'show_active_cover', - 'limit_tracklisting_height', - 'tracklisting_height', - 'allow_track_listing_loop', - 'allow_track_listing_toggle', - 'skip_amount', - 'initial_track', - ), - 'info' => '', - ), - ); - - return apply_filters( 'audioigniter_player_types', $player_types ); - } - - public function save_post( $post_id ) { - if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { return false; } - if ( isset( $_POST['post_view'] ) && 'list' === $_POST['post_view'] ) { return false; } - if ( ! isset( $_POST['post_type'] ) || $_POST['post_type'] !== $this->post_type ) { return false; } - if ( ! isset( $_POST[ $this->post_type . '_nonce' ] ) || ! wp_verify_nonce( $_POST[ $this->post_type . '_nonce' ], basename( __FILE__ ) ) ) { return false; } - $post_type_obj = get_post_type_object( $this->post_type ); - if ( ! current_user_can( $post_type_obj->cap->edit_post, $post_id ) ) { return false; } - - update_post_meta( $post_id, '_audioigniter_tracks', $this->sanitizer->metabox_playlist( $_POST['ai_playlist_tracks'], $post_id ) ); - - update_post_meta( $post_id, '_audioigniter_show_numbers', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_numbers'] ) ); - update_post_meta( $post_id, '_audioigniter_show_numbers_reverse', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_numbers_reverse'] ) ); - update_post_meta( $post_id, '_audioigniter_show_covers', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_covers'] ) ); - update_post_meta( $post_id, '_audioigniter_show_active_cover', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_active_cover'] ) ); - update_post_meta( $post_id, '_audioigniter_show_artist', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_artist'] ) ); - update_post_meta( $post_id, '_audioigniter_show_buy_links', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_buy_links'] ) ); - update_post_meta( $post_id, '_audioigniter_buy_links_new_target', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_buy_links_new_target'] ) ); - update_post_meta( $post_id, '_audioigniter_cycle_tracks', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_cycle_tracks'] ) ); - update_post_meta( $post_id, '_audioigniter_show_track_listing', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_track_listing'] ) ); - update_post_meta( $post_id, '_audioigniter_allow_track_listing_toggle', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_allow_track_listing_toggle'] ) ); - update_post_meta( $post_id, '_audioigniter_allow_track_listing_loop', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_allow_track_listing_loop'] ) ); - update_post_meta( $post_id, '_audioigniter_player_type', $this->sanitizer->player_type( $_POST['_audioigniter_player_type'] ) ); - update_post_meta( $post_id, '_audioigniter_show_credit', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_show_credit'] ) ); - update_post_meta( $post_id, '_audioigniter_limit_tracklisting_height', $this->sanitizer->checkbox_ref( $_POST['_audioigniter_limit_tracklisting_height'] ) ); - update_post_meta( $post_id, '_audioigniter_tracklisting_height', intval( $_POST['_audioigniter_tracklisting_height'] ) ); - update_post_meta( $post_id, '_audioigniter_volume', intval( $_POST['_audioigniter_volume'] ) ); - update_post_meta( $post_id, '_audioigniter_max_width', $this->sanitizer->intval_or_empty( $_POST['_audioigniter_max_width'] ) ); - - /** - * @since 1.4.0 - */ - do_action( 'audioigniter_save_post', $post_id ); - } - - public static function get_default_track_values() { - return apply_filters( 'audioigniter_default_track_values', array( - 'cover_id' => '', - 'title' => '', - 'artist' => '', - 'track_url' => '', - 'buy_link' => '', - 'download_url' => '', - 'download_uses_track_url' => 0, - ) ); - } - - public function register_image_sizes() { - add_image_size( 'audioigniter_cover', 560, 560, true ); - } - - public function register_widgets() { - $widgets = apply_filters( 'audioigniter_register_widgets', array() ); - - foreach ( $widgets as $class => $file ) { - require_once( $file ); - register_widget( $class ); - } - } - - public function register_shortcodes() { - add_shortcode( 'ai_playlist', array( $this, 'shortcode_ai_playlist' ) ); - } - - /** - * Checks whether passed post object or ID is an AudioIgniter playlist. - * - * @version 1.4.0 - * @since 1.4.0 - * - * @param int|WP_Post $post Post ID or post object. - * - * @return bool - */ - public function is_playlist( $post ) { - $post = get_post( $post ); - - if ( is_wp_error( $post ) || empty( $post ) || is_null( $post ) || $post->post_type !== $this->post_type ) { - return false; - } - - return true; - } - - /** - * Returns a data attributes array for the given playlist. - * - * @version 1.4.0 - * @since 1.4.0 - * - * @param int $post_id Post ID. - * - * @return array - */ - public function get_playlist_data_attributes_array( $post_id ) { - $post_id = intval( $post_id ); - - if ( ! $this->is_playlist( $post_id ) ) { - return array(); - } - - $attrs = array( - 'data-player-type' => $this->get_post_meta( $post_id, '_audioigniter_player_type', 'full' ), - 'data-tracks-url' => add_query_arg( array( 'audioigniter_playlist_id' => $post_id ), home_url( '/' ) ), - 'data-display-track-no' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_numbers', 1 ) ), - 'data-reverse-track-order' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_numbers_reverse', 0 ) ), - 'data-display-tracklist-covers' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_covers', 1 ) ), - 'data-display-active-cover' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_active_cover', 1 ) ), - 'data-display-artist-names' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_artist', 1 ) ), - 'data-display-buy-buttons' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_buy_links', 1 ) ), - 'data-buy-buttons-target' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_buy_links_new_target', 1 ) ), - 'data-cycle-tracks' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_cycle_tracks', 0 ) ), - 'data-display-credits' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_credit', 1 ) ), - 'data-display-tracklist' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_show_track_listing', 1 ) ), - 'data-allow-tracklist-toggle' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_allow_track_listing_toggle', 1 ) ), - 'data-allow-tracklist-loop' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_allow_track_listing_loop', 1 ) ), - 'data-limit-tracklist-height' => $this->convert_bool_string( $this->get_post_meta( $post_id, '_audioigniter_limit_tracklisting_height', 1 ) ), - 'data-volume' => intval( $this->get_post_meta( $post_id, '_audioigniter_volume', 100 ) ), - 'data-tracklist-height' => intval( $this->get_post_meta( $post_id, '_audioigniter_tracklisting_height', 185 ) ), - 'data-max-width' => $this->get_post_meta( $post_id, '_audioigniter_max_width' ), - ); - - return apply_filters( 'audioigniter_get_playlist_data_attributes_array', $attrs, $post_id ); - } - - /** - * Returns the output of the [ai_playlist] shortcode. - * - * @version 1.4.0 - * @since 1.0.0 - * - * @param array $atts The shortcode attributes. - * @param string $content Content, when used with a shortcode closing tag. - * @param string $tag The shortcode name used to reach this function. - * - * @return string - */ - public function shortcode_ai_playlist( $atts, $content, $tag ) { - $atts = shortcode_atts( array( - 'id' => '', - 'class' => '', - ), $atts, $tag ); - - $id = intval( $atts['id'] ); - $class_name = $atts['class']; - - if ( ! $this->is_playlist( $id ) ) { - return ''; - } - - $post = get_post( $id ); - - $params = apply_filters( 'audioigniter_shortcode_data_attributes_array', $this->get_playlist_data_attributes_array( $id ), $id, $post, $atts ); - $params = array_filter( $params, array( $this->sanitizer, 'array_filter_empty_null' ) ); - $params = $this->sanitizer->html_data_attributes_array( $params ); - - // Returning a truthy value from the filter, will short-circuit execution of the shortcode. - if ( false !== apply_filters( 'audioigniter_shortcode_shortcircuit', false, $id, $post, $params ) ) { - return ''; - } - - $data = ''; - foreach ( $params as $attribute => $value ) { - $data .= sprintf( '%s="%s" ', sanitize_key( $attribute ), esc_attr( $value ) ); - } - - $player_classes = array_merge( array( - 'audioigniter-root', - ), explode( ' ', $class_name ) ); - - $output = sprintf( '
', - esc_attr( $id ), - esc_attr( implode( ' ', $player_classes ) ), - $data - ); - - return $output; - } - - public function convert_bool_string( $value ) { - if ( $value ) { - return 'true'; - } - - return 'false'; - } - - public function register_playlist_endpoint() { - add_rewrite_tag( '%audioigniter_playlist_id%', '([0-9]+)' ); - add_rewrite_rule( '^audioigniter/playlist/([0-9]+)/?', 'index.php?audioigniter_playlist_id=$matches[1]', 'bottom' ); - } - - public function handle_playlist_endpoint() { - global $wp_query; - - $playlist_id = $wp_query->get( 'audioigniter_playlist_id' ); - - if ( empty( $playlist_id ) ) { - return; - } - - $playlist_id = intval( $playlist_id ); - $post = get_post( $playlist_id ); - - if ( empty( $post ) || $post->post_type !== $this->post_type ) { - wp_send_json_error( __( "ID doesn't match a playlist", 'audioigniter' ) ); - } - - $response = array(); - $tracks = $this->get_post_meta( $playlist_id, '_audioigniter_tracks', array() ); - - if ( empty( $tracks ) ) { - $tracks = array(); - } - - foreach ( $tracks as $track ) { - $track = wp_parse_args( $track, self::get_default_track_values() ); - $track_response = array(); - - $track_response['title'] = $track['title']; - $track_response['subtitle'] = $track['artist']; - $track_response['audio'] = $track['track_url']; - $track_response['buyUrl'] = $track['buy_link']; - $track_response['downloadUrl'] = $track['download_uses_track_url'] ? $track['track_url'] : $track['download_url']; - $track_response['downloadFilename'] = $this->get_filename_from_url( $track_response['downloadUrl'] ); - - if ( ! $track_response['downloadFilename'] ) { - $track_response['downloadFilename'] = $track_response['downloadUrl']; - } - - $cover_url = wp_get_attachment_image_src( intval( $track['cover_id'] ), 'audioigniter_cover' ); - if ( ! empty( $cover_url[0] ) ) { - $cover_url = $cover_url[0]; - } else { - $cover_url = ''; - } - - $track_response['cover'] = $cover_url; - - $track_response = apply_filters( 'audioigniter_playlist_endpoint_track', $track_response, $track, $playlist_id, $post ); - if ( false === $track_response ) { - continue; - } - - $response[] = $track_response; - } - - wp_send_json( $response ); - } - - public function filter_posts_columns( $columns ) { - $date = $columns['date']; - unset( $columns['date'] ); - - $columns['shortcode'] = __( 'Shortcode', 'audioigniter' ); - $columns['date'] = $date; - - return $columns; - } - - public function add_custom_columns( $column, $post_id ) { - if ( 'shortcode' === $column ) { - ?>"> $this->post_type, - 'posts_per_page' => - 1, - 'orderby' => $orderby, - 'order' => $order, - ) ); - - return $q->posts; - } - - public function get_post_meta( $post_id, $key, $default = '' ) { - $keys = get_post_custom_keys( $post_id ); - - $value = $default; - - if ( is_array( $keys ) && in_array( $key, $keys, true ) ) { - $value = get_post_meta( $post_id, $key, true ); - } - - return $value; - } - - public function plugin_activated() { - if ( ! current_user_can( 'activate_plugins' ) ) { - return; - } - - $this->register_post_types(); - - do_action( 'audioigniter_activated' ); - - flush_rewrite_rules(); - } - - public function plugin_deactivated() { - if ( ! current_user_can( 'activate_plugins' ) ) { - return; - } - - unregister_post_type( $this->post_type ); - - do_action( 'audioigniter_deactivated' ); - - flush_rewrite_rules(); - } - - public static function plugin_basename() { - return plugin_basename( __FILE__ ); - } - - public function plugin_url() { - return self::$plugin_url; - } - - public function plugin_path() { - return self::$plugin_path; - } -} - - -/** - * Main instance of AudioIgniter. - * - * Returns the working instance of AudioIgniter. No need for globals. - * - * @since 1.0.0 - * @return AudioIgniter - */ -function AudioIgniter() { - return AudioIgniter::instance(); -} - -add_action( 'plugins_loaded', array( AudioIgniter(), 'plugin_setup' ) ); -register_activation_hook( __FILE__, array( AudioIgniter(), 'plugin_activated' ) ); -register_deactivation_hook( __FILE__, array( AudioIgniter(), 'plugin_deactivated' ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/inc/class-audioigniter-admin-page-upsell.php b/wp-content/upgrade-temp-backup/plugins/audioigniter/inc/class-audioigniter-admin-page-upsell.php deleted file mode 100644 index 5bb991a8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/inc/class-audioigniter-admin-page-upsell.php +++ /dev/null @@ -1,169 +0,0 @@ -tabs = array( - 'general' => array( - 'title' => _x( 'General', 'settings tab title', 'audioigniter' ), - 'callback' => array( $this, 'tab_general' ), - ), - ); - } - - /** - * Register the page - * - * @since 2.0.0 - * - * @return void - */ - public function register() { - $page_slug = 'edit.php?post_type=' . AudioIgniter()->post_type; - add_submenu_page( $page_slug, __( 'AudioIgniter Settings', 'audioigniter' ), __( 'Go Pro!', 'audioigniter' ), 'manage_options', self::$page_slug, array( $this, 'render_page' ) ); - } - - /** - * Renders the onboarding page. - * - * @since 2.0.0 - */ - public function render_page() { - $active_tab = isset( $_GET['tab'] ) ? sanitize_key( wp_unslash( $_GET['tab'] ) ) : ''; // phpcs:ignore WordPress.Security.NonceVerification - if ( ! array_key_exists( $active_tab, $this->tabs ) ) { - reset( $this->tabs ); - $active_tab = key( $this->tabs ); - } - - ?> -
-

- -

- -
- -
-
-
- -
- generate_tabs( $active_tab ); ?> -
-
-
- -
-
- tabs as $tab => $tab_info ) : ?> - - - -
-
- -
- tabs[ $active_tab ]['callback'] ) ) { - call_user_func( $this->tabs[ $active_tab ]['callback'], $active_tab ); - } ?> -
- -
- -
- TODO: Leave disabled option below and write some upsell stuff. Maybe add images. Or replace everything with upsell info. -
- - - - - - -
- -

- -

-
- - - -
- 'ai_playlist', - 'page' => self::$page_slug, - ), admin_url( 'edit.php' ) ); - } - - /** - * Returns the URL of a specific tab. - * - * @since 2.0.0 - * - * @return string - */ - private function get_tab_url( $tab ) { - return add_query_arg( array( - 'tab' => $tab, - ), $this->get_page_url() ); - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/inc/class-audioigniter-sanitizer.php b/wp-content/upgrade-temp-backup/plugins/audioigniter/inc/class-audioigniter-sanitizer.php deleted file mode 100644 index 09abd5d5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/inc/class-audioigniter-sanitizer.php +++ /dev/null @@ -1,368 +0,0 @@ -get_player_types() - * - * @param string $value Player type to sanitize. - * - * @return string - */ - public static function player_type( $value ) { - $choices = AudioIgniter()->get_player_types(); - if ( array_key_exists( $value, $choices ) ) { - return $value; - } - - return 'full'; - } - - /** - * Sanitizes a playlist (repeatable tracks). - * - * @version 1.2.0 - * @since 1.0.0 - * - * @uses AudioIgniter_Sanitizer::playlist_track() - * - * @param array $post_tracks Input values to sanitize, as passed by the playlist metabox. - * @param int|null $post_id Optional. Post ID where the track belongs to. - * - * @return array - */ - public static function metabox_playlist( $post_tracks, $post_id = null ) { - if ( empty( $post_tracks ) || ! is_array( $post_tracks ) ) { - return array(); - } - - $tracks = array(); - - foreach ( $post_tracks as $uid => $track_data ) { - $track = self::playlist_track( $track_data, $post_id, $uid ); - if ( false !== $track ) { - $tracks[] = $track; - } - } - - return apply_filters( 'audioigniter_sanitize_playlist', $tracks, $post_tracks, $post_id ); - } - - /** - * Sanitizes a single playlist track. - * - * @since 1.0.0 - * - * @uses AudioIgniter::get_default_track_values() - * - * @param array $track Input values to sanitize. - * @param int|null $post_id Optional. Post ID where the track belongs to. - * @param string $track_uid Optional. UID that identifies the track in the metabox list. - * - * @return array|false Array if at least one field is completed, false otherwise. - */ - public static function playlist_track( $track, $post_id = null, $track_uid = '' ) { - $track = wp_parse_args( $track, AudioIgniter::get_default_track_values() ); - - $sanitized_track = array(); - - $sanitized_track['cover_id'] = intval( $track['cover_id'] ); - $sanitized_track['title'] = sanitize_text_field( $track['title'] ); - $sanitized_track['artist'] = sanitize_text_field( $track['artist'] ); - $sanitized_track['track_url'] = esc_url_raw( $track['track_url'] ); - $sanitized_track['buy_link'] = esc_url_raw( $track['buy_link'] ); - $sanitized_track['download_url'] = esc_url_raw( $track['download_url'] ); - $sanitized_track['download_uses_track_url'] = ! empty( $track['download_uses_track_url'] ) ? 1 : 0; - - $sanitized_track = array_map( 'trim', $sanitized_track ); - - $tmp = array_filter( $sanitized_track ); - if ( empty( $tmp ) ) { - $sanitized_track = false; - } - - return apply_filters( 'audioigniter_sanitize_playlist_track', $sanitized_track, $track, $post_id, $track_uid ); - } - - /** - * Sanitizes a checkbox value. - * - * @since 1.0.0 - * - * @param int|string|bool $input Input value to sanitize. - * - * @return int|string Returns 1 if $input evaluates to 1, an empty string otherwise. - */ - public static function checkbox( $input ) { - if ( 1 == $input ) { // WPCS: loose comparison ok. - return 1; - } - - return ''; - } - - /** - * Sanitizes a checkbox value. Value is passed by reference. - * - * Useful when sanitizing form checkboxes. Since browsers don't send any data when a checkbox - * is not checked, checkbox() throws an error. - * checkbox_ref() however evaluates &$input as null so no errors are thrown. - * - * @since 1.0.0 - * - * @param int|string|bool &$input Input value to sanitize. - * - * @return int|string Returns 1 if $input evaluates to 1, an empty string otherwise. - */ - public static function checkbox_ref( &$input ) { - if ( 1 == $input ) { // WPCS: loose comparison ok. - return 1; - } - - return ''; - } - - - /** - * Sanitizes integer input while differentiating zero from empty string. - * - * @since 1.0.0 - * - * @param mixed $input Input value to sanitize. - * - * @return int|string Integer value (including zero), or an empty string otherwise. - */ - public static function intval_or_empty( $input ) { - if ( is_null( $input ) || false === $input || '' === $input ) { - return ''; - } - - if ( 0 == $input ) { // WPCS: loose comparison ok. - return 0; - } - - return intval( $input ); - } - - - /** - * Returns a sanitized hex color code. - * - * @since 1.0.0 - * - * @param string $str The color string to be sanitized. - * @param bool $return_hash Whether to return the color code prepended by a hash. - * @param string $return_fail The value to return on failure. - * - * @return string A valid hex color code on success, an empty string on failure. - */ - public static function hex_color( $str, $return_hash = true, $return_fail = '' ) { - if ( false === $str || empty( $str ) || 'false' === $str ) { - return $return_fail; - } - - // Allow keywords and predefined colors - if ( in_array( $str, array( 'transparent', 'initial', 'inherit', 'black', 'silver', 'gray', 'grey', 'white', 'maroon', 'red', 'purple', 'fuchsia', 'green', 'lime', 'olive', 'yellow', 'navy', 'blue', 'teal', 'aqua', 'orange', 'aliceblue', 'antiquewhite', 'aquamarine', 'azure', 'beige', 'bisque', 'blanchedalmond', 'blueviolet', 'brown', 'burlywood', 'cadetblue', 'chartreuse', 'chocolate', 'coral', 'cornflowerblue', 'cornsilk', 'crimson', 'darkblue', 'darkcyan', 'darkgoldenrod', 'darkgray', 'darkgrey', 'darkgreen', 'darkkhaki', 'darkmagenta', 'darkolivegreen', 'darkorange', 'darkorchid', 'darkred', 'darksalmon', 'darkseagreen', 'darkslateblue', 'darkslategray', 'darkslategrey', 'darkturquoise', 'darkviolet', 'deeppink', 'deepskyblue', 'dimgray', 'dimgrey', 'dodgerblue', 'firebrick', 'floralwhite', 'forestgreen', 'gainsboro', 'ghostwhite', 'gold', 'goldenrod', 'greenyellow', 'grey', 'honeydew', 'hotpink', 'indianred', 'indigo', 'ivory', 'khaki', 'lavender', 'lavenderblush', 'lawngreen', 'lemonchiffon', 'lightblue', 'lightcoral', 'lightcyan', 'lightgoldenrodyellow', 'lightgray', 'lightgreen', 'lightgrey', 'lightpink', 'lightsalmon', 'lightseagreen', 'lightskyblue', 'lightslategray', 'lightslategrey', 'lightsteelblue', 'lightyellow', 'limegreen', 'linen', 'mediumaquamarine', 'mediumblue', 'mediumorchid', 'mediumpurple', 'mediumseagreen', 'mediumslateblue', 'mediumspringgreen', 'mediumturquoise', 'mediumvioletred', 'midnightblue', 'mintcream', 'mistyrose', 'moccasin', 'navajowhite', 'oldlace', 'olivedrab', 'orangered', 'orchid', 'palegoldenrod', 'palegreen', 'paleturquoise', 'palevioletred', 'papayawhip', 'peachpuff', 'peru', 'pink', 'plum', 'powderblue', 'rosybrown', 'royalblue', 'saddlebrown', 'salmon', 'sandybrown', 'seagreen', 'seashell', 'sienna', 'skyblue', 'slateblue', 'slategray', 'slategrey', 'snow', 'springgreen', 'steelblue', 'tan', 'thistle', 'tomato', 'turquoise', 'violet', 'wheat', 'whitesmoke', 'yellowgreen', 'rebeccapurple' ), true ) ) { - return $str; - } - - // Include the hash if not there. - // The regex below depends on in. - if ( substr( $str, 0, 1 ) !== '#' ) { - $str = '#' . $str; - } - - preg_match( '/(#)([0-9a-fA-F]{6})/', $str, $matches ); - - if ( count( $matches ) === 3 ) { - if ( $return_hash ) { - return $matches[1] . $matches[2]; - } else { - return $matches[2]; - } - } - - return $return_fail; - } - - /** - * Sanitizes a CSS color. - * - * Tries to validate and sanitize values in these formats: - * - rgba() - * - 3 and 6 digit hex values, optionally prefixed with `#` - * - Predefined CSS named colors/keywords, such as 'transparent', 'initial', 'inherit', 'black', 'silver', etc. - * - * @since 1.7.1 - * - * @param string $color The color value to sanitize - * @param bool $return_hash Whether to return hex color prefixed with a `#` - * @param string $return_fail Value to return when $color fails validation. - * - * @return string - */ - public static function rgba_color( $color, $return_hash = true, $return_fail = '' ) { - if ( false === $color || empty( $color ) || 'false' === $color ) { - return $return_fail; - } - - // Allow keywords and predefined colors - if ( in_array( $color, array( 'transparent', 'initial', 'inherit', 'black', 'silver', 'gray', 'grey', 'white', 'maroon', 'red', 'purple', 'fuchsia', 'green', 'lime', 'olive', 'yellow', 'navy', 'blue', 'teal', 'aqua', 'orange', 'aliceblue', 'antiquewhite', 'aquamarine', 'azure', 'beige', 'bisque', 'blanchedalmond', 'blueviolet', 'brown', 'burlywood', 'cadetblue', 'chartreuse', 'chocolate', 'coral', 'cornflowerblue', 'cornsilk', 'crimson', 'darkblue', 'darkcyan', 'darkgoldenrod', 'darkgray', 'darkgrey', 'darkgreen', 'darkkhaki', 'darkmagenta', 'darkolivegreen', 'darkorange', 'darkorchid', 'darkred', 'darksalmon', 'darkseagreen', 'darkslateblue', 'darkslategray', 'darkslategrey', 'darkturquoise', 'darkviolet', 'deeppink', 'deepskyblue', 'dimgray', 'dimgrey', 'dodgerblue', 'firebrick', 'floralwhite', 'forestgreen', 'gainsboro', 'ghostwhite', 'gold', 'goldenrod', 'greenyellow', 'grey', 'honeydew', 'hotpink', 'indianred', 'indigo', 'ivory', 'khaki', 'lavender', 'lavenderblush', 'lawngreen', 'lemonchiffon', 'lightblue', 'lightcoral', 'lightcyan', 'lightgoldenrodyellow', 'lightgray', 'lightgreen', 'lightgrey', 'lightpink', 'lightsalmon', 'lightseagreen', 'lightskyblue', 'lightslategray', 'lightslategrey', 'lightsteelblue', 'lightyellow', 'limegreen', 'linen', 'mediumaquamarine', 'mediumblue', 'mediumorchid', 'mediumpurple', 'mediumseagreen', 'mediumslateblue', 'mediumspringgreen', 'mediumturquoise', 'mediumvioletred', 'midnightblue', 'mintcream', 'mistyrose', 'moccasin', 'navajowhite', 'oldlace', 'olivedrab', 'orangered', 'orchid', 'palegoldenrod', 'palegreen', 'paleturquoise', 'palevioletred', 'papayawhip', 'peachpuff', 'peru', 'pink', 'plum', 'powderblue', 'rosybrown', 'royalblue', 'saddlebrown', 'salmon', 'sandybrown', 'seagreen', 'seashell', 'sienna', 'skyblue', 'slateblue', 'slategray', 'slategrey', 'snow', 'springgreen', 'steelblue', 'tan', 'thistle', 'tomato', 'turquoise', 'violet', 'wheat', 'whitesmoke', 'yellowgreen', 'rebeccapurple' ), true ) ) { - return $color; - } - - preg_match( '/rgba\(\s*(\d{1,3}\.?\d*\%?)\s*,\s*(\d{1,3}\.?\d*\%?)\s*,\s*(\d{1,3}\.?\d*\%?)\s*,\s*(\d{1}\.?\d*\%?)\s*\)/', $color, $rgba_matches ); - if ( ! empty( $rgba_matches ) && 5 === count( $rgba_matches ) ) { - for ( $i = 1; $i < 4; $i++ ) { - if ( strpos( $rgba_matches[ $i ], '%' ) !== false ) { - $rgba_matches[ $i ] = self::float_0_100( $rgba_matches[ $i ] ); - } else { - $rgba_matches[ $i ] = self::int_0_255( $rgba_matches[ $i ] ); - } - } - $rgba_matches[4] = self::float_0_1( $rgba_matches[ $i ] ); - return sprintf( 'rgba(%s, %s, %s, %s)', $rgba_matches[1], $rgba_matches[2], $rgba_matches[3], $rgba_matches[4] ); - } - - // Not a color function either. Let's see if it's a hex color. - - // Include the hash if not there. - // The regex below depends on in. - if ( substr( $color, 0, 1 ) !== '#' ) { - $color = '#' . $color; - } - - preg_match( '/(#)([0-9a-fA-F]{6})/', $color, $matches ); - - if ( 3 === count( $matches ) ) { - if ( $return_hash ) { - return $matches[1] . $matches[2]; - } else { - return $matches[2]; - } - } - - return $return_fail; - } - - /** - * Sanitizes a percentage value, 0% - 100% - * - * Accepts float values with or without the percentage sign `%` - * Returns a string suffixed with the percentage sign `%`. - * - * @since 1.7.1 - * - * @param mixed $value - * - * @return string A percentage value, including the percentage sign. - */ - public static function float_0_100( $value ) { - $value = str_replace( '%', '', $value ); - if ( floatval( $value ) > 100 ) { - $value = 100; - } elseif ( floatval( $value ) < 0 ) { - $value = 0; - } - - return floatval( $value ) . '%'; - } - - /** - * Sanitizes a decimal CSS color value, 0 - 255. - * - * Accepts float values with or without the percentage sign `%` - * Returns a string suffixed with the percentage sign `%`. - * - * @since 1.7.1 - * - * @param mixed $value - * - * @return int A number between 0-255. - */ - public static function int_0_255( $value ) { - if ( intval( $value ) > 255 ) { - $value = 255; - } elseif ( intval( $value ) < 0 ) { - $value = 0; - } - - return intval( $value ); - } - - /** - * Sanitizes a CSS opacity value, 0 - 1. - * - * @since 1.7.1 - * - * @param mixed $value - * - * @return float A number between 0-1. - */ - public static function float_0_1( $value ) { - if ( floatval( $value ) > 1 ) { - $value = 1; - } elseif ( floatval( $value ) < 0 ) { - $value = 0; - } - - return floatval( $value ); - } - - /** - * Removes elements whose keys are not valid data-attribute names. - * - * @since 1.0.0 - * - * @param array $array Input array to sanitize. - * - * @return array() - */ - public static function html_data_attributes_array( $array ) { - $keys = array_keys( $array ); - $key_prefix = 'data-'; - - // Remove keys that are not data attributes. - foreach ( $keys as $key ) { - if ( substr( $key, 0, strlen( $key_prefix ) ) !== $key_prefix ) { - unset( $array[ $key ] ); - } - } - - return $array; - } - - - /** - * Returns false when value is empty or null. - * Only use with array_filter() or similar, as the naming can lead to confusion. - * - * @since 1.2.0 - * - * @param mixed $value Array value to check whether empty or null. - * - * @return bool false if empty or null, true otherwise. - */ - public static function array_filter_empty_null( $value ) { - if ( '' === $value || is_null( $value ) ) { - return false; - } - - return true; - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/languages/audioigniter.pot b/wp-content/upgrade-temp-backup/plugins/audioigniter/languages/audioigniter.pot deleted file mode 100644 index d8a00b96..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/languages/audioigniter.pot +++ /dev/null @@ -1,423 +0,0 @@ -#, fuzzy -msgid "" -msgstr "" -"Project-Id-Version: AudioIgniter\n" -"POT-Creation-Date: 2024-11-19 13:49+0200\n" -"PO-Revision-Date: 2016-08-29 19:22+0300\n" -"Last-Translator: Anastis Sourgoutsidis \n" -"Language-Team: Anastis Sourgoutsidis \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n" -"X-Generator: Poedit 3.5\n" -"X-Poedit-Basepath: ..\n" -"X-Poedit-WPHeader: audioigniter.php\n" -"X-Poedit-SourceCharset: UTF-8\n" -"X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;" -"esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;" -"_nx_noop:3c,1,2;__ngettext_noop:1,2\n" -"X-Poedit-Flags-xgettext: --add-comments=translators:\n" -"X-Poedit-SearchPath-0: .\n" -"X-Poedit-SearchPathExcluded-0: *.js\n" - -#. translators: %s is the track's title. -#: audioigniter.php:220 -#, php-format -msgid "Play %s" -msgstr "" - -#. translators: %s is the track's title. -#: audioigniter.php:222 -#, php-format -msgid "Pause %s" -msgstr "" - -#: audioigniter.php:223 -msgid "Previous track" -msgstr "" - -#: audioigniter.php:224 -msgid "Next track" -msgstr "" - -#: audioigniter.php:225 -msgid "Toggle track listing repeat" -msgstr "" - -#: audioigniter.php:226 -msgid "Toggle track repeat" -msgstr "" - -#: audioigniter.php:227 -msgid "Toggle track listing visibility" -msgstr "" - -#: audioigniter.php:228 -msgid "Buy this track" -msgstr "" - -#: audioigniter.php:229 -msgid "Download this track" -msgstr "" - -#: audioigniter.php:230 -msgid "Volume Up" -msgstr "" - -#: audioigniter.php:231 -msgid "Volume Down" -msgstr "" - -#: audioigniter.php:232 -msgid "Open track lyrics" -msgstr "" - -#: audioigniter.php:233 -msgid "Set playback rate" -msgstr "" - -#: audioigniter.php:234 -msgid "Skip forward" -msgstr "" - -#: audioigniter.php:235 -msgid "Skip backward" -msgstr "" - -#: audioigniter.php:236 -msgid "Shuffle" -msgstr "" - -#: audioigniter.php:249 -msgid "" -"Do you really want to remove all tracks? (This will not delete your audio " -"files)." -msgstr "" - -#: audioigniter.php:250 -msgid "Select or upload audio media" -msgstr "" - -#: audioigniter.php:251 -msgid "Select a cover image" -msgstr "" - -#: audioigniter.php:294 -msgctxt "post type general name" -msgid "Playlists" -msgstr "" - -#: audioigniter.php:295 audioigniter.php:311 -msgctxt "post type singular name" -msgid "Playlist" -msgstr "" - -#: audioigniter.php:296 -msgctxt "admin menu" -msgid "AudioIgniter" -msgstr "" - -#: audioigniter.php:297 -msgctxt "admin menu" -msgid "All Playlists" -msgstr "" - -#: audioigniter.php:298 -msgctxt "add new on admin bar" -msgid "Playlist" -msgstr "" - -#: audioigniter.php:299 audioigniter.php:300 -msgid "Add New Playlist" -msgstr "" - -#: audioigniter.php:301 -msgid "Edit Playlist" -msgstr "" - -#: audioigniter.php:302 -msgid "New Playlist" -msgstr "" - -#: audioigniter.php:303 -msgid "View Playlist" -msgstr "" - -#: audioigniter.php:304 -msgid "Search Playlists" -msgstr "" - -#: audioigniter.php:305 -msgid "No playlists found" -msgstr "" - -#: audioigniter.php:306 -msgid "No playlists found in the trash" -msgstr "" - -#: audioigniter.php:331 audioigniter.php:857 -msgid "Tracks" -msgstr "" - -#: audioigniter.php:332 -msgid "Settings" -msgstr "" - -#: audioigniter.php:333 audioigniter.php:1325 -msgid "Shortcode" -msgstr "" - -#: audioigniter.php:391 -msgid "AudioIgniter Logo" -msgstr "" - -#: audioigniter.php:400 -msgid "Upgrade to Pro" -msgstr "" - -#: audioigniter.php:424 -msgid "Support" -msgstr "" - -#: audioigniter.php:428 -msgid "Documentation" -msgstr "" - -#: audioigniter.php:432 -msgid "Rate this plugin" -msgstr "" - -#. translators: %s is a URL. -#: audioigniter.php:455 -#, php-format -msgid "" -"Thank you for creating with AudioIgniter" -msgstr "" - -#: audioigniter.php:501 -msgid "Toggle track visibility" -msgstr "" - -#: audioigniter.php:512 -msgid "Remove Cover Image" -msgstr "" - -#: audioigniter.php:525 -msgid "Upload Cover" -msgstr "" - -#: audioigniter.php:543 audioigniter.php:550 -msgid "Title" -msgstr "" - -#: audioigniter.php:558 audioigniter.php:565 -msgid "Artist" -msgstr "" - -#: audioigniter.php:574 audioigniter.php:581 -msgid "Buy link" -msgstr "" - -#: audioigniter.php:594 audioigniter.php:603 -msgid "Audio file or radio stream" -msgstr "" - -#: audioigniter.php:607 -msgid "Upload" -msgstr "" - -#: audioigniter.php:618 audioigniter.php:625 -msgid "Download URL" -msgstr "" - -#: audioigniter.php:639 -msgid "Remove Track" -msgstr "" - -#: audioigniter.php:654 -msgid "Add Track" -msgstr "" - -#: audioigniter.php:661 -msgid "Clear Playlist" -msgstr "" - -#: audioigniter.php:667 -msgid "Expand All" -msgstr "" - -#: audioigniter.php:670 -msgid "Collapse All" -msgstr "" - -#: audioigniter.php:709 -msgid "Player & Track listing" -msgstr "" - -#: audioigniter.php:714 -msgid "Player Type" -msgstr "" - -#: audioigniter.php:745 -msgid "Show track listing by default" -msgstr "" - -#: audioigniter.php:759 -msgid "Show track listing visibility toggle button" -msgstr "" - -#: audioigniter.php:773 -msgid "Reverse track order" -msgstr "" - -#: audioigniter.php:779 -msgid "Starting volume" -msgstr "" - -#: audioigniter.php:790 -msgid "0-100" -msgstr "" - -#: audioigniter.php:795 -msgid "Enter a value between 0 and 100 in increments of 10" -msgstr "" - -#: audioigniter.php:809 -msgid "Limit track listing height" -msgstr "" - -#: audioigniter.php:815 audioigniter.php:825 -msgid "Track listing height" -msgstr "" - -#: audioigniter.php:830 -msgid "Set a number of pixels" -msgstr "" - -#: audioigniter.php:836 -msgid "Maximum player width" -msgstr "" - -#: audioigniter.php:844 -msgid "Automatic width" -msgstr "" - -#: audioigniter.php:849 -#, no-php-format -msgid "" -"Set a number of pixels, or leave empty to automatically cover 100% of the " -"available area (recommended)." -msgstr "" - -#: audioigniter.php:869 -msgid "Show track numbers in tracklist" -msgstr "" - -#: audioigniter.php:883 -msgid "Show track covers in tracklist" -msgstr "" - -#: audioigniter.php:897 -msgid "Show active track's cover" -msgstr "" - -#: audioigniter.php:911 -msgid "Show artist names" -msgstr "" - -#: audioigniter.php:925 -msgid "Show track extra buttons (buy link, download button etc)" -msgstr "" - -#: audioigniter.php:939 -msgid "Open buy links in new window" -msgstr "" - -#: audioigniter.php:947 -msgid "Track & Track listing repeat" -msgstr "" - -#: audioigniter.php:959 -msgid "Repeat track listing enabled by default" -msgstr "" - -#: audioigniter.php:973 -msgid "Show track listing repeat toggle button" -msgstr "" - -#: audioigniter.php:990 -msgid "Show \"Powered by AudioIgniter\" link" -msgstr "" - -#: audioigniter.php:994 -msgid "" -"We've put a great deal of effort into building this plugin. If you feel like " -"it, let others know about it by enabling this option." -msgstr "" - -#: audioigniter.php:1014 -msgid "Grab the shortcode" -msgstr "" - -#: audioigniter.php:1048 -msgid "Full Player" -msgstr "" - -#: audioigniter.php:1053 -msgid "Simple Player" -msgstr "" - -#: audioigniter.php:1276 -msgid "ID doesn't match a playlist" -msgstr "" - -#: inc/class-audioigniter-admin-page-upsell.php:32 -msgctxt "settings tab title" -msgid "General" -msgstr "" - -#: inc/class-audioigniter-admin-page-upsell.php:47 -#: inc/class-audioigniter-admin-page-upsell.php:65 -msgid "AudioIgniter Settings" -msgstr "" - -#: inc/class-audioigniter-admin-page-upsell.php:47 -msgid "Go Pro!" -msgstr "" - -#: inc/class-audioigniter-admin-page-upsell.php:123 -msgid "Analytics" -msgstr "" - -#: inc/class-audioigniter-admin-page-upsell.php:127 -msgid "Enable analytics" -msgstr "" - -#: inc/class-audioigniter-admin-page-upsell.php:130 -msgid "" -"When disabled, no new events will be logged and processed into the database." -msgstr "" - -#. Plugin Name of the plugin/theme -msgid "AudioIgniter" -msgstr "" - -#. Plugin URI of the plugin/theme -msgid "https://www.cssigniter.com/plugins/audioigniter/" -msgstr "" - -#. Description of the plugin/theme -msgid "" -"AudioIgniter lets you create music playlists and embed them in your " -"WordPress posts, pages or custom post types and serve your audio content in " -"style!" -msgstr "" - -#. Author of the plugin/theme -msgid "The CSSIgniter Team" -msgstr "" - -#. Author URI of the plugin/theme -msgid "https://www.cssigniter.com" -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/audioigniter/player/build/app.js b/wp-content/upgrade-temp-backup/plugins/audioigniter/player/build/app.js deleted file mode 100644 index c8d99410..00000000 --- a/wp-content/upgrade-temp-backup/plugins/audioigniter/player/build/app.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! For license information please see app.js.LICENSE.txt */ -(()=>{var e,t,n={3379:e=>{var t={animationIterationCount:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridColumn:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,stopOpacity:!0,strokeDashoffset:!0,strokeOpacity:!0,strokeWidth:!0};e.exports=function(e,n){return"number"!=typeof n||t[e]?n:n+"px"}},4184:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function a(){for(var e=[],t=0;t{var r=n(7236),a=n(6189),o={float:"cssFloat"},i=n(3379);function l(e,t,n){var l=o[t];if(void 0===l&&(l=function(e){var t=a(e),n=r(t);return o[t]=o[e]=o[n]=n,n}(t)),l){if(void 0===n)return e.style[l];e.style[l]=i(l,n)}}function u(e,t){for(var n in t)t.hasOwnProperty(n)&&l(e,n,t[n])}function s(){2===arguments.length?"string"==typeof arguments[1]?arguments[0].style.cssText=arguments[1]:u(arguments[0],arguments[1]):l(arguments[0],arguments[1],arguments[2])}e.exports=s,e.exports.set=s,e.exports.get=function(e,t){return Array.isArray(t)?t.reduce((function(t,n){return t[n]=l(e,n||""),t}),{}):l(e,t||"")}},8875:(e,t,n)=>{var r;!function(){"use strict";var a=!("undefined"==typeof window||!window.document||!window.document.createElement),o={canUseDOM:a,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:a&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:a&&!!window.screen};void 0===(r=function(){return o}.call(t,n,t,e))||(e.exports=r)}()},139:e=>{"use strict";function t(e){return function(){return e}}var n=function(){};n.thatReturns=t,n.thatReturnsFalse=t(!1),n.thatReturnsTrue=t(!0),n.thatReturnsNull=t(null),n.thatReturnsThis=function(){return this},n.thatReturnsArgument=function(e){return e},e.exports=n},3759:e=>{"use strict";e.exports=function(e,t,n,r,a,o,i,l){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var s=[n,r,a,o,i,l],c=0;(u=new Error(t.replace(/%s/g,(function(){return s[c++]})))).name="Invariant Violation"}throw u.framesToPop=1,u}}},75:function(e){(function(){var t,n,r;"undefined"!=typeof performance&&null!==performance&&performance.now?e.exports=function(){return performance.now()}:"undefined"!=typeof process&&null!==process&&process.hrtime?(e.exports=function(){return(t()-r)/1e6},n=process.hrtime,r=(t=function(){var e;return 1e9*(e=n())[0]+e[1]})()):Date.now?(e.exports=function(){return Date.now()-r},r=Date.now()):(e.exports=function(){return(new Date).getTime()-r},r=(new Date).getTime())}).call(this)},7236:e=>{var t=null,n=["Webkit","Moz","O","ms"];e.exports=function(e){t||(t=document.createElement("div"));var r=t.style;if(e in r)return e;for(var a=e.charAt(0).toUpperCase()+e.slice(1),o=n.length;o>=0;o--){var i=n[o]+a;if(i in r)return i}return!1}},2703:(e,t,n)=>{"use strict";var r=n(414);function a(){}function o(){}o.resetWarningCache=a,e.exports=function(){function e(e,t,n,a,o,i){if(i!==r){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:o,resetWarningCache:a};return n.PropTypes=n,n}},5697:(e,t,n)=>{e.exports=n(2703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},4087:(e,t,n)=>{for(var r=n(75),a="undefined"==typeof window?n.g:window,o=["moz","webkit"],i="AnimationFrame",l=a["request"+i],u=a["cancel"+i]||a["cancelRequest"+i],s=0;!l&&s{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}},4608:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=Object.assign||function(e){for(var t=1;t1?r-1:0),o=1;o0&&void 0!==arguments[0]?arguments[0]:0;this.view.scrollLeft=e}},{key:"scrollTop",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;this.view.scrollTop=e}},{key:"scrollToLeft",value:function(){this.view.scrollLeft=0}},{key:"scrollToTop",value:function(){this.view.scrollTop=0}},{key:"scrollToRight",value:function(){this.view.scrollLeft=this.view.scrollWidth}},{key:"scrollToBottom",value:function(){this.view.scrollTop=this.view.scrollHeight}},{key:"addListeners",value:function(){if("undefined"!=typeof document){var e=this.view,t=this.trackHorizontal,n=this.trackVertical,r=this.thumbHorizontal,a=this.thumbVertical;e.addEventListener("scroll",this.handleScroll),(0,f.default)()&&(t.addEventListener("mouseenter",this.handleTrackMouseEnter),t.addEventListener("mouseleave",this.handleTrackMouseLeave),t.addEventListener("mousedown",this.handleHorizontalTrackMouseDown),n.addEventListener("mouseenter",this.handleTrackMouseEnter),n.addEventListener("mouseleave",this.handleTrackMouseLeave),n.addEventListener("mousedown",this.handleVerticalTrackMouseDown),r.addEventListener("mousedown",this.handleHorizontalThumbMouseDown),a.addEventListener("mousedown",this.handleVerticalThumbMouseDown),window.addEventListener("resize",this.handleWindowResize))}}},{key:"removeListeners",value:function(){if("undefined"!=typeof document){var e=this.view,t=this.trackHorizontal,n=this.trackVertical,r=this.thumbHorizontal,a=this.thumbVertical;e.removeEventListener("scroll",this.handleScroll),(0,f.default)()&&(t.removeEventListener("mouseenter",this.handleTrackMouseEnter),t.removeEventListener("mouseleave",this.handleTrackMouseLeave),t.removeEventListener("mousedown",this.handleHorizontalTrackMouseDown),n.removeEventListener("mouseenter",this.handleTrackMouseEnter),n.removeEventListener("mouseleave",this.handleTrackMouseLeave),n.removeEventListener("mousedown",this.handleVerticalTrackMouseDown),r.removeEventListener("mousedown",this.handleHorizontalThumbMouseDown),a.removeEventListener("mousedown",this.handleVerticalThumbMouseDown),window.removeEventListener("resize",this.handleWindowResize),this.teardownDragging())}}},{key:"handleScroll",value:function(e){var t=this,n=this.props,r=n.onScroll,a=n.onScrollFrame;r&&r(e),this.update((function(e){var n=e.scrollLeft,r=e.scrollTop;t.viewScrollLeft=n,t.viewScrollTop=r,a&&a(e)})),this.detectScrolling()}},{key:"handleScrollStart",value:function(){var e=this.props.onScrollStart;e&&e(),this.handleScrollStartAutoHide()}},{key:"handleScrollStartAutoHide",value:function(){this.props.autoHide&&this.showTracks()}},{key:"handleScrollStop",value:function(){var e=this.props.onScrollStop;e&&e(),this.handleScrollStopAutoHide()}},{key:"handleScrollStopAutoHide",value:function(){this.props.autoHide&&this.hideTracks()}},{key:"handleWindowResize",value:function(){this.update()}},{key:"handleHorizontalTrackMouseDown",value:function(e){e.preventDefault();var t=e.target,n=e.clientX,r=t.getBoundingClientRect().left,a=this.getThumbHorizontalWidth(),o=Math.abs(r-n)-a/2;this.view.scrollLeft=this.getScrollLeftForOffset(o)}},{key:"handleVerticalTrackMouseDown",value:function(e){e.preventDefault();var t=e.target,n=e.clientY,r=t.getBoundingClientRect().top,a=this.getThumbVerticalHeight(),o=Math.abs(r-n)-a/2;this.view.scrollTop=this.getScrollTopForOffset(o)}},{key:"handleHorizontalThumbMouseDown",value:function(e){e.preventDefault(),this.handleDragStart(e);var t=e.target,n=e.clientX,r=t.offsetWidth,a=t.getBoundingClientRect().left;this.prevPageX=r-(n-a)}},{key:"handleVerticalThumbMouseDown",value:function(e){e.preventDefault(),this.handleDragStart(e);var t=e.target,n=e.clientY,r=t.offsetHeight,a=t.getBoundingClientRect().top;this.prevPageY=r-(n-a)}},{key:"setupDragging",value:function(){(0,l.default)(document.body,m.disableSelectStyle),document.addEventListener("mousemove",this.handleDrag),document.addEventListener("mouseup",this.handleDragEnd),document.onselectstart=d.default}},{key:"teardownDragging",value:function(){(0,l.default)(document.body,m.disableSelectStyleReset),document.removeEventListener("mousemove",this.handleDrag),document.removeEventListener("mouseup",this.handleDragEnd),document.onselectstart=void 0}},{key:"handleDragStart",value:function(e){this.dragging=!0,e.stopImmediatePropagation(),this.setupDragging()}},{key:"handleDrag",value:function(e){if(this.prevPageX){var t=e.clientX,n=-this.trackHorizontal.getBoundingClientRect().left+t-(this.getThumbHorizontalWidth()-this.prevPageX);this.view.scrollLeft=this.getScrollLeftForOffset(n)}if(this.prevPageY){var r=e.clientY,a=-this.trackVertical.getBoundingClientRect().top+r-(this.getThumbVerticalHeight()-this.prevPageY);this.view.scrollTop=this.getScrollTopForOffset(a)}return!1}},{key:"handleDragEnd",value:function(){this.dragging=!1,this.prevPageX=this.prevPageY=0,this.teardownDragging(),this.handleDragEndAutoHide()}},{key:"handleDragEndAutoHide",value:function(){this.props.autoHide&&this.hideTracks()}},{key:"handleTrackMouseEnter",value:function(){this.trackMouseOver=!0,this.handleTrackMouseEnterAutoHide()}},{key:"handleTrackMouseEnterAutoHide",value:function(){this.props.autoHide&&this.showTracks()}},{key:"handleTrackMouseLeave",value:function(){this.trackMouseOver=!1,this.handleTrackMouseLeaveAutoHide()}},{key:"handleTrackMouseLeaveAutoHide",value:function(){this.props.autoHide&&this.hideTracks()}},{key:"showTracks",value:function(){clearTimeout(this.hideTracksTimeout),(0,l.default)(this.trackHorizontal,{opacity:1}),(0,l.default)(this.trackVertical,{opacity:1})}},{key:"hideTracks",value:function(){var e=this;if(!this.dragging&&!this.scrolling&&!this.trackMouseOver){var t=this.props.autoHideTimeout;clearTimeout(this.hideTracksTimeout),this.hideTracksTimeout=setTimeout((function(){(0,l.default)(e.trackHorizontal,{opacity:0}),(0,l.default)(e.trackVertical,{opacity:0})}),t)}}},{key:"detectScrolling",value:function(){var e=this;this.scrolling||(this.scrolling=!0,this.handleScrollStart(),this.detectScrollingInterval=setInterval((function(){e.lastViewScrollLeft===e.viewScrollLeft&&e.lastViewScrollTop===e.viewScrollTop&&(clearInterval(e.detectScrollingInterval),e.scrolling=!1,e.handleScrollStop()),e.lastViewScrollLeft=e.viewScrollLeft,e.lastViewScrollTop=e.viewScrollTop}),100))}},{key:"raf",value:function(e){var t=this;this.requestFrame&&i.default.cancel(this.requestFrame),this.requestFrame=(0,i.default)((function(){t.requestFrame=void 0,e()}))}},{key:"update",value:function(e){var t=this;this.raf((function(){return t._update(e)}))}},{key:"_update",value:function(e){var t=this.props,n=t.onUpdate,r=t.hideTracksWhenNotNeeded,a=this.getValues();if((0,f.default)()){var o=a.scrollLeft,i=a.clientWidth,u=a.scrollWidth,s=(0,p.default)(this.trackHorizontal),c=this.getThumbHorizontalWidth(),d={width:c,transform:"translateX("+o/(u-i)*(s-c)+"px)"},m=a.scrollTop,y=a.clientHeight,v=a.scrollHeight,g=(0,h.default)(this.trackVertical),b=this.getThumbVerticalHeight(),k={height:b,transform:"translateY("+m/(v-y)*(g-b)+"px)"};if(r){var w={visibility:u>i?"visible":"hidden"},S={visibility:v>y?"visible":"hidden"};(0,l.default)(this.trackHorizontal,w),(0,l.default)(this.trackVertical,S)}(0,l.default)(this.thumbHorizontal,d),(0,l.default)(this.thumbVertical,k)}n&&n(a),"function"==typeof e&&e(a)}},{key:"render",value:function(){var e=this,t=(0,f.default)(),n=this.props,a=(n.onScroll,n.onScrollFrame,n.onScrollStart,n.onScrollStop,n.onUpdate,n.renderView),o=n.renderTrackHorizontal,i=n.renderTrackVertical,l=n.renderThumbHorizontal,s=n.renderThumbVertical,d=n.tagName,p=(n.hideTracksWhenNotNeeded,n.autoHide),h=(n.autoHideTimeout,n.autoHideDuration),y=(n.thumbSize,n.thumbMinSize,n.universal),v=n.autoHeight,g=n.autoHeightMin,b=n.autoHeightMax,k=n.style,w=n.children,S=function(e,t){var n={};for(var r in e)t.indexOf(r)>=0||Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=e[r]);return n}(n,["onScroll","onScrollFrame","onScrollStart","onScrollStop","onUpdate","renderView","renderTrackHorizontal","renderTrackVertical","renderThumbHorizontal","renderThumbVertical","tagName","hideTracksWhenNotNeeded","autoHide","autoHideTimeout","autoHideDuration","thumbSize","thumbMinSize","universal","autoHeight","autoHeightMin","autoHeightMax","style","children"]),_=this.state.didMountUniversal,T=r({},m.containerStyleDefault,v&&r({},m.containerStyleAutoHeight,{minHeight:g,maxHeight:b}),k),E=r({},m.viewStyleDefault,{marginRight:t?-t:0,marginBottom:t?-t:0},v&&r({},m.viewStyleAutoHeight,{minHeight:(0,c.default)(g)?"calc("+g+" + "+t+"px)":g+t,maxHeight:(0,c.default)(b)?"calc("+b+" + "+t+"px)":b+t}),v&&y&&!_&&{minHeight:g,maxHeight:b},y&&!_&&m.viewStyleUniversalInitial),O={transition:"opacity "+h+"ms",opacity:0},P=r({},m.trackHorizontalStyleDefault,p&&O,(!t||y&&!_)&&{display:"none"}),C=r({},m.trackVerticalStyleDefault,p&&O,(!t||y&&!_)&&{display:"none"});return(0,u.createElement)(d,r({},S,{style:T,ref:function(t){e.container=t}}),[(0,u.cloneElement)(a({style:E}),{key:"view",ref:function(t){e.view=t}},w),(0,u.cloneElement)(o({style:P}),{key:"trackHorizontal",ref:function(t){e.trackHorizontal=t}},(0,u.cloneElement)(l({style:m.thumbHorizontalStyleDefault}),{ref:function(t){e.thumbHorizontal=t}})),(0,u.cloneElement)(i({style:C}),{key:"trackVertical",ref:function(t){e.trackVertical=t}},(0,u.cloneElement)(s({style:m.thumbVerticalStyleDefault}),{ref:function(t){e.thumbVertical=t}}))])}}]),t}(u.Component);t.default=k,k.propTypes={onScroll:s.default.func,onScrollFrame:s.default.func,onScrollStart:s.default.func,onScrollStop:s.default.func,onUpdate:s.default.func,renderView:s.default.func,renderTrackHorizontal:s.default.func,renderTrackVertical:s.default.func,renderThumbHorizontal:s.default.func,renderThumbVertical:s.default.func,tagName:s.default.string,thumbSize:s.default.number,thumbMinSize:s.default.number,hideTracksWhenNotNeeded:s.default.bool,autoHide:s.default.bool,autoHideTimeout:s.default.number,autoHideDuration:s.default.number,autoHeight:s.default.bool,autoHeightMin:s.default.oneOfType([s.default.number,s.default.string]),autoHeightMax:s.default.oneOfType([s.default.number,s.default.string]),universal:s.default.bool,style:s.default.object,children:s.default.node},k.defaultProps={renderView:y.renderViewDefault,renderTrackHorizontal:y.renderTrackHorizontalDefault,renderTrackVertical:y.renderTrackVerticalDefault,renderThumbHorizontal:y.renderThumbHorizontalDefault,renderThumbVertical:y.renderThumbVerticalDefault,tagName:"div",thumbMinSize:30,hideTracksWhenNotNeeded:!1,autoHide:!1,autoHideTimeout:1e3,autoHideDuration:200,autoHeight:!1,autoHeightMin:0,autoHeightMax:200,universal:!1}},7679:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.containerStyleDefault={position:"relative",overflow:"hidden",width:"100%",height:"100%"},t.containerStyleAutoHeight={height:"auto"},t.viewStyleDefault={position:"absolute",top:0,left:0,right:0,bottom:0,overflow:"scroll",WebkitOverflowScrolling:"touch"},t.viewStyleAutoHeight={position:"relative",top:void 0,left:void 0,right:void 0,bottom:void 0},t.viewStyleUniversalInitial={overflow:"hidden",marginRight:0,marginBottom:0},t.trackHorizontalStyleDefault={position:"absolute",height:6},t.trackVerticalStyleDefault={position:"absolute",width:6},t.thumbHorizontalStyleDefault={position:"relative",display:"block",height:"100%"},t.thumbVerticalStyleDefault={position:"relative",display:"block",width:"100%"},t.disableSelectStyle={userSelect:"none"},t.disableSelectStyleReset={userSelect:""}},1298:(e,t,n)=>{"use strict";t.$B=void 0;var r,a=n(4608),o=(r=a)&&r.__esModule?r:{default:r};o.default,t.$B=o.default},6839:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.clientHeight,n=getComputedStyle(e),r=n.paddingTop,a=n.paddingBottom;return t-parseFloat(r)-parseFloat(a)}},4749:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t=e.clientWidth,n=getComputedStyle(e),r=n.paddingLeft,a=n.paddingRight;return t-parseFloat(r)-parseFloat(a)}},3305:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){if(!1!==i)return i;if("undefined"!=typeof document){var e=document.createElement("div");(0,o.default)(e,{width:100,height:100,position:"absolute",top:-9999,overflow:"scroll",MsOverflowStyle:"scrollbar"}),document.body.appendChild(e),i=e.offsetWidth-e.clientWidth,document.body.removeChild(e)}else i=0;return i||0};var r,a=n(3879),o=(r=a)&&r.__esModule?r:{default:r};var i=!1},5205:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return"string"==typeof e}},8669:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){return!1}},2496:(e,t,n)=>{"use strict";var r=n(139),a=n(3759),o=n(7288);e.exports=function(){function e(e,t,n,r,i,l){l!==o&&a(!1,"Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types")}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t};return n.checkPropTypes=r,n.PropTypes=n,n}},2196:(e,t,n)=>{e.exports=n(2496)()},7288:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},4448:(e,t,n)=>{"use strict";var r=n(7294),a=n(3840);function o(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n
-HTML; - - return $login_button; - } - - /** - * Removes the login form from the HTML DOM - * - * @return void - */ - public function remove_login_form() { - ?> - - - * @copyright 2015-2023 daggerhart - * @license http://www.gnu.org/licenses/gpl-2.0.txt GPL-2.0+ - */ - -/** - * OpenID_Connect_Generic_Option_Logger class. - * - * Simple class for logging messages to the options table. - * - * @package OpenID_Connect_Generic - * @category Logging - */ -class OpenID_Connect_Generic_Option_Logger { - - /** - * Thw WordPress option name/key. - * - * @var string - */ - const OPTION_NAME = 'openid-connect-generic-logs'; - - /** - * The default message type. - * - * @var string - */ - private $default_message_type = 'none'; - - /** - * The number of items to keep in the log. - * - * @var int - */ - private $log_limit = 1000; - - /** - * Whether or not logging is enabled. - * - * @var bool - */ - private $logging_enabled = true; - - /** - * Internal cache of logs. - * - * @var array - */ - private $logs; - - /** - * Setup the logger according to the needs of the instance. - * - * @param string|null $default_message_type The log message type. - * @param bool|TRUE|null $logging_enabled Whether logging is enabled. - * @param int|null $log_limit The log entry limit. - */ - public function __construct( $default_message_type = null, $logging_enabled = null, $log_limit = null ) { - if ( ! is_null( $default_message_type ) ) { - $this->default_message_type = $default_message_type; - } - if ( ! is_null( $logging_enabled ) ) { - $this->logging_enabled = boolval( $logging_enabled ); - } - if ( ! is_null( $log_limit ) ) { - $this->log_limit = intval( $log_limit ); - } - } - - /** - * Save an array of data to the logs. - * - * @param string|array|WP_Error $data The log message data. - * @param string|null $type The log message type. - * @param float|null $processing_time Optional event processing time. - * @param int|null $time The log message timestamp (default: time()). - * @param int|null $user_ID The current WordPress user ID (default: get_current_user_id()). - * @param string|null $request_uri The related HTTP request URI (default: $_SERVER['REQUEST_URI']|'Unknown'). - * - * @return bool - */ - public function log( $data, $type = null, $processing_time = null, $time = null, $user_ID = null, $request_uri = null ) { - if ( boolval( $this->logging_enabled ) ) { - $logs = $this->get_logs(); - $logs[] = $this->make_message( $data, $type, $processing_time, $time, $user_ID, $request_uri ); - $logs = $this->upkeep_logs( $logs ); - return $this->save_logs( $logs ); - } - - return false; - } - - /** - * Retrieve all log messages. - * - * @return array - */ - public function get_logs() { - if ( empty( $this->logs ) ) { - $this->logs = get_option( self::OPTION_NAME, array() ); - } - - // Call the upkeep_logs function to give the appearance that logs have been reduced to the $this->log_limit. - // The logs are actually limited during a logging action but the logger isn't available during a simple settings update. - return $this->upkeep_logs( $this->logs ); - } - - /** - * Get the name of the option where this log is stored. - * - * @return string - */ - public function get_option_name() { - return self::OPTION_NAME; - } - - /** - * Create a message array containing the data and other information. - * - * @param string|array|WP_Error $data The log message data. - * @param string|null $type The log message type. - * @param float|null $processing_time Optional event processing time. - * @param int|null $time The log message timestamp (default: time()). - * @param int|null $user_ID The current WordPress user ID (default: get_current_user_id()). - * @param string|null $request_uri The related HTTP request URI (default: $_SERVER['REQUEST_URI']|'Unknown'). - * - * @return array - */ - private function make_message( $data, $type, $processing_time, $time, $user_ID, $request_uri ) { - // Determine the type of message. - if ( empty( $type ) ) { - $type = $this->default_message_type; - - if ( is_array( $data ) && isset( $data['type'] ) ) { - $type = $data['type']; - unset( $data['type'] ); - } - - if ( is_wp_error( $data ) ) { - $type = $data->get_error_code(); - $data = $data->get_error_message( $type ); - } - } - - if ( empty( $request_uri ) ) { - $request_uri = ( ! empty( $_SERVER['REQUEST_URI'] ) ) ? esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ) : 'Unknown'; - $request_uri = preg_replace( '/code=([^&]+)/i', 'code=', $request_uri ); - } - - // Construct the message. - $message = array( - 'type' => $type, - 'time' => ! empty( $time ) ? $time : time(), - 'user_ID' => ! is_null( $user_ID ) ? $user_ID : get_current_user_id(), - 'uri' => $request_uri, - 'data' => $data, - 'processing_time' => $processing_time, - ); - - return $message; - } - - /** - * Keep the log count under the limit. - * - * @param array $logs The plugin logs. - * - * @return array - */ - private function upkeep_logs( $logs ) { - $items_to_remove = count( $logs ) - $this->log_limit; - - if ( $items_to_remove > 0 ) { - // Only keep the last $log_limit messages from the end. - $logs = array_slice( $logs, $items_to_remove ); - } - - return $logs; - } - - /** - * Save the log messages. - * - * @param array $logs The array of log messages. - * - * @return bool - */ - private function save_logs( $logs ) { - // Save the logs. - $this->logs = $logs; - return update_option( self::OPTION_NAME, $logs, false ); - } - - /** - * Clear all log messages. - * - * @return void - */ - public function clear_logs() { - $this->save_logs( array() ); - } - - /** - * Get a simple html table of all the logs. - * - * @param array $logs The array of log messages. - * - * @return string - */ - public function get_logs_table( $logs = array() ) { - if ( empty( $logs ) ) { - $logs = $this->get_logs(); - } - $logs = array_reverse( $logs ); - - ini_set( 'xdebug.var_display_max_depth', '-1' ); - - ob_start(); - ?> - - - - - - - - - - - - - -
-
- - -
-
- - -
-
- - user_login : '0' ); ?> -
-
- - -
-
- - -
-
- - * @copyright 2015-2023 daggerhart - * @license http://www.gnu.org/licenses/gpl-2.0.txt GPL-2.0+ - */ - -/** - * OpenId_Connect_Generic_Option_Settings class. - * - * WordPress options handling. - * - * @package OpenID_Connect_Generic - * @category Settings - * - * Legacy Settings: - * - * @property string $ep_login The login endpoint. - * @property string $ep_token The token endpoint. - * @property string $ep_userinfo The userinfo endpoint. - * - * OAuth Client Settings: - * - * @property string $login_type How the client (login form) should provide login options. - * @property string $client_id The ID the client will be recognized as when connecting the to Identity provider server. - * @property string $client_secret The secret key the IDP server expects from the client. - * @property string $scope The list of scopes this client should access. - * @property string $endpoint_login The IDP authorization endpoint URL. - * @property string $endpoint_userinfo The IDP User information endpoint URL. - * @property string $endpoint_token The IDP token validation endpoint URL. - * @property string $endpoint_end_session The IDP logout endpoint URL. - * @property string $acr_values The Authentication contract as defined on the IDP. - * - * Non-standard Settings: - * - * @property bool $no_sslverify The flag to enable/disable SSL verification during authorization. - * @property int $http_request_timeout The timeout for requests made to the IDP. Default value is 5. - * @property string $identity_key The key in the user claim array to find the user's identification data. - * @property string $nickname_key The key in the user claim array to find the user's nickname. - * @property string $email_format The key(s) in the user claim array to formulate the user's email address. - * @property string $displayname_format The key(s) in the user claim array to formulate the user's display name. - * @property bool $identify_with_username The flag which indicates how the user's identity will be determined. - * @property int $state_time_limit The valid time limit of the state, in seconds. Defaults to 180 seconds. - * - * Plugin Settings: - * - * @property bool $enforce_privacy The flag to indicates whether a user us required to be authenticated to access the site. - * @property bool $alternate_redirect_uri The flag to indicate whether to use the alternative redirect URI. - * @property bool $token_refresh_enable The flag whether to support refresh tokens by IDPs. - * @property bool $link_existing_users The flag to indicate whether to link to existing WordPress-only accounts or greturn an error. - * @property bool $create_if_does_not_exist The flag to indicate whether to create new users or not. - * @property bool $redirect_user_back The flag to indicate whether to redirect the user back to the page on which they started. - * @property bool $redirect_on_logout The flag to indicate whether to redirect to the login screen on session expiration. - * @property bool $enable_logging The flag to enable/disable logging. - * @property int $log_limit The maximum number of log entries to keep. - */ -class OpenID_Connect_Generic_Option_Settings { - - /** - * WordPress option name/key. - * - * @var string - */ - const OPTION_NAME = 'openid_connect_generic_settings'; - - /** - * Stored option values array. - * - * @var array - */ - private $values; - - /** - * Default plugin settings values. - * - * @var array - */ - private $default_settings; - - /** - * List of settings that can be defined by environment variables. - * - * @var array - */ - private $environment_settings = array( - 'client_id' => 'OIDC_CLIENT_ID', - 'client_secret' => 'OIDC_CLIENT_SECRET', - 'endpoint_end_session' => 'OIDC_ENDPOINT_LOGOUT_URL', - 'endpoint_login' => 'OIDC_ENDPOINT_LOGIN_URL', - 'endpoint_token' => 'OIDC_ENDPOINT_TOKEN_URL', - 'endpoint_userinfo' => 'OIDC_ENDPOINT_USERINFO_URL', - 'login_type' => 'OIDC_LOGIN_TYPE', - 'scope' => 'OIDC_CLIENT_SCOPE', - 'create_if_does_not_exist' => 'OIDC_CREATE_IF_DOES_NOT_EXIST', - 'enforce_privacy' => 'OIDC_ENFORCE_PRIVACY', - 'link_existing_users' => 'OIDC_LINK_EXISTING_USERS', - 'redirect_on_logout' => 'OIDC_REDIRECT_ON_LOGOUT', - 'redirect_user_back' => 'OIDC_REDIRECT_USER_BACK', - 'acr_values' => 'OIDC_ACR_VALUES', - 'enable_logging' => 'OIDC_ENABLE_LOGGING', - 'log_limit' => 'OIDC_LOG_LIMIT', - ); - - /** - * The class constructor. - * - * @param array $default_settings The default plugin settings values. - * @param bool $granular_defaults The granular defaults. - */ - public function __construct( $default_settings = array(), $granular_defaults = true ) { - $this->default_settings = $default_settings; - $this->values = array(); - - $this->values = (array) get_option( self::OPTION_NAME, $this->default_settings ); - - // For each defined environment variable/constant be sure the settings key is set. - foreach ( $this->environment_settings as $key => $constant ) { - if ( defined( $constant ) ) { - $this->__set( $key, constant( $constant ) ); - } - } - - if ( $granular_defaults ) { - $this->values = array_replace_recursive( $this->default_settings, $this->values ); - } - } - - /** - * Magic getter for settings. - * - * @param string $key The array key/option name. - * - * @return mixed - */ - public function __get( $key ) { - if ( isset( $this->values[ $key ] ) ) { - return $this->values[ $key ]; - } - } - - /** - * Magic setter for settings. - * - * @param string $key The array key/option name. - * @param mixed $value The option value. - * - * @return void - */ - public function __set( $key, $value ) { - $this->values[ $key ] = $value; - } - - /** - * Magic method to check is an attribute isset. - * - * @param string $key The array key/option name. - * - * @return bool - */ - public function __isset( $key ) { - return isset( $this->values[ $key ] ); - } - - /** - * Magic method to clear an attribute. - * - * @param string $key The array key/option name. - * - * @return void - */ - public function __unset( $key ) { - unset( $this->values[ $key ] ); - } - - /** - * Get the plugin settings array. - * - * @return array - */ - public function get_values() { - return $this->values; - } - - /** - * Get the plugin WordPress options name. - * - * @return string - */ - public function get_option_name() { - return self::OPTION_NAME; - } - - /** - * Save the plugin options to the WordPress options table. - * - * @return void - */ - public function save() { - - // For each defined environment variable/constant be sure it isn't saved to the database. - foreach ( $this->environment_settings as $key => $constant ) { - if ( defined( $constant ) ) { - $this->__unset( $key ); - } - } - - update_option( self::OPTION_NAME, $this->values ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/includes/openid-connect-generic-settings-page.php b/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/includes/openid-connect-generic-settings-page.php deleted file mode 100644 index 9543dd26..00000000 --- a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/includes/openid-connect-generic-settings-page.php +++ /dev/null @@ -1,603 +0,0 @@ - - * @copyright 2015-2023 daggerhart - * @license http://www.gnu.org/licenses/gpl-2.0.txt GPL-2.0+ - */ - -/** - * OpenID_Connect_Generic_Settings_Page class. - * - * Admin settings page. - * - * @package OpenID_Connect_Generic - * @category Settings - */ -class OpenID_Connect_Generic_Settings_Page { - - /** - * Local copy of the settings provided by the base plugin. - * - * @var OpenID_Connect_Generic_Option_Settings - */ - private $settings; - - /** - * Instance of the plugin logger. - * - * @var OpenID_Connect_Generic_Option_Logger - */ - private $logger; - - /** - * The controlled list of settings & associated defined during - * construction for i18n reasons. - * - * @var array - */ - private $settings_fields = array(); - - /** - * Options page slug. - * - * @var string - */ - private $options_page_name = 'openid-connect-generic-settings'; - - /** - * Options page settings group name. - * - * @var string - */ - private $settings_field_group; - - /** - * Settings page class constructor. - * - * @param OpenID_Connect_Generic_Option_Settings $settings The plugin settings object. - * @param OpenID_Connect_Generic_Option_Logger $logger The plugin logging class object. - */ - public function __construct( OpenID_Connect_Generic_Option_Settings $settings, OpenID_Connect_Generic_Option_Logger $logger ) { - - $this->settings = $settings; - $this->logger = $logger; - $this->settings_field_group = $this->settings->get_option_name() . '-group'; - - $fields = $this->get_settings_fields(); - - // Some simple pre-processing. - foreach ( $fields as $key => &$field ) { - $field['key'] = $key; - $field['name'] = $this->settings->get_option_name() . '[' . $key . ']'; - } - - // Allow alterations of the fields. - $this->settings_fields = $fields; - } - - /** - * Hook the settings page into WordPress. - * - * @param OpenID_Connect_Generic_Option_Settings $settings A plugin settings object instance. - * @param OpenID_Connect_Generic_Option_Logger $logger A plugin logger object instance. - * - * @return void - */ - public static function register( OpenID_Connect_Generic_Option_Settings $settings, OpenID_Connect_Generic_Option_Logger $logger ) { - $settings_page = new self( $settings, $logger ); - - // Add our options page the the admin menu. - add_action( 'admin_menu', array( $settings_page, 'admin_menu' ) ); - - // Register our settings. - add_action( 'admin_init', array( $settings_page, 'admin_init' ) ); - } - - /** - * Implements hook admin_menu to add our options/settings page to the - * dashboard menu. - * - * @return void - */ - public function admin_menu() { - add_options_page( - __( 'OpenID Connect - Generic Client', 'daggerhart-openid-connect-generic' ), - __( 'OpenID Connect Client', 'daggerhart-openid-connect-generic' ), - 'manage_options', - $this->options_page_name, - array( $this, 'settings_page' ) - ); - } - - /** - * Implements hook admin_init to register our settings. - * - * @return void - */ - public function admin_init() { - register_setting( - $this->settings_field_group, - $this->settings->get_option_name(), - array( - $this, - 'sanitize_settings', - ) - ); - - add_settings_section( - 'client_settings', - __( 'Client Settings', 'daggerhart-openid-connect-generic' ), - array( $this, 'client_settings_description' ), - $this->options_page_name - ); - - add_settings_section( - 'user_settings', - __( 'WordPress User Settings', 'daggerhart-openid-connect-generic' ), - array( $this, 'user_settings_description' ), - $this->options_page_name - ); - - add_settings_section( - 'authorization_settings', - __( 'Authorization Settings', 'daggerhart-openid-connect-generic' ), - array( $this, 'authorization_settings_description' ), - $this->options_page_name - ); - - add_settings_section( - 'log_settings', - __( 'Log Settings', 'daggerhart-openid-connect-generic' ), - array( $this, 'log_settings_description' ), - $this->options_page_name - ); - - // Preprocess fields and add them to the page. - foreach ( $this->settings_fields as $key => $field ) { - // Make sure each key exists in the settings array. - if ( ! isset( $this->settings->{ $key } ) ) { - $this->settings->{ $key } = null; - } - - // Determine appropriate output callback. - switch ( $field['type'] ) { - case 'checkbox': - $callback = 'do_checkbox'; - break; - - case 'select': - $callback = 'do_select'; - break; - - case 'text': - default: - $callback = 'do_text_field'; - break; - } - - // Add the field. - add_settings_field( - $key, - $field['title'], - array( $this, $callback ), - $this->options_page_name, - $field['section'], - $field - ); - } - } - - /** - * Get the plugin settings fields definition. - * - * @return array - */ - private function get_settings_fields() { - - /** - * Simple settings fields have: - * - * - title - * - description - * - type ( checkbox | text | select ) - * - section - settings/option page section ( client_settings | authorization_settings ) - * - example (optional example will appear beneath description and be wrapped in ) - */ - $fields = array( - 'login_type' => array( - 'title' => __( 'Login Type', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Select how the client (login form) should provide login options.', 'daggerhart-openid-connect-generic' ), - 'type' => 'select', - 'options' => array( - 'button' => __( 'OpenID Connect button on login form', 'daggerhart-openid-connect-generic' ), - 'auto' => __( 'Auto Login - SSO', 'daggerhart-openid-connect-generic' ), - ), - 'disabled' => defined( 'OIDC_LOGIN_TYPE' ), - 'section' => 'client_settings', - ), - 'client_id' => array( - 'title' => __( 'Client ID', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'The ID this client will be recognized as when connecting the to Identity provider server.', 'daggerhart-openid-connect-generic' ), - 'example' => 'my-wordpress-client-id', - 'type' => 'text', - 'disabled' => defined( 'OIDC_CLIENT_ID' ), - 'section' => 'client_settings', - ), - 'client_secret' => array( - 'title' => __( 'Client Secret Key', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Arbitrary secret key the server expects from this client. Can be anything, but should be very unique.', 'daggerhart-openid-connect-generic' ), - 'type' => 'text', - 'disabled' => defined( 'OIDC_CLIENT_SECRET' ), - 'section' => 'client_settings', - ), - 'scope' => array( - 'title' => __( 'OpenID Scope', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Space separated list of scopes this client should access.', 'daggerhart-openid-connect-generic' ), - 'example' => 'email profile openid offline_access', - 'type' => 'text', - 'disabled' => defined( 'OIDC_CLIENT_SCOPE' ), - 'section' => 'client_settings', - ), - 'endpoint_login' => array( - 'title' => __( 'Login Endpoint URL', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Identify provider authorization endpoint.', 'daggerhart-openid-connect-generic' ), - 'example' => 'https://example.com/oauth2/authorize', - 'type' => 'text', - 'disabled' => defined( 'OIDC_ENDPOINT_LOGIN_URL' ), - 'section' => 'client_settings', - ), - 'endpoint_userinfo' => array( - 'title' => __( 'Userinfo Endpoint URL', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Identify provider User information endpoint.', 'daggerhart-openid-connect-generic' ), - 'example' => 'https://example.com/oauth2/UserInfo', - 'type' => 'text', - 'disabled' => defined( 'OIDC_ENDPOINT_USERINFO_URL' ), - 'section' => 'client_settings', - ), - 'endpoint_token' => array( - 'title' => __( 'Token Validation Endpoint URL', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Identify provider token endpoint.', 'daggerhart-openid-connect-generic' ), - 'example' => 'https://example.com/oauth2/token', - 'type' => 'text', - 'disabled' => defined( 'OIDC_ENDPOINT_TOKEN_URL' ), - 'section' => 'client_settings', - ), - 'endpoint_end_session' => array( - 'title' => __( 'End Session Endpoint URL', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Identify provider logout endpoint.', 'daggerhart-openid-connect-generic' ), - 'example' => 'https://example.com/oauth2/logout', - 'type' => 'text', - 'disabled' => defined( 'OIDC_ENDPOINT_LOGOUT_URL' ), - 'section' => 'client_settings', - ), - 'acr_values' => array( - 'title' => __( 'ACR values', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Use a specific defined authentication contract from the IDP - optional.', 'daggerhart-openid-connect-generic' ), - 'type' => 'text', - 'disabled' => defined( 'OIDC_ACR_VALUES' ), - 'section' => 'client_settings', - ), - 'identity_key' => array( - 'title' => __( 'Identity Key', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Where in the user claim array to find the user\'s identification data. Possible standard values: preferred_username, name, or sub. If you\'re having trouble, use "sub".', 'daggerhart-openid-connect-generic' ), - 'example' => 'preferred_username', - 'type' => 'text', - 'section' => 'client_settings', - ), - 'no_sslverify' => array( - 'title' => __( 'Disable SSL Verify', 'daggerhart-openid-connect-generic' ), - // translators: %1$s HTML tags for layout/styles, %2$s closing HTML tag for styles. - 'description' => sprintf( __( 'Do not require SSL verification during authorization. The OAuth extension uses curl to make the request. By default CURL will generally verify the SSL certificate to see if its valid an issued by an accepted CA. This setting disabled that verification.%1$sNot recommended for production sites.%2$s', 'daggerhart-openid-connect-generic' ), '
', '' ), - 'type' => 'checkbox', - 'section' => 'client_settings', - ), - 'http_request_timeout' => array( - 'title' => __( 'HTTP Request Timeout', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Set the timeout for requests made to the IDP. Default value is 5.', 'daggerhart-openid-connect-generic' ), - 'example' => 30, - 'type' => 'text', - 'section' => 'client_settings', - ), - 'enforce_privacy' => array( - 'title' => __( 'Enforce Privacy', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Require users be logged in to see the site.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'disabled' => defined( 'OIDC_ENFORCE_PRIVACY' ), - 'section' => 'authorization_settings', - ), - 'alternate_redirect_uri' => array( - 'title' => __( 'Alternate Redirect URI', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Provide an alternative redirect route. Useful if your server is causing issues with the default admin-ajax method. You must flush rewrite rules after changing this setting. This can be done by saving the Permalinks settings page.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'section' => 'authorization_settings', - ), - 'nickname_key' => array( - 'title' => __( 'Nickname Key', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Where in the user claim array to find the user\'s nickname. Possible standard values: preferred_username, name, or sub.', 'daggerhart-openid-connect-generic' ), - 'example' => 'preferred_username', - 'type' => 'text', - 'section' => 'client_settings', - ), - 'email_format' => array( - 'title' => __( 'Email Formatting', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'String from which the user\'s email address is built. Specify "{email}" as long as the user claim contains an email claim.', 'daggerhart-openid-connect-generic' ), - 'example' => '{email}', - 'type' => 'text', - 'section' => 'client_settings', - ), - 'displayname_format' => array( - 'title' => __( 'Display Name Formatting', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'String from which the user\'s display name is built.', 'daggerhart-openid-connect-generic' ), - 'example' => '{given_name} {family_name}', - 'type' => 'text', - 'section' => 'client_settings', - ), - 'identify_with_username' => array( - 'title' => __( 'Identify with User Name', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'If checked, the user\'s identity will be determined by the user name instead of the email address.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'section' => 'client_settings', - ), - 'state_time_limit' => array( - 'title' => __( 'State time limit', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'State valid time in seconds. Defaults to 180', 'daggerhart-openid-connect-generic' ), - 'type' => 'number', - 'section' => 'client_settings', - ), - 'token_refresh_enable' => array( - 'title' => __( 'Enable Refresh Token', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'If checked, support refresh tokens used to obtain access tokens from supported IDPs.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'section' => 'client_settings', - ), - 'link_existing_users' => array( - 'title' => __( 'Link Existing Users', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'If a WordPress account already exists with the same identity as a newly-authenticated user over OpenID Connect, login as that user instead of generating an error.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'disabled' => defined( 'OIDC_LINK_EXISTING_USERS' ), - 'section' => 'user_settings', - ), - 'create_if_does_not_exist' => array( - 'title' => __( 'Create user if does not exist', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'If the user identity is not linked to an existing WordPress user, it is created. If this setting is not enabled, and if the user authenticates with an account which is not linked to an existing WordPress user, then the authentication will fail.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'disabled' => defined( 'OIDC_CREATE_IF_DOES_NOT_EXIST' ), - 'section' => 'user_settings', - ), - 'redirect_user_back' => array( - 'title' => __( 'Redirect Back to Origin Page', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'After a successful OpenID Connect authentication, this will redirect the user back to the page on which they clicked the OpenID Connect login button. This will cause the login process to proceed in a traditional WordPress fashion. For example, users logging in through the default wp-login.php page would end up on the WordPress Dashboard and users logging in through the WooCommerce "My Account" page would end up on their account page.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'disabled' => defined( 'OIDC_REDIRECT_USER_BACK' ), - 'section' => 'user_settings', - ), - 'redirect_on_logout' => array( - 'title' => __( 'Redirect to the login screen when session is expired', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'When enabled, this will automatically redirect the user back to the WordPress login page if their access token has expired.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'disabled' => defined( 'OIDC_REDIRECT_ON_LOGOUT' ), - 'section' => 'user_settings', - ), - 'enable_logging' => array( - 'title' => __( 'Enable Logging', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Very simple log messages for debugging purposes.', 'daggerhart-openid-connect-generic' ), - 'type' => 'checkbox', - 'disabled' => defined( 'OIDC_ENABLE_LOGGING' ), - 'section' => 'log_settings', - ), - 'log_limit' => array( - 'title' => __( 'Log Limit', 'daggerhart-openid-connect-generic' ), - 'description' => __( 'Number of items to keep in the log. These logs are stored as an option in the database, so space is limited.', 'daggerhart-openid-connect-generic' ), - 'type' => 'number', - 'disabled' => defined( 'OIDC_LOG_LIMIT' ), - 'section' => 'log_settings', - ), - ); - - return apply_filters( 'openid-connect-generic-settings-fields', $fields ); - } - - /** - * Sanitization callback for settings/option page. - * - * @param array $input The submitted settings values. - * - * @return array - */ - public function sanitize_settings( $input ) { - $options = array(); - - // Loop through settings fields to control what we're saving. - foreach ( $this->settings_fields as $key => $field ) { - if ( isset( $input[ $key ] ) ) { - $options[ $key ] = sanitize_text_field( trim( $input[ $key ] ) ); - } else { - $options[ $key ] = ''; - } - } - - return $options; - } - - /** - * Output the options/settings page. - * - * @return void - */ - public function settings_page() { - wp_enqueue_style( 'daggerhart-openid-connect-generic-admin', plugin_dir_url( __DIR__ ) . 'css/styles-admin.css', array(), OpenID_Connect_Generic::VERSION, 'all' ); - - $redirect_uri = admin_url( 'admin-ajax.php?action=openid-connect-authorize' ); - - if ( $this->settings->alternate_redirect_uri ) { - $redirect_uri = site_url( '/openid-connect-authorize' ); - } - ?> -
-

- -
- settings_field_group ); - do_settings_sections( $this->options_page_name ); - submit_button(); - - // Simple debug to view settings array. - if ( isset( $_GET['debug'] ) ) { - var_dump( $this->settings->get_values() ); - } - ?> -
- -

- -

- - -

-

- - [openid_connect_generic_login_button] -

-

- - [openid_connect_generic_auth_url] -

- - settings->enable_logging ) { ?> -

-
- logger->get_logs_table() ); ?> -
- - -
- - - value="settings->{ $field['key'] } ); ?>"> - do_field_description( $field ); - } - - /** - * Output a checkbox for a boolean setting. - * - hidden field is default value so we don't have to check isset() on save. - * - * @param array $field The settings field definition array. - * - * @return void - */ - public function do_checkbox( $field ) { - $hidden_value = 0; - if ( ! empty( $field['disabled'] ) && boolval( $field['disabled'] ) === true ) { - $hidden_value = intval( $this->settings->{ $field['key'] } ); - } - ?> - - - value="1" - settings->{ $field['key'] }, 1 ); ?>> - do_field_description( $field ); - } - - /** - * Output a select control. - * - * @param array $field The settings field definition array. - * - * @return void - */ - public function do_select( $field ) { - $current_value = isset( $this->settings->{ $field['key'] } ) ? $this->settings->{ $field['key'] } : ''; - ?> - - do_field_description( $field ); - } - - /** - * Output the field description, and example if present. - * - * @param array $field The settings field definition array. - * - * @return void - */ - public function do_field_description( $field ) { - ?> -

- - -
: - - -

- \n" -"Language-Team: LANGUAGE \n" -"Language: en\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" -"X-Poedit-Country: United States\n" -"X-Poedit-SourceCharset: UTF-8\n" -"X-Poedit-KeywordsList: " -"__;_e;_x:1,2c;_ex:1,2c;_n:1,2;_nx:1,2,4c;_n_noop:1,2;_nx_noop:1,2,3c;esc_" -"attr__;esc_html__;esc_attr_e;esc_html_e;esc_attr_x:1,2c;esc_html_x:1,2c;\n" -"X-Poedit-Basepath: ../\n" -"X-Poedit-SearchPath-0: .\n" -"X-Poedit-Bookmarks: \n" -"X-Textdomain-Support: yes\n" -"X-Generator: grunt-wp-i18n 1.0.3\n" - -#: includes/openid-connect-generic-client-wrapper.php:293 -msgid "Session expired. Please login again." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:540 -msgid "User identity is not linked to an existing WordPress user." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:598 -msgid "Invalid user." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:816 -msgid "No appropriate username found." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:826 -#. translators: %1$s is the santitized version of the username from the IDP. -msgid "Username %1$s could not be sanitized." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:848 -#. translators: %1$s is the configured User Claim nickname key. -msgid "No nickname found in user claim using key: %1$s." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:945 -msgid "User claim incomplete." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:1048 -msgid "Bad user claim result." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:1114 -msgid "Can not authorize." -msgstr "" - -#: includes/openid-connect-generic-client-wrapper.php:1143 -msgid "Failed user creation." -msgstr "" - -#: includes/openid-connect-generic-client.php:176 -msgid "Missing state." -msgstr "" - -#: includes/openid-connect-generic-client.php:180 -msgid "Invalid state." -msgstr "" - -#: includes/openid-connect-generic-client.php:195 -msgid "Missing authentication code." -msgstr "" - -#: includes/openid-connect-generic-client.php:240 -msgid "Request for authentication token failed." -msgstr "" - -#: includes/openid-connect-generic-client.php:273 -msgid "Refresh token failed." -msgstr "" - -#: includes/openid-connect-generic-client.php:288 -msgid "Missing token body." -msgstr "" - -#: includes/openid-connect-generic-client.php:296 -msgid "Invalid token." -msgstr "" - -#: includes/openid-connect-generic-client.php:349 -msgid "Request for userinfo failed." -msgstr "" - -#: includes/openid-connect-generic-client.php:409 -msgid "Missing authentication state." -msgstr "" - -#: includes/openid-connect-generic-client.php:446 -msgid "No identity token." -msgstr "" - -#: includes/openid-connect-generic-client.php:453 -msgid "Missing identity token." -msgstr "" - -#: includes/openid-connect-generic-client.php:480 -msgid "Bad ID token claim." -msgstr "" - -#: includes/openid-connect-generic-client.php:485 -msgid "No subject identity." -msgstr "" - -#: includes/openid-connect-generic-client.php:491 -msgid "No matching acr values." -msgstr "" - -#: includes/openid-connect-generic-client.php:511 -msgid "Bad user claim." -msgstr "" - -#: includes/openid-connect-generic-client.php:531 -msgid "Invalid user claim." -msgstr "" - -#: includes/openid-connect-generic-client.php:536 -msgid "Error from the IDP." -msgstr "" - -#: includes/openid-connect-generic-client.php:545 -msgid "Incorrect user claim." -msgstr "" - -#: includes/openid-connect-generic-client.php:552 -msgid "Unauthorized access." -msgstr "" - -#: includes/openid-connect-generic-login-form.php:122 -#. translators: %1$s is the error code from the IDP. -msgid "ERROR (%1$s)" -msgstr "" - -#: includes/openid-connect-generic-login-form.php:141 -msgid "Login with OpenID Connect" -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:228 -msgid "Details" -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:229 -msgid "Data" -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:236 -msgid "Date" -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:240 -msgid "Type" -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:244 -msgid "User" -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:248 -msgid "URI " -msgstr "" - -#: includes/openid-connect-generic-option-logger.php:252 -msgid "Response Time (sec)" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:108 -msgid "OpenID Connect - Generic Client" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:109 -msgid "OpenID Connect Client" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:133 -msgid "Client Settings" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:140 -msgid "WordPress User Settings" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:147 -msgid "Authorization Settings" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:154 -msgid "Log Settings" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:212 -msgid "Login Type" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:213 -msgid "Select how the client (login form) should provide login options." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:216 -msgid "OpenID Connect button on login form" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:217 -msgid "Auto Login - SSO" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:223 -msgid "Client ID" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:224 -msgid "" -"The ID this client will be recognized as when connecting the to Identity " -"provider server." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:231 -msgid "Client Secret Key" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:232 -msgid "" -"Arbitrary secret key the server expects from this client. Can be anything, " -"but should be very unique." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:238 -msgid "OpenID Scope" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:239 -msgid "Space separated list of scopes this client should access." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:246 -msgid "Login Endpoint URL" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:247 -msgid "Identify provider authorization endpoint." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:254 -msgid "Userinfo Endpoint URL" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:255 -msgid "Identify provider User information endpoint." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:262 -msgid "Token Validation Endpoint URL" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:263 -msgid "Identify provider token endpoint." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:270 -msgid "End Session Endpoint URL" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:271 -msgid "Identify provider logout endpoint." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:278 -msgid "ACR values" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:279 -msgid "Use a specific defined authentication contract from the IDP - optional." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:285 -msgid "Identity Key" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:286 -msgid "" -"Where in the user claim array to find the user's identification data. " -"Possible standard values: preferred_username, name, or sub. If you're " -"having trouble, use \"sub\"." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:292 -msgid "Disable SSL Verify" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:294 -#. translators: %1$s HTML tags for layout/styles, %2$s closing HTML tag for -#. styles. -msgid "" -"Do not require SSL verification during authorization. The OAuth extension " -"uses curl to make the request. By default CURL will generally verify the " -"SSL certificate to see if its valid an issued by an accepted CA. This " -"setting disabled that verification.%1$sNot recommended for production " -"sites.%2$s" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:299 -msgid "HTTP Request Timeout" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:300 -msgid "Set the timeout for requests made to the IDP. Default value is 5." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:306 -msgid "Enforce Privacy" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:307 -msgid "Require users be logged in to see the site." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:313 -msgid "Alternate Redirect URI" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:314 -msgid "" -"Provide an alternative redirect route. Useful if your server is causing " -"issues with the default admin-ajax method. You must flush rewrite rules " -"after changing this setting. This can be done by saving the Permalinks " -"settings page." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:319 -msgid "Nickname Key" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:320 -msgid "" -"Where in the user claim array to find the user's nickname. Possible " -"standard values: preferred_username, name, or sub." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:326 -msgid "Email Formatting" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:327 -msgid "" -"String from which the user's email address is built. Specify \"{email}\" as " -"long as the user claim contains an email claim." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:333 -msgid "Display Name Formatting" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:334 -msgid "String from which the user's display name is built." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:340 -msgid "Identify with User Name" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:341 -msgid "" -"If checked, the user's identity will be determined by the user name instead " -"of the email address." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:346 -msgid "State time limit" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:347 -msgid "State valid time in seconds. Defaults to 180" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:352 -msgid "Enable Refresh Token" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:353 -msgid "" -"If checked, support refresh tokens used to obtain access tokens from " -"supported IDPs." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:358 -msgid "Link Existing Users" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:359 -msgid "" -"If a WordPress account already exists with the same identity as a " -"newly-authenticated user over OpenID Connect, login as that user instead of " -"generating an error." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:365 -msgid "Create user if does not exist" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:366 -msgid "" -"If the user identity is not linked to an existing WordPress user, it is " -"created. If this setting is not enabled, and if the user authenticates with " -"an account which is not linked to an existing WordPress user, then the " -"authentication will fail." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:372 -msgid "Redirect Back to Origin Page" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:373 -msgid "" -"After a successful OpenID Connect authentication, this will redirect the " -"user back to the page on which they clicked the OpenID Connect login " -"button. This will cause the login process to proceed in a traditional " -"WordPress fashion. For example, users logging in through the default " -"wp-login.php page would end up on the WordPress Dashboard and users logging " -"in through the WooCommerce \"My Account\" page would end up on their " -"account page." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:379 -msgid "Redirect to the login screen when session is expired" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:380 -msgid "" -"When enabled, this will automatically redirect the user back to the " -"WordPress login page if their access token has expired." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:386 -msgid "Enable Logging" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:387 -msgid "Very simple log messages for debugging purposes." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:393 -msgid "Log Limit" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:394 -msgid "" -"Number of items to keep in the log. These logs are stored as an option in " -"the database, so space is limited." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:456 -msgid "Notes" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:459 -msgid "Redirect URI" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:463 -msgid "Login Button Shortcode" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:467 -msgid "Authentication URL Shortcode" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:472 -msgid "Logs" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:561 -msgid "Example" -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:574 -msgid "Enter your OpenID Connect identity provider settings." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:583 -msgid "Modify the interaction between OpenID Connect and WordPress users." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:592 -msgid "Control the authorization mechanics of the site." -msgstr "" - -#: includes/openid-connect-generic-settings-page.php:601 -msgid "Log information about login attempts through OpenID Connect Generic." -msgstr "" - -#: openid-connect-generic.php:242 -msgid "Private site" -msgstr "" - -#. Plugin Name of the plugin/theme -msgid "OpenID Connect Generic" -msgstr "" - -#. Plugin URI of the plugin/theme -msgid "https://github.com/daggerhart/openid-connect-generic" -msgstr "" - -#. Description of the plugin/theme -msgid "" -"Connect to an OpenID Connect identity provider using Authorization Code " -"Flow." -msgstr "" - -#. Author of the plugin/theme -msgid "daggerhart" -msgstr "" - -#. Author URI of the plugin/theme -msgid "http://www.daggerhart.com" -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/openid-connect-generic.php b/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/openid-connect-generic.php deleted file mode 100644 index 81895e9a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/openid-connect-generic.php +++ /dev/null @@ -1,439 +0,0 @@ - - * @copyright 2015-2023 daggerhart - * @license http://www.gnu.org/licenses/gpl-2.0.txt GPL-2.0+ - * @link https://github.com/oidc-wp - * - * @wordpress-plugin - * Plugin Name: OpenID Connect Generic - * Plugin URI: https://github.com/oidc-wp/openid-connect-generic - * Description: Connect to an OpenID Connect identity provider using Authorization Code Flow. - * Version: 3.10.2 - * Requires at least: 5.0 - * Requires PHP: 7.4 - * Author: daggerhart - * Author URI: https://www.daggerhartlab.com - * Text Domain: daggerhart-openid-connect-generic - * Domain Path: /languages - * License: GPL-2.0+ - * License URI: http://www.gnu.org/licenses/gpl-2.0.txt - * GitHub Plugin URI: https://github.com/oidc-wp/openid-connect-generic - */ - -/* -Notes - Spec Doc - http://openid.net/specs/openid-connect-basic-1_0-32.html - - Filters - - openid-connect-generic-alter-request - 3 args: request array, plugin settings, specific request op - - openid-connect-generic-settings-fields - modify the fields provided on the settings page - - openid-connect-generic-settings - modify settings values early in plugin bootstrap. - - openid-connect-generic-login-button-text - modify the login button text - - openid-connect-generic-cookie-redirect-url - modify the redirect url stored as a cookie - - openid-connect-generic-user-login-test - (bool) should the user be logged in based on their claim - - openid-connect-generic-user-creation-test - (bool) should the user be created based on their claim - - openid-connect-generic-auth-url - modify the authentication url - - openid-connect-generic-alter-user-claim - modify the user_claim before a new user is created - - openid-connect-generic-alter-user-data - modify user data before a new user is created - - openid-connect-modify-token-response-before-validation - modify the token response before validation - - openid-connect-modify-id-token-claim-before-validation - modify the token claim before validation - - openid-connect-generic-new-state-value - modify the user's state value before it us saved. - - Actions - - openid-connect-generic-user-create - 2 args: fires when a new user is created by this plugin - - openid-connect-generic-user-update - 1 arg: user ID, fires when user is updated by this plugin - - openid-connect-generic-update-user-using-current-claim - 2 args: fires every time an existing user logs in and the claims are updated. - - openid-connect-generic-redirect-user-back - 2 args: $redirect_url, $user. Allows interruption of redirect during login. - - openid-connect-generic-user-logged-in - 1 arg: $user, fires when user is logged in. - - openid-connect-generic-cron-daily - daily cron action - - openid-connect-generic-state-not-found - the given state does not exist in the database, regardless of its expiration. - - openid-connect-generic-state-expired - the given state exists, but expired before this login attempt. - - Callable actions - - User Meta - - openid-connect-generic-subject-identity - the identity of the user provided by the idp - - openid-connect-generic-last-id-token-claim - the user's most recent id_token claim, decoded - - openid-connect-generic-last-user-claim - the user's most recent user_claim - - openid-connect-generic-last-token-response - the user's most recent token response - - Options - - openid_connect_generic_settings - plugin settings - - openid-connect-generic-valid-states - locally stored generated states -*/ - - -/** - * OpenID_Connect_Generic class. - * - * Defines plugin initialization functionality. - * - * @package OpenID_Connect_Generic - * @category General - */ -class OpenID_Connect_Generic { - - /** - * Singleton instance of self - * - * @var OpenID_Connect_Generic - */ - protected static $_instance = null; - - /** - * Plugin version. - * - * @var string - */ - const VERSION = '3.10.2'; - - /** - * Plugin settings. - * - * @var OpenID_Connect_Generic_Option_Settings - */ - private $settings; - - /** - * Plugin logs. - * - * @var OpenID_Connect_Generic_Option_Logger - */ - private $logger; - - /** - * Openid Connect Generic client - * - * @var OpenID_Connect_Generic_Client - */ - private $client; - - /** - * Client wrapper. - * - * @var OpenID_Connect_Generic_Client_Wrapper - */ - public $client_wrapper; - - /** - * Setup the plugin - * - * @param OpenID_Connect_Generic_Option_Settings $settings The settings object. - * @param OpenID_Connect_Generic_Option_Logger $logger The loggin object. - * - * @return void - */ - public function __construct( OpenID_Connect_Generic_Option_Settings $settings, OpenID_Connect_Generic_Option_Logger $logger ) { - $this->settings = $settings; - $this->logger = $logger; - self::$_instance = $this; - } - - // @codeCoverageIgnoreStart - - /** - * WordPress Hook 'init'. - * - * @return void - */ - public function init() { - - // Allow altering the settings. - $this->settings = apply_filters( 'openid-connect-generic-settings', $this->settings ); - - $this->client = new OpenID_Connect_Generic_Client( - $this->settings->client_id, - $this->settings->client_secret, - $this->settings->scope, - $this->settings->endpoint_login, - $this->settings->endpoint_userinfo, - $this->settings->endpoint_token, - $this->get_redirect_uri( $this->settings ), - $this->settings->acr_values, - $this->get_state_time_limit( $this->settings ), - $this->logger - ); - - $this->client_wrapper = OpenID_Connect_Generic_Client_Wrapper::register( $this->client, $this->settings, $this->logger ); - if ( defined( 'WP_CLI' ) && WP_CLI ) { - return; - } - - OpenID_Connect_Generic_Login_Form::register( $this->settings, $this->client_wrapper ); - - // Add a shortcode to get the auth URL. - add_shortcode( 'openid_connect_generic_auth_url', array( $this->client_wrapper, 'get_authentication_url' ) ); - - // Add actions to our scheduled cron jobs. - add_action( 'openid-connect-generic-cron-daily', array( $this, 'cron_states_garbage_collection' ) ); - - $this->upgrade(); - - if ( is_admin() ) { - OpenID_Connect_Generic_Settings_Page::register( $this->settings, $this->logger ); - } - } - - /** - * Get the default redirect URI. - * - * @param OpenID_Connect_Generic_Option_Settings $settings The settings object. - * - * @return string - */ - public function get_redirect_uri( OpenID_Connect_Generic_Option_Settings $settings ) { - $redirect_uri = admin_url( 'admin-ajax.php?action=openid-connect-authorize' ); - - if ( $settings->alternate_redirect_uri ) { - $redirect_uri = site_url( '/openid-connect-authorize' ); - } - - return $redirect_uri; - } - - /** - * Get the default state time limit. - * - * @param OpenID_Connect_Generic_Option_Settings $settings The settings object. - * - * @return int - */ - public function get_state_time_limit( OpenID_Connect_Generic_Option_Settings $settings ) { - $state_time_limit = 180; - // State time limit cannot be zero. - if ( $settings->state_time_limit ) { - $state_time_limit = intval( $settings->state_time_limit ); - } - - return $state_time_limit; - } - - /** - * Check if privacy enforcement is enabled, and redirect users that aren't - * logged in. - * - * @return void - */ - public function enforce_privacy_redirect() { - if ( $this->settings->enforce_privacy && ! is_user_logged_in() ) { - // The client endpoint relies on the wp-admin ajax endpoint. - if ( - ! defined( 'DOING_AJAX' ) || - ! boolval( constant( 'DOING_AJAX' ) ) || - ! isset( $_GET['action'] ) || - 'openid-connect-authorize' != $_GET['action'] ) { - auth_redirect(); - } - } - } - - /** - * Enforce privacy settings for rss feeds. - * - * @param string $content The content. - * - * @return mixed - */ - public function enforce_privacy_feeds( $content ) { - if ( $this->settings->enforce_privacy && ! is_user_logged_in() ) { - $content = __( 'Private site', 'daggerhart-openid-connect-generic' ); - } - return $content; - } - - /** - * Handle plugin upgrades - * - * @return void - */ - public function upgrade() { - $last_version = get_option( 'openid-connect-generic-plugin-version', 0 ); - $settings = $this->settings; - - if ( version_compare( self::VERSION, $last_version, '>' ) ) { - // An upgrade is required. - self::setup_cron_jobs(); - - // @todo move this to another file for upgrade scripts - if ( isset( $settings->ep_login ) ) { - $settings->endpoint_login = $settings->ep_login; - $settings->endpoint_token = $settings->ep_token; - $settings->endpoint_userinfo = $settings->ep_userinfo; - - unset( $settings->ep_login, $settings->ep_token, $settings->ep_userinfo ); - $settings->save(); - } - - // Update the stored version number. - update_option( 'openid-connect-generic-plugin-version', self::VERSION ); - } - } - - /** - * Expire state transients by attempting to access them and allowing the - * transient's own mechanisms to delete any that have expired. - * - * @return void - */ - public function cron_states_garbage_collection() { - global $wpdb; - $states = $wpdb->get_col( "SELECT `option_name` FROM {$wpdb->options} WHERE `option_name` LIKE '_transient_openid-connect-generic-state--%'" ); - - if ( ! empty( $states ) ) { - foreach ( $states as $state ) { - $transient = str_replace( '_transient_', '', $state ); - get_transient( $transient ); - } - } - } - - /** - * Ensure cron jobs are added to the schedule. - * - * @return void - */ - public static function setup_cron_jobs() { - if ( ! wp_next_scheduled( 'openid-connect-generic-cron-daily' ) ) { - wp_schedule_event( time(), 'daily', 'openid-connect-generic-cron-daily' ); - } - } - - /** - * Activation hook. - * - * @return void - */ - public static function activation() { - self::setup_cron_jobs(); - } - - /** - * Deactivation hook. - * - * @return void - */ - public static function deactivation() { - wp_clear_scheduled_hook( 'openid-connect-generic-cron-daily' ); - } - - /** - * Simple autoloader. - * - * @param string $class The class name. - * - * @return void - */ - public static function autoload( $class ) { - $prefix = 'OpenID_Connect_Generic_'; - - if ( stripos( $class, $prefix ) !== 0 ) { - return; - } - - $filename = $class . '.php'; - - // Internal files are all lowercase and use dashes in filenames. - if ( false === strpos( $filename, '\\' ) ) { - $filename = strtolower( str_replace( '_', '-', $filename ) ); - } else { - $filename = str_replace( '\\', DIRECTORY_SEPARATOR, $filename ); - } - - $filepath = __DIR__ . '/includes/' . $filename; - - if ( file_exists( $filepath ) ) { - require_once $filepath; - } - } - - /** - * Instantiate the plugin and hook into WordPress. - * - * @return void - */ - public static function bootstrap() { - /** - * This is a documented valid call for spl_autoload_register. - * - * @link https://www.php.net/manual/en/function.spl-autoload-register.php#71155 - */ - spl_autoload_register( array( 'OpenID_Connect_Generic', 'autoload' ) ); - - $settings = new OpenID_Connect_Generic_Option_Settings( - // Default settings values. - array( - // OAuth client settings. - 'login_type' => defined( 'OIDC_LOGIN_TYPE' ) ? OIDC_LOGIN_TYPE : 'button', - 'client_id' => defined( 'OIDC_CLIENT_ID' ) ? OIDC_CLIENT_ID : '', - 'client_secret' => defined( 'OIDC_CLIENT_SECRET' ) ? OIDC_CLIENT_SECRET : '', - 'scope' => defined( 'OIDC_CLIENT_SCOPE' ) ? OIDC_CLIENT_SCOPE : '', - 'endpoint_login' => defined( 'OIDC_ENDPOINT_LOGIN_URL' ) ? OIDC_ENDPOINT_LOGIN_URL : '', - 'endpoint_userinfo' => defined( 'OIDC_ENDPOINT_USERINFO_URL' ) ? OIDC_ENDPOINT_USERINFO_URL : '', - 'endpoint_token' => defined( 'OIDC_ENDPOINT_TOKEN_URL' ) ? OIDC_ENDPOINT_TOKEN_URL : '', - 'endpoint_end_session' => defined( 'OIDC_ENDPOINT_LOGOUT_URL' ) ? OIDC_ENDPOINT_LOGOUT_URL : '', - 'acr_values' => defined( 'OIDC_ACR_VALUES' ) ? OIDC_ACR_VALUES : '', - - // Non-standard settings. - 'no_sslverify' => 0, - 'http_request_timeout' => 5, - 'identity_key' => 'preferred_username', - 'nickname_key' => 'preferred_username', - 'email_format' => '{email}', - 'displayname_format' => '', - 'identify_with_username' => false, - 'state_time_limit' => 180, - - // Plugin settings. - 'enforce_privacy' => defined( 'OIDC_ENFORCE_PRIVACY' ) ? intval( OIDC_ENFORCE_PRIVACY ) : 0, - 'alternate_redirect_uri' => 0, - 'token_refresh_enable' => 1, - 'link_existing_users' => defined( 'OIDC_LINK_EXISTING_USERS' ) ? intval( OIDC_LINK_EXISTING_USERS ) : 0, - 'create_if_does_not_exist' => defined( 'OIDC_CREATE_IF_DOES_NOT_EXIST' ) ? intval( OIDC_CREATE_IF_DOES_NOT_EXIST ) : 1, - 'redirect_user_back' => defined( 'OIDC_REDIRECT_USER_BACK' ) ? intval( OIDC_REDIRECT_USER_BACK ) : 0, - 'redirect_on_logout' => defined( 'OIDC_REDIRECT_ON_LOGOUT' ) ? intval( OIDC_REDIRECT_ON_LOGOUT ) : 1, - 'enable_logging' => defined( 'OIDC_ENABLE_LOGGING' ) ? intval( OIDC_ENABLE_LOGGING ) : 0, - 'log_limit' => defined( 'OIDC_LOG_LIMIT' ) ? intval( OIDC_LOG_LIMIT ) : 1000, - ) - ); - - $logger = new OpenID_Connect_Generic_Option_Logger( 'error', $settings->enable_logging, $settings->log_limit ); - - $plugin = new self( $settings, $logger ); - - add_action( 'init', array( $plugin, 'init' ) ); - - // Privacy hooks. - add_action( 'template_redirect', array( $plugin, 'enforce_privacy_redirect' ), 0 ); - add_filter( 'the_content_feed', array( $plugin, 'enforce_privacy_feeds' ), 999 ); - add_filter( 'the_excerpt_rss', array( $plugin, 'enforce_privacy_feeds' ), 999 ); - add_filter( 'comment_text_rss', array( $plugin, 'enforce_privacy_feeds' ), 999 ); - } - - /** - * Create (if needed) and return a singleton of self. - * - * @return OpenID_Connect_Generic - */ - public static function instance() { - if ( null === self::$_instance ) { - self::bootstrap(); - } - return self::$_instance; - } -} - -OpenID_Connect_Generic::instance(); - -register_activation_hook( __FILE__, array( 'OpenID_Connect_Generic', 'activation' ) ); -register_deactivation_hook( __FILE__, array( 'OpenID_Connect_Generic', 'deactivation' ) ); - -// Provide publicly accessible plugin helper functions. -require_once 'includes/functions.php'; diff --git a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/readme.txt b/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/readme.txt deleted file mode 100644 index 6d9cd567..00000000 --- a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/readme.txt +++ /dev/null @@ -1,137 +0,0 @@ -=== OpenID Connect Generic Client === -Contributors: daggerhart, tnolte -Tags: security, login, oauth2, openidconnect, apps, authentication, autologin, sso -Requires at least: 5.0 -Tested up to: 6.9.0 -Stable tag: 3.10.2 -Requires PHP: 7.4 -License: GPLv2 or later -License URI: http://www.gnu.org/licenses/gpl-2.0.html - -A simple client that provides SSO or opt-in authentication against a generic OAuth2 Server implementation. - -== Description == - -This plugin allows to authenticate users against OpenID Connect OAuth2 API with Authorization Code Flow. -Once installed, it can be configured to automatically authenticate users (SSO), or provide a "Login with OpenID Connect" -button on the login form. After consent has been obtained, an existing user is automatically logged into WordPress, while -new users are created in WordPress database. - -Much of the documentation can be found on the Settings > OpenID Connect Generic dashboard page. - -Please submit issues to the Github repo: https://github.com/daggerhart/openid-connect-generic - -== Installation == - -1. Upload to the `/wp-content/plugins/` directory -1. Activate the plugin -1. Visit Settings > OpenID Connect and configure to meet your needs - -== Frequently Asked Questions == - -= What is the client's Redirect URI? = - -Most OAuth2 servers will require whitelisting a set of redirect URIs for security purposes. The Redirect URI provided -by this client is like so: https://example.com/wp-admin/admin-ajax.php?action=openid-connect-authorize - -Replace `example.com` with your domain name and path to WordPress. - -= Can I change the client's Redirect URI? = - -Some OAuth2 servers do not allow for a client redirect URI to contain a query string. The default URI provided by -this module leverages WordPress's `admin-ajax.php` endpoint as an easy way to provide a route that does not include -HTML, but this will naturally involve a query string. Fortunately, this plugin provides a setting that will make use of -an alternate redirect URI that does not include a query string. - -On the settings page for this plugin (Dashboard > Settings > OpenID Connect Generic) there is a checkbox for -**Alternate Redirect URI**. When checked, the plugin will use the Redirect URI -`https://example.com/openid-connect-authorize`. - - -== Changelog == - -= 3.10.2 = - -* Fix: @socialmedialabs - Regression affecting SSO Auto Login with url handling improvement changes. - -= 3.10.1 = - -* Chore: @daggerhart - Readme updates and clarifications. -* Chore: @daggerhart - Release workflow updates. -* Improved error handling for malformed urls. -* Fix: @JUVOJustin - Change request for userinfo to GET. -* Feature: @JUVOJustin - New filter for settings values `openid-connect-generic-settings`. -* Feature: @JUVOJustin - New filter for state values `openid-connect-generic-new-state-value`. - -= 3.10.0 = - -* Chore: @timnolte - Dependency updates. -* Fix: @drzraf - Prevents running the auth url filter twice. -* Fix: @timnolte - Updates the log cleanup handling to properly retain the configured number of log entries. -* Fix: @timnolte - Updates the log display output to reflect the log retention policy. -* Chore: @timnolte - Adds Unit Testing & New Local Development Environment. -* Feature: @timnolte - Updates logging to allow for tracking processing time. -* Feature: @menno-ll - Adds a remember me feature via a new filter. -* Improvement: @menno-ll - Updates WP Cookie Expiration to Same as Session Length. - -= 3.9.1 = - -* Improvement: @timnolte - Refactors Composer setup and GitHub Actions. -* Improvement: @timnolte - Bumps WordPress tested version compatibility. - -= 3.9.0 = - -* Feature: @matchaxnb - Added support for additional configuration constants. -* Feature: @schanzen - Added support for agregated claims. -* Fix: @rkcreation - Fixed access token not updating user metadata after login. -* Fix: @danc1248 - Fixed user creation issue on Multisite Networks. -* Feature: @RobjS - Added plugin singleton to support for more developer customization. -* Feature: @jkouris - Added action hook to allow custom handling of session expiration. -* Fix: @tommcc - Fixed admin CSS loading only on the plugin settings screen. -* Feature: @rkcreation - Added method to refresh the user claim. -* Feature: @Glowsome - Added acr_values support & verification checks that it when defined in options is honored. -* Fix: @timnolte - Fixed regression which caused improper fallback on missing claims. -* Fix: @slykar - Fixed missing query string handling in redirect URL. -* Fix: @timnolte - Fixed issue with some user linking and user creation handling. -* Improvement: @timnolte - Fixed plugin settings typos and screen formatting. -* Security: @timnolte - Updated build tooling security vulnerabilities. -* Improvement: @timnolte - Changed build tooling scripts. - -= 3.8.5 = - -* Fix: @timnolte - Fixed missing URL request validation before use & ensure proper current page URL is setup for Redirect Back. -* Fix: @timnolte - Fixed Redirect URL Logic to Handle Sub-directory Installs. -* Fix: @timnolte - Fixed issue with redirecting user back when the openid_connect_generic_auth_url shortcode is used. - -= 3.8.4 = - -* Fix: @timnolte - Fixed invalid State object access for redirection handling. -* Improvement: @timnolte - Fixed local wp-env Docker development environment. -* Improvement: @timnolte - Fixed Composer scripts for linting and static analysis. - -= 3.8.3 = - -* Fix: @timnolte - Fixed problems with proper redirect handling. -* Improvement: @timnolte - Changes redirect handling to use State instead of cookies. -* Improvement: @timnolte - Refactored additional code to meet coding standards. - -= 3.8.2 = - -* Fix: @timnolte - Fixed reported XSS vulnerability on WordPress login screen. - -= 3.8.1 = - -* Fix: @timnolte - Prevent SSO redirect on password protected posts. -* Fix: @timnolte - CI/CD build issues. -* Fix: @timnolte - Invalid redirect handling on logout for Auto Login setting. - -= 3.8.0 = - -* Feature: @timnolte - Ability to use 6 new constants for setting client configuration instead of storing in the DB. -* Improvement: @timnolte - Plugin development & contribution updates. -* Improvement: @timnolte - Refactored to meet WordPress coding standards. -* Improvement: @timnolte - Refactored to provide localization. - --------- - -[See the previous changelogs here](https://github.com/oidc-wp/openid-connect-generic/blob/main/CHANGELOG.md#changelog) diff --git a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/wp-cli.yml b/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/wp-cli.yml deleted file mode 100644 index 3f430d6f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/daggerhart-openid-connect-generic/wp-cli.yml +++ /dev/null @@ -1 +0,0 @@ -path: /app/wp diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/assets.yml b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/assets.yml deleted file mode 100644 index f32e729c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/assets.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: Plugin asset/readme update on WordPress.org - -on: workflow_dispatch - -jobs: - trunk: - name: Push assets to trunk on WordPress.org - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: https://code.forgejo.org/actions/checkout@v4 - - - name: Install and cache rsync - uses: https://github.com/awalsh128/cache-apt-pkgs-action@latest - with: - packages: rsync subversion - version: 1.0 - - - name: WordPress.org plugin asset/readme update - uses: https://github.com/10up/action-wordpress-plugin-asset-update@stable - env: - SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }} - SVN_USERNAME: ${{ secrets.SVN_USERNAME }} - SLUG: event-bridge-for-activitypub diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/deploy.yml b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/deploy.yml deleted file mode 100644 index 45fae27a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/deploy.yml +++ /dev/null @@ -1,26 +0,0 @@ -name: Deploy to WordPress.org - -on: - push: - tags: '[0-9]+.[0-9]+.[0-9]+' - -jobs: - tag: - name: Deploy tagged release on WordPress.org - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: https://code.forgejo.org/actions/checkout@v4 - - - name: Install and cache rsync and subversion - uses: https://github.com/awalsh128/cache-apt-pkgs-action@latest - with: - packages: rsync subversion - version: 1.0 - - - name: WordPress Plugin Deploy - uses: https://github.com/10up/action-wordpress-plugin-deploy@stable - env: - SVN_PASSWORD: ${{ secrets.SVN_PASSWORD }} - SVN_USERNAME: ${{ secrets.SVN_USERNAME }} - SLUG: event-bridge-for-activitypub diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpcs.yml b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpcs.yml deleted file mode 100644 index 21622e2e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpcs.yml +++ /dev/null @@ -1,61 +0,0 @@ -name: PHP Code Checker - -on: - push: - branches: - - main - pull_request: - -jobs: - phpcs: - name: PHP Code Checker - runs-on: ubuntu-latest - strategy: - matrix: - php-versions: ['8.1'] - steps: - - name: Checkout - uses: https://code.forgejo.org/actions/checkout@v4 - - - name: Cache Composer - id: cache-composer - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: | - ./vendor/ - key: cache-composer-3 - - - name: Setup cache environment for PHP Extensions - id: php-extensions-cache - uses: https://github.com/shivammathur/cache-extensions@v1 - with: - php-version: ${{ matrix.php-versions }} - extensions: dom, iconv, json, libxml, zip - key: php-extensions-cache-v1 - - - name: Cache PHP extensions - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: ${{ steps.php-extensions-cache.outputs.dir }} - key: ${{ steps.php-extensions-cache.outputs.key }} - restore-keys: ${{ steps.php-extensions-cache.outputs.key }} - - - name: Setup PHP - uses: https://github.com/shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php-versions }} - extensions: dom, iconv, json, libxml, zip - coverage: none - tools: composer, cs2pr - env: - runner: self-hosted - GITHUB_TOKEN: ${{ env.COMPOSER_TOKEN }} - - - name: Install Composer dependencies for PHP - if: steps.cache-composer.outputs.cache-hit != 'true' - uses: ramsey/composer-install@v3 - env: - COMPOSER_AUTH: '{"github-oauth": {"github.com": "${{ secrets.COMPOSER_TOKEN }}"}}' - - - name: Run PHP_CodeSniffer - run: ./vendor/bin/phpcs diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpstan.yml b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpstan.yml deleted file mode 100644 index ce87dacc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpstan.yml +++ /dev/null @@ -1,87 +0,0 @@ -name: PHPStan Tests - -on: - push: - branches: - - main - pull_request: - -env: - WP_TESTS_DIR: /workspace/wordpress-test-lib - WP_CORE_DIR: /workspace/wordpress - -jobs: - phpstan: - runs-on: ubuntu-latest - strategy: - matrix: - php-version: ['7.4','8.1','8.4'] - name: PHPStan for WordPress ${{ matrix.php-version }} - steps: - - name: Checkout - uses: https://code.forgejo.org/actions/checkout@v4 - - - name: Cache WordPress Setup and installed plugins (Event plugins and ActivityPub plugin). - id: cache-wordpress - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: | - ${{ env.WP_CORE_DIR }} - ${{ env.WP_TESTS_DIR }} - key: cache-phpstan-wordpress-6.7-activitypub-5.1.0-2 - - - name: Cache Composer - id: cache-composer - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: | - ./vendor/ - key: cache-composer-3 - - - name: Setup cache environment for PHP Extensions - id: php-extensions-cache - uses: https://github.com/shivammathur/cache-extensions@v1 - with: - php-version: ${{ matrix.php-version }} - extensions: dom, iconv, json, libxml, zip - key: php-extensions-cache-v1 - - - name: Cache PHP extensions - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: ${{ steps.php-extensions-cache.outputs.dir }} - key: ${{ steps.php-extensions-cache.outputs.key }} - restore-keys: ${{ steps.php-extensions-cache.outputs.key }} - - - name: Setup PHP - uses: https://github.com/shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php-version }} - extensions: dom, iconv, json, libxml, zip - coverage: none - tools: composer, cs2pr - env: - runner: self-hosted - GITHUB_TOKEN: ${{ env.COMPOSER_TOKEN }} - - - name: Install Composer dependencies for PHP - if: steps.cache-composer.outputs.cache-hit != 'true' - uses: ramsey/composer-install@v3 - env: - COMPOSER_AUTH: '{"github-oauth": {"github.com": "${{ secrets.COMPOSER_TOKEN }}"}}' - - - name: Log debug information - run: | - git --version - php --version - composer --version - - - name: Install third party plugins, so that PHP Stan finds that functions - if: steps.cache-wordpress.outputs.cache-hit != 'true' - run: bash bin/install-wp-tests.sh wordpress_test root root 127.0.0.1 latest true false false true - - - name: Running PHPStan Analyze - if: ${{ success() || failure() }} - run: | - ./vendor/bin/phpstan --version - ./vendor/bin/phpstan analyze -vv --memory-limit=2G --error-format=checkstyle | cs2pr diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpunit.yml b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpunit.yml deleted file mode 100644 index 9c07a0db..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/phpunit.yml +++ /dev/null @@ -1,147 +0,0 @@ -name: PHPUnit - -on: - push: - branches: - - main - pull_request: - -env: - WP_TESTS_DIR: /workspace/wordpress-test-lib - WP_CORE_DIR: /workspace/wordpress - -jobs: - phpunit: - runs-on: ubuntu-latest - services: - mysql: - image: mariadb - env: - MYSQL_ROOT_PASSWORD: root - strategy: - matrix: - php-version: ['7.4', '8.1', '8.3', '8.4'] - wordpress-version: ['6.7', '6.8-RC3'] - name: "PHPUnit: PHP ${{ matrix.php-version }} - WordPress ${{ matrix.wordpress-version }}" - continue-on-error: true - steps: - - name: Checkout - uses: https://code.forgejo.org/actions/checkout@v4 - - - name: Cache WordPress Setup and installed plugins (Event plugins and ActivityPub plugin). - id: cache-wordpress - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: | - ${{ env.WP_CORE_DIR }} - ${{ env.WP_TESTS_DIR }} - key: cache-phpunit-wordpress-${{ matrix.wordpress-version }}-activitypub-5.7.0 - - - name: Cache Composer - id: cache-composer - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: | - ./vendor/ - key: cache-composer-3 - - - name: Setup cache environment for PHP Extensions - id: php-extensions-cache - uses: https://github.com/shivammathur/cache-extensions@v1 - with: - php-version: ${{ matrix.php-version }} - extensions: dom, iconv, json, libxml, zip - key: php-extensions-cache-v1 - - - name: Cache PHP extensions - uses: https://code.forgejo.org/actions/cache@v4 - with: - path: ${{ steps.php-extensions-cache.outputs.dir }} - key: ${{ steps.php-extensions-cache.outputs.key }} - restore-keys: ${{ steps.php-extensions-cache.outputs.key }} - - - name: Setup PHP - uses: https://github.com/shivammathur/setup-php@v2 - with: - php-version: ${{ matrix.php-version }} - extensions: dom, iconv, json, libxml, zip - coverage: none - tools: composer, cs2pr - env: - runner: self-hosted - GITHUB_TOKEN: ${{ secrets.COMPOSER_TOKEN }} - - - name: Install Composer dependencies for PHP - if: steps.cache-composer.outputs.cache-hit != 'true' - uses: ramsey/composer-install@v3 - env: - COMPOSER_AUTH: '{"github-oauth": {"github.com": "${{ secrets.COMPOSER_TOKEN }}"}}' - - - name: Install and cache mysqladmin needed to initialize the test database - uses: https://github.com/awalsh128/cache-apt-pkgs-action@latest - with: - packages: mysql-client - version: 1.0 - - - name: Setup Test Environment - if: steps.cache-wordpress.outputs.cache-hit != 'true' - run: bash bin/install-wp-tests.sh wordpress_test root root 127.0.0.1 ${{ matrix.wordpress-version }} false false false false - - - name: Initialize WordPress test database - if: steps.cache-wordpress.outputs.cache-hit != 'false' - run: bash bin/install-wp-tests.sh wordpress_test root root 127.0.0.1 ${{ matrix.wordpress-version }} false true true true - - - name: Run General Tests - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for The Events Calendar - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=the_events_calendar - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for VS Event List - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=vs_event_list - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for GatherPress - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=gatherpress - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for Events Manager - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=events_manager - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for WP Event Manager - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=wp_event_manager - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for Eventin (WP Event Solution) - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=eventin - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for Modern Events Calendar Lite - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=modern_events_calendar_lite - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for EventPrime - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=eventprime - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for Event Organiser - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=event_organiser - env: - PHP_VERSION: ${{ matrix.php-version }} - - - name: Run Integration tests for EventON – Events Calendar - run: cd /workspace/Event-Federation/wordpress-event-bridge-for-activitypub/ && ./vendor/bin/phpunit --filter=eventon - env: - PHP_VERSION: ${{ matrix.php-version }} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/release.yml b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/release.yml deleted file mode 100644 index 78d84211..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.forgejo/workflows/release.yml +++ /dev/null @@ -1,17 +0,0 @@ -on: - push: - tags: - - '^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?$' - -jobs: - upload-release: - runs-on: ubuntu-latest - steps: - - uses: https://code.forgejo.org/actions/checkout@v4 - - - uses: https://code.forgejo.org/actions/forgejo-release@v2 - with: - direction: upload - url: https://codeberg.org - release-notes: ${{ TAG }} - token: ${{ secrets.GITHUB_TOKEN }} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.gitattributes b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.gitattributes deleted file mode 100644 index f5aa0a25..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/.gitattributes +++ /dev/null @@ -1,26 +0,0 @@ -.distignore export-ignore -.forgejo export-ignore -.gitattributes export-ignore -.gitignore export-ignore -.wordpress-org export-ignore -.wp-env.json export-ignore -bin export-ignore -CODE_OF_CONDUCT.md export-ignore -composer.json export-ignore -composer.lock export-ignore -docker-compose.yml export-ignore -Dockerfile export-ignore -docs export-ignore -FEDERATION.md export-ignore -Gruntfile.js export-ignore -node_modules export-ignore -package.json export-ignore -package-lock.json export-ignore -phpcs.xml export-ignore -phpstan.neon export-ignore -phpstan.neon.dist export-ignore -phpunit.xml export-ignore -README.md export-ignore -src export-ignore -tests export-ignore -vendor export-ignore diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/CHANGELOG.md deleted file mode 100644 index d87b1e66..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/CHANGELOG.md +++ /dev/null @@ -1,48 +0,0 @@ -# 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.1.0/), -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - -## [1.1.0] - 2025-04-12 - -### Added - -* Basic support for Starter Kits - -### Fixed - -* Fixed: Uncatched error in following process (issue #145) -* Fixed: Compatibility with ActivityPub plugin version 5.7.0 - -## [1.0.0] - 2025-02-11 - -### Changed - -* This plugin now depends on ActivityPub plugin version greater than 5.1.0 - -### Added - -* Support for the EventPrime event plugin -* Event self-announce feature at configurable time before event starts -* Blueprint (Preview via WordPress Playground) -* Event Sources feature: cache and list events from remote ActivityPub profiles on your site -* Custom ActivityPub preview -* Admin setting to enforce sending summary of events as plain text - -### Fixed - -* The Events Calendar date times when using the Gutenberg editor. -* Improved admin UI for event-category mapping - -## [0.3.5] - 2025-01-03 - -### Fixed - -* Images of Acknowledgements in Admin UI - -## [0.3.4] - 2024-12-21 - -* Initial release on WordPress.org - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/CONTRIBUTING.md b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/CONTRIBUTING.md deleted file mode 100644 index 3f790ce3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/CONTRIBUTING.md +++ /dev/null @@ -1,44 +0,0 @@ -# Contributing - -Thank you for considering contributing to Event Bridge For ActivityPub WordPress Plugin 💜 - -You can contribute in the following ways: - -- Finding and reporting bugs -- Translating the plugin into various languages -- Contributing code by fixing bugs or implementing features -- Improving the documentation -- Proposing ideas for new features - -## Bug reports - -Bug reports and feature suggestions must use descriptive and concise titles and be submitted to [Codeberg Issues](https://codeberg.org/Event-Federation/wordpress-event-bridge-for-activitypub/issues) or the [WordPress.org Support Forum](https://wordpress.org/support/plugin/event-bridge-for-activitypub/). Please use the search function to make sure that you are not submitting duplicates, and that a similar report or request has not already been resolved or rejected. - -## Translations - -You can submit translations via [translate.WordPress.org](https://translate.wordpress.org/projects/wp-plugins/event-bridge-for-activitypub/). These changes are merged by WordPress itself to each plugin installation. - -## Pull requests - -**Please use clean, concise titles for your pull requests.** Unless the pull request is about refactoring code or other internal tasks, assume that the person reading the pull request title is not a programmer or WordPress developer, but instead a WordPress user, and **try to describe your change or fix from their perspective**. We use commit squashing, so the final commit in the main branch will carry the title of the pull request, and commits from the main branch are fed into the changelog. The changelog is separated into [keepachangelog.com categories](https://keepachangelog.com/en/1.0.0/), and while that spec does not prescribe how the entries ought to be named, for easier sorting, start your pull request titles using one of the verbs "Add", "Change", "Deprecate", "Remove", or "Fix" (present tense). - -Example: - -| Not ideal | Better | -| ------------------------------------ | ------------------------------------------------------------- | -| Fixed NoMethodError in RemovalWorker | Fix nil error when removing statuses caused by race condition | - -It is not always possible to phrase every change in such a manner, but it is desired. - -**The smaller the set of changes in the pull request is, the quicker it can be reviewed and merged.** Splitting tasks into multiple smaller pull requests is often preferable. - -**Pull requests that do not pass automated checks may not be reviewed**. In particular, you need to keep in mind: - -- Unit and integration test (PHPUnit) -- Code style rules (PHP_CodeSniffer) -- [WordPress plugin guidelines](https://developer.wordpress.org/plugins/wordpress-org/detailed-plugin-guidelines/) - -## Documentation - -- Documentation for users is currently in the README.md and readme.txt files and the admin pages of the plugin (see the `.template/` folder), although this can change if it could be advantageous. -- Documentation for developers is the the projects [Wiki](https://codeberg.org/Event-Federation/wordpress-event-bridge-for-activitypub/wiki). diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/LICENSE b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/LICENSE deleted file mode 100644 index 241d6f31..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/LICENSE +++ /dev/null @@ -1,235 +0,0 @@ -GNU AFFERO GENERAL PUBLIC LICENSE -Version 3, 19 November 2007 - -Copyright (C) 2007 Free Software Foundation, Inc. - -Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. - - Preamble - -The GNU Affero General Public License is a free, copyleft license for software and other kinds of works, specifically designed to ensure cooperation with the community in the case of network server software. - -The licenses for most software and other practical works are designed to take away your freedom to share and change the works. By contrast, our General Public Licenses are intended to guarantee your freedom to share and change all versions of a program--to make sure it remains free software for all its users. - -When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for them if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs, and that you know you can do these things. - -Developers that use our General Public Licenses protect your rights with two steps: (1) assert copyright on the software, and (2) offer you this License which gives you legal permission to copy, distribute and/or modify the software. - -A secondary benefit of defending all users' freedom is that improvements made in alternate versions of the program, if they receive widespread use, become available for other developers to incorporate. Many developers of free software are heartened and encouraged by the resulting cooperation. However, in the case of software used on network servers, this result may fail to come about. The GNU General Public License permits making a modified version and letting the public access it on a server without ever releasing its source code to the public. - -The GNU Affero General Public License is designed specifically to ensure that, in such cases, the modified source code becomes available to the community. It requires the operator of a network server to provide the source code of the modified version running there to the users of that server. Therefore, public use of a modified version, on a publicly accessible server, gives the public access to the source code of the modified version. - -An older license, called the Affero General Public License and published by Affero, was designed to accomplish similar goals. This is a different license, not a version of the Affero GPL, but Affero has released a new version of the Affero GPL which permits relicensing under this license. - -The precise terms and conditions for copying, distribution and modification follow. - - TERMS AND CONDITIONS - -0. Definitions. - -"This License" refers to version 3 of the GNU Affero General Public License. - -"Copyright" also means copyright-like laws that apply to other kinds of works, such as semiconductor masks. - -"The Program" refers to any copyrightable work licensed under this License. Each licensee is addressed as "you". "Licensees" and "recipients" may be individuals or organizations. - -To "modify" a work means to copy from or adapt all or part of the work in a fashion requiring copyright permission, other than the making of an exact copy. The resulting work is called a "modified version" of the earlier work or a work "based on" the earlier work. - -A "covered work" means either the unmodified Program or a work based on the Program. - -To "propagate" a work means to do anything with it that, without permission, would make you directly or secondarily liable for infringement under applicable copyright law, except executing it on a computer or modifying a private copy. Propagation includes copying, distribution (with or without modification), making available to the public, and in some countries other activities as well. - -To "convey" a work means any kind of propagation that enables other parties to make or receive copies. Mere interaction with a user through a computer network, with no transfer of a copy, is not conveying. - -An interactive user interface displays "Appropriate Legal Notices" to the extent that it includes a convenient and prominently visible feature that (1) displays an appropriate copyright notice, and (2) tells the user that there is no warranty for the work (except to the extent that warranties are provided), that licensees may convey the work under this License, and how to view a copy of this License. If the interface presents a list of user commands or options, such as a menu, a prominent item in the list meets this criterion. - -1. Source Code. -The "source code" for a work means the preferred form of the work for making modifications to it. "Object code" means any non-source form of a work. - -A "Standard Interface" means an interface that either is an official standard defined by a recognized standards body, or, in the case of interfaces specified for a particular programming language, one that is widely used among developers working in that language. - -The "System Libraries" of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A "Major Component", in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it. - -The "Corresponding Source" for a work in object code form means all the source code needed to generate, install, and (for an executable work) run the object code and to modify the work, including scripts to control those activities. However, it does not include the work's System Libraries, or general-purpose tools or generally available free programs which are used unmodified in performing those activities but which are not part of the work. For example, Corresponding Source includes interface definition files associated with source files for the work, and the source code for shared libraries and dynamically linked subprograms that the work is specifically designed to require, such as by intimate data communication or control flow between those -subprograms and other parts of the work. - -The Corresponding Source need not include anything that users can regenerate automatically from other parts of the Corresponding Source. - -The Corresponding Source for a work in source code form is that same work. - -2. Basic Permissions. -All rights granted under this License are granted for the term of copyright on the Program, and are irrevocable provided the stated conditions are met. This License explicitly affirms your unlimited permission to run the unmodified Program. The output from running a covered work is covered by this License only if the output, given its content, constitutes a covered work. This License acknowledges your rights of fair use or other equivalent, as provided by copyright law. - -You may make, run and propagate covered works that you do not convey, without conditions so long as your license otherwise remains in force. You may convey covered works to others for the sole purpose of having them make modifications exclusively for you, or provide you with facilities for running those works, provided that you comply with the terms of this License in conveying all material for which you do not control copyright. Those thus making or running the covered works for you must do so exclusively on your behalf, under your direction and control, on terms that prohibit them from making any copies of your copyrighted material outside their relationship with you. - -Conveying under any other circumstances is permitted solely under the conditions stated below. Sublicensing is not allowed; section 10 makes it unnecessary. - -3. Protecting Users' Legal Rights From Anti-Circumvention Law. -No covered work shall be deemed part of an effective technological measure under any applicable law fulfilling obligations under article 11 of the WIPO copyright treaty adopted on 20 December 1996, or similar laws prohibiting or restricting circumvention of such measures. - -When you convey a covered work, you waive any legal power to forbid circumvention of technological measures to the extent such circumvention is effected by exercising rights under this License with respect to the covered work, and you disclaim any intention to limit operation or modification of the work as a means of enforcing, against the work's users, your or third parties' legal rights to forbid circumvention of technological measures. - -4. Conveying Verbatim Copies. -You may convey verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice; keep intact all notices stating that this License and any non-permissive terms added in accord with section 7 apply to the code; keep intact all notices of the absence of any warranty; and give all recipients a copy of this License along with the Program. - -You may charge any price or no price for each copy that you convey, and you may offer support or warranty protection for a fee. - -5. Conveying Modified Source Versions. -You may convey a work based on the Program, or the modifications to produce it from the Program, in the form of source code under the terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is released under this License and any conditions added under section 7. This requirement modifies the requirement in section 4 to "keep intact all notices". - - c) You must license the entire work, as a whole, under this License to anyone who comes into possession of a copy. This License will therefore apply, along with any applicable section 7 additional terms, to the whole of the work, and all its parts, regardless of how they are packaged. This License gives no permission to license the work in any other way, but it does not invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display Appropriate Legal Notices; however, if the Program has interactive interfaces that do not display Appropriate Legal Notices, your work need not make them do so. - -A compilation of a covered work with other separate and independent works, which are not by their nature extensions of the covered work, and which are not combined with it such as to form a larger program, in or on a volume of a storage or distribution medium, is called an "aggregate" if the compilation and its resulting copyright are not used to limit the access or legal rights of the compilation's users beyond what the individual works permit. Inclusion of a covered work in an aggregate does not cause this License to apply to the other parts of the aggregate. - -6. Conveying Non-Source Forms. -You may convey a covered work in object code form under the terms of sections 4 and 5, provided that you also convey the machine-readable Corresponding Source under the terms of this License, in one of these ways: - - a) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by the Corresponding Source fixed on a durable physical medium customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product (including a physical distribution medium), accompanied by a written offer, valid for at least three years and valid for as long as you offer spare parts or customer support for that product model, to give anyone who possesses the object code either (1) a copy of the Corresponding Source for all the software in the product that is covered by this License, on a durable physical medium customarily used for software interchange, for a price no more than your reasonable cost of physically performing this conveying of source, or (2) access to copy the Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the written offer to provide the Corresponding Source. This alternative is allowed only occasionally and noncommercially, and only if you received the object code with such an offer, in accord with subsection 6b. - - d) Convey the object code by offering access from a designated place (gratis or for a charge), and offer equivalent access to the Corresponding Source in the same way through the same place at no further charge. You need not require recipients to copy the Corresponding Source along with the object code. If the place to copy the object code is a network server, the Corresponding Source may be on a different server (operated by you or a third party) that supports equivalent copying facilities, provided you maintain clear directions next to the object code saying where to find the Corresponding Source. Regardless of what server hosts the Corresponding Source, you remain obligated to ensure that it is available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided you inform other peers where the object code and Corresponding Source of the work are being offered to the general public at no charge under subsection 6d. - -A separable portion of the object code, whose source code is excluded from the Corresponding Source as a System Library, need not be included in conveying the object code work. - -A "User Product" is either (1) a "consumer product", which means any tangible personal property which is normally used for personal, family, or household purposes, or (2) anything designed or sold for incorporation into a dwelling. In determining whether a product is a consumer product, doubtful cases shall be resolved in favor of coverage. For a particular product received by a particular user, "normally used" refers to a typical or common use of that class of product, regardless of the status of the particular user or of the way in which the particular user actually uses, or expects or is expected to use, the product. A product is a consumer product regardless of whether the product has substantial commercial, industrial or non-consumer uses, unless such uses represent the only significant mode of use of the product. - -"Installation Information" for a User Product means any methods, procedures, authorization keys, or other information required to install and execute modified versions of a covered work in that User Product from a modified version of its Corresponding Source. The information must suffice to ensure that the continued functioning of the modified object code is in no case prevented or interfered with solely because modification has been made. - -If you convey an object code work under this section in, or with, or specifically for use in, a User Product, and the conveying occurs as part of a transaction in which the right of possession and use of the User Product is transferred to the recipient in perpetuity or for a fixed term (regardless of how the transaction is characterized), the Corresponding Source conveyed under this section must be accompanied by the Installation Information. But this requirement does not apply if neither you nor any third party retains the ability to install modified object code on the User Product (for example, the work has been installed in ROM). - -The requirement to provide Installation Information does not include a requirement to continue to provide support service, warranty, or updates for a work that has been modified or installed by the recipient, or for the User Product in which it has been modified or installed. Access to a network may be denied when the modification itself materially and adversely affects the operation of the network or violates the rules and protocols for communication across the network. - -Corresponding Source conveyed, and Installation Information provided, in accord with this section must be in a format that is publicly documented (and with an implementation available to the public in source code form), and must require no special password or key for unpacking, reading or copying. - -7. Additional Terms. -"Additional permissions" are terms that supplement the terms of this License by making exceptions from one or more of its conditions. Additional permissions that are applicable to the entire Program shall be treated as though they were included in this License, to the extent that they are valid under applicable law. If additional permissions apply only to part of the Program, that part may be used separately under those permissions, but the entire Program remains governed by this License without regard to the additional permissions. - -When you convey a copy of a covered work, you may at your option remove any additional permissions from that copy, or from any part of it. (Additional permissions may be written to require their own removal in certain cases when you modify the work.) You may place additional permissions on material, added by you to a covered work, for which you have or can give appropriate copyright permission. - -Notwithstanding any other provision of this License, for material you add to a covered work, you may (if authorized by the copyright holders of that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or author attributions in that material or in the Appropriate Legal Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or requiring that modified versions of such material be marked in reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or authors of the material; or - - e) Declining to grant rights under trademark law for use of some trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that material by anyone who conveys the material (or modified versions of it) with contractual assumptions of liability to the recipient, for any liability that these contractual assumptions directly impose on those licensors and authors. - -All other non-permissive additional terms are considered "further restrictions" within the meaning of section 10. If the Program as you received it, or any part of it, contains a notice stating that it is governed by this License along with a term that is a further restriction, you may remove that term. If a license document contains a further restriction but permits relicensing or conveying under this License, you may add to a covered work material governed by the terms of that license document, provided that the further restriction does not survive such relicensing or conveying. - -If you add terms to a covered work in accord with this section, you must place, in the relevant source files, a statement of the additional terms that apply to those files, or a notice indicating where to find the applicable terms. - -Additional terms, permissive or non-permissive, may be stated in the form of a separately written license, or stated as exceptions; the above requirements apply either way. - -8. Termination. - -You may not propagate or modify a covered work except as expressly provided under this License. Any attempt otherwise to propagate or modify it is void, and will automatically terminate your rights under this License (including any patent licenses granted under the third paragraph of section 11). - -However, if you cease all violation of this License, then your license from a particular copyright holder is reinstated (a) provisionally, unless and until the copyright holder explicitly and finally terminates your license, and (b) permanently, if the copyright holder fails to notify you of the violation by some reasonable means prior to 60 days after the cessation. - -Moreover, your license from a particular copyright holder is reinstated permanently if the copyright holder notifies you of the violation by some reasonable means, this is the first time you have received notice of violation of this License (for any work) from that copyright holder, and you cure the violation prior to 30 days after your receipt of the notice. - -Termination of your rights under this section does not terminate the licenses of parties who have received copies or rights from you under this License. If your rights have been terminated and not permanently reinstated, you do not qualify to receive new licenses for the same material under section 10. - -9. Acceptance Not Required for Having Copies. - -You are not required to accept this License in order to receive or run a copy of the Program. Ancillary propagation of a covered work occurring solely as a consequence of using peer-to-peer transmission to receive a copy likewise does not require acceptance. However, nothing other than this License grants you permission to propagate or modify any covered work. These actions infringe copyright if you do not accept this License. Therefore, by modifying or propagating a covered work, you indicate your acceptance of this License to do so. - -10. Automatic Licensing of Downstream Recipients. - -Each time you convey a covered work, the recipient automatically receives a license from the original licensors, to run, modify and propagate that work, subject to this License. You are not responsible for enforcing compliance by third parties with this License. - -An "entity transaction" is a transaction transferring control of an organization, or substantially all assets of one, or subdividing an organization, or merging organizations. If propagation of a covered work results from an entity transaction, each party to that transaction who receives a copy of the work also receives whatever licenses to the work the party's predecessor in interest had or could give under the previous paragraph, plus a right to possession of the Corresponding Source of the work from the predecessor in interest, if the predecessor has it or can get it with reasonable efforts. - -You may not impose any further restrictions on the exercise of the rights granted or affirmed under this License. For example, you may not impose a license fee, royalty, or other charge for exercise of rights granted under this License, and you may not initiate litigation (including a cross-claim or counterclaim in a lawsuit) alleging that any patent claim is infringed by making, using, selling, offering for sale, or importing the Program or any portion of it. - -11. Patents. - -A "contributor" is a copyright holder who authorizes use under this License of the Program or a work on which the Program is based. The work thus licensed is called the contributor's "contributor version". - -A contributor's "essential patent claims" are all patent claims owned or controlled by the contributor, whether already acquired or hereafter acquired, that would be infringed by some manner, permitted by this License, of making, using, or selling its contributor version, but do not include claims that would be infringed only as a consequence of further modification of the contributor version. For purposes of this definition, "control" includes the right to grant patent sublicenses in a manner consistent with the requirements of this License. - -Each contributor grants you a non-exclusive, worldwide, royalty-free patent license under the contributor's essential patent claims, to make, use, sell, offer for sale, import and otherwise run, modify and propagate the contents of its contributor version. - -In the following three paragraphs, a "patent license" is any express agreement or commitment, however denominated, not to enforce a patent (such as an express permission to practice a patent or covenant not to sue for patent infringement). To "grant" such a patent license to a party means to make such an agreement or commitment not to enforce a patent against the party. - -If you convey a covered work, knowingly relying on a patent license, and the Corresponding Source of the work is not available for anyone to copy, free of charge and under the terms of this License, through a publicly available network server or other readily accessible means, then you must either (1) cause the Corresponding Source to be so available, or (2) arrange to deprive yourself of the benefit of the patent license for this particular work, or (3) arrange, in a manner consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have actual knowledge that, but for the patent license, your conveying the covered work in a country, or your recipient's use of the covered work in a country, would infringe one or more identifiable patents in that country that you have reason to believe are valid. - -If, pursuant to or in connection with a single transaction or arrangement, you convey, or propagate by procuring conveyance of, a covered work, and grant a patent license to some of the parties receiving the covered work authorizing them to use, propagate, modify or convey a specific copy of the covered work, then the patent license you grant is automatically extended to all recipients of the covered work and works based on it. - -A patent license is "discriminatory" if it does not include within the scope of its coverage, prohibits the exercise of, or is conditioned on the non-exercise of one or more of the rights that are specifically granted under this License. You may not convey a covered work if you are a party to an arrangement with a third party that is in the business of distributing software, under which you make payment to the third party based on the extent of your activity of conveying the work, and under which the third party grants, to any of the parties who would receive the covered work from you, a discriminatory patent license (a) in connection with copies of the covered work conveyed by you (or copies made from those copies), or (b) primarily for and in connection with specific products or compilations that contain the covered work, unless you entered into that arrangement, or that patent license was granted, prior to 28 March 2007. - -Nothing in this License shall be construed as excluding or limiting any implied license or other defenses to infringement that may otherwise be available to you under applicable patent law. - -12. No Surrender of Others' Freedom. - -If conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot convey a covered work so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you to collect a royalty for further conveying from those to whom you convey the Program, the only way you could satisfy both those terms and this License would be to refrain entirely from conveying the Program. - -13. Remote Network Interaction; Use with the GNU General Public License. - -Notwithstanding any other provision of this License, if you modify the Program, your modified version must prominently offer all users interacting with it remotely through a computer network (if your version supports such interaction) an opportunity to receive the Corresponding Source of your version by providing access to the Corresponding Source from a network server at no charge, through some standard or customary means of facilitating copying of software. This Corresponding Source shall include the Corresponding Source for any work covered by version 3 of the GNU General Public License that is incorporated pursuant to the following paragraph. - -Notwithstanding any other provision of this License, you have permission to link or combine any covered work with a work licensed under version 3 of the GNU General Public License into a single combined work, and to convey the resulting work. The terms of this License will continue to apply to the part which is the covered work, but the work with which it is combined will remain governed by version 3 of the GNU General Public License. - -14. Revised Versions of this License. - -The Free Software Foundation may publish revised and/or new versions of the GNU Affero General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. - -Each version is given a distinguishing version number. If the Program specifies that a certain numbered version of the GNU Affero General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that numbered version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of the GNU Affero General Public License, you may choose any version ever published by the Free Software Foundation. - -If the Program specifies that a proxy can decide which future versions of the GNU Affero General Public License can be used, that proxy's public statement of acceptance of a version permanently authorizes you to choose that version for the Program. - -Later license versions may give you additional or different permissions. However, no additional obligations are imposed on any author or copyright holder as a result of your choosing to follow a later version. - -15. Disclaimer of Warranty. - -THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - -16. Limitation of Liability. - -IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. - -17. Interpretation of Sections 15 and 16. - -If the disclaimer of warranty and limitation of liability provided above cannot be given local legal effect according to their terms, reviewing courts shall apply local law that most closely approximates an absolute waiver of all civil liability in connection with the Program, unless a warranty or assumption of liability accompanies a copy of the Program in return for a fee. - -END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively state the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. - - test - Copyright (C) 2023 linos - - This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. - - This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. - - You should have received a copy of the GNU Affero General Public License along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - -If your software can interact with users remotely through a computer network, you should also make sure that it provides a way for users to get its source. For example, if your program is a web application, its interface could display a "Source" link that leads users to an archive of the code. There are many ways you could offer source, and different solutions will be better for different programs; see section 13 for the specific requirements. - -You should also get your employer (if you work as a programmer) or school, if any, to sign a "copyright disclaimer" for the program, if necessary. For more information on this, and how to apply and follow the GNU AGPL, see . diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/css/event-bridge-for-activitypub-admin.css b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/css/event-bridge-for-activitypub-admin.css deleted file mode 100644 index da750dba..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/css/event-bridge-for-activitypub-admin.css +++ /dev/null @@ -1,236 +0,0 @@ -.settings_page_event-bridge-for-activitypub #wpcontent { - padding-left: 0; -} - -.event-bridge-for-activitypub-settings-page .box { - border: 1px solid #c3c4c7; - background-color: #fff; - padding: 1em 1.5em; - margin-bottom: 1.5em; -} - -.event-bridge-for-activitypub-settings-page .logo-center { - width: 25%; - margin: 10px 5% 10px 5%; -} - -.event-bridge-for-activitypub-settings-page .box ul.event-bridge-for-activitypub-list { - margin-left: 0.6em; -} - -.event-bridge-for-activitypub-settings-page .box pre { - padding: 1rem; - min-height: 200px; - box-shadow: none; - border-radius: 15px; - border: 1px solid #dfe0e2; - background-color: #f7f7f7; -} - -.event-bridge-for-activitypub-settings td { - padding-top: 20px; - padding-bottom: 20px; -} - -.event-bridge-for-activitypub-settings-header { - text-align: center; - margin: 0 0 1rem; -} - -.event-bridge-for-activitypub-settings-title-section { - display: flex; - align-items: center; - justify-content: center; - clear: both; - padding-top: 8px; -} - -.event-bridge-for-activitypub-settings-tabs-wrapper { - display: -ms-inline-grid; - -ms-grid-columns: auto auto auto auto; - vertical-align: top; - display: inline-grid; - grid-template-columns: auto auto auto auto; -} - -.event-bridge-for-activitypub-settings-tab.active { - box-shadow: inset 0 -3px #3582c4; - font-weight: 600; -} - -.event-bridge-for-activitypub-settings-tab { - display: block; - text-decoration: none; - color: inherit; - padding: .5rem 1rem 1rem; - margin: 0 1rem; - transition: box-shadow .5s ease-in-out; -} - -.event-bridge-for-activitypub-settings .box h3 { - font-size: 1.15em; - margin-bottom: 0em; -} - -#event_bridge_for_activitypub_initially_activated { - display: hidden; -} - -/* Accordions for admin pages */ -.event-bridge-for-activitypub-settings-accordion { - border: 1px solid #c3c4c7; -} - -.event-bridge-for-activitypub-settings-accordion-heading { - margin: 0; - border-top: 1px solid #c3c4c7; - font-size: inherit; - line-height: inherit; - font-weight: 600; - color: inherit; -} - -.event-bridge-for-activitypub-settings-accordion-heading:first-child { - border-top: none; -} - -.event-bridge-for-activitypub-settings-accordion-panel { - margin: 0; - padding: 1em 1.5em; - background: #fff; -} - -.event-bridge-for-activitypub-settings-accordion-trigger { - background: #fff; - border: 0; - color: #2c3338; - cursor: pointer; - display: flex; - font-weight: 400; - margin: 0; - padding: 1em 3.5em 1em 1.5em; - min-height: 46px; - position: relative; - text-align: left; - width: 100%; - align-items: center; - justify-content: space-between; - -webkit-user-select: auto; - user-select: auto; -} - -.event-bridge-for-activitypub-settings-accordion-trigger { - color: #2c3338; - cursor: pointer; - font-weight: 400; - text-align: left; -} - -.event-bridge-for-activitypub-settings-accordion-trigger .title { - pointer-events: none; - font-weight: 600; - flex-grow: 1; -} - -.event-bridge-for-activitypub-settings-accordion-trigger .icon, -.event-bridge-for-activitypub-settings-accordion-viewed .icon { - border: solid #50575e medium; - border-width: 0 2px 2px 0; - height: .5rem; - pointer-events: none; - position: absolute; - right: 1.5em; - top: 50%; - transform: translateY(-70%) rotate(45deg); - width: .5rem; -} - -.event-bridge-for-activitypub-settings-accordion-trigger[aria-expanded="true"] .icon { - transform: translateY(-30%) rotate(-135deg); -} - -.event-bridge-for-activitypub-settings-accordion-trigger:active, -.event-bridge-for-activitypub-settings-accordion-trigger:hover { - background: #f6f7f7; -} - -.event-bridge-for-activitypub-settings-accordion-trigger:focus { - color: #1d2327; - border: none; - box-shadow: none; - outline-offset: -1px; - outline: 2px solid #2271b1; - background-color: #f6f7f7; -} - -.event-bridge-for-activitypub-settings-inline-icon { - width: 1.5em; - height: 1.5em; - vertical-align: middle; - margin: 0 0.3em; -} - -code.event-bridge-for-activitypub-settings-example-url { - display: block; - background: rgb(28, 29, 33); - padding: 8px; - margin: 10px 0px 10px 0; - border-radius: 7px; - color: #d5d5d6; - overflow-x: auto; - word-break: break-all; -} - -#event_bridge_for_activitypub_summary_type_custom-details { - display: none; -} - -#event_bridge_for_activitypub_summary_type_custom-details > details { - padding: 0.5em; -} - -.event_bridge_for_activitypub-list { - list-style: disc; - padding-left: 22px; -} - -.event_bridge_for_activitypub-admin-table-container { - padding-left: 22px; -} - -.event_bridge_for_activitypub-admin-table-top > h2 { - display: inline-block; - font-size: 23px; - font-weight: 400; - margin: 0 10px 0 2px; - padding: 9px 0 4px; - line-height: 1.3; -} - -.event_bridge_for_activitypub-admin-table-top > a { - display: inline-block; -} - -.settings_page_event-bridge-for-activitypub .notice-warning { - background: #fff; - border: 1px solid #c3c4c7; - border-left-width: 4px; - box-shadow: 0 1px 1px rgba(0,0,0,.04); - margin: 5px 15px 2px; - padding: 1px 12px; - border-left-color: #dba617; -} - -.event-bridge-for-activitypub-settings .select-cell::before { - content: "\21D2"; - margin-right: 8px; - color: inherit; -} - -ul.event-bridge-for-activitypub-syntax-list { - list-style: disc; -} - -ul.event-bridge-for-activitypub-syntax-list > li { - margin: 6px 6px 6px 20px; -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/acknowledgement-NGI0Entrust.svg b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/acknowledgement-NGI0Entrust.svg deleted file mode 100644 index 0d211b38..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/acknowledgement-NGI0Entrust.svg +++ /dev/null @@ -1,121 +0,0 @@ - - - -image/svg+xml - - - - - - -NGI Zero Entrust - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/acknowledgement-NLnet.svg b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/acknowledgement-NLnet.svg deleted file mode 100644 index 7980346a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/acknowledgement-NLnet.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/activitypub.svg b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/activitypub.svg deleted file mode 100644 index f56d428f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/activitypub.svg +++ /dev/null @@ -1,288 +0,0 @@ - - - - - ActivityPub logo - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - image/svg+xml - - ActivityPub logo - - 2017-04-15 - - - Robert Martinez - - - - - ActivityPub - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/fediverse.svg b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/fediverse.svg deleted file mode 100644 index a789df22..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/fediverse.svg +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/gancio.png b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/gancio.png deleted file mode 100644 index d53e1632..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/gancio.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/mastodon.svg b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/mastodon.svg deleted file mode 100644 index 0f8baebf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/mastodon.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/mobilizon.svg b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/mobilizon.svg deleted file mode 100644 index 8b5d57e5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/img/mobilizon.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/js/event-bridge-for-activitypub-admin.js b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/js/event-bridge-for-activitypub-admin.js deleted file mode 100644 index 3715707b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/assets/js/event-bridge-for-activitypub-admin.js +++ /dev/null @@ -1,34 +0,0 @@ -jQuery( function( $ ) { - // Accordion handling in various areas. - $( '.event-bridge-for-activitypub-settings-accordion' ).on( 'click', '.event-bridge-for-activitypub-settings-accordion-trigger', function() { - var isExpanded = ( 'true' === $( this ).attr( 'aria-expanded' ) ); - - if ( isExpanded ) { - $( this ).attr( 'aria-expanded', 'false' ); - $( '#' + $( this ).attr( 'aria-controls' ) ).attr( 'hidden', true ); - } else { - $( this ).attr( 'aria-expanded', 'true' ); - $( '#' + $( this ).attr( 'aria-controls' ) ).attr( 'hidden', false ); - } - } ); - - // Function to toggle visibility of custom details based on selected radio button. - function toggleCustomDetailsForSummary() { - if ($("#event_bridge_for_activitypub_summary_type_custom").is(':checked')) { - $("#event_bridge_for_activitypub_summary_type_custom-details").show(); - } else { - $("#event_bridge_for_activitypub_summary_type_custom-details").hide(); - } - } - - // Run the toggle function on page load. - $(document).ready(function() { - toggleCustomDetailsForSummary(); // Set the correct state on load. - - // Listen for changes on the radio buttons - $("input[name=event_bridge_for_activitypub_summary_type]").change(function() { - toggleCustomDetailsForSummary(); // Update visibility on change. - }); - }); - -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/block.json b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/block.json deleted file mode 100644 index ad2fc046..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/block.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "name": "reminder", - "title": "Reminder Plugin: not a block, but block.json is very useful.", - "category": "widgets", - "icon": "admin-comments", - "keywords": [], - "editorScript": "file:./plugin.js" -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/plugin.asset.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/plugin.asset.php deleted file mode 100644 index 169666b7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/plugin.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react-jsx-runtime', 'wp-components', 'wp-core-data', 'wp-data', 'wp-editor', 'wp-i18n', 'wp-plugins'), 'version' => 'd491284dfb7e5078a777'); diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/plugin.js b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/plugin.js deleted file mode 100644 index cd5cfa27..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/build/reminder/plugin.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";const e=window.wp.editor,t=window.wp.plugins,i=window.wp.components,n=window.wp.data,a=window.wp.coreData,r=window.wp.i18n,d=window.ReactJSXRuntime,p=activityPubEventBridge.reminderTypeGap;(0,t.registerPlugin)("event-bridge-for-activitypub-reminder",{render:()=>{const t=(0,n.useSelect)((e=>e("core/editor").getCurrentPostType()),[]),[_,b]=(0,a.useEntityProp)("postType",t,"meta"),u=_?.event_bridge_for_activitypub_reminder_time_gap?_?.event_bridge_for_activitypub_reminder_time_gap:p;return(0,d.jsx)(e.PluginDocumentSettingPanel,{name:"activitypub",title:(0,r.__)("Send reminder before event's start","activitypub"),children:(0,d.jsx)(i.SelectControl,{label:(0,r.__)("Time gap","activitypub"),value:u,options:[{label:(0,r.__)("Disabled","event-bridge-for-activitypub"),value:0},{label:(0,r.__)("6 hours","event-bridge-for-activitypub"),value:21600},{label:(0,r.__)("1 day","event-bridge-for-activitypub"),value:86400},{label:(0,r.__)("3 days","event-bridge-for-activitypub"),value:259200},{label:(0,r.__)("1 week","event-bridge-for-activitypub"),value:604800}],onChange:e=>{b({..._,event_bridge_for_activitypub_reminder_time_gap:e})},__nextHasNoMarginBottom:!0})})}})})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/event-bridge-for-activitypub.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/event-bridge-for-activitypub.php deleted file mode 100644 index 179cbd7e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/event-bridge-for-activitypub.php +++ /dev/null @@ -1,39 +0,0 @@ -NGI0 Entrust Fund, a fund established by NLnet. - * Plugin URI: https://event-federation.eu/ - * Version: 1.1.0 - * Author: André Menrath - * Author URI: https://graz.social/@linos - * Text Domain: event-bridge-for-activitypub - * License: AGPL-3.0-or-later - * License URI: https://www.gnu.org/licenses/agpl-3.0.html - * Requires PHP: 7.4 - * Requires Plugins: activitypub - * - * Requires at least ActivityPub plugin with version >= 5.6.1. ActivityPub plugin tested up to: 5.7.0. - * - * @package Event_Bridge_For_ActivityPub - * @license AGPL-3.0-or-later - */ - -// Exit if accessed directly. -defined( 'ABSPATH' ) || exit; // @codeCoverageIgnore - -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR', plugin_dir_path( __FILE__ ) ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_BASENAME', plugin_basename( __FILE__ ) ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE', plugin_dir_path( __FILE__ ) . '/' . basename( __FILE__ ) ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_URL', plugin_dir_url( __FILE__ ) ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_VERSION', current( get_file_data( __FILE__, array( 'Version' ), 'plugin' ) ) ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_DOMAIN', 'event-bridge-for-activitypub' ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_ACTIVITYPUB_PLUGIN_MIN_VERSION', '5.6.1' ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_SUMMARY_TEMPLATE', "[ap_start_time]\n[ap_end_time]\n[ap_location]\n\n[ap_content]" ); -define( 'EVENT_BRIDGE_FOR_ACTIVITYPUB_DEFAULT_SUMMARY_TYPE', 'preset' ); - -// Include and register the autoloader class for automatic loading of plugin classes. -require_once EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . '/includes/class-autoloader.php'; -Event_Bridge_For_ActivityPub\Autoloader::register(); - -// Initialize the plugin. -Event_Bridge_For_ActivityPub\Setup::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/class-handler.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/class-handler.php deleted file mode 100644 index 3081c01d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/class-handler.php +++ /dev/null @@ -1,35 +0,0 @@ - array( - 'name' => _x( 'Event Sources', 'post_type plural name', 'event-bridge-for-activitypub' ), - 'singular_name' => _x( 'Event Source', 'post_type single name', 'event-bridge-for-activitypub' ), - ), - 'public' => false, - 'hierarchical' => false, - 'rewrite' => false, - 'query_var' => false, - 'delete_with_user' => false, - 'can_export' => true, - 'supports' => array(), - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_activitypub_actor_id', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => 'sanitize_url', - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_activitypub_errors', - array( - 'type' => 'string', - 'single' => false, - 'sanitize_callback' => function ( $value ) { - if ( ! is_string( $value ) ) { - throw new \Exception( 'Error message is no valid string' ); - } - - return esc_sql( $value ); - }, - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_activitypub_actor_json', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => function ( $value ) { - return sanitize_text_field( $value ); - }, - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_activitypub_inbox', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => 'sanitize_url', - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_event_bridge_for_activitypub_utilize_announces', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => function ( $value ) { - if ( 'same_origin' === $value ) { - return 'same_origin'; - } - return ''; - }, - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_event_bridge_for_activitypub_accept_of_follow', - array( - 'type' => 'string', - 'single' => true, - 'sanitize_callback' => 'sanitize_url', - ) - ); - - \register_post_meta( - self::POST_TYPE, - '_event_bridge_for_activitypub_event_count', - array( - 'type' => 'integer', - 'single' => true, - 'sanitize_callback' => 'absint', - 'default' => '0', - ) - ); - } - - /** - * Add new Event Source. - * - * @param string $actor The Actor URL/ID. - * - * @return Event_Source|WP_Error|null The Followed (WP_Post array) or an WP_Error. - */ - public static function add_event_source( $actor ) { - $meta = get_remote_metadata_by_actor( $actor ); - - if ( is_tombstone( $meta ) ) { - return $meta; - } - - if ( \is_wp_error( $meta ) ) { - return $meta; - } - - if ( empty( $meta ) ) { - return null; - } - - $event_source = new Event_Source(); - $event_source->from_array( $meta ); - - $post_id = $event_source->save(); - - if ( \is_wp_error( $post_id ) ) { - return $post_id; - } - - self::delete_event_source_transients(); - - self::queue_follow_actor( $actor ); - - return $event_source; - } - - /** - * Compose the ActivityPub ID of a follow request. - * - * @param string $follower_id The ActivityPub ID of the actor that followers the other one. - * @param string $followed_id The ActivityPub ID of the followed actor. - * @return string The `Follow` ID. - */ - public static function compose_follow_id( $follower_id, $followed_id ) { - return $follower_id . '#follow-' . \preg_replace( '~^https?://~', '', $followed_id ); - } - - /** - * Delete all transients related to the event sources. - * - * @return void - */ - public static function delete_event_source_transients(): void { - \delete_transient( 'event_bridge_for_activitypub_event_sources' ); - \delete_transient( 'event_bridge_for_activitypub_event_sources_hosts' ); - } - - /** - * Check whether an attachment is set as a featured image of any post. - * - * @param string|int $attachment_id The numeric post ID of the attachment. - * @return bool - */ - public static function is_attachment_featured_image( $attachment_id ): bool { - if ( ! is_numeric( $attachment_id ) ) { - return false; - } - - // Query posts with the given attachment ID as their featured image. - $args = array( - 'post_type' => 'any', - 'meta_query' => array( - array( - 'key' => '_thumbnail_id', - 'value' => $attachment_id, - 'compare' => '=', - ), - ), - 'fields' => 'ids', // Only retrieve post IDs for performance. - 'numberposts' => 1, // We only need one match to confirm. - ); - - $posts = \get_posts( $args ); - - return ! empty( $posts ); - } - - /** - * Delete all posts of an event source. - * - * @param int $event_source_post_id The WordPress Post ID of the event source. - * @return void - */ - public static function delete_events_by_event_source( $event_source_post_id ): void { - global $wpdb; - $results = $wpdb->get_results( - $wpdb->prepare( - "SELECT post_id FROM $wpdb->postmeta WHERE meta_key = %s AND meta_value = %s", - '_event_bridge_for_activitypub_event_source', - absint( $event_source_post_id ) - ) - ); - - // If no matching posts are found, return early. - if ( empty( $results ) ) { - return; - } - - // Loop through the posts and delete them permanently. - foreach ( $results as $result ) { - // Check if the post has a thumbnail. - $thumbnail_id = \get_post_thumbnail_id( $result->post_id ); - - if ( $thumbnail_id ) { - // Remove the thumbnail from the post. - \delete_post_thumbnail( $result->post_id ); - - // Delete the attachment (and its files) from the media library. - if ( self::is_attachment_featured_image( $thumbnail_id ) ) { - \wp_delete_attachment( $thumbnail_id, true ); - } - } - - \wp_delete_post( $result->post_id, true ); - } - - // Clean up the query. - \wp_reset_postdata(); - } - - /** - * Remove an Event Source (=Followed ActivityPub actor). - * - * @param int|string $event_source_post_id The Events Sources Post ID or ActivityPub ID. - * - * @return void Post data on success, false or null on failure. - */ - public static function remove_event_source( $event_source_post_id ): void { - $event_source = Event_Source::get_by_id( $event_source_post_id ); - - if ( ! $event_source ) { - return; - } - - self::delete_events_by_event_source( $event_source->get__id() ); - - self::delete_event_source_transients(); - - // Temporary hack. - $post = \get_post( $event_source->get__id() ); - $post->post_status = 'draft'; - - if ( $post instanceof \WP_Post ) { - $post = \get_object_vars( $post ); - $post = \wp_slash( $post ); - $post = \wp_update_post( $post ); - } - - self::queue_unfollow_actor( $event_source->get_id() ); - } - - /** - * Get all Event-Sources. - * - * It returns associative arrays, where the keys are the WordPress post IDs and the values are the ActivityPub IDs. - * For example: - * array( - * 15 => 'https://remote.example/actors/event_organizer1', - * 19 => 'https://remote2.example/users/johnmastodon', - * ) - * - * @return array List of `Event Sources`: => - */ - public static function get_event_sources(): array { - $event_sources = get_transient( 'event_bridge_for_activitypub_event_sources' ); - - if ( $event_sources && is_array( $event_sources ) ) { - return $event_sources; - } - - $event_sources = self::get_event_sources_with_count()['actors']; - - set_transient( 'event_bridge_for_activitypub_event_sources', $event_sources ); - - return $event_sources; - } - - /** - * Get the Event Sources along with a total count for pagination purposes. - * - * @param int $number Maximum number of results to return. - * @param int $page Page number. - * @param array $args The WP_Query arguments. - * - * @return array { - * Data about the event sources. - * - * @type array $actors List of `Event Sources`: => - * @type int $total Total number of followers. - * } - */ - public static function get_event_sources_with_count( $number = -1, $page = null, $args = array() ): array { - $defaults = array( - 'post_type' => self::POST_TYPE, - 'posts_per_page' => $number, - 'paged' => $page, - 'orderby' => 'ID', - 'order' => 'DESC', - 'post_status' => array( 'publish', 'pending', 'draft', 'auto-draft', 'future', 'private', 'inherit' ), - ); - - $args = wp_parse_args( $args, $defaults ); - $query = new WP_Query( $args ); - $total = $query->found_posts; - $actors = array(); - - foreach ( $query->get_posts() as $post ) { - $actors[ $post->ID ] = get_post_meta( $post->ID, '_activitypub_actor_id', true ); - } - - $event_sources = compact( 'actors', 'total' ); - - return $event_sources; - } - - /** - * Queue a hook to run async. - * - * @param string $hook The hook name. - * @param array $args The arguments to pass to the hook. - * @param string $unqueue_hook Optional a hook to unschedule before queuing. - * @return void|bool|WP_Error Whether the hook was queued. - */ - public static function queue( $hook, $args, $unqueue_hook = null ) { - if ( $unqueue_hook ) { - $hook_timestamp = \wp_next_scheduled( $unqueue_hook, $args ); - if ( $hook_timestamp ) { - \wp_unschedule_event( $hook_timestamp, $unqueue_hook, $args ); - } - } - - if ( \wp_next_scheduled( $hook, $args ) ) { - return; - } - - return \wp_schedule_single_event( \time(), $hook, $args ); - } - - /** - * Prepare to follow an ActivityPub actor via a scheduled event. - * - * @param string $actor The ActivityPub actor. - * - * @return bool Whether the event was queued. - */ - public static function queue_follow_actor( $actor ): bool { - $queued = self::queue( - 'event_bridge_for_activitypub_follow', - array( $actor ), - 'event_bridge_for_activitypub_unfollow' - ); - - if ( \is_wp_error( $queued ) ) { - return false; - } - - // Following this actor has already been queued. - if ( null === $queued ) { - return true; - } - - return $queued; - } - - /** - * Follow an ActivityPub actor via the Blog user. - * - * @param string $actor_id The ID/URL of the Actor. - */ - public static function activitypub_follow_actor( $actor_id ) { - $actor = Event_Source::get_by_id( $actor_id ); - - if ( ! $actor ) { - return $actor; - } - - $inbox = $actor->get_shared_inbox(); - $to = $actor->get_id(); - - $from_actor = new Blog(); - - $activity = new \Activitypub\Activity\Activity(); - $activity->set_type( 'Follow' ); - $activity->set_to( null ); - $activity->set_cc( null ); - $activity->set_actor( $from_actor->get_id() ); - $activity->set_object( $to ); - $activity->set_id( self::compose_follow_id( $from_actor->get_id(), $to ) ); - $activity = $activity->to_json(); - \Activitypub\safe_remote_post( $inbox, $activity, \Activitypub\Collection\Actors::BLOG_USER_ID ); - } - - /** - * Prepare to unfollow an actor via a scheduled event. - * - * @param string $actor The ActivityPub actor ID. - * - * @return bool|void|WP_Error Whether the event was queued. - */ - public static function queue_unfollow_actor( $actor ) { - $queued = self::queue( - 'event_bridge_for_activitypub_unfollow', - array( $actor ), - 'event_bridge_for_activitypub_follow' - ); - - if ( \is_wp_error( $queued ) ) { - return false; - } - - // Following this actor has already been queued. - if ( null === $queued ) { - return true; - } - - return $queued; - } - - /** - * Unfollow an ActivityPub actor. - * - * @param string $actor The ActivityPub ID of the actor to unfollow. - * @return void - */ - public static function activitypub_unfollow_actor( $actor ): void { - $actor = Event_Source::get_by_id( $actor ); - - if ( ! $actor ) { - return; - } - - $inbox = $actor->get_shared_inbox(); - $to = $actor->get_id(); - - $from_actor = new Blog(); - - if ( ! $inbox ) { - return; - } - - $activity = new \Activitypub\Activity\Activity(); - $activity->set_type( 'Undo' ); - $activity->set_to( null ); - $activity->set_cc( null ); - $activity->set_actor( $from_actor->get_id() ); - $activity->set_object( - array( - 'type' => 'Follow', - 'actor' => $actor, - 'object' => $to, - 'id' => self::compose_follow_id( $from_actor->get_id(), $to ), - ) - ); - $activity->set_id( $from_actor->get_id() . '#unfollow-' . \preg_replace( '~^https?://~', '', $to ) ); - $activity = $activity->to_json(); - \Activitypub\safe_remote_post( $inbox, $activity, \Activitypub\Collection\Actors::BLOG_USER_ID ); - - $actor->delete(); - - self::delete_event_source_transients(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-accept.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-accept.php deleted file mode 100644 index ab7b63f1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-accept.php +++ /dev/null @@ -1,76 +0,0 @@ -get_id(), $activity['actor'] ); - - // Check if the object of the `Accept` is indeed the `Follow` request we sent to that actor. - if ( object_to_uri( $activity['object'] ) !== $follow_id ) { - return; - } - - // Save the accept status of the follow request to the event source post. - \update_post_meta( $event_source_post_id, '_event_bridge_for_activitypub_accept_of_follow', $activity['id'] ); - \wp_update_post( - array( - 'ID' => $event_source_post_id, - 'post_status' => 'publish', - ) - ); - - // Trigger the backfilling of events from this actor. - \do_action( 'event_bridge_for_activitypub_backfill_events', $event_source_post_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-create.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-create.php deleted file mode 100644 index 74ff5438..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-create.php +++ /dev/null @@ -1,76 +0,0 @@ -get_actor_object()->get_id(), // Gets the WordPress user that "owns" the object by ActivityPub means. - $activity['id'], - Actor::init_from_array( $actor ) - ); - } - - /** - * Send "Ignore" response. - * - * @param string $actor The actors ActivityPub ID which sends the response. - * @param string $ignored The ID of the Activity that gets ignored. - * @param Actor|mixed $to The target actor. - */ - public static function send_ignore_response( $actor, $ignored, $to ) { - // Get actor object that owns the object that was targeted by the ignored activity. - $actor = Actors::get_by_resource( $actor ); - - if ( \is_wp_error( $to ) || \is_wp_error( $actor ) ) { - return; - } - - // Get inbox. - $inbox = $to->get_inbox(); - - if ( ! $inbox ) { - return; - } - - // Send "Ignore" activity. - $activity = new Activity(); - $activity->set_type( 'Ignore' ); - $activity->set_object( \esc_url_raw( $ignored ) ); - $activity->set_actor( $actor->get_id() ); - $activity->set_to( $to->get_id() ); - $activity->set_id( $actor->get_id() . '#ignore-' . \preg_replace( '~^https?://~', '', $ignored ) ); - $activity->set_sensitive( null ); - - // @phpstan-ignore-next-line - Http::post( $inbox, $activity->to_json(), $actor->get__id() ); - } - - /** - * Get the WordPress Post ID by the ActivityPub ID. - * - * @param string $activitypub_id The ActivityPub objects ID. - * @return int The WordPress post ID. - */ - private static function get_post_id_by_activitypub_id( $activitypub_id ) { - // Parse the URL and extract its components. - $parsed_url = wp_parse_url( $activitypub_id ); - $home_url = \trailingslashit( \home_url() ); - - // Ensure the base URL matches the home URL. - if ( \trailingslashit( "{$parsed_url['scheme']}://{$parsed_url['host']}" ) !== $home_url ) { - return 0; - } - - // Check for a valid query string and parse it. - if ( isset( $parsed_url['query'] ) ) { - parse_str( $parsed_url['query'], $query_vars ); - - // Ensure the only parameter is 'p'. - if ( count( $query_vars ) === 1 && isset( $query_vars['p'] ) ) { - return intval( $query_vars['p'] ); // Return the post ID. - } - } - - // Fallback: legacy ActivityPub plugin (before version 3.0.0) used pretty permalinks as `id`. - return \url_to_postid( $activitypub_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-undo.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-undo.php deleted file mode 100644 index c2ad5aaa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-undo.php +++ /dev/null @@ -1,73 +0,0 @@ -get_results( - $wpdb->prepare( - "SELECT post_id FROM $wpdb->postmeta WHERE meta_key = %s AND meta_value = %s", - '_event_bridge_for_activitypub_accept_of_follow', - $accept_id - ) - ); - - // If no event source with that accept ID is found return. - if ( empty( $results ) ) { - return; - } - - $post_id = reset( $results )->post_id; - - \delete_post_meta( $post_id, '_event_bridge_for_activitypub_accept_of_follow' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-update.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-update.php deleted file mode 100644 index 1281a95c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/handler/class-update.php +++ /dev/null @@ -1,76 +0,0 @@ -get_icon(); - - if ( is_string( $icon ) ) { - return $icon; - } - - if ( isset( $icon['url'] ) && is_string( $icon['url'] ) ) { - return $icon['url']; - } - - return ''; - } - - /** - * Return the Post-IDs of all events cached by this event source. - */ - public static function get_cached_events(): array { - return array(); - } - - /** - * Getter for URL attribute. - * - * @return string The URL. - */ - public function get_url() { - if ( $this->url ) { - return $this->url; - } - - return $this->id; - } - - /** - * Get the outbox. - * - * @return ?string The outbox URL. - */ - public function get_outbox() { - if ( $this->outbox ) { - return $this->outbox; - } - - $actor_json = \get_post_meta( $this->get__id(), '_activitypub_actor_json', true ); - - if ( ! $actor_json ) { - return null; - } - - $actor = \json_decode( $actor_json, true ); - - if ( ! isset( $actor['outbox'] ) ) { - \do_action( 'event_bridge_for_activitypub_write_log', array( "[ACTIVITYPUB] Did not find outbox URL for actor {$actor}" ) ); - return null; - } - - return $actor['outbox']; - } - - /** - * Get the Event Source Post ID by the ActivityPub ID. - * - * @param string $activitypub_actor_id The ActivityPub actor ID. - * @return int|false The Event Sources Post ID, if a WordPress Post representing it is found, false otherwise. - */ - public static function get_post_id_by_activitypub_id( $activitypub_actor_id ) { - $event_sources = Event_Sources::get_event_sources(); - - return array_search( $activitypub_actor_id, $event_sources, true ); - } - - /** - * Get the Event Source by the ActivityPub ID or WordPress Post ID. - * - * @param int|string $event_source_id The ActivityPub actor ID as string or the Post ID as int of the Event Source. - * @return ?Event_Source The Event Sources if it exists, false otherwise. - */ - public static function get_by_id( $event_source_id ): ?Event_Source { - $post_id = is_integer( $event_source_id ) ? $event_source_id : self::get_post_id_by_activitypub_id( $event_source_id ); - - if ( ! $post_id ) { - return null; - } - - // Get Custom Post. - $event_source_post = \get_post( $post_id ); - - if ( ! $event_source_post ) { - return null; - } - - // Init From Custom Post. - $event_source = self::init_from_cpt( $event_source_post ); - - if ( ! $event_source ) { - return null; - } - - return $event_source; - } - - /** - * Convert a Custom-Post-Type input to an \Event_Bridge_For_ActivityPub\ActivityPub\Model\Event_Source. - * - * @param \WP_Post $post The post object. - * @return ?Event_Source - */ - public static function init_from_cpt( $post ): ?Event_Source { - if ( Event_Sources::POST_TYPE !== $post->post_type ) { - return null; - } - $actor_json = \get_post_meta( $post->ID, '_activitypub_actor_json', true ); - $object = static::init_from_json( $actor_json ); - - if ( \is_wp_error( $object ) ) { - return null; - } - - $object->set__id( $post->ID ); - $object->set_name( $post->post_title ); - $object->set_summary( $post->post_excerpt ); - $object->set_published( gmdate( 'Y-m-d H:i:s', strtotime( $post->post_date ) ) ); - $object->set_updated( gmdate( 'Y-m-d H:i:s', strtotime( $post->post_modified ) ) ); - $object->set_status( $post->post_status ); - $thumbnail_id = \get_post_thumbnail_id( $post ); - if ( $thumbnail_id ) { - $object->set_icon( - array( - 'type' => 'Image', - 'url' => \wp_get_attachment_image_url( $thumbnail_id, 'thumbnail', true ), - ) - ); - } - - if ( ! $object instanceof Event_Source ) { // To make phpstan happy. - return null; - } - - return $object; - } - - /** - * Validate the current Event Source ActivityPub actor object. - * - * @return boolean True if the verification was successful. - */ - public function is_valid(): bool { - // The minimum required attributes. - $required_attributes = array( - 'id', - 'preferredUsername', - 'inbox', - 'publicKey', - 'publicKeyPem', - ); - - foreach ( $required_attributes as $attribute ) { - if ( ! $this->get( $attribute ) ) { - return false; - } - } - - return true; - } - - /** - * Update the post meta. - */ - protected function get_post_meta_input() { - $meta_input = array(); - $meta_input['_activitypub_inbox'] = \sanitize_url( $this->get_shared_inbox() ); - $meta_input['_activitypub_actor_json'] = $this->to_json(); - $meta_input['_activitypub_actor_id'] = $this->get_id(); - - return $meta_input; - } - - /** - * Get the shared inbox, with a fallback to the inbox. - * - * @return string|null The URL to the shared inbox, the inbox or null. - */ - public function get_shared_inbox() { - if ( ! empty( $this->get_endpoints()['sharedInbox'] ) ) { - return $this->get_endpoints()['sharedInbox']; - } elseif ( ! empty( $this->get_inbox() ) ) { - return $this->get_inbox(); - } - - return null; - } - - /** - * Save the current Event Source object to Database within custom post type. - * - * @return int|WP_Error The post ID or an WP_Error. - */ - public function save() { - Event_Sources::delete_event_source_transients(); - - if ( ! $this->is_valid() ) { - return new WP_Error( 'activitypub_invalid_follower', __( 'Invalid Follower', 'event-bridge-for-activitypub' ), array( 'status' => 400 ) ); - } - - if ( ! $this->get__id() ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $post_id = $wpdb->get_var( - $wpdb->prepare( - "SELECT post_id FROM $wpdb->postmeta WHERE meta_key='_activitypub_actor_id' AND meta_value=%s", - esc_sql( $this->get_id() ) - ) - ); - - if ( $post_id ) { - $post = get_post( $post_id ); - $this->set__id( $post->ID ); - } - } - - $post_id = $this->get__id(); - - $args = array( - 'ID' => $post_id, - 'post_title' => wp_strip_all_tags( sanitize_text_field( $this->get_name() ) ), - 'post_author' => 0, - 'post_type' => Event_Sources::POST_TYPE, - 'post_name' => esc_url_raw( $this->get_id() ), - 'post_excerpt' => sanitize_text_field( wp_kses( $this->get_summary(), 'user_description' ) ), - 'post_status' => 'pending', - 'meta_input' => $this->get_post_meta_input(), - ); - - if ( ! empty( $post_id ) ) { - // If this is an update, prevent the "added" date from being overwritten by the current date. - $post = get_post( $post_id ); - $args['post_date'] = $post->post_date; - $args['post_date_gmt'] = $post->post_date_gmt; - } - - $post_id = \wp_insert_post( $args ); - $this->_id = $post_id; - - // Abort if inserting or updating the post didn't work. - - // @phpstan-ignore-next-line - if ( is_wp_error( $post_id ) || 0 === $post_id ) { - return $post_id; - } - - // Delete old icon. - // Check if the post has a thumbnail. - $thumbnail_id = get_post_thumbnail_id( $post_id ); - - if ( $thumbnail_id ) { - // Remove the thumbnail from the post. - delete_post_thumbnail( $post_id ); - - // Delete the attachment (and its files) from the media library. - wp_delete_attachment( $thumbnail_id, true ); - } - - // Set new icon. - $icon = $this->get_icon(); - - if ( isset( $icon['url'] ) ) { - $image = media_sideload_image( sanitize_url( $icon['url'] ), $post_id, null, 'id' ); - } - if ( isset( $image ) && ! is_wp_error( $image ) ) { - set_post_thumbnail( $post_id, $image ); - } - - return $post_id; - } - - /** - * Delete an Event Source and it's profile image. - */ - public function delete() { - $post_id = $this->get__id(); - - if ( ! $post_id ) { - return false; - } - - $thumbnail_id = get_post_thumbnail_id( $post_id ); - - if ( $thumbnail_id ) { - wp_delete_attachment( $thumbnail_id, true ); - } - - $result = wp_delete_post( $post_id, false ) ?? false; - - if ( $result ) { - Event_Sources::delete_event_source_transients(); - } - - return $result; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/scheduler/class-event.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/scheduler/class-event.php deleted file mode 100644 index 668abc39..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/scheduler/class-event.php +++ /dev/null @@ -1,107 +0,0 @@ -is_event_post_type_of_active_event_plugin( $post->post_type ) ) { - return true; - } - - return false; - } - - /** - * Schedule Activities. - * - * @param string $new_status New post status. - * @param string $old_status Old post status. - * @param \WP_Post $post Post object. - */ - public static function maybe_schedule_event_post_activity( $new_status, $old_status, $post ): void { - if ( defined( 'WP_IMPORTING' ) && WP_IMPORTING ) { - return; - } - - if ( ! Setup::get_instance()->is_event_post_type_of_active_event_plugin( $post->post_type ) ) { - return; - } - - if ( Setup::is_post_disabled( $post ) ) { - return; - } - - switch ( $new_status ) { - case 'publish': - $type = ( 'publish' === $old_status ) ? 'Update' : 'Create'; - break; - - case 'draft': - $type = ( 'publish' === $old_status ) ? 'Update' : false; - break; - - case 'trash': - $type = 'Delete'; - break; - - default: - $type = false; - } - - // Do not send Activities if `$type` is not set or unknown. - if ( empty( $type ) ) { - return; - } - - $hook = 'event_bridge_for_activitypub_add_event_post_to_outbox'; - $args = array( $post, $type, $post->post_author ); - - if ( false === \wp_next_scheduled( $hook, $args ) ) { - \wp_schedule_single_event( \time() + 10, $hook, $args ); - } - } - - /** - * Add an event post to the outbox. - * - * @param \WP_Post $post The WP_Post object to add to the outbox. - * @param string $activity_type The type of the Activity. - * @param integer $user_id The User-ID. - */ - public static function add_event_post_to_outbox( $post, $activity_type, $user_id ): void { - $post = get_post( $post->ID ); - add_to_outbox( $post, $activity_type, $user_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-event-organiser.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-event-organiser.php deleted file mode 100644 index 4407c54f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-event-organiser.php +++ /dev/null @@ -1,78 +0,0 @@ -schedule = \eo_get_event_schedule( $item->ID ); - } - - /** - * Get the end time from the event object. - */ - public function get_end_time(): string { - return $this->schedule['end']->format( 'Y-m-d\TH:i:sP' ); - } - - /** - * Get the start time from the event object. - */ - public function get_start_time(): string { - return $this->schedule['start']->format( 'Y-m-d\TH:i:sP' ); - } - - /** - * Get location from the event object. - */ - public function get_location(): ?Place { - $venue = \get_the_terms( $this->item->ID, 'event-venue' ); - - if ( empty( $venue ) || is_wp_error( $venue ) ) { - return null; - } - - $venue = array_pop( $venue ); - - $location_transformer = new Event_Organiser_Location_Transformer( $venue ); - $location = $location_transformer->to_object(); - - return $location; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-event.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-event.php deleted file mode 100644 index 09468e20..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-event.php +++ /dev/null @@ -1,609 +0,0 @@ -item ); - } - - /** - * Set a hardcoded template for the content. - * - * This actually disabled templates for the content. - * Maybe this independent templates for events will be added later. - */ - protected function get_post_content_template(): string { - return '[ap_content]'; - } - - /** - * Extend the construction of the Post Transformer to also set the according taxonomy of the event post type. - * - * @param \WP_Post $item The WordPress post object (event). - * @param string $wp_taxonomy The taxonomy slug of the event post type. - */ - public function __construct( $item, $wp_taxonomy = 'category' ) { - parent::__construct( $item ); - $this->wp_taxonomy = $wp_taxonomy; - } - - /** - * Extract the join mode. - * - * Currently we don't handle joins, we always mark events as external. - * - * @return string - */ - public function get_join_mode(): ?string { - return 'external'; - } - - /** - * Extract the external participation url. - * - * Currently we don't handle joins, we always mark events as external. - * We just link back to the events HTML representation on our WordPress site. - * - * @return ?string The external participation URL. - */ - public function get_external_participation_url(): ?string { - return 'external' === $this->get_join_mode() ? $this->get_url() : null; - } - - /** - * Set the event category, via the mapping setting. - * - * @return ?string - */ - public function get_category(): ?string { - if ( is_null( $this->wp_taxonomy ) ) { - return null; - } - $current_category_mapping = \get_option( 'event_bridge_for_activitypub_event_category_mappings', array() ); - $terms = \get_the_terms( $this->item, $this->wp_taxonomy ); - - // Check if the event has a category set and if that category has a specific mapping return that one. - if ( ! is_wp_error( $terms ) && $terms && array_key_exists( $terms[0]->slug, $current_category_mapping ) ) { - return sanitize_text_field( $current_category_mapping[ $terms[0]->slug ] ); - } else { - // Return the default event category. - return sanitize_text_field( \get_option( 'event_bridge_for_activitypub_default_event_category', 'MEETING' ) ); - } - } - - /** - * Retrieves the excerpt text (may be HTML). Used for constructing the summary. - * - * @return ?string - */ - protected function retrieve_excerpt(): ?string { - if ( $this->item->post_excerpt ) { - return $this->item->post_excerpt; - } else { - return null; - } - } - - /** - * Get the start time. - * - * This is mandatory and must be implemented in the final event transformer class. - */ - abstract public function get_start_time(): string; - - /** - * Get the end time. - * - * This is not mandatory and therefore just return null by default. - */ - public function get_end_time(): ?string { - return null; - } - - /** - * Get a default for the location. - * - * This should be overridden in the actual event transformer. - * - * @return array|Place|null - */ - public function get_location() { - return null; - } - - /** - * Default value for the event status. - */ - public function get_status(): ?string { - return 'CONFIRMED'; - } - - /** - * Compose a human readable formatted start time. - */ - protected function format_start_time(): string { - return $this->format_time( $this->get_start_time() ); - } - - /** - * Compose a human readable formatted end time. - */ - protected function format_end_time(): string { - return $this->format_time( $this->get_end_time() ); - } - - /** - * Compose a human readable formatted time. - * - * @param ?string $time The time which needs to be formatted. - */ - protected static function format_time( $time ) { - if ( is_null( $time ) ) { - return ''; - } - $start_datetime = new DateTime( $time ); - $start_timestamp = $start_datetime->getTimestamp(); - $datetime_format = get_option( 'date_format' ) . ' ' . get_option( 'time_format' ); - return \wp_date( $datetime_format, $start_timestamp ); - } - - /** - * Generates output for the 'ap_start_time' shortcode. - * - * @param ?array $atts The shortcode's attributes. - * @return string The formatted start date and time of the event. - */ - public function shortcode_start_time( $atts ) { - $start_timestamp = $this->get_start_time(); - return $this->generate_time_output( $start_timestamp, $atts, '🗓️', __( 'Start', 'event-bridge-for-activitypub' ) ); - } - - /** - * Generates output for the 'ap_end_time' shortcode. - * - * @param ?array $atts The shortcode's attributes. - * @return string The formatted end date and time of the event. - */ - public function shortcode_end_time( $atts ) { - $end_timestamp = $this->get_end_time(); - return $this->generate_time_output( $end_timestamp, $atts, '⏳', __( 'End', 'event-bridge-for-activitypub' ) ); - } - - /** - * Generates the formatted time output for a shortcode. - * - * @param string|null $timestamp The timestamp for the event time. - * @param array $atts The shortcode attributes. - * @param string $icon The icon to display. - * @param string $label The label to display (e.g., 'Start', 'End'). - * @return string The formatted date and time, or an empty string if the timestamp is invalid. - */ - private function generate_time_output( $timestamp, $atts, $icon, $label ): string { - if ( ! $timestamp ) { - return ''; - } - - $args = shortcode_atts( - array( - 'icon' => 'true', - 'label' => 'true', - ), - $atts - ); - - $args['icon'] = filter_var( $args['icon'], FILTER_VALIDATE_BOOLEAN ); - $args['label'] = filter_var( $args['label'], FILTER_VALIDATE_BOOLEAN ); - - $output = array(); - - if ( $args['icon'] ) { - $output[] = $icon; - } - - if ( $args['label'] ) { - $output[] = $label . ':'; - } - - $output[] = self::format_time( $timestamp ); - - return implode( ' ', $output ); - } - - /** - * Generates output for the 'ap_location' shortcode. - * - * @param ?array $atts The shortcode's attributes. - * @return string The formatted location/address of the event. - */ - public function shortcode_location( $atts ) { - $args = shortcode_atts( - array( - 'icon' => 'true', - 'label' => 'true', - 'country' => 'true', - 'zip' => 'true', - 'city' => 'true', - 'street' => 'true', - ), - $atts, - 'ap_location' - ); - - // Convert attributes to booleans. - $args = array_map( - function ( $value ) { - return filter_var( $value, FILTER_VALIDATE_BOOLEAN ); - }, - $args - ); - - $location = $this->get_location(); - if ( ! $location ) { - return ''; - } - - $output = array(); - - if ( is_array( $location ) && isset( $location['type'] ) && 'VirtualLocation' === $location['type'] ) { - if ( $args['icon'] ) { - $output[] = '🔗'; - } - if ( $args['label'] && isset( $location['name'] ) ) { - $output[] = $location['name'] . ':'; - } - } else { - if ( $args['icon'] ) { - $output[] = '📍'; - } - - if ( $args['label'] ) { - $output[] = esc_html__( 'Location', 'event-bridge-for-activitypub' ) . ':'; - } - } - - $output[] = $this->get_formatted_address( true, $args ); - - // Join output array into a single string with spaces and return. - return implode( ' ', array_filter( $output ) ); - } - - /** - * Formats the address based on provided arguments. - * - * @param mixed $address The address data, either as a string or an array. - * @param array $args The arguments for which components to include. - * @return string The formatted address. - */ - protected static function format_address( $address, $args = array() ) { - if ( is_string( $address ) ) { - return esc_html( $address ); - } - - if ( empty( $args ) ) { - $args = array( - 'icon' => 'true', - 'title' => 'true', - 'country' => 'true', - 'zip' => 'true', - 'city' => 'true', - 'street' => 'true', - ); - } - - if ( is_array( $address ) ) { - $address_parts = array(); - - $components = array( - 'street' => 'streetAddress', - 'zip' => 'postalCode', - 'city' => 'addressLocality', - 'country' => 'addressCountry', - ); - - foreach ( $components as $arg_key => $address_key ) { - if ( $args[ $arg_key ] && ! empty( $address[ $address_key ] ) ) { - $address_parts[] = esc_html( $address[ $address_key ] ); - } - } - - return implode( ', ', $address_parts ); - } - - return ''; - } - - /** - * Format the category using the translation. - */ - protected function format_categories(): string { - if ( is_null( $this->wp_taxonomy ) ) { - return ''; - } - $categories = array(); - - // Add the federated category string. - require_once EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . '/includes/event-categories.php'; - $federated_category = $this->get_category(); - if ( array_key_exists( $federated_category, EVENT_BRIDGE_FOR_ACTIVITYPUB_EVENT_CATEGORIES ) ) { - $categories[] = EVENT_BRIDGE_FOR_ACTIVITYPUB_EVENT_CATEGORIES[ $federated_category ]; - } - - // Add all category terms. - $terms = \get_the_terms( $this->item, $this->wp_taxonomy ); - if ( $terms && ! is_wp_error( $terms ) ) { - foreach ( $terms as $term ) { - $categories[] = $term->name; - } - } - - if ( ! empty( $categories ) ) { - return implode( ' · ', array_unique( $categories ) ); - } - return ''; - } - - /** - * Register the shortcodes. - */ - public function register_shortcodes() { - Shortcodes::register(); - foreach ( array( 'location', 'start_time', 'end_time' ) as $shortcode ) { - \add_shortcode( 'ap_' . $shortcode, array( $this, 'shortcode_' . $shortcode ) ); - } - } - - /** - * Register the shortcodes. - */ - public function unregister_shortcodes() { - Shortcodes::unregister(); - foreach ( array( 'location', 'start_time', 'end_time' ) as $shortcode ) { - \remove_shortcode( 'ap_' . $shortcode ); - } - } - - /** - * Get the summary. - */ - public function get_summary(): ?string { - if ( 'preset' === get_option( 'event_bridge_for_activitypub_summary_type', 'preset' ) ) { - $summary = EVENT_BRIDGE_FOR_ACTIVITYPUB_SUMMARY_TEMPLATE; - } else { - $summary = $this->get_event_summary_template(); - } - - // It seems that shortcodes are only applied to published posts. - if ( is_preview() ) { - $this->item->post_status = 'publish'; - } - - // Register our shortcodes just in time. - - $this->register_shortcodes(); - - // Fill in the shortcodes. - \setup_postdata( $this->item ); - Shortcodes::register(); - $summary = \do_shortcode( $summary ); - \wp_reset_postdata(); - - $summary = \wpautop( $summary ); - $summary = \preg_replace( '/[\n\r\t]/', '', $summary ); - $summary = \trim( $summary ); - - $summary = \apply_filters( 'event_bridge_for_activitypub_the_summary', $summary, $this->item ); - - // Unregister the shortcodes. - $this->unregister_shortcodes(); - - if ( 'plain' === get_option( 'event_bridge_for_activitypub_summary_format', 'html' ) ) { - $summary = self::strip_html_preserve_linebreaks( $summary ); - } - - return $summary; - } - - /** - * Strip all HTML but preverse some line breaks. - * - * @param mixed $content The HTML input. - * @return string - */ - private static function strip_html_preserve_linebreaks( $content ): string { - // Replace
with newlines. - $content = preg_replace( '//i', "\n", $content ); - - // Replace closing

followed by

with double newlines (preserve paragraph breaks). - $content = preg_replace( '/<\/p>\s*

/', "\n\n", $content ); - - // Preserve list structure. - $content = preg_replace( '/<\/ul>/i', "\n", $content ); - $content = preg_replace( '/

  • /i', '- ', $content ); - $content = preg_replace( '/<\/li>/i', "\n", $content ); - - // Remove all remaining HTML tags. - $content = wp_strip_all_tags( $content ); - - // Normalize excessive newlines (more than 2 in a row to just 2). - $content = preg_replace( "/\n{3,}/", "\n\n", $content ); - - // Trim trailing newlines. - return trim( $content ); - } - - /** - * Get the address as a string. - * - * @param bool $include_location_name Whether to include the locations name. - * @param array $args The arguments forwarded to format_address. - * - * @return string - */ - public function get_formatted_address( $include_location_name = false, $args = array() ) { - $location = $this->get_location(); - - if ( $location instanceof Place ) { - $location_name = $location->get_name(); - $foramted_address = self::format_address( $location->get_address(), $args ); - - $loaction_parts = array(); - - if ( $location_name ) { - $location_parts[] = $location_name; - } - - if ( $foramted_address ) { - $location_parts[] = $foramted_address; - } - - if ( ! empty( $location_parts ) ) { - return implode( ', ', $location_parts ); - } - } elseif ( is_array( $location ) && isset( $location['type'] ) && 'VirtualLocation' === $location['type'] ) { - if ( isset( $location['url'] ) ) { - return $location['url']; - } - } - - return ''; - } - - /** - * Gets the template to use to generate the summary of the ActivityStreams representation of an event post. - * - * @return string The Template. - */ - protected function get_event_summary_template() { - $summary = \get_option( 'event_bridge_for_activitypub_custom_summary', EVENT_BRIDGE_FOR_ACTIVITYPUB_SUMMARY_TEMPLATE ); - $template = $summary ?? EVENT_BRIDGE_FOR_ACTIVITYPUB_SUMMARY_TEMPLATE; - - return apply_filters( 'event_bridge_for_activitypub_summary_template', $template, $this->item ); - } - - /** - * By default set the timezone of the WordPress site. - * - * This is likely to be overwritten by the actual transformer. - * - * @return string The timezone string of the site. - */ - public function get_timezone(): string { - return \wp_timezone_string(); - } - - /** - * Remove the permalink shortcode from a WordPress template. - * - * This used for the summary template, because the summary usually gets, - * used when converting a object, where the URL is usually appended anyway. - * - * @param string $template The template string. - * @param WP_Post|WP_Comment $item The item which was used to select the template. - */ - public static function remove_ap_permalink_from_template( $template, $item ) { - - // we could override the template here, to get out custom template from an option. - - if ( 'event' === $item->post_type ) { - $template = str_replace( '[ap_permalink]', '', $template ); - $template = str_replace( '[ap_permalink type="html"]', '', $template ); - } - - return $template; - } - - /** - * Generic function that converts an WP-Event object to an ActivityPub-Event object. - * - * @return Event_object|\WP_Error - */ - public function to_object() { - $activitypub_object = new Event_Object(); - $activitypub_object = $this->transform_object_properties( $activitypub_object ); - - // @phpstan-ignore-next-line - $activitypub_object->set_comments_enabled( $this->get_comments_enabled() ); - - if ( \is_wp_error( $activitypub_object ) ) { - return $activitypub_object; - } - - // maybe move the following logic (till end of the function) into getter functions. - - $published = \strtotime( $this->item->post_date_gmt ); - - $activitypub_object->set_published( \gmdate( 'Y-m-d\TH:i:s\Z', $published ) ); - - $updated = \strtotime( $this->item->post_modified_gmt ); - - if ( $updated > $published ) { - $activitypub_object->set_updated( \gmdate( 'Y-m-d\TH:i:s\Z', $updated ) ); - } - - $activitypub_object->set_content_map( - array( - $this->get_locale() => $this->get_content(), - ) - ); - - $activitypub_object->set_to( - array( - 'https://www.w3.org/ns/activitystreams#Public', - $this->get_actor_object()->get_followers(), - ) - ); - - // @phpstan-ignore-next-line - return $activitypub_object; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventin.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventin.php deleted file mode 100644 index fd518845..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventin.php +++ /dev/null @@ -1,166 +0,0 @@ -event_model = new Event_Model( $this->item->ID ); - } - - /** - * Get the end time from the event object. - */ - public function get_start_time(): string { - return \gmdate( 'Y-m-d\TH:i:s\Z', strtotime( $this->event_model->get_start_datetime() ) ); - } - - /** - * Get the end time from the event object. - */ - public function get_end_time(): string { - return \gmdate( 'Y-m-d\TH:i:s\Z', strtotime( $this->event_model->get_end_datetime() ) ); - } - - /** - * Get the timezone of the event. - */ - public function get_timezone(): string { - return $this->event_model->get_timezone(); - } - - /** - * Get whether the event is online. - * - * @return bool - */ - public function get_is_online(): bool { - return 'online' === $this->event_model->__get( 'event_type' ) ? true : false; - } - - /** - * Maybe add online link to attachments. - * - * @return array - */ - public function get_attachment(): array { - $attachment = parent::get_attachment(); - - $location = (array) $this->event_model->__get( 'location' ); - - // @phpstan-ignore-next-line - if ( array_key_exists( 'integration', $location ) && array_key_exists( $location['integration'], $location ) ) { - $online_link = array( - 'type' => 'Link', - 'mediaType' => 'text/html', - 'name' => $location[ $location['integration'] ], - 'href' => $location[ $location['integration'] ], - ); - $attachment[] = $online_link; - } - return $attachment; - } - - /** - * Compose the events tags. - */ - public function get_tag(): ?array { - // The parent tag function also fetches the mentions. - $tags = parent::get_tag(); - - $post_tags = \wp_get_post_terms( $this->item->ID, 'etn_tags' ); - $post_categories = \wp_get_post_terms( $this->item->ID, 'etn_category' ); - - if ( ! is_wp_error( $post_tags ) && $post_tags ) { - foreach ( $post_tags as $term ) { - $tag = array( - 'type' => 'Hashtag', - 'href' => \esc_url( \get_tag_link( $term->term_id ) ), - 'name' => esc_hashtag( $term->name ), - ); - $tags[] = $tag; - } - } - - if ( ! is_wp_error( $post_categories ) && $post_categories ) { - foreach ( $post_categories as $term ) { - $tag = array( - 'type' => 'Hashtag', - 'href' => \esc_url( \get_tag_link( $term->term_id ) ), - 'name' => esc_hashtag( $term->name ), - ); - $tags[] = $tag; - } - } - - if ( empty( $tags ) ) { - return null; - } - - return $tags; - } - - /** - * Get the location. - * - * @return ?Place - */ - public function get_location(): ?Place { - $location = (array) $this->event_model->__get( 'location' ); - - // @phpstan-ignore-next-line - if ( ! array_key_exists( 'address', $location ) ) { - return null; - } - - // @phpstan-ignore-next-line - $place = new Place(); - - $address = $location['address']; - - $place->set_name( $address ); - $place->set_address( $address ); - $place->set_sensitive( null ); - - return $place; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventon.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventon.php deleted file mode 100644 index c005e1aa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventon.php +++ /dev/null @@ -1,186 +0,0 @@ -wp_taxonomy = $wp_taxonomy; - - $this->tax_meta = \get_option( 'evo_tax_meta' ); - } - - - /** - * Get content. - */ - public function get_content(): string { - $subtitle = \get_post_meta( $this->item->ID, 'evcal_subtitle', true ); - - $content = $subtitle ? $subtitle . '
    ' : ''; - $content = $content . parent::get_content(); - return $content; - } - - /** - * Get the event location(s). - * - * @return array|null The Place. - */ - public function get_location() { - $location = array(); - - $terms = \get_the_terms( $this->item->ID, 'event_location' ); - - // The terms may both contain virtual and physical Locations. - if ( ! empty( $terms ) ) { - foreach ( $terms as $term ) { - $location_transformer = new EventOn_Place_Transformer( $term ); - $location[] = $location_transformer->to_object()->to_array( false ); - } - } - - // Virtual Locations can also be directly int the post meta, not in terms! - $virtual_url = \get_post_meta( $this->item->ID, '_vir_url', true ); - $virtual_type = \get_post_meta( $this->item->ID, '_vir_type', true ); - - if ( $virtual_url ) { - $virtual_location = array( - 'type' => 'VirtualLocation', - 'url' => (string) $virtual_url, - ); - if ( $virtual_type ) { - $virtual_location['name'] = (string) $virtual_type; - } - $location[] = $virtual_location; - } - - // If we only have one location, send object directy, not in array. - if ( 1 === count( $location ) ) { - $location = reset( $location ); - } elseif ( empty( $location ) ) { - return null; - } - - return $location; - } - - /** - * Get the end time from the events metadata. - */ - public function get_end_time(): ?string { - $end_time = \get_post_meta( $this->item->ID, '_unix_end_ev', true ); - $timezone = \get_post_meta( $this->item->ID, '_evo_tz', true ); - $timezone = $timezone ? new \DateTimeZone( $timezone ) : null; - - if ( is_null( $end_time ) || empty( $end_time ) ) { - return null; - } - return \wp_date( 'Y-m-d\TH:i:sP', (int) $end_time, $timezone ); - } - - /** - * Get timezone - * - * @return string - */ - public function get_timezone(): string { - $timezone = \get_post_meta( $this->item->ID, '_evo_tz', true ); - - return $timezone ?? \wp_timezone_string(); - } - - /** - * Get the end time from the events metadata. - */ - public function get_start_time(): string { - $start_time = \get_post_meta( $this->item->ID, '_unix_start_ev', true ); - $timezone = \get_post_meta( $this->item->ID, '_evo_tz', true ); - $timezone = $timezone ? new \DateTimeZone( $timezone ) : null; - - return \wp_date( 'Y-m-d\TH:i:sP', (int) $start_time, $timezone ); - } - - /** - * Get the event link from the events metadata. - * - * @return ?array Associated array of an ActivityStreams Link object with the events URL. - */ - private function get_event_link(): ?array { - $event_link = \get_post_meta( $this->item->ID, 'event-link', true ); - $event_link_label = \get_post_meta( $this->item->ID, 'event-link-label', true ) ?? 'Event Link'; - if ( $event_link ) { - return array( - 'type' => 'Link', - 'name' => $event_link_label, - 'href' => \esc_url( $event_link ), - 'mediaType' => 'text/html', - ); - } - return null; - } - - /** - * Overrides/extends the get_attachments function to also add the event Link. - * - * @return array - */ - protected function get_attachment(): array { - $attachments = parent::get_attachment(); - if ( count( $attachments ) ) { - $attachments[0]['type'] = 'Document'; - $attachments[0]['name'] = 'Banner'; - } - $event_link = $this->get_event_link(); - if ( $event_link ) { - $attachments[] = $event_link; - } - return $attachments; - } - - /** - * Retrieves the excerpt text (may be HTML). Used for constructing the summary. - * - * @return ?string - */ - protected function retrieve_excerpt(): ?string { - if ( \get_post_meta( $this->item->ID, 'event-summary', true ) ) { - return \get_post_meta( $this->item->ID, 'event-summary', true ); - } else { - return parent::retrieve_excerpt(); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventprime.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventprime.php deleted file mode 100644 index b3008f69..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-eventprime.php +++ /dev/null @@ -1,70 +0,0 @@ -wp_object->ID, 'em_end_date', true ); - if ( $timestamp ) { - return \gmdate( 'Y-m-d\TH:i:s\Z', $timestamp ); - } else { - return null; - } - } - - /** - * Get the end time from the event object. - */ - public function get_start_time(): string { - $timestamp = \get_post_meta( $this->wp_object->ID, 'em_start_date', true ); - if ( $timestamp ) { - return \gmdate( 'Y-m-d\TH:i:s\Z', $timestamp ); - } else { - return ''; - } - } - - /** - * Get location from the event object. - */ - public function get_location(): ?Place { - $venue_term_id = \get_post_meta( $this->item->ID, 'em_venue', true ); - if ( ! $venue_term_id ) { - return null; - } - - $venue = \get_the_terms( $this->item->ID, 'em_venue' ); - - if ( empty( $venue ) || is_wp_error( $venue ) ) { - return null; - } - - $venue = array_pop( $venue ); - - $location_transformer = new EventPrime_Location_Transformer( $venue ); - $location = $location_transformer->to_object(); - - return $location; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-events-manager.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-events-manager.php deleted file mode 100644 index f61f50a6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-events-manager.php +++ /dev/null @@ -1,248 +0,0 @@ -em_event = new EM_Event( $this->item->ID, 'post_id' ); - } - - /** - * Returns whether the even is online - * - * @return bool - */ - protected function is_online(): bool { - return \EM_Event_Locations\Event_Locations::is_enabled( 'url' ) && 'url' === $this->em_event->event_location_type; - } - - /** - * Get the event location. - * - * @return array|Place|null The Place. - */ - public function get_location() { - if ( $this->is_online() ) { - if ( property_exists( $this->em_event->event_location, 'data' ) ) { - $event_location = $this->em_event->event_location->data; - } else { - $event_location = array(); - } - - $event_link_url = isset( $event_location['url'] ) ? $event_location['url'] : null; - $event_link_text = isset( $event_location['text'] ) ? $event_location['text'] : esc_html__( 'Link', 'event-bridge-for-activitypub' ); - - if ( empty( $event_link_url ) ) { - return null; - } - - return array( - 'type' => 'VirtualLocation', - 'url' => \esc_url( $event_link_url ), - 'name' => \esc_html( $event_link_text ), - ); - } - - if ( ! \EM_Locations::is_enabled() ) { - return null; - } - - $em_location = $this->em_event->get_location(); - - if ( ! isset( $em_location->post_id ) || ! $em_location->post_id ) { - return null; - } - - $location_transformer = new Events_Manager_Place_Transformer( get_post( $em_location->post_id ) ); - $full_location_object = false; - $location = $location_transformer->to_object( $full_location_object ); - return $location; - } - - /** - * Get the end time from the events metadata. - */ - public function get_end_time(): ?string { - return null; - } - - /** - * Get the end time from the events metadata. - */ - public function get_start_time(): string { - $date_string = $this->em_event->event_start_date; - $time_string = $this->em_event->event_start_time; - $timezone_string = $this->em_event->event_timezone; - - // Create a DateTime object with the given date, time, and timezone. - $datetime = new DateTime( $date_string . ' ' . $time_string, new DateTimeZone( $timezone_string ) ); - - // Set the timezone for proper formatting. - $datetime->setTimezone( new DateTimeZone( 'UTC' ) ); - - // Format the DateTime object as 'Y-m-d\TH:i:s\Z'. - $formatted_date = $datetime->format( 'Y-m-d\TH:i:s\Z' ); - return $formatted_date; - } - - /** - * Returns the maximum attendee capacity. - * - * @return ?int - */ - public function get_maximum_attendee_capacity() { - return $this->em_event->event_spaces; - } - - /** - * Return the remaining attendee capacity - * - * @return ?int - */ - public function get_remaining_attendee_capacity(): ?int { - $em_bookings_count = $this->get_participant_count(); - $max_bookings = $this->em_event->event_spaces; - - if ( $max_bookings && $em_bookings_count ) { - return $this->em_event->event_spaces - $em_bookings_count; - } - - return null; - } - - /** - * Returns the current participant count. - * - * @return int - */ - public function get_participant_count(): int { - $em_bookings = $this->em_event->get_bookings()->get_bookings(); - return count( $em_bookings->bookings ); - } - - /** - * Get the event link as an ActivityPub Link object, but as an associative array. - * - * @return array|null - */ - private function get_event_link_attachment(): ?array { - if ( $this->is_online() ) { - if ( property_exists( $this->em_event->event_location, 'data' ) ) { - $event_location = $this->em_event->event_location->data; - } else { - $event_location = array(); - } - - $event_link_url = isset( $event_location['url'] ) ? $event_location['url'] : null; - $event_link_text = isset( $event_location['text'] ) ? $event_location['text'] : __( 'Link', 'event-bridge-for-activitypub' ); - - if ( empty( $event_link_url ) ) { - return null; - } - - return array( - 'type' => 'Link', - 'name' => \esc_html( $event_link_text ), - 'href' => \esc_url( $event_link_url ), - 'mediaType' => 'text/html', - ); - } - - return null; - } - - /** - * Overrides/extends the get_attachments function to also add the event Link. - */ - protected function get_attachment(): array { - // Get attachments via parent function. - $attachments = parent::get_attachment(); - - // The first attachment is the featured image, make sure it is compatible with Mobilizon. - if ( count( $attachments ) ) { - $attachments[0]['type'] = 'Document'; - $attachments[0]['name'] = 'Banner'; - } - - $event_link_attachment = $this->get_event_link_attachment(); - - if ( $event_link_attachment ) { - $attachments[] = $event_link_attachment; - } - return $attachments; - } - - /** - * Compose the events tags. - */ - public function get_tag(): array { - // The parent tag function also fetches the mentions. - $tags = parent::get_tag(); - - $post_tags = \wp_get_post_terms( $this->item->ID, 'event-tags' ); - - if ( $post_tags ) { - foreach ( $post_tags as $post_tag ) { - $tag = array( - 'type' => 'Hashtag', - 'href' => \esc_url( \get_tag_link( $post_tag->term_id ) ), - 'name' => esc_hashtag( $post_tag->name ), - ); - $tags[] = $tag; - } - } - return $tags; - } - - /** - * Get the events title/name. - * - * @return string - */ - protected function get_name(): string { - return $this->em_event->event_name; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-gatherpress.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-gatherpress.php deleted file mode 100644 index 9b4f49f7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-gatherpress.php +++ /dev/null @@ -1,156 +0,0 @@ -gp_event = new GatherPress_Event( $item->ID ); - $this->gp_venue = $this->gp_event->get_venue_information(); - } - - /** - * Get the event location. - * - * @return ?Place The place objector null if not place set. - */ - public function get_location(): ?Place { - $address = $this->gp_venue['full_address']; - if ( $address ) { - $place = new Place(); - $place->set_type( 'Place' ); - $place->set_name( $address ); - $place->set_address( $address ); - return $place; - } else { - return null; - } - } - - /** - * Get the end time from the event object. - */ - public function get_end_time(): string { - return $this->gp_event->get_datetime_end( 'Y-m-d\TH:i:s\Z' ); - } - - /** - * Get the end time from the event object. - */ - public function get_start_time(): string { - return $this->gp_event->get_datetime_start( 'Y-m-d\TH:i:s\Z' ); - } - - /** - * Get the event link from the events metadata. - */ - private function get_event_link(): array { - - $event_link = get_post_meta( $this->item->ID, 'event-link', true ); - if ( $event_link ) { - return array( - 'type' => 'Link', - 'name' => 'Website', - 'href' => \esc_url( $event_link ), - 'mediaType' => 'text/html', - ); - } - - return array(); - } - - /** - * Overrides/extends the get_attachments function to also add the event Link. - */ - protected function get_attachment(): array { - $attachments = parent::get_attachment(); - if ( count( $attachments ) ) { - $attachments[0]['type'] = 'Document'; - $attachments[0]['name'] = 'Banner'; - } - $event_link = $this->get_event_link(); - if ( $event_link ) { - $attachments[] = $this->get_event_link(); - } - return $attachments; - } - - /** - * Prevents gatherpress blocks from being rendered for the content. - * - * @param mixed $block_content The blocks content. - * @param mixed $block The block. - */ - public static function filter_gatherpress_blocks( $block_content, $block ) { - // Check if the block name starts with 'gatherpress'. - if ( isset( $block['blockName'] ) && 0 === strpos( $block['blockName'], 'gatherpress/' ) ) { - return ''; // Skip rendering this block. - } - - return $block_content; // Return the content for other blocks. - } - - /** - * Apply the filter for preventing the rendering off gatherpress blocks just in time. - * - * @return Event_Object - */ - public function to_object(): Event_Object { - add_filter( 'render_block', array( self::class, 'filter_gatherpress_blocks' ), 10, 2 ); - $activitypub_object = parent::to_object(); - remove_filter( 'render_block', array( self::class, 'filter_gatherpress_blocks' ) ); - return $activitypub_object; - } - - /** - * Determine whether the event is online. - * - * @return bool - */ - public function get_is_online(): bool { - return $this->gp_event->maybe_get_online_event_link() ? true : false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-modern-events-calendar-lite.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-modern-events-calendar-lite.php deleted file mode 100644 index 48011a65..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-modern-events-calendar-lite.php +++ /dev/null @@ -1,127 +0,0 @@ -mec_main = MEC::getInstance( 'app.libraries.main' ); - $this->mec_event = new MEC_Event( $item ); - } - - /** - * Retrieves the content without the plugins rendered shortcodes. - */ - public function get_content(): string { - $content = wpautop( $this->item->post_content ); - return $content; - } - - /** - * Get the end time from the event object. - * - * @return string - */ - public function get_start_time(): string { - return \gmdate( 'Y-m-d\TH:i:s\Z', $this->mec_event->get_datetime()['start']['timestamp'] ); - } - - /** - * Get the end time from the event object. - * - * @return string - */ - public function get_end_time(): string { - return \gmdate( 'Y-m-d\TH:i:s\Z', $this->mec_event->get_datetime()['end']['timestamp'] ); - } - - /** - * Get the location. - * - * @return ?Place - */ - public function get_location(): ?Place { - $location_id = $this->mec_main->get_master_location_id( $this->mec_event->ID ); - - if ( ! $location_id ) { - return null; - } - - $data = $this->mec_main->get_location_data( $location_id ); - - $location = new Place(); - $location->set_sensitive( null ); - - if ( ! empty( $data['address'] ) ) { - $location->set_address( $data['address'] ); - } - if ( ! empty( $data['name'] ) ) { - $location->set_name( $data['name'] ); - } - if ( ! empty( $data['longitude'] ) ) { - $location->set_longitude( $data['longitude'] ); - } - if ( ! empty( $data['latitude'] ) ) { - $location->set_latitude( $data['latitude'] ); - } - - return $location; - } - - /** - * Get the location. - */ - public function get_timezone(): string { - $timezone = get_post_meta( $this->item->ID, 'mec_timezone', true ); - - if ( 'global' === $timezone ) { - return parent::get_timezone(); - } - - return $timezone; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-the-events-calendar.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-the-events-calendar.php deleted file mode 100644 index 61cb979e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-the-events-calendar.php +++ /dev/null @@ -1,203 +0,0 @@ -tribe_event = \tribe_get_event( $item ); - } - - /** - * Get the tags, including also the set categories from The Events Calendar. - * - * @return array The array if tags, - */ - public function get_tag(): array { - $tags = array(); - $category_ids = tribe_get_event_cat_ids(); - if ( $category_ids ) { - foreach ( $category_ids as $category_id ) { - $term = \get_term( $category_id ); - $tag = array( - 'type' => 'Hashtag', - 'href' => \esc_url( \get_term_link( $term ) ), - 'name' => esc_hashtag( $term->name ), - ); - $tags[] = $tag; - } - } - $tags = array_merge( $tags, parent::get_tag() ); - - return $tags; - } - - /** - * Get the end time from the event object. - */ - public function get_end_time(): string { - $utc_time = get_post_meta( $this->tribe_event->ID, '_EventEndDateUTC', true ); - $timezone = new \DateTimeZone( $this->get_timezone() ); - $time = new \DateTime( $utc_time ); - $time->setTimezone( $timezone ); - return $time->format( 'Y-m-d\TH:i:sP' ); - } - - /** - * Get the end time from the event object. - */ - public function get_start_time(): string { - $utc_time = get_post_meta( $this->tribe_event->ID, '_EventStartDateUTC', true ); - $timezone = new \DateTimeZone( $this->get_timezone() ); - $time = new \DateTime( $utc_time ); - $time->setTimezone( $timezone ); - return $time->format( 'Y-m-d\TH:i:sP' ); - } - - /** - * Get the timezone of the event. - * - * @return string The timezone string of the site. - */ - public function get_timezone(): string { - // @phpstan-ignore-next-line - $timezone = $this->tribe_event->timezone; - - if ( ! $timezone || ! is_string( $timezone ) ) { - return parent::get_timezone(); - } - - return $timezone; - } - - /** - * Get status of the tribe event - * - * @return string status of the event - */ - public function get_status(): string { - // @phpstan-ignore-next-line - $event_status = $this->tribe_event->event_status; - - if ( 'canceled' === $event_status ) { - return 'CANCELLED'; - } - - if ( 'postponed' === $event_status ) { - return 'CANCELLED'; // This will be reflected in the cancelled reason. - } - - return 'CONFIRMED'; - } - - - /** - * Check if the comments are enabled for the current event. - */ - public function get_comments_enabled(): bool { - return ( 'open' === $this->tribe_event->comment_status ) ? true : false; - } - - /** - * Check if the event is an online event. - */ - public function get_is_online(): bool { - return false; - } - - /** - * Get the event location. - * - * @return ?Place The place/venue if one is set. - */ - public function get_location(): ?Place { - // Get short handle for the venues. - - if ( ! \tribe_has_venue( $this->tribe_event->ID ) ) { - return null; - } - - $venue_id = \tribe_get_venue_id( $this->tribe_event->ID ); - $post = \get_post( $venue_id ); - - if ( ! $post ) { - return null; - } - - $location_transformer = new The_Events_Calendar_Location( $post ); - $full_location_object = false; - $location = $location_transformer->to_object( $full_location_object ); - return $location; - } - - /** - * Apply the filter for preventing the rendering off The Events Calendar blocks just in time. - * - * @return Event_Object - */ - public function to_object(): Event_Object { - add_filter( 'render_block', array( self::class, 'filter_tribe_blocks' ), 10, 2 ); - $activitypub_object = parent::to_object(); - remove_filter( 'render_block', array( self::class, 'filter_tribe_blocks' ) ); - return $activitypub_object; - } - - /** - * Prevents The Events Calendar blocks from being rendered for the content. - * - * @param mixed $block_content The blocks content. - * @param mixed $block The block. - */ - public static function filter_tribe_blocks( $block_content, $block ) { - // Check if the block name starts with 'tribe' and is not an exception. - if ( isset( $block['blockName'] ) && 0 === strpos( $block['blockName'], 'tribe/' ) ) { - return ''; // Skip rendering this block. - } - - return $block_content; // Return the content for other blocks. - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-vs-event-list.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-vs-event-list.php deleted file mode 100644 index 1ea96415..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-vs-event-list.php +++ /dev/null @@ -1,115 +0,0 @@ -item->ID, 'event-location', true ); - if ( $address ) { - $place = new Place(); - $place->set_type( 'Place' ); - $place->set_name( $address ); - $place->set_address( $address ); - return $place; - } else { - return null; - } - } - - /** - * Get the end time from the events metadata. - */ - public function get_end_time(): ?string { - if ( 'yes' === \get_post_meta( $this->item->ID, 'event-hide-end-time', true ) ) { - return null; - } - $end_time = \get_post_meta( $this->item->ID, 'event-date', true ); - if ( is_null( $end_time ) || empty( $end_time ) || 'no' === $end_time ) { - return null; - } - return \gmdate( 'Y-m-d\TH:i:s\Z', (int) $end_time ); - } - - /** - * Get the end time from the events metadata. - */ - public function get_start_time(): string { - $start_time = \get_post_meta( $this->item->ID, 'event-start-date', true ); - return \gmdate( 'Y-m-d\TH:i:s\Z', (int) $start_time ); - } - - /** - * Get the event link from the events metadata. - * - * @return ?array Associated array of an ActivityStreams Link object with the events URL. - */ - private function get_event_link(): ?array { - $event_link = \get_post_meta( $this->item->ID, 'event-link', true ); - $event_link_label = \get_post_meta( $this->item->ID, 'event-link-label', true ) ?? 'Event Link'; - if ( $event_link ) { - return array( - 'type' => 'Link', - 'name' => $event_link_label, - 'href' => \esc_url( $event_link ), - 'mediaType' => 'text/html', - ); - } - return null; - } - - /** - * Overrides/extends the get_attachments function to also add the event Link. - * - * @return array - */ - protected function get_attachment(): array { - $attachments = parent::get_attachment(); - if ( count( $attachments ) ) { - $attachments[0]['type'] = 'Document'; - $attachments[0]['name'] = 'Banner'; - } - $event_link = $this->get_event_link(); - if ( $event_link ) { - $attachments[] = $event_link; - } - return $attachments; - } - - /** - * Retrieves the excerpt text (may be HTML). Used for constructing the summary. - * - * @return ?string - */ - protected function retrieve_excerpt(): ?string { - if ( \get_post_meta( $this->item->ID, 'event-summary', true ) ) { - return \get_post_meta( $this->item->ID, 'event-summary', true ); - } else { - return parent::retrieve_excerpt(); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-wp-event-manager.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-wp-event-manager.php deleted file mode 100644 index eda001e5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/event/class-wp-event-manager.php +++ /dev/null @@ -1,162 +0,0 @@ -item->ID, '_event_online', true ); - $is_online = false; - // Radio buttons. - if ( 'yes' === $is_online_text ) { - $is_online = true; - } - // Checkbox. - if ( '1' === $is_online_text ) { - $is_online = true; - } - return $is_online; - } - - /** - * Get the event location. - * - * @return ?Place The Place. - */ - public function get_location(): ?Place { - $location_name = get_post_meta( $this->item->ID, '_event_location', true ); - - if ( $location_name ) { - $location = new Place(); - $location->set_name( $location_name ); - $location->set_sensitive( null ); - $location->set_address( $location_name ); - - return $location; - } - return null; - } - - /** - * Get the end time from the events metadata. - * - * @return ?string The events end-datetime if is set, null otherwise. - */ - public function get_end_time(): ?string { - $end_date = get_post_meta( $this->item->ID, '_event_end_date', true ); - if ( ! $end_date ) { - return null; - } - $timezone = new DateTimeZone( $this->get_timezone() ); - - if ( is_numeric( $end_date ) ) { - $end_date = '@' . $end_date; - } - - $end_datetime = new DateTime( $end_date, $timezone ); - - return $end_datetime->format( 'Y-m-d\TH:i:sP' ); - } - - /** - * Get timezone. - * - * @return string - */ - public function get_timezone(): string { - $time_zone = get_post_meta( $this->item->ID, '_event_timezone', true ); - if ( $time_zone ) { - return $time_zone; - } - return parent::get_timezone(); - } - - /** - * Get the end time from the events metadata. - */ - public function get_start_time(): string { - $start_date = get_post_meta( $this->item->ID, '_event_start_date', true ); - $timezone = new DateTimeZone( $this->get_timezone() ); - - if ( is_numeric( $start_date ) ) { - $start_date = '@' . $start_date; - } - - $start_datetime = new DateTime( $start_date, $timezone ); - - return $start_datetime->format( 'Y-m-d\TH:i:sP' ); - } - - /** - * Get the event link as an ActivityPub Link object, but as an associative array. - * - * @return ?array - */ - private function get_event_link_attachment(): ?array { - $event_link_url = get_post_meta( $this->item->ID, '_event_video_url', true ); - - if ( str_starts_with( $event_link_url, 'http' ) ) { - return array( - 'type' => 'Link', - 'name' => \esc_html__( 'Video URL', 'event-bridge-for-activitypub' ), - 'href' => \esc_url( $event_link_url ), - 'mediaType' => 'text/html', - ); - } else { - return null; - } - } - - /** - * Overrides/extends the get_attachments function to also add the event Link. - */ - protected function get_attachment() { - // Get attachments via parent function. - $attachments = parent::get_attachment(); - - // The first attachment is the featured image, make sure it is compatible with Mobilizon. - if ( count( $attachments ) ) { - $attachments[0]['type'] = 'Document'; - $attachments[0]['name'] = 'Banner'; - } - - if ( $this->get_event_link_attachment() ) { - $attachments[] = $this->get_event_link_attachment(); - } - return $attachments; - } - - /** - * Get the events title/name. - * - * @return string - */ - protected function get_name(): string { - return $this->item->post_title; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-base-post-place.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-base-post-place.php deleted file mode 100644 index 355af17f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-base-post-place.php +++ /dev/null @@ -1,146 +0,0 @@ -transform_object_properties( $activitypub_object ); - - if ( \is_wp_error( $activitypub_object ) ) { - return $activitypub_object; - } - - if ( ! empty( $activitypub_object->get_content() ) ) { - $activitypub_object->set_content_map( - array( - $this->get_locale() => $this->get_content(), - ) - ); - } - - $updated = \strtotime( $this->item->post_modified_gmt ); - - $activitypub_object->set_updated( \gmdate( 'Y-m-d\TH:i:s\Z', $updated ) ); - - if ( $full_object ) { - $published = \strtotime( $this->item->post_date_gmt ); - - $activitypub_object->set_published( \gmdate( 'Y-m-d\TH:i:s\Z', $published ) ); - - $activitypub_object->set_to( - array( - 'https://www.w3.org/ns/activitystreams#Public', - $this->get_actor_object()->get_followers(), - ) - ); - } - - $address = $this->get_address(); - - if ( $address ) { - $activitypub_object->set_address( $address ); - } - - // @phpstan-ignore-next-line - return $activitypub_object; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-base-term-place.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-base-term-place.php deleted file mode 100644 index 2a70b88a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-base-term-place.php +++ /dev/null @@ -1,165 +0,0 @@ -item->term_id; - } - - /** - * Get the ActivityPub ID of the term. - * - * @return string - */ - public function get_url() { - return \get_term_link( $this->item ); - } - - /** - * Returns the most unique, resolvable "ID" there currently is for a WordPress term. - * - * @return string The "ID" - */ - public function get_id() { - /** - * The first approach was to use the normal query from WordPress, but it contains the slug, which might be edited. - * - * \add_query_arg( $this->item->taxonomy, $this->item->slug, \trailingslashit( \home_url() ) ); - * - * As https://github.com/Automattic/wordpress-activitypub/pull/1272 got merged, now we can definy a real ID. - */ - return \add_query_arg( 'term_id', $this->item->term_id, \trailingslashit( \home_url() ) ); - } - - /** - * Use Term description as ActivityPub content. - * - * @return mixed|string - */ - public function get_content() { - return $this->item->description; - } - - /** - * Returns the name for the ActivityPub Item which is the title of the term. - * - * @return string|null The title or null if the object type is `note`. - */ - protected function get_name() { - if ( isset( $this->item->name ) && $this->item instanceof \WP_Term ) { - return \wp_strip_all_tags( - \html_entity_decode( - $this->item->name - ) - ); - } - - return null; - } - - /** - * Generic function that converts an WordPress location object to an ActivityPub-Place object. - * - * @return Place_Object|\WP_Error - */ - public function to_object() { - $activitypub_object = new Place_Object(); - - $activitypub_object->set_type( $this->get_type() ); - $activitypub_object->set_id( $this->get_id() ); - $activitypub_object->set_name( $this->get_name() ); - $activitypub_object->set_url( $this->get_url() ); - $activitypub_object->set_content( $this->get_content() ); - $activitypub_object->set_sensitive( $this->get_sensitive() ); - - $address = $this->get_address(); - - if ( $address ) { - $activitypub_object->set_address( $address ); - } - - return $activitypub_object; - } - - /** - * Don't set a media type on Place per default. - * - * @return null - * @phpstan-ignore-next-line - */ - public function get_media_type() { - return null; - } - - /** - * Don't set sensitive per default. - * - * @return null - */ - public function get_sensitive() { - return null; - } - - /** - * Don't support replies for Place per default. - * - * @return null - */ - public function get_replies() { - return null; - } - - /** - * Don't support tags for Place per default. - * - * @return null - * @phpstan-ignore-next-line - */ - protected function get_tag() { - return null; - } - - /** - * Don't set attrbuted to per default. - * - * @return null The attributed to. - * @phpstan-ignore-next-line - */ - protected function get_attributed_to() { - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-event-organiser.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-event-organiser.php deleted file mode 100644 index f9fa4050..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-event-organiser.php +++ /dev/null @@ -1,89 +0,0 @@ -item->ID ); - return 0.0 !== $longitude ? $longitude : null; - } - - /** - * Get the latitude. - * - * @return float|null - */ - public function get_latitude() { - $latitude = \eo_get_venue_lat( $this->item->ID ); - return 0.0 !== $latitude ? $latitude : null; - } - - /** - * Get the description of the venue as the ActivityPub content. - * - * @return string|null - */ - public function get_content() { - $description = \eo_get_venue_description( $this->item->term_id ); - - if ( empty( $description ) ) { - return null; - } - - return $description; - } - - /** - * Get the events address. - * - * @return ?array The place/venue if one is set, or null if no valid address data exists. - */ - public function get_address(): ?array { - $address = \eo_get_venue_address( $this->item->term_id ); - - // Map the values to a schema.org PostalAddress. - $postal_address = array( - 'streetAddress' => isset( $address['address'] ) ? $address['address'] : null, - 'postalCode' => isset( $address['address'] ) ? $address['postcode'] : null, - 'addressRegion' => isset( $address['address'] ) ? $address['state'] : null, - 'addressLocality' => isset( $address['address'] ) ? $address['city'] : null, - 'addressCountry' => isset( $address['address'] ) ? $address['country'] : null, - ); - - // Filter out empty values. - foreach ( $postal_address as $key => $value ) { - if ( empty( $value ) ) { - unset( $postal_address[ $key ] ); - } - } - - // If no valid address data remains, return null. - if ( empty( $postal_address ) ) { - return null; - } - - // Add the type. - $postal_address['type'] = 'PostalAddress'; - - return $postal_address; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-eventon.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-eventon.php deleted file mode 100644 index e71cc55c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-eventon.php +++ /dev/null @@ -1,197 +0,0 @@ -term_id ] ) ) { - $this->tax_meta = $evo_tax_meta['event_location'][ $item->term_id ]; - } - } - - /** - * Generic function that converts an WordPress location object to an ActivityPub-Place object. - * - * @return Place_Object|\WP_Error - */ - public function to_object() { - $object = parent::to_object(); - - if ( \is_wp_error( $object ) ) { - return $object; - } - - $object->set_longitude( $this->get_longitude() ); - $object->set_latitude( $this->get_latitude() ); - - return $object; - } - - /** - * Get the type, either Place or VirtualLocation, both is stored in the same taxonomy. - * - * @return string - */ - public function get_type(): string { - if ( $this->is_virtual_location() ) { - return 'VirtualLocation'; - } - return 'Place'; - } - - /** - * Get the longitute. - * - * @return float|null - */ - public function get_longitude(): ?float { - $longitude = null; - - if ( isset( $this->tax_meta['location_lon'] ) ) { - $longitude = $this->tax_meta['location_lon']; - } - - return $longitude ? (float) $longitude : null; - } - - /** - * Get the latitude. - * - * @return float|null - */ - public function get_latitude(): ?float { - $latitude = null; - - if ( isset( $this->tax_meta['location_lat'] ) ) { - $latitude = $this->tax_meta['location_lat']; - } - - return $latitude ? (float) $latitude : null; - } - - /** - * Get the events address. - * - * @return ?array The place/venue if one is set, or null if no valid address data exists. - */ - public function get_address(): ?array { - - if ( $this->is_virtual_location() ) { - return null; - } - - // Map the values to a schema.org PostalAddress. - $postal_address = array( - 'streetAddress' => isset( $this->tax_meta['location_address'] ) ? (string) $this->tax_meta['location_address'] : null, - 'addressRegion' => isset( $this->tax_meta['location_state'] ) ? (string) $this->tax_meta['location_state'] : null, - 'addressCountry' => isset( $this->tax_meta['location_country'] ) ? (string) $this->tax_meta['location_country'] : null, - ); - - if ( isset( $this->tax_meta['location_city'] ) ) { - $locality_and_postal_code = $this->parse_city_for_postal_code( $this->tax_meta['location_city'] ); - $postal_address['addressLocality'] = (string) $locality_and_postal_code['addressLocality']; - $postal_address['postalCode'] = (string) $locality_and_postal_code['postalCode']; - } - - // Filter out empty values. - foreach ( $postal_address as $key => $value ) { - if ( empty( $value ) ) { - unset( $postal_address[ $key ] ); - } - } - - // If no valid address data remains, return null. - if ( empty( $postal_address ) ) { - return null; - } - - // Add the type. - $postal_address = array_merge( - array( - 'type' => 'PostalAddress', - ), - $postal_address - ); - - return $postal_address; - } - - /** - * Check if this term represents a virtual location. - * - * @return bool - */ - private function is_virtual_location(): bool { - if ( isset( $this->tax_meta['location_type'] ) && 'virtual' === $this->tax_meta['location_type'] ) { - return true; - } - return false; - } - - /** - * Parse a string whether it contains a postal code and seperates both. - * - * @param string $input The input string of the locality which might contain the postal code too. - * @return array{addressLocality: string, postalCode: string} - */ - private function parse_city_for_postal_code( $input ): array { - $input = trim( $input ); - - if ( empty( $input ) ) { - return array( - 'addressLocality' => '', - 'postalCode' => '', - ); - } - - $parts = explode( ' ', $input ); - $postal_code = ''; - $locality = array(); - - foreach ( $parts as $part ) { - if ( preg_match( '/^\d{4,5}$/', $part ) ) { - // Match postal codes (assuming 4-5 digit codes). - $postal_code = $part; - } else { - // Assume everything else is part of the name of the city. - $locality[] = $part; - } - } - - return array( - 'addressLocality' => implode( ' ', $locality ), - 'postalCode' => $postal_code, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-eventprime.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-eventprime.php deleted file mode 100644 index f78964cd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-eventprime.php +++ /dev/null @@ -1,59 +0,0 @@ -ep_get_custom_page_url( 'venues_page', $this->item->term_id, 'venue', 'term' ); - - if ( \is_wp_error( $url ) ) { - return null; - } - return $url; - } - - /** - * Get the best "ID" we currently have. - * - * @return string|null - */ - public function get_id() { - return $this->get_url(); - } - - /** - * Get the event location. - * - * @return array|string|null The place/venue if one is set. - */ - public function get_address() { - $address = \get_term_meta( $this->item->term_id, 'em_address', true ); - $display_address = \get_term_meta( $this->item->term_id, 'em_display_address_on_frontend', true ); - - if ( $address && $display_address ) { - return $address; - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-events-manager.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-events-manager.php deleted file mode 100644 index 21b381e2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-events-manager.php +++ /dev/null @@ -1,95 +0,0 @@ -post_type ) { - $this->em_location = em_get_location( $post ); - } - } - - /** - * Get the name of the location. - * - * @return ?string - */ - public function get_name(): ?string { - if ( isset( $this->em_location->location_name ) ) { - return \wp_strip_all_tags( - \html_entity_decode( - $this->em_location->location_name - ) - ); - } - - return null; - } - - /** - * Get the event location. - * - * @return ?array The place/venue if one is set. - */ - public function get_address(): ?array { - $postal_address = array(); - - if ( isset( $this->em_location->location_country ) && $this->em_location->location_country ) { - $postal_address['addressCountry'] = $this->em_location->location_country; - } - - if ( isset( $this->em_location->location_town ) && $this->em_location->location_town ) { - $postal_address['addressLocality'] = $this->em_location->location_town; - } - - if ( isset( $this->em_location->location_address ) && $this->em_location->location_address ) { - $postal_address['streetAddress'] = $this->em_location->location_address; - } - - if ( isset( $this->em_location->location_state ) && $this->em_location->location_state ) { - $postal_address['addressRegion'] = $this->em_location->location_state; - } - - if ( isset( $this->em_location->location_postcode ) && $this->em_location->location_postcode ) { - $postal_address['postalCode'] = $this->em_location->location_postcode; - } - - if ( ! empty( $postal_address ) ) { - return array_merge( array( 'type' => 'PostalAddress' ), $postal_address ); - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-the-events-calendar.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-the-events-calendar.php deleted file mode 100644 index 5632bcc0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transformer/place/class-the-events-calendar.php +++ /dev/null @@ -1,63 +0,0 @@ -item->ID ); - if ( $country ) { - $postal_address['addressCountry'] = $country; - } - - $city = \tribe_get_city( $this->item->ID ); - if ( $city ) { - $postal_address['addressLocality'] = $city; - } - - $province = \tribe_get_province( $this->item->ID ); - if ( $province ) { - $postal_address['addressRegion'] = $province; - } - - $zip = \tribe_get_zip( $this->item->ID ); - if ( $zip ) { - $postal_address['postalCode'] = $zip; - } - - $address = \tribe_get_address( $this->item->ID ); - if ( $city ) { - $postal_address['streetAddress'] = $address; - } - - if ( empty( $postal_address ) ) { - return null; - } - - $postal_address = array_merge( array( 'type' => 'PostalAddress' ), $postal_address ); - - return $postal_address; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-base.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-base.php deleted file mode 100644 index 00a5c031..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-base.php +++ /dev/null @@ -1,378 +0,0 @@ -get_id(); - $event_source_activitypub_id = \get_the_guid( $event_source_post_id ); - - if ( $post_id ) { - \do_action( - 'event_bridge_for_activitypub_write_log', - array( "[ACTIVITYPUB] Processed incoming event {$event_activitypub_id} from {$event_source_activitypub_id}" ) - ); - // Use post meta to remember who we received this event from. - \update_post_meta( $post_id, '_event_bridge_for_activitypub_event_source', absint( $event_source_post_id ) ); - \update_post_meta( $post_id, 'activitypub_content_visibility', defined( 'ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL' ) ? constant( 'ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL' ) : '' ); - } else { - \do_action( - 'event_bridge_for_activitypub_write_log', - array( "[ACTIVITYPUB] Failed processing incoming event {$event_activitypub_id} from {$event_source_activitypub_id}" ) - ); - } - } - - /** - * Delete a local event in WordPress that is a cached remote one. - * - * @param string $activitypub_event_id The ActivityPub events ID. - * @return bool|WP_Post|null|WP_Error - */ - public static function delete( $activitypub_event_id ) { - $post_id = static::get_post_id_from_activitypub_id( $activitypub_event_id ); - - if ( ! $post_id ) { - \do_action( - 'event_bridge_for_activitypub_write_log', - array( "[ACTIVITYPUB] Received delete for event that is not cached locally {$activitypub_event_id}" ) - ); - return new WP_Error( - 'event_bridge_for_activitypub_remote_event_not_found', - \__( 'Remote event not found in cache', 'event-bridge-for-activitypub' ), - array( 'status' => 404 ) - ); - } - - $thumbnail_id = get_post_thumbnail_id( $post_id ); - - if ( $thumbnail_id && ! Event_Sources::is_attachment_featured_image( $thumbnail_id ) ) { - wp_delete_attachment( $thumbnail_id, true ); - } - - $result = wp_delete_post( $post_id, true ); - - if ( $result ) { - \do_action( 'event_bridge_for_activitypub_write_log', array( "[ACTIVITYPUB] Deleted cached event {$activitypub_event_id}" ) ); - } else { - \do_action( 'event_bridge_for_activitypub_write_log', array( "[ACTIVITYPUB] Failed deleting cached event {$activitypub_event_id}" ) ); - } - - return $result; - } - - /** - * Format an ActivityStreams xds:datetime to WordPress GMT format. - * - * @param string $time_string The ActivityStreams xds:datetime (may include offset). - * @return string The GMT string in format 'Y-m-d H:i:s'. - */ - protected static function format_time_string_to_wordpress_gmt( $time_string ): string { - $datetime = new \DateTime( $time_string ); - $datetime->setTimezone( new \DateTimeZone( 'GMT' ) ); - return $datetime->format( 'Y-m-d H:i:s' ); - } - - /** - * Get WordPress post by ActivityPub object ID using the guid. - * - * @param string $activitypub_id The ActivityPub object ID. - * @return int The WordPress Post ID, 0 if not post with that ActivityPub object ID (by guid) is found. - */ - protected static function get_post_id_from_activitypub_id( $activitypub_id ): int { - global $wpdb; - return (int) $wpdb->get_var( - $wpdb->prepare( - "SELECT ID FROM $wpdb->posts WHERE guid=%s", - esc_sql( $activitypub_id ), - ) - ); - } - - /** - * Get the image URL and alt-text of an ActivityPub object. - * - * @param mixed $data The ActivityPub object as ann associative array. - * @return array Array containing the images URL and alt-text. - */ - private static function extract_image_alt_and_url( $data ): array { - $image = array( - 'url' => null, - 'alt' => null, - ); - - // Check whether it is already simple. - if ( ! $data || is_string( $data ) ) { - $image['url'] = $data; - return $image; - } - - if ( ! isset( $data['type'] ) ) { - return $image; - } - - if ( ! in_array( $data['type'], array( 'Document', 'Image' ), true ) ) { - return $image; - } - - if ( isset( $data['url'] ) ) { - $image['url'] = $data['url']; - } elseif ( isset( $data['id'] ) ) { - $image['id'] = $data['id']; - } - - if ( isset( $data['name'] ) ) { - $image['alt'] = $data['name']; - } - - return $image; - } - - /** - * Returns the URL of the featured image. - * - * @param Event $event The ActivityPub event object. - * - * @return array - */ - protected static function get_featured_image( $event ): array { - // Search for the featured image in the image property. - $image = $event->get_image(); - - if ( $image ) { - return self::extract_image_alt_and_url( $image ); - } - - // Fallback attachment. - $attachment = $event->get_attachment(); - - // If attachment is an array get the first fitting one. - if ( is_array( $attachment ) && ! empty( $attachment ) ) { - $supported_types = array( 'Image', 'Document' ); - $match = null; - - foreach ( $attachment as $item ) { - if ( in_array( $item['type'], $supported_types, true ) ) { - $match = $item; - break; - } - } - - $attachment = $match; - } - - return self::extract_image_alt_and_url( $attachment ); - } - - /** - * Given an image URL return an attachment ID. Image will be side-loaded into the media library if it doesn't exist. - * - * Forked from https://gist.github.com/kingkool68/a66d2df7835a8869625282faa78b489a. - * - * @param int $post_id The post ID where the image will be set as featured image. - * @param string $url The image URL to maybe sideload. - * @uses media_sideload_image - * @return string|int|WP_Error - */ - protected static function maybe_sideload_image( $post_id, $url = '' ) { - global $wpdb; - - // Include necessary WordPress file for media handling. - if ( ! function_exists( 'media_sideload_image' ) ) { - // @phpstan-ignore-next-line - require_once ABSPATH . 'wp-admin/includes/media.php'; - // @phpstan-ignore-next-line - require_once ABSPATH . 'wp-admin/includes/file.php'; - // @phpstan-ignore-next-line - require_once ABSPATH . 'wp-admin/includes/image.php'; - } - - // Check to see if the URL has already been fetched, if so return the attachment ID. - $attachment_id = $wpdb->get_var( - $wpdb->prepare( "SELECT `post_id` FROM {$wpdb->postmeta} WHERE `meta_key` = '_source_url' AND `meta_value` = %s", $url ) - ); - if ( ! empty( $attachment_id ) ) { - return $attachment_id; - } - - $attachment_id = $wpdb->get_var( - $wpdb->prepare( "SELECT `ID` FROM {$wpdb->posts} WHERE guid=%s", $url ) - ); - if ( ! empty( $attachment_id ) ) { - return $attachment_id; - } - - // If the URL doesn't exist, sideload it to the media library. - return media_sideload_image( $url, $post_id, $url, 'id' ); - } - - /** - * Sideload an image_url set it as featured image and add the alt-text. - * - * @param int $post_id The post ID where the image will be set as featured image. - * @param string $image_url The image URL. - * @param string $alt_text The alt-text of the image. - * @return int|WP_Error The attachment ID - */ - protected static function set_featured_image_with_alt( $post_id, $image_url, $alt_text = '' ) { - // Maybe sideload the image or get the Attachment ID of an existing one. - $image_id = self::maybe_sideload_image( $post_id, $image_url ); - - if ( \is_wp_error( $image_id ) ) { - // Handle the error. - return $image_id; - } - - // Set the image as the featured image for the post. - \set_post_thumbnail( $post_id, $image_id ); - - // Update the alt text. - if ( ! empty( $alt_text ) ) { - \update_post_meta( $image_id, '_wp_attachment_image_alt', $alt_text ); - } - - return $image_id; // Return the attachment ID for further use if needed. - } - - /** - * Convert a PostalAddress to a string. - * - * @link https://schema.org/PostalAddress - * - * @param array $postal_address The PostalAddress as an associative array. - * @return string - */ - private static function postal_address_to_string( $postal_address ): string { - if ( ! isset( $postal_address['type'] ) || 'PostalAddress' !== $postal_address['type'] ) { - _doing_it_wrong( - __METHOD__, - 'The parameter postal_address must be an associate array like schema.org/PostalAddress.', - esc_html( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_VERSION ) - ); - } - - $address = array(); - $known_attributes = array( - 'streetAddress', - 'postalCode', - 'addressLocality', - 'addressState', - 'addressCountry', - ); - - foreach ( $known_attributes as $attribute ) { - if ( isset( $postal_address[ $attribute ] ) && is_string( $postal_address[ $attribute ] ) ) { - $address[] = $postal_address[ $attribute ]; - } - } - - $address_string = implode( ' ,', $address ); - - return $address_string; - } - - /** - * Convert an address to a string. - * - * @param mixed $address The address as an object, string or associative array. - * @return string - */ - protected static function address_to_string( $address ): string { - if ( is_string( $address ) ) { - return $address; - } - - if ( is_object( $address ) ) { - $address = (array) $address; - } - - if ( ! is_array( $address ) || ! isset( $address['type'] ) ) { - return ''; - } - - if ( 'PostalAddress' === $address['type'] ) { - return self::postal_address_to_string( $address ); - } - return ''; - } - - /** - * Return the number of revisions to keep. - * - * @return int The number of revisions to keep. - */ - public static function revisions_to_keep(): int { - return 5; - } - - /** - * Returns the URL of the online event link. - * - * @param Event $event The ActivityPub event object. - * - * @return ?string - */ - protected static function get_online_event_link_from_attachments( $event ): ?string { - $attachments = $event->get_attachment(); - - if ( ! is_array( $attachments ) || empty( $attachments ) ) { - return null; - } - - foreach ( $attachments as $attachment ) { - if ( array_key_exists( 'type', $attachment ) && 'Link' === $attachment['type'] && isset( $attachment['href'] ) ) { - return $attachment['href']; - } - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-gatherpress.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-gatherpress.php deleted file mode 100644 index 47aafe79..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-gatherpress.php +++ /dev/null @@ -1,207 +0,0 @@ -get_tag(); - - // Ensure the input is valid. - if ( empty( $tags_array ) || ! is_array( $tags_array ) || ! $post_id ) { - return false; - } - - // Extract and process tag names. - $tag_names = array(); - foreach ( $tags_array as $tag ) { - if ( isset( $tag['name'] ) && 'Hashtag' === $tag['type'] ) { - $tag_names[] = ltrim( $tag['name'], '#' ); // Remove the '#' from the name. - } - } - - // Add the tags as terms to the post. - if ( ! empty( $tag_names ) ) { - \wp_set_object_terms( $post_id, $tag_names, IntegrationsGatherPress::get_event_category_taxonomy(), true ); - } - - return true; - } - - /** - * Add venue. - * - * @param Event $activitypub_event The ActivityPub event object. - * @param int $post_id The post ID. - */ - private static function add_venue( $activitypub_event, $post_id ) { - $location = $activitypub_event->get_location(); - - if ( ! $location ) { - return; - } - - if ( $location instanceof Place ) { - $location = $location->to_array(); - } - - if ( ! is_array( $location ) ) { - return; - } - - if ( ! isset( $location['name'] ) ) { - return; - } - - // Fallback for Gancio instances. - if ( 'online' === $location['name'] ) { - $online_event_link = self::get_online_event_link_from_attachments( $activitypub_event ); - if ( ! $online_event_link ) { - return; - } - \update_post_meta( $post_id, 'gatherpress_online_event_link', \sanitize_url( $online_event_link ) ); - \wp_set_object_terms( $post_id, 'online-event', '_gatherpress_venue', false ); - return; - } - - $venue_instance = \GatherPress\Core\Venue::get_instance(); - $venue_name = \sanitize_title( $location['name'] ); - $venue_slug = $venue_instance->get_venue_term_slug( $venue_name ); - $venue_post = $venue_instance->get_venue_post_from_term_slug( $venue_slug ); - - if ( ! $venue_post ) { - $venue_id = \wp_insert_post( - array( - 'post_title' => sanitize_text_field( $location['name'] ), - 'post_type' => 'gatherpress_venue', - 'post_status' => 'publish', - ) - ); - } else { - $venue_id = $venue_post->ID; - } - - $venue_information = array(); - - $address_string = isset( $location['address'] ) ? self::address_to_string( $location['address'] ) : ''; - - $venue_information['fullAddress'] = $address_string; - $venue_information['phone_number'] = ''; - $venue_information['website'] = ''; - $venue_information['permalink'] = ''; - - $venue_json = \wp_json_encode( $venue_information ); - - \update_post_meta( $venue_id, 'gatherpress_venue_information', $venue_json ); - - \wp_set_object_terms( $post_id, $venue_slug, '_gatherpress_venue', false ); - } - - /** - * Save the ActivityPub event object as GatherPress Event. - * - * @param Event $activitypub_event The ActivityPub event object. - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * - * @return false|int - */ - protected static function save_event( $activitypub_event, $event_source_post_id ) { - // Limit this as a safety measure. - \add_filter( 'wp_revisions_to_keep', array( self::class, 'revisions_to_keep' ) ); - - $post_id = self::get_post_id_from_activitypub_id( $activitypub_event->get_id() ); - - $args = array( - 'post_title' => sanitize_text_field( $activitypub_event->get_name() ), - 'post_type' => 'gatherpress_event', - 'post_content' => wp_kses_post( $activitypub_event->get_content() ?? '' ) . '', - 'post_excerpt' => wp_kses_post( $activitypub_event->get_summary() ?? '' ), - 'post_status' => 'publish', - 'guid' => sanitize_url( $activitypub_event->get_id() ), - ); - - if ( $activitypub_event->get_published() ) { - $post_date = self::format_time_string_to_wordpress_gmt( $activitypub_event->get_published() ); - $args['post_date'] = $post_date; - $args['post_date_gmt'] = $post_date; - } - - if ( $post_id ) { - // Update existing GatherPress event post. - $args['ID'] = $post_id; - \wp_update_post( $args ); - } else { - // Insert new GatherPress event post. - $post_id = \wp_insert_post( $args ); - } - - // @phpstan-ignore-next-line - if ( ! $post_id || \is_wp_error( $post_id ) ) { - return false; - } - - // Insert the dates. - $gatherpress_event = new GatherPress_Event( $post_id ); - $start_time = $activitypub_event->get_start_time(); - $end_time = $activitypub_event->get_end_time(); - if ( ! $end_time ) { - $end_time = new DateTime( $start_time ); - $end_time->modify( '+1 hour' ); - $end_time = $end_time->format( 'Y-m-d H:i:s' ); - } - $params = array( - 'datetime_start' => $start_time, - 'datetime_end' => $end_time, - 'timezone' => $activitypub_event->get_timezone(), - ); - // Sanitization of the params is done in the save_datetimes function just in time. - $gatherpress_event->save_datetimes( $params ); - - // Insert featured image. - $image = self::get_featured_image( $activitypub_event ); - self::set_featured_image_with_alt( $post_id, $image['url'], $image['alt'] ); - - // Add hashtags. - self::add_tags_to_post( $activitypub_event, $post_id ); - - // Add venue. - self::add_venue( $activitypub_event, $post_id ); - - // Limit this as a safety measure. - \remove_filter( 'wp_revisions_to_keep', array( self::class, 'revisions_to_keep' ) ); - - return $post_id; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-the-events-calendar.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-the-events-calendar.php deleted file mode 100644 index d36f448b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-the-events-calendar.php +++ /dev/null @@ -1,371 +0,0 @@ -get_id() ); - $duration = self::get_duration( $activitypub_event ); - $venue_id = self::add_venue( $activitypub_event, $event_source_post_id ); - $organizer_id = self::add_organizer( $activitypub_event ); - - $args = array( - 'title' => $activitypub_event->get_name(), - 'content' => $activitypub_event->get_content() ?? '', - 'start_date' => gmdate( 'Y-m-d H:i:s', strtotime( $activitypub_event->get_start_time() ) ), - 'duration' => $duration, - 'status' => 'publish', - 'guid' => $activitypub_event->get_id(), - ); - - if ( $venue_id ) { - $args['venue'] = $venue_id; - $args['VenueID'] = $venue_id; - } - - if ( $organizer_id ) { - $args['organizer'] = $organizer_id; - $args['OrganizerID'] = $organizer_id; - } - - if ( $activitypub_event->get_published() ) { - $post_date = self::format_time_string_to_wordpress_gmt( $activitypub_event->get_published() ); - $args['post_date'] = $post_date; - $args['post_date_gmt'] = $post_date; - } - - $tribe_event = new The_Events_Calendar_Event_Repository(); - - if ( $post_id ) { - $post = $tribe_event->where( 'id', $post_id )->set_args( $args )->save(); - } else { - $post = $tribe_event->set_args( $args )->create(); - } - - if ( $post instanceof \WP_Post ) { - $post_id = $post->ID; - } - - if ( ! $post_id ) { - return false; - } - - // Insert featured image. - $image = self::get_featured_image( $activitypub_event ); - if ( isset( $image['url'] ) ) { - self::set_featured_image_with_alt( $post_id, $image['url'], $image['alt'] ); - } - - // Add tags. - self::add_tags_to_post( $activitypub_event, $post_id ); - - // Remove revision limit. - remove_filter( 'wp_revisions_to_keep', array( self::class, 'revisions_to_keep' ) ); - - return $post_id; - } - - /** - * Map an ActivityStreams Place to the Events Calendar venue. - * - * @param array|Place $location An ActivityPub location as an associative array or Place object. - * @link https://www.w3.org/TR/activitystreams-vocabulary/#dfn-place - * @return array - */ - private static function get_venue_args( $location ): array { - $args = array( - 'venue' => $location['name'], - 'status' => 'publish', - ); - - if ( $location instanceof Place ) { - $location = $location->to_array(); - } - - if ( ! isset( $location['address'] ) ) { - return $args; - } - - if ( is_array( $location['address'] ) ) { - $mapping = array( - 'streetAddress' => 'address', - 'postalCode' => 'zip', - 'addressLocality' => 'city', - 'addressState' => 'state', - 'addressCountry' => 'country', - 'url' => 'website', - ); - - foreach ( $mapping as $postal_address_key => $venue_key ) { - if ( isset( $location['address'][ $postal_address_key ] ) ) { - $args[ $venue_key ] = $location['address'][ $postal_address_key ]; - } - } - } elseif ( is_string( $location['address'] ) ) { - // Use the address field for a solely text address. - $args['address'] = $location['address']; - } - - if ( isset( $location['id'] ) ) { - $args['guid'] = $location['id']; - } - - return $args; - } - - /** - * Add venue. - * - * @param Event $activitypub_event The ActivityPub event object. - * @param int $event_source_post_id The WordPress Post ID of the event source. - * - * @return ?int $post_id The venues post ID. - */ - private static function add_venue( $activitypub_event, $event_source_post_id ): ?int { - $location = $activitypub_event->get_location(); - - // Make sure we have a valid location in the right format. - if ( ! $location ) { - return null; - } - - if ( $location instanceof Place ) { - $location = $location->to_array(); - } - - if ( ! is_array( $location ) ) { - return null; - } - - if ( ! isset( $location['name'] ) ) { - return null; - } - - // Fallback for Gancio instances. - if ( 'online' === $location['name'] ) { - return null; - } - - $tribe_venue = new The_Events_Calendar_Venue_Repository(); - - // If the venue already exists try to find it's post id. - $post_id = null; - - // Search if we already got this venue/place in our database. - if ( isset( $location['id'] ) ) { - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $post_id = $wpdb->get_var( - $wpdb->prepare( - "SELECT ID FROM $wpdb->posts WHERE guid=%s AND post_type=%s", - $location['id'], - \Tribe__Events__Venue::POSTTYPE - ) - ); - if ( $post_id ) { - $post_id = (int) $post_id; - } - } - - if ( ! $post_id ) { - // Try to find a match by searching. - $results = $tribe_venue->search( $location['name'] )->all(); - - foreach ( $results as $potential_matching_post_id ) { - // @phpstan-ignore-next-line - if ( $potential_matching_post_id instanceof \WP_Post ) { - $potential_matching_post_id = $potential_matching_post_id->ID; - } - // Only accept a match for the venue/location if it was received by the same actor. - if ( \get_post_meta( $potential_matching_post_id, '_event_bridge_for_activitypub_event_source', true ) === $event_source_post_id ) { - $post_id = $potential_matching_post_id; - break; - } - } - } - - if ( $post_id ) { - // Update if we found a match. - $result = $tribe_venue->where( 'id', $post_id )->set_args( self::get_venue_args( $location ) )->save(); - if ( array_key_exists( $post_id, $result ) && $result[ $post_id ] ) { - return $post_id; - } - } else { - // Create a new venue. - $post = $tribe_venue->set_args( self::get_venue_args( $location ) )->create(); - if ( $post ) { - $post_id = $post->ID; - update_post_meta( $post_id, '_event_bridge_for_activitypub_event_source', $event_source_post_id ); - } - } - - return $post_id; - } - - /** - * Add organizer. - * - * @param Event $activitypub_event The ActivityPub event object. - * - * @return int|bool $post_id The organizers post ID. - */ - private static function add_organizer( $activitypub_event ) { - // This might likely change, because of FEP-8a8e. - $actor = $activitypub_event->get_attributed_to(); - - if ( is_null( $actor ) ) { - return false; - } - - $actor_id = object_to_uri( $actor ); - $event_source = Event_Source::get_by_id( $actor_id ); - - // As long as we do not support announces, we expect the attributedTo to be an existing event source. - if ( ! $event_source ) { - return false; - } - - // Prepare arguments for inserting/updating the organizer post. - $args = array( - 'organizer' => $event_source->get_name(), - 'description' => $event_source->get_summary(), - 'website' => $event_source->get_url(), - 'excerpt' => $event_source->get_summary(), - 'post_parent' => $event_source->get__id(), // Maybe just use post meta too here. - ); - - if ( $event_source->get_published() ) { - $post_date = self::format_time_string_to_wordpress_gmt( $event_source->get_published() ); - $args['post_date'] = $post_date; - $args['post_date_gmt'] = $post_date; - } - - // Get organizer if it is already present. - $children = \get_children( - array( - 'post_parent' => $event_source->get__id(), - 'post_type' => \Tribe__Events__Organizer::POSTTYPE, - ), - ); - - if ( count( $children ) ) { - // Update organizer post. - $child = array_pop( $children ); - $tribe_organizer_post_ids = \tribe_organizers()->where( 'id', $child->ID )->set_args( $args )->save(); - - // Fallback to delete duplicates. - foreach ( $children as $to_delete ) { - \wp_delete_post( $to_delete->ID, true ); - } - - // If updating failed return. - if ( 1 !== count( $tribe_organizer_post_ids ) || ! reset( $tribe_organizer_post_ids ) ) { - return false; - } - - $tribe_organizer_post_id = array_key_first( $tribe_organizer_post_ids ); - } else { - // Create new organizer post. - $tribe_organizer_post = \tribe_organizers()->set_args( $args )->create(); - - if ( ! $tribe_organizer_post ) { - return false; - } - - $tribe_organizer_post_id = $tribe_organizer_post->ID; - - // Make a relationship between the event source WP_Post and the organizer WP_Post. - \update_post_meta( $tribe_organizer_post_id, '_event_bridge_for_activitypub_event_source', true ); - } - - // Add the thumbnail of the event source to the organizer. - if ( \get_post_thumbnail_id( $event_source->get__id() ) ) { - \set_post_thumbnail( $tribe_organizer_post_id, \get_post_thumbnail_id( $event_source->get__id() ) ); - } - - return $tribe_organizer_post_id; - } - - /** - * Add tags to post. - * - * @param Event $activitypub_event The ActivityPub event object. - * @param int $post_id The post ID. - */ - private static function add_tags_to_post( $activitypub_event, $post_id ): bool { - $tags_array = $activitypub_event->get_tag(); - - // Ensure the input is valid. - if ( empty( $tags_array ) || ! is_array( $tags_array ) || ! $post_id ) { - return false; - } - - // Extract and process tag names. - $tag_names = array(); - foreach ( $tags_array as $tag ) { - if ( isset( $tag['name'] ) && 'Hashtag' === $tag['type'] ) { - $tag_names[] = ltrim( $tag['name'], '#' ); // Remove the '#' from the name. - } - } - - // Add the tags as terms to the post. - if ( ! empty( $tag_names ) ) { - \wp_set_object_terms( $post_id, $tag_names, 'post_tag', true ); - } - - return true; - } - - /** - * Get the events duration in seconds. - * - * @param Event $activitypub_event The ActivityPub event object. - * - * @return int - */ - private static function get_duration( $activitypub_event ): int { - $end_time = $activitypub_event->get_end_time(); - if ( ! $end_time ) { - return 2 * HOUR_IN_SECONDS; - } - return abs( strtotime( $end_time ) - strtotime( $activitypub_event->get_start_time() ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-vs-event-list.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-vs-event-list.php deleted file mode 100644 index bb738b37..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/class-vs-event-list.php +++ /dev/null @@ -1,175 +0,0 @@ -to_array(); - } - - // Return empty string when location is not an associative array. - if ( ! is_array( $location ) || 0 === count( $location ) ) { - return $location_string; - } - - if ( ! isset( $location['type'] ) || 'Place' !== $location['type'] ) { - return $location_string; - } - - // Add name of the location. - if ( isset( $location['name'] ) ) { - $location_string .= $location['name']; - } - - // Add delimiter between name and address if both are set. - if ( isset( $location['name'] ) && isset( $location['address'] ) ) { - $location_string .= ' – '; - } - - // Add address. - if ( isset( $location['address'] ) ) { - $location_string .= self::address_to_string( $location['address'] ); - } - return $location_string; - } - - /** - * Add tags to post. - * - * @param Event $activitypub_event The ActivityPub event object. - * @param int $post_id The post ID. - */ - private static function add_tags_to_post( $activitypub_event, $post_id ) { - $tags_array = $activitypub_event->get_tag(); - - // Ensure the input is valid. - if ( empty( $tags_array ) || ! is_array( $tags_array ) || ! $post_id ) { - return false; - } - - // Extract and process tag names. - $tag_names = array(); - foreach ( $tags_array as $tag ) { - if ( isset( $tag['name'] ) && 'Hashtag' === $tag['type'] ) { - $tag_names[] = ltrim( $tag['name'], '#' ); // Remove the '#' from the name. - } - } - - // Add the tags as terms to the post. - if ( ! empty( $tag_names ) ) { - \wp_set_object_terms( $post_id, $tag_names, IntegrationsVS_Event_List::get_event_category_taxonomy(), true ); - } - - return true; - } - - /** - * Save the ActivityPub event object as VS Event List event. - * - * @param Event $activitypub_event The ActivityPub event object. - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * - * @return false|int - */ - protected static function save_event( $activitypub_event, $event_source_post_id ) { - // Limit this as a safety measure. - \add_filter( 'wp_revisions_to_keep', array( self::class, 'revisions_to_keep' ) ); - - $post_id = self::get_post_id_from_activitypub_id( $activitypub_event->get_id() ); - - $args = array( - 'post_title' => $activitypub_event->get_name(), - 'post_type' => \Event_Bridge_For_ActivityPub\Integrations\VS_Event_List::get_post_type(), - 'post_content' => $activitypub_event->get_content() ?? '', - 'post_excerpt' => $activitypub_event->get_summary() ?? '', - 'post_status' => 'publish', - 'guid' => $activitypub_event->get_id(), - 'meta_input' => array( - 'event-start-date' => \strtotime( $activitypub_event->get_start_time() ), - 'event-link' => $activitypub_event->get_url() ?? $activitypub_event->get_id(), - 'event-link-label' => \sanitize_text_field( __( 'Original Website', 'event-bridge-for-activitypub' ) ), - 'event-link-target' => 'yes', // Open in new window. - 'event-link-title' => 'no', // Whether to redirect event title to original source. - 'event-link-image' => 'no', // Whether to redirect events featured image to original source. - ), - ); - - if ( $activitypub_event->get_published() ) { - $post_date = self::format_time_string_to_wordpress_gmt( $activitypub_event->get_published() ); - $args['post_date'] = $post_date; - $args['post_date_gmt'] = $post_date; - } - - // Add end time. - $end_time = $activitypub_event->get_end_time(); - if ( $end_time ) { - $args['meta_input']['event-date'] = \strtotime( $end_time ); - } - - // Maybe add location. - $location = self::get_location_as_string( $activitypub_event->get_location() ); - if ( $location ) { - $args['meta_input']['event-location'] = $location; - } - - if ( $post_id ) { - // Update existing event post. - $args['ID'] = $post_id; - $post_id = \wp_update_post( $args ); - } else { - // Insert new event post. - $post_id = \wp_insert_post( $args ); - } - - // @phpstan-ignore-next-line - if ( 0 === $post_id || \is_wp_error( $post_id ) ) { - return false; - } - - // Insert featured image. - $image = self::get_featured_image( $activitypub_event ); - self::set_featured_image_with_alt( $post_id, $image['url'], $image['alt'] ); - - // Add hashtags. - self::add_tags_to_post( $activitypub_event, $post_id ); - - // Limit this as a safety measure. - \remove_filter( 'wp_revisions_to_keep', array( self::class, 'revisions_to_keep' ) ); - - return $post_id; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/helper/class-sanitizer.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/helper/class-sanitizer.php deleted file mode 100644 index aae19039..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/helper/class-sanitizer.php +++ /dev/null @@ -1,241 +0,0 @@ - 404 ) ); - } - - $event = new Event(); - - // Straightforward sanitization of all attributes we possible make use of. - if ( isset( $data['content'] ) ) { - $event->set_content( \wp_kses_post( $data['content'] ) ); - } - - if ( isset( $data['summary'] ) ) { - $event->set_summary( \wp_kses_post( $data['summary'] ) ); - } - - if ( isset( $data['name'] ) ) { - $event->set_name( \sanitize_text_field( $data['name'] ) ); - } - - if ( isset( $data['startTime'] ) ) { - $event->set_start_time( \sanitize_text_field( $data['startTime'] ) ); - } - - if ( isset( $data['endTime'] ) ) { - $event->set_end_time( \sanitize_text_field( $data['endTime'] ) ); - } - - if ( isset( $data['published'] ) ) { - $event->set_published( \sanitize_text_field( $data['published'] ) ); - } - - if ( isset( $data['id'] ) ) { - $event->set_id( \sanitize_url( $data['id'] ) ); - } - - if ( isset( $data['url'] ) ) { - $event->set_url( \sanitize_url( $data['url'] ) ); - } - - if ( isset( $data['attributedTo'] ) ) { - $event->set_attributed_to( self::sanitize_attributed_to( $data['attributedTo'] ) ); - } - - if ( isset( $data['location'] ) ) { - $event->set_location( self::sanitize_place_object_from_array( $data['location'] ) ); - } - - if ( isset( $data['attachment'] ) ) { - $event->set_attachment( self::sanitize_attachment( $data['attachment'] ) ); - } - - if ( isset( $data['tag'] ) ) { - $event->set_tag( self::sanitize_attachment( $data['tag'] ) ); - } - - return $event; - } - - /** - * Sanitize attributedTo. - * - * Currently only multiple attributedTo's are not supported. - * - * @param mixed $data The object array. - * - * @return string - */ - private static function sanitize_attributed_to( $data ): string { - if ( is_array( $data ) && self::array_is_list( $data ) ) { - $data = reset( $data ); - } - - return object_to_uri( $data ); - } - - /** - * Sanitize attachments. - * - * @param mixed $data The object array. - * - * @return ?array - */ - private static function sanitize_attachment( $data ): ?array { - if ( ! is_array( $data ) ) { - return null; - } - - if ( ! self::array_is_list( $data ) ) { - $data = array( $data ); - } - - $attachment = array(); - - foreach ( $data as $item ) { - $sanitized_item = array(); - - // Straightforward sanitization of all attributes we possible make use of. - if ( isset( $item['name'] ) ) { - $sanitized_item['name'] = \sanitize_text_field( $item['name'] ); - } - if ( isset( $item['url'] ) ) { - $sanitized_item['url'] = \sanitize_url( $item['url'] ); - } - if ( isset( $item['id'] ) ) { - $sanitized_item['id'] = \sanitize_url( $item['id'] ); - } - if ( isset( $item['type'] ) ) { - $sanitized_item['type'] = \sanitize_text_field( $item['type'] ); - } - if ( isset( $item['href'] ) ) { - $sanitized_item['href'] = \sanitize_text_field( $item['href'] ); - } - - if ( isset( $sanitized_item['url'] ) || isset( $sanitized_item['href'] ) || isset( $sanitized_item['name'] ) ) { - $attachment[] = $sanitized_item; - } - } - - return $attachment; - } - - /** - * Fallback for PHP version prior to 8.1 for array_is_list. - * - * @param array $arr The array to check. - * @return bool - */ - private static function array_is_list( $arr ) { - if ( ! function_exists( 'array_is_list' ) ) { - if ( array() === $arr ) { - return true; - } - return array_keys( $arr ) === range( 0, count( $arr ) - 1 ); - } - return array_is_list( $arr ); - } - - /** - * Convert input array to an Location. - * - * @param mixed $data The object array. - * - * @return ?Place An Object built from the input array or null. - */ - private static function sanitize_place_object_from_array( $data ): ?Place { - if ( ! is_array( $data ) ) { - return null; - } - - // If the array is a list, work with the first item. - if ( array_key_exists( 0, $data ) ) { - $data = $data[0]; - } - - $place = new Place(); - - if ( isset( $data['name'] ) ) { - $place->set_name( \sanitize_text_field( $data['name'] ) ); - } - - if ( isset( $data['id'] ) ) { - $place->set_id( \sanitize_url( $data['id'] ) ); - } - - if ( isset( $data['url'] ) ) { - $place->set_url( \sanitize_url( $data['url'] ) ); - } - - if ( isset( $data['address'] ) ) { - if ( is_string( $data['address'] ) ) { - $place->set_address( \sanitize_text_field( $data['address'] ) ); - } - if ( is_array( $data['address'] ) && isset( $data['address']['type'] ) && 'PostalAddress' === $data['address']['type'] ) { - $address = array(); - if ( isset( $data['address']['streetAddress'] ) ) { - $address['streetAddress'] = \sanitize_text_field( $data['address']['streetAddress'] ); - } - if ( isset( $data['address']['postalCode'] ) ) { - $address['postalCode'] = \sanitize_text_field( $data['address']['postalCode'] ); - } - if ( isset( $data['address']['addressLocality'] ) ) { - $address['addressLocality'] = \sanitize_text_field( $data['address']['addressLocality'] ); - } - if ( isset( $data['address']['addressState'] ) ) { - $address['addressState'] = \sanitize_text_field( $data['address']['addressState'] ); - } - if ( isset( $data['address']['addressCountry'] ) ) { - $address['addressCountry'] = \sanitize_text_field( $data['address']['addressCountry'] ); - } - if ( isset( $data['address']['url'] ) ) { - $address['url'] = \sanitize_url( $data['address']['url'] ); - } - $place->set_address( $address ); - } - } - - return $place; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/helper/class-the-events-calendar-event-repository.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/helper/class-the-events-calendar-event-repository.php deleted file mode 100644 index a4f1f846..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/activitypub/transmogrifier/helper/class-the-events-calendar-event-repository.php +++ /dev/null @@ -1,43 +0,0 @@ -event_plugin = $event_plugin; - if ( $this->event_post_type_is_not_activitypub_enabled() ) { - add_action( 'admin_notices', array( $this, 'admin_notice_activitypub_not_enabled_for_post_type' ), 10, 1 ); - } - } - - /** - * Check if ActivityPub is enabled for the custom post type of the event plugin. - * - * @return bool - */ - private function event_post_type_is_not_activitypub_enabled(): bool { - return ! in_array( $this->event_plugin::get_post_type(), get_option( 'activitypub_support_post_types', array() ), true ); - } - - /** - * Display the admin notices for the plugins. - * - * @return void - */ - public function admin_notice_activitypub_not_enabled_for_post_type(): void { - if ( $this->event_plugin::is_plugin_page() ) { - $this->do_admin_notice_post_type_not_activitypub_enabled(); - } - } - - /** - * Print admin notice that the current post type is not enabled in the ActivityPub plugin. - * - * @return void - */ - private function do_admin_notice_post_type_not_activitypub_enabled(): void { - $all_plugins = get_plugins(); - $event_plugin_file = $this->event_plugin::get_relative_plugin_file(); - if ( isset( $all_plugins[ $event_plugin_file ]['Name'] ) ) { - $event_plugin_name = $all_plugins[ $event_plugin_file ]['Name']; - } elseif ( isset( get_mu_plugins()[ $event_plugin_file ]['Name'] ) ) { - $event_plugin_name = get_mu_plugins()[ $event_plugin_file ]['Name']; - } else { - return; - } - $activitypub_plugin_data = get_plugin_data( ACTIVITYPUB_PLUGIN_FILE ); - $notice = sprintf( - /* translators: 1: the name of the event plugin a admin notice is shown. 2: The name of the ActivityPub plugin. */ - _x( - 'You have installed the %1$s plugin, but the event post type of the plugin %2$s is not enabled in the %1$s settings.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_html( $activitypub_plugin_data['Name'] ), - esc_html( $event_plugin_name ), - admin_url( 'options-general.php?page=activitypub&tab=settings' ) - ); - $allowed_html = array( - 'a' => array( - 'href' => true, - 'title' => true, - ), - 'b' => array(), - 'i' => array(), - ); - echo '

    ' . \wp_kses( $notice, $allowed_html ) . '

    '; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-general-admin-notices.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-general-admin-notices.php deleted file mode 100644 index 6a5302f0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-general-admin-notices.php +++ /dev/null @@ -1,152 +0,0 @@ - array( - 'href' => true, - 'title' => true, - 'target' => true, - ), - 'br', - 'i', - ); - - /** - * Admin notice when the ActivityPub plugin is not enabled. - * - * @return string - */ - public static function get_admin_notice_activitypub_plugin_not_enabled(): string { - return sprintf( - /* translators: 1: An URL that points to the ActivityPub plugin. */ - _x( - 'For the Event Bridge for ActivityPub to work, you will need to install and activate the ActivityPub plugin.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_html( self::ACTIVITYPUB_PLUGIN_URL ) - ); - } - - /** - * Admin notice when the ActivityPub plugin version is too old. - * - * @return string - */ - public static function get_admin_notice_activitypub_plugin_version_too_old(): string { - return sprintf( - /* translators: 1: The name of the ActivityPub plugin. 2: The minimum required version number of the ActivityPub plugin. */ - _x( - 'Please upgrade your ActivityPub plugin. At least version %2$s is required for the Event Bridge for ActivityPub to work.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_html( self::ACTIVITYPUB_PLUGIN_URL ), - esc_html( EVENT_BRIDGE_FOR_ACTIVITYPUB_ACTIVITYPUB_PLUGIN_MIN_VERSION ) - ); - } - - /** - * Warning that no supported event plugin can be found. - * - * @return string - */ - public static function get_admin_notice_no_supported_event_plugin_active(): string { - return sprintf( - /* translators: 1: An URL to the list of supported event plugins. */ - _x( - 'The Plugin Event Bridge for ActivityPub is of no use, because you do not have installed and activated a supported Event Plugin. -
    For a list of supported Event Plugins see here.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_url( self::EVENT_BRIDGE_FOR_ACTIVITYPUB_SUPPORTED_EVENT_PLUGINS_URL ) - ); - } - - /** - * Warning to fix status issues first. - * - * @return string - */ - public static function get_admin_notice_status_not_ok(): string { - return sprintf( - /* translators: 1: An URL to the list of supported event plugins. */ - _x( - 'The Plugin Event Bridge for ActivityPub is of no use, because you do not have installed and activated a supported Event Plugin. -
    For a list of supported Event Plugins see here.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_html( self::EVENT_BRIDGE_FOR_ACTIVITYPUB_SUPPORTED_EVENT_PLUGINS_URL ) - ); - } - - /** - * Warning if the plugin is Active and the ActivityPub plugin is not. - * - * @return void - */ - public static function activitypub_plugin_not_enabled(): void { - $notice = self::get_admin_notice_activitypub_plugin_not_enabled(); - // @phpstan-ignore-next-line - echo '

    ' . \wp_kses( $notice, self::ALLOWED_HTML ) . '

    '; - } - - /** - * Warning if the plugin is Active and the ActivityPub plugins version is too old. - * - * @return void - */ - public static function activitypub_plugin_version_too_old(): void { - $notice = self::get_admin_notice_activitypub_plugin_version_too_old(); - // @phpstan-ignore-next-line - echo '

    ' . \wp_kses( $notice, self::ALLOWED_HTML ) . '

    '; - } - - /** - * Warning when no supported Even Plugin is installed and active. - * - * @return void - */ - public static function no_supported_event_plugin_active(): void { - $notice = self::get_admin_notice_no_supported_event_plugin_active(); - // @phpstan-ignore-next-line - echo '

    ' . \wp_kses( $notice, self::ALLOWED_HTML ) . '

    '; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-health-check.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-health-check.php deleted file mode 100644 index ecf4652d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-health-check.php +++ /dev/null @@ -1,211 +0,0 @@ - __( 'ActivityPub Event Transformer Test', 'event-bridge-for-activitypub' ), - 'test' => array( self::class, 'test_event_transformation' ), - ); - - return $tests; - } - - /** - * The the transformation of the most recent event posts. - * - * @return array - */ - public static function test_event_transformation(): array { - $result = array( - 'label' => \__( 'Transformation of Events to a valid ActivityStreams representation.', 'event-bridge-for-activitypub' ), - 'status' => 'good', - 'badge' => array( - 'label' => \__( 'Event Bridge for ActivityPub', 'event-bridge-for-activitypub' ), - 'color' => 'green', - ), - 'description' => \sprintf( - '

    %s

    ', - \__( 'The transformation to ActivityPub of your most recent events was successful.', 'event-bridge-for-activitypub' ) - ), - 'actions' => '', - 'test' => 'test_event_transformation', - ); - - $check = self::transform_most_recent_event_posts(); - - if ( true === $check ) { - return $result; - } - - $result['status'] = 'critical'; - $result['label'] = \__( 'One or more of your most recent events failed to transform to ActivityPub', 'event-bridge-for-activitypub' ); - $result['badge']['color'] = 'red'; - $result['description'] = \sprintf( - '

    %s

    ', - \__( 'The transformation to ActivityPub of your most recent events was not successful.', 'event-bridge-for-activitypub' ) - ); - - return $result; - } - - /** - * Test if right transformer gets applied. - * - * @param Event_Plugin_Integration $event_plugin The event plugin definition. - * - * @return bool True if the check passed. - */ - public static function test_if_event_transformer_is_used( $event_plugin ): bool { - if ( ! Setup::get_instance()->is_activitypub_plugin_active() ) { - return false; - } - - // Get a (random) event post. - $event_posts = self::get_most_recent_event_posts( $event_plugin->get_post_type(), 1 ); - - // If no post is found, we can not do this test. - if ( isset( $event_posts[0] ) || empty( $event_posts ) ) { - return true; - } - - // Call the transformer Factory. - $transformer = Transformer_Factory::get_transformer( \get_post( $event_posts[0] ) ); - // Check that we got the right transformer. - $desired_transformer_class = $event_plugin::get_activitypub_event_transformer( $event_posts[0] ); - if ( $transformer instanceof $desired_transformer_class ) { - return true; - } - return false; - } - - /** - * Retrieves the most recently published event posts of a certain event post type. - * - * @param ?string $event_post_type The post type of the events. - * @param ?int $number_of_posts The maximum number of events to return. - * - * @return \WP_Post[] Array of event posts, or false if none are found. - */ - public static function get_most_recent_event_posts( $event_post_type = null, $number_of_posts = 5 ): array { - if ( ! Setup::get_instance()->is_activitypub_plugin_active() ) { - return array(); - } - - if ( ! $event_post_type ) { - $active_event_plugins = Setup::get_instance()->get_active_event_plugins(); - $active_event_plugin = reset( $active_event_plugins ); - if ( ! $active_event_plugin ) { - return array(); - } - $event_post_type = $active_event_plugin->get_post_type(); - } - - $args = array( - 'numberposts' => $number_of_posts, - 'category' => 0, - 'orderby' => 'date', - 'order' => 'DESC', - 'include' => array(), - 'exclude' => array(), - 'meta_query' => array( - 'relation' => 'OR', - array( - 'key' => '_event_bridge_for_activitypub_event_source', - 'compare' => 'NOT EXISTS', - ), - array( - 'key' => '_event_bridge_for_activitypub_event_source', - 'value' => '', - 'compare' => '=', - ), - ), - 'post_type' => $event_post_type, - 'suppress_filters' => true, - ); - - $query = new WP_Query(); - return $query->query( $args ); - } - - /** - * Transform the most recent event posts. - */ - public static function transform_most_recent_event_posts(): bool { - return true; - } - - /** - * Retrieves information like name and version from active event plugins. - */ - private static function get_info_about_active_event_plugins(): array { - $active_event_plugins = Setup::get_instance()->get_active_event_plugins(); - $info = array(); - foreach ( $active_event_plugins as $active_event_plugin ) { - $event_plugin_file = $active_event_plugin->get_relative_plugin_file(); - $event_plugin_data = \get_plugin_data( $event_plugin_file ); - - $info[] = array( - 'event_plugin_name' => $event_plugin_data['Name'], - 'event_plugin_version' => $event_plugin_data['Version'], - 'event_plugin_file' => $event_plugin_file, - ); - } - return $info; - } - - /** - * Static function for generating site debug data when required. - * - * @param array $info The debug information to be added to the core information page. - * @return array The extended information. - */ - public static function add_debug_information( $info ): array { - $info['event_bridge_for_activitypub'] = array( - 'label' => __( 'Event Bridge for ActivityPub', 'event-bridge-for-activitypub' ), - 'fields' => array( - 'plugin_version' => array( - 'label' => __( 'Plugin Version', 'event-bridge-for-activitypub' ), - 'value' => EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_VERSION, - 'private' => true, - ), - 'active_event_plugins' => self::get_info_about_active_event_plugins(), - ), - ); - - return $info; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-settings-page.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-settings-page.php deleted file mode 100644 index 0b58c39b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-settings-page.php +++ /dev/null @@ -1,280 +0,0 @@ - __( 'Event Bridge', 'event-bridge-for-activitypub' ), - 'template' => EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . 'templates/settings/tab.php', - ); - - return $tabs; - } - - /** - * Checks whether the current request wants to add an event source (ActivityPub follow) and passed on to actual handler. - * - * @return void - */ - public static function maybe_add_event_source() { - if ( ! isset( $_POST['event_bridge_for_activitypub_add_event_source'] ) ) { - return; - } - - // Check and verify request and check capabilities. - if ( ! \wp_verify_nonce( sanitize_key( $_REQUEST['_wpnonce'] ), 'event-bridge-for-activitypub_add-event-source-options' ) ) { - return; - } - - if ( ! \current_user_can( 'manage_options' ) ) { - return; - } - - $event_source = \sanitize_text_field( $_POST['event_bridge_for_activitypub_add_event_source'] ); - - $actor_url = false; - $url = \wp_parse_url( $event_source ); - - $error_message = \esc_html__( 'Failed to add Event Source', 'event-bridge-for-activitypub' ); - - // Check if URL is a Collection or a single Actor. - $maybe_collection = \wp_safe_remote_get( $event_source ); - - if ( ! \is_wp_error( $maybe_collection ) ) { - $maybe_collection = \json_decode( \wp_remote_retrieve_body( $maybe_collection ), true ); - } - - $event_sources = array(); - - if ( isset( $maybe_collection['type'] ) && in_array( $maybe_collection['type'], array( 'Collection', 'OrderedCollection' ), true ) ) { - // Return only the IDs of the items in the collection. - $event_sources = \wp_list_pluck( $maybe_collection['items'], 'id' ); - } else { - $event_sources[] = $event_source; - } - - // Iterate over all event sources and add them to the collection. - foreach ( $event_sources as $event_source ) { - $url = \wp_parse_url( $event_source ); - - if ( isset( $url['path'], $url['host'], $url['scheme'] ) ) { - $actor_url = \sanitize_url( $event_source ); - } elseif ( preg_match( '/^@?' . Event_Source::ACTIVITYPUB_USER_HANDLE_REGEXP . '$/i', $event_source ) ) { - $actor_url = Webfinger::resolve( $event_source ); - if ( \is_wp_error( $actor_url ) ) { - \add_settings_error( - 'event-bridge-for-activitypub_add-event-source', - 'event_bridge_for_activitypub_cannot_follow_actor', - $error_message . ': ' . esc_html__( 'Cannot find an ActivityPub actor for this user handle via Webfinger.', 'event-bridge-for-activitypub' ), - 'error' - ); - continue; - } - } else { - if ( ! isset( $url['path'] ) && isset( $url['host'] ) ) { - $actor_url = Event_Sources::get_application_actor( $url['host'] ); - } elseif ( self::is_domain( $event_source ) ) { - $actor_url = Event_Sources::get_application_actor( $event_source ); - } - if ( ! $actor_url ) { - \add_settings_error( - 'event-bridge-for-activitypub_add-event-source', - 'event_bridge_for_activitypub_cannot_follow_actor', - $error_message . ': ' . \esc_html__( 'Unable to identify the ActivityPub relay actor to follow for this domain.', 'event-bridge-for-activitypub' ), - 'error' - ); - continue; - } - } - - if ( ! $actor_url ) { - \add_settings_error( - 'event-bridge-for-activitypub_add-event-source', - 'event_bridge_for_activitypub_cannot_follow_actor', - $error_message . ': ' . \esc_html__( 'ActivityPub actor does not exist.', 'event-bridge-for-activitypub' ), - 'error' - ); - continue; - } - - // Don't proceed if on the same host! - if ( \wp_parse_url( \home_url(), PHP_URL_HOST ) === \wp_parse_url( $actor_url, PHP_URL_HOST ) ) { - \add_settings_error( - 'event-bridge-for-activitypub_add-event-source', - 'event_bridge_for_activitypub_cannot_follow_actor', - $error_message . ': ' . \esc_html__( 'Cannot follow own actor on own domain.', 'event-bridge-for-activitypub' ), - 'error' - ); - continue; - } - - Event_Source_Collection::add_event_source( $actor_url ); - } - } - - /** - * Check if a string is a valid domain name. - * - * @param string $domain The input string which might be a domain. - * @return bool - */ - private static function is_domain( $domain ): bool { - $pattern = '/^(?!\-)(?:(?:[a-zA-Z\d](?:[a-zA-Z\d\-]{0,61}[a-zA-Z\d])?)\.)+(?!\d+$)[a-zA-Z\d]{2,63}$/'; - return 1 === preg_match( $pattern, $domain ); - } - - /** - * Adds Link to the settings page in the plugin page. - * It's called via apply_filter('plugin_action_links_' . PLUGIN_NAME). - * - * @param array $links Already added links. - * - * @return array Original links but with link to setting page added. - */ - public static function settings_link( $links ): array { - $links[] = \sprintf( - '%2s', - \add_query_arg( 'tab', 'event-bridge-for-activitypub', \menu_page_url( 'activitypub', false ) ), - \__( 'Settings', 'event-bridge-for-activitypub' ) - ); - - return $links; - } - - /** - * Receive the event categories (terms) used by the event plugin. - * - * @param Event_Plugin_Integration $event_plugin Contains info about a certain event plugin. - * - * @return array An array of Terms. - */ - private static function get_event_terms( $event_plugin ): array { - $taxonomy = $event_plugin::get_event_category_taxonomy(); - if ( $taxonomy ) { - $event_terms = get_terms( - array( - 'taxonomy' => $taxonomy, - 'hide_empty' => true, - ) - ); - return ! is_wp_error( $event_terms ) ? $event_terms : array(); - } else { - return array(); - } - } - - /** - * Preparing the data and loading the template for the settings page. - * - * @return void - */ - public static function do_settings_page(): void { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( empty( $_GET['subpage'] ) ) { - $tab = 'welcome'; - } else { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $tab = \sanitize_key( $_GET['subpage'] ); - } - - // Fallback to always re-scan active event plugins, when user visits admin area of this plugin. - $plugin_setup = Setup::get_instance(); - $plugin_setup->redetect_active_event_plugins(); - $event_plugins = $plugin_setup->get_active_event_plugins(); - - switch ( $tab ) { - case 'settings': - $event_terms = array(); - - foreach ( $event_plugins as $event_plugin_integration ) { - $event_terms = array_merge( $event_terms, self::get_event_terms( $event_plugin_integration ) ); - } - - $args = array( - 'slug' => self::SETTINGS_SLUG, - 'event_terms' => $event_terms, - ); - - \load_template( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . 'templates/settings/subpages/settings.php', true, $args ); - break; - case 'event-sources': - $supports_event_sources = array(); - - foreach ( $event_plugins as $event_plugin_integration ) { - if ( is_a( $event_plugin_integration, Feature_Event_Sources::class ) ) { - $class_name = get_class( $event_plugin_integration ); - $supports_event_sources[ $class_name ] = $event_plugin_integration::get_plugin_name(); - } - } - - $args = array( - 'supports_event_sources' => $supports_event_sources, - ); - - \wp_enqueue_script( 'thickbox' ); - \wp_enqueue_style( 'thickbox' ); - \load_template( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . 'templates/settings/subpages/event-sources.php', true, $args ); - break; - case 'welcome': - default: - \wp_enqueue_script( 'plugin-install' ); - \add_thickbox(); - \wp_enqueue_script( 'updates' ); - - \load_template( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . 'templates/settings/subpages/welcome.php', true ); - break; - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-user-interface.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-user-interface.php deleted file mode 100644 index 9d673a2e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/admin/class-user-interface.php +++ /dev/null @@ -1,100 +0,0 @@ -guid; - - $parent = get_post_parent(); - - if ( $parent && Event_Sources_Collection::POST_TYPE === $parent->post_type ) { - $url = \get_post_meta( $parent->ID, '_activitypub_actor_id', true ); - } - - $actions['view_origin'] = sprintf( - '⁂ %s', - \esc_url( $url ), - \esc_html__( 'Open original page', 'event-bridge-for-activitypub' ) - ); - - return $actions; - } - - /** - * Modify the user capabilities so that nobody can edit external events. - * - * @param array $caps Concerned user's capabilities. - * @param mixed $cap Required primitive capabilities for the requested capability. - * @param array $user_id The WordPress user ID. - * @param array $args Additional args. - * - * @return array - */ - public static function disable_editing_for_external_events( $caps, $cap, $user_id, $args ) { - if ( 'edit_post' === $cap && isset( $args[0] ) ) { - $post_id = $args[0]; - $post = get_post( $post_id ); - if ( $post && Event_Sources::is_cached_external_post( $post ) ) { - // Deny editing by returning 'do_not_allow'. - return array( 'do_not_allow' ); - } - } - return $caps; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-autoloader.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-autoloader.php deleted file mode 100644 index 40f99cdf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-autoloader.php +++ /dev/null @@ -1,67 +0,0 @@ -get_active_event_plugins() as $event_plugin_integration ) { - if ( ! is_a( $event_plugin_integration, Feature_Event_Sources::class ) ) { - continue; - } - - $post_type = $event_plugin_integration::get_post_type(); - self::register_post_meta_event_bridge_for_activitypub_event_source( $post_type ); - - $post_type = $event_plugin_integration::get_place_post_type(); - if ( $post_type ) { - self::register_post_meta_event_bridge_for_activitypub_event_source( $post_type ); - } - - $post_type = $event_plugin_integration::get_organizer_post_type(); - if ( $post_type ) { - self::register_post_meta_event_bridge_for_activitypub_event_source( $post_type ); - } - } - } - - /** - * Register post meta _event_bridge_for_activitypub_event_source for a given post type. - * - * @param string $post_type The post type to register the meta for. - * @return void - */ - private static function register_post_meta_event_bridge_for_activitypub_event_source( $post_type ) { - \register_post_meta( - $post_type, - '_event_bridge_for_activitypub_event_source', - array( - 'type' => 'integer', - 'single' => true, - 'sanitize_callback' => 'absint', - ) - ); - } - - /** - * Get the Application actor via FEP-2677. - * - * @param string $domain The domain without scheme. - * @return bool|string The URL/ID of the application actor, false if not found. - */ - public static function get_application_actor( $domain ) { - $result = wp_remote_get( 'https://' . $domain . '/.well-known/nodeinfo' ); - - if ( is_wp_error( $result ) ) { - return false; - } - - $body = wp_remote_retrieve_body( $result ); - - $nodeinfo = json_decode( $body, true ); - - // Check if 'links' exists and is an array. - if ( isset( $nodeinfo['links'] ) && is_array( $nodeinfo['links'] ) ) { - foreach ( $nodeinfo['links'] as $link ) { - // Check if this link matches the application actor rel. - if ( isset( $link['rel'] ) && 'https://www.w3.org/ns/activitystreams#Application' === $link['rel'] ) { - if ( is_string( $link['href'] ) ) { - return $link['href']; - } - break; - } - } - } - - // Return false if no application actor is found. - return false; - } - - /** - * Filter that cached external posts are not scheduled via the ActivityPub plugin. - * - * Posts that are actually just external events are treated as cache. They are displayed in - * the frontend HTML view and redirected via ActivityPub request, but we do not own them. - * - * @param bool $disabled If it is disabled already by others (the upstream ActivityPub plugin). - * @param WP_Post $post The WordPress post object. - * @return bool False if the post is not disabled for federation via ActivityPub. - */ - public static function is_post_disabled_for_activitypub( $disabled, $post = null ): bool { - if ( $disabled ) { - return $disabled; - } - return self::is_cached_external_post( $post ); - } - - /** - * Determine whether a WP post is a cached external event. - * - * @param WP_Post|int $post The WordPress post object or post ID. - * @return bool - */ - public static function is_cached_external_post( $post ): bool { - $post_id = $post instanceof WP_Post ? $post->ID : $post; - - if ( \get_post_meta( $post_id, '_event_bridge_for_activitypub_event_source', true ) ) { - return true; - } - - return false; - } - - /** - * Add the ActivityPub template for EventPrime. - * - * @param string $template The path to the template object. - * @return string The new path to the JSON template. - */ - public static function redirect_activitypub_requests_for_cached_external_events( $template ) { - if ( defined( 'REST_REQUEST' ) && REST_REQUEST ) { - return $template; - } - - if ( ! is_activitypub_request() ) { - return $template; - } - - if ( ! \is_singular() ) { - return $template; - } - - $post = \get_post( \get_queried_object_id() ); - - if ( self::is_cached_external_post( $post ) ) { - \wp_safe_redirect( $post->guid, 301 ); - exit; - } - - return $template; - } - - /** - * Delete old cached events that took place in the past. - */ - public static function clear_cache() { - // Get the event plugin integration that is used. - $event_plugin_integration = Setup::get_event_plugin_integration_used_for_event_sources_feature(); - - if ( ! $event_plugin_integration ) { - return; - } - - $cache_retention_period = get_option( 'event_bridge_for_activitypub_event_source_cache_retention', WEEK_IN_SECONDS ); - - $ended_before_time = gmdate( 'Y-m-d H:i:s', time() - $cache_retention_period ); - - $past_event_ids = $event_plugin_integration::get_cached_remote_events( $ended_before_time ); - - foreach ( $past_event_ids as $post_id ) { - if ( has_post_thumbnail( $post_id ) ) { - $attachment_id = get_post_thumbnail_id( $post_id ); - wp_delete_attachment( $attachment_id, true ); - } - wp_delete_post( $post_id, true ); - } - } - - /** - * Add the Blog Authors to the following list of the Blog Actor - * if Blog not in single mode. - * - * @param array $follow_list The array of following urls. - * @param mixed $user The user object, a subtype of \Activitypub\Model\User. - * - * @return array The array of following urls. - */ - public static function add_event_sources_to_follow_collection( $follow_list, $user ): array { - if ( ! $user instanceof Blog ) { - return $follow_list; - } - - $event_sources_activitypub_ids = array_values( Event_Sources_Collection::get_event_sources() ); - - return array_merge( $follow_list, $event_sources_activitypub_ids ); - } - - /** - * Get an array will all unique hosts of all Event-Sources. - * - * @return array A list with all unique hosts of all Event Sources' ActivityPub IDs. - */ - public static function get_event_sources_hosts() { - $hosts = get_transient( 'event_bridge_for_activitypub_event_sources_hosts' ); - - if ( $hosts ) { - return $hosts; - } - - $event_sources = Event_Sources_Collection::get_event_sources(); - - $hosts = array(); - foreach ( $event_sources as $actor ) { - $url = wp_parse_url( $actor ); - if ( isset( $url['host'] ) ) { - $hosts[] = $url['host']; - } - } - - $hosts = array_unique( $hosts ); - - set_transient( 'event_bridge_for_activitypub_event_sources_hosts', $hosts ); - - return $hosts; - } - - /** - * Add Event Sources hosts to allowed hosts used by safe redirect. - * - * @param array $hosts The hosts before the filter. - * @return array - */ - public static function add_event_sources_hosts_to_allowed_redirect_hosts( $hosts ) { - $event_sources_hosts = self::get_event_sources_hosts(); - return array_merge( $hosts, $event_sources_hosts ); - } - - /** - * Mark incoming accept activities as valid. - * - * @param bool $valid The validation state. - * @param string $param The object parameter. - * @param WP_REST_Request $request The request object. - * - * @return bool|WP_Error The validation state: true if valid, false if not. - */ - public static function validate_activity( $valid, $param, $request ) { - if ( $valid ) { - return $valid; - } - $json_params = $request->get_json_params(); - - if ( isset( $json_params['object']['type'] ) && in_array( $json_params['object']['type'], array( 'Accept', 'Undo' ), true ) ) { - return true; - } - - return $valid; - } - - /** - * Validate the event object. - * - * @param bool $valid The validation state. - * @param string $param The object parameter. - * @param WP_REST_Request $request The request object. - * - * @return bool|WP_Error The validation state: true if valid, false if not. - */ - public static function validate_event_object( $valid, $param, $request ) { - $json_params = $request->get_json_params(); - - // Check if we should continue with the validation. - if ( isset( $json_params['object']['type'] ) && 'Event' === $json_params['object']['type'] ) { - $valid = true; - } else { - return $valid; - } - - if ( empty( $json_params['type'] ) ) { - return false; - } - - if ( empty( $json_params['actor'] ) ) { - return false; - } - - if ( ! in_array( $json_params['type'], array( 'Create', 'Update', 'Delete', 'Announce' ), true ) ) { - return $valid; - } - - if ( ! self::is_valid_activitypub_event_object( $json_params['object'] ) ) { - return false; - } - - if ( ! self::same_host( $json_params['actor'], $json_params['id'], $json_params['object']['id'] ) ) { - return false; - } - - return true; - } - - /** - * Checks if all provided URLs belong to the same origin (host). - * - * @param string ...$urls List of URLs to compare. - * @return bool True if all URLs have the same host, false otherwise. - */ - public static function same_host( ...$urls ) { - if ( empty( $urls ) ) { - return false; // No URLs given, can't compare hosts. - } - - $first = \wp_parse_url( array_shift( $urls ) ); - if ( ! isset( $first['host'] ) ) { - return false; - } - - $first_host = $first['host']; - - foreach ( $urls as $url ) { - $result = \wp_parse_url( $url ); - if ( ! isset( $result['host'] ) ) { - return false; - } - - if ( $result['host'] !== $first_host ) { - return false; - } - } - - return true; - } - - - /** - * Check if the object is a valid ActivityPub event. - * - * @param mixed $event_object The (event) object as an associative array. - * @return bool True if the object is an valid ActivityPub Event, false if not. - */ - public static function is_valid_activitypub_event_object( $event_object ): bool { - if ( ! is_array( $event_object ) ) { - return false; - } - - $required = array( - 'id', - 'startTime', - 'name', - ); - - if ( array_intersect( $required, array_keys( $event_object ) ) !== $required ) { - return false; - } - - if ( ! self::is_valid_activitypub_time_string( $event_object['startTime'] ) ) { - return false; - } - - if ( ! self::is_valid_activitypub_id( $event_object['id'] ) ) { - return false; - } - - return true; - } - - /** - * Validate an ActivityPub ID. - * - * @link https://www.w3.org/TR/activitypub/#obj-id - * - * @param string $id The ID to validate. - * @return bool - */ - public static function is_valid_activitypub_id( $id ) { - return \sanitize_url( $id ) ? true : false; - } - - /** - * Validate a time string if it is according to the ActivityPub specification. - * - * @link https://www.w3.org/TR/activitystreams-core/#dates - * - * @param string $time_string The xsd:datetime string. - * @return bool - */ - public static function is_valid_activitypub_time_string( string $time_string ): bool { - // Regular expression based on AS2 rules. - return 1 === preg_match( '/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}(:\d{2})?(\.\d+)?(Z|[+-]\d{2}:\d{2})$/', $time_string ); - } - - /** - * Check if a given DateTime is already passed. - * - * @param string|DateTime $time The ActivityPub like time string or DateTime object. - * @return bool - */ - public static function is_time_passed( $time ) { - if ( ! $time instanceof DateTime ) { - // Create a DateTime object from the ActivityPub time string. - $time = new DateTime( $time, new DateTimeZone( 'UTC' ) ); - } - - // Get the current time in UTC. - $current_time = new DateTime( 'now', new DateTimeZone( 'UTC' ) ); - - // Compare the event time with the current time. - return $time < $current_time; - } - - /** - * Determine whether an Event is an ongoing or future event. - * - * @param array $event_object The ActivityPub Event as an associative array. - * @return bool - */ - public static function is_ongoing_or_future_event( $event_object ) { - if ( isset( $event_object['endTime'] ) ) { - $time = $event_object['endTime']; - } else { - $time = new DateTime( $event_object['startTime'], new DateTimeZone( 'UTC' ) ); - $time->modify( '+3 hours' ); - } - return ! self::is_time_passed( $time ); - } - - /** - * Check that an ActivityPub actor is an event source (i.e. it is followed by the ActivityPub blog actor). - * - * @param string $actor_id The actor ID. - * @return bool True if the ActivityPub actor ID is followed, false otherwise. - */ - public static function actor_is_event_source( $actor_id ) { - $event_sources = Event_Sources_Collection::get_event_sources(); - if ( in_array( $actor_id, $event_sources, true ) ) { - return true; - } - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-outbox-parser.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-outbox-parser.php deleted file mode 100644 index f970383e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-outbox-parser.php +++ /dev/null @@ -1,282 +0,0 @@ -get_outbox(); - - if ( ! $outbox_url ) { - return; - } - - // Schedule the import of events via the outbox. - self::queue_importing_from_outbox( $outbox_url, $event_source->get__id(), 0 ); - } - - /** - * Import events from an outbox: OrderedCollection or OrderedCollectionPage. - * - * @param string $url The url of the current page or outbox. - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * @return void - */ - public static function import_events_from_outbox( $url, $event_source_post_id ) { - $setup = Setup::get_instance(); - if ( ! $setup->is_activitypub_plugin_active() ) { - return; - } - - $outbox = self::fetch_outbox( $url ); - - if ( ! $outbox ) { - return; - } - - $current_count = self::get_import_count( $event_source_post_id ); - - if ( $current_count >= self::MAX_EVENTS_TO_IMPORT ) { - return; - } - - // Process orderedItems if they exist (non-paginated outbox). - if ( isset( $outbox['orderedItems'] ) && is_array( $outbox['orderedItems'] ) ) { - $current_count += self::import_events_from_items( - $outbox['orderedItems'], - $event_source_post_id, - self::MAX_EVENTS_TO_IMPORT - $current_count - ); - } - - self::update_import_count( $event_source_post_id, $current_count ); - - // If the count is already exceeded abort here. - if ( $current_count >= self::MAX_EVENTS_TO_IMPORT ) { - return; - } - - // Get next page and if it exists schedule the import of next page. - $pagination_url = self::get_pagination_url( $outbox ); - - if ( $pagination_url ) { - self::queue_importing_from_outbox( $pagination_url, $event_source_post_id ); - } - } - - /** - * Check if an Activity is of type Update or Create. - * - * @param array $activity The Activity as associative array. - * @return bool - */ - private static function is_create_or_update_activity( $activity ) { - if ( ! isset( $activity['type'] ) ) { - return false; - } - if ( in_array( $activity['type'], array( 'Update', 'Create' ), true ) ) { - return true; - } - return false; - } - - /** - * Parses items from an Collection, OrderedCollection, CollectionPage or OrderedCollectionPage. - * - * @param array $items The items as an associative array. - * @param int $max_items The maximum number of items to parse. - * @return array Parsed events from the collection. - */ - private static function parse_outbox_items_for_events( $items, $max_items ) { - $parsed_events = array(); - - foreach ( $items as $activity ) { - // Abort if we have exceeded the maximal events to return. - if ( $max_items > 0 && count( $parsed_events ) >= $max_items ) { - break; - } - - // Check if it is a create or update Activity. - if ( ! self::is_create_or_update_activity( $activity ) ) { - continue; - } - - // If no object is set we cannot process anything. - if ( ! isset( $activity['object'] ) ) { - continue; - } - - // Check if the Event object meets the minimum requirements and is valid. - $is_valid_event_object = Event_Sources::is_valid_activitypub_event_object( $activity['object'] ); - if ( ! $is_valid_event_object ) { - continue; - } - - // Check if the event is in the future or ongoing. - if ( Event_Sources::is_ongoing_or_future_event( $activity['object'] ) ) { - $parsed_events[] = $activity['object']; - } - } - - return $parsed_events; - } - - /** - * Import events from the items of an outbox. - * - * @param array $items The items/orderedItems as an associative array. - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * @param int $limit The limit of how many events to save locally. - * @return int The number of saved events (at least attempted). - */ - private static function import_events_from_items( $items, $event_source_post_id, $limit = -1 ): int { - $events = self::parse_outbox_items_for_events( $items, $limit ); - - $transmogrifier = Setup::get_transmogrifier(); - - if ( ! $transmogrifier ) { - return 0; - } - - $imported_count = 0; - - foreach ( $events as $event ) { - $transmogrifier::save( $event, $event_source_post_id ); - ++$imported_count; - if ( $limit > 0 && $imported_count >= $limit ) { - break; - } - } - - return $imported_count; - } - - /** - * Schedule the import of events from an outbox OrderedCollection or OrderedCollectionPage. - * - * @param string $url The url of the current page or outbox. - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * @param int $delay The delay of the current time in seconds. - * @return bool - */ - private static function queue_importing_from_outbox( $url, $event_source_post_id, $delay = 10 ): bool { - $hook = 'event_bridge_for_activitypub_import_events_from_outbox'; - $args = array( $url, $event_source_post_id ); - - if ( \wp_next_scheduled( $hook, $args ) ) { - return false; - } - - return \wp_schedule_single_event( \time() + $delay, $hook, $args ); - } - - /** - * Get the current import count for the actor. - * - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * @return int The current count of imported events. - */ - private static function get_import_count( $event_source_post_id ): int { - return (int) \get_post_meta( $event_source_post_id, '_event_bridge_for_activitypub_event_count', true ); - } - - /** - * Update the import count for an event source.. - * - * @param int $event_source_post_id The Post ID of the Event Source that owns the outbox. - * @param int $count The new count of imported events. - * @return void - */ - private static function update_import_count( $event_source_post_id, $count ) { - \update_post_meta( $event_source_post_id, '_event_bridge_for_activitypub_event_count', $count ); - } - - /** - * Fetch the outbox from the given URL. - * - * @param string $url The URL of the outbox. - * @return array|null The decoded outbox data, or null if fetching fails. - */ - private static function fetch_outbox( $url ) { - $response = Http::get( $url ); - - if ( \is_wp_error( $response ) ) { - return null; - } - - $outbox = \wp_remote_retrieve_body( $response ); - $outbox = \json_decode( $outbox, true ); - - return ( is_array( $outbox ) && isset( $outbox['type'] ) && isset( $outbox['id'] ) ) ? $outbox : null; - } - - /** - * Get the pagination URL from the outbox. - * - * @param array $outbox The outbox data. - * @return string|null The pagination URL, or null if not found. - */ - private static function get_pagination_url( $outbox ) { - // If we are on a collection page simply use the next key. - if ( 'OrderedCollectionPage' === $outbox['type'] && ! empty( $outbox['next'] ) && is_string( $outbox['next'] ) ) { - return $outbox['next']; - } - - // If we still have the ordered collection itself. - if ( isset( $outbox['type'] ) && 'OrderedCollection' === $outbox['type'] && isset( $outbox['first'] ) ) { - return object_to_uri( $outbox['first'] ); - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-preview.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-preview.php deleted file mode 100644 index 637947bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-preview.php +++ /dev/null @@ -1,40 +0,0 @@ -get_active_event_plugins_post_types(); - - if ( in_array( \get_post_type(), $event_post_types, true ) ) { - return EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . '/templates/event-preview.php'; - } - - return ACTIVITYPUB_PLUGIN_DIR . '/templates/post-preview.php'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-reminder.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-reminder.php deleted file mode 100644 index 67153ebe..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-reminder.php +++ /dev/null @@ -1,192 +0,0 @@ - true, - 'single' => true, - 'type' => 'integer', - 'sanitize_callback' => 'absint', - ) - ); - } - } - - /** - * Enqueue the block editor assets. - */ - public static function enqueue_editor_assets() { - // Check for our supported post types. - $current_screen = \get_current_screen(); - $event_post_types = Setup::get_instance()->get_active_event_plugins_post_types(); - if ( ! $current_screen || ! in_array( $current_screen->post_type, $event_post_types, true ) ) { - return; - } - $asset_data = include EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . 'build/reminder/plugin.asset.php'; - $plugin_url = plugins_url( 'build/reminder/plugin.js', EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE ); - \wp_enqueue_script( 'event-bridge-for-activitypub-reminder', $plugin_url, $asset_data['dependencies'], $asset_data['version'], true ); - - // Pass the the default site wide time gap option to the settings block on the events edit page. - \wp_localize_script( - 'event-bridge-for-activitypub-reminder', - 'activityPubEventBridge', - array( - 'reminderTypeGap' => \get_option( 'event_bridge_for_activitypub_reminder_time_gap', 0 ), - ) - ); - } - - /** - * Schedule Activities. - * - * @param string $new_status New post status. - * @param string $old_status Old post status. - * @param ?WP_Post $post Post object. - */ - public static function maybe_schedule_event_reminder( $new_status, $old_status, $post ): void { - if ( ! $post instanceof WP_Post ) { - return; - } - - // At first always unschedule the reminder for this event, it will be added again, in case. - self::unschedule_event_reminder( $post->ID ); - - // Do not set reminders if post is password protected. - if ( \post_password_required( $post ) ) { - return; - } - - // Only schedule an reminder for event post types. - if ( ! Setup::get_instance()->is_event_post_type_of_active_event_plugin( $post->post_type ) ) { - return; - } - - // Do not schedule a reminder if the event is not published. - if ( 'publish' !== $new_status ) { - return; - } - - // See if a reminder time gap is set for the event individually in the events post-meta. - $reminder_time_gap = (int) get_post_meta( $post->ID, 'event_bridge_for_activitypub_reminder_time_gap', true ); - - // If not fallback to the global reminder time gap. - if ( ! $reminder_time_gap ) { - $reminder_time_gap = \get_option( 'event_bridge_for_activitypub_reminder_time_gap', 0 ); - } - - // Any non positive integer means that this feature is not active for this event post. - if ( 0 === $reminder_time_gap || ! is_int( $reminder_time_gap ) ) { - return; - } - - // Get start time of the event. - $event_transformer = Transformer_Factory::get_transformer( $post ); - - if ( \is_wp_error( $event_transformer ) || ! $event_transformer instanceof Event_Transformer ) { - return; - } - - $start_time = $event_transformer->get_start_time(); - $start_datetime = new DateTime( $start_time ); - $start_timestamp = $start_datetime->getTimestamp(); - - // Get the time when the reminder of the event's start should be sent. - $schedule_time = $start_timestamp - $reminder_time_gap; - - // If the reminder time has already passed "now" skip it. - if ( $schedule_time < \time() ) { - return; - } - - // All checks passed: schedule a single event which will trigger the sending of the reminder for this event post. - \wp_schedule_single_event( $schedule_time, 'event_bridge_for_activitypub_send_event_reminder', array( $post->ID ) ); - } - - /** - * Unschedule the event reminder. - * - * @param int $post_id The WordPress post ID of the event post. - */ - public static function unschedule_event_reminder( $post_id ): void { - \wp_clear_scheduled_hook( 'event_bridge_for_activitypub_send_event_reminder', array( $post_id ) ); - } - - /** - * Send a reminder for an event post. - * - * This currently sends an Announce activity. - * - * @param int $post_id The WordPress post ID of the event post. - */ - public static function send_event_reminder( $post_id ) { - $post = \get_post( $post_id ); - - $transformer = Transformer_Factory::get_transformer( $post ); - - if ( \is_wp_error( $transformer ) || ! $transformer instanceof Event_Transformer ) { - return; - } - - $actor = $transformer->get_actor_object(); - $user_id = $actor->get__id(); - - if ( $user_id > 0 && is_user_disabled( $user_id ) ) { - return; - } - - // Add announce of the event to outbox. - add_to_outbox( $post, 'Announce', $user_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-settings.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-settings.php deleted file mode 100644 index e4dca80d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-settings.php +++ /dev/null @@ -1,261 +0,0 @@ - 'string', - 'description' => \__( 'Default standardized federated event category.', 'event-bridge-for-activitypub' ), - 'show_in_rest' => true, - 'default' => self::DEFAULT_EVENT_CATEGORY, - 'sanitize_callback' => array( self::class, 'sanitize_mapped_event_category' ), - ) - ); - - \register_setting( - 'event-bridge-for-activitypub', - 'event_bridge_for_activitypub_event_category_mappings', - array( - 'type' => 'array', - 'description' => \__( 'Define your own custom post template', 'event-bridge-for-activitypub' ), - 'default' => array(), - 'sanitize_callback' => array( self::class, 'sanitize_event_category_mappings' ), - ) - ); - - \register_setting( - 'event-bridge-for-activitypub', - 'event_bridge_for_activitypub_reminder_time_gap', - array( - 'type' => 'array', - 'description' => \__( 'Time gap in seconds when a reminder is triggered that the event is about to start.', 'event-bridge-for-activitypub' ), - 'default' => 0, // Zero leads to this feature being deactivated. - 'sanitize_callback' => 'absint', - ) - ); - - \register_setting( - 'event-bridge-for-activitypub', - 'event_bridge_for_activitypub_initially_activated', - array( - 'type' => 'boolean', - 'description' => \__( 'Whether the plugin just got activated for the first time.', 'event-bridge-for-activitypub' ), - 'default' => 1, - ) - ); - - \register_setting( - 'event-bridge-for-activitypub', - 'event_bridge_for_activitypub_summary_type', - array( - 'type' => 'string', - 'description' => \__( 'Summary type to use for ActivityStreams', 'event-bridge-for-activitypub' ), - 'show_in_rest' => true, - 'default' => 'preset', - ) - ); - - \register_setting( - 'event-bridge-for-activitypub', - 'event_bridge_for_activitypub_summary_format', - array( - 'type' => 'string', - 'description' => \__( 'Summary format to use for ActivityStreams', 'event-bridge-for-activitypub' ), - 'show_in_rest' => true, - 'default' => 'html', - ) - ); - - \register_setting( - 'event-bridge-for-activitypub', - 'event_bridge_for_activitypub_custom_summary', - array( - 'type' => 'string', - 'description' => \__( 'Define your own custom summary template for events', 'event-bridge-for-activitypub' ), - 'show_in_rest' => true, - 'default' => EVENT_BRIDGE_FOR_ACTIVITYPUB_SUMMARY_TEMPLATE, - ) - ); - - \register_setting( - 'event-bridge-for-activitypub_event-sources', - 'event_bridge_for_activitypub_event_sources_active', - array( - 'type' => 'boolean', - 'show_in_rest' => true, - 'description' => \__( 'Whether the event sources feature is activated.', 'event-bridge-for-activitypub' ), - 'default' => 0, - 'sanitize_callback' => array( self::class, 'sanitize_event_sources_feature_active' ), - ) - ); - - \register_setting( - 'event-bridge-for-activitypub_event-sources', - 'event_bridge_for_activitypub_event_source_cache_retention', - array( - 'type' => 'integer', - 'show_in_rest' => true, - 'description' => \__( 'The cache retention period for external event sources.', 'event-bridge-for-activitypub' ), - 'default' => WEEK_IN_SECONDS, - 'sanitize_callback' => 'absint', - ) - ); - - \register_setting( - 'event-bridge-for-activitypub_event-sources', - 'event_bridge_for_activitypub_integration_used_for_event_sources_feature', - array( - 'type' => 'string', - 'description' => \__( 'Define which plugin/integration is used for the event sources feature', 'event-bridge-for-activitypub' ), - 'default' => array(), - 'sanitize_callback' => array( self::class, 'sanitize_event_plugin_integration_used_for_event_sources' ), - ) - ); - - \register_setting( - 'event-bridge-for-activitypub_add-event-source', - 'event_bridge_for_activitypub_add_event_source', - array( - 'type' => 'array', - 'description' => \__( 'Dummy setting for adding event sources', 'event-bridge-for-activitypub' ), - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - } - - /** - * Do not allow the event sources feature to get deactivated, when event sources are still followed. - * - * @param mixed $value The optios value. - */ - public static function sanitize_event_sources_feature_active( $value ) { - $count = count( Event_Sources::get_event_sources() ); - - $value = (bool) $value; - - if ( 0 === $count ) { - return $value; - } - - if ( ! $value ) { - \add_settings_error( - 'event-bridge-for-activitypub_event-sources', - 'event_bridge_for_activitypub_cannot_disable_event_sources', - __( 'It is not possible to disable the Event Sources feature while you are still having active followed Event Sources.', 'event-bridge-for-activitypub' ), - 'error' - ); - } - - return true; - } - - /** - * Sanitize the option which event plugin. - * - * @param mixed $event_plugin_integration The setting. - * @return string - */ - public static function sanitize_event_plugin_integration_used_for_event_sources( $event_plugin_integration ): string { - if ( ! is_string( $event_plugin_integration ) ) { - return ''; - } - $setup = Setup::get_instance(); - $active_event_plugins = $setup->get_active_event_plugins(); - - $valid_options = array(); - foreach ( $active_event_plugins as $active_event_plugin ) { - if ( $active_event_plugin instanceof Feature_Event_Sources ) { - $valid_options[] = get_class( $active_event_plugin ); - } - } - if ( in_array( $event_plugin_integration, $valid_options, true ) ) { - return $event_plugin_integration; - } - return Setup::get_default_integration_class_name_used_for_event_sources_feature(); - } - - /** - * Sanitize the target ActivityPub Event category. - * - * @param string $event_category The ActivityPUb event category. - */ - public static function sanitize_mapped_event_category( $event_category ): string { - return self::is_allowed_event_category( $event_category ) ? $event_category : self::DEFAULT_EVENT_CATEGORY; - } - - /** - * Sanitization function for the event category mapping setting. - * - * Currently only the default event categories are allowed to be target of a mapping. - * - * @param array $event_category_mappings The settings value. - * - * @return array An array that contains only valid mapping pairs. - */ - public static function sanitize_event_category_mappings( $event_category_mappings ): array { - if ( empty( $event_category_mappings ) ) { - return array(); - } - foreach ( $event_category_mappings as $taxonomy_slug => $event_category ) { - if ( ! self::is_allowed_event_category( $event_category ) ) { - unset( $event_category_mappings[ $taxonomy_slug ] ); - } - } - return $event_category_mappings; - } - - /** - * Checks if the given event category is allowed to be target of a mapping. - * - * @param string $event_category The event category to check. - * - * @return bool True if allowed, false otherwise. - */ - private static function is_allowed_event_category( $event_category ): bool { - require_once EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . '/includes/event-categories.php'; - $allowed_event_categories = array_keys( EVENT_BRIDGE_FOR_ACTIVITYPUB_EVENT_CATEGORIES ); - return in_array( $event_category, $allowed_event_categories, true ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-setup.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-setup.php deleted file mode 100644 index 8f9ffe02..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/class-setup.php +++ /dev/null @@ -1,692 +0,0 @@ -activitypub_plugin_is_active = defined( 'ACTIVITYPUB_PLUGIN_VERSION' ) || \is_plugin_active( 'activitypub/activitypub.php' ); - $this->activitypub_plugin_version = self::get_activitypub_plugin_version(); - - // Register main action that load the Event Bridge For ActivityPub. - \add_action( 'plugins_loaded', array( $this, 'setup_hooks' ) ); - } - - /** - * The single instance of the class. - * - * @since 1.0.0 - * @var ?self The instance of the class. - */ - private static $instance = null; - - /** - * Get the instance of the Singleton class. - * - * If an instance does not exist, it creates one; otherwise, it returns the existing instance. - * - * @since 1.0.0 - * - * @return self The instance of the class. - */ - public static function get_instance(): self { - if ( null === self::$instance ) { - self::$instance = new self(); - } - - return self::$instance; - } - - /** - * Getter function for whether the ActivityPub plugin is active. - * - * @return bool True when the ActivityPub plugin is active. - */ - public function is_activitypub_plugin_active(): bool { - return $this->activitypub_plugin_is_active; - } - - /** - * Get the current version of the ActivityPub plugin. - * - * @return string The semantic Version. - */ - private static function get_activitypub_plugin_version(): string { - if ( defined( 'ACTIVITYPUB_PLUGIN_VERSION' ) ) { - return constant( 'ACTIVITYPUB_PLUGIN_VERSION' ); - } - return '0.0.0'; - } - - /** - * Getter function for the active event plugins. - * - * @return Event_Plugin_Integration[] - */ - public function get_active_event_plugins(): array { - return $this->active_event_plugins; - } - - /** - * Getter function for the active event plugins event post types. - * - * @return array List of event post types of the active event plugins. - */ - public function get_active_event_plugins_post_types(): array { - $post_types = array(); - foreach ( $this->active_event_plugins as $event_plugin ) { - $post_types[] = $event_plugin->get_post_type(); - } - - return $post_types; - } - - /** - * Function to check whether a post type is an event post type of an active event plugin. - * - * @param string $post_type The post type. - * - * @return bool True if it is an event post type. - */ - public function is_event_post_type_of_active_event_plugin( $post_type ): bool { - foreach ( $this->active_event_plugins as $event_plugin ) { - if ( $post_type === $event_plugin->get_post_type() ) { - return true; - } - } - - return false; - } - - /** - * Holds all the full class names for the supported event plugins. - * - * @var string[] - */ - private const EVENT_PLUGIN_INTEGRATIONS = array( - \Event_Bridge_For_ActivityPub\Integrations\Events_Manager::class, - \Event_Bridge_For_ActivityPub\Integrations\GatherPress::class, - \Event_Bridge_For_ActivityPub\Integrations\The_Events_Calendar::class, - \Event_Bridge_For_ActivityPub\Integrations\VS_Event_List::class, - \Event_Bridge_For_ActivityPub\Integrations\WP_Event_Manager::class, - \Event_Bridge_For_ActivityPub\Integrations\Eventin::class, - \Event_Bridge_For_ActivityPub\Integrations\Modern_Events_Calendar_Lite::class, - \Event_Bridge_For_ActivityPub\Integrations\Event_Organiser::class, - \Event_Bridge_For_ActivityPub\Integrations\EventPrime::class, - \Event_Bridge_For_ActivityPub\Integrations\EventOn::class, - ); - - /** - * Force the re-scan for active event plugins without using the cached transient. - * - * @return void - */ - public function redetect_active_event_plugins(): void { - if ( ! $this->activitypub_plugin_is_active ) { - return; - } - \delete_transient( 'event_bridge_for_activitypub_active_event_plugins' ); - - $this->detect_active_event_plugins(); - } - - /** - * Function that checks for supported activated event plugins. - * - * @return array List of supported event plugins as keys from the SUPPORTED_EVENT_PLUGINS const. - */ - public function detect_active_event_plugins(): array { - // Detection will fail in case the ActivityPub plugin is not active. - if ( ! $this->activitypub_plugin_is_active ) { - return array(); - } - - $active_event_plugins = \get_transient( 'event_bridge_for_activitypub_active_event_plugins' ); - - if ( $active_event_plugins ) { - $this->active_event_plugins = $active_event_plugins; - return $active_event_plugins; - } - - if ( ! function_exists( 'get_plugins' ) ) { - // @phpstan-ignore-next-line - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - - $all_plugins = array_merge( \get_plugins(), \get_mu_plugins() ); - - $active_event_plugins = array(); - foreach ( self::EVENT_PLUGIN_INTEGRATIONS as $event_plugin_integration ) { - // Get the filename of the main plugin file of the event plugin (relative to the plugin dir). - $event_plugin_file = $event_plugin_integration::get_relative_plugin_file(); - - // Check if plugin is present on disk and is activated. - if ( array_key_exists( $event_plugin_file, $all_plugins ) && \is_plugin_active( $event_plugin_file ) ) { - $active_event_plugins[ $event_plugin_file ] = new $event_plugin_integration(); - } - } - \set_transient( 'event_bridge_for_activitypub_active_event_plugins', $active_event_plugins ); - $this->active_event_plugins = $active_event_plugins; - return $active_event_plugins; - } - - /** - * Function that checks which event plugins support the event sources feature. - * - * @return array List of supported event plugins as keys from the SUPPORTED_EVENT_PLUGINS const. - */ - public static function detect_event_plugins_supporting_event_sources(): array { - $plugins_supporting_event_sources = array(); - - foreach ( self::EVENT_PLUGIN_INTEGRATIONS as $event_plugin_integration ) { - if ( is_a( $event_plugin_integration, Feature_Event_Sources::class, true ) ) { - $plugins_supporting_event_sources[] = new $event_plugin_integration(); - } - } - return $plugins_supporting_event_sources; - } - - /** - * Main setup function of the plugin "Event Bridge For ActivityPub". - * - * This method adds hooks for different purposes as needed. - * - * @since 1.0.0 - * - * @return void - */ - public function setup_hooks(): void { - // Detect active supported event plugins. - $this->detect_active_event_plugins(); - - // Register hook that runs when this plugin gets activated. - \register_activation_hook( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE, array( $this, 'activate' ) ); - - // Register listeners whenever any plugin gets activated or deactivated to maybe update the transient of active event plugins. - \add_action( 'activated_plugin', array( $this, 'redetect_active_event_plugins' ) ); - \add_action( 'deactivated_plugin', array( $this, 'redetect_active_event_plugins' ) ); - - // Add hook that takes care of all notices in the Admin UI. - \add_action( 'admin_init', array( $this, 'do_admin_notices' ) ); - - // Add hook that registers all settings of this plugin to WordPress. - \add_action( 'admin_init', array( Settings::class, 'register_settings' ) ); - - // Add hook that loads CSS and JavaScript files for the Admin UI. - \add_action( 'admin_enqueue_scripts', array( self::class, 'enqueue_styles' ) ); - - // Register the settings page of this plugin as a Tab in the ActivityPub plugins settings. - Settings_Page::init(); - - // Add settings link in the Plugin overview Page. - \add_filter( - 'plugin_action_links_' . EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_BASENAME, - array( Settings_Page::class, 'settings_link' ) - ); - - // If we don't have any active event plugins, or the ActivityPub plugin is not enabled, abort here. - if ( empty( $this->active_event_plugins ) || ! $this->activitypub_plugin_is_active ) { - self::shut_down(); - return; - } - - // Register health checks and status reports to the WordPress status report site. - \add_action( 'init', array( Health_Check::class, 'init' ) ); - - // Check if the minimum required version of the ActivityPub plugin is installed, if not abort. - - if ( ! version_compare( $this->activitypub_plugin_version, EVENT_BRIDGE_FOR_ACTIVITYPUB_ACTIVITYPUB_PLUGIN_MIN_VERSION, '>=' ) ) { - return; - } - - // Register our own deplayed event scheduler because of upstream race-condition bug. - // See https://github.com/Automattic/wordpress-activitypub/issues/1269 for more information. - if ( version_compare( $this->activitypub_plugin_version, '7.0.0', '<' ) ) { - Event_Scheduler::init(); - } - - // Register the event reminders. - \add_action( 'init', array( Reminder::class, 'init' ) ); - - // Initialize the handling of "Join" activities. - Join_Handler::init(); - - // If the Event-Sources feature is enabled and all requirements are met, initialize it. - if ( ! is_user_type_disabled( 'blog' ) && \get_option( 'event_bridge_for_activitypub_event_sources_active' ) ) { - Event_Sources::init(); - } - - // Initialize writing of debug logs. - Debug::init(); - - $this->register_plugin_specific_hooks(); - - // Most importantly: register the ActivityPub transformers for events to the ActivityPub plugin. - \add_filter( 'activitypub_transformer', array( $this, 'register_activitypub_transformer' ), 10, 3 ); - - // Apply custom ActivityPub previews for events. - \add_action( 'init', array( Preview::class, 'init' ) ); - - $this->maybe_register_term_activitypub_ids(); - } - - /** - * Temporary hack to register custom actions and hooks, only needed by exceptional event plugins. - * - * @return void - */ - private function register_plugin_specific_hooks(): void { - if ( array_key_exists( \Event_Bridge_For_ActivityPub\Integrations\EventPrime::get_relative_plugin_file(), $this->active_event_plugins ) ) { - \Event_Bridge_For_ActivityPub\Integrations\EventPrime::init(); - } - } - - /** - * Shut down the plugin. - * - * @return void - */ - public static function shut_down(): void { - // Delete all transients. - Event_Sources_Collection::delete_event_source_transients(); - \delete_transient( 'event_bridge_for_activitypub_active_event_plugins' ); - - // Unschedule all crons. - \wp_unschedule_hook( 'event_bridge_for_activitypub_event_sources_clear_cache' ); - } - - /** - * Add the CSS for the admin pages. - * - * @param string $hook_suffix The suffix of the hook. - * - * @return void - */ - public static function enqueue_styles( $hook_suffix ): void { - if ( 'settings_page_activitypub' !== $hook_suffix ) { - return; - } - - // Check if we're on your custom tab. - $current_tab = isset( $_GET['tab'] ) ? \sanitize_key( $_GET['tab'] ) : 'welcome'; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( 'event-bridge-for-activitypub' === $current_tab ) { - \wp_enqueue_style( - 'event-bridge-for-activitypub-admin-styles', - plugins_url( - 'assets/css/event-bridge-for-activitypub-admin.css', - EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE - ), - array(), - EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_VERSION - ); - \wp_enqueue_script( - 'event-bridge-for-activitypub-admin-script', - plugins_url( - 'assets/js/event-bridge-for-activitypub-admin.js', - EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE - ), - array( 'jquery' ), - EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_VERSION, - false - ); - } - } - - /** - * Fires the initialization of admin notices. - */ - public function do_admin_notices(): void { - foreach ( $this->active_event_plugins as $event_plugin ) { - new Event_Plugin_Admin_Notices( $event_plugin ); - } - // Check if any general admin notices are needed and add actions to insert the needed admin notices. - if ( ! $this->activitypub_plugin_is_active ) { - // The ActivityPub plugin is not active. - \add_action( 'admin_notices', array( General_Admin_Notices::class, 'activitypub_plugin_not_enabled' ), 10, 0 ); - return; - } - if ( ! version_compare( $this->activitypub_plugin_version, EVENT_BRIDGE_FOR_ACTIVITYPUB_ACTIVITYPUB_PLUGIN_MIN_VERSION, '>=' ) ) { - // The ActivityPub plugin is too old. - \add_action( 'admin_notices', array( General_Admin_Notices::class, 'activitypub_plugin_version_too_old' ), 10, 0 ); - return; - } - if ( empty( $this->active_event_plugins ) ) { - // No supported Event Plugin is active. - \add_action( 'admin_notices', array( General_Admin_Notices::class, 'no_supported_event_plugin_active' ), 10, 0 ); - } - } - - /** - * Add the custom transformers for the events and locations of several WordPress event plugins. - * - * @param \Activitypub\Transformer\Base $transformer The transformer to use. - * @param mixed $data The data to transform. - * @param string $object_class The class of the object to transform. - * - * @return \Activitypub\Transformer\Base|null|\WP_Error - */ - public function register_activitypub_transformer( $transformer, $data, $object_class ) { - // If the current WordPress object is not a post (e.g., a WP_Comment), don't change the transformer. - if ( 'WP_Post' === $object_class ) { - // Get the transformer for a specific event plugins event or location post type. - foreach ( $this->active_event_plugins as $event_plugin ) { - // Check if we have an event. - if ( $data->post_type === $event_plugin->get_post_type() ) { - if ( ! self::is_post_disabled( $data ) ) { - return $event_plugin::get_activitypub_event_transformer( $data ); - } else { - return new \WP_Error( 'invalid_object', __( 'Invalid object', 'event-bridge-for-activitypub' ) ); - } - } - - // Check if we have a location. - if ( $data->post_type === $event_plugin->get_place_post_type() ) { - if ( ! self::is_post_disabled( $data ) ) { - return $event_plugin::get_activitypub_place_transformer( $data ); - } else { - return new \WP_Error( 'invalid_object', __( 'Invalid object', 'event-bridge-for-activitypub' ) ); - } - } - } - } elseif ( 'WP_Term' === $object_class ) { - foreach ( $this->active_event_plugins as $event_plugin ) { - if ( $data->taxonomy === $event_plugin->get_place_taxonomy() ) { - return $event_plugin::get_activitypub_place_transformer( $data ); - } - } - } - - // Return the default transformer. - return $transformer; - } - - /** - * Check if a post of a post type that is managed by this plugin is disabled for ActivityPub. - * - * This function checks the visibility of the post and whether it is private or has a password. - * - * @param mixed $post The post object or ID. - * - * @return boolean True if the post is disabled, false otherwise. - */ - public static function is_post_disabled( $post ): bool { - $post = \get_post( $post ); - $disabled = false; - - if ( ! $post ) { - return true; - } - - $visibility = \get_post_meta( $post->ID, 'activitypub_content_visibility', true ); - - if ( - ACTIVITYPUB_CONTENT_VISIBILITY_LOCAL === $visibility || - ACTIVITYPUB_CONTENT_VISIBILITY_PRIVATE === $visibility || - 'private' === $post->post_status || - ! empty( $post->post_password ) - ) { - $disabled = true; - } - - return $disabled; - } - - /** - * Activates ActivityPub support for all active event plugins event post-types. - * - * @since 1.0.0 - * - * @return void - */ - public function activate_activitypub_support_for_active_event_plugins(): void { - // If someone installs this plugin, we simply enable ActivityPub support for all currently active event post types. - $activitypub_supported_post_types = get_option( 'activitypub_support_post_types', array() ); - foreach ( $this->active_event_plugins as $event_plugin ) { - if ( ! in_array( $event_plugin->get_post_type(), $activitypub_supported_post_types, true ) ) { - $activitypub_supported_post_types[] = $event_plugin->get_post_type(); - add_post_type_support( $event_plugin->get_post_type(), 'activitypub' ); - } - } - \update_option( 'activitypub_support_post_types', $activitypub_supported_post_types ); - } - - /** - * Activates the Event Bridge for ActivityPub plugin. - * - * This method handles the activation of the Event Bridge for ActivityPub plugin. - * - * @since 1.0.0 - * @see register_activation_hook() - * @return void - */ - public function activate(): void { - $this->redetect_active_event_plugins(); - // Don't allow plugin activation, when the ActivityPub plugin is not activated yet. - if ( ! $this->activitypub_plugin_is_active ) { - \deactivate_plugins( plugin_basename( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE ) ); - $notice = General_Admin_Notices::get_admin_notice_activitypub_plugin_not_enabled(); - \wp_die( - // @phpstan-ignore-next-line - wp_kses( $notice, General_Admin_Notices::ALLOWED_HTML ), - 'Plugin dependency check', - array( 'back_link' => true ), - ); - } - - if ( empty( $this->active_event_plugins ) ) { - \deactivate_plugins( plugin_basename( EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_FILE ) ); - $notice = General_Admin_Notices::get_admin_notice_no_supported_event_plugin_active(); - \wp_die( - // @phpstan-ignore-next-line - wp_kses( $notice, General_Admin_Notices::ALLOWED_HTML ), - 'Plugin dependency check', - array( 'back_link' => true ), - ); - } - - self::activate_activitypub_support_for_active_event_plugins(); - } - - /** - * Maybe (depending on active event plugins) make it possible to querly event terms by `?term_id=`. - * - * @return void - */ - private function maybe_register_term_activitypub_ids(): void { - $register_term_query_var = false; - - foreach ( $this->active_event_plugins as $event_plugin ) { - if ( $event_plugin::get_place_taxonomy() ) { - $register_term_query_var = true; - break; - } - } - - if ( $register_term_query_var ) { - \add_filter( 'query_vars', array( self::class, 'add_term_query_var' ) ); - \add_filter( 'activitypub_queried_object', array( $this, 'maybe_detect_event_plugins_location_term' ) ); - } - } - - /** - * Add the 'activitypub' query for term variable so WordPress won't mangle it. - * - * @param array $vars The query variables. - * - * @return array The query variables. - */ - public static function add_term_query_var( $vars ) { - $vars[] = 'term_id'; - - return $vars; - } - - /** - * Filters the queried object. - * - * @param \WP_Term|\WP_Post_Type|\WP_Post|\WP_User|\WP_Comment|null $queried_object The queried object. - */ - public function maybe_detect_event_plugins_location_term( $queried_object ) { - if ( $queried_object ) { - return $queried_object; - } - - $term_id = \get_query_var( 'term_id' ); - - if ( $term_id ) { - $queried_object = \get_term( $term_id ); - } - - if ( $queried_object instanceof \WP_Term && $this->is_place_taxonomy_of_active_event_plugin( $queried_object->taxonomy ) ) { - return $queried_object; - } - - return null; - } - - /** - * Check whether a taxonomy is an active event plugins location taxonomy. - * - * @param string $taxonomy The taxonomy. - * @return boolean - */ - private function is_place_taxonomy_of_active_event_plugin( $taxonomy ): bool { - foreach ( $this->active_event_plugins as $event_plugin ) { - if ( $event_plugin::get_place_taxonomy() === $taxonomy ) { - return true; - } - } - - return false; - } - - /** - * Get the event plugin integration class name used for the event sources feature. - * - * @return ?string The class name of the event plugin integration class. - */ - public static function get_event_plugin_integration_used_for_event_sources_feature(): ?string { - // Get plugin option. - $event_plugin_integration = get_option( - 'event_bridge_for_activitypub_integration_used_for_event_sources_feature', - self::get_default_integration_class_name_used_for_event_sources_feature() - ); - - // Exit if event sources are not active or no plugin is specified. - if ( empty( $event_plugin_integration ) ) { - return null; - } - - // Validate if setting is actual existing class. - if ( ! class_exists( $event_plugin_integration ) ) { - return null; - } - - return $event_plugin_integration; - } - - /** - * Get the transmogrifier class. - * - * Retrieves the appropriate transmogrifier class based on the active event plugins and settings. - * - * @return ?string The transmogrifier class name or null if not available. - */ - public static function get_transmogrifier(): ?string { - $event_plugin_integration = self::get_event_plugin_integration_used_for_event_sources_feature(); - - if ( ! $event_plugin_integration ) { - return null; - } - - // Validate if get_transformer method exists in event plugin integration. - if ( ! method_exists( $event_plugin_integration, 'get_transmogrifier' ) ) { - return null; - } - - $transmogrifier = $event_plugin_integration::get_transmogrifier(); - - return $transmogrifier; - } - - /** - * Get the full class name of the first event plugin integration that is active and supports the event source feature. - * - * @return string The full class name of the event plugin integration. - */ - public static function get_default_integration_class_name_used_for_event_sources_feature(): string { - $setup = self::get_instance(); - - $event_plugin_integrations = $setup->get_active_event_plugins(); - foreach ( $event_plugin_integrations as $event_plugin_integration ) { - if ( $event_plugin_integration instanceof Feature_Event_Sources ) { - return get_class( $event_plugin_integration ); - } - } - return ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/event-categories.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/event-categories.php deleted file mode 100644 index 71232e74..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/event-categories.php +++ /dev/null @@ -1,50 +0,0 @@ - __( 'Arts', 'event-bridge-for-activitypub' ), - 'BOOK_CLUBS' => __( 'Book clubs', 'event-bridge-for-activitypub' ), - 'BUSINESS' => __( 'Business', 'event-bridge-for-activitypub' ), - 'CAUSES' => __( 'Causes', 'event-bridge-for-activitypub' ), - 'COMEDY' => __( 'Comedy', 'event-bridge-for-activitypub' ), - 'CRAFTS' => __( 'Crafts', 'event-bridge-for-activitypub' ), - 'FOOD_DRINK' => __( 'Food & Drink', 'event-bridge-for-activitypub' ), - 'HEALTH' => __( 'Health', 'event-bridge-for-activitypub' ), - 'MUSIC' => __( 'Music', 'event-bridge-for-activitypub' ), - 'AUTO_BOAT_AIR' => __( 'Auto, boat and air', 'event-bridge-for-activitypub' ), - 'COMMUNITY' => __( 'Community', 'event-bridge-for-activitypub' ), - 'FAMILY_EDUCATION' => __( 'Family & Education', 'event-bridge-for-activitypub' ), - 'FASHION_BEAUTY' => __( 'Fashion & Beauty', 'event-bridge-for-activitypub' ), - 'FILM_MEDIA' => __( 'Film & Media', 'event-bridge-for-activitypub' ), - 'GAMES' => __( 'Games', 'event-bridge-for-activitypub' ), - 'LANGUAGE_CULTURE' => __( 'Language & Culture', 'event-bridge-for-activitypub' ), - 'LEARNING' => __( 'Learning', 'event-bridge-for-activitypub' ), - 'LGBTQ' => __( 'LGBTQ', 'event-bridge-for-activitypub' ), - 'MOVEMENTS_POLITICS' => __( 'Movements and politics', 'event-bridge-for-activitypub' ), - 'NETWORKING' => __( 'Networking', 'event-bridge-for-activitypub' ), - 'PARTY' => __( 'Party', 'event-bridge-for-activitypub' ), - 'PERFORMING_VISUAL_ARTS' => __( 'Performing & Visual Arts', 'event-bridge-for-activitypub' ), - 'PETS' => __( 'Pets', 'event-bridge-for-activitypub' ), - 'PHOTOGRAPHY' => __( 'Photography', 'event-bridge-for-activitypub' ), - 'OUTDOORS_ADVENTURE' => __( 'Outdoors & Adventure', 'event-bridge-for-activitypub' ), - 'SPIRITUALITY_RELIGION_BELIEFS' => __( 'Spirituality, Religion & Beliefs', 'event-bridge-for-activitypub' ), - 'SCIENCE_TECH' => __( 'Science & Tech', 'event-bridge-for-activitypub' ), - 'SPORTS' => __( 'Sports', 'event-bridge-for-activitypub' ), - 'THEATRE' => __( 'Theatre', 'event-bridge-for-activitypub' ), - 'MEETING' => __( 'Meeting', 'event-bridge-for-activitypub' ), // Default value in federation. - 'DEFAULT' => __( 'Default', 'event-bridge-for-activitypub' ), // Internal default for overrides. - ), -); diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-event-organiser.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-event-organiser.php deleted file mode 100644 index 7f1b0909..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-event-organiser.php +++ /dev/null @@ -1,109 +0,0 @@ -is_activitypub_request() && defined( 'EVENT_ORGANISER_DIR' ) ) { - $class_path = constant( EVENT_ORGANISER_DIR ) . 'includes/class-eo-theme-compatability.php'; - - if ( file_exists( $class_path ) ) { - require_once $class_path; - - // Remove the theme filter which is not needed in ActivityStreams. - $eo = \EO_Theme_Compatabilty::get_instance(); - if ( $eo instanceof \EO_Theme_Compatabilty ) { - $eo->remove_filter( 'template_include', PHP_INT_MAX - 1 ); - } - } - } - - return new Event_Organiser_Place_Transformer( $term ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-event-plugin-integration.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-event-plugin-integration.php deleted file mode 100644 index 9f73a67c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-event-plugin-integration.php +++ /dev/null @@ -1,132 +0,0 @@ -base && static::get_post_type() === $screen->post_type; - $is_event_plugins_settings_page = in_array( $screen->id, static::get_settings_pages(), true ); - - return $is_event_plugins_edit_page || $is_event_plugins_settings_page; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-eventin.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-eventin.php deleted file mode 100644 index 3624ec81..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-eventin.php +++ /dev/null @@ -1,74 +0,0 @@ -post_type ) { - return new EventPrime_Event_Transformer( $post ); - } - } - - if ( 'venue' === $object_type ) { - $term = get_term( self::get_object_id( $object_type ) ); - if ( $term && self::get_place_taxonomy() === $term->taxonomy ) { - return new EventPrime_Place_Transformer( $term ); - } - } - - return $transformer; - } - - /** - * Determine if the current post is actually just a shortcode Wrapper linking to an EventPrime event. - * - * @param \WP_Post $post The WordPress post object. - * @return string|bool - */ - private static function post_contains_eventprime_object( $post ) { - if ( 'page' !== $post->post_type ) { - return false; - } - - if ( '[em_event]' === $post->post_content || '[em_events]' === $post->post_content ) { - return 'event'; - } - - if ( '[em_sites]' === $post->post_content ) { - return 'venue'; - } - - return false; - } - - /** - * Extract the post id for events and term id for venues for an EventPrime event query. - * - * @param string $type 'event' or 'venue'. - * @return bool|int The post ID, or term ID if found, false otherwise. - */ - private static function get_object_id( $type = 'event' ) { - if ( ! in_array( $type, array( 'venue', 'event' ), true ) ) { - return false; - } - - $event = get_query_var( $type ); - if ( ! $event ) { - if ( ! empty( filter_input( INPUT_GET, $type, FILTER_SANITIZE_FULL_SPECIAL_CHARS ) ) ) { - $event = rtrim( filter_input( INPUT_GET, $type, FILTER_SANITIZE_FULL_SPECIAL_CHARS ), '/\\' ); - } - } - - if ( $event ) { - $ep_basic_functions = new Eventprime_Basic_Functions(); - return $ep_basic_functions->ep_get_id_by_slug( $event, "em_{$type}" ); - } - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-events-manager.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-events-manager.php deleted file mode 100644 index 98bb0a76..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-events-manager.php +++ /dev/null @@ -1,95 +0,0 @@ -get_results( - $wpdb->prepare( - "SELECT DISTINCT {$wpdb->prefix}posts.ID - FROM {$wpdb->prefix}posts - LEFT JOIN {$wpdb->prefix}gatherpress_events - ON {$wpdb->prefix}posts.ID = {$wpdb->prefix}gatherpress_events.post_id - LEFT JOIN {$wpdb->prefix}postmeta - ON {$wpdb->prefix}posts.ID = {$wpdb->prefix}postmeta.post_id - WHERE {$wpdb->prefix}posts.post_type = 'gatherpress_event' - AND {$wpdb->prefix}posts.post_status = 'publish' - AND {$wpdb->prefix}gatherpress_events.datetime_end_gmt <= %s - AND {$wpdb->prefix}postmeta.meta_key = '_event_bridge_for_activitypub_event_source' - ", - $ends_before_time_string - ), - ARRAY_N - ); - - $post_ids = array_column( $results, 0 ); - - return $post_ids; - } - - /** - * Init function: force displaying online event link for federated events. - */ - public static function init(): void { - \add_filter( - 'gatherpress_force_online_event_link', - function ( $force_online_event_link ) { - // Get the current post object. - $post = get_post(); - - // Check if we are in a valid context and the post type is 'gatherpress'. - if ( $post && 'gatherpress_event' === $post->post_type ) { - // Add your custom logic here to decide whether to force the link. - // For example, force it only if a specific meta field exists. - if ( get_post_meta( $post->ID, '_event_bridge_for_activitypub_event_source', true ) ) { - return true; // Force the online event link. - } - } - - return $force_online_event_link; // Default behavior. - }, - 10, - 1 - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-modern-events-calendar-lite.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-modern-events-calendar-lite.php deleted file mode 100644 index 01f1384e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-modern-events-calendar-lite.php +++ /dev/null @@ -1,75 +0,0 @@ -get_main_post_type(). - return 'mec-events'; - } - - /** - * Returns the IDs of the admin pages of the plugin. - * - * @return array The settings page urls. - */ - public static function get_settings_pages(): array { - return array( 'MEC-settings', 'MEC-support', 'MEC-ix', 'MEC-wizard', 'MEC-addons', 'mec-intro' ); - } - - /** - * Returns the taxonomy used for the plugin's event categories. - * - * @return string - */ - public static function get_event_category_taxonomy(): string { - return 'mec_category'; - } - - /** - * Returns the ActivityPub transformer for a Modern_Events_Calendar_Lite event post. - * - * @param \WP_Post $post The WordPress post object of the Event. - * @return Modern_Events_Calendar_Lite_Transformer - */ - public static function get_activitypub_event_transformer( $post ): Modern_Events_Calendar_Lite_Transformer { - return new Modern_Events_Calendar_Lite_Transformer( $post, self::get_event_category_taxonomy() ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-the-events-calendar.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-the-events-calendar.php deleted file mode 100644 index 6fba3bc7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-the-events-calendar.php +++ /dev/null @@ -1,155 +0,0 @@ - - */ - public static function get_cached_remote_events( $ends_before_time ): array { - add_filter( - 'tribe_repository_events_apply_modifier_schema_entry', - array( self::class, 'add_is_activitypub_remote_cached_to_query' ), - 10, - 1 - ); - - $events = tribe_events()->where( 'ends_before', $ends_before_time )->get_ids(); - - remove_filter( - 'tribe_repository_events_apply_modifier_schema_entry', - array( self::class, 'add_is_activitypub_remote_cached_to_query' ) - ); - - return $events; - } - - /** - * Only show remote cached ActivityPub events in Tribe query. - * - * @param array $schema_entry The current schema entry. - * @return array The modified schema entry. - */ - public static function add_is_activitypub_remote_cached_to_query( $schema_entry ) { - $schema_entry['meta_query']['is-remote-cached'] = array( - 'key' => '_event_bridge_for_activitypub_event_source', - 'compare' => 'EXISTS', - ); - return $schema_entry; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-vs-event-list.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-vs-event-list.php deleted file mode 100644 index 443df0e8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-vs-event-list.php +++ /dev/null @@ -1,117 +0,0 @@ - - */ - public static function get_cached_remote_events( $ends_before_time ): array { - $args = array( - 'post_type' => 'event', - 'posts_per_page' => -1, - 'fields' => 'ids', - 'meta_query' => array( - 'relation' => 'AND', - array( - 'key' => '_event_bridge_for_activitypub_event_source', - 'compare' => 'EXISTS', - ), - array( - 'key' => 'event-date', - 'value' => $ends_before_time, - 'type' => 'NUMERIC', - 'compare' => '<', - ), - ), - ); - - $query = new WP_Query( $args ); - - $post_ids = $query->posts; - - return $post_ids; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-wp-event-manager.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-wp-event-manager.php deleted file mode 100644 index 668e4822..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/includes/integrations/class-wp-event-manager.php +++ /dev/null @@ -1,73 +0,0 @@ - \__( 'Event Source', 'event-bridge-for-activitypub' ), - 'plural' => \__( 'Event Sources', 'event-bridge-for-activitypub' ), - 'ajax' => true, - ) - ); - } - - /** - * Get columns. - * - * @return array - */ - public function get_columns(): array { - return array( - 'cb' => '', - 'icon' => \__( 'Icon', 'event-bridge-for-activitypub' ), - 'name' => \__( 'Name', 'event-bridge-for-activitypub' ), - 'accepted' => \__( 'Follow', 'event-bridge-for-activitypub' ), - 'url' => \__( 'URL', 'event-bridge-for-activitypub' ), - 'published' => \__( 'Followed', 'event-bridge-for-activitypub' ), - 'modified' => \__( 'Last updated', 'event-bridge-for-activitypub' ), - ); - } - - /** - * Returns sortable columns. - * - * @return array - */ - public function get_sortable_columns(): array { - return array( - 'name' => array( 'name', true ), - 'modified' => array( 'modified', false ), - 'published' => array( 'published', false ), - ); - } - - /** - * Prepare items. - */ - public function prepare_items(): void { - $columns = $this->get_columns(); - $hidden = array(); - - $this->process_action(); - $this->_column_headers = array( $columns, $hidden, $this->get_sortable_columns() ); - - $page_num = $this->get_pagenum(); - $per_page = 20; - - $args = array(); - - // phpcs:disable WordPress.Security.NonceVerification.Recommended - if ( isset( $_GET['orderby'] ) ) { - $args['orderby'] = sanitize_text_field( wp_unslash( $_GET['orderby'] ) ); - } - - if ( isset( $_GET['order'] ) ) { - $args['order'] = sanitize_text_field( wp_unslash( $_GET['order'] ) ); - } - - if ( isset( $_GET['s'] ) && isset( $_REQUEST['_wpnonce'] ) ) { - $nonce = sanitize_text_field( wp_unslash( $_REQUEST['_wpnonce'] ) ); - if ( wp_verify_nonce( $nonce, 'bulk-' . $this->_args['plural'] ) ) { - $args['s'] = sanitize_text_field( wp_unslash( $_GET['s'] ) ); - } - } - // phpcs:enable WordPress.Security.NonceVerification.Recommended - - $event_sources = Event_Sources_Collection::get_event_sources_with_count( $per_page, $page_num, $args ); - $total_count = $event_sources['total']; - - $this->items = array(); - $this->set_pagination_args( - array( - 'total_items' => $total_count, - 'total_pages' => (int) ceil( $total_count / $per_page ), - 'per_page' => $per_page, - ) - ); - - foreach ( $event_sources['actors'] as $event_source_post_id => $event_source_activitypub_id ) { - $event_source = Event_Source::get_by_id( (int) $event_source_post_id ); - - if ( ! $event_source || ! in_array( $event_source->get_status(), array( 'publish', 'pending' ), true ) ) { - continue; - } - - $item = array( - 'icon' => esc_attr( $event_source->get_icon_url() ), - 'name' => esc_attr( $event_source->get_name() ), - 'url' => esc_attr( $event_source_activitypub_id ), - 'accepted' => esc_attr( get_post_meta( $event_source->get__id(), '_event_bridge_for_activitypub_accept_of_follow', true ) ), - 'identifier' => esc_attr( $event_source_post_id ), - 'published' => esc_attr( $event_source->get_published() ), - 'modified' => esc_attr( $event_source->get_updated() ), - ); - - $this->items[] = $item; - } - } - - /** - * Returns bulk actions. - * - * @return array - */ - public function get_bulk_actions(): array { - return array( - 'delete' => __( 'Delete', 'event-bridge-for-activitypub' ), - ); - } - - /** - * Column default. - * - * @param array $item Item. - * @param string $column_name Column name. - * @return string - */ - public function column_default( $item, $column_name ) { - if ( ! array_key_exists( $column_name, $item ) ) { - return __( 'None', 'event-bridge-for-activitypub' ); - } - return $item[ $column_name ]; - } - - /** - * Column avatar. - * - * @param array $item Item. - * @return string - */ - public function column_icon( $item ): string { - return sprintf( - '', - $item['icon'] - ); - } - - /** - * Column url. - * - * @param array $item Item. - * @return string - */ - public function column_url( $item ): string { - return sprintf( - '%s', - esc_url( $item['url'] ), - $item['url'] - ); - } - - /** - * Column cb. - * - * @param array $item Item. - * @return string - */ - public function column_cb( $item ): string { - return sprintf( '', esc_attr( $item['identifier'] ) ); - } - - /** - * Column action. - * - * @param array $item Item. - * @return string - */ - public function column_accepted( $item ): string { - if ( $item['accepted'] ) { - return esc_html__( 'Accepted', 'event-bridge-for-activitypub' ); - } else { - return esc_html__( 'Pending', 'event-bridge-for-activitypub' ); - } - } - - /** - * Process action. - */ - public function process_action(): void { - if ( ! isset( $_REQUEST['event_sources'] ) || ! isset( $_REQUEST['_wpnonce'] ) ) { - return; - } - $nonce = sanitize_text_field( wp_unslash( $_REQUEST['_wpnonce'] ) ); - if ( ! wp_verify_nonce( $nonce, 'bulk-' . $this->_args['plural'] ) ) { - return; - } - - if ( ! current_user_can( 'manage_options' ) ) { - return; - } - - $event_sources = $_REQUEST['event_sources']; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput - - if ( ! is_array( $event_sources ) ) { - return; - } - - if ( 'delete' === $this->current_action() ) { - foreach ( $event_sources as $event_source ) { - Event_Sources_Collection::remove_event_source( absint( $event_source ) ); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/readme.txt b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/readme.txt deleted file mode 100644 index 1643b052..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/readme.txt +++ /dev/null @@ -1,157 +0,0 @@ -=== Event Bridge for ActivityPub === -Contributors: andremenrath, pfefferle -Tags: events, fediverse, activitypub, calendar -Requires at least: 6.5 -Tested up to: 6.8 -Stable tag: 1.1.0 -Requires PHP: 7.4 -License: AGPL-3.0-or-later -License URI: https://www.gnu.org/licenses/agpl-3.0.html -Integrating popular event plugins with the ActivityPub plugin. - -== Description == - -Make your events more discoverable, expand your reach effortlessly while being independent of other (commercial) platforms, and be a part of the growing decentralized web (the Fediverse). With the Event Bridge for ActivityPub Plugin for WordPress, your events can be automatically followed, aggregated and displayed across decentralized platforms like [Mastodon](https://joinmastodon.org) or [Gancio](https://gancio.org), without any extra work. Forget the hassle of managing multiple social media accounts just to keep your audience informed. - -This plugin is not an event managing plugin but an add-on to popular event plugins. It extends their functionality to fully support the [ActivityPub plugin](https://wordpress.org/plugins/activitypub/). With the ActivityPub plugin people can follow your website directly and engage with your events just as they would on social media: liking, boosting and even commenting if you enable it. You retain full ownership of your content. By integrating into your existing setup, it ensures no extra work is needed while enhancing your events' visibility across the web. - -= Supported Event Plugins = - -Full support (including importing events from the Fediverse): - -* [The Events Calendar](https://de.wordpress.org/plugins/the-events-calendar/) -* [VS Event List](https://de.wordpress.org/plugins/very-simple-event-list/) -* [GatherPress](https://gatherpress.org/) - -Basic support (outgoing events): - -* [Events Manager](https://de.wordpress.org/plugins/events-manager/) -* [WP Event Manager](https://de.wordpress.org/plugins/wp-event-manager/) -* [Eventin](https://de.wordpress.org/plugins/wp-event-solution/) -* [Modern Events Calendar Lite](https://webnus.net/modern-events-calendar/) -* [Event Organiser](https://wordpress.org/plugins/event-organiser/) -* [EventPrime – Events Calendar, Bookings and Tickets](https://wordpress.org/plugins/eventprime-event-calendar-management/) -* [EventON – Events Calendar](https://wordpress.org/plugins/eventon-lite/) - -= How It Works = - -With the Event Bridge for ActivityPub WordPress plugin, sharing your events is effortless and automatic! Once you create an event on your WordPress site, it is seamlessly shared across the decentralized web using the ActivityPub protocol. - -[vimeo https://vimeo.com/1043105544 ] - -Your events can be automatically delivered to platforms that fully support events, such as [Mobilizon](https://joinmobilizon.org/), [Gancio](https://gancio.org), [Friendica](https://friendi.ca), [Hubzilla](https://hubzilla.org), and [Pleroma](https://pleroma.social/). These platforms create public event calendars by pulling in events from various sources, including your website. Any updates you make to your events are synced across these platforms—so you only need to manage your events on your own site, with no extra work required. - -[vimeo https://vimeo.com/1043104445 ] - -Even platforms that don't yet fully support events, like [Mastodon](https://joinmastodon.org), will still receive a detailed, well-composed summary of your event. The Event Federation plugin ensures that users from those platforms are provided with all important information about an event. - -= Features for Your WordPress Events and the Fediverse = - -**ActivityPub-Enabled Event Sharing:** Your WordPress events are now compatible with the Fediverse, using the ActivityStreams format. This means your events can be easily discovered and followed by users on platforms like Mastodon and other ActivityPub-compatible services. - -**Automatic Event Summaries:** When your event is shared on the Fediverse, platforms like Mastodon that don't fully support events will display a brief HTML summary of key details — such as the event's title, start time, and location. This ensures that even if someone can't view the full event on their platform, they still get the important info at a glance, with a link to your WordPress event page. Advanced users can create custom summaries via a set of shortcodes. - -**Improved Event Discoverability:** Your custom event categories are mapped to a set of default categories used in the Fediverse, helping your events reach a wider audience. This improves the chances that users searching for similar events on other platforms will find yours. - -**Event Reminders for Your Followers:** Often, events are planned well in advance. To keep your followers informed right in time, you can set up reminders that are supposed to trigger the events showing up in their timelines right before the event starts. At the moment this reminder is implemented as a self-boost of your original event post. While this feature may behave differently across various platforms, we are working on a more robust solution that will let you schedule dedicated reminder notes that appear in all followers' timelines. - -**External Event Sources:** This functionality is only available for a subset of the supported event plugins. It enables your WordPress site to act as a hub for displaying events from other ActivityPub profiles, aggregating them into a cohesive calendar view. - -== Installation == - -This plugin depends on the [ActivityPub plugin](https://wordpress.org/plugins/activitypub/). Additionally, you need to use one of the supported event Plugins. - -= Supported Event Plugins = - -Full support (including importing events from the Fediverse): - -* [The Events Calendar](https://de.wordpress.org/plugins/the-events-calendar/) -* [VS Event List](https://de.wordpress.org/plugins/very-simple-event-list/) -* [GatherPress](https://gatherpress.org/) - -Basic support (outgoing events): - -* [Events Manager](https://de.wordpress.org/plugins/events-manager/) -* [WP Event Manager](https://de.wordpress.org/plugins/wp-event-manager/) -* [Eventin](https://de.wordpress.org/plugins/wp-event-solution/) -* [Modern Events Calendar Lite](https://webnus.net/modern-events-calendar/) -* [Event Organiser](https://wordpress.org/plugins/event-organiser/) -* [EventPrime – Events Calendar, Bookings and Tickets](https://wordpress.org/plugins/eventprime-event-calendar-management/) - -= Configuration = - -If you're new to the [ActivityPub plugin](https://wordpress.org/plugins/activitypub/), it's recommended to spend a few minutes reading through its documentation to familiarize yourself with its setup and functionality. - -== Frequently Asked Questions == - -= Do I need to install another event plugin to use the Event Federation Plugin? = - -Yes, this plugin works as an add-on and requires both the ActivityPub plugin and a supported event plugin such as The Events Calendar, VS Event List, or Events Manager to manage your events. It just fills the missing gap between event plugins and the [ActivityPub plugin](https://wordpress.org/plugins/activitypub/). - -= What platforms can follow my events? = - -Your events can be followed on platforms that support ActivityPub like [Mobilizon](https://joinmobilizon.org/), [Gancio](https://gancio.org), [Friendica](https://friendi.ca), [Hubzilla](https://hubzilla.org), and [Pleroma](https://pleroma.social/). Even other applications like [Mastodon](https://joinmastodon.org), which don't fully support events yet, will display all important information about the events. - -= Why does Mastodon not show any updates? == - -Mastodon does not yet handle updates of `Event` objects. See the related tracking issue [#31114](https://github.com/mastodon/mastodon/issues/31114). - -= How much extra work is required to maintain my events across the decentralized Web? = - -None! Once the plugin is set up, your events are automatically sent to all connected platforms or account that follow you (your Website). Any updates you make to your events are synced without additional effort. - -= Can I still use social media to promote my events? = - -Yes, you can still use traditional social media if you wish. However, this plugin helps reduce reliance on commercial platforms by connecting your events to the decentralized Fediverse. - -= Will this plugin work if I don't use the ActivityPub plugin? = - -No, the Event Federation Plugin depends on the [ActivityPub plugin](https://wordpress.org/plugins/activitypub/) to deliver your events across decentralized platforms, so it's essential to have it installed and configured. - -= My event plugin is not supported, what can I do? = - -If you know about coding have a look at the documentation of how to add your plugin or open an [issue](https://codeberg.org/Event-Federation/wordpress-event-bridge-for-activitypub/issues), if we can spare some free hours we might add it. - -= What if I experience problems? = - -We're always interested in your feedback. Feel free to reach out to us via [E-Mail](https://event-federation.eu/contact/) or create an [issue](https://codeberg.org/Event-Federation/wordpress-event-bridge-for-activitypub/issues). - -== Acknowledgement == - -The development of this WordPress plugin was funded through the [NGI0 Entrust](https://NLnet.nl/entrust) Fund, a fund established by [NLnet](https://nlnet.nl) with financial support from the European Commission's [Next Generation Internet](https://ngi.eu) programme, under the aegis of [Communications Networks, Content and Technology](https://commission.europa.eu/about-european-commission/departments-and-executive-agencies/communications-networks-content-and-technology_en) under grant agreement number 101069594. - -== Changelog == - -= [1.1.0] - 2025-04-12 = - -* Added: Basic support for Starter Kits -* Fixed: Uncatched error in following process (issue #145) -* Fixed: Compatibility with ActivityPub plugin version 5.7.0 - -= [1.0.0] - 2025-02-11 = - -* Added: Support for the EventPrime event plugin -* Added: Event self-announce feature at configurable time before event starts -* Added: Blueprint (Preview via WordPress Playground) -* Added: Event Sources feature: cache and list events from remote ActivityPub profiles on your site -* Added: Custom ActivityPub preview -* Added: Admin setting to enfore sending summary of events as plain text -* Changed: Now depends on ActivityPub plugin version greater than 5.1.0 -* Fixed: The Events Calendar date times when using the Gutenberg editor -* Fixed: Improved admin UI for event-category mapping - -= [0.3.5] - 2025-01-03 = - -* Fixed: Images of Acknowledgements in Admin UI - -= [0.3.4] - 2024-12-21 = - -* Initial release on https://wordpress.org/ - -== Contributing == - -This plugin is free software, and contributions of all kinds are welcome! Whether it's reporting issues, submitting improvements, or suggesting new features, your input helps make the plugin better for everyone. - -Please review our [Contribution Guidelines](https://codeberg.org/Event-Federation/wordpress-event-bridge-for-activitypub/src/branch/main/CONTRIBUTING.md) to get started. The source code is hosted on [Codeberg](https://codeberg.org/Event-Federation/wordpress-event-bridge-for-activitypub), where you can open issues and submit pull requests. - -Thank you for contributing! diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/event-preview.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/event-preview.php deleted file mode 100644 index 001c0f0d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/event-preview.php +++ /dev/null @@ -1,1510 +0,0 @@ -get_error_message() ), - 404 - ); -} - -if ( $transformer instanceof Event ) { - $object = $transformer->to_object(); - $user = $transformer->get_actor_object(); - $address = $transformer->get_formatted_address(); - $location = $transformer->get_location(); - if ( $location ) { - $location_name = $location->get_name(); - } else { - $location_name = ''; - } -} else { - \wp_die( - 'Wrong ActivityPub preview template.', - 404 - ); -} - -$first_image_attachment = null; - -?> - - - - - <?php echo \esc_html( $object->get_name() ); ?>HUU - - - -
    -

    - -
    - - -
    -
    -
    -
    -
    -
    - <?php echo \esc_attr( isset( $first_image_attachment['name'] ) ? $first_image_attachment['name'] : '' ); ?> -
    -
    -
    -
    -
    -
    -
    - -
    -
    - - -
    -
    -
    -
    -
    -
    - - -
    -
    -
    -
    -
    -
    -

    get_name() ); ?>

    -
    - - - -
    -
    - -

    - -

    - - -

    - get_tag() as $hashtag ) : ?> - - - - - - - -

    - -
    -
    -
    -
    -
    - - - -
    -
    -
    - - -
    -
    -
    -
    -
    -
    - -
    -
    -

    - - -
    -
    - get_content(), ACTIVITYPUB_MASTODON_HTML_SANITIZER ); ?> -
    -
    -
    -
    -
    - -

    -
    -
    - -
    -
    - - - -

    - -

    -

    -
    -
    -
    -
    -
    -
    - - -
    -
    -
    - - - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/menu.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/menu.php deleted file mode 100644 index b4e333fd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/menu.php +++ /dev/null @@ -1,45 +0,0 @@ - '', - 'settings' => '', - 'event-sources' => '', - ) -); -?> - -
    - - - -
    - - 'active', - ) -); - -if ( ! current_user_can( 'manage_options' ) ) { - return; -} - -$activitypub_plugin_is_active = Setup::get_instance()->is_activitypub_plugin_active(); - -\get_option( 'event_bridge_for_activitypub_event_sources_active', false ); - -if ( ! isset( $args ) || ! array_key_exists( 'supports_event_sources', $args ) ) { - return; -} - -$event_plugins_supporting_event_sources = $args['supports_event_sources']; - -$event_sources_active = \get_option( 'event_bridge_for_activitypub_event_sources_active', false ); -$cache_retention_period = \get_option( 'event_bridge_for_activitypub_event_source_cache_retention', DAY_IN_SECONDS ); - -?> - -
    -
    - -
    -

    -

    - - - - - - - - - - - - - - - - - - -
    - - - - > -
    - - - -

    -
    - - - -

    -
    - -

    -

    - '; - foreach ( $plugins_supporting_event_sources as $event_plugin ) { - echo '
  • ' . esc_attr( $event_plugin->get_plugin_name() ) . '
  • '; - } - echo ''; - } else { - $activitypub_plugin_data = \get_plugin_data( ACTIVITYPUB_PLUGIN_FILE ); - - $notice = sprintf( - /* translators: 1: The name of the ActivityPub plugin. */ - _x( - 'In order to use this feature your have to enable the Blog-Actor in the the %2$s settings.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - \admin_url( 'options-general.php?page=activitypub&tab=event-bridge-for-activitypub&subpage=settings' ), - \esc_html( $activitypub_plugin_data['Name'] ) - ); - - $allowed_html = array( - 'a' => array( - 'href' => true, - 'title' => true, - ), - ); - echo '

    ' . \wp_kses( $notice, $allowed_html ) . '

    '; - } - ?> -
    - -
    -
    -
    -
    - - - -
    - -
    -

    - - - - -
    -
    - - - - prepare_items(); - $table->search_box( 'Search', 'search' ); - $table->display(); - ?> -
    -
    - -
    - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/subpages/settings.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/subpages/settings.php deleted file mode 100644 index 60106358..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/subpages/settings.php +++ /dev/null @@ -1,229 +0,0 @@ - 'active', - ) -); - -$activitypub_plugin_is_active = Setup::get_instance()->is_activitypub_plugin_active(); - -if ( ! isset( $args ) || ! array_key_exists( 'event_terms', $args ) ) { - return; -} - -if ( ! current_user_can( 'manage_options' ) ) { - return; -} - -$event_terms = $args['event_terms']; - -require_once EVENT_BRIDGE_FOR_ACTIVITYPUB_PLUGIN_DIR . '/includes/event-categories.php'; - -$selected_default_event_category = \get_option( 'event_bridge_for_activitypub_default_event_category', 'MEETING' ); -$current_category_mapping = \get_option( 'event_bridge_for_activitypub_event_category_mappings', array() ); -$reminder_time_gap = \get_option( 'event_bridge_for_activitypub_reminder_time_gap', 0 ); - -$reminder_time_gap_choices = array( - 0 => __( 'Disabled', 'event-bridge-for-activitypub' ), - HOUR_IN_SECONDS * 6 => __( '6 hours', 'event-bridge-for-activitypub' ), - DAY_IN_SECONDS => __( '1 day', 'event-bridge-for-activitypub' ), - DAY_IN_SECONDS * 3 => __( '3 days', 'event-bridge-for-activitypub' ), - WEEK_IN_SECONDS => __( '1 week', 'event-bridge-for-activitypub' ), -); - -if ( \get_option( 'event_bridge_for_activitypub_initially_activated' ) ) { - \update_option( 'event_bridge_for_activitypub_initially_activated', '' ); -} -?> - -
    -
    - -
    -

    -

    - - - - - - - - - - - -
    - - -

    - -

    -

    - -

    -
    - -
    - -
    -
    -
    [ap_start_time icon="true" label="true"]
    -
    -
    [ap_end_time icon="true" label="true"]
    -
    -
    [ap_location icon="true" label="true"]
    -
    -
    [ap_hashtags]
    -
    -
    [ap_excerpt]
    -
    -
    [ap_content]
    -
    -
    -
    -
    -
    -
    - - -

    - /> - - array(), - ); - echo \wp_kses( __( 'Many Fediverse applications, including Mastodon before version 4.3.0, do not render summaries as HTML. Enable this option to send the summary as plain text for better compatibility (e.g., <ul><li>Item 1</li></ul> will be sent as \'Item 1\' without formatting).', 'event-bridge-for-activitypub' ), $allowed_html ); - ?> - -

    -
    -
    - -
    -

    -

    - - - - - -
    - - - -
    - - -

    -

    - - - - - - - - - - - - -
    - - -
    - -
    -
    -

    -

    - - - - - - -
    - -

    - -
    -
    - - - -
    -
    diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/subpages/welcome.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/subpages/welcome.php deleted file mode 100644 index c5456cec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/subpages/welcome.php +++ /dev/null @@ -1,250 +0,0 @@ - 'active', - ) -); - -$active_event_plugins = Setup::get_instance()->get_active_event_plugins(); -$activitypub_plugin_is_active = Setup::get_instance()->is_activitypub_plugin_active(); -$event_bridge_for_activitypub_status_ok = true; -$example_event_post = Health_Check::get_most_recent_event_posts(); - -if ( empty( $example_event_post ) ) { - $example_event_post = 'https://yoursite.com/events/event-name'; - $example_event_post_is_dummy = true; -} else { - $example_event_post = \get_permalink( $example_event_post[0] ); - $example_event_post_is_dummy = false; -} - -global $wp_filesystem; -WP_Filesystem(); - -?> - -
    -
    -

    -

    - ⚠' . \wp_kses( $notice, General_Admin_Notices::ALLOWED_HTML ) . '

    '; - } elseif ( empty( $active_event_plugins ) ) { - $notice = General_Admin_Notices::get_admin_notice_no_supported_event_plugin_active(); - echo '

    ⚠' . \wp_kses( $notice, General_Admin_Notices::ALLOWED_HTML ) . '

    '; - } - ?> - -

    get_plugin_name() ); ?>:

    -
      -
    • - %2$s is enabled in the %1$s settings.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_html( get_plugin_data( ACTIVITYPUB_PLUGIN_FILE )['Name'] ), - esc_html( $active_event_plugin->get_plugin_name() ), - admin_url( 'options-general.php?page=activitypub&tab=event-bridge-for-activitypub&subpage=settings' ) - ); - } else { - $event_bridge_for_activitypub_status_ok = false; - echo '❌ '; - $status_message_post_type_enabled = sprintf( - /* translators: 1: the name of the event plugin a admin notice is shown. 2: The name of the ActivityPub plugin. */ - _x( - 'The post type for events of the plugin %2$s is not enabled in the %1$s settings.', - 'admin notice', - 'event-bridge-for-activitypub' - ), - esc_html( get_plugin_data( ACTIVITYPUB_PLUGIN_FILE )['Name'] ), - esc_html( $active_event_plugin->get_plugin_name() ), - admin_url( 'options-general.php?page=activitypub&tab=event-bridge-for-activitypub&subpage=settings' ) - ); - } - $allowed_html = array( - 'a' => array( - 'href' => true, - 'title' => true, - ), - 'b' => array(), - 'i' => array(), - ); - echo \wp_kses( $status_message_post_type_enabled, $allowed_html ); - ?> -
    • -
    • - -
    • -
    - -
    - - - - - - - - -
    -

    -

    ' . \esc_html__( 'Please fix the status issues above first.', 'event-bridge-for-activitypub' ) . '

    '; - } - ?> -

    -
    -

    - -

    - -

    - -

    - -

    - -

    - -

    - -

    - -
    -
    - -
    -

    -

    Logo NLnet: abstract logo of four people seen from above Logo NGI Zero: letterlogo shaped like a tag

    -

    The development of this plugin was funded through the NGI0 Entrust Fund, a fund established by NLnet with financial support from the European Commission's Next Generation Internet programme, under the aegis of DG Communications Networks, Content and Technology under grant agreement No 101069594.

    -
    - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/tab.php b/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/tab.php deleted file mode 100644 index 753c1b8a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/event-bridge-for-activitypub/templates/settings/tab.php +++ /dev/null @@ -1,13 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -function gitium_error_log( $message ) { - if ( ! defined( 'WP_DEBUG' ) || ! WP_DEBUG ) { return; } - error_log( "gitium_error_log: $message" ); -} - -function wp_content_is_versioned() { - return file_exists( WP_CONTENT_DIR . '/.git' ); -} - -if ( ! function_exists( 'gitium_enable_maintenance_mode' ) ) : - function gitium_enable_maintenance_mode() { - $file = ABSPATH . '/.maintenance'; - - if ( false === file_put_contents( $file, 'set_key( $git_private_key ); - - $git->add( $dir ); - gitium_update_versions(); - $current_user = wp_get_current_user(); - return $git->commit( $message, $current_user->display_name, $current_user->user_email ); -} - -function _gitium_format_message( $name, $version = false, $prefix = '' ) { - $commit_message = "`$name`"; - if ( $version ) { - $commit_message .= " version $version"; - } - if ( $prefix ) { - $commit_message = "$prefix $commit_message"; - } - return $commit_message; -} - -/** - * This function return the basic info about a path. - * - * base_path - means the path after wp-content dir (themes/plugins) - * type - can be file/theme/plugin - * name - the file name of the path, if it is a file, or the theme/plugin name - * version - the theme/plugin version, othewise null - */ -/* Some examples: - - with 'wp-content/themes/twentyten/style.css' will return: - array( - 'base_path' => 'wp-content/themes/twentyten' - 'type' => 'theme' - 'name' => 'TwentyTen' - 'version' => '1.12' - ) - - with 'wp-content/themes/twentyten/img/foo.png' will return: - array( - 'base_path' => 'wp-content/themes/twentyten' - 'type' => 'theme' - 'name' => 'TwentyTen' - 'version' => '1.12' - ) - - with 'wp-content/plugins/foo.php' will return: - array( - 'base_path' => 'wp-content/plugins/foo.php' - 'type' => 'plugin' - 'name' => 'Foo' - 'varsion' => '2.0' - ) - - with 'wp-content/plugins/autover/autover.php' will return: - array( - 'base_path' => 'wp-content/plugins/autover' - 'type' => 'plugin' - 'name' => 'autover' - 'version' => '3.12' - ) - - with 'wp-content/plugins/autover/' will return: - array( - 'base_path' => 'wp-content/plugins/autover' - 'type' => 'plugin' - 'name' => 'autover' - 'version' => '3.12' - ) -*/ -function _gitium_module_by_path( $path ) { - $versions = gitium_get_versions(); - - // default values - $module = array( - 'base_path' => $path, - 'type' => 'file', - 'name' => basename( $path ), - 'version' => null, - ); - - // find the base_path - $split_path = explode( '/', $path ); - if ( 2 < count( $split_path ) ) { - $module['base_path'] = "{$split_path[0]}/{$split_path[1]}/{$split_path[2]}"; - } - - // find other data for theme - if ( array_key_exists( 'themes', $versions ) && 0 === strpos( $path, 'wp-content/themes/' ) ) { - $module['type'] = 'theme'; - foreach ( $versions['themes'] as $theme => $data ) { - if ( 0 === strpos( $path, "wp-content/themes/$theme" ) ) { - $module['name'] = $data['name']; - $module['version'] = $data['version']; - break; - } - } - } - - // find other data for plugin - if ( array_key_exists( 'plugins', $versions ) && 0 === strpos( $path, 'wp-content/plugins/' ) ) { - $module['type'] = 'plugin'; - foreach ( $versions['plugins'] as $plugin => $data ) { - if ( '.' === dirname( $plugin ) ) { // single file plugin - if ( "wp-content/plugins/$plugin" === $path ) { - $module['base_path'] = $path; - $module['name'] = $data['name']; - $module['version'] = $data['version']; - break; - } - } else if ( 'wp-content/plugins/' . dirname( $plugin ) === $module['base_path'] ) { - $module['name'] = $data['name']; - $module['version'] = $data['version']; - break; - } - } - } - - return $module; -} - -function gitium_group_commit_modified_plugins_and_themes( $msg_append = '' ) { - global $git; - - $uncommited_changes = $git->get_local_changes(); - $commit_groups = array(); - $commits = array(); - - if ( ! empty( $msg_append ) ) { - $msg_append = "($msg_append)"; - } - foreach ( $uncommited_changes as $path => $action ) { - $change = _gitium_module_by_path( $path ); - $change['action'] = $action; - $commit_groups[ $change['base_path'] ] = $change; - } - - foreach ( $commit_groups as $base_path => $change ) { - $commit_message = _gitium_format_message( $change['name'], $change['version'], "{$change['action']} {$change['type']}" ); - $commit = _gitium_commit_changes( "$commit_message $msg_append", $base_path, false ); - if ( $commit ) { - $commits[] = $commit; - } - } - - return $commits; -} - -function gitium_commit_and_push_gitignore_file( $path = '' ) { - global $git; - - $current_user = wp_get_current_user(); - if ( ! empty( $path ) ) { $git->rm_cached( $path ); } - $git->add( '.gitignore' ); - $commit = $git->commit( 'Update the `.gitignore` file', $current_user->display_name, $current_user->user_email ); - gitium_merge_and_push( $commit ); -} - -if ( ! function_exists( 'gitium_acquire_merge_lock' ) ) : - function gitium_acquire_merge_lock() { - $gitium_lock_path = apply_filters( 'gitium_lock_path', sys_get_temp_dir().'/.gitium-lock' ); - $gitium_lock_handle = fopen( $gitium_lock_path, 'w+' ); - - $lock_timeout = intval( ini_get( 'max_execution_time' ) ) > 10 ? intval( ini_get( 'max_execution_time' ) ) - 5 : 10; - $lock_timeout_ms = 10; - $lock_retries = 0; - while ( ! flock( $gitium_lock_handle, LOCK_EX | LOCK_NB ) ) { - usleep( $lock_timeout_ms * 1000 ); - $lock_retries++; - if ( $lock_retries * $lock_timeout_ms > $lock_timeout * 1000 ) { - return false; // timeout - } - } - gitium_error_log( __FUNCTION__ ); - return array( $gitium_lock_path, $gitium_lock_handle ); - } -endif; - -if ( ! function_exists( 'gitium_release_merge_lock' ) ) : - function gitium_release_merge_lock( $lock ) { - list( $gitium_lock_path, $gitium_lock_handle ) = $lock; - gitium_error_log( __FUNCTION__ ); - flock( $gitium_lock_handle, LOCK_UN ); - fclose( $gitium_lock_handle ); - } -endif; - -// Merges the commits with remote and pushes them back -function gitium_merge_and_push( $commits ) { - global $git; - - $lock = gitium_acquire_merge_lock() - or trigger_error( 'Timeout when gitium lock was acquired', E_USER_WARNING ); - - if ( ! $git->fetch_ref() ) { - return false; - } - - $merge_status = $git->merge_with_accept_mine( $commits ); - - gitium_release_merge_lock( $lock ); - - return $git->push() && $merge_status; -} - -function gitium_check_after_event( $plugin, $event = 'activation' ) { - global $git; - - if ( 'gitium/gitium.php' == $plugin ) { return; } // do not hook on activation of this plugin - - if ( $git->is_dirty() ) { - $versions = gitium_update_versions(); - if ( isset( $versions['plugins'][ $plugin ] ) ) { - $name = $versions['plugins'][ $plugin ]['name']; - $version = $versions['plugins'][ $plugin ]['version']; - } else { - $name = $plugin; - } - gitium_auto_push( _gitium_format_message( $name, $version, "after $event of" ) ); - } -} - -function gitium_update_remote_tracking_branch() { - global $git; - $remote_branch = $git->get_remote_tracking_branch(); - set_transient( 'gitium_remote_tracking_branch', $remote_branch ); - - return $remote_branch; -} - -function _gitium_get_remote_tracking_branch( $update_transient = false ) { - if ( ! $update_transient && ( false !== ( $remote_branch = get_transient( 'gitium_remote_tracking_branch' ) ) ) ) { - return $remote_branch; - } else { - return gitium_update_remote_tracking_branch(); - } -} - -function gitium_update_is_status_working() { - global $git; - $is_status_working = $git->is_status_working(); - set_transient( 'gitium_is_status_working', $is_status_working ); - return $is_status_working; -} - -function _gitium_is_status_working( $update_transient = false ) { - if ( ! $update_transient && ( false !== ( $is_status_working = get_transient( 'gitium_is_status_working' ) ) ) ) { - return $is_status_working; - } else { - return gitium_update_is_status_working(); - } -} - -function _gitium_status( $update_transient = false ) { - global $git; - - if ( ! $update_transient && ( false !== ( $changes = get_transient( 'gitium_uncommited_changes' ) ) ) ) { - return $changes; - } - - $git_version = get_transient( 'gitium_git_version' ); - if ( false === $git_version ) { - set_transient( 'gitium_git_version', $git->get_version() ); - } - - if ( $git->is_status_working() && $git->get_remote_tracking_branch() ) { - if ( ! $git->fetch_ref() ) { - set_transient( 'gitium_remote_disconnected', $git->get_last_error() ); - } else { - delete_transient( 'gitium_remote_disconnected' ); - } - $changes = $git->status(); - } else { - delete_transient( 'gitium_remote_disconnected' ); - $changes = array(); - } - - set_transient( 'gitium_uncommited_changes', $changes, 12 * 60 * 60 ); // cache changes for half-a-day - return $changes; -} - -function _gitium_ssh_encode_buffer( $buffer ) { - $len = strlen( $buffer ); - if ( ord( $buffer[0] ) & 0x80 ) { - $len++; - $buffer = "\x00" . $buffer; - } - return pack( 'Na*', $len, $buffer ); -} - -function _gitium_generate_keypair() { - $rsa_key = openssl_pkey_new( - array( - 'private_key_bits' => 2048, - 'private_key_type' => OPENSSL_KEYTYPE_RSA, - ) - ); - - try { - $private_key = openssl_pkey_get_private( $rsa_key ); - $try = openssl_pkey_export( $private_key, $pem ); //Private Key - if (!$try) - return false; - } catch (Exception $e) { - return false; - } - - $key_info = openssl_pkey_get_details( $rsa_key ); - $buffer = pack( 'N', 7 ) . 'ssh-rsa' . - _gitium_ssh_encode_buffer( $key_info['rsa']['e'] ) . - _gitium_ssh_encode_buffer( $key_info['rsa']['n'] ); - $public_key = 'ssh-rsa ' . base64_encode( $buffer ) . ' gitium@' . parse_url( get_home_url(), PHP_URL_HOST ); - - return array( $public_key, $pem ); -} - -function gitium_get_keypair( $generate_new_keypair = false ) { - if ( $generate_new_keypair ) { - $keypair = _gitium_generate_keypair(); - delete_option( 'gitium_keypair' ); - add_option( 'gitium_keypair', $keypair, '', false ); - } - if ( false === ( $keypair = get_option( 'gitium_keypair', false ) ) ) { - $keypair = _gitium_generate_keypair(); - add_option( 'gitium_keypair', $keypair, '', false ); - } - return $keypair; -} - -function _gitium_generate_webhook_key() { - return md5( str_shuffle( 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789.()[]{}-_=+!@#%^&*~<>:;' ) ); -} - -function gitium_get_webhook_key( $generate_new_webhook_key = false ) { - if ( $generate_new_webhook_key ) { - $key = _gitium_generate_webhook_key(); - delete_option( 'gitium_webhook_key' ); - add_option( 'gitium_webhook_key', $key, '', false ); - return $key; - } - if ( false === ( $key = get_option( 'gitium_webhook_key', false ) ) ) { - $key = _gitium_generate_webhook_key(); - add_option( 'gitium_webhook_key', $key, '', false ); - } - return $key; -} - -function gitium_get_webhook() { - if ( defined( 'GIT_WEBHOOK_URL' ) && GIT_WEBHOOK_URL ) { return GIT_WEBHOOK_URL; } - $key = gitium_get_webhook_key(); - $url = add_query_arg( 'key', $key, plugins_url( 'gitium-webhook.php', __FILE__ ) ); - return apply_filters( 'gitium_webhook_url', $url, $key ); -} - -function gitium_admin_init() { - global $git; - - $git_version = get_transient( 'gitium_git_version' ); - if ( false === $git_version ) { - set_transient( 'gitium_git_version', $git->get_version() ); - } -} -add_action( 'admin_init', 'gitium_admin_init' ); - -add_action('admin_enqueue_scripts', 'enqueue_script_for_gitium_page'); -function enqueue_script_for_gitium_page($hook) { - // Check if the current page is your plugin's settings page - if ((isset($_GET['page']) && $_GET['page'] === 'gitium/gitium.php') || (isset($_GET['page']) && $_GET['page'] === 'gitium/gitium-settings.php')) { - // Enqueue your JavaScript file - wp_enqueue_script( - 'my-plugin-script', // Handle for the script - plugin_dir_url(__FILE__) . 'js/copy-to-clipboard.js', // URL to the script - array('jquery'), // Dependencies - '1.1', // Version number - true // Load in footer - ); - } -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/gitium-webhook.php b/wp-content/upgrade-temp-backup/plugins/gitium/gitium-webhook.php deleted file mode 100644 index 47b82b06..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/gitium-webhook.php +++ /dev/null @@ -1,81 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -header( 'Content-Type: text/html' ); -define( 'SHORTINIT', true ); - -$current_dir = __DIR__; - -// Define an array of possible WordPress root locations -$try_wp_roots = [ - getenv('DOCUMENT_ROOT'), - filter_input(INPUT_SERVER, 'DOCUMENT_ROOT', FILTER_SANITIZE_FULL_SPECIAL_CHARS), - realpath($current_dir . '/../../../../../'), - realpath($current_dir . '/../../../../'), - realpath($current_dir . '/../../../'), // Typical WordPress structure - realpath($current_dir . '/../../'), // Alternative structure - realpath($current_dir . '/../'), // Closer parent directory - $current_dir, // Fallback to current directory -]; - -$wordpress_loader = null; - -foreach ($try_wp_roots as $root) { - if ($root && file_exists($root . '/wp-load.php')) { - $wordpress_loader = $root . '/wp-load.php'; - break; - } -} - -if ($wordpress_loader) { - require_once $wordpress_loader; -} else { - die('Error: Unable to locate wp-load.php. Please verify your WordPress installation.'); -} - -require_once __DIR__ . '/functions.php'; -require_once __DIR__ . '/inc/class-git-wrapper.php'; - -$webhook_key = get_option( 'gitium_webhook_key', '' ); -$get_key = filter_input(INPUT_GET, 'key', FILTER_SANITIZE_FULL_SPECIAL_CHARS); -if ( ! empty ( $webhook_key ) && isset( $get_key ) && $webhook_key == $get_key ) : - ( '1.7' <= substr( $git->get_version(), 0, 3 ) ) or wp_die( 'Gitium plugin require minimum `git version 1.7`!' ); - - list( $git_public_key, $git_private_key ) = gitium_get_keypair(); - if ( ! $git_public_key || ! $git_private_key ) - wp_die('Not ready.', 'Not ready.', array( 'response' => 403 )); - else - $git->set_key( $git_private_key ); - - $commits = array(); - $commitmsg = sprintf( 'Merged changes from %s on %s', $_SERVER['SERVER_NAME'], date( 'm.d.Y' ) ); - - if ( $git->is_dirty() && $git->add() > 0 ) { - $commits[] = $git->commit( $commitmsg ) or trigger_error( 'Could not commit local changes!', E_USER_ERROR ); - } - gitium_merge_and_push( $commits ) or trigger_error( 'Failed merge & push: ' . serialize( $git->get_last_error() ), E_USER_ERROR ); - - wp_die( $commitmsg , 'Pull done!', array( 'response' => 200 ) ); -else : - wp_die( 'Cheating uh?', 'Cheating uh?', array( 'response' => 403 ) ); -endif; diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/gitium.php b/wp-content/upgrade-temp-backup/plugins/gitium/gitium.php deleted file mode 100644 index e253488f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/gitium.php +++ /dev/null @@ -1,380 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -define( 'GITIUM_LAST_COMMITS', 20 ); -define( 'GITIUM_MIN_GIT_VER', '1.7' ); -define( 'GITIUM_MIN_PHP_VER', '5.6' ); - -if ( is_multisite() ) { - define( 'GITIUM_ADMIN_MENU_ACTION', 'network_admin_menu' ); - define( 'GITIUM_ADMIN_NOTICES_ACTION', 'network_admin_notices' ); - define( 'GITIUM_MANAGE_OPTIONS_CAPABILITY', 'manage_network_options' ); -} else { - define( 'GITIUM_ADMIN_MENU_ACTION', 'admin_menu' ); - define( 'GITIUM_ADMIN_NOTICES_ACTION', 'admin_notices' ); - define( 'GITIUM_MANAGE_OPTIONS_CAPABILITY', 'manage_options' ); -} - -require_once __DIR__ . '/functions.php'; -require_once __DIR__ . '/inc/class-git-wrapper.php'; -require_once __DIR__ . '/inc/class-gitium-requirements.php'; -require_once __DIR__ . '/inc/class-gitium-admin.php'; -require_once __DIR__ . '/inc/class-gitium-help.php'; -require_once __DIR__ . '/inc/class-gitium-menu.php'; -require_once __DIR__ . '/inc/class-gitium-menu-bubble.php'; -require_once __DIR__ . '/inc/class-gitium-submenu-configure.php'; -require_once __DIR__ . '/inc/class-gitium-submenu-status.php'; -require_once __DIR__ . '/inc/class-gitium-submenu-commits.php'; -require_once __DIR__ . '/inc/class-gitium-submenu-settings.php'; - -function gitium_load_textdomain() { - load_plugin_textdomain( 'gitium', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' ); -} -add_action( 'plugins_loaded', 'gitium_load_textdomain' ); - -function _gitium_make_ssh_git_file_exe() { - $ssh_wrapper = dirname( __FILE__ ) . '/inc/ssh-git'; - $process = proc_open( - "chmod -f +x $ssh_wrapper", - array( - 0 => array( 'pipe', 'r' ), // stdin - 1 => array( 'pipe', 'w' ), // stdout - ), - $pipes - ); - if ( is_resource( $process ) ) { - fclose( $pipes[0] ); - proc_close( $process ); - } -} -register_activation_hook( __FILE__, '_gitium_make_ssh_git_file_exe' ); - -function gitium_deactivation() { - delete_transient( 'gitium_git_version' ); -} -register_deactivation_hook( __FILE__, 'gitium_deactivation' ); - -function gitium_uninstall_hook() { - delete_transient( 'gitium_remote_tracking_branch' ); - delete_transient( 'gitium_remote_disconnected' ); - delete_transient( 'gitium_uncommited_changes' ); - delete_transient( 'gitium_git_version' ); - delete_transient( 'gitium_versions' ); - delete_transient( 'gitium_menu_bubble' ); - delete_transient( 'gitium_is_status_working' ); - - delete_option( 'gitium_keypair' ); - delete_option( 'gitium_webhook_key' ); -} -register_uninstall_hook( __FILE__, 'gitium_uninstall_hook' ); - -/* Array -( - [themes] => Array - ( - [twentytwelve] => `Twenty Twelve` version 1.3 - ) - [plugins] => Array - ( - [cron-view/cron-gui.php] => `Cron GUI` version 1.03 - [hello-dolly/hello.php] => `Hello Dolly` version 1.6 - ) - -) */ -function gitium_update_versions() { - $new_versions = []; - - // get all themes from WP - $all_themes = wp_get_themes( array( 'allowed' => true ) ); - foreach ( $all_themes as $theme_name => $theme ) : - $theme_versions[ $theme_name ] = array( - 'name' => $theme->Name, - 'version' => null, - 'msg' => '', - ); - $theme_versions[ $theme_name ]['msg'] = '`' . $theme->Name . '`'; - $version = $theme->Version; - if ( ! empty( $version ) ) { - $theme_versions[ $theme_name ]['msg'] .= " version $version"; - $theme_versions[ $theme_name ]['version'] .= $version; - } - endforeach; - - if ( ! empty( $theme_versions ) ) { - $new_versions['themes'] = $theme_versions; - } - // get all plugins from WP - if ( ! function_exists( 'get_plugins' ) ) { - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - $all_plugins = get_plugins(); - foreach ( $all_plugins as $name => $data ) : - $plugin_versions[ $name ] = array( - 'name' => $data['Name'], - 'version' => null, - 'msg' => '', - ); - $plugin_versions[ $name ]['msg'] = "`{$data['Name']}`"; - if ( ! empty( $data['Version'] ) ) { - $plugin_versions[ $name ]['msg'] .= ' version ' . $data['Version']; - $plugin_versions[ $name ]['version'] .= $data['Version']; - } - endforeach; - - if ( ! empty( $plugin_versions ) ) { - $new_versions['plugins'] = $plugin_versions; - } - - set_transient( 'gitium_versions', $new_versions ); - - return $new_versions; -} -add_action( 'load-plugins.php', 'gitium_update_versions', 999 ); - -function gitium_upgrader_post_install( $res, $hook_extra, $result ) { - _gitium_make_ssh_git_file_exe(); - - $action = null; - $type = null; - - // install logic - if ( isset( $hook_extra['type'] ) && ( 'plugin' === $hook_extra['type'] ) ) { - $action = 'installed'; - $type = 'plugin'; - } else if ( isset( $hook_extra['type'] ) && ( 'theme' === $hook_extra['type'] ) ) { - $action = 'installed'; - $type = 'theme'; - } - - // update/upgrade logic - if ( isset( $hook_extra['plugin'] ) ) { - $action = 'updated'; - $type = 'plugin'; - } else if ( isset( $hook_extra['theme'] ) ) { - $action = 'updated'; - $type = 'theme'; - } - - // get action if missed above - if ( isset( $hook_extra['action'] ) ) { - $action = $hook_extra['action']; - if ( 'install' === $action ) { - $action = 'installed'; - } - if ( 'update' === $action ) { - $action = 'updated'; - } - } - - if ( WP_DEBUG ) { - error_log( __FUNCTION__ . ':hook_extra:' . serialize( $hook_extra ) ); - error_log( __FUNCTION__ . ':action:type:' . $action . ':' . $type ); - } - - $git_dir = $result['destination']; - $version = ''; - - if ( ABSPATH == substr( $git_dir, 0, strlen( ABSPATH ) ) ) { - $git_dir = substr( $git_dir, strlen( ABSPATH ) ); - } - switch ( $type ) { - case 'theme': - wp_clean_themes_cache(); - $theme_data = wp_get_theme( $result['destination_name'] ); - $name = $theme_data->get( 'Name' ); - $version = $theme_data->get( 'Version' ); - break; - case 'plugin': - foreach ( $result['source_files'] as $file ) : - if ( '.php' != substr( $file, -4 ) ) { continue; } - // every .php file is a possible plugin so we check if it's a plugin - $filepath = trailingslashit( $result['destination'] ) . $file; - $plugin_data = get_plugin_data( $filepath ); - if ( $plugin_data['Name'] ) : - $name = $plugin_data['Name']; - $version = $plugin_data['Version']; - // We get info from the first plugin in the package - break; - endif; - endforeach; - break; - } - if ( empty( $name ) ) { - $name = $result['destination_name']; - } - $commit_message = _gitium_format_message( $name,$version,"$action $type" ); - $commit = _gitium_commit_changes( $commit_message, $git_dir, false ); - gitium_merge_and_push( $commit ); - - return $res; -} -add_filter( 'upgrader_post_install', 'gitium_upgrader_post_install', 10, 3 ); - -// Checks for local changes, tries to group them by plugin/theme and pushes the changes -function gitium_auto_push( $msg_prepend = '' ) { - global $git; - list( , $git_private_key ) = gitium_get_keypair(); - if ( ! $git_private_key ) - return; - $git->set_key( $git_private_key ); - - $commits = gitium_group_commit_modified_plugins_and_themes( $msg_prepend ); - gitium_merge_and_push( $commits ); - gitium_update_versions(); -} -add_action( 'upgrader_process_complete', 'gitium_auto_push', 11, 0 ); - -function gitium_check_after_activate_modifications( $plugin ) { - gitium_check_after_event( $plugin ); -} -add_action( 'activated_plugin', 'gitium_check_after_activate_modifications', 999 ); - -function gitium_check_after_deactivate_modifications( $plugin ) { - gitium_check_after_event( $plugin, 'deactivation' ); -} -add_action( 'deactivated_plugin', 'gitium_check_after_deactivate_modifications', 999 ); - -function gitium_check_for_plugin_deletions() { // Handle plugin deletion - // $_GET['deleted'] used to resemble if a plugin has been deleted (true) - // ...meanwhile commit b28dd45f3dad19f0e06c546fdc89ed5b24bacd72 in github.com/WordPress/WordPress... - // Now it resembles the number of deleted plugins (a number). Thanks WP - if ( isset( $_GET['deleted'] ) && ( 1 <= (int) $_GET['deleted'] || 'true' == $_GET['deleted'] ) ) { - gitium_auto_push(); - } -} -add_action( 'load-plugins.php', 'gitium_check_for_plugin_deletions' ); - -add_action( 'wp_ajax_wp-plugin-delete-success', 'gitium_auto_push' ); -add_action( 'wp_ajax_wp-theme-delete-success', 'gitium_auto_push' ); - -function gitium_wp_plugin_delete_success() { -?> - - - -=' ) ) - add_action( 'wp_ajax_edit-theme-plugin-file', 'add_filter_for_ajax_save', 1, 0 ); -else - add_action( 'admin_enqueue_scripts', 'gitium_hook_plugin_and_theme_editor_page' ); - -function gitium_options_page_check() { - global $git; - if ( ! $git->can_exec_git() ) { wp_die( 'Cannot exec git' ); } - return true; -} - -function gitium_remote_disconnected_notice() { - if ( current_user_can( GITIUM_MANAGE_OPTIONS_CAPABILITY ) && $message = get_transient( 'gitium_remote_disconnected' ) ) : ?> -
    -

    - Could not connect to remote repository. -

    -

    -
    - - - - - - - - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-git-wrapper.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-git-wrapper.php deleted file mode 100644 index de78d79e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-git-wrapper.php +++ /dev/null @@ -1,680 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -if (!defined('GITIGNORE')) - define('GITIGNORE', <<repo_dir = $repo_dir; - } - - function _rrmdir( $dir ) { - if ( empty( $dir ) || ! is_dir( $dir ) ) { - return false; - } - - $files = array_diff( scandir( $dir ), array( '.', '..' ) ); - foreach ( $files as $file ) { - $filepath = realpath("$dir/$file"); - ( is_dir( $filepath ) ) ? $this->_rrmdir( $filepath ) : unlink( $filepath ); - } - return rmdir( $dir ); - } - - function _log(...$args) { - if ( ! defined( 'WP_DEBUG' ) || ! WP_DEBUG ) { return; } - - $output = ''; - if (isset($args) && $args) foreach ( $args as $arg ) { - $output .= var_export($arg, true).'/n/n'; - } - - if ($output) error_log($output); - } - - function _git_temp_key_file() { - $key_file = tempnam( sys_get_temp_dir(), 'ssh-git' ); - return $key_file; - } - - function set_key( $private_key ) { - $this->private_key = $private_key; - } - - private function get_env() { - $env = array( - 'HOME' => getenv( 'HOME' ), - ); - $key_file = null; - - if ( defined( 'GIT_SSH' ) && GIT_SSH ) { - $env['GIT_SSH'] = GIT_SSH; - } else { - $env['GIT_SSH'] = dirname( __FILE__ ) . '/ssh-git'; - } - - if ( defined( 'GIT_KEY_FILE' ) && GIT_KEY_FILE ) { - $env['GIT_KEY_FILE'] = GIT_KEY_FILE; - } elseif ( $this->private_key ) { - $key_file = $this->_git_temp_key_file(); - chmod( $key_file, 0600 ); - file_put_contents( $key_file, $this->private_key ); - $env['GIT_KEY_FILE'] = $key_file; - } - - return $env; - } - - protected function _call(...$args) { - $args = join( ' ', array_map( 'escapeshellarg', $args ) ); - $return = -1; - $response = array(); - $env = $this->get_env(); - - $git_bin_path = apply_filters( 'gitium_git_bin_path', '' ); - $cmd = "{$git_bin_path}git $args 2>&1"; - - $proc = proc_open( - $cmd, - array( - 0 => array( 'pipe', 'r' ), // stdin - 1 => array( 'pipe', 'w' ), // stdout - ), - $pipes, - $this->repo_dir, - $env - ); - if ( is_resource( $proc ) ) { - fclose( $pipes[0] ); - while ( $line = fgets( $pipes[1] ) ) { - $response[] = rtrim( $line, "\n\r" ); - } - $return = (int)proc_close( $proc ); - } - $this->_log( "$return $cmd", join( "\n", $response ) ); - if ( ! defined( 'GIT_KEY_FILE' ) && isset( $env['GIT_KEY_FILE'] ) ) { - unlink( $env['GIT_KEY_FILE'] ); - } - if ( 0 != $return ) { - $this->last_error = join( "\n", $response ); - } else { - $this->last_error = null; - } - return array( $return, $response ); - } - - function get_last_error() { - return $this->last_error; - } - - function can_exec_git() { - list( $return, ) = $this->_call( 'version' ); - return ( 0 == $return ); - } - - function is_status_working() { - list( $return, ) = $this->_call( 'status', '-s' ); - return ( 0 == $return ); - } - - function get_version() { - list( $return, $version ) = $this->_call( 'version' ); - if ( 0 != $return ) { return ''; } - if ( ! empty( $version[0] ) ) { - return substr( $version[0], 12 ); - } - return ''; - } - - // git rev-list @{u}.. - function get_ahead_commits() { - list( , $commits ) = $this->_call( 'rev-list', '@{u}..' ); - return $commits; - } - - // git rev-list ..@{u} - function get_behind_commits() { - list( , $commits ) = $this->_call( 'rev-list', '..@{u}' ); - return $commits; - } - - function init() { - file_put_contents( "$this->repo_dir/.gitignore", $this->gitignore ); - list( $return, ) = $this->_call( 'init' ); - $this->_call( 'config', 'user.email', 'gitium@presslabs.com' ); - $this->_call( 'config', 'user.name', 'Gitium' ); - $this->_call( 'config', 'push.default', 'matching' ); - return ( 0 == $return ); - } - - function is_dot_git_dir( $dir ) { - $realpath = realpath( $dir ); - $git_config = realpath( $realpath . '/config' ); - $git_index = realpath( $realpath . '/index' ); - if ( ! empty( $realpath ) && is_dir( $realpath ) && file_exists( $git_config ) && file_exists( $git_index ) ) { - return True; - } - return False; - } - - function cleanup() { - $dot_git_dir = realpath( $this->repo_dir . '/.git' ); - if ( $this->is_dot_git_dir( $dot_git_dir ) && $this->_rrmdir( $dot_git_dir ) ) { - if ( WP_DEBUG ) { - error_log( "Gitium cleanup successfull. Removed '$dot_git_dir'." ); - } - return True; - } - if ( WP_DEBUG ) { - error_log( "Gitium cleanup failed. '$dot_git_dir' is not a .git dir." ); - } - return False; - } - - function add_remote_url( $url ) { - list( $return, ) = $this->_call( 'remote', 'add', 'origin', $url ); - return ( 0 == $return ); - } - - function get_remote_url() { - list( , $response ) = $this->_call( 'config', '--get', 'remote.origin.url' ); - if ( isset( $response[0] ) ) { - return $response[0]; - } - return ''; - } - - function remove_remote() { - list( $return, ) = $this->_call( 'remote', 'rm', 'origin'); - return ( 0 == $return ); - } - - function get_remote_tracking_branch() { - list( $return, $response ) = $this->_call( 'rev-parse', '--abbrev-ref', '--symbolic-full-name', '@{u}' ); - if ( 0 == $return ) { - return $response[0]; - } - return false; - } - - function get_local_branch() { - list( $return, $response ) = $this->_call( 'rev-parse', '--abbrev-ref', 'HEAD' ); - if ( 0 == $return ) { - return $response[0]; - } - return false; - } - - function fetch_ref() { - list( $return, ) = $this->_call( 'fetch', 'origin' ); - return ( 0 == $return ); - } - - protected function _resolve_merge_conflicts( $message ) { - list( , $changes ) = $this->status( true ); - $this->_log( $changes ); - foreach ( $changes as $path => $change ) { - if ( in_array( $change, array( 'UD', 'DD' ) ) ) { - $this->_call( 'rm', $path ); - $message .= "\n\tConflict: $path [removed]"; - } elseif ( 'DU' == $change ) { - $this->_call( 'add', $path ); - $message .= "\n\tConflict: $path [added]"; - } elseif ( in_array( $change, array( 'AA', 'UU', 'AU', 'UA' ) ) ) { - $this->_call( 'checkout', '--theirs', $path ); - $this->_call( 'add', '--all', $path ); - $message .= "\n\tConflict: $path [local version]"; - } - } - $this->commit( $message ); - } - - function get_commit_message( $commit ) { - list( $return, $response ) = $this->_call( 'log', '--format=%B', '-n', '1', $commit ); - return ( $return !== 0 ? false : join( "\n", $response ) ); - } - - private function strpos_haystack_array( $haystack, $needle, $offset=0 ) { - if ( ! is_array( $haystack ) ) { $haystack = array( $haystack ); } - - foreach ( $haystack as $query ) { - if ( strpos( $query, $needle, $offset) !== false ) { return true; } - } - return false; - } - - private function cherry_pick( $commits ) { - foreach ( $commits as $commit ) { - if ( empty( $commit ) ) { return false; } - - list( $return, $response ) = $this->_call( 'cherry-pick', $commit ); - - // abort the cherry-pick if the changes are already pushed - if ( false !== $this->strpos_haystack_array( $response, 'previous cherry-pick is now empty' ) ) { - $this->_call( 'cherry-pick', '--abort' ); - continue; - } - - if ( $return != 0 ) { - $this->_resolve_merge_conflicts( $this->get_commit_message( $commit ) ); - } - } - } - - function merge_with_accept_mine(...$commits) { - do_action( 'gitium_before_merge_with_accept_mine' ); - - if ( 1 == count($commits) && is_array( $commits[0] ) ) { - $commits = $commits[0]; - } - - // get ahead commits - $ahead_commits = $this->get_ahead_commits(); - - // combine all commits with the ahead commits - $commits = array_unique( array_merge( array_reverse( $commits ), $ahead_commits ) ); - $commits = array_reverse( $commits ); - - // get the remote branch - $remote_branch = $this->get_remote_tracking_branch(); - - // get the local branch - $local_branch = $this->get_local_branch(); - - // rename the local branch to 'merge_local' - $this->_call( 'branch', '-m', 'merge_local' ); - - // local branch set up to track remote branch - $this->_call( 'branch', $local_branch, $remote_branch ); - - // checkout to the $local_branch - list( $return, ) = $this->_call( 'checkout', $local_branch ); - if ( $return != 0 ) { - $this->_call( 'branch', '-M', $local_branch ); - return false; - } - - // don't cherry pick if there are no commits - if ( count( $commits ) > 0 ) { - $this->cherry_pick( $commits ); - } - - if ( $this->successfully_merged() ) { // git status without states: AA, DD, UA, AU ... - // delete the 'merge_local' branch - $this->_call( 'branch', '-D', 'merge_local' ); - return true; - } else { - $this->_call( 'cherry-pick', '--abort' ); - $this->_call( 'checkout', '-b', 'merge_local' ); - $this->_call( 'branch', '-M', $local_branch ); - return false; - } - } - - function successfully_merged() { - list( , $response ) = $this->status( true ); - $changes = array_values( $response ); - return ( 0 == count( array_intersect( $changes, array( 'DD', 'AU', 'UD', 'UA', 'DU', 'AA', 'UU' ) ) ) ); - } - - function merge_initial_commit( $commit, $branch ) { - list( $return, ) = $this->_call( 'branch', '-m', 'initial' ); - if ( 0 != $return ) { - return false; - } - list( $return, ) = $this->_call( 'checkout', $branch ); - if ( 0 != $return ) { - return false; - } - list( $return, ) = $this->_call( - 'cherry-pick', '--strategy', 'recursive', '--strategy-option', 'theirs', $commit - ); - if ( $return != 0 ) { - $this->_resolve_merge_conflicts( $this->get_commit_message( $commit ) ); - if ( ! $this->successfully_merged() ) { - $this->_call( 'cherry-pick', '--abort' ); - $this->_call( 'checkout', 'initial' ); - return false; - } - } - $this->_call( 'branch', '-D', 'initial' ); - return true; - } - - function get_remote_branches() { - list( , $response ) = $this->_call( 'branch', '-r' ); - $response = array_map( 'trim', $response ); - $response = array_map( function( $b ) { return str_replace( "origin/", "", $b ); }, $response ); - return $response; - } - - function add(...$args) { - if ( 1 == count($args) && is_array( $args[0] ) ) { - $args = $args[0]; - } - $params = array_merge( array( 'add', '-n', '--all' ), $args ); - list ( , $response ) = call_user_func_array( array( $this, '_call' ), $params ); - $count = count( $response ); - - $params = array_merge( array( 'add', '--all' ), $args ); - list ( , $response ) = call_user_func_array( array( $this, '_call' ), $params ); - - return $count; - } - - function commit( $message, $author_name = '', $author_email = '' ) { - $author = ''; - if ( $author_email ) { - if ( empty( $author_name ) ) { - $author_name = $author_email; - } - $author = "$author_name <$author_email>"; - } - - if ( ! empty( $author ) ) { - list( $return, $response ) = $this->_call( 'commit', '-m', $message, '--author', $author ); - } else { - list( $return, $response ) = $this->_call( 'commit', '-m', $message ); - } - if ( $return !== 0 ) { return false; } - - list( $return, $response ) = $this->_call( 'rev-parse', 'HEAD' ); - - return ( $return === 0 ) ? $response[0] : false; - } - - function push( $branch = '' ) { - if ( ! empty( $branch ) ) { - list( $return, ) = $this->_call( 'push', '--porcelain', '-u', 'origin', $branch ); - } else { - list( $return, ) = $this->_call( 'push', '--porcelain', '-u', 'origin', 'HEAD' ); - } - return ( $return == 0 ); - } - - /* - * Get uncommited changes with status porcelain - * git status --porcelain - * It returns an array like this: - array( - file => deleted|modified - ... - ) - */ - function get_local_changes() { - list( $return, $response ) = $this->_call( 'status', '--porcelain' ); - - if ( 0 !== $return ) { - return array(); - } - $new_response = array(); - if ( ! empty( $response ) ) { - foreach ( $response as $line ) : - $work_tree_status = substr( $line, 1, 1 ); - $path = substr( $line, 3 ); - - if ( ( '"' == $path[0] ) && ('"' == $path[strlen( $path ) - 1] ) ) { - // git status --porcelain will put quotes around paths with whitespaces - // we don't want the quotes, let's get rid of them - $path = substr( $path, 1, strlen( $path ) - 2 ); - } - - if ( 'D' == $work_tree_status ) { - $action = 'deleted'; - } else { - $action = 'modified'; - } - $new_response[ $path ] = $action; - endforeach; - } - return $new_response; - } - - function get_uncommited_changes() { - list( , $changes ) = $this->status(); - return $changes; - } - - function local_status() { - list( $return, $response ) = $this->_call( 'status', '-s', '-b', '-u' ); - if ( 0 !== $return ) { - return array( '', array() ); - } - - $new_response = array(); - if ( ! empty( $response ) ) { - $branch_status = array_shift( $response ); - foreach ( $response as $idx => $line ) : - unset( $index_status, $work_tree_status, $path, $new_path, $old_path ); - - if ( empty( $line ) ) { continue; } // ignore empty lines like the last item - if ( '#' == $line[0] ) { continue; } // ignore branch status - - $index_status = substr( $line, 0, 1 ); - $work_tree_status = substr( $line, 1, 1 ); - $path = substr( $line, 3 ); - - $old_path = ''; - $new_path = explode( '->', $path ); - if ( ( 'R' === $index_status ) && ( ! empty( $new_path[1] ) ) ) { - $old_path = trim( $new_path[0] ); - $path = trim( $new_path[1] ); - } - $new_response[ $path ] = trim( $index_status . $work_tree_status . ' ' . $old_path ); - endforeach; - } - - return array( $branch_status, $new_response ); - } - - function status( $local_only = false ) { - list( $branch_status, $new_response ) = $this->local_status(); - - if ( $local_only ) { return array( $branch_status, $new_response ); } - - $behind_count = 0; - $ahead_count = 0; - if ( preg_match( '/## ([^.]+)\.+([^ ]+)/', $branch_status, $matches ) ) { - $local_branch = $matches[1]; - $remote_branch = $matches[2]; - - list( , $response ) = $this->_call( 'rev-list', "$local_branch..$remote_branch", '--count' ); - $behind_count = (int)$response[0]; - - list( , $response ) = $this->_call( 'rev-list', "$remote_branch..$local_branch", '--count' ); - $ahead_count = (int)$response[0]; - } - - if ( $behind_count ) { - list( , $response ) = $this->_call( 'diff', '-z', '--name-status', "$local_branch~$ahead_count", $remote_branch ); - $response = explode( chr( 0 ), $response[0] ); - array_pop( $response ); - for ( $idx = 0 ; $idx < count( $response ) / 2 ; $idx++ ) { - $file = $response[ $idx * 2 + 1 ]; - $change = $response[ $idx * 2 ]; - if ( ! isset( $new_response[ $file ] ) ) { - $new_response[ $file ] = "r$change"; - } - } - } - return array( $branch_status, $new_response ); - } - - /* - * Checks if repo has uncommited changes - * git status --porcelain - */ - function is_dirty() { - $changes = $this->get_uncommited_changes(); - return ! empty( $changes ); - } - - /** - * Return the last n commits - */ - function get_last_commits( $n = 20 ) { - list( $return, $message ) = $this->_call( 'log', '-n', $n, '--pretty=format:%s' ); - if ( 0 !== $return ) { return false; } - - list( $return, $response ) = $this->_call( 'log', '-n', $n, '--pretty=format:%h|%an|%ae|%ad|%cn|%ce|%cd' ); - if ( 0 !== $return ) { return false; } - - foreach ( $response as $index => $value ) { - $commit_info = explode( '|', $value ); - $commits[ $commit_info[0] ] = array( - 'subject' => $message[ $index ], - 'author_name' => $commit_info[1], - 'author_email' => $commit_info[2], - 'author_date' => $commit_info[3], - ); - if ( $commit_info[1] != $commit_info[4] && $commit_info[2] != $commit_info[5] ) { - $commits[ $commit_info[0] ]['committer_name'] = $commit_info[4]; - $commits[ $commit_info[0] ]['committer_email'] = $commit_info[5]; - $commits[ $commit_info[0] ]['committer_date'] = $commit_info[6]; - } - } - return $commits; - } - - public function set_gitignore( $content ) { - file_put_contents( $this->repo_dir . '/.gitignore', $content ); - return true; - } - - public function get_gitignore() { - return file_get_contents( $this->repo_dir . '/.gitignore' ); - } - - /** - * Remove files in .gitignore from version control - */ - function rm_cached( $path ) { - list( $return, ) = $this->_call( 'rm', '--cached', $path ); - return ( $return == 0 ); - } - - function remove_wp_content_from_version_control() { - $process = proc_open( - 'rm -rf ' . ABSPATH . '/wp-content/.git', - array( - 0 => array( 'pipe', 'r' ), // stdin - 1 => array( 'pipe', 'w' ), // stdout - ), - $pipes - ); - if ( is_resource( $process ) ) { - fclose( $pipes[0] ); - proc_close( $process ); - return true; - } - return false; - } -} - -if ( ! defined( 'GIT_DIR' ) ) { - define( 'GIT_DIR', dirname( WP_CONTENT_DIR ) ); -} - -# global is needed here for wp-cli as it includes/exec files inside a function scope -# this forces the context to really be global :\. -global $git; -$git = new Git_Wrapper( GIT_DIR ); diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-admin.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-admin.php deleted file mode 100644 index 0c0a3d8e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-admin.php +++ /dev/null @@ -1,58 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ -class Gitium_Admin { - - public function __construct() { - global $git; - - list( , $git_private_key ) = gitium_get_keypair(); - $git->set_key( $git_private_key ); - - if ( current_user_can( GITIUM_MANAGE_OPTIONS_CAPABILITY ) ) { - $req = new Gitium_Requirements(); - if ( ! $req->get_status() ) { - return false; - } - - if ( $this->has_configuration() ) { - new Gitium_Submenu_Status(); - new Gitium_Submenu_Commits(); - new Gitium_Submenu_Settings(); - new Gitium_Menu_Bubble(); - } else { - new Gitium_Submenu_Configure(); - } - } - } - - public function has_configuration() { - return _gitium_is_status_working() && _gitium_get_remote_tracking_branch(); - } -} - -if ( ( is_admin() && ! is_multisite() ) || ( is_network_admin() && is_multisite() ) ) { - add_action( 'init', 'gitium_admin_page' ); - function gitium_admin_page() { - new Gitium_Admin(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-help.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-help.php deleted file mode 100644 index 57416798..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-help.php +++ /dev/null @@ -1,113 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Help { - - public function __construct( $hook, $help = 'gitium' ) { - add_action( "load-{$hook}", array( $this, $help ), 20 ); - } - - private function general() { - $screen = get_current_screen(); - $screen->add_help_tab( array( 'id' => 'gitium', 'title' => __( 'Gitium', 'gitium' ), 'callback' => array( $this, 'gitium' ) ) ); - $screen->add_help_tab( array( 'id' => 'faq', 'title' => __( 'F.A.Q.', 'gitium' ), 'callback' => array( $this, 'faq' ) ) ); - $screen->add_help_tab( array( 'id' => 'requirements', 'title' => __( 'Requirements', 'gitium' ), 'callback' => array( $this, 'requirements_callback' ) ) ); - $screen->set_help_sidebar( '
    ' ); - } - - public function gitium() { - echo '

    ' . __( 'Gitium enables continuous deployment for WordPress integrating with tools such as Github, Bitbucket or Travis-CI. Plugin and theme updates, installs and removals are automatically versioned.', 'gitium' ) . '

    '; - echo '

    ' . __( 'Ninja code edits from the WordPress editor are also tracked into version control. Gitium is designed for sane development environments.', 'gitium' ) . '

    '; - echo '

    ' . __( 'Staging and production can follow different branches of the same repository. You can deploy code simply trough git push.', 'gitium' ) . '

    '; - echo '

    ' . __( 'Gitium requires git command line tool minimum version 1.7 installed on the server and proc_open PHP function enabled.', 'gitium' ) . '

    '; - } - - public function faq() { - echo '

    ' . __( 'Could not connect to remote repository?', 'gitium' ) . '
    '. __( 'If you encounter this kind of error you can try to fix it by setting the proper username of the .git directory.', 'gitium' ) . '
    ' . __( 'Example', 'gitium' ) .': chown -R www-data:www-data .git

    '; - echo '

    ' . __( 'Is this plugin considered stable?', 'gitium' ) . '
    '. __( 'Right now this plugin is considered alpha quality and should be used in production environments only by adventurous kinds.', 'gitium' ) . '

    '; - echo '

    ' . __( 'What happens in case of conflicts?', 'gitium' ) . '
    '. __( 'The behavior in case of conflicts is to overwrite the changes on the origin repository with the local changes (ie. local modifications take precedence over remote ones).', 'gitium' ) . '

    '; - echo '

    ' . __( 'How to deploy automatically after a push?', 'gitium' ) . '
    '. __( 'You can ping the webhook url after a push to automatically deploy the new code. The webhook url can be found under Code menu. This url plays well with Github or Bitbucket webhooks.', 'gitium' ) . '

    '; - echo '

    ' . __( 'Does it works on multi site setups?', 'gitium' ) . '
    '. __( 'Gitium is not supporting multisite setups at the moment.', 'gitium' ) . '

    '; - echo '

    ' . __( 'How does gitium handle submodules?', 'gitium' ) . '
    '. __( 'Currently submodules are not supported.', 'gitium' ) . '

    '; - } - - public function requirements_callback() { - echo '

    ' . __( 'Gitium requires:', 'gitium' ) . '

    '; - echo '

    ' . __( 'the function proc_open available', 'gitium' ) . '

    '; - echo '

    ' . __( 'can exec the file inc/ssh-git', 'gitium' ) . '

    '; - - printf( '

    ' . __( 'git version >= %s', 'gitium' ) . '

    ', GITIUM_MIN_GIT_VER ); - printf( '

    ' . __( 'PHP version >= %s', 'gitium' ) . '

    ', GITIUM_MIN_PHP_VER ); - } - - public function configuration() { - $screen = get_current_screen(); - $screen->add_help_tab( array( 'id' => 'configuration', 'title' => __( 'Configuration', 'gitium' ), 'callback' => array( $this, 'configuration_callback' ) ) ); - $this->general(); - } - - public function configuration_callback() { - echo '

    ' . __( 'Configuration step 1', 'gitium' ) . '
    ' . __( 'In this step you must specify the Remote URL. This URL represents the link between the git sistem and your site.', 'gitium' ) . '

    '; - echo '

    ' . __( 'You can get this URL from your Git repository and it looks like this:', 'gitium' ) . '

    '; - echo '

    ' . __( 'github.com -> git@github.com:user/example.git', 'gitium' ) . '

    '; - echo '

    ' . __( 'bitbucket.org -> git@bitbucket.org:user/glowing-happiness.git', 'gitium' ) . '

    '; - echo '

    ' . __( 'To go to the next step, fill the Remote URL and then press the Fetch button.', 'gitium' ) . '

    '; - echo '

    ' . __( 'Configuration step 2', 'gitium' ) . '
    ' . __( 'In this step you must select the branch you want to follow.', 'gitium' ) . '

    '; - echo '

    ' . __( 'Only this branch will have all of your code modifications.', 'gitium' ) . '

    '; - echo '

    ' . __( 'When you push the button Merge & Push, all code(plugins & themes) will be pushed on the git repository.', 'gitium' ) . '

    '; - } - - public function status() { - $screen = get_current_screen(); - $screen->add_help_tab( array( 'id' => 'status', 'title' => __( 'Status', 'gitium' ), 'callback' => array( $this, 'status_callback' ) ) ); - $this->general(); - } - - public function status_callback() { - echo '

    ' . __( 'On status page you can see what files are modified, and you can commit the changes to git.', 'gitium' ) . '

    '; - } - - public function commits() { - $screen = get_current_screen(); - $screen->add_help_tab( array( 'id' => 'commits', 'title' => __( 'Commits', 'gitium' ), 'callback' => array( $this, 'commits_callback' ) ) ); - $this->general(); - } - - public function commits_callback() { - echo '

    ' . __( 'You may be wondering what is the difference between author and committer.', 'gitium' ) . '

    '; - echo '

    ' . __( 'The author is the person who originally wrote the patch, whereas the committer is the person who last applied the patch.', 'gitium' ) . '

    '; - echo '

    ' . __( 'So, if you send in a patch to a project and one of the core members applies the patch, both of you get credit — you as the author and the core member as the committer.', 'gitium' ) . '

    '; - } - - public function settings() { - $screen = get_current_screen(); - $screen->add_help_tab( array( 'id' => 'settings', 'title' => __( 'Settings', 'gitium' ), 'callback' => array( $this, 'settings_callback' ) ) ); - $this->general(); - } - - public function settings_callback() { - echo '

    ' . __( 'Each line from the gitignore file specifies a pattern.', 'gitium' ) . '

    '; - echo '

    ' . __( 'When deciding whether to ignore a path, Git normally checks gitignore patterns from multiple sources, with the following order of precedence, from highest to lowest (within one level of precedence, the last matching pattern decides the outcome)', 'gitium' ) . '

    '; - echo '

    ' . sprintf( __( 'Read more on %s', 'gitium' ), 'git documentation' ) . '

    '; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-menu-bubble.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-menu-bubble.php deleted file mode 100644 index c1a8a838..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-menu-bubble.php +++ /dev/null @@ -1,61 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Menu_Bubble extends Gitium_Menu { - - public function __construct() { - parent::__construct( $this->gitium_menu_slug, $this->gitium_menu_slug ); - add_action( GITIUM_ADMIN_MENU_ACTION, array( $this, 'add_menu_bubble' ) ); - } - - public function add_menu_bubble() { - global $menu; - - if ( ! _gitium_is_status_working() ) { - foreach ( $menu as $key => $value ) { - if ( $this->menu_slug == $menu[ $key ][2] ) { - $menu_bubble = get_transient( 'gitium_menu_bubble' ); - if ( false === $menu_bubble ) { $menu_bubble = ''; } - $menu[ $key ][0] = str_replace( $menu_bubble, '', $menu[ $key ][0] ); - delete_transient( 'gitium_menu_bubble' ); - return; - } - } - } - - list( , $changes ) = _gitium_status(); - - if ( ! empty( $changes ) ) : - $bubble_count = count( $changes ); - foreach ( $menu as $key => $value ) { - if ( $this->menu_slug == $menu[ $key ][2] ) { - $menu_bubble = " " - . $bubble_count . ''; - $menu[ $key ][0] .= $menu_bubble; - set_transient( 'gitium_menu_bubble', $menu_bubble ); - return; - } - } - endif; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-menu.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-menu.php deleted file mode 100644 index 9adac247..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-menu.php +++ /dev/null @@ -1,103 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Menu { - - public $gitium_menu_slug = 'gitium/gitium.php'; - public $commits_menu_slug = 'gitium/gitium-commits.php'; - public $settings_menu_slug = 'gitium/gitium-settings.php'; - - public $git = null; - - public $menu_slug; - public $submenu_slug; - - public function __construct( $menu_slug, $submenu_slug ) { - global $git; - $this->git = $git; - - $this->menu_slug = $menu_slug; - $this->submenu_slug = $submenu_slug; - } - - public function redirect( $message = '', $success = false, $menu_slug = '' ) { - $message_id = substr( - md5( str_shuffle( 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789' ) . time() ), 0, 8 - ); - if ( $message ) { - set_transient( 'message_' . $message_id, $message, 900 ); - } - if ( '' === $menu_slug ) { $menu_slug = $this->menu_slug; } - $url = network_admin_url( 'admin.php?page=' . $menu_slug ); - $url = esc_url_raw( add_query_arg( - array( - 'message' => $message_id, - 'success' => $success, - ), - $url - ) ); - wp_safe_redirect( $url ); - exit; - } - - public function success_redirect( $message = '', $menu_slug = '' ) { - $this->redirect( $message, true, $menu_slug ); - } - - public function disconnect_repository() { - $gitium_disconnect_repo = filter_input(INPUT_POST, 'GitiumSubmitDisconnectRepository', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - - if ( ! isset( $gitium_disconnect_repo ) ) { - return; - } - check_admin_referer( 'gitium-admin' ); - gitium_uninstall_hook(); - if ( ! $this->git->remove_remote() ) { - $this->redirect( __('Could not remove remote.', 'gitium') ); - } - $this->success_redirect( __('You are now disconnected from the repository. New key pair generated.', 'gitium') ); - } - - public function show_message() { - $get_message = filter_input(INPUT_GET, 'message', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - $get_success = filter_input(INPUT_GET, 'success', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( isset( $get_message ) && $get_message ) { - $type = ( isset( $get_success ) && $get_success == 1 ) ? 'updated' : 'error'; - $message = get_transient( 'message_'. $get_message ); - if ( $message ) : ?> -

    - -
    - - ' class="button secondary" onclick="return confirm('')"/>  -
    - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Requirements { - - private $req = array(); - private $msg = array(); - - /** - * Gitium requires: - * git min version - * the function proc_open available - * PHP min version - * can exec the file inc/ssh-git - */ - public function __construct() { - $this->_check_req(); - add_action( GITIUM_ADMIN_NOTICES_ACTION, array( $this, 'admin_notices' ) ); - } - - private function _check_req() { - list($this->req['is_git_version'], $this->msg['is_git_version'] ) = $this->is_git_version(); - list($this->req['is_proc_open'], $this->msg['is_proc_open'] ) = $this->is_proc_open(); - list($this->req['is_php_verion'], $this->msg['is_php_verion'] ) = $this->is_php_version(); - list($this->req['can_exec_ssh_git_file'],$this->msg['can_exec_ssh_git_file']) = $this->can_exec_ssh_git_file(); - - return $this->req; - } - - public function admin_notices() { - if ( ! current_user_can( GITIUM_MANAGE_OPTIONS_CAPABILITY ) ) { - return; - } - - foreach ( $this->req as $key => $value ) { - if ( false === $value ) { - echo "

    Gitium Requirement: {$this->msg[$key]}

    "; - } - } - } - - public function get_status() { - $requirements = $this->req; - - foreach ( $requirements as $req ) : - if ( false === $req ) : - return false; - endif; - endforeach; - - return true; - } - - private function is_git_version() { - $git_version = get_transient( 'gitium_git_version' ); - - if ( GITIUM_MIN_GIT_VER > substr( $git_version, 0, 3 ) ) { - global $git; - $git_version = $git->get_version(); - set_transient( 'gitium_git_version', $git_version ); - if ( empty( $git_version ) ) { - return array( false, 'There is no git installed on this server.' ); - } else if ( GITIUM_MIN_GIT_VER > substr( $git_version, 0, 3 ) ) { - return array( false, "The git version is `$git_version` and must be greater than `" . GITIUM_MIN_GIT_VER . "`!" ); - } - } - - return array( true, "The git version is `$git_version`." ); - } - - private function is_proc_open() { - if ( ! function_exists( 'proc_open' ) ) { - return array( false, 'The function `proc_open` is disabled!' ); - } else { - return array( true, 'The function `proc_open` is enabled!' ); - } - } - - private function is_php_version() { - if ( ! function_exists( 'phpversion' ) ) { - return array( false, 'The function `phpversion` is disabled!' ); - } else { - $php_version = phpversion(); - if ( GITIUM_MIN_PHP_VER <= substr( $php_version, 0, 3 ) ) { - return array( true, "The PHP version is `$php_version`." ); - } else { - return array( false, "The PHP version is `$php_version` and is not greater or equal to " . GITIUM_MIN_PHP_VER ); - } - } - } - - private function can_exec_ssh_git_file() { - $filepath = dirname( __FILE__ ) . '/ssh-git'; - - if ( ! function_exists( 'is_executable' ) ) { - return array( false, 'The function `is_executable` is disabled!' ); - } else if ( is_executable( $filepath ) ) { - return array( true, "The `$filepath` file can be executed!" ); - } else { - return array( false, "The `$filepath` file is not executable" ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-submenu-commits.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-submenu-commits.php deleted file mode 100644 index e204c487..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-submenu-commits.php +++ /dev/null @@ -1,100 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Submenu_Commits extends Gitium_Menu { - - public function __construct() { - parent::__construct( $this->gitium_menu_slug, $this->commits_menu_slug ); - add_action( GITIUM_ADMIN_MENU_ACTION, array( $this, 'admin_menu' ) ); - } - - public function admin_menu() { - $submenu_hook = add_submenu_page( - $this->menu_slug, - __( 'Git Commits', 'gitium' ), - __( 'Commits', 'gitium' ), - GITIUM_MANAGE_OPTIONS_CAPABILITY, - $this->submenu_slug, - array( $this, 'page' ) - ); - new Gitium_Help( $submenu_hook, 'commits' ); - } - - public function table_head() { - ?> - - - - - - - '; - } - - public function table_start_row() { - static $counter = 0; - $counter++; - echo ( 0 != $counter % 2 ) ? '' : ''; - } - - public function page() { - ?> -
    -

    - - table_head(); ?> - - git->get_last_commits( GITIUM_LAST_COMMITS ) as $commit_id => $data ) { - unset( $committer_name ); - extract( $data ); - if ( isset( $committer_name ) ) { - $committer = " -> $committer_name " . sprintf( __( 'committed %s ago', 'gitium' ), human_time_diff( strtotime( $committer_date ) ) ) . ''; - $committers_avatar = '
    ' . get_avatar( $committer_email, 16 ) . '
    '; - } else { - $committer = ''; - $committers_avatar = ''; - } - $this->table_start_row(); - ?> - - - table_end_row(); - } - ?> - -
    -
    - -

    -
    -

    -
    - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Submenu_Configure extends Gitium_Menu { - - public function __construct() { - parent::__construct( $this->gitium_menu_slug, $this->gitium_menu_slug ); - - if ( current_user_can( GITIUM_MANAGE_OPTIONS_CAPABILITY ) ) { - add_action( GITIUM_ADMIN_MENU_ACTION, array( $this, 'admin_menu' ) ); - add_action( 'admin_init', array( $this, 'regenerate_keypair' ) ); - add_action( 'admin_init', array( $this, 'gitium_warning' ) ); - add_action( 'admin_init', array( $this, 'init_repo' ) ); - add_action( 'admin_init', array( $this, 'choose_branch' ) ); - add_action( 'admin_init', array( $this, 'disconnect_repository' ) ); - } - } - - public function admin_menu() { - add_menu_page( - __( 'Git Configuration', 'gitium' ), - 'Gitium', - GITIUM_MANAGE_OPTIONS_CAPABILITY, - $this->menu_slug, - array( $this, 'page' ), - plugins_url( 'img/gitium.png', dirname( __FILE__ ) ) - ); - - $submenu_hook = add_submenu_page( - $this->menu_slug, - __( 'Git Configuration', 'gitium' ), - __( 'Configuration', 'gitium' ), - GITIUM_MANAGE_OPTIONS_CAPABILITY, - $this->menu_slug, - array( $this, 'page' ) - ); - new Gitium_Help( $submenu_hook, 'configuration' ); - } - - public function regenerate_keypair() { - $submit_keypair = filter_input(INPUT_POST, 'GitiumSubmitRegenerateKeypair', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $submit_keypair ) ) { - return; - } - check_admin_referer( 'gitium-admin' ); - gitium_get_keypair( true ); - $this->success_redirect( __( 'Keypair successfully regenerated.', 'gitium' ) ); - } - - public function gitium_warning() { - $submit_warning = filter_input(INPUT_POST, 'GitiumSubmitWarning', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $submit_warning ) ) { - return; - } - check_admin_referer( 'gitium-admin' ); - $this->git->remove_wp_content_from_version_control(); - } - - public function init_process( $remote_url ) { - $git = $this->git; - $git->init(); - $git->add_remote_url( $remote_url ); - $git->fetch_ref(); - if ( count( $git->get_remote_branches() ) == 0 ) { - $git->add( 'wp-content', '.gitignore' ); - $current_user = wp_get_current_user(); - $git->commit( __( 'Initial commit', 'gitium' ), $current_user->display_name, $current_user->user_email ); - if ( ! $git->push( 'master' ) ) { - $git->cleanup(); - return false; - } - } - return true; - } - - public function init_repo() { - $remote_url = filter_input(INPUT_POST, 'remote_url', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - $gitium_submit_fetch = filter_input(INPUT_POST, 'GitiumSubmitFetch', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $gitium_submit_fetch ) || ! isset( $remote_url ) ) { - return; - } - check_admin_referer( 'gitium-admin' ); - - if ( empty( $remote_url ) ) { - $this->redirect( __( 'Please specify a valid repo.', 'gitium' ) ); - } - if ( $this->init_process( $remote_url ) ) { - $this->success_redirect( __( 'Repository initialized successfully.', 'gitium' ) ); - } else { - global $git; - $this->redirect( __( 'Could not push to remote: ', 'gitium' ) . $remote_url . ' ERROR: ' . serialize( $git->get_last_error() ) ); - } - } - - public function choose_branch() { - $gitium_submit_merge_push = filter_input(INPUT_POST, 'GitiumSubmitMergeAndPush', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - $tracking_branch = filter_input(INPUT_POST, 'tracking_branch', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $gitium_submit_merge_push ) || ! isset( $tracking_branch ) ) { - return; - } - check_admin_referer( 'gitium-admin' ); - $this->git->add(); - - $branch = $tracking_branch; - set_transient( 'gitium_remote_tracking_branch', $branch ); - $current_user = wp_get_current_user(); - - $commit = $this->git->commit( __( 'Merged existing code from ', 'gitium' ) . get_home_url(), $current_user->display_name, $current_user->user_email ); - if ( ! $commit ) { - $this->git->cleanup(); - $this->redirect( __( 'Could not create initial commit -> ', 'gitium' ) . $this->git->get_last_error() ); - } - if ( ! $this->git->merge_initial_commit( $commit, $branch ) ) { - $this->git->cleanup(); - $this->redirect( __( 'Could not merge the initial commit -> ', 'gitium' ) . $this->git->get_last_error() ); - } - $this->git->push( $branch ); - $this->success_redirect( __( 'Branch selected successfully.', 'gitium' ) ); - } - - private function setup_step_1_remote_url() { - ?> - - - - -


    - https://user:pass@github.com/user/example.git
    ', 'gitium' ); ?>

    - - - - - - -

    - - -

    -

    -

    - -
    -

    -


    - github or bitbucket.', 'gitium' ); ?> -

    - - - -
    -

    -
    - -

    wp-content is already under version control. You must remove it from version control in order to continue.

    -

    NOTE by doing this you WILL LOSE commit history, but NOT the actual files.

    - -
    -
    - -
    -

    -

    -
    - - - setup_step_1_remote_url(); ?> - setup_step_1_key_pair(); ?> -
    -

    - -

    -
    -
    - git; ?> -
    -

    -

    - - -
    - - - - - - - -
    - -

    get_remote_url() ); ?>

    -
    - -

    - -

    -
    - show_disconnect_repository_button(); - ?> -
    - show_message(); - - if ( wp_content_is_versioned() ) { - return $this->setup_warning(); - } - - if ( ! $this->git->is_status_working() || ! $this->git->get_remote_url() ) { - return $this->setup_step_1(); - } - - if ( ! $this->git->get_remote_tracking_branch() ) { - return $this->setup_step_2(); - } - - _gitium_status( true ); - gitium_update_is_status_working(); - gitium_update_remote_tracking_branch(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-submenu-settings.php b/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-submenu-settings.php deleted file mode 100644 index 7b292471..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/class-gitium-submenu-settings.php +++ /dev/null @@ -1,150 +0,0 @@ - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Submenu_Settings extends Gitium_Menu { - - public function __construct() { - parent::__construct( $this->gitium_menu_slug, $this->settings_menu_slug ); - add_action( GITIUM_ADMIN_MENU_ACTION, array( $this, 'admin_menu' ) ); - add_action( 'admin_init', array( $this, 'save' ) ); - add_action( 'admin_init', array( $this, 'regenerate_webhook' ) ); - add_action( 'admin_init', array( $this, 'regenerate_public_key' ) ); - } - - public function admin_menu() { - $submenu_hook = add_submenu_page( - $this->menu_slug, - 'Settings', - __( 'Settings' ), - GITIUM_MANAGE_OPTIONS_CAPABILITY, - $this->submenu_slug, - array( $this, 'page' ) - ); - new Gitium_Help( $submenu_hook, 'settings' ); - } - - public function regenerate_webhook() { - $gitium_regen_webhook = filter_input(INPUT_POST, 'GitiumSubmitRegenerateWebhook', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $gitium_regen_webhook ) ) { - return; - } - check_admin_referer( 'gitium-settings' ); - gitium_get_webhook_key( true ); - $this->success_redirect( __( 'Webhook URL regenerates. Please make sure you update any external references.', 'gitium' ), $this->settings_menu_slug ); - } - - public function regenerate_public_key() { - $submit_regenerate_pub_key = filter_input(INPUT_POST, 'GitiumSubmitRegeneratePublicKey', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $submit_regenerate_pub_key ) ) { - return; - } - check_admin_referer( 'gitium-settings' ); - gitium_get_keypair( true ); - $this->success_redirect( __( 'Public key successfully regenerated.', 'gitium' ), $this->settings_menu_slug ); - } - - private function show_webhook_table_webhook_url() { - ?> - - - -

    - - - Merge changes

    - -

    -

    - -
    -

    -

    - - - - - - -

    -

    -


    - github or bitbucket.', 'gitium' ); ?> -

    - - - - - show_webhook_table_webhook_url() ?> - show_webhook_table_public_key(); ?> -
    - git->set_gitignore( $gitignore_content ) ) { - gitium_commit_and_push_gitignore_file(); - $this->success_redirect( __( 'The file `.gitignore` is saved!', 'gitium' ), $this->settings_menu_slug ); - } else { - $this->redirect( __( 'The file `.gitignore` could not be saved!', 'gitium' ), false, $this->settings_menu_slug ); - } - } - - public function page() { - $this->show_message(); - ?> -
    -

    - -
    - - -

    - - - show_webhook_table(); ?> -

    - -

    - -
    -
    - - * - * Gitium is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * any later version. - * - * Gitium is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Gitium. If not, see . - * - * @package Gitium - */ - -class Gitium_Submenu_Status extends Gitium_Menu { - - public function __construct() { - parent::__construct( $this->gitium_menu_slug, $this->gitium_menu_slug ); - - if ( current_user_can( GITIUM_MANAGE_OPTIONS_CAPABILITY ) ) { - add_action( GITIUM_ADMIN_MENU_ACTION, array( $this, 'admin_menu' ) ); - add_action( 'admin_init', array( $this, 'save_changes' ) ); - add_action( 'admin_init', array( $this, 'save_ignorelist' ) ); - add_action( 'admin_init', array( $this, 'disconnect_repository' ) ); - } - } - - public function admin_menu() { - add_menu_page( - __( 'Git Status', 'gitium' ), - 'Gitium', - GITIUM_MANAGE_OPTIONS_CAPABILITY, - $this->menu_slug, - array( $this, 'page' ), - plugins_url( 'img/gitium.png', dirname( __FILE__ ) ) - ); - - $submenu_hook = add_submenu_page( - $this->menu_slug, - __( 'Git Status', 'gitium' ), - __( 'Status', 'gitium' ), - GITIUM_MANAGE_OPTIONS_CAPABILITY, - $this->menu_slug, - array( $this, 'page' ) - ); - new Gitium_Help( $submenu_hook, 'status' ); - } - - private function get_change_meanings() { - return array( - '??' => __( 'untracked', 'gitium' ), - 'rM' => __( 'modified on remote', 'gitium' ), - 'rA' => __( 'added to remote', 'gitium' ), - 'rD' => __( 'deleted from remote', 'gitium' ), - 'D' => __( 'deleted from work tree', 'gitium' ), - 'M' => __( 'updated in work tree', 'gitium' ), - 'A' => __( 'added to work tree', 'gitium' ), - 'AM' => __( 'added to work tree', 'gitium' ), - 'R' => __( 'deleted from work tree', 'gitium' ), - ); - } - - public function humanized_change( $change ) { - $meaning = $this->get_change_meanings(); - - if ( isset( $meaning[ $change ] ) ) { - return $meaning[ $change ]; - } - if ( 0 === strpos( $change, 'R ' ) ) { - $old_filename = substr( $change, 2 ); - $change = sprintf( __( 'renamed from `%s`', 'gitium' ), $old_filename ); - } - return $change; - } - - public function save_ignorelist() { - $gitium_ignore_path = filter_input(INPUT_POST, 'GitiumIgnorePath', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - if ( ! isset( $gitium_ignore_path ) ) { - return; - } else { - $path = $gitium_ignore_path; - } - check_admin_referer( 'gitium-admin' ); - - if ( $this->git->set_gitignore( join( "\n", array_unique( array_merge( explode( "\n", $this->git->get_gitignore() ), array( $path ) ) ) ) ) ) { - gitium_commit_and_push_gitignore_file( $path ); - $this->success_redirect( __( 'The file `.gitignore` is saved!', 'gitium' ), $this->gitium_menu_slug ); - } else { - $this->redirect( __( 'The file `.gitignore` could not be saved!', 'gitium' ), false, $this->gitium_menu_slug ); - } - } - - public function save_changes() { - $gitium_save_changes = filter_input(INPUT_POST, 'GitiumSubmitSaveChanges', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - $gitium_commit_msg = filter_input(INPUT_POST, 'commitmsg', FILTER_SANITIZE_FULL_SPECIAL_CHARS); - - if ( ! isset( $gitium_save_changes ) ) { - return; - } - - check_admin_referer( 'gitium-admin' ); - - gitium_enable_maintenance_mode() or wp_die( __( 'Could not enable the maintenance mode!', 'gitium' ) ); - - $commitmsg = sprintf( __( 'Merged changes from %s on %s', 'gitium' ), get_site_url(), date( 'm.d.Y' ) ); - - if ( isset( $gitium_commit_msg ) && ! empty( $gitium_commit_msg ) ) { - $commitmsg = $gitium_commit_msg; - } - - $commits = array(); - - $current_user = wp_get_current_user(); - - // Get local status and behind commits - $local_status = $this->git->local_status(); - $behind_commits = count( $this->git->get_behind_commits() ); - - if ( $this->git->is_dirty() && $this->git->add() > 0 ) { - $commit = $this->git->commit( $commitmsg, $current_user->display_name, $current_user->user_email ); - if ( ! $commit ) { - gitium_disable_maintenance_mode(); - $this->redirect( __( 'Could not commit!', 'gitium' ) ); - } - $commits[] = $commit; - } - - $merge_success = gitium_merge_and_push( $commits ); - - gitium_disable_maintenance_mode(); - - if ( ! $merge_success ) { - $this->redirect( __( 'Merge failed: ', 'gitium' ) . $this->git->get_last_error() ); - } - - // Determine message based on previous conditions - if ( $behind_commits > 0 && empty( $local_status[1] ) ) { - $this->success_redirect( sprintf( __( 'Pull done!', 'gitium' ) ) ); - } else{ - $this->success_redirect( sprintf( __( 'Pushed commit: `%s`', 'gitium' ), $commitmsg ) ); - } - } - - private function show_ahead_and_behind_info( $changes = '' ) { - $branch = $this->git->get_remote_tracking_branch(); - $ahead = count( $this->git->get_ahead_commits() ); - $behind = count( $this->git->get_behind_commits() ); - ?> -

    - %s.', 'gitium' ), $branch ); - ?>  -

    - - - $type ) : - $counter++; - echo ( 0 != $counter % 2 ) ? '' : ''; - echo '' . esc_html( $path ) . ''; - echo ''; - echo ''; - if ( is_dir( ABSPATH . '/' . $path ) && is_dir( ABSPATH . '/' . trailingslashit( $path ) . '.git' ) ) { // test if is submodule - _e( 'Submodules are not supported in this version.', 'gitium' ); - } else { - echo '' . esc_html( $this->humanized_change( $type ) ) . ''; - } - echo ''; - echo ''; - endforeach; - } - - private function show_git_changes_table( $changes = '' ) { - ?> - - - - - '; - else : - $this->show_git_changes_table_rows( $changes ); - endif; - ?> - -

    '; - _e( 'Nothing to commit, working directory clean.', 'gitium' ); - echo '

    - git->local_status(); - $behind_commits = count( $this->git->get_behind_commits() ); - - // Determine button value based on conditions - if ( $behind_commits > 0 && !empty( $local_status[1] ) ) { - $button_value = __( 'Pull & Push changes', 'gitium' ); - } else if ( $behind_commits > 0 ) { - $button_value = __( 'Pull changes', 'gitium' ); - } else if ( !empty( $local_status[1] ) ) { - $button_value = __( 'Push changes', 'gitium' ); - } - - // Check if there are any changes to display the form - if ( !empty( $changes ) ) : ?> -

    - - -

    -

    - />  -

    - -
    -
     
    -

    git->get_remote_url() ); ?>

    - -
    - show_ahead_and_behind_info( $changes ); - $this->show_git_changes_table( $changes ); - $this->show_git_changes_table_submit_buttons( $changes ); - ?> -
    - show_disconnect_repository_button(); - ?> -
    - show_message(); - _gitium_status( true ); - $this->changes_page(); - } -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/inc/ssh-git b/wp-content/upgrade-temp-backup/plugins/gitium/inc/ssh-git deleted file mode 100755 index ee976562..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/inc/ssh-git +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/sh -SSH_AUTH_SOCK='' -SSH="ssh -q -F /dev/null -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" -if [ -z "$GIT_KEY_FILE" ] ; then - exec $SSH "$@" -else - exec $SSH -i "$GIT_KEY_FILE" "$@" -fi diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/js/copy-to-clipboard.js b/wp-content/upgrade-temp-backup/plugins/gitium/js/copy-to-clipboard.js deleted file mode 100644 index af934807..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/js/copy-to-clipboard.js +++ /dev/null @@ -1,38 +0,0 @@ -document.addEventListener('DOMContentLoaded', function() { - const copyButton = document.getElementById('copyButton'); - - copyButton.addEventListener('click', function() { - // Get the text to copy from the button's data attribute - const textToCopy = copyButton.getAttribute('data-copy-text'); - - // Check if navigator.clipboard is supported - if (navigator.clipboard && navigator.clipboard.writeText) { - navigator.clipboard.writeText(textToCopy) - .then(() => { - alert('Copied to clipboard using navigator: ' + textToCopy); - }) - .catch(err => { - console.error('Could not copy text with navigator: ', err); - }); - } else { - // Deprecated fallback for older browsers - console.warn('Using deprecated document.execCommand("copy") as a fallback. Update your browser for better clipboard support.'); - - // Fallback using document.execCommand - const tempTextarea = document.createElement('textarea'); - tempTextarea.value = textToCopy; - document.body.appendChild(tempTextarea); - tempTextarea.select(); - - try { - document.execCommand('copy'); - alert('Copied to clipboard (using fallback): ' + textToCopy); - } catch (err) { - console.error('Fallback copy failed: ', err); - } - - // Remove the temporary textarea - document.body.removeChild(tempTextarea); - } - }); -}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-es_ES.mo b/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-es_ES.mo deleted file mode 100644 index d0ce249f..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-es_ES.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-es_ES.po b/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-es_ES.po deleted file mode 100644 index 8af1389f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-es_ES.po +++ /dev/null @@ -1,546 +0,0 @@ -msgid "" -msgstr "" -"Project-Id-Version: Gitium\n" -"POT-Creation-Date: 2014-10-20 19:06+0200\n" -"PO-Revision-Date: 2014-11-13 11:20+0200\n" -"Last-Translator: Presslabs \n" -"Language-Team: Presslabs \n" -"Language: English\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 1.5.4\n" -"X-Poedit-KeywordsList: __;_e\n" -"X-Poedit-Basepath: .\n" -"X-Poedit-SourceCharset: UTF-8\n" -"X-Poedit-SearchPath-0: ..\n" - -#: ../inc/class-gitium-submenu-configure.php:34 -#: ../inc/class-gitium-submenu-configure.php:44 -msgid "Git Configuration" -msgstr "Configuración Git" - -#: ../inc/class-gitium-submenu-configure.php:45 -msgid "Configuration" -msgstr "Configuración" - -#: ../inc/class-gitium-submenu-configure.php:59 -msgid "Keypair successfully regenerated." -msgstr "Par de claves regenerado con éxito." - -#: ../inc/class-gitium-submenu-configure.php:78 -msgid "Initial commit" -msgstr "Commit Inicial" - -#: ../inc/class-gitium-submenu-configure.php:94 -msgid "Please specify a valid repo." -msgstr "Por favor, especifique un repo válido" - -#: ../inc/class-gitium-submenu-configure.php:99 -msgid "Could not push to remote" -msgstr "No se pudo empujar al remoto" - -#: ../inc/class-gitium-submenu-configure.php:113 -msgid "Merged existing code from " -msgstr "Código existente fusionado de" - -#: ../inc/class-gitium-submenu-configure.php:116 -msgid "Could not create initial commit -> " -msgstr "No se pudo crear Commit inicial ->" - -#: ../inc/class-gitium-submenu-configure.php:120 -msgid "Could not merge the initial commit -> " -msgstr "No se pudo fusionar el Commit inicial ->" - -#: ../inc/class-gitium-submenu-configure.php:129 -msgid "Remote URL" -msgstr "URL remoto" - -#: ../inc/class-gitium-submenu-configure.php:132 -msgid "" -"This URL provide access to a Git repository via SSH, HTTPS, or Subversion." -msgstr "" -"Este URL proporciona acceso a un repositorio Git vía SSH, HTTPS o Subversión." - -#: ../inc/class-gitium-submenu-configure.php:133 -msgid "" -"If you need to authenticate over \"https://\" instead of SSH use: " -"https://user:pass@github.com/user/example.git" -msgstr "" -"Si necesita autenticar sobre \"https:// en lugar del uso de SSH: " -"https://user:pass@github.com/user/example.git " - -#: ../inc/class-gitium-submenu-configure.php:143 -msgid "Key pair" -msgstr "Par de claves" - -#: ../inc/class-gitium-submenu-configure.php:147 -#: ../inc/class-gitium-submenu-settings.php:80 -msgid "Regenerate Key" -msgstr "Regenerar clave" - -#: ../inc/class-gitium-submenu-configure.php:149 -#: ../inc/class-gitium-submenu-settings.php:81 -msgid "" -"If your code use ssh keybased authentication for git you need to allow write " -"access to your repository using this key." -msgstr "" -"Si su código usa autenticación ssh keybased para git, usted necesita " -"permitir el acceso de escritura a su repositorio utilizando esta clave." - -#: ../inc/class-gitium-submenu-configure.php:150 -#: ../inc/class-gitium-submenu-settings.php:82 -msgid "" -"Checkout instructions for github or bitbucket." -msgstr "" -"Instrucciones de Pedido para github or %s." -msgstr "Siguiendo sucursal remota %s." - -#: ../inc/class-gitium-submenu-status.php:127 -msgid "Everything is up to date" -msgstr "Todo está actualizado" - -#: ../inc/class-gitium-submenu-status.php:130 -#, php-format -msgid "You are %s commits ahead and %s behind remote." -msgstr "Usted está %s Commits por delante y %s por detrás del remoto." - -#: ../inc/class-gitium-submenu-status.php:132 -#, php-format -msgid "You are %s commits ahead remote." -msgstr "Usted está %s Commits delante del remoto." - -#: ../inc/class-gitium-submenu-status.php:134 -#, php-format -msgid "You are %s commits behind remote." -msgstr "Usted está %s Commits detrás del remoto." - -#: ../inc/class-gitium-submenu-status.php:160 -msgid "Add this file to the `.gitignore` list." -msgstr "Añadir este archivo a la lista `.gitignore`." - -#: ../inc/class-gitium-submenu-status.php:163 -msgid "Submodules are not supported in this version." -msgstr "Sub-módulos no son compatibles con esta versión." - -#: ../inc/class-gitium-submenu-status.php:175 -#: ../inc/class-gitium-submenu-status.php:176 -msgid "Path" -msgstr "Ruta" - -#: ../inc/class-gitium-submenu-status.php:175 -#: ../inc/class-gitium-submenu-status.php:176 -msgid "Change" -msgstr "Cambiar" - -#: ../inc/class-gitium-submenu-status.php:181 -msgid "Nothing to commit, working directory clean." -msgstr "Nada que comprometer, directorio de trabajo limpio." - -#: ../inc/class-gitium-submenu-status.php:195 -msgid "Commit message" -msgstr "Comprometer mensaje" - -#: ../inc/class-gitium-submenu-status.php:199 -msgid "Save changes" -msgstr "Guardar cambios" - -#: ../inc/class-gitium-submenu-status.php:209 -msgid "connected to" -msgstr "conectados a" - -#: ../inc/class-gitium-submenu-settings.php:32 ../inc/class-gitium-help.php:81 -msgid "Settings" -msgstr "Ajustes" - -#: ../inc/class-gitium-submenu-settings.php:46 -msgid "" -"Webhook URL regenerates. Please make sure you update any external references." -msgstr "" -"Webhook URL se regenera. Por favor, asegúrese de actualizar todas las " -"referencias externas." - -#: ../inc/class-gitium-submenu-settings.php:55 -msgid "Public key successfully regenerated." -msgstr "Clave pública regenera con éxito." - -#: ../inc/class-gitium-submenu-settings.php:61 -msgid "Webhook URL" -msgstr "URL Webhook" - -#: ../inc/class-gitium-submenu-settings.php:65 -msgid "Regenerate Webhook" -msgstr "Regenerar Webhook" - -#: ../inc/class-gitium-submenu-settings.php:67 -msgid "Pinging this URL triggers an update from remote repository." -msgstr "" -"Hacer ping en esta URL desencadena una actualización del repositorio remoto." - -#: ../inc/class-gitium-submenu-settings.php:77 -msgid "Public Key" -msgstr "Clave Pública" - -#: ../inc/class-gitium-submenu-settings.php:116 -msgid "Gitium Settings" -msgstr "Ajustes Gitium" - -#: ../inc/class-gitium-submenu-settings.php:121 -msgid "Be careful when you modify this list!" -msgstr "¡Tenga cuidado al modificar esta lista!" - -#: ../inc/class-gitium-submenu-settings.php:126 -msgid "Save" -msgstr "Guardar" - -#: ../inc/class-gitium-help.php:26 -msgid "Gitium" -msgstr "Gitium" - -#: ../inc/class-gitium-help.php:27 -msgid "F.A.Q." -msgstr "PF" - -#: ../inc/class-gitium-help.php:32 -msgid "" -"Gitium enables continuous deployment for WordPress integrating with tools " -"such as Github, Bitbucket or Travis-CI. Plugin and theme updates, installs " -"and removals are automatically versioned." -msgstr "" -"Gitium permite el despliegue continuo para integración de WordPress con " -"herramientas como Github, Bitbucket o Travis-CI. El plugin y las " -"actualizaciones de temas, instalaciones y eliminaciones están versionadas " -"automáticamente." - -#: ../inc/class-gitium-help.php:33 -msgid "" -"Ninja code edits from the WordPress editor are also tracked into version " -"control. Gitium is designed for sane development environments." -msgstr "" -"Las ediciones Código Ninja desde el editor de WordPress también son " -"rastreadas en el control de versiones. Gitium está diseñado para entornos de " -"desarrollo sanos." - -#: ../inc/class-gitium-help.php:34 -msgid "" -"Staging and production can follow different branches of the same repository. " -"You can deploy code simply trough git push." -msgstr "" -"Puesta en escena y producción pueden seguir diferentes ramas del mismo " -"repositorio. Puede implementar código simplemente a través git push." - -#: ../inc/class-gitium-help.php:35 -msgid "" -"Gitium requires git command line tool minimum version 1.7 " -"installed on the server and proc_open PHP function enabled." -msgstr "" -"Gitium requiere la herramienta de línea de comandos git , " -"mínimo la versión 1.7 instalada en el servidor y proc_open la " -"función PHP habilitada." - -#: ../inc/class-gitium-help.php:39 -msgid "Is this plugin considered stable?" -msgstr "¿Es este plugin considerado estable?" - -#: ../inc/class-gitium-help.php:39 -msgid "" -"Right now this plugin is considered alpha quality and should be used in " -"production environments only by adventurous kinds." -msgstr "" -"Ahora mismo este plugin se considera de calidad alfa y debe utilizarse en " -"entornos de producción sólo por tipos aventureros." - -#: ../inc/class-gitium-help.php:40 -msgid "What happens in case of conflicts?" -msgstr "¿Qué sucede en caso de conflictos?" - -#: ../inc/class-gitium-help.php:40 -msgid "" -"The behavior in case of conflicts is to overwrite the changes on the origin " -"repository with the local changes (ie. local modifications take precedence " -"over remote ones)." -msgstr "" -"El comportamiento en caso de conflictos es sobrescribir los cambios en el " -"repositorio de origen con los cambios locales (p.ej. las modificaciones " -"locales toman precedencia sobre las remotas)." - -#: ../inc/class-gitium-help.php:41 -msgid "How to deploy automatically after a push?" -msgstr "¿Cómo implementar automáticamente después de un empujón?" - -#: ../inc/class-gitium-help.php:41 -msgid "" -"You can ping the webhook url after a push to automatically deploy the new " -"code. The webhook url can be found under Code menu. This url plays well with " -"Github or Bitbucket webhooks." -msgstr "" -"Puede hacer ping en la url webhook después de un empujón para distribuir " -"automáticamente el nuevo código. La url webhook se puede encontrar en el " -"menú Código. Esta url juega bien con Github o BitBucket WebHooks." - -#: ../inc/class-gitium-help.php:42 -msgid "Does it works on multi site setups?" -msgstr "¿Trabaja en múltiples configuraciones de sitio?" - -#: ../inc/class-gitium-help.php:42 -msgid "Gitium is not supporting multisite setups at the moment." -msgstr "" -"Gitium no soporta a las configuraciones de múltiples sitios en este momento." - -#: ../inc/class-gitium-help.php:43 -msgid "How does gitium handle submodules?" -msgstr "¿Cómo manejar gitium los submódulos?" - -#: ../inc/class-gitium-help.php:43 -msgid "Currently submodules are not supported." -msgstr "Actualmente los submódulos no son compatibles." - -#: ../inc/class-gitium-help.php:47 -msgid "" -"In this step you must specify the Remote URL. This URL " -"represents the link between the git sistem and your site." -msgstr "" -"En esta etapa, se debe especificar el URL remoto . Esta URL " -"representa el enlace entre el sistema git y su sitio." - -#: ../inc/class-gitium-help.php:48 -msgid "You can get this URL from your Git repository and it looks like this:" -msgstr "" -"Usted puede obtener esta dirección URL de su repositorio Git y se ve así:" - -#: ../inc/class-gitium-help.php:49 -msgid "github.com -> git@github.com:user/example.git" -msgstr "github.com -> git@github.com:user/example.git" - -#: ../inc/class-gitium-help.php:50 -msgid "bitbucket.org -> git@bitbucket.org:user/glowing-happiness.git" -msgstr "bitbucket.org -> git@bitbucket.org:user/glowing-happiness.git" - -#: ../inc/class-gitium-help.php:51 -msgid "" -"To go to the next step, fill the Remote URL and then press the " -"Fetch button." -msgstr "" -"Para ir al siguiente paso, llene la URL remota y pulse el " -"botón Buscar ." - -#: ../inc/class-gitium-help.php:52 -msgid "" -"In this step you must select the branch you want to follow." -msgstr "" -"En este paso deberá seleccionar la rama que desea seguir." - -#: ../inc/class-gitium-help.php:53 -msgid "Only this branch will have all of your code modifications." -msgstr "Sólo esta rama tendrá todas sus modificaciones de código." - -#: ../inc/class-gitium-help.php:54 -msgid "" -"When you push the button Merge & Push, all code(plugins & " -"themes) will be pushed on the git repository." -msgstr "" -"Cuando se presiona el botón Combinar y Empujar , todo el " -"código (plugins y temas) serán empujados en el repositorio git." - -#: ../inc/class-gitium-help.php:64 -msgid "" -"On status page you can see what files are modified, and you can commit the " -"changes to git." -msgstr "" -"En la página de estado se puede ver qué archivos son modificados, y usted " -"puede confirmar los cambios a Git." - -#: ../inc/class-gitium-help.php:69 ../inc/class-gitium-submenu-commits.php:29 -#: ../inc/class-gitium-submenu-commits.php:41 -msgid "Commits" -msgstr "Commits" - -#: ../inc/class-gitium-help.php:74 -msgid "" -"You may be wondering what is the difference between author and committer." -msgstr "" -"Usted puede preguntarse cuál es la diferencia entre el autor y el comitter." - -#: ../inc/class-gitium-help.php:75 -msgid "" -"The author is the person who originally wrote the patch, " -"whereas the committer is the person who last applied the patch." -msgstr "" -"El autor es la persona que originalmente escribió el parche, " -"mientras que el committer es la persona que aplicó el parche " -"al final." - -#: ../inc/class-gitium-help.php:76 -msgid "" -"So, if you send in a patch to a project and one of the core members applies " -"the patch, both of you get credit — you as the author and the core member as " -"the committer." -msgstr "" -"Por lo tanto, si usted envía en un parche para un proyecto y uno de los " -"principales miembros aplica el parche, ambos consiguen crédito - usted como " -"el autor y el miembro de núcleo como el commiter." - -#: ../inc/class-gitium-help.php:86 -msgid "Each line from the gitignore file specifies a pattern." -msgstr "Cada línea del archivo gitignore especifica un patrón." - -#: ../inc/class-gitium-help.php:87 -msgid "" -"When deciding whether to ignore a path, Git normally checks gitignore " -"patterns from multiple sources, with the following order of precedence, from " -"highest to lowest (within one level of precedence, the last matching pattern " -"decides the outcome)" -msgstr "" -"A la hora de decidir si se debe pasar por alto una ruta, Git normalmente " -"comprueba patrones gitignore de múltiples fuentes, con el siguiente orden, " -"de de mayor a menor (dentro de un nivel de prioridad, la última " -"coincidencia de patrones decide el resultado)" - -#: ../inc/class-gitium-help.php:88 -#, php-format -msgid "Read more on %s" -msgstr "Leer más en %s" - -#: ../inc/class-gitium-submenu-commits.php:28 -msgid "Git Commits" -msgstr "Commits Git" - -#: ../inc/class-gitium-submenu-commits.php:61 -#, php-format -msgid "Last %s commits" -msgstr "Últimos commits %s" - -#: ../inc/class-gitium-submenu-commits.php:70 -#, php-format -msgid "committed %s ago" -msgstr "cometido hace %s" - -#: ../inc/class-gitium-submenu-commits.php:82 -#, php-format -msgid "authored %s ago" -msgstr "Creado hace %s" diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-sr_RS.mo b/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-sr_RS.mo deleted file mode 100644 index 677d3bf3..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-sr_RS.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-sr_RS.po b/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-sr_RS.po deleted file mode 100644 index 09cb064a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium-sr_RS.po +++ /dev/null @@ -1,538 +0,0 @@ -msgid "" -msgstr "" -"Project-Id-Version: Gitium\n" -"POT-Creation-Date: 2014-10-20 19:06+0200\n" -"PO-Revision-Date: 2014-10-24 12:51+0200\n" -"Last-Translator: Presslabs \n" -"Language-Team: Presslabs \n" -"Language: English\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 1.5.4\n" -"X-Poedit-KeywordsList: __;_e\n" -"X-Poedit-Basepath: .\n" -"X-Poedit-SourceCharset: UTF-8\n" -"X-Poedit-SearchPath-0: ..\n" - -#: ../inc/class-gitium-submenu-configure.php:34 -#: ../inc/class-gitium-submenu-configure.php:44 -msgid "Git Configuration" -msgstr "Git konfiguracija" - -#: ../inc/class-gitium-submenu-configure.php:45 -msgid "Configuration" -msgstr "Konfiguracija" - -#: ../inc/class-gitium-submenu-configure.php:59 -msgid "Keypair successfully regenerated." -msgstr "Par ključeva uspešno regenerisan" - -#: ../inc/class-gitium-submenu-configure.php:78 -msgid "Initial commit" -msgstr "Početna uputstva" - -#: ../inc/class-gitium-submenu-configure.php:94 -msgid "Please specify a valid repo." -msgstr "Odaberite važeće spremište" - -#: ../inc/class-gitium-submenu-configure.php:99 -msgid "Could not push to remote" -msgstr "Neuspelo potiskivanje u udaljeno spremište" - -#: ../inc/class-gitium-submenu-configure.php:113 -msgid "Merged existing code from " -msgstr "Postojeći kod spojen sa" - -#: ../inc/class-gitium-submenu-configure.php:116 -msgid "Could not create initial commit -> " -msgstr "Neuspelo kreiranje početnog uputstva ->" - -#: ../inc/class-gitium-submenu-configure.php:120 -msgid "Could not merge the initial commit -> " -msgstr "Neuspelo spajanje početnog uputstva ->" - -#: ../inc/class-gitium-submenu-configure.php:129 -msgid "Remote URL" -msgstr "URL udaljenog spremišta" - -#: ../inc/class-gitium-submenu-configure.php:132 -msgid "" -"This URL provide access to a Git repository via SSH, HTTPS, or Subversion." -msgstr "" -"Ovaj URL obezbeđuje pristup Git skladištu putem SSH-a, HTTPS-a ili " -"Subverzije." - -#: ../inc/class-gitium-submenu-configure.php:133 -msgid "" -"If you need to authenticate over \"https://\" instead of SSH use: " -"https://user:pass@github.com/user/example.git" -msgstr "" -"Ako treba da proverite preko \"https://\" umesto SSH, koristite: " -"https://user:pass@github.com/user/example.git" - -#: ../inc/class-gitium-submenu-configure.php:143 -msgid "Key pair" -msgstr "Par ključeva" - -#: ../inc/class-gitium-submenu-configure.php:147 -#: ../inc/class-gitium-submenu-settings.php:80 -msgid "Regenerate Key" -msgstr "Ključ za regenerisanje" - -#: ../inc/class-gitium-submenu-configure.php:149 -#: ../inc/class-gitium-submenu-settings.php:81 -msgid "" -"If your code use ssh keybased authentication for git you need to allow write " -"access to your repository using this key." -msgstr "" -"Ako vaš kod koristi git autentifikaciju na osnovu ssh ključa, morate pismeno " -"dozvoliti pristup svom spremištu uz pomoć ovog ključa. " - -#: ../inc/class-gitium-submenu-configure.php:150 -#: ../inc/class-gitium-submenu-settings.php:82 -msgid "" -"Checkout instructions for github or bitbucket." -msgstr "" -"Pogledajte uputstva na github " -"ili bitbucket." - -#: ../inc/class-gitium-submenu-configure.php:160 -msgid "Warning!" -msgstr "Upozorenje!" - -#: ../inc/class-gitium-submenu-configure.php:174 -#: ../inc/class-gitium-help.php:47 -msgid "Configuration step 1" -msgstr "Konfiguracija, korak 1" - -#: ../inc/class-gitium-submenu-configure.php:175 -#: ../inc/class-gitium-submenu-configure.php:194 -msgid "" -"If you need help to set this up, please click on the \"Help\" button from " -"the top right corner of this screen." -msgstr "" -"Ako vam treba pomoć za ovo podešavanje, kliknite na taster \"Pomoć\" u " -"gornjem desnom uglu ekrana." - -#: ../inc/class-gitium-submenu-configure.php:183 -msgid "Fetch" -msgstr "Uzmi" - -#: ../inc/class-gitium-submenu-configure.php:193 -#: ../inc/class-gitium-help.php:52 -msgid "Configuration step 2" -msgstr "Konfiguracija, korak 2" - -#: ../inc/class-gitium-submenu-configure.php:202 -msgid "Choose tracking branch" -msgstr "Odaberite ogranak za praćenje" - -#: ../inc/class-gitium-submenu-configure.php:215 -msgid "Merge & Push" -msgstr "Spoji & Potisni" - -#: ../inc/class-gitium-submenu-status.php:32 -#: ../inc/class-gitium-submenu-status.php:42 -msgid "Git Status" -msgstr "Git Status" - -#: ../inc/class-gitium-submenu-status.php:43 -#: ../inc/class-gitium-submenu-status.php:209 ../inc/class-gitium-help.php:59 -msgid "Status" -msgstr "Status" - -#: ../inc/class-gitium-submenu-status.php:53 -msgid "untracked" -msgstr "nepraćen" - -#: ../inc/class-gitium-submenu-status.php:54 -msgid "modified on remote" -msgstr "modifikovan na udaljenom skladištu" - -#: ../inc/class-gitium-submenu-status.php:55 -msgid "added to remote" -msgstr "dodat udaljenom skladištu" - -#: ../inc/class-gitium-submenu-status.php:56 -msgid "deleted from remote" -msgstr "obrisan sa udaljenog skladišta" - -#: ../inc/class-gitium-submenu-status.php:57 -#: ../inc/class-gitium-submenu-status.php:61 -msgid "deleted from work tree" -msgstr "obrisan sa radnog drveta" - -#: ../inc/class-gitium-submenu-status.php:58 -msgid "updated in work tree" -msgstr "ažuriran u radnom drvetu" - -#: ../inc/class-gitium-submenu-status.php:59 -#: ../inc/class-gitium-submenu-status.php:60 -msgid "added to work tree" -msgstr "dodat radnom drvetu" - -#: ../inc/class-gitium-submenu-status.php:73 -#, php-format -msgid "renamed from `%s`" -msgstr "ime `%s` promenjeno" - -#: ../inc/class-gitium-submenu-status.php:88 -#: ../inc/class-gitium-submenu-settings.php:106 -msgid "The file `.gitignore` is saved!" -msgstr "Datoteka `.gitignore` je sačuvana!" - -#: ../inc/class-gitium-submenu-status.php:90 -#: ../inc/class-gitium-submenu-settings.php:108 -msgid "The file `.gitignore` could not be saved!" -msgstr "Datoteka `.gitignore` ne može biti sačuvana!" - -#: ../inc/class-gitium-submenu-status.php:100 -msgid "Could not enable the maintenance mode!" -msgstr "Režim održavanja nije mogao biti aktiviran!" - -#: ../inc/class-gitium-submenu-status.php:102 -#: ../inc/class-gitium-submenu-status.php:196 -#, php-format -msgid "Merged changes from %s on %s" -msgstr "Promene sa %s na %s spojene!" - -#: ../inc/class-gitium-submenu-status.php:109 -msgid "Could not commit!" -msgstr "Neuspelo izvršenje!" - -#: ../inc/class-gitium-submenu-status.php:114 -msgid "Merge failed: " -msgstr "Neuspelo spajanje:" - -#: ../inc/class-gitium-submenu-status.php:116 -#, php-format -msgid "Pushed commit: `%s`" -msgstr "Preneto izvršenje: `%s`" - -#: ../inc/class-gitium-submenu-status.php:125 -#, php-format -msgid "Following remote branch %s." -msgstr "Praćenje udaljenog ogranka%s." - -#: ../inc/class-gitium-submenu-status.php:127 -msgid "Everything is up to date" -msgstr "Sve je ažurirano" - -#: ../inc/class-gitium-submenu-status.php:130 -#, php-format -msgid "You are %s commits ahead and %s behind remote." -msgstr "Vi ste %s izvršenja ispred i %s iza udaljenog spremišta." - -#: ../inc/class-gitium-submenu-status.php:132 -#, php-format -msgid "You are %s commits ahead remote." -msgstr "Vi ste %s izvršenja ispred udaljenog spremišta." - -#: ../inc/class-gitium-submenu-status.php:134 -#, php-format -msgid "You are %s commits behind remote." -msgstr "Vi ste %s izvršenja iza udaljenog spremišta." - -#: ../inc/class-gitium-submenu-status.php:160 -msgid "Add this file to the `.gitignore` list." -msgstr "Dodajte ovu datoteku `.gitignore` listi." - -#: ../inc/class-gitium-submenu-status.php:163 -msgid "Submodules are not supported in this version." -msgstr "U ovoj verziji nisu podržani submoduli." - -#: ../inc/class-gitium-submenu-status.php:175 -#: ../inc/class-gitium-submenu-status.php:176 -msgid "Path" -msgstr "Putanja" - -#: ../inc/class-gitium-submenu-status.php:175 -#: ../inc/class-gitium-submenu-status.php:176 -msgid "Change" -msgstr "Izmeni" - -#: ../inc/class-gitium-submenu-status.php:181 -msgid "Nothing to commit, working directory clean." -msgstr "Nema ničega za izvršenje, radni direktorijum je čist." - -#: ../inc/class-gitium-submenu-status.php:195 -msgid "Commit message" -msgstr "Poruka o izvršenju" - -#: ../inc/class-gitium-submenu-status.php:199 -msgid "Save changes" -msgstr "Sačuvaj izmene" - -#: ../inc/class-gitium-submenu-status.php:209 -msgid "connected to" -msgstr "povezan sa" - -#: ../inc/class-gitium-submenu-settings.php:32 ../inc/class-gitium-help.php:81 -msgid "Settings" -msgstr "Podešavanja" - -#: ../inc/class-gitium-submenu-settings.php:46 -msgid "" -"Webhook URL regenerates. Please make sure you update any external references." -msgstr "" -"Webhook URL se regeneriše. Proverite da li ste ažurirali eksterne reference." - -#: ../inc/class-gitium-submenu-settings.php:55 -msgid "Public key successfully regenerated." -msgstr "Javni ključ uspešno regenerisan." - -#: ../inc/class-gitium-submenu-settings.php:61 -msgid "Webhook URL" -msgstr "Webhook URL" - -#: ../inc/class-gitium-submenu-settings.php:65 -msgid "Regenerate Webhook" -msgstr "Regeneriši webhook" - -#: ../inc/class-gitium-submenu-settings.php:67 -msgid "Pinging this URL triggers an update from remote repository." -msgstr "Pingovanje ovog URL-a povlači ažuriranje iz udaljenog skladišta." - -#: ../inc/class-gitium-submenu-settings.php:77 -msgid "Public Key" -msgstr "Javni ključ" - -#: ../inc/class-gitium-submenu-settings.php:116 -msgid "Gitium Settings" -msgstr "Gitium podešavanja" - -#: ../inc/class-gitium-submenu-settings.php:121 -msgid "Be careful when you modify this list!" -msgstr "Oprezno menjajte ovu listu!" - -#: ../inc/class-gitium-submenu-settings.php:126 -msgid "Save" -msgstr "Sačuvaj" - -#: ../inc/class-gitium-help.php:26 -msgid "Gitium" -msgstr "Gitium" - -#: ../inc/class-gitium-help.php:27 -msgid "F.A.Q." -msgstr "Često postavljana pitanja" - -#: ../inc/class-gitium-help.php:32 -msgid "" -"Gitium enables continuous deployment for WordPress integrating with tools " -"such as Github, Bitbucket or Travis-CI. Plugin and theme updates, installs " -"and removals are automatically versioned." -msgstr "" -"Gitium omogućava kontinuiranu primenu WordPress integrisanja alatima, kao " -"što su: Github, Bitbucket ili Travis-CI. Ažuriranja plugin-a i teme, " -"instalacije i uklanjanja automatski su verzionirani." - -#: ../inc/class-gitium-help.php:33 -msgid "" -"Ninja code edits from the WordPress editor are also tracked into version " -"control. Gitium is designed for sane development environments." -msgstr "" -"Nindža kod, koji uređuje iz WordPress uređivača, takođe se prati u kontroli " -"verzije. Gitium je dizajniran za razumna razvojna okruženja." - -#: ../inc/class-gitium-help.php:34 -msgid "" -"Staging and production can follow different branches of the same repository. " -"You can deploy code simply trough git push." -msgstr "" -"Postavljanje i proizvodnja mogu da prate različite grane istog spremišta. " -"Možete da primenite kod jednostavno kroz git push." - -#: ../inc/class-gitium-help.php:35 -msgid "" -"Gitium requires git command line tool minimum version 1.7 " -"installed on the server and proc_open PHP function enabled." -msgstr "" -"Gitium zahteva da na serveru bude instaliran git alat komandne " -"linije, najmanje verzije 1.7 i proc_open aktiviranu PHP " -"funkciju." - -#: ../inc/class-gitium-help.php:39 -msgid "Is this plugin considered stable?" -msgstr "Da li se ovaj plugin smatra stabilnim?" - -#: ../inc/class-gitium-help.php:39 -msgid "" -"Right now this plugin is considered alpha quality and should be used in " -"production environments only by adventurous kinds." -msgstr "" -"Trenutno se smatra da ovaj plugin ima alfa kvalitet i treba ga koristiti u " -"okruženjima produkcije isključivo avanturističkog karaktera." - -#: ../inc/class-gitium-help.php:40 -msgid "What happens in case of conflicts?" -msgstr "Šta se dešava u slučaju konflikta?" - -#: ../inc/class-gitium-help.php:40 -msgid "" -"The behavior in case of conflicts is to overwrite the changes on the origin " -"repository with the local changes (ie. local modifications take precedence " -"over remote ones)." -msgstr "" -"U slučaju konflikta treba poništiti izmene u prvobitnom spremištu, zajedno " -"sa lokalnim izmenama (tj. Lokalne izmene imaju prednost u odnosu na " -"udaljene)." - -#: ../inc/class-gitium-help.php:41 -msgid "How to deploy automatically after a push?" -msgstr "Kako izvršiti automatsko razmeštanje posle pritiska?" - -#: ../inc/class-gitium-help.php:41 -msgid "" -"You can ping the webhook url after a push to automatically deploy the new " -"code. The webhook url can be found under Code menu. This url plays well with " -"Github or Bitbucket webhooks." -msgstr "" -"Možete pingovati url za webhook nakon pritiska za automatsko razmeštanje " -"novog koda. URL za webhook možete naći u meniju koda. Ovaj url dobro radi uz " -"Github ili Bitbucket webhooks." - -#: ../inc/class-gitium-help.php:42 -msgid "Does it works on multi site setups?" -msgstr "Da li radi na podešavanjima višestrukih site-ova?" - -#: ../inc/class-gitium-help.php:42 -msgid "Gitium is not supporting multisite setups at the moment." -msgstr "Gitium trenutno ne podržava podešavanje višestrukih site-ova." - -#: ../inc/class-gitium-help.php:43 -msgid "How does gitium handle submodules?" -msgstr "Kako gitium upravlja submodulima?" - -#: ../inc/class-gitium-help.php:43 -msgid "Currently submodules are not supported." -msgstr "Trenutno, submoduli nisu podržani." - -#: ../inc/class-gitium-help.php:47 -msgid "" -"In this step you must specify the Remote URL. This URL " -"represents the link between the git sistem and your site." -msgstr "" -"U ovom koraku morate odrediti Udaljeni URL. Ovaj URL " -"predstavlja vezu između git sistema i vašeg site-a." - -#: ../inc/class-gitium-help.php:48 -msgid "You can get this URL from your Git repository and it looks like this:" -msgstr "Ovaj URL možete dobiti iz svog Git spremišta i on izgleda ovako:" - -#: ../inc/class-gitium-help.php:49 -msgid "github.com -> git@github.com:user/example.git" -msgstr "github.com -> git@github.com:user/example.git" - -#: ../inc/class-gitium-help.php:50 -msgid "bitbucket.org -> git@bitbucket.org:user/glowing-happiness.git" -msgstr "bitbucket.org -> git@bitbucket.org:user/glowing-happines.git" - -#: ../inc/class-gitium-help.php:51 -msgid "" -"To go to the next step, fill the Remote URL and then press the " -"Fetch button." -msgstr "" -"Da biste prešli na sledeći korak, popunite Udaljeni URL i " -"pritisnite Dobavi taster." - -#: ../inc/class-gitium-help.php:52 -msgid "" -"In this step you must select the branch you want to follow." -msgstr "" -"U ovom koraku morate odabrati ogranak koji želite da pratite. " - -#: ../inc/class-gitium-help.php:53 -msgid "Only this branch will have all of your code modifications." -msgstr "Samo će ovaj ogranak imati sve vaše modifikacije koda." - -#: ../inc/class-gitium-help.php:54 -msgid "" -"When you push the button Merge & Push, all code(plugins & " -"themes) will be pushed on the git repository." -msgstr "" -"Kad kliknete na taster Spoji & Potisni svi (plugin-ovi i teme) " -"koda biće potisnuti u git spremište." - -#: ../inc/class-gitium-help.php:64 -msgid "" -"On status page you can see what files are modified, and you can commit the " -"changes to git." -msgstr "" -"Na stranici statusa možete videti koje su datoteke izmenjene i možete uneti " -"izmene u git." - -#: ../inc/class-gitium-help.php:69 ../inc/class-gitium-submenu-commits.php:29 -#: ../inc/class-gitium-submenu-commits.php:41 -msgid "Commits" -msgstr "Izvršenja" - -#: ../inc/class-gitium-help.php:74 -msgid "" -"You may be wondering what is the difference between author and committer." -msgstr "Možda se pitate u čemu je razlika između autora i izvršioca?" - -#: ../inc/class-gitium-help.php:75 -msgid "" -"The author is the person who originally wrote the patch, " -"whereas the committer is the person who last applied the patch." -msgstr "" -"Autor je osoba koja je originalno napisala zakrpu, dok je " -"izvršilac osoba koja je poslednja primenila zakrpu." - -#: ../inc/class-gitium-help.php:76 -msgid "" -"So, if you send in a patch to a project and one of the core members applies " -"the patch, both of you get credit — you as the author and the core member as " -"the committer." -msgstr "" -"Dakle, ako pošaljete zakrpu projektu i jedan od ključnih članova je primeni " -"- oboje dobijate zasluge - vi kao autor, a ključni član kao izvršilac." - -#: ../inc/class-gitium-help.php:86 -msgid "Each line from the gitignore file specifies a pattern." -msgstr "Svaka linija iz gitignore datoteke označava šablon." - -#: ../inc/class-gitium-help.php:87 -msgid "" -"When deciding whether to ignore a path, Git normally checks gitignore " -"patterns from multiple sources, with the following order of precedence, from " -"highest to lowest (within one level of precedence, the last matching pattern " -"decides the outcome)" -msgstr "" -"Kad odlučujete o tome da li ćete ignorisati putanju, Git obično proverava " -"gitignore šablone iz višestrukih izvora, sa sledećim redosledom - od " -"najvišeg do najnižeg (u okviru jednog nivoa prednosti, poslednji šablon koji " -"se poklapa odlučuje o ishodu)." - -#: ../inc/class-gitium-help.php:88 -#, php-format -msgid "Read more on %s" -msgstr "Pročitajte više o %s" - -#: ../inc/class-gitium-submenu-commits.php:28 -msgid "Git Commits" -msgstr "Git izvršenja" - -#: ../inc/class-gitium-submenu-commits.php:61 -#, php-format -msgid "Last %s commits" -msgstr "Poslednja %s izvršenja" - -#: ../inc/class-gitium-submenu-commits.php:70 -#, php-format -msgid "committed %s ago" -msgstr "izvršena pre %s" - -#: ../inc/class-gitium-submenu-commits.php:82 -#, php-format -msgid "authored %s ago" -msgstr "autorizovana pre %s" diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium.pot b/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium.pot deleted file mode 100644 index 807f7dae..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/languages/gitium.pot +++ /dev/null @@ -1,489 +0,0 @@ -msgid "" -msgstr "" -"Project-Id-Version: Gitium\n" -"POT-Creation-Date: 2014-10-20 19:06+0200\n" -"PO-Revision-Date: 2014-10-20 19:06+0200\n" -"Last-Translator: Presslabs \n" -"Language-Team: Presslabs \n" -"Language: English\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 1.5.4\n" -"X-Poedit-KeywordsList: __;_e\n" -"X-Poedit-Basepath: .\n" -"X-Poedit-SourceCharset: UTF-8\n" -"X-Poedit-SearchPath-0: ..\n" - -#: ../inc/class-gitium-submenu-configure.php:34 -#: ../inc/class-gitium-submenu-configure.php:44 -msgid "Git Configuration" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:45 -msgid "Configuration" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:59 -msgid "Keypair successfully regenerated." -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:78 -msgid "Initial commit" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:94 -msgid "Please specify a valid repo." -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:99 -msgid "Could not push to remote" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:113 -msgid "Merged existing code from " -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:116 -msgid "Could not create initial commit -> " -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:120 -msgid "Could not merge the initial commit -> " -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:129 -msgid "Remote URL" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:132 -msgid "" -"This URL provide access to a Git repository via SSH, HTTPS, or Subversion." -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:133 -msgid "" -"If you need to authenticate over \"https://\" instead of SSH use: " -"https://user:pass@github.com/user/example.git" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:143 -msgid "Key pair" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:147 -#: ../inc/class-gitium-submenu-settings.php:80 -msgid "Regenerate Key" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:149 -#: ../inc/class-gitium-submenu-settings.php:81 -msgid "" -"If your code use ssh keybased authentication for git you need to allow write " -"access to your repository using this key." -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:150 -#: ../inc/class-gitium-submenu-settings.php:82 -msgid "" -"Checkout instructions for github or bitbucket." -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:160 -msgid "Warning!" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:174 -#: ../inc/class-gitium-help.php:47 -msgid "Configuration step 1" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:175 -#: ../inc/class-gitium-submenu-configure.php:194 -msgid "" -"If you need help to set this up, please click on the \"Help\" button from " -"the top right corner of this screen." -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:183 -msgid "Fetch" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:193 -#: ../inc/class-gitium-help.php:52 -msgid "Configuration step 2" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:202 -msgid "Choose tracking branch" -msgstr "" - -#: ../inc/class-gitium-submenu-configure.php:215 -msgid "Merge & Push" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:32 -#: ../inc/class-gitium-submenu-status.php:42 -msgid "Git Status" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:43 -#: ../inc/class-gitium-submenu-status.php:209 ../inc/class-gitium-help.php:59 -msgid "Status" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:53 -msgid "untracked" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:54 -msgid "modified on remote" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:55 -msgid "added to remote" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:56 -msgid "deleted from remote" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:57 -#: ../inc/class-gitium-submenu-status.php:61 -msgid "deleted from work tree" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:58 -msgid "updated in work tree" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:59 -#: ../inc/class-gitium-submenu-status.php:60 -msgid "added to work tree" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:73 -#, php-format -msgid "renamed from `%s`" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:88 -#: ../inc/class-gitium-submenu-settings.php:106 -msgid "The file `.gitignore` is saved!" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:90 -#: ../inc/class-gitium-submenu-settings.php:108 -msgid "The file `.gitignore` could not be saved!" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:100 -msgid "Could not enable the maintenance mode!" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:102 -#: ../inc/class-gitium-submenu-status.php:196 -#, php-format -msgid "Merged changes from %s on %s" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:109 -msgid "Could not commit!" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:114 -msgid "Merge failed: " -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:116 -#, php-format -msgid "Pushed commit: `%s`" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:125 -#, php-format -msgid "Following remote branch %s." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:127 -msgid "Everything is up to date" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:130 -#, php-format -msgid "You are %s commits ahead and %s behind remote." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:132 -#, php-format -msgid "You are %s commits ahead remote." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:134 -#, php-format -msgid "You are %s commits behind remote." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:160 -msgid "Add this file to the `.gitignore` list." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:163 -msgid "Submodules are not supported in this version." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:175 -#: ../inc/class-gitium-submenu-status.php:176 -msgid "Path" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:175 -#: ../inc/class-gitium-submenu-status.php:176 -msgid "Change" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:181 -msgid "Nothing to commit, working directory clean." -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:195 -msgid "Commit message" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:199 -msgid "Save changes" -msgstr "" - -#: ../inc/class-gitium-submenu-status.php:209 -msgid "connected to" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:32 ../inc/class-gitium-help.php:81 -msgid "Settings" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:46 -msgid "" -"Webhook URL regenerates. Please make sure you update any external references." -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:55 -msgid "Public key successfully regenerated." -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:61 -msgid "Webhook URL" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:65 -msgid "Regenerate Webhook" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:67 -msgid "Pinging this URL triggers an update from remote repository." -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:77 -msgid "Public Key" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:116 -msgid "Gitium Settings" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:121 -msgid "Be careful when you modify this list!" -msgstr "" - -#: ../inc/class-gitium-submenu-settings.php:126 -msgid "Save" -msgstr "" - -#: ../inc/class-gitium-help.php:26 -msgid "Gitium" -msgstr "" - -#: ../inc/class-gitium-help.php:27 -msgid "F.A.Q." -msgstr "" - -#: ../inc/class-gitium-help.php:32 -msgid "" -"Gitium enables continuous deployment for WordPress integrating with tools " -"such as Github, Bitbucket or Travis-CI. Plugin and theme updates, installs " -"and removals are automatically versioned." -msgstr "" - -#: ../inc/class-gitium-help.php:33 -msgid "" -"Ninja code edits from the WordPress editor are also tracked into version " -"control. Gitium is designed for sane development environments." -msgstr "" - -#: ../inc/class-gitium-help.php:34 -msgid "" -"Staging and production can follow different branches of the same repository. " -"You can deploy code simply trough git push." -msgstr "" - -#: ../inc/class-gitium-help.php:35 -msgid "" -"Gitium requires git command line tool minimum version 1.7 " -"installed on the server and proc_open PHP function enabled." -msgstr "" - -#: ../inc/class-gitium-help.php:39 -msgid "Is this plugin considered stable?" -msgstr "" - -#: ../inc/class-gitium-help.php:39 -msgid "" -"Right now this plugin is considered alpha quality and should be used in " -"production environments only by adventurous kinds." -msgstr "" - -#: ../inc/class-gitium-help.php:40 -msgid "What happens in case of conflicts?" -msgstr "" - -#: ../inc/class-gitium-help.php:40 -msgid "" -"The behavior in case of conflicts is to overwrite the changes on the origin " -"repository with the local changes (ie. local modifications take precedence " -"over remote ones)." -msgstr "" - -#: ../inc/class-gitium-help.php:41 -msgid "How to deploy automatically after a push?" -msgstr "" - -#: ../inc/class-gitium-help.php:41 -msgid "" -"You can ping the webhook url after a push to automatically deploy the new " -"code. The webhook url can be found under Code menu. This url plays well with " -"Github or Bitbucket webhooks." -msgstr "" - -#: ../inc/class-gitium-help.php:42 -msgid "Does it works on multi site setups?" -msgstr "" - -#: ../inc/class-gitium-help.php:42 -msgid "Gitium is not supporting multisite setups at the moment." -msgstr "" - -#: ../inc/class-gitium-help.php:43 -msgid "How does gitium handle submodules?" -msgstr "" - -#: ../inc/class-gitium-help.php:43 -msgid "Currently submodules are not supported." -msgstr "" - -#: ../inc/class-gitium-help.php:47 -msgid "" -"In this step you must specify the Remote URL. This URL " -"represents the link between the git sistem and your site." -msgstr "" - -#: ../inc/class-gitium-help.php:48 -msgid "You can get this URL from your Git repository and it looks like this:" -msgstr "" - -#: ../inc/class-gitium-help.php:49 -msgid "github.com -> git@github.com:user/example.git" -msgstr "" - -#: ../inc/class-gitium-help.php:50 -msgid "bitbucket.org -> git@bitbucket.org:user/glowing-happiness.git" -msgstr "" - -#: ../inc/class-gitium-help.php:51 -msgid "" -"To go to the next step, fill the Remote URL and then press the " -"Fetch button." -msgstr "" - -#: ../inc/class-gitium-help.php:52 -msgid "" -"In this step you must select the branch you want to follow." -msgstr "" - -#: ../inc/class-gitium-help.php:53 -msgid "Only this branch will have all of your code modifications." -msgstr "" - -#: ../inc/class-gitium-help.php:54 -msgid "" -"When you push the button Merge & Push, all code(plugins & " -"themes) will be pushed on the git repository." -msgstr "" - -#: ../inc/class-gitium-help.php:64 -msgid "" -"On status page you can see what files are modified, and you can commit the " -"changes to git." -msgstr "" - -#: ../inc/class-gitium-help.php:69 ../inc/class-gitium-submenu-commits.php:29 -#: ../inc/class-gitium-submenu-commits.php:41 -msgid "Commits" -msgstr "" - -#: ../inc/class-gitium-help.php:74 -msgid "" -"You may be wondering what is the difference between author and committer." -msgstr "" - -#: ../inc/class-gitium-help.php:75 -msgid "" -"The author is the person who originally wrote the patch, " -"whereas the committer is the person who last applied the patch." -msgstr "" - -#: ../inc/class-gitium-help.php:76 -msgid "" -"So, if you send in a patch to a project and one of the core members applies " -"the patch, both of you get credit — you as the author and the core member as " -"the committer." -msgstr "" - -#: ../inc/class-gitium-help.php:86 -msgid "Each line from the gitignore file specifies a pattern." -msgstr "" - -#: ../inc/class-gitium-help.php:87 -msgid "" -"When deciding whether to ignore a path, Git normally checks gitignore " -"patterns from multiple sources, with the following order of precedence, from " -"highest to lowest (within one level of precedence, the last matching pattern " -"decides the outcome)" -msgstr "" - -#: ../inc/class-gitium-help.php:88 -#, php-format -msgid "Read more on %s" -msgstr "" - -#: ../inc/class-gitium-submenu-commits.php:28 -msgid "Git Commits" -msgstr "" - -#: ../inc/class-gitium-submenu-commits.php:61 -#, php-format -msgid "Last %s commits" -msgstr "" - -#: ../inc/class-gitium-submenu-commits.php:70 -#, php-format -msgid "committed %s ago" -msgstr "" - -#: ../inc/class-gitium-submenu-commits.php:82 -#, php-format -msgid "authored %s ago" -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/gitium/readme.txt b/wp-content/upgrade-temp-backup/plugins/gitium/readme.txt deleted file mode 100644 index 27fa5c00..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gitium/readme.txt +++ /dev/null @@ -1,310 +0,0 @@ -=== Gitium === - -Contributors: PressLabs -Donate link: https://www.presslabs.com/gitium/ -Tags: git, version control, revision, gitium, presslabs -Requires at least: 4.7 -Tested up to: 6.8 -Requires PHP: 7.4 -License: GPLv3 -Stable tag: 1.2.1 -License URI: https://www.gnu.org/licenses/gpl-3.0.en.html - -Automatic git version control and deployment for your plugins and themes integrated into wp-admin. - -== About the makers == -This plugin was developed by the crafty people at Presslabs—the Smart Managed WordPress Hosting Platform. Here we bring high-performance hosting and business intelligence for WordPress sites. In our spare time, we contribute to the global open-source community with our code. - -We’ve built Gitium back in 2013 to provide our clients a more simple and error-free method to integrate a new git version control into their code management flow. - -== What is Gitium? == - -This plugin enables continuous deployment for WordPress, integrating with tools such as Github, Bitbucket or Travis-CI. Theme or plugin updates, installs and removals are all automatically versioned. Ninja code edits from the WordPress editor are also tracked by the version control system. - -== Why is Gitium? == - -Gitium is designed with responsible development environments in mind, allowing staging and production to follow different branches of the same repository. You can also deploy code by simply using git push. - -Gitium requires git command line tool with a minimum version of 1.7 installed on the server and the proc_open PHP function enabled. - -== Gitium features: == --preserves the WordPress behavior --accountability for code changes --safe code storage—gets all code edits in Git - -== Development == -For more details about Gitium, head here: http://docs.presslabs.com/gitium/usage/ - -== Receiving is nicer when giving == -We’ve built this to make our lives easier and we’re happy to do that for other developers, too. We’d really appreciate it if you could contribute with code, tests, documentation or just share your experience with Gitium. - -Development of Gitium happens at http://github.com/PressLabs/gitium -Issues are tracked at http://github.com/PressLabs/gitium/issues -This WordPress plugin can be found at https://wordpress.org/plugins/gitium/ - -== Screenshots == - -1. Setup step 1: Get SSH Key -2. Setup step 2: Set SSH Key (Github) -3. Setup step 3: Add remote repository -4. Setup step 4: Choose following branch -5. Commit local changes - - -== Installation == - -= Manual Installation = - -1. Go to your WordPress admin dashboard. -2. Navigate to 'Plugins' → 'Add New'. -3. Search for "Gitium". -4. Install and activate the Gitium plugin. - -= Usage = - -- Connect Your Repository -After activation, go to the Gitium settings in your WordPress admin area. -Copy the Public Key that Gitium has generated for you from the Key Pair field. -In your repository manager of choice (GitHub, GitLab, or Bitbucket), go to the settings page and find the “Deploy keys” (or similar) section. There you will need to add the Public Key you’ve copied from Gitium. This will grant Gitium access to your repository. Make sure to allow write access as well. Also make sure that you copy the entire key from gitium. -Now go back to your main repository page and copy the SSH URL to your repo. Paste this URL in Gitium and press the “Fetch” button. -A “Repository initialized successfully” message will show up. This means that your repository has been populated with the current code of your website and it is ready to start working with Gitium. - -- Initial Commit -Once connected, Gitium will automatically commit your existing WordPress theme and plugins to the connected repository. -This initial commit serves as the baseline for your site’s code. - -- Making Changes -Make changes to your WordPress site’s code (themes, plugins) as needed. -Gitium will automatically commit these changes to your Git repository. -Using the webhook provided by Gitium, it will also automatically deploy the changes from the repository to your WordPress site. - -- Webook Configuration -Gitium uses the webhook to automatically deploy remote changes to your server. To configure it follow these steps: - 1. Go to your WordPress website and go to your Gitium Settings page; - 2. Copy the full Webhook URL that Gitium provides; - 3. In your Git Manager settings, go to Webhook section, add a new webhook and paste the webhook URL you have copied from Gitium. - 4. Press Add, no settings changes needed. The webook simply needs a ping, nothing more. The security key is already embedded in the final URL Gitium has generated for you. - -Now when you push to your repo, this webhook will automatically pull the changes to your remote server and deploy them. - -You can see more details about the plugin also in our documentation here: https://www.presslabs.com/docs/code/gitium/install-gitium/ - -== Frequently Asked Questions == - -= Could not connect to remote repository? = - -If you encounter this kind of error you can try to fix it by setting the proper username of the .git directory. - -Example: chown -R www-data:www-data .git - -= Is this plugin considered stable? = - -Yes, we consider the plugin stable after extensive usage in production environments at Presslabs, with hundreds of users and powering sites with hundreds of millions of pageviews per month. - -= What will happen in case of conflicts? = - -The behavior in case of conflicts is to overwrite the changes on the `origin` repository with the local changes (ie. local modifications take precedence over remote ones). - -= How to deploy automatically after a push? = - -You can ping the webhook url after a push to automatically deploy the new code. The webhook url can be found under `Gitium` menu, `Settings` section. This url also plays well with Github or Bitbucket webhooks. - -= Does it works on multi site setups? = - -Gitium does not support multisite setups at the moment. - -= How does gitium handle submodules? = - -Submodules are currently not supported. - -= Where do I report security bugs found in this plugin? = - -Please report security bugs found in the source code of the Gitium plugin through the [Patchstack Vulnerability Disclosure Program](https://patchstack.com/database/vdp/gitium). The Patchstack team will assist you with verification, CVE assignment, and notify the developers of this plugin. - -== Upgrade Notice == -= 1.2.1 = -Tested up to WP 6.8 - -== Changelog == - -= 1.2.1 = -* Tested the compatibility of the plugin with WP 6.8 - -= 1.2.0 = -* Changed the license for all files to GPLv3 -* Fix: In some cases, the WP is configured in another folder. We've made some changes on how we check for the wp-load.php file - -= 1.1.0 = -* Fix: In some cases, the website was stuck in maintenance when it was pulling the changes from remote -* Added: A copy-to-clipboard button was introduced for copying ssh key-pair and webhook url - -= 1.0.7 = -* Fix: HOME env definition; -* Fix: deprecation warnings in PHP 8.1; -* Compat: added composer.json package; -* Compat: add the possibility to use a custom `.gitignore` by defining the `GITIGNORE` constant. - -= 1.0.6 = -* Fixed deprecation warnings for dynamic property in git-wrapper - -= 1.0.5 = -* Various bug fixes - -= 1.0.4 = -* PHP 8 compat. fixes - -= 1.0.3 = -* Fixed wrong redirection for multisite installations during initial setup - -= 1.0.2 = -* Full PHP 7+ compatibility -* Hotfix - Fixed the blank pages being displayed instead of success of failure messages; -* Hotfix - Fixed the push process when other remote branches had changes; -* Hotfix - Fixed the missing ssh / key handling with fatal errors during activation; -* Added - More success messages in certain cases. - -= 1.0.1 = -* Hotfix - Fix race condition on Code Editor Save - -= 1.0 = -* Fixed WP 4.9 Compatibility - -= 1.0-rc12 = -* Bumped plugin version - -= 1.0-rc11 = -* Hotfixed an error that prevented gitium to error_log properly. - -= 1.0-rc10 = -* Bumped wordpress tested version - -= 1.0-rc9 = -* PHP7 compat and wp-cli - -= 1.0-rc8 = -* Fix some indents -* Add some more tests -* Fix the submenu configure logic - -= 1.0-rc7 = -* Test remote url from git wrapper -* Remove the phpmd package from test environment -* Set WP_DEBUG to false on tests -* Refactoring -* Abort the cherry-pick - changes are already there -* Fix the race condition -* Add acquire and release logs for gitium lock -* Add explanations to merge with accept mine logic - -= 1.0-rc6 = -* Delete all transients and options on uninstall hook -* Add transients to is_versions and get_remote_tracking_branch functions -* Update the composer -* Check requirements before show the admin menu -* Put the logs off by default(on test env) -* Fix redirect issue and display errors -* Create wordpress docker env command -* PHP Warning: unlink #114 - -= 1.0-rc5 = -* Fix delete plugin/theme bug on 4.6 -* Update the readme file - -= 1.0-rc4 = -* Fix merge with accept mine behind commits bug - -= 1.0-rc3 = -* Add support for multisite -* Fix PHP error on merge & push - -= 1.0-rc2 = -* Change the default lockfile location -* Fix a PHP Warning - -= 1.0-rc1 = -* Update the logic of merge and push -* Add lock mechanism for fetch and merge -* Fix repo stuck on merge_local branch -* Tested up to 4.5.3 - -= 0.5.8-beta = -* Add documentation for 'Could not connect to remote repository?' -* Fix the update theme from Dashboard commit message & the install plugin commit message -* Fix install/delete plugin/theme commit message -* Add a test and rewrite the tests -* Tested up to 4.5.2 - -= 0.5.7-beta = -* Fix bug deleting plugins/themes causes wrong commit message -* Fix bug wrong commit message -* Fix bug updated function to stop maintenance mode hang -* Fix bug undefined variable 'new_versions' -* Add 'Merge changes' button for gitium webhook -* Add gitium documentation for docker -* Add more tests - -= 0.5.6-beta = -* Fix compatibility issues with wp-cli - -= 0.5.5-beta = -* Fix bug plugin deletion from plugins page did not trigger commit - -= 0.5.4-beta = -* Fix bug missing changes on similarly named plugins -* Add requirements notices -* Add requirements help section - -= 0.5.3-beta = -* Fix paths with spaces bug -* Add a Disconnect from repo button -* Fix POST var `path` conflicts -* Fix travis tests - -= 0.5.2-beta = -* Add Contextual Help to Configuration page -* Make the icon path relative -* The key file is deleted properly -* Update serbian translation -* Make the resource type more specific -* Fix Menu Bubble -* Remove useless param for get_transient -* Add Spanish Translation -* Rename `gitium_version` transient -* Fix git version notice -* Delete .vimrc -* Update .gitignore -* Fix syntax error -* Add better git version check -* Fix add_query_arg vulnerability - -= 0.5.1-beta = -* Update Serbian Translation (by [Ogi Djuraskovic](http://firstsiteguide.com/)) -* Fix Menu Bubble - -= 0.5-beta = -* Add `Last 20 Commits` menu page -* Add WordPress Contextual Help menu -* Add `Settings` menu page -* Move `Webhook URL` and `Public Key` fields to `Settings` page -* Add menu icon -* The `.gitignore` file can be edited -* Fix commit message on theme/plugin update event -* Refactoring - -= 0.4-beta = -* Add `Bitbucket` documentation link -* Add the action `gitium_before_merge_with_accept_mine` -* Moved to `travis-ci.org` -* Add new tests -* Added code climate coverage reporting -* Refactoring - -= 0.3.2-alpha = -* Fix plugin activation issues - -= 0.3.1-alpha = -* Fix issues with ssh repositories -* Fix maintemance mode when webhook fails - -= 0.3-alpha = -* First alpha release diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/css.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/css.php deleted file mode 100644 index e46eec65..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/css.php +++ /dev/null @@ -1,134 +0,0 @@ -_selector ) { - $this->add_selector_rules_to_output(); - } - - $this->_selector = $selector; - - return $this; - } - - /** - * Adds a css property with value to the css output - * - * @access public - * @since 1.0 - * - * @param string $property - the css property. - * @param string $value - the value to be placed with the property. - * @param string $url Whether we need to generate URL in the string. - * @return $this - */ - public function add_property( $property, $value, $url = '' ) { - // If we don't have a value or our value is the same as our og default, bail. - if ( empty( $value ) ) { - return false; - } - - // Set up our background image URL param if needed. - $url_start = ( '' !== $url ) ? "url('" : ""; // phpcs:ignore -- need double quotes. - $url_end = ( '' !== $url ) ? "')" : ""; // phpcs:ignore -- need double quotes. - - $this->_css .= $property . ':' . $url_start . $value . $url_end . ';'; - return $this; - } - - /** - * Adds the current selector rules to the output variable - * - * @access private - * @since 1.0 - * - * @return $this - */ - private function add_selector_rules_to_output() { - if ( ! empty( $this->_css ) ) { - $this->_selector_output = $this->_selector; - $selector_output = sprintf( '%1$s{%2$s}', $this->_selector_output, $this->_css ); - - $this->_output .= $selector_output; - - // Reset the css. - $this->_css = ''; - } - - return $this; - } - - /** - * Returns the minified css in the $_output variable - * - * @access public - * @since 1.0 - * - * @return string - */ - public function css_output() { - // Add current selector's rules to output. - $this->add_selector_rules_to_output(); - - // Output minified css. - return $this->_output; - } - - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/functions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/functions.php deleted file mode 100644 index fb21ce01..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/functions.php +++ /dev/null @@ -1,1342 +0,0 @@ - '', - 'body_repeat' => '', - 'body_size' => '', - 'body_attachment' => '', - 'body_position' => '', - 'top_bar_image' => '', - 'top_bar_repeat' => '', - 'top_bar_size' => '', - 'top_bar_attachment' => '', - 'top_bar_position' => '', - 'header_image' => '', - 'header_repeat' => '', - 'header_size' => '', - 'header_attachment' => '', - 'header_position' => '', - 'nav_image' => '', - 'nav_repeat' => '', - 'nav_item_image' => '', - 'nav_item_repeat' => '', - 'nav_item_hover_image' => '', - 'nav_item_hover_repeat' => '', - 'nav_item_current_image' => '', - 'nav_item_current_repeat' => '', - 'sub_nav_image' => '', - 'sub_nav_repeat' => '', - 'sub_nav_item_image' => '', - 'sub_nav_item_repeat' => '', - 'sub_nav_item_hover_image' => '', - 'sub_nav_item_hover_repeat' => '', - 'sub_nav_item_current_image' => '', - 'sub_nav_item_current_repeat' => '', - 'content_image' => '', - 'content_repeat' => '', - 'content_size' => '', - 'content_attachment' => '', - 'content_position' => '', - 'sidebar_widget_image' => '', - 'sidebar_widget_repeat' => '', - 'sidebar_widget_size' => '', - 'sidebar_widget_attachment' => '', - 'sidebar_widget_position' => '', - 'footer_widget_image' => '', - 'footer_widget_repeat' => '', - 'footer_widget_size' => '', - 'footer_widget_attachment' => '', - 'footer_widget_position' => '', - 'footer_image' => '', - 'footer_repeat' => '', - 'footer_size' => '', - 'footer_attachment' => '', - 'footer_position' => '', - ); - - return apply_filters( 'generate_background_option_defaults', $generate_background_defaults ); - } -} - -if ( ! function_exists( 'generate_backgrounds_customize' ) ) { - add_action( 'customize_register', 'generate_backgrounds_customize', 999 ); - /** - * Build our Customizer options - * - * @since 0.1 - * - * @param object $wp_customize The Customizer object. - */ - function generate_backgrounds_customize( $wp_customize ) { - $defaults = generate_get_background_defaults(); - - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Background_Images_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - if ( class_exists( 'WP_Customize_Panel' ) ) { - if ( ! $wp_customize->get_panel( 'generate_backgrounds_panel' ) ) { - $wp_customize->add_panel( - 'generate_backgrounds_panel', - array( - 'capability' => 'edit_theme_options', - 'theme_supports' => '', - 'title' => __( 'Background Images', 'gp-premium' ), - 'priority' => 55, - ) - ); - } - } - - $wp_customize->add_section( - 'backgrounds_section', - array( - 'title' => __( 'Background Images', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 50, - ) - ); - - $wp_customize->add_section( - 'generate_backgrounds_body', - array( - 'title' => __( 'Body', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 5, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_body_background_image_shortcuts', - array( - 'section' => 'generate_backgrounds_body', - 'element' => __( 'Body', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_container', - 'colors' => 'body_section', - 'typography' => 'font_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - /** - * Body background - */ - $wp_customize->add_setting( - 'generate_background_settings[body_image]', - array( - 'default' => $defaults['body_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_backgrounds-body-image', - array( - 'section' => 'generate_backgrounds_body', - 'settings' => 'generate_background_settings[body_image]', - 'label' => __( 'Body', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[body_repeat]', - array( - 'default' => $defaults['body_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[body_size]', - array( - 'default' => $defaults['body_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[body_attachment]', - array( - 'default' => $defaults['body_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[body_position]', - array( - 'default' => $defaults['body_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'body_backgrounds_control', - array( - 'section' => 'generate_backgrounds_body', - 'settings' => array( - 'repeat' => 'generate_background_settings[body_repeat]', - 'size' => 'generate_background_settings[body_size]', - 'attachment' => 'generate_background_settings[body_attachment]', - 'position' => 'generate_background_settings[body_position]', - ), - ) - ) - ); - - /** - * Top bar background - */ - $wp_customize->add_section( - 'generate_backgrounds_top_bar', - array( - 'title' => __( 'Top Bar', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 5, - 'panel' => 'generate_backgrounds_panel', - 'active_callback' => 'generate_premium_is_top_bar_active', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[top_bar_image]', - array( - 'default' => $defaults['top_bar_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[top_bar_image]', - array( - 'section' => 'generate_backgrounds_top_bar', - 'settings' => 'generate_background_settings[top_bar_image]', - 'label' => __( 'Top Bar', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[top_bar_repeat]', - array( - 'default' => $defaults['top_bar_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[top_bar_size]', - array( - 'default' => $defaults['top_bar_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[top_bar_attachment]', - array( - 'default' => $defaults['top_bar_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[top_bar_position]', - array( - 'default' => $defaults['top_bar_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'top_bar_backgrounds_control', - array( - 'section' => 'generate_backgrounds_top_bar', - 'settings' => array( - 'repeat' => 'generate_background_settings[top_bar_repeat]', - 'size' => 'generate_background_settings[top_bar_size]', - 'attachment' => 'generate_background_settings[top_bar_attachment]', - 'position' => 'generate_background_settings[top_bar_position]', - ), - ) - ) - ); - - /** - * Header background - */ - $wp_customize->add_section( - 'generate_backgrounds_header', - array( - 'title' => __( 'Header', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 10, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_header_background_image_shortcuts', - array( - 'section' => 'generate_backgrounds_header', - 'element' => __( 'Header', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_header', - 'colors' => 'header_color_section', - 'typography' => 'font_header_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[header_image]', - array( - 'default' => $defaults['header_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_backgrounds-header-image', - array( - 'section' => 'generate_backgrounds_header', - 'settings' => 'generate_background_settings[header_image]', - 'label' => __( 'Header', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[header_repeat]', - array( - 'default' => $defaults['header_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[header_size]', - array( - 'default' => $defaults['header_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[header_attachment]', - array( - 'default' => $defaults['header_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[header_position]', - array( - 'default' => $defaults['header_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'header_backgrounds_control', - array( - 'section' => 'generate_backgrounds_header', - 'settings' => array( - 'repeat' => 'generate_background_settings[header_repeat]', - 'size' => 'generate_background_settings[header_size]', - 'attachment' => 'generate_background_settings[header_attachment]', - 'position' => 'generate_background_settings[header_position]', - ), - ) - ) - ); - - $wp_customize->add_section( - 'generate_backgrounds_navigation', - array( - 'title' => __( 'Primary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 15, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_primary_navigation_background_image_shortcuts', - array( - 'section' => 'generate_backgrounds_navigation', - 'element' => __( 'Primary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_navigation', - 'colors' => 'navigation_color_section', - 'typography' => 'font_navigation_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - /** - * Navigation background - */ - $wp_customize->add_setting( - 'generate_background_settings[nav_image]', - array( - 'default' => $defaults['nav_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[nav_image]', - array( - 'section' => 'generate_backgrounds_navigation', - 'settings' => 'generate_background_settings[nav_image]', - 'priority' => 750, - 'label' => __( 'Navigation', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[nav_repeat]', - array( - 'default' => $defaults['nav_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[nav_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_navigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[nav_repeat]', - 'priority' => 800, - ) - ); - - /** - * Navigation item background - */ - $wp_customize->add_setting( - 'generate_background_settings[nav_item_image]', - array( - 'default' => $defaults['nav_item_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_backgrounds-nav-item-image', - array( - 'section' => 'generate_backgrounds_navigation', - 'settings' => 'generate_background_settings[nav_item_image]', - 'priority' => 950, - 'label' => __( 'Navigation Item', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[nav_item_repeat]', - array( - 'default' => $defaults['nav_item_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[nav_item_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_navigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[nav_item_repeat]', - 'priority' => 1000, - ) - ); - - /** - * Navigation item hover background - */ - $wp_customize->add_setting( - 'generate_background_settings[nav_item_hover_image]', - array( - 'default' => $defaults['nav_item_hover_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_backgrounds-nav-item-hover-image', - array( - 'section' => 'generate_backgrounds_navigation', - 'settings' => 'generate_background_settings[nav_item_hover_image]', - 'priority' => 1150, - 'label' => __( 'Navigation Item Hover', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[nav_item_hover_repeat]', - array( - 'default' => $defaults['nav_item_hover_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[nav_item_hover_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_navigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[nav_item_hover_repeat]', - 'priority' => 1200, - ) - ); - - /** - * Navigation item current background - */ - $wp_customize->add_setting( - 'generate_background_settings[nav_item_current_image]', - array( - 'default' => $defaults['nav_item_current_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_backgrounds-nav-item-current-image', - array( - 'section' => 'generate_backgrounds_navigation', - 'settings' => 'generate_background_settings[nav_item_current_image]', - 'priority' => 1350, - 'label' => __( 'Navigation Item Current', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[nav_item_current_repeat]', - array( - 'default' => $defaults['nav_item_current_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[nav_item_current_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_navigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[nav_item_current_repeat]', - 'priority' => 1400, - ) - ); - - $wp_customize->add_section( - 'generate_backgrounds_subnavigation', - array( - 'title' => __( 'Primary Sub-Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 20, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - /** - * Sub-Navigation item background - */ - $wp_customize->add_setting( - 'generate_background_settings[sub_nav_item_image]', - array( - 'default' => $defaults['sub_nav_item_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[sub_nav_item_image]', - array( - 'section' => 'generate_backgrounds_subnavigation', - 'settings' => 'generate_background_settings[sub_nav_item_image]', - 'priority' => 1700, - 'label' => __( 'Sub-Navigation Item', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sub_nav_item_repeat]', - array( - 'default' => $defaults['sub_nav_item_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[sub_nav_item_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_subnavigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[sub_nav_item_repeat]', - 'priority' => 1800, - ) - ); - - /** - * Sub-Navigation item hover background - */ - $wp_customize->add_setting( - 'generate_background_settings[sub_nav_item_hover_image]', - array( - 'default' => $defaults['sub_nav_item_hover_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[sub_nav_item_hover_image]', - array( - 'section' => 'generate_backgrounds_subnavigation', - 'settings' => 'generate_background_settings[sub_nav_item_hover_image]', - 'priority' => 2000, - 'label' => __( 'Sub-Navigation Item Hover', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sub_nav_item_hover_repeat]', - array( - 'default' => $defaults['sub_nav_item_hover_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[sub_nav_item_hover_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_subnavigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[sub_nav_item_hover_repeat]', - 'priority' => 2100, - ) - ); - - /** - * Sub-Navigation item current background - */ - $wp_customize->add_setting( - 'generate_background_settings[sub_nav_item_current_image]', - array( - 'default' => $defaults['sub_nav_item_current_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[sub_nav_item_current_image]', - array( - 'section' => 'generate_backgrounds_subnavigation', - 'settings' => 'generate_background_settings[sub_nav_item_current_image]', - 'priority' => 2300, - 'label' => __( 'Sub-Navigation Item Current', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sub_nav_item_current_repeat]', - array( - 'default' => $defaults['sub_nav_item_current_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_control( - 'generate_background_settings[sub_nav_item_current_repeat]', - array( - 'type' => 'select', - 'section' => 'generate_backgrounds_subnavigation', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_background_settings[sub_nav_item_current_repeat]', - 'priority' => 2400, - ) - ); - - $wp_customize->add_section( - 'generate_backgrounds_content', - array( - 'title' => __( 'Content', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 25, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_content_background_image_shortcuts', - array( - 'section' => 'generate_backgrounds_content', - 'element' => __( 'Content', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'content_color_section', - 'typography' => 'font_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - /** - * Content background - */ - $wp_customize->add_setting( - 'generate_background_settings[content_image]', - array( - 'default' => $defaults['content_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[content_image]', - array( - 'section' => 'generate_backgrounds_content', - 'settings' => 'generate_background_settings[content_image]', - 'label' => __( 'Content', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[content_repeat]', - array( - 'default' => $defaults['content_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[content_size]', - array( - 'default' => $defaults['content_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[content_attachment]', - array( - 'default' => $defaults['content_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[content_position]', - array( - 'default' => $defaults['content_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'content_backgrounds_control', - array( - 'section' => 'generate_backgrounds_content', - 'settings' => array( - 'repeat' => 'generate_background_settings[content_repeat]', - 'size' => 'generate_background_settings[content_size]', - 'attachment' => 'generate_background_settings[content_attachment]', - 'position' => 'generate_background_settings[content_position]', - ), - ) - ) - ); - - $wp_customize->add_section( - 'generate_backgrounds_sidebars', - array( - 'title' => __( 'Sidebar', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 25, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_sidebar_background_image_shortcuts', - array( - 'section' => 'generate_backgrounds_sidebars', - 'element' => __( 'Sidebar', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_sidebars', - 'colors' => 'sidebar_widget_color_section', - 'typography' => 'font_widget_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sidebar_widget_image]', - array( - 'default' => $defaults['sidebar_widget_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[sidebar_widget_image]', - array( - 'section' => 'generate_backgrounds_sidebars', - 'settings' => 'generate_background_settings[sidebar_widget_image]', - 'label' => __( 'Sidebar Widgets', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sidebar_widget_repeat]', - array( - 'default' => $defaults['sidebar_widget_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sidebar_widget_size]', - array( - 'default' => $defaults['sidebar_widget_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sidebar_widget_attachment]', - array( - 'default' => $defaults['sidebar_widget_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[sidebar_widget_position]', - array( - 'default' => $defaults['sidebar_widget_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'sidebar_backgrounds_control', - array( - 'section' => 'generate_backgrounds_sidebars', - 'settings' => array( - 'repeat' => 'generate_background_settings[sidebar_widget_repeat]', - 'size' => 'generate_background_settings[sidebar_widget_size]', - 'attachment' => 'generate_background_settings[sidebar_widget_attachment]', - 'position' => 'generate_background_settings[sidebar_widget_position]', - ), - ) - ) - ); - - $wp_customize->add_section( - 'generate_backgrounds_footer', - array( - 'title' => __( 'Footer', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 30, - 'panel' => 'generate_backgrounds_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_footer_background_image_shortcuts', - array( - 'section' => 'generate_backgrounds_footer', - 'element' => __( 'Footer', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_footer', - 'colors' => 'footer_color_section', - 'typography' => 'font_footer_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_widget_image]', - array( - 'default' => $defaults['footer_widget_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_background_settings[footer_widget_image]', - array( - 'section' => 'generate_backgrounds_footer', - 'settings' => 'generate_background_settings[footer_widget_image]', - 'label' => __( 'Footer Widget Area', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_widget_repeat]', - array( - 'default' => $defaults['footer_widget_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_widget_size]', - array( - 'default' => $defaults['footer_widget_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_widget_attachment]', - array( - 'default' => $defaults['footer_widget_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_widget_position]', - array( - 'default' => $defaults['footer_widget_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'footer_widgets_backgrounds_control', - array( - 'section' => 'generate_backgrounds_footer', - 'settings' => array( - 'repeat' => 'generate_background_settings[footer_widget_repeat]', - 'size' => 'generate_background_settings[footer_widget_size]', - 'attachment' => 'generate_background_settings[footer_widget_attachment]', - 'position' => 'generate_background_settings[footer_widget_position]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_image]', - array( - 'default' => $defaults['footer_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_backgrounds-footer-image', - array( - 'section' => 'generate_backgrounds_footer', - 'settings' => 'generate_background_settings[footer_image]', - 'label' => __( 'Footer Area', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_repeat]', - array( - 'default' => $defaults['footer_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_size]', - array( - 'default' => $defaults['footer_size'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_attachment]', - array( - 'default' => $defaults['footer_attachment'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - ) - ); - - $wp_customize->add_setting( - 'generate_background_settings[footer_position]', - array( - 'default' => $defaults['footer_position'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_html', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Background_Images_Customize_Control( - $wp_customize, - 'footer_backgrounds_control', - array( - 'section' => 'generate_backgrounds_footer', - 'settings' => array( - 'repeat' => 'generate_background_settings[footer_repeat]', - 'size' => 'generate_background_settings[footer_size]', - 'attachment' => 'generate_background_settings[footer_attachment]', - 'position' => 'generate_background_settings[footer_position]', - ), - ) - ) - ); - } -} - -if ( ! function_exists( 'generate_backgrounds_css' ) ) { - /** - * Generate the CSS in the section using the Theme Customizer - * - * @since 0.1 - */ - function generate_backgrounds_css() { - $generate_settings = wp_parse_args( - get_option( 'generate_background_settings', array() ), - generate_get_background_defaults() - ); - - // Fix size values. - // Spaces and % are stripped by sanitize_key. - $generate_settings['body_size'] = ( '100' == $generate_settings['body_size'] ) ? '100% auto' : esc_attr( $generate_settings['body_size'] ); // phpcs:ignore -- Non-strict comparison ok. - $generate_settings['top_bar_size'] = ( '100' == $generate_settings['top_bar_size'] ) ? '100% auto' : esc_attr( $generate_settings['top_bar_size'] ); // phpcs:ignore -- Non-strict comparison ok. - $generate_settings['header_size'] = ( '100' == $generate_settings['header_size'] ) ? '100% auto' : esc_attr( $generate_settings['header_size'] ); // phpcs:ignore -- Non-strict comparison ok. - $generate_settings['content_size'] = ( '100' == $generate_settings['content_size'] ) ? '100% auto' : esc_attr( $generate_settings['content_size'] ); // phpcs:ignore -- Non-strict comparison ok. - $generate_settings['sidebar_widget_size'] = ( '100' == $generate_settings['sidebar_widget_size'] ) ? '100% auto' : esc_attr( $generate_settings['sidebar_widget_size'] ); // phpcs:ignore -- Non-strict comparison ok. - $generate_settings['footer_widget_size'] = ( '100' == $generate_settings['footer_widget_size'] ) ? '100% auto' : esc_attr( $generate_settings['footer_widget_size'] ); // phpcs:ignore -- Non-strict comparison ok. - $generate_settings['footer_size'] = ( '100' == $generate_settings['footer_size'] ) ? '100% auto' : esc_attr( $generate_settings['footer_size'] ); // phpcs:ignore -- Non-strict comparison ok. - - $css = new GeneratePress_Backgrounds_CSS(); - - $css->set_selector( 'body' ); - $css->add_property( 'background-image', esc_url( $generate_settings['body_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['body_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['body_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['body_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['body_position'] ) ); - - if ( is_active_sidebar( 'top-bar' ) ) { - $css->set_selector( '.top-bar' ); - $css->add_property( 'background-image', esc_url( $generate_settings['top_bar_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['top_bar_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['top_bar_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['top_bar_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['top_bar_position'] ) ); - } - - $css->set_selector( '.site-header' ); - $css->add_property( 'background-image', esc_url( $generate_settings['header_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['header_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['header_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['header_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['header_position'] ) ); - - $css->set_selector( '.main-navigation, .main-navigation .menu-toggle' ); - $css->add_property( 'background-image', esc_url( $generate_settings['nav_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_repeat'] ) ); - - $css->set_selector( '.main-navigation .main-nav > ul > li > a' ); - $css->add_property( 'background-image', esc_url( $generate_settings['nav_item_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_item_repeat'] ) ); - - $css->set_selector( '.main-navigation .main-nav > ul > li > a:hover,.main-navigation .main-nav > ul > li.sfHover > a' ); - $css->add_property( 'background-image', esc_url( $generate_settings['nav_item_hover_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_item_hover_repeat'] ) ); - - $css->set_selector( '.main-navigation .main-nav > ul > li[class*="current-menu-"] > a,.main-navigation .main-nav > ul > li[class*="current-menu-"] > a:hover,.main-navigation .main-nav > ul > li[class*="current-menu-"].sfHover > a' ); - $css->add_property( 'background-image', esc_url( $generate_settings['nav_item_current_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_item_current_repeat'] ) ); - - $css->set_selector( '.main-navigation ul ul li a' ); - $css->add_property( 'background-image', esc_url( $generate_settings['sub_nav_item_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sub_nav_item_repeat'] ) ); - - $css->set_selector( '.main-navigation ul ul li > a:hover,.main-navigation ul ul li.sfHover > a' ); - $css->add_property( 'background-image', esc_url( $generate_settings['sub_nav_item_hover_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sub_nav_item_hover_repeat'] ) ); - - $css->set_selector( '.main-navigation ul ul li[class*="current-menu-"] > a,.main-navigation ul ul li[class*="current-menu-"] > a:hover,.main-navigation ul ul li[class*="current-menu-"].sfHover > a' ); - $css->add_property( 'background-image', esc_url( $generate_settings['sub_nav_item_current_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sub_nav_item_current_repeat'] ) ); - - $css->set_selector( '.separate-containers .inside-article,.separate-containers .comments-area,.separate-containers .page-header,.one-container .container,.separate-containers .paging-navigation,.separate-containers .inside-page-header' ); - $css->add_property( 'background-image', esc_url( $generate_settings['content_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['content_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['content_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['content_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['content_position'] ) ); - - $css->set_selector( '.sidebar .widget' ); - $css->add_property( 'background-image', esc_url( $generate_settings['sidebar_widget_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sidebar_widget_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['sidebar_widget_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['sidebar_widget_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['sidebar_widget_position'] ) ); - - $css->set_selector( '.footer-widgets' ); - $css->add_property( 'background-image', esc_url( $generate_settings['footer_widget_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['footer_widget_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['footer_widget_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['footer_widget_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['footer_widget_position'] ) ); - - $css->set_selector( '.site-info' ); - $css->add_property( 'background-image', esc_url( $generate_settings['footer_image'] ), 'url' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['footer_repeat'] ) ); - $css->add_property( 'background-size', esc_attr( $generate_settings['footer_size'] ) ); - $css->add_property( 'background-attachment', esc_attr( $generate_settings['footer_attachment'] ) ); - $css->add_property( 'background-position', esc_attr( $generate_settings['footer_position'] ) ); - - return apply_filters( 'generate_backgrounds_css_output', $css->css_output() ); - } -} - -if ( ! function_exists( 'generate_background_scripts' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_background_scripts', 70 ); - /** - * Enqueue scripts and styles. - * - * @since 0.1 - */ - function generate_background_scripts() { - if ( 'inline' === generate_get_css_print_method() ) { - wp_add_inline_style( 'generate-style', generate_backgrounds_css() ); - } - } -} - -add_filter( 'generate_external_dynamic_css_output', 'generate_backgrounds_add_external_css' ); -/** - * Add to external stylesheet. - * - * @since 1.11.0 - * - * @param string $css Existing CSS. - */ -function generate_backgrounds_add_external_css( $css ) { - if ( 'inline' === generate_get_css_print_method() ) { - return $css; - } - - $css .= generate_backgrounds_css(); - - return $css; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/secondary-nav-backgrounds.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/secondary-nav-backgrounds.php deleted file mode 100644 index fdc17f1d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/functions/secondary-nav-backgrounds.php +++ /dev/null @@ -1,420 +0,0 @@ -get_section( 'secondary_nav_section' ) ) { - return; - } - - $defaults = generate_secondary_nav_get_defaults(); - - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - $wp_customize->add_section( - 'secondary_bg_images_section', - array( - 'title' => __( 'Secondary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'panel' => 'generate_backgrounds_panel', - 'priority' => 21, - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_secondary_navigation_background_image_shortcuts', - array( - 'section' => 'secondary_bg_images_section', - 'element' => __( 'Secondary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'secondary_nav_section', - 'colors' => 'secondary_navigation_color_section', - 'typography' => 'secondary_font_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_image]', - array( - 'default' => $defaults['nav_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-nav-image', - array( - 'section' => 'secondary_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[nav_image]', - 'priority' => 750, - 'label' => __( 'Navigation', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_repeat]', - array( - 'default' => $defaults['nav_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[nav_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[nav_repeat]', - 'priority' => 800, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_item_image]', - array( - 'default' => $defaults['nav_item_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-nav-item-image', - array( - 'section' => 'secondary_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[nav_item_image]', - 'priority' => 950, - 'label' => __( 'Navigation Item', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_item_repeat]', - array( - 'default' => $defaults['nav_item_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[nav_item_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[nav_item_repeat]', - 'priority' => 1000, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_item_hover_image]', - array( - 'default' => $defaults['nav_item_hover_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-nav-item-hover-image', - array( - 'section' => 'secondary_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[nav_item_hover_image]', - 'priority' => 1150, - 'label' => __( 'Navigation Item Hover', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_item_hover_repeat]', - array( - 'default' => $defaults['nav_item_hover_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[nav_item_hover_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[nav_item_hover_repeat]', - 'priority' => 1200, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_item_current_image]', - array( - 'default' => $defaults['nav_item_current_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-nav-item-current-image', - array( - 'section' => 'secondary_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[nav_item_current_image]', - 'priority' => 1350, - 'label' => __( 'Navigation Item Current', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[nav_item_current_repeat]', - array( - 'default' => $defaults['nav_item_current_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[nav_item_current_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[nav_item_current_repeat]', - 'priority' => 1400, - ) - ); - - $wp_customize->add_section( - 'secondary_subnav_bg_images_section', - array( - 'title' => __( 'Secondary Sub-Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'panel' => 'generate_backgrounds_panel', - 'priority' => 22, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[sub_nav_item_image]', - array( - 'default' => $defaults['sub_nav_item_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-sub-nav-item-image', - array( - 'section' => 'secondary_subnav_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[sub_nav_item_image]', - 'priority' => 1700, - 'label' => __( 'Sub-Navigation Item', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[sub_nav_item_repeat]', - array( - 'default' => $defaults['sub_nav_item_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[sub_nav_item_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_subnav_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[sub_nav_item_repeat]', - 'priority' => 1800, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[sub_nav_item_hover_image]', - array( - 'default' => $defaults['sub_nav_item_hover_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-sub-nav-item-hover-image', - array( - 'section' => 'secondary_subnav_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[sub_nav_item_hover_image]', - 'priority' => 2000, - 'label' => __( 'Sub-Navigation Item Hover', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[sub_nav_item_hover_repeat]', - array( - 'default' => $defaults['sub_nav_item_hover_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[sub_nav_item_hover_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_subnav_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[sub_nav_item_hover_repeat]', - 'priority' => 2100, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[sub_nav_item_current_image]', - array( - 'default' => $defaults['sub_nav_item_current_image'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'esc_url_raw', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Image_Control( - $wp_customize, - 'generate_secondary_backgrounds-sub-nav-item-current-image', - array( - 'section' => 'secondary_subnav_bg_images_section', - 'settings' => 'generate_secondary_nav_settings[sub_nav_item_current_image]', - 'priority' => 2300, - 'label' => __( 'Sub-Navigation Item Current', 'gp-premium' ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[sub_nav_item_current_repeat]', - array( - 'default' => $defaults['sub_nav_item_current_repeat'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[sub_nav_item_current_repeat]', - array( - 'type' => 'select', - 'section' => 'secondary_subnav_bg_images_section', - 'choices' => array( - '' => __( 'Repeat', 'gp-premium' ), - 'repeat-x' => __( 'Repeat x', 'gp-premium' ), - 'repeat-y' => __( 'Repeat y', 'gp-premium' ), - 'no-repeat' => __( 'No Repeat', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[sub_nav_item_current_repeat]', - 'priority' => 2400, - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/generate-backgrounds.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/generate-backgrounds.php deleted file mode 100644 index d9cd1055..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/backgrounds/generate-backgrounds.php +++ /dev/null @@ -1,19 +0,0 @@ -post_count ) { - $columns = false; - } - } - - // Return the result. - return apply_filters( 'generate_blog_columns', $columns ); - } -} - -if ( ! function_exists( 'generate_blog_get_masonry' ) ) { - /** - * Check if masonry is enabled. - * This function is a mess with strings as bools etc.. Will re-write in a big upate to get lots of testing. - */ - function generate_blog_get_masonry() { - $generate_blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - // If masonry is enabled via option or filter, enable it. - // phpcs:ignore -- non-strict comparison allowed. - if ( $generate_blog_settings['masonry'] || 'true' == apply_filters( 'generate_blog_masonry', 'false' ) ) { - $masonry = 'true'; - } else { - $masonry = 'false'; - } - - // Allow masonry to be turned off using a boolean. - if ( false === apply_filters( 'generate_blog_masonry', 'false' ) ) { - $masonry = 'false'; - } - - return $masonry; - } -} - -if ( ! function_exists( 'generate_blog_add_columns_container' ) ) { - add_action( 'generate_before_main_content', 'generate_blog_add_columns_container' ); - /** - * Add columns container - * - * @since 1.0 - */ - function generate_blog_add_columns_container() { - if ( ! generate_blog_get_columns() ) { - return; - } - - $columns = generate_blog_get_column_count(); - - printf( - '
    %2$s', - 'false' !== generate_blog_get_masonry() ? 'masonry-container are-images-unloaded' : '', - 'false' !== generate_blog_get_masonry() ? '
    ' : '' // phpcs:ignore -- no escaping needed. - ); - } -} - -if ( ! function_exists( 'generate_blog_add_ending_columns_container' ) ) { - add_action( 'generate_after_main_content', 'generate_blog_add_ending_columns_container' ); - /** - * Add closing columns container - * - * @since 1.0 - */ - function generate_blog_add_ending_columns_container() { - if ( ! generate_blog_get_columns() ) { - return; - } - - echo '
    '; - } -} - -if ( ! function_exists( 'generate_blog_columns_css' ) ) { - /** - * Add inline CSS - */ - function generate_blog_columns_css() { - $generate_blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( function_exists( 'generate_spacing_get_defaults' ) ) { - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - } - - $separator = ( function_exists( 'generate_spacing_get_defaults' ) ) ? absint( $spacing_settings['separator'] ) : 20; - - $return = ''; - if ( generate_blog_get_columns() ) { - $return .= '.generate-columns {margin-bottom: ' . $separator . 'px;padding-left: ' . $separator . 'px;}'; - $return .= '.generate-columns-container {margin-left: -' . $separator . 'px;}'; - $return .= '.page-header {margin-bottom: ' . $separator . 'px;margin-left: ' . $separator . 'px}'; - $return .= '.generate-columns-container > .paging-navigation {margin-left: ' . $separator . 'px;}'; - } - - return $return; - } -} - -if ( ! function_exists( 'generate_blog_get_column_count' ) ) { - /** - * Get our column grid class - */ - function generate_blog_get_column_count() { - $generate_blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - $count = $generate_blog_settings['columns']; - - return apply_filters( 'generate_blog_get_column_count', $count ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/columns.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/columns.css deleted file mode 100644 index 1066ab1f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/columns.css +++ /dev/null @@ -1,149 +0,0 @@ -.masonry-enabled .page-header { - position: relative !important; -} - -.separate-containers .site-main > .generate-columns-container { - margin-bottom: 0; -} - -.masonry-container.are-images-unloaded, -.load-more.are-images-unloaded, -.masonry-enabled #nav-below { - opacity: 0; -} - -/* columns */ -.generate-columns-container:not(.masonry-container) { - display: flex; - flex-wrap: wrap; - align-items: stretch; -} - -.generate-columns .inside-article { - height: 100%; - box-sizing: border-box; -} - -.generate-columns-activated.post-image-aligned-left .generate-columns-container article:not(.featured-column) .post-image, -.generate-columns-activated.post-image-aligned-right .generate-columns-container article:not(.featured-column) .post-image { - float: none; - text-align: center; - margin-left: 0; - margin-right: 0; -} - -.generate-columns-container .paging-navigation, -.generate-columns-container .page-header { - flex: 1 1 100%; - clear: both; -} - -.generate-columns-container .paging-navigation { - margin-bottom: 0; -} - -.load-more:not(.has-svg-icon) .button.loading:before { - content: "\e900"; - display: inline-block; - font-family: "GP Premium"; - font-style: normal; - font-weight: normal; - font-variant: normal; - text-transform: none; - line-height: 1; - animation: spin 2s infinite linear; - margin-right: 7px; -} - -.load-more .button:not(.loading) .gp-icon { - display: none; -} - -.load-more .gp-icon svg { - animation: spin 2s infinite linear; - margin-right: 7px; -} - -@keyframes spin { - 0% { - transform: rotate(0deg); - } - 100% { - transform: rotate(360deg); - } -} - -.generate-columns { - box-sizing: border-box; -} - -.generate-columns.grid-20, -.grid-sizer.grid-20 { - width: 20%; -} - -.generate-columns.grid-25, -.grid-sizer.grid-25 { - width: 25%; -} - -.generate-columns.grid-33, -.grid-sizer.grid-33 { - width: 33.3333%; -} - -.generate-columns.grid-50, -.grid-sizer.grid-50 { - width: 50%; -} - -.generate-columns.grid-60, -.grid-sizer.grid-60 { - width: 60%; -} - -.generate-columns.grid-66, -.grid-sizer.grid-66 { - width: 66.66667%; -} - -.generate-columns.grid-100, -.grid-sizer.grid-100 { - width: 100%; -} - -@media (min-width: 768px) and (max-width: 1024px) { - .generate-columns.tablet-grid-50, - .grid-sizer.tablet-grid-50 { - width: 50%; - } -} - -@media (max-width: 767px) { - .generate-columns-activated .generate-columns-container { - margin-left: 0; - margin-right: 0; - } - .generate-columns-container > *, - .generate-columns-container .generate-columns { - padding-left: 0; - } - .generate-columns-container .page-header { - margin-left: 0; - } - .generate-columns.mobile-grid-100, - .grid-sizer.mobile-grid-100 { - width: 100%; - } - .generate-columns-container > .paging-navigation { - margin-left: 0; - } -} - -@media (max-width: 768px) { - .load-more { - display: block; - text-align: center; - margin-bottom: 0; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/columns.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/columns.min.css deleted file mode 100644 index 3814f76b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/columns.min.css +++ /dev/null @@ -1 +0,0 @@ -.masonry-enabled .page-header{position:relative!important}.separate-containers .site-main>.generate-columns-container{margin-bottom:0}.load-more.are-images-unloaded,.masonry-container.are-images-unloaded,.masonry-enabled #nav-below{opacity:0}.generate-columns-container:not(.masonry-container){display:flex;flex-wrap:wrap;align-items:stretch}.generate-columns .inside-article{height:100%;box-sizing:border-box}.generate-columns-activated.post-image-aligned-left .generate-columns-container article:not(.featured-column) .post-image,.generate-columns-activated.post-image-aligned-right .generate-columns-container article:not(.featured-column) .post-image{float:none;text-align:center;margin-left:0;margin-right:0}.generate-columns-container .page-header,.generate-columns-container .paging-navigation{flex:1 1 100%;clear:both}.generate-columns-container .paging-navigation{margin-bottom:0}.load-more:not(.has-svg-icon) .button.loading:before{content:"\e900";display:inline-block;font-family:"GP Premium";font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;animation:spin 2s infinite linear;margin-right:7px}.load-more .button:not(.loading) .gp-icon{display:none}.load-more .gp-icon svg{animation:spin 2s infinite linear;margin-right:7px}@keyframes spin{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}.generate-columns{box-sizing:border-box}.generate-columns.grid-20,.grid-sizer.grid-20{width:20%}.generate-columns.grid-25,.grid-sizer.grid-25{width:25%}.generate-columns.grid-33,.grid-sizer.grid-33{width:33.3333%}.generate-columns.grid-50,.grid-sizer.grid-50{width:50%}.generate-columns.grid-60,.grid-sizer.grid-60{width:60%}.generate-columns.grid-66,.grid-sizer.grid-66{width:66.66667%}.generate-columns.grid-100,.grid-sizer.grid-100{width:100%}@media (min-width:768px) and (max-width:1024px){.generate-columns.tablet-grid-50,.grid-sizer.tablet-grid-50{width:50%}}@media (max-width:767px){.generate-columns-activated .generate-columns-container{margin-left:0;margin-right:0}.generate-columns-container .generate-columns,.generate-columns-container>*{padding-left:0}.generate-columns-container .page-header{margin-left:0}.generate-columns.mobile-grid-100,.grid-sizer.mobile-grid-100{width:100%}.generate-columns-container>.paging-navigation{margin-left:0}}@media (max-width:768px){.load-more{display:block;text-align:center;margin-bottom:0}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/featured-images.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/featured-images.css deleted file mode 100644 index c3efa57f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/featured-images.css +++ /dev/null @@ -1,104 +0,0 @@ -.post-image-above-header .inside-article .post-image, -.post-image-above-header .inside-article .featured-image { - margin-top: 0; - margin-bottom: 2em; -} - -.post-image-aligned-left .inside-article .post-image, -.post-image-aligned-left .inside-article .featured-image { - margin-top: 0; - margin-right: 2em; - float: left; - text-align: left; -} - -.post-image-aligned-center .post-image, -.post-image-aligned-center .featured-image { - text-align: center; -} - -.post-image-aligned-right .inside-article .post-image, -.post-image-aligned-right .inside-article .featured-image { - margin-top: 0; - margin-left: 2em; - float: right; - text-align: right; -} - -.post-image-below-header.post-image-aligned-right .inside-article .post-image, -.post-image-below-header.post-image-aligned-right .inside-article .featured-image, -.post-image-below-header.post-image-aligned-center .inside-article .featured-image, -.post-image-below-header.post-image-aligned-left .inside-article .post-image, -.post-image-below-header.post-image-aligned-left .inside-article .featured-image { - margin-top: 2em; -} - -.post-image-aligned-left > .featured-image, -.post-image-aligned-right > .featured-image { - float: none; - margin-left: auto; - margin-right: auto; -} - -.post-image-aligned-left .featured-image { - text-align: left; -} - -.post-image-aligned-right .featured-image { - text-align: right; -} - -.post-image-aligned-left .inside-article:before, -.post-image-aligned-left .inside-article:after, -.post-image-aligned-right .inside-article:before, -.post-image-aligned-right .inside-article:after { - content: ""; - display: table; -} - -.post-image-aligned-left .inside-article:after, -.post-image-aligned-right .inside-article:after { - clear: both; -} - -.one-container.post-image-above-header .page-header + .no-featured-image-padding .inside-article .post-image, -.one-container.post-image-above-header .no-featured-image-padding.generate-columns .inside-article .post-image { - margin-top: 0; -} - -.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image, -.one-container.both-right.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.both-right.post-image-aligned-center .no-featured-image-padding .featured-image { - margin-right: 0; -} - -.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image, -.one-container.both-left.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.both-left.post-image-aligned-center .no-featured-image-padding .featured-image { - margin-left: 0; -} - -.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .featured-image { - margin-left: 0; - margin-right: 0; -} - -.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .post-image, -.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .featured-image { - margin-left: 0; - margin-right: 0; -} - -@media (max-width: 768px) { - body:not(.post-image-aligned-center) .inside-article .post-image, - body:not(.post-image-aligned-center) .featured-image, - body:not(.post-image-aligned-center) .inside-article .featured-image { - margin-right: 0; - margin-left: 0; - float: none; - text-align: center; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/featured-images.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/featured-images.min.css deleted file mode 100644 index ba2493d8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/featured-images.min.css +++ /dev/null @@ -1 +0,0 @@ -.post-image-above-header .inside-article .featured-image,.post-image-above-header .inside-article .post-image{margin-top:0;margin-bottom:2em}.post-image-aligned-left .inside-article .featured-image,.post-image-aligned-left .inside-article .post-image{margin-top:0;margin-right:2em;float:left;text-align:left}.post-image-aligned-center .featured-image,.post-image-aligned-center .post-image{text-align:center}.post-image-aligned-right .inside-article .featured-image,.post-image-aligned-right .inside-article .post-image{margin-top:0;margin-left:2em;float:right;text-align:right}.post-image-below-header.post-image-aligned-center .inside-article .featured-image,.post-image-below-header.post-image-aligned-left .inside-article .featured-image,.post-image-below-header.post-image-aligned-left .inside-article .post-image,.post-image-below-header.post-image-aligned-right .inside-article .featured-image,.post-image-below-header.post-image-aligned-right .inside-article .post-image{margin-top:2em}.post-image-aligned-left>.featured-image,.post-image-aligned-right>.featured-image{float:none;margin-left:auto;margin-right:auto}.post-image-aligned-left .featured-image{text-align:left}.post-image-aligned-right .featured-image{text-align:right}.post-image-aligned-left .inside-article:after,.post-image-aligned-left .inside-article:before,.post-image-aligned-right .inside-article:after,.post-image-aligned-right .inside-article:before{content:"";display:table}.post-image-aligned-left .inside-article:after,.post-image-aligned-right .inside-article:after{clear:both}.one-container.post-image-above-header .no-featured-image-padding.generate-columns .inside-article .post-image,.one-container.post-image-above-header .page-header+.no-featured-image-padding .inside-article .post-image{margin-top:0}.one-container.both-right.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.both-right.post-image-aligned-center .no-featured-image-padding .post-image,.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .post-image{margin-right:0}.one-container.both-left.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.both-left.post-image-aligned-center .no-featured-image-padding .post-image,.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .post-image{margin-left:0}.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .post-image{margin-left:0;margin-right:0}.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .featured-image,.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .post-image{margin-left:0;margin-right:0}@media (max-width:768px){body:not(.post-image-aligned-center) .featured-image,body:not(.post-image-aligned-center) .inside-article .featured-image,body:not(.post-image-aligned-center) .inside-article .post-image{margin-right:0;margin-left:0;float:none;text-align:center}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/style.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/style.css deleted file mode 100644 index e79ddd50..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/style.css +++ /dev/null @@ -1,254 +0,0 @@ -.post-image-above-header .inside-article .post-image, -.post-image-above-header .inside-article .featured-image { - margin-top: 0; - margin-bottom: 2em; -} - -.post-image-aligned-left .inside-article .post-image, -.post-image-aligned-left .inside-article .featured-image { - margin-top: 0; - margin-right: 2em; - float: left; - text-align: left; -} - -.post-image-aligned-center .post-image, -.post-image-aligned-center .featured-image { - text-align: center; -} - -.post-image-aligned-right .inside-article .post-image, -.post-image-aligned-right .inside-article .featured-image { - margin-top: 0; - margin-left: 2em; - float: right; - text-align: right; -} - -.post-image-below-header.post-image-aligned-right .inside-article .post-image, -.post-image-below-header.post-image-aligned-right .inside-article .featured-image, -.post-image-below-header.post-image-aligned-center .inside-article .featured-image, -.post-image-below-header.post-image-aligned-left .inside-article .post-image, -.post-image-below-header.post-image-aligned-left .inside-article .featured-image { - margin-top: 2em; -} - -.post-image-aligned-left > .featured-image, -.post-image-aligned-right > .featured-image { - float: none; - margin-left: auto; - margin-right: auto; -} - -.post-image-aligned-left .featured-image { - text-align: left; -} - -.post-image-aligned-right .featured-image { - text-align: right; -} - -.post-image-aligned-left .inside-article:before, -.post-image-aligned-left .inside-article:after, -.post-image-aligned-right .inside-article:before, -.post-image-aligned-right .inside-article:after { - content: ""; - display: table; -} - -.post-image-aligned-left .inside-article:after, -.post-image-aligned-right .inside-article:after { - clear: both; -} - -.one-container.post-image-above-header .page-header + .no-featured-image-padding .inside-article .post-image, -.one-container.post-image-above-header .no-featured-image-padding.generate-columns .inside-article .post-image { - margin-top: 0; -} - -.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image, -.one-container.both-right.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.both-right.post-image-aligned-center .no-featured-image-padding .featured-image { - margin-right: 0; -} - -.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image, -.one-container.both-left.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.both-left.post-image-aligned-center .no-featured-image-padding .featured-image { - margin-left: 0; -} - -.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .post-image, -.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .featured-image { - margin-left: 0; - margin-right: 0; -} - -.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .post-image, -.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .featured-image { - margin-left: 0; - margin-right: 0; -} - -@media (max-width: 768px) { - body:not(.post-image-aligned-center) .inside-article .post-image, - body:not(.post-image-aligned-center) .featured-image, - body:not(.post-image-aligned-center) .inside-article .featured-image { - margin-right: 0; - margin-left: 0; - float: none; - text-align: center; - } -} - -.masonry-enabled .page-header { - position: relative !important; -} - -.separate-containers .site-main > .generate-columns-container { - margin-bottom: 0; -} - -.masonry-container.are-images-unloaded, -.load-more.are-images-unloaded, -.masonry-enabled #nav-below { - opacity: 0; -} - -/* columns */ -.generate-columns-container:not(.masonry-container) { - display: flex; - flex-wrap: wrap; - align-items: stretch; -} - -.generate-columns .inside-article { - height: 100%; - box-sizing: border-box; -} - -.generate-columns-activated.post-image-aligned-left .generate-columns-container article:not(.featured-column) .post-image, -.generate-columns-activated.post-image-aligned-right .generate-columns-container article:not(.featured-column) .post-image { - float: none; - text-align: center; - margin-left: 0; - margin-right: 0; -} - -.generate-columns-container .paging-navigation, -.generate-columns-container .page-header { - flex: 1 1 100%; - clear: both; -} - -.generate-columns-container .paging-navigation { - margin-bottom: 0; -} - -.load-more:not(.has-svg-icon) .button.loading:before { - content: "\e900"; - display: inline-block; - font-family: "GP Premium"; - font-style: normal; - font-weight: normal; - font-variant: normal; - text-transform: none; - line-height: 1; - animation: spin 2s infinite linear; - margin-right: 7px; -} - -.load-more .button:not(.loading) .gp-icon { - display: none; -} - -.load-more .gp-icon svg { - animation: spin 2s infinite linear; - margin-right: 7px; -} - -@keyframes spin { - 0% { - transform: rotate(0deg); - } - 100% { - transform: rotate(360deg); - } -} - -.generate-columns { - box-sizing: border-box; -} - -.generate-columns.grid-20, -.grid-sizer.grid-20 { - width: 20%; -} - -.generate-columns.grid-25, -.grid-sizer.grid-25 { - width: 25%; -} - -.generate-columns.grid-33, -.grid-sizer.grid-33 { - width: 33.3333%; -} - -.generate-columns.grid-50, -.grid-sizer.grid-50 { - width: 50%; -} - -.generate-columns.grid-60, -.grid-sizer.grid-60 { - width: 60%; -} - -.generate-columns.grid-66, -.grid-sizer.grid-66 { - width: 66.66667%; -} - -.generate-columns.grid-100, -.grid-sizer.grid-100 { - width: 100%; -} - -@media (min-width: 768px) and (max-width: 1024px) { - .generate-columns.tablet-grid-50, - .grid-sizer.tablet-grid-50 { - width: 50%; - } -} - -@media (max-width: 767px) { - .generate-columns-activated .generate-columns-container { - margin-left: 0; - margin-right: 0; - } - .generate-columns-container > *, - .generate-columns-container .generate-columns { - padding-left: 0; - } - .generate-columns-container .page-header { - margin-left: 0; - } - .generate-columns.mobile-grid-100, - .grid-sizer.mobile-grid-100 { - width: 100%; - } - .generate-columns-container > .paging-navigation { - margin-left: 0; - } -} - -@media (max-width: 768px) { - .load-more { - display: block; - text-align: center; - margin-bottom: 0; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/style.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/style.min.css deleted file mode 100644 index 6f877184..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/css/style.min.css +++ /dev/null @@ -1 +0,0 @@ -.post-image-above-header .inside-article .featured-image,.post-image-above-header .inside-article .post-image{margin-top:0;margin-bottom:2em}.post-image-aligned-left .inside-article .featured-image,.post-image-aligned-left .inside-article .post-image{margin-top:0;margin-right:2em;float:left;text-align:left}.post-image-aligned-center .featured-image,.post-image-aligned-center .post-image{text-align:center}.post-image-aligned-right .inside-article .featured-image,.post-image-aligned-right .inside-article .post-image{margin-top:0;margin-left:2em;float:right;text-align:right}.post-image-below-header.post-image-aligned-center .inside-article .featured-image,.post-image-below-header.post-image-aligned-left .inside-article .featured-image,.post-image-below-header.post-image-aligned-left .inside-article .post-image,.post-image-below-header.post-image-aligned-right .inside-article .featured-image,.post-image-below-header.post-image-aligned-right .inside-article .post-image{margin-top:2em}.post-image-aligned-left>.featured-image,.post-image-aligned-right>.featured-image{float:none;margin-left:auto;margin-right:auto}.post-image-aligned-left .featured-image{text-align:left}.post-image-aligned-right .featured-image{text-align:right}.post-image-aligned-left .inside-article:after,.post-image-aligned-left .inside-article:before,.post-image-aligned-right .inside-article:after,.post-image-aligned-right .inside-article:before{content:"";display:table}.post-image-aligned-left .inside-article:after,.post-image-aligned-right .inside-article:after{clear:both}.one-container.post-image-above-header .no-featured-image-padding.generate-columns .inside-article .post-image,.one-container.post-image-above-header .page-header+.no-featured-image-padding .inside-article .post-image{margin-top:0}.one-container.both-right.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.both-right.post-image-aligned-center .no-featured-image-padding .post-image,.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.right-sidebar.post-image-aligned-center .no-featured-image-padding .post-image{margin-right:0}.one-container.both-left.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.both-left.post-image-aligned-center .no-featured-image-padding .post-image,.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.left-sidebar.post-image-aligned-center .no-featured-image-padding .post-image{margin-left:0}.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .featured-image,.one-container.both-sidebars.post-image-aligned-center .no-featured-image-padding .post-image{margin-left:0;margin-right:0}.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .featured-image,.one-container.post-image-aligned-center .no-featured-image-padding.generate-columns .post-image{margin-left:0;margin-right:0}@media (max-width:768px){body:not(.post-image-aligned-center) .featured-image,body:not(.post-image-aligned-center) .inside-article .featured-image,body:not(.post-image-aligned-center) .inside-article .post-image{margin-right:0;margin-left:0;float:none;text-align:center}}.masonry-enabled .page-header{position:relative!important}.separate-containers .site-main>.generate-columns-container{margin-bottom:0}.load-more.are-images-unloaded,.masonry-container.are-images-unloaded,.masonry-enabled #nav-below{opacity:0}.generate-columns-container:not(.masonry-container){display:flex;flex-wrap:wrap;align-items:stretch}.generate-columns .inside-article{height:100%;box-sizing:border-box}.generate-columns-activated.post-image-aligned-left .generate-columns-container article:not(.featured-column) .post-image,.generate-columns-activated.post-image-aligned-right .generate-columns-container article:not(.featured-column) .post-image{float:none;text-align:center;margin-left:0;margin-right:0}.generate-columns-container .page-header,.generate-columns-container .paging-navigation{flex:1 1 100%;clear:both}.generate-columns-container .paging-navigation{margin-bottom:0}.load-more:not(.has-svg-icon) .button.loading:before{content:"\e900";display:inline-block;font-family:"GP Premium";font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;animation:spin 2s infinite linear;margin-right:7px}.load-more .button:not(.loading) .gp-icon{display:none}.load-more .gp-icon svg{animation:spin 2s infinite linear;margin-right:7px}@keyframes spin{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}.generate-columns{box-sizing:border-box}.generate-columns.grid-20,.grid-sizer.grid-20{width:20%}.generate-columns.grid-25,.grid-sizer.grid-25{width:25%}.generate-columns.grid-33,.grid-sizer.grid-33{width:33.3333%}.generate-columns.grid-50,.grid-sizer.grid-50{width:50%}.generate-columns.grid-60,.grid-sizer.grid-60{width:60%}.generate-columns.grid-66,.grid-sizer.grid-66{width:66.66667%}.generate-columns.grid-100,.grid-sizer.grid-100{width:100%}@media (min-width:768px) and (max-width:1024px){.generate-columns.tablet-grid-50,.grid-sizer.tablet-grid-50{width:50%}}@media (max-width:767px){.generate-columns-activated .generate-columns-container{margin-left:0;margin-right:0}.generate-columns-container .generate-columns,.generate-columns-container>*{padding-left:0}.generate-columns-container .page-header{margin-left:0}.generate-columns.mobile-grid-100,.grid-sizer.mobile-grid-100{width:100%}.generate-columns-container>.paging-navigation{margin-left:0}}@media (max-width:768px){.load-more{display:block;text-align:center;margin-bottom:0}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/customizer.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/customizer.php deleted file mode 100644 index 2c018ea8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/customizer.php +++ /dev/null @@ -1,1181 +0,0 @@ -register_control_type( 'GeneratePress_Title_Customize_Control' ); - } - - // Remove our blog control from the free theme. - if ( $wp_customize->get_control( 'blog_content_control' ) ) { - $wp_customize->remove_control( 'blog_content_control' ); - } - - // Register our custom controls. - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Refresh_Button_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Information_Customize_Control' ); - $wp_customize->register_control_type( 'Generate_Control_Toggle_Customize_Control' ); - } - - $wp_customize->add_section( - 'generate_blog_loop_template_section', - array( - 'title' => __( 'Blog', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'panel' => 'generate_layout_panel', - 'priority' => 40, - 'active_callback' => function() { - return generate_has_active_element( 'loop-template', true ); - }, - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_loop_template', - array( - 'section' => 'generate_blog_loop_template_section', - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Loop Template Element. Other options can be found within that Element.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - return generate_has_active_element( 'loop-template', true ); - }, - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[excerpt_length]', array( - 'default' => $defaults['excerpt_length'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'absint', - ) - ); - - $wp_customize->add_control( - 'generate_loop_template_excerpt_length', - array( - 'type' => 'number', - 'label' => __( 'Excerpt word count', 'gp-premium' ), - 'section' => 'generate_blog_loop_template_section', - 'settings' => 'generate_blog_settings[excerpt_length]', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[read_more]', - array( - 'default' => $defaults['read_more'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'wp_kses_post', - ) - ); - - $wp_customize->add_control( - 'generate_loop_template_read_more', - array( - 'type' => 'text', - 'label' => __( 'Read more label', 'gp-premium' ), - 'section' => 'generate_blog_loop_template_section', - 'settings' => 'generate_blog_settings[read_more]', - ) - ); - - // Blog content section. - $wp_customize->add_section( - 'generate_blog_section', - array( - 'title' => __( 'Blog', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'panel' => 'generate_layout_panel', - 'priority' => 40, - 'active_callback' => function() { - return ! generate_has_active_element( 'loop-template', true ); - }, - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_blog_archives_title', - array( - 'section' => 'generate_blog_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Content', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new Generate_Control_Toggle_Customize_Control( - $wp_customize, - 'generate_post_meta_toggle', - array( - 'section' => 'generate_blog_section', - 'targets' => array( - 'post-meta-archives' => __( 'Archives', 'gp-premium' ), - 'post-meta-single' => __( 'Single', 'gp-premium' ), - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - 'generate_settings[post_content]', - array( - 'type' => 'select', - 'label' => __( 'Content type', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - 'full' => __( 'Full Content', 'gp-premium' ), - 'excerpt' => __( 'Excerpt', 'gp-premium' ), - ), - 'settings' => 'generate_settings[post_content]', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[excerpt_length]', array( - 'type' => 'number', - 'label' => __( 'Excerpt word count', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[excerpt_length]', - 'active_callback' => 'generate_premium_is_excerpt', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[read_more]', array( - 'type' => 'text', - 'label' => __( 'Read more label', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[read_more]', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[read_more_button]', - array( - 'default' => $defaults['read_more_button'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[read_more_button]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display read more as button', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[read_more_button]', - ) - ); - - // Post date - $wp_customize->add_setting( - 'generate_blog_settings[date]', - array( - 'default' => $defaults['date'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[date]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post date', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[date]', - ) - ); - - // Post author - $wp_customize->add_setting( - 'generate_blog_settings[author]', - array( - 'default' => $defaults['author'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[author]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post author', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[author]', - ) - ); - - // Category links - $wp_customize->add_setting( - 'generate_blog_settings[categories]', - array( - 'default' => $defaults['categories'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[categories]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post categories', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[categories]', - ) - ); - - // Tag links - $wp_customize->add_setting( - 'generate_blog_settings[tags]', - array( - 'default' => $defaults['tags'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[tags]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post tags', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[tags]', - ) - ); - - // Comment link - $wp_customize->add_setting( - 'generate_blog_settings[comments]', - array( - 'default' => $defaults['comments'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[comments]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display comment count', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[comments]', - ) - ); - - // Infinite scroll - $wp_customize->add_setting( - 'generate_blog_settings[infinite_scroll]', - array( - 'default' => $defaults['infinite_scroll'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[infinite_scroll]', - array( - 'type' => 'checkbox', - 'label' => __( 'Use infinite scroll', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[infinite_scroll]', - ) - ); - - // Infinite scroll - $wp_customize->add_setting( - 'generate_blog_settings[infinite_scroll_button]', - array( - 'default' => $defaults['infinite_scroll_button'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[infinite_scroll_button]', - array( - 'type' => 'checkbox', - 'label' => __( 'Use button to load more posts', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[infinite_scroll_button]', - 'active_callback' => 'generate_premium_infinite_scroll_active', - ) - ); - - // Load more text - $wp_customize->add_setting( - 'generate_blog_settings[masonry_load_more]', array( - 'default' => $defaults['masonry_load_more'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'wp_kses_post', - ) - ); - - $wp_customize->add_control( - 'blog_masonry_load_more_control', array( - 'label' => __( 'Load more label', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[masonry_load_more]', - 'active_callback' => 'generate_premium_infinite_scroll_button_active', - ) - ); - - // Loading text - $wp_customize->add_setting( - 'generate_blog_settings[masonry_loading]', array( - 'default' => $defaults['masonry_loading'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'wp_kses_post', - ) - ); - - $wp_customize->add_control( - 'blog_masonry_loading_control', array( - 'label' => __( 'Loading label', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[masonry_loading]', - 'active_callback' => 'generate_premium_infinite_scroll_button_active', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[single_date]', - array( - 'default' => $defaults['single_date'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_date]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post date', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_date]', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[single_author]', - array( - 'default' => $defaults['single_author'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_author]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post author', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_author]', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[single_categories]', - array( - 'default' => $defaults['single_categories'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_categories]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post categories', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_categories]', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[single_tags]', - array( - 'default' => $defaults['single_tags'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_tags]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post tags', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_tags]', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[single_post_navigation]', - array( - 'default' => $defaults['single_post_navigation'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_navigation]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display post navigation', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_post_navigation]', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_blog_featured_images_title', - array( - 'section' => 'generate_blog_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Featured Images', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_control( - new Generate_Control_Toggle_Customize_Control( - $wp_customize, - 'generate_featured_image_toggle', - array( - 'section' => 'generate_blog_section', - 'targets' => array( - 'featured-image-archives' => __( 'Archives', 'gp-premium' ), - 'featured-image-single' => __( 'Posts', 'gp-premium' ), - 'featured-image-page' => __( 'Pages', 'gp-premium' ), - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Show featured images - $wp_customize->add_setting( - 'generate_blog_settings[post_image]', - array( - 'default' => $defaults['post_image'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display featured images', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[post_image]', - ) - ); - - // Padding - $wp_customize->add_setting( - 'generate_blog_settings[post_image_padding]', - array( - 'default' => $defaults['post_image_padding'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image_padding]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display padding around images', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[post_image_padding]', - 'active_callback' => 'generate_premium_display_image_padding', - ) - ); - - // Location - $wp_customize->add_setting( - 'generate_blog_settings[post_image_position]', - array( - 'default' => $defaults['post_image_position'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image_position]', - array( - 'type' => 'select', - 'label' => __( 'Location', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - '' => __( 'Below Title', 'gp-premium' ), - 'post-image-above-header' => __( 'Above Title', 'gp-premium' ), - ), - 'settings' => 'generate_blog_settings[post_image_position]', - 'active_callback' => 'generate_premium_featured_image_active', - ) - ); - - // Alignment - $wp_customize->add_setting( - 'generate_blog_settings[post_image_alignment]', - array( - 'default' => $defaults['post_image_alignment'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image_alignment]', - array( - 'type' => 'select', - 'label' => __( 'Alignment', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - 'post-image-aligned-center' => __( 'Center', 'gp-premium' ), - 'post-image-aligned-left' => __( 'Left', 'gp-premium' ), - 'post-image-aligned-right' => __( 'Right', 'gp-premium' ), - ), - 'settings' => 'generate_blog_settings[post_image_alignment]', - 'active_callback' => 'generate_premium_featured_image_active', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[post_image_size]', - array( - 'default' => $defaults['post_image_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image_size]', - array( - 'type' => 'select', - 'label' => __( 'Media Attachment Size', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => generate_blog_get_image_sizes(), - 'settings' => 'generate_blog_settings[post_image_size]', - 'active_callback' => 'generate_premium_featured_image_active', - ) - ); - - // Width - $wp_customize->add_setting( - 'generate_blog_settings[post_image_width]', array( - 'default' => $defaults['post_image_width'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image_width]', - array( - 'type' => 'number', - 'label' => __( 'Width', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[post_image_width]', - 'active_callback' => 'generate_premium_featured_image_active', - ) - ); - - // Height - $wp_customize->add_setting( - 'generate_blog_settings[post_image_height]', array( - 'default' => $defaults['post_image_height'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[post_image_height]', - array( - 'type' => 'number', - 'label' => __( 'Height', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[post_image_height]', - 'active_callback' => 'generate_premium_featured_image_active', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_regenerate_images_notice', - array( - 'section' => 'generate_blog_section', - 'description' => sprintf( - __( 'We will attempt to serve exact image sizes based on your width/height settings. If that is not possible, we will resize your images using CSS. Learn more about featured image sizing %s.', 'gp-premium' ), - '' . __( 'here', 'gp-premium' ) . '' - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => 'generate_premium_featured_image_active', - ) - ) - ); - - /* - * Single featured images - */ - - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image]', - array( - 'default' => $defaults['single_post_image'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display featured images', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_post_image]', - ) - ); - - // Padding - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image_padding]', - array( - 'default' => $defaults['single_post_image_padding'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image_padding]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display padding around images', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_post_image_padding]', - 'active_callback' => 'generate_premium_display_image_padding_single', - ) - ); - - // Location - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image_position]', - array( - 'default' => $defaults['single_post_image_position'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image_position]', - array( - 'type' => 'select', - 'label' => __( 'Location', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - 'below-title' => __( 'Below Title', 'gp-premium' ), - 'inside-content' => __( 'Above Title', 'gp-premium' ), - 'above-content' => __( 'Above Content Area', 'gp-premium' ), - ), - 'settings' => 'generate_blog_settings[single_post_image_position]', - 'active_callback' => 'generate_premium_single_featured_image_active', - ) - ); - - // Alignment - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image_alignment]', - array( - 'default' => $defaults['single_post_image_alignment'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image_alignment]', - array( - 'type' => 'select', - 'label' => __( 'Alignment', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - 'center' => __( 'Center', 'gp-premium' ), - 'left' => __( 'Left', 'gp-premium' ), - 'right' => __( 'Right', 'gp-premium' ), - ), - 'settings' => 'generate_blog_settings[single_post_image_alignment]', - 'active_callback' => 'generate_premium_single_featured_image_active', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image_size]', - array( - 'default' => $defaults['single_post_image_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image_size]', - array( - 'type' => 'select', - 'label' => __( 'Media Attachment Size', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => generate_blog_get_image_sizes(), - 'settings' => 'generate_blog_settings[single_post_image_size]', - 'active_callback' => 'generate_premium_single_featured_image_active', - ) - ); - - // Width - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image_width]', array( - 'default' => $defaults['single_post_image_width'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image_width]', - array( - 'type' => 'number', - 'label' => __( 'Width', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_post_image_width]', - 'active_callback' => 'generate_premium_single_featured_image_active', - ) - ); - - // Height - $wp_customize->add_setting( - 'generate_blog_settings[single_post_image_height]', array( - 'default' => $defaults['single_post_image_height'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[single_post_image_height]', - array( - 'type' => 'number', - 'label' => __( 'Height', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[single_post_image_height]', - 'active_callback' => 'generate_premium_single_featured_image_active', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_regenerate_single_post_images_notice', - array( - 'section' => 'generate_blog_section', - 'description' => sprintf( - __( 'We will attempt to serve exact image sizes based on your width/height settings. If that is not possible, we will resize your images using CSS. Learn more about featured image sizing %s.', 'gp-premium' ), - '' . __( 'here', 'gp-premium' ) . '' - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => 'generate_premium_single_featured_image_active', - ) - ) - ); - - /* - * Page featured images - */ - - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image]', - array( - 'default' => $defaults['page_post_image'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display featured images', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[page_post_image]', - ) - ); - - // Padding - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image_padding]', - array( - 'default' => $defaults['page_post_image_padding'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image_padding]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display padding around images', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[page_post_image_padding]', - 'active_callback' => 'generate_premium_display_image_padding_single_page', - ) - ); - - // Location - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image_position]', - array( - 'default' => $defaults['page_post_image_position'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image_position]', - array( - 'type' => 'select', - 'label' => __( 'Location', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - 'below-title' => __( 'Below Title', 'gp-premium' ), - 'inside-content' => __( 'Above Title', 'gp-premium' ), - 'above-content' => __( 'Above Content Area', 'gp-premium' ), - ), - 'settings' => 'generate_blog_settings[page_post_image_position]', - 'active_callback' => 'generate_premium_single_page_featured_image_active', - ) - ); - - // Alignment - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image_alignment]', - array( - 'default' => $defaults['page_post_image_alignment'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image_alignment]', - array( - 'type' => 'select', - 'label' => __( 'Alignment', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - 'center' => __( 'Center', 'gp-premium' ), - 'left' => __( 'Left', 'gp-premium' ), - 'right' => __( 'Right', 'gp-premium' ), - ), - 'settings' => 'generate_blog_settings[page_post_image_alignment]', - 'active_callback' => 'generate_premium_single_page_featured_image_active', - ) - ); - - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image_size]', - array( - 'default' => $defaults['page_post_image_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image_size]', - array( - 'type' => 'select', - 'label' => __( 'Media Attachment Size', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => generate_blog_get_image_sizes(), - 'settings' => 'generate_blog_settings[page_post_image_size]', - 'active_callback' => 'generate_premium_single_page_featured_image_active', - ) - ); - - // Width - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image_width]', array( - 'default' => $defaults['page_post_image_width'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image_width]', - array( - 'type' => 'number', - 'label' => __( 'Width', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[page_post_image_width]', - 'active_callback' => 'generate_premium_single_page_featured_image_active', - ) - ); - - // Height - $wp_customize->add_setting( - 'generate_blog_settings[page_post_image_height]', array( - 'default' => $defaults['page_post_image_height'], - 'capability' => 'edit_theme_options', - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[page_post_image_height]', - array( - 'type' => 'number', - 'label' => __( 'Height', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[page_post_image_height]', - 'active_callback' => 'generate_premium_single_page_featured_image_active', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_regenerate_page_images_notice', - array( - 'section' => 'generate_blog_section', - 'description' => sprintf( - __( 'We will attempt to serve exact image sizes based on your width/height settings. If that is not possible, we will resize your images using CSS. Learn more about featured image sizing %s.', 'gp-premium' ), - '' . __( 'here', 'gp-premium' ) . '' - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => 'generate_premium_single_page_featured_image_active', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_blog_columns_title', - array( - 'section' => 'generate_blog_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Columns', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Enable columns - $wp_customize->add_setting( - 'generate_blog_settings[column_layout]', - array( - 'default' => $defaults['column_layout'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[column_layout]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display posts in columns', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[column_layout]', - ) - ); - - // Column count class - $wp_customize->add_setting( - 'generate_blog_settings[columns]', - array( - 'default' => $defaults['columns'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[columns]', - array( - 'type' => 'select', - 'label' => __( 'Columns', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'choices' => array( - '50' => '2', - '33' => '3', - '25' => '4', - '20' => '5' - ), - 'settings' => 'generate_blog_settings[columns]', - 'active_callback' => 'generate_premium_blog_columns_active', - ) - ); - - // Featured column - $wp_customize->add_setting( - 'generate_blog_settings[featured_column]', - array( - 'default' => $defaults['featured_column'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[featured_column]', - array( - 'type' => 'checkbox', - 'label' => __( 'Make first post featured', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[featured_column]', - 'active_callback' => 'generate_premium_blog_columns_active', - ) - ); - - // Masonry - $wp_customize->add_setting( - 'generate_blog_settings[masonry]', - array( - 'default' => $defaults['masonry'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_blog_settings[masonry]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display posts in masonry grid', 'gp-premium' ), - 'section' => 'generate_blog_section', - 'settings' => 'generate_blog_settings[masonry]', - 'active_callback' => 'generate_premium_blog_columns_active', - ) - ); - } -} - -add_action( 'customize_controls_print_styles', 'generate_blog_customizer_controls_css' ); - -function generate_blog_customizer_controls_css() { - ?> - - '55', - 'read_more' => __( 'Read more', 'gp-premium' ), - 'read_more_button' => false, - 'masonry' => false, - 'masonry_load_more' => __( '+ More', 'gp-premium' ), - 'masonry_loading' => __( 'Loading...', 'gp-premium' ), - 'infinite_scroll' => false, - 'infinite_scroll_button' => false, - 'post_image' => true, - 'post_image_position' => '', - 'post_image_alignment' => 'post-image-aligned-center', - 'post_image_size' => 'full', - 'post_image_width' => '', - 'post_image_height' => '', - 'post_image_padding' => true, - 'single_post_image' => true, - 'single_post_image_position' => 'inside-content', - 'single_post_image_alignment' => 'center', - 'single_post_image_size' => 'full', - 'single_post_image_width' => '', - 'single_post_image_height' => '', - 'single_post_image_padding' => true, - 'page_post_image' => true, - 'page_post_image_position' => 'above-content', - 'page_post_image_alignment' => 'center', - 'page_post_image_size' => 'full', - 'page_post_image_width' => '', - 'page_post_image_height' => '', - 'page_post_image_padding' => true, - 'date' => true, - 'author' => true, - 'categories' => true, - 'tags' => true, - 'comments' => true, - 'single_date' => true, - 'single_author' => true, - 'single_categories' => true, - 'single_tags' => true, - 'single_post_navigation' => true, - 'column_layout' => false, - 'columns' => '50', - 'featured_column' => false, - ); - - return apply_filters( 'generate_blog_option_defaults', $generate_blog_defaults ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/generate-blog.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/generate-blog.php deleted file mode 100644 index 9b52b1ea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/generate-blog.php +++ /dev/null @@ -1,754 +0,0 @@ - $settings['masonry_load_more'], - 'loading' => $settings['masonry_loading'], - 'icon' => function_exists( 'generate_get_svg_icon' ) ? generate_get_svg_icon( 'spinner' ) : '', - 'masonryInit' => apply_filters( - 'generate_blog_masonry_init', - array( - 'columnWidth' => '.grid-sizer', - 'itemSelector' => '.masonry-post', - 'stamp' => '.page-header', - 'percentPosition' => true, - 'stagger' => 30, - 'visibleStyle' => array( - 'transform' => 'translateY(0)', - 'opacity' => 1, - ), - 'hiddenStyle' => array( - 'transform' => 'translateY(5px)', - 'opacity' => 0, - ), - ) - ), - 'infiniteScrollInit' => apply_filters( - 'generate_blog_infinite_scroll_init', - array( - 'path' => '.infinite-scroll-path a', - 'append' => '#main .infinite-scroll-item', - 'history' => false, - 'loadOnScroll' => $settings['infinite_scroll_button'] ? false : true, - 'button' => $settings['infinite_scroll_button'] ? '.load-more a' : null, - 'scrollThreshold' => $settings['infinite_scroll_button'] ? false : 600, - ) - ), - ) - ); - } - - $needs_columns_css = false; - $needs_featured_image_css = false; - - if ( generate_blog_get_columns() || $settings['infinite_scroll'] ) { - $needs_columns_css = true; - } - - if ( ! is_singular() ) { - if ( $settings['post_image'] ) { - $needs_featured_image_css = true; - } - } - - if ( is_page() && has_post_thumbnail() ) { - if ( $settings['page_post_image'] ) { - $needs_featured_image_css = true; - } - } - - if ( is_single() && has_post_thumbnail() ) { - if ( $settings['single_post_image'] ) { - $needs_featured_image_css = true; - } - } - - if ( $needs_columns_css && $needs_featured_image_css ) { - wp_enqueue_style( 'generate-blog', plugin_dir_url( __FILE__ ) . "css/style{$suffix}.css", array(), GENERATE_BLOG_VERSION ); - } elseif ( $needs_columns_css ) { - wp_enqueue_style( 'generate-blog-columns', plugin_dir_url( __FILE__ ) . "css/columns{$suffix}.css", array(), GENERATE_BLOG_VERSION ); - } elseif ( $needs_featured_image_css ) { - wp_enqueue_style( 'generate-blog-images', plugin_dir_url( __FILE__ ) . "css/featured-images{$suffix}.css", array(), GENERATE_BLOG_VERSION ); - } - } -} - -if ( ! function_exists( 'generate_blog_post_classes' ) ) { - add_filter( 'post_class', 'generate_blog_post_classes' ); - /** - * Adds custom classes to the content container - * - * @since 0.1 - */ - function generate_blog_post_classes( $classes ) { - // Don't add these classes to the GB Query Loop block items. - if ( in_array( 'gb-query-loop-item', $classes ) ) { - return $classes; - } - - global $wp_query; - $paged = get_query_var( 'paged' ); - $paged = $paged ? $paged : 1; - - // Get our options - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( $settings['infinite_scroll'] ) { - $classes[] = 'infinite-scroll-item'; - } - - // Set our masonry class - if ( 'true' == generate_blog_get_masonry() && generate_blog_get_columns() ) { - $classes[] = 'masonry-post'; - } - - // Set our column classes - if ( generate_blog_get_columns() && ! is_singular() ) { - $classes[] = 'generate-columns'; - $classes[] = 'tablet-grid-50'; - $classes[] = 'mobile-grid-100'; - $classes[] = 'grid-parent'; - - // Set our featured column class - if ( $wp_query->current_post == 0 && $paged == 1 && $settings['featured_column'] ) { - if ( 50 == generate_blog_get_column_count() ) { - $classes[] = 'grid-100'; - } - - if ( 33 == generate_blog_get_column_count() ) { - $classes[] = 'grid-66'; - } - - if ( 25 == generate_blog_get_column_count() ) { - $classes[] = 'grid-50'; - } - - if ( 20 == generate_blog_get_column_count() ) { - $classes[] = 'grid-60'; - } - $classes[] = 'featured-column'; - } else { - $classes[] = 'grid-' . generate_blog_get_column_count(); - } - } - - if ( ! $settings['post_image_padding'] && ! is_singular() ) { - $classes[] = 'no-featured-image-padding'; - } - - $location = generate_blog_get_singular_template(); - - if ( ! $settings[$location . '_post_image_padding'] && is_singular() ) { - $classes[] = 'no-featured-image-padding'; - } - - $atts = generate_get_blog_image_attributes(); - - if ( ! is_singular() && has_post_thumbnail() && ! empty( $atts ) ) { - $values = array( - $atts['width'], - $atts['height'], - $atts['crop'], - ); - - $image_src = wp_get_attachment_image_src( get_post_thumbnail_id( get_the_ID(), 'full' ), $values ); - - if ( $image_src && ( ! $image_src[3] || ! apply_filters( 'generate_use_featured_image_size_match', true ) ) ) { - $classes[] = 'resize-featured-image'; - } - } - - return $classes; - } -} - -if ( ! function_exists( 'generate_blog_body_classes' ) ) { - add_filter( 'body_class', 'generate_blog_body_classes' ); - /** - * Adds custom classes to the body - * - * @since 0.1 - */ - function generate_blog_body_classes( $classes ) { - // Get theme options - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( is_singular() ) { - $location = generate_blog_get_singular_template(); - - if ( 'below-title' == $settings[$location . '_post_image_position'] ) { - $classes[] = 'post-image-below-header'; - } - - if ( 'inside-content' == $settings[$location . '_post_image_position'] ) { - $classes[] = 'post-image-above-header'; - } - - $classes[] = ( ! empty( $settings[$location . '_post_image_alignment'] ) ) ? 'post-image-aligned-' . $settings[$location . '_post_image_alignment'] : 'post-image-aligned-center'; - } else { - $classes[] = ( '' == $settings['post_image_position'] ) ? 'post-image-below-header' : 'post-image-above-header'; - $classes[] = ( ! empty( $settings['post_image_alignment'] ) ) ? $settings['post_image_alignment'] : 'post-image-aligned-center'; - } - - if ( 'true' == generate_blog_get_masonry() && generate_blog_get_columns() ) { - $classes[] = 'masonry-enabled'; - } - - if ( generate_blog_get_columns() && ! is_singular() ) { - $classes[] = 'generate-columns-activated'; - } - - if ( $settings[ 'infinite_scroll' ] && ! is_singular() ) { - $classes[] = 'infinite-scroll'; - } - - return $classes; - } -} - -if ( ! function_exists( 'generate_excerpt_length' ) ) { - add_filter( 'excerpt_length', 'generate_excerpt_length', 15 ); - /** - * Set our excerpt length - * - * @since 0.1 - */ - function generate_excerpt_length( $length ) { - $generate_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - return absint( apply_filters( 'generate_excerpt_length', $generate_settings['excerpt_length'] ) ); - } -} - -if ( ! function_exists( 'generate_blog_css' ) ) { - /** - * Build our inline CSS - * - * @since 0.1 - */ - function generate_blog_css() { - global $post; - $return = ''; - - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ! defined( 'GENERATE_VERSION' ) ) { - return; - } - - if ( version_compare( GENERATE_VERSION, '3.0.0-alpha.1', '<' ) ) { - // Get disable headline meta. - $disable_headline = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate-disable-headline', true ) : ''; - - if ( ! $settings['categories'] && ! $settings['comments'] && ! $settings['tags'] && ! is_singular() ) { - $return .= '.blog footer.entry-meta, .archive footer.entry-meta {display:none;}'; - } - - if ( ! $settings['single_date'] && ! $settings['single_author'] && $disable_headline && is_singular() ) { - $return .= '.single .entry-header{display:none;}.single .entry-content {margin-top:0;}'; - } - - if ( ! $settings['date'] && ! $settings['author'] && ! is_singular() ) { - $return .= '.entry-header .entry-meta {display:none;}'; - } - - if ( ! $settings['single_date'] && ! $settings['single_author'] && is_singular() ) { - $return .= '.entry-header .entry-meta {display:none;}'; - } - - if ( ! $settings['single_post_navigation'] && is_singular() ) { - $return .= '.post-navigation {display:none;}'; - } - - if ( ! $settings['single_categories'] && ! $settings['single_post_navigation'] && ! $settings['single_tags'] && is_singular() ) { - $return .= '.single footer.entry-meta {display:none;}'; - } - } - - $separator = 20; - $content_padding_top = 40; - $content_padding_right = 40; - $content_padding_left = 40; - $mobile_content_padding_top = 30; - $mobile_content_padding_right = 30; - $mobile_content_padding_left = 30; - - if ( function_exists( 'generate_spacing_get_defaults' ) ) { - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - - $separator = absint( $spacing_settings['separator'] ); - $content_padding_top = absint( $spacing_settings['content_top'] ); - $content_padding_right = absint( $spacing_settings['content_right'] ); - $content_padding_left = absint( $spacing_settings['content_left'] ); - $mobile_content_padding_top = absint( $spacing_settings['mobile_content_top'] ); - $mobile_content_padding_right = absint( $spacing_settings['mobile_content_right'] ); - $mobile_content_padding_left = absint( $spacing_settings['mobile_content_left'] ); - } - - if ( 'true' == generate_blog_get_masonry() && generate_blog_get_columns() ) { - $return .= '.page-header {margin-bottom: ' . $separator . 'px;margin-left: ' . $separator . 'px}'; - } - - if ( $settings[ 'infinite_scroll' ] && ! is_singular() ) { - $return .= '#nav-below {display:none;}'; - } - - if ( ! $settings['post_image_padding'] && 'post-image-aligned-center' == $settings['post_image_alignment'] && ! is_singular() ) { - $return .= '.no-featured-image-padding .post-image {margin-left:-' . $content_padding_left . 'px;margin-right:-' . $content_padding_right . 'px;}'; - $return .= '.post-image-above-header .no-featured-image-padding .inside-article .post-image {margin-top:-' . $content_padding_top . 'px;}'; - } - - $location = generate_blog_get_singular_template(); - - if ( ! $settings[$location . '_post_image_padding'] && 'center' == $settings[$location . '_post_image_alignment'] && is_singular() ) { - $return .= '.no-featured-image-padding .featured-image {margin-left:-' . $content_padding_left . 'px;margin-right:-' . $content_padding_right . 'px;}'; - $return .= '.post-image-above-header .no-featured-image-padding .inside-article .featured-image {margin-top:-' . $content_padding_top . 'px;}'; - } - - if ( ! $settings['page_post_image_padding'] || ! $settings['single_post_image_padding'] || ! $settings['post_image_padding'] ) { - $return .= '@media ' . generate_premium_get_media_query( 'mobile' ) . '{'; - if ( ! $settings['post_image_padding'] && 'post-image-aligned-center' == $settings['post_image_alignment'] && ! is_singular() ) { - $return .= '.no-featured-image-padding .post-image {margin-left:-' . $mobile_content_padding_left . 'px;margin-right:-' . $mobile_content_padding_right . 'px;}'; - $return .= '.post-image-above-header .no-featured-image-padding .inside-article .post-image {margin-top:-' . $mobile_content_padding_top . 'px;}'; - } - - if ( ! $settings[$location . '_post_image_padding'] && 'center' == $settings[$location . '_post_image_alignment'] && is_singular() ) { - $return .= '.no-featured-image-padding .featured-image {margin-left:-' . $mobile_content_padding_left . 'px;margin-right:-' . $mobile_content_padding_right . 'px;}'; - $return .= '.post-image-above-header .no-featured-image-padding .inside-article .featured-image {margin-top:-' . $mobile_content_padding_top . 'px;}'; - } - $return .= '}'; - } - - $atts = generate_get_blog_image_attributes(); - - if ( ! empty( $atts ) ) { - $image_width = $atts['width'] && 9999 !== $atts['width'] ? 'width: ' . $atts['width'] . 'px;' : ''; - $image_height = $atts['height'] && 9999 !== $atts['height'] ? 'height: ' . $atts['height'] . 'px;' : ''; - $image_crop = $atts['crop'] ? '-o-object-fit: cover;object-fit: cover;' : ''; - - if ( ! $image_width && $image_height ) { - $image_crop = '-o-object-fit: cover;object-fit: cover;'; - } - - if ( ! is_singular() ) { - $return .= '.resize-featured-image .post-image img {' . $image_width . $image_height . $image_crop . '}'; - } - - if ( is_single() || is_page() ) { - $values = array( - $atts['width'], - $atts['height'], - $atts['crop'], - ); - - $image_src = wp_get_attachment_image_src( get_post_thumbnail_id( get_the_ID(), 'full' ), $values ); - - if ( $image_src && ( ! $image_src[3] || ! apply_filters( 'generate_use_featured_image_size_match', true ) ) ) { - $return .= '.featured-image img {' . $image_width . $image_height . $image_crop . '}'; - } - } - } - - return $return; - } -} - -add_filter( 'generate_excerpt_more_text', 'generate_blog_set_read_more_text' ); -/** - * Set the read more text with our Customizer setting. - * - * @param string $text The read more text. - */ -function generate_blog_set_read_more_text( $text ) { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( $settings['read_more'] ) { - return wp_kses_post( $settings['read_more'] ); - } - - return $text; -} - -if ( ! function_exists( 'generate_blog_excerpt_more' ) ) { - add_filter( 'excerpt_more', 'generate_blog_excerpt_more', 15 ); - /** - * Prints the read more HTML - */ - function generate_blog_excerpt_more( $more ) { - $generate_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( '' == $generate_settings['read_more'] ) { - return ''; - } - - // We don't need to overwrite the entire element just to change its text. - // If we can filter the text, stop here. - if ( function_exists( 'generate_get_read_more_text' ) ) { - return $more; - } - - return apply_filters( - 'generate_excerpt_more_output', - sprintf( - ' ... %3$s', - the_title_attribute( 'echo=0' ), - esc_url( get_permalink( get_the_ID() ) ), - wp_kses_post( $generate_settings['read_more'] ), - sprintf( - /* translators: Aria-label describing the read more button */ - _x( 'More on %s', 'more on post title', 'gp-premium' ), - the_title_attribute( 'echo=0' ) - ) - ) - ); - } -} - -if ( ! function_exists( 'generate_blog_content_more' ) ) { - add_filter( 'the_content_more_link', 'generate_blog_content_more', 15 ); - /** - * Prints the read more HTML - */ - function generate_blog_content_more( $more ) { - $generate_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( '' == $generate_settings['read_more'] ) { - return ''; - } - - // We don't need to overwrite the entire element just to change its text. - // If we can filter the text, stop here. - if ( function_exists( 'generate_get_read_more_text' ) ) { - return $more; - } - - return apply_filters( - 'generate_content_more_link_output', - sprintf( - '

    %3$s

    ', - the_title_attribute( 'echo=0' ), - esc_url( get_permalink( get_the_ID() ) . apply_filters( 'generate_more_jump', '#more-' . get_the_ID() ) ), - wp_kses_post( $generate_settings['read_more'] ), - sprintf( - /* translators: Aria-label describing the read more button */ - _x( 'More on %s', 'more on post title', 'gp-premium' ), - the_title_attribute( 'echo=0' ) - ) - ) - ); - } -} - -/** - * Checks the setting and returns false if $thing is disabled - * - * @since 1.4 - * - * @param String $data The original data, passed through if not disabled - * @param String $thing The name of the thing to check - * @return String|False The original data, or false (if disabled) - */ -function generate_disable_post_thing( $data, $thing ) { - $generate_blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ! $generate_blog_settings[$thing] ) { - return false; - } - - return $data; -} - -if ( ! function_exists( 'generate_disable_post_date' ) ) { - add_filter( 'generate_post_date', 'generate_disable_post_date' ); - /** - * Remove the post date if set - * - * @since 0.1 - */ - function generate_disable_post_date( $date ) { - if ( is_singular() ) { - return generate_disable_post_thing( $date, 'single_date' ); - } else { - return generate_disable_post_thing( $date, 'date' ); - } - } -} - -if ( ! function_exists( 'generate_disable_post_author' ) ) { - add_filter( 'generate_post_author', 'generate_disable_post_author' ); - /** - * Set the author if set - * - * @since 0.1 - */ - function generate_disable_post_author( $author ) { - if ( is_singular() ) { - return generate_disable_post_thing( $author, 'single_author' ); - } else { - return generate_disable_post_thing( $author, 'author' ); - } - } -} - -if ( ! function_exists( 'generate_disable_post_categories' ) ) { - add_filter( 'generate_show_categories', 'generate_disable_post_categories' ); - /** - * Remove the categories if set - * - * @since 0.1 - */ - function generate_disable_post_categories( $categories ) { - if ( is_singular() ) { - return generate_disable_post_thing( $categories, 'single_categories' ); - } else { - return generate_disable_post_thing( $categories, 'categories' ); - } - } -} - -if ( ! function_exists( 'generate_disable_post_tags' ) ) { - add_filter( 'generate_show_tags', 'generate_disable_post_tags' ); - /** - * Remove the tags if set - * - * @since 0.1 - */ - function generate_disable_post_tags( $tags ) { - if ( is_singular() ) { - return generate_disable_post_thing( $tags, 'single_tags' ); - } else { - return generate_disable_post_thing( $tags, 'tags' ); - } - } -} - -if ( ! function_exists( 'generate_disable_post_comments_link' ) ) { - add_filter( 'generate_show_comments', 'generate_disable_post_comments_link' ); - /** - * Remove the link to comments if set - * - * @since 0.1 - */ - function generate_disable_post_comments_link( $comments_link ) { - return generate_disable_post_thing( $comments_link, 'comments' ); - } -} - -add_filter( 'generate_show_post_navigation', 'generate_disable_post_navigation' ); -/** - * Remove the single post navigation - * - * @since 1.5 - */ -function generate_disable_post_navigation( $navigation ) { - if ( is_singular() ) { - return generate_disable_post_thing( $navigation, 'single_post_navigation' ); - } else { - return $navigation; - } -} - -add_filter( 'generate_excerpt_more_output', 'generate_blog_read_more_button' ); -add_filter( 'generate_content_more_link_output', 'generate_blog_read_more_button' ); -/** - * Add the button class to our read more link if set. - * - * @since 1.5 - * - * @param string $output Our existing read more link. - */ -function generate_blog_read_more_button( $output ) { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ! $settings['read_more_button'] ) { - return $output; - } - - $aria_label = function_exists( 'generate_get_read_more_aria_label' ) - ? generate_get_read_more_aria_label() - : sprintf( - /* translators: Aria-label describing the read more button */ - _x( 'More on %s', 'more on post title', 'gp-premium' ), - the_title_attribute( 'echo=0' ) - ); - - return sprintf( - '%5$s

    %3$s

    ', - the_title_attribute( 'echo=0' ), - esc_url( get_permalink( get_the_ID() ) . apply_filters( 'generate_more_jump', '#more-' . get_the_ID() ) ), - wp_kses_post( $settings['read_more'] ), - $aria_label, - 'generate_excerpt_more_output' === current_filter() ? ' ... ' : '' - ); -} - -if ( ! function_exists( 'generate_blog_load_more' ) ) { - add_action( 'generate_after_main_content', 'generate_blog_load_more', 20 ); - /** - * Build our load more button - */ - function generate_blog_load_more() { - // Get theme options - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ( ! $settings[ 'infinite_scroll_button' ] || ! $settings[ 'infinite_scroll' ] ) || is_singular() || is_404() ) { - return; - } - - global $wp_query; - - if ( $wp_query->max_num_pages < 2 ) { - return; - } - - if ( is_post_type_archive( 'product' ) ) { - return; - } - - if ( is_tax( 'product_cat' ) ) { - return; - } - - $icon = ''; - - if ( function_exists( 'generate_get_svg_icon' ) ) { - $icon = generate_get_svg_icon( 'spinner' ); - } - - printf( - '
    - %3$s%4$s -
    ', - $icon ? 'has-svg-icon' : '', - ( 'true' == generate_blog_get_masonry() && generate_blog_get_columns() ) ? 'are-images-unloaded' : '', - $icon, - wp_kses_post( $settings['masonry_load_more'] ) - ); - } -} - -/** - * Checks to see whether we're getting page or single post options. - * - * @since 1.5 - * - * @return string Name of our singular template - */ -function generate_blog_get_singular_template() { - $template = 'single'; - - if ( is_page() ) { - $template = 'page'; - } - - return $template; -} - -add_action( 'generate_after_footer', 'generate_blog_do_infinite_scroll_path', 500 ); -/** - * Add a next page of posts link for infinite scroll. - * - * @since 2.0.0 - */ -function generate_blog_do_infinite_scroll_path() { - if ( function_exists( 'is_woocommerce' ) && is_woocommerce() ) { - return; - } - - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( $settings['infinite_scroll'] && ! is_singular() && ! is_404() ) { - printf( - '', - get_next_posts_link() - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/images.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/images.php deleted file mode 100644 index 54f11c71..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/images.php +++ /dev/null @@ -1,369 +0,0 @@ - 'full', - ); - - foreach ( $sizes as $key => $name ) { - $new_sizes[ $name ] = $name; - } - - return $new_sizes; -} - -add_filter( 'generate_page_header_default_size', 'generate_blog_set_featured_image_size' ); -/** - * Set our featured image sizes. - * - * @since 1.10.0 - * - * @param string $size The existing size. - * @return string The new size. - */ -function generate_blog_set_featured_image_size( $size ) { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ! is_singular() ) { - $size = $settings['post_image_size']; - } - - if ( is_single() ) { - $size = $settings['single_post_image_size']; - } - - if ( is_page() ) { - $size = $settings['page_post_image_size']; - } - - $atts = generate_get_blog_image_attributes(); - - if ( ! empty( $atts ) ) { - $values = array( - $atts['width'], - $atts['height'], - $atts['crop'], - ); - - $image_src = wp_get_attachment_image_src( get_post_thumbnail_id( get_the_ID(), 'full' ), $values ); - - if ( $image_src && $image_src[3] && apply_filters( 'generate_use_featured_image_size_match', true ) ) { - return $values; - } else { - return $size; - } - } - - return $size; -} - -if ( ! function_exists( 'generate_get_blog_image_attributes' ) ) { - /** - * Build our image attributes - * - * @since 0.1 - */ - function generate_get_blog_image_attributes() { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( is_singular() ) { - if ( is_singular( 'page' ) ) { - $single = 'page_'; - } else { - $single = 'single_'; - } - } else { - $single = ''; - } - - $ignore_crop = array( '', '0', '9999' ); - - $atts = array( - 'width' => ( in_array( $settings[ "{$single}post_image_width" ], $ignore_crop ) ) ? 9999 : absint( $settings[ "{$single}post_image_width" ] ), - 'height' => ( in_array( $settings[ "{$single}post_image_height" ], $ignore_crop ) ) ? 9999 : absint( $settings[ "{$single}post_image_height" ] ), - 'crop' => ( in_array( $settings[ "{$single}post_image_width" ], $ignore_crop ) || in_array( $settings[ "{$single}post_image_height" ], $ignore_crop ) ) ? false : true, - ); - - // If there's no height or width, empty the array. - if ( 9999 == $atts['width'] && 9999 == $atts['height'] ) { // phpcs:ignore - $atts = array(); - } - - return apply_filters( 'generate_blog_image_attributes', $atts ); - } -} - -if ( ! function_exists( 'generate_blog_setup' ) ) { - add_action( 'wp', 'generate_blog_setup', 50 ); - /** - * Setup our blog functions and actions - * - * @since 0.1 - */ - function generate_blog_setup() { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - // Move our featured images to above the title. - if ( 'post-image-above-header' === $settings['post_image_position'] ) { - remove_action( 'generate_after_entry_header', 'generate_post_image' ); - add_action( 'generate_before_content', 'generate_post_image' ); - - // If we're using the Page Header add-on, move those as well. - if ( function_exists( 'generate_page_header_post_image' ) ) { - remove_action( 'generate_after_entry_header', 'generate_page_header_post_image' ); - add_action( 'generate_before_content', 'generate_page_header_post_image' ); - } - } - - $page_header_content = false; - if ( function_exists( 'generate_page_header_get_options' ) ) { - $options = generate_page_header_get_options(); - - if ( $options && '' !== $options['content'] ) { - $page_header_content = true; - } - - // If our Page Header has no content, remove it. - // This will allow the Blog add-on to add an image for us. - if ( ! $page_header_content && is_singular() ) { - remove_action( 'generate_before_content', 'generate_page_header' ); - remove_action( 'generate_after_entry_header', 'generate_page_header' ); - remove_action( 'generate_after_header', 'generate_page_header' ); - } - } - - // Remove the core theme featured image. - // I would like to filter instead one day. - remove_action( 'generate_after_header', 'generate_featured_page_header' ); - remove_action( 'generate_before_content', 'generate_featured_page_header_inside_single' ); - - $location = generate_blog_get_singular_template(); - - if ( $settings[ $location . '_post_image' ] && is_singular() && ! $page_header_content ) { - if ( 'below-title' === $settings[ $location . '_post_image_position' ] ) { - add_action( 'generate_after_entry_header', 'generate_blog_single_featured_image' ); - } - - if ( 'inside-content' === $settings[ $location . '_post_image_position' ] ) { - add_action( 'generate_before_content', 'generate_blog_single_featured_image' ); - } - - if ( 'above-content' === $settings[ $location . '_post_image_position' ] ) { - add_action( 'generate_after_header', 'generate_blog_single_featured_image' ); - } - } - } -} - -add_filter( 'generate_featured_image_output', 'generate_blog_featured_image' ); -/** - * Remove featured image if set or using WooCommerce. - * - * @since 1.5 - * @param string $output The existing output. - * @return string The image HTML - */ -function generate_blog_featured_image( $output ) { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ( function_exists( 'is_woocommerce' ) && is_woocommerce() ) || ! $settings['post_image'] ) { - return false; - } - - return $output; -} - -/** - * Build our featured images for single posts and pages. - * - * This function is way more complicated than it could be so it can - * ensure compatibility with the Page Header add-on. - * - * @since 1.5 - * - * @return string The image HTML - */ -function generate_blog_single_featured_image() { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - $image_id = get_post_thumbnail_id( get_the_ID(), 'full' ); - - if ( function_exists( 'generate_page_header_get_image' ) && generate_page_header_get_image( 'ID' ) ) { - if ( intval( $image_id ) !== generate_page_header_get_image( 'ID' ) ) { - $image_id = generate_page_header_get_image( 'ID' ); - } - } - - $location = generate_blog_get_singular_template(); - - if ( ( function_exists( 'is_woocommerce' ) && is_woocommerce() ) || ! $settings[ $location . '_post_image' ] || ! $image_id ) { - return false; - } - - $attrs = array( - 'itemprop' => 'image', - ); - - if ( function_exists( 'generate_get_schema_type' ) ) { - if ( 'microdata' !== generate_get_schema_type() ) { - $attrs = array(); - } - } - - $attrs['loading'] = false; - $attrs = apply_filters( 'generate_single_featured_image_attrs', $attrs ); - - $image_html = apply_filters( - 'post_thumbnail_html', // phpcs:ignore -- Core filter. - wp_get_attachment_image( - $image_id, - apply_filters( 'generate_page_header_default_size', 'full' ), - '', - $attrs - ), - get_the_ID(), - $image_id, - apply_filters( 'generate_page_header_default_size', 'full' ), - '' - ); - - $location = generate_blog_get_singular_template(); - - $classes = array( - is_page() ? 'page-header-image' : null, - is_singular() && ! is_page() ? 'page-header-image-single' : null, - 'above-content' === $settings[ $location . '_post_image_position' ] ? 'grid-container grid-parent' : null, - ); - - $image_html = apply_filters( 'generate_single_featured_image_html', $image_html ); - - // phpcs:ignore -- No need to escape here. - echo apply_filters( - 'generate_single_featured_image_output', - sprintf( - '', - $image_html, - implode( ' ', $classes ) - ), - $image_html - ); -} - -add_filter( 'generate_blog_image_attributes', 'generate_blog_page_header_image_atts' ); -/** - * Filter our image attributes in case we're using differents atts in our Page Header - * - * @since 1.5 - * - * @param array $atts Our existing image attributes. - * @return array Image attributes - */ -function generate_blog_page_header_image_atts( $atts ) { - if ( ! function_exists( 'generate_page_header_get_options' ) ) { - return $atts; - } - - if ( ! is_singular() ) { - return $atts; - } - - $options = generate_page_header_get_options(); - - if ( $options && 'enable' === $options['image_resize'] ) { - $ignore_crop = array( '', '0', '9999' ); - - $atts = array( - 'width' => ( in_array( $options['image_width'], $ignore_crop ) ) ? 9999 : absint( $options['image_width'] ), - 'height' => ( in_array( $options['image_height'], $ignore_crop ) ) ? 9999 : absint( $options['image_height'] ), - 'crop' => ( in_array( $options['image_width'], $ignore_crop ) || in_array( $options['image_height'], $ignore_crop ) ) ? false : true, - ); - } - - return $atts; -} - -add_filter( 'generate_single_featured_image_html', 'generate_blog_page_header_link' ); -/** - * Add our Page Header link to our featured image if set. - * - * @since 1.5 - * - * @param string $image_html Our existing image HTML. - * @return string Our new image HTML. - */ -function generate_blog_page_header_link( $image_html ) { - if ( ! function_exists( 'generate_page_header_get_options' ) ) { - return $image_html; - } - - $options = generate_page_header_get_options(); - - if ( ! empty( $options['image_link'] ) ) { - return '' . $image_html . ''; - } else { - return $image_html; - } -} - -add_filter( 'body_class', 'generate_blog_remove_featured_image_class', 20 ); -/** - * Remove the featured image classes if they're disabled. - * - * @since 2.1.0 - * @param array $classes The body classes. - */ -function generate_blog_remove_featured_image_class( $classes ) { - if ( is_singular() ) { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( is_single() ) { - $disable_single_featured_image = ! $settings['single_post_image']; - $classes = generate_premium_remove_featured_image_class( $classes, $disable_single_featured_image ); - } - - if ( is_page() && ! $settings['page_post_image'] ) { - $disable_page_featured_image = ! $settings['page_post_image']; - $classes = generate_premium_remove_featured_image_class( $classes, $disable_page_featured_image ); - } - } - - return $classes; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/controls.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/controls.js deleted file mode 100644 index eb397ff9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/controls.js +++ /dev/null @@ -1,98 +0,0 @@ -jQuery( function( $ ) { - // Featured image controls - var featuredImageArchiveControls = [ - 'generate_blog_settings-post_image', - 'generate_blog_settings-post_image_padding', - 'generate_blog_settings-post_image_position', - 'generate_blog_settings-post_image_alignment', - 'generate_blog_settings-post_image_size', - 'generate_blog_settings-post_image_width', - 'generate_blog_settings-post_image_height', - 'generate_regenerate_images_notice', - ]; - - $.each( featuredImageArchiveControls, function( index, value ) { - $( '#customize-control-' + value ).attr( 'data-control-section', 'featured-image-archives' ); - } ); - - var featuredImageSingleControls = [ - 'generate_blog_settings-single_post_image', - 'generate_blog_settings-single_post_image_padding', - 'generate_blog_settings-single_post_image_position', - 'generate_blog_settings-single_post_image_alignment', - 'generate_blog_settings-single_post_image_size', - 'generate_blog_settings-single_post_image_width', - 'generate_blog_settings-single_post_image_height', - 'generate_regenerate_single_post_images_notice', - ]; - - $.each( featuredImageSingleControls, function( index, value ) { - $( '#customize-control-' + value ).attr( 'data-control-section', 'featured-image-single' ).css( { - visibility: 'hidden', - height: '0', - width: '0', - margin: '0', - overflow: 'hidden', - } ); - } ); - - var featuredImagePageControls = [ - 'generate_blog_settings-page_post_image', - 'generate_blog_settings-page_post_image_padding', - 'generate_blog_settings-page_post_image_position', - 'generate_blog_settings-page_post_image_alignment', - 'generate_blog_settings-page_post_image_size', - 'generate_blog_settings-page_post_image_width', - 'generate_blog_settings-page_post_image_height', - 'generate_regenerate_page_images_notice', - ]; - - $.each( featuredImagePageControls, function( index, value ) { - $( '#customize-control-' + value ).attr( 'data-control-section', 'featured-image-page' ).css( { - visibility: 'hidden', - height: '0', - width: '0', - margin: '0', - overflow: 'hidden', - } ); - } ); - - // Post meta controls - var postMetaArchiveControls = [ - 'generate_settings-post_content', - 'generate_blog_settings-excerpt_length', - 'generate_blog_settings-read_more', - 'generate_blog_settings-read_more_button', - 'generate_blog_settings-date', - 'generate_blog_settings-author', - 'generate_blog_settings-categories', - 'generate_blog_settings-tags', - 'generate_blog_settings-comments', - 'generate_blog_settings-infinite_scroll', - 'generate_blog_settings-infinite_scroll_button', - 'blog_masonry_load_more_control', - 'blog_masonry_loading_control', - ]; - - $.each( postMetaArchiveControls, function( index, value ) { - $( '#customize-control-' + value ).attr( 'data-control-section', 'post-meta-archives' ); - } ); - - var postMetaSingleControls = [ - 'generate_blog_settings-single_date', - 'generate_blog_settings-single_author', - 'generate_blog_settings-single_categories', - 'generate_blog_settings-single_tags', - 'generate_blog_settings-single_post_navigation', - ]; - - $.each( postMetaSingleControls, function( index, value ) { - $( '#customize-control-' + value ).attr( 'data-control-section', 'post-meta-single' ).css( { - visibility: 'hidden', - height: '0', - width: '0', - margin: '0', - overflow: 'hidden', - } ); - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/customizer.js deleted file mode 100644 index f3c6656c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/customizer.js +++ /dev/null @@ -1,76 +0,0 @@ -/** - * Theme Customizer enhancements for a better user experience. - * - * Contains handlers to make Theme Customizer preview reload changes asynchronously. - */ - -( function( $ ) { - // Container width - wp.customize( 'generate_settings[container_width]', function( value ) { - value.bind( function() { - if ( $( '.masonry-container' )[ 0 ] ) { - jQuery( '.masonry-container' ).imagesLoaded( function() { - $container = jQuery( '.masonry-container' ); - if ( jQuery( $container ).length ) { - $container.masonry( { - columnWidth: '.grid-sizer', - itemSelector: '.masonry-post', - stamp: '.page-header', - } ); - } - } ); - } - } ); - } ); - - $( 'body' ).on( 'generate_spacing_updated', function() { - if ( $( '.masonry-container' )[ 0 ] ) { - jQuery( '.masonry-container' ).imagesLoaded( function() { - $container = jQuery( '.masonry-container' ); - if ( jQuery( $container ).length ) { - $container.masonry( { - columnWidth: '.grid-sizer', - itemSelector: '.masonry-post', - stamp: '.page-header', - } ); - } - } ); - } - } ); - - /** - * The first infinite scroll load in the Customizer misses article classes if they've been - * added or removed in the previous refresh. - * - * This is totally hacky, but I'm just happy I finally got it working! - */ - var $container = $( '.infinite-scroll-item' ).first().parent(); - $container.on( 'load.infiniteScroll', function( event, response ) { - var $posts = $( response ).find( 'article' ); - if ( wp.customize.value( 'generate_blog_settings[column_layout]' )() ) { - $posts.addClass( 'generate-columns' ); - $posts.addClass( 'grid-parent' ); - $posts.addClass( 'grid-' + wp.customize.value( 'generate_blog_settings[columns]' )() ); - $posts.addClass( 'tablet-grid-50' ); - $posts.addClass( 'mobile-grid-100' ); - } else { - $posts.removeClass( 'generate-columns' ); - $posts.removeClass( 'grid-parent' ); - $posts.removeClass( 'grid-' + wp.customize.value( 'generate_blog_settings[columns]' )() ); - $posts.removeClass( 'tablet-grid-50' ); - $posts.removeClass( 'mobile-grid-100' ); - } - - if ( wp.customize.value( 'generate_blog_settings[masonry]' )() ) { - $posts.addClass( 'masonry-post' ); - } else { - $posts.removeClass( 'masonry-post' ); - } - - if ( ! wp.customize.value( 'generate_blog_settings[post_image_padding]' )() ) { - $posts.addClass( 'no-featured-image-padding' ); - } else { - $posts.removeClass( 'no-featured-image-padding' ); - } - } ); -}( jQuery ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/infinite-scroll.pkgd.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/infinite-scroll.pkgd.min.js deleted file mode 100644 index 329c20c6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/functions/js/infinite-scroll.pkgd.min.js +++ /dev/null @@ -1,12 +0,0 @@ -/*! - * Infinite Scroll PACKAGED v3.0.6 - * Automatically add next page - * - * Licensed GPLv3 for open source use - * or Infinite Scroll Commercial License for commercial use - * - * https://infinite-scroll.com - * Copyright 2018 Metafizzy - */ - -!function(t,e){"function"==typeof define&&define.amd?define("jquery-bridget/jquery-bridget",["jquery"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("jquery")):t.jQueryBridget=e(t,t.jQuery)}(window,function(t,e){"use strict";function i(i,r,l){function a(t,e,n){var o,r="$()."+i+'("'+e+'")';return t.each(function(t,a){var h=l.data(a,i);if(!h)return void s(i+" not initialized. Cannot call methods, i.e. "+r);var c=h[e];if(!c||"_"==e.charAt(0))return void s(r+" is not a valid method");var u=c.apply(h,n);o=void 0===o?u:o}),void 0!==o?o:t}function h(t,e){t.each(function(t,n){var o=l.data(n,i);o?(o.option(e),o._init()):(o=new r(n,e),l.data(n,i,o))})}l=l||e||t.jQuery,l&&(r.prototype.option||(r.prototype.option=function(t){l.isPlainObject(t)&&(this.options=l.extend(!0,this.options,t))}),l.fn[i]=function(t){if("string"==typeof t){var e=o.call(arguments,1);return a(this,t,e)}return h(this,t),this},n(l))}function n(t){!t||t&&t.bridget||(t.bridget=i)}var o=Array.prototype.slice,r=t.console,s="undefined"==typeof r?function(){}:function(t){r.error(t)};return n(e||t.jQuery),i}),function(t,e){"function"==typeof define&&define.amd?define("ev-emitter/ev-emitter",e):"object"==typeof module&&module.exports?module.exports=e():t.EvEmitter=e()}("undefined"!=typeof window?window:this,function(){function t(){}var e=t.prototype;return e.on=function(t,e){if(t&&e){var i=this._events=this._events||{},n=i[t]=i[t]||[];return n.indexOf(e)==-1&&n.push(e),this}},e.once=function(t,e){if(t&&e){this.on(t,e);var i=this._onceEvents=this._onceEvents||{},n=i[t]=i[t]||{};return n[e]=!0,this}},e.off=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){var n=i.indexOf(e);return n!=-1&&i.splice(n,1),this}},e.emitEvent=function(t,e){var i=this._events&&this._events[t];if(i&&i.length){i=i.slice(0),e=e||[];for(var n=this._onceEvents&&this._onceEvents[t],o=0;o=0,this.isPrefilling?(this.log("prefill"),this.loadNextPage()):this.stopPrefill()},s.getPrefillDistance=function(){return this.options.elementScroll?this.scroller.clientHeight-this.scroller.scrollHeight:this.windowHeight-this.element.clientHeight},s.stopPrefill=function(){this.log("stopPrefill"),this.off("append",this.prefill)},e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/scroll-watch",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){var n=e.prototype;return e.defaults.scrollThreshold=400,e.create.scrollWatch=function(){this.pageScrollHandler=this.onPageScroll.bind(this),this.resizeHandler=this.onResize.bind(this);var t=this.options.scrollThreshold,e=t||0===t;e&&this.enableScrollWatch()},e.destroy.scrollWatch=function(){this.disableScrollWatch()},n.enableScrollWatch=function(){this.isScrollWatching||(this.isScrollWatching=!0,this.updateMeasurements(),this.updateScroller(),this.on("last",this.disableScrollWatch),this.bindScrollWatchEvents(!0))},n.disableScrollWatch=function(){this.isScrollWatching&&(this.bindScrollWatchEvents(!1),delete this.isScrollWatching)},n.bindScrollWatchEvents=function(e){var i=e?"addEventListener":"removeEventListener";this.scroller[i]("scroll",this.pageScrollHandler),t[i]("resize",this.resizeHandler)},n.onPageScroll=e.throttle(function(){var t=this.getBottomDistance();t<=this.options.scrollThreshold&&this.dispatchEvent("scrollThreshold")}),n.getBottomDistance=function(){return this.options.elementScroll?this.getElementBottomDistance():this.getWindowBottomDistance()},n.getWindowBottomDistance=function(){var e=this.top+this.element.clientHeight,i=t.pageYOffset+this.windowHeight;return e-i},n.getElementBottomDistance=function(){var t=this.scroller.scrollHeight,e=this.scroller.scrollTop+this.scroller.clientHeight;return t-e},n.onResize=function(){this.updateMeasurements()},i.debounceMethod(e,"onResize",150),e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/history",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){var n=e.prototype;e.defaults.history="replace";var o=document.createElement("a");return e.create.history=function(){if(this.options.history){o.href=this.getAbsolutePath();var t=o.origin||o.protocol+"//"+o.host,e=t==location.origin;return e?void(this.options.append?this.createHistoryAppend():this.createHistoryPageLoad()):void console.error("[InfiniteScroll] cannot set history with different origin: "+o.origin+" on "+location.origin+" . History behavior disabled.")}},n.createHistoryAppend=function(){this.updateMeasurements(),this.updateScroller(),this.scrollPages=[{top:0,path:location.href,title:document.title}],this.scrollPageIndex=0,this.scrollHistoryHandler=this.onScrollHistory.bind(this),this.unloadHandler=this.onUnload.bind(this),this.scroller.addEventListener("scroll",this.scrollHistoryHandler),this.on("append",this.onAppendHistory),this.bindHistoryAppendEvents(!0)},n.bindHistoryAppendEvents=function(e){var i=e?"addEventListener":"removeEventListener";this.scroller[i]("scroll",this.scrollHistoryHandler),t[i]("unload",this.unloadHandler)},n.createHistoryPageLoad=function(){this.on("load",this.onPageLoadHistory)},e.destroy.history=n.destroyHistory=function(){var t=this.options.history&&this.options.append;t&&this.bindHistoryAppendEvents(!1)},n.onAppendHistory=function(t,e,i){if(i&&i.length){var n=i[0],r=this.getElementScrollY(n);o.href=e,this.scrollPages.push({top:r,path:o.href,title:t.title})}},n.getElementScrollY=function(t){return this.options.elementScroll?this.getElementElementScrollY(t):this.getElementWindowScrollY(t)},n.getElementWindowScrollY=function(e){var i=e.getBoundingClientRect();return i.top+t.pageYOffset},n.getElementElementScrollY=function(t){return t.offsetTop-this.top},n.onScrollHistory=function(){for(var t,e,i=this.getScrollViewY(),n=0;n=i)break;t=n,e=o}t!=this.scrollPageIndex&&(this.scrollPageIndex=t,this.setHistory(e.title,e.path))},i.debounceMethod(e,"onScrollHistory",150),n.getScrollViewY=function(){return this.options.elementScroll?this.scroller.scrollTop+this.scroller.clientHeight/2:t.pageYOffset+this.windowHeight/2},n.setHistory=function(t,e){var i=this.options.history,n=i&&history[i+"State"];n&&(history[i+"State"](null,t,e),this.options.historyTitle&&(document.title=t),this.dispatchEvent("history",null,[t,e]))},n.onUnload=function(){var e=this.scrollPageIndex;if(0!==e){var i=this.scrollPages[e],n=t.pageYOffset-i.top+this.top;this.destroyHistory(),scrollTo(0,n)}},n.onPageLoadHistory=function(t,e){this.setHistory(t.title,e)},e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/button",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){function n(t,e){this.element=t,this.infScroll=e,this.clickHandler=this.onClick.bind(this),this.element.addEventListener("click",this.clickHandler),e.on("request",this.disable.bind(this)),e.on("load",this.enable.bind(this)),e.on("error",this.hide.bind(this)),e.on("last",this.hide.bind(this))}return e.create.button=function(){var t=i.getQueryElement(this.options.button);if(t)return void(this.button=new n(t,this))},e.destroy.button=function(){this.button&&this.button.destroy()},n.prototype.onClick=function(t){t.preventDefault(),this.infScroll.loadNextPage()},n.prototype.enable=function(){this.element.removeAttribute("disabled")},n.prototype.disable=function(){this.element.disabled="disabled"},n.prototype.hide=function(){this.element.style.display="none"},n.prototype.destroy=function(){this.element.removeEventListener("click",this.clickHandler)},e.Button=n,e}),function(t,e){"function"==typeof define&&define.amd?define("infinite-scroll/js/status",["./core","fizzy-ui-utils/utils"],function(i,n){return e(t,i,n)}):"object"==typeof module&&module.exports?module.exports=e(t,require("./core"),require("fizzy-ui-utils")):e(t,t.InfiniteScroll,t.fizzyUIUtils)}(window,function(t,e,i){function n(t){r(t,"none")}function o(t){r(t,"block")}function r(t,e){t&&(t.style.display=e)}var s=e.prototype;return e.create.status=function(){var t=i.getQueryElement(this.options.status);t&&(this.statusElement=t,this.statusEventElements={request:t.querySelector(".infinite-scroll-request"),error:t.querySelector(".infinite-scroll-error"),last:t.querySelector(".infinite-scroll-last")},this.on("request",this.showRequestStatus),this.on("error",this.showErrorStatus),this.on("last",this.showLastStatus),this.bindHideStatus("on"))},s.bindHideStatus=function(t){var e=this.options.append?"append":"load";this[t](e,this.hideAllStatus)},s.showRequestStatus=function(){this.showStatus("request")},s.showErrorStatus=function(){this.showStatus("error")},s.showLastStatus=function(){this.showStatus("last"),this.bindHideStatus("off")},s.showStatus=function(t){o(this.statusElement),this.hideStatusEventElements();var e=this.statusEventElements[t];o(e)},s.hideAllStatus=function(){n(this.statusElement),this.hideStatusEventElements()},s.hideStatusEventElements=function(){for(var t in this.statusEventElements){var e=this.statusEventElements[t];n(e)}},e}),function(t,e){"function"==typeof define&&define.amd?define(["infinite-scroll/js/core","infinite-scroll/js/page-load","infinite-scroll/js/scroll-watch","infinite-scroll/js/history","infinite-scroll/js/button","infinite-scroll/js/status"],e):"object"==typeof module&&module.exports&&(module.exports=e(require("./core"),require("./page-load"),require("./scroll-watch"),require("./history"),require("./button"),require("./status")))}(window,function(t){return t}),function(t,e){"use strict";"function"==typeof define&&define.amd?define("imagesloaded/imagesloaded",["ev-emitter/ev-emitter"],function(i){return e(t,i)}):"object"==typeof module&&module.exports?module.exports=e(t,require("ev-emitter")):t.imagesLoaded=e(t,t.EvEmitter)}("undefined"!=typeof window?window:this,function(t,e){function i(t,e){for(var i in e)t[i]=e[i];return t}function n(t){if(Array.isArray(t))return t;var e="object"==typeof t&&"number"==typeof t.length;return e?h.call(t):[t]}function o(t,e,r){if(!(this instanceof o))return new o(t,e,r);var s=t;return"string"==typeof t&&(s=document.querySelectorAll(t)),s?(this.elements=n(s),this.options=i({},this.options),"function"==typeof e?r=e:i(this.options,e),r&&this.on("always",r),this.getImages(),l&&(this.jqDeferred=new l.Deferred),void setTimeout(this.check.bind(this))):void a.error("Bad element for imagesLoaded "+(s||t))}function r(t){this.img=t}function s(t,e){this.url=t,this.element=e,this.img=new Image}var l=t.jQuery,a=t.console,h=Array.prototype.slice;o.prototype=Object.create(e.prototype),o.prototype.options={},o.prototype.getImages=function(){this.images=[],this.elements.forEach(this.addElementImages,this)},o.prototype.addElementImages=function(t){"IMG"==t.nodeName&&this.addImage(t),this.options.background===!0&&this.addElementBackgroundImages(t);var e=t.nodeType;if(e&&c[e]){for(var i=t.querySelectorAll("img"),n=0;n 'false', - 'masonry_width' => 'width2', - 'masonry_most_recent_width' => 'width4', - 'post_image' => 'true', - 'date' => 'true', - 'author' => 'true', - 'categories' => 'true', - 'tags' => 'true', - 'comments' => 'true', - ); - - // Get our spacing settings - $blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - $defaults - ); - - $new_settings = array(); - - // These options use to be a select input with false + true values - // This will make the false values empty so the options can be checkboxes - $keys = array( 'date', 'author', 'categories', 'tags', 'comments', 'masonry', 'post_image' ); - foreach ( $keys as $key ) { - if ( is_string( $blog_settings[ $key ] ) ) { - if ( 'false' == $blog_settings[ $key ] ) { - $new_settings[ $key ] = false; - } elseif ( 'true' == $blog_settings[ $key ] ) { - $new_settings[ $key ] = true; - } - } - } - - // Set the single post meta options to whatever the blog options are - $new_settings[ 'single_date' ] = isset( $new_settings[ 'date' ] ) ? $new_settings[ 'date' ] : true; - $new_settings[ 'single_author' ] = isset( $new_settings[ 'author' ] ) ? $new_settings[ 'author' ] : true; - $new_settings[ 'single_categories' ] = isset( $new_settings[ 'categories' ] ) ? $new_settings[ 'categories' ] : true; - $new_settings[ 'single_tags' ] = isset( $new_settings[ 'tags' ] ) ? $new_settings[ 'tags' ] : true; - - if ( isset( $new_settings[ 'masonry' ] ) && $new_settings[ 'masonry' ] ) { - $new_settings[ 'column_layout' ] = true; - $new_settings[ 'infinite_scroll' ] = true; - $new_settings[ 'infinite_scroll_button' ] = true; - - if ( 'width2' == $blog_settings['masonry_width'] ) { - $new_settings[ 'columns' ] = '33'; - } - - if ( 'width4' == $blog_settings['masonry_width'] ) { - $new_settings[ 'columns' ] = '50'; - } - - if ( 'width6' == $blog_settings['masonry_width'] ) { - $new_settings[ 'columns' ] = '100'; - } - - if ( 'width2' == $blog_settings[ 'masonry_width' ] ) { - if ( 'width2' !== $blog_settings[ 'masonry_most_recent_width' ] ) { - $new_settings[ 'featured_column' ] = true; - } else { - $new_settings[ 'featured_column' ] = false; - } - } - - if ( 'width4' == $blog_settings[ 'masonry_width' ] ) { - if ( 'width6' == $blog_settings[ 'masonry_most_recent_width' ] ) { - $new_settings[ 'featured_column' ] = true; - } else { - $new_settings[ 'featured_column' ] = false; - } - } - - if ( 'width6' == $blog_settings[ 'masonry_width' ] ) { - $new_settings[ 'featured_column' ] = false; - } - } - - if ( function_exists( 'generate_page_header_get_defaults' ) ) { - $page_header_settings = wp_parse_args( - get_option( 'generate_page_header_settings', array() ), - generate_page_header_get_defaults() - ); - - if ( 'hide' == $page_header_settings[ 'post_header_position' ] ) { - $new_settings[ 'single_post_image' ] = false; - } else { - $new_settings[ 'single_post_image_position' ] = $page_header_settings[ 'post_header_position' ]; - } - - $new_settings[ 'page_post_image_position' ] = $page_header_settings[ 'page_header_position' ]; - } - - unset( $blog_settings['masonry_width'] ); - unset( $blog_settings['masonry_most_recent_width'] ); - - $update_settings = wp_parse_args( $new_settings, $blog_settings ); - update_option( 'generate_blog_settings', $update_settings ); - - // Update our migration option so we don't need to run this again - $updated[ 'blog_visibility_updated' ] = 'true'; - $migration_settings = wp_parse_args( $updated, $settings ); - update_option( 'generate_migration_settings', $migration_settings ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/generate-blog.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/generate-blog.php deleted file mode 100644 index 49fd37fd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/blog/generate-blog.php +++ /dev/null @@ -1,20 +0,0 @@ -register_control_type( 'GeneratePress_Alpha_Color_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Title_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Get our palettes. - $palettes = generate_get_default_color_palettes(); - - // Add our Colors panel. - if ( class_exists( 'WP_Customize_Panel' ) ) { - $wp_customize->add_panel( - 'generate_colors_panel', - array( - 'priority' => 30, - 'theme_supports' => '', - 'title' => __( 'Colors', 'gp-premium' ), - 'description' => '', - ) - ); - } - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_body_color_shortcuts', - array( - 'section' => 'body_section', - 'element' => __( 'Body', 'gp-premium' ), - 'shortcuts' => array( - 'typography' => 'font_section', - 'backgrounds' => 'generate_backgrounds_body', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Add Top Bar Colors section. - if ( isset( $defaults['top_bar_background_color'] ) && function_exists( 'generate_is_top_bar_active' ) ) { - $wp_customize->add_section( - 'generate_top_bar_colors', - array( - 'title' => __( 'Top Bar', 'gp-premium' ), - 'priority' => 40, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[top_bar_background_color]', - array( - 'default' => $defaults['top_bar_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[top_bar_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'generate_top_bar_colors', - 'settings' => 'generate_settings[top_bar_background_color]', - 'palette' => $palettes, - 'show_opacity' => true, - 'priority' => 1, - 'active_callback' => 'generate_is_top_bar_active', - ) - ) - ); - - // Add color settings. - $top_bar_colors = array(); - $top_bar_colors[] = array( - 'slug' => 'top_bar_text_color', - 'default' => $defaults['top_bar_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - 'priority' => 2, - ); - $top_bar_colors[] = array( - 'slug' => 'top_bar_link_color', - 'default' => $defaults['top_bar_link_color'], - 'label' => __( 'Link', 'gp-premium' ), - 'priority' => 3, - ); - $top_bar_colors[] = array( - 'slug' => 'top_bar_link_color_hover', - 'default' => $defaults['top_bar_link_color_hover'], - 'label' => __( 'Link Hover', 'gp-premium' ), - 'priority' => 4, - ); - - foreach ( $top_bar_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'generate_top_bar_colors', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - 'palette' => $palettes, - 'active_callback' => 'generate_is_top_bar_active', - ) - ) - ); - } - } - - // Add Header Colors section. - $wp_customize->add_section( - 'header_color_section', - array( - 'title' => __( 'Header', 'gp-premium' ), - 'priority' => 50, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_header_color_shortcuts', - array( - 'section' => 'header_color_section', - 'element' => __( 'Header', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_header', - 'typography' => 'font_header_section', - 'backgrounds' => 'generate_backgrounds_header', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[header_background_color]', - array( - 'default' => $defaults['header_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[header_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'header_color_section', - 'settings' => 'generate_settings[header_background_color]', - 'palette' => $palettes, - 'show_opacity' => true, - 'priority' => 1, - ) - ) - ); - - // Add color settings. - $header_colors = array(); - $header_colors[] = array( - 'slug' => 'header_text_color', - 'default' => $defaults['header_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - 'priority' => 2, - ); - $header_colors[] = array( - 'slug' => 'header_link_color', - 'default' => $defaults['header_link_color'], - 'label' => __( 'Link', 'gp-premium' ), - 'priority' => 3, - ); - $header_colors[] = array( - 'slug' => 'header_link_hover_color', - 'default' => $defaults['header_link_hover_color'], - 'label' => __( 'Link Hover', 'gp-premium' ), - 'priority' => 4, - ); - $header_colors[] = array( - 'slug' => 'site_title_color', - 'default' => $defaults['site_title_color'], - 'label' => __( 'Site Title', 'gp-premium' ), - 'priority' => 5, - ); - $header_colors[] = array( - 'slug' => 'site_tagline_color', - 'default' => $defaults['site_tagline_color'], - 'label' => __( 'Tagline', 'gp-premium' ), - 'priority' => 6, - ); - - foreach ( $header_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'header_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - 'palette' => $palettes, - ) - ) - ); - } - - // Add Navigation section. - $wp_customize->add_section( - 'navigation_color_section', - array( - 'title' => __( 'Primary Navigation', 'gp-premium' ), - 'priority' => 60, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_primary_navigation_color_shortcuts', - array( - 'section' => 'navigation_color_section', - 'element' => __( 'Primary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_navigation', - 'typography' => 'font_navigation_section', - 'backgrounds' => 'generate_backgrounds_navigation', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_primary_navigation_parent_items', - array( - 'section' => 'navigation_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Parent Items', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_background_color]', - array( - 'default' => $defaults['navigation_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[navigation_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[navigation_background_color]', - 'palette' => $palettes, - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_background_hover_color]', - array( - 'default' => $defaults['navigation_background_hover_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[navigation_background_hover_color]', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[navigation_background_hover_color]', - 'palette' => $palettes, - 'priority' => 3, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_background_current_color]', - array( - 'default' => $defaults['navigation_background_current_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[navigation_background_current_color]', - array( - 'label' => __( 'Background Current', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[navigation_background_current_color]', - 'palette' => $palettes, - 'priority' => 5, - ) - ) - ); - - // Add color settings. - $navigation_colors = array(); - $navigation_colors[] = array( - 'slug' => 'navigation_text_color', - 'default' => $defaults['navigation_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - 'priority' => 2, - ); - $navigation_colors[] = array( - 'slug' => 'navigation_text_hover_color', - 'default' => $defaults['navigation_text_hover_color'], - 'label' => __( 'Text Hover', 'gp-premium' ), - 'priority' => 4, - ); - $navigation_colors[] = array( - 'slug' => 'navigation_text_current_color', - 'default' => $defaults['navigation_text_current_color'], - 'label' => __( 'Text Current', 'gp-premium' ), - 'priority' => 6, - ); - - foreach ( $navigation_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - ) - ) - ); - } - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_primary_navigation_sub_menu_items', - array( - 'section' => 'navigation_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Sub-Menu Items', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 7, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[subnavigation_background_color]', - array( - 'default' => $defaults['subnavigation_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[subnavigation_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[subnavigation_background_color]', - 'palette' => $palettes, - 'priority' => 8, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[subnavigation_background_hover_color]', - array( - 'default' => $defaults['subnavigation_background_hover_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[subnavigation_background_hover_color]', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[subnavigation_background_hover_color]', - 'palette' => $palettes, - 'priority' => 10, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[subnavigation_background_current_color]', - array( - 'default' => $defaults['subnavigation_background_current_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[subnavigation_background_current_color]', - array( - 'label' => __( 'Background Current', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[subnavigation_background_current_color]', - 'palette' => $palettes, - 'priority' => 12, - ) - ) - ); - - // Add color settings. - $subnavigation_colors = array(); - $subnavigation_colors[] = array( - 'slug' => 'subnavigation_text_color', - 'default' => $defaults['subnavigation_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - 'priority' => 9, - ); - $subnavigation_colors[] = array( - 'slug' => 'subnavigation_text_hover_color', - 'default' => $defaults['subnavigation_text_hover_color'], - 'label' => __( 'Text Hover', 'gp-premium' ), - 'priority' => 11, - ); - $subnavigation_colors[] = array( - 'slug' => 'subnavigation_text_current_color', - 'default' => $defaults['subnavigation_text_current_color'], - 'label' => __( 'Text Current', 'gp-premium' ), - 'priority' => 13, - ); - - foreach ( $subnavigation_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - ) - ) - ); - } - - if ( isset( $defaults['navigation_search_background_color'] ) ) { - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_primary_navigation_search', - array( - 'section' => 'navigation_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Navigation Search', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 15, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_search_background_color]', - array( - 'default' => $defaults['navigation_search_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[navigation_search_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[navigation_search_background_color]', - 'palette' => $palettes, - 'priority' => 16, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_search_text_color]', - array( - 'default' => $defaults['navigation_search_text_color'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[navigation_search_text_color]', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'navigation_color_section', - 'settings' => 'generate_settings[navigation_search_text_color]', - 'priority' => 17, - ) - ) - ); - } - - $wp_customize->add_section( - 'buttons_color_section', - array( - 'title' => __( 'Buttons', 'gp-premium' ), - 'priority' => 75, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_buttons_color_shortcuts', - array( - 'section' => 'buttons_color_section', - 'element' => __( 'Button', 'gp-premium' ), - 'shortcuts' => array( - 'typography' => 'font_buttons_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_button_background_color]', - array( - 'default' => $defaults['form_button_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[form_button_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'buttons_color_section', - 'settings' => 'generate_settings[form_button_background_color]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_button_text_color]', - array( - 'default' => $defaults['form_button_text_color'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'form_button_text_color', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'buttons_color_section', - 'settings' => 'generate_settings[form_button_text_color]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_button_background_color_hover]', - array( - 'default' => $defaults['form_button_background_color_hover'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[form_button_background_color_hover]', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'buttons_color_section', - 'settings' => 'generate_settings[form_button_background_color_hover]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_button_text_color_hover]', - array( - 'default' => $defaults['form_button_text_color_hover'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'form_button_text_color_hover', - array( - 'label' => __( 'Text Hover', 'gp-premium' ), - 'section' => 'buttons_color_section', - 'settings' => 'generate_settings[form_button_text_color_hover]', - ) - ) - ); - - // Add Content Colors section. - $wp_customize->add_section( - 'content_color_section', - array( - 'title' => __( 'Content', 'gp-premium' ), - 'priority' => 80, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_content_color_shortcuts', - array( - 'section' => 'content_color_section', - 'element' => __( 'Content', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_container', - 'typography' => 'font_content_section', - 'backgrounds' => 'generate_backgrounds_content', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[content_background_color]', - array( - 'default' => $defaults['content_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[content_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'content_color_section', - 'settings' => 'generate_settings[content_background_color]', - 'palette' => $palettes, - 'priority' => 1, - ) - ) - ); - - // Add color settings. - $content_colors = array(); - $content_colors[] = array( - 'slug' => 'content_text_color', - 'default' => $defaults['content_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - 'priority' => 2, - ); - $content_colors[] = array( - 'slug' => 'content_link_color', - 'default' => $defaults['content_link_color'], - 'label' => __( 'Link', 'gp-premium' ), - 'priority' => 3, - ); - $content_colors[] = array( - 'slug' => 'content_link_hover_color', - 'default' => $defaults['content_link_hover_color'], - 'label' => __( 'Link Hover', 'gp-premium' ), - 'priority' => 4, - ); - $content_colors[] = array( - 'slug' => 'content_title_color', - 'default' => $defaults['content_title_color'], - 'label' => __( 'Content Title', 'gp-premium' ), - 'priority' => 5, - ); - $content_colors[] = array( - 'slug' => 'blog_post_title_color', - 'default' => $defaults['blog_post_title_color'], - 'label' => __( 'Archive Content Title', 'gp-premium' ), - 'priority' => 6, - ); - $content_colors[] = array( - 'slug' => 'blog_post_title_hover_color', - 'default' => $defaults['blog_post_title_hover_color'], - 'label' => __( 'Archive Content Title Hover', 'gp-premium' ), - 'priority' => 7, - ); - $content_colors[] = array( - 'slug' => 'entry_meta_text_color', - 'default' => $defaults['entry_meta_text_color'], - 'label' => __( 'Entry Meta Text', 'gp-premium' ), - 'priority' => 8, - ); - $content_colors[] = array( - 'slug' => 'entry_meta_link_color', - 'default' => $defaults['entry_meta_link_color'], - 'label' => __( 'Entry Meta Links', 'gp-premium' ), - 'priority' => 9, - ); - $content_colors[] = array( - 'slug' => 'entry_meta_link_color_hover', - 'default' => $defaults['entry_meta_link_color_hover'], - 'label' => __( 'Entry Meta Links Hover', 'gp-premium' ), - 'priority' => 10, - ); - $content_colors[] = array( - 'slug' => 'h1_color', - 'default' => $defaults['h1_color'], - 'label' => __( 'Heading 1 (H1) Color', 'gp-premium' ), - 'priority' => 11, - ); - $content_colors[] = array( - 'slug' => 'h2_color', - 'default' => $defaults['h2_color'], - 'label' => __( 'Heading 2 (H2) Color', 'gp-premium' ), - 'priority' => 12, - ); - $content_colors[] = array( - 'slug' => 'h3_color', - 'default' => $defaults['h3_color'], - 'label' => __( 'Heading 3 (H3) Color', 'gp-premium' ), - 'priority' => 13, - ); - - if ( isset( $defaults['h4_color'] ) ) { - $content_colors[] = array( - 'slug' => 'h4_color', - 'default' => $defaults['h4_color'], - 'label' => __( 'Heading 4 (H4) Color', 'gp-premium' ), - 'priority' => 14, - ); - } - - if ( isset( $defaults['h5_color'] ) ) { - $content_colors[] = array( - 'slug' => 'h5_color', - 'default' => $defaults['h5_color'], - 'label' => __( 'Heading 5 (H5) Color', 'gp-premium' ), - 'priority' => 15, - ); - } - - foreach ( $content_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'content_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - ) - ) - ); - } - - // Add Sidebar Widget colors. - $wp_customize->add_section( - 'sidebar_widget_color_section', - array( - 'title' => __( 'Sidebar Widgets', 'gp-premium' ), - 'priority' => 90, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_sidebar_color_shortcuts', - array( - 'section' => 'sidebar_widget_color_section', - 'element' => __( 'Sidebar', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_sidebars', - 'typography' => 'font_widget_section', - 'backgrounds' => 'generate_backgrounds_sidebars', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[sidebar_widget_background_color]', - array( - 'default' => $defaults['sidebar_widget_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[sidebar_widget_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'sidebar_widget_color_section', - 'settings' => 'generate_settings[sidebar_widget_background_color]', - 'palette' => $palettes, - 'priority' => 1, - ) - ) - ); - - // Add color settings. - $sidebar_widget_colors = array(); - $sidebar_widget_colors[] = array( - 'slug' => 'sidebar_widget_text_color', - 'default' => $defaults['sidebar_widget_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - 'priority' => 2, - ); - $sidebar_widget_colors[] = array( - 'slug' => 'sidebar_widget_link_color', - 'default' => $defaults['sidebar_widget_link_color'], - 'label' => __( 'Link', 'gp-premium' ), - 'priority' => 3, - ); - $sidebar_widget_colors[] = array( - 'slug' => 'sidebar_widget_link_hover_color', - 'default' => $defaults['sidebar_widget_link_hover_color'], - 'label' => __( 'Link Hover', 'gp-premium' ), - 'priority' => 4, - ); - $sidebar_widget_colors[] = array( - 'slug' => 'sidebar_widget_title_color', - 'default' => $defaults['sidebar_widget_title_color'], - 'label' => __( 'Widget Title', 'gp-premium' ), - 'priority' => 5, - ); - - foreach ( $sidebar_widget_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'sidebar_widget_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - ) - ) - ); - } - - // Add Form colors. - $wp_customize->add_section( - 'form_color_section', - array( - 'title' => __( 'Forms', 'gp-premium' ), - 'priority' => 130, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_background_color]', - array( - 'default' => $defaults['form_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[form_background_color]', - array( - 'label' => __( 'Form Background', 'gp-premium' ), - 'section' => 'form_color_section', - 'settings' => 'generate_settings[form_background_color]', - 'palette' => $palettes, - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_background_color_focus]', - array( - 'default' => $defaults['form_background_color_focus'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[form_background_color_focus]', - array( - 'label' => __( 'Form Background Focus', 'gp-premium' ), - 'section' => 'form_color_section', - 'settings' => 'generate_settings[form_background_color_focus]', - 'palette' => $palettes, - 'priority' => 3, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_border_color]', - array( - 'default' => $defaults['form_border_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[form_border_color]', - array( - 'label' => __( 'Form Border', 'gp-premium' ), - 'section' => 'form_color_section', - 'settings' => 'generate_settings[form_border_color]', - 'palette' => $palettes, - 'priority' => 5, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[form_border_color_focus]', - array( - 'default' => $defaults['form_border_color_focus'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[form_border_color_focus]', - array( - 'label' => __( 'Form Border Focus', 'gp-premium' ), - 'section' => 'form_color_section', - 'settings' => 'generate_settings[form_border_color_focus]', - 'palette' => $palettes, - 'priority' => 6, - ) - ) - ); - - // Add color settings. - $form_colors = array(); - $form_colors[] = array( - 'slug' => 'form_text_color', - 'default' => $defaults['form_text_color'], - 'label' => __( 'Form Text', 'gp-premium' ), - 'priority' => 2, - ); - $form_colors[] = array( - 'slug' => 'form_text_color_focus', - 'default' => $defaults['form_text_color_focus'], - 'label' => __( 'Form Text Focus', 'gp-premium' ), - 'priority' => 4, - ); - - foreach ( $form_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'form_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - 'priority' => $color['priority'], - ) - ) - ); - } - - // Add Footer colors. - $wp_customize->add_section( - 'footer_color_section', - array( - 'title' => __( 'Footer', 'gp-premium' ), - 'priority' => 150, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_footer_color_shortcuts', - array( - 'section' => 'footer_color_section', - 'element' => __( 'Footer', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_footer', - 'typography' => 'font_footer_section', - 'backgrounds' => 'generate_backgrounds_footer', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_footer_widgets_title', - array( - 'section' => 'footer_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Footer Widgets', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[footer_widget_background_color]', - array( - 'default' => $defaults['footer_widget_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[footer_widget_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[footer_widget_background_color]', - 'palette' => $palettes, - ) - ) - ); - - // Add color settings. - $footer_widget_colors = array(); - $footer_widget_colors[] = array( - 'slug' => 'footer_widget_text_color', - 'default' => $defaults['footer_widget_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - ); - $footer_widget_colors[] = array( - 'slug' => 'footer_widget_link_color', - 'default' => $defaults['footer_widget_link_color'], - 'label' => __( 'Link', 'gp-premium' ), - ); - $footer_widget_colors[] = array( - 'slug' => 'footer_widget_link_hover_color', - 'default' => $defaults['footer_widget_link_hover_color'], - 'label' => __( 'Link Hover', 'gp-premium' ), - ); - $footer_widget_colors[] = array( - 'slug' => 'footer_widget_title_color', - 'default' => $defaults['footer_widget_title_color'], - 'label' => __( 'Widget Title', 'gp-premium' ), - ); - - foreach ( $footer_widget_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - ) - ) - ); - } - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_footer_title', - array( - 'section' => 'footer_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Footer Bar', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[footer_background_color]', - array( - 'default' => $defaults['footer_background_color'], - 'type' => 'option', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[footer_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[footer_background_color]', - 'palette' => $palettes, - ) - ) - ); - - // Add color settings. - $footer_colors = array(); - $footer_colors[] = array( - 'slug' => 'footer_text_color', - 'default' => $defaults['footer_text_color'], - 'label' => __( 'Text', 'gp-premium' ), - ); - $footer_colors[] = array( - 'slug' => 'footer_link_color', - 'default' => $defaults['footer_link_color'], - 'label' => __( 'Link', 'gp-premium' ), - ); - $footer_colors[] = array( - 'slug' => 'footer_link_hover_color', - 'default' => $defaults['footer_link_hover_color'], - 'label' => __( 'Link Hover', 'gp-premium' ), - ); - - foreach ( $footer_colors as $color ) { - $wp_customize->add_setting( - 'generate_settings[' . $color['slug'] . ']', - array( - 'default' => $color['default'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - $color['slug'], - array( - 'label' => $color['label'], - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[' . $color['slug'] . ']', - ) - ) - ); - } - - if ( isset( $defaults['back_to_top_background_color'] ) ) { - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_back_to_top_title', - array( - 'section' => 'footer_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Back to Top Button', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[back_to_top_background_color]', - array( - 'default' => $defaults['back_to_top_background_color'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[back_to_top_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[back_to_top_background_color]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[back_to_top_text_color]', - array( - 'default' => $defaults['back_to_top_text_color'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[back_to_top_text_color]', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[back_to_top_text_color]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[back_to_top_background_color_hover]', - array( - 'default' => $defaults['back_to_top_background_color_hover'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[back_to_top_background_color_hover]', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[back_to_top_background_color_hover]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[back_to_top_text_color_hover]', - array( - 'default' => $defaults['back_to_top_text_color_hover'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[back_to_top_text_color_hover]', - array( - 'label' => __( 'Text Hover', 'gp-premium' ), - 'section' => 'footer_color_section', - 'settings' => 'generate_settings[back_to_top_text_color_hover]', - ) - ) - ); - } - } -} - -if ( ! function_exists( 'generate_get_color_setting' ) ) { - /** - * Wrapper function to get our settings - * - * @since 1.3.42 - * @param string $setting The setting to check. - */ - function generate_get_color_setting( $setting ) { - - // Bail if we don't have our color defaults. - if ( ! function_exists( 'generate_get_color_defaults' ) ) { - return; - } - - if ( function_exists( 'generate_get_defaults' ) ) { - $defaults = array_merge( generate_get_defaults(), generate_get_color_defaults() ); - } else { - $defaults = generate_get_color_defaults(); - } - - $generate_settings = wp_parse_args( - get_option( 'generate_settings', array() ), - $defaults - ); - - return $generate_settings[ $setting ]; - } -} - -if ( ! function_exists( 'generate_colors_rgba_to_hex' ) ) { - /** - * Convert RGBA to hex if necessary - * - * @since 1.3.42 - * @param string $rgba The string to convert to hex. - */ - function generate_colors_rgba_to_hex( $rgba ) { - // If it's not rgba, return it. - if ( false === strpos( $rgba, 'rgba' ) ) { - return $rgba; - } - - return substr( $rgba, 0, strrpos( $rgba, ',' ) ) . ')'; - } -} - -if ( ! function_exists( 'generate_get_default_color_palettes' ) ) { - /** - * Set up our colors for the color picker palettes and filter them so you can change them - * - * @since 1.3.42 - */ - function generate_get_default_color_palettes() { - $palettes = array( - generate_colors_rgba_to_hex( generate_get_color_setting( 'link_color' ) ), - generate_colors_rgba_to_hex( generate_get_color_setting( 'background_color' ) ), - generate_colors_rgba_to_hex( generate_get_color_setting( 'navigation_background_color' ) ), - generate_colors_rgba_to_hex( generate_get_color_setting( 'navigation_background_hover_color' ) ), - '#F1C40F', - '#1e72bd', - '#1ABC9C', - '#3498DB', - ); - - return apply_filters( 'generate_default_color_palettes', $palettes ); - } -} - -if ( ! function_exists( 'generate_enqueue_color_palettes' ) ) { - add_action( 'customize_controls_enqueue_scripts', 'generate_enqueue_color_palettes', 1001 ); - /** - * Add our custom color palettes to the color pickers in the Customizer. - * Hooks into 1001 priority to show up after Secondary Nav. - * - * @since 1.3.42 - */ - function generate_enqueue_color_palettes() { - // Old versions of WP don't get nice things. - if ( ! function_exists( 'wp_add_inline_script' ) ) { - return; - } - - // Grab our palette array and turn it into JS. - $palettes = wp_json_encode( generate_get_default_color_palettes() ); - - // Add our custom palettes. - // json_encode takes care of escaping. - wp_add_inline_script( 'wp-color-picker', 'jQuery.wp.wpColorPicker.prototype.options.palettes = ' . $palettes . ';' ); - } -} - -if ( ! function_exists( 'generate_colors_customizer_live_preview' ) ) { - add_action( 'customize_preview_init', 'generate_colors_customizer_live_preview' ); - /** - * Add our live preview javascript. - * - * @since 0.1 - */ - function generate_colors_customizer_live_preview() { - wp_enqueue_script( - 'generate-colors-customizer', - trailingslashit( plugin_dir_url( __FILE__ ) ) . 'js/customizer.js', - array( 'jquery', 'customize-preview' ), - GENERATE_COLORS_VERSION, - true - ); - - wp_register_script( - 'generate-wc-colors-customizer', - trailingslashit( plugin_dir_url( __FILE__ ) ) . 'js/wc-customizer.js', - array( 'jquery', 'customize-preview', 'generate-colors-customizer' ), - GENERATE_COLORS_VERSION, - true - ); - - wp_register_script( - 'generate-menu-plus-colors-customizer', - trailingslashit( plugin_dir_url( __FILE__ ) ) . 'js/menu-plus-customizer.js', - array( 'jquery', 'customize-preview', 'generate-colors-customizer' ), - GENERATE_COLORS_VERSION, - true - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/customizer.js deleted file mode 100644 index a2fb4253..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/customizer.js +++ /dev/null @@ -1,620 +0,0 @@ -/** - * Theme Customizer enhancements for a better user experience. - * - * Contains handlers to make Theme Customizer preview reload changes asynchronously. - */ -function generate_colors_live_update( id, selector, property, default_value, get_value, settings ) { - default_value = typeof default_value !== 'undefined' ? default_value : 'initial'; - get_value = typeof get_value !== 'undefined' ? get_value : ''; - settings = typeof settings !== 'undefined' ? settings : 'generate_settings'; - wp.customize( settings + '[' + id + ']', function( value ) { - value.bind( function( newval ) { - - // Stop the header link color from applying to the site title. - if ( 'header_link_color' === id || 'header_link_color' === id ) { - jQuery( '.site-header a' ).addClass( 'header-link' ); - jQuery( '.site-header .main-title a' ).removeClass( 'header-link' ); - } - - if ( 'content_link_color' === id || 'content_link_color_hover' === id || 'entry_meta_link_color' === id || 'blog_post_title_color' === id ) { - var content_link = jQuery( '.inside-article a' ); - var meta = jQuery( '.entry-meta a' ); - var title = jQuery( '.entry-title a' ); - - content_link.attr( 'data-content-link-color', true ); - - if ( '' !== wp.customize.value('generate_settings[entry_meta_link_color]')() ) { - meta.attr( 'data-content-link-color', '' ); - } else { - meta.attr( 'data-content-link-color', true ); - } - - if ( '' !== wp.customize.value('generate_settings[blog_post_title_color]')() ) { - title.attr( 'data-content-link-color', '' ); - } else { - title.attr( 'data-content-link-color', true ); - } - } - - default_value = ( '' !== get_value ) ? wp.customize.value('generate_settings[' + get_value + ']')() : default_value; - newval = ( '' !== newval ) ? newval : default_value; - var unique_id = ( 'generate_secondary_nav_settings' == settings ) ? 'secondary_' : ''; - if ( jQuery( 'style#' + unique_id + id ).length ) { - jQuery( 'style#' + unique_id + id ).html( selector + '{' + property + ':' + newval + ';}' ); - } else { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#' + id ).not( ':last' ).remove(); - }, 1000); - } - - } ); - } ); -} - -/** - * Header background color - * Empty: transparent - */ -generate_colors_live_update( 'top_bar_background_color', '.top-bar', 'background-color', 'transparent' ); - -/** - * Header text color - * Empty: text_color - */ -generate_colors_live_update( 'top_bar_text_color', '.top-bar', 'color', '', 'text_color' ); - -/** - * Header link color - * Empty: link_color - */ -generate_colors_live_update( 'top_bar_link_color', '.top-bar a, .top-bar a:visited', 'color', '', 'link_color' ); - -/** - * Header link color hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'top_bar_link_color_hover', '.top-bar a:hover', 'color', '', 'link_color_hover' ); - - -/** - * Header background color - * Empty: transparent - */ -generate_colors_live_update( 'header_background_color', '.site-header', 'background-color', 'transparent' ); - -/** - * Header text color - * Empty: text_color - */ -generate_colors_live_update( 'header_text_color', '.site-header', 'color', '', 'text_color' ); - -/** - * Header link color - * Empty: link_color - */ -generate_colors_live_update( 'header_link_color', '.site-header a.header-link, .site-header a.header-link:visited', 'color', '', 'link_color' ); - -/** - * Header link color hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'header_link_hover_color', '.site-header a.header-link:hover', 'color', '', 'link_color_hover' ); - -/** - * Site title color - * Empty: link_color - */ -generate_colors_live_update( 'site_title_color', '.main-title a,.main-title a:hover,.main-title a:visited,.header-wrap .navigation-stick .main-title a, .header-wrap .navigation-stick .main-title a:hover, .header-wrap .navigation-stick .main-title a:visited', 'color', '', 'link_color' ); - -/** - * Site tagline color - * Empty: text_color - */ -generate_colors_live_update( 'site_tagline_color', '.site-description', 'color', '', 'text_color' ); - -/** - * Main navigation background - * Empty: transparent - */ -generate_colors_live_update( 'navigation_background_color', '.main-navigation', 'background-color', 'transparent' ); - -/** - * Primary navigation text color - * Empty: link_color - */ -generate_colors_live_update( 'navigation_text_color', - '.main-navigation .main-nav ul li a,\ - .menu-toggle,button.menu-toggle:hover,\ - button.menu-toggle:focus,\ - .main-navigation .mobile-bar-items a,\ - .main-navigation .mobile-bar-items a:hover,\ - .main-navigation .mobile-bar-items a:focus,\ - .main-navigation .menu-bar-items', - 'color', '', 'link_color' -); - -/** - * Primary navigation text color hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'navigation_text_hover_color', - '.navigation-search input[type="search"],\ - .navigation-search input[type="search"]:active,\ - .navigation-search input[type="search"]:focus,\ - .main-navigation .main-nav ul li:hover > a,\ - .main-navigation .main-nav ul li:focus > a,\ - .main-navigation .main-nav ul li.sfHover > a,\ - .main-navigation .menu-bar-item:hover a', - 'color', '', 'link_color_hover' -); - -/** - * Primary navigation menu item hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'navigation_background_hover_color', - '.navigation-search input[type="search"],\ - .navigation-search input[type="search"]:focus,\ - .main-navigation .main-nav ul li:hover > a,\ - .main-navigation .main-nav ul li:focus > a,\ - .main-navigation .main-nav ul li.sfHover > a,\ - .main-navigation .menu-bar-item:hover a', - 'background-color', 'transparent' -); - -/** - * Primary sub-navigation color - * Empty: transparent - */ -generate_colors_live_update( 'subnavigation_background_color', '.main-navigation ul ul', 'background-color', 'transparent' ); - -/** - * Primary sub-navigation text color - * Empty: link_color - */ -generate_colors_live_update( 'subnavigation_text_color', '.main-navigation .main-nav ul ul li a', 'color', 'link_color' ); - -/** - * Primary sub-navigation hover - */ -var subnavigation_hover = '.main-navigation .main-nav ul ul li:hover > a, \ - .main-navigation .main-nav ul ul li:focus > a, \ - .main-navigation .main-nav ul ul li.sfHover > a'; - -/** - * Primary sub-navigation text hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'subnavigation_text_hover_color', subnavigation_hover, 'color', '', 'link_color_hover' ); - -/** - * Primary sub-navigation background hover - * Empty: transparent - */ -generate_colors_live_update( 'subnavigation_background_hover_color', subnavigation_hover, 'background-color', 'transparent' ); - -/** - * Navigation current selectors - */ -var navigation_current = '.main-navigation .main-nav ul li[class*="current-menu-"] > a, \ - .main-navigation .main-nav ul li[class*="current-menu-"]:hover > a, \ - .main-navigation .main-nav ul li[class*="current-menu-"].sfHover > a'; - -/** - * Primary navigation current text - * Empty: link_color - */ -generate_colors_live_update( 'navigation_text_current_color', navigation_current, 'color', '', 'link_color' ); - -/** - * Primary navigation current text - * Empty: transparent - */ -generate_colors_live_update( 'navigation_background_current_color', navigation_current, 'background-color', 'transparent' ); - -/** - * Primary sub-navigation current selectors - */ -var subnavigation_current = '.main-navigation .main-nav ul ul li[class*="current-menu-"] > a,\ - .main-navigation .main-nav ul ul li[class*="current-menu-"]:hover > a, \ - .main-navigation .main-nav ul ul li[class*="current-menu-"].sfHover > a'; - -/** - * Primary sub-navigation current text - * Empty: link_color - */ -generate_colors_live_update( 'subnavigation_text_current_color', subnavigation_current, 'color', '', 'link_color' ); - -/** - * Primary navigation current item background - * Empty: transparent - */ -generate_colors_live_update( 'subnavigation_background_current_color', subnavigation_current, 'background-color', 'transparent' ); - -/** - * Secondary navigation background - * Empty: transparent - */ -generate_colors_live_update( 'navigation_background_color', '.secondary-navigation', 'background-color', 'transparent', '', 'generate_secondary_nav_settings' ); - -/** - * Secondary navigation text color - * Empty: link_color - */ -generate_colors_live_update( 'navigation_text_color', - '.secondary-navigation .main-nav ul li a,\ - .secondary-navigation .menu-toggle,\ - button.secondary-menu-toggle:hover,\ - button.secondary-menu-toggle:focus, \ - .secondary-navigation .top-bar, \ - .secondary-navigation .top-bar a,\ - .secondary-menu-bar-items,\ - .secondary-menu-bar-items .menu-bar-item > a', - 'color', '', 'link_color', 'generate_secondary_nav_settings' -); - -/** - * Navigation search - */ -wp.customize( 'generate_settings[navigation_search_background_color]', function( value ) { - value.bind( function( newval ) { - if ( jQuery( 'style#navigation_search_background_color' ).length ) { - jQuery( 'style#navigation_search_background_color' ).html( '.navigation-search input[type="search"],.navigation-search input[type="search"]:active, .navigation-search input[type="search"]:focus, .main-navigation .main-nav ul li.search-item.active > a, .main-navigation .menu-bar-items .search-item.active > a{background-color:' + newval + ';}' ); - } else { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#navigation_search_background_color' ).not( ':last' ).remove(); - }, 1000); - } - - if ( jQuery( 'style#navigation_search_background_opacity' ).length ) { - if ( newval ) { - jQuery( 'style#navigation_search_background_opacity' ).html( '.navigation-search input{opacity: 1;}' ); - } else { - jQuery( 'style#navigation_search_background_opacity' ).html( '.navigation-search input{opacity: 0.9;}' ); - } - } else { - if ( newval ) { - jQuery( 'head' ).append( '' ); - } - - setTimeout(function() { - jQuery( 'style#navigation_search_background_opacity' ).not( ':last' ).remove(); - }, 1000); - } - } ); -} ); - -generate_colors_live_update( 'navigation_search_text_color', '.navigation-search input[type="search"],.navigation-search input[type="search"]:active, .navigation-search input[type="search"]:focus, .main-navigation .main-nav ul li.search-item.active > a, .main-navigation .menu-bar-items .search-item.active > a', 'color', '' ); - -/** - * Secondary navigation text color hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'navigation_text_hover_color', - '.secondary-navigation .main-nav ul li:hover > a, \ - .secondary-navigation .main-nav ul li:focus > a, \ - .secondary-navigation .main-nav ul li.sfHover > a,\ - .secondary-menu-bar-items .menu-bar-item:hover > a', - 'color', '', 'link_color_hover', 'generate_secondary_nav_settings' -); - -/** - * Secondary navigation menu item hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'navigation_background_hover_color', - '.secondary-navigation .main-nav ul li:hover > a, \ - .secondary-navigation .main-nav ul li:focus > a, \ - .secondary-navigation .main-nav ul li.sfHover > a, \ - .secondary-menu-bar-items .menu-bar-item:hover > a', - 'background-color', 'transparent', '', 'generate_secondary_nav_settings' -); - -/** - * Secondary navigation top bar link hover - */ -wp.customize( 'generate_secondary_nav_settings[navigation_background_hover_color]', function( value ) { - value.bind( function( newval ) { - if ( jQuery( 'style#secondary_nav_top_bar_hover' ).length ) { - jQuery( 'style#secondary_nav_top_bar_hover' ).html( '.secondary-navigation .top-bar a:hover,.secondary-navigation .top-bar a:focus{color:' + newval + ';}' ); - } else { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#secondary_nav_top_bar_hover' ).not( ':last' ).remove(); - }, 1000); - } - } ); -} ); - -generate_colors_live_update( 'navigation_top_bar_hover_color', - '.secondary-navigation .top-bar a:hover, \ - .secondary-navigation .top-bar a:focus', - 'color', 'transparent', '', 'generate_secondary_nav_settings' -); - -/** - * Secondary sub-navigation color - * Empty: transparent - */ -generate_colors_live_update( 'subnavigation_background_color', '.secondary-navigation ul ul', 'background-color', 'transparent', '', 'generate_secondary_nav_settings' ); - -/** - * Secondary sub-navigation text color - * Empty: link_color - */ -generate_colors_live_update( 'subnavigation_text_color', '.secondary-navigation .main-nav ul ul li a', 'color', '', 'link_color', 'generate_secondary_nav_settings' ); - -/** - * Secondary sub-navigation hover - */ -var secondary_subnavigation_hover = '.secondary-navigation .main-nav ul ul li > a:hover, \ - .secondary-navigation .main-nav ul ul li:focus > a, \ - .secondary-navigation .main-nav ul ul li.sfHover > a'; - -/** - * Secondary sub-navigation text hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'subnavigation_text_hover_color', secondary_subnavigation_hover, 'color', '', 'link_color_hover', 'generate_secondary_nav_settings' ); - -/** - * Secondary sub-navigation background hover - * Empty: transparent - */ -generate_colors_live_update( 'subnavigation_background_hover_color', secondary_subnavigation_hover, 'background-color', 'transparent', '', 'generate_secondary_nav_settings' ); - -/** - * Secondary navigation current selectors - */ -var secondary_navigation_current = '.secondary-navigation .main-nav ul li[class*="current-menu-"] > a, \ - .secondary-navigation .main-nav ul li[class*="current-menu-"]:hover > a, \ - .secondary-navigation .main-nav ul li[class*="current-menu-"].sfHover > a'; - -/** - * Secondary navigation current text - * Empty: link_color - */ -generate_colors_live_update( 'navigation_text_current_color', secondary_navigation_current, 'color', '', 'link_color', 'generate_secondary_nav_settings' ); - -/** - * Secondary navigation current text - * Empty: transparent - */ -generate_colors_live_update( 'navigation_background_current_color', secondary_navigation_current, 'background-color', 'transparent', '', 'generate_secondary_nav_settings' ); - -/** - * Secondary sub-navigation current selectors - */ -var secondary_subnavigation_current = '.secondary-navigation .main-nav ul ul li[class*="current-menu-"] > a,\ - .secondary-navigation .main-nav ul ul li[class*="current-menu-"]:hover > a, \ - .secondary-navigation .main-nav ul ul li[class*="current-menu-"].sfHover > a'; - -/** - * Secondary sub-navigation current text - * Empty: link_color - */ -generate_colors_live_update( 'subnavigation_text_current_color', secondary_subnavigation_current, 'color', '', 'link_color', 'generate_secondary_nav_settings' ); - -/** - * Primary navigation current item background - * Empty: transparent - */ -generate_colors_live_update( 'subnavigation_background_current_color', secondary_subnavigation_current, 'background-color', 'transparent', '', 'generate_secondary_nav_settings' ); - -/** - * Content selectors - */ -var content = '.separate-containers .inside-article,\ - .separate-containers .comments-area,\ - .separate-containers .page-header,\ - .one-container .container,\ - .separate-containers .paging-navigation,\ - .inside-page-header'; - -/** - * Content background - * Empty: transparent - */ -generate_colors_live_update( 'content_background_color', content, 'background-color', 'transparent' ); - -/** - * Content text color - * Empty: text_color - */ -generate_colors_live_update( 'content_text_color', content, 'color', '', 'text_color' ); - -/** - * Content links - * Empty: link_color - */ -generate_colors_live_update( 'content_link_color', - '.inside-article a:not(.button):not(.wp-block-button__link)[data-content-link-color=true], \ - .inside-article a:not(.button):not(.wp-block-button__link)[data-content-link-color=true]:visited,\ - .paging-navigation a,\ - .paging-navigation a:visited,\ - .comments-area a,\ - .comments-area a:visited,\ - .page-header a,\ - .page-header a:visited', - 'color', '', 'link_color' -); - -/** - * Content links on hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'content_link_hover_color', - '.inside-article a:not(.button):not(.wp-block-button__link)[data-content-link-color=true]:hover,\ - .paging-navigation a:hover,\ - .comments-area a:hover,\ - .page-header a:hover', - 'color', '', 'link_color_hover' -); - -generate_colors_live_update( 'content_title_color', '.entry-header h1,.page-header h1', 'color', 'inherit', 'text_color' ); -generate_colors_live_update( 'blog_post_title_color', '.entry-title a,.entry-title a:visited', 'color', '', 'link_color' ); -generate_colors_live_update( 'blog_post_title_hover_color', '.entry-title a:hover', 'color', '', 'link_color_hover' ); -generate_colors_live_update( 'entry_meta_text_color', '.entry-meta', 'color', '', 'text_color' ); -generate_colors_live_update( 'entry_meta_link_color', '.entry-meta a, .entry-meta a:visited', 'color', '', 'link_color' ); -generate_colors_live_update( 'entry_meta_link_color_hover', '.entry-meta a:hover', 'color', '', 'link_color_hover' ); -generate_colors_live_update( 'h1_color', 'h1', 'color', '', 'text_color' ); -generate_colors_live_update( 'h2_color', 'h2', 'color', '', 'text_color' ); -generate_colors_live_update( 'h3_color', 'h3', 'color', '', 'text_color' ); -generate_colors_live_update( 'h4_color', 'h4', 'color', '', 'text_color' ); -generate_colors_live_update( 'h5_color', 'h5', 'color', '', 'text_color' ); -generate_colors_live_update( 'sidebar_widget_background_color', '.sidebar .widget', 'background-color', 'transparent' ); -generate_colors_live_update( 'sidebar_widget_text_color', '.sidebar .widget', 'color', '', 'text_color' ); -generate_colors_live_update( 'sidebar_widget_link_color', '.sidebar .widget a, .sidebar .widget a:visited', 'color', '', 'link_color' ); -generate_colors_live_update( 'sidebar_widget_link_hover_color', '.sidebar .widget a:hover', 'color', '', 'link_color_hover' ); -generate_colors_live_update( 'sidebar_widget_title_color', '.sidebar .widget .widget-title', 'color', '', 'text_color' ); -generate_colors_live_update( 'footer_widget_background_color', '.footer-widgets', 'background-color', 'transparent' ); -generate_colors_live_update( 'footer_widget_text_color', '.footer-widgets', 'color', '', 'text_color' ); -generate_colors_live_update( 'footer_widget_link_color', '.footer-widgets a, .footer-widgets a:visited', 'color', '', 'link_color' ); -generate_colors_live_update( 'footer_widget_link_hover_color', '.footer-widgets a:hover', 'color', '', 'link_color_hover' ); -generate_colors_live_update( 'footer_widget_title_color', '.footer-widgets .widget-title', 'color', '', 'text_color' ); -generate_colors_live_update( 'footer_background_color', '.site-info', 'background-color', 'transparent' ); -generate_colors_live_update( 'footer_text_color', '.site-info', 'color', '', 'text_color' ); -generate_colors_live_update( 'footer_link_color', '.site-info a, .site-info a:visited', 'color', '', 'link_color' ); -generate_colors_live_update( 'footer_link_hover_color', '.site-info a:hover', 'color', '', 'link_color_hover' ); - -/** - * Form selectors - */ -var forms = 'input[type="text"], \ - input[type="email"], \ - input[type="url"], \ - input[type="password"], \ - input[type="search"], \ - input[type="number"], \ - input[type="tel"], \ - textarea, \ - select'; - -/** - * Form background - * Empty: inherit - */ -generate_colors_live_update( 'form_background_color', forms, 'background-color', 'inherit' ); - -/** - * Border color - * Empty: inherit - */ -generate_colors_live_update( 'form_border_color', forms, 'border-color' ); - -/** - * Form text color - * Empty: text_color - */ -generate_colors_live_update( 'form_text_color', forms, 'color', '', 'text_color' ); - -/** - * Form background on focus selectors - * Empty: inherit - */ -var forms_focus = 'input[type="text"]:focus, \ - input[type="email"]:focus, \ - input[type="url"]:focus, \ - input[type="password"]:focus, \ - input[type="search"]:focus,\ - input[type="number"]:focus,\ - input[type="tel"]:focus, \ - textarea:focus, \ - select:focus'; - -/** - * Form background color on focus - * Empty: initial - */ -generate_colors_live_update( 'form_background_color_focus', forms_focus, 'background-color' ); - -/** - * Form text color on focus - * Empty: initial - */ -generate_colors_live_update( 'form_text_color_focus', forms_focus, 'color' ); - -/** - * Form border color on focus - * Empty: initial - */ -generate_colors_live_update( 'form_border_color_focus', forms_focus, 'border-color' ); - -/** - * Button selectors - */ -var button = 'button, \ - html input[type="button"], \ - input[type="reset"], \ - input[type="submit"],\ - a.button,\ - a.button:visited,\ - a.wp-block-button__link:not(.has-background)'; - -/** - * Button background - * Empty: initial - */ -generate_colors_live_update( 'form_button_background_color', button, 'background-color' ); - -/** - * Button text - * Empty: initial - */ -generate_colors_live_update( 'form_button_text_color', button, 'color' ); - -/** - * Button on hover/focus selectors - * Empty: initial - */ -var button_hover = 'button:hover, \ - html input[type="button"]:hover, \ - input[type="reset"]:hover, \ - input[type="submit"]:hover,\ - a.button:hover,\ - button:focus, \ - html input[type="button"]:focus, \ - input[type="reset"]:focus, \ - input[type="submit"]:focus,\ - a.button:focus,\ - a.wp-block-button__link:not(.has-background):active,\ - a.wp-block-button__link:not(.has-background):focus,\ - a.wp-block-button__link:not(.has-background):hover'; - -/** - * Button color on hover - * Empty: initial - */ -generate_colors_live_update( 'form_button_background_color_hover', button_hover, 'background-color' ); - -/** - * Button text color on hover - * Empty: initial - */ -generate_colors_live_update( 'form_button_text_color_hover', button_hover, 'color' ); - -/** - * Back to top background color - * Empty: transparent - */ -generate_colors_live_update( 'back_to_top_background_color', 'a.generate-back-to-top', 'background-color', 'transparent' ); - -/** - * Back to top text color - * Empty: text_color - */ -generate_colors_live_update( 'back_to_top_text_color', 'a.generate-back-to-top', 'color', '', 'text_color' ); - -/** - * Back to top background color hover - * Empty: transparent - */ -generate_colors_live_update( 'back_to_top_background_color_hover', 'a.generate-back-to-top:hover,a.generate-back-to-top:focus', 'background-color', 'transparent' ); - -/** - * Back to top text color hover - * Empty: text_color - */ -generate_colors_live_update( 'back_to_top_text_color_hover', 'a.generate-back-to-top:hover,a.generate-back-to-top:focus', 'color', '', 'text_color' ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/menu-plus-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/menu-plus-customizer.js deleted file mode 100644 index f74fa31e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/menu-plus-customizer.js +++ /dev/null @@ -1,102 +0,0 @@ -/** - * Main navigation background - * Empty: transparent - */ -generate_colors_live_update( 'slideout_background_color', '.main-navigation.slideout-navigation', 'background-color', '' ); - -/** - * Primary navigation text color - * Empty: link_color - */ -generate_colors_live_update( 'slideout_text_color', '.slideout-navigation.main-navigation .main-nav ul li a, .slideout-navigation a, .slideout-navigation', 'color', '' ); - -/** - * Primary navigation text color hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'slideout_text_hover_color', - '.slideout-navigation.main-navigation .main-nav ul li:hover > a,\ - .slideout-navigation.main-navigation .main-nav ul li:focus > a,\ - .slideout-navigation.main-navigation .main-nav ul li.sfHover > a', - 'color', '' -); - -/** - * Primary navigation menu item hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'slideout_background_hover_color', - '.slideout-navigation.main-navigation .main-nav ul li:hover > a,\ - .slideout-navigation.main-navigation .main-nav ul li:focus > a,\ - .slideout-navigation.main-navigation .main-nav ul li.sfHover > a', - 'background-color', 'transparent' -); - -/** - * Primary sub-navigation color - * Empty: transparent - */ -generate_colors_live_update( 'slideout_submenu_background_color', '.slideout-navigation.main-navigation ul ul', 'background-color', '' ); - -/** - * Primary sub-navigation text color - * Empty: link_color - */ -generate_colors_live_update( 'slideout_submenu_text_color', '.slideout-navigation.main-navigation .main-nav ul ul li a', 'color', '' ); - -/** - * Primary sub-navigation hover - */ -var slideout_submenu_hover = '.slideout-navigation.main-navigation .main-nav ul ul li:hover > a,\ - .slideout-navigation.main-navigation .main-nav ul ul li:focus > a,\ - .slideout-navigation.main-navigation .main-nav ul ul li.sfHover > a'; - -/** - * Primary sub-navigation text hover - * Empty: link_color_hover - */ -generate_colors_live_update( 'slideout_submenu_text_hover_color', slideout_submenu_hover, 'color', '' ); - -/** - * Primary sub-navigation background hover - * Empty: transparent - */ -generate_colors_live_update( 'slideout_submenu_background_hover_color', slideout_submenu_hover, 'background-color', '' ); - -/** - * Navigation current selectors - */ -var slideout_current = '.slideout-navigation.main-navigation .main-nav ul li[class*="current-menu-"] > a,\ - .slideout-navigation.main-navigation .main-nav ul li[class*="current-menu-"] > a:hover,\ - .slideout-navigation.main-navigation .main-nav ul li[class*="current-menu-"].sfHover > a'; - -/** - * Primary navigation current text - * Empty: link_color - */ -generate_colors_live_update( 'slideout_text_current_color', slideout_current, 'color', '' ); - -/** - * Primary navigation current text - * Empty: transparent - */ -generate_colors_live_update( 'slideout_background_current_color', slideout_current, 'background-color' ); - -/** - * Primary sub-navigation current selectors - */ -var slideout_submenu_current = '.slideout-navigation.main-navigation .main-nav ul ul li[class*="current-menu-"] > a,\ - .slideout-navigation.main-navigation .main-nav ul ul li[class*="current-menu-"] > a:hover,\ - .slideout-navigation.main-navigation .main-nav ul ul li[class*="current-menu-"].sfHover > a'; - -/** - * Primary sub-navigation current text - * Empty: link_color - */ -generate_colors_live_update( 'slideout_submenu_text_current_color', slideout_submenu_current, 'color', '' ); - -/** - * Primary navigation current item background - * Empty: transparent - */ -generate_colors_live_update( 'slideout_submenu_background_current_color', slideout_submenu_current, 'background-color' ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/wc-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/wc-customizer.js deleted file mode 100644 index b694f300..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/js/wc-customizer.js +++ /dev/null @@ -1,161 +0,0 @@ -/** - * WooCommerce link color - */ -generate_colors_live_update( 'wc_product_title_color', '.woocommerce ul.products li.product .woocommerce-LoopProduct-link', 'color', '', 'link_color' ); -generate_colors_live_update( 'wc_product_title_color_hover', '.woocommerce ul.products li.product .woocommerce-LoopProduct-link:hover', 'color', '', 'link_color_hover' ); - -/** - * WooCommerce primary button - */ -var wc_button = '.woocommerce #respond input#submit, .woocommerce a.button, .woocommerce button.button, .woocommerce input.button, button, \ - html input[type="button"], \ - input[type="reset"], \ - input[type="submit"],\ - .button,\ - .button:visited'; -generate_colors_live_update( 'form_button_background_color', wc_button, 'background-color' ); -generate_colors_live_update( 'form_button_text_color', wc_button, 'color' ); - -/** - * WooCommerce primary button hover - */ -var wc_button_hover = '.woocommerce #respond input#submit:hover, .woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce input.button:hover,button:hover, \ - html input[type="button"]:hover, \ - input[type="reset"]:hover, \ - input[type="submit"]:hover,\ - .button:hover,\ - button:focus, \ - html input[type="button"]:focus, \ - input[type="reset"]:focus, \ - input[type="submit"]:focus,\ - .button:focus'; -generate_colors_live_update( 'form_button_background_color_hover', wc_button_hover, 'background-color' ); -generate_colors_live_update( 'form_button_text_color_hover', wc_button_hover, 'color' ); - -/** - * WooCommerce alt button - */ -var wc_alt_button = '.woocommerce #respond input#submit.alt, .woocommerce a.button.alt, .woocommerce button.button.alt, .woocommerce input.button.alt'; -generate_colors_live_update( 'wc_alt_button_background', wc_alt_button, 'background-color' ); -generate_colors_live_update( 'wc_alt_button_text', wc_alt_button, 'color' ); - -/** - * WooCommerce alt button hover - */ -var wc_alt_button_hover = '.woocommerce #respond input#submit.alt:hover, .woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover, .woocommerce input.button.alt:hover'; -generate_colors_live_update( 'wc_alt_button_background_hover', wc_alt_button_hover, 'background-color' ); -generate_colors_live_update( 'wc_alt_button_text_hover', wc_alt_button_hover, 'color' ); - -/** - * WooCommerce star ratings - */ -var wc_stars = '.woocommerce .star-rating span:before, .woocommerce .star-rating:before'; -generate_colors_live_update( 'wc_rating_stars', wc_stars, 'color' ); - -/** - * WooCommerce sale sticker - */ -var wc_sale_sticker = '.woocommerce span.onsale'; -generate_colors_live_update( 'wc_sale_sticker_background', wc_sale_sticker, 'background-color' ); -generate_colors_live_update( 'wc_sale_sticker_text', wc_sale_sticker, 'color' ); - -/** - * WooCommerce price - */ -var wc_price = '.woocommerce ul.products li.product .price, .woocommerce div.product p.price'; -generate_colors_live_update( 'wc_price_color', wc_price, 'color' ); - -/** - * WooCommerce product tab text - */ -var wc_product_tab = '.woocommerce div.product .woocommerce-tabs ul.tabs li a'; -generate_colors_live_update( 'wc_product_tab', wc_product_tab, 'color' ); - -/** - * WooCommerce product tab text highlight/active - */ -var wc_product_tab_active = '.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover, .woocommerce div.product .woocommerce-tabs ul.tabs li.active a'; -generate_colors_live_update( 'wc_product_tab_highlight', wc_product_tab_active, 'color' ); - -/** - * WooCommerce success message - */ -var wc_success_message = '.woocommerce-message'; -generate_colors_live_update( 'wc_success_message_background', wc_success_message, 'background-color' ); -generate_colors_live_update( 'wc_success_message_text', wc_success_message + ', div.woocommerce-message a.button, div.woocommerce-message a.button:focus, div.woocommerce-message a.button:hover, div.woocommerce-message a, div.woocommerce-message a:focus, div.woocommerce-message a:hover', 'color' ); - -/** - * WooCommerce info message - */ -var wc_info_message = '.woocommerce-info'; -generate_colors_live_update( 'wc_info_message_background', wc_info_message, 'background-color' ); -generate_colors_live_update( 'wc_info_message_text', wc_info_message + ', div.woocommerce-info a.button, div.woocommerce-info a.button:focus, div.woocommerce-info a.button:hover, div.woocommerce-info a, div.woocommerce-info a:focus, div.woocommerce-info a:hover', 'color' ); - -/** - * WooCommerce error message - */ -var wc_error_message = '.woocommerce-error'; -generate_colors_live_update( 'wc_error_message_background', wc_error_message, 'background-color' ); -generate_colors_live_update( 'wc_error_message_text', wc_error_message + ', div.woocommerce-error a.button, div.woocommerce-error a.button:focus, div.woocommerce-error a.button:hover, div.woocommerce-error a, div.woocommerce-error a:focus, div.woocommerce-error a:hover', 'color' ); - -/** - * Menu Mini Cart - */ -generate_colors_live_update( 'wc_mini_cart_background_color', '#wc-mini-cart', 'background-color' ); -generate_colors_live_update( 'wc_mini_cart_text_color', '#wc-mini-cart,#wc-mini-cart a:not(.button), #wc-mini-cart a.remove', 'color' ); - -generate_colors_live_update( 'wc_mini_cart_button_background', '#wc-mini-cart .button.checkout', 'background-color' ); -generate_colors_live_update( 'wc_mini_cart_button_text', '#wc-mini-cart .button.checkout', 'color' ); - -generate_colors_live_update( 'wc_mini_cart_button_background_hover', '#wc-mini-cart .button.checkout:hover, #wc-mini-cart .button.checkout:focus, #wc-mini-cart .button.checkout:active', 'background-color' ); -generate_colors_live_update( 'wc_mini_cart_button_text_hover', '#wc-mini-cart .button.checkout:hover, #wc-mini-cart .button.checkout:focus, #wc-mini-cart .button.checkout:active', 'color' ); - -/** - * Sticky panel cart button - */ - generate_colors_live_update( 'wc_panel_cart_background_color', '.add-to-cart-panel', 'background-color' ); - generate_colors_live_update( 'wc_panel_cart_text_color', '.add-to-cart-panel, .add-to-cart-panel a:not(.button)', 'color' ); - - generate_colors_live_update( 'wc_panel_cart_button_background', '#wc-sticky-cart-panel .button', 'background-color' ); - generate_colors_live_update( 'wc_panel_cart_button_text', '#wc-sticky-cart-panel .button', 'color' ); - - generate_colors_live_update( 'wc_panel_cart_button_background_hover', '#wc-sticky-cart-panel .button:hover, #wc-sticky-cart-panel .button:focus, #wc-sticky-cart-panel .button:active', 'background-color' ); - generate_colors_live_update( 'wc_panel_cart_button_text_hover', '#wc-sticky-cart-panel .button:hover, #wc-sticky-cart-panel .button:focus, #wc-sticky-cart-panel .button:active', 'color' ); - -/** - * Price slider bar - */ -generate_colors_live_update( 'wc_price_slider_background_color', '.woocommerce .widget_price_filter .price_slider_wrapper .ui-widget-content', 'background-color' ); -generate_colors_live_update( 'wc_price_slider_bar_color', '.woocommerce .widget_price_filter .ui-slider .ui-slider-range, .woocommerce .widget_price_filter .ui-slider .ui-slider-handle', 'background-color' ); - -// Archive product description text -wp.customize( 'generate_settings[text_color]', function( value ) { - value.bind( function( newval ) { - if ( ! wp.customize.value('generate_settings[content_text_color]')() ) { - if ( jQuery( 'style#wc_desc_color' ).length ) { - jQuery( 'style#wc_desc_color' ).html( '.woocommerce-product-details__short-description{color:' + newval + ';}' ); - } else { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#wc_desc_color' ).not( ':last' ).remove(); - }, 1000); - } - } - } ); -} ); - -wp.customize( 'generate_settings[content_text_color]', function( value ) { - value.bind( function( newval ) { - if ( '' == newval ) { - newval = wp.customize.value('generate_settings[text_color]')(); - } - if ( jQuery( 'style#wc_desc_color' ).length ) { - jQuery( 'style#wc_desc_color' ).html( '.woocommerce-product-details__short-description{color:' + newval + ';}' ); - } else { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#wc_desc_color' ).not( ':last' ).remove(); - }, 1000); - } - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/secondary-nav-colors.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/secondary-nav-colors.php deleted file mode 100644 index 7c3ee911..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/secondary-nav-colors.php +++ /dev/null @@ -1,403 +0,0 @@ -get_section( 'secondary_nav_section' ) ) { - return; - } - - // Bail if we don't have our color defaults. - if ( ! function_exists( 'generate_secondary_nav_get_defaults' ) ) { - return; - } - - // Add our controls. - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - // Get our defaults. - $defaults = generate_secondary_nav_get_defaults(); - - // Add control types so controls can be built using JS. - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Alpha_Color_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Title_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Get our palettes. - $palettes = generate_get_default_color_palettes(); - - // Add Secondary Navigation section. - $wp_customize->add_section( - 'secondary_navigation_color_section', - array( - 'title' => __( 'Secondary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 71, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_secondary_navigation_color_shortcuts', - array( - 'section' => 'secondary_navigation_color_section', - 'element' => __( 'Secondary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'secondary_nav_section', - 'typography' => 'secondary_font_section', - 'backgrounds' => 'secondary_bg_images_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_secondary_navigation_items', - array( - 'section' => 'secondary_navigation_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Parent Items', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Background. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[navigation_background_color]', - array( - 'default' => $defaults['navigation_background_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'secondary_navigation_background_color', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[navigation_background_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[navigation_text_color]', - array( - 'default' => $defaults['navigation_text_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'secondary_navigation_text_color', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[navigation_text_color]', - ) - ) - ); - - // Background hover. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[navigation_background_hover_color]', - array( - 'default' => $defaults['navigation_background_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'secondary_navigation_background_hover_color', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[navigation_background_hover_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text hover. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[navigation_text_hover_color]', - array( - 'default' => $defaults['navigation_text_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'secondary_navigation_text_hover_color', - array( - 'label' => __( 'Text Hover', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[navigation_text_hover_color]', - ) - ) - ); - - // Background current. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[navigation_background_current_color]', - array( - 'default' => $defaults['navigation_background_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'secondary_navigation_background_current_color', - array( - 'label' => __( 'Background Current', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[navigation_background_current_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text current. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[navigation_text_current_color]', - array( - 'default' => $defaults['navigation_text_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'secondary_navigation_text_current_color', - array( - 'label' => __( 'Text Current', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[navigation_text_current_color]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_secondary_navigation_sub_menu_items', - array( - 'section' => 'secondary_navigation_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Sub-Menu Items', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Background. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[subnavigation_background_color]', - array( - 'default' => $defaults['subnavigation_background_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'secondary_subnavigation_background_color', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[subnavigation_background_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[subnavigation_text_color]', - array( - 'default' => $defaults['subnavigation_text_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'secondary_subnavigation_text_color', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[subnavigation_text_color]', - ) - ) - ); - - // Background hover. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[subnavigation_background_hover_color]', - array( - 'default' => $defaults['subnavigation_background_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'secondary_subnavigation_background_hover_color', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[subnavigation_background_hover_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text hover. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[subnavigation_text_hover_color]', - array( - 'default' => $defaults['subnavigation_text_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'secondary_subnavigation_text_hover_color', - array( - 'label' => __( 'Text Hover', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[subnavigation_text_hover_color]', - ) - ) - ); - - // Background current. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[subnavigation_background_current_color]', - array( - 'default' => $defaults['subnavigation_background_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'secondary_subnavigation_background_current_color', - array( - 'label' => __( 'Background Current', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[subnavigation_background_current_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text current. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[subnavigation_text_current_color]', - array( - 'default' => $defaults['subnavigation_text_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'secondary_subnavigation_text_current_color', - array( - 'label' => __( 'Text Current', 'gp-premium' ), - 'section' => 'secondary_navigation_color_section', - 'settings' => 'generate_secondary_nav_settings[subnavigation_text_current_color]', - ) - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/slideout-nav-colors.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/slideout-nav-colors.php deleted file mode 100644 index f479dd6e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/slideout-nav-colors.php +++ /dev/null @@ -1,400 +0,0 @@ -get_section( 'menu_plus_slideout_menu' ) ) { - return; - } - - // Bail if we don't have our color defaults. - if ( ! function_exists( 'generate_get_color_defaults' ) ) { - return; - } - - // Add our controls. - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - // Get our defaults. - $defaults = generate_get_color_defaults(); - - // Add control types so controls can be built using JS. - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Alpha_Color_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Get our palettes. - $palettes = generate_get_default_color_palettes(); - - // Add Secondary Navigation section. - $wp_customize->add_section( - 'slideout_color_section', - array( - 'title' => __( 'Off Canvas Panel', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 73, - 'panel' => 'generate_colors_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_off_canvas_color_shortcuts', - array( - 'section' => 'slideout_color_section', - 'element' => __( 'Off Canvas Panel', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'menu_plus_slideout_menu', - 'typography' => 'generate_slideout_typography', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_slideout_navigation_items', - array( - 'section' => 'slideout_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Parent Menu Items', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Background. - $wp_customize->add_setting( - 'generate_settings[slideout_background_color]', - array( - 'default' => $defaults['slideout_background_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[slideout_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_background_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text. - $wp_customize->add_setting( - 'generate_settings[slideout_text_color]', - array( - 'default' => $defaults['slideout_text_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[slideout_text_color]', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_text_color]', - ) - ) - ); - - // Background hover. - $wp_customize->add_setting( - 'generate_settings[slideout_background_hover_color]', - array( - 'default' => $defaults['slideout_background_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[slideout_background_hover_color]', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_background_hover_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text hover. - $wp_customize->add_setting( - 'generate_settings[slideout_text_hover_color]', - array( - 'default' => $defaults['slideout_text_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[slideout_text_hover_color]', - array( - 'label' => __( 'Text Hover', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_text_hover_color]', - ) - ) - ); - - // Background current. - $wp_customize->add_setting( - 'generate_settings[slideout_background_current_color]', - array( - 'default' => $defaults['slideout_background_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[slideout_background_current_color]', - array( - 'label' => __( 'Background Current', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_background_current_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text current. - $wp_customize->add_setting( - 'generate_settings[slideout_text_current_color]', - array( - 'default' => $defaults['slideout_text_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[slideout_text_current_color]', - array( - 'label' => __( 'Text Current', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_text_current_color]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_slideout_navigation_sub_menu_items', - array( - 'section' => 'slideout_color_section', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Sub-Menu Items', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - // Background. - $wp_customize->add_setting( - 'generate_settings[slideout_submenu_background_color]', - array( - 'default' => $defaults['slideout_submenu_background_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[slideout_submenu_background_color]', - array( - 'label' => __( 'Background', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_submenu_background_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text. - $wp_customize->add_setting( - 'generate_settings[slideout_submenu_text_color]', - array( - 'default' => $defaults['slideout_submenu_text_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[slideout_submenu_text_color]', - array( - 'label' => __( 'Text', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_submenu_text_color]', - ) - ) - ); - - // Background hover. - $wp_customize->add_setting( - 'generate_settings[slideout_submenu_background_hover_color]', - array( - 'default' => $defaults['slideout_submenu_background_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[slideout_submenu_background_hover_color]', - array( - 'label' => __( 'Background Hover', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_submenu_background_hover_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text hover. - $wp_customize->add_setting( - 'generate_settings[slideout_submenu_text_hover_color]', - array( - 'default' => $defaults['slideout_submenu_text_hover_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[slideout_submenu_text_hover_color]', - array( - 'label' => __( 'Text Hover', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_submenu_text_hover_color]', - ) - ) - ); - - // Background current. - $wp_customize->add_setting( - 'generate_settings[slideout_submenu_background_current_color]', - array( - 'default' => $defaults['slideout_submenu_background_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[slideout_submenu_background_current_color]', - array( - 'label' => __( 'Background Current', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_submenu_background_current_color]', - 'palette' => $palettes, - ) - ) - ); - - // Text current. - $wp_customize->add_setting( - 'generate_settings[slideout_submenu_text_current_color]', - array( - 'default' => $defaults['slideout_submenu_text_current_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[slideout_submenu_text_current_color]', - array( - 'label' => __( 'Text Current', 'gp-premium' ), - 'section' => 'slideout_color_section', - 'settings' => 'generate_settings[slideout_submenu_text_current_color]', - ) - ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/woocommerce-colors.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/woocommerce-colors.php deleted file mode 100644 index 6c453815..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/functions/woocommerce-colors.php +++ /dev/null @@ -1,911 +0,0 @@ -get_section( 'generate_woocommerce_colors' ) ) { - return; - } - - if ( ! function_exists( 'generate_get_color_defaults' ) ) { - return; - } - - // Add our controls. - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - // Get our defaults. - $defaults = generate_get_color_defaults(); - - // Add control types so controls can be built using JS. - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Alpha_Color_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Title_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Information_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Get our palettes. - $palettes = generate_get_default_color_palettes(); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_woocommerce_color_shortcuts', - array( - 'section' => 'generate_woocommerce_colors', - 'element' => __( 'WooCommerce', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_woocommerce_layout', - 'typography' => 'generate_woocommerce_typography', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_button_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Buttons', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_woocommerce_primary_button_message', - array( - 'section' => 'generate_woocommerce_colors', - 'label' => __( 'Primary Button Colors', 'gp-premium' ), - 'description' => __( 'Primary button colors can be set here.', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_alt_button_background]', - array( - 'default' => $defaults['wc_alt_button_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_alt_button_background]', - array( - 'label' => __( 'Alt Button Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_alt_button_background]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_alt_button_background_hover]', - array( - 'default' => $defaults['wc_alt_button_background_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_alt_button_background_hover]', - array( - 'label' => __( 'Alt Button Background Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_alt_button_background_hover]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_alt_button_text]', - array( - 'default' => $defaults['wc_alt_button_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_alt_button_text]', - array( - 'label' => __( 'Alt Button Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_alt_button_text]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_alt_button_text_hover]', - array( - 'default' => $defaults['wc_alt_button_text_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_alt_button_text_hover]', - array( - 'label' => __( 'Alt Button Text Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_alt_button_text_hover]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_product_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Products', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_product_title_color]', - array( - 'default' => $defaults['wc_product_title_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_product_title_color]', - array( - 'label' => __( 'Product Title', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_product_title_color]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_product_title_color_hover]', - array( - 'default' => $defaults['wc_product_title_color_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_product_title_color_hover]', - array( - 'label' => __( 'Product Title Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_product_title_color_hover]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_rating_stars]', - array( - 'default' => $defaults['wc_rating_stars'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => '', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_rating_stars]', - array( - 'label' => __( 'Star Ratings', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_rating_stars]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_sale_sticker_background]', - array( - 'default' => $defaults['wc_sale_sticker_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_sale_sticker_background]', - array( - 'label' => __( 'Sale Sticker Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_sale_sticker_background]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_sale_sticker_text]', - array( - 'default' => $defaults['wc_sale_sticker_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_sale_sticker_text]', - array( - 'label' => __( 'Sale Sticker Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_sale_sticker_text]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_price_color]', - array( - 'default' => $defaults['wc_price_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_price_color]', - array( - 'label' => __( 'Price', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_price_color]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_panel_cart_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Sticky Panel Cart', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_panel_cart_background_color]', - array( - 'default' => $defaults['wc_panel_cart_background_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_panel_cart_background_color]', - array( - 'label' => __( 'Background Color', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_panel_cart_background_color]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_panel_cart_text_color]', - array( - 'default' => $defaults['wc_panel_cart_text_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_panel_cart_text_color]', - array( - 'label' => __( 'Text Color', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_panel_cart_text_color]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_panel_cart_button_background]', - array( - 'default' => $defaults['wc_panel_cart_button_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_panel_cart_button_background]', - array( - 'label' => __( 'Button Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_panel_cart_button_background]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_panel_cart_button_background_hover]', - array( - 'default' => $defaults['wc_panel_cart_button_background_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_panel_cart_button_background_hover]', - array( - 'label' => __( 'Button Background Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_panel_cart_button_background_hover]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_panel_cart_button_text]', - array( - 'default' => $defaults['wc_panel_cart_button_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_panel_cart_button_text]', - array( - 'label' => __( 'Button Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_panel_cart_button_text]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_panel_cart_button_text_hover]', - array( - 'default' => $defaults['wc_panel_cart_button_text_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_panel_cart_button_text_hover]', - array( - 'label' => __( 'Button Text Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_panel_cart_button_text_hover]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_mini_cart_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Menu Mini Cart', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_mini_cart_background_color]', - array( - 'default' => $defaults['wc_mini_cart_background_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_mini_cart_background_color]', - array( - 'label' => __( 'Cart Background Color', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_mini_cart_background_color]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_mini_cart_text_color]', - array( - 'default' => $defaults['wc_mini_cart_text_color'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_mini_cart_text_color]', - array( - 'label' => __( 'Cart Text Color', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_mini_cart_text_color]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_mini_cart_button_background]', - array( - 'default' => $defaults['wc_mini_cart_button_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_mini_cart_button_background]', - array( - 'label' => __( 'Button Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_mini_cart_button_background]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_mini_cart_button_background_hover]', - array( - 'default' => $defaults['wc_mini_cart_button_background_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_mini_cart_button_background_hover]', - array( - 'label' => __( 'Button Background Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_mini_cart_button_background_hover]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_mini_cart_button_text]', - array( - 'default' => $defaults['wc_mini_cart_button_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_mini_cart_button_text]', - array( - 'label' => __( 'Button Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_mini_cart_button_text]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_mini_cart_button_text_hover]', - array( - 'default' => $defaults['wc_mini_cart_button_text_hover'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_mini_cart_button_text_hover]', - array( - 'label' => __( 'Button Text Hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_mini_cart_button_text_hover]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_price_slider_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Price Slider Widget', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_price_slider_background_color]', - array( - 'default' => $defaults['wc_price_slider_background_color'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_price_slider_background_color]', - array( - 'label' => __( 'Slider Background Color', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_price_slider_background_color]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_price_slider_bar_color]', - array( - 'default' => $defaults['wc_price_slider_bar_color'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_price_slider_bar_color]', - array( - 'label' => __( 'Slider Bar Color', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_price_slider_bar_color]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_product_tabs_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Product Tabs', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_product_tab]', - array( - 'default' => $defaults['wc_product_tab'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_product_tab]', - array( - 'label' => __( 'Product Tab Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_product_tab]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_product_tab_highlight]', - array( - 'default' => $defaults['wc_product_tab_highlight'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_product_tab_highlight]', - array( - 'label' => __( 'Product Tab Active', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_product_tab_highlight]', - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_messages_title', - array( - 'section' => 'generate_woocommerce_colors', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Messages', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_success_message_background]', - array( - 'default' => $defaults['wc_success_message_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_success_message_background]', - array( - 'label' => __( 'Success Message Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_success_message_background]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_success_message_text]', - array( - 'default' => $defaults['wc_success_message_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_success_message_text]', - array( - 'label' => __( 'Success Message Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_success_message_text]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_info_message_background]', - array( - 'default' => $defaults['wc_info_message_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_info_message_background]', - array( - 'label' => __( 'Info Message Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_info_message_background]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_info_message_text]', - array( - 'default' => $defaults['wc_info_message_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_info_message_text]', - array( - 'label' => __( 'Info Message Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_info_message_text]', - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_error_message_background]', - array( - 'default' => $defaults['wc_error_message_background'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'transport' => 'postMessage', - 'sanitize_callback' => 'generate_premium_sanitize_rgba', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Alpha_Color_Customize_Control( - $wp_customize, - 'generate_settings[wc_error_message_background]', - array( - 'label' => __( 'Error Message Background', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_error_message_background]', - 'palette' => $palettes, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[wc_error_message_text]', - array( - 'default' => $defaults['wc_error_message_text'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_hex_color', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new WP_Customize_Color_Control( - $wp_customize, - 'generate_settings[wc_error_message_text]', - array( - 'label' => __( 'Error Message Text', 'gp-premium' ), - 'section' => 'generate_woocommerce_colors', - 'settings' => 'generate_settings[wc_error_message_text]', - ) - ) - ); - - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/generate-colors.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/generate-colors.php deleted file mode 100644 index a90e5c4c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/colors/generate-colors.php +++ /dev/null @@ -1,20 +0,0 @@ -register_control_type( 'GeneratePress_Copyright_Customize_Control' ); - } - - $wp_customize->add_setting( - 'generate_copyright', - array( - 'default' => '', - 'type' => 'theme_mod', - 'sanitize_callback' => 'wp_kses_post', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Copyright_Customize_Control( - $wp_customize, - 'generate_copyright', - array( - 'label' => __( 'Copyright', 'gp-premium' ), - 'section' => 'generate_layout_footer', - 'settings' => 'generate_copyright', - 'priority' => 500, - ) - ) - ); - - // Initiate selective refresh. - if ( isset( $wp_customize->selective_refresh ) ) { - $wp_customize->selective_refresh->add_partial( - 'generate_copyright', - array( - 'selector' => '.copyright-bar', - 'settings' => array( 'generate_copyright' ), - 'render_callback' => 'generate_copyright_selective_refresh', - ) - ); - } - } -} - -if ( ! function_exists( 'generate_copyright_selective_refresh' ) ) { - /** - * Return our copyright on selective refresh - */ - function generate_copyright_selective_refresh() { - $options = array( - '%current_year%', - '%copy%', - ); - - $replace = array( - date( 'Y' ), // phpcs:ignore -- prefer date(). - '©', - ); - - $new_copyright = get_theme_mod( 'generate_copyright' ); - $new_copyright = str_replace( $options, $replace, get_theme_mod( 'generate_copyright' ) ); - - return do_shortcode( $new_copyright ); - } -} - -if ( ! function_exists( 'generate_copyright_remove_default' ) ) { - add_action( 'wp', 'generate_copyright_remove_default' ); - /** - * Remove the default copyright. - * - * @since 0.1 - * @deprecated GP 1.3.42 - */ - function generate_copyright_remove_default() { - // As of 1.3.42, we no longer need to do this. - // We use a nice little filter instead. - if ( ! function_exists( 'generate_add_login_attribution' ) ) { - return; - } - - if ( get_theme_mod( 'generate_copyright' ) && '' !== get_theme_mod( 'generate_copyright' ) ) { - remove_action( 'generate_credits', 'generate_add_footer_info' ); - remove_action( 'generate_copyright_line', 'generate_add_login_attribution' ); - } - } -} - -if ( ! function_exists( 'generate_copyright_add_custom' ) ) { - add_action( 'generate_credits', 'generate_copyright_add_custom' ); - /** - * Add the custom copyright. - * - * @since 0.1 - * @deprecated GP 1.3.42 - */ - function generate_copyright_add_custom() { - // As of 1.3.42, we no longer need to do this. - // We use a nice little filter instead. - if ( ! function_exists( 'generate_add_login_attribution' ) ) { - return; - } - - $options = array( - '%current_year%', - '%copy%', - ); - - $replace = array( - date( 'Y' ), // phpcs:ignore -- prefer date(). - '©', - ); - - $new_copyright = get_theme_mod( 'generate_copyright' ); - $new_copyright = str_replace( $options, $replace, get_theme_mod( 'generate_copyright' ) ); - - if ( get_theme_mod( 'generate_copyright' ) && '' !== get_theme_mod( 'generate_copyright' ) ) { - echo do_shortcode( $new_copyright ); - } - } -} - -if ( ! function_exists( 'generate_apply_custom_copyright' ) ) { - add_filter( 'generate_copyright', 'generate_apply_custom_copyright' ); - /** - * Add the custom copyright - * - * @since 1.2.92 - * @param string $copyright The copyright value. - */ - function generate_apply_custom_copyright( $copyright ) { - // This will only work if GP >= 1.3.42 and the below function doesn't exist. - if ( function_exists( 'generate_add_login_attribution' ) ) { - return; - } - - $options = array( - '%current_year%', - '%copy%', - ); - - $replace = array( - date( 'Y' ), // phpcs:ignore -- prefer date(). - '©', - ); - - $new_copyright = get_theme_mod( 'generate_copyright' ); - $new_copyright = str_replace( $options, $replace, get_theme_mod( 'generate_copyright' ) ); - - if ( get_theme_mod( 'generate_copyright' ) && '' !== get_theme_mod( 'generate_copyright' ) ) { - return do_shortcode( $new_copyright ); - } - - return $copyright; - - } -} - -if ( ! function_exists( 'generate_copyright_customizer_live_preview' ) ) { - add_action( 'customize_preview_init', 'generate_copyright_customizer_live_preview' ); - /** - * Add our live preview - */ - function generate_copyright_customizer_live_preview() { - wp_enqueue_script( - 'generate-copyright-customizer', - plugin_dir_url( __FILE__ ) . 'js/customizer.js', - array( 'jquery', 'customize-preview' ), - GENERATE_COPYRIGHT_VERSION, - true - ); - } -} - -if ( ! function_exists( 'generate_update_copyright' ) ) { - add_action( 'admin_init', 'generate_update_copyright' ); - /** - * Our copyright use to have it's own setting - * If we have the old setting, move it into our theme_mod - */ - function generate_update_copyright() { - // If we already have a custom logo, bail. - if ( get_theme_mod( 'generate_copyright' ) ) { - return; - } - - // Get the old logo value. - $old_value = get_option( 'gen_custom_copyright' ); - - // If there's no old value, bail. - if ( empty( $old_value ) ) { - return; - } - - // Now let's update the new logo setting with our ID. - set_theme_mod( 'generate_copyright', $old_value ); - - // Got our custom logo? Time to delete the old value. - if ( get_theme_mod( 'generate_copyright' ) ) { - delete_option( 'gen_custom_copyright' ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/copyright/functions/js/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/copyright/functions/js/customizer.js deleted file mode 100644 index fdd64115..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/copyright/functions/js/customizer.js +++ /dev/null @@ -1,18 +0,0 @@ -/** - * Theme Customizer enhancements for a better user experience. - * - * Contains handlers to make Theme Customizer preview reload changes asynchronously. - */ - -( function( $ ) { - // Update the site title in real time... - wp.customize( 'generate_copyright', function( value ) { - value.bind( function( newval ) { - if ( $( '.copyright-bar' ).length ) { - $( '.copyright-bar' ).html( newval ); - } else { - $( '.inside-site-info' ).html( newval ); - } - } ); - } ); -}( jQuery ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/copyright/generate-copyright.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/copyright/generate-copyright.php deleted file mode 100644 index 2b9ce0b3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/copyright/generate-copyright.php +++ /dev/null @@ -1,20 +0,0 @@ -ID, '_generate-disable-header', true ); - $disable_nav = get_post_meta( $post->ID, '_generate-disable-nav', true ); - $disable_secondary_nav = get_post_meta( $post->ID, '_generate-disable-secondary-nav', true ); - $disable_post_image = get_post_meta( $post->ID, '_generate-disable-post-image', true ); - $disable_headline = get_post_meta( $post->ID, '_generate-disable-headline', true ); - $disable_footer = get_post_meta( $post->ID, '_generate-disable-footer', true ); - } - - $return = ''; - - if ( ! empty( $disable_header ) && false !== $disable_header ) { - $return = '.site-header {display:none}'; - } - - if ( ! empty( $disable_nav ) && false !== $disable_nav ) { - $return .= '#site-navigation,.navigation-clone, #mobile-header {display:none !important}'; - } - - if ( ! empty( $disable_secondary_nav ) && false !== $disable_secondary_nav ) { - $return .= '#secondary-navigation {display:none}'; - } - - if ( ! empty( $disable_post_image ) && false !== $disable_post_image ) { - $return .= '.generate-page-header, .page-header-image, .page-header-image-single {display:none}'; - } - - $need_css_removal = true; - - if ( defined( 'GENERATE_VERSION' ) && version_compare( GENERATE_VERSION, '3.0.0-alpha.1', '>=' ) ) { - $need_css_removal = false; - } - - if ( $need_css_removal && ! empty( $disable_headline ) && false !== $disable_headline && ! is_single() ) { - $return .= '.entry-header {display:none} .page-content, .entry-content, .entry-summary {margin-top:0}'; - } - - if ( ! empty( $disable_footer ) && false !== $disable_footer ) { - $return .= '.site-footer {display:none}'; - } - - return $return; - } -} - -if ( ! function_exists( 'generate_de_scripts' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_de_scripts', 50 ); - /** - * Enqueue scripts and styles - */ - function generate_de_scripts() { - wp_add_inline_style( 'generate-style', generate_disable_elements() ); - } -} - -if ( ! function_exists( 'generate_add_de_meta_box' ) ) { - add_action( 'add_meta_boxes', 'generate_add_de_meta_box', 50 ); - /** - * Generate the layout metabox. - * - * @since 0.1 - */ - function generate_add_de_meta_box() { - // Set user role - make filterable. - $allowed = apply_filters( 'generate_metabox_capability', 'edit_theme_options' ); - - // If not an administrator, don't show the metabox. - if ( ! current_user_can( $allowed ) ) { - return; - } - - if ( defined( 'GENERATE_LAYOUT_META_BOX' ) ) { - return; - } - - $args = array( 'public' => true ); - $post_types = get_post_types( $args ); - foreach ( $post_types as $type ) { - if ( 'attachment' !== $type ) { - add_meta_box( - 'generate_de_meta_box', - __( 'Disable Elements', 'gp-premium' ), - 'generate_show_de_meta_box', - $type, - 'side', - 'default' - ); - } - } - } -} - -if ( ! function_exists( 'generate_show_de_meta_box' ) ) { - /** - * Outputs the content of the metabox. - * - * @param object $post The post object. - */ - function generate_show_de_meta_box( $post ) { - wp_nonce_field( basename( __FILE__ ), 'generate_de_nonce' ); - $stored_meta = get_post_meta( $post->ID ); - $stored_meta['_generate-disable-header'][0] = ( isset( $stored_meta['_generate-disable-header'][0] ) ) ? $stored_meta['_generate-disable-header'][0] : ''; - $stored_meta['_generate-disable-nav'][0] = ( isset( $stored_meta['_generate-disable-nav'][0] ) ) ? $stored_meta['_generate-disable-nav'][0] : ''; - $stored_meta['_generate-disable-secondary-nav'][0] = ( isset( $stored_meta['_generate-disable-secondary-nav'][0] ) ) ? $stored_meta['_generate-disable-secondary-nav'][0] : ''; - $stored_meta['_generate-disable-post-image'][0] = ( isset( $stored_meta['_generate-disable-post-image'][0] ) ) ? $stored_meta['_generate-disable-post-image'][0] : ''; - $stored_meta['_generate-disable-headline'][0] = ( isset( $stored_meta['_generate-disable-headline'][0] ) ) ? $stored_meta['_generate-disable-headline'][0] : ''; - $stored_meta['_generate-disable-footer'][0] = ( isset( $stored_meta['_generate-disable-footer'][0] ) ) ? $stored_meta['_generate-disable-footer'][0] : ''; - $stored_meta['_generate-disable-top-bar'][0] = ( isset( $stored_meta['_generate-disable-top-bar'][0] ) ) ? $stored_meta['_generate-disable-top-bar'][0] : ''; - ?> - -

    -

    - - - - - - - - - - - - - - - - - -
    -

    - - ID, '_generate-disable-top-bar', true ); - $disable_header = get_post_meta( $post->ID, '_generate-disable-header', true ); - $disable_mobile_header = get_post_meta( $post->ID, '_generate-disable-mobile-header', true ); - $disable_nav = get_post_meta( $post->ID, '_generate-disable-nav', true ); - $disable_headline = get_post_meta( $post->ID, '_generate-disable-headline', true ); - $disable_footer = get_post_meta( $post->ID, '_generate-disable-footer', true ); - } - - // Remove the top bar. - if ( ! empty( $disable_top_bar ) && false !== $disable_top_bar && function_exists( 'generate_top_bar' ) ) { - remove_action( 'generate_before_header', 'generate_top_bar', 5 ); - remove_action( 'generate_inside_secondary_navigation', 'generate_secondary_nav_top_bar_widget', 5 ); - } - - // Remove the header. - if ( ! empty( $disable_header ) && false !== $disable_header && function_exists( 'generate_construct_header' ) ) { - remove_action( 'generate_header', 'generate_construct_header' ); - } - - // Remove the mobile header. - if ( ! empty( $disable_mobile_header ) && false !== $disable_mobile_header && function_exists( 'generate_menu_plus_mobile_header' ) ) { - remove_action( 'generate_after_header', 'generate_menu_plus_mobile_header', 5 ); - } - - // Remove the navigation. - if ( ! empty( $disable_nav ) && false !== $disable_nav && function_exists( 'generate_get_navigation_location' ) ) { - add_filter( 'generate_navigation_location', '__return_false', 20 ); - add_filter( 'generate_disable_mobile_header_menu', '__return_true' ); - } - - // Remove the title. - if ( ! empty( $disable_headline ) && false !== $disable_headline && function_exists( 'generate_show_title' ) ) { - add_filter( 'generate_show_title', '__return_false' ); - } - - // Remove the footer. - if ( ! empty( $disable_footer ) && false !== $disable_footer ) { - if ( function_exists( 'generate_construct_footer_widgets' ) ) { - remove_action( 'generate_footer', 'generate_construct_footer_widgets', 5 ); - } - - if ( function_exists( 'generate_construct_footer' ) ) { - remove_action( 'generate_footer', 'generate_construct_footer' ); - } - } - } -} - -add_action( 'generate_layout_disable_elements_section', 'generate_premium_disable_elements_options' ); -/** - * Add the meta box options to the Layout meta box in the new GP - * - * @since 1.4 - * @param array $stored_meta Existing meta data. - */ -function generate_premium_disable_elements_options( $stored_meta ) { - $stored_meta['_generate-disable-header'][0] = ( isset( $stored_meta['_generate-disable-header'][0] ) ) ? $stored_meta['_generate-disable-header'][0] : ''; - $stored_meta['_generate-disable-mobile-header'][0] = ( isset( $stored_meta['_generate-disable-mobile-header'][0] ) ) ? $stored_meta['_generate-disable-mobile-header'][0] : ''; - $stored_meta['_generate-disable-nav'][0] = ( isset( $stored_meta['_generate-disable-nav'][0] ) ) ? $stored_meta['_generate-disable-nav'][0] : ''; - $stored_meta['_generate-disable-secondary-nav'][0] = ( isset( $stored_meta['_generate-disable-secondary-nav'][0] ) ) ? $stored_meta['_generate-disable-secondary-nav'][0] : ''; - $stored_meta['_generate-disable-post-image'][0] = ( isset( $stored_meta['_generate-disable-post-image'][0] ) ) ? $stored_meta['_generate-disable-post-image'][0] : ''; - $stored_meta['_generate-disable-headline'][0] = ( isset( $stored_meta['_generate-disable-headline'][0] ) ) ? $stored_meta['_generate-disable-headline'][0] : ''; - $stored_meta['_generate-disable-footer'][0] = ( isset( $stored_meta['_generate-disable-footer'][0] ) ) ? $stored_meta['_generate-disable-footer'][0] : ''; - $stored_meta['_generate-disable-top-bar'][0] = ( isset( $stored_meta['_generate-disable-top-bar'][0] ) ) ? $stored_meta['_generate-disable-top-bar'][0] : ''; - ?> -
    - - - - - - - - - - - - - - - - - - - - - -
    - array('wp-hooks', 'wp-i18n'), 'version' => 'bfbc5254c52ffe55aa92'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/adjacent-posts.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/adjacent-posts.js deleted file mode 100644 index 673839b4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/adjacent-posts.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";const s=window.wp.i18n,e=window.wp.hooks;(0,e.addFilter)("generateblocks.dynamicTags.sourceOptions","generatepress-pro/dynamicTags/set-adjacent-post-options",(function(e,{dynamicTagType:t}){return"post"!==t||(e.push({value:"next-post",label:(0,s.__)("Next Post","gp-premium")}),e.push({value:"previous-post",label:(0,s.__)("Previous Post","gp-premium")})),e})),(0,e.addFilter)("generateblocks.dynamicTags.sourcesInOptions","generatepress-pro/dynamicTags/set-adjacent-sources-in-options",(function(s){return s.push("next-post"),s.push("previous-post"),s}))})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements-rtl.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements-rtl.css deleted file mode 100644 index 1117e2e3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements-rtl.css +++ /dev/null @@ -1,7 +0,0 @@ -.inline-post-meta-area.block-editor-block-list__layout,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout{align-items:center;display:flex}.inline-post-meta-area.block-editor-block-list__layout>.wp-block.block-list-appender,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout>.wp-block.block-list-appender,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout>.wp-block.block-list-appender{margin-right:20px}.inline-post-meta-area.block-editor-block-list__layout>.wp-block-image,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout>.wp-block-image,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout>.wp-block-image{line-height:0}.inline-post-meta-area.block-editor-block-list__layout>.wp-block-image figcaption,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout>.wp-block-image figcaption,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout>.wp-block-image figcaption{display:none}.inline-post-meta-area .wp-block{margin-right:0;margin-left:0}.gpp-dynamic-container-bg-dropdown .components-popover__content{width:275px}.gpp-dynamic-container-bg-dropdown .components-popover__content .components-base-control:not(:last-child){margin-bottom:20px}.gpp-dynamic-container-bg-dropdown .components-popover__content .components-base-control:last-child .components-base-control__field{margin-bottom:0}.gpp-dynamic-container-bg-dropdown .components-popover__content .components-base-control:last-child .components-base-control__help{margin-top:3px} -.gpp-dynamic-headline-text-dropdown .components-popover__content{width:275px}.gpp-dynamic-headline-text-dropdown .components-popover__content .components-base-control:not(:last-child){margin-bottom:20px}.gpp-dynamic-headline-text-dropdown .components-popover__content .components-base-control:last-child .components-base-control__field{margin-bottom:0}.gpp-dynamic-headline-text-dropdown .components-popover__content .components-base-control:last-child .components-base-control__help{margin-top:3px}.gpp-blocks-dynamic-text-replace-field{display:none}.gpp-block-dynamic-year .components-base-control__help{margin-top:2px} -.wp-block[data-type="generatepress/dynamic-content"]{margin-bottom:0;margin-top:0} -.wp-block[data-type="generatepress/dynamic-image"]{color:#fff;margin-bottom:0;margin-top:0}.wp-block[data-type="generatepress/dynamic-image"] .components-gpp-dynamic-image-placeholder__label{align-items:center;bottom:0;color:#fff;display:flex;font-size:1em;justify-content:center;right:0;position:absolute;left:0;top:0}.wp-block[data-type="generatepress/dynamic-image"] .components-gpp-dynamic-image-placeholder__label>.gpp-dynamic-featured-image__label{margin-right:10px}.wp-block[data-type="generatepress/dynamic-image"] .gpp-dynamic-image-placeholder{background:#000;vertical-align:middle}.wp-block[data-type="generatepress/dynamic-image"] .components-placeholder{width:100%}.wp-block[data-type="generatepress/dynamic-image"] .gpp-dynamic-image-preview{display:inline-block;position:relative}.wp-block[data-type="generatepress/dynamic-image"] .dynamic-author-image-rounded{border-radius:100%} -.components-generatepress-units-control-header__units{align-items:center;display:flex;justify-content:space-between;margin-bottom:5px}.components-generatepress-control__units .components-generatepress-control-buttons__units button.components-button{background:#fff;border:0;border-radius:0!important;box-shadow:none!important;color:#929da7;font-size:10px;height:auto;line-height:20px;padding:0 5px;position:relative;text-align:center;text-shadow:none}.components-generatepress-control__units .components-generatepress-control-buttons__units button.components-button.is-primary{background:#fff!important;color:#000!important;cursor:default;font-weight:700;z-index:1} -.editor-styles-wrapper .is-root-container>.wp-block{margin-right:auto;margin-left:auto;max-width:var(--gp-block-element-width)}.left-sidebar-block-type div:not(.block-editor-inner-blocks)>.block-editor-block-list__layout,.right-sidebar-block-type div:not(.block-editor-inner-blocks)>.block-editor-block-list__layout{padding:10px}.gpp-block-element-panel>.components-base-control{margin-bottom:20px}.gpp-block-element-panel .components-notice,.gpp-block-element-panel .components-notice .components-notice__content{margin:0}.gpp-element-panel-label .components-panel__body-toggle.components-button{display:flex;flex-direction:row-reverse;justify-content:flex-end}.gpp-element-panel-label .components-panel__body-toggle.components-button svg.components-panel__icon{margin:0 0 0 10px}button.gpp-block-elements-template-button{background:#fff;border:1px solid #ddd;border-radius:5px;cursor:pointer;margin:0 0 10px;padding:5px}button.gpp-block-elements-template-button:hover{border-color:var(--wp-admin-theme-color)}button.gpp-block-elements-template-button .gpp-block-template-label{color:#888;font-size:13px;padding:5px}.element-has-parent #generate_premium_elements{display:none}.gpp-block-element-template-panel{background:#fafafa} -.gp-select-search .select-search-container{--select-search-background:#fff;--select-search-border:#949494;--select-search-selected:var(--wp-admin-theme-color);--select-search-text:#2c3338;--select-search-subtle-text:#6c6f85;--select-search-inverted-text:var(--select-search-background);--select-search-highlight:#eff1f5;box-sizing:border-box;color:var(--select-search-text);font-family:var(--select-search-font);position:relative;width:100%}.gp-select-search .select-search-container *,.gp-select-search .select-search-container :after,.gp-select-search .select-search-container :before{box-sizing:inherit}.gp-select-search .select-search-input{-webkit-appearance:none;border:1px solid var(--select-search-border);border-radius:3px;color:var(--select-search-text);display:block;font-size:13px;height:30px;letter-spacing:.01rem;line-height:30px;outline:none;padding:0 8px 0 26px;position:relative;text-align:right;text-overflow:ellipsis;width:100%;z-index:1;-webkit-font-smoothing:antialiased;background:var(--select-search-background) url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E") no-repeat left 5px top 55%;background-size:13px 13px}.gp-select-search .select-search-is-multiple .select-search-input{border-radius:3px 3px 0 0;margin-bottom:-2px}.gp-select-search .select-search-input::-webkit-search-cancel-button,.gp-select-search .select-search-input::-webkit-search-decoration,.gp-select-search .select-search-input::-webkit-search-results-button,.gp-select-search .select-search-input::-webkit-search-results-decoration{-webkit-appearance:none}.gp-select-search .select-search-input[readonly]{cursor:pointer}.gp-select-search .select-search-is-disabled .select-search-input{cursor:not-allowed}.gp-select-search .select-search-container:not(.select-search-is-disabled) .select-search-input:hover,.gp-select-search .select-search-container:not(.select-search-is-disabled).select-search-has-focus .select-search-input{border-color:var(--select-search-selected)}.gp-select-search .select-search-select{background:var(--select-search-background);border:1px solid var(--select-search-border);box-shadow:0 .0625rem .125rem #00000026;max-height:360px;overflow:auto}.gp-select-search .select-search-container:not(.select-search-is-multiple) .select-search-select{border-radius:3px;display:none;right:0;position:absolute;left:0;top:35px;z-index:2}.gp-select-search .select-search-container:not(.select-search-is-multiple).select-search-has-focus .select-search-select{display:block}.gp-select-search .select-search-has-focus .select-search-select{border-color:var(--select-search-selected)}.gp-select-search .select-search-options{list-style:none}.gp-select-search .select-search-not-found,.gp-select-search .select-search-option{background:var(--select-search-background);border:none;color:var(--select-search-text);cursor:pointer;display:block;font-family:monospace;font-size:11px;height:30px;letter-spacing:.01rem;outline:none;padding:0 8px;text-align:right;width:100%;-webkit-font-smoothing:antialiased}.gp-select-search .select-search-option:disabled{background:#0000!important;cursor:not-allowed;opacity:.5}.gp-select-search .select-search-is-highlighted,.gp-select-search .select-search-option:not(.select-search-is-selected):hover{background:var(--select-search-highlight)}.gp-select-search .select-search-is-selected{color:var(--select-search-selected);font-weight:700}.gp-select-search .select-search-group-header{font-size:12px;font-weight:700;letter-spacing:.1rem;padding:10px 8px;text-transform:uppercase} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.asset.php deleted file mode 100644 index 7388e923..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('lodash', 'react', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-data', 'wp-dom-ready', 'wp-edit-post', 'wp-element', 'wp-hooks', 'wp-i18n', 'wp-plugins', 'wp-server-side-render'), 'version' => '3e4b04d9f2c101e0232f'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.css deleted file mode 100644 index cd289fa7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.css +++ /dev/null @@ -1,7 +0,0 @@ -.inline-post-meta-area.block-editor-block-list__layout,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout{align-items:center;display:flex}.inline-post-meta-area.block-editor-block-list__layout>.wp-block.block-list-appender,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout>.wp-block.block-list-appender,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout>.wp-block.block-list-appender{margin-left:20px}.inline-post-meta-area.block-editor-block-list__layout>.wp-block-image,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout>.wp-block-image,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout>.wp-block-image{line-height:0}.inline-post-meta-area.block-editor-block-list__layout>.wp-block-image figcaption,.inline-post-meta-area>.gb-inside-container.block-editor-block-list__layout>.wp-block-image figcaption,.inline-post-meta-area>.gb-inside-container>.block-editor-inner-blocks>.block-editor-block-list__layout>.wp-block-image figcaption{display:none}.inline-post-meta-area .wp-block{margin-left:0;margin-right:0}.gpp-dynamic-container-bg-dropdown .components-popover__content{width:275px}.gpp-dynamic-container-bg-dropdown .components-popover__content .components-base-control:not(:last-child){margin-bottom:20px}.gpp-dynamic-container-bg-dropdown .components-popover__content .components-base-control:last-child .components-base-control__field{margin-bottom:0}.gpp-dynamic-container-bg-dropdown .components-popover__content .components-base-control:last-child .components-base-control__help{margin-top:3px} -.gpp-dynamic-headline-text-dropdown .components-popover__content{width:275px}.gpp-dynamic-headline-text-dropdown .components-popover__content .components-base-control:not(:last-child){margin-bottom:20px}.gpp-dynamic-headline-text-dropdown .components-popover__content .components-base-control:last-child .components-base-control__field{margin-bottom:0}.gpp-dynamic-headline-text-dropdown .components-popover__content .components-base-control:last-child .components-base-control__help{margin-top:3px}.gpp-blocks-dynamic-text-replace-field{display:none}.gpp-block-dynamic-year .components-base-control__help{margin-top:2px} -.wp-block[data-type="generatepress/dynamic-content"]{margin-bottom:0;margin-top:0} -.wp-block[data-type="generatepress/dynamic-image"]{color:#fff;margin-bottom:0;margin-top:0}.wp-block[data-type="generatepress/dynamic-image"] .components-gpp-dynamic-image-placeholder__label{align-items:center;bottom:0;color:#fff;display:flex;font-size:1em;justify-content:center;left:0;position:absolute;right:0;top:0}.wp-block[data-type="generatepress/dynamic-image"] .components-gpp-dynamic-image-placeholder__label>.gpp-dynamic-featured-image__label{margin-left:10px}.wp-block[data-type="generatepress/dynamic-image"] .gpp-dynamic-image-placeholder{background:#000;vertical-align:middle}.wp-block[data-type="generatepress/dynamic-image"] .components-placeholder{width:100%}.wp-block[data-type="generatepress/dynamic-image"] .gpp-dynamic-image-preview{display:inline-block;position:relative}.wp-block[data-type="generatepress/dynamic-image"] .dynamic-author-image-rounded{border-radius:100%} -.components-generatepress-units-control-header__units{align-items:center;display:flex;justify-content:space-between;margin-bottom:5px}.components-generatepress-control__units .components-generatepress-control-buttons__units button.components-button{background:#fff;border:0;border-radius:0!important;box-shadow:none!important;color:#929da7;font-size:10px;height:auto;line-height:20px;padding:0 5px;position:relative;text-align:center;text-shadow:none}.components-generatepress-control__units .components-generatepress-control-buttons__units button.components-button.is-primary{background:#fff!important;color:#000!important;cursor:default;font-weight:700;z-index:1} -.editor-styles-wrapper .is-root-container>.wp-block{margin-left:auto;margin-right:auto;max-width:var(--gp-block-element-width)}.left-sidebar-block-type div:not(.block-editor-inner-blocks)>.block-editor-block-list__layout,.right-sidebar-block-type div:not(.block-editor-inner-blocks)>.block-editor-block-list__layout{padding:10px}.gpp-block-element-panel>.components-base-control{margin-bottom:20px}.gpp-block-element-panel .components-notice,.gpp-block-element-panel .components-notice .components-notice__content{margin:0}.gpp-element-panel-label .components-panel__body-toggle.components-button{display:flex;flex-direction:row-reverse;justify-content:flex-end}.gpp-element-panel-label .components-panel__body-toggle.components-button svg.components-panel__icon{margin:0 10px 0 0}button.gpp-block-elements-template-button{background:#fff;border:1px solid #ddd;border-radius:5px;cursor:pointer;margin:0 0 10px;padding:5px}button.gpp-block-elements-template-button:hover{border-color:var(--wp-admin-theme-color)}button.gpp-block-elements-template-button .gpp-block-template-label{color:#888;font-size:13px;padding:5px}.element-has-parent #generate_premium_elements{display:none}.gpp-block-element-template-panel{background:#fafafa} -.gp-select-search .select-search-container{--select-search-background:#fff;--select-search-border:#949494;--select-search-selected:var(--wp-admin-theme-color);--select-search-text:#2c3338;--select-search-subtle-text:#6c6f85;--select-search-inverted-text:var(--select-search-background);--select-search-highlight:#eff1f5;box-sizing:border-box;color:var(--select-search-text);font-family:var(--select-search-font);position:relative;width:100%}.gp-select-search .select-search-container *,.gp-select-search .select-search-container :after,.gp-select-search .select-search-container :before{box-sizing:inherit}.gp-select-search .select-search-input{-webkit-appearance:none;border:1px solid var(--select-search-border);border-radius:3px;color:var(--select-search-text);display:block;font-size:13px;height:30px;letter-spacing:.01rem;line-height:30px;outline:none;padding:0 26px 0 8px;position:relative;text-align:left;text-overflow:ellipsis;width:100%;z-index:1;-webkit-font-smoothing:antialiased;background:var(--select-search-background) url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E") no-repeat right 5px top 55%;background-size:13px 13px}.gp-select-search .select-search-is-multiple .select-search-input{border-radius:3px 3px 0 0;margin-bottom:-2px}.gp-select-search .select-search-input::-webkit-search-cancel-button,.gp-select-search .select-search-input::-webkit-search-decoration,.gp-select-search .select-search-input::-webkit-search-results-button,.gp-select-search .select-search-input::-webkit-search-results-decoration{-webkit-appearance:none}.gp-select-search .select-search-input[readonly]{cursor:pointer}.gp-select-search .select-search-is-disabled .select-search-input{cursor:not-allowed}.gp-select-search .select-search-container:not(.select-search-is-disabled) .select-search-input:hover,.gp-select-search .select-search-container:not(.select-search-is-disabled).select-search-has-focus .select-search-input{border-color:var(--select-search-selected)}.gp-select-search .select-search-select{background:var(--select-search-background);border:1px solid var(--select-search-border);box-shadow:0 .0625rem .125rem #00000026;max-height:360px;overflow:auto}.gp-select-search .select-search-container:not(.select-search-is-multiple) .select-search-select{border-radius:3px;display:none;left:0;position:absolute;right:0;top:35px;z-index:2}.gp-select-search .select-search-container:not(.select-search-is-multiple).select-search-has-focus .select-search-select{display:block}.gp-select-search .select-search-has-focus .select-search-select{border-color:var(--select-search-selected)}.gp-select-search .select-search-options{list-style:none}.gp-select-search .select-search-not-found,.gp-select-search .select-search-option{background:var(--select-search-background);border:none;color:var(--select-search-text);cursor:pointer;display:block;font-family:monospace;font-size:11px;height:30px;letter-spacing:.01rem;outline:none;padding:0 8px;text-align:left;width:100%;-webkit-font-smoothing:antialiased}.gp-select-search .select-search-option:disabled{background:#0000!important;cursor:not-allowed;opacity:.5}.gp-select-search .select-search-is-highlighted,.gp-select-search .select-search-option:not(.select-search-is-selected):hover{background:var(--select-search-highlight)}.gp-select-search .select-search-is-selected{color:var(--select-search-selected);font-weight:700}.gp-select-search .select-search-group-header{font-size:12px;font-weight:700;letter-spacing:.1rem;padding:10px 8px;text-transform:uppercase} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.js deleted file mode 100644 index 33336a1f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/block-elements.js +++ /dev/null @@ -1,3 +0,0 @@ -(()=>{var e={184:(e,t)=>{var n;!function(){"use strict";var a={}.hasOwnProperty;function i(){for(var e=[],t=0;t{"use strict";var a=n(196),i=Symbol.for("react.element"),o=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),r=a.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,p={key:!0,ref:!0,__self:!0,__source:!0};function l(e,t,n){var a,l={},c=null,g=null;for(a in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(g=t.ref),t)o.call(t,a)&&!p.hasOwnProperty(a)&&(l[a]=t[a]);if(e&&e.defaultProps)for(a in t=e.defaultProps)void 0===l[a]&&(l[a]=t[a]);return{$$typeof:i,type:e,key:c,ref:g,props:l,_owner:r.current}}t.jsx=l,t.jsxs=l},893:(e,t,n)=>{"use strict";e.exports=n(251)},196:e=>{"use strict";e.exports=window.React}},t={};function n(a){var i=t[a];if(void 0!==i)return i.exports;var o=t[a]={exports:{}};return e[a](o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var a in t)n.o(t,a)&&!n.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e=n(196);function t(e,t,n){return void 0===e[t]&&(e[t]=[]),e[t].push(n),e}function a(t,n=null){return"generatepress"===t?(0,e.createElement)("svg",{width:"20",height:"20",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 600 600",preserveAspectRatio:"none"},(0,e.createElement)("path",{d:"M485.2 427.8l-99.1-46.2 15.8-34c5.6-11.9 8.8-24.3 10-36.7 3.3-33.7-9-67.3-33.2-91.1-8.9-8.7-19.3-16.1-31.3-21.7-11.9-5.6-24.3-8.8-36.7-10-33.7-3.3-67.4 9-91.1 33.2-8.7 8.9-16.1 19.3-21.7 31.3l-15.8 34-30.4 65.2c-.7 1.5-.1 3.3 1.5 4l65.2 30.4 34 15.8 34 15.8 68 31.7 74.7 34.8c-65 45.4-152.1 55.2-228.7 17.4C90.2 447.4 44.1 313.3 97.3 202.6c53.3-110.8 186-158.5 297.8-106.3 88.1 41.1 137.1 131.9 129.1 223.4-.1 1.3.6 2.4 1.7 3l65.6 30.6c1.8.8 3.9-.3 4.2-2.2 22.6-130.7-44-265.4-170.5-323.5-150.3-69-327-4.1-396.9 145.8-70 150.1-5.1 328.5 145.1 398.5 114.1 53.2 244.5 28.4 331.3-52.3 17.9-16.6 33.9-35.6 47.5-56.8 1-1.5.4-3.6-1.3-4.3l-65.7-30.7zm-235-109.6l15.8-34c8.8-18.8 31.1-26.9 49.8-18.1s26.9 31 18.1 49.8l-15.8 34-34-15.8-33.9-15.9z"})):"dynamic"===t?(0,e.createElement)("svg",{width:"24",height:"24",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",viewBox:"0 0 256 256"},(0,e.createElement)("path",{d:"M128 26c-52.71 0-94 23.72-94 54v96c0 30.28 41.29 54 94 54s94-23.72 94-54V80c0-30.28-41.29-54-94-54zm0 12c44.449 0 82 19.233 82 42s-37.551 42-82 42-82-19.233-82-42 37.551-42 82-42zm82 138c0 22.767-37.551 42-82 42s-82-19.233-82-42v-21.21C61.97 171.163 92.374 182 128 182s66.03-10.837 82-27.21zm0-48c0 22.767-37.551 42-82 42s-82-19.233-82-42v-21.21C61.97 123.163 92.374 134 128 134s66.03-10.837 82-27.21z",fill:"currentColor"})):"tools"===t?(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},(0,e.createElement)("path",{d:"M14.7 6.3a1 1 0 000 1.4l1.6 1.6a1 1 0 001.4 0l3.77-3.77a6 6 0 01-7.94 7.94l-6.91 6.91a2.12 2.12 0 01-3-3l6.91-6.91a6 6 0 017.94-7.94l-3.76 3.76z"})):"sliders"===t?(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M4 21v-7M4 10V3M12 21v-9M12 8V3M20 21v-5M20 12V3M1 14h6M9 8h6M17 16h6"})):"plus-circle"===t?(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",clipRule:"evenodd",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2",viewBox:"0 0 24 24",style:n},(0,e.createElement)("path",{d:"m12.002 2c5.518 0 9.998 4.48 9.998 9.998 0 5.517-4.48 9.997-9.998 9.997-5.517 0-9.997-4.48-9.997-9.997 0-5.518 4.48-9.998 9.997-9.998zm0 1.5c-4.69 0-8.497 3.808-8.497 8.498s3.807 8.497 8.497 8.497 8.498-3.807 8.498-8.497-3.808-8.498-8.498-8.498zm-.747 7.75h-3.5c-.414 0-.75.336-.75.75s.336.75.75.75h3.5v3.5c0 .414.336.75.75.75s.75-.336.75-.75v-3.5h3.5c.414 0 .75-.336.75-.75s-.336-.75-.75-.75h-3.5v-3.5c0-.414-.336-.75-.75-.75s-.75.336-.75.75z",fillRule:"nonzero"})):"minus-circle"===t?(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",clipRule:"evenodd",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2",viewBox:"0 0 24 24",style:n},(0,e.createElement)("path",{d:"m12.002 2.005c5.518 0 9.998 4.48 9.998 9.997 0 5.518-4.48 9.998-9.998 9.998-5.517 0-9.997-4.48-9.997-9.998 0-5.517 4.48-9.997 9.997-9.997zm0 1.5c-4.69 0-8.497 3.807-8.497 8.497s3.807 8.498 8.497 8.498 8.498-3.808 8.498-8.498-3.808-8.497-8.498-8.497zm4.253 7.75h-8.5c-.414 0-.75.336-.75.75s.336.75.75.75h8.5c.414 0 .75-.336.75-.75s-.336-.75-.75-.75z",fillRule:"nonzero"})):"trash"===t?(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",style:{fill:"none"},stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M3 6h18M19 6v14a2 2 0 01-2 2H7a2 2 0 01-2-2V6m3 0V4a2 2 0 012-2h4a2 2 0 012 2v2M10 11v6M14 11v6"})):void 0}const i=window.wp.i18n,o=window.wp.hooks,r=window.wp.element,p=window.wp.components,l=window.wp.compose,c=window.wp.blockEditor,g=["generateblocks/container"];function s(t){const n=()=>{let e="Desktop";return void 0!==t.deviceType&&t.deviceType&&(e=t.deviceType),e},{attributes:a,setAttributes:o,showInlineOptions:l=!1}=t,{gpInlinePostMeta:c,gpInlinePostMetaJustify:g,gpInlinePostMetaJustifyTablet:s,gpInlinePostMetaJustifyMobile:d,gpRemoveContainerCondition:m,gpRemoveContainerConditionPostMeta:u,gpAdjacentPostInSameTerm:b,gpAdjacentPostInSameTermTax:x}=a,h=wp.data.select("core/editor").getEditedPostAttribute("meta"),f=[{label:(0,i.__)("Choose…","gp-premium"),value:"self"},{label:(0,i.__)("No featured image","gp-premium"),value:"no-featured-image"},{label:(0,i.__)("No post meta","gp-premium"),value:"no-post-meta"}];return"post-navigation-template"===h._generate_block_type&&(f.push({label:(0,i.__)("No next post","gp-premium"),value:"no-next-post"}),f.push({label:(0,i.__)("No previous post","gp-premium"),value:"no-previous-post"})),gpPremiumBlockElements.isBlockElement?(0,e.createElement)(r.Fragment,null,!!l&&"Desktop"===n()&&(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("Inline post meta items","gp-premium"),checked:!!c,onChange:e=>{o({gpInlinePostMeta:e})}}),!!l&&!!c&&(0,e.createElement)(r.Fragment,null,"Desktop"===n()&&(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Inline alignment","gp-premium"),value:g,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Left","gp-premium"),value:"flex-start"},{label:(0,i.__)("Center","gp-premium"),value:"center"},{label:(0,i.__)("Right","gp-premium"),value:"flex-end"},{label:(0,i.__)("Space between","gp-premium"),value:"space-between"}],onChange:e=>{o({gpInlinePostMetaJustify:e})}}),"Tablet"===n()&&(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Inline alignment","gp-premium"),value:s,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Left","gp-premium"),value:"flex-start"},{label:(0,i.__)("Center","gp-premium"),value:"center"},{label:(0,i.__)("Right","gp-premium"),value:"flex-end"},{label:(0,i.__)("Space between","gp-premium"),value:"space-between"}],onChange:e=>{o({gpInlinePostMetaJustifyTablet:e})}}),"Mobile"===n()&&(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Inline alignment","gp-premium"),value:d,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Left","gp-premium"),value:"flex-start"},{label:(0,i.__)("Center","gp-premium"),value:"center"},{label:(0,i.__)("Right","gp-premium"),value:"flex-end"},{label:(0,i.__)("Space between","gp-premium"),value:"space-between"}],onChange:e=>{o({gpInlinePostMetaJustifyMobile:e})}})),(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Remove container condition","gp-premium"),value:m,options:f,onChange:e=>{o({gpRemoveContainerCondition:e})}}),"no-post-meta"===m&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Meta field name","gp-premium"),type:"text",value:u,onChange:e=>{o({gpRemoveContainerConditionPostMeta:e})}}),("no-next-post"===m||"no-previous-post"===m)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("In same term","gp-premium"),help:(0,i.__)("Check for posts with the same term as the current post.","gp-premium"),checked:!!b,onChange:e=>{o({gpAdjacentPostInSameTerm:e})}}),!!b&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Taxonomy","gp-premium"),help:(0,i.__)("The taxonomy to check if in the same term.","gp-premium"),type:"text",value:x,onChange:e=>{o({gpAdjacentPostInSameTermTax:e})}})))):null}const d=(0,l.createHigherOrderComponent)((t=>n=>{const{name:o,attributes:l,isSelected:s,setAttributes:d}=n,{gpDynamicImageBg:m,gpDynamicImageCustomField:u,gpUseFallbackImageBg:b,bgImage:x,gpDynamicLinkType:h,gpDynamicLinkCustomField:f,gpDynamicSource:y,gpDynamicSourceInSameTerm:_,gpDynamicSourceInSameTermTaxonomy:k}=l,w=wp.data.select("core/editor").getEditedPostAttribute("meta");let v=!!m||!!h;return"post-navigation-template"!==w._generate_block_type&&(v=!1),"next-posts"!==h&&"previous-posts"!==h||(v=!1),(0,e.createElement)(r.Fragment,null,(0,e.createElement)(t,{...n}),s&&g.includes(o)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(c.BlockControls,null,(0,e.createElement)(p.ToolbarGroup,null,(0,e.createElement)(p.Dropdown,{contentClassName:"gpp-dynamic-container-bg-dropdown",popoverProps:{className:"block-editor-block-settings-menu__popover",position:"bottom right"},renderToggle:({isOpen:t,onToggle:n})=>(0,e.createElement)(p.ToolbarButton,{icon:a("dynamic"),label:(0,i.__)("Dynamic options","gp-premium"),onClick:n,"aria-expanded":t,isPressed:!!m||!!h}),renderContent:()=>(0,e.createElement)(r.Fragment,null,(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Dynamic Background Image","gp-premium"),value:m,options:[{label:(0,i.__)("None","gp-premium"),value:""},{label:(0,i.__)("Featured image","gp-premium"),value:"featured-image"},{label:(0,i.__)("Post meta","gp-premium"),value:"post-meta"},{label:(0,i.__)("Term meta","gp-premium"),value:"term-meta"},{label:(0,i.__)("User meta","gp-premium"),value:"user-meta"}],onChange:e=>{d({gpDynamicImageBg:e})},disabled:!x,help:x?"":(0,i.__)("Add a background image to this Container to make it dynamic.","gp-premium")}),("post-meta"===m||"term-meta"===m||"user-meta"===m)&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Meta field name","gp-premium"),value:u,onChange:e=>{d({gpDynamicImageCustomField:e})}}),""!==m&&(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("Use fallback image","gp-premium"),checked:!!b,onChange:e=>{d({gpUseFallbackImageBg:e})}})),gpPremiumBlockElements.isGenerateBlocksProActive&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.BaseControl,{className:"gpp-button-dynamic-link-area"},(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Dynamic Link","gp-premium"),value:h,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Post","gp-premium"),value:"post"},{label:(0,i.__)("Post meta","gp-premium"),value:"post-meta"}],onChange:e=>{d(e?{gpDynamicLinkType:e,url:"#"}:{gpDynamicLinkType:e,url:""})}}),"post-meta"===h&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Meta field name","gp-premium"),type:"text",value:f,onChange:e=>{d({gpDynamicLinkCustomField:e})}}))),v&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Source","gp-premium"),value:y,options:[{label:(0,i.__)("Current post","gp-premium"),value:"current-post"},{label:(0,i.__)("Next post","gp-premium"),value:"next-post"},{label:(0,i.__)("Previous post","gp-premium"),value:"previous-post"}],onChange:e=>{d({gpDynamicSource:e})}}),("next-post"===y||"previous-post"===y)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("In same term","gp-premium"),help:(0,i.__)("Check for posts with the same term as the current post.","gp-premium"),checked:!!_,onChange:e=>{d({gpDynamicSourceInSameTerm:e})}}),!!_&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Taxonomy","gp-premium"),help:(0,i.__)("The taxonomy to check if in the same term.","gp-premium"),type:"text",value:k,onChange:e=>{d({gpDynamicSourceInSameTermTaxonomy:e})}}))))})))))}),"addDynamicContainerBgToolbar");function m(e,n,a){if(!["container"].includes(a))return e;const i=(0,o.applyFilters)("generateblocks.editor.cssAttrs",n.attributes,n),{uniqueId:r,gpInlinePostMeta:p,gpInlinePostMetaJustify:l,gpInlinePostMetaJustifyTablet:c,gpInlinePostMetaJustifyMobile:g,useInnerContainer:s}=i;let d=".gb-container-"+r+".inline-post-meta-area > .gb-inside-container > .block-editor-inner-blocks > .block-editor-block-list__layout";return void 0!==s&&(d=s?".gb-container-"+r+".inline-post-meta-area > .gb-inside-container":".gb-container-"+r+".inline-post-meta-area"),p&&(t(e,d,{"justify-content":l}),"generateblocks.editor.tabletCSS"===(0,o.currentFilter)()&&t(e,d,{"justify-content":c}),"generateblocks.editor.mobileCSS"===(0,o.currentFilter)()&&t(e,d,{"justify-content":g})),e}(0,o.addFilter)("blocks.registerBlockType","gp-premium/dynamic-container/add-attributes",(function(e){return g.includes(e.name)?(void 0!==e.attributes&&(e.attributes=Object.assign(e.attributes,{gpDynamicImageBg:{type:"string",default:""},gpUseFallbackImageBg:{type:"boolean",default:!1},gpDynamicImageCustomField:{type:"string",default:""},gpInlinePostMeta:{type:"boolean",default:!1},gpInlinePostMetaJustify:{type:"string",default:""},gpInlinePostMetaJustifyTablet:{type:"string",default:""},gpInlinePostMetaJustifyMobile:{type:"string",default:""},gpDynamicLinkType:{type:"string",default:""},gpDynamicLinkCustomField:{type:"string",default:""},gpDynamicSource:{type:"string",default:"current-post"},gpRemoveContainerCondition:{type:"string",default:""},gpRemoveContainerConditionPostMeta:{type:"string",default:""},gpAdjacentPostInSameTerm:{type:"boolean",default:!1},gpAdjacentPostInSameTermTax:{type:"string",default:"category"},gpDynamicSourceInSameTerm:{type:"boolean",default:!1},gpDynamicSourceInSameTermTaxonomy:{type:"string",default:"category"}})),e):e})),(0,o.addFilter)("generateblocks.editor.controls","gp-premium/dynamic-container/add-container-controls",(function(t,n,a){return"containerLayout"!==n&&"containerGridLayout"!==n?t:(0,e.createElement)(r.Fragment,null,(0,e.createElement)(s,{...a,showInlineOptions:!0}),t)})),(0,o.addFilter)("generateblocks.editor.settingsPanel","gp-premium/dynamic-container/add-container-controls",(function(t,n){return"generateblocks/container"!==n.name||n.attributes.useInnerContainer?t:(0,e.createElement)(r.Fragment,null,t,(0,e.createElement)(s,{...n}))})),(0,o.addFilter)("editor.BlockEdit","gp-premium/dynamic-container/toolbar",d),(0,o.addFilter)("generateblocks.frontend.htmlAttributes","gp-premium/dynamic-container/add-html-attributes",(function(e,t,n){return"generateblocks/container"!==t||n.gpInlinePostMeta&&(e=Object.assign(e,{className:e.className+" inline-post-meta-area"})),e})),(0,o.addFilter)("generateblocks.editor.mainCSS","gp-premium/dynamic-container/add-main-css",m),(0,o.addFilter)("generateblocks.editor.tabletCSS","gp-premium/dynamic-container/add-tablet-css",m),(0,o.addFilter)("generateblocks.editor.mobileCSS","gp-premium/dynamic-container/add-mobile-css",m);class u extends r.Component{constructor(){super(...arguments),this.wrapElement=this.wrapElement.bind(this)}componentDidMount(){if(this.props.attributes.gpDynamicTextType&&"generateblocks/headline"===this.props.name){const e=document.querySelector(".gb-headline-"+this.props.attributes.uniqueId+" .rich-text");e&&""!==this.props.attributes.gpDynamicTextType&&this.props.attributes.gpDynamicLinkType&&!this.props.attributes.removeText&&this.wrapElement(e)}}componentDidUpdate(){if(this.props.attributes.gpDynamicTextType){let e=this.props.attributes.content;"generateblocks/button"===this.props.name&&(e=this.props.attributes.text),e!==this.props.attributes.gpDynamicTextReplace&&this.props.setAttributes({gpDynamicTextReplace:e})}if(this.props.attributes.gpDynamicTextType&&"generateblocks/headline"===this.props.name){const e=document.querySelector(".gb-headline-"+this.props.attributes.uniqueId+" .rich-text");if(e){const t=e.parentNode;if(t){const n=t.classList.contains("gblocks-faux-headline-link");""!==this.props.attributes.gpDynamicTextType?(n&&!this.props.attributes.gpDynamicLinkType&&t.replaceWith(...t.childNodes),n||!this.props.attributes.gpDynamicLinkType||this.props.isSelected||this.wrapElement(e)):n&&t.replaceWith(...t.childNodes),(this.props.attributes.removeText||n&&this.props.isSelected)&&t.replaceWith(...t.childNodes)}}}}wrapElement(e){const t=document.createElement("a");t.classList.add("gblocks-faux-headline-link"),e.parentNode.insertBefore(t,e),t.appendChild(e)}render(){return null}}const b=u;class x extends r.Component{render(){const{attributes:t,setAttributes:n,name:a}=this.props,{gpDynamicTextType:o,gpDynamicSource:l,gpDynamicTextReplace:c,gpDynamicTextTaxonomy:g,gpDynamicTextTaxonomySeparator:s,gpDynamicTextCustomField:d,gpDynamicTextBefore:m,gpDynamicDateUpdated:u,gpDynamicNoCommentsText:b,gpDynamicSingleCommentText:x,gpDynamicMultipleCommentsText:h,gpDynamicLinkType:f,gpDynamicLinkCustomField:y,gpDynamicSourceInSameTerm:_,gpDynamicSourceInSameTermTaxonomy:k,className:w,gpDynamicDateType:v,gpDynamicUpdatedDateBefore:T}=t,C=[{label:(0,i.__)("Choose…","gp-premium"),value:""}],D=gpPremiumBlockElements.taxonomies;D&&Object.keys(D).forEach((e=>{C.push({label:D[e],value:D[e]})}));let R=[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Single post","gp-premium"),value:"single-post"},{label:(0,i.__)("Author archives","gp-premium"),value:"author-archives"},{label:(0,i.__)("Comments area","gp-premium"),value:"comments"},{label:(0,i.__)("Next page of posts","gp-premium"),value:"next-posts"},{label:(0,i.__)("Previous page of posts","gp-premium"),value:"previous-posts"},{label:(0,i.__)("Post meta","gp-premium"),value:"post-meta"},{label:(0,i.__)("Author meta","gp-premium"),value:"user-meta"},{label:(0,i.__)("Term meta","gp-premium"),value:"term-meta"}];"terms"===o&&(R=[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Term archives","gp-premium"),value:"term-archives"}]),"generateblocks/headline"!==a||o||(R=[]);let L=!!o||!!f;"post-navigation-template"!==wp.data.select("core/editor").getEditedPostAttribute("meta")._generate_block_type&&(L=!1),"next-posts"!==f&&"previous-posts"!==f||(L=!1);let I=(0,i.__)("Before text","gp-premim");return"post-date"===o&&u&&"published-date"===v&&(I=(0,i.__)("Published date before text","gp-premium")),(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Dynamic text type","gp-premium"),value:o,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Title","gp-premium"),value:"title"},{label:(0,i.__)("Post date","gp-premium"),value:"post-date"},{label:(0,i.__)("Post author name","gp-premium"),value:"post-author"},{label:(0,i.__)("List of terms","gp-premium"),value:"terms"},{label:(0,i.__)("Comments number","gp-premium"),value:"comments-number"},{label:(0,i.__)("Post meta","gp-premium"),value:"post-meta"},{label:(0,i.__)("Term meta","gp-premium"),value:"term-meta"},{label:(0,i.__)("Author meta","gp-premium"),value:"user-meta"}],onChange:e=>{n({gpDynamicTextType:e});let t=[];w&&(t=w.split(" "));const o=["dynamic-term-class"];if(t=t.filter((e=>!o.includes(e))),"terms"===e&&t.push("dynamic-term-class"),t.length>0?n({className:t.join(" ")}):n({className:""}),"generateblocks/headline"===a){let t=(0,i.__)("Hello World","gp-premium");"post-date"===e?t=(0,i.__)("Post date","gp-premium"):"post-author"===e?t=(0,i.__)("Post author name","gp-premium"):"terms"===e?t=(0,i.__)("Terms","gp-premium"):"comments-number"===e?t=(0,i.__)("Comments number","gp-premium"):"post-meta"===e?t=(0,i.__)("Post meta","gp-premium"):"user-meta"===e?t=(0,i.__)("User meta","gp-premium"):"term-meta"===e&&(t=(0,i.__)("Term meta","gp-premium")),n({content:t})}}}),""!==o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{className:"gpp-blocks-dynamic-text-replace-field",type:"text",value:c}),"post-date"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Date type","gp-premium"),value:v,options:[{label:(0,i.__)("Published date","gp-premim"),value:"published-date"},{label:(0,i.__)("Updated date","gp-premium"),value:"updated-date"}],onChange:e=>{n({gpDynamicDateType:e,gpDynamicTextBefore:"",gpDynamicUpdatedDateBefore:""})}}),"published-date"===v&&(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("Replace with updated date","gp-premium"),checked:!!u,onChange:e=>{n({gpDynamicDateUpdated:e})}})),"terms"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Taxonomy","gp-premium"),value:g,options:C,onChange:e=>{n({gpDynamicTextTaxonomy:e})}}),"generateblocks/headline"===a&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{label:(0,i.__)("Term separator","gp-premium"),type:"text",value:s,onChange:e=>{n({gpDynamicTextTaxonomySeparator:e})}}))),"comments-number"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{label:(0,i.__)("No comments text","gp-premium"),type:"text",value:b,onChange:e=>{n({gpDynamicNoCommentsText:e})}}),(0,e.createElement)(p.TextControl,{label:(0,i.__)("Singular comments text","gp-premium"),type:"text",value:x,onChange:e=>{n({gpDynamicSingleCommentText:e})}}),(0,e.createElement)(p.TextControl,{label:(0,i.__)("Plural comments text","gp-premium"),help:(0,i.__)("Use % in place of the number of comments","gp-premium"),type:"text",value:h,onChange:e=>{n({gpDynamicMultipleCommentsText:e})}})),("post-meta"===o||"term-meta"===o||"user-meta"===o)&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Meta field name","gp-premium"),type:"text",value:d,onChange:e=>{n({gpDynamicTextCustomField:e})}}),"generateblocks/headline"===a&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{label:I,type:"text",value:m,onChange:e=>{n({gpDynamicTextBefore:e})}}),"post-date"===o&&!!u&&"published-date"===v&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Updated date before text","gp-premium"),type:"text",value:T,onChange:e=>{n({gpDynamicUpdatedDateBefore:e})}}))),R.length>1&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Dynamic link type","gp-premium"),value:f,options:R,onChange:e=>{"generateblocks/button"===a&&n(e?{gpDynamicLinkType:e,hasUrl:!0,url:"#"}:{gpDynamicLinkType:e,hasUrl:!1,url:""}),"generateblocks/headline"===a&&n({gpDynamicLinkType:e})}}),("post-meta"===f||"term-meta"===f||"user-meta"===f)&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Meta field name","gp-premium"),type:"text",value:y,onChange:e=>{n({gpDynamicLinkCustomField:e})}})),L&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Source","gp-premium"),value:l,options:[{label:(0,i.__)("Current post","gp-premium"),value:"current-post"},{label:(0,i.__)("Next post","gp-premium"),value:"next-post"},{label:(0,i.__)("Previous post","gp-premium"),value:"previous-post"}],onChange:e=>{n({gpDynamicSource:e})}}),("next-post"===l||"previous-post"===l)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("In same term","gp-premium"),help:(0,i.__)("Check for posts with the same term as the current post.","gp-premim"),checked:!!_,onChange:e=>{n({gpDynamicSourceInSameTerm:e})}}),!!_&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Taxonomy","gp-premium"),help:(0,i.__)("The taxonomy to check if in the same term.","gp-premim"),type:"text",value:k,onChange:e=>{n({gpDynamicSourceInSameTermTaxonomy:e})}}))))}}const h=x,f=["generateblocks/headline","generateblocks/button"],y=(0,l.createHigherOrderComponent)((t=>n=>f.includes(n.name)?(0,e.createElement)(r.Fragment,null,(0,e.createElement)(b,{...n}),(0,e.createElement)(t,{...n})):(0,e.createElement)(t,{...n})),"withClientIdClassName"),_=(0,l.createHigherOrderComponent)((t=>n=>{const{name:o,attributes:l,isSelected:g}=n,{gpDynamicTextType:s,gpDynamicLinkType:d}=l;return(0,e.createElement)(r.Fragment,null,(0,e.createElement)(t,{...n}),g&&f.includes(o)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(c.BlockControls,null,(0,e.createElement)(p.ToolbarGroup,null,(0,e.createElement)(p.Dropdown,{contentClassName:"gpp-dynamic-headline-text-dropdown",popoverProps:{className:"block-editor-block-settings-menu__popover",position:"bottom right"},renderToggle:({isOpen:t,onToggle:n})=>(0,e.createElement)(p.ToolbarButton,{icon:a("dynamic"),label:(0,i.__)("Dynamic options","gp-premium"),onClick:n,"aria-expanded":t,isPressed:!!s||!!d}),renderContent:()=>(0,e.createElement)(r.Fragment,null,(0,e.createElement)(h,{...n}))})))))}),"addDynamicHeadlineTextToolbar");function k(e,t){return!(void 0===t.attributes.gpDynamicTextType||!t.attributes.gpDynamicTextType)||e}(0,o.addFilter)("blocks.registerBlockType","gp-premium/dynamic-text/add-attributes",(function(e){return f.includes(e.name)?(void 0!==e.attributes&&(e.attributes=Object.assign(e.attributes,{gpDynamicTextType:{type:"string",default:""},gpDynamicLinkType:{type:"string",default:""},gpDynamicTextReplace:{type:"string",default:""},gpDynamicSource:{type:"string",default:"current-post"},gpDynamicSourceInSameTerm:{type:"boolean",default:!1},gpDynamicSourceInSameTermTaxonomy:{type:"string",default:"category"},gpDynamicTextTaxonomy:{type:"string",default:""},gpDynamicTextTaxonomySeparator:{type:"string",default:", "},gpDynamicTextCustomField:{type:"string",default:""},gpDynamicTextBefore:{type:"string",default:""},gpDynamicUpdatedDateBefore:{type:"string",default:""},gpDynamicDateUpdated:{type:"boolean",default:!1},gpDynamicNoCommentsText:{type:"string",default:(0,i.__)("No Comments","gp-premium")},gpDynamicSingleCommentText:{type:"string",default:(0,i.__)("1 Comment","gp-premium")},gpDynamicMultipleCommentsText:{type:"string",default:(0,i.__)("% Comments","gp-premium")},gpDynamicLinkCustomField:{type:"string",default:""},gpDynamicDateType:{type:"string",default:"published-date"}})),e):e})),(0,o.addFilter)("editor.BlockListBlock","my-plugin/with-client-id-class-name",y),(0,o.addFilter)("editor.BlockEdit","gp-premium/dynamic-headline/toolbar",_),(0,o.addFilter)("generateblocks.editor.headlineDisableFormatting","gp-premium/dynamic-headline/disable-headline-formatting",k),(0,o.addFilter)("generateblocks.editor.buttonDisableFormatting","gp-premium/dynamic-headline/disable-button-formatting",k),(0,o.addFilter)("generateblocks.editor.mainCSS","gp-premium/dynamic-headline/headline-css",(function(e,n,a){if(!["headline"].includes(a))return e;const{uniqueId:i,gpDynamicTextBefore:o,gpDynamicTextType:r}=n.attributes;return r&&o&&t(e,".gb-headline-"+i+" .gb-headline-text:before, .gb-headline-"+i+".gb-headline-text:before",{content:'"'+o+'"'}),e}));const w=window.wp.serverSideRender;var v=n.n(w);class T extends r.Component{render(){const{attributes:t,setAttributes:n}=this.props,{contentType:a,excerptLength:o,useThemeMoreLink:l,customMoreLink:g}=t;return(0,e.createElement)(r.Fragment,null,(0,e.createElement)(c.InspectorControls,null,(0,e.createElement)(p.PanelBody,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Type","gp-premium"),value:a,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Post content","gp-premium"),value:"post-content"},{label:(0,i.__)("Post excerpt","gp-premium"),value:"post-excerpt"},{label:(0,i.__)("Term description","gp-premium"),value:"term-description"},{label:(0,i.__)("Author description","gp-premium"),value:"author-description"}],onChange:e=>{n({contentType:e})}}),"post-excerpt"===a&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{label:(0,i.__)("Excerpt length","gp-premium"),type:"number",value:o||"",placeholder:gpPremiumBlockElements.excerptLength,onChange:e=>{n({excerptLength:e})},onBlur:()=>{n({excerptLength:parseInt(o)})},onClick:e=>{e.currentTarget.focus()}}),(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("Use theme more link","gp-premium"),type:"number",checked:!!l,onChange:e=>{n({useThemeMoreLink:e})}}),!l&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Custom more link","gp-premium"),type:"text",value:g||"",onChange:e=>{n({customMoreLink:e})}})))),!a&&(0,e.createElement)(p.Placeholder,{label:(0,i.__)("Dynamic content","gp-premium"),instructions:(0,i.__)("Choose your dynamic content type.","gp-premium")},(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Type","gp-premium"),value:a,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Post content","gp-premium"),value:"post-content"},{label:(0,i.__)("Post excerpt","gp-premium"),value:"post-excerpt"},{label:(0,i.__)("Term description","gp-premium"),value:"term-description"},{label:(0,i.__)("Author description","gp-premium"),value:"author-description"}],onChange:e=>{n({contentType:e})}})),"post-content"===a&&(0,e.createElement)("div",{className:"gb-entry-content"},(0,e.createElement)("p",null,(0,i.__)("This is a placeholder for your content.","gp-premium")),(0,e.createElement)("p",null,"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar ligula augue, quis bibendum tellus scelerisque venenatis. Pellentesque porta nisi mi. In hac habitasse platea dictumst. Etiam risus elit, molestie non volutpat ac, pellentesque sed eros. Nunc leo odio, sodales non tortor at, porttitor posuere dui.")),"post-excerpt"===a&&(0,e.createElement)("div",null,(0,e.createElement)(v(),{block:"generatepress/dynamic-content",attributes:t})),("author-description"===a||"term-description"===a)&&(0,e.createElement)("div",{className:"gb-description"},(0,e.createElement)("p",null,(0,i.__)("This is a placeholder for your description.","gp-premium")),(0,e.createElement)("p",null,"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar ligula augue, quis bibendum tellus scelerisque venenatis. Pellentesque porta nisi mi. In hac habitasse platea dictumst. Etiam risus elit, molestie non volutpat ac, pellentesque sed eros. Nunc leo odio, sodales non tortor at, porttitor posuere dui.")))}}const C=T,D=window.wp.blocks;(0,D.registerBlockType)("generatepress/dynamic-content",{title:(0,i.__)("Dynamic Content","gp-premium"),description:(0,i.__)("Displays dynamic content based on your chosen source.","gp-premium"),icon:a("generatepress"),category:"generatepress",keywords:[(0,i.__)("content"),(0,i.__)("dynamic content"),(0,i.__)("gp"),(0,i.__)("generate")],supports:{anchor:!1,className:!1,customClassName:!1},attributes:{contentType:{type:"string",default:""},excerptLength:{type:"number",default:gpPremiumBlockElements.excerptLength},useThemeMoreLink:{type:"boolean",default:!0},customMoreLink:{type:"string",default:""}},edit:C,save:()=>null});var R=n(184),L=n.n(R);class I extends r.Component{render(){const{attributes:t,setAttributes:n}=this.props,{imageSize:a,imageType:o,imageSource:l,customField:g,linkTo:s,linkToCustomField:d,imageWidth:m,imageHeight:u,avatarSize:b,avatarRounded:x,gpDynamicSourceInSameTerm:h,gpDynamicSourceInSameTermTaxonomy:f}=t,y=[];Object.keys(gpPremiumBlockElements.imageSizes).forEach((e=>{y.push({label:gpPremiumBlockElements.imageSizes[e],value:gpPremiumBlockElements.imageSizes[e]})}));const _=gpPremiumBlockElements.imageSizeDimensions;let k=m,w=u;k||void 0!==_[a]&&_[a].width&&(k=_[a].width),w||void 0!==_[a]&&_[a].height&&(w=_[a].height);let v=gpPremiumBlockElements.featuredImagePlaceholder;"author-avatar"!==o&&k!==w||(v=gpPremiumBlockElements.authorImagePlaceholder);const T=wp.data.select("core/editor").getEditedPostAttribute("meta");return(0,e.createElement)(r.Fragment,null,(0,e.createElement)(c.InspectorControls,null,(0,e.createElement)(p.PanelBody,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Type","gp-premium"),value:o,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Featured image","gp-premium"),value:"featured-image"},{label:(0,i.__)("Author avatar","gp-premium"),value:"author-avatar"},{label:(0,i.__)("Post meta","gp-premium"),value:"post-meta"}],onChange:e=>{n({imageType:e})}}),("featured-image"===o||"post-meta"===o)&&(0,e.createElement)(r.Fragment,null,"post-meta"===o&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Meta field name","gp-premium"),type:"text",value:g,onChange:e=>{n({customField:e})}}),"post-navigation-template"===T._generate_block_type&&(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Source","gp-premium"),value:l,options:[{label:(0,i.__)("Current post","gp-premium"),value:"current-post"},{label:(0,i.__)("Next post","gp-premium"),value:"next-post"},{label:(0,i.__)("Previous post","gp-premium"),value:"previous-post"}],onChange:e=>{n({imageSource:e})}}),("next-post"===l||"previous-post"===l)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("In same term","gp-premium"),help:(0,i.__)("Check for posts with the same term as the current post.","gp-premim"),checked:!!h,onChange:e=>{n({gpDynamicSourceInSameTerm:e})}}),!!h&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Taxonomy","gp-premium"),help:(0,i.__)("The taxonomy to check if in the same term.","gp-premim"),type:"text",value:f,onChange:e=>{n({gpDynamicSourceInSameTermTaxonomy:e})}})),(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Image size","gp-premium"),value:a,options:y,onChange:e=>{n({imageSize:e})}}),(0,e.createElement)(p.TextControl,{label:(0,i.__)("Image width","gp-premium"),type:"number",value:m||"",placeholder:k,onChange:e=>{n({imageWidth:e})},onBlur:()=>{m&&n({imageWidth:parseInt(m)})},onClick:e=>{e.currentTarget.focus()}}),(0,e.createElement)(p.TextControl,{label:(0,i.__)("Image height","gp-premium"),type:"number",value:u||"",placeholder:w,onChange:e=>{n({imageHeight:e})},onBlur:()=>{u&&n({imageHeight:parseInt(u)})},onClick:e=>{e.currentTarget.focus()}}),(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Link to","gp-premium"),value:s,options:[{label:(0,i.__)("None","gp-premium"),value:""},{label:(0,i.__)("Single post","gp-premium"),value:"single-post"},{label:(0,i.__)("Custom field","gp-premium"),value:"custom-field"}],onChange:e=>{n({linkTo:e})}}),"custom-field"===s&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Custom field name","gp-premium"),type:"text",value:d,onChange:e=>{n({linkToCustomField:e})}})),"author-avatar"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{label:(0,i.__)("Image size","gp-premium"),type:"number",value:b||"",onChange:e=>{n({avatarSize:parseInt(e)})}}),(0,e.createElement)(p.ToggleControl,{label:(0,i.__)("Make image rounded","gp-premium"),checked:!!x,onChange:e=>{n({avatarRounded:e})}})))),!o&&(0,e.createElement)(p.Placeholder,{label:(0,i.__)("Dynamic image","gp-premium"),instructions:(0,i.__)("Choose your dynamic image type.","gp-premium")},(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Type","gp-premium"),value:o,options:[{label:(0,i.__)("Choose…","gp-premium"),value:""},{label:(0,i.__)("Featured image","gp-premium"),value:"featured-image"},{label:(0,i.__)("Author avatar","gp-premium"),value:"author-avatar"},{label:(0,i.__)("Post meta","gp-premium"),value:"post-meta"}],onChange:e=>{n({imageType:e})}})),(0,e.createElement)("div",{className:"gpp-dynamic-image-preview"},(0,e.createElement)(r.Fragment,null,("featured-image"===o||"post-meta"===o)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)("div",{className:"components-gpp-dynamic-image-placeholder__label"},(0,e.createElement)(p.Icon,{icon:"format-image"})),(0,e.createElement)("img",{src:v,className:"dynamic-featured-image gpp-dynamic-image-placeholder",width:k||"",height:w||"",alt:(0,i.__)("Dynamic image placeholder","gp-premium")})),"author-avatar"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)("div",{className:"components-gpp-dynamic-image-placeholder__label"},(0,e.createElement)(p.Icon,{icon:"admin-users"})),(0,e.createElement)("img",{src:v,className:L()({"dynamic-author-image":!0,"gpp-dynamic-image-placeholder":!0,"dynamic-author-image-rounded":!!x}),width:b||null,height:b||null,alt:(0,i.__)("Dynamic image placeholder","gp-premium")})))))}}const S=I;(0,D.registerBlockType)("generatepress/dynamic-image",{title:(0,i.__)("Dynamic Image","gp-premium"),description:(0,i.__)("Displays a dynamic image from your chosen source.","gp-premium"),icon:a("generatepress"),category:"generatepress",keywords:[(0,i.__)("image"),(0,i.__)("dynamic image"),(0,i.__)("gp"),(0,i.__)("generate")],supports:{anchor:!1,className:!1,customClassName:!0},attributes:{imageType:{type:"string",default:""},imageSource:{type:"string",default:"current-post"},customField:{type:"string",default:""},gpDynamicSourceInSameTerm:{type:"boolean",default:!1},gpDynamicSourceInSameTermTaxonomy:{type:"string",default:"category"},imageSize:{type:"string",default:"full"},linkTo:{type:"string",default:""},linkToCustomField:{type:"string",default:""},imageWidth:{type:"number",default:null},imageHeight:{type:"number",default:null},avatarSize:{type:"number",default:30},avatarRounded:{type:"boolean",default:!1}},edit:S,save:()=>null});const B=window.lodash;var E=n.n(B);class M extends r.Component{render(){const{label:t,value:n,onClick:a,units:o}=this.props;return(0,e.createElement)("div",{className:"components-generatepress-units-control-header__units"},(0,e.createElement)("div",{className:"components-generatepress-units-control-label__units"},t),(0,e.createElement)("div",{className:"components-generatepress-control__units"},(0,e.createElement)(p.ButtonGroup,{className:"components-generatepress-control-buttons__units","aria-label":(0,i.__)("Select Units","gp-premium")},o.map((t=>{let o=t;return"px"===t&&(o=(0,i._x)("Pixel","A size unit for CSS markup","gp-premium")),"em"===t&&(o=(0,i._x)("Em","A size unit for CSS markup","gp-premium")),"%"===t&&(o=(0,i._x)("Percentage","A size unit for CSS markup","gp-premium")),"deg"===t&&(o=(0,i._x)("Degree","A size unit for CSS markup","gp-premium")),(0,e.createElement)(p.Tooltip -/* translators: Unit type (px, em, %) */,{text:(0,i.sprintf)((0,i.__)("%s Units","gp-premium"),o),key:t},(0,e.createElement)(p.Button,{key:t,className:"components-generatepress-control-button__units--"+t,isSmall:!0,isPrimary:n===t,"aria-pressed":n===t -/* translators: %s: values associated with CSS syntax, 'Pixel', 'Em', 'Percentage' */,"aria-label":(0,i.sprintf)((0,i.__)("%s Units","gp-premium"),o),onClick:()=>a(t)},t))})))))}}const z={template_1:{label:(0,i._x)("Two columns with featured image","label","gp-premium"),thumbnail:"post-navigation-featured-images-1.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"99fe8eb7","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"bdf9a41e","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column","alignItems":"center","justifyContent":"space-between","sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"8e5dc8f7","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","columnGap":"20px","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginBottomMobile":"10px"},"gpRemoveContainerCondition":"no-previous-post"} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSource":"previous-post","imageSize":"thumbnail","linkTo":"single-post","imageWidth":100,"imageHeight":100,"avatarSize":100} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"d54a6460","isDynamic":true,"blockVersion":4,"sizing":{"width":"75%","widthMobile":"75%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"0d00c744","element":"p","blockVersion":3,"spacing":{"marginBottom":"5px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Previous post title","gpDynamicSource":"previous-post"} --\x3e

    Previous post title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"86e1ad46","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"post-author","gpDynamicLinkType":"author-archives","gpDynamicTextReplace":"Author name","gpDynamicSource":"previous-post","gpDynamicTextBefore":"by "} --\x3e

    Author name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"2540358d","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row-reverse","flexDirectionMobile":"row","alignItems":"center","columnGap":"20px","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"typography":{"textAlignMobile":"left"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"gpRemoveContainerCondition":"no-next-post"} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSource":"next-post","imageSize":"thumbnail","linkTo":"single-post","imageWidth":100,"imageHeight":100,"avatarSize":100} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"daa456b5","isDynamic":true,"blockVersion":4,"sizing":{"width":"75%","widthMobile":"75%","height":"","maxWidth":""},"typography":{"textAlign":"right","textAlignMobile":"left"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"2883b2a4","element":"p","blockVersion":3,"spacing":{"marginBottom":"5px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Next post title","gpDynamicSource":"next-post"} --\x3e

    Next post title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"3d2e07c6","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"post-author","gpDynamicLinkType":"author-archives","gpDynamicTextReplace":"Author name","gpDynamicSource":"next-post","gpDynamicTextBefore":"by "} --\x3e

    Author name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_do_template_part"},{key:"_generate_hook_priority",value:"1"},{key:"_generate_disable_post_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!0}]},template_2:{label:(0,i._x)("Two columns with arrows","label","gp-premium"),thumbnail:"post-navigation-arrows-1.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"d1dd99b1","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"20px","paddingRight":"0px","paddingBottom":"20px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"8878e700","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column","alignItems":"center","justifyContent":"space-between","rowGapMobile":"10px","sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"9c89f761","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","columnGap":"30px","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":"","marginBottomMobile":"10px"},"gpRemoveContainerCondition":"no-previous-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"9cf413a8","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthTablet":"","widthMobile":"","height":"","maxWidth":""},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":""}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"bec8d56e","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"10px","paddingRight":"10px","paddingBottom":"10px","paddingLeft":"10px"},"backgroundColor":"#000000","backgroundColorHover":"#abb8c3","textColor":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1.5em","height":"1.5em","paddingRight":"0.5em"},"gpDynamicLinkType":"single-post","gpDynamicSource":"previous-post"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"625f3305","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthTablet":"","widthMobile":"","height":"","maxWidth":""},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":""}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"a6f36397","element":"p","blockVersion":3,"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Previous post title","gpDynamicSource":"previous-post"} --\x3e

    Previous post title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"3d262c0b","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date","gpDynamicSource":"previous-post","gpDynamicDateUpdated":true} --\x3e

    Date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"5d70717c","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"flex-end","justifyContentMobile":"flex-start","columnGap":"30px","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"typography":{"textAlign":"right","textAlignMobile":"left"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"gpRemoveContainerCondition":"no-next-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"78f3ead4","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthTablet":"","widthMobile":"","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"643cf12f","element":"p","blockVersion":3,"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Next post title","gpDynamicSource":"next-post"} --\x3e

    Next post title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"8ac35083","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date","gpDynamicSource":"next-post","gpDynamicDateUpdated":true} --\x3e

    Date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"780c810b","isDynamic":true,"blockVersion":4,"orderMobile":-1,"sizing":{"width":"","widthTablet":"","widthMobile":"","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"122d9fa4","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"10px","paddingRight":"10px","paddingBottom":"10px","paddingLeft":"10px"},"backgroundColor":"#000000","backgroundColorHover":"#abb8c3","textColor":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1.5em","height":"1.5em","paddingRight":"0.5em"},"gpDynamicLinkType":"single-post","gpDynamicSource":"next-post"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_do_template_part"},{key:"_generate_hook_priority",value:"1"},{key:"_generate_disable_post_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!0}]},template_3:{label:(0,i._x)("Two columns with background overlays","label","gp-premium"),thumbnail:"post-navigation-overlay.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"aadd0a6f","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"3642451a","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"59edc08b","backgroundColor":"#000000","textColor":"#ffffff","linkColor":"#ffffff","linkColorHover":"#e3e3e3","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"bgOptions":{"selector":"pseudo-element","opacity":0.4,"overlay":false,"position":"center center","size":"cover","repeat":"no-repeat","attachment":""},"innerZindex":1,"isDynamic":true,"blockVersion":4,"position":"relative","overflowX":"hidden","overflowY":"hidden","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"40px","paddingRight":"40px","paddingBottom":"40px","paddingLeft":"40px"},"paddingSyncUnits":true,"gpDynamicImageBg":"featured-image","gpDynamicSource":"previous-post","gpRemoveContainerCondition":"no-previous-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"a510c6c2","isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"8d3d4c12","element":"p","blockVersion":3,"display":"inline-block","typography":{"fontSize":"14px","textTransform":"uppercase"},"spacing":{"paddingTop":"5px","paddingRight":"10px","paddingBottom":"5px","paddingLeft":"10px"},"inlineWidth":true,"backgroundColor":"#cf2e2e"} --\x3e

    Previous

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"352592d1","element":"h3","blockVersion":3,"typography":{"fontSize":"25px"},"spacing":{"marginBottom":"0px"},"className":"","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World","gpDynamicSource":"previous-post"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"993a41e4","backgroundColor":"#000000","textColor":"#ffffff","linkColor":"#ffffff","linkColorHover":"#e3e3e3","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"bgOptions":{"selector":"pseudo-element","opacity":0.4,"overlay":false,"position":"center center","size":"cover","repeat":"no-repeat","attachment":""},"innerZindex":1,"isDynamic":true,"blockVersion":4,"position":"relative","overflowX":"hidden","overflowY":"hidden","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"40px","paddingRight":"40px","paddingBottom":"40px","paddingLeft":"40px"},"paddingSyncUnits":true,"gpDynamicImageBg":"featured-image","gpDynamicSource":"next-post","gpRemoveContainerCondition":"no-next-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"ea84c30e","isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"49c8845f","element":"p","blockVersion":3,"display":"inline-block","typography":{"fontSize":"14px","textTransform":"uppercase"},"spacing":{"paddingTop":"5px","paddingRight":"10px","paddingBottom":"5px","paddingLeft":"10px"},"inlineWidth":true,"backgroundColor":"#cf2e2e"} --\x3e

    Next

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"6ba8079e","element":"h3","blockVersion":3,"typography":{"fontSize":"25px"},"spacing":{"marginBottom":"0px"},"className":"","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World","gpDynamicSource":"next-post"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_do_template_part"},{key:"_generate_hook_priority",value:"1"},{key:"_generate_disable_post_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!1}]},template_4:{label:(0,i._x)("Two columns with arrows","label","gp-premium"),thumbnail:"post-navigation-arrows-2.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"96f5f0fa","innerContainer":"full","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"f9c8f86f","isDynamic":true,"blockVersion":4,"display":"flex","sizing":{"maxWidth":""},"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"5287d6da","backgroundColor":"#ffffff","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row-reverse","flexDirectionMobile":"column","justifyContent":"space-between","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"30px","paddingRight":"0px","paddingBottom":"25px","paddingLeft":"25px"},"gpRemoveContainerCondition":"no-previous-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"75cd654a","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthMobile":"100%","height":"","maxWidth":""},"typography":{"textAlignMobile":"right"},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":""}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"6acb0e83","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"15px","paddingRight":"20px","paddingBottom":"15px","paddingLeft":"20px"},"backgroundColor":"#0366d6","backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicLinkType":"single-post","gpDynamicSource":"previous-post"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"eb3b7005","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthMobile":"100%","height":"","maxWidth":""},"typography":{},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":"","paddingTopMobile":"","paddingRightMobile":"10px","paddingBottomMobile":"","paddingLeftMobile":"","marginTopMobile":"20px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"0a2d5bfc","element":"h3","blockVersion":3,"typography":{"textAlign":"left"},"spacing":{"marginBottom":"10px"},"textColor":"#000000","linkColor":"#000000","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World","gpDynamicSource":"previous-post"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"164ae39e","element":"p","blockVersion":3,"display":"flex","alignItems":"center","typography":{"fontSize":"14px"},"spacing":{"marginBottom":"0px"},"hasIcon":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicTextType":"comments-number","gpDynamicLinkType":"comments","gpDynamicTextReplace":"Comments number","gpDynamicSource":"previous-post"} --\x3e

    Comments number

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"7af8fa61","backgroundColor":"#0366d6","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column","justifyContent":"space-between","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"30px","paddingRight":"25px","paddingBottom":"25px","paddingLeft":"0px"},"gpRemoveContainerCondition":"no-next-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"045e1698","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthMobile":"100%","height":"","maxWidth":""},"typography":{},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":""}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"557abb73","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"15px","paddingRight":"20px","paddingBottom":"15px","paddingLeft":"20px"},"backgroundColor":"#ffffff","backgroundColorHover":"#222222","textColor":"#0693e3","textColorHover":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicLinkType":"single-post","gpDynamicSource":"next-post"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"9ad09f6f","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthMobile":"100%","height":"","maxWidth":""},"typography":{},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":"","paddingLeftMobile":"10px","marginTopMobile":"20px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"9ba9e9d1","element":"h3","blockVersion":3,"typography":{},"spacing":{"marginBottom":"10px"},"textColor":"#ffffff","linkColor":"#ffffff","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World","gpDynamicSource":"next-post"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"8ebf8dbe","element":"p","blockVersion":3,"display":"flex","alignItems":"center","typography":{"fontSize":"14px","textAlign":""},"spacing":{"marginBottom":"0px"},"textColor":"#ffffff","linkColor":"#ffffff","hasIcon":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicTextType":"comments-number","gpDynamicLinkType":"comments","gpDynamicTextReplace":"Comments number","gpDynamicSource":"next-post"} --\x3e

    Comments number

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_do_template_part"},{key:"_generate_hook_priority",value:"1"},{key:"_generate_disable_post_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!1}]},template_5:{label:(0,i._x)("Two columns with featured image offset","label","gp-premim"),thumbnail:"post-navigation-offset.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"52018004","innerContainer":"full","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"typography":{"textAlign":"right"},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":"","marginRight":"30px","marginLeft":"30px","marginLeftTablet":"30px","marginRightMobile":"25px","marginLeftMobile":"25px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"e54982d5","isDynamic":true,"blockVersion":4,"sizing":{"maxWidth":""},"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/grid {"uniqueId":"7bdd6853","columns":4,"horizontalGap":0,"verticalGapMobile":0,"isDynamic":true,"blockVersion":3,"useLegacyRowGap":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"4138dd74","isGrid":true,"gridId":"7bdd6853","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"verticalAlignment":"center","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"column","justifyContent":"center","sizing":{"width":"25%","widthTablet":"50%","widthMobile":"50%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"borders":{"borderBottomLeftRadius":"10px","borderTopLeftRadius":"10px","borderBottomLeftRadiusTablet":"0px","borderBottomLeftRadiusMobile":"0px","borderTopLeftRadiusMobile":"5px"},"gpDynamicImageBg":"featured-image","gpDynamicSource":"previous-post","gpRemoveContainerCondition":"no-previous-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"83fd48c9","isDynamic":true,"blockVersion":4,"typography":{"textAlign":"left"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"a3aaad4c","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"15px","paddingRight":"15px","paddingBottom":"15px","paddingLeft":"15px","marginRight":"1.5em","marginLeft":"-1.5em"},"borders":{"borderTopWidth":"7px","borderTopStyle":"solid","borderTopColor":"#f9f9f9","borderRightWidth":"7px","borderRightStyle":"solid","borderRightColor":"#f9f9f9","borderBottomWidth":"7px","borderBottomStyle":"solid","borderBottomColor":"#f9f9f9","borderLeftWidth":"7px","borderLeftStyle":"solid","borderLeftColor":"#f9f9f9","borderTopRightRadius":"100%","borderBottomRightRadius":"100%","borderBottomLeftRadius":"100%","borderTopLeftRadius":"100%"},"backgroundColor":"#b5b5b5","backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1em","height":"1em","widthMobile":"0.8em","heightMobile":"0.8em","paddingRight":"0.5em"},"gpDynamicLinkType":"single-post","gpDynamicSource":"previous-post"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"18430adf","isGrid":true,"gridId":"7bdd6853","backgroundColor":"#ffffff","isDynamic":true,"blockVersion":4,"position":"relative","zindex":2,"sizing":{"width":"25%","widthTablet":"50%","widthMobile":"50%","height":"100%","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"30px","paddingRight":"30px","paddingBottom":"30px","paddingLeft":"30px","marginRight":"10px","marginRightTablet":"0px","paddingTopMobile":"10px","paddingRightMobile":"10px","paddingBottomMobile":"10px","paddingLeftMobile":"10px","marginRightMobile":"0px"},"paddingSyncUnits":true,"borders":{"borderTopRightRadius":"10px","borderBottomRightRadius":"10px","borderBottomRightRadiusTablet":"0px","borderTopRightRadiusMobile":"5px","borderBottomRightRadiusMobile":"0px"},"gpDynamicImageBg":"featured-image","gpDynamicSource":"previous-post","gpRemoveContainerCondition":"no-previous-post"} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"2acc62a4","element":"h3","blockVersion":3,"typography":{"fontSize":"25px","textAlign":"left","fontSizeMobile":"17px"},"spacing":{"paddingTop":"10px","paddingRight":"10px","paddingBottom":"10px","paddingLeft":"10px","marginBottom":"0em","marginLeft":"-4em","marginLeftMobile":"-3em"},"paddingSyncUnits":true,"borders":{"borderBottomLeftRadius":"10px","borderTopLeftRadius":"10px","borderTopRightRadiusMobile":"5px","borderBottomRightRadiusMobile":"5px","borderBottomLeftRadiusMobile":"5px","borderTopLeftRadiusMobile":"5px"},"backgroundColor":"#ffffff","textColor":"#000000","linkColor":"#000000","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World","gpDynamicSource":"previous-post"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"ce9878f4","isGrid":true,"gridId":"7bdd6853","backgroundColor":"#ffffff","isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"width":"25%","widthTablet":"50%","widthMobile":"50%","height":"100%","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"30px","paddingRight":"30px","paddingBottom":"30px","paddingLeft":"30px","marginLeft":"10px","marginLeftTablet":"0px","paddingTopMobile":"10px","paddingRightMobile":"10px","paddingBottomMobile":"10px","paddingLeftMobile":"10px","marginLeftMobile":"0px"},"paddingSyncUnits":true,"borders":{"borderBottomLeftRadius":"10px","borderTopLeftRadius":"10px","borderTopLeftRadiusTablet":"0px","borderBottomLeftRadiusMobile":"5px","borderTopLeftRadiusMobile":"0px"},"gpDynamicImageBg":"featured-image","gpDynamicSource":"next-post","gpRemoveContainerCondition":"no-next-post"} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"9d97a37f","element":"h3","blockVersion":3,"typography":{"fontSize":"25px","textAlign":"right","fontSizeMobile":"17px"},"spacing":{"paddingTop":"10px","paddingRight":"10px","paddingBottom":"10px","paddingLeft":"10px","marginRight":"-4em","marginBottom":"0em","marginRightMobile":"-3em"},"paddingSyncUnits":true,"borders":{"borderTopRightRadius":"10px","borderBottomRightRadius":"10px","borderTopRightRadiusMobile":"5px","borderBottomRightRadiusMobile":"5px","borderBottomLeftRadiusMobile":"5px","borderTopLeftRadiusMobile":"5px"},"backgroundColor":"#ffffff","textColor":"#000000","linkColor":"#000000","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World","gpDynamicSource":"next-post"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"6c856070","isGrid":true,"gridId":"7bdd6853","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"verticalAlignment":"center","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"column","justifyContent":"center","sizing":{"width":"25%","widthTablet":"50%","widthMobile":"50%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"borders":{"borderTopRightRadius":"10px","borderBottomRightRadius":"10px","borderTopRightRadiusTablet":"0px","borderTopRightRadiusMobile":"0px","borderBottomRightRadiusMobile":"5px"},"gpDynamicImageBg":"featured-image","gpDynamicSource":"next-post","gpRemoveContainerCondition":"no-next-post"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"be12f57c","isDynamic":true,"blockVersion":4} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"139d60e4","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"15px","paddingRight":"15px","paddingBottom":"15px","paddingLeft":"15px","marginRight":"-1.5em","marginLeft":"1.5em"},"borders":{"borderTopWidth":"7px","borderTopStyle":"solid","borderTopColor":"#f9f9f9","borderRightWidth":"7px","borderRightStyle":"solid","borderRightColor":"#f9f9f9","borderBottomWidth":"7px","borderBottomStyle":"solid","borderBottomColor":"#f9f9f9","borderLeftWidth":"7px","borderLeftStyle":"solid","borderLeftColor":"#f9f9f9","borderTopRightRadius":"100%","borderBottomRightRadius":"100%","borderBottomLeftRadius":"100%","borderTopLeftRadius":"100%"},"backgroundColor":"#b5b5b5","backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1em","height":"1em","widthMobile":"0.8em","heightMobile":"0.8em","paddingRight":"0.5em"},"gpDynamicLinkType":"single-post","gpDynamicSource":"next-post"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/grid --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_do_template_part"},{key:"_generate_hook_priority",value:"1"},{key:"_generate_disable_post_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!1}]}},W={basic_1:{label:(0,i._x)("Inline with avatar","label","gp-premium"),thumbnail:"post-meta-inline.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"8a25fc79","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","sizing":{"height":"","maxWidth":""},"typography":{"fontSize":"14px"},"spacing":{"paddingTop":"15px","paddingRight":"0px","paddingBottom":"15px","paddingLeft":"0px","marginTop":"20px","marginBottom":"20px"},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#e8edf0","borderBottomWidth":"1px","borderBottomStyle":"solid","borderBottomColor":"#e8edf0"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"82a213c1","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center"} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"author-avatar","avatarRounded":true} /--\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"3fb4928a","element":"div","blockVersion":3,"display":"inline-block","spacing":{"paddingRight":"10px","marginLeft":"10px"},"inlineWidth":true,"gpDynamicTextType":"post-author","gpDynamicLinkType":"author-archives","gpDynamicTextReplace":"Author Name"} --\x3e
    Author Name
    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"f9b55781","element":"div","blockVersion":3,"display":"inline-block","spacing":{"paddingLeft":"10px"},"inlineWidth":true,"borders":{"borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#e8edf0"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date"} --\x3e
    Date
    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"8fca9ec9","element":"div","blockVersion":3,"display":"inline-flex","alignItems":"center","spacing":{"paddingLeft":"10px","marginLeft":"10px"},"inlineWidth":true,"borders":{"borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#e8edf0"},"hasIcon":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicTextType":"comments-number","gpDynamicLinkType":"comments","gpDynamicTextReplace":"Comments","gpDynamicTextTaxonomy":"category","gpDynamicNoCommentsText":"0","gpDynamicSingleCommentText":"1","gpDynamicMultipleCommentsText":"%"} --\x3e
    Comments
    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_post_meta_location",value:"after-post-title"},{key:"_generate_disable_primary_post_meta",value:!0}]},basic_2:{label:(0,i._x)("Stacked with avatar","label","gp-premium"),thumbnail:"post-meta-avatar-stacked.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"a745be15","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","columnGap":"20px","sizing":{"height":"","maxWidth":""},"typography":{"fontSize":"14px"},"spacing":{"paddingTop":"20px","paddingRight":"0px","paddingBottom":"20px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"fd4592f4","isDynamic":true,"blockVersion":4,"sizing":{"width":"10%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"author-avatar","avatarSize":120} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"137e86ad","isDynamic":true,"blockVersion":4,"sizing":{"width":"90%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"d7bb0434","element":"p","blockVersion":3,"spacing":{"marginBottom":"5px"},"gpDynamicTextType":"post-author","gpDynamicLinkType":"author-archives","gpDynamicTextReplace":"Author Name"} --\x3e

    Author Name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"759ebd2f","element":"p","blockVersion":3,"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date","gpDynamicDateUpdated":true} --\x3e

    Date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_post_meta_location",value:"after-post-title"},{key:"_generate_disable_primary_post_meta",value:!0}]},basic_3:{label:(0,i._x)("Term buttons","label","gp-premium"),thumbnail:"post-meta-term-buttons.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"7134d7c2","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","columnGap":"10px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"e378fc0b","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"13px","textAlign":"center"},"fontSize":"","spacing":{"paddingTop":"10px","paddingRight":"10px","paddingBottom":"10px","paddingLeft":"10px","marginTop":"","marginRight":"","marginBottom":"","marginLeft":""},"borders":{"borderTopRightRadius":"","borderBottomRightRadius":"","borderBottomLeftRadius":"","borderTopLeftRadius":""},"backgroundColor":"#000000","backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#ffffff","className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicLinkType":"term-archives","gpDynamicTextReplace":"Terms","gpDynamicTextTaxonomy":"category"} --\x3e Terms \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_post_meta_location",value:"before-post-title"},{key:"_generate_disable_primary_post_meta",value:!1}]}},V={template_1:{label:(0,i._x)("Full footer 1","label","gp-premium"),thumbnail:"site-footer-full-1.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"73cd57e1","backgroundColor":"#1b1b42","shapeDividers":[],"isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"140px","paddingRight":"30px","paddingBottom":"60px","paddingLeft":"30px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"7d9550dd","isDynamic":true,"blockVersion":4,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/grid {"uniqueId":"b76f312f","columns":3,"horizontalGap":80,"verticalAlignment":"center","verticalGapTablet":40,"isDynamic":true,"blockVersion":3,"useLegacyRowGap":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"53cb46e2","isGrid":true,"gridId":"b76f312f","isDynamic":true,"blockVersion":4,"sizing":{"width":"60%","widthTablet":"100%","widthMobile":"100%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"aa19f1fb","element":"h3","blockVersion":3,"textColor":"#ffffff"} --\x3e

    Reach out to us for a consultation.

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"41582601","element":"p","blockVersion":3,"spacing":{"paddingRight":"100px","paddingRightTablet":"0px"},"textColor":"#ffffff"} --\x3e

    Semper blandit suspendisse faucibus metus lobortis morbi magna vivamus per risus fermentum dapibus imperdiet praesent magnis.

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"529d5dda","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontWeight":"600","textAlign":"center"},"spacing":{"paddingTop":"10px","paddingRight":"20px","paddingBottom":"10px","paddingLeft":"20px","marginRight":"20px","marginBottomMobile":"20px"},"borders":{"borderTopWidth":"3px","borderTopStyle":"solid","borderTopColor":"#ffffff","borderTopColorHover":"rgba(242, 245, 250, 0.8)","borderRightWidth":"3px","borderRightStyle":"solid","borderRightColor":"#ffffff","borderRightColorHover":"rgba(242, 245, 250, 0.8)","borderBottomWidth":"3px","borderBottomStyle":"solid","borderBottomColor":"#ffffff","borderBottomColorHover":"rgba(242, 245, 250, 0.8)","borderLeftWidth":"3px","borderLeftStyle":"solid","borderLeftColor":"#ffffff","borderLeftColorHover":"rgba(242, 245, 250, 0.8)","borderTopRightRadius":"2px","borderBottomRightRadius":"2px","borderBottomLeftRadius":"2px","borderTopLeftRadius":"2px"},"backgroundColorHover":"#6212b3","backgroundColorHoverOpacity":0,"textColor":"#ffffff","textColorHover":"#f2f5fa"} --\x3e Contact Us \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"e1bd60bb","isGrid":true,"gridId":"b76f312f","removeVerticalGapTablet":true,"isDynamic":true,"blockVersion":4,"sizing":{"width":"20%","widthTablet":"50%","widthMobile":"100%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"37420255","element":"p","blockVersion":3,"textColor":"#ffffff"} --\x3e

    Company Name
    Address Here
    Address Here

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"bf8e162e","element":"p","blockVersion":3,"display":"flex","alignItems":"center","spacing":{"marginBottom":"0px"},"textColor":"#ffffff","linkColor":"#ffffff","linkColorHover":"#f2f5fa","hasIcon":true,"iconStyles":{"width":"1em","height":"1em","paddingTop":".1em","paddingRight":"0.5em"}} --\x3e

    +1 000 000 0000

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"c762d353","isGrid":true,"gridId":"b76f312f","removeVerticalGapTablet":true,"removeVerticalGapMobile":true,"isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","columnGap":"10px","sizing":{"width":"20%","widthTablet":"50%","widthMobile":"100%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"13c371f8","hasUrl":true,"ariaLabel":"instagram link","blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"6px","paddingRight":"6px","paddingBottom":"6px","paddingLeft":"6px","marginRight":""},"borders":{"borderTopWidth":"2px","borderTopStyle":"solid","borderTopColor":"#ffffff","borderTopColorHover":"#f2f5fa","borderRightWidth":"2px","borderRightStyle":"solid","borderRightColor":"#ffffff","borderRightColorHover":"#f2f5fa","borderBottomWidth":"2px","borderBottomStyle":"solid","borderBottomColor":"#ffffff","borderBottomColorHover":"#f2f5fa","borderLeftWidth":"2px","borderLeftStyle":"solid","borderLeftColor":"#ffffff","borderLeftColorHover":"#f2f5fa","borderTopRightRadius":"50px","borderBottomRightRadius":"50px","borderBottomLeftRadius":"50px","borderTopLeftRadius":"50px"},"backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#f2f5fa","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.8em","height":"0.8em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"926332bd","hasUrl":true,"ariaLabel":"twitter link","blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"6px","paddingRight":"6px","paddingBottom":"6px","paddingLeft":"6px","marginRight":""},"borders":{"borderTopWidth":"2px","borderTopStyle":"solid","borderTopColor":"#ffffff","borderTopColorHover":"#f2f5fa","borderRightWidth":"2px","borderRightStyle":"solid","borderRightColor":"#ffffff","borderRightColorHover":"#f2f5fa","borderBottomWidth":"2px","borderBottomStyle":"solid","borderBottomColor":"#ffffff","borderBottomColorHover":"#f2f5fa","borderLeftWidth":"2px","borderLeftStyle":"solid","borderLeftColor":"#ffffff","borderLeftColorHover":"#f2f5fa","borderTopRightRadius":"50px","borderBottomRightRadius":"50px","borderBottomLeftRadius":"50px","borderTopLeftRadius":"50px"},"backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#f2f5fa","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.8em","height":"0.8em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"d957854e","hasUrl":true,"ariaLabel":"facebook link","blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"6px","paddingRight":"6px","paddingBottom":"6px","paddingLeft":"6px"},"borders":{"borderTopWidth":"2px","borderTopStyle":"solid","borderTopColor":"#ffffff","borderTopColorHover":"#f2f5fa","borderRightWidth":"2px","borderRightStyle":"solid","borderRightColor":"#ffffff","borderRightColorHover":"#f2f5fa","borderBottomWidth":"2px","borderBottomStyle":"solid","borderBottomColor":"#ffffff","borderBottomColorHover":"#f2f5fa","borderLeftWidth":"2px","borderLeftStyle":"solid","borderLeftColor":"#ffffff","borderLeftColorHover":"#f2f5fa","borderTopRightRadius":"50px","borderBottomRightRadius":"50px","borderBottomLeftRadius":"50px","borderTopLeftRadius":"50px"},"backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#f2f5fa","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.8em","height":"0.8em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/grid --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"0f87c806","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column-reverse","alignItems":"center","justifyContent":"space-between","rowGapMobile":"20px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"60px","paddingRight":"0px","paddingBottom":"60px","paddingLeft":"0px","marginTop":"60px"},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#ffffff"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"e6861bde","isDynamic":true,"blockVersion":4,"sizing":{"width":"","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"97c10964","element":"p","blockVersion":3,"typography":{"fontSize":"17px"},"spacing":{"marginBottom":"0px"},"textColor":"#ffffff"} --\x3e

    © Company Name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"7c528044","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column","alignItems":"center","alignItemsMobile":"flex-start","columnGap":"20px","rowGapMobile":"10px","sizing":{"width":"","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"907cc664","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"17px","textAlign":"center"},"fontSize":"","spacing":{"marginRight":""},"textColor":"#ffffff","textColorHover":"#f2f5fa"} --\x3e Privacy Policy \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"a6a340bc","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"17px","textAlign":"center"},"fontSize":"","textColor":"#ffffff","textColorHover":"#f2f5fa"} --\x3e Terms of Service \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e'},template_2:{label:(0,i._x)("Full footer 2","label","gp-premium"),thumbnail:"site-footer-full-2.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"e224c1dd","backgroundColor":"#fafbfc","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"80px","paddingRight":"20px","paddingBottom":"80px","paddingLeft":"20px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"0836612c","isDynamic":true,"blockVersion":4,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"34307d45","element":"p","blockVersion":3,"typography":{"fontSize":"14px","letterSpacing":"0.3em","fontWeight":"bold","textTransform":"uppercase","textAlign":"center"},"spacing":{"marginTop":"10px"},"textColor":"#2e3d4d"} --\x3e

    Your Company Name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"4068688a","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column","alignItems":"center","rowGapMobile":"20px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"60px","paddingRight":"20px","paddingBottom":"60px","paddingLeft":"20px","marginTop":"60px","marginBottom":"60px"},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#5c7a99","borderBottomWidth":"1px","borderBottomStyle":"solid","borderBottomColor":"#5c7a99"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"12d457ad","isDynamic":true,"blockVersion":4,"sizing":{"width":"33.33%","widthMobile":"100%","height":"","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"0px","paddingRight":"20px","paddingBottom":"0px","paddingLeft":"20px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"8818b435","element":"p","blockVersion":3,"typography":{"fontSize":"13px","letterSpacing":"0.2em","fontWeight":"bold","textTransform":"uppercase"},"spacing":{"marginBottom":"0px"}} --\x3e

    PH +1 000 000 0000

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"68ec175a","isDynamic":true,"blockVersion":4,"sizing":{"width":"33.33%","widthMobile":"100%","height":"","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"0px","paddingRight":"20px","paddingBottom":"0px","paddingLeft":"20px"},"borders":{"borderRightWidth":"1px","borderRightStyle":"solid","borderRightColor":"#5c7a99","borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#5c7a99","borderTopWidthMobile":"0px","borderTopStyleMobile":"solid","borderTopColorMobile":"#5c7a99","borderRightWidthMobile":"0px","borderRightStyleMobile":"solid","borderRightColorMobile":"#5c7a99","borderBottomWidthMobile":"0px","borderBottomStyleMobile":"solid","borderBottomColorMobile":"#5c7a99","borderLeftWidthMobile":"0px","borderLeftStyleMobile":"solid","borderLeftColorMobile":"#5c7a99"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"cf4dcfab","element":"p","blockVersion":3,"typography":{"fontSize":"13px","letterSpacing":"0.2em","fontWeight":"bold","textTransform":"uppercase"},"spacing":{"marginBottom":"0px"}} --\x3e

    24 M Drive
    East Hampton, NY 11937

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"47f78435","removeVerticalGapMobile":true,"isDynamic":true,"blockVersion":4,"sizing":{"width":"33.33%","widthMobile":"100%","height":"","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"0px","paddingRight":"20px","paddingBottom":"0px","paddingLeft":"20px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"2800ad9a","hasUrl":false,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"marginRight":"20px"},"textColor":"#2e3d4d","textColorHover":"#5c7a99","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.9em","height":"0.9em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"eb98a6f6","hasUrl":false,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"marginRight":"20px"},"textColor":"#2e3d4d","textColorHover":"#5c7a99","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.9em","height":"0.9em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"ab839eb9","hasUrl":false,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"marginRight":"20px"},"textColor":"#2e3d4d","textColorHover":"#5c7a99","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.8em","height":"0.8em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"5b757c38","hasUrl":false,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"marginRight":"20px"},"textColor":"#2e3d4d","textColorHover":"#5c7a99","hasIcon":true,"removeText":true,"iconStyles":{"width":"0.8em","height":"0.8em","paddingRight":"0.5em"}} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"77c9f71e","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","flexDirectionMobile":"column","alignItems":"center","justifyContent":"space-between","rowGapMobile":"20px"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"cc32f783","isDynamic":true,"blockVersion":4,"sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"1e50faeb","element":"p","blockVersion":3,"typography":{"fontSize":"12px","letterSpacing":"0.2em","fontWeight":"bold","textTransform":"uppercase","textAlign":"left","textAlignMobile":"center"},"spacing":{"marginBottom":"0px"}} --\x3e

    © Your Copyright Message

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"b706d851","removeVerticalGapMobile":true,"isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"flex-end","justifyContentMobile":"center","columnGap":"20px","rowGap":"10px","sizing":{"width":"50%","widthMobile":"100%","height":"","maxWidth":""},"typography":{},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"373aae0d","hasUrl":false,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"12px","letterSpacing":"0.2em","fontWeight":"bold","textTransform":"uppercase","textAlign":"center"},"fontSize":"","spacing":{"marginRight":""},"textColor":"#2e3d4d","textColorHover":"#5c7a99"} --\x3e Privacy Policy \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"3cd1cf71","hasUrl":false,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"12px","letterSpacing":"0.2em","fontWeight":"bold","textTransform":"uppercase","textAlign":"center"},"fontSize":"","textColor":"#2e3d4d","textColorHover":"#5c7a99"} --\x3e Terms of Service \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e'}},q={template_1:{label:(0,i._x)("Basic layout with term buttons","label","gp-premium"),thumbnail:"content-template-basic.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"d2cafe96","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":""},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"75c01790","isDynamic":true,"blockVersion":4} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"38620841","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"13px","textAlign":"center"},"fontSize":"","spacing":{"paddingTop":"5px","paddingRight":"10px","paddingBottom":"5px","paddingLeft":"10px"},"backgroundColor":"#000000","backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#ffffff","className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicLinkType":"term-archives","gpDynamicTextReplace":"Terms","gpDynamicTextTaxonomy":"category"} --\x3e Terms \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"f593ba8c","blockVersion":3,"typography":{"fontWeight":"bold"},"spacing":{"marginBottom":"30px"},"linkColor":"#000000","linkColorHover":"#858585","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Post Title"} --\x3e

    Post Title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"1ed16867","isDynamic":true,"blockVersion":4,"display":"flex","alignItems":"center","justifyContent":"space-between","columnGap":"10px","rowGap":"10px","sizing":{"height":"","maxWidth":""},"typography":{"fontSize":"14px"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"dc72dc13","isDynamic":true,"blockVersion":4,"display":"flex","alignItems":"center","sizing":{"width":"50%","widthMobile":"50%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"author-avatar","avatarRounded":true} /--\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"c7b33e8b","element":"p","blockVersion":3,"spacing":{"marginBottom":"0px","marginLeft":"10px"},"gpDynamicTextType":"post-author","gpDynamicLinkType":"author-archives","gpDynamicTextReplace":"Author name"} --\x3e

    Author name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"ec93a944","isDynamic":true,"blockVersion":4,"sizing":{"width":"50%","widthMobile":"50%","height":"","maxWidth":""},"typography":{"textAlign":"right"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"af8af68e","element":"p","blockVersion":3,"spacing":{"marginBottom":"0px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Post date","gpDynamicDateUpdated":true} --\x3e

    Post date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"b70b46a6","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginTop":"30px","marginBottom":"30px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSize":"medium_large","linkTo":"single-post"} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt"} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"750"},{key:"_generate_use_theme_post_container",value:!0}]},template_2:{label:(0,i._x)("Layout with offset content","label","gp-premium"),thumbnail:"content-template-offset.jpg",content:'\x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSize":"large","linkTo":"single-post"} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"05e7d83e","backgroundColor":"#ffffff","isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"20px","paddingRight":"20px","paddingBottom":"20px","paddingLeft":"20px","marginTop":"-65px","marginRight":"40px","marginBottom":"20px","marginLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"83898f1c","element":"p","blockVersion":3,"typography":{"fontSize":"14px","fontWeight":"700","textTransform":"uppercase"},"spacing":{"marginBottom":"20px"},"linkColor":"#000000","linkColorHover":"#abb8c3","className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicLinkType":"term-archives","gpDynamicTextReplace":"Category","gpDynamicTextTaxonomy":"category"} --\x3e

    Category

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"98a0e67b","blockVersion":3,"typography":{"fontSize":"28px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Title"} --\x3e

    Title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt","excerptLength":25,"useThemeMoreLink":false} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"fed802f7","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"space-between","columnGap":"5px","rowGap":"5px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginTop":"20px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"74fcc8db","isDynamic":true,"blockVersion":4,"display":"flex","alignItems":"center","sizing":{"width":"66.66%","widthMobile":"66.66%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginTop":"15px"}} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"author-avatar","avatarSize":35,"avatarRounded":true} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"33ed7660","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginLeft":"10px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"2def9732","element":"p","blockVersion":3,"typography":{"fontSize":"15px"},"spacing":{"marginBottom":"0px"},"borders":{"borderRightWidth":"0px","borderRightStyle":"solid"},"gpDynamicTextType":"post-author","gpDynamicTextReplace":"Post author name"} --\x3e

    Post author name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"dd34513e","element":"p","blockVersion":3,"typography":{"fontSize":"12px"},"spacing":{"marginRight":"10px","marginBottom":"0px"},"borders":{"borderBottomWidth":"0px","borderBottomStyle":"solid"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date","gpDynamicDateUpdated":true} --\x3e

    Date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"6d144082","verticalAlignment":"center","isDynamic":true,"blockVersion":4,"sizing":{"width":"33.33%","widthMobile":"33.33%","height":"","maxWidth":""},"typography":{"textAlign":"right"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginTop":"15px"},"gpInlinePostMetaJustify":"flex-end"} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"7c89fc64","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontWeight":"700","textTransform":"uppercase","textAlign":"center"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"textColor":"#000000","textColorHover":"#abb8c3","gpDynamicLinkType":"single-post"} --\x3e More \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"500"},{key:"_generate_use_theme_post_container",value:!1}]},template_3:{label:(0,i._x)("Layout with featured image overlay","label","gp-premim"),thumbnail:"content-template-overlay.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"99e0f8fe","gradient":true,"gradientDirection":180,"gradientColorOne":"#000000","gradientColorOneOpacity":0.62,"gradientColorTwo":"#000000","gradientColorTwoOpacity":0,"gradientSelector":"pseudo-element","textColor":"#ffffff","linkColor":"#ffffff","linkColorHover":"#ffffff","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"innerZindex":1,"isDynamic":true,"blockVersion":4,"position":"relative","overflowX":"hidden","overflowY":"hidden","sizing":{"minHeight":"420px","height":"","maxWidth":""},"spacing":{"paddingTop":"20px","paddingRight":"20px","paddingBottom":"20px","paddingLeft":"20px"},"borders":{"borderTopRightRadius":"12px","borderBottomRightRadius":"12px","borderBottomLeftRadius":"12px","borderTopLeftRadius":"12px"},"gpDynamicImageBg":"featured-image"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"95ce0971","isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"864271b1","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"space-between","columnGap":"5px","rowGap":"5px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginBottom":"10px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"bc0ec4fa","element":"p","blockVersion":3,"typography":{"fontSize":"13px","fontWeight":"700","textTransform":"uppercase"},"spacing":{"marginRight":"10px","marginBottom":"0px"},"className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicTextReplace":"Category","gpDynamicTextTaxonomy":"category","gpDynamicTextTaxonomySeparator":" / "} --\x3e

    Category

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"5e2dac4c","element":"p","blockVersion":3,"display":"flex","alignItems":"center","justifyContent":"flex-end","typography":{"fontSize":"12px","textAlign":"right"},"spacing":{"marginBottom":"0px"},"hasIcon":true,"iconStyles":{"width":"1.4em","height":"1.4em","paddingRight":"0.5em"},"gpDynamicTextType":"comments-number","gpDynamicTextReplace":"COMMENTS","gpDynamicNoCommentsText":"0","gpDynamicSingleCommentText":"1","gpDynamicMultipleCommentsText":"%"} --\x3e

    COMMENTS

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"b1e898af","blockVersion":3,"typography":{"fontSize":"24px"},"marginUnit":"%","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Title"} --\x3e

    Title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"64bb1fda","isDynamic":true,"blockVersion":4,"display":"flex","justifyContent":"flex-end","spacing":{"marginTop":"300px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"95f40917","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"12px","fontWeight":"700","textTransform":"uppercase","textAlign":"center"},"fontSize":"","spacing":{"paddingTop":"10px","paddingRight":"20px","paddingBottom":"10px","paddingLeft":"20px"},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#ffffff","borderTopColorHover":"#ffffff","borderRightWidth":"1px","borderRightStyle":"solid","borderRightColor":"#ffffff","borderRightColorHover":"#ffffff","borderBottomWidth":"1px","borderBottomStyle":"solid","borderBottomColor":"#ffffff","borderBottomColorHover":"#ffffff","borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#ffffff","borderLeftColorHover":"#ffffff","borderTopRightRadius":"8px","borderBottomRightRadius":"8px","borderBottomLeftRadius":"8px","borderTopLeftRadius":"8px"},"backgroundColor":"#ffffff","backgroundColorHover":"#ffffff","backgroundColorHoverOpacity":0.75,"textColor":"#000000","textColorHover":"#000000","gpDynamicLinkType":"single-post"} --\x3e Read More \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"500"},{key:"_generate_use_theme_post_container",value:!1}]},template_4:{label:(0,i._x)("Layout with slanted shape divider","label","gp-premim"),thumbnail:"content-template-slant.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"0af7ec3a","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true,"borders":{"borderTopWidth":"0px","borderTopStyle":"solid","borderTopColor":"#000000","borderRightWidth":"0px","borderRightStyle":"solid","borderRightColor":"#000000","borderBottomWidth":"0px","borderBottomStyle":"solid","borderBottomColor":"#000000","borderLeftWidth":"0px","borderLeftStyle":"solid","borderLeftColor":"#000000"}} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSize":"large"} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"cc5683f8","shapeDividers":[{"shape":"gb-angle-1","color":"#ffffff","colorOpacity":1,"location":"bottom","height":50,"heightTablet":"","heightMobile":"","width":100,"widthTablet":"","widthMobile":"","flipHorizontally":false,"zindex":""}],"isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"height":"","maxWidth":""},"typography":{"fontSize":"14px"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginTop":"0px","marginBottom":"0px"},"paddingSyncUnits":true} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"7f6bf8cd","backgroundColor":"#ffffff","shapeDividers":[],"isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"25px","paddingBottom":"15px","paddingLeft":"25px","marginTop":"0px","marginRight":"0px","marginBottom":"0px","marginLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"7fd9c317","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginBottom":"5px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Post date","gpDynamicDateUpdated":true} --\x3e

    Post date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"a8ee15fd","blockVersion":3,"typography":{"fontSize":"30px"},"spacing":{"marginBottom":"15px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt","excerptLength":25,"useThemeMoreLink":false} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"72735d03","isDynamic":true,"blockVersion":4,"display":"flex","justifyContent":"flex-end"} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"120ee35e","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontWeight":"700","textTransform":"uppercase","textAlign":"center"},"spacing":{"paddingTop":"15px","paddingRight":"20px","paddingBottom":"15px","paddingLeft":"20px"},"backgroundColorHover":"#222222","textColor":"#000000","textColorHover":"#ffffff","gpDynamicLinkType":"single-post"} --\x3e Read More \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"500"},{key:"_generate_use_theme_post_container",value:!1}]},template_5:{label:(0,i._x)("Layout with centered content","label","gp-premim"),thumbnail:"content-template-centered.jpg",content:'\x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSize":"large"} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"5a785d21","backgroundColor":"#ffffff","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"25px","paddingRight":"25px","paddingBottom":"25px","paddingLeft":"25px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"82629d5c","blockVersion":3,"typography":{"fontSize":"25px","fontWeight":"700"},"linkColor":"#000000","gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt","excerptLength":15,"useThemeMoreLink":false} /--\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"a1b8a609","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"fontSize":"15px","textTransform":"uppercase","textAlign":"center"},"fontSize":"","spacing":{"paddingTop":"8px","paddingRight":"20px","paddingBottom":"8px","paddingLeft":"20px"},"borders":{"borderTopRightRadius":"50px","borderBottomRightRadius":"50px","borderBottomLeftRadius":"50px","borderTopLeftRadius":"50px"},"backgroundColor":"#cf2e2e","backgroundColorHover":"#222222","textColor":"#ffffff","textColorHover":"#ffffff","gpDynamicLinkType":"single-post"} --\x3e Read more \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"500"},{key:"_generate_use_theme_post_container",value:!1}]},template_6:{label:(0,i._x)("Layout with borders","label","gp-premim"),thumbnail:"content-template-borders.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"0af4cc7c","backgroundColor":"#ffffff","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"5px","paddingRight":"5px","paddingBottom":"5px","paddingLeft":"5px"},"paddingSyncUnits":true,"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#b6b6b6","borderRightWidth":"1px","borderRightStyle":"solid","borderRightColor":"#b6b6b6","borderBottomWidth":"1px","borderBottomStyle":"solid","borderBottomColor":"#b6b6b6","borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#b6b6b6","borderTopRightRadius":"2px","borderBottomRightRadius":"2px","borderBottomLeftRadius":"2px","borderTopLeftRadius":"2px"}} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSize":"large"} /--\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"b69b5c43","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"30px","paddingRight":"30px","paddingBottom":"30px","paddingLeft":"30px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"8dfa4238","element":"p","blockVersion":3,"typography":{"fontSize":"14px","fontWeight":"700","textTransform":"uppercase"},"spacing":{"marginBottom":"5px"},"textColor":"#0693e3","className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicLinkType":"term-archives","gpDynamicTextReplace":"Terms","gpDynamicTextTaxonomy":"category"} --\x3e

    Terms

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"29491daa","blockVersion":3,"typography":{"fontSize":"30px"},"spacing":{"marginBottom":"15px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Hello World"} --\x3e

    Hello World

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt","excerptLength":25,"useThemeMoreLink":false} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"d5dadc43","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"space-between","sizing":{"height":"","maxWidth":""},"typography":{"fontSize":"14px"},"spacing":{"paddingTop":"15px","paddingRight":"10px","paddingBottom":"10px","paddingLeft":"10px"},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#b6b6b6"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"2c30b1f9","isDynamic":true,"blockVersion":4,"sizing":{"width":"50%","widthMobile":"50%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"fc06eba3","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginBottom":"0px"},"textColor":"#b6b6b6","gpDynamicTextType":"post-date","gpDynamicTextReplace":"Post date","gpDynamicTextTaxonomy":"category","gpDynamicDateUpdated":true} --\x3e

    Post date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"9bb8c373","isDynamic":true,"blockVersion":4,"sizing":{"width":"50%","widthMobile":"50%","height":"","maxWidth":""},"typography":{"textAlign":"right"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"0fcad1cd","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textTransform":"uppercase","textAlign":"center"},"spacing":{"paddingTop":"8px","paddingRight":"12px","paddingBottom":"8px","paddingLeft":"12px"},"borders":{"borderTopWidth":"2px","borderTopStyle":"solid","borderTopColor":"#0693e3","borderTopColorHover":"#222222","borderRightWidth":"2px","borderRightStyle":"solid","borderRightColor":"#0693e3","borderRightColorHover":"#222222","borderBottomWidth":"2px","borderBottomStyle":"solid","borderBottomColor":"#0693e3","borderBottomColorHover":"#222222","borderLeftWidth":"2px","borderLeftStyle":"solid","borderLeftColor":"#0693e3","borderLeftColorHover":"#222222","borderTopRightRadius":"2px","borderBottomRightRadius":"2px","borderBottomLeftRadius":"2px","borderTopLeftRadius":"2px"},"backgroundColorHover":"#222222","textColor":"#0693e3","textColorHover":"#ffffff","gpDynamicLinkType":"single-post"} --\x3e Read more \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"500"},{key:"_generate_use_theme_post_container",value:!1}]},template_7:{label:(0,i._x)("Landscape layout","label","gp-premium"),thumbnail:"content-template-landscape.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"918d68ce","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"","paddingRight":"","paddingBottom":"","paddingLeft":""},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/grid {"uniqueId":"ae18e4a9","columns":2,"horizontalGap":30,"verticalGapMobile":10,"isDynamic":true,"blockVersion":3,"useLegacyRowGap":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"ff15641f","isGrid":true,"gridId":"ae18e4a9","isDynamic":true,"blockVersion":4,"sizing":{"width":"40%","widthTablet":"40%","widthMobile":"100%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"gpRemoveContainerCondition":"no-featured-image"} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"featured-image","imageSize":"medium_large","linkTo":"single-post"} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"64596747","isGrid":true,"gridId":"ae18e4a9","verticalAlignment":"center","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"column","justifyContent":"center","sizing":{"width":"60%","widthTablet":"60%","widthMobile":"100%","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"20px","paddingBottom":"10px","paddingLeft":"0px","paddingTopMobile":"10px","paddingRightMobile":"10px","paddingBottomMobile":"10px","paddingLeftMobile":"10px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"ce3f6f48","isDynamic":true,"blockVersion":4,"display":"flex","alignItems":"center","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginBottom":"10px"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"fdbba1f9","element":"p","blockVersion":3,"typography":{"fontSize":"14px","fontWeight":"900","textTransform":"uppercase"},"spacing":{"paddingRight":"10px","marginRight":"10px","marginBottom":"0px"},"borders":{"borderRightWidth":"1px","borderRightStyle":"solid"},"className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicTextReplace":"Category","gpDynamicTextTaxonomy":"category"} --\x3e

    Category

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"6df4d39e","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginRight":"10px","marginBottom":"0px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date","gpDynamicDateUpdated":true} --\x3e

    Date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"84923e14","blockVersion":3,"typography":{"fontSize":"28px"},"spacing":{"marginBottom":"20px"},"gpDynamicTextType":"title","gpDynamicLinkType":"single-post","gpDynamicTextReplace":"Title"} --\x3e

    Title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt","excerptLength":20} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/grid --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_block_element_editor_width_unit",value:"px"},{key:"_generate_block_element_editor_width",value:"800"},{key:"_generate_use_theme_post_container",value:!0}]}},P={template_1:{label:(0,i._x)("Default next and previous buttons","label","gp-premium"),thumbnail:"archive-navigation-buttons-2.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"fb6c192f","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"space-between","columnGap":"10px","rowGap":"10px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"af38c5d0","isDynamic":true,"blockVersion":4,"sizing":{"width":"50%","widthMobile":"50%","height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"aa4ef21a","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"hasIcon":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"className":"button","gpDynamicLinkType":"previous-posts"} --\x3e Previous \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"4f3ab895","isDynamic":true,"blockVersion":4,"sizing":{"width":"50%","widthMobile":"50%","height":"","maxWidth":""},"typography":{"textAlign":"right"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"84010058","hasUrl":true,"blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"hasIcon":true,"iconLocation":"right","iconPaddingRight":"","iconStyles":{"width":"1em","height":"1em","paddingLeft":"0.5em"},"className":"button","gpDynamicLinkType":"next-posts"} --\x3e Next \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_main_content"},{key:"_generate_hook_priority",value:"20"},{key:"_generate_disable_archive_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!0}]},template_2:{label:(0,i._x)("Rounded buttons with icon","label","gp-premium"),thumbnail:"archive-navigation-buttons-1.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"5edb5029","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"row","alignItems":"center","justifyContent":"center","columnGap":"10px","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"4c23c469","hasUrl":true,"ariaLabel":"Previous page","blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"20px","paddingRight":"20px","paddingBottom":"20px","paddingLeft":"20px","marginTop":"","marginRight":"","marginBottom":"","marginLeft":""},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#000000","borderRightWidth":"1px","borderRightStyle":"solid","borderRightColor":"#000000","borderBottomWidth":"1px","borderBottomStyle":"solid","borderBottomColor":"#000000","borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#000000","borderTopRightRadius":"100px","borderBottomRightRadius":"100px","borderBottomLeftRadius":"100px","borderTopLeftRadius":"100px"},"backgroundColor":"#ffffff","backgroundColorHover":"#222222","textColor":"#000000","textColorHover":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicLinkType":"previous-posts"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- wp:generateblocks/button {"uniqueId":"55622f43","hasUrl":true,"ariaLabel":"Next page","blockVersion":4,"display":"inline-flex","alignItems":"center","justifyContent":"center","typography":{"textAlign":"center"},"spacing":{"paddingTop":"20px","paddingRight":"20px","paddingBottom":"20px","paddingLeft":"20px","marginTop":"","marginRight":"","marginBottom":"","marginLeft":""},"borders":{"borderTopWidth":"1px","borderTopStyle":"solid","borderTopColor":"#000000","borderRightWidth":"1px","borderRightStyle":"solid","borderRightColor":"#000000","borderBottomWidth":"1px","borderBottomStyle":"solid","borderBottomColor":"#000000","borderLeftWidth":"1px","borderLeftStyle":"solid","borderLeftColor":"#000000","borderTopRightRadius":"100px","borderBottomRightRadius":"100px","borderBottomLeftRadius":"100px","borderTopLeftRadius":"100px"},"backgroundColor":"#ffffff","backgroundColorHover":"#222222","textColor":"#000000","textColorHover":"#ffffff","hasIcon":true,"removeText":true,"iconStyles":{"width":"1em","height":"1em","paddingRight":"0.5em"},"gpDynamicLinkType":"next-posts"} --\x3e \x3c!-- /wp:generateblocks/button --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_main_content"},{key:"_generate_hook_priority",value:"20"},{key:"_generate_disable_archive_navigation",value:!0},{key:"_generate_use_archive_navigation_container",value:!1}]}},A={template_1:{label:(0,i._x)("Basic single post page hero","label","gp-premium"),thumbnail:"page-hero-basic.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"8b6d1c4b","backgroundColor":"#000000","textColor":"#ffffff","linkColor":"#ffffff","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"bgOptions":{"selector":"pseudo-element","opacity":0.3,"overlay":false,"position":"center center","size":"cover","repeat":"no-repeat","attachment":""},"innerZindex":1,"isDynamic":true,"blockVersion":4,"position":"relative","overflowX":"hidden","overflowY":"hidden","sizing":{"height":"","maxWidth":""},"typography":{"textAlign":"center"},"spacing":{"paddingTop":"150px","paddingRight":"40px","paddingBottom":"150px","paddingLeft":"40px"},"gpDynamicImageBg":"featured-image"} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"3f517a84","isDynamic":true,"blockVersion":4,"position":"relative","zindex":1,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"62a8b2cc","element":"h1","blockVersion":3,"typography":{"fontSize":"50px"},"gpDynamicTextType":"title","gpDynamicTextReplace":"Page Title"} --\x3e

    Page Title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"f49b9f49","isDynamic":true,"blockVersion":4,"display":"flex","alignItems":"center","justifyContent":"center","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generatepress/dynamic-image {"imageType":"author-avatar","avatarRounded":true} /--\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"2e715b13","element":"p","blockVersion":3,"spacing":{"marginBottom":"0px","marginLeft":"10px"},"gpDynamicTextType":"post-author","gpDynamicTextReplace":"Author name"} --\x3e

    Author name

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"dedbe2c8","element":"p","blockVersion":3,"spacing":{"paddingLeft":"20px","marginBottom":"0px","marginLeft":"20px"},"borders":{"borderLeftWidth":"1px","borderLeftStyle":"solid"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Post date","gpDynamicDateUpdated":true} --\x3e

    Post date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_header"},{key:"_generate_disable_title",value:!0},{key:"_generate_disable_featured_image",value:!0},{key:"_generate_disable_primary_post_meta",value:!0}]},template_2:{label:(0,i._x)("Single post hero with excerpt","label","gp-premium"),thumbnail:"page-hero-excerpt.jpg",content:'\x3c!-- wp:generateblocks/container {"uniqueId":"70385d72","isDynamic":true,"blockVersion":4,"sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"80px","paddingRight":"40px","paddingBottom":"80px","paddingLeft":"40px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"01bfa731","isDynamic":true,"blockVersion":4,"sizing":{"maxWidth":""},"useGlobalMaxWidth":true,"spacing":{"marginRight":"auto","marginLeft":"auto"}} --\x3e \x3c!-- wp:generateblocks/grid {"uniqueId":"5dc55b95","columns":2,"horizontalGap":80,"verticalGap":20,"isDynamic":true,"blockVersion":3,"useLegacyRowGap":true} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"579e5b87","isGrid":true,"gridId":"5dc55b95","verticalAlignment":"center","isDynamic":true,"blockVersion":4,"display":"flex","flexDirection":"column","justifyContent":"center","sizing":{"width":"45%","widthTablet":"60%","widthMobile":"100%","height":"100%","maxWidth":""},"typography":{"fontSize":"14px"},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"}} --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"d909e043","isDynamic":true,"blockVersion":4,"display":"flex","alignItems":"center","sizing":{"height":"","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px","marginBottom":"10px"},"paddingSyncUnits":true} --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"9fdb86dc","element":"p","blockVersion":3,"typography":{"fontSize":"14px","fontWeight":"900","textTransform":"uppercase"},"spacing":{"paddingRight":"10px","marginRight":"10px","marginBottom":"0px"},"borders":{"borderRightWidth":"1px","borderRightStyle":"solid"},"textColor":"#000000","linkColor":"#000000","className":"dynamic-term-class","gpDynamicTextType":"terms","gpDynamicLinkType":"term-archives","gpDynamicTextReplace":"Category","gpDynamicTextTaxonomy":"category"} --\x3e

    Category

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"1ee4cbcf","element":"p","blockVersion":3,"typography":{"fontSize":"14px"},"spacing":{"marginRight":"10px","marginBottom":"0px"},"gpDynamicTextType":"post-date","gpDynamicTextReplace":"Date","gpDynamicDateUpdated":true} --\x3e

    Date

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/headline {"uniqueId":"56c7eb13","blockVersion":3,"spacing":{"marginBottom":"10px"},"gpDynamicTextType":"title","gpDynamicTextReplace":"Title"} --\x3e

    Title

    \x3c!-- /wp:generateblocks/headline --\x3e \x3c!-- wp:generatepress/dynamic-content {"contentType":"post-excerpt","useThemeMoreLink":false} /--\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- wp:generateblocks/container {"uniqueId":"4e92c4e8","isGrid":true,"gridId":"5dc55b95","bgImage":{"id":"","image":{"url":"#dynamic-background-image"}},"bgOptions":{"selector":"element","opacity":1,"overlay":false,"position":"center center","size":"cover","repeat":"no-repeat","attachment":""},"isDynamic":true,"blockVersion":4,"sizing":{"width":"55%","widthTablet":"40%","widthMobile":"100%","minHeight":"400px","minHeightMobile":"250px","height":"100%","maxWidth":""},"spacing":{"paddingTop":"0px","paddingRight":"0px","paddingBottom":"0px","paddingLeft":"0px"},"gpDynamicImageBg":"featured-image","gpUseFallbackImageBg":true} /--\x3e \x3c!-- /wp:generateblocks/grid --\x3e \x3c!-- /wp:generateblocks/container --\x3e \x3c!-- /wp:generateblocks/container --\x3e',meta:[{key:"_generate_hook",value:"generate_after_header"},{key:"_generate_disable_title",value:!0},{key:"_generate_disable_featured_image",value:!0},{key:"_generate_disable_primary_post_meta",value:!0}]}},H=window.wp.plugins,j=window.wp.editPost,N=window.wp.data,F=window.wp.domReady;var U=n.n(F),G=n(893);function O(e,t){return String(e)===String(t)}function J(e,t){return Array.isArray(e)?e.map((e=>t.find((t=>O(t.value,e))))).filter((e=>e)):t.find((t=>O(t.value,e)))||null}function $(e){return Array.isArray(e)?e:[e]}function Y(e,t,n){if(!e&&!n)return t&&t.length&&t[0].name||"";const a=Array.isArray(e);return e||a?a?e.map((e=>e.name)).filter(Boolean).join(", "):e.name||"":""}function K(e){return e?Array.isArray(e)?e.filter(Boolean).map((e=>e.value)):e.value||null:null}function X(e,t){return t.length?e.filter((e=>function(e,t){const n=e.length,a=t.length;if(n>a)return!1;if(t.indexOf(e)>=0)return!0;e:for(let i=0,o=0;i"group"===e.type?e.items.map((n=>({...n,group:e.name,index:t++}))):{...e,index:t++})).flat()}const Q=()=>{};function ee({options:t,defaultValue:n,value:a,multiple:i,search:o,onChange:r=Q,onFocus:p=Q,onBlur:l=Q,closeOnSelect:c=!0,placeholder:g,getOptions:s,filterOptions:d,useFuzzySearch:m=!0,debounce:u}){const b=(0,e.useRef)(),[x,h]=(0,e.useState)(null),[f,y]=(0,e.useState)(""),[_,k]=(0,e.useState)(!1),[w,v]=function(t,n,a,i){const[o,r]=(0,e.useState)((()=>Z(t))),[p,l]=(0,e.useState)(!1);return(0,e.useEffect)((()=>{let e;if(n)return e=setTimeout((()=>{const e=n(i,o);l(!0),Promise.resolve(e).then((e=>r(Z(e)))).finally((()=>l(!1)))}),a),()=>{clearTimeout(e)}}),[i]),(0,e.useEffect)((()=>{r(Z(t))}),[t]),[o,p]}(t,s,u,f),T=e=>{const t=function(e,t,n){if(!e)return t;if(!n)return e;if(!t)return $(e);const a=$(t),i=a.findIndex((t=>O(t.value,e.value)));return i>=0?a.splice(i,1):a.push(e),a}(J(decodeURIComponent(e),w),x,i);void 0===a&&h(t),r(K(t),t),setTimeout((()=>{b.current&&c&&b.current.blur()}),0)},C=function(e){const t=[];return e.forEach((e=>{if(e.group){const n=t.findIndex((t=>"group"===t.type&&t.name===e.group));n>=0?t[n].items.push(e):t.push({items:[e],type:"group",name:e.group})}else t.push(e)})),t}((E=[m?X:null,...d||[]],M=w,z=f,E.filter(Boolean).reduce(((e,t)=>t(e,z)),M).map(((e,t)=>({...e,index:t}))))),[D,R,L]=function(t,n,a){const[i,o]=(0,e.useState)(-1);return[{onKeyDown:e=>{const n=e.key.replace("Arrow","").toLowerCase();"down"!==n&&"up"!==n||(e.preventDefault(),o(function(e,t,n){const a=n.length-1;let i=null,o=-1,r=e;for(;o++<=a&&(!i||i.disabled);)r="down"===t?r+1:r-1,r<0?r=a:r>a&&(r=0),i=n[r];return r}(i,n,t)))},onKeyUp:e=>{"Escape"===e.key?(e.preventDefault(),a.current.blur()):"Enter"===e.key&&(e.preventDefault(),t[i]&&n(t[i].value))}},i,o]}(C,T,b),I={search:f,focus:_,option:x,value:K(x),fetching:v,highlighted:R,options:C,displayValue:Y(x,w,g)},S={tabIndex:"0",readOnly:!o,placeholder:g,value:_&&o?f:I.displayValue,ref:b,...D,onFocus:e=>{k(!0),p(e)},onBlur:e=>{k(!1),y(""),L(-1),l(e)},onMouseDown:e=>{_&&(e.preventDefault(),b.current.blur())},onChange:o?({target:e})=>y(e.value):null},B={tabIndex:"-1",onMouseDown(e){e.preventDefault(),T(e.currentTarget.value)}};var E,M,z;return(0,e.useEffect)((()=>{h(J(void 0===a?n:a,w))}),[a,w]),[I,S,B]}const te=e=>"string"==typeof e,ne=(e,t)=>te(t)?`${t}-${e}`:t[e];function ae({optionProps:e,highlighted:t,selected:n,option:a,cls:i,renderOption:o,disabled:r}){const p={...e,value:encodeURIComponent(a.value),disabled:r},l=i({option:!0,"is-selected":n,"is-highlighted":t});return(0,G.jsxs)("li",{className:i("row"),role:"menuitem","data-index":a.index,children:[o&&o(p,a,{selected:n,highlighted:t},l),!o&&(0,G.jsx)("button",{type:"button",className:l,...p,children:a.name})]})}var ie=(0,e.memo)(ae);function oe(e){const{options:t,cls:n,renderOption:a,renderGroupHeader:i,optionProps:o,snapshot:r,disabled:p}=e;return(0,G.jsx)("ul",{className:n("options"),children:t.map((t=>{return"group"===t.type?(0,G.jsx)("li",{role:"none",className:n("row"),children:(0,G.jsxs)("div",{className:n("group"),children:[(0,G.jsx)("div",{className:n("group-header"),children:i?i(t.name):t.name}),(0,G.jsx)(oe,{...e,options:t.items})]})},t.name):(0,G.jsx)(ie,{option:t,optionProps:o,cls:n,renderOption:a,selected:(l=t,c=r.option,!!c&&(Array.isArray(c)?c.findIndex((e=>e.value===l.value))>=0:c.value===l.value)),highlighted:r.highlighted===t.index,disabled:t.disabled||p},t.value);var l,c}))})}var re=(0,e.memo)(oe);const pe=(0,e.forwardRef)((({disabled:t,placeholder:n,multiple:a,search:i,autoFocus:o,autoComplete:r,id:p,closeOnSelect:l,className:c,renderValue:g,renderOption:s,renderGroupHeader:d,fuzzySearch:m,emptyMessage:u,value:b,...x},h)=>{const f=(0,e.useRef)(null),y=e=>function(e,t){return te(e)?ne(e,t):Object.entries(e).filter((([e,t])=>e&&t)).map((([e])=>ne(e,t))).join(" ")}(e,c),[_,k]=(0,e.useState)(b),[w,v,T]=ee({value:_,placeholder:n,multiple:a,search:i,closeOnSelect:l&&!a,useFuzzySearch:m,...x}),{highlighted:C,value:D,fetching:R,focus:L}=w,I={...v,autoFocus:o,autoComplete:r,disabled:t};return(0,e.useEffect)((()=>{const{current:e}=f;if(e){const t=Array.isArray(D)?D[0]:D,n=e.querySelector(C>-1?`[data-index="${C}"]`:`[value="${encodeURIComponent(t)}"]`);if(n){const t=e.getBoundingClientRect(),a=n.getBoundingClientRect();e.scrollTop=n.offsetTop-t.height/2+a.height/2}}}),[D,C,f.current]),(0,e.useEffect)((()=>k(b)),[b]),(0,G.jsxs)("div",{ref:h,id:p,className:y({container:!0,"is-multiple":a,"is-disabled":t,"is-loading":R,"has-focus":L}),children:[(!a||n||i)&&(0,G.jsxs)("div",{className:y("value"),children:[g&&g(I,w,y("input")),!g&&(0,G.jsx)("input",{...I,className:y("input")})]}),(0,G.jsxs)("div",{className:y("select"),ref:f,onMouseDown:e=>e.preventDefault(),children:[w.options.length>0&&(0,G.jsx)(re,{options:w.options,optionProps:T,renderOption:s,renderGroupHeader:d,disabled:t,snapshot:w,cls:y}),!w.options.length&&(0,G.jsx)("ul",{className:y("options"),children:!w.options.length&&u&&(0,G.jsx)("li",{className:y("not-found"),children:u})})]})]})}));pe.defaultProps={options:[],fuzzySearch:!0,printOptions:"auto",closeOnSelect:!0,debounce:250,autoComplete:"on",className:"select-search"},pe.displayName="SelectSearch";var le=(0,e.memo)(pe);function ce(t){return(0,e.createElement)("div",{className:"gp-select-search"},(0,e.createElement)(le,{...t}))}class ge extends r.Component{constructor(){super(...arguments),this.getWidth=this.getWidth.bind(this),this.state={installingPlugin:!1,pluginInstalled:!1}}componentDidMount(){const e=document.createElement("style");e.id="gp-block-elements-css",document.head.appendChild(e),e.innerHTML=`html {--gp-block-element-width: ${this.getWidth().width}${this.getWidth().unit}}`;const t=document.querySelector(".editor-styles-wrapper");if(t?.style?.setProperty("--content-width",this.getWidth().width+this.getWidth().unit),"undefined"!==wp.data.select("core/edit-post").getPreference("panels")["generatepress-block-element/generatepress-block-element"]){const e=wp.data.select("core/edit-post").getPreference("panels")["generatepress-block-element/generatepress-block-element"];void 0!==e&&e.opened||wp.data.dispatch("core/edit-post").toggleEditorPanelOpened("generatepress-block-element/generatepress-block-element")}if(this.props.meta._generate_block_type||this.props.updateMeta({_generate_block_type:"hook"}),"undefined"!==wp.data.select("core/edit-post").getPreference("panels")["page-attributes"]){const e=wp.data.select("core/edit-post").getPreference("panels")["page-attributes"];void 0===e||!e.enabled&&void 0!==e.enabled||wp.data.dispatch("core/edit-post").toggleEditorPanelEnabled("page-attributes")}this.props.elementParent&&document.body.classList.add("element-has-parent")}componentDidUpdate(){document.getElementById("gp-block-elements-css").innerHTML=`html {--gp-block-element-width: ${this.getWidth().width}${this.getWidth().unit}}`;const e=document.querySelector(".editor-styles-wrapper");e?.style?.setProperty("--content-width",this.getWidth().width+this.getWidth().unit);const t=wp.data.select("core/editor").getEditedPostAttribute("meta");if("content-template"===t._generate_block_type&&(t._generate_use_theme_post_container?document.body.classList.contains("using-theme-post-container")||document.body.classList.add("using-theme-post-container"):document.body.classList.contains("using-theme-post-container")&&document.body.classList.remove("using-theme-post-container")),"archive-navigation-template"!==t._generate_block_type&&"post-navigation-template"!==t._generate_block_type||(t._generate_use_archive_navigation_container?document.body.classList.contains("using-theme-pagination-container")||document.body.classList.add("using-theme-pagination-container"):document.body.classList.contains("using-theme-pagination-container")&&document.body.classList.remove("using-theme-pagination-container")),"undefined"!==wp.data.select("core/edit-post").getPreference("panels")["page-attributes"]){const e=wp.data.select("core/edit-post").getPreference("panels")["page-attributes"];void 0!==e&&e.enabled&&wp.data.dispatch("core/edit-post").toggleEditorPanelEnabled("page-attributes")}!this.props.elementParent&&!t._generate_post_loop_item_display||document.body.classList.contains("element-has-parent")?this.props.elementParent&&t._generate_post_loop_item_display||!document.body.classList.contains("element-has-parent")||document.body.classList.remove("element-has-parent"):document.body.classList.add("element-has-parent")}getWidth(){const e=wp.data.select("core/editor").getEditedPostAttribute("meta");let t=100,n="%";return"left-sidebar"===e._generate_block_type&&(t=gpPremiumBlockElements.leftSidebarWidth,n="px"),"right-sidebar"===e._generate_block_type&&(t=gpPremiumBlockElements.rightSidebarWidth,n="px"),"content-template"!==e._generate_block_type&&"post-meta-template"!==e._generate_block_type&&"post-navigation-template"!==e._generate_block_type||(t=gpPremiumBlockElements.contentWidth,n="px"),e._generate_block_element_editor_width&&(t=wp.data.select("core/editor").getEditedPostAttribute("meta")._generate_block_element_editor_width),e._generate_block_element_editor_width_unit&&(n=wp.data.select("core/editor").getEditedPostAttribute("meta")._generate_block_element_editor_width_unit),{width:t,unit:n}}render(){const{meta:{_generate_block_element_editor_width:t,_generate_block_element_editor_width_unit:n,_generate_block_type:o,_generate_hook:l,_generate_custom_hook:c,_generate_hook_priority:g,_generate_post_loop_item_tagname:s,_generate_post_meta_location:d,_generate_disable_primary_post_meta:m,_generate_disable_secondary_post_meta:u,_generate_disable_title:b,_generate_disable_featured_image:x,_generate_use_theme_post_container:h,_generate_post_loop_item_display:f,_generate_post_loop_item_display_tax:y,_generate_post_loop_item_display_term:_,_generate_post_loop_item_display_post_meta:k,_generate_disable_post_navigation:w,_generate_disable_archive_navigation:v,_generate_use_archive_navigation_container:T}={},updateMeta:C,updateParentId:R,updateOrder:L,elementParent:I,elementMenuOrder:S}=this.props,B=[];Object.keys(gpPremiumBlockElements.hooks).forEach((e=>{const t=[],n=gpPremiumBlockElements.hooks[e].group,a=gpPremiumBlockElements.hooks[e].hooks;Object.keys(a).forEach((e=>{t.push({value:a[e],name:a[e].replace("generate_","").replace("woocommerce_","")})})),B.push({type:"group",name:n,items:t})})),B.push({type:"group",name:(0,i.__)("Custom","gp-premium"),items:[{value:"custom",name:(0,i.__)("Custom Hook","gp-premium")}]});const H=[{label:(0,i.__)("Choose…","gp-premium"),value:""}],N=gpPremiumBlockElements.taxonomies;N&&Object.keys(N).forEach((e=>{H.push({label:N[e],value:N[e]})}));const F=[{label:(0,i.__)("Choose…","gp-premium"),value:""}];"page-hero"===o&&F.push({label:(0,i.__)("After header","gp-premium"),value:"generate_after_header"},{label:(0,i.__)("Before content container","gp-premium"),value:"generate_before_main_content"},{label:(0,i.__)("Before content","gp-premium"),value:"generate_before_content"}),"post-navigation-template"===o&&F.push({label:(0,i.__)("After content","gp-premium"),value:"generate_after_content"},{label:(0,i.__)("After content container","gp-premium"),value:"generate_after_do_template_part"});let U="";"post-navigation-template"===o&&(U=z),"post-meta-template"===o&&(U=W),"site-footer"===o&&(U=V),"content-template"===o&&(U=q),"archive-navigation-template"===o&&(U=P),"page-hero"===o&&(U=A);const G=[],O=gpPremiumBlockElements.parentElements;return O&&Object.keys(O).forEach((e=>{G.push({label:O[e].label,value:O[e].id})})),(0,e.createElement)(r.Fragment,null,(0,e.createElement)(j.PluginDocumentSettingPanel,{name:"generatepress-block-element",title:(0,i.__)("Block Element","gp-premium"),className:"gpp-block-element-panel gpp-element-panel-label",icon:a("generatepress")},!gpPremiumBlockElements.isGenerateBlocksActive&&(0,e.createElement)(p.BaseControl,null,(0,e.createElement)("p",null,(0,i.__)("To take full advantage of Block Elements, we suggest using our GenerateBlocks plugin.","gp-premium")),gpPremiumBlockElements.isGenerateBlocksInstalled?(0,e.createElement)("a",{href:gpPremiumBlockElements.activateLink,className:"components-button is-primary"},(0,i.__)("Activate GenerateBlocks","gp-premium")):(0,e.createElement)("a",{href:gpPremiumBlockElements.installLink,className:"components-button is-primary"},(0,i.__)("Install GenerateBlocks","gp-premium"))),(0,e.createElement)(M,{label:(0,i.__)("Editor width","gp-premium"),value:n||this.getWidth().unit,units:["px","%"],onClick:e=>{C({_generate_block_element_editor_width_unit:e||""})}}),(0,e.createElement)(p.TextControl,{type:"number",onChange:e=>{C({_generate_block_element_editor_width:e||""})},placeholder:this.getWidth().width,value:t||""}),(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Element type","gp-premium"),value:o,options:[{label:(0,i.__)("Hook","gp-premium"),value:"hook"},{label:(0,i.__)("Site Header","gp-premium"),value:"site-header"},{label:(0,i.__)("Page Hero","gp-premium"),value:"page-hero"},{label:(0,i.__)("Content Template","gp-premium"),value:"content-template"},{label:(0,i.__)("Loop Template","gp-premium"),value:"loop-template"},{label:(0,i.__)("Post Meta Template","gp-premium"),value:"post-meta-template"},{label:(0,i.__)("Post Navigation","gp-premium"),value:"post-navigation-template"},{label:(0,i.__)("Archive Navigation","gp-premium"),value:"archive-navigation-template"},{label:(0,i.__)("Right Sidebar","gp-premium"),value:"right-sidebar"},{label:(0,i.__)("Left Sidebar","gp-premium"),value:"left-sidebar"},{label:(0,i.__)("Site Footer","gp-premium"),value:"site-footer"},{label:(0,i.__)("Search Modal","gp-premium"),value:"search-modal"}],onChange:e=>{document.body.classList.remove(o+"-block-type"),document.body.classList.add(e+"-block-type"),C("page-hero"===e?{_generate_block_type:e,_generate_hook:"generate_after_header",_generate_block_element_editor_width_unit:"%",_generate_block_element_editor_width:"100"}:"post-navigation-template"===e?{_generate_block_type:e,_generate_hook:"generate_after_do_template_part",_generate_block_element_editor_width_unit:"%",_generate_block_element_editor_width:"100"}:"archive-navigation-template"===e?{_generate_block_type:e,_generate_hook:"generate_after_main_content",_generate_hook_priority:"20",_generate_block_element_editor_width_unit:"%",_generate_block_element_editor_width:"100"}:{_generate_block_type:e,_generate_block_element_editor_width_unit:"",_generate_block_element_editor_width:""})}}),gpPremiumBlockElements.isGenerateBlocksActive&&!!U&&(0,e.createElement)(p.BaseControl,null,(0,e.createElement)(p.PanelBody,{initialOpen:!1,name:"generatepress-block-element-templates",title:(0,i.__)("Templates","gp-premium"),className:"gpp-block-element-template-panel"},Object.keys(U).map((t=>(0,e.createElement)("button",{key:t,className:"gpp-block-elements-template-button",onClick:()=>{U[t].content=U[t].content.replaceAll("#dynamic-background-image",gpPremiumBlockElements.bgImageFallback);const e=(0,D.parse)(U[t].content),n=wp.data.select("core/block-editor").getBlocks();let a=!1;1===n.length&&("core/paragraph"!==n[0].name||n[0].attributes.content||(a=!0)),e.length&&(a?wp.data.dispatch("core/block-editor").replaceBlocks(n[0].clientId,e):wp.data.dispatch("core/block-editor").insertBlocks(e));const i=U[t].meta,o={};i&&i.forEach((e=>{o[e.key]=e.value})),Object.keys(o).length>0&&C(o)}},void 0!==U[t].thumbnail&&!!U[t].thumbnail&&(0,e.createElement)("img",{src:gpPremiumBlockElements.templateImageUrl+"/"+U[t].thumbnail,alt:U[t].label}),(0,e.createElement)("div",{className:"gpp-block-template-label"},U[t].label)))))),("right-sidebar"===o||"left-sidebar"===o)&&(0,e.createElement)(p.Notice,{status:"info",isDismissible:!1,className:"gpp-block-element-notice"},(0,i.__)("This will remove the current sidebar widgets for the selected sidebar. Your layout must have a sidebar set for this Element to show.","gp-premium")),"site-footer"===o&&(0,e.createElement)(p.BaseControl,null,(0,e.createElement)(p.Notice,{status:"info",isDismissible:!1,className:"gpp-block-element-notice"},(0,i.__)("This Element will replace your site footer area that holds your copyright message. It will not replace footer widgets if they exist.","gp-premium"))),"post-meta-template"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Location","gp-premium"),value:d,options:[{label:(0,i.__)("After post title","gp-premium"),value:"after-post-title"},{label:(0,i.__)("Before post title","gp-premium"),value:"before-post-title"},{label:(0,i.__)("After content","gp-premium"),value:"after-content"},{label:(0,i.__)("Custom","gp-premium"),value:"custom"}],onChange:e=>{C({_generate_post_meta_location:e})}})),F.length>1&&(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Quick hook select","gp-premium"),value:l||"",options:F,onChange:e=>{C({_generate_hook:e})}}),(!o||"hook"===o||"page-hero"===o||"post-navigation-template"===o||"archive-navigation-template"===o||"post-meta-template"===o&&"custom"===d)&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.BaseControl,{id:"gpp-hook-select",label:(0,i.__)("Hook name","gp-premium"),className:"gpp-hook-select"},(0,e.createElement)(ce,{options:B,value:l,placeholder:(0,i.__)("Choose your hook","gp-premium"),search:!0,onChange:e=>{e!==l&&C({_generate_hook:e||""})}})),"custom"===l&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Custom hook name","gp-premium"),type:"text",onChange:e=>{C({_generate_custom_hook:e||""})},value:c||""}),!!l&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Priority","gp-premium"),type:"text",onChange:e=>{C({_generate_hook_priority:e||""})},value:g||"",placeholder:"10"})),"post-meta-template"===o&&(0,e.createElement)(r.Fragment,null,(""===d||"after-post-title"===d||"before-post-title"===d||"custom"===d)&&(0,e.createElement)(p.ToggleControl,{checked:!!m,label:(0,i.__)("Replace default primary post meta","gp-premium"),onChange:e=>{C({_generate_disable_primary_post_meta:e})}}),("after-content"===d||"custom"===d)&&(0,e.createElement)(p.ToggleControl,{checked:!!u,label:(0,i.__)("Replace default secondary post meta","gp-premium"),onChange:e=>{C({_generate_disable_secondary_post_meta:e})}})),"content-template"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Tag name","gp-premium"),value:s,options:[{label:"article",value:"article"},{label:"div",value:"div"},{label:"section",value:"section"},{label:"aside",value:"aside"}],onChange:e=>{C({_generate_post_loop_item_tagname:e})}}),(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Apply to","gp-premium"),value:f,options:[{label:(0,i.__)("All posts","gp-premium"),value:""},{label:(0,i.__)("Posts with term","gp-premium"),value:"has-term"},{label:(0,i.__)("Posts with custom field","gp-premium"),value:"has-post-meta"},{label:(0,i.__)("First post","gp-premium"),value:"is-first-post"}],onChange:e=>{C({_generate_post_loop_item_display:e})}}),""!==f&&(0,e.createElement)(r.Fragment,null,"has-term"===f&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.SelectControl,{label:(0,i.__)("Taxonomy","gp-premium"),value:y,options:H,onChange:e=>{C({_generate_post_loop_item_display_tax:e})}}),!!y&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Term name","gp-premium"),type:"text",onChange:e=>{C({_generate_post_loop_item_display_term:e||""})},value:_||""})),"has-post-meta"===f&&(0,e.createElement)(p.TextControl,{label:(0,i.__)("Post meta name","gp-premium"),type:"text",onChange:e=>{C({_generate_post_loop_item_display_post_meta:e||""})},value:k||""}),G.length>0&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.BaseControl,null,(0,e.createElement)(p.ComboboxControl,{className:"editor-page-attributes__parent",label:(0,i.__)("Parent Element","gp-premium"),help:(0,i.__)("Set a parent Element to inherit in case the above conditions do not apply.","gp-premim"),value:I,options:G,onFilterValueChange:e=>{e&&E()(R(e),300)},onChange:e=>{R(e)}})),!!I&&(0,e.createElement)(p.TextControl,{type:"number",label:(0,i.__)("Display Order","gp-premium"),onChange:e=>{L(e)},value:S}))),(0,e.createElement)(p.ToggleControl,{checked:!!h,label:(0,i.__)("Keep default post container","gp-premium"),onChange:e=>{C({_generate_use_theme_post_container:e})}})),"page-hero"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{checked:!!b,label:(0,i.__)("Disable title","gp-premium"),onChange:e=>{C({_generate_disable_title:e})}}),(0,e.createElement)(p.ToggleControl,{checked:!!x,label:(0,i.__)("Disable featured image","gp-premium"),onChange:e=>{C({_generate_disable_featured_image:e})}}),(0,e.createElement)(p.ToggleControl,{checked:!!m,label:(0,i.__)("Disable primary post meta","gp-premium"),onChange:e=>{C({_generate_disable_primary_post_meta:e})}})),"site-footer"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.TextControl,{className:"gpp-block-dynamic-year",type:"text",readOnly:!0,value:"{{current_year}}",label:(0,i.__)("Current year template tag","gp-premium"),help:(0,i.__)("Use the above template tag to add the current year to your footer.","gp-premium")})),"post-navigation-template"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{checked:!!w,label:(0,i.__)("Disable default post navigation","gp-premium"),onChange:e=>{C({_generate_disable_post_navigation:e})}}),(0,e.createElement)(p.ToggleControl,{checked:!!T,label:(0,i.__)("Add default archive navigation container","gp-premium"),onChange:e=>{C({_generate_use_archive_navigation_container:e})}})),"archive-navigation-template"===o&&(0,e.createElement)(r.Fragment,null,(0,e.createElement)(p.ToggleControl,{checked:!!v,label:(0,i.__)("Disable default pagination","gp-premium"),onChange:e=>{C({_generate_disable_archive_navigation:e})}}),(0,e.createElement)(p.ToggleControl,{checked:!!T,label:(0,i.__)("Keep default archive navigation container","gp-premium"),onChange:e=>{C({_generate_use_archive_navigation_container:e})}}))))}}const se=(0,N.withSelect)((e=>{const{getEditedPostAttribute:t}=e("core/editor");return{meta:t("meta"),elementParent:t("parent"),elementMenuOrder:t("menu_order")}})),de=(0,N.withDispatch)(((e,{meta:t})=>{const{editPost:n}=e("core/editor");return{updateMeta(e){n({meta:{...t,...e}})},updateParentId(e){n({parent:e})},updateOrder(e){n({menu_order:e})}}})),me=(0,l.compose)([se,de])(ge);(0,H.registerPlugin)("generatepress-block-element",{icon:null,render:me}),U()((()=>(0,H.unregisterPlugin)("generatepress-content-width")))})()})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/customizer.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/customizer.asset.php deleted file mode 100644 index e00d5caa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/customizer.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('wp-hooks', 'wp-i18n'), 'version' => '542c4e5db7eed60770ec'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/customizer.js deleted file mode 100644 index c0f382ef..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/customizer.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";const e=window.wp.hooks,o=window.wp.i18n;(0,e.addFilter)("generate_typography_element_groups","generatepress-pro/customizer/add-typography-groups",(function(e){const a={};return gpCustomizerControls.hasSecondaryNav&&(a.secondaryNavigation=(0,o.__)("Secondary Navigation","gp-premium")),gpCustomizerControls.hasMenuPlus&&(a.offCanvasPanel=(0,o.__)("Off-Canvas Panel","gp-premium")),gpCustomizerControls.hasWooCommerce&&(a.wooCommerce=(0,o.__)("WooCommerce","gp-premium")),{...e,...a}})),(0,e.addFilter)("generate_typography_elements","generatepress-pro/customizer/add-typography-elements",(function(e){const a={};return gpCustomizerControls.hasSecondaryNav&&(a["secondary-nav-menu-items"]={module:"secondary-nav",group:"secondaryNavigation",label:(0,o.__)("Secondary Menu Items","gp-premium"),placeholders:{fontSize:{value:"13",min:6,max:30,step:1}}},a["secondary-nav-sub-menu-items"]={module:"secondary-nav",group:"secondaryNavigation",label:(0,o.__)("Secondary Sub-Menu Items","gp-premium"),placeholders:{fontSize:{value:"12",min:6,max:30,step:1}}},a["secondary-nav-menu-toggle"]={module:"secondary-nav",group:"secondaryNavigation",label:(0,o.__)("Secondary Mobile Menu Toggle","gp-premium"),placeholders:{fontSize:{value:"13",min:6,max:30,step:1}}}),gpCustomizerControls.hasMenuPlus&&(a["off-canvas-panel-menu-items"]={module:"off-canvas-panel",group:"offCanvasPanel",label:(0,o.__)("Off-Canvas Menu Items","gp-premium"),placeholders:{fontSize:{value:"",min:6,max:30,step:1}}},a["off-canvas-panel-sub-menu-items"]={module:"off-canvas-panel",group:"offCanvasPanel",label:(0,o.__)("Off-Canvas Sub-Menu Items","gp-premium"),placeholders:{fontSize:{value:"",min:6,max:30,step:1}}}),gpCustomizerControls.hasWooCommerce&&(a["woocommerce-catalog-product-titles"]={module:"woocommerce",group:"wooCommerce",label:(0,o.__)("Catalog Product Titles","gp-premium"),placeholders:{fontSize:{value:"",min:6,max:50,step:1}}},a["woocommerce-related-product-titles"]={module:"woocommerce",group:"wooCommerce",label:(0,o.__)("Related/Upsell Product Titles","gp-premium"),placeholders:{fontSize:{value:"",min:6,max:50,step:1}}}),{...e,...a}}))})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/dashboard.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/dashboard.asset.php deleted file mode 100644 index 12a58801..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/dashboard.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-element', 'wp-i18n'), 'version' => '6a732fdaaa86f685bd9f'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/dashboard.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/dashboard.js deleted file mode 100644 index f1b04547..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/dashboard.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{var e,t={217:(e,t,s)=>{"use strict";const r=window.React,a=window.wp.element;function n(e,t){void 0!==a.createRoot?(0,a.createRoot)(t).render(e):(0,a.render)(e,t)}const o=window.wp.i18n,i=window.wp.components,l=window.wp.apiFetch;var c=s.n(l),m=s(162),d=s.n(m);function p(e,t=null){return"generatepress"===e?(0,r.createElement)("svg",{width:"20",height:"20",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 600 600",preserveAspectRatio:"none"},(0,r.createElement)("path",{d:"M485.2 427.8l-99.1-46.2 15.8-34c5.6-11.9 8.8-24.3 10-36.7 3.3-33.7-9-67.3-33.2-91.1-8.9-8.7-19.3-16.1-31.3-21.7-11.9-5.6-24.3-8.8-36.7-10-33.7-3.3-67.4 9-91.1 33.2-8.7 8.9-16.1 19.3-21.7 31.3l-15.8 34-30.4 65.2c-.7 1.5-.1 3.3 1.5 4l65.2 30.4 34 15.8 34 15.8 68 31.7 74.7 34.8c-65 45.4-152.1 55.2-228.7 17.4C90.2 447.4 44.1 313.3 97.3 202.6c53.3-110.8 186-158.5 297.8-106.3 88.1 41.1 137.1 131.9 129.1 223.4-.1 1.3.6 2.4 1.7 3l65.6 30.6c1.8.8 3.9-.3 4.2-2.2 22.6-130.7-44-265.4-170.5-323.5-150.3-69-327-4.1-396.9 145.8-70 150.1-5.1 328.5 145.1 398.5 114.1 53.2 244.5 28.4 331.3-52.3 17.9-16.6 33.9-35.6 47.5-56.8 1-1.5.4-3.6-1.3-4.3l-65.7-30.7zm-235-109.6l15.8-34c8.8-18.8 31.1-26.9 49.8-18.1s26.9 31 18.1 49.8l-15.8 34-34-15.8-33.9-15.9z"})):"dynamic"===e?(0,r.createElement)("svg",{width:"24",height:"24",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",viewBox:"0 0 256 256"},(0,r.createElement)("path",{d:"M128 26c-52.71 0-94 23.72-94 54v96c0 30.28 41.29 54 94 54s94-23.72 94-54V80c0-30.28-41.29-54-94-54zm0 12c44.449 0 82 19.233 82 42s-37.551 42-82 42-82-19.233-82-42 37.551-42 82-42zm82 138c0 22.767-37.551 42-82 42s-82-19.233-82-42v-21.21C61.97 171.163 92.374 182 128 182s66.03-10.837 82-27.21zm0-48c0 22.767-37.551 42-82 42s-82-19.233-82-42v-21.21C61.97 123.163 92.374 134 128 134s66.03-10.837 82-27.21z",fill:"currentColor"})):"tools"===e?(0,r.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"},(0,r.createElement)("path",{d:"M14.7 6.3a1 1 0 000 1.4l1.6 1.6a1 1 0 001.4 0l3.77-3.77a6 6 0 01-7.94 7.94l-6.91 6.91a2.12 2.12 0 01-3-3l6.91-6.91a6 6 0 017.94-7.94l-3.76 3.76z"})):"sliders"===e?(0,r.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",viewBox:"0 0 24 24"},(0,r.createElement)("path",{d:"M4 21v-7M4 10V3M12 21v-9M12 8V3M20 21v-5M20 12V3M1 14h6M9 8h6M17 16h6"})):"plus-circle"===e?(0,r.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",clipRule:"evenodd",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2",viewBox:"0 0 24 24",style:t},(0,r.createElement)("path",{d:"m12.002 2c5.518 0 9.998 4.48 9.998 9.998 0 5.517-4.48 9.997-9.998 9.997-5.517 0-9.997-4.48-9.997-9.997 0-5.518 4.48-9.998 9.997-9.998zm0 1.5c-4.69 0-8.497 3.808-8.497 8.498s3.807 8.497 8.497 8.497 8.498-3.807 8.498-8.497-3.808-8.498-8.498-8.498zm-.747 7.75h-3.5c-.414 0-.75.336-.75.75s.336.75.75.75h3.5v3.5c0 .414.336.75.75.75s.75-.336.75-.75v-3.5h3.5c.414 0 .75-.336.75-.75s-.336-.75-.75-.75h-3.5v-3.5c0-.414-.336-.75-.75-.75s-.75.336-.75.75z",fillRule:"nonzero"})):"minus-circle"===e?(0,r.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",clipRule:"evenodd",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:"2",viewBox:"0 0 24 24",style:t},(0,r.createElement)("path",{d:"m12.002 2.005c5.518 0 9.998 4.48 9.998 9.997 0 5.518-4.48 9.998-9.998 9.998-5.517 0-9.997-4.48-9.997-9.998 0-5.517 4.48-9.997 9.997-9.997zm0 1.5c-4.69 0-8.497 3.807-8.497 8.497s3.807 8.498 8.497 8.498 8.498-3.808 8.498-8.498-3.808-8.497-8.498-8.497zm4.253 7.75h-8.5c-.414 0-.75.336-.75.75s.336.75.75.75h8.5c.414 0 .75-.336.75-.75s-.336-.75-.75-.75z",fillRule:"nonzero"})):"trash"===e?(0,r.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",style:{fill:"none"},stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",viewBox:"0 0 24 24"},(0,r.createElement)("path",{d:"M3 6h18M19 6v14a2 2 0 01-2 2H7a2 2 0 01-2-2V6m3 0V4a2 2 0 012-2h4a2 2 0 012 2v2M10 11v6M14 11v6"})):void 0}const u=()=>{const[e,t]=(0,a.useState)(!1),[s,n]=(0,a.useState)(""),[l,m]=(0,a.useState)(""),[u,g]=(0,a.useState)(!1),[_,h]=(0,a.useState)(!1),[v,b]=(0,a.useState)(generateProDashboard.modules);if((0,a.useEffect)((()=>{e||t(!0)})),!e)return(0,r.createElement)(i.Placeholder,{className:"generatepress-dashboard__placeholder"},(0,r.createElement)(i.Spinner,null));const E=(e,t,s)=>{n(t);const r=e.target.previousElementSibling.previousElementSibling;c()({path:"/generatepress-pro/v1/modules",method:"POST",data:{key:v[t].key,action:s}}).then((e=>{if(n(""),r.classList.add("generatepress-dashboard__section-item-message__show"),r.textContent=e.response,e.success&&e.response){b((e=>({...e,[t]:{...e[t],isActive:"activate"===s}})));const e={"Font Library":{id:"gp-font-library-tab",url:generateProDashboard.fontLibraryUrl},"Site Library":{id:"gp-site-library-tab",url:generateProDashboard.siteLibraryUrl},Elements:{id:"gp-elements-tab",url:generateProDashboard.elementsUrl}};let a=null;if(t in e&&(a=document.querySelector(`a#${e[t].id}`),!a)){a=document.createElement("a"),a.id=e[t].id,a.href=e[t].url,a.textContent=t,a.style.display="none";const s=document.querySelector(".generatepress-dashboard-header__navigation");if(s){const e=s.children[0].nextSibling;s.insertBefore(a,e)}}a&&("activate"===s?a.style.display="flex":"deactivate"===s&&(a.style.display="none")),setTimeout((function(){r.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3)}else r.classList.add("generatepress-dashboard__section-item-message__error")}))};return(0,r.createElement)(r.Fragment,null,!!v&&(0,r.createElement)("div",{className:"generatepress-dashboard__section"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-title"},(0,r.createElement)("h2",null,(0,o.__)("Modules","gp-premium"))),Object.keys(v).filter((e=>!(!v[e].isActive&&v[e].deprecated))).map((e=>(0,r.createElement)("div",{className:"generatepress-dashboard__section-item",key:e,style:{boxShadow:v[e].isActive?"-5px 0 0 var(--wp-admin-theme-color)":"-5px 0 0 #ddd",pointerEvents:"WooCommerce"!==e||generateProDashboard.hasWooCommerce?null:"none",opacity:"WooCommerce"!==e||generateProDashboard.hasWooCommerce?null:"0.5"}},(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-content"},(0,r.createElement)(r.Fragment,null,!!v[e].title&&(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-title"},v[e].title,!!v[e].isActive&&"Site Library"===e&&(0,r.createElement)("a",{className:"generatepress-module-action",href:generateProDashboard.siteLibraryUrl},(0,o.__)("Open Site Library","gp-premium")," →"),!!v[e].isActive&&"Elements"===e&&(0,r.createElement)("a",{className:"generatepress-module-action",href:generateProDashboard.elementsUrl},(0,o.__)("Open Elements","gp-premium")," →"),!!v[e].isActive&&"Font Library"===e&&(0,r.createElement)("a",{className:"generatepress-module-action",href:generateProDashboard.fontLibraryUrl},(0,o.__)("Open Font Library","gp-premium")," →")),!!v[e].description&&(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-description"},v[e].description))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-action"},(0,r.createElement)("span",{className:"generatepress-dashboard__section-item-message"}),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-settings"},!!v[e].settings&&!!v[e].isActive&&(0,r.createElement)(r.Fragment,null,e!==l&&(0,r.createElement)(i.Tooltip,{text:(0,o.__)("Open tools for this module.","gp-premium")},(0,r.createElement)(i.Button,{isTertiary:!0,icon:p("sliders"),onClick:()=>m(e)})),e===l&&(0,r.createElement)(r.Fragment,null,(0,r.createElement)(i.Button,{disabled:!!_,className:"generatepress-dashboard__reset-button",isPrimary:!0,onClick:t=>{const s={[e]:v[e]};window.confirm((0,o.__)("This will delete all settings for this module. It cannot be undone.","gp-premium"))&&((e,t)=>{h(!0);const s=e.target.parentNode.previousElementSibling;c()({path:"/generatepress-pro/v1/reset",method:"POST",data:{items:t}}).then((e=>{h(!1),s.classList.add("generatepress-dashboard__section-item-message__show"),"object"==typeof e.response?s.textContent=(0,o.__)("Settings reset.","gp-premium"):s.textContent=e.response,e.success&&e.response?setTimeout((function(){s.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3):s.classList.add("generatepress-dashboard__section-item-message__error")}))})(t,s)}},!!_&&(0,r.createElement)(i.Spinner,null),!_&&(0,o.__)("Reset","gp-premium")),(0,r.createElement)(i.Button,{isTertiary:!0,onClick:t=>{((e,t,s,r)=>{g(!0);const a=e.target.parentNode.previousElementSibling;c()({path:"/generatepress-pro/v1/export",method:"POST",data:{items:t,type:"all"}}).then((e=>{if(g(!1),a.classList.add("generatepress-dashboard__section-item-message__show"),"object"==typeof e.response?a.textContent=(0,o.__)("Options exported","gp-premium"):a.textContent=e.response,e.success&&e.response){const t=(new Date).toISOString().slice(0,10),s="generatepress-settings-"+r+"-"+t+".json",n=new Blob([JSON.stringify(e.response)],{type:"application/json",name:s});d()(n,s),setTimeout((function(){a.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3)}else a.classList.add("generatepress-dashboard__section-item-message__error")}))})(t,{[e]:v[e]},0,e)}},!!u&&(0,r.createElement)(i.Spinner,null),!u&&(0,o.__)("Export","gp-premium"))))),(0,r.createElement)(i.Button,{disabled:e===s||"WooCommerce"===e&&!generateProDashboard.hasWooCommerce,isPrimary:!v[e].isActive||null,isSecondary:!!v[e].isActive||null,onClick:t=>{if(v[e].isActive){if(v[e].deprecated&&!window.confirm((0,o.__)("This module has been deprecated. Deactivating it will remove it from this list.","gp-premium")))return;E(t,e,"deactivate")}else E(t,e,"activate")}},e===s&&(0,r.createElement)(i.Spinner,null),e!==s&&!v[e].isActive&&(0,o.__)("Activate","gp-premium"),e!==s&&!!v[e].isActive&&(0,o.__)("Deactivate","gp-premium"))))))))};window.addEventListener("DOMContentLoaded",(()=>{n((0,r.createElement)(u,null),document.getElementById("generatepress-module-list"))}));const g=()=>{const[e,t]=(0,a.useState)(!1),[s,n]=(0,a.useState)(!1),[l,m]=(0,a.useState)(generateProDashboard.licenseKey),[d,p]=(0,a.useState)(generateProDashboard.licenseKeyStatus),[u,g]=(0,a.useState)(generateProDashboard.betaTester),[_,h]=(0,a.useState)(!1);if((0,a.useEffect)((()=>{h(!!l)}),[]),(0,a.useEffect)((()=>{e||t(!0)})),!e)return(0,r.createElement)(i.Placeholder,{className:"generatepress-dashboard__placeholder"},(0,r.createElement)(i.Spinner,null));const v=(e=l)=>{n(!0),h(!!e);const t=document.querySelector(".generatepress-dashboard__section-item-message");t.classList.remove("generatepress-dashboard__section-item-message__show"),c()({path:"/generatepress-pro/v1/license",method:"POST",data:{key:e,status:d}}).then((e=>{n(!1),t.classList.add("generatepress-dashboard__section-item-message__show"),e.success&&e.response?(t.classList.remove("generatepress-dashboard__section-item-message__error"),"valid"===e.response.license?t.textContent=(0,o.__)("License key activated.","gp-premium"):"deactivated"===e.response.license?t.textContent=(0,o.__)("License key deactivated.","gp-premium"):t.textContent=e.response,p(e.response.license),setTimeout((function(){t.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3)):(t.classList.add("generatepress-dashboard__section-item-message__error"),t.textContent=e.response)}))};return(0,r.createElement)(r.Fragment,null,(0,r.createElement)("div",{className:"generatepress-dashboard__section generatepress-license-key-area"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-title"},(0,r.createElement)("h2",null,(0,o.__)("License Key","gp-premium")),(0,r.createElement)("span",{className:"generatepress-dashboard__section-item-message"})),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item"},(0,r.createElement)(i.Notice,{className:"generatepress-dashboard__section-license-notice",isDismissible:!1,status:"valid"===d?"success":"warning"},"valid"===d?(0,r.createElement)("span",null,(0,o.__)("Receiving premium updates.","gp-premium")):(0,r.createElement)("span",null,(0,o.__)("Not receiving premium updates.","gp-premium"))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-license-key"},_?(0,r.createElement)(i.TextControl,{type:"text",autoComplete:"off",value:l,disabled:!0}):(0,r.createElement)(r.Fragment,null,(0,r.createElement)(i.TextControl,{placeholder:(0,o.__)("Enter your license key to activate updates.","gp-premium"),type:"text",autoComplete:"off",onChange:e=>m(e)}),!!l&&(0,r.createElement)(i.Button,{variant:"primary",disabled:!!s,onClick:()=>v()},s&&(0,r.createElement)(i.Spinner,null),!s&&(0,o.__)("Save key"))),!!_&&!!l&&(0,r.createElement)(i.Button,{variant:"primary",onClick:()=>{m(""),v("")}},(0,o.__)("Clear key","generateblocks"))),""!==l&&(0,r.createElement)("div",{className:"generatepress-dashboard__section-beta-tester"},(0,r.createElement)(i.ToggleControl,{label:(0,o.__)("Receive development version updates"),help:(0,o.__)("Get alpha, beta, and release candidate updates directly to your Dashboard.","gp-premium"),checked:!!u,onChange:e=>{g(e),(e=>{const t=document.querySelector(".generatepress-dashboard__section-item-message");t.classList.remove("generatepress-dashboard__section-item-message__show"),c()({path:"/generatepress-pro/v1/beta",method:"POST",data:{beta:e}}).then((e=>{n(!1),t.classList.add("generatepress-dashboard__section-item-message__show"),e.success&&e.response?(t.classList.remove("generatepress-dashboard__section-item-message__error"),t.textContent=e.response,setTimeout((function(){t.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3)):(t.classList.add("generatepress-dashboard__section-item-message__error"),t.textContent=e.response)}))})(e)}})))))};window.addEventListener("DOMContentLoaded",(()=>{n((0,r.createElement)(g,null),document.getElementById("generatepress-license-key"))}));const _=()=>{const[e,t]=(0,a.useState)(!1),[s,n]=(0,a.useState)(!1),[l,m]=(0,a.useState)(!1),[p,u]=(0,a.useState)(!1),[g,_]=(0,a.useState)("all");return(0,a.useEffect)((()=>{e||t(!0)})),e?(0,r.createElement)(r.Fragment,null,(0,r.createElement)("div",{className:"generatepress-dashboard__section"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-title"},(0,r.createElement)("h2",null,(0,o.__)("Import / Export","gp-premium"))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-content"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-title"},(0,o.__)("Export","gp-premium")),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-description"},(0,o.__)("Export your customizer settings.","gp-premium"))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-action"},(0,r.createElement)("span",{className:"generatepress-dashboard__section-item-message"}),(0,r.createElement)(i.ButtonGroup,{className:"generatepress-dashboard__section-item-export-type"},(0,r.createElement)(i.Button,{isPrimary:"all"===g,onClick:()=>_("all")},(0,o.__)("All","gp-premium")),(0,r.createElement)(i.Button,{isPrimary:"global-colors"===g,onClick:()=>_("global-colors")},(0,o.__)("Global Colors","gp-premium")),(0,r.createElement)(i.Button,{isPrimary:"typography"===g,onClick:()=>_("typography")},(0,o.__)("Typography","gp-premium"))),(0,r.createElement)(i.Button,{disabled:!!s,isPrimary:!0,onClick:e=>(e=>{n(!0);const t=e.target.previousElementSibling.previousElementSibling;c()({path:"/generatepress-pro/v1/export",method:"POST",data:{items:!1,type:g}}).then((e=>{if(n(!1),t.classList.add("generatepress-dashboard__section-item-message__show"),"object"==typeof e.response?t.textContent=(0,o.__)("Options exported","gp-premium"):t.textContent=e.response,e.success&&e.response){const s=(new Date).toISOString().slice(0,10),r="generatepress-settings-"+g+"-"+s+".json",a=new Blob([JSON.stringify(e.response)],{type:"application/json",name:r});d()(a,r),setTimeout((function(){t.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3)}else t.classList.add("generatepress-dashboard__section-item-message__error")}))})(e)},!!s&&(0,r.createElement)(i.Spinner,null),!s&&(0,o.__)("Export","gp-premium")))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-content"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-title"},(0,o.__)("Import","gp-premium")),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-description"},(0,o.__)("Import your customizer settings.","gp-premium"))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-action"},(0,r.createElement)("span",{className:"generatepress-dashboard__section-item-message"}),(0,r.createElement)("input",{type:"file",accept:".json",onChange:e=>{const t=new FileReader;t.onloadend=()=>{let e=t.result;e=JSON.parse(e),e&&u(e)},t.readAsText(e.target.files[0])}}),(0,r.createElement)(i.Button,{disabled:!!l||!p,isPrimary:!0,onClick:e=>{window.confirm((0,o.__)("This can overwrite existing settings and cannot be undone.","gp-premium"))&&(e=>{m(!0);const t=e.target.previousElementSibling.previousElementSibling,s=e.target.previousElementSibling;s.style.display="none",c()({path:"/generatepress-pro/v1/import",method:"POST",data:{import:p}}).then((e=>{m(!1),t.classList.add("generatepress-dashboard__section-item-message__show"),"object"==typeof e.response?t.textContent=(0,o.__)("Options imported.","gp-premium"):t.textContent=e.response,e.success&&e.response?setTimeout((function(){t.classList.remove("generatepress-dashboard__section-item-message__show"),s.style.display="block",s.value=""}),3e3):t.classList.add("generatepress-dashboard__section-item-message__error")}))})(e)}},!!l&&(0,r.createElement)(i.Spinner,null),!l&&(0,o.__)("Import","gp-premium")))))):(0,r.createElement)(i.Placeholder,{className:"generatepress-dashboard__placeholder"},(0,r.createElement)(i.Spinner,null))};window.addEventListener("DOMContentLoaded",(()=>{n((0,r.createElement)(_,null),document.getElementById("generatepress-import-export-pro"))}));const h=()=>{const[e,t]=(0,a.useState)(!1),[s,n]=(0,a.useState)(!1);return(0,a.useEffect)((()=>{e||t(!0)})),e?(0,r.createElement)(r.Fragment,null,(0,r.createElement)("div",{className:"generatepress-dashboard__section"},(0,r.createElement)("div",{className:"generatepress-dashboard__section-title",style:{marginBottom:0}},(0,r.createElement)("h2",null,(0,o.__)("Reset","gp-premium"))),(0,r.createElement)("div",{className:"generatepress-dashboard__section-item-description",style:{marginTop:0}},(0,o.__)("Reset your customizer settings.","gp-premium")),(0,r.createElement)(i.Button,{className:"generatepress-dashboard__reset-button",style:{marginTop:"10px"},disabled:!!s,isPrimary:!0,onClick:e=>{window.confirm((0,o.__)("This will delete all of your customizer settings. It cannot be undone.","gp-premium"))&&(e=>{n(!0);const t=e.target.nextElementSibling;c()({path:"/generatepress-pro/v1/reset",method:"POST",data:{items:!1}}).then((e=>{n(!1),t.classList.add("generatepress-dashboard__section-item-message__show"),"object"==typeof e.response?t.textContent=(0,o.__)("Settings reset.","gp-premium"):t.textContent=e.response,e.success&&e.response?setTimeout((function(){t.classList.remove("generatepress-dashboard__section-item-message__show")}),3e3):t.classList.add("generatepress-dashboard__section-item-message__error")}))})(e)}},!!s&&(0,r.createElement)(i.Spinner,null),!s&&(0,o.__)("Reset","gp-premium")),(0,r.createElement)("span",{className:"generatepress-dashboard__section-item-message",style:{marginLeft:"10px"}}))):(0,r.createElement)(i.Placeholder,{className:"generatepress-dashboard__placeholder"},(0,r.createElement)(i.Spinner,null))};window.addEventListener("DOMContentLoaded",(()=>{n((0,r.createElement)(h,null),document.getElementById("generatepress-reset-pro"))}))},162:function(e,t,s){var r,a;void 0===(a="function"==typeof(r=function(){"use strict";function t(e,t,s){var r=new XMLHttpRequest;r.open("GET",e),r.responseType="blob",r.onload=function(){i(r.response,t,s)},r.onerror=function(){console.error("could not download file")},r.send()}function r(e){var t=new XMLHttpRequest;t.open("HEAD",e,!1);try{t.send()}catch(e){}return 200<=t.status&&299>=t.status}function a(e){try{e.dispatchEvent(new MouseEvent("click"))}catch(s){var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),e.dispatchEvent(t)}}var n="object"==typeof window&&window.window===window?window:"object"==typeof self&&self.self===self?self:"object"==typeof s.g&&s.g.global===s.g?s.g:void 0,o=n.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),i=n.saveAs||("object"!=typeof window||window!==n?function(){}:"download"in HTMLAnchorElement.prototype&&!o?function(e,s,o){var i=n.URL||n.webkitURL,l=document.createElement("a");s=s||e.name||"download",l.download=s,l.rel="noopener","string"==typeof e?(l.href=e,l.origin===location.origin?a(l):r(l.href)?t(e,s,o):a(l,l.target="_blank")):(l.href=i.createObjectURL(e),setTimeout((function(){i.revokeObjectURL(l.href)}),4e4),setTimeout((function(){a(l)}),0))}:"msSaveOrOpenBlob"in navigator?function(e,s,n){if(s=s||e.name||"download","string"!=typeof e)navigator.msSaveOrOpenBlob(function(e,t){return void 0===t?t={autoBom:!1}:"object"!=typeof t&&(console.warn("Deprecated: Expected third argument to be a object"),t={autoBom:!t}),t.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(e.type)?new Blob(["\ufeff",e],{type:e.type}):e}(e,n),s);else if(r(e))t(e,s,n);else{var o=document.createElement("a");o.href=e,o.target="_blank",setTimeout((function(){a(o)}))}}:function(e,s,r,a){if((a=a||open("","_blank"))&&(a.document.title=a.document.body.innerText="downloading..."),"string"==typeof e)return t(e,s,r);var i="application/octet-stream"===e.type,l=/constructor/i.test(n.HTMLElement)||n.safari,c=/CriOS\/[\d]+/.test(navigator.userAgent);if((c||i&&l||o)&&"undefined"!=typeof FileReader){var m=new FileReader;m.onloadend=function(){var e=m.result;e=c?e:e.replace(/^data:[^;]*;/,"data:attachment/file;"),a?a.location.href=e:location=e,a=null},m.readAsDataURL(e)}else{var d=n.URL||n.webkitURL,p=d.createObjectURL(e);a?a.location=p:location.href=p,a=null,setTimeout((function(){d.revokeObjectURL(p)}),4e4)}});n.saveAs=i.saveAs=i,e.exports=i})?r.apply(t,[]):r)||(e.exports=a)}},s={};function r(e){var a=s[e];if(void 0!==a)return a.exports;var n=s[e]={exports:{}};return t[e].call(n.exports,n,n.exports,r),n.exports}r.m=t,e=[],r.O=(t,s,a,n)=>{if(!s){var o=1/0;for(m=0;m=n)&&Object.keys(r.O).every((e=>r.O[e](s[l])))?s.splice(l--,1):(i=!1,n0&&e[m-1][2]>n;m--)e[m]=e[m-1];e[m]=[s,a,n]},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var s in t)r.o(t,s)&&!r.o(e,s)&&Object.defineProperty(e,s,{enumerable:!0,get:t[s]})},r.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e={966:0,100:0};r.O.j=t=>0===e[t];var t=(t,s)=>{var a,n,[o,i,l]=s,c=0;if(o.some((t=>0!==e[t]))){for(a in i)r.o(i,a)&&(r.m[a]=i[a]);if(l)var m=l(r)}for(t&&t(s);cr(217)));a=r.O(a)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor-rtl.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor-rtl.css deleted file mode 100644 index 4d7bafd0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.gpp-active-element-type{color:#555;font-size:11px;text-transform:uppercase} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.asset.php deleted file mode 100644 index a6182b78..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-edit-post', 'wp-element', 'wp-html-entities', 'wp-i18n', 'wp-plugins'), 'version' => '81f036c27194ee54b73d'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.css deleted file mode 100644 index 4d7bafd0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.css +++ /dev/null @@ -1 +0,0 @@ -.gpp-active-element-type{color:#555;font-size:11px;text-transform:uppercase} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.js deleted file mode 100644 index 4a40ca01..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/editor.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";const e=window.React,t=window.wp.i18n,n=window.wp.plugins,l=window.wp.editPost,i=window.wp.element,m=window.wp.htmlEntities;class s extends i.Component{render(){const n=gpPremiumEditor.activeElements;return!n||n.length<1?null:gpPremiumEditor.postTypeIsPublic?(0,e.createElement)(l.PluginDocumentSettingPanel,{name:"generatepress-elements-info",title:(0,t.__)("Active Elements","gp-premium"),className:"gpp-element-info-panel gpp-element-panel-label"},(0,e.createElement)(i.Fragment,null,(0,e.createElement)("ul",{className:"gpp-active-elements"},Object.keys(n).map(((t,l)=>(0,e.createElement)("li",{key:`gpp-active-block-element-${l}`},(0,e.createElement)("a",{href:n[t].url+"&action=edit"},(0,m.decodeEntities)(n[t].name))," ",(0,e.createElement)("span",{className:"gpp-active-element-type"},"- ",n[t].type))))),(0,e.createElement)("a",{href:gpPremiumEditor.elementsUrl,className:"components-button is-secondary"},(0,t.__)("All Elements","gp-premium")))):null}}(0,n.registerPlugin)("generatepress-elements-info-panel",{icon:null,render:s})})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library-rtl.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library-rtl.css deleted file mode 100644 index 6b1f9806..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.gp-font-library{box-sizing:border-box;margin:40px auto 0;max-width:1200px;padding:0 20px}.gp-font-library .components-tab-panel__tabs{background-color:#fff;border-bottom:1px solid #e7e7e7}.gp-font-library .components-tab-panel__tabs .components-tab-panel__tabs-item{padding:30px 20px}.gp-font-library .components-tab-panel__tabs .components-tab-panel__tabs-item.active-tab{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.gp-font-library .components-tab-panel__tabs .components-tab-panel__tabs-item:first-child{margin-right:20px}.gp-font-library .components-tab-panel__tabs .gp-tab-header{font-size:14px}.gp-font-library .components-tab-panel__tab-content{background-color:#fff;box-sizing:border-box;margin:0 auto;max-width:1200px;min-height:600px;padding:30px 40px}.gp-font-library .components-tab-panel__tab-content h2{font-size:20px;line-height:1.2em;margin-bottom:20px;margin-top:0}.gp-font-library__text{max-width:700px}.gp-font-library__list{font-size:16px}.gp-font-library__list li{margin-bottom:0}.gp-font-library__list li+li{margin-top:-1px}.gp-font-library__notice{margin-bottom:30px}.gp-font-library__results li{align-items:center;display:flex;gap:2px}.gp-font-library__result--success svg{fill:#4ab866}.gp-font-library__result--failure svg{fill:#cc1818}.gp-font-library-authorize-fonts{border:1px solid #aaa;border-radius:3px;margin:50px auto 0;max-width:350px;padding:25px}.gp-font-library-authorize-fonts h3{font-size:1.5em;margin-top:10px}.gp-font-library-authorize-fonts .components-button{margin:10px 0}.gp-font-library-variant{padding:30px}.gp-font-library-variant__header{display:flex;justify-content:space-between}.gp-font-library-variant__label{color:#777;font-size:14px}.gp-font-library-card{align-items:center;border:1px solid #e0e0e0;display:flex;font-style:italic;gap:10px;height:auto;padding:16px;text-align:right;width:100%}.gp-font-library-card :where(input,label),.gp-font-library-card:where(button,a){cursor:pointer}.gp-font-library-card+.gp-font-library-card{margin-top:-1px}.gp-font-library-card__variants{align-items:center;display:flex;gap:10px;margin-right:auto}.gp-font-library-card__categories{margin:auto;min-width:7.69em;text-transform:capitalize}.gp-font-library-card .gp-font-library-preview{min-width:25%}.gp-font-library-card:hover img{filter:invert(39%) sepia(67%) saturate(7078%) hue-rotate(213deg) brightness(96%) contrast(98%)}.gp-font-library-preview{align-items:center;display:flex;font-style:normal}.gp-font-library-preview__image{display:block;max-width:100%}.gp-font-library-preview__fallback{font-size:19px}.gp-font-library-edit h3{margin-top:20px}.gp-font-library-edit__control-notice{max-width:500px}.gp-font-library-edit__control label{display:block}.gp-font-library-edit__control .components-input-control__container,.gp-font-library-edit__control input[type=text]{max-width:250px!important}.gp-font-library-edit__footer{margin-top:40px}.gp-font-library-edit__variants{list-style:none;padding-right:0;width:250px}.gp-font-library-edit__variant{align-items:center;display:flex;justify-content:space-between}.gp-font-library-edit__variant .components-checkbox-control{--checkbox-input-size:24px}.gp-font-library-edit__variant .components-checkbox-control .components-base-control__field{align-items:center;display:flex}.gp-font-library-edit__variant--delete .components-checkbox-control{opacity:.5;text-decoration:line-through}.gp-font-library-edit__advanced{margin-bottom:20px}.gp-font-library-edit__advanced>.gb-stack{margin-top:20px}.gp-font-library-google__header-container{container-type:inline-size}.gp-font-library-google__header{align-items:flex-start;display:flex;margin-bottom:30px}.gp-font-library-google__header-content{flex-grow:1}.gp-font-library-google__header-content>:last-child{margin-bottom:0}.gp-font-library-google__header-content h2{margin-top:0}.gp-font-library-google__description{width:100%}.gp-font-library-google__filters{display:flex;flex-wrap:wrap;gap:10px;justify-content:space-between;margin-bottom:10px}.gp-font-library-google__filters select{height:40px!important}.gp-font-library-google__results{font-size:12px;font-style:italic;font-weight:500}.gp-font-library-google__results .components-button{margin-right:1em}.gp-font-library-google__pagination{align-items:flex-end;display:flex;gap:10px}.gp-font-library-google__pagination-numbers{align-items:center;display:flex;gap:10px;margin-left:auto}.gp-font-library-google__footer{align-items:center;display:flex;flex-wrap:wrap;gap:10px}.gp-font-library-settings{width:500px}.gp-font-library-settings__controls{margin-bottom:40px}.gp-font-library-settings__controls .components-base-control>:last-child{margin-bottom:0}.gp-font-library-settings__auth{background-color:#cc181833;border:1px solid #cc1818;border-radius:4px;font-size:14px;padding:10px}.gp-font-library-settings__auth :first-child{margin-top:0}.gp-font-library-settings__auth :last-child{margin-bottom:0} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.asset.php deleted file mode 100644 index 0264391d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('lodash', 'react', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-primitives'), 'version' => '70fe87ecb0efc8fb0659'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.css deleted file mode 100644 index 4ab5702e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.css +++ /dev/null @@ -1 +0,0 @@ -.gp-font-library{box-sizing:border-box;margin:40px auto 0;max-width:1200px;padding:0 20px}.gp-font-library .components-tab-panel__tabs{background-color:#fff;border-bottom:1px solid #e7e7e7}.gp-font-library .components-tab-panel__tabs .components-tab-panel__tabs-item{padding:30px 20px}.gp-font-library .components-tab-panel__tabs .components-tab-panel__tabs-item.active-tab{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.gp-font-library .components-tab-panel__tabs .components-tab-panel__tabs-item:first-child{margin-left:20px}.gp-font-library .components-tab-panel__tabs .gp-tab-header{font-size:14px}.gp-font-library .components-tab-panel__tab-content{background-color:#fff;box-sizing:border-box;margin:0 auto;max-width:1200px;min-height:600px;padding:30px 40px}.gp-font-library .components-tab-panel__tab-content h2{font-size:20px;line-height:1.2em;margin-bottom:20px;margin-top:0}.gp-font-library__text{max-width:700px}.gp-font-library__list{font-size:16px}.gp-font-library__list li{margin-bottom:0}.gp-font-library__list li+li{margin-top:-1px}.gp-font-library__notice{margin-bottom:30px}.gp-font-library__results li{align-items:center;display:flex;gap:2px}.gp-font-library__result--success svg{fill:#4ab866}.gp-font-library__result--failure svg{fill:#cc1818}.gp-font-library-authorize-fonts{border:1px solid #aaa;border-radius:3px;margin:50px auto 0;max-width:350px;padding:25px}.gp-font-library-authorize-fonts h3{font-size:1.5em;margin-top:10px}.gp-font-library-authorize-fonts .components-button{margin:10px 0}.gp-font-library-variant{padding:30px}.gp-font-library-variant__header{display:flex;justify-content:space-between}.gp-font-library-variant__label{color:#777;font-size:14px}.gp-font-library-card{align-items:center;border:1px solid #e0e0e0;display:flex;font-style:italic;gap:10px;height:auto;padding:16px;text-align:left;width:100%}.gp-font-library-card :where(input,label),.gp-font-library-card:where(button,a){cursor:pointer}.gp-font-library-card+.gp-font-library-card{margin-top:-1px}.gp-font-library-card__variants{align-items:center;display:flex;gap:10px;margin-left:auto}.gp-font-library-card__categories{margin:auto;min-width:7.69em;text-transform:capitalize}.gp-font-library-card .gp-font-library-preview{min-width:25%}.gp-font-library-card:hover img{filter:invert(39%) sepia(67%) saturate(7078%) hue-rotate(213deg) brightness(96%) contrast(98%)}.gp-font-library-preview{align-items:center;display:flex;font-style:normal}.gp-font-library-preview__image{display:block;max-width:100%}.gp-font-library-preview__fallback{font-size:19px}.gp-font-library-edit h3{margin-top:20px}.gp-font-library-edit__control-notice{max-width:500px}.gp-font-library-edit__control label{display:block}.gp-font-library-edit__control .components-input-control__container,.gp-font-library-edit__control input[type=text]{max-width:250px!important}.gp-font-library-edit__footer{margin-top:40px}.gp-font-library-edit__variants{list-style:none;padding-left:0;width:250px}.gp-font-library-edit__variant{align-items:center;display:flex;justify-content:space-between}.gp-font-library-edit__variant .components-checkbox-control{--checkbox-input-size:24px}.gp-font-library-edit__variant .components-checkbox-control .components-base-control__field{align-items:center;display:flex}.gp-font-library-edit__variant--delete .components-checkbox-control{opacity:.5;text-decoration:line-through}.gp-font-library-edit__advanced{margin-bottom:20px}.gp-font-library-edit__advanced>.gb-stack{margin-top:20px}.gp-font-library-google__header-container{container-type:inline-size}.gp-font-library-google__header{align-items:flex-start;display:flex;margin-bottom:30px}.gp-font-library-google__header-content{flex-grow:1}.gp-font-library-google__header-content>:last-child{margin-bottom:0}.gp-font-library-google__header-content h2{margin-top:0}.gp-font-library-google__description{width:100%}.gp-font-library-google__filters{display:flex;flex-wrap:wrap;gap:10px;justify-content:space-between;margin-bottom:10px}.gp-font-library-google__filters select{height:40px!important}.gp-font-library-google__results{font-size:12px;font-style:italic;font-weight:500}.gp-font-library-google__results .components-button{margin-left:1em}.gp-font-library-google__pagination{align-items:flex-end;display:flex;gap:10px}.gp-font-library-google__pagination-numbers{align-items:center;display:flex;gap:10px;margin-right:auto}.gp-font-library-google__footer{align-items:center;display:flex;flex-wrap:wrap;gap:10px}.gp-font-library-settings{width:500px}.gp-font-library-settings__controls{margin-bottom:40px}.gp-font-library-settings__controls .components-base-control>:last-child{margin-bottom:0}.gp-font-library-settings__auth{background-color:#cc181833;border:1px solid #cc1818;border-radius:4px;font-size:14px;padding:10px}.gp-font-library-settings__auth :first-child{margin-top:0}.gp-font-library-settings__auth :last-child{margin-bottom:0} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.js deleted file mode 100644 index d907e9cc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/font-library.js +++ /dev/null @@ -1,11 +0,0 @@ -(()=>{var e={771:e=>{var t;globalThis,t=()=>(()=>{var e={703:(e,t,n)=>{"use strict";var r=n(414);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,s){if(s!==r){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},697:(e,t,n)=>{e.exports=n(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(e,t)=>{"use strict";Symbol.for("react.element"),Symbol.for("react.portal"),Symbol.for("react.fragment"),Symbol.for("react.strict_mode"),Symbol.for("react.profiler"),Symbol.for("react.provider"),Symbol.for("react.context"),Symbol.for("react.server_context"),Symbol.for("react.forward_ref"),Symbol.for("react.suspense"),Symbol.for("react.suspense_list"),Symbol.for("react.memo"),Symbol.for("react.lazy"),Symbol.for("react.offscreen"),Symbol.for("react.module.reference")},864:(e,t,n)=>{"use strict";n(921)},251:(e,t,n)=>{"use strict";var r=n(196),o=Symbol.for("react.element"),i=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),s=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};t.jsx=function(e,t,n){var r,l={},u=null,c=null;for(r in void 0!==n&&(u=""+n),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(c=t.ref),t)i.call(t,r)&&!a.hasOwnProperty(r)&&(l[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===l[r]&&(l[r]=t[r]);return{$$typeof:o,type:e,key:u,ref:c,props:l,_owner:s.current}}},893:(e,t,n)=>{"use strict";e.exports=n(251)},196:e=>{"use strict";e.exports=window.React}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nc=void 0;var r={};return(()=>{"use strict";n.r(r),n.d(r,{Autocomplete:()=>Be,Checkbox:()=>Ke,ColorPicker:()=>on,SortableList:()=>Uo,SortableListItem:()=>Ho,Stack:()=>jo,Table:()=>Wi});var e=n(196),t=n.n(e);const o=window.wp.element,i=window.wp.components,s=window.wp.i18n,a=window.wp.primitives;var l=n(893);const u=(0,l.jsx)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,l.jsx)(a.Path,{d:"M12 3.2c-4.8 0-8.8 3.9-8.8 8.8 0 4.8 3.9 8.8 8.8 8.8 4.8 0 8.8-3.9 8.8-8.8 0-4.8-4-8.8-8.8-8.8zm0 16c-4 0-7.2-3.3-7.2-7.2C4.8 8 8 4.8 12 4.8s7.2 3.3 7.2 7.2c0 4-3.2 7.2-7.2 7.2zM11 17h2v-6h-2v6zm0-8h2V7h-2v2z"})});function c(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)>=0)continue;n[r]=e[r]}return n}function d(){return d=Object.assign?Object.assign.bind():function(e){for(var t=1;t"object"==typeof e&&null!=e&&1===e.nodeType,p=(e,t)=>(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e,m=(e,t)=>{if(e.clientHeight{const t=(e=>{if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}})(e);return!!t&&(t.clientHeightit||i>e&&s=t&&a>=n?i-e-r:s>t&&an?s-t+o:0,v=e=>{const t=e.parentElement;return null==t?e.getRootNode().host||null:t};var w=function(){return w=Object.assign||function(e){for(var t,n=1,r=arguments.length;n1?n-1:0),o=1;os)&&(e=t>0?-1:s+1);var a=e+t;a<0?a=o?s:0:a>s&&(a=o?0:s);var l=M(a,t<0,n,r,o);return-1===l?e>=i?-1:e:l}function M(e,t,n,r,o){void 0===o&&(o=!1);var i=n.length;if(t){for(var s=e;s>=0;s--)if(!r(n[s],s))return s}else for(var a=e;a{var n,r,o,i;if("undefined"==typeof document)return[];const{scrollMode:s,block:a,inline:l,boundary:u,skipOverflowHiddenElements:c}=t,d="function"==typeof u?u:e=>e!==u;if(!g(e))throw new TypeError("Invalid target");const h=document.scrollingElement||document.documentElement,f=[];let p=e;for(;g(p)&&d(p);){if(p=v(p),p===h){f.push(p);break}null!=p&&p===document.body&&m(p)&&!m(document.documentElement)||null!=p&&m(p,c)&&f.push(p)}const w=null!=(r=null==(n=window.visualViewport)?void 0:n.width)?r:innerWidth,y=null!=(i=null==(o=window.visualViewport)?void 0:o.height)?i:innerHeight,{scrollX:C,scrollY:x}=window,{height:S,width:E,top:R,right:O,bottom:I,left:k}=e.getBoundingClientRect(),{top:M,right:F,bottom:D,left:P}=(e=>{const t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);let A="start"===a||"nearest"===a?R-M:"end"===a?I+D:R+S/2-M+D,V="center"===l?k+E/2-P+F:"end"===l?O+F:k-P;const T=[];for(let e=0;e=0&&k>=0&&I<=y&&O<=w&&R>=o&&I<=u&&k>=c&&O<=i)return T;const d=getComputedStyle(t),g=parseInt(d.borderLeftWidth,10),p=parseInt(d.borderTopWidth,10),m=parseInt(d.borderRightWidth,10),v=parseInt(d.borderBottomWidth,10);let M=0,F=0;const D="offsetWidth"in t?t.offsetWidth-t.clientWidth-g-m:0,P="offsetHeight"in t?t.offsetHeight-t.clientHeight-p-v:0,L="offsetWidth"in t?0===t.offsetWidth?0:r/t.offsetWidth:0,N="offsetHeight"in t?0===t.offsetHeight?0:n/t.offsetHeight:0;if(h===t)M="start"===a?A:"end"===a?A-y:"nearest"===a?b(x,x+y,y,p,v,x+A,x+A+S,S):A-y/2,F="start"===l?V:"center"===l?V-w/2:"end"===l?V-w:b(C,C+w,w,g,m,C+V,C+V+E,E),M=Math.max(0,M+x),F=Math.max(0,F+C);else{M="start"===a?A-o-p:"end"===a?A-u+v+P:"nearest"===a?b(o,u,n,p,v+P,A,A+S,S):A-(o+n/2)+P/2,F="start"===l?V-c-g:"center"===l?V-(c+r/2)+D/2:"end"===l?V-i+m+D:b(c,i,r,g,m+D,V,V+E,E);const{scrollLeft:e,scrollTop:s}=t;M=0===N?0:Math.max(0,Math.min(s+M/N,t.scrollHeight-n/N+P)),F=0===L?0:Math.max(0,Math.min(e+F/L,t.scrollWidth-r/L+D)),A+=s-M,V+=e-F}T.push({el:t,top:M,left:F})}return T})(e,{boundary:t,block:"nearest",scrollMode:"if-needed"});n.forEach((function(e){var t=e.el,n=e.top,r=e.left;t.scrollTop=n,t.scrollLeft=r}))}},environment:"undefined"==typeof window?void 0:window};function H(e,t,n){void 0===n&&(n=A);var r=e["default"+N(t)];return void 0!==r?r:n[t]}function U(e,t,n){void 0===n&&(n=A);var r=e[t];if(void 0!==r)return r;var o=e["initial"+N(t)];return void 0!==o?o:H(e,t,n)}function W(e,t,n){var r=e.items,o=e.initialHighlightedIndex,i=e.defaultHighlightedIndex,s=e.isItemDisabled,a=e.itemToKey,l=t.selectedItem,u=t.highlightedIndex;return 0===r.length?-1:void 0===o||u!==o||s(r[o],o)?void 0===i||s(r[i],i)?l?r.findIndex((function(e){return a(l)===a(e)})):n<0&&!s(r[r.length-1],r.length-1)?r.length-1:n>0&&!s(r[0],0)?0:-1:i:o}var j=C;function q(e,t,n){var r;return void 0===n&&(n=!0),d({isOpen:!1,highlightedIndex:-1},(null==(r=e.items)?void 0:r.length)&&t>=0&&d({selectedItem:e.items[t],isOpen:H(e,"isOpen"),highlightedIndex:H(e,"highlightedIndex")},n&&{inputValue:e.itemToString(e.items[t])}))}function K(e,t){return e.isOpen===t.isOpen&&e.inputValue===t.inputValue&&e.highlightedIndex===t.highlightedIndex&&e.selectedItem===t.selectedItem}function Y(){var e=t().useRef(!0);return t().useEffect((function(){return e.current=!1,function(){e.current=!0}}),[]),e.current}function _(e){var t=H(e,"highlightedIndex");return t>-1&&e.isItemDisabled(e.items[t],t)?-1:t}var Z=d({},{environment:f().shape({addEventListener:f().func.isRequired,removeEventListener:f().func.isRequired,document:f().shape({createElement:f().func.isRequired,getElementById:f().func.isRequired,activeElement:f().any.isRequired,body:f().any.isRequired}).isRequired,Node:f().func.isRequired}),itemToString:f().func,itemToKey:f().func,stateReducer:f().func},{getA11yStatusMessage:f().func,highlightedIndex:f().number,defaultHighlightedIndex:f().number,initialHighlightedIndex:f().number,isOpen:f().bool,defaultIsOpen:f().bool,initialIsOpen:f().bool,selectedItem:f().any,initialSelectedItem:f().any,defaultSelectedItem:f().any,id:f().string,labelId:f().string,menuId:f().string,getItemId:f().func,toggleButtonId:f().string,onSelectedItemChange:f().func,onHighlightedIndexChange:f().func,onStateChange:f().func,onIsOpenChange:f().func,scrollIntoView:f().func});w(w({},Z),{items:f().array.isRequired,isItemDisabled:f().func}),w(w({},G),{isItemDisabled:function(){return!1}});var X=0,J=1,Q=2,$=3,ee=4,te=5,ne=6,re=7,oe=8,ie=9,se=10,ae=13,le=19,ue=22,ce=Object.freeze({__proto__:null,ControlledPropUpdatedSelectedItem:ue,FunctionCloseMenu:17,FunctionOpenMenu:16,FunctionReset:21,FunctionSelectItem:le,FunctionSetHighlightedIndex:18,FunctionSetInputValue:20,FunctionToggleMenu:15,InputBlur:ie,InputChange:oe,InputClick:se,InputKeyDownArrowDown:X,InputKeyDownArrowUp:J,InputKeyDownEnd:ee,InputKeyDownEnter:re,InputKeyDownEscape:Q,InputKeyDownHome:$,InputKeyDownPageDown:ne,InputKeyDownPageUp:te,ItemClick:ae,ItemMouseMove:12,MenuMouseLeave:11,ToggleButtonClick:14});function de(e){var t=function(e){var t=U(e,"selectedItem"),n=U(e,"isOpen"),r=function(e){var t=U(e,"highlightedIndex");return t>-1&&e.isItemDisabled(e.items[t],t)?-1:t}(e),o=U(e,"inputValue");return{highlightedIndex:r<0&&t&&n?e.items.findIndex((function(n){return e.itemToKey(n)===e.itemToKey(t)})):r,isOpen:n,selectedItem:t,inputValue:o}}(e),n=t.selectedItem,r=t.inputValue;return""===r&&n&&void 0===e.defaultInputValue&&void 0===e.initialInputValue&&void 0===e.inputValue&&(r=e.itemToString(n)),d({},t,{inputValue:r})}d({},Z,{items:f().array.isRequired,isItemDisabled:f().func,inputValue:f().string,defaultInputValue:f().string,initialInputValue:f().string,inputId:f().string,onInputValueChange:f().func});var he=C,fe=d({},G,{isItemDisabled:function(){return!1}});function ge(e,t){var n,r,o=t.type,i=t.props,s=t.altKey;switch(o){case ae:r={isOpen:H(i,"isOpen"),highlightedIndex:_(i),selectedItem:i.items[t.index],inputValue:i.itemToString(i.items[t.index])};break;case X:r=e.isOpen?{highlightedIndex:k(e.highlightedIndex,1,i.items,i.isItemDisabled,!0)}:{highlightedIndex:s&&null==e.selectedItem?-1:W(i,e,1),isOpen:i.items.length>=0};break;case J:r=e.isOpen?s?q(i,e.highlightedIndex):{highlightedIndex:k(e.highlightedIndex,-1,i.items,i.isItemDisabled,!0)}:{highlightedIndex:W(i,e,-1),isOpen:i.items.length>=0};break;case re:r=q(i,e.highlightedIndex);break;case Q:r=d({isOpen:!1,highlightedIndex:-1},!e.isOpen&&{selectedItem:null,inputValue:""});break;case te:r={highlightedIndex:k(e.highlightedIndex,-10,i.items,i.isItemDisabled,!0)};break;case ne:r={highlightedIndex:k(e.highlightedIndex,10,i.items,i.isItemDisabled,!0)};break;case $:r={highlightedIndex:M(0,!1,i.items,i.isItemDisabled)};break;case ee:r={highlightedIndex:M(i.items.length-1,!0,i.items,i.isItemDisabled)};break;case ie:r=d({isOpen:!1,highlightedIndex:-1},e.highlightedIndex>=0&&(null==(n=i.items)?void 0:n.length)&&t.selectItem&&{selectedItem:i.items[e.highlightedIndex],inputValue:i.itemToString(i.items[e.highlightedIndex])});break;case oe:r={isOpen:!0,highlightedIndex:_(i),inputValue:t.inputValue};break;case se:r={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:W(i,e,0)};break;case le:r={selectedItem:t.selectedItem,inputValue:i.itemToString(t.selectedItem)};break;case ue:r={inputValue:t.inputValue};break;default:return function(e,t,n){var r,o=t.type,i=t.props;switch(o){case n.ItemMouseMove:r={highlightedIndex:t.disabled?-1:t.index};break;case n.MenuMouseLeave:r={highlightedIndex:-1};break;case n.ToggleButtonClick:case n.FunctionToggleMenu:r={isOpen:!e.isOpen,highlightedIndex:e.isOpen?-1:W(i,e,0)};break;case n.FunctionOpenMenu:r={isOpen:!0,highlightedIndex:W(i,e,0)};break;case n.FunctionCloseMenu:r={isOpen:!1};break;case n.FunctionSetHighlightedIndex:r={highlightedIndex:i.isItemDisabled(i.items[t.highlightedIndex],t.highlightedIndex)?-1:t.highlightedIndex};break;case n.FunctionSetInputValue:r={inputValue:t.inputValue};break;case n.FunctionReset:r={highlightedIndex:_(i),isOpen:H(i,"isOpen"),selectedItem:H(i,"selectedItem"),inputValue:H(i,"inputValue")};break;default:throw new Error("Reducer called without proper action type.")}return d({},e,r)}(e,t,ce)}return d({},e,r)}var pe=["onMouseLeave","refKey","ref"],me=["item","index","refKey","ref","onMouseMove","onMouseDown","onClick","onPress","disabled"],be=["onClick","onPress","refKey","ref"],ve=["onKeyDown","onChange","onInput","onBlur","onChangeText","onClick","refKey","ref"];function we(t){void 0===t&&(t={}),he(t,we);var n=d({},fe,t),r=n.items,o=n.scrollIntoView,i=n.environment,s=n.getA11yStatusMessage,a=function(t,n,r,o){var i=(0,e.useRef)(),s=B(t,n,r,o),a=s[0],l=s[1],u=Y();return(0,e.useEffect)((function(){I(n,"selectedItem")&&(u||n.itemToKey(n.selectedItem)!==n.itemToKey(i.current)&&l({type:ue,inputValue:n.itemToString(n.selectedItem)}),i.current=a.selectedItem===i.current?n.selectedItem:a.selectedItem)}),[a.selectedItem,n.selectedItem]),[O(a,n),l]}(ge,n,de,K),l=a[0],u=a[1],h=l.isOpen,f=l.highlightedIndex,g=l.selectedItem,p=l.inputValue,m=(0,e.useRef)(null),b=(0,e.useRef)({}),v=(0,e.useRef)(null),w=(0,e.useRef)(null),y=Y(),x=L(n),S=(0,e.useRef)(),k=z({state:l,props:n}),M=(0,e.useCallback)((function(e){return b.current[x.getItemId(e)]}),[x]);!function(t,n,r,o){void 0===o&&(o={});var i=o.document,s=Y();(0,e.useEffect)((function(){if(t&&!s&&i){var e=t(n);V(e,i)}}),r),(0,e.useEffect)((function(){return function(){var e,t;V.cancel(),(t=null==(e=i)?void 0:e.getElementById("a11y-status-message"))&&t.remove()}}),[i])}(s,l,[h,f,g,p],i);var D=function(t){var n=t.highlightedIndex,r=t.isOpen,o=t.itemRefs,i=t.getItemNodeFromIndex,s=t.menuElement,a=t.scrollIntoView,l=(0,e.useRef)(!0);return T((function(){n<0||!r||!Object.keys(o.current).length||(!1===l.current?l.current=!0:a(i(n),s))}),[n]),l}({menuElement:m.current,highlightedIndex:f,isOpen:h,itemRefs:b,scrollIntoView:o,getItemNodeFromIndex:M});j({props:n,state:l}),(0,e.useEffect)((function(){U(n,"isOpen")&&v.current&&v.current.focus()}),[]),(0,e.useEffect)((function(){y||(S.current=r.length)}));var P=function(t,n,r){var o=(0,e.useRef)({isMouseDown:!1,isTouchMove:!1,isTouchEnd:!1});return(0,e.useEffect)((function(){if(!t)return C;var e=n.map((function(e){return e.current}));function i(){o.current.isTouchEnd=!1,o.current.isMouseDown=!0}function s(n){o.current.isMouseDown=!1,F(n.target,e,t)||r()}function a(){o.current.isTouchEnd=!1,o.current.isTouchMove=!1}function l(){o.current.isTouchMove=!0}function u(n){o.current.isTouchEnd=!0,o.current.isTouchMove||F(n.target,e,t,!1)||r()}return t.addEventListener("mousedown",i),t.addEventListener("mouseup",s),t.addEventListener("touchstart",a),t.addEventListener("touchmove",l),t.addEventListener("touchend",u),function(){t.removeEventListener("mousedown",i),t.removeEventListener("mouseup",s),t.removeEventListener("touchstart",a),t.removeEventListener("touchmove",l),t.removeEventListener("touchend",u)}}),[t,r]),o.current}(i,[w,m,v],(0,e.useCallback)((function(){k.current.state.isOpen&&u({type:ie,selectItem:!1})}),[u,k])),A=C;(0,e.useEffect)((function(){h||(b.current={})}),[h]),(0,e.useEffect)((function(){var e;h&&null!=i&&i.document&&null!=v&&null!=(e=v.current)&&e.focus&&i.document.activeElement!==v.current&&v.current.focus()}),[h,i]);var N=(0,e.useMemo)((function(){return{ArrowDown:function(e){e.preventDefault(),u({type:X,altKey:e.altKey})},ArrowUp:function(e){e.preventDefault(),u({type:J,altKey:e.altKey})},Home:function(e){k.current.state.isOpen&&(e.preventDefault(),u({type:$}))},End:function(e){k.current.state.isOpen&&(e.preventDefault(),u({type:ee}))},Escape:function(e){var t=k.current.state;(t.isOpen||t.inputValue||t.selectedItem||t.highlightedIndex>-1)&&(e.preventDefault(),u({type:Q}))},Enter:function(e){k.current.state.isOpen&&229!==e.which&&(e.preventDefault(),u({type:re}))},PageUp:function(e){k.current.state.isOpen&&(e.preventDefault(),u({type:te}))},PageDown:function(e){k.current.state.isOpen&&(e.preventDefault(),u({type:ne}))}}}),[u,k]),G=(0,e.useCallback)((function(e){return d({id:x.labelId,htmlFor:x.inputId},e)}),[x]),H=(0,e.useCallback)((function(e,t){var n,r=void 0===e?{}:e,o=r.onMouseLeave,i=r.refKey,s=void 0===i?"ref":i,a=r.ref,l=c(r,pe),h=(void 0===t?{}:t).suppressRefError;return A("getMenuProps",void 0!==h&&h,s,m),d(((n={})[s]=R(a,(function(e){m.current=e})),n.id=x.menuId,n.role="listbox",n["aria-labelledby"]=l&&l["aria-label"]?void 0:""+x.labelId,n.onMouseLeave=E(o,(function(){u({type:11})})),n),l)}),[u,A,x]),W=(0,e.useCallback)((function(e){var t,n,r=void 0===e?{}:e,o=r.item,i=r.index,s=r.refKey,a=void 0===s?"ref":s,l=r.ref,h=r.onMouseMove,f=r.onMouseDown,g=r.onClick;r.onPress;var p=r.disabled,m=c(r,me);void 0!==p&&console.warn('Passing "disabled" as an argument to getItemProps is not supported anymore. Please use the isItemDisabled prop from useCombobox.');var v=k.current,w=v.props,y=v.state,C=function(e,t,n,r){var o,i;if(void 0===e){if(void 0===t)throw new Error(r);o=n[t],i=t}else i=void 0===t?n.indexOf(e):t,o=e;return[o,i]}(o,i,w.items,"Pass either item or index to getItemProps!"),S=C[0],O=C[1],I=w.isItemDisabled(S,O),M=g;return d(((t={})[a]=R(l,(function(e){e&&(b.current[x.getItemId(O)]=e)})),t["aria-disabled"]=I,t["aria-selected"]=O===y.highlightedIndex,t.id=x.getItemId(O),t.role="option",t),!I&&((n={}).onClick=E(M,(function(){u({type:ae,index:O})})),n),{onMouseMove:E(h,(function(){P.isTouchEnd||O===y.highlightedIndex||(D.current=!1,u({type:12,index:O,disabled:I}))})),onMouseDown:E(f,(function(e){return e.preventDefault()}))},m)}),[u,x,k,P,D]),q=(0,e.useCallback)((function(e){var t,n=void 0===e?{}:e,r=n.onClick;n.onPress;var o=n.refKey,i=void 0===o?"ref":o,s=n.ref,a=c(n,be),l=k.current.state;return d(((t={})[i]=R(s,(function(e){w.current=e})),t["aria-controls"]=x.menuId,t["aria-expanded"]=l.isOpen,t.id=x.toggleButtonId,t.tabIndex=-1,t),!a.disabled&&d({},{onClick:E(r,(function(){u({type:14})}))}),a)}),[u,k,x]),_=(0,e.useCallback)((function(e,t){var n,r=void 0===e?{}:e,o=r.onKeyDown,s=r.onChange,a=r.onInput,l=r.onBlur;r.onChangeText;var h=r.onClick,f=r.refKey,g=void 0===f?"ref":f,p=r.ref,m=c(r,ve),b=(void 0===t?{}:t).suppressRefError;A("getInputProps",void 0!==b&&b,g,v);var w,y=k.current.state,C={};return m.disabled||((w={}).onChange=E(s,a,(function(e){u({type:oe,inputValue:e.target.value})})),w.onKeyDown=E(o,(function(e){var t=function(e){var t=e.key,n=e.keyCode;return n>=37&&n<=40&&0!==t.indexOf("Arrow")?"Arrow"+t:t}(e);t&&N[t]&&N[t](e)})),w.onBlur=E(l,(function(e){if(null!=i&&i.document&&y.isOpen&&!P.isMouseDown){var t=null===e.relatedTarget&&i.document.activeElement!==i.document.body;u({type:ie,selectItem:!t})}})),w.onClick=E(h,(function(){u({type:se})})),C=w),d(((n={})[g]=R(p,(function(e){v.current=e})),n["aria-activedescendant"]=y.isOpen&&y.highlightedIndex>-1?x.getItemId(y.highlightedIndex):"",n["aria-autocomplete"]="list",n["aria-controls"]=x.menuId,n["aria-expanded"]=y.isOpen,n["aria-labelledby"]=m&&m["aria-label"]?void 0:x.labelId,n.autoComplete="off",n.id=x.inputId,n.role="combobox",n.value=y.inputValue,n),C,m)}),[u,x,i,N,k,P,A]),Z=(0,e.useCallback)((function(){u({type:15})}),[u]),ce=(0,e.useCallback)((function(){u({type:17})}),[u]),ye=(0,e.useCallback)((function(){u({type:16})}),[u]),Ce=(0,e.useCallback)((function(e){u({type:18,highlightedIndex:e})}),[u]),xe=(0,e.useCallback)((function(e){u({type:le,selectedItem:e})}),[u]);return{getItemProps:W,getLabelProps:G,getMenuProps:H,getInputProps:_,getToggleButtonProps:q,toggleMenu:Z,openMenu:ye,closeMenu:ce,setHighlightedIndex:Ce,setInputValue:(0,e.useCallback)((function(e){u({type:20,inputValue:e})}),[u]),selectItem:xe,reset:(0,e.useCallback)((function(){u({type:21})}),[u]),highlightedIndex:f,isOpen:h,selectedItem:g,inputValue:p}}we.stateChangeTypes=ce,f().array,f().array,f().array,f().func,f().number,f().number,f().number,f().func,f().func,f().string,f().string;const ye=window.ReactDOM;function Ce(e,t,n){let r,o=n.initialDeps??[];return()=>{var i,s,a,l;let u;n.key&&(null==(i=n.debug)?void 0:i.call(n))&&(u=Date.now());const c=e();if(c.length===o.length&&!c.some(((e,t)=>o[t]!==e)))return r;let d;if(o=c,n.key&&(null==(s=n.debug)?void 0:s.call(n))&&(d=Date.now()),r=t(...c),n.key&&(null==(a=n.debug)?void 0:a.call(n))){const e=Math.round(100*(Date.now()-u))/100,t=Math.round(100*(Date.now()-d))/100,r=t/16,o=(e,t)=>{for(e=String(e);e.length{let r;return function(...o){e.clearTimeout(r),r=e.setTimeout((()=>t.apply(this,o)),n)}},Ee=e=>e,Re=e=>{const t=Math.max(e.startIndex-e.overscan,0),n=Math.min(e.endIndex+e.overscan,e.count-1),r=[];for(let e=t;e<=n;e++)r.push(e);return r},Oe=(e,t)=>{const n=e.scrollElement;if(!n)return;const r=e.targetWindow;if(!r)return;const o=e=>{const{width:n,height:r}=e;t({width:Math.round(n),height:Math.round(r)})};if(o(n.getBoundingClientRect()),!r.ResizeObserver)return()=>{};const i=new r.ResizeObserver((e=>{const t=e[0];if(null==t?void 0:t.borderBoxSize){const e=t.borderBoxSize[0];if(e)return void o({width:e.inlineSize,height:e.blockSize})}o(n.getBoundingClientRect())}));return i.observe(n,{box:"border-box"}),()=>{i.unobserve(n)}},Ie={passive:!0},ke="undefined"==typeof window||"onscrollend"in window,Me=(e,t)=>{const n=e.scrollElement;if(!n)return;const r=e.targetWindow;if(!r)return;let o=0;const i=ke?()=>{}:Se(r,(()=>{t(o,!1)}),e.options.isScrollingResetDelay),s=r=>()=>{o=n[e.options.horizontal?"scrollLeft":"scrollTop"],i(),t(o,r)},a=s(!0),l=s(!1);return l(),n.addEventListener("scroll",a,Ie),n.addEventListener("scrollend",l,Ie),()=>{n.removeEventListener("scroll",a),n.removeEventListener("scrollend",l)}},Fe=(e,t,n)=>{if(null==t?void 0:t.borderBoxSize){const e=t.borderBoxSize[0];if(e)return Math.round(e[n.options.horizontal?"inlineSize":"blockSize"])}return Math.round(e.getBoundingClientRect()[n.options.horizontal?"width":"height"])},De=(e,{adjustments:t=0,behavior:n},r)=>{var o,i;const s=e+t;null==(i=null==(o=r.scrollElement)?void 0:o.scrollTo)||i.call(o,{[r.options.horizontal?"left":"top"]:s,behavior:n})};class Pe{constructor(e){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.scrollToIndexTimeoutId=null,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollDirection=null,this.scrollAdjustments=0,this.measureElementCache=new Map,this.observer=(()=>{let e=null;const t=()=>e||(this.targetWindow&&this.targetWindow.ResizeObserver?e=new this.targetWindow.ResizeObserver((e=>{e.forEach((e=>{this._measureElement(e.target,e)}))})):null);return{disconnect:()=>{var e;return null==(e=t())?void 0:e.disconnect()},observe:e=>{var n;return null==(n=t())?void 0:n.observe(e,{box:"border-box"})},unobserve:e=>{var n;return null==(n=t())?void 0:n.unobserve(e)}}})(),this.range=null,this.setOptions=e=>{Object.entries(e).forEach((([t,n])=>{void 0===n&&delete e[t]})),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:Ee,rangeExtractor:Re,onChange:()=>{},measureElement:Fe,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,...e}},this.notify=(e,t)=>{var n,r;const{startIndex:o,endIndex:i}=this.range??{startIndex:void 0,endIndex:void 0},s=this.calculateRange();(e||o!==(null==s?void 0:s.startIndex)||i!==(null==s?void 0:s.endIndex))&&(null==(r=(n=this.options).onChange)||r.call(n,this,t))},this.cleanup=()=>{this.unsubs.filter(Boolean).forEach((e=>e())),this.unsubs=[],this.scrollElement=null},this._didMount=()=>(this.measureElementCache.forEach(this.observer.observe),()=>{this.observer.disconnect(),this.cleanup()}),this._willUpdate=()=>{var e;const t=this.options.getScrollElement();this.scrollElement!==t&&(this.cleanup(),this.scrollElement=t,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=(null==(e=this.scrollElement)?void 0:e.window)??null,this._scrollToOffset(this.scrollOffset,{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,(e=>{this.scrollRect=e,this.notify(!1,!1)}))),this.unsubs.push(this.options.observeElementOffset(this,((e,t)=>{this.scrollAdjustments=0,this.scrollDirection=t?this.scrollOffsetthis.scrollRect[this.options.horizontal?"width":"height"],this.getMeasurementOptions=Ce((()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey]),((e,t,n,r)=>(this.pendingMeasuredCacheIndexes=[],{count:e,paddingStart:t,scrollMargin:n,getItemKey:r})),{key:!1}),this.getFurthestMeasurement=(e,t)=>{const n=new Map,r=new Map;for(let o=t-1;o>=0;o--){const t=e[o];if(n.has(t.lane))continue;const i=r.get(t.lane);if(null==i||t.end>i.end?r.set(t.lane,t):t.ende.end===t.end?e.index-t.index:e.end-t.end))[0]:void 0},this.getMeasurements=Ce((()=>[this.getMeasurementOptions(),this.itemSizeCache]),(({count:e,paddingStart:t,scrollMargin:n,getItemKey:r},o)=>{const i=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const s=this.measurementsCache.slice(0,i);for(let a=i;athis.options.debug}),this.calculateRange=Ce((()=>[this.getMeasurements(),this.getSize(),this.scrollOffset]),((e,t,n)=>this.range=e.length>0&&t>0?function({measurements:e,outerSize:t,scrollOffset:n}){const r=e.length-1,o=Ae(0,r,(t=>e[t].start),n);let i=o;for(;ithis.options.debug}),this.getIndexes=Ce((()=>[this.options.rangeExtractor,this.calculateRange(),this.options.overscan,this.options.count]),((e,t,n,r)=>null===t?[]:e({startIndex:t.startIndex,endIndex:t.endIndex,overscan:n,count:r})),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=e=>{const t=this.options.indexAttribute,n=e.getAttribute(t);return n?parseInt(n,10):(console.warn(`Missing attribute name '${t}={index}' on measured element.`),-1)},this._measureElement=(e,t)=>{const n=this.measurementsCache[this.indexFromElement(e)];if(!n||!e.isConnected)return void this.measureElementCache.forEach(((t,n)=>{t===e&&(this.observer.unobserve(e),this.measureElementCache.delete(n))}));const r=this.measureElementCache.get(n.key);r!==e&&(r&&this.observer.unobserve(r),this.observer.observe(e),this.measureElementCache.set(n.key,e));const o=this.options.measureElement(e,t,this);this.resizeItem(n,o)},this.resizeItem=(e,t)=>{const n=t-(this.itemSizeCache.get(e.key)??e.size);0!==n&&((void 0!==this.shouldAdjustScrollPositionOnItemSizeChange?this.shouldAdjustScrollPositionOnItemSizeChange(e,n,this):e.start{e&&this._measureElement(e,void 0)},this.getVirtualItems=Ce((()=>[this.getIndexes(),this.getMeasurements()]),((e,t)=>{const n=[];for(let r=0,o=e.length;rthis.options.debug}),this.getVirtualItemForOffset=e=>{const t=this.getMeasurements();return xe(t[Ae(0,t.length-1,(e=>xe(t[e]).start),e)])},this.getOffsetForAlignment=(e,t)=>{const n=this.getSize();"auto"===t&&(t=e<=this.scrollOffset?"start":e>=this.scrollOffset+n?"end":"start"),"start"===t||("end"===t?e-=n:"center"===t&&(e-=n/2));const r=this.options.horizontal?"scrollWidth":"scrollHeight",o=(this.scrollElement?"document"in this.scrollElement?this.scrollElement.document.documentElement[r]:this.scrollElement[r]:0)-this.getSize();return Math.max(Math.min(o,e),0)},this.getOffsetForIndex=(e,t="auto")=>{e=Math.max(0,Math.min(e,this.options.count-1));const n=xe(this.getMeasurements()[e]);if("auto"===t)if(n.end>=this.scrollOffset+this.getSize()-this.options.scrollPaddingEnd)t="end";else{if(!(n.start<=this.scrollOffset+this.options.scrollPaddingStart))return[this.scrollOffset,t];t="start"}const r="end"===t?n.end+this.options.scrollPaddingEnd:n.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(r,t),t]},this.isDynamicMode=()=>this.measureElementCache.size>0,this.cancelScrollToIndex=()=>{null!==this.scrollToIndexTimeoutId&&this.targetWindow&&(this.targetWindow.clearTimeout(this.scrollToIndexTimeoutId),this.scrollToIndexTimeoutId=null)},this.scrollToOffset=(e,{align:t="start",behavior:n}={})=>{this.cancelScrollToIndex(),"smooth"===n&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(e,t),{adjustments:void 0,behavior:n})},this.scrollToIndex=(e,{align:t="auto",behavior:n}={})=>{e=Math.max(0,Math.min(e,this.options.count-1)),this.cancelScrollToIndex(),"smooth"===n&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size.");const[r,o]=this.getOffsetForIndex(e,t);this._scrollToOffset(r,{adjustments:void 0,behavior:n}),"smooth"!==n&&this.isDynamicMode()&&this.targetWindow&&(this.scrollToIndexTimeoutId=this.targetWindow.setTimeout((()=>{if(this.scrollToIndexTimeoutId=null,this.measureElementCache.has(this.options.getItemKey(e))){const[t]=this.getOffsetForIndex(e,o);((e,t)=>Math.abs(e-t)<1)(t,this.scrollOffset)||this.scrollToIndex(e,{align:o,behavior:n})}else this.scrollToIndex(e,{align:o,behavior:n})})))},this.scrollBy=(e,{behavior:t}={})=>{this.cancelScrollToIndex(),"smooth"===t&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.scrollOffset+e,{adjustments:void 0,behavior:t})},this.getTotalSize=()=>{var e;const t=this.getMeasurements();let n;return n=0===t.length?this.options.paddingStart:1===this.options.lanes?(null==(e=t[t.length-1])?void 0:e.end)??0:Math.max(...t.slice(-this.options.lanes).map((e=>e.end))),n-this.options.scrollMargin+this.options.paddingEnd},this._scrollToOffset=(e,{adjustments:t,behavior:n})=>{this.options.scrollToFn(e,{behavior:n,adjustments:t},this)},this.measure=()=>{var e,t;this.itemSizeCache=new Map,null==(t=(e=this.options).onChange)||t.call(e,this,!1)},this.setOptions(e),this.scrollRect=this.options.initialRect,this.scrollOffset="function"==typeof this.options.initialOffset?this.options.initialOffset():this.options.initialOffset,this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach((e=>{this.itemSizeCache.set(e.key,e.size)})),this.notify(!1,!1)}}const Ae=(e,t,n,r)=>{for(;e<=t;){const o=(e+t)/2|0,i=n(o);if(ir))return o;t=o-1}}return e>0?e-1:0},Ve="undefined"!=typeof document?e.useLayoutEffect:e.useEffect;function Te(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t""===t||e.value.includes(t)||e.label.includes(t))},R){const[O,I]=(0,o.useState)(n),[k,M]=(0,o.useState)(w),F=(0,o.useRef)(null);(0,o.useEffect)((()=>{I(n)}),[n]),(0,o.useEffect)((()=>{M(w),w||H("")}),[w]);const D=function(t){return function(t){const n=e.useReducer((()=>({})),{})[1],r={...t,onChange:(e,r)=>{var o;r?(0,ye.flushSync)(n):n(),null==(o=t.onChange)||o.call(t,e,r)}},[o]=e.useState((()=>new Pe(r)));return o.setOptions(r),e.useEffect((()=>o._didMount()),[]),Ve((()=>o._willUpdate())),o}({observeElementRect:Oe,observeElementOffset:Me,scrollToFn:De,...t})}({count:O.length,getScrollElement:()=>F.current,estimateSize:(0,o.useCallback)((()=>33),[]),onChange:c}),P=(0,o.useMemo)((()=>{const e={initialInputValue:h,items:O,selectedItem:k,onInputValueChange({inputValue:e}){I(n.filter((t=>E(t,e)))),r&&r(e)},onSelectedItemChange({selectedItem:e}){M(e),e||H(""),a&&a(e,H,M)},itemToString:e=>e?e["label"===v?m:b]||e:""};return x&&(e.onHighlightedIndexChange=({highlightedIndex:e,type:t})=>{t!==we.stateChangeTypes.MenuMouseLeave&&D.scrollToIndex(e)}),e}),[x,k,O,h,E,r,a,n,m,b,v]),{isOpen:A,getToggleButtonProps:V,getLabelProps:T,getMenuProps:L,getInputProps:N,highlightedIndex:z,getItemProps:B,inputValue:G,setInputValue:H}=we(P);(0,o.useEffect)((()=>{H(h)}),[h]);const{id:U,...W}=T();return(0,e.createElement)(i.BaseControl,{id:U,label:t,help:p,...W,className:"gb-autocomplete"},(0,e.createElement)(e.Fragment,null,d&&(0,e.createElement)("div",{className:"gb-icon"},(0,e.createElement)(i.Tooltip,{text:d},(0,e.createElement)("div",null,(0,e.createElement)(i.Icon,{icon:u})))),(0,e.createElement)("div",{className:Le(Ne.control,x&&"is-virtualized",f)},(0,e.createElement)("div",{className:Ne.wrapper},y&&y({inputValue:G,items:O,setSelectedItem:M,setInputValue:H}),(0,e.createElement)("div",{className:Ne.inputWrapper},(0,e.createElement)("input",{placeholder:g,className:Le(Ne.input,S&&Ne.showClear),type:"text",...N({ref:R,value:G})}),S&&G&&(0,e.createElement)(i.Button,{className:Ne.clear,icon:ze,label:(0,s.__)("Clear","generateblocks-pro"),onClick:()=>{l&&l(),M(""),H("")}}),(0,e.createElement)("button",{"aria-label":(0,s.__)("toggle menu","generateblocks-pro"),className:Ne.toggle,type:"button",...V()},(0,e.createElement)("svg",{className:Ne.arrow,viewBox:"0 0 20 20",width:"20",height:"20",xmlns:"http://www.w3.org/2000/svg"},(0,e.createElement)("path",{transform:A?"rotate(180)":void 0,d:"M5 6l5 5 5-5 2 1-7 7-7-7 2-1z",fill:"#555",style:{transformOrigin:"center"}})))),C&&C({inputValue:G,items:O,setSelectedItem:M,setInputValue:H})),(0,e.createElement)("ul",{...L({ref:F,className:Le(Ne.menu,!(A&&O.length)&&Ne.hidden)})},x?(0,e.createElement)(e.Fragment,null,(0,e.createElement)("li",{key:"total-size",style:{height:D.getTotalSize(),marginBottom:0}}),D.getVirtualItems().map((({index:t,size:n,start:r})=>{const o=O[t],i=o[m]||o.value||o;return(0,e.createElement)("li",{className:Le(z===t&&Ne.focused,k===o&&Ne.selected,Ne.option),key:`${i}${t}`,...B({index:t,item:o}),style:{position:"absolute",top:0,left:0,width:"100%",height:n,transform:`translateY(${r}px)`}},(0,e.createElement)("span",null,i))}))):A&&O.map(((t,n)=>{const r=t[m]||t.value||t;return(0,e.createElement)("li",{className:Le(z===n&&Ne.focused,k===t&&Ne.selected,Ne.option),key:`${t}${n}`,...B({item:t,index:n})},(0,e.createElement)("span",null,r))}))))))})),Ge={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};let He;const Ue=new Uint8Array(16);function We(){if(!He&&(He="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!He))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return He(Ue)}const je=[];for(let e=0;e<256;++e)je.push((e+256).toString(16).slice(1));const qe=function(e,t,n){if(Ge.randomUUID&&!t&&!e)return Ge.randomUUID();const r=(e=e||{}).random||(e.rng||We)();if(r[6]=15&r[6]|64,r[8]=63&r[8]|128,t){n=n||0;for(let e=0;e<16;++e)t[n+e]=r[e];return t}return function(e,t=0){return je[e[t+0]]+je[e[t+1]]+je[e[t+2]]+je[e[t+3]]+"-"+je[e[t+4]]+je[e[t+5]]+"-"+je[e[t+6]]+je[e[t+7]]+"-"+je[e[t+8]]+je[e[t+9]]+"-"+je[e[t+10]]+je[e[t+11]]+je[e[t+12]]+je[e[t+13]]+je[e[t+14]]+je[e[t+15]]}(r)},Ke=(0,o.forwardRef)((function({id:t,label:n,value:r,checked:i,onChange:a,indeterminate:l,"aria-label":u,className:c,...d},h){const f=t||qe(),g=(0,o.useRef)(),p=h||g;if((0,o.useLayoutEffect)((()=>{p.current&&(p.current.indeterminate=l)}),[p.current]),!u&&!n)throw new Error((0,s.__)("Checkbox must have an accessible label","generateblocks-pro"));return(0,e.createElement)("div",{className:"components-checkbox-control gb-checkbox"},(0,e.createElement)("span",{className:"components-checkbox-control__input-container"},(0,e.createElement)("input",{type:"checkbox",className:Le("components-checkbox-control__input",c),id:f,checked:i,onChange:a,value:r,"aria-label":u,ref:p,...d}),l&&!i&&(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",role:"presentation",className:"components-checkbox-control__indeterminate","aria-hidden":"true",focusable:"false"},(0,e.createElement)("path",{d:"M7 11.5h10V13H7z"})),i&&(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",role:"presentation",className:"components-checkbox-control__checked","aria-hidden":"true",focusable:"false"},(0,e.createElement)("path",{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"}))),n&&(0,e.createElement)("label",{htmlFor:f,className:"components-checkbox-control__label"},n))})),Ye=window.wp.compose,_e=window.wp.blockEditor,Ze=window.wp.hooks;function Xe(){return(Xe=Object.assign||function(e){for(var t=1;t=0||(o[n]=e[n]);return o}function Qe(t){var n=(0,e.useRef)(t),r=(0,e.useRef)((function(e){n.current&&n.current(e)}));return n.current=t,r.current}var $e=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=1),e>n?n:e0:e.buttons>0)&&i.current?s(nt(i.current,e,l.current)):n(!1)},t=function(){return n(!1)};function n(n){var r=u.current,o=tt(i.current),s=n?o.addEventListener:o.removeEventListener;s(r?"touchmove":"mousemove",e),s(r?"touchend":"mouseup",t)}return[function(e){var t=e.nativeEvent,r=i.current;if(r&&(rt(t),!function(e,t){return t&&!et(e)}(t,u.current)&&r)){if(et(t)){u.current=!0;var o=t.changedTouches||[];o.length&&(l.current=o[0].identifier)}r.focus(),s(nt(r,t,l.current)),n(!0)}},function(e){var t=e.which||e.keyCode;t<37||t>40||(e.preventDefault(),a({left:39===t?.05:37===t?-.05:0,top:40===t?.05:38===t?-.05:0}))},n]}),[a,s]),d=c[0],h=c[1],f=c[2];return(0,e.useEffect)((function(){return f}),[f]),e.createElement("div",Xe({},o,{onTouchStart:d,onMouseDown:d,className:"react-colorful__interactive",ref:i,onKeyDown:h,tabIndex:0,role:"slider"}))})),it=function(e){return e.filter(Boolean).join(" ")},st=function(t){var n=t.color,r=t.left,o=t.top,i=void 0===o?.5:o,s=it(["react-colorful__pointer",t.className]);return e.createElement("div",{className:s,style:{top:100*i+"%",left:100*r+"%"}},e.createElement("div",{className:"react-colorful__pointer-fill",style:{backgroundColor:n}}))},at=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=Math.pow(10,t)),Math.round(n*e)/n},lt=(Math.PI,function(e){var t=e.s,n=e.v,r=e.a,o=(200-t)*n/100;return{h:at(e.h),s:at(o>0&&o<200?t*n/100/(o<=100?o:200-o)*100:0),l:at(o/2),a:at(r,2)}}),ut=function(e){var t=lt(e);return"hsl("+t.h+", "+t.s+"%, "+t.l+"%)"},ct=function(e){var t=lt(e);return"hsla("+t.h+", "+t.s+"%, "+t.l+"%, "+t.a+")"},dt=function(e){var t=e.h,n=e.s,r=e.v,o=e.a;t=t/360*6,n/=100,r/=100;var i=Math.floor(t),s=r*(1-n),a=r*(1-(t-i)*n),l=r*(1-(1-t+i)*n),u=i%6;return{r:at(255*[r,a,s,s,l,r][u]),g:at(255*[l,r,r,a,s,s][u]),b:at(255*[s,s,l,r,r,a][u]),a:at(o,2)}},ht=function(e){var t=/rgba?\(?\s*(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?[,\s]+(-?\d*\.?\d+)(%)?,?\s*[/\s]*(-?\d*\.?\d+)?(%)?\s*\)?/i.exec(e);return t?gt({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:void 0===t[7]?1:Number(t[7])/(t[8]?100:1)}):{h:0,s:0,v:0,a:1}},ft=ht,gt=function(e){var t=e.r,n=e.g,r=e.b,o=e.a,i=Math.max(t,n,r),s=i-Math.min(t,n,r),a=s?i===t?(n-r)/s:i===n?2+(r-t)/s:4+(t-n)/s:0;return{h:at(60*(a<0?a+6:a)),s:at(i?s/i*100:0),v:at(i/255*100),a:o}},pt=e.memo((function(t){var n=t.hue,r=t.onChange,o=it(["react-colorful__hue",t.className]);return e.createElement("div",{className:o},e.createElement(ot,{onMove:function(e){r({h:360*e.left})},onKey:function(e){r({h:$e(n+360*e.left,0,360)})},"aria-label":"Hue","aria-valuenow":at(n),"aria-valuemax":"360","aria-valuemin":"0"},e.createElement(st,{className:"react-colorful__hue-pointer",left:n/360,color:ut({h:n,s:100,v:100,a:1})})))})),mt=e.memo((function(t){var n=t.hsva,r=t.onChange,o={backgroundColor:ut({h:n.h,s:100,v:100,a:1})};return e.createElement("div",{className:"react-colorful__saturation",style:o},e.createElement(ot,{onMove:function(e){r({s:100*e.left,v:100-100*e.top})},onKey:function(e){r({s:$e(n.s+100*e.left,0,100),v:$e(n.v-100*e.top,0,100)})},"aria-label":"Color","aria-valuetext":"Saturation "+at(n.s)+"%, Brightness "+at(n.v)+"%"},e.createElement(st,{className:"react-colorful__saturation-pointer",top:1-n.v/100,left:n.s/100,color:ut(n)})))})),bt=function(e,t){return e.replace(/\s/g,"")===t.replace(/\s/g,"")};function vt(t,n,r){var o=Qe(r),i=(0,e.useState)((function(){return t.toHsva(n)})),s=i[0],a=i[1],l=(0,e.useRef)({color:n,hsva:s});(0,e.useEffect)((function(){if(!t.equal(n,l.current.color)){var e=t.toHsva(n);l.current={hsva:e,color:n},a(e)}}),[n,t]),(0,e.useEffect)((function(){var e;(function(e,t){if(e===t)return!0;for(var n in e)if(e[n]!==t[n])return!1;return!0})(s,l.current.hsva)||t.equal(e=t.fromHsva(s),l.current.color)||(l.current={hsva:s,color:e},o(e))}),[s,t,o]);var u=(0,e.useCallback)((function(e){a((function(t){return Object.assign({},t,e)}))}),[]);return[s,u]}var wt="undefined"!=typeof window?e.useLayoutEffect:e.useEffect,yt=new Map,Ct=function(e){wt((function(){var t=e.current?e.current.ownerDocument:document;if(void 0!==t&&!yt.has(t)){var r=t.createElement("style");r.innerHTML='.react-colorful{position:relative;display:flex;flex-direction:column;width:200px;height:200px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;cursor:default}.react-colorful__saturation{position:relative;flex-grow:1;border-color:transparent;border-bottom:12px solid #000;border-radius:8px 8px 0 0;background-image:linear-gradient(0deg,#000,transparent),linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.react-colorful__alpha-gradient,.react-colorful__pointer-fill{content:"";position:absolute;left:0;top:0;right:0;bottom:0;pointer-events:none;border-radius:inherit}.react-colorful__alpha-gradient,.react-colorful__saturation{box-shadow:inset 0 0 0 1px rgba(0,0,0,.05)}.react-colorful__alpha,.react-colorful__hue{position:relative;height:24px}.react-colorful__hue{background:linear-gradient(90deg,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red)}.react-colorful__last-control{border-radius:0 0 8px 8px}.react-colorful__interactive{position:absolute;left:0;top:0;right:0;bottom:0;border-radius:inherit;outline:none;touch-action:none}.react-colorful__pointer{position:absolute;z-index:1;box-sizing:border-box;width:28px;height:28px;transform:translate(-50%,-50%);background-color:#fff;border:2px solid #fff;border-radius:50%;box-shadow:0 2px 4px rgba(0,0,0,.2)}.react-colorful__interactive:focus .react-colorful__pointer{transform:translate(-50%,-50%) scale(1.1)}.react-colorful__alpha,.react-colorful__alpha-pointer{background-color:#fff;background-image:url(\'data:image/svg+xml;charset=utf-8,\')}.react-colorful__saturation-pointer{z-index:3}.react-colorful__hue-pointer{z-index:2}',yt.set(t,r);var o=n.nc;o&&r.setAttribute("nonce",o),t.head.appendChild(r)}}),[])},xt=function(t){var n=t.className,r=t.colorModel,o=t.color,i=void 0===o?r.defaultColor:o,s=t.onChange,a=Je(t,["className","colorModel","color","onChange"]),l=(0,e.useRef)(null);Ct(l);var u=vt(r,i,s),c=u[0],d=u[1],h=it(["react-colorful",n]);return e.createElement("div",Xe({},a,{ref:l,className:h}),e.createElement(mt,{hsva:c,onChange:d}),e.createElement(pt,{hue:c.h,onChange:d,className:"react-colorful__last-control"}))},St=function(t){var n=t.className,r=t.hsva,o=t.onChange,i={backgroundImage:"linear-gradient(90deg, "+ct(Object.assign({},r,{a:0}))+", "+ct(Object.assign({},r,{a:1}))+")"},s=it(["react-colorful__alpha",n]),a=at(100*r.a);return e.createElement("div",{className:s},e.createElement("div",{className:"react-colorful__alpha-gradient",style:i}),e.createElement(ot,{onMove:function(e){o({a:e.left})},onKey:function(e){o({a:$e(r.a+e.left)})},"aria-label":"Alpha","aria-valuetext":a+"%","aria-valuenow":a,"aria-valuemin":"0","aria-valuemax":"100"},e.createElement(st,{className:"react-colorful__alpha-pointer",left:r.a,color:ct(r)})))},Et=function(t){var n=t.className,r=t.colorModel,o=t.color,i=void 0===o?r.defaultColor:o,s=t.onChange,a=Je(t,["className","colorModel","color","onChange"]),l=(0,e.useRef)(null);Ct(l);var u=vt(r,i,s),c=u[0],d=u[1],h=it(["react-colorful",n]);return e.createElement("div",Xe({},a,{ref:l,className:h}),e.createElement(mt,{hsva:c,onChange:d}),e.createElement(pt,{hue:c.h,onChange:d}),e.createElement(St,{hsva:c,onChange:d,className:"react-colorful__last-control"}))},Rt={defaultColor:"rgba(0, 0, 0, 1)",toHsva:ht,fromHsva:function(e){var t=dt(e);return"rgba("+t.r+", "+t.g+", "+t.b+", "+t.a+")"},equal:bt},Ot=function(t){return e.createElement(Et,Xe({},t,{colorModel:Rt}))},It={defaultColor:"rgb(0, 0, 0)",toHsva:ft,fromHsva:function(e){var t=dt(e);return"rgb("+t.r+", "+t.g+", "+t.b+")"},equal:bt},kt=function(t){return e.createElement(xt,Xe({},t,{colorModel:It}))},Mt={grad:.9,turn:360,rad:360/(2*Math.PI)},Ft=function(e){return"string"==typeof e?e.length>0:"number"==typeof e},Dt=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=Math.pow(10,t)),Math.round(n*e)/n+0},Pt=function(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=1),e>n?n:e>t?e:t},At=function(e){return(e=isFinite(e)?e%360:0)>0?e:e+360},Vt=function(e){return{r:Pt(e.r,0,255),g:Pt(e.g,0,255),b:Pt(e.b,0,255),a:Pt(e.a)}},Tt=function(e){return{r:Dt(e.r),g:Dt(e.g),b:Dt(e.b),a:Dt(e.a,3)}},Lt=/^#([0-9a-f]{3,8})$/i,Nt=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},zt=function(e){var t=e.r,n=e.g,r=e.b,o=e.a,i=Math.max(t,n,r),s=i-Math.min(t,n,r),a=s?i===t?(n-r)/s:i===n?2+(r-t)/s:4+(t-n)/s:0;return{h:60*(a<0?a+6:a),s:i?s/i*100:0,v:i/255*100,a:o}},Bt=function(e){var t=e.h,n=e.s,r=e.v,o=e.a;t=t/360*6,n/=100,r/=100;var i=Math.floor(t),s=r*(1-n),a=r*(1-(t-i)*n),l=r*(1-(1-t+i)*n),u=i%6;return{r:255*[r,a,s,s,l,r][u],g:255*[l,r,r,a,s,s][u],b:255*[s,s,l,r,r,a][u],a:o}},Gt=function(e){return{h:At(e.h),s:Pt(e.s,0,100),l:Pt(e.l,0,100),a:Pt(e.a)}},Ht=function(e){return{h:Dt(e.h),s:Dt(e.s),l:Dt(e.l),a:Dt(e.a,3)}},Ut=function(e){return Bt((n=(t=e).s,{h:t.h,s:(n*=((r=t.l)<50?r:100-r)/100)>0?2*n/(r+n)*100:0,v:r+n,a:t.a}));var t,n,r},Wt=function(e){return{h:(t=zt(e)).h,s:(o=(200-(n=t.s))*(r=t.v)/100)>0&&o<200?n*r/100/(o<=100?o:200-o)*100:0,l:o/2,a:t.a};var t,n,r,o},jt=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,qt=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Kt=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Yt=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,_t={string:[[function(e){var t=Lt.exec(e);return t?(e=t[1]).length<=4?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:4===e.length?Dt(parseInt(e[3]+e[3],16)/255,2):1}:6===e.length||8===e.length?{r:parseInt(e.substr(0,2),16),g:parseInt(e.substr(2,2),16),b:parseInt(e.substr(4,2),16),a:8===e.length?Dt(parseInt(e.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(e){var t=Kt.exec(e)||Yt.exec(e);return t?t[2]!==t[4]||t[4]!==t[6]?null:Vt({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:void 0===t[7]?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(e){var t=jt.exec(e)||qt.exec(e);if(!t)return null;var n,r,o=Gt({h:(n=t[1],r=t[2],void 0===r&&(r="deg"),Number(n)*(Mt[r]||1)),s:Number(t[3]),l:Number(t[4]),a:void 0===t[5]?1:Number(t[5])/(t[6]?100:1)});return Ut(o)},"hsl"]],object:[[function(e){var t=e.r,n=e.g,r=e.b,o=e.a,i=void 0===o?1:o;return Ft(t)&&Ft(n)&&Ft(r)?Vt({r:Number(t),g:Number(n),b:Number(r),a:Number(i)}):null},"rgb"],[function(e){var t=e.h,n=e.s,r=e.l,o=e.a,i=void 0===o?1:o;if(!Ft(t)||!Ft(n)||!Ft(r))return null;var s=Gt({h:Number(t),s:Number(n),l:Number(r),a:Number(i)});return Ut(s)},"hsl"],[function(e){var t=e.h,n=e.s,r=e.v,o=e.a,i=void 0===o?1:o;if(!Ft(t)||!Ft(n)||!Ft(r))return null;var s=function(e){return{h:At(e.h),s:Pt(e.s,0,100),v:Pt(e.v,0,100),a:Pt(e.a)}}({h:Number(t),s:Number(n),v:Number(r),a:Number(i)});return Bt(s)},"hsv"]]},Zt=function(e,t){for(var n=0;n=.5},e.prototype.toHex=function(){return t=(e=Tt(this.rgba)).r,n=e.g,r=e.b,i=(o=e.a)<1?Nt(Dt(255*o)):"","#"+Nt(t)+Nt(n)+Nt(r)+i;var e,t,n,r,o,i},e.prototype.toRgb=function(){return Tt(this.rgba)},e.prototype.toRgbString=function(){return t=(e=Tt(this.rgba)).r,n=e.g,r=e.b,(o=e.a)<1?"rgba("+t+", "+n+", "+r+", "+o+")":"rgb("+t+", "+n+", "+r+")";var e,t,n,r,o},e.prototype.toHsl=function(){return Ht(Wt(this.rgba))},e.prototype.toHslString=function(){return t=(e=Ht(Wt(this.rgba))).h,n=e.s,r=e.l,(o=e.a)<1?"hsla("+t+", "+n+"%, "+r+"%, "+o+")":"hsl("+t+", "+n+"%, "+r+"%)";var e,t,n,r,o},e.prototype.toHsv=function(){return e=zt(this.rgba),{h:Dt(e.h),s:Dt(e.s),v:Dt(e.v),a:Dt(e.a,3)};var e},e.prototype.invert=function(){return en({r:255-(e=this.rgba).r,g:255-e.g,b:255-e.b,a:e.a});var e},e.prototype.saturate=function(e){return void 0===e&&(e=.1),en(Xt(this.rgba,e))},e.prototype.desaturate=function(e){return void 0===e&&(e=.1),en(Xt(this.rgba,-e))},e.prototype.grayscale=function(){return en(Xt(this.rgba,-1))},e.prototype.lighten=function(e){return void 0===e&&(e=.1),en(Qt(this.rgba,e))},e.prototype.darken=function(e){return void 0===e&&(e=.1),en(Qt(this.rgba,-e))},e.prototype.rotate=function(e){return void 0===e&&(e=15),this.hue(this.hue()+e)},e.prototype.alpha=function(e){return"number"==typeof e?en({r:(t=this.rgba).r,g:t.g,b:t.b,a:e}):Dt(this.rgba.a,3);var t},e.prototype.hue=function(e){var t=Wt(this.rgba);return"number"==typeof e?en({h:e,s:t.s,l:t.l,a:t.a}):Dt(t.h)},e.prototype.isEqual=function(e){return this.toHex()===en(e).toHex()},e}(),en=function(e){return e instanceof $t?e:new $t(e)};const tn={control:"Uy2rTDWqjs4vgNH0aeBm",toggleButton:"qLXIpwst_CtGTtmsg3mN",toggleIndicator:"UVmA1eywUsKVQzLMDooq",content:"eTonGpRD1VuB2tbLNegK",inputWrapper:"nc5TMqH__oA5bcPGTm0D",input:"_ubMuvqZvhc0awiEVNAL",clear:"f5wwshdAOOkfChALEoo2",palette:"OhNX_C7EMJcWKe5tqpKQ",opacity:"mos6VIbAjooq2LMyKr88"},nn="gb-color-picker-palettes";function rn(e){return{...e,color:`var(--wp--preset--color--${e.slug}, ${e.color})`}}function on(t){const{value:n,onChange:r,label:a,tooltip:l,"aria-label":u,colors:c,renderToggle:d,onClick:h,onOpacityChange:f,valueOpacity:g=1}=t,[p,m]=(0,o.useState)(n||""),b=(0,o.useRef)(null),v=1!==g?kt:Ot,w=(0,o.useMemo)((()=>(e=>{if(String(e).startsWith("var(")){const t=e.match(/\(([^)]+)\)/);if(t){const n=getComputedStyle(document.documentElement).getPropertyValue(t[1]);n&&(e=n)}}return en(e).toRgbString()})(n)),[n]),y=(0,Ye.useDebounce)(r,100);(0,o.useEffect)((()=>{n!==p&&m(n)}),[n]),(0,o.useEffect)((()=>{n!==p&&y(p);const e=setTimeout((()=>{b.current&&b.current.focus()}),10);return()=>clearTimeout(e)}),[p]);const C=function(){const[e=[],t=[]]=(0,_e.useSettings)("color.palette.custom","color.palette.theme");return(0,o.useMemo)((()=>[...e.map(rn),...t.map(rn)]),[e,t])}(),x=(0,Ze.applyFilters)("generateblocks.components.colorPalettes",c||C,t,C);(0,o.useEffect)((()=>{sessionStorage.setItem(nn,JSON.stringify(x))}),[x]);const S=qe();return(0,e.createElement)(i.BaseControl,{id:S,label:a,className:Le("gb-color-picker",tn.control),"data-gb-control":"ColorPickerControl"},(0,e.createElement)(i.Dropdown,{className:tn.toggle,contentClassName:tn.content,placement:"top left",renderToggle:({isOpen:t,onToggle:r})=>{if(d)return d({isOpen:t,onToggle:r});const o=(0,e.createElement)(i.Button,{className:tn.toggleButton,onClick:()=>{r(),h&&h()},"aria-expanded":t,"aria-label":u},(0,e.createElement)("span",{className:tn.toggleIndicator,style:{background:n?(s=n,a=g,s?(a||0===a)&&1!==a&&s.startsWith("#")?en(s).alpha(a).toRgbString():s:""):null}}));var s,a;return(0,e.createElement)(e.Fragment,null,l?(0,e.createElement)(i.Tooltip,{text:l},o):o)},renderContent:()=>{const t=sessionStorage.getItem(nn),r=sessionStorage?JSON.parse(t):x;return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(v,{color:w,onChange:e=>{en(e).isValid()&&(e=1===en(e).alpha()?en(e).toHex():e),m(e)}}),(0,e.createElement)("div",{className:tn.inputWrapper},(0,e.createElement)(i.TextControl,{ref:b,className:tn.input,type:"text",value:p,onChange:e=>{!e.startsWith("#")&&/^([0-9A-F]{3}){1,2}$/i.test(e)&&(e="#"+e),m(e)},onBlur:()=>{en(n).isValid()&&1===en(n).alpha()&&m(en(n).toHex())}}),(0,e.createElement)(i.Button,{size:"small",variant:"secondary",className:tn.clear,onClick:()=>{m(""),1!==g&&f(1)}},(0,s.__)("Clear","generateblocks"))),1!==g&&(0,e.createElement)("div",{className:tn.opacity},(0,e.createElement)(i.RangeControl,{label:(0,s.__)("Opacity","generateblocks"),value:g||0,onChange:e=>f(e),min:0,max:1,step:.01,initialPosition:1})),(0,e.createElement)(i.BaseControl,{className:tn.palette},(0,e.createElement)(_e.ColorPalette,{colors:r,value:n||"",onChange:e=>{m(e)},disableCustomColors:!0,clearable:!1})))}}))}const sn="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement;function an(e){const t=Object.prototype.toString.call(e);return"[object Window]"===t||"[object global]"===t}function ln(e){return"nodeType"in e}function un(e){var t,n;return e?an(e)?e:ln(e)&&null!=(t=null==(n=e.ownerDocument)?void 0:n.defaultView)?t:window:window}function cn(e){const{Document:t}=un(e);return e instanceof t}function dn(e){return!an(e)&&e instanceof un(e).HTMLElement}function hn(e){return e instanceof un(e).SVGElement}function fn(e){return e?an(e)?e.document:ln(e)?cn(e)?e:dn(e)||hn(e)?e.ownerDocument:document:document:document}const gn=sn?e.useLayoutEffect:e.useEffect;function pn(t){const n=(0,e.useRef)(t);return gn((()=>{n.current=t})),(0,e.useCallback)((function(){for(var e=arguments.length,t=new Array(e),r=0;r{r.current!==t&&(r.current=t)}),n),r}function bn(t,n){const r=(0,e.useRef)();return(0,e.useMemo)((()=>{const e=t(r.current);return r.current=e,e}),[...n])}function vn(t){const n=pn(t),r=(0,e.useRef)(null),o=(0,e.useCallback)((e=>{e!==r.current&&(null==n||n(e,r.current)),r.current=e}),[]);return[r,o]}function wn(t){const n=(0,e.useRef)();return(0,e.useEffect)((()=>{n.current=t}),[t]),n.current}let yn={};function Cn(t,n){return(0,e.useMemo)((()=>{if(n)return n;const e=null==yn[t]?0:yn[t]+1;return yn[t]=e,t+"-"+e}),[t,n])}function xn(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o{const r=Object.entries(n);for(const[n,o]of r){const r=t[n];null!=r&&(t[n]=r+e*o)}return t}),{...t})}}const Sn=xn(1),En=xn(-1);function Rn(e){if(!e)return!1;const{KeyboardEvent:t}=un(e.target);return t&&e instanceof t}function On(e){if(function(e){if(!e)return!1;const{TouchEvent:t}=un(e.target);return t&&e instanceof t}(e)){if(e.touches&&e.touches.length){const{clientX:t,clientY:n}=e.touches[0];return{x:t,y:n}}if(e.changedTouches&&e.changedTouches.length){const{clientX:t,clientY:n}=e.changedTouches[0];return{x:t,y:n}}}return function(e){return"clientX"in e&&"clientY"in e}(e)?{x:e.clientX,y:e.clientY}:null}const In=Object.freeze({Translate:{toString(e){if(!e)return;const{x:t,y:n}=e;return"translate3d("+(t?Math.round(t):0)+"px, "+(n?Math.round(n):0)+"px, 0)"}},Scale:{toString(e){if(!e)return;const{scaleX:t,scaleY:n}=e;return"scaleX("+t+") scaleY("+n+")"}},Transform:{toString(e){if(e)return[In.Translate.toString(e),In.Scale.toString(e)].join(" ")}},Transition:{toString(e){let{property:t,duration:n,easing:r}=e;return t+" "+n+"ms "+r}}}),kn="a,frame,iframe,input:not([type=hidden]):not(:disabled),select:not(:disabled),textarea:not(:disabled),button:not(:disabled),*[tabindex]";function Mn(e){return e.matches(kn)?e:e.querySelector(kn)}const Fn={display:"none"};function Dn(e){let{id:n,value:r}=e;return t().createElement("div",{id:n,style:Fn},r)}function Pn(e){let{id:n,announcement:r,ariaLiveType:o="assertive"}=e;return t().createElement("div",{id:n,style:{position:"fixed",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0 0 0 0)",clipPath:"inset(100%)",whiteSpace:"nowrap"},role:"status","aria-live":o,"aria-atomic":!0},r)}const An=(0,e.createContext)(null),Vn={draggable:"\n To pick up a draggable item, press the space bar.\n While dragging, use the arrow keys to move the item.\n Press space again to drop the item in its new position, or press escape to cancel.\n "},Tn={onDragStart(e){let{active:t}=e;return"Picked up draggable item "+t.id+"."},onDragOver(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was moved over droppable area "+n.id+".":"Draggable item "+t.id+" is no longer over a droppable area."},onDragEnd(e){let{active:t,over:n}=e;return n?"Draggable item "+t.id+" was dropped over droppable area "+n.id:"Draggable item "+t.id+" was dropped."},onDragCancel(e){let{active:t}=e;return"Dragging was cancelled. Draggable item "+t.id+" was dropped."}};function Ln(n){let{announcements:r=Tn,container:o,hiddenTextDescribedById:i,screenReaderInstructions:s=Vn}=n;const{announce:a,announcement:l}=function(){const[t,n]=(0,e.useState)("");return{announce:(0,e.useCallback)((e=>{null!=e&&n(e)}),[]),announcement:t}}(),u=Cn("DndLiveRegion"),[c,d]=(0,e.useState)(!1);if((0,e.useEffect)((()=>{d(!0)}),[]),function(t){const n=(0,e.useContext)(An);(0,e.useEffect)((()=>{if(!n)throw new Error("useDndMonitor must be used within a children of ");return n(t)}),[t,n])}((0,e.useMemo)((()=>({onDragStart(e){let{active:t}=e;a(r.onDragStart({active:t}))},onDragMove(e){let{active:t,over:n}=e;r.onDragMove&&a(r.onDragMove({active:t,over:n}))},onDragOver(e){let{active:t,over:n}=e;a(r.onDragOver({active:t,over:n}))},onDragEnd(e){let{active:t,over:n}=e;a(r.onDragEnd({active:t,over:n}))},onDragCancel(e){let{active:t,over:n}=e;a(r.onDragCancel({active:t,over:n}))}})),[a,r])),!c)return null;const h=t().createElement(t().Fragment,null,t().createElement(Dn,{id:i,value:s.draggable}),t().createElement(Pn,{id:u,announcement:l}));return o?(0,ye.createPortal)(h,o):h}var Nn;function zn(){}function Bn(t,n){return(0,e.useMemo)((()=>({sensor:t,options:null!=n?n:{}})),[t,n])}function Gn(){for(var t=arguments.length,n=new Array(t),r=0;r[...n].filter((e=>null!=e))),[...n])}!function(e){e.DragStart="dragStart",e.DragMove="dragMove",e.DragEnd="dragEnd",e.DragCancel="dragCancel",e.DragOver="dragOver",e.RegisterDroppable="registerDroppable",e.SetDroppableDisabled="setDroppableDisabled",e.UnregisterDroppable="unregisterDroppable"}(Nn||(Nn={}));const Hn=Object.freeze({x:0,y:0});function Un(e,t){return Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function Wn(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return n-r}function jn(e,t){let{data:{value:n}}=e,{data:{value:r}}=t;return r-n}function qn(e){let{left:t,top:n,height:r,width:o}=e;return[{x:t,y:n},{x:t+o,y:n},{x:t,y:n+r},{x:t+o,y:n+r}]}function Kn(e,t){if(!e||0===e.length)return null;const[n]=e;return t?n[t]:n}function Yn(e,t,n){return void 0===t&&(t=e.left),void 0===n&&(n=e.top),{x:t+.5*e.width,y:n+.5*e.height}}const Zn=e=>{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=Yn(t,t.left,t.top),i=[];for(const e of r){const{id:t}=e,r=n.get(t);if(r){const n=Un(Yn(r),o);i.push({id:t,data:{droppableContainer:e,value:n}})}}return i.sort(Wn)};function Xn(e,t){const n=Math.max(t.top,e.top),r=Math.max(t.left,e.left),o=Math.min(t.left+t.width,e.left+e.width),i=Math.min(t.top+t.height,e.top+e.height),s=o-r,a=i-n;if(r{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=[];for(const e of r){const{id:r}=e,i=n.get(r);if(i){const n=Xn(i,t);n>0&&o.push({id:r,data:{droppableContainer:e,value:n}})}}return o.sort(jn)};function Qn(e,t){return e&&t?{x:e.left-t.left,y:e.top-t.top}:Hn}function $n(e){return function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o({...t,top:t.top+e*n.y,bottom:t.bottom+e*n.y,left:t.left+e*n.x,right:t.right+e*n.x})),{...t})}}const er=$n(1);const tr={ignoreTransform:!1};function nr(e,t){void 0===t&&(t=tr);let n=e.getBoundingClientRect();if(t.ignoreTransform){const{transform:t,transformOrigin:r}=un(e).getComputedStyle(e);t&&(n=function(e,t,n){const r=function(e){if(e.startsWith("matrix3d(")){const t=e.slice(9,-1).split(/, /);return{x:+t[12],y:+t[13],scaleX:+t[0],scaleY:+t[5]}}if(e.startsWith("matrix(")){const t=e.slice(7,-1).split(/, /);return{x:+t[4],y:+t[5],scaleX:+t[0],scaleY:+t[3]}}return null}(t);if(!r)return e;const{scaleX:o,scaleY:i,x:s,y:a}=r,l=e.left-s-(1-o)*parseFloat(n),u=e.top-a-(1-i)*parseFloat(n.slice(n.indexOf(" ")+1)),c=o?e.width/o:e.width,d=i?e.height/i:e.height;return{width:c,height:d,top:u,right:l+c,bottom:u+d,left:l}}(n,t,r))}const{top:r,left:o,width:i,height:s,bottom:a,right:l}=n;return{top:r,left:o,width:i,height:s,bottom:a,right:l}}function rr(e){return nr(e,{ignoreTransform:!0})}function or(e,t){const n=[];return e?function r(o){if(null!=t&&n.length>=t)return n;if(!o)return n;if(cn(o)&&null!=o.scrollingElement&&!n.includes(o.scrollingElement))return n.push(o.scrollingElement),n;if(!dn(o)||hn(o))return n;if(n.includes(o))return n;const i=un(e).getComputedStyle(o);return o!==e&&function(e,t){void 0===t&&(t=un(e).getComputedStyle(e));const n=/(auto|scroll|overlay)/;return["overflow","overflowX","overflowY"].some((e=>{const r=t[e];return"string"==typeof r&&n.test(r)}))}(o,i)&&n.push(o),function(e,t){return void 0===t&&(t=un(e).getComputedStyle(e)),"fixed"===t.position}(o,i)?n:r(o.parentNode)}(e):n}function ir(e){const[t]=or(e,1);return null!=t?t:null}function sr(e){return sn&&e?an(e)?e:ln(e)?cn(e)||e===fn(e).scrollingElement?window:dn(e)?e:null:null:null}function ar(e){return an(e)?e.scrollX:e.scrollLeft}function lr(e){return an(e)?e.scrollY:e.scrollTop}function ur(e){return{x:ar(e),y:lr(e)}}var cr;function dr(e){return!(!sn||!e)&&e===document.scrollingElement}function hr(e){const t={x:0,y:0},n=dr(e)?{height:window.innerHeight,width:window.innerWidth}:{height:e.clientHeight,width:e.clientWidth},r={x:e.scrollWidth-n.width,y:e.scrollHeight-n.height};return{isTop:e.scrollTop<=t.y,isLeft:e.scrollLeft<=t.x,isBottom:e.scrollTop>=r.y,isRight:e.scrollLeft>=r.x,maxScroll:r,minScroll:t}}!function(e){e[e.Forward=1]="Forward",e[e.Backward=-1]="Backward"}(cr||(cr={}));const fr={x:.2,y:.2};function gr(e,t,n,r,o){let{top:i,left:s,right:a,bottom:l}=n;void 0===r&&(r=10),void 0===o&&(o=fr);const{isTop:u,isBottom:c,isLeft:d,isRight:h}=hr(e),f={x:0,y:0},g={x:0,y:0},p=t.height*o.y,m=t.width*o.x;return!u&&i<=t.top+p?(f.y=cr.Backward,g.y=r*Math.abs((t.top+p-i)/p)):!c&&l>=t.bottom-p&&(f.y=cr.Forward,g.y=r*Math.abs((t.bottom-p-l)/p)),!h&&a>=t.right-m?(f.x=cr.Forward,g.x=r*Math.abs((t.right-m-a)/m)):!d&&s<=t.left+m&&(f.x=cr.Backward,g.x=r*Math.abs((t.left+m-s)/m)),{direction:f,speed:g}}function pr(e){if(e===document.scrollingElement){const{innerWidth:e,innerHeight:t}=window;return{top:0,left:0,right:e,bottom:t,width:e,height:t}}const{top:t,left:n,right:r,bottom:o}=e.getBoundingClientRect();return{top:t,left:n,right:r,bottom:o,width:e.clientWidth,height:e.clientHeight}}function mr(e){return e.reduce(((e,t)=>Sn(e,ur(t))),Hn)}const br=[["x",["left","right"],function(e){return e.reduce(((e,t)=>e+ar(t)),0)}],["y",["top","bottom"],function(e){return e.reduce(((e,t)=>e+lr(t)),0)}]];class vr{constructor(e,t){this.rect=void 0,this.width=void 0,this.height=void 0,this.top=void 0,this.bottom=void 0,this.right=void 0,this.left=void 0;const n=or(t),r=mr(n);this.rect={...e},this.width=e.width,this.height=e.height;for(const[e,t,o]of br)for(const i of t)Object.defineProperty(this,i,{get:()=>{const t=o(n),s=r[e]-t;return this.rect[i]+s},enumerable:!0});Object.defineProperty(this,"rect",{enumerable:!1})}}class wr{constructor(e){this.target=void 0,this.listeners=[],this.removeAll=()=>{this.listeners.forEach((e=>{var t;return null==(t=this.target)?void 0:t.removeEventListener(...e)}))},this.target=e}add(e,t,n){var r;null==(r=this.target)||r.addEventListener(e,t,n),this.listeners.push([e,t,n])}}function yr(e,t){const n=Math.abs(e.x),r=Math.abs(e.y);return"number"==typeof t?Math.sqrt(n**2+r**2)>t:"x"in t&&"y"in t?n>t.x&&r>t.y:"x"in t?n>t.x:"y"in t&&r>t.y}var Cr,xr;function Sr(e){e.preventDefault()}function Er(e){e.stopPropagation()}!function(e){e.Click="click",e.DragStart="dragstart",e.Keydown="keydown",e.ContextMenu="contextmenu",e.Resize="resize",e.SelectionChange="selectionchange",e.VisibilityChange="visibilitychange"}(Cr||(Cr={})),function(e){e.Space="Space",e.Down="ArrowDown",e.Right="ArrowRight",e.Left="ArrowLeft",e.Up="ArrowUp",e.Esc="Escape",e.Enter="Enter"}(xr||(xr={}));const Rr={start:[xr.Space,xr.Enter],cancel:[xr.Esc],end:[xr.Space,xr.Enter]},Or=(e,t)=>{let{currentCoordinates:n}=t;switch(e.code){case xr.Right:return{...n,x:n.x+25};case xr.Left:return{...n,x:n.x-25};case xr.Down:return{...n,y:n.y+25};case xr.Up:return{...n,y:n.y-25}}};class Ir{constructor(e){this.props=void 0,this.autoScrollEnabled=!1,this.referenceCoordinates=void 0,this.listeners=void 0,this.windowListeners=void 0,this.props=e;const{event:{target:t}}=e;this.props=e,this.listeners=new wr(fn(t)),this.windowListeners=new wr(un(t)),this.handleKeyDown=this.handleKeyDown.bind(this),this.handleCancel=this.handleCancel.bind(this),this.attach()}attach(){this.handleStart(),this.windowListeners.add(Cr.Resize,this.handleCancel),this.windowListeners.add(Cr.VisibilityChange,this.handleCancel),setTimeout((()=>this.listeners.add(Cr.Keydown,this.handleKeyDown)))}handleStart(){const{activeNode:e,onStart:t}=this.props,n=e.node.current;n&&function(e,t){if(void 0===t&&(t=nr),!e)return;const{top:n,left:r,bottom:o,right:i}=t(e);ir(e)&&(o<=0||i<=0||n>=window.innerHeight||r>=window.innerWidth)&&e.scrollIntoView({block:"center",inline:"center"})}(n),t(Hn)}handleKeyDown(e){if(Rn(e)){const{active:t,context:n,options:r}=this.props,{keyboardCodes:o=Rr,coordinateGetter:i=Or,scrollBehavior:s="smooth"}=r,{code:a}=e;if(o.end.includes(a))return void this.handleEnd(e);if(o.cancel.includes(a))return void this.handleCancel(e);const{collisionRect:l}=n.current,u=l?{x:l.left,y:l.top}:Hn;this.referenceCoordinates||(this.referenceCoordinates=u);const c=i(e,{active:t,context:n.current,currentCoordinates:u});if(c){const t=En(c,u),r={x:0,y:0},{scrollableAncestors:o}=n.current;for(const n of o){const o=e.code,{isTop:i,isRight:a,isLeft:l,isBottom:u,maxScroll:d,minScroll:h}=hr(n),f=pr(n),g={x:Math.min(o===xr.Right?f.right-f.width/2:f.right,Math.max(o===xr.Right?f.left:f.left+f.width/2,c.x)),y:Math.min(o===xr.Down?f.bottom-f.height/2:f.bottom,Math.max(o===xr.Down?f.top:f.top+f.height/2,c.y))},p=o===xr.Right&&!a||o===xr.Left&&!l,m=o===xr.Down&&!u||o===xr.Up&&!i;if(p&&g.x!==c.x){const e=n.scrollLeft+t.x,i=o===xr.Right&&e<=d.x||o===xr.Left&&e>=h.x;if(i&&!t.y)return void n.scrollTo({left:e,behavior:s});r.x=i?n.scrollLeft-e:o===xr.Right?n.scrollLeft-d.x:n.scrollLeft-h.x,r.x&&n.scrollBy({left:-r.x,behavior:s});break}if(m&&g.y!==c.y){const e=n.scrollTop+t.y,i=o===xr.Down&&e<=d.y||o===xr.Up&&e>=h.y;if(i&&!t.x)return void n.scrollTo({top:e,behavior:s});r.y=i?n.scrollTop-e:o===xr.Down?n.scrollTop-d.y:n.scrollTop-h.y,r.y&&n.scrollBy({top:-r.y,behavior:s});break}}this.handleMove(e,Sn(En(c,this.referenceCoordinates),r))}}}handleMove(e,t){const{onMove:n}=this.props;e.preventDefault(),n(t)}handleEnd(e){const{onEnd:t}=this.props;e.preventDefault(),this.detach(),t()}handleCancel(e){const{onCancel:t}=this.props;e.preventDefault(),this.detach(),t()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll()}}function kr(e){return Boolean(e&&"distance"in e)}function Mr(e){return Boolean(e&&"delay"in e)}Ir.activators=[{eventName:"onKeyDown",handler:(e,t,n)=>{let{keyboardCodes:r=Rr,onActivation:o}=t,{active:i}=n;const{code:s}=e.nativeEvent;if(r.start.includes(s)){const t=i.activatorNode.current;return!(t&&e.target!==t||(e.preventDefault(),null==o||o({event:e.nativeEvent}),0))}return!1}}];class Fr{constructor(e,t,n){var r;void 0===n&&(n=function(e){const{EventTarget:t}=un(e);return e instanceof t?e:fn(e)}(e.event.target)),this.props=void 0,this.events=void 0,this.autoScrollEnabled=!0,this.document=void 0,this.activated=!1,this.initialCoordinates=void 0,this.timeoutId=null,this.listeners=void 0,this.documentListeners=void 0,this.windowListeners=void 0,this.props=e,this.events=t;const{event:o}=e,{target:i}=o;this.props=e,this.events=t,this.document=fn(i),this.documentListeners=new wr(this.document),this.listeners=new wr(n),this.windowListeners=new wr(un(i)),this.initialCoordinates=null!=(r=On(o))?r:Hn,this.handleStart=this.handleStart.bind(this),this.handleMove=this.handleMove.bind(this),this.handleEnd=this.handleEnd.bind(this),this.handleCancel=this.handleCancel.bind(this),this.handleKeydown=this.handleKeydown.bind(this),this.removeTextSelection=this.removeTextSelection.bind(this),this.attach()}attach(){const{events:e,props:{options:{activationConstraint:t,bypassActivationConstraint:n}}}=this;if(this.listeners.add(e.move.name,this.handleMove,{passive:!1}),this.listeners.add(e.end.name,this.handleEnd),this.windowListeners.add(Cr.Resize,this.handleCancel),this.windowListeners.add(Cr.DragStart,Sr),this.windowListeners.add(Cr.VisibilityChange,this.handleCancel),this.windowListeners.add(Cr.ContextMenu,Sr),this.documentListeners.add(Cr.Keydown,this.handleKeydown),t){if(null!=n&&n({event:this.props.event,activeNode:this.props.activeNode,options:this.props.options}))return this.handleStart();if(Mr(t))return void(this.timeoutId=setTimeout(this.handleStart,t.delay));if(kr(t))return}this.handleStart()}detach(){this.listeners.removeAll(),this.windowListeners.removeAll(),setTimeout(this.documentListeners.removeAll,50),null!==this.timeoutId&&(clearTimeout(this.timeoutId),this.timeoutId=null)}handleStart(){const{initialCoordinates:e}=this,{onStart:t}=this.props;e&&(this.activated=!0,this.documentListeners.add(Cr.Click,Er,{capture:!0}),this.removeTextSelection(),this.documentListeners.add(Cr.SelectionChange,this.removeTextSelection),t(e))}handleMove(e){var t;const{activated:n,initialCoordinates:r,props:o}=this,{onMove:i,options:{activationConstraint:s}}=o;if(!r)return;const a=null!=(t=On(e))?t:Hn,l=En(r,a);if(!n&&s){if(kr(s)){if(null!=s.tolerance&&yr(l,s.tolerance))return this.handleCancel();if(yr(l,s.distance))return this.handleStart()}return Mr(s)&&yr(l,s.tolerance)?this.handleCancel():void 0}e.cancelable&&e.preventDefault(),i(a)}handleEnd(){const{onEnd:e}=this.props;this.detach(),e()}handleCancel(){const{onCancel:e}=this.props;this.detach(),e()}handleKeydown(e){e.code===xr.Esc&&this.handleCancel()}removeTextSelection(){var e;null==(e=this.document.getSelection())||e.removeAllRanges()}}const Dr={move:{name:"pointermove"},end:{name:"pointerup"}};class Pr extends Fr{constructor(e){const{event:t}=e,n=fn(t.target);super(e,Dr,n)}}Pr.activators=[{eventName:"onPointerDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return!(!n.isPrimary||0!==n.button||(null==r||r({event:n}),0))}}];const Ar={move:{name:"mousemove"},end:{name:"mouseup"}};var Vr;!function(e){e[e.RightClick=2]="RightClick"}(Vr||(Vr={})),class extends Fr{constructor(e){super(e,Ar,fn(e.event.target))}}.activators=[{eventName:"onMouseDown",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;return n.button!==Vr.RightClick&&(null==r||r({event:n}),!0)}}];const Tr={move:{name:"touchmove"},end:{name:"touchend"}};var Lr,Nr;(class extends Fr{constructor(e){super(e,Tr)}static setup(){return window.addEventListener(Tr.move.name,e,{capture:!1,passive:!1}),function(){window.removeEventListener(Tr.move.name,e)};function e(){}}}).activators=[{eventName:"onTouchStart",handler:(e,t)=>{let{nativeEvent:n}=e,{onActivation:r}=t;const{touches:o}=n;return!(o.length>1||(null==r||r({event:n}),0))}}],function(e){e[e.Pointer=0]="Pointer",e[e.DraggableRect=1]="DraggableRect"}(Lr||(Lr={})),function(e){e[e.TreeOrder=0]="TreeOrder",e[e.ReversedTreeOrder=1]="ReversedTreeOrder"}(Nr||(Nr={}));const zr={x:{[cr.Backward]:!1,[cr.Forward]:!1},y:{[cr.Backward]:!1,[cr.Forward]:!1}};var Br,Gr;!function(e){e[e.Always=0]="Always",e[e.BeforeDragging=1]="BeforeDragging",e[e.WhileDragging=2]="WhileDragging"}(Br||(Br={})),function(e){e.Optimized="optimized"}(Gr||(Gr={}));const Hr=new Map;function Ur(e,t){return bn((n=>e?n||("function"==typeof t?t(e):e):null),[t,e])}function Wr(t){let{callback:n,disabled:r}=t;const o=pn(n),i=(0,e.useMemo)((()=>{if(r||"undefined"==typeof window||void 0===window.ResizeObserver)return;const{ResizeObserver:e}=window;return new e(o)}),[r]);return(0,e.useEffect)((()=>()=>null==i?void 0:i.disconnect()),[i]),i}function jr(e){return new vr(nr(e),e)}function qr(t,n,r){void 0===n&&(n=jr);const[o,i]=(0,e.useReducer)((function(e){if(!t)return null;var o;if(!1===t.isConnected)return null!=(o=null!=e?e:r)?o:null;const i=n(t);return JSON.stringify(e)===JSON.stringify(i)?e:i}),null),s=function(t){let{callback:n,disabled:r}=t;const o=pn(n),i=(0,e.useMemo)((()=>{if(r||"undefined"==typeof window||void 0===window.MutationObserver)return;const{MutationObserver:e}=window;return new e(o)}),[o,r]);return(0,e.useEffect)((()=>()=>null==i?void 0:i.disconnect()),[i]),i}({callback(e){if(t)for(const n of e){const{type:e,target:r}=n;if("childList"===e&&r instanceof HTMLElement&&r.contains(t)){i();break}}}}),a=Wr({callback:i});return gn((()=>{i(),t?(null==a||a.observe(t),null==s||s.observe(document.body,{childList:!0,subtree:!0})):(null==a||a.disconnect(),null==s||s.disconnect())}),[t]),o}const Kr=[];function Yr(t,n){void 0===n&&(n=[]);const r=(0,e.useRef)(null);return(0,e.useEffect)((()=>{r.current=null}),n),(0,e.useEffect)((()=>{const e=t!==Hn;e&&!r.current&&(r.current=t),!e&&r.current&&(r.current=null)}),[t]),r.current?En(t,r.current):Hn}function _r(t){return(0,e.useMemo)((()=>t?function(e){const t=e.innerWidth,n=e.innerHeight;return{top:0,left:0,right:t,bottom:n,width:t,height:n}}(t):null),[t])}const Zr=[];const Xr=[{sensor:Pr,options:{}},{sensor:Ir,options:{}}],Jr={current:{}},Qr={draggable:{measure:rr},droppable:{measure:rr,strategy:Br.WhileDragging,frequency:Gr.Optimized},dragOverlay:{measure:nr}};class $r extends Map{get(e){var t;return null!=e&&null!=(t=super.get(e))?t:void 0}toArray(){return Array.from(this.values())}getEnabled(){return this.toArray().filter((e=>{let{disabled:t}=e;return!t}))}getNodeFor(e){var t,n;return null!=(t=null==(n=this.get(e))?void 0:n.node.current)?t:void 0}}const eo={activatorEvent:null,active:null,activeNode:null,activeNodeRect:null,collisions:null,containerNodeRect:null,draggableNodes:new Map,droppableRects:new Map,droppableContainers:new $r,over:null,dragOverlay:{nodeRef:{current:null},rect:null,setRef:zn},scrollableAncestors:[],scrollableAncestorRects:[],measuringConfiguration:Qr,measureDroppableContainers:zn,windowRect:null,measuringScheduled:!1},to={activatorEvent:null,activators:[],active:null,activeNodeRect:null,ariaDescribedById:{draggable:""},dispatch:zn,draggableNodes:new Map,over:null,measureDroppableContainers:zn},no=(0,e.createContext)(to),ro=(0,e.createContext)(eo);function oo(){return{draggable:{active:null,initialCoordinates:{x:0,y:0},nodes:new Map,translate:{x:0,y:0}},droppable:{containers:new $r}}}function io(e,t){switch(t.type){case Nn.DragStart:return{...e,draggable:{...e.draggable,initialCoordinates:t.initialCoordinates,active:t.active}};case Nn.DragMove:return e.draggable.active?{...e,draggable:{...e.draggable,translate:{x:t.coordinates.x-e.draggable.initialCoordinates.x,y:t.coordinates.y-e.draggable.initialCoordinates.y}}}:e;case Nn.DragEnd:case Nn.DragCancel:return{...e,draggable:{...e.draggable,active:null,initialCoordinates:{x:0,y:0},translate:{x:0,y:0}}};case Nn.RegisterDroppable:{const{element:n}=t,{id:r}=n,o=new $r(e.droppable.containers);return o.set(r,n),{...e,droppable:{...e.droppable,containers:o}}}case Nn.SetDroppableDisabled:{const{id:n,key:r,disabled:o}=t,i=e.droppable.containers.get(n);if(!i||r!==i.key)return e;const s=new $r(e.droppable.containers);return s.set(n,{...i,disabled:o}),{...e,droppable:{...e.droppable,containers:s}}}case Nn.UnregisterDroppable:{const{id:n,key:r}=t,o=e.droppable.containers.get(n);if(!o||r!==o.key)return e;const i=new $r(e.droppable.containers);return i.delete(n),{...e,droppable:{...e.droppable,containers:i}}}default:return e}}function so(t){let{disabled:n}=t;const{active:r,activatorEvent:o,draggableNodes:i}=(0,e.useContext)(no),s=wn(o),a=wn(null==r?void 0:r.id);return(0,e.useEffect)((()=>{if(!n&&!o&&s&&null!=a){if(!Rn(s))return;if(document.activeElement===s.target)return;const e=i.get(a);if(!e)return;const{activatorNode:t,node:n}=e;if(!t.current&&!n.current)return;requestAnimationFrame((()=>{for(const e of[t.current,n.current]){if(!e)continue;const t=Mn(e);if(t){t.focus();break}}}))}}),[o,n,i,a,s]),null}const ao=(0,e.createContext)({...Hn,scaleX:1,scaleY:1});var lo;!function(e){e[e.Uninitialized=0]="Uninitialized",e[e.Initializing=1]="Initializing",e[e.Initialized=2]="Initialized"}(lo||(lo={}));const uo=(0,e.memo)((function(n){var r,o,i,s;let{id:a,accessibility:l,autoScroll:u=!0,children:c,sensors:d=Xr,collisionDetection:h=Jn,measuring:f,modifiers:g,...p}=n;const m=(0,e.useReducer)(io,void 0,oo),[b,v]=m,[w,y]=function(){const[t]=(0,e.useState)((()=>new Set)),n=(0,e.useCallback)((e=>(t.add(e),()=>t.delete(e))),[t]);return[(0,e.useCallback)((e=>{let{type:n,event:r}=e;t.forEach((e=>{var t;return null==(t=e[n])?void 0:t.call(e,r)}))}),[t]),n]}(),[C,x]=(0,e.useState)(lo.Uninitialized),S=C===lo.Initialized,{draggable:{active:E,nodes:R,translate:O},droppable:{containers:I}}=b,k=E?R.get(E):null,M=(0,e.useRef)({initial:null,translated:null}),F=(0,e.useMemo)((()=>{var e;return null!=E?{id:E,data:null!=(e=null==k?void 0:k.data)?e:Jr,rect:M}:null}),[E,k]),D=(0,e.useRef)(null),[P,A]=(0,e.useState)(null),[V,T]=(0,e.useState)(null),L=mn(p,Object.values(p)),N=Cn("DndDescribedBy",a),z=(0,e.useMemo)((()=>I.getEnabled()),[I]),B=(G=f,(0,e.useMemo)((()=>({draggable:{...Qr.draggable,...null==G?void 0:G.draggable},droppable:{...Qr.droppable,...null==G?void 0:G.droppable},dragOverlay:{...Qr.dragOverlay,...null==G?void 0:G.dragOverlay}})),[null==G?void 0:G.draggable,null==G?void 0:G.droppable,null==G?void 0:G.dragOverlay]));var G;const{droppableRects:H,measureDroppableContainers:U,measuringScheduled:W}=function(t,n){let{dragging:r,dependencies:o,config:i}=n;const[s,a]=(0,e.useState)(null),{frequency:l,measure:u,strategy:c}=i,d=(0,e.useRef)(t),h=function(){switch(c){case Br.Always:return!1;case Br.BeforeDragging:return r;default:return!r}}(),f=mn(h),g=(0,e.useCallback)((function(e){void 0===e&&(e=[]),f.current||a((t=>null===t?e:t.concat(e.filter((e=>!t.includes(e))))))}),[f]),p=(0,e.useRef)(null),m=bn((e=>{if(h&&!r)return Hr;if(!e||e===Hr||d.current!==t||null!=s){const e=new Map;for(let n of t){if(!n)continue;if(s&&s.length>0&&!s.includes(n.id)&&n.rect.current){e.set(n.id,n.rect.current);continue}const t=n.node.current,r=t?new vr(u(t),t):null;n.rect.current=r,r&&e.set(n.id,r)}return e}return e}),[t,s,r,h,u]);return(0,e.useEffect)((()=>{d.current=t}),[t]),(0,e.useEffect)((()=>{h||g()}),[r,h]),(0,e.useEffect)((()=>{s&&s.length>0&&a(null)}),[JSON.stringify(s)]),(0,e.useEffect)((()=>{h||"number"!=typeof l||null!==p.current||(p.current=setTimeout((()=>{g(),p.current=null}),l))}),[l,h,g,...o]),{droppableRects:m,measureDroppableContainers:g,measuringScheduled:null!=s}}(z,{dragging:S,dependencies:[O.x,O.y],config:B.droppable}),j=function(e,t){const n=null!==t?e.get(t):void 0,r=n?n.node.current:null;return bn((e=>{var n;return null===t?null:null!=(n=null!=r?r:e)?n:null}),[r,t])}(R,E),q=(0,e.useMemo)((()=>V?On(V):null),[V]),K=function(){const e=!1===(null==P?void 0:P.autoScrollEnabled),t="object"==typeof u?!1===u.enabled:!1===u,n=S&&!e&&!t;return"object"==typeof u?{...u,enabled:n}:{enabled:n}}(),Y=function(e,t){return Ur(e,t)}(j,B.draggable.measure);!function(t){let{activeNode:n,measure:r,initialRect:o,config:i=!0}=t;const s=(0,e.useRef)(!1),{x:a,y:l}="boolean"==typeof i?{x:i,y:i}:i;gn((()=>{if(!a&&!l||!n)return void(s.current=!1);if(s.current||!o)return;const e=null==n?void 0:n.node.current;if(!e||!1===e.isConnected)return;const t=Qn(r(e),o);if(a||(t.x=0),l||(t.y=0),s.current=!0,Math.abs(t.x)>0||Math.abs(t.y)>0){const n=ir(e);n&&n.scrollBy({top:t.y,left:t.x})}}),[n,a,l,o,r])}({activeNode:E?R.get(E):null,config:K.layoutShiftCompensation,initialRect:Y,measure:B.draggable.measure});const _=qr(j,B.draggable.measure,Y),Z=qr(j?j.parentElement:null),X=(0,e.useRef)({activatorEvent:null,active:null,activeNode:j,collisionRect:null,collisions:null,droppableRects:H,draggableNodes:R,draggingNode:null,draggingNodeRect:null,droppableContainers:I,over:null,scrollableAncestors:[],scrollAdjustedTranslate:null}),J=I.getNodeFor(null==(r=X.current.over)?void 0:r.id),Q=function(t){let{measure:n}=t;const[r,o]=(0,e.useState)(null),i=Wr({callback:(0,e.useCallback)((e=>{for(const{target:t}of e)if(dn(t)){o((e=>{const r=n(t);return e?{...e,width:r.width,height:r.height}:r}));break}}),[n])}),s=(0,e.useCallback)((e=>{const t=function(e){if(!e)return null;if(e.children.length>1)return e;const t=e.children[0];return dn(t)?t:e}(e);null==i||i.disconnect(),t&&(null==i||i.observe(t)),o(t?n(t):null)}),[n,i]),[a,l]=vn(s);return(0,e.useMemo)((()=>({nodeRef:a,rect:r,setRef:l})),[r,a,l])}({measure:B.dragOverlay.measure}),$=null!=(o=Q.nodeRef.current)?o:j,ee=S?null!=(i=Q.rect)?i:_:null,te=Boolean(Q.nodeRef.current&&Q.rect),ne=Qn(re=te?null:_,Ur(re));var re;const oe=_r($?un($):null),ie=function(t){const n=(0,e.useRef)(t),r=bn((e=>t?e&&e!==Kr&&t&&n.current&&t.parentNode===n.current.parentNode?e:or(t):Kr),[t]);return(0,e.useEffect)((()=>{n.current=t}),[t]),r}(S?null!=J?J:j:null),se=function(t,n){void 0===n&&(n=nr);const[r]=t,o=_r(r?un(r):null),[i,s]=(0,e.useReducer)((function(){return t.length?t.map((e=>dr(e)?o:new vr(n(e),e))):Zr}),Zr),a=Wr({callback:s});return t.length>0&&i===Zr&&s(),gn((()=>{t.length?t.forEach((e=>null==a?void 0:a.observe(e))):(null==a||a.disconnect(),s())}),[t]),i}(ie),ae=function(e,t){let{transform:n,...r}=t;return null!=e&&e.length?e.reduce(((e,t)=>t({transform:e,...r})),n):n}(g,{transform:{x:O.x-ne.x,y:O.y-ne.y,scaleX:1,scaleY:1},activatorEvent:V,active:F,activeNodeRect:_,containerNodeRect:Z,draggingNodeRect:ee,over:X.current.over,overlayNodeRect:Q.rect,scrollableAncestors:ie,scrollableAncestorRects:se,windowRect:oe}),le=q?Sn(q,O):null,ue=function(t){const[n,r]=(0,e.useState)(null),o=(0,e.useRef)(t),i=(0,e.useCallback)((e=>{const t=sr(e.target);t&&r((e=>e?(e.set(t,ur(t)),new Map(e)):null))}),[]);return(0,e.useEffect)((()=>{const e=o.current;if(t!==e){n(e);const s=t.map((e=>{const t=sr(e);return t?(t.addEventListener("scroll",i,{passive:!0}),[t,ur(t)]):null})).filter((e=>null!=e));r(s.length?new Map(s):null),o.current=t}return()=>{n(t),n(e)};function n(e){e.forEach((e=>{const t=sr(e);null==t||t.removeEventListener("scroll",i)}))}}),[i,t]),(0,e.useMemo)((()=>t.length?n?Array.from(n.values()).reduce(((e,t)=>Sn(e,t)),Hn):mr(t):Hn),[t,n])}(ie),ce=Yr(ue),de=Yr(ue,[_]),he=Sn(ae,ce),fe=ee?er(ee,ae):null,ge=F&&fe?h({active:F,collisionRect:fe,droppableRects:H,droppableContainers:z,pointerCoordinates:le}):null,pe=Kn(ge,"id"),[me,be]=(0,e.useState)(null),ve=function(e,t,n){return{...e,scaleX:t&&n?t.width/n.width:1,scaleY:t&&n?t.height/n.height:1}}(te?ae:Sn(ae,de),null!=(s=null==me?void 0:me.rect)?s:null,_),we=(0,e.useCallback)(((e,t)=>{let{sensor:n,options:r}=t;if(null==D.current)return;const o=R.get(D.current);if(!o)return;const i=e.nativeEvent,s=new n({active:D.current,activeNode:o,event:i,options:r,context:X,onStart(e){const t=D.current;if(null==t)return;const n=R.get(t);if(!n)return;const{onDragStart:r}=L.current,o={active:{id:t,data:n.data,rect:M}};(0,ye.unstable_batchedUpdates)((()=>{null==r||r(o),x(lo.Initializing),v({type:Nn.DragStart,initialCoordinates:e,active:t}),w({type:"onDragStart",event:o})}))},onMove(e){v({type:Nn.DragMove,coordinates:e})},onEnd:a(Nn.DragEnd),onCancel:a(Nn.DragCancel)});function a(e){return async function(){const{active:t,collisions:n,over:r,scrollAdjustedTranslate:o}=X.current;let s=null;if(t&&o){const{cancelDrop:a}=L.current;s={activatorEvent:i,active:t,collisions:n,delta:o,over:r},e===Nn.DragEnd&&"function"==typeof a&&await Promise.resolve(a(s))&&(e=Nn.DragCancel)}D.current=null,(0,ye.unstable_batchedUpdates)((()=>{v({type:e}),x(lo.Uninitialized),be(null),A(null),T(null);const t=e===Nn.DragEnd?"onDragEnd":"onDragCancel";if(s){const e=L.current[t];null==e||e(s),w({type:t,event:s})}}))}}(0,ye.unstable_batchedUpdates)((()=>{A(s),T(e.nativeEvent)}))}),[R]),Ce=(0,e.useCallback)(((e,t)=>(n,r)=>{const o=n.nativeEvent,i=R.get(r);if(null!==D.current||!i||o.dndKit||o.defaultPrevented)return;const s={active:i};!0===e(n,t.options,s)&&(o.dndKit={capturedBy:t.sensor},D.current=r,we(n,t))}),[R,we]),xe=function(t,n){return(0,e.useMemo)((()=>t.reduce(((e,t)=>{const{sensor:r}=t;return[...e,...r.activators.map((e=>({eventName:e.eventName,handler:n(e.handler,t)})))]}),[])),[t,n])}(d,Ce);!function(t){(0,e.useEffect)((()=>{if(!sn)return;const e=t.map((e=>{let{sensor:t}=e;return null==t.setup?void 0:t.setup()}));return()=>{for(const t of e)null==t||t()}}),t.map((e=>{let{sensor:t}=e;return t})))}(d),gn((()=>{_&&C===lo.Initializing&&x(lo.Initialized)}),[_,C]),(0,e.useEffect)((()=>{const{onDragMove:e}=L.current,{active:t,activatorEvent:n,collisions:r,over:o}=X.current;if(!t||!n)return;const i={active:t,activatorEvent:n,collisions:r,delta:{x:he.x,y:he.y},over:o};(0,ye.unstable_batchedUpdates)((()=>{null==e||e(i),w({type:"onDragMove",event:i})}))}),[he.x,he.y]),(0,e.useEffect)((()=>{const{active:e,activatorEvent:t,collisions:n,droppableContainers:r,scrollAdjustedTranslate:o}=X.current;if(!e||null==D.current||!t||!o)return;const{onDragOver:i}=L.current,s=r.get(pe),a=s&&s.rect.current?{id:s.id,rect:s.rect.current,data:s.data,disabled:s.disabled}:null,l={active:e,activatorEvent:t,collisions:n,delta:{x:o.x,y:o.y},over:a};(0,ye.unstable_batchedUpdates)((()=>{be(a),null==i||i(l),w({type:"onDragOver",event:l})}))}),[pe]),gn((()=>{X.current={activatorEvent:V,active:F,activeNode:j,collisionRect:fe,collisions:ge,droppableRects:H,draggableNodes:R,draggingNode:$,draggingNodeRect:ee,droppableContainers:I,over:me,scrollableAncestors:ie,scrollAdjustedTranslate:he},M.current={initial:ee,translated:fe}}),[F,j,ge,fe,R,$,ee,H,I,me,ie,he]),function(t){let{acceleration:n,activator:r=Lr.Pointer,canScroll:o,draggingRect:i,enabled:s,interval:a=5,order:l=Nr.TreeOrder,pointerCoordinates:u,scrollableAncestors:c,scrollableAncestorRects:d,delta:h,threshold:f}=t;const g=function(e){let{delta:t,disabled:n}=e;const r=wn(t);return bn((e=>{if(n||!r||!e)return zr;const o=Math.sign(t.x-r.x),i=Math.sign(t.y-r.y);return{x:{[cr.Backward]:e.x[cr.Backward]||-1===o,[cr.Forward]:e.x[cr.Forward]||1===o},y:{[cr.Backward]:e.y[cr.Backward]||-1===i,[cr.Forward]:e.y[cr.Forward]||1===i}}}),[n,t,r])}({delta:h,disabled:!s}),[p,m]=function(){const t=(0,e.useRef)(null);return[(0,e.useCallback)(((e,n)=>{t.current=setInterval(e,n)}),[]),(0,e.useCallback)((()=>{null!==t.current&&(clearInterval(t.current),t.current=null)}),[])]}(),b=(0,e.useRef)({x:0,y:0}),v=(0,e.useRef)({x:0,y:0}),w=(0,e.useMemo)((()=>{switch(r){case Lr.Pointer:return u?{top:u.y,bottom:u.y,left:u.x,right:u.x}:null;case Lr.DraggableRect:return i}}),[r,i,u]),y=(0,e.useRef)(null),C=(0,e.useCallback)((()=>{const e=y.current;if(!e)return;const t=b.current.x*v.current.x,n=b.current.y*v.current.y;e.scrollBy(t,n)}),[]),x=(0,e.useMemo)((()=>l===Nr.TreeOrder?[...c].reverse():c),[l,c]);(0,e.useEffect)((()=>{if(s&&c.length&&w){for(const e of x){if(!1===(null==o?void 0:o(e)))continue;const t=c.indexOf(e),r=d[t];if(!r)continue;const{direction:i,speed:s}=gr(e,r,w,n,f);for(const e of["x","y"])g[e][i[e]]||(s[e]=0,i[e]=0);if(s.x>0||s.y>0)return m(),y.current=e,p(C,a),b.current=s,void(v.current=i)}b.current={x:0,y:0},v.current={x:0,y:0},m()}else m()}),[n,C,o,m,s,a,JSON.stringify(w),JSON.stringify(g),p,c,x,d,JSON.stringify(f)])}({...K,delta:O,draggingRect:fe,pointerCoordinates:le,scrollableAncestors:ie,scrollableAncestorRects:se});const Se=(0,e.useMemo)((()=>({active:F,activeNode:j,activeNodeRect:_,activatorEvent:V,collisions:ge,containerNodeRect:Z,dragOverlay:Q,draggableNodes:R,droppableContainers:I,droppableRects:H,over:me,measureDroppableContainers:U,scrollableAncestors:ie,scrollableAncestorRects:se,measuringConfiguration:B,measuringScheduled:W,windowRect:oe})),[F,j,_,V,ge,Z,Q,R,I,H,me,U,ie,se,B,W,oe]),Ee=(0,e.useMemo)((()=>({activatorEvent:V,activators:xe,active:F,activeNodeRect:_,ariaDescribedById:{draggable:N},dispatch:v,draggableNodes:R,over:me,measureDroppableContainers:U})),[V,xe,F,_,v,N,R,me,U]);return t().createElement(An.Provider,{value:y},t().createElement(no.Provider,{value:Ee},t().createElement(ro.Provider,{value:Se},t().createElement(ao.Provider,{value:ve},c)),t().createElement(so,{disabled:!1===(null==l?void 0:l.restoreFocus)})),t().createElement(Ln,{...l,hiddenTextDescribedById:N}))})),co=(0,e.createContext)(null),ho="button",fo="Droppable";const go="Droppable",po={timeout:25};function mo(e,t,n){const r=e.slice();return r.splice(n<0?r.length+n:n,0,r.splice(t,1)[0]),r}function bo(e,t){return e.reduce(((e,n,r)=>{const o=t.get(n);return o&&(e[r]=o),e}),Array(e.length))}function vo(e){return null!==e&&e>=0}const wo=e=>{let{rects:t,activeIndex:n,overIndex:r,index:o}=e;const i=mo(t,r,n),s=t[o],a=i[o];return a&&s?{x:a.left-s.left,y:a.top-s.top,scaleX:a.width/s.width,scaleY:a.height/s.height}:null},yo={scaleX:1,scaleY:1},Co=e=>{var t;let{activeIndex:n,activeNodeRect:r,index:o,rects:i,overIndex:s}=e;const a=null!=(t=i[n])?t:r;if(!a)return null;if(o===n){const e=i[s];return e?{x:0,y:nn&&o<=s?{x:0,y:-a.height-l,...yo}:o=s?{x:0,y:a.height+l,...yo}:{x:0,y:0,...yo}},xo="Sortable",So=t().createContext({activeIndex:-1,containerId:xo,disableTransforms:!1,items:[],overIndex:-1,useDragOverlay:!1,sortedRects:[],strategy:wo,disabled:{draggable:!1,droppable:!1}});function Eo(n){let{children:r,id:o,items:i,strategy:s=wo,disabled:a=!1}=n;const{active:l,dragOverlay:u,droppableRects:c,over:d,measureDroppableContainers:h}=(0,e.useContext)(ro),f=Cn(xo,o),g=Boolean(null!==u.rect),p=(0,e.useMemo)((()=>i.map((e=>"object"==typeof e&&"id"in e?e.id:e))),[i]),m=null!=l,b=l?p.indexOf(l.id):-1,v=d?p.indexOf(d.id):-1,w=(0,e.useRef)(p),y=!function(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0;n{y&&m&&h(p)}),[y,p,m,h]),(0,e.useEffect)((()=>{w.current=p}),[p]);const S=(0,e.useMemo)((()=>({activeIndex:b,containerId:f,disabled:x,disableTransforms:C,items:p,overIndex:v,useDragOverlay:g,sortedRects:bo(p,c),strategy:s})),[b,f,x.draggable,x.droppable,C,p,v,c,g,s]);return t().createElement(So.Provider,{value:S},r)}const Ro=e=>{let{id:t,items:n,activeIndex:r,overIndex:o}=e;return mo(n,r,o).indexOf(t)},Oo=e=>{let{containerId:t,isSorting:n,wasDragging:r,index:o,items:i,newIndex:s,previousItems:a,previousContainerId:l,transition:u}=e;return!(!u||!r||a!==i&&o===s||!n&&(s===o||t!==l))},Io={duration:200,easing:"ease"},ko="transform",Mo=In.Transition.toString({property:ko,duration:0,easing:"linear"}),Fo={roleDescription:"sortable"};function Do(t){let{animateLayoutChanges:n=Oo,attributes:r,disabled:o,data:i,getNewIndex:s=Ro,id:a,strategy:l,resizeObserverConfig:u,transition:c=Io}=t;const{items:d,containerId:h,activeIndex:f,disabled:g,disableTransforms:p,sortedRects:m,overIndex:b,useDragOverlay:v,strategy:w}=(0,e.useContext)(So),y=function(e,t){var n,r;return"boolean"==typeof e?{draggable:e,droppable:!1}:{draggable:null!=(n=null==e?void 0:e.draggable)?n:t.draggable,droppable:null!=(r=null==e?void 0:e.droppable)?r:t.droppable}}(o,g),C=d.indexOf(a),x=(0,e.useMemo)((()=>({sortable:{containerId:h,index:C,items:d},...i})),[h,i,C,d]),S=(0,e.useMemo)((()=>d.slice(d.indexOf(a))),[d,a]),{rect:E,node:R,isOver:O,setNodeRef:I}=function(t){let{data:n,disabled:r=!1,id:o,resizeObserverConfig:i}=t;const s=Cn(go),{active:a,dispatch:l,over:u,measureDroppableContainers:c}=(0,e.useContext)(no),d=(0,e.useRef)({disabled:r}),h=(0,e.useRef)(!1),f=(0,e.useRef)(null),g=(0,e.useRef)(null),{disabled:p,updateMeasurementsFor:m,timeout:b}={...po,...i},v=mn(null!=m?m:o),w=Wr({callback:(0,e.useCallback)((()=>{h.current?(null!=g.current&&clearTimeout(g.current),g.current=setTimeout((()=>{c(Array.isArray(v.current)?v.current:[v.current]),g.current=null}),b)):h.current=!0}),[b]),disabled:p||!a}),y=(0,e.useCallback)(((e,t)=>{w&&(t&&(w.unobserve(t),h.current=!1),e&&w.observe(e))}),[w]),[C,x]=vn(y),S=mn(n);return(0,e.useEffect)((()=>{w&&C.current&&(w.disconnect(),h.current=!1,w.observe(C.current))}),[C,w]),gn((()=>(l({type:Nn.RegisterDroppable,element:{id:o,key:s,disabled:r,node:C,rect:f,data:S}}),()=>l({type:Nn.UnregisterDroppable,key:s,id:o}))),[o]),(0,e.useEffect)((()=>{r!==d.current.disabled&&(l({type:Nn.SetDroppableDisabled,id:o,key:s,disabled:r}),d.current.disabled=r)}),[o,s,r,l]),{active:a,rect:f,isOver:(null==u?void 0:u.id)===o,node:C,over:u,setNodeRef:x}}({id:a,data:x,disabled:y.droppable,resizeObserverConfig:{updateMeasurementsFor:S,...u}}),{active:k,activatorEvent:M,activeNodeRect:F,attributes:D,setNodeRef:P,listeners:A,isDragging:V,over:T,setActivatorNodeRef:L,transform:N}=function(t){let{id:n,data:r,disabled:o=!1,attributes:i}=t;const s=Cn(fo),{activators:a,activatorEvent:l,active:u,activeNodeRect:c,ariaDescribedById:d,draggableNodes:h,over:f}=(0,e.useContext)(no),{role:g=ho,roleDescription:p="draggable",tabIndex:m=0}=null!=i?i:{},b=(null==u?void 0:u.id)===n,v=(0,e.useContext)(b?ao:co),[w,y]=vn(),[C,x]=vn(),S=function(t,n){return(0,e.useMemo)((()=>t.reduce(((e,t)=>{let{eventName:r,handler:o}=t;return e[r]=e=>{o(e,n)},e}),{})),[t,n])}(a,n),E=mn(r);return gn((()=>(h.set(n,{id:n,key:s,node:w,activatorNode:C,data:E}),()=>{const e=h.get(n);e&&e.key===s&&h.delete(n)})),[h,n]),{active:u,activatorEvent:l,activeNodeRect:c,attributes:(0,e.useMemo)((()=>({role:g,tabIndex:m,"aria-disabled":o,"aria-pressed":!(!b||g!==ho)||void 0,"aria-roledescription":p,"aria-describedby":d.draggable})),[o,g,m,b,p,d.draggable]),isDragging:b,listeners:o?void 0:S,node:w,over:f,setNodeRef:y,setActivatorNodeRef:x,transform:v}}({id:a,data:x,attributes:{...Fo,...r},disabled:y.draggable}),z=function(){for(var t=arguments.length,n=new Array(t),r=0;re=>{n.forEach((t=>t(e)))}),n)}(I,P),B=Boolean(k),G=B&&!p&&vo(f)&&vo(b),H=!v&&V,U=H&&G?N:null,W=G?null!=U?U:(null!=l?l:w)({rects:m,activeNodeRect:F,activeIndex:f,overIndex:b,index:C}):null,j=vo(f)&&vo(b)?s({id:a,items:d,activeIndex:f,overIndex:b}):C,q=null==k?void 0:k.id,K=(0,e.useRef)({activeId:q,items:d,newIndex:j,containerId:h}),Y=d!==K.current.items,_=n({active:k,containerId:h,isDragging:V,isSorting:B,id:a,index:C,items:d,newIndex:K.current.newIndex,previousItems:K.current.items,previousContainerId:K.current.containerId,transition:c,wasDragging:null!=K.current.activeId}),Z=function(t){let{disabled:n,index:r,node:o,rect:i}=t;const[s,a]=(0,e.useState)(null),l=(0,e.useRef)(r);return gn((()=>{if(!n&&r!==l.current&&o.current){const e=i.current;if(e){const t=nr(o.current,{ignoreTransform:!0}),n={x:e.left-t.left,y:e.top-t.top,scaleX:e.width/t.width,scaleY:e.height/t.height};(n.x||n.y)&&a(n)}}r!==l.current&&(l.current=r)}),[n,r,o,i]),(0,e.useEffect)((()=>{s&&a(null)}),[s]),s}({disabled:!_,index:C,node:R,rect:E});return(0,e.useEffect)((()=>{B&&K.current.newIndex!==j&&(K.current.newIndex=j),h!==K.current.containerId&&(K.current.containerId=h),d!==K.current.items&&(K.current.items=d)}),[B,j,h,d]),(0,e.useEffect)((()=>{if(q===K.current.activeId)return;if(q&&!K.current.activeId)return void(K.current.activeId=q);const e=setTimeout((()=>{K.current.activeId=q}),50);return()=>clearTimeout(e)}),[q]),{active:k,activeIndex:f,attributes:D,data:x,rect:E,index:C,newIndex:j,items:d,isOver:O,isSorting:B,isDragging:V,listeners:A,node:R,overIndex:b,over:T,setNodeRef:z,setActivatorNodeRef:L,setDroppableNodeRef:I,setDraggableNodeRef:P,transform:null!=Z?Z:W,transition:Z||Y&&K.current.newIndex===C?Mo:H&&!Rn(M)||!c?void 0:B||_?In.Transition.toString({...c,property:ko}):void 0}}function Po(e){if(!e)return!1;const t=e.data.current;return!!(t&&"sortable"in t&&"object"==typeof t.sortable&&"containerId"in t.sortable&&"items"in t.sortable&&"index"in t.sortable)}const Ao=[xr.Down,xr.Right,xr.Up,xr.Left],Vo=(e,t)=>{let{context:{active:n,collisionRect:r,droppableRects:o,droppableContainers:i,over:s,scrollableAncestors:a}}=t;if(Ao.includes(e.code)){if(e.preventDefault(),!n||!r)return;const t=[];i.getEnabled().forEach((n=>{if(!n||null!=n&&n.disabled)return;const i=o.get(n.id);if(i)switch(e.code){case xr.Down:r.topi.top&&t.push(n);break;case xr.Left:r.left>i.left&&t.push(n);break;case xr.Right:r.left{let{collisionRect:t,droppableRects:n,droppableContainers:r}=e;const o=qn(t),i=[];for(const e of r){const{id:t}=e,r=n.get(t);if(r){const n=qn(r),s=o.reduce(((e,t,r)=>e+Un(n[r],t)),0),a=Number((s/4).toFixed(4));i.push({id:t,data:{droppableContainer:e,value:a}})}}return i.sort(Wn)})({active:n,collisionRect:r,droppableRects:o,droppableContainers:t,pointerCoordinates:null});let u=Kn(l,"id");if(u===(null==s?void 0:s.id)&&l.length>1&&(u=l[1].id),null!=u){const e=i.get(n.id),t=i.get(u),s=t?o.get(t.id):null,l=null==t?void 0:t.node.current;if(l&&s&&e&&t){const n=or(l).some(((e,t)=>a[t]!==e)),o=To(e,t),i=function(e,t){return!(!Po(e)||!Po(t))&&!!To(e,t)&&e.data.current.sortable.index{let{containerNodeRect:t,draggingNodeRect:n,transform:r}=e;return n&&t?function(e,t,n){const r={...e};return t.top+e.y<=n.top?r.y=n.top-t.top:t.bottom+e.y>=n.top+n.height&&(r.y=n.top+n.height-t.bottom),t.left+e.x<=n.left?r.x=n.left-t.left:t.right+e.x>=n.left+n.width&&(r.x=n.left+n.width-t.right),r}(r,n,t):r},No=e=>{let{transform:t}=e;return{...t,x:0}},zo={list:"UFXv660XisMp2k7oIkOA",item:"cuno_GtO4bhcM59n00B2",handle:"fOOS92b6g0h9pAqn_2JI"},Bo=(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 256 256"},(0,e.createElement)("rect",{width:"256",height:"256",fill:"none"}),(0,e.createElement)("circle",{cx:"91",cy:"60",r:"16"}),(0,e.createElement)("circle",{cx:"91",cy:"128",r:"16"}),(0,e.createElement)("circle",{cx:"91",cy:"196",r:"16"}),(0,e.createElement)("circle",{cx:"161",cy:"60",r:"16"}),(0,e.createElement)("circle",{cx:"161",cy:"128",r:"16"}),(0,e.createElement)("circle",{cx:"161",cy:"196",r:"16"}));function Go({label:t,className:n="",...r}){return(0,e.createElement)(i.Button,{className:Le("gb-sortable-listitem__handle",zo.handle,n),variant:"tertiary",showTooltip:!1,icon:Bo,label:t,...r})}function Ho({children:t,id:n,dragHandle:r=!0,dragHandleLabel:o=(0,s.__)("Reorder Item","generateblocks"),as:i="li",className:a="",disabled:l=!1}){const{active:u,attributes:c,listeners:d,setNodeRef:h,transform:f,transition:g,isDragging:p}=Do({id:n,disabled:l,data:{disabled:l}}),m={transform:In.Transform.toString(f),transition:g};u&&u.id===n&&(m.zIndex=1);const b=i,v=r?{ref:h,style:m}:{ref:h,style:m,...c,...d};return(0,e.createElement)(b,{className:Le("gb-sortable-listitem",zo.item,a,p&&"is-dragging"),"data-component":"SortableListItem",...v},r&&(0,e.createElement)(Go,{label:o,...c,...d}),t)}const Uo=(0,o.forwardRef)((function({itemComponent:t,onDragStart:n,onDragEnd:r,items:i,setItems:a,dragHandle:l=!0,dragHandleLabel:u=(0,s.__)("Reorder Item","generateblocks-pro"),className:c=""},d){const[h,f]=(0,o.useState)(!1),[g,p]=(0,o.useState)(null),m=Gn(Bn(Pr),Bn(Ir,{coordinateGetter:Vo})),b=t,v=(0,o.useMemo)((()=>i.map((e=>(e.id||(e.id=qe()),e)))),[i]);return(0,e.createElement)(uo,{modifiers:[No,Lo],sensors:m,collisionDetection:Zn,onDragStart:e=>{const{active:t}=e;f(!0),p(t),n&&n(e)},onDragEnd:e=>{f(!1),function(e){var t;const{active:n,over:r}=e,o=null!==(t=r.data.current?.disabled)&&void 0!==t&&t;if(n.id!==r.id&&!o){const e=i.findIndex((e=>e.id===n.id)),t=i.findIndex((e=>e.id===r.id));a(mo(i,e,t))}}(e),p(null),r&&r(e,g)}},(0,e.createElement)("ul",{className:Le("gb-sortable-list",zo.list,c,h&&"is-dragging"),ref:d},(0,e.createElement)(Eo,{items:v,strategy:Co},i.map(((t,n)=>{var r;return(0,e.createElement)(Ho,{key:`${t.id}${n}`,id:t.id,dragHandle:l,dragHandleLabel:u,disabled:null!==(r=t.disabled)&&void 0!==r&&r},(0,e.createElement)(b,{item:t,index:n}))})))))})),Wo={flex:"rDe4XxEMyRee1hSKKXzn",horizontal:"Yg1nkwz9mFYMuk6zv1DW",flow:"b6i6J_7eUIspcsEZ3Qia",vertical:"dfG8sfdNVPzQp7pqgYJQ"};function jo({children:t,gap:n,layout:r="flow",direction:o="vertical",as:i="div",wrap:s=!0,className:a="",style:l={},...u}){const c=i,d={...l,"--gap":n};return"flex"===r&&(d.flexWrap=s?"wrap":"nowrap"),(0,e.createElement)(c,{...u,className:Le("gb-stack",Wo[o],Wo[r],a),style:d},t)}function qo(e,t){return"function"==typeof e?e(t):e}function Ko(e,t){return n=>{t.setState((t=>({...t,[e]:qo(n,t[e])})))}}function Yo(e){return e instanceof Function}function _o(e,t,n){let r,o=[];return i=>{let s;n.key&&n.debug&&(s=Date.now());const a=e(i);if(a.length===o.length&&!a.some(((e,t)=>o[t]!==e)))return r;let l;if(o=a,n.key&&n.debug&&(l=Date.now()),r=t(...a),null==n||null==n.onChange||n.onChange(r),n.key&&n.debug&&null!=n&&n.debug()){const e=Math.round(100*(Date.now()-s))/100,t=Math.round(100*(Date.now()-l))/100,r=t/16,o=(e,t)=>{for(e=String(e);e.length{var n;return null!=(n=null==e?void 0:e.debugAll)?n:e[t]},key:!1,onChange:r}}const Xo="debugHeaders";function Jo(e,t,n){var r;let o={id:null!=(r=n.id)?r:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const e=[],t=n=>{n.subHeaders&&n.subHeaders.length&&n.subHeaders.map(t),e.push(n)};return t(o),e},getContext:()=>({table:e,header:o,column:t})};return e._features.forEach((t=>{null==t.createHeader||t.createHeader(o,e)})),o}const Qo={createTable:e=>{e.getHeaderGroups=_o((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((t,n,r,o)=>{var i,s;const a=null!=(i=null==r?void 0:r.map((e=>n.find((t=>t.id===e)))).filter(Boolean))?i:[],l=null!=(s=null==o?void 0:o.map((e=>n.find((t=>t.id===e)))).filter(Boolean))?s:[];return $o(t,[...a,...n.filter((e=>!(null!=r&&r.includes(e.id)||null!=o&&o.includes(e.id)))),...l],e)}),Zo(e.options,Xo)),e.getCenterHeaderGroups=_o((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((t,n,r,o)=>$o(t,n=n.filter((e=>!(null!=r&&r.includes(e.id)||null!=o&&o.includes(e.id)))),e,"center")),Zo(e.options,Xo)),e.getLeftHeaderGroups=_o((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left]),((t,n,r)=>{var o;const i=null!=(o=null==r?void 0:r.map((e=>n.find((t=>t.id===e)))).filter(Boolean))?o:[];return $o(t,i,e,"left")}),Zo(e.options,Xo)),e.getRightHeaderGroups=_o((()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right]),((t,n,r)=>{var o;const i=null!=(o=null==r?void 0:r.map((e=>n.find((t=>t.id===e)))).filter(Boolean))?o:[];return $o(t,i,e,"right")}),Zo(e.options,Xo)),e.getFooterGroups=_o((()=>[e.getHeaderGroups()]),(e=>[...e].reverse()),Zo(e.options,Xo)),e.getLeftFooterGroups=_o((()=>[e.getLeftHeaderGroups()]),(e=>[...e].reverse()),Zo(e.options,Xo)),e.getCenterFooterGroups=_o((()=>[e.getCenterHeaderGroups()]),(e=>[...e].reverse()),Zo(e.options,Xo)),e.getRightFooterGroups=_o((()=>[e.getRightHeaderGroups()]),(e=>[...e].reverse()),Zo(e.options,Xo)),e.getFlatHeaders=_o((()=>[e.getHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),Zo(e.options,Xo)),e.getLeftFlatHeaders=_o((()=>[e.getLeftHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),Zo(e.options,Xo)),e.getCenterFlatHeaders=_o((()=>[e.getCenterHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),Zo(e.options,Xo)),e.getRightFlatHeaders=_o((()=>[e.getRightHeaderGroups()]),(e=>e.map((e=>e.headers)).flat()),Zo(e.options,Xo)),e.getCenterLeafHeaders=_o((()=>[e.getCenterFlatHeaders()]),(e=>e.filter((e=>{var t;return!(null!=(t=e.subHeaders)&&t.length)}))),Zo(e.options,Xo)),e.getLeftLeafHeaders=_o((()=>[e.getLeftFlatHeaders()]),(e=>e.filter((e=>{var t;return!(null!=(t=e.subHeaders)&&t.length)}))),Zo(e.options,Xo)),e.getRightLeafHeaders=_o((()=>[e.getRightFlatHeaders()]),(e=>e.filter((e=>{var t;return!(null!=(t=e.subHeaders)&&t.length)}))),Zo(e.options,Xo)),e.getLeafHeaders=_o((()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()]),((e,t,n)=>{var r,o,i,s,a,l;return[...null!=(r=null==(o=e[0])?void 0:o.headers)?r:[],...null!=(i=null==(s=t[0])?void 0:s.headers)?i:[],...null!=(a=null==(l=n[0])?void 0:l.headers)?a:[]].map((e=>e.getLeafHeaders())).flat()}),Zo(e.options,Xo))}};function $o(e,t,n,r){var o,i;let s=0;const a=function(e,t){void 0===t&&(t=1),s=Math.max(s,t),e.filter((e=>e.getIsVisible())).forEach((e=>{var n;null!=(n=e.columns)&&n.length&&a(e.columns,t+1)}),0)};a(e);let l=[];const u=(e,t)=>{const o={depth:t,id:[r,`${t}`].filter(Boolean).join("_"),headers:[]},i=[];e.forEach((e=>{const s=[...i].reverse()[0];let a,l=!1;if(e.column.depth===o.depth&&e.column.parent?a=e.column.parent:(a=e.column,l=!0),s&&(null==s?void 0:s.column)===a)s.subHeaders.push(e);else{const o=Jo(n,a,{id:[r,t,a.id,null==e?void 0:e.id].filter(Boolean).join("_"),isPlaceholder:l,placeholderId:l?`${i.filter((e=>e.column===a)).length}`:void 0,depth:t,index:i.length});o.subHeaders.push(e),i.push(o)}o.headers.push(e),e.headerGroup=o})),l.push(o),t>0&&u(i,t-1)},c=t.map(((e,t)=>Jo(n,e,{depth:s,index:t})));u(c,s-1),l.reverse();const d=e=>e.filter((e=>e.column.getIsVisible())).map((e=>{let t=0,n=0,r=[0];return e.subHeaders&&e.subHeaders.length?(r=[],d(e.subHeaders).forEach((e=>{let{colSpan:n,rowSpan:o}=e;t+=n,r.push(o)}))):t=1,n+=Math.min(...r),e.colSpan=t,e.rowSpan=n,{colSpan:t,rowSpan:n}}));return d(null!=(o=null==(i=l[0])?void 0:i.headers)?o:[]),l}const ei=(e,t,n,r,o,i,s)=>{let a={id:t,index:r,original:n,depth:o,parentId:s,_valuesCache:{},_uniqueValuesCache:{},getValue:t=>{if(a._valuesCache.hasOwnProperty(t))return a._valuesCache[t];const n=e.getColumn(t);return null!=n&&n.accessorFn?(a._valuesCache[t]=n.accessorFn(a.original,r),a._valuesCache[t]):void 0},getUniqueValues:t=>{if(a._uniqueValuesCache.hasOwnProperty(t))return a._uniqueValuesCache[t];const n=e.getColumn(t);return null!=n&&n.accessorFn?n.columnDef.getUniqueValues?(a._uniqueValuesCache[t]=n.columnDef.getUniqueValues(a.original,r),a._uniqueValuesCache[t]):(a._uniqueValuesCache[t]=[a.getValue(t)],a._uniqueValuesCache[t]):void 0},renderValue:t=>{var n;return null!=(n=a.getValue(t))?n:e.options.renderFallbackValue},subRows:null!=i?i:[],getLeafRows:()=>function(e,t){const n=[],r=e=>{e.forEach((e=>{n.push(e);const o=t(e);null!=o&&o.length&&r(o)}))};return r(e),n}(a.subRows,(e=>e.subRows)),getParentRow:()=>a.parentId?e.getRow(a.parentId,!0):void 0,getParentRows:()=>{let e=[],t=a;for(;;){const n=t.getParentRow();if(!n)break;e.push(n),t=n}return e.reverse()},getAllCells:_o((()=>[e.getAllLeafColumns()]),(t=>t.map((t=>function(e,t,n,r){const o={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(r),renderValue:()=>{var t;return null!=(t=o.getValue())?t:e.options.renderFallbackValue},getContext:_o((()=>[e,n,t,o]),((e,t,n,r)=>({table:e,column:t,row:n,cell:r,getValue:r.getValue,renderValue:r.renderValue})),Zo(e.options,"debugCells"))};return e._features.forEach((r=>{null==r.createCell||r.createCell(o,n,t,e)}),{}),o}(e,a,t,t.id)))),Zo(e.options,"debugRows")),_getAllCellsByColumnId:_o((()=>[a.getAllCells()]),(e=>e.reduce(((e,t)=>(e[t.column.id]=t,e)),{})),Zo(e.options,"debugRows"))};for(let t=0;t{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},ni=(e,t,n)=>{var r;const o=n.toLowerCase();return Boolean(null==(r=e.getValue(t))||null==(r=r.toString())||null==(r=r.toLowerCase())?void 0:r.includes(o))};ni.autoRemove=e=>hi(e);const ri=(e,t,n)=>{var r;return Boolean(null==(r=e.getValue(t))||null==(r=r.toString())?void 0:r.includes(n))};ri.autoRemove=e=>hi(e);const oi=(e,t,n)=>{var r;return(null==(r=e.getValue(t))||null==(r=r.toString())?void 0:r.toLowerCase())===(null==n?void 0:n.toLowerCase())};oi.autoRemove=e=>hi(e);const ii=(e,t,n)=>{var r;return null==(r=e.getValue(t))?void 0:r.includes(n)};ii.autoRemove=e=>hi(e)||!(null!=e&&e.length);const si=(e,t,n)=>!n.some((n=>{var r;return!(null!=(r=e.getValue(t))&&r.includes(n))}));si.autoRemove=e=>hi(e)||!(null!=e&&e.length);const ai=(e,t,n)=>n.some((n=>{var r;return null==(r=e.getValue(t))?void 0:r.includes(n)}));ai.autoRemove=e=>hi(e)||!(null!=e&&e.length);const li=(e,t,n)=>e.getValue(t)===n;li.autoRemove=e=>hi(e);const ui=(e,t,n)=>e.getValue(t)==n;ui.autoRemove=e=>hi(e);const ci=(e,t,n)=>{let[r,o]=n;const i=e.getValue(t);return i>=r&&i<=o};ci.resolveFilterValue=e=>{let[t,n]=e,r="number"!=typeof t?parseFloat(t):t,o="number"!=typeof n?parseFloat(n):n,i=null===t||Number.isNaN(r)?-1/0:r,s=null===n||Number.isNaN(o)?1/0:o;if(i>s){const e=i;i=s,s=e}return[i,s]},ci.autoRemove=e=>hi(e)||hi(e[0])&&hi(e[1]);const di={includesString:ni,includesStringSensitive:ri,equalsString:oi,arrIncludes:ii,arrIncludesAll:si,arrIncludesSome:ai,equals:li,weakEquals:ui,inNumberRange:ci};function hi(e){return null==e||""===e}const fi={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:Ko("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=null==n?void 0:n.getValue(e.id);return"string"==typeof r?di.includesString:"number"==typeof r?di.inNumberRange:"boolean"==typeof r||null!==r&&"object"==typeof r?di.equals:Array.isArray(r)?di.arrIncludes:di.weakEquals},e.getFilterFn=()=>{var n,r;return Yo(e.columnDef.filterFn)?e.columnDef.filterFn:"auto"===e.columnDef.filterFn?e.getAutoFilterFn():null!=(n=null==(r=t.options.filterFns)?void 0:r[e.columnDef.filterFn])?n:di[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,r,o;return(null==(n=e.columnDef.enableColumnFilter)||n)&&(null==(r=t.options.enableColumnFilters)||r)&&(null==(o=t.options.enableFilters)||o)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return null==(n=t.getState().columnFilters)||null==(n=n.find((t=>t.id===e.id)))?void 0:n.value},e.getFilterIndex=()=>{var n,r;return null!=(n=null==(r=t.getState().columnFilters)?void 0:r.findIndex((t=>t.id===e.id)))?n:-1},e.setFilterValue=n=>{t.setColumnFilters((t=>{const r=e.getFilterFn(),o=null==t?void 0:t.find((t=>t.id===e.id)),i=qo(n,o?o.value:void 0);var s;if(gi(r,i,e))return null!=(s=null==t?void 0:t.filter((t=>t.id!==e.id)))?s:[];const a={id:e.id,value:i};var l;return o?null!=(l=null==t?void 0:t.map((t=>t.id===e.id?a:t)))?l:[]:null!=t&&t.length?[...t,a]:[a]}))}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns();null==e.options.onColumnFiltersChange||e.options.onColumnFiltersChange((e=>{var r;return null==(r=qo(t,e))?void 0:r.filter((e=>{const t=n.find((t=>t.id===e.id));return!t||!gi(t.getFilterFn(),e.value,t)}))}))},e.resetColumnFilters=t=>{var n,r;e.setColumnFilters(t?[]:null!=(n=null==(r=e.initialState)?void 0:r.columnFilters)?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function gi(e,t,n){return!(!e||!e.autoRemove)&&e.autoRemove(t,n)||void 0===t||"string"==typeof t&&!t}const pi={sum:(e,t,n)=>n.reduce(((t,n)=>{const r=n.getValue(e);return t+("number"==typeof r?r:0)}),0),min:(e,t,n)=>{let r;return n.forEach((t=>{const n=t.getValue(e);null!=n&&(r>n||void 0===r&&n>=n)&&(r=n)})),r},max:(e,t,n)=>{let r;return n.forEach((t=>{const n=t.getValue(e);null!=n&&(r=n)&&(r=n)})),r},extent:(e,t,n)=>{let r,o;return n.forEach((t=>{const n=t.getValue(e);null!=n&&(void 0===r?n>=n&&(r=o=n):(r>n&&(r=n),o{let n=0,r=0;if(t.forEach((t=>{let o=t.getValue(e);null!=o&&(o=+o)>=o&&(++n,r+=o)})),n)return r/n},median:(e,t)=>{if(!t.length)return;const n=t.map((t=>t.getValue(e)));if(!function(e){return Array.isArray(e)&&e.every((e=>"number"==typeof e))}(n))return;if(1===n.length)return n[0];const r=Math.floor(n.length/2),o=n.sort(((e,t)=>e-t));return n.length%2!=0?o[r]:(o[r-1]+o[r])/2},unique:(e,t)=>Array.from(new Set(t.map((t=>t.getValue(e)))).values()),uniqueCount:(e,t)=>new Set(t.map((t=>t.getValue(e)))).size,count:(e,t)=>t.length},mi={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return null!=(t=null==(n=e.getValue())||null==n.toString?void 0:n.toString())?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:Ko("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping((t=>null!=t&&t.includes(e.id)?t.filter((t=>t!==e.id)):[...null!=t?t:[],e.id]))},e.getCanGroup=()=>{var n,r;return(null==(n=e.columnDef.enableGrouping)||n)&&(null==(r=t.options.enableGrouping)||r)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return null==(n=t.getState().grouping)?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return null==(n=t.getState().grouping)?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const t=e.getCanGroup();return()=>{t&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],r=null==n?void 0:n.getValue(e.id);return"number"==typeof r?pi.sum:"[object Date]"===Object.prototype.toString.call(r)?pi.extent:void 0},e.getAggregationFn=()=>{var n,r;if(!e)throw new Error;return Yo(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:"auto"===e.columnDef.aggregationFn?e.getAutoAggregationFn():null!=(n=null==(r=t.options.aggregationFns)?void 0:r[e.columnDef.aggregationFn])?n:pi[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>null==e.options.onGroupingChange?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,r;e.setGrouping(t?[]:null!=(n=null==(r=e.initialState)?void 0:r.grouping)?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const r=t.getColumn(n);return null!=r&&r.columnDef.getGroupingValue?(e._groupingValuesCache[n]=r.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,r)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var t;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!(null==(t=n.subRows)||!t.length)}}},bi={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:Ko("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=_o((e=>[Ei(t,e)]),(t=>t.findIndex((t=>t.id===e.id))),Zo(t.options,"debugColumns")),e.getIsFirstColumn=n=>{var r;return(null==(r=Ei(t,n)[0])?void 0:r.id)===e.id},e.getIsLastColumn=n=>{var r;const o=Ei(t,n);return(null==(r=o[o.length-1])?void 0:r.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>null==e.options.onColumnOrderChange?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:null!=(n=e.initialState.columnOrder)?n:[])},e._getOrderColumnsFn=_o((()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode]),((e,t,n)=>r=>{let o=[];if(null!=e&&e.length){const t=[...e],n=[...r];for(;n.length&&t.length;){const e=t.shift(),r=n.findIndex((t=>t.id===e));r>-1&&o.push(n.splice(r,1)[0])}o=[...o,...n]}else o=r;return function(e,t,n){if(null==t||!t.length||!n)return e;const r=e.filter((e=>!t.includes(e.id)));if("remove"===n)return r;const o=t.map((t=>e.find((e=>e.id===t)))).filter(Boolean);return[...o,...r]}(o,t,n)}),Zo(e.options,"debugTable"))}},vi={getInitialState:e=>({columnPinning:{left:[],right:[]},...e}),getDefaultOptions:e=>({onColumnPinningChange:Ko("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const r=e.getLeafColumns().map((e=>e.id)).filter(Boolean);t.setColumnPinning((e=>{var t,o,i,s,a,l;return"right"===n?{left:(null!=(i=null==e?void 0:e.left)?i:[]).filter((e=>!(null!=r&&r.includes(e)))),right:[...(null!=(s=null==e?void 0:e.right)?s:[]).filter((e=>!(null!=r&&r.includes(e)))),...r]}:"left"===n?{left:[...(null!=(a=null==e?void 0:e.left)?a:[]).filter((e=>!(null!=r&&r.includes(e)))),...r],right:(null!=(l=null==e?void 0:e.right)?l:[]).filter((e=>!(null!=r&&r.includes(e))))}:{left:(null!=(t=null==e?void 0:e.left)?t:[]).filter((e=>!(null!=r&&r.includes(e)))),right:(null!=(o=null==e?void 0:e.right)?o:[]).filter((e=>!(null!=r&&r.includes(e))))}}))},e.getCanPin=()=>e.getLeafColumns().some((e=>{var n,r,o;return(null==(n=e.columnDef.enablePinning)||n)&&(null==(r=null!=(o=t.options.enableColumnPinning)?o:t.options.enablePinning)||r)})),e.getIsPinned=()=>{const n=e.getLeafColumns().map((e=>e.id)),{left:r,right:o}=t.getState().columnPinning,i=n.some((e=>null==r?void 0:r.includes(e))),s=n.some((e=>null==o?void 0:o.includes(e)));return i?"left":!!s&&"right"},e.getPinnedIndex=()=>{var n,r;const o=e.getIsPinned();return o?null!=(n=null==(r=t.getState().columnPinning)||null==(r=r[o])?void 0:r.indexOf(e.id))?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=_o((()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right]),((e,t,n)=>{const r=[...null!=t?t:[],...null!=n?n:[]];return e.filter((e=>!r.includes(e.column.id)))}),Zo(t.options,"debugRows")),e.getLeftVisibleCells=_o((()=>[e._getAllVisibleCells(),t.getState().columnPinning.left]),((e,t)=>{const n=(null!=t?t:[]).map((t=>e.find((e=>e.column.id===t)))).filter(Boolean).map((e=>({...e,position:"left"})));return n}),Zo(t.options,"debugRows")),e.getRightVisibleCells=_o((()=>[e._getAllVisibleCells(),t.getState().columnPinning.right]),((e,t)=>{const n=(null!=t?t:[]).map((t=>e.find((e=>e.column.id===t)))).filter(Boolean).map((e=>({...e,position:"right"})));return n}),Zo(t.options,"debugRows"))},createTable:e=>{e.setColumnPinning=t=>null==e.options.onColumnPinningChange?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,r;return e.setColumnPinning(t?{left:[],right:[]}:null!=(n=null==(r=e.initialState)?void 0:r.columnPinning)?n:{left:[],right:[]})},e.getIsSomeColumnsPinned=t=>{var n;const r=e.getState().columnPinning;var o,i;return t?Boolean(null==(n=r[t])?void 0:n.length):Boolean((null==(o=r.left)?void 0:o.length)||(null==(i=r.right)?void 0:i.length))},e.getLeftLeafColumns=_o((()=>[e.getAllLeafColumns(),e.getState().columnPinning.left]),((e,t)=>(null!=t?t:[]).map((t=>e.find((e=>e.id===t)))).filter(Boolean)),Zo(e.options,"debugColumns")),e.getRightLeafColumns=_o((()=>[e.getAllLeafColumns(),e.getState().columnPinning.right]),((e,t)=>(null!=t?t:[]).map((t=>e.find((e=>e.id===t)))).filter(Boolean)),Zo(e.options,"debugColumns")),e.getCenterLeafColumns=_o((()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right]),((e,t,n)=>{const r=[...null!=t?t:[],...null!=n?n:[]];return e.filter((e=>!r.includes(e.id)))}),Zo(e.options,"debugColumns"))}},wi={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},yi={getDefaultColumnDef:()=>wi,getInitialState:e=>({columnSizing:{},columnSizingInfo:{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]},...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:Ko("columnSizing",e),onColumnSizingInfoChange:Ko("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,r,o;const i=t.getState().columnSizing[e.id];return Math.min(Math.max(null!=(n=e.columnDef.minSize)?n:wi.minSize,null!=(r=null!=i?i:e.columnDef.size)?r:wi.size),null!=(o=e.columnDef.maxSize)?o:wi.maxSize)},e.getStart=_o((e=>[e,Ei(t,e),t.getState().columnSizing]),((t,n)=>n.slice(0,e.getIndex(t)).reduce(((e,t)=>e+t.getSize()),0)),Zo(t.options,"debugColumns")),e.getAfter=_o((e=>[e,Ei(t,e),t.getState().columnSizing]),((t,n)=>n.slice(e.getIndex(t)+1).reduce(((e,t)=>e+t.getSize()),0)),Zo(t.options,"debugColumns")),e.resetSize=()=>{t.setColumnSizing((t=>{let{[e.id]:n,...r}=t;return r}))},e.getCanResize=()=>{var n,r;return(null==(n=e.columnDef.enableResizing)||n)&&(null==(r=t.options.enableColumnResizing)||r)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let t=0;const n=e=>{var r;e.subHeaders.length?e.subHeaders.forEach(n):t+=null!=(r=e.column.getSize())?r:0};return n(e),t},e.getStart=()=>{if(e.index>0){const t=e.headerGroup.headers[e.index-1];return t.getStart()+t.getSize()}return 0},e.getResizeHandler=n=>{const r=t.getColumn(e.column.id),o=null==r?void 0:r.getCanResize();return i=>{if(!r||!o)return;if(null==i.persist||i.persist(),xi(i)&&i.touches&&i.touches.length>1)return;const s=e.getSize(),a=e?e.getLeafHeaders().map((e=>[e.column.id,e.column.getSize()])):[[r.id,r.getSize()]],l=xi(i)?Math.round(i.touches[0].clientX):i.clientX,u={},c=(e,n)=>{"number"==typeof n&&(t.setColumnSizingInfo((e=>{var r,o;const i="rtl"===t.options.columnResizeDirection?-1:1,s=(n-(null!=(r=null==e?void 0:e.startOffset)?r:0))*i,a=Math.max(s/(null!=(o=null==e?void 0:e.startSize)?o:0),-.999999);return e.columnSizingStart.forEach((e=>{let[t,n]=e;u[t]=Math.round(100*Math.max(n+n*a,0))/100})),{...e,deltaOffset:s,deltaPercentage:a}})),"onChange"!==t.options.columnResizeMode&&"end"!==e||t.setColumnSizing((e=>({...e,...u}))))},d=e=>c("move",e),h=e=>{c("end",e),t.setColumnSizingInfo((e=>({...e,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]})))},f=n||"undefined"!=typeof document?document:null,g={moveHandler:e=>d(e.clientX),upHandler:e=>{null==f||f.removeEventListener("mousemove",g.moveHandler),null==f||f.removeEventListener("mouseup",g.upHandler),h(e.clientX)}},p={moveHandler:e=>(e.cancelable&&(e.preventDefault(),e.stopPropagation()),d(e.touches[0].clientX),!1),upHandler:e=>{var t;null==f||f.removeEventListener("touchmove",p.moveHandler),null==f||f.removeEventListener("touchend",p.upHandler),e.cancelable&&(e.preventDefault(),e.stopPropagation()),h(null==(t=e.touches[0])?void 0:t.clientX)}},m=!!function(){if("boolean"==typeof Ci)return Ci;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch(t){e=!1}return Ci=e,Ci}()&&{passive:!1};xi(i)?(null==f||f.addEventListener("touchmove",p.moveHandler,m),null==f||f.addEventListener("touchend",p.upHandler,m)):(null==f||f.addEventListener("mousemove",g.moveHandler,m),null==f||f.addEventListener("mouseup",g.upHandler,m)),t.setColumnSizingInfo((e=>({...e,startOffset:l,startSize:s,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:r.id})))}}},createTable:e=>{e.setColumnSizing=t=>null==e.options.onColumnSizingChange?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>null==e.options.onColumnSizingInfoChange?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:null!=(n=e.initialState.columnSizing)?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}:null!=(n=e.initialState.columnSizingInfo)?n:{startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]})},e.getTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getHeaderGroups()[0])?void 0:n.headers.reduce(((e,t)=>e+t.getSize()),0))?t:0},e.getLeftTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getLeftHeaderGroups()[0])?void 0:n.headers.reduce(((e,t)=>e+t.getSize()),0))?t:0},e.getCenterTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getCenterHeaderGroups()[0])?void 0:n.headers.reduce(((e,t)=>e+t.getSize()),0))?t:0},e.getRightTotalSize=()=>{var t,n;return null!=(t=null==(n=e.getRightHeaderGroups()[0])?void 0:n.headers.reduce(((e,t)=>e+t.getSize()),0))?t:0}}};let Ci=null;function xi(e){return"touchstart"===e.type}const Si={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:Ko("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility((t=>({...t,[e.id]:null!=n?n:!e.getIsVisible()})))},e.getIsVisible=()=>{var n,r;const o=e.columns;return null==(n=o.length?o.some((e=>e.getIsVisible())):null==(r=t.getState().columnVisibility)?void 0:r[e.id])||n},e.getCanHide=()=>{var n,r;return(null==(n=e.columnDef.enableHiding)||n)&&(null==(r=t.options.enableHiding)||r)},e.getToggleVisibilityHandler=()=>t=>{null==e.toggleVisibility||e.toggleVisibility(t.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=_o((()=>[e.getAllCells(),t.getState().columnVisibility]),(e=>e.filter((e=>e.column.getIsVisible()))),Zo(t.options,"debugRows")),e.getVisibleCells=_o((()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()]),((e,t,n)=>[...e,...t,...n]),Zo(t.options,"debugRows"))},createTable:e=>{const t=(t,n)=>_o((()=>[n(),n().filter((e=>e.getIsVisible())).map((e=>e.id)).join("_")]),(e=>e.filter((e=>null==e.getIsVisible?void 0:e.getIsVisible()))),Zo(e.options,"debugColumns"));e.getVisibleFlatColumns=t(0,(()=>e.getAllFlatColumns())),e.getVisibleLeafColumns=t(0,(()=>e.getAllLeafColumns())),e.getLeftVisibleLeafColumns=t(0,(()=>e.getLeftLeafColumns())),e.getRightVisibleLeafColumns=t(0,(()=>e.getRightLeafColumns())),e.getCenterVisibleLeafColumns=t(0,(()=>e.getCenterLeafColumns())),e.setColumnVisibility=t=>null==e.options.onColumnVisibilityChange?void 0:e.options.onColumnVisibilityChange(t),e.resetColumnVisibility=t=>{var n;e.setColumnVisibility(t?{}:null!=(n=e.initialState.columnVisibility)?n:{})},e.toggleAllColumnsVisible=t=>{var n;t=null!=(n=t)?n:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce(((e,n)=>({...e,[n.id]:t||!(null!=n.getCanHide&&n.getCanHide())})),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some((e=>!(null!=e.getIsVisible&&e.getIsVisible()))),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some((e=>null==e.getIsVisible?void 0:e.getIsVisible())),e.getToggleAllColumnsVisibilityHandler=()=>t=>{var n;e.toggleAllColumnsVisible(null==(n=t.target)?void 0:n.checked)}}};function Ei(e,t){return t?"center"===t?e.getCenterVisibleLeafColumns():"left"===t?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const Ri={getInitialState:e=>({...e,pagination:{pageIndex:0,pageSize:10,...null==e?void 0:e.pagination}}),getDefaultOptions:e=>({onPaginationChange:Ko("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var r,o;if(t){if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetPageIndex)?r:!e.options.manualPagination){if(n)return;n=!0,e._queue((()=>{e.resetPageIndex(),n=!1}))}}else e._queue((()=>{t=!0}))},e.setPagination=t=>null==e.options.onPaginationChange?void 0:e.options.onPaginationChange((e=>qo(t,e))),e.resetPagination=t=>{var n;e.setPagination(t?{pageIndex:0,pageSize:10}:null!=(n=e.initialState.pagination)?n:{pageIndex:0,pageSize:10})},e.setPageIndex=t=>{e.setPagination((n=>{let r=qo(t,n.pageIndex);const o=void 0===e.options.pageCount||-1===e.options.pageCount?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return r=Math.max(0,Math.min(r,o)),{...n,pageIndex:r}}))},e.resetPageIndex=t=>{var n,r;e.setPageIndex(t?0:null!=(n=null==(r=e.initialState)||null==(r=r.pagination)?void 0:r.pageIndex)?n:0)},e.resetPageSize=t=>{var n,r;e.setPageSize(t?10:null!=(n=null==(r=e.initialState)||null==(r=r.pagination)?void 0:r.pageSize)?n:10)},e.setPageSize=t=>{e.setPagination((e=>{const n=Math.max(1,qo(t,e.pageSize)),r=e.pageSize*e.pageIndex,o=Math.floor(r/n);return{...e,pageIndex:o,pageSize:n}}))},e.setPageCount=t=>e.setPagination((n=>{var r;let o=qo(t,null!=(r=e.options.pageCount)?r:-1);return"number"==typeof o&&(o=Math.max(-1,o)),{...n,pageCount:o}})),e.getPageOptions=_o((()=>[e.getPageCount()]),(e=>{let t=[];return e&&e>0&&(t=[...new Array(e)].fill(null).map(((e,t)=>t))),t}),Zo(e.options,"debugTable")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:t}=e.getState().pagination,n=e.getPageCount();return-1===n||0!==n&&te.setPageIndex((e=>e-1)),e.nextPage=()=>e.setPageIndex((e=>e+1)),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var t;return null!=(t=e.options.pageCount)?t:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var t;return null!=(t=e.options.rowCount)?t:e.getPrePaginationRowModel().rows.length}}},Oi={getInitialState:e=>({rowPinning:{top:[],bottom:[]},...e}),getDefaultOptions:e=>({onRowPinningChange:Ko("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,r,o)=>{const i=r?e.getLeafRows().map((e=>{let{id:t}=e;return t})):[],s=o?e.getParentRows().map((e=>{let{id:t}=e;return t})):[],a=new Set([...s,e.id,...i]);t.setRowPinning((e=>{var t,r,o,i,s,l;return"bottom"===n?{top:(null!=(o=null==e?void 0:e.top)?o:[]).filter((e=>!(null!=a&&a.has(e)))),bottom:[...(null!=(i=null==e?void 0:e.bottom)?i:[]).filter((e=>!(null!=a&&a.has(e)))),...Array.from(a)]}:"top"===n?{top:[...(null!=(s=null==e?void 0:e.top)?s:[]).filter((e=>!(null!=a&&a.has(e)))),...Array.from(a)],bottom:(null!=(l=null==e?void 0:e.bottom)?l:[]).filter((e=>!(null!=a&&a.has(e))))}:{top:(null!=(t=null==e?void 0:e.top)?t:[]).filter((e=>!(null!=a&&a.has(e)))),bottom:(null!=(r=null==e?void 0:e.bottom)?r:[]).filter((e=>!(null!=a&&a.has(e))))}}))},e.getCanPin=()=>{var n;const{enableRowPinning:r,enablePinning:o}=t.options;return"function"==typeof r?r(e):null==(n=null!=r?r:o)||n},e.getIsPinned=()=>{const n=[e.id],{top:r,bottom:o}=t.getState().rowPinning,i=n.some((e=>null==r?void 0:r.includes(e))),s=n.some((e=>null==o?void 0:o.includes(e)));return i?"top":!!s&&"bottom"},e.getPinnedIndex=()=>{var n,r;const o=e.getIsPinned();if(!o)return-1;const i=null==(n="top"===o?t.getTopRows():t.getBottomRows())?void 0:n.map((e=>{let{id:t}=e;return t}));return null!=(r=null==i?void 0:i.indexOf(e.id))?r:-1}},createTable:e=>{e.setRowPinning=t=>null==e.options.onRowPinningChange?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,r;return e.setRowPinning(t?{top:[],bottom:[]}:null!=(n=null==(r=e.initialState)?void 0:r.rowPinning)?n:{top:[],bottom:[]})},e.getIsSomeRowsPinned=t=>{var n;const r=e.getState().rowPinning;var o,i;return t?Boolean(null==(n=r[t])?void 0:n.length):Boolean((null==(o=r.top)?void 0:o.length)||(null==(i=r.bottom)?void 0:i.length))},e._getPinnedRows=(t,n,r)=>{var o;return(null==(o=e.options.keepPinnedRows)||o?(null!=n?n:[]).map((t=>{const n=e.getRow(t,!0);return n.getIsAllParentsExpanded()?n:null})):(null!=n?n:[]).map((e=>t.find((t=>t.id===e))))).filter(Boolean).map((e=>({...e,position:r})))},e.getTopRows=_o((()=>[e.getRowModel().rows,e.getState().rowPinning.top]),((t,n)=>e._getPinnedRows(t,n,"top")),Zo(e.options,"debugRows")),e.getBottomRows=_o((()=>[e.getRowModel().rows,e.getState().rowPinning.bottom]),((t,n)=>e._getPinnedRows(t,n,"bottom")),Zo(e.options,"debugRows")),e.getCenterRows=_o((()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom]),((e,t,n)=>{const r=new Set([...null!=t?t:[],...null!=n?n:[]]);return e.filter((e=>!r.has(e.id)))}),Zo(e.options,"debugRows"))}},Ii={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:Ko("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>null==e.options.onRowSelectionChange?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:null!=(n=e.initialState.rowSelection)?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection((n=>{t=void 0!==t?t:!e.getIsAllRowsSelected();const r={...n},o=e.getPreGroupedRowModel().flatRows;return t?o.forEach((e=>{e.getCanSelect()&&(r[e.id]=!0)})):o.forEach((e=>{delete r[e.id]})),r}))},e.toggleAllPageRowsSelected=t=>e.setRowSelection((n=>{const r=void 0!==t?t:!e.getIsAllPageRowsSelected(),o={...n};return e.getRowModel().rows.forEach((t=>{ki(o,t.id,r,!0,e)})),o})),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=_o((()=>[e.getState().rowSelection,e.getCoreRowModel()]),((t,n)=>Object.keys(t).length?Mi(e,n):{rows:[],flatRows:[],rowsById:{}}),Zo(e.options,"debugTable")),e.getFilteredSelectedRowModel=_o((()=>[e.getState().rowSelection,e.getFilteredRowModel()]),((t,n)=>Object.keys(t).length?Mi(e,n):{rows:[],flatRows:[],rowsById:{}}),Zo(e.options,"debugTable")),e.getGroupedSelectedRowModel=_o((()=>[e.getState().rowSelection,e.getSortedRowModel()]),((t,n)=>Object.keys(t).length?Mi(e,n):{rows:[],flatRows:[],rowsById:{}}),Zo(e.options,"debugTable")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let r=Boolean(t.length&&Object.keys(n).length);return r&&t.some((e=>e.getCanSelect()&&!n[e.id]))&&(r=!1),r},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter((e=>e.getCanSelect())),{rowSelection:n}=e.getState();let r=!!t.length;return r&&t.some((e=>!n[e.id]))&&(r=!1),r},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys(null!=(t=e.getState().rowSelection)?t:{}).length;return n>0&&n{const t=e.getPaginationRowModel().flatRows;return!e.getIsAllPageRowsSelected()&&t.filter((e=>e.getCanSelect())).some((e=>e.getIsSelected()||e.getIsSomeSelected()))},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,r)=>{const o=e.getIsSelected();t.setRowSelection((i=>{var s;if(n=void 0!==n?n:!o,e.getCanSelect()&&o===n)return i;const a={...i};return ki(a,e.id,n,null==(s=null==r?void 0:r.selectChildren)||s,t),a}))},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return Fi(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return"some"===Di(e,n)},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return"all"===Di(e,n)},e.getCanSelect=()=>{var n;return"function"==typeof t.options.enableRowSelection?t.options.enableRowSelection(e):null==(n=t.options.enableRowSelection)||n},e.getCanSelectSubRows=()=>{var n;return"function"==typeof t.options.enableSubRowSelection?t.options.enableSubRowSelection(e):null==(n=t.options.enableSubRowSelection)||n},e.getCanMultiSelect=()=>{var n;return"function"==typeof t.options.enableMultiRowSelection?t.options.enableMultiRowSelection(e):null==(n=t.options.enableMultiRowSelection)||n},e.getToggleSelectedHandler=()=>{const t=e.getCanSelect();return n=>{var r;t&&e.toggleSelected(null==(r=n.target)?void 0:r.checked)}}}},ki=(e,t,n,r,o)=>{var i;const s=o.getRow(t,!0);n?(s.getCanMultiSelect()||Object.keys(e).forEach((t=>delete e[t])),s.getCanSelect()&&(e[t]=!0)):delete e[t],r&&null!=(i=s.subRows)&&i.length&&s.getCanSelectSubRows()&&s.subRows.forEach((t=>ki(e,t.id,n,r,o)))};function Mi(e,t){const n=e.getState().rowSelection,r=[],o={},i=function(e,t){return e.map((e=>{var t;const s=Fi(e,n);if(s&&(r.push(e),o[e.id]=e),null!=(t=e.subRows)&&t.length&&(e={...e,subRows:i(e.subRows)}),s)return e})).filter(Boolean)};return{rows:i(t.rows),flatRows:r,rowsById:o}}function Fi(e,t){var n;return null!=(n=t[e.id])&&n}function Di(e,t,n){var r;if(null==(r=e.subRows)||!r.length)return!1;let o=!0,i=!1;return e.subRows.forEach((e=>{if((!i||o)&&(e.getCanSelect()&&(Fi(e,t)?i=!0:o=!1),e.subRows&&e.subRows.length)){const n=Di(e,t);"all"===n?i=!0:"some"===n?(i=!0,o=!1):o=!1}})),o?"all":!!i&&"some"}const Pi=/([0-9]+)/gm;function Ai(e,t){return e===t?0:e>t?1:-1}function Vi(e){return"number"==typeof e?isNaN(e)||e===1/0||e===-1/0?"":String(e):"string"==typeof e?e:""}function Ti(e,t){const n=e.split(Pi).filter(Boolean),r=t.split(Pi).filter(Boolean);for(;n.length&&r.length;){const e=n.shift(),t=r.shift(),o=parseInt(e,10),i=parseInt(t,10),s=[o,i].sort();if(isNaN(s[0])){if(e>t)return 1;if(t>e)return-1}else{if(isNaN(s[1]))return isNaN(o)?-1:1;if(o>i)return 1;if(i>o)return-1}}return n.length-r.length}const Li={alphanumeric:(e,t,n)=>Ti(Vi(e.getValue(n)).toLowerCase(),Vi(t.getValue(n)).toLowerCase()),alphanumericCaseSensitive:(e,t,n)=>Ti(Vi(e.getValue(n)),Vi(t.getValue(n))),text:(e,t,n)=>Ai(Vi(e.getValue(n)).toLowerCase(),Vi(t.getValue(n)).toLowerCase()),textCaseSensitive:(e,t,n)=>Ai(Vi(e.getValue(n)),Vi(t.getValue(n))),datetime:(e,t,n)=>{const r=e.getValue(n),o=t.getValue(n);return r>o?1:rAi(e.getValue(n),t.getValue(n))},Ni={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:Ko("sorting",e),isMultiSortEvent:e=>e.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let r=!1;for(const t of n){const n=null==t?void 0:t.getValue(e.id);if("[object Date]"===Object.prototype.toString.call(n))return Li.datetime;if("string"==typeof n&&(r=!0,n.split(Pi).length>1))return Li.alphanumeric}return r?Li.text:Li.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return"string"==typeof(null==n?void 0:n.getValue(e.id))?"asc":"desc"},e.getSortingFn=()=>{var n,r;if(!e)throw new Error;return Yo(e.columnDef.sortingFn)?e.columnDef.sortingFn:"auto"===e.columnDef.sortingFn?e.getAutoSortingFn():null!=(n=null==(r=t.options.sortingFns)?void 0:r[e.columnDef.sortingFn])?n:Li[e.columnDef.sortingFn]},e.toggleSorting=(n,r)=>{const o=e.getNextSortingOrder(),i=null!=n;t.setSorting((s=>{const a=null==s?void 0:s.find((t=>t.id===e.id)),l=null==s?void 0:s.findIndex((t=>t.id===e.id));let u,c=[],d=i?n:"desc"===o;var h;return u=null!=s&&s.length&&e.getCanMultiSort()&&r?a?"toggle":"add":null!=s&&s.length&&l!==s.length-1?"replace":a?"toggle":"replace","toggle"===u&&(i||o||(u="remove")),"add"===u?(c=[...s,{id:e.id,desc:d}],c.splice(0,c.length-(null!=(h=t.options.maxMultiSortColCount)?h:Number.MAX_SAFE_INTEGER))):c="toggle"===u?s.map((t=>t.id===e.id?{...t,desc:d}:t)):"remove"===u?s.filter((t=>t.id!==e.id)):[{id:e.id,desc:d}],c}))},e.getFirstSortDir=()=>{var n,r;return(null!=(n=null!=(r=e.columnDef.sortDescFirst)?r:t.options.sortDescFirst)?n:"desc"===e.getAutoSortDir())?"desc":"asc"},e.getNextSortingOrder=n=>{var r,o;const i=e.getFirstSortDir(),s=e.getIsSorted();return s?!!(s===i||null!=(r=t.options.enableSortingRemoval)&&!r||n&&null!=(o=t.options.enableMultiRemove)&&!o)&&("desc"===s?"asc":"desc"):i},e.getCanSort=()=>{var n,r;return(null==(n=e.columnDef.enableSorting)||n)&&(null==(r=t.options.enableSorting)||r)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,r;return null!=(n=null!=(r=e.columnDef.enableMultiSort)?r:t.options.enableMultiSort)?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const r=null==(n=t.getState().sorting)?void 0:n.find((t=>t.id===e.id));return!!r&&(r.desc?"desc":"asc")},e.getSortIndex=()=>{var n,r;return null!=(n=null==(r=t.getState().sorting)?void 0:r.findIndex((t=>t.id===e.id)))?n:-1},e.clearSorting=()=>{t.setSorting((t=>null!=t&&t.length?t.filter((t=>t.id!==e.id)):[]))},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return r=>{n&&(null==r.persist||r.persist(),null==e.toggleSorting||e.toggleSorting(void 0,!!e.getCanMultiSort()&&(null==t.options.isMultiSortEvent?void 0:t.options.isMultiSortEvent(r))))}}},createTable:e=>{e.setSorting=t=>null==e.options.onSortingChange?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,r;e.setSorting(t?[]:null!=(n=null==(r=e.initialState)?void 0:r.sorting)?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},zi=[Qo,Si,bi,vi,ti,fi,{createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},{getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:Ko("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const r=null==(n=e.getCoreRowModel().flatRows[0])||null==(n=n._getAllCellsByColumnId()[t.id])?void 0:n.getValue();return"string"==typeof r||"number"==typeof r}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,r,o,i;return(null==(n=e.columnDef.enableGlobalFilter)||n)&&(null==(r=t.options.enableGlobalFilter)||r)&&(null==(o=t.options.enableFilters)||o)&&(null==(i=null==t.options.getColumnCanGlobalFilter?void 0:t.options.getColumnCanGlobalFilter(e))||i)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>di.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:r}=e.options;return Yo(r)?r:"auto"===r?e.getGlobalAutoFilterFn():null!=(t=null==(n=e.options.filterFns)?void 0:n[r])?t:di[r]},e.setGlobalFilter=t=>{null==e.options.onGlobalFilterChange||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},Ni,mi,{getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:Ko("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var r,o;if(t){if(null!=(r=null!=(o=e.options.autoResetAll)?o:e.options.autoResetExpanded)?r:!e.options.manualExpanding){if(n)return;n=!0,e._queue((()=>{e.resetExpanded(),n=!1}))}}else e._queue((()=>{t=!0}))},e.setExpanded=t=>null==e.options.onExpandedChange?void 0:e.options.onExpandedChange(t),e.toggleAllRowsExpanded=t=>{(null!=t?t:!e.getIsAllRowsExpanded())?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=t=>{var n,r;e.setExpanded(t?{}:null!=(n=null==(r=e.initialState)?void 0:r.expanded)?n:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some((e=>e.getCanExpand())),e.getToggleAllRowsExpandedHandler=()=>t=>{null==t.persist||t.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const t=e.getState().expanded;return!0===t||Object.values(t).some(Boolean)},e.getIsAllRowsExpanded=()=>{const t=e.getState().expanded;return"boolean"==typeof t?!0===t:!!Object.keys(t).length&&!e.getRowModel().flatRows.some((e=>!e.getIsExpanded()))},e.getExpandedDepth=()=>{let t=0;return(!0===e.getState().expanded?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach((e=>{const n=e.split(".");t=Math.max(t,n.length)})),t},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded((r=>{var o;const i=!0===r||!(null==r||!r[e.id]);let s={};if(!0===r?Object.keys(t.getRowModel().rowsById).forEach((e=>{s[e]=!0})):s=r,n=null!=(o=n)?o:!i,!i&&n)return{...s,[e.id]:!0};if(i&&!n){const{[e.id]:t,...n}=s;return n}return r}))},e.getIsExpanded=()=>{var n;const r=t.getState().expanded;return!!(null!=(n=null==t.options.getIsRowExpanded?void 0:t.options.getIsRowExpanded(e))?n:!0===r||(null==r?void 0:r[e.id]))},e.getCanExpand=()=>{var n,r,o;return null!=(n=null==t.options.getRowCanExpand?void 0:t.options.getRowCanExpand(e))?n:(null==(r=t.options.enableExpanding)||r)&&!(null==(o=e.subRows)||!o.length)},e.getIsAllParentsExpanded=()=>{let n=!0,r=e;for(;n&&r.parentId;)r=t.getRow(r.parentId,!0),n=r.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const t=e.getCanExpand();return()=>{t&&e.toggleExpanded()}}}},Ri,Oi,Ii,yi];function Bi(e){var t,n;const r=[...zi,...null!=(t=e._features)?t:[]];let o={_features:r};const i=o._features.reduce(((e,t)=>Object.assign(e,null==t.getDefaultOptions?void 0:t.getDefaultOptions(o))),{});let s={...null!=(n=e.initialState)?n:{}};o._features.forEach((e=>{var t;s=null!=(t=null==e.getInitialState?void 0:e.getInitialState(s))?t:s}));const a=[];let l=!1;const u={_features:r,options:{...i,...e},initialState:s,_queue:e=>{a.push(e),l||(l=!0,Promise.resolve().then((()=>{for(;a.length;)a.shift()();l=!1})).catch((e=>setTimeout((()=>{throw e})))))},reset:()=>{o.setState(o.initialState)},setOptions:e=>{const t=qo(e,o.options);o.options=(e=>o.options.mergeOptions?o.options.mergeOptions(i,e):{...i,...e})(t)},getState:()=>o.options.state,setState:e=>{null==o.options.onStateChange||o.options.onStateChange(e)},_getRowId:(e,t,n)=>{var r;return null!=(r=null==o.options.getRowId?void 0:o.options.getRowId(e,t,n))?r:`${n?[n.id,t].join("."):t}`},getCoreRowModel:()=>(o._getCoreRowModel||(o._getCoreRowModel=o.options.getCoreRowModel(o)),o._getCoreRowModel()),getRowModel:()=>o.getPaginationRowModel(),getRow:(e,t)=>{let n=(t?o.getPrePaginationRowModel():o.getRowModel()).rowsById[e];if(!n&&(n=o.getCoreRowModel().rowsById[e],!n))throw new Error;return n},_getDefaultColumnDef:_o((()=>[o.options.defaultColumn]),(e=>{var t;return e=null!=(t=e)?t:{},{header:e=>{const t=e.header.column.columnDef;return t.accessorKey?t.accessorKey:t.accessorFn?t.id:null},cell:e=>{var t,n;return null!=(t=null==(n=e.renderValue())||null==n.toString?void 0:n.toString())?t:null},...o._features.reduce(((e,t)=>Object.assign(e,null==t.getDefaultColumnDef?void 0:t.getDefaultColumnDef())),{}),...e}}),Zo(e,"debugColumns")),_getColumnDefs:()=>o.options.columns,getAllColumns:_o((()=>[o._getColumnDefs()]),(e=>{const t=function(e,n,r){return void 0===r&&(r=0),e.map((e=>{const i=function(e,t,n,r){var o,i;const s={...e._getDefaultColumnDef(),...t},a=s.accessorKey;let l,u=null!=(o=null!=(i=s.id)?i:a?a.replace(".","_"):void 0)?o:"string"==typeof s.header?s.header:void 0;if(s.accessorFn?l=s.accessorFn:a&&(l=a.includes(".")?e=>{let t=e;for(const e of a.split(".")){var n;t=null==(n=t)?void 0:n[e]}return t}:e=>e[s.accessorKey]),!u)throw new Error;let c={id:`${String(u)}`,accessorFn:l,parent:r,depth:n,columnDef:s,columns:[],getFlatColumns:_o((()=>[!0]),(()=>{var e;return[c,...null==(e=c.columns)?void 0:e.flatMap((e=>e.getFlatColumns()))]}),Zo(e.options,"debugColumns")),getLeafColumns:_o((()=>[e._getOrderColumnsFn()]),(e=>{var t;if(null!=(t=c.columns)&&t.length){let t=c.columns.flatMap((e=>e.getLeafColumns()));return e(t)}return[c]}),Zo(e.options,"debugColumns"))};for(const t of e._features)null==t.createColumn||t.createColumn(c,e);return c}(o,e,r,n),s=e;return i.columns=s.columns?t(s.columns,i,r+1):[],i}))};return t(e)}),Zo(e,"debugColumns")),getAllFlatColumns:_o((()=>[o.getAllColumns()]),(e=>e.flatMap((e=>e.getFlatColumns()))),Zo(e,"debugColumns")),_getAllFlatColumnsById:_o((()=>[o.getAllFlatColumns()]),(e=>e.reduce(((e,t)=>(e[t.id]=t,e)),{})),Zo(e,"debugColumns")),getAllLeafColumns:_o((()=>[o.getAllColumns(),o._getOrderColumnsFn()]),((e,t)=>t(e.flatMap((e=>e.getLeafColumns())))),Zo(e,"debugColumns")),getColumn:e=>o._getAllFlatColumnsById()[e]};Object.assign(o,u);for(let e=0;e{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}(r=t)||"function"==typeof r||function(e){return"object"==typeof e&&"symbol"==typeof e.$$typeof&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}(r)?e.createElement(t,n):t:null;var r}const Hi={table:"l03h0IHl5WOI4XvelHt3",striped:"pz9cxM_c8wpWcOh3bw5v"},Ui=function({row:t,canDrag:n}){var r,o;const{active:i,setNodeRef:s,transform:a,transition:l,isDragging:u}=Do({id:t.id,disabled:null!==(r=t?.disabled)&&void 0!==r&&r,data:{disabled:null!==(o=t?.disabled)&&void 0!==o&&o}}),c={backgroundColor:u?"#fff":void 0,transform:In.Transform.toString(a),transition:l,width:t?.getSize?`${t.getSize().width}px`:void 0,zIndex:i&&i.id===t.id?1:void 0},d=n?{ref:s,style:c,className:Le("gb-table__row","gb-table__row--draggable",u&&"is-dragging"),"data-row-id":t.id}:{};return(0,e.createElement)("tr",{...d,key:t.id,"data-row-id":t.id},t.getVisibleCells().map((t=>(0,e.createElement)("td",{key:t.id,className:"gb-table__cell"},Gi(t.column.columnDef.cell,t.getContext())))))};function Wi({columns:t,onDragStart:n,onDragEnd:r,onRowSelectionChange:i,rowSelection:s={},striped:a=!0,showHeader:l=!0,data:u=[],className:c="",draggableRows:d=!1,getRowId:h=(e=>e.id),enableRowSelection:f=!1,"aria-labelledby":g,"aria-label":p}){const m={},b=(0,o.useRef)(null);f&&(m.rowSelection=s);const v=function(t){const n={state:{},onStateChange:()=>{},renderFallbackValue:null,...t},[r]=e.useState((()=>({current:Bi(n)}))),[o,i]=e.useState((()=>r.current.initialState));return r.current.setOptions((e=>({...e,...t,state:{...o,...t.state},onStateChange:e=>{i(e),null==t.onStateChange||t.onStateChange(e)}}))),r.current}({data:u,columns:t,getCoreRowModel:e=>_o((()=>[e.options.data]),(t=>{const n={rows:[],flatRows:[],rowsById:{}},r=function(t,o,i){void 0===o&&(o=0);const s=[];for(let l=0;le._autoResetPageIndex()))),getRowId:h,enableRowSelection:f,onRowSelectionChange:i,state:m}),w=v.getRowModel().rows,y=d&&!v.getIsSomeRowsSelected()&&!v.getIsAllRowsSelected(),C=Gn(Bn(Pr),Bn(Ir,{coordinateGetter:Vo}));if(!p&&!g)throw new Error("Table component requires an accessible label. Please add an aria-label or valid aria-labelledby prop.");return(0,e.createElement)(uo,{modifiers:[No,Lo],sensors:C,collisionDetection:Zn,onDragStart:n,onDragEnd:r},(0,e.createElement)("table",{className:Le("gb-table",Hi.table,a&&Hi.striped,c),cellPadding:0,"aria-label":p,"aria-labelledby":g,ref:b},l&&(0,e.createElement)("thead",null,v.getHeaderGroups().map((t=>(0,e.createElement)("tr",{key:t.id},t.headers.map((t=>(0,e.createElement)("th",{key:t.id,className:"gb-table__header",colSpan:t.colSpan,"data-column-id":t.column.id},t.isPlaceholder?null:Gi(t.column.columnDef.header,t.getContext())))))))),(0,e.createElement)("tbody",null,y?(0,e.createElement)(Eo,{items:w,strategy:Co},w.map((t=>(0,e.createElement)(Ui,{row:t,key:t.id,canDrag:y})))):(0,e.createElement)(e.Fragment,null,w.map((t=>(0,e.createElement)("tr",{key:t.id,className:"gb-table__row","data-row-id":t.id},t.getVisibleCells().map((t=>(0,e.createElement)("td",{key:t.id,className:"gb-table__cell","data-column-id":t.column.id},Gi(t.column.columnDef.cell,t.getContext())))))))))))}Wi.RowHandle=function({row:t,disabled:n=!1}){var r,o;const{attributes:i,listeners:a}=Do({id:t.id,disabled:n||null!==(r=t?.disabled)&&void 0!==r&&r,data:{disabled:n||null!==(o=t?.disabled)&&void 0!==o&&o}});return(0,e.createElement)(Go,{className:"gb-table__handle",variant:"tertiary",showTooltip:!1,label:(0,s.__)("Reorder style","generateblocks-pro"),...i,...a})},Wi.HeaderRowCheckbox=function({table:t,onChange:n,...r}){return(0,e.createElement)(Ke,{type:"checkbox",className:"components-checkbox-control__input gb-table__checkbox gb-table__checkbox--all",checked:t.getIsAllRowsSelected(),indeterminate:t.getIsSomeRowsSelected(),onChange:e=>{t.toggleAllRowsSelected(e.target.checked),n&&n(e)},...r})},Wi.RowCheckbox=function({row:t,"aria-label":n=(0,s.__)("Select row","generateblocks-pro"),...r}){return(0,e.createElement)(Ke,{checked:t.getIsSelected(),disabled:!t.getCanSelect(),onChange:t.getToggleSelectedHandler(),"aria-label":n,...r})}})(),r})(),e.exports=t()},528:e=>{e.exports=function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){if(i)return i(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i=void 0,s=0;s=252?6:a>=248?5:a>=240?4:a>=224?3:a>=192?2:1;function l(e,t){if(t<65534&&(e.subarray&&i||!e.subarray&&o))return String.fromCharCode.apply(null,r.shrinkBuf(e,t));for(var n="",s=0;s>>6,t[s++]=128|63&n):n<65536?(t[s++]=224|n>>>12,t[s++]=128|n>>>6&63,t[s++]=128|63&n):(t[s++]=240|n>>>18,t[s++]=128|n>>>12&63,t[s++]=128|n>>>6&63,t[s++]=128|63&n);return t},n.buf2binstring=function(e){return l(e,e.length)},n.binstring2buf=function(e){for(var t=new r.Buf8(e.length),n=0,o=t.length;n4)u[r++]=65533,n+=i-1;else{for(o&=2===i?31:3===i?15:7;i>1&&n1?u[r++]=65533:o<65536?u[r++]=o:(o-=65536,u[r++]=55296|o>>10&1023,u[r++]=56320|1023&o)}return l(u,r)},n.utf8border=function(e,t){var n;for((t=t||e.length)>e.length&&(t=e.length),n=t-1;n>=0&&128==(192&e[n]);)n--;return n<0||0===n?t:n+s[e[n]]>t?n:t}},{"./common":1}],3:[function(e,t,n){"use strict";t.exports=function(e,t,n,r){for(var o=65535&e|0,i=e>>>16&65535|0,s=0;0!==n;){n-=s=n>2e3?2e3:n;do{i=i+(o=o+t[r++]|0)|0}while(--s);o%=65521,i%=65521}return o|i<<16|0}},{}],4:[function(e,t,n){"use strict";t.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],5:[function(e,t,n){"use strict";var r=function(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}();t.exports=function(e,t,n,o){var i=r,s=o+n;e^=-1;for(var a=o;a>>8^i[255&(e^t[a])];return-1^e}},{}],6:[function(e,t,n){"use strict";t.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],7:[function(e,t,n){"use strict";t.exports=function(e,t){var n,r,o,i,s,a,l,u,c,d,h,f,g,p,m,b,v,w,y,C,x,S,E,R,O;n=e.state,r=e.next_in,R=e.input,o=r+(e.avail_in-5),i=e.next_out,O=e.output,s=i-(t-e.avail_out),a=i+(e.avail_out-257),l=n.dmax,u=n.wsize,c=n.whave,d=n.wnext,h=n.window,f=n.hold,g=n.bits,p=n.lencode,m=n.distcode,b=(1<>>=y=w>>>24,g-=y,0==(y=w>>>16&255))O[i++]=65535&w;else{if(!(16&y)){if(0==(64&y)){w=p[(65535&w)+(f&(1<>>=y,g-=y),g<15&&(f+=R[r++]<>>=y=w>>>24,g-=y,!(16&(y=w>>>16&255))){if(0==(64&y)){w=m[(65535&w)+(f&(1<l){e.msg="invalid distance too far back",n.mode=30;break e}if(f>>>=y,g-=y,x>(y=i-s)){if((y=x-y)>c&&n.sane){e.msg="invalid distance too far back",n.mode=30;break e}if(S=0,E=h,0===d){if(S+=u-y,y2;)O[i++]=E[S++],O[i++]=E[S++],O[i++]=E[S++],C-=3;C&&(O[i++]=E[S++],C>1&&(O[i++]=E[S++]))}else{S=i-x;do{O[i++]=O[S++],O[i++]=O[S++],O[i++]=O[S++],C-=3}while(C>2);C&&(O[i++]=O[S++],C>1&&(O[i++]=O[S++]))}break}}break}}while(r>3,f&=(1<<(g-=C<<3))-1,e.next_in=r,e.next_out=i,e.avail_in=r>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function v(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new r.Buf16(320),this.work=new r.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function w(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=h,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new r.Buf32(p),t.distcode=t.distdyn=new r.Buf32(m),t.sane=1,t.back=-1,c):d}function y(e){var t;return e&&e.state?((t=e.state).wsize=0,t.whave=0,t.wnext=0,w(e)):d}function C(e,t){var n,r;return e&&e.state?(r=e.state,t<0?(n=0,t=-t):(n=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?d:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,y(e))):d}function x(e,t){var n,r;return e?(r=new v,e.state=r,r.window=null,(n=C(e,t))!==c&&(e.state=null),n):d}var S,E,R=!0;function O(e){if(R){var t;for(S=new r.Buf32(512),E=new r.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(a(l,e.lens,0,288,S,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;a(u,e.lens,0,32,E,0,e.work,{bits:5}),R=!1}e.lencode=S,e.lenbits=9,e.distcode=E,e.distbits=5}function I(e,t,n,o){var i,s=e.state;return null===s.window&&(s.wsize=1<=s.wsize?(r.arraySet(s.window,t,n-s.wsize,s.wsize,0),s.wnext=0,s.whave=s.wsize):((i=s.wsize-s.wnext)>o&&(i=o),r.arraySet(s.window,t,n-o,i,s.wnext),(o-=i)?(r.arraySet(s.window,t,n-o,o,0),s.wnext=o,s.whave=s.wsize):(s.wnext+=i,s.wnext===s.wsize&&(s.wnext=0),s.whave>>8&255,n.check=i(n.check,U,2,0),x=0,S=0,n.mode=2;break}if(n.flags=0,n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&x)<<8)+(x>>8))%31){e.msg="incorrect header check",n.mode=g;break}if(8!=(15&x)){e.msg="unknown compression method",n.mode=g;break}if(S-=4,N=8+(15&(x>>>=4)),0===n.wbits)n.wbits=N;else if(N>n.wbits){e.msg="invalid window size",n.mode=g;break}n.dmax=1<>8&1),512&n.flags&&(U[0]=255&x,U[1]=x>>>8&255,n.check=i(n.check,U,2,0)),x=0,S=0,n.mode=3;case 3:for(;S<32;){if(0===y)break e;y--,x+=p[v++]<>>8&255,U[2]=x>>>16&255,U[3]=x>>>24&255,n.check=i(n.check,U,4,0)),x=0,S=0,n.mode=4;case 4:for(;S<16;){if(0===y)break e;y--,x+=p[v++]<>8),512&n.flags&&(U[0]=255&x,U[1]=x>>>8&255,n.check=i(n.check,U,2,0)),x=0,S=0,n.mode=5;case 5:if(1024&n.flags){for(;S<16;){if(0===y)break e;y--,x+=p[v++]<>>8&255,n.check=i(n.check,U,2,0)),x=0,S=0}else n.head&&(n.head.extra=null);n.mode=6;case 6:if(1024&n.flags&&((k=n.length)>y&&(k=y),k&&(n.head&&(N=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),r.arraySet(n.head.extra,p,v,k,N)),512&n.flags&&(n.check=i(n.check,p,k,v)),y-=k,v+=k,n.length-=k),n.length))break e;n.length=0,n.mode=7;case 7:if(2048&n.flags){if(0===y)break e;k=0;do{N=p[v+k++],n.head&&N&&n.length<65536&&(n.head.name+=String.fromCharCode(N))}while(N&&k>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=f;break;case 10:for(;S<32;){if(0===y)break e;y--,x+=p[v++]<>>=7&S,S-=7&S,n.mode=27;break}for(;S<3;){if(0===y)break e;y--,x+=p[v++]<>>=1)){case 0:n.mode=14;break;case 1:if(O(n),n.mode=20,6===t){x>>>=2,S-=2;break e}break;case 2:n.mode=17;break;case 3:e.msg="invalid block type",n.mode=g}x>>>=2,S-=2;break;case 14:for(x>>>=7&S,S-=7&S;S<32;){if(0===y)break e;y--,x+=p[v++]<>>16^65535)){e.msg="invalid stored block lengths",n.mode=g;break}if(n.length=65535&x,x=0,S=0,n.mode=15,6===t)break e;case 15:n.mode=16;case 16:if(k=n.length){if(k>y&&(k=y),k>C&&(k=C),0===k)break e;r.arraySet(m,p,v,k,w),y-=k,v+=k,C-=k,w+=k,n.length-=k;break}n.mode=f;break;case 17:for(;S<14;){if(0===y)break e;y--,x+=p[v++]<>>=5,S-=5,n.ndist=1+(31&x),x>>>=5,S-=5,n.ncode=4+(15&x),x>>>=4,S-=4,n.nlen>286||n.ndist>30){e.msg="too many length or distance symbols",n.mode=g;break}n.have=0,n.mode=18;case 18:for(;n.have>>=3,S-=3}for(;n.have<19;)n.lens[W[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,B={bits:n.lenbits},z=a(0,n.lens,0,19,n.lencode,0,n.work,B),n.lenbits=B.bits,z){e.msg="invalid code lengths set",n.mode=g;break}n.have=0,n.mode=19;case 19:for(;n.have>>16&255,A=65535&H,!((D=H>>>24)<=S);){if(0===y)break e;y--,x+=p[v++]<>>=D,S-=D,n.lens[n.have++]=A;else{if(16===A){for(G=D+2;S>>=D,S-=D,0===n.have){e.msg="invalid bit length repeat",n.mode=g;break}N=n.lens[n.have-1],k=3+(3&x),x>>>=2,S-=2}else if(17===A){for(G=D+3;S>>=D)),x>>>=3,S-=3}else{for(G=D+7;S>>=D)),x>>>=7,S-=7}if(n.have+k>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=g;break}for(;k--;)n.lens[n.have++]=N}}if(n.mode===g)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=g;break}if(n.lenbits=9,B={bits:n.lenbits},z=a(l,n.lens,0,n.nlen,n.lencode,0,n.work,B),n.lenbits=B.bits,z){e.msg="invalid literal/lengths set",n.mode=g;break}if(n.distbits=6,n.distcode=n.distdyn,B={bits:n.distbits},z=a(u,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,B),n.distbits=B.bits,z){e.msg="invalid distances set",n.mode=g;break}if(n.mode=20,6===t)break e;case 20:n.mode=21;case 21:if(y>=6&&C>=258){e.next_out=w,e.avail_out=C,e.next_in=v,e.avail_in=y,n.hold=x,n.bits=S,s(e,R),w=e.next_out,m=e.output,C=e.avail_out,v=e.next_in,p=e.input,y=e.avail_in,x=n.hold,S=n.bits,n.mode===f&&(n.back=-1);break}for(n.back=0;P=(H=n.lencode[x&(1<>>16&255,A=65535&H,!((D=H>>>24)<=S);){if(0===y)break e;y--,x+=p[v++]<>V)])>>>16&255,A=65535&H,!(V+(D=H>>>24)<=S);){if(0===y)break e;y--,x+=p[v++]<>>=V,S-=V,n.back+=V}if(x>>>=D,S-=D,n.back+=D,n.length=A,0===P){n.mode=26;break}if(32&P){n.back=-1,n.mode=f;break}if(64&P){e.msg="invalid literal/length code",n.mode=g;break}n.extra=15&P,n.mode=22;case 22:if(n.extra){for(G=n.extra;S>>=n.extra,S-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=23;case 23:for(;P=(H=n.distcode[x&(1<>>16&255,A=65535&H,!((D=H>>>24)<=S);){if(0===y)break e;y--,x+=p[v++]<>V)])>>>16&255,A=65535&H,!(V+(D=H>>>24)<=S);){if(0===y)break e;y--,x+=p[v++]<>>=V,S-=V,n.back+=V}if(x>>>=D,S-=D,n.back+=D,64&P){e.msg="invalid distance code",n.mode=g;break}n.offset=A,n.extra=15&P,n.mode=24;case 24:if(n.extra){for(G=n.extra;S>>=n.extra,S-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=g;break}n.mode=25;case 25:if(0===C)break e;if(k=R-C,n.offset>k){if((k=n.offset-k)>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=g;break}k>n.wnext?(k-=n.wnext,M=n.wsize-k):M=n.wnext-k,k>n.length&&(k=n.length),F=n.window}else F=m,M=w-n.offset,k=n.length;k>C&&(k=C),C-=k,n.length-=k;do{m[w++]=F[M++]}while(--k);0===n.length&&(n.mode=21);break;case 26:if(0===C)break e;m[w++]=n.length,C--,n.mode=21;break;case 27:if(n.wrap){for(;S<32;){if(0===y)break e;y--,x|=p[v++]<=1&&0===L[I];I--);if(k>I&&(k=I),0===I)return c[d++]=20971520,c[d++]=20971520,f.bits=1,0;for(O=1;O0&&(0===e||1!==I))return-1;for(N[1]=0,E=1;E852||2===e&&P>592)return 1;for(;;){y=E-F,h[R]w?(C=z[B+h[R]],x=V[T+h[R]]):(C=96,x=0),g=1<>F)+(p-=g)]=y<<24|C<<16|x|0}while(0!==p);for(g=1<>=1;if(0!==g?(A&=g-1,A+=g):A=0,R++,0==--L[E]){if(E===I)break;E=t[n+h[R]]}if(E>k&&(A&b)!==m){for(0===F&&(F=k),v+=O,D=1<<(M=E-F);M+F852||2===e&&P>592)return 1;c[m=A&b]=k<<24|M<<16|v-d|0}}return 0!==A&&(c[v+A]=E-F<<24|64<<16|0),f.bits=k,0}},{"../utils/common":1}],10:[function(e,t,n){"use strict";t.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],11:[function(e,t,n){"use strict";t.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],"/lib/inflate.js":[function(e,t,n){"use strict";var r=e("./zlib/inflate"),o=e("./utils/common"),i=e("./utils/strings"),s=e("./zlib/constants"),a=e("./zlib/messages"),l=e("./zlib/zstream"),u=e("./zlib/gzheader"),c=Object.prototype.toString;function d(e){if(!(this instanceof d))return new d(e);this.options=o.assign({chunkSize:16384,windowBits:0,to:""},e||{});var t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,0===t.windowBits&&(t.windowBits=-15)),!(t.windowBits>=0&&t.windowBits<16)||e&&e.windowBits||(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&0==(15&t.windowBits)&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new l,this.strm.avail_out=0;var n=r.inflateInit2(this.strm,t.windowBits);if(n!==s.Z_OK)throw new Error(a[n]);if(this.header=new u,r.inflateGetHeader(this.strm,this.header),t.dictionary&&("string"==typeof t.dictionary?t.dictionary=i.string2buf(t.dictionary):"[object ArrayBuffer]"===c.call(t.dictionary)&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(n=r.inflateSetDictionary(this.strm,t.dictionary))!==s.Z_OK))throw new Error(a[n])}function h(e,t){var n=new d(t);if(n.push(e,!0),n.err)throw n.msg||a[n.err];return n.result}d.prototype.push=function(e,t){var n,a,l,u,d,h=this.strm,f=this.options.chunkSize,g=this.options.dictionary,p=!1;if(this.ended)return!1;a=t===~~t?t:!0===t?s.Z_FINISH:s.Z_NO_FLUSH,"string"==typeof e?h.input=i.binstring2buf(e):"[object ArrayBuffer]"===c.call(e)?h.input=new Uint8Array(e):h.input=e,h.next_in=0,h.avail_in=h.input.length;do{if(0===h.avail_out&&(h.output=new o.Buf8(f),h.next_out=0,h.avail_out=f),(n=r.inflate(h,s.Z_NO_FLUSH))===s.Z_NEED_DICT&&g&&(n=r.inflateSetDictionary(this.strm,g)),n===s.Z_BUF_ERROR&&!0===p&&(n=s.Z_OK,p=!1),n!==s.Z_STREAM_END&&n!==s.Z_OK)return this.onEnd(n),this.ended=!0,!1;h.next_out&&(0!==h.avail_out&&n!==s.Z_STREAM_END&&(0!==h.avail_in||a!==s.Z_FINISH&&a!==s.Z_SYNC_FLUSH)||("string"===this.options.to?(l=i.utf8border(h.output,h.next_out),u=h.next_out-l,d=i.buf2string(h.output,l),h.next_out=u,h.avail_out=f-u,u&&o.arraySet(h.output,h.output,l,u,0),this.onData(d)):this.onData(o.shrinkBuf(h.output,h.next_out)))),0===h.avail_in&&0===h.avail_out&&(p=!0)}while((h.avail_in>0||0===h.avail_out)&&n!==s.Z_STREAM_END);return n===s.Z_STREAM_END&&(a=s.Z_FINISH),a===s.Z_FINISH?(n=r.inflateEnd(this.strm),this.onEnd(n),this.ended=!0,n===s.Z_OK):a!==s.Z_SYNC_FLUSH||(this.onEnd(s.Z_OK),h.avail_out=0,!0)},d.prototype.onData=function(e){this.chunks.push(e)},d.prototype.onEnd=function(e){e===s.Z_OK&&("string"===this.options.to?this.result=this.chunks.join(""):this.result=o.flattenChunks(this.chunks)),this.chunks=[],this.err=e,this.msg=this.strm.msg},n.Inflate=d,n.inflate=h,n.inflateRaw=function(e,t){return(t=t||{}).raw=!0,h(e,t)},n.ungzip=h},{"./utils/common":1,"./utils/strings":2,"./zlib/constants":4,"./zlib/gzheader":6,"./zlib/inflate":8,"./zlib/messages":10,"./zlib/zstream":11}]},{},[])("/lib/inflate.js")},606:e=>{e.exports=function e(t,n,r){function o(s,a){if(!n[s]){if(!t[s]){if(i)return i(s,!0);var l=new Error("Cannot find module '"+s+"'");throw l.code="MODULE_NOT_FOUND",l}var u=n[s]={exports:{}};t[s][0].call(u.exports,(function(e){return o(t[s][1][e]||e)}),u,u.exports,e,t,n,r)}return n[s].exports}for(var i=void 0,s=0;s0},i.prototype.readMoreInput=function(){if(!(this.bit_end_pos_>256))if(this.eos_){if(this.bit_pos_>this.bit_end_pos_)throw new Error("Unexpected end of input "+this.bit_pos_+" "+this.bit_end_pos_)}else{var e=this.buf_ptr_,t=this.input_.read(this.buf_,e,r);if(t<0)throw new Error("Unexpected end of input");if(t=8;)this.val_>>>=8,this.val_|=this.buf_[8191&this.pos_]<<24,++this.pos_,this.bit_pos_=this.bit_pos_-8>>>0,this.bit_end_pos_=this.bit_end_pos_-8>>>0},i.prototype.readBits=function(e){32-this.bit_pos_>>this.bit_pos_&o[e];return this.bit_pos_+=e,t},t.exports=i},{}],2:[function(e,t,n){n.lookup=new Uint8Array([0,0,0,0,0,0,0,0,0,4,4,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,12,16,12,12,20,12,16,24,28,12,12,32,12,36,12,44,44,44,44,44,44,44,44,44,44,32,32,24,40,28,12,12,48,52,52,52,48,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,24,12,28,12,12,12,56,60,60,60,56,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,24,12,28,12,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,56,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,10,10,10,10,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,22,22,22,22,23,23,23,23,24,24,24,24,25,25,25,25,26,26,26,26,27,27,27,27,28,28,28,28,29,29,29,29,30,30,30,30,31,31,31,31,32,32,32,32,33,33,33,33,34,34,34,34,35,35,35,35,36,36,36,36,37,37,37,37,38,38,38,38,39,39,39,39,40,40,40,40,41,41,41,41,42,42,42,42,43,43,43,43,44,44,44,44,45,45,45,45,46,46,46,46,47,47,47,47,48,48,48,48,49,49,49,49,50,50,50,50,51,51,51,51,52,52,52,52,53,53,53,53,54,54,54,54,55,55,55,55,56,56,56,56,57,57,57,57,58,58,58,58,59,59,59,59,60,60,60,60,61,61,61,61,62,62,62,62,63,63,63,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),n.lookupOffsets=new Uint16Array([1024,1536,1280,1536,0,256,768,512])},{}],3:[function(e,t,n){var r=e("./streams").BrotliInput,o=e("./streams").BrotliOutput,i=e("./bit_reader"),s=e("./dictionary"),a=e("./huffman").HuffmanCode,l=e("./huffman").BrotliBuildHuffmanTable,u=e("./context"),c=e("./prefix"),d=e("./transform"),h=8,f=16,g=256,p=704,m=26,b=6,v=2,w=8,y=255,C=1080,x=18,S=new Uint8Array([1,2,3,4,0,5,17,6,16,7,8,9,10,11,12,13,14,15]),E=16,R=new Uint8Array([3,2,1,0,3,3,3,3,3,3,2,2,2,2,2,2]),O=new Int8Array([0,0,0,0,-1,1,-2,2,-3,3,-1,1,-2,2,-3,3]),I=new Uint16Array([256,402,436,468,500,534,566,598,630,662,694,726,758,790,822,854,886,920,952,984,1016,1048,1080]);function k(e){var t;return 0===e.readBits(1)?16:(t=e.readBits(3))>0?17+t:(t=e.readBits(3))>0?8+t:17}function M(e){if(e.readBits(1)){var t=e.readBits(3);return 0===t?1:e.readBits(t)+(1<1&&0===i)throw new Error("Invalid size byte");o.meta_block_length|=i<<8*r}}else for(r=0;r4&&0===s)throw new Error("Invalid size nibble");o.meta_block_length|=s<<4*r}return++o.meta_block_length,o.input_end||o.is_metadata||(o.is_uncompressed=e.readBits(1)),o}function P(e,t,n){var r;return n.fillBitWindow(),(r=e[t+=n.val_>>>n.bit_pos_&y].bits-w)>0&&(n.bit_pos_+=w,t+=e[t].value,t+=n.val_>>>n.bit_pos_&(1<>=1,++c;for(p=0;p0;++p){var C,E=S[p],R=0;r.fillBitWindow(),R+=r.val_>>>r.bit_pos_&15,r.bit_pos_+=y[R].bits,C=y[R].value,m[E]=C,0!==C&&(b-=32>>C,++v)}if(1!==v&&0!==b)throw new Error("[ReadHuffmanCode] invalid num_codes or space");!function(e,t,n,r){for(var o=0,i=h,s=0,u=0,c=32768,d=[],g=0;g<32;g++)d.push(new a(0,0));for(l(d,0,5,e,x);o0;){var p,m=0;if(r.readMoreInput(),r.fillBitWindow(),m+=r.val_>>>r.bit_pos_&31,r.bit_pos_+=d[m].bits,(p=255&d[m].value)>p);else{var b,v,w=p-14,y=0;if(p===f&&(y=i),u!==y&&(s=0,u=y),b=s,s>0&&(s-=2,s<<=w),o+(v=(s+=r.readBits(w)+3)-b)>t)throw new Error("[ReadHuffmanCodeLengths] symbol + repeat_delta > num_symbols");for(var C=0;C>>5]),this.htrees=new Uint32Array(t)}function z(e,t){var n,r,o={num_htrees:null,context_map:null},i=0;t.readMoreInput();var s=o.num_htrees=M(t)+1,l=o.context_map=new Uint8Array(e);if(s<=1)return o;for(t.readBits(1)&&(i=t.readBits(4)+1),n=[],r=0;r=e)throw new Error("[DecodeContextMap] i >= context_map_size");l[r]=0,++r}else l[r]=u-i,++r}return t.readBits(1)&&function(e,t){var n,r=new Uint8Array(256);for(n=0;n<256;++n)r[n]=n;for(n=0;n=e&&(a-=e),r[n]=a,o[l+(1&i[u])]=a,++i[u]}function G(e,t,n,r,o,s){var a,l=o+1,u=n&o,c=s.pos_&i.IBUF_MASK;if(t<8||s.bit_pos_+(t<<3)0;)s.readMoreInput(),r[u++]=s.readBits(8),u===l&&(e.write(r,l),u=0);else{if(s.bit_end_pos_<32)throw new Error("[CopyUncompressedBlockToOutput] br.bit_end_pos_ < 32");for(;s.bit_pos_<32;)r[u]=s.val_>>>s.bit_pos_,s.bit_pos_+=8,++u,--t;if(c+(a=s.bit_end_pos_-s.bit_pos_>>3)>i.IBUF_MASK){for(var d=i.IBUF_MASK+1-c,h=0;h=l)for(e.write(r,l),u-=l,h=0;h=l;){if(a=l-u,s.input_.read(r,u,a)t.buffer.length){var ve=new Uint8Array(R+ne);ve.set(t.buffer),t.buffer=ve}if(O=be.input_end,Y=be.is_uncompressed,be.is_metadata)for(H(x);ne>0;--ne)x.readMoreInput(),x.readBits(8);else if(0!==ne)if(Y)x.bit_pos_=x.bit_pos_+7&-8,G(t,ne,R,h,l,x),R+=ne;else{for(n=0;n<3;++n)ie[n]=M(x)+1,ie[n]>=2&&(A(ie[n]+2,w,n*C,x),A(m,y,n*C,x),re[n]=V(y,n*C,x),ae[n]=1);for(x.readMoreInput(),X=(1<<(_=x.readBits(2)))-1,J=(Z=E+(x.readBits(4)<<_))+(48<<_),ue=new Uint8Array(ie[0]),n=0;n0;){var Ce,xe,Se,Ee,Re,Oe,Ie,ke,Me,Fe,De,Pe;for(x.readMoreInput(),0===re[1]&&(B(ie[1],w,1,oe,se,ae,x),re[1]=V(y,C,x),te=j[1].htrees[oe[1]]),--re[1],(xe=(Ce=P(j[1].codes,te,x))>>6)>=2?(xe-=2,Ie=-1):Ie=0,Se=c.kInsertRangeLut[xe]+(Ce>>3&7),Ee=c.kCopyRangeLut[xe]+(7&Ce),Re=c.kInsertLengthPrefixCode[Se].offset+x.readBits(c.kInsertLengthPrefixCode[Se].nbits),Oe=c.kCopyLengthPrefixCode[Ee].offset+x.readBits(c.kCopyLengthPrefixCode[Ee].nbits),U=h[R-1&l],W=h[R-2&l],Me=0;Me4?3:Oe-2))],(Ie=P(j[2].codes,j[2].htrees[ge],x))>=Z&&(Pe=(Ie-=Z)&X,Ie=Z+((Ae=(2+(1&(Ie>>=_))<<(De=1+(Ie>>1)))-4)+x.readBits(De)<<_)+Pe)),(ke=T(Ie,F,L))<0)throw new Error("[BrotliDecompress] invalid distance");if(Fe=R&l,ke>(I=R=s.minDictionaryWordLength&&Oe<=s.maxDictionaryWordLength))throw new Error("Invalid backward reference. pos: "+R+" distance: "+ke+" len: "+Oe+" bytes left: "+ne);var Ae=s.offsetsByLength[Oe],Ve=ke-I-1,Te=s.sizeBitsByLength[Oe],Le=Ve>>Te;if(Ae+=(Ve&(1<=f){t.write(h,o);for(var _x=0;_x0&&(F[3&L]=ke,++L),Oe>ne)throw new Error("Invalid backward reference. pos: "+R+" distance: "+ke+" len: "+Oe+" bytes left: "+ne);for(Me=0;Me>=1;return(e&n-1)+n}function s(e,t,n,o,i){do{e[t+(o-=n)]=new r(i.bits,i.value)}while(o>0)}function a(e,t,n){for(var r=1<0;--C[c])s(e,t+h,f,b,new r(255&c,65535&w[d++])),h=i(h,c);for(p=v-1,g=-1,c=n+1,f=2;c<=o;++c,f<<=1)for(;C[c]>0;--C[c])(h&p)!==g&&(t+=b,v+=b=1<<(m=a(C,c,n)),e[y+(g=h&p)]=new r(m+n&255,t-y-g&65535)),s(e,t+(h>>n),f,b,new r(c-n&255,65535&w[d++])),h=i(h,c);return v}},{}],8:[function(e,t,n){"use strict";n.byteLength=function(e){var t=l(e),n=t[0],r=t[1];return 3*(n+r)/4-r},n.toByteArray=function(e){for(var t,n=l(e),r=n[0],s=n[1],a=new i(function(e,t,n){return 3*(t+n)/4-n}(0,r,s)),u=0,c=s>0?r-4:r,d=0;d>16&255,a[u++]=t>>8&255,a[u++]=255&t;return 2===s&&(t=o[e.charCodeAt(d)]<<2|o[e.charCodeAt(d+1)]>>4,a[u++]=255&t),1===s&&(t=o[e.charCodeAt(d)]<<10|o[e.charCodeAt(d+1)]<<4|o[e.charCodeAt(d+2)]>>2,a[u++]=t>>8&255,a[u++]=255&t),a},n.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],s=16383,a=0,l=n-o;al?l:a+s));return 1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0;a<64;++a)r[a]=s[a],o[s.charCodeAt(a)]=a;function l(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function u(e,t,n){for(var o,i=[],s=t;s>18&63]+r[a>>12&63]+r[a>>6&63]+r[63&a]);var a;return i.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},{}],9:[function(e,t,n){function r(e,t){this.offset=e,this.nbits=t}n.kBlockLengthPrefixCode=[new r(1,2),new r(5,2),new r(9,2),new r(13,2),new r(17,3),new r(25,3),new r(33,3),new r(41,3),new r(49,4),new r(65,4),new r(81,4),new r(97,4),new r(113,5),new r(145,5),new r(177,5),new r(209,5),new r(241,6),new r(305,6),new r(369,7),new r(497,8),new r(753,9),new r(1265,10),new r(2289,11),new r(4337,12),new r(8433,13),new r(16625,24)],n.kInsertLengthPrefixCode=[new r(0,0),new r(1,0),new r(2,0),new r(3,0),new r(4,0),new r(5,0),new r(6,1),new r(8,1),new r(10,2),new r(14,2),new r(18,3),new r(26,3),new r(34,4),new r(50,4),new r(66,5),new r(98,5),new r(130,6),new r(194,7),new r(322,8),new r(578,9),new r(1090,10),new r(2114,12),new r(6210,14),new r(22594,24)],n.kCopyLengthPrefixCode=[new r(2,0),new r(3,0),new r(4,0),new r(5,0),new r(6,0),new r(7,0),new r(8,0),new r(9,0),new r(10,1),new r(12,1),new r(14,2),new r(18,2),new r(22,3),new r(30,3),new r(38,4),new r(54,4),new r(70,5),new r(102,5),new r(134,6),new r(198,7),new r(326,8),new r(582,9),new r(1094,10),new r(2118,24)],n.kInsertRangeLut=[0,0,8,8,0,16,8,16,16],n.kCopyRangeLut=[0,8,0,8,16,0,16,8,16]},{}],10:[function(e,t,n){function r(e){this.buffer=e,this.pos=0}function o(e){this.buffer=e,this.pos=0}r.prototype.read=function(e,t,n){this.pos+n>this.buffer.length&&(n=this.buffer.length-this.pos);for(var r=0;rthis.buffer.length)throw new Error("Output buffer is not large enough");return this.buffer.set(e.subarray(0,t),this.pos),this.pos+=t,t},n.BrotliOutput=o},{}],11:[function(e,t,n){var r=e("./dictionary"),o=10,i=11;function s(e,t,n){this.prefix=new Uint8Array(e.length),this.transform=t,this.suffix=new Uint8Array(n.length);for(var r=0;r'),new s("",0,"\n"),new s("",3,""),new s("",0,"]"),new s("",0," for "),new s("",14,""),new s("",2,""),new s("",0," a "),new s("",0," that "),new s(" ",o,""),new s("",0,". "),new s(".",0,""),new s(" ",0,", "),new s("",15,""),new s("",0," with "),new s("",0,"'"),new s("",0," from "),new s("",0," by "),new s("",16,""),new s("",17,""),new s(" the ",0,""),new s("",4,""),new s("",0,". The "),new s("",i,""),new s("",0," on "),new s("",0," as "),new s("",0," is "),new s("",7,""),new s("",1,"ing "),new s("",0,"\n\t"),new s("",0,":"),new s(" ",0,". "),new s("",0,"ed "),new s("",20,""),new s("",18,""),new s("",6,""),new s("",0,"("),new s("",o,", "),new s("",8,""),new s("",0," at "),new s("",0,"ly "),new s(" the ",0," of "),new s("",5,""),new s("",9,""),new s(" ",o,", "),new s("",o,'"'),new s(".",0,"("),new s("",i," "),new s("",o,'">'),new s("",0,'="'),new s(" ",0,"."),new s(".com/",0,""),new s(" the ",0," of the "),new s("",o,"'"),new s("",0,". This "),new s("",0,","),new s(".",0," "),new s("",o,"("),new s("",o,"."),new s("",0," not "),new s(" ",0,'="'),new s("",0,"er "),new s(" ",i," "),new s("",0,"al "),new s(" ",i,""),new s("",0,"='"),new s("",i,'"'),new s("",o,". "),new s(" ",0,"("),new s("",0,"ful "),new s(" ",o,". "),new s("",0,"ive "),new s("",0,"less "),new s("",i,"'"),new s("",0,"est "),new s(" ",o,"."),new s("",i,'">'),new s(" ",0,"='"),new s("",o,","),new s("",0,"ize "),new s("",i,"."),new s(" ",0,""),new s(" ",0,","),new s("",o,'="'),new s("",i,'="'),new s("",0,"ous "),new s("",i,", "),new s("",o,"='"),new s(" ",o,","),new s(" ",i,'="'),new s(" ",i,", "),new s("",i,","),new s("",i,"("),new s("",i,". "),new s(" ",i,"."),new s("",i,"='"),new s(" ",i,". "),new s(" ",o,'="'),new s(" ",i,"='"),new s(" ",o,"='")];function l(e,t){return e[t]<192?(e[t]>=97&&e[t]<=122&&(e[t]^=32),1):e[t]<224?(e[t+1]^=32,2):(e[t+2]^=5,3)}n.kTransforms=a,n.kNumTransforms=a.length,n.transformDictionaryWord=function(e,t,n,s,u){var c,d=a[u].prefix,h=a[u].suffix,f=a[u].transform,g=f<12?0:f-11,p=0,m=t;g>s&&(g=s);for(var b=0;b0;){var v=l(e,c);c+=v,s-=v}for(var w=0;w{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";const e=window.React,t=window.wp.i18n,r=window.wp.element,o=window.wp.components,i=window.wp.apiFetch;var s=n.n(i),a=n(606),l=n.n(a),u=n(528),c=n.n(u);globalThis.fetch;class d{constructor(e,t={},n){this.type=e,this.detail=t,this.msg=n,Object.defineProperty(this,"__mayPropagate",{enumerable:!1,writable:!0}),this.__mayPropagate=!0}preventDefault(){}stopPropagation(){this.__mayPropagate=!1}valueOf(){return this}toString(){return this.msg?`[${this.type} event]: ${this.msg}`:`[${this.type} event]`}}class h{constructor(){this.listeners={}}addEventListener(e,t,n){let r=this.listeners[e]||[];n?r.unshift(t):r.push(t),this.listeners[e]=r}removeEventListener(e,t){let n=this.listeners[e]||[],r=n.findIndex((e=>e===t));r>-1&&(n.splice(r,1),this.listeners[e]=n)}dispatch(e){let t=this.listeners[e.type];if(t)for(let n=0,r=t.length;n{let t=e.replace(/get(Big)?/,"").toLowerCase(),n=parseInt(e.replace(/[^\d]/g,""))/8;Object.defineProperty(this,t,{get:()=>this.getValue(e,n)})}))}get currentPosition(){return this.start+this.offset}set currentPosition(e){this.start=e,this.offset=0}skip(e=0,t=8){this.offset+=e*t/8}getValue(e,t){let n=this.start+this.offset;this.offset+=t;try{return this.data[e](n)}catch(n){throw console.error("parser",e,t,this),console.error("parser",this.start,this.offset),n}}flags(e){if(8===e||16===e||32===e||64===e)return this[`uint${e}`].toString(2).padStart(e,0).split("").map((e=>"1"===e));console.error("Error parsing flags: flag types can only be 1, 2, 4, or 8 bytes long"),console.trace()}get tag(){const e=this.uint32;return t=[e>>24&255,e>>16&255,e>>8&255,255&e],Array.from(t).map((e=>String.fromCharCode(e))).join("");var t}get fixed(){return this.int16+Math.round(1e3*this.uint16/65356)/1e3}get legacyFixed(){let e=this.uint16,t=this.uint16.toString(16).padStart(4,0);return parseFloat(`${e}.${t}`)}get uint24(){return(this.uint8<<16)+(this.uint8<<8)+this.uint8}get uint128(){let e=0;for(let t=0;t<5;t++){let t=this.uint8;if(e=128*e+(127&t),t<128)break}return e}get longdatetime(){return new Date(f+1e3*parseInt(this.int64.toString()))}get fword(){return this.int16}get ufword(){return this.uint16}get Offset16(){return this.uint16}get Offset32(){return this.uint32}get F2DOT14(){const e=p.uint16;return[0,1,-2,-1][e>>14]+(16383&e)/16384}verifyLength(){this.offset!=this.length&&console.error(`unexpected parsed table size (${this.offset}) for "${this.name}" (expected ${this.length})`)}readBytes(e=0,t=0,n=8,r=!1){if(0===(e=e||this.length))return[];t&&(this.currentPosition=t);const o=`${r?"":"u"}int${n}`,i=[];for(;e--;)i.push(this[o]);return i}}class m{constructor(e){const t={enumerable:!1,get:()=>e};Object.defineProperty(this,"parser",t);const n=e.currentPosition,r={enumerable:!1,get:()=>n};Object.defineProperty(this,"start",r)}load(e){Object.keys(e).forEach((t=>{let n=Object.getOwnPropertyDescriptor(e,t);n.get?this[t]=n.get.bind(this):void 0!==n.value&&(this[t]=n.value)})),this.parser.length&&this.parser.verifyLength()}}class b extends m{constructor(e,t,n){const{parser:r,start:o}=super(new g(e,t,n)),i={enumerable:!1,get:()=>r};Object.defineProperty(this,"p",i);const s={enumerable:!1,get:()=>o};Object.defineProperty(this,"tableStart",s)}}function v(e,t,n){let r;Object.defineProperty(e,t,{get:()=>r||(r=n(),r),enumerable:!0})}class w extends b{constructor(e,t,n){const{p:r}=super({offset:0,length:12},t,"sfnt");this.version=r.uint32,this.numTables=r.uint16,this.searchRange=r.uint16,this.entrySelector=r.uint16,this.rangeShift=r.uint16,r.verifyLength(),this.directory=[...new Array(this.numTables)].map((e=>new y(r))),this.tables={},this.directory.forEach((e=>{v(this.tables,e.tag.trim(),(()=>n(this.tables,{tag:e.tag,offset:e.offset,length:e.length},t)))}))}}class y{constructor(e){this.tag=e.tag,this.checksum=e.uint32,this.offset=e.uint32,this.length=e.uint32}}const C=c().inflate||void 0;class x extends b{constructor(e,t,n){const{p:r}=super({offset:0,length:44},t,"woff");this.signature=r.tag,this.flavor=r.uint32,this.length=r.uint32,this.numTables=r.uint16,r.uint16,this.totalSfntSize=r.uint32,this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.metaOffset=r.uint32,this.metaLength=r.uint32,this.metaOrigLength=r.uint32,this.privOffset=r.uint32,this.privLength=r.uint32,r.verifyLength(),this.directory=[...new Array(this.numTables)].map((e=>new S(r))),E(this,t,n)}}class S{constructor(e){this.tag=e.tag,this.offset=e.uint32,this.compLength=e.uint32,this.origLength=e.uint32,this.origChecksum=e.uint32}}function E(e,t,n){e.tables={},e.directory.forEach((r=>{v(e.tables,r.tag.trim(),(()=>{let o=0,i=t;if(r.compLength!==r.origLength){const e=t.buffer.slice(r.offset,r.offset+r.compLength);let n;if(!C){const e="no brotli decoder available to decode WOFF2 font";throw font.onerror&&font.onerror(e),new Error(e)}n=C(new Uint8Array(e)),i=new DataView(n.buffer)}else o=r.offset;return n(e.tables,{tag:r.tag,offset:o,length:r.origLength},i)}))}))}const R=l();class O extends b{constructor(e,t,n){const{p:r}=super({offset:0,length:48},t,"woff2");this.signature=r.tag,this.flavor=r.uint32,this.length=r.uint32,this.numTables=r.uint16,r.uint16,this.totalSfntSize=r.uint32,this.totalCompressedSize=r.uint32,this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.metaOffset=r.uint32,this.metaLength=r.uint32,this.metaOrigLength=r.uint32,this.privOffset=r.uint32,this.privLength=r.uint32,r.verifyLength(),this.directory=[...new Array(this.numTables)].map((e=>new I(r)));let o,i=r.currentPosition;this.directory[0].offset=0,this.directory.forEach(((e,t)=>{let n=this.directory[t+1];n&&(n.offset=e.offset+(void 0!==e.transformLength?e.transformLength:e.origLength))}));let s=t.buffer.slice(i);if(!R){const t="no brotli decoder available to decode WOFF2 font";throw e.onerror&&e.onerror(t),new Error(t)}o=R(new Uint8Array(s)),function(e,t,n){e.tables={},e.directory.forEach((r=>{v(e.tables,r.tag.trim(),(()=>{const o=r.offset,i=o+(r.transformLength?r.transformLength:r.origLength),s=new DataView(t.slice(o,i).buffer);try{return n(e.tables,{tag:r.tag,offset:0,length:r.origLength},s)}catch(e){console.error(e)}}))}))}(this,o,n)}}class I{constructor(e){this.flags=e.uint8;const t=this.tagNumber=63&this.flags;this.tag=63===t?e.tag:["cmap","head","hhea","hmtx","maxp","name","OS/2","post","cvt ","fpgm","glyf","loca","prep","CFF ","VORG","EBDT","EBLC","gasp","hdmx","kern","LTSH","PCLT","VDMX","vhea","vmtx","BASE","GDEF","GPOS","GSUB","EBSC","JSTF","MATH","CBDT","CBLC","COLR","CPAL","SVG ","sbix","acnt","avar","bdat","bloc","bsln","cvar","fdsc","feat","fmtx","fvar","gvar","hsty","just","lcar","mort","morx","opbd","prop","trak","Zapf","Silf","Glat","Gloc","Feat","Sill"][63&t];let n=0!=(this.transformVersion=(192&this.flags)>>6);"glyf"!==this.tag&&"loca"!==this.tag||(n=3!==this.transformVersion),this.origLength=e.uint128,n&&(this.transformLength=e.uint128)}}const k={};let M=!1;function F(e,t,n){let r=t.tag.replace(/[^\w\d]/g,""),o=k[r];return o?new o(t,n,e):(console.warn(`lib-font has no definition for ${r}. The table was skipped.`),{})}function D(){let e=0;function t(n,r){if(!M)return e>10?r(new Error("loading took too long")):(e++,setTimeout((()=>t(n)),250));n(F)}return new Promise(((e,n)=>t(e)))}Promise.all([Promise.resolve().then((function(){return ee})),Promise.resolve().then((function(){return te})),Promise.resolve().then((function(){return ne})),Promise.resolve().then((function(){return oe})),Promise.resolve().then((function(){return ie})),Promise.resolve().then((function(){return le})),Promise.resolve().then((function(){return ue})),Promise.resolve().then((function(){return de})),Promise.resolve().then((function(){return xe})),Promise.resolve().then((function(){return Ve})),Promise.resolve().then((function(){return Dt})),Promise.resolve().then((function(){return Pt})),Promise.resolve().then((function(){return Tt})),Promise.resolve().then((function(){return zt})),Promise.resolve().then((function(){return Bt})),Promise.resolve().then((function(){return Gt})),Promise.resolve().then((function(){return Ut})),Promise.resolve().then((function(){return Wt})),Promise.resolve().then((function(){return jt})),Promise.resolve().then((function(){return qt})),Promise.resolve().then((function(){return Kt})),Promise.resolve().then((function(){return Yt})),Promise.resolve().then((function(){return Zt})),Promise.resolve().then((function(){return en})),Promise.resolve().then((function(){return nn})),Promise.resolve().then((function(){return rn})),Promise.resolve().then((function(){return on})),Promise.resolve().then((function(){return sn})),Promise.resolve().then((function(){return an})),Promise.resolve().then((function(){return cn})),Promise.resolve().then((function(){return pn})),Promise.resolve().then((function(){return vn})),Promise.resolve().then((function(){return yn})),Promise.resolve().then((function(){return Sn})),Promise.resolve().then((function(){return En})),Promise.resolve().then((function(){return Rn})),Promise.resolve().then((function(){return In})),Promise.resolve().then((function(){return kn})),Promise.resolve().then((function(){return Pn})),Promise.resolve().then((function(){return An})),Promise.resolve().then((function(){return Tn}))]).then((e=>{e.forEach((e=>{let t=Object.keys(e)[0];k[t]=e[t]})),M=!0}));const P=[0,1,0,0],A=[79,84,84,79],V=[119,79,70,70],T=[119,79,70,50];function L(e,t){if(e.length===t.length){for(let n=0;n{globalThis.document&&!this.options.skipStyleSheet&&await async function(e,t,n={}){if(!globalThis.document)return;let r=function(e,t){let n=e.lastIndexOf("."),r=(e.substring(n+1)||"").toLowerCase(),o={ttf:"truetype",otf:"opentype",woff:"woff",woff2:"woff2"}[r];if(o)return o;let i={eot:"The .eot format is not supported: it died in January 12, 2016, when Microsoft retired all versions of IE that didn't already support WOFF.",svg:"The .svg format is not supported: SVG fonts (not to be confused with OpenType with embedded SVG) were so bad we took the entire fonts chapter out of the SVG specification again.",fon:"The .fon format is not supported: this is an ancient Windows bitmap font format.",ttc:"Based on the current CSS specification, font collections are not (yet?) supported."}[r];if(i||(i=`${e} is not a known webfont format.`),t)throw new Error(i);console.warn(`Could not load font: ${i}`)}(t,n.errorOnStyle);if(!r)return;let o=document.createElement("style");o.className="injected-by-Font-js";let i=[];return n.styleRules&&(i=Object.entries(n.styleRules).map((([e,t])=>`${e}: ${t};`))),o.textContent=`\n@font-face {\n font-family: "${e}";\n ${i.join("\n\t")}\n src: url("${t}") format("${r}");\n}`,globalThis.document.head.appendChild(o),o}(this.name,e,this.options),this.loadFont(e)})()}async loadFont(e,t){fetch(e).then((e=>function(e){if(!e.ok)throw new Error(`HTTP ${e.status} - ${e.statusText}`);return e}(e)&&e.arrayBuffer())).then((n=>this.fromDataBuffer(n,t||e))).catch((n=>{const r=new d("error",n,`Failed to load font at ${t||e}`);this.dispatch(r),this.onerror&&this.onerror(r)}))}async fromDataBuffer(e,t){this.fontData=new DataView(e);let n=function(e){const t=[e.getUint8(0),e.getUint8(1),e.getUint8(2),e.getUint8(3)];return L(t,P)||L(t,A)?"SFNT":L(t,V)?"WOFF":L(t,T)?"WOFF2":void 0}(this.fontData);if(!n)throw new Error(`${t} is either an unsupported font format, or not a font at all.`);await this.parseBasicData(n);const r=new d("load",{font:this});this.dispatch(r),this.onload&&this.onload(r)}async parseBasicData(e){return D().then((t=>("SFNT"===e&&(this.opentype=new w(this,this.fontData,t)),"WOFF"===e&&(this.opentype=new x(this,this.fontData,t)),"WOFF2"===e&&(this.opentype=new O(this,this.fontData,t)),this.opentype)))}getGlyphId(e){return this.opentype.tables.cmap.getGlyphId(e)}reverse(e){return this.opentype.tables.cmap.reverse(e)}supports(e){return 0!==this.getGlyphId(e)}supportsVariation(e){return!1!==this.opentype.tables.cmap.supportsVariation(e)}measureText(e,t=16){if(this.__unloaded)throw new Error("Cannot measure text: font was unloaded. Please reload before calling measureText()");let n=document.createElement("div");n.textContent=e,n.style.fontFamily=this.name,n.style.fontSize=`${t}px`,n.style.color="transparent",n.style.background="transparent",n.style.top="0",n.style.left="0",n.style.position="absolute",document.body.appendChild(n);let r=n.getBoundingClientRect();document.body.removeChild(n);const o=this.opentype.tables["OS/2"];return r.fontSize=t,r.ascender=o.sTypoAscender,r.descender=o.sTypoDescender,r}unload(){if(this.styleElement.parentNode){this.styleElement.parentNode.removeElement(this.styleElement);const e=new d("unload",{font:this});this.dispatch(e),this.onunload&&this.onunload(e)}this._unloaded=!0}load(){if(this.__unloaded){delete this.__unloaded,document.head.appendChild(this.styleElement);const e=new d("load",{font:this});this.dispatch(e),this.onload&&this.onload(e)}}}globalThis.Font=N;class z extends m{constructor(e,t,n){super(e),this.plaformID=t,this.encodingID=n}}class B extends z{constructor(e,t,n){super(e,t,n),this.format=0,this.length=e.uint16,this.language=e.uint16,this.glyphIdArray=[...new Array(256)].map((t=>e.uint8))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 0. only supports(id) is implemented.")),0<=e&&e<=255}reverse(e){return console.warn("reverse not implemented for cmap subtable format 0"),{}}getSupportedCharCodes(){return[{start:1,end:256}]}}class G extends z{constructor(e,t,n){super(e,t,n),this.format=2,this.length=e.uint16,this.language=e.uint16,this.subHeaderKeys=[...new Array(256)].map((t=>e.uint16));const r=Math.max(...this.subHeaderKeys),o=e.currentPosition;v(this,"subHeaders",(()=>(e.currentPosition=o,[...new Array(r)].map((t=>new H(e))))));const i=o+8*r;v(this,"glyphIndexArray",(()=>(e.currentPosition=i,[...new Array(r)].map((t=>e.uint16)))))}supports(e){e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 2. only supports(id) is implemented."));const t=e&&255,n=e&&65280,r=this.subHeaders[n],o=this.subHeaders[r],i=o.firstCode,s=i+o.entryCount;return i<=t&&t<=s}reverse(e){return console.warn("reverse not implemented for cmap subtable format 2"),{}}getSupportedCharCodes(e=!1){return e?this.subHeaders.map((e=>({firstCode:e.firstCode,lastCode:e.lastCode}))):this.subHeaders.map((e=>({start:e.firstCode,end:e.lastCode})))}}class H{constructor(e){this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.first+this.entryCount,this.idDelta=e.int16,this.idRangeOffset=e.uint16}}class U extends z{constructor(e,t,n){super(e,t,n),this.format=4,this.length=e.uint16,this.language=e.uint16,this.segCountX2=e.uint16,this.segCount=this.segCountX2/2,this.searchRange=e.uint16,this.entrySelector=e.uint16,this.rangeShift=e.uint16;const r=e.currentPosition;v(this,"endCode",(()=>e.readBytes(this.segCount,r,16)));const o=r+2+this.segCountX2;v(this,"startCode",(()=>e.readBytes(this.segCount,o,16)));const i=o+this.segCountX2;v(this,"idDelta",(()=>e.readBytes(this.segCount,i,16,!0)));const s=i+this.segCountX2;v(this,"idRangeOffset",(()=>e.readBytes(this.segCount,s,16)));const a=s+this.segCountX2,l=this.length-(a-this.tableStart);v(this,"glyphIdArray",(()=>e.readBytes(l,a,16))),v(this,"segments",(()=>this.buildSegments(s,a,e)))}buildSegments(e,t,n){return[...new Array(this.segCount)].map(((t,r)=>{let o=this.startCode[r],i=this.endCode[r],s=this.idDelta[r],a=this.idRangeOffset[r],l=e+2*r,u=[];if(0===a)for(let e=o+s,t=i+s;e<=t;e++)u.push(e);else for(let e=0,t=i-o;e<=t;e++)n.currentPosition=l+a+2*e,u.push(n.uint16);return{startCode:o,endCode:i,idDelta:s,idRangeOffset:a,glyphIDs:u}}))}reverse(e){let t=this.segments.find((t=>t.glyphIDs.includes(e)));if(!t)return{};const n=t.startCode+t.glyphIDs.indexOf(e);return{code:n,unicode:String.fromCodePoint(n)}}getGlyphId(e){if(e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343)return 0;if(65534==(65534&e)||65535==(65535&e))return 0;let t=this.segments.find((t=>t.startCode<=e&&e<=t.endCode));return t?t.glyphIDs[e-t.startCode]:0}supports(e){return 0!==this.getGlyphId(e)}getSupportedCharCodes(e=!1){return e?this.segments:this.segments.map((e=>({start:e.startCode,end:e.endCode})))}}class W extends z{constructor(e,t,n){super(e,t,n),this.format=6,this.length=e.uint16,this.language=e.uint16,this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.firstCode+this.entryCount-1,v(this,"glyphIdArray",(()=>[...new Array(this.entryCount)].map((t=>e.uint16))))}supports(e){if(e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 6. only supports(id) is implemented.")),ethis.firstCode+this.entryCount)return{};const t=e-this.firstCode;return{code:t,unicode:String.fromCodePoint(t)}}reverse(e){let t=this.glyphIdArray.indexOf(e);if(t>-1)return this.firstCode+t}getSupportedCharCodes(e=!1){return e?[{firstCode:this.firstCode,lastCode:this.lastCode}]:[{start:this.firstCode,end:this.lastCode}]}}class j extends z{constructor(e,t,n){super(e,t,n),this.format=8,e.uint16,this.length=e.uint32,this.language=e.uint32,this.is32=[...new Array(8192)].map((t=>e.uint8)),this.numGroups=e.uint32,v(this,"groups",(()=>[...new Array(this.numGroups)].map((t=>new q(e)))))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 8. only supports(id) is implemented.")),-1!==this.groups.findIndex((t=>t.startcharCode<=e&&e<=t.endcharCode))}reverse(e){return console.warn("reverse not implemented for cmap subtable format 8"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map((e=>({start:e.startcharCode,end:e.endcharCode})))}}class q{constructor(e){this.startcharCode=e.uint32,this.endcharCode=e.uint32,this.startGlyphID=e.uint32}}class K extends z{constructor(e,t,n){super(e,t,n),this.format=10,e.uint16,this.length=e.uint32,this.language=e.uint32,this.startCharCode=e.uint32,this.numChars=e.uint32,this.endCharCode=this.startCharCode+this.numChars,v(this,"glyphs",(()=>[...new Array(this.numChars)].map((t=>e.uint16))))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 10. only supports(id) is implemented.")),!(ethis.startCharCode+this.numChars)&&e-this.startCharCode}reverse(e){return console.warn("reverse not implemented for cmap subtable format 10"),{}}getSupportedCharCodes(e=!1){return e?[{startCharCode:this.startCharCode,endCharCode:this.endCharCode}]:[{start:this.startCharCode,end:this.endCharCode}]}}class Y extends z{constructor(e,t,n){super(e,t,n),this.format=12,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32,v(this,"groups",(()=>[...new Array(this.numGroups)].map((t=>new _(e)))))}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||65534==(65534&e)||65535==(65535&e)?0:-1!==this.groups.findIndex((t=>t.startCharCode<=e&&e<=t.endCharCode))}reverse(e){for(let t of this.groups){let n=t.startGlyphID;if(n>e)continue;if(n===e)return t.startCharCode;if(n+(t.endCharCode-t.startCharCode)({start:e.startCharCode,end:e.endCharCode})))}}class _{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.startGlyphID=e.uint32}}class Z extends z{constructor(e,t,n){super(e,t,n),this.format=13,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32,v(this,"groups",[...new Array(this.numGroups)].map((t=>new X(e))))}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),-1!==this.groups.findIndex((t=>t.startCharCode<=e&&e<=t.endCharCode))}reverse(e){return console.warn("reverse not implemented for cmap subtable format 13"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map((e=>({start:e.startCharCode,end:e.endCharCode})))}}class X{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.glyphID=e.uint32}}class J extends z{constructor(e,t,n){super(e,t,n),this.subTableStart=e.currentPosition,this.format=14,this.length=e.uint32,this.numVarSelectorRecords=e.uint32,v(this,"varSelectors",(()=>[...new Array(this.numVarSelectorRecords)].map((t=>new Q(e)))))}supports(){return console.warn("supports not implemented for cmap subtable format 14"),0}getSupportedCharCodes(){return console.warn("getSupportedCharCodes not implemented for cmap subtable format 14"),[]}reverse(e){return console.warn("reverse not implemented for cmap subtable format 14"),{}}supportsVariation(e){return this.varSelector.find((t=>t.varSelector===e))||!1}getSupportedVariations(){return this.varSelectors.map((e=>e.varSelector))}}class Q{constructor(e){this.varSelector=e.uint24,this.defaultUVSOffset=e.Offset32,this.nonDefaultUVSOffset=e.Offset32}}class ${constructor(e,t){const n=this.platformID=e.uint16,r=this.encodingID=e.uint16,o=this.offset=e.Offset32;v(this,"table",(()=>(e.currentPosition=t+o,function(e,t,n){const r=e.uint16;return 0===r?new B(e,t,n):2===r?new G(e,t,n):4===r?new U(e,t,n):6===r?new W(e,t,n):8===r?new j(e,t,n):10===r?new K(e,t,n):12===r?new Y(e,t,n):13===r?new Z(e,t,n):14===r?new J(e,t,n):{}}(e,n,r))))}}var ee=Object.freeze({__proto__:null,cmap:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.numTables=n.uint16,this.encodingRecords=[...new Array(this.numTables)].map((e=>new $(n,this.tableStart)))}getSubTable(e){return this.encodingRecords[e].table}getSupportedEncodings(){return this.encodingRecords.map((e=>({platformID:e.platformID,encodingId:e.encodingID})))}getSupportedCharCodes(e,t){const n=this.encodingRecords.findIndex((n=>n.platformID===e&&n.encodingID===t));return-1!==n&&this.getSubTable(n).getSupportedCharCodes()}reverse(e){for(let t=0;t{let o=this.getSubTable(r);return!!o.getGlyphId&&(t=o.getGlyphId(e),0!==t)})),t}supports(e){return this.encodingRecords.some(((t,n)=>{const r=this.getSubTable(n);return r.supports&&!1!==r.supports(e)}))}supportsVariation(e){return this.encodingRecords.some(((t,n)=>{const r=this.getSubTable(n);return r.supportsVariation&&!1!==r.supportsVariation(e)}))}}}),te=Object.freeze({__proto__:null,head:class extends b{constructor(e,t){const{p:n}=super(e,t);this.load({majorVersion:n.uint16,minorVersion:n.uint16,fontRevision:n.fixed,checkSumAdjustment:n.uint32,magicNumber:n.uint32,flags:n.flags(16),unitsPerEm:n.uint16,created:n.longdatetime,modified:n.longdatetime,xMin:n.int16,yMin:n.int16,xMax:n.int16,yMax:n.int16,macStyle:n.flags(16),lowestRecPPEM:n.uint16,fontDirectionHint:n.uint16,indexToLocFormat:n.uint16,glyphDataFormat:n.uint16})}}}),ne=Object.freeze({__proto__:null,hhea:class extends b{constructor(e,t){const{p:n}=super(e,t);this.majorVersion=n.uint16,this.minorVersion=n.uint16,this.ascender=n.fword,this.descender=n.fword,this.lineGap=n.fword,this.advanceWidthMax=n.ufword,this.minLeftSideBearing=n.fword,this.minRightSideBearing=n.fword,this.xMaxExtent=n.fword,this.caretSlopeRise=n.int16,this.caretSlopeRun=n.int16,this.caretOffset=n.int16,n.int16,n.int16,n.int16,n.int16,this.metricDataFormat=n.int16,this.numberOfHMetrics=n.uint16,n.verifyLength()}}});class re{constructor(e,t){this.advanceWidth=e,this.lsb=t}}var oe=Object.freeze({__proto__:null,hmtx:class extends b{constructor(e,t,n){const{p:r}=super(e,t),o=n.hhea.numberOfHMetrics,i=n.maxp.numGlyphs,s=r.currentPosition;if(v(this,"hMetrics",(()=>(r.currentPosition=s,[...new Array(o)].map((e=>new re(r.uint16,r.int16)))))),o(r.currentPosition=e,[...new Array(i-o)].map((e=>r.int16)))))}}}}),ie=Object.freeze({__proto__:null,maxp:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.legacyFixed,this.numGlyphs=n.uint16,1===this.version&&(this.maxPoints=n.uint16,this.maxContours=n.uint16,this.maxCompositePoints=n.uint16,this.maxCompositeContours=n.uint16,this.maxZones=n.uint16,this.maxTwilightPoints=n.uint16,this.maxStorage=n.uint16,this.maxFunctionDefs=n.uint16,this.maxInstructionDefs=n.uint16,this.maxStackElements=n.uint16,this.maxSizeOfInstructions=n.uint16,this.maxComponentElements=n.uint16,this.maxComponentDepth=n.uint16),n.verifyLength()}}});class se{constructor(e,t){this.length=e,this.offset=t}}class ae{constructor(e,t){this.platformID=e.uint16,this.encodingID=e.uint16,this.languageID=e.uint16,this.nameID=e.uint16,this.length=e.uint16,this.offset=e.Offset16,v(this,"string",(()=>(e.currentPosition=t.stringStart+this.offset,function(e,t){const{platformID:n,length:r}=t;if(0===r)return"";if(0===n||3===n){const t=[];for(let n=0,o=r/2;nnew ae(n,this))),1===this.format&&(this.langTagCount=n.uint16,this.langTagRecords=[...new Array(this.langTagCount)].map((e=>new se(n.uint16,n.Offset16)))),this.stringStart=this.tableStart+this.stringOffset}get(e){let t=this.nameRecords.find((t=>t.nameID===e));if(t)return t.string}}}),ue=Object.freeze({__proto__:null,OS2:class extends b{constructor(e,t){const{p:n}=super(e,t);return this.version=n.uint16,this.xAvgCharWidth=n.int16,this.usWeightClass=n.uint16,this.usWidthClass=n.uint16,this.fsType=n.uint16,this.ySubscriptXSize=n.int16,this.ySubscriptYSize=n.int16,this.ySubscriptXOffset=n.int16,this.ySubscriptYOffset=n.int16,this.ySuperscriptXSize=n.int16,this.ySuperscriptYSize=n.int16,this.ySuperscriptXOffset=n.int16,this.ySuperscriptYOffset=n.int16,this.yStrikeoutSize=n.int16,this.yStrikeoutPosition=n.int16,this.sFamilyClass=n.int16,this.panose=[...new Array(10)].map((e=>n.uint8)),this.ulUnicodeRange1=n.flags(32),this.ulUnicodeRange2=n.flags(32),this.ulUnicodeRange3=n.flags(32),this.ulUnicodeRange4=n.flags(32),this.achVendID=n.tag,this.fsSelection=n.uint16,this.usFirstCharIndex=n.uint16,this.usLastCharIndex=n.uint16,this.sTypoAscender=n.int16,this.sTypoDescender=n.int16,this.sTypoLineGap=n.int16,this.usWinAscent=n.uint16,this.usWinDescent=n.uint16,0===this.version?n.verifyLength():(this.ulCodePageRange1=n.flags(32),this.ulCodePageRange2=n.flags(32),1===this.version?n.verifyLength():(this.sxHeight=n.int16,this.sCapHeight=n.int16,this.usDefaultChar=n.uint16,this.usBreakChar=n.uint16,this.usMaxContext=n.uint16,this.version<=4?n.verifyLength():(this.usLowerOpticalPointSize=n.uint16,this.usUpperOpticalPointSize=n.uint16,5===this.version?n.verifyLength():void 0)))}}});const ce=[".notdef",".null","nonmarkingreturn","space","exclam","quotedbl","numbersign","dollar","percent","ampersand","quotesingle","parenleft","parenright","asterisk","plus","comma","hyphen","period","slash","zero","one","two","three","four","five","six","seven","eight","nine","colon","semicolon","less","equal","greater","question","at","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","bracketleft","backslash","bracketright","asciicircum","underscore","grave","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","braceleft","bar","braceright","asciitilde","Adieresis","Aring","Ccedilla","Eacute","Ntilde","Odieresis","Udieresis","aacute","agrave","acircumflex","adieresis","atilde","aring","ccedilla","eacute","egrave","ecircumflex","edieresis","iacute","igrave","icircumflex","idieresis","ntilde","oacute","ograve","ocircumflex","odieresis","otilde","uacute","ugrave","ucircumflex","udieresis","dagger","degree","cent","sterling","section","bullet","paragraph","germandbls","registered","copyright","trademark","acute","dieresis","notequal","AE","Oslash","infinity","plusminus","lessequal","greaterequal","yen","mu","partialdiff","summation","product","pi","integral","ordfeminine","ordmasculine","Omega","ae","oslash","questiondown","exclamdown","logicalnot","radical","florin","approxequal","Delta","guillemotleft","guillemotright","ellipsis","nonbreakingspace","Agrave","Atilde","Otilde","OE","oe","endash","emdash","quotedblleft","quotedblright","quoteleft","quoteright","divide","lozenge","ydieresis","Ydieresis","fraction","currency","guilsinglleft","guilsinglright","fi","fl","daggerdbl","periodcentered","quotesinglbase","quotedblbase","perthousand","Acircumflex","Ecircumflex","Aacute","Edieresis","Egrave","Iacute","Icircumflex","Idieresis","Igrave","Oacute","Ocircumflex","apple","Ograve","Uacute","Ucircumflex","Ugrave","dotlessi","circumflex","tilde","macron","breve","dotaccent","ring","cedilla","hungarumlaut","ogonek","caron","Lslash","lslash","Scaron","scaron","Zcaron","zcaron","brokenbar","Eth","eth","Yacute","yacute","Thorn","thorn","minus","multiply","onesuperior","twosuperior","threesuperior","onehalf","onequarter","threequarters","franc","Gbreve","gbreve","Idotaccent","Scedilla","scedilla","Cacute","cacute","Ccaron","ccaron","dcroat"];var de=Object.freeze({__proto__:null,post:class extends b{constructor(e,t){const{p:n}=super(e,t);if(this.version=n.legacyFixed,this.italicAngle=n.fixed,this.underlinePosition=n.fword,this.underlineThickness=n.fword,this.isFixedPitch=n.uint32,this.minMemType42=n.uint32,this.maxMemType42=n.uint32,this.minMemType1=n.uint32,this.maxMemType1=n.uint32,1===this.version||3===this.version)return n.verifyLength();if(this.numGlyphs=n.uint16,2===this.version){this.glyphNameIndex=[...new Array(this.numGlyphs)].map((e=>n.uint16)),this.namesOffset=n.currentPosition,this.glyphNameOffsets=[1];for(let e=0;en.int8)))}getGlyphName(e){if(2!==this.version)return console.warn(`post table version ${this.version} does not support glyph name lookups`),"";let t=this.glyphNameIndex[e];if(t<258)return ce[t];let n=this.glyphNameOffsets[e],r=this.glyphNameOffsets[e+1]-n-1;return 0===r?".notdef.":(this.parser.currentPosition=this.namesOffset+n,this.parser.readBytes(r,this.namesOffset+n,8,!0).map((e=>String.fromCharCode(e))).join(""))}}});class he extends b{constructor(e,t){const{p:n}=super(e,t,"AxisTable");this.baseTagListOffset=n.Offset16,this.baseScriptListOffset=n.Offset16,v(this,"baseTagList",(()=>new fe({offset:e.offset+this.baseTagListOffset},t))),v(this,"baseScriptList",(()=>new ge({offset:e.offset+this.baseScriptListOffset},t)))}}class fe extends b{constructor(e,t){const{p:n}=super(e,t,"BaseTagListTable");this.baseTagCount=n.uint16,this.baselineTags=[...new Array(this.baseTagCount)].map((e=>n.tag))}}class ge extends b{constructor(e,t){const{p:n}=super(e,t,"BaseScriptListTable");this.baseScriptCount=n.uint16;const r=n.currentPosition;v(this,"baseScriptRecords",(()=>(n.currentPosition=r,[...new Array(this.baseScriptCount)].map((e=>new pe(this.start,n))))))}}class pe{constructor(e,t){this.baseScriptTag=t.tag,this.baseScriptOffset=t.Offset16,v(this,"baseScriptTable",(()=>(t.currentPosition=e+this.baseScriptOffset,new me(t))))}}class me{constructor(e){this.start=e.currentPosition,this.baseValuesOffset=e.Offset16,this.defaultMinMaxOffset=e.Offset16,this.baseLangSysCount=e.uint16,this.baseLangSysRecords=[...new Array(this.baseLangSysCount)].map((t=>new be(this.start,e))),v(this,"baseValues",(()=>(e.currentPosition=this.start+this.baseValuesOffset,new ve(e)))),v(this,"defaultMinMax",(()=>(e.currentPosition=this.start+this.defaultMinMaxOffset,new we(e))))}}class be{constructor(e,t){this.baseLangSysTag=t.tag,this.minMaxOffset=t.Offset16,v(this,"minMax",(()=>(t.currentPosition=e+this.minMaxOffset,new we(t))))}}class ve{constructor(e){this.parser=e,this.start=e.currentPosition,this.defaultBaselineIndex=e.uint16,this.baseCoordCount=e.uint16,this.baseCoords=[...new Array(this.baseCoordCount)].map((t=>e.Offset16))}getTable(e){return this.parser.currentPosition=this.start+this.baseCoords[e],new Ce(this.parser)}}class we{constructor(e){this.minCoord=e.Offset16,this.maxCoord=e.Offset16,this.featMinMaxCount=e.uint16;const t=e.currentPosition;v(this,"featMinMaxRecords",(()=>(e.currentPosition=t,[...new Array(this.featMinMaxCount)].map((t=>new ye(e))))))}}class ye{constructor(e){this.featureTableTag=e.tag,this.minCoord=e.Offset16,this.maxCoord=e.Offset16}}class Ce{constructor(e){this.baseCoordFormat=e.uint16,this.coordinate=e.int16,2===this.baseCoordFormat&&(this.referenceGlyph=e.uint16,this.baseCoordPoint=e.uint16),3===this.baseCoordFormat&&(this.deviceTable=e.Offset16)}}var xe=Object.freeze({__proto__:null,BASE:class extends b{constructor(e,t){const{p:n}=super(e,t);this.majorVersion=n.uint16,this.minorVersion=n.uint16,this.horizAxisOffset=n.Offset16,this.vertAxisOffset=n.Offset16,v(this,"horizAxis",(()=>new he({offset:e.offset+this.horizAxisOffset},t))),v(this,"vertAxis",(()=>new he({offset:e.offset+this.vertAxisOffset},t))),1===this.majorVersion&&1===this.minorVersion&&(this.itemVarStoreOffset=n.Offset32,v(this,"itemVarStore",(()=>new he({offset:e.offset+this.itemVarStoreOffset},t))))}}});class Se{constructor(e){this.classFormat=e.uint16,1===this.classFormat&&(this.startGlyphID=e.uint16,this.glyphCount=e.uint16,this.classValueArray=[...new Array(this.glyphCount)].map((t=>e.uint16))),2===this.classFormat&&(this.classRangeCount=e.uint16,this.classRangeRecords=[...new Array(this.classRangeCount)].map((t=>new Ee(e))))}}class Ee{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.class=e.uint16}}class Re extends m{constructor(e){super(e),this.coverageFormat=e.uint16,1===this.coverageFormat&&(this.glyphCount=e.uint16,this.glyphArray=[...new Array(this.glyphCount)].map((t=>e.uint16))),2===this.coverageFormat&&(this.rangeCount=e.uint16,this.rangeRecords=[...new Array(this.rangeCount)].map((t=>new Oe(e))))}}class Oe{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.startCoverageIndex=e.uint16}}class Ie{constructor(e,t){this.table=e,this.parser=t,this.start=t.currentPosition,this.format=t.uint16,this.variationRegionListOffset=t.Offset32,this.itemVariationDataCount=t.uint16,this.itemVariationDataOffsets=[...new Array(this.itemVariationDataCount)].map((e=>t.Offset32))}}class ke extends m{constructor(e){super(e),this.coverageOffset=e.Offset16,this.glyphCount=e.uint16,this.attachPointOffsets=[...new Array(this.glyphCount)].map((t=>e.Offset16))}getPoint(e){return this.parser.currentPosition=this.start+this.attachPointOffsets[e],new Me(this.parser)}}class Me{constructor(e){this.pointCount=e.uint16,this.pointIndices=[...new Array(this.pointCount)].map((t=>e.uint16))}}class Fe extends m{constructor(e){super(e),this.coverageOffset=e.Offset16,v(this,"coverage",(()=>(e.currentPosition=this.start+this.coverageOffset,new Re(e)))),this.ligGlyphCount=e.uint16,this.ligGlyphOffsets=[...new Array(this.ligGlyphCount)].map((t=>e.Offset16))}getLigGlyph(e){return this.parser.currentPosition=this.start+this.ligGlyphOffsets[e],new De(this.parser)}}class De extends m{constructor(e){super(e),this.caretCount=e.uint16,this.caretValueOffsets=[...new Array(this.caretCount)].map((t=>e.Offset16))}getCaretValue(e){return this.parser.currentPosition=this.start+this.caretValueOffsets[e],new Pe(this.parser)}}class Pe{constructor(e){this.caretValueFormat=e.uint16,1===this.caretValueFormat&&(this.coordinate=e.int16),2===this.caretValueFormat&&(this.caretValuePointIndex=e.uint16),3===this.caretValueFormat&&(this.coordinate=e.int16,this.deviceOffset=e.Offset16)}}class Ae extends m{constructor(e){super(e),this.markGlyphSetTableFormat=e.uint16,this.markGlyphSetCount=e.uint16,this.coverageOffsets=[...new Array(this.markGlyphSetCount)].map((t=>e.Offset32))}getMarkGlyphSet(e){return this.parser.currentPosition=this.start+this.coverageOffsets[e],new Re(this.parser)}}var Ve=Object.freeze({__proto__:null,GDEF:class extends b{constructor(e,t){const{p:n}=super(e,t);this.majorVersion=n.uint16,this.minorVersion=n.uint16,this.glyphClassDefOffset=n.Offset16,v(this,"glyphClassDefs",(()=>{if(0!==this.glyphClassDefOffset)return n.currentPosition=this.tableStart+this.glyphClassDefOffset,new Se(n)})),this.attachListOffset=n.Offset16,v(this,"attachList",(()=>{if(0!==this.attachListOffset)return n.currentPosition=this.tableStart+this.attachListOffset,new ke(n)})),this.ligCaretListOffset=n.Offset16,v(this,"ligCaretList",(()=>{if(0!==this.ligCaretListOffset)return n.currentPosition=this.tableStart+this.ligCaretListOffset,new Fe(n)})),this.markAttachClassDefOffset=n.Offset16,v(this,"markAttachClassDef",(()=>{if(0!==this.markAttachClassDefOffset)return n.currentPosition=this.tableStart+this.markAttachClassDefOffset,new Se(n)})),this.minorVersion>=2&&(this.markGlyphSetsDefOffset=n.Offset16,v(this,"markGlyphSetsDef",(()=>{if(0!==this.markGlyphSetsDefOffset)return n.currentPosition=this.tableStart+this.markGlyphSetsDefOffset,new Ae(n)}))),3===this.minorVersion&&(this.itemVarStoreOffset=n.Offset32,v(this,"itemVarStore",(()=>{if(0!==this.itemVarStoreOffset)return n.currentPosition=this.tableStart+this.itemVarStoreOffset,new Ie(n)})))}}});class Te extends m{static EMPTY={scriptCount:0,scriptRecords:[]};constructor(e){super(e),this.scriptCount=e.uint16,this.scriptRecords=[...new Array(this.scriptCount)].map((t=>new Le(e)))}}class Le{constructor(e){this.scriptTag=e.tag,this.scriptOffset=e.Offset16}}class Ne extends m{constructor(e){super(e),this.defaultLangSys=e.Offset16,this.langSysCount=e.uint16,this.langSysRecords=[...new Array(this.langSysCount)].map((t=>new ze(e)))}}class ze{constructor(e){this.langSysTag=e.tag,this.langSysOffset=e.Offset16}}class Be{constructor(e){this.lookupOrder=e.Offset16,this.requiredFeatureIndex=e.uint16,this.featureIndexCount=e.uint16,this.featureIndices=[...new Array(this.featureIndexCount)].map((t=>e.uint16))}}class Ge extends m{static EMPTY={featureCount:0,featureRecords:[]};constructor(e){super(e),this.featureCount=e.uint16,this.featureRecords=[...new Array(this.featureCount)].map((t=>new He(e)))}}class He{constructor(e){this.featureTag=e.tag,this.featureOffset=e.Offset16}}class Ue extends m{constructor(e){super(e),this.featureParams=e.Offset16,this.lookupIndexCount=e.uint16,this.lookupListIndices=[...new Array(this.lookupIndexCount)].map((t=>e.uint16))}getFeatureParams(){if(this.featureParams>0){const e=this.parser;e.currentPosition=this.start+this.featureParams;const t=this.featureTag;if("size"===t)return new je(e);if(t.startsWith("cc"))return new We(e);if(t.startsWith("ss"))return new qe(e)}}}class We{constructor(e){this.format=e.uint16,this.featUiLabelNameId=e.uint16,this.featUiTooltipTextNameId=e.uint16,this.sampleTextNameId=e.uint16,this.numNamedParameters=e.uint16,this.firstParamUiLabelNameId=e.uint16,this.charCount=e.uint16,this.character=[...new Array(this.charCount)].map((t=>e.uint24))}}class je{constructor(e){this.designSize=e.uint16,this.subfamilyIdentifier=e.uint16,this.subfamilyNameID=e.uint16,this.smallEnd=e.uint16,this.largeEnd=e.uint16}}class qe{constructor(e){this.version=e.uint16,this.UINameID=e.uint16}}function Ke(e){e.parser.currentPosition-=2,delete e.coverageOffset,delete e.getCoverageTable}class Ye extends m{constructor(e){super(e),this.substFormat=e.uint16,this.coverageOffset=e.Offset16}getCoverageTable(){let e=this.parser;return e.currentPosition=this.start+this.coverageOffset,new Re(e)}}class _e{constructor(e){this.glyphSequenceIndex=e.uint16,this.lookupListIndex=e.uint16}}class Ze extends Ye{constructor(e){super(e),this.deltaGlyphID=e.int16}}class Xe extends Ye{constructor(e){super(e),this.sequenceCount=e.uint16,this.sequenceOffsets=[...new Array(this.sequenceCount)].map((t=>e.Offset16))}getSequence(e){let t=this.parser;return t.currentPosition=this.start+this.sequenceOffsets[e],new Je(t)}}class Je{constructor(e){this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map((t=>e.uint16))}}class Qe extends Ye{constructor(e){super(e),this.alternateSetCount=e.uint16,this.alternateSetOffsets=[...new Array(this.alternateSetCount)].map((t=>e.Offset16))}getAlternateSet(e){let t=this.parser;return t.currentPosition=this.start+this.alternateSetOffsets[e],new $e(t)}}class $e{constructor(e){this.glyphCount=e.uint16,this.alternateGlyphIDs=[...new Array(this.glyphCount)].map((t=>e.uint16))}}class et extends Ye{constructor(e){super(e),this.ligatureSetCount=e.uint16,this.ligatureSetOffsets=[...new Array(this.ligatureSetCount)].map((t=>e.Offset16))}getLigatureSet(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureSetOffsets[e],new tt(t)}}class tt extends m{constructor(e){super(e),this.ligatureCount=e.uint16,this.ligatureOffsets=[...new Array(this.ligatureCount)].map((t=>e.Offset16))}getLigature(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureOffsets[e],new nt(t)}}class nt{constructor(e){this.ligatureGlyph=e.uint16,this.componentCount=e.uint16,this.componentGlyphIDs=[...new Array(this.componentCount-1)].map((t=>e.uint16))}}class rt extends Ye{constructor(e){super(e),1===this.substFormat&&(this.subRuleSetCount=e.uint16,this.subRuleSetOffsets=[...new Array(this.subRuleSetCount)].map((t=>e.Offset16))),2===this.substFormat&&(this.classDefOffset=e.Offset16,this.subClassSetCount=e.uint16,this.subClassSetOffsets=[...new Array(this.subClassSetCount)].map((t=>e.Offset16))),3===this.substFormat&&(Ke(this),this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.coverageOffsets=[...new Array(this.glyphCount)].map((t=>e.Offset16)),this.substLookupRecords=[...new Array(this.substitutionCount)].map((t=>new _e(e))))}getSubRuleSet(e){if(1!==this.substFormat)throw new Error(`lookup type 5.${this.substFormat} has no subrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.subRuleSetOffsets[e],new ot(t)}getSubClassSet(e){if(2!==this.substFormat)throw new Error(`lookup type 5.${this.substFormat} has no subclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.subClassSetOffsets[e],new st(t)}getCoverageTable(e){if(3!==this.substFormat&&!e)return super.getCoverageTable();if(!e)throw new Error(`lookup type 5.${this.substFormat} requires an coverage table index.`);let t=this.parser;return t.currentPosition=this.start+this.coverageOffsets[e],new Re(t)}}class ot extends m{constructor(e){super(e),this.subRuleCount=e.uint16,this.subRuleOffsets=[...new Array(this.subRuleCount)].map((t=>e.Offset16))}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.subRuleOffsets[e],new it(t)}}class it{constructor(e){this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.inputSequence=[...new Array(this.glyphCount-1)].map((t=>e.uint16)),this.substLookupRecords=[...new Array(this.substitutionCount)].map((t=>new _e(e)))}}class st extends m{constructor(e){super(e),this.subClassRuleCount=e.uint16,this.subClassRuleOffsets=[...new Array(this.subClassRuleCount)].map((t=>e.Offset16))}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.subClassRuleOffsets[e],new at(t)}}class at extends it{constructor(e){super(e)}}class lt extends Ye{constructor(e){super(e),1===this.substFormat&&(this.chainSubRuleSetCount=e.uint16,this.chainSubRuleSetOffsets=[...new Array(this.chainSubRuleSetCount)].map((t=>e.Offset16))),2===this.substFormat&&(this.backtrackClassDefOffset=e.Offset16,this.inputClassDefOffset=e.Offset16,this.lookaheadClassDefOffset=e.Offset16,this.chainSubClassSetCount=e.uint16,this.chainSubClassSetOffsets=[...new Array(this.chainSubClassSetCount)].map((t=>e.Offset16))),3===this.substFormat&&(Ke(this),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map((t=>e.Offset16)),this.inputGlyphCount=e.uint16,this.inputCoverageOffsets=[...new Array(this.inputGlyphCount)].map((t=>e.Offset16)),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[...new Array(this.lookaheadGlyphCount)].map((t=>e.Offset16)),this.seqLookupCount=e.uint16,this.seqLookupRecords=[...new Array(this.substitutionCount)].map((t=>new ft(e))))}getChainSubRuleSet(e){if(1!==this.substFormat)throw new Error(`lookup type 6.${this.substFormat} has no chainsubrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleSetOffsets[e],new ut(t)}getChainSubClassSet(e){if(2!==this.substFormat)throw new Error(`lookup type 6.${this.substFormat} has no chainsubclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubClassSetOffsets[e],new dt(t)}getCoverageFromOffset(e){if(3!==this.substFormat)throw new Error(`lookup type 6.${this.substFormat} does not use contextual coverage offsets.`);let t=this.parser;return t.currentPosition=this.start+e,new Re(t)}}class ut extends m{constructor(e){super(e),this.chainSubRuleCount=e.uint16,this.chainSubRuleOffsets=[...new Array(this.chainSubRuleCount)].map((t=>e.Offset16))}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new ct(t)}}class ct{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map((t=>e.uint16)),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map((t=>e.uint16)),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map((t=>e.uint16)),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.SubstCount)].map((t=>new _e(e)))}}class dt extends m{constructor(e){super(e),this.chainSubClassRuleCount=e.uint16,this.chainSubClassRuleOffsets=[...new Array(this.chainSubClassRuleCount)].map((t=>e.Offset16))}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new ht(t)}}class ht{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map((t=>e.uint16)),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map((t=>e.uint16)),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map((t=>e.uint16)),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.substitutionCount)].map((t=>new ft(e)))}}class ft extends m{constructor(e){super(e),this.sequenceIndex=e.uint16,this.lookupListIndex=e.uint16}}class gt extends m{constructor(e){super(e),this.substFormat=e.uint16,this.extensionLookupType=e.uint16,this.extensionOffset=e.Offset32}}class pt extends Ye{constructor(e){super(e),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map((t=>e.Offset16)),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[new Array(this.lookaheadGlyphCount)].map((t=>e.Offset16)),this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map((t=>e.uint16))}}var mt={buildSubtable:function(e,t){const n=new[void 0,Ze,Xe,Qe,et,rt,lt,gt,pt][e](t);return n.type=e,n}};class bt extends m{constructor(e){super(e)}}class vt extends bt{constructor(e){super(e),console.log("lookup type 1")}}class wt extends bt{constructor(e){super(e),console.log("lookup type 2")}}class yt extends bt{constructor(e){super(e),console.log("lookup type 3")}}class Ct extends bt{constructor(e){super(e),console.log("lookup type 4")}}class xt extends bt{constructor(e){super(e),console.log("lookup type 5")}}class St extends bt{constructor(e){super(e),console.log("lookup type 6")}}class Et extends bt{constructor(e){super(e),console.log("lookup type 7")}}class Rt extends bt{constructor(e){super(e),console.log("lookup type 8")}}class Ot extends bt{constructor(e){super(e),console.log("lookup type 9")}}var It={buildSubtable:function(e,t){const n=new[void 0,vt,wt,yt,Ct,xt,St,Et,Rt,Ot][e](t);return n.type=e,n}};class kt extends m{static EMPTY={lookupCount:0,lookups:[]};constructor(e){super(e),this.lookupCount=e.uint16,this.lookups=[...new Array(this.lookupCount)].map((t=>e.Offset16))}}class Mt extends m{constructor(e,t){super(e),this.ctType=t,this.lookupType=e.uint16,this.lookupFlag=e.uint16,this.subTableCount=e.uint16,this.subtableOffsets=[...new Array(this.subTableCount)].map((t=>e.Offset16)),this.markFilteringSet=e.uint16}get rightToLeft(){return!0&this.lookupFlag}get ignoreBaseGlyphs(){return!0&this.lookupFlag}get ignoreLigatures(){return!0&this.lookupFlag}get ignoreMarks(){return!0&this.lookupFlag}get useMarkFilteringSet(){return!0&this.lookupFlag}get markAttachmentType(){return!0&this.lookupFlag}getSubTable(e){const t="GSUB"===this.ctType?mt:It;return this.parser.currentPosition=this.start+this.subtableOffsets[e],t.buildSubtable(this.lookupType,this.parser)}}class Ft extends b{constructor(e,t,n){const{p:r,tableStart:o}=super(e,t,n);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.scriptListOffset=r.Offset16,this.featureListOffset=r.Offset16,this.lookupListOffset=r.Offset16,1===this.majorVersion&&1===this.minorVersion&&(this.featureVariationsOffset=r.Offset32);const i=!(this.scriptListOffset||this.featureListOffset||this.lookupListOffset);v(this,"scriptList",(()=>i?Te.EMPTY:(r.currentPosition=o+this.scriptListOffset,new Te(r)))),v(this,"featureList",(()=>i?Ge.EMPTY:(r.currentPosition=o+this.featureListOffset,new Ge(r)))),v(this,"lookupList",(()=>i?kt.EMPTY:(r.currentPosition=o+this.lookupListOffset,new kt(r)))),this.featureVariationsOffset&&v(this,"featureVariations",(()=>i?FeatureVariations.EMPTY:(r.currentPosition=o+this.featureVariationsOffset,new FeatureVariations(r))))}getSupportedScripts(){return this.scriptList.scriptRecords.map((e=>e.scriptTag))}getScriptTable(e){let t=this.scriptList.scriptRecords.find((t=>t.scriptTag===e));this.parser.currentPosition=this.scriptList.start+t.scriptOffset;let n=new Ne(this.parser);return n.scriptTag=e,n}ensureScriptTable(e){return"string"==typeof e?this.getScriptTable(e):e}getSupportedLangSys(e){const t=0!==(e=this.ensureScriptTable(e)).defaultLangSys,n=e.langSysRecords.map((e=>e.langSysTag));return t&&n.unshift("dflt"),n}getDefaultLangSysTable(e){let t=(e=this.ensureScriptTable(e)).defaultLangSys;if(0!==t){this.parser.currentPosition=e.start+t;let n=new Be(this.parser);return n.langSysTag="",n.defaultForScript=e.scriptTag,n}}getLangSysTable(e,t="dflt"){if("dflt"===t)return this.getDefaultLangSysTable(e);let n=(e=this.ensureScriptTable(e)).langSysRecords.find((e=>e.langSysTag===t));this.parser.currentPosition=e.start+n.langSysOffset;let r=new Be(this.parser);return r.langSysTag=t,r}getFeatures(e){return e.featureIndices.map((e=>this.getFeature(e)))}getFeature(e){let t;if(t=parseInt(e)==e?this.featureList.featureRecords[e]:this.featureList.featureRecords.find((t=>t.featureTag===e)),!t)return;this.parser.currentPosition=this.featureList.start+t.featureOffset;let n=new Ue(this.parser);return n.featureTag=t.featureTag,n}getLookups(e){return e.lookupListIndices.map((e=>this.getLookup(e)))}getLookup(e,t){let n=this.lookupList.lookups[e];return this.parser.currentPosition=this.lookupList.start+n,new Mt(this.parser,t)}}var Dt=Object.freeze({__proto__:null,GSUB:class extends Ft{constructor(e,t){super(e,t,"GSUB")}getLookup(e){return super.getLookup(e,"GSUB")}}}),Pt=Object.freeze({__proto__:null,GPOS:class extends Ft{constructor(e,t){super(e,t,"GPOS")}getLookup(e){return super.getLookup(e,"GPOS")}}});class At extends m{constructor(e){super(e),this.numEntries=e.uint16,this.documentRecords=[...new Array(this.numEntries)].map((t=>new Vt(e)))}getDocument(e){let t=this.documentRecords[e];if(!t)return"";let n=this.start+t.svgDocOffset;return this.parser.currentPosition=n,this.parser.readBytes(t.svgDocLength)}getDocumentForGlyph(e){let t=this.documentRecords.findIndex((t=>t.startGlyphID<=e&&e<=t.endGlyphID));return-1===t?"":this.getDocument(t)}}class Vt{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.svgDocOffset=e.Offset32,this.svgDocLength=e.uint32}}var Tt=Object.freeze({__proto__:null,SVG:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.offsetToSVGDocumentList=n.Offset32,n.currentPosition=this.tableStart+this.offsetToSVGDocumentList,this.documentList=new At(n)}}});class Lt{constructor(e){this.tag=e.tag,this.minValue=e.fixed,this.defaultValue=e.fixed,this.maxValue=e.fixed,this.flags=e.flags(16),this.axisNameID=e.uint16}}class Nt{constructor(e,t,n){let r=e.currentPosition;this.subfamilyNameID=e.uint16,e.uint16,this.coordinates=[...new Array(t)].map((t=>e.fixed)),e.currentPosition-r(n.currentPosition=r,[...new Array(this.axisCount)].map((e=>new Lt(n))))));const o=r+this.axisCount*this.axisSize;v(this,"instances",(()=>{let e=[];for(let t=0;te.tag))}getAxis(e){return this.axes.find((t=>t.tag===e))}}}),Bt=Object.freeze({__proto__:null,cvt:class extends b{constructor(e,t){const{p:n}=super(e,t),r=e.length/2;v(this,"items",(()=>[...new Array(r)].map((e=>n.fword))))}}}),Gt=Object.freeze({__proto__:null,fpgm:class extends b{constructor(e,t){const{p:n}=super(e,t);v(this,"instructions",(()=>[...new Array(e.length)].map((e=>n.uint8))))}}});class Ht{constructor(e){this.rangeMaxPPEM=e.uint16,this.rangeGaspBehavior=e.uint16}}var Ut=Object.freeze({__proto__:null,gasp:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.numRanges=n.uint16,v(this,"gaspRanges",(()=>[...new Array(this.numRanges)].map((e=>new Ht(n)))))}}}),Wt=Object.freeze({__proto__:null,glyf:class extends b{constructor(e,t){super(e,t)}getGlyphData(e,t){return this.parser.currentPosition=this.tableStart+e,this.parser.readBytes(t)}}}),jt=Object.freeze({__proto__:null,loca:class extends b{constructor(e,t,n){const{p:r}=super(e,t),o=n.maxp.numGlyphs+1;0===n.head.indexToLocFormat?(this.x2=!0,v(this,"offsets",(()=>[...new Array(o)].map((e=>r.Offset16))))):v(this,"offsets",(()=>[...new Array(o)].map((e=>r.Offset32))))}getGlyphDataOffsetAndLength(e){let t=this.offsets[e]*this.x2?2:1;return{offset:t,length:(this.offsets[e+1]*this.x2?2:1)-t}}}}),qt=Object.freeze({__proto__:null,prep:class extends b{constructor(e,t){const{p:n}=super(e,t);v(this,"instructions",(()=>[...new Array(e.length)].map((e=>n.uint8))))}}}),Kt=Object.freeze({__proto__:null,CFF:class extends b{constructor(e,t){const{p:n}=super(e,t);v(this,"data",(()=>n.readBytes()))}}}),Yt=Object.freeze({__proto__:null,CFF2:class extends b{constructor(e,t){const{p:n}=super(e,t);v(this,"data",(()=>n.readBytes()))}}});class _t{constructor(e){this.glyphIndex=e.uint16,this.vertOriginY=e.int16}}var Zt=Object.freeze({__proto__:null,VORG:class extends b{constructor(e,t){const{p:n}=super(e,t);this.majorVersion=n.uint16,this.minorVersion=n.uint16,this.defaultVertOriginY=n.int16,this.numVertOriginYMetrics=n.uint16,v(this,"vertORiginYMetrics",(()=>[...new Array(this.numVertOriginYMetrics)].map((e=>new _t(n)))))}}});class Xt{constructor(e){this.indexSubTableArrayOffset=e.Offset32,this.indexTablesSize=e.uint32,this.numberofIndexSubTables=e.uint32,this.colorRef=e.uint32,this.hori=new Qt(e),this.vert=new Qt(e),this.startGlyphIndex=e.uint16,this.endGlyphIndex=e.uint16,this.ppemX=e.uint8,this.ppemY=e.uint8,this.bitDepth=e.uint8,this.flags=e.int8}}class Jt{constructor(e){this.hori=new Qt(e),this.vert=new Qt(e),this.ppemX=e.uint8,this.ppemY=e.uint8,this.substitutePpemX=e.uint8,this.substitutePpemY=e.uint8}}class Qt{constructor(e){this.ascender=e.int8,this.descender=e.int8,this.widthMax=e.uint8,this.caretSlopeNumerator=e.int8,this.caretSlopeDenominator=e.int8,this.caretOffset=e.int8,this.minOriginSB=e.int8,this.minAdvanceSB=e.int8,this.maxBeforeBL=e.int8,this.minAfterBL=e.int8,this.pad1=e.int8,this.pad2=e.int8}}class $t extends b{constructor(e,t,n){const{p:r}=super(e,t,n);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.numSizes=r.uint32,v(this,"bitMapSizes",(()=>[...new Array(this.numSizes)].map((e=>new Xt(r)))))}}var en=Object.freeze({__proto__:null,EBLC:$t});class tn extends b{constructor(e,t,n){const{p:r}=super(e,t,n);this.majorVersion=r.uint16,this.minorVersion=r.uint16}}var nn=Object.freeze({__proto__:null,EBDT:tn}),rn=Object.freeze({__proto__:null,EBSC:class extends b{constructor(e,t){const{p:n}=super(e,t);this.majorVersion=n.uint16,this.minorVersion=n.uint16,this.numSizes=n.uint32,v(this,"bitmapScales",(()=>[...new Array(this.numSizes)].map((e=>new Jt(n)))))}}}),on=Object.freeze({__proto__:null,CBLC:class extends $t{constructor(e,t){super(e,t,"CBLC")}}}),sn=Object.freeze({__proto__:null,CBDT:class extends tn{constructor(e,t){super(e,t,"CBDT")}}}),an=Object.freeze({__proto__:null,sbix:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.flags=n.flags(16),this.numStrikes=n.uint32,v(this,"strikeOffsets",(()=>[...new Array(this.numStrikes)].map((e=>n.Offset32))))}}});class ln{constructor(e){this.gID=e.uint16,this.firstLayerIndex=e.uint16,this.numLayers=e.uint16}}class un{constructor(e){this.gID=e.uint16,this.paletteIndex=e.uint16}}var cn=Object.freeze({__proto__:null,COLR:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.numBaseGlyphRecords=n.uint16,this.baseGlyphRecordsOffset=n.Offset32,this.layerRecordsOffset=n.Offset32,this.numLayerRecords=n.uint16}getBaseGlyphRecord(e){let t=this.tableStart+this.baseGlyphRecordsOffset;this.parser.currentPosition=t;let n=new ln(this.parser),r=n.gID,o=this.tableStart+this.layerRecordsOffset-6;this.parser.currentPosition=o;let i=new ln(this.parser),s=i.gID;if(r===e)return n;if(s===e)return i;for(;t!==o;){let n=t+(o-t)/12;this.parser.currentPosition=n;let r=new ln(this.parser),i=r.gID;if(i===e)return r;i>e?o=n:inew un(p)))}}});class dn{constructor(e){this.blue=e.uint8,this.green=e.uint8,this.red=e.uint8,this.alpha=e.uint8}}class hn{constructor(e,t){this.paletteTypes=[...new Array(t)].map((t=>e.uint32))}}class fn{constructor(e,t){this.paletteLabels=[...new Array(t)].map((t=>e.uint16))}}class gn{constructor(e,t){this.paletteEntryLabels=[...new Array(t)].map((t=>e.uint16))}}var pn=Object.freeze({__proto__:null,CPAL:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.numPaletteEntries=n.uint16;const r=this.numPalettes=n.uint16;this.numColorRecords=n.uint16,this.offsetFirstColorRecord=n.Offset32,this.colorRecordIndices=[...new Array(this.numPalettes)].map((e=>n.uint16)),v(this,"colorRecords",(()=>(n.currentPosition=this.tableStart+this.offsetFirstColorRecord,[...new Array(this.numColorRecords)].map((e=>new dn(n)))))),1===this.version&&(this.offsetPaletteTypeArray=n.Offset32,this.offsetPaletteLabelArray=n.Offset32,this.offsetPaletteEntryLabelArray=n.Offset32,v(this,"paletteTypeArray",(()=>(n.currentPosition=this.tableStart+this.offsetPaletteTypeArray,new hn(n,r)))),v(this,"paletteLabelArray",(()=>(n.currentPosition=this.tableStart+this.offsetPaletteLabelArray,new fn(n,r)))),v(this,"paletteEntryLabelArray",(()=>(n.currentPosition=this.tableStart+this.offsetPaletteEntryLabelArray,new gn(n,r)))))}}});class mn{constructor(e){this.format=e.uint32,this.length=e.uint32,this.offset=e.Offset32}}class bn{constructor(e){e.uint16,e.uint16,this.signatureLength=e.uint32,this.signature=e.readBytes(this.signatureLength)}}var vn=Object.freeze({__proto__:null,DSIG:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint32,this.numSignatures=n.uint16,this.flags=n.uint16,this.signatureRecords=[...new Array(this.numSignatures)].map((e=>new mn(n)))}getData(e){const t=this.signatureRecords[e];return this.parser.currentPosition=this.tableStart+t.offset,new bn(this.parser)}}});class wn{constructor(e,t){this.pixelSize=e.uint8,this.maxWidth=e.uint8,this.widths=e.readBytes(t)}}var yn=Object.freeze({__proto__:null,hdmx:class extends b{constructor(e,t,n){const{p:r}=super(e,t),o=n.hmtx.numGlyphs;this.version=r.uint16,this.numRecords=r.int16,this.sizeDeviceRecord=r.int32,this.records=[...new Array(numRecords)].map((e=>new wn(r,o)))}}});class Cn{constructor(e){this.version=e.uint16,this.length=e.uint16,this.coverage=e.flags(8),this.format=e.uint8,0===this.format&&(this.nPairs=e.uint16,this.searchRange=e.uint16,this.entrySelector=e.uint16,this.rangeShift=e.uint16,v(this,"pairs",(()=>[...new Array(this.nPairs)].map((t=>new xn(e)))))),2===this.format&&console.warn("Kern subtable format 2 is not supported: this parser currently only parses universal table data.")}get horizontal(){return this.coverage[0]}get minimum(){return this.coverage[1]}get crossstream(){return this.coverage[2]}get override(){return this.coverage[3]}}class xn{constructor(e){this.left=e.uint16,this.right=e.uint16,this.value=e.fword}}var Sn=Object.freeze({__proto__:null,kern:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.nTables=n.uint16,v(this,"tables",(()=>{let e=this.tableStart+4;const t=[];for(let r=0;r[...new Array(this.mergeClassCount)].map((e=>n.readBytes(this.mergeClassCount))))),console.warn("Full MERG parsing is currently not supported."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}}});class On{constructor(e,t){this.tableStart=e,this.parser=t,this.tag=t.tag,this.dataOffset=t.Offset32,this.dataLength=t.uint32}getData(){return this.parser.currentField=this.tableStart+this.dataOffset,this.parser.readBytes(this.dataLength)}}var In=Object.freeze({__proto__:null,meta:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint32,this.flags=n.uint32,n.uint32,this.dataMapsCount=n.uint32,this.dataMaps=[...new Array(this.dataMapsCount)].map((e=>new On(this.tableStart,n)))}}}),kn=Object.freeze({__proto__:null,PCLT:class extends b{constructor(e,t){super(e,t),console.warn("This font uses a PCLT table, which is currently not supported by this parser."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}}});class Mn{constructor(e){this.bCharSet=e.uint8,this.xRatio=e.uint8,this.yStartRatio=e.uint8,this.yEndRatio=e.uint8}}class Fn{constructor(e){this.recs=e.uint16,this.startsz=e.uint8,this.endsz=e.uint8,this.records=[...new Array(this.recs)].map((t=>new Dn(e)))}}class Dn{constructor(e){this.yPelHeight=e.uint16,this.yMax=e.int16,this.yMin=e.int16}}var Pn=Object.freeze({__proto__:null,VDMX:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.uint16,this.numRecs=n.uint16,this.numRatios=n.uint16,this.ratRanges=[...new Array(this.numRatios)].map((e=>new Mn(n))),this.offsets=[...new Array(this.numRatios)].map((e=>n.Offset16)),this.VDMXGroups=[...new Array(this.numRecs)].map((e=>new Fn(n)))}}}),An=Object.freeze({__proto__:null,vhea:class extends b{constructor(e,t){const{p:n}=super(e,t);this.version=n.fixed,this.ascent=this.vertTypoAscender=n.int16,this.descent=this.vertTypoDescender=n.int16,this.lineGap=this.vertTypoLineGap=n.int16,this.advanceHeightMax=n.int16,this.minTopSideBearing=n.int16,this.minBottomSideBearing=n.int16,this.yMaxExtent=n.int16,this.caretSlopeRise=n.int16,this.caretSlopeRun=n.int16,this.caretOffset=n.int16,this.reserved=n.int16,this.reserved=n.int16,this.reserved=n.int16,this.reserved=n.int16,this.metricDataFormat=n.int16,this.numOfLongVerMetrics=n.uint16,n.verifyLength()}}});class Vn{constructor(e,t){this.advanceHeight=e,this.topSideBearing=t}}var Tn=Object.freeze({__proto__:null,vmtx:class extends b{constructor(e,t,n){super(e,t);const r=n.vhea.numOfLongVerMetrics,o=n.maxp.numGlyphs,i=p.currentPosition;if(lazy(this,"vMetrics",(()=>(p.currentPosition=i,[...new Array(r)].map((e=>new Vn(p.uint16,p.int16)))))),r(p.currentPosition=e,[...new Array(o-r)].map((e=>p.int16)))))}}}});const Ln=["otf","ttf","woff","woff2"];function Nn(e,t="custom"){const n=new FormData;if(e?.fontFace){const r=[];e.fontFace.forEach(((o,i)=>{const s={...o};if(s.file){const e=Array.isArray(s.file)?s.file:[s.file],t=[];e.forEach(((e,r)=>{const o=`file-${i}-${r}`;n.append(o,e,e.name),t.push(o)})),s.src=1===t.length?t[0]:t}s.slug=e?.slug,s.source=t,r.push(s)})),n.append("variants",JSON.stringify(r)),n.append("source",t),n.append("slug",e?.slug)}return n}const zn=e=>s()({path:`/generatepress-font-library/v1/${e}`,method:"GET"}),Bn=(e,t={})=>s()({path:`/generatepress-font-library/v1/${e}`,method:"POST",...t});async function Gn(e){return new Promise(((t,n)=>{const r=new window.FileReader;r.readAsArrayBuffer(e),r.onload=()=>t(r.result),r.onerror=n}))}async function Hn(e){const t=new N("Uploaded Font");if("string"==typeof e)t.src=e;else{const n=await Gn(e);t.fromDataBuffer(n,e.name)}const n=(await new Promise((e=>t.onload=e))).detail.font,{name:r}=n.opentype.tables,o=r.get(16)||r.get(1),i=r.get(2).toLowerCase().includes("italic"),s=n.opentype.tables["OS/2"].usWeightClass||"normal",a=!!n.opentype.tables.fvar,l=a&&n.opentype.tables.fvar.axes.find((({tag:e})=>"wght"===e));return{file:e,fontFamily:o,fontStyle:i?"italic":"normal",fontWeight:(l?`${l.minValue} ${l.maxValue}`:null)||s,isVariable:a}}const Un=window.wp.primitives,Wn=(0,e.createElement)(Un.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,e.createElement)(Un.Path,{d:"M18.3 11.7c-.6-.6-1.4-.9-2.3-.9H6.7l2.9-3.3-1.1-1-4.5 5L8.5 16l1-1-2.7-2.7H16c.5 0 .9.2 1.3.5 1 1 1 3.4 1 4.5v.3h1.5v-.2c0-1.5 0-4.3-1.5-5.7z"}));function jn(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;t{var d;const[h,f]=(0,r.useState)(null),[g,p]=(0,r.useState)(n.cssVariable.replace("--gp-font--","")),[m,b]=(0,r.useState)(n.disabled),[v,w]=(0,r.useState)(null!==(d=n.alias)&&void 0!==d?d:""),[y,C]=(0,r.useState)(n.fallback||""),[x,S]=(0,r.useState)((()=>{var e;return null!==(e=(0,Kn.cloneDeep)(n.variants))&&void 0!==e?e:[]})),[E,R]=(0,r.useState)(n.fontDisplay||"auto"),O=v||n.name,I=(0,r.useMemo)((()=>Xn(v)),[v]),k=(0,r.useMemo)((()=>`--gp-font--${Xn(g)}`),[g]),M=(0,r.useMemo)((()=>y?`${v||O}, ${y}`:`${v||O}`),[v,y,O]),F=(0,r.useCallback)((async()=>{const e={data:{fontId:n.id}};try{await Bn("delete-font",e),s(!0),a({type:"success",message:(0,t.__)("Font deleted successfully.")}),i(null),f(null),c(!1)}catch(e){f({type:"error",message:(0,t.__)("Error deleting font. Please try again.","gp-premium")}),console.error(e.message)}}),[n,s,a,i,c]),D=(0,r.useCallback)((()=>{window.confirm((0,t.__)("Are you sure you want to delete this font and all its variants?","gp-premium"))&&F()}),[F]);return(0,r.useEffect)((()=>{const e={...n,disabled:m,fontDisplay:E,alias:v,variants:x,fallback:y,cssVariable:k};c(!(0,Kn.isEqual)(e,n))}),[m,v,x,E,y,c,n,k]),(0,e.createElement)("div",{className:"gp-font-library-edit"},!n&&(0,e.createElement)(o.Spinner,null),n&&(0,e.createElement)(e.Fragment,null,h&&(0,e.createElement)(o.Notice,{status:h.type,onRemove:()=>f(null)},h.message),(0,e.createElement)(o.Button,{className:"gp-font-library-edit__back",title:(0,t.__)("Go back to the font library","gp-premium"),variant:"tertiary",icon:Wn,onClick:()=>{if(u){if(window.confirm((0,t.__)("You have unsaved changes. Click OK to discard changes or cancel to keep editing the font.","gp-premium"))){const e=x.map((e=>({...e,deleteStatus:!1})));S(e),c(!1),i(null)}}else i(null)}},(0,t.__)("Back","gp-premium")),(0,e.createElement)("h3",null,(0,t.sprintf)(/* translators: Edit font family */ -(0,t.__)("Edit Font: %s","gp-premium"),O)),(0,e.createElement)(Yn.Stack,{gap:"30px"},(0,e.createElement)("div",{className:"gp-font-library-edit__control"},(0,e.createElement)("strong",null,(0,t.__)("Font Status","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("If a font is disabled, no font variants are added to the frontend of your site.","gp-premium")),(0,e.createElement)(o.ToggleControl,{checked:!m,label:m?(0,t.__)("Disabled","gp-premium"):(0,t.__)("Enabled","gp-premium"),onChange:e=>{b(!e)}})),(0,e.createElement)("div",{className:"gp-font-library-edit__control"},(0,e.createElement)("strong",null,(0,t.__)("Available Font Variants","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("Enable or disable individual font variants on the frontend of your site.","gp-premium")),(0,e.createElement)("ul",{className:"gp-font-library-edit__variants",style:{opacity:m?"0.5":"1"},role:"list"},x&&(0,e.createElement)(e.Fragment,null,x?.map((({name:n,src:r,disabled:i=!1,deleteStatus:s=!1},a)=>(0,e.createElement)("li",{key:r,className:qn("gp-font-library-edit__variant",s&&"gp-font-library-edit__variant--delete")},(0,e.createElement)(o.CheckboxControl,{className:s?"delete-variant":"",disabled:m||s,label:n,checked:!i,onChange:e=>{const t=[...x];t[a].disabled=!e,S(t),t.every((e=>e.disabled))&&b(!0)},__nextHasNoMarginBottom:!0}),(0,e.createElement)(o.Button,{size:"compact",title:s?(0,t.__)("Undelete font variant","gp-premium"):(0,t.__)("Delete font variant","gp-premium"),onClick:()=>{const e=[...x];e[a].deleteStatus=!s,S(e)}},(0,e.createElement)(o.Icon,{size:"18",color:"#cc1818",icon:Zn("trash")}))))))))),(0,e.createElement)("details",{className:"gp-font-library-edit__advanced"},(0,e.createElement)("summary",null,(0,t.__)("Advanced Options","gp-premium")," "),(0,e.createElement)(Yn.Stack,{gap:"30px"},(0,e.createElement)("div",{className:"gp-font-library-edit__control"},(0,e.createElement)("strong",null,(0,t.__)("Font Display")),(0,e.createElement)("p",{className:"gp-font-library__text"},(0,t.__)("Specify the font-display value, used in the @font-face CSS. This value determines how your text displays as the webfont loads.","gp-premium")),(0,e.createElement)(o.SelectControl,{className:"gp-font-library-edit__control",value:E,options:[{label:"Auto",value:"auto"},{label:"Block",value:"block"},{label:"Fallback",value:"fallback"},{label:"Optional",value:"optional"},{label:"Swap",value:"swap"}],onChange:e=>{R(e)}})),(0,e.createElement)("div",{className:"gp-font-library-edit__control"},(0,e.createElement)("strong",null,(0,t.__)("Font Alias")),(0,e.createElement)("p",{className:"gp-font-library__text"},(0,t.__)("Specify an alias for this font that will be used as the font family name in CSS. If left blank the default font family name will be used.","gp-premium")),(0,e.createElement)(o.TextControl,{className:"gp-font-library-edit__control",label:(0,t.__)("Add Font Family Alias","gp-premium"),placeholder:(0,t.sprintf)(/* translators: Font family alias */ -(0,t.__)("e.g. Custom %s","gp-premium"),O),value:v,onChange:w,help:`${k}: ${M};`})),(0,e.createElement)("div",{className:"gp-font-library-edit__control"},(0,e.createElement)("strong",null,(0,t.__)("Font Family Fallback")),(0,e.createElement)("p",{className:"gp-font-library__text"},(0,t.__)("Enter the CSS font-family fallback value you want to use for this font here. This appears after the font family name in the CSS.","gp-premium")),(0,e.createElement)(o.TextControl,{className:"gp-font-library-edit__control",label:(0,t.__)("Font Family","gp-premium"),placeholder:(0,t.__)("sans-serif, system-ui","gp-premium"),value:y,onChange:C,help:`font-family: ${M};`})),(0,e.createElement)("div",{className:"gp-font-library-edit__control"},(0,e.createElement)("strong",null,(0,t.__)("CSS Variable Suffix")),(0,e.createElement)("p",{className:"gp-font-library__text"},(0,t.__)("You may customize the CSS variable suffix for your font if you wish to change it.","gp-premium")),(0,e.createElement)(o.TextControl,{className:"gp-font-library-edit__control",label:(0,t.__)("CSS Variable suffix","gp-premium"),placeholder:I||n.slug,value:g,onChange:p,help:(0,e.createElement)(e.Fragment,null,`font-family: var(${k});`,25===g.length&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("br",null),(0,e.createElement)("strong",null,(0,t.__)("Max 25 characters","gp-premium")))),minLength:"1",maxLength:"25",max:"25"})),0===g.length&&(0,e.createElement)(o.Notice,{status:"warning",isDismissible:!1,className:"gp-font-library-edit__control-notice"},(0,t.__)("CSS Variable suffix cannot be empty. Please enter a valid suffix.","gp-premium")))),k!==n.cssVariable&&(0,e.createElement)(o.Notice,{status:"warning",isDismissible:!1},(0,t.__)("If you have used this font's css variable, changing the variable suffix may cause loss of visual styles.","gp-premium")),(0,e.createElement)(o.Flex,{className:"gp-font-library-edit__footer",alignItems:"center",gap:"20px",justifyContent:"flex-start"},(0,e.createElement)(o.FlexItem,null,(0,e.createElement)(o.Button,{title:(0,t.__)("Delete font and all its variants","gp-premium"),isDestructive:!0,size:"compact",variant:"primary",onClick:D},(0,t.__)("Delete","gp-premium"))),u&&(0,e.createElement)(o.FlexItem,null,(0,e.createElement)(o.Button,{title:(0,t.__)("Save font changes","gp-premium"),size:"compact",variant:"primary",onClick:async()=>{let e=m?"draft":"publish";Array.isArray(x)&&x?.every((({disabled:e})=>e))&&(e="draft");const r=[],o=[];if(x.forEach((e=>{e.deleteStatus?o.push(e):r.push({...e,deleteStatus:!1})})),0===r.length)if(window.confirm((0,t.__)("You've selected to delete ALL variants. This will also delete the font from the library. Click OK to proceed, or Cancel to undelete variants.","gp-premium")))F();else{const e=x.map((e=>({...e,deleteStatus:!1})));S(e)}else{const a={data:{newVariants:r,deleteVariants:o,fontDisplay:E,fallback:y,alias:v,cssVariable:k,status:e,id:n.id}};await Bn("update-font-post",a),s(!0),l({type:"success",message:(0,t.__)("Font changes saved.")}),c(!1),i(null)}}},(0,t.__)("Save","gp-premium"))))))},Qn=(0,e.createElement)(Un.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,e.createElement)(Un.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"})),$n=(0,r.memo)((function({font:n,loading:r="lazy",fallbackText:i=""}){const{preview:s,fontFamily:a,name:l,alias:u}=n;return(0,e.createElement)("div",{className:"gp-font-library-preview"},s?(0,e.createElement)(e.Fragment,null,(0,e.createElement)("img",{className:"gp-font-library-preview__image",src:s,alt:(0,t.__)("A graphical rendering of the font family","gp-premium"),height:"23",loading:r}),(0,e.createElement)(o.VisuallyHidden,null,i||l)):(0,e.createElement)("span",{className:"gp-font-library-preview__fallback",style:{fontFamily:a}},l," ",u&&`(${u})`))})),er=(0,r.memo)((function({font:n,onClick:i,category:s=""}){const a=(0,r.useMemo)((()=>function({variants:e=[],fontFace:t=[]}){var n;let r=0;const o=e.length>0?e:t,i=null!==(n=o?.length)&&void 0!==n?n:0;return o.forEach((({disabled:e=!1})=>{e||r++})),{total:i,enabled:r}}(n)),[n]);return(0,e.createElement)(o.Button,{className:"gp-font-library-card",type:"button",onClick:i},(0,e.createElement)($n,{font:n}),s&&(0,e.createElement)("span",{className:"gp-font-library-card__categories"},s),(0,e.createElement)("div",{className:"gp-font-library-card__variants"},a.total===a.enabled?(0,t.sprintf)(/* translators: %d: Total number of font variants. */ -(0,t._n)("%d variant","%d variants",a.total,"gp-premium"),a.total):(0,t.sprintf)(/* translators: %s: Number of enabled font variants. */ -(0,t.__)("%s variants","gp-premium"),`${a.enabled}/${a.total}`),(0,e.createElement)(o.Icon,{icon:Qn})))}));function tr({fonts:n,setUpdateFontList:i,unsavedChanges:s,setUnsavedChanges:a,editFont:l,setEditFont:u}){const[c,d]=(0,r.useState)(null),[h,f]=(0,r.useState)(null);return(0,r.useEffect)((()=>{if(n)return document.head.appendChild(function(e){const t=document.getElementById("gp-custom-font-style");t&&t.parentNode.removeChild(t);const n=document.createElement("style");n.id="gp-custom-font-style";let r="";return e.forEach((e=>{const{name:t="",alias:n="",variants:o=[],fontDisplay:i="auto",preview:s=""}=e;if(s)return null;const a=n||t;o&&o.length>0&&o.filter((e=>!e.disabled)).forEach((e=>{r+=`@font-face {\n\tfont-display: ${i};\n\tfont-family: '${a}';\n\tfont-style: ${e.fontStyle};\n\tfont-weight: ${e.fontWeight};\n\tsrc: url('${e.src}')${(e=>{const t={woff:"woff",woff2:"woff2",ttf:"truetype",otf:"opentype"}[e.split(".").pop()]||null;return t?` format('${t}')`:""})(e.src)};\n}\n`}))})),n.textContent=r,n}(n?.response)),()=>{const e=document.getElementById("gp-custom-font-style");e&&document.head.removeChild(e)}}),[n]),(0,r.useEffect)((()=>{l&&(d(null),f(null))}),[l]),l?(0,e.createElement)(Jn,{editFont:l,setEditFont:u,setUpdateFontList:i,setDeleteNotice:d,setSaveNotice:f,unsavedChanges:s,setUnsavedChanges:a}):(0,e.createElement)("div",{className:"gp-font-library__tab"},(0,e.createElement)("div",{className:"gp-font-library__notices"},c&&(0,e.createElement)("div",{style:{margin:"0 0 20px 0"}},(0,e.createElement)(o.Notice,{status:c.type,onRemove:()=>d(null)},c.message)),h&&(0,e.createElement)("div",{style:{margin:"0 0 20px 0"}},(0,e.createElement)(o.Notice,{status:h.type,onRemove:()=>f(null)},h.message))),(0,e.createElement)("h2",null,(0,t.__)("Installed Fonts","gp-premium")),n?(0,e.createElement)("div",null,0===n?.response.length&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("p",null,(0,t.__)("No fonts have been installed yet.","gp-premium")),(0,e.createElement)("div",{style:{display:"flex",gap:"10px"}},(0,e.createElement)(o.Button,{variant:"primary",onClick:()=>{const e=document.querySelector(".gp-font-library__google-fonts");e&&e.click()}},(0,t.__)("Install Google Fonts","gp-premium")),(0,e.createElement)(o.Button,{variant:"primary",onClick:()=>{const e=document.querySelector(".gp-font-library__upload");e&&e.click()}},(0,t.__)("Upload Custom Fonts","gp-premium")))),n?.response.length>0&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{style:{marginBottom:"30px",__marginTop:"-20px"}},(0,t.__)("Installed and enabled fonts are automatically available on the frontend of your site."))),n?.response.length>0&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("ul",{style:{marginBottom:"25px"},className:"gp-font-library__list",role:"list"},n.response.map((t=>(0,e.createElement)("li",{key:t.id},(0,e.createElement)(er,{font:t,onClick:()=>u(t),loading:"eager"}))))))):(0,e.createElement)(o.Spinner,null))}const nr=(0,e.createElement)(Un.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,e.createElement)(Un.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"})),rr=window.wp.compose,or=[{value:"latin",label:"Latin"},{value:"latin-ext",label:"Latin Extended"},{value:"bengali",label:"Bengali"},{value:"chinese-hongkong",label:"Chinese (Hong Kong)"},{value:"chinese-simplified",label:"Chinese (Simplified)"},{value:"chinese-traditional",label:"Chinese (Traditional)"},{value:"cyrillic",label:"Cyrillic"},{value:"cyrillic-ext",label:"Cyrillic Extended"},{value:"devanagari",label:"Devanagari"},{value:"greek",label:"Greek"},{value:"greek-ext",label:"Greek Extended"},{value:"gujarati",label:"Gujarati"},{value:"gurmukhi",label:"Gurmukhi"},{value:"hebrew",label:"Hebrew"},{value:"japanese",label:"Japanese"},{value:"kannada",label:"Kannada"},{value:"khmer",label:"Khmer"},{value:"korean",label:"Korean"},{value:"malayalam",label:"Malayalam"},{value:"math",label:"Math"},{value:"myanmar",label:"Myanmar"},{value:"oriya",label:"Oriya"},{value:"sinhala",label:"Sinhala"},{value:"symbols",label:"Symbols"},{value:"tamil",label:"Tamil"},{value:"telugu",label:"Telugu"},{value:"thai",label:"Thai"},{value:"tibetan",label:"Tibetan"},{value:"vietnamese",label:"Vietnamese"}];function ir({settings:n,setSettings:i,setUpdateFontList:s,googleFonts:a}){var l;const[u,c]=(0,r.useState)(5),[d,h]=(0,r.useState)(n?.preferred_subset?n.preferred_subset[0]:"latin"),[f,g]=(0,r.useState)(!1),[p,m]=(0,r.useState)(!1),[b,v]=(0,r.useState)(null),[w,y]=(0,r.useState)([]),[C,x]=(0,r.useState)(1),[S,E]=(0,r.useState)({}),[R,O]=(0,r.useState)(null),I=(0,r.useRef)(),k=null!==(l=n?.google_gdpr)&&void 0!==l&&l,M=(0,r.useMemo)((()=>{var e;return null!==(e=b?.font_family_settings?.fontFace)&&void 0!==e?e:[]}),[b]),F=(0,r.useMemo)((()=>function(e,t){const{category:n,search:r}=t;let o=e||[];return n&&"all"!==n&&(o=o.filter((e=>-1!==e.categories.indexOf(n)))),r&&(o=o.filter((e=>e.font_family_settings.name.toLowerCase().includes(r.toLowerCase())))),o}(a,S)),[a,S]),D=(0,r.useMemo)((()=>F.slice((C-1)*u,C*u)),[F,C,u]),P=(0,r.useMemo)((()=>Array.from({length:Math.ceil(F.length/u)},((e,t)=>({label:t+1,value:t+1})))),[F,u]),A=(0,r.useMemo)((()=>Object.values(S).length>0),[S]);function V(){E({}),x(1)}const T=(0,rr.debounce)((function(e){E({...S,search:e}),x(1)}),300),L=(0,r.useCallback)((async(e=!1)=>{try{const t=await Bn("set-settings",{data:{settings:{...n,google_gdpr:e}}});if(!t.success)throw new Error(t.response);i({...n,google_gdpr:e})}catch(e){console.error(e),O({type:"error",message:(0,t.__)("An error occurred while updating settings.","gp-premium")})}}),[n,i]),N=(0,r.useCallback)((async(e="")=>{try{const t=await Bn("set-settings",{data:{settings:{...n,preferred_subset:e}}});if(!t.success)throw new Error(t.response.message);i({...n,preferred_subset:e})}catch(e){console.error(e),O({type:"error",message:(0,t.__)("An error occurred while updating settings.","gp-premium")})}}),[n,i]);return(0,r.useEffect)((()=>{I.current?I.current.scrollIntoView({behavior:"smooth"}):window.scrollTo(0,0)}),[C]),(0,e.createElement)(e.Fragment,null,R&&(0,e.createElement)(o.Notice,{className:"gp-font-library__notice",isDismissible:!0,status:R.type,onRemove:()=>O(null)},R.message),k?(0,e.createElement)("section",{ref:I},b?(0,e.createElement)("div",{className:"gp-font-library__select-variants"},(0,e.createElement)(o.Button,{onClick:()=>{v(null),O(null)},icon:nr},b.font_family_settings.name),(0,e.createElement)("h3",null,(0,t.__)("Install variants","gp-premium")),(0,e.createElement)("p",{className:"gp-font-library__text"},(0,t.__)("Select the font variants you want to install. GeneratePress will install the most optimal version of the font available. If the font has a variable version, that will be used automatically.","gp-premium")),(0,e.createElement)("ul",{role:"list",className:"gp-font-library__list"},M.map((t=>{const n=`variant-${t.fontWeight}-${t.fontStyle}`;return(0,e.createElement)("li",{className:"gp-font-library-card",key:n},(0,e.createElement)(o.CheckboxControl,{checked:w.includes(t),id:n,onChange:e=>{y(e?[...w,t]:w.filter((e=>e!==t)))},__nextHasNoMarginBottom:!0}),(0,e.createElement)("label",{htmlFor:n},(0,e.createElement)($n,{font:t,loading:"eager",fallbackText:t.fontFamily})))}))),(0,e.createElement)("footer",{className:"gp-font-library-google__footer"},(0,e.createElement)(o.Button,{isBusy:p,variant:"primary",disabled:0===w.length,onClick:async()=>{try{m(!0);let e=w;const n=await Bn("optimize-google-fonts",{data:{font:b.font_family_settings,variants:w}});if(n.success){e=n.response;const t=e.map((e=>e.src));if(t.every((e=>t[0]===e))){const{fontWeight:t,isVariable:n,fontStyle:r}=await Hn(e[0].src);e=[{...e[0],fontWeight:t,isVariable:n,fontStyle:r}],document.querySelectorAll(".injected-by-Font-js").forEach((e=>e.remove()))}}const r=await Bn("upload-fonts",{data:{font:b.font_family_settings,variants:e}});if(!r.success)throw new Error(r.response);s(!0),V(),y([]),O({type:"success",message:(0,t.__)("Fonts were installed successfully.","gp-premium")})}catch(e){s(!1),O({type:"error",message:(0,t.__)("An error occurred while downloading the variants.","gp-premium")}),console.error(e.message)}m(!1)}},(0,t.__)("Install Selected","gp-premium")),p&&(0,e.createElement)("span",null,(0,t.__)("Downloading…","gp-premium")," "))):(0,e.createElement)(e.Fragment,null,(0,e.createElement)("header",{className:"gp-font-library-google__header"},(0,e.createElement)("div",{className:"gp-font-library-google__header-content"},(0,e.createElement)("h2",null,(0,t.__)("Google Fonts","gp-premium")),(0,e.createElement)("p",{className:"gp-font-library-google__description"},(0,t.__)("Install fonts from Google Fonts. Fonts are installed locally on your site.","gp-premium"))),(0,e.createElement)(o.Button,{variant:"link",onClick:()=>g(!0)},(0,t.__)("Settings","gp-premium")),f&&(0,e.createElement)(o.Modal,{title:(0,t.__)("Settings","gp-premium"),onRequestClose:()=>g(!1),className:"gp-font-library-settings"},(0,e.createElement)(Yn.Stack,{className:"gp-font-library-settings__controls",gap:"20px"},(0,e.createElement)(o.SelectControl,{value:d,options:or,label:(0,t.__)("Preferred Subset","gp-premium"),onChange:e=>{h(e)},help:(0,t.__)("Choose which character subset you want to download if available.","gp-premium")}),(0,e.createElement)(o.Button,{variant:"primary",onClick:()=>{N(d||"latin"),O({type:"success",message:(0,t.__)("Preferred subset updated.","gp-premium")}),g(!1)},size:"compact"},(0,t.__)("Save Settings","gp-premium"))),(0,e.createElement)("h3",null,(0,t.__)("Revoke access to Google Fonts","gp-premium")),(0,e.createElement)("div",{className:"gp-font-library-settings__auth"},(0,e.createElement)("p",{id:"google-fonts-revoke-access-description"},(0,t.__)("This will remove the connection to Google Fonts and you will not be able to install new fonts from Google Fonts. Previously installed fonts will NOT be deleted.","gp-premium")),(0,e.createElement)(o.Button,{isDestructive:!0,variant:"primary",size:"compact","aria-describedby":"google-fonts-revoke-access-description",onClick:()=>{L(!1),O({type:"success",message:(0,t.__)("Google fonts access has been revoked.","gp-premium")}),g(!1)}},(0,t.__)("Revoke access","gp-premium"))))),(0,e.createElement)("div",{className:"gp-font-library-google__filters"},(0,e.createElement)(o.SearchControl,{label:(0,t.__)("Search","gp-premium"),value:S.search,onChange:T,__nextHasNoMarginBottom:!0,placeholder:(0,t.__)("Font name…","gp-premium"),hideLabelFromVision:!1}),(0,e.createElement)(o.SelectControl,{label:(0,t.__)("Category","gp-premium"),value:S.category,onChange:e=>E({...S,category:e}),options:[{label:(0,t.__)("All","gp-premium"),value:""},{label:(0,t.__)("Serif","gp-premium"),value:"serif"},{label:(0,t.__)("Sans Serif","gp-premium"),value:"sans-serif"},{label:(0,t.__)("Display","gp-premium"),value:"display"},{label:(0,t.__)("Handwriting","gp-premium"),value:"handwriting"},{label:(0,t.__)("Monospace","gp-premium"),value:"monospace"}],__nextHasNoMarginBottom:!0})),(0,e.createElement)("p",{className:"gp-font-library-google__results"},F.length>0?(0,e.createElement)(e.Fragment,null,(0,e.createElement)("span",null,(0,t.sprintf)(/* translators: %d: Total number of matching fonts. */ -(0,t._n)("%d matching font","%d matching fonts",F.length,"gp-premium"),F.length)),F.length!==a.length&&(0,e.createElement)("span",null,"( ",(0,t.sprintf)(/* translators: %d: Total number of fonts. */ -"%d total",a.length)," )"),A&&(0,e.createElement)(o.Button,{onClick:V,variant:"link"},(0,t.__)("Reset","gp-premium"))):(0,e.createElement)("span",null,(0,t.__)("No matching fonts found.","gp-premium"))),(0,e.createElement)("ul",{role:"list",className:"gp-font-library__list"},D.map((t=>{var n;const r=null!==(n=t.font_family_settings)&&void 0!==n?n:{};return(0,e.createElement)("li",{key:r.slug},(0,e.createElement)(er,{font:r,onClick:()=>v(t),category:t.categories[0]}))}))),(0,e.createElement)("nav",{className:"gp-font-library-google__pagination","aria-label":(0,t.__)("Font list pagination","gp-premium")},(0,e.createElement)("div",{className:"gp-font-library-google__pagination-numbers"},(0,e.createElement)(o.Button,{disabled:1===C,onClick:()=>x(C-1)},(0,t.__)("Previous","gp-premium")),(0,e.createElement)(o.SelectControl,{label:(0,t.__)("Choose Page","gp-premium"),value:C,onChange:e=>x(parseInt(e,10)),options:P,hideLabelFromVision:!0,__nextHasNoMarginBottom:!0}),(0,e.createElement)(o.Button,{disabled:D.lengthx(C+1)},(0,t.__)("Next","gp-premium"))),(0,e.createElement)(o.SelectControl,{label:(0,t.__)("Per Page","gp-premium"),value:S.category,onChange:e=>c(e),options:[{label:(0,t.__)("5","gp-premium"),value:5},{label:(0,t.__)("10","gp-premium"),value:10},{label:(0,t.__)("15","gp-premium"),value:15},{label:(0,t.__)("20","gp-premium"),value:20}],style:{width:"100px"},__nextHasNoMarginBottom:!0})))):(0,e.createElement)("div",{className:"gp-font-library-authorize-fonts"},(0,e.createElement)("h3",null,(0,t.__)("Connect to Google Fonts?","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("To install fonts from Google you must give permission to connect directly to Google servers. The fonts you install will be downloaded from Google and stored on your site. Your site will then use these locally-hosted fonts.","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("You can alternatively upload fonts directly on the Upload Custom Fonts tab.","gp-premium")),(0,e.createElement)(o.Button,{variant:"primary",onClick:()=>{L(!0)}},(0,t.__)("Allow access to Google Fonts","gp-premium"))))}const sr=(0,r.forwardRef)((function({icon:e,size:t=24,...n},o){return(0,r.cloneElement)(e,{width:t,height:t,...n,ref:o})})),ar=(0,e.createElement)(Un.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,e.createElement)(Un.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})),lr=(0,e.createElement)(Un.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,e.createElement)(Un.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"})),ur=/([\p{Ll}\d])(\p{Lu})/gu,cr=/(\p{Lu})([\p{Lu}][\p{Ll}])/gu,dr=/(\d)\p{Ll}|(\p{L})\d/u,hr=/[^\p{L}\d]+/giu,fr="$1\0$2",gr="";function pr(e){let t=e.trim();t=t.replace(ur,fr).replace(cr,fr),t=t.replace(hr,"\0");let n=0,r=t.length;for(;"\0"===t.charAt(n);)n++;if(n===r)return[];for(;"\0"===t.charAt(r-1);)r--;return t.slice(n,r).split(/\0/g)}function mr(e){const t=pr(e);for(let e=0;ei;){const t=s-1,n=e.charAt(t);if(!o.includes(n))break;s=t}return[e.slice(0,i),n(e.slice(i,s)),e.slice(s)]}(e,t);return n+r.map((i=t?.locale,!1===i?e=>e.toLowerCase():e=>e.toLocaleLowerCase(i))).join(t?.delimiter??" ")+o;var i}const vr=Ln.map((e=>`.${e}`)).join(","),wr=({setUpdateFontList:n})=>{const[i,s]=(0,r.useState)([]),[a,l]=(0,r.useState)(!1),u=(0,r.useCallback)((async r=>{try{const n=await async function(e){return await Promise.all(e.map((async e=>await Hn(e))))}(r),o=await async function(e){const t=[];for(const n of e){const{name:e}=n;try{const r=await Bn("upload-fonts",{body:Nn(n)});t.push({status:"fulfilled",value:{...r.response,name:e}})}catch(n){t.push({status:"rejected",value:{message:n.message,name:e}})}}const n={errors:[],successes:[]};return t.forEach((e=>{const t=e.value;"fulfilled"===e.status&&t.ID?n.successes.push(t):n.errors.push(t)})),n}(function(e){const t=e.reduce(((e,t)=>{var n;return e[t.fontFamily]||(e[t.fontFamily]={name:t.fontFamily,fontFamily:t.fontFamily,slug:(n=t.fontFamily.toLowerCase(),br(n,{delimiter:"-"})),fontFace:[]}),e[t.fontFamily].fontFace.push(t),e}),{});return Object.values(t)}(n)),i=o.errors.length>0,a=o.successes.length>0;let l=(0,t.__)("All fonts were uploaded successfully.");i&&a?l=(0,t.__)("Some fonts failed to upload.","gp-premium"):i&&!a&&(l=(0,t.__)("All fonts failed to upload.","gp-premium")),s((n=>[...n,{type:"info",message:(0,e.createElement)(e.Fragment,null,l,(0,e.createElement)("ul",{className:"gp-font-library__results"},o.successes.map((n=>(0,e.createElement)("li",{className:"gp-font-library__result gp-font-library__result--success",key:n.fontFamily},(0,e.createElement)(sr,{icon:ar,size:"1.25em"}),(0,t.sprintf)( -// translators: %s: font family name -(0,t.__)("%s installed.","gp-premium"),n.name)))),o.errors.map((n=>(0,e.createElement)("li",{className:"gp-font-library__result gp-font-library__result--failure",key:n.fontFamily},(0,e.createElement)(sr,{icon:lr,size:"1.25em"}),(0,t.sprintf)( -// translators: %s: font family name -(0,t.__)("%s install failed.","gp-premium"),n.name))))))}]))}catch(e){s((e=>[...e,{type:"error",message:(0,t.__)("There was an error installing fonts.")}])),console.error(e.message)}n(!0),l(!1)}),[n,l,s]),c=(0,r.useCallback)((async n=>{l(!0),s([]);const r=new Set,o=[...n];let i=!1;const a=o.map((async n=>{const o=await async function(e){const t=new N("Uploaded Font");try{const n=await Gn(e);return await t.fromDataBuffer(n,"font"),!0}catch(e){return console.error("Error: ",e),!1}}(n);if(!o)return i=!0,s([{type:"error",message:(0,e.createElement)(e.Fragment,null,(0,t.__)("Invalid or corrupted font file: ","gp-premium")," ",`${n.name}`)}]),null;if(r.has(n.name))return null;const a=n.name.split(".").pop().toLowerCase();return Ln.includes(a)?(r.add(n.name),n):null})),c=(await Promise.all(a)).filter((e=>null!==e));if(c.length>0)u(c);else{const e=i?(0,t.__)("Sorry, you are not allowed to upload this file type."):(0,t.__)("No fonts found to install.");console.error("Error: ",e),l(!1)}}),[u,l,s]);return(0,e.createElement)(e.Fragment,null,i&&(0,e.createElement)("div",{style:{margin:"0 0 20px 0"}},(0,e.createElement)(Yn.Stack,{gap:"20px"},i.map(((t,n)=>(0,e.createElement)(o.Notice,{key:`${t.type}-${n}`,status:t.type,onRemove:()=>s(i.toSpliced(n,1))},t.message))))),(0,e.createElement)("h2",null,(0,t.__)("Upload Fonts","gp-premium")),(0,e.createElement)("div",{style:{position:"relative"},className:"gp-font-library-upload"},(0,e.createElement)(o.DropZone,{onFilesDrop:function(e){c(e)}}),(0,e.createElement)("div",{className:"gp-font-library-modal__local-fonts"},(0,e.createElement)(o.FormFileUpload,{accept:vr,multiple:!0,onChange:function(e){c(e.target.files)},render:({openFileDialog:n})=>(0,e.createElement)(o.Button,{style:{background:"#f0f0f0",alignItems:"center",display:"flex",height:"256px",justifyContent:"center",width:"100%"},className:"gp-font-library-modal__upload-area",onClick:n},a&&(0,e.createElement)(o.Spinner,null),!a&&(0,t.__)("Click to upload"))}))),(0,e.createElement)("p",{style:{margin:"25px 0"}},(0,t.__)("Upload one or more fonts. Once uploaded, they will appear via the Font Library tab above. Supported formats are: .ttf, .otf, .woff, and .woff2.","gp-premium")))},yr=(t,n)=>(0,e.createElement)("div",{className:"gp-tab-header",id:n},t),Cr=async({setFonts:e,updateFontList:t,setUpdateFontList:n})=>{const r=await zn("get-fonts");e({success:r.success,response:r.response}),t&&n(!1)};var xr,Sr;xr=(0,e.createElement)((()=>{const[n,i]=(0,r.useState)(null),[a,l]=(0,r.useState)(!1),[u,c]=(0,r.useState)({google_gdpr:!1}),[d,h]=(0,r.useState)(!1),[f,g]=(0,r.useState)(null),[p,m]=(0,r.useState)("library-font"),[b,v]=(0,r.useState)([]),w=(0,r.useMemo)((()=>[{disabled:d,name:"library-font",title:yr((0,t.__)("Font Library","gp-premium"),"library_font_hd"),content:(0,e.createElement)(tr,{fonts:n,editFont:f,setEditFont:g,unsavedChanges:d,setUnsavedChanges:h,setUpdateFontList:l}),className:"gp-font-library__fonts"},{disabled:d,name:"upload-font",title:yr((0,t.__)("Upload Custom Fonts","gp-premium"),"upload_font_hd"),content:(0,e.createElement)(wr,{setFonts:i,setUpdateFontList:l}),className:"gp-font-library__upload"},{disabled:d,name:"google-font",title:yr((0,t.__)("Install Google Fonts","gp-premium"),"google_font_hd"),content:(0,e.createElement)(ir,{settings:u,setSettings:c,setUpdateFontList:l,googleFonts:b}),className:"gp-font-library__google-fonts"}]),[n,f,d,h,i,l,u,c,b]),y=(0,r.useCallback)((e=>{"library-font"===e||d||g(null),m(e)}),[d]);return(0,r.useEffect)((()=>{0===b.length&&"google-font"===p&&async function({setGoogleFonts:e,setNotice:n}){try{var r;const t=await async function(e="google-fonts"){const t={path:`/wp/v2/font-collections/${e}`,method:"GET"};return await s()(t)}("google-fonts"),n=null!==(r=t?.font_families)&&void 0!==r?r:[];if(!n)throw new Error(t);e(n)}catch(e){n({type:"error",message:(0,t.__)("An error occurred while fetching Google Fonts.","gp-premium")}),console.error(e.message)}}({setGoogleFonts:v})}),[p,b.length,v]),(0,r.useEffect)((()=>{a&&Cr({updateFontList:a,setUpdateFontList:l,setFonts:i}).catch((e=>console.error("Error:",e)))}),[a]),(0,r.useEffect)((()=>{Cr({updateFontList:a,setUpdateFontList:l,setFonts:i}),(async()=>{try{var e;const t=await zn("get-settings");c(null!==(e=t?.response)&&void 0!==e&&e)}catch(e){console.error(e.message)}})()}),[]),(0,e.createElement)(e.Fragment,null,(0,e.createElement)(o.TabPanel,{onSelect:y,className:"gp-font-tab-panel",activeClass:"active-tab",orientation:"horizontal",initialTabName:p,tabs:w},(e=>e.content)))}),null),Sr=document.getElementById("gp-font-library"),void 0!==r.createRoot?(0,r.createRoot)(Sr).render(xr):(0,r.render)(xr,Sr)})()})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages-rtl.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages-rtl.css deleted file mode 100644 index b69e48bd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages-rtl.css +++ /dev/null @@ -1,2 +0,0 @@ -.mnc9nIWbe_UvWqh_EGSg{position:relative;width:100%}.lvIdqq0VcOc4Fsgp6edt{display:flex;gap:0 4px}.JQD57VZha1Nz_puhbEGL{flex-grow:1;position:relative}.uPu9muJa3zAmugfyIwKm[type=text]{appearance:none;border-color:#8c8f94;border-radius:3px;box-shadow:none;color:#2c3338;cursor:pointer;font-size:16px;line-height:2;min-height:30px;min-width:0;padding:0 8px 0 24px;vertical-align:middle;width:100%}@media(min-width:600px){.uPu9muJa3zAmugfyIwKm[type=text]{font-size:13px}}.uPu9muJa3zAmugfyIwKm[type=text].WNS5v6eZssWgR0abiuiV{outline-offset:2px}.uPu9muJa3zAmugfyIwKm[type=text].MgYZFTRJHzGT5kJMx1EN{padding-left:44px}.BI9El7N6XuVkzJ0yYqjN{display:block;height:12px;width:12px}.FIMlw2_F2weKvrhreh8G{background:#0000;border:none;box-shadow:none;height:100%;left:0;top:0}.FIMlw2_F2weKvrhreh8G,.HfEDCyNjbWPw8DWxXwEJ{position:absolute}.HfEDCyNjbWPw8DWxXwEJ{background-color:#fff;border:1px solid #d3d6d9;color:#0b0c0c;margin:8px 0 0;max-height:342px;overflow-x:hidden;padding:0;transform:translateZ(0);width:calc(100% - 2px);z-index:200}.HfEDCyNjbWPw8DWxXwEJ.GguvZjj87n5NGDn8J2P6{display:block}.HfEDCyNjbWPw8DWxXwEJ.BJaSrnsPhERUxtRDC6Vu{display:none}.GzNl93gsU8KelMCsQSyZ{border-bottom:1px solid #d3d6d9;border-right-width:0;border-left-width:0;border-top-width:1px;cursor:pointer;display:block;margin:0;padding:7px;position:relative}.GzNl93gsU8KelMCsQSyZ>*{pointer-events:none}.GzNl93gsU8KelMCsQSyZ:first-of-type{border-top-width:0}.GzNl93gsU8KelMCsQSyZ:last-of-type{border-bottom-width:0;margin-bottom:0}.GzNl93gsU8KelMCsQSyZ:where(:nth-child(odd)){background-color:#fafafa}.GzNl93gsU8KelMCsQSyZ.WNS5v6eZssWgR0abiuiV,.GzNl93gsU8KelMCsQSyZ:hover{background-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:#fff;outline:0}.kUveEVlY9D_n5Zmz_dXD{height:30px!important;min-width:16px!important;padding:0!important;position:absolute;left:24px;top:0;width:16px!important}@media(-ms-high-contrast:active),(forced-colors:active){.HfEDCyNjbWPw8DWxXwEJ{border-color:FieldText}.GzNl93gsU8KelMCsQSyZ{background-color:Field;color:FieldText}.GzNl93gsU8KelMCsQSyZ:hover,.HKlvLGhxs7ir32hUBNzQ{background-color:SelectedItem;border-color:SelectedItem;color:SelectedItemText;forced-color-adjust:none;outline-color:SelectedItemText}}.Uy2rTDWqjs4vgNH0aeBm .components-base-control__field{align-items:center;display:flex}.Uy2rTDWqjs4vgNH0aeBm .components-base-control__field .components-base-control__label{flex:1;margin:0}.qLXIpwst_CtGTtmsg3mN{height:auto;min-height:auto;padding:4px}.UVmA1eywUsKVQzLMDooq{background:linear-gradient(45deg,#0000 48%,#0003 0,#0003 52%,#0000 0);border:1px solid #0003;border-radius:50%;height:25px;width:25px}.eTonGpRD1VuB2tbLNegK .components-popover__content{max-width:365px;min-width:max-content;padding:15px}.eTonGpRD1VuB2tbLNegK .components-popover__content>div{padding:0}.eTonGpRD1VuB2tbLNegK .components-base-control__field{margin-bottom:0}.eTonGpRD1VuB2tbLNegK .react-colorful{width:100%!important}.eTonGpRD1VuB2tbLNegK .react-colorful .react-colorful__pointer{height:20px;width:20px}.eTonGpRD1VuB2tbLNegK .react-colorful .react-colorful__saturation{height:150px}.eTonGpRD1VuB2tbLNegK .components-circular-option-picker__option-wrapper{height:25px;width:25px}.nc5TMqH__oA5bcPGTm0D{display:flex;margin-top:15px}.nc5TMqH__oA5bcPGTm0D ._ubMuvqZvhc0awiEVNAL{flex:1}.nc5TMqH__oA5bcPGTm0D .f5wwshdAOOkfChALEoo2{height:auto}.nc5TMqH__oA5bcPGTm0D .components-base-control__field{margin-bottom:0}.OhNX_C7EMJcWKe5tqpKQ{margin-top:15px}.OhNX_C7EMJcWKe5tqpKQ .components-circular-option-picker{display:flex;flex-wrap:wrap}.OhNX_C7EMJcWKe5tqpKQ .components-circular-option-picker .components-circular-option-picker__swatches{display:flex;flex-wrap:wrap;gap:6px}.OhNX_C7EMJcWKe5tqpKQ .components-circular-option-picker .components-circular-option-picker__swatches .components-circular-option-picker__option-wrapper{margin:0}.mos6VIbAjooq2LMyKr88{display:flex;margin-top:15px}.mos6VIbAjooq2LMyKr88 .components-range-control{flex-grow:1;padding-right:5px}.UFXv660XisMp2k7oIkOA{margin:0}.cuno_GtO4bhcM59n00B2{--icon-size:1rem;display:grid;gap:.625rem;grid-template-columns:36px minmax(0,1fr);position:relative}.cuno_GtO4bhcM59n00B2 .components-button svg{display:block;height:var(--icon-size);width:var(--icon-size)}.fOOS92b6g0h9pAqn_2JI{border-radius:0;height:100%;position:relative;z-index:2}.rDe4XxEMyRee1hSKKXzn{display:flex;flex-wrap:wrap;gap:var(--gap,10px)}.Yg1nkwz9mFYMuk6zv1DW.b6i6J_7eUIspcsEZ3Qia>*+*{margin-inline-start:var(--gap,10px)}.dfG8sfdNVPzQp7pqgYJQ.b6i6J_7eUIspcsEZ3Qia>*+*{margin-block-start:var(--gap,10px)}.dfG8sfdNVPzQp7pqgYJQ.rDe4XxEMyRee1hSKKXzn{flex-direction:column}.l03h0IHl5WOI4XvelHt3{border-collapse:collapse;width:100%}.l03h0IHl5WOI4XvelHt3 td,.l03h0IHl5WOI4XvelHt3 th{box-sizing:border-box}.l03h0IHl5WOI4XvelHt3.pz9cxM_c8wpWcOh3bw5v tr:nth-child(2n){background-color:rgba(var(--wp-admin-theme-color--rgb),.04)} - diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.asset.php deleted file mode 100644 index 71313fd9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.asset.php +++ /dev/null @@ -1 +0,0 @@ - array(), 'version' => '50ca20852d9e1cd8d9dc'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.css deleted file mode 100644 index a6a6311e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.css +++ /dev/null @@ -1,2 +0,0 @@ -.mnc9nIWbe_UvWqh_EGSg{position:relative;width:100%}.lvIdqq0VcOc4Fsgp6edt{display:flex;gap:0 4px}.JQD57VZha1Nz_puhbEGL{flex-grow:1;position:relative}.uPu9muJa3zAmugfyIwKm[type=text]{appearance:none;border-color:#8c8f94;border-radius:3px;box-shadow:none;color:#2c3338;cursor:pointer;font-size:16px;line-height:2;min-height:30px;min-width:0;padding:0 24px 0 8px;vertical-align:middle;width:100%}@media(min-width:600px){.uPu9muJa3zAmugfyIwKm[type=text]{font-size:13px}}.uPu9muJa3zAmugfyIwKm[type=text].WNS5v6eZssWgR0abiuiV{outline-offset:2px}.uPu9muJa3zAmugfyIwKm[type=text].MgYZFTRJHzGT5kJMx1EN{padding-right:44px}.BI9El7N6XuVkzJ0yYqjN{display:block;height:12px;width:12px}.FIMlw2_F2weKvrhreh8G{background:#0000;border:none;box-shadow:none;height:100%;right:0;top:0}.FIMlw2_F2weKvrhreh8G,.HfEDCyNjbWPw8DWxXwEJ{position:absolute}.HfEDCyNjbWPw8DWxXwEJ{background-color:#fff;border:1px solid #d3d6d9;color:#0b0c0c;margin:8px 0 0;max-height:342px;overflow-x:hidden;padding:0;transform:translateZ(0);width:calc(100% - 2px);z-index:200}.HfEDCyNjbWPw8DWxXwEJ.GguvZjj87n5NGDn8J2P6{display:block}.HfEDCyNjbWPw8DWxXwEJ.BJaSrnsPhERUxtRDC6Vu{display:none}.GzNl93gsU8KelMCsQSyZ{border-bottom:1px solid #d3d6d9;border-left-width:0;border-right-width:0;border-top-width:1px;cursor:pointer;display:block;margin:0;padding:7px;position:relative}.GzNl93gsU8KelMCsQSyZ>*{pointer-events:none}.GzNl93gsU8KelMCsQSyZ:first-of-type{border-top-width:0}.GzNl93gsU8KelMCsQSyZ:last-of-type{border-bottom-width:0;margin-bottom:0}.GzNl93gsU8KelMCsQSyZ:where(:nth-child(odd)){background-color:#fafafa}.GzNl93gsU8KelMCsQSyZ.WNS5v6eZssWgR0abiuiV,.GzNl93gsU8KelMCsQSyZ:hover{background-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:#fff;outline:0}.kUveEVlY9D_n5Zmz_dXD{height:30px!important;min-width:16px!important;padding:0!important;position:absolute;right:24px;top:0;width:16px!important}@media(-ms-high-contrast:active),(forced-colors:active){.HfEDCyNjbWPw8DWxXwEJ{border-color:FieldText}.GzNl93gsU8KelMCsQSyZ{background-color:Field;color:FieldText}.GzNl93gsU8KelMCsQSyZ:hover,.HKlvLGhxs7ir32hUBNzQ{background-color:SelectedItem;border-color:SelectedItem;color:SelectedItemText;forced-color-adjust:none;outline-color:SelectedItemText}}.Uy2rTDWqjs4vgNH0aeBm .components-base-control__field{align-items:center;display:flex}.Uy2rTDWqjs4vgNH0aeBm .components-base-control__field .components-base-control__label{flex:1;margin:0}.qLXIpwst_CtGTtmsg3mN{height:auto;min-height:auto;padding:4px}.UVmA1eywUsKVQzLMDooq{background:linear-gradient(-45deg,#0000 48%,#0003 0,#0003 52%,#0000 0);border:1px solid #0003;border-radius:50%;height:25px;width:25px}.eTonGpRD1VuB2tbLNegK .components-popover__content{max-width:365px;min-width:max-content;padding:15px}.eTonGpRD1VuB2tbLNegK .components-popover__content>div{padding:0}.eTonGpRD1VuB2tbLNegK .components-base-control__field{margin-bottom:0}.eTonGpRD1VuB2tbLNegK .react-colorful{width:100%!important}.eTonGpRD1VuB2tbLNegK .react-colorful .react-colorful__pointer{height:20px;width:20px}.eTonGpRD1VuB2tbLNegK .react-colorful .react-colorful__saturation{height:150px}.eTonGpRD1VuB2tbLNegK .components-circular-option-picker__option-wrapper{height:25px;width:25px}.nc5TMqH__oA5bcPGTm0D{display:flex;margin-top:15px}.nc5TMqH__oA5bcPGTm0D ._ubMuvqZvhc0awiEVNAL{flex:1}.nc5TMqH__oA5bcPGTm0D .f5wwshdAOOkfChALEoo2{height:auto}.nc5TMqH__oA5bcPGTm0D .components-base-control__field{margin-bottom:0}.OhNX_C7EMJcWKe5tqpKQ{margin-top:15px}.OhNX_C7EMJcWKe5tqpKQ .components-circular-option-picker{display:flex;flex-wrap:wrap}.OhNX_C7EMJcWKe5tqpKQ .components-circular-option-picker .components-circular-option-picker__swatches{display:flex;flex-wrap:wrap;gap:6px}.OhNX_C7EMJcWKe5tqpKQ .components-circular-option-picker .components-circular-option-picker__swatches .components-circular-option-picker__option-wrapper{margin:0}.mos6VIbAjooq2LMyKr88{display:flex;margin-top:15px}.mos6VIbAjooq2LMyKr88 .components-range-control{flex-grow:1;padding-left:5px}.UFXv660XisMp2k7oIkOA{margin:0}.cuno_GtO4bhcM59n00B2{--icon-size:1rem;display:grid;gap:.625rem;grid-template-columns:36px minmax(0,1fr);position:relative}.cuno_GtO4bhcM59n00B2 .components-button svg{display:block;height:var(--icon-size);width:var(--icon-size)}.fOOS92b6g0h9pAqn_2JI{border-radius:0;height:100%;position:relative;z-index:2}.rDe4XxEMyRee1hSKKXzn{display:flex;flex-wrap:wrap;gap:var(--gap,10px)}.Yg1nkwz9mFYMuk6zv1DW.b6i6J_7eUIspcsEZ3Qia>*+*{margin-inline-start:var(--gap,10px)}.dfG8sfdNVPzQp7pqgYJQ.b6i6J_7eUIspcsEZ3Qia>*+*{margin-block-start:var(--gap,10px)}.dfG8sfdNVPzQp7pqgYJQ.rDe4XxEMyRee1hSKKXzn{flex-direction:column}.l03h0IHl5WOI4XvelHt3{border-collapse:collapse;width:100%}.l03h0IHl5WOI4XvelHt3 td,.l03h0IHl5WOI4XvelHt3 th{box-sizing:border-box}.l03h0IHl5WOI4XvelHt3.pz9cxM_c8wpWcOh3bw5v tr:nth-child(2n){background-color:rgba(var(--wp-admin-theme-color--rgb),.04)} - diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/packages.js deleted file mode 100644 index e69de29b..00000000 diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library-rtl.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library-rtl.css deleted file mode 100644 index fe19ff49..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library-rtl.css +++ /dev/null @@ -1 +0,0 @@ -.generatepress-site-library{box-sizing:border-box;margin:40px auto 0;max-width:1200px;padding:0 20px}.generatepress-site-library .generatepress-site-library-opened{bottom:0;display:flex;height:100vh;right:0;position:fixed;left:0;top:0;width:100%;z-index:99999}.generatepress-site-library .generatepress-site-library-info{background:#fff;border-right:1px solid #ddd;padding-bottom:50px;position:relative;width:300px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header{border-bottom:1px solid #ddd;display:flex;justify-content:space-between;padding-right:20px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header .has-author{margin-bottom:0}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header .site-library-author{color:#777;display:block;font-size:11px;margin-bottom:1em;margin-top:3px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header button{border-right:1px solid #ddd;height:auto}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-footer{border-top:1px solid #ddd;bottom:0;display:flex;right:0;position:absolute;left:0}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-footer button{flex-grow:1;font-size:20px;height:50px;justify-content:center}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-footer button:not(:last-child){border-left:1px solid #ddd}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content{box-sizing:border-box;height:calc(100% - 53px);overflow-y:auto;padding:20px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content>:first-child{margin-top:0}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content h3{margin-top:30px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content h3+.gpp-library-action-button{margin-top:10px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content .gpp-debug-panel{background-color:#ffe0a3;border:1px solid #ffcd99}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content .gpp-debug-panel .components-panel__body-title:hover{background-color:#0000}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content .gpp-debug-panel code{font-size:11px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-plugins{font-size:12px;list-style-type:disc;margin-bottom:0;margin-right:1.5em}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-plugins li{margin-bottom:0}.generatepress-site-library .generatepress-site-library-iframe{background:#fff;display:flex;justify-content:center;width:calc(100% - 300px)}.generatepress-site-library .generatepress-site-library-iframe iframe{height:100%;width:100%}.generatepress-site-library .gpp-library-action-button{align-items:center;display:flex;margin-top:30px}.generatepress-site-library .gpp-library-action-button button .components-spinner{margin:0}.generatepress-site-library .gpp-library-action-button .gpp-library-action-message{padding-right:10px}.generatepress-site-library .generatepress-site-library-filter{align-items:center;background:#fff;border:1px solid #ddd;border-radius:4px;display:flex;justify-content:space-between;margin-bottom:40px;padding:20px}.generatepress-site-library .generatepress-site-library-filter>.components-base-control{margin-left:20px}.generatepress-site-library .generatepress-site-library-filter>.components-base-control .components-base-control__field{margin-bottom:0}.generatepress-site-library .generatepress-site-library-filter .components-select-control label{font-size:11px}.generatepress-site-library-list{display:flex;flex-wrap:wrap;list-style:none;margin-right:-30px;padding:0}.generatepress-site-library-list>.generatepress-site-library-list-item{box-sizing:border-box;flex:0 0 33.333%;padding-bottom:30px;padding-right:30px;width:33.333%}@media screen and (max-width:840px){.generatepress-site-library-list>.generatepress-site-library-list-item{flex:0 0 50%;width:50%}}@media screen and (max-width:450px){.generatepress-site-library-list>.generatepress-site-library-list-item{flex:0 0 100%;width:100%}}.generatepress-site-library-list>.generatepress-site-library-list-item>button{background-color:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 0 0 2px #0000;cursor:pointer;display:block;padding:5px;text-align:center;transition:border-color .2s,box-shadow .2s;width:100%}.generatepress-site-library-list>.generatepress-site-library-list-item>button:active,.generatepress-site-library-list>.generatepress-site-library-list-item>button:focus,.generatepress-site-library-list>.generatepress-site-library-list-item>button:hover{box-shadow:0 0 0 2px #216eb7}.generatepress-site-library-list>.generatepress-site-library-list-item>button .generatepress-site-library-list-item-image{display:block;position:relative}.generatepress-site-library-list>.generatepress-site-library-list-item>button .generatepress-site-library-list-item-image img{border-top-right-radius:4px;border-top-left-radius:4px;display:block;height:auto;width:100%}.generatepress-site-library-list>.generatepress-site-library-list-item .generatepress-site-library-list-item-title{font-size:20px;padding:20px 20px 10px}.generatepress-site-library-list>.generatepress-site-library-list-item .generatepress-site-library-list-item-title .generatepress-site-library-required-version{color:#000;display:block;font-size:12px;padding-top:5px}.generatepress-site-library-restore{background:#fff;border:1px solid #ddd;padding:40px}.generatepress-site-library-restore h2{font-size:25px;margin-top:0}.components-placeholder.gpp-library-placeholder{background:#0000;border:0;box-shadow:0 0 0}.components-placeholder.gpp-library-placeholder .components-placeholder__fieldset{justify-content:center}.generatepress-site-library-no-results{padding:50px;text-align:center}.generatepress-site-library-no-results button .components-spinner,.generatepress-site-library-refresh button .components-spinner{margin:0}.generatepress-site-library-refresh{text-align:center}.appearance_page_generatepress-library #wpbody-content .metabox-holder,.appearance_page_generatepress-library #wpcontent{padding:0}.site-library-header{background-color:#fff;box-shadow:0 1px 0 #c8d7e180,0 1px 2px #ddd;margin-bottom:40px;padding:20px}.site-library-header .site-library-container{box-sizing:border-box;display:flex;margin:0 auto;max-width:1200px;padding:0 20px}.site-library-header .library-links{margin-right:auto}.site-library-header .library-links a{display:inline-block;margin:0 10px}.site-library-header .library-title{color:#000;font-size:20px;font-weight:500}.generatepress-dashboard-tabs{box-sizing:border-box;margin:0 auto;max-width:1200px;padding:0 20px} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.asset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.asset.php deleted file mode 100644 index f83a7026..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'wp-api-fetch', 'wp-components', 'wp-element', 'wp-html-entities', 'wp-i18n'), 'version' => 'a6719ff1717f5c4541f7'); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.css deleted file mode 100644 index 254a1596..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.css +++ /dev/null @@ -1 +0,0 @@ -.generatepress-site-library{box-sizing:border-box;margin:40px auto 0;max-width:1200px;padding:0 20px}.generatepress-site-library .generatepress-site-library-opened{bottom:0;display:flex;height:100vh;left:0;position:fixed;right:0;top:0;width:100%;z-index:99999}.generatepress-site-library .generatepress-site-library-info{background:#fff;border-left:1px solid #ddd;padding-bottom:50px;position:relative;width:300px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header{border-bottom:1px solid #ddd;display:flex;justify-content:space-between;padding-left:20px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header .has-author{margin-bottom:0}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header .site-library-author{color:#777;display:block;font-size:11px;margin-bottom:1em;margin-top:3px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-header button{border-left:1px solid #ddd;height:auto}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-footer{border-top:1px solid #ddd;bottom:0;display:flex;left:0;position:absolute;right:0}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-footer button{flex-grow:1;font-size:20px;height:50px;justify-content:center}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-footer button:not(:last-child){border-right:1px solid #ddd}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content{box-sizing:border-box;height:calc(100% - 53px);overflow-y:auto;padding:20px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content>:first-child{margin-top:0}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content h3{margin-top:30px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content h3+.gpp-library-action-button{margin-top:10px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content .gpp-debug-panel{background-color:#ffe0a3;border:1px solid #ffcd99}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content .gpp-debug-panel .components-panel__body-title:hover{background-color:#0000}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-content .gpp-debug-panel code{font-size:11px}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-plugins{font-size:12px;list-style-type:disc;margin-bottom:0;margin-left:1.5em}.generatepress-site-library .generatepress-site-library-info .generatepress-site-library-plugins li{margin-bottom:0}.generatepress-site-library .generatepress-site-library-iframe{background:#fff;display:flex;justify-content:center;width:calc(100% - 300px)}.generatepress-site-library .generatepress-site-library-iframe iframe{height:100%;width:100%}.generatepress-site-library .gpp-library-action-button{align-items:center;display:flex;margin-top:30px}.generatepress-site-library .gpp-library-action-button button .components-spinner{margin:0}.generatepress-site-library .gpp-library-action-button .gpp-library-action-message{padding-left:10px}.generatepress-site-library .generatepress-site-library-filter{align-items:center;background:#fff;border:1px solid #ddd;border-radius:4px;display:flex;justify-content:space-between;margin-bottom:40px;padding:20px}.generatepress-site-library .generatepress-site-library-filter>.components-base-control{margin-right:20px}.generatepress-site-library .generatepress-site-library-filter>.components-base-control .components-base-control__field{margin-bottom:0}.generatepress-site-library .generatepress-site-library-filter .components-select-control label{font-size:11px}.generatepress-site-library-list{display:flex;flex-wrap:wrap;list-style:none;margin-left:-30px;padding:0}.generatepress-site-library-list>.generatepress-site-library-list-item{box-sizing:border-box;flex:0 0 33.333%;padding-bottom:30px;padding-left:30px;width:33.333%}@media screen and (max-width:840px){.generatepress-site-library-list>.generatepress-site-library-list-item{flex:0 0 50%;width:50%}}@media screen and (max-width:450px){.generatepress-site-library-list>.generatepress-site-library-list-item{flex:0 0 100%;width:100%}}.generatepress-site-library-list>.generatepress-site-library-list-item>button{background-color:#fff;border:1px solid #ddd;border-radius:4px;box-shadow:0 0 0 2px #0000;cursor:pointer;display:block;padding:5px;text-align:center;transition:border-color .2s,box-shadow .2s;width:100%}.generatepress-site-library-list>.generatepress-site-library-list-item>button:active,.generatepress-site-library-list>.generatepress-site-library-list-item>button:focus,.generatepress-site-library-list>.generatepress-site-library-list-item>button:hover{box-shadow:0 0 0 2px #216eb7}.generatepress-site-library-list>.generatepress-site-library-list-item>button .generatepress-site-library-list-item-image{display:block;position:relative}.generatepress-site-library-list>.generatepress-site-library-list-item>button .generatepress-site-library-list-item-image img{border-top-left-radius:4px;border-top-right-radius:4px;display:block;height:auto;width:100%}.generatepress-site-library-list>.generatepress-site-library-list-item .generatepress-site-library-list-item-title{font-size:20px;padding:20px 20px 10px}.generatepress-site-library-list>.generatepress-site-library-list-item .generatepress-site-library-list-item-title .generatepress-site-library-required-version{color:#000;display:block;font-size:12px;padding-top:5px}.generatepress-site-library-restore{background:#fff;border:1px solid #ddd;padding:40px}.generatepress-site-library-restore h2{font-size:25px;margin-top:0}.components-placeholder.gpp-library-placeholder{background:#0000;border:0;box-shadow:0 0 0}.components-placeholder.gpp-library-placeholder .components-placeholder__fieldset{justify-content:center}.generatepress-site-library-no-results{padding:50px;text-align:center}.generatepress-site-library-no-results button .components-spinner,.generatepress-site-library-refresh button .components-spinner{margin:0}.generatepress-site-library-refresh{text-align:center}.appearance_page_generatepress-library #wpbody-content .metabox-holder,.appearance_page_generatepress-library #wpcontent{padding:0}.site-library-header{background-color:#fff;box-shadow:0 1px 0 #c8d7e180,0 1px 2px #ddd;margin-bottom:40px;padding:20px}.site-library-header .site-library-container{box-sizing:border-box;display:flex;margin:0 auto;max-width:1200px;padding:0 20px}.site-library-header .library-links{margin-left:auto}.site-library-header .library-links a{display:inline-block;margin:0 10px}.site-library-header .library-title{color:#000;font-size:20px;font-weight:500}.generatepress-dashboard-tabs{box-sizing:border-box;margin:0 auto;max-width:1200px;padding:0 20px} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.js deleted file mode 100644 index 66525a97..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/site-library.js +++ /dev/null @@ -1,6 +0,0 @@ -(()=>{var e={703:(e,t,r)=>{"use strict";var n=r(414);function a(){}function s(){}s.resetWarningCache=a,e.exports=function(){function e(e,t,r,a,s,i){if(i!==n){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function t(){return e}e.isRequired=e;var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:s,resetWarningCache:a};return r.PropTypes=r,r}},697:(e,t,r)=>{e.exports=r(703)()},414:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},216:(e,t,r)=>{"use strict";t.be=void 0;var n=function(){function e(e,t){for(var r=0;r=0&&_-E[0]<=d&&_+b+E[1]>=0}(e,r):function(e){var t=e.ref;if(!(t.offsetWidth||t.offsetHeight||t.getClientRects().length))return!1;var r=void 0,n=void 0;try{var a=t.getBoundingClientRect();r=a.top,n=a.height}catch(e){r=0,n=0}var s=window.innerHeight||document.documentElement.clientHeight,i=Array.isArray(e.props.offset)?e.props.offset:[e.props.offset,e.props.offset];return r-i[0]<=s&&r+n+i[1]>=0}(e);n?e.visible||(e.props.once&&g.push(e),e.visible=!0,e.forceUpdate()):e.props.once&&e.visible||(e.visible=!1,e.props.unmountIfInvisible&&e.forceUpdate())}},y=function(){for(var e=0;e{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r){var n=void 0,a=void 0,s=void 0,i=void 0,l=void 0,o=function o(){var p=+new Date-i;p=0?n=setTimeout(o,t-p):(n=null,r||(l=e.apply(s,a),n||(s=null,a=null)))};return function(){s=this,a=arguments,i=+new Date;var p=r&&!n;return n||(n=setTimeout(o,t)),p&&(l=e.apply(s,a),s=null,a=null),l}}},81:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.on=function(e,t,r,n){n=n||!1,e.addEventListener?e.addEventListener(t,r,n):e.attachEvent&&e.attachEvent("on"+t,(function(t){r.call(e,t||window.event)}))},t.off=function(e,t,r,n){n=n||!1,e.removeEventListener?e.removeEventListener(t,r,n):e.detachEvent&&e.detachEvent("on"+t,r)}},315:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if(!(e instanceof HTMLElement))return document.documentElement;for(var t="absolute"===e.style.position,r=/(scroll|auto)/,n=e;n;){if(!n.parentNode)return e.ownerDocument||document.documentElement;var a=window.getComputedStyle(n),s=a.position,i=a.overflow,l=a["overflow-x"],o=a["overflow-y"];if("static"===s&&t)n=n.parentNode;else{if(r.test(i)&&r.test(l)&&r.test(o))return n;n=n.parentNode}}return e.ownerDocument||e.documentElement||document.documentElement}},821:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,r){var n,a;return t||(t=250),function(){var s=r||this,i=+new Date,l=arguments;n&&i{"use strict";e.exports=window.React}},t={};function r(n){var a=t[n];if(void 0!==a)return a.exports;var s=t[n]={exports:{}};return e[n](s,s.exports,r),s.exports}r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,{a:t}),t},r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e=r(196);const t=window.wp.i18n,n=window.wp.element,a=window.wp.components,s=window.wp.htmlEntities,i=window.wp.apiFetch;var l,o,p=r.n(i),c=r(216);function m(e,t,r){const n=r&&r.lexicographical,a=r&&r.zeroExtend;let s=e.split("."),i=t.split(".");function l(e){return(n?/^\d+[A-Za-z]*$/:/^\d+$/).test(e)}if(!s.every(l)||!i.every(l))return NaN;if(a){for(;s.lengthi[e]?1:-1}return s.length!==i.length?-1:0}function u({allSites:r,value:n,onChange:s}){if(!r)return null;const i=[""];return Object.keys(r).forEach((e=>{r[e].category.forEach((e=>{i.includes(e)||i.push(e)}))})),i.length<2?null:(0,e.createElement)("div",null,i.map((r=>(0,e.createElement)(a.Button,{key:r,variant:r===n?"primary":"",onClick:()=>s(r)},""===r?(0,t.__)("All","gp-premium"):r))))}function d({onChange:r,value:n}){return(0,e.createElement)("div",null,(0,e.createElement)("input",{type:"search",onChange:e=>r(e?.target?.value),value:n,placeholder:(0,t.__)("Search site name or author","gp-premium")}))}function g({url:t,previewWidth:r}){const a=(0,n.useRef)(null);return(0,n.useEffect)((()=>{const e=a.current.attachShadow({mode:"open"}),r=document.createElement("iframe");return r.src=t,r.style.width="100%",r.style.height="100%",e.appendChild(r),()=>{e.removeChild(r)}}),[t]),(0,e.createElement)("div",{style:{width:r},ref:a})}l=(0,e.createElement)((function(){const[r,i]=(0,n.useState)(!1),[l,o]=(0,n.useState)({}),[h,f]=(0,n.useState)(!1),[b,v]=(0,n.useState)(!1),[y,_]=(0,n.useState)({}),[E,w]=(0,n.useState)({}),[C,k]=(0,n.useState)({}),[S,O]=(0,n.useState)(!1),[T,x]=(0,n.useState)(!0),[N,L]=(0,n.useState)(!0),[P,R]=(0,n.useState)(!1),[j,B]=(0,n.useState)(!1),[I,D]=(0,n.useState)([]),[A,M]=(0,n.useState)([]),[W,F]=(0,n.useState)([]),[U,z]=(0,n.useState)(!1),[H,V]=(0,n.useState)(gppSiteLibrary.hasBackup),[G,q]=(0,n.useState)(""),[Z,$]=(0,n.useState)(""),[J,Y]=(0,n.useState)("desktop");function K(e){e.classList.add("gpp-library-action-message--show"),e.textContent=(0,t.__)("Activating plugins","gp-premium"),p()({path:"/generatepress-site-library/v1/activate_plugins",method:"POST",data:{siteData:y,siteSlug:y.name.replace(/\s+/g,"_").toLowerCase(),importOptions:T,importContent:N}}).then((t=>{e.textContent=t.response,t.success&&t.response||e.classList.add("gblocks-action-message--error"),setTimeout((()=>{Q(e)}),2e3)}))}function Q(e){e.classList.add("gpp-library-action-message--show"),e.textContent=(0,t.__)("Importing content","gp-premium"),p()({path:"/generatepress-site-library/v1/import_content",method:"POST",data:{siteData:y,siteSlug:y.name.replace(/\s+/g,"_").toLowerCase(),importOptions:T,importContent:N}}).then((r=>{e.textContent=r.response,r.success&&r.response||e.classList.add("gblocks-action-message--error"),setTimeout((()=>{!function(e){e.classList.add("gpp-library-action-message--show"),e.textContent=(0,t.__)("Importing site options","gp-premium"),p()({path:"/generatepress-site-library/v1/import_site_options",method:"POST",data:{siteData:y,siteSlug:y.name.replace(/\s+/g,"_").toLowerCase(),importOptions:T,importContent:N}}).then((r=>{e.textContent=r.response,r.success&&r.response||e.classList.add("gblocks-action-message--error"),setTimeout((()=>{S?function(e){e.classList.add("gpp-library-action-message--show"),e.textContent=(0,t.__)("Importing widgets","gp-premium"),p()({path:"/generatepress-site-library/v1/import_widgets",method:"POST",data:{siteData:y,siteSlug:y.name.replace(/\s+/g,"_").toLowerCase(),importOptions:T,importContent:N}}).then((r=>{e.textContent=r.response,r.success&&r.response||e.classList.add("gblocks-action-message--error"),setTimeout((()=>{e.textContent=(0,t.__)("Import Complete","gp-premium"),f(!1),B(!0),V(!0)}),2e3)}))}(e):(e.textContent=(0,t.__)("Import Complete","gp-premium"),f(!1),B(!0),V(!0))}),2e3)}))}(e)}),2e3)}))}if((0,n.useEffect)((()=>{p()({path:"/generatepress-site-library/v1/get_sites",method:"POST",data:{forceRefresh:!1}}).then((e=>{i(!0),o(e.response)}))}),[]),!r)return(0,e.createElement)(a.Placeholder,{className:"gpp-library-placeholder"},(0,e.createElement)(a.Spinner,null));if(!l||"no results"===l)return(0,e.createElement)("div",{className:"generatepress-site-library-no-results"},(0,e.createElement)("p",null,(0,t.__)("No sites were found.","gp-premium")," ",(0,e.createElement)("a",{href:"https://docs.generatepress.com/article/site-library-unavailable/",target:"_blank",rel:"noreferrer noopener"},(0,t.__)("Why?","gp-premium"))),(0,e.createElement)(a.Button,{variant:"primary",onClick:()=>{z(!0),p()({path:"/generatepress-site-library/v1/get_sites",method:"POST",data:{forceRefresh:!0}}).then((e=>{i(!0),o(e.response),z(!1)}))}},U&&(0,e.createElement)(a.Spinner,null),!U&&(0,t.__)("Try again","gp-premium")));let X="100%";"tablet"===J&&(X="768px"),"mobile"===J&&(X="480px");const ee=y.author_name&&y.author_url&&"GeneratePress"!==y.author_name;return(0,e.createElement)(n.Fragment,null,(0,e.createElement)("div",{className:"generatepress-site-library"},!!H&&(0,e.createElement)("div",{className:"generatepress-site-library-restore"},(0,e.createElement)("h2",null,(0,t.__)("Existing Site Import Detected","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("It is highly recommended that you remove the last site you imported before importing a new one.","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("This process restores your previous options, widgets and active plugins. It will also remove your imported content and CSS.","gp-premium")),(0,e.createElement)("div",{className:"gpp-library-action-button"},(0,e.createElement)(a.Button,{variant:"primary",onClick:e=>{window.confirm((0,t.__)("This process makes changes to your website. If it contains important data, we suggest backing it up before proceeding.","gp-premium"))&&(f(!0),function(e){const r=e.target.nextElementSibling;r.classList.add("gpp-library-action-message--show"),r.textContent=(0,t.__)("Restoring theme options","gp-premium"),p()({path:"/generatepress-site-library/v1/restore_theme_options",method:"POST"}).then((e=>{r.textContent=e.response,e.success&&e.response||r.classList.add("gblocks-action-message--error"),setTimeout((()=>{r.textContent=(0,t.__)("Restoring content","gp-premium"),p()({path:"/generatepress-site-library/v1/restore_content",method:"POST"}).then((e=>{r.textContent=e.response,e.success&&e.response||r.classList.add("gblocks-action-message--error"),f(!1),V(!1)}))}),2e3)}))}(e))}},h&&(0,e.createElement)(a.Spinner,null),!h&&(0,t.__)("Remove imported site","gp-premium")),(0,e.createElement)("span",{className:"gpp-library-action-message"}),!h&&(0,e.createElement)(a.Button,{onClick:()=>{V(!1)}},(0,t.__)("No thanks","gp-premium")))),!b&&!H&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("div",{className:"generatepress-site-library-filter"},(0,e.createElement)(u,{allSites:l,value:G,onChange:e=>{q(e),setTimeout((()=>{(0,c.be)()}),100)}}),(0,e.createElement)(d,{value:Z,onChange:e=>{$(e),q(""),setTimeout((()=>{(0,c.be)()}),100)}})),(0,e.createElement)("ul",{className:"generatepress-site-library-list"},Object.keys(l).map((r=>{if(""!==G&&!l[r].category.includes(G))return null;const n=l[r].name,a=(0,s.decodeEntities)(n);if(""!==Z&&!a.toLowerCase().includes(Z.toLowerCase())&&!l[r].author_name.toLowerCase().includes(Z.toLowerCase()))return null;const i=l[r].directory+"/screenshot.png",o=gppSiteLibrary.gppVersion.split("-")[0],p=l[r].min_version.split("-")[0],u=gppSiteLibrary.gpVersion.split("-")[0],d=gppSiteLibrary.generateblocksVersion.split("-")[0],g=l[r].min_theme_version?l[r].min_theme_version.split("-")[0]:u,h=l[r].min_generateblocks_version?l[r].min_generateblocks_version.split("-")[0]:d,f=l[r].image_width,b=l[r].image_height,y=m(p,o)>0||m(g,u)>0||d&&m(h,d)>0;return(0,e.createElement)("li",{className:"generatepress-site-library-list-item",key:n+":"+r},(0,e.createElement)("button",{disabled:y,onClick:()=>{v(!0),_(l[r]),w(JSON.parse(l[r].plugins))}},(0,e.createElement)("div",{className:"generatepress-site-library-list-item-image"},(0,e.createElement)(c.ZP,{offset:100,once:!0},(0,e.createElement)("img",{src:i,alt:n,width:f,height:b}))),(0,e.createElement)("div",{className:"generatepress-site-library-list-item-title"},a,!!y&&m(p,o)>0&&(0,e.createElement)("span",{className:"generatepress-site-library-required-version"},(0,t.sprintf)(/* translators: Version number */ -(0,t.__)("Requires GP Premium %s.","gp-premium"),p)),!!y&&m(g,u)>0&&(0,e.createElement)("span",{className:"generatepress-site-library-required-version"},(0,t.sprintf)(/* translators: Version number */ -(0,t.__)("Requires GeneratePress %s.","gp-premium"),g)),!!y&&d&&m(h,d)>0&&(0,e.createElement)("span",{className:"generatepress-site-library-required-version"},(0,t.sprintf)(/* translators: Version number */ -(0,t.__)("Requires GenerateBlocks %s.","gp-premium"),h)))))}))),(0,e.createElement)("div",{className:"generatepress-site-library-refresh"},(0,e.createElement)(a.Button,{variant:"primary",onClick:()=>{z(!0),p()({path:"/generatepress-site-library/v1/get_sites",method:"POST",data:{forceRefresh:!0}}).then((e=>{i(!0),o(e.response),z(!1)}))}},U&&(0,e.createElement)(a.Spinner,null),!U&&(0,t.__)("Refresh sites","gp-premium")))),b&&(0,e.createElement)("div",{className:"generatepress-site-library-opened"},(0,e.createElement)("div",{className:"generatepress-site-library-iframe"},(0,e.createElement)(g,{url:y.preview_url,previewWidth:X})),(0,e.createElement)("div",{className:"generatepress-site-library-info"},(0,e.createElement)("div",{className:"generatepress-site-library-header"},(0,e.createElement)("div",{className:"generatepress-site-library-header__title"},(0,e.createElement)("h2",{className:ee?"has-author":""},(0,s.decodeEntities)(y.name)),ee&&(0,e.createElement)("span",{className:"site-library-author"},/* translators: Site library site built by "author name" */ -(0,t.__)("Built by","gp-premium")+" ",(0,e.createElement)("a",{href:y.author_url,target:"_blank",rel:"noreferrer noopener"},y.author_name))),(0,e.createElement)(a.Button,{onClick:()=>{f(!1),v(!1),_({}),w({}),k({}),O(!1),x(!0),L(!0),R(!1),B(!1),D([]),M([]),F([])}},(0,e.createElement)("svg",{width:"35",height:"35",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true",focusable:"false"},(0,e.createElement)("path",{d:"M13 11.9l3.3-3.4-1.1-1-3.2 3.3-3.2-3.3-1.1 1 3.3 3.4-3.5 3.6 1 1L12 13l3.5 3.5 1-1z"})))),(0,e.createElement)("div",{className:"generatepress-site-library-content"},!!y.description&&(0,e.createElement)("p",null,(0,s.decodeEntities)(y.description)),!j&&(0,e.createElement)(n.Fragment,null,0===Object.keys(C).length&&(0,e.createElement)(n.Fragment,null,gppSiteLibrary.isDebugEnabled&&(0,e.createElement)(a.PanelBody,{className:"gpp-debug-panel",title:(0,t.__)("Debug Mode Enabled","gp-premium"),initialOpen:!1},(0,e.createElement)("p",null,(0,t.__)("WordPress debug mode is currently enabled. With this, any errors from third-party plugins might affect the import process.","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("To disable it, find WP_DEBUG in your wp-config.php file and set it to false like the below.","gp-premium")),(0,e.createElement)("code",null,"define( 'WP_DEBUG', false );"),(0,e.createElement)("p",null,(0,e.createElement)("a",{href:"https://docs.generatepress.com/article/debug-mode-enabled/",target:"_blank",rel:"noreferrer noopener"},(0,t.__)("Learn more here","gp-premium")))),Object.keys(E).length>0&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("h3",null,(0,t.__)("Plugins","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("This site uses the following plugins.","gp-premium")),(0,e.createElement)("ul",{className:"generatepress-site-library-plugins"},Object.entries(E).map((([t])=>(0,e.createElement)("li",{key:t},t))))),(0,e.createElement)("div",{className:"gpp-library-action-button"},(0,e.createElement)(a.Button,{variant:"primary",disabled:h,onClick:e=>{f(!0);const r=e.target.nextElementSibling;r.textContent=(0,t.__)("Gathering information","gp-premium"),p()({path:"/generatepress-site-library/v1/get_site_data",method:"POST",data:{siteData:y}}).then((e=>{const t=[],n=[],a=[];Object.entries(e.response.plugin_data).forEach((([r])=>{const s=e.response.plugin_data[r];s.repo&&!s.installed?t.push(s.name):s.installed||s.active?n.push(s.name):a.push(s.name)})),f(!1),k(e.response),w(e.response.plugins),O(e.response.widgets),D(t),M(n),F(a),r.classList.add("gpp-library-action-message--show"),r.textContent=e.response,e.success&&e.response?setTimeout((function(){r.classList.remove("gpp-library-action-message--show")}),3e3):r.classList.add("gpp-library-action-message--error")}))}},h&&(0,e.createElement)(a.Spinner,null),!h&&(0,t.__)("Get Started","gp-premium")),(0,e.createElement)("span",{className:"gpp-library-action-message"}))),Object.keys(C).length>0&&Object.keys(E).length>0&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("h3",null,(0,t.__)("Plugins","gp-premium")),I.length>0&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("p",null,(0,t.__)("These plugins can be installed automatically.","gp-premium")),(0,e.createElement)("ul",{className:"generatepress-site-library-plugins"},I.map((t=>(0,e.createElement)("li",{key:t},t))))),A.length>0&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("p",null,(0,t.__)("These plugins are already installed.","gp-premium")),(0,e.createElement)("ul",{className:"generatepress-site-library-plugins"},A.map((t=>(0,e.createElement)("li",{key:t},t))))),W.length>0&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("p",{style:{fontWeight:"bold"}},(0,t.__)("These plugins need to be installed manually.","gp-premium")),(0,e.createElement)("ul",{className:"generatepress-site-library-plugins"},W.map((t=>"GenerateBlocks Pro"===t?(0,e.createElement)("li",{key:t},(0,e.createElement)(a.ExternalLink,{href:"https://generatepress.com/blocks/#pricing"},t)):(0,e.createElement)("li",{key:t},t)))))),Object.keys(C).length>0&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("h3",null,(0,t.__)("Import","gp-premium")),!h&&0===W.length&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("p",null,(0,t.__)("This process makes changes to your website. If it contains important data, we suggest backing it up before proceeding.","gp-premium")),(0,e.createElement)(a.ToggleControl,{checked:!!P,label:(0,t.__)("I understand","gp-premium"),onChange:e=>{R(e)}})),(0,e.createElement)("div",{className:"gpp-library-action-button"},(0,e.createElement)(a.Button,{variant:"primary",disabled:!P||j||h||W.length>0,onClick:e=>{f(!0),function(e){const r=e.target.nextElementSibling;r.classList.add("gpp-library-action-message--show"),r.textContent=(0,t.__)("Importing theme options","gp-premium"),p()({path:"/generatepress-site-library/v1/import_theme_options",method:"POST",data:{siteData:y,siteSlug:y.name.replace(/\s+/g,"_").toLowerCase(),importOptions:T,importContent:N}}).then((e=>{r.textContent=e.response,e.success&&e.response||r.classList.add("gblocks-action-message--error"),setTimeout((()=>{N?Object.keys(C.plugin_data).length>0?function(e){void 0!==e.target&&(e=e.target.nextElementSibling),e.classList.add("gpp-library-action-message--show"),e.textContent=(0,t.__)("Installing plugins","gp-premium"),Object.entries(C.plugin_data).forEach((([r,n])=>{let a=n.slug.split("/")[0],s=n.name;n.installed?(delete C.plugin_data[r],0===Object.keys(C.plugin_data).length&&K(e)):("bb-plugin"===a&&(a="beaver-builder-lite-version",s="Beaver Builder Lite"),e.textContent=(0,t.sprintf)(/* translators: Installing "Plugin Name" */ -(0,t.__)("Installing %s","gp-premium"),s),wp.updates.installPlugin({slug:a,success:t=>{console.log(t),delete C.plugin_data[r],0===Object.keys(C.plugin_data).length&&K(e)},error:t=>{console.log(t),delete C.plugin_data[r],0===Object.keys(C.plugin_data).length&&K(e)}}))}))}(r):Q(r):(r.textContent=(0,t.__)("Import Complete","gp-premium"),f(!1),B(!0),V(!0))}),2e3)}))}(e)}},h&&(0,e.createElement)(a.Spinner,null),!h&&(0,t.__)("Begin Import","gp-premium")),(0,e.createElement)("span",{className:"gpp-library-action-message"})))),!!j&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("h3",null,(0,t.__)("Import Complete","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("Check out your new site and start making it yours!","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("Note: We do our best to ensure all imported images are licensed for open use. However, image licenses can change, so we strongly advise that you replace all imported images with your own.","gp-premium")),(0,e.createElement)("a",{className:"components-button is-primary",href:gppSiteLibrary.homeUrl},(0,t.__)("View Site","gp-premium")),y.uploads_url&&Object.values(E).includes("elementor/elementor.php")&&(0,e.createElement)(n.Fragment,null,(0,e.createElement)("h3",null,(0,t.__)("Additional Cleanup","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("This site is using Elementor which means you will want to replace the imported image URLs.","gp-premium")),(0,e.createElement)("p",null,(0,t.__)("Take note of the old and new URLs below, then head over to the Elementor Tools area to replace them.","gp-premium")),(0,e.createElement)(a.TextControl,{label:(0,t.__)("Old URL","gp-premium"),readOnly:!0,value:y.uploads_url}),(0,e.createElement)(a.TextControl,{label:(0,t.__)("New URL","gp-premium"),readOnly:!0,value:gppSiteLibrary.uploadsUrl}),(0,e.createElement)("a",{href:gppSiteLibrary.elementorReplaceUrls,className:"components-button is-primary",target:"_blank",rel:"noopener noreferrer"},(0,t.__)("Elementor Tools","gp-premium")))),(0,e.createElement)("div",{className:"generatepress-site-library-footer"},(0,e.createElement)(a.Tooltip,{text:(0,t.__)("Preview desktop","gp-premium")},(0,e.createElement)(a.Button,{variant:"desktop"===J?"primary":"",onClick:()=>{Y("desktop")}},(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",width:"1em",height:"1em",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M21 14H3V4h18m0-2H3c-1.11 0-2 .89-2 2v12a2 2 0 002 2h7l-2 3v1h8v-1l-2-3h7a2 2 0 002-2V4a2 2 0 00-2-2z",fill:"currentColor"})))),(0,e.createElement)(a.Tooltip,{text:(0,t.__)("Preview tablet","gp-premium")},(0,e.createElement)(a.Button,{variant:"tablet"===J?"primary":"",onClick:()=>{Y("tablet")}},(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",width:"1em",height:"1em",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M19 19H4V3h15m-7.5 20a1.5 1.5 0 01-1.5-1.5 1.5 1.5 0 011.5-1.5 1.5 1.5 0 011.5 1.5 1.5 1.5 0 01-1.5 1.5m7-23h-14A2.5 2.5 0 002 2.5v19A2.5 2.5 0 004.5 24h14a2.5 2.5 0 002.5-2.5v-19A2.5 2.5 0 0018.5 0z",fill:"currentColor"})))),(0,e.createElement)(a.Tooltip,{text:(0,t.__)("Preview mobile","gp-premium")},(0,e.createElement)(a.Button,{variant:"mobile"===J?"primary":"",onClick:()=>{Y("mobile")}},(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",width:"1em",height:"1em",viewBox:"0 0 24 24"},(0,e.createElement)("path",{d:"M17 19H7V5h10m0-4H7c-1.11 0-2 .89-2 2v18a2 2 0 002 2h10a2 2 0 002-2V3a2 2 0 00-2-2z",fill:"currentColor"}))))))))))}),null),o=document.getElementById("gpp-site-library"),void 0!==n.createRoot?(0,n.createRoot)(o).render(l):(0,n.render)(l,o)})()})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/style-dashboard-rtl.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/style-dashboard-rtl.css deleted file mode 100644 index d1224c75..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/style-dashboard-rtl.css +++ /dev/null @@ -1,4 +0,0 @@ -.generatepress-module-action{display:inline-block;font-size:12px;font-weight:400;line-height:1;margin-right:10px;text-decoration:none}.generatepress-dashboard__section-item-settings{align-items:center;display:flex}.generatepress-dashboard__section-item-settings button{font-size:11px;height:30px;justify-content:center!important}.generatepress-dashboard__section-item-settings button .components-spinner{margin-top:0}.generatepress-dashboard__section-item-settings button svg{height:20px;margin:0!important;width:20px}.generatepress-dashboard__section-item-settings button:not(:last-child){margin-left:5px} -.generatepress-license-key-area .generatepress-dashboard__section-item-message{background:#fff}.generatepress-license-key-area .generatepress-dashboard__section-item{flex-wrap:wrap;justify-content:flex-start}.generatepress-license-key-area .generatepress-dashboard__section-license-key{display:flex;flex:1}.generatepress-license-key-area .generatepress-dashboard__section-license-key .components-base-control{flex:1}.generatepress-license-key-area .generatepress-dashboard__section-license-key button{height:31px;margin-right:8px}.generatepress-license-key-area .generatepress-dashboard__section-beta-tester{align-items:center;display:flex;flex-basis:100%;margin-top:30px}.generatepress-license-key-area .generatepress-dashboard__section-license-notice{flex-basis:100%;margin:0 0 20px}.generatepress-license-key-area .components-base-control__field,.generatepress-license-key-area .components-base-control__help{margin-bottom:0} -.generatepress-dashboard__section-item-action input[type=file]{border:1px solid #ddd;padding:5px}.generatepress-dashboard__section-item-export-popover .components-popover__content{padding:20px} -.generatepress-dashboard__section-item-modules{margin-top:20px} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/style-dashboard.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/style-dashboard.css deleted file mode 100644 index f226f072..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/dist/style-dashboard.css +++ /dev/null @@ -1,4 +0,0 @@ -.generatepress-module-action{display:inline-block;font-size:12px;font-weight:400;line-height:1;margin-left:10px;text-decoration:none}.generatepress-dashboard__section-item-settings{align-items:center;display:flex}.generatepress-dashboard__section-item-settings button{font-size:11px;height:30px;justify-content:center!important}.generatepress-dashboard__section-item-settings button .components-spinner{margin-top:0}.generatepress-dashboard__section-item-settings button svg{height:20px;margin:0!important;width:20px}.generatepress-dashboard__section-item-settings button:not(:last-child){margin-right:5px} -.generatepress-license-key-area .generatepress-dashboard__section-item-message{background:#fff}.generatepress-license-key-area .generatepress-dashboard__section-item{flex-wrap:wrap;justify-content:flex-start}.generatepress-license-key-area .generatepress-dashboard__section-license-key{display:flex;flex:1}.generatepress-license-key-area .generatepress-dashboard__section-license-key .components-base-control{flex:1}.generatepress-license-key-area .generatepress-dashboard__section-license-key button{height:31px;margin-left:8px}.generatepress-license-key-area .generatepress-dashboard__section-beta-tester{align-items:center;display:flex;flex-basis:100%;margin-top:30px}.generatepress-license-key-area .generatepress-dashboard__section-license-notice{flex-basis:100%;margin:0 0 20px}.generatepress-license-key-area .components-base-control__field,.generatepress-license-key-area .components-base-control__help{margin-bottom:0} -.generatepress-dashboard__section-item-action input[type=file]{border:1px solid #ddd;padding:5px}.generatepress-dashboard__section-item-export-popover .components-popover__content{padding:20px} -.generatepress-dashboard__section-item-modules{margin-top:20px} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/author-image-placeholder.png b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/author-image-placeholder.png deleted file mode 100644 index f8bdda75..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/author-image-placeholder.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/background-image-fallback.jpg b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/background-image-fallback.jpg deleted file mode 100644 index ae5ef65d..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/background-image-fallback.jpg and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/balloon.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/balloon.css deleted file mode 100644 index b2dbcb0c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/balloon.css +++ /dev/null @@ -1,211 +0,0 @@ -button[data-balloon] { - overflow: visible; } - -[data-balloon] { - position: relative; - cursor: pointer; } - [data-balloon]:after { - filter: alpha(opacity=0); - -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)"; - -moz-opacity: 0; - -khtml-opacity: 0; - opacity: 0; - pointer-events: none; - transition: all 0.18s ease-out 0.18s; - font-weight: normal !important; - font-style: normal !important; - text-shadow: none !important; - font-size: 12px !important; - background: rgba(17, 17, 17, 0.9); - border-radius: 4px; - color: #fff; - content: attr(data-balloon); - padding: .5em 1em; - position: absolute; - white-space: nowrap; - z-index: 10; } - [data-balloon]:before { - background: no-repeat url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http://www.w3.org/2000/svg%22%20width%3D%2236px%22%20height%3D%2212px%22%3E%3Cpath%20fill%3D%22rgba(17, 17, 17, 0.9)%22%20transform%3D%22rotate(0)%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E"); - background-size: 100% auto; - width: 18px; - height: 6px; - filter: alpha(opacity=0); - -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=0)"; - -moz-opacity: 0; - -khtml-opacity: 0; - opacity: 0; - pointer-events: none; - transition: all 0.18s ease-out 0.18s; - content: ''; - position: absolute; - z-index: 10; } - [data-balloon]:hover:before, [data-balloon]:hover:after, [data-balloon][data-balloon-visible]:before, [data-balloon][data-balloon-visible]:after { - filter: alpha(opacity=100); - -ms-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=100)"; - -moz-opacity: 1; - -khtml-opacity: 1; - opacity: 1; - pointer-events: auto; } - [data-balloon].font-awesome:after { - font-family: FontAwesome; } - [data-balloon][data-balloon-break]:after { - white-space: pre; } - [data-balloon][data-balloon-blunt]:before, [data-balloon][data-balloon-blunt]:after { - transition: none; } - [data-balloon][data-balloon-pos="up"]:after { - bottom: 100%; - left: 50%; - margin-bottom: 11px; - transform: translate(-50%, 10px); - transform-origin: top; } - [data-balloon][data-balloon-pos="up"]:before { - bottom: 100%; - left: 50%; - margin-bottom: 5px; - transform: translate(-50%, 10px); - transform-origin: top; } - [data-balloon][data-balloon-pos="up"]:hover:after, [data-balloon][data-balloon-pos="up"][data-balloon-visible]:after { - transform: translate(-50%, 0); } - [data-balloon][data-balloon-pos="up"]:hover:before, [data-balloon][data-balloon-pos="up"][data-balloon-visible]:before { - transform: translate(-50%, 0); } - [data-balloon][data-balloon-pos="up-left"]:after { - bottom: 100%; - left: 0; - margin-bottom: 11px; - transform: translate(0, 10px); - transform-origin: top; } - [data-balloon][data-balloon-pos="up-left"]:before { - bottom: 100%; - left: 5px; - margin-bottom: 5px; - transform: translate(0, 10px); - transform-origin: top; } - [data-balloon][data-balloon-pos="up-left"]:hover:after, [data-balloon][data-balloon-pos="up-left"][data-balloon-visible]:after { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos="up-left"]:hover:before, [data-balloon][data-balloon-pos="up-left"][data-balloon-visible]:before { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos="up-right"]:after { - bottom: 100%; - right: 0; - margin-bottom: 11px; - transform: translate(0, 10px); - transform-origin: top; } - [data-balloon][data-balloon-pos="up-right"]:before { - bottom: 100%; - right: 5px; - margin-bottom: 5px; - transform: translate(0, 10px); - transform-origin: top; } - [data-balloon][data-balloon-pos="up-right"]:hover:after, [data-balloon][data-balloon-pos="up-right"][data-balloon-visible]:after { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos="up-right"]:hover:before, [data-balloon][data-balloon-pos="up-right"][data-balloon-visible]:before { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos='down']:after { - left: 50%; - margin-top: 11px; - top: 100%; - transform: translate(-50%, -10px); } - [data-balloon][data-balloon-pos='down']:before { - background: no-repeat url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http://www.w3.org/2000/svg%22%20width%3D%2236px%22%20height%3D%2212px%22%3E%3Cpath%20fill%3D%22rgba(17, 17, 17, 0.9)%22%20transform%3D%22rotate(180 18 6)%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E"); - background-size: 100% auto; - width: 18px; - height: 6px; - left: 50%; - margin-top: 5px; - top: 100%; - transform: translate(-50%, -10px); } - [data-balloon][data-balloon-pos='down']:hover:after, [data-balloon][data-balloon-pos='down'][data-balloon-visible]:after { - transform: translate(-50%, 0); } - [data-balloon][data-balloon-pos='down']:hover:before, [data-balloon][data-balloon-pos='down'][data-balloon-visible]:before { - transform: translate(-50%, 0); } - [data-balloon][data-balloon-pos='down-left']:after { - left: 0; - margin-top: 11px; - top: 100%; - transform: translate(0, -10px); } - [data-balloon][data-balloon-pos='down-left']:before { - background: no-repeat url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http://www.w3.org/2000/svg%22%20width%3D%2236px%22%20height%3D%2212px%22%3E%3Cpath%20fill%3D%22rgba(17, 17, 17, 0.9)%22%20transform%3D%22rotate(180 18 6)%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E"); - background-size: 100% auto; - width: 18px; - height: 6px; - left: 5px; - margin-top: 5px; - top: 100%; - transform: translate(0, -10px); } - [data-balloon][data-balloon-pos='down-left']:hover:after, [data-balloon][data-balloon-pos='down-left'][data-balloon-visible]:after { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos='down-left']:hover:before, [data-balloon][data-balloon-pos='down-left'][data-balloon-visible]:before { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos='down-right']:after { - right: 0; - margin-top: 11px; - top: 100%; - transform: translate(0, -10px); } - [data-balloon][data-balloon-pos='down-right']:before { - background: no-repeat url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http://www.w3.org/2000/svg%22%20width%3D%2236px%22%20height%3D%2212px%22%3E%3Cpath%20fill%3D%22rgba(17, 17, 17, 0.9)%22%20transform%3D%22rotate(180 18 6)%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E"); - background-size: 100% auto; - width: 18px; - height: 6px; - right: 5px; - margin-top: 5px; - top: 100%; - transform: translate(0, -10px); } - [data-balloon][data-balloon-pos='down-right']:hover:after, [data-balloon][data-balloon-pos='down-right'][data-balloon-visible]:after { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos='down-right']:hover:before, [data-balloon][data-balloon-pos='down-right'][data-balloon-visible]:before { - transform: translate(0, 0); } - [data-balloon][data-balloon-pos='left']:after { - margin-right: 11px; - right: 100%; - top: 50%; - transform: translate(10px, -50%); } - [data-balloon][data-balloon-pos='left']:before { - background: no-repeat url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http://www.w3.org/2000/svg%22%20width%3D%2212px%22%20height%3D%2236px%22%3E%3Cpath%20fill%3D%22rgba(17, 17, 17, 0.9)%22%20transform%3D%22rotate(-90 18 18)%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E"); - background-size: 100% auto; - width: 6px; - height: 18px; - margin-right: 5px; - right: 100%; - top: 50%; - transform: translate(10px, -50%); } - [data-balloon][data-balloon-pos='left']:hover:after, [data-balloon][data-balloon-pos='left'][data-balloon-visible]:after { - transform: translate(0, -50%); } - [data-balloon][data-balloon-pos='left']:hover:before, [data-balloon][data-balloon-pos='left'][data-balloon-visible]:before { - transform: translate(0, -50%); } - [data-balloon][data-balloon-pos='right']:after { - left: 100%; - margin-left: 11px; - top: 50%; - transform: translate(-10px, -50%); } - [data-balloon][data-balloon-pos='right']:before { - background: no-repeat url("data:image/svg+xml;charset=utf-8,%3Csvg%20xmlns%3D%22http://www.w3.org/2000/svg%22%20width%3D%2212px%22%20height%3D%2236px%22%3E%3Cpath%20fill%3D%22rgba(17, 17, 17, 0.9)%22%20transform%3D%22rotate(90 6 6)%22%20d%3D%22M2.658,0.000%20C-13.615,0.000%2050.938,0.000%2034.662,0.000%20C28.662,0.000%2023.035,12.002%2018.660,12.002%20C14.285,12.002%208.594,0.000%202.658,0.000%20Z%22/%3E%3C/svg%3E"); - background-size: 100% auto; - width: 6px; - height: 18px; - left: 100%; - margin-left: 5px; - top: 50%; - transform: translate(-10px, -50%); } - [data-balloon][data-balloon-pos='right']:hover:after, [data-balloon][data-balloon-pos='right'][data-balloon-visible]:after { - transform: translate(0, -50%); } - [data-balloon][data-balloon-pos='right']:hover:before, [data-balloon][data-balloon-pos='right'][data-balloon-visible]:before { - transform: translate(0, -50%); } - [data-balloon][data-balloon-length='small']:after { - white-space: normal; - width: 80px; } - [data-balloon][data-balloon-length='medium']:after { - white-space: normal; - width: 150px; } - [data-balloon][data-balloon-length='large']:after { - white-space: normal; - width: 260px; } - [data-balloon][data-balloon-length='xlarge']:after { - white-space: normal; - width: 380px; } - @media screen and (max-width: 768px) { - [data-balloon][data-balloon-length='xlarge']:after { - white-space: normal; - width: 90vw; } } - [data-balloon][data-balloon-length='fit']:after { - white-space: normal; - width: 100%; } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/elements.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/elements.css deleted file mode 100644 index 08699596..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/elements.css +++ /dev/null @@ -1,86 +0,0 @@ -.choose-element-type-parent:before { - content: ""; - position: fixed; - left: 0; - top: 0; - right: 0; - bottom: 0; - background: rgba(0,0,0,0.5); - z-index: 9991; -} - -.choose-element-type { - position: fixed; - width: 500px; - background: #fff; - left: 50%; - padding: 30px; - box-sizing: border-box; - box-shadow: 0 0 20px rgba(0,0,0,0.05); - border: 1px solid #ddd; - z-index: 9992; - transform: translate(-50%, -50%); - top: 50%; -} - -.choose-element-type h2 { - margin-top: 0; -} - -select.select-type { - position: relative; - padding: 10px 15px; - margin: 0; - background-color: #fff; - box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3; - width: 100%; - overflow: hidden; - height: auto; - border: 0; - cursor: pointer; -} - -select.select-type:hover { - background-color: #fafafa; -} - -.dark-mode select.select-type:hover { - background-color: #23282d; -} - -.choose-element-type button.button { - font-size: 17px; - margin-left: 10px; -} - -.select-type-container { - display: flex; -} - -button.close-choose-element-type { - position: absolute; - top: 10px; - right: 10px; - background: transparent; - border: 0; - box-shadow: 0 0 0; - cursor: pointer; - padding: 0; -} - -button.close-choose-element-type svg { - height: 20px; - width: 20px; -} - -.hook-location { - background: #efefef; - padding: 2px 5px; - font-family: monospace; - font-size: 11px; - border-radius: 2px; -} - -.wrap #generate_premium_elements.closed .inside { - display: block; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/elements.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/elements.js deleted file mode 100644 index 03aa79c9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/elements.js +++ /dev/null @@ -1,29 +0,0 @@ -jQuery( function( $ ) { - $( '.post-type-gp_elements .page-title-action:not(.legacy-button)' ).on( 'click', function( e ) { - e.preventDefault(); - - $( '.choose-element-type-parent' ).show(); - $( '.choose-element-type .select-type' ).focus(); - } ); - - $( '.close-choose-element-type' ).on( 'click', function( e ) { - e.preventDefault(); - - $( '.choose-element-type-parent' ).hide(); - $( '.page-title-action' ).focus(); - } ); - - $( '.post-type-gp_elements' ).on( 'keyup', function( e ) { - const $element = $( '.choose-element-type-parent' ); - - if ( e.key === 'Escape' && $element.is( ':visible' ) ) { - $element.hide(); - $( '.page-title-action' ).focus(); - } - } ); - - // Don't allow Elements to quick edit parents. - $( '.inline-edit-gp_elements select#post_parent, .inline-edit-gp_elements .inline-edit-menu-order-input, .bulk-edit-gp_elements select#post_parent' ).each( function() { - $( this ).closest( 'label' ).remove(); - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/featured-image-placeholder.png b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/featured-image-placeholder.png deleted file mode 100644 index 500f8c9c..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/featured-image-placeholder.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/metabox.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/metabox.css deleted file mode 100644 index d508c547..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/metabox.css +++ /dev/null @@ -1,400 +0,0 @@ -#generate_premium_elements { - background-color: transparent; - border: 0; - box-shadow: 0 0 0; -} - -#generate_premium_elements .inside { - padding: 0; - margin: 0; -} - -#generate_premium_elements .CodeMirror { - position: relative; - padding: 0; - background: white; - box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3; - width: 100%; - overflow: hidden; -} - -tr.generate-element-row td { - border-bottom: 1px solid #f0f0f0; - zoom: 1; -} - -td.generate-element-row-heading { - background: #F9F9F9; - border-right: 1px solid #E1E1E1; - padding: 13px 15px; - width: 24%; -} - -td.generate-element-row-heading label { - display: inline-block; - font-size: 13px; - line-height: 1.4em; - font-weight: bold; - padding: 0; - margin: 0 0 3px; - color: #333; -} - -td.generate-element-row-content { - padding: 13px 15px; - position: relative; - width: 75%; -} - -.metabox-holder #generate_premium_elements .handlediv, -.metabox-holder #generate_premium_elements .hndle, -.metabox-holder #generate_premium_elements .postbox-header { - display: none; -} - -#generate_premium_elements .inside { - padding: 0; -} - -#generate_premium_elements select, -#generate_premium_elements input[type="number"], -#generate_premium_elements input[type="text"] { - width: 100%; -} - -#generate_premium_elements .condition select.condition-object-select + .select2 { - display: none; -} - -#generate_premium_elements .condition.generate-elements-rule-objects-visible select.condition-select + .select2 { - margin-right: 5px; - width: 100%; -} - -#generate_premium_elements .condition.generate-elements-rule-objects-visible select.condition-object-select + .select2 { - display: inline-block; - margin-left: 5px; - width: 100%; -} - -#generate_premium_elements .condition { - display: flex; - margin-bottom: 10px; -} - -#generate_premium_elements .condition .select2 { - flex-grow: 1; -} - -button.remove-condition { - background: transparent; - border: 0; - line-height: 1; - width: 30px; - font-size: 20px; - cursor: pointer; - opacity: 0.5; - position: relative; - bottom: -3px; -} - -button.add-condition { - margin-top: 10px !important; -} - -button.remove-condition:before { - content: "\f153"; - font-family: dashicons; -} - -table.generate-elements-settings { - position: relative; - padding: 0; - background: white; - box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3; - width: 100%; - overflow: hidden; -} - -.generate-element-row-loading { - background-color: rgba(255,255,255,0.9); - background-image: url('spinner.gif'); - background-position: center center; - background-repeat: no-repeat; - position: absolute; - top: 0; - bottom: 0; - left: 0; - right: 0; - z-index: 1; -} - -ul.element-metabox-tabs { - position: relative; - padding: 0; - margin: 0 0 20px; - background: white; - box-shadow: 0 0 0 1px rgba(200, 215, 225, 0.5), 0 1px 2px #e9eff3; - display: flex; - width: 100%; - overflow: hidden; -} - -.edit-post-layout__metaboxes ul.element-metabox-tabs { - margin: 0; -} - -ul.element-metabox-tabs li { - width: auto; - flex: none; - border-bottom: 2px solid transparent; - border-top: none; - text-align: center; - margin-bottom: 0; -} - -ul.element-metabox-tabs li a { - display: block; - width: auto; - padding: 16px 16px 14px 16px; - color: #0087be; - font-weight: 400; - text-decoration: none; - box-shadow: 0 0 0; -} - -ul.element-metabox-tabs li a:hover { - color: #00a0d2; -} - -ul.element-metabox-tabs li.is-selected { - border-bottom-color: #2e4453; -} - -ul.element-metabox-tabs li.is-selected a { - color: #2e4453; -} - -#generate-element-content, -#generate-element-content + .CodeMirror { - margin-bottom: 20px; -} - -.element-metabox-tabs li:not([data-tab="display-rules"]):not([data-tab="internal-notes"]), -.generate-elements-settings:not([data-tab="display-rules"]):not([data-tab="internal-notes"]) { - display: none; -} - -.element-settings.header .element-metabox-tabs li[data-type="header"], -.element-settings.hook .element-metabox-tabs li[data-type="hook"], -.element-settings.block .element-metabox-tabs li[data-type="hook"], -.element-settings.layout .element-metabox-tabs li[data-type="layout"] { - display: block; -} - -.element-settings.header:not(.has-page-hero) table[data-tab="site-header"], -.element-settings.header.has-page-hero table[data-tab="hero"], -.element-settings.hook table[data-tab="hook-settings"], -.element-settings.block table[data-tab="hook-settings"], -.element-settings.layout table[data-tab="sidebars"] { - display: table; -} - -.element-settings.header:not(.has-page-hero) #generate-element-content { - display: none; -} - -.element-settings.header:not(.has-page-hero) #generate-element-content + .CodeMirror:not(.gpp-elements-show-codemirror) { - height: 0; - overflow: hidden; - opacity: 0; - margin: 0; -} - -.padding-container { - display: flex; -} - -.single-value-padding-container { - display: block; -} - -.single-value-padding-container input[type="number"] { - width: 60px !important; - display: inline-block; - vertical-align: middle; -} - -.padding-element-options { - display: flex; -} - -.padding-element span.unit { - border: 1px solid #ddd; - display: inline-block; - line-height: 26px; - padding: 0 10px; - margin-left: -5px; - vertical-align: middle; - border-left: 0; -} - -.padding-element input { - width: 60px !important; - min-height: 30px; -} - -.padding-element select { - width: auto !important; - position: relative; - left: -5px; - min-height: 30px; -} - -.padding-element span { - display: block; - font-size: 90%; - opacity: 0.8; -} - -.generate-element-row-content .responsive-controls.single-responsive-value { - padding: 8px 15px 7px 0; -} - -.generate-element-row-content .responsive-controls.checkbox-responsive-value { - padding: 2px 15px 0 0; -} - -#postimagediv { - display: none; -} - -.image-preview img { - height: 30px; - width: auto; - vertical-align: middle; - border-radius: 5px; -} - -.gp-media-preview img { - vertical-align: middle; - background-color: #efefef; - border-radius: 5px; - height: 30px; - width: auto; -} - -.media-container, -.change-featured-image, -.set-featured-image { - display: flex; - align-items: center; -} - -.media-container > input, -.media-container .gp-media-preview img, -.change-featured-image > *, -.set-featured-image > * { - margin-right: 10px !important; -} - -.generate-element-row-content .responsive-controls { - float: left; - padding: 15px 15px 15px 0; -} - -.generate-element-row-content .responsive-controls a { - text-decoration: none; - color: #222; - opacity: 0.5; - outline: 0; - box-shadow: 0 0 0; -} - -.generate-element-row-content .responsive-controls a.is-selected { - opacity: 1; -} - -.generate-element-row-content .responsive-controls a span { - font-size: 14px; - width: auto; - height: auto; - vertical-align: baseline; -} - -#generate-element-content { - width: 100%; - height: 300px; -} - -.layout-radio-item { - margin-bottom: 3px; -} - -.layout-radio-item:first-child { - margin-bottom: 15px; -} - -span.tip { - display: inline-block; - float: right; - background: #b3b3b3; - height: 15px; - width: 15px; - text-align: center; - line-height: 15px; - color: #fff; - border-radius: 50%; - font-size: 10px; -} - -body:not(.header-element-type) #generate_page_hero_template_tags, -.header-element-type:not(.element-has-page-hero) #generate_page_hero_template_tags { - display: none; -} - -#_generate_element_internal_notes { - width: 100%; - height: 250px; -} - -.select2-results__option { - margin: 0; -} - -body .select2-container--default .select2-selection--single { - border-color: #ddd; -} - -.select2-results__option[role="list"] { - padding: 0; -} - -#generate_premium_elements #_generate_content_width { - width: 65px; - vertical-align: middle; -} - -#_generate_content_width + span { - border: 1px solid #ddd; - height: 26px; - display: inline-block; - vertical-align: middle; - line-height: 26px; - padding: 0 10px; - margin-left: -6px; -} - -.hide-hook-row, -.sidebar-notice { - display: none; -} - -.sidebar-notice { - margin-top: 10px; - font-style: italic; -} - -.element-settings.block .generate-elements-settings[data-type="hook"] tr:last-child td { - border-bottom: 0; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/metabox.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/metabox.js deleted file mode 100644 index c003b0df..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/metabox.js +++ /dev/null @@ -1,424 +0,0 @@ -jQuery( function( $ ) { - if ( $( '.element-settings' ).hasClass( 'header' ) || $( '.element-settings' ).hasClass( 'hook' ) ) { - $( function() { - if ( elements.settings ) { - wp.codeEditor.initialize( 'generate-element-content', elements.settings ); - } - } ); - } - - $( '#_generate_block_type' ).on( 'change', function() { - var _this = $( this ).val(); - - if ( 'hook' === _this ) { - $( '.hook-row' ).removeClass( 'hide-hook-row' ); - } else { - $( '.hook-row' ).addClass( 'hide-hook-row' ); - } - - $( 'body' ).removeClass( 'right-sidebar-block-type' ); - $( 'body' ).removeClass( 'left-sidebar-block-type' ); - $( 'body' ).removeClass( 'header-block-type' ); - $( 'body' ).removeClass( 'footer-block-type' ); - - $( 'body' ).addClass( _this + '-block-type' ); - - if ( 'left-sidebar' === _this || 'right-sidebar' === _this ) { - $( '.sidebar-notice' ).show(); - } else { - $( '.sidebar-notice' ).hide(); - } - } ); - - $( '#_generate_hook' ).on( 'change', function() { - var _this = $( this ); - - $( '.disable-header-hook' ).hide(); - $( '.disable-footer-hook' ).hide(); - $( '.custom-hook-name' ).hide(); - - if ( 'generate_header' === _this.val() ) { - $( '.disable-header-hook' ).show(); - } - - if ( 'generate_footer' === _this.val() ) { - $( '.disable-footer-hook' ).show(); - } - - if ( 'custom' === _this.val() ) { - $( '.custom-hook-name' ).show(); - } - } ); - - $( '#_generate_hook' ).select2( { - width: '100%', - } ); - - $( '.element-metabox-tabs li' ).on( 'click', function() { - var _this = $( this ), - tab = _this.data( 'tab' ); - - _this.siblings().removeClass( 'is-selected' ); - _this.addClass( 'is-selected' ); - $( '.generate-elements-settings' ).hide(); - $( '.generate-elements-settings[data-tab="' + tab + '"]' ).show(); - - if ( $( '.element-settings' ).hasClass( 'block' ) && 'hook-settings' === tab ) { - $( '.generate-elements-settings[data-tab="display-rules"]' ).show(); - } - - if ( $( '.element-settings' ).hasClass( 'header' ) ) { - if ( 'hero' !== tab ) { - $( '#generate-element-content' ).next( '.CodeMirror' ).removeClass( 'gpp-elements-show-codemirror' ); - $( '#generate_page_hero_template_tags' ).css( 'display', '' ); - } else { - $( '#generate-element-content' ).next( '.CodeMirror' ).addClass( 'gpp-elements-show-codemirror' ); - $( '#generate_page_hero_template_tags' ).css( 'display', 'block' ); - } - } - } ); - - var select2Init = function() { - var selects = $( '.generate-element-row-content .condition:not(.hidden) select:not(.select2-init)' ); - - selects.each( function() { - var select = $( this ), - config = { - width: 'style', - }; - - select.select2( config ); - select.addClass( 'select2-init' ); - } ); - }; - - select2Init(); - - $( '.add-condition' ).on( 'click', function() { - var _this = $( this ); - - var row = _this.closest( '.generate-element-row-content' ).find( '.condition.hidden.screen-reader-text' ).clone( true ); - row.removeClass( 'hidden screen-reader-text' ); - row.insertBefore( _this.closest( '.generate-element-row-content' ).find( '.condition:last' ) ); - - select2Init(); - - return false; - } ); - - $( '.remove-condition' ).on( 'click', function() { - $( this ).parents( '.condition' ).remove(); - - select2Init(); - - return false; - } ); - - var getLocationObjects = function( _this, onload = false, data = '' ) { - var select = _this, - parent = select.parent(), - location = select.val(), - objectSelect = parent.find( '.condition-object-select' ), - locationType = '', - actionType = 'terms'; - - if ( '' === location ) { - parent.removeClass( 'generate-elements-rule-objects-visible' ); - select.closest( '.generate-element-row-content' ).find( '.generate-element-row-loading' ).remove(); - } else { - if ( location.indexOf( ':taxonomy:' ) > 0 ) { - locationType = 'taxonomy'; - } else { - locationType = location.substr( 0, location.indexOf( ':' ) ); - } - - var locationID = location.substr( location.lastIndexOf( ':' ) + 1 ); - - if ( 'taxonomy' === locationType || 'post' === locationType ) { - if ( ! ( '.generate-element-row-loading' ).length ) { - select.closest( '.generate-element-row-content' ).prepend( '
    ' ); - } - - var fillObjects = function( response ) { - var objects = response[ locationID ].objects; - - var blank = { - id: '', - name: 'All ' + response[ locationID ].label, - }; - - if ( location.indexOf( ':taxonomy:' ) > 0 ) { - blank.name = elements.choose; - } - - objectSelect.empty(); - - objectSelect.append( $( '' ); - objectSelect.val( '0' ); - } - } - }; - - $( '.condition select.condition-select' ).on( 'change', function() { - getLocationObjects( $( this ) ); - - $( '.elements-no-location-error' ).hide(); - } ); - - var postObjects = []; - var termObjects = []; - - $( '.generate-elements-rule-objects-visible' ).each( function() { - var _this = $( this ), - select = _this.find( 'select.condition-select' ), - location = select.val(), - locationID = location.substr( location.lastIndexOf( ':' ) + 1 ), - locationType = ''; - - if ( location.indexOf( ':taxonomy:' ) > 0 ) { - locationType = 'taxonomy'; - } else { - locationType = location.substr( 0, location.indexOf( ':' ) ); - } - - if ( 'post' === locationType ) { - if ( ! postObjects.includes( locationID ) ) { - postObjects.push( locationID ); - } - } else if ( 'taxonomy' === locationType && ! termObjects.includes( locationID ) ) { - termObjects.push( locationID ); - } - } ); - - if ( postObjects.length > 0 || termObjects.length > 0 ) { - $.post( ajaxurl, { - action: 'generate_elements_get_location_objects', - posts: postObjects, - terms: termObjects, - nonce: elements.nonce, - }, function( response ) { - response = JSON.parse( response ); - - $( '.generate-elements-rule-objects-visible' ).each( function() { - var _this = $( this ), - select = _this.find( 'select.condition-select' ); - - $( '
    ' ).insertBefore( _this ); - - getLocationObjects( select, true, response ); - } ); - } ); - } - - $( '.set-featured-image a, .change-featured-image a:not(.remove-image)' ).on( 'click', function( event ) { - event.preventDefault(); - - // Stop propagation to prevent thickbox from activating. - event.stopPropagation(); - - // Open the featured image modal - wp.media.featuredImage.frame().open(); - } ); - - wp.media.featuredImage.frame().on( 'select', function() { - $( '.set-featured-image' ).hide(); - $( '.change-featured-image' ).show(); - - setTimeout( function() { - $( '.image-preview' ).empty(); - $( '#postimagediv img' ).appendTo( '.image-preview' ); - }, 500 ); - } ); - - $( '#postimagediv' ).on( 'click', '#remove-post-thumbnail', function() { - $( '.set-featured-image' ).show(); - $( '.change-featured-image' ).hide(); - $( '.image-preview' ).empty(); - return false; - } ); - - $( '.remove-image' ).on( 'click', function( e ) { - e.preventDefault(); - - $( '#remove-post-thumbnail' ).trigger( 'click' ); - } ); - - $( '.generate-upload-file' ).on( 'click', function() { - if ( frame ) { - frame.open(); - return; - } - - var _this = $( this ), - container = _this.closest( '.media-container' ); - - var frame = wp.media( { - title: _this.data( 'title' ), - multiple: false, - library: { type: _this.data( 'type' ) }, - button: { text: _this.data( 'insert' ) }, - } ); - - frame.on( 'select', function() { - var attachment = frame.state().get( 'selection' ).first().toJSON(); - - container.find( '.media-field' ).val( attachment.id ); - container.find( '.remove-field' ).show(); - - if ( _this.data( 'preview' ) ) { - container.find( '.gp-media-preview' ).empty().append( '' ).show(); - } - } ); - - frame.open(); - } ); - - $( '.remove-field' ).on( 'click', function() { - var _this = $( this ), - container = _this.closest( '.media-container' ); - - _this.hide(); - container.find( '.media-field' ).val( '' ); - container.find( '.gp-media-preview' ).empty(); - } ); - - $( '#_generate_hero_background_image' ).on( 'change', function() { - var _this = $( this ); - - if ( '' !== _this.val() ) { - $( '.requires-background-image' ).show(); - } else { - $( '.requires-background-image' ).hide(); - } - - if ( 'featured-image' === _this.val() ) { - $( '.image-text' ).text( elements.fallback_image ); - } - - if ( 'custom-image' === _this.val() ) { - $( '.image-text' ).text( elements.custom_image ); - } - } ); - - // Responsive controls in our settings. - $( '.responsive-controls a' ).on( 'click', function( e ) { - e.preventDefault(); - - var _this = $( this ), - control = _this.attr( 'data-control' ), - controlArea = _this.closest( '.generate-element-row-content' ); - - controlArea.find( '.padding-container' ).hide(); - controlArea.find( '.padding-container.' + control ).show(); - _this.siblings().removeClass( 'is-selected' ); - _this.addClass( 'is-selected' ); - } ); - - $( '#_generate_site_header_merge' ).on( 'change', function() { - var _this = $( this ); - - if ( '' !== _this.val() ) { - $( '.requires-header-merge' ).show(); - - if ( $( '#_generate_navigation_colors' ).is( ':checked' ) ) { - $( '.requires-navigation-colors' ).show(); - } - - if ( $( '#_generate_hero_full_screen' ).is( ':checked' ) ) { - $( '.requires-full-screen' ).show(); - } - } else { - $( '.requires-header-merge' ).hide(); - $( '.requires-navigation-colors' ).hide(); - $( '.requires-full-screen' ).hide(); - } - } ); - - $( '#_generate_navigation_colors' ).on( 'change', function() { - var _this = $( this ); - - if ( _this.is( ':checked' ) ) { - $( '.requires-navigation-colors' ).show(); - } else { - $( '.requires-navigation-colors' ).hide(); - } - } ); - - $( '#_generate_hero_full_screen' ).on( 'change', function() { - var _this = $( this ); - - if ( _this.is( ':checked' ) ) { - $( '.requires-full-screen' ).show(); - } else { - $( '.requires-full-screen' ).hide(); - } - } ); - - $( '#_generate_hero_background_parallax' ).on( 'change', function() { - var _this = $( this ); - - if ( _this.is( ':checked' ) ) { - $( '#_generate_hero_background_position' ).val( '' ).change(); - $( '#_generate_hero_background_position option[value="left center"]' ).attr( 'disabled', true ); - $( '#_generate_hero_background_position option[value="left bottom"]' ).attr( 'disabled', true ); - $( '#_generate_hero_background_position option[value="right center"]' ).attr( 'disabled', true ); - $( '#_generate_hero_background_position option[value="right bottom"]' ).attr( 'disabled', true ); - $( '#_generate_hero_background_position option[value="center center"]' ).attr( 'disabled', true ); - $( '#_generate_hero_background_position option[value="center bottom"]' ).attr( 'disabled', true ); - } else { - $( '#_generate_hero_background_position option[value="left center"]' ).attr( 'disabled', false ); - $( '#_generate_hero_background_position option[value="left bottom"]' ).attr( 'disabled', false ); - $( '#_generate_hero_background_position option[value="right center"]' ).attr( 'disabled', false ); - $( '#_generate_hero_background_position option[value="right bottom"]' ).attr( 'disabled', false ); - $( '#_generate_hero_background_position option[value="center center"]' ).attr( 'disabled', false ); - $( '#_generate_hero_background_position option[value="center bottom"]' ).attr( 'disabled', false ); - } - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/spinner.gif b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/spinner.gif deleted file mode 100644 index 209d10b6..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/admin/spinner.gif and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/js/parallax.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/js/parallax.js deleted file mode 100644 index a4540e52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/js/parallax.js +++ /dev/null @@ -1,17 +0,0 @@ -function generate_parallax_element( selector, context ) { - context = context || document; - var elements = context.querySelectorAll( selector ); - return Array.prototype.slice.call( elements ); -} - -window.addEventListener( "scroll", function() { - var scrolledHeight= window.pageYOffset; - generate_parallax_element( ".page-hero" ).forEach( function( el, index, array ) { - var limit = el.offsetTop + el.offsetHeight; - if( scrolledHeight > el.offsetTop && scrolledHeight <= limit ) { - el.style.backgroundPositionY = ( scrolledHeight - el.offsetTop ) / hero.parallax + "px"; - } else { - el.style.backgroundPositionY = "0"; - } - }); -}); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/js/parallax.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/js/parallax.min.js deleted file mode 100644 index f1918424..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/assets/js/parallax.min.js +++ /dev/null @@ -1 +0,0 @@ -function generate_parallax_element(e,o){var t=(o=o||document).querySelectorAll(e);return Array.prototype.slice.call(t)}window.addEventListener("scroll",function(){var r=window.pageYOffset;generate_parallax_element(".page-hero").forEach(function(e,o,t){var a=e.offsetTop+e.offsetHeight;r>e.offsetTop&&r<=a?e.style.backgroundPositionY=(r-e.offsetTop)/hero.parallax+"px":e.style.backgroundPositionY="0"})}); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-block-elements.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-block-elements.php deleted file mode 100644 index 4e2b73de..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-block-elements.php +++ /dev/null @@ -1,1789 +0,0 @@ - true, - ) - ) - ); - - $parent_elements = get_posts( - array( - 'post_type' => 'gp_elements', - 'post_parent' => 0, - 'no_found_rows' => true, - 'post_status' => 'publish', - 'numberposts' => 100, - 'fields' => 'ids', - 'exclude' => array( get_the_ID() ), - 'meta_query' => array( - array( - 'key' => '_generate_block_type', - 'value' => 'content-template', - 'compare' => '=', - ), - ), - ) - ); - - $parent_elements_data = array(); - - foreach ( (array) $parent_elements as $element ) { - $parent_elements_data[] = array( - 'label' => get_the_title( $element ), - 'id' => $element, - ); - } - - $image_sizes = get_intermediate_image_sizes(); - $image_sizes = array_diff( $image_sizes, array( '1536x1536', '2048x2048' ) ); - $image_sizes[] = 'full'; - - $containerWidth = function_exists( 'generate_get_option' ) ? generate_get_option( 'container_width' ) : 1100; - $rightSidebarWidth = apply_filters( 'generate_right_sidebar_width', '25' ); - $leftSidebarWidth = apply_filters( 'generate_left_sidebar_width', '25' ); - - $containerWidth = floatval( $containerWidth ); - $leftSidebarWidth = '0.' . $leftSidebarWidth; - $rightSidebarWidth = '0.' . $rightSidebarWidth; - - $leftSidebarWidth = $containerWidth - ( $containerWidth * $leftSidebarWidth ); - $rightSidebarWidth = $containerWidth - ( $containerWidth * $rightSidebarWidth ); - - $leftSidebarWidth = $containerWidth - $leftSidebarWidth; - $rightSidebarWidth = $containerWidth - $rightSidebarWidth; - - $contentWidth = $containerWidth - $rightSidebarWidth; - - wp_localize_script( - 'gp-premium-block-elements', - 'gpPremiumBlockElements', - array( - 'isBlockElement' => 'gp_elements' === get_post_type(), - 'taxonomies' => $taxonomies, - 'rightSidebarWidth' => $rightSidebarWidth, - 'leftSidebarWidth' => $leftSidebarWidth, - 'contentWidth' => $contentWidth, - 'hooks' => GeneratePress_Elements_Helper::get_available_hooks(), - 'excerptLength' => apply_filters( 'excerpt_length', 55 ), // phpcs:ignore -- Core filter. - 'isGenerateBlocksActive' => function_exists( 'generateblocks_load_plugin_textdomain' ), - 'isGenerateBlocksInstalled' => file_exists( WP_PLUGIN_DIR . '/generateblocks/plugin.php' ) ? true : false, - 'isGenerateBlocksProActive' => function_exists( 'generateblocks_pro_init' ), - 'installLink' => wp_nonce_url( self_admin_url( 'update.php?action=install-plugin&plugin=generateblocks' ), 'install-plugin_generateblocks' ), - 'activateLink' => wp_nonce_url( 'plugins.php?action=activate&plugin=generateblocks/plugin.php&plugin_status=all&paged=1&s', 'activate-plugin_generateblocks/plugin.php' ), - 'imageSizes' => $image_sizes, - 'imageSizeDimensions' => $this->get_image_Sizes(), - 'featuredImagePlaceholder' => GP_PREMIUM_DIR_URL . 'elements/assets/admin/featured-image-placeholder.png', - 'authorImagePlaceholder' => GP_PREMIUM_DIR_URL . 'elements/assets/admin/author-image-placeholder.png', - 'bgImageFallback' => GP_PREMIUM_DIR_URL . 'elements/assets/admin/background-image-fallback.jpg', - 'templateImageUrl' => 'https://gpsites.co/files/element-library', - 'parentElements' => $parent_elements_data, - ) - ); - - wp_enqueue_style( - 'gp-premium-block-elements', - GP_PREMIUM_DIR_URL . 'dist/block-elements.css', - array( 'wp-edit-blocks' ), - filemtime( GP_PREMIUM_DIR_PATH . 'dist/block-elements.css' ) - ); - } - - /** - * Add our block category. - * - * @param array $categories The existing categories. - */ - public function add_block_category( $categories ) { - return array_merge( - array( - array( - 'slug' => 'generatepress', - 'title' => __( 'GeneratePress', 'gp-premium' ), - ), - ), - $categories - ); - } - - /** - * Register our dynamic blocks. - */ - public function register_dynamic_blocks() { - if ( ! function_exists( 'register_block_type' ) ) { - return; - } - - register_block_type( - 'generatepress/dynamic-content', - array( - 'render_callback' => array( $this, 'do_dynamic_content_block' ), - 'attributes' => array( - 'contentType' => array( - 'type' => 'string', - 'default' => '', - ), - 'excerptLength' => array( - 'type' => 'number', - 'default' => apply_filters( 'excerpt_length', 55 ), // phpcs:ignore -- Core filter. - ), - 'useThemeMoreLink' => array( - 'type' => 'boolean', - 'defaut' => true, - ), - 'customMoreLink' => array( - 'type' => 'string', - 'default' => '', - ), - ), - ) - ); - - register_block_type( - 'generatepress/dynamic-image', - array( - 'render_callback' => array( $this, 'do_dynamic_image_block' ), - 'attributes' => array( - 'imageType' => array( - 'type' => 'string', - 'default' => '', - ), - 'imageSource' => array( - 'type' => 'string', - 'default' => 'current-post', - ), - 'customField' => array( - 'type' => 'string', - 'default' => '', - ), - 'gpDynamicSourceInSameTerm' => array( - 'type' => 'boolean', - 'default' => false, - ), - 'gpDynamicSourceInSameTermTaxonomy' => array( - 'tyoe' => 'string', - 'default' => 'category', - ), - 'imageSize' => array( - 'type' => 'string', - 'default' => 'full', - ), - 'linkTo' => array( - 'type' => 'string', - 'default' => '', - ), - 'linkToCustomField' => array( - 'type' => 'string', - 'default' => '', - ), - 'imageWidth' => array( - 'type' => 'number', - 'default' => null, - ), - 'imageHeight' => array( - 'type' => 'number', - 'default' => null, - ), - 'avatarSize' => array( - 'type' => 'number', - 'default' => 30, - ), - 'avatarRounded' => array( - 'type' => 'boolean', - 'default' => false, - ), - ), - ) - ); - } - - /** - * Do our dynamic content block. - * - * @param array $attributes The attributes from this block. - */ - public function do_dynamic_content_block( $attributes ) { - if ( empty( $attributes['contentType'] ) ) { - return; - } - - if ( 'post-content' === $attributes['contentType'] ) { - return $this->do_content_block(); - } - - if ( 'post-excerpt' === $attributes['contentType'] ) { - return $this->do_excerpt_block( $attributes ); - } - - if ( 'term-description' === $attributes['contentType'] ) { - return sprintf( - '
    %s
    ', - term_description() - ); - } - - if ( 'author-description' === $attributes['contentType'] ) { - return sprintf( - '
    %s
    ', - get_the_author_meta( 'description' ) - ); - } - } - - /** - * Build our content block. - */ - public function do_content_block() { - // Prevents infinite loops while in the editor or autosaving. - $nonpublic_post_types = array( - 'gp_elements', - 'revision', - ); - - if ( ! in_array( get_post_type(), $nonpublic_post_types ) && ! is_admin() ) { - return sprintf( - '
    %s
    ', - apply_filters( 'the_content', str_replace( ']]>', ']]>', get_the_content() ) ) // phpcs:ignore -- Core filter. - ); - } - } - - /** - * Build our excerpt block. - * - * @param array $attributes The block attributes. - */ - public function do_excerpt_block( $attributes ) { - if ( version_compare( PHP_VERSION, '5.6', '>=' ) ) { - $filter_excerpt_length = function( $length ) use ( $attributes ) { - return isset( $attributes['excerptLength'] ) ? $attributes['excerptLength'] : $length; - }; - - add_filter( - 'excerpt_length', - $filter_excerpt_length, - 100 - ); - - if ( isset( $attributes['useThemeMoreLink'] ) && ! $attributes['useThemeMoreLink'] ) { - $filter_more_text = function() use ( $attributes ) { - if ( empty( $attributes['customMoreLink'] ) ) { - return ' ...'; - } - - return apply_filters( - 'generate_excerpt_block_more_output', - sprintf( - ' ... %3$s', - the_title_attribute( 'echo=0' ), - esc_url( get_permalink( get_the_ID() ) ), - wp_kses_post( $attributes['customMoreLink'] ), - sprintf( - /* translators: Aria-label describing the read more button */ - _x( 'More on %s', 'more on post title', 'gp-premium' ), - the_title_attribute( 'echo=0' ) - ) - ) - ); - }; - - add_filter( - 'excerpt_more', - $filter_more_text, - 100 - ); - } - } - - if ( 'gp_elements' === get_post_type() || is_admin() ) { - $post = get_posts( - array( - 'post_type' => 'post', - 'numberposts' => 1, - ) - ); - - if ( ! empty( $post[0] ) ) { - return sprintf( - '
    %s
    ', - apply_filters( 'the_excerpt', get_the_excerpt( $post[0]->ID ) ) // phpcs:ignore -- Core filter. - ); - } else { - return sprintf( - '

    %s

    Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed pulvinar ligula augue, quis bibendum tellus scelerisque venenatis. Pellentesque porta nisi mi. In hac habitasse platea dictumst. Etiam risus elit, molestie non volutpat ac, pellentesque sed eros. Nunc leo odio, sodales non tortor at, porttitor posuere dui.

    ', - __( 'This is a placeholder for your content.', 'gp-premium' ) - ); - } - } - - $excerpt = apply_filters( 'the_excerpt', get_the_excerpt() ); // phpcs:ignore -- Core filter. - - if ( isset( $filter_excerpt_length ) ) { - remove_filter( - 'excerpt_length', - $filter_excerpt_length, - 100 - ); - } - - if ( isset( $filter_more_text ) ) { - remove_filter( - 'excerpt_more', - $filter_more_text, - 100 - ); - } - - return sprintf( - '
    %s
    ', - $excerpt - ); - } - - /** - * Build our dynamic image block. - * - * @param array $attributes The block attributes. - */ - public function do_dynamic_image_block( $attributes ) { - if ( empty( $attributes['imageType'] ) ) { - return; - } - - if ( 'featured-image' === $attributes['imageType'] ) { - $image_source = ! empty( $attributes['imageSource'] ) ? $attributes['imageSource'] : 'current-post'; - $id = $this->get_source_id( $image_source, $attributes ); - - if ( ! $id ) { - return; - } - - if ( has_post_thumbnail( $id ) ) { - $size = ! empty( $attributes['imageSize'] ) ? $attributes['imageSize'] : 'full'; - $featured_image_classes = array( 'dynamic-featured-image' ); - - if ( ! empty( $attributes['className'] ) ) { - $featured_image_classes[] = $attributes['className']; - } - - $featured_image = get_the_post_thumbnail( $id, $size, array( 'class' => implode( ' ', $featured_image_classes ) ) ); - - // We can't alter the width/height generated by get_the_post_thumbnail(), so we need to resort to this. - if ( ! empty( $attributes['imageWidth'] ) ) { - $featured_image = preg_replace( '/width=[\"\'][0-9]+[\"\']/i', 'width="' . absint( $attributes['imageWidth'] ) . '"', $featured_image ); - } - - if ( ! empty( $attributes['imageHeight'] ) ) { - $featured_image = preg_replace( '/height=[\"\'][0-9]+[\"\']/i', 'height="' . absint( $attributes['imageHeight'] ) . '"', $featured_image ); - } - - if ( $featured_image ) { - if ( ! empty( $attributes['linkTo'] ) ) { - if ( 'single-post' === $attributes['linkTo'] ) { - $featured_image = sprintf( - '%s', - esc_url( get_permalink( $id ) ), - $featured_image - ); - } - - if ( 'custom-field' === $attributes['linkTo'] ) { - $custom_field = get_post_meta( $id, $attributes['linkToCustomField'], true ); - - if ( $custom_field ) { - $featured_image = sprintf( - '%s', - esc_url( $custom_field ), - $featured_image - ); - } - } - } - - return $featured_image; - } - } - } - - if ( 'post-meta' === $attributes['imageType'] ) { - $image_source = ! empty( $attributes['imageSource'] ) ? $attributes['imageSource'] : 'current-post'; - $id = $this->get_source_id( $image_source, $attributes ); - - if ( ! $id ) { - return; - } - - $image_field_name = ! empty( $attributes['customField'] ) ? $attributes['customField'] : ''; - - if ( $image_field_name ) { - $image = get_post_meta( $id, $image_field_name, true ); - - if ( ctype_digit( $image ) ) { - $size = ! empty( $attributes['imageSize'] ) ? $attributes['imageSize'] : 'full'; - $image_output = wp_get_attachment_image( $image, $size, false, array( 'class' => 'dynamic-meta-image' ) ); - - // We can't alter the width/height generated by get_the_post_thumbnail(), so we need to resort to this. - if ( ! empty( $attributes['imageWidth'] ) ) { - $image_output = preg_replace( '/width=[\"\'][0-9]+[\"\']/i', 'width="' . absint( $attributes['imageWidth'] ) . '"', $image_output ); - } - - if ( ! empty( $attributes['imageHeight'] ) ) { - $image_output = preg_replace( '/height=[\"\'][0-9]+[\"\']/i', 'height="' . absint( $attributes['imageHeight'] ) . '"', $image_output ); - } - } else { - $image_output = apply_filters( - 'generate_dynamic_custom_field_image', - sprintf( - '', - $image, - ! empty( $attributes['imageWidth'] ) ? absint( $attributes['imageWidth'] ) : '', - ! empty( $attributes['imageHeight'] ) ? absint( $attributes['imageHeight'] ) : '' - ) - ); - } - - if ( ! empty( $image_output ) ) { - if ( ! empty( $attributes['linkTo'] ) ) { - if ( 'single-post' === $attributes['linkTo'] ) { - $image_output = sprintf( - '%s', - esc_url( get_permalink( $id ) ), - $image_output - ); - } - - if ( 'custom-field' === $attributes['linkTo'] ) { - $custom_field = get_post_meta( $id, $attributes['linkToCustomField'], true ); - - if ( $custom_field ) { - $image_output = sprintf( - '%s', - esc_url( $custom_field ), - $image_output - ); - } - } - } - - return $image_output; - } - } - } - - if ( 'author-avatar' === $attributes['imageType'] ) { - global $post; - $author_id = $post->post_author; - $size = ! empty( $attributes['avatarSize'] ) ? $attributes['avatarSize'] : 30; - $image_alt = apply_filters( 'generate_dynamic_author_image_alt', __( 'Photo of author', 'gp-premium' ) ); - - $classes = array( - 'dynamic-author-image', - ); - - if ( ! empty( $attributes['avatarRounded'] ) ) { - $classes[] = 'dynamic-author-image-rounded'; - } - - $avatar = get_avatar( - $author_id, - $size, - '', - esc_attr( $image_alt ), - array( - 'class' => implode( ' ', $classes ), - ) - ); - - if ( $avatar ) { - return $avatar; - } - } - } - - /** - * Get our dynamic URL. - * - * @param string $link_type The kind of link to add. - * @param string $source The source of the dynamic data. - * @param array $block The block we're working with. - */ - public function get_dynamic_url( $link_type, $source, $block ) { - $id = $this->get_source_id( $source, $block['attrs'] ); - $author_id = $this->get_author_id( $source, $block['attrs'] ); - $url = ''; - - if ( 'single-post' === $link_type ) { - $url = get_permalink( $id ); - } - - if ( isset( $block['attrs']['gpDynamicLinkCustomField'] ) ) { - if ( 'post-meta' === $link_type ) { - $url = get_post_meta( $id, $block['attrs']['gpDynamicLinkCustomField'], true ); - } - - if ( 'user-meta' === $link_type ) { - $url = $this->get_user_data( $author_id, $block['attrs']['gpDynamicLinkCustomField'] ); - } - - if ( 'term-meta' === $link_type ) { - $url = get_term_meta( get_queried_object_id(), $block['attrs']['gpDynamicLinkCustomField'], true ); - } - } - - if ( 'author-archives' === $link_type ) { - $url = get_author_posts_url( $author_id ); - } - - if ( 'comments' === $link_type ) { - $url = get_comments_link( $id ); - } - - if ( 'next-posts' === $link_type ) { - global $paged, $wp_query; - - $max_page = 0; - - if ( ! $max_page ) { - $max_page = $wp_query->max_num_pages; - } - - $paged_num = isset( $paged ) && $paged ? $paged : 1; - $nextpage = (int) $paged_num + 1; - - if ( ! is_single() && ( $nextpage <= $max_page ) ) { - $url = next_posts( $max_page, false ); - } - } - - if ( 'previous-posts' === $link_type ) { - global $paged; - - if ( ! is_single() && (int) $paged > 1 ) { - $url = previous_posts( false ); - } - } - - return apply_filters( 'generate_dynamic_element_url', $url, $link_type, $source, $block ); - } - - /** - * Wrap our dynamic text in a link. - * - * @param string $text The text to wrap. - * @param string $link_type The kind of link to add. - * @param string $source The source of the dynamic data. - * @param array $block The block we're working with. - */ - public function add_dynamic_link( $text, $link_type, $source, $block ) { - if ( 'generateblocks/headline' === $block['blockName'] ) { - $url = $this->get_dynamic_url( $link_type, $source, $block ); - - if ( ! $url ) { - return $text; - } - - return sprintf( - '%s', - esc_url( $url ), - $text - ); - } - - if ( 'generateblocks/button' === $block['blockName'] ) { - $url = $this->get_dynamic_url( $link_type, $source, $block ); - - // Since this is a button, we want to scrap the whole block if we don't have a link. - if ( ! $url ) { - return ''; - } - - $dynamic_url = sprintf( - 'href="%s"', - esc_url( $url ) - ); - - return str_replace( 'href="#"', $dynamic_url, $text ); - } - } - - /** - * Get user data. - * - * @since 2.0.0 - * @param int $author_id The ID of the user. - * @param string $field The field to look up. - */ - public function get_user_data( $author_id, $field ) { - $data = get_user_meta( $author_id, $field, true ); - - if ( ! $data ) { - $user_data_names = array( - 'user_nicename', - 'user_email', - 'user_url', - 'display_name', - ); - - if ( in_array( $field, $user_data_names ) ) { - $user_data = get_userdata( $author_id ); - - if ( $user_data ) { - switch ( $field ) { - case 'user_nicename': - $data = $user_data->user_nicename; - break; - - case 'user_email': - $data = $user_data->user_email; - break; - - case 'user_url': - $data = $user_data->user_url; - break; - - case 'display_name': - $data = $user_data->display_name; - break; - } - } - } - } - - return $data; - } - - /** - * Add the dynamic bits to our blocks. - * - * @param string $block_content The block content. - * @param array $block The block info. - */ - public function render_blocks( $block_content, $block ) { - if ( 'gp_elements' === get_post_type() || is_admin() ) { - return $block_content; - } - - if ( 'generateblocks/headline' === $block['blockName'] || 'generateblocks/button' === $block['blockName'] ) { - if ( ! empty( $block['attrs']['gpDynamicTextType'] ) && ! empty( $block['attrs']['gpDynamicTextReplace'] ) ) { - $text_to_replace = $block['attrs']['gpDynamicTextReplace']; - $text_type = $block['attrs']['gpDynamicTextType']; - $link_type = ! empty( $block['attrs']['gpDynamicLinkType'] ) ? $block['attrs']['gpDynamicLinkType'] : ''; - $source = ! empty( $block['attrs']['gpDynamicSource'] ) ? $block['attrs']['gpDynamicSource'] : 'current-post'; - $id = $this->get_source_id( $source, $block['attrs'] ); - - if ( ! $id ) { - return ''; - } - - if ( 'title' === $text_type ) { - $post_title = get_the_title( $id ); - - if ( ! in_the_loop() ) { - if ( is_tax() || is_category() || is_tag() ) { - $post_title = get_queried_object()->name; - } elseif ( is_post_type_archive() ) { - $post_title = post_type_archive_title( '', false ); - } elseif ( is_archive() && function_exists( 'get_the_archive_title' ) ) { - $post_title = get_the_archive_title(); - - if ( is_author() ) { - $post_title = get_the_author(); - } - } elseif ( is_home() ) { - $page_for_posts = get_option( 'page_for_posts' ); - - if ( ! empty( $page_for_posts ) ) { - $post_title = get_the_title( $page_for_posts ); - } else { - $post_title = __( 'Blog', 'gp-premium' ); - } - } - } - - $post_title = apply_filters( 'generate_dynamic_element_text', $post_title, $block ); - - if ( $link_type ) { - $post_title = $this->add_dynamic_link( $post_title, $link_type, $source, $block ); - } - - if ( ! empty( $block['attrs']['gpDynamicTextBefore'] ) ) { - $post_title = $block['attrs']['gpDynamicTextBefore'] . $post_title; - } - - $post_title = apply_filters( 'generate_dynamic_element_text_output', $post_title, $block ); - $block_content = str_replace( $text_to_replace, $post_title, $block_content ); - } - - if ( 'post-date' === $text_type ) { - $updated_time = get_the_modified_time( 'U', $id ); - $published_time = get_the_time( 'U', $id ) + 1800; - - $post_date = sprintf( - '', - esc_attr( get_the_date( 'c', $id ) ), - esc_html( get_the_date( '', $id ) ) - ); - - $is_updated_date = isset( $block['attrs']['gpDynamicDateType'] ) && 'updated-date' === $block['attrs']['gpDynamicDateType']; - - if ( ! empty( $block['attrs']['gpDynamicDateUpdated'] ) || $is_updated_date ) { - if ( $updated_time > $published_time ) { - $post_date = sprintf( - '', - esc_attr( get_the_modified_date( 'c', $id ) ), - esc_html( get_the_modified_date( '', $id ) ) - ); - } elseif ( $is_updated_date ) { - // If we're showing the updated date but no updated date exists, don't display anything. - return ''; - } - } - - $post_date = apply_filters( 'generate_dynamic_element_text', $post_date, $block ); - - if ( $link_type ) { - $post_date = $this->add_dynamic_link( $post_date, $link_type, $source, $block ); - } - - $before_text = ''; - - if ( ! empty( $block['attrs']['gpDynamicTextBefore'] ) ) { - $before_text = $block['attrs']['gpDynamicTextBefore']; - } - - // Use the updated date before text if we're set to replace the published date with updated date. - if ( ! empty( $block['attrs']['gpDynamicUpdatedDateBefore'] ) && ! empty( $block['attrs']['gpDynamicDateUpdated'] ) && $updated_time > $published_time ) { - $before_text = $block['attrs']['gpDynamicUpdatedDateBefore']; - } - - if ( ! empty( $before_text ) ) { - $post_date = $before_text . $post_date; - } - - $post_date = apply_filters( 'generate_dynamic_element_text_output', $post_date, $block ); - $block_content = str_replace( $text_to_replace, $post_date, $block_content ); - } - - if ( 'post-author' === $text_type ) { - $author_id = $this->get_author_id( $source, $block['attrs'] ); - $post_author = get_the_author_meta( 'display_name', $author_id ); - $post_author = apply_filters( 'generate_dynamic_element_text', $post_author, $block ); - - if ( empty( $post_author ) ) { - return ''; - } - - if ( $link_type ) { - $post_author = $this->add_dynamic_link( $post_author, $link_type, $source, $block ); - } - - if ( ! empty( $block['attrs']['gpDynamicTextBefore'] ) ) { - $post_author = $block['attrs']['gpDynamicTextBefore'] . $post_author; - } - - $post_author = apply_filters( 'generate_dynamic_element_text_output', $post_author, $block ); - $block_content = str_replace( $text_to_replace, $post_author, $block_content ); - } - - if ( 'terms' === $text_type && 'generateblocks/headline' === $block['blockName'] ) { - if ( ! empty( $block['attrs']['gpDynamicTextTaxonomy'] ) ) { - $terms = get_the_terms( $id, $block['attrs']['gpDynamicTextTaxonomy'] ); - - if ( is_wp_error( $terms ) ) { - return $block_content; - } - - $term_items = array(); - - foreach ( (array) $terms as $term ) { - if ( ! isset( $term->name ) ) { - continue; - } - - if ( 'term-archives' === $link_type ) { - $term_link = get_term_link( $term, $block['attrs']['gpDynamicTextTaxonomy'] ); - - if ( ! is_wp_error( $term_link ) ) { - $term_items[] = sprintf( - '%2$s', - esc_url( get_term_link( $term, $block['attrs']['gpDynamicTextTaxonomy'] ) ), - $term->name, - $term->slug - ); - } - } else { - $term_items[] = sprintf( - '%1$s', - $term->name, - $term->slug - ); - } - } - - if ( empty( $term_items ) ) { - return ''; - } - - $sep = isset( $block['attrs']['gpDynamicTextTaxonomySeparator'] ) ? $block['attrs']['gpDynamicTextTaxonomySeparator'] : ', '; - $term_output = implode( $sep, $term_items ); - - if ( ! empty( $block['attrs']['gpDynamicTextBefore'] ) ) { - $term_output = $block['attrs']['gpDynamicTextBefore'] . $term_output; - } - - $term_output = apply_filters( 'generate_dynamic_element_text_output', $term_output, $block ); - $block_content = str_replace( $text_to_replace, $term_output, $block_content ); - } else { - return ''; - } - } - - if ( 'comments-number' === $text_type ) { - if ( ! post_password_required( $id ) && ( comments_open( $id ) || get_comments_number( $id ) ) ) { - if ( ! isset( $block['attrs']['gpDynamicNoCommentsText'] ) ) { - $block['attrs']['gpDynamicNoCommentsText'] = __( 'No Comments', 'gp-premium' ); - } - - if ( '' === $block['attrs']['gpDynamicNoCommentsText'] && get_comments_number( $id ) < 1 ) { - return ''; - } - - $comments_text = get_comments_number_text( - $block['attrs']['gpDynamicNoCommentsText'], - ! empty( $block['attrs']['gpDynamicSingleCommentText'] ) ? $block['attrs']['gpDynamicSingleCommentText'] : __( '1 Comment', 'gp-premium' ), - ! empty( $block['attrs']['gpDynamicMultipleCommentsText'] ) ? $block['attrs']['gpDynamicMultipleCommentsText'] : __( '% Comments', 'gp-premium' ) - ); - - $comments_text = apply_filters( 'generate_dynamic_element_text', $comments_text, $block ); - - if ( '' === $comments_text ) { - return ''; - } - - if ( $link_type ) { - $comments_text = $this->add_dynamic_link( $comments_text, $link_type, $source, $block ); - } - - if ( ! empty( $block['attrs']['gpDynamicTextBefore'] ) ) { - $comments_text = $block['attrs']['gpDynamicTextBefore'] . $comments_text; - } - - $comments_text = apply_filters( 'generate_dynamic_element_text_output', $comments_text, $block ); - $block_content = str_replace( $text_to_replace, $comments_text, $block_content ); - } else { - return ''; - } - } - - if ( 'post-meta' === $text_type || 'term-meta' === $text_type || 'user-meta' === $text_type ) { - if ( ! empty( $block['attrs']['gpDynamicTextCustomField'] ) ) { - $custom_field = get_post_meta( $id, $block['attrs']['gpDynamicTextCustomField'], true ); - - if ( 'term-meta' === $text_type ) { - $custom_field = get_term_meta( get_queried_object_id(), $block['attrs']['gpDynamicTextCustomField'], true ); - } - - if ( 'user-meta' === $text_type ) { - $author_id = $this->get_author_id( $source, $block['attrs'] ); - $custom_field = $this->get_user_data( $author_id, $block['attrs']['gpDynamicTextCustomField'] ); - } - - $custom_field = apply_filters( 'generate_dynamic_element_text', $custom_field, $block ); - - if ( $custom_field ) { - if ( $link_type ) { - $custom_field = $this->add_dynamic_link( $custom_field, $link_type, $source, $block ); - } - - if ( ! empty( $block['attrs']['gpDynamicTextBefore'] ) ) { - $custom_field = $block['attrs']['gpDynamicTextBefore'] . $custom_field; - } - - add_filter( 'wp_kses_allowed_html', [ 'GeneratePress_Elements_Helper', 'expand_allowed_html' ], 10, 2 ); - $custom_field = wp_kses_post( $custom_field ); - remove_filter( 'wp_kses_allowed_html', [ 'GeneratePress_Elements_Helper', 'expand_allowed_html' ], 10, 2 ); - - $custom_field = apply_filters( 'generate_dynamic_element_text_output', $custom_field, $block ); - $block_content = str_replace( $text_to_replace, $custom_field, $block_content ); - } else { - $block_content = ''; - } - } else { - $block_content = ''; - } - } - } - } - - if ( 'generateblocks/button' === $block['blockName'] ) { - $link_type = ! empty( $block['attrs']['gpDynamicLinkType'] ) ? $block['attrs']['gpDynamicLinkType'] : ''; - - if ( ! empty( $link_type ) && 'term-archives' !== $link_type ) { - $source = ! empty( $block['attrs']['gpDynamicSource'] ) ? $block['attrs']['gpDynamicSource'] : 'current-post'; - $id = $this->get_source_id( $source, $block['attrs'] ); - - if ( ! $id ) { - return ''; - } - - if ( $link_type ) { - $block_content = $this->add_dynamic_link( $block_content, $link_type, $source, $block ); - } - } - - if ( ! empty( $block['attrs']['gpDynamicTextType'] ) && ! empty( $block['attrs']['gpDynamicTextReplace'] ) ) { - $text_to_replace = $block['attrs']['gpDynamicTextReplace']; - $text_type = $block['attrs']['gpDynamicTextType']; - $link_type = ! empty( $block['attrs']['gpDynamicLinkType'] ) ? $block['attrs']['gpDynamicLinkType'] : ''; - $source = ! empty( $block['attrs']['gpDynamicSource'] ) ? $block['attrs']['gpDynamicSource'] : 'current-post'; - $id = $this->get_source_id( $source, $block['attrs'] ); - - if ( ! $id ) { - return ''; - } - - if ( 'terms' === $text_type ) { - if ( ! empty( $block['attrs']['gpDynamicTextTaxonomy'] ) ) { - $terms = get_the_terms( $id, $block['attrs']['gpDynamicTextTaxonomy'] ); - - if ( is_wp_error( $terms ) ) { - return ''; - } - - $term_buttons = array(); - - foreach ( (array) $terms as $term ) { - if ( ! isset( $term->name ) ) { - continue; - } - - $term_button = str_replace( $text_to_replace, $term->name, $block_content ); - - if ( isset( $term->slug ) ) { - $term_button = str_replace( 'dynamic-term-class', 'post-term-item term-' . $term->slug, $term_button ); - } - - if ( 'term-archives' === $link_type ) { - $term_link = get_term_link( $term, $block['attrs']['gpDynamicTextTaxonomy'] ); - - if ( ! is_wp_error( $term_link ) ) { - $term_url = sprintf( - 'href="%s"', - esc_url( $term_link ) - ); - - $term_button = str_replace( 'href="#"', $term_url, $term_button ); - } - } - - $term_buttons[] = $term_button; - } - - if ( empty( $term_buttons ) ) { - return ''; - } - - $block_content = implode( '', $term_buttons ); - } else { - return ''; - } - } - } - } - - if ( 'generateblocks/container' === $block['blockName'] ) { - if ( ! empty( $block['attrs']['gpRemoveContainerCondition'] ) ) { - $in_same_term = ! empty( $block['attrs']['gpAdjacentPostInSameTerm'] ) ? true : false; - $term_taxonomy = ! empty( $block['attrs']['gpAdjacentPostInSameTermTax'] ) ? $block['attrs']['gpAdjacentPostInSameTermTax'] : 'category'; - - if ( 'no-next-post' === $block['attrs']['gpRemoveContainerCondition'] ) { - $next_post = get_next_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $next_post ) ) { - if ( ! empty( $block['attrs']['isGrid'] ) && ! empty( $block['attrs']['uniqueId'] ) ) { - return '
    '; - } else { - return ''; - } - } - } - - if ( 'no-previous-post' === $block['attrs']['gpRemoveContainerCondition'] ) { - $previous_post = get_previous_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $previous_post ) ) { - if ( ! empty( $block['attrs']['isGrid'] ) && ! empty( $block['attrs']['uniqueId'] ) ) { - return '
    '; - } else { - return ''; - } - } - } - - if ( 'no-featured-image' === $block['attrs']['gpRemoveContainerCondition'] ) { - if ( ! has_post_thumbnail() ) { - return ''; - } - } - - if ( 'no-post-meta' === $block['attrs']['gpRemoveContainerCondition'] && ! empty( $block['attrs']['gpRemoveContainerConditionPostMeta'] ) ) { - $post_meta_check = get_post_meta( get_the_ID(), $block['attrs']['gpRemoveContainerConditionPostMeta'], true ); - - if ( ! $post_meta_check ) { - return ''; - } - } - } elseif ( ! empty( $block['attrs']['url'] ) && ! empty( $block['attrs']['gpDynamicLinkType'] ) ) { - $source = ! empty( $block['attrs']['gpDynamicSource'] ) ? $block['attrs']['gpDynamicSource'] : 'current-post'; - - $id = $this->get_source_id( $source, $block['attrs'] ); - - if ( ! $id ) { - return ''; - } - } - } - - return $block_content; - } - - /** - * Set the featured image as a GB background. - * - * @param string $url The current URL. - * @param array $settings The current settings. - */ - public function set_background_image_url( $url, $settings ) { - if ( ! empty( $settings['gpDynamicImageBg'] ) ) { - $custom_field = ''; - $source = ! empty( $settings['gpDynamicSource'] ) ? $settings['gpDynamicSource'] : 'current-post'; - $id = $this->get_source_id( $source, $settings ); - - if ( ! $id ) { - return ''; - } - - if ( 'post-meta' === $settings['gpDynamicImageBg'] ) { - $custom_field = get_post_meta( $id, $settings['gpDynamicImageCustomField'], true ); - } - - if ( 'term-meta' === $settings['gpDynamicImageBg'] ) { - $custom_field = get_term_meta( get_queried_object_id(), $settings['gpDynamicImageCustomField'], true ); - } - - if ( 'user-meta' === $settings['gpDynamicImageBg'] ) { - $author_id = $this->get_author_id( $source, $settings ); - $custom_field = $this->get_user_data( $author_id, $settings['gpDynamicImageCustomField'] ); - } - - if ( 'featured-image' === $settings['gpDynamicImageBg'] && has_post_thumbnail( $id ) ) { - $image_size = ! empty( $settings['bgImageSize'] ) ? $settings['bgImageSize'] : 'full'; - $url = get_the_post_thumbnail_url( $id, $image_size ); - } elseif ( ! empty( $custom_field ) ) { - if ( is_numeric( $custom_field ) ) { - $image_size = ! empty( $settings['bgImageSize'] ) ? $settings['bgImageSize'] : 'full'; - $url = wp_get_attachment_image_url( $custom_field, $image_size ); - } else { - $url = $custom_field; - } - } elseif ( empty( $settings['gpUseFallbackImageBg'] ) ) { - $url = ''; - } - } - - return $url; - } - - /** - * Set the attributes for our main Container wrapper. - * - * @param array $attributes The existing attributes. - * @param array $settings The settings for the block. - */ - public function set_container_attributes( $attributes, $settings ) { - if ( ! empty( $settings['bgImage'] ) && in_the_loop() ) { - if ( ! empty( $settings['gpDynamicImageBg'] ) ) { - $custom_field = ''; - $source = ! empty( $settings['gpDynamicSource'] ) ? $settings['gpDynamicSource'] : 'current-post'; - $id = $this->get_source_id( $source, $settings ); - - if ( ! $id ) { - return $attributes; - } - - if ( 'post-meta' === $settings['gpDynamicImageBg'] ) { - $custom_field = get_post_meta( $id, $settings['gpDynamicImageCustomField'], true ); - } - - if ( 'term-meta' === $settings['gpDynamicImageBg'] ) { - $custom_field = get_term_meta( get_queried_object_id(), $settings['gpDynamicImageCustomField'], true ); - } - - if ( 'user-meta' === $settings['gpDynamicImageBg'] ) { - $author_id = $this->get_author_id( $source, $settings ); - $custom_field = $this->get_user_data( $author_id, $settings['gpDynamicImageCustomField'] ); - } - - if ( 'featured-image' === $settings['gpDynamicImageBg'] && has_post_thumbnail( $id ) ) { - $image_size = ! empty( $settings['bgImageSize'] ) ? $settings['bgImageSize'] : 'full'; - $url = get_the_post_thumbnail_url( $id, $image_size ); - } elseif ( ! empty( $custom_field ) ) { - if ( is_numeric( $custom_field ) ) { - $image_size = ! empty( $settings['bgImageSize'] ) ? $settings['bgImageSize'] : 'full'; - $url = wp_get_attachment_image_url( $custom_field, $image_size ); - } else { - $url = $custom_field; - } - } elseif ( ! empty( $settings['gpUseFallbackImageBg'] ) ) { - if ( isset( $settings['bgImage']['id'] ) ) { - $image_size = ! empty( $settings['bgImageSize'] ) ? $settings['bgImageSize'] : 'full'; - $image_src = wp_get_attachment_image_src( $settings['bgImage']['id'], $image_size ); - - if ( is_array( $image_src ) ) { - $url = $image_src[0]; - } else { - $url = $settings['bgImage']['image']['url']; - } - } else { - $url = $settings['bgImage']['image']['url']; - } - } - - if ( ! empty( $url ) ) { - $attributes['style'] = '--background-url:url(' . esc_url( $url ) . ')'; - $attributes['class'] .= ' gb-has-dynamic-bg'; - } else { - $attributes['class'] .= ' gb-no-dynamic-bg'; - } - } - } - - if ( ! empty( $settings['gpInlinePostMeta'] ) ) { - $attributes['class'] .= ' inline-post-meta-area'; - } - - return $attributes; - } - - /** - * Set GenerateBlocks defaults. - * - * @param array $defaults The current defaults. - */ - public function set_defaults( $defaults ) { - $defaults['container']['gpInlinePostMeta'] = false; - $defaults['container']['gpInlinePostMetaJustify'] = ''; - $defaults['container']['gpInlinePostMetaJustifyTablet'] = ''; - $defaults['container']['gpInlinePostMetaJustifyMobile'] = ''; - $defaults['container']['gpDynamicImageBg'] = ''; - $defaults['container']['gpDynamicImageCustomField'] = ''; - $defaults['container']['gpDynamicLinkType'] = ''; - $defaults['container']['gpDynamicSource'] = 'current-post'; - $defaults['container']['gpDynamicSourceInSameTerm'] = false; - $defaults['headline']['gpDynamicTextTaxonomy'] = ''; - $defaults['headline']['gpDynamicTextTaxonomySeparator'] = ', '; - - return $defaults; - } - - /** - * Generate our CSS for our options. - * - * @param string $name Name of the block. - * @param array $settings Our available settings. - * @param object $css Current desktop CSS object. - * @param object $desktop_css Current desktop-only CSS object. - * @param object $tablet_css Current tablet CSS object. - * @param object $tablet_only_css Current tablet-only CSS object. - * @param object $mobile_css Current mobile CSS object. - */ - public function generate_css( $name, $settings, $css, $desktop_css, $tablet_css, $tablet_only_css, $mobile_css ) { - if ( 'container' === $name ) { - if ( ! empty( $settings['bgImage'] ) ) { - if ( 'element' === $settings['bgOptions']['selector'] ) { - $css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.gb-has-dynamic-bg' ); - } elseif ( 'pseudo-element' === $settings['bgOptions']['selector'] ) { - $css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.gb-has-dynamic-bg:before' ); - } - - $css->add_property( 'background-image', 'var(--background-url)' ); - - if ( 'element' === $settings['bgOptions']['selector'] ) { - $css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.gb-no-dynamic-bg' ); - } elseif ( 'pseudo-element' === $settings['bgOptions']['selector'] ) { - $css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.gb-no-dynamic-bg:before' ); - } - - $css->add_property( 'background-image', 'none' ); - } - - if ( ! empty( $settings['gpInlinePostMeta'] ) ) { - $css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.inline-post-meta-area > .gb-inside-container' ); - $css->add_property( 'display', 'flex' ); - $css->add_property( 'align-items', 'center' ); - $css->add_property( 'justify-content', $settings['gpInlinePostMetaJustify'] ); - - $tablet_css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.inline-post-meta-area > .gb-inside-container' ); - $tablet_css->add_property( 'justify-content', $settings['gpInlinePostMetaJustifyTablet'] ); - - $mobile_css->set_selector( '.gb-container-' . $settings['uniqueId'] . '.inline-post-meta-area > .gb-inside-container' ); - $mobile_css->add_property( 'justify-content', $settings['gpInlinePostMetaJustifyMobile'] ); - } - } - } - - /** - * Set the attributes for our main Container wrapper. - * - * @param array $attributes The existing attributes. - * @param array $settings The settings for the block. - */ - public function set_dynamic_container_url( $attributes, $settings ) { - $link_type = ! empty( $settings['gpDynamicLinkType'] ) ? $settings['gpDynamicLinkType'] : ''; - - if ( - $link_type && - isset( $settings['url'] ) && - isset( $settings['linkType'] ) && - '' !== $settings['url'] && - ( 'wrapper' === $settings['linkType'] || 'hidden-link' === $settings['linkType'] ) - ) { - if ( ! empty( $link_type ) ) { - $source = ! empty( $settings['gpDynamicSource'] ) ? $settings['gpDynamicSource'] : 'current-post'; - $id = $this->get_source_id( $source, $settings ); - - if ( ! $id ) { - return $attributes; - } - - if ( 'post' === $link_type ) { - $attributes['href'] = esc_url( get_permalink( $id ) ); - } - - if ( 'post-meta' === $link_type ) { - if ( ! empty( $settings['gpDynamicLinkCustomField'] ) ) { - $custom_field = get_post_meta( $id, $settings['gpDynamicLinkCustomField'], true ); - - if ( $custom_field ) { - $attributes['href'] = esc_url( $custom_field ); - } - } - } - } - } - - return $attributes; - } - - /** - * Get our needed source ID. - * - * @param string $source The source attribute. - * @param array $attributes All block attributes. - */ - public function get_source_id( $source, $attributes = array() ) { - $id = get_the_ID(); - - if ( 'next-post' === $source ) { - $in_same_term = ! empty( $attributes['gpDynamicSourceInSameTerm'] ) ? true : false; - $term_taxonomy = ! empty( $attributes['gpDynamicSourceInSameTermTaxonomy'] ) ? $attributes['gpDynamicSourceInSameTermTaxonomy'] : 'category'; - $next_post = get_next_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $next_post ) ) { - return false; - } - - $id = $next_post->ID; - } - - if ( 'previous-post' === $source ) { - $in_same_term = ! empty( $attributes['gpDynamicSourceInSameTerm'] ) ? true : false; - $term_taxonomy = ! empty( $attributes['gpDynamicSourceInSameTermTaxonomy'] ) ? $attributes['gpDynamicSourceInSameTermTaxonomy'] : 'category'; - $previous_post = get_previous_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $previous_post ) ) { - return false; - } - - $id = $previous_post->ID; - } - - return apply_filters( 'generate_dynamic_element_source_id', $id, $source, $attributes ); - } - - /** - * Get our author ID. - * - * @param string $source The source attribute. - * @param array $attributes All block attributes. - */ - public function get_author_id( $source, $attributes ) { - global $post; - $post_info = $post; - - if ( 'next-post' === $source ) { - $in_same_term = ! empty( $attributes['gpDynamicSourceInSameTerm'] ) ? true : false; - $term_taxonomy = ! empty( $attributes['gpDynamicSourceInSameTermTaxonomy'] ) ? $attributes['gpDynamicSourceInSameTermTaxonomy'] : 'category'; - $next_post = get_next_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $next_post ) ) { - return ''; - } - - $post_info = $next_post; - } - - if ( 'previous-post' === $source ) { - $in_same_term = ! empty( $attributes['gpDynamicSourceInSameTerm'] ) ? true : false; - $term_taxonomy = ! empty( $attributes['gpDynamicSourceInSameTermTaxonomy'] ) ? $attributes['gpDynamicSourceInSameTermTaxonomy'] : 'category'; - $previous_post = get_previous_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $previous_post ) ) { - return ''; - } - - $post_info = $previous_post; - } - - if ( isset( $post_info->post_author ) ) { - return $post_info->post_author; - } - } - - /** - * Register our post meta. - */ - public function register_meta() { - register_meta( - 'post', - '_generate_block_element_editor_width', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_int' ), - ) - ); - - register_meta( - 'post', - '_generate_block_element_editor_width_unit', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - register_meta( - 'post', - '_generate_block_type', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - register_meta( - 'post', - '_generate_hook', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - register_meta( - 'post', - '_generate_custom_hook', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_custom_hook' ), - ) - ); - - register_meta( - 'post', - '_generate_hook_priority', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_int' ), - ) - ); - - register_meta( - 'post', - '_generate_post_meta_location', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_text_field' ), - ) - ); - - register_meta( - 'post', - '_generate_post_loop_item_tagname', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_text_field' ), - ) - ); - - register_meta( - 'post', - '_generate_disable_primary_post_meta', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_disable_secondary_post_meta', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_disable_title', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_disable_featured_image', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_use_theme_post_container', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_use_archive_navigation_container', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_disable_post_navigation', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_disable_archive_navigation', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'boolean', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'rest_sanitize_boolean' ), - ) - ); - - register_meta( - 'post', - '_generate_post_loop_item_display', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_text_field' ), - ) - ); - - register_meta( - 'post', - '_generate_post_loop_item_display_tax', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_text_field' ), - ) - ); - - register_meta( - 'post', - '_generate_post_loop_item_display_term', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_text_field' ), - ) - ); - - register_meta( - 'post', - '_generate_post_loop_item_display_post_meta', - array( - 'object_subtype' => 'gp_elements', - 'type' => 'string', - 'show_in_rest' => true, - 'auth_callback' => '__return_true', - 'single' => true, - 'sanitize_callback' => array( $this, 'sanitize_text_field' ), - ) - ); - } - - /** - * Sanitize our custom hook field. - * - * @param string $value The value to sanitize. - */ - public function sanitize_custom_hook( $value ) { - $not_allowed = array( - 'muplugins_loaded', - 'registered_taxonomy', - 'plugins_loaded', - 'setup_theme', - 'after_setup_theme', - 'init', - 'widgets_init', - 'wp_loaded', - 'pre_get_posts', - 'wp', - 'template_redirect', - 'get_header', - 'wp_enqueue_scripts', - 'the_post', - 'dynamic_sidebar', - 'get_footer', - 'get_sidebar', - 'wp_print_footer_scripts', - 'shutdown', - ); - - if ( in_array( $value, $not_allowed ) ) { - return ''; - } - - return sanitize_key( $value ); - } - - /** - * Sanitize number values that can be empty. - * - * @param int $value The value to sanitize. - */ - public function sanitize_int( $value ) { - if ( ! is_numeric( $value ) ) { - return ''; - } - - return absint( $value ); - } - - /** - * Get our image size names and dimensions. - */ - public function get_image_sizes() { - global $_wp_additional_image_sizes; - - $default_image_sizes = get_intermediate_image_sizes(); - - foreach ( $default_image_sizes as $size ) { - $image_sizes[ $size ]['width'] = intval( get_option( "{$size}_size_w" ) ); - $image_sizes[ $size ]['height'] = intval( get_option( "{$size}_size_h" ) ); - $image_sizes[ $size ]['crop'] = get_option( "{$size}_crop" ) ? get_option( "{$size}_crop" ) : false; - } - - if ( isset( $_wp_additional_image_sizes ) && count( $_wp_additional_image_sizes ) ) { - $image_sizes = array_merge( $image_sizes, $_wp_additional_image_sizes ); - } - - return $image_sizes; - } - - /** - * Add front-end CSS. - */ - public function frontend_css() { - require_once GP_LIBRARY_DIRECTORY . 'class-make-css.php'; - $css = new GeneratePress_Pro_CSS(); - - $css->set_selector( '.dynamic-author-image-rounded' ); - $css->add_property( 'border-radius', '100%' ); - - $css->set_selector( '.dynamic-featured-image, .dynamic-author-image' ); - $css->add_property( 'vertical-align', 'middle' ); - - $css->set_selector( '.one-container.blog .dynamic-content-template:not(:last-child), .one-container.archive .dynamic-content-template:not(:last-child)' ); - $css->add_property( 'padding-bottom', '0px' ); - - $css->set_selector( '.dynamic-entry-excerpt > p:last-child' ); - $css->add_property( 'margin-bottom', '0px' ); - - wp_add_inline_style( 'generate-style', $css->css_output() ); - } -} - -GeneratePress_Block_Elements::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-block.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-block.php deleted file mode 100644 index 051d8e43..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-block.php +++ /dev/null @@ -1,469 +0,0 @@ -post_id = $post_id; - $this->type = get_post_meta( $post_id, '_generate_block_type', true ); - $has_content_template_condition = get_post_meta( $post_id, '_generate_post_loop_item_display', true ); - - // Take over the $post_id temporarily if this is a child block. - // This allows us to inherit the parent block Display Rules. - if ( 'content-template' === $this->type && $has_content_template_condition ) { - $parent_block = wp_get_post_parent_id( $post_id ); - - if ( ! empty( $parent_block ) ) { - $this->has_parent = true; - $post_id = $parent_block; - } - } - - $display_conditions = get_post_meta( $post_id, '_generate_element_display_conditions', true ) ? get_post_meta( $post_id, '_generate_element_display_conditions', true ) : array(); - $exclude_conditions = get_post_meta( $post_id, '_generate_element_exclude_conditions', true ) ? get_post_meta( $post_id, '_generate_element_exclude_conditions', true ) : array(); - $user_conditions = get_post_meta( $post_id, '_generate_element_user_conditions', true ) ? get_post_meta( $post_id, '_generate_element_user_conditions', true ) : array(); - - $display = apply_filters( - 'generate_block_element_display', - GeneratePress_Conditions::show_data( - $display_conditions, - $exclude_conditions, - $user_conditions - ), - $post_id - ); - - /** - * Simplify filter name. - * - * @since 2.0.0 - */ - $display = apply_filters( - 'generate_element_display', - $display, - $post_id - ); - - // Restore our actual post ID if it's been changed. - if ( 'content-template' === $this->type && $has_content_template_condition ) { - $post_id = $this->post_id; - } - - if ( $display ) { - global $generate_elements; - - $generate_elements[ $post_id ] = array( - 'is_block_element' => true, - 'type' => $this->type, - 'id' => $post_id, - ); - - $hook = get_post_meta( $post_id, '_generate_hook', true ); - $custom_hook = get_post_meta( $post_id, '_generate_custom_hook', true ); - $priority = get_post_meta( $post_id, '_generate_hook_priority', true ); - - if ( '' === $priority ) { - $priority = 10; - } - - switch ( $this->type ) { - case 'site-header': - $hook = 'generate_header'; - break; - - case 'site-footer': - $hook = 'generate_footer'; - break; - - case 'right-sidebar': - $hook = 'generate_before_right_sidebar_content'; - break; - - case 'left-sidebar': - $hook = 'generate_before_left_sidebar_content'; - break; - - case 'content-template': - $hook = 'generate_before_do_template_part'; - break; - - case 'loop-template': - $hook = 'generate_before_main_content'; - break; - - case 'search-modal': - $hook = 'generate_inside_search_modal'; - break; - } - - if ( 'custom' === $hook && $custom_hook ) { - $hook = $custom_hook; - } - - if ( 'post-meta-template' === $this->type ) { - $post_meta_location = get_post_meta( $post_id, '_generate_post_meta_location', true ); - - if ( '' === $post_meta_location || 'after-post-title' === $post_meta_location ) { - $hook = 'generate_after_entry_title'; - - if ( is_page() ) { - $hook = 'generate_after_page_title'; - } - } elseif ( 'before-post-title' === $post_meta_location ) { - $hook = 'generate_before_entry_title'; - - if ( is_page() ) { - $hook = 'generate_before_page_title'; - } - } elseif ( 'after-content' === $post_meta_location ) { - $hook = 'generate_after_content'; - } - } - - if ( ! $hook ) { - return; - } - - if ( 'generate_header' === $hook ) { - remove_action( 'generate_header', 'generate_construct_header' ); - } - - if ( 'generate_footer' === $hook ) { - remove_action( 'generate_footer', 'generate_construct_footer' ); - } - - if ( 'content-template' === $this->type && ! $this->has_parent ) { - add_filter( 'generate_do_template_part', array( $this, 'do_template_part' ) ); - } - - if ( 'loop-template' === $this->type ) { - add_filter( 'generate_has_default_loop', '__return_false' ); - add_filter( 'generate_blog_columns', '__return_false' ); - add_filter( 'option_generate_blog_settings', array( $this, 'filter_blog_settings' ) ); - add_filter( 'post_class', array( $this, 'post_classes' ) ); - } - - if ( 'search-modal' === $this->type ) { - remove_action( 'generate_inside_search_modal', 'generate_do_search_fields' ); - } - - add_action( 'wp', array( $this, 'remove_elements' ), 100 ); - add_action( esc_attr( $hook ), array( $this, 'build_hook' ), absint( $priority ) ); - add_filter( 'generateblocks_do_content', array( $this, 'do_block_content' ) ); - } - } - - /** - * Disable our post loop items if needed. - * - * @param boolean $do Whether to display the default post loop item or not. - */ - public function do_template_part( $do ) { - if ( GeneratePress_Elements_Helper::should_render_content_template( $this->post_id ) ) { - return false; - } - - return $do; - } - - /** - * Tell GenerateBlocks about our block element content so it can build CSS. - * - * @since 1.11.0 - * @param string $content The existing content. - */ - public function do_block_content( $content ) { - if ( has_blocks( $this->post_id ) ) { - $block_element = get_post( $this->post_id ); - - if ( ! $block_element || 'gp_elements' !== $block_element->post_type ) { - return $content; - } - - if ( 'publish' !== $block_element->post_status || ! empty( $block_element->post_password ) ) { - return $content; - } - - $content .= $block_element->post_content; - } - - return $content; - } - - /** - * Remove existing sidebar widgets. - * - * @since 1.11.0 - * @param array $widgets The existing widgets. - */ - public function remove_sidebar_widgets( $widgets ) { - if ( 'right-sidebar' === $this->type ) { - unset( $widgets['sidebar-1'] ); - } - - if ( 'left-sidebar' === $this->type ) { - unset( $widgets['sidebar-2'] ); - } - - return $widgets; - } - - /** - * Filter some of our blog settings. - * - * @param array $settings Existing blog settings. - */ - public function filter_blog_settings( $settings ) { - if ( 'loop-template' === $this->type ) { - $settings['infinite_scroll'] = false; - $settings['read_more_button'] = false; - } - - return $settings; - } - - /** - * Add class to our loop template item posts. - * - * @param array $classes Post classes. - */ - public function post_classes( $classes ) { - if ( 'loop-template' === $this->type && is_main_query() ) { - $classes[] = 'is-loop-template-item'; - } - - return $classes; - } - - /** - * Remove existing elements. - * - * @since 2.0.0 - */ - public function remove_elements() { - if ( 'right-sidebar' === $this->type || 'left-sidebar' === $this->type ) { - add_filter( 'sidebars_widgets', array( $this, 'remove_sidebar_widgets' ) ); - add_filter( 'generate_show_default_sidebar_widgets', '__return_false' ); - } - - if ( 'page-hero' === $this->type ) { - $disable_title = get_post_meta( $this->post_id, '_generate_disable_title', true ); - $disable_featured_image = get_post_meta( $this->post_id, '_generate_disable_featured_image', true ); - $disable_primary_post_meta = get_post_meta( $this->post_id, '_generate_disable_primary_post_meta', true ); - - if ( $disable_title ) { - if ( is_singular() ) { - add_filter( 'generate_show_title', '__return_false' ); - } - - remove_action( 'generate_archive_title', 'generate_archive_title' ); - remove_filter( 'get_the_archive_title', 'generate_filter_the_archive_title' ); - - // WooCommerce removal. - if ( class_exists( 'WooCommerce' ) ) { - remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_title', 5 ); - add_filter( 'woocommerce_show_page_title', '__return_false' ); - remove_action( 'woocommerce_archive_description', 'woocommerce_taxonomy_archive_description' ); - remove_action( 'woocommerce_archive_description', 'woocommerce_product_archive_description' ); - } - } - - if ( $disable_primary_post_meta ) { - remove_action( 'generate_after_entry_title', 'generate_post_meta' ); - } - - if ( $disable_featured_image && is_singular() ) { - remove_action( 'generate_after_entry_header', 'generate_blog_single_featured_image' ); - remove_action( 'generate_before_content', 'generate_blog_single_featured_image' ); - remove_action( 'generate_after_header', 'generate_blog_single_featured_image' ); - remove_action( 'generate_before_content', 'generate_featured_page_header_inside_single' ); - remove_action( 'generate_after_header', 'generate_featured_page_header' ); - } - } - - if ( 'post-meta-template' === $this->type ) { - $post_meta_location = get_post_meta( $this->post_id, '_generate_post_meta_location', true ); - $disable_primary_post_meta = get_post_meta( $this->post_id, '_generate_disable_primary_post_meta', true ); - $disable_secondary_post_meta = get_post_meta( $this->post_id, '_generate_disable_secondary_post_meta', true ); - - if ( '' === $post_meta_location || 'after-post-title' === $post_meta_location || 'custom' === $post_meta_location ) { - if ( $disable_primary_post_meta ) { - remove_action( 'generate_after_entry_title', 'generate_post_meta' ); - } - } elseif ( 'before-post-title' === $post_meta_location || 'custom' === $post_meta_location ) { - if ( $disable_primary_post_meta ) { - remove_action( 'generate_after_entry_title', 'generate_post_meta' ); - } - } elseif ( 'after-content' === $post_meta_location || 'custom' === $post_meta_location ) { - if ( $disable_secondary_post_meta ) { - remove_action( 'generate_after_entry_content', 'generate_footer_meta' ); - } - } - } - - if ( 'post-navigation-template' === $this->type ) { - $disable_post_navigation = get_post_meta( $this->post_id, '_generate_disable_post_navigation', true ); - - if ( $disable_post_navigation ) { - add_filter( 'generate_footer_entry_meta_items', array( $this, 'disable_post_navigation' ) ); - } - } - - if ( 'archive-navigation-template' === $this->type ) { - $disable_archive_navigation = get_post_meta( $this->post_id, '_generate_disable_archive_navigation', true ); - - if ( $disable_archive_navigation ) { - remove_action( 'generate_after_loop', 'generate_do_post_navigation' ); - } - } - } - - /** - * Disable post navigation. - * - * @param array $items The post meta items. - */ - public function disable_post_navigation( $items ) { - return array_diff( $items, array( 'post-navigation' ) ); - } - - /** - * Builds the HTML structure for Page Headers. - * - * @since 1.11.0 - */ - public function build_hook() { - $post_id = $this->post_id; - - if ( 'content-template' === $this->type ) { - // Check for child templates if this isn't already one. - if ( ! $this->has_parent ) { - $children = get_posts( - array( - 'post_type' => 'gp_elements', - 'post_parent' => $post_id, - 'order' => 'ASC', - 'orderby' => 'menu_order', - 'no_found_rows' => true, - 'post_status' => 'publish', - 'numberposts' => 20, - 'fields' => 'ids', - ) - ); - - if ( ! empty( $children ) ) { - // Loop through any child templates and overwrite $post_id if applicable. - foreach ( (array) $children as $child_id ) { - if ( GeneratePress_Elements_Helper::should_render_content_template( $child_id ) ) { - $post_id = $child_id; - break; - } - } - } else { - // No children, check if parent should render. - if ( ! GeneratePress_Elements_Helper::should_render_content_template( $post_id ) ) { - return; - } - } - } else { - // No children, check if template should render. - if ( ! GeneratePress_Elements_Helper::should_render_content_template( $post_id ) ) { - return; - } - } - - // Don't display child elements - they will replace the parent element if applicable. - if ( $this->has_parent ) { - return; - } - - $tag_name_value = get_post_meta( $post_id, '_generate_post_loop_item_tagname', true ); - $use_theme_container = get_post_meta( $post_id, '_generate_use_theme_post_container', true ); - - if ( $tag_name_value ) { - $tag_name = $tag_name_value; - } else { - $tag_name = 'article'; - } - - printf( - '<%s id="%s" class="%s">', - esc_attr( $tag_name ), - 'post-' . get_the_ID(), - implode( ' ', get_post_class( 'dynamic-content-template' ) ) // phpcs:ignore -- No escaping needed. - ); - - if ( $use_theme_container ) { - echo '
    '; - } - } - - if ( 'archive-navigation-template' === $this->type || 'post-navigation-template' === $this->type ) { - $use_theme_pagination_container = get_post_meta( $post_id, '_generate_use_archive_navigation_container', true ); - - if ( $use_theme_pagination_container ) { - echo '
    '; - } - } - - echo GeneratePress_Elements_Helper::build_content( $post_id ); // phpcs:ignore -- No escaping needed. - - if ( 'content-template' === $this->type ) { - if ( $use_theme_container ) { - echo '
    '; - } - - echo ''; - } - - if ( 'archive-navigation-template' === $this->type || 'post-navigation-template' === $this->type ) { - $use_theme_pagination_container = get_post_meta( $post_id, '_generate_use_archive_navigation_container', true ); - - if ( $use_theme_pagination_container ) { - echo '
    '; - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-conditions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-conditions.php deleted file mode 100644 index 759d1f81..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-conditions.php +++ /dev/null @@ -1,447 +0,0 @@ - array( - 'label' => esc_attr__( 'General', 'gp-premium' ), - 'locations' => array( - 'general:site' => esc_attr__( 'Entire Site', 'gp-premium' ), - 'general:front_page' => esc_attr__( 'Front Page', 'gp-premium' ), - 'general:blog' => esc_attr__( 'Blog', 'gp-premium' ), - 'general:singular' => esc_attr__( 'All Singular', 'gp-premium' ), - 'general:archive' => esc_attr__( 'All Archives', 'gp-premium' ), - 'general:author' => esc_attr__( 'Author Archives', 'gp-premium' ), - 'general:date' => esc_attr__( 'Date Archives', 'gp-premium' ), - 'general:search' => esc_attr__( 'Search Results', 'gp-premium' ), - 'general:no_results' => esc_attr__( 'No Search Results', 'gp-premium' ), - 'general:404' => esc_attr__( '404 Template', 'gp-premium' ), - 'general:is_paged' => esc_attr__( 'Paginated Results', 'gp-premium' ), - ), - ), - ); - - // Add the post types. - $post_types = get_post_types( - array( - 'public' => true, - ), - 'objects' - ); - - foreach ( $post_types as $post_type_slug => $post_type ) { - - if ( in_array( $post_type_slug, array( 'fl-theme-layout' ) ) ) { - continue; - } - - $post_type_object = get_post_type_object( $post_type_slug ); - $counts = wp_count_posts( $post_type_slug ); - $count = $counts->publish + $counts->future + $counts->draft + $counts->pending + $counts->private; - - // Add the post type. - $types[ $post_type_slug ] = array( - 'label' => esc_html( $post_type->labels->name ), - 'locations' => array( - 'post:' . $post_type_slug => esc_html( $post_type->labels->singular_name ), - ), - ); - - // Add the post type archive. - // We add this regardless of `has_archive` as we deal with that after taxonomies are added. - $types[ $post_type_slug . '_archive' ] = array( - /* translators: post type name */ - 'label' => sprintf( esc_html_x( '%s Archives', '%s is a singular post type name', 'gp-premium' ), $post_type->labels->singular_name ), - 'locations' => array( - /* translators: post type name */ - 'archive:' . $post_type_slug => sprintf( esc_html_x( '%s Archive', '%s is a singular post type name', 'gp-premium' ), $post_type->labels->singular_name ), - ), - ); - - // Add the taxonomies for the post type. - $taxonomies = get_object_taxonomies( $post_type_slug, 'objects' ); - - foreach ( $taxonomies as $taxonomy_slug => $taxonomy ) { - - $public = $taxonomy->public && $taxonomy->show_ui; - - if ( 'post_format' === $taxonomy_slug ) { - continue; - } elseif ( ! apply_filters( 'generate_elements_show_taxonomy', $public, $taxonomy ) ) { - continue; - } - - $label = str_replace( - array( - $post_type->labels->name, - $post_type->labels->singular_name, - ), - '', - $taxonomy->labels->singular_name - ); - - if ( isset( $types[ $post_type_slug . '_archive' ]['locations'] ) ) { - /* translators: '%1$s is post type label. %2$s is taxonomy label. */ - $types[ $post_type_slug . '_archive' ]['locations'][ 'taxonomy:' . $taxonomy_slug ] = sprintf( esc_html_x( '%1$s %2$s Archive', '%1$s is post type label. %2$s is taxonomy label.', 'gp-premium' ), $post_type->labels->singular_name, $label ); - } - - if ( isset( $types[ $post_type_slug ]['locations'] ) ) { - $types[ $post_type_slug ]['locations'][ $post_type_slug . ':taxonomy:' . $taxonomy_slug ] = esc_html( $post_type->labels->singular_name . ' ' . $label ); - } - } - - // Remove the archives location if `has_archive` is set to false. - if ( 'post' !== $post_type_slug && empty( $post_type_object->has_archive ) ) { - unset( $types[ $post_type_slug . '_archive' ]['locations'][ 'archive:' . $post_type_slug ] ); - } - - // Remove the entire item if no locations exist. - if ( 0 === count( (array) $types[ $post_type_slug . '_archive' ]['locations'] ) ) { - unset( $types[ $post_type_slug . '_archive' ] ); - } - } - - return $types; - } - - /** - * Output our available user conditions. - * - * @since 1.7 - * - * @return array - */ - public static function get_user_conditions() { - $rules = array( - 'general' => array( - 'label' => esc_attr__( 'General', 'gp-premium' ), - 'rules' => array( - 'general:all' => esc_attr__( 'All Users', 'gp-premium' ), - 'general:logged_in' => esc_attr__( 'Logged In', 'gp-premium' ), - 'general:logged_out' => esc_attr__( 'Logged Out', 'gp-premium' ), - ), - ), - 'role' => array( - 'label' => esc_attr__( 'Roles', 'gp-premium' ), - 'rules' => array(), - ), - ); - - $roles = get_editable_roles(); - - foreach ( $roles as $slug => $data ) { - $rules['role']['rules'][ $slug ] = $data['name']; - } - - return $rules; - } - - /** - * Get our current location. - * - * @since 1.7 - * - * @return array - */ - public static function get_current_location() { - global $wp_query; - global $post; - - $location = null; - $object = null; - $queried_object = get_queried_object(); - - // Get the location string. - if ( is_front_page() ) { - $location = 'general:front_page'; - } elseif ( is_home() ) { - $location = 'general:blog'; - } elseif ( is_author() ) { - $location = 'general:author'; - } elseif ( is_date() ) { - $location = 'general:date'; - } elseif ( is_search() ) { - $location = 'general:search'; - - global $wp_query; - - if ( 0 === $wp_query->found_posts ) { - $location = 'general:no_results'; - } - } elseif ( is_404() ) { - $location = 'general:404'; - } elseif ( is_category() ) { - - $location = 'taxonomy:category'; - - if ( is_object( $queried_object ) ) { - $object = $queried_object->term_id; - } - } elseif ( is_tag() ) { - - $location = 'taxonomy:post_tag'; - - if ( is_object( $queried_object ) ) { - $object = $queried_object->term_id; - } - } elseif ( is_tax() ) { - - $location = 'taxonomy:' . get_query_var( 'taxonomy' ); - - if ( is_object( $queried_object ) ) { - $location = 'taxonomy:' . $queried_object->taxonomy; - $object = $queried_object->term_id; - } - } elseif ( is_post_type_archive() ) { - $post_type = $wp_query->get( 'post_type' ); - - if ( is_array( $post_type ) ) { - $location = 'archive:' . $post_type[0]; - } else { - $location = 'archive:' . $post_type; - } - } elseif ( is_singular() ) { - - if ( is_object( $post ) ) { - $location = 'post:' . $post->post_type; - } - - if ( is_object( $queried_object ) ) { - $object = $queried_object->ID; - } - } - - if ( is_admin() && function_exists( 'get_current_screen' ) ) { - $current_screen = get_current_screen(); - - if ( isset( $current_screen->is_block_editor ) && $current_screen->is_block_editor ) { - $post_id = false; - - if ( isset( $_GET['post'] ) ) { // phpcs:ignore -- Just checking if it's set. - $post_id = absint( $_GET['post'] ); // phpcs:ignore -- No data processing going on. - } - - if ( $post_id ) { - // Get the location string. - $front_page_id = get_option( 'page_on_front' ); - $blog_id = get_option( 'page_for_posts' ); - - if ( (int) $post_id === (int) $front_page_id ) { - $location = 'general:front_page'; - } elseif ( (int) $post_id === (int) $blog_id ) { - $location = 'general:blog'; - } else { - if ( isset( $current_screen->post_type ) ) { - $location = 'post:' . $current_screen->post_type; - } - - $object = $post_id; - } - } elseif ( isset( $_GET['post_type'] ) ) { // phpcs:ignore -- Just checking if it's set. - $location = 'post:' . esc_attr( $_GET['post_type'] ); // phpcs:ignore -- No data processing going on. - } - } - } - - return array( - 'rule' => $location, - 'object' => $object, - ); - } - - /** - * Get info on the current user. - * - * @since 1.7 - * - * @return array - */ - public static function get_current_user() { - $status = array(); - if ( is_user_logged_in() ) { - $status[] = 'general:logged_in'; - } else { - $status[] = 'general:logged_out'; - } - - $user = wp_get_current_user(); - - foreach ( (array) $user->roles as $role ) { - $status[] = $role; - } - - return $status; - } - - /** - * Figure out if we should display the element or not. - * - * @since 1.7 - * - * @param array $conditionals The conditions. - * @param array $exclude The exclusions. - * @param array $roles The roles. - * @return bool - */ - public static function show_data( $conditionals, $exclude, $roles ) { - $current_location = self::get_current_location(); - $show = false; - - // Show depending on location conditionals. - if ( ! $show ) { - foreach ( (array) $conditionals as $conditional ) { - if ( in_array( 'general:site', $conditional ) ) { - $show = true; - } elseif ( is_singular() && in_array( 'general:singular', $conditional ) ) { - $show = true; - } elseif ( is_archive() && in_array( 'general:archive', $conditional ) ) { - $show = true; - } elseif ( ! empty( $current_location['rule'] ) && in_array( $current_location['rule'], $conditional ) ) { - if ( ! isset( $conditional['object'] ) || empty( $conditional['object'] ) ) { - $show = true; - } else { - if ( in_array( $current_location['object'], $conditional ) ) { - $show = true; - } - } - } elseif ( is_singular() && strstr( $conditional['rule'], ':taxonomy:' ) ) { - $tax = substr( $conditional['rule'], strrpos( $conditional['rule'], ':' ) + 1 ); - - if ( $tax && isset( $conditional['object'] ) && has_term( $conditional['object'], $tax ) ) { - $show = true; - } - } elseif ( is_front_page() && is_home() && ( in_array( 'general:blog', $conditional ) || in_array( 'general:front_page', $conditional ) ) ) { - // If the home page is the blog, both of general:blog and general:front_page apply. - $show = true; - } elseif ( in_array( 'general:is_paged', $conditional ) && is_paged() ) { - $show = true; - } - } - } - - // Exclude based on exclusion conditionals. - if ( $show ) { - foreach ( (array) $exclude as $conditional ) { - if ( is_singular() && in_array( 'general:singular', $conditional ) ) { - $show = false; - } elseif ( is_archive() && in_array( 'general:archive', $conditional ) ) { - $show = false; - } elseif ( ! empty( $current_location['rule'] ) && in_array( $current_location['rule'], $conditional ) ) { - if ( ! isset( $conditional['object'] ) || empty( $conditional['object'] ) ) { - $show = false; - } else { - if ( in_array( $current_location['object'], $conditional ) ) { - $show = false; - } - } - } elseif ( is_singular() && strstr( $conditional['rule'], ':taxonomy:' ) ) { - $tax = substr( $conditional['rule'], strrpos( $conditional['rule'], ':' ) + 1 ); - - if ( $tax && isset( $conditional['object'] ) && has_term( $conditional['object'], $tax ) ) { - $show = false; - } - } elseif ( is_front_page() && is_home() && ( in_array( 'general:blog', $conditional ) || in_array( 'general:front_page', $conditional ) ) ) { - // If the home page is the blog, both of general:blog and general:front_page apply. - $show = false; - } elseif ( in_array( 'general:is_paged', $conditional ) && is_paged() ) { - $show = false; - } - } - } - - // Exclude user roles. - if ( $show && ! empty( $roles ) ) { - $user_info = self::get_current_user(); - - $check = array_intersect( $roles, $user_info ); - if ( ! count( $check ) > 0 && ! in_array( 'general:all', $roles ) ) { - $show = false; - } - } - - return $show; - } - - /** - * Returns the label for a saved location. - * - * @since 1.7 - * @param string $saved_location The location. - * @return string|bool - */ - public static function get_saved_label( $saved_location ) { - $locations = self::get_conditions(); - - $rule = $saved_location['rule']; - $object_id = $saved_location['object']; - $object_type = ''; - $label = false; - - foreach ( $locations as $data ) { - if ( isset( $data['locations'][ $rule ] ) && ! $label ) { - $label = $data['locations'][ $rule ]; - - $object_types = explode( ':', $rule ); - - if ( in_array( 'taxonomy', $object_types ) && $object_id ) { - $term = get_term( $object_id ); - - if ( ! is_object( $term ) || is_wp_error( $term ) ) { - return false; - } - - $label .= ': ' . $term->name; - } elseif ( ( in_array( 'post', $object_types ) || in_array( 'page', $object_types ) ) && $object_id ) { - $post = get_post( $object_id ); - - if ( ! is_object( $post ) ) { - return false; - } - - $label .= ': ' . $post->post_title; - } - } - } - - return $label; - } -} - -GeneratePress_Conditions::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-elements-helper.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-elements-helper.php deleted file mode 100644 index 052f2687..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-elements-helper.php +++ /dev/null @@ -1,527 +0,0 @@ -post_type ) { - return ''; - } - - if ( 'publish' !== $block_element->post_status || ! empty( $block_element->post_password ) ) { - return ''; - } - - $block_type = get_post_meta( $id, '_generate_block_type', true ); - - if ( 'site-footer' === $block_type ) { - $block_element->post_content = str_replace( '{{current_year}}', date( 'Y' ), $block_element->post_content ); // phpcs:ignore -- Prefer date(). - } - - // Handle embeds for block elements. - global $wp_embed; - - if ( is_object( $wp_embed ) && method_exists( $wp_embed, 'autoembed' ) ) { - $block_element->post_content = $wp_embed->autoembed( $block_element->post_content ); - } - - return apply_filters( 'generate_do_block_element_content', do_blocks( $block_element->post_content ) ); - } - - /** - * Get our Element type label. - * - * @since 2.0.0 - * @param string $type The type value. - */ - public static function get_element_type_label( $type ) { - switch ( $type ) { - case 'block': - $label = __( 'Block', 'gp-premium' ); - break; - - case 'header': - $label = __( 'Header', 'gp-premium' ); - break; - - case 'hook': - $label = __( 'Hook', 'gp-premium' ); - break; - - case 'layout': - $label = __( 'Layout', 'gp-premium' ); - break; - - case 'site-header': - $label = __( 'Site Header', 'gp-premium' ); - break; - - case 'page-hero': - $label = __( 'Page Hero', 'gp-premium' ); - break; - - case 'content-template': - $label = __( 'Content Template', 'gp-premium' ); - break; - - case 'loop-template': - $label = __( 'Loop Template', 'gp-premium' ); - break; - - case 'post-meta-template': - $label = __( 'Post Meta Template', 'gp-premium' ); - break; - - case 'post-navigation-template': - $label = __( 'Post Navigation', 'gp-premium' ); - break; - - case 'archive-navigation-template': - $label = __( 'Archive Navigation', 'gp-premium' ); - break; - - case 'right-sidebar': - $label = __( 'Right Sidebar', 'gp-premium' ); - break; - - case 'left-sidebar': - $label = __( 'Left Sidebar', 'gp-premium' ); - break; - - case 'site-footer': - $label = __( 'Site Footer', 'gp-premium' ); - break; - - default: - $label = esc_html( str_replace( '-', ' ', ucfirst( $type ) ) ); - break; - } - - return $label; - } - - /** - * Check for content template conditions. - * - * @since 2.0.0 - * @param int $post_id The post to check. - */ - public static function should_render_content_template( $post_id ) { - $loop_item_display = get_post_meta( $post_id, '_generate_post_loop_item_display', true ); - $display = true; - - if ( 'has-term' === $loop_item_display ) { - $tax = get_post_meta( $post_id, '_generate_post_loop_item_display_tax', true ); - - if ( $tax ) { - $term = get_post_meta( $post_id, '_generate_post_loop_item_display_term', true ); - - // Add support for multiple comma separated terms. - if ( ! empty( $term ) ) { - $term = str_replace( ' ', '', $term ); - $term = explode( ',', $term ); - } - - if ( has_term( $term, $tax ) ) { - $display = true; - } else { - $display = false; - } - } - } - - if ( 'has-post-meta' === $loop_item_display ) { - $post_meta_name = get_post_meta( $post_id, '_generate_post_loop_item_display_post_meta', true ); - - if ( $post_meta_name ) { - $post_meta = get_post_meta( get_the_ID(), $post_meta_name, true ); - - if ( $post_meta ) { - $display = true; - } else { - $display = false; - } - } - } - - if ( 'is-first-post' === $loop_item_display ) { - global $wp_query; - - if ( 0 === $wp_query->current_post && ! is_paged() ) { - $display = true; - } else { - $display = false; - } - } - - return apply_filters( 'generate_should_render_content_template', $display, $post_id ); - } - - /** - * Build our entire list of hooks to display. - * - * @since 1.7 - * - * @return array Our list of hooks. - */ - public static function get_available_hooks() { - $hooks = array( - 'scripts' => array( - 'group' => esc_attr__( 'Scripts/Styles', 'gp-premium' ), - 'hooks' => array( - 'wp_head', - 'wp_body_open', - 'wp_footer', - ), - ), - 'header' => array( - 'group' => esc_attr__( 'Header', 'gp-premium' ), - 'hooks' => array( - 'generate_before_header', - 'generate_after_header', - 'generate_before_header_content', - 'generate_after_header_content', - 'generate_before_logo', - 'generate_after_logo', - 'generate_header', - ), - ), - 'navigation' => array( - 'group' => esc_attr__( 'Navigation', 'gp-premium' ), - 'hooks' => array( - 'generate_inside_navigation', - 'generate_after_primary_menu', - 'generate_inside_secondary_navigation', - 'generate_inside_mobile_menu', - 'generate_inside_mobile_menu_bar', - 'generate_inside_mobile_header', - 'generate_inside_slideout_navigation', - 'generate_after_slideout_navigation', - ), - ), - 'content' => array( - 'group' => esc_attr__( 'Content', 'gp-premium' ), - 'hooks' => array( - 'generate_inside_site_container', - 'generate_inside_container', - 'generate_before_main_content', - 'generate_after_main_content', - 'generate_before_content', - 'generate_after_content', - 'generate_after_entry_content', - 'generate_after_primary_content_area', - 'generate_before_entry_title', - 'generate_after_entry_title', - 'generate_after_entry_header', - 'generate_before_archive_title', - 'generate_after_archive_title', - 'generate_after_archive_description', - ), - ), - 'comments' => array( - 'group' => esc_attr__( 'Comments', 'gp-premium' ), - 'hooks' => array( - 'generate_before_comments_container', - 'generate_before_comments', - 'generate_inside_comments', - 'generate_below_comments_title', - ), - ), - 'sidebars' => array( - 'group' => esc_attr__( 'Sidebars', 'gp-premium' ), - 'hooks' => array( - 'generate_before_right_sidebar_content', - 'generate_after_right_sidebar_content', - 'generate_before_left_sidebar_content', - 'generate_after_left_sidebar_content', - ), - ), - 'footer' => array( - 'group' => esc_attr__( 'Footer', 'gp-premium' ), - 'hooks' => array( - 'generate_before_footer', - 'generate_after_footer', - 'generate_after_footer_widgets', - 'generate_before_footer_content', - 'generate_after_footer_content', - 'generate_footer', - ), - ), - ); - - if ( class_exists( 'WooCommerce' ) ) { - $hooks['navigation']['hooks'][] = 'generate_mobile_cart_items'; - - $hooks['woocommerce-global'] = array( - 'group' => esc_attr__( 'WooCommerce - Global', 'gp-premium' ), - 'hooks' => array( - 'woocommerce_before_main_content', - 'woocommerce_after_main_content', - 'woocommerce_sidebar', - 'woocommerce_breadcrumb', - ), - ); - - $hooks['woocommerce-shop'] = array( - 'group' => esc_attr__( 'WooCommerce - Shop', 'gp-premium' ), - 'hooks' => array( - 'woocommerce_archive_description', - 'woocommerce_before_shop_loop', - 'woocommerce_after_shop_loop', - 'woocommerce_before_shop_loop_item_title', - 'woocommerce_after_shop_loop_item_title', - ), - ); - - $hooks['woocommerce-product'] = array( - 'group' => esc_attr__( 'WooCommerce - Product', 'gp-premium' ), - 'hooks' => array( - 'woocommerce_before_single_product', - 'woocommerce_before_single_product_summary', - 'woocommerce_after_single_product_summary', - 'woocommerce_single_product_summary', - 'woocommerce_share', - 'woocommerce_simple_add_to_cart', - 'woocommerce_before_add_to_cart_form', - 'woocommerce_after_add_to_cart_form', - 'woocommerce_before_add_to_cart_button', - 'woocommerce_after_add_to_cart_button', - 'woocommerce_before_add_to_cart_quantity', - 'woocommerce_after_add_to_cart_quantity', - 'woocommerce_product_meta_start', - 'woocommerce_product_meta_end', - 'woocommerce_after_single_product', - ), - ); - - $hooks['woocommerce-cart'] = array( - 'group' => esc_attr__( 'WooCommerce - Cart', 'gp-premium' ), - 'hooks' => array( - 'woocommerce_before_calculate_totals', - 'woocommerce_after_calculate_totals', - 'woocommerce_before_cart', - 'woocommerce_after_cart_table', - 'woocommerce_before_cart_table', - 'woocommerce_before_cart_contents', - 'woocommerce_cart_contents', - 'woocommerce_after_cart_contents', - 'woocommerce_cart_coupon', - 'woocommerce_cart_actions', - 'woocommerce_before_cart_totals', - 'woocommerce_cart_totals_before_order_total', - 'woocommerce_cart_totals_after_order_total', - 'woocommerce_proceed_to_checkout', - 'woocommerce_after_cart_totals', - 'woocommerce_after_cart', - ), - ); - - $hooks['woocommerce-checkout'] = array( - 'group' => esc_attr__( 'WooCommerce - Checkout', 'gp-premium' ), - 'hooks' => array( - 'woocommerce_before_checkout_form', - 'woocommerce_checkout_before_customer_details', - 'woocommerce_checkout_after_customer_details', - 'woocommerce_checkout_billing', - 'woocommerce_before_checkout_billing_form', - 'woocommerce_after_checkout_billing_form', - 'woocommerce_before_order_notes', - 'woocommerce_after_order_notes', - 'woocommerce_checkout_shipping', - 'woocommerce_checkout_before_order_review', - 'woocommerce_checkout_order_review', - 'woocommerce_review_order_before_cart_contents', - 'woocommerce_review_order_after_cart_contents', - 'woocommerce_review_order_before_order_total', - 'woocommerce_review_order_after_order_total', - 'woocommerce_review_order_before_payment', - 'woocommerce_review_order_before_submit', - 'woocommerce_review_order_after_submit', - 'woocommerce_review_order_after_payment', - 'woocommerce_checkout_after_order_review', - 'woocommerce_after_checkout_form', - ), - ); - - $hooks['woocommerce-account'] = array( - 'group' => esc_attr__( 'WooCommerce - Account', 'gp-premium' ), - 'hooks' => array( - 'woocommerce_before_account_navigation', - 'woocommerce_account_navigation', - 'woocommerce_after_account_navigation', - ), - ); - } - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $hooks['navigation']['hooks'][] = 'generate_menu_bar_items'; - } - - if ( defined( 'GENERATE_VERSION' ) && version_compare( GENERATE_VERSION, '3.0.0-alpha.1', '>' ) ) { - $hooks['navigation']['hooks'][] = 'generate_before_navigation'; - $hooks['navigation']['hooks'][] = 'generate_after_navigation'; - $hooks['navigation']['hooks'][] = 'generate_after_mobile_menu_button'; - $hooks['navigation']['hooks'][] = 'generate_inside_mobile_menu_control_wrapper'; - - $hooks['content']['hooks'][] = 'generate_after_loop'; - $hooks['content']['hooks'][] = 'generate_before_do_template_part'; - $hooks['content']['hooks'][] = 'generate_after_do_template_part'; - } - - return apply_filters( 'generate_hooks_list', $hooks ); - } - - /** - * Expand the wp_kses_post sanitization function to allow iframe HTML tags - * - * @param array $tags The allowed tags, attributes, and/or attribute values. - * @param string $context Context to judge allowed tags by. Allowed values are 'post'. - * @return array - */ - public static function expand_allowed_html( $tags, $context ) { - if ( ! isset( $tags['iframe'] ) ) { - $tags['iframe'] = [ - 'src' => true, - 'height' => true, - 'width' => true, - 'frameborder' => true, - 'allowfullscreen' => true, - 'title' => true, - ]; - } - - $tags = apply_filters( 'generate_dynamic_content_allowed_html', $tags, $context ); - - return $tags; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-hero.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-hero.php deleted file mode 100644 index 631b1185..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-hero.php +++ /dev/null @@ -1,1041 +0,0 @@ -conditional = get_post_meta( $post_id, '_generate_element_display_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_exclude_conditions', true ) ) { - $this->exclude = get_post_meta( $post_id, '_generate_element_exclude_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_user_conditions', true ) ) { - $this->users = get_post_meta( $post_id, '_generate_element_user_conditions', true ); - } - - $display = apply_filters( 'generate_header_element_display', GeneratePress_Conditions::show_data( $this->conditional, $this->exclude, $this->users ), $post_id ); - - /** - * Simplify filter name. - * - * @since 2.0.0 - */ - $display = apply_filters( - 'generate_element_display', - $display, - $post_id - ); - - if ( $display ) { - global $generate_elements; - - $generate_elements[ $post_id ] = array( - 'is_block_element' => false, - 'type' => 'header', - 'id' => $post_id, - ); - - $location = apply_filters( 'generate_page_hero_location', 'generate_after_header', $post_id ); - - add_action( $location, array( $this, 'build_hero' ), 9 ); - add_action( 'wp_enqueue_scripts', array( $this, 'enqueue' ), 100 ); - add_action( 'wp', array( $this, 'after_setup' ), 100 ); - - self::$instances++; - } - - } - - /** - * Add necessary scripts and styles. - * - * @since 1.7 - */ - public function enqueue() { - $options = self::get_options(); - - wp_add_inline_style( 'generate-style', self::build_css() ); - - if ( $options['parallax'] ) { - wp_enqueue_script( 'generate-hero-parallax', plugin_dir_url( __FILE__ ) . 'assets/js/parallax.min.js', array(), GP_PREMIUM_VERSION, true ); - wp_localize_script( - 'generate-hero-parallax', - 'hero', - array( - 'parallax' => apply_filters( 'generate_hero_parallax_speed', 2 ), - ) - ); - } - } - - /** - * Builds the HTML structure for Page Headers. - * - * @since 1.7 - */ - public function build_hero() { - $options = self::get_options(); - - if ( empty( $options['content'] ) ) { - return; - } - - $options['container_classes'] = implode( - ' ', - array( - 'page-hero', - 'contained' === $options['container'] ? 'grid-container grid-parent' : '', - $options['classes'], - ) - ); - - $options['inner_container_classes'] = implode( - ' ', - array( - 'inside-page-hero', - 'full-width' !== $options['inner_container'] ? 'grid-container grid-parent' : '', - ) - ); - - $options['content'] = self::template_tags( $options['content'] ); - $options['content'] = do_shortcode( $options['content'] ); - - // phpcs:ignore -- No escaping needed. - echo apply_filters( - 'generate_page_hero_output', - sprintf( - '
    -
    - %3$s -
    -
    ', - trim( $options['container_classes'] ), - trim( $options['inner_container_classes'] ), - $options['content'] - ), - $options - ); - } - - /** - * Builds all of our custom CSS for Page Headers. - * - * @since 1.7 - * - * @return string Dynamic CSS. - */ - public static function build_css() { - $options = self::get_options(); - - // Initiate our CSS class. - require_once GP_LIBRARY_DIRECTORY . 'class-make-css.php'; - $css = new GeneratePress_Pro_CSS(); - - $image_url = false; - if ( $options['background_image'] && function_exists( 'get_the_post_thumbnail_url' ) ) { - if ( 'featured-image' === $options['background_image'] ) { - if ( is_singular() ) { - $image_url = get_the_post_thumbnail_url( get_the_ID(), 'full' ); - } - - if ( ! $image_url ) { - $image_url = get_the_post_thumbnail_url( self::$post_id, 'full' ); - } - } - - if ( 'custom-image' === $options['background_image'] ) { - $image_url = get_the_post_thumbnail_url( self::$post_id, 'full' ); - } - } - - $image_url = apply_filters( 'generate_page_hero_background_image_url', $image_url, $options ); - - // Figure out desktop units. - $options['padding_top_unit'] = $options['padding_top_unit'] ? $options['padding_top_unit'] : 'px'; - $options['padding_right_unit'] = $options['padding_right_unit'] ? $options['padding_right_unit'] : 'px'; - $options['padding_bottom_unit'] = $options['padding_bottom_unit'] ? $options['padding_bottom_unit'] : 'px'; - $options['padding_left_unit'] = $options['padding_left_unit'] ? $options['padding_left_unit'] : 'px'; - - // Figure out mobile units. - $options['padding_top_unit_mobile'] = $options['padding_top_unit_mobile'] ? $options['padding_top_unit_mobile'] : 'px'; - $options['padding_right_unit_mobile'] = $options['padding_right_unit_mobile'] ? $options['padding_right_unit_mobile'] : 'px'; - $options['padding_bottom_unit_mobile'] = $options['padding_bottom_unit_mobile'] ? $options['padding_bottom_unit_mobile'] : 'px'; - $options['padding_left_unit_mobile'] = $options['padding_left_unit_mobile'] ? $options['padding_left_unit_mobile'] : 'px'; - - $padding_inside = false; - $using_flexbox = false; - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $using_flexbox = true; - - if ( function_exists( 'generate_get_option' ) && 'text' === generate_get_option( 'container_alignment' ) ) { - $padding_inside = true; - } - } - - $css->set_selector( '.page-hero' ); - - if ( $options['background_color'] ) { - $css->add_property( 'background-color', esc_attr( $options['background_color'] ) ); - } - - if ( $image_url ) { - $css->add_property( 'background-image', 'url(' . esc_url( $image_url ) . ')' ); - $css->add_property( 'background-size', 'cover' ); - - if ( $options['background_color'] && $options['background_overlay'] ) { - $css->add_property( 'background-image', 'linear-gradient(0deg, ' . $options['background_color'] . ',' . $options['background_color'] . '), url(' . $image_url . ')' ); - } - - if ( $options['background_position'] ) { - $css->add_property( 'background-position', esc_attr( $options['background_position'] ) ); - } - - $css->add_property( 'background-repeat', 'no-repeat' ); - } - - if ( $options['text_color'] ) { - $css->add_property( 'color', esc_attr( $options['text_color'] ) ); - } - - if ( $options['padding_top'] ) { - $css->add_property( 'padding-top', absint( $options['padding_top'] ), false, esc_html( $options['padding_top_unit'] ) ); - } - - if ( $options['padding_right'] ) { - $css->add_property( 'padding-right', absint( $options['padding_right'] ), false, esc_html( $options['padding_right_unit'] ) ); - } - - if ( $options['padding_bottom'] ) { - $css->add_property( 'padding-bottom', absint( $options['padding_bottom'] ), false, esc_html( $options['padding_bottom_unit'] ) ); - } - - if ( $options['padding_left'] ) { - $css->add_property( 'padding-left', absint( $options['padding_left'] ), false, esc_html( $options['padding_left_unit'] ) ); - } - - if ( $options['horizontal_alignment'] ) { - $css->add_property( 'text-align', esc_html( $options['horizontal_alignment'] ) ); - } - - if ( ! $using_flexbox ) { - $css->add_property( 'box-sizing', 'border-box' ); - } - - if ( $options['site_header_merge'] && $options['full_screen'] ) { - $css->add_property( 'min-height', '100vh' ); - - if ( $options['vertical_alignment'] ) { - $css->add_property( 'display', '-webkit-flex' ); - $css->add_property( 'display', '-ms-flex' ); - $css->add_property( 'display', 'flex' ); - - if ( 'center' === $options['vertical_alignment'] ) { - $css->add_property( '-webkit-box', 'center' ); - $css->add_property( '-ms-flex-pack', 'center' ); - $css->add_property( 'justify-content', 'center' ); - } elseif ( 'bottom' === $options['vertical_alignment'] ) { - $css->add_property( '-webkit-box', 'end' ); - $css->add_property( '-ms-flex-pack', 'end' ); - $css->add_property( 'justify-content', 'flex-end' ); - } - - $css->add_property( '-webkit-box-orient', 'vertical' ); - $css->add_property( '-webkit-box-direction', 'normal' ); - $css->add_property( '-ms-flex-direction', 'column' ); - $css->add_property( 'flex-direction', 'column' ); - - $css->set_selector( '.page-hero .inside-page-hero' ); - $css->add_property( 'width', '100%' ); - } - } - - if ( $padding_inside && function_exists( 'generate_get_option' ) ) { - $container_width = generate_get_option( 'container_width' ); - $padding_right = '0px'; - $padding_left = '0px'; - - if ( $options['padding_right'] ) { - $padding_right = absint( $options['padding_right'] ) . $options['padding_right_unit']; - } - - if ( $options['padding_left'] ) { - $padding_left = absint( $options['padding_left'] ) . $options['padding_left_unit']; - } - - $css->set_selector( '.page-hero .inside-page-hero.grid-container' ); - - $css->add_property( - 'max-width', - sprintf( - 'calc(%1$s - %2$s - %3$s)', - $container_width . 'px', - $padding_right, - $padding_left - ) - ); - } - - $css->set_selector( '.page-hero h1, .page-hero h2, .page-hero h3, .page-hero h4, .page-hero h5, .page-hero h6' ); - if ( $options['text_color'] ) { - $css->add_property( 'color', esc_attr( $options['text_color'] ) ); - } - - $css->set_selector( '.inside-page-hero > *:last-child' ); - $css->add_property( 'margin-bottom', '0px' ); - - $css->set_selector( '.page-hero a, .page-hero a:visited' ); - - if ( $options['link_color'] ) { - $css->add_property( 'color', esc_attr( $options['link_color'] ) ); - } - - if ( $options['content'] ) { - $css->set_selector( '.page-hero time.updated' ); - $css->add_property( 'display', 'none' ); - } - - $css->set_selector( '.page-hero a:hover' ); - - if ( $options['link_color_hover'] ) { - $css->add_property( 'color', esc_attr( $options['link_color_hover'] ) ); - } - - if ( '' !== $options['site_header_merge'] ) { - if ( 'merge-desktop' === $options['site_header_merge'] ) { - $css->start_media_query( apply_filters( 'generate_not_mobile_media_query', '(min-width: 769px)' ) ); - } - - $header_background = $options['header_background_color'] ? $options['header_background_color'] : 'transparent'; - - if ( $options['site_header_height'] ) { - $css->set_selector( '.page-hero' ); - - if ( $options['padding_top'] ) { - $css->add_property( 'padding-top', 'calc(' . absint( $options['padding_top'] ) . esc_html( $options['padding_top_unit'] ) . ' + ' . absint( $options['site_header_height'] ) . 'px)' ); - } else { - $css->add_property( 'padding-top', absint( $options['site_header_height'] ), false, 'px' ); - } - } - - $css->set_selector( '.header-wrap' ); - $css->add_property( 'position', 'absolute' ); - $css->add_property( 'left', '0px' ); - $css->add_property( 'right', '0px' ); - $css->add_property( 'z-index', '10' ); - - $css->set_selector( '.header-wrap .site-header' ); - $css->add_property( 'background', $header_background ); - - $css->set_selector( '.header-wrap .main-title a, .header-wrap .main-title a:hover, .header-wrap .main-title a:visited' ); - $css->add_property( 'color', esc_attr( $options['header_title_color'] ) ); - - if ( ! GeneratePress_Elements_Helper::does_option_exist( 'navigation-as-header' ) ) { - $css->set_selector( '.header-wrap .mobile-header-navigation:not(.navigation-stick):not(.toggled) .main-title a, .header-wrap .mobile-header-navigation:not(.navigation-stick):not(.toggled) .main-title a:hover, .header-wrap .mobile-header-navigation:not(.navigation-stick):not(.toggled) .main-title a:visited' ); - $css->add_property( 'color', esc_attr( $options['header_title_color'] ) ); - } - - if ( function_exists( 'generate_get_color_defaults' ) ) { - $color_settings = wp_parse_args( - get_option( 'generate_settings', array() ), - generate_get_color_defaults() - ); - - if ( GeneratePress_Elements_Helper::does_option_exist( 'navigation-as-header' ) ) { - $css->set_selector( '.header-wrap .toggled .main-title a, .header-wrap .toggled .main-title a:hover, .header-wrap .toggled .main-title a:visited, .header-wrap .navigation-stick .main-title a, .header-wrap .navigation-stick .main-title a:hover, .header-wrap .navigation-stick .main-title a:visited' ); - $css->add_property( 'color', esc_attr( $color_settings['site_title_color'] ) ); - } - } - - $css->set_selector( '.header-wrap .site-description' ); - $css->add_property( 'color', esc_attr( $options['header_tagline_color'] ) ); - - if ( $options['navigation_colors'] ) { - $navigation_background = $options['navigation_background_color'] ? $options['navigation_background_color'] : 'transparent'; - $navigation_background_hover = $options['navigation_background_color_hover'] ? $options['navigation_background_color_hover'] : 'transparent'; - $navigation_background_current = $options['navigation_background_color_current'] ? $options['navigation_background_color_current'] : 'transparent'; - - $css->set_selector( '.header-wrap #site-navigation:not(.toggled), .header-wrap #mobile-header:not(.toggled):not(.navigation-stick), .has-inline-mobile-toggle .mobile-menu-control-wrapper' ); - $css->add_property( 'background', $navigation_background ); - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $css->set_selector( '.header-wrap #site-navigation:not(.toggled) .main-nav > ul > li > a, .header-wrap #mobile-header:not(.toggled):not(.navigation-stick) .main-nav > ul > li > a, .header-wrap .main-navigation:not(.toggled):not(.navigation-stick) .menu-toggle, .header-wrap .main-navigation:not(.toggled):not(.navigation-stick) .menu-toggle:hover, .main-navigation:not(.toggled):not(.navigation-stick) .menu-bar-item:not(.close-search) > a' ); - } else { - $css->set_selector( '.header-wrap #site-navigation:not(.toggled) .main-nav > ul > li > a, .header-wrap #mobile-header:not(.toggled):not(.navigation-stick) .main-nav > ul > li > a, .header-wrap .main-navigation:not(.toggled):not(.navigation-stick) .menu-toggle, .header-wrap .main-navigation:not(.toggled):not(.navigation-stick) .menu-toggle:hover, .main-navigation:not(.toggled):not(.navigation-stick) .mobile-bar-items a, .main-navigation:not(.toggled):not(.navigation-stick) .mobile-bar-items a:hover, .main-navigation:not(.toggled):not(.navigation-stick) .mobile-bar-items a:focus' ); - } - - $css->add_property( 'color', esc_attr( $options['navigation_text_color'] ) ); - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $css->set_selector( '.header-wrap #site-navigation:not(.toggled) .main-nav > ul > li:hover > a, .header-wrap #site-navigation:not(.toggled) .main-nav > ul > li:focus > a, .header-wrap #site-navigation:not(.toggled) .main-nav > ul > li.sfHover > a, .header-wrap #mobile-header:not(.toggled) .main-nav > ul > li:hover > a, .header-wrap #site-navigation:not(.toggled) .menu-bar-item:not(.close-search):hover > a, .header-wrap #mobile-header:not(.toggled) .menu-bar-item:not(.close-search):hover > a, .header-wrap #site-navigation:not(.toggled) .menu-bar-item:not(.close-search).sfHover > a, .header-wrap #mobile-header:not(.toggled) .menu-bar-item:not(.close-search).sfHover > a' ); - } else { - $css->set_selector( '.header-wrap #site-navigation:not(.toggled) .main-nav > ul > li:hover > a, .header-wrap #site-navigation:not(.toggled) .main-nav > ul > li:focus > a, .header-wrap #site-navigation:not(.toggled) .main-nav > ul > li.sfHover > a, .header-wrap #mobile-header:not(.toggled) .main-nav > ul > li:hover > a' ); - } - - $css->add_property( 'background', $navigation_background_hover ); - - if ( '' !== $options['navigation_text_color_hover'] ) { - $css->add_property( 'color', esc_attr( $options['navigation_text_color_hover'] ) ); - } else { - $css->add_property( 'color', esc_attr( $options['navigation_text_color'] ) ); - } - - $css->set_selector( '.header-wrap #site-navigation:not(.toggled) .main-nav > ul > li[class*="current-menu-"] > a, .header-wrap #mobile-header:not(.toggled) .main-nav > ul > li[class*="current-menu-"] > a, .header-wrap #site-navigation:not(.toggled) .main-nav > ul > li[class*="current-menu-"]:hover > a, .header-wrap #mobile-header:not(.toggled) .main-nav > ul > li[class*="current-menu-"]:hover > a' ); - $css->add_property( 'background', $navigation_background_current ); - - if ( '' !== $options['navigation_text_color_current'] ) { - $css->add_property( 'color', esc_attr( $options['navigation_text_color_current'] ) ); - } else { - $css->add_property( 'color', esc_attr( $options['navigation_text_color'] ) ); - } - } - - if ( $options['site_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'navigation-as-header' ) ) { - $css->set_selector( '.main-navigation .site-logo, .main-navigation.toggled .page-hero-logo, .main-navigation.navigation-stick .page-hero-logo' ); - $css->add_property( 'display', 'none' ); - - $css->set_selector( '.main-navigation .page-hero-logo, .main-navigation.toggled .site-logo:not(.page-hero-logo), #mobile-header .mobile-header-logo' ); - $css->add_property( 'display', 'block' ); - - if ( ! GeneratePress_Elements_Helper::does_option_exist( 'sticky-navigation-logo' ) ) { - $css->set_selector( '.main-navigation.navigation-stick .site-logo:not(.page-hero-logo)' ); - $css->add_property( 'display', 'block' ); - - $css->set_selector( '.main-navigation.navigation-stick .page-hero-logo' ); - $css->add_property( 'display', 'none' ); - } - } - - if ( $options['navigation_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'sticky-navigation' ) ) { - $css->set_selector( '#site-navigation:not(.navigation-stick):not(.toggled) .navigation-logo:not(.page-hero-navigation-logo)' ); - $css->add_property( 'display', 'none' ); - - $css->set_selector( '#sticky-navigation .page-hero-navigation-logo, #site-navigation.navigation-stick .page-hero-navigation-logo, #site-navigation.toggled .page-hero-navigation-logo' ); - $css->add_property( 'display', 'none' ); - } - - if ( $options['mobile_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'mobile-logo' ) ) { - $css->set_selector( '#mobile-header:not(.navigation-stick):not(.toggled) .mobile-header-logo:not(.page-hero-mobile-logo)' ); - $css->add_property( 'display', 'none' ); - - $css->set_selector( '#mobile-header.navigation-stick .page-hero-mobile-logo, #mobile-header.toggled .page-hero-mobile-logo' ); - $css->add_property( 'display', 'none' ); - } - - if ( $options['site_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'site-logo' ) ) { - $css->set_selector( '.site-logo:not(.page-hero-logo)' ); - $css->add_property( 'display', 'none' ); - } - - if ( 'merge-desktop' === $options['site_header_merge'] ) { - $css->stop_media_query(); - } - - if ( class_exists( 'Elementor\Plugin' ) ) { - $css->set_selector( '.elementor-editor-active .header-wrap' ); - $css->add_property( 'pointer-events', 'none' ); - } - } - - $css->start_media_query( generate_premium_get_media_query( 'mobile' ) ); - - $css->set_selector( '.page-hero' ); - - if ( $options['padding_top_mobile'] || '0' === $options['padding_top_mobile'] ) { - $css->add_property( 'padding-top', absint( $options['padding_top_mobile'] ), false, esc_html( $options['padding_top_unit_mobile'] ) ); - } - - if ( 'merge' === $options['site_header_merge'] && $options['site_header_height_mobile'] ) { - if ( $options['padding_top_mobile'] || '0' === $options['padding_top_mobile'] ) { - $css->add_property( 'padding-top', 'calc(' . absint( $options['padding_top_mobile'] ) . esc_html( $options['padding_top_unit_mobile'] ) . ' + ' . absint( $options['site_header_height_mobile'] ) . 'px)' ); - } elseif ( $options['padding_top'] ) { - $css->add_property( 'padding-top', 'calc(' . absint( $options['padding_top'] ) . esc_html( $options['padding_top_unit'] ) . ' + ' . absint( $options['site_header_height_mobile'] ) . 'px)' ); - } else { - $css->add_property( 'padding-top', absint( $options['site_header_height_mobile'] ), false, 'px' ); - } - } - - if ( $options['padding_right_mobile'] || '0' === $options['padding_right_mobile'] ) { - $css->add_property( 'padding-right', absint( $options['padding_right_mobile'] ), false, esc_html( $options['padding_right_unit_mobile'] ) ); - } - - if ( $options['padding_bottom_mobile'] || '0' === $options['padding_bottom_mobile'] ) { - $css->add_property( 'padding-bottom', absint( $options['padding_bottom_mobile'] ), false, esc_html( $options['padding_bottom_unit_mobile'] ) ); - } - - if ( $options['padding_left_mobile'] || '0' === $options['padding_left_mobile'] ) { - $css->add_property( 'padding-left', absint( $options['padding_left_mobile'] ), false, esc_html( $options['padding_left_unit_mobile'] ) ); - } - - if ( GeneratePress_Elements_Helper::does_option_exist( 'site-logo' ) && 'merge-desktop' === $options['site_header_merge'] ) { - $css->set_selector( '.inside-header .page-hero-logo, .main-navigation .page-hero-logo, #mobile-header .page-hero-mobile-logo' ); - $css->add_property( 'display', 'none' ); - } - - $css->stop_media_query(); - - return apply_filters( 'generate_page_hero_css_output', $css->css_output(), $options ); - } - - /** - * Put all of our meta options within an array. - * - * @since 1.7 - * - * @return array All Page Header options. - */ - public static function get_options() { - $post_id = self::$post_id; - - return apply_filters( - 'generate_hero_options', - array( - 'element_id' => $post_id, - 'content' => get_post_meta( $post_id, '_generate_element_content', true ), - 'classes' => get_post_meta( $post_id, '_generate_hero_custom_classes', true ), - 'container' => get_post_meta( $post_id, '_generate_hero_container', true ), - 'inner_container' => get_post_meta( $post_id, '_generate_hero_inner_container', true ), - 'horizontal_alignment' => get_post_meta( $post_id, '_generate_hero_horizontal_alignment', true ), - 'full_screen' => get_post_meta( $post_id, '_generate_hero_full_screen', true ), - 'vertical_alignment' => get_post_meta( $post_id, '_generate_hero_vertical_alignment', true ), - 'padding_top' => get_post_meta( $post_id, '_generate_hero_padding_top', true ), - 'padding_top_unit' => get_post_meta( $post_id, '_generate_hero_padding_top_unit', true ), - 'padding_right' => get_post_meta( $post_id, '_generate_hero_padding_right', true ), - 'padding_right_unit' => get_post_meta( $post_id, '_generate_hero_padding_right_unit', true ), - 'padding_bottom' => get_post_meta( $post_id, '_generate_hero_padding_bottom', true ), - 'padding_bottom_unit' => get_post_meta( $post_id, '_generate_hero_padding_bottom_unit', true ), - 'padding_left' => get_post_meta( $post_id, '_generate_hero_padding_left', true ), - 'padding_left_unit' => get_post_meta( $post_id, '_generate_hero_padding_left_unit', true ), - 'padding_top_mobile' => get_post_meta( $post_id, '_generate_hero_padding_top_mobile', true ), - 'padding_top_unit_mobile' => get_post_meta( $post_id, '_generate_hero_padding_top_unit_mobile', true ), - 'padding_right_mobile' => get_post_meta( $post_id, '_generate_hero_padding_right_mobile', true ), - 'padding_right_unit_mobile' => get_post_meta( $post_id, '_generate_hero_padding_right_unit_mobile', true ), - 'padding_bottom_mobile' => get_post_meta( $post_id, '_generate_hero_padding_bottom_mobile', true ), - 'padding_bottom_unit_mobile' => get_post_meta( $post_id, '_generate_hero_padding_bottom_unit_mobile', true ), - 'padding_left_mobile' => get_post_meta( $post_id, '_generate_hero_padding_left_mobile', true ), - 'padding_left_unit_mobile' => get_post_meta( $post_id, '_generate_hero_padding_left_unit_mobile', true ), - 'background_image' => get_post_meta( $post_id, '_generate_hero_background_image', true ), - 'disable_featured_image' => get_post_meta( $post_id, '_generate_hero_disable_featured_image', true ), - 'background_overlay' => get_post_meta( $post_id, '_generate_hero_background_overlay', true ), - 'background_position' => get_post_meta( $post_id, '_generate_hero_background_position', true ), - 'parallax' => get_post_meta( $post_id, '_generate_hero_background_parallax', true ), - 'background_color' => get_post_meta( $post_id, '_generate_hero_background_color', true ), - 'text_color' => get_post_meta( $post_id, '_generate_hero_text_color', true ), - 'link_color' => get_post_meta( $post_id, '_generate_hero_link_color', true ), - 'link_color_hover' => get_post_meta( $post_id, '_generate_hero_background_link_color_hover', true ), - 'site_header_merge' => get_post_meta( $post_id, '_generate_site_header_merge', true ), - 'site_header_height' => get_post_meta( $post_id, '_generate_site_header_height', true ), - 'site_header_height_mobile' => get_post_meta( $post_id, '_generate_site_header_height_mobile', true ), - 'site_logo' => get_post_meta( $post_id, '_generate_site_logo', true ), - 'retina_logo' => get_post_meta( $post_id, '_generate_retina_logo', true ), - 'navigation_logo' => get_post_meta( $post_id, '_generate_navigation_logo', true ), - 'mobile_logo' => get_post_meta( $post_id, '_generate_mobile_logo', true ), - 'navigation_location' => get_post_meta( $post_id, '_generate_navigation_location', true ), - 'header_background_color' => get_post_meta( $post_id, '_generate_site_header_background_color', true ), - 'header_title_color' => get_post_meta( $post_id, '_generate_site_header_title_color', true ), - 'header_tagline_color' => get_post_meta( $post_id, '_generate_site_header_tagline_color', true ), - 'navigation_colors' => get_post_meta( $post_id, '_generate_navigation_colors', true ), - 'navigation_background_color' => get_post_meta( $post_id, '_generate_navigation_background_color', true ), - 'navigation_text_color' => get_post_meta( $post_id, '_generate_navigation_text_color', true ), - 'navigation_background_color_hover' => get_post_meta( $post_id, '_generate_navigation_background_color_hover', true ), - 'navigation_text_color_hover' => get_post_meta( $post_id, '_generate_navigation_text_color_hover', true ), - 'navigation_background_color_current' => get_post_meta( $post_id, '_generate_navigation_background_color_current', true ), - 'navigation_text_color_current' => get_post_meta( $post_id, '_generate_navigation_text_color_current', true ), - ) - ); - } - - /** - * Does the bulk of the work after everything has initialized. - * - * @since 1.7 - */ - public function after_setup() { - $options = self::get_options(); - - if ( $options['disable_featured_image'] && is_singular() ) { - remove_action( 'generate_after_entry_header', 'generate_blog_single_featured_image' ); - remove_action( 'generate_before_content', 'generate_blog_single_featured_image' ); - remove_action( 'generate_after_header', 'generate_blog_single_featured_image' ); - remove_action( 'generate_before_content', 'generate_featured_page_header_inside_single' ); - remove_action( 'generate_after_header', 'generate_featured_page_header' ); - } - - if ( $options['site_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'site-logo' ) ) { - if ( '' !== $options['site_header_merge'] ) { - add_action( 'generate_after_logo', array( $this, 'add_site_logo' ) ); - } else { - add_filter( 'theme_mod_custom_logo', array( $this, 'replace_logo' ) ); - - if ( $options['retina_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'retina-logo' ) ) { - add_filter( 'generate_retina_logo', array( $this, 'replace_logo' ) ); - } - } - } - - if ( $options['navigation_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'navigation-logo' ) ) { - if ( $options['site_header_merge'] && GeneratePress_Elements_Helper::does_option_exist( 'sticky-navigation' ) ) { - add_action( 'generate_inside_navigation', array( $this, 'add_navigation_logo' ) ); - } else { - add_filter( 'generate_navigation_logo', array( $this, 'replace_logo' ) ); - } - } - - if ( $options['mobile_logo'] && GeneratePress_Elements_Helper::does_option_exist( 'mobile-logo' ) ) { - if ( 'merge' === $options['site_header_merge'] ) { - add_action( 'generate_inside_mobile_header', array( $this, 'add_mobile_header_logo' ) ); - } else { - add_filter( 'generate_mobile_header_logo', array( $this, 'replace_logo' ) ); - } - } - - if ( $options['navigation_location'] ) { - add_filter( 'generate_navigation_location', array( $this, 'navigation_location' ) ); - } - - if ( '' !== $options['site_header_merge'] ) { - add_action( 'generate_before_header', array( $this, 'merged_header_start' ), 1 ); - add_action( 'generate_after_header', array( $this, 'merged_header_end' ), 8 ); - - if ( 'contained' === $options['container'] ) { - add_filter( 'generate_header_class', array( $this, 'site_header_classes' ) ); - } - } - - if ( $options['content'] ) { - self::remove_template_elements(); - } - } - - /** - * Returns our custom logos if set within the Page Header. - * - * @since 1.7 - * - * @return string New URLs to images. - */ - public static function replace_logo() { - $filter = current_filter(); - $options = self::get_options(); - - if ( 'theme_mod_custom_logo' === $filter ) { - return $options['site_logo']; - } - - if ( 'generate_retina_logo' === $filter ) { - return wp_get_attachment_url( $options['retina_logo'] ); - } - - if ( 'generate_navigation_logo' === $filter ) { - return wp_get_attachment_url( $options['navigation_logo'] ); - } - - if ( 'generate_mobile_header_logo' === $filter ) { - return wp_get_attachment_url( $options['mobile_logo'] ); - } - } - - /** - * Adds a new site logo element if our header is merged on desktop only. - * - * @since 1.7 - */ - public static function add_site_logo() { - $options = self::get_options(); - - $logo_url = wp_get_attachment_url( $options['site_logo'] ); - $retina_logo_url = wp_get_attachment_url( $options['retina_logo'] ); - - if ( ! $logo_url ) { - return; - } - - $attr = apply_filters( - 'generate_page_hero_logo_attributes', - array( - 'class' => 'header-image is-logo-image', - 'alt' => esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ), - 'src' => $logo_url, - 'title' => esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ), - ) - ); - - if ( '' !== $retina_logo_url ) { - $attr['srcset'] = $logo_url . ' 1x, ' . $retina_logo_url . ' 2x'; - - // Add dimensions to image if retina is set. This fixes a container width bug in Firefox. - $data = wp_get_attachment_metadata( $options['site_logo'] ); - - if ( ! empty( $data ) ) { - $attr['width'] = $data['width']; - $attr['height'] = $data['height']; - } - } - - $attr = array_map( 'esc_attr', $attr ); - $html_attr = ''; - - foreach ( $attr as $name => $value ) { - $html_attr .= " $name=" . '"' . $value . '"'; - } - - // phpcs:ignore -- Escaping not needed. - echo apply_filters( - 'generate_page_hero_logo_output', - sprintf( - '', - esc_url( apply_filters( 'generate_logo_href', home_url( '/' ) ) ), - esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ), - $html_attr - ), - $logo_url, - $html_attr - ); - } - - /** - * Adds the custom navigation logo if needed. - * Only needed if there's a sticky navigation. - * - * @since 1.7 - */ - public static function add_navigation_logo() { - $options = self::get_options(); - - printf( - '', - esc_url( apply_filters( 'generate_logo_href', home_url( '/' ) ) ), - esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ), - esc_url( wp_get_attachment_url( $options['navigation_logo'] ) ), - esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ) - ); - } - - /** - * Adds the custom mobile header if needed. - * Only needed if there's a sticky navigation. - * - * @since 1.7 - */ - public static function add_mobile_header_logo() { - $options = self::get_options(); - - if ( 'title' === GeneratePress_Elements_Helper::does_option_exist( 'mobile-header-branding' ) ) { - return; - } - - printf( - '', - esc_url( apply_filters( 'generate_logo_href', home_url( '/' ) ) ), - esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ), - esc_url( wp_get_attachment_url( $options['mobile_logo'] ) ), - esc_attr( apply_filters( 'generate_logo_title', get_bloginfo( 'name', 'display' ) ) ) - ); - } - - /** - * Set the navigation location if set. - * - * @since 1.7 - * - * @return string The navigation location. - */ - public static function navigation_location() { - $options = self::get_options(); - - if ( 'no-navigation' === $options['navigation_location'] ) { - return ''; - } else { - return $options['navigation_location']; - } - } - - /** - * The opening merged header element. - * - * @since 1.7 - */ - public static function merged_header_start() { - echo '
    '; - } - - /** - * The closing merged header element. - * - * @since 1.7 - */ - public static function merged_header_end() { - echo '
    '; - } - - /** - * Adds classes to the site header. - * - * @since 1.7 - * - * @param array $classes Existing classes. - * @return array New classes. - */ - public static function site_header_classes( $classes ) { - $classes[] = 'grid-container'; - $classes[] = 'grid-parent'; - - return $classes; - } - - /** - * Checks if template tags exist, and removes those elements from elsewhere. - * - * @since 1.7 - */ - public static function remove_template_elements() { - $options = self::get_options(); - - if ( strpos( $options['content'], '{{post_title}}' ) !== false ) { - if ( is_singular() ) { - add_filter( 'generate_show_title', '__return_false' ); - } - - remove_action( 'generate_archive_title', 'generate_archive_title' ); - remove_filter( 'get_the_archive_title', 'generate_filter_the_archive_title' ); - add_filter( 'post_class', array( self::$hero, 'remove_hentry' ) ); - } - - if ( strpos( $options['content'], '{{post_date}}' ) !== false ) { - add_filter( 'generate_post_date', '__return_false' ); - add_filter( 'post_class', array( self::$hero, 'remove_hentry' ) ); - } - - if ( strpos( $options['content'], '{{post_author}}' ) !== false ) { - add_filter( 'generate_post_author', '__return_false' ); - add_filter( 'post_class', array( self::$hero, 'remove_hentry' ) ); - } - - if ( strpos( $options['content'], '{{post_terms.category}}' ) !== false ) { - add_filter( 'generate_show_categories', '__return_false' ); - } - - if ( strpos( $options['content'], '{{post_terms.post_tag}}' ) !== false ) { - add_filter( 'generate_show_tags', '__return_false' ); - } - } - - /** - * Checks for template tags and replaces them. - * - * @since 1.7 - * - * @param string $content The content to check. - * @return mixed The content with the template tags replaced. - */ - public static function template_tags( $content ) { - $search = array(); - $replace = array(); - - $search[] = '{{post_title}}'; - $post_title = ''; - - if ( is_singular() ) { - $post_title = get_the_title(); - } elseif ( is_tax() || is_category() || is_tag() ) { - $post_title = get_queried_object()->name; - } elseif ( is_post_type_archive() ) { - $post_title = post_type_archive_title( '', false ); - } elseif ( is_archive() && function_exists( 'get_the_archive_title' ) ) { - $post_title = get_the_archive_title(); - - if ( is_author() ) { - $post_title = get_the_author(); - } - } elseif ( is_home() ) { - $post_title = __( 'Blog', 'gp-premium' ); - } - - $replace[] = apply_filters( 'generate_page_hero_post_title', $post_title ); - - if ( is_singular() ) { - $time_string = ''; - if ( get_the_time( 'U' ) !== get_the_modified_time( 'U' ) ) { - $time_string = '' . $time_string; - } - - $time_string = sprintf( - $time_string, - esc_attr( get_the_date( 'c' ) ), - esc_html( get_the_date() ), - esc_attr( get_the_modified_date( 'c' ) ), - esc_html( get_the_modified_date() ) - ); - - $search[] = '{{post_date}}'; - $replace[] = apply_filters( 'generate_page_hero_post_date', $time_string ); - - // Author. - global $post; - $author_id = $post->post_author; - - $author = sprintf( - '', - esc_url( get_author_posts_url( $author_id ) ), - /* translators: author name */ - esc_attr( sprintf( __( 'View all posts by %s', 'gp-premium' ), get_the_author_meta( 'display_name', $author_id ) ) ), - esc_html( get_the_author_meta( 'display_name', $author_id ) ) - ); - - $search[] = '{{post_author}}'; - $replace[] = apply_filters( 'generate_page_hero_post_author', $author ); - - // Post terms. - if ( strpos( $content, '{{post_terms' ) !== false ) { - $data = preg_match_all( '/{{post_terms.([^}]*)}}/', $content, $matches ); - foreach ( $matches[1] as $match ) { - $search[] = '{{post_terms.' . $match . '}}'; - $terms = get_the_term_list( get_the_ID(), $match, apply_filters( 'generate_page_hero_terms_before', '' ), apply_filters( 'generate_page_hero_terms_separator', ', ' ), apply_filters( 'generate_page_hero_terms_after', '' ) ); - - if ( ! is_wp_error( $terms ) ) { - $replace[] = $terms; - } - } - } - - // Custom field. - if ( strpos( $content, '{{custom_field' ) !== false ) { - $data = preg_match_all( '/{{custom_field.([^}]*)}}/', $content, $matches ); - foreach ( $matches[1] as $match ) { - if ( null !== get_post_meta( get_the_ID(), $match, true ) && '_thumbnail_id' !== $match ) { - $search[] = '{{custom_field.' . $match . '}}'; - $value = get_post_meta( get_the_ID(), $match, true ); - add_filter( 'wp_kses_allowed_html', [ 'GeneratePress_Elements_Helper', 'expand_allowed_html' ], 10, 2 ); - $value = wp_kses_post( $value ); - remove_filter( 'wp_kses_allowed_html', [ 'GeneratePress_Elements_Helper', 'expand_allowed_html' ], 10, 2 ); - $replace[] = $value; - } - } - - $thumbnail_id = get_post_meta( get_the_ID(), '_thumbnail_id', true ); - if ( null !== $thumbnail_id ) { - $search[] = '{{custom_field._thumbnail_id}}'; - $replace[] = wp_get_attachment_image( $thumbnail_id, apply_filters( 'generate_hero_thumbnail_id_size', 'medium' ) ); - } - } - } - - // Taxonomy description. - if ( is_tax() || is_category() || is_tag() ) { - if ( strpos( $content, '{{custom_field' ) !== false ) { - $search[] = '{{custom_field.description}}'; - $replace[] = term_description( get_queried_object()->term_id, get_queried_object()->taxonomy ); - } - } - - return str_replace( $search, $replace, $content ); - } - - /** - * When the post title, author or date are in the Page Hero, they appear outside of the - * hentry element. This causes errors in Google Search Console. - * - * @since 1.7 - * - * @param array $classes Existing classes. - * @return array - */ - public function remove_hentry( $classes ) { - $classes = array_diff( $classes, array( 'hentry' ) ); - - return $classes; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-hooks.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-hooks.php deleted file mode 100644 index dca87caa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-hooks.php +++ /dev/null @@ -1,223 +0,0 @@ -hook = get_post_meta( $post_id, '_generate_hook', true ); - - if ( empty( $this->hook ) ) { - return; - } - - $this->content = get_post_meta( $post_id, '_generate_element_content', true ); - - if ( get_post_meta( $post_id, '_generate_custom_hook', true ) ) { - $this->custom_hook = get_post_meta( $post_id, '_generate_custom_hook', true ); - } - - if ( get_post_meta( $post_id, '_generate_hook_disable_site_header', true ) ) { - $this->disable_site_header = get_post_meta( $post_id, '_generate_hook_disable_site_header', true ); - } - - if ( get_post_meta( $post_id, '_generate_hook_disable_site_footer', true ) ) { - $this->disable_site_footer = get_post_meta( $post_id, '_generate_hook_disable_site_footer', true ); - } - - if ( get_post_meta( $post_id, '_generate_hook_priority', true ) || '0' === get_post_meta( $post_id, '_generate_hook_priority', true ) ) { - $this->priority = get_post_meta( $post_id, '_generate_hook_priority', true ); - } - - if ( get_post_meta( $post_id, '_generate_hook_execute_php', true ) ) { - $this->php = get_post_meta( $post_id, '_generate_hook_execute_php', true ); - } - - if ( get_post_meta( $post_id, '_generate_hook_execute_shortcodes', true ) ) { - $this->shortcodes = get_post_meta( $post_id, '_generate_hook_execute_shortcodes', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_display_conditions', true ) ) { - $this->conditional = get_post_meta( $post_id, '_generate_element_display_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_exclude_conditions', true ) ) { - $this->exclude = get_post_meta( $post_id, '_generate_element_exclude_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_user_conditions', true ) ) { - $this->users = get_post_meta( $post_id, '_generate_element_user_conditions', true ); - } - - if ( 'custom' === $this->hook && $this->custom_hook ) { - $this->hook = $this->custom_hook; - } - - $display = apply_filters( 'generate_hook_element_display', GeneratePress_Conditions::show_data( $this->conditional, $this->exclude, $this->users ), $post_id ); - - /** - * Simplify filter name. - * - * @since 2.0.0 - */ - $display = apply_filters( - 'generate_element_display', - $display, - $post_id - ); - - if ( $display ) { - global $generate_elements; - - $generate_elements[ $post_id ] = array( - 'is_block_element' => false, - 'type' => 'hook', - 'id' => $post_id, - ); - - if ( 'generate_header' === $this->hook && $this->disable_site_header ) { - remove_action( 'generate_header', 'generate_construct_header' ); - } - - if ( 'generate_footer' === $this->hook && $this->disable_site_footer ) { - remove_action( 'generate_footer', 'generate_construct_footer' ); - add_filter( 'generate_footer_widgets', '__return_null' ); - } - - add_action( esc_attr( $this->hook ), array( $this, 'execute_hook' ), absint( $this->priority ) ); - } - - } - - /** - * Output our hook content. - * - * @since 1.7 - */ - public function execute_hook() { - - $content = $this->content; - - if ( $this->shortcodes ) { - $content = do_shortcode( $content ); - } - - if ( $this->php && GeneratePress_Elements_Helper::should_execute_php() ) { - ob_start(); - eval( '?>' . $content . 'conditional = get_post_meta( $post_id, '_generate_element_display_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_exclude_conditions', true ) ) { - $this->exclude = get_post_meta( $post_id, '_generate_element_exclude_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_element_user_conditions', true ) ) { - $this->users = get_post_meta( $post_id, '_generate_element_user_conditions', true ); - } - - if ( get_post_meta( $post_id, '_generate_sidebar_layout', true ) ) { - $this->sidebar_layout = get_post_meta( $post_id, '_generate_sidebar_layout', true ); - } - - if ( get_post_meta( $post_id, '_generate_footer_widgets', true ) ) { - $this->footer_widgets = get_post_meta( $post_id, '_generate_footer_widgets', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_site_header', true ) ) { - $this->disable_site_header = get_post_meta( $post_id, '_generate_disable_site_header', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_mobile_header', true ) ) { - $this->disable_mobile_header = get_post_meta( $post_id, '_generate_disable_mobile_header', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_top_bar', true ) ) { - $this->disable_top_bar = get_post_meta( $post_id, '_generate_disable_top_bar', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_primary_navigation', true ) ) { - $this->disable_primary_navigation = get_post_meta( $post_id, '_generate_disable_primary_navigation', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_secondary_navigation', true ) ) { - $this->disable_secondary_navigation = get_post_meta( $post_id, '_generate_disable_secondary_navigation', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_featured_image', true ) ) { - $this->disable_featured_image = get_post_meta( $post_id, '_generate_disable_featured_image', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_content_title', true ) ) { - $this->disable_content_title = get_post_meta( $post_id, '_generate_disable_content_title', true ); - } - - if ( get_post_meta( $post_id, '_generate_disable_footer', true ) ) { - $this->disable_footer = get_post_meta( $post_id, '_generate_disable_footer', true ); - } - - if ( get_post_meta( $post_id, '_generate_content_area', true ) ) { - $this->content_area = get_post_meta( $post_id, '_generate_content_area', true ); - } - - if ( get_post_meta( $post_id, '_generate_content_width', true ) ) { - $this->content_width = get_post_meta( $post_id, '_generate_content_width', true ); - } - - $display = apply_filters( 'generate_layout_element_display', GeneratePress_Conditions::show_data( $this->conditional, $this->exclude, $this->users ), $post_id ); - - /** - * Simplify filter name. - * - * @since 2.0.0 - */ - $display = apply_filters( - 'generate_element_display', - $display, - $post_id - ); - - if ( $display ) { - global $generate_elements; - - $generate_elements[ $post_id ] = array( - 'is_block_element' => false, - 'type' => 'layout', - 'id' => $post_id, - ); - - add_action( 'wp', array( $this, 'after_setup' ), 100 ); - add_action( 'wp_enqueue_scripts', array( $this, 'build_css' ), 50 ); - - if ( is_admin() ) { - add_action( 'current_screen', array( $this, 'after_setup' ), 100 ); - add_action( 'enqueue_block_editor_assets', array( $this, 'build_css' ), 50 ); - } - } - - } - - /** - * Return our available options. - * - * @since 1.7 - * @deprecated 1.7.3 - * - * @return array - */ - public static function get_options() { - return false; - } - - /** - * Initiate our set layout changes. - * - * @since 1.7 - */ - public function after_setup() { - if ( $this->sidebar_layout && ! self::post_meta_exists( '_generate-sidebar-layout-meta' ) ) { - add_filter( 'generate_sidebar_layout', array( $this, 'filter_options' ) ); - } - - if ( $this->footer_widgets && ! self::post_meta_exists( '_generate-footer-widget-meta' ) ) { - add_filter( 'generate_footer_widgets', array( $this, 'filter_options' ) ); - } - - if ( $this->disable_site_header ) { - remove_action( 'generate_header', 'generate_construct_header' ); - } - - if ( $this->disable_mobile_header ) { - remove_action( 'generate_after_header', 'generate_menu_plus_mobile_header', 5 ); - } - - if ( $this->disable_top_bar ) { - remove_action( 'generate_before_header', 'generate_top_bar', 5 ); - remove_action( 'generate_inside_secondary_navigation', 'generate_secondary_nav_top_bar_widget', 5 ); - } - - if ( $this->disable_primary_navigation ) { - add_filter( 'generate_navigation_location', '__return_false', 20 ); - add_filter( 'generate_disable_mobile_header_menu', '__return_true' ); - } - - if ( $this->disable_secondary_navigation ) { - add_filter( 'has_nav_menu', array( $this, 'disable_secondary_navigation' ), 10, 2 ); - } - - if ( $this->disable_featured_image ) { - remove_action( 'generate_after_entry_header', 'generate_blog_single_featured_image' ); - remove_action( 'generate_before_content', 'generate_blog_single_featured_image' ); - remove_action( 'generate_after_header', 'generate_blog_single_featured_image' ); - remove_action( 'generate_before_content', 'generate_featured_page_header_inside_single' ); - remove_action( 'generate_after_header', 'generate_featured_page_header' ); - add_filter( 'body_class', array( $this, 'remove_featured_image_class' ), 20 ); - } - - if ( $this->disable_content_title ) { - add_filter( 'generate_show_title', '__return_false' ); - } - - if ( $this->disable_footer ) { - remove_action( 'generate_footer', 'generate_construct_footer' ); - add_filter( 'generate_footer_widgets', '__return_null' ); - } - - if ( $this->content_area ) { - add_filter( 'body_class', array( $this, 'body_classes' ) ); - } - - if ( is_admin() ) { - if ( $this->sidebar_layout && ! self::admin_post_meta_exists( '_generate-sidebar-layout-meta' ) ) { - add_filter( 'generate_block_editor_sidebar_layout', array( $this, 'filter_options' ) ); - } - - if ( $this->disable_content_title ) { - add_filter( 'generate_block_editor_show_content_title', '__return_false' ); - } - - if ( $this->content_area ) { - add_filter( 'generate_block_editor_content_area_type', array( $this, 'set_editor_content_area' ) ); - } - - if ( $this->content_width ) { - add_filter( 'generate_block_editor_container_width', array( $this, 'set_editor_content_width' ) ); - } - } - } - - /** - * Build dynamic CSS - */ - public function build_css() { - if ( $this->content_width ) { - wp_add_inline_style( 'generate-style', '#content {max-width: ' . absint( $this->content_width ) . 'px;margin-left: auto;margin-right: auto;}' ); - } - - if ( is_admin() ) { - $admin_css = ''; - - if ( version_compare( generate_premium_get_theme_version(), '3.2.0-alpha.1', '<' ) ) { - if ( 'full-width' === $this->content_area ) { - $admin_css .= 'html .editor-styles-wrapper .wp-block{max-width: 100%}'; - } - - if ( $this->content_width ) { - $admin_css .= 'html .editor-styles-wrapper .wp-block{max-width: ' . absint( $this->content_width ) . 'px;}'; - } - } - - if ( $this->content_area ) { - $admin_css .= '#generate-layout-page-builder-container {opacity: 0.5;pointer-events: none;}'; - } - - if ( $admin_css ) { - wp_add_inline_style( 'wp-edit-blocks', $admin_css ); - } - } - } - - /** - * Check to see if our individual post metabox has a value. - * - * @since 1.7 - * - * @param string $meta The meta key we're checking for. - * @return bool - */ - public static function post_meta_exists( $meta ) { - if ( ! is_singular() ) { - return false; - } - - $value = get_post_meta( get_the_ID(), $meta, true ); - - if ( '_generate-footer-widget-meta' === $meta && '0' === $value ) { - $value = true; - } - - if ( $value ) { - return true; - } - - return false; - } - - /** - * Check to see if our individual post metabox has a value in the admin area. - * - * @since 1.11.0 - * - * @param string $meta The meta key we're checking for. - * @return bool - */ - public static function admin_post_meta_exists( $meta ) { - if ( is_admin() ) { - $current_screen = get_current_screen(); - - if ( isset( $current_screen->is_block_editor ) && $current_screen->is_block_editor ) { - $post_id = false; - - if ( isset( $_GET['post'] ) ) { // phpcs:ignore -- No data processing happening here. - $post_id = absint( $_GET['post'] ); // phpcs:ignore -- No data processing happening here. - } - - if ( $post_id ) { - $value = get_post_meta( $post_id, $meta, true ); - - if ( '_generate-footer-widget-meta' === $meta && '0' === $value ) { - $value = true; - } - - if ( $value ) { - return true; - } - } else { - return false; - } - } - } - } - - /** - * Filter our filterable options. - * - * @since 1.7 - */ - public function filter_options() { - $filter = current_filter(); - - if ( 'generate_sidebar_layout' === $filter || 'generate_block_editor_sidebar_layout' === $filter ) { - return $this->sidebar_layout; - } - - if ( 'generate_footer_widgets' === $filter ) { - if ( 'no-widgets' === $this->footer_widgets ) { - return 0; - } else { - return $this->footer_widgets; - } - } - } - - /** - * Set the content area type in the editor. - * - * @param string $area Content area type. - */ - public function set_editor_content_area( $area ) { - if ( 'full-width' === $this->content_area ) { - $area = 'true'; - } - - if ( 'contained-container' === $this->content_area ) { - $area = 'contained'; - } - - return $area; - } - - /** - * Set the content width in the editor. - * - * @param string $width Content width with unit. - */ - public function set_editor_content_width( $width ) { - if ( $this->content_width ) { - $width = absint( $this->content_width ) . 'px'; - } - - return $width; - } - - /** - * Disable the Secondary Navigation if set. - * - * @since 1.7 - * - * @param bool $has_nav_menu The existing value. - * @param string $location The location we're checking. - * @return bool - */ - public static function disable_secondary_navigation( $has_nav_menu, $location ) { - if ( 'secondary' === $location ) { - return false; - } - - return $has_nav_menu; - } - - /** - * Sets any necessary body classes. - * - * @since 1.7 - * - * @param array $classes Our existing body classes. - * @return array Our new set of classes. - */ - public function body_classes( $classes ) { - if ( 'full-width' === $this->content_area ) { - $classes[] = 'full-width-content'; - } - - if ( 'contained' === $this->content_area ) { - $classes[] = 'contained-content'; - } - - return $classes; - } - - /** - * Remove the featured image class if it's disabled. - * - * @since 2.1.0 - * @param array $classes The body classes. - */ - public function remove_featured_image_class( $classes ) { - if ( is_singular() ) { - $classes = generate_premium_remove_featured_image_class( $classes, $this->disable_featured_image ); - } - - return $classes; - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-metabox.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-metabox.php deleted file mode 100644 index 4d121d9e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/elements/class-metabox.php +++ /dev/null @@ -1,2245 +0,0 @@ -is_block_editor ) ) { - $element_type = 'block'; - } - } - } - - return $element_type; - } - - /** - * Add a body class if we're using the Header element type. - * We do this so we can hide the Template Tags metabox for other types. - * - * @since 1.7 - * - * @param string $classes Existing classes. - * @return string - */ - public function body_class( $classes ) { - if ( 'gp_elements' === get_post_type() ) { - $element_type = self::get_element_type(); - - if ( $element_type ) { - $classes .= ' ' . $element_type . '-element-type'; - } else { - $classes .= ' no-element-type'; - } - - if ( 'header' === $element_type && get_post_meta( get_the_ID(), '_generate_element_content', true ) ) { - $classes .= ' element-has-page-hero'; - } - - $block_type = get_post_meta( get_the_ID(), '_generate_block_type', true ); - - if ( $block_type ) { - if ( 'content-template' === $block_type && get_post_meta( get_the_ID(), '_generate_use_theme_post_container', true ) ) { - $classes .= ' using-theme-post-container'; - } - - if ( ( 'archive-navigation-template' === $block_type || 'post-navigation-template' === $block_type ) && get_post_meta( get_the_ID(), '_generate_use_archive_navigation_container', true ) ) { - $classes .= ' using-theme-pagination-container'; - } - - $classes .= ' ' . $block_type . '-block-type'; - } - } - - return $classes; - } - - /** - * Enqueue any necessary scripts and styles. - * - * @since 1.7 - * - * @param string $hook The current page hook. - */ - public function scripts( $hook ) { - if ( in_array( $hook, array( 'post.php', 'post-new.php' ) ) ) { - if ( 'gp_elements' === get_post_type() ) { - $element_type = get_post_meta( get_the_ID(), '_generate_element_type', true ); - - // Remove autosave when dealing with non-content Elements. - // phpcs:ignore -- No data processing happening. - if ( 'block' !== $element_type || ( isset( $_GET['element_type'] ) && 'block' !== $_GET['element_type'] ) ) { - wp_dequeue_script( 'autosave' ); - } - - $deps = array( 'jquery' ); - - if ( function_exists( 'wp_enqueue_code_editor' ) ) { - $settings = wp_enqueue_code_editor( - array( - 'type' => 'application/x-httpd-php', - 'codemirror' => array( - 'indentUnit' => 2, - 'tabSize' => 2, - ), - ) - ); - - $deps[] = 'code-editor'; - } else { - $settings = false; - } - - $element_type = self::get_element_type(); - - wp_enqueue_script( 'generate-elements-metabox', plugin_dir_url( __FILE__ ) . 'assets/admin/metabox.js', $deps, GP_PREMIUM_VERSION, true ); - - wp_localize_script( - 'generate-elements-metabox', - 'elements', - array( - 'nonce' => wp_create_nonce( 'generate-elements-location' ), - 'settings' => $settings ? wp_json_encode( $settings ) : false, - 'type' => $element_type, - 'custom_image' => __( 'Custom Image', 'gp-premium' ), - 'fallback_image' => __( 'Fallback Image', 'gp-premium' ), - 'choose' => __( 'Choose...', 'gp-premium' ), - 'showID' => apply_filters( 'generate_elements_show_object_ids', false ), - ) - ); - - wp_enqueue_style( 'generate-elements-metabox', plugin_dir_url( __FILE__ ) . 'assets/admin/metabox.css', array(), GP_PREMIUM_VERSION ); - wp_enqueue_style( 'generate-elements-balloon', plugin_dir_url( __FILE__ ) . 'assets/admin/balloon.css', array(), GP_PREMIUM_VERSION ); - - wp_enqueue_media(); - wp_enqueue_script( 'wp-color-picker' ); - wp_enqueue_style( 'wp-color-picker' ); - wp_enqueue_script( 'wp-color-picker-alpha', GP_LIBRARY_DIRECTORY_URL . 'alpha-color-picker/wp-color-picker-alpha.min.js', array( 'wp-color-picker' ), '3.0.0', true ); - - wp_add_inline_script( - 'wp-color-picker-alpha', - 'jQuery( function() { jQuery( ".color-picker" ).wpColorPicker(); } );' - ); - - if ( function_exists( 'wp_add_inline_script' ) && function_exists( 'generate_get_default_color_palettes' ) ) { - // Grab our palette array and turn it into JS. - $palettes = wp_json_encode( generate_get_default_color_palettes() ); - - // Add our custom palettes. - // json_encode takes care of escaping. - wp_add_inline_script( 'wp-color-picker', 'jQuery.wp.wpColorPicker.prototype.options.palettes = ' . $palettes . ';' ); - } - - wp_enqueue_style( 'select2', GP_LIBRARY_DIRECTORY_URL . 'select2/select2.min.css', array(), '4.0.13' ); - wp_enqueue_script( 'select2', GP_LIBRARY_DIRECTORY_URL . 'select2/select2.full.min.js', array( 'jquery', 'generate-elements-metabox' ), '4.0.13', true ); - - $css = ''; - - if ( function_exists( 'generate_get_option' ) && 'separate-containers' === generate_get_option( 'content_layout_setting' ) ) { - $css .= 'body.left-sidebar-block-type .block-editor-block-list__layout.is-root-container, body.right-sidebar-block-type .block-editor-block-list__layout.is-root-container {background: ' . generate_get_option( 'background_color' ) . ';}'; - $css .= 'body.content-template-block-type:not(.using-theme-post-container) .block-editor-block-list__layout.is-root-container, body.archive-navigation-template-block-type:not(.using-theme-pagination-container) .block-editor-block-list__layout.is-root-container {background: ' . generate_get_option( 'background_color' ) . ';}'; - } - - wp_add_inline_style( 'generate-elements-metabox', $css ); - } - } - } - - /** - * Register our metabox. - * - * @since 1.7 - */ - public function register_metabox() { - // Title not translated on purpose. - add_meta_box( 'generate_premium_elements', __( 'Display Rules', 'gp-premium' ), array( $this, 'element_fields' ), 'gp_elements', 'normal', 'high' ); - add_meta_box( 'generate_page_hero_template_tags', __( 'Template Tags', 'gp-premium' ), array( $this, 'template_tags' ), 'gp_elements', 'side', 'low' ); - remove_meta_box( 'slugdiv', 'gp_elements', 'normal' ); - } - - /** - * Output all of our metabox fields. - * - * @since 1.7 - * - * @param object $post Our post object. - */ - public function element_fields( $post ) { - wp_nonce_field( basename( __FILE__ ), 'generate_elements_nonce' ); - - $type = self::get_element_type(); - $page_hero_class = ''; - $merge = get_post_meta( get_the_ID(), '_generate_site_header_merge', true ); - $conditions_set = get_post_meta( get_the_ID(), '_generate_element_display_conditions', true ); - $post_status = get_post_status( get_the_ID() ); - - if ( 'header' === $type && get_post_meta( get_the_ID(), '_generate_element_content', true ) ) { - $page_hero_class = ' has-page-hero'; - } - ?> - - - -
    -

    -
    - - -
    - - - - - - - - - - - - - - - > - - - - - > - - - - - > - - - - - - - - - - - - - - - - - - - - - -
    - - - /> -
    - - - /> -
    - - - - DISALLOW_FILE_EDIT' - ); - ?> - - /> - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - > - - - - - > - - - - - - - - - - - - - - - - - > - - - - - > - - - - - > - - - - - > - - - - - > - - - - - - - - - - - - - - - - - - - - - - - - - -
    - - ? - - -
    - - - -
    - - - -
    - - - -
    - - - /> -
    - - - -
    - - -
    - - -
    - -
    -
    -
    - - - -
    - - -
    - -
    -
    - - - -
    - - -
    - -
    -
    - - - -
    - - -
    - -
    -
    - - - -
    - - -
    -
    - - -
    - - - -
    - - - - - -
    - - - -
    - - - /> -
    - - ? - - /> -
    - - ? - - /> -
    - - - -
    - - - -
    - - - -
    - - - -
    - - - - - - - - - > - - - - - > - - - - - - > - - - - - - - > - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - > - - - - - > - - - - - > - - - - - > - - - - - > - - - - - > - - - - - > - - - - -
    - - ? - - -
    - - ? - - -
    - - -
    - -
    -
    - - px -
    -
    - - -
    - - - -
    - - - -
    - - - -
    - - -
    -
    - '; - } - ?> -
    - - /> - - -
    -
    - - -
    -
    - '; - } - ?> -
    - - /> - - -
    -
    - - -
    -
    - '; - } - ?> -
    - - /> - - -
    -
    - - -
    -
    - '; - } - ?> -
    - - /> - - -
    -
    - - - -
    - - - /> -
    - - - -
    - - - -
    - - - -
    - - - -
    - - - -
    - - - -
    - - - - - - - - - - -
    - - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    -
    - - - - - - - - -
    - - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    - -
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    - - - /> -
    - - - /> -
    - - - /> -
    - - - /> -
    - - - /> -
    - - - /> -
    - - - /> -
    - - - /> -
    - - - - - - - - - - - - -
    - - -
    - -
    - -
    - -
    - -
    - -
    -
    - - - - px -
    - - - - - - - - - - - - - - - - - - - > - - - - -
    - - ? - - $value ) { - $type = explode( ':', $value['rule'] ); - - if ( in_array( 'post', $type ) || in_array( 'taxonomy', $type ) ) { - $show = true; - } else { - $show = false; - } - ?> -
    - - - - - -
    - -
    - - - - - -
    - - - - -
    - - ? - - $value ) { - $type = explode( ':', $value['rule'] ); - - if ( in_array( 'post', $type ) || in_array( 'taxonomy', $type ) ) { - $show = true; - } else { - $show = false; - } - ?> -
    - - - - - -
    - -
    - - - - - -
    - - - - -
    - - ? - - $value ) { - ?> -
    - - - -
    - -
    - - - -
    - - - - -
    - - ? - - /> -
    - - - - - - - - -
    - 'text', - '_generate_custom_hook' => 'text', - '_generate_hook_priority' => 'number', - ); - - if ( 'hook' === $type_value ) { - $hook_values['_generate_hook_disable_site_header'] = 'key'; - $hook_values['_generate_hook_disable_site_footer'] = 'key'; - $hook_values['_generate_hook_execute_shortcodes'] = 'key'; - $hook_values['_generate_hook_execute_php'] = 'key'; - } - - // We don't want people to be able to use these hooks. - $blacklist = array( - 'muplugins_loaded', - 'registered_taxonomy', - 'plugins_loaded', - 'setup_theme', - 'after_setup_theme', - 'init', - 'widgets_init', - 'wp_loaded', - 'pre_get_posts', - 'wp', - 'template_redirect', - 'get_header', - 'wp_enqueue_scripts', - 'the_post', - 'dynamic_sidebar', - 'get_footer', - 'get_sidebar', - 'wp_print_footer_scripts', - 'shutdown', - ); - - foreach ( $hook_values as $key => $type ) { - $value = false; - - if ( isset( $_POST[ $key ] ) ) { - // Bail if we're using a blacklisted hook. - if ( '_generate_custom_hook' === $key ) { - if ( in_array( $_POST[ $key ], $blacklist ) ) { - continue; - } - } - - if ( 'number' === $type ) { - $value = absint( $_POST[ $key ] ); - } elseif ( 'key' === $type ) { - $value = sanitize_key( $_POST[ $key ] ); - } else { - $value = sanitize_text_field( $_POST[ $key ] ); - } - - // Need to temporarily change the $value so it returns true. - if ( '_generate_hook_priority' === $key ) { - if ( '0' === $_POST[ $key ] ) { - $value = 'zero'; - } - } - } - - if ( $value ) { - if ( 'zero' === $value ) { - $value = '0'; - } - - update_post_meta( $post_id, $key, $value ); - } else { - delete_post_meta( $post_id, $key ); - } - } - } - - // Page Header type. - if ( 'header' === $type_value ) { - $hero_values = array( - '_generate_hero_custom_classes' => 'attribute', - '_generate_hero_container' => 'text', - '_generate_hero_inner_container' => 'text', - '_generate_hero_horizontal_alignment' => 'text', - '_generate_hero_full_screen' => 'key', - '_generate_hero_vertical_alignment' => 'text', - '_generate_hero_padding_top' => 'number', - '_generate_hero_padding_top_unit' => 'text', - '_generate_hero_padding_right' => 'number', - '_generate_hero_padding_right_unit' => 'text', - '_generate_hero_padding_bottom' => 'number', - '_generate_hero_padding_bottom_unit' => 'text', - '_generate_hero_padding_left' => 'number', - '_generate_hero_padding_left_unit' => 'text', - '_generate_hero_padding_top_mobile' => 'number', - '_generate_hero_padding_top_unit_mobile' => 'text', - '_generate_hero_padding_right_mobile' => 'number', - '_generate_hero_padding_right_unit_mobile' => 'text', - '_generate_hero_padding_bottom_mobile' => 'number', - '_generate_hero_padding_bottom_unit_mobile' => 'text', - '_generate_hero_padding_left_mobile' => 'number', - '_generate_hero_padding_left_unit_mobile' => 'text', - '_generate_hero_background_image' => 'key', - '_generate_hero_disable_featured_image' => 'key', - '_generate_hero_background_color' => 'color', - '_generate_hero_text_color' => 'color', - '_generate_hero_link_color' => 'color', - '_generate_hero_background_link_color_hover' => 'color', - '_generate_hero_background_overlay' => 'key', - '_generate_hero_background_position' => 'text', - '_generate_hero_background_parallax' => 'key', - '_generate_site_header_merge' => 'key', - '_generate_site_header_height' => 'number', - '_generate_site_header_height_mobile' => 'number', - '_generate_navigation_colors' => 'key', - '_generate_site_logo' => 'number', - '_generate_retina_logo' => 'number', - '_generate_navigation_logo' => 'number', - '_generate_mobile_logo' => 'number', - '_generate_navigation_location' => 'key', - '_generate_site_header_background_color' => 'text', - '_generate_site_header_title_color' => 'text', - '_generate_site_header_tagline_color' => 'text', - '_generate_navigation_background_color' => 'text', - '_generate_navigation_text_color' => 'text', - '_generate_navigation_background_color_hover' => 'text', - '_generate_navigation_text_color_hover' => 'text', - '_generate_navigation_background_color_current' => 'text', - '_generate_navigation_text_color_current' => 'text', - ); - - foreach ( $hero_values as $key => $type ) { - $value = false; - - if ( isset( $_POST[ $key ] ) ) { - if ( 'number' === $type ) { - $value = absint( $_POST[ $key ] ); - } elseif ( 'key' === $type ) { - $value = sanitize_key( $_POST[ $key ] ); - } elseif ( 'attribute' === $type ) { - $value = esc_attr( $_POST[ $key ] ); - } else { - $value = sanitize_text_field( $_POST[ $key ] ); - } - } - - if ( - '_generate_hero_padding_top_mobile' === $key || - '_generate_hero_padding_right_mobile' === $key || - '_generate_hero_padding_bottom_mobile' === $key || - '_generate_hero_padding_left_mobile' === $key - ) { - if ( '0' === $_POST[ $key ] ) { - $value = 'zero'; - } - } - - if ( $value ) { - if ( 'zero' === $value ) { - $value = '0'; // String on purpose. - } - - update_post_meta( $post_id, $key, $value ); - } else { - delete_post_meta( $post_id, $key ); - } - } - } - - // Save Layout type. - if ( 'layout' === $type_value ) { - $layout_values = array( - '_generate_sidebar_layout' => 'key', - '_generate_footer_widgets' => 'key', - '_generate_disable_site_header' => 'key', - '_generate_disable_mobile_header' => 'key', - '_generate_disable_top_bar' => 'key', - '_generate_disable_primary_navigation' => 'key', - '_generate_disable_secondary_navigation' => 'key', - '_generate_disable_featured_image' => 'key', - '_generate_disable_content_title' => 'key', - '_generate_disable_footer' => 'key', - '_generate_content_area' => 'key', - '_generate_content_width' => 'number', - ); - - foreach ( $layout_values as $key => $type ) { - $value = false; - - if ( isset( $_POST[ $key ] ) ) { - if ( 'number' === $type ) { - $value = absint( $_POST[ $key ] ); - } elseif ( 'key' === $type ) { - $value = sanitize_key( $_POST[ $key ] ); - } else { - $value = sanitize_text_field( $_POST[ $key ] ); - } - } - - if ( $value ) { - update_post_meta( $post_id, $key, $value ); - } else { - delete_post_meta( $post_id, $key ); - } - } - } - - $ignore_languages = false; - - if ( isset( $_POST['_generate_element_ignore_languages'] ) ) { - $ignore_languages = sanitize_key( $_POST['_generate_element_ignore_languages'] ); - } - - if ( $ignore_languages ) { - update_post_meta( $post_id, '_generate_element_ignore_languages', $ignore_languages ); - } else { - delete_post_meta( $post_id, '_generate_element_ignore_languages' ); - } - - // Display conditions. - $conditions = get_post_meta( $post_id, '_generate_element_display_conditions', true ); - $new_conditions = array(); - - $rules = $_POST['display-condition']; - $objects = $_POST['display-condition-object']; - - $count = count( $rules ); - - for ( $i = 0; $i < $count; $i++ ) { - if ( '' !== $rules[ $i ] ) { - if ( in_array( $rules[ $i ], $rules ) ) { - $new_conditions[ $i ]['rule'] = sanitize_text_field( $rules[ $i ] ); - $new_conditions[ $i ]['object'] = sanitize_key( $objects[ $i ] ); - } else { - $new_conditions[ $i ]['rule'] = ''; - $new_conditions[ $i ]['object'] = ''; - } - } - } - - if ( 'block' === $type_value ) { - $dynamic_css_posts = get_option( 'generateblocks_dynamic_css_posts', array() ); - - if ( $dynamic_css_posts ) { - foreach ( $new_conditions as $condition ) { - if ( $condition['object'] && isset( $dynamic_css_posts[ $condition['object'] ] ) ) { - unset( $dynamic_css_posts[ $condition['object'] ] ); - } - - if ( ! $condition['object'] ) { - $dynamic_css_posts = array(); - break; - } - } - - update_option( 'generateblocks_dynamic_css_posts', $dynamic_css_posts ); - } - } - - if ( ! empty( $new_conditions ) && $new_conditions !== $conditions ) { - update_post_meta( $post_id, '_generate_element_display_conditions', $new_conditions ); - } elseif ( empty( $new_conditions ) && $conditions ) { - delete_post_meta( $post_id, '_generate_element_display_conditions', $conditions ); - } - - // Exclude conditions. - $exclude_conditions = get_post_meta( $post_id, '_generate_element_exclude_conditions', true ); - $new_exclude_conditions = array(); - - $exclude_rules = $_POST['exclude-condition']; - $exclude_objects = $_POST['exclude-condition-object']; - - $exclude_count = count( $exclude_rules ); - - for ( $i = 0; $i < $exclude_count; $i++ ) { - if ( '' !== $exclude_rules[ $i ] ) { - if ( in_array( $exclude_rules[ $i ], $exclude_rules ) ) { - $new_exclude_conditions[ $i ]['rule'] = sanitize_text_field( $exclude_rules[ $i ] ); - $new_exclude_conditions[ $i ]['object'] = sanitize_key( $exclude_objects[ $i ] ); - } else { - $new_exclude_conditions[ $i ]['rule'] = ''; - $new_exclude_conditions[ $i ]['object'] = ''; - } - } - } - - if ( ! empty( $new_exclude_conditions ) && $new_exclude_conditions !== $exclude_conditions ) { - update_post_meta( $post_id, '_generate_element_exclude_conditions', $new_exclude_conditions ); - } elseif ( empty( $new_exclude_conditions ) && $exclude_conditions ) { - delete_post_meta( $post_id, '_generate_element_exclude_conditions', $exclude_conditions ); - } - - // User conditions. - $user_conditions = get_post_meta( $post_id, '_generate_element_user_conditions', true ); - $new_user_conditions = array(); - - $user_rules = $_POST['user-condition']; - $user_count = count( $user_rules ); - - for ( $i = 0; $i < $user_count; $i++ ) { - if ( '' !== $user_rules[ $i ] ) { - if ( in_array( $user_rules[ $i ], $user_rules ) ) { - $new_user_conditions[ $i ] = sanitize_text_field( $user_rules[ $i ] ); - } else { - $new_user_conditions[ $i ] = ''; - } - } - } - - if ( ! empty( $new_user_conditions ) && $new_user_conditions !== $user_conditions ) { - update_post_meta( $post_id, '_generate_element_user_conditions', $new_user_conditions ); - } elseif ( empty( $new_user_conditions ) && $user_conditions ) { - delete_post_meta( $post_id, '_generate_element_user_conditions', $user_conditions ); - } - - // Internal notes. - $notes_key = '_generate_element_internal_notes'; - - if ( isset( $_POST[ $notes_key ] ) ) { - if ( function_exists( 'sanitize_textarea_field' ) ) { - $notes_value = sanitize_textarea_field( $_POST[ $notes_key ] ); - } else { - $notes_value = sanitize_text_field( $_POST[ $notes_key ] ); - } - - if ( $notes_value ) { - update_post_meta( $post_id, $notes_key, $notes_value ); - } else { - delete_post_meta( $post_id, $notes_key ); - } - } - } - - /** - * Get terms of a set taxonomy. - * - * @since 1.7 - */ - public function get_terms() { - check_ajax_referer( 'generate-elements-location', 'nonce' ); - - $current_user_can = 'manage_options'; - - if ( apply_filters( 'generate_elements_metabox_ajax_allow_editors', false ) ) { - $current_user_can = 'edit_posts'; - } - - if ( ! current_user_can( $current_user_can ) ) { - return; - } - - if ( ! isset( $_POST['id'] ) ) { - return; - } - - $tax_id = sanitize_text_field( $_POST['id'] ); - - echo wp_json_encode( self::get_taxonomy_terms( $tax_id ) ); - - die(); - } - - /** - * Get all posts inside a specific post type. - * - * @since 1.7 - */ - public function get_posts() { - check_ajax_referer( 'generate-elements-location', 'nonce' ); - - $current_user_can = 'manage_options'; - - if ( apply_filters( 'generate_elements_metabox_ajax_allow_editors', false ) ) { - $current_user_can = 'edit_posts'; - } - - if ( ! current_user_can( $current_user_can ) ) { - return; - } - - if ( ! isset( $_POST['id'] ) ) { - return; - } - - $post_type = sanitize_text_field( $_POST['id'] ); - - echo wp_json_encode( self::get_post_type_posts( $post_type ) ); - - die(); - } - - /** - * Get all of our posts and terms in one go on load. - * - * @since 2.0.0 - */ - public function get_all_objects() { - check_ajax_referer( 'generate-elements-location', 'nonce' ); - - $current_user_can = 'manage_options'; - - if ( apply_filters( 'generate_elements_metabox_ajax_allow_editors', false ) ) { - $current_user_can = 'edit_posts'; - } - - if ( ! current_user_can( $current_user_can ) ) { - return; - } - - if ( ! isset( $_POST['posts'] ) && ! isset( $_POST['terms'] ) ) { - return; - } - - $posts = array(); - $terms = array(); - - if ( ! empty( $_POST['posts'] ) ) { - $posts = array_map( 'sanitize_text_field', $_POST['posts'] ); - } - - if ( ! empty( $_POST['terms'] ) ) { - $terms = array_map( 'sanitize_text_field', $_POST['terms'] ); - } - - $all_posts = self::get_post_type_posts( $posts ); - $all_terms = self::get_taxonomy_terms( $terms ); - - echo wp_json_encode( array_merge( $all_posts, $all_terms ) ); - - die(); - } - - /** - * Look up posts inside a post type. - * - * @since 1.7 - * - * @param string|array $post_type The post type to look up. - * @return array - */ - public static function get_post_type_posts( $post_type ) { - if ( ! is_array( $post_type ) ) { - $post_type = array( $post_type ); - } - - $data = array(); - - foreach ( $post_type as $type ) { - global $wpdb; - - $post_status = array( 'publish', 'future', 'draft', 'pending', 'private' ); - - $object = get_post_type_object( $type ); - - $data[ $type ] = array( - 'type' => 'posts', - 'postType' => $type, - 'label' => $object->label, - 'objects' => array(), - ); - - if ( 'attachment' === $type ) { - $posts = $wpdb->get_results( $wpdb->prepare( "SELECT ID, post_title from $wpdb->posts where post_type = %s ORDER BY post_title", $type ) ); - - } else { - $format = implode( ', ', array_fill( 0, count( $post_status ), '%s' ) ); - $query = sprintf( "SELECT ID, post_title from $wpdb->posts where post_type = '%s' AND post_status IN(%s) ORDER BY post_title", $type, $format ); - // @codingStandardsIgnoreLine - $posts = $wpdb->get_results( $wpdb->prepare( $query, $post_status ) ); - } - - foreach ( $posts as $post ) { - $title = ( '' !== $post->post_title ) ? esc_attr( $post->post_title ) : $type . '-' . $post->ID; - $data[ $type ]['objects'][] = array( - 'id' => $post->ID, - 'name' => $title, - ); - } - } - - return $data; - } - - /** - * Get taxonomy terms for a specific taxonomy. - * - * @since 1.7 - * - * @param int|array $tax_id The taxonomy ID. - * @return array - */ - public static function get_taxonomy_terms( $tax_id ) { - if ( ! is_array( $tax_id ) ) { - $tax_id = array( $tax_id ); - } - - $data = array(); - - foreach ( $tax_id as $id ) { - $tax = get_taxonomy( $id ); - - $terms = get_terms( - array( - 'taxonomy' => $id, - 'hide_empty' => false, - ) - ); - - $data[ $id ] = array( - 'type' => 'terms', - 'taxonomy' => $id, - 'label' => $tax->label, - 'objects' => array(), - ); - - foreach ( $terms as $term ) { - $data[ $id ]['objects'][] = array( - 'id' => $term->term_id, - 'name' => esc_attr( $term->name ), - ); - } - } - - return $data; - } - - /** - * Build our entire list of hooks to display. - * - * @since 1.7 - * - * @return array Our list of hooks. - */ - public static function get_available_hooks() { - return GeneratePress_Elements_Helper::get_available_hooks(); - } - - /** - * Add available template tags to Header Elements. - * - * @since 1.7 - */ - public static function template_tags() { - ?> - -

    - -

    - - -

    - -

    - - -

    - -

    - - -

    - -

    - - -

    - -

    - _x( 'Elements', 'Post Type General Name', 'gp-premium' ), - 'singular_name' => _x( 'Element', 'Post Type Singular Name', 'gp-premium' ), - 'menu_name' => __( 'Elements', 'gp-premium' ), - 'all_items' => __( 'All Elements', 'gp-premium' ), - 'add_new' => __( 'Add New Element', 'gp-premium' ), - 'add_new_item' => __( 'Add New Element', 'gp-premium' ), - 'new_item' => __( 'New Element', 'gp-premium' ), - 'edit_item' => __( 'Edit Element', 'gp-premium' ), - 'update_item' => __( 'Update Element', 'gp-premium' ), - 'search_items' => __( 'Search Element', 'gp-premium' ), - 'featured_image' => __( 'Background Image', 'gp-premium' ), - 'set_featured_image' => __( 'Set background image', 'gp-premium' ), - 'remove_featured_image' => __( 'Remove background image', 'gp-premium' ), - 'item_published' => __( 'Element published.', 'gp-premium' ), - 'item_updated' => __( 'Element updated.', 'gp-premium' ), - 'item_scheduled' => __( 'Element scheduled.', 'gp-premium' ), - 'item_reverted_to_draft' => __( 'Element reverted to draft.', 'gp-premium' ), - ); - - $args = array( - 'labels' => $labels, - 'supports' => array( 'title', 'editor', 'thumbnail', 'custom-fields', 'page-attributes', 'revisions' ), - 'hierarchical' => true, - 'public' => false, - 'show_ui' => true, - 'show_in_menu' => false, - 'can_export' => true, - 'has_archive' => false, - 'exclude_from_search' => true, - 'show_in_rest' => true, - ); - - register_post_type( 'gp_elements', $args ); - } - - /** - * Disable editor and show_in_rest support for non-Block Elements. - * - * @since 1.11.0 - * @param array $args The existing args. - * @param string $post_type The current post type. - */ - public function set_standard_element( $args, $post_type ) { - if ( 'gp_elements' === $post_type ) { - $post_id = false; - $type = false; - - if ( isset( $_GET['post'] ) ) { // phpcs:ignore -- No processing happening. - $post_id = absint( $_GET['post'] ); // phpcs:ignore -- No processing happening. - } - - if ( $post_id ) { - $type = get_post_meta( $post_id, '_generate_element_type', true ); - } elseif ( isset( $_GET['element_type'] ) ) { // phpcs:ignore -- No processing happening. - $type = esc_html( $_GET['element_type'] ); // phpcs:ignore -- No processing happening. - } - - if ( ! $type ) { - return $args; - } - - if ( 'block' !== $type ) { - $args['supports'] = array( 'title', 'thumbnail' ); - $args['show_in_rest'] = false; - $args['hierarchical'] = false; - } - - if ( 'block' === $type ) { - $args['supports'] = array( 'title', 'editor', 'custom-fields', 'page-attributes', 'revisions' ); - } - - if ( 'layout' === $type ) { - $args['labels']['add_new_item'] = __( 'Add New Layout', 'gp-premium' ); - $args['labels']['edit_item'] = __( 'Edit Layout', 'gp-premium' ); - } - - if ( 'hook' === $type ) { - $args['labels']['add_new_item'] = __( 'Add New Hook', 'gp-premium' ); - $args['labels']['edit_item'] = __( 'Edit Hook', 'gp-premium' ); - } - - if ( 'header' === $type ) { - $args['labels']['add_new_item'] = __( 'Add New Header', 'gp-premium' ); - $args['labels']['edit_item'] = __( 'Edit Header', 'gp-premium' ); - } - } - - return $args; - } - - /** - * Register custom post type columns. - * - * @since 1.7 - * - * @param array $columns Existing CPT columns. - * @return array All our CPT columns. - */ - public function register_columns( $columns ) { - $columns['element_type'] = esc_html__( 'Type', 'gp-premium' ); - $columns['location'] = esc_html__( 'Location', 'gp-premium' ); - $columns['exclusions'] = esc_html__( 'Exclusions', 'gp-premium' ); - $columns['users'] = esc_html__( 'Users', 'gp-premium' ); - - $new_columns = array(); - - // Need to do some funky stuff to display these columns before the date. - foreach ( $columns as $key => $value ) { - if ( 'date' === $key ) { - $new_columns['element_type'] = esc_html__( 'Type', 'gp-premium' ); - $new_columns['location'] = esc_html__( 'Location', 'gp-premium' ); - $new_columns['exclusions'] = esc_html__( 'Exclusions', 'gp-premium' ); - $new_columns['users'] = esc_html__( 'Users', 'gp-premium' ); - } - - $new_columns[ $key ] = $value; - } - - return $new_columns; - } - - /** - * Add a filter select input to the admin list. - * - * @since 1.7 - */ - public function build_element_type_filter() { - $screen = function_exists( 'get_current_screen' ) ? get_current_screen() : false; - - if ( ! $screen ) { - return; - } - - if ( ! isset( $screen->post_type ) || 'gp_elements' !== $screen->post_type ) { - return; - } - - $values = array( - 'block' => esc_html__( 'Blocks', 'gp-premium' ), - 'header' => esc_html__( 'Headers', 'gp-premium' ), - 'hook' => esc_html__( 'Hooks', 'gp-premium' ), - 'layout' => esc_html__( 'Layouts', 'gp-premium' ), - ); - - $current_element_type = isset( $_GET['gp_element_type_filter'] ) ? esc_html( $_GET['gp_element_type_filter'] ) : ''; // phpcs:ignore -- No processing happening. - $current_block_type = isset( $_GET['gp_elements_block_type_filter'] ) ? esc_html( $_GET['gp_elements_block_type_filter'] ) : ''; // phpcs:ignore -- No processing happening. - ?> - - - - is_main_query() && '' !== $type ) { - $meta_query[] = array( - 'key' => '_generate_element_type', - 'value' => esc_attr( $type ), - 'compare' => '=', - ); - - $block_type = isset( $_GET['gp_elements_block_type_filter'] ) ? $_GET['gp_elements_block_type_filter'] : ''; // phpcs:ignore -- No processing happening. - - if ( 'block' === $type && '' !== $block_type ) { - $meta_query['relation'] = 'AND'; - - $meta_query[] = array( - 'key' => '_generate_block_type', - 'value' => esc_attr( $block_type ), - 'compare' => '=', - ); - } - - $query->set( 'meta_query', $meta_query ); - } - } - - /** - * Add content to our custom post type columns. - * - * @since 1.7 - * - * @param string $column The name of the column. - * @param int $post_id The ID of the post row. - */ - public function add_columns( $column, $post_id ) { - switch ( $column ) { - case 'element_type': - $type = get_post_meta( $post_id, '_generate_element_type', true ); - $hook_location = get_post_meta( $post_id, '_generate_hook', true ); - - if ( 'block' === $type ) { - echo esc_html__( 'Block', 'gp-premium' ); - - $block_type = get_post_meta( $post_id, '_generate_block_type', true ); - - if ( $block_type ) { - echo ' - ' . esc_html( GeneratePress_Elements_Helper::get_element_type_label( $block_type ) ); - - if ( 'hook' === $block_type && $hook_location ) { - echo '
    '; - - if ( 'custom' === $hook_location ) { - $custom_hook = get_post_meta( $post_id, '_generate_custom_hook', true ); - echo '' . esc_html( $custom_hook ) . ''; - } else { - echo '' . esc_html( $hook_location ) . ''; - } - } - } - } - - if ( 'header' === $type ) { - echo esc_html__( 'Header', 'gp-premium' ); - } - - if ( 'hook' === $type ) { - echo esc_html__( 'Hook', 'gp-premium' ); - - if ( $hook_location ) { - echo '
    '; - - if ( 'custom' === $hook_location ) { - $custom_hook = get_post_meta( $post_id, '_generate_custom_hook', true ); - echo '' . esc_html( $custom_hook ) . ''; - } else { - echo '' . esc_html( $hook_location ) . ''; - } - } - } - - if ( 'layout' === $type ) { - echo esc_html__( 'Layout', 'gp-premium' ); - } - break; - - case 'location': - $location = get_post_meta( $post_id, '_generate_element_display_conditions', true ); - $parent_block = wp_get_post_parent_id( $post_id ); - - if ( $location ) { - foreach ( (array) $location as $data ) { - echo esc_html( GeneratePress_Conditions::get_saved_label( $data ) ); - echo '
    '; - } - } elseif ( ! empty( $parent_block ) ) { - echo esc_html__( 'Inherit from parent', 'gp-premium' ); - } else { - echo esc_html__( 'Not set', 'gp-premium' ); - } - break; - - case 'exclusions': - $location = get_post_meta( $post_id, '_generate_element_exclude_conditions', true ); - - if ( $location ) { - foreach ( (array) $location as $data ) { - echo esc_html( GeneratePress_Conditions::get_saved_label( $data ) ); - echo '
    '; - } - } - break; - - case 'users': - $users = get_post_meta( $post_id, '_generate_element_user_conditions', true ); - - if ( $users ) { - foreach ( (array) $users as $data ) { - if ( strpos( $data, ':' ) !== false ) { - $data = substr( $data, strpos( $data, ':' ) + 1 ); - } - - $return = ucwords( str_replace( '_', ' ', $data ) ); - - echo esc_html( $return ) . '
    '; - } - } - break; - } - } - - /** - * Create our admin menu item. - * - * @since 1.7 - */ - public function menu_item() { - add_submenu_page( - 'themes.php', - esc_html__( 'Elements', 'gp-premium' ), - esc_html__( 'Elements', 'gp-premium' ), - apply_filters( 'generate_elements_admin_menu_capability', 'manage_options' ), - 'edit.php?post_type=gp_elements' - ); - } - - /** - * Make sure our admin menu item is highlighted. - * - * @since 1.7 - */ - public function fix_current_item() { - global $parent_file, $submenu_file, $post_type; - - if ( 'gp_elements' === $post_type ) { - $parent_file = 'themes.php'; // phpcs:ignore - $submenu_file = 'edit.php?post_type=gp_elements'; // phpcs:ignore - } - } - - /** - * Add scripts to the edit/post area of Elements. - * - * @since 1.11.0 - * @param string $hook The current hook for the page. - */ - public function admin_scripts( $hook ) { - if ( ! function_exists( 'get_current_screen' ) ) { - return; - } - - $current_screen = get_current_screen(); - - if ( 'edit.php' === $hook || 'post.php' === $hook ) { - if ( 'gp_elements' === $current_screen->post_type ) { - wp_enqueue_script( 'generate-elements', plugin_dir_url( __FILE__ ) . 'assets/admin/elements.js', array( 'jquery' ), GP_PREMIUM_VERSION, true ); - wp_enqueue_style( 'generate-elements', plugin_dir_url( __FILE__ ) . 'assets/admin/elements.css', array(), GP_PREMIUM_VERSION ); - } - } - } - - /** - * Build the Add New Element modal. - * - * @since 1.11.0 - */ - public function element_modal() { - if ( ! function_exists( 'get_current_screen' ) ) { - return; - } - - $current_screen = get_current_screen(); - - if ( 'edit-gp_elements' === $current_screen->id || 'gp_elements' === $current_screen->id ) { - ?> - - 'gp_elements', - 'no_found_rows' => true, - 'post_status' => 'publish', - 'numberposts' => 500, // phpcs:ignore - 'fields' => 'ids', - 'suppress_filters' => false, - ); - - $custom_args = apply_filters( - 'generate_elements_custom_args', - array( - 'order' => 'ASC', - ) - ); - - $args = array_merge( $args, $custom_args ); - - // Prevent Polylang from altering the query. - if ( function_exists( 'pll_get_post_language' ) ) { - $args['lang'] = ''; - } - - $posts = get_posts( $args ); - - foreach ( $posts as $post_id ) { - $post_id = apply_filters( 'generate_element_post_id', $post_id ); - $type = get_post_meta( $post_id, '_generate_element_type', true ); - - if ( 'hook' === $type ) { - new GeneratePress_Hook( $post_id ); - } - - if ( 'header' === $type && ! GeneratePress_Hero::$instances ) { - new GeneratePress_Hero( $post_id ); - } - - if ( 'layout' === $type ) { - new GeneratePress_Site_Layout( $post_id ); - } - - if ( 'block' === $type ) { - new GeneratePress_Block_Element( $post_id ); - } - } -} - -add_filter( 'generate_dashboard_tabs', 'generate_elements_dashboard_tab' ); -/** - * Add the Sites tab to our Dashboard tabs. - * - * @since 1.6 - * - * @param array $tabs Existing tabs. - * @return array New tabs. - */ -function generate_elements_dashboard_tab( $tabs ) { - $screen = get_current_screen(); - - $tabs['Elements'] = array( - 'name' => __( 'Elements', 'gp-premium' ), - 'url' => admin_url( 'edit.php?post_type=gp_elements' ), - 'class' => 'edit-gp_elements' === $screen->id ? 'active' : '', - 'id' => 'gp-elements-tab', - ); - - return $tabs; -} - -add_filter( 'generate_dashboard_screens', 'generate_elements_dashboard_screen' ); -/** - * Add the Sites tab to our Dashboard screens. - * - * @since 2.1.0 - * - * @param array $screens Existing screens. - * @return array New screens. - */ -function generate_elements_dashboard_screen( $screens ) { - $screens[] = 'edit-gp_elements'; - - return $screens; -} - -add_filter( 'generate_element_post_id', 'generate_elements_ignore_languages' ); -/** - * Disable Polylang elements if their language doesn't match. - * We disable their automatic quering so Elements with no language display by default. - * - * @since 1.8 - * - * @param int $post_id The current post ID. - * @return bool|int - */ -function generate_elements_ignore_languages( $post_id ) { - if ( function_exists( 'pll_get_post_language' ) && function_exists( 'pll_current_language' ) ) { - $language = pll_get_post_language( $post_id, 'locale' ); - $disable = get_post_meta( $post_id, '_generate_element_ignore_languages', true ); - - if ( $disable ) { - return $post_id; - } - - if ( $language && $language !== pll_current_language( 'locale' ) ) { // phpcs:ignore -- Using Yoda check I am. - return false; - } - } - - return $post_id; -} - -add_action( 'save_post_wp_block', 'generate_elements_wp_block_update', 10, 2 ); -/** - * Regenerate the GenerateBlocks CSS file when a re-usable block is saved. - * - * @since 1.11.0 - * @param int $post_id The post ID. - * @param object $post The post object. - */ -function generate_elements_wp_block_update( $post_id, $post ) { - $is_autosave = wp_is_post_autosave( $post_id ); - $is_revision = wp_is_post_revision( $post_id ); - - if ( $is_autosave || $is_revision || ! current_user_can( 'edit_post', $post_id ) ) { - return $post_id; - } - - if ( isset( $post->post_content ) ) { - if ( strpos( $post->post_content, 'wp:generateblocks' ) !== false ) { - global $wpdb; - - $option = get_option( 'generateblocks_dynamic_css_posts', array() ); - - $posts = $wpdb->get_col( "SELECT post_id FROM $wpdb->postmeta WHERE meta_key = '_generateblocks_reusable_blocks'" ); - - foreach ( (array) $posts as $id ) { - $display_conditions = get_post_meta( $id, '_generate_element_display_conditions', true ); - - if ( $display_conditions ) { - foreach ( (array) $display_conditions as $condition ) { - if ( 'general:site' === $condition['rule'] ) { - $option = array(); - break; - } - - if ( $condition['object'] && isset( $option[ $condition['object'] ] ) ) { - unset( $option[ $condition['object'] ] ); - } - } - } - } - - update_option( 'generateblocks_dynamic_css_posts', $option ); - } - } - -} - -add_filter( 'generate_do_block_element_content', 'generate_add_block_element_content_filters' ); -/** - * Apply content filters to our block elements. - * - * @since 1.11.0 - * @param string $content The block element content. - */ -function generate_add_block_element_content_filters( $content ) { - $content = shortcode_unautop( $content ); - $content = do_shortcode( $content ); - - if ( function_exists( 'wp_filter_content_tags' ) ) { - $content = wp_filter_content_tags( $content ); - } elseif ( function_exists( 'wp_make_content_images_responsive' ) ) { - $content = wp_make_content_images_responsive( $content ); - } - - return $content; -} - -add_action( 'admin_bar_menu', 'generate_add_elements_admin_bar', 100 ); -/** - * Add the Elementd admin bar item. - * - * @since 2.0.0 - */ -function generate_add_elements_admin_bar() { - $current_user_can = 'manage_options'; - - if ( apply_filters( 'generate_elements_metabox_ajax_allow_editors', false ) ) { - $current_user_can = 'edit_posts'; - } - - if ( ! current_user_can( $current_user_can ) ) { - return; - } - - global $wp_admin_bar; - global $generate_elements; - - $title = __( 'Elements', 'gp-premium' ); - $count = ! empty( $generate_elements ) ? count( $generate_elements ) : 0; - - // Prevent "Entire Site" Elements from being counted on non-edit pages in the admin. - if ( is_admin() && function_exists( 'get_current_screen' ) ) { - $screen = get_current_screen(); - - if ( ! isset( $screen->is_block_editor ) || ! $screen->is_block_editor ) { - $count = 0; - } - - if ( 'edit' !== $screen->parent_base ) { - $count = 0; - } - } - - if ( $count > 0 ) { - $title = sprintf( - /* translators: Active Element count. */ - __( 'Elements (%s)', 'gp-premium' ), - $count - ); - } - - $wp_admin_bar->add_menu( - array( - 'id' => 'gp_elements-menu', - 'title' => $title, - 'href' => esc_url( admin_url( 'edit.php?post_type=gp_elements' ) ), - ) - ); - - if ( ! empty( $generate_elements ) ) { - // Prevent "Entire Site" Elements from being counted on non-edit pages in the admin. - if ( is_admin() && function_exists( 'get_current_screen' ) ) { - $screen = get_current_screen(); - - if ( ! isset( $screen->is_block_editor ) || ! $screen->is_block_editor ) { - return; - } - - if ( 'edit' !== $screen->parent_base ) { - return; - } - } - - foreach ( (array) $generate_elements as $key => $data ) { - $label = GeneratePress_Elements_Helper::get_element_type_label( $data['type'] ); - - $wp_admin_bar->add_menu( - array( - 'id' => 'element-' . absint( $data['id'] ), - 'parent' => 'gp_elements-menu', - 'title' => get_the_title( $data['id'] ) . ' (' . $label . ')', - 'href' => get_edit_post_link( $data['id'] ), - ) - ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-cpt.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-cpt.php deleted file mode 100644 index e8afe669..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-cpt.php +++ /dev/null @@ -1,134 +0,0 @@ - _x( 'Fonts', 'Post Type General Name', 'gp-premium' ), - 'singular_name' => _x( 'Font', 'Post Type Singular Name', 'gp-premium' ), - 'menu_name' => __( 'Fonts', 'gp-premium' ), - 'all_items' => __( 'All Fonts', 'gp-premium' ), - 'add_new' => __( 'Add New Font', 'gp-premium' ), - 'add_new_item' => __( 'Add New Font', 'gp-premium' ), - 'new_item' => __( 'New Font', 'gp-premium' ), - 'edit_item' => __( 'Edit Font', 'gp-premium' ), - 'update_item' => __( 'Update Font', 'gp-premium' ), - 'search_items' => __( 'Search Font', 'gp-premium' ), - 'item_published' => __( 'Font published.', 'gp-premium' ), - 'item_updated' => __( 'Font updated.', 'gp-premium' ), - 'item_scheduled' => __( 'Font scheduled.', 'gp-premium' ), - 'item_reverted_to_draft' => __( 'Font reverted to draft.', 'gp-premium' ), - ); - - $args = array( - 'labels' => $labels, - 'supports' => array( 'title', 'custom-fields' ), - 'hierarchical' => false, - 'public' => false, - 'show_ui' => false, - 'show_in_menu' => true, - 'has_archive' => false, - 'exclude_from_search' => true, - 'show_in_rest' => true, - ); - - register_post_type( GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, $args ); - - // Font variants. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_variants', - array( - 'type' => 'array', - 'show_in_rest' => false, - ) - ); - - // Font family alias. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_family_alias', - array( - 'type' => 'string', - 'show_in_rest' => false, - ) - ); - - // Font display value. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_display', - array( - 'type' => 'string', - 'show_in_rest' => false, - ) - ); - - // Font source. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_source', - array( - 'type' => 'string', - 'show_in_rest' => false, - ) - ); - - // Font family fallback. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_fallback', - array( - 'type' => 'string', - 'show_in_rest' => false, - ) - ); - - // Font family preview. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_preview', - array( - 'type' => 'string', - 'show_in_rest' => false, - ) - ); - - // Font family variable. - register_post_meta( - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'gp_font_variable', - array( - 'type' => 'string', - 'show_in_rest' => false, - ) - ); - } -} - -GeneratePress_Pro_Font_Library_CPT::get_instance()->init(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-optimize.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-optimize.php deleted file mode 100644 index b688a8d7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-optimize.php +++ /dev/null @@ -1,252 +0,0 @@ - self::USER_AGENT, - ) - ); - - $code = wp_remote_retrieve_response_code( $response ); - - if ( 200 !== $code ) { - return ''; - } - - return wp_remote_retrieve_body( $response ); - } - - /** - * Parse the stylesheet and build it into a font object which OMGF can understand. - * - * @param string $stylesheet A valid CSS stylesheet. - * - * @return array - */ - private static function convert_to_fonts_object( $stylesheet ) { - preg_match_all( '/font-family:\s\'(.*?)\';/', $stylesheet, $font_families ); - - if ( empty( $font_families[1] ) ) { - return array(); - } - - $font_families = array_unique( $font_families[1] ); - $object = array(); - - foreach ( $font_families as $font_family ) { - $slug = sanitize_title( $font_family ); - $object[ $slug ] = array( - 'slug' => $slug, - 'fontFamily' => $font_family, - 'variants' => self::parse_variants( $stylesheet, $font_family ), - 'subsets' => self::parse_subsets( $stylesheet, $font_family ), - ); - } - - return $object; - } - - /** - * Parse a stylesheet from Google Fonts' API into a valid Font Object. - * - * @param string $stylesheet The stylesheet to parse. - * @param string $font_family The font family used in the parse. - * - * @return array - */ - private static function parse_variants( $stylesheet, $font_family ) { - /** - * This also captures the commented Subset name. - */ - preg_match_all( '/\/\*\s.*?}/s', $stylesheet, $font_faces ); - - if ( empty( $font_faces[0] ) ) { - return array(); - } - - $font_object = array(); - - foreach ( $font_faces[0] as $font_face ) { - // Check for exact match of font-family. - if ( ! preg_match( '/font-family:[\s\'"]*?' . $font_family . '[\'"]?;/', $font_face ) ) { - continue; - } - - preg_match( '/font-style:\s(normal|italic);/', $font_face, $font_style ); - preg_match( '/font-weight:\s([0-9]+);/', $font_face, $font_weight ); - preg_match( '/src:\surl\((.*?woff2)\)/', $font_face, $font_src ); - preg_match( '/\/\*\s([a-z\-0-9\[\]]+?)\s\*\//', $font_face, $subset ); - preg_match( '/unicode-range:\s(.*?);/', $font_face, $range ); - - $subset = ! empty( $subset[1] ) ? trim( $subset[1], '[]' ) : ''; - - /** - * Remove variants that have subset the user doesn't need. - */ - $allowed_subsets = apply_filters( - 'generatepress_google_font_subsets', - GeneratePress_Pro_Font_Library::get_settings( 'preferred_subset' ) - ); - - if ( empty( $allowed_subsets ) ) { - $allowed_subsets = array( 'latin' ); - } - - if ( ! empty( $subset ) && ! in_array( $subset, $allowed_subsets, true ) && ! is_numeric( $subset ) ) { - continue; - } - - /** - * If $subset is empty, assume it's a logographic (Chinese, Japanese, etc.) character set. - * - * @TODO: Apply subset setting here. - */ - if ( is_numeric( $subset ) ) { - $subset = 'logogram-' . $subset; - } - - $key = $subset . '-' . $font_weight[1] . ( 'normal' === $font_style[1] ? '' : '-' . $font_style[1] ); - - // Setup font object data. - $font_object[ $key ] = array( - 'fontFamily' => $font_family, - 'fontStyle' => $font_style[1], - 'fontWeight' => $font_weight[1], - 'src' => $font_src[1], - ); - - if ( ! empty( $subset ) ) { - $font_object[ $key ]['subset'] = $subset; - } - - if ( ! empty( $range ) && isset( $range[1] ) ) { - $font_object[ $key ]['range'] = $range[1]; - } - } - - return $font_object; - } - - /** - * Parse stylesheets for subsets, which in Google Fonts stylesheets are always - * included, commented above each @font-face statements, e.g. /* latin-ext - * - * @param string $stylesheet The stylesheet to parse. - * @param string $font_family The font family used in the parse. - * - * @return array - */ - private static function parse_subsets( $stylesheet, $font_family ) { - - preg_match_all( '/\/\*\s([a-z\-]+?)\s\*\//', $stylesheet, $subsets ); - - if ( empty( $subsets[1] ) ) { - return array(); - } - - $subsets = array_unique( $subsets[1] ); - - return $subsets; - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-rest.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-rest.php deleted file mode 100644 index b91e5aea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library-rest.php +++ /dev/null @@ -1,579 +0,0 @@ -namespace . $this->version; - - // Get fonts from CPT. - register_rest_route( - $namespace, - '/get-fonts/', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_fonts' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - // Download a Google font. - register_rest_route( - $namespace, - '/download-google-font/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'download_google_font' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - // Upload a font. - register_rest_route( - $namespace, - '/upload-fonts/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'upload_fonts' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - // Delete a font family. - register_rest_route( - $namespace, - '/delete-font/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'delete_font' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - // Get font library settings. - register_rest_route( - $namespace, - '/get-settings/', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_settings' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - // Set font library settings. - register_rest_route( - $namespace, - '/set-settings/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'set_settings' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/optimize-google-fonts/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'optimize_google_fonts' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/update-font-post/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'update_font_post' ), - 'permission_callback' => array( $this, 'edit_posts_permission' ), - ) - ); - } - - /** - * Get font posts. - * - * @param WP_REST_Request $request The request object. - * - * @return array The response. - */ - public function get_fonts( WP_REST_Request $request ) { - $name = $request->get_param( 'name' ); - $response = GeneratePress_Pro_Font_Library::get_fonts( $name ); - - return $this->success( $response ); - } - - /** - * Generate font CSS. - * - * @return mixed - */ - public function build_css_file() { - - $result = GeneratePress_Pro_Font_Library::build_css_file(); - - if ( is_wp_error( $result ) ) { - return $this->error( 'font_css_generation_failed', __( 'Failed to generate font CSS.', 'gp-premium' ) ); - } - - return $this->success( $result ); - } - - /** - * Delete a specific font from the library and the associated CPT post. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function delete_font( WP_REST_Request $request ) { - $font_id = $request->get_param( 'fontId' ); - $slug = get_post_field( 'post_name', $font_id ); - $upload_dir = wp_get_upload_dir(); - $font_base_path = trailingslashit( $upload_dir['basedir'] ) . 'generatepress/fonts/' . $slug . '/'; - - // Delete the font post. - $success = wp_delete_post( $font_id, true ); - - if ( ! $success ) { - return $this->error( - 'font_post_delete_failed', - __( 'Failed to delete font post.', 'gp-premium' ) - ); - } - - // Delete the font sub folder if it exists. - if ( file_exists( $font_base_path ) ) { - GeneratePress_Pro_Font_Library::delete_directory( $font_base_path ); - } - - // Regenerate the font CSS. - $this->build_css_file(); - - // Return success. - return $this->success( __( 'Font successfully deleted!', 'gp-premium' ) ); - } - - /** - * Download a specific Google font and update the CPT. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function optimize_google_fonts( WP_REST_Request $request ) { - $font = $request->get_param( 'font' ) ?? array(); - $variants = $request->get_param( 'variants' ) ?? array(); - - if ( ! $font || ! $variants ) { - return $this->failed( 'No font or variants provided' ); - } - - $optimized_variants = GeneratePress_Pro_Font_Library_Optimize::get_variants( $font, $variants ); - - if ( $optimized_variants ) { - foreach ( $optimized_variants as $key => $optimized_variant ) { - foreach ( $variants as &$variant ) { - $style_match = $variant['fontStyle'] === $optimized_variant['fontStyle']; - $weight_match = $variant['fontWeight'] === $optimized_variant['fontWeight']; - - if ( $style_match && $weight_match ) { - $variant['src'] = $optimized_variant['src']; - break; - } - } - } - } - - return $this->success( $variants ); - } - - /** - * Check if a font post exists by slug and create it if it doesn't exist. - * - * @param array $variant The font variant to check. - * @param array $slug The font slug. - * @return mixed - */ - public static function get_font_post( $variant, $slug ) { - global $wpdb; - - $font_post = $wpdb->get_row( - $wpdb->prepare( - "SELECT ID FROM $wpdb->posts WHERE post_name = %s AND post_type = %s", - $slug, - GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT - ) - ); - - if ( $font_post ) { - return $font_post->ID; - } - - $font_post = wp_insert_post( - array( - 'post_title' => $variant['fontFamily'], - 'post_name' => $slug, - 'post_type' => GeneratePress_Pro_Font_Library::FONT_LIBRARY_CPT, - 'post_status' => 'publish', - 'wp_error' => true, - 'meta_input' => array( - 'gp_font_family_alias' => '', - 'gp_font_variants' => array(), - 'gp_font_display' => 'auto', - 'gp_font_fallback' => '', - 'gp_font_variable' => GeneratePress_Pro_Font_Library::CSS_VAR_PREFIX . $slug, - ), - ) - ); - - return $font_post; - } - - /** - * Upload a specific custom font and update the CPT. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function upload_fonts( WP_REST_Request $request ) { - $font = $request->get_param( 'font' ) ?? array(); - $variants = $request->get_param( 'variants' ); - $source = $request->get_param( 'source' ); - $slug = $request->get_param( 'slug' ) ?? $font['slug'] ?? ''; - $results = array( - 'ID' => null, - 'variants' => array(), - ); - - // Tweaks variants based on the source if needed. - if ( 'custom' === $source ) { - // Decode the FormData sent via POST. - $variants = json_decode( $variants, true ); - } - - foreach ( $variants as $variant ) { - // Move the uploaded font asset from the temp folder to the fonts directory. - if ( ! function_exists( 'wp_handle_upload' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - $file = $variant['src']; - - // If custom assume the font is being uploaded. - if ( 'custom' === $source ) { - $file_params = $request->get_file_params(); - $file = $file_params[ $variant['src'] ] ?? $variant['src']; - } - - $font_file = GeneratePress_Pro_Font_Library::handle_font_file_upload( $variant, $slug, $file ); - - if ( is_wp_error( $font_file ) ) { - $results['error'][] = array( - 'font' => $variant, - 'message' => $font_file->get_error_message(), - ); - - continue; - } - - // Get the font post for this variant. - $font_post = self::get_font_post( $variant, $slug ); - - if ( is_wp_error( $font_post ) ) { - return $this->error( 500, __( 'Failed to create font post.', 'gp-premium' ) ); - } - - if ( 'google' === $source ) { - $font_family = explode( ', ', $font['fontFamily'] ?? '' ); - // Remove the main font-family. - array_shift( $font_family ); - - // Set the fallback if we can infer one. - if ( $font_family ) { - $fallback = implode( ', ', $font_family ); - update_post_meta( $font_post, 'gp_font_fallback', $fallback ); - } - } - - $existing_variants = get_post_meta( $font_post, 'gp_font_variants', true ); - - if ( ! is_array( $variants ) ) { - $existing_variants = array(); - } - - $checked_variants = GeneratePress_Pro_Font_Library::check_variants( - $existing_variants, - array( - 'src' => $font_file['url'], - 'fontFamily' => $variant['fontFamily'], - 'fontStyle' => $variant['fontStyle'], - 'fontWeight' => $variant['fontWeight'], - 'name' => GeneratePress_Pro_Font_Library::get_variant_name( $variant ), - 'isVariable' => $variant['isVariable'] ?? false, - 'source' => 'custom', - 'disabled' => false, - 'preview' => '', - ) - ); - - // Update the font post meta with merged variants. - update_post_meta( $font_post, 'gp_font_variants', $checked_variants ); - - // Generate the font CSS. - $generate_css = $this->build_css_file(); - - if ( false === $generate_css->data['success'] ) { - return $this->error( 500, __( 'CSS Generation failed', 'gp-premium' ) ); - } - - $results['ID'] = $font_post; - $results['variants'] = $checked_variants; - } - - return $this->success( $results ); - } - - /** - * Get font library settings. - * - * @return mixed - */ - public function get_settings() { - return $this->success( get_option( 'gp_font_library_settings', array() ) ); - } - - /** - * Update font library settings. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function set_settings( WP_REST_Request $request ) { - $settings = $request->get_param( 'settings' ); - $sanitized_settings = array(); - - foreach ( $settings as $setting => $value ) { - if ( 'google_gdpr' === $setting ) { - $sanitized_settings[ $setting ] = (bool) $value; - } elseif ( 'preferred_subset' === $setting ) { - // Stored as an array to support multiple preferred subsets in the future. - $sanitized_settings[ $setting ] = array( sanitize_text_field( $value ) ); - } else { - $sanitized_settings[ $setting ] = sanitize_text_field( $value ); - } - } - - $updated = update_option( - GeneratePress_Pro_Font_Library::SETTINGS_OPTION, - $sanitized_settings, - false - ); - - if ( $updated ) { - // Return success. - return $this->success( - array( - 'message' => __( 'Font settings successfully updated!', 'gp-premium' ), - 'response' => $updated, - 'settings' => $sanitized_settings, - ) - ); - } - - return $this->failed( - array( - 'message' => __( 'Failed to update font settings.', 'gp-premium' ), - 'settings' => $sanitized_settings, - ) - ); - - } - - /** - * Update a font post. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function update_font_post( WP_REST_Request $request ) { - $font_id = $request->get_param( 'id' ); - $status = $request->get_param( 'status' ); - $font_family_alias = $request->get_param( 'alias' ); - $new_variants = $request->get_param( 'newVariants' ); - $delete_variants = $request->get_param( 'deleteVariants' ); - $font_display = $request->get_param( 'fontDisplay' ); - $fallback = $request->get_param( 'fallback' ); - $css_variable = $request->get_param( 'cssVariable' ); - $slug = get_post_field( 'post_name', $font_id ); - - // Update the font post. - wp_update_post( - array( - 'ID' => $font_id, - 'post_status' => $status, - 'meta_input' => array( - 'gp_font_family_alias' => $font_family_alias, - 'gp_font_variants' => $new_variants, - 'gp_font_display' => $font_display, - 'gp_font_fallback' => $fallback, - 'gp_font_variable' => $css_variable, - ), - ) - ); - - $upload_dir = wp_get_upload_dir(); - $base_path = trailingslashit( $upload_dir['basedir'] ) . 'generatepress/fonts/' . $slug . '/'; - foreach ( $delete_variants as $variant ) { - if ( isset( $variant['deleteStatus'] ) && $variant['deleteStatus'] ) { - $file_path = $base_path . basename( $variant['src'] ); - if ( file_exists( $file_path ) ) { - unlink( $file_path ); - } - } - } - - // Regenerate the font CSS. - $this->build_css_file(); - - // Return success. - return $this->success( __( 'Font post successfully updated!', 'gp-premium' ) ); - } - - /** - * Get edit options permissions. - * - * @return bool - */ - public function update_settings_permission() { - return current_user_can( 'manage_options' ); - } - - /** - * Get edit posts permissions. - * - * @return bool - */ - public function edit_posts_permission() { - return current_user_can( 'edit_posts' ); - } - - /** - * Success rest. - * - * @param mixed $response response data. - * @param mixed $data data. - * @return mixed - */ - public function success( $response, $data = null ) { - return new WP_REST_Response( - array( - 'success' => true, - 'response' => $response, - 'data' => $data, - ), - 200 - ); - } - - /** - * Failed rest. - * - * @param mixed $response response data. - * @return mixed - */ - public function failed( $response ) { - return new WP_REST_Response( - array( - 'success' => false, - 'response' => $response, - ), - 200 - ); - } - - /** - * Error rest. - * - * @param mixed $code error code. - * @param mixed $response response data. - * @return mixed - */ - public function error( $code, $response ) { - return new WP_REST_Response( - array( - 'error' => true, - 'success' => false, - 'error_code' => $code, - 'response' => $response, - ), - 500 - ); - } -} - -GeneratePress_Pro_Font_Library_Rest::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library.php deleted file mode 100644 index a8dffd38..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/font-library/class-font-library.php +++ /dev/null @@ -1,840 +0,0 @@ - __( 'Font Library', 'gp-premium' ), - 'url' => self::get_font_library_uri(), - 'class' => 'appearance_page_generatepress-font-library' === $screen->id ? 'active' : '', - 'id' => 'gp-font-library-tab', - ); - - return $tabs; - } - - /** - * Add our menu item. - */ - public function add_menu() { - add_submenu_page( - 'themes.php', - __( 'Font Library', 'gp-premium' ), - __( 'Font Library', 'gp-premium' ), - 'manage_options', - 'generatepress-font-library', - array( $this, 'library_page' ) - ); - } - - /** - * Add our page. - */ - public function library_page() { - echo '
    '; - } - - /** - * Add tags to the head element for the font library page. - */ - public function add_head_tags() { - $screen = get_current_screen(); - $user_id = get_current_user_id(); - $google_gdpr = (bool) self::get_settings( 'google_gdpr' ); - - // Stop if we're not on the right page or the user hasn't opted in to google fonts. - if ( 'appearance_page_generatepress-font-library' !== $screen->id || ! $google_gdpr ) { - return; - } - - echo ' - - - - '; - } - - /** - * Add our scripts. - */ - public function enqueue_scripts() { - $screen = get_current_screen(); - - if ( 'appearance_page_generatepress-font-library' === $screen->id ) { - $assets = generate_premium_get_enqueue_assets( 'font-library' ); - $upload_dir = wp_get_upload_dir(); - - wp_enqueue_script( - 'generatepress-pro-font-library', - GP_PREMIUM_DIR_URL . 'dist/font-library.js', - $assets['dependencies'], - $assets['version'], - true - ); - - if ( function_exists( 'wp_set_script_translations' ) ) { - wp_set_script_translations( 'generatepress-pro-font-library', 'gp-premium', GP_PREMIUM_DIR_PATH . 'langs' ); - } - - wp_localize_script( - 'generatepress-pro-font-library', - 'gppFontLibrary', - array( - 'uploadsUrl' => $upload_dir['baseurl'], - ) - ); - - wp_enqueue_style( - 'generatepress-pro-font-library', - GP_PREMIUM_DIR_URL . 'dist/font-library.css', - array( 'wp-components' ), - GP_PREMIUM_VERSION - ); - } - } - - /** - * Tell GeneratePress this is an admin page. - * - * @param array $screens Existing screens. - */ - public function add_dashboard_screen( $screens ) { - $screens[] = 'appearance_page_generatepress-font-library'; - - return $screens; - } - - /** - * Get font posts. - * - * @param string $name font name. - * - * @return mixed - */ - public static function get_fonts( $name = null ) { - $args = array( - 'post_type' => self::FONT_LIBRARY_CPT, - 'post_status' => 'any', - 'numberposts' => GeneratePress_Pro_Font_Library::FONTS_MAX_QUERY, // phpcs:ignore - 'fields' => 'ids', - 'no_found_rows' => true, - 'update_post_meta_cache' => false, - 'update_post_term_cache' => false, - 'order' => 'ASC', - ); - - if ( $name ) { - $args['name'] = $name; - } - - $all_fonts = get_posts( $args ); - $response = array(); - - if ( is_array( $all_fonts ) ) { - foreach ( $all_fonts as $font_post ) { - $font_name = get_the_title( $font_post ); - $alias = get_post_meta( $font_post, 'gp_font_family_alias', true ); - $slug = get_post_field( 'post_name', $font_post ); - $status = get_post_status( $font_post ); - $fallback = get_post_meta( $font_post, 'gp_font_fallback', true ); - $preview = get_post_meta( $font_post, 'gp_font_preview', true ); - $font_family = empty( $alias ) ? $font_name : $alias; - - $font_family = "\"$font_family\""; - - if ( $fallback ) { - $font_family .= ", $fallback"; - } - - // Setup the font data. - $response[] = array( - 'id' => $font_post, - 'name' => $font_name, - 'fontFamily' => $font_family, - 'disabled' => 'publish' !== $status, - 'slug' => get_post_field( 'post_name', $font_post ), - 'alias' => get_post_meta( $font_post, 'gp_font_family_alias', true ), - 'variants' => get_post_meta( $font_post, 'gp_font_variants', true ), - 'source' => get_post_meta( $font_post, 'gp_font_source', true ), - 'fallback' => $fallback, - 'fontDisplay' => get_post_meta( $font_post, 'gp_font_display', true ), - 'preview' => empty( $preview ) ? '' : $preview, - 'cssVariable' => get_post_meta( $font_post, 'gp_font_variable', true ), - ); - } - - return $response; - } else { - return array(); - } - } - - /** - * Get the font library URI. - * - * @return string - */ - public static function get_font_library_uri() { - return admin_url( 'themes.php?page=generatepress-font-library' ); - } - - /** - * Font format mappings. - * - * @param array $font Array of font data. - * @return string - */ - public static function get_font_face_rule( $font ) { - $css = ''; - if ( ! empty( $font['variants'] ) ) { - $font_family = $font['alias'] ? $font['alias'] : $font['name']; - - foreach ( $font['variants'] as $variant ) { - $is_disabled = $variant['disabled'] ?? false; - - if ( $is_disabled ) { - continue; - } - - $format = self::get_font_format( $variant['src'] ); - $css .= "@font-face { - font-display: {$font['fontDisplay']}; - font-family: \"$font_family\"; - font-style: {$variant['fontStyle']}; - font-weight: {$variant['fontWeight']}; - src: url('{$variant['src']}')$format; -}\n"; - } - } - - return $css; - } - - /** - * Font format mappings. - * - * @param string $font_url File extension. - * @return string|null - */ - private static function get_font_format( $font_url ) { - $extension = pathinfo( $font_url, PATHINFO_EXTENSION ); - - $format_map = array( - 'woff' => 'woff', - 'woff2' => 'woff2', - 'ttf' => 'truetype', - 'otf' => 'opentype', - ); - - $format_string = isset( $format_map[ $extension ] ) ? $format_map[ $extension ] : null; - return $format_string ? " format('$format_string')" : ''; - } - - /** - * Parses a font variant string to determine weight and style. - * Returns an array with 'weight', 'style'. - * - * @param string $variant Font variant string. - * @return array - */ - private static function parse_font_variant( $variant ) { - $weight = '400'; - $style = 'normal'; - - if ( 'regular' === $variant ) { - return array( - 'weight' => $weight, - 'style' => $style, - ); - } - - if ( 'italic' === $variant || strpos( $variant, 'italic' ) !== false ) { - $style = 'italic'; - if ( strpos( $variant, 'italic' ) !== false ) { - $variant = str_replace( 'italic', '', $variant ); - } - } - - return array( - 'weight' => empty( $variant ) ? $weight : $variant, - 'style' => $style, - ); - } - - /** - * Checks if the existing font variant exists. - * - * Overwrite it if it exists, and delete associated font file if different. - * Otherwise, add new variant if not found in the list. - * - * @param array $variants Font variants. - * @param int $new_variant New variant to be added. - * @param string $base_path Base path. - * - * @return array The resolved list of variants. - */ - public static function check_variants( $variants, $new_variant ) { - $checked_variants = $variants; - if ( empty( $variants ) ) { - return array( $new_variant ); - } - - $found = false; - foreach ( $variants as $key => $variant ) { - if ( $variant['name'] === $new_variant['name'] ) { - $checked_variants[ $key ] = $new_variant; - $found = true; - break; - } - } - - if ( ! $found ) { - $checked_variants[] = $new_variant; - } - - return $checked_variants; - } - - /** - * Format uploaded font variant. - * - * @param array $variant Font variant. - * @return string The formatted variant name. - */ - public static function get_variant_name( $variant ) { - // Force variant to array-like structure. - $is_italic = 'italic' === $variant['fontStyle']; - - $labels = array( - '100' => 'Thin 100', - '200' => 'ExtraLight 200', - '250' => 'ExtraLight 250', - '300' => 'Light 300', - '400' => 'Regular 400', - 'regular' => 'Regular 400', - '500' => 'Medium 500', - '600' => 'SemiBold 600', - '700' => 'Bold 700', - '800' => 'ExtraBold 800', - '900' => 'Black 900', - ); - - $resolved_label = $labels[ $variant['fontWeight'] ]; - - if ( $resolved_label ) { - return $resolved_label . ( $is_italic ? ' Italic' : '' ); - } - - return str_replace( ' ', '-', $variant['fontWeight'] ) . ' ' . __( '(Variable)', 'gp-premium' ); - } - - /** - * Format a font file name to remove spaces, commas. - * - * @param string $name Font name. - * @return string - */ - public static function format_font_filename( $name ) { - // Replace spaces and commas in file name with hyphen. - $name = preg_replace( '/[ ,]/', '-', $name ); - return $name; - } - - /** - * Returns the expected mime-type values for font files, depending on PHP version. - * - * This is needed because font mime types vary by PHP version, so checking the PHP version - * is necessary until a list of valid mime-types for each file extension can be provided to - * the 'upload_mimes' filter. - * - * @return array A collection of mime types keyed by file extension. - */ - public static function get_allowed_font_mime_types() { - $php_7_ttf_mime_type = PHP_VERSION_ID >= 70300 ? 'application/font-sfnt' : 'application/x-font-ttf'; - - return array( - 'otf' => 'application/vnd.ms-opentype', - 'ttf' => PHP_VERSION_ID >= 70400 ? 'font/sfnt' : $php_7_ttf_mime_type, - 'woff' => PHP_VERSION_ID >= 80112 ? 'font/woff' : 'application/font-woff', - 'woff2' => PHP_VERSION_ID >= 80112 ? 'font/woff2' : 'application/font-woff2', - ); - } - - /** - * Get the font CSS file. - * - * @param string $type Type of path to return. Can return the `path` or `url` to the file. - * @return string - */ - public static function get_font_css_file( $type ) { - $upload_dir = wp_get_upload_dir(); - $file_path = 'generatepress/fonts/fonts.css'; - $base = ''; - - if ( 'url' === $type ) { - $base = $upload_dir['baseurl']; - } elseif ( 'path' === $type ) { - $base = $upload_dir['basedir']; - } - - return $base ? trailingslashit( $base ) . $file_path : ''; - } - - /** - * Get the font CSS file URL. - * - * @return string - */ - public static function get_font_css_file_url() { - $css_file_url = self::get_font_css_file( 'url' ); - $css_file_dir = self::get_font_css_file( 'path' ); - - return file_exists( $css_file_dir ) - ? $css_file_url - : ''; - } - - /** - * Add our font CSS. - */ - public function enqueue_font_css() { - $font_file_url = self::get_font_css_file_url(); - - // Enqueue the custom fonts CSS if the file exists. - if ( $font_file_url ) { - $version = filemtime( self::get_font_css_file( 'path' ) ) ?? GP_PREMIUM_VERSION; - - wp_enqueue_style( 'generatepress-fonts', $font_file_url, array(), $version ); - } - } - - /** - * Add a font to the uploads directory either from $_FILES or a remote URL. - * - * @param array $variant Font variant object. - * @param string $slug Font slug. - * @param array|null $file Single file item from $_FILES or null. - * @return array|WP_Error Array containing uploaded file attributes on success, or WP_Error object on failure. - */ - public static function handle_font_file_upload( $variant, $slug, $file ) { - if ( ! $slug ) { - $slug = $variant['slug'] ?? ''; - } - $upload_dir = wp_get_upload_dir(); - $base_path = trailingslashit( $upload_dir['basedir'] ) . 'generatepress/fonts/' . $slug . '/'; - - // Ensure the directory exists. - if ( ! file_exists( $base_path ) ) { - wp_mkdir_p( $base_path ); - } - - /** - * If $file is an array, assume it's a param from $_FILES. - */ - if ( is_array( $file ) ) { - $file_name = basename( $file['name'] ); - $file_path = $base_path . $file_name; - - // Check if the font file exists and delete it if so. - if ( file_exists( $file_path ) ) { - unlink( $file_path ); - } - - $set_upload_dir = function ( $font_dir ) use ( $base_path, $slug ) { - $font_dir['path'] = $base_path; - $font_dir['url'] = untrailingslashit( - content_url( 'uploads/generatepress/fonts/' . $slug ) - ); - $font_dir['subdir'] = ''; - return $font_dir; - }; - - add_filter( 'upload_mimes', array( __CLASS__, 'get_allowed_font_mime_types' ) ); - add_filter( 'upload_dir', $set_upload_dir ); - - $overrides = array( - 'upload_error_handler' => array( __CLASS__, 'handle_font_file_upload_error' ), - // Not testing a form submission. - 'test_form' => false, - // Only allow uploading font files for this request. - 'mimes' => self::get_allowed_font_mime_types(), - ); - - $uploaded_file = wp_handle_upload( $file, $overrides ); - - remove_filter( 'upload_dir', $set_upload_dir ); - remove_filter( 'upload_mimes', array( __CLASS__, 'get_allowed_font_mime_types' ) ); - - return $uploaded_file; - } - - $file_name = basename( $variant['src'] ); - $file_path = $base_path . $file_name; - - $response = wp_remote_get( $variant['src'] ); - - if ( is_wp_error( $response ) ) { - $error_message = $response->get_error_message(); - return new WP_Error( 500, "Failed to download {$variant['fontFamily']} from {$variant['src']}: $error_message" ); - } - - // Save the file. - $filesystem = generate_premium_get_wp_filesystem(); - - if ( ! $filesystem ) { - return new WP_Error( 500, 'Error setting up the file system object.' ); - } - - $file_contents = wp_remote_retrieve_body( $response ); - - if ( ! $file_contents ) { - return new WP_Error( 500, "Failed to download $variant from {$variant['src']}: Empty body" ); - } - - // Assuming $filesystem is already set up correctly. - $chmod_file = defined( 'FS_CHMOD_FILE' ) ? FS_CHMOD_FILE : 0644; - - if ( is_writable( $file_path ) || is_writable( dirname( $file_path ) ) ) { - if ( $filesystem->put_contents( $file_path, $file_contents, $chmod_file ) ) { - return array( - 'file' => $file_path, - 'url' => trailingslashit( $upload_dir['baseurl'] ) . 'generatepress/fonts/' . $slug . '/' . $file_name, - ); - } else { - return new WP_Error( 500, "Failed to download $variant from {$variant['src']}." ); - } - } - - return new WP_Error( 500, 'Unable to write to file path.' ); - } - - /** - * Handles file upload error. - * - * @param array $file File upload data. - * @param string $message Error message from wp_handle_upload(). - * @return WP_Error WP_Error object. - */ - public static function handle_font_file_upload_error( $file, $message ) { - $status = 500; - $code = 'rest_font_upload_unknown_error'; - - // Note: The absence of a text domain is intentional here as it's checking against a WP core string. - if ( __( 'Sorry, you are not allowed to upload this file type.' ) === $message ) { - $status = 400; - $code = 'rest_font_upload_invalid_file_type'; - } - - return new WP_Error( $code, $message, array( 'status' => $status ) ); - } - - /** - * Runs on wp_after_insert_post to download remote font files. - * - * @param int $post_id Post ID. - * @param string $key The meta key that was imported. - * @param mixed $value The meta value that was imported. - * @return void - */ - public function update_post_meta( $post_id, $key, $value ) { - $upload_dir = wp_get_upload_dir(); - // Bail if we're not working with a font library post variant meta value. - if ( get_post_type( $post_id ) !== self::FONT_LIBRARY_CPT || 'gp_font_variants' !== $key ) { - return; - } - - // Check the src of each variant and if the URL is remote, download the file. - $variants = $value; - - // Stop here if variants aren't found. - if ( ! $variants ) { - return; - } - - foreach ( $variants as &$variant ) { - $site_hostname = wp_parse_url( site_url(), PHP_URL_HOST ); - - // Bail if the variant src is already on this site. - if ( strpos( $variant['src'], $site_hostname ) !== false ) { - continue; - } - - $font_slug = get_post_field( 'post_name', $post_id ); - $font_dir = trailingslashit( $upload_dir['basedir'] ) . 'generatepress/fonts/' . $font_slug . '/'; - $font_base_url = trailingslashit( $upload_dir['baseurl'] ) . 'generatepress/fonts/' . $font_slug . '/'; - $response = wp_remote_get( $variant['src'] ); - $response_code = (int) wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code ) { - continue; - } - - $file_name = basename( $variant['src'] ); - $file_path = $font_dir . $file_name; - - // If the directory exists, remove it and it's contents. - if ( ! file_exists( $font_dir ) ) { - wp_mkdir_p( $font_dir ); - } - - // Setup filesystem. - $filesystem = generate_premium_get_wp_filesystem(); - - // Bail here if the filesystem can't initialize. - if ( ! $filesystem ) { - continue; - } - - $file_contents = wp_remote_retrieve_body( $response ); - - // Bail if file contents are empty or not found. - if ( ! $file_contents ) { - continue; - } - - $chmod_file = defined( 'FS_CHMOD_FILE' ) ? FS_CHMOD_FILE : 0644; - - if ( is_writable( $file_path ) || is_writable( dirname( $file_path ) ) ) { - // Bail if the file can't be written. - if ( ! $filesystem->put_contents( $file_path, $file_contents, $chmod_file ) ) { - continue; - } - } - - $variant['src'] = $font_base_url . $file_name; - } - - // Update the meta value with the new src for each variant. - update_post_meta( $post_id, 'gp_font_variants', $variants ); - } - - /** - * Recursive function to delete a directory and its contents. - * - * @param string $dir directory path. - * @return bool - */ - public static function delete_directory( $dir ) { - if ( ! file_exists( $dir ) ) { - return true; - } - - if ( ! is_dir( $dir ) ) { - return unlink( $dir ); - } - - foreach ( scandir( $dir ) as $item ) { - if ( '.' === $item || '..' === $item ) { - continue; - } - - if ( ! self::delete_directory( $dir . DIRECTORY_SEPARATOR . $item ) ) { - return false; - } - } - - return rmdir( $dir ); - } - - /** - * Check if the post exists by checking the title. - * - * @param bool $post_exists Unused. The default post_exists function value. - * @param array $font The font post array. - * @return int Post ID on success, 0 on failure. - */ - public function maybe_font_exists( $post_exists, $font ) { - /** - * The value of $font here is a post array from the XML import, not our standard - * font array. We need to check if the font exists by title. - */ - return post_exists( $font['post_title'] ); - } - - /** - * Get the CSS variables and values for each font-family. - * - * @return string The color palette variable CSS declaration. - */ - public static function get_css_variables() { - $fonts = self::get_fonts(); - - if ( ! $fonts ) { - return ''; - } - - $variables = ":root {\n"; - - foreach ( $fonts as $font ) { - if ( isset( $font['disabled'] ) && $font['disabled'] ) { - continue; - } - - $variables .= sprintf( - "%s: %s;\n", - $font['cssVariable'], - $font['fontFamily'] - ); - } - - $variables .= "}\n"; - - return $variables; - } - - /** - * Add CSS variable definitions to the block editor. - * - * @param string $css The generated CSS for the stylesheet. - * @return void - **/ - public function add_variable_definitions_to_editor( $css ) { - wp_add_inline_style( 'generateblocks-pro', self::get_css_variables() ); - } - - /** - * Build the font CSS file. - * - * @return string|WP_Error The file path on success, WP_Error on failure. - */ - public static function build_css_file() { - $generated_css = self::generate_font_css(); - $upload_dir = wp_get_upload_dir(); - - // Save the generated font CSS to a file. - $base_path_dir = trailingslashit( $upload_dir['basedir'] ) . 'generatepress/fonts/'; - $file_path = $base_path_dir . 'fonts.css'; - $filesystem = generate_premium_get_wp_filesystem(); - - if ( ! $filesystem ) { - return new WP_Error( 500, __( 'Error setting up the file system object.', 'gp-premium' ) ); - } - - // Assuming $filesystem is already set up correctly. - $chmod_file = defined( 'FS_CHMOD_FILE' ) ? FS_CHMOD_FILE : 0644; - - if ( empty( $generated_css ) ) { - if ( file_exists( $file_path ) ) { - $filesystem->delete( $file_path ); - } - } else { - if ( is_writable( $file_path ) || is_writable( dirname( $file_path ) ) ) { - if ( ! $filesystem->put_contents( $file_path, $generated_css, $chmod_file ) ) { - return new WP_Error( 500, __( 'Failed to write Google font CSS to file.', 'gp-premium' ) ); - } - } - } - - return $file_path; - } - - /** - * Generate font CSS. - * - * @return mixed - */ - public static function generate_font_css() { - $fonts = self::get_fonts(); - $variables = self::get_css_variables(); - $css = $variables . "\n"; - - if ( $fonts ) { - foreach ( $fonts as $font ) { - // Add the generated CSS. - $css .= self::get_font_face_rule( $font ); - } - } - - return apply_filters( 'generatepress_font_css', $css, $fonts ); - } - - /** - * Add the font CSS to the block editor. - * - * @param array $settings The block editor settings. - * @return array - */ - public function add_fonts_to_editor( $settings ) { - $font_file_url = self::get_font_css_file_url(); - - if ( ! $font_file_url ) { - return $settings; - } - - $fonts_import = sprintf( - '@import url("%s");', - $font_file_url - ); - - $settings['styles'][] = array( 'css' => $fonts_import ); - - return $settings; - } - - /** - * Get font library settings. At the moment this is just the Google GDPR setting. - * - * @param string $setting The setting to retrieve. - * @return mixed - */ - public static function get_settings( $setting = null ) { - - $settings = get_option( self::SETTINGS_OPTION, array() ); - - if ( $setting ) { - return $settings[ $setting ] ?? null; - } - - return $settings; - } -} - -GeneratePress_Pro_Font_Library::get_instance()->init(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/class-external-file-css.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/class-external-file-css.php deleted file mode 100644 index 9f59b66c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/class-external-file-css.php +++ /dev/null @@ -1,449 +0,0 @@ -register_control_type( 'GeneratePress_Action_Button_Control' ); - } - - $wp_customize->add_setting( - 'generate_settings[css_print_method]', - array( - 'default' => $defaults['css_print_method'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_settings[css_print_method]', - array( - 'type' => 'select', - 'label' => __( 'Dynamic CSS Print Method', 'gp-premium' ), - 'description' => __( 'Generating your dynamic CSS in an external file offers significant performance advantages.', 'gp-premium' ), - 'section' => 'generate_general_section', - 'choices' => array( - 'inline' => __( 'Inline Embedding', 'gp-premium' ), - 'file' => __( 'External File', 'gp-premium' ), - ), - 'settings' => 'generate_settings[css_print_method]', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Action_Button_Control( - $wp_customize, - 'generate_regenerate_external_css_file', - array( - 'section' => 'generate_general_section', - 'data_type' => 'regenerate_external_css', - 'nonce' => esc_html( wp_create_nonce( 'generatepress_regenerate_css_file' ) ), - 'label' => __( 'Regenerate CSS File', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => 'generate_is_using_external_css_file_callback', - ) - ) - ); - } - - /** - * Set our CSS Print Method. - * - * @param string $method The existing method. - */ - public function set_print_method( $method ) { - if ( ! function_exists( 'generate_get_option' ) ) { - return $method; - } - - return generate_get_option( 'css_print_method' ); - } - - /** - * Determine if we're using file mode or inline mode. - */ - public function mode() { - $mode = generate_get_css_print_method(); - - if ( 'file' === $mode && $this->needs_update() ) { - $data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( ! isset( $data['updated_time'] ) ) { - // No time set, so set the current time minus 5 seconds so the file is still generated. - $data['updated_time'] = time() - 5; - update_option( 'generatepress_dynamic_css_data', $data ); - } - - // Only allow processing 1 file every 5 seconds. - $current_time = (int) time(); - $last_time = (int) $data['updated_time']; - - if ( 5 <= ( $current_time - $last_time ) ) { - - // Attempt to write to the file. - $mode = ( $this->can_write() && $this->make_css() ) ? 'file' : 'inline'; - - // Does again if the file exists. - if ( 'file' === $mode ) { - $mode = ( file_exists( $this->file( 'path' ) ) ) ? 'file' : 'inline'; - } - } - } - - return $mode; - } - - /** - * Set things up. - */ - public function init() { - if ( 'file' === $this->mode() ) { - add_filter( 'generate_using_dynamic_css_external_file', '__return_true' ); - add_filter( 'generate_dynamic_css_skip_cache', '__return_true', 20 ); - - // Remove inline CSS in GP < 3.0.0. - if ( ! function_exists( 'generate_get_dynamic_css' ) && function_exists( 'generate_enqueue_dynamic_css' ) ) { - remove_action( 'wp_enqueue_scripts', 'generate_enqueue_dynamic_css', 50 ); - } - } - } - - /** - * Enqueue the dynamic CSS. - */ - public function enqueue_dynamic_css() { - if ( 'file' === $this->mode() ) { - wp_enqueue_style( 'generatepress-dynamic', esc_url( $this->file( 'uri' ) ), array( 'generate-style' ), null ); // phpcs:ignore WordPress.WP.EnqueuedResourceParameters.MissingVersion - - // Move the child theme after our dynamic stylesheet. - if ( is_child_theme() && wp_style_is( 'generate-child', 'enqueued' ) ) { - wp_dequeue_style( 'generate-child' ); - wp_enqueue_style( 'generate-child' ); - } - - // Re-add no-cache CSS in GP < 3.0.0. - if ( ! function_exists( 'generate_get_dynamic_css' ) && function_exists( 'generate_no_cache_dynamic_css' ) ) { - $nocache_css = generate_no_cache_dynamic_css(); - - if ( function_exists( 'generate_do_icon_css' ) ) { - $nocache_css .= generate_do_icon_css(); - } - - wp_add_inline_style( 'generate-style', wp_strip_all_tags( $nocache_css ) ); - } - } - } - - /** - * Make our CSS. - */ - public function make_css() { - $content = ''; - - if ( function_exists( 'generate_get_dynamic_css' ) ) { - $content = generate_get_dynamic_css(); - } elseif ( function_exists( 'generate_base_css' ) && function_exists( 'generate_font_css' ) && function_exists( 'generate_advanced_css' ) && function_exists( 'generate_spacing_css' ) ) { - $content = generate_base_css() . generate_font_css() . generate_advanced_css() . generate_spacing_css(); - } - - $content = apply_filters( 'generate_external_dynamic_css_output', $content ); - - if ( ! $content ) { - return false; - } - - $filesystem = generate_premium_get_wp_filesystem(); - - if ( ! $filesystem ) { - return false; - } - - // Take care of domain mapping. - if ( defined( 'DOMAIN_MAPPING' ) && DOMAIN_MAPPING ) { - if ( function_exists( 'domain_mapping_siteurl' ) && function_exists( 'get_original_url' ) ) { - $mapped_domain = domain_mapping_siteurl( false ); - $original_domain = get_original_url( 'siteurl' ); - - $content = str_replace( $original_domain, $mapped_domain, $content ); - } - } - - if ( is_writable( $this->file( 'path' ) ) || ( ! file_exists( $this->file( 'path' ) ) && is_writable( dirname( $this->file( 'path' ) ) ) ) ) { - $chmod_file = 0644; - - if ( defined( 'FS_CHMOD_FILE' ) ) { - $chmod_file = FS_CHMOD_FILE; - } - - if ( ! $filesystem->put_contents( $this->file( 'path' ), wp_strip_all_tags( $content ), $chmod_file ) ) { - - // Fail! - return false; - - } else { - - $this->update_saved_time(); - - // Success! - return true; - - } - } - } - - /** - * Determines if the CSS file is writable. - */ - public function can_write() { - global $blog_id; - - // Get the upload directory for this site. - $upload_dir = wp_get_upload_dir(); - - // If this is a multisite installation, append the blogid to the filename. - $css_blog_id = ( is_multisite() && $blog_id > 1 ) ? '_blog-' . $blog_id : null; - - $file_name = '/style' . $css_blog_id . '.min.css'; - $folder_path = $upload_dir['basedir'] . DIRECTORY_SEPARATOR . 'generatepress'; - - // Does the folder exist? - if ( file_exists( $folder_path ) ) { - // Folder exists, but is the folder writable? - if ( ! is_writable( $folder_path ) ) { - // Folder is not writable. - // Does the file exist? - if ( ! file_exists( $folder_path . $file_name ) ) { - // File does not exist, therefore it can't be created - // since the parent folder is not writable. - return false; - } else { - // File exists, but is it writable? - if ( ! is_writable( $folder_path . $file_name ) ) { - // Nope, it's not writable. - return false; - } - } - } else { - // The folder is writable. - // Does the file exist? - if ( file_exists( $folder_path . $file_name ) ) { - // File exists. - // Is it writable? - if ( ! is_writable( $folder_path . $file_name ) ) { - // Nope, it's not writable. - return false; - } - } - } - } else { - // Can we create the folder? - // returns true if yes and false if not. - return wp_mkdir_p( $folder_path ); - } - - // all is well! - return true; - } - - /** - * Gets the css path or url to the stylesheet - * - * @param string $target path/url. - */ - public function file( $target = 'path' ) { - global $blog_id; - - // Get the upload directory for this site. - $upload_dir = wp_get_upload_dir(); - - // If this is a multisite installation, append the blogid to the filename. - $css_blog_id = ( is_multisite() && $blog_id > 1 ) ? '_blog-' . $blog_id : null; - - $file_name = 'style' . $css_blog_id . '.min.css'; - $folder_path = $upload_dir['basedir'] . DIRECTORY_SEPARATOR . 'generatepress'; - - // The complete path to the file. - $file_path = $folder_path . DIRECTORY_SEPARATOR . $file_name; - - // Get the URL directory of the stylesheet. - $css_uri_folder = $upload_dir['baseurl']; - - $css_uri = trailingslashit( $css_uri_folder ) . 'generatepress/' . $file_name; - - // Take care of domain mapping. - if ( defined( 'DOMAIN_MAPPING' ) && DOMAIN_MAPPING ) { - if ( function_exists( 'domain_mapping_siteurl' ) && function_exists( 'get_original_url' ) ) { - $mapped_domain = domain_mapping_siteurl( false ); - $original_domain = get_original_url( 'siteurl' ); - $css_uri = str_replace( $original_domain, $mapped_domain, $css_uri ); - } - } - - $css_uri = set_url_scheme( $css_uri ); - - if ( 'path' === $target ) { - return $file_path; - } elseif ( 'url' === $target || 'uri' === $target ) { - $timestamp = ( file_exists( $file_path ) ) ? '?ver=' . filemtime( $file_path ) : ''; - return $css_uri . $timestamp; - } - } - - /** - * Update the our updated file time. - */ - public function update_saved_time() { - $data = get_option( 'generatepress_dynamic_css_data', array() ); - $data['updated_time'] = time(); - - update_option( 'generatepress_dynamic_css_data', $data ); - } - - /** - * Delete the saved time. - */ - public function delete_saved_time() { - $data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $data['updated_time'] ) ) { - unset( $data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $data ); - } - - /** - * Update our plugin/theme versions. - */ - public function update_versions() { - $data = get_option( 'generatepress_dynamic_css_data', array() ); - - $data['theme_version'] = GENERATE_VERSION; - $data['plugin_version'] = GP_PREMIUM_VERSION; - - update_option( 'generatepress_dynamic_css_data', $data ); - } - - /** - * Do we need to update the CSS file? - */ - public function needs_update() { - $data = get_option( 'generatepress_dynamic_css_data', array() ); - $update = false; - - // If there's no updated time, needs update. - // The time is set in mode(). - if ( ! isset( $data['updated_time'] ) ) { - $update = true; - } - - // If we haven't set our versions, do so now. - if ( ! isset( $data['theme_version'] ) && ! isset( $data['plugin_version'] ) ) { - $update = true; - $this->update_versions(); - - // Bail early so we don't check undefined versions below. - return $update; - } - - // Version numbers have changed, needs update. - if ( (string) GENERATE_VERSION !== (string) $data['theme_version'] || (string) GP_PREMIUM_VERSION !== (string) $data['plugin_version'] ) { - $update = true; - $this->update_versions(); - } - - return $update; - } - - /** - * Regenerate the CSS file. - */ - public function regenerate_css_file() { - check_ajax_referer( 'generatepress_regenerate_css_file', '_nonce' ); - - if ( ! current_user_can( 'manage_options' ) ) { - wp_send_json_error( __( 'Security check failed.', 'gp-premium' ) ); - } - - $this->delete_saved_time(); - - wp_send_json_success(); - } -} - -GeneratePress_External_CSS_File::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/enqueue-scripts.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/enqueue-scripts.php deleted file mode 100644 index a9108a61..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/enqueue-scripts.php +++ /dev/null @@ -1,81 +0,0 @@ - $data ) { - $type = esc_html( GeneratePress_Elements_Helper::get_element_type_label( $data['type'] ) ); - - $active_elements[] = array( - 'type' => $type, - 'name' => get_the_title( $data['id'] ), - 'url' => get_edit_post_link( $data['id'] ), - ); - } - } - - $post_type_is_public = false; - - if ( get_post_type() ) { - $post_type = get_post_type_object( get_post_type() ); - - if ( is_object( $post_type ) && ! empty( $post_type->public ) ) { - $post_type_is_public = true; - } - } - - wp_localize_script( - 'gp-premium-editor', - 'gpPremiumEditor', - array( - 'isBlockElement' => 'gp_elements' === get_post_type(), - 'activeElements' => $active_elements, - 'elementsUrl' => esc_url( admin_url( 'edit.php?post_type=gp_elements' ) ), - 'postTypeIsPublic' => $post_type_is_public, - ) - ); - - wp_enqueue_style( - 'gp-premium-editor', - GP_PREMIUM_DIR_URL . 'dist/editor.css', - array( 'wp-edit-blocks' ), - filemtime( GP_PREMIUM_DIR_PATH . 'dist/editor.css' ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons.php deleted file mode 100644 index 1b587f4c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons.php +++ /dev/null @@ -1,87 +0,0 @@ - - - - - - '; - } - - if ( 'shopping-cart' === $icon ) { - $svg = ''; - } - - if ( 'shopping-basket' === $icon ) { - $svg = ''; - } - - if ( 'spinner' === $icon ) { - $svg = ''; - } - - if ( 'pro-menu-bars' === $icon ) { - $svg = ''; - } - - if ( 'pro-close' === $icon ) { - $svg = ''; - } - - if ( $svg ) { - $output = sprintf( - ' - %2$s - ', - $icon, - $svg - ); - } - - return $output; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.eot b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.eot deleted file mode 100644 index 72d97394..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.eot and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.svg b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.svg deleted file mode 100644 index e1c517d0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.svg +++ /dev/null @@ -1,20 +0,0 @@ - - - -Generated by IcoMoon - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.ttf b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.ttf deleted file mode 100644 index 4bae85f6..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.ttf and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.woff b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.woff deleted file mode 100644 index 01c2cc17..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/gp-premium.woff and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/icons.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/icons.css deleted file mode 100644 index be13090e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/icons.css +++ /dev/null @@ -1,10 +0,0 @@ -@font-face { - font-family: 'GP Premium'; - src: url('gp-premium.eot'); - src: url('gp-premium.eot#iefix') format('embedded-opentype'), - url('gp-premium.woff') format('woff'), - url('gp-premium.ttf') format('truetype'), - url('gp-premium.svg#gp-premium') format('svg'); - font-weight: normal; - font-style: normal; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/icons.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/icons.min.css deleted file mode 100644 index 442a46bd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/icons/icons.min.css +++ /dev/null @@ -1 +0,0 @@ -@font-face{font-family:'GP Premium';src:url(gp-premium.eot);src:url(gp-premium.eot#iefix) format('embedded-opentype'),url(gp-premium.woff) format('woff'),url(gp-premium.ttf) format('truetype'),url(gp-premium.svg#gp-premium) format('svg');font-weight:400;font-style:normal} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/js/smooth-scroll.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/js/smooth-scroll.js deleted file mode 100644 index c2a8a5f7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/js/smooth-scroll.js +++ /dev/null @@ -1,743 +0,0 @@ -/*! - * smooth-scroll v14.2.1: Animate scrolling to anchor links - * (c) 2018 Chris Ferdinandi - * MIT License - * http://github.com/cferdinandi/smooth-scroll - */ - -/** - * closest() polyfill - * @link https://developer.mozilla.org/en-US/docs/Web/API/Element/closest#Polyfill - */ -if (window.Element && !Element.prototype.closest) { - Element.prototype.closest = function(s) { - var matches = (this.document || this.ownerDocument).querySelectorAll(s), - i, - el = this; - do { - i = matches.length; - while (--i >= 0 && matches.item(i) !== el) {} - } while ((i < 0) && (el = el.parentElement)); - return el; - }; -} - -/** - * CustomEvent() polyfill - * https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent/CustomEvent#Polyfill - */ -(function () { - - if (typeof window.CustomEvent === "function") return false; - - function CustomEvent(event, params) { - params = params || { bubbles: false, cancelable: false, detail: undefined }; - var evt = document.createEvent('CustomEvent'); - evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail); - return evt; - } - - CustomEvent.prototype = window.Event.prototype; - - window.CustomEvent = CustomEvent; -})(); -/** - * requestAnimationFrame() polyfill - * By Erik Möller. Fixes from Paul Irish and Tino Zijdel. - * @link http://paulirish.com/2011/requestanimationframe-for-smart-animating/ - * @link http://my.opera.com/emoller/blog/2011/12/20/requestanimationframe-for-smart-er-animating - * @license MIT - */ -(function() { - var lastTime = 0; - var vendors = ['ms', 'moz', 'webkit', 'o']; - for(var x = 0; x < vendors.length && !window.requestAnimationFrame; ++x) { - window.requestAnimationFrame = window[vendors[x]+'RequestAnimationFrame']; - window.cancelAnimationFrame = window[vendors[x]+'CancelAnimationFrame'] || - window[vendors[x]+'CancelRequestAnimationFrame']; - } - - if (!window.requestAnimationFrame) { - window.requestAnimationFrame = function(callback, element) { - var currTime = new Date().getTime(); - var timeToCall = Math.max(0, 16 - (currTime - lastTime)); - var id = window.setTimeout((function() { callback(currTime + timeToCall); }), - timeToCall); - lastTime = currTime + timeToCall; - return id; - }; - } - - if (!window.cancelAnimationFrame) { - window.cancelAnimationFrame = function(id) { - clearTimeout(id); - }; - } -}()); - -(function (root, factory) { - if (typeof define === 'function' && define.amd) { - define([], (function () { - return factory(root); - })); - } else if (typeof exports === 'object') { - module.exports = factory(root); - } else { - root.SmoothScroll = factory(root); - } -})(typeof global !== 'undefined' ? global : typeof window !== 'undefined' ? window : this, (function (window) { - - 'use strict'; - - // - // Default settings - // - - var defaults = { - // Selectors - ignore: '[data-scroll-ignore]', - header: null, - topOnEmptyHash: true, - - // Speed & Easing - speed: 500, - clip: true, - offset: 0, - easing: 'easeInOutCubic', - customEasing: null, - - // History - updateURL: true, - popstate: true, - - // Custom Events - emitEvents: true - }; - - - // - // Utility Methods - // - - /** - * Check if browser supports required methods - * @return {Boolean} Returns true if all required methods are supported - */ - var supports = function () { - return ( - 'querySelector' in document && - 'addEventListener' in window && - 'requestAnimationFrame' in window && - 'closest' in window.Element.prototype - ); - }; - - /** - * Merge two or more objects. Returns a new object. - * @param {Object} objects The objects to merge together - * @returns {Object} Merged values of defaults and options - */ - var extend = function () { - - // Variables - var extended = {}; - - // Merge the object into the extended object - var merge = function (obj) { - for (var prop in obj) { - if (obj.hasOwnProperty(prop)) { - extended[prop] = obj[prop]; - } - } - }; - - // Loop through each object and conduct a merge - for (var i = 0; i < arguments.length; i++) { - merge(arguments[i]); - } - - return extended; - - }; - - /** - * Check to see if user prefers reduced motion - * @param {Object} settings Script settings - */ - var reduceMotion = function (settings) { - if ('matchMedia' in window && window.matchMedia('(prefers-reduced-motion)').matches) { - return true; - } - return false; - }; - - /** - * Get the height of an element. - * @param {Node} elem The element to get the height of - * @return {Number} The element's height in pixels - */ - var getHeight = function (elem) { - return parseInt(window.getComputedStyle(elem).height, 10); - }; - - /** - * Decode a URI, with error check - * @param {String} hash The URI to decode - * @return {String} A decoded URI (or the original string if an error is thrown) - */ - var decode = function (hash) { - var decoded; - try { - decoded = decodeURIComponent(hash); - } catch(e) { - decoded = hash; - } - return decoded; - }; - - /** - * Escape special characters for use with querySelector - * @author Mathias Bynens - * @link https://github.com/mathiasbynens/CSS.escape - * @param {String} id The anchor ID to escape - */ - var escapeCharacters = function (id) { - - // Remove leading hash - if (id.charAt(0) === '#') { - id = id.substr(1); - } - - var string = String(id); - var length = string.length; - var index = -1; - var codeUnit; - var result = ''; - var firstCodeUnit = string.charCodeAt(0); - while (++index < length) { - codeUnit = string.charCodeAt(index); - // Note: there’s no need to special-case astral symbols, surrogate - // pairs, or lone surrogates. - - // If the character is NULL (U+0000), then throw an - // `InvalidCharacterError` exception and terminate these steps. - if (codeUnit === 0x0000) { - throw new InvalidCharacterError( - 'Invalid character: the input contains U+0000.' - ); - } - - if ( - // If the character is in the range [\1-\1F] (U+0001 to U+001F) or is - // U+007F, […] - (codeUnit >= 0x0001 && codeUnit <= 0x001F) || codeUnit == 0x007F || - // If the character is the first character and is in the range [0-9] - // (U+0030 to U+0039), […] - (index === 0 && codeUnit >= 0x0030 && codeUnit <= 0x0039) || - // If the character is the second character and is in the range [0-9] - // (U+0030 to U+0039) and the first character is a `-` (U+002D), […] - ( - index === 1 && - codeUnit >= 0x0030 && codeUnit <= 0x0039 && - firstCodeUnit === 0x002D - ) - ) { - // http://dev.w3.org/csswg/cssom/#escape-a-character-as-code-point - result += '\\' + codeUnit.toString(16) + ' '; - continue; - } - - // If the character is not handled by one of the above rules and is - // greater than or equal to U+0080, is `-` (U+002D) or `_` (U+005F), or - // is in one of the ranges [0-9] (U+0030 to U+0039), [A-Z] (U+0041 to - // U+005A), or [a-z] (U+0061 to U+007A), […] - if ( - codeUnit >= 0x0080 || - codeUnit === 0x002D || - codeUnit === 0x005F || - codeUnit >= 0x0030 && codeUnit <= 0x0039 || - codeUnit >= 0x0041 && codeUnit <= 0x005A || - codeUnit >= 0x0061 && codeUnit <= 0x007A - ) { - // the character itself - result += string.charAt(index); - continue; - } - - // Otherwise, the escaped character. - // http://dev.w3.org/csswg/cssom/#escape-a-character - result += '\\' + string.charAt(index); - - } - - // Return sanitized hash - var hash; - try { - hash = decodeURIComponent('#' + result); - } catch(e) { - hash = '#' + result; - } - return hash; - - }; - - /** - * Calculate the easing pattern - * @link https://gist.github.com/gre/1650294 - * @param {String} type Easing pattern - * @param {Number} time Time animation should take to complete - * @returns {Number} - */ - var easingPattern = function (settings, time) { - var pattern; - - // Default Easing Patterns - if (settings.easing === 'easeInQuad') pattern = time * time; // accelerating from zero velocity - if (settings.easing === 'easeOutQuad') pattern = time * (2 - time); // decelerating to zero velocity - if (settings.easing === 'easeInOutQuad') pattern = time < 0.5 ? 2 * time * time : -1 + (4 - 2 * time) * time; // acceleration until halfway, then deceleration - if (settings.easing === 'easeInCubic') pattern = time * time * time; // accelerating from zero velocity - if (settings.easing === 'easeOutCubic') pattern = (--time) * time * time + 1; // decelerating to zero velocity - if (settings.easing === 'easeInOutCubic') pattern = time < 0.5 ? 4 * time * time * time : (time - 1) * (2 * time - 2) * (2 * time - 2) + 1; // acceleration until halfway, then deceleration - if (settings.easing === 'easeInQuart') pattern = time * time * time * time; // accelerating from zero velocity - if (settings.easing === 'easeOutQuart') pattern = 1 - (--time) * time * time * time; // decelerating to zero velocity - if (settings.easing === 'easeInOutQuart') pattern = time < 0.5 ? 8 * time * time * time * time : 1 - 8 * (--time) * time * time * time; // acceleration until halfway, then deceleration - if (settings.easing === 'easeInQuint') pattern = time * time * time * time * time; // accelerating from zero velocity - if (settings.easing === 'easeOutQuint') pattern = 1 + (--time) * time * time * time * time; // decelerating to zero velocity - if (settings.easing === 'easeInOutQuint') pattern = time < 0.5 ? 16 * time * time * time * time * time : 1 + 16 * (--time) * time * time * time * time; // acceleration until halfway, then deceleration - - // Custom Easing Patterns - if (!!settings.customEasing) pattern = settings.customEasing(time); - - return pattern || time; // no easing, no acceleration - }; - - /** - * Determine the document's height - * @returns {Number} - */ - var getDocumentHeight = function () { - return Math.max( - document.body.scrollHeight, document.documentElement.scrollHeight, - document.body.offsetHeight, document.documentElement.offsetHeight, - document.body.clientHeight, document.documentElement.clientHeight - ); - }; - - /** - * Calculate how far to scroll - * Clip support added by robjtede - https://github.com/cferdinandi/smooth-scroll/issues/405 - * @param {Element} anchor The anchor element to scroll to - * @param {Number} headerHeight Height of a fixed header, if any - * @param {Number} offset Number of pixels by which to offset scroll - * @param {Boolean} clip If true, adjust scroll distance to prevent abrupt stops near the bottom of the page - * @returns {Number} - */ - var getEndLocation = function (anchor, headerHeight, offset, clip) { - var location = 0; - if (anchor.offsetParent) { - do { - location += anchor.offsetTop; - anchor = anchor.offsetParent; - } while (anchor); - } - location = Math.max(location - headerHeight - offset, 0); - if (clip) { - location = Math.min(location, getDocumentHeight() - window.innerHeight); - } - return location; - }; - - /** - * Get the height of the fixed header - * @param {Node} header The header - * @return {Number} The height of the header - */ - var getHeaderHeight = function (header) { - return !header ? 0 : (getHeight(header) + header.offsetTop); - }; - - /** - * Update the URL - * @param {Node} anchor The anchor that was scrolled to - * @param {Boolean} isNum If true, anchor is a number - * @param {Object} options Settings for Smooth Scroll - */ - var updateURL = function (anchor, isNum, options) { - - // Bail if the anchor is a number - if (isNum) return; - - // Verify that pushState is supported and the updateURL option is enabled - if (!history.pushState || !options.updateURL) return; - - // Update URL - history.pushState( - { - smoothScroll: JSON.stringify(options), - anchor: anchor.id - }, - document.title, - anchor === document.documentElement ? '#top' : '#' + anchor.id - ); - - }; - - /** - * Bring the anchored element into focus - * @param {Node} anchor The anchor element - * @param {Number} endLocation The end location to scroll to - * @param {Boolean} isNum If true, scroll is to a position rather than an element - */ - var adjustFocus = function (anchor, endLocation, isNum) { - - // Is scrolling to top of page, blur - if (anchor === 0) { - document.body.focus(); - } - - // Don't run if scrolling to a number on the page - if (isNum) return; - - // Otherwise, bring anchor element into focus - anchor.focus(); - if (document.activeElement !== anchor) { - anchor.setAttribute('tabindex', '-1'); - anchor.focus(); - anchor.style.outline = 'none'; - } - window.scrollTo(0 , endLocation); - - }; - - /** - * Emit a custom event - * @param {String} type The event type - * @param {Object} options The settings object - * @param {Node} anchor The anchor element - * @param {Node} toggle The toggle element - */ - var emitEvent = function (type, options, anchor, toggle) { - if (!options.emitEvents || typeof window.CustomEvent !== 'function') return; - var event = new CustomEvent(type, { - bubbles: true, - detail: { - anchor: anchor, - toggle: toggle - } - }); - document.dispatchEvent(event); - }; - - - // - // SmoothScroll Constructor - // - - var SmoothScroll = function (selector, options) { - - // - // Variables - // - - var smoothScroll = {}; // Object for public APIs - var settings, anchor, toggle, fixedHeader, headerHeight, eventTimeout, animationInterval; - - - // - // Methods - // - - /** - * Cancel a scroll-in-progress - */ - smoothScroll.cancelScroll = function (noEvent) { - cancelAnimationFrame(animationInterval); - animationInterval = null; - if (noEvent) return; - emitEvent('scrollCancel', settings); - }; - - /** - * Start/stop the scrolling animation - * @param {Node|Number} anchor The element or position to scroll to - * @param {Element} toggle The element that toggled the scroll event - * @param {Object} options - */ - smoothScroll.animateScroll = function (anchor, toggle, options) { - - // Local settings - var animateSettings = extend(settings || defaults, options || {}); // Merge user options with defaults - - // Selectors and variables - var isNum = Object.prototype.toString.call(anchor) === '[object Number]' ? true : false; - var anchorElem = isNum || !anchor.tagName ? null : anchor; - if (!isNum && !anchorElem) return; - var startLocation = window.pageYOffset; // Current location on the page - if (animateSettings.header && !fixedHeader) { - // Get the fixed header if not already set - fixedHeader = document.querySelector(animateSettings.header); - } - if (!headerHeight) { - // Get the height of a fixed header if one exists and not already set - headerHeight = getHeaderHeight(fixedHeader); - } - var endLocation = isNum ? anchor : getEndLocation(anchorElem, headerHeight, parseInt((typeof animateSettings.offset === 'function' ? animateSettings.offset(anchor, toggle) : animateSettings.offset), 10), animateSettings.clip); // Location to scroll to - var distance = endLocation - startLocation; // distance to travel - var documentHeight = getDocumentHeight(); - var timeLapsed = 0; - var start, percentage, position; - - /** - * Stop the scroll animation when it reaches its target (or the bottom/top of page) - * @param {Number} position Current position on the page - * @param {Number} endLocation Scroll to location - * @param {Number} animationInterval How much to scroll on this loop - */ - var stopAnimateScroll = function (position, endLocation) { - - // Get the current location - var currentLocation = window.pageYOffset; - - // Check if the end location has been reached yet (or we've hit the end of the document) - if (position == endLocation || currentLocation == endLocation || ((startLocation < endLocation && window.innerHeight + currentLocation) >= documentHeight)) { - - // Clear the animation timer - smoothScroll.cancelScroll(true); - - // Bring the anchored element into focus - adjustFocus(anchor, endLocation, isNum); - - // Emit a custom event - emitEvent('scrollStop', animateSettings, anchor, toggle); - - // Reset start - start = null; - animationInterval = null; - - return true; - - } - }; - - /** - * Loop scrolling animation - */ - var loopAnimateScroll = function (timestamp) { - if (!start) { start = timestamp; } - timeLapsed += timestamp - start; - percentage = (timeLapsed / parseInt(animateSettings.speed, 10)); - percentage = (percentage > 1) ? 1 : percentage; - position = startLocation + (distance * easingPattern(animateSettings, percentage)); - window.scrollTo(0, Math.floor(position)); - if (!stopAnimateScroll(position, endLocation)) { - animationInterval = window.requestAnimationFrame(loopAnimateScroll); - start = timestamp; - } - }; - - /** - * Reset position to fix weird iOS bug - * @link https://github.com/cferdinandi/smooth-scroll/issues/45 - */ - if (window.pageYOffset === 0) { - window.scrollTo(0, 0); - } - - // Update the URL - updateURL(anchor, isNum, animateSettings); - - // Emit a custom event - emitEvent('scrollStart', animateSettings, anchor, toggle); - - // Start scrolling animation - smoothScroll.cancelScroll(true); - window.requestAnimationFrame(loopAnimateScroll); - - }; - - /** - * If smooth scroll element clicked, animate scroll - */ - var clickHandler = function (event) { - - // Don't run if the user prefers reduced motion - if (reduceMotion(settings)) return; - - // Don't run if right-click or command/control + click - if (event.button !== 0 || event.metaKey || event.ctrlKey) return; - - // Check if event.target has closest() method - // By @totegi - https://github.com/cferdinandi/smooth-scroll/pull/401/ - if(!('closest' in event.target))return; - - // Check if a smooth scroll link was clicked - toggle = event.target.closest(selector); - if (!toggle || toggle.tagName.toLowerCase() !== 'a' || event.target.closest(settings.ignore)) return; - - // Only run if link is an anchor and points to the current page - if (toggle.hostname !== window.location.hostname || toggle.pathname !== window.location.pathname || !/#/.test(toggle.href)) return; - - // Get an escaped version of the hash - var hash = escapeCharacters(decode(toggle.hash)); - - // Get the anchored element - var anchor = settings.topOnEmptyHash && hash === '#' ? document.documentElement : document.querySelector(hash); - anchor = !anchor && hash === '#top' ? document.documentElement : anchor; - - // If anchored element exists, scroll to it - if (!anchor) return; - event.preventDefault(); - smoothScroll.animateScroll(anchor, toggle); - - }; - - /** - * Animate scroll on popstate events - */ - var popstateHandler = function (event) { - // Stop if history.state doesn't exist (ex. if clicking on a broken anchor link). - // fixes `Cannot read property 'smoothScroll' of null` error getting thrown. - if (history.state === null) return; - - // Only run if state is a popstate record for this instantiation - if (!history.state.smoothScroll || history.state.smoothScroll !== JSON.stringify(settings)) return; - - // Only run if state includes an anchor - if (!history.state.anchor) return; - - // Get the anchor - var anchor = document.querySelector(escapeCharacters(decode(history.state.anchor))); - if (!anchor) return; - - // Animate scroll to anchor link - smoothScroll.animateScroll(anchor, null, {updateURL: false}); - - }; - - /** - * On window scroll and resize, only run events at a rate of 15fps for better performance - */ - var resizeThrottler = function (event) { - if (!eventTimeout) { - eventTimeout = setTimeout((function() { - eventTimeout = null; // Reset timeout - headerHeight = getHeaderHeight(fixedHeader); // Get the height of a fixed header if one exists - }), 66); - } - }; - - /** - * Destroy the current initialization. - */ - smoothScroll.destroy = function () { - - // If plugin isn't already initialized, stop - if (!settings) return; - - // Remove event listeners - document.removeEventListener('click', clickHandler, false); - window.removeEventListener('resize', resizeThrottler, false); - window.removeEventListener('popstate', popstateHandler, false); - - // Cancel any scrolls-in-progress - smoothScroll.cancelScroll(); - - // Reset variables - settings = null; - anchor = null; - toggle = null; - fixedHeader = null; - headerHeight = null; - eventTimeout = null; - animationInterval = null; - - }; - - /** - * Initialize Smooth Scroll - * @param {Object} options User settings - */ - smoothScroll.init = function (options) { - - // feature test - if (!supports()) throw 'Smooth Scroll: This browser does not support the required JavaScript methods and browser APIs.'; - - // Destroy any existing initializations - smoothScroll.destroy(); - - // Selectors and variables - settings = extend(defaults, options || {}); // Merge user options with defaults - fixedHeader = settings.header ? document.querySelector(settings.header) : null; // Get the fixed header - headerHeight = getHeaderHeight(fixedHeader); - - // When a toggle is clicked, run the click handler - document.addEventListener('click', clickHandler, false); - - // If window is resized and there's a fixed header, recalculate its size - if (fixedHeader) { - window.addEventListener('resize', resizeThrottler, false); - } - - // If updateURL and popState are enabled, listen for pop events - if (settings.updateURL && settings.popstate) { - window.addEventListener('popstate', popstateHandler, false); - } - - }; - - - // - // Initialize plugin - // - - smoothScroll.init(options); - - - // - // Public APIs - // - - return smoothScroll; - - }; - - return SmoothScroll; - -})); - -/* GP */ -var gpscroll = new SmoothScroll( gpSmoothScroll.elements.join(), { - speed: gpSmoothScroll.duration, - offset: function( anchor, toggle ) { - var body = document.body, - nav = document.querySelector( '#site-navigation' ), - stickyNav = document.querySelector( '#sticky-navigation' ), - mobileHeader = document.querySelector( '#mobile-header' ), - menuToggle = document.querySelector( '.menu-toggle' ), - offset = 0; - - if ( mobileHeader && ( mobileHeader.offsetWidth || mobileHeader.offsetHeight || mobileHeader.getClientRects().length ) ) { - if ( body.classList.contains( 'mobile-header-sticky' ) ) { - offset = offset + mobileHeader.clientHeight; - } - } else if ( menuToggle && ( menuToggle.offsetWidth || menuToggle.offsetHeight || menuToggle.getClientRects().length ) ) { - if ( body.classList.contains( 'both-sticky-menu' ) || body.classList.contains( 'mobile-sticky-menu' ) ) { - if ( stickyNav ) { - offset = offset + stickyNav.clientHeight; - } else if ( nav ) { - offset = offset + nav.clientHeight; - } - } - } else if ( body.classList.contains( 'both-sticky-menu' ) || body.classList.contains( 'desktop-sticky-menu' ) ) { - if ( stickyNav ) { - offset = offset + stickyNav.clientHeight; - } else if ( nav ) { - offset = offset + nav.clientHeight; - } - } - - return gpSmoothScroll.offset - ? gpSmoothScroll.offset - : offset; - } -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/js/smooth-scroll.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/general/js/smooth-scroll.min.js deleted file mode 100644 index 9fbd8c4e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/general/js/smooth-scroll.min.js +++ /dev/null @@ -1 +0,0 @@ -window.Element&&!Element.prototype.closest&&(Element.prototype.closest=function(e){var t,n=(this.document||this.ownerDocument).querySelectorAll(e),o=this;do{for(t=n.length;0<=--t&&n.item(t)!==o;);}while(t<0&&(o=o.parentElement));return o}),function(){function e(e,t){t=t||{bubbles:!1,cancelable:!1,detail:void 0};var n=document.createEvent("CustomEvent");return n.initCustomEvent(e,t.bubbles,t.cancelable,t.detail),n}"function"!=typeof window.CustomEvent&&(e.prototype=window.Event.prototype,window.CustomEvent=e)}(),function(){for(var r=0,e=["ms","moz","webkit","o"],t=0;t=s)return S.cancelScroll(!0),e=t,n=p,0===(t=o)&&document.body.focus(),n||(t.focus(),document.activeElement!==t&&(t.setAttribute("tabindex","-1"),t.focus(),t.style.outline="none"),b.scrollTo(0,e)),C("scrollStop",h,o,i),!(w=l=null)},f=function(e){var t,n,o;m=(u+=e-(l=l||e))/parseInt(h.speed,10),m=r+c*(n=1 apply_filters( - 'generate_smooth_scroll_elements', - array( - '.smooth-scroll', - 'li.smooth-scroll a', - ) - ), - 'duration' => apply_filters( 'generate_smooth_scroll_duration', 800 ), - 'offset' => apply_filters( 'generate_smooth_scroll_offset', '' ), - ) - ); -} - -add_filter( 'generate_option_defaults', 'generate_smooth_scroll_default' ); -/** - * Add the smooth scroll option to our defaults. - * - * @since 1.6 - * - * @param array $defaults Existing defaults. - * @return array New defaults. - */ -function generate_smooth_scroll_default( $defaults ) { - $defaults['smooth_scroll'] = false; - - return $defaults; -} - -add_action( 'customize_register', 'generate_smooth_scroll_customizer', 99 ); -/** - * Add our smooth scroll option to the Customizer. - * - * @since 1.6 - * - * @param WP_Customize_Manager $wp_customize Theme Customizer object. - */ -function generate_smooth_scroll_customizer( $wp_customize ) { - if ( ! function_exists( 'generate_get_defaults' ) ) { - return; - } - - $defaults = generate_get_defaults(); - - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - $wp_customize->add_setting( - 'generate_settings[smooth_scroll]', - array( - 'default' => $defaults['smooth_scroll'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_settings[smooth_scroll]', - array( - 'type' => 'checkbox', - 'label' => __( 'Smooth scroll', 'gp-premium' ), - 'description' => __( 'Initiate smooth scroll on anchor links using the smooth-scroll class.', 'gp-premium' ), - 'section' => 'generate_general_section', - ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/gp-premium.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/gp-premium.php deleted file mode 100644 index 14974bfa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/gp-premium.php +++ /dev/null @@ -1,309 +0,0 @@ -=' ) && ! defined( 'GENERATE_DISABLE_SITE_LIBRARY' ) ) { - require_once GP_PREMIUM_DIR_PATH . 'site-library/class-site-library-rest.php'; - require_once GP_PREMIUM_DIR_PATH . 'site-library/class-site-library-helper.php'; -} - -if ( is_admin() ) { - require_once GP_PREMIUM_DIR_PATH . 'inc/deprecated-admin.php'; - - if ( generatepress_is_module_active( 'generate_package_site_library', 'GENERATE_SITE_LIBRARY' ) && version_compare( PHP_VERSION, '5.4', '>=' ) && ! defined( 'GENERATE_DISABLE_SITE_LIBRARY' ) ) { - require_once GP_PREMIUM_DIR_PATH . 'site-library/class-site-library.php'; - } -} - -if ( generatepress_is_module_active( 'generate_package_font_library', 'GENERATE_FONT_LIBRARY' ) ) { - require_once GP_PREMIUM_DIR_PATH . 'font-library/class-font-library.php'; - require_once GP_PREMIUM_DIR_PATH . 'font-library/class-font-library-rest.php'; - require_once GP_PREMIUM_DIR_PATH . 'font-library/class-font-library-optimize.php'; - require_once GP_PREMIUM_DIR_PATH . 'font-library/class-font-library-cpt.php'; -} - -if ( ! function_exists( 'generate_premium_updater' ) ) { - add_action( 'admin_init', 'generate_premium_updater', 0 ); - /** - * Set up the updater - **/ - function generate_premium_updater() { - if ( ! class_exists( 'GeneratePress_Premium_Plugin_Updater' ) ) { - include GP_PREMIUM_DIR_PATH . 'library/class-plugin-updater.php'; - } - - $license_key = get_option( 'gen_premium_license_key' ); - - $edd_updater = new GeneratePress_Premium_Plugin_Updater( - 'https://generatepress.com', - __FILE__, - array( - 'version' => GP_PREMIUM_VERSION, - 'license' => trim( $license_key ), - 'item_name' => 'GP Premium', - 'author' => 'Tom Usborne', - 'url' => home_url(), - 'beta' => apply_filters( 'generate_premium_beta_tester', false ), - ) - ); - } -} - -add_filter( 'edd_sl_plugin_updater_api_params', 'generate_premium_set_updater_api_params', 10, 3 ); -/** - * Add the GeneratePress version to our updater params. - * - * @param array $api_params The array of data sent in the request. - * @param array $api_data The array of data set up in the class constructor. - * @param string $plugin_file The full path and filename of the file. - */ -function generate_premium_set_updater_api_params( $api_params, $api_data, $plugin_file ) { - /* - * Make sure $plugin_file matches your plugin's file path. You should have a constant for this - * or can use __FILE__ if this code goes in your plugin's main file. - */ - if ( __FILE__ === $plugin_file ) { - // Dynamically retrieve the current version number. - $api_params['generatepress_version'] = defined( 'GENERATE_VERSION' ) ? GENERATE_VERSION : ''; - } - - return $api_params; -} - -if ( ! function_exists( 'generate_premium_setup' ) ) { - add_action( 'after_setup_theme', 'generate_premium_setup' ); - /** - * Add useful functions to GP Premium - **/ - function generate_premium_setup() { - // This used to be in the theme but the WP.org review team asked for it to be removed. - // Not wanting people to have broken shortcodes in their widgets on update, I added it into premium. - add_filter( 'widget_text', 'do_shortcode' ); - } -} - -if ( ! function_exists( 'generate_premium_theme_information' ) ) { - add_action( 'admin_notices', 'generate_premium_theme_information' ); - /** - * Checks whether there's a theme update available and lets you know. - * Also checks to see if GeneratePress is the active theme. If not, tell them. - * - * @since 1.2.95 - **/ - function generate_premium_theme_information() { - $theme = wp_get_theme(); - - if ( 'GeneratePress' === $theme->name || 'generatepress' === $theme->template ) { - - // Get our information on updates. - // @see https://developer.wordpress.org/reference/functions/wp_prepare_themes_for_js/. - $updates = array(); - if ( current_user_can( 'update_themes' ) ) { - $updates_transient = get_site_transient( 'update_themes' ); - if ( isset( $updates_transient->response ) ) { - $updates = $updates_transient->response; - } - } - - $screen = get_current_screen(); - - // If a GeneratePress update exists, and we're not on the themes page. - // No need to tell people an update exists on the themes page, WP does that for us. - if ( isset( $updates['generatepress'] ) && 'themes' !== $screen->base ) { - printf( - '
    -

    %1$s %3$s

    -
    ', - esc_html__( 'GeneratePress has an update available.', 'gp-premium' ), - esc_url( admin_url( 'themes.php' ) ), - esc_html__( 'Update now.', 'gp-premium' ) - ); - } - } else { - // GeneratePress isn't the active theme, let them know GP Premium won't work. - printf( - '
    -

    %1$s %2$s

    -
    ', - esc_html__( 'GP Premium requires GeneratePress to be your active theme.', 'gp-premium' ), - esc_html__( 'Install now.', 'gp-premium' ), - esc_url( admin_url( 'theme-install.php?theme=generatepress' ) ) - ); - } - - } -} - -add_filter( 'plugin_action_links_' . plugin_basename( __FILE__ ), 'generate_add_configure_action_link' ); -/** - * Show a "Configure" link in the plugin action links. - * - * @since 1.3 - * @param array $links The existing plugin row links. - */ -function generate_add_configure_action_link( $links ) { - $configuration_link = '' . __( 'Configure', 'gp-premium' ) . ''; - - return array_merge( $links, array( $configuration_link ) ); -} - -add_action( 'admin_init', 'generatepress_deactivate_standalone_addons' ); -/** - * Deactivate any standalone add-ons if they're active. - * - * @since 1.3.1 - */ -function generatepress_deactivate_standalone_addons() { - $addons = array( - 'generate-backgrounds/generate-backgrounds.php', - 'generate-blog/generate-blog.php', - 'generate-colors/generate-colors.php', - 'generate-copyright/generate-copyright.php', - 'generate-disable-elements/generate-disable-elements.php', - 'generate-hooks/generate-hooks.php', - 'generate-ie/generate-ie.php', - 'generate-menu-plus/generate-menu-plus.php', - 'generate-page-header/generate-page-header.php', - 'generate-secondary-nav/generate-secondary-nav.php', - 'generate-sections/generate-sections.php', - 'generate-spacing/generate-spacing.php', - 'generate-typography/generate-fonts.php', - ); - - deactivate_plugins( $addons ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/css/hooks.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/css/hooks.css deleted file mode 100644 index 5b981c5e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/css/hooks.css +++ /dev/null @@ -1,59 +0,0 @@ -#gp_hooks_settings .form-table td, -#gp_hooks_settings .form-table th { - padding: 30px; - background: #FFF; - display: block; - width: 100%; - box-sizing: border-box; - margin-bottom: 0; -} - -#gp_hooks_settings .form-table th { - padding-bottom: 0; -} - -#gp_hooks_settings .form-table tr { - margin-bottom: 20px; - display: block; - max-width: 100%; - border: 1px solid #e5e5e5; - box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); - box-sizing: border-box; -} - -.execute, div.disable { - background: none repeat scroll 0 0 #f1f1f1; - display: inline-block; - padding: 10px; - font-size: 14px; -} - -.admin-bar #gp_hooks_settings .sticky-scroll-box.fixed { - top: 52px; -} -#gp_hooks_settings .sticky-scroll-box.fixed { - position: fixed; - right: 18px; - top: 20px; -} - -.rtl #gp_hooks_settings .sticky-scroll-box.fixed { - position: fixed; - left: 18px; - right: auto; -} - -#gp_hooks_settings input[type="checkbox"] { - margin-top: 1px; - margin-right: 0px; -} - -#gp_hooks_settings .form-table { - margin-top: 0; -} - -.appearance_page_gp_hooks_settings #setting-error-true { - margin-left: 2px; - margin-right: 19px; - margin-top: 20px; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/js/admin.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/js/admin.js deleted file mode 100644 index c4a41586..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/js/admin.js +++ /dev/null @@ -1,38 +0,0 @@ -jQuery(document).ready(function($) { - - jQuery('#hook-dropdown').on('change', function() { - var id = jQuery(this).children(":selected").attr("id"); - jQuery('#gp_hooks_settings .form-table tr').hide(); - jQuery('#gp_hooks_settings .form-table tr').eq(id).show(); - Cookies.set('remember_hook', $('#hook-dropdown option:selected').attr('id'), { expires: 90, path: '/'}); - - if ( jQuery('#hook-dropdown').val() == 'all' ) { - $('#gp_hooks_settings .form-table tr').show(); - Cookies.set('remember_hook', 'none', { expires: 90, path: '/'}); - } - - }); - - //checks if the cookie has been set - if( Cookies.get('remember_hook') === null || Cookies.get('remember_hook') === "" || Cookies.get('remember_hook') === "null" || Cookies.get('remember_hook') === "none" || Cookies.get('remember_hook') === undefined ) - { - $('#gp_hooks_settings .form-table tr').show(); - Cookies.set('remember_hook', 'none', { expires: 90, path: '/'}); - } else { - $('#hook-dropdown option[id="' + Cookies.get('remember_hook') + '"]').attr('selected', 'selected'); - $('#gp_hooks_settings .form-table tr').hide(); - $('#gp_hooks_settings .form-table tr').eq(Cookies.get('remember_hook')).show(); - } - - var top = $('.sticky-scroll-box').offset().top; - $(window).scroll(function (event) { - var y = $(this).scrollTop(); - if (y >= top) - $('.sticky-scroll-box').addClass('fixed'); - else - $('.sticky-scroll-box').removeClass('fixed'); - $('.sticky-scroll-box').width($('.sticky-scroll-box').parent().width()); - }); - -}); - diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/js/jquery.cookie.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/js/jquery.cookie.js deleted file mode 100644 index e5733169..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/assets/js/jquery.cookie.js +++ /dev/null @@ -1,165 +0,0 @@ -/*! - * JavaScript Cookie v2.1.3 - * https://github.com/js-cookie/js-cookie - * - * Copyright 2006, 2015 Klaus Hartl & Fagner Brack - * Released under the MIT license - */ -;(function (factory) { - var registeredInModuleLoader = false; - if (typeof define === 'function' && define.amd) { - define(factory); - registeredInModuleLoader = true; - } - if (typeof exports === 'object') { - module.exports = factory(); - registeredInModuleLoader = true; - } - if (!registeredInModuleLoader) { - var OldCookies = window.Cookies; - var api = window.Cookies = factory(); - api.noConflict = function () { - window.Cookies = OldCookies; - return api; - }; - } -}(function () { - function extend () { - var i = 0; - var result = {}; - for (; i < arguments.length; i++) { - var attributes = arguments[ i ]; - for (var key in attributes) { - result[key] = attributes[key]; - } - } - return result; - } - - function init (converter) { - function api (key, value, attributes) { - var result; - if (typeof document === 'undefined') { - return; - } - - // Write - - if (arguments.length > 1) { - attributes = extend({ - path: '/' - }, api.defaults, attributes); - - if (typeof attributes.expires === 'number') { - var expires = new Date(); - expires.setMilliseconds(expires.getMilliseconds() + attributes.expires * 864e+5); - attributes.expires = expires; - } - - // We're using "expires" because "max-age" is not supported by IE - attributes.expires = attributes.expires ? attributes.expires.toUTCString() : ''; - - try { - result = JSON.stringify(value); - if (/^[\{\[]/.test(result)) { - value = result; - } - } catch (e) {} - - if (!converter.write) { - value = encodeURIComponent(String(value)) - .replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g, decodeURIComponent); - } else { - value = converter.write(value, key); - } - - key = encodeURIComponent(String(key)); - key = key.replace(/%(23|24|26|2B|5E|60|7C)/g, decodeURIComponent); - key = key.replace(/[\(\)]/g, escape); - - var stringifiedAttributes = ''; - - for (var attributeName in attributes) { - if (!attributes[attributeName]) { - continue; - } - stringifiedAttributes += '; ' + attributeName; - if (attributes[attributeName] === true) { - continue; - } - stringifiedAttributes += '=' + attributes[attributeName]; - } - return (document.cookie = key + '=' + value + stringifiedAttributes); - } - - // Read - - if (!key) { - result = {}; - } - - // To prevent the for loop in the first place assign an empty array - // in case there are no cookies at all. Also prevents odd result when - // calling "get()" - var cookies = document.cookie ? document.cookie.split('; ') : []; - var rdecode = /(%[0-9A-Z]{2})+/g; - var i = 0; - - for (; i < cookies.length; i++) { - var parts = cookies[i].split('='); - var cookie = parts.slice(1).join('='); - - if (cookie.charAt(0) === '"') { - cookie = cookie.slice(1, -1); - } - - try { - var name = parts[0].replace(rdecode, decodeURIComponent); - cookie = converter.read ? - converter.read(cookie, name) : converter(cookie, name) || - cookie.replace(rdecode, decodeURIComponent); - - if (this.json) { - try { - cookie = JSON.parse(cookie); - } catch (e) {} - } - - if (key === name) { - result = cookie; - break; - } - - if (!key) { - result[name] = cookie; - } - } catch (e) {} - } - - return result; - } - - api.set = api; - api.get = function (key) { - return api.call(api, key); - }; - api.getJSON = function () { - return api.apply({ - json: true - }, [].slice.call(arguments)); - }; - api.defaults = {}; - - api.remove = function (key, attributes) { - api(key, '', extend(attributes, { - expires: -1 - })); - }; - - api.withConverter = init; - - return api; - } - - return init(function () {}); -})); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/functions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/functions.php deleted file mode 100644 index e0954f28..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/hooks/functions/functions.php +++ /dev/null @@ -1,542 +0,0 @@ - -

    %1$s %2$s

    - ', - esc_html__( 'DISALLOW_FILE_EDIT is defined. You should also disallow PHP execution in GP Hooks.', 'gp-premium' ), - esc_html__( 'Learn how', 'gp-premium' ) - ); - } - } -} - -if ( ! function_exists( 'generate_hooks_setup' ) ) { - function generate_hooks_setup() { - // Just to verify that we're activated. - } -} - -if ( ! class_exists( 'Generate_Hooks_Settings' ) ) { - class Generate_Hooks_Settings { - private $dir; - private $file; - private $assets_dir; - private $assets_url; - private $settings_base; - private $settings; - - public function __construct( $file ) { - $this->file = $file; - $this->dir = dirname( $this->file ); - $this->assets_dir = trailingslashit( $this->dir ) . 'assets'; - $this->assets_url = esc_url( trailingslashit( plugins_url( '/assets/', $this->file ) ) ); - $this->settings_base = ''; - - // Initialise settings - add_action( 'admin_init', array( $this, 'init' ) ); - - // Register plugin settings - add_action( 'admin_init' , array( $this, 'register_settings' ) ); - - // Add settings page to menu - add_action( 'admin_menu' , array( $this, 'add_menu_item' ) ); - - // Add settings link to plugins page - add_filter( 'plugin_action_links_' . plugin_basename( $this->file ) , array( $this, 'add_settings_link' ) ); - } - - /** - * Initialise settings - * @return void - */ - public function init() { - $this->settings = $this->settings_fields(); - } - - /** - * Add settings page to admin menu - * @return void - */ - public function add_menu_item() { - $page = add_theme_page( __( 'GP Hooks', 'gp-premium' ) , __( 'GP Hooks', 'gp-premium' ) , apply_filters( 'generate_hooks_capability','manage_options' ) , 'gp_hooks_settings' , array( $this, 'settings_page' ) ); - add_action( 'admin_print_styles-' . $page, array( $this, 'settings_assets' ) ); - } - - /** - * Load settings JS & CSS - * @return void - */ - public function settings_assets() { - wp_enqueue_script( 'gp-cookie', $this->assets_url . 'js/jquery.cookie.js', array( 'jquery' ), GENERATE_HOOKS_VERSION ); - wp_enqueue_script( 'gp-hooks', $this->assets_url . 'js/admin.js', array( 'jquery', 'gp-cookie' ), GENERATE_HOOKS_VERSION ); - wp_enqueue_style( 'gp-hooks', $this->assets_url . 'css/hooks.css' ); - } - - /** - * Add settings link to plugin list table - * @param array $links Existing links - * @return array Modified links - */ - public function add_settings_link( $links ) { - $settings_link = '' . __( 'GP Hooks', 'gp-premium' ) . ''; - array_push( $links, $settings_link ); - return $links; - } - - /** - * Build settings fields - * @return array Fields to be displayed on settings page - */ - private function settings_fields() { - - $settings['standard'] = array( - 'title' => '', - 'description' => '', - 'fields' => array( - array( - "name" => __( 'wp_head', 'gp-premium' ), - "id" => 'generate_wp_head', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Header', 'gp-premium' ), - "id" => 'generate_before_header', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Header Content', 'gp-premium' ), - "id" => 'generate_before_header_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Header Content', 'gp-premium' ), - "id" => 'generate_after_header_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Header', 'gp-premium' ), - "id" => 'generate_after_header', - "type" => 'textarea' - ), - - array( - "name" => __( 'Inside Content Container', 'gp-premium' ), - "id" => 'generate_before_main_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Content', 'gp-premium' ), - "id" => 'generate_before_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Entry Title', 'gp-premium' ), - "id" => 'generate_after_entry_header', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Content', 'gp-premium' ), - "id" => 'generate_after_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Right Sidebar Content', 'gp-premium' ), - "id" => 'generate_before_right_sidebar_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Right Sidebar Content', 'gp-premium' ), - "id" => 'generate_after_right_sidebar_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Left Sidebar Content', 'gp-premium' ), - "id" => 'generate_before_left_sidebar_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Left Sidebar Content', 'gp-premium' ), - "id" => 'generate_after_left_sidebar_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Footer', 'gp-premium' ), - "id" => 'generate_before_footer', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Footer Widgets', 'gp-premium' ), - "id" => 'generate_after_footer_widgets', - "type" => 'textarea' - ), - - array( - "name" => __( 'Before Footer Content', 'gp-premium' ), - "id" => 'generate_before_footer_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'After Footer Content', 'gp-premium' ), - "id" => 'generate_after_footer_content', - "type" => 'textarea' - ), - - array( - "name" => __( 'wp_footer', 'gp-premium' ), - "id" => 'generate_wp_footer', - "type" => 'textarea' - ) - ) - ); - - $settings = apply_filters( 'gp_hooks_settings_fields', $settings ); - - return $settings; - } - - /** - * Register plugin settings - * @return void - */ - public function register_settings() { - if ( is_array( $this->settings ) ) { - foreach( $this->settings as $section => $data ) { - - // Add section to page - add_settings_section( $section, $data['title'], array( $this, 'settings_section' ), 'gp_hooks_settings' ); - - foreach( $data['fields'] as $field ) { - - // Sanitizing isn't possible, as hooks allow any HTML, JS or PHP to be added. - // Allowing PHP can be a security issue if you have admin users who you don't trust. - // In that case, you can disable the ability to add PHP in hooks like this: define( 'GENERATE_HOOKS_DISALLOW_PHP', true ); - $validation = ''; - if( isset( $field['callback'] ) ) { - $validation = $field['callback']; - } - - // Register field - $option_name = $this->settings_base . $field['id']; - register_setting( 'gp_hooks_settings', 'generate_hooks', $validation ); - - // Add field to page - add_settings_field( 'generate_hooks[' . $field['id'] . ']', $field['name'], array( $this, 'display_field' ), 'gp_hooks_settings', $section, array( 'field' => $field ) ); - } - } - } - } - - public function settings_section( $section ) { - $html = ''; - echo $html; - } - - /** - * Generate HTML for displaying fields - * @param array $args Field data - * @return void - */ - public function display_field( $args ) { - - $field = $args['field']; - - $html = ''; - - $option_name = $this->settings_base . $field['id']; - $option = get_option( 'generate_hooks' ); - - $data = ''; - if( isset( $option[$option_name] ) ) { - $data = $option[$option_name]; - } elseif( isset( $field['default'] ) ) { - $data = $field['default']; - } - - - switch( $field['type'] ) { - - case 'textarea': - $checked = ''; - $checked2 = ''; - if( isset( $option[$field['id'] . '_php'] ) && 'true' == $option[$field['id'] . '_php'] ){ - $checked = 'checked="checked"'; - } - if( isset( $option[$field['id'] . '_disable'] ) && 'true' == $option[$field['id'] . '_disable'] ){ - $checked2 = 'checked="checked"'; - } - $html .= ''; - - if ( ! defined( 'GENERATE_HOOKS_DISALLOW_PHP' ) ) { - $html .= '
    '; - } - $html .= '
    '; - break; - - case 'checkbox': - - - break; - - } - - echo $html; - } - - /** - * Validate individual settings field - * @param string $data Inputted value - * @return string Validated value - */ - public function validate_field( $data ) { - if ( $data && strlen( $data ) > 0 && $data != '' ) { - $data = urlencode( strtolower( str_replace( ' ' , '-' , $data ) ) ); - } - return $data; - } - - /** - * Load settings page content - * @return void - */ - public function settings_page() { - - // Build page HTML - $html = '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - // Get settings fields - ob_start(); - settings_fields( 'gp_hooks_settings' ); - do_settings_sections( 'gp_hooks_settings' ); - $html .= ob_get_clean(); - $html .= '
    '; - - $html .= '
    '; - $html .= '
    '; - $html .= '

    ' . __( 'GP Hooks', 'gp-premium' ) . '

    '; - $html .= '
    '; - $html .= '

    ' . __( 'Use these fields to insert anything you like throughout GeneratePress. Shortcodes are allowed, and you can even use PHP if you check the Execute PHP checkboxes.', 'gp-premium' ) . '

    '; - $html .= ''; - $html .= '

    '; - $html .= ''; - $html .= '

    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - $html .= '
    '; - - echo $html; - } - - } - $settings = new Generate_Hooks_Settings( __FILE__ ); -} - -if ( ! function_exists( 'generate_update_hooks' ) ) { - add_action( 'admin_init', 'generate_update_hooks' ); - /** - * Moving standalone db entries to generate_hooks db entry - */ - function generate_update_hooks() { - $generate_hooks = get_option( 'generate_hooks' ); - - // If we've done this before, bail - if ( ! empty( $generate_hooks ) ) { - return; - } - - // One last check - if ( 'true' == $generate_hooks['updated'] ) { - return; - } - - $hooks = generate_hooks_get_hooks(); - $generate_new_hooks = array(); - - foreach ( $hooks as $hook ) { - - $current_hook = get_option( $hook ); - - if ( isset( $current_hook ) && '' !== $current_hook ) { - - $generate_new_hooks[ $hook ] = get_option( $hook ); - $generate_new_hooks[ 'updated' ] = 'true'; - // Let's not delete the old options yet, just in case - //delete_option( $hook ); - - } - - } - - $generate_new_hook_settings = wp_parse_args( $generate_new_hooks, $generate_hooks ); - update_option( 'generate_hooks', $generate_new_hook_settings ); - - } -} - -if ( ! function_exists( 'generate_hooks_admin_errors' ) ) { - add_action( 'admin_notices', 'generate_hooks_admin_errors' ); - /** - * Add our admin notices - */ - function generate_hooks_admin_errors() { - $screen = get_current_screen(); - if ( 'appearance_page_gp_hooks_settings' !== $screen->base ) { - return; - } - - if ( isset( $_GET['settings-updated'] ) && 'true' == $_GET['settings-updated'] ) { - add_settings_error( 'generate-hook-notices', 'true', __( 'Hooks saved.', 'gp-premium' ), 'updated' ); - } - - settings_errors( 'generate-hook-notices' ); - } -} - -add_action( 'admin_head', 'generate_old_gp_hooks_fix_menu' ); -/** - * Set our current menu in the admin while in the old Page Header pages. - * - * @since 1.7 - */ -function generate_old_gp_hooks_fix_menu() { - if ( ! function_exists( 'generate_premium_do_elements' ) ) { - return; - } - - global $parent_file, $submenu_file, $post_type; - - $screen = get_current_screen(); - - if ( 'appearance_page_gp_hooks_settings' === $screen->base ) { - $parent_file = 'themes.php'; - $submenu_file = 'edit.php?post_type=gp_elements'; - } - - remove_submenu_page( 'themes.php', 'gp_hooks_settings' ); -} - -add_action( 'admin_head', 'generate_hooks_add_legacy_button', 999 ); -/** - * Add legacy buttons to our new GP Elements post type. - * - * @since 1.7 - */ -function generate_hooks_add_legacy_button() { - if ( ! function_exists( 'generate_premium_do_elements' ) ) { - return; - } - - $screen = get_current_screen(); - - if ( 'gp_elements' === $screen->post_type && 'edit' === $screen->base ) : - ?> - - $valueID; - } - - if ( 'previous-post' === $source ) { - $in_same_term = $options['inSameTerm'] ?? false; - $term_taxonomy = $options['sameTermTaxonomy'] ?? 'category'; - $previous_post = get_previous_post( $in_same_term, '', $term_taxonomy ); - - if ( ! is_object( $previous_post ) ) { - return false; - } - - return $previous_post->ID; - } - - return $id; - } -} - -GeneratePress_Pro_Dynamic_Tags_Adjacent_Posts::get_instance()->init(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-dashboard.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-dashboard.php deleted file mode 100644 index c3e35a92..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-dashboard.php +++ /dev/null @@ -1,417 +0,0 @@ - array( - 'title' => __( 'Backgrounds', 'gp-premium' ), - 'description' => __( 'Set background images for various HTML elements.', 'gp-premium' ), - 'key' => 'generate_package_backgrounds', - 'settings' => 'generate_background_settings', - 'isActive' => 'activated' === get_option( 'generate_package_backgrounds', false ), - 'exportable' => true, - ), - 'Blog' => array( - 'title' => __( 'Blog', 'gp-premium' ), - 'description' => __( 'Set blog options like infinite scroll, masonry layouts and more.', 'gp-premium' ), - 'key' => 'generate_package_blog', - 'settings' => 'generate_blog_settings', - 'isActive' => 'activated' === get_option( 'generate_package_blog', false ), - 'exportable' => true, - ), - 'Colors' => array( - 'title' => __( 'Colors', 'gp-premium' ), - 'key' => 'generate_package_colors', - 'isActive' => 'activated' === get_option( 'generate_package_colors', false ), - ), - 'Copyright' => array( - 'title' => __( 'Copyright', 'gp-premium' ), - 'description' => __( 'Set a custom copyright message in your footer.', 'gp-premium' ), - 'key' => 'generate_package_copyright', - 'settings' => 'copyright', - 'isActive' => 'activated' === get_option( 'generate_package_copyright', false ), - 'exportable' => true, - ), - 'Disable Elements' => array( - 'title' => __( 'Disable Elements', 'gp-premium' ), - 'description' => __( 'Disable default theme elements on specific pages or inside a Layout Element.', 'gp-premium' ), - 'key' => 'generate_package_disable_elements', - 'isActive' => 'activated' === get_option( 'generate_package_disable_elements', false ), - ), - 'Elements' => array( - 'title' => __( 'Elements', 'gp-premium' ), - 'description' => __( 'Use our block editor theme builder, build advanced HTML hooks, and gain more Layout control.', 'gp-premium' ), - 'key' => 'generate_package_elements', - 'isActive' => 'activated' === get_option( 'generate_package_elements', false ), - ), - 'Font Library' => array( - 'title' => __( 'Font Library', 'gp-premium' ), - 'description' => __( 'Download and localize fonts from the Google Fonts library.', 'gp-premium' ), - 'key' => 'generate_package_font_library', - 'isActive' => 'activated' === get_option( 'generate_package_font_library', false ), - ), - 'Hooks' => array( - 'title' => __( 'Hooks', 'gp-premium' ), - 'description' => __( 'This module has been deprecated. Please use Elements instead.', 'gp-premium' ), - 'key' => 'generate_package_hooks', - 'settings' => 'generate_hooks', - 'isActive' => 'activated' === get_option( 'generate_package_hooks', false ), - 'exportable' => true, - ), - 'Menu Plus' => array( - 'title' => __( 'Menu Plus', 'gp-premium' ), - 'description' => __( 'Set up a mobile header, sticky navigation or off-canvas panel.', 'gp-premium' ), - 'key' => 'generate_package_menu_plus', - 'settings' => 'generate_menu_plus_settings', - 'isActive' => 'activated' === get_option( 'generate_package_menu_plus', false ), - 'exportable' => true, - ), - 'Page Header' => array( - 'title' => __( 'Page Header', 'gp-premium' ), - 'description' => __( 'This module has been deprecated. Please use Elements instead.', 'gp-premium' ), - 'key' => 'generate_package_page_header', - 'settings' => 'generate_page_header_settings', - 'isActive' => 'activated' === get_option( 'generate_package_page_header', false ), - 'exportable' => true, - ), - 'Secondary Nav' => array( - 'title' => __( 'Secondary Nav', 'gp-premium' ), - 'description' => __( 'Add a fully-featured secondary navigation to your site.', 'gp-premium' ), - 'key' => 'generate_package_secondary_nav', - 'settings' => 'generate_secondary_nav_settings', - 'isActive' => 'activated' === get_option( 'generate_package_secondary_nav', false ), - 'exportable' => true, - ), - 'Sections' => array( - 'title' => __( 'Sections', 'gp-premium' ), - 'description' => __( 'This module has been deprecated. Please consider using our GenerateBlocks plugin instead.', 'gp-premium' ), - 'key' => 'generate_package_sections', - 'isActive' => 'activated' === get_option( 'generate_package_sections', false ), - ), - 'Spacing' => array( - 'title' => __( 'Spacing', 'gp-premium' ), - 'description' => __( 'Set the padding and overall spacing of your theme elements.', 'gp-premium' ), - 'key' => 'generate_package_spacing', - 'settings' => 'generate_spacing_settings', - 'isActive' => 'activated' === get_option( 'generate_package_spacing', false ), - 'exportable' => true, - ), - 'Typography' => array( - 'title' => __( 'Typography', 'gp-premium' ), - 'description' => __( 'This module has been deprecated. Switch to our dynamic typography system in Customize > General instead.', 'gp-premium' ), - 'key' => 'generate_package_typography', - 'isActive' => 'activated' === get_option( 'generate_package_typography', false ), - ), - 'WooCommerce' => array( - 'title' => __( 'WooCommerce', 'gp-premium' ), - 'description' => __( 'Add colors, typography, and layout options to your WooCommerce store.', 'gp-premium' ), - 'key' => 'generate_package_woocommerce', - 'settings' => 'generate_woocommerce_settings', - 'isActive' => 'activated' === get_option( 'generate_package_woocommerce', false ), - 'exportable' => true, - ), - ); - - if ( version_compare( PHP_VERSION, '5.4', '>=' ) && ! defined( 'GENERATE_DISABLE_SITE_LIBRARY' ) ) { - $modules['Site Library'] = array( - 'title' => __( 'Site Library', 'gp-premium' ), - 'description' => __( 'Choose from an extensive library of professionally designed starter sites.', 'gp-premium' ), - 'key' => 'generate_package_site_library', - 'isActive' => 'activated' === get_option( 'generate_package_site_library', false ), - ); - } - - if ( function_exists( 'generate_is_using_dynamic_typography' ) && generate_is_using_dynamic_typography() ) { - unset( $modules['Typography'] ); - } - - if ( version_compare( generate_premium_get_theme_version(), '3.1.0-alpha.1', '>=' ) ) { - unset( $modules['Colors'] ); - } - - $deprecated_modules = apply_filters( - 'generate_premium_deprecated_modules', - array( - 'Page Header', - 'Hooks', - 'Sections', - ) - ); - - foreach ( $deprecated_modules as $deprecated_module ) { - if ( isset( $modules[ $deprecated_module ] ) ) { - $modules[ $deprecated_module ]['deprecated'] = true; - } - } - - ksort( $modules ); - - return $modules; - } - - /** - * Get modules that can have their settings exported and imported. - */ - public static function get_exportable_modules() { - $modules = array( - 'Core' => array( - 'settings' => 'generate_settings', - 'title' => __( 'Core', 'gp-premium' ), - 'isActive' => true, - ), - ); - - foreach ( self::get_modules() as $key => $data ) { - if ( ! empty( $data['exportable'] ) && $data['isActive'] ) { - $modules[ $key ] = $data; - } - } - - return $modules; - } - - /** - * Get options using theme_mods. - */ - public static function get_theme_mods() { - $theme_mods = array( - 'font_body_variants', - 'font_body_category', - 'font_site_title_variants', - 'font_site_title_category', - 'font_site_tagline_variants', - 'font_site_tagline_category', - 'font_navigation_variants', - 'font_navigation_category', - 'font_secondary_navigation_variants', - 'font_secondary_navigation_category', - 'font_buttons_variants', - 'font_buttons_category', - 'font_heading_1_variants', - 'font_heading_1_category', - 'font_heading_2_variants', - 'font_heading_2_category', - 'font_heading_3_variants', - 'font_heading_3_category', - 'font_heading_4_variants', - 'font_heading_4_category', - 'font_heading_5_variants', - 'font_heading_5_category', - 'font_heading_6_variants', - 'font_heading_6_category', - 'font_widget_title_variants', - 'font_widget_title_category', - 'font_footer_variants', - 'font_footer_category', - 'generate_copyright', - ); - - if ( function_exists( 'generate_is_using_dynamic_typography' ) && generate_is_using_dynamic_typography() ) { - $theme_mods = array( - 'generate_copyright', - ); - } - - return $theme_mods; - } - - /** - * Get our setting keys. - */ - public static function get_setting_keys() { - return array( - 'generate_settings', - 'generate_background_settings', - 'generate_blog_settings', - 'generate_hooks', - 'generate_page_header_settings', - 'generate_secondary_nav_settings', - 'generate_spacing_settings', - 'generate_menu_plus_settings', - 'generate_woocommerce_settings', - ); - } - - /** - * Returns safely the license key. - */ - public static function get_license_key() { - $license_key = get_option( 'gen_premium_license_key', '' ); - - if ( $license_key && strlen( $license_key ) > 4 ) { - $hidden_length = strlen( $license_key ) - 4; - $safe_part = substr( $license_key, -4 ); - $hidden_part = implode( '', array_fill( 0, $hidden_length, '*' ) ); - - return $hidden_part . $safe_part; - } - - return $license_key; - } - - /** - * Add our scripts to the page. - */ - public function enqueue_scripts() { - if ( ! class_exists( 'GeneratePress_Dashboard' ) ) { - return; - } - - $dashboard_pages = GeneratePress_Dashboard::get_pages(); - $current_screen = get_current_screen(); - - - if ( in_array( $current_screen->id, $dashboard_pages ) ) { - $packages_info = generate_premium_get_enqueue_assets( 'packages' ); - wp_enqueue_style( - 'generatepress-pro-packages', - GP_PREMIUM_DIR_URL . 'dist/packages.css', - array(), - $packages_info['version'] - ); - - wp_enqueue_style( - 'generate-pro-dashboard', - GP_PREMIUM_DIR_URL . 'dist/style-dashboard.css', - array( 'wp-components' ), - GP_PREMIUM_VERSION - ); - - if ( 'appearance_page_generate-options' === $current_screen->id ) { - wp_enqueue_script( - 'generate-pro-dashboard', - GP_PREMIUM_DIR_URL . 'dist/dashboard.js', - array(), - GP_PREMIUM_VERSION, - true - ); - - wp_set_script_translations( 'generate-pro-dashboard', 'gp-premium', GP_PREMIUM_DIR_PATH . 'langs' ); - - wp_localize_script( - 'generate-pro-dashboard', - 'generateProDashboard', - array( - 'modules' => self::get_modules(), - 'exportableModules' => self::get_exportable_modules(), - 'fontLibraryUrl' => admin_url( 'themes.php?page=generatepress-font-library' ), - 'siteLibraryUrl' => admin_url( 'themes.php?page=generatepress-library' ), - 'elementsUrl' => admin_url( 'edit.php?post_type=gp_elements' ), - 'hasWooCommerce' => class_exists( 'WooCommerce' ), - 'licenseKey' => self::get_license_key(), - 'licenseKeyStatus' => get_option( 'gen_premium_license_key_status', 'deactivated' ), - 'betaTester' => get_option( 'gp_premium_beta_testing', false ), - ) - ); - } - } - } - - /** - * Enable beta testing if our option is set. - * - * @since 2.1.0 - * @param boolean $value Whether beta testing is on or not. - */ - public function set_beta_tester( $value ) { - if ( get_option( 'gp_premium_beta_testing', false ) ) { - return true; - } - - return $value; - } - - /** - * Add the container for our start customizing app. - */ - public function module_list() { - echo '
    '; - } - - /** - * Add the container for our start customizing app. - */ - public function license_key() { - echo '
    '; - } - - /** - * Add the container for our start customizing app. - */ - public function import_export() { - echo '
    '; - } - - /** - * Add the container for our reset app. - */ - public function reset() { - echo '
    '; - } -} - -GeneratePress_Pro_Dashboard::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-register-dynamic-tags.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-register-dynamic-tags.php deleted file mode 100644 index b7038ead..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-register-dynamic-tags.php +++ /dev/null @@ -1,306 +0,0 @@ - __( 'Archive Title', 'gp-premium' ), - 'tag' => 'archive_title', - 'type' => 'archive', - 'supports' => [], - 'description' => __( 'Get the title for the current archive being viewed.', 'gp-premium' ), - 'return' => [ $this, 'get_archive_title' ], - ] - ); - - new GenerateBlocks_Register_Dynamic_Tag( - [ - 'title' => __( 'Archive Description', 'gp-premium' ), - 'tag' => 'archive_description', - 'type' => 'archive', - 'supports' => [], - 'description' => __( 'Get the description for the current archive being viewed.', 'gp-premium' ), - 'return' => [ $this, 'get_archive_description' ], - ] - ); - - new GenerateBlocks_Register_Dynamic_Tag( - [ - 'title' => __( 'Term Meta', 'gp-premium' ), - 'tag' => 'term_meta', - 'type' => 'term', - 'supports' => [ 'meta', 'source' ], - 'description' => __( 'Access term meta by key for the specified term. Return value must be a string.', 'gp-premium' ), - 'return' => [ $this, 'get_term_meta' ], - ] - ); - - new GenerateBlocks_Register_Dynamic_Tag( - [ - 'title' => __( 'Current year', 'gp-premium' ), - 'tag' => 'current_year', - 'type' => 'site', - 'supports' => [], - 'return' => [ $this, 'get_current_year' ], - ] - ); - - new GenerateBlocks_Register_Dynamic_Tag( - [ - 'title' => __( 'Previous Posts URL', 'gp-premium' ), - 'tag' => 'previous_posts_page_url', - 'type' => 'post', - 'supports' => [ 'source', 'instant-pagination' ], - 'return' => [ $this, 'get_previous_posts_page_url' ], - ] - ); - - new GenerateBlocks_Register_Dynamic_Tag( - [ - 'title' => __( 'Next Posts URL', 'gp-premium' ), - 'tag' => 'next_posts_page_url', - 'type' => 'post', - 'supports' => [ 'source', 'instant-pagination' ], - 'return' => [ $this, 'get_next_posts_page_url' ], - ] - ); - } - - /** - * Get the archive title. - * - * @param array $options The options. - * @param object $block The block. - * @param object $instance The block instance. - * @return string - */ - public static function get_archive_title( $options, $block, $instance ) { - $output = ''; - $id = $options['id'] ?? 0; - - if ( is_category() ) { - $output = single_cat_title( '', false ); - } elseif ( is_tag() ) { - $output = single_tag_title( '', false ); - } elseif ( is_author() ) { - $output = get_the_author(); - } elseif ( is_post_type_archive() ) { - $output = post_type_archive_title( '', false ); - } elseif ( is_tax() ) { - $output = single_term_title( '', false ); - } elseif ( is_home() ) { - $page = get_option( 'page_for_posts' ) ?? 0; - - if ( $page ) { - $output = get_the_title( $page ); - } else { - $output = __( 'Blog', 'generateblocks-pro' ); - } - } elseif ( is_search() ) { - $output = get_search_query(); - } elseif ( $id ) { - if ( term_exists( (int) $id ) ) { - $term = get_term( $id ); - $output = $term->name; - } elseif ( is_string( $id ) ) { - // Assume it's a post type archive title. - $post_type_obj = get_post_type_object( $id ); - $title = $post_type_obj->labels->name ?? ''; - - if ( $title ) { - /** - * Core Filter. Filters the post type archive title. - * - * @param string $post_type_name Post type 'name' label. - * @param string $post_type Post type. - */ - $output = apply_filters( 'post_type_archive_title', $title, $id ); - } - } - } - - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - /** - * Get the archive description. - * - * @param array $options The options. - * @param object $block The block. - * @param object $instance The block instance. - * @return string - */ - public static function get_archive_description( $options, $block, $instance ) { - $output = get_the_archive_description(); - - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - /** - * Get the term meta. - * - * @param array $options The options. - * @param array $block The block. - * @param object $instance The block instance. - * @return string - */ - public static function get_term_meta( $options, $block, $instance ) { - $id = GenerateBlocks_Dynamic_Tags::get_id( $options, 'term', $instance ); - - if ( ! $id ) { - return GenerateBlocks_Dynamic_Tag_Callbacks::output( '', $options, $instance ); - } - - $key = $options['key'] ?? ''; - $output = ''; - - if ( empty( $key ) ) { - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - $value = GenerateBlocks_Meta_Handler::get_term_meta( $id, $key, true ); - - if ( ! $value ) { - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - add_filter( 'wp_kses_allowed_html', [ 'GenerateBlocks_Dynamic_Tags', 'expand_allowed_html' ], 10, 2 ); - $output = wp_kses_post( $value ); - remove_filter( 'wp_kses_allowed_html', [ 'GenerateBlocks_Dynamic_Tags', 'expand_allowed_html' ], 10, 2 ); - - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - /** - * Get the current year. - * - * @param array $options The options. - * @param array $block The block. - * @param object $instance The block instance. - * - * @return string - */ - public static function get_current_year( $options, $block, $instance ) { - $output = wp_date( 'Y' ); - - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - /** - * Get the previous post page URL. - * - * @param array $options The options. - * @param object $block The block. - * @param object $instance The block instance. - * @return string - */ - public static function get_previous_posts_page_url( $options, $block, $instance ) { - $page_key = isset( $instance->context['generateblocks/queryId'] ) ? 'query-' . $instance->context['generateblocks/queryId'] . '-page' : 'query-page'; - $page = empty( $_GET[ $page_key ] ) ? 1 : (int) $_GET[ $page_key ]; // phpcs:ignore -- No data processing happening. - $inherit_query = $instance->context['generateblocks/inheritQuery'] ?? false; - $output = ''; - - if ( $inherit_query ) { - global $paged; - - if ( $paged > 1 ) { - $output = previous_posts( false ); - } - } elseif ( 1 !== $page ) { - $output = esc_url( add_query_arg( $page_key, $page - 1 ) ); - } - - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - /** - * Get the next post page URL. - * - * @param array $options The options. - * @param object $block The block. - * @param object $instance The block instance. - * @return string - */ - public static function get_next_posts_page_url( $options, $block, $instance ) { - $page_key = isset( $instance->context['generateblocks/queryId'] ) ? 'query-' . $instance->context['generateblocks/queryId'] . '-page' : 'query-page'; - $page = empty( $_GET[ $page_key ] ) ? 1 : (int) $_GET[ $page_key ]; // phpcs:ignore -- No data processing happening. - $args = $instance->context['generateblocks/query'] ?? []; - $inherit_query = $instance->context['generateblocks/inheritQuery'] ?? false; - $per_page = $args['per_page'] ?? apply_filters( 'generateblocks_query_per_page_default', 10, $args ); - $output = ''; - - if ( $inherit_query ) { - global $wp_query, $paged; - - if ( ! $paged ) { - $paged = 1; // phpcs:ignore -- Need to overrite global here. - } - - $next_page = (int) $paged + 1; - - if ( $next_page <= $wp_query->max_num_pages ) { - $output = next_posts( $wp_query->max_num_pages, false ); - } - } else { - $query_data = $instance->context['generateblocks/queryData'] ?? null; - $query_type = $instance->context['generateblocks/queryType'] ?? GenerateBlocks_Block_Query::TYPE_WP_QUERY; - $is_wp_query = GenerateBlocks_Block_Query::TYPE_WP_QUERY === $query_type; - - if ( ! $query_data || ( ! $is_wp_query && ! is_array( $query_data ) ) ) { - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - $next_page = $page + 1; - $custom_query_max_pages = $is_wp_query - ? (int) $query_data->max_num_pages - : ceil( count( $query_data ) / $per_page ); - - if ( $custom_query_max_pages < $next_page ) { - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } - - if ( $custom_query_max_pages && $custom_query_max_pages !== $page ) { - $output = esc_url( add_query_arg( $page_key, $page + 1 ) ); - } - - wp_reset_postdata(); // Restore original Post Data. - } - - return GenerateBlocks_Dynamic_Tag_Callbacks::output( $output, $options, $instance ); - } -} - -GeneratePress_Pro_Dynamic_Tags_Register::get_instance()->init(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-rest.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-rest.php deleted file mode 100644 index e9bffe21..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-rest.php +++ /dev/null @@ -1,570 +0,0 @@ -namespace . $this->version; - - register_rest_route( - $namespace, - '/modules/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'update_module' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/license/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'update_licensing' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/beta/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'update_beta_testing' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/export/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'export' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/import/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'import' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - register_rest_route( - $namespace, - '/reset/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'reset' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - } - - /** - * Get edit options permissions. - * - * @return bool - */ - public function update_settings_permission() { - return current_user_can( 'manage_options' ); - } - - /** - * Update modules. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function update_module( WP_REST_Request $request ) { - $module_key = $request->get_param( 'key' ); - $action = $request->get_param( 'action' ); - $current_setting = get_option( $module_key, false ); - $modules = GeneratePress_Pro_Dashboard::get_modules(); - $safe_module_keys = array(); - - foreach ( $modules as $key => $data ) { - $safe_module_keys[] = $data['key']; - } - - if ( ! in_array( $module_key, $safe_module_keys ) ) { - return $this->failed( 'Bad module key.' ); - } - - $message = ''; - - if ( 'activate' === $action ) { - update_option( $module_key, 'activated' ); - $message = __( 'Module activated.', 'gp-premium' ); - } - - if ( 'deactivate' === $action ) { - update_option( $module_key, 'deactivated' ); - $message = __( 'Module deactivated.', 'gp-premium' ); - } - - return $this->success( $message ); - } - - /** - * Update licensing. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function update_licensing( WP_REST_Request $request ) { - $new_license_key = $request->get_param( 'key' ); - $old_license = get_option( 'gen_premium_license_key', '' ); - $old_status = get_option( 'gen_premium_license_key_status', 'deactivated' ); - $new_license = strpos( $new_license_key, '***' ) !== false - ? trim( $old_license ) - : trim( $new_license_key ); - - if ( $new_license ) { - $api_params = array( - 'edd_action' => 'activate_license', - 'license' => sanitize_key( $new_license ), - 'item_name' => rawurlencode( 'GP Premium' ), - 'url' => home_url(), - ); - } elseif ( $old_license && 'valid' === $old_status ) { - $api_params = array( - 'edd_action' => 'deactivate_license', - 'license' => sanitize_key( $old_license ), - 'item_name' => rawurlencode( 'GP Premium' ), - 'url' => home_url(), - ); - } - - if ( isset( $api_params ) ) { - $response = wp_remote_post( - 'https://generatepress.com', - array( - 'timeout' => 30, - 'sslverify' => false, - 'body' => $api_params, - ) - ); - - if ( is_wp_error( $response ) || 200 !== (int) wp_remote_retrieve_response_code( $response ) ) { - if ( is_object( $response ) ) { - return $this->failed( $response->get_error_message() ); - } elseif ( is_array( $response ) && isset( $response['response']['message'] ) ) { - if ( 'Forbidden' === $response['response']['message'] ) { - $message = __( '403 Forbidden. Your server is not able to communicate with generatepress.com in order to activate your license key.', 'gp-premium' ); - } else { - $message = $response['response']['message']; - } - } - } else { - $license_data = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( false === $license_data->success ) { - switch ( $license_data->error ) { - case 'expired': - $message = sprintf( - /* translators: License key expiration date. */ - __( 'Your license key expired on %s.', 'gp-premium' ), - date_i18n( get_option( 'date_format' ), strtotime( $license_data->expires, current_time( 'timestamp' ) ) ) // phpcs:ignore - ); - break; - - case 'disabled': - case 'revoked': - $message = __( 'Your license key has been disabled.', 'gp-premium' ); - break; - - case 'missing': - $message = __( 'Invalid license.', 'gp-premium' ); - break; - - case 'invalid': - case 'site_inactive': - $message = __( 'Your license is not active for this URL.', 'gp-premium' ); - break; - - case 'item_name_mismatch': - /* translators: GP Premium */ - $message = sprintf( __( 'This appears to be an invalid license key for %s.', 'gp-premium' ), __( 'GP Premium', 'gp-premium' ) ); - break; - - case 'no_activations_left': - $message = __( 'Your license key has reached its activation limit.', 'gp-premium' ); - break; - - default: - $message = __( 'An error occurred, please try again.', 'gp-premium' ); - break; - } - } - } - - update_option( 'gen_premium_license_key_status', esc_attr( $license_data->license ) ); - } - - update_option( 'gen_premium_license_key', sanitize_key( $new_license ) ); - - if ( ! isset( $api_params ) ) { - return $this->success( __( 'Settings saved.', 'gp-premium' ) ); - } - - if ( ! empty( $message ) ) { - return $this->failed( $message ); - } - - return $this->success( $license_data ); - } - - /** - * Update licensing. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function update_beta_testing( WP_REST_Request $request ) { - $new_beta_tester = $request->get_param( 'beta' ); - - if ( ! empty( $new_beta_tester ) ) { - update_option( 'gp_premium_beta_testing', true, false ); - } else { - delete_option( 'gp_premium_beta_testing' ); - } - - if ( ! isset( $api_params ) ) { - return $this->success( __( 'Settings saved.', 'gp-premium' ) ); - } - - if ( ! empty( $message ) ) { - return $this->failed( $message ); - } - - return $this->success( $license_data ); - } - - /** - * Export settings. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function export( WP_REST_Request $request ) { - $exportable_modules = $request->get_param( 'items' ); - - if ( ! $exportable_modules ) { - $exportable_modules = GeneratePress_Pro_Dashboard::get_exportable_modules(); - } - - $export_type = $request->get_param( 'type' ); - - if ( 'all' === $export_type ) { - $data = array( - 'modules' => array(), - 'mods' => array(), - 'options' => array(), - ); - - $module_settings = array(); - - foreach ( $exportable_modules as $exported_module_key => $exported_module_data ) { - if ( isset( $exported_module_data['settings'] ) ) { - $module_settings[] = $exported_module_data['settings']; - } - } - - $modules = GeneratePress_Pro_Dashboard::get_modules(); - - // Export module status of the exported options. - foreach ( $modules as $module_key => $module_data ) { - if ( isset( $module_data['settings'] ) && in_array( $module_data['settings'], $module_settings ) ) { - $data['modules'][ $module_key ] = $module_data['key']; - } - } - - $theme_mods = GeneratePress_Pro_Dashboard::get_theme_mods(); - - foreach ( $theme_mods as $theme_mod ) { - if ( 'generate_copyright' === $theme_mod ) { - if ( in_array( 'copyright', $module_settings ) ) { - $data['mods'][ $theme_mod ] = get_theme_mod( $theme_mod ); - } - } else { - if ( in_array( 'generate_settings', $module_settings ) ) { - $data['mods'][ $theme_mod ] = get_theme_mod( $theme_mod ); - } - } - } - - $settings = GeneratePress_Pro_Dashboard::get_setting_keys(); - - foreach ( $settings as $setting ) { - if ( in_array( $setting, $module_settings ) ) { - $data['options'][ $setting ] = get_option( $setting ); - } - } - } - - if ( 'global-colors' === $export_type ) { - $data['global-colors'] = generate_get_option( 'global_colors' ); - } - - if ( 'typography' === $export_type ) { - $data['font-manager'] = generate_get_option( 'font_manager' ); - $data['typography'] = generate_get_option( 'typography' ); - } - - $data = apply_filters( 'generate_export_data', $data, $export_type ); - - return $this->success( $data ); - } - - /** - * Import settings. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function import( WP_REST_Request $request ) { - $settings = $request->get_param( 'import' ); - - if ( empty( $settings ) ) { - $this->failed( __( 'No settings to import.', 'gp-premium' ) ); - } - - if ( ! empty( $settings['typography'] ) ) { - $existing_settings = get_option( 'generate_settings', array() ); - $existing_settings['typography'] = $settings['typography']; - - if ( ! empty( $settings['font-manager'] ) ) { - $existing_settings['font_manager'] = $settings['font-manager']; - } - - update_option( 'generate_settings', $existing_settings ); - } elseif ( ! empty( $settings['global-colors'] ) ) { - $existing_settings = get_option( 'generate_settings', array() ); - $existing_settings['global_colors'] = $settings['global-colors']; - - update_option( 'generate_settings', $existing_settings ); - } else { - $modules = GeneratePress_Pro_Dashboard::get_modules(); - - foreach ( (array) $settings['modules'] as $key => $val ) { - if ( isset( $modules[ $key ] ) && in_array( $val, $modules[ $key ] ) ) { - update_option( $val, 'activated' ); - } - } - - foreach ( (array) $settings['mods'] as $key => $val ) { - if ( in_array( $key, GeneratePress_Pro_Dashboard::get_theme_mods() ) ) { - set_theme_mod( $key, $val ); - } - } - - foreach ( (array) $settings['options'] as $key => $val ) { - if ( in_array( $key, GeneratePress_Pro_Dashboard::get_setting_keys() ) ) { - update_option( $key, $val ); - } - } - } - - // Delete existing dynamic CSS cache. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - - $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $dynamic_css_data['updated_time'] ) ) { - unset( $dynamic_css_data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); - - return $this->success( __( 'Settings imported.', 'gp-premium' ) ); - } - - /** - * Reset settings. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function reset( WP_REST_Request $request ) { - $reset_items = $request->get_param( 'items' ); - - if ( ! $reset_items ) { - $reset_items = GeneratePress_Pro_Dashboard::get_exportable_modules(); - } - - $module_settings = array(); - - foreach ( $reset_items as $reset_module_key => $reset_module_data ) { - if ( isset( $reset_module_data['settings'] ) ) { - $module_settings[] = $reset_module_data['settings']; - } - } - - $theme_mods = GeneratePress_Pro_Dashboard::get_theme_mods(); - - foreach ( $theme_mods as $theme_mod ) { - if ( 'generate_copyright' === $theme_mod ) { - if ( in_array( 'copyright', $module_settings ) ) { - remove_theme_mod( $theme_mod ); - } - } else { - if ( in_array( 'generate_settings', $module_settings ) ) { - remove_theme_mod( $theme_mod ); - } - } - } - - $settings = GeneratePress_Pro_Dashboard::get_setting_keys(); - - foreach ( $settings as $setting ) { - if ( in_array( $setting, $module_settings ) ) { - delete_option( $setting ); - } - } - - // Delete our dynamic CSS option. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - - // Reset our dynamic CSS file updated time so it regenerates. - $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $dynamic_css_data['updated_time'] ) ) { - unset( $dynamic_css_data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); - - // Delete any GeneratePress Site CSS in Additional CSS. - $additional_css = wp_get_custom_css_post(); - - if ( ! empty( $additional_css ) ) { - $additional_css->post_content = preg_replace( '#(/\\* GeneratePress Site CSS \\*/).*?(/\\* End GeneratePress Site CSS \\*/)#s', '', $additional_css->post_content ); - wp_update_custom_css_post( $additional_css->post_content ); - } - - return $this->success( __( 'Settings reset.', 'gp-premium' ) ); - } - - /** - * Success rest. - * - * @param mixed $response response data. - * @return mixed - */ - public function success( $response ) { - return new WP_REST_Response( - array( - 'success' => true, - 'response' => $response, - ), - 200 - ); - } - - /** - * Failed rest. - * - * @param mixed $response response data. - * @return mixed - */ - public function failed( $response ) { - return new WP_REST_Response( - array( - 'success' => false, - 'response' => $response, - ), - 200 - ); - } - - /** - * Error rest. - * - * @param mixed $code error code. - * @param mixed $response response data. - * @return mixed - */ - public function error( $code, $response ) { - return new WP_REST_Response( - array( - 'error' => true, - 'success' => false, - 'error_code' => $code, - 'response' => $response, - ), - 401 - ); - } -} - -GeneratePress_Pro_Rest::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-singleton.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-singleton.php deleted file mode 100644 index 52507b82..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/class-singleton.php +++ /dev/null @@ -1,58 +0,0 @@ -id ) { - return true; - } - - return false; -} - -/** - * Add the Sites tab to our Dashboard tabs. - * - * @since 1.6 - * @deprecated 2.0.0 - * - * @param array $tabs Existing tabs. - * @return array New tabs. - */ -function generate_sites_dashboard_tab( $tabs ) { - $tabs['Sites'] = array( - 'name' => __( 'Site Library', 'gp-premium' ), - 'url' => admin_url( 'themes.php?page=generatepress-site-library' ), - 'class' => generate_is_sites_dashboard() ? 'active' : '', - ); - - return $tabs; -} - -/** - * Register our Site Library page. - * - * @since 1.7 - * @deprecated 2.0.0 - */ -function generate_site_library_register() { - add_submenu_page( - 'themes.php', - __( 'Site Library', 'gp-premium' ), - __( 'Site Library', 'gp-premium' ), - 'manage_options', - 'generatepress-site-library', - 'generate_sites_container' - ); -} - -/** - * Set our current menu item as the GeneratePress Dashboard. - * - * @since 1.7 - * @deprecated 2.0.0 - */ -function generate_site_library_fix_menu() { - global $parent_file, $submenu_file, $post_type; - - if ( generate_is_sites_dashboard() ) { - $parent_file = 'themes.php'; // phpcs:ignore -- Override necessary. - $submenu_file = 'generate-options'; // phpcs:ignore -- Override necessary. - } - - remove_submenu_page( 'themes.php', 'generatepress-site-library' ); -} - -/** - * Add our scripts for the site library. - * - * @since 1.8 - * @deprecated 2.0.0 - */ -function generate_sites_do_enqueue_scripts() { - if ( ! generate_is_sites_dashboard() ) { - return; - } - - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - - wp_enqueue_script( - 'generate-sites-admin', - GENERATE_SITES_URL . 'assets/js/admin.js', - array( 'jquery', 'wp-util', 'updates', 'generate-sites-blazy' ), - GP_PREMIUM_VERSION, - true - ); - - wp_enqueue_script( - 'generate-sites-download', - GENERATE_SITES_URL . 'assets/js/download.js', - array( 'jquery', 'generate-sites-admin' ), - GP_PREMIUM_VERSION, - true - ); - - wp_enqueue_script( - 'generate-sites-blazy', - GENERATE_SITES_URL . 'assets/js/blazy.min.js', - array(), - GP_PREMIUM_VERSION, - true - ); - - wp_localize_script( - 'generate-sites-admin', - 'generate_sites_params', - array( - 'ajaxurl' => admin_url( 'admin-ajax.php' ), - 'nonce' => wp_create_nonce( 'generate_sites_nonce' ), - 'importing_options' => __( 'Importing options', 'gp-premium' ), - 'backing_up_options' => __( 'Backing up options', 'gp-premium' ), - 'checking_demo_content' => __( 'Checking demo content', 'gp-premium' ), - 'downloading_content' => __( 'Downloading content', 'gp-premium' ), - 'importing_content' => __( 'Importing content', 'gp-premium' ), - 'importing_site_options' => __( 'Importing site options', 'gp-premium' ), - 'importing_widgets' => __( 'Importing widgets', 'gp-premium' ), - 'activating_plugins' => __( 'Activating plugins', 'gp-premium' ), - 'installing_plugins' => __( 'Installing plugins', 'gp-premium' ), - 'automatic_plugins' => __( 'Automatic', 'gp-premium' ), - 'manual_plugins' => __( 'Manual', 'gp-premium' ), - 'home_url' => home_url(), - 'restoreThemeOptions' => __( 'Restoring theme options', 'gp-premium' ), - 'restoreSiteOptions' => __( 'Restoring site options', 'gp-premium' ), - 'restoreContent' => __( 'Removing imported content', 'gp-premium' ), - 'restorePlugins' => __( 'Deactivating imported plugins', 'gp-premium' ), - 'restoreWidgets' => __( 'Restoring widgets', 'gp-premium' ), - 'restoreCSS' => __( 'Restoring CSS', 'gp-premium' ), - 'cleanUp' => __( 'Cleaning up', 'gp-premium' ), - 'hasContentBackup' => ! empty( $backup_data['content'] ), - 'confirmRemoval' => __( 'This process makes changes to your database. If you have existing data, be sure to create a backup as a precaution.', 'gp-premium' ), - ) - ); - - wp_enqueue_style( - 'generate-sites-admin', - GENERATE_SITES_URL . 'assets/css/admin.css', - array(), - GP_PREMIUM_VERSION - ); - - wp_enqueue_style( - 'generate-premium-dashboard', - plugin_dir_url( dirname( __FILE__ ) ) . 'inc/assets/dashboard.css', - array(), - GP_PREMIUM_VERSION - ); -} - -/** - * Add a body class while in the Site Library. - * - * @since 1.8 - * @deprecated 2.0.0 - * - * @param array $classes Current body classes. - * @return array Existing and our new body classes - */ -function generate_sites_do_admin_body_classes( $classes ) { - if ( generate_is_sites_dashboard() ) { - $classes .= ' generate-sites'; - } - - return $classes; -} - -/** - * Add an opening wrapper element for our Dashboard tabs and page builder links. - * - * @since 1.8 - */ -function generate_sites_add_tabs_wrapper_open() { - echo '
    '; -} - -/** - * Adds our Site dashboard container. - * - * @since 1.6 - * @deprecated 2.0.0 - */ -function generate_sites_container() { - ?> -
    -
    -
    -
    - -
    - - -
    -
    -
    - '; - - if ( ! empty( $page_builders ) ) : - ?> -
    - -
    - -
    -
    - - -
    - -
    - - - - -
    -

    - -
    -

    -

    -
    - -
    - - - - -
    -
    - -
    - -
    - - - %2$s - -
    ', - esc_html( wp_create_nonce( 'refresh_sites_nonce' ) ), - __( 'Refresh Sites', 'gp-premium' ), - esc_url( admin_url( 'themes.php?page=generatepress-site-library' ) ), - __( 'Reload Page', 'gp-premium' ) - ); - ?> - - - get_post_types( array( 'public' => true ) ), - 'showposts' => -1, - 'meta_query' => array( - array( - 'key' => '_generate-select-page-header', - 'compare' => 'EXISTS', - ), - ), - ); - - $posts = get_posts( $args ); - $new_values = array(); - - foreach ( $posts as $post ) { - $page_header_id = get_post_meta( $post->ID, '_generate-select-page-header', true ); - - if ( $page_header_id ) { - $new_values[ $post->ID ] = $page_header_id; - } - } - - return $new_values; -} - -/** - * Get our Element display locations. - * - * @since 1.7 - * @deprecated 2.0.0 - * - * @return array - */ -function generate_sites_export_elements_location() { - $args = array( - 'post_type' => 'gp_elements', - 'showposts' => -1, - ); - - $posts = get_posts( $args ); - $new_values = array(); - - foreach ( $posts as $post ) { - $display_conditions = get_post_meta( $post->ID, '_generate_element_display_conditions', true ); - - if ( $display_conditions ) { - $new_values[ $post->ID ] = $display_conditions; - } - } - - return $new_values; -} - -/** - * Get our Element display locations. - * - * @since 1.7 - * @deprecated 2.0.0 - * - * @return array - */ -function generate_sites_export_elements_exclusion() { - $args = array( - 'post_type' => 'gp_elements', - 'showposts' => -1, - ); - - $posts = get_posts( $args ); - $new_values = array(); - - foreach ( $posts as $post ) { - $display_conditions = get_post_meta( $post->ID, '_generate_element_exclude_conditions', true ); - - if ( $display_conditions ) { - $new_values[ $post->ID ] = $display_conditions; - } - } - - return $new_values; -} - -/** - * List out compatible theme modules Sites can activate. - * - * @since 1.6 - * @deprecated 2.0.0 - * - * @return array - */ -function generatepress_get_site_premium_modules() { - return array( - 'Backgrounds' => 'generate_package_backgrounds', - 'Blog' => 'generate_package_blog', - 'Colors' => 'generate_package_colors', - 'Copyright' => 'generate_package_copyright', - 'Elements' => 'generate_package_elements', - 'Disable Elements' => 'generate_package_disable_elements', - 'Hooks' => 'generate_package_hooks', - 'Menu Plus' => 'generate_package_menu_plus', - 'Page Header' => 'generate_package_page_header', - 'Secondary Nav' => 'generate_package_secondary_nav', - 'Sections' => 'generate_package_sections', - 'Spacing' => 'generate_package_spacing', - 'Typography' => 'generate_package_typography', - 'WooCommerce' => 'generate_package_woocommerce', - ); -} - -/** - * Don't allow Sites to modify these options. - * - * @since 1.6 - * @deprecated 2.0.0 - * - * @return array - */ -function generatepress_sites_disallowed_options() { - return array( - 'admin_email', - 'siteurl', - 'home', - 'blog_charset', - 'blog_public', - 'current_theme', - 'stylesheet', - 'template', - 'default_role', - 'mailserver_login', - 'mailserver_pass', - 'mailserver_port', - 'mailserver_url', - 'permalink_structure', - 'rewrite_rules', - 'users_can_register', - ); -} - -/** - * Add our GeneratePress Site export checkbox to the Export module. - * - * @since 1.7 - * @deprecated 2.0.0 - */ -function generatepress_sites_add_export_checkbox() { - if ( ! apply_filters( 'generate_show_generatepress_site_export_option', false ) ) { - return; - } - ?> -
    - - - $key ) { - if ( 'activated' === get_option( $key ) ) { - $data['modules'][ $name ] = $key; - } - } - - // Site options. - $data['site_options']['nav_menu_locations'] = get_theme_mod( 'nav_menu_locations' ); - $data['site_options']['custom_logo'] = wp_get_attachment_url( get_theme_mod( 'custom_logo' ) ); - $data['site_options']['show_on_front'] = get_option( 'show_on_front' ); - $data['site_options']['page_on_front'] = get_option( 'page_on_front' ); - $data['site_options']['page_for_posts'] = get_option( 'page_for_posts' ); - - // Page header. - $data['site_options']['page_header_global_locations'] = get_option( 'generate_page_header_global_locations' ); - $data['site_options']['page_headers'] = generate_sites_export_page_headers(); - - // Elements. - $data['site_options']['element_locations'] = generate_sites_export_elements_location(); - $data['site_options']['element_exclusions'] = generate_sites_export_elements_exclusion(); - - // Custom CSS. - if ( function_exists( 'wp_get_custom_css_post' ) ) { - $data['custom_css'] = wp_get_custom_css_post()->post_content; - } - - // WooCommerce. - if ( is_plugin_active( 'woocommerce/woocommerce.php' ) ) { - $data['site_options']['woocommerce_shop_page_id'] = get_option( 'woocommerce_shop_page_id' ); - $data['site_options']['woocommerce_cart_page_id'] = get_option( 'woocommerce_cart_page_id' ); - $data['site_options']['woocommerce_checkout_page_id'] = get_option( 'woocommerce_checkout_page_id' ); - $data['site_options']['woocommerce_myaccount_page_id'] = get_option( 'woocommerce_myaccount_page_id' ); - $data['site_options']['woocommerce_single_image_width'] = get_option( 'woocommerce_single_image_width' ); - $data['site_options']['woocommerce_thumbnail_image_width'] = get_option( 'woocommerce_thumbnail_image_width' ); - $data['site_options']['woocommerce_thumbnail_cropping'] = get_option( 'woocommerce_thumbnail_cropping' ); - $data['site_options']['woocommerce_shop_page_display'] = get_option( 'woocommerce_shop_page_display' ); - $data['site_options']['woocommerce_category_archive_display'] = get_option( 'woocommerce_category_archive_display' ); - $data['site_options']['woocommerce_default_catalog_orderby'] = get_option( 'woocommerce_default_catalog_orderby' ); - } - - // Elementor. - if ( is_plugin_active( 'elementor/elementor.php' ) ) { - $data['site_options']['elementor_container_width'] = get_option( 'elementor_container_width' ); - $data['site_options']['elementor_cpt_support'] = get_option( 'elementor_cpt_support' ); - $data['site_options']['elementor_css_print_method'] = get_option( 'elementor_css_print_method' ); - $data['site_options']['elementor_default_generic_fonts'] = get_option( 'elementor_default_generic_fonts' ); - $data['site_options']['elementor_disable_color_schemes'] = get_option( 'elementor_disable_color_schemes' ); - $data['site_options']['elementor_disable_typography_schemes'] = get_option( 'elementor_disable_typography_schemes' ); - $data['site_options']['elementor_editor_break_lines'] = get_option( 'elementor_editor_break_lines' ); - $data['site_options']['elementor_exclude_user_roles'] = get_option( 'elementor_exclude_user_roles' ); - $data['site_options']['elementor_global_image_lightbox'] = get_option( 'elementor_global_image_lightbox' ); - $data['site_options']['elementor_page_title_selector'] = get_option( 'elementor_page_title_selector' ); - $data['site_options']['elementor_scheme_color'] = get_option( 'elementor_scheme_color' ); - $data['site_options']['elementor_scheme_color-picker'] = get_option( 'elementor_scheme_color-picker' ); - $data['site_options']['elementor_scheme_typography'] = get_option( 'elementor_scheme_typography' ); - $data['site_options']['elementor_space_between_widgets'] = get_option( 'elementor_space_between_widgets' ); - $data['site_options']['elementor_stretched_section_container'] = get_option( 'elementor_stretched_section_container' ); - $data['site_options']['elementor_load_fa4_shim'] = get_option( 'elementor_load_fa4_shim' ); - $data['site_options']['elementor_active_kit'] = get_option( 'elementor_active_kit' ); - } - - // Beaver Builder. - if ( is_plugin_active( 'beaver-builder-lite-version/fl-builder.php' ) || is_plugin_active( 'bb-plugin/fl-builder.php' ) ) { - $data['site_options']['_fl_builder_enabled_icons'] = get_option( '_fl_builder_enabled_icons' ); - $data['site_options']['_fl_builder_enabled_modules'] = get_option( '_fl_builder_enabled_modules' ); - $data['site_options']['_fl_builder_post_types'] = get_option( '_fl_builder_post_types' ); - $data['site_options']['_fl_builder_color_presets'] = get_option( '_fl_builder_color_presets' ); - $data['site_options']['_fl_builder_services'] = get_option( '_fl_builder_services' ); - $data['site_options']['_fl_builder_settings'] = get_option( '_fl_builder_settings' ); - $data['site_options']['_fl_builder_user_access'] = get_option( '_fl_builder_user_access' ); - $data['site_options']['_fl_builder_enabled_templates'] = get_option( '_fl_builder_enabled_templates' ); - } - - // Menu Icons. - if ( is_plugin_active( 'menu-icons/menu-icons.php' ) ) { - $data['site_options']['menu-icons'] = get_option( 'menu-icons' ); - } - - // Ninja Forms. - if ( is_plugin_active( 'ninja-forms/ninja-forms.php' ) ) { - $data['site_options']['ninja_forms_settings'] = get_option( 'ninja_forms_settings' ); - } - - // Social Warfare. - if ( is_plugin_active( 'social-warfare/social-warfare.php' ) ) { - $data['site_options']['socialWarfareOptions'] = get_option( 'socialWarfareOptions' ); - } - - // Elements Plus. - if ( is_plugin_active( 'elements-plus/elements-plus.php' ) ) { - $data['site_options']['elements_plus_settings'] = get_option( 'elements_plus_settings' ); - } - - // Ank Google Map. - if ( is_plugin_active( 'ank-google-map/ank-google-map.php' ) ) { - $data['site_options']['ank_google_map'] = get_option( 'ank_google_map' ); - } - - // GP Social Share. - if ( is_plugin_active( 'gp-social-share-svg/gp-social-share.php' ) ) { - $data['site_options']['gp_social_settings'] = get_option( 'gp_social_settings' ); - } - - // Active plugins. - $active_plugins = get_option( 'active_plugins' ); - $all_plugins = get_plugins(); - - $ignore = apply_filters( - 'generate_sites_ignore_plugins', - array( - 'gp-premium/gp-premium.php', - 'widget-importer-exporter/widget-importer-exporter.php', - ) - ); - - foreach ( $ignore as $plugin ) { - unset( $all_plugins[ $plugin ] ); - } - - $activated_plugins = array(); - - foreach ( $active_plugins as $p ) { - if ( isset( $all_plugins[ $p ] ) ) { - $activated_plugins[ $all_plugins[ $p ]['Name'] ] = $p; - } - } - - $data['plugins'] = $activated_plugins; - - return $data; - -} - -/** - * Get our sites from the site server. - * - * @since 1.12.0' - * @deprecated 2.0.0 - */ -function generate_get_sites_from_library() { - $remote_sites = get_transient( 'generatepress_sites' ); - $trusted_authors = get_transient( 'generatepress_sites_trusted_providers' ); - - if ( empty( $remote_sites ) ) { - $sites = array(); - - $data = wp_safe_remote_get( 'https://gpsites.co/wp-json/wp/v2/sites?per_page=100' ); - - if ( is_wp_error( $data ) ) { - set_transient( 'generatepress_sites', 'no results', 5 * MINUTE_IN_SECONDS ); - return; - } - - $data = json_decode( wp_remote_retrieve_body( $data ), true ); - - if ( ! is_array( $data ) ) { - set_transient( 'generatepress_sites', 'no results', 5 * MINUTE_IN_SECONDS ); - return; - } - - foreach ( (array) $data as $site ) { - $sites[ $site['name'] ] = array( - 'name' => $site['name'], - 'directory' => $site['directory'], - 'preview_url' => $site['preview_url'], - 'author_name' => $site['author_name'], - 'author_url' => $site['author_url'], - 'description' => $site['description'], - 'page_builder' => $site['page_builder'], - 'min_version' => $site['min_version'], - 'uploads_url' => $site['uploads_url'], - 'plugins' => $site['plugins'], - 'documentation' => $site['documentation'], - ); - } - - $sites = apply_filters( 'generate_add_sites', $sites ); - - set_transient( 'generatepress_sites', $sites, 24 * HOUR_IN_SECONDS ); - } - - if ( empty( $trusted_authors ) ) { - $trusted_authors = wp_safe_remote_get( 'https://gpsites.co/wp-json/sites/site' ); - - if ( is_wp_error( $trusted_authors ) || empty( $trusted_authors ) ) { - set_transient( 'generatepress_sites_trusted_providers', 'no results', 5 * MINUTE_IN_SECONDS ); - return; - } - - $trusted_authors = json_decode( wp_remote_retrieve_body( $trusted_authors ), true ); - - $authors = array(); - foreach ( (array) $trusted_authors['trusted_author'] as $author ) { - $authors[] = $author; - } - - set_transient( 'generatepress_sites_trusted_providers', $authors, 24 * HOUR_IN_SECONDS ); - } -} - -/** - * Fetch our sites and trusted authors. Stores them in their own transients. - * We use current_screen instead of admin_init so we can check what admin page we're on. - * - * @since 1.6 - * @deprecated 2.0.0 - */ -function generatepress_sites_init() { - $screen = get_current_screen(); - - if ( 'appearance_page_generate-options' === $screen->id || 'appearance_page_generatepress-site-library' === $screen->id ) { - generate_get_sites_from_library(); - } -} - -/** - * Initiate our Sites once everything has loaded. - * We use current_screen instead of admin_init so we can check what admin page we're on. - * - * @since 1.6 - * @deprecated 2.0.0 - */ -function generatepress_sites_output() { - if ( ! class_exists( 'GeneratePress_Site' ) ) { - return; // Bail if we don't have the needed class. - } - - $sites = get_transient( 'generatepress_sites' ); - - if ( empty( $sites ) || ! is_array( $sites ) ) { - add_action( 'generate_inside_sites_container', 'generatepress_sites_no_results_error' ); - return; - } - - if ( apply_filters( 'generate_sites_randomize', false ) ) { - shuffle( $sites ); - } - - foreach ( $sites as $site ) { - new GeneratePress_Site( $site ); - } -} - -/** - * Show an error message when no sites exist. - * - * @since 1.8.2 - * @deprecated 2.0.0 - */ -function generatepress_sites_no_results_error() { - printf( - '
    - %1$s %2$s -
    ', - __( 'No sites found.', 'gp-premium' ), - __( 'Why?', 'gp-premium' ), - 'https://docs.generatepress.com/article/site-library-unavailable/' - ); -} - -/** - * Build each site UI. - * - * @deprecated 2.0.0 - */ -class GeneratePress_Site { - /** - * Get it rockin' - * - * @param array $config The site configuration. - */ - public function __construct( $config = array() ) { - // Do nothing. - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/deprecated.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/deprecated.php deleted file mode 100644 index e84e37a8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/deprecated.php +++ /dev/null @@ -1,728 +0,0 @@ -current_post == 0 && $paged == 1 ) ? true : false; - - // Get our Customizer options - $generate_blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - $masonry_post_width = $generate_blog_settings['masonry_width']; - - // Get our post meta option - $stored_meta = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate-blog-post-class', true ) : ''; - - // If our post meta option is set, use it - // Or else, use our Customizer option - if ( '' !== $stored_meta ) { - if ( 'width4' == $stored_meta && 'width4' == $generate_blog_settings['masonry_width'] ) { - $masonry_post_width = 'medium'; - } else { - $masonry_post_width = $stored_meta; - } - } - - // Return our width class - return apply_filters( 'generate_masonry_post_width', $masonry_post_width ); - } -} - -if ( ! function_exists( 'generate_blog_add_post_class_meta_box' ) ) { - /** - * Create our masonry meta box - * - * @deprecated 1.5 - */ - function generate_blog_add_post_class_meta_box() { - $generate_blog_settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( 'true' !== $generate_blog_settings['masonry'] ) { - return; - } - - $post_types = apply_filters( 'generate_blog_masonry_metabox', array( 'post' ) ); - - add_meta_box - ( - 'generate_blog_post_class_meta_box', // $id - __('Masonry Post Width','generate-blog'), // $title - 'generate_blog_show_post_class_metabox', // $callback - $post_types, // $page - 'side', // $context - 'default' // $priority - ); - } -} - -if ( ! function_exists( 'generate_blog_show_post_class_metabox' ) ) { - /** - * Outputs the content of the metabox - * @deprecated 1.5 - */ - function generate_blog_show_post_class_metabox( $post ) { - wp_nonce_field( basename( __FILE__ ), 'generate_blog_post_class_nonce' ); - $stored_meta = get_post_meta( $post->ID ); - - // Set defaults to avoid PHP notices - if ( isset($stored_meta['_generate-blog-post-class'][0]) ) { - $stored_meta['_generate-blog-post-class'][0] = $stored_meta['_generate-blog-post-class'][0]; - } else { - $stored_meta['_generate-blog-post-class'][0] = ''; - } - ?> -

    -
    - -

    - max_num_pages; - } - - if ( ! $paged ) { - $paged = 1; - } - - $nextpage = intval( $paged ) + 1; - - if ( ! is_single() && ( $nextpage <= $max_page ) ) { - return next_posts( $max_page, false ); - } - } -} - -/** - * Fixes a bug in Safari where images with srcset won't display when using infinite scroll. - * - * @since 1.5.5 - * @deprecated 1.6 - */ -function generate_blog_disable_infinite_scroll_srcset() { - $settings = wp_parse_args( - get_option( 'generate_blog_settings', array() ), - generate_blog_get_defaults() - ); - - if ( ! is_singular() && $settings[ 'infinite_scroll' ] ) { - add_filter( 'wp_calculate_image_srcset', '__return_empty_array' ); - } -} - -if ( ! function_exists( 'generate_blog_init' ) ) { - function generate_blog_init() { - load_plugin_textdomain( 'generate-blog', false, 'gp-premium/langs/blog/' ); - } -} - -/** - * Colors module. - */ -if ( ! function_exists( 'generate_colors_init' ) ) { - function generate_colors_init() { - load_plugin_textdomain( 'generate-colors', false, 'gp-premium/langs/colors/' ); - } -} - -if ( ! function_exists( 'generate_colors_setup' ) ) { - function generate_colors_setup() { - // Here so we can check to see if Colors is activated - } -} - -/** - * Copyright module. - */ -if ( ! function_exists( 'generate_copyright_init' ) ) { - function generate_copyright_init() { - load_plugin_textdomain( 'generate-copyright', false, 'gp-premium/langs/copyright/' ); - } -} - -/** - * Disable Elements module. - */ -if ( ! function_exists('generate_disable_elements_init') ) { - function generate_disable_elements_init() { - load_plugin_textdomain( 'disable-elements', false, 'gp-premium/langs/disable-elements/' ); - } -} - -/** - * Hooks module. - */ -if ( ! function_exists( 'generate_hooks_init' ) ) { - function generate_hooks_init() { - load_plugin_textdomain( 'generate-hooks', false, 'gp-premium/langs/hooks/' ); - } -} - -/** - * Import/Export module. - */ -if ( ! function_exists( 'generate_ie_init' ) ) { - function generate_ie_init() { - load_plugin_textdomain( 'generate-ie', false, 'gp-premium/langs/import-export/' ); - } -} - -/** - * Menu Plus module. - */ -if ( ! function_exists( 'generate_slideout_navigation_class' ) ) { - /** - * Display the classes for the slideout navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - */ - function generate_slideout_navigation_class( $class = '' ) { - // Separates classes with a single space, collates classes for post DIV - echo 'class="' . join( ' ', generate_get_slideout_navigation_class( $class ) ) . '"'; - } -} - -if ( ! function_exists( 'generate_get_slideout_navigation_class' ) ) { - /** - * Retrieve the classes for the slideout navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - * @return array Array of classes. - */ - function generate_get_slideout_navigation_class( $class = '' ) { - $classes = array(); - - if ( !empty($class) ) { - if ( !is_array( $class ) ) - $class = preg_split('#\s+#', $class); - $classes = array_merge($classes, $class); - } - - $classes = array_map('esc_attr', $classes); - - return apply_filters('generate_slideout_navigation_class', $classes, $class); - } -} - -if ( ! function_exists( 'generate_slideout_menu_class' ) ) { - /** - * Display the classes for the slideout navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - */ - function generate_slideout_menu_class( $class = '' ) { - // Separates classes with a single space, collates classes for post DIV - echo 'class="' . join( ' ', generate_get_slideout_menu_class( $class ) ) . '"'; - } -} - -if ( ! function_exists( 'generate_get_slideout_menu_class' ) ) { - /** - * Retrieve the classes for the slideout navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - * @return array Array of classes. - */ - function generate_get_slideout_menu_class( $class = '' ) { - $classes = array(); - - if ( !empty($class) ) { - if ( !is_array( $class ) ) - $class = preg_split('#\s+#', $class); - $classes = array_merge($classes, $class); - } - - $classes = array_map('esc_attr', $classes); - - return apply_filters('generate_slideout_menu_class', $classes, $class); - } -} - -if ( ! function_exists( 'generate_slideout_menu_classes' ) ) { - /** - * Adds custom classes to the menu - * @since 0.1 - */ - function generate_slideout_menu_classes( $classes ) { - $classes[] = 'slideout-menu'; - return $classes; - } -} - -if ( ! function_exists( 'generate_slideout_navigation_classes' ) ) { - /** - * Adds custom classes to the navigation - * @since 0.1 - */ - function generate_slideout_navigation_classes( $classes ){ - $slideout_effect = apply_filters( 'generate_menu_slideout_effect','overlay' ); - $slideout_position = apply_filters( 'generate_menu_slideout_position','left' ); - - $classes[] = 'main-navigation'; - $classes[] = 'slideout-navigation'; - - return $classes; - } -} - -if ( ! function_exists( 'generate_menu_plus_init' ) ) { - function generate_menu_plus_init() { - load_plugin_textdomain( 'menu-plus', false, 'gp-premium/langs/menu-plus/' ); - } -} - -if ( ! function_exists( 'generate_slideout_menu_fallback' ) ) { - /** - * Menu fallback. - * - * @param array $args - * @return string - * @since 1.1.4 - */ - function generate_slideout_menu_fallback( $args ) { - - } -} - -/** - * Page header module. - */ -if ( ! function_exists( 'generate_page_header_inside' ) ) { - /** - * Add page header inside content - * @since 0.3 - */ - function generate_page_header_inside() { - if ( ! is_page() ) { - return; - } - - if ( 'inside-content' == generate_get_page_header_location() ) { - generate_page_header_area( 'page-header-image', 'page-header-content' ); - } - } -} - -if ( ! function_exists( 'generate_page_header_single_below_title' ) ) { - /** - * Add post header below title - * @since 0.3 - */ - function generate_page_header_single_below_title() { - if ( ! is_single() ) { - return; - } - - if ( 'below-title' == generate_get_page_header_location() ) { - generate_page_header_area( 'page-header-image-single page-header-below-title', 'page-header-content-single page-header-below-title' ); - } - } -} - -if ( ! function_exists( 'generate_page_header_single_above' ) ) { - /** - * Add post header above content - * @since 0.3 - */ - function generate_page_header_single_above() { - if ( ! is_single() ) { - return; - } - - if ( 'above-content' == generate_get_page_header_location() ) { - generate_page_header_area( 'page-header-image-single', 'page-header-content-single' ); - } - } -} - -if ( ! function_exists( 'generate_page_header_single' ) ) { - /** - * Add post header inside content - * @since 0.3 - */ - function generate_page_header_single() { - $image_class = 'page-header-image-single'; - $content_class = 'page-header-content-single'; - - if ( 'below-title' == generate_get_page_header_location() ) { - $image_class = 'page-header-image-single page-header-below-title'; - $content_class = 'page-header-content-single page-header-below-title'; - } - - if ( 'inside-content' == generate_get_page_header_location() ) { - generate_page_header_area( $image_class, $content_class ); - } - } -} - -if ( ! function_exists( 'generate_page_header_init' ) ) { - function generate_page_header_init() { - load_plugin_textdomain( 'page-header', false, 'gp-premium/langs/page-header/' ); - } -} - -/** - * Secondary Navigation module. - */ -if ( ! function_exists( 'generate_secondary_nav_init' ) ) { - function generate_secondary_nav_init() { - load_plugin_textdomain( 'secondary-nav', false, 'gp-premium/langs/secondary-nav/' ); - } -} - -/** - * Sections module. - */ -if ( ! function_exists( 'generate_sections_init' ) ) { - function generate_sections_init() { - load_plugin_textdomain( 'generate-sections', false, 'gp-premium/langs/sections/' ); - } -} - -if ( ! function_exists( 'generate_sections_metabox_init' ) ) { - /* - * Enqueue styles and scripts specific to metaboxs - */ - function generate_sections_metabox_init(){ - - // I prefer to enqueue the styles only on pages that are using the metaboxes - wp_enqueue_style( 'generate-sections-metabox', plugin_dir_url( __FILE__ ) . 'wpalchemy/css/meta.css'); - wp_enqueue_style( 'generate-style-grid', get_template_directory_uri() . '/css/unsemantic-grid.css', false, GENERATE_VERSION, 'all' ); - - //make sure we enqueue some scripts just in case ( only needed for repeating metaboxes ) - wp_enqueue_script( 'jquery' ); - wp_enqueue_script( 'jquery-ui-core' ); - wp_enqueue_script( 'jquery-ui-widget' ); - wp_enqueue_script( 'jquery-ui-mouse' ); - wp_enqueue_script( 'jquery-ui-sortable' ); - wp_enqueue_style( 'wp-color-picker' ); - - // special script for dealing with repeating textareas- needs to run AFTER all the tinyMCE init scripts, so make 'editor' a requirement - wp_enqueue_script( 'generate-sections-metabox', plugin_dir_url( __FILE__ ) . 'wpalchemy/js/sections-metabox.js', array( 'jquery', 'editor', 'media-upload', 'wp-color-picker' ), GENERATE_SECTIONS_VERSION, true ); - $translation_array = array( - 'no_content_error' => __( 'Error: Content already detected in default editor.', 'gp-premium' ), - 'use_visual_editor' => __( 'Please activate the "Visual" tab in your main editor before transferring content.', 'gp-premium' ) - ); - wp_localize_script( 'generate-sections-metabox', 'generate_sections', $translation_array ); - } -} - -/** - * Spacing module. - */ -if ( ! function_exists( 'generate_spacing_init' ) ) { - function generate_spacing_init() { - load_plugin_textdomain( 'generate-spacing', false, 'gp-premium/langs/spacing/' ); - } -} - -if ( ! function_exists( 'generate_spacing_setup' ) ) { - function generate_spacing_setup() { - // Here so we can check to see if Spacing is active - } -} - -/** - * Typography module. - */ -if ( ! function_exists( 'generate_typography_init' ) ) { - function generate_typography_init() { - load_plugin_textdomain( 'generate-typography', false, 'gp-premium/langs/typography/' ); - } -} - -if ( ! function_exists( 'generate_fonts_setup' ) ) { - function generate_fonts_setup() { - // Here to check if Typography is active - } -} - -/** - * WooCommerce module. - */ -if ( ! function_exists( 'generate_woocommerce_init' ) ) { - function generate_woocommerce_init() { - load_plugin_textdomain( 'generate-woocommerce', false, 'gp-premium/langs/woocommerce/' ); - } -} - -/** - * Use text instead of an icon if essentials are in use. - * - * @since 1.3 - * @deprecated 1.6 - * - * @param string $icon Existing icon HTML. - * @return string New icon HTML. - */ -function generatepress_wc_essentials_menu_icon( $icon ) { - if ( apply_filters( 'generate_fontawesome_essentials', false ) ) { - return __( 'Cart', 'gp-premium' ); - } - - return $icon; -} - -if ( ! function_exists( 'generate_activation_styles' ) ) { - function generate_activation_styles() { - // Added to dashboard.css - } -} - -if ( ! function_exists( 'generate_verify_styles' ) ) { - function generate_verify_styles() { - // Added to dashboard.css - } -} - -if ( ! function_exists( 'generate_add_license_key_field' ) ) { - function generate_add_license_key_field() { - // Replaced by generatepress_premium_license_key_field() - } -} - -if ( ! function_exists( 'generate_premium_license_key' ) ) { - function generate_premium_license_key() { - // Replaced by generatepress_premium_license_key_field() - } -} - -if ( ! function_exists( 'generate_save_premium_license_key' ) ) { - function generate_save_premium_license_key() { - // Replaced by generatepress_premium_process_license_key() - } -} - - -if ( ! function_exists( 'generate_process_license_key' ) ) { - function generate_process_license_key() { - // Replaced by generatepress_premium_process_license_key() - } -} - -/** - * Add the Refresh sites link after the list of sites. - * - * @since 1.6 - * @deprecated 1.7 - */ -function generate_sites_refresh_link() { - if ( ! generate_is_sites_dashboard() ) { - return; - } - - printf( - '
    - %2$s -
    ', - wp_nonce_url( admin_url( 'themes.php?page=generate-options&area=generate-sites' ), 'refresh_sites', 'refresh_sites_nonce' ), - __( 'Refresh Sites', 'gp-premium' ) - ); -} - -/** - * Delete our sites transient if the Refresh sites link is clicked. - * - * @since 1.6 - * @deprecated 1.12.0 - */ -function generate_sites_refresh_list() { - if ( ! isset( $_GET['refresh_sites_nonce'] ) || ! wp_verify_nonce( $_GET['refresh_sites_nonce'], 'refresh_sites' ) ) { - return; - } - - delete_transient( 'generatepress_sites' ); -} - -if ( ! function_exists( 'generate_insert_import_export' ) ) { - /** - * @deprecated 1.7 - */ - function generate_insert_import_export() { - // Replaced by GeneratePress_Import_Export::build_html() - } -} - -if ( ! function_exists( 'generate_ie_import_form' ) ) { - /** - * @deprecated 1.7 - */ - function generate_ie_import_form() { - // Replaced by GeneratePress_Import_Export::build_html() - } -} - -if ( ! function_exists( 'generate_process_settings_export' ) ) { - /** - * Process a settings export that generates a .json file of the shop settings - * - * @deprecated 1.7 - */ - function generate_process_settings_export() { - // Replaced by GeneratePress_Import_Export::export() - } -} - -if ( ! function_exists( 'generate_process_settings_import' ) ) { - /** - * Process a settings import from a json file - * - * @deprecated 1.7 - */ - function generate_process_settings_import() { - // Replaced by GeneratePress_Import_Export::import() - } -} - -if ( ! function_exists( 'generate_ie_exportable' ) ) { - /** - * @deprecated 1.7 - */ - function generate_ie_exportable() { - // A check to see if other addons can add their export button - } -} - -/** - * Build our dynamic CSS. - * - * @since 1.6 - */ -function generate_menu_plus_make_css() { - // Replaced by generate_do_off_canvas_css() -} - -/** - * Enqueue our dynamic CSS. - * - * @since 1.6 - */ -function generate_menu_plus_enqueue_dynamic_css() { - // No longer needed. -} - -if ( ! function_exists( 'generate_hidden_secondary_navigation' ) && function_exists( 'is_customize_preview' ) ) { - /** - * Adds a hidden navigation if no navigation is set - * This allows us to use postMessage to position the navigation when it doesn't exist - */ - function generate_hidden_secondary_navigation() { - if ( is_customize_preview() && function_exists( 'generate_secondary_navigation_position' ) ) { - ?> -
    - -
    - $desktop, - 'tablet' => $tablet, - 'mobile' => $mobile, - 'mobile-menu' => $mobile_menu, - ) - ); - - return $queries[ $name ]; -} - -/** - * Get our CSS print method. - * - * @since 1.11.0 - */ -function generate_get_css_print_method() { - $mode = apply_filters( 'generatepress_dynamic_css_print_method', 'inline' ); - - if ( - ( function_exists( 'is_customize_preview' ) && is_customize_preview() ) - || - is_preview() - || - // AMP inlines all CSS, so inlining from the start improves CSS processing performance. - ( function_exists( 'is_amp_endpoint' ) && is_amp_endpoint() ) - ) { - return 'inline'; - } - - if ( ! defined( 'GENERATE_VERSION' ) ) { - return 'inline'; - } - - return $mode; -} - -/** - * Check to see if we have a Block Element. - * - * @since 2.0.0 - * @param string $element The type of element to check. - * @param boolean $block_element Whether it's a block element or not. - */ -function generate_has_active_element( $element, $block_element ) { - global $generate_elements; - - if ( ! empty( $generate_elements ) ) { - foreach ( (array) $generate_elements as $key => $data ) { - if ( $element === $data['type'] && $block_element === $data['is_block_element'] ) { - return true; - } - } - } - - return false; -} - -/** - * Check our GeneratePress version. - * - * @since 2.1.0 - */ -function generate_premium_get_theme_version() { - return defined( 'GENERATE_VERSION' ) ? GENERATE_VERSION : false; -} - -/** - * Remove the featured-image-active class if needed. - * - * @since 2.1.0 - */ -function generate_premium_remove_featured_image_class( $classes, $remove_class ) { - if ( $remove_class && in_array( 'featured-image-active', $classes ) ) { - $classes = array_diff( $classes, array( 'featured-image-active' ) ); - } - - return $classes; -} - -/** - * Returns the global $wp_filesystem with credentials set. - * Returns null in case of any errors. - * - * @return WP_Filesystem_Base|null - */ -function generate_premium_get_wp_filesystem() { - global $wp_filesystem; - - $success = true; - - // Initialize the file system if it has not been done yet. - if ( ! $wp_filesystem ) { - require_once ABSPATH . '/wp-admin/includes/file.php'; - - $constants = array( - 'hostname' => 'FTP_HOST', - 'username' => 'FTP_USER', - 'password' => 'FTP_PASS', - 'public_key' => 'FTP_PUBKEY', - 'private_key' => 'FTP_PRIKEY', - ); - - $credentials = array(); - - // We provide credentials based on wp-config.php constants. - // Reference https://developer.wordpress.org/apis/wp-config-php/#wordpress-upgrade-constants. - foreach ( $constants as $key => $constant ) { - if ( defined( $constant ) ) { - $credentials[ $key ] = constant( $constant ); - } - } - - $success = WP_Filesystem( $credentials ); - } - - if ( ! $success || $wp_filesystem->errors->has_errors() ) { - return null; - } - - return $wp_filesystem; -} - -/** - * Get our script dependencies and version. - * - * @param string $filename The filename to use. - * @param array $fallback_assets The assets to fallback to. - */ -function generate_premium_get_enqueue_assets( - $filename = '', - $fallback_assets = array( - 'dependencies' => array(), - 'version' => '', - ) -) { - if ( ! $filename ) { - return $fallback_assets; - } - - $assets_file = GP_PREMIUM_DIR_PATH . 'dist/' . $filename . '.asset.php'; - $compiled_assets = file_exists( $assets_file ) - ? require $assets_file - : false; - - $assets = - isset( $compiled_assets['dependencies'] ) && - isset( $compiled_assets['version'] ) - ? $compiled_assets - : $fallback_assets; - - return $assets; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/activation.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/activation.php deleted file mode 100644 index bce1852b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/activation.php +++ /dev/null @@ -1,623 +0,0 @@ -base ) { - return; - } - - wp_enqueue_style( 'generate-premium-dashboard', plugin_dir_url( __FILE__ ) . 'assets/dashboard.css', array(), GP_PREMIUM_VERSION ); - wp_enqueue_script( 'generate-premium-dashboard', plugin_dir_url( __FILE__ ) . 'assets/dashboard.js', array( 'jquery' ), GP_PREMIUM_VERSION, true ); - - wp_localize_script( - 'generate-premium-dashboard', - 'dashboard', - array( - 'deprecated_module' => esc_attr__( 'This module has been deprecated. Deactivating it will remove it from this list.', 'gp-premium' ), - ) - ); -} - -if ( ! function_exists( 'generate_premium_notices' ) ) { - add_action( 'admin_notices', 'generate_premium_notices' ); - /* - * Set up errors and messages - */ - function generate_premium_notices() { - if ( isset( $_GET['generate-message'] ) && 'addon_deactivated' == $_GET['generate-message'] ) { - add_settings_error( 'generate-premium-notices', 'addon_deactivated', __( 'Module deactivated.', 'gp-premium' ), 'updated' ); - } - - if ( isset( $_GET['generate-message'] ) && 'addon_activated' == $_GET['generate-message'] ) { - add_settings_error( 'generate-premium-notices', 'addon_activated', __( 'Module activated.', 'gp-premium' ), 'updated' ); - } - - settings_errors( 'generate-premium-notices' ); - } -} - -if ( ! function_exists( 'generate_license_errors' ) ) { - add_action( 'admin_notices', 'generate_license_errors' ); - /* - * Set up errors and messages - */ - function generate_license_errors() { - if ( isset( $_GET['generate-message'] ) && 'deactivation_passed' == $_GET['generate-message'] ) { - add_settings_error( 'generate-license-notices', 'deactivation_passed', __( 'License deactivated.', 'gp-premium' ), 'updated' ); - } - - if ( isset( $_GET['generate-message'] ) && 'license_activated' == $_GET['generate-message'] ) { - add_settings_error( 'generate-license-notices', 'license_activated', __( 'License activated.', 'gp-premium' ), 'updated' ); - } - - if ( isset( $_GET['sl_activation'] ) && ! empty( $_GET['message'] ) ) { - - switch ( $_GET['sl_activation'] ) { - - case 'false': - $message = urldecode( $_GET['message'] ); - add_settings_error( 'generate-license-notices', 'license_failed', esc_html( $message ), 'error' ); - break; - - case 'true': - default: - break; - - } - } - - settings_errors( 'generate-license-notices' ); - } -} - -if ( ! function_exists( 'generate_super_package_addons' ) ) { - add_action( 'generate_options_items', 'generate_super_package_addons', 5 ); - /** - * Build the area that allows us to activate and deactivate modules. - * - * @since 0.1 - */ - function generate_super_package_addons() { - $addons = array( - 'Backgrounds' => 'generate_package_backgrounds', - 'Blog' => 'generate_package_blog', - 'Colors' => 'generate_package_colors', - 'Copyright' => 'generate_package_copyright', - 'Disable Elements' => 'generate_package_disable_elements', - 'Elements' => 'generate_package_elements', - 'Hooks' => 'generate_package_hooks', - 'Menu Plus' => 'generate_package_menu_plus', - 'Page Header' => 'generate_package_page_header', - 'Secondary Nav' => 'generate_package_secondary_nav', - 'Sections' => 'generate_package_sections', - 'Spacing' => 'generate_package_spacing', - 'Typography' => 'generate_package_typography', - 'WooCommerce' => 'generate_package_woocommerce', - ); - - if ( version_compare( PHP_VERSION, '5.4', '>=' ) && ! defined( 'GENERATE_DISABLE_SITE_LIBRARY' ) ) { - $addons['Site Library'] = 'generate_package_site_library'; - } - - if ( function_exists( 'generate_is_using_dynamic_typography' ) && generate_is_using_dynamic_typography() ) { - unset( $addons['Typography'] ); - } - - if ( version_compare( generate_premium_get_theme_version(), '3.1.0-alpha.1', '>=' ) ) { - unset( $addons['Colors'] ); - } - - ksort( $addons ); - - $addon_count = 0; - foreach ( $addons as $k => $v ) { - if ( 'activated' == get_option( $v ) ) - $addon_count++; - } - - $key = get_option( 'gen_premium_license_key_status', 'deactivated' ); - $version = ( defined( 'GP_PREMIUM_VERSION' ) ) ? GP_PREMIUM_VERSION : ''; - - ?> -
    -

    -
    -
    -
    -
    -
    - - - - -
    -
    - $v ) : - - $key = get_option( $v ); - - if( $key == 'activated' ) { ?> -
    -
    - - -
    -
    - - -
    -
    - -
    - -
    - type="checkbox" class="addon-checkbox" name="generate_addon_checkbox[]" value="" /> - -
    - -
    - - - - - - -
    - -
    -
    '; - endforeach; - ?> - -
    -
    - - 'generate_package_typography', - 'Colors' => 'generate_package_colors', - 'Backgrounds' => 'generate_package_backgrounds', - 'Page Header' => 'generate_package_page_header', - 'Sections' => 'generate_package_sections', - 'Copyright' => 'generate_package_copyright', - 'Disable Elements' => 'generate_package_disable_elements', - 'Elements' => 'generate_package_elements', - 'Blog' => 'generate_package_blog', - 'Hooks' => 'generate_package_hooks', - 'Spacing' => 'generate_package_spacing', - 'Secondary Nav' => 'generate_package_secondary_nav', - 'Menu Plus' => 'generate_package_menu_plus', - 'WooCommerce' => 'generate_package_woocommerce', - ); - - if ( version_compare( PHP_VERSION, '5.4', '>=' ) && ! defined( 'GENERATE_DISABLE_SITE_LIBRARY' ) ) { - $addons['Site Library'] = 'generate_package_site_library'; - } - - foreach( $addons as $k => $v ) : - - if ( isset( $_POST[$v . '_activate_package'] ) ) { - - // If we didn't click the button, bail. - if ( ! check_admin_referer( $v . '_activate_nonce', $v . '_activate_nonce' ) ) { - return; - } - - // If we're not an administrator, bail. - if ( ! current_user_can( 'manage_options' ) ) { - return; - } - - $autoload = null; - - if ( 'generate_package_site_library' === $v ) { - $autoload = false; - } - - update_option( $v, 'activated', $autoload ); - wp_safe_redirect( admin_url( 'themes.php?page=generate-options&generate-message=addon_activated' ) ); - exit; - } - - endforeach; - } -} - -/*********************************************** -* Deactivate the plugin -***********************************************/ -if ( ! function_exists( 'generate_deactivate_super_package_addons' ) ) { - add_action( 'admin_init', 'generate_deactivate_super_package_addons' ); - - function generate_deactivate_super_package_addons() { - $addons = array( - 'Typography' => 'generate_package_typography', - 'Colors' => 'generate_package_colors', - 'Backgrounds' => 'generate_package_backgrounds', - 'Page Header' => 'generate_package_page_header', - 'Sections' => 'generate_package_sections', - 'Copyright' => 'generate_package_copyright', - 'Disable Elements' => 'generate_package_disable_elements', - 'Elements' => 'generate_package_elements', - 'Blog' => 'generate_package_blog', - 'Hooks' => 'generate_package_hooks', - 'Spacing' => 'generate_package_spacing', - 'Secondary Nav' => 'generate_package_secondary_nav', - 'Menu Plus' => 'generate_package_menu_plus', - 'WooCommerce' => 'generate_package_woocommerce', - ); - - if ( version_compare( PHP_VERSION, '5.4', '>=' ) && ! defined( 'GENERATE_DISABLE_SITE_LIBRARY' ) ) { - $addons['Site Library'] = 'generate_package_site_library'; - } - - foreach( $addons as $k => $v ) : - - if ( isset( $_POST[$v . '_deactivate_package'] ) ) { - - // If we didn't click the button, bail. - if ( ! check_admin_referer( $v . '_deactivate_nonce', $v . '_deactivate_nonce' ) ) { - return; - } - - // If we're not an administrator, bail. - if ( ! current_user_can( 'manage_options' ) ) { - return; - } - - $autoload = null; - - if ( 'generate_package_site_library' === $v ) { - $autoload = false; - } - - update_option( $v, 'deactivated', $autoload ); - wp_safe_redirect( admin_url('themes.php?page=generate-options&generate-message=addon_deactivated' ) ); - exit; - } - - endforeach; - } -} - -if ( ! function_exists( 'generate_premium_body_class' ) ) { - add_filter( 'admin_body_class', 'generate_premium_body_class' ); - /** - * Add a class or many to the body in the dashboard - */ - function generate_premium_body_class( $classes ) { - return "$classes gp_premium"; - } -} - -if ( ! function_exists( 'generate_activation_area' ) ) { - add_action( 'generate_admin_right_panel', 'generate_activation_area' ); - - function generate_activation_area() { - $license = get_option( 'gen_premium_license_key', '' ); - $key = get_option( 'gen_premium_license_key_status', 'deactivated' ); - - if ( 'valid' == $key ) { - $message = sprintf( '%s', __( 'Receiving updates', 'gp-premium' ) ); - } else { - $message = sprintf( '%s', __( 'Not receiving updates', 'gp-premium' ) ); - } - ?> -
    -
    -

    - - - - [?] - -

    - -
    -
    -

    - -

    - -

    > - /> - -

    - - - -
    -
    -
    -
    - 'activate_license', - 'license' => $new, - 'item_name' => urlencode( 'GP Premium' ), - 'url' => home_url() - ); - } - - // If we don't have a value (it's been cleared), run deactivation. - if ( '' == $new && 'valid' == get_option( 'gen_premium_license_key_status' ) ) { - $api_params = array( - 'edd_action' => 'deactivate_license', - 'license' => $old, - 'item_name' => urlencode( 'GP Premium' ), - 'url' => home_url() - ); - } - - // Nothing? Get out of here. - if ( ! isset( $api_params ) ) { - wp_safe_redirect( admin_url( 'themes.php?page=generate-options' ) ); - exit; - } - - // Phone home. - $license_response = wp_remote_post( 'https://generatepress.com', array( - 'timeout' => 60, - 'sslverify' => false, - 'body' => $api_params - ) ); - - // Make sure the response came back okay. - if ( is_wp_error( $license_response ) || 200 !== wp_remote_retrieve_response_code( $license_response ) ) { - if ( is_object( $license_response ) ) { - $message = $license_response->get_error_message(); - } elseif ( is_array( $license_response ) && isset( $license_response['response']['message'] ) ) { - if ( 'Forbidden' === $license_response['response']['message'] ) { - $message = __( '403 Forbidden. Your server is not able to communicate with generatepress.com in order to activate your license key.', 'gp-premium' ); - } else { - $message = $license_response['response']['message']; - } - } - } else { - - // Still here? Decode our response. - $license_data = json_decode( wp_remote_retrieve_body( $license_response ) ); - - if ( false === $license_data->success ) { - - switch ( $license_data->error ) { - - case 'expired' : - - $message = sprintf( - __( 'Your license key expired on %s.', 'gp-premium' ), - date_i18n( get_option( 'date_format' ), strtotime( $license_data->expires, current_time( 'timestamp' ) ) ) - ); - break; - - case 'revoked' : - - $message = __( 'Your license key has been disabled.', 'gp-premium' ); - break; - - case 'missing' : - - $message = __( 'Invalid license.', 'gp-premium' ); - break; - - case 'invalid' : - case 'site_inactive' : - - $message = __( 'Your license is not active for this URL.', 'gp-premium' ); - break; - - case 'item_name_mismatch' : - - $message = __( 'This appears to be an invalid license key for GP Premium.', 'gp-premium' ); - break; - - case 'no_activations_left': - - $message = __( 'Your license key has reached its activation limit.', 'gp-premium' ); - break; - - default : - - $message = __( 'An error occurred, please try again.', 'gp-premium' ); - break; - } - - } - - } - - // Check if anything passed on a message constituting a failure - if ( ! empty( $message ) ) { - delete_option( 'gen_premium_license_key_status' ); - $base_url = admin_url( 'themes.php?page=generate-options' ); - $redirect = add_query_arg( array( 'sl_activation' => 'false', 'message' => urlencode( $message ) ), esc_url( $base_url ) ); - wp_redirect( $redirect ); - exit(); - } - - // Update our license key status - update_option( 'gen_premium_license_key_status', $license_data->license ); - - if ( 'valid' == $license_data->license ) { - // Validated, go tell them - wp_safe_redirect( admin_url( 'themes.php?page=generate-options&generate-message=license_activated' ) ); - exit; - } elseif ( 'deactivated' == $license_data->license ) { - // Deactivated, go tell them - wp_safe_redirect( admin_url( 'themes.php?page=generate-options&generate-message=deactivation_passed' ) ); - exit; - } else { - // Failed, go tell them - wp_safe_redirect( admin_url( 'themes.php?page=generate-options&generate-message=license_failed' ) ); - exit; - } - } -} - -if ( ! function_exists( 'generate_license_missing' ) ) { - add_action( 'in_plugin_update_message-gp-premium/gp-premium.php', 'generate_license_missing', 10, 2 ); - /** - * Add a message to the plugin update area if no license key is set - */ - function generate_license_missing() { - $license = get_option( 'gen_premium_license_key_status' ); - - if ( 'valid' !== $license ) { - echo ' ' . __( 'Enter valid license key for automatic updates.', 'gp-premium' ) . ''; - } - } -} - -add_filter( 'generate_premium_beta_tester', 'generatepress_premium_beta_tester' ); -/** - * Enable beta testing if our option is set. - * - * @since 1.6 - */ -function generatepress_premium_beta_tester( $value ) { - if ( get_option( 'gp_premium_beta_testing', false ) ) { - return true; - } - - return $value; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/assets/dashboard.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/assets/dashboard.css deleted file mode 100644 index 700993cb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/assets/dashboard.css +++ /dev/null @@ -1,199 +0,0 @@ -.generatepress-dashboard-tabs { - margin-bottom: 40px; -} - -.generatepress-dashboard-tabs a { - background-color: rgba(255,255,255,0.5); - border: 1px solid #ddd; - padding: 10px 15px; - cursor: pointer; - color: #222; - display: inline-block; - text-decoration: none; -} - -.generatepress-dashboard-tabs a:not(:last-child) { - border-right: 0; -} - -.generatepress-dashboard-tabs a.active { - background-color: #ffffff; - border-color: #ccc; - font-weight: 500; -} - -input#generate-select-all, -.addon-checkbox { - margin-right: 15px !important; -} -.gp-premium-version, -.gp-addon-count { - display: block; - color:#ccc; -} - -.addon-container:before, -.addon-container:after { - content: "."; - display: block; - overflow: hidden; - visibility: hidden; - font-size: 0; - line-height: 0; - width: 0; - height: 0; -} - -.addon-container:after { - clear: both; -} - -.premium-addons .gp-clear { - margin: 0 !important; - border: 0; - padding: 0 !important; -} - -.premium-addons .add-on.gp-clear { - padding: 15px !important; - margin: 0 !important; - box-shadow: 0 -1px 0 rgba(0, 0, 0, 0.1) inset; -} - -.premium-addons .add-on:last-child { - border: 0 !important; -} - -.addon-action { - float: right; - clear: right; -} - -.addon-name { - float: left; -} - -.premium-addons .add-on.gp-clear.activated { - background-color:#F7FCFE !important; - border-left: 5px solid #2EA2CC !important; - font-weight: bold; - padding-left: 10px !important; -} - -.premium-addons .addon-action input[type="submit"], -.premium-addons .addon-action input[type="submit"]:visited { - background: none; - border: 0; - color: #0d72b2; - padding: 0; - font-size: inherit; - cursor: pointer; - box-shadow: 0 0 0 transparent; -} - -.premium-addons .addon-action input[type="submit"]:hover, -.premium-addons .addon-action input[type="submit"]:focus { - background: none; - border: 0; - color: #0f92e5; - padding: 0; - font-size: inherit; - box-shadow: 0 0 0 transparent; -} - -.premium-addons input[type="submit"].hide-customizer-button, -.premium-addons input[type="submit"]:visited.hide-customizer-button { - color: #a00; - font-weight: normal; -} - -.premium-addons input[type="submit"]:hover.hide-customizer-button, -.premium-addons input[type="submit"]:focus.hide-customizer-button { - color: red; - font-weight: normal; -} - -.premium-addons input[type="submit"].hide-customizer-button { - display: none; -} - -.premium-addons .add-on.activated:hover input[type="submit"].hide-customizer-button { - display: inline; -} - -.gp_premium input[name="generate_activate_all"] { - display: none; -} - -.email-container .addon-name { - width: 75%; - min-width: 150px; -} - -.license-key-container { - margin-bottom:15px; -} - -.license-key-container:last-child { - margin:0; -} - -.license-key-info { - float: right; - text-decoration: none; -} - -.license-key-container label { - font-size: 11px; - font-weight: normal; - color: #777; - display: inline-block; - margin-bottom: 0; -} - -.status { - position: absolute; - right:10px; - top:-1px; - background:rgba(255,255,255,0.9); -} - -.license-key-input { - width:100%; - box-sizing:border-box; - padding:10px; -} - -.license-key-input::-webkit-credentials-auto-fill-button { - visibility: hidden; - pointer-events: none; - position: absolute; - right: 0; -} - -.license-key-button { - position:relative; - top:1px; - width:100%; - box-sizing:border-box; - padding: 10px !important; - height:auto !important; - line-height:normal !important; -} - -.license-key-message { - font-size: 80%; - font-weight: normal; -} - -.license-key-message.receiving-updates { - color: green; -} - -.license-key-message.not-receiving-updates { - color: red; -} - -.mass-activate-select { - margin-top: 0; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/assets/dashboard.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/assets/dashboard.js deleted file mode 100644 index e789014f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/assets/dashboard.js +++ /dev/null @@ -1,48 +0,0 @@ -jQuery( function( $ ) { - $( '#generate-select-all' ).on( 'click', function() { - if ( this.checked ) { - $( '.addon-checkbox:not(:disabled)' ).each( function() { - this.checked = true; - } ); - } else { - $( '.addon-checkbox' ).each( function() { - this.checked = false; - } ); - } - } ); - - $( '#generate_license_key_gp_premium' ).on( 'input', function() { - if ( '' !== $.trim( this.value ) ) { - $( '.beta-testing-container' ).show(); - } else { - $( '.beta-testing-container' ).hide(); - } - } ); - - $( 'input[name="generate_package_hooks_deactivate_package"]' ).on( 'click', function() { - // eslint-disable-next-line no-alert - var check = confirm( dashboard.deprecated_module ); - - if ( ! check ) { - return false; - } - } ); - - $( 'input[name="generate_package_page_header_deactivate_package"]' ).on( 'click', function() { - // eslint-disable-next-line no-alert - var check = confirm( dashboard.deprecated_module ); - - if ( ! check ) { - return false; - } - } ); - - $( 'input[name="generate_package_sections_deactivate_package"]' ).on( 'click', function() { - // eslint-disable-next-line no-alert - var check = confirm( dashboard.deprecated_module ); - - if ( ! check ) { - return false; - } - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/dashboard.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/dashboard.php deleted file mode 100644 index 2ea4d584..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/dashboard.php +++ /dev/null @@ -1,47 +0,0 @@ - array( - 'name' => __( 'Modules', 'gp-premium' ), - 'url' => admin_url( 'themes.php?page=generate-options' ), - 'class' => 'appearance_page_generate-options' === $screen->id ? 'active' : '', - ), - ) ); - - // Don't print any markup if we only have one tab. - if ( count( $tabs ) === 1 ) { - return; - } - ?> -
    - %3$s', - esc_url( $tab['url'] ), - esc_attr( $tab['class'] ), - esc_html( $tab['name'] ) - ); - } - ?> -
    - -
    -

    -
    -
    -

    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -

    -

    - - '' ) ); ?> -

    -
    - -

    -
    -

    - -

    -

    - - - '' ) ); ?> -

    -
    -
    -
    - array(), - 'mods' => array(), - 'options' => array(), - ); - - foreach ( $modules as $name => $value ) { - if ( 'activated' === get_option( $value ) ) { - $data['modules'][ $name ] = $value; - } - } - - foreach ( $theme_mods as $theme_mod ) { - if ( 'generate_copyright' === $theme_mod ) { - if ( in_array( 'copyright', $_POST['module_group'] ) ) { - $data['mods'][ $theme_mod ] = get_theme_mod( $theme_mod ); - } - } else { - if ( in_array( 'generate_settings', $_POST['module_group'] ) ) { - $data['mods'][ $theme_mod ] = get_theme_mod( $theme_mod ); - } - } - } - - foreach ( $settings as $setting ) { - if ( in_array( $setting, $_POST['module_group'] ) ) { - $data['options'][ $setting ] = get_option( $setting ); - } - } - - $data = apply_filters( 'generate_export_data', $data ); - - nocache_headers(); - header( 'Content-Type: application/json; charset=utf-8' ); - header( 'Content-Disposition: attachment; filename=generate-settings-export-' . date( 'Ymd' ) . '.json' ); // phpcs:ignore -- Prefer date(). - header( 'Expires: 0' ); - - echo wp_json_encode( $data ); - exit; - } - - /** - * Import our exported file. - * - * @since 1.7 - */ - public static function import() { - if ( empty( $_POST['generate_action'] ) || 'import_settings' !== $_POST['generate_action'] ) { - return; - } - - if ( ! wp_verify_nonce( $_POST['generate_import_nonce'], 'generate_import_nonce' ) ) { - return; - } - - if ( ! current_user_can( 'manage_options' ) ) { - return; - } - - $filename = $_FILES['import_file']['name']; - $extension = end( explode( '.', $_FILES['import_file']['name'] ) ); - - if ( 'json' !== $extension ) { - wp_die( __( 'Please upload a valid .json file', 'gp-premium' ) ); - } - - $import_file = $_FILES['import_file']['tmp_name']; - - if ( empty( $import_file ) ) { - wp_die( __( 'Please upload a file to import', 'gp-premium' ) ); - } - - // Retrieve the settings from the file and convert the json object to an array. - $settings = json_decode( file_get_contents( $import_file ), true ); // phpcs:ignore -- file_get_contents() is fine here. - - foreach ( (array) $settings['modules'] as $key => $val ) { - if ( in_array( $val, self::get_modules() ) ) { - update_option( $val, 'activated' ); - } - } - - foreach ( (array) $settings['mods'] as $key => $val ) { - if ( in_array( $key, self::get_theme_mods() ) ) { - set_theme_mod( $key, $val ); - } - } - - foreach ( (array) $settings['options'] as $key => $val ) { - if ( in_array( $key, self::get_settings() ) ) { - update_option( $key, $val ); - } - } - - // Delete existing dynamic CSS cache. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - - $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $dynamic_css_data['updated_time'] ) ) { - unset( $dynamic_css_data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); - - wp_safe_redirect( admin_url( 'admin.php?page=generate-options&status=imported' ) ); - exit; - } - - /** - * List out our available modules. - * - * @since 1.7 - */ - public static function get_modules() { - return array( - 'Backgrounds' => 'generate_package_backgrounds', - 'Blog' => 'generate_package_blog', - 'Colors' => 'generate_package_colors', - 'Copyright' => 'generate_package_copyright', - 'Elements' => 'generate_package_elements', - 'Disable Elements' => 'generate_package_disable_elements', - 'Hooks' => 'generate_package_hooks', - 'Menu Plus' => 'generate_package_menu_plus', - 'Page Header' => 'generate_package_page_header', - 'Secondary Nav' => 'generate_package_secondary_nav', - 'Sections' => 'generate_package_sections', - 'Spacing' => 'generate_package_spacing', - 'Typography' => 'generate_package_typography', - 'WooCommerce' => 'generate_package_woocommerce', - ); - } - - /** - * List our our set theme mods. - * - * @since 1.7 - */ - public static function get_theme_mods() { - return array( - 'font_body_variants', - 'font_body_category', - 'font_site_title_variants', - 'font_site_title_category', - 'font_site_tagline_variants', - 'font_site_tagline_category', - 'font_navigation_variants', - 'font_navigation_category', - 'font_secondary_navigation_variants', - 'font_secondary_navigation_category', - 'font_buttons_variants', - 'font_buttons_category', - 'font_heading_1_variants', - 'font_heading_1_category', - 'font_heading_2_variants', - 'font_heading_2_category', - 'font_heading_3_variants', - 'font_heading_3_category', - 'font_heading_4_variants', - 'font_heading_4_category', - 'font_heading_5_variants', - 'font_heading_5_category', - 'font_heading_6_variants', - 'font_heading_6_category', - 'font_widget_title_variants', - 'font_widget_title_category', - 'font_footer_variants', - 'font_footer_category', - 'generate_copyright', - ); - } - - /** - * List out our available settings. - * - * @since 1.7 - */ - public static function get_settings() { - return array( - 'generate_settings', - 'generate_background_settings', - 'generate_blog_settings', - 'generate_hooks', - 'generate_page_header_settings', - 'generate_secondary_nav_settings', - 'generate_spacing_settings', - 'generate_menu_plus_settings', - 'generate_woocommerce_settings', - ); - } -} - -GeneratePress_Import_Export::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/reset.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/reset.php deleted file mode 100644 index bdcdca6f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/inc/legacy/reset.php +++ /dev/null @@ -1,273 +0,0 @@ - -
    -

    -
    -
    - -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -

    -

    - esc_js( $warning ), - 'id' => '', - ) - ); - ?> -

    -
    -
    -
    - array(), - 'options' => array(), - ); - - foreach ( $theme_mods as $theme_mod ) { - if ( 'generate_copyright' === $theme_mod ) { - if ( in_array( 'copyright', $_POST['module_group'] ) ) { - remove_theme_mod( $theme_mod ); - } - } else { - if ( in_array( 'generate_settings', $_POST['module_group'] ) ) { - remove_theme_mod( $theme_mod ); - } - } - } - - foreach ( $settings as $setting ) { - if ( in_array( $setting, $_POST['module_group'] ) ) { - delete_option( $setting ); - } - } - - // Delete our dynamic CSS option. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - - // Reset our dynamic CSS file updated time so it regenerates. - $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $dynamic_css_data['updated_time'] ) ) { - unset( $dynamic_css_data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); - - // Delete any GeneratePress Site CSS in Additional CSS. - $additional_css = wp_get_custom_css_post(); - - if ( ! empty( $additional_css ) ) { - $additional_css->post_content = preg_replace( '#(/\\* GeneratePress Site CSS \\*/).*?(/\\* End GeneratePress Site CSS \\*/)#s', '', $additional_css->post_content ); - wp_update_custom_css_post( $additional_css->post_content ); - } - - wp_safe_redirect( admin_url( 'themes.php?page=generate-options&status=reset' ) ); - exit; -} - -add_action( 'admin_head', 'generate_reset_options_css', 100 ); -/** - * Add CSS to the dashboard. - */ -function generate_reset_options_css() { - $screen = get_current_screen(); - - if ( ! is_object( $screen ) ) { - return; - } - - if ( 'appearance_page_generate-options' !== $screen->base ) { - return; - } - ?> - - base ) { - return; - } - ?> - - 1;"},"Post author name":["Nom de l'auteur de la publication"],"Post date":["Date de la publication"],"Title":["Titre"],"Dynamic text type":["Type de texte dynamique"],"Published date before text":["Texte avant la date de publication"],"Term archives":["Archives des termes"],"Author meta":["M\u00e9tadonn\u00e9es des auteurs"],"Previous page of posts":["Pr\u00e9c\u00e9dente page des publications"],"Next page of posts":["Prochaine page des publications"],"Comments area":["Zone des commentaires"],"Author archives":["Archives des auteurs"],"Single post":["Publication unique"],"Taxonomy":["Taxonomie"],"In same term":["Dans le m\u00eame terme"],"No previous post":["Pas de publication pr\u00e9c\u00e9dente"],"This will remove the current sidebar widgets for the selected sidebar. Your layout must have a sidebar set for this Element to show.":["Cela supprimera les widgets en cours pour la colonne lat\u00e9rale s\u00e9lectionn\u00e9e. Votre mise en page doit avoir des colonnes lat\u00e9rales d\u00e9finies pour que cet \u00e9l\u00e9ment soit visible."],"Site Footer":["Pied de page du site"],"None":["Aucun"],"Type":["Type"],"Right Sidebar":["Colonne lat\u00e9rale de droite"],"Left Sidebar":["Colonne lat\u00e9rale gauche"],"Priority":["Priorit\u00e9"],"Custom Hook":["Hook personnalis\u00e9"],"Custom":["Personnaliser"],"Site Header":["Ent\u00eate du site"],"Page Hero":["Banni\u00e8re"],"Hook":["Hook"],"Right":["Droite"],"Left":["Gauche"],"Center":["Centre"],"Location":["Emplacement"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR-53e2a1d5945b8d2b1c35e81ae1e532f3.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR-53e2a1d5945b8d2b1c35e81ae1e532f3.json deleted file mode 100644 index a7b5560a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR-53e2a1d5945b8d2b1c35e81ae1e532f3.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2021-03-10 11:23:17+0000","generator":"WP-CLI\/2.6.0","source":"dist\/editor.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"fr","plural-forms":"nplurals=2; plural=n > 1;"},"All Elements":["Tous les \u00e9l\u00e9ments"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR-92fa58377f1b6f7bef9c785c31ae29ff.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR-92fa58377f1b6f7bef9c785c31ae29ff.json deleted file mode 100644 index 0c595687..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR-92fa58377f1b6f7bef9c785c31ae29ff.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2021-03-10 11:23:17+0000","generator":"WP-CLI\/2.6.0","source":"dist\/site-library.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"fr","plural-forms":"nplurals=2; plural=n > 1;"},"Why?":["Pourquoi?"],"This process restores your previous options, widgets and active plugins. It will also remove your imported content and CSS.":["Cette op\u00e9ration restaure vos r\u00e9glages pr\u00e9c\u00e9dents: options, widgets et extensions actives. Cela va aussi supprimer le contenu import\u00e9 est les CSS. "],"It is highly recommended that you remove the last site you imported before importing a new one.":["Il est vraiment recommand\u00e9 de supprimer le dernier site que vous avez import\u00e9 avant d'en importer un nouveau. "],"Existing Site Import Detected":["L'importation de ce site existe d\u00e9j\u00e0"],"Restoring theme options":["Restaurer les options du th\u00e8me"],"New URL":["Nouvelle URL"],"Old URL":["Ancienne URL"],"This site is using Elementor which means you will want to replace the imported image URLs.":["Ce site utilise Elementor ce qui veut dire que vous devrez remplacer les URLs des images import\u00e9es"],"Additional Cleanup":["Nettoyage suppl\u00e9mentaire"],"This site uses the following plugins.":["Ce site utilise les plugins suivants"],"Installing plugins":["Installation de plugins..."],"Activating plugins":["Activer les plugins"],"Importing widgets":["Importation des widgets"],"Importing site options":["Importation des options du site"],"Importing content":["Importation du contenu"],"None":["Aucun"],"Import":["Importer"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR.mo deleted file mode 100644 index 09ab19f4..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-fr_FR.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-hr.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-hr.mo deleted file mode 100644 index aa6b8ca5..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-hr.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-hu_HU.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-hu_HU.mo deleted file mode 100644 index e0aa58e4..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-hu_HU.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-it_IT.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-it_IT.mo deleted file mode 100644 index f92a2b4a..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-it_IT.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nb_NO.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nb_NO.mo deleted file mode 100644 index 792e21a2..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nb_NO.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-42da344ccb044413769d16ed3484307b.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-42da344ccb044413769d16ed3484307b.json deleted file mode 100644 index cd4fea2c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-42da344ccb044413769d16ed3484307b.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-22 13:18:34+0000","generator":"WP-CLI\/2.6.0","source":"dist\/block-elements.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"nl","plural-forms":"nplurals=2; plural=n != 1;"},"Loop Template":["Loop thema"],"The taxonomy to check if in the same term.":["De taxonomie om te controleren of het om dezelfde term gaat."],"Check for posts with the same term as the current post.":["Zoek naar berichten met dezelfde term als het huidige bericht."],"Remove container condition":["Verwijder container conditie"],"Display Order":["Weergavevolgorde"],"Parent Element":["Bovenliggend element"],"First post":["Eerste bericht"],"No post meta":["Geen bericht-meta"],"No featured image":["Geen uitgelichte afbeelding"],"Keep default archive navigation container":["Behoud standaard archief navigatie container"],"Disable default pagination":["Standaard paginering uitschakelen"],"Add default archive navigation container":["Voeg standaard archief navigatie container toe"],"Disable default post navigation":["Standaard berichtnavigatie uitschakelen"],"Use the above template tag to add the current year to your footer.":["Gebruik bovenstaande template tag om het huidige jaartal aan je footer toe te voegen."],"Current year template tag":["Huidig jaartal template tag"],"Disable primary post meta":["Uitzetten primaire bericht-meta"],"Disable featured image":["Uitzetten uitgelichte afbeelding"],"Disable title":["Uitzetten titel"],"Keep default post container":["Behoud standaard berichtcontainer"],"Post meta name":["Berichtmeta-naam"],"Term name":["Termnaam"],"Posts with custom field":["Berichten met aangepast veld"],"Posts with term":["Berichten met term"],"All posts":["Alle berichten"],"Apply to":["Toepassen op"],"Tag name":["Tag-naam"],"Replace default secondary post meta":["Vervang standaard secundaire bericht-meta"],"Replace default primary post meta":["Vervang standaard primaire bericht-meta"],"Custom hook name":["Aangepaste hook naam"],"Choose your hook":["Kies je hook"],"Hook name":["Hook naam"],"Quick hook select":["Snelle hook selectie"],"Before post title":["Voor berichttitel"],"After post title":["Na bericht titel"],"This Element will replace your site footer area that holds your copyright message. It will not replace footer widgets if they exist.":["Dit element vervangt het footer gebied van je site waar het copyright bericht staat. Het vervangt niet je footer widgets als deze bestaan."],"Templates":["Templates"],"Element type":["Element type"],"Editor width":["Breedte editor"],"Install GenerateBlocks":["Installeer GenerateBlocks"],"Activate GenerateBlocks":["Activeer GenerateBlocks"],"To take full advantage of Block Elements, we suggest using our GenerateBlocks plugin.":["Om volledig gebruikt te kunnen maken Block Elements, raden we het gebruik van onze GenerateBlocks plug-in aan."],"Block Element":["Block Element"],"After content container":["Na inhoud-container"],"After content":["Na inhoud"],"Before content":["Voor inhoud"],"Before content container":["Voor inhoud-container"],"After header":["Na header"],"label\u0004Single post hero with excerpt":["Enkel bericht-hero met uittreksel"],"label\u0004Basic single post page hero":["Eenvoudige enkel bericht-hero "],"label\u0004Rounded buttons with icon":["Afgeronde knoppen met icoon"],"label\u0004Default next and previous buttons":["Standaard volgende en vorige knoppen"],"label\u0004Landscape layout":["Liggende layout"],"label\u0004Layout with offset content":["Layout met offset inhoud"],"label\u0004Basic layout with term buttons":["Eenvoudige layout met term-knoppen"],"label\u0004Full footer 2":["Volledige footer 2"],"label\u0004Full footer 1":["Volledige footer 1"],"label\u0004Term buttons":["Term-knoppen"],"label\u0004Stacked with avatar":["Gestapeld met avatar"],"label\u0004Inline with avatar":["Inline met avatar"],"label\u0004Two columns with background overlays":["Twee kolommen met achtergrond bedekking"],"label\u0004Two columns with arrows":["Twee kolommen met pijlen"],"label\u0004Two columns with featured image":["Twee kolommen met uitgelichte afbeelding"],"%s Units":["%s eenheden"],"A size unit for CSS markup\u0004Degree":["Graden"],"A size unit for CSS markup\u0004Percentage":["Percentage"],"A size unit for CSS markup\u0004Em":["Em"],"A size unit for CSS markup\u0004Pixel":["Pixel"],"Select Units":["Selecteer eenheden"],"Displays a dynamic image from your chosen source.":["Geef een dynamische afbeelding weer van je gekozen bron"],"Dynamic Image":["Dynamische afbeelding"],"Dynamic image placeholder":["Dynamische afbeelding placeholder"],"Choose your dynamic image type.":["Kies type dynamische afbeelding"],"Dynamic image":["Dynamische afbeelding"],"Make image rounded":["Maak afbeelding afgerond"],"Custom field name":["Aangepast veld-naam"],"Custom field":["Aangepast veld"],"Link to":["Link naar"],"Image height":["Afbeeldingshoogte"],"Image width":["Afbeeldingsbreedte"],"Image size":["Afbeeldingsgrootte"],"Author avatar":["Auteur avatar"],"Displays dynamic content based on your chosen source.":["Toont dynamische inhoud gebaseerd op je gekozen bron."],"Dynamic Content":["Dynamische inhoud"],"This is a placeholder for your description.":["Dit is een plaatshouder voor je beschrijving."],"Choose your dynamic content type.":["Selecteer je dynamische inhoudstype"],"Dynamic content":["Dynamische inhoud"],"Custom more link":["Aangepaste meer link"],"Use theme more link":["Gebruik thema meer link"],"Excerpt length":["Lengte uittreksel"],"Author description":["Schrijver omschrijving"],"Term description":["Term omschrijving"],"Post excerpt":["Bericht uittreksel"],"Post content":["Bericht-inhoud"],"Dynamic link type":["Dynamische link-type"],"Updated date before text":["Bijgewerkt datum voor tekst"],"Use % in place of the number of comments":["Gebruik % in de plaats van het aantal reacties"],"Plural comments text":["Meervoud reacties tekst"],"Singular comments text":["Enkelvoudige reacties tekst"],"No comments text":["Geen reacties tekst"],"Term separator":["Term scheidingsteken"],"Replace with updated date":["Vervang door bijgewerkt datum"],"Updated date":["Bijgewerkt datum"],"Date type":["Datumtype"],"Terms":["Termen"],"Hello World":["Hallo wereld"],"Comments number":["Aantal reacties"],"List of terms":["Termenlijst"],"Post author name":["Bericht auteurnaam"],"Post date":["Berichtdatum"],"Title":["Titel"],"Dynamic text type":["Dynamische tekst type"],"Published date before text":["Gepubliceerd datum voor tekst"],"Term archives":["Term archief"],"Author meta":["Auteur meta"],"Previous page of posts":["Vorige pagina van berichten"],"Next page of posts":["Volgende pagina van berichten"],"Comments area":["Reacties gebied"],"Author archives":["Auteur archieven"],"Single post":["Enkel bericht"],"Taxonomy":["Taxonomie"],"In same term":["In dezelfde term"],"No previous post":["Geen vorig bericht"],"No next post":["Geen volgend bericht"],"Space between":["Spatie tussen"],"Inline alignment":["Inline uitlijning"],"Inline post meta items":["Inline bericht meta-termen"],"Previous post":["Vorig bericht"],"Next post":["Volgend bericht"],"Current post":["huidig bericht"],"Source":["Bron"],"Post":["Bericht"],"Choose\u2026":["Selecteer..."],"Dynamic Link":["Dynamische link"],"Use fallback image":["Gebruik terugval-afbeelding"],"Meta field name":["Metaveld naam"],"Add a background image to this Container to make it dynamic.":["Voeg een achtergrond toe aan deze Container om deze dynamisch te maken."],"User meta":["Gebruiker meta"],"Term meta":["Term meta"],"Post meta":["Bericht meta"],"Featured image":["Uitgelichte afbeelding"],"Dynamic Background Image":["Dynamische achtergrond afbeelding"],"Dynamic options":["Dynamische instellingen"],"Archive Navigation":["Archief navigatie"],"Post Navigation":["Berichtnavigatie"],"Post Meta Template":["Bericht meta template"],"Content Template":["Inhoud template"],"% Comments":["% reacties"],"1 Comment":["1 reactie"],"No Comments":["Geen reacties"],"This is a placeholder for your content.":["Dit is een plaatshouder voor je inhoud."],"This will remove the current sidebar widgets for the selected sidebar. Your layout must have a sidebar set for this Element to show.":["Dit verwijdert de huidige zijbalkwidgets voor de geselecteerde zijbalk. Je lay-out moet een zijbalk hebben om dit Element te laten zien."],"Site Footer":["Site footer"],"None":["Geen"],"Type":["Type"],"Right Sidebar":["Rechter zijbalk"],"Left Sidebar":["Linker zijbalk"],"Priority":["Prioriteit"],"Custom Hook":["Aangepaste hook"],"Custom":["Aangepast"],"Site Header":["Site header"],"Page Hero":["Page Hero"],"Hook":["Hook"],"Right":["Rechts"],"Left":["Links"],"Center":["Midden"],"Location":["Locatie"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-53e2a1d5945b8d2b1c35e81ae1e532f3.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-53e2a1d5945b8d2b1c35e81ae1e532f3.json deleted file mode 100644 index bd23357a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-53e2a1d5945b8d2b1c35e81ae1e532f3.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-22 13:18:34+0000","generator":"WP-CLI\/2.6.0","source":"dist\/editor.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"nl","plural-forms":"nplurals=2; plural=n != 1;"},"Active Elements":["Actieve elementen"],"All Elements":["Alle elementen"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-92fa58377f1b6f7bef9c785c31ae29ff.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-92fa58377f1b6f7bef9c785c31ae29ff.json deleted file mode 100644 index 0cc8e32a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-92fa58377f1b6f7bef9c785c31ae29ff.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-22 13:18:34+0000","generator":"WP-CLI\/2.6.0","source":"dist\/site-library.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"nl","plural-forms":"nplurals=2; plural=n != 1;"},"Requires GeneratePress %s.":["Vereist GeneratePress %s."],"Built by":["Gebouwd door"],"Note: We do our best to ensure all imported images are licensed for open use. However, image licenses can change, so we strongly advise that you replace all imported images with your own.":["Opmerking: we doen ons best om ervoor te zorgen dat alle ge\u00efmporteerde afbeeldingen vrij gebruikt mogen worden. Afbeeldingslicenties kunnen echter veranderen, dus we raden je ten zeerste aan om alle ge\u00efmporteerde afbeeldingen te vervangen door je eigen afbeeldingen."],"Check out your new site and start making it yours!":["Bekijk je nieuwe site en geef het jouw unieke stijl!"],"Learn more here":["Leer hier meer"],"To disable it, find WP_DEBUG in your wp-config.php file and set it to false like the below.":["Zoek - om het uit te schakelen - naar WP_DEBUG in je wp-config.php-bestand en stel het in op false zoals hieronder."],"WordPress debug mode is currently enabled. With this, any errors from third-party plugins might affect the import process.":["De foutopsporingsmodus van WordPress is momenteel ingeschakeld. Hierdoor kunnen eventuele fouten van plug-ins van derden het importproces be\u00efnvloeden."],"Debug Mode Enabled":["Foutopsporingsmodus ingeschakeld"],"Preview mobile":["Voorbeeld mobiel"],"Preview tablet":["Voorbeeld tablet"],"Preview desktop":["Voorbeeld desktop"],"Elementor Tools":["Elementor Tools"],"Take note of the old and new URLs below, then head over to the Elementor Tools area to replace them.":["Noteer de oude en nieuwe URL's hieronder en ga naar het Elementor Tools-gebied om ze te vervangen."],"Begin Import":["Begin importeren"],"I understand":["Ik begrijp het"],"Confirm Import":["Bevestig importeren"],"Import Demo Content":["Importeer demo inhoud"],"This will install and activate needed plugins, import demo content, and import site options.":["Dit installeert en activeert de benodigde plug-ins, importeert de demo-inhoud en importeert site-instellingen."],"Import Theme Options":["Importeer thema-instellingen"],"This will import the options from the Customizer.":["Dit importeert de instellingen van de Customizer."],"These plugins need to be installed manually.":["Deze plug-ins moeten handmatig worden ge\u00efnstalleerd."],"These plugins are already installed.":["Deze plug-ins zijn al ge\u00efnstalleerd."],"These plugins can be installed automatically.":["Deze plug-ins kunnen automatisch worden ge\u00efnstalleerd."],"Gathering information":["Informatie aan het verzamelen."],"Refresh sites":["Vernieuw sites"],"Requires GP Premium %s.":["Vereist GP Premium %s."],"Page Builder":["Pagina bouwer"],"Category":["Categorie"],"No thanks":["Nee bedankt"],"Remove imported site":["Verwijder ge\u00efmporteerde site"],"This process makes changes to your website. If it contains important data, we suggest backing it up before proceeding.":["Dit proces maakt veranderingen aan je website. Als deze belangrijke data bevat, raden we aan om deze te back-uppen."],"Try again":["Nogmaals proberen"],"No sites were found.":["Geen sites gevonden."],"Restoring content":["Terugzetten inhoud"],"Installing %s":["%s wordt ge\u00efnstalleerd"],"Import Complete":["Import compleet"],"Importing theme options":["Thema-instellingen worden ge\u00efmporteerd"],"Why?":["Waarom?"],"This process restores your previous options, widgets and active plugins. It will also remove your imported content and CSS.":["Deze procedure zet de vorige instellingen, widgets, en actieve plugins terug. Het verwijdert ook de ge\u00efmporteerde inhoud en CSS."],"It is highly recommended that you remove the last site you imported before importing a new one.":["Het is aanbevolen dat je de laatste site verwijdert die je hebt ge\u00efmporteerd voordat je een nieuwe importeert."],"Existing Site Import Detected":["Bestaande site import gevonden"],"Restoring theme options":["Terugzetten thema-instellingen"],"New URL":["Nieuwe URL"],"Old URL":["Oude URL"],"This site is using Elementor which means you will want to replace the imported image URLs.":["Deze site maakt gebruik van Elementor, wat betekent dat je de ge\u00efmporteerde afbeeldings-URLs moet aanpassen."],"Additional Cleanup":["Extra opruimen"],"This site uses the following plugins.":["Deze site maakt gebruik van de volgende plugins:"],"All":["Alles"],"View Site":["Bekijk site"],"Get Started":["Nu beginnen"],"Plugins":["Plugins"],"Installing plugins":["Plugins aan het installeren"],"Activating plugins":["Plugins aan het activeren"],"Importing widgets":["Widgets aan het importeren"],"Importing site options":["Site-instellingen aan het importeren"],"Importing content":["Inhoud aan het importeren"],"None":["Geen"],"Import":["Importeren"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-cbab080b0f20fd6c323029398be6c986.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-cbab080b0f20fd6c323029398be6c986.json deleted file mode 100644 index 2c6bc645..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-cbab080b0f20fd6c323029398be6c986.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-22 13:18:34+0000","generator":"WP-CLI\/2.6.0","source":"dist\/dashboard.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"nl","plural-forms":"nplurals=2; plural=n != 1;"},"This will delete all of your customizer settings. It cannot be undone.":["Dit zal al je customizer instellingen verwijderen. Het kan niet ongedaan worden gemaakt."],"Reset your customizer settings.":["Reset je customizer instellingen."],"Options imported.":["Opties ge\u00efmporteerd."],"This can overwrite existing settings and cannot be undone.":["Dit kan bestaande instellingen overschrijven en kan niet ongedaan worden gemaakt."],"Import your customizer settings.":["Importeer je customizer instellingen."],"Global Colors":["Globale kleuren"],"Export your customizer settings.":["Exporteer je customizer instellingen."],"Import \/ Export":["Importeren \/ exporteren"],"License key deactivated.":["Licentiesleutel gedeactiveerd."],"License key activated.":["Licentiesleutel geactiveerd."],"Get alpha and beta updates directly to your Dashboard.":["Ontvang alpha en beta updates direct in je Dashboard."],"Enter your license key to activate updates.":["Voer je licentiesleutel in om updates te activeren."],"Not receiving premium updates.":["Geen premium updates ontvangen."],"Receiving premium updates.":["Premium-updates ontvangen."],"Options exported":["Opties ge\u00ebxporteerd"],"This will delete all settings for this module. It cannot be undone.":["Hiermee worden alle instellingen voor deze module verwijderd. Dit kan niet ongedaan worden gemaakt."],"Open tools for this module.":["Open gereedschap voor deze module."],"Open Elements":["Open elementen"],"Open Site Library":["Open site bibliotheek"],"Settings reset.":["Instellingen gereset."],"Typography":["Typografie"],"All":["Alles"],"Reset":["Terugzetten"],"Modules":["Modules"],"License Key":["Licentiecode"],"Deactivate":["Deactiveren"],"Activate":["Activeren"],"This module has been deprecated. Deactivating it will remove it from this list.":["Deze module is verouderd. Als u deze deactiveert, wordt deze uit deze lijst verwijderd."],"Import":["Importeren"],"Export":["Exporteren"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-ecf9f3c2af10c4f2dfbf4f42504922d1.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-ecf9f3c2af10c4f2dfbf4f42504922d1.json deleted file mode 100644 index 69729ba2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL-ecf9f3c2af10c4f2dfbf4f42504922d1.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-22 13:18:34+0000","generator":"WP-CLI\/2.6.0","source":"dist\/customizer.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"nl","plural-forms":"nplurals=2; plural=n != 1;"},"Related\/Upsell Product Titles":["Gerelateerde\/opwaarderende producttitels"],"Catalog Product Titles":["Catalogus product titels"],"Off-Canvas Sub-Menu Items":["Off-canvas submenu items"],"Off-Canvas Menu Items":["Off-canvas menu items"],"Secondary Mobile Menu Toggle":["Secundair mobiel menu toggle"],"Secondary Sub-Menu Items":["Secundaire submenu items"],"Secondary Menu Items":["Secundaire menu-items"],"Off-Canvas Panel":["Off-canvas paneel"],"WooCommerce":["WooCommerce"],"Secondary Navigation":["Secundaire navigatie"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL.mo deleted file mode 100644 index d13ab9e4..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-nl_NL.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pl_PL.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pl_PL.mo deleted file mode 100644 index 06c623d9..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pl_PL.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_BR.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_BR.mo deleted file mode 100644 index e453013e..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_BR.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-42da344ccb044413769d16ed3484307b.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-42da344ccb044413769d16ed3484307b.json deleted file mode 100644 index 101c7110..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-42da344ccb044413769d16ed3484307b.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2020-08-08 21:16:06+0000","generator":"WP-CLI\/2.6.0","source":"dist\/block-elements.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"pt","plural-forms":"nplurals=2; plural=n != 1;"},"Site Footer":["Rodap\u00e9 do site"],"None":["Nenhuma"],"Type":["Tipo"],"Right Sidebar":["Barra lateral direita"],"Left Sidebar":["Barra lateral esquerda"],"Priority":["Prioridade"],"Custom Hook":["Hook personalizado"],"Custom":["Personalizado"],"Site Header":["Cabe\u00e7alho do site"],"Page Hero":["Hero de p\u00e1gina"],"Hook":["Hook"],"Right":["Direita"],"Left":["Esquerda"],"Center":["Centro"],"Location":["Localiza\u00e7\u00e3o"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-53e2a1d5945b8d2b1c35e81ae1e532f3.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-53e2a1d5945b8d2b1c35e81ae1e532f3.json deleted file mode 100644 index 4fc6aaba..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-53e2a1d5945b8d2b1c35e81ae1e532f3.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2020-08-08 21:16:06+0000","generator":"WP-CLI\/2.6.0","source":"dist\/editor.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"pt","plural-forms":"nplurals=2; plural=n != 1;"},"All Elements":["Todos os elementos"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-92fa58377f1b6f7bef9c785c31ae29ff.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-92fa58377f1b6f7bef9c785c31ae29ff.json deleted file mode 100644 index d60c4950..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT-92fa58377f1b6f7bef9c785c31ae29ff.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2020-08-08 21:16:06+0000","generator":"WP-CLI\/2.6.0","source":"dist\/site-library.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"pt","plural-forms":"nplurals=2; plural=n != 1;"},"Why?":["Porqu\u00ea?"],"This process restores your previous options, widgets and active plugins. It will also remove your imported content and CSS.":["Este processo recupera as suas op\u00e7\u00f5es, widgets e plugins activos anteriores. Tamb\u00e9m ir\u00e1 remover o seu conte\u00fado importado e CSS."],"It is highly recommended that you remove the last site you imported before importing a new one.":["\u00c9 altamente recomendado que remova o site importado anteriormente antes de importar um novo."],"Existing Site Import Detected":["Detectado um site importado existente"],"Restoring theme options":["A recuperar op\u00e7\u00f5es do tema"],"New URL":["URL novo"],"Old URL":["URL antigo"],"This site is using Elementor which means you will want to replace the imported image URLs.":["Este site utiliza o Elementor, isto significa que dever\u00e1 substituir os URL das imagens importadas."],"Additional Cleanup":["Limpeza adicional"],"This site uses the following plugins.":["Este site utiliza os seguintes plugins."],"All":["Todos"],"View Site":["Ver site"],"Get Started":["Come\u00e7ar"],"Plugins":["Plugins"],"Installing plugins":["A instalar plugins"],"Activating plugins":["A activar plugins"],"Importing widgets":["A importar widgets"],"Importing site options":["A importar op\u00e7\u00f5es do site"],"Importing content":["A importar conte\u00fados"],"None":["Nenhuma"],"Import":["Importar"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT.mo deleted file mode 100644 index 53b4c446..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-pt_PT.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-42da344ccb044413769d16ed3484307b.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-42da344ccb044413769d16ed3484307b.json deleted file mode 100644 index ff9ec0df..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-42da344ccb044413769d16ed3484307b.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2023-11-08 16:38:58+0000","generator":"WP-CLI\/2.6.0","source":"dist\/block-elements.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"ru","plural-forms":"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"},"Loop Template":["\u0428\u0430\u0431\u043b\u043e\u043d \u0446\u0438\u043a\u043b\u0430"],"The taxonomy to check if in the same term.":["\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0442\u0430\u043a\u0441\u043e\u043d\u043e\u043c\u0438\u044e \u0435\u0441\u043b\u0438 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0439 \u0442\u0435\u0440\u043c\u0438\u043d."],"Check for posts with the same term as the current post.":["\u041f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0437\u0430\u043f\u0438\u0441\u0438 \u0441 \u0442\u0430\u043a\u0438\u043c \u0436\u0435 \u0438\u043c\u0435\u043d\u0435\u043c \u043a\u0430\u043a \u0442\u0435\u043a\u0443\u0449\u0430\u044f \u0437\u0430\u043f\u0438\u0441\u044c."],"Remove container condition":["\u0423\u0434\u0430\u043b\u0438\u0442\u044c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430"],"Display Order":["\u041e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442\u044c \u0417\u0430\u043a\u0430\u0437"],"Parent Element":["\u0420\u043e\u0434\u0438\u0442\u0435\u043b\u044c\u0441\u043a\u0438\u0439 \u044d\u043b\u0435\u043c\u0435\u043d\u0442"],"First post":["\u041f\u0435\u0440\u0432\u0430\u044f \u0437\u0430\u043f\u0438\u0441\u044c"],"No post meta":["\u041d\u0435\u0442 \u043c\u0435\u0442\u0430-\u0434\u0430\u043d\u043d\u044b\u0445 \u0437\u0430\u043f\u0438\u0441\u0438"],"No featured image":["\u041d\u0435\u0442 \u0438\u0437\u0431\u0440\u0430\u043d\u043d\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f"],"Keep default archive navigation container":["\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438 \u0430\u0440\u0445\u0438\u0432\u0430 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Disable default pagination":["\u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043f\u0430\u0433\u0438\u043d\u0430\u0446\u0438\u044e \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Add default archive navigation container":["\u0414\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u0438 \u043f\u043e \u0430\u0440\u0445\u0438\u0432\u0443 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Disable default post navigation":["\u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044e \u043f\u043e \u0437\u0430\u043f\u0438\u0441\u044f\u043c \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Use the above template tag to add the current year to your footer.":["\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u043d\u043d\u044b\u0439 \u0432\u044b\u0448\u0435 \u0442\u0435\u0433 \u0448\u0430\u0431\u043b\u043e\u043d\u0430, \u0447\u0442\u043e\u0431\u044b \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0442\u0435\u043a\u0443\u0449\u0438\u0439 \u0433\u043e\u0434 \u0432 \u043f\u043e\u0434\u0432\u0430\u043b"],"Current year template tag":["\u0422\u0435\u0433 \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u0433\u043e\u0434\u0430"],"Disable primary post meta":["\u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u043c\u0435\u0442\u0430-\u0434\u0430\u043d\u043d\u044b\u0435 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438"],"Disable featured image":["\u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u043f\u0438\u0441\u0438"],"Disable title":["\u041e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a"],"Keep default post container":["\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u0437\u0430\u043f\u0438\u0441\u0438 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Post meta name":["\u041c\u0435\u0442\u0430-\u0438\u043c\u044f \u0437\u0430\u043f\u0438\u0441\u0438"],"Term name":["\u041d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u0442\u0435\u0440\u043c\u0438\u043d\u0430"],"Posts with custom field":["\u0417\u0430\u043f\u0438\u0441\u0438 \u0441 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u043b\u044c\u043d\u044b\u043c \u043f\u043e\u043b\u0435\u043c"],"Posts with term":["\u0417\u0430\u043f\u0438\u0441\u0438 \u0441 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043c\u0438"],"All posts":["\u0412\u0441\u0435 \u0437\u0430\u043f\u0438\u0441\u0438"],"Apply to":["\u041f\u0440\u0438\u043c\u0435\u043d\u0438\u0442\u044c \u043a"],"Tag name":["\u0418\u043c\u044f \u0442\u0435\u0433\u0430"],"Replace default secondary post meta":["\u0417\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u043c\u0435\u0442\u0443 \u0432\u0442\u043e\u0440\u0438\u0447\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Replace default primary post meta":["\u0417\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u043c\u0435\u0442\u0430 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"Custom hook name":["\u0418\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u0445\u0443\u043a\u0430"],"Choose your hook":["\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0441\u0432\u043e\u0439 \u0445\u0443\u043a"],"Hook name":["\u0418\u043c\u044f \u0445\u0443\u043a\u0430"],"Quick hook select":["\u0411\u044b\u0441\u0442\u0440\u044b\u0439 \u0432\u044b\u0431\u043e\u0440 \u0445\u0443\u043a\u0430"],"Before post title":["\u041f\u0435\u0440\u0435\u0434 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u043e\u043c \u0437\u0430\u043f\u0438\u0441\u0438"],"After post title":["\u041f\u043e\u0441\u043b\u0435 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0430 \u0437\u0430\u043f\u0438\u0441\u0438"],"This Element will replace your site footer area that holds your copyright message. It will not replace footer widgets if they exist.":["\u042d\u0442\u043e\u0442 \u044d\u043b\u0435\u043c\u0435\u043d\u0442 \u0437\u0430\u043c\u0435\u043d\u0438\u0442 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u043f\u043e\u0434\u0432\u0430\u043b\u0430 \u0432\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430, \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u0449\u0438\u0439 \u0432\u0430\u0448\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u043e\u0431 \u0430\u0432\u0442\u043e\u0440\u0441\u043a\u0438\u0445 \u043f\u0440\u0430\u0432\u0430\u0445. \u041e\u043d \u043d\u0435 \u0437\u0430\u043c\u0435\u043d\u0438\u0442 \u0432\u0438\u0434\u0436\u0435\u0442\u044b \u043f\u043e\u0434\u0432\u0430\u043b\u0430, \u0435\u0441\u043b\u0438 \u043e\u043d\u0438 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0442."],"Templates":["\u0428\u0430\u0431\u043b\u043e\u043d\u044b\u0439"],"Element type":["\u0422\u0438\u043f \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430"],"Editor width":["\u0428\u0438\u0440\u0438\u043d\u0430 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0430"],"Install GenerateBlocks":["\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c GenerateBlocks"],"Activate GenerateBlocks":["\u0410\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c GenerateBlocks"],"To take full advantage of Block Elements, we suggest using our GenerateBlocks plugin.":["\u0427\u0442\u043e\u0431\u044b \u0432 \u043f\u043e\u043b\u043d\u043e\u0439 \u043c\u0435\u0440\u0435 \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u0430\u043c\u0438 \u0431\u043b\u043e\u0447\u043d\u044b\u0445 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432, \u043c\u044b \u043f\u0440\u0435\u0434\u043b\u0430\u0433\u0430\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0430\u0448 \u043f\u043b\u0430\u0433\u0438\u043d GenerateBlocks."],"Block Element":["\u042d\u043b\u0435\u043c\u0435\u043d\u0442 \u0411\u043b\u043e\u043a\u0430"],"After content container":["\u041f\u043e\u0441\u043b\u0435 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430"],"After content":["\u041f\u043e\u0441\u043b\u0435 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430"],"Before content":["\u041f\u0435\u0440\u0435\u0434 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u043e\u043c"],"Before content container":["\u041f\u0435\u0440\u0435\u0434 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u043c \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430"],"After header":["\u041f\u043e\u0441\u043b\u0435 \u0448\u0430\u043f\u043a\u0438"],"label\u0004Single post hero with excerpt":["Hero \u043e\u0434\u0438\u043d\u043e\u0447\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u0438 \u0441 \u043e\u0442\u0440\u044b\u0432\u043a\u0430\u043c\u0438"],"label\u0004Basic single post page hero":["Hero \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0441 \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u043e\u0439 \u0437\u0430\u043f\u0438\u0441\u044c\u044e"],"label\u0004Rounded buttons with icon":["\u041e\u043a\u0440\u0443\u0433\u043b\u044b\u0435 \u043a\u043d\u043e\u043f\u043a\u0438 \u0441\u043e \u0437\u043d\u0430\u0447\u043a\u043e\u043c"],"label\u0004Default next and previous buttons":["\u041a\u043d\u043e\u043f\u043a\u0438 \u00ab\u0414\u0430\u043b\u0435\u0435\u00bb \u0438 \u00ab\u041d\u0430\u0437\u0430\u0434\u00bb \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e"],"label\u0004Landscape layout":["\u0410\u043b\u044c\u0431\u043e\u043c\u043d\u0430\u044f \u043e\u0440\u0438\u0435\u043d\u0442\u0430\u0446\u0438\u044f"],"label\u0004Layout with offset content":["\u041c\u0430\u043a\u0435\u0442 \u0441\u043e \u0441\u043c\u0435\u0449\u0435\u043d\u043d\u044b\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u044b\u043c"],"label\u0004Basic layout with term buttons":["\u0411\u0430\u0437\u043e\u0432\u044b\u0439 \u043c\u0430\u043a\u0435\u0442 \u0441 \u043a\u043d\u043e\u043f\u043a\u0430\u043c\u0438 \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u0432"],"label\u0004Full footer 2":["\u041f\u043e\u043b\u043d\u044b\u0439 \u043f\u043e\u0434\u0432\u0430\u043b 2"],"label\u0004Full footer 1":["\u041f\u043e\u043b\u043d\u044b\u0439 \u043f\u043e\u0434\u0432\u0430\u043b 1"],"label\u0004Term buttons":["\u041a\u043d\u043e\u043f\u043a\u0438 \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u0432"],"label\u0004Stacked with avatar":["\u0421\u043b\u043e\u0436\u0435\u043d\u044b \u0441 \u0430\u0432\u0430\u0442\u0430\u0440\u043e\u043c"],"label\u0004Inline with avatar":["\u041d\u0430 \u043b\u0438\u043d\u0438\u0438 \u0441 \u0430\u0432\u0430\u0442\u0430\u0440\u043e\u043c"],"label\u0004Two columns with background overlays":["\u0414\u0432\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438 \u0441 \u0444\u043e\u043d\u043e\u0432\u044b\u043c\u0438 \u043d\u0430\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c\u0438"],"label\u0004Two columns with arrows":["\u0414\u0432\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438 \u0441\u043e \u0441\u0442\u0440\u0435\u043b\u043a\u0430\u043c\u0438"],"label\u0004Two columns with featured image":["\u0414\u0432\u0435 \u043a\u043e\u043b\u043e\u043d\u043a\u0438 \u0441 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435\u043c \u0437\u0430\u043f\u0438\u0441\u0438"],"%s Units":["% \u0435\u0434\u0438\u043d\u0438\u0446"],"A size unit for CSS markup\u0004Degree":["\u0421\u0442\u0435\u043f\u0435\u043d\u044c"],"A size unit for CSS markup\u0004Percentage":["\u041f\u0440\u043e\u0446\u0435\u043d\u0442"],"A size unit for CSS markup\u0004Em":["\u0420\u0430\u0437\u043c\u0435\u0440"],"A size unit for CSS markup\u0004Pixel":["\u041f\u0438\u043a\u0441\u0435\u043b\u044c"],"Select Units":["\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0435\u0434\u0438\u043d\u0438\u0446\u044b"],"Displays a dynamic image from your chosen source.":["\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0438\u0437 \u0432\u044b\u0431\u0440\u0430\u043d\u043d\u043e\u0433\u043e \u0432\u0430\u043c\u0438 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430."],"Dynamic Image":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435"],"Dynamic image placeholder":["\u043f\u043e\u043b\u0435 \u0434\u043b\u044f \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f"],"Choose your dynamic image type.":["\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0442\u0438\u043f \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f."],"Dynamic image":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435"],"Make image rounded":["\u0421\u0434\u0435\u043b\u0430\u0442\u044c \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u043a\u0440\u0443\u0433\u043b\u0435\u043d\u043d\u044b\u043c"],"Custom field name":["\u0418\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0433\u043e \u043f\u043e\u043b\u044f"],"Custom field":["\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u043e\u0435 \u043f\u043e\u043b\u0435"],"Link to":["\u0421\u0441\u044b\u043b\u043a\u0430 \u043d\u0430"],"Image height":["\u0412\u044b\u0441\u043e\u0442\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f"],"Image width":["\u0428\u0438\u0440\u0438\u043d\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f"],"Image size":["\u0420\u0430\u0437\u043c\u0435\u0440 \u043a\u0430\u0440\u0442\u0438\u043d\u043a\u0438"],"Author avatar":["\u0410\u0432\u0430\u0442\u0430\u0440 \u0430\u0432\u0442\u043e\u0440\u0430"],"Displays dynamic content based on your chosen source.":["\u041e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u0442 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 \u0432\u044b\u0431\u0440\u0430\u043d\u043d\u043e\u0433\u043e \u0432\u0430\u043c\u0438 \u0438\u0441\u0442\u043e\u0447\u043d\u0438\u043a\u0430."],"Dynamic Content":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442"],"This is a placeholder for your description.":["\u042d\u0442\u043e \u043f\u043e\u043b\u0435 \u0434\u043b\u044f \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044f"],"Choose your dynamic content type.":["\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435 \u0442\u0438\u043f \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430."],"Dynamic content":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442"],"Custom more link":["\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0441\u0441\u044b\u043b\u043a\u0430 \u0435\u0449\u0435"],"Use theme more link":["\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0441\u0441\u044b\u043b\u043a\u0443 \u0435\u0449\u0435 \u0442\u0435\u043c\u044b"],"Excerpt length":["\u0414\u043b\u0438\u043d\u0430 \u043e\u0442\u0440\u044b\u0432\u043a\u0430"],"Author description":["\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0430\u0432\u0442\u043e\u0440\u0430 "],"Term description":["\u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0442\u0435\u0440\u043c\u0438\u043d\u0430"],"Post excerpt":["\u041e\u0442\u0440\u044b\u0432\u043e\u043a \u0437\u0430\u043f\u0438\u0441\u0438"],"Post content":["\u0421\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0437\u0430\u043f\u0438\u0441\u0438"],"Dynamic link type":["\u0422\u0438\u043f \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0439 \u0441\u0441\u044b\u043b\u043a\u0438"],"Updated date before text":["\u0414\u0430\u0442\u0430 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u043a\u0441\u0442\u043e\u043c"],"Use % in place of the number of comments":["\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435 % \u0432\u043c\u0435\u0441\u0442\u043e \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432"],"Plural comments text":["\u0422\u0435\u043a\u0441\u0442 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432 \u0432\u043e \u043c\u043d\u043e\u0436\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e\u043c \u0447\u0438\u0441\u043b\u0435"],"Singular comments text":["\u0422\u0435\u043a\u0441\u0442 \u0435\u0434\u0438\u043d\u0438\u0447\u043d\u044b\u0445 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432"],"No comments text":["\u0422\u0435\u043a\u0441\u0442 \u0431\u0435\u0437 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432"],"Term separator":["\u0420\u0430\u0437\u0434\u0435\u043b\u0438\u0442\u0435\u043b\u044c \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u0432"],"Replace with updated date":["\u0417\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u043e\u0439 \u0434\u0430\u0442\u043e\u0439"],"Updated date":["\u0414\u0430\u0442\u0430 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f"],"Date type":["\u0422\u0438\u043f \u0434\u0430\u0442\u044b"],"Terms":["\u0422\u0435\u0440\u043c\u0438\u043d\u044b"],"Hello World":["\u041f\u0440\u0438\u0432\u0435\u0442, \u043c\u0438\u0440"],"Comments number":["\u041a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432"],"List of terms":["\u0421\u043f\u0438\u0441\u043e\u043a \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u0432"],"Post author name":["\u0418\u043c\u044f \u0430\u0432\u0442\u043e\u0440\u0430 \u0437\u0430\u043f\u0438\u0441\u0438"],"Post date":["\u0414\u0430\u0442\u0430 \u0437\u0430\u043f\u0438\u0441\u0438"],"Title":["\u0417\u0430\u0433\u043e\u043b\u043e\u0432\u043e\u043a"],"Dynamic text type":["\u0422\u0438\u043f \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0433\u043e \u0442\u0435\u043a\u0441\u0442\u0430"],"Published date before text":["\u0414\u0430\u0442\u0430 \u043f\u0443\u0431\u043b\u0438\u043a\u0430\u0446\u0438\u0438 \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u043a\u0441\u0442\u043e\u043c"],"Term archives":["\u0410\u0440\u0445\u0438\u0432\u044b \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u0432"],"Author meta":["\u041c\u0435\u0442\u0430 \u0430\u0432\u0442\u043e\u0440\u0430"],"Previous page of posts":["\u041f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0437\u0430\u043f\u0438\u0441\u0435\u0439"],"Next page of posts":["\u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0437\u0430\u043f\u0438\u0441\u0435\u0439"],"Comments area":["\u041e\u0431\u043b\u0430\u0441\u0442\u044c \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432"],"Author archives":["\u0410\u0440\u0445\u0438\u0432\u044b \u0430\u0432\u0442\u043e\u0440\u0430"],"Single post":["\u0415\u0434\u0438\u043d\u0438\u0447\u043d\u0430\u044f \u0437\u0430\u043f\u0438\u0441\u044c"],"Taxonomy":["\u0422\u0430\u043a\u0441\u043e\u043d\u043e\u043c\u0438\u044f"],"In same term":["\u0422\u0435\u043c \u0436\u0435 \u0442\u0435\u0440\u043c\u0438\u043d\u043e\u043c"],"No previous post":["\u041d\u0435\u0442 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u0439 \u0437\u0430\u043f\u0438\u0441\u0438"],"No next post":["\u041d\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0435\u0439 \u0437\u0430\u043f\u0438\u0441\u0438"],"Space between":["\u041f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u043e \u043c\u0435\u0436\u0434\u0443"],"Inline alignment":["\u041b\u0438\u043d\u0435\u0439\u043d\u043e\u0435 \u0432\u044b\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u043d\u0438\u0435"],"Inline post meta items":["\u041c\u0435\u0442\u0430\u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b \u043b\u0438\u043d\u0435\u0439\u043d\u044b\u0445 \u0437\u0430\u043f\u0438\u0441\u0435\u0439"],"Previous post":["\u041f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0430\u044f \u0437\u0430\u043f\u0438\u0441\u044c"],"Next post":["\u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f \u0437\u0430\u043f\u0438\u0441\u044c"],"Current post":["\u0422\u0435\u043a\u0443\u0449\u0430\u044f \u0437\u0430\u043f\u0438\u0441\u044c"],"Source":["\u0418\u0441\u0442\u043e\u0447\u043d\u0438\u043a"],"Post":["\u0417\u0430\u043f\u0438\u0441\u044c"],"Choose\u2026":["\u0412\u044b\u0431\u0435\u0440\u0438\u0442\u0435..."],"Dynamic Link":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0430\u044f \u0441\u0441\u044b\u043b\u043a\u0430"],"Use fallback image":["\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435"],"Meta field name":["\u0418\u043c\u044f \u043c\u0435\u0442\u0430\u043f\u043e\u043b\u044f"],"Add a background image to this Container to make it dynamic.":["\u0414\u043e\u0431\u0430\u0432\u044c\u0442\u0435 \u0444\u043e\u043d\u043e\u0432\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0432 \u044d\u0442\u043e\u0442 \u041a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440, \u0447\u0442\u043e\u0431\u044b \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0435\u0433\u043e \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u043d\u044b\u043c."],"User meta":["\u041c\u0435\u0442\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f"],"Term meta":["\u0422\u0435\u0440\u043c\u0438\u043d \u043c\u0435\u0442\u0430"],"Post meta":["\u041c\u0435\u0442\u0430 \u0437\u0430\u043f\u0438\u0441\u0438"],"Featured image":["\u0418\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u0437\u0430\u043f\u0438\u0441\u0438"],"Dynamic Background Image":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u043e\u0435 \u0444\u043e\u043d\u043e\u0432\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435"],"Dynamic options":["\u0414\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b"],"Archive Navigation":["\u041d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044f \u043f\u043e \u0430\u0440\u0445\u0438\u0432\u0443"],"Post Navigation":["\u041d\u0430\u0432\u0438\u0433\u0430\u0446\u0438\u044f \u043f\u043e \u0437\u0430\u043f\u0438\u0441\u044f\u043c"],"Post Meta Template":["\u041c\u0435\u0442\u0430 \u0448\u0430\u0431\u043b\u043e\u043d \u0437\u0430\u043f\u0438\u0441\u0438"],"Content Template":["\u0428\u0430\u0431\u043b\u043e\u043d \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430"],"% Comments":["% \u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0438"],"1 Comment":["1 \u041a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0439"],"No Comments":["\u041d\u0435\u0442 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u0435\u0432"],"This is a placeholder for your content.":["\u042d\u0442\u043e \u043f\u043e\u043b\u0435 \u0434\u043b\u044f \u0437\u0430\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e. "],"This will remove the current sidebar widgets for the selected sidebar. Your layout must have a sidebar set for this Element to show.":["\u042d\u0442\u043e \u0443\u0434\u0430\u043b\u0438\u0442 \u0442\u0435\u043a\u0443\u0449\u0438\u0435 \u0432\u0438\u0434\u0436\u0435\u0442\u044b \u0441\u0430\u0439\u0434\u0431\u0430\u0440\u0430 \u0434\u043b\u044f \u0432\u044b\u0431\u0440\u0430\u043d\u043d\u043e\u0433\u043e \u0441\u0430\u0439\u0434\u0431\u0430\u0440\u0430. \u0412 \u0432\u0430\u0448\u0435\u043c \u043c\u0430\u043a\u0435\u0442\u0435 \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d \u0441\u0430\u0439\u0434\u0431\u0430\u0440 \u0434\u043b\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u044d\u0442\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430."],"Site Footer":["\u041f\u043e\u0434\u0432\u0430\u043b \u0441\u0430\u0439\u0442\u0430"],"None":["\u041e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u0435\u0442"],"Type":["\u0422\u0438\u043f"],"Right Sidebar":["\u0412 \u043f\u0440\u0430\u0432\u043e\u043c \u0431\u043e\u043a\u043e\u0432\u0438\u043a\u0435"],"Left Sidebar":["\u0412 \u043b\u0435\u0432\u043e\u043c \u0431\u043e\u043a\u043e\u0432\u0438\u043a\u0435"],"Priority":["\u041f\u0440\u0438\u043e\u0440\u0438\u0442\u0435\u0442"],"Custom Hook":["\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u0438\u0439 \u0445\u0443\u043a"],"Custom":["\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u0441\u043a\u0438\u0439"],"Site Header":["\u0428\u0430\u043f\u043a\u0430 \u0441\u0430\u0439\u0442\u0430"],"Page Hero":["Hero \u0421\u0442\u0440\u0430\u043d\u0438\u0446\u0430"],"Hook":["\u0425\u0443\u043a"],"Right":["\u0421\u043f\u0440\u0430\u0432\u0430"],"Left":["\u0421\u043b\u0435\u0432\u0430"],"Center":["\u041f\u043e \u0446\u0435\u043d\u0442\u0440\u0443"],"Location":["\u0420\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0438\u0435"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-53e2a1d5945b8d2b1c35e81ae1e532f3.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-53e2a1d5945b8d2b1c35e81ae1e532f3.json deleted file mode 100644 index 31dfd244..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-53e2a1d5945b8d2b1c35e81ae1e532f3.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2023-11-08 16:38:58+0000","generator":"WP-CLI\/2.6.0","source":"dist\/editor.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"ru","plural-forms":"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"},"Active Elements":["\u0410\u043a\u0442\u0438\u0432\u043d\u044b\u0435 \u042d\u0435\u043c\u0435\u043d\u0442\u044b"],"All Elements":["\u0412\u0441\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-92fa58377f1b6f7bef9c785c31ae29ff.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-92fa58377f1b6f7bef9c785c31ae29ff.json deleted file mode 100644 index 3b4bd9e2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-92fa58377f1b6f7bef9c785c31ae29ff.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2023-11-08 16:38:58+0000","generator":"WP-CLI\/2.6.0","source":"dist\/site-library.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"ru","plural-forms":"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"},"Requires GeneratePress %s.":["\u0422\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f GeneratePress %s."],"Built by":["\u0421\u043e\u0437\u0434\u0430\u043d\u043e"],"Note: We do our best to ensure all imported images are licensed for open use. However, image licenses can change, so we strongly advise that you replace all imported images with your own.":["\u041f\u0440\u0438\u043c\u0435\u0447\u0430\u043d\u0438\u0435. \u041c\u044b \u0434\u0435\u043b\u0430\u0435\u043c \u0432\u0441\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0435, \u0447\u0442\u043e\u0431\u044b \u0432\u0441\u0435 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0431\u044b\u043b\u0438 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u044b \u0434\u043b\u044f \u043e\u0442\u043a\u0440\u044b\u0442\u043e\u0433\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f. \u041e\u0434\u043d\u0430\u043a\u043e \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u0438 \u043d\u0430 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u043c\u043e\u0433\u0443\u0442 \u043c\u0435\u043d\u044f\u0442\u044c\u0441\u044f, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043c\u044b \u043d\u0430\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0432\u0430\u043c \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0432\u0441\u0435 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0441\u0432\u043e\u0438\u043c\u0438 \u0441\u043e\u0431\u0441\u0442\u0432\u0435\u043d\u043d\u044b\u043c\u0438."],"Check out your new site and start making it yours!":["\u041f\u0440\u043e\u0432\u0435\u0440\u044c\u0442\u0435 \u0441\u0432\u043e\u0439 \u043d\u043e\u0432\u044b\u0439 \u0441\u0430\u0439\u0442 \u0438 \u043d\u0430\u0447\u043d\u0438\u0442\u0435 \u0434\u0435\u043b\u0430\u0442\u044c \u0435\u0433\u043e \u0441\u0432\u043e\u0438\u043c!"],"Learn more here":["\u0423\u0437\u043d\u0430\u0439\u0442\u0435 \u0431\u043e\u043b\u044c\u0448\u0435 \u0437\u0434\u0435\u0441\u044c"],"To disable it, find WP_DEBUG in your wp-config.php file and set it to false like the below.":["\u0427\u0442\u043e\u0431\u044b \u043e\u0442\u043a\u043b\u044e\u0447\u0438\u0442\u044c, \u043d\u0430\u0439\u0434\u0438\u0442\u0435 WP_DEBUG \u0432 \u0444\u0430\u0439\u043b\u0435 wp-config.php \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u0435 \u0434\u043b\u044f \u043d\u0435\u0433\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 false, \u043a\u0430\u043a \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u043e \u043d\u0438\u0436\u0435."],"WordPress debug mode is currently enabled. With this, any errors from third-party plugins might affect the import process.":["\u0412 \u043d\u0430\u0441\u0442\u043e\u044f\u0449\u0435\u0435 \u0432\u0440\u0435\u043c\u044f \u0432\u043a\u043b\u044e\u0447\u0435\u043d \u0440\u0435\u0436\u0438\u043c \u043e\u0442\u043b\u0430\u0434\u043a\u0438 WordPress. \u041f\u0440\u0438 \u044d\u0442\u043e\u043c \u043b\u044e\u0431\u044b\u0435 \u043e\u0448\u0438\u0431\u043a\u0438 \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u0445 \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432 \u043c\u043e\u0433\u0443\u0442 \u043f\u043e\u0432\u043b\u0438\u044f\u0442\u044c \u043d\u0430 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0438\u043c\u043f\u043e\u0440\u0442\u0430."],"Debug Mode Enabled":["\u0412\u043a\u043b\u044e\u0447\u0435\u043d \u0440\u0435\u0436\u0438\u043c \u043e\u0442\u043b\u0430\u0434\u043a\u0438"],"Preview mobile":["\u041f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u043d\u0430 \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u044b\u0445 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432\u0430\u0445"],"Preview tablet":["\u041f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u043f\u043b\u0430\u043d\u0448\u0435\u0442\u0430"],"Preview desktop":["\u041f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0439 \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u0440\u0430\u0431\u043e\u0447\u0435\u0433\u043e \u0441\u0442\u043e\u043b\u0430"],"Elementor Tools":["\u0418\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b Elementor"],"Take note of the old and new URLs below, then head over to the Elementor Tools area to replace them.":["\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u043d\u0430 \u0441\u0442\u0430\u0440\u044b\u0439 \u0438 \u043d\u043e\u0432\u044b\u0439 URL-\u0430\u0434\u0440\u0435\u0441\u0430 \u043d\u0438\u0436\u0435, \u0437\u0430\u0442\u0435\u043c \u043f\u0435\u0440\u0435\u0439\u0434\u0438\u0442\u0435 \u0432 \u043e\u0431\u043b\u0430\u0441\u0442\u044c \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u043e\u0432 Elementor, \u0447\u0442\u043e\u0431\u044b \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u0438\u0445."],"Begin Import":["\u041d\u0430\u0447\u0430\u0442\u044c \u0438\u043c\u043f\u043e\u0440\u0442"],"I understand":["\u042f \u043f\u043e\u043d\u0438\u043c\u0430\u044e"],"Confirm Import":["\u041f\u043e\u0434\u0442\u0432\u0435\u0440\u0434\u0438\u0442\u044c \u0438\u043c\u043f\u043e\u0440\u0442"],"Import Demo Content":["\u0418\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442"],"This will install and activate needed plugins, import demo content, and import site options.":["\u042d\u0442\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u0438\u0442 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0438 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u043f\u043b\u0430\u0433\u0438\u043d\u044b, \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0434\u0435\u043c\u043e\u043d\u0441\u0442\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442 \u0438 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0441\u0430\u0439\u0442\u0430."],"Import Theme Options":["\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0438\u043c\u043f\u043e\u0440\u0442\u0430 \u0442\u0435\u043c\u044b "],"This will import the options from the Customizer.":["\u0418\u043c\u043f\u043e\u0440\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0438\u0437 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u0449\u0438\u043a\u0430."],"These plugins need to be installed manually.":["\u042d\u0442\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u044b \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0432\u0440\u0443\u0447\u043d\u0443\u044e."],"These plugins are already installed.":["\u042d\u0442\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u044b \u0443\u0436\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u044b."],"These plugins can be installed automatically.":["\u042d\u0442\u0438 \u043f\u043b\u0430\u0433\u0438\u043d\u044b \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u044b \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438."],"Gathering information":["\u041f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0441\u0431\u043e\u0440 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438. "],"Refresh sites":["\u041e\u0431\u043d\u043e\u0432\u0438\u0442\u0435 \u0441\u0430\u0439\u0442\u044b"],"Requires GP Premium %s.":["\u0422\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0439 \u043f\u043b\u0430\u0433\u0438\u043d GP Premium %s."],"Page Builder":["\u041a\u043e\u043d\u0441\u0442\u0440\u0443\u043a\u0442\u043e\u0440 \u0441\u0442\u0440\u0430\u043d\u0438\u0446"],"Category":["\u041a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u044f"],"No thanks":["\u041d\u0435\u0442, \u0441\u043f\u0430\u0441\u0438\u0431\u043e"],"Remove imported site":["\u0423\u0434\u0430\u043b\u0438\u0442\u044c \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0441\u0430\u0439\u0442"],"This process makes changes to your website. If it contains important data, we suggest backing it up before proceeding.":["\u042d\u0442\u043e\u0442 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0432\u043d\u043e\u0441\u0438\u0442 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432 \u0432\u0430\u0448 \u0441\u0430\u0439\u0442. \u0415\u0441\u043b\u0438 \u043e\u043d \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u0442 \u0432\u0430\u0436\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435, \u043c\u044b \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u043c \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0440\u0435\u0437\u0435\u0440\u0432\u043d\u0443\u044e \u043a\u043e\u043f\u0438\u044e, \u043f\u0440\u0435\u0436\u0434\u0435 \u0447\u0435\u043c \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0438\u0442\u044c."],"Try again":["\u041f\u043e\u043f\u0440\u043e\u0431\u0443\u0439 \u0435\u0449\u0435 \u0440\u0430\u0437"],"No sites were found.":["\u0421\u0430\u0439\u0442\u043e\u0432 \u043d\u0435 \u043d\u0430\u0439\u0434\u0435\u043d\u043e."],"Restoring content":["\u0412\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e"],"Installing %s":["\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 %s"],"Import Complete":["\u0418\u043c\u043f\u043e\u0440\u0442 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d"],"Importing theme options":["\u0418\u043c\u043f\u043e\u0440\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0442\u0435\u043c\u044b"],"Why?":["\u041f\u043e\u0447\u0435\u043c\u0443?"],"This process restores your previous options, widgets and active plugins. It will also remove your imported content and CSS.":["\u042d\u0442\u043e\u0442 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u0432\u0430\u0448\u0438 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b, \u0432\u0438\u0434\u0436\u0435\u0442\u044b \u0438 \u0430\u043a\u0442\u0438\u0432\u043d\u044b\u0435 \u043f\u043b\u0430\u0433\u0438\u043d\u044b. \u041e\u043d \u0442\u0430\u043a\u0436\u0435 \u0443\u0434\u0430\u043b\u0438\u0442 \u0432\u0430\u0448 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442 \u0438 CSS."],"It is highly recommended that you remove the last site you imported before importing a new one.":["\u041d\u0430\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u043f\u043e\u0441\u043b\u0435\u0434\u043d\u0438\u0439 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0441\u0430\u0439\u0442 \u043f\u0435\u0440\u0435\u0434 \u0438\u043c\u043f\u043e\u0440\u0442\u043e\u043c \u043d\u043e\u0432\u043e\u0433\u043e."],"Existing Site Import Detected":["\u041e\u0431\u043d\u0430\u0440\u0443\u0436\u0435\u043d \u0438\u043c\u043f\u043e\u0440\u0442 \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430"],"Restoring theme options":["\u0412\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u0442\u0435\u043c\u044b"],"New URL":["\u041d\u043e\u0432\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 URL"],"Old URL":["\u0421\u0442\u0430\u0440\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 URL"],"This site is using Elementor which means you will want to replace the imported image URLs.":["\u042d\u0442\u043e\u0442 \u0441\u0430\u0439\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 Elementor, \u0447\u0442\u043e \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e \u0412\u0430\u043c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0431\u0443\u0434\u0435\u0442 \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c URL-\u0430\u0434\u0440\u0435\u0441\u0430 \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0439."],"Additional Cleanup":["\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043e\u0447\u0438\u0441\u0442\u043a\u0430"],"This site uses the following plugins.":["\u042d\u0442\u043e\u0442 \u0441\u0430\u0439\u0442 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0435 \u043f\u043b\u0430\u0433\u0438\u043d\u044b."],"All":["\u0412\u0441\u0435"],"View Site":["\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0441\u0430\u0439\u0442"],"Get Started":["\u041d\u0430\u0447\u0430\u0442\u044c"],"Plugins":["\u041f\u043b\u0430\u0433\u0438\u043d\u044b"],"Installing plugins":["\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432"],"Activating plugins":["\u0410\u043a\u0442\u0438\u0432\u0430\u0446\u0438\u044f \u043f\u043b\u0430\u0433\u0438\u043d\u043e\u0432"],"Importing widgets":["\u0418\u043c\u043f\u043e\u0440\u0442 \u0432\u0438\u0434\u0436\u0435\u0442\u043e\u0432"],"Importing site options":["\u0418\u043c\u043f\u043e\u0440\u0442 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u0441\u0430\u0439\u0442\u0430"],"Importing content":["\u0418\u043c\u043f\u043e\u0440\u0442 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u0430"],"None":["\u041e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u0435\u0442"],"Import":["\u0418\u043c\u043f\u043e\u0440\u0442"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-cbab080b0f20fd6c323029398be6c986.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-cbab080b0f20fd6c323029398be6c986.json deleted file mode 100644 index c12a39a7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-cbab080b0f20fd6c323029398be6c986.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2023-11-08 16:38:58+0000","generator":"WP-CLI\/2.6.0","source":"dist\/dashboard.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"ru","plural-forms":"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"},"This will delete all of your customizer settings. It cannot be undone.":["\u042d\u0442\u043e \u0443\u0434\u0430\u043b\u0438\u0442 \u0432\u0441\u0435 \u0432\u0430\u0448\u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u0430\u0441\u0442\u043e\u043c\u0430\u0439\u0437\u0435\u0440\u0430. \u042d\u0442\u043e \u043d\u0435 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043e\u0442\u043c\u0435\u043d\u0435\u043d\u043e."],"Reset your customizer settings.":["\u0421\u0431\u0440\u043e\u0441\u044c\u0442\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u0430\u0441\u0442\u043e\u043c\u0430\u0439\u0437\u0435\u0440\u0430."],"Options imported.":["\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u0438\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u044b."],"This can overwrite existing settings and cannot be undone.":["\u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0438 \u043d\u0435 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043e\u0442\u043c\u0435\u043d\u0435\u043d\u043e."],"Import your customizer settings.":["\u0418\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0439\u0442\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u041a\u0430\u0441\u0442\u043e\u043c\u0430\u0439\u0437\u0435\u0440\u0430."],"Global Colors":["\u0413\u043b\u043e\u0431\u0430\u043b\u044c\u043d\u044b\u0435 \u0446\u0432\u0435\u0442\u0430"],"Export your customizer settings.":["\u042d\u043a\u0441\u043f\u043e\u0440\u0442 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u043a\u0430\u0441\u0442\u043e\u043c\u0430\u0439\u0437\u0435\u0440\u0430."],"Import \/ Export":["\u0418\u043c\u043f\u043e\u0440\u0442 \/ \u042d\u043a\u0441\u043f\u043e\u0440\u0442"],"License key deactivated.":["\u041b\u0438\u0446\u0435\u043d\u0437\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 \u0434\u0435\u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d."],"License key activated.":["\u041b\u0438\u0446\u0435\u043d\u0437\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043b\u044e\u0447 \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u043d."],"Get alpha and beta updates directly to your Dashboard.":["\u041f\u043e\u043b\u0443\u0447\u0430\u0439\u0442\u0435 \u0430\u043b\u044c\u0444\u0430- \u0438 \u0431\u0435\u0442\u0430-\u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u044f\u043c\u043e \u043d\u0430 \u041a\u043e\u043d\u0441\u043e\u043b\u0438."],"Enter your license key to activate updates.":["\u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u043b\u0438\u0446\u0435\u043d\u0437\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043b\u044e\u0447, \u0447\u0442\u043e\u0431\u044b \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f."],"Not receiving premium updates.":["\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043f\u0440\u0435\u043c\u0438\u0443\u043c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0439 \u043e\u0442\u043a\u043b\u044e\u0447\u0435\u043d\u043e."],"Receiving premium updates.":["\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u043f\u0440\u0435\u043c\u0438\u0443\u043c \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0439 \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u043e."],"Options exported":["\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u044b \u044d\u043a\u0441\u043f\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u044b"],"This will delete all settings for this module. It cannot be undone.":["\u042d\u0442\u043e \u043f\u0440\u0438\u0432\u0435\u0434\u0435\u0442 \u043a \u0443\u0434\u0430\u043b\u0435\u043d\u0438\u044e \u0432\u0441\u0435\u0445 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043c\u043e\u0434\u0443\u043b\u044f. \u042d\u0442\u043e \u043d\u0435 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043e\u0442\u043c\u0435\u043d\u0435\u043d\u043e."],"Open tools for this module.":["\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043c\u043e\u0434\u0443\u043b\u044f."],"Open Elements":["\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u042d\u043b\u0435\u043c\u0435\u043d\u0442\u044b"],"Open Site Library":["\u041e\u0442\u043a\u0440\u044b\u0442\u044c \u0411\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 \u0421\u0430\u0439\u0442\u043e\u0432"],"Settings reset.":["\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0441\u0431\u0440\u043e\u0448\u0435\u043d\u044b"],"Typography":["\u0422\u0438\u043f\u043e\u0433\u0440\u0430\u0444\u0438\u043a\u0430"],"All":["\u0412\u0441\u0435"],"Reset":["\u0421\u0431\u0440\u043e\u0441"],"Modules":["\u041c\u043e\u0434\u0443\u043b\u0438"],"License Key":["\u041b\u0438\u0446\u0435\u043d\u0437\u0438\u043e\u043d\u043d\u044b\u0439 \u043a\u043b\u044e\u0447"],"Deactivate":["\u0414\u0435\u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c"],"Activate":["\u0410\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c"],"This module has been deprecated. Deactivating it will remove it from this list.":["\u042d\u0442\u043e\u0442 \u043c\u043e\u0434\u0443\u043b\u044c \u0443\u0441\u0442\u0430\u0440\u0435\u043b. \u0414\u0435\u0430\u043a\u0442\u0438\u0432\u0430\u0446\u0438\u044f \u0443\u0434\u0430\u043b\u0438\u0442 \u0435\u0433\u043e \u0438\u0437 \u044d\u0442\u043e\u0433\u043e \u0441\u043f\u0438\u0441\u043a\u0430."],"Import":["\u0418\u043c\u043f\u043e\u0440\u0442"],"Export":["\u042d\u043a\u0441\u043f\u043e\u0440\u0442"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-ecf9f3c2af10c4f2dfbf4f42504922d1.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-ecf9f3c2af10c4f2dfbf4f42504922d1.json deleted file mode 100644 index 37e7b72a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU-ecf9f3c2af10c4f2dfbf4f42504922d1.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2023-11-08 16:38:58+0000","generator":"WP-CLI\/2.6.0","source":"dist\/customizer.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"ru","plural-forms":"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"},"Related\/Upsell Product Titles":["\u041d\u0430\u0437\u0432\u0430\u043d\u0438\u0435 \u043f\u043e\u0445\u043e\u0436\u0438\u0445\/\u0430\u043f\u0441\u0435\u043b\u043b \u0442\u043e\u0432\u0430\u0440\u043e\u0432"],"Catalog Product Titles":["\u041d\u0430\u0437\u0432\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u043e\u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430"],"Off-Canvas Sub-Menu Items":["\u041f\u0443\u043d\u043a\u0442\u044b \u043f\u043e\u0434\u043c\u0435\u043d\u044e Off-Canvas"],"Off-Canvas Menu Items":["\u041f\u0443\u043d\u043a\u0442\u044b \u043c\u0435\u043d\u044e Off-Canvas"],"Secondary Mobile Menu Toggle":["\u041f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u0442\u0435\u043b\u044c \u0432\u0442\u043e\u0440\u0438\u0447\u043d\u043e\u0433\u043e \u043c\u043e\u0431\u0438\u043b\u044c\u043d\u043e\u0433\u043e \u043c\u0435\u043d\u044e"],"Secondary Sub-Menu Items":["\u041f\u0443\u043d\u043a\u0442\u044b \u0432\u0442\u043e\u0440\u0438\u0447\u043d\u043e\u0433\u043e \u043f\u043e\u0434\u043c\u0435\u043d\u044e"],"Secondary Menu Items":["\u041f\u0443\u043d\u043a\u0442\u044b \u0432\u0442\u043e\u0440\u0438\u0447\u043d\u043e\u0433\u043e \u043c\u0435\u043d\u044e"],"Off-Canvas Panel":["\u041f\u0430\u043d\u0435\u043b\u044c Off-Canvas"],"WooCommerce":["WooCommerce"],"Secondary Navigation":["\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u043c\u0435\u043d\u044e"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU.mo deleted file mode 100644 index dd9262e2..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-ru_RU.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-42da344ccb044413769d16ed3484307b.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-42da344ccb044413769d16ed3484307b.json deleted file mode 100644 index 58f573c2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-42da344ccb044413769d16ed3484307b.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-01 13:13:24+0000","generator":"WP-CLI\/2.6.0","source":"dist\/block-elements.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"sv_SE","plural-forms":"nplurals=2; plural=n != 1;"},"Loop Template":[""],"The taxonomy to check if in the same term.":[""],"Check for posts with the same term as the current post.":["Kolla efter inl\u00e4gg med samma term som det nuvarande inl\u00e4gget."],"Remove container condition":["Ta bort beh\u00e5llarens villkor"],"Display Order":[""],"Parent Element":["\u00d6verordnat element"],"First post":["F\u00f6rsta inl\u00e4gg"],"No post meta":[""],"No featured image":["Ingen utvald bild"],"Keep default archive navigation container":[""],"Disable default pagination":[""],"Add default archive navigation container":[""],"Disable default post navigation":[""],"Use the above template tag to add the current year to your footer.":[""],"Current year template tag":[""],"Disable primary post meta":["Inaktivera prim\u00e4r metadata f\u00f6r inl\u00e4gg"],"Disable featured image":["Inaktivera utvald bild"],"Disable title":["Inaktivera rubrik"],"Keep default post container":[""],"Post meta name":["Namn f\u00f6r metadata f\u00f6r inl\u00e4gg"],"Term name":["Termnamn"],"Posts with custom field":["Inl\u00e4gg med anpassat f\u00e4lt"],"Posts with term":["Inl\u00e4gg med term"],"All posts":["Alla inl\u00e4gg"],"Apply to":["Till\u00e4mpa p\u00e5"],"Tag name":["Etikettnamn"],"Replace default secondary post meta":[""],"Replace default primary post meta":[""],"Custom hook name":["V\u00e4lj namn f\u00f6r \u00e5tg\u00e4rds-hook"],"Choose your hook":["V\u00e4lj din \u00e5tg\u00e4rds-hook"],"Hook name":["Namn p\u00e5 \u00e5tg\u00e4rds-hook"],"Quick hook select":[""],"Before post title":["F\u00f6re inl\u00e4ggsrubrik"],"After post title":["Efter inl\u00e4ggsrubrik"],"This Element will replace your site footer area that holds your copyright message. It will not replace footer widgets if they exist.":["Detta element kommer att ers\u00e4tta ditt sidfotomr\u00e5de som inneh\u00e5ller ditt upphovsr\u00e4ttsmeddelande. Det ers\u00e4tter inte sidfotens widgetar om det finns."],"Templates":["Mallar"],"Element type":["Elementtyp"],"Editor width":["Redigeringsbredd"],"Install GenerateBlocks":["Installera GenerateBlocks"],"Activate GenerateBlocks":["Aktivera GenerateBlocks"],"To take full advantage of Block Elements, we suggest using our GenerateBlocks plugin.":["F\u00f6r att dra full nytta av Block Elements f\u00f6resl\u00e5r vi att du anv\u00e4nder v\u00e5rt till\u00e4gg GenerateBlocks."],"Block Element":["Block Element"],"After content container":["Efter inneh\u00e5llsbeh\u00e5llare"],"After content":["Efter inneh\u00e5ll"],"Before content":["F\u00f6re inneh\u00e5ll"],"Before content container":["F\u00f6re inneh\u00e5llsbeh\u00e5llare"],"After header":[""],"label\u0004Single post hero with excerpt":[""],"label\u0004Basic single post page hero":[""],"label\u0004Rounded buttons with icon":["Rundade knappar med ikon"],"label\u0004Default next and previous buttons":["Standardknappar f\u00f6r n\u00e4sta och f\u00f6reg\u00e5ende"],"label\u0004Landscape layout":["Liggande layout"],"label\u0004Layout with offset content":["Layout med f\u00f6rskjutet inneh\u00e5ll"],"label\u0004Basic layout with term buttons":[""],"label\u0004Full footer 2":["Hel sidfot 2"],"label\u0004Full footer 1":["Hel sidfot 1"],"label\u0004Term buttons":[""],"label\u0004Stacked with avatar":["Staplad med profilbild"],"label\u0004Inline with avatar":[""],"label\u0004Two columns with background overlays":["2 kolumner med bakgrund\u00f6verl\u00e4gg"],"label\u0004Two columns with arrows":["Tv\u00e5 kolumner med pilar"],"label\u0004Two columns with featured image":["Tv\u00e5 kolumner med utvald bild"],"%s Units":[""],"A size unit for CSS markup\u0004Degree":["Grad"],"A size unit for CSS markup\u0004Percentage":["Procentsats"],"A size unit for CSS markup\u0004Em":["Em"],"A size unit for CSS markup\u0004Pixel":["Pixel"],"Select Units":["V\u00e4lj enheter"],"Displays a dynamic image from your chosen source.":["Visar en dynamisk bild fr\u00e5n din valda k\u00e4lla."],"Dynamic Image":["Dynamisk bild"],"Dynamic image placeholder":["Platsh\u00e5llare f\u00f6r dynamisk bild"],"Choose your dynamic image type.":["V\u00e4lj din dynamiska bildtyp."],"Dynamic image":["Dynamisk bild"],"Make image rounded":["G\u00f6r bild rundad"],"Custom field name":["Anpassat f\u00e4ltnamn"],"Custom field":["Anpassat f\u00e4lt"],"Link to":["L\u00e4nk till"],"Image height":["Bildh\u00f6jd"],"Image width":["Bildbredd"],"Image size":["Bildstorlek"],"Author avatar":["Profilbild f\u00f6r f\u00f6rfattare"],"Displays dynamic content based on your chosen source.":["Visar dynamiskt inneh\u00e5ll baserat p\u00e5 din valda k\u00e4lla."],"Dynamic Content":["Dynamiskt inneh\u00e5ll"],"This is a placeholder for your description.":["Detta \u00e4r en platsh\u00e5llare f\u00f6r din beskrivning."],"Choose your dynamic content type.":["V\u00e4lj din dynamiska inneh\u00e5llstyp."],"Dynamic content":["Dynamiskt inneh\u00e5ll"],"Custom more link":["Anpassad l\u00e4nk f\u00f6r \u201dMer\u201d"],"Use theme more link":["Anv\u00e4nd temats l\u00e4nk f\u00f6r \u201dMer\u201d"],"Excerpt length":["Utdragsl\u00e4ngd"],"Author description":["F\u00f6rfattarbeskrivning"],"Term description":["Termbeskrivning"],"Post excerpt":["Inl\u00e4ggsutdrag"],"Post content":["Inl\u00e4ggsinneh\u00e5ll"],"Dynamic link type":["Dynamisk l\u00e4nktyp"],"Updated date before text":["Uppdateringsdatum f\u00f6re text"],"Use % in place of the number of comments":["Anv\u00e4nd % i st\u00e4llet f\u00f6r antalet kommentarer"],"Plural comments text":["Kommentarstext i plural"],"Singular comments text":["Kommentarstext i singular"],"No comments text":["Text f\u00f6r \u201dInga kommentarer\u201d"],"Term separator":[""],"Replace with updated date":["Ers\u00e4tt med uppdateringsdatum"],"Updated date":["Uppdateringsdatum"],"Date type":["Datumtyp"],"Terms":["Termer"],"Hello World":["Hej v\u00e4rlden"],"Comments number":["Antal kommentarer"],"List of terms":["Lista \u00f6ver termer"],"Post author name":["Inl\u00e4ggsf\u00f6rfattarens namn"],"Post date":["Publiceringsdatum"],"Title":["Rubrik"],"Dynamic text type":["Dynamisk texttyp"],"Published date before text":["Publiceringsdatum f\u00f6re text"],"Term archives":["Termarkiv"],"Author meta":["Meta f\u00f6r f\u00f6rfattare"],"Previous page of posts":["F\u00f6reg\u00e5ende sida med inl\u00e4gg"],"Next page of posts":["N\u00e4sta sida med inl\u00e4gg"],"Comments area":["Kommentaromr\u00e5de"],"Author archives":["F\u00f6rfattararkiv"],"Single post":["Enskilt inl\u00e4gg"],"Taxonomy":["Taxonomi"],"In same term":["I samma term"],"No previous post":["Inget f\u00f6reg\u00e5ende inl\u00e4gg"],"No next post":["Inget n\u00e4sta inl\u00e4gg"],"Space between":["Avst\u00e5nd mellan"],"Inline alignment":[""],"Inline post meta items":[""],"Previous post":["F\u00f6reg\u00e5ende inl\u00e4gg"],"Next post":["N\u00e4sta inl\u00e4gg"],"Current post":["Nuvarande inl\u00e4gg"],"Source":["K\u00e4lla"],"Post":["Inl\u00e4gg"],"Choose\u2026":["V\u00e4lj \u2026"],"Dynamic Link":["Dynamisk l\u00e4nk"],"Use fallback image":["Anv\u00e4nd reservbild"],"Meta field name":[""],"Add a background image to this Container to make it dynamic.":["L\u00e4gg till en bakgrundsbild i denna beh\u00e5llare f\u00f6r att g\u00f6ra den dynamisk."],"User meta":["Anv\u00e4ndarmeta"],"Term meta":[""],"Post meta":["Metadata f\u00f6r inl\u00e4gg"],"Featured image":["Utvald bild"],"Dynamic Background Image":["Dynamisk bakgrundsbild"],"Dynamic options":["Dynamiska alternativ"],"Archive Navigation":["Arkivnavigering"],"Post Navigation":["Inl\u00e4ggsnavigering"],"Post Meta Template":[""],"Content Template":["Inneh\u00e5llsmall"],"% Comments":["% kommentarer"],"1 Comment":["1 kommentar"],"No Comments":["Inga kommentarer"],"This is a placeholder for your content.":["Detta \u00e4r en platsh\u00e5llare f\u00f6r ditt inneh\u00e5ll."],"This will remove the current sidebar widgets for the selected sidebar. Your layout must have a sidebar set for this Element to show.":["Detta kommer ta bort nuvarande widgetar i sidopanelen f\u00f6r den valda sidopanelen. Din layout m\u00e5ste ha en sidopanel f\u00f6r att detta element ska visas."],"Site Footer":["Webbplatsens sidfot"],"None":["Ingen"],"Type":["Typ"],"Right Sidebar":["H\u00f6ger sidopanel"],"Left Sidebar":["V\u00e4nster sidopanel"],"Priority":["Prioritet"],"Custom Hook":["Anpassad \u00e5tg\u00e4rds-hook"],"Custom":["Anpassad"],"Site Header":["Webbplatsens sidhuvud"],"Page Hero":[""],"Hook":["\u00c5tg\u00e4rds-hook"],"Right":["H\u00f6ger"],"Left":["V\u00e4nster"],"Center":["Centrerat"],"Location":["Plats"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-53e2a1d5945b8d2b1c35e81ae1e532f3.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-53e2a1d5945b8d2b1c35e81ae1e532f3.json deleted file mode 100644 index 5b924ae9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-53e2a1d5945b8d2b1c35e81ae1e532f3.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-01 13:13:24+0000","generator":"WP-CLI\/2.6.0","source":"dist\/editor.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"sv_SE","plural-forms":"nplurals=2; plural=n != 1;"},"Active Elements":["Aktiva element"],"All Elements":["Alla element"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-92fa58377f1b6f7bef9c785c31ae29ff.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-92fa58377f1b6f7bef9c785c31ae29ff.json deleted file mode 100644 index b2ff7285..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-92fa58377f1b6f7bef9c785c31ae29ff.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-01 13:13:24+0000","generator":"WP-CLI\/2.6.0","source":"dist\/site-library.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"sv_SE","plural-forms":"nplurals=2; plural=n != 1;"},"Requires GeneratePress %s.":["Kr\u00e4ver GeneratePress %s."],"Built by":["Byggd med"],"Note: We do our best to ensure all imported images are licensed for open use. However, image licenses can change, so we strongly advise that you replace all imported images with your own.":[""],"Check out your new site and start making it yours!":["Kolla in din nya webbplats och b\u00f6rja g\u00f6ra den till din egen!"],"Learn more here":["L\u00e4r dig mer h\u00e4r"],"To disable it, find WP_DEBUG in your wp-config.php file and set it to false like the below.":["F\u00f6r att inaktivera den, hitta WP_DEBUG i din wp-config.php-fil och st\u00e4ll in den p\u00e5 falsk som nedan."],"WordPress debug mode is currently enabled. With this, any errors from third-party plugins might affect the import process.":["WordPress fels\u00f6kningsl\u00e4ge \u00e4r f\u00f6r n\u00e4rvarande aktiverat. Med detta kan eventuella fel fr\u00e5n till\u00e4gg fr\u00e5n tredje part p\u00e5verka importprocessen."],"Debug Mode Enabled":["Fels\u00f6kningsl\u00e4ge aktiverat"],"Preview mobile":["F\u00f6rhandsgranska mobil"],"Preview tablet":["F\u00f6rhandsgranska surfplatta"],"Preview desktop":["F\u00f6rhandsgranska station\u00e4r dator"],"Elementor Tools":["Elementor-verktyg"],"Take note of the old and new URLs below, then head over to the Elementor Tools area to replace them.":[""],"Begin Import":["Starta import"],"I understand":["Jag f\u00f6rst\u00e5r"],"Confirm Import":["Bekr\u00e4fta import"],"Import Demo Content":["Importera demoinneh\u00e5ll"],"This will install and activate needed plugins, import demo content, and import site options.":["Detta kommer att installera och aktivera n\u00f6dv\u00e4ndiga till\u00e4gg, importera demo-inneh\u00e5ll och importera webbplatsalternativ."],"Import Theme Options":["Importera temaalternativ"],"This will import the options from the Customizer.":["Detta importerar alternativen fr\u00e5n anpassaren."],"These plugins need to be installed manually.":["Dessa till\u00e4gg m\u00e5ste installeras manuellt."],"These plugins are already installed.":["Dessa till\u00e4gg \u00e4r redan installerade."],"These plugins can be installed automatically.":["Dessa till\u00e4gg kan installeras automatiskt."],"Gathering information":["Samlar information"],"Refresh sites":["Uppdatera webbplatser"],"Requires GP Premium %s.":["Kr\u00e4ver GP Premium %s."],"Page Builder":["Sidbyggare"],"Category":["Kategori"],"No thanks":["Nej tack"],"Remove imported site":["Ta bort importerad webbplats"],"This process makes changes to your website. If it contains important data, we suggest backing it up before proceeding.":["Denna process g\u00f6r \u00e4ndringar p\u00e5 din webbplats. Om den inneh\u00e5ller viktiga data f\u00f6resl\u00e5r vi att du s\u00e4kerhetskopierar den innan du forts\u00e4tter."],"Try again":["F\u00f6rs\u00f6k igen"],"No sites were found.":["Inga webbplatser hittades."],"Restoring content":["\u00c5terst\u00e4ller inneh\u00e5ll"],"Installing %s":["Installerar %s"],"Import Complete":["Import slutf\u00f6rd"],"Importing theme options":["Importerar temaalternativ"],"Why?":["Varf\u00f6r?"],"This process restores your previous options, widgets and active plugins. It will also remove your imported content and CSS.":["Denna process \u00e5terst\u00e4ller dina f\u00f6reg\u00e5ende alternativ, widgetar och aktiva till\u00e4gg. Det tar ocks\u00e5 bort ditt importerade inneh\u00e5ll och CSS."],"It is highly recommended that you remove the last site you imported before importing a new one.":["Det rekommenderas starkt att du tar bort den senaste webbplatsen du importerade innan du importerar en ny."],"Existing Site Import Detected":["Befintlig webbplatsimport uppt\u00e4ckt"],"Restoring theme options":["\u00c5terst\u00e4ller temalternativ"],"New URL":["Ny URL"],"Old URL":["Gammal URL"],"This site is using Elementor which means you will want to replace the imported image URLs.":["Denna webbplats anv\u00e4nder Elementor vilket inneb\u00e4r att du beh\u00f6ver ers\u00e4tta de importerade bild-URL:erna."],"Additional Cleanup":["Ytterligare upprensning"],"This site uses the following plugins.":["Denna webbplats anv\u00e4nder f\u00f6ljande till\u00e4gg."],"All":["Alla"],"View Site":["Visa webbplats"],"Get Started":["Komma ig\u00e5ng"],"Plugins":["Till\u00e4gg"],"Installing plugins":["Installerar till\u00e4gg"],"Activating plugins":["Aktiverar till\u00e4gg"],"Importing widgets":["Importerar widgetar"],"Importing site options":["Importerar webbplatsalternativ"],"Importing content":["Importerar inneh\u00e5ll"],"None":["Ingen"],"Import":["Importera"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-cbab080b0f20fd6c323029398be6c986.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-cbab080b0f20fd6c323029398be6c986.json deleted file mode 100644 index 4bad3bc6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-cbab080b0f20fd6c323029398be6c986.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-01 13:13:24+0000","generator":"WP-CLI\/2.6.0","source":"dist\/dashboard.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"sv_SE","plural-forms":"nplurals=2; plural=n != 1;"},"This will delete all of your customizer settings. It cannot be undone.":["Detta kommer ta bort alla dina anpassningsinst\u00e4llningar. Det kan inte \u00e5ngras."],"Reset your customizer settings.":["\u00c5terst\u00e4ll dina inst\u00e4llningar f\u00f6r anpassaren."],"Options imported.":["Alternativ importerade."],"This can overwrite existing settings and cannot be undone.":["Detta kan skriva \u00f6ver befintliga inst\u00e4llningar och kan inte \u00e5ngras."],"Import your customizer settings.":["Importera dina inst\u00e4llningar f\u00f6r anpassaren."],"Global Colors":["Globala f\u00e4rger"],"Export your customizer settings.":["Exportera dina inst\u00e4llningar f\u00f6r anpassaren."],"Import \/ Export":["Import\/export"],"License key deactivated.":["Licensnyckel inaktiverad."],"License key activated.":["Licensnyckel aktiverad."],"Get alpha and beta updates directly to your Dashboard.":[""],"Enter your license key to activate updates.":["Ange din licensnyckel f\u00f6r att aktivera uppdateringar."],"Not receiving premium updates.":["Tar inte emot premiumuppdateringar."],"Receiving premium updates.":["Tar emot premiumuppdateringar."],"Options exported":["Alternativ exporterad"],"This will delete all settings for this module. It cannot be undone.":["Detta kommer ta bort alla inst\u00e4llningar f\u00f6r denna modul. Det kan inte \u00e5ngras."],"Open tools for this module.":["\u00d6ppna verktyg f\u00f6r denna modul."],"Open Elements":["\u00d6ppna element"],"Open Site Library":["\u00d6ppna webbplatsbibliotek"],"Settings reset.":["Inst\u00e4llningar \u00e5terst\u00e4lls."],"Typography":["Typografi"],"All":["Alla"],"Reset":["\u00c5terst\u00e4ll"],"Modules":["Moduler"],"License Key":["Licensnyckel"],"Deactivate":["Inaktivera"],"Activate":["Aktivera"],"This module has been deprecated. Deactivating it will remove it from this list.":["Denna modul har tagits ur bruk. Vid inaktivering kommer den att tas bort fr\u00e5n denna lista."],"Import":["Importera"],"Export":["Exportera"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-ecf9f3c2af10c4f2dfbf4f42504922d1.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-ecf9f3c2af10c4f2dfbf4f42504922d1.json deleted file mode 100644 index f7a81aff..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE-ecf9f3c2af10c4f2dfbf4f42504922d1.json +++ /dev/null @@ -1 +0,0 @@ -{"translation-revision-date":"2022-10-01 13:13:24+0000","generator":"WP-CLI\/2.6.0","source":"dist\/customizer.js","domain":"messages","locale_data":{"messages":{"":{"domain":"messages","lang":"sv_SE","plural-forms":"nplurals=2; plural=n != 1;"},"Related\/Upsell Product Titles":["Produktrubriker f\u00f6r relaterad\/merf\u00f6rs\u00e4ljning"],"Catalog Product Titles":[""],"Off-Canvas Sub-Menu Items":[""],"Off-Canvas Menu Items":[""],"Secondary Mobile Menu Toggle":[""],"Secondary Sub-Menu Items":[""],"Secondary Menu Items":["Sekund\u00e4ra menyalternativ"],"Off-Canvas Panel":[""],"WooCommerce":["WooCommerce"],"Secondary Navigation":["Sekund\u00e4r navigation"]}}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE.mo deleted file mode 100644 index 2452b734..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-sv_SE.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-uk.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-uk.mo deleted file mode 100644 index 007659aa..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-uk.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-vi.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-vi.mo deleted file mode 100644 index 1838e84d..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-vi.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-zh_CN.mo b/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-zh_CN.mo deleted file mode 100644 index cf5a1f2d..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/langs/gp-premium-zh_CN.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/alpha-color-picker/wp-color-picker-alpha.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/alpha-color-picker/wp-color-picker-alpha.js deleted file mode 100644 index bd407429..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/alpha-color-picker/wp-color-picker-alpha.js +++ /dev/null @@ -1,635 +0,0 @@ -/**! - * wp-color-picker-alpha - * - * Overwrite Automattic Iris for enabled Alpha Channel in wpColorPicker - * Only run in input and is defined data alpha in true - * - * Version: 3.0.0 - * https://github.com/kallookoo/wp-color-picker-alpha - * Licensed under the GPLv2 license or later. - */ - -( function( $, undef ) { - - var wpColorPickerAlpha = { - 'version' : 300 - }; - - // Always try to use the last version of this script. - if ( 'wpColorPickerAlpha' in window && 'version' in window.wpColorPickerAlpha ) { - var version = parseInt( window.wpColorPickerAlpha.version, 10 ); - if ( ! isNaN( version ) && version >= wpColorPickerAlpha.version ) { - return; - } - } - - // Prevent multiple initiations - if ( Color.fn.hasOwnProperty( 'to_s' ) ) { - return; - } - - // Create new method to replace the `Color.toString()` inside the scripts. - Color.fn.to_s = function( type ) { - type = ( type || 'hex' ); - // Change hex to rgba to return the correct color. - if ( 'hex' === type && this._alpha < 1 ) { - type = 'rgba'; - } - - var color = ''; - if ( 'hex' === type ) { - color = this.toString(); - } else if ( ! this.error ) { - color = this.toCSS( type ).replace( /\(\s+/, '(' ).replace( /\s+\)/, ')' ); - } - return color; - } - - // Register the global variable. - window.wpColorPickerAlpha = wpColorPickerAlpha; - - // Background image encoded - var backgroundImage = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAAHnlligAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAHJJREFUeNpi+P///4EDBxiAGMgCCCAGFB5AADGCRBgYDh48CCRZIJS9vT2QBAggFBkmBiSAogxFBiCAoHogAKIKAlBUYTELAiAmEtABEECk20G6BOmuIl0CIMBQ/IEMkO0myiSSraaaBhZcbkUOs0HuBwDplz5uFJ3Z4gAAAABJRU5ErkJggg=='; - - /** - * Iris - */ - $.widget( 'a8c.iris', $.a8c.iris, { - /** - * Alpha options - * - * @since 3.0.0 - * - * @type {Object} - */ - alphaOptions: { - alphaEnabled: false, - }, - /** - * Get the current color or the new color. - * - * @since 3.0.0 - * @access private - * - * @param {Object|*} The color instance if not defined return the cuurent color. - * - * @return {string} The element's color. - */ - _getColor: function( color ) { - if ( color === undef ) { - color = this._color; - } - - if ( this.alphaOptions.alphaEnabled ) { - color = color.to_s( this.alphaOptions.alphaColorType ); - if ( ! this.alphaOptions.alphaColorWithSpace ) { - color = color.replace( /\s+/g, '' ); - } - return color; - } - return color.toString(); - }, - /** - * Create widget - * - * @since 3.0.0 - * @access private - * - * @return {void} - */ - _create: function() { - try { - // Try to get the wpColorPicker alpha options. - this.alphaOptions = this.element.wpColorPicker( 'instance' ).alphaOptions; - } catch( e ) {} - - // We make sure there are all options - $.extend( {}, this.alphaOptions, { - alphaEnabled: false, - alphaCustomWidth: 130, - alphaReset: false, - alphaColorType: 'hex', - alphaColorWithSpace: false, - } ); - - this._super(); - }, - /** - * Binds event listeners to the Iris. - * - * @since 3.0.0 - * @access private - * - * @return {void} - */ - _addInputListeners: function( input ) { - var self = this, - debounceTimeout = 100, - callback = function( event ){ - var val = input.val(), - color = new Color( val ), - val = val.replace( /^(#|(rgb|hsl)a?)/, '' ), - type = self.alphaOptions.alphaColorType; - - input.removeClass( 'iris-error' ); - - if ( ! color.error ) { - // let's not do this on keyup for hex shortcodes - if ( 'hex' !== type || ! ( event.type === 'keyup' && val.match( /^[0-9a-fA-F]{3}$/ ) ) ) { - // Compare color ( #AARRGGBB ) - if ( color.toIEOctoHex() !== self._color.toIEOctoHex() ) { - self._setOption( 'color', self._getColor( color ) ); - } - } - } else if ( val !== '' ) { - input.addClass( 'iris-error' ); - } - }; - - input.on( 'change', callback ).on( 'keyup', self._debounce( callback, debounceTimeout ) ); - - // If we initialized hidden, show on first focus. The rest is up to you. - if ( self.options.hide ) { - input.one( 'focus', function() { - self.show(); - }); - } - }, - /** - * Init Controls - * - * @since 3.0.0 - * @access private - * - * @return {void} - */ - _initControls: function() { - this._super(); - - if ( this.alphaOptions.alphaEnabled ) { - // Create Alpha controls - var self = this, - stripAlpha = self.controls.strip.clone(false, false), - stripAlphaSlider = stripAlpha.find( '.iris-slider-offset' ), - controls = { - stripAlpha : stripAlpha, - stripAlphaSlider : stripAlphaSlider - }; - - stripAlpha.addClass( 'iris-strip-alpha' ); - stripAlphaSlider.addClass( 'iris-slider-offset-alpha' ); - stripAlpha.appendTo( self.picker.find( '.iris-picker-inner' ) ); - - // Push new controls - $.each( controls, function( k, v ) { - self.controls[k] = v; - } ); - - // Create slider - self.controls.stripAlphaSlider.slider( { - orientation : 'vertical', - min : 0, - max : 100, - step : 1, - value : parseInt( self._color._alpha * 100 ), - slide : function( event, ui ) { - self.active = 'strip'; - // Update alpha value - self._color._alpha = parseFloat( ui.value / 100 ); - self._change.apply( self, arguments ); - } - } ); - } - }, - /** - * Create the controls sizes - * - * @since 3.0.0 - * @access private - * - * @param {bool} reset Set to True for recreate the controls sizes. - * - * @return {void} - */ - _dimensions: function( reset ) { - this._super( reset ); - - if ( this.alphaOptions.alphaEnabled ) { - var self = this, - opts = self.options, - controls = self.controls, - square = controls.square, - strip = self.picker.find( '.iris-strip' ), - innerWidth, squareWidth, stripWidth, stripMargin, totalWidth; - - /** - * I use Math.round() to avoid possible size errors, - * this function returns the value of a number rounded - * to the nearest integer. - * - * The width to append all widgets, - * if border is enabled, 22 is subtracted. - * 20 for css left and right property - * 2 for css border - */ - innerWidth = Math.round( self.picker.outerWidth( true ) - ( opts.border ? 22 : 0 ) ); - // The width of the draggable, aka square. - squareWidth = Math.round( square.outerWidth() ); - // The width for the sliders - stripWidth = Math.round( ( innerWidth - squareWidth ) / 2 ); - // The margin for the sliders - stripMargin = Math.round( stripWidth / 2 ); - // The total width of the elements. - totalWidth = Math.round( squareWidth + ( stripWidth * 2 ) + ( stripMargin * 2 ) ); - - // Check and change if necessary. - while ( totalWidth > innerWidth ) { - stripWidth = Math.round( stripWidth - 2 ); - stripMargin = Math.round( stripMargin - 1 ); - totalWidth = Math.round( squareWidth + ( stripWidth * 2 ) + ( stripMargin * 2 ) ); - } - - - square.css( 'margin', '0' ); - strip.width( stripWidth ).css( 'margin-left', stripMargin + 'px' ); - } - }, - /** - * Callback to update the controls and the current color. - * - * @since 3.0.0 - * @access private - * - * @return {void} - */ - _change: function() { - var self = this, - active = self.active; - - self._super(); - - if ( self.alphaOptions.alphaEnabled ) { - var controls = self.controls, - alpha = parseInt( self._color._alpha * 100 ), - color = self._color.toRgb(), - gradient = [ - 'rgb(' + color.r + ',' + color.g + ',' + color.b + ') 0%', - 'rgba(' + color.r + ',' + color.g + ',' + color.b + ', 0) 100%' - ], - target = self.picker.closest( '.wp-picker-container' ).find( '.wp-color-result' ); - - self.options.color = self._getColor(); - // Generate background slider alpha, only for CSS3. - controls.stripAlpha.css( { 'background' : 'linear-gradient(to bottom, ' + gradient.join( ', ' ) + '), url(' + backgroundImage + ')' } ); - // Update alpha value - if ( active ) { - controls.stripAlphaSlider.slider( 'value', alpha ); - } - - if ( ! self._color.error ) { - self.element.removeClass( 'iris-error' ).val( self.options.color ); - } - - self.picker.find( '.iris-palette-container' ).on( 'click.palette', '.iris-palette', function() { - var color = $( this ).data( 'color' ); - if ( self.alphaOptions.alphaReset ) { - self._color._alpha = 1; - color = self._getColor(); - } - self._setOption( 'color', color ); - } ); - } - }, - /** - * Paint dimensions. - * - * @since 3.0.0 - * @access private - * - * @param {string} origin Origin (position). - * @param {string} control Type of the control, - * - * @return {void} - */ - _paintDimension: function( origin, control ) { - var self = this, - color = false; - - // Fix for slider hue opacity. - if ( self.alphaOptions.alphaEnabled && 'strip' === control ) { - color = self._color; - self._color = new Color( color.toString() ); - self.hue = self._color.h(); - } - - self._super( origin, control ); - - // Restore the color after paint. - if ( color ) { - self._color = color; - } - }, - /** - * To update the options, see original source to view the available options. - * - * @since 3.0.0 - * - * @param {string} key The Option name. - * @param {mixed} value The Option value to update. - * - * @return {void} - */ - _setOption: function( key, value ) { - var self = this; - if ( 'color' === key && self.alphaOptions.alphaEnabled ) { - // cast to string in case we have a number - value = '' + value; - newColor = new Color( value ).setHSpace( self.options.mode ); - // Check if error && Check the color to prevent callbacks with the same color. - if ( ! newColor.error && self._getColor( newColor ) !== self._getColor() ) { - self._color = newColor; - self.options.color = self._getColor(); - self.active = 'external'; - self._change(); - } - } else { - return self._super( key, value ); - } - }, - /** - * Returns the iris object if no new color is provided. If a new color is provided, it sets the new color. - * - * @param newColor {string|*} The new color to use. Can be undefined. - * - * @since 3.0.0 - * - * @return {string} The element's color. - */ - color: function( newColor ) { - if ( newColor === true ) { - return this._color.clone(); - } - if ( newColor === undef ) { - return this._getColor(); - } - this.option( 'color', newColor ); - }, - } ); - - /** - * wpColorPicker - */ - $.widget( 'wp.wpColorPicker', $.wp.wpColorPicker, { - /** - * Alpha options - * - * @since 3.0.0 - * - * @type {Object} - */ - alphaOptions: { - alphaEnabled: false, - }, - /** - * Get the alpha options. - * - * @since 3.0.0 - * @access private - * - * @return {object} The current alpha options. - */ - _getAlphaOptions: function() { - var el = this.element, - type = ( el.data( 'type' ) || this.options.type ), - color = ( el.data( 'defaultColor' ) || el.val() ), - options = { - alphaEnabled: ( el.data( 'alphaEnabled' ) || false ), - alphaCustomWidth: 130, - alphaReset: false, - alphaColorType: 'rgb', - alphaColorWithSpace: false, - }; - - if ( options.alphaEnabled ) { - options.alphaEnabled = ( el.is( 'input' ) && 'full' === type ); - } - - if ( ! options.alphaEnabled ) { - return options; - } - - options.alphaColorWithSpace = ( color && color.match( /\s/ ) ); - - $.each( options, function( name, defaultValue ) { - var value = ( el.data( name ) || defaultValue ); - switch ( name ) { - case 'alphaCustomWidth': - value = ( value ? parseInt( value, 10 ) : 0 ); - value = ( isNaN( value ) ? defaultValue : value ); - break; - case 'alphaColorType': - if ( ! value.match( /^(hex|(rgb|hsl)a?)$/ ) ) { - if ( color && color.match( /^#/ ) ) { - value = 'hex'; - } else if ( color && color.match( /^hsla?/ ) ) { - value = 'hsl'; - } else { - value = defaultValue; - } - } - break; - default: - value = !!value; - break; - } - options[name] = value; - } ); - - return options; - }, - /** - * Create widget - * - * @since 3.0.0 - * @access private - * - * @return {void} - */ - _create: function() { - // Return early if Iris support is missing. - if ( ! $.support.iris ) { - return; - } - - // Set the alpha options for the current instance. - this.alphaOptions = this._getAlphaOptions(); - - // Create widget. - this._super(); - }, - /** - * Binds event listeners to the color picker and create options, etc... - * - * @since 3.0.0 - * @access private - * - * @return {void} - */ - _addListeners: function() { - if ( ! this.alphaOptions.alphaEnabled ) { - return this._super(); - } - - var self = this, - el = self.element, - isDeprecated = self.toggler.is( 'a' ); - - this.alphaOptions.defaultWidth = el.width(); - if ( this.alphaOptions.alphaCustomWidth ) { - el.width( parseInt( this.alphaOptions.defaultWidth + this.alphaOptions.alphaCustomWidth, 10 ) ); - } - - self.toggler.css( { - 'position': 'relative', - 'background-image' : 'url(' + backgroundImage + ')' - } ); - - if ( isDeprecated ) { - self.toggler.html( '' ); - } else { - self.toggler.append( '' ); - } - - self.colorAlpha = self.toggler.find( 'span.color-alpha' ).css( { - 'width' : '30px', - 'height' : '100%', - 'position' : 'absolute', - 'top' : 0, - 'background-color' : el.val(), - } ); - - // Define the correct position for ltr or rtl direction. - if ( 'ltr' === self.colorAlpha.css( 'direction' ) ) { - self.colorAlpha.css( { - 'border-bottom-left-radius' : '2px', - 'border-top-left-radius' : '2px', - 'left' : 0 - } ); - } else { - self.colorAlpha.css( { - 'border-bottom-right-radius' : '2px', - 'border-top-right-radius' : '2px', - 'right' : 0 - } ); - } - - - el.iris( { - /** - * @summary Handles the onChange event if one has been defined in the options. - * - * Handles the onChange event if one has been defined in the options and additionally - * sets the background color for the toggler element. - * - * @since 3.0.0 - * - * @param {Event} event The event that's being called. - * @param {HTMLElement} ui The HTMLElement containing the color picker. - * - * @returns {void} - */ - change: function( event, ui ) { - self.colorAlpha.css( { 'background-color': ui.color.to_s( self.alphaOptions.alphaColorType ) } ); - - // fire change callback if we have one - if ( $.isFunction( self.options.change ) ) { - self.options.change.call( this, event, ui ); - } - } - } ); - - - /** - * Prevent any clicks inside this widget from leaking to the top and closing it. - * - * @since 3.0.0 - * - * @param {Event} event The event that's being called. - * - * @return {void} - */ - self.wrap.on( 'click.wpcolorpicker', function( event ) { - event.stopPropagation(); - }); - - /** - * Open or close the color picker depending on the class. - * - * @since 3.0.0 - */ - self.toggler.click( function() { - if ( self.toggler.hasClass( 'wp-picker-open' ) ) { - self.close(); - } else { - self.open(); - } - }); - - /** - * Checks if value is empty when changing the color in the color picker. - * If so, the background color is cleared. - * - * @since 3.0.0 - * - * @param {Event} event The event that's being called. - * - * @return {void} - */ - el.change( function( event ) { - var val = $( this ).val(); - - if ( el.hasClass( 'iris-error' ) || val === '' || val.match( /^(#|(rgb|hsl)a?)$/ ) ) { - if ( isDeprecated ) { - self.toggler.removeAttr( 'style' ); - } - - self.colorAlpha.css( 'background-color', '' ); - - // fire clear callback if we have one - if ( $.isFunction( self.options.clear ) ) { - self.options.clear.call( this, event ); - } - } - } ); - - /** - * Enables the user to either clear the color in the color picker or revert back to the default color. - * - * @since 3.0.0 - * - * @param {Event} event The event that's being called. - * - * @return {void} - */ - self.button.click( function( event ) { - if ( $( this ).hasClass( 'wp-picker-default' ) ) { - el.val( self.options.defaultColor ).change(); - } else if ( $( this ).hasClass( 'wp-picker-clear' ) ) { - el.val( '' ); - if ( isDeprecated ) { - self.toggler.removeAttr( 'style' ); - } - - self.colorAlpha.css( 'background-color', '' ); - - // fire clear callback if we have one - if ( $.isFunction( self.options.clear ) ) { - self.options.clear.call( this, event ); - } - - el.trigger( 'change' ); - } - } ); - }, - } ); -} ( jQuery ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/alpha-color-picker/wp-color-picker-alpha.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/alpha-color-picker/wp-color-picker-alpha.min.js deleted file mode 100644 index fde8c833..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/alpha-color-picker/wp-color-picker-alpha.min.js +++ /dev/null @@ -1,11 +0,0 @@ -/**! - * wp-color-picker-alpha - * - * Overwrite Automattic Iris for enabled Alpha Channel in wpColorPicker - * Only run in input and is defined data alpha in true - * - * Version: 3.0.0 - * https://github.com/kallookoo/wp-color-picker-alpha - * Licensed under the GPLv2 license or later. - */ -!function(e,a){var l,o={version:300};if("wpColorPickerAlpha"in window&&"version"in window.wpColorPickerAlpha){var t=parseInt(window.wpColorPickerAlpha.version,10);if(!isNaN(t)&&o.version<=t)return}Color.fn.hasOwnProperty("to_s")||(Color.fn.to_s=function(o){"hex"===(o=o||"hex")&&this._alpha<1&&(o="rgba");var a="";return"hex"===o?a=this.toString():this.error||(a=this.toCSS(o).replace(/\(\s+/,"(").replace(/\s+\)/,")")),a},window.wpColorPickerAlpha=o,l="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAAHnlligAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAHJJREFUeNpi+P///4EDBxiAGMgCCCAGFB5AADGCRBgYDh48CCRZIJS9vT2QBAggFBkmBiSAogxFBiCAoHogAKIKAlBUYTELAiAmEtABEECk20G6BOmuIl0CIMBQ/IEMkO0myiSSraaaBhZcbkUOs0HuBwDplz5uFJ3Z4gAAAABJRU5ErkJggg==",e.widget("a8c.iris",e.a8c.iris,{alphaOptions:{alphaEnabled:!1},_getColor:function(o){return o===a&&(o=this._color),this.alphaOptions.alphaEnabled?(o=o.to_s(this.alphaOptions.alphaColorType),this.alphaOptions.alphaColorWithSpace||(o=o.replace(/\s+/g,"")),o):o.toString()},_create:function(){try{this.alphaOptions=this.element.wpColorPicker("instance").alphaOptions}catch(o){}e.extend({},this.alphaOptions,{alphaEnabled:!1,alphaCustomWidth:130,alphaReset:!1,alphaColorType:"hex",alphaColorWithSpace:!1}),this._super()},_addInputListeners:function(i){function o(o){var a=i.val(),t=new Color(a),a=a.replace(/^(#|(rgb|hsl)a?)/,""),r=l.alphaOptions.alphaColorType;i.removeClass("iris-error"),t.error?""!==a&&i.addClass("iris-error"):"hex"===r&&"keyup"===o.type&&a.match(/^[0-9a-fA-F]{3}$/)||t.toIEOctoHex()!==l._color.toIEOctoHex()&&l._setOption("color",l._getColor(t))}var l=this;i.on("change",o).on("keyup",l._debounce(o,100)),l.options.hide&&i.one("focus",function(){l.show()})},_initControls:function(){var t,o,a,r;this._super(),this.alphaOptions.alphaEnabled&&(a=(o=(t=this).controls.strip.clone(!1,!1)).find(".iris-slider-offset"),r={stripAlpha:o,stripAlphaSlider:a},o.addClass("iris-strip-alpha"),a.addClass("iris-slider-offset-alpha"),o.appendTo(t.picker.find(".iris-picker-inner")),e.each(r,function(o,a){t.controls[o]=a}),t.controls.stripAlphaSlider.slider({orientation:"vertical",min:0,max:100,step:1,value:parseInt(100*t._color._alpha),slide:function(o,a){t.active="strip",t._color._alpha=parseFloat(a.value/100),t._change.apply(t,arguments)}}))},_dimensions:function(o){if(this._super(o),this.alphaOptions.alphaEnabled){for(var a=this,t=a.options,r=a.controls.square,o=a.picker.find(".iris-strip"),i=Math.round(a.picker.outerWidth(!0)-(t.border?22:0)),l=Math.round(r.outerWidth()),e=Math.round((i-l)/2),s=Math.round(e/2),n=Math.round(l+2*e+2*s);i'):t.toggler.append(''),t.colorAlpha=t.toggler.find("span.color-alpha").css({width:"30px",height:"100%",position:"absolute",top:0,"background-color":r.val()}),"ltr"===t.colorAlpha.css("direction")?t.colorAlpha.css({"border-bottom-left-radius":"2px","border-top-left-radius":"2px",left:0}):t.colorAlpha.css({"border-bottom-right-radius":"2px","border-top-right-radius":"2px",right:0}),r.iris({change:function(o,a){t.colorAlpha.css({"background-color":a.color.to_s(t.alphaOptions.alphaColorType)}),e.isFunction(t.options.change)&&t.options.change.call(this,o,a)}}),t.wrap.on("click.wpcolorpicker",function(o){o.stopPropagation()}),t.toggler.click(function(){t.toggler.hasClass("wp-picker-open")?t.close():t.open()}),r.change(function(o){var a=e(this).val();(r.hasClass("iris-error")||""===a||a.match(/^(#|(rgb|hsl)a?)$/))&&(i&&t.toggler.removeAttr("style"),t.colorAlpha.css("background-color",""),e.isFunction(t.options.clear)&&t.options.clear.call(this,o))}),t.button.click(function(o){e(this).hasClass("wp-picker-default")?r.val(t.options.defaultColor).change():e(this).hasClass("wp-picker-clear")&&(r.val(""),i&&t.toggler.removeAttr("style"),t.colorAlpha.css("background-color",""),e.isFunction(t.options.clear)&&t.options.clear.call(this,o),r.trigger("change"))})}}))}(jQuery); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/class-make-css.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/class-make-css.php deleted file mode 100644 index 19876b27..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/class-make-css.php +++ /dev/null @@ -1,202 +0,0 @@ -_selector !== '' ){ - $this->add_selector_rules_to_output(); - } - $this->_selector = $selector; - return $this; - } - - /** - * Adds a css property with value to the css output - * - * @access public - * @since 1.0 - * - * @param string $property - the css property - * @param string $value - the value to be placed with the property - * @param string $og_default - check to see if the value matches the default - * @param string $unit - the unit for the value (px) - * @return $this - */ - public function add_property( $property, $value, $og_default = false, $unit = false ) { - // Add our unit to our value if it exists - if ( $unit && '' !== $unit ) { - $value = $value . $unit; - if ( '' !== $og_default ) { - $og_default = $og_default . $unit; - } - } - - // If we don't have a value or our value is the same as our og default, bail - if ( empty( $value ) || $og_default == $value ) - return false; - - $this->_css .= $property . ':' . $value . ';'; - return $this; - } - - /** - * Sets a media query in the class - * - * @since 1.1 - * @param string $value - * @return $this - */ - public function start_media_query( $value ) { - // Add the current rules to the output - $this->add_selector_rules_to_output(); - - // Add any previous media queries to the output - if ( ! empty( $this->_media_query ) ) { - $this->add_media_query_rules_to_output(); - } - - // Set the new media query - $this->_media_query = $value; - return $this; - } - - /** - * Stops using a media query. - * - * @see start_media_query() - * - * @since 1.1 - * @return $this - */ - public function stop_media_query() { - return $this->start_media_query( null ); - } - - /** - * Adds the current media query's rules to the class' output variable - * - * @since 1.1 - * @return $this - */ - private function add_media_query_rules_to_output() { - if( !empty( $this->_media_query_output ) ) { - $this->_output .= sprintf( '@media %1$s{%2$s}', $this->_media_query, $this->_media_query_output ); - - // Reset the media query output string - $this->_media_query_output = ''; - } - return $this; - } - - /** - * Adds the current selector rules to the output variable - * - * @access private - * @since 1.0 - * - * @return $this - */ - private function add_selector_rules_to_output() { - if( !empty( $this->_css ) ) { - $this->_selector_output = $this->_selector; - $selector_output = sprintf( '%1$s{%2$s}', $this->_selector_output, $this->_css ); - - // Add our CSS to the output - if ( ! empty( $this->_media_query ) ) { - $this->_media_query_output .= $selector_output; - $this->_css = ''; - } else { - $this->_output .= $selector_output; - } - - // Reset the css - $this->_css = ''; - } - - return $this; - } - - /** - * Returns the minified css in the $_output variable - * - * @access public - * @since 1.0 - * - * @return string - */ - public function css_output() - { - // Add current selector's rules to output - $this->add_selector_rules_to_output(); - - // Output minified css - return $this->_output; - } - -} -endif; diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/class-plugin-updater.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/class-plugin-updater.php deleted file mode 100644 index 42fb1e09..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/class-plugin-updater.php +++ /dev/null @@ -1,676 +0,0 @@ -api_url = trailingslashit( $_api_url ); - $this->api_data = $_api_data; - $this->plugin_file = $_plugin_file; - $this->name = plugin_basename( $_plugin_file ); - $this->slug = basename( $_plugin_file, '.php' ); - $this->version = $_api_data['version']; - $this->wp_override = isset( $_api_data['wp_override'] ) ? (bool) $_api_data['wp_override'] : false; - $this->beta = ! empty( $this->api_data['beta'] ) ? true : false; - $this->failed_request_cache_key = 'edd_sl_failed_http_' . md5( $this->api_url ); - - $edd_plugin_data[ $this->slug ] = $this->api_data; - - /** - * Fires after the $edd_plugin_data is setup. - * - * @since x.x.x - * - * @param array $edd_plugin_data Array of EDD SL plugin data. - */ - do_action( 'post_edd_sl_plugin_updater_setup', $edd_plugin_data ); - - // Set up hooks. - $this->init(); - - } - - /** - * Set up WordPress filters to hook into WP's update process. - * - * @uses add_filter() - * - * @return void - */ - public function init() { - - add_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_update' ) ); - add_filter( 'plugins_api', array( $this, 'plugins_api_filter' ), 10, 3 ); - add_action( 'after_plugin_row', array( $this, 'show_update_notification' ), 10, 2 ); - add_action( 'admin_init', array( $this, 'show_changelog' ) ); - - } - - /** - * Check for Updates at the defined API endpoint and modify the update array. - * - * This function dives into the update API just when WordPress creates its update array, - * then adds a custom API call and injects the custom plugin data retrieved from the API. - * It is reassembled from parts of the native WordPress plugin update code. - * See wp-includes/update.php line 121 for the original wp_update_plugins() function. - * - * @uses api_request() - * - * @param array $_transient_data Update array build by WordPress. - * @return array Modified update array with custom plugin data. - */ - public function check_update( $_transient_data ) { - - global $pagenow; - - if ( ! is_object( $_transient_data ) ) { - $_transient_data = new stdClass(); - } - - if ( ! empty( $_transient_data->response ) && ! empty( $_transient_data->response[ $this->name ] ) && false === $this->wp_override ) { - return $_transient_data; - } - - $current = $this->get_repo_api_data(); - if ( false !== $current && is_object( $current ) && isset( $current->new_version ) ) { - if ( version_compare( $this->version, $current->new_version, '<' ) ) { - $_transient_data->response[ $this->name ] = $current; - } else { - // Populating the no_update information is required to support auto-updates in WordPress 5.5. - $_transient_data->no_update[ $this->name ] = $current; - } - } - $_transient_data->last_checked = time(); - $_transient_data->checked[ $this->name ] = $this->version; - - return $_transient_data; - } - - /** - * Get repo API data from store. - * Save to cache. - * - * @return \stdClass - */ - public function get_repo_api_data() { - $version_info = $this->get_cached_version_info(); - - if ( false === $version_info ) { - $version_info = $this->api_request( - 'plugin_latest_version', - array( - 'slug' => $this->slug, - 'beta' => $this->beta, - ) - ); - if ( ! $version_info ) { - return false; - } - - // This is required for your plugin to support auto-updates in WordPress 5.5. - $version_info->plugin = $this->name; - $version_info->id = $this->name; - $version_info->tested = $this->get_tested_version( $version_info ); - - $this->set_version_info_cache( $version_info ); - } - - return $version_info; - } - - /** - * Gets the plugin's tested version. - * - * @since 1.9.2 - * @param object $version_info - * @return null|string - */ - private function get_tested_version( $version_info ) { - - // There is no tested version. - if ( empty( $version_info->tested ) ) { - return null; - } - - // Strip off extra version data so the result is x.y or x.y.z. - list( $current_wp_version ) = explode( '-', get_bloginfo( 'version' ) ); - - // The tested version is greater than or equal to the current WP version, no need to do anything. - if ( version_compare( $version_info->tested, $current_wp_version, '>=' ) ) { - return $version_info->tested; - } - $current_version_parts = explode( '.', $current_wp_version ); - $tested_parts = explode( '.', $version_info->tested ); - - // The current WordPress version is x.y.z, so update the tested version to match it. - if ( isset( $current_version_parts[2] ) && $current_version_parts[0] === $tested_parts[0] && $current_version_parts[1] === $tested_parts[1] ) { - $tested_parts[2] = $current_version_parts[2]; - } - - return implode( '.', $tested_parts ); - } - - /** - * Show the update notification on multisite subsites. - * - * @param string $file - * @param array $plugin - */ - public function show_update_notification( $file, $plugin ) { - - // Return early if in the network admin, or if this is not a multisite install. - if ( is_network_admin() || ! is_multisite() ) { - return; - } - - // Allow single site admins to see that an update is available. - if ( ! current_user_can( 'activate_plugins' ) ) { - return; - } - - if ( $this->name !== $file ) { - return; - } - - // Do not print any message if update does not exist. - $update_cache = get_site_transient( 'update_plugins' ); - - if ( ! isset( $update_cache->response[ $this->name ] ) ) { - if ( ! is_object( $update_cache ) ) { - $update_cache = new stdClass(); - } - $update_cache->response[ $this->name ] = $this->get_repo_api_data(); - } - - // Return early if this plugin isn't in the transient->response or if the site is running the current or newer version of the plugin. - if ( empty( $update_cache->response[ $this->name ] ) || version_compare( $this->version, $update_cache->response[ $this->name ]->new_version, '>=' ) ) { - return; - } - - printf( - '', - $this->slug, - $file, - in_array( $this->name, $this->get_active_plugins(), true ) ? 'active' : 'inactive' - ); - - echo ''; - echo '

    '; - - $changelog_link = ''; - if ( ! empty( $update_cache->response[ $this->name ]->sections->changelog ) ) { - $changelog_link = add_query_arg( - array( - 'edd_sl_action' => 'view_plugin_changelog', - 'plugin' => urlencode( $this->name ), - 'slug' => urlencode( $this->slug ), - 'TB_iframe' => 'true', - 'width' => 77, - 'height' => 911, - ), - self_admin_url( 'index.php' ) - ); - } - $update_link = add_query_arg( - array( - 'action' => 'upgrade-plugin', - 'plugin' => urlencode( $this->name ), - ), - self_admin_url( 'update.php' ) - ); - - printf( - /* translators: the plugin name. */ - esc_html__( 'There is a new version of %1$s available.', 'easy-digital-downloads' ), - esc_html( $plugin['Name'] ) - ); - - if ( ! current_user_can( 'update_plugins' ) ) { - echo ' '; - esc_html_e( 'Contact your network administrator to install the update.', 'easy-digital-downloads' ); - } elseif ( empty( $update_cache->response[ $this->name ]->package ) && ! empty( $changelog_link ) ) { - echo ' '; - printf( - /* translators: 1. opening anchor tag, do not translate 2. the new plugin version 3. closing anchor tag, do not translate. */ - __( '%1$sView version %2$s details%3$s.', 'easy-digital-downloads' ), - '', - esc_html( $update_cache->response[ $this->name ]->new_version ), - '' - ); - } elseif ( ! empty( $changelog_link ) ) { - echo ' '; - printf( - __( '%1$sView version %2$s details%3$s or %4$supdate now%5$s.', 'easy-digital-downloads' ), - '', - esc_html( $update_cache->response[ $this->name ]->new_version ), - '', - '', - '' - ); - } else { - printf( - ' %1$s%2$s%3$s', - '', - esc_html__( 'Update now.', 'easy-digital-downloads' ), - '' - ); - } - - do_action( "in_plugin_update_message-{$file}", $plugin, $plugin ); - - echo '

    '; - } - - /** - * Gets the plugins active in a multisite network. - * - * @return array - */ - private function get_active_plugins() { - $active_plugins = (array) get_option( 'active_plugins' ); - $active_network_plugins = (array) get_site_option( 'active_sitewide_plugins' ); - - return array_merge( $active_plugins, array_keys( $active_network_plugins ) ); - } - - /** - * Updates information on the "View version x.x details" page with custom data. - * - * @uses api_request() - * - * @param mixed $_data - * @param string $_action - * @param object $_args - * @return object $_data - */ - public function plugins_api_filter( $_data, $_action = '', $_args = null ) { - - if ( 'plugin_information' !== $_action ) { - - return $_data; - - } - - if ( ! isset( $_args->slug ) || ( $_args->slug !== $this->slug ) ) { - - return $_data; - - } - - $to_send = array( - 'slug' => $this->slug, - 'is_ssl' => is_ssl(), - 'fields' => array( - 'banners' => array(), - 'reviews' => false, - 'icons' => array(), - ), - ); - - // Get the transient where we store the api request for this plugin for 24 hours - $edd_api_request_transient = $this->get_cached_version_info(); - - //If we have no transient-saved value, run the API, set a fresh transient with the API value, and return that value too right now. - if ( empty( $edd_api_request_transient ) ) { - - $api_response = $this->api_request( 'plugin_information', $to_send ); - - // Expires in 3 hours - $this->set_version_info_cache( $api_response ); - - if ( false !== $api_response ) { - $_data = $api_response; - } - } else { - $_data = $edd_api_request_transient; - } - - // Convert sections into an associative array, since we're getting an object, but Core expects an array. - if ( isset( $_data->sections ) && ! is_array( $_data->sections ) ) { - $_data->sections = $this->convert_object_to_array( $_data->sections ); - } - - // Convert banners into an associative array, since we're getting an object, but Core expects an array. - if ( isset( $_data->banners ) && ! is_array( $_data->banners ) ) { - $_data->banners = $this->convert_object_to_array( $_data->banners ); - } - - // Convert icons into an associative array, since we're getting an object, but Core expects an array. - if ( isset( $_data->icons ) && ! is_array( $_data->icons ) ) { - $_data->icons = $this->convert_object_to_array( $_data->icons ); - } - - // Convert contributors into an associative array, since we're getting an object, but Core expects an array. - if ( isset( $_data->contributors ) && ! is_array( $_data->contributors ) ) { - $_data->contributors = $this->convert_object_to_array( $_data->contributors ); - } - - if ( ! isset( $_data->plugin ) ) { - $_data->plugin = $this->name; - } - - return $_data; - } - - /** - * Convert some objects to arrays when injecting data into the update API - * - * Some data like sections, banners, and icons are expected to be an associative array, however due to the JSON - * decoding, they are objects. This method allows us to pass in the object and return an associative array. - * - * @since 3.6.5 - * - * @param stdClass $data - * - * @return array - */ - private function convert_object_to_array( $data ) { - if ( ! is_array( $data ) && ! is_object( $data ) ) { - return array(); - } - $new_data = array(); - foreach ( $data as $key => $value ) { - $new_data[ $key ] = is_object( $value ) ? $this->convert_object_to_array( $value ) : $value; - } - - return $new_data; - } - - /** - * Disable SSL verification in order to prevent download update failures - * - * @param array $args - * @param string $url - * @return object $array - */ - public function http_request_args( $args, $url ) { - - if ( strpos( $url, 'https://' ) !== false && strpos( $url, 'edd_action=package_download' ) ) { - $args['sslverify'] = $this->verify_ssl(); - } - return $args; - - } - - /** - * Calls the API and, if successfull, returns the object delivered by the API. - * - * @uses get_bloginfo() - * @uses wp_remote_post() - * @uses is_wp_error() - * - * @param string $_action The requested action. - * @param array $_data Parameters for the API action. - * @return false|object|void - */ - private function api_request( $_action, $_data ) { - $data = array_merge( $this->api_data, $_data ); - - if ( $data['slug'] !== $this->slug ) { - return; - } - - // Don't allow a plugin to ping itself - if ( trailingslashit( home_url() ) === $this->api_url ) { - return false; - } - - if ( $this->request_recently_failed() ) { - return false; - } - - return $this->get_version_from_remote(); - } - - /** - * Determines if a request has recently failed. - * - * @since 1.9.1 - * - * @return bool - */ - private function request_recently_failed() { - $failed_request_details = get_option( $this->failed_request_cache_key ); - - // Request has never failed. - if ( empty( $failed_request_details ) || ! is_numeric( $failed_request_details ) ) { - return false; - } - - /* - * Request previously failed, but the timeout has expired. - * This means we're allowed to try again. - */ - if ( time() > $failed_request_details ) { - delete_option( $this->failed_request_cache_key ); - - return false; - } - - return true; - } - - /** - * Logs a failed HTTP request for this API URL. - * We set a timestamp for 1 hour from now. This prevents future API requests from being - * made to this domain for 1 hour. Once the timestamp is in the past, API requests - * will be allowed again. This way if the site is down for some reason we don't bombard - * it with failed API requests. - * - * @see EDD_SL_Plugin_Updater::request_recently_failed - * - * @since 1.9.1 - */ - private function log_failed_request() { - update_option( $this->failed_request_cache_key, strtotime( '+1 hour' ) ); - } - - /** - * If available, show the changelog for sites in a multisite install. - */ - public function show_changelog() { - - if ( empty( $_REQUEST['edd_sl_action'] ) || 'view_plugin_changelog' !== $_REQUEST['edd_sl_action'] ) { - return; - } - - if ( empty( $_REQUEST['plugin'] ) ) { - return; - } - - if ( empty( $_REQUEST['slug'] ) || $this->slug !== $_REQUEST['slug'] ) { - return; - } - - if ( ! current_user_can( 'update_plugins' ) ) { - wp_die( esc_html__( 'You do not have permission to install plugin updates', 'easy-digital-downloads' ), esc_html__( 'Error', 'easy-digital-downloads' ), array( 'response' => 403 ) ); - } - - $version_info = $this->get_repo_api_data(); - if ( isset( $version_info->sections ) ) { - $sections = $this->convert_object_to_array( $version_info->sections ); - if ( ! empty( $sections['changelog'] ) ) { - echo '
    ' . wp_kses_post( $sections['changelog'] ) . '
    '; - } - } - - exit; - } - - /** - * Gets the current version information from the remote site. - * - * @return array|false - */ - private function get_version_from_remote() { - $api_params = array( - 'edd_action' => 'get_version', - 'license' => ! empty( $this->api_data['license'] ) ? $this->api_data['license'] : '', - 'item_name' => isset( $this->api_data['item_name'] ) ? $this->api_data['item_name'] : false, - 'item_id' => isset( $this->api_data['item_id'] ) ? $this->api_data['item_id'] : false, - 'version' => isset( $this->api_data['version'] ) ? $this->api_data['version'] : false, - 'slug' => $this->slug, - 'author' => $this->api_data['author'], - 'url' => home_url(), - 'beta' => $this->beta, - 'php_version' => phpversion(), - 'wp_version' => get_bloginfo( 'version' ), - ); - - /** - * Filters the parameters sent in the API request. - * - * @param array $api_params The array of data sent in the request. - * @param array $this->api_data The array of data set up in the class constructor. - * @param string $this->plugin_file The full path and filename of the file. - */ - $api_params = apply_filters( 'edd_sl_plugin_updater_api_params', $api_params, $this->api_data, $this->plugin_file ); - - $request = wp_remote_post( - $this->api_url, - array( - 'timeout' => 15, - 'sslverify' => $this->verify_ssl(), - 'body' => $api_params, - ) - ); - - if ( is_wp_error( $request ) || ( 200 !== wp_remote_retrieve_response_code( $request ) ) ) { - $this->log_failed_request(); - - return false; - } - - $request = json_decode( wp_remote_retrieve_body( $request ) ); - - if ( $request && isset( $request->sections ) ) { - $request->sections = maybe_unserialize( $request->sections ); - } else { - $request = false; - } - - if ( $request && isset( $request->banners ) ) { - $request->banners = maybe_unserialize( $request->banners ); - } - - if ( $request && isset( $request->icons ) ) { - $request->icons = maybe_unserialize( $request->icons ); - } - - if ( ! empty( $request->sections ) ) { - foreach ( $request->sections as $key => $section ) { - $request->$key = (array) $section; - } - } - - return $request; - } - - /** - * Get the version info from the cache, if it exists. - * - * @param string $cache_key - * @return object - */ - public function get_cached_version_info( $cache_key = '' ) { - - if ( empty( $cache_key ) ) { - $cache_key = $this->get_cache_key(); - } - - $cache = get_option( $cache_key ); - - // Cache is expired - if ( empty( $cache['timeout'] ) || time() > $cache['timeout'] ) { - return false; - } - - // We need to turn the icons into an array, thanks to WP Core forcing these into an object at some point. - $cache['value'] = json_decode( $cache['value'] ); - if ( ! empty( $cache['value']->icons ) ) { - $cache['value']->icons = (array) $cache['value']->icons; - } - - return $cache['value']; - - } - - /** - * Adds the plugin version information to the database. - * - * @param string $value - * @param string $cache_key - */ - public function set_version_info_cache( $value = '', $cache_key = '' ) { - - if ( empty( $cache_key ) ) { - $cache_key = $this->get_cache_key(); - } - - $data = array( - 'timeout' => strtotime( '+3 hours', time() ), - 'value' => wp_json_encode( $value ), - ); - - update_option( $cache_key, $data, 'no' ); - - // Delete the duplicate option - delete_option( 'edd_api_request_' . md5( serialize( $this->slug . $this->api_data['license'] . $this->beta ) ) ); - } - - /** - * Returns if the SSL of the store should be verified. - * - * @since 1.6.13 - * @return bool - */ - private function verify_ssl() { - return (bool) apply_filters( 'edd_sl_api_request_verify_ssl', true, $this ); - } - - /** - * Gets the unique key (option name) for a plugin. - * - * @since 1.9.0 - * @return string - */ - private function get_cache_key() { - $string = $this->slug . $this->api_data['license'] . $this->beta; - - return 'edd_sl_' . md5( serialize( $string ) ); - } - -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer-helpers.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer-helpers.php deleted file mode 100644 index 7bdb8f16..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer-helpers.php +++ /dev/null @@ -1,531 +0,0 @@ - wp_create_nonce( 'gp_customize_nonce' ) ) ); - wp_localize_script( 'generatepress-pro-typography-customizer', 'typography_defaults', generate_typography_default_fonts() ); - wp_localize_script( - 'generatepress-pro-typography-customizer', - 'generatePressTypography', - array( - 'googleFonts' => apply_filters( 'generate_typography_customize_list', generate_get_all_google_fonts( $number_of_fonts ) ) - ) - ); - } - - wp_enqueue_script( 'generatepress-pro-customizer-controls', plugin_dir_url( __FILE__ ) . 'customizer/controls/js/generatepress-controls.js', array( 'customize-controls', 'jquery' ), GP_PREMIUM_VERSION, true ); - - $overlay_defaults = apply_filters( 'generate_off_canvas_overlay_style_defaults', array( - 'backgroundColor' => 'rgba(10,10,10,0.95)', - 'textColor' => '#ffffff', - 'backgroundHoverColor' => 'rgba(0,0,0,0)', - 'backgroundCurrentColor' => 'rgba(0,0,0,0)', - 'subMenuBackgroundColor' => 'rgba(0,0,0,0)', - 'subMenuTextColor' => '#ffffff', - 'subMenuBackgroundHoverColor' => 'rgba(0,0,0,0)', - 'subMenuBackgroundCurrentColor' => 'rgba(0,0,0,0)', - 'fontWeight' => 200, - 'fontSize' => 25, - ) ); - - wp_localize_script( - 'gp-button-actions', - 'gpButtonActions', - array( - 'warning' => esc_html__( 'This will design your overlay by changing options in the Customizer for you. Once saved, this can not be undone.', 'gp-premium' ), - 'styling' => $overlay_defaults, - ) - ); - - $controls_a11y = array( - 'fontSizeLabel' => esc_html__( 'Font size', 'gp-premium' ), - 'mobileHeaderFontSizeLabel' => esc_html__( 'Mobile header font size', 'gp-premium' ), - ); - - if ( function_exists( 'generate_get_default_fonts' ) ) { - $font_defaults = generate_get_default_fonts(); - - $controls_a11y['siteTitleFontSize'] = $font_defaults['site_title_font_size']; - $controls_a11y['mobileSiteTitleFontSize'] = $font_defaults['mobile_site_title_font_size']; - } - - if ( function_exists( 'generate_get_color_defaults' ) ) { - $color_defaults = generate_get_color_defaults(); - - $controls_a11y['navigationTextColor'] = $color_defaults['navigation_text_color']; - $controls_a11y['siteTitleTextColor'] = $color_defaults['site_title_color']; - } - - if ( function_exists( 'generate_get_defaults' ) ) { - $defaults = generate_get_defaults(); - - $controls_a11y['navigationAlignment'] = $defaults['nav_alignment_setting']; - } - - wp_localize_script( - 'generatepress-pro-customizer-controls', - 'gpControls', - $controls_a11y - ); - - wp_enqueue_script( - 'generate-pro-customizer-controls', - GP_PREMIUM_DIR_URL . 'dist/customizer.js', - array( 'customize-controls', 'wp-i18n', 'wp-element', 'customize-base' ), - GP_PREMIUM_VERSION, - true - ); - - if ( function_exists( 'wp_set_script_translations' ) ) { - wp_set_script_translations( 'generate-pro-customizer-controls', 'gp-premium' ); - } - - wp_localize_script( - 'generate-pro-customizer-controls', - 'gpCustomizerControls', - array( - 'hasSecondaryNav' => generatepress_is_module_active( 'generate_package_secondary_nav', 'GENERATE_SECONDARY_NAV' ), - 'hasMenuPlus' => generatepress_is_module_active( 'generate_package_menu_plus', 'GENERATE_MENU_PLUS' ), - 'hasWooCommerce' => class_exists( 'WooCommerce' ) && generatepress_is_module_active( 'generate_package_woocommerce', 'GENERATE_WOOCOMMERCE' ), - ) - ); -} - -add_action( 'customize_register', 'generate_premium_customizer_shortcut_controls', 100 ); -/** - * Add shortcuts to sections we don't control in this plugin. - * - * @since 1.8 - */ -function generate_premium_customizer_shortcut_controls( $wp_customize ) { - if ( ! class_exists( 'WP_Customize_Panel' ) ) { - return; - } - - if ( ! $wp_customize->get_panel( 'generate_layout_panel' ) ) { - return; - } - - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_header_layout_shortcuts', - array( - 'section' => 'generate_layout_header', - 'element' => __( 'Header', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'header_color_section', - 'typography' => 'font_header_section', - 'backgrounds' => 'generate_backgrounds_header', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_primary_navigation_layout_shortcuts', - array( - 'section' => 'generate_layout_navigation', - 'element' => __( 'Primary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'navigation_color_section', - 'typography' => 'font_navigation_section', - 'backgrounds' => 'generate_backgrounds_navigation', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - if ( $wp_customize->get_control( 'blogname' ) ) { - $wp_customize->get_control( 'generate_settings[container_width]' )->priority = 1; - } - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_content_layout_shortcuts', - array( - 'section' => 'generate_layout_container', - 'element' => __( 'Content', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'content_color_section', - 'typography' => 'font_content_section', - 'backgrounds' => 'generate_backgrounds_content', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_sidebar_layout_shortcuts', - array( - 'section' => 'generate_layout_sidebars', - 'element' => __( 'Sidebar', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'sidebar_widget_color_section', - 'typography' => 'font_widget_section', - 'backgrounds' => 'generate_backgrounds_sidebars', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_footer_layout_shortcuts', - array( - 'section' => 'generate_layout_footer', - 'element' => __( 'Footer', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'footer_color_section', - 'typography' => 'font_footer_section', - 'backgrounds' => 'generate_backgrounds_footer', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_colors_shortcuts', - array( - 'section' => 'generate_colors_section', - 'element' => __( 'Colors', 'gp-premium' ), - 'shortcuts' => array(), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_typography_shortcuts', - array( - 'section' => 'generate_typography_section', - 'element' => __( 'Typography', 'gp-premium' ), - 'shortcuts' => array(), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); -} - -add_action( 'customize_register', 'generate_premium_layout_block_element_messages', 1000 ); -/** - * Add shortcuts to sections we don't control in this plugin. - * - * @since 1.8 - */ -function generate_premium_layout_block_element_messages( $wp_customize ) { - if ( ! class_exists( 'WP_Customize_Panel' ) ) { - return; - } - - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Information_Customize_Control' ); - } - - if ( version_compare( PHP_VERSION, '5.6', '>=' ) ) { - $footer_sections = array( - 'generate_layout_footer', - 'footer_color_section', - 'font_footer_section', - 'generate_backgrounds_footer', - ); - - foreach ( $footer_sections as $section ) { - if ( $wp_customize->get_section( $section ) ) { - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_site_footer_element_' . $section, - array( - 'section' => $section, - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Site Footer Element. Some of the options below may not apply.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - $has_block_element = generate_has_active_element( 'site-footer', true ); - - if ( $has_block_element ) { - return true; - } - - return false; - }, - 'priority' => 0, - ) - ) - ); - } - } - - $header_sections = array( - 'generate_layout_header', - 'header_color_section', - 'font_header_section', - 'generate_backgrounds_header', - ); - - foreach ( $header_sections as $section ) { - if ( $wp_customize->get_section( $section ) ) { - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_site_header_element_' . $section, - array( - 'section' => $section, - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Site Header Element. Some of the options below may not apply.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - $has_block_element = generate_has_active_element( 'site-header', true ); - - if ( $has_block_element ) { - return true; - } - - return false; - }, - 'priority' => 0, - ) - ) - ); - } - } - - $sidebar_sections = array( - 'generate_layout_sidebars', - 'sidebar_widget_color_section', - 'font_widget_section', - 'generate_backgrounds_sidebars', - ); - - foreach ( $sidebar_sections as $section ) { - if ( $wp_customize->get_section( $section ) ) { - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_sidebar_element_' . $section, - array( - 'section' => $section, - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Sidebar Element. Some of the options below may not apply.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - $has_right_sidebar_block_element = generate_has_active_element( 'right-sidebar', true ); - - if ( $has_right_sidebar_block_element ) { - return true; - } - - $has_left_sidebar_block_element = generate_has_active_element( 'left-sidebar', true ); - - if ( $has_left_sidebar_block_element ) { - return true; - } - - return false; - }, - 'priority' => 0, - ) - ) - ); - } - } - - if ( $wp_customize->get_section( 'generate_blog_section' ) ) { - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_post_loop_item_element', - array( - 'section' => 'generate_blog_section', - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Content Template Element. Some of the options below may not apply.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - $has_block_element = generate_has_active_element( 'content-template', true ); - - if ( $has_block_element ) { - return true; - } - - return false; - }, - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_page_hero_element', - array( - 'section' => 'generate_blog_section', - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Page Hero Element. Some of the options below may not apply.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - $has_block_element = generate_has_active_element( 'page-hero', true ); - - if ( $has_block_element ) { - return true; - } - - return false; - }, - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Information_Customize_Control( - $wp_customize, - 'generate_using_post_meta_area_element', - array( - 'section' => 'generate_blog_section', - 'description' => sprintf( - /* translators: URL to the Elements dashboard. */ - __( 'This page is using a Post Meta Template Element. Some of the options below may not apply.', 'gp-premium' ), - admin_url( 'edit.php?post_type=gp_elements' ) - ), - 'notice' => true, - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'active_callback' => function() { - $has_block_element = generate_has_active_element( 'post-meta-template', true ); - - if ( $has_block_element ) { - return true; - } - - return false; - }, - 'priority' => 0, - ) - ) - ); - } - } -} - -add_action( 'customize_controls_print_styles', 'generate_premium_customize_print_styles' ); -/** - * Print control styles for the Customizer. - * - * @since 1.9 - */ -function generate_premium_customize_print_styles() { - $sizes = apply_filters( 'generate_customizer_device_preview_sizes', array( - 'tablet' => 800, - 'mobile' => 411, - 'mobile_height' => 731, - ) ); - ?> - - json['data_type'] = $this->data_type; - $this->json['description'] = $this->description; - $this->json['nonce'] = $this->nonce; - } - - public function content_template() { - ?> - - <# if ( data.description ) { #> - -

    {{{ data.description }}}

    -
    - <# } #> - json['palette'] = $this->palette; - $this->json['defaultValue'] = $this->setting->default; - $this->json[ 'link' ] = $this->get_link(); - $this->json[ 'show_opacity' ] = $this->show_opacity; - - if ( is_array( $this->json['palette'] ) ) { - $this->json['palette'] = implode( '|', $this->json['palette'] ); - } else { - // Default to true. - $this->json['palette'] = ( false === $this->json['palette'] || 'false' === $this->json['palette'] ) ? 'false' : 'true'; - } - - // Support passing show_opacity as string or boolean. Default to true. - $this->json[ 'show_opacity' ] = ( false === $this->json[ 'show_opacity' ] || 'false' === $this->json[ 'show_opacity' ] ) ? 'false' : 'true'; - } - - /** - * Render the control. - */ - public function render_content() {} - - public function content_template() { - ?> - <# if ( data.label && '' !== data.label ) { #> - {{ data.label }} - <# } #> - - json[ 'position_title' ] = esc_html__( 'left top, x% y%, xpos ypos (px)', 'gp-premium' ); - $this->json[ 'position_placeholder' ] = esc_html__( 'Position', 'gp-premium' ); - - foreach ( $this->settings as $setting_key => $setting_id ) { - $this->json[ $setting_key ] = array( - 'link' => $this->get_link( $setting_key ), - 'value' => $this->value( $setting_key ), - 'default' => isset( $setting_id->default ) ? $setting_id->default : '', - 'id' => isset( $setting_id->id ) ? $setting_id->id : '' - ); - - if ( 'repeat' === $setting_key ) { - $this->json[ $setting_key ]['choices'] = $this->get_repeat_choices(); - } - - if ( 'size' === $setting_key ) { - $this->json[ $setting_key ]['choices'] = $this->get_size_choices(); - } - - if ( 'attachment' === $setting_key ) { - $this->json[ $setting_key ]['choices'] = $this->get_attachment_choices(); - } - } - } - - public function content_template() { - ?> - <# if ( '' !== data.label ) { #> - {{ data.label }} - <# } #> - - <# if ( 'undefined' !== typeof ( data.repeat ) ) { #> -
    - -
    - <# } #> - - <# if ( 'undefined' !== typeof ( data.size ) ) { #> -
    - -
    - <# } #> - - <# if ( 'undefined' !== typeof ( data.attachment ) ) { #> -
    - -
    - <# } #> - - <# if ( 'undefined' !== typeof ( data.position ) ) { #> -
    - -
    - <# } #> - esc_html__( 'Repeat', 'gp-premium' ), - 'repeat-x' => esc_html__( 'Repeat x', 'gp-premium' ), - 'repeat-y' => esc_html__( 'Repeat y', 'gp-premium' ), - 'no-repeat' => esc_html__( 'No Repeat', 'gp-premium' ) - ); - } - - public function get_size_choices() { - return array( - '' => esc_html__( 'Size (Auto)', 'gp-premium' ), - '100' => esc_html__( '100% Width', 'gp-premium' ), - 'cover' => esc_html__( 'Cover', 'gp-premium' ), - 'contain' => esc_html__( 'Contain', 'gp-premium' ) - ); - } - - public function get_attachment_choices() { - return array( - '' => esc_html__( 'Attachment', 'gp-premium' ), - 'fixed' => esc_html__( 'Fixed', 'gp-premium' ), - 'local' => esc_html__( 'Local', 'gp-premium' ), - 'inherit' => esc_html__( 'Inherit', 'gp-premium' ) - ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/class-control-toggle.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/class-control-toggle.php deleted file mode 100644 index 7c893a6e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/class-control-toggle.php +++ /dev/null @@ -1,37 +0,0 @@ -json[ 'targets' ] = $this->targets; - - } - - public function content_template() { - ?> -
    - <# jQuery.each( data.targets, function( index, value ) { #> - - <# } ); #> -
    - json[ 'link' ] = $this->get_link(); - $this->json[ 'value' ] = $this->value(); - $this->json[ 'id' ] = $this->id; - $this->json[ 'current_year' ] = __( '%current_year% to update year automatically.', 'gp-premium' ); - $this->json[ 'copyright' ] = __( '%copy% to include the copyright symbol.', 'gp-premium' ); - $this->json[ 'html' ] = __( 'HTML is allowed.', 'gp-premium' ); - $this->json[ 'shortcodes' ] = __( 'Shortcodes are allowed.', 'gp-premium' ); - } - /** - * Render the control's content. - * - * Allows the content to be overriden without having to rewrite the wrapper. - * - * @since 10/16/2012 - * @return void - */ - public function content_template() { - ?> - - json[ 'link' ] = $this->get_link(); - $this->json[ 'value' ] = $this->value(); - $this->json[ 'id' ] = $this->id; - $this->json[ 'default_value' ] = $this->default_value; - $this->json[ 'reset_title' ] = esc_attr__( 'Reset','generate-spacing' ); - $this->json[ 'unit' ] = $this->unit; - $this->json[ 'edit_field' ] = $this->edit_field; - } - - public function content_template() { - ?> - -
    - <# if ( '' !== data.default_value ) { #>{{ data.reset_title }}<# } #> - json[ 'link' ] = $this->get_link(); - $this->json[ 'value' ] = absint( $this->value() ); - $this->json[ 'description' ] = esc_html( $this->description ); - } - - public function content_template() { - ?> - - type ) { - default: - case 'text' : ?> - - label ) ) echo '' . esc_html( $this->label ) . ''; - if ( ! empty( $this->description ) ) echo '' . esc_html( $this->description ) . ''; - if ( ! empty( $this->areas ) ) : - echo '
    '; - foreach ( $this->areas as $value => $label ) : - echo '' . esc_html( $label ) . ''; - endforeach; - endif; - break; - - case 'line' : - echo '
    '; - break; - } - } -} -endif; - -if ( class_exists( 'WP_Customize_Control' ) && ! class_exists( 'Generate_Backgrounds_Customize_Control' ) ) : -/* - * @deprecated 1.3 - */ -class Generate_Backgrounds_Customize_Control extends WP_Customize_Control { - public function render() {} -} -endif; - -if ( class_exists( 'WP_Customize_Control' ) && ! class_exists( 'Generate_Backgrounds_Customize_Misc_Control' ) ) : -/* - * No longer used - * Kept for back compat purposes - * @deprecated 1.2.95 - */ -class Generate_Backgrounds_Customize_Misc_Control extends WP_Customize_Control { - public function render() {} -} -endif; - -if ( class_exists( 'WP_Customize_Control' ) && ! class_exists( 'Generate_Blog_Customize_Control' ) ) : -/** - * Add our number input field for the featured image width - * @deprecated 1.3 - */ -class Generate_Blog_Customize_Control extends WP_Customize_Control { - public $type = 'gp-post-image-size'; - public $placeholder = ''; - - public function enqueue() { - wp_enqueue_script( 'gp-blog-customizer', trailingslashit( plugin_dir_url( __FILE__ ) ) . 'js/blog-customizer.js', array( 'customize-controls' ), GENERATE_BLOG_VERSION, true ); - } - - public function to_json() { - parent::to_json(); - $this->json[ 'link' ] = $this->get_link(); - $this->json[ 'value' ] = $this->value(); - $this->json[ 'placeholder' ] = $this->placeholder; - } - public function content_template() { - ?> - - json[ 'link' ] = $this->get_link(); - $this->json[ 'value' ] = $this->value(); - $this->json[ 'placeholder' ] = $this->placeholder; - } - public function content_template() { - ?> - - json[ 'text' ] = __( 'Apply image sizes','page-header' ); - } - - public function content_template() { - ?> - {{{ data.text }}} - json[ 'link' ] = $this->get_link(); - $this->json[ 'value' ] = $this->value(); - $this->json[ 'id' ] = $this->id; - } - - public function content_template() { - ?> - - - - - - json['description'] = $this->description; - $this->json['notice'] = $this->notice; - } - - public function content_template() { - ?> - <# if ( data.notice ) { #> -
    - <# } #> - - <# if ( data.label ) { #> - {{ data.label }} - <# } #> - <# if ( data.description ) { #> -

    {{{ data.description }}}

    - <# } #> - - <# if ( data.notice ) { #> -
    - <# } #> - json['choices'][$device]['min'] = ( isset( $this->choices[$device]['min'] ) ) ? $this->choices[$device]['min'] : '0'; - $this->json['choices'][$device]['max'] = ( isset( $this->choices[$device]['max'] ) ) ? $this->choices[$device]['max'] : '100'; - $this->json['choices'][$device]['step'] = ( isset( $this->choices[$device]['step'] ) ) ? $this->choices[$device]['step'] : '1'; - $this->json['choices'][$device]['edit'] = ( isset( $this->choices[$device]['edit'] ) ) ? $this->choices[$device]['edit'] : false; - $this->json['choices'][$device]['unit'] = ( isset( $this->choices[$device]['unit'] ) ) ? $this->choices[$device]['unit'] : false; - } - - foreach ( $this->settings as $setting_key => $setting_id ) { - $this->json[ $setting_key ] = array( - 'link' => $this->get_link( $setting_key ), - 'value' => $this->value( $setting_key ), - 'default' => isset( $setting_id->default ) ? $setting_id->default : '', - ); - } - - $this->json['desktop_label'] = __( 'Desktop', 'gp-premium' ); - $this->json['tablet_label'] = __( 'Tablet', 'gp-premium' ); - $this->json['mobile_label'] = __( 'Mobile', 'gp-premium' ); - $this->json['reset_label'] = __( 'Reset', 'gp-premium' ); - - $this->json['description'] = $this->description; - $this->json['sub_description'] = $this->sub_description; - } - /** - * Enqueue control related scripts/styles. - * - * @access public - */ - public function enqueue() { - wp_enqueue_script( 'generatepress-pro-range-slider', trailingslashit( plugin_dir_url( __FILE__ ) ) . 'js/slider-customizer.js', array( 'jquery', 'customize-base', 'jquery-ui-slider' ), GP_PREMIUM_VERSION, true ); - wp_enqueue_style( 'generatepress-pro-range-slider-css', trailingslashit( plugin_dir_url( __FILE__ ) ) . 'css/slider-customizer.css', GP_PREMIUM_VERSION ); - } - /** - * An Underscore (JS) template for this control's content (but not its container). - * - * Class variables for this control class are available in the `data` JS object; - * export custom variables by overriding {@see WP_Customize_Control::to_json()}. - * - * @see WP_Customize_Control::print_template() - * - * @access protected - */ - protected function content_template() { - ?> -
    -
    - <# if ( data.label || data.description ) { #> -
    - <# if ( data.label ) { #> - {{{ data.label }}} - <# } #> - - <# if ( data.description ) { #> -

    {{{ data.description }}}

    - <# } #> -
    - <# } #> - -
    - - <# if ( 'undefined' !== typeof ( data.desktop ) ) { #> - - <# } #> - - <# if ( 'undefined' !== typeof (data.tablet) ) { #> - - <# } #> - - <# if ( 'undefined' !== typeof (data.mobile) ) { #> - - <# } #> - - - -
    -
    - -
    - <# if ( 'undefined' !== typeof ( data.desktop ) ) { #> - - <# } #> - - <# if ( 'undefined' !== typeof ( data.tablet ) ) { #> - - <# } #> - - <# if ( 'undefined' !== typeof ( data.mobile ) ) { #> - - <# } #> -
    - - <# if ( data.sub_description ) { #> -

    {{{ data.sub_description }}}

    - <# } #> -
    - - {{{ data.label }}} - shortcuts as $name => $id ) { - if ( 'colors' === $name ) { - $name = esc_html__( 'Colors', 'gp-premium' ); - - if ( version_compare( generate_premium_get_theme_version(), '3.1.0-alpha.1', '>=' ) && 'generate_woocommerce_colors' !== $id ) { - $id = 'generate_colors_section'; - } - - if ( ! generatepress_is_module_active( 'generate_package_colors', 'GENERATE_COLORS' ) ) { - $id = false; - $name = false; - } - } - - if ( 'typography' === $name ) { - $name = esc_html__( 'Typography', 'gp-premium' ); - - if ( function_exists( 'generate_is_using_dynamic_typography' ) && generate_is_using_dynamic_typography() ) { - $id = 'generate_typography_section'; - } - - if ( ! generatepress_is_module_active( 'generate_package_typography', 'GENERATE_TYPOGRAPHY' ) ) { - $id = false; - $name = false; - } - } - - if ( 'backgrounds' === $name ) { - $name = esc_html__( 'Backgrounds', 'gp-premium' ); - - if ( ! generatepress_is_module_active( 'generate_package_backgrounds', 'GENERATE_BACKGROUNDS' ) ) { - $id = false; - $name = false; - } - } - - if ( 'layout' === $name ) { - $name = esc_html__( 'Layout', 'gp-premium' ); - } - - if ( $id && $name ) { - $shortcuts[ $id ] = $name; - } - } - - if ( ! empty( $shortcuts ) ) { - $this->json['shortcuts'] = $shortcuts; - } else { - $this->json['shortcuts'] = false; - } - - if ( 'WooCommerce' !== $this->element ) { - $this->element = strtolower( $this->element ); - } - - $this->json['more'] = sprintf( - __( 'More %s controls:', 'gp-premium' ), - '' . $this->element . '' - ); - - $this->json['return'] = __( 'Go Back', 'gp-premium' ); - - $this->json['section'] = $this->section; - - if ( apply_filters( 'generate_disable_customizer_shortcuts', false ) ) { - $this->json['shortcuts'] = false; - } - } - - public function content_template() { - ?> -
    - <# if ( data.shortcuts ) { #> -
    - - {{{ data.more }}} - - - - <# _.each( data.shortcuts, function( label, section ) { #> - - {{{ label }}} - - <# } ) #> - -
    - <# } #> - - -
    - - settings as $setting_key => $setting_id ) { - $this->json[ $setting_key ] = array( - 'link' => $this->get_link( $setting_key ), - 'value' => $this->value( $setting_key ) - ); - } - - $this->json[ 'element' ] = $this->element; - $this->json[ 'title' ] = __( 'Link values', 'gp-premium' ); - $this->json[ 'unlink_title' ] = __( 'Un-link values', 'gp-premium' ); - - $this->json['label_top'] = esc_html__( 'Top', 'gp-premium' ); - $this->json['label_right'] = esc_html__( 'Right', 'gp-premium' ); - $this->json['label_bottom'] = esc_html__( 'Bottom', 'gp-premium' ); - $this->json['label_left'] = esc_html__( 'Left', 'gp-premium' ); - $this->json['desktop_label'] = esc_html__( 'Desktop', 'gp-premium' ); - $this->json['tablet_label'] = esc_html__( 'Tablet', 'gp-premium' ); - $this->json['mobile_label'] = esc_html__( 'Mobile', 'gp-premium' ); - } - - public function content_template() { - ?> -
    -
    - <# if ( data.label || data.description ) { #> -
    - <# if ( data.label ) { #> - - <# } #> - - <# if ( data.description ) { #> - {{{ data.description }}} - <# } #> -
    - <# } #> - -
    - - <# if ( 'undefined' !== typeof ( data.desktop_top ) ) { #> - - <# } #> - - <# if ( 'undefined' !== typeof (data.tablet_top) ) { #> - - <# } #> - - <# if ( 'undefined' !== typeof (data.mobile_top) ) { #> - - <# } #> - -
    -
    - -
    - - - <# if ( 'undefined' !== typeof ( data.mobile_top ) ) { #> - - <# } #> -
    -
    - json[ 'title' ] = esc_html( $this->title ); - } - - public function content_template() { - ?> -
    - {{ data.title }} -
    - json[ 'default_fonts_title'] = __( 'System Fonts', 'gp-premium' ); - $this->json[ 'google_fonts_title'] = __( 'Google Fonts', 'gp-premium' ); - $this->json[ 'default_fonts' ] = generate_typography_default_fonts(); - $this->json[ 'family_title' ] = esc_html__( 'Font family', 'gp-premium' ); - $this->json[ 'weight_title' ] = esc_html__( 'Font weight', 'gp-premium' ); - $this->json[ 'transform_title' ] = esc_html__( 'Text transform', 'gp-premium' ); - $this->json[ 'category_title' ] = ''; - $this->json[ 'variant_title' ] = esc_html__( 'Variants', 'gp-premium' ); - - foreach ( $this->settings as $setting_key => $setting_id ) { - $this->json[ $setting_key ] = array( - 'link' => $this->get_link( $setting_key ), - 'value' => $this->value( $setting_key ), - 'default' => isset( $setting_id->default ) ? $setting_id->default : '', - 'id' => isset( $setting_id->id ) ? $setting_id->id : '' - ); - - if ( 'weight' === $setting_key ) { - $this->json[ $setting_key ]['choices'] = $this->get_font_weight_choices(); - } - - if ( 'transform' === $setting_key ) { - $this->json[ $setting_key ]['choices'] = $this->get_font_transform_choices(); - } - } - } - - public function content_template() { - ?> - <# if ( '' !== data.label ) { #> - {{ data.label }} - <# } #> - <# if ( 'undefined' !== typeof ( data.family ) ) { #> -
    - -
    - <# } #> - - <# if ( 'undefined' !== typeof ( data.variant ) ) { #> - <# - var id = data.family.value.split(' ').join('_').toLowerCase(); - var font_data = generatePressTypography.googleFonts[id]; - var variants = ''; - if ( typeof font_data !== 'undefined' ) { - variants = font_data.variants; - } - - if ( null === data.variant.value ) { - data.variant.value = data.variant.default; - } - #> -
    - -
    - <# } #> - - <# if ( 'undefined' !== typeof ( data.category ) ) { #> -
    - -
    - <# } #> - -
    - <# if ( 'undefined' !== typeof ( data.weight ) ) { #> -
    - -
    - <# } #> - - <# if ( 'undefined' !== typeof ( data.transform ) ) { #> -
    - -
    - <# } #> -
    - esc_html__( 'inherit', 'gp-premium' ), - 'normal' => esc_html__( 'normal', 'gp-premium' ), - 'bold' => esc_html__( 'bold', 'gp-premium' ), - '100' => esc_html( '100' ), - '200' => esc_html( '200' ), - '300' => esc_html( '300' ), - '400' => esc_html( '400' ), - '500' => esc_html( '500' ), - '600' => esc_html( '600' ), - '700' => esc_html( '700' ), - '800' => esc_html( '800' ), - '900' => esc_html( '900' ), - ); - } - - public function get_font_transform_choices() { - return array( - '' => esc_html__( 'inherit', 'gp-premium' ), - 'none' => esc_html__( 'none', 'gp-premium' ), - 'capitalize' => esc_html__( 'capitalize', 'gp-premium' ), - 'uppercase' => esc_html__( 'uppercase', 'gp-premium' ), - 'lowercase' => esc_html__( 'lowercase', 'gp-premium' ), - ); - } -} -endif; diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/alpha-color-picker.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/alpha-color-picker.css deleted file mode 100644 index d820a935..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/alpha-color-picker.css +++ /dev/null @@ -1,32 +0,0 @@ -/** - * Alpha Color Picker CSS - */ -.customize-control-gp-alpha-color .iris-picker .iris-square { - margin-right:10px; -} - -.customize-control-gp-alpha-color .alpha-slider.ui-widget-content, -.customize-control-gp-alpha-color .ui-widget-header{ - background: none; - border: 0; - box-shadow: 0 0 0 transparent; -} - -.alpha-color-picker-wrap a.iris-square-value:focus { - box-shadow: none; -} - -.gp-alpha-color-picker-container { - position: relative; - margin-left: 10px; - background-image: url(transparency-grid.png); -} - -.gp-alpha-color-picker-container .iris-picker .iris-strip .ui-slider-handle { - z-index: 100; -} - -.customize-control-gp-alpha-color .wp-picker-input-wrap .button.wp-picker-clear { - margin-left: 6px; - padding: 2px 8px; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/button-actions.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/button-actions.css deleted file mode 100644 index 4c55423e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/button-actions.css +++ /dev/null @@ -1,19 +0,0 @@ -button[data-type="regenerate_external_css"]:before { - font: normal 20px/.5 dashicons; - display: inline-block; - padding: 0; - top: 9px; - left: -4px; - position: relative; - vertical-align: top; - content: "\f463"; -} - -button[data-type="regenerate_external_css"].loading:before { - animation: rotation 1s infinite linear; -} - -button[data-type="regenerate_external_css"].success:before { - content: "\f147"; - color: #46b450; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/control-toggle-customizer.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/control-toggle-customizer.css deleted file mode 100644 index b27e743b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/control-toggle-customizer.css +++ /dev/null @@ -1,21 +0,0 @@ -.generatepress-control-toggles { - display: flex; -} - -.generatepress-control-toggles button { - flex-basis: 100%; - background-color: #fafafa; - border: 1px solid #ddd; - cursor: pointer; - padding: 5px 10px; -} - -.generatepress-control-toggles button:last-child { - border-left: 0; -} - -.generatepress-control-toggles button.active { - background-color: #fff; - border: 1px solid #ccc; - font-weight: bold; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/information-control.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/information-control.css deleted file mode 100644 index 4d042817..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/information-control.css +++ /dev/null @@ -1,12 +0,0 @@ -.gp-info-notice { - background: #fff; - border: 1px solid #c3c4c7; - border-left-width: 4px; - box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); - margin: 0; - padding: 1px 12px; -} - -.gp-info-notice-info { - border-left-color: #72aee6; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/section-shortcuts.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/section-shortcuts.css deleted file mode 100644 index 71e4c4ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/section-shortcuts.css +++ /dev/null @@ -1,43 +0,0 @@ -.generatepress-shortcuts > div { - background: #fff; - padding: 10px 15px; - border-width: 0 1px 1px 0; - border-color: #ddd; - border-style: solid; - margin-bottom: 10px; -} - -.customize-control-gp_section_shortcut { - margin-bottom: 0; -} - -.generatepress-shortcuts .more-controls { - font-weight: 600; - margin-right: 5px; - display: block; - font-size: 12px; - margin-bottom: 3px; -} - -.generatepress-shortcuts .shortcuts .shortcut:not(:last-child):after { - content: "\2022"; - padding: 0 1px; -} - -.generatepress-shortcuts .shortcut a { - text-decoration: none; -} - -.generatepress-shortcuts .shortcut { - font-size: 12px; -} - -.return-shortcut .dashicons { - float: right; - cursor: pointer; -} - -.return-shortcut a { - font-size: 12px; - text-decoration: none; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/selectWoo.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/selectWoo.min.css deleted file mode 100644 index 59fa33d3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/selectWoo.min.css +++ /dev/null @@ -1 +0,0 @@ -.select2-container{box-sizing:border-box;display:inline-block;margin:0;position:relative;vertical-align:middle}.select2-container .select2-selection--single{box-sizing:border-box;cursor:pointer;display:block;height:28px;user-select:none;-webkit-user-select:none}.select2-container .select2-selection--single .select2-selection__rendered{display:block;padding-left:8px;padding-right:20px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.select2-container .select2-selection--single .select2-selection__clear{position:relative}.select2-container[dir="rtl"] .select2-selection--single .select2-selection__rendered{padding-right:8px;padding-left:20px}.select2-container .select2-selection--multiple{box-sizing:border-box;cursor:pointer;display:block;min-height:32px;user-select:none;-webkit-user-select:none}.select2-container .select2-selection--multiple .select2-selection__rendered{display:inline-block;overflow:hidden;padding-left:8px;text-overflow:ellipsis;white-space:nowrap}.select2-container .select2-search--inline{float:left}.select2-container .select2-search--inline .select2-search__field{box-sizing:border-box;border:none;font-size:100%;margin-top:5px;padding:0}.select2-container .select2-search--inline .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-dropdown{background-color:white;border:1px solid #aaa;border-radius:4px;box-sizing:border-box;display:block;position:absolute;left:-100000px;width:100%;z-index:1051}.select2-results{display:block}.select2-results__options{list-style:none;margin:0;padding:0}.select2-results__option{padding:6px;user-select:none;-webkit-user-select:none}.select2-results__option[data-selected]{cursor:pointer}.select2-container--open .select2-dropdown{left:0}.select2-container--open .select2-dropdown--above{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--open .select2-dropdown--below{border-top:none;border-top-left-radius:0;border-top-right-radius:0}.select2-search--dropdown{display:block;padding:4px}.select2-search--dropdown .select2-search__field{padding:4px;width:100%;box-sizing:border-box}.select2-search--dropdown .select2-search__field::-webkit-search-cancel-button{-webkit-appearance:none}.select2-search--dropdown.select2-search--hide{display:none}.select2-close-mask{border:0;margin:0;padding:0;display:block;position:fixed;left:0;top:0;min-height:100%;min-width:100%;height:auto;width:auto;opacity:0;z-index:99;background-color:#fff;filter:alpha(opacity=0)}.select2-hidden-accessible{border:0 !important;clip:rect(0 0 0 0) !important;height:1px !important;margin:-1px !important;overflow:hidden !important;padding:0 !important;position:absolute !important;width:1px !important}.select2-container--default .select2-selection--single{background-color:#fff;border:1px solid #aaa;border-radius:4px}.select2-container--default .select2-selection--single .select2-selection__rendered{color:#444;line-height:28px}.select2-container--default .select2-selection--single .select2-selection__clear{cursor:pointer;float:right;font-weight:bold}.select2-container--default .select2-selection--single .select2-selection__placeholder{color:#999}.select2-container--default .select2-selection--single .select2-selection__arrow{height:26px;position:absolute;top:1px;right:1px;width:20px}.select2-container--default .select2-selection--single .select2-selection__arrow b{border-color:#888 transparent transparent transparent;border-style:solid;border-width:5px 4px 0 4px;height:0;left:50%;margin-left:-4px;margin-top:-2px;position:absolute;top:50%;width:0}.select2-container--default[dir="rtl"] .select2-selection--single .select2-selection__clear{float:left}.select2-container--default[dir="rtl"] .select2-selection--single .select2-selection__arrow{left:1px;right:auto}.select2-container--default.select2-container--disabled .select2-selection--single{background-color:#eee;cursor:default}.select2-container--default.select2-container--disabled .select2-selection--single .select2-selection__clear{display:none}.select2-container--default.select2-container--open .select2-selection--single .select2-selection__arrow b{border-color:transparent transparent #888 transparent;border-width:0 4px 5px 4px}.select2-container--default .select2-selection--multiple{background-color:white;border:1px solid #aaa;border-radius:4px;cursor:text}.select2-container--default .select2-selection--multiple .select2-selection__rendered{box-sizing:border-box;list-style:none;margin:0;padding:0 5px;width:100%}.select2-container--default .select2-selection--multiple .select2-selection__rendered li{list-style:none}.select2-container--default .select2-selection--multiple .select2-selection__placeholder{color:#999;margin-top:5px;float:left}.select2-container--default .select2-selection--multiple .select2-selection__clear{cursor:pointer;float:right;font-weight:bold;margin-top:5px;margin-right:10px}.select2-container--default .select2-selection--multiple .select2-selection__choice{background-color:#e4e4e4;border:1px solid #aaa;border-radius:4px;cursor:default;float:left;margin-right:5px;margin-top:5px;padding:0 5px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove{color:#999;cursor:pointer;display:inline-block;font-weight:bold;margin-right:2px}.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover{color:#333}.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__choice,.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__placeholder,.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-search--inline{float:right}.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__choice{margin-left:5px;margin-right:auto}.select2-container--default[dir="rtl"] .select2-selection--multiple .select2-selection__choice__remove{margin-left:2px;margin-right:auto}.select2-container--default.select2-container--focus .select2-selection--multiple{border:solid black 1px;outline:0}.select2-container--default.select2-container--disabled .select2-selection--multiple{background-color:#eee;cursor:default}.select2-container--default.select2-container--disabled .select2-selection__choice__remove{display:none}.select2-container--default.select2-container--open.select2-container--above .select2-selection--single,.select2-container--default.select2-container--open.select2-container--above .select2-selection--multiple{border-top-left-radius:0;border-top-right-radius:0}.select2-container--default.select2-container--open.select2-container--below .select2-selection--single,.select2-container--default.select2-container--open.select2-container--below .select2-selection--multiple{border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--default .select2-search--dropdown .select2-search__field{border:1px solid #aaa}.select2-container--default .select2-search--inline .select2-search__field{background:transparent;border:none;outline:0;box-shadow:none;-webkit-appearance:textfield}.select2-container--default .select2-results>.select2-results__options{max-height:200px;overflow-y:auto}.select2-container--default .select2-results__option[role=group]{padding:0}.select2-container--default .select2-results__option[aria-disabled=true]{color:#999}.select2-container--default .select2-results__option[data-selected=true]{background-color:#ddd}.select2-container--default .select2-results__option .select2-results__option{padding-left:1em}.select2-container--default .select2-results__option .select2-results__option .select2-results__group{padding-left:0}.select2-container--default .select2-results__option .select2-results__option .select2-results__option{margin-left:-1em;padding-left:2em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-2em;padding-left:3em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-3em;padding-left:4em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-4em;padding-left:5em}.select2-container--default .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option .select2-results__option{margin-left:-5em;padding-left:6em}.select2-container--default .select2-results__option--highlighted[data-selected]{background-color:#5897fb;color:white}.select2-container--default .select2-results__group{cursor:default;display:block;padding:6px}.select2-container--classic .select2-selection--single{background-color:#f7f7f7;border:1px solid #aaa;border-radius:4px;outline:0;background-image:-webkit-linear-gradient(top, #fff 50%, #eee 100%);background-image:-o-linear-gradient(top, #fff 50%, #eee 100%);background-image:linear-gradient(to bottom, #fff 50%, #eee 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFFFFFF', endColorstr='#FFEEEEEE', GradientType=0)}.select2-container--classic .select2-selection--single:focus{border:1px solid #5897fb}.select2-container--classic .select2-selection--single .select2-selection__rendered{color:#444;line-height:28px}.select2-container--classic .select2-selection--single .select2-selection__clear{cursor:pointer;float:right;font-weight:bold;margin-right:10px}.select2-container--classic .select2-selection--single .select2-selection__placeholder{color:#999}.select2-container--classic .select2-selection--single .select2-selection__arrow{background-color:#ddd;border:none;border-left:1px solid #aaa;border-top-right-radius:4px;border-bottom-right-radius:4px;height:26px;position:absolute;top:1px;right:1px;width:20px;background-image:-webkit-linear-gradient(top, #eee 50%, #ccc 100%);background-image:-o-linear-gradient(top, #eee 50%, #ccc 100%);background-image:linear-gradient(to bottom, #eee 50%, #ccc 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFEEEEEE', endColorstr='#FFCCCCCC', GradientType=0)}.select2-container--classic .select2-selection--single .select2-selection__arrow b{border-color:#888 transparent transparent transparent;border-style:solid;border-width:5px 4px 0 4px;height:0;left:50%;margin-left:-4px;margin-top:-2px;position:absolute;top:50%;width:0}.select2-container--classic[dir="rtl"] .select2-selection--single .select2-selection__clear{float:left}.select2-container--classic[dir="rtl"] .select2-selection--single .select2-selection__arrow{border:none;border-right:1px solid #aaa;border-radius:0;border-top-left-radius:4px;border-bottom-left-radius:4px;left:1px;right:auto}.select2-container--classic.select2-container--open .select2-selection--single{border:1px solid #5897fb}.select2-container--classic.select2-container--open .select2-selection--single .select2-selection__arrow{background:transparent;border:none}.select2-container--classic.select2-container--open .select2-selection--single .select2-selection__arrow b{border-color:transparent transparent #888 transparent;border-width:0 4px 5px 4px}.select2-container--classic.select2-container--open.select2-container--above .select2-selection--single{border-top:none;border-top-left-radius:0;border-top-right-radius:0;background-image:-webkit-linear-gradient(top, #fff 0%, #eee 50%);background-image:-o-linear-gradient(top, #fff 0%, #eee 50%);background-image:linear-gradient(to bottom, #fff 0%, #eee 50%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFFFFFF', endColorstr='#FFEEEEEE', GradientType=0)}.select2-container--classic.select2-container--open.select2-container--below .select2-selection--single{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0;background-image:-webkit-linear-gradient(top, #eee 50%, #fff 100%);background-image:-o-linear-gradient(top, #eee 50%, #fff 100%);background-image:linear-gradient(to bottom, #eee 50%, #fff 100%);background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFEEEEEE', endColorstr='#FFFFFFFF', GradientType=0)}.select2-container--classic .select2-selection--multiple{background-color:white;border:1px solid #aaa;border-radius:4px;cursor:text;outline:0}.select2-container--classic .select2-selection--multiple:focus{border:1px solid #5897fb}.select2-container--classic .select2-selection--multiple .select2-selection__rendered{list-style:none;margin:0;padding:0 5px}.select2-container--classic .select2-selection--multiple .select2-selection__clear{display:none}.select2-container--classic .select2-selection--multiple .select2-selection__choice{background-color:#e4e4e4;border:1px solid #aaa;border-radius:4px;cursor:default;float:left;margin-right:5px;margin-top:5px;padding:0 5px}.select2-container--classic .select2-selection--multiple .select2-selection__choice__remove{color:#888;cursor:pointer;display:inline-block;font-weight:bold;margin-right:2px}.select2-container--classic .select2-selection--multiple .select2-selection__choice__remove:hover{color:#555}.select2-container--classic[dir="rtl"] .select2-selection--multiple .select2-selection__choice{float:right}.select2-container--classic[dir="rtl"] .select2-selection--multiple .select2-selection__choice{margin-left:5px;margin-right:auto}.select2-container--classic[dir="rtl"] .select2-selection--multiple .select2-selection__choice__remove{margin-left:2px;margin-right:auto}.select2-container--classic.select2-container--open .select2-selection--multiple{border:1px solid #5897fb}.select2-container--classic.select2-container--open.select2-container--above .select2-selection--multiple{border-top:none;border-top-left-radius:0;border-top-right-radius:0}.select2-container--classic.select2-container--open.select2-container--below .select2-selection--multiple{border-bottom:none;border-bottom-left-radius:0;border-bottom-right-radius:0}.select2-container--classic .select2-search--dropdown .select2-search__field{border:1px solid #aaa;outline:0}.select2-container--classic .select2-search--inline .select2-search__field{outline:0;box-shadow:none}.select2-container--classic .select2-dropdown{background-color:#fff;border:1px solid transparent}.select2-container--classic .select2-dropdown--above{border-bottom:none}.select2-container--classic .select2-dropdown--below{border-top:none}.select2-container--classic .select2-results>.select2-results__options{max-height:200px;overflow-y:auto}.select2-container--classic .select2-results__option[role=group]{padding:0}.select2-container--classic .select2-results__option[aria-disabled=true]{color:grey}.select2-container--classic .select2-results__option--highlighted[data-selected]{background-color:#3875d7;color:#fff}.select2-container--classic .select2-results__group{cursor:default;display:block;padding:6px}.select2-container--classic.select2-container--open .select2-dropdown{border-color:#5897fb} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/slider-customizer.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/slider-customizer.css deleted file mode 100644 index d7add5f7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/slider-customizer.css +++ /dev/null @@ -1,131 +0,0 @@ -.customize-control-generatepress-pro-range-slider .generatepress-slider { - position: relative; - width: calc(100% - 60px); - height: 6px; - background-color: rgba(0,0,0,.10); - cursor: pointer; - transition: background .5s; -} - -.customize-control-generatepress-pro-range-slider .has-unit .generatepress-slider { - width: calc(100% - 90px); -} - -.customize-control-generatepress-pro-range-slider .gp_range_value.hide-value { - display: none; -} - -.customize-control-generatepress-pro-range-slider .gp_range_value.hide-value + .generatepress-slider { - width: 100%; -} - -.customize-control-generatepress-pro-range-slider .generatepress-slider .ui-slider-handle { - height: 16px; - width: 16px; - background-color: #3498D9; - display: inline-block; - position: absolute; - top: 50%; - transform: translateY(-50%) translateX(-4px); - border-radius: 50%; - cursor: pointer; -} - -.customize-control-generatepress-pro-range-slider .wrapper { - display: flex; - justify-content: space-between; - align-items: center; -} - -.customize-control-generatepress-pro-range-slider .gp_range_value { - font-size: 14px; - padding: 0; - font-weight: 400; - width: 50px; - display: flex; -} - -.customize-control-generatepress-pro-range-slider .has-unit .gp_range_value { - width: 80px; -} - -.customize-control-generatepress-pro-range-slider .gp_range_value span.value { - font-size: 12px; - width: calc(100% - 2px); - text-align: center; - min-height: 30px; - background: #FFF; - line-height: 30px; - border: 1px solid #DDD; -} - -.customize-control-generatepress-pro-range-slider .has-unit .gp_range_value span.value { - width: calc(100% - 32px); - display: block; -} - -.customize-control-generatepress-pro-range-slider .gp_range_value .unit { - width: 29px; - text-align: center; - font-size: 12px; - line-height: 30px; - background: #fff; - border: 1px solid #ddd; - margin-left: 1px; -} - -.customize-control-generatepress-pro-range-slider .generatepress-pro-range-slider-reset span { - font-size: 16px; - line-height: 22px; -} - -.customize-control-generatepress-pro-range-slider .gp_range_value input { - font-size: 12px; - padding: 0px; - text-align: center; - min-height: 30px; - height: auto; - border-radius: 0; - border-color: #ddd; -} - -.customize-control-generatepress-pro-range-slider .has-unit .gp_range_value input { - width: calc(100% - 30px); -} - -.customize-control-generatepress-pro-range-slider .gp-range-title-area .dashicons { - cursor: pointer; - font-size: 11px; - width: 20px; - height: 20px; - line-height: 20px; - color: #222; - text-align: center; - position: relative; - top: 2px; -} - -.customize-control-generatepress-pro-range-slider .gp-range-title-area .dashicons:hover { - background: #fafafa; -} - -.customize-control-generatepress-pro-range-slider .gp-range-title-area .dashicons.selected { - background: #fff; - color: #222; -} - -.gp-range-title-area { - display: flex; -} - -.gp-range-slider-controls { - margin-left: auto; -} - -.customize-control-generatepress-pro-range-slider .gp-device-controls > span:first-child:last-child { - display: none; -} - -.customize-control-generatepress-pro-range-slider .sub-description { - margin-top: 10px; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/spacing-customizer.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/spacing-customizer.css deleted file mode 100644 index 058e9c60..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/spacing-customizer.css +++ /dev/null @@ -1,101 +0,0 @@ -.gp-spacing-control-section-title-area { - display: flex; -} - -.gp-range-slider-controls { - margin-left: auto; -} - -.customize-control-spacing .description { - font-size: 10px; - text-transform: uppercase; - font-weight: bold; - font-style: normal; - opacity: 0.7; -} - -.spacing-values-area { - display: flex; -} - -.gp-spacing-section input { - min-height: 30px; - border-radius: 0; - border-color: #ddd; -} - -.gp-link-spacing-section span { - display: block; - color: #0073aa; - font-size: 14px; - cursor: pointer; - height: auto; - min-height: 28px; - line-height: 28px; - box-sizing: border-box; - width: 40px; - background: #fff; - border: 1px solid #ddd; -} - -.gp-link-spacing-section span.gp-unlink-spacing { - background-color: #0073aa; - color: #fff; -} - -.gp-spacing-section { - margin-right: 2px; - text-align:center -} - -.gp-link-spacing-section { - margin-right: 0; -} - -.gp-spacing-section .description { - font-size: 10px; - text-transform: uppercase; - font-weight: bold; - font-style: normal; - opacity: 0.7; -} - -.no-edit-field { - font-size: 11px; - opacity: 0.8; - font-weight: 600; -} - -/* - * Make sure slider is 100% wide. - * Old versions of Secondary Nav will have this set as 50% - * so we need to set !important to overwrite that. - */ -.customize-control.customize-control-gp-spacing-slider { - width: 100% !important; -} - -.customize-control-generatepress-spacing .gp-spacing-control-section-title-area .dashicons { - cursor: pointer; - font-size: 11px; - width: 20px; - height: 20px; - line-height: 20px; - color: #222; - text-align: center; - position: relative; - top: 2px; -} - -.customize-control-generatepress-spacing .gp-spacing-control-section-title-area .dashicons:hover { - background: #fafafa; -} - -.customize-control-generatepress-spacing .gp-spacing-control-section-title-area .dashicons.selected { - background: #fff; - color: #222; -} - -.customize-control-generatepress-spacing .gp-device-controls > span:first-child:last-child { - display: none; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/title-customizer.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/title-customizer.css deleted file mode 100644 index 9a1289e2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/title-customizer.css +++ /dev/null @@ -1,9 +0,0 @@ -.generatepress-customizer-title { - background: #FFF; - padding: 10px 12px; - font-weight: 600; - border-style: solid; - border-width: 0 1px 1px 0; - border-color: #ddd; - font-size: 15px; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/transparency-grid.png b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/transparency-grid.png deleted file mode 100644 index 20d0f653..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/transparency-grid.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/typography-customizer.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/typography-customizer.css deleted file mode 100644 index 53aadcda..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/css/typography-customizer.css +++ /dev/null @@ -1,60 +0,0 @@ -.generatepress-font-family { - margin-bottom: 12px; -} - -.generatepress-weight-transform-wrapper { - display: flex; - justify-content: space-between; -} - -.generatepress-font-weight, -.generatepress-font-transform { - width: calc(50% - 5px); -} - -span.select2-container.select2-container--default.select2-container--open li.select2-results__option { - margin:0; -} - -span.select2-container.select2-container--default.select2-container--open{ - z-index:999999; -} - -.select2-selection__rendered li { - margin-bottom: 0; -} - -.select2-container--default .select2-selection--single, -.select2-container--default.select2-container .select2-selection--multiple, -.select2-dropdown, -.select2-container--default .select2-selection--multiple .select2-selection__choice { - border-color: #ddd; - border-radius: 0; -} - -.select2-container--default .select2-results__option[aria-selected=true] { - color: rgba(0,0,0,0.4); -} - -.select2-container .select2-search--inline { - display: none; -} - -#customize-control-single_content_title_control, -#customize-control-font_heading_2_control, -#customize-control-archive_content_title_control, -#customize-control-font_heading_3_control, -#customize-control-font_heading_4_control, -#customize-control-font_heading_5_control, -#customize-control-font_heading_6_control { - margin-top: 20px; -} - -.generatepress-weight-transform-wrapper select option[value=""] { - display: none; -} - -#customize-control-single_content_title_control .generatepress-weight-transform-wrapper select option[value=""], -#customize-control-archive_content_title_control .generatepress-weight-transform-wrapper select option[value=""] { - display: block; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/alpha-color-picker.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/alpha-color-picker.js deleted file mode 100644 index 319f7a1a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/alpha-color-picker.js +++ /dev/null @@ -1,277 +0,0 @@ -/** - * Alpha Color Picker JS - * - * This file includes several helper functions and the core control JS. - */ - -/** - * Override the stock color.js toString() method to add support for - * outputting RGBa or Hex. - */ -Color.prototype.toString = function( flag ) { - - // If our no-alpha flag has been passed in, output RGBa value with 100% opacity. - // This is used to set the background color on the opacity slider during color changes. - if ( 'no-alpha' == flag ) { - return this.toCSS( 'rgba', '1' ).replace( /\s+/g, '' ); - } - - // If we have a proper opacity value, output RGBa. - if ( 1 > this._alpha ) { - return this.toCSS( 'rgba', this._alpha ).replace( /\s+/g, '' ); - } - - // Proceed with stock color.js hex output. - var hex = parseInt( this._color, 10 ).toString( 16 ); - if ( this.error ) { return ''; } - if ( hex.length < 6 ) { - for ( var i = 6 - hex.length - 1; i >= 0; i-- ) { - hex = '0' + hex; - } - } - - return '#' + hex; -}; - -/** - * Given an RGBa, RGB, or hex color value, return the alpha channel value. - */ -function generate_get_alpha_value_from_color( value ) { - var alphaVal; - - // Remove all spaces from the passed in value to help our RGBa regex. - value = value.toString().replace( / /g, '' ); - - if ( value.match( /rgba\(\d+\,\d+\,\d+\,([^\)]+)\)/ ) ) { - alphaVal = parseFloat( value.match( /rgba\(\d+\,\d+\,\d+\,([^\)]+)\)/ )[1] ).toFixed(2) * 100; - alphaVal = parseInt( alphaVal ); - } else { - alphaVal = 100; - } - - return alphaVal; -} - -/** - * Force update the alpha value of the color picker object and maybe the alpha slider. - */ - function generate_update_alpha_value_on_color_control( alpha, $control, $alphaSlider, update_slider ) { - var iris, colorPicker, color; - - iris = $control.data( 'a8cIris' ); - colorPicker = $control.data( 'wpWpColorPicker' ); - - // Set the alpha value on the Iris object. - iris._color._alpha = alpha; - - // Store the new color value. - color = iris._color.toString(); - - // Set the value of the input. - $control.val( color ); - - // Update the background color of the color picker. - colorPicker.toggler.css({ - 'background-color': color - }); - - // Maybe update the alpha slider itself. - if ( update_slider ) { - generate_update_alpha_value_on_alpha_slider( alpha, $alphaSlider ); - } - - // Update the color value of the color picker object. - $control.wpColorPicker( 'color', color ); -} - -/** - * Update the slider handle position and label. - */ -function generate_update_alpha_value_on_alpha_slider( alpha, $alphaSlider ) { - $alphaSlider.slider( 'value', alpha ); - //$alphaSlider.find( '.ui-slider-handle' ).text( alpha.toString() ); -} - -/** - * Initialization trigger. - */ -jQuery( document ).ready( function( $ ) { - - // Loop over each control and transform it into our color picker. - $( '.gp-alpha-color-control' ).each( function() { - - // Scope the vars. - var $control, startingColor, paletteInput, showOpacity, defaultColor, palette, - colorPickerOptions, $container, $alphaSlider, alphaVal, sliderOptions, savedValue; - - // Store the control instance. - $control = $( this ); - - // Get our saved value - savedValue = wp.customize.value( $control.attr( 'data-customize-setting-link' ) )(); - - // Get a clean starting value for the option. - startingColor = savedValue.toString().replace( /\s+/g, '' ); - - // Get some data off the control. - paletteInput = $control.attr( 'data-palette' ); - showOpacity = $control.attr( 'data-show-opacity' ); - defaultColor = $control.attr( 'data-default-color' ); - - // Process the palette. - if ( paletteInput.indexOf( '|' ) !== -1 ) { - palette = paletteInput.split( '|' ); - } else if ( 'false' == paletteInput ) { - palette = false; - } else { - palette = true; - } - - // Set up the options that we'll pass to wpColorPicker(). - colorPickerOptions = { - change: function( event, ui ) { - var key, value, alpha, $transparency; - - key = $control.attr( 'data-customize-setting-link' ); - value = $control.wpColorPicker( 'color' ); - - // Send ajax request to wp.customize to trigger the Save action. - wp.customize( key, function( obj ) { - obj.set( value ); - }); - - $transparency = $container.find( '.transparency' ); - - // Always show the background color of the opacity slider at 100% opacity. - $alphaSlider.closest( '.gp-alpha-color-picker-container' ).css( 'background-color', ui.color.toString( 'no-alpha' ) ); - }, - palettes: palette - }; - - // Create the colorpicker. - $control.val( savedValue ).wpColorPicker( colorPickerOptions ); - - $container = $control.parents( '.wp-picker-container:first' ); - - // Insert our opacity slider. - $( '
    ' + - '
    ' + - '
    ' ).appendTo( $container.find( '.iris-picker-inner' ) ); - - $alphaSlider = $container.find( '.alpha-slider' ); - - // If starting value is in format RGBa, grab the alpha channel. - alphaVal = generate_get_alpha_value_from_color( startingColor ); - - // Get the solid color - solidColor = startingColor.toString().replace( '0.' + alphaVal, '100' ); - - // Set up jQuery UI slider() options. - sliderOptions = { - create: function( event, ui ) { - var value = $( this ).slider( 'value' ); - - // Set up initial values. - //$( this ).find( '.ui-slider-handle' ).text( value ); - $( this ).closest( '.iris-slider' ).css( 'background-color', solidColor ); - }, - value: alphaVal, - range: 'max', - step: 1, - min: 0, - max: 100, - animate: 300, - orientation: "vertical" - }; - - // Initialize jQuery UI slider with our options. - $alphaSlider.slider( sliderOptions ); - - // Bind event handler for clicking on a palette color. - $container.find( '.iris-palette' ).on( 'click', function() { - var color, alpha; - - color = $( this ).css( 'background-color' ); - alpha = generate_get_alpha_value_from_color( color ); - - generate_update_alpha_value_on_alpha_slider( alpha, $alphaSlider ); - - // Sometimes Iris doesn't set a perfect background-color on the palette, - // for example rgba(20, 80, 100, 0.3) becomes rgba(20, 80, 100, 0.298039). - // To compensante for this we round the opacity value on RGBa colors here - // and save it a second time to the color picker object. - if ( alpha != 100 ) { - color = color.toString().replace( /[^,]+(?=\))/, ( alpha / 100 ).toFixed( 2 ) ); - } - - $control.wpColorPicker( 'color', color ); - }); - - // Bind event handler for clicking on the 'Clear' button. - $container.find( '.button.wp-picker-clear' ).on( 'click', function() { - var key = $control.attr( 'data-customize-setting-link' ); - - // The #fff color is delibrate here. This sets the color picker to white instead of the - // defult black, which puts the color picker in a better place to visually represent empty. - $control.wpColorPicker( 'color', '#ffffff' ); - - // Set the actual option value to empty string. - wp.customize( key, function( obj ) { - obj.set( '' ); - }); - - generate_update_alpha_value_on_alpha_slider( 100, $alphaSlider ); - }); - - // Bind event handler for clicking on the 'Default' button. - $container.find( '.button.wp-picker-default' ).on( 'click', function() { - var alpha = generate_get_alpha_value_from_color( defaultColor ); - - generate_update_alpha_value_on_alpha_slider( alpha, $alphaSlider ); - }); - - // Bind event handler for typing or pasting into the input. - $control.on( 'input', function() { - var value = $( this ).val(); - - if ( '' === value ) { - var key = $control.attr( 'data-customize-setting-link' ); - - // The #fff color is delibrate here. This sets the color picker to white instead of the - // defult black, which puts the color picker in a better place to visually represent empty. - $control.wpColorPicker( 'color', '' ); - - // Set the actual option value to empty string. - wp.customize( key, function( obj ) { - obj.set( '' ); - }); - - generate_update_alpha_value_on_alpha_slider( 100, $alphaSlider ); - } else { - var alpha = generate_get_alpha_value_from_color( value ); - - generate_update_alpha_value_on_alpha_slider( alpha, $alphaSlider ); - } - }); - - // Update all the things when the slider is interacted with. - $alphaSlider.slider().on( 'slide', function( event, ui ) { - var alpha = parseFloat( ui.value ) / 100.0; - - generate_update_alpha_value_on_color_control( alpha, $control, $alphaSlider, false ); - }); - - }); -}); - -// Move the opacity bar next to the hue bar -jQuery( document ).ready( function( $ ) { - var container_width = $( '.customize-control-gp-alpha-color .iris-picker' ).width(); - var square_width = $( '.customize-control-gp-alpha-color .iris-square' ).width(); - var available_space = container_width - square_width; - var strip_width = ( available_space / 2 ) - 20; - var strip_height = $( '.customize-control-gp-alpha-color .iris-strip' ).height(); - $( '.customize-control-gp-alpha-color .iris-strip, .gp-alpha-color-picker-container' ).css( 'width', strip_width + 'px' ); - $( '.gp-alpha-color-picker-container' ).css( 'height', strip_height + 'px' ); - -}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/backgrounds-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/backgrounds-customizer.js deleted file mode 100644 index 74a4b2b7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/backgrounds-customizer.js +++ /dev/null @@ -1,31 +0,0 @@ -( function( api ) { - api.controlConstructor[ 'gp-background-images' ] = api.Control.extend( { - ready() { - var control = this; - - control.container.on( 'change', '.generatepress-backgrounds-repeat select', - function() { - control.settings.repeat.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change', '.generatepress-backgrounds-size select', - function() { - control.settings.size.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change', '.generatepress-backgrounds-attachment select', - function() { - control.settings.attachment.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'input', '.generatepress-backgrounds-position input', - function() { - control.settings.position.set( jQuery( this ).val() ); - } - ); - }, - } ); -}( wp.customize ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/button-actions.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/button-actions.js deleted file mode 100644 index 600c3072..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/button-actions.js +++ /dev/null @@ -1,43 +0,0 @@ -jQuery( function( $ ) { - $( '[data-type="overlay_design"]' ).on( 'click', function( e ) { - e.preventDefault(); - - // eslint-disable-next-line no-alert - if ( ! confirm( gpButtonActions.warning ) ) { - return; - } - - ( function( api ) { - 'use strict'; - - api.instance( 'generate_settings[slideout_background_color]' ).set( gpButtonActions.styling.backgroundColor ); - api.instance( 'generate_settings[slideout_text_color]' ).set( gpButtonActions.styling.textColor ); - api.instance( 'generate_settings[slideout_background_hover_color]' ).set( gpButtonActions.styling.backgroundHoverColor ); - api.instance( 'generate_settings[slideout_background_current_color]' ).set( gpButtonActions.styling.backgroundCurrentColor ); - - api.instance( 'generate_settings[slideout_submenu_background_color]' ).set( gpButtonActions.styling.subMenuBackgroundColor ); - api.instance( 'generate_settings[slideout_submenu_text_color]' ).set( gpButtonActions.styling.subMenuTextColor ); - api.instance( 'generate_settings[slideout_submenu_background_hover_color]' ).set( gpButtonActions.styling.subMenuBackgroundHoverColor ); - api.instance( 'generate_settings[slideout_submenu_background_current_color]' ).set( gpButtonActions.styling.subMenuBackgroundCurrentColor ); - - api.instance( 'generate_settings[slideout_font_weight]' ).set( gpButtonActions.styling.fontWeight ); - api.instance( 'generate_settings[slideout_font_size]' ).set( gpButtonActions.styling.fontSize ); - - $( '.wp-color-picker' ).wpColorPicker().change(); - }( wp.customize ) ); - } ); - - $( '[data-type="regenerate_external_css"]' ).on( 'click', function( e ) { - var $thisButton = $( this ); // eslint-disable-line no-var - e.preventDefault(); - - $thisButton.removeClass( 'success' ).addClass( 'loading' ); - - $.post( ajaxurl, { - action: 'generatepress_regenerate_css_file', - _nonce: $thisButton.data( 'nonce' ), - } ).done( function() { - $thisButton.removeClass( 'loading' ).addClass( 'success' ); - } ); - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/control-toggle-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/control-toggle-customizer.js deleted file mode 100644 index 76083b29..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/control-toggle-customizer.js +++ /dev/null @@ -1,35 +0,0 @@ -jQuery( function( $ ) { - $( '.generatepress-control-toggles' ).each( function() { - $( this ).find( 'button' ).first().addClass( 'active' ); - } ); - - $( document ).on( 'click', '.generatepress-control-toggles button', function( e ) { - e.preventDefault(); - var button = $( this ), - target = button.data( 'target' ), - otherTargets = button.siblings(); - - button.addClass( 'active' ); - button.siblings().removeClass( 'active' ); - - $( 'li[data-control-section="' + target + '"]' ).css( { - visibility: 'visible', - height: '', - width: '', - margin: '', - overflow: '', - } ); - - $.each( otherTargets, function() { - var otherTarget = $( this ).data( 'target' ); - - $( 'li[data-control-section="' + otherTarget + '"]' ).css( { - visibility: 'hidden', - height: '0', - width: '0', - margin: '0', - overflow: 'hidden', - } ); - } ); - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/copyright-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/copyright-customizer.js deleted file mode 100644 index 4d5b4eb8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/copyright-customizer.js +++ /dev/null @@ -1,12 +0,0 @@ -( function( $, api ) { - api.controlConstructor[ 'gp-copyright' ] = api.Control.extend( { - ready() { - var control = this; - $( '.gp-copyright-area', control.container ).on( 'change keyup', - function() { - control.setting.set( $( this ).val() ); - } - ); - }, - } ); -}( jQuery, wp.customize ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/generatepress-controls.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/generatepress-controls.js deleted file mode 100644 index 2b3f2e08..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/generatepress-controls.js +++ /dev/null @@ -1,151 +0,0 @@ -( function( $, api ) { - /** - * Set some controls when we're using the navigation as a header. - * - * @since 1.8 - */ - api( 'generate_menu_plus_settings[navigation_as_header]', function( value ) { - value.bind( function( newval ) { - var navAlignmentSetting = api.instance( 'generate_settings[nav_alignment_setting]' ), - navAlignment = gpControls.navigationAlignment, - siteTitleFontSizeSetting = api.instance( 'generate_settings[site_title_font_size]' ), - mobileSiteTitleFontSizeSetting = api.instance( 'generate_settings[mobile_site_title_font_size]' ), - siteTitleFontSize = gpControls.siteTitleFontSize, - mobileSiteTitleFontSize = gpControls.mobileSiteTitleFontSize, - mobileHeader = api.instance( 'generate_menu_plus_settings[mobile_header]' ).get(), - navTextColorSetting = api.instance( 'generate_settings[navigation_text_color]' ), - navTextColor = gpControls.navigationTextColor, - siteTitleTextColorSetting = api.instance( 'generate_settings[site_title_color]' ), - siteTitleTextColor = gpControls.siteTitleTextColor; - - if ( siteTitleFontSizeSetting && ! siteTitleFontSizeSetting._dirty && 25 !== siteTitleFontSizeSetting.get() ) { - siteTitleFontSize = siteTitleFontSizeSetting.get(); - } - - if ( mobileSiteTitleFontSizeSetting && ! mobileSiteTitleFontSizeSetting._dirty && 20 !== mobileSiteTitleFontSizeSetting.get() ) { - mobileSiteTitleFontSize = mobileSiteTitleFontSizeSetting.get(); - } - - if ( navTextColorSetting && ! navTextColorSetting._dirty ) { - navTextColor = navTextColorSetting.get(); - } - - if ( siteTitleTextColorSetting && ! siteTitleTextColorSetting._dirty ) { - siteTitleTextColor = siteTitleTextColorSetting.get(); - } - - if ( newval ) { - navAlignmentSetting.set( 'right' ); - - if ( siteTitleFontSizeSetting ) { - siteTitleFontSizeSetting.set( 25 ); - } - - if ( api.instance( 'generate_settings[site_title_color]' ) ) { - api.instance( 'generate_settings[site_title_color]' ).set( navTextColor ); - } - - if ( mobileSiteTitleFontSizeSetting && 'enable' !== mobileHeader ) { - mobileSiteTitleFontSizeSetting.set( 20 ); - } - } else { - navAlignmentSetting.set( navAlignment ); - - if ( siteTitleFontSizeSetting ) { - siteTitleFontSizeSetting.set( siteTitleFontSize ); - } - - if ( api.instance( 'generate_settings[site_title_color]' ) ) { - api.instance( 'generate_settings[site_title_color]' ).set( siteTitleTextColor ); - } - - if ( mobileSiteTitleFontSizeSetting && 'enable' !== mobileHeader ) { - mobileSiteTitleFontSizeSetting.set( mobileSiteTitleFontSize ); - } - } - } ); - - var showRegularHeader, - showRegularHeaderCallback; - - /** - * Determine whether we should display our header controls. - * - * @return {boolean} Whether we should show the regular header. - */ - showRegularHeader = function() { - if ( value.get() ) { - return false; - } - - return true; - }; - - /** - * Update a control's active state according to the navigation as header option. - * - * @param {wp.customize.Control} control The current control. - */ - showRegularHeaderCallback = function( control ) { - var setActiveState = function() { - control.active.set( showRegularHeader() ); - }; - - control.active.validate = showRegularHeader; - setActiveState(); - value.bind( setActiveState ); - }; - - api.control( 'generate_header_helper', showRegularHeaderCallback ); - api.control( 'generate_settings[header_layout_setting]', showRegularHeaderCallback ); - api.control( 'generate_settings[header_inner_width]', showRegularHeaderCallback ); - api.control( 'generate_settings[header_alignment_setting]', showRegularHeaderCallback ); - api.control( 'header_spacing', showRegularHeaderCallback ); - api.control( 'generate_settings[header_background_color]', showRegularHeaderCallback ); - api.control( 'header_text_color', showRegularHeaderCallback ); - api.control( 'header_link_color', showRegularHeaderCallback ); - api.control( 'header_link_hover_color', showRegularHeaderCallback ); - api.control( 'site_tagline_color', showRegularHeaderCallback ); - api.control( 'font_site_tagline_control', showRegularHeaderCallback ); - api.control( 'generate_settings[site_tagline_font_size]', showRegularHeaderCallback ); - api.control( 'generate_settings[nav_position_setting]', showRegularHeaderCallback ); - api.control( 'generate_settings[logo_width]', showRegularHeaderCallback ); - } ); - - /** - * Set the navigation branding font size label on mobile header branding change. - * - * @since 1.8 - */ - api( 'generate_menu_plus_settings[mobile_header_branding]', function( value ) { - value.bind( function( newval ) { - if ( api.instance( 'generate_settings[mobile_site_title_font_size]' ) && 'title' === newval ) { - api.instance( 'generate_settings[mobile_site_title_font_size]' ).set( 20 ); - } - } ); - } ); - - /** - * Set the navigation branding font size label on mobile header change. - * - * @since 1.8 - */ - api( 'generate_menu_plus_settings[mobile_header]', function( value ) { - value.bind( function( newval ) { - var mobileSiteTitleFontSizeSetting = api.instance( 'generate_settings[mobile_site_title_font_size]' ), - mobileSiteTitleFontSize = gpControls.mobileSiteTitleFontSize; - - if ( mobileSiteTitleFontSizeSetting && ! mobileSiteTitleFontSizeSetting._dirty && 20 !== mobileSiteTitleFontSizeSetting.get() ) { - mobileSiteTitleFontSize = mobileSiteTitleFontSizeSetting.get(); - } - - if ( api.instance( 'generate_settings[mobile_site_title_font_size]' ) ) { - if ( 'enable' === newval ) { - api.instance( 'generate_settings[mobile_site_title_font_size]' ).set( 20 ); - } else { - api.instance( 'generate_settings[mobile_site_title_font_size]' ).set( mobileSiteTitleFontSize ); - } - } - } ); - } ); -}( jQuery, wp.customize ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/section-shortcuts.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/section-shortcuts.js deleted file mode 100644 index f1d93985..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/section-shortcuts.js +++ /dev/null @@ -1,46 +0,0 @@ -jQuery( function( $ ) { - $( '.generatepress-shortcuts a' ).on( 'click', function( e ) { - e.preventDefault(); - var section = $( this ).attr( 'data-section' ), - currentSection = $( this ).attr( 'data-current-section' ), - destinationSectionElement = $( '[id$="' + section + '"]' ); - - if ( section ) { - wp.customize.section( section ).focus(); - - destinationSectionElement.find( '.show-shortcuts' ).hide(); - destinationSectionElement.find( '.return-shortcut' ).show(); - destinationSectionElement.find( '.return-shortcut a' ).attr( 'data-return', currentSection ); - } - } ); - - $( '.return-shortcut .dashicons' ).on( 'click', function() { - var container = $( this ).closest( '.generatepress-shortcuts' ); - - container.find( '.show-shortcuts' ).show(); - container.find( '.return-shortcut' ).hide(); - } ); - - $( '.return-shortcut a' ).on( 'click', function( e ) { - e.preventDefault(); - - var section = $( this ).attr( 'data-return' ); - var container = $( this ).closest( '.generatepress-shortcuts' ); - - if ( section ) { - wp.customize.section( section ).focus(); - - container.find( '.show-shortcuts' ).show(); - container.find( '.return-shortcut' ).hide(); - } - } ); - - var customizeSectionBack = $( '.customize-section-back' ); - - if ( customizeSectionBack ) { - customizeSectionBack.on( 'click', function() { - $( '.show-shortcuts' ).show(); - $( '.return-shortcut' ).hide(); - } ); - } -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/selectWoo.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/selectWoo.min.js deleted file mode 100644 index c2de789f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/selectWoo.min.js +++ /dev/null @@ -1 +0,0 @@ -/*! Select2 1.0.8 | https://github.com/select2/select2/blob/master/LICENSE.md */!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):"object"==typeof module&&module.exports?module.exports=function(b,c){return void 0===c&&(c="undefined"!=typeof window?require("jquery"):require("jquery")(b)),a(c),c}:a(jQuery)}(function(a){var b=function(){if(a&&a.fn&&a.fn.select2&&a.fn.select2.amd)var b=a.fn.select2.amd;var b;return function(){if(!b||!b.requirejs){b?c=b:b={};var a,c,d;!function(b){function e(a,b){return v.call(a,b)}function f(a,b){var c,d,e,f,g,h,i,j,k,l,m,n,o=b&&b.split("/"),p=t.map,q=p&&p["*"]||{};if(a){for(a=a.split("/"),g=a.length-1,t.nodeIdCompat&&x.test(a[g])&&(a[g]=a[g].replace(x,"")),"."===a[0].charAt(0)&&o&&(n=o.slice(0,o.length-1),a=n.concat(a)),k=0;k0&&(a.splice(k-1,2),k-=2)}a=a.join("/")}if((o||q)&&p){for(c=a.split("/"),k=c.length;k>0;k-=1){if(d=c.slice(0,k).join("/"),o)for(l=o.length;l>0;l-=1)if((e=p[o.slice(0,l).join("/")])&&(e=e[d])){f=e,h=k;break}if(f)break;!i&&q&&q[d]&&(i=q[d],j=k)}!f&&i&&(f=i,h=j),f&&(c.splice(0,h,f),a=c.join("/"))}return a}function g(a,c){return function(){var d=w.call(arguments,0);return"string"!=typeof d[0]&&1===d.length&&d.push(null),o.apply(b,d.concat([a,c]))}}function h(a){return function(b){return f(b,a)}}function i(a){return function(b){r[a]=b}}function j(a){if(e(s,a)){var c=s[a];delete s[a],u[a]=!0,n.apply(b,c)}if(!e(r,a)&&!e(u,a))throw new Error("No "+a);return r[a]}function k(a){var b,c=a?a.indexOf("!"):-1;return c>-1&&(b=a.substring(0,c),a=a.substring(c+1,a.length)),[b,a]}function l(a){return a?k(a):[]}function m(a){return function(){return t&&t.config&&t.config[a]||{}}}var n,o,p,q,r={},s={},t={},u={},v=Object.prototype.hasOwnProperty,w=[].slice,x=/\.js$/;p=function(a,b){var c,d=k(a),e=d[0],g=b[1];return a=d[1],e&&(e=f(e,g),c=j(e)),e?a=c&&c.normalize?c.normalize(a,h(g)):f(a,g):(a=f(a,g),d=k(a),e=d[0],a=d[1],e&&(c=j(e))),{f:e?e+"!"+a:a,n:a,pr:e,p:c}},q={require:function(a){return g(a)},exports:function(a){var b=r[a];return void 0!==b?b:r[a]={}},module:function(a){return{id:a,uri:"",exports:r[a],config:m(a)}}},n=function(a,c,d,f){var h,k,m,n,o,t,v,w=[],x=typeof d;if(f=f||a,t=l(f),"undefined"===x||"function"===x){for(c=!c.length&&d.length?["require","exports","module"]:c,o=0;o0&&(b.call(arguments,a.prototype.constructor),e=c.prototype.constructor),e.apply(this,arguments)}function e(){this.constructor=d}var f=b(c),g=b(a);c.displayName=a.displayName,d.prototype=new e;for(var h=0;h":">",'"':""","'":"'","/":"/"};return"string"!=typeof a?a:String(a).replace(/[&<>"'\/\\]/g,function(a){return b[a]})},c.entityDecode=function(a){var b=document.createElement("textarea");return b.innerHTML=a,b.value},c.appendMany=function(b,c){if("1.7"===a.fn.jquery.substr(0,3)){var d=a();a.map(c,function(a){d=d.add(a)}),c=d}b.append(c)},c.isTouchscreen=function(){return void 0===c._isTouchscreenCache&&(c._isTouchscreenCache="ontouchstart"in document.documentElement),c._isTouchscreenCache},c}),b.define("select2/results",["jquery","./utils"],function(a,b){function c(a,b,d){this.$element=a,this.data=d,this.options=b,c.__super__.constructor.call(this)}return b.Extend(c,b.Observable),c.prototype.render=function(){var b=a('
      ');return this.options.get("multiple")&&b.attr("aria-multiselectable","true"),this.$results=b,b},c.prototype.clear=function(){this.$results.empty()},c.prototype.displayMessage=function(b){var c=this.options.get("escapeMarkup");this.clear(),this.hideLoading();var d=a('
    • '),e=this.options.get("translations").get(b.message);d.append(c(e(b.args))),d[0].className+=" select2-results__message",this.$results.append(d)},c.prototype.hideMessages=function(){this.$results.find(".select2-results__message").remove()},c.prototype.append=function(a){this.hideLoading();var b=[];if(null==a.results||0===a.results.length)return void(0===this.$results.children().length&&this.trigger("results:message",{message:"noResults"}));a.results=this.sort(a.results);for(var c=0;c0?b.first().trigger("mouseenter"):a.first().trigger("mouseenter"),this.ensureHighlightVisible()},c.prototype.setClasses=function(){var b=this;this.data.current(function(c){var d=a.map(c,function(a){return a.id.toString()});b.$results.find(".select2-results__option[data-selected]").each(function(){var b=a(this),c=a.data(this,"data"),e=""+c.id;null!=c.element&&c.element.selected||null==c.element&&a.inArray(e,d)>-1?b.attr("data-selected","true"):b.attr("data-selected","false")})})},c.prototype.showLoading=function(a){this.hideLoading();var b=this.options.get("translations").get("searching"),c={disabled:!0,loading:!0,text:b(a)},d=this.option(c);d.className+=" loading-results",this.$results.prepend(d)},c.prototype.hideLoading=function(){this.$results.find(".loading-results").remove()},c.prototype.option=function(b){var c=document.createElement("li");c.className="select2-results__option";var d={role:"option","data-selected":"false",tabindex:-1};b.disabled&&(delete d["data-selected"],d["aria-disabled"]="true"),null==b.id&&delete d["data-selected"],null!=b._resultId&&(c.id=b._resultId),b.title&&(c.title=b.title),b.children&&(d["aria-label"]=b.text,delete d["data-selected"]);for(var e in d){var f=d[e];c.setAttribute(e,f)}if(b.children){var g=a(c),h=document.createElement("strong");h.className="select2-results__group";var i=a(h);this.template(b,h),i.attr("role","presentation");for(var j=[],k=0;k",{class:"select2-results__options select2-results__options--nested",role:"listbox"});n.append(j),g.attr("role","list"),g.append(h),g.append(n)}else this.template(b,c);return a.data(c,"data",b),c},c.prototype.bind=function(b,c){var d=this,e=b.id+"-results";this.$results.attr("id",e),b.on("results:all",function(a){d.clear(),d.append(a.data),b.isOpen()&&(d.setClasses(),d.highlightFirstItem())}),b.on("results:append",function(a){d.append(a.data),b.isOpen()&&d.setClasses()}),b.on("query",function(a){d.hideMessages(),d.showLoading(a)}),b.on("select",function(){b.isOpen()&&(d.setClasses(),d.highlightFirstItem())}),b.on("unselect",function(){b.isOpen()&&(d.setClasses(),d.highlightFirstItem())}),b.on("open",function(){d.$results.attr("aria-expanded","true"),d.$results.attr("aria-hidden","false"),d.setClasses(),d.ensureHighlightVisible()}),b.on("close",function(){d.$results.attr("aria-expanded","false"),d.$results.attr("aria-hidden","true"),d.$results.removeAttr("aria-activedescendant")}),b.on("results:toggle",function(){var a=d.getHighlightedResults();0!==a.length&&a.trigger("mouseup")}),b.on("results:select",function(){var a=d.getHighlightedResults();if(0!==a.length){var b=a.data("data");"true"==a.attr("data-selected")?d.trigger("close",{}):d.trigger("select",{data:b})}}),b.on("results:previous",function(){var a=d.getHighlightedResults(),b=d.$results.find("[data-selected]"),c=b.index(a);if(0!==c){var e=c-1;0===a.length&&(e=0);var f=b.eq(e);f.trigger("mouseenter");var g=d.$results.offset().top,h=f.offset().top,i=d.$results.scrollTop()+(h-g);0===e?d.$results.scrollTop(0):h-g<0&&d.$results.scrollTop(i)}}),b.on("results:next",function(){var a=d.getHighlightedResults(),b=d.$results.find("[data-selected]"),c=b.index(a),e=c+1;if(!(e>=b.length)){var f=b.eq(e);f.trigger("mouseenter");var g=d.$results.offset().top+d.$results.outerHeight(!1),h=f.offset().top+f.outerHeight(!1),i=d.$results.scrollTop()+h-g;0===e?d.$results.scrollTop(0):h>g&&d.$results.scrollTop(i)}}),b.on("results:focus",function(a){a.element.addClass("select2-results__option--highlighted").attr("aria-selected","true"),d.$results.attr("aria-activedescendant",a.element.attr("id"))}),b.on("results:message",function(a){d.displayMessage(a)}),a.fn.mousewheel&&this.$results.on("mousewheel",function(a){var b=d.$results.scrollTop(),c=d.$results.get(0).scrollHeight-b+a.deltaY,e=a.deltaY>0&&b-a.deltaY<=0,f=a.deltaY<0&&c<=d.$results.height();e?(d.$results.scrollTop(0),a.preventDefault(),a.stopPropagation()):f&&(d.$results.scrollTop(d.$results.get(0).scrollHeight-d.$results.height()),a.preventDefault(),a.stopPropagation())}),this.$results.on("mouseup",".select2-results__option[data-selected]",function(b){var c=a(this),e=c.data("data");if("true"===c.attr("data-selected"))return void(d.options.get("multiple")?d.trigger("unselect",{originalEvent:b,data:e}):d.trigger("close",{}));d.trigger("select",{originalEvent:b,data:e})}),this.$results.on("mouseenter",".select2-results__option[data-selected]",function(b){var c=a(this).data("data");d.getHighlightedResults().removeClass("select2-results__option--highlighted").attr("aria-selected","false"),d.trigger("results:focus",{data:c,element:a(this)})})},c.prototype.getHighlightedResults=function(){return this.$results.find(".select2-results__option--highlighted")},c.prototype.destroy=function(){this.$results.remove()},c.prototype.ensureHighlightVisible=function(){var a=this.getHighlightedResults();if(0!==a.length){var b=this.$results.find("[data-selected]"),c=b.index(a),d=this.$results.offset().top,e=a.offset().top,f=this.$results.scrollTop()+(e-d),g=e-d;f-=2*a.outerHeight(!1),c<=2?this.$results.scrollTop(0):(g>this.$results.outerHeight()||g<0)&&this.$results.scrollTop(f)}},c.prototype.template=function(b,c){var d=this.options.get("templateResult"),e=this.options.get("escapeMarkup"),f=d(b,c);null==f?c.style.display="none":"string"==typeof f?c.innerHTML=e(f):a(c).append(f)},c}),b.define("select2/keys",[],function(){return{BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46}}),b.define("select2/selection/base",["jquery","../utils","../keys"],function(a,b,c){function d(a,b){this.$element=a,this.options=b,d.__super__.constructor.call(this)}return b.Extend(d,b.Observable),d.prototype.render=function(){var b=a('');return this._tabindex=0,null!=this.$element.data("old-tabindex")?this._tabindex=this.$element.data("old-tabindex"):null!=this.$element.attr("tabindex")&&(this._tabindex=this.$element.attr("tabindex")),b.attr("title",this.$element.attr("title")),b.attr("tabindex",this._tabindex),this.$selection=b,b},d.prototype.bind=function(a,b){var d=this,e=(a.id,a.id+"-results");this.options.get("minimumResultsForSearch");this.container=a,this.$selection.on("focus",function(a){d.trigger("focus",a)}),this.$selection.on("blur",function(a){d._handleBlur(a)}),this.$selection.on("keydown",function(a){d.trigger("keypress",a),a.which===c.SPACE&&a.preventDefault()}),a.on("results:focus",function(a){d.$selection.attr("aria-activedescendant",a.data._resultId)}),a.on("selection:update",function(a){d.update(a.data)}),a.on("open",function(){d.$selection.attr("aria-expanded","true"),d.$selection.attr("aria-owns",e),d._attachCloseHandler(a)}),a.on("close",function(){d.$selection.attr("aria-expanded","false"),d.$selection.removeAttr("aria-activedescendant"),d.$selection.removeAttr("aria-owns"),window.setTimeout(function(){d.$selection.focus()},1),d._detachCloseHandler(a)}),a.on("enable",function(){d.$selection.attr("tabindex",d._tabindex)}),a.on("disable",function(){d.$selection.attr("tabindex","-1")})},d.prototype._handleBlur=function(b){var c=this;window.setTimeout(function(){document.activeElement==c.$selection[0]||a.contains(c.$selection[0],document.activeElement)||c.trigger("blur",b)},1)},d.prototype._attachCloseHandler=function(b){a(document.body).on("mousedown.select2."+b.id,function(b){var c=a(b.target),d=c.closest(".select2");a(".select2.select2-container--open").each(function(){var b=a(this);this!=d[0]&&(b.data("element").select2("close"),setTimeout(function(){b.find("*:focus").blur(),c.focus()},1))})})},d.prototype._detachCloseHandler=function(b){a(document.body).off("mousedown.select2."+b.id)},d.prototype.position=function(a,b){b.find(".selection").append(a)},d.prototype.destroy=function(){this._detachCloseHandler(this.container)},d.prototype.update=function(a){throw new Error("The `update` method must be defined in child classes.")},d}),b.define("select2/selection/single",["jquery","./base","../utils","../keys"],function(a,b,c,d){function e(){e.__super__.constructor.apply(this,arguments)}return c.Extend(e,b),e.prototype.render=function(){var a=e.__super__.render.call(this);return a.addClass("select2-selection--single"),a.html(''),a},e.prototype.bind=function(a,b){var c=this;e.__super__.bind.apply(this,arguments);var d=a.id+"-container";this.$selection.find(".select2-selection__rendered").attr("id",d).attr("role","textbox").attr("aria-readonly","true"),this.$selection.attr("aria-labelledby",d),this.$selection.attr("role","combobox"),this.$selection.on("mousedown",function(a){1===a.which&&c.trigger("toggle",{originalEvent:a})}),this.$selection.on("focus",function(a){}),this.$selection.on("keydown",function(b){!a.isOpen()&&b.which>=48&&b.which<=90&&a.open()}),this.$selection.on("blur",function(a){}),a.on("focus",function(b){a.isOpen()||c.$selection.focus()}),a.on("selection:update",function(a){c.update(a.data)})},e.prototype.clear=function(){this.$selection.find(".select2-selection__rendered").empty()},e.prototype.display=function(a,b){var c=this.options.get("templateSelection");return this.options.get("escapeMarkup")(c(a,b))},e.prototype.selectionContainer=function(){return a("")},e.prototype.update=function(a){if(0===a.length)return void this.clear();var b=a[0],d=this.$selection.find(".select2-selection__rendered"),e=c.entityDecode(this.display(b,d));d.empty().text(e),d.prop("title",b.title||b.text)},e}),b.define("select2/selection/multiple",["jquery","./base","../utils"],function(a,b,c){function d(a,b){d.__super__.constructor.apply(this,arguments)}return c.Extend(d,b),d.prototype.render=function(){var a=d.__super__.render.call(this);return a.addClass("select2-selection--multiple"),a.html('
        '),a},d.prototype.bind=function(b,c){var e=this;d.__super__.bind.apply(this,arguments),this.$selection.on("click",function(a){e.trigger("toggle",{originalEvent:a})}),this.$selection.on("click",".select2-selection__choice__remove",function(b){if(!e.options.get("disabled")){var c=a(this),d=c.parent(),f=d.data("data");e.trigger("unselect",{originalEvent:b,data:f})}}),this.$selection.on("keydown",function(a){!b.isOpen()&&a.which>=48&&a.which<=90&&b.open()}),b.on("focus",function(){e.focusOnSearch()})},d.prototype.clear=function(){this.$selection.find(".select2-selection__rendered").empty()},d.prototype.display=function(a,b){var c=this.options.get("templateSelection");return this.options.get("escapeMarkup")(c(a,b))},d.prototype.selectionContainer=function(){return a('
      • ')},d.prototype.focusOnSearch=function(){var a=this;void 0!==a.$search&&setTimeout(function(){a._keyUpPrevented=!0,a.$search.focus()},1)},d.prototype.update=function(a){if(this.clear(),0!==a.length){for(var b=[],d=0;d1||c)return a.call(this,b);this.clear();var d=this.createPlaceholder(this.placeholder);this.$selection.find(".select2-selection__rendered").append(d)},b}),b.define("select2/selection/allowClear",["jquery","../keys"],function(a,b){function c(){}return c.prototype.bind=function(a,b,c){var d=this;a.call(this,b,c),null==this.placeholder&&this.options.get("debug")&&window.console&&console.error&&console.error("Select2: The `allowClear` option should be used in combination with the `placeholder` option."),this.$selection.on("mousedown",".select2-selection__clear",function(a){d._handleClear(a)}),b.on("keypress",function(a){d._handleKeyboardClear(a,b)})},c.prototype._handleClear=function(a,b){if(!this.options.get("disabled")){var c=this.$selection.find(".select2-selection__clear");if(0!==c.length){b.stopPropagation();for(var d=c.data("data"),e=0;e0||0===c.length)){var d=a('×');d.data("data",c),this.$selection.find(".select2-selection__rendered").prepend(d)}},c}),b.define("select2/selection/search",["jquery","../utils","../keys"],function(a,b,c){function d(a,b,c){a.call(this,b,c)}return d.prototype.render=function(b){var c=a('');this.$searchContainer=c,this.$search=c.find("input");var d=b.call(this);return this._transferTabIndex(),d},d.prototype.bind=function(a,b,d){var e=this,f=b.id+"-results";a.call(this,b,d),b.on("open",function(){e.$search.attr("aria-owns",f),e.$search.trigger("focus")}),b.on("close",function(){e.$search.val(""),e.$search.removeAttr("aria-activedescendant"),e.$search.removeAttr("aria-owns"),e.$search.trigger("focus")}),b.on("enable",function(){e.$search.prop("disabled",!1),e._transferTabIndex()}),b.on("disable",function(){e.$search.prop("disabled",!0)}),b.on("focus",function(a){e.$search.trigger("focus")}),b.on("results:focus",function(a){e.$search.attr("aria-activedescendant",a.data._resultId)}),this.$selection.on("focusin",".select2-search--inline",function(a){e.trigger("focus",a)}),this.$selection.on("focusout",".select2-search--inline",function(a){e._handleBlur(a)}),this.$selection.on("keydown",".select2-search--inline",function(a){if(a.stopPropagation(),e.trigger("keypress",a),e._keyUpPrevented=a.isDefaultPrevented(),a.which===c.BACKSPACE&&""===e.$search.val()){var d=e.$searchContainer.prev(".select2-selection__choice");if(d.length>0){var f=d.data("data");e.searchRemoveChoice(f),a.preventDefault()}}else a.which===c.ENTER&&(b.open(),a.preventDefault())});var g=document.documentMode,h=g&&g<=11;this.$selection.on("input.searchcheck",".select2-search--inline",function(a){if(h)return void e.$selection.off("input.search input.searchcheck");e.$selection.off("keyup.search")}),this.$selection.on("keyup.search input.search",".select2-search--inline",function(a){if(h&&"input"===a.type)return void e.$selection.off("input.search input.searchcheck");var b=a.which;b!=c.SHIFT&&b!=c.CTRL&&b!=c.ALT&&b!=c.TAB&&e.handleSearch(a)})},d.prototype._transferTabIndex=function(a){this.$search.attr("tabindex",this.$selection.attr("tabindex")),this.$selection.attr("tabindex","-1")},d.prototype.createPlaceholder=function(a,b){this.$search.attr("placeholder",b.text)},d.prototype.update=function(a,b){var c=this.$search[0]==document.activeElement;this.$search.attr("placeholder",""),a.call(this,b),this.$selection.find(".select2-selection__rendered").append(this.$searchContainer),this.resizeSearch(),c&&this.$search.focus()},d.prototype.handleSearch=function(){if(this.resizeSearch(),!this._keyUpPrevented){var a=this.$search.val();this.trigger("query",{term:a})}this._keyUpPrevented=!1},d.prototype.searchRemoveChoice=function(a,b){this.trigger("unselect",{data:b}),this.$search.val(b.text),this.handleSearch()},d.prototype.resizeSearch=function(){this.$search.css("width","25px");var a="";if(""!==this.$search.attr("placeholder"))a=this.$selection.find(".select2-selection__rendered").innerWidth();else{a=.75*(this.$search.val().length+1)+"em"}this.$search.css("width",a)},d}),b.define("select2/selection/eventRelay",["jquery"],function(a){function b(){}return b.prototype.bind=function(b,c,d){var e=this,f=["open","opening","close","closing","select","selecting","unselect","unselecting"],g=["opening","closing","selecting","unselecting"];b.call(this,c,d),c.on("*",function(b,c){if(-1!==a.inArray(b,f)){c=c||{};var d=a.Event("select2:"+b,{params:c});e.$element.trigger(d),-1!==a.inArray(b,g)&&(c.prevented=d.isDefaultPrevented())}})},b}),b.define("select2/translation",["jquery","require"],function(a,b){function c(a){this.dict=a||{}}return c.prototype.all=function(){return this.dict},c.prototype.get=function(a){return this.dict[a]},c.prototype.extend=function(b){this.dict=a.extend({},b.all(),this.dict)},c._cache={},c.loadPath=function(a){if(!(a in c._cache)){var d=b(a);c._cache[a]=d}return new c(c._cache[a])},c}),b.define("select2/diacritics",[],function(){return{"Ⓐ":"A","A":"A","À":"A","Á":"A","Â":"A","Ầ":"A","Ấ":"A","Ẫ":"A","Ẩ":"A","Ã":"A","Ā":"A","Ă":"A","Ằ":"A","Ắ":"A","Ẵ":"A","Ẳ":"A","Ȧ":"A","Ǡ":"A","Ä":"A","Ǟ":"A","Ả":"A","Å":"A","Ǻ":"A","Ǎ":"A","Ȁ":"A","Ȃ":"A","Ạ":"A","Ậ":"A","Ặ":"A","Ḁ":"A","Ą":"A","Ⱥ":"A","Ɐ":"A","Ꜳ":"AA","Æ":"AE","Ǽ":"AE","Ǣ":"AE","Ꜵ":"AO","Ꜷ":"AU","Ꜹ":"AV","Ꜻ":"AV","Ꜽ":"AY","Ⓑ":"B","B":"B","Ḃ":"B","Ḅ":"B","Ḇ":"B","Ƀ":"B","Ƃ":"B","Ɓ":"B","Ⓒ":"C","C":"C","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","Ç":"C","Ḉ":"C","Ƈ":"C","Ȼ":"C","Ꜿ":"C","Ⓓ":"D","D":"D","Ḋ":"D","Ď":"D","Ḍ":"D","Ḑ":"D","Ḓ":"D","Ḏ":"D","Đ":"D","Ƌ":"D","Ɗ":"D","Ɖ":"D","Ꝺ":"D","DZ":"DZ","DŽ":"DZ","Dz":"Dz","Dž":"Dz","Ⓔ":"E","E":"E","È":"E","É":"E","Ê":"E","Ề":"E","Ế":"E","Ễ":"E","Ể":"E","Ẽ":"E","Ē":"E","Ḕ":"E","Ḗ":"E","Ĕ":"E","Ė":"E","Ë":"E","Ẻ":"E","Ě":"E","Ȅ":"E","Ȇ":"E","Ẹ":"E","Ệ":"E","Ȩ":"E","Ḝ":"E","Ę":"E","Ḙ":"E","Ḛ":"E","Ɛ":"E","Ǝ":"E","Ⓕ":"F","F":"F","Ḟ":"F","Ƒ":"F","Ꝼ":"F","Ⓖ":"G","G":"G","Ǵ":"G","Ĝ":"G","Ḡ":"G","Ğ":"G","Ġ":"G","Ǧ":"G","Ģ":"G","Ǥ":"G","Ɠ":"G","Ꞡ":"G","Ᵹ":"G","Ꝿ":"G","Ⓗ":"H","H":"H","Ĥ":"H","Ḣ":"H","Ḧ":"H","Ȟ":"H","Ḥ":"H","Ḩ":"H","Ḫ":"H","Ħ":"H","Ⱨ":"H","Ⱶ":"H","Ɥ":"H","Ⓘ":"I","I":"I","Ì":"I","Í":"I","Î":"I","Ĩ":"I","Ī":"I","Ĭ":"I","İ":"I","Ï":"I","Ḯ":"I","Ỉ":"I","Ǐ":"I","Ȉ":"I","Ȋ":"I","Ị":"I","Į":"I","Ḭ":"I","Ɨ":"I","Ⓙ":"J","J":"J","Ĵ":"J","Ɉ":"J","Ⓚ":"K","K":"K","Ḱ":"K","Ǩ":"K","Ḳ":"K","Ķ":"K","Ḵ":"K","Ƙ":"K","Ⱪ":"K","Ꝁ":"K","Ꝃ":"K","Ꝅ":"K","Ꞣ":"K","Ⓛ":"L","L":"L","Ŀ":"L","Ĺ":"L","Ľ":"L","Ḷ":"L","Ḹ":"L","Ļ":"L","Ḽ":"L","Ḻ":"L","Ł":"L","Ƚ":"L","Ɫ":"L","Ⱡ":"L","Ꝉ":"L","Ꝇ":"L","Ꞁ":"L","LJ":"LJ","Lj":"Lj","Ⓜ":"M","M":"M","Ḿ":"M","Ṁ":"M","Ṃ":"M","Ɱ":"M","Ɯ":"M","Ⓝ":"N","N":"N","Ǹ":"N","Ń":"N","Ñ":"N","Ṅ":"N","Ň":"N","Ṇ":"N","Ņ":"N","Ṋ":"N","Ṉ":"N","Ƞ":"N","Ɲ":"N","Ꞑ":"N","Ꞥ":"N","NJ":"NJ","Nj":"Nj","Ⓞ":"O","O":"O","Ò":"O","Ó":"O","Ô":"O","Ồ":"O","Ố":"O","Ỗ":"O","Ổ":"O","Õ":"O","Ṍ":"O","Ȭ":"O","Ṏ":"O","Ō":"O","Ṑ":"O","Ṓ":"O","Ŏ":"O","Ȯ":"O","Ȱ":"O","Ö":"O","Ȫ":"O","Ỏ":"O","Ő":"O","Ǒ":"O","Ȍ":"O","Ȏ":"O","Ơ":"O","Ờ":"O","Ớ":"O","Ỡ":"O","Ở":"O","Ợ":"O","Ọ":"O","Ộ":"O","Ǫ":"O","Ǭ":"O","Ø":"O","Ǿ":"O","Ɔ":"O","Ɵ":"O","Ꝋ":"O","Ꝍ":"O","Ƣ":"OI","Ꝏ":"OO","Ȣ":"OU","Ⓟ":"P","P":"P","Ṕ":"P","Ṗ":"P","Ƥ":"P","Ᵽ":"P","Ꝑ":"P","Ꝓ":"P","Ꝕ":"P","Ⓠ":"Q","Q":"Q","Ꝗ":"Q","Ꝙ":"Q","Ɋ":"Q","Ⓡ":"R","R":"R","Ŕ":"R","Ṙ":"R","Ř":"R","Ȑ":"R","Ȓ":"R","Ṛ":"R","Ṝ":"R","Ŗ":"R","Ṟ":"R","Ɍ":"R","Ɽ":"R","Ꝛ":"R","Ꞧ":"R","Ꞃ":"R","Ⓢ":"S","S":"S","ẞ":"S","Ś":"S","Ṥ":"S","Ŝ":"S","Ṡ":"S","Š":"S","Ṧ":"S","Ṣ":"S","Ṩ":"S","Ș":"S","Ş":"S","Ȿ":"S","Ꞩ":"S","Ꞅ":"S","Ⓣ":"T","T":"T","Ṫ":"T","Ť":"T","Ṭ":"T","Ț":"T","Ţ":"T","Ṱ":"T","Ṯ":"T","Ŧ":"T","Ƭ":"T","Ʈ":"T","Ⱦ":"T","Ꞇ":"T","Ꜩ":"TZ","Ⓤ":"U","U":"U","Ù":"U","Ú":"U","Û":"U","Ũ":"U","Ṹ":"U","Ū":"U","Ṻ":"U","Ŭ":"U","Ü":"U","Ǜ":"U","Ǘ":"U","Ǖ":"U","Ǚ":"U","Ủ":"U","Ů":"U","Ű":"U","Ǔ":"U","Ȕ":"U","Ȗ":"U","Ư":"U","Ừ":"U","Ứ":"U","Ữ":"U","Ử":"U","Ự":"U","Ụ":"U","Ṳ":"U","Ų":"U","Ṷ":"U","Ṵ":"U","Ʉ":"U","Ⓥ":"V","V":"V","Ṽ":"V","Ṿ":"V","Ʋ":"V","Ꝟ":"V","Ʌ":"V","Ꝡ":"VY","Ⓦ":"W","W":"W","Ẁ":"W","Ẃ":"W","Ŵ":"W","Ẇ":"W","Ẅ":"W","Ẉ":"W","Ⱳ":"W","Ⓧ":"X","X":"X","Ẋ":"X","Ẍ":"X","Ⓨ":"Y","Y":"Y","Ỳ":"Y","Ý":"Y","Ŷ":"Y","Ỹ":"Y","Ȳ":"Y","Ẏ":"Y","Ÿ":"Y","Ỷ":"Y","Ỵ":"Y","Ƴ":"Y","Ɏ":"Y","Ỿ":"Y","Ⓩ":"Z","Z":"Z","Ź":"Z","Ẑ":"Z","Ż":"Z","Ž":"Z","Ẓ":"Z","Ẕ":"Z","Ƶ":"Z","Ȥ":"Z","Ɀ":"Z","Ⱬ":"Z","Ꝣ":"Z","ⓐ":"a","a":"a","ẚ":"a","à":"a","á":"a","â":"a","ầ":"a","ấ":"a","ẫ":"a","ẩ":"a","ã":"a","ā":"a","ă":"a","ằ":"a","ắ":"a","ẵ":"a","ẳ":"a","ȧ":"a","ǡ":"a","ä":"a","ǟ":"a","ả":"a","å":"a","ǻ":"a","ǎ":"a","ȁ":"a","ȃ":"a","ạ":"a","ậ":"a","ặ":"a","ḁ":"a","ą":"a","ⱥ":"a","ɐ":"a","ꜳ":"aa","æ":"ae","ǽ":"ae","ǣ":"ae","ꜵ":"ao","ꜷ":"au","ꜹ":"av","ꜻ":"av","ꜽ":"ay","ⓑ":"b","b":"b","ḃ":"b","ḅ":"b","ḇ":"b","ƀ":"b","ƃ":"b","ɓ":"b","ⓒ":"c","c":"c","ć":"c","ĉ":"c","ċ":"c","č":"c","ç":"c","ḉ":"c","ƈ":"c","ȼ":"c","ꜿ":"c","ↄ":"c","ⓓ":"d","d":"d","ḋ":"d","ď":"d","ḍ":"d","ḑ":"d","ḓ":"d","ḏ":"d","đ":"d","ƌ":"d","ɖ":"d","ɗ":"d","ꝺ":"d","dz":"dz","dž":"dz","ⓔ":"e","e":"e","è":"e","é":"e","ê":"e","ề":"e","ế":"e","ễ":"e","ể":"e","ẽ":"e","ē":"e","ḕ":"e","ḗ":"e","ĕ":"e","ė":"e","ë":"e","ẻ":"e","ě":"e","ȅ":"e","ȇ":"e","ẹ":"e","ệ":"e","ȩ":"e","ḝ":"e","ę":"e","ḙ":"e","ḛ":"e","ɇ":"e","ɛ":"e","ǝ":"e","ⓕ":"f","f":"f","ḟ":"f","ƒ":"f","ꝼ":"f","ⓖ":"g","g":"g","ǵ":"g","ĝ":"g","ḡ":"g","ğ":"g","ġ":"g","ǧ":"g","ģ":"g","ǥ":"g","ɠ":"g","ꞡ":"g","ᵹ":"g","ꝿ":"g","ⓗ":"h","h":"h","ĥ":"h","ḣ":"h","ḧ":"h","ȟ":"h","ḥ":"h","ḩ":"h","ḫ":"h","ẖ":"h","ħ":"h","ⱨ":"h","ⱶ":"h","ɥ":"h","ƕ":"hv","ⓘ":"i","i":"i","ì":"i","í":"i","î":"i","ĩ":"i","ī":"i","ĭ":"i","ï":"i","ḯ":"i","ỉ":"i","ǐ":"i","ȉ":"i","ȋ":"i","ị":"i","į":"i","ḭ":"i","ɨ":"i","ı":"i","ⓙ":"j","j":"j","ĵ":"j","ǰ":"j","ɉ":"j","ⓚ":"k","k":"k","ḱ":"k","ǩ":"k","ḳ":"k","ķ":"k","ḵ":"k","ƙ":"k","ⱪ":"k","ꝁ":"k","ꝃ":"k","ꝅ":"k","ꞣ":"k","ⓛ":"l","l":"l","ŀ":"l","ĺ":"l","ľ":"l","ḷ":"l","ḹ":"l","ļ":"l","ḽ":"l","ḻ":"l","ſ":"l","ł":"l","ƚ":"l","ɫ":"l","ⱡ":"l","ꝉ":"l","ꞁ":"l","ꝇ":"l","lj":"lj","ⓜ":"m","m":"m","ḿ":"m","ṁ":"m","ṃ":"m","ɱ":"m","ɯ":"m","ⓝ":"n","n":"n","ǹ":"n","ń":"n","ñ":"n","ṅ":"n","ň":"n","ṇ":"n","ņ":"n","ṋ":"n","ṉ":"n","ƞ":"n","ɲ":"n","ʼn":"n","ꞑ":"n","ꞥ":"n","nj":"nj","ⓞ":"o","o":"o","ò":"o","ó":"o","ô":"o","ồ":"o","ố":"o","ỗ":"o","ổ":"o","õ":"o","ṍ":"o","ȭ":"o","ṏ":"o","ō":"o","ṑ":"o","ṓ":"o","ŏ":"o","ȯ":"o","ȱ":"o","ö":"o","ȫ":"o","ỏ":"o","ő":"o","ǒ":"o","ȍ":"o","ȏ":"o","ơ":"o","ờ":"o","ớ":"o","ỡ":"o","ở":"o","ợ":"o","ọ":"o","ộ":"o","ǫ":"o","ǭ":"o","ø":"o","ǿ":"o","ɔ":"o","ꝋ":"o","ꝍ":"o","ɵ":"o","ƣ":"oi","ȣ":"ou","ꝏ":"oo","ⓟ":"p","p":"p","ṕ":"p","ṗ":"p","ƥ":"p","ᵽ":"p","ꝑ":"p","ꝓ":"p","ꝕ":"p","ⓠ":"q","q":"q","ɋ":"q","ꝗ":"q","ꝙ":"q","ⓡ":"r","r":"r","ŕ":"r","ṙ":"r","ř":"r","ȑ":"r","ȓ":"r","ṛ":"r","ṝ":"r","ŗ":"r","ṟ":"r","ɍ":"r","ɽ":"r","ꝛ":"r","ꞧ":"r","ꞃ":"r","ⓢ":"s","s":"s","ß":"s","ś":"s","ṥ":"s","ŝ":"s","ṡ":"s","š":"s","ṧ":"s","ṣ":"s","ṩ":"s","ș":"s","ş":"s","ȿ":"s","ꞩ":"s","ꞅ":"s","ẛ":"s","ⓣ":"t","t":"t","ṫ":"t","ẗ":"t","ť":"t","ṭ":"t","ț":"t","ţ":"t","ṱ":"t","ṯ":"t","ŧ":"t","ƭ":"t","ʈ":"t","ⱦ":"t","ꞇ":"t","ꜩ":"tz","ⓤ":"u","u":"u","ù":"u","ú":"u","û":"u","ũ":"u","ṹ":"u","ū":"u","ṻ":"u","ŭ":"u","ü":"u","ǜ":"u","ǘ":"u","ǖ":"u","ǚ":"u","ủ":"u","ů":"u","ű":"u","ǔ":"u","ȕ":"u","ȗ":"u","ư":"u","ừ":"u","ứ":"u","ữ":"u","ử":"u","ự":"u","ụ":"u","ṳ":"u","ų":"u","ṷ":"u","ṵ":"u","ʉ":"u","ⓥ":"v","v":"v","ṽ":"v","ṿ":"v","ʋ":"v","ꝟ":"v","ʌ":"v","ꝡ":"vy","ⓦ":"w","w":"w","ẁ":"w","ẃ":"w","ŵ":"w","ẇ":"w","ẅ":"w","ẘ":"w","ẉ":"w","ⱳ":"w","ⓧ":"x","x":"x","ẋ":"x","ẍ":"x","ⓨ":"y","y":"y","ỳ":"y","ý":"y","ŷ":"y","ỹ":"y","ȳ":"y","ẏ":"y","ÿ":"y","ỷ":"y","ẙ":"y","ỵ":"y","ƴ":"y","ɏ":"y","ỿ":"y","ⓩ":"z","z":"z","ź":"z","ẑ":"z","ż":"z","ž":"z","ẓ":"z","ẕ":"z","ƶ":"z","ȥ":"z","ɀ":"z","ⱬ":"z","ꝣ":"z","Ά":"Α","Έ":"Ε","Ή":"Η","Ί":"Ι","Ϊ":"Ι","Ό":"Ο","Ύ":"Υ","Ϋ":"Υ","Ώ":"Ω","ά":"α","έ":"ε","ή":"η","ί":"ι","ϊ":"ι","ΐ":"ι","ό":"ο","ύ":"υ","ϋ":"υ","ΰ":"υ","ω":"ω","ς":"σ"}}),b.define("select2/data/base",["../utils"],function(a){function b(a,c){b.__super__.constructor.call(this)}return a.Extend(b,a.Observable),b.prototype.current=function(a){throw new Error("The `current` method must be defined in child classes.")},b.prototype.query=function(a,b){throw new Error("The `query` method must be defined in child classes.")},b.prototype.bind=function(a,b){},b.prototype.destroy=function(){},b.prototype.generateResultId=function(b,c){var d="";return d+=null!=b?b.id:a.generateChars(4),d+="-result-",d+=a.generateChars(4),null!=c.id?d+="-"+c.id.toString():d+="-"+a.generateChars(4),d},b}),b.define("select2/data/select",["./base","../utils","jquery"],function(a,b,c){function d(a,b){this.$element=a,this.options=b,d.__super__.constructor.call(this)}return b.Extend(d,a),d.prototype.current=function(a){var b=[],d=this;this.$element.find(":selected").each(function(){var a=c(this),e=d.item(a);b.push(e)}),a(b)},d.prototype.select=function(a){var b=this;if(a.selected=!0,c(a.element).is("option"))return a.element.selected=!0,void this.$element.trigger("change");if(this.$element.prop("multiple"))this.current(function(d){var e=[];a=[a],a.push.apply(a,d);for(var f=0;f=0){var k=f.filter(d(j)),l=this.item(k),m=c.extend(!0,{},j,l),n=this.option(m);k.replaceWith(n)}else{var o=this.option(j);if(j.children){var p=this.convertToOptions(j.children);b.appendMany(o,p)}h.push(o)}}return h},d}),b.define("select2/data/ajax",["./array","../utils","jquery"],function(a,b,c){function d(a,b){this.ajaxOptions=this._applyDefaults(b.get("ajax")),null!=this.ajaxOptions.processResults&&(this.processResults=this.ajaxOptions.processResults),d.__super__.constructor.call(this,a,b)}return b.Extend(d,a),d.prototype._applyDefaults=function(a){var b={data:function(a){return c.extend({},a,{q:a.term})},transport:function(a,b,d){var e=c.ajax(a);return e.then(b),e.fail(d),e}};return c.extend({},b,a,!0)},d.prototype.processResults=function(a){return a},d.prototype.query=function(a,b){function d(){var d=f.transport(f,function(d){var f=e.processResults(d,a);e.options.get("debug")&&window.console&&console.error&&(f&&f.results&&c.isArray(f.results)||console.error("Select2: The AJAX results did not return an array in the `results` key of the response.")),b(f),e.container.focusOnActiveElement()},function(){d.status&&"0"===d.status||e.trigger("results:message",{message:"errorLoading"})});e._request=d}var e=this;null!=this._request&&(c.isFunction(this._request.abort)&&this._request.abort(),this._request=null);var f=c.extend({type:"GET"},this.ajaxOptions);"function"==typeof f.url&&(f.url=f.url.call(this.$element,a)),"function"==typeof f.data&&(f.data=f.data.call(this.$element,a)),this.ajaxOptions.delay&&null!=a.term?(this._queryTimeout&&window.clearTimeout(this._queryTimeout),this._queryTimeout=window.setTimeout(d,this.ajaxOptions.delay)):d()},d}),b.define("select2/data/tags",["jquery"],function(a){function b(b,c,d){var e=d.get("tags"),f=d.get("createTag");void 0!==f&&(this.createTag=f);var g=d.get("insertTag");if(void 0!==g&&(this.insertTag=g),b.call(this,c,d),a.isArray(e))for(var h=0;h0&&b.term.length>this.maximumInputLength)return void this.trigger("results:message",{message:"inputTooLong",args:{maximum:this.maximumInputLength,input:b.term,params:b}});a.call(this,b,c)},a}),b.define("select2/data/maximumSelectionLength",[],function(){function a(a,b,c){this.maximumSelectionLength=c.get("maximumSelectionLength"),a.call(this,b,c)}return a.prototype.query=function(a,b,c){var d=this;this.current(function(e){var f=null!=e?e.length:0;if(d.maximumSelectionLength>0&&f>=d.maximumSelectionLength)return void d.trigger("results:message",{message:"maximumSelected",args:{maximum:d.maximumSelectionLength}});a.call(d,b,c)})},a}),b.define("select2/dropdown",["jquery","./utils"],function(a,b){function c(a,b){this.$element=a,this.options=b,c.__super__.constructor.call(this)}return b.Extend(c,b.Observable),c.prototype.render=function(){var b=a('');return b.attr("dir",this.options.get("dir")),this.$dropdown=b,b},c.prototype.bind=function(){},c.prototype.position=function(a,b){},c.prototype.destroy=function(){this.$dropdown.remove()},c}),b.define("select2/dropdown/search",["jquery","../utils"],function(a,b){function c(){}return c.prototype.render=function(b){var c=b.call(this),d=a('');return this.$searchContainer=d,this.$search=d.find("input"),c.prepend(d),c},c.prototype.bind=function(b,c,d){var e=this,f=c.id+"-results";b.call(this,c,d),this.$search.on("keydown",function(a){e.trigger("keypress",a),e._keyUpPrevented=a.isDefaultPrevented()}),this.$search.on("input",function(b){a(this).off("keyup")}),this.$search.on("keyup input",function(a){e.handleSearch(a)}),c.on("open",function(){e.$search.attr("tabindex",0),e.$search.attr("aria-owns",f),e.$search.focus(),window.setTimeout(function(){e.$search.focus()},0)}),c.on("close",function(){e.$search.attr("tabindex",-1),e.$search.removeAttr("aria-activedescendant"),e.$search.removeAttr("aria-owns"),e.$search.val("")}),c.on("focus",function(){c.isOpen()||e.$search.focus()}),c.on("results:all",function(a){if(null==a.query.term||""===a.query.term){e.showSearch(a)?e.$searchContainer.removeClass("select2-search--hide"):e.$searchContainer.addClass("select2-search--hide")}}),c.on("results:focus",function(a){e.$search.attr("aria-activedescendant",a.data._resultId)})},c.prototype.handleSearch=function(a){if(!this._keyUpPrevented){var b=this.$search.val();this.trigger("query",{term:b})}this._keyUpPrevented=!1},c.prototype.showSearch=function(a,b){return!0},c}),b.define("select2/dropdown/hidePlaceholder",[],function(){function a(a,b,c,d){this.placeholder=this.normalizePlaceholder(c.get("placeholder")),a.call(this,b,c,d)}return a.prototype.append=function(a,b){b.results=this.removePlaceholder(b.results),a.call(this,b)},a.prototype.normalizePlaceholder=function(a,b){return"string"==typeof b&&(b={id:"",text:b}),b},a.prototype.removePlaceholder=function(a,b){for(var c=b.slice(0),d=b.length-1;d>=0;d--){var e=b[d];this.placeholder.id===e.id&&c.splice(d,1)}return c},a}),b.define("select2/dropdown/infiniteScroll",["jquery"],function(a){function b(a,b,c,d){this.lastParams={},a.call(this,b,c,d),this.$loadingMore=this.createLoadingMore(),this.loading=!1}return b.prototype.append=function(a,b){this.$loadingMore.remove(),this.loading=!1,a.call(this,b),this.showLoadingMore(b)&&this.$results.append(this.$loadingMore)},b.prototype.bind=function(b,c,d){var e=this;b.call(this,c,d),c.on("query",function(a){e.lastParams=a,e.loading=!0}),c.on("query:append",function(a){e.lastParams=a,e.loading=!0}),this.$results.on("scroll",function(){var b=a.contains(document.documentElement,e.$loadingMore[0]);if(!e.loading&&b){e.$results.offset().top+e.$results.outerHeight(!1)+50>=e.$loadingMore.offset().top+e.$loadingMore.outerHeight(!1)&&e.loadMore()}})},b.prototype.loadMore=function(){this.loading=!0;var b=a.extend({},{page:1},this.lastParams);b.page++,this.trigger("query:append",b)},b.prototype.showLoadingMore=function(a,b){return b.pagination&&b.pagination.more},b.prototype.createLoadingMore=function(){var b=a('
      • '),c=this.options.get("translations").get("loadingMore");return b.html(c(this.lastParams)),b},b}),b.define("select2/dropdown/attachBody",["jquery","../utils"],function(a,b){function c(b,c,d){this.$dropdownParent=d.get("dropdownParent")||a(document.body),b.call(this,c,d)}return c.prototype.bind=function(a,b,c){var d=this,e=!1;a.call(this,b,c),b.on("open",function(){d._showDropdown(),d._attachPositioningHandler(b),e||(e=!0,b.on("results:all",function(){d._positionDropdown(),d._resizeDropdown()}),b.on("results:append",function(){d._positionDropdown(),d._resizeDropdown()}))}),b.on("close",function(){d._hideDropdown(),d._detachPositioningHandler(b)}),this.$dropdownContainer.on("mousedown",function(a){a.stopPropagation()})},c.prototype.destroy=function(a){a.call(this),this.$dropdownContainer.remove()},c.prototype.position=function(a,b,c){b.attr("class",c.attr("class")),b.removeClass("select2"),b.addClass("select2-container--open"),b.css({position:"absolute",top:-999999}),this.$container=c},c.prototype.render=function(b){var c=a(""),d=b.call(this);return c.append(d),this.$dropdownContainer=c,c},c.prototype._hideDropdown=function(a){this.$dropdownContainer.detach()},c.prototype._attachPositioningHandler=function(c,d){var e=this,f="scroll.select2."+d.id,g="resize.select2."+d.id,h="orientationchange.select2."+d.id,i=this.$container.parents().filter(b.hasScroll);i.each(function(){a(this).data("select2-scroll-position",{x:a(this).scrollLeft(),y:a(this).scrollTop()})}),i.on(f,function(b){var c=a(this).data("select2-scroll-position");a(this).scrollTop(c.y)}),a(window).on(f+" "+g+" "+h,function(a){e._positionDropdown(),e._resizeDropdown()})},c.prototype._detachPositioningHandler=function(c,d){var e="scroll.select2."+d.id,f="resize.select2."+d.id,g="orientationchange.select2."+d.id;this.$container.parents().filter(b.hasScroll).off(e),a(window).off(e+" "+f+" "+g)},c.prototype._positionDropdown=function(){var b=a(window),c=this.$dropdown.hasClass("select2-dropdown--above"),d=this.$dropdown.hasClass("select2-dropdown--below"),e=null,f=this.$container.offset();f.bottom=f.top+this.$container.outerHeight(!1);var g={height:this.$container.outerHeight(!1)};g.top=f.top,g.bottom=f.top+g.height;var h={height:this.$dropdown.outerHeight(!1)},i={top:b.scrollTop(),bottom:b.scrollTop()+b.height()},j=i.topf.bottom+h.height,l={left:f.left,top:g.bottom},m=this.$dropdownParent;"static"===m.css("position")&&(m=m.offsetParent());var n=m.offset();l.top-=n.top,l.left-=n.left,c||d||(e="below"),k||!j||c?!j&&k&&c&&(e="below"):e="above",("above"==e||c&&"below"!==e)&&(l.top=g.top-n.top-h.height),null!=e&&(this.$dropdown.removeClass("select2-dropdown--below select2-dropdown--above").addClass("select2-dropdown--"+e),this.$container.removeClass("select2-container--below select2-container--above").addClass("select2-container--"+e)),this.$dropdownContainer.css(l)},c.prototype._resizeDropdown=function(){var a={width:this.$container.outerWidth(!1)+"px"};this.options.get("dropdownAutoWidth")&&(a.minWidth=a.width,a.position="relative",a.width="auto"),this.$dropdown.css(a)},c.prototype._showDropdown=function(a){this.$dropdownContainer.appendTo(this.$dropdownParent),this._positionDropdown(),this._resizeDropdown()},c}),b.define("select2/dropdown/minimumResultsForSearch",[],function(){function a(b){for(var c=0,d=0;d0&&(l.dataAdapter=j.Decorate(l.dataAdapter,r)),l.maximumInputLength>0&&(l.dataAdapter=j.Decorate(l.dataAdapter,s)),l.maximumSelectionLength>0&&(l.dataAdapter=j.Decorate(l.dataAdapter,t)),l.tags&&(l.dataAdapter=j.Decorate(l.dataAdapter,p)),null==l.tokenSeparators&&null==l.tokenizer||(l.dataAdapter=j.Decorate(l.dataAdapter,q)),null!=l.query){var C=b(l.amdBase+"compat/query");l.dataAdapter=j.Decorate(l.dataAdapter,C)}if(null!=l.initSelection){var D=b(l.amdBase+"compat/initSelection");l.dataAdapter=j.Decorate(l.dataAdapter,D)}}if(null==l.resultsAdapter&&(l.resultsAdapter=c,null!=l.ajax&&(l.resultsAdapter=j.Decorate(l.resultsAdapter,x)),null!=l.placeholder&&(l.resultsAdapter=j.Decorate(l.resultsAdapter,w)),l.selectOnClose&&(l.resultsAdapter=j.Decorate(l.resultsAdapter,A))),null==l.dropdownAdapter){if(l.multiple)l.dropdownAdapter=u;else{var E=j.Decorate(u,v);l.dropdownAdapter=E}if(0!==l.minimumResultsForSearch&&(l.dropdownAdapter=j.Decorate(l.dropdownAdapter,z)),l.closeOnSelect&&(l.dropdownAdapter=j.Decorate(l.dropdownAdapter,B)),null!=l.dropdownCssClass||null!=l.dropdownCss||null!=l.adaptDropdownCssClass){var F=b(l.amdBase+"compat/dropdownCss");l.dropdownAdapter=j.Decorate(l.dropdownAdapter,F)}l.dropdownAdapter=j.Decorate(l.dropdownAdapter,y)}if(null==l.selectionAdapter){if(l.multiple?l.selectionAdapter=e:l.selectionAdapter=d,null!=l.placeholder&&(l.selectionAdapter=j.Decorate(l.selectionAdapter,f)),l.allowClear&&(l.selectionAdapter=j.Decorate(l.selectionAdapter,g)),l.multiple&&(l.selectionAdapter=j.Decorate(l.selectionAdapter,h)),null!=l.containerCssClass||null!=l.containerCss||null!=l.adaptContainerCssClass){var G=b(l.amdBase+"compat/containerCss");l.selectionAdapter=j.Decorate(l.selectionAdapter,G)}l.selectionAdapter=j.Decorate(l.selectionAdapter,i)}if("string"==typeof l.language)if(l.language.indexOf("-")>0){var H=l.language.split("-"),I=H[0];l.language=[l.language,I]}else l.language=[l.language];if(a.isArray(l.language)){var J=new k;l.language.push("en");for(var K=l.language,L=0;L0){for(var f=a.extend(!0,{},e),g=e.children.length-1;g>=0;g--){null==c(d,e.children[g])&&f.children.splice(g,1)}return f.children.length>0?f:c(d,f)}var h=b(e.text).toUpperCase(),i=b(d.term).toUpperCase();return h.indexOf(i)>-1?e:null}this.defaults={amdBase:"./",amdLanguageBase:"./i18n/",closeOnSelect:!0,debug:!1,dropdownAutoWidth:!1,escapeMarkup:j.escapeMarkup,language:C,matcher:c,minimumInputLength:0,maximumInputLength:0,maximumSelectionLength:0,minimumResultsForSearch:0,selectOnClose:!1,sorter:function(a){return a},templateResult:function(a){return a.text},templateSelection:function(a){return a.text},theme:"default",width:"resolve"}},D.prototype.set=function(b,c){var d=a.camelCase(b),e={};e[d]=c;var f=j._convertData(e);a.extend(this.defaults,f)},new D}),b.define("select2/options",["require","jquery","./defaults","./utils"],function(a,b,c,d){function e(b,e){if(this.options=b,null!=e&&this.fromElement(e),this.options=c.apply(this.options),e&&e.is("input")){var f=a(this.get("amdBase")+"compat/inputData");this.options.dataAdapter=d.Decorate(this.options.dataAdapter,f)}}return e.prototype.fromElement=function(a){var c=["select2"];null==this.options.multiple&&(this.options.multiple=a.prop("multiple")),null==this.options.disabled&&(this.options.disabled=a.prop("disabled")),null==this.options.language&&(a.prop("lang")?this.options.language=a.prop("lang").toLowerCase():a.closest("[lang]").prop("lang")&&(this.options.language=a.closest("[lang]").prop("lang"))),null==this.options.dir&&(a.prop("dir")?this.options.dir=a.prop("dir"):a.closest("[dir]").prop("dir")?this.options.dir=a.closest("[dir]").prop("dir"):this.options.dir="ltr"),a.prop("disabled",this.options.disabled),a.prop("multiple",this.options.multiple),a.data("select2Tags")&&(this.options.debug&&window.console&&console.warn&&console.warn('Select2: The `data-select2-tags` attribute has been changed to use the `data-data` and `data-tags="true"` attributes and will be removed in future versions of Select2.'),a.data("data",a.data("select2Tags")),a.data("tags",!0)),a.data("ajaxUrl")&&(this.options.debug&&window.console&&console.warn&&console.warn("Select2: The `data-ajax-url` attribute has been changed to `data-ajax--url` and support for the old attribute will be removed in future versions of Select2."),a.attr("ajax--url",a.data("ajaxUrl")),a.data("ajax--url",a.data("ajaxUrl")));var e={};e=b.fn.jquery&&"1."==b.fn.jquery.substr(0,2)&&a[0].dataset?b.extend(!0,{},a[0].dataset,a.data()):a.data();var f=b.extend(!0,{},e);f=d._convertData(f);for(var g in f)b.inArray(g,c)>-1||(b.isPlainObject(this.options[g])?b.extend(this.options[g],f[g]):this.options[g]=f[g]);return this},e.prototype.get=function(a){return this.options[a]},e.prototype.set=function(a,b){this.options[a]=b},e}),b.define("select2/core",["jquery","./options","./utils","./keys"],function(a,b,c,d){var e=function(a,c){null!=a.data("select2")&&a.data("select2").destroy(),this.$element=a,this.id=this._generateId(a),c=c||{},this.options=new b(c,a),e.__super__.constructor.call(this);var d=a.attr("tabindex")||0;a.data("old-tabindex",d),a.attr("tabindex","-1");var f=this.options.get("dataAdapter");this.dataAdapter=new f(a,this.options);var g=this.render();this._placeContainer(g);var h=this.options.get("selectionAdapter");this.selection=new h(a,this.options),this.$selection=this.selection.render(),this.selection.position(this.$selection,g);var i=this.options.get("dropdownAdapter");this.dropdown=new i(a,this.options),this.$dropdown=this.dropdown.render(),this.dropdown.position(this.$dropdown,g);var j=this.options.get("resultsAdapter");this.results=new j(a,this.options,this.dataAdapter),this.$results=this.results.render(),this.results.position(this.$results,this.$dropdown);var k=this;this._bindAdapters(),this._registerDomEvents(),this._registerDataEvents(),this._registerSelectionEvents(),this._registerDropdownEvents(),this._registerResultsEvents(),this._registerEvents(),this.dataAdapter.current(function(a){k.trigger("selection:update",{data:a})}),a.addClass("select2-hidden-accessible"),a.attr("aria-hidden","true"),this._syncAttributes(),a.data("select2",this)};return c.Extend(e,c.Observable),e.prototype._generateId=function(a){var b="";return b=null!=a.attr("id")?a.attr("id"):null!=a.attr("name")?a.attr("name")+"-"+c.generateChars(2):c.generateChars(4),b=b.replace(/(:|\.|\[|\]|,)/g,""),b="select2-"+b},e.prototype._placeContainer=function(a){a.insertAfter(this.$element);var b=this._resolveWidth(this.$element,this.options.get("width"));null!=b&&a.css("width",b)},e.prototype._resolveWidth=function(a,b){var c=/^width:(([-+]?([0-9]*\.)?[0-9]+)(px|em|ex|%|in|cm|mm|pt|pc))/i;if("resolve"==b){var d=this._resolveWidth(a,"style");return null!=d?d:this._resolveWidth(a,"element")}if("element"==b){var e=a.outerWidth(!1);return e<=0?"auto":e+"px"}if("style"==b){var f=a.attr("style");if("string"!=typeof f)return null;for(var g=f.split(";"),h=0,i=g.length;h=1)return k[1]}return null}return b},e.prototype._bindAdapters=function(){this.dataAdapter.bind(this,this.$container),this.selection.bind(this,this.$container),this.dropdown.bind(this,this.$container),this.results.bind(this,this.$container)},e.prototype._registerDomEvents=function(){var b=this;this.$element.on("change.select2",function(){b.dataAdapter.current(function(a){b.trigger("selection:update",{data:a})})}),this.$element.on("focus.select2",function(a){b.trigger("focus",a)}),this._syncA=c.bind(this._syncAttributes,this),this._syncS=c.bind(this._syncSubtree,this),this.$element[0].attachEvent&&this.$element[0].attachEvent("onpropertychange",this._syncA);var d=window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver;null!=d?(this._observer=new d(function(c){a.each(c,b._syncA),a.each(c,b._syncS)}),this._observer.observe(this.$element[0],{attributes:!0,childList:!0,subtree:!1})):this.$element[0].addEventListener&&(this.$element[0].addEventListener("DOMAttrModified",b._syncA,!1),this.$element[0].addEventListener("DOMNodeInserted",b._syncS,!1),this.$element[0].addEventListener("DOMNodeRemoved",b._syncS,!1))},e.prototype._registerDataEvents=function(){var a=this;this.dataAdapter.on("*",function(b,c){a.trigger(b,c)})},e.prototype._registerSelectionEvents=function(){var b=this,c=["toggle","focus"];this.selection.on("toggle",function(){b.toggleDropdown()}),this.selection.on("focus",function(a){b.focus(a)}),this.selection.on("*",function(d,e){-1===a.inArray(d,c)&&b.trigger(d,e)})},e.prototype._registerDropdownEvents=function(){var a=this;this.dropdown.on("*",function(b,c){a.trigger(b,c)})},e.prototype._registerResultsEvents=function(){var a=this;this.results.on("*",function(b,c){a.trigger(b,c)})},e.prototype._registerEvents=function(){var b=this;this.on("open",function(){b.$container.addClass("select2-container--open")}),this.on("close",function(){b.$container.removeClass("select2-container--open")}),this.on("enable",function(){b.$container.removeClass("select2-container--disabled")}),this.on("disable",function(){b.$container.addClass("select2-container--disabled")}),this.on("blur",function(){b.$container.removeClass("select2-container--focus")}),this.on("query",function(a){b.isOpen()||b.trigger("open",{}),this.dataAdapter.query(a,function(c){b.trigger("results:all",{data:c,query:a})})}),this.on("query:append",function(a){this.dataAdapter.query(a,function(c){b.trigger("results:append",{data:c,query:a})})}),this.on("open",function(){setTimeout(function(){b.focusOnActiveElement()},1)}),a(document).on("keydown",function(a){var c=a.which;if(b.isOpen()){c===d.ESC||c===d.UP&&a.altKey?(b.close(),a.preventDefault()):c===d.ENTER||c===d.TAB?(b.trigger("results:select",{}),a.preventDefault()):c===d.SPACE&&a.ctrlKey?(b.trigger("results:toggle",{}),a.preventDefault()):c===d.UP?(b.trigger("results:previous",{}),a.preventDefault()):c===d.DOWN&&(b.trigger("results:next",{}),a.preventDefault());var e=b.$dropdown.find(".select2-search__field");e.length||(e=b.$container.find(".select2-search__field")),c===d.DOWN||c===d.UP?b.focusOnActiveElement():(e.focus(),setTimeout(function(){b.focusOnActiveElement()},1e3))}else b.hasFocus()&&(c!==d.ENTER&&c!==d.SPACE&&c!==d.DOWN||(b.open(),a.preventDefault()))})},e.prototype.focusOnActiveElement=function(){this.isOpen()&&!c.isTouchscreen()&&this.$results.find("li.select2-results__option--highlighted").focus()},e.prototype._syncAttributes=function(){this.options.set("disabled",this.$element.prop("disabled")),this.options.get("disabled")?(this.isOpen()&&this.close(),this.trigger("disable",{})):this.trigger("enable",{})},e.prototype._syncSubtree=function(a,b){var c=!1,d=this;if(!a||!a.target||"OPTION"===a.target.nodeName||"OPTGROUP"===a.target.nodeName){if(b)if(b.addedNodes&&b.addedNodes.length>0)for(var e=0;e0&&(c=!0);else c=!0;c&&this.dataAdapter.current(function(a){d.trigger("selection:update",{data:a})})}},e.prototype.trigger=function(a,b){var c=e.__super__.trigger,d={open:"opening",close:"closing",select:"selecting",unselect:"unselecting"};if(void 0===b&&(b={}),a in d){var f=d[a],g={prevented:!1,name:a,args:b};if(c.call(this,f,g),g.prevented)return void(b.prevented=!0)}c.call(this,a,b)},e.prototype.toggleDropdown=function(){this.options.get("disabled")||(this.isOpen()?this.close():this.open())},e.prototype.open=function(){this.isOpen()||this.trigger("query",{})},e.prototype.close=function(){this.isOpen()&&this.trigger("close",{})},e.prototype.isOpen=function(){return this.$container.hasClass("select2-container--open")},e.prototype.hasFocus=function(){return this.$container.hasClass("select2-container--focus")},e.prototype.focus=function(a){this.hasFocus()||(this.$container.addClass("select2-container--focus"),this.trigger("focus",{}))},e.prototype.enable=function(a){this.options.get("debug")&&window.console&&console.warn&&console.warn('Select2: The `select2("enable")` method has been deprecated and will be removed in later Select2 versions. Use $element.prop("disabled") instead.'),null!=a&&0!==a.length||(a=[!0]);var b=!a[0];this.$element.prop("disabled",b)},e.prototype.data=function(){this.options.get("debug")&&arguments.length>0&&window.console&&console.warn&&console.warn('Select2: Data can no longer be set using `select2("data")`. You should consider setting the value instead using `$element.val()`.');var a=[];return this.dataAdapter.current(function(b){a=b}),a},e.prototype.val=function(b){if(this.options.get("debug")&&window.console&&console.warn&&console.warn('Select2: The `select2("val")` method has been deprecated and will be removed in later Select2 versions. Use $element.val() instead.'),null==b||0===b.length)return this.$element.val();var c=b[0];a.isArray(c)&&(c=a.map(c,function(a){return a.toString()})),this.$element.val(c).trigger("change")},e.prototype.destroy=function(){this.$container.remove(),this.$element[0].detachEvent&&this.$element[0].detachEvent("onpropertychange",this._syncA),null!=this._observer?(this._observer.disconnect(),this._observer=null):this.$element[0].removeEventListener&&(this.$element[0].removeEventListener("DOMAttrModified",this._syncA,!1),this.$element[0].removeEventListener("DOMNodeInserted",this._syncS,!1),this.$element[0].removeEventListener("DOMNodeRemoved",this._syncS,!1)),this._syncA=null,this._syncS=null,this.$element.off(".select2"),this.$element.attr("tabindex",this.$element.data("old-tabindex")),this.$element.removeClass("select2-hidden-accessible"),this.$element.attr("aria-hidden","false"),this.$element.removeData("select2"),this.dataAdapter.destroy(),this.selection.destroy(),this.dropdown.destroy(),this.results.destroy(),this.dataAdapter=null,this.selection=null,this.dropdown=null,this.results=null},e.prototype.render=function(){var b=a('');return b.attr("dir",this.options.get("dir")),this.$container=b,this.$container.addClass("select2-container--"+this.options.get("theme")),b.data("element",this.$element),b},e}),b.define("jquery-mousewheel",["jquery"],function(a){return a}),b.define("jquery.select2",["jquery","jquery-mousewheel","./select2/core","./select2/defaults"],function(a,b,c,d){if(null==a.fn.selectWoo){var e=["open","close","destroy"];a.fn.selectWoo=function(b){if("object"==typeof(b=b||{}))return this.each(function(){var d=a.extend(!0,{},b);new c(a(this),d)}),this;if("string"==typeof b){var d,f=Array.prototype.slice.call(arguments,1);return this.each(function(){var c=a(this).data("select2");null==c&&window.console&&console.error&&console.error("The select2('"+b+"') method was called on an element that is not using Select2."),d=c[b].apply(c,f)}),a.inArray(b,e)>-1?this:d}throw new Error("Invalid arguments for Select2: "+b)}}return null!=a.fn.select2&&null!=a.fn.select2.defaults&&(a.fn.selectWoo.defaults=a.fn.select2.defaults),null==a.fn.selectWoo.defaults&&(a.fn.selectWoo.defaults=d),a.fn.select2=a.fn.select2||a.fn.selectWoo,c}),{define:b.define,require:b.require}}(),c=b.require("jquery.select2");return a.fn.select2.amd=b,a.fn.selectWoo.amd=b,c}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/slider-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/slider-customizer.js deleted file mode 100644 index d517ffc9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/slider-customizer.js +++ /dev/null @@ -1,137 +0,0 @@ -wp.customize.controlConstructor[ 'generatepress-pro-range-slider' ] = wp.customize.Control.extend( { - ready() { - 'use strict'; - - var control = this, - value, - controlClass = '.customize-control-generatepress-pro-range-slider', - footerActions = jQuery( '#customize-footer-actions' ); - - // Set up the sliders - jQuery( '.generatepress-slider' ).each( function() { - var _this = jQuery( this ); - var _input = _this.closest( 'label' ).find( 'input[type="number"]' ); - var _text = _input.next( '.value' ); - - _this.slider( { - value: _input.val(), - min: _this.data( 'min' ), - max: _this.data( 'max' ), - step: _this.data( 'step' ), - slide( event, ui ) { - _input.val( ui.value ).change(); - _text.text( ui.value ); - }, - } ); - } ); - - // Update the range value based on the input value - jQuery( controlClass + ' .gp_range_value input[type=number]' ).on( 'input', function() { - value = jQuery( this ).attr( 'value' ); - - if ( '' == value ) { - value = -1; - } - - jQuery( this ).closest( 'label' ).find( '.generatepress-slider' ).slider( 'value', parseFloat( value ) ).change(); - } ); - - // Handle the reset button - jQuery( controlClass + ' .generatepress-reset' ).on( 'click', function() { - var icon = jQuery( this ), - visibleArea = icon.closest( '.gp-range-title-area' ).next( '.gp-range-slider-areas' ).children( 'label:visible' ), - input = visibleArea.find( 'input[type=number]' ), - sliderValue = visibleArea.find( '.generatepress-slider' ), - visualValue = visibleArea.find( '.gp_range_value' ), - resetValue = input.attr( 'data-reset_value' ); - - input.val( resetValue ).change(); - visualValue.find( 'input' ).val( resetValue ); - visualValue.find( '.value' ).text( resetValue ); - - if ( '' == resetValue ) { - resetValue = -1; - } - - sliderValue.slider( 'value', parseFloat( resetValue ) ); - } ); - - // Figure out which device icon to make active on load - jQuery( controlClass + ' .generatepress-range-slider-control' ).each( function() { - var _this = jQuery( this ); - - _this.find( '.gp-device-controls' ).children( 'span:first-child' ).addClass( 'selected' ); - _this.find( '.range-option-area:first-child' ).show(); - } ); - - // Do stuff when device icons are clicked - jQuery( controlClass + ' .gp-device-controls > span' ).on( 'click', function( event ) { - var device = jQuery( this ).data( 'option' ); - - jQuery( controlClass + ' .gp-device-controls span' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.addClass( 'selected' ); - _this.siblings().removeClass( 'selected' ); - } - } ); - - jQuery( controlClass + ' .gp-range-slider-areas label' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.show(); - _this.siblings().hide(); - } - } ); - - // Set the device we're currently viewing - wp.customize.previewedDevice.set( jQuery( event.currentTarget ).data( 'option' ) ); - } ); - - // Set the selected devices in our control when the Customizer devices are clicked - footerActions.find( '.devices button' ).on( 'click', function() { - var device = jQuery( this ).data( 'device' ); - - jQuery( controlClass + ' .gp-device-controls span' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.addClass( 'selected' ); - _this.siblings().removeClass( 'selected' ); - } - } ); - - jQuery( controlClass + ' .gp-range-slider-areas label' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.show(); - _this.siblings().hide(); - } - } ); - } ); - - // Apply changes when desktop slider is changed - control.container.on( 'input change', '.desktop-range', - function() { - control.settings.desktop.set( jQuery( this ).val() ); - } - ); - - // Apply changes when tablet slider is changed - control.container.on( 'input change', '.tablet-range', - function() { - control.settings.tablet.set( jQuery( this ).val() ); - } - ); - - // Apply changes when mobile slider is changed - control.container.on( 'input change', '.mobile-range', - function() { - control.settings.mobile.set( jQuery( this ).val() ); - } - ); - }, -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/spacing-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/spacing-customizer.js deleted file mode 100644 index 35c205d4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/spacing-customizer.js +++ /dev/null @@ -1,203 +0,0 @@ -( function( $, api ) { - // No longer needed as of 1.2.95 - // Keeping it here just in case - api.controlConstructor.spacing = api.Control.extend( { - ready() { - var control = this; - $( '.generate-number-control', control.container ).on( 'change keyup', - function() { - control.setting.set( $( this ).val() ); - } - ); - }, - } ); - - api.controlConstructor[ 'gp-spacing-slider' ] = api.Control.extend( { - ready() { - var control = this; - $( '.slider-input', control.container ).on( 'change keyup', - function() { - control.setting.set( $( this ).val() ); - } - ); - }, - } ); - - api.controlConstructor[ 'generatepress-spacing' ] = api.Control.extend( { - ready() { - var control = this, - controlClass = '.customize-control-generatepress-spacing', - footerActions = jQuery( '#customize-footer-actions' ); - - // Figure out which device icon to make active on load - jQuery( controlClass + ' .gp-spacing-control-section' ).each( function() { - var _this = jQuery( this ); - _this.find( '.gp-device-controls' ).children( 'span:first-child' ).addClass( 'selected' ); - _this.find( '.spacing-values-area:first-child' ).show(); - } ); - - // Do stuff when device icons are clicked - jQuery( controlClass + ' .gp-device-controls > span' ).on( 'click', function( event ) { - var device = jQuery( this ).data( 'option' ); - - jQuery( controlClass + ' .gp-device-controls span' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.addClass( 'selected' ); - _this.siblings().removeClass( 'selected' ); - } - } ); - - jQuery( controlClass + ' .spacing-values-container .spacing-values-area' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.show(); - _this.siblings().hide(); - } - } ); - - // Set the device we're currently viewing - wp.customize.previewedDevice.set( jQuery( event.currentTarget ).data( 'option' ) ); - } ); - - // Set the selected devices in our control when the Customizer devices are clicked - footerActions.find( '.devices button' ).on( 'click', function() { - var device = jQuery( this ).data( 'device' ); - jQuery( controlClass + ' .gp-device-controls span' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.addClass( 'selected' ); - _this.siblings().removeClass( 'selected' ); - } - } ); - - jQuery( controlClass + ' .spacing-values-container .spacing-values-area' ).each( function() { - var _this = jQuery( this ); - - if ( device === _this.attr( 'data-option' ) ) { - _this.show(); - _this.siblings().hide(); - } - } ); - } ); - - control.container.on( 'change keyup', '.spacing-top', - function() { - control.settings.desktop_top.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.spacing-right', - function() { - control.settings.desktop_right.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.spacing-bottom', - function() { - control.settings.desktop_bottom.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.spacing-left', - function() { - control.settings.desktop_left.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.tablet-spacing-top', - function() { - control.settings.tablet_top.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.tablet-spacing-right', - function() { - control.settings.tablet_right.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.tablet-spacing-bottom', - function() { - control.settings.tablet_bottom.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.tablet-spacing-left', - function() { - control.settings.tablet_left.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.mobile-spacing-top', - function() { - control.settings.mobile_top.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.mobile-spacing-right', - function() { - control.settings.mobile_right.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.mobile-spacing-bottom', - function() { - control.settings.mobile_bottom.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change keyup', '.mobile-spacing-left', - function() { - control.settings.mobile_left.set( jQuery( this ).val() ); - } - ); - }, - } ); -}( jQuery, wp.customize ) ); - -jQuery( function( $ ) { - $( '.gp-link-spacing' ).on( 'click', function( e ) { - e.preventDefault(); - - // Set up variables - var _this = $( this ), - element = _this.data( 'element' ); - - // Add our linked-values class to the next 4 elements - _this.parent( '.gp-spacing-section' ).prevAll().slice( 0, 4 ).find( 'input' ).addClass( 'linked-values' ).attr( 'data-element', element ); - - // Change our link icon class - _this.hide(); - _this.next( 'span' ).show(); - } ); - - $( '.gp-unlink-spacing' ).on( 'click', function( e ) { - e.preventDefault(); - - // Set up variables - var _this = $( this ); - - // Remove our linked-values class to the next 4 elements - _this.parent( '.gp-spacing-section' ).prevAll().slice( 0, 4 ).find( 'input' ).removeClass( 'linked-values' ).attr( 'data-element', '' ); - - // Change our link icon class - _this.hide(); - _this.prev( 'span' ).show(); - } ); - - $( '.gp-spacing-section' ).on( 'input', '.linked-values', function() { - var _this = $( this ), - data = _this.attr( 'data-element' ), - val = _this.val(), - targetElements = _this.closest( '.spacing-values-area' ).find( '.linked-values[ data-element="' + data + '" ]' ); - - targetElements.each( function() { - var element = $( this ); - element.val( val ).change(); - } ); - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/typography-customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/typography-customizer.js deleted file mode 100644 index 1d8b2b3c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/controls/js/typography-customizer.js +++ /dev/null @@ -1,148 +0,0 @@ -( function( api ) { - api.controlConstructor[ 'gp-pro-customizer-typography' ] = api.Control.extend( { - ready() { - var control = this; - - control.container.on( 'change', '.generatepress-font-family select', - function() { - var _this = jQuery( this ), - _value = _this.val(), - _categoryID = _this.attr( 'data-category' ), - _variantsID = _this.attr( 'data-variants' ); - - // Set our font family - control.settings.family.set( _this.val() ); - - // Bail if our controls don't exist - if ( 'undefined' === typeof control.settings.category || 'undefined' === typeof control.settings.variant ) { - return; - } - - setTimeout( function() { - // Send our request to the generate_get_all_google_fonts_ajax function - var response = jQuery.getJSON( { - type: 'POST', - url: ajaxurl, - data: { - action: 'generate_get_all_google_fonts_ajax', - gp_customize_nonce: gp_customize.nonce, - }, - async: false, - dataType: 'json', - } ); - - // Get our response - var fonts = response.responseJSON; - - // Create an ID from our selected font - var id = _value.split( ' ' ).join( '_' ).toLowerCase(); - - // Set our values if we have them - if ( id in fonts ) { - // Get existing variants if this font is already selected - var got_variants = false; - jQuery( '.generatepress-font-family select' ).not( _this ).each( function( key, select ) { - var parent = jQuery( this ).closest( '.generatepress-font-family' ); - - if ( _value == jQuery( select ).val() && _this.data( 'category' ) !== jQuery( select ).data( 'category' ) ) { - if ( ! got_variants ) { - updated_variants = jQuery( parent.next( '.generatepress-font-variant' ).find( 'select' ) ).val(); - got_variants = true; - } - } - } ); - - // We're using a Google font, so show the variants field - _this.closest( '.generatepress-font-family' ).next( 'div' ).show(); - - // Remove existing variants - jQuery( 'select[name="' + _variantsID + '"]' ).find( 'option' ).remove(); - - // Populate our select input with available variants - jQuery.each( fonts[ id ].variants, function( key, value ) { - jQuery( 'select[name="' + _variantsID + '"]' ).append( jQuery( '' ).attr( 'value', value ).text( value ) ); - } ); - - // Set our variants - if ( ! got_variants ) { - control.settings.variant.set( fonts[ id ].variants ); - } else { - control.settings.variant.set( updated_variants ); - } - - // Set our font category - control.settings.category.set( fonts[ id ].category ); - jQuery( 'input[name="' + _categoryID + '"' ).val( fonts[ id ].category ); - } else { - _this.closest( '.generatepress-font-family' ).next( 'div' ).hide(); - control.settings.category.set( '' ); - control.settings.variant.set( '' ); - jQuery( 'input[name="' + _categoryID + '"' ).val( '' ); - jQuery( 'select[name="' + _variantsID + '"]' ).find( 'option' ).remove(); - } - }, 25 ); - } - ); - - control.container.on( 'change', '.generatepress-font-variant select', - function() { - var _this = jQuery( this ); - var variants = _this.val(); - - control.settings.variant.set( variants ); - - jQuery( '.generatepress-font-variant select' ).each( function( key, value ) { - var this_control = jQuery( this ).closest( 'li' ).attr( 'id' ).replace( 'customize-control-', '' ); - var parent = jQuery( this ).closest( '.generatepress-font-variant' ); - var font_val = api.control( this_control ).settings.family.get(); - - if ( font_val == control.settings.family.get() && _this.attr( 'name' ) !== jQuery( value ).attr( 'name' ) ) { - jQuery( parent.find( 'select' ) ).not( _this ).val( variants ).triggerHandler( 'change' ); - api.control( this_control ).settings.variant.set( variants ); - } - } ); - } - ); - - control.container.on( 'change', '.generatepress-font-category input', - function() { - control.settings.category.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change', '.generatepress-font-weight select', - function() { - control.settings.weight.set( jQuery( this ).val() ); - } - ); - - control.container.on( 'change', '.generatepress-font-transform select', - function() { - control.settings.transform.set( jQuery( this ).val() ); - } - ); - }, - } ); -}( wp.customize ) ); - -jQuery( document ).ready( function( $ ) { - jQuery( '.generatepress-font-family select' ).selectWoo(); - jQuery( '.generatepress-font-variant' ).each( function( key, value ) { - var _this = $( this ); - value = _this.data( 'saved-value' ); - - if ( value ) { - value = value.toString().split( ',' ); - } - - _this.find( 'select' ).selectWoo().val( value ).trigger( 'change.select2' ); - } ); - - $( '.generatepress-font-family' ).each( function( key, value ) { - var _this = $( this ); - - if ( $.inArray( _this.find( 'select' ).val(), typography_defaults ) !== -1 ) { - _this.next( '.generatepress-font-variant' ).hide(); - } - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/deprecated.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/deprecated.php deleted file mode 100644 index 00dd2f9e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/deprecated.php +++ /dev/null @@ -1,324 +0,0 @@ -manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_backgrounds_is_top_bar_active' ) ) : -/** - * Check to see if the top bar is active - * - * @since 1.3.45 - */ -function generate_backgrounds_is_top_bar_active() -{ - $top_bar = is_active_sidebar( 'top-bar' ) ? true : false; - return apply_filters( 'generate_is_top_bar_active', $top_bar ); -} -endif; - -if ( ! function_exists( 'generate_blog_sanitize_choices' ) ) : -/** - * Sanitize choices - */ -function generate_blog_sanitize_choices( $input, $setting ) { - - // Ensure input is a slug - $input = sanitize_key( $input ); - - // Get list of choices from the control - // associated with the setting - $choices = $setting->manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_blog_is_posts_page' ) ) : -/** - * Check to see if we're on a posts page - */ -function generate_blog_is_posts_page() -{ - $blog = ( is_home() || is_archive() || is_attachment() || is_tax() ) ? true : false; - - return $blog; -} -endif; - -if ( ! function_exists( 'generate_blog_is_posts_page_single' ) ) : -/** - * Check to see if we're on a posts page or a single post - */ -function generate_blog_is_posts_page_single() -{ - $blog = ( is_home() || is_archive() || is_attachment() || is_tax() || is_single() ) ? true : false; - - return $blog; -} -endif; - -if ( ! function_exists( 'generate_blog_is_excerpt' ) ) : -/** - * Check to see if we're displaying excerpts - */ -function generate_blog_is_excerpt() -{ - if ( ! function_exists( 'generate_get_defaults' ) ) - return; - - $generate_settings = wp_parse_args( - get_option( 'generate_settings', array() ), - generate_get_defaults() - ); - - return ( 'excerpt' == $generate_settings['post_content'] ) ? true : false; -} -endif; - -if ( ! function_exists( 'generate_colors_sanitize_hex_color' ) ) : -/** - * Sanitize hex colors - * We don't use the core function as we want to allow empty values - * @since 0.1 - */ -function generate_colors_sanitize_hex_color( $color ) { - if ( '' === $color ) - return ''; - - // 3 or 6 hex digits, or the empty string. - if ( preg_match('|^#([A-Fa-f0-9]{3}){1,2}$|', $color ) ) - return $color; - - return ''; -} -endif; - -if ( ! function_exists( 'generate_colors_sanitize_rgba' ) ) : -/** - * Sanitize RGBA colors - * @since 1.3.42 - */ -function generate_colors_sanitize_rgba( $color ) { - if ( '' === $color ) - return ''; - - // If string does not start with 'rgba', then treat as hex - // sanitize the hex color and finally convert hex to rgba - if ( false === strpos( $color, 'rgba' ) ) { - return generate_colors_sanitize_hex_color( $color ); - } - - // By now we know the string is formatted as an rgba color so we need to further sanitize it. - $color = str_replace( ' ', '', $color ); - sscanf( $color, 'rgba(%d,%d,%d,%f)', $red, $green, $blue, $alpha ); - return 'rgba('.$red.','.$green.','.$blue.','.$alpha.')'; - - return ''; -} -endif; - -if ( ! function_exists( 'generate_menu_plus_sanitize_choices' ) ) : -/** - * Sanitize choices - */ -function generate_menu_plus_sanitize_choices( $input, $setting ) { - - // Ensure input is a slug - $input = sanitize_key( $input ); - - // Get list of choices from the control - // associated with the setting - $choices = $setting->manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_page_header_is_posts_page' ) ) : -/** - * This is an active_callback - * Check if we're on a posts page - */ -function generate_page_header_is_posts_page() -{ - $blog = ( is_home() || is_archive() || is_attachment() || is_tax() ) ? true : false; - - return $blog; -} -endif; - -if ( ! function_exists( 'generate_page_header_is_posts_page_single' ) ) : -/** - * Check to see if we're on a posts page or a single post - */ -function generate_page_header_is_posts_page_single() -{ - $blog = ( is_home() || is_archive() || is_attachment() || is_tax() || is_single() ) ? true : false; - - return $blog; -} -endif; - -if ( ! function_exists( 'generate_secondary_nav_sanitize_choices' ) ) : -/** - * Sanitize choices - */ -function generate_secondary_nav_sanitize_choices( $input, $setting ) { - - // Ensure input is a slug - $input = sanitize_key( $input ); - - // Get list of choices from the control - // associated with the setting - $choices = $setting->manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_spacing_sanitize_choices' ) ) : -/** - * Sanitize choices - */ -function generate_spacing_sanitize_choices( $input, $setting ) { - - // Ensure input is a slug - $input = sanitize_key( $input ); - - // Get list of choices from the control - // associated with the setting - $choices = $setting->manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_premium_sanitize_typography' ) ) : -/** - * Sanitize typography dropdown - * @since 1.1.10 - * @deprecated 1.2.95 - */ -function generate_premium_sanitize_typography( $input ) -{ - if ( ! function_exists( 'generate_get_all_google_fonts' ) || ! function_exists( 'generate_typography_default_fonts' ) ) { - return 'Open Sans'; - } - - // Grab all of our fonts - $fonts = generate_get_all_google_fonts(); - - // Loop through all of them and grab their names - $font_names = array(); - foreach ( $fonts as $k => $fam ) { - $font_names[] = $fam['name']; - } - - // Get all non-Google font names - $not_google = generate_typography_default_fonts(); - - // Merge them both into one array - $valid = array_merge( $font_names, $not_google ); - - // Sanitize - if ( in_array( $input, $valid ) ) { - return $input; - } else { - return 'Open Sans'; - } -} -endif; - -if ( ! function_exists( 'generate_typography_sanitize_choices' ) ) : -/** - * Sanitize choices - * @since 1.3.24 - */ -function generate_typography_sanitize_choices( $input, $setting ) { - - // Ensure input is a slug - $input = sanitize_key( $input ); - - // Get list of choices from the control - // associated with the setting - $choices = $setting->manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_page_header_sanitize_choices' ) ) : -/** - * Sanitize our select inputs - */ -function generate_page_header_sanitize_choices( $input, $setting ) { - - // Ensure input is a slug - $input = sanitize_key( $input ); - - // Get list of choices from the control - // associated with the setting - $choices = $setting->manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); -} -endif; - -if ( ! function_exists( 'generate_page_header_sanitize_hex_color' ) ) : -/** - * Sanitize colors - * We don't use the core function as we want to allow empty values - */ -function generate_page_header_sanitize_hex_color( $color ) { - if ( '' === $color ) - return ''; - - // 3 or 6 hex digits, or the empty string. - if ( preg_match('|^#([A-Fa-f0-9]{3}){1,2}$|', $color ) ) - return $color; - - return ''; -} -endif; - -if ( ! function_exists( 'generate_page_header_sanitize_html' ) ) : -/** - * Sanitize our fields that accept HTML - */ -function generate_page_header_sanitize_html( $input ) -{ - return wp_kses_post( $input ); -} -endif; \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/sanitize.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/sanitize.php deleted file mode 100644 index a0cb7efc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/customizer/sanitize.php +++ /dev/null @@ -1,131 +0,0 @@ -manager->get_control( $setting->id )->choices; - - // If the input is a valid key, return it; - // otherwise, return the default - return ( array_key_exists( $input, $choices ) ? $input : $setting->default ); - } -} - -if ( ! function_exists( 'generate_premium_sanitize_checkbox' ) ) { - /** - * Sanitize checkbox - */ - function generate_premium_sanitize_checkbox( $checked ) { - // Boolean check. - return ( ( isset( $checked ) && true == $checked ) ? true : false ); - } -} - -if ( ! function_exists( 'generate_premium_sanitize_hex_color' ) ) { - /** - * Sanitize hex colors - * We don't use the core function as we want to allow empty values - * - * @since 0.1 - */ - function generate_premium_sanitize_hex_color( $color ) { - if ( '' === $color ) { - return ''; - } - - // 3 or 6 hex digits, or the empty string. - if ( preg_match('|^#([A-Fa-f0-9]{3}){1,2}$|', $color ) ) { - return $color; - } - - return ''; - } -} - -if ( ! function_exists( 'generate_premium_sanitize_rgba' ) ) { - /** - * Sanitize RGBA colors - * - * @since 1.3.42 - */ - function generate_premium_sanitize_rgba( $color ) { - if ( '' === $color ) { - return ''; - } - - // If string does not start with 'rgba', then treat as hex - // sanitize the hex color and finally convert hex to rgba - if ( false === strpos( $color, 'rgba' ) ) { - return generate_premium_sanitize_hex_color( $color ); - } - - // By now we know the string is formatted as an rgba color so we need to further sanitize it. - $color = str_replace( ' ', '', $color ); - sscanf( $color, 'rgba(%d,%d,%d,%f)', $red, $green, $blue, $alpha ); - return 'rgba('.$red.','.$green.','.$blue.','.$alpha.')'; - - return ''; - } -} - -if ( ! function_exists( 'generate_premium_sanitize_decimal_integer' ) ) { - /** - * Sanitize integers that can use decimals - * - * @since 1.3.41 - */ - function generate_premium_sanitize_decimal_integer( $input ) { - return abs( floatval( $input ) ); - } -} - -/** - * Sanitize integers that can use decimals - * @since 1.4 - */ -function generate_premium_sanitize_decimal_integer_empty( $input ) { - if ( '' == $input ) { - return ''; - } - - return abs( floatval( $input ) ); -} - -if ( ! function_exists( 'generate_premium_sanitize_html' ) ) { - /** - * Sanitize our fields that accept HTML - */ - function generate_premium_sanitize_html( $input ) { - return wp_kses_post( $input ); - } -} - -function generate_premium_sanitize_variants( $input ) { - if ( is_array( $input ) ) { - $input = implode( ',', $input ); - } - - return sanitize_text_field( $input ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/select2/select2.full.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/library/select2/select2.full.min.js deleted file mode 100644 index fa781916..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/library/select2/select2.full.min.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ -!function(n){"function"==typeof define&&define.amd?define(["jquery"],n):"object"==typeof module&&module.exports?module.exports=function(e,t){return void 0===t&&(t="undefined"!=typeof window?require("jquery"):require("jquery")(e)),n(t),t}:n(jQuery)}(function(d){var e=function(){if(d&&d.fn&&d.fn.select2&&d.fn.select2.amd)var e=d.fn.select2.amd;var t,n,i,h,o,s,f,g,m,v,y,_,r,a,w,l;function b(e,t){return r.call(e,t)}function c(e,t){var n,i,r,o,s,a,l,c,u,d,p,h=t&&t.split("/"),f=y.map,g=f&&f["*"]||{};if(e){for(s=(e=e.split("/")).length-1,y.nodeIdCompat&&w.test(e[s])&&(e[s]=e[s].replace(w,"")),"."===e[0].charAt(0)&&h&&(e=h.slice(0,h.length-1).concat(e)),u=0;u":">",'"':""","'":"'","/":"/"};return"string"!=typeof e?e:String(e).replace(/[&<>"'\/\\]/g,function(e){return t[e]})},r.appendMany=function(e,t){if("1.7"===o.fn.jquery.substr(0,3)){var n=o();o.map(t,function(e){n=n.add(e)}),t=n}e.append(t)},r.__cache={};var n=0;return r.GetUniqueElementId=function(e){var t=e.getAttribute("data-select2-id");return null==t&&(e.id?(t=e.id,e.setAttribute("data-select2-id",t)):(e.setAttribute("data-select2-id",++n),t=n.toString())),t},r.StoreData=function(e,t,n){var i=r.GetUniqueElementId(e);r.__cache[i]||(r.__cache[i]={}),r.__cache[i][t]=n},r.GetData=function(e,t){var n=r.GetUniqueElementId(e);return t?r.__cache[n]&&null!=r.__cache[n][t]?r.__cache[n][t]:o(e).data(t):r.__cache[n]},r.RemoveData=function(e){var t=r.GetUniqueElementId(e);null!=r.__cache[t]&&delete r.__cache[t],e.removeAttribute("data-select2-id")},r}),e.define("select2/results",["jquery","./utils"],function(h,f){function i(e,t,n){this.$element=e,this.data=n,this.options=t,i.__super__.constructor.call(this)}return f.Extend(i,f.Observable),i.prototype.render=function(){var e=h('
          ');return this.options.get("multiple")&&e.attr("aria-multiselectable","true"),this.$results=e},i.prototype.clear=function(){this.$results.empty()},i.prototype.displayMessage=function(e){var t=this.options.get("escapeMarkup");this.clear(),this.hideLoading();var n=h(''),i=this.options.get("translations").get(e.message);n.append(t(i(e.args))),n[0].className+=" select2-results__message",this.$results.append(n)},i.prototype.hideMessages=function(){this.$results.find(".select2-results__message").remove()},i.prototype.append=function(e){this.hideLoading();var t=[];if(null!=e.results&&0!==e.results.length){e.results=this.sort(e.results);for(var n=0;n",{class:"select2-results__options select2-results__options--nested"});p.append(l),s.append(a),s.append(p)}else this.template(e,t);return f.StoreData(t,"data",e),t},i.prototype.bind=function(t,e){var l=this,n=t.id+"-results";this.$results.attr("id",n),t.on("results:all",function(e){l.clear(),l.append(e.data),t.isOpen()&&(l.setClasses(),l.highlightFirstItem())}),t.on("results:append",function(e){l.append(e.data),t.isOpen()&&l.setClasses()}),t.on("query",function(e){l.hideMessages(),l.showLoading(e)}),t.on("select",function(){t.isOpen()&&(l.setClasses(),l.options.get("scrollAfterSelect")&&l.highlightFirstItem())}),t.on("unselect",function(){t.isOpen()&&(l.setClasses(),l.options.get("scrollAfterSelect")&&l.highlightFirstItem())}),t.on("open",function(){l.$results.attr("aria-expanded","true"),l.$results.attr("aria-hidden","false"),l.setClasses(),l.ensureHighlightVisible()}),t.on("close",function(){l.$results.attr("aria-expanded","false"),l.$results.attr("aria-hidden","true"),l.$results.removeAttr("aria-activedescendant")}),t.on("results:toggle",function(){var e=l.getHighlightedResults();0!==e.length&&e.trigger("mouseup")}),t.on("results:select",function(){var e=l.getHighlightedResults();if(0!==e.length){var t=f.GetData(e[0],"data");"true"==e.attr("aria-selected")?l.trigger("close",{}):l.trigger("select",{data:t})}}),t.on("results:previous",function(){var e=l.getHighlightedResults(),t=l.$results.find("[aria-selected]"),n=t.index(e);if(!(n<=0)){var i=n-1;0===e.length&&(i=0);var r=t.eq(i);r.trigger("mouseenter");var o=l.$results.offset().top,s=r.offset().top,a=l.$results.scrollTop()+(s-o);0===i?l.$results.scrollTop(0):s-o<0&&l.$results.scrollTop(a)}}),t.on("results:next",function(){var e=l.getHighlightedResults(),t=l.$results.find("[aria-selected]"),n=t.index(e)+1;if(!(n>=t.length)){var i=t.eq(n);i.trigger("mouseenter");var r=l.$results.offset().top+l.$results.outerHeight(!1),o=i.offset().top+i.outerHeight(!1),s=l.$results.scrollTop()+o-r;0===n?l.$results.scrollTop(0):rthis.$results.outerHeight()||o<0)&&this.$results.scrollTop(r)}},i.prototype.template=function(e,t){var n=this.options.get("templateResult"),i=this.options.get("escapeMarkup"),r=n(e,t);null==r?t.style.display="none":"string"==typeof r?t.innerHTML=i(r):h(t).append(r)},i}),e.define("select2/keys",[],function(){return{BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46}}),e.define("select2/selection/base",["jquery","../utils","../keys"],function(n,i,r){function o(e,t){this.$element=e,this.options=t,o.__super__.constructor.call(this)}return i.Extend(o,i.Observable),o.prototype.render=function(){var e=n('');return this._tabindex=0,null!=i.GetData(this.$element[0],"old-tabindex")?this._tabindex=i.GetData(this.$element[0],"old-tabindex"):null!=this.$element.attr("tabindex")&&(this._tabindex=this.$element.attr("tabindex")),e.attr("title",this.$element.attr("title")),e.attr("tabindex",this._tabindex),e.attr("aria-disabled","false"),this.$selection=e},o.prototype.bind=function(e,t){var n=this,i=e.id+"-results";this.container=e,this.$selection.on("focus",function(e){n.trigger("focus",e)}),this.$selection.on("blur",function(e){n._handleBlur(e)}),this.$selection.on("keydown",function(e){n.trigger("keypress",e),e.which===r.SPACE&&e.preventDefault()}),e.on("results:focus",function(e){n.$selection.attr("aria-activedescendant",e.data._resultId)}),e.on("selection:update",function(e){n.update(e.data)}),e.on("open",function(){n.$selection.attr("aria-expanded","true"),n.$selection.attr("aria-owns",i),n._attachCloseHandler(e)}),e.on("close",function(){n.$selection.attr("aria-expanded","false"),n.$selection.removeAttr("aria-activedescendant"),n.$selection.removeAttr("aria-owns"),n.$selection.trigger("focus"),n._detachCloseHandler(e)}),e.on("enable",function(){n.$selection.attr("tabindex",n._tabindex),n.$selection.attr("aria-disabled","false")}),e.on("disable",function(){n.$selection.attr("tabindex","-1"),n.$selection.attr("aria-disabled","true")})},o.prototype._handleBlur=function(e){var t=this;window.setTimeout(function(){document.activeElement==t.$selection[0]||n.contains(t.$selection[0],document.activeElement)||t.trigger("blur",e)},1)},o.prototype._attachCloseHandler=function(e){n(document.body).on("mousedown.select2."+e.id,function(e){var t=n(e.target).closest(".select2");n(".select2.select2-container--open").each(function(){this!=t[0]&&i.GetData(this,"element").select2("close")})})},o.prototype._detachCloseHandler=function(e){n(document.body).off("mousedown.select2."+e.id)},o.prototype.position=function(e,t){t.find(".selection").append(e)},o.prototype.destroy=function(){this._detachCloseHandler(this.container)},o.prototype.update=function(e){throw new Error("The `update` method must be defined in child classes.")},o.prototype.isEnabled=function(){return!this.isDisabled()},o.prototype.isDisabled=function(){return this.options.get("disabled")},o}),e.define("select2/selection/single",["jquery","./base","../utils","../keys"],function(e,t,n,i){function r(){r.__super__.constructor.apply(this,arguments)}return n.Extend(r,t),r.prototype.render=function(){var e=r.__super__.render.call(this);return e.addClass("select2-selection--single"),e.html(''),e},r.prototype.bind=function(t,e){var n=this;r.__super__.bind.apply(this,arguments);var i=t.id+"-container";this.$selection.find(".select2-selection__rendered").attr("id",i).attr("role","textbox").attr("aria-readonly","true"),this.$selection.attr("aria-labelledby",i),this.$selection.on("mousedown",function(e){1===e.which&&n.trigger("toggle",{originalEvent:e})}),this.$selection.on("focus",function(e){}),this.$selection.on("blur",function(e){}),t.on("focus",function(e){t.isOpen()||n.$selection.trigger("focus")})},r.prototype.clear=function(){var e=this.$selection.find(".select2-selection__rendered");e.empty(),e.removeAttr("title")},r.prototype.display=function(e,t){var n=this.options.get("templateSelection");return this.options.get("escapeMarkup")(n(e,t))},r.prototype.selectionContainer=function(){return e("")},r.prototype.update=function(e){if(0!==e.length){var t=e[0],n=this.$selection.find(".select2-selection__rendered"),i=this.display(t,n);n.empty().append(i);var r=t.title||t.text;r?n.attr("title",r):n.removeAttr("title")}else this.clear()},r}),e.define("select2/selection/multiple",["jquery","./base","../utils"],function(r,e,l){function n(e,t){n.__super__.constructor.apply(this,arguments)}return l.Extend(n,e),n.prototype.render=function(){var e=n.__super__.render.call(this);return e.addClass("select2-selection--multiple"),e.html('
            '),e},n.prototype.bind=function(e,t){var i=this;n.__super__.bind.apply(this,arguments),this.$selection.on("click",function(e){i.trigger("toggle",{originalEvent:e})}),this.$selection.on("click",".select2-selection__choice__remove",function(e){if(!i.isDisabled()){var t=r(this).parent(),n=l.GetData(t[0],"data");i.trigger("unselect",{originalEvent:e,data:n})}})},n.prototype.clear=function(){var e=this.$selection.find(".select2-selection__rendered");e.empty(),e.removeAttr("title")},n.prototype.display=function(e,t){var n=this.options.get("templateSelection");return this.options.get("escapeMarkup")(n(e,t))},n.prototype.selectionContainer=function(){return r('
          • ×
          • ')},n.prototype.update=function(e){if(this.clear(),0!==e.length){for(var t=[],n=0;n×');a.StoreData(i[0],"data",t),this.$selection.find(".select2-selection__rendered").prepend(i)}},e}),e.define("select2/selection/search",["jquery","../utils","../keys"],function(i,a,l){function e(e,t,n){e.call(this,t,n)}return e.prototype.render=function(e){var t=i('');this.$searchContainer=t,this.$search=t.find("input");var n=e.call(this);return this._transferTabIndex(),n},e.prototype.bind=function(e,t,n){var i=this,r=t.id+"-results";e.call(this,t,n),t.on("open",function(){i.$search.attr("aria-controls",r),i.$search.trigger("focus")}),t.on("close",function(){i.$search.val(""),i.$search.removeAttr("aria-controls"),i.$search.removeAttr("aria-activedescendant"),i.$search.trigger("focus")}),t.on("enable",function(){i.$search.prop("disabled",!1),i._transferTabIndex()}),t.on("disable",function(){i.$search.prop("disabled",!0)}),t.on("focus",function(e){i.$search.trigger("focus")}),t.on("results:focus",function(e){e.data._resultId?i.$search.attr("aria-activedescendant",e.data._resultId):i.$search.removeAttr("aria-activedescendant")}),this.$selection.on("focusin",".select2-search--inline",function(e){i.trigger("focus",e)}),this.$selection.on("focusout",".select2-search--inline",function(e){i._handleBlur(e)}),this.$selection.on("keydown",".select2-search--inline",function(e){if(e.stopPropagation(),i.trigger("keypress",e),i._keyUpPrevented=e.isDefaultPrevented(),e.which===l.BACKSPACE&&""===i.$search.val()){var t=i.$searchContainer.prev(".select2-selection__choice");if(0this.maximumInputLength?this.trigger("results:message",{message:"inputTooLong",args:{maximum:this.maximumInputLength,input:t.term,params:t}}):e.call(this,t,n)},e}),e.define("select2/data/maximumSelectionLength",[],function(){function e(e,t,n){this.maximumSelectionLength=n.get("maximumSelectionLength"),e.call(this,t,n)}return e.prototype.bind=function(e,t,n){var i=this;e.call(this,t,n),t.on("select",function(){i._checkIfMaximumSelected()})},e.prototype.query=function(e,t,n){var i=this;this._checkIfMaximumSelected(function(){e.call(i,t,n)})},e.prototype._checkIfMaximumSelected=function(e,n){var i=this;this.current(function(e){var t=null!=e?e.length:0;0=i.maximumSelectionLength?i.trigger("results:message",{message:"maximumSelected",args:{maximum:i.maximumSelectionLength}}):n&&n()})},e}),e.define("select2/dropdown",["jquery","./utils"],function(t,e){function n(e,t){this.$element=e,this.options=t,n.__super__.constructor.call(this)}return e.Extend(n,e.Observable),n.prototype.render=function(){var e=t('');return e.attr("dir",this.options.get("dir")),this.$dropdown=e},n.prototype.bind=function(){},n.prototype.position=function(e,t){},n.prototype.destroy=function(){this.$dropdown.remove()},n}),e.define("select2/dropdown/search",["jquery","../utils"],function(o,e){function t(){}return t.prototype.render=function(e){var t=e.call(this),n=o('');return this.$searchContainer=n,this.$search=n.find("input"),t.prepend(n),t},t.prototype.bind=function(e,t,n){var i=this,r=t.id+"-results";e.call(this,t,n),this.$search.on("keydown",function(e){i.trigger("keypress",e),i._keyUpPrevented=e.isDefaultPrevented()}),this.$search.on("input",function(e){o(this).off("keyup")}),this.$search.on("keyup input",function(e){i.handleSearch(e)}),t.on("open",function(){i.$search.attr("tabindex",0),i.$search.attr("aria-controls",r),i.$search.trigger("focus"),window.setTimeout(function(){i.$search.trigger("focus")},0)}),t.on("close",function(){i.$search.attr("tabindex",-1),i.$search.removeAttr("aria-controls"),i.$search.removeAttr("aria-activedescendant"),i.$search.val(""),i.$search.trigger("blur")}),t.on("focus",function(){t.isOpen()||i.$search.trigger("focus")}),t.on("results:all",function(e){null!=e.query.term&&""!==e.query.term||(i.showSearch(e)?i.$searchContainer.removeClass("select2-search--hide"):i.$searchContainer.addClass("select2-search--hide"))}),t.on("results:focus",function(e){e.data._resultId?i.$search.attr("aria-activedescendant",e.data._resultId):i.$search.removeAttr("aria-activedescendant")})},t.prototype.handleSearch=function(e){if(!this._keyUpPrevented){var t=this.$search.val();this.trigger("query",{term:t})}this._keyUpPrevented=!1},t.prototype.showSearch=function(e,t){return!0},t}),e.define("select2/dropdown/hidePlaceholder",[],function(){function e(e,t,n,i){this.placeholder=this.normalizePlaceholder(n.get("placeholder")),e.call(this,t,n,i)}return e.prototype.append=function(e,t){t.results=this.removePlaceholder(t.results),e.call(this,t)},e.prototype.normalizePlaceholder=function(e,t){return"string"==typeof t&&(t={id:"",text:t}),t},e.prototype.removePlaceholder=function(e,t){for(var n=t.slice(0),i=t.length-1;0<=i;i--){var r=t[i];this.placeholder.id===r.id&&n.splice(i,1)}return n},e}),e.define("select2/dropdown/infiniteScroll",["jquery"],function(n){function e(e,t,n,i){this.lastParams={},e.call(this,t,n,i),this.$loadingMore=this.createLoadingMore(),this.loading=!1}return e.prototype.append=function(e,t){this.$loadingMore.remove(),this.loading=!1,e.call(this,t),this.showLoadingMore(t)&&(this.$results.append(this.$loadingMore),this.loadMoreIfNeeded())},e.prototype.bind=function(e,t,n){var i=this;e.call(this,t,n),t.on("query",function(e){i.lastParams=e,i.loading=!0}),t.on("query:append",function(e){i.lastParams=e,i.loading=!0}),this.$results.on("scroll",this.loadMoreIfNeeded.bind(this))},e.prototype.loadMoreIfNeeded=function(){var e=n.contains(document.documentElement,this.$loadingMore[0]);if(!this.loading&&e){var t=this.$results.offset().top+this.$results.outerHeight(!1);this.$loadingMore.offset().top+this.$loadingMore.outerHeight(!1)<=t+50&&this.loadMore()}},e.prototype.loadMore=function(){this.loading=!0;var e=n.extend({},{page:1},this.lastParams);e.page++,this.trigger("query:append",e)},e.prototype.showLoadingMore=function(e,t){return t.pagination&&t.pagination.more},e.prototype.createLoadingMore=function(){var e=n('
          • '),t=this.options.get("translations").get("loadingMore");return e.html(t(this.lastParams)),e},e}),e.define("select2/dropdown/attachBody",["jquery","../utils"],function(f,a){function e(e,t,n){this.$dropdownParent=f(n.get("dropdownParent")||document.body),e.call(this,t,n)}return e.prototype.bind=function(e,t,n){var i=this;e.call(this,t,n),t.on("open",function(){i._showDropdown(),i._attachPositioningHandler(t),i._bindContainerResultHandlers(t)}),t.on("close",function(){i._hideDropdown(),i._detachPositioningHandler(t)}),this.$dropdownContainer.on("mousedown",function(e){e.stopPropagation()})},e.prototype.destroy=function(e){e.call(this),this.$dropdownContainer.remove()},e.prototype.position=function(e,t,n){t.attr("class",n.attr("class")),t.removeClass("select2"),t.addClass("select2-container--open"),t.css({position:"absolute",top:-999999}),this.$container=n},e.prototype.render=function(e){var t=f(""),n=e.call(this);return t.append(n),this.$dropdownContainer=t},e.prototype._hideDropdown=function(e){this.$dropdownContainer.detach()},e.prototype._bindContainerResultHandlers=function(e,t){if(!this._containerResultsHandlersBound){var n=this;t.on("results:all",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("results:append",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("results:message",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("select",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("unselect",function(){n._positionDropdown(),n._resizeDropdown()}),this._containerResultsHandlersBound=!0}},e.prototype._attachPositioningHandler=function(e,t){var n=this,i="scroll.select2."+t.id,r="resize.select2."+t.id,o="orientationchange.select2."+t.id,s=this.$container.parents().filter(a.hasScroll);s.each(function(){a.StoreData(this,"select2-scroll-position",{x:f(this).scrollLeft(),y:f(this).scrollTop()})}),s.on(i,function(e){var t=a.GetData(this,"select2-scroll-position");f(this).scrollTop(t.y)}),f(window).on(i+" "+r+" "+o,function(e){n._positionDropdown(),n._resizeDropdown()})},e.prototype._detachPositioningHandler=function(e,t){var n="scroll.select2."+t.id,i="resize.select2."+t.id,r="orientationchange.select2."+t.id;this.$container.parents().filter(a.hasScroll).off(n),f(window).off(n+" "+i+" "+r)},e.prototype._positionDropdown=function(){var e=f(window),t=this.$dropdown.hasClass("select2-dropdown--above"),n=this.$dropdown.hasClass("select2-dropdown--below"),i=null,r=this.$container.offset();r.bottom=r.top+this.$container.outerHeight(!1);var o={height:this.$container.outerHeight(!1)};o.top=r.top,o.bottom=r.top+o.height;var s=this.$dropdown.outerHeight(!1),a=e.scrollTop(),l=e.scrollTop()+e.height(),c=ar.bottom+s,d={left:r.left,top:o.bottom},p=this.$dropdownParent;"static"===p.css("position")&&(p=p.offsetParent());var h={top:0,left:0};(f.contains(document.body,p[0])||p[0].isConnected)&&(h=p.offset()),d.top-=h.top,d.left-=h.left,t||n||(i="below"),u||!c||t?!c&&u&&t&&(i="below"):i="above",("above"==i||t&&"below"!==i)&&(d.top=o.top-h.top-s),null!=i&&(this.$dropdown.removeClass("select2-dropdown--below select2-dropdown--above").addClass("select2-dropdown--"+i),this.$container.removeClass("select2-container--below select2-container--above").addClass("select2-container--"+i)),this.$dropdownContainer.css(d)},e.prototype._resizeDropdown=function(){var e={width:this.$container.outerWidth(!1)+"px"};this.options.get("dropdownAutoWidth")&&(e.minWidth=e.width,e.position="relative",e.width="auto"),this.$dropdown.css(e)},e.prototype._showDropdown=function(e){this.$dropdownContainer.appendTo(this.$dropdownParent),this._positionDropdown(),this._resizeDropdown()},e}),e.define("select2/dropdown/minimumResultsForSearch",[],function(){function e(e,t,n,i){this.minimumResultsForSearch=n.get("minimumResultsForSearch"),this.minimumResultsForSearch<0&&(this.minimumResultsForSearch=1/0),e.call(this,t,n,i)}return e.prototype.showSearch=function(e,t){return!(function e(t){for(var n=0,i=0;i');return e.attr("dir",this.options.get("dir")),this.$container=e,this.$container.addClass("select2-container--"+this.options.get("theme")),u.StoreData(e[0],"element",this.$element),e},d}),e.define("select2/compat/utils",["jquery"],function(s){return{syncCssClasses:function(e,t,n){var i,r,o=[];(i=s.trim(e.attr("class")))&&s((i=""+i).split(/\s+/)).each(function(){0===this.indexOf("select2-")&&o.push(this)}),(i=s.trim(t.attr("class")))&&s((i=""+i).split(/\s+/)).each(function(){0!==this.indexOf("select2-")&&null!=(r=n(this))&&o.push(r)}),e.attr("class",o.join(" "))}}}),e.define("select2/compat/containerCss",["jquery","./utils"],function(s,a){function l(e){return null}function e(){}return e.prototype.render=function(e){var t=e.call(this),n=this.options.get("containerCssClass")||"";s.isFunction(n)&&(n=n(this.$element));var i=this.options.get("adaptContainerCssClass");if(i=i||l,-1!==n.indexOf(":all:")){n=n.replace(":all:","");var r=i;i=function(e){var t=r(e);return null!=t?t+" "+e:e}}var o=this.options.get("containerCss")||{};return s.isFunction(o)&&(o=o(this.$element)),a.syncCssClasses(t,this.$element,i),t.css(o),t.addClass(n),t},e}),e.define("select2/compat/dropdownCss",["jquery","./utils"],function(s,a){function l(e){return null}function e(){}return e.prototype.render=function(e){var t=e.call(this),n=this.options.get("dropdownCssClass")||"";s.isFunction(n)&&(n=n(this.$element));var i=this.options.get("adaptDropdownCssClass");if(i=i||l,-1!==n.indexOf(":all:")){n=n.replace(":all:","");var r=i;i=function(e){var t=r(e);return null!=t?t+" "+e:e}}var o=this.options.get("dropdownCss")||{};return s.isFunction(o)&&(o=o(this.$element)),a.syncCssClasses(t,this.$element,i),t.css(o),t.addClass(n),t},e}),e.define("select2/compat/initSelection",["jquery"],function(i){function e(e,t,n){n.get("debug")&&window.console&&console.warn&&console.warn("Select2: The `initSelection` option has been deprecated in favor of a custom data adapter that overrides the `current` method. This method is now called multiple times instead of a single time when the instance is initialized. Support will be removed for the `initSelection` option in future versions of Select2"),this.initSelection=n.get("initSelection"),this._isInitialized=!1,e.call(this,t,n)}return e.prototype.current=function(e,t){var n=this;this._isInitialized?e.call(this,t):this.initSelection.call(null,this.$element,function(e){n._isInitialized=!0,i.isArray(e)||(e=[e]),t(e)})},e}),e.define("select2/compat/inputData",["jquery","../utils"],function(s,i){function e(e,t,n){this._currentData=[],this._valueSeparator=n.get("valueSeparator")||",","hidden"===t.prop("type")&&n.get("debug")&&console&&console.warn&&console.warn("Select2: Using a hidden input with Select2 is no longer supported and may stop working in the future. It is recommended to use a ` - - -1, - 'orderby' => 'title', - 'post_type' => 'generate_page_header', - 'suppress_filters' => false, - )); - - $options[ $type ] = ! isset( $options[ $type ] ) ? '' : $options[ $type ]; - - foreach( $page_headers as $header ) { - printf( '', - $header->ID, - selected( $options[ $type ], $header->ID ), - $header->post_title - ); - } - ?> - - ( window_height - offset ) ) { - jQuery( '.fullscreen-enabled' ).attr( 'style', 'height: initial !important' ); - } -} - -jQuery(document).ready(function($) { - - // Run the header height function - generateHeaderHeight(); - - // Set up the resize timer - var generateResizeTimer; - - if ( jQuery('.generate-page-header.fullscreen-enabled')[0] ) { - // Initiate full window height on resize - var width = $(window).width(); - $(window).resize(function() { - if($(window).width() != width){ - clearTimeout(generateResizeTimer); - generateResizeTimer = setTimeout(generateHeaderHeight, 200); - width = $(window).width(); - } - }); - - $( window ).on( "orientationchange", function( event ) { - if($(window).width() != width){ - clearTimeout(generateResizeTimer); - generateResizeTimer = setTimeout(generateHeaderHeight, 200); - width = $(window).width(); - } - }); - } - -}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/full-height.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/full-height.min.js deleted file mode 100644 index dd988e11..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/full-height.min.js +++ /dev/null @@ -1 +0,0 @@ -function generateHeaderHeight(){if(jQuery(".fullscreen-enabled").length){var a,b=jQuery(window).height();a=jQuery(".inside-page-header").length?jQuery(".inside-page-header"):jQuery(".generate-inside-combined-content").length?jQuery(".generate-inside-combined-content"):jQuery(".generate-inside-page-header-content");var c=jQuery(".fullscreen-enabled").offset().top;jQuery(".fullscreen-enabled").css("height",b-c+"px"),a.outerHeight()>b-c&&jQuery(".fullscreen-enabled").attr("style","height: initial !important")}}function generateHeaderParallax(){var a=jQuery(".menu-toggle");if(!a.is(":visible")&&jQuery(".generate-page-header.parallax-enabled")[0]){if(jQuery(".page-header-contained")[0])var b=jQuery(".generate-page-header.parallax-enabled .inside-content-header");else var b=jQuery(".generate-page-header.parallax-enabled");var c=jQuery(this).scrollTop(),d=jQuery(".generate-page-header.parallax-enabled").data("parallax-speed");return b.css("background-position","center "+parseInt(-c/d)+"px")}}jQuery(document).ready(function(a){generateHeaderHeight();var b;if(jQuery(".generate-page-header.parallax-enabled")[0]&&a(document).scroll(function(){generateHeaderParallax()}),jQuery(".generate-page-header.fullscreen-enabled")[0]){var c=a(window).width();a(window).resize(function(){a(window).width()!=c&&(clearTimeout(b),b=setTimeout(generateHeaderHeight,200),c=a(window).width())}),a(window).on("orientationchange",function(d){a(window).width()!=c&&(clearTimeout(b),b=setTimeout(generateHeaderHeight,200),c=a(window).width())})}}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/jquery.vide.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/jquery.vide.min.js deleted file mode 100644 index d78004e0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/jquery.vide.min.js +++ /dev/null @@ -1,9 +0,0 @@ -/* - * Vide - v0.5.0 - * Easy as hell jQuery plugin for video backgrounds. - * http://vodkabears.github.io/vide/ - * - * Made by Ilya Makarov - * Under MIT License - */ -!function(a,b){"function"==typeof define&&define.amd?define(["jquery"],b):b("object"==typeof exports?require("jquery"):a.jQuery)}(this,function(a){"use strict";function b(a){var b,c,d,e,f,g,h,i={};for(f=a.replace(/\s*:\s*/g,":").replace(/\s*,\s*/g,",").split(","),h=0,g=f.length;g>h&&(c=f[h],-1===c.search(/^(http|https|ftp):\/\//)&&-1!==c.search(":"));h++)b=c.indexOf(":"),d=c.substring(0,b),e=c.substring(b+1),e||(e=void 0),"string"==typeof e&&(e="true"===e||("false"===e?!1:e)),"string"==typeof e&&(e=isNaN(e)?e:+e),i[d]=e;return null==d&&null==e?a:i}function c(a){a=""+a;var b,c,d,e=a.split(/\s+/),f="50%",g="50%";for(d=0,b=e.length;b>d;d++)c=e[d],"left"===c?f="0%":"right"===c?f="100%":"top"===c?g="0%":"bottom"===c?g="100%":"center"===c?0===d?f="50%":g="50%":0===d?f=c:g=c;return{x:f,y:g}}function d(b,c){var d=function(){c(this.src)};a('').load(d),a('').load(d),a('').load(d),a('').load(d)}function e(c,d,e){if(this.$element=a(c),"string"==typeof d&&(d=b(d)),e?"string"==typeof e&&(e=b(e)):e={},"string"==typeof d)d=d.replace(/\.\w*$/,"");else if("object"==typeof d)for(var f in d)d.hasOwnProperty(f)&&(d[f]=d[f].replace(/\.\w*$/,""));this.settings=a.extend({},g,e),this.path=d;try{this.init()}catch(i){if(i.message!==h)throw i}}var f="vide",g={volume:1,playbackRate:1,muted:!0,loop:!0,autoplay:!0,position:"50% 50%",posterType:"detect",resizing:!0,bgColor:"transparent",className:""},h="Not implemented";e.prototype.init=function(){var b,e,g=this,i=g.path,j=i,k="",l=g.$element,m=g.settings,n=c(m.position),o=m.posterType;e=g.$wrapper=a("
            ").addClass(m.className).css({position:"absolute","z-index":-1,top:0,left:0,bottom:0,right:0,overflow:"hidden","-webkit-background-size":"cover","-moz-background-size":"cover","-o-background-size":"cover","background-size":"cover","background-color":m.bgColor,"background-repeat":"no-repeat","background-position":n.x+" "+n.y}),"object"==typeof i&&(i.poster?j=i.poster:i.mp4?j=i.mp4:i.webm?j=i.webm:i.ogv&&(j=i.ogv)),"detect"===o?d(j,function(a){e.css("background-image","url("+a+")")}):"none"!==o&&e.css("background-image","url("+j+"."+o+")"),"static"===l.css("position")&&l.css("position","relative"),l.prepend(e),"object"==typeof i?(i.mp4&&(k+=''),i.webm&&(k+=''),i.ogv&&(k+=''),b=g.$video=a("")):b=g.$video=a('');try{b.prop({autoplay:m.autoplay,loop:m.loop,volume:m.volume,muted:m.muted,defaultMuted:m.muted,playbackRate:m.playbackRate,defaultPlaybackRate:m.playbackRate})}catch(p){throw new Error(h)}b.css({margin:"auto",position:"absolute","z-index":-1,top:n.y,left:n.x,"-webkit-transform":"translate(-"+n.x+", -"+n.y+")","-ms-transform":"translate(-"+n.x+", -"+n.y+")","-moz-transform":"translate(-"+n.x+", -"+n.y+")",transform:"translate(-"+n.x+", -"+n.y+")",visibility:"hidden",opacity:0}).one("canplaythrough."+f,function(){g.resize()}).one("playing."+f,function(){b.css({visibility:"visible",opacity:1}),e.css("background-image","none")}),l.on("resize."+f,function(){m.resizing&&g.resize()}),e.append(b)},e.prototype.getVideoObject=function(){return this.$video[0]},e.prototype.resize=function(){if(this.$video){var a=this.$wrapper,b=this.$video,c=b[0],d=c.videoHeight,e=c.videoWidth,f=a.height(),g=a.width();g/e>f/d?b.css({width:g+2,height:"auto"}):b.css({width:"auto",height:f+2})}},e.prototype.destroy=function(){delete a[f].lookup[this.index],this.$video&&this.$video.off(f),this.$element.off(f).removeData(f),this.$wrapper.remove()},a[f]={lookup:[]},a.fn[f]=function(b,c){var d;return this.each(function(){d=a.data(this,f),d&&d.destroy(),d=new e(this,b,c),d.index=a[f].lookup.push(d)-1,a.data(this,f,d)}),this},a(document).ready(function(){var b=a(window);b.on("resize."+f,function(){for(var b,c=a[f].lookup.length,d=0;c>d;d++)b=a[f].lookup[d],b&&b.settings.resizing&&b.resize()}),b.on("unload."+f,function(){return!1}),a(document).find("[data-"+f+"-bg]").each(function(b,c){var d=a(c),e=d.data(f+"-options"),g=d.data(f+"-bg");d[f](g,e)})})});jQuery(document).ready(function($) {var page_header_content = $( '.page-header-content' );if ( page_header_content.length ) {if ( page_header_content.hasClass( 'grid-container' ) ) {$( '.inside-page-header-container' ).data('vide').getVideoObject().play();} else {page_header_content.data('vide').getVideoObject().play();}}}); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/lc_switch.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/lc_switch.js deleted file mode 100644 index 89eae365..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/lc_switch.js +++ /dev/null @@ -1,149 +0,0 @@ -/** - * lc_switch.js - * Version: 1.0 - * Author: LCweb - Luca Montanari - * Website: http://www.lcweb.it - * Licensed under the MIT license - */ - -(function($){ - if(typeof($.fn.lc_switch) != 'undefined') {return false;} // prevent dmultiple scripts inits - - $.fn.lc_switch = function(on_text, off_text) { - - // destruct - $.fn.lcs_destroy = function() { - - $(this).each(function() { - var $wrap = $(this).parents('.lcs_wrap'); - - $wrap.children().not('input').remove(); - $(this).unwrap(); - }); - - return true; - }; - - - // set to ON - $.fn.lcs_on = function() { - - $(this).each(function() { - var $wrap = $(this).parents('.lcs_wrap'); - var $input = $wrap.find('input'); - - if(typeof($.fn.prop) == 'function') { - $wrap.find('input').prop('checked', true); - } else { - $wrap.find('input').attr('checked', true); - } - - $wrap.find('input').trigger('lcs-on'); - $wrap.find('input').trigger('lcs-statuschange'); - $wrap.find('.lcs_switch').removeClass('lcs_off').addClass('lcs_on'); - - // if radio - disable other ones - if( $wrap.find('.lcs_switch').hasClass('lcs_radio_switch') ) { - var f_name = $input.attr('name'); - $wrap.parents('form').find('input[name='+f_name+']').not($input).lcs_off(); - } - }); - - return true; - }; - - - // set to OFF - $.fn.lcs_off = function() { - - $(this).each(function() { - var $wrap = $(this).parents('.lcs_wrap'); - - if(typeof($.fn.prop) == 'function') { - $wrap.find('input').prop('checked', false); - } else { - $wrap.find('input').attr('checked', false); - } - - $wrap.find('input').trigger('lcs-off'); - $wrap.find('input').trigger('lcs-statuschange'); - $wrap.find('.lcs_switch').removeClass('lcs_on').addClass('lcs_off'); - }); - - return true; - }; - - - // construct - return this.each(function(){ - - // check against double init - if( !$(this).parent().hasClass('lcs_wrap') ) { - - // default texts - var ckd_on_txt = (typeof(on_text) == 'undefined') ? 'ON' : on_text; - var ckd_off_txt = (typeof(off_text) == 'undefined') ? 'OFF' : off_text; - - // labels structure - var on_label = (ckd_on_txt) ? '
            '+ ckd_on_txt +'
            ' : ''; - var off_label = (ckd_off_txt) ? '
            '+ ckd_off_txt +'
            ' : ''; - - - // default states - var disabled = ($(this).is(':disabled')) ? true: false; - var active = ($(this).is(':checked')) ? true : false; - - var status_classes = ''; - status_classes += (active) ? ' lcs_on' : ' lcs_off'; - if(disabled) {status_classes += ' lcs_disabled';} - - - // wrap and append - var structure = - '
            ' + - '
            ' + - on_label + off_label + - '
            '; - - if( $(this).is(':input') && ($(this).attr('type') == 'checkbox' || $(this).attr('type') == 'radio') ) { - - $(this).wrap('
            '); - $(this).parent().append(structure); - - $(this).parent().find('.lcs_switch').addClass('lcs_'+ $(this).attr('type') +'_switch'); - } - } - }); - }; - - - - // handlers - $(document).ready(function() { - - // on click - $(document).delegate('.lcs_switch:not(.lcs_disabled)', 'click tap', function(e) { - - if( $(this).hasClass('lcs_on') ) { - if( !$(this).hasClass('lcs_radio_switch') ) { // not for radio - $(this).lcs_off(); - } - } else { - $(this).lcs_on(); - } - }); - - - // on checkbox status change - $(document).delegate('.lcs_wrap input', 'change', function() { - - if( $(this).is(':checked') ) { - $(this).lcs_on(); - } else { - $(this).lcs_off(); - } - }); - - }); - -})(jQuery); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/metabox.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/metabox.js deleted file mode 100644 index f1c0f66e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/metabox.js +++ /dev/null @@ -1,220 +0,0 @@ -jQuery(document).ready(function($) { - $( '#generate-tabs-container input[type="checkbox"]' ).lc_switch( '', '' ); - - $( '.generate-tabs-menu a' ).on( 'click', function( event ) { - event.preventDefault(); - $( this ).parent().addClass( 'generate-current' ); - $( this ).parent().siblings().removeClass( 'generate-current' ); - var tab = $( this ).attr( 'href' ); - $( '.generate-tab-content' ).not(tab).css( 'display', 'none' ); - $( tab ).fadeIn( 100 ); - - if ( '#generate-image-tab' == tab || '#generate-content-tab' == tab ) { - $( '.show-in-excerpt' ).show(); - } else { - $( '.show-in-excerpt' ).hide(); - } - } ); - - $( '#_meta-generate-page-header-content' ).on( 'input change', function() { - if ( this.value.length ) { - $( '.page-header-content-required' ).hide(); - } else { - $( '.page-header-content-required' ).show(); - } - }); -}); - -jQuery(window).on('load', function() { - if ( jQuery( '#_meta-generate-page-header-enable-image-crop' ).val() == 'enable' ) { - jQuery( '#crop-enabled' ).show(); - } - - jQuery( '#_meta-generate-page-header-enable-image-crop' ).change(function () { - if ( jQuery( this ).val() === 'enable' ) { - jQuery( '#crop-enabled' ).show(); - } else { - jQuery( '#crop-enabled' ).hide(); - } - }); - - if ( jQuery( '#_meta-generate-page-header-image-background' ).is( ':checked' ) ) { - jQuery( '.parallax' ).show(); - } else { - jQuery( '.parallax' ).hide(); - } - - jQuery('body').delegate('.image-background', 'lcs-statuschange', function() { - if (jQuery(this).is(":checked")) { - jQuery('.parallax').show(); - } else { - jQuery('.parallax').hide(); - jQuery('#_meta-generate-page-header-image-background-fixed').lcs_off(); - } - }); - - if ( jQuery('#_meta-generate-page-header-full-screen').is(':checked')) { - jQuery('.vertical-center').show(); - } else { - jQuery('.vertical-center').hide(); - } - - jQuery('body').delegate('#_meta-generate-page-header-full-screen', 'lcs-statuschange', function() { - if (jQuery(this).is(":checked")) { - jQuery('.vertical-center').show(); - } else { - jQuery('.vertical-center').hide(); - jQuery('#_meta-generate-page-header-vertical-center').lcs_off(); - } - }); - - if ( jQuery('#_meta-generate-page-header-transparent-navigation').is(':checked')) { - jQuery('.navigation-colors').show(); - } else { - jQuery('.navigation-colors').hide(); - } - - jQuery('body').delegate('#_meta-generate-page-header-transparent-navigation', 'lcs-statuschange', function() { - if (jQuery(this).is(":checked")) { - jQuery('.navigation-colors').show(); - } else { - jQuery('.navigation-colors').hide(); - } - }); - - if ( jQuery('#_meta-generate-page-header-combine').is(':checked')) { - jQuery('.combination-options').show(); - } else { - jQuery('.combination-options').hide(); - } - - jQuery('body').delegate('#_meta-generate-page-header-combine', 'lcs-statuschange', function() { - if (jQuery(this).is(":checked")) { - jQuery('.combination-options').show(); - } else { - jQuery('.combination-options').hide(); - } - }); - - if ( jQuery('#_meta-generate-page-header-image-background-type').val() == '' ) { - jQuery('.vertical-center').hide(); - jQuery('.fullscreen').hide(); - } - jQuery('#_meta-generate-page-header-image-background-type').change(function () { - if (jQuery(this).val() === '') { - jQuery('.vertical-center').hide(); - jQuery('#_meta-generate-page-header-vertical-center').lcs_off(); - jQuery('.fullscreen').hide(); - jQuery('#_meta-generate-page-header-full-screen').lcs_off(); - } else { - //jQuery('.vertical-center').show(); - jQuery('.fullscreen').show(); - } - }); - - var $set_button = jQuery('.generate-upload-file'); - /** - * open the media manager - */ - $set_button.click(function (e) { - e.preventDefault(); - - var $thisbutton = jQuery(this); - var frame = wp.media({ - title : $thisbutton.data('title'), - multiple : false, - library : { type : $thisbutton.data('type') }, - button : { text : $thisbutton.data('insert') } - }); - // close event media manager - frame.on('select', function () { - var attachment = frame.state().get('selection').first().toJSON(); - // set the file - //set_dfi(attachment.url); - $thisbutton.prev('input').val(attachment.url); - $thisbutton.nextAll('input.image-id').val(attachment.id); - if ( $thisbutton.data('prev') === true ) { - $thisbutton.prev('input').prevAll('#preview-image').children('.saved-image').remove(); - $thisbutton.prev('input').prevAll('#preview-image').append(''); - } - $thisbutton.nextAll( '.generate-page-header-remove-image' ).show(); - if ( 'upload_image' == $thisbutton.prev( 'input' ).attr( 'id' ) ) { - jQuery( '.featured-image-message' ).hide(); - jQuery( '.page-header-image-settings' ).show(); - jQuery( '.generate-page-header-set-featured-image' ).hide(); - } - }); - - // everthing is set open the media manager - frame.open(); - }); -}); -jQuery(document).ready(function($) { - $('#generate-tabs-container .color-picker').wpColorPicker(); - - jQuery( '.generate-page-header-remove-image' ).on( 'click', function( e ) { - e.preventDefault(); - var input = jQuery( this ).data( 'input' ); - var input_id = jQuery( this ).data( 'input-id' ); - var preview = jQuery( this ).data( 'prev' ); - jQuery( input ).attr( 'value', '' ); - jQuery( input_id ).attr( 'value', '' ); - jQuery( preview ).children( '.saved-image' ).remove(); - jQuery( this ).hide(); - if ( '-1' == jQuery( '#_thumbnail_id' ).attr( 'value' ) ) { - jQuery( '.page-header-image-settings' ).hide(); - jQuery( '.generate-page-header-set-featured-image' ).show(); - - } else { - jQuery( '.generate-page-header-set-featured-image' ).hide(); - jQuery( '.page-header-image-settings' ).show(); - jQuery( '.featured-image-message' ).show(); - } - return false; - }); - - $('#postimagediv').on( 'click', '#remove-post-thumbnail', function() { - // The featured image is gone, so we can hide the message - jQuery( '.featured-image-message' ).hide(); - - // If there's no other image set, we can hide the image settings - if ( '' == jQuery( '#_meta-generate-page-header-image-id' ).attr( 'value' ) ) { - jQuery( '.page-header-image-settings' ).hide(); - jQuery( '.generate-page-header-set-featured-image' ).show(); - } - - // No more featured image means we can show the 'show excerpt' option - jQuery( '.show-in-excerpt' ).show(); - - return false; - }); - - wp.media.featuredImage.frame().on('select', function() { - - // We have a featured image, so the 'show excerpt' function isn't necessary - jQuery( '.show-in-excerpt' ).hide(); - - // We can stop here if we have a custom image set - if ( '' !== jQuery( '#_meta-generate-page-header-image-id' ).attr( 'value' ) ) - return; - - // Hide the set your featured image message - jQuery( '.generate-page-header-set-featured-image' ).hide(); - - // Show the "using feaured image" message - jQuery( '.featured-image-message' ).show(); - - // Show the image settings (image link, resizing etc..) - jQuery( '.page-header-image-settings' ).show(); - }); - - $( '.generate-featured-image, .generate-page-header-set-featured-image a' ).on( 'click', function( event ) { - event.preventDefault(); - - // Stop propagation to prevent thickbox from activating. - event.stopPropagation(); - - // Open the featured image modal - wp.media.featuredImage.frame().open(); - }); -}); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/parallax.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/parallax.js deleted file mode 100644 index 8fe3b26c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/parallax.js +++ /dev/null @@ -1,17 +0,0 @@ -function generate_parallax_element( selector, context ) { - context = context || document; - var elements = context.querySelectorAll( selector ); - return Array.prototype.slice.call( elements ); -} - -window.addEventListener( "scroll", function() { - var scrolledHeight= window.pageYOffset; - generate_parallax_element( ".parallax-enabled" ).forEach( function( el, index, array ) { - var limit = el.offsetTop + el.offsetHeight; - if( scrolledHeight > el.offsetTop && scrolledHeight <= limit ) { - el.style.backgroundPositionY = ( scrolledHeight - el.offsetTop ) / el.getAttribute( 'data-parallax-speed' ) + "px"; - } else { - el.style.backgroundPositionY = "0"; - } - }); -}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/parallax.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/parallax.min.js deleted file mode 100644 index 8263a901..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/js/parallax.min.js +++ /dev/null @@ -1 +0,0 @@ -function generate_parallax_element(e,t){var a=(t=t||document).querySelectorAll(e);return Array.prototype.slice.call(a)}window.addEventListener("scroll",function(){var e=window.pageYOffset;generate_parallax_element(".parallax-enabled").forEach(function(t,a,o){var r=t.offsetTop+t.offsetHeight;e>t.offsetTop&&e<=r?t.style.backgroundPositionY=(e-t.offsetTop)/t.getAttribute("data-parallax-speed")+"px":t.style.backgroundPositionY="0"})}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/metabox.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/metabox.php deleted file mode 100644 index 76b25c4a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/metabox.php +++ /dev/null @@ -1,782 +0,0 @@ - true ); - $post_types = get_post_types( $args ); - - // Bail if we're not using the old Page Header meta box - if ( 'generate_page_header' !== get_post_type() && '' == $stored_meta['_meta-generate-page-header-content'][0] && '' == $stored_meta['_meta-generate-page-header-image'][0] && '' == $stored_meta['_meta-generate-page-header-image-id'][0] ) { - if ( ! defined( 'GENERATE_LAYOUT_META_BOX' ) ) { - foreach ( $post_types as $type ) { - if ( 'attachment' !== $type ) { - add_meta_box( - 'generate_select_page_header_meta_box', - __( 'Page Header', 'gp-premium' ), - 'generate_do_select_page_header_meta_box', - $type, - 'normal', - 'high' - ); - } - } - } - - if ( ! apply_filters( 'generate_page_header_legacy_metabox', false ) ) { - return; - } - } - - array_push( $post_types, 'generate_page_header' ); - foreach ($post_types as $type) { - if ( 'attachment' !== $type ) { - add_meta_box( - 'generate_page_header_meta_box', - __( 'Page Header', 'gp-premium' ), - 'show_generate_page_header_meta_box', - $type, - 'normal', - 'high' - ); - } - } - } -} - -if ( ! function_exists( 'generate_page_header_metabox_enqueue' ) ) { - add_action( 'admin_enqueue_scripts', 'generate_page_header_metabox_enqueue' ); - /** - * Add our metabox scripts - */ - function generate_page_header_metabox_enqueue( $hook ) { - // I prefer to enqueue the styles only on pages that are using the metaboxes - if ( in_array( $hook, array( "post.php", "post-new.php" ) ) ) { - $args = array( 'public' => true ); - $post_types = get_post_types( $args ); - - $screen = get_current_screen(); - $post_type = $screen->id; - - if ( in_array( $post_type, (array) $post_types ) || 'generate_page_header' == get_post_type() ){ - wp_enqueue_media(); - wp_enqueue_script( 'wp-color-picker' ); - wp_enqueue_style( 'wp-color-picker' ); - wp_enqueue_script( 'wp-color-picker-alpha', GP_LIBRARY_DIRECTORY_URL . 'alpha-color-picker/wp-color-picker-alpha.min.js', array( 'wp-color-picker' ), '3.0.0', true ); - - wp_add_inline_script( - 'wp-color-picker-alpha', - 'jQuery( function() { jQuery( ".color-picker" ).wpColorPicker(); } );' - ); - - wp_enqueue_style( 'generate-page-header-metabox', plugin_dir_url( __FILE__ ) . 'css/metabox.css', array(), GENERATE_PAGE_HEADER_VERSION ); - wp_enqueue_script( 'generate-lc-switch', plugin_dir_url( __FILE__ ) . 'js/lc_switch.js', array( 'jquery' ), GENERATE_PAGE_HEADER_VERSION, false ); - wp_enqueue_script( 'generate-page-header-metabox', plugin_dir_url( __FILE__ ) . 'js/metabox.js', array( 'jquery','generate-lc-switch', 'wp-color-picker' ), GENERATE_PAGE_HEADER_VERSION, false ); - - if ( function_exists( 'wp_add_inline_script' ) && function_exists( 'generate_get_default_color_palettes' ) ) { - // Grab our palette array and turn it into JS - $palettes = json_encode( generate_get_default_color_palettes() ); - - // Add our custom palettes - // json_encode takes care of escaping - wp_add_inline_script( 'wp-color-picker', 'jQuery.wp.wpColorPicker.prototype.options.palettes = ' . $palettes . ';' ); - } - } - } - } -} - -/** - * Build our Select Page Header meta box. - * - * @since 1.4 - */ -function generate_do_select_page_header_meta_box( $post ) { - wp_nonce_field( basename( __FILE__ ), 'generate_page_header_nonce' ); - $stored_meta = get_post_meta( $post->ID ); - $stored_meta['_generate-select-page-header'][0] = ( isset( $stored_meta['_generate-select-page-header'][0] ) ) ? $stored_meta['_generate-select-page-header'][0] : ''; - - $page_headers = get_posts(array( - 'posts_per_page' => -1, - 'orderby' => 'title', - 'post_type' => 'generate_page_header', - )); - - if ( count( $page_headers ) > 0 ) : - ?> -

            - -

            - -

            - create one?', 'gp-premium' ), - esc_url( admin_url( 'post-new.php?post_type=generate_page_header' ) ) - ); - ?> -

            -

            %1$s

            ', - __( 'Content is required for the below settings to work.', 'gp-premium' ), - '' !== generate_page_header_get_post_meta( get_the_ID(), '_meta-generate-page-header-content', true ) ? 'style="display:none"' : '' - ); - - if ( '' !== generate_page_header_get_post_meta( get_the_ID(), '_meta-generate-page-header-content', true ) ) { - ?> - - -
            -
              -
            • - -
            • - -
            • - -
            • - -
            • - -
            • - - -
            • - -
            • - - -
            • - -
            • - - -
              > -

              -
              - /> -

              -
              - -
            -
            -
            - - - -
            - - - -
            - - - - - - - - -
            > -

            -
            - -

            - -

            -
            - -

            - - -
            -
            - -
            - - -

            - -
            - -
            -

            - /> - -

            - -

            - /> - -

            - -

            - /> - -

            - -

            - /> - -

            - -

            - /> - -

            - -

            - /> - -

            - -

            - /> - -

            -
            - -
            -

            -
            - -

            - -

            -
            - -

            - -

            -
            - -

            - -

            -
            - - -

            - -

            -
            - - -

            -
            - -
            -

            -
            - -

            - -

            -
            - -

            - -

            -
            - -

            - -

            -
            - -

            -
            -
            -
            -
            - - - - -
            - -

            - -

            - -
            - - - -
            - - - - - - - - -

            - -

            - -

            - -
            - - - -
            - - - - - - - - - -
            - - - -
            -
            - 'FILTER_CONTENT', - '_meta-generate-page-header-image' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-image-id' => 'FILTER_SANITIZE_NUMBER_INT', - '_meta-generate-page-header-image-link' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-enable-image-crop' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-crop' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-width' => 'FILTER_SANITIZE_NUMBER_INT', - '_meta-generate-page-header-image-height' => 'FILTER_SANITIZE_NUMBER_INT', - '_meta-generate-page-header-image-background-type' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-inner-container' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-alignment' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-spacing' => 'FILTER_SANITIZE_NUMBER_INT', - '_meta-generate-page-header-image-background-spacing-unit' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-left-right-padding' => 'FILTER_SANITIZE_NUMBER_INT', - '_meta-generate-page-header-left-right-padding-unit' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-color' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-text-color' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-link-color' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-link-color-hover' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-navigation-background' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-navigation-text' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-navigation-background-hover' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-navigation-text-hover' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-navigation-background-current' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-navigation-text-current' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-site-title' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-site-tagline' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-video' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-video-ogv' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-video-webm' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-video-overlay' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-content-autop' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-content-padding' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-full-screen' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-vertical-center' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-fixed' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-image-background-overlay' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-combine' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-absolute-position' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-transparent-navigation' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-add-to-excerpt' => 'FILTER_SANITIZE_STRING', - '_meta-generate-page-header-logo' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-logo-id' => 'FILTER_SANITIZE_NUMBER_INT', - '_meta-generate-page-header-navigation-logo' => 'FILTER_SANITIZE_URL', - '_meta-generate-page-header-navigation-logo-id' => 'FILTER_SANITIZE_NUMBER_INT', - ); - - if ( ! defined( 'GENERATE_LAYOUT_META_BOX' ) ) { - $options[ '_generate-select-page-header' ] = 'FILTER_SANITIZE_NUMBER_INT'; - } - - foreach ( $options as $key => $sanitize ) { - if ( 'FILTER_SANITIZE_STRING' == $sanitize ) { - $value = filter_input( INPUT_POST, $key, FILTER_SANITIZE_STRING ); - } elseif ( 'FILTER_SANITIZE_URL' == $sanitize ) { - $value = filter_input( INPUT_POST, $key, FILTER_SANITIZE_URL ); - } elseif ( 'FILTER_SANITIZE_NUMBER_INT' == $sanitize ) { - $value = filter_input( INPUT_POST, $key, FILTER_SANITIZE_NUMBER_INT ); - } elseif ( 'FILTER_CONTENT' == $sanitize && isset( $_POST[ $key ] ) ) { - if ( current_user_can( 'unfiltered_html' ) ) { - $value = $_POST[ $key ]; - } else { - $value = wp_kses_post( $_POST[ $key ] ); - } - } else { - $value = filter_input( INPUT_POST, $key, FILTER_DEFAULT ); - } - - if ( $value ) { - update_post_meta( $post_id, $key, $value ); - } else { - delete_post_meta( $post_id, $key ); - } - } - } -} - -add_action( 'add_meta_boxes', 'generate_page_header_tags_add_meta_box' ); -/** - * Add our Template Tags meta box. - * - * @param WP_Post $post Current post object. - * - * @since 1.4 - */ -function generate_page_header_tags_add_meta_box( $post ) { - add_meta_box( 'generate_page_header_tags', __( 'Template Tags', 'gp-premium' ), 'generate_page_header_tags_do_meta_box', 'generate_page_header', 'side', 'low' ); -} - -/** - * Meta box display callback. - * - * @param WP_Post $post Current post object. - * - * @since 1.4 - */ -function generate_page_header_tags_do_meta_box( $post ) { - ?> - -

            - - -

            - - -

            - - -

            - - -

            - - - -
          • - ( ! empty( $options[ 'background_video' ] ) ) ? 'mp4:' . esc_url( $options[ 'background_video' ] ) : null, - 'ogv' => ( ! empty( $options[ 'background_video_ogv' ] ) ) ? 'ogv:' . esc_url( $options[ 'background_video_ogv' ] ) : null, - 'webm' => ( ! empty( $options[ 'background_video_webm' ] ) ) ? 'webm:' . esc_url( $options[ 'background_video_webm' ] ) : null, - 'poster' => ( ! empty( $image_url ) ) ? 'poster:' . esc_url( $image_url ) : null - ); - - // Add our videos to a string - $video_output = array(); - foreach( $video_types as $video => $val ) { - $video_output[] = $val; - } - - $video = null; - // Video variable - if ( $video_enabled && '' !== $options[ 'content' ] ) { - - $ext = ( ! empty( $image_url ) ) ? pathinfo( $image_url, PATHINFO_EXTENSION ) : false; - $video_options = array(); - - if ( $ext ) { - $video_options[ 'posterType' ] = 'posterType:' . $ext; - } else { - $video_options[ 'posterType' ] = 'posterType: none'; - } - - $video_options[ 'className' ] = 'className:generate-page-header-video'; - - if ( apply_filters( 'generate_page_header_video_loop', true ) ) { - $video_options[ 'loop' ] = 'loop:true'; - } else { - $video_options[ 'loop' ] = 'loop:false'; - } - - if ( apply_filters( 'generate_page_header_video_muted', true ) ) { - $video_options[ 'muted' ] = 'muted:true'; - } else { - $video_options[ 'muted' ] = 'muted:false'; - } - - $video_options[ 'autoplay' ] = 'autoplay:false'; - - $video = sprintf( ' data-vide-bg="%1$s" data-vide-options="%2$s"', - implode( ', ', array_filter( $video_output ) ), - implode( ', ', array_filter( $video_options ) ) - ); - } - - // Write a class if we're merging the header - $combined_content = ( '' !== $options[ 'merge' ] ) ? ' generate-combined-page-header' : ''; - - // If content is set, show it - if ( '' !== $options[ 'content' ] && false !== $options[ 'content' ] ) { - printf( - '
            -
            ', - ( 'fluid' == $options[ 'container_type' ] ) ? $video : null, - $content_class . $parallax . $full_screen . $vertical_center_container . $container_type . $combined_content . ' generate-page-header generate-content-header', - ( 'fluid' !== $options[ 'container_type' ] ) ? $video : null, - $vertical_center, - ( '' !== $options[ 'merge' ] ) ? 'generate-merged-header' : '', - ( ! empty( $parallax ) ) ? 'data-parallax-speed="' . esc_attr( $parallax_speed ) . '"' : '', - $options[ 'page_header_id' ] - ); - } - - do_action( 'generate_inside_merged_page_header' ); - } -} - -if ( ! function_exists( 'generate_page_header_area' ) ) { - /** - * Build our entire page header. - * - * @since 0.1 - * - * @param $image_class The class to give our element if it's an image. - * @param $content_class The class to give our element if it's content. - */ - function generate_page_header_area( $image_class, $content_class ) { - // Get our options - $options = generate_page_header_get_options(); - - // Get out of here if we don't have content or an image - if ( '' == $options[ 'content' ] && ! generate_page_header_get_image( 'ALL' ) ) { - return; - } - - $inner_container = ( '' == $options[ 'inner_container' ] ) ? ' grid-container grid-parent' : ''; - - do_action( 'generate_before_page_header' ); - - // If an image is set and no content is set - if ( '' == $options[ 'content' ] && generate_page_header_get_image( 'ALL' ) ) { - - printf( - '
            - %2$s - %4$s - %3$s -
            ', - esc_attr( $image_class ) . $inner_container . ' generate-page-header', - ( ! empty( $options[ 'image_link' ] ) ) ? '' : null, - ( ! empty( $options[ 'image_link' ] ) ) ? '' : null, - generate_page_header_get_image_output() - ); - - } - - // If content is set, show it - if ( '' !== $options[ 'content' ] && false !== $options[ 'content' ] ) { - // If we're not merging our header, we can start the container here - // If we were merging, the container would be added in the generate_before_header hook - if ( '' == $options[ 'merge' ] ) { - generate_page_header_area_start_container( 'page-header-image', 'page-header-content' ); - } - - // Replace any found template tags - $options[ 'content' ] = generate_page_header_template_tags( $options[ 'content' ] ); - - // Print the rest of our page header HTML - // The starting elements are inside generate_page_header_area_start_container() - printf ( '
            -
            - %4$s - %6$s - %5$s -
            -
            -
            -
            ', - ( '' !== $options[ 'merge' ] ) ? 'generate-combined-content' : '', - $inner_container, - ( '' !== $options[ 'merge' ] ) ? 'generate-inside-combined-content' : 'generate-inside-page-header-content', - ( ! empty( $options[ 'add_padding' ] ) ) ? '
            ' : null, - ( ! empty( $options[ 'add_padding' ] ) ) ? '
            ' : null, - ( ! empty( $options[ 'autop' ] ) ) ? do_shortcode( wpautop( $options[ 'content' ] ) ) : do_shortcode( $options[ 'content' ] ) - ); - } - - do_action( 'generate_after_page_header' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/post-image.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/post-image.php deleted file mode 100644 index b88250ad..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/post-image.php +++ /dev/null @@ -1,60 +0,0 @@ - - %2$s - %4$s - %3$s - ', - 'post-image page-header-post-image', - ( ! empty( $options[ 'image_link' ] ) ) ? '' : null, - ( ! empty( $options[ 'image_link' ] ) ) ? '' : null, - generate_page_header_get_image_output() - ); - } - - // If content is set, show it - if ( '' !== $options[ 'content' ] && false !== $options[ 'content' ] ) { - printf( - '
            -
            - %3$s - %5$s - %4$s -
            -
            ', - 'post-image generate-page-header generate-post-content-header page-header-post-image', - 'inside-page-header-container inside-post-content-header grid-container grid-parent', - ( ! empty( $options[ 'add_padding' ] ) ) ? '
            ' : null, - ( ! empty( $options[ 'add_padding' ] ) ) ? '
            ' : null, - ( ! empty( $options[ 'autop' ] ) ) ? do_shortcode( wpautop( $options[ 'content' ] ) ) : do_shortcode( $options[ 'content' ] ) - ); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/post-type.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/post-type.php deleted file mode 100644 index 9768b43c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/page-header/functions/post-type.php +++ /dev/null @@ -1,236 +0,0 @@ - _x( 'Page Headers', 'Post Type General Name', 'gp-premium' ), - 'singular_name' => _x( 'Page Header', 'Post Type Singular Name', 'gp-premium' ), - 'menu_name' => __( 'Page Headers', 'gp-premium' ), - 'name_admin_bar' => __( 'Page Header', 'gp-premium' ), - 'archives' => __( 'Page Header Archives', 'gp-premium' ), - 'parent_item_colon' => __( 'Parent Page Header:', 'gp-premium' ), - 'all_items' => __( 'All Page Headers', 'gp-premium' ), - 'add_new_item' => __( 'Add New Page Header', 'gp-premium' ), - 'new_item' => __( 'New Page Header', 'gp-premium' ), - 'edit_item' => __( 'Edit Page Header', 'gp-premium' ), - 'update_item' => __( 'Update Page Header', 'gp-premium' ), - 'view_item' => __( 'View Page Header', 'gp-premium' ), - 'search_items' => __( 'Search Page Header', 'gp-premium' ), - 'insert_into_item' => __( 'Insert into Page Header', 'gp-premium' ), - 'uploaded_to_this_item' => __( 'Uploaded to this Page Header', 'gp-premium' ), - ); - $args = array( - 'label' => __( 'Page Header', 'gp-premium' ), - 'labels' => $labels, - 'supports' => array( 'title', 'thumbnail' ), - 'hierarchical' => false, - 'public' => false, - 'show_ui' => true, - 'show_in_menu' => function_exists( 'generate_premium_do_elements' ) ? false : true, - 'menu_position' => 100, - 'menu_icon' => 'dashicons-welcome-widgets-menus', - 'show_in_admin_bar' => false, - 'show_in_nav_menus' => false, - 'can_export' => true, - 'has_archive' => false, - 'exclude_from_search' => true, - 'publicly_queryable' => false, - 'capability_type' => 'page', - ); - register_post_type( 'generate_page_header', $args ); - - $post_types = get_post_types( array( 'public' => true ) ); - $term_args = array( - 'sanitize_callback' => 'int', - 'type' => 'string', - 'description' => '', - 'single' => true, - 'show_in_rest' => true, - ); - foreach ( $post_types as $type ) { - register_meta( $type, 'generate_page_header', $term_args ); - } - - $taxonomies = get_taxonomies( array( 'public' => true ) ); - if ( $taxonomies ) { - foreach ( $taxonomies as $taxonomy ) { - add_action( $taxonomy . '_add_form_fields', 'generate_page_header_tax_new_ph_field' ); - add_action( $taxonomy . '_edit_form_fields', 'generate_page_header_tax_edit_ph_field' ); - add_action( 'edit_' . $taxonomy, 'generate_page_header_tax_save_ph' ); - add_action( 'create_' . $taxonomy, 'generate_page_header_tax_save_ph' ); - } - } -} - -add_action( 'admin_menu', 'generate_old_page_header_options_page' ); -/** - * Add our submenu page to the Appearance tab. - * - * @since 1.7 - */ -function generate_old_page_header_options_page() { - if ( ! function_exists( 'generate_premium_do_elements' ) ) { - return; - } - - add_submenu_page( - 'themes.php', - esc_html__( 'Page Headers', 'gp-premium' ), - esc_html__( 'Page Headers', 'gp-premium' ), - 'manage_options', - 'edit.php?post_type=generate_page_header' - ); -} - -add_action( 'admin_head', 'generate_old_page_header_fix_menu' ); -/** - * Set our current menu in the admin while in the old Page Header pages. - * - * @since 1.7 - */ -function generate_old_page_header_fix_menu() { - if ( ! function_exists( 'generate_premium_do_elements' ) ) { - return; - } - - global $parent_file, $submenu_file, $post_type; - - $screen = get_current_screen(); - - if ( 'generate_page_header' === $post_type || 'appearance_page_page-header-global-locations' === $screen->base ) { - $parent_file = 'themes.php'; - $submenu_file = 'edit.php?post_type=gp_elements'; - } - - remove_submenu_page( 'themes.php', 'edit.php?post_type=generate_page_header' ); - remove_submenu_page( 'themes.php', 'page-header-global-locations' ); -} - -add_action( 'admin_head', 'generate_page_header_add_legacy_locations_button', 999 ); -/** - * Add legacy buttons to our new GP Elements post type. - * - * @since 1.7 - */ -function generate_page_header_add_legacy_locations_button() { - if ( ! function_exists( 'generate_premium_do_elements' ) ) { - return; - } - - $screen = get_current_screen(); - - if ( 'generate_page_header' === $screen->post_type ) : - ?> - - post_type && 'edit' === $screen->base ) : - ?> - - -
            - - -
            - - - - - - - - - - - tag in metabox -* Elements: Add generate_elements_metabox_ajax_allow_editors filter -* Elements: Add new 3.0 hooks to hook selector -* Elements: Re-add generate_elements_custom_args filter -* Menu Plus: Better prepare navigation as header for GP 3.0 -* Menu Plus: Better prepare Off-Canvas Panel for GP 3.0 -* Menu Plus: Better prepare sticky navigation for GP 3.0 -* Menu Plus: Add has-menu-bar-items class to mobile header if needed -* Menu Plus: Add is-logo-image class to all site logos -* Menu Plus: Fix mobile header alignment when it has menu bar items -* Secondary Nav: Better prepare sticky navigation for GP 3.0 -* Secondary Nav: Fix hidden navigation widget in top bar when merged with secondary nav -* Sites: Improve the option-only import feature -* Sites: Improve the refresh sites button functionality -* Sites: Improve the undo site import functionality -* Sites: Fix Elementor site import issues -* Sites: Re-add Elementor sites to library -* Spacing: Better prepare Customizer live preview for GP 3.0 -* Spacing: Fix blog column spacing Customizer live preview -* Spacing: Stop handling mobile header, widget and footer widget features added in GP 3.0 -* Typography: Add mobile font size control for H3 (when using GP 3.0) -* Typography: Add mobile font size control for H4 (when using GP 3.0) -* Typography: Add mobile font size control for H5 (when using GP 3.0) -* Typography: Allow empty tablet and mobile site title font size values -* Typography: Make menu toggle CSS selector specific to primary navigation -* WooCommerce: Use CSS for secondary product image functionality instead of JS -* WooCommerce: Only load .js file if needed -* WooCommerce: Fix quantity box functionality when multiple quantity boxes exist on the page -* General: Improve alpha color picker script for better 5.5 compatibility -* General: Move child theme stylesheet after dynamic stylesheet if enabled -* General: Update gp-premium-de_DE.mo -* General: Update gp-premium-es_ES.mo -* General: Update gp-premium-fi.mo -* General: Update gp-premium-pt_PT.mo -* General: Update gp-premium-sv_SE.mo - -= 1.11.3 = -* Blog: Set widths to grid-sizer element -* Elements: Fix legacy Page Header/Hooks buttons in the Elements dashboard -* Page Header: Replace .load() with .on('load') -* Page Header: Fix color picker error in WP 5.5 - -= 1.11.2 = -* Blog: Remove negative featured image top margin from columns when using one container -* Blog: Fix infinite scroll items loading above viewport when using columns -* Blog: Fix infinite scroll featured images not displaying in Safari -* Elements: Prevent error in editor when generate_get_option() function doesn't exist -* General: Load inline CSS in previews when using external CSS option -* General: Update gp-premium-es_ES.mo -* General: Update gp-premium-pt_PT.mo - -= 1.11.1 = -* Elements: Remove stray quote character in Layout Element metabox -* Sections: Fix color picker JS error in WP 5.5 -* General: Fix external CSS option not removing inline CSS in some cases - -= 1.11.0 = -* New: Block Elements -* New: Apply Layout Element options to the block editor if set -* New: Generate dynamic CSS in an external file -* Blog: Separate CSS and load only when needed -* Blog: Add column width classes to stylesheet -* Blog: Disable featured image itemprop if microdata is disabled -* Blog: Add generate_blog_masonry_init filter -* Blog: Add generate_blog_infinite_scroll_init filter -* Blog: Fix archive page header overlap when using no featured image padding/one container -* Blog: Replace screen reader text with aria-label in read more buttons -* Disable Elements: Add option to disable the Mobile Header -* Disable Elements: Disable top bar disables it even when combined with Secondary Nav -* Disable Elements: Use generate_show_post_navigation filter to disable single post navigation -* Elements: Use full hook name with generate_ prefix in dropdown -* Elements: Rebuild how Element types are chosen -* Elements: Add chosen hook under type column in edit.php -* Menu Plus: Add generate_after_mobile_header_menu_button filter -* Menu Plus: Add sticky placeholder only when nav becomes sticky -* Menu Plus: Add class to sticky nav when scrolling up -* Menu Plus: Fix navigation branding/mobile header layout when using RTL languages -* Page Header: Prevent PHP notices -* Secondary Nav: Clean up CSS -* Secondary Nav: Add generate_after_secondary_navigation hook -* Secondary Nav: Add generate_before_secondary_navigation hook -* Secondary Nav: Integrate with future flexbox option -* Secondary Nav: Add has-top-bar class if needed -* Secondary Nav: Add screen reader text to mobile menu toggle if no text exists -* Secondary Nav: Remove microdata if disabled -* Secondary Nav: Add generate_secondary_menu_bar_items hook -* Spacing: Set sidebar width in Customizer for future flexbox option -* WooCommerce: Add generate_woocommerce_show_add_to_cart_panel filter -* WooCommerce: Integrate with future flexbox option -* WooCommerce: Ensure WC()->cart is set -* WooCommerce: Remove left margin from SVG menu cart icon -* WooCommerce: Show sticky add to cart panel on sold individually products -* WooCommerce: Remove bottom margin from related/upsell products -* WooCommerce: Fix cart menu item spacing in RTL languages -* WooCommerce: Fix menu item cart dropdown design in RTL languages -* General: Update selectWoo -* General: Update select2 -* General: Run all CSS through PostCSS -* General: Fix various text domains -* General: Fix JS error when toggling nav as header option without Colors/Typography modules -* General: Update all translations over 90% complete -* General: PHP cleanup/coding standards -* General: Add off_canvas_desktop_toggle_label to wpml-config.xml - -= 1.10.0 = -* Blog: Remove existing on-the-fly featured image resizer (Image Processing Queue) -* Blog: Choose from existing image sizes for featured images -* Blog: Use CSS to further resize featured images if necessary -* Blog: Fix edge case persistent transient bug with old image resizer -* Elements: Fix broken closing element in metabox -* General: Change scroll variable to gpscroll in smooth scroll script to avoid conflicts -* General: Update responsive widths in Customizer -* General: Fix responsive Customizer views when using RTL -* Menu Plus: Don't output sticky nav branding if sticky nav is disabled -* Menu Plus: Fix focus when off canvas overlay is opened (a11y) -* Menu Plus: Fix sticky navigation jump when navigation branding is in use -* Sections: Fix visible block editor when Sections are enabled -* WooCommerce: Use minmax in grid template definitions to fix overflow issue -* WooCommerce: Prevent add to cart panel interfering with back to top button on mobile -* WooCommerce: WooCommerce: Fix secondary image position if HTML isn't ordered correctly -* General: Add/update all translations over 50% complete. Big thanks to all contributors! -* Translation: Added Arabic - thank you anass! -* Translation: Added Bengali - thank you gtmroy! -* Translation: Added Spanish (Spain) - thank you davidperez (closemarketing.es)! -* Translation: Added Spanish (Argentina) - thank you bratorr! -* Translation: Added Finnish - thank you Stedi! -* Translation: Add Dutch - thank you Robin! -* Translation: Added Ukrainian - thank you EUROMEDIA! -* Translation: Vietnamese added - thank you themevi! - -= 1.9.1 = -* Blog: Fix "null" in infinite scroll load more button text -* WooCommerce: Fix hidden added to cart panel on mobile when sticky nav active -* WooCommerce: Fix missing SVG icon in mobile added to cart panel - -= 1.9.0 = -* Blog: Support SVG icon feature -* Colors: Add navigation search color options -* Disable Elements: Disable mobile menu in Mobile Header if nav is disabled -* Elements: Add wp_body_open hook -* Elements: Allow 0 mobile padding in Elements -* Elements: Add generate_elements_admin_menu_capability filter -* Elements: Add generate_page_hero_css_output filter -* Elements: Prevent error in Header Element if taxonomy doesn't exist -* Elements: Fix double logo when Header Element has logo + using nav as header -* Elements: Fix mobile header logo not replacing if merge is disabled -* Elements: Fix missing arrow in Choose Element Type select in WP 5.3 -* Elements: Add generate_inside_site_container hook option -* Elements: Add generate_after_entry_content hook option -* Menu Plus: Add off canvas desktop toggle label option -* Menu Plus: Add generate_off_canvas_toggle_output filter -* Menu Plus: Support SVG icon feature -* Menu Plus: Fix sticky navigation overlapping BB controls -* Menu Plus: Add align-items: center to nav as header, mobile header and sticky nav with branding -* Sections: Fix text/visual switch bug in Firefox -* Sites: Add option to revert site import -* Sites: Increase site library limit to 100 -* Spacing: Add live preview to group container padding -* Typography: Add tablet site title/navigation font size options -* Typography: Add archive post title weight, transform, font size and line height -* Typography: Add single content title weight, transform, font size and line height -* Typography: Only call all google fonts once in the Customizer -* Typography: Get Google fonts from readable JSON list -* Typography: Make sure font settings aren't lost if list is changed -* Typography: Only call generate_get_all_google_fonts if needed -* WooCommerce: Add columns gap options (desktop, tablet, mobile) -* WooCommerce: Add tablet column options -* WooCommerce: Add related/upsell tablet column options -* WooCommerce: Support SVG icon feature -* WooCommerce: Prevent empty added to cart panel on single products -* WooCommerce: Fix woocommerce-ordering arrow in old FF versions -* WooCommerce: Make item/items string translatable -* General: Better customizer device widths -* General: Use generate_premium_get_media_query throughout modules -* General: Improve Customizer control styling - -= 1.8.3 = -* Menu Plus: Use flexbox for center aligned nav with nav branding -* Menu Plus: Center overlay off canvas exit button on mobile -* Menu Plus: Add alt tag to sticky nav logo -* Menu Plus: Set generate_not_mobile_menu_media_query filter based on mobile menu breakpoint -* Sections: Remember when text tab is active -* Sections: Disable visual editor if turned off in profile -* Typography: Add generate_google_font_display filter -* WooCommerce: Fix single product sidebar layout metabox option -* WooCommerce: Reduce carousel thumbnail max-width to 100px to match new thumbnail sizes - -= 1.8.2 = -* Elements: Use Page Hero site title color for mobile header site title -* Menu Plus: Give mobile header site title more left spacing -* Menu Plus: Fix nav search icon in sticky navigation when using nav branding in Firefox -* Site Library: Show Site Library tab even if no sites exist -* Site Library: Show an error message in Site Library if no sites exist -* Typography: Remove reference to generate_get_navigation_location() function -* WooCommerce: Remove quantity field arrows when using quantity buttons in Firefox -* WooCommerce: Remove extra border when loading quantity buttons -* WooCommerce: Use get_price_html() is sticky add to cart panel - -= 1.8.1 = -* Menu Plus: Revert sticky nav duplicate ID fix due to Cyrillic script bug - -= 1.8 = -* Blog: Apply columns filter to masonry grid sizer -* Colors: Merge Footer Widgets and Footer controls in Color panel -* Colors: Remove edit_theme_options capability to Customizer controls (set by default) -* Disable Elements: Make sure mobile header is disabled when primary navigation is disabled -* Elements: Add content width option in Layout Element -* Elements: Fix mobile header logo when mobile menu toggled -* Elements: Add generate_page_hero_location filter -* Elements: Add generate_elements_show_object_ids filter to show IDs in Display Rule values -* Elements: Prevent merged header wrap from conflicting with Elementor controls -* Elements: Change Container tab name to Content -* Elements: Add woocommerce_share option to Hooks -* Elements: Improve WPML compatibility -* Elements: Improve Polylang compatibility -* Elements: Prevent PHP notices when adding taxonomy locations to non-existent archives -* Elements: Add generate_mobile_cart_items hook to hook list -* Elements: Add generate_element_post_id filter -* Elements: Escape HTML elements inside Element textarea -* Elements: Add Beaver Builder templates to the Display Rules -* Menu Plus: Add mobile header breakpoint option -* Menu Plus: Add off canvas overlay option -* Menu Plus: Add navigation as header option -* Menu Plus: Remove navigation logo option if navigation as header set -* Menu Plus: Add sticky navigation logo option -* Menu Plus: Allow site title in mobile header instead of logo -* Menu Plus: Add option to move exit button inside the off canvas panel -* Menu Plus: Change Slideout Navigation name to Off Canvas Panel -* Menu Plus: Only re-focus after slideout close on escape key -* Menu Plus: Give close slideout event a name so it can be removed -* Menu Plus: Remove invalid transition-delay -* Menu Plus: Improve slideout overlay transition -* Menu Plus: Add mobile open/close icons to GPP font -* Menu Plus: Allow dynamic widget classes in off canvas panel (fixes WC range slider widget issue) -* Menu Plus: Basic compatibility with future SVG icons -* Menu Plus: Prevent duplicate IDs when sticky navigation is cloned -* Secondary Nav: Add dropdown direction option -* Secondary Nav: Basic compatibility with future SVG icons -* Sections: Fix section editor issues in WP 5.0 -* Sections: Show Better Font Awesome icon in editor -* Sites: Re-design UI -* Sites: Add option to activate as a module like all the other modules -* Sites: Don't show backup options button if no options exist -* Sites: Make JS action classes more specific to the site library -* Sites: Set mime types of content.xml and widgets.wie -* Spacing: Add header padding option for mobile -* Spacing: Add widget padding option for mobile -* Spacing: Add footer widgets padding option for mobile -* Spacing: Add content separator option -* Spacing: Apply mobile menu item width to mobile bar only -* WooCommerce: Add option for mini cart in the menu -* WooCommerce: Add option to open off overlay panel on add to cart -* WooCommerce: Add option to open sticky add to cart panel on single products -* WooCommerce: Add option to add +/- buttons to the quantity fields -* WooCommerce: Add option to show number of items in cart menu item -* WooCommerce: Add option to choose single product image area width -* WooCommerce: Add color options for price slider widget -* WooCommerce: Use CSS grid for the product archives -* WooCommerce: Horizontally align add to cart buttons -* WooCommerce: Re-design the cart widget -* WooCommerce: Tighten up product info spacing -* WooCommerce: Improve product tab design to look more like tabs -* WooCommerce: Simplify single product image display -* WooCommerce: Use flexbox for quantity/add to cart alignment -* WooCommerce: Improve rating star styles -* WooCommerce: Use product alignment setting for related/upsell products -* WooCommerce: Remove bottom margin from product image -* WooCommerce: Organize colors in the Customizer -* WooCommerce: Remove title attribute from menu cart item -* WooCommerce: Improve coupon field design -* WooCommerce: Improve result count/ordering styling -* WooCommerce: Add gap around WC single product images -* WooCommerce: Remove arrow from checkout button -* WooCommerce: Hide view cart link on add to cart click -* WooCommerce: Organize CSS -* Introduce in-Customizer shortcuts -* Add generate_disable_customizer_shortcuts filter diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/fields/secondary-navigation.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/fields/secondary-navigation.php deleted file mode 100644 index d2bffea0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/fields/secondary-navigation.php +++ /dev/null @@ -1,174 +0,0 @@ - a, .secondary-navigation .main-nav ul li:not([class*="current-menu-"]):focus > a, .secondary-navigation .main-nav ul li.sfHover:not([class*="current-menu-"]) > a, .secondary-navigation .menu-bar-item:hover > a, .secondary-navigation .menu-bar-item.sfHover > a'; - $menu_current_selectors = '.secondary-navigation .main-nav ul li[class*="current-menu-"] > a'; - $submenu_hover_selectors = '.secondary-navigation .main-nav ul ul li:not([class*="current-menu-"]):hover > a, .secondary-navigation .main-nav ul ul li:not([class*="current-menu-"]):focus > a, .secondary-navigation .main-nav ul ul li.sfHover:not([class*="current-menu-"]) > a'; - $submenu_current_selectors = '.secondary-navigation .main-nav ul ul li[class*="current-menu-"] > a'; - - GeneratePress_Customize_Field::add_title( - 'generate_secondary_navigation_colors_title', - array( - 'section' => 'generate_colors_section', - 'title' => __( 'Secondary Navigation', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'secondary-navigation-colors', - ), - ) - ); - - // Navigation background group. - GeneratePress_Customize_Field::add_color_field_group( - 'secondary_navigation_background', - 'generate_colors_section', - 'secondary-navigation-colors', - array( - 'generate_secondary_nav_settings[navigation_background_color]' => array( - 'default_value' => $secondary_color_defaults['navigation_background_color'], - 'label' => __( 'Navigation Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.secondary-navigation', - 'property' => 'background-color', - 'hide_label' => false, - ), - 'generate_secondary_nav_settings[navigation_background_hover_color]' => array( - 'default_value' => $secondary_color_defaults['navigation_background_hover_color'], - 'label' => __( 'Navigation Background Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => $menu_hover_selectors, - 'property' => 'background-color', - 'hide_label' => true, - ), - 'generate_secondary_nav_settings[navigation_background_current_color]' => array( - 'default_value' => $secondary_color_defaults['navigation_background_current_color'], - 'label' => __( 'Navigation Background Current', 'gp-premium' ), - 'tooltip' => __( 'Choose Current Color', 'gp-premium' ), - 'element' => $menu_current_selectors, - 'property' => 'background-color', - 'hide_label' => true, - ), - ) - ); - - // Navigation text group. - GeneratePress_Customize_Field::add_color_field_group( - 'secondary_navigation_text', - 'generate_colors_section', - 'secondary-navigation-colors', - array( - 'generate_secondary_nav_settings[navigation_text_color]' => array( - 'default_value' => $secondary_color_defaults['navigation_text_color'], - 'label' => __( 'Navigation Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.secondary-navigation .main-nav ul li a, .secondary-navigation .menu-toggle, .secondary-navigation button.menu-toggle:hover, .secondary-navigation button.menu-toggle:focus, .secondary-navigation .mobile-bar-items a, .secondary-navigation .mobile-bar-items a:hover, .secondary-navigation .mobile-bar-items a:focus, .secondary-navigation .menu-bar-items', - 'property' => 'color', - 'hide_label' => false, - ), - 'generate_secondary_nav_settings[navigation_text_hover_color]' => array( - 'default_value' => $secondary_color_defaults['navigation_text_hover_color'], - 'label' => __( 'Navigation Text Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => $menu_hover_selectors, - 'property' => 'color', - 'hide_label' => true, - ), - 'generate_secondary_nav_settings[navigation_text_current_color]' => array( - 'default_value' => $secondary_color_defaults['navigation_text_current_color'], - 'label' => __( 'Navigation Text Current', 'gp-premium' ), - 'tooltip' => __( 'Choose Current Color', 'gp-premium' ), - 'element' => $menu_current_selectors, - 'property' => 'color', - 'hide_label' => true, - ), - ) - ); - - // Sub-Menu background group. - GeneratePress_Customize_Field::add_color_field_group( - 'secondary_navigation_submenu_background', - 'generate_colors_section', - 'secondary-navigation-colors', - array( - 'generate_secondary_nav_settings[subnavigation_background_color]' => array( - 'default_value' => $secondary_color_defaults['subnavigation_background_color'], - 'label' => __( 'Sub-Menu Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.secondary-navigation ul ul', - 'property' => 'background-color', - 'hide_label' => false, - ), - 'generate_secondary_nav_settings[subnavigation_background_hover_color]' => array( - 'default_value' => $secondary_color_defaults['subnavigation_background_hover_color'], - 'label' => __( 'Sub-Menu Background Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => $submenu_hover_selectors, - 'property' => 'background-color', - 'hide_label' => true, - ), - 'generate_secondary_nav_settings[subnavigation_background_current_color]' => array( - 'default_value' => $secondary_color_defaults['subnavigation_background_current_color'], - 'label' => __( 'Sub-Menu Background Current', 'gp-premium' ), - 'tooltip' => __( 'Choose Current Color', 'gp-premium' ), - 'element' => $submenu_current_selectors, - 'property' => 'background-color', - 'hide_label' => true, - ), - ) - ); - - // Sub-Menu text group. - GeneratePress_Customize_Field::add_color_field_group( - 'secondary_navigation_submenu_text', - 'generate_colors_section', - 'secondary-navigation-colors', - array( - 'generate_secondary_nav_settings[subnavigation_text_color]' => array( - 'default_value' => $secondary_color_defaults['subnavigation_text_color'], - 'label' => __( 'Sub-Menu Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.secondary-navigation .main-nav ul ul li a', - 'property' => 'color', - 'hide_label' => false, - ), - 'generate_secondary_nav_settings[subnavigation_text_hover_color]' => array( - 'default_value' => $secondary_color_defaults['subnavigation_text_hover_color'], - 'label' => __( 'Sub-Menu Text Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => $submenu_hover_selectors, - 'property' => 'color', - 'hide_label' => true, - ), - 'generate_secondary_nav_settings[subnavigation_text_current_color]' => array( - 'default_value' => $secondary_color_defaults['subnavigation_text_current_color'], - 'label' => __( 'Sub-Menu Text Current', 'gp-premium' ), - 'tooltip' => __( 'Choose Current Color', 'gp-premium' ), - 'element' => $submenu_current_selectors, - 'property' => 'color', - 'hide_label' => true, - ), - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css.php deleted file mode 100644 index 370c5ef8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css.php +++ /dev/null @@ -1,138 +0,0 @@ -_selector ) { - $this->add_selector_rules_to_output(); - } - - $this->_selector = $selector; - return $this; - } - - /** - * Adds a css property with value to the css output. - * - * @access public - * @since 1.0 - * - * @param string $property - the css property. - * @param string $value - the value to be placed with the property. - * @param string $og_default - check to see if the value matches the default. - * @param string $unit - the unit for the value (px). - * @return $this - */ - public function add_property( $property, $value, $og_default = false, $unit = false ) { - // Add our unit to the value if it exists. - if ( $unit && '' !== $unit ) { - $value = $value . $unit; - if ( '' !== $og_default ) { - $og_default = $og_default . $unit; - } - } - - // If we don't have a value or our value is the same as our og default, bail. - if ( empty( $value ) || $og_default == $value ) { - return false; - } - - $this->_css .= $property . ':' . $value . ';'; - return $this; - } - - /** - * Adds the current selector rules to the output variable - * - * @access private - * @since 1.0 - * - * @return $this - */ - private function add_selector_rules_to_output() { - if ( ! empty( $this->_css ) ) { - $this->_selector_output = $this->_selector; - $selector_output = sprintf( '%1$s{%2$s}', $this->_selector_output, $this->_css ); - - $this->_output .= $selector_output; - - // Reset the css. - $this->_css = ''; - } - - return $this; - } - - /** - * Returns the minified css in the $_output variable - * - * @access public - * @since 1.0 - * - * @return string - */ - public function css_output() { - // Add current selector's rules to output. - $this->add_selector_rules_to_output(); - - // Output minified css. - return $this->_output; - } - - } -endif; diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main-mobile.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main-mobile.css deleted file mode 100644 index ed9b708c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main-mobile.css +++ /dev/null @@ -1,125 +0,0 @@ -.secondary-navigation.toggled ul ul { - transition: 0s; - visibility: hidden; - float: none; -} - -.secondary-navigation.toggled ul ul.toggled-on { - visibility: visible; -} - -.secondary-navigation.toggled .main-nav ul ul { - position: relative; - top: 0; - left: 0; - width: 100%; - box-shadow: none; - border-bottom: 1px solid rgba(0, 0, 0, 0.05); -} - -.secondary-navigation.toggled .main-nav ul ul li:last-child > ul { - border-bottom: 0; -} - -.secondary-navigation.toggled .main-nav ul ul.toggled-on { - position: relative; - top: 0; - left: auto !important; - right: auto !important; - width: 100%; - pointer-events: auto; - height: auto; - opacity: 1; - display: block; -} - -.secondary-navigation.toggled .main-nav > ul { - display: block; -} - -.secondary-navigation.toggled .main-nav .sf-menu > li { - float: none; - clear: both; - display: block !important; - text-align: left !important; -} - -.secondary-navigation.toggled .main-nav .sf-menu > li.hide-on-mobile { - display: none !important; -} - -.secondary-navigation.toggled .dropdown-menu-toggle:before { - content: "\f107" !important; -} - -.secondary-navigation.toggled .sfHover > a .dropdown-menu-toggle:before { - content: "\f106" !important; -} - -.secondary-navigation.toggled .menu-item-has-children .dropdown-menu-toggle { - float: right; -} - -.dropdown-hover .secondary-navigation.toggled ul li:hover > ul, -.dropdown-hover .secondary-navigation.toggled ul li.sfHover > ul { - transition-delay: 0s; -} - -.rtl .secondary-navigation.toggled .main-nav .sf-menu > li { - text-align: right !important; -} - -@media (max-width: 768px) { - .secondary-navigation .menu-toggle { - display: block; - } - .secondary-navigation ul, - .secondary-navigation:not(.toggled) .main-nav > ul { - display: none; - } - .secondary-navigation.toggled .main-nav { - flex-basis: 100%; - order: 3; - } - .secondary-nav-aligned-left .secondary-navigation.has-top-bar .menu-toggle { - text-align: left; - } - .secondary-nav-aligned-left .secondary-navigation .top-bar { - order: 2; - } - .secondary-nav-aligned-right .secondary-navigation.has-top-bar .menu-toggle { - text-align: right; - } - .secondary-navigation.has-top-bar .top-bar .inside-top-bar .widget { - margin: 0 20px; - } - .secondary-nav-aligned-center .secondary-navigation .top-bar { - flex-basis: 100%; - } - .secondary-nav-float-right .secondary-navigation { - margin-left: 0; - width: 100%; - margin-top: 1.5em; - } - .secondary-nav-float-right .header-widget { - margin-left: auto; - } - .secondary-nav-float-left .secondary-navigation, - .secondary-nav-float-left .multi-navigation-wrapper { - margin-left: 0; - width: 100%; - margin-top: 1.5em; - } - .secondary-nav-float-left:not(.nav-float-right) .header-widget { - margin-left: auto; - margin-right: auto; - order: unset; - } - .secondary-nav-float-left .site-logo, - .secondary-nav-float-left .site-branding { - order: unset; - } - .secondary-navigation.has-top-bar .inside-navigation, .secondary-navigation.has-menu-bar-items .inside-navigation { - justify-content: space-between; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main-mobile.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main-mobile.min.css deleted file mode 100644 index 567c5024..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main-mobile.min.css +++ /dev/null @@ -1 +0,0 @@ -.secondary-navigation.toggled ul ul{transition:0s;visibility:hidden;float:none}.secondary-navigation.toggled ul ul.toggled-on{visibility:visible}.secondary-navigation.toggled .main-nav ul ul{position:relative;top:0;left:0;width:100%;box-shadow:none;border-bottom:1px solid rgba(0,0,0,.05)}.secondary-navigation.toggled .main-nav ul ul li:last-child>ul{border-bottom:0}.secondary-navigation.toggled .main-nav ul ul.toggled-on{position:relative;top:0;left:auto!important;right:auto!important;width:100%;pointer-events:auto;height:auto;opacity:1;display:block}.secondary-navigation.toggled .main-nav>ul{display:block}.secondary-navigation.toggled .main-nav .sf-menu>li{float:none;clear:both;display:block!important;text-align:left!important}.secondary-navigation.toggled .main-nav .sf-menu>li.hide-on-mobile{display:none!important}.secondary-navigation.toggled .dropdown-menu-toggle:before{content:"\f107"!important}.secondary-navigation.toggled .sfHover>a .dropdown-menu-toggle:before{content:"\f106"!important}.secondary-navigation.toggled .menu-item-has-children .dropdown-menu-toggle{float:right}.dropdown-hover .secondary-navigation.toggled ul li.sfHover>ul,.dropdown-hover .secondary-navigation.toggled ul li:hover>ul{transition-delay:0s}.rtl .secondary-navigation.toggled .main-nav .sf-menu>li{text-align:right!important}@media (max-width:768px){.secondary-navigation .menu-toggle{display:block}.secondary-navigation ul,.secondary-navigation:not(.toggled) .main-nav>ul{display:none}.secondary-navigation.toggled .main-nav{flex-basis:100%;order:3}.secondary-nav-aligned-left .secondary-navigation.has-top-bar .menu-toggle{text-align:left}.secondary-nav-aligned-left .secondary-navigation .top-bar{order:2}.secondary-nav-aligned-right .secondary-navigation.has-top-bar .menu-toggle{text-align:right}.secondary-navigation.has-top-bar .top-bar .inside-top-bar .widget{margin:0 20px}.secondary-nav-aligned-center .secondary-navigation .top-bar{flex-basis:100%}.secondary-nav-float-right .secondary-navigation{margin-left:0;width:100%;margin-top:1.5em}.secondary-nav-float-right .header-widget{margin-left:auto}.secondary-nav-float-left .multi-navigation-wrapper,.secondary-nav-float-left .secondary-navigation{margin-left:0;width:100%;margin-top:1.5em}.secondary-nav-float-left:not(.nav-float-right) .header-widget{margin-left:auto;margin-right:auto;order:unset}.secondary-nav-float-left .site-branding,.secondary-nav-float-left .site-logo{order:unset}.secondary-navigation.has-menu-bar-items .inside-navigation,.secondary-navigation.has-top-bar .inside-navigation{justify-content:space-between}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main.css deleted file mode 100644 index 9540b8a4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main.css +++ /dev/null @@ -1,377 +0,0 @@ -.secondary-navigation { - z-index: 99; - padding: 0; -} - -.secondary-navigation .inside-navigation { - display: flex; - align-items: center; - flex-wrap: wrap; - justify-content: space-between; -} - -.secondary-navigation ul { - list-style: none; - margin: 0; - padding-left: 0; -} - -.secondary-navigation li { - position: relative; -} - -.secondary-navigation a { - display: block; - text-decoration: none; -} - -.secondary-navigation ul ul { - display: block; - box-shadow: 0 1px 1px rgba(0, 0, 0, 0.1); - float: left; - position: absolute; - left: -99999px; - opacity: 0; - z-index: 99999; - width: 200px; - text-align: left; - top: auto; - transition: opacity 80ms linear; - transition-delay: 0s; - pointer-events: none; - height: 0; - overflow: hidden; -} - -.secondary-navigation ul ul li { - width: 100%; -} - -.secondary-navigation ul ul li a { - line-height: normal; - font-size: 90%; -} - -.secondary-navigation.sub-menu-left ul ul { - box-shadow: -1px 1px 0 rgba(0, 0, 0, 0.1); -} - -.secondary-navigation.sub-menu-left .sub-menu { - right: 0; -} - -.secondary-navigation .main-nav > ul { - display: flex; - flex-wrap: wrap; -} - -.secondary-navigation .main-nav ul ul li a { - line-height: normal; - font-size: 12px; - padding-left: 20px; - padding-right: 20px; - padding-top: 10px; - padding-bottom: 10px; -} - -.secondary-navigation .main-nav ul li.menu-item-has-children > a { - padding-right: 0; - position: relative; -} - -.secondary-navigation .main-nav ul li a { - font-family: inherit; - font-weight: normal; - text-transform: none; - font-size: 13px; - padding-left: 20px; - padding-right: 20px; - line-height: 40px; -} - -.secondary-navigation .menu-toggle { - font-family: inherit; - font-weight: normal; - text-transform: none; - font-size: 13px; - padding-left: 20px; - padding-right: 20px; - line-height: 40px; - margin: 0; -} - -.secondary-navigation .menu-item-has-children .dropdown-menu-toggle { - padding-right: 20px; -} - -.secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle { - padding-top: 10px; - padding-bottom: 10px; - margin-top: -10px; -} - -.secondary-navigation .secondary-menu-bar-items { - display: flex; - align-items: center; - font-size: 13px; -} - -.secondary-navigation .menu-bar-item { - position: relative; -} - -.secondary-navigation .menu-bar-item.search-item { - z-index: 20; -} - -.secondary-navigation .menu-bar-item > a { - font-family: inherit; - font-weight: normal; - text-transform: none; - font-size: 13px; - padding-left: 20px; - padding-right: 20px; - line-height: 40px; -} - -.dropdown-hover .secondary-navigation:not(.toggled) ul li:hover > ul, -.dropdown-hover .secondary-navigation:not(.toggled) ul li.sfHover > ul { - left: auto; - opacity: 1; - transition-delay: 150ms; - pointer-events: auto; - height: auto; - overflow: visible; -} - -.dropdown-hover .secondary-navigation:not(.toggled) ul ul li:hover > ul, -.dropdown-hover .secondary-navigation:not(.toggled) ul ul li.sfHover > ul { - left: 100%; - top: 0; -} - -.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li:hover > ul, -.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li.sfHover > ul { - right: 100%; - top: 0; - left: auto; -} - -.secondary-nav-float-right .header-widget { - margin-left: 20px; -} - -.secondary-nav-float-right .secondary-navigation { - margin-left: auto; -} - -.secondary-nav-float-right .secondary-navigation .main-nav ul ul li a { - line-height: normal; -} - -.secondary-nav-float-right .secondary-navigation ul ul ul { - top: 0; -} - -.secondary-nav-float-right .multi-navigation-wrapper { - margin-left: auto; -} - -.secondary-nav-float-left .secondary-navigation, -.secondary-nav-float-left .multi-navigation-wrapper { - margin-right: auto; -} - -.secondary-nav-float-left .site-logo, -.secondary-nav-float-left .site-branding { - order: 5; -} - -.secondary-nav-float-left:not(.nav-float-right) .header-widget { - order: -10; - margin-left: 0; - margin-right: 20px; -} - -.secondary-nav-float-left.nav-float-right .site-branding, -.secondary-nav-float-left.nav-float-right .site-logo { - margin-left: auto; - margin-right: auto; -} - -.secondary-nav-float-left.nav-float-right .inside-header .main-navigation, -.secondary-nav-float-left.nav-float-right .header-widget { - order: 10; -} - -.secondary-nav-float-right.nav-float-left .secondary-navigation { - order: 10; -} - -.multi-navigation-wrapper { - display: flex; - flex-direction: column; -} - -.widget-area .secondary-navigation li { - display: block; - float: none; - margin: 0; - padding: 0; - width: 100%; -} - -.widget-area .secondary-navigation ul ul { - left: 100%; - top: 0; - width: 220px; -} - -.secondary-nav-aligned-right .secondary-navigation .inside-navigation { - justify-content: flex-end; -} - -.secondary-nav-aligned-right.rtl .secondary-navigation .inside-navigation { - justify-content: flex-start; -} - -.secondary-nav-aligned-center .secondary-navigation .inside-navigation { - justify-content: center; -} - -.secondary-nav-aligned-center .secondary-navigation .main-nav > ul { - justify-content: center; -} - -.secondary-nav-aligned-left.rtl .secondary-navigation .inside-navigation { - justify-content: flex-end; -} - -.dropdown-click .secondary-navigation ul ul { - visibility: hidden; - float: none; -} - -.dropdown-click .secondary-navigation ul.toggled-on, -.dropdown-click .secondary-navigation ul li.sfHover > ul.toggled-on { - left: auto; - opacity: 1; - visibility: visible; - pointer-events: auto; - height: auto; - overflow: visible; -} - -.dropdown-click .secondary-navigation ul ul ul.toggled-on { - left: 0; - top: auto; - position: relative; - box-shadow: none; - border-bottom: 1px solid rgba(0, 0, 0, 0.05); -} - -.dropdown-click .secondary-navigation ul ul li:last-child > ul.toggled-on { - border-bottom: 0; -} - -.dropdown-click .widget-area .secondary-navigation ul ul { - top: auto; - position: absolute; - float: none; - width: 100%; - left: -99999px; -} - -.dropdown-click .widget-area .secondary-navigation ul ul.toggled-on { - position: relative; - left: 0; - right: 0; -} - -.both-right .widget-area .secondary-navigation ul ul, -.right-sidebar .widget-area .secondary-navigation ul ul, -.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul { - left: auto; - right: 100%; -} - -.dropdown-click.both-right .widget-area .secondary-navigation ul ul, -.dropdown-click.right-sidebar .widget-area .secondary-navigation ul ul, -.dropdown-click.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul { - right: 0; -} - -.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li.sfHover > ul { - top: 0; - left: 100%; - width: 220px; -} - -.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul, -.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul, -.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li.sfHover ul { - right: 100%; - left: auto; -} - -.rtl .secondary-navigation ul ul { - float: right; - left: auto; - right: 0; - text-align: right; -} - -.rtl .secondary-navigation ul ul ul { - left: auto; - right: 100%; -} - -.rtl .secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle { - transform: rotate(180deg); -} - -/* Top bar */ -.secondary-navigation.has-top-bar .menu-toggle, .secondary-navigation.has-menu-bar-items .menu-toggle { - flex-grow: 0; -} - -.secondary-navigation .top-bar { - background: transparent; -} - -.secondary-navigation .top-bar a { - display: inline; -} - -.secondary-navigation .inside-top-bar { - padding: 0; -} - -.secondary-nav-aligned-right .secondary-navigation .top-bar { - margin-right: auto; -} - -.secondary-nav-aligned-right .secondary-navigation .top-bar .inside-top-bar .widget { - margin: 0 10px; -} - -.secondary-nav-aligned-left .secondary-navigation .top-bar { - order: 2; - margin-left: auto; -} - -.secondary-nav-aligned-left .secondary-navigation .top-bar .inside-top-bar .widget { - margin-left: 10px; -} - -.secondary-nav-aligned-center .secondary-navigation.has-top-bar .inside-top-bar { - justify-content: center; -} - -.secondary-nav-aligned-center .secondary-navigation.has-top-bar .inside-navigation { - display: block; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main.min.css deleted file mode 100644 index e21c11da..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/main.min.css +++ /dev/null @@ -1 +0,0 @@ -.secondary-navigation{z-index:99;padding:0}.secondary-navigation .inside-navigation{display:flex;align-items:center;flex-wrap:wrap;justify-content:space-between}.secondary-navigation ul{list-style:none;margin:0;padding-left:0}.secondary-navigation li{position:relative}.secondary-navigation a{display:block;text-decoration:none}.secondary-navigation ul ul{display:block;box-shadow:0 1px 1px rgba(0,0,0,.1);float:left;position:absolute;left:-99999px;opacity:0;z-index:99999;width:200px;text-align:left;top:auto;transition:opacity 80ms linear;transition-delay:0s;pointer-events:none;height:0;overflow:hidden}.secondary-navigation ul ul li{width:100%}.secondary-navigation ul ul li a{line-height:normal;font-size:90%}.secondary-navigation.sub-menu-left ul ul{box-shadow:-1px 1px 0 rgba(0,0,0,.1)}.secondary-navigation.sub-menu-left .sub-menu{right:0}.secondary-navigation .main-nav>ul{display:flex;flex-wrap:wrap}.secondary-navigation .main-nav ul ul li a{line-height:normal;font-size:12px;padding-left:20px;padding-right:20px;padding-top:10px;padding-bottom:10px}.secondary-navigation .main-nav ul li.menu-item-has-children>a{padding-right:0;position:relative}.secondary-navigation .main-nav ul li a{font-family:inherit;font-weight:400;text-transform:none;font-size:13px;padding-left:20px;padding-right:20px;line-height:40px}.secondary-navigation .menu-toggle{font-family:inherit;font-weight:400;text-transform:none;font-size:13px;padding-left:20px;padding-right:20px;line-height:40px;margin:0}.secondary-navigation .menu-item-has-children .dropdown-menu-toggle{padding-right:20px}.secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle{padding-top:10px;padding-bottom:10px;margin-top:-10px}.secondary-navigation .secondary-menu-bar-items{display:flex;align-items:center;font-size:13px}.secondary-navigation .menu-bar-item{position:relative}.secondary-navigation .menu-bar-item.search-item{z-index:20}.secondary-navigation .menu-bar-item>a{font-family:inherit;font-weight:400;text-transform:none;font-size:13px;padding-left:20px;padding-right:20px;line-height:40px}.dropdown-hover .secondary-navigation:not(.toggled) ul li.sfHover>ul,.dropdown-hover .secondary-navigation:not(.toggled) ul li:hover>ul{left:auto;opacity:1;transition-delay:150ms;pointer-events:auto;height:auto;overflow:visible}.dropdown-hover .secondary-navigation:not(.toggled) ul ul li.sfHover>ul,.dropdown-hover .secondary-navigation:not(.toggled) ul ul li:hover>ul{left:100%;top:0}.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li.sfHover>ul,.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li:hover>ul{right:100%;top:0;left:auto}.secondary-nav-float-right .header-widget{margin-left:20px}.secondary-nav-float-right .secondary-navigation{margin-left:auto}.secondary-nav-float-right .secondary-navigation .main-nav ul ul li a{line-height:normal}.secondary-nav-float-right .secondary-navigation ul ul ul{top:0}.secondary-nav-float-right .multi-navigation-wrapper{margin-left:auto}.secondary-nav-float-left .multi-navigation-wrapper,.secondary-nav-float-left .secondary-navigation{margin-right:auto}.secondary-nav-float-left .site-branding,.secondary-nav-float-left .site-logo{order:5}.secondary-nav-float-left:not(.nav-float-right) .header-widget{order:-10;margin-left:0;margin-right:20px}.secondary-nav-float-left.nav-float-right .site-branding,.secondary-nav-float-left.nav-float-right .site-logo{margin-left:auto;margin-right:auto}.secondary-nav-float-left.nav-float-right .header-widget,.secondary-nav-float-left.nav-float-right .inside-header .main-navigation{order:10}.secondary-nav-float-right.nav-float-left .secondary-navigation{order:10}.multi-navigation-wrapper{display:flex;flex-direction:column}.widget-area .secondary-navigation li{display:block;float:none;margin:0;padding:0;width:100%}.widget-area .secondary-navigation ul ul{left:100%;top:0;width:220px}.secondary-nav-aligned-right .secondary-navigation .inside-navigation{justify-content:flex-end}.secondary-nav-aligned-right.rtl .secondary-navigation .inside-navigation{justify-content:flex-start}.secondary-nav-aligned-center .secondary-navigation .inside-navigation{justify-content:center}.secondary-nav-aligned-center .secondary-navigation .main-nav>ul{justify-content:center}.secondary-nav-aligned-left.rtl .secondary-navigation .inside-navigation{justify-content:flex-end}.dropdown-click .secondary-navigation ul ul{visibility:hidden;float:none}.dropdown-click .secondary-navigation ul li.sfHover>ul.toggled-on,.dropdown-click .secondary-navigation ul.toggled-on{left:auto;opacity:1;visibility:visible;pointer-events:auto;height:auto;overflow:visible}.dropdown-click .secondary-navigation ul ul ul.toggled-on{left:0;top:auto;position:relative;box-shadow:none;border-bottom:1px solid rgba(0,0,0,.05)}.dropdown-click .secondary-navigation ul ul li:last-child>ul.toggled-on{border-bottom:0}.dropdown-click .widget-area .secondary-navigation ul ul{top:auto;position:absolute;float:none;width:100%;left:-99999px}.dropdown-click .widget-area .secondary-navigation ul ul.toggled-on{position:relative;left:0;right:0}.both-right .widget-area .secondary-navigation ul ul,.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul,.right-sidebar .widget-area .secondary-navigation ul ul{left:auto;right:100%}.dropdown-click.both-right .widget-area .secondary-navigation ul ul,.dropdown-click.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul,.dropdown-click.right-sidebar .widget-area .secondary-navigation ul ul{right:0}.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li.sfHover>ul,.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li:hover ul{top:0;left:100%;width:220px}.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul,.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li:hover ul,.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li.sfHover ul,.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li:hover ul,.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul,.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li:hover ul{right:100%;left:auto}.rtl .secondary-navigation ul ul{float:right;left:auto;right:0;text-align:right}.rtl .secondary-navigation ul ul ul{left:auto;right:100%}.rtl .secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle{transform:rotate(180deg)}.secondary-navigation.has-menu-bar-items .menu-toggle,.secondary-navigation.has-top-bar .menu-toggle{flex-grow:0}.secondary-navigation .top-bar{background:0 0}.secondary-navigation .top-bar a{display:inline}.secondary-navigation .inside-top-bar{padding:0}.secondary-nav-aligned-right .secondary-navigation .top-bar{margin-right:auto}.secondary-nav-aligned-right .secondary-navigation .top-bar .inside-top-bar .widget{margin:0 10px}.secondary-nav-aligned-left .secondary-navigation .top-bar{order:2;margin-left:auto}.secondary-nav-aligned-left .secondary-navigation .top-bar .inside-top-bar .widget{margin-left:10px}.secondary-nav-aligned-center .secondary-navigation.has-top-bar .inside-top-bar{justify-content:center}.secondary-nav-aligned-center .secondary-navigation.has-top-bar .inside-navigation{display:block} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style-mobile.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style-mobile.css deleted file mode 100644 index 51b5e656..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style-mobile.css +++ /dev/null @@ -1,97 +0,0 @@ -.secondary-navigation.toggled ul ul { - transition: 0s; - visibility: hidden; -} - -.secondary-navigation.toggled ul ul.toggled-on { - visibility: visible; -} - -.secondary-navigation.toggled .main-nav ul ul { - position: relative; - top: 0; - left: 0; - width: 100%; -} - -.secondary-navigation.toggled .main-nav ul ul.toggled-on { - position: relative; - top: 0; - left: auto !important; - right: auto !important; - width: 100%; - pointer-events: auto; - height: auto; - opacity: 1; - display: block; -} - -.secondary-navigation.toggled .main-nav > ul { - display: block; -} - -.secondary-navigation.toggled .main-nav .sf-menu > li { - float: none; - clear: both; - display: block !important; - text-align: left !important; -} - -.secondary-navigation.toggled .main-nav .sf-menu > li.hide-on-mobile { - display: none !important; -} - -.secondary-navigation.toggled .dropdown-menu-toggle:before { - content: "\f107" !important; -} - -.secondary-navigation.toggled .sfHover > a .dropdown-menu-toggle:before { - content: "\f106" !important; -} - -.secondary-navigation.toggled .menu-item-has-children .dropdown-menu-toggle { - float: right; -} - -.secondary-navigation.toggled .sf-menu > li.menu-item-float-right { - float: none !important; - display: inline-block; -} - -.dropdown-hover .secondary-navigation.toggled ul li:hover > ul, -.dropdown-hover .secondary-navigation.toggled ul li.sfHover > ul { - transition-delay: 0s; -} - -.rtl .secondary-navigation.toggled .main-nav .sf-menu > li { - text-align: right !important; -} - -@media (max-width: 768px) { - .secondary-nav-float-left .inside-header .secondary-navigation { - float: none; - } - .secondary-navigation .menu-toggle { - display: block; - } - .secondary-navigation ul { - display: none; - } - .secondary-nav-aligned-left .secondary-navigation .top-bar { - position: absolute; - right: 0; - } - .secondary-nav-aligned-left .secondary-navigation .top-bar + .menu-toggle { - text-align: left; - } - .secondary-nav-aligned-right .secondary-navigation .top-bar { - position: absolute; - left: 0; - } - .secondary-nav-aligned-right .secondary-navigation .top-bar + .menu-toggle { - text-align: right; - } - .secondary-nav-aligned-center .secondary-navigation .top-bar + .menu-toggle + div { - display: block; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style-mobile.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style-mobile.min.css deleted file mode 100644 index f1ded0a3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style-mobile.min.css +++ /dev/null @@ -1 +0,0 @@ -.secondary-navigation.toggled ul ul{transition:0s;visibility:hidden}.secondary-navigation.toggled ul ul.toggled-on{visibility:visible}.secondary-navigation.toggled .main-nav ul ul{position:relative;top:0;left:0;width:100%}.secondary-navigation.toggled .main-nav ul ul.toggled-on{position:relative;top:0;left:auto!important;right:auto!important;width:100%;pointer-events:auto;height:auto;opacity:1;display:block}.secondary-navigation.toggled .main-nav>ul{display:block}.secondary-navigation.toggled .main-nav .sf-menu>li{float:none;clear:both;display:block!important;text-align:left!important}.secondary-navigation.toggled .main-nav .sf-menu>li.hide-on-mobile{display:none!important}.secondary-navigation.toggled .dropdown-menu-toggle:before{content:"\f107"!important}.secondary-navigation.toggled .sfHover>a .dropdown-menu-toggle:before{content:"\f106"!important}.secondary-navigation.toggled .menu-item-has-children .dropdown-menu-toggle{float:right}.secondary-navigation.toggled .sf-menu>li.menu-item-float-right{float:none!important;display:inline-block}.dropdown-hover .secondary-navigation.toggled ul li.sfHover>ul,.dropdown-hover .secondary-navigation.toggled ul li:hover>ul{transition-delay:0s}.rtl .secondary-navigation.toggled .main-nav .sf-menu>li{text-align:right!important}@media (max-width:768px){.secondary-nav-float-left .inside-header .secondary-navigation{float:none}.secondary-navigation .menu-toggle{display:block}.secondary-navigation ul{display:none}.secondary-nav-aligned-left .secondary-navigation .top-bar{position:absolute;right:0}.secondary-nav-aligned-left .secondary-navigation .top-bar+.menu-toggle{text-align:left}.secondary-nav-aligned-right .secondary-navigation .top-bar{position:absolute;left:0}.secondary-nav-aligned-right .secondary-navigation .top-bar+.menu-toggle{text-align:right}.secondary-nav-aligned-center .secondary-navigation .top-bar+.menu-toggle+div{display:block}} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style.css deleted file mode 100644 index e24c07f1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style.css +++ /dev/null @@ -1,337 +0,0 @@ -.secondary-navigation { - clear: both; - z-index: 99; - padding: 0; -} - -.secondary-navigation ul { - list-style: none; - margin: 0; - padding-left: 0; -} - -.secondary-navigation li { - float: left; - position: relative; -} - -.secondary-navigation a { - display: block; - text-decoration: none; -} - -.secondary-navigation ul ul { - display: block; - box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1); - float: left; - position: absolute; - left: -99999px; - opacity: 0; - z-index: 99999; - width: 200px; - text-align: left; - top: auto; - transition: opacity 80ms linear; - transition-delay: 0s; - pointer-events: none; - height: 0; - overflow: hidden; -} - -.secondary-navigation ul ul li { - width: 100%; -} - -.secondary-navigation ul ul li a { - line-height: normal; - font-size: 90%; -} - -.secondary-navigation.sub-menu-left .sub-menu { - right: 0; -} - -.secondary-navigation .main-nav ul ul li a { - line-height: normal; - font-size: 12px; - padding-left: 20px; - padding-right: 20px; - padding-top: 10px; - padding-bottom: 10px; -} - -.secondary-navigation .main-nav ul li.menu-item-has-children > a { - padding-right: 0; - position: relative; -} - -.secondary-navigation .main-nav ul li a { - font-family: inherit; - font-weight: normal; - text-transform: none; - font-size: 13px; - padding-left: 20px; - padding-right: 20px; - line-height: 40px; -} - -.secondary-navigation .menu-toggle { - font-family: inherit; - font-weight: normal; - text-transform: none; - font-size: 13px; - padding-left: 20px; - padding-right: 20px; - line-height: 40px; - margin: 0; -} - -.secondary-navigation .menu-item-has-children .dropdown-menu-toggle { - padding-right: 20px; -} - -.secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle { - padding-top: 10px; - padding-bottom: 10px; - margin-top: -10px; -} - -.dropdown-hover .secondary-navigation:not(.toggled) ul li:hover > ul, -.dropdown-hover .secondary-navigation:not(.toggled) ul li.sfHover > ul { - left: auto; - opacity: 1; - transition-delay: 150ms; - pointer-events: auto; - height: auto; - overflow: visible; -} - -.dropdown-hover .secondary-navigation:not(.toggled) ul ul li:hover > ul, -.dropdown-hover .secondary-navigation:not(.toggled) ul ul li.sfHover > ul { - left: 100%; - top: 0; -} - -.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li:hover > ul, -.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li.sfHover > ul { - right: 100%; - top: 0; - left: auto; -} - -.secondary-nav-float-right .secondary-navigation { - float: right; -} - -.secondary-nav-float-right .secondary-navigation .main-nav ul ul li a { - line-height: normal; -} - -.secondary-nav-float-right .secondary-navigation ul ul ul { - top: 0; -} - -.secondary-nav-float-left .inside-header .secondary-navigation { - float: left; - clear: left; -} - -.secondary-nav-float-left .inside-header:after { - clear: both; - content: ''; - display: table; -} - -.secondary-nav-float-left:not(.nav-float-right) .inside-header .site-branding, -.secondary-nav-float-left:not(.nav-float-right) .inside-header .site-logo { - float: right; - clear: right; -} - -.secondary-nav-float-left.nav-float-right .inside-header .site-branding, -.secondary-nav-float-left.nav-float-right .inside-header .site-logo { - float: none; - clear: none; -} - -.secondary-nav-float-left.nav-float-right .site-header { - text-align: center; -} - -.secondary-nav-float-right.nav-float-left .inside-header .site-branding, -.secondary-nav-float-right.nav-float-left .inside-header .site-logo { - float: none; - clear: none; -} - -.secondary-nav-float-right.nav-float-left .site-header { - text-align: center; -} - -.widget-area .secondary-navigation li { - display: block; - float: none; - margin: 0; - padding: 0; - width: 100%; -} - -.widget-area .secondary-navigation ul ul { - left: 100%; - top: 0; - width: 220px; -} - -.both-right .widget-area .secondary-navigation ul ul, -.right-sidebar .widget-area .secondary-navigation ul ul, -.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul { - left: auto; - right: 100%; -} - -.secondary-nav-aligned-right.secondary-nav-below-header .secondary-navigation .sf-menu > li, -.secondary-nav-aligned-right.secondary-nav-above-header .secondary-navigation .sf-menu > li, -.secondary-nav-aligned-center.secondary-nav-below-header .secondary-navigation .sf-menu > li, -.secondary-nav-aligned-center.secondary-nav-above-header .secondary-navigation .sf-menu > li { - float: none; - display: inline-block; -} - -.secondary-nav-aligned-right .secondary-navigation ul.secondary-menu, -.secondary-nav-aligned-center .secondary-navigation ul.secondary-menu { - font-size: 0px; -} - -.secondary-nav-aligned-left.secondary-nav-below-header .secondary-navigation, -.secondary-nav-aligned-left.secondary-nav-above-header .secondary-navigation { - text-align: left; -} - -.secondary-nav-aligned-left.secondary-nav-below-header .secondary-navigation:after, -.secondary-nav-aligned-left.secondary-nav-above-header .secondary-navigation:after { - clear: both; - content: ''; - display: table; -} - -.secondary-nav-aligned-center.secondary-nav-below-header .secondary-navigation, -.secondary-nav-aligned-center.secondary-nav-above-header .secondary-navigation { - text-align: center; -} - -.secondary-nav-aligned-right.secondary-nav-below-header .secondary-navigation, -.secondary-nav-aligned-right.secondary-nav-above-header .secondary-navigation { - text-align: right; -} - -.dropdown-click .secondary-navigation ul ul { - visibility: hidden; -} - -.dropdown-click .secondary-navigation ul.toggled-on, -.dropdown-click .secondary-navigation ul li.sfHover > ul.toggled-on { - left: auto; - opacity: 1; - visibility: visible; - pointer-events: auto; - height: auto; - overflow: visible; -} - -.dropdown-click .secondary-navigation ul ul ul.toggled-on { - left: 0; - top: auto; - position: relative; -} - -.dropdown-click .widget-area .secondary-navigation ul ul { - top: auto; - position: absolute; - float: none; - width: 100%; - left: -99999px; -} - -.dropdown-click .widget-area .secondary-navigation ul ul.toggled-on { - position: relative; - left: 0; - right: 0; -} - -.dropdown-click.both-right .widget-area .secondary-navigation ul ul, -.dropdown-click.right-sidebar .widget-area .secondary-navigation ul ul, -.dropdown-click.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul { - right: 0; -} - -.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li.sfHover > ul { - top: 0; - left: 100%; - width: 220px; -} - -.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul, -.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul, -.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li:hover ul, -.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li.sfHover ul { - right: 100%; - left: auto; -} - -.rtl .secondary-navigation ul ul { - float: right; - left: auto; - right: 0; - text-align: right; -} - -.rtl .secondary-navigation ul ul ul { - left: auto; - right: 100%; -} - -.rtl .secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle { - transform: rotate(180deg); -} - -/* Top bar */ -.secondary-navigation .top-bar { - background: transparent; -} - -.secondary-navigation .inside-top-bar { - padding: 0; -} - -.secondary-navigation .top-bar a { - display: inline; -} - -.secondary-nav-aligned-right .secondary-navigation .top-bar { - float: left; -} - -.secondary-nav-aligned-right .secondary-navigation .top-bar .inside-top-bar .widget { - margin: 0 10px; -} - -.secondary-nav-aligned-left .secondary-navigation .top-bar { - float: right; -} - -.secondary-nav-aligned-left .secondary-navigation .top-bar .inside-top-bar .widget { - margin-left: 10px; -} - -.secondary-nav-aligned-center .secondary-navigation .top-bar, -.secondary-nav-aligned-center .secondary-navigation .top-bar + .menu-toggle + div { - display: inline-block; - vertical-align: middle; -} - -.secondary-nav-aligned-center .secondary-navigation .top-bar .widget:not(:first-child) { - margin-left: 10px; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style.min.css deleted file mode 100644 index 88215e4e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/css/style.min.css +++ /dev/null @@ -1 +0,0 @@ -.secondary-navigation{clear:both;z-index:99;padding:0}.secondary-navigation ul{list-style:none;margin:0;padding-left:0}.secondary-navigation li{float:left;position:relative}.secondary-navigation a{display:block;text-decoration:none}.secondary-navigation ul ul{display:block;box-shadow:0 2px 2px rgba(0,0,0,.1);float:left;position:absolute;left:-99999px;opacity:0;z-index:99999;width:200px;text-align:left;top:auto;transition:opacity 80ms linear;transition-delay:0s;pointer-events:none;height:0;overflow:hidden}.secondary-navigation ul ul li{width:100%}.secondary-navigation ul ul li a{line-height:normal;font-size:90%}.secondary-navigation.sub-menu-left .sub-menu{right:0}.secondary-navigation .main-nav ul ul li a{line-height:normal;font-size:12px;padding-left:20px;padding-right:20px;padding-top:10px;padding-bottom:10px}.secondary-navigation .main-nav ul li.menu-item-has-children>a{padding-right:0;position:relative}.secondary-navigation .main-nav ul li a{font-family:inherit;font-weight:400;text-transform:none;font-size:13px;padding-left:20px;padding-right:20px;line-height:40px}.secondary-navigation .menu-toggle{font-family:inherit;font-weight:400;text-transform:none;font-size:13px;padding-left:20px;padding-right:20px;line-height:40px;margin:0}.secondary-navigation .menu-item-has-children .dropdown-menu-toggle{padding-right:20px}.secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle{padding-top:10px;padding-bottom:10px;margin-top:-10px}.dropdown-hover .secondary-navigation:not(.toggled) ul li.sfHover>ul,.dropdown-hover .secondary-navigation:not(.toggled) ul li:hover>ul{left:auto;opacity:1;transition-delay:150ms;pointer-events:auto;height:auto;overflow:visible}.dropdown-hover .secondary-navigation:not(.toggled) ul ul li.sfHover>ul,.dropdown-hover .secondary-navigation:not(.toggled) ul ul li:hover>ul{left:100%;top:0}.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li.sfHover>ul,.dropdown-hover .secondary-navigation.sub-menu-left:not(.toggled) ul ul li:hover>ul{right:100%;top:0;left:auto}.secondary-nav-float-right .secondary-navigation{float:right}.secondary-nav-float-right .secondary-navigation .main-nav ul ul li a{line-height:normal}.secondary-nav-float-right .secondary-navigation ul ul ul{top:0}.secondary-nav-float-left .inside-header .secondary-navigation{float:left;clear:left}.secondary-nav-float-left .inside-header:after{clear:both;content:'';display:table}.secondary-nav-float-left:not(.nav-float-right) .inside-header .site-branding,.secondary-nav-float-left:not(.nav-float-right) .inside-header .site-logo{float:right;clear:right}.secondary-nav-float-left.nav-float-right .inside-header .site-branding,.secondary-nav-float-left.nav-float-right .inside-header .site-logo{float:none;clear:none}.secondary-nav-float-left.nav-float-right .site-header{text-align:center}.secondary-nav-float-right.nav-float-left .inside-header .site-branding,.secondary-nav-float-right.nav-float-left .inside-header .site-logo{float:none;clear:none}.secondary-nav-float-right.nav-float-left .site-header{text-align:center}.widget-area .secondary-navigation li{display:block;float:none;margin:0;padding:0;width:100%}.widget-area .secondary-navigation ul ul{left:100%;top:0;width:220px}.both-right .widget-area .secondary-navigation ul ul,.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul,.right-sidebar .widget-area .secondary-navigation ul ul{left:auto;right:100%}.secondary-nav-aligned-center.secondary-nav-above-header .secondary-navigation .sf-menu>li,.secondary-nav-aligned-center.secondary-nav-below-header .secondary-navigation .sf-menu>li,.secondary-nav-aligned-right.secondary-nav-above-header .secondary-navigation .sf-menu>li,.secondary-nav-aligned-right.secondary-nav-below-header .secondary-navigation .sf-menu>li{float:none;display:inline-block}.secondary-nav-aligned-center .secondary-navigation ul.secondary-menu,.secondary-nav-aligned-right .secondary-navigation ul.secondary-menu{font-size:0}.secondary-nav-aligned-left.secondary-nav-above-header .secondary-navigation,.secondary-nav-aligned-left.secondary-nav-below-header .secondary-navigation{text-align:left}.secondary-nav-aligned-left.secondary-nav-above-header .secondary-navigation:after,.secondary-nav-aligned-left.secondary-nav-below-header .secondary-navigation:after{clear:both;content:'';display:table}.secondary-nav-aligned-center.secondary-nav-above-header .secondary-navigation,.secondary-nav-aligned-center.secondary-nav-below-header .secondary-navigation{text-align:center}.secondary-nav-aligned-right.secondary-nav-above-header .secondary-navigation,.secondary-nav-aligned-right.secondary-nav-below-header .secondary-navigation{text-align:right}.dropdown-click .secondary-navigation ul ul{visibility:hidden}.dropdown-click .secondary-navigation ul li.sfHover>ul.toggled-on,.dropdown-click .secondary-navigation ul.toggled-on{left:auto;opacity:1;visibility:visible;pointer-events:auto;height:auto;overflow:visible}.dropdown-click .secondary-navigation ul ul ul.toggled-on{left:0;top:auto;position:relative}.dropdown-click .widget-area .secondary-navigation ul ul{top:auto;position:absolute;float:none;width:100%;left:-99999px}.dropdown-click .widget-area .secondary-navigation ul ul.toggled-on{position:relative;left:0;right:0}.dropdown-click.both-right .widget-area .secondary-navigation ul ul,.dropdown-click.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation ul ul,.dropdown-click.right-sidebar .widget-area .secondary-navigation ul ul{right:0}.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li.sfHover>ul,.dropdown-hover .widget-area .secondary-navigation:not(.toggled) ul li:hover ul{top:0;left:100%;width:220px}.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul,.dropdown-hover.both-right .widget-area .secondary-navigation:not(.toggled) ul li:hover ul,.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li.sfHover ul,.dropdown-hover.both-sidebars .widget-area .inside-right-sidebar .secondary-navigation:not(.toggled) ul li:hover ul,.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li.sfHover ul,.dropdown-hover.right-sidebar .widget-area .secondary-navigation:not(.toggled) ul li:hover ul{right:100%;left:auto}.rtl .secondary-navigation ul ul{float:right;left:auto;right:0;text-align:right}.rtl .secondary-navigation ul ul ul{left:auto;right:100%}.rtl .secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle{transform:rotate(180deg)}.secondary-navigation .top-bar{background:0 0}.secondary-navigation .inside-top-bar{padding:0}.secondary-navigation .top-bar a{display:inline}.secondary-nav-aligned-right .secondary-navigation .top-bar{float:left}.secondary-nav-aligned-right .secondary-navigation .top-bar .inside-top-bar .widget{margin:0 10px}.secondary-nav-aligned-left .secondary-navigation .top-bar{float:right}.secondary-nav-aligned-left .secondary-navigation .top-bar .inside-top-bar .widget{margin-left:10px}.secondary-nav-aligned-center .secondary-navigation .top-bar,.secondary-nav-aligned-center .secondary-navigation .top-bar+.menu-toggle+div{display:inline-block;vertical-align:middle}.secondary-nav-aligned-center .secondary-navigation .top-bar .widget:not(:first-child){margin-left:10px} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/functions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/functions.php deleted file mode 100644 index f8a2a29e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/functions/functions.php +++ /dev/null @@ -1,1379 +0,0 @@ - __( 'Secondary Menu', 'gp-premium' ), - ) - ); - } -} - -if ( ! function_exists( 'generate_secondary_nav_enqueue_scripts' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_secondary_nav_enqueue_scripts', 100 ); - /** - * Add our necessary scripts. - * - * @since 0.1 - */ - function generate_secondary_nav_enqueue_scripts() { - // Bail if no Secondary menu is set. - if ( ! has_nav_menu( 'secondary' ) ) { - return; - } - - $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min'; - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - wp_enqueue_style( 'generate-secondary-nav', plugin_dir_url( __FILE__ ) . "css/main{$suffix}.css", array(), GENERATE_SECONDARY_NAV_VERSION ); - wp_enqueue_style( 'generate-secondary-nav-mobile', plugin_dir_url( __FILE__ ) . "css/main-mobile{$suffix}.css", array(), GENERATE_SECONDARY_NAV_VERSION, 'all' ); - } else { - wp_enqueue_style( 'generate-secondary-nav', plugin_dir_url( __FILE__ ) . "css/style{$suffix}.css", array(), GENERATE_SECONDARY_NAV_VERSION ); - wp_enqueue_style( 'generate-secondary-nav-mobile', plugin_dir_url( __FILE__ ) . "css/style-mobile{$suffix}.css", array(), GENERATE_SECONDARY_NAV_VERSION, 'all' ); - } - - if ( ! defined( 'GENERATE_DISABLE_MOBILE' ) ) { - wp_add_inline_script( - 'generate-navigation', - "jQuery( document ).ready( function($) { - $( '.secondary-navigation .menu-toggle' ).on( 'click', function( e ) { - e.preventDefault(); - $( this ).closest( '.secondary-navigation' ).toggleClass( 'toggled' ); - $( this ).closest( '.secondary-navigation' ).attr( 'aria-expanded', $( this ).closest( '.secondary-navigation' ).attr( 'aria-expanded' ) === 'true' ? 'false' : 'true' ); - $( this ).toggleClass( 'toggled' ); - $( this ).children( 'i' ).toggleClass( 'fa-bars' ).toggleClass( 'fa-close' ); - $( this ).attr( 'aria-expanded', $( this ).attr( 'aria-expanded' ) === 'false' ? 'true' : 'false' ); - }); - });" - ); - } - } -} - -if ( ! function_exists( 'generate_secondary_nav_enqueue_customizer_scripts' ) ) { - add_action( 'customize_preview_init', 'generate_secondary_nav_enqueue_customizer_scripts' ); - /** - * Add our Customizer preview JS. - * - * @since 0.1 - */ - function generate_secondary_nav_enqueue_customizer_scripts() { - wp_enqueue_script( 'generate-secondary-nav-customizer', plugin_dir_url( __FILE__ ) . 'js/customizer.js', array( 'jquery', 'customize-preview' ), GENERATE_SECONDARY_NAV_VERSION, true ); - - wp_localize_script( - 'generate-secondary-nav-customizer', - 'generateSecondaryNav', - array( - 'isFlex' => function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox(), - ) - ); - } -} - -if ( ! function_exists( 'generate_secondary_nav_get_defaults' ) ) { - /** - * Set default options. - * - * @since 0.1 - * @param bool $filter Whether to filter the defaults or not. - */ - function generate_secondary_nav_get_defaults( $filter = true ) { - $generate_defaults = array( - 'secondary_nav_mobile_label' => 'Menu', - 'secondary_nav_layout_setting' => 'secondary-fluid-nav', - 'secondary_nav_inner_width' => 'contained', - 'secondary_nav_position_setting' => 'secondary-nav-above-header', - 'secondary_nav_alignment' => 'right', - 'secondary_nav_dropdown_direction' => 'right', - 'navigation_background_color' => '#636363', - 'navigation_text_color' => '#ffffff', - 'navigation_background_hover_color' => '#303030', - 'navigation_text_hover_color' => '#ffffff', - 'navigation_background_current_color' => '#ffffff', - 'navigation_text_current_color' => '#222222', - 'subnavigation_background_color' => '#303030', - 'subnavigation_text_color' => '#ffffff', - 'subnavigation_background_hover_color' => '#474747', - 'subnavigation_text_hover_color' => '#ffffff', - 'subnavigation_background_current_color' => '#474747', - 'subnavigation_text_current_color' => '#ffffff', - 'secondary_menu_item' => '20', - 'secondary_menu_item_height' => '40', - 'secondary_sub_menu_item_height' => '10', - 'font_secondary_navigation' => 'inherit', - 'font_secondary_navigation_variants' => '', - 'font_secondary_navigation_category' => '', - 'secondary_navigation_font_weight' => 'normal', - 'secondary_navigation_font_transform' => 'none', - 'secondary_navigation_font_size' => '13', - 'nav_image' => '', - 'nav_repeat' => '', - 'nav_item_image' => '', - 'nav_item_repeat' => '', - 'nav_item_hover_image' => '', - 'nav_item_hover_repeat' => '', - 'nav_item_current_image' => '', - 'nav_item_current_repeat' => '', - 'sub_nav_image' => '', - 'sub_nav_repeat' => '', - 'sub_nav_item_image' => '', - 'sub_nav_item_repeat' => '', - 'sub_nav_item_hover_image' => '', - 'sub_nav_item_hover_repeat' => '', - 'sub_nav_item_current_image' => '', - 'sub_nav_item_current_repeat' => '', - 'merge_top_bar' => false, - ); - - if ( $filter ) { - return apply_filters( 'generate_secondary_nav_option_defaults', $generate_defaults ); - } - - return $generate_defaults; - } -} - -if ( ! function_exists( 'generate_secondary_nav_customize_register' ) ) { - add_action( 'customize_register', 'generate_secondary_nav_customize_register', 100 ); - /** - * Register our options. - * - * @since 0.1 - * @param object $wp_customize The Customizer object. - */ - function generate_secondary_nav_customize_register( $wp_customize ) { - $defaults = generate_secondary_nav_get_defaults(); - - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - if ( method_exists( $wp_customize, 'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Use the Layout panel in the free theme if it exists. - if ( $wp_customize->get_panel( 'generate_layout_panel' ) ) { - $layout_panel = 'generate_layout_panel'; - } else { - $layout_panel = 'secondary_navigation_panel'; - } - - // Add our secondary navigation panel. - // This shouldn't be used anymore if the theme is up to date. - if ( class_exists( 'WP_Customize_Panel' ) ) { - $wp_customize->add_panel( - 'secondary_navigation_panel', - array( - 'priority' => 100, - 'capability' => 'edit_theme_options', - 'theme_supports' => '', - 'title' => __( 'Secondary Navigation', 'gp-premium' ), - 'description' => '', - ) - ); - } - - $wp_customize->add_section( - 'secondary_nav_section', - array( - 'title' => __( 'Secondary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 31, - 'panel' => $layout_panel, - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_secondary_navigation_layout_shortcuts', - array( - 'section' => 'secondary_nav_section', - 'element' => __( 'Secondary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'secondary_navigation_color_section', - 'typography' => 'secondary_font_section', - 'backgrounds' => 'secondary_bg_images_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_nav_mobile_label]', - array( - 'default' => $defaults['secondary_nav_mobile_label'], - 'type' => 'option', - 'sanitize_callback' => 'wp_kses_post', - ) - ); - - $wp_customize->add_control( - 'secondary_nav_mobile_label_control', - array( - 'label' => __( 'Mobile Menu Label', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'settings' => 'generate_secondary_nav_settings[secondary_nav_mobile_label]', - 'priority' => 10, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_nav_layout_setting]', - array( - 'default' => $defaults['secondary_nav_layout_setting'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[secondary_nav_layout_setting]', - array( - 'type' => 'select', - 'label' => __( 'Navigation Width', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'choices' => array( - 'secondary-fluid-nav' => _x( 'Full', 'Width', 'gp-premium' ), - 'secondary-contained-nav' => _x( 'Contained', 'Width', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[secondary_nav_layout_setting]', - 'priority' => 15, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_nav_inner_width]', - array( - 'default' => $defaults['secondary_nav_inner_width'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[secondary_nav_inner_width]', - array( - 'type' => 'select', - 'label' => __( 'Inner Navigation Width', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'choices' => array( - 'full-width' => _x( 'Full', 'Width', 'gp-premium' ), - 'contained' => _x( 'Contained', 'Width', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[secondary_nav_inner_width]', - 'priority' => 15, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_nav_alignment]', - array( - 'default' => $defaults['secondary_nav_alignment'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[secondary_nav_alignment]', - array( - 'type' => 'select', - 'label' => __( 'Navigation Alignment', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'choices' => array( - 'left' => __( 'Left', 'gp-premium' ), - 'center' => __( 'Center', 'gp-premium' ), - 'right' => __( 'Right', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[secondary_nav_alignment]', - 'priority' => 20, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_nav_position_setting]', - array( - 'default' => $defaults['secondary_nav_position_setting'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[secondary_nav_position_setting]', - array( - 'type' => 'select', - 'label' => __( 'Navigation Location', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'choices' => array( - 'secondary-nav-below-header' => __( 'Below Header', 'gp-premium' ), - 'secondary-nav-above-header' => __( 'Above Header', 'gp-premium' ), - 'secondary-nav-float-right' => __( 'Float Right', 'gp-premium' ), - 'secondary-nav-float-left' => __( 'Float Left', 'gp-premium' ), - 'secondary-nav-left-sidebar' => __( 'Left Sidebar', 'gp-premium' ), - 'secondary-nav-right-sidebar' => __( 'Right Sidebar', 'gp-premium' ), - '' => __( 'No Navigation', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[secondary_nav_position_setting]', - 'priority' => 30, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_nav_dropdown_direction]', - array( - 'default' => $defaults['secondary_nav_dropdown_direction'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[secondary_nav_dropdown_direction]', - array( - 'type' => 'select', - 'label' => __( 'Dropdown Direction', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'choices' => array( - 'right' => __( 'Right', 'gp-premium' ), - 'left' => __( 'Left', 'gp-premium' ), - ), - 'settings' => 'generate_secondary_nav_settings[secondary_nav_dropdown_direction]', - 'priority' => 35, - ) - ); - - $wp_customize->add_setting( - 'generate_secondary_nav_settings[merge_top_bar]', - array( - 'default' => $defaults['merge_top_bar'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox', - ) - ); - - $wp_customize->add_control( - 'generate_secondary_nav_settings[merge_top_bar]', - array( - 'type' => 'checkbox', - 'label' => __( 'Merge with Secondary Navigation', 'gp-premium' ), - 'section' => 'generate_top_bar', - 'settings' => 'generate_secondary_nav_settings[merge_top_bar]', - 'priority' => 100, - 'active_callback' => 'generate_secondary_nav_show_merge_top_bar', - ) - ); - } -} - -if ( ! function_exists( 'generate_display_secondary_google_fonts' ) ) { - add_filter( 'generate_typography_google_fonts', 'generate_display_secondary_google_fonts', 50 ); - /** - * Add Google Fonts to wp_head if needed. - * - * @since 0.1 - * @param array $google_fonts Existing fonts. - */ - function generate_display_secondary_google_fonts( $google_fonts ) { - if ( ! has_nav_menu( 'secondary' ) ) { - return $google_fonts; - } - - $generate_secondary_nav_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( function_exists( 'generate_typography_default_fonts' ) ) { - $not_google = str_replace( ' ', '+', generate_typography_default_fonts() ); - } else { - $not_google = array( - 'inherit', - 'Arial,+Helvetica,+sans-serif', - 'Century+Gothic', - 'Comic+Sans+MS', - 'Courier+New', - 'Georgia,+Times+New+Roman,+Times,+serif', - 'Helvetica', - 'Impact', - 'Lucida+Console', - 'Lucida+Sans+Unicode', - 'Palatino+Linotype', - 'Tahoma,+Geneva,+sans-serif', - 'Trebuchet+MS,+Helvetica,+sans-serif', - 'Verdana,+Geneva,+sans-serif', - ); - } - - $secondary_google_fonts = array(); - - if ( function_exists( 'generate_get_google_font_variants' ) ) { - - // If our value is still using the old format, fix it. - if ( strpos( $generate_secondary_nav_settings['font_secondary_navigation'], ':' ) !== false ) { - $generate_secondary_nav_settings['font_secondary_navigation'] = current( explode( ':', $generate_secondary_nav_settings['font_secondary_navigation'] ) ); - } - - // Grab the variants using the plain name. - $variants = generate_get_google_font_variants( $generate_secondary_nav_settings['font_secondary_navigation'], 'font_secondary_navigation', generate_secondary_nav_get_defaults() ); - - } else { - $variants = ''; - } - - // Replace the spaces in the names with a plus. - $value = str_replace( ' ', '+', $generate_secondary_nav_settings['font_secondary_navigation'] ); - - // If we have variants, add them to our value. - $value = ! empty( $variants ) ? $value . ':' . $variants : $value; - - // Add our value to the array. - $secondary_google_fonts[] = $value; - - // Ignore any non-Google fonts. - $secondary_google_fonts = array_diff( $secondary_google_fonts, $not_google ); - - // Separate each different font with a bar. - $secondary_google_fonts = implode( '|', $secondary_google_fonts ); - - if ( ! empty( $secondary_google_fonts ) ) { - $print_secondary_fonts = '|' . $secondary_google_fonts; - } else { - $print_secondary_fonts = ''; - } - - // Remove any duplicates. - $return = $google_fonts . $print_secondary_fonts; - $return = implode( '|', array_unique( explode( '|', $return ) ) ); - return $return; - - } -} - -if ( ! function_exists( 'generate_add_secondary_navigation_after_header' ) ) { - add_action( 'generate_after_header', 'generate_add_secondary_navigation_after_header', 7 ); - /** - * Add the navigation after the header. - * - * @since 0.1 - */ - function generate_add_secondary_navigation_after_header() { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( 'secondary-nav-below-header' === $generate_settings['secondary_nav_position_setting'] ) { - generate_secondary_navigation_position(); - } - - } -} - -if ( ! function_exists( 'generate_add_secondary_navigation_before_header' ) ) { - add_action( 'generate_before_header', 'generate_add_secondary_navigation_before_header', 7 ); - /** - * Add the navigation before the header. - * - * @since 0.1 - */ - function generate_add_secondary_navigation_before_header() { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( 'secondary-nav-above-header' === $generate_settings['secondary_nav_position_setting'] ) { - generate_secondary_navigation_position(); - } - - } -} - -if ( ! function_exists( 'generate_add_secondary_navigation_float_right' ) ) { - add_action( 'generate_before_header_content', 'generate_add_secondary_navigation_float_right', 7 ); - /** - * Add the navigation inside the header so it can float right. - * - * @since 0.1 - */ - function generate_add_secondary_navigation_float_right() { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - return; - } - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( 'secondary-nav-float-right' === $generate_settings['secondary_nav_position_setting'] || 'secondary-nav-float-left' === $generate_settings['secondary_nav_position_setting'] ) { - generate_secondary_navigation_position(); - } - - } -} - -add_action( 'generate_after_header_content', 'generate_do_secondary_navigation_float_right', 7 ); -/** - * Add the navigation inside the header so it can float right. - * - * @since 1.11.0 - */ -function generate_do_secondary_navigation_float_right() { - if ( ! function_exists( 'generate_is_using_flexbox' ) ) { - return; - } - - if ( ! generate_is_using_flexbox() ) { - return; - } - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( 'secondary-nav-float-right' === $generate_settings['secondary_nav_position_setting'] || 'secondary-nav-float-left' === $generate_settings['secondary_nav_position_setting'] ) { - generate_secondary_navigation_position(); - } - -} - -add_action( 'generate_before_navigation', 'generate_do_multi_navigation_wrapper_open', 11 ); -/** - * Open our wrapper that puts both navigations inside one element. - * - * @since 1.11.0 - */ -function generate_do_multi_navigation_wrapper_open() { - if ( ! function_exists( 'generate_is_using_flexbox' ) ) { - return; - } - - if ( ! generate_is_using_flexbox() ) { - return; - } - - if ( ! function_exists( 'generate_get_option' ) ) { - return; - } - - if ( ! has_nav_menu( 'secondary' ) ) { - return; - } - - if ( function_exists( 'generate_menu_plus_get_defaults' ) ) { - $menu_settings = wp_parse_args( - get_option( 'generate_menu_plus_settings', array() ), - generate_menu_plus_get_defaults() - ); - - if ( $menu_settings['navigation_as_header'] ) { - return; - } - } - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( - ( 'secondary-nav-float-right' === $generate_settings['secondary_nav_position_setting'] && 'nav-float-right' === generate_get_option( 'nav_position_setting' ) ) || - ( 'secondary-nav-float-left' === $generate_settings['secondary_nav_position_setting'] && 'nav-float-left' === generate_get_option( 'nav_position_setting' ) ) - ) { - echo '
            '; - } -} - -add_action( 'generate_after_secondary_navigation', 'generate_do_multi_navigation_wrapper_close', 7 ); -/** - * Close our wrapper that puts both navigations inside one element. - * - * @since 1.11.0 - */ -function generate_do_multi_navigation_wrapper_close() { - if ( ! function_exists( 'generate_is_using_flexbox' ) ) { - return; - } - - if ( ! generate_is_using_flexbox() ) { - return; - } - - if ( ! function_exists( 'generate_get_option' ) ) { - return; - } - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( - ( 'secondary-nav-float-right' === $generate_settings['secondary_nav_position_setting'] && 'nav-float-right' === generate_get_option( 'nav_position_setting' ) ) || - ( 'secondary-nav-float-left' === $generate_settings['secondary_nav_position_setting'] && 'nav-float-left' === generate_get_option( 'nav_position_setting' ) ) - ) { - echo '
            '; - } -} - -if ( ! function_exists( 'generate_add_secondary_navigation_before_right_sidebar' ) ) { - add_action( 'generate_before_right_sidebar_content', 'generate_add_secondary_navigation_before_right_sidebar', 7 ); - /** - * Add the navigation into the right sidebar. - * - * @since 0.1 - */ - function generate_add_secondary_navigation_before_right_sidebar() { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( 'secondary-nav-right-sidebar' === $generate_settings['secondary_nav_position_setting'] ) { - echo '
            '; - generate_secondary_navigation_position(); - echo '
            '; - } - - } -} - -if ( ! function_exists( 'generate_add_secondary_navigation_before_left_sidebar' ) ) { - add_action( 'generate_before_left_sidebar_content', 'generate_add_secondary_navigation_before_left_sidebar', 7 ); - /** - * Add the navigation into the left sidebar. - * - * @since 0.1 - */ - function generate_add_secondary_navigation_before_left_sidebar() { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( 'secondary-nav-left-sidebar' === $generate_settings['secondary_nav_position_setting'] ) { - echo '
            '; - generate_secondary_navigation_position(); - echo '
            '; - } - - } -} - -if ( ! function_exists( 'generate_secondary_navigation_position' ) ) { - /** - * Build our secondary navigation. - * Would like to change this function name. - * - * @since 0.1 - */ - function generate_secondary_navigation_position() { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - if ( has_nav_menu( 'secondary' ) ) : - do_action( 'generate_before_secondary_navigation' ); - - $classes = generate_get_secondary_navigation_class(); - $classes = implode( ' ', $classes ); - $attributes = [ - 'id' => 'secondary-navigation', - 'aria-label' => esc_attr__( 'Secondary', 'gp-premium' ), - 'class' => $classes, - ]; - $microdata = ''; - - if ( function_exists( 'generate_get_schema_type' ) && 'microdata' === generate_get_schema_type() ) { - $attributes['itemtype'] = 'https://schema.org/SiteNavigationElement'; - $attributes['itemscope'] = true; - $microdata = ' itemtype="https://schema.org/SiteNavigationElement" itemscope="itemscope"'; - } - - $secondary_nav_attributes = sprintf( - 'id="secondary-navigation" aria-label="%1$s" class="%2$s"%3$s"', - esc_attr__( 'Secondary', 'gp-premium' ), - esc_attr( $classes ), - $microdata - ); - - if ( function_exists( 'generate_get_attr' ) ) { - $secondary_nav_attributes = generate_get_attr( - 'secondary-navigation', - $attributes - ); - } - ?> - - - - '; - do_action( 'generate_secondary_menu_bar_items' ); - echo ''; - } - } -} - -if ( ! function_exists( 'generate_secondary_nav_body_classes' ) ) { - add_filter( 'body_class', 'generate_secondary_nav_body_classes' ); - /** - * Adds custom classes to the array of body classes. - * - * @since 0.1 - * @param array $classes Existing body classes. - */ - function generate_secondary_nav_body_classes( $classes ) { - if ( ! has_nav_menu( 'secondary' ) ) { - return $classes; - } - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - $classes[] = ( $generate_settings['secondary_nav_position_setting'] ) ? $generate_settings['secondary_nav_position_setting'] : 'secondary-nav-below-header'; - - if ( 'left' === $generate_settings['secondary_nav_alignment'] ) { - $classes[] = 'secondary-nav-aligned-left'; - } elseif ( 'center' === $generate_settings['secondary_nav_alignment'] ) { - $classes[] = 'secondary-nav-aligned-center'; - } elseif ( 'right' === $generate_settings['secondary_nav_alignment'] ) { - $classes[] = 'secondary-nav-aligned-right'; - } else { - $classes[] = 'secondary-nav-aligned-left'; - } - - return $classes; - } -} - -if ( ! function_exists( 'generate_secondary_menu_classes' ) ) { - add_filter( 'generate_secondary_menu_class', 'generate_secondary_menu_classes' ); - /** - * Adds custom classes to the menu. - * - * @since 0.1 - * @param array $classes Existing classes. - */ - function generate_secondary_menu_classes( $classes ) { - - $classes[] = 'secondary-menu'; - $classes[] = 'sf-menu'; - - return $classes; - - } -} - -if ( ! function_exists( 'generate_secondary_navigation_classes' ) ) { - add_filter( 'generate_secondary_navigation_class', 'generate_secondary_navigation_classes' ); - /** - * Adds custom classes to the navigation. - * - * @since 0.1 - * @param array $classes Existing classes. - */ - function generate_secondary_navigation_classes( $classes ) { - $classes[] = 'secondary-navigation'; - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - $nav_layout = $generate_settings['secondary_nav_layout_setting']; - - if ( 'secondary-contained-nav' === $nav_layout ) { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $navigation_location = $generate_settings['secondary_nav_position_setting']; - - if ( 'secondary-nav-float-right' !== $navigation_location && 'secondary-nav-float-left' !== $navigation_location ) { - $classes[] = 'grid-container'; - } - } else { - $classes[] = 'grid-container'; - $classes[] = 'grid-parent'; - } - } - - if ( 'left' === $generate_settings['secondary_nav_dropdown_direction'] ) { - $layout = $generate_settings['secondary_nav_position_setting']; - - switch ( $layout ) { - case 'secondary-nav-below-header': - case 'secondary-nav-above-header': - case 'secondary-nav-float-right': - case 'secondary-nav-float-left': - $classes[] = 'sub-menu-left'; - break; - } - } - - if ( $generate_settings['merge_top_bar'] && is_active_sidebar( 'top-bar' ) ) { - $classes[] = 'has-top-bar'; - } - - if ( generate_secondary_nav_has_menu_bar_items() ) { - $classes[] = 'has-menu-bar-items'; - } - - return $classes; - - } -} - -if ( ! function_exists( 'generate_inside_secondary_navigation_classes' ) ) { - add_filter( 'generate_inside_secondary_navigation_class', 'generate_inside_secondary_navigation_classes' ); - /** - * Adds custom classes to the inner navigation - * - * @since 1.3.41 - * @param array $classes Existing classes. - */ - function generate_inside_secondary_navigation_classes( $classes ) { - $classes[] = 'inside-navigation'; - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - $inner_nav_width = $generate_settings['secondary_nav_inner_width']; - - if ( 'full-width' !== $inner_nav_width ) { - $classes[] = 'grid-container'; - $classes[] = 'grid-parent'; - } - - return $classes; - - } -} - -if ( ! function_exists( 'generate_secondary_nav_css' ) ) { - /** - * Generate the CSS in the section using the Theme Customizer. - * - * @since 0.1 - */ - function generate_secondary_nav_css() { - - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( function_exists( 'generate_spacing_get_defaults' ) ) { - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - $separator = $spacing_settings['separator']; - } else { - $separator = 20; - } - - // Check if we're using our legacy typography system. - $using_dynamic_typography = function_exists( 'generate_is_using_dynamic_typography' ) && generate_is_using_dynamic_typography(); - $secondary_nav_family = ''; - - if ( ! $using_dynamic_typography ) { - if ( function_exists( 'generate_get_font_family_css' ) ) { - $secondary_nav_family = generate_get_font_family_css( 'font_secondary_navigation', 'generate_secondary_nav_settings', generate_secondary_nav_get_defaults() ); - } else { - $secondary_nav_family = current( explode( ':', $generate_settings['font_secondary_navigation'] ) ); - } - - if ( '""' === $secondary_nav_family ) { - $secondary_nav_family = 'inherit'; - } - } - - // Get our untouched defaults. - $og_defaults = generate_secondary_nav_get_defaults( false ); - - $css = new GeneratePress_Secondary_Nav_CSS(); - - $css->set_selector( '.secondary-navigation' ); - $css->add_property( 'background-color', esc_attr( $generate_settings['navigation_background_color'] ) ); - $css->add_property( 'background-image', ! empty( $generate_settings['nav_image'] ) ? 'url(' . esc_url( $generate_settings['nav_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_repeat'] ) ); - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - if ( function_exists( 'generate_spacing_get_defaults' ) && function_exists( 'generate_get_option' ) && 'text' === generate_get_option( 'container_alignment' ) ) { - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - - $navigation_left_padding = absint( $spacing_settings['header_left'] ) - absint( $generate_settings['secondary_menu_item'] ); - $navigation_right_padding = absint( $spacing_settings['header_right'] ) - absint( $generate_settings['secondary_menu_item'] ); - - $css->set_selector( '.secondary-nav-below-header .secondary-navigation .inside-navigation.grid-container, .secondary-nav-above-header .secondary-navigation .inside-navigation.grid-container' ); - $css->add_property( 'padding', generate_padding_css( 0, $navigation_right_padding, 0, $navigation_left_padding ) ); - } - } - - if ( 'secondary-nav-above-header' === $generate_settings['secondary_nav_position_setting'] && has_nav_menu( 'secondary' ) && is_active_sidebar( 'top-bar' ) ) { - $css->set_selector( '.secondary-navigation .top-bar' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_text_color'] ) ); - $css->add_property( 'line-height', absint( $generate_settings['secondary_menu_item_height'] ), false, 'px' ); - - if ( ! $using_dynamic_typography ) { - $css->add_property( 'font-family', $secondary_nav_family ); - $css->add_property( 'font-weight', esc_attr( $generate_settings['secondary_navigation_font_weight'] ) ); - $css->add_property( 'text-transform', esc_attr( $generate_settings['secondary_navigation_font_transform'] ) ); - $css->add_property( 'font-size', absint( $generate_settings['secondary_navigation_font_size'] ), false, 'px' ); - } - - $css->set_selector( '.secondary-navigation .top-bar a' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_text_color'] ) ); - - $css->set_selector( '.secondary-navigation .top-bar a:hover, .secondary-navigation .top-bar a:focus' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_background_hover_color'] ) ); - } - - // Navigation text. - $css->set_selector( '.secondary-navigation .main-nav ul li a,.secondary-navigation .menu-toggle,.secondary-menu-bar-items .menu-bar-item > a' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_text_color'] ) ); - - if ( ! $using_dynamic_typography ) { - $css->add_property( 'font-family', ( 'inherit' !== $secondary_nav_family ) ? $secondary_nav_family : null ); - $css->add_property( 'font-weight', esc_attr( $generate_settings['secondary_navigation_font_weight'] ), $og_defaults['secondary_navigation_font_weight'] ); - $css->add_property( 'text-transform', esc_attr( $generate_settings['secondary_navigation_font_transform'] ), $og_defaults['secondary_navigation_font_transform'] ); - $css->add_property( 'font-size', absint( $generate_settings['secondary_navigation_font_size'] ), $og_defaults['secondary_navigation_font_size'], 'px' ); - } - - $css->add_property( 'padding-left', absint( $generate_settings['secondary_menu_item'] ), $og_defaults['secondary_menu_item'], 'px' ); - $css->add_property( 'padding-right', absint( $generate_settings['secondary_menu_item'] ), $og_defaults['secondary_menu_item'], 'px' ); - $css->add_property( 'line-height', absint( $generate_settings['secondary_menu_item_height'] ), $og_defaults['secondary_menu_item_height'], 'px' ); - $css->add_property( 'background-image', ! empty( $generate_settings['nav_item_image'] ) ? 'url(' . esc_url( $generate_settings['nav_item_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_item_repeat'] ) ); - - $css->set_selector( '.secondary-navigation .secondary-menu-bar-items' ); - $css->add_property( 'color', $generate_settings['navigation_text_color'] ); - - if ( ! $using_dynamic_typography ) { - $css->add_property( 'font-size', absint( $generate_settings['secondary_navigation_font_size'] ), $og_defaults['secondary_navigation_font_size'], 'px' ); - } - - // Mobile menu text on hover. - $css->set_selector( 'button.secondary-menu-toggle:hover,button.secondary-menu-toggle:focus' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_text_color'] ) ); - - // Widget area navigation. - $css->set_selector( '.widget-area .secondary-navigation' ); - $css->add_property( 'margin-bottom', absint( $separator ), false, 'px' ); - - // Sub-navigation background. - $css->set_selector( '.secondary-navigation ul ul' ); - $css->add_property( 'background-color', esc_attr( $generate_settings['subnavigation_background_color'] ) ); - $css->add_property( 'top', 'auto' ); // Added for compatibility purposes on 22/12/2016. - - // Sub-navigation text. - $css->set_selector( '.secondary-navigation .main-nav ul ul li a' ); - $css->add_property( 'color', esc_attr( $generate_settings['subnavigation_text_color'] ) ); - - if ( ! $using_dynamic_typography ) { - $css->add_property( 'font-size', absint( $generate_settings['secondary_navigation_font_size'] - 1 ), absint( $og_defaults['secondary_navigation_font_size'] - 1 ), 'px' ); - } - - $css->add_property( 'padding-left', absint( $generate_settings['secondary_menu_item'] ), $og_defaults['secondary_menu_item'], 'px' ); - $css->add_property( 'padding-right', absint( $generate_settings['secondary_menu_item'] ), $og_defaults['secondary_menu_item'], 'px' ); - $css->add_property( 'padding-top', absint( $generate_settings['secondary_sub_menu_item_height'] ), $og_defaults['secondary_sub_menu_item_height'], 'px' ); - $css->add_property( 'padding-bottom', absint( $generate_settings['secondary_sub_menu_item_height'] ), $og_defaults['secondary_sub_menu_item_height'], 'px' ); - $css->add_property( 'background-image', ! empty( $generate_settings['sub_nav_item_image'] ) ? 'url(' . esc_url( $generate_settings['sub_nav_item_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sub_nav_item_repeat'] ) ); - - // Menu item padding on RTL. - if ( is_rtl() ) { - $css->set_selector( 'nav.secondary-navigation .main-nav ul li.menu-item-has-children > a' ); - $css->add_property( 'padding-right', absint( $generate_settings['secondary_menu_item'] ), $og_defaults['secondary_menu_item'], 'px' ); - } - - // Dropdown arrow. - $css->set_selector( '.secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle' ); - $css->add_property( 'padding-top', absint( $generate_settings['secondary_sub_menu_item_height'] ), $og_defaults['secondary_sub_menu_item_height'], 'px' ); - $css->add_property( 'padding-bottom', absint( $generate_settings['secondary_sub_menu_item_height'] ), $og_defaults['secondary_sub_menu_item_height'], 'px' ); - $css->add_property( 'margin-top', '-' . absint( $generate_settings['secondary_sub_menu_item_height'] ), '-' . absint( $og_defaults['secondary_sub_menu_item_height'] ), 'px' ); - - // Dropdown arrow. - $css->set_selector( '.secondary-navigation .menu-item-has-children .dropdown-menu-toggle' ); - $css->add_property( 'padding-right', absint( $generate_settings['secondary_menu_item'] ), $og_defaults['secondary_menu_item'], 'px' ); - - // Sub-navigation dropdown arrow. - $css->set_selector( '.secondary-navigation .menu-item-has-children ul .dropdown-menu-toggle' ); - $css->add_property( 'padding-top', absint( $generate_settings['secondary_sub_menu_item_height'] ), $og_defaults['secondary_sub_menu_item_height'], 'px' ); - $css->add_property( 'padding-bottom', absint( $generate_settings['secondary_sub_menu_item_height'] ), $og_defaults['secondary_sub_menu_item_height'], 'px' ); - $css->add_property( 'margin-top', '-' . absint( $generate_settings['secondary_sub_menu_item_height'] ), '-' . absint( $og_defaults['secondary_sub_menu_item_height'] ), 'px' ); - - // Navigation background/text on hover. - $css->set_selector( '.secondary-navigation .main-nav ul li:not([class*="current-menu-"]):hover > a, .secondary-navigation .main-nav ul li:not([class*="current-menu-"]):focus > a, .secondary-navigation .main-nav ul li.sfHover:not([class*="current-menu-"]) > a, .secondary-menu-bar-items .menu-bar-item:hover > a' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_text_hover_color'] ) ); - $css->add_property( 'background-color', esc_attr( $generate_settings['navigation_background_hover_color'] ) ); - $css->add_property( 'background-image', ! empty( $generate_settings['nav_item_hover_image'] ) ? 'url(' . esc_url( $generate_settings['nav_item_hover_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_item_hover_repeat'] ) ); - - // Sub-Navigation background/text on hover. - $css->set_selector( '.secondary-navigation .main-nav ul ul li:not([class*="current-menu-"]):hover > a,.secondary-navigation .main-nav ul ul li:not([class*="current-menu-"]):focus > a,.secondary-navigation .main-nav ul ul li.sfHover:not([class*="current-menu-"]) > a' ); - $css->add_property( 'color', esc_attr( $generate_settings['subnavigation_text_hover_color'] ) ); - $css->add_property( 'background-color', esc_attr( $generate_settings['subnavigation_background_hover_color'] ) ); - $css->add_property( 'background-image', ! empty( $generate_settings['sub_nav_item_hover_image'] ) ? 'url(' . esc_url( $generate_settings['sub_nav_item_hover_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sub_nav_item_hover_repeat'] ) ); - - // Navigation background / text current + hover. - $css->set_selector( '.secondary-navigation .main-nav ul li[class*="current-menu-"] > a' ); - $css->add_property( 'color', esc_attr( $generate_settings['navigation_text_current_color'] ) ); - $css->add_property( 'background-color', esc_attr( $generate_settings['navigation_background_current_color'] ) ); - $css->add_property( 'background-image', ! empty( $generate_settings['nav_item_current_image'] ) ? 'url(' . esc_url( $generate_settings['nav_item_current_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['nav_item_current_repeat'] ) ); - - // Sub-Navigation background / text current + hover. - $css->set_selector( '.secondary-navigation .main-nav ul ul li[class*="current-menu-"] > a' ); - $css->add_property( 'color', esc_attr( $generate_settings['subnavigation_text_current_color'] ) ); - $css->add_property( 'background-color', esc_attr( $generate_settings['subnavigation_background_current_color'] ) ); - $css->add_property( 'background-image', ! empty( $generate_settings['sub_nav_item_current_image'] ) ? 'url(' . esc_url( $generate_settings['sub_nav_item_current_image'] ) . ')' : '' ); - $css->add_property( 'background-repeat', esc_attr( $generate_settings['sub_nav_item_current_repeat'] ) ); - - // RTL menu item padding. - if ( is_rtl() ) { - $css->set_selector( '.secondary-navigation .main-nav ul li.menu-item-has-children > a' ); - $css->add_property( 'padding-right', absint( $generate_settings['secondary_menu_item'] ), false, 'px' ); - } - - if ( function_exists( 'generate_get_option' ) && function_exists( 'generate_get_defaults' ) ) { - $theme_defaults = generate_get_defaults(); - - if ( isset( $theme_defaults['icons'] ) ) { - if ( 'svg' === generate_get_option( 'icons' ) ) { - $css->set_selector( '.secondary-navigation.toggled .dropdown-menu-toggle:before' ); - $css->add_property( 'display', 'none' ); - } - } - } - - $mobile_css = '@media ' . generate_premium_get_media_query( 'mobile-menu' ) . ' {.secondary-menu-bar-items .menu-bar-item:hover > a{background: none;color: ' . $generate_settings['navigation_text_color'] . ';}}'; - - // Return our dynamic CSS. - return $css->css_output() . $mobile_css; - } -} - -if ( ! function_exists( 'generate_secondary_color_scripts' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_secondary_color_scripts', 110 ); - /** - * Enqueue scripts and styles - */ - function generate_secondary_color_scripts() { - // Bail if no Secondary menu is set. - if ( ! has_nav_menu( 'secondary' ) ) { - return; - } - - wp_add_inline_style( 'generate-secondary-nav', generate_secondary_nav_css() ); - - if ( class_exists( 'GeneratePress_Typography' ) ) { - wp_add_inline_style( 'generate-secondary-nav', GeneratePress_Typography::get_css( 'secondary-nav' ) ); - } - } -} - -if ( ! function_exists( 'generate_secondary_navigation_class' ) ) { - /** - * Display the classes for the secondary navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - */ - function generate_secondary_navigation_class( $class = '' ) { - // Separates classes with a single space, collates classes for post DIV. - echo 'class="' . join( ' ', generate_get_secondary_navigation_class( $class ) ) . '"'; // phpcs:ignore -- Escaped in generate_get_secondary_navigation_class. - } -} - -if ( ! function_exists( 'generate_get_secondary_navigation_class' ) ) { - /** - * Retrieve the classes for the secondary navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - * @return array Array of classes. - */ - function generate_get_secondary_navigation_class( $class = '' ) { - $classes = array(); - - if ( ! empty( $class ) ) { - if ( ! is_array( $class ) ) { - $class = preg_split( '#\s+#', $class ); - } - - $classes = array_merge( $classes, $class ); - } - - $classes = array_map( 'esc_attr', $classes ); - - return apply_filters( 'generate_secondary_navigation_class', $classes, $class ); - } -} - -if ( ! function_exists( 'generate_secondary_menu_class' ) ) { - /** - * Display the classes for the secondary navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - */ - function generate_secondary_menu_class( $class = '' ) { - // Separates classes with a single space, collates classes for post DIV. - echo 'class="' . join( ' ', generate_get_secondary_menu_class( $class ) ) . '"'; // phpcs:ignore -- Escaped in generate_get_secondary_menu_class. - } -} - -if ( ! function_exists( 'generate_get_secondary_menu_class' ) ) { - /** - * Retrieve the classes for the secondary navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - * @return array Array of classes. - */ - function generate_get_secondary_menu_class( $class = '' ) { - $classes = array(); - - if ( ! empty( $class ) ) { - if ( ! is_array( $class ) ) { - $class = preg_split( '#\s+#', $class ); - } - - $classes = array_merge( $classes, $class ); - } - - $classes = array_map( 'esc_attr', $classes ); - - return apply_filters( 'generate_secondary_menu_class', $classes, $class ); - } -} - -if ( ! function_exists( 'generate_inside_secondary_navigation_class' ) ) { - /** - * Display the classes for the inner navigation. - * - * @since 0.1 - * @param string|array $class One or more classes to add to the class list. - */ - function generate_inside_secondary_navigation_class( $class = '' ) { - $classes = array(); - - if ( ! empty( $class ) ) { - if ( ! is_array( $class ) ) { - $class = preg_split( '#\s+#', $class ); - } - - $classes = array_merge( $classes, $class ); - } - - $classes = array_map( 'esc_attr', $classes ); - - $return = apply_filters( 'generate_inside_secondary_navigation_class', $classes, $class ); - - // Separates classes with a single space, collates classes for post DIV. - echo 'class="' . join( ' ', $return ) . '"'; // phpcs:ignore -- Escaped above. - } -} - -if ( ! function_exists( 'generate_secondary_nav_remove_top_bar' ) ) { - add_action( 'wp', 'generate_secondary_nav_remove_top_bar' ); - /** - * Remove the top bar and add it to the Secondary Navigation if it's set - */ - function generate_secondary_nav_remove_top_bar() { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - if ( $generate_settings['merge_top_bar'] && 'secondary-nav-above-header' === $generate_settings['secondary_nav_position_setting'] && has_nav_menu( 'secondary' ) && is_active_sidebar( 'top-bar' ) ) { - remove_action( 'generate_before_header', 'generate_top_bar', 5 ); - add_action( 'generate_inside_secondary_navigation', 'generate_secondary_nav_top_bar_widget', 5 ); - add_filter( 'generate_is_top_bar_active', '__return_false' ); - } - } -} - -if ( ! function_exists( 'generate_secondary_nav_top_bar_widget' ) ) { - /** - * Build the top bar widget area - * This is placed into the secondary navigation if set - */ - function generate_secondary_nav_top_bar_widget() { - if ( ! is_active_sidebar( 'top-bar' ) ) { - return; - } - ?> -
            -
            - -
            -
            - .secondary-navigation .main-nav ul li a, .secondary-navigation .menu-toggle, .secondary-menu-bar-items .menu-bar-item > a{padding: 0 ' + newval + 'px;}.secondary-navigation .menu-item-has-children .dropdown-menu-toggle{padding-right:' + newval + 'px;}' ); - setTimeout(function() { - jQuery( 'style#secondary_menu_item' ).not( ':last' ).remove(); - }, 50); - } ); - } ); - - wp.customize( 'generate_secondary_nav_settings[secondary_menu_item_height]', function( value ) { - value.bind( function( newval ) { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#secondary_menu_item_height' ).not( ':last' ).remove(); - }, 50); - } ); - } ); - - wp.customize( 'generate_secondary_nav_settings[secondary_sub_menu_item_height]', function( value ) { - value.bind( function( newval ) { - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#secondary_sub_menu_item_height' ).not( ':last' ).remove(); - }, 50); - } ); - } ); - -})( jQuery ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/generate-secondary-nav.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/generate-secondary-nav.php deleted file mode 100644 index 7c3e48eb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/secondary-nav/generate-secondary-nav.php +++ /dev/null @@ -1,23 +0,0 @@ - *:last-child { - margin-bottom: 0; -} - -.generate-sections-container { - background-size: cover; -} - -.generate-sections-container.no-padding .generate-sections-inside-container { - padding: 0px !important; -} - -.generate-sections-enabled.one-container .site-content { - padding: 0; -} - -.generate-sections-enabled.one-container .container { - background: transparent; -} - -.generate-sections-enabled.one-container .site-main { - margin: 0 !important; -} - -.generate-sections-enabled .entry-content { - text-align: center; -} - -.separate-containers .site-main > .generate-sections-container { - margin-bottom: 0; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/css/style.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/css/style.min.css deleted file mode 100644 index 802b011a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/css/style.min.css +++ /dev/null @@ -1 +0,0 @@ -.sections-no-sidebars.generate-sections-enabled .container.grid-container,.sections-sidebars.no-sidebar.generate-sections-enabled .container.grid-container{max-width:100%}.sections-no-sidebars.generate-sections-enabled #primary.content-area,.sections-sidebars.no-sidebar.generate-sections-enabled #primary.content-area{width:100%}.sections-no-sidebars.generate-sections-enabled.separate-containers #main.site-main,.sections-no-sidebars.generate-sections-enabled.separate-containers .hentry,.sections-sidebars.no-sidebar.generate-sections-enabled.separate-containers #main.site-main,.sections-sidebars.no-sidebar.generate-sections-enabled.separate-containers .hentry{margin:0}.generate-sections-inside-container>:last-child{margin-bottom:0}.generate-sections-container{background-size:cover}.generate-sections-container.no-padding .generate-sections-inside-container{padding:0!important}.generate-sections-enabled.one-container .site-content{padding:0}.generate-sections-enabled.one-container .container{background:0 0}.generate-sections-enabled.one-container .site-main{margin:0!important}.generate-sections-enabled .entry-content{text-align:center}.separate-containers .site-main>.generate-sections-container{margin-bottom:0} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/generate-sections.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/generate-sections.php deleted file mode 100644 index 2703c8e4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/generate-sections.php +++ /dev/null @@ -1,329 +0,0 @@ -ID, '_generate_use_sections', TRUE) : ''; - - if ( is_home() || is_archive() || is_search() || is_attachment() || is_tax() ) { - return $template; - } - - if ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) { - - $new_template = dirname( __FILE__ ) . '/templates/template.php'; - - if ( '' != $new_template ) { - return $new_template; - } - } - return $template; - - } -} - -if ( ! function_exists( 'generate_sections_show_excerpt' ) ) { - add_filter( 'generate_show_excerpt', 'generate_sections_show_excerpt' ); - /** - * If Sections is enabled on a post, make sure we use the excerpt field on the blog page - */ - function generate_sections_show_excerpt( $show_excerpt ) { - global $post; - $use_sections = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate_use_sections', TRUE) : ''; - - if ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) { - return true; - } - - return $show_excerpt; - } -} - -if ( ! function_exists( 'generate_sections_styles' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_sections_styles' ); - /** - * Enqueue necessary scripts if sections are enabled - */ - function generate_sections_styles() { - - global $post; - $use_sections = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate_use_sections', TRUE) : ''; - - // Bail if we're on a posts page - if ( is_home() || is_archive() || is_search() || is_attachment() || is_tax() ) { - return; - } - - if ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) { - wp_enqueue_style( 'generate-sections-styles', plugin_dir_url( __FILE__ ) . 'css/style.min.css' ); - wp_enqueue_script( 'generate-sections-parallax', plugin_dir_url( __FILE__ ) . 'js/parallax.min.js', array(), GENERATE_SECTIONS_VERSION, true ); - } - } -} - -if ( ! function_exists( 'generate_sections_body_classes' ) ) { - add_filter( 'body_class', 'generate_sections_body_classes' ); - /** - * Add classes to our element when sections are enabled - */ - function generate_sections_body_classes( $classes ) { - global $post; - $use_sections = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate_use_sections', TRUE) : ''; - $sidebars = apply_filters( 'generate_sections_sidebars', false ); - - // Bail if we're on a posts page - if ( is_home() || is_archive() || is_search() || is_attachment() || is_tax() ) { - return $classes; - } - - if ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) { - $classes[] = 'generate-sections-enabled'; - } - - if ( ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) && ! $sidebars ) { - $classes[] = 'sections-no-sidebars'; - } - - if ( ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) && $sidebars ) { - $classes[] = 'sections-sidebars'; - } - - return $classes; - } -} - -if ( ! function_exists( 'generate_sections_add_css' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_sections_add_css', 500 ); - /** - * Create the CSS for our sections - */ - function generate_sections_add_css() { - global $post; - $use_sections = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate_use_sections', TRUE) : ''; - - if ( ! isset( $use_sections['use_sections'] ) ) { - return; - } - - if ( 'true' !== $use_sections['use_sections'] ) { - return; - } - - if ( is_home() || is_archive() || is_search() || is_attachment() || is_tax() ) { - return; - } - - if ( function_exists( 'generate_spacing_get_defaults' ) ) { - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - - $left_padding = $spacing_settings['content_left']; - $right_padding = $spacing_settings['content_right']; - $mobile_padding_left = ( isset( $spacing_settings[ 'mobile_content_left' ] ) ) ? $spacing_settings[ 'mobile_content_left' ] : 30; - $mobile_padding_right = ( isset( $spacing_settings[ 'mobile_content_right' ] ) ) ? $spacing_settings[ 'mobile_content_right' ] : 30; - } else { - $right_padding = 40; - $left_padding = 40; - $mobile_padding = 30; - } - - $sections = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate_sections', TRUE) : ''; - - // check if the repeater field has rows of data - if ( $sections && '' !== $sections ) { - - $css = '.generate-sections-inside-container {padding-left:' . $left_padding . 'px;padding-right:' . $right_padding . 'px;}'; - // loop through the rows of data - $i = 0; - foreach ( $sections['sections'] as $section ) : - $i++; - - // Get image details - $image_id = ( isset( $section['background_image'] ) && '' !== $section['background_image'] ) ? intval( $section['background_image'] ) : ''; - $image_url = ( '' !== $image_id ) ? wp_get_attachment_image_src( $image_id, 'full' ) : ''; - - // Get the padding type - $padding_type = apply_filters( 'generate_sections_padding_type','px' ); - - // If someone has changed the padding type using a filter, use their value - if ( 'px' !== $padding_type ) { - $top_padding_type = $padding_type; - $bottom_padding_type = $padding_type; - } else { - $top_padding_type = ( isset( $section['top_padding_unit'] ) && '' !== $section['top_padding_unit'] ) ? $section['top_padding_unit'] : $padding_type; - $bottom_padding_type = ( isset( $section['bottom_padding_unit'] ) && '' !== $section['bottom_padding_unit'] ) ? $section['bottom_padding_unit'] : $padding_type; - } - - // Default padding top - $padding_top = apply_filters( 'generate_sections_default_padding_top','40' ); - - // Default padding bottom - $padding_bottom = apply_filters( 'generate_sections_default_padding_bottom','40' ); - - $custom_id = ( isset( $section['custom_id'] ) ) ? $section['custom_id'] : ''; - $custom_id = ( '' == $custom_id ) ? "generate-section-$i" : $custom_id; - - // Get the values - $background_color = ( isset( $section['background_color'] ) && '' !== $section['background_color'] ) ? 'background-color:' . esc_attr( $section['background_color'] ) . ';' : ''; - $background_image = ( ! empty( $image_url[0] ) ) ? 'background-image:url(' . esc_url( $image_url[0] ) . ');' : ''; - - if ( isset( $section['background_color_overlay'] ) && '' !== $section['background_color_overlay'] ) { - if ( '' !== $background_image && '' !== $background_color ) { - $background_image = 'background-image:linear-gradient(0deg, ' . $section['background_color'] . ',' . $section['background_color'] . '), url(' . esc_url( $image_url[0] ) . ');'; - $background_color = ''; - } - } - - $text_color = ( isset( $section['text_color'] ) && '' !== $section['text_color'] ) ? 'color:' . esc_attr( $section['text_color'] ) . ';' : ''; - $link_color = ( isset( $section['link_color'] ) && '' !== $section['link_color'] ) ? 'color:' . esc_attr( $section['link_color'] ) . ';' : ''; - $link_color_hover = ( isset( $section['link_color_hover'] ) && '' !== $section['link_color_hover'] ) ? 'color:' . esc_attr( $section['link_color_hover'] ) . ';' : ''; - $top_padding = ( isset( $section['top_padding'] ) && '' !== $section['top_padding'] ) ? 'padding-top:' . absint( $section['top_padding'] ) . $top_padding_type . ';' : 'padding-top:' . $padding_top . 'px;'; - $bottom_padding = ( isset( $section['bottom_padding'] ) && '' !== $section['bottom_padding'] ) ? 'padding-bottom:' . absint( $section['bottom_padding'] ) . $bottom_padding_type . ';' : 'padding-bottom:' . $padding_bottom . 'px;'; - - // Outer container - if ( '' !== $background_color || '' !== $background_image ) { - $css .= '#' . $custom_id . '.generate-sections-container{' . $background_color . $background_image . '}'; - } - - // Inner container - if ( '' !== $top_padding || '' !== $bottom_padding || '' !== $text_color ) { - $css .= '#' . $custom_id . ' .generate-sections-inside-container{' . $top_padding . $bottom_padding . $text_color . '}'; - } - - // Link color - if ( '' !== $link_color ) { - $css .= '#' . $custom_id . ' a,#generate-section-' . $i . ' a:visited{' . $link_color . '}'; - } - - // Link color hover - if ( '' !== $link_color_hover ) { - $css .= '#' . $custom_id . ' a:hover{' . $link_color_hover . '}'; - } - - $mobile = generate_premium_get_media_query( 'mobile' ); - $css .= '@media ' . esc_attr( $mobile ) . ' {.generate-sections-inside-container {padding-left: ' . $mobile_padding_left . 'px;padding-right: ' . $mobile_padding_right . 'px;}}'; - endforeach; - - // Build CSS - wp_add_inline_style( 'generate-style', $css ); - - } - } -} - -if ( ! function_exists( 'generate_sections_filter_admin_init' ) ) { - add_action( 'admin_init', 'generate_sections_filter_admin_init' ); - /* - * Recreate the default filters on the_content - * this will make it much easier to output the meta content with proper/expected formatting - */ - function generate_sections_filter_admin_init() { - if ( user_can_richedit() ) { - add_filter( 'generate_section_content', 'convert_smilies' ); - add_filter( 'generate_section_content', 'convert_chars' ); - add_filter( 'generate_section_content', 'wpautop' ); - add_filter( 'generate_section_content', 'shortcode_unautop' ); - add_filter( 'generate_section_content', 'prepend_attachment' ); - } - } -} - -if ( ! function_exists( 'generate_sections_filter' ) ) { - add_action( 'init', 'generate_sections_filter' ); - /* - * Recreate the default filters on the_content - * this will make it much easier to output the meta content with proper/expected formatting - */ - function generate_sections_filter() { - if ( is_admin() ) { - return; - } - - add_filter( 'generate_section_content', 'convert_smilies' ); - add_filter( 'generate_section_content', 'convert_chars' ); - add_filter( 'generate_section_content', 'wpautop' ); - add_filter( 'generate_section_content', 'shortcode_unautop' ); - add_filter( 'generate_section_content', 'prepend_attachment' ); - add_filter( 'generate_section_content', 'do_shortcode'); - - add_filter( 'generate_the_section_content', array($GLOBALS['wp_embed'], 'autoembed'), 9 ); - } -} - -if ( ! function_exists( 'generate_sections_save_content' ) ) { - add_action( 'save_post', 'generate_sections_save_content', 99, 4 ); - /* - * When we save our post, grab all of the section content and save it as regular content. - * - * This will prevent content loss/theme lock. - */ - function generate_sections_save_content( $post_id, $post ) { - - if ( ! isset( $_POST['_generate_sections_nonce'] ) || ! wp_verify_nonce( $_POST['_generate_sections_nonce'], 'generate_sections_nonce' ) ) { - return; - } - - if ( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE ) { - return; - } - - if ( ! current_user_can('edit_post', $post_id ) ) { - return; - } - - // See if we're using sections - $use_sections = get_post_meta( $post_id, '_generate_use_sections', true); - - // Make sure use sections exists and that we're not saving a revision - if ( ! isset( $use_sections['use_sections'] ) || wp_is_post_revision( $post_id ) ) { - return; - } - - // Return if sections are set to false - if ( 'true' !== $use_sections['use_sections'] ) { - return; - } - - // Get our sections - $sections = get_post_meta( $post_id, '_generate_sections', true ); - - // Return if there's nothing in our sections - if ( ! isset( $sections ) || '' == $sections ) { - return; - } - - // Prevent infinite loop - remove_action( 'save_post', 'generate_sections_save_content', 99, 4 ); - - // Let's do some stuff if sections aren't empty - if ( '' !== $sections ) { - // Set up our content variable - $content = ''; - - // Loop through each section and add our content to the content variable - foreach ( $sections['sections'] as $section ) { - $content .= ( isset( $section['content'] ) && '' !== $section['content'] ) ? $section['content'] . "\n\n" : ''; - } - - // Now update our post if we have section content - if ( '' !== $content ) { - $post->post_content = $content; - wp_update_post( $post, true ); - } - } - - // Re-hook the save_post action - add_action('save_post', 'generate_sections_save_content', 99, 4); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/js/parallax.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/js/parallax.js deleted file mode 100644 index 2c49e753..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/js/parallax.js +++ /dev/null @@ -1,17 +0,0 @@ -function generate_sections_parallax_element( selector, context ) { - context = context || document; - var elements = context.querySelectorAll( selector ); - return Array.prototype.slice.call( elements ); -} - -window.addEventListener( "scroll", function() { - var scrolledHeight= window.pageYOffset; - generate_sections_parallax_element( ".generate-sections-container.enable-parallax" ).forEach( function( el, index, array ) { - var limit = el.offsetTop + el.offsetHeight; - if( scrolledHeight > el.offsetTop && scrolledHeight <= limit ) { - el.style.backgroundPositionY = ( scrolledHeight - el.offsetTop ) / el.getAttribute( 'data-speed' ) + "px"; - } else { - el.style.backgroundPositionY = "0"; - } - }); -}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/js/parallax.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/js/parallax.min.js deleted file mode 100644 index 7004f63b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/js/parallax.min.js +++ /dev/null @@ -1 +0,0 @@ -function generate_sections_parallax_element(e,t){var o=(t=t||document).querySelectorAll(e);return Array.prototype.slice.call(o)}window.addEventListener("scroll",function(){var e=window.pageYOffset;generate_sections_parallax_element(".generate-sections-container.enable-parallax").forEach(function(t,o,n){var a=t.offsetTop+t.offsetHeight;e>t.offsetTop&&e<=a?t.style.backgroundPositionY=(e-t.offsetTop)/t.getAttribute("data-speed")+"px":t.style.backgroundPositionY="0"})}); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/css/generate-sections-metabox.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/css/generate-sections-metabox.css deleted file mode 100644 index 6927a1b3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/css/generate-sections-metabox.css +++ /dev/null @@ -1,348 +0,0 @@ -body { - -webkit-backface-visibility: hidden; -} -#_generate_sections_metabox { - opacity: 0; - height: 0; - overflow: hidden; -} - -#_generate_use_sections_metabox { - display: block !important; -} - -.generate_sections_control { - padding-top: 8px; -} - -.generate-sections-enabled #postdivrich { - opacity: 0; - height: 0; - overflow: hidden; -} -.generate-sections-enabled #_generate_sections_metabox { - opacity: 1; - height: auto; -} - -.generate_sections_control .warning { - color: red; -} -.generate_sections_control .dodelete-repeating_textareas { - float: right; -} -.generate_sections_control .section { - border: 1px solid #DFDFDF; - box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); - margin: 6px 0px 8px; - overflow: hidden; - position: relative; - background: white; -} -.generate_sections_control .section .section-title { - font-size: 14px; - padding: 0 0 0 15px; - margin: 0; - max-height: 50px; -} -.generate_sections_control .section .section-title > span { - cursor: pointer; - overflow:hidden; - display:block; - max-height:50px; - line-height:50px; - width:100%; -} -.generate_sections_control .section .section-controls { - position: absolute; - top:0; - right:0; - text-align: right; -} -.rtl .generate_sections_control .section .section-controls { - right:auto;left:0; -} -.generate_sections_control .section .section-controls a { - color: #aaa; - display:block; - float:left; - border-left: 1px solid #efefef; -} -.generate_sections_control .section .section-controls a:hover { - color: #777; -} -.generate_sections_control .section textarea { - display: none; -} -.generate_sections_control .section h3 { - color: #999; - font-size: 1em; - margin: 15px 6px; - text-transform: uppercase; -} -.generate_sections_control .section .ui-sortable-placeholder { - line-height: 1.4em; - border: 3px dashed #DDD; -} -.generate-sections-modal .media-menu-item { - cursor: pointer; -} -.custom-classes input { - width:100%; -} -.js .generate_sections_control .move-section { - cursor: move; -} -.generate-sections-modal p { - margin-top:5px; -} -#_generate_sections_metabox { - box-shadow: 0 0 0 transparent; -} -.section-controls a { - line-height:50px; - padding: 0 15px; - width:initial; - height:initial; -} - -.generate_sections_control .section .section-controls a.delete-section:hover { - color: red; -} - -.generate_sections_control p { - margin: 5px; -} - -textarea#generate-sections-editor { - border:0; -} - -#generate-sections-editor_ifr { - min-height: 400px; -} - -a#generate-add-section, a#generate-delete-sections { - height: auto; - line-height: inherit; - padding: 10px 20px; -} - -#wp-generate-sections-editor-wrap.old-sections-js .wp-media-buttons > * { - display:none; -} - -#wp-generate-sections-editor-wrap.old-sections-js .wp-media-buttons > .generate-sections-add-media, -#wp-generate-sections-editor-wrap.old-sections-js .wp-media-buttons > .su-generator-button, -#wp-generate-sections-editor-wrap.old-sections-js .wp-media-buttons > .envira-gallery-choose-gallery, -#wp-generate-sections-editor-wrap.old-sections-js .wp-media-buttons > .gridable-insert-row-button { - display: inline-block; -} - -#custom-media-buttons > * { - display: none; -} - -#custom-media-buttons > .insert-media, -#custom-media-buttons > .su-generator-button, -#custom-media-buttons > .envira-gallery-choose-gallery, -#custom-media-buttons > .gridable-insert-row-button, -#custom-media-buttons > .bfa-iconpicker { - display: inline-block; -} - -#_generate_sections_metabox { - background: transparent; - border: 0; -} -#_generate_sections_metabox > .handlediv, #_generate_sections_metabox > .hndle { - display: none; -} -#_generate_sections_metabox > .inside { - padding-left: 0; - padding-right: 0; -} - -body.wp-admin .grid-container { - max-width: 100%; -} - -.generate-sections-modal h3 { - margin-top: 0; -} - -input#custom_classes, -input#custom_id { - width: 100%; - max-width: 300px; -} - -.box-type select, -.inner-box-type select, -.parallax-effect select, -.top-padding input, -.bottom-padding input { - width: 100%; - box-sizing: border-box; -} - -.send-to-editor { - display: inline-block; - margin-top: 15px !important; -} - -#generate-sections-modal-dialog .media-frame-title .dashicons-arrow-down { - display: none; -} - -.gs-grid-container { - margin-left: auto; - margin-right: auto; - max-width: 100%; - padding-left: 10px; - padding-right: 10px; -} - -.gs-grid-parent { - padding-left: 0; - padding-right: 0; -} - -.gs-grid-container:before, -.gs-grid-container:after { - content: "."; - display: block; - overflow: hidden; - visibility: hidden; - font-size: 0; - line-height: 0; - width: 0; - height: 0; - clear: both; -} - -@media screen and (min-width: 769px) { - .gs-grid-50:before, - .gs-grid-50:after, - .gs-grid-33:before, - .gs-grid-33:after, - .gs-grid-25:before, - .gs-grid-25:after - .gs-grid-20:before, - .gs-grid-20:after - .gs-grid-12:before, - .gs-grid-12:after { - content: "."; - display: block; - overflow: hidden; - visibility: hidden; - font-size: 0; - line-height: 0; - width: 0; - height: 0; - clear: both; - } - .gs-grid-50, - .gs-grid-33, - .gs-grid-25, - .gs-grid-20, - .gs-grid-12 { - box-sizing: border-box; - padding-left: 10px; - padding-right: 10px; - } - .gs-grid-50 { - width: 50% !important; - float: left; - } - .gs-grid-33 { - width: 33.333% !important; - float: left; - } - .gs-grid-25 { - width: 25% !important; - float: left; - } - .gs-grid-20 { - width: 20% !important; - float: left; - } - .gs-grid-12 { - width: 12.5% !important; - float: left; - } - .top-border { - border-top: 1px solid #EFEFEF; - } - .bottom-border { - border-bottom: 1px solid #EFEFEF; - } - .border-right { - border-right: 1px solid #EFEFEF; - } - .border-left { - border-left: 1px solid #EFEFEF; - } -} - -@media screen and (max-width: 768px) { - .gs-grid-50, .gs-grid-33, .gs-grid-25, .gs-grid-12 { - width: 100% !important; - } - .generate_sections_control .section .section-controls { - position: relative; - } -} - -@media screen and (max-width: 500px) { - .generate_sections_control .section .section-controls a:first-child { - border-left: 0; - } -} - -#generate-sections-modal-dialog .media-modal-close { - text-decoration: none; - text-align: center; -} -/* - The styles below were ripped from the Media Modal in WordPress 3.5 - ~~ Thanks for building a beautiful Modal UI ( that I could steal ) -*/ -body.generate-modal-open { overflow: hidden; } - -.generate-sections-modal .media-modal { z-index: 65535; } -.generate-sections-modal .media-modal-backdrop { z-index: 65534; } -.generate-sections-modal .media-frame-content .panel { display: none; padding: 2em; } -.generate-sections-modal .media-frame-content .panel.active { display: block; } -.generate-sections-modal .media-frame-content .panel .section-title input { width:100%;padding:10px; } -.generate-sections-modal .media-frame-content .panel .html-active .mce-panel { display: none; } -.generate-sections-modal .media-frame-content .panel .html-active .wp-editor-area { display: block !important; min-height: 300px; } -.generate-sections-modal .media-frame-content .panel .mce-wp-dfw, .generate-sections-modal .media-frame-content .panel .qt-dfw { display: none; } -.generate-sections-modal .media-frame-content .panel .generate-sections-remove-image { display: none; } - -textarea.no-rich-edit { - width: 100%; - min-height: 300px; -} - -.wp-picker-container .wp-color-result.button { - height: 24px; - margin: 0 6px 6px 0px; - padding: 0 0 0 30px; - font-size: 11px; -} - -.wp-color-result:after { - display: none; -} - -.wp-color-result-text { - background: #f7f7f7; - border-radius: 0 2px 2px 0; - border-left: 1px solid #ccc; - color: #555; - display: block; - line-height: 22px; - padding: 0 6px; - text-align: center; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/css/lc_switch.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/css/lc_switch.css deleted file mode 100644 index 5f95b304..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/css/lc_switch.css +++ /dev/null @@ -1,92 +0,0 @@ -.lcs_wrap { - display: inline-block; - direction: ltr; - height: 28px; - vertical-align: middle; -} -.lcs_wrap input { - display: none; -} - -.lcs_switch { - display: inline-block; - position: relative; - width: 73px; - height: 28px; - border-radius: 30px; - background: #ddd; - overflow: hidden; - cursor: pointer; - transition: all .2s ease-in-out; -} -.lcs_cursor { - display: inline-block; - position: absolute; - top: 3px; - width: 22px; - height: 22px; - border-radius: 100%; - background: #fff; - box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.2), 0 3px 4px 0 rgba(0, 0, 0, 0.1); - z-index: 10; - transition: all .2s linear; -} -.lcs_label { - font-family: "Trebuchet MS", Helvetica, sans-serif; - font-size: 12px; - letter-spacing: 1px; - line-height: 18px; - color: #fff; - font-weight: bold; - position: absolute; - width: 33px; - top: 5px; - overflow: hidden; - text-align: center; - opacity: 0; - transition: all .2s ease-in-out .1s; -} -.lcs_label.lcs_label_on { - left: -70px; - z-index: 6; -} -.lcs_label.lcs_label_off { - right: -70px; - z-index: 5; -} - - -/* on */ -.lcs_switch.lcs_on { - background: #75b936; - box-shadow: 0 0 2px #579022 inset; -} -.lcs_switch.lcs_on .lcs_cursor { - left: 48px; -} -.lcs_switch.lcs_on .lcs_label_on { - left: 10px; - opacity: 1; -} - - -/* off */ -.lcs_switch.lcs_off { - background: #b2b2b2; - box-shadow: 0px 0px 2px #a4a4a4 inset; -} -.lcs_switch.lcs_off .lcs_cursor { - left: 3px; -} -.lcs_switch.lcs_off .lcs_label_off { - right: 10px; - opacity: 1; -} - - -/* disabled */ -.lcs_switch.lcs_disabled { - opacity: 0.65; - filter: alpha(opacity=65); - cursor: default; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/js/generate-sections-metabox-4.9.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/js/generate-sections-metabox-4.9.js deleted file mode 100644 index f9215062..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/js/generate-sections-metabox-4.9.js +++ /dev/null @@ -1,835 +0,0 @@ -/*-----------------------------------------------------------------------------------*/ -/* Generate Sections Metabox -/* -/* © Kathy Darling http://www.kathyisawesome.com -/* 2016-07-19. */ -/*-----------------------------------------------------------------------------------*/ - -/** - * @type {Object} JavaScript namespace for our application. - */ -var Generate_Sections = { - backbone_modal: { - __instance: undefined - } -}; - -(function($, Generate_Sections) { - - - // Model - Generate_Sections.Section = Backbone.Model.extend({ - defaults: { - "title": "", - "box_type": "", - "inner_box_type": "", - "custom_classes": "", - "custom_id": "", - "top_padding": "", - "bottom_padding": "", - "top_padding_unit": "", - "bottom_padding_unit": "", - "background_color": "", - "background_image": "", - "background_image_preview": "", - "parallax_effect": "", - "background_color_overlay": "", - "text_color": "", - "link_color": "", - "link_color_hover": "", - "content": "" - } - }); - - - // Collection - Generate_Sections.SectionsCollection = Backbone.Collection.extend({ - model: Generate_Sections.Section, - el: "#generate_sections_container", - comparator: function(model) { - return model.get('index'); - } - }); - - - /** - * Primary Modal Application Class - */ - Generate_Sections.backbone_modal.Application = Backbone.View.extend({ - - attributes: { - id: "generate-sections-modal-dialog", - class: "generate-sections-modal", - role: "dialog" - }, - - template: wp.template("generate-sections-modal-window"), - - mediaUploader: null, - - /*-----------------------------------------------------------------------------------*/ - /* tinyMCE settings - /*-----------------------------------------------------------------------------------*/ - - tmc_settings: {}, - - /*-----------------------------------------------------------------------------------*/ - /* tinyMCE defaults - /*-----------------------------------------------------------------------------------*/ - - tmc_defaults: { - theme: "modern", - menubar: false, - wpautop: true, - indent: false, - toolbar1: "bold,italic,underline,blockquote,strikethrough,bullist,numlist,alignleft,aligncenter,alignright,undo,redo,link,unlink,fullscreen", - plugins: "fullscreen,image,wordpress,wpeditimage,wplink", - max_height: 500 - }, - - /*-----------------------------------------------------------------------------------*/ - /* quicktags settings - /*-----------------------------------------------------------------------------------*/ - - qt_settings: {}, - - /*-----------------------------------------------------------------------------------*/ - /* quicktags defaults - /*-----------------------------------------------------------------------------------*/ - - qt_defaults: { - buttons: "strong,em,link,block,del,ins,img,ul,ol,li,code,more,close,fullscreen" - }, - - model: Generate_Sections.Section, - - events: { - "click .media-modal-backdrop, .media-modal-close, .media-button-close": "closeModal", - "click .media-button-insert": "saveModal", - "click .media-menu-item": "switchTab", - "keydown": "keydown", - "click .generate-sections-upload-button": "openMediaUploader", - "click .generate-sections-remove-image": "removeImage", - "click div.media-frame-title h1": "toggleMenu" - }, - - - - /** - * Simple object to store any UI elements we need to use over the life of the application. - */ - ui: { - nav: undefined, - content: undefined - }, - - - /** - * Instantiates the Template object and triggers load. - */ - initialize: function() { - _.bindAll(this, "render", "closeModal", "saveModal", "switchTab"); - - this.focusManager = new wp.media.view.FocusManager({ - el: this.el - }); - - this.changeInsertText(); - this.tinyMCEsettings(); - this.render(); - }, - - /** - * switch the insert button text to "insert section" - */ - changeInsertText: function(restore) { - - var restore = typeof restore !== 'undefined' && restore == true ? true : false; - - if (restore == false && typeof(wp.media.view.l10n.insertIntoPost) !== "undefined") { - this.insertIntoPost = wp.media.view.l10n.insertIntoPost; - wp.media.view.l10n.insertIntoPost = generate_sections_metabox_i18n.insert_into_section; - // switch the insert button text back - } else if (restore == true && typeof(this.insertIntoPost) !== "undefined") { - wp.media.view.l10n.insertIntoPost = this.insertIntoPost; - } - }, - - - /** - * Merge the default TinyMCE settings - */ - tinyMCEsettings: function() { - // get the #content"s tinyMCE settings or use default - var init_settings = typeof tinyMCEPreInit == "object" && "mceInit" in tinyMCEPreInit && "content" in tinyMCEPreInit.mceInit ? tinyMCEPreInit.mceInit.content : this.tmc_defaults; - - // get the #content"s quicktags settings or use default - var qt_settings = typeof tinyMCEPreInit == "object" && "qtInit" in tinyMCEPreInit && "content" in tinyMCEPreInit.qtInit ? tinyMCEPreInit.qtInit.content : this.qt_defaults; - - var _this = this; - var custom_settings = { - selector: "#generate-sections-editor", - wp_autoresize_on: false, - cache_suffix: "", - min_height: 400, - } - - // merge our settings with WordPress" and store for later use - this.tmc_settings = $.extend({}, init_settings, custom_settings); - - this.qt_settings = $.extend({}, qt_settings, { - id: "generate-sections-editor" - }); - }, - - - /** - * Assembles the UI from loaded template. - * @internal Obviously, if the template fail to load, our modal never launches. - */ - render: function() { - - "use strict"; - - // Build the base window and backdrop, attaching them to the $el. - // Setting the tab index allows us to capture focus and redirect it in Application.preserveFocus - this.$el.attr("tabindex", "0") - .html(this.template); - - // Handle any attempt to move focus out of the modal. - //jQuery(document).on("focusin", this.preserveFocus); - - // set overflow to "hidden" on the body so that it ignores any scroll events while the modal is active - // and append the modal to the body. - jQuery("body").addClass("generate-modal-open").prepend(this.$el); - - // aria hide the background - jQuery("#wpwrap").attr("aria-hidden", "true"); - - this.renderContent(); - - this.renderPreview(); - - this.selected(); - this.colorPicker(); - this.startTinyMCE(); - - // Set focus on the modal to prevent accidental actions in the underlying page - this.$el.focus(); - - return this; - }, - - /** - * Make the menu mobile-friendly - */ - toggleMenu: function() { - this.$el.find('.media-menu').toggleClass('visible'); - }, - - /** - * Create the nav tabs & panels - */ - renderContent: function() { - - var model = this.model; - - var menu_item = wp.template("generate-sections-modal-menu-item"); - - // Save a reference to the navigation bar"s unordered list and populate it with items. - this.ui.nav = this.$el.find(".media-menu"); - - // reference to content area - this.ui.panels = this.$el.find(".media-frame-content"); - - // loop through the tabs - if (generate_sections_metabox_i18n.tabs.length) { - - // for...of is nicer, but not supported by minify, so stay with for...in for now - for (var tab in generate_sections_metabox_i18n.tabs) { - - if (generate_sections_metabox_i18n.tabs.hasOwnProperty(tab)) { - - tab = generate_sections_metabox_i18n.tabs[tab]; - - var $new_tab = $(menu_item({ - target: tab.target, - name: tab.title - })); - - var panel = wp.template("generate-sections-edit-" + tab.target); - - var $new_panel = $(panel(model.toJSON())); - - if (tab.active == "true") { - $new_tab.addClass("active"); - $new_panel.addClass("active"); - } - - jQuery( 'body' ).on( 'generate_section_show_settings', function() { - jQuery( '.generate-sections-modal .media-menu-item' ).removeClass('active'); - jQuery( '.generate-sections-modal .panel' ).removeClass('active'); - jQuery( '.generate-section-item-style' ).addClass('active'); - jQuery( '.generate-section-settings' ).addClass('active'); - }); - - this.ui.nav.append($new_tab); - this.ui.panels.append($new_panel); - } - } - } - - }, - - - /** - * Render the background image preview - */ - renderPreview: function(image_id) { - - var image_id = typeof image_id !== 'undefined' ? image_id : this.model.get("background_image"); - - var $preview = $("#generate-section-image-preview"); - $preview.children().remove(); - - if (image_id > 0) { - this.background = new wp.media.model.Attachment.get(image_id); - - this.background.fetch({ - success: function(att) { - if (_.contains(['png', 'jpg', 'gif', 'jpeg'], att.get('subtype'))) { - $("").attr("src", att.attributes.sizes.thumbnail.url).appendTo($preview); - $preview.next().find(".generate-sections-remove-image").show(); - } - } - }); - } - - }, - - - /** - * Set the default option for the select boxes - */ - selected: function() { - - var _this = this; - - this.$el.find("select").each(function(index, select) { - - var attribute = jQuery(select).attr("name"); - var selected = _this.model.get(attribute); - jQuery(select).val(selected); - - }); - }, - - /** - * Start the colorpicker - */ - colorPicker: function() { - this.$el.find(".generate-sections-color").wpColorPicker(); - }, - - /** - * Start TinyMCE on the textarea - */ - startTinyMCE: function() { - - // set the default editor - this.ui.panels.find("#wp-generate-sections-editor-wrap").addClass(generate_sections_metabox_i18n.default_editor); - - // remove tool buttons if richedit disabled - if (!generate_sections_metabox_i18n.user_can_richedit) { - this.ui.panels.find(".wp-editor-tabs").remove(); - } - - // add our copy to the collection in the tinyMCEPreInit object because switch editors - if (typeof tinyMCEPreInit == 'object') { - tinyMCEPreInit.mceInit["generate-sections-editor"] = this.tmc_settings; - tinyMCEPreInit.qtInit["generate-sections-editor"] = this.qt_settings; - tinyMCEPreInit.mceInit["generate-sections-editor"].wp_keep_scroll_position = false; - } - - try { - - var rich = (typeof tinyMCE != "undefined"); - - // turn on the quicktags editor - quicktags(this.qt_settings); - - // attempt to fix problem of quicktags toolbar with no buttons - QTags._buttonsInit(); - - if (rich !== false) { - // turn on tinyMCE - tinyMCE.init(this.tmc_settings); - } - - } catch (e) {} - - }, - - /** - * Launch Media Uploader - */ - openMediaUploader: function(e) { - - var _this = this; - - $input = jQuery(e.currentTarget).prev("#generate-sections-background-image"); - - e.preventDefault(); - - // If the uploader object has already been created, reopen the dialog - if (this.mediaUploader) { - this.mediaUploader.open(); - return; - } - // Extend the wp.media object - this.mediaUploader = wp.media.frames.file_frame = wp.media({ - title: generate_sections_metabox_i18n.media_library_title, - button: { - text: generate_sections_metabox_i18n.media_library_button - }, - multiple: false - }); - - - // When a file is selected, grab the URL and set it as the text field"s value - this.mediaUploader.on("select", function() { - - attachment = _this.mediaUploader.state().get("selection").first().toJSON(); - - $input.val(attachment.id); - - _this.renderPreview(attachment.id); - }); - // Open the uploader dialog - this.mediaUploader.open(); - - }, - - /** - * Remove the background image - */ - removeImage: function(e) { - e.preventDefault(); - $("#generate-section-image-preview").children().remove(); - $("#generate-section-image-preview").next().find(".generate-sections-remove-image").hide(); - $("#generate-sections-background-image").val(""); - }, - - - /** - * Closes the modal and cleans up after the instance. - * @param e {object} A jQuery-normalized event object. - */ - closeModal: function(e) { - "use strict"; - - e.preventDefault(); - this.undelegateEvents(); - jQuery(document).off("focusin"); - jQuery("body").removeClass("generate-modal-open"); - jQuery("body").removeClass("generate-section-content"); - - // remove restricted media modal tab focus once it's closed - this.$el.undelegate('keydown'); - - // remove the tinymce editor - // this needs to be called before the modal is closed or it will fail in Firefox (that was fun to figure out...) - if (typeof tinyMCE != "undefined") { - tinymce.EditorManager.execCommand("mceRemoveEditor", true, "generate-sections-editor"); - } - - // remove modal and unset instances - this.remove(); - Generate_Sections.backbone_modal.__instance = undefined; - this.mediaUploader = null; - Generate_Sections.modalOpen = null; - - // switch the insert button text back - this.changeInsertText(true); - - // send focus back to where it was prior to modal open - Generate_Sections.lastFocus.focus(); - - // aria unhide the background - jQuery("#wpwrap").attr("aria-hidden", "false"); - - // Fix bug where the window scrolls down 50px on close - var topDistance = jQuery("body").offset().top; - if ( topDistance >= jQuery("body").scrollTop() ) { - jQuery("body").scrollTop(0); - } - - }, - - /** - * Responds to the btn-ok.click event - * @param e {object} A jQuery-normalized event object. - * @todo You should make this your own. - */ - saveModal: function(e) { - "use strict"; - - this.model.get("index"); - - var model = this.model; - - // send the tinymce content to the textarea - if (typeof tinyMCE != "undefined") { - tinymce.triggerSave(); - } - - var $inputs = this.ui.panels.find("input, select, textarea"); - - $inputs.each(function(index, input) { - - var name = $(input).attr("name"); - - if (model.attributes.hasOwnProperty(name)) { - var value = $(input).val(); - model.set(name, value); - } - - }); - - this.closeModal(e); - }, - - /** - * Handles tab clicks and switches to corresponding panel - * @param e {object} A jQuery-normalized event object. - */ - switchTab: function(e) { - "use strict"; - e.preventDefault(); - - // close lingering wp link windows - if (typeof tinyMCE != "undefined" && 'style' == jQuery( e.currentTarget ).data( 'target' ) && this.ui.panels.find( '#wp-generate-sections-editor-wrap' ).hasClass( 'tmce-active' )) { - tinyMCE.activeEditor.execCommand('wp_link_cancel'); - tinyMCE.activeEditor.execCommand('wp_media_cancel'); - } - - this.ui.nav.children().removeClass("active"); - this.ui.panels.children().removeClass("active"); - - var target = jQuery(e.currentTarget).addClass("active").data("target"); - - this.ui.panels.find("div[data-id=" + target + "]").addClass("active"); - }, - - /** - * close on keyboard shortcuts - * @param {Object} event - */ - keydown: function(e) { - // Close the modal when escape is pressed. - if (27 === e.which && this.$el.is(':visible')) { - this.closeModal(e); - e.stopImmediatePropagation(); - } - } - - }); - - - // Singular View - Generate_Sections.sectionView = Backbone.View.extend({ - - model: Generate_Sections.Section, - tagName: 'div', - - initialize: function() { - // re-render on all changes EXCEPT index - this.listenTo(this.model, "change", this.maybeRender); - }, - - attributes: { - class: "ui-state-default section" - }, - - // Get the template from the DOM - template: wp.template("generate-sections-section"), - - events: { - 'click .edit-section': 'editSection', - 'click .section-title > span': 'editSection', - 'click .delete-section': 'removeSection', - 'click .toggle-section': 'toggleSection', - 'reorder': 'reorder', - }, - - maybeRender: function(e) { - if (this.model.hasChanged('index')) return; - this.render(); - }, - - // Render the single model - include an index. - render: function() { - this.model.set('index', this.model.collection.indexOf(this.model)); - this.$el.html(this.template(this.model.toJSON())); - - if (!this.model.get('title')) { - this.$el.find('h3.section-title > span').text(generate_sections_metabox_i18n.default_title); - } - this.$el.find('textarea').val(JSON.stringify(this.model)); - - return this; - }, - - - // launch the edit modal - editSection: function(e) { - - // stash the current focus - Generate_Sections.lastFocus = document.activeElement; - Generate_Sections.modalOpen = true; - - e.preventDefault(); - if (Generate_Sections.backbone_modal.__instance === undefined) { - Generate_Sections.backbone_modal.__instance = new Generate_Sections.backbone_modal.Application({ - model: this.model - }); - } - - }, - - // reorder after sort - reorder: function(event, index) { - this.$el.trigger('update-sort', [this.model, index]); - }, - - // remove/destroy a model - removeSection: function(e) { - e.preventDefault(); - if (confirm(generate_sections_metabox_i18n.confirm)) { - this.model.destroy(); - Generate_Sections.sectionList.render(); // manually calling instead of listening since listening interferes with sorting - } - }, - }); - - - // List View - Generate_Sections.sectionListView = Backbone.View.extend({ - - el: "#generate_sections_container", - events: { - 'update-sort': 'updateSort', - // 'add-section': 'addOne' - }, - - // callback for clone button - addSection: function(model) { - this.collection.add(model); - this.addOne(model); - }, - - addOne: function(model) { - var view = new Generate_Sections.sectionView({ - model: model - }); - this.$el.append(view.render().el); - }, - - render: function() { - this.$el.children().remove(); - this.collection.each(this.addOne, this); - return this; - }, - - updateSort: function(event, model, position) { - this.collection.remove(model); - - // renumber remaining models around missing model - this.collection.each(function(model, index) { - - var new_index = index; - if (index >= position) { - new_index += 1; - } - model.set('index', new_index); - }); - - // set the index of the missing model - model.set('index', position); - - // add the model back to the collection - this.collection.add(model, { - at: position - }); - - this.render(); - - }, - - }); - - - // The Buttons & Nonce - Generate_Sections.ButtonControls = Backbone.View.extend({ - - attributes: { - class: "generate_sections_buttons" - }, - - tagName: 'p', - - el: "#_generate_sections_metabox", - - template: wp.template("generate-sections-buttons"), - - // Attach events - events: { - "click .button-primary": "newSection", - "click #generate-delete-sections": "clearAll", - 'click .edit-section': 'editSection', - }, - - // create new - newSection: function(e) { - e.preventDefault(); - var newSection = new Generate_Sections.Section(); - Generate_Sections.sectionList.addSection(newSection); - }, - - // clear all models - clearAll: function(e) { - e.preventDefault(); - if (confirm(generate_sections_metabox_i18n.confirm)) { - Generate_Sections.sectionCollection.reset(); - Generate_Sections.sectionList.render(); - } - }, - - render: function() { - this.$el.find(".generate_sections_control").append(this.template); - return this; - }, - - }); - - - // init - Generate_Sections.initApplication = function() { - - // Create Collection From Existing Meta - Generate_Sections.sectionCollection = new Generate_Sections.SectionsCollection(generate_sections_metabox_i18n.sections); - - // Create the List View - Generate_Sections.sectionList = new Generate_Sections.sectionListView({ - collection: Generate_Sections.sectionCollection - }); - Generate_Sections.sectionList.render(); - - // Buttons - Generate_Sections.Buttons = new Generate_Sections.ButtonControls({ - collection: Generate_Sections.sectionCollection - }); - Generate_Sections.Buttons.render(); - - }; - - - /*-----------------------------------------------------------------------------------*/ - /* Execute the above methods in the Generate_Sections object. - /*-----------------------------------------------------------------------------------*/ - - jQuery(document).ready(function($) { - - Generate_Sections.initApplication(); - - $( '#generate_sections_container' ).sortable({ - axis: "y", - opacity: 0.5, - grid: [20, 10], - tolerance: "pointer", - handle: ".move-section", - update: function(event, ui) { - ui.item.trigger("reorder", ui.item.index()); - } - } ); - - if ( $( '.use-sections-switch' ).is( ':checked' ) ) { - setTimeout( function() { - generateShowSections(); - }, 200 ); - } else { - generateHideSections(); - } - - $( '.use-sections-switch' ).on( 'change', function( e ) { - var status = ( $(this).is( ':checked' ) ) ? 'checked' : 'unchecked'; - - if ( 'checked' == status ) { - generateShowSections(); - } else if ( 'unchecked' == status ) { - generateHideSections(); - } - } ); - - function generateShowSections() { - - // Hide send to editor button - $('.send-to-editor').css('display', 'none'); - - // Hide the editor - $('#postdivrich').css({ - 'opacity': '0', - 'height': '0', - 'overflow': 'hidden' - }); - - // Show the sections - $('#_generate_sections_metabox').css({ - 'opacity': '1', - 'height': 'auto' - }); - - // Remove and add the default editor - this removes any visible toolbars etc.. - // We need to set a timeout for this to work - // if (typeof tinyMCE != "undefined") { - // tinyMCE.EditorManager.execCommand("mceRemoveEditor", true, "content"); - // $( '.use-sections-cover' ).css( 'z-index','10000' ); - // setTimeout('tinyMCE.EditorManager.execCommand("mceAddEditor", true, "content");', 1); - // setTimeout('jQuery( ".use-sections-cover" ).css( "z-index","-1" );', 1000); - // } - - // Set a trigger - $('body').trigger('generate_show_sections'); - - } - - function generateHideSections() { - - // Show send to editor button - $('.send-to-editor').css('display', 'inline-block'); - - // Show the editor - $('#postdivrich').css({ - 'opacity': '1', - 'height': 'auto' - }); - - // Hide the sections - $('#_generate_sections_metabox').css({ - 'opacity': '0', - 'height': '0', - 'overflow': 'hidden' - }); - - $('body').trigger('generate_hide_sections'); - - } - - $( document ).on( 'click', '.edit-section.edit-settings', function() { - $( 'body' ).trigger( 'generate_section_show_settings' ); - }); - - }); - - -})(jQuery, Generate_Sections); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/js/generate-sections-metabox.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/js/generate-sections-metabox.js deleted file mode 100644 index 4c498070..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/js/generate-sections-metabox.js +++ /dev/null @@ -1,858 +0,0 @@ -/*-----------------------------------------------------------------------------------*/ -/* Generate Sections Metabox -/* -/* © Kathy Darling http://www.kathyisawesome.com -/* 2016-07-19. */ -/*-----------------------------------------------------------------------------------*/ - -/** - * @type {Object} JavaScript namespace for our application. - */ -var Generate_Sections = { - backbone_modal: { - __instance: undefined - } -}; - -(function($, Generate_Sections) { - - - // Model - Generate_Sections.Section = Backbone.Model.extend({ - defaults: { - "title": "", - "box_type": "", - "inner_box_type": "", - "custom_classes": "", - "custom_id": "", - "top_padding": "", - "bottom_padding": "", - "top_padding_unit": "", - "bottom_padding_unit": "", - "background_color": "", - "background_image": "", - "background_image_preview": "", - "parallax_effect": "", - "background_color_overlay": "", - "text_color": "", - "link_color": "", - "link_color_hover": "", - "content": "" - } - }); - - - // Collection - Generate_Sections.SectionsCollection = Backbone.Collection.extend({ - model: Generate_Sections.Section, - el: "#generate_sections_container", - comparator: function(model) { - return model.get('index'); - } - }); - - - /** - * Primary Modal Application Class - */ - Generate_Sections.backbone_modal.Application = Backbone.View.extend({ - - attributes: { - id: "generate-sections-modal-dialog", - class: "generate-sections-modal", - role: "dialog" - }, - - template: wp.template("generate-sections-modal-window"), - - mediaUploader: null, - - /*-----------------------------------------------------------------------------------*/ - /* tinyMCE settings - /*-----------------------------------------------------------------------------------*/ - - tmc_settings: {}, - - /*-----------------------------------------------------------------------------------*/ - /* tinyMCE defaults - /*-----------------------------------------------------------------------------------*/ - - tmc_defaults: { - theme: "modern", - menubar: false, - wpautop: true, - indent: false, - toolbar1: "bold,italic,underline,blockquote,strikethrough,bullist,numlist,alignleft,aligncenter,alignright,undo,redo,link,unlink,fullscreen", - plugins: "fullscreen,image,wordpress,wpeditimage,wplink", - max_height: 500 - }, - - /*-----------------------------------------------------------------------------------*/ - /* quicktags settings - /*-----------------------------------------------------------------------------------*/ - - qt_settings: {}, - - /*-----------------------------------------------------------------------------------*/ - /* quicktags defaults - /*-----------------------------------------------------------------------------------*/ - - qt_defaults: { - buttons: "strong,em,link,block,del,ins,img,ul,ol,li,code,more,close,fullscreen" - }, - - model: Generate_Sections.Section, - - events: { - "click .media-modal-backdrop, .media-modal-close, .media-button-close": "closeModal", - "click .media-button-insert": "saveModal", - "click .media-menu-item": "switchTab", - "keydown": "keydown", - "click .generate-sections-upload-button": "openMediaUploader", - "click .generate-sections-remove-image": "removeImage", - "click div.media-frame-title h1": "toggleMenu" - }, - - - - /** - * Simple object to store any UI elements we need to use over the life of the application. - */ - ui: { - nav: undefined, - content: undefined - }, - - - /** - * Instantiates the Template object and triggers load. - */ - initialize: function() { - _.bindAll(this, "render", "closeModal", "saveModal", "switchTab"); - - this.focusManager = new wp.media.view.FocusManager({ - el: this.el - }); - - this.changeInsertText(); - //this.tinyMCEsettings(); - this.render(); - }, - - /** - * switch the insert button text to "insert section" - */ - changeInsertText: function(restore) { - - var restore = typeof restore !== 'undefined' && restore == true ? true : false; - - if (restore == false && typeof(wp.media.view.l10n.insertIntoPost) !== "undefined") { - this.insertIntoPost = wp.media.view.l10n.insertIntoPost; - wp.media.view.l10n.insertIntoPost = generate_sections_metabox_i18n.insert_into_section; - // switch the insert button text back - } else if (restore == true && typeof(this.insertIntoPost) !== "undefined") { - wp.media.view.l10n.insertIntoPost = this.insertIntoPost; - } - }, - - /** - * Assembles the UI from loaded template. - * @internal Obviously, if the template fail to load, our modal never launches. - */ - render: function() { - - "use strict"; - - // Build the base window and backdrop, attaching them to the $el. - // Setting the tab index allows us to capture focus and redirect it in Application.preserveFocus - this.$el.attr("tabindex", "0").html(this.template); - - // Handle any attempt to move focus out of the modal. - //jQuery(document).on("focusin", this.preserveFocus); - - // set overflow to "hidden" on the body so that it ignores any scroll events while the modal is active - // and append the modal to the body. - jQuery("body").addClass("generate-modal-open").prepend(this.$el); - - // aria hide the background - jQuery("#wpwrap").attr("aria-hidden", "true"); - - this.renderContent(); - - this.renderPreview(); - - this.selected(); - this.colorPicker(); - //this.startTinyMCE(); - this.launchEditor(); - - // Set focus on the modal to prevent accidental actions in the underlying page - this.$el.focus(); - - return this; - }, - - launchEditor: function() { - var id = this.ui.panels.find( ".generate-sections-editor-wrap" ).find( 'textarea' ).attr( 'id' ), - customButtonsContainer = this.ui.panels.find( '.generate-sections-editor-wrap' ).find( '#custom-media-buttons' ); - - customButtonsContainer.find( '.insert-media' ).remove(); - var customButtons = customButtonsContainer.html(); - customButtonsContainer.remove(); - - var init_settings = true; - - if ( typeof tinyMCEPreInit == "object" && "mceInit" in tinyMCEPreInit && "content" in tinyMCEPreInit.mceInit ) { - init_settings = tinyMCEPreInit.mceInit.content; - } else if ( typeof window.wpEditorL10n !== "undefined" ) { - init_settings = window.wpEditorL10n.tinymce.settings; - } else { - init_settings = this.tmc_defaults; - } - - var thisPanel = this.ui.panels; - - var custom_settings = { - wp_autoresize_on: false, - cache_suffix: "", - min_height: 400, - wp_keep_scroll_position: false, - setup: function( editor ) { - editor.on( 'init', function( e ) { - if ( 'html-active' === generate_sections_metabox_i18n.default_editor && generate_sections_metabox_i18n.user_can_richedit ) { - thisPanel.find( '#wp-generate-sections-editor-wrap' ).removeClass( 'tmce-active' ).addClass( 'html-active' ); - editor.hidden = true; - } - } ); - } - } - - init_settings = $.extend({}, init_settings, custom_settings); - - var qt_settings = true; - - if ( typeof tinyMCEPreInit == "object" && "qtInit" in tinyMCEPreInit && "content" in tinyMCEPreInit.qtInit ) { - qt_settings = tinyMCEPreInit.qtInit.content; - } else { - qt_settings = this.qt_defaults; - } - - if ( ! generate_sections_metabox_i18n.user_can_richedit ) { - init_settings = false; - } - - wp.sectionsEditor.initialize( id, { - tinymce: init_settings, - quicktags: qt_settings, - mediaButtons: true - } ); - - var buttonsElement = this.ui.panels.find( '#wp-generate-sections-editor-wrap' ).find( '.wp-media-buttons' ); - buttonsElement.attr( 'id', 'custom-media-buttons' ); - $( customButtons ).appendTo( buttonsElement ); - - if ( ! generate_sections_metabox_i18n.user_can_richedit ) { - this.ui.panels.find( '#generate-sections-editor' ).addClass( 'no-rich-edit' ); - } - }, - - /** - * Make the menu mobile-friendly - */ - toggleMenu: function() { - this.$el.find('.media-menu').toggleClass('visible'); - }, - - /** - * Create the nav tabs & panels - */ - renderContent: function() { - - var model = this.model; - - var menu_item = wp.template("generate-sections-modal-menu-item"); - - // Save a reference to the navigation bar"s unordered list and populate it with items. - this.ui.nav = this.$el.find(".media-menu"); - - // reference to content area - this.ui.panels = this.$el.find(".media-frame-content"); - - // loop through the tabs - if (generate_sections_metabox_i18n.tabs.length) { - - // for...of is nicer, but not supported by minify, so stay with for...in for now - for (var tab in generate_sections_metabox_i18n.tabs) { - - if (generate_sections_metabox_i18n.tabs.hasOwnProperty(tab)) { - - tab = generate_sections_metabox_i18n.tabs[tab]; - - var $new_tab = $(menu_item({ - target: tab.target, - name: tab.title - })); - - var panel = wp.template("generate-sections-edit-" + tab.target); - - var $new_panel = $(panel(model.toJSON())); - - if (tab.active == "true") { - $new_tab.addClass("active"); - $new_panel.addClass("active"); - } - - jQuery( 'body' ).on( 'generate_section_show_settings', function() { - jQuery( '.generate-sections-modal .media-menu-item' ).removeClass('active'); - jQuery( '.generate-sections-modal .panel' ).removeClass('active'); - jQuery( '.generate-section-item-style' ).addClass('active'); - jQuery( '.generate-section-settings' ).addClass('active'); - }); - - this.ui.nav.append($new_tab); - this.ui.panels.append($new_panel); - } - } - } - - }, - - - /** - * Render the background image preview - */ - renderPreview: function(image_id) { - - var image_id = typeof image_id !== 'undefined' ? image_id : this.model.get("background_image"); - - var $preview = $("#generate-section-image-preview"); - $preview.children().remove(); - - if (image_id > 0) { - this.background = new wp.media.model.Attachment.get(image_id); - - this.background.fetch({ - success: function(att) { - if (_.contains(['png', 'jpg', 'gif', 'jpeg'], att.get('subtype'))) { - $("").attr("src", att.attributes.sizes.thumbnail.url).appendTo($preview); - $preview.next().find(".generate-sections-remove-image").show(); - } - } - }); - } - - }, - - - /** - * Set the default option for the select boxes - */ - selected: function() { - - var _this = this; - - this.$el.find("select").each(function(index, select) { - - var attribute = jQuery(select).attr("name"); - var selected = _this.model.get(attribute); - jQuery(select).val(selected); - - }); - }, - - /** - * Start the colorpicker - */ - colorPicker: function() { - this.$el.find(".generate-sections-color").wpColorPicker(); - }, - - /** - * Launch Media Uploader - */ - openMediaUploader: function(e) { - - var _this = this; - - $input = jQuery(e.currentTarget).prev("#generate-sections-background-image"); - - e.preventDefault(); - - // If the uploader object has already been created, reopen the dialog - if (this.mediaUploader) { - this.mediaUploader.open(); - return; - } - // Extend the wp.media object - this.mediaUploader = wp.media.frames.file_frame = wp.media({ - title: generate_sections_metabox_i18n.media_library_title, - button: { - text: generate_sections_metabox_i18n.media_library_button - }, - multiple: false - }); - - - // When a file is selected, grab the URL and set it as the text field"s value - this.mediaUploader.on("select", function() { - - attachment = _this.mediaUploader.state().get("selection").first().toJSON(); - - $input.val(attachment.id); - - _this.renderPreview(attachment.id); - }); - // Open the uploader dialog - this.mediaUploader.open(); - - }, - - /** - * Remove the background image - */ - removeImage: function(e) { - e.preventDefault(); - $("#generate-section-image-preview").children().remove(); - $("#generate-section-image-preview").next().find(".generate-sections-remove-image").hide(); - $("#generate-sections-background-image").val(""); - }, - - - /** - * Closes the modal and cleans up after the instance. - * @param e {object} A jQuery-normalized event object. - */ - closeModal: function(e) { - "use strict"; - - e.preventDefault(); - this.undelegateEvents(); - jQuery(document).off("focusin"); - jQuery("body").removeClass("generate-modal-open"); - jQuery("body").removeClass("generate-section-content"); - - // remove restricted media modal tab focus once it's closed - this.$el.undelegate('keydown'); - - // remove the tinymce editor - // this needs to be called before the modal is closed or it will fail in Firefox (that was fun to figure out...) - if (typeof tinyMCE != "undefined") { - tinymce.EditorManager.execCommand("mceRemoveEditor", true, "generate-sections-editor"); - } - - // remove modal and unset instances - this.remove(); - Generate_Sections.backbone_modal.__instance = undefined; - this.mediaUploader = null; - Generate_Sections.modalOpen = null; - - // switch the insert button text back - this.changeInsertText(true); - - // send focus back to where it was prior to modal open - Generate_Sections.lastFocus.focus(); - - // aria unhide the background - jQuery("#wpwrap").attr("aria-hidden", "false"); - - // Fix bug where the window scrolls down 50px on close - var topDistance = jQuery("body").offset().top; - if ( topDistance >= jQuery("body").scrollTop() ) { - jQuery("body").scrollTop(0); - } - - }, - - /** - * Responds to the btn-ok.click event - * @param e {object} A jQuery-normalized event object. - * @todo You should make this your own. - */ - saveModal: function(e) { - "use strict"; - - this.model.get("index"); - - var model = this.model; - - // send the tinymce content to the textarea - if (typeof tinyMCE != "undefined") { - tinymce.triggerSave(); - } - - var $inputs = this.ui.panels.find("input, select, textarea"); - - $inputs.each(function(index, input) { - - var name = $(input).attr("name"); - - if (model.attributes.hasOwnProperty(name)) { - var value = $(input).val(); - model.set(name, value); - } - - }); - - this.closeModal(e); - }, - - /** - * Handles tab clicks and switches to corresponding panel - * @param e {object} A jQuery-normalized event object. - */ - switchTab: function(e) { - "use strict"; - e.preventDefault(); - - // close lingering wp link windows - if (typeof tinyMCE != "undefined" && 'style' == jQuery( e.currentTarget ).data( 'target' ) && this.ui.panels.find( '#wp-generate-sections-editor-wrap' ).hasClass( 'tmce-active' )) { - tinyMCE.activeEditor.execCommand('wp_link_cancel'); - tinyMCE.activeEditor.execCommand('wp_media_cancel'); - } - - this.ui.nav.children().removeClass("active"); - this.ui.panels.children().removeClass("active"); - - var target = jQuery(e.currentTarget).addClass("active").data("target"); - - this.ui.panels.find("div[data-id=" + target + "]").addClass("active"); - }, - - /** - * close on keyboard shortcuts - * @param {Object} event - */ - keydown: function(e) { - // Close the modal when escape is pressed. - if (27 === e.which && this.$el.is(':visible')) { - this.closeModal(e); - e.stopImmediatePropagation(); - } - } - - }); - - - // Singular View - Generate_Sections.sectionView = Backbone.View.extend({ - - model: Generate_Sections.Section, - tagName: 'div', - - initialize: function() { - // re-render on all changes EXCEPT index - this.listenTo(this.model, "change", this.maybeRender); - }, - - attributes: { - class: "ui-state-default section" - }, - - // Get the template from the DOM - template: wp.template("generate-sections-section"), - - events: { - 'click .edit-section': 'editSection', - 'click .section-title > span': 'editSection', - 'click .delete-section': 'removeSection', - 'click .toggle-section': 'toggleSection', - 'reorder': 'reorder', - }, - - maybeRender: function(e) { - if (this.model.hasChanged('index')) return; - this.render(); - }, - - // Render the single model - include an index. - render: function() { - this.model.set('index', this.model.collection.indexOf(this.model)); - this.$el.html(this.template(this.model.toJSON())); - - if (!this.model.get('title')) { - this.$el.find('h3.section-title > span').text(generate_sections_metabox_i18n.default_title); - } - this.$el.find('textarea').val(JSON.stringify(this.model)); - - return this; - }, - - - // launch the edit modal - editSection: function(e) { - - // stash the current focus - Generate_Sections.lastFocus = document.activeElement; - Generate_Sections.modalOpen = true; - - e.preventDefault(); - if (Generate_Sections.backbone_modal.__instance === undefined) { - Generate_Sections.backbone_modal.__instance = new Generate_Sections.backbone_modal.Application({ - model: this.model - }); - } - - }, - - // reorder after sort - reorder: function(event, index) { - this.$el.trigger('update-sort', [this.model, index]); - }, - - // remove/destroy a model - removeSection: function(e) { - e.preventDefault(); - if (confirm(generate_sections_metabox_i18n.confirm)) { - this.model.destroy(); - Generate_Sections.sectionList.render(); // manually calling instead of listening since listening interferes with sorting - } - }, - }); - - - // List View - Generate_Sections.sectionListView = Backbone.View.extend({ - - el: "#generate_sections_container", - events: { - 'update-sort': 'updateSort', - // 'add-section': 'addOne' - }, - - // callback for clone button - addSection: function(model) { - this.collection.add(model); - this.addOne(model); - }, - - addOne: function(model) { - var view = new Generate_Sections.sectionView({ - model: model - }); - this.$el.append(view.render().el); - }, - - render: function() { - this.$el.children().remove(); - this.collection.each(this.addOne, this); - return this; - }, - - updateSort: function(event, model, position) { - this.collection.remove(model); - - // renumber remaining models around missing model - this.collection.each(function(model, index) { - - var new_index = index; - if (index >= position) { - new_index += 1; - } - model.set('index', new_index); - }); - - // set the index of the missing model - model.set('index', position); - - // add the model back to the collection - this.collection.add(model, { - at: position - }); - - this.render(); - - }, - - }); - - - // The Buttons & Nonce - Generate_Sections.ButtonControls = Backbone.View.extend({ - - attributes: { - class: "generate_sections_buttons" - }, - - tagName: 'p', - - el: "#_generate_sections_metabox", - - template: wp.template("generate-sections-buttons"), - - // Attach events - events: { - "click .button-primary": "newSection", - "click #generate-delete-sections": "clearAll", - 'click .edit-section': 'editSection', - }, - - // create new - newSection: function(e) { - e.preventDefault(); - var newSection = new Generate_Sections.Section(); - Generate_Sections.sectionList.addSection(newSection); - }, - - // clear all models - clearAll: function(e) { - e.preventDefault(); - if (confirm(generate_sections_metabox_i18n.confirm)) { - Generate_Sections.sectionCollection.reset(); - Generate_Sections.sectionList.render(); - } - }, - - render: function() { - this.$el.find(".generate_sections_control").append(this.template); - return this; - }, - - }); - - - // init - Generate_Sections.initApplication = function() { - - // Create Collection From Existing Meta - Generate_Sections.sectionCollection = new Generate_Sections.SectionsCollection(generate_sections_metabox_i18n.sections); - - // Create the List View - Generate_Sections.sectionList = new Generate_Sections.sectionListView({ - collection: Generate_Sections.sectionCollection - }); - Generate_Sections.sectionList.render(); - - // Buttons - Generate_Sections.Buttons = new Generate_Sections.ButtonControls({ - collection: Generate_Sections.sectionCollection - }); - Generate_Sections.Buttons.render(); - - }; - - - /*-----------------------------------------------------------------------------------*/ - /* Execute the above methods in the Generate_Sections object. - /*-----------------------------------------------------------------------------------*/ - - jQuery( function( $ ) { - - Generate_Sections.initApplication(); - - $( '#generate_sections_container' ).sortable({ - axis: "y", - opacity: 0.5, - grid: [20, 10], - tolerance: "pointer", - handle: ".move-section", - update: function(event, ui) { - ui.item.trigger("reorder", ui.item.index()); - } - } ); - - if ( $( '.use-sections-switch' ).is( ':checked' ) ) { - setTimeout( function() { - generateShowSections(); - }, 200 ); - } else { - generateHideSections(); - } - - $( '.use-sections-switch' ).on( 'change', function( e ) { - var status = ( $(this).is( ':checked' ) ) ? 'checked' : 'unchecked'; - - if ( 'checked' == status ) { - generateShowSections(); - } else if ( 'unchecked' == status ) { - generateHideSections(); - } - } ); - - function generateShowSections() { - - // Hide send to editor button - $('.send-to-editor').css('display', 'none'); - - // Hide the editor - $('#postdivrich').css({ - 'opacity': '0', - 'height': '0', - 'overflow': 'hidden' - }); - - $( '.block-editor-block-list__layout' ).hide(); - - $( '.edit-post-layout .edit-post-visual-editor' ).css( { - 'flex-grow': 'unset', - 'flex-basis': '0' - } ); - - $( '.edit-post-visual-editor .block-editor-writing-flow__click-redirect' ).css( { - 'min-height': '0' - } ); - - $( '.edit-post-layout__metaboxes:not(:empty)' ).css( 'border-top', '0' ); - - // Show the sections - $('#_generate_sections_metabox').css({ - 'opacity': '1', - 'height': 'auto' - }); - - // Remove and add the default editor - this removes any visible toolbars etc.. - // We need to set a timeout for this to work - // if (typeof tinyMCE != "undefined") { - // tinyMCE.EditorManager.execCommand("mceRemoveEditor", true, "content"); - // $( '.use-sections-cover' ).css( 'z-index','10000' ); - // setTimeout('tinyMCE.EditorManager.execCommand("mceAddEditor", true, "content");', 1); - // setTimeout('jQuery( ".use-sections-cover" ).css( "z-index","-1" );', 1000); - // } - - // Set a trigger - $('body').trigger('generate_show_sections'); - - } - - function generateHideSections() { - - // Show send to editor button - $('.send-to-editor').css('display', 'inline-block'); - - // Show the editor - $('#postdivrich').css({ - 'opacity': '1', - 'height': 'auto' - }); - - $( '.block-editor-block-list__layout' ).show(); - - $( '.edit-post-layout .edit-post-visual-editor' ).css( { - 'flex-grow': '', - 'flex-basis': '' - } ); - - $( '.edit-post-visual-editor .block-editor-writing-flow__click-redirect' ).css( { - 'min-height': '' - } ); - - $( '.edit-post-layout__metaboxes:not(:empty)' ).css( 'border-top', '' ); - - // Hide the sections - $('#_generate_sections_metabox').css({ - 'opacity': '0', - 'height': '0', - 'overflow': 'hidden' - }); - - $('body').trigger('generate_hide_sections'); - - } - - $( document ).on( 'click', '.edit-section.edit-settings', function() { - $( 'body' ).trigger( 'generate_section_show_settings' ); - }); - - }); - - -})(jQuery, Generate_Sections); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/metabox-functions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/metabox-functions.php deleted file mode 100644 index 402614ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/metabox-functions.php +++ /dev/null @@ -1,396 +0,0 @@ -ID, '_generate_use_sections', TRUE) : ''; - - if ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) { - $classes .= ' generate-sections-enabled'; - } - - return $classes; - } -} - -if ( ! function_exists( 'generate_sections_content_width' ) ) { - add_action( 'wp', 'generate_sections_content_width', 50 ); - /** - * Set our content width when sections are enabled - */ - function generate_sections_content_width() { - global $post; - $use_sections = ( isset( $post ) ) ? get_post_meta( $post->ID, '_generate_use_sections', TRUE) : ''; - - if ( isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ) { - global $content_width; - $content_width = 2000; - } - } -} - -if ( ! function_exists( 'generate_sections_add_metaboxes' ) ) { - add_action( 'add_meta_boxes', 'generate_sections_add_metaboxes', 5 ); - /* - * Functions for creating the metaboxes - */ - function generate_sections_add_metaboxes() { - - $post_types = apply_filters( 'generate_sections_post_types', array( 'page', 'post' ) ); - - add_meta_box( - '_generate_use_sections_metabox', - __( 'Sections', 'gp-premium' ), - 'generate_sections_use_sections_metabox', - $post_types, - 'side', - 'high' - ); - - add_meta_box( - '_generate_sections_metabox', - __( 'Sections', 'gp-premium' ), - 'generate_sections_sections_metabox', - $post_types, - 'normal', - 'high' - ); - - } -} - -if ( ! function_exists( 'generate_sections_sanitize_function' ) ) { - /* - * Sanitize our settings - */ - function generate_sections_sanitize_function( $data, $post_id ) { - - $section = array(); - - if ( isset( $data['title'] ) ) { - $section['title'] = sanitize_text_field( $data['title'] ); - } - - if ( isset( $data['content'] ) ) { - $section['content'] = sanitize_post_field( 'post_content', $data['content'], $post_id, 'db' ); - } - - if ( isset( $data['custom_classes'] ) ) { - $section['custom_classes'] = sanitize_text_field( $data['custom_classes'] ); - } - - if ( isset( $data['custom_id'] ) ) { - $section['custom_id'] = sanitize_text_field( $data['custom_id'] ); - } - - if ( isset( $data['top_padding'] ) ) { - $section['top_padding'] = '' == $data['top_padding'] ? $data['top_padding'] : absint( $data['top_padding'] ); - } - - if ( isset( $data['bottom_padding'] ) ) { - $section['bottom_padding'] = '' == $data['bottom_padding'] ? $data['bottom_padding'] : absint( $data['bottom_padding'] ); - } - - if ( isset( $data['top_padding_unit'] ) ) { - $section['top_padding_unit'] = $data['top_padding_unit'] == '%' ? '%' : ''; - } - - if ( isset( $data['bottom_padding_unit'] ) ) { - $section['bottom_padding_unit'] = $data['bottom_padding_unit'] == '%' ? '%' : ''; - } - - if ( isset( $data['background_image'] ) ) { - $section['background_image'] = absint( $data['background_image'] ); - } - - if ( isset( $data['background_color'] ) ) { - $section['background_color'] = generate_sections_sanitize_rgba( $data['background_color'] ); - } - - if ( isset( $data['text_color'] ) ) { - $section['text_color'] = generate_sections_sanitize_hex_color( $data['text_color'] ); - } - - if ( isset( $data['link_color'] ) ) { - $section['link_color'] = generate_sections_sanitize_hex_color( $data['link_color'] ); - } - - if ( isset( $data['link_color_hover'] ) ) { - $section['link_color_hover'] = generate_sections_sanitize_hex_color( $data['link_color_hover'] ); - } - - if ( isset( $data['box_type'] ) ) { - $section['box_type'] = $data['box_type'] == 'contained' ? 'contained' : ''; - } - - if ( isset( $data['inner_box_type'] ) ) { - $section['inner_box_type'] = $data['inner_box_type'] == 'fluid' ? 'fluid' : ''; - } - - if ( isset( $data['parallax_effect'] ) ) { - $section['parallax_effect'] = $data['parallax_effect'] == 'enable' ? 'enable' : ''; - } - - if ( isset( $data['background_color_overlay'] ) ) { - $section['background_color_overlay'] = $data['background_color_overlay'] == 'enable' ? 'enable' : ''; - } - - return $section; - - } -} - -if ( ! function_exists( 'generate_sections_metabox_scripts' ) ) { - add_action( 'admin_enqueue_scripts', 'generate_sections_metabox_scripts', 20 ); - /* - * Enqueue styles and scripts specific to metaboxs - */ - function generate_sections_metabox_scripts( $hook ) { - // I prefer to enqueue the styles only on pages that are using the metaboxes - if ( in_array( $hook, array( "post.php", "post-new.php" ) ) ) { - - $post_types = apply_filters( 'generate_sections_post_types', array( 'page', 'post' ) ); - - $screen = get_current_screen(); - $post_type = $screen->id; - - if ( in_array( $post_type, (array) $post_types ) ) { - wp_enqueue_style( 'generate-sections-metabox', plugin_dir_url( __FILE__ ) . 'css/generate-sections-metabox.css', false, GENERATE_SECTIONS_VERSION ); - wp_enqueue_style( 'generate-lc-switch', plugin_dir_url( __FILE__ ) . 'css/lc_switch.css', false, GENERATE_SECTIONS_VERSION ); - - //make sure we enqueue some scripts just in case ( only needed for repeating metaboxes ) - wp_enqueue_script( 'jquery' ); - wp_enqueue_script( 'jquery-ui-core' ); - wp_enqueue_script( 'jquery-ui-widget' ); - wp_enqueue_script( 'jquery-ui-mouse' ); - wp_enqueue_script( 'jquery-ui-sortable' ); - wp_enqueue_script( 'editor' ); - wp_enqueue_script( 'media-upload' ); - wp_enqueue_script( 'wp-color-picker' ); - wp_enqueue_style( 'wp-color-picker' ); - wp_enqueue_script( 'wp-color-picker-alpha', GP_LIBRARY_DIRECTORY_URL . 'alpha-color-picker/wp-color-picker-alpha.min.js', array( 'wp-color-picker' ), '3.0.0', true ); - - wp_add_inline_script( - 'wp-color-picker-alpha', - 'jQuery( function() { jQuery( ".color-picker" ).wpColorPicker(); } );' - ); - - wp_enqueue_media(); - - if ( function_exists( 'wp_enqueue_editor' ) ) { - wp_enqueue_editor(); - - wp_add_inline_script( - 'editor', - 'window.wp.sectionsEditor = window.wp.editor;', - 'after' - ); - } - - if ( version_compare( get_bloginfo( 'version' ), '5.0', '<' ) ) { - wp_enqueue_script( 'generate-sections-metabox', plugin_dir_url( __FILE__ ) . 'js/generate-sections-metabox-4.9.js', array( 'jquery', 'jquery-ui-core', 'jquery-ui-widget', 'jquery-ui-mouse', 'jquery-ui-sortable', 'editor', 'media-upload', 'wp-color-picker' ), GENERATE_SECTIONS_VERSION, true ); - } else { - wp_enqueue_script( 'generate-sections-metabox', plugin_dir_url( __FILE__ ) . 'js/generate-sections-metabox.js', array( 'jquery', 'jquery-ui-core', 'jquery-ui-widget', 'jquery-ui-mouse', 'jquery-ui-sortable', 'editor', 'media-upload', 'wp-color-picker' ), GENERATE_SECTIONS_VERSION, true ); - } - - if ( function_exists( 'wp_add_inline_script' ) ) { - if ( function_exists( 'generate_get_default_color_palettes' ) ) { - // Grab our palette array and turn it into JS - $palettes = json_encode( generate_get_default_color_palettes() ); - - // Add our custom palettes - // json_encode takes care of escaping - wp_add_inline_script( 'wp-color-picker', 'jQuery.wp.wpColorPicker.prototype.options.palettes = ' . $palettes . ';' ); - } - } - } - } - } -} - -if ( ! function_exists( 'generate_sections_admin_footer_scripts' ) ) { - add_action( 'admin_footer', 'generate_sections_admin_footer_scripts' ); - - function generate_sections_admin_footer_scripts() { - // We don't need this if wp_add_inline_script exists - if ( function_exists( 'wp_add_inline_script' ) ) { - return; - } - ?> - - ID, '_generate_sections', true ); - - $sections = isset( $meta['sections'] ) && is_array( $meta['sections' ] ) ? $meta['sections'] : array(); - - $translation_array = array( - 'confirm' => __( 'This action can not be undone, are you sure?', 'gp-premium' ), - 'post_id' => $post->ID, - 'sections' => $sections, - 'default_title' => __( 'Section', 'gp-premium' ), - 'default_content_title' => __( 'Content', 'gp-premium' ), - 'tabs' => array( - array( 'title' => __( 'Settings', 'gp-premium' ), 'target' => 'style', 'active' => 'false' ), - array( 'title' => __( 'Content', 'gp-premium' ), 'target' => 'content', 'active' => 'true' ), - //array( 'title' => __( 'Layout', 'gp-premium' ), 'target' => 'layout', 'active' => 'false' ), - ), - 'top_padding' => apply_filters( 'generate_sections_default_padding_top','40' ), - 'bottom_padding' => apply_filters( 'generate_sections_default_padding_bottom','40' ), - 'media_library_title' => __('Section Background', 'gp-premium' ), - 'media_library_button' => __( 'Set as Section Background', 'gp-premium' ), - 'generate_nonce' => wp_create_nonce( 'generate_sections_nonce' ), - 'default_editor' => user_can_richedit() && wp_default_editor() == 'tinymce' ? 'tmce-active' : 'html-active', - 'user_can_richedit' => user_can_richedit(), - 'insert_into_section' => __( 'Insert into Section', 'gp-premium' ), - 'edit_section' => __( 'Edit Section', 'gp-premium' ) - - ); - wp_localize_script( 'generate-sections-metabox', 'generate_sections_metabox_i18n', $translation_array ); - - include_once( plugin_dir_path( __FILE__ ) . 'views/sections.php' ); - include_once( plugin_dir_path( __FILE__ ) . 'views/sections-template.php' ); - add_action( 'print_media_templates', 'generate_sections_print_templates' ); - - do_action( 'generate_sections_metabox' ); - } -} - -if ( ! function_exists( 'generate_sections_save_use_metabox' ) ) { - add_action( 'save_post', 'generate_sections_save_use_metabox' ); - /* - * Save the "use" metabox - */ - function generate_sections_save_use_metabox( $post_id ) { - if ( ! isset( $_POST['_generate_sections_use_sections_nonce'] ) || ! wp_verify_nonce( $_POST['_generate_sections_use_sections_nonce'], 'generate_sections_use_sections_nonce' ) ) { - return $post_id; - } - - if ( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE ) { - return $post_id; - } - - if ( ! current_user_can('edit_post', $post_id ) ) { - return $post_id; - } - - if ( isset ( $_POST['_generate_use_sections'] ) && isset ( $_POST['_generate_use_sections']['use_sections'] ) && $_POST['_generate_use_sections']['use_sections'] == 'true' ) { - update_post_meta( $post_id, '_generate_use_sections', array( 'use_sections' => 'true' ) ); - } else { - delete_post_meta( $post_id, '_generate_use_sections' ); - } - } -} - -if ( ! function_exists( 'generate_sections_save_sections_metabox' ) ) { - add_action( 'save_post', 'generate_sections_save_sections_metabox', 20 ); - /* - * Save the sections metabox - */ - function generate_sections_save_sections_metabox( $post_id ) { - - if ( ! isset( $_POST['_generate_sections_nonce'] ) || ! wp_verify_nonce( $_POST['_generate_sections_nonce'], 'generate_sections_nonce' ) ) { - return $post_id; - } - - if ( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE ) { - return $post_id; - } - - if ( ! current_user_can('edit_post', $post_id ) ) { - return $post_id; - } - - $clean = array(); - - if ( isset ( $_POST['_generate_sections'] ) && isset( $_POST['_generate_sections']['sections'] ) && is_array( $_POST['_generate_sections']['sections'] ) ) { - - foreach( $_POST['_generate_sections']['sections'] as $section ) { - - $section = json_decode( stripslashes( trim($section) ), true); - - $section = generate_sections_sanitize_function( $section, $post_id ); - if ( ! empty( $section ) ){ - $clean[] = $section; - } - - } - - } - - // save data - if ( ! empty( $clean ) ) { - // this maintains data structure of previous version - $meta = array( 'sections' => $clean ); - update_post_meta( $post_id, '_generate_sections', $meta ); - } else { - delete_post_meta( $post_id, '_generate_sections' ); - } - - } -} - -if ( ! function_exists( 'generate_sections_sanitize_hex_color' ) ) { - /* - * Sanitize colors - * We don't use the built in function so we can use empty values - */ - function generate_sections_sanitize_hex_color( $color ) { - if ( '' === $color ) { - return ''; - } - - // 3 or 6 hex digits, or the empty string. - if ( preg_match('|^#([A-Fa-f0-9]{3}){1,2}$|', $color ) ) { - return $color; - } - - return null; - } -} - -if ( ! function_exists( 'generate_sections_sanitize_rgba' ) ) { - /** - * Sanitize RGBA colors - * @since 1.3.42 - */ - function generate_sections_sanitize_rgba( $color ) { - if ( '' === $color ) { - return ''; - } - - // If string does not start with 'rgba', then treat as hex - // sanitize the hex color and finally convert hex to rgba - if ( false === strpos( $color, 'rgba' ) ) { - return generate_sections_sanitize_hex_color( $color ); - } - - // By now we know the string is formatted as an rgba color so we need to further sanitize it. - $color = str_replace( ' ', '', $color ); - sscanf( $color, 'rgba(%d,%d,%d,%f)', $red, $green, $blue, $alpha ); - return 'rgba('.$red.','.$green.','.$blue.','.$alpha.')'; - - return ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/views/sections-template.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/views/sections-template.php deleted file mode 100644 index 4fd904bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/views/sections-template.php +++ /dev/null @@ -1,279 +0,0 @@ - - - - - - - - - - - - - - - - - - - - -
            - - - -
            - -
            \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/views/use-sections.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/views/use-sections.php deleted file mode 100644 index d2aa993f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/metaboxes/views/use-sections.php +++ /dev/null @@ -1,17 +0,0 @@ - -
            - - ID, '_generate_use_sections', true ); - //$use_sections = isset( $use_sections['use_sections'] ) && 'true' == $use_sections['use_sections'] ? true : false; - wp_nonce_field( 'generate_sections_use_sections_nonce', '_generate_sections_use_sections_nonce' ); - ?> - -
            diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/templates/template.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/templates/template.php deleted file mode 100644 index daf0d21e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/sections/functions/templates/template.php +++ /dev/null @@ -1,122 +0,0 @@ -ID, '_generate_sections', TRUE) : ''; -$sidebars = apply_filters( 'generate_sections_sidebars', false ); -?> - -
            > -
            > - - - -
            > -
            -
            - -
            -
            -
            - - - - '; - $container['after'] = '
            '; - else : - $container['before'] = '
            '; - $container['after'] = '
            '; - endif; - - // Create inner container - if ( 'fluid' == $inner_box_type ) : - $inner_container['before'] = '
            '; - $inner_container['after'] = '
            '; - else : - $inner_container['before'] = '
            '; - $inner_container['after'] = '
            '; - endif; - - // Output the container - $return .= $container['before']; - $return .= $inner_container['before']; - - // Output the content - // Add \n\n to fix issue where paragraph wrapping was off - $return .= "\n\n" . $content; - - // Output the closing containers - $return .= $container['after']; - $return .= $inner_container['after']; - - endforeach; - - // Return our sections through the_content filter - echo apply_filters( 'the_content', $return ); - else : - ?> -
            -
            - -
            -
            - - - - - - - - - $widgets ) { - // Skip inactive widgets (should not be in export file). - if ( 'wp_inactive_widgets' === $sidebar_id ) { - continue; - } - - if ( is_array( $widgets ) ) { - foreach ( $widgets as $widget_instance_id => $widget ) { - $all_widgets[] = $widget; - } - } - } - - $results['wp_inactive_widgets'] = $all_widgets; - - update_option( 'sidebars_widgets', $results ); - - } - - /** - * Checks to see whether options exist or not. - * - * @since 1.8 - * - * @return bool - */ - public static function do_options_exist() { - $theme_mods = self::get_theme_mods(); - $settings = self::get_theme_settings(); - - $has_data = array( - 'mods' => array(), - 'options' => array(), - ); - - foreach ( $theme_mods as $theme_mod ) { - if ( get_theme_mod( $theme_mod ) ) { - $has_data['mods'][ $theme_mod ] = get_theme_mod( $theme_mod ); - } - } - - foreach ( $settings as $setting ) { - if ( get_option( $setting ) ) { - - // The blog module runs a migration script on activation for now. This checks if those migrated values have been changed. - if ( 'generate_blog_settings' === $setting && function_exists( 'generate_blog_get_defaults' ) ) { - $defaults = generate_blog_get_defaults(); - $options = get_option( $setting ); - $diff = array(); - - foreach ( $options as $option => $value ) { - if ( isset( $defaults[ $option ] ) && $value !== $defaults[ $option ] ) { - $diff[ $option ] = $value; - } - } - - if ( empty( $diff ) ) { - continue; - } - } - - $has_data['options'][ $setting ] = get_option( $setting ); - } - } - - if ( ! array_filter( $has_data ) ) { - return false; - } else { - return true; - } - } - - /** - * Imports our content and custom CSS. - * - * @since 1.6 - * @param string $path Path to the file. - * @param string $slug File slug. - */ - public static function import_xml( $path, $slug ) { - if ( ! class_exists( 'WP_Importer' ) ) { - require_once ABSPATH . '/wp-admin/includes/class-wp-importer.php'; - } - - require_once GP_PREMIUM_DIR_PATH . 'site-library/libs/wxr-importer/WXRImporter.php'; - require_once GP_PREMIUM_DIR_PATH . 'site-library/libs/wxr-importer/WPImporterLogger.php'; - require_once GP_PREMIUM_DIR_PATH . 'site-library/libs/wxr-importer/WXRImportInfo.php'; - require_once GP_PREMIUM_DIR_PATH . 'site-library/classes/class-content-importer.php'; - - if ( ! function_exists( 'wp_crop_image' ) ) { - require_once ABSPATH . 'wp-admin/includes/image.php'; - } - - add_filter( 'upload_mimes', array( __CLASS__, 'mime_types' ) ); - add_filter( 'wp_check_filetype_and_ext', array( __CLASS__, 'check_real_mime_type' ), 10, 4 ); - add_filter( 'wp_prepare_attachment_for_js', array( __CLASS__, 'add_svg_image_support' ), 10, 3 ); - - $options = array( - 'fetch_attachments' => true, - 'default_author' => 0, - ); - - $current_css = wp_get_custom_css_post(); - - $logger = new GeneratePress\WPContentImporter2\WPImporterLogger(); - $importer = new GeneratePress_Sites_Content_Importer( $options ); - $importer->set_logger( $logger ); - $result = $importer->import( $path ); - - // Get all mapped post and term data. - $existing_data = self::get_mapped_post_ids( $slug ); - $mapped_data = $importer->get_importer_data(); - $mapped_posts = $mapped_data['mapping']['post']; - - // Merge exiting mapped posts with any new ones. Existing posts don't get mapped, so we need to preserve them. - $all_data = $mapped_posts + $existing_data; - - // Set our site specific mapped posts with all of our data. - update_option( 'generatepress_sites_mapped_ids_' . $slug, $all_data, false ); - - // Set mapped term IDs. - // These are always the same, even if the site has been imported before. No fancy stuff needed. - $term_mapping = $mapped_data['mapping']['term_id']; - set_transient( 'generatepress_sites_mapped_term_ids', $term_mapping, 0.1 * HOUR_IN_SECONDS ); - - wp_update_custom_css_post( $current_css->post_content ); - - // Page builders need so much extra work. - self::update_page_builder_content(); - - remove_filter( 'upload_mimes', array( __CLASS__, 'mime_types' ) ); - remove_filter( 'wp_check_filetype_and_ext', array( __CLASS__, 'check_real_mime_type' ), 10, 4 ); - remove_filter( 'wp_prepare_attachment_for_js', array( __CLASS__, 'add_svg_image_support' ), 10, 3 ); - } - - /** - * List plugins that have a pro version. - * - * We want to check to see if these exist before installing or activating - * the free versions. - * - * @since 1.6 - * - * @return array - */ - public static function check_for_pro_plugins() { - return apply_filters( - 'generate_sites_pro_plugins', - array( - 'beaver-builder-lite-version/fl-builder.php' => 'bb-plugin/fl-builder.php', - 'ultimate-addons-for-beaver-builder-lite/bb-ultimate-addon.php' => 'bb-ultimate-addon/bb-ultimate-addon.php', - 'powerpack-addon-for-beaver-builder/bb-powerpack-lite.php' => 'bbpowerpack/bb-powerpack.php', - ) - ); - } - - /** - * Check to see if required plugins are active. - * - * @since 1.6 - * - * @param string $plugin The plugin to check for. - */ - public static function is_plugin_installed( $plugin ) { - $pro_plugins = self::check_for_pro_plugins(); - - // Check to see if this plugin has a pro version. - if ( array_key_exists( $plugin, $pro_plugins ) ) { - if ( file_exists( WP_PLUGIN_DIR . '/' . $pro_plugins[ $plugin ] ) ) { - return true; - } - } - - if ( file_exists( WP_PLUGIN_DIR . '/' . $plugin ) ) { - return true; - } - - return false; - - } - - /** - * Allow SVG images. - * - * @since 1.6 - * - * @param array $response Attachment response. - * @param object $attachment Attachment object. - * @param array $meta Attachment meta data. - */ - public static function add_svg_image_support( $response, $attachment, $meta ) { - if ( ! function_exists( 'simplexml_load_file' ) ) { - return $response; - } - - if ( ! empty( $response['sizes'] ) ) { - return $response; - } - - if ( 'image/svg+xml' !== $response['mime'] ) { - return $response; - } - - $svg_path = get_attached_file( $attachment->ID ); - - $dimensions = self::get_svg_dimensions( $svg_path ); - - $response['sizes'] = array( - 'full' => array( - 'url' => $response['url'], - 'width' => $dimensions->width, - 'height' => $dimensions->height, - 'orientation' => $dimensions->width > $dimensions->height ? 'landscape' : 'portrait', - ), - ); - - return $response; - } - - /** - * Get the dimensions of the uploaded SVG. - * - * @since 1.6 - * - * @param string $svg SVG file path. - * @return array Return SVG file height & width for valid SVG file. - */ - public static function get_svg_dimensions( $svg ) { - $svg = simplexml_load_file( $svg ); - - if ( false === $svg ) { - $width = '0'; - $height = '0'; - } else { - $attributes = $svg->attributes(); - $width = (string) $attributes->width; - $height = (string) $attributes->height; - } - - return (object) array( - 'width' => $width, - 'height' => $height, - ); - } - - /** - * Taken from the core media_sideload_image function and - * modified to return an array of data instead of html. - * - * @since 1.6 - * - * @param string $file The image file path. - * @return array An array of image data. - */ - public static function sideload_image( $file ) { - - $data = new stdClass(); - - if ( ! function_exists( 'media_handle_sideload' ) ) { - require_once ABSPATH . 'wp-admin/includes/media.php'; - require_once ABSPATH . 'wp-admin/includes/file.php'; - require_once ABSPATH . 'wp-admin/includes/image.php'; - } - - add_filter( 'upload_mimes', array( __CLASS__, 'mime_types' ) ); - add_filter( 'wp_check_filetype_and_ext', array( __CLASS__, 'check_real_mime_type' ), 10, 4 ); - add_filter( 'wp_prepare_attachment_for_js', array( __CLASS__, 'add_svg_image_support' ), 10, 3 ); - - if ( ! empty( $file ) ) { - - // Set variables for storage, fix file filename for query strings. - preg_match( '/[^\?]+\.(jpe?g|jpe|svg|gif|png)\b/i', $file, $matches ); - $file_array = array(); - $file_array['name'] = basename( $matches[0] ); - - // Download file to temp location. - $file_array['tmp_name'] = download_url( $file ); - - // If error storing temporarily, return the error. - if ( is_wp_error( $file_array['tmp_name'] ) ) { - return $file_array['tmp_name']; - } - - // Do the validation and storage stuff. - $id = media_handle_sideload( $file_array, 0 ); - - // If error storing permanently, unlink. - if ( is_wp_error( $id ) ) { - @unlink( $file_array['tmp_name'] ); // phpcs:ignore - return $id; - } - - // Build the object to return. - $meta = wp_get_attachment_metadata( $id ); - $data->attachment_id = $id; - $data->url = wp_get_attachment_url( $id ); - $data->thumbnail_url = wp_get_attachment_thumb_url( $id ); - - if ( isset( $meta['height'] ) ) { - $data->height = $meta['height']; - } - - if ( isset( $meta['width'] ) ) { - $data->width = $meta['width']; - } - } - - remove_filter( 'upload_mimes', array( __CLASS__, 'mime_types' ) ); - remove_filter( 'wp_check_filetype_and_ext', array( __CLASS__, 'check_real_mime_type' ), 10, 4 ); - remove_filter( 'wp_prepare_attachment_for_js', array( __CLASS__, 'add_svg_image_support' ), 10, 3 ); - - return $data; - - } - - /** - * Re-maps menu locations. - * - * @since 1.6 - * - * @param array $locations Incoming locations. - */ - public static function set_nav_menu_locations( $locations = array() ) { - $menu_locations = array(); - - $term_ids = self::get_mapped_term_ids(); - - if ( isset( $locations ) ) { - self::log( '== Start mapping menu locations ==' ); - - foreach ( $locations as $menu => $value ) { - if ( empty( $value ) ) { - continue; - } - - $menu_locations[ $menu ] = $term_ids[ $value ]; - self::log( $value . ' -> ' . $term_ids[ $value ] ); - } - - set_theme_mod( 'nav_menu_locations', $menu_locations ); - } - } - - /** - * Re-maps the front page and posts page. - * - * @since 1.6 - * - * @param string $name Name of the option to update. - * @param string $value Title of the page. - * @param string $slug Slug of the page. - */ - public static function set_reading_pages( $name, $value, $slug ) { - if ( empty( $value ) ) { - return; - } - - self::log( '== Start mapping front and blog pages ==' ); - - // Get import data, with new menu IDs. - $post_ids = self::get_mapped_post_ids( $slug ); - - update_option( $name, $post_ids[ $value ] ); - self::log( $value . ' -> ' . $post_ids[ $value ] ); - } - - /** - * Re-maps WooCommerce pages. - * - * @since 1.6 - * - * @param string $name Name of the option to update. - * @param string $value Title of the page. - * @param string $slug Slug of the page. - */ - public static function set_woocommerce_pages( $name, $value, $slug ) { - if ( empty( $value ) ) { - return; - } - - self::log( '== Start mapping WooCommerce pages ==' ); - - $post_ids = self::get_mapped_post_ids( $slug ); - - update_option( $name, $post_ids[ $value ] ); - self::log( $value . ' -> ' . $post_ids[ $value ] ); - } - - /** - * Change the menu IDs in the custom menu widgets in the widget import data. - * This solves the issue with custom menu widgets not having the correct (new) menu ID, because they - * have the old menu ID from the export site. - * - * @param array $widget The widget settings array. - */ - public static function fix_custom_menu_widget_ids( $widget ) { - // Skip (no changes needed), if this is not a custom menu widget. - if ( ! array_key_exists( 'nav_menu', $widget ) || empty( $widget['nav_menu'] ) || ! is_int( $widget['nav_menu'] ) ) { - return $widget; - } - - // Get import data, with new menu IDs. - $term_ids = self::get_mapped_term_ids(); - - if ( ! isset( $term_ids[ $widget['nav_menu'] ] ) ) { - return $widget; - } - - self::log( '== Start mapping navigation widgets ==' ); - self::log( $widget['nav_menu'] . ' -> ' . $term_ids[ $widget['nav_menu'] ] ); - - // Set the new menu ID for the widget. - $widget['nav_menu'] = $term_ids[ $widget['nav_menu'] ]; - - return $widget; - } - - /** - * Re-maps the element locations. - * - * @since 1.7 - * - * @param array $locations Incoming locations. - * @param string $slug Element slug. - */ - public static function set_element_locations( $locations, $slug ) { - $post_ids = self::get_mapped_post_ids( $slug ); - - if ( isset( $locations ) && ! empty( $locations ) ) { - self::log( '== Start mapping element locations ==' ); - - foreach ( (array) $locations as $key => $value ) { - $new_locations = array(); - if ( empty( $value ) ) { - continue; - } - - foreach ( (array) $value as $data ) { - if ( $data['object'] ) { - self::log( $data['object'] . ' -> ' . $post_ids[ $data['object'] ] ); - $data['object'] = $post_ids[ $data['object'] ]; - } - - $new_locations[] = $data; - } - - update_post_meta( $post_ids[ $key ], '_generate_element_display_conditions', $new_locations ); - } - } - } - - /** - * Re-maps the element exclusions. - * - * @since 1.7 - * - * @param array $locations Incoming locations. - * @param string $slug Element slug. - */ - public static function set_element_exclusions( $locations, $slug ) { - $post_ids = self::get_mapped_post_ids( $slug ); - - if ( isset( $locations ) && ! empty( $locations ) ) { - self::log( '== Start mapping element exclusions ==' ); - - foreach ( (array) $locations as $key => $value ) { - $new_locations = array(); - if ( empty( $value ) ) { - continue; - } - - foreach ( (array) $value as $data ) { - if ( $data['object'] ) { - self::log( $data['object'] . ' -> ' . $post_ids[ $data['object'] ] ); - $data['object'] = $post_ids[ $data['object'] ]; - } - - $new_locations[] = $data; - } - - update_post_meta( $post_ids[ $key ], '_generate_element_exclude_conditions', $new_locations ); - } - } - } - - /** - * Update menu URLs. - * - * @since 1.7.3 - * @param string $url Preview URL. - */ - public static function update_menu_urls( $url ) { - $args = array( - 'post_type' => 'nav_menu_item', - 'fields' => 'ids', - 'no_found_rows' => true, - 'post_status' => 'any', - 'numberposts' => 50, - ); - - $items = get_posts( $args ); - - foreach ( $items as $item_id ) { - $item_type = get_post_meta( $item_id, '_menu_item_type', true ); - - if ( 'custom' === $item_type ) { - $item_url = get_post_meta( $item_id, '_menu_item_url', true ); - - if ( $item_url && '#' !== $item_url ) { - $item_url = str_replace( $url, site_url(), $item_url ); - - update_post_meta( $item_id, '_menu_item_url', $item_url ); - } - } - } - } - - /** - * Allow other files types to be uploaded. - * - * @since 1.6 - * - * @param array $mimes Existing types. - * @return array Merged types. - */ - public static function mime_types( $mimes ) { - $mimes = array_merge( - $mimes, - array( - 'xml' => 'text/xml', - 'wie' => 'text/plain', - 'svg' => 'image/svg+xml', - 'svgz' => 'image/svg+xml', - ) - ); - - return $mimes; - } - - /** - * Different MIME type of different PHP version - * - * Filters the "real" file type of the given file. - * - * @since 1.8 - * - * @param array $defaults Default file types. - * @param string $file Full path to the file. - * @param string $filename The name of the file (may differ from $file due to $file being in a tmp directory). - * @param array $mimes Key is the file extension with value as the mime type. - */ - public static function check_real_mime_type( $defaults, $file, $filename, $mimes ) { - if ( 'content.xml' === $filename ) { - $defaults['ext'] = 'xml'; - $defaults['type'] = 'text/xml'; - } - - if ( 'widgets.wie' === $filename ) { - $defaults['ext'] = 'wie'; - $defaults['type'] = 'text/plain'; - } - - return $defaults; - } - - /** - * Download a file to WordPress from a URL. - * - * @since 1.6 - * - * @param string $file URL of the file. - * @return array - */ - public static function download_file( $file ) { - add_filter( 'upload_mimes', array( __CLASS__, 'mime_types' ) ); - add_filter( 'wp_check_filetype_and_ext', array( __CLASS__, 'check_real_mime_type' ), 10, 4 ); - add_filter( 'wp_prepare_attachment_for_js', array( __CLASS__, 'add_svg_image_support' ), 10, 3 ); - - // Gives us access to the download_url() and wp_handle_sideload() functions. - require_once ABSPATH . 'wp-admin/includes/file.php'; - - // URL to the WordPress logo. - $url = $file; - $timeout_seconds = 10; - - // Download file to temp dir. - $temp_file = download_url( $url, $timeout_seconds ); - - if ( is_wp_error( $temp_file ) ) { - - return array( - 'success' => false, - 'data' => $temp_file->get_error_message(), - ); - - } - - // Array based on $_FILE as seen in PHP file uploads. - $file = array( - 'name' => basename( $url ), - 'tmp_name' => $temp_file, - 'error' => 0, - 'size' => filesize( $temp_file ), - ); - - $overrides = array( - 'test_form' => false, - 'test_size' => true, - ); - - // Move the temporary file into the uploads directory. - $results = wp_handle_sideload( $file, $overrides ); - - // Clean up. - remove_filter( 'upload_mimes', array( __CLASS__, 'mime_types' ) ); - remove_filter( 'wp_check_filetype_and_ext', array( __CLASS__, 'check_real_mime_type' ), 10, 4 ); - remove_filter( 'wp_prepare_attachment_for_js', array( __CLASS__, 'add_svg_image_support' ), 10, 3 ); - - if ( empty( $results['error'] ) ) { - - return array( - 'success' => true, - 'data' => $results, - ); - - } else { - - return array( - 'success' => false, - 'error' => $results['error'], - ); - - } - - } - - /** - * Get data from the options.json file. - * - * @since 1.6 - * - * @param string $url URL of the file. - * @return array - */ - public static function get_options( $url ) { - $url = wp_safe_remote_get( esc_url( $url ) ); - - if ( is_wp_error( $url ) ) { - return false; - } - - return json_decode( wp_remote_retrieve_body( $url ), true ); - } - - /** - * Check to see if a remote file exists. - * - * @since 1.6 - * - * @param string $url URL of the file. - * @return bool - */ - public static function file_exists( $url ) { - $response = wp_safe_remote_get( esc_url( $url ) ); - - if ( is_wp_error( $response ) ) { - self::log( $response->get_error_message() ); - return false; - } - - return strlen( $response['body'] ) > 100 && ( '200' === (string) $response['response']['code'] || '301' === (string) $response['response']['code'] ) ? true : false; - } - - /** - * Log events to the debug.log file. - * - * @since 1.6 - * @param mixed $log Log data. - * @return void - */ - public static function log( $log ) { - if ( ! WP_DEBUG_LOG ) { - return; - } - - if ( is_array( $log ) || is_object( $log ) ) { - error_log( print_r( $log, true ) ); // phpcs:ignore -- Needed to log events. - } else { - error_log( $log ); // phpcs:ignore -- Needed to log events. - } - } - - /** - * Get all posts to run through batch processing. - * - * @since 1.6 - * - * @return object All posts. - */ - public static function get_all_posts() { - $args = array( - 'post_type' => 'any', - 'fields' => 'ids', - 'no_found_rows' => true, - 'post_status' => 'publish', - 'numberposts' => -1, - 'meta_query' => array( - 'relation' => 'OR', - array( - 'key' => '_fl_builder_data', - 'compare' => 'EXISTS', - ), - array( - 'key' => '_elementor_data', - 'compare' => 'EXISTS', - ), - ), - ); - - $posts = get_posts( $args ); - - if ( $posts ) { - return $posts; - } - - return false; - } - - /** - * Searches Elementor and Beaver Builder content for images to download. - * - * @since 1.6 - */ - public static function update_page_builder_content() { - include_once ABSPATH . 'wp-admin/includes/plugin.php'; - - // Add "bb-plugin" in import [queue]. - // Add "beaver-builder-lite-version" in import [queue]. - if ( is_plugin_active( 'beaver-builder-lite-version/fl-builder.php' ) || is_plugin_active( 'bb-plugin/fl-builder.php' ) ) { - require_once GP_PREMIUM_DIR_PATH . 'site-library/classes/class-beaver-builder-batch-processing.php'; - require_once GP_PREMIUM_DIR_PATH . 'site-library/classes/class-site-import-image.php'; - - $beaver_builder = new GeneratePress_Sites_Process_Beaver_Builder(); - $beaver_builder->import(); - } - } - - /** - * Clear Elementor & Beaver Builder caches when needed. - * - * @since 1.6 - */ - public static function clear_page_builder_cache() { - - if ( class_exists( 'FLBuilderModel' ) && method_exists( 'FLBuilderModel', 'delete_asset_cache_for_all_posts' ) ) { - // Clear all cache. - FLBuilderModel::delete_asset_cache_for_all_posts(); - self::log( 'Cleared Beaver Builder cache.' ); - } - - if ( class_exists( 'Elementor\Plugin' ) && method_exists( 'Elementor\Posts_CSS_Manager', 'clear_cache' ) ) { - // !important, Clear the cache after images import. - Elementor\Plugin::instance()->posts_css_manager->clear_cache(); - self::log( 'Cleared Elementor cache.' ); - } - - } - - /** - * List out GP option names. - * - * @since 1.6 - * - * @return array - */ - public static function get_theme_settings() { - return array( - 'generate_settings', - 'generate_background_settings', - 'generate_blog_settings', - 'generate_page_header_settings', - 'generate_secondary_nav_settings', - 'generate_spacing_settings', - 'generate_menu_plus_settings', - 'generate_woocommerce_settings', - ); - } - - /** - * List out GP theme mods. - * - * @since 1.6 - * - * @return array - */ - public static function get_theme_mods() { - return array( - 'font_body_variants', - 'font_body_category', - 'font_site_title_variants', - 'font_site_title_category', - 'font_site_tagline_variants', - 'font_site_tagline_category', - 'font_navigation_variants', - 'font_navigation_category', - 'font_secondary_navigation_variants', - 'font_secondary_navigation_category', - 'font_buttons_variants', - 'font_buttons_category', - 'font_heading_1_variants', - 'font_heading_1_category', - 'font_heading_2_variants', - 'font_heading_2_category', - 'font_heading_3_variants', - 'font_heading_3_category', - 'font_heading_4_variants', - 'font_heading_4_category', - 'font_heading_5_variants', - 'font_heading_5_category', - 'font_heading_6_variants', - 'font_heading_6_category', - 'font_widget_title_variants', - 'font_widget_title_category', - 'font_footer_variants', - 'font_footer_category', - 'generate_copyright', - ); - } - - /** - * Build the loading icon. - * - * @since 1.6 - */ - public static function loading_icon() { - ?> - - - - - - - - - - - - - 'generate_package_backgrounds', - 'Blog' => 'generate_package_blog', - 'Colors' => 'generate_package_colors', - 'Copyright' => 'generate_package_copyright', - 'Elements' => 'generate_package_elements', - 'Disable Elements' => 'generate_package_disable_elements', - 'Hooks' => 'generate_package_hooks', - 'Menu Plus' => 'generate_package_menu_plus', - 'Page Header' => 'generate_package_page_header', - 'Secondary Nav' => 'generate_package_secondary_nav', - 'Sections' => 'generate_package_sections', - 'Spacing' => 'generate_package_spacing', - 'Typography' => 'generate_package_typography', - 'WooCommerce' => 'generate_package_woocommerce', - 'Font Library' => 'generate_package_font_library', - ); - } - - /** - * A list of options we shouldn't be able to touch. - */ - public static function disallowed_options() { - return array( - 'admin_email', - 'siteurl', - 'home', - 'blog_charset', - 'blog_public', - 'current_theme', - 'stylesheet', - 'template', - 'default_role', - 'mailserver_login', - 'mailserver_pass', - 'mailserver_port', - 'mailserver_url', - 'permalink_structure', - 'rewrite_rules', - 'users_can_register', - ); - } - - /** - * Track Imported Post - * - * @param int $post_id Post ID. - * @return void - */ - public static function track_post( $post_id ) { - update_post_meta( $post_id, '_generatepress_sites_imported_post', true ); - } - - /** - * Track Imported Term - * - * @param int $term_id Term ID. - * @return void - */ - public static function track_term( $term_id ) { - $term = get_term( $term_id ); - - update_term_meta( $term_id, '_generatepress_sites_imported_term', true ); - } - - /** - * Prevent WooCommerce from creating new pages if we're importing them. - * generate_woocommerce_no_create_pages is set during Site Library import. - */ - public static function woocommerce_no_new_pages() { - if ( ! function_exists( 'is_woocommerce' ) ) { - return; - } - - $woocommerce_version = get_option( 'woocommerce_db_version' ); - - if ( empty( $woocommerce_version ) ) { - $no_new_pages = get_option( 'generate_woocommerce_no_create_pages', false ); - - if ( $no_new_pages ) { - add_filter( 'woocommerce_create_pages', '__return_empty_array' ); - delete_option( 'generate_woocommerce_no_create_pages' ); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library-rest.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library-rest.php deleted file mode 100644 index abcd7f27..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library-rest.php +++ /dev/null @@ -1,947 +0,0 @@ -namespace . $this->version; - - // Get Templates. - register_rest_route( - $namespace, - '/get_sites/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'get_sites' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/get_site_data/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'get_site_data' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/import_theme_options/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'import_options' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/activate_plugins/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'activate_plugins' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/import_content/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'import_content' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/import_site_options/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'import_site_options' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/import_widgets/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'import_widgets' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/restore_theme_options/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'restore_theme_options' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - - // Get Templates. - register_rest_route( - $namespace, - '/restore_content/', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'restore_content' ), - 'permission_callback' => array( $this, 'update_settings_permission' ), - ) - ); - } - - /** - * Get edit options permissions. - * - * @return bool - */ - public function update_settings_permission() { - return current_user_can( 'manage_options' ); - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function get_sites( WP_REST_Request $request ) { - $force_refresh = $request->get_param( 'forceRefresh' ); - $sites = get_option( 'generatepress_sites', array() ); - - $time_now = strtotime( 'now' ); - $sites_expire = get_option( 'generatepress_sites_expiration', sanitize_text_field( $time_now ) ); - - if ( $force_refresh || empty( $sites ) || $sites_expire < $time_now ) { - $sites = array(); - - $url = 'https://sites.generatepress.com/wp-json/gp-starter-sites/v1/sites'; - - if ( defined( 'GENERATEBLOCKS_VERSION' ) ) { - if ( ! function_exists( 'generateblocks_use_v1_blocks' ) || generateblocks_use_v1_blocks() ) { - $url = 'https://gpsites.co/wp-json/wp/v2/sites?per_page=100'; - } - } - - $data = wp_safe_remote_get( $url ); - - if ( is_wp_error( $data ) ) { - update_option( 'generatepress_sites', 'no results', false ); - update_option( 'generatepress_sites_expiration', strtotime( '+5 minutes' ), false ); - return $this->failed( 'no results' ); - } - - $data = json_decode( wp_remote_retrieve_body( $data ), true ); - - if ( ! is_array( $data ) ) { - update_option( 'generatepress_sites', 'no results', false ); - update_option( 'generatepress_sites_expiration', strtotime( '+5 minutes' ), false ); - return $this->failed( 'no results' ); - } - - foreach ( (array) $data as $site ) { - $sites[ $site['name'] ] = array( - 'name' => $site['name'], - 'directory' => $site['directory'], - 'preview_url' => $site['preview_url'], - 'author_name' => $site['author_name'], - 'author_url' => $site['author_url'], - 'description' => $site['description'], - 'page_builder' => $site['page_builder'], - 'category' => $site['category'], - 'min_version' => $site['min_version'], - 'min_theme_version' => $site['min_theme_version'], - 'min_generateblocks_version' => $site['min_generateblocks_version'], - 'uploads_url' => $site['uploads_url'], - 'plugins' => $site['plugins'], - 'documentation' => $site['documentation'], - 'image_width' => ! empty( $site['image_width'] ) ? $site['image_width'] : 600, - 'image_height' => ! empty( $site['image_height'] ) ? $site['image_height'] : 600, - ); - } - - update_option( 'generatepress_sites', $sites, false ); - update_option( 'generatepress_sites_expiration', strtotime( '+1 day' ), false ); - } - - $sites = apply_filters( 'generate_add_sites', $sites ); - - return $this->success( $sites ); - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function get_site_data( WP_REST_Request $request ) { - $site_data = $request->get_param( 'siteData' ); - - if ( GeneratePress_Site_Library_Helper::file_exists( $site_data['directory'] . '/options.json' ) ) { - $settings = GeneratePress_Site_Library_Helper::get_options( $site_data['directory'] . '/options.json' ); - - $data['options'] = true; - $data['modules'] = $settings['modules']; - $data['plugins'] = $settings['plugins']; - - if ( is_array( $data['plugins'] ) ) { - include_once ABSPATH . 'wp-admin/includes/plugin.php'; - $plugin_data = array(); - - foreach ( $data['plugins'] as $name => $slug ) { - $basename = strtok( $slug, '/' ); - $plugin_data[ $name ] = array( - 'name' => $name, - 'slug' => $slug, - 'installed' => GeneratePress_Site_Library_Helper::is_plugin_installed( $slug ) ? true : false, - 'active' => is_plugin_active( $slug ) ? true : false, - 'repo' => GeneratePress_Site_Library_Helper::file_exists( 'https://api.wordpress.org/plugins/info/1.0/' . $basename ) ? true : false, - ); - } - - $data['plugin_data'] = $plugin_data; - } - } - - if ( GeneratePress_Site_Library_Helper::file_exists( $site_data['directory'] . '/content.xml' ) ) { - $data['content'] = true; - } else { - $data['content'] = false; - } - - if ( GeneratePress_Site_Library_Helper::file_exists( $site_data['directory'] . '/widgets.wie' ) ) { - $data['widgets'] = true; - } else { - $data['widgets'] = false; - } - - return $this->success( $data ); - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function import_options( WP_REST_Request $request ) { - $site_data = $request->get_param( 'siteData' ); - - if ( ! GeneratePress_Site_Library_Helper::file_exists( $site_data['directory'] . '/options.json' ) ) { - return $this->failed( 'No theme options exist.' ); - } - - // Delete existing backup. - delete_option( '_generatepress_site_library_backup' ); - - // Backup options. - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - - $theme_mods = GeneratePress_Site_Library_Helper::get_theme_mods(); - $settings = GeneratePress_Site_Library_Helper::get_theme_settings(); - - $data = array( - 'mods' => array(), - 'options' => array(), - ); - - foreach ( $theme_mods as $theme_mod ) { - $data['mods'][ $theme_mod ] = get_theme_mod( $theme_mod ); - } - - foreach ( $settings as $setting ) { - $data['options'][ $setting ] = get_option( $setting ); - } - - $backup_data['theme_options'] = $data; - - $modules = GeneratePress_Site_Library_Helper::premium_modules(); - - $active_modules = array(); - foreach ( $modules as $name => $key ) { - if ( 'activated' === get_option( $key ) ) { - $active_modules[ $name ] = $key; - } - } - - $backup_data['modules'] = $active_modules; - - $settings = GeneratePress_Site_Library_Helper::get_options( $site_data['directory'] . '/options.json' ); - - // Remove all existing theme options. - $option_keys = array( - 'generate_settings', - 'generate_background_settings', - 'generate_blog_settings', - 'generate_hooks', - 'generate_page_header_settings', - 'generate_secondary_nav_settings', - 'generate_spacing_settings', - 'generate_menu_plus_settings', - 'generate_woocommerce_settings', - ); - - foreach ( $option_keys as $key ) { - delete_option( $key ); - } - - // Need to backup these items before we remove all theme mods. - $backup_data['site_options']['nav_menu_locations'] = get_theme_mod( 'nav_menu_locations' ); - $backup_data['site_options']['custom_logo'] = get_theme_mod( 'custom_logo' ); - - // Remove existing theme mods. - remove_theme_mods(); - - // Remove existing activated premium modules. - $premium_modules = GeneratePress_Site_Library_Helper::premium_modules(); - - foreach ( $premium_modules as $name => $key ) { - delete_option( $key ); - } - - // Activate necessary modules. - foreach ( $settings['modules'] as $name => $key ) { - // Only allow valid premium modules. - if ( ! in_array( $key, $premium_modules ) ) { - GeneratePress_Site_Library_Helper::log( 'Bad premium module key: ' . $key ); - continue; - } - - update_option( $key, 'activated' ); - } - - // Set theme mods. - foreach ( $settings['mods'] as $key => $val ) { - // Only allow valid theme mods. - if ( ! in_array( $key, GeneratePress_Site_Library_Helper::get_theme_mods() ) ) { - GeneratePress_Site_Library_Helper::log( 'Bad theme mod key: ' . $key ); - continue; - } - - set_theme_mod( $key, $val ); - } - - // Set theme options. - foreach ( $settings['options'] as $key => $val ) { - // Only allow valid options. - if ( ! in_array( $key, GeneratePress_Site_Library_Helper::get_theme_settings() ) ) { - GeneratePress_Site_Library_Helper::log( 'Bad theme setting key: ' . $key ); - continue; - } - - if ( is_array( $val ) || is_object( $val ) ) { - foreach ( $val as $option_name => $option_value ) { - // Import any images. - if ( is_string( $option_value ) && preg_match( '/\.(jpg|jpeg|png|gif)/i', $option_value ) ) { - $data = GeneratePress_Site_Library_Helper::sideload_image( $option_value ); - - if ( ! is_wp_error( $data ) ) { - $val[ $option_name ] = $data->url; - } - } - - // Set these options if we import content. - unset( $val['hide_title'] ); - unset( $val['hide_tagline'] ); - unset( $val['logo_width'] ); - } - } - - update_option( $key, $val ); - } - - // Re-add non-theme option related theme mods. - set_theme_mod( 'nav_menu_locations', $backup_data['site_options']['nav_menu_locations'] ); - set_theme_mod( 'custom_logo', $backup_data['site_options']['custom_logo'] ); - - $existing_settings = get_option( 'generate_settings', array() ); - - if ( isset( $backup_data['theme_options']['options']['generate_settings']['hide_title'] ) ) { - $existing_settings['hide_title'] = $backup_data['theme_options']['options']['generate_settings']['hide_title']; - } - - if ( isset( $backup_data['theme_options']['options']['generate_settings']['hide_tagline'] ) ) { - $existing_settings['hide_tagline'] = $backup_data['theme_options']['options']['generate_settings']['hide_tagline']; - } - - if ( isset( $backup_data['theme_options']['options']['generate_settings']['logo_width'] ) ) { - $existing_settings['logo_width'] = $backup_data['theme_options']['options']['generate_settings']['logo_width']; - } - - update_option( 'generate_settings', $existing_settings ); - - // Remove dynamic CSS cache. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - - $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $dynamic_css_data['updated_time'] ) ) { - unset( $dynamic_css_data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); - - // Custom CSS. - $css = $settings['custom_css']; - $css = '/* GeneratePress Site CSS */ ' . $css . ' /* End GeneratePress Site CSS */'; - - $current_css = wp_get_custom_css_post(); - - if ( isset( $current_css->post_content ) ) { - $current_css->post_content = preg_replace( '#(/\\* GeneratePress Site CSS \\*/).*?(/\\* End GeneratePress Site CSS \\*/)#s', '', $current_css->post_content ); - $css = $current_css->post_content . $css; - } - - wp_update_custom_css_post( $css ); - - update_option( '_generatepress_site_library_backup', $backup_data ); - - return $this->success( __( 'Options imported', 'gp-premium' ) ); - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function activate_plugins( WP_REST_Request $request ) { - $site_data = $request->get_param( 'siteData' ); - $settings = GeneratePress_Site_Library_Helper::get_options( $site_data['directory'] . '/options.json' ); - $plugins = $settings['plugins']; - - // Backup plugins. - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - $backup_data['plugins'] = get_option( 'active_plugins', array() ); - update_option( '_generatepress_site_library_backup', $backup_data ); - - if ( ! empty( $plugins ) ) { - $pro_plugins = GeneratePress_Site_Library_Helper::check_for_pro_plugins(); - include_once ABSPATH . 'wp-admin/includes/plugin.php'; - - foreach ( $plugins as $plugin ) { - // If the plugin has a pro version and it exists, activate it instead. - if ( array_key_exists( $plugin, $pro_plugins ) ) { - if ( file_exists( WP_PLUGIN_DIR . '/' . $pro_plugins[ $plugin ] ) ) { - $plugin = $pro_plugins[ $plugin ]; - } - } - - // Install BB lite if pro doesn't exist. - if ( 'bb-plugin/fl-builder.php' === $plugin && ! file_exists( WP_PLUGIN_DIR . '/bb-plugin/fl-builder.php' ) ) { - $plugin = 'beaver-builder-lite-version/fl-builder.php'; - } - - if ( ! is_plugin_active( $plugin ) ) { - activate_plugin( $plugin, '', false, true ); - - if ( 'woocommerce/woocommerce.php' === $plugin ) { - add_option( 'generate_woocommerce_no_create_pages', true ); - } - } - } - - return $this->success( __( 'Plugins activated', 'gp-premium' ) ); - } - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function import_content( WP_REST_Request $request ) { - $site_data = $request->get_param( 'siteData' ); - $site_slug = $request->get_param( 'siteSlug' ); - $import_options = $request->get_param( 'importOptions' ); - $import_content = $request->get_param( 'importContent' ); - - // Increase PHP max execution time. - set_time_limit( apply_filters( 'generate_sites_content_import_time_limit', 300 ) ); - - $xml_path = $site_data['directory'] . '/content.xml'; - $xml_file = GeneratePress_Site_Library_Helper::download_file( $xml_path ); - $xml_path = $xml_file['data']['file']; - - if ( ! $xml_path ) { - return $this->failed( 'No content found.' ); - } - - // Increase PHP max execution time. - set_time_limit( apply_filters( 'generate_sites_content_import_time_limit', 300 ) ); - - // Disable import of authors. - add_filter( 'wxr_importer.pre_process.user', '__return_false' ); - - // Keep track of our progress. - add_action( 'wxr_importer.processed.post', array( 'GeneratePress_Site_Library_Helper', 'track_post' ) ); - add_action( 'wxr_importer.processed.term', array( 'GeneratePress_Site_Library_Helper', 'track_term' ) ); - - if ( class_exists( 'GeneratePress_Pro_Font_Library' ) ) { - $font_instance = GeneratePress_Pro_Font_Library::get_instance(); - add_action( 'import_post_meta', array( $font_instance, 'update_post_meta' ), 100, 3 ); - } - - // Disables generation of multiple image sizes (thumbnails) in the content import step. - if ( ! apply_filters( 'generate_sites_regen_thumbnails', true ) ) { - add_filter( 'intermediate_image_sizes_advanced', '__return_null' ); - } - - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - $backup_data['content'] = true; - update_option( '_generatepress_site_library_backup', $backup_data ); - - GeneratePress_Site_Library_Helper::import_xml( $xml_path, $site_slug ); - - if ( class_exists( 'GeneratePress_Pro_Font_Library' ) ) { - GeneratePress_Pro_Font_Library::build_css_file(); - } - - if ( class_exists( 'GenerateBlocks_Pro_Enqueue_Styles' ) ) { - $instance = GenerateBlocks_Pro_Enqueue_Styles::get_instance(); - - if ( $instance && method_exists( $instance, 'build_css' ) ) { - $instance->build_css(); - } - } - - return $this->success( 'Content imported' ); - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function import_site_options( WP_REST_Request $request ) { - $site_data = $request->get_param( 'siteData' ); - $site_slug = $request->get_param( 'siteSlug' ); - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - - $settings = GeneratePress_Site_Library_Helper::get_options( $site_data['directory'] . '/options.json' ); - - foreach ( $settings['site_options'] as $key => $val ) { - switch ( $key ) { - case 'page_for_posts': - case 'page_on_front': - $backup_data['site_options'][ $key ] = get_option( $key ); - GeneratePress_Site_Library_Helper::set_reading_pages( $key, $val, $site_slug ); - break; - - case 'woocommerce_shop_page_id': - case 'woocommerce_cart_page_id': - case 'woocommerce_checkout_page_id': - case 'woocommerce_myaccount_page_id': - $backup_data['site_options'][ $key ] = get_option( $key ); - GeneratePress_Site_Library_Helper::set_woocommerce_pages( $key, $val, $site_slug ); - break; - - case 'nav_menu_locations': - if ( ! isset( $backup_data['site_options']['nav_menu_location'] ) ) { - $backup_data['site_options']['nav_menu_locations'] = get_theme_mod( 'nav_menu_locations' ); - } - - GeneratePress_Site_Library_Helper::set_nav_menu_locations( $val ); - break; - - case 'element_locations': - GeneratePress_Site_Library_Helper::set_element_locations( $val, $site_slug ); - break; - - case 'element_exclusions': - GeneratePress_Site_Library_Helper::set_element_exclusions( $val, $site_slug ); - break; - - case 'custom_logo': - if ( ! isset( $backup_data['site_options']['custom_logo'] ) ) { - $backup_data['site_options']['custom_logo'] = get_theme_mod( 'custom_logo' ); - } - - $data = GeneratePress_Site_Library_Helper::sideload_image( $val ); - - if ( ! is_wp_error( $data ) && isset( $data->attachment_id ) ) { - set_theme_mod( 'custom_logo', $data->attachment_id ); - update_post_meta( $data->attachment_id, '_wp_attachment_is_custom_header', get_option( 'stylesheet' ) ); - } else { - remove_theme_mod( 'custom_logo' ); - } - - break; - - default: - if ( in_array( $key, (array) GeneratePress_Site_Library_Helper::disallowed_options() ) ) { - GeneratePress_Site_Library_Helper::log( 'Disallowed option: ' . $key ); - } else { - $backup_data['site_options'][ $key ] = get_option( $key ); - delete_option( $key ); - update_option( $key, $val ); - } - break; - } - } - - // Set theme options. - $theme_settings = get_option( 'generate_settings', array() ); - $update_theme_settings = false; - - foreach ( $settings['options'] as $key => $val ) { - if ( 'generate_settings' !== $key ) { - continue; - } - - if ( is_array( $val ) || is_object( $val ) ) { - foreach ( $val as $option_name => $option_value ) { - if ( 'hide_title' === $option_name ) { - $theme_settings['hide_title'] = $option_value; - $update_theme_settings = true; - } - - if ( 'hide_tagline' === $option_name ) { - $theme_settings['hide_tagline'] = $option_value; - $update_theme_settings = true; - } - - if ( 'logo_width' === $option_name ) { - $theme_settings['logo_width'] = $option_value; - $update_theme_settings = true; - } - } - } - } - - if ( $update_theme_settings ) { - update_option( 'generate_settings', $theme_settings ); - - // Remove dynamic CSS cache. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - - $dynamic_css_data = get_option( 'generatepress_dynamic_css_data', array() ); - - if ( isset( $dynamic_css_data['updated_time'] ) ) { - unset( $dynamic_css_data['updated_time'] ); - } - - update_option( 'generatepress_dynamic_css_data', $dynamic_css_data ); - } - - // Set our backed up options. - update_option( '_generatepress_site_library_backup', $backup_data ); - - // Update any custom menu link URLs. - GeneratePress_Site_Library_Helper::update_menu_urls( $site_data['preview_url'] ); - - // Clear page builder cache. - GeneratePress_Site_Library_Helper::clear_page_builder_cache(); - - return $this->success( 'Site options imported' ); - } - - /** - * Export a group of assets. - * - * @param WP_REST_Request $request request object. - * - * @return mixed - */ - public function import_widgets( WP_REST_Request $request ) { - $site_data = $request->get_param( 'siteData' ); - - require_once GP_PREMIUM_DIR_PATH . 'site-library/classes/class-site-widget-importer.php'; - - $widgets_path = $site_data['directory'] . '/widgets.wie'; - - $wie_file = GeneratePress_Site_Library_Helper::download_file( $widgets_path ); - $wie_path = $wie_file['data']['file']; - - $data = implode( '', file( $wie_path ) ); - $data = json_decode( $data ); - - GeneratePress_Site_Library_Helper::clear_widgets(); - - add_filter( 'wie_widget_settings_array', array( 'GeneratePress_Site_Library_Helper', 'fix_custom_menu_widget_ids' ) ); - $widgets_importer = GeneratePress_Sites_Widget_Importer::instance(); - $widgets_importer->wie_import_data( $data ); - remove_filter( 'wie_widget_settings_array', array( 'GeneratePress_Site_Library_Helper', 'fix_custom_menu_widget_ids' ) ); - - return $this->success( 'Widgets imported' ); - } - - /** - * Restore our theme options. - */ - public function restore_theme_options() { - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - - if ( ! empty( $backup_data ) ) { - if ( ! empty( $backup_data['theme_options']['mods'] ) ) { - remove_theme_mods(); - } - - if ( ! empty( $backup_data['theme_options']['options'] ) ) { - $option_keys = array( - 'generate_settings', - 'generate_background_settings', - 'generate_blog_settings', - 'generate_hooks', - 'generate_page_header_settings', - 'generate_secondary_nav_settings', - 'generate_spacing_settings', - 'generate_menu_plus_settings', - 'generate_woocommerce_settings', - ); - - foreach ( $option_keys as $key ) { - delete_option( $key ); - } - } - - if ( ! empty( $backup_data['modules'] ) ) { - $modules = GeneratePress_Site_Library_Helper::premium_modules(); - - foreach ( $modules as $name => $key ) { - delete_option( $key ); - } - - foreach ( (array) $backup_data['modules'] as $name => $key ) { - update_option( $key, 'activated' ); - } - } - - if ( ! empty( $backup_data['theme_options']['mods'] ) ) { - foreach ( $backup_data['theme_options']['mods'] as $key => $val ) { - // Only allow valid theme mods. - if ( ! in_array( $key, GeneratePress_Site_Library_Helper::get_theme_mods() ) ) { - GeneratePress_Site_Library_Helper::log( 'Bad theme mod key: ' . $key ); - continue; - } - - set_theme_mod( $key, $val ); - } - } - - if ( ! empty( $backup_data['theme_options']['options'] ) ) { - foreach ( $backup_data['theme_options']['options'] as $key => $val ) { - // Only allow valid options. - if ( ! in_array( $key, GeneratePress_Site_Library_Helper::get_theme_settings() ) ) { - GeneratePress_Site_Library_Helper::log( 'Bad theme setting key: ' . $key ); - continue; - } - - update_option( $key, $val ); - } - } - - // Re-add non-theme option related theme mods. - if ( isset( $backup_data['site_options']['nav_menu_locations'] ) ) { - set_theme_mod( 'nav_menu_locations', $backup_data['site_options']['nav_menu_locations'] ); - } - - if ( isset( $backup_data['site_options']['custom_logo'] ) ) { - set_theme_mod( 'custom_logo', $backup_data['site_options']['custom_logo'] ); - } - } - - return $this->success( __( 'Theme options restored.', 'gp-premium' ) ); - } - - /** - * Restore content. - */ - public function restore_content() { - $backup_data = get_option( '_generatepress_site_library_backup', array() ); - - // Plugins. - if ( ! empty( $backup_data['plugins'] ) && ! empty( $backup_data['site_options'] ) ) { - update_option( 'active_plugins', $backup_data['plugins'] ); - } - - // Content. - if ( ! empty( $backup_data ) ) { - global $wpdb; - $post_ids = $wpdb->get_col( "SELECT post_id FROM {$wpdb->postmeta} WHERE meta_key='_generatepress_sites_imported_post'" ); - $term_ids = $wpdb->get_col( "SELECT term_id FROM {$wpdb->termmeta} WHERE meta_key='_generatepress_sites_imported_term'" ); - - foreach ( $post_ids as $id ) { - wp_delete_post( $id, true ); - } - } - - // Site options. - if ( ! empty( $backup_data['site_options'] ) ) { - foreach ( $backup_data['site_options'] as $key => $val ) { - if ( in_array( $key, (array) GeneratePress_Site_Library_Helper::disallowed_options() ) ) { - GeneratePress_Site_Library_Helper::log( 'Disallowed option: ' . $key ); - continue; - } - - if ( 'nav_menu_locations' === $key || 'custom_logo' === $key ) { - set_theme_mod( $key, $val ); - } else { - if ( ! $val && ! is_numeric( $val ) ) { - delete_option( $key ); - } else { - update_option( $key, $val ); - } - } - } - } - - // Widgets. - if ( ! empty( $backup_data['widgets'] ) ) { - update_option( 'sidebars_widgets', $backup_data['widgets'] ); - } - - // CSS. - $current_css = wp_get_custom_css_post(); - - if ( isset( $current_css->post_content ) ) { - // Remove existing library CSS. - $current_css->post_content = preg_replace( '#(/\\* GeneratePress Site CSS \\*/).*?(/\\* End GeneratePress Site CSS \\*/)#s', '', $current_css->post_content ); - } - - wp_update_custom_css_post( $current_css->post_content ); - - // Clean up. - delete_option( 'generate_dynamic_css_output' ); - delete_option( 'generate_dynamic_css_cached_version' ); - delete_option( '_generatepress_site_library_backup' ); - - return $this->success( __( 'Content restored.', 'gp-premium' ) ); - } - - /** - * Success rest. - * - * @param mixed $response response data. - * @return mixed - */ - public function success( $response ) { - return new WP_REST_Response( - array( - 'success' => true, - 'response' => $response, - ), - 200 - ); - } - - /** - * Failed rest. - * - * @param mixed $response response data. - * @return mixed - */ - public function failed( $response ) { - return new WP_REST_Response( - array( - 'success' => false, - 'response' => $response, - ), - 200 - ); - } - - /** - * Error rest. - * - * @param mixed $code error code. - * @param mixed $response response data. - * @return mixed - */ - public function error( $code, $response ) { - return new WP_REST_Response( - array( - 'error' => true, - 'success' => false, - 'error_code' => $code, - 'response' => $response, - ), - 401 - ); - } -} - -GeneratePress_Site_Library_Rest::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library.php deleted file mode 100644 index eb212fb2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/class-site-library.php +++ /dev/null @@ -1,413 +0,0 @@ -id ) { - $parent_file = 'themes.php'; // phpcs:ignore -- Override necessary. - $submenu_file = 'generate-options'; // phpcs:ignore -- Override necessary. - } - - remove_submenu_page( 'themes.php', 'generatepress-library' ); - } - - /** - * Add our scripts. - */ - public function enqueue_scripts() { - $screen = get_current_screen(); - - if ( 'appearance_page_generatepress-library' === $screen->id ) { - wp_enqueue_script( - 'generatepress-pro-site-library', - GP_PREMIUM_DIR_URL . 'dist/site-library.js', - array( 'wp-api', 'wp-i18n', 'wp-components', 'wp-element', 'wp-api-fetch', 'wp-util', 'wp-html-entities', 'updates' ), - GP_PREMIUM_VERSION, - true - ); - - if ( function_exists( 'wp_set_script_translations' ) ) { - wp_set_script_translations( 'generatepress-pro-site-library', 'gp-premium', GP_PREMIUM_DIR_PATH . 'langs' ); - } - - if ( function_exists( 'wp_get_upload_dir' ) ) { - $uploads_url = wp_get_upload_dir(); - } else { - $uploads_url = wp_upload_dir( null, false ); - } - - wp_localize_script( - 'generatepress-pro-site-library', - 'gppSiteLibrary', - array( - 'homeUrl' => esc_url( home_url() ), - 'hasBackup' => ! empty( get_option( '_generatepress_site_library_backup', array() ) ), - 'gppVersion' => GP_PREMIUM_VERSION, - 'gpVersion' => generate_premium_get_theme_version(), - 'generateblocksVersion' => defined( 'GENERATEBLOCKS_VERSION' ) ? GENERATEBLOCKS_VERSION : '', - 'elementorReplaceUrls' => esc_url( admin_url( 'admin.php?page=elementor-tools#tab-replace_url' ) ), - 'uploadsUrl' => $uploads_url['baseurl'], - 'isDebugEnabled' => defined( 'WP_DEBUG' ) && true === WP_DEBUG, - ) - ); - - wp_enqueue_style( - 'generatepress-pro-site-library', - GP_PREMIUM_DIR_URL . 'dist/site-library.css', - array( 'wp-components' ), - GP_PREMIUM_VERSION - ); - - if ( ! class_exists( 'GeneratePress_Dashboard' ) ) { - wp_enqueue_style( - 'generate-premium-dashboard', - GP_PREMIUM_DIR_URL . 'inc/legacy/assets/dashboard.css', - array(), - GP_PREMIUM_VERSION - ); - } - } - } - - /** - * Add our page. - */ - public function library_page() { - if ( ! class_exists( 'GeneratePress_Dashboard' ) ) : - ?> -
            -
            -
            - -
            - - -
            -
            - - -
            - __( 'Site Library', 'gp-premium' ), - 'url' => admin_url( 'themes.php?page=generatepress-library' ), - 'class' => 'appearance_page_generatepress-library' === $screen->id ? 'active' : '', - 'id' => 'gp-site-library-tab', - ); - - return $tabs; - } - - /** - * Tell GeneratePress this is an admin page. - * - * @param array $screens Existing screens. - */ - public function add_dashboard_screen( $screens ) { - $screens[] = 'appearance_page_generatepress-library'; - - return $screens; - } - - /** - * Add our GeneratePress Site export checkbox to the Export module. - */ - public function add_export_checkbox() { - if ( ! apply_filters( 'generate_show_generatepress_site_export_option', false ) ) { - return; - } - ?> -
            - - - $key ) { - if ( 'activated' === get_option( $key ) ) { - $data['modules'][ $name ] = $key; - } - } - - // Site options. - $data['site_options']['nav_menu_locations'] = get_theme_mod( 'nav_menu_locations' ); - $data['site_options']['custom_logo'] = wp_get_attachment_url( get_theme_mod( 'custom_logo' ) ); - $data['site_options']['show_on_front'] = get_option( 'show_on_front' ); - $data['site_options']['page_on_front'] = get_option( 'page_on_front' ); - $data['site_options']['page_for_posts'] = get_option( 'page_for_posts' ); - - // Elements. - $data['site_options']['element_locations'] = $this->get_elements_locations(); - $data['site_options']['element_exclusions'] = $this->get_elements_exclusions(); - - // Custom CSS. - if ( function_exists( 'wp_get_custom_css_post' ) ) { - $data['custom_css'] = wp_get_custom_css_post()->post_content; - } - - // WooCommerce. - if ( is_plugin_active( 'woocommerce/woocommerce.php' ) ) { - $data['site_options']['woocommerce_shop_page_id'] = get_option( 'woocommerce_shop_page_id' ); - $data['site_options']['woocommerce_cart_page_id'] = get_option( 'woocommerce_cart_page_id' ); - $data['site_options']['woocommerce_checkout_page_id'] = get_option( 'woocommerce_checkout_page_id' ); - $data['site_options']['woocommerce_myaccount_page_id'] = get_option( 'woocommerce_myaccount_page_id' ); - $data['site_options']['woocommerce_single_image_width'] = get_option( 'woocommerce_single_image_width' ); - $data['site_options']['woocommerce_thumbnail_image_width'] = get_option( 'woocommerce_thumbnail_image_width' ); - $data['site_options']['woocommerce_thumbnail_cropping'] = get_option( 'woocommerce_thumbnail_cropping' ); - $data['site_options']['woocommerce_shop_page_display'] = get_option( 'woocommerce_shop_page_display' ); - $data['site_options']['woocommerce_category_archive_display'] = get_option( 'woocommerce_category_archive_display' ); - $data['site_options']['woocommerce_default_catalog_orderby'] = get_option( 'woocommerce_default_catalog_orderby' ); - } - - // Elementor. - if ( is_plugin_active( 'elementor/elementor.php' ) ) { - $data['site_options']['elementor_container_width'] = get_option( 'elementor_container_width' ); - $data['site_options']['elementor_cpt_support'] = get_option( 'elementor_cpt_support' ); - $data['site_options']['elementor_css_print_method'] = get_option( 'elementor_css_print_method' ); - $data['site_options']['elementor_default_generic_fonts'] = get_option( 'elementor_default_generic_fonts' ); - $data['site_options']['elementor_disable_color_schemes'] = get_option( 'elementor_disable_color_schemes' ); - $data['site_options']['elementor_disable_typography_schemes'] = get_option( 'elementor_disable_typography_schemes' ); - $data['site_options']['elementor_editor_break_lines'] = get_option( 'elementor_editor_break_lines' ); - $data['site_options']['elementor_exclude_user_roles'] = get_option( 'elementor_exclude_user_roles' ); - $data['site_options']['elementor_global_image_lightbox'] = get_option( 'elementor_global_image_lightbox' ); - $data['site_options']['elementor_page_title_selector'] = get_option( 'elementor_page_title_selector' ); - $data['site_options']['elementor_scheme_color'] = get_option( 'elementor_scheme_color' ); - $data['site_options']['elementor_scheme_color-picker'] = get_option( 'elementor_scheme_color-picker' ); - $data['site_options']['elementor_scheme_typography'] = get_option( 'elementor_scheme_typography' ); - $data['site_options']['elementor_space_between_widgets'] = get_option( 'elementor_space_between_widgets' ); - $data['site_options']['elementor_stretched_section_container'] = get_option( 'elementor_stretched_section_container' ); - $data['site_options']['elementor_load_fa4_shim'] = get_option( 'elementor_load_fa4_shim' ); - $data['site_options']['elementor_active_kit'] = get_option( 'elementor_active_kit' ); - } - - // Beaver Builder. - if ( is_plugin_active( 'beaver-builder-lite-version/fl-builder.php' ) || is_plugin_active( 'bb-plugin/fl-builder.php' ) ) { - $data['site_options']['_fl_builder_enabled_icons'] = get_option( '_fl_builder_enabled_icons' ); - $data['site_options']['_fl_builder_enabled_modules'] = get_option( '_fl_builder_enabled_modules' ); - $data['site_options']['_fl_builder_post_types'] = get_option( '_fl_builder_post_types' ); - $data['site_options']['_fl_builder_color_presets'] = get_option( '_fl_builder_color_presets' ); - $data['site_options']['_fl_builder_services'] = get_option( '_fl_builder_services' ); - $data['site_options']['_fl_builder_settings'] = get_option( '_fl_builder_settings' ); - $data['site_options']['_fl_builder_user_access'] = get_option( '_fl_builder_user_access' ); - $data['site_options']['_fl_builder_enabled_templates'] = get_option( '_fl_builder_enabled_templates' ); - } - - // Menu Icons. - if ( is_plugin_active( 'menu-icons/menu-icons.php' ) ) { - $data['site_options']['menu-icons'] = get_option( 'menu-icons' ); - } - - // Ninja Forms. - if ( is_plugin_active( 'ninja-forms/ninja-forms.php' ) ) { - $data['site_options']['ninja_forms_settings'] = get_option( 'ninja_forms_settings' ); - } - - // Social Warfare. - if ( is_plugin_active( 'social-warfare/social-warfare.php' ) ) { - $data['site_options']['socialWarfareOptions'] = get_option( 'socialWarfareOptions' ); - } - - // Elements Plus. - if ( is_plugin_active( 'elements-plus/elements-plus.php' ) ) { - $data['site_options']['elements_plus_settings'] = get_option( 'elements_plus_settings' ); - } - - // Ank Google Map. - if ( is_plugin_active( 'ank-google-map/ank-google-map.php' ) ) { - $data['site_options']['ank_google_map'] = get_option( 'ank_google_map' ); - } - - // GP Social Share. - if ( is_plugin_active( 'gp-social-share-svg/gp-social-share.php' ) ) { - $data['site_options']['gp_social_settings'] = get_option( 'gp_social_settings' ); - } - - // Active plugins. - $active_plugins = get_option( 'active_plugins' ); - $all_plugins = get_plugins(); - - $ignore = apply_filters( - 'generate_sites_ignore_plugins', - array( - 'gp-premium/gp-premium.php', - 'widget-importer-exporter/widget-importer-exporter.php', - ) - ); - - foreach ( $ignore as $plugin ) { - unset( $all_plugins[ $plugin ] ); - } - - $activated_plugins = array(); - - foreach ( $active_plugins as $p ) { - if ( isset( $all_plugins[ $p ] ) ) { - $activated_plugins[ $all_plugins[ $p ]['Name'] ] = $p; - } - } - - $data['plugins'] = $activated_plugins; - - return $data; - - } - - /** - * Get our Element display locations. - * - * @return array - */ - public function get_elements_locations() { - $args = array( - 'post_type' => 'gp_elements', - 'showposts' => -1, - ); - - $posts = get_posts( $args ); - $new_values = array(); - - foreach ( $posts as $post ) { - $display_conditions = get_post_meta( $post->ID, '_generate_element_display_conditions', true ); - - if ( $display_conditions ) { - $new_values[ $post->ID ] = $display_conditions; - } - } - - return $new_values; - } - - /** - * Get our Element display locations. - * - * @return array - */ - public function get_elements_exclusions() { - $args = array( - 'post_type' => 'gp_elements', - 'showposts' => -1, - ); - - $posts = get_posts( $args ); - $new_values = array(); - - foreach ( $posts as $post ) { - $display_conditions = get_post_meta( $post->ID, '_generate_element_exclude_conditions', true ); - - if ( $display_conditions ) { - $new_values[ $post->ID ] = $display_conditions; - } - } - - return $new_values; - } -} - -GeneratePress_Site_Library::get_instance(); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-beaver-builder-batch-processing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-beaver-builder-batch-processing.php deleted file mode 100644 index 6ec1cbdc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-beaver-builder-batch-processing.php +++ /dev/null @@ -1,163 +0,0 @@ -image_importer = new GeneratePress_Sites_Image_Importer(); - } - - /** - * Import - * - * @since 1.6 - * @return void - */ - public function import() { - GeneratePress_Site_Library_Helper::log( '== Start Processing Beaver Builder Images ==' ); - - $post_ids = GeneratePress_Site_Library_Helper::get_all_posts(); - - if ( is_array( $post_ids ) ) { - foreach ( $post_ids as $post_id ) { - $this->import_single_post( $post_id ); - } - } - } - - /** - * Update post meta. - * - * @param integer $post_id Post ID. - * @return void - */ - public function import_single_post( $post_id = 0 ) { - - if ( ! empty( $post_id ) ) { - - // Get page builder data. - $data = get_post_meta( $post_id, '_fl_builder_data', true ); - - if ( ! empty( $data ) ) { - foreach ( $data as $key => $el ) { - // Import background images. - if ( 'row' === $el->type || 'column' === $el->type ) { - $data[ $key ]->settings = $this->import_background_images( $el->settings ); - } - - // Import module images. - if ( 'module' === $el->type ) { - $data[ $key ]->settings = $this->import_module_images( $el->settings ); - } - } - - // Update page builder data. - update_post_meta( $post_id, '_fl_builder_data', $data ); - update_post_meta( $post_id, '_fl_builder_draft', $data ); - - // Clear all cache. - FLBuilderModel::delete_asset_cache_for_all_posts(); - } - } - } - - /** - * Import Module Images. - * - * @param object $settings Module settings object. - * @return object - */ - public function import_module_images( $settings ) { - - /** - * 1) Set photos. - */ - $settings = $this->import_photo( $settings ); - - /** - * 2) Set `$settings->data` for Only type 'image-icon' - * - * @todo Remove the condition `'image-icon' === $settings->type` if `$settings->data` is used only for the Image Icon. - */ - if ( isset( $settings->data ) && isset( $settings->photo ) && ! empty( $settings->photo ) && 'image-icon' === $settings->type ) { - $settings->data = FLBuilderPhoto::get_attachment_data( $settings->photo ); - } - - /** - * 3) Set `list item` module images - */ - if ( isset( $settings->add_list_item ) ) { - foreach ( $settings->add_list_item as $key => $value ) { - $settings->add_list_item[ $key ] = $this->import_photo( $value ); - } - } - - return $settings; - } - - /** - * Helper: Import BG Images. - * - * @param object $settings Row settings object. - * @return object - */ - public function import_background_images( $settings ) { - - if ( ! empty( $settings->bg_image ) && ! empty( $settings->bg_image_src ) ) { - $image = array( - 'url' => $settings->bg_image_src, - 'id' => $settings->bg_image, - ); - - $downloaded_image = $this->image_importer->import( $image ); - - $settings->bg_image_src = $downloaded_image['url']; - $settings->bg_image = $downloaded_image['id']; - } - - return $settings; - } - - /** - * Helper: Import Photo. - * - * @param object $settings Row settings object. - * @return object - */ - public function import_photo( $settings ) { - - if ( ! empty( $settings->photo ) && ! empty( $settings->photo_src ) ) { - $image = array( - 'url' => $settings->photo_src, - 'id' => $settings->photo, - ); - - $downloaded_image = $this->image_importer->import( $image ); - - $settings->photo_src = $downloaded_image['url']; - $settings->photo = $downloaded_image['id']; - } - - return $settings; - } - - -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-content-importer.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-content-importer.php deleted file mode 100644 index f2198499..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-content-importer.php +++ /dev/null @@ -1,49 +0,0 @@ -mapping['user_slug'][ $current_user_obj->user_login ] = $current_user_obj->ID; - } - - /** - * Get all protected variables from the WXR_Importer needed for continuing the import. - */ - public function get_importer_data() { - return array( - 'mapping' => $this->mapping, - ); - } - - /** - * Sets all protected variables from the WXR_Importer needed for continuing the import. - * - * @param array $data with set variables. - */ - public function set_importer_data( $data ) { - // phpcs:ignore -- Commented out code for now. - // $this->mapping = empty( $data['mapping'] ) ? array() : $data['mapping']; - // $this->requires_remapping = empty( $data['requires_remapping'] ) ? array() : $data['requires_remapping']; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-site-import-image.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-site-import-image.php deleted file mode 100644 index bd8226fe..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-site-import-image.php +++ /dev/null @@ -1,200 +0,0 @@ - $attachment ) { - $downloaded_images[] = $this->import( $attachment ); - } - - return $downloaded_images; - } - - /** - * Get Hash Image. - * - * @since 1.6 - * @param string $attachment_url Attachment URL. - * @return string Hash string. - */ - private function get_hash_image( $attachment_url ) { - return sha1( $attachment_url ); - } - - /** - * Get Saved Image. - * - * @since 1.6 - * @param string $attachment Attachment Data. - * @return string Hash string. - */ - private function get_saved_image( $attachment ) { - - global $wpdb; - - // Already imported? Then return! - if ( isset( $this->already_imported_ids[ $attachment['id'] ] ) ) { - GeneratePress_Site_Library_Helper::log( 'Successfully replaced: ' . $attachment['url'] ); - - return $this->already_imported_ids[ $attachment['id'] ]; - } - - // 1. Is already imported in Batch Import Process? - $post_id = $wpdb->get_var( - $wpdb->prepare( - 'SELECT `post_id` FROM `' . $wpdb->postmeta . '` - WHERE `meta_key` = \'_generatepress_sites_image_hash\' - AND `meta_value` = %s - ;', - $this->get_hash_image( $attachment['url'] ) - ) - ); - - // 2. Is image already imported though XML? - if ( empty( $post_id ) ) { - // Get file name without extension. - // To check it exist in attachment. - $filename = preg_replace( '/\\.[^.\\s]{3,4}$/', '', basename( $attachment['url'] ) ); - - $post_id = $wpdb->get_var( - $wpdb->prepare( - 'SELECT `post_id` FROM `' . $wpdb->postmeta . '` - WHERE `meta_key` = \'_wp_attached_file\' - AND `meta_value` LIKE %s - ;', - '%' . $filename . '%' - ) - ); - - GeneratePress_Site_Library_Helper::log( 'Successfully replaced: ' . $attachment['url'] ); - } - - if ( $post_id ) { - $new_attachment = array( - 'id' => $post_id, - 'url' => wp_get_attachment_url( $post_id ), - ); - - $this->already_imported_ids[ $attachment['id'] ] = $new_attachment; - - return $new_attachment; - } - - return false; - } - - /** - * Import Image - * - * @since 1.6 - * @param array $attachment Attachment array. - * @return array Attachment array. - */ - public function import( $attachment ) { - - $saved_image = $this->get_saved_image( $attachment ); - - if ( $saved_image ) { - return $saved_image; - } - - $file_content = wp_remote_retrieve_body( wp_safe_remote_get( $attachment['url'] ) ); - - // Empty file content? - if ( empty( $file_content ) ) { - GeneratePress_Site_Library_Helper::log( 'Failed to replace: ' . $attachment['url'] ); - GeneratePress_Site_Library_Helper::log( 'Error: Failed wp_remote_retrieve_body().' ); - - return $attachment; - } - - // Extract the file name and extension from the URL. - $filename = basename( $attachment['url'] ); - - $upload = wp_upload_bits( - $filename, - null, - $file_content - ); - - $post = array( - 'post_title' => $filename, - 'guid' => $upload['url'], - ); - - $info = wp_check_filetype( $upload['file'] ); - - if ( $info ) { - $post['post_mime_type'] = $info['type']; - } else { - // For now just return the origin attachment. - return $attachment; - } - - $post_id = wp_insert_attachment( $post, $upload['file'] ); - - wp_update_attachment_metadata( - $post_id, - wp_generate_attachment_metadata( $post_id, $upload['file'] ) - ); - - update_post_meta( $post_id, '_generatepress_sites_image_hash', $this->get_hash_image( $attachment['url'] ) ); - - $new_attachment = array( - 'id' => $post_id, - 'url' => $upload['url'], - ); - - GeneratePress_Site_Library_Helper::log( 'Successfully replaced: ' . $attachment['url'] ); - - $this->already_imported_ids[ $attachment['id'] ] = $new_attachment; - - return $new_attachment; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-site-widget-importer.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-site-widget-importer.php deleted file mode 100644 index ed1b611a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/classes/class-site-widget-importer.php +++ /dev/null @@ -1,275 +0,0 @@ - true, - ) - ); - } - - // Hook before import. - do_action( 'wie_before_import' ); // phpcs:ignore -- Keep the plugin prefix. - - $data = apply_filters( 'wie_import_data', $data ); // phpcs:ignore -- Keep the plugin prefix. - - // Get all available widgets site supports. - $available_widgets = $this->wie_available_widgets(); - - // Get all existing widget instances. - $widget_instances = array(); - - foreach ( $available_widgets as $widget_data ) { - $widget_instances[ $widget_data['id_base'] ] = get_option( 'widget_' . $widget_data['id_base'] ); - } - - // Begin results. - $results = array(); - - // Loop import data's sidebars. - foreach ( $data as $sidebar_id => $widgets ) { - // Skip inactive widgets (should not be in export file). - if ( 'wp_inactive_widgets' === $sidebar_id ) { - continue; - } - - // Check if sidebar is available on this site. - // Otherwise add widgets to inactive, and say so. - if ( isset( $wp_registered_sidebars[ $sidebar_id ] ) ) { - $sidebar_available = true; - $use_sidebar_id = $sidebar_id; - $sidebar_message_type = 'success'; - $sidebar_message = ''; - } else { - $sidebar_available = false; - $use_sidebar_id = 'wp_inactive_widgets'; // Add to inactive if sidebar does not exist in theme. - $sidebar_message_type = 'error'; - $sidebar_message = esc_html__( 'Widget area does not exist in theme (using Inactive)', 'widget-importer-exporter' ); - } - - // Result for sidebar - // Sidebar name if theme supports it; otherwise ID. - $results[ $sidebar_id ]['name'] = ! empty( $wp_registered_sidebars[ $sidebar_id ]['name'] ) ? $wp_registered_sidebars[ $sidebar_id ]['name'] : $sidebar_id; - $results[ $sidebar_id ]['message_type'] = $sidebar_message_type; - $results[ $sidebar_id ]['message'] = $sidebar_message; - $results[ $sidebar_id ]['widgets'] = array(); - - // Loop widgets. - foreach ( $widgets as $widget_instance_id => $widget ) { - $fail = false; - - // Get id_base (remove -# from end) and instance ID number. - $id_base = preg_replace( '/-[0-9]+$/', '', $widget_instance_id ); - $instance_id_number = str_replace( $id_base . '-', '', $widget_instance_id ); - - // Does site support this widget? - if ( ! $fail && ! isset( $available_widgets[ $id_base ] ) ) { - $fail = true; - $widget_message_type = 'error'; - $widget_message = esc_html__( 'Site does not support widget', 'widget-importer-exporter' ); // Explain why widget not imported. - } - - // Filter to modify settings object before conversion to array and import - // Leave this filter here for backwards compatibility with manipulating objects (before conversion to array below) - // Ideally the newer wie_widget_settings_array below will be used instead of this. - $widget = apply_filters( 'wie_widget_settings', $widget ); // phpcs:ignore -- Keep the plugin prefix. - - // Convert multidimensional objects to multidimensional arrays - // Some plugins like Jetpack Widget Visibility store settings as multidimensional arrays - // Without this, they are imported as objects and cause fatal error on Widgets page - // If this creates problems for plugins that do actually intend settings in objects then may need to consider other approach: https://wordpress.org/support/topic/problem-with-array-of-arrays - // It is probably much more likely that arrays are used than objects, however. - $widget = json_decode( wp_json_encode( $widget ), true ); - - // Filter to modify settings array - // This is preferred over the older wie_widget_settings filter above - // Do before identical check because changes may make it identical to end result (such as URL replacements). - $widget = apply_filters( 'wie_widget_settings_array', $widget ); // phpcs:ignore -- Keep the plugin prefix. - - // Does widget with identical settings already exist in same sidebar? - if ( ! $fail && isset( $widget_instances[ $id_base ] ) ) { - // Get existing widgets in this sidebar. - $sidebars_widgets = get_option( 'sidebars_widgets' ); - $sidebar_widgets = isset( $sidebars_widgets[ $use_sidebar_id ] ) ? $sidebars_widgets[ $use_sidebar_id ] : array(); // Check Inactive if that's where will go. - - // Loop widgets with ID base. - $single_widget_instances = ! empty( $widget_instances[ $id_base ] ) ? $widget_instances[ $id_base ] : array(); - - foreach ( $single_widget_instances as $check_id => $check_widget ) { - // Is widget in same sidebar and has identical settings? - if ( in_array( "$id_base-$check_id", $sidebar_widgets, true ) && (array) $widget === $check_widget ) { - $fail = true; - $widget_message_type = 'warning'; - // Explain why widget not imported. - $widget_message = esc_html__( 'Widget already exists', 'widget-importer-exporter' ); - break; - } - } - } - - // No failure. - if ( ! $fail ) { - // Add widget instance. - $single_widget_instances = get_option( 'widget_' . $id_base ); // All instances for that widget ID base, get fresh every time. - - $single_widget_instances = ! empty( $single_widget_instances ) ? $single_widget_instances : array( - '_multiwidget' => 1, // Start fresh if have to. - ); - - $single_widget_instances[] = $widget; // Add it. - - // Get the key it was given. - end( $single_widget_instances ); - - $new_instance_id_number = key( $single_widget_instances ); - - // If key is 0, make it 1 - // When 0, an issue can occur where adding a widget causes data from other widget to load, - // and the widget doesn't stick (reload wipes it). - if ( '0' === strval( $new_instance_id_number ) ) { - $new_instance_id_number = 1; - $single_widget_instances[ $new_instance_id_number ] = $single_widget_instances[0]; - unset( $single_widget_instances[0] ); - } - - // Move _multiwidget to end of array for uniformity. - if ( isset( $single_widget_instances['_multiwidget'] ) ) { - $multiwidget = $single_widget_instances['_multiwidget']; - unset( $single_widget_instances['_multiwidget'] ); - $single_widget_instances['_multiwidget'] = $multiwidget; - } - - // Update option with new widget. - update_option( 'widget_' . $id_base, $single_widget_instances ); - - // Assign widget instance to sidebar. - // Which sidebars have which widgets, get fresh every time. - $sidebars_widgets = get_option( 'sidebars_widgets' ); - - // Avoid rarely fatal error when the option is an empty string - // https://github.com/stevengliebe/widget-importer-exporter/pull/11. - if ( ! $sidebars_widgets ) { - $sidebars_widgets = array(); - } - - // Use ID number from new widget instance. - $new_instance_id = $id_base . '-' . $new_instance_id_number; - - // Add new instance to sidebar. - $sidebars_widgets[ $use_sidebar_id ][] = $new_instance_id; - - // Save the amended data. - update_option( 'sidebars_widgets', $sidebars_widgets ); - - // After widget import action. - $after_widget_import = array( - 'sidebar' => $use_sidebar_id, - 'sidebar_old' => $sidebar_id, - 'widget' => $widget, - 'widget_type' => $id_base, - 'widget_id' => $new_instance_id, - 'widget_id_old' => $widget_instance_id, - 'widget_id_num' => $new_instance_id_number, - 'widget_id_num_old' => $instance_id_number, - ); - - do_action( 'wie_after_widget_import', $after_widget_import ); // phpcs:ignore -- Keep the plugin prefix. - - // Success message. - if ( $sidebar_available ) { - $widget_message_type = 'success'; - $widget_message = esc_html__( 'Imported', 'widget-importer-exporter' ); - } else { - $widget_message_type = 'warning'; - $widget_message = esc_html__( 'Imported to Inactive', 'widget-importer-exporter' ); - } - } - - // Result for widget instance. - $results[ $sidebar_id ]['widgets'][ $widget_instance_id ]['name'] = isset( $available_widgets[ $id_base ]['name'] ) ? $available_widgets[ $id_base ]['name'] : $id_base; // Widget name or ID if name not available (not supported by site). - $results[ $sidebar_id ]['widgets'][ $widget_instance_id ]['title'] = ! empty( $widget['title'] ) ? $widget['title'] : esc_html__( 'No Title', 'widget-importer-exporter' ); // Show "No Title" if widget instance is untitled. - $results[ $sidebar_id ]['widgets'][ $widget_instance_id ]['message_type'] = $widget_message_type; - $results[ $sidebar_id ]['widgets'][ $widget_instance_id ]['message'] = $widget_message; - } - } - - // Hook after import. - do_action( 'wie_after_import' ); // phpcs:ignore -- Keep the plugin prefix. - - // Return results. - return apply_filters( 'wie_import_results', $results ); // phpcs:ignore -- Keep the plugin prefix. - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/libs/wxr-importer/WPImporterLogger.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/libs/wxr-importer/WPImporterLogger.php deleted file mode 100644 index 08183915..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/libs/wxr-importer/WPImporterLogger.php +++ /dev/null @@ -1,138 +0,0 @@ -log( 'emergency', $message, $context ); - } - - /** - * Action must be taken immediately. - * - * Example: Entire website down, database unavailable, etc. This should - * trigger the SMS alerts and wake you up. - * - * @param string $message - * @param array $context - * @return null - */ - public function alert( $message, array $context = array() ) { - return $this->log( 'alert', $message, $context ); - } - - /** - * Critical conditions. - * - * Example: Application component unavailable, unexpected exception. - * - * @param string $message - * @param array $context - * @return null - */ - public function critical( $message, array $context = array() ) { - return $this->log( 'critical', $message, $context ); - } - - /** - * Runtime errors that do not require immediate action but should typically - * be logged and monitored. - * - * @param string $message - * @param array $context - * @return null - */ - public function error( $message, array $context = array()) { - return $this->log( 'error', $message, $context ); - } - - /** - * Exceptional occurrences that are not errors. - * - * Example: Use of deprecated APIs, poor use of an API, undesirable things - * that are not necessarily wrong. - * - * @param string $message - * @param array $context - * @return null - */ - public function warning( $message, array $context = array() ) { - return $this->log( 'warning', $message, $context ); - } - - /** - * Normal but significant events. - * - * @param string $message - * @param array $context - * @return null - */ - public function notice( $message, array $context = array() ) { - return $this->log( 'notice', $message, $context ); - } - - /** - * Interesting events. - * - * Example: User logs in, SQL logs. - * - * @param string $message - * @param array $context - * @return null - */ - public function info( $message, array $context = array() ) { - return $this->log( 'info', $message, $context ); - } - - /** - * Detailed debug information. - * - * @param string $message - * @param array $context - * @return null - */ - public function debug( $message, array $context = array() ) { - return $this->log( 'debug', $message, $context ); - } - - /** - * Logs with an arbitrary level. - * - * @param mixed $level - * @param string $message - * @param array $context - * @return null - */ - public function log( $level, $message, array $context = array() ) { - $this->messages[] = array( - 'timestamp' => time(), - 'level' => $level, - 'message' => $message, - 'context' => $context, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/libs/wxr-importer/WXRImportInfo.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/libs/wxr-importer/WXRImportInfo.php deleted file mode 100644 index a7e75aa0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/site-library/libs/wxr-importer/WXRImportInfo.php +++ /dev/null @@ -1,16 +0,0 @@ -` tag at the start of the file. - * - * @var string - */ - protected $version = '1.0'; - - // information to import from WXR file - protected $categories = array(); - protected $tags = array(); - protected $base_url = ''; - - // TODO: REMOVE THESE - protected $processed_terms = array(); - protected $processed_posts = array(); - protected $processed_menu_items = array(); - protected $menu_item_orphans = array(); - protected $missing_menu_items = array(); - - // NEW STYLE - protected $mapping = array(); - protected $requires_remapping = array(); - protected $exists = array(); - protected $user_slug_override = array(); - - protected $url_remap = array(); - protected $featured_images = array(); - - /** - * Logger instance. - * - * @var WP_Importer_Logger - */ - protected $logger; - - /** - * Constructor - * - * @param array $options { - * @var bool $prefill_existing_posts Should we prefill `post_exists` calls? (True prefills and uses more memory, false checks once per imported post and takes longer. Default is true.) - * @var bool $prefill_existing_comments Should we prefill `comment_exists` calls? (True prefills and uses more memory, false checks once per imported comment and takes longer. Default is true.) - * @var bool $prefill_existing_terms Should we prefill `term_exists` calls? (True prefills and uses more memory, false checks once per imported term and takes longer. Default is true.) - * @var bool $update_attachment_guids Should attachment GUIDs be updated to the new URL? (True updates the GUID, which keeps compatibility with v1, false doesn't update, and allows deduplication and reimporting. Default is false.) - * @var bool $fetch_attachments Fetch attachments from the remote server. (True fetches and creates attachment posts, false skips attachments. Default is false.) - * @var bool $aggressive_url_search Should we search/replace for URLs aggressively? (True searches all posts' content for old URLs and replaces, false checks for `` only. Default is false.) - * @var int $default_author User ID to use if author is missing or invalid. (Default is null, which leaves posts unassigned.) - * } - */ - public function __construct( $options = array() ) { - // Initialize some important variables - $empty_types = array( - 'post' => array(), - 'comment' => array(), - 'term' => array(), - 'user' => array(), - ); - - $this->mapping = $empty_types; - $this->mapping['user_slug'] = array(); - $this->mapping['term_id'] = array(); - $this->requires_remapping = $empty_types; - $this->exists = $empty_types; - - $this->options = wp_parse_args( $options, array( - 'prefill_existing_posts' => true, - 'prefill_existing_comments' => true, - 'prefill_existing_terms' => true, - 'update_attachment_guids' => false, - 'fetch_attachments' => false, - 'aggressive_url_search' => false, - 'default_author' => null, - ) ); - } - - public function set_logger( $logger ) { - $this->logger = $logger; - } - - /** - * Get a stream reader for the file. - * - * @param string $file Path to the XML file. - * @return XMLReader|WP_Error Reader instance on success, error otherwise. - */ - protected function get_reader( $file ) { - // Avoid loading external entities for security - $old_value = null; - if ( function_exists( 'libxml_disable_entity_loader' ) ) { - // $old_value = libxml_disable_entity_loader( true ); - } - - $reader = new \XMLReader(); - $status = $reader->open( $file ); - - if ( ! is_null( $old_value ) ) { - // libxml_disable_entity_loader( $old_value ); - } - - if ( ! $status ) { - return new \WP_Error( 'wxr_importer.cannot_parse', __( 'Could not open the file for parsing', 'wordpress-importer' ) ); - } - - return $reader; - } - - /** - * The main controller for the actual import stage. - * - * @param string $file Path to the WXR file for importing - */ - public function get_preliminary_information( $file ) { - // Let's run the actual importer now, woot - $reader = $this->get_reader( $file ); - if ( is_wp_error( $reader ) ) { - return $reader; - } - - // Set the version to compatibility mode first - $this->version = '1.0'; - - // Start parsing! - $data = new WXRImportInfo(); - while ( $reader->read() ) { - // Only deal with element opens - if ( $reader->nodeType !== \XMLReader::ELEMENT ) { - continue; - } - - switch ( $reader->name ) { - case 'wp:wxr_version': - // Upgrade to the correct version - $this->version = $reader->readString(); - - if ( version_compare( $this->version, self::MAX_WXR_VERSION, '>' ) ) { - $this->logger->warning( sprintf( - __( 'This WXR file (version %s) is newer than the importer (version %s) and may not be supported. Please consider updating.', 'wordpress-importer' ), - $this->version, - self::MAX_WXR_VERSION - ) ); - } - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'generator': - $data->generator = $reader->readString(); - $reader->next(); - break; - - case 'title': - $data->title = $reader->readString(); - $reader->next(); - break; - - case 'wp:base_site_url': - $data->siteurl = $reader->readString(); - $reader->next(); - break; - - case 'wp:base_blog_url': - $data->home = $reader->readString(); - $reader->next(); - break; - - case 'wp:author': - $node = $reader->expand(); - - $parsed = $this->parse_author_node( $node ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $data->users[] = $parsed; - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'item': - $node = $reader->expand(); - $parsed = $this->parse_post_node( $node ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - if ( $parsed['data']['post_type'] === 'attachment' ) { - $data->media_count++; - } else { - $data->post_count++; - } - $data->comment_count += count( $parsed['comments'] ); - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:category': - case 'wp:tag': - case 'wp:term': - $data->term_count++; - - // Handled everything in this node, move on to the next - $reader->next(); - break; - } - } - - $data->version = $this->version; - - return $data; - } - - /** - * The main controller for the actual import stage. - * - * @param string $file Path to the WXR file for importing - */ - public function parse_authors( $file ) { - // Let's run the actual importer now, woot - $reader = $this->get_reader( $file ); - if ( is_wp_error( $reader ) ) { - return $reader; - } - - // Set the version to compatibility mode first - $this->version = '1.0'; - - // Start parsing! - $authors = array(); - while ( $reader->read() ) { - // Only deal with element opens - if ( $reader->nodeType !== \XMLReader::ELEMENT ) { - continue; - } - - switch ( $reader->name ) { - case 'wp:wxr_version': - // Upgrade to the correct version - $this->version = $reader->readString(); - - if ( version_compare( $this->version, self::MAX_WXR_VERSION, '>' ) ) { - $this->logger->warning( sprintf( - __( 'This WXR file (version %s) is newer than the importer (version %s) and may not be supported. Please consider updating.', 'wordpress-importer' ), - $this->version, - self::MAX_WXR_VERSION - ) ); - } - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:author': - $node = $reader->expand(); - - $parsed = $this->parse_author_node( $node ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $authors[] = $parsed; - - // Handled everything in this node, move on to the next - $reader->next(); - break; - } - } - - return $authors; - } - - /** - * The main controller for the actual import stage. - * - * @param string $file Path to the WXR file for importing - */ - public function import( $file ) { - add_filter( 'import_post_meta_key', array( $this, 'is_valid_meta_key' ) ); - add_filter( 'http_request_timeout', array( &$this, 'bump_request_timeout' ) ); - - /* - * Elementor fix for excessive use of `wp_slash` after our update v3.0.2. - * Method in Elementor: \Elementor\Compatibility::register_actions - * https://wordpress.org/support/topic/version-2-6-0-breaks-every-elementor-theme/ - * - * This can be removed after Elementor skips the functionality in above method if our plugin is in use. - */ - if ( method_exists( '\Elementor\Compatibility', 'on_wxr_importer_pre_process_post_meta' ) ) { - remove_action( 'wxr_importer.pre_process.post_meta', array( 'Elementor\Compatibility', 'on_wxr_importer_pre_process_post_meta' ) ); - } - - $result = $this->import_start( $file ); - if ( is_wp_error( $result ) ) { - return $result; - } - - // Let's run the actual importer now, woot - $reader = $this->get_reader( $file ); - if ( is_wp_error( $reader ) ) { - return $reader; - } - - // Set the version to compatibility mode first - $this->version = '1.0'; - - // Reset other variables - $this->base_url = ''; - - // Start parsing! - while ( $reader->read() ) { - // Only deal with element opens - if ( $reader->nodeType !== \XMLReader::ELEMENT ) { - continue; - } - - switch ( $reader->name ) { - case 'wp:wxr_version': - // Upgrade to the correct version - $this->version = $reader->readString(); - - if ( version_compare( $this->version, self::MAX_WXR_VERSION, '>' ) ) { - $this->logger->warning( sprintf( - __( 'This WXR file (version %s) is newer than the importer (version %s) and may not be supported. Please consider updating.', 'wordpress-importer' ), - $this->version, - self::MAX_WXR_VERSION - ) ); - } - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:base_site_url': - $this->base_url = $reader->readString(); - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'item': - $node = $reader->expand(); - $parsed = $this->parse_post_node( $node ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $this->process_post( $parsed['data'], $parsed['meta'], $parsed['comments'], $parsed['terms'] ); - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:author': - $node = $reader->expand(); - - $parsed = $this->parse_author_node( $node ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $status = $this->process_author( $parsed['data'], $parsed['meta'] ); - if ( is_wp_error( $status ) ) { - $this->log_error( $status ); - } - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:category': - $node = $reader->expand(); - - $parsed = $this->parse_term_node( $node, 'category' ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $status = $this->process_term( $parsed['data'], $parsed['meta'] ); - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:tag': - $node = $reader->expand(); - - $parsed = $this->parse_term_node( $node, 'tag' ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $status = $this->process_term( $parsed['data'], $parsed['meta'] ); - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - case 'wp:term': - $node = $reader->expand(); - - $parsed = $this->parse_term_node( $node ); - if ( is_wp_error( $parsed ) ) { - $this->log_error( $parsed ); - - // Skip the rest of this post - $reader->next(); - break; - } - - $status = $this->process_term( $parsed['data'], $parsed['meta'] ); - - // Handled everything in this node, move on to the next - $reader->next(); - break; - - default: - // Skip this node, probably handled by something already - break; - } - } - - // Now that we've done the main processing, do any required - // post-processing and remapping. - $this->post_process(); - - if ( $this->options['aggressive_url_search'] ) { - $this->replace_attachment_urls_in_content(); - } - - $this->remap_featured_images(); - - $this->import_end(); - } - - /** - * Log an error instance to the logger. - * - * @param WP_Error $error Error instance to log. - */ - protected function log_error( WP_Error $error ) { - $this->logger->warning( $error->get_error_message() ); - - // Log the data as debug info too - $data = $error->get_error_data(); - if ( ! empty( $data ) ) { - $this->logger->debug( var_export( $data, true ) ); - } - } - - /** - * Parses the WXR file and prepares us for the task of processing parsed data - * - * @param string $file Path to the WXR file for importing - */ - protected function import_start( $file ) { - if ( ! is_file( $file ) ) { - return new \WP_Error( 'wxr_importer.file_missing', __( 'The file does not exist, please try again.', 'wordpress-importer' ) ); - } - - // Suspend bunches of stuff in WP core - wp_defer_term_counting( true ); - wp_defer_comment_counting( true ); - wp_suspend_cache_invalidation( true ); - - // Prefill exists calls if told to - if ( $this->options['prefill_existing_posts'] ) { - $this->prefill_existing_posts(); - } - if ( $this->options['prefill_existing_comments'] ) { - $this->prefill_existing_comments(); - } - if ( $this->options['prefill_existing_terms'] ) { - $this->prefill_existing_terms(); - } - - /** - * Begin the import. - * - * Fires before the import process has begun. If you need to suspend - * caching or heavy processing on hooks, do so here. - */ - do_action( 'generate_import_start' ); - } - - /** - * Performs post-import cleanup of files and the cache - */ - protected function import_end() { - // Re-enable stuff in core - wp_suspend_cache_invalidation( false ); - wp_cache_flush(); - foreach ( get_taxonomies() as $tax ) { - delete_option( "{$tax}_children" ); - _get_term_hierarchy( $tax ); - } - - wp_defer_term_counting( false ); - wp_defer_comment_counting( false ); - - /** - * Complete the import. - * - * Fires after the import process has finished. If you need to update - * your cache or re-enable processing, do so here. - */ - do_action( 'generate_import_end' ); - } - - /** - * Set the user mapping. - * - * @param array $mapping List of map arrays (containing `old_slug`, `old_id`, `new_id`) - */ - public function set_user_mapping( $mapping ) { - foreach ( $mapping as $map ) { - if ( empty( $map['old_slug'] ) || empty( $map['old_id'] ) || empty( $map['new_id'] ) ) { - $this->logger->warning( __( 'Invalid author mapping', 'wordpress-importer' ) ); - $this->logger->debug( var_export( $map, true ) ); - continue; - } - - $old_slug = $map['old_slug']; - $old_id = $map['old_id']; - $new_id = $map['new_id']; - - $this->mapping['user'][ $old_id ] = $new_id; - $this->mapping['user_slug'][ $old_slug ] = $new_id; - } - } - - /** - * Set the user slug overrides. - * - * Allows overriding the slug in the import with a custom/renamed version. - * - * @param string[] $overrides Map of old slug to new slug. - */ - public function set_user_slug_overrides( $overrides ) { - foreach ( $overrides as $original => $renamed ) { - $this->user_slug_override[ $original ] = $renamed; - } - } - - /** - * Parse a post node into post data. - * - * @param DOMElement $node Parent node of post data (typically `item`). - * @return array|WP_Error Post data array on success, error otherwise. - */ - protected function parse_post_node( $node ) { - $data = array(); - $meta = array(); - $comments = array(); - $terms = array(); - - foreach ( $node->childNodes as $child ) { - // We only care about child elements - if ( $child->nodeType !== XML_ELEMENT_NODE ) { - continue; - } - - switch ( $child->tagName ) { - case 'wp:post_type': - $data['post_type'] = $child->textContent; - break; - - case 'title': - $data['post_title'] = $child->textContent; - break; - - case 'guid': - $data['guid'] = $child->textContent; - break; - - case 'dc:creator': - $data['post_author'] = $child->textContent; - break; - - case 'content:encoded': - $data['post_content'] = $child->textContent; - break; - - case 'excerpt:encoded': - $data['post_excerpt'] = $child->textContent; - break; - - case 'wp:post_id': - $data['post_id'] = $child->textContent; - break; - - case 'wp:post_date': - $data['post_date'] = $child->textContent; - break; - - case 'wp:post_date_gmt': - $data['post_date_gmt'] = $child->textContent; - break; - - case 'wp:comment_status': - $data['comment_status'] = $child->textContent; - break; - - case 'wp:ping_status': - $data['ping_status'] = $child->textContent; - break; - - case 'wp:post_name': - $data['post_name'] = $child->textContent; - break; - - case 'wp:status': - $data['post_status'] = $child->textContent; - - if ( $data['post_status'] === 'auto-draft' ) { - // Bail now - return new \WP_Error( - 'wxr_importer.post.cannot_import_draft', - __( 'Cannot import auto-draft posts' ), - $data - ); - } - break; - - case 'wp:post_parent': - $data['post_parent'] = $child->textContent; - break; - - case 'wp:menu_order': - $data['menu_order'] = $child->textContent; - break; - - case 'wp:post_password': - $data['post_password'] = $child->textContent; - break; - - case 'wp:is_sticky': - $data['is_sticky'] = $child->textContent; - break; - - case 'wp:attachment_url': - $data['attachment_url'] = $child->textContent; - break; - - case 'wp:postmeta': - $meta_item = $this->parse_meta_node( $child ); - if ( ! empty( $meta_item ) ) { - $meta[] = $meta_item; - } - break; - - case 'wp:comment': - $comment_item = $this->parse_comment_node( $child ); - if ( ! empty( $comment_item ) ) { - $comments[] = $comment_item; - } - break; - - case 'category': - $term_item = $this->parse_category_node( $child ); - if ( ! empty( $term_item ) ) { - $terms[] = $term_item; - } - break; - } - } - - return compact( 'data', 'meta', 'comments', 'terms' ); - } - - /** - * Create new posts based on import information - * - * Posts marked as having a parent which doesn't exist will become top level items. - * Doesn't create a new post if: the post type doesn't exist, the given post ID - * is already noted as imported or a post with the same title and date already exists. - * Note that new/updated terms, comments and meta are imported for the last of the above. - */ - protected function process_post( $data, $meta, $comments, $terms ) { - /** - * Pre-process post data. - * - * @param array $data Post data. (Return empty to skip.) - * @param array $meta Meta data. - * @param array $comments Comments on the post. - * @param array $terms Terms on the post. - */ - $data = apply_filters( 'wxr_importer.pre_process.post', $data, $meta, $comments, $terms ); - if ( empty( $data ) ) { - return false; - } - - $original_id = isset( $data['post_id'] ) ? (int) $data['post_id'] : 0; - $parent_id = isset( $data['post_parent'] ) ? (int) $data['post_parent'] : 0; - $author_id = isset( $data['post_author'] ) ? (int) $data['post_author'] : 0; - - // Have we already processed this? - if ( isset( $this->mapping['post'][ $original_id ] ) ) { - return; - } - - $post_type_object = get_post_type_object( $data['post_type'] ); - - // Is this type even valid? - if ( ! $post_type_object ) { - $this->logger->warning( sprintf( - __( 'Failed to import "%s": Invalid post type %s', 'wordpress-importer' ), - $data['post_title'], - $data['post_type'] - ) ); - return false; - } - - $post_exists = $this->post_exists( $data ); - if ( $post_exists ) { - $this->logger->info( sprintf( - __( '%s "%s" already exists.', 'wordpress-importer' ), - $post_type_object->labels->singular_name, - $data['post_title'] - ) ); - - /** - * Post processing already imported. - * - * @param array $data Raw data imported for the post. - */ - do_action( 'wxr_importer.process_already_imported.post', $data ); - - // Even though this post already exists, new comments might need importing - $this->process_comments( $comments, $original_id, $data, $post_exists ); - - return false; - } - - // Map the parent post, or mark it as one we need to fix - $requires_remapping = false; - if ( $parent_id ) { - if ( isset( $this->mapping['post'][ $parent_id ] ) ) { - $data['post_parent'] = $this->mapping['post'][ $parent_id ]; - } else { - $meta[] = array( 'key' => '_wxr_import_parent', 'value' => $parent_id ); - $requires_remapping = true; - - $data['post_parent'] = 0; - } - } - - // Map the author, or mark it as one we need to fix - $author = sanitize_user( $data['post_author'], true ); - if ( empty( $author ) ) { - // Missing or invalid author, use default if available. - $data['post_author'] = $this->options['default_author']; - } elseif ( isset( $this->mapping['user_slug'][ $author ] ) ) { - $data['post_author'] = $this->mapping['user_slug'][ $author ]; - } else { - $meta[] = array( 'key' => '_wxr_import_user_slug', 'value' => $author ); - $requires_remapping = true; - - $data['post_author'] = (int) get_current_user_id(); - } - - // Does the post look like it contains attachment images? - if ( preg_match( self::REGEX_HAS_ATTACHMENT_REFS, $data['post_content'] ) ) { - $meta[] = array( 'key' => '_wxr_import_has_attachment_refs', 'value' => true ); - $requires_remapping = true; - } - - // Whitelist to just the keys we allow - $postdata = array( - 'import_id' => $data['post_id'], - ); - $allowed = array( - 'post_author' => true, - 'post_date' => true, - 'post_date_gmt' => true, - 'post_content' => true, - 'post_excerpt' => true, - 'post_title' => true, - 'post_status' => true, - 'post_name' => true, - 'comment_status' => true, - 'ping_status' => true, - 'guid' => true, - 'post_parent' => true, - 'menu_order' => true, - 'post_type' => true, - 'post_password' => true, - ); - foreach ( $data as $key => $value ) { - if ( ! isset( $allowed[ $key ] ) ) { - continue; - } - - $postdata[ $key ] = $data[ $key ]; - } - - $postdata = apply_filters( 'wp_import_post_data_processed', wp_slash( $postdata ), $data ); - - if ( 'attachment' === $postdata['post_type'] ) { - if ( ! $this->options['fetch_attachments'] ) { - $this->logger->notice( sprintf( - __( 'Skipping attachment "%s", fetching attachments disabled' ), - $data['post_title'] - ) ); - /** - * Post processing skipped. - * - * @param array $data Raw data imported for the post. - * @param array $meta Raw meta data, already processed by {@see process_post_meta}. - */ - do_action( 'wxr_importer.process_skipped.post', $data, $meta ); - return false; - } - $remote_url = ! empty( $data['attachment_url'] ) ? $data['attachment_url'] : $data['guid']; - $post_id = $this->process_attachment( $postdata, $meta, $remote_url ); - } else { - $post_id = wp_insert_post( $postdata, true ); - do_action( 'wp_import_insert_post', $post_id, $original_id, $postdata, $data ); - } - - if ( is_wp_error( $post_id ) ) { - $this->logger->error( sprintf( - __( 'Failed to import "%s" (%s)', 'wordpress-importer' ), - $data['post_title'], - $post_type_object->labels->singular_name - ) ); - $this->logger->debug( $post_id->get_error_message() ); - - /** - * Post processing failed. - * - * @param WP_Error $post_id Error object. - * @param array $data Raw data imported for the post. - * @param array $meta Raw meta data, already processed by {@see process_post_meta}. - * @param array $comments Raw comment data, already processed by {@see process_comments}. - * @param array $terms Raw term data, already processed. - */ - do_action( 'wxr_importer.process_failed.post', $post_id, $data, $meta, $comments, $terms ); - return false; - } - - // Ensure stickiness is handled correctly too - if ( $data['is_sticky'] === '1' ) { - stick_post( $post_id ); - } - - // map pre-import ID to local ID - $this->mapping['post'][ $original_id ] = (int) $post_id; - if ( $requires_remapping ) { - $this->requires_remapping['post'][ $post_id ] = true; - } - $this->mark_post_exists( $data, $post_id ); - - $this->logger->info( sprintf( - __( 'Imported "%s" (%s)', 'wordpress-importer' ), - $data['post_title'], - $post_type_object->labels->singular_name - ) ); - $this->logger->debug( sprintf( - __( 'Post %d remapped to %d', 'wordpress-importer' ), - $original_id, - $post_id - ) ); - - // Handle the terms too - $terms = apply_filters( 'wp_import_post_terms', $terms, $post_id, $data ); - - if ( ! empty( $terms ) ) { - $term_ids = array(); - foreach ( $terms as $term ) { - $taxonomy = $term['taxonomy']; - $key = sha1( $taxonomy . ':' . $term['slug'] ); - - if ( isset( $this->mapping['term'][ $key ] ) ) { - $term_ids[ $taxonomy ][] = (int) $this->mapping['term'][ $key ]; - } else { - $meta[] = array( 'key' => '_wxr_import_term', 'value' => $term ); - $requires_remapping = true; - } - } - - foreach ( $term_ids as $tax => $ids ) { - $tt_ids = wp_set_post_terms( $post_id, $ids, $tax ); - do_action( 'wp_import_set_post_terms', $tt_ids, $ids, $tax, $post_id, $data ); - } - } - - $this->process_comments( $comments, $post_id, $data ); - $this->process_post_meta( $meta, $post_id, $data ); - - if ( 'nav_menu_item' === $data['post_type'] ) { - $this->process_menu_item_meta( $post_id, $data, $meta ); - } - - /** - * Post processing completed. - * - * @param int $post_id New post ID. - * @param array $data Raw data imported for the post. - * @param array $meta Raw meta data, already processed by {@see process_post_meta}. - * @param array $comments Raw comment data, already processed by {@see process_comments}. - * @param array $terms Raw term data, already processed. - */ - do_action( 'wxr_importer.processed.post', $post_id, $data, $meta, $comments, $terms ); - } - - /** - * Attempt to create a new menu item from import data - * - * Fails for draft, orphaned menu items and those without an associated nav_menu - * or an invalid nav_menu term. If the post type or term object which the menu item - * represents doesn't exist then the menu item will not be imported (waits until the - * end of the import to retry again before discarding). - * - * @param array $item Menu item details from WXR file - */ - protected function process_menu_item_meta( $post_id, $data, $meta ) { - - $item_type = get_post_meta( $post_id, '_menu_item_type', true ); - $original_object_id = get_post_meta( $post_id, '_menu_item_object_id', true ); - $object_id = null; - - $this->logger->debug( sprintf( 'Processing menu item %s', $item_type ) ); - - $requires_remapping = false; - switch ( $item_type ) { - case 'taxonomy': - if ( isset( $this->mapping['term_id'][ $original_object_id ] ) ) { - $object_id = $this->mapping['term_id'][ $original_object_id ]; - } else { - add_post_meta( $post_id, '_wxr_import_menu_item', wp_slash( $original_object_id ) ); - $requires_remapping = true; - } - break; - - case 'post_type': - if ( isset( $this->mapping['post'][ $original_object_id ] ) ) { - $object_id = $this->mapping['post'][ $original_object_id ]; - } else { - add_post_meta( $post_id, '_wxr_import_menu_item', wp_slash( $original_object_id ) ); - $requires_remapping = true; - } - break; - - case 'custom': - // Custom refers to itself, wonderfully easy. - $object_id = $post_id; - break; - - default: - // associated object is missing or not imported yet, we'll retry later - $this->missing_menu_items[] = $item; - $this->logger->debug( 'Unknown menu item type' ); - break; - } - - if ( $requires_remapping ) { - $this->requires_remapping['post'][ $post_id ] = true; - } - - if ( empty( $object_id ) ) { - // Nothing needed here. - return; - } - - $this->logger->debug( sprintf( 'Menu item %d mapped to %d', $original_object_id, $object_id ) ); - update_post_meta( $post_id, '_menu_item_object_id', wp_slash( $object_id ) ); - } - - /** - * If fetching attachments is enabled then attempt to create a new attachment - * - * @param array $post Attachment post details from WXR - * @param string $url URL to fetch attachment from - * @return int|WP_Error Post ID on success, WP_Error otherwise - */ - protected function process_attachment( $post, $meta, $remote_url ) { - // try to use _wp_attached file for upload folder placement to ensure the same location as the export site - // e.g. location is 2003/05/image.jpg but the attachment post_date is 2010/09, see media_handle_upload() - $post['upload_date'] = $post['post_date']; - foreach ( $meta as $meta_item ) { - if ( $meta_item['key'] !== '_wp_attached_file' ) { - continue; - } - - if ( preg_match( '%^[0-9]{4}/[0-9]{2}%', $meta_item['value'], $matches ) ) { - $post['upload_date'] = $matches[0]; - } - break; - } - - // if the URL is absolute, but does not contain address, then upload it assuming base_site_url - if ( preg_match( '|^/[\w\W]+$|', $remote_url ) ) { - $remote_url = rtrim( $this->base_url, '/' ) . $remote_url; - } - - $upload = $this->fetch_remote_file( $remote_url, $post ); - if ( is_wp_error( $upload ) ) { - return $upload; - } - - $info = wp_check_filetype( $upload['file'] ); - if ( ! $info ) { - return new \WP_Error( 'attachment_processing_error', __( 'Invalid file type', 'wordpress-importer' ) ); - } - - $post['post_mime_type'] = $info['type']; - - // WP really likes using the GUID for display. Allow updating it. - // See https://core.trac.wordpress.org/ticket/33386 - if ( $this->options['update_attachment_guids'] ) { - $post['guid'] = $upload['url']; - } - - // as per wp-admin/includes/upload.php - $post_id = wp_insert_attachment( $post, $upload['file'] ); - if ( is_wp_error( $post_id ) ) { - return $post_id; - } - - $attachment_metadata = wp_generate_attachment_metadata( $post_id, $upload['file'] ); - wp_update_attachment_metadata( $post_id, $attachment_metadata ); - - // Map this image URL later if we need to - $this->url_remap[ $remote_url ] = $upload['url']; - - // If we have a HTTPS URL, ensure the HTTP URL gets replaced too - if ( substr( $remote_url, 0, 8 ) === 'https://' ) { - $insecure_url = 'http' . substr( $remote_url, 5 ); - $this->url_remap[ $insecure_url ] = $upload['url']; - } - - if ( $this->options['aggressive_url_search'] ) { - // remap resized image URLs, works by stripping the extension and remapping the URL stub. - /*if ( preg_match( '!^image/!', $info['type'] ) ) { - $parts = pathinfo( $remote_url ); - $name = basename( $parts['basename'], ".{$parts['extension']}" ); // PATHINFO_FILENAME in PHP 5.2 - - $parts_new = pathinfo( $upload['url'] ); - $name_new = basename( $parts_new['basename'], ".{$parts_new['extension']}" ); - - $this->url_remap[$parts['dirname'] . '/' . $name] = $parts_new['dirname'] . '/' . $name_new; - }*/ - } - - return $post_id; - } - - /** - * Parse a meta node into meta data. - * - * @param DOMElement $node Parent node of meta data (typically `wp:postmeta` or `wp:commentmeta`). - * @return array|null Meta data array on success, or null on error. - */ - protected function parse_meta_node( $node ) { - foreach ( $node->childNodes as $child ) { - // We only care about child elements - if ( $child->nodeType !== XML_ELEMENT_NODE ) { - continue; - } - - switch ( $child->tagName ) { - case 'wp:meta_key': - $key = $child->textContent; - break; - - case 'wp:meta_value': - $value = $child->textContent; - break; - } - } - - if ( empty( $key ) || empty( $value ) ) { - return null; - } - - return compact( 'key', 'value' ); - } - - /** - * Process and import post meta items. - * - * @param array $meta List of meta data arrays - * @param int $post_id Post to associate with - * @param array $post Post data - * @return int|WP_Error Number of meta items imported on success, error otherwise. - */ - protected function process_post_meta( $meta, $post_id, $post ) { - if ( empty( $meta ) ) { - return true; - } - - foreach ( $meta as $meta_item ) { - /** - * Pre-process post meta data. - * - * @param array $meta_item Meta data. (Return empty to skip.) - * @param int $post_id Post the meta is attached to. - */ - $meta_item = apply_filters( 'wxr_importer.pre_process.post_meta', $meta_item, $post_id ); - if ( empty( $meta_item ) ) { - return false; - } - - $key = apply_filters( 'import_post_meta_key', $meta_item['key'], $post_id, $post ); - $value = false; - - if ( '_edit_last' === $key ) { - $value = intval( $meta_item['value'] ); - if ( ! isset( $this->mapping['user'][ $value ] ) ) { - // Skip! - continue; - } - - $value = $this->mapping['user'][ $value ]; - } - - if ( $key ) { - // export gets meta straight from the DB so could have a serialized string - if ( ! $value ) { - $value = maybe_unserialize( $meta_item['value'] ); - } - - if ( function_exists( 'wp_slash_strings_only' ) ) { - add_post_meta( $post_id, wp_slash( $key ), wp_slash_strings_only( $value ) ); - } else { - add_post_meta( $post_id, $key, $value ); - } - - do_action( 'import_post_meta', $post_id, $key, $value ); - - // if the post has a featured image, take note of this in case of remap - if ( '_thumbnail_id' === $key ) { - $this->featured_images[ $post_id ] = (int) $value; - } - } - } - - return true; - } - - /** - * Parse a comment node into comment data. - * - * @param DOMElement $node Parent node of comment data (typically `wp:comment`). - * @return array Comment data array. - */ - protected function parse_comment_node( $node ) { - $data = array( - 'commentmeta' => array(), - ); - - foreach ( $node->childNodes as $child ) { - // We only care about child elements - if ( $child->nodeType !== XML_ELEMENT_NODE ) { - continue; - } - - switch ( $child->tagName ) { - case 'wp:comment_id': - $data['comment_id'] = $child->textContent; - break; - case 'wp:comment_author': - $data['comment_author'] = $child->textContent; - break; - - case 'wp:comment_author_email': - $data['comment_author_email'] = $child->textContent; - break; - - case 'wp:comment_author_IP': - $data['comment_author_IP'] = $child->textContent; - break; - - case 'wp:comment_author_url': - $data['comment_author_url'] = $child->textContent; - break; - - case 'wp:comment_user_id': - $data['comment_user_id'] = $child->textContent; - break; - - case 'wp:comment_date': - $data['comment_date'] = $child->textContent; - break; - - case 'wp:comment_date_gmt': - $data['comment_date_gmt'] = $child->textContent; - break; - - case 'wp:comment_content': - $data['comment_content'] = $child->textContent; - break; - - case 'wp:comment_approved': - $data['comment_approved'] = $child->textContent; - break; - - case 'wp:comment_type': - $data['comment_type'] = $child->textContent; - break; - - case 'wp:comment_parent': - $data['comment_parent'] = $child->textContent; - break; - - case 'wp:commentmeta': - $meta_item = $this->parse_meta_node( $child ); - if ( ! empty( $meta_item ) ) { - $data['commentmeta'][] = $meta_item; - } - break; - } - } - - return $data; - } - - /** - * Process and import comment data. - * - * @param array $comments List of comment data arrays. - * @param int $post_id Post to associate with. - * @param array $post Post data. - * @return int|WP_Error Number of comments imported on success, error otherwise. - */ - protected function process_comments( $comments, $post_id, $post, $post_exists = false ) { - - $comments = apply_filters( 'wp_import_post_comments', $comments, $post_id, $post ); - if ( empty( $comments ) ) { - return 0; - } - - $num_comments = 0; - - // Sort by ID to avoid excessive remapping later - usort( $comments, array( $this, 'sort_comments_by_id' ) ); - - foreach ( $comments as $key => $comment ) { - /** - * Pre-process comment data - * - * @param array $comment Comment data. (Return empty to skip.) - * @param int $post_id Post the comment is attached to. - */ - $comment = apply_filters( 'wxr_importer.pre_process.comment', $comment, $post_id ); - if ( empty( $comment ) ) { - return false; - } - - $original_id = isset( $comment['comment_id'] ) ? (int) $comment['comment_id'] : 0; - $parent_id = isset( $comment['comment_parent'] ) ? (int) $comment['comment_parent'] : 0; - $author_id = isset( $comment['comment_user_id'] ) ? (int) $comment['comment_user_id'] : 0; - - // if this is a new post we can skip the comment_exists() check - // TODO: Check comment_exists for performance - if ( $post_exists ) { - $existing = $this->comment_exists( $comment ); - if ( $existing ) { - - /** - * Comment processing already imported. - * - * @param array $comment Raw data imported for the comment. - */ - do_action( 'wxr_importer.process_already_imported.comment', $comment ); - - $this->mapping['comment'][ $original_id ] = $existing; - continue; - } - } - - // Remove meta from the main array - $meta = isset( $comment['commentmeta'] ) ? $comment['commentmeta'] : array(); - unset( $comment['commentmeta'] ); - - // Map the parent comment, or mark it as one we need to fix - $requires_remapping = false; - if ( $parent_id ) { - if ( isset( $this->mapping['comment'][ $parent_id ] ) ) { - $comment['comment_parent'] = $this->mapping['comment'][ $parent_id ]; - } else { - // Prepare for remapping later - $meta[] = array( 'key' => '_wxr_import_parent', 'value' => $parent_id ); - $requires_remapping = true; - - // Wipe the parent for now - $comment['comment_parent'] = 0; - } - } - - // Map the author, or mark it as one we need to fix - if ( $author_id ) { - if ( isset( $this->mapping['user'][ $author_id ] ) ) { - $comment['user_id'] = $this->mapping['user'][ $author_id ]; - } else { - // Prepare for remapping later - $meta[] = array( 'key' => '_wxr_import_user', 'value' => $author_id ); - $requires_remapping = true; - - // Wipe the user for now - $comment['user_id'] = 0; - } - } - - // Run standard core filters - $comment['comment_post_ID'] = $post_id; - $comment = wp_filter_comment( $comment ); - - // wp_insert_comment expects slashed data - $comment_id = wp_insert_comment( wp_slash( $comment ) ); - $this->mapping['comment'][ $original_id ] = $comment_id; - if ( $requires_remapping ) { - $this->requires_remapping['comment'][ $comment_id ] = true; - } - $this->mark_comment_exists( $comment, $comment_id ); - - /** - * Comment has been imported. - * - * @param int $comment_id New comment ID - * @param array $comment Comment inserted (`comment_id` item refers to the original ID) - * @param int $post_id Post parent of the comment - * @param array $post Post data - */ - do_action( 'wp_import_insert_comment', $comment_id, $comment, $post_id, $post ); - - // Process the meta items - foreach ( $meta as $meta_item ) { - $value = maybe_unserialize( $meta_item['value'] ); - add_comment_meta( $comment_id, wp_slash( $meta_item['key'] ), wp_slash( $value ) ); - } - - /** - * Post processing completed. - * - * @param int $post_id New post ID. - * @param array $comment Raw data imported for the comment. - * @param array $meta Raw meta data, already processed by {@see process_post_meta}. - * @param array $post_id Parent post ID. - */ - do_action( 'wxr_importer.processed.comment', $comment_id, $comment, $meta, $post_id ); - - $num_comments++; - } - - return $num_comments; - } - - protected function parse_category_node( $node ) { - $data = array( - // Default taxonomy to "category", since this is a `` tag - 'taxonomy' => 'category', - ); - $meta = array(); - - if ( $node->hasAttribute( 'domain' ) ) { - $data['taxonomy'] = $node->getAttribute( 'domain' ); - } - if ( $node->hasAttribute( 'nicename' ) ) { - $data['slug'] = $node->getAttribute( 'nicename' ); - } - - $data['name'] = $node->textContent; - - if ( empty( $data['slug'] ) ) { - return null; - } - - // Just for extra compatibility - if ( $data['taxonomy'] === 'tag' ) { - $data['taxonomy'] = 'post_tag'; - } - - return $data; - } - - /** - * Callback for `usort` to sort comments by ID - * - * @param array $a Comment data for the first comment - * @param array $b Comment data for the second comment - * @return int - */ - public static function sort_comments_by_id( $a, $b ) { - if ( empty( $a['comment_id'] ) ) { - return 1; - } - - if ( empty( $b['comment_id'] ) ) { - return -1; - } - - return $a['comment_id'] - $b['comment_id']; - } - - protected function parse_author_node( $node ) { - $data = array(); - $meta = array(); - foreach ( $node->childNodes as $child ) { - // We only care about child elements - if ( $child->nodeType !== XML_ELEMENT_NODE ) { - continue; - } - - switch ( $child->tagName ) { - case 'wp:author_login': - $data['user_login'] = $child->textContent; - break; - - case 'wp:author_id': - $data['ID'] = $child->textContent; - break; - - case 'wp:author_email': - $data['user_email'] = $child->textContent; - break; - - case 'wp:author_display_name': - $data['display_name'] = $child->textContent; - break; - - case 'wp:author_first_name': - $data['first_name'] = $child->textContent; - break; - - case 'wp:author_last_name': - $data['last_name'] = $child->textContent; - break; - } - } - - return compact( 'data', 'meta' ); - } - - protected function process_author( $data, $meta ) { - /** - * Pre-process user data. - * - * @param array $data User data. (Return empty to skip.) - * @param array $meta Meta data. - */ - $data = apply_filters( 'wxr_importer.pre_process.user', $data, $meta ); - if ( empty( $data ) ) { - return false; - } - - // Have we already handled this user? - $original_id = isset( $data['ID'] ) ? $data['ID'] : 0; - $original_slug = $data['user_login']; - - if ( isset( $this->mapping['user'][ $original_id ] ) ) { - $existing = $this->mapping['user'][ $original_id ]; - - // Note the slug mapping if we need to too - if ( ! isset( $this->mapping['user_slug'][ $original_slug ] ) ) { - $this->mapping['user_slug'][ $original_slug ] = $existing; - } - - return false; - } - - if ( isset( $this->mapping['user_slug'][ $original_slug ] ) ) { - $existing = $this->mapping['user_slug'][ $original_slug ]; - - // Ensure we note the mapping too - $this->mapping['user'][ $original_id ] = $existing; - - return false; - } - - // Allow overriding the user's slug - $login = $original_slug; - if ( isset( $this->user_slug_override[ $login ] ) ) { - $login = $this->user_slug_override[ $login ]; - } - - $userdata = array( - 'user_login' => sanitize_user( $login, true ), - 'user_pass' => wp_generate_password(), - ); - - $allowed = array( - 'user_email' => true, - 'display_name' => true, - 'first_name' => true, - 'last_name' => true, - ); - foreach ( $data as $key => $value ) { - if ( ! isset( $allowed[ $key ] ) ) { - continue; - } - - $userdata[ $key ] = $data[ $key ]; - } - - $user_id = wp_insert_user( wp_slash( $userdata ) ); - if ( is_wp_error( $user_id ) ) { - $this->logger->error( sprintf( - __( 'Failed to import user "%s"', 'wordpress-importer' ), - $userdata['user_login'] - ) ); - $this->logger->debug( $user_id->get_error_message() ); - - /** - * User processing failed. - * - * @param WP_Error $user_id Error object. - * @param array $userdata Raw data imported for the user. - */ - do_action( 'wxr_importer.process_failed.user', $user_id, $userdata ); - return false; - } - - if ( $original_id ) { - $this->mapping['user'][ $original_id ] = $user_id; - } - $this->mapping['user_slug'][ $original_slug ] = $user_id; - - $this->logger->info( sprintf( - __( 'Imported user "%s"', 'wordpress-importer' ), - $userdata['user_login'] - ) ); - $this->logger->debug( sprintf( - __( 'User %d remapped to %d', 'wordpress-importer' ), - $original_id, - $user_id - ) ); - - // TODO: Implement meta handling once WXR includes it - /** - * User processing completed. - * - * @param int $user_id New user ID. - * @param array $userdata Raw data imported for the user. - */ - do_action( 'wxr_importer.processed.user', $user_id, $userdata ); - } - - protected function parse_term_node( $node, $type = 'term' ) { - $data = array(); - $meta = array(); - - $tag_name = array( - 'id' => 'wp:term_id', - 'taxonomy' => 'wp:term_taxonomy', - 'slug' => 'wp:term_slug', - 'parent' => 'wp:term_parent', - 'name' => 'wp:term_name', - 'description' => 'wp:term_description', - ); - $taxonomy = null; - - // Special casing! - switch ( $type ) { - case 'category': - $tag_name['slug'] = 'wp:category_nicename'; - $tag_name['parent'] = 'wp:category_parent'; - $tag_name['name'] = 'wp:cat_name'; - $tag_name['description'] = 'wp:category_description'; - $tag_name['taxonomy'] = null; - - $data['taxonomy'] = 'category'; - break; - - case 'tag': - $tag_name['slug'] = 'wp:tag_slug'; - $tag_name['parent'] = null; - $tag_name['name'] = 'wp:tag_name'; - $tag_name['description'] = 'wp:tag_description'; - $tag_name['taxonomy'] = null; - - $data['taxonomy'] = 'post_tag'; - break; - } - - foreach ( $node->childNodes as $child ) { - // We only care about child elements - if ( $child->nodeType !== XML_ELEMENT_NODE ) { - continue; - } - - $key = array_search( $child->tagName, $tag_name ); - if ( $key ) { - $data[ $key ] = $child->textContent; - } - } - - if ( empty( $data['taxonomy'] ) ) { - return null; - } - - // Compatibility with WXR 1.0 - if ( $data['taxonomy'] === 'tag' ) { - $data['taxonomy'] = 'post_tag'; - } - - return compact( 'data', 'meta' ); - } - - protected function process_term( $data, $meta ) { - /** - * Pre-process term data. - * - * @param array $data Term data. (Return empty to skip.) - * @param array $meta Meta data. - */ - $data = apply_filters( 'wxr_importer.pre_process.term', $data, $meta ); - if ( empty( $data ) ) { - return false; - } - - $original_id = isset( $data['id'] ) ? (int) $data['id'] : 0; - $parent_id = isset( $data['parent'] ) ? (int) $data['parent'] : 0; - - $mapping_key = sha1( $data['taxonomy'] . ':' . $data['slug'] ); - $existing = $this->term_exists( $data ); - if ( $existing ) { - - /** - * Term processing already imported. - * - * @param array $data Raw data imported for the term. - */ - do_action( 'wxr_importer.process_already_imported.term', $data ); - - $this->mapping['term'][ $mapping_key ] = $existing; - $this->mapping['term_id'][ $original_id ] = $existing; - return false; - } - - // WP really likes to repeat itself in export files - if ( isset( $this->mapping['term'][ $mapping_key ] ) ) { - return false; - } - - $termdata = array(); - $allowed = array( - 'slug' => true, - 'description' => true, - ); - - // Map the parent comment, or mark it as one we need to fix - // TODO: add parent mapping and remapping - /*$requires_remapping = false; - if ( $parent_id ) { - if ( isset( $this->mapping['term'][ $parent_id ] ) ) { - $data['parent'] = $this->mapping['term'][ $parent_id ]; - } else { - // Prepare for remapping later - $meta[] = array( 'key' => '_wxr_import_parent', 'value' => $parent_id ); - $requires_remapping = true; - - // Wipe the parent for now - $data['parent'] = 0; - } - }*/ - - foreach ( $data as $key => $value ) { - if ( ! isset( $allowed[ $key ] ) ) { - continue; - } - - $termdata[ $key ] = $data[ $key ]; - } - - $result = wp_insert_term( $data['name'], $data['taxonomy'], $termdata ); - if ( is_wp_error( $result ) ) { - $this->logger->warning( sprintf( - __( 'Failed to import %s %s', 'wordpress-importer' ), - $data['taxonomy'], - $data['name'] - ) ); - $this->logger->debug( $result->get_error_message() ); - do_action( 'wp_import_insert_term_failed', $result, $data ); - - /** - * Term processing failed. - * - * @param WP_Error $result Error object. - * @param array $data Raw data imported for the term. - * @param array $meta Meta data supplied for the term. - */ - do_action( 'wxr_importer.process_failed.term', $result, $data, $meta ); - return false; - } - - $term_id = $result['term_id']; - - $this->mapping['term'][ $mapping_key ] = $term_id; - $this->mapping['term_id'][ $original_id ] = $term_id; - - $this->logger->info( sprintf( - __( 'Imported "%s" (%s)', 'wordpress-importer' ), - $data['name'], - $data['taxonomy'] - ) ); - $this->logger->debug( sprintf( - __( 'Term %d remapped to %d', 'wordpress-importer' ), - $original_id, - $term_id - ) ); - - do_action( 'wp_import_insert_term', $term_id, $data ); - - /** - * Term processing completed. - * - * @param int $term_id New term ID. - * @param array $data Raw data imported for the term. - */ - do_action( 'wxr_importer.processed.term', $term_id, $data ); - } - - /** - * Attempt to download a remote file attachment - * - * @param string $url URL of item to fetch - * @param array $post Attachment details - * @return array|WP_Error Local file location details on success, WP_Error otherwise - */ - protected function fetch_remote_file( $url, $post ) { - // extract the file name and extension from the url - $file_name = basename( $url ); - - // get placeholder file in the upload dir with a unique, sanitized filename - $upload = wp_upload_bits( $file_name, 0, '', $post['upload_date'] ); - if ( $upload['error'] ) { - return new \WP_Error( 'upload_dir_error', $upload['error'] ); - } - - // fetch the remote url and write it to the placeholder file - $response = wp_remote_get( $url, array( - 'stream' => true, - 'filename' => $upload['file'], - ) ); - - // request failed - if ( is_wp_error( $response ) ) { - unlink( $upload['file'] ); - return $response; - } - - $code = (int) wp_remote_retrieve_response_code( $response ); - - // make sure the fetch was successful - if ( $code !== 200 ) { - unlink( $upload['file'] ); - return new \WP_Error( - 'import_file_error', - sprintf( - __( 'Remote server returned %1$d %2$s for %3$s', 'wordpress-importer' ), - $code, - get_status_header_desc( $code ), - $url - ) - ); - } - - $filesize = filesize( $upload['file'] ); - $headers = wp_remote_retrieve_headers( $response ); - - if ( isset( $headers['content-length'] ) && $filesize !== (int) $headers['content-length'] ) { - unlink( $upload['file'] ); - return new \WP_Error( 'import_file_error', __( 'Remote file is incorrect size', 'wordpress-importer' ) ); - } - - if ( 0 === $filesize ) { - unlink( $upload['file'] ); - return new \WP_Error( 'import_file_error', __( 'Zero size file downloaded', 'wordpress-importer' ) ); - } - - $max_size = (int) $this->max_attachment_size(); - if ( ! empty( $max_size ) && $filesize > $max_size ) { - unlink( $upload['file'] ); - $message = sprintf( __( 'Remote file is too large, limit is %s', 'wordpress-importer' ), size_format( $max_size ) ); - return new \WP_Error( 'import_file_error', $message ); - } - - return $upload; - } - - protected function post_process() { - // Time to tackle any left-over bits - if ( ! empty( $this->requires_remapping['post'] ) ) { - $this->post_process_posts( $this->requires_remapping['post'] ); - } - if ( ! empty( $this->requires_remapping['comment'] ) ) { - $this->post_process_comments( $this->requires_remapping['comment'] ); - } - } - - protected function post_process_posts( $todo ) { - foreach ( $todo as $post_id => $_ ) { - $this->logger->debug( sprintf( - // Note: title intentionally not used to skip extra processing - // for when debug logging is off - __( 'Running post-processing for post %d', 'wordpress-importer' ), - $post_id - ) ); - - $data = array(); - - $parent_id = get_post_meta( $post_id, '_wxr_import_parent', true ); - if ( ! empty( $parent_id ) ) { - // Have we imported the parent now? - if ( isset( $this->mapping['post'][ $parent_id ] ) ) { - $data['post_parent'] = $this->mapping['post'][ $parent_id ]; - } else { - $this->logger->warning( sprintf( - __( 'Could not find the post parent for "%s" (post #%d)', 'wordpress-importer' ), - get_the_title( $post_id ), - $post_id - ) ); - $this->logger->debug( sprintf( - __( 'Post %d was imported with parent %d, but could not be found', 'wordpress-importer' ), - $post_id, - $parent_id - ) ); - } - } - - $author_slug = get_post_meta( $post_id, '_wxr_import_user_slug', true ); - if ( ! empty( $author_slug ) ) { - // Have we imported the user now? - if ( isset( $this->mapping['user_slug'][ $author_slug ] ) ) { - $data['post_author'] = $this->mapping['user_slug'][ $author_slug ]; - } else { - $this->logger->warning( sprintf( - __( 'Could not find the author for "%s" (post #%d)', 'wordpress-importer' ), - get_the_title( $post_id ), - $post_id - ) ); - $this->logger->debug( sprintf( - __( 'Post %d was imported with author "%s", but could not be found', 'wordpress-importer' ), - $post_id, - $author_slug - ) ); - } - } - - $has_attachments = get_post_meta( $post_id, '_wxr_import_has_attachment_refs', true ); - if ( ! empty( $has_attachments ) ) { - $post = get_post( $post_id ); - $content = $post->post_content; - - // Replace all the URLs we've got - $new_content = str_replace( array_keys( $this->url_remap ), $this->url_remap, $content ); - if ( $new_content !== $content ) { - $data['post_content'] = $new_content; - } - } - - if ( get_post_type( $post_id ) === 'nav_menu_item' ) { - $this->post_process_menu_item( $post_id ); - } - - // Do we have updates to make? - if ( empty( $data ) ) { - $this->logger->debug( sprintf( - __( 'Post %d was marked for post-processing, but none was required.', 'wordpress-importer' ), - $post_id - ) ); - continue; - } - - // Run the update - $data['ID'] = $post_id; - - if ( isset( $data['post_content'] ) ) { - $data['post_content'] = wp_slash( $data['post_content'] ); - } - - $result = wp_update_post( $data, true ); - - if ( is_wp_error( $result ) ) { - $this->logger->warning( sprintf( - __( 'Could not update "%s" (post #%d) with mapped data', 'wordpress-importer' ), - get_the_title( $post_id ), - $post_id - ) ); - $this->logger->debug( $result->get_error_message() ); - continue; - } - - // Clear out our temporary meta keys - delete_post_meta( $post_id, '_wxr_import_parent' ); - delete_post_meta( $post_id, '_wxr_import_user_slug' ); - delete_post_meta( $post_id, '_wxr_import_has_attachment_refs' ); - } - } - - protected function post_process_menu_item( $post_id ) { - $menu_object_id = get_post_meta( $post_id, '_wxr_import_menu_item', true ); - if ( empty( $menu_object_id ) ) { - // No processing needed! - return; - } - - $menu_item_type = get_post_meta( $post_id, '_menu_item_type', true ); - switch ( $menu_item_type ) { - case 'taxonomy': - if ( isset( $this->mapping['term_id'][ $menu_object_id ] ) ) { - $menu_object = $this->mapping['term_id'][ $menu_object_id ]; - } - break; - - case 'post_type': - if ( isset( $this->mapping['post'][ $menu_object_id ] ) ) { - $menu_object = $this->mapping['post'][ $menu_object_id ]; - } - break; - - default: - // Cannot handle this. - return; - } - - if ( ! empty( $menu_object ) ) { - update_post_meta( $post_id, '_menu_item_object_id', wp_slash( $menu_object ) ); - } else { - $this->logger->warning( sprintf( - __( 'Could not find the menu object for "%s" (post #%d)', 'wordpress-importer' ), - get_the_title( $post_id ), - $post_id - ) ); - $this->logger->debug( sprintf( - __( 'Post %d was imported with object "%d" of type "%s", but could not be found', 'wordpress-importer' ), - $post_id, - $menu_object_id, - $menu_item_type - ) ); - } - - delete_post_meta( $post_id, '_wxr_import_menu_item' ); - } - - - protected function post_process_comments( $todo ) { - foreach ( $todo as $comment_id => $_ ) { - $data = array(); - - $parent_id = get_comment_meta( $comment_id, '_wxr_import_parent', true ); - if ( ! empty( $parent_id ) ) { - // Have we imported the parent now? - if ( isset( $this->mapping['comment'][ $parent_id ] ) ) { - $data['comment_parent'] = $this->mapping['comment'][ $parent_id ]; - } else { - $this->logger->warning( sprintf( - __( 'Could not find the comment parent for comment #%d', 'wordpress-importer' ), - $comment_id - ) ); - $this->logger->debug( sprintf( - __( 'Comment %d was imported with parent %d, but could not be found', 'wordpress-importer' ), - $comment_id, - $parent_id - ) ); - } - } - - $author_id = get_comment_meta( $comment_id, '_wxr_import_user', true ); - if ( ! empty( $author_id ) ) { - // Have we imported the user now? - if ( isset( $this->mapping['user'][ $author_id ] ) ) { - $data['user_id'] = $this->mapping['user'][ $author_id ]; - } else { - $this->logger->warning( sprintf( - __( 'Could not find the author for comment #%d', 'wordpress-importer' ), - $comment_id - ) ); - $this->logger->debug( sprintf( - __( 'Comment %d was imported with author %d, but could not be found', 'wordpress-importer' ), - $comment_id, - $author_id - ) ); - } - } - - // Do we have updates to make? - if ( empty( $data ) ) { - continue; - } - - // Run the update - $data['comment_ID'] = $comment_ID; - $result = wp_update_comment( wp_slash( $data ) ); - if ( empty( $result ) ) { - $this->logger->warning( sprintf( - __( 'Could not update comment #%d with mapped data', 'wordpress-importer' ), - $comment_id - ) ); - continue; - } - - // Clear out our temporary meta keys - delete_comment_meta( $comment_id, '_wxr_import_parent' ); - delete_comment_meta( $comment_id, '_wxr_import_user' ); - } - } - - /** - * Use stored mapping information to update old attachment URLs - */ - protected function replace_attachment_urls_in_content() { - global $wpdb; - // make sure we do the longest urls first, in case one is a substring of another - uksort( $this->url_remap, array( $this, 'cmpr_strlen' ) ); - - foreach ( $this->url_remap as $from_url => $to_url ) { - // remap urls in post_content - $query = $wpdb->prepare( "UPDATE {$wpdb->posts} SET post_content = REPLACE(post_content, %s, %s)", $from_url, $to_url ); - $wpdb->query( $query ); - - // remap enclosure urls - $query = $wpdb->prepare( "UPDATE {$wpdb->postmeta} SET meta_value = REPLACE(meta_value, %s, %s) WHERE meta_key='enclosure'", $from_url, $to_url ); - $result = $wpdb->query( $query ); - } - } - - /** - * Update _thumbnail_id meta to new, imported attachment IDs - */ - function remap_featured_images() { - - if ( empty( $this->featured_images ) ) { - return; - } - - // cycle through posts that have a featured image - $this->logger->info( 'Starting remapping of featured images' ); - - foreach ( $this->featured_images as $post_id => $value ) { - if ( isset( $this->mapping['post'][ $value ] ) ) { - $new_id = $this->mapping['post'][ $value ]; - - // only update if there's a difference - if ( $new_id !== $value ) { - $this->logger->info( sprintf( 'Remapping featured image ID %d to new ID %d for post ID %d',$value, $new_id, $post_id ) ); - update_post_meta( $post_id, '_thumbnail_id', $new_id ); - } - } - } - } - - /** - * Decide if the given meta key maps to information we will want to import - * - * @param string $key The meta key to check - * @return string|bool The key if we do want to import, false if not - */ - public function is_valid_meta_key( $key ) { - // skip attachment metadata since we'll regenerate it from scratch - // skip _edit_lock as not relevant for import - if ( in_array( $key, array( '_wp_attached_file', '_wp_attachment_metadata', '_edit_lock' ) ) ) { - return false; - } - - return $key; - } - - /** - * Decide what the maximum file size for downloaded attachments is. - * Default is 0 (unlimited), can be filtered via import_attachment_size_limit - * - * @return int Maximum attachment file size to import - */ - protected function max_attachment_size() { - return apply_filters( 'import_attachment_size_limit', 0 ); - } - - /** - * Added to http_request_timeout filter to force timeout at 60 seconds during import - * - * @access protected - * @return int 60 - */ - function bump_request_timeout($val) { - return 60; - } - - // return the difference in length between two strings - function cmpr_strlen( $a, $b ) { - return strlen( $b ) - strlen( $a ); - } - - /** - * Prefill existing post data. - * - * This preloads all GUIDs into memory, allowing us to avoid hitting the - * database when we need to check for existence. With larger imports, this - * becomes prohibitively slow to perform SELECT queries on each. - * - * By preloading all this data into memory, it's a constant-time lookup in - * PHP instead. However, this does use a lot more memory, so for sites doing - * small imports onto a large site, it may be a better tradeoff to use - * on-the-fly checking instead. - */ - protected function prefill_existing_posts() { - global $wpdb; - $posts = $wpdb->get_results( "SELECT ID, guid FROM {$wpdb->posts}" ); - - foreach ( $posts as $item ) { - $this->exists['post'][ $item->guid ] = $item->ID; - } - } - - /** - * Does the post exist? - * - * @param array $data Post data to check against. - * @return int|bool Existing post ID if it exists, false otherwise. - */ - protected function post_exists( $data ) { - // Constant-time lookup if we prefilled - $exists_key = $data['guid']; - - $exists = null; - - if ( $this->options['prefill_existing_posts'] ) { - // Sites: fix for custom post types. The guids in the prefilled section are escaped, so these ones should be as well. - $exists_key = htmlentities( $exists_key ); - $exists = isset( $this->exists['post'][ $exists_key ] ) ? $this->exists['post'][ $exists_key ] : false; - } else if ( isset( $this->exists['post'][ $exists_key ] ) ) { - // No prefilling, but might have already handled it - $exists = $this->exists['post'][ $exists_key ]; - } else { - // Still nothing, try post_exists, and cache it - $exists = post_exists( $data['post_title'], $data['post_content'], $data['post_date'] ); - } - - /** - * Filter ID of the existing post corresponding to post currently importing. - * - * Return 0 to force the post to be imported. Filter the ID to be something else - * to override which existing post is mapped to the imported post. - * - * @see post_exists() - * - * @param int $post_exists Post ID, or 0 if post did not exist. - * @param array $data The post array to be inserted. - */ - $exists = apply_filters( 'wp_import_existing_post', $exists, $data ); - - $this->exists['post'][ $exists_key ] = $exists; - - return $exists; - } - - /** - * Mark the post as existing. - * - * @param array $data Post data to mark as existing. - * @param int $post_id Post ID. - */ - protected function mark_post_exists( $data, $post_id ) { - $exists_key = $data['guid']; - $this->exists['post'][ $exists_key ] = $post_id; - } - - /** - * Prefill existing comment data. - * - * @see self::prefill_existing_posts() for justification of why this exists. - */ - protected function prefill_existing_comments() { - global $wpdb; - $posts = $wpdb->get_results( "SELECT comment_ID, comment_author, comment_date FROM {$wpdb->comments}" ); - - foreach ( $posts as $item ) { - $exists_key = sha1( $item->comment_author . ':' . $item->comment_date ); - $this->exists['comment'][ $exists_key ] = $item->comment_ID; - } - } - - /** - * Does the comment exist? - * - * @param array $data Comment data to check against. - * @return int|bool Existing comment ID if it exists, false otherwise. - */ - protected function comment_exists( $data ) { - $exists_key = sha1( $data['comment_author'] . ':' . $data['comment_date'] ); - - // Constant-time lookup if we prefilled - if ( $this->options['prefill_existing_comments'] ) { - return isset( $this->exists['comment'][ $exists_key ] ) ? $this->exists['comment'][ $exists_key ] : false; - } - - // No prefilling, but might have already handled it - if ( isset( $this->exists['comment'][ $exists_key ] ) ) { - return $this->exists['comment'][ $exists_key ]; - } - - // Still nothing, try comment_exists, and cache it - $exists = comment_exists( $data['comment_author'], $data['comment_date'] ); - $this->exists['comment'][ $exists_key ] = $exists; - - return $exists; - } - - /** - * Mark the comment as existing. - * - * @param array $data Comment data to mark as existing. - * @param int $comment_id Comment ID. - */ - protected function mark_comment_exists( $data, $comment_id ) { - $exists_key = sha1( $data['comment_author'] . ':' . $data['comment_date'] ); - $this->exists['comment'][ $exists_key ] = $comment_id; - } - - /** - * Prefill existing term data. - * - * @see self::prefill_existing_posts() for justification of why this exists. - */ - protected function prefill_existing_terms() { - global $wpdb; - $query = "SELECT t.term_id, tt.taxonomy, t.slug FROM {$wpdb->terms} AS t"; - $query .= " JOIN {$wpdb->term_taxonomy} AS tt ON t.term_id = tt.term_id"; - $terms = $wpdb->get_results( $query ); - - foreach ( $terms as $item ) { - $exists_key = sha1( $item->taxonomy . ':' . $item->slug ); - $this->exists['term'][ $exists_key ] = $item->term_id; - } - } - - /** - * Does the term exist? - * - * @param array $data Term data to check against. - * @return int|bool Existing term ID if it exists, false otherwise. - */ - protected function term_exists( $data ) { - $exists_key = sha1( $data['taxonomy'] . ':' . $data['slug'] ); - - // Constant-time lookup if we prefilled - if ( $this->options['prefill_existing_terms'] ) { - return isset( $this->exists['term'][ $exists_key ] ) ? $this->exists['term'][ $exists_key ] : false; - } - - // No prefilling, but might have already handled it - if ( isset( $this->exists['term'][ $exists_key ] ) ) { - return $this->exists['term'][ $exists_key ]; - } - - // Still nothing, try comment_exists, and cache it - $exists = term_exists( $data['slug'], $data['taxonomy'] ); - if ( is_array( $exists ) ) { - $exists = $exists['term_id']; - } - - $this->exists['term'][ $exists_key ] = $exists; - - return $exists; - } - - /** - * Mark the term as existing. - * - * @param array $data Term data to mark as existing. - * @param int $term_id Term ID. - */ - protected function mark_term_exists( $data, $term_id ) { - $exists_key = sha1( $data['taxonomy'] . ':' . $data['slug'] ); - $this->exists['term'][ $exists_key ] = $term_id; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/content-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/content-spacing.php deleted file mode 100644 index 3b90e405..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/content-spacing.php +++ /dev/null @@ -1,244 +0,0 @@ -add_section( - 'generate_spacing_content', - array( - 'title' => __( 'Content', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 10, - 'panel' => 'generate_spacing_panel', - ) -); - -// If we don't have a layout panel, use our old spacing section. -if ( $wp_customize->get_panel( 'generate_layout_panel' ) ) { - $content_section = 'generate_layout_container'; -} else { - $content_section = 'generate_spacing_content'; -} - -// Take control of the container width control. -// This control is handled by the free theme, but we take control of it here for consistency between control styles. -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[container_width]', - array( - 'label' => __( 'Container Width', 'gp-premium' ), - 'section' => 'generate_layout_container', - 'settings' => array( - 'desktop' => 'generate_settings[container_width]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 700, - 'max' => 2000, - 'step' => 5, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 0, - ) - ) -); - -// Separating space. -$wp_customize->add_setting( - 'generate_spacing_settings[separator]', - array( - 'default' => $defaults['separator'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[separator]', - array( - 'label' => __( 'Separating Space', 'gp-premium' ), - 'section' => $content_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[separator]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) -); - -// Content padding top. -$wp_customize->add_setting( - 'generate_spacing_settings[content_top]', - array( - 'default' => $defaults['content_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Content padding right. -$wp_customize->add_setting( - 'generate_spacing_settings[content_right]', - array( - 'default' => $defaults['content_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Content padding bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[content_bottom]', - array( - 'default' => $defaults['content_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Content padding left. -$wp_customize->add_setting( - 'generate_spacing_settings[content_left]', - array( - 'default' => $defaults['content_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$content_padding_settings = array( - 'desktop_top' => 'generate_spacing_settings[content_top]', - 'desktop_right' => 'generate_spacing_settings[content_right]', - 'desktop_bottom' => 'generate_spacing_settings[content_bottom]', - 'desktop_left' => 'generate_spacing_settings[content_left]', -); - -// If mobile_content_top is set, the rest of them are too. -// We have to check as these defaults are set in the theme. -if ( isset( $defaults['mobile_content_top'] ) ) { - $content_padding_settings['mobile_top'] = 'generate_spacing_settings[mobile_content_top]'; - $content_padding_settings['mobile_right'] = 'generate_spacing_settings[mobile_content_right]'; - $content_padding_settings['mobile_bottom'] = 'generate_spacing_settings[mobile_content_bottom]'; - $content_padding_settings['mobile_left'] = 'generate_spacing_settings[mobile_content_left]'; - - // Mobile content padding top. - $wp_customize->add_setting( - 'generate_spacing_settings[mobile_content_top]', - array( - 'default' => $defaults['mobile_content_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - // Content padding right. - $wp_customize->add_setting( - 'generate_spacing_settings[mobile_content_right]', - array( - 'default' => $defaults['mobile_content_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - // Content padding bottom. - $wp_customize->add_setting( - 'generate_spacing_settings[mobile_content_bottom]', - array( - 'default' => $defaults['mobile_content_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - // Content padding left. - $wp_customize->add_setting( - 'generate_spacing_settings[mobile_content_left]', - array( - 'default' => $defaults['mobile_content_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); -} - -// Make use of the content padding settings. -$wp_customize->add_control( - new GeneratePress_Spacing_Control( - $wp_customize, - 'content_spacing', - array( - 'type' => 'generatepress-spacing', - 'label' => esc_html__( 'Content Padding', 'gp-premium' ), - 'section' => $content_section, - 'settings' => $content_padding_settings, - 'element' => 'content', - 'priority' => 99, - ) - ) -); - -$wp_customize->add_setting( - 'generate_spacing_settings[content_element_separator]', - array( - 'default' => $defaults['content_element_separator'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[content_element_separator]', - array( - 'label' => __( 'Content Separator', 'gp-premium' ), - 'sub_description' => __( 'The content separator controls the space between the featured image, title, content and entry meta.', 'gp-premium' ), - 'section' => $content_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[content_element_separator]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 10, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) -); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/footer-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/footer-spacing.php deleted file mode 100644 index 3ffc54af..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/footer-spacing.php +++ /dev/null @@ -1,207 +0,0 @@ -add_section( - 'generate_spacing_footer', - array( - 'title' => __( 'Footer', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 20, - 'panel' => 'generate_spacing_panel', - ) -); - -// Use our layout panel if it exists. -if ( $wp_customize->get_panel( 'generate_layout_panel' ) ) { - $footer_section = 'generate_layout_footer'; -} else { - $footer_section = 'generate_spacing_footer'; -} - -// Footer widget area padding top. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_widget_container_top]', - array( - 'default' => $defaults['footer_widget_container_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding right. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_widget_container_right]', - array( - 'default' => $defaults['footer_widget_container_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_widget_container_bottom]', - array( - 'default' => $defaults['footer_widget_container_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding left. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_widget_container_left]', - array( - 'default' => $defaults['footer_widget_container_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding top. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_footer_widget_container_top]', - array( - 'default' => $defaults['mobile_footer_widget_container_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding right. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_footer_widget_container_right]', - array( - 'default' => $defaults['mobile_footer_widget_container_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_footer_widget_container_bottom]', - array( - 'default' => $defaults['mobile_footer_widget_container_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer widget area padding left. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_footer_widget_container_left]', - array( - 'default' => $defaults['mobile_footer_widget_container_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Make use of the Footer widget area padding settings. -$wp_customize->add_control( - new GeneratePress_Spacing_Control( - $wp_customize, - 'footer_widget_area_spacing', - array( - 'type' => 'generatepress-spacing', - 'label' => esc_html__( 'Footer Widget Area Padding', 'gp-premium' ), - 'section' => $footer_section, - 'settings' => array( - 'desktop_top' => 'generate_spacing_settings[footer_widget_container_top]', - 'desktop_right' => 'generate_spacing_settings[footer_widget_container_right]', - 'desktop_bottom' => 'generate_spacing_settings[footer_widget_container_bottom]', - 'desktop_left' => 'generate_spacing_settings[footer_widget_container_left]', - 'mobile_top' => 'generate_spacing_settings[mobile_footer_widget_container_top]', - 'mobile_right' => 'generate_spacing_settings[mobile_footer_widget_container_right]', - 'mobile_bottom' => 'generate_spacing_settings[mobile_footer_widget_container_bottom]', - 'mobile_left' => 'generate_spacing_settings[mobile_footer_widget_container_left]', - ), - 'element' => 'footer_widget_area', - 'priority' => 99, - ) - ) -); - -// Footer padding top. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_top]', - array( - 'default' => $defaults['footer_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer padding right. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_right]', - array( - 'default' => $defaults['footer_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer padding bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_bottom]', - array( - 'default' => $defaults['footer_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Footer padding left. -$wp_customize->add_setting( - 'generate_spacing_settings[footer_left]', - array( - 'default' => $defaults['footer_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Make use of the footer padding settings. -$wp_customize->add_control( - new GeneratePress_Spacing_Control( - $wp_customize, - 'footer_spacing', - array( - 'type' => 'generatepress-spacing', - 'label' => esc_html__( 'Footer Padding', 'gp-premium' ), - 'section' => $footer_section, - 'settings' => array( - 'desktop_top' => 'generate_spacing_settings[footer_top]', - 'desktop_right' => 'generate_spacing_settings[footer_right]', - 'desktop_bottom' => 'generate_spacing_settings[footer_bottom]', - 'desktop_left' => 'generate_spacing_settings[footer_left]', - ), - 'element' => 'footer', - 'priority' => 105, - ) - ) -); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/header-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/header-spacing.php deleted file mode 100644 index f937d91b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/header-spacing.php +++ /dev/null @@ -1,135 +0,0 @@ -add_section( - 'generate_spacing_header', - array( - 'title' => __( 'Header', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 5, - 'panel' => 'generate_spacing_panel', - ) -); - -// If we don't have a layout panel, use our old spacing section. -$header_section = ( $wp_customize->get_panel( 'generate_layout_panel' ) ) ? 'generate_layout_header' : 'generate_spacing_header'; - -// Header top. -$wp_customize->add_setting( - 'generate_spacing_settings[header_top]', - array( - 'default' => $defaults['header_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Header right. -$wp_customize->add_setting( - 'generate_spacing_settings[header_right]', - array( - 'default' => $defaults['header_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Header bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[header_bottom]', - array( - 'default' => $defaults['header_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Header left. -$wp_customize->add_setting( - 'generate_spacing_settings[header_left]', - array( - 'default' => $defaults['header_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_header_top]', - array( - 'default' => $defaults['mobile_header_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Header right. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_header_right]', - array( - 'default' => $defaults['mobile_header_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Header bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_header_bottom]', - array( - 'default' => $defaults['mobile_header_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Header left. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_header_left]', - array( - 'default' => $defaults['mobile_header_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Do something with our header controls. -$wp_customize->add_control( - new GeneratePress_Spacing_Control( - $wp_customize, - 'header_spacing', - array( - 'type' => 'generatepress-spacing', - 'label' => esc_html__( 'Header Padding', 'gp-premium' ), - 'section' => $header_section, - 'settings' => array( - 'desktop_top' => 'generate_spacing_settings[header_top]', - 'desktop_right' => 'generate_spacing_settings[header_right]', - 'desktop_bottom' => 'generate_spacing_settings[header_bottom]', - 'desktop_left' => 'generate_spacing_settings[header_left]', - 'mobile_top' => 'generate_spacing_settings[mobile_header_top]', - 'mobile_right' => 'generate_spacing_settings[mobile_header_right]', - 'mobile_bottom' => 'generate_spacing_settings[mobile_header_bottom]', - 'mobile_left' => 'generate_spacing_settings[mobile_header_left]', - ), - 'element' => 'header', - ) - ) -); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/js/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/js/customizer.js deleted file mode 100644 index 966c3eaa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/js/customizer.js +++ /dev/null @@ -1,661 +0,0 @@ -function generate_spacing_live_update( name, id, selector, property, negative, divide, media, unit ) { - settings = typeof settings !== 'undefined' ? settings : 'generate_spacing_settings'; - wp.customize( settings + '[' + id + ']', function( value ) { - value.bind( function( newval ) { - negative = typeof negative !== 'undefined' ? negative : false; - media = typeof media !== 'undefined' ? media : ''; - divide = typeof divide !== 'undefined' ? divide : false; - unit = typeof unit !== 'undefined' ? unit : 'px'; - - // Get new value - newval = ( divide ) ? newval / 2 : newval; - - // Check if negative integer - negative = ( negative ) ? '-' : ''; - - var isTablet = ( 'tablet' == id.substring( 0, 6 ) ) ? true : false, - isMobile = ( 'mobile' == id.substring( 0, 6 ) ) ? true : false; - - if ( isTablet ) { - if ( '' == wp.customize(settings + '[' + id + ']').get() ) { - var desktopID = id.replace( 'tablet_', '' ); - newval = wp.customize(settings + '[' + desktopID + ']').get(); - } - } - - if ( isMobile ) { - if ( '' == wp.customize(settings + '[' + id + ']').get() ) { - var desktopID = id.replace( 'mobile_', '' ); - newval = wp.customize(settings + '[' + desktopID + ']').get(); - } - } - - // We're using a desktop value - if ( ! isTablet && ! isMobile ) { - - var tabletValue = ( typeof wp.customize(settings + '[tablet_' + id + ']') !== 'undefined' ) ? wp.customize(settings + '[tablet_' + id + ']').get() : '', - mobileValue = ( typeof wp.customize(settings + '[mobile_' + id + ']') !== 'undefined' ) ? wp.customize(settings + '[mobile_' + id + ']').get() : ''; - - // The tablet setting exists, mobile doesn't - if ( '' !== tabletValue && '' == mobileValue ) { - media = gp_spacing.desktop + ', ' + gp_spacing.mobile; - } - - // The tablet setting doesn't exist, mobile does - if ( '' == tabletValue && '' !== mobileValue ) { - media = gp_spacing.desktop + ', ' + gp_spacing.tablet; - } - - // The tablet setting doesn't exist, neither does mobile - if ( '' == tabletValue && '' == mobileValue ) { - media = gp_spacing.desktop + ', ' + gp_spacing.tablet + ', ' + gp_spacing.mobile; - } - - } - - // Check if media query - media_query = ( '' !== media ) ? 'media="' + media + '"' : ''; - - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#' + name ).not( ':last' ).remove(); - }, 50 ); - - jQuery('body').trigger('generate_spacing_updated'); - } ); - } ); -} - -/** - * Top bar padding - */ -generate_spacing_live_update( 'top_bar_top', 'top_bar_top', '.inside-top-bar', 'padding-top' ); -generate_spacing_live_update( 'top_bar_right', 'top_bar_right', '.inside-top-bar', 'padding-right' ); -generate_spacing_live_update( 'top_bar_bottom', 'top_bar_bottom', '.inside-top-bar', 'padding-bottom' ); -generate_spacing_live_update( 'top_bar_left', 'top_bar_left', '.inside-top-bar', 'padding-left' ); - -/** - * Header padding - */ -generate_spacing_live_update( 'header_top', 'header_top', '.inside-header', 'padding-top', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'header_right', 'header_right', '.inside-header', 'padding-right', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'header_bottom', 'header_bottom', '.inside-header', 'padding-bottom', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'header_left', 'header_left', '.inside-header', 'padding-left', false, false, gp_spacing.desktop ); - -generate_spacing_live_update( 'mobile_header_top', 'mobile_header_top', '.inside-header', 'padding-top', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_header_right', 'mobile_header_right', '.inside-header', 'padding-right', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_header_bottom', 'mobile_header_bottom', '.inside-header', 'padding-bottom', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_header_left', 'mobile_header_left', '.inside-header', 'padding-left', false, false, gp_spacing.mobile ); - -jQuery( window ).on( 'load', function() { - var containerAlignment = wp.customize( 'generate_settings[container_alignment]' ); - - if ( gp_spacing.isFlex && containerAlignment && 'text' === containerAlignment.get() ) { - generate_spacing_live_update( 'header_left_sticky_nav', 'header_left', '.main-navigation.navigation-stick:not(.has-branding) .inside-navigation.grid-container', 'padding-left', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'header_right_sticky_nav', 'header_right', '.main-navigation.navigation-stick:not(.has-branding) .inside-navigation.grid-container', 'padding-right', false, false, gp_spacing.desktop ); - - generate_spacing_live_update( 'mobile_header_left_sticky_nav', 'mobile_header_left', '.main-navigation.navigation-stick:not(.has-branding) .inside-navigation.grid-container', 'padding-left', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_header_right_sticky_nav', 'mobile_header_right', '.main-navigation.navigation-stick:not(.has-branding) .inside-navigation.grid-container', 'padding-right', false, false, gp_spacing.mobile ); - } -} ); - -/** - * Content padding - */ -var content_areas = '.separate-containers .inside-article, \ - .separate-containers .comments-area, \ - .separate-containers .page-header, \ - .separate-containers .paging-navigation, \ - .one-container .site-content, \ - .inside-page-header, \ - .wp-block-group__inner-container'; - -generate_spacing_live_update( 'content_top', 'content_top', content_areas, 'padding-top', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'content_right', 'content_right', content_areas, 'padding-right', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'content_bottom', 'content_bottom', content_areas, 'padding-bottom', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'content_left', 'content_left', content_areas, 'padding-left', false, false, gp_spacing.desktop ); - -jQuery( window ).on( 'load', function() { - var containerAlignment = wp.customize( 'generate_settings[container_alignment]' ); - - if ( gp_spacing.isFlex && containerAlignment && 'text' === containerAlignment.get() ) { - generate_spacing_live_update( 'content_left_nav_as_header', 'content_left', '.main-navigation.has-branding .inside-navigation.grid-container, .main-navigation.has-branding .inside-navigation.grid-container', 'padding-left', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'content_right_nav_as_header', 'content_right', '.main-navigation.has-branding .inside-navigation.grid-container, .main-navigation.has-branding .inside-navigation.grid-container', 'padding-right', false, false, gp_spacing.desktop ); - } -} ); - -generate_spacing_live_update( 'one_container_post_content_bottom', 'content_bottom', '.one-container.archive .post:not(:last-child):not(.is-loop-template-item),.one-container.blog .post:not(:last-child):not(.is-loop-template-item)', 'padding-bottom' ); - -/* Mobile content padding */ -generate_spacing_live_update( 'mobile_content_top', 'mobile_content_top', content_areas, 'padding-top', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_content_right', 'mobile_content_right', content_areas, 'padding-right', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_content_bottom', 'mobile_content_bottom', content_areas, 'padding-bottom', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_content_left', 'mobile_content_left', content_areas, 'padding-left', false, false, gp_spacing.mobile ); - -generate_spacing_live_update( 'content-margin-right', 'content_right', '.one-container.right-sidebar .site-main,.one-container.both-right .site-main', 'margin-right' ); -generate_spacing_live_update( 'content-margin-left', 'content_left', '.one-container.left-sidebar .site-main,.one-container.both-left .site-main', 'margin-left' ); -generate_spacing_live_update( 'content-margin-right-both', 'content_right', '.one-container.both-sidebars .site-main', 'margin-right' ); -generate_spacing_live_update( 'content-margin-left-both', 'content_left', '.one-container.both-sidebars .site-main', 'margin-left' ); - -/* Content element separator */ - -generate_spacing_live_update( 'content_element_separator_top', 'content_element_separator', '.post-image:not(:first-child), .page-content:not(:first-child), .entry-content:not(:first-child), .entry-summary:not(:first-child), footer.entry-meta', 'margin-top', false, false, false, 'em' ); -generate_spacing_live_update( 'content_element_separator_bottom', 'content_element_separator', '.post-image-above-header .inside-article div.featured-image, .post-image-above-header .inside-article div.post-image', 'margin-bottom', false, false, false, 'em' ); - -/** - * Featured image padding - */ -var featured_image_no_padding_x = '.post-image-below-header.post-image-aligned-center .no-featured-image-padding .post-image, \ - .post-image-below-header.post-image-aligned-center .no-featured-image-padding .featured-image'; - -generate_spacing_live_update( 'featured_image_padding_right', 'content_right', featured_image_no_padding_x, 'margin-right', true, false, gp_spacing.desktop ); -generate_spacing_live_update( 'featured_image_padding_left', 'content_left', featured_image_no_padding_x, 'margin-left', true, false, gp_spacing.desktop ); -generate_spacing_live_update( 'mobile_featured_image_padding_right', 'mobile_content_right', featured_image_no_padding_x, 'margin-right', true, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_featured_image_padding_left', 'mobile_content_left', featured_image_no_padding_x, 'margin-left', true, false, gp_spacing.mobile ); - -var featured_image_no_padding_y = '.post-image-above-header.post-image-aligned-center .no-featured-image-padding .post-image, \ - .post-image-above-header.post-image-aligned-center .no-featured-image-padding .featured-image'; - -generate_spacing_live_update( 'featured_image_padding_top', 'content_top', featured_image_no_padding_y, 'margin-top', true, false, gp_spacing.desktop ); -generate_spacing_live_update( 'featured_image_padding_right', 'content_right', featured_image_no_padding_y, 'margin-right', true, false, gp_spacing.desktop ); -generate_spacing_live_update( 'featured_image_padding_left', 'content_left', featured_image_no_padding_y, 'margin-left', true, false, gp_spacing.desktop ); -generate_spacing_live_update( 'mobile_featured_image_padding_top', 'mobile_content_top', featured_image_no_padding_y, 'margin-top', true, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_featured_image_padding_right', 'mobile_content_right', featured_image_no_padding_y, 'margin-right', true, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_featured_image_padding_left', 'mobile_content_left', featured_image_no_padding_y, 'margin-left', true, false, gp_spacing.mobile ); - -/** - * Main navigation spacing - */ -var menu_items = '.main-navigation .main-nav ul li a,\ - .main-navigation .menu-toggle,\ - .main-navigation .mobile-bar-items a,\ - .main-navigation .menu-bar-item > a'; - -// Menu item width -generate_spacing_live_update( 'menu_item_padding_left', 'menu_item', menu_items + ', .slideout-navigation button.slideout-exit', 'padding-left', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'menu_item_padding_right', 'menu_item', menu_items + ', .slideout-navigation button.slideout-exit', 'padding-right', false, false, gp_spacing.desktop ); - -// Tablet menu item width -//generate_spacing_live_update( 'tablet_menu_item_padding_left', 'tablet_menu_item', menu_items, 'padding-left', false, false, gp_spacing.tablet ); -//generate_spacing_live_update( 'tablet_menu_item_padding_right', 'tablet_menu_item', menu_items, 'padding-right', false, false, gp_spacing.tablet ); - -// Mobile menu item width -generate_spacing_live_update( 'mobile_menu_item_padding_left', 'mobile_menu_item', '.main-navigation .menu-toggle,.main-navigation .mobile-bar-items a, .main-navigation .menu-bar-item > a', 'padding-left', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_menu_item_padding_right', 'mobile_menu_item', '.main-navigation .menu-toggle,.main-navigation .mobile-bar-items a, .main-navigation .menu-bar-item > a', 'padding-right', false, false, gp_spacing.mobile ); - -// Menu item height -generate_spacing_live_update( 'menu_item_height', 'menu_item_height', menu_items, 'line-height', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'navigation_logo_height', 'menu_item_height', '.main-navigation .navigation-logo img, .main-navigation .site-logo img', 'height', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'nav_title_height', 'menu_item_height', '.navigation-branding .main-title', 'line-height', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'mobile_header_logo_height', 'menu_item_height', '.mobile-header-navigation .mobile-header-logo img', 'height', false, false, gp_spacing.desktop ); - -//generate_spacing_live_update( 'tablet_menu_item_height', 'tablet_menu_item_height', menu_items, 'line-height', false, false, gp_spacing.tablet ); -//generate_spacing_live_update( 'tablet_navigation_logo_height', 'tablet_menu_item_height', '.main-navigation .navigation-logo img', 'height', false, false, gp_spacing.tablet ); -//generate_spacing_live_update( 'tablet_mobile_header_logo_height', 'tablet_menu_item_height', '.mobile-header-navigation .mobile-header-logo img', 'height', false, false, gp_spacing.tablet ); - -generate_spacing_live_update( 'mobile_menu_item_height', 'mobile_menu_item_height', menu_items, 'line-height', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_navigation_logo_height', 'mobile_menu_item_height', '.main-navigation .site-logo.navigation-logo img, .main-navigation .site-logo img, .main-navigation .navigation-branding img', 'height', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_nav_title_height', 'menu_item_height', '.navigation-branding .main-title', 'line-height', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_mobile_header_logo_height', 'mobile_menu_item_height', '.mobile-header-navigation .site-logo.mobile-header-logo img', 'height', false, false, gp_spacing.mobile ); - -// Off canvas menu item height -wp.customize( 'generate_spacing_settings[off_canvas_menu_item_height]', function( value ) { - value.bind( function( newval ) { - - if ( '' == newval ) { - newval = wp.customize('generate_spacing_settings[menu_item_height]').get(); - } - - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#off_canvas_menu_item_height' ).not( ':last' ).remove(); - }, 200 ); - - } ); -} ); - -/** - * Main sub-navigation spacing - */ -generate_spacing_live_update( 'sub_menu_item_height_top', 'sub_menu_item_height', '.main-navigation .main-nav ul ul li a', 'padding-top' ); -generate_spacing_live_update( 'sub_menu_item_height_right', 'menu_item', '.main-navigation .main-nav ul ul li a', 'padding-right', false, false, gp_spacing.desktop ); -//generate_spacing_live_update( 'tablet_sub_menu_item_height_right', 'tablet_menu_item', '.main-navigation .main-nav ul ul li a', 'padding-right', false, false, gp_spacing.tablet ); -generate_spacing_live_update( 'sub_menu_item_height_bottom', 'sub_menu_item_height', '.main-navigation .main-nav ul ul li a', 'padding-bottom' ); -generate_spacing_live_update( 'sub_menu_item_height_left', 'menu_item', '.main-navigation .main-nav ul ul li a', 'padding-left', false, false, gp_spacing.desktop ); -//generate_spacing_live_update( 'tablet_sub_menu_item_height_left', 'tablet_menu_item', '.main-navigation .main-nav ul ul li a', 'padding-left', false, false, gp_spacing.tablet ); -generate_spacing_live_update( 'sub_menu_item_offset', 'menu_item_height', '.main-navigation ul ul', 'top' ); - -/** - * Main navigation RTL arrow spacing - */ -generate_spacing_live_update( 'dropdown_menu_arrow', 'menu_item', '.menu-item-has-children .dropdown-menu-toggle', 'padding-right', false, false, gp_spacing.desktop ); -//generate_spacing_live_update( 'tablet_dropdown_menu_arrow', 'tablet_menu_item', '.menu-item-has-children .dropdown-menu-toggle', 'padding-right', false, false, gp_spacing.tablet ); - -/** - * Main sub-navigation arrow spacing - */ -generate_spacing_live_update( 'dropdown_submenu_arrow_top', 'sub_menu_item_height', '.menu-item-has-children ul .dropdown-menu-toggle', 'padding-top' ); -generate_spacing_live_update( 'dropdown_submenu_arrow_bottom', 'sub_menu_item_height', '.menu-item-has-children ul .dropdown-menu-toggle', 'padding-bottom' ); -generate_spacing_live_update( 'dropdown_submenu_arrow_margin', 'sub_menu_item_height', '.menu-item-has-children ul .dropdown-menu-toggle', 'margin-top', true ); - -/** - * Sub-Menu Width - */ -generate_spacing_live_update( 'sub_menu_width', 'sub_menu_width', '.main-navigation ul ul', 'width' ); - -/** - - * Sticky menu item height - - */ -wp.customize( 'generate_spacing_settings[sticky_menu_item_height]', function( value ) { - value.bind( function( newval ) { - - if ( '' == newval ) { - newval = wp.customize('generate_spacing_settings[menu_item_height]').get(); - } - - jQuery( 'head' ).append( '' ); - jQuery( 'head' ).append( '' ); - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#sticky_menu_item_height' ).not( ':last' ).remove(); - jQuery( 'style#sticky_menu_item_logo_height' ).not( ':last' ).remove(); - jQuery( 'style#sticky_menu_item_height_transition' ).remove(); - }, 200 ); - - } ); -} ); - -// Disable the transition while we resize -wp.customize( 'generate_spacing_settings[menu_item_height]', function( value ) { - value.bind( function( newval ) { - - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#menu_item_height_transition' ).remove(); - }, 200 ); - - } ); -} ); - -wp.customize( 'generate_spacing_settings[off_canvas_menu_item_height]', function( value ) { - value.bind( function( newval ) { - - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#off_canvas_menu_item_height_transition' ).remove(); - }, 200 ); - - } ); -} ); - -/** - * Widget padding - */ -generate_spacing_live_update( 'widget_top', 'widget_top', '.widget-area .widget, .one-container .widget-area .widget', 'padding-top', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'widget_right', 'widget_right', '.widget-area .widget, .one-container .widget-area .widget', 'padding-right', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'widget_bottom', 'widget_bottom', '.widget-area .widget, .one-container .widget-area .widget', 'padding-bottom', false, false, gp_spacing.desktop ); -generate_spacing_live_update( 'widget_left', 'widget_left', '.widget-area .widget, .one-container .widget-area .widget', 'padding-left', false, false, gp_spacing.desktop ); - -generate_spacing_live_update( 'mobile_widget_top', 'mobile_widget_top', '.widget-area .widget', 'padding-top', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_widget_right', 'mobile_widget_right', '.widget-area .widget', 'padding-right', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_widget_bottom', 'mobile_widget_bottom', '.widget-area .widget', 'padding-bottom', false, false, gp_spacing.mobile ); -generate_spacing_live_update( 'mobile_widget_left', 'mobile_widget_left', '.widget-area .widget', 'padding-left', false, false, gp_spacing.mobile ); - - -if ( gp_spacing.isFlex ) { - /** - * Footer widget area - */ - generate_spacing_live_update( 'footer_widget_container_top', 'footer_widget_container_top', '.footer-widgets-container', 'padding-top', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'footer_widget_container_right', 'footer_widget_container_right', '.footer-widgets-container', 'padding-right', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'footer_widget_container_bottom', 'footer_widget_container_bottom', '.footer-widgets-container', 'padding-bottom', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'footer_widget_container_left', 'footer_widget_container_left', '.footer-widgets-container', 'padding-left', false, false, gp_spacing.desktop ); - - generate_spacing_live_update( 'mobile_footer_widget_container_top', 'mobile_footer_widget_container_top', '.footer-widgets-container', 'padding-top', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_footer_widget_container_right', 'mobile_footer_widget_container_right', '.footer-widgets-container', 'padding-right', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_footer_widget_container_bottom', 'mobile_footer_widget_container_bottom', '.footer-widgets-container', 'padding-bottom', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_footer_widget_container_left', 'mobile_footer_widget_container_left', '.footer-widgets-container', 'padding-left', false, false, gp_spacing.mobile ); - - /** - * Footer - */ - generate_spacing_live_update( 'footer_top', 'footer_top', '.inside-site-info', 'padding-top' ); - generate_spacing_live_update( 'footer_right', 'footer_right', '.inside-site-info', 'padding-right' ); - generate_spacing_live_update( 'footer_bottom', 'footer_bottom', '.inside-site-info', 'padding-bottom' ); - generate_spacing_live_update( 'footer_left', 'footer_left', '.inside-site-info', 'padding-left' ); -} else { - /** - * Footer widget area - */ - generate_spacing_live_update( 'footer_widget_container_top', 'footer_widget_container_top', '.footer-widgets', 'padding-top', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'footer_widget_container_right', 'footer_widget_container_right', '.footer-widgets', 'padding-right', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'footer_widget_container_bottom', 'footer_widget_container_bottom', '.footer-widgets', 'padding-bottom', false, false, gp_spacing.desktop ); - generate_spacing_live_update( 'footer_widget_container_left', 'footer_widget_container_left', '.footer-widgets', 'padding-left', false, false, gp_spacing.desktop ); - - generate_spacing_live_update( 'mobile_footer_widget_container_top', 'mobile_footer_widget_container_top', '.footer-widgets', 'padding-top', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_footer_widget_container_right', 'mobile_footer_widget_container_right', '.footer-widgets', 'padding-right', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_footer_widget_container_bottom', 'mobile_footer_widget_container_bottom', '.footer-widgets', 'padding-bottom', false, false, gp_spacing.mobile ); - generate_spacing_live_update( 'mobile_footer_widget_container_left', 'mobile_footer_widget_container_left', '.footer-widgets', 'padding-left', false, false, gp_spacing.mobile ); - - /** - * Footer - */ - generate_spacing_live_update( 'footer_top', 'footer_top', '.site-info', 'padding-top' ); - generate_spacing_live_update( 'footer_right', 'footer_right', '.site-info', 'padding-right' ); - generate_spacing_live_update( 'footer_bottom', 'footer_bottom', '.site-info', 'padding-bottom' ); - generate_spacing_live_update( 'footer_left', 'footer_left', '.site-info', 'padding-left' ); -} - - -/** - * Separator - */ - -/* Masonry */ -if ( jQuery( 'body' ).hasClass( 'masonry-enabled' ) ) { - generate_spacing_live_update( 'masonry_separator', 'separator', '.masonry-post .inside-article', 'margin-left' ); - generate_spacing_live_update( 'masonry_separator_bottom', 'separator', '.masonry-container > article', 'margin-bottom' ); - generate_spacing_live_update( 'masonry_separator_container', 'separator', '.masonry-container', 'margin-left', 'negative' ); - generate_spacing_live_update( 'masonry_separator_page_header_left', 'separator', '.masonry-enabled .page-header', 'margin-left' ); - generate_spacing_live_update( 'masonry_separator_page_header_bottom', 'separator', '.masonry-enabled .page-header', 'margin-bottom' ); - generate_spacing_live_update( 'masonry_separator_load_more', 'separator', '.separate-containers .site-main > .masonry-load-more', 'margin-bottom' ); -} - -/* Columns */ -if ( jQuery( 'body' ).hasClass( 'generate-columns-activated' ) ) { - generate_spacing_live_update( 'columns_bottom', 'separator', '.generate-columns', 'margin-bottom' ); - generate_spacing_live_update( 'columns_left', 'separator', '.generate-columns', 'padding-left' ); - generate_spacing_live_update( 'columns_container', 'separator', '.generate-columns-container', 'margin-left', 'negative' ); - generate_spacing_live_update( 'columns_page_header_bottom', 'separator', '.generate-columns-container .page-header', 'margin-bottom' ); - generate_spacing_live_update( 'columns_page_header_left', 'separator', '.generate-columns-container .page-header', 'margin-left' ); - generate_spacing_live_update( 'columns_pagination', 'separator', '.separate-containers .generate-columns-container > .paging-navigation', 'margin-left' ); -} - -/* Right sidebar */ -if ( jQuery( 'body' ).hasClass( 'right-sidebar' ) ) { - generate_spacing_live_update( 'right_sidebar_sepatator_top', 'separator', '.right-sidebar.separate-containers .site-main', 'margin-top' ); - generate_spacing_live_update( 'right_sidebar_sepatator_right', 'separator', '.right-sidebar.separate-containers .site-main', 'margin-right' ); - generate_spacing_live_update( 'right_sidebar_sepatator_bottom', 'separator', '.right-sidebar.separate-containers .site-main', 'margin-bottom' ); -} - -/* Left sidebar */ -if ( jQuery( 'body' ).hasClass( 'left-sidebar' ) ) { - generate_spacing_live_update( 'left_sidebar_sepatator_top', 'separator', '.left-sidebar.separate-containers .site-main', 'margin-top' ); - generate_spacing_live_update( 'left_sidebar_sepatator_left', 'separator', '.left-sidebar.separate-containers .site-main', 'margin-left' ); - generate_spacing_live_update( 'left_sidebar_sepatator_bottom', 'separator', '.left-sidebar.separate-containers .site-main', 'margin-bottom' ); -} - -/* Both sidebars */ -if ( jQuery( 'body' ).hasClass( 'both-sidebars' ) ) { - generate_spacing_live_update( 'both_sidebars_sepatator', 'separator', '.both-sidebars.separate-containers .site-main', 'margin' ); -} - -/* Both sidebars right */ -if ( jQuery( 'body' ).hasClass( 'both-right' ) ) { - generate_spacing_live_update( 'both_right_sidebar_sepatator_top', 'separator', '.both-right.separate-containers .site-main', 'margin-top' ); - generate_spacing_live_update( 'both_right_sidebar_sepatator_right', 'separator', '.both-right.separate-containers .site-main', 'margin-right' ); - generate_spacing_live_update( 'both_right_sidebar_sepatator_bottom', 'separator', '.both-right.separate-containers .site-main', 'margin-bottom' ); - - if ( gp_spacing.isFlex ) { - generate_spacing_live_update( 'both_right_left_sidebar', 'separator', '.both-right .inside-left-sidebar', 'margin-right', false, true ); - generate_spacing_live_update( 'both_right_right_sidebar', 'separator', '.both-right .inside-right-sidebar', 'margin-left', false, true ); - } else { - generate_spacing_live_update( 'both_right_left_sidebar', 'separator', '.both-right.separate-containers .inside-left-sidebar', 'margin-right', false, true ); - generate_spacing_live_update( 'both_right_right_sidebar', 'separator', '.both-right.separate-containers .inside-right-sidebar', 'margin-left', false, true ); - } -} - -/* Both sidebars left */ -if ( jQuery( 'body' ).hasClass( 'both-left' ) ) { - generate_spacing_live_update( 'both_left_sidebar_sepatator_top', 'separator', '.both-left.separate-containers .site-main', 'margin-top' ); - generate_spacing_live_update( 'both_left_sidebar_sepatator_right', 'separator', '.both-left.separate-containers .site-main', 'margin-bottom' ); - generate_spacing_live_update( 'both_left_sidebar_sepatator_bottom', 'separator', '.both-left.separate-containers .site-main', 'margin-left' ); - - if ( gp_spacing.isFlex ) { - generate_spacing_live_update( 'both_left_left_sidebar', 'separator', '.both-left .inside-left-sidebar', 'margin-right', false, true ); - generate_spacing_live_update( 'both_left_right_sidebar', 'separator', '.both-left .inside-right-sidebar', 'margin-left', false, true ); - } else { - generate_spacing_live_update( 'both_left_left_sidebar', 'separator', '.both-left.separate-containers .inside-left-sidebar', 'margin-right', false, true ); - generate_spacing_live_update( 'both_left_right_sidebar', 'separator', '.both-left.separate-containers .inside-right-sidebar', 'margin-left', false, true ); - } -} - -/* Main element margin */ -generate_spacing_live_update( 'site_main_separator_top', 'separator', '.separate-containers .site-main', 'margin-top' ); -generate_spacing_live_update( 'site_main_separator_bottom', 'separator', '.separate-containers .site-main', 'margin-bottom' ); - -/* Page header element */ -if ( gp_spacing.isFlex ) { - generate_spacing_live_update( 'page_header_separator_top', 'separator', '.separate-containers .featured-image', 'margin-top' ); -} else { - generate_spacing_live_update( 'page_header_separator_top', 'separator', - '.separate-containers .page-header-image, \ - .separate-containers .page-header-contained, \ - .separate-containers .page-header-image-single, \ - .separate-containers .page-header-content-single', 'margin-top' ); -} - -/* Top and bottom sidebar margin */ -generate_spacing_live_update( 'right_sidebar_separator_top', 'separator', '.separate-containers .inside-right-sidebar, .separate-containers .inside-left-sidebar', 'margin-top' ); -generate_spacing_live_update( 'right_sidebar_separator_bottom', 'separator', '.separate-containers .inside-right-sidebar, .separate-containers .inside-left-sidebar', 'margin-bottom' ); - -/* Element separators */ -if ( gp_spacing.isFlex ) { - generate_spacing_live_update( 'content_separator', 'separator', - '.sidebar .widget, \ - .site-main > *, \ - .page-header, \ - .widget-area .main-navigation', 'margin-bottom' ); -} else { - generate_spacing_live_update( 'content_separator', 'separator', - '.separate-containers .widget, \ - .separate-containers .site-main > *, \ - .separate-containers .page-header, \ - .widget-area .main-navigation', 'margin-bottom' ); -} - -/** - * Right sidebar width - */ -wp.customize( 'generate_spacing_settings[right_sidebar_width]', function( value ) { - value.bind( function( newval ) { - var body = jQuery( 'body' ); - - if ( jQuery( '#right-sidebar' ).length ) { - if ( gp_spacing.isFlex ) { - var contentWidth = 100, - leftSidebar = jQuery( '#left-sidebar' ).length ? wp.customize.value('generate_spacing_settings[left_sidebar_width]')() : 0; - - if ( body.hasClass( 'right-sidebar' ) ) { - contentWidth = ( Number( contentWidth ) - Number( newval ) ); - } else if ( ! body.hasClass( 'left-sidebar' ) && ! body.hasClass( 'no-sidebar' ) ) { - var totalSidebarWidth = ( Number( leftSidebar ) + Number( newval ) ); - - contentWidth = ( Number( contentWidth ) - Number( totalSidebarWidth ) ); - } - - jQuery( 'head' ).append( '' ); - - setTimeout(function() { - jQuery( 'style#right_sidebar_width' ).not( ':last' ).remove(); - }, 200 ); - } else { - // Left sidebar width - var left_sidebar = ( jQuery( '#left-sidebar' ).length ) ? wp.customize.value('generate_spacing_settings[left_sidebar_width]')() : 0; - - // Right sidebar class - jQuery( "#right-sidebar" ).removeClass(function (index, css) { - return (css.match (/(^|\s)grid-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-grid-\S+/g) || []).join(' '); - }).addClass( 'grid-' + newval ).addClass( 'tablet-grid-' + newval ).addClass( 'grid-parent' ); - - // Content area class - jQuery( ".content-area" ).removeClass(function (index, css) { - return (css.match (/(^|\s)grid-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-grid-\S+/g) || []).join(' '); - }).addClass( 'grid-' + ( 100 - newval - left_sidebar ) ).addClass( 'tablet-grid-' + ( 100 - newval - left_sidebar ) ).addClass( 'grid-parent' ); - - if ( body.hasClass( 'both-sidebars' ) ) { - var content_width = ( 100 - newval - left_sidebar ); - jQuery( '#left-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( content_width ) ).addClass( 'tablet-pull-' + ( content_width ) ); - } - - if ( body.hasClass( 'both-left' ) ) { - var total_sidebar_width = ( parseInt( left_sidebar ) + parseInt( newval ) ); - - jQuery( '#right-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( 100 - total_sidebar_width ) ).addClass( 'tablet-pull-' + ( 100 - total_sidebar_width ) ); - - jQuery( '#left-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( 100 - total_sidebar_width ) ).addClass( 'tablet-pull-' + ( 100 - total_sidebar_width ) ); - - jQuery( '.content-area' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'push-' + ( total_sidebar_width ) ).addClass( 'tablet-push-' + ( total_sidebar_width ) ); - } - } - jQuery('body').trigger('generate_spacing_updated'); - } - } ); -} ); - -/** - * Left sidebar width - */ -wp.customize( 'generate_spacing_settings[left_sidebar_width]', function( value ) { - value.bind( function( newval ) { - var body = jQuery( 'body' ); - if ( jQuery( '#left-sidebar' ).length ) { - if ( gp_spacing.isFlex ) { - var contentWidth = 100, - rightSidebar = jQuery( '#right-sidebar' ).length ? wp.customize.value('generate_spacing_settings[right_sidebar_width]')() : 0; - - if ( body.hasClass( 'left-sidebar' ) ) { - contentWidth = ( Number( contentWidth ) - Number( newval ) ); - } else if ( ! body.hasClass( 'right-sidebar' ) && ! body.hasClass( 'no-sidebar' ) ) { - var totalSidebarWidth = ( Number( rightSidebar ) + Number( newval ) ); - - contentWidth = ( Number( contentWidth ) - Number( totalSidebarWidth ) ); - } - - jQuery( 'head' ).append( '' ); - - setTimeout(function() { - jQuery( 'style#left_sidebar_width' ).not( ':last' ).remove(); - }, 200 ); - } else { - // Right sidebar width - var right_sidebar = ( jQuery( '#right-sidebar' ).length ) ? wp.customize.value('generate_spacing_settings[right_sidebar_width]')() : 0; - - // Right sidebar class - jQuery( "#left-sidebar" ).removeClass(function (index, css) { - return (css.match (/(^|\s)grid-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-grid-\S+/g) || []).join(' '); - }).addClass( 'grid-' + newval ).addClass( 'tablet-grid-' + newval ).addClass( 'grid-parent' ); - - // Content area class - jQuery( ".content-area" ).removeClass(function (index, css) { - return (css.match (/(^|\s)grid-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-grid-\S+/g) || []).join(' '); - }).addClass( 'grid-' + ( 100 - newval - right_sidebar ) ).addClass( 'tablet-grid-' + ( 100 - newval - right_sidebar ) ).addClass( 'grid-parent' ); - - if ( body.hasClass( 'left-sidebar' ) ) { - jQuery( '#left-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( 100 - newval ) ).addClass( 'tablet-pull-' + ( 100 - newval ) ); - - jQuery( '.content-area' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'push-' + newval ).addClass( 'tablet-push-' + newval ).addClass( 'grid-' + ( 100 - newval ) ).addClass( 'tablet-grid-' + ( 100 - newval ) ); - } - - if ( body.hasClass( 'both-sidebars' ) ) { - var content_width = ( 100 - newval - right_sidebar ); - jQuery( '#left-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( content_width ) ).addClass( 'tablet-pull-' + ( content_width ) ); - - jQuery( '.content-area' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'push-' + ( newval ) ).addClass( 'tablet-push-' + ( newval ) ); - } - - if ( body.hasClass( 'both-left' ) ) { - var content_width = ( 100 - newval - right_sidebar ); - var total_sidebar_width = ( parseInt( right_sidebar ) + parseInt( newval ) ); - - jQuery( '#right-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( 100 - total_sidebar_width ) ).addClass( 'tablet-pull-' + ( 100 - total_sidebar_width ) ); - - jQuery( '#left-sidebar' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).addClass( 'pull-' + ( 100 - total_sidebar_width ) ).addClass( 'tablet-pull-' + ( 100 - total_sidebar_width ) ); - - jQuery( '.content-area' ).removeClass(function (index, css) { - return (css.match (/(^|\s)pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-pull-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)push-\S+/g) || []).join(' '); - }).removeClass(function (index, css) { - return (css.match (/(^|\s)tablet-push-\S+/g) || []).join(' '); - }).addClass( 'push-' + ( total_sidebar_width ) ).addClass( 'tablet-push-' + ( total_sidebar_width ) ); - } - } - jQuery('body').trigger('generate_spacing_updated'); - } - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/navigation-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/navigation-spacing.php deleted file mode 100644 index 09884e67..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/navigation-spacing.php +++ /dev/null @@ -1,281 +0,0 @@ -add_section( - 'generate_spacing_navigation', - array( - 'title' => __( 'Primary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 15, - 'panel' => 'generate_spacing_panel', - ) -); - -// If our new Layout section doesn't exist, use the old navigation section. -$navigation_section = ( $wp_customize->get_panel( 'generate_layout_panel' ) ) ? 'generate_layout_navigation' : 'generate_spacing_navigation'; - -// Menu item width. -$wp_customize->add_setting( - 'generate_spacing_settings[menu_item]', - array( - 'default' => $defaults['menu_item'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_menu_item]', - array( - 'default' => $defaults['mobile_menu_item'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[menu_item]', - array( - 'label' => __( 'Menu Item Width', 'gp-premium' ), - 'section' => $navigation_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[menu_item]', - 'mobile' => 'generate_spacing_settings[mobile_menu_item]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 220, - ) - ) -); - -// Menu item height. -$wp_customize->add_setting( - 'generate_spacing_settings[menu_item_height]', - array( - 'default' => $defaults['menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_menu_item_height]', - array( - 'default' => $defaults['mobile_menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[menu_item_height]', - array( - 'label' => __( 'Menu Item Height', 'gp-premium' ), - 'section' => $navigation_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[menu_item_height]', - 'mobile' => 'generate_spacing_settings[mobile_menu_item_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 20, - 'max' => 150, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 20, - 'max' => 150, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 240, - ) - ) -); - -// Sub-menu item height. -$wp_customize->add_setting( - 'generate_spacing_settings[sub_menu_item_height]', - array( - 'default' => $defaults['sub_menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[sub_menu_item_height]', - array( - 'label' => __( 'Sub-Menu Item Height', 'gp-premium' ), - 'section' => $navigation_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[sub_menu_item_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 50, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 260, - ) - ) -); - -if ( isset( $defaults['sub_menu_width'] ) ) { - $wp_customize->add_setting( - 'generate_spacing_settings[sub_menu_width]', - array( - 'default' => $defaults['sub_menu_width'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[sub_menu_width]', - array( - 'label' => __( 'Sub-Menu Width', 'gp-premium' ), - 'section' => $navigation_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[sub_menu_width]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 100, - 'max' => 500, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 265, - ) - ) - ); -} - -// Sticky menu height. -$wp_customize->add_setting( - 'generate_spacing_settings[sticky_menu_item_height]', - array( - 'default' => $defaults['sticky_menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[sticky_menu_item_height]', - array( - 'label' => __( 'Menu Item Height', 'gp-premium' ), - 'section' => 'menu_plus_sticky_menu', - 'settings' => array( - 'desktop' => 'generate_spacing_settings[sticky_menu_item_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 20, - 'max' => 150, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 150, - 'active_callback' => 'generate_sticky_navigation_activated', - ) - ) -); - -// Off canvas menu height. -$wp_customize->add_setting( - 'generate_spacing_settings[off_canvas_menu_item_height]', - array( - 'default' => $defaults['off_canvas_menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[off_canvas_menu_item_height]', - array( - 'label' => __( 'Menu Item Height', 'gp-premium' ), - 'section' => 'menu_plus_slideout_menu', - 'settings' => array( - 'desktop' => 'generate_spacing_settings[off_canvas_menu_item_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 20, - 'max' => 150, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 200, - 'active_callback' => 'generate_slideout_navigation_activated', - ) - ) -); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/secondary-nav-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/secondary-nav-spacing.php deleted file mode 100644 index dd565a57..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/secondary-nav-spacing.php +++ /dev/null @@ -1,159 +0,0 @@ -get_section( 'secondary_nav_section' ) ) { - return; - } - - // Get our controls. - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - // Get our defaults. - $defaults = generate_secondary_nav_get_defaults(); - - // Remove our old label control if it exists. - // It only would if the user is using an old Secondary Nav add-on version. - if ( $wp_customize->get_control( 'generate_secondary_navigation_spacing_title' ) ) { - $wp_customize->remove_control( 'generate_secondary_navigation_spacing_title' ); - } - - // Menu item width. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_menu_item]', - array( - 'default' => $defaults['secondary_menu_item'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_secondary_nav_settings[secondary_menu_item]', - array( - 'label' => __( 'Menu Item Width', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'settings' => array( - 'desktop' => 'generate_secondary_nav_settings[secondary_menu_item]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 220, - ) - ) - ); - - // Menu item height. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_menu_item_height]', - array( - 'default' => $defaults['secondary_menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_secondary_nav_settings[secondary_menu_item_height]', - array( - 'label' => __( 'Menu Item Height', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'settings' => array( - 'desktop' => 'generate_secondary_nav_settings[secondary_menu_item_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 20, - 'max' => 150, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 240, - ) - ) - ); - - // Sub-menu height. - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_sub_menu_item_height]', - array( - 'default' => $defaults['secondary_sub_menu_item_height'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_secondary_nav_settings[secondary_sub_menu_item_height]', - array( - 'label' => __( 'Sub-Menu Item Height', 'gp-premium' ), - 'section' => 'secondary_nav_section', - 'settings' => array( - 'desktop' => 'generate_secondary_nav_settings[secondary_sub_menu_item_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 50, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'priority' => 260, - ) - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/sidebar-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/sidebar-spacing.php deleted file mode 100644 index b8c3b0c7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/sidebar-spacing.php +++ /dev/null @@ -1,211 +0,0 @@ -add_section( - 'generate_spacing_sidebar', - array( - 'title' => __( 'Sidebars', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 15, - 'panel' => 'generate_spacing_panel', - ) -); - -// Add our controls to the Layout panel if it exists. -// If not, use the old section. -$widget_section = ( $wp_customize->get_panel( 'generate_layout_panel' ) ) ? 'generate_layout_sidebars' : 'generate_spacing_sidebar'; - -// Widget padding top. -$wp_customize->add_setting( - 'generate_spacing_settings[widget_top]', - array( - 'default' => $defaults['widget_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding right. -$wp_customize->add_setting( - 'generate_spacing_settings[widget_right]', - array( - 'default' => $defaults['widget_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[widget_bottom]', - array( - 'default' => $defaults['widget_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding left. -$wp_customize->add_setting( - 'generate_spacing_settings[widget_left]', - array( - 'default' => $defaults['widget_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding top. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_widget_top]', - array( - 'default' => $defaults['mobile_widget_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding right. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_widget_right]', - array( - 'default' => $defaults['mobile_widget_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding bottom. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_widget_bottom]', - array( - 'default' => $defaults['mobile_widget_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Widget padding left. -$wp_customize->add_setting( - 'generate_spacing_settings[mobile_widget_left]', - array( - 'default' => $defaults['mobile_widget_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -// Make use of the widget padding settings. -$wp_customize->add_control( - new GeneratePress_Spacing_Control( - $wp_customize, - 'widget_spacing', - array( - 'type' => 'generatepress-spacing', - 'label' => esc_html__( 'Widget Padding', 'gp-premium' ), - 'section' => $widget_section, - 'settings' => array( - 'desktop_top' => 'generate_spacing_settings[widget_top]', - 'desktop_right' => 'generate_spacing_settings[widget_right]', - 'desktop_bottom' => 'generate_spacing_settings[widget_bottom]', - 'desktop_left' => 'generate_spacing_settings[widget_left]', - 'mobile_top' => 'generate_spacing_settings[mobile_widget_top]', - 'mobile_right' => 'generate_spacing_settings[mobile_widget_right]', - 'mobile_bottom' => 'generate_spacing_settings[mobile_widget_bottom]', - 'mobile_left' => 'generate_spacing_settings[mobile_widget_left]', - ), - 'element' => 'widget', - 'priority' => 99, - ) - ) -); - -// Left sidebar width. -$wp_customize->add_setting( - 'generate_spacing_settings[left_sidebar_width]', - array( - 'default' => $defaults['left_sidebar_width'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[left_sidebar_width]', - array( - 'label' => esc_html__( 'Left Sidebar Width', 'gp-premium' ), - 'section' => $widget_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[left_sidebar_width]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 15, - 'max' => 50, - 'step' => 5, - 'edit' => false, - 'unit' => '%', - ), - ), - 'priority' => 125, - ) - ) -); - -// Right sidebar width. -$wp_customize->add_setting( - 'generate_spacing_settings[right_sidebar_width]', - array( - 'default' => $defaults['right_sidebar_width'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) -); - -$wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_spacing_settings[right_sidebar_width]', - array( - 'label' => esc_html__( 'Right Sidebar Width', 'gp-premium' ), - 'section' => $widget_section, - 'settings' => array( - 'desktop' => 'generate_spacing_settings[right_sidebar_width]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 15, - 'max' => 50, - 'step' => 5, - 'edit' => false, - 'unit' => '%', - ), - ), - 'priority' => 125, - ) - ) -); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/top-bar-spacing.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/top-bar-spacing.php deleted file mode 100644 index ecc0f085..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/customizer/top-bar-spacing.php +++ /dev/null @@ -1,73 +0,0 @@ -add_setting( - 'generate_spacing_settings[top_bar_top]', - array( - 'default' => $defaults['top_bar_top'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_spacing_settings[top_bar_right]', - array( - 'default' => $defaults['top_bar_right'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_spacing_settings[top_bar_bottom]', - array( - 'default' => $defaults['top_bar_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_spacing_settings[top_bar_left]', - array( - 'default' => $defaults['top_bar_left'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Spacing_Control( - $wp_customize, - 'top_bar_spacing', - array( - 'type' => 'generatepress-spacing', - 'label' => esc_html__( 'Top Bar Padding', 'gp-premium' ), - 'section' => 'generate_top_bar', - 'settings' => array( - 'desktop_top' => 'generate_spacing_settings[top_bar_top]', - 'desktop_right' => 'generate_spacing_settings[top_bar_right]', - 'desktop_bottom' => 'generate_spacing_settings[top_bar_bottom]', - 'desktop_left' => 'generate_spacing_settings[top_bar_left]', - ), - 'element' => 'top_bar', - 'priority' => 99, - 'active_callback' => 'generate_premium_is_top_bar_active', - ) - ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/functions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/functions.php deleted file mode 100644 index a428989c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/functions.php +++ /dev/null @@ -1,362 +0,0 @@ -register_control_type( 'GeneratePress_Pro_Range_Slider_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Spacing_Control' ); - } - - // Add our Spacing panel. - // This is only used if the Layout panel in the free theme doesn't exist. - if ( class_exists( 'WP_Customize_Panel' ) ) { - if ( ! $wp_customize->get_panel( 'generate_spacing_panel' ) ) { - $wp_customize->add_panel( - 'generate_spacing_panel', - array( - 'capability' => 'edit_theme_options', - 'theme_supports' => '', - 'title' => __( 'Spacing', 'gp-premium' ), - 'description' => __( 'Change the spacing for various elements using pixels.', 'gp-premium' ), - 'priority' => 35, - ) - ); - } - } - - require_once plugin_dir_path( __FILE__ ) . 'customizer/top-bar-spacing.php'; - require_once plugin_dir_path( __FILE__ ) . 'customizer/header-spacing.php'; - require_once plugin_dir_path( __FILE__ ) . 'customizer/content-spacing.php'; - require_once plugin_dir_path( __FILE__ ) . 'customizer/sidebar-spacing.php'; - require_once plugin_dir_path( __FILE__ ) . 'customizer/navigation-spacing.php'; - require_once plugin_dir_path( __FILE__ ) . 'customizer/footer-spacing.php'; - - } -} - -if ( ! function_exists( 'generate_right_sidebar_width' ) ) { - add_filter( 'generate_right_sidebar_width', 'generate_right_sidebar_width' ); - /** - * Set our right sidebar width. - * - * @param int $width The sidebar width. - */ - function generate_right_sidebar_width( $width ) { - // Bail if we don't have our defaults. - if ( ! function_exists( 'generate_spacing_get_defaults' ) ) { - return $width; - } - - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - - return absint( $spacing_settings['right_sidebar_width'] ); - } -} - -if ( ! function_exists( 'generate_left_sidebar_width' ) ) { - add_filter( 'generate_left_sidebar_width', 'generate_left_sidebar_width' ); - /** - * Set our left sidebar width. - * - * @param int $width The sidebar width. - */ - function generate_left_sidebar_width( $width ) { - // Bail if we don't have our defaults. - if ( ! function_exists( 'generate_spacing_get_defaults' ) ) { - return $width; - } - - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - - return absint( $spacing_settings['left_sidebar_width'] ); - } -} - -if ( ! function_exists( 'generate_spacing_customizer_live_preview' ) ) { - add_action( 'customize_preview_init', 'generate_spacing_customizer_live_preview' ); - /** - * Add our live preview JS - */ - function generate_spacing_customizer_live_preview() { - wp_enqueue_script( - 'generate-spacing-customizer', - trailingslashit( plugin_dir_url( __FILE__ ) ) . 'customizer/js/customizer.js', - array( 'jquery', 'customize-preview' ), - GENERATE_SPACING_VERSION, - true - ); - - wp_localize_script( - 'generate-spacing-customizer', - 'gp_spacing', - array( - 'mobile' => generate_premium_get_media_query( 'mobile' ), - 'tablet' => generate_premium_get_media_query( 'tablet' ), - 'desktop' => generate_premium_get_media_query( 'desktop' ), - 'isFlex' => function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox(), - ) - ); - } -} - -if ( ! function_exists( 'generate_include_spacing_defaults' ) ) { - /** - * Check if we should include our default.css file. - * - * @since 1.3.42 - */ - function generate_include_spacing_defaults() { - return true; - } -} - -if ( ! function_exists( 'generate_spacing_premium_defaults' ) ) { - add_filter( 'generate_spacing_option_defaults', 'generate_spacing_premium_defaults' ); - /** - * Add premium spacing defaults. - * - * @since 1.3 - * @param array $defaults The existing defaults. - */ - function generate_spacing_premium_defaults( $defaults ) { - $defaults['mobile_menu_item'] = ''; - $defaults['mobile_menu_item_height'] = ''; - $defaults['sticky_menu_item_height'] = ''; - $defaults['off_canvas_menu_item_height'] = ''; - $defaults['content_element_separator'] = '2'; // em. - - // These defaults were added to GeneratePress (free) in 3.0.0. - if ( defined( 'GENERATE_VERSION' ) && version_compare( GENERATE_VERSION, '3.0.0-alpha.1', '<' ) ) { - $defaults['mobile_header_top'] = ''; - $defaults['mobile_header_right'] = ''; - $defaults['mobile_header_bottom'] = ''; - $defaults['mobile_header_left'] = ''; - - $defaults['mobile_widget_top'] = ''; - $defaults['mobile_widget_right'] = ''; - $defaults['mobile_widget_bottom'] = ''; - $defaults['mobile_widget_left'] = ''; - - $defaults['mobile_footer_widget_container_top'] = ''; - $defaults['mobile_footer_widget_container_right'] = ''; - $defaults['mobile_footer_widget_container_bottom'] = ''; - $defaults['mobile_footer_widget_container_left'] = ''; - } - - return $defaults; - } -} - -/** - * Build our premium CSS. - */ -function generate_spacing_do_premium_css() { - // Bail if we don't have our defaults. - if ( ! function_exists( 'generate_spacing_get_defaults' ) ) { - return; - } - - $spacing_settings = wp_parse_args( - get_option( 'generate_spacing_settings', array() ), - generate_spacing_get_defaults() - ); - - require_once GP_LIBRARY_DIRECTORY . 'class-make-css.php'; - $premium_css = new GeneratePress_Pro_CSS(); - $css_output = ''; - - // Mobile spacing. - $premium_css->start_media_query( generate_premium_get_media_query( 'mobile-menu' ) ); - - if ( '' !== $spacing_settings['mobile_menu_item'] ) { - $premium_css->set_selector( '.main-navigation .menu-toggle,.main-navigation .mobile-bar-items a,.main-navigation .menu-bar-item > a' ); - $premium_css->add_property( 'padding-left', absint( $spacing_settings['mobile_menu_item'] ), false, 'px' ); - $premium_css->add_property( 'padding-right', absint( $spacing_settings['mobile_menu_item'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_menu_item_height'] ) { - $premium_css->set_selector( '.main-navigation .main-nav ul li a,.main-navigation .menu-toggle,.main-navigation .mobile-bar-items a,.main-navigation .menu-bar-item > a' ); - $premium_css->add_property( 'line-height', absint( $spacing_settings['mobile_menu_item_height'] ), false, 'px' ); - - $premium_css->set_selector( '.main-navigation .site-logo.navigation-logo img, .mobile-header-navigation .site-logo.mobile-header-logo img, .navigation-search input[type="search"]' ); - $premium_css->add_property( 'height', absint( $spacing_settings['mobile_menu_item_height'] ), false, 'px' ); - } - - $premium_css->stop_media_query(); - - // This CSS was added to GeneratePress (free) in 3.0.0. - if ( defined( 'GENERATE_VERSION' ) && version_compare( GENERATE_VERSION, '3.0.0-alpha.1', '<' ) ) { - $premium_css->start_media_query( generate_premium_get_media_query( 'mobile' ) ); - - $premium_css->set_selector( '.inside-header' ); - - if ( '' !== $spacing_settings['mobile_header_top'] ) { - $premium_css->add_property( 'padding-top', absint( $spacing_settings['mobile_header_top'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_header_right'] ) { - $premium_css->add_property( 'padding-right', absint( $spacing_settings['mobile_header_right'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_header_bottom'] ) { - $premium_css->add_property( 'padding-bottom', absint( $spacing_settings['mobile_header_bottom'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_header_left'] ) { - $premium_css->add_property( 'padding-left', absint( $spacing_settings['mobile_header_left'] ), false, 'px' ); - } - - $premium_css->set_selector( '.widget-area .widget' ); - - if ( '' !== $spacing_settings['mobile_widget_top'] ) { - $premium_css->add_property( 'padding-top', absint( $spacing_settings['mobile_widget_top'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_widget_right'] ) { - $premium_css->add_property( 'padding-right', absint( $spacing_settings['mobile_widget_right'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_widget_bottom'] ) { - $premium_css->add_property( 'padding-bottom', absint( $spacing_settings['mobile_widget_bottom'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_widget_left'] ) { - $premium_css->add_property( 'padding-left', absint( $spacing_settings['mobile_widget_left'] ), false, 'px' ); - } - - $premium_css->set_selector( '.footer-widgets' ); - - if ( '' !== $spacing_settings['mobile_footer_widget_container_top'] ) { - $premium_css->add_property( 'padding-top', absint( $spacing_settings['mobile_footer_widget_container_top'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_footer_widget_container_right'] ) { - $premium_css->add_property( 'padding-right', absint( $spacing_settings['mobile_footer_widget_container_right'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_footer_widget_container_bottom'] ) { - $premium_css->add_property( 'padding-bottom', absint( $spacing_settings['mobile_footer_widget_container_bottom'] ), false, 'px' ); - } - - if ( '' !== $spacing_settings['mobile_footer_widget_container_left'] ) { - $premium_css->add_property( 'padding-left', absint( $spacing_settings['mobile_footer_widget_container_left'] ), false, 'px' ); - } - - $premium_css->stop_media_query(); - - $premium_css->set_selector( '.post-image, .page-content, .entry-content, .entry-summary, footer.entry-meta' ); - $premium_css->add_property( 'margin-top', floatval( $spacing_settings['content_element_separator'] ), '2', 'em' ); - } else { - $premium_css->set_selector( '.post-image:not(:first-child), .page-content:not(:first-child), .entry-content:not(:first-child), .entry-summary:not(:first-child), footer.entry-meta' ); - $premium_css->add_property( 'margin-top', floatval( $spacing_settings['content_element_separator'] ), '2', 'em' ); - } - - $premium_css->set_selector( '.post-image-above-header .inside-article div.featured-image, .post-image-above-header .inside-article div.post-image' ); - $premium_css->add_property( 'margin-bottom', floatval( $spacing_settings['content_element_separator'] ), '2', 'em' ); - - if ( function_exists( 'generate_menu_plus_get_defaults' ) ) { - $menu_plus = wp_parse_args( - get_option( 'generate_menu_plus_settings', array() ), - generate_menu_plus_get_defaults() - ); - - if ( 'false' !== $menu_plus['sticky_menu'] && '' !== $spacing_settings['sticky_menu_item_height'] ) { - $premium_css->start_media_query( generate_premium_get_media_query( 'tablet' ) . ',' . generate_premium_get_media_query( 'desktop' ) ); - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $premium_css->set_selector( '.main-navigation.sticky-navigation-transition .main-nav > ul > li > a,.sticky-navigation-transition .menu-toggle,.main-navigation.sticky-navigation-transition .menu-bar-item > a, .sticky-navigation-transition .navigation-branding .main-title' ); - } else { - $premium_css->set_selector( '.main-navigation.sticky-navigation-transition .main-nav > ul > li > a,.sticky-navigation-transition .menu-toggle,.main-navigation.sticky-navigation-transition .mobile-bar-items a, .sticky-navigation-transition .navigation-branding .main-title' ); - } - - $premium_css->add_property( 'line-height', absint( $spacing_settings['sticky_menu_item_height'] ), false, 'px' ); - - $premium_css->set_selector( '.main-navigation.sticky-navigation-transition .site-logo img, .main-navigation.sticky-navigation-transition .navigation-search input[type="search"], .main-navigation.sticky-navigation-transition .navigation-branding img' ); - $premium_css->add_property( 'height', absint( $spacing_settings['sticky_menu_item_height'] ), false, 'px' ); - - $premium_css->stop_media_query(); - } - - if ( 'false' !== $menu_plus['slideout_menu'] ) { - $premium_css->set_selector( '.main-navigation.slideout-navigation .main-nav > ul > li > a' ); - if ( '' !== $spacing_settings['off_canvas_menu_item_height'] ) { - $premium_css->add_property( 'line-height', absint( $spacing_settings['off_canvas_menu_item_height'] ), false, 'px' ); - } - } - } - - if ( '' !== $premium_css->css_output() ) { - $css_output = $premium_css->css_output(); - } - - return $css_output; -} - -if ( ! function_exists( 'generate_spacing_premium_css' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_spacing_premium_css', 105 ); - /** - * Add premium spacing CSS - * - * @since 1.3 - */ - function generate_spacing_premium_css() { - $css = generate_spacing_do_premium_css(); - - if ( 'inline' === generate_get_css_print_method() && $css ) { - wp_add_inline_style( 'generate-style', $css ); - } - } -} - -add_filter( 'generate_external_dynamic_css_output', 'generate_spacing_add_to_external_stylesheet' ); -/** - * Add CSS to the external stylesheet. - * - * @since 1.11.0 - * @param string $css Existing CSS. - */ -function generate_spacing_add_to_external_stylesheet( $css ) { - if ( 'inline' === generate_get_css_print_method() ) { - return $css; - } - - $css .= generate_spacing_do_premium_css(); - - return $css; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/migration.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/migration.php deleted file mode 100644 index 1eac04b6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/spacing/functions/migration.php +++ /dev/null @@ -1,102 +0,0 @@ -register_control_type( 'GeneratePress_Pro_Range_Slider_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Pro_Typography_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Add the typography panel. - if ( class_exists( 'WP_Customize_Panel' ) ) { - $wp_customize->add_panel( - 'generate_typography_panel', - array( - 'priority' => 30, - 'capability' => 'edit_theme_options', - 'theme_supports' => '', - 'title' => __( 'Typography', 'gp-premium' ), - 'description' => '', - ) - ); - } - - // Body section. - $wp_customize->add_section( - 'font_section', - array( - 'title' => __( 'Body', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 30, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_body_typography_shortcuts', - array( - 'section' => 'font_section', - 'element' => __( 'Body', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'body_section', - 'backgrounds' => 'generate_backgrounds_body', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_body]', - array( - 'default' => $defaults['font_body'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_body_variants', - array( - 'default' => $defaults['font_body_variants'], - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'font_body_category', - array( - 'default' => $defaults['font_body_category'], - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[body_font_weight]', - array( - 'default' => $defaults['body_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[body_font_transform]', - array( - 'default' => $defaults['body_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'body_typography', - array( - 'section' => 'font_section', - 'priority' => 1, - 'settings' => array( - 'family' => 'generate_settings[font_body]', - 'variant' => 'font_body_variants', - 'category' => 'font_body_category', - 'weight' => 'generate_settings[body_font_weight]', - 'transform' => 'generate_settings[body_font_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[body_font_size]', - array( - 'default' => $defaults['body_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[body_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_section', - 'priority' => 40, - 'settings' => array( - 'desktop' => 'generate_settings[body_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 25, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[body_line_height]', - array( - 'default' => $defaults['body_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[body_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_section', - 'priority' => 45, - 'settings' => array( - 'desktop' => 'generate_settings[body_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 1, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => '', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[paragraph_margin]', - array( - 'default' => $defaults['paragraph_margin'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[paragraph_margin]', - array( - 'description' => __( 'Paragraph margin', 'gp-premium' ), - 'section' => 'font_section', - 'priority' => 47, - 'settings' => array( - 'desktop' => 'generate_settings[paragraph_margin]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - - $wp_customize->add_section( - 'generate_top_bar_typography', - array( - 'title' => __( 'Top Bar', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 30, - 'panel' => 'generate_typography_panel', - ) - ); - - if ( isset( $defaults['font_top_bar'] ) && function_exists( 'generate_is_top_bar_active' ) ) { - $wp_customize->add_setting( - 'generate_settings[font_top_bar]', - array( - 'default' => $defaults['font_top_bar'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_top_bar_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_top_bar_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[top_bar_font_weight]', - array( - 'default' => $defaults['top_bar_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[top_bar_font_transform]', - array( - 'default' => $defaults['top_bar_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'top_bar_typography', - array( - 'section' => 'generate_top_bar_typography', - 'settings' => array( - 'family' => 'generate_settings[font_top_bar]', - 'variant' => 'font_top_bar_variants', - 'category' => 'font_top_bar_category', - 'weight' => 'generate_settings[top_bar_font_weight]', - 'transform' => 'generate_settings[top_bar_font_transform]', - ), - 'active_callback' => 'generate_premium_is_top_bar_active', - ) - ) - ); - - } - - if ( isset( $defaults['top_bar_font_size'] ) && function_exists( 'generate_is_top_bar_active' ) ) { - $wp_customize->add_setting( - 'generate_settings[top_bar_font_size]', - array( - 'default' => $defaults['top_bar_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[top_bar_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'generate_top_bar_typography', - 'priority' => 75, - 'settings' => array( - 'desktop' => 'generate_settings[top_bar_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 25, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - 'active_callback' => 'generate_premium_is_top_bar_active', - ) - ) - ); - } - - $wp_customize->add_section( - 'font_header_section', - array( - 'title' => __( 'Header', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 40, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_header_typography_shortcuts', - array( - 'section' => 'font_header_section', - 'element' => __( 'Header', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_header', - 'colors' => 'header_color_section', - 'backgrounds' => 'generate_backgrounds_header', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_site_title]', - array( - 'default' => $defaults['font_site_title'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_site_title_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_site_title_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[site_title_font_weight]', - array( - 'default' => $defaults['site_title_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[site_title_font_transform]', - array( - 'default' => $defaults['site_title_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'site_title_typography', - array( - 'label' => __( 'Site Title', 'gp-premium' ), - 'section' => 'font_header_section', - 'settings' => array( - 'family' => 'generate_settings[font_site_title]', - 'variant' => 'font_site_title_variants', - 'category' => 'font_site_title_category', - 'weight' => 'generate_settings[site_title_font_weight]', - 'transform' => 'generate_settings[site_title_font_transform]', - ), - 'priority' => 50, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[site_title_font_size]', - array( - 'default' => $defaults['site_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[tablet_site_title_font_size]', - array( - 'default' => $defaults['tablet_site_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[mobile_site_title_font_size]', - array( - 'default' => $defaults['mobile_site_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[site_title_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_header_section', - 'priority' => 75, - 'settings' => array( - 'desktop' => 'generate_settings[site_title_font_size]', - 'tablet' => 'generate_settings[tablet_site_title_font_size]', - 'mobile' => 'generate_settings[mobile_site_title_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 200, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'tablet' => array( - 'min' => 10, - 'max' => 200, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 10, - 'max' => 200, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_site_tagline]', - array( - 'default' => $defaults['font_site_tagline'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_site_tagline_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_site_tagline_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[site_tagline_font_weight]', - array( - 'default' => $defaults['site_tagline_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[site_tagline_font_transform]', - array( - 'default' => $defaults['site_tagline_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_site_tagline_control', - array( - 'label' => __( 'Site Tagline', 'gp-premium' ), - 'section' => 'font_header_section', - 'settings' => array( - 'family' => 'generate_settings[font_site_tagline]', - 'variant' => 'font_site_tagline_variants', - 'category' => 'font_site_tagline_category', - 'weight' => 'generate_settings[site_tagline_font_weight]', - 'transform' => 'generate_settings[site_tagline_font_transform]', - ), - 'priority' => 80, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[site_tagline_font_size]', - array( - 'default' => $defaults['site_tagline_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[site_tagline_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_header_section', - 'priority' => 105, - 'settings' => array( - 'desktop' => 'generate_settings[site_tagline_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 50, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_section( - 'font_navigation_section', - array( - 'title' => __( 'Primary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 50, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_primary_navigation_typography_shortcuts', - array( - 'section' => 'font_navigation_section', - 'element' => __( 'Primary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_navigation', - 'colors' => 'navigation_color_section', - 'backgrounds' => 'generate_backgrounds_navigation', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_navigation]', - array( - 'default' => $defaults['font_navigation'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_navigation_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_navigation_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_font_weight]', - array( - 'default' => $defaults['navigation_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_font_transform]', - array( - 'default' => $defaults['navigation_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'google_font_site_navigation_control', - array( - 'section' => 'font_navigation_section', - 'settings' => array( - 'family' => 'generate_settings[font_navigation]', - 'variant' => 'font_navigation_variants', - 'category' => 'font_navigation_category', - 'weight' => 'generate_settings[navigation_font_weight]', - 'transform' => 'generate_settings[navigation_font_transform]', - ), - 'priority' => 120, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[navigation_font_size]', - array( - 'default' => $defaults['navigation_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[tablet_navigation_font_size]', - array( - 'default' => $defaults['tablet_navigation_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[mobile_navigation_font_size]', - array( - 'default' => $defaults['mobile_navigation_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[navigation_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_navigation_section', - 'priority' => 165, - 'settings' => array( - 'desktop' => 'generate_settings[navigation_font_size]', - 'tablet' => 'generate_settings[tablet_navigation_font_size]', - 'mobile' => 'generate_settings[mobile_navigation_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'tablet' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_section( - 'font_buttons_section', - array( - 'title' => __( 'Buttons', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 55, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_buttons_typography_shortcuts', - array( - 'section' => 'font_buttons_section', - 'element' => __( 'Button', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'buttons_color_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - if ( isset( $defaults['font_buttons'] ) ) { - $wp_customize->add_setting( - 'generate_settings[font_buttons]', - array( - 'default' => $defaults['font_buttons'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_buttons_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_buttons_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[buttons_font_weight]', - array( - 'default' => $defaults['buttons_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[buttons_font_transform]', - array( - 'default' => $defaults['buttons_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_buttons_control', - array( - 'section' => 'font_buttons_section', - 'settings' => array( - 'family' => 'generate_settings[font_buttons]', - 'variant' => 'font_buttons_variants', - 'category' => 'font_buttons_category', - 'weight' => 'generate_settings[buttons_font_weight]', - 'transform' => 'generate_settings[buttons_font_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[buttons_font_size]', - array( - 'default' => $defaults['buttons_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'buttons_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_buttons_section', - 'settings' => array( - 'desktop' => 'generate_settings[buttons_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 5, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } - - $wp_customize->add_section( - 'font_content_section', - array( - 'title' => __( 'Headings', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 60, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_headings_typography_shortcuts', - array( - 'section' => 'font_content_section', - 'element' => __( 'Content', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_container', - 'colors' => 'content_color_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_heading_1]', - array( - 'default' => $defaults['font_heading_1'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_1_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_1_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_1_weight]', - array( - 'default' => $defaults['heading_1_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_1_transform]', - array( - 'default' => $defaults['heading_1_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_heading_1_control', - array( - 'label' => __( 'Heading 1 (H1)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'family' => 'generate_settings[font_heading_1]', - 'variant' => 'font_heading_1_variants', - 'category' => 'font_heading_1_category', - 'weight' => 'generate_settings[heading_1_weight]', - 'transform' => 'generate_settings[heading_1_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_1_font_size]', - array( - 'default' => $defaults['heading_1_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[mobile_heading_1_font_size]', - array( - 'default' => $defaults['mobile_heading_1_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'h1_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_1_font_size]', - 'mobile' => 'generate_settings[mobile_heading_1_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 15, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 15, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - if ( isset( $defaults['heading_1_line_height'] ) ) { - $wp_customize->add_setting( - 'generate_settings[heading_1_line_height]', - array( - 'default' => $defaults['heading_1_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_1_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_1_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - } - - if ( isset( $defaults['heading_1_margin_bottom'] ) ) { - $wp_customize->add_setting( - 'generate_settings[heading_1_margin_bottom]', - array( - 'default' => $defaults['heading_1_margin_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_1_margin_bottom]', - array( - 'description' => __( 'Bottom margin', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_1_margin_bottom]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } - - $wp_customize->add_setting( - 'generate_settings[single_post_title_weight]', - array( - 'default' => $defaults['single_post_title_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[single_post_title_transform]', - array( - 'default' => $defaults['single_post_title_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'single_content_title_control', - array( - 'label' => __( 'Single Content Title (H1)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'weight' => 'generate_settings[single_post_title_weight]', - 'transform' => 'generate_settings[single_post_title_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[single_post_title_font_size]', - array( - 'default' => $defaults['single_post_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[single_post_title_font_size_mobile]', - array( - 'default' => $defaults['single_post_title_font_size_mobile'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'single_post_title_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[single_post_title_font_size]', - 'mobile' => 'generate_settings[single_post_title_font_size_mobile]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 15, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 15, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[single_post_title_line_height]', - array( - 'default' => $defaults['single_post_title_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer_empty', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[single_post_title_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[single_post_title_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_heading_2]', - array( - 'default' => $defaults['font_heading_2'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_2_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_2_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_2_weight]', - array( - 'default' => $defaults['heading_2_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_2_transform]', - array( - 'default' => $defaults['heading_2_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_heading_2_control', - array( - 'label' => __( 'Heading 2 (H2)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'family' => 'generate_settings[font_heading_2]', - 'variant' => 'font_heading_2_variants', - 'category' => 'font_heading_2_category', - 'weight' => 'generate_settings[heading_2_weight]', - 'transform' => 'generate_settings[heading_2_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_2_font_size]', - array( - 'default' => $defaults['heading_2_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[mobile_heading_2_font_size]', - array( - 'default' => $defaults['mobile_heading_2_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'h2_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_2_font_size]', - 'mobile' => 'generate_settings[mobile_heading_2_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - if ( isset( $defaults['heading_2_line_height'] ) ) { - $wp_customize->add_setting( - 'generate_settings[heading_2_line_height]', - array( - 'default' => $defaults['heading_2_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_2_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_2_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - } - - if ( isset( $defaults['heading_2_margin_bottom'] ) ) { - $wp_customize->add_setting( - 'generate_settings[heading_2_margin_bottom]', - array( - 'default' => $defaults['heading_2_margin_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_2_margin_bottom]', - array( - 'description' => __( 'Bottom margin', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_2_margin_bottom]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } - - $wp_customize->add_setting( - 'generate_settings[archive_post_title_weight]', - array( - 'default' => $defaults['archive_post_title_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[archive_post_title_transform]', - array( - 'default' => $defaults['archive_post_title_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'archive_content_title_control', - array( - 'label' => __( 'Archive Content Title (H2)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'weight' => 'generate_settings[archive_post_title_weight]', - 'transform' => 'generate_settings[archive_post_title_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[archive_post_title_font_size]', - array( - 'default' => $defaults['archive_post_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[archive_post_title_font_size_mobile]', - array( - 'default' => $defaults['archive_post_title_font_size_mobile'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'archive_post_title_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[archive_post_title_font_size]', - 'mobile' => 'generate_settings[archive_post_title_font_size_mobile]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 15, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 15, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[archive_post_title_line_height]', - array( - 'default' => $defaults['archive_post_title_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer_empty', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[archive_post_title_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[archive_post_title_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_heading_3]', - array( - 'default' => $defaults['font_heading_3'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_3_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_3_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_3_weight]', - array( - 'default' => $defaults['heading_3_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_3_transform]', - array( - 'default' => $defaults['heading_3_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_heading_3_control', - array( - 'label' => __( 'Heading 3 (H3)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'family' => 'generate_settings[font_heading_3]', - 'variant' => 'font_heading_3_variants', - 'category' => 'font_heading_3_category', - 'weight' => 'generate_settings[heading_3_weight]', - 'transform' => 'generate_settings[heading_3_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_3_font_size]', - array( - 'default' => $defaults['heading_3_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $h3_font_size_options = array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ); - - $h3_font_size_settings = array( - 'desktop' => 'generate_settings[heading_3_font_size]', - ); - - if ( isset( $defaults['mobile_heading_3_font_size'] ) ) { - $wp_customize->add_setting( - 'generate_settings[mobile_heading_3_font_size]', - array( - 'default' => $defaults['mobile_heading_3_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $h3_font_size_options['mobile'] = array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ); - - $h3_font_size_settings['mobile'] = 'generate_settings[mobile_heading_3_font_size]'; - } - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'h3_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => $h3_font_size_settings, - 'choices' => $h3_font_size_options, - ) - ) - ); - - if ( isset( $defaults['heading_3_line_height'] ) ) { - $wp_customize->add_setting( - 'generate_settings[heading_3_line_height]', - array( - 'default' => $defaults['heading_3_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_3_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_3_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - } - - if ( isset( $defaults['heading_3_margin_bottom'] ) ) { - $wp_customize->add_setting( - 'generate_settings[heading_3_margin_bottom]', - array( - 'default' => $defaults['heading_3_margin_bottom'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_3_margin_bottom]', - array( - 'description' => __( 'Bottom margin', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_3_margin_bottom]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } - - if ( isset( $defaults['font_heading_4'] ) ) { - $wp_customize->add_setting( - 'generate_settings[font_heading_4]', - array( - 'default' => $defaults['font_heading_4'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_4_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_4_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_4_weight]', - array( - 'default' => $defaults['heading_4_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_4_transform]', - array( - 'default' => $defaults['heading_4_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_heading_4_control', - array( - 'label' => __( 'Heading 4 (H4)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'family' => 'generate_settings[font_heading_4]', - 'variant' => 'font_heading_4_variants', - 'category' => 'font_heading_4_category', - 'weight' => 'generate_settings[heading_4_weight]', - 'transform' => 'generate_settings[heading_4_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_4_font_size]', - array( - 'default' => $defaults['heading_4_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $h4_font_size_options = array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ); - - $h4_font_size_settings = array( - 'desktop' => 'generate_settings[heading_4_font_size]', - ); - - if ( isset( $defaults['mobile_heading_4_font_size'] ) ) { - $wp_customize->add_setting( - 'generate_settings[mobile_heading_4_font_size]', - array( - 'default' => $defaults['mobile_heading_4_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $h4_font_size_options['mobile'] = array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ); - - $h4_font_size_settings['mobile'] = 'generate_settings[mobile_heading_4_font_size]'; - } - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'h4_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => $h4_font_size_settings, - 'choices' => $h4_font_size_options, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_4_line_height]', - array( - 'default' => $defaults['heading_4_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer_empty', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_4_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_4_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - } - - if ( isset( $defaults['font_heading_5'] ) ) { - $wp_customize->add_setting( - 'generate_settings[font_heading_5]', - array( - 'default' => $defaults['font_heading_5'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_5_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_5_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_5_weight]', - array( - 'default' => $defaults['heading_5_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_5_transform]', - array( - 'default' => $defaults['heading_5_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_heading_5_control', - array( - 'label' => __( 'Heading 5 (H5)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'family' => 'generate_settings[font_heading_5]', - 'variant' => 'font_heading_5_variants', - 'category' => 'font_heading_5_category', - 'weight' => 'generate_settings[heading_5_weight]', - 'transform' => 'generate_settings[heading_5_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_5_font_size]', - array( - 'default' => $defaults['heading_5_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $h5_font_size_options = array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ); - - $h5_font_size_settings = array( - 'desktop' => 'generate_settings[heading_5_font_size]', - ); - - if ( isset( $defaults['mobile_heading_5_font_size'] ) ) { - $wp_customize->add_setting( - 'generate_settings[mobile_heading_5_font_size]', - array( - 'default' => $defaults['mobile_heading_5_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $h5_font_size_options['mobile'] = array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ); - - $h5_font_size_settings['mobile'] = 'generate_settings[mobile_heading_5_font_size]'; - } - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'h5_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => $h5_font_size_settings, - 'choices' => $h5_font_size_options, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_5_line_height]', - array( - 'default' => $defaults['heading_5_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer_empty', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_5_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_5_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - } - - if ( isset( $defaults['font_heading_6'] ) ) { - $wp_customize->add_setting( - 'generate_settings[font_heading_6]', - array( - 'default' => $defaults['font_heading_6'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_6_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_heading_6_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_6_weight]', - array( - 'default' => $defaults['heading_6_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_6_transform]', - array( - 'default' => $defaults['heading_6_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_heading_6_control', - array( - 'label' => __( 'Heading 6 (H6)', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'family' => 'generate_settings[font_heading_6]', - 'variant' => 'font_heading_6_variants', - 'category' => 'font_heading_6_category', - 'weight' => 'generate_settings[heading_6_weight]', - 'transform' => 'generate_settings[heading_6_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_6_font_size]', - array( - 'default' => $defaults['heading_6_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'h6_font_sizes', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_6_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[heading_6_line_height]', - array( - 'default' => $defaults['heading_6_line_height'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_decimal_integer_empty', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[heading_6_line_height]', - array( - 'description' => __( 'Line height', 'gp-premium' ), - 'section' => 'font_content_section', - 'settings' => array( - 'desktop' => 'generate_settings[heading_6_line_height]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 5, - 'step' => .1, - 'edit' => true, - 'unit' => 'em', - ), - ), - ) - ) - ); - } - - $wp_customize->add_section( - 'font_widget_section', - array( - 'title' => __( 'Widgets', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 60, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_widgets_typography_shortcuts', - array( - 'section' => 'font_widget_section', - 'element' => __( 'Widgets', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_sidebars', - 'colors' => 'sidebar_widget_color_section', - 'backgrounds' => 'generate_backgrounds_sidebars', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[font_widget_title]', - array( - 'default' => $defaults['font_widget_title'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_widget_title_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_widget_title_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[widget_title_font_weight]', - array( - 'default' => $defaults['widget_title_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[widget_title_font_transform]', - array( - 'default' => $defaults['widget_title_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'google_font_widget_title_control', - array( - 'label' => __( 'Widget Titles', 'gp-premium' ), - 'section' => 'font_widget_section', - 'settings' => array( - 'family' => 'generate_settings[font_widget_title]', - 'variant' => 'font_widget_title_variants', - 'category' => 'font_widget_title_category', - 'weight' => 'generate_settings[widget_title_font_weight]', - 'transform' => 'generate_settings[widget_title_font_transform]', - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[widget_title_font_size]', - array( - 'default' => $defaults['widget_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[widget_title_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_widget_section', - 'settings' => array( - 'desktop' => 'generate_settings[widget_title_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - if ( isset( $defaults['widget_title_separator'] ) ) { - $wp_customize->add_setting( - 'generate_settings[widget_title_separator]', - array( - 'default' => $defaults['widget_title_separator'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[widget_title_separator]', - array( - 'description' => __( 'Bottom margin', 'gp-premium' ), - 'section' => 'font_widget_section', - 'settings' => array( - 'desktop' => 'generate_settings[widget_title_separator]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } - - $wp_customize->add_setting( - 'generate_settings[widget_content_font_size]', - array( - 'default' => $defaults['widget_content_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[widget_content_font_size]', - array( - 'description' => __( 'Content font size', 'gp-premium' ), - 'section' => 'font_widget_section', - 'priority' => 240, - 'settings' => array( - 'desktop' => 'generate_settings[widget_content_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_section( - 'font_footer_section', - array( - 'title' => __( 'Footer', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 70, - 'panel' => 'generate_typography_panel', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_footer_typography_shortcuts', - array( - 'section' => 'font_footer_section', - 'element' => __( 'Footer', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_layout_footer', - 'colors' => 'footer_color_section', - 'backgrounds' => 'generate_backgrounds_footer', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - if ( isset( $defaults['font_footer'] ) ) { - $wp_customize->add_setting( - 'generate_settings[font_footer]', - array( - 'default' => $defaults['font_footer'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_footer_category', - array( - 'default' => '', - 'sanitize_callback' => 'sanitize_text_field', - ) - ); - - $wp_customize->add_setting( - 'font_footer_variants', - array( - 'default' => '', - 'sanitize_callback' => 'generate_premium_sanitize_variants', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[footer_weight]', - array( - 'default' => $defaults['footer_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_setting( - 'generate_settings[footer_transform]', - array( - 'default' => $defaults['footer_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'font_footer_control', - array( - 'section' => 'font_footer_section', - 'settings' => array( - 'family' => 'generate_settings[font_footer]', - 'variant' => 'font_footer_variants', - 'category' => 'font_footer_category', - 'weight' => 'generate_settings[footer_weight]', - 'transform' => 'generate_settings[footer_transform]', - ), - ) - ) - ); - } - - $wp_customize->add_setting( - 'generate_settings[footer_font_size]', - array( - 'default' => $defaults['footer_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[footer_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'font_footer_section', - 'settings' => array( - 'desktop' => 'generate_settings[footer_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } -} - -if ( ! function_exists( 'generate_enqueue_google_fonts' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_enqueue_google_fonts', 0 ); - /** - * Enqueue Google Fonts. - * - * @since 0.1 - */ - function generate_enqueue_google_fonts() { - // Bail if we don't have our defaults function. - if ( ! function_exists( 'generate_get_default_fonts' ) ) { - return; - } - - $generate_settings = wp_parse_args( - get_option( 'generate_settings', array() ), - generate_get_default_fonts() - ); - - // List our non-Google fonts. - $not_google = str_replace( ' ', '+', generate_typography_default_fonts() ); - - // Grab our font family settings. - $font_settings = array( - 'font_body', - 'font_top_bar', - 'font_site_title', - 'font_site_tagline', - 'font_navigation', - 'font_widget_title', - 'font_buttons', - 'font_heading_1', - 'font_heading_2', - 'font_heading_3', - 'font_heading_4', - 'font_heading_5', - 'font_heading_6', - 'font_footer', - ); - - // Create our Google Fonts array. - $google_fonts = array(); - if ( ! empty( $font_settings ) ) { - foreach ( $font_settings as $key ) { - // If the key isn't set, move on. - if ( ! isset( $generate_settings[ $key ] ) ) { - continue; - } - - // If our value is still using the old format, fix it. - if ( strpos( $generate_settings[ $key ], ':' ) !== false ) { - $generate_settings[ $key ] = current( explode( ':', $generate_settings[ $key ] ) ); - } - - // Replace the spaces in the names with a plus. - $value = str_replace( ' ', '+', $generate_settings[ $key ] ); - - // Grab the variants using the plain name. - $variants = generate_get_google_font_variants( $generate_settings[ $key ], $key, generate_get_default_fonts() ); - - // If we have variants, add them to our value. - $value = ! empty( $variants ) ? $value . ':' . $variants : $value; - - // Make sure we don't add the same font twice. - if ( ! in_array( $value, $google_fonts ) ) { - $google_fonts[] = $value; - } - } - } - - // Ignore any non-Google fonts. - $google_fonts = array_diff( $google_fonts, $not_google ); - - // Separate each different font with a bar. - $google_fonts = implode( '|', $google_fonts ); - - // Apply a filter to the output. - $google_fonts = apply_filters( 'generate_typography_google_fonts', $google_fonts ); - - // Get the subset. - $subset = apply_filters( 'generate_fonts_subset', '' ); - - // Set up our arguments. - $font_args = array(); - $font_args['family'] = $google_fonts; - if ( '' !== $subset ) { - $font_args['subset'] = urlencode( $subset ); // phpcs:ignore -- Keeping legacy urlencode(). - } - - $display = apply_filters( 'generate_google_font_display', '' ); - - if ( $display ) { - $font_args['display'] = $display; - } - - // Create our URL using the arguments. - $fonts_url = add_query_arg( $font_args, '//fonts.googleapis.com/css' ); - - // Enqueue our fonts. - if ( $google_fonts ) { - wp_enqueue_style( 'generate-fonts', $fonts_url, array(), null, 'all' ); // phpcs:ignore -- Version not needed. - } - } -} - -if ( ! function_exists( 'generate_get_all_google_fonts' ) ) { - /** - * Return an array of all of our Google Fonts. - * - * @since 1.3.0 - * @param string $amount The number of fonts to load. - */ - function generate_get_all_google_fonts( $amount = 'all' ) { - ob_start(); - include wp_normalize_path( dirname( __FILE__ ) . '/google-fonts.json' ); // phpcs:ignore WPThemeReview.CoreFunctionality.FileInclude - $fonts_json = ob_get_clean(); - $google_fonts = json_decode( $fonts_json ); - - // Loop through them and put what we need into our fonts array. - $fonts = array(); - foreach ( (array) $google_fonts as $item ) { - - // Grab what we need from our big list. - $atts = array( - 'name' => $item->family, - 'category' => $item->category, - 'variants' => $item->variants, - ); - - // Create an ID using our font family name. - $id = strtolower( str_replace( ' ', '_', $item->family ) ); - - // Add our attributes to our new array. - $fonts[ $id ] = $atts; - } - - if ( 'all' !== $amount ) { - $fonts = array_slice( $fonts, 0, $amount ); - } - - // Alphabetize our fonts. - if ( apply_filters( 'generate_alphabetize_google_fonts', true ) ) { - asort( $fonts ); - } - - // Filter to allow us to modify the fonts array. - return apply_filters( 'generate_google_fonts_array', $fonts ); - } -} - -if ( ! function_exists( 'generate_get_all_google_fonts_ajax' ) ) { - add_action( 'wp_ajax_generate_get_all_google_fonts_ajax', 'generate_get_all_google_fonts_ajax' ); - /** - * Return an array of all of our Google Fonts. - * - * @since 1.3.0 - */ - function generate_get_all_google_fonts_ajax() { - // Bail if the nonce doesn't check out. - if ( ! isset( $_POST['gp_customize_nonce'] ) || ! wp_verify_nonce( $_POST['gp_customize_nonce'], 'gp_customize_nonce' ) ) { - wp_die(); - } - - // Do another nonce check. - check_ajax_referer( 'gp_customize_nonce', 'gp_customize_nonce' ); - - // Bail if user can't edit theme options. - if ( ! current_user_can( 'edit_theme_options' ) ) { - wp_die(); - } - - // Get all of our fonts. - $fonts = apply_filters( 'generate_typography_customize_list', generate_get_all_google_fonts() ); - - // Send all of our fonts in JSON format. - echo wp_json_encode( $fonts ); - - die(); - } -} - -if ( ! function_exists( 'generate_get_google_font_variants' ) ) { - /** - * Wrapper function to find variants for chosen Google Fonts - * Example: generate_get_google_font_variation( 'Open Sans' ) - * - * @since 1.3.0 - * @param string $font The font we're checking. - * @param string $key The key we're checking. - * @param array $default The defaults we're checking. - */ - function generate_get_google_font_variants( $font, $key = '', $default = '' ) { - // Bail if we don't have our defaults function. - if ( ! function_exists( 'generate_get_default_fonts' ) ) { - return; - } - - // Don't need variants if we're using a system font. - if ( in_array( $font, generate_typography_default_fonts() ) ) { - return; - } - - // Return if we have our variants saved. - if ( '' !== $key && get_theme_mod( $key . '_variants' ) ) { - return get_theme_mod( $key . '_variants' ); - } - - // Make sure we have defaults. - if ( '' == $default ) { // phpcs:ignore -- Non-strict allowed. - $default = generate_get_default_fonts(); - } - - // If our default font is selected and the category isn't saved, we already know the category. - if ( $default[ $key ] == $font ) { // phpcs:ignore -- Non-strict allowed. - return $default[ $key . '_variants' ]; - } - - // Grab all of our fonts. - // It's a big list, so hopefully we're not even still reading. - $fonts = generate_get_all_google_fonts(); - - // Get the ID from our font. - $id = strtolower( str_replace( ' ', '_', $font ) ); - - // If the ID doesn't exist within our fonts, we can bail. - if ( ! array_key_exists( $id, $fonts ) ) { - return; - } - - // Grab all of the variants associated with our font. - $variants = $fonts[ $id ]['variants']; - - // Loop through them and put them into an array, then turn them into a comma separated list. - $output = array(); - if ( $variants ) { - foreach ( $variants as $variant ) { - $output[] = $variant; - } - - return implode( ',', apply_filters( 'generate_typography_variants', $output ) ); - } - } -} - -if ( ! function_exists( 'generate_get_google_font_category' ) ) { - /** - * Wrapper function to find the category for chosen Google Font - * Example: generate_get_google_font_category( 'Open Sans' ) - * - * @since 1.3.0 - * @param string $font The font we're checking. - * @param string $key The key we're checking. - * @param array $default The defaults we're checking. - */ - function generate_get_google_font_category( $font, $key = '', $default = '' ) { - // Bail if we don't have our defaults function. - if ( ! function_exists( 'generate_get_default_fonts' ) ) { - return; - } - - // Don't need a category if we're using a system font. - if ( in_array( $font, generate_typography_default_fonts() ) ) { - return; - } - - // Return if we have our variants saved. - if ( '' !== $key && get_theme_mod( $key . '_category' ) ) { - return ', ' . get_theme_mod( $key . '_category' ); - } - - // Make sure we have defaults. - if ( '' == $default ) { // phpcs:ignore -- Non-strict allowed. - $default = generate_get_default_fonts(); - } - - // If our default font is selected and the category isn't saved, we already know the category. - if ( $default[ $key ] == $font ) { // phpcs:ignore -- Non-strict allowed. - return ', ' . $default[ $key . '_category' ]; - } - - // Get all of our fonts. - // It's a big list, so hopefully we're not even still reading. - $fonts = generate_get_all_google_fonts(); - - // Get the ID from our font. - $id = strtolower( str_replace( ' ', '_', $font ) ); - - // If the ID doesn't exist within our fonts, we can bail. - if ( ! array_key_exists( $id, $fonts ) ) { - return; - } - - // Let's grab our category to go with our font. - $category = ! empty( $fonts[ $id ]['category'] ) ? ', ' . $fonts[ $id ]['category'] : ''; - - // Return it to be used by our function. - return $category; - - } -} - -if ( ! function_exists( 'generate_get_font_family_css' ) ) { - /** - * Wrapper function to create font-family value for CSS. - * - * @since 1.3.0 - * @param string $font The font we're checking. - * @param array $settings The settings we're checking. - * @param array $default The defaults we're checking. - */ - function generate_get_font_family_css( $font, $settings, $default ) { - $generate_settings = wp_parse_args( - get_option( $settings, array() ), - $default - ); - - // We don't want to wrap quotes around these values. - $no_quotes = array( - 'inherit', - 'Arial, Helvetica, sans-serif', - 'Georgia, Times New Roman, Times, serif', - 'Helvetica', - 'Impact', - 'Segoe UI, Helvetica Neue, Helvetica, sans-serif', - 'Tahoma, Geneva, sans-serif', - 'Trebuchet MS, Helvetica, sans-serif', - 'Verdana, Geneva, sans-serif', - apply_filters( 'generate_typography_system_stack', '-apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"' ), - ); - - // Get our font. - $font_family = $generate_settings[ $font ]; - - if ( 'System Stack' === $font_family ) { - $font_family = apply_filters( 'generate_typography_system_stack', '-apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"' ); - } - - // If our value is still using the old format, fix it. - if ( strpos( $font_family, ':' ) !== false ) { - $font_family = current( explode( ':', $font_family ) ); - } - - // Set up our wrapper. - if ( in_array( $font_family, $no_quotes ) ) { - $wrapper_start = null; - $wrapper_end = null; - } else { - $wrapper_start = '"'; - $wrapper_end = '"' . generate_get_google_font_category( $font_family, $font, $default ); - } - - // Output the CSS. - $output = ( 'inherit' === $font_family ) ? 'inherit' : $wrapper_start . $font_family . $wrapper_end; - return $output; - } -} - -if ( ! function_exists( 'generate_typography_customizer_live_preview' ) ) { - add_action( 'customize_preview_init', 'generate_typography_customizer_live_preview' ); - /** - * Add our live preview JS - */ - function generate_typography_customizer_live_preview() { - wp_enqueue_script( - 'generate-typography-customizer', - trailingslashit( plugin_dir_url( __FILE__ ) ) . 'js/customizer.js', - array( 'jquery', 'customize-preview' ), - GENERATE_FONT_VERSION, - true - ); - - wp_localize_script( - 'generate-typography-customizer', - 'gp_typography', - array( - 'mobile' => generate_premium_get_media_query( 'mobile' ), - 'tablet' => generate_premium_get_media_query( 'tablet' ), - 'desktop' => generate_premium_get_media_query( 'desktop' ), - ) - ); - } -} - -if ( ! function_exists( 'generate_typography_default_fonts' ) ) { - /** - * Get our system fonts - */ - function generate_typography_default_fonts() { - $fonts = array( - 'inherit', - 'System Stack', - 'Arial, Helvetica, sans-serif', - 'Century Gothic', - 'Comic Sans MS', - 'Courier New', - 'Georgia, Times New Roman, Times, serif', - 'Helvetica', - 'Impact', - 'Lucida Console', - 'Lucida Sans Unicode', - 'Palatino Linotype', - 'Segoe UI, Helvetica Neue, Helvetica, sans-serif', - 'Tahoma, Geneva, sans-serif', - 'Trebuchet MS, Helvetica, sans-serif', - 'Verdana, Geneva, sans-serif', - ); - - return apply_filters( 'generate_typography_default_fonts', $fonts ); - } -} - -if ( ! function_exists( 'generate_include_typography_defaults' ) ) { - /** - * Check if we should include our default.css file. - * - * @since 1.3.42 - */ - function generate_include_typography_defaults() { - return true; - } -} - -if ( ! function_exists( 'generate_typography_premium_css_defaults' ) ) { - add_filter( 'generate_font_option_defaults', 'generate_typography_premium_css_defaults' ); - /** - * Add premium control defaults - * - * @since 1.3 - * @param array $defaults The existing defaults. - */ - function generate_typography_premium_css_defaults( $defaults ) { - $defaults['tablet_site_title_font_size'] = ''; - $defaults['tablet_navigation_font_size'] = ''; - $defaults['mobile_navigation_font_size'] = ''; - - $defaults['single_post_title_weight'] = ''; - $defaults['single_post_title_transform'] = ''; - $defaults['single_post_title_font_size'] = ''; - $defaults['single_post_title_font_size_mobile'] = ''; - $defaults['single_post_title_line_height'] = ''; - - $defaults['archive_post_title_weight'] = ''; - $defaults['archive_post_title_transform'] = ''; - $defaults['archive_post_title_font_size'] = ''; - $defaults['archive_post_title_font_size_mobile'] = ''; - $defaults['archive_post_title_line_height'] = ''; - - return $defaults; - } -} - -/** - * Premium typography CSS output. - */ -function generate_typography_get_premium_css() { - if ( ! function_exists( 'generate_get_default_fonts' ) ) { - return; - } - - $generate_settings = wp_parse_args( - get_option( 'generate_settings', array() ), - generate_get_default_fonts() - ); - - // Initiate our CSS class. - require_once GP_LIBRARY_DIRECTORY . 'class-make-css.php'; - - $premium_css = new GeneratePress_Pro_CSS(); - - $site_title_family = false; - if ( function_exists( 'generate_get_font_family_css' ) ) { - $site_title_family = generate_get_font_family_css( 'font_site_title', 'generate_settings', generate_get_default_fonts() ); - } - - $premium_css->set_selector( 'h1.entry-title' ); - $premium_css->add_property( 'font-weight', esc_attr( $generate_settings['single_post_title_weight'] ) ); - $premium_css->add_property( 'text-transform', esc_attr( $generate_settings['single_post_title_transform'] ) ); - - if ( '' !== $generate_settings['single_post_title_font_size'] ) { - $premium_css->add_property( 'font-size', absint( $generate_settings['single_post_title_font_size'] ), false, 'px' ); - } - - if ( '' !== $generate_settings['single_post_title_line_height'] ) { - $premium_css->add_property( 'line-height', floatval( $generate_settings['single_post_title_line_height'] ), false, 'em' ); - } - - $premium_css->set_selector( 'h2.entry-title' ); - $premium_css->add_property( 'font-weight', esc_attr( $generate_settings['archive_post_title_weight'] ) ); - $premium_css->add_property( 'text-transform', esc_attr( $generate_settings['archive_post_title_transform'] ) ); - - if ( '' !== $generate_settings['archive_post_title_font_size'] ) { - $premium_css->add_property( 'font-size', absint( $generate_settings['archive_post_title_font_size'] ), false, 'px' ); - } - - if ( '' !== $generate_settings['archive_post_title_line_height'] ) { - $premium_css->add_property( 'line-height', floatval( $generate_settings['archive_post_title_line_height'] ), false, 'em' ); - } - - if ( function_exists( 'generate_menu_plus_get_defaults' ) ) { - $menu_settings = wp_parse_args( - get_option( 'generate_menu_plus_settings', array() ), - generate_menu_plus_get_defaults() - ); - - if ( $menu_settings['navigation_as_header'] || $menu_settings['sticky_navigation_logo'] || 'enable' === $menu_settings['mobile_header'] ) { - $premium_css->set_selector( '.navigation-branding .main-title' ); - $premium_css->add_property( 'font-weight', esc_attr( $generate_settings['site_title_font_weight'] ) ); - $premium_css->add_property( 'text-transform', esc_attr( $generate_settings['site_title_font_transform'] ) ); - $premium_css->add_property( 'font-size', absint( $generate_settings['site_title_font_size'] ), false, 'px' ); - - if ( $site_title_family ) { - $premium_css->add_property( 'font-family', 'inherit' !== $generate_settings['font_site_title'] ? $site_title_family : null ); - } - } - } - - $premium_css->start_media_query( generate_premium_get_media_query( 'tablet' ) ); - - if ( '' !== $generate_settings['tablet_navigation_font_size'] ) { - $premium_css->set_selector( '.main-navigation:not(.slideout-navigation) a, .main-navigation .menu-toggle, .main-navigation .menu-bar-items' ); - $premium_css->add_property( 'font-size', absint( $generate_settings['tablet_navigation_font_size'] ), false, 'px' ); - - $tablet_subnav_font_size = $generate_settings['tablet_navigation_font_size'] - 1; - - if ( $generate_settings['tablet_navigation_font_size'] >= 17 ) { - $tablet_subnav_font_size = $generate_settings['tablet_navigation_font_size'] - 3; - } - - $premium_css->set_selector( '.main-navigation:not(.slideout-navigation) .main-nav ul ul li a' ); - $premium_css->add_property( 'font-size', absint( $tablet_subnav_font_size ), false, 'px' ); - } - - if ( '' !== $generate_settings['tablet_site_title_font_size'] ) { - $premium_css->set_selector( '.main-title, .navigation-branding .main-title' ); - $premium_css->add_property( 'font-size', absint( $generate_settings['tablet_site_title_font_size'] ), false, 'px' ); - } - - $premium_css->stop_media_query(); - - $premium_css->start_media_query( generate_premium_get_media_query( 'mobile' ) ); - - $premium_css->set_selector( 'h1.entry-title' ); - - if ( '' !== $generate_settings['single_post_title_font_size_mobile'] ) { - $premium_css->add_property( 'font-size', absint( $generate_settings['single_post_title_font_size_mobile'] ), false, 'px' ); - } - - $premium_css->set_selector( 'h2.entry-title' ); - - if ( '' !== $generate_settings['archive_post_title_font_size_mobile'] ) { - $premium_css->add_property( 'font-size', absint( $generate_settings['archive_post_title_font_size_mobile'] ), false, 'px' ); - } - - $premium_css->stop_media_query(); - - $premium_css->start_media_query( generate_premium_get_media_query( 'mobile-menu' ) ); - - if ( ! empty( $generate_settings['mobile_navigation_font_size'] ) ) { - $premium_css->set_selector( '.main-navigation:not(.slideout-navigation) a, .main-navigation .menu-toggle, .main-navigation .menu-bar-items' ); - $premium_css->add_property( 'font-size', absint( $generate_settings['mobile_navigation_font_size'] ), false, 'px' ); - - $mobile_subnav_font_size = $generate_settings['mobile_navigation_font_size'] - 1; - - if ( $generate_settings['mobile_navigation_font_size'] >= 17 ) { - $mobile_subnav_font_size = $generate_settings['mobile_navigation_font_size'] - 3; - } - - $premium_css->set_selector( '.main-navigation:not(.slideout-navigation) .main-nav ul ul li a' ); - $premium_css->add_property( 'font-size', absint( $mobile_subnav_font_size ), false, 'px' ); - } - - if ( function_exists( 'generate_menu_plus_get_defaults' ) ) { - $menu_settings = wp_parse_args( - get_option( 'generate_menu_plus_settings', array() ), - generate_menu_plus_get_defaults() - ); - - if ( $menu_settings['navigation_as_header'] || $menu_settings['sticky_navigation_logo'] || 'enable' === $menu_settings['mobile_header'] ) { - if ( ! empty( $generate_settings['mobile_site_title_font_size'] ) ) { - $premium_css->set_selector( '.navigation-branding .main-title' ); - $premium_css->add_property( 'font-size', absint( $generate_settings['mobile_site_title_font_size'] ), false, 'px' ); - } - } - } - - $premium_css->stop_media_query(); - - return $premium_css->css_output(); -} - -if ( ! function_exists( 'generate_typography_premium_css' ) ) { - add_action( 'wp_enqueue_scripts', 'generate_typography_premium_css', 100 ); - /** - * Add premium control CSS - * - * @since 1.3 - */ - function generate_typography_premium_css() { - if ( 'inline' === generate_get_css_print_method() ) { - wp_add_inline_style( 'generate-style', generate_typography_get_premium_css() ); - } - } -} - -add_filter( 'generate_external_dynamic_css_output', 'generate_typography_add_to_external_stylesheet' ); -/** - * Add CSS to the external stylesheet. - * - * @since 1.11.0 - * @param string $css Existing CSS. - */ -function generate_typography_add_to_external_stylesheet( $css ) { - if ( 'inline' === generate_get_css_print_method() ) { - return $css; - } - - $css .= generate_typography_get_premium_css(); - - return $css; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/google-fonts.json b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/google-fonts.json deleted file mode 100644 index a574abcf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/google-fonts.json +++ /dev/null @@ -1,6835 +0,0 @@ -[ - { - "family": "Roboto", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Open Sans", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic" - ] - }, - { - "family": "Lato", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Slabo 27px", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Oswald", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Roboto Condensed", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Source Sans Pro", - "category": "sans-serif", - "variants": [ - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Montserrat", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Raleway", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "PT Sans", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Roboto Slab", - "category": "serif", - "variants": [ - "100", - "300", - "regular", - "700" - ] - }, - { - "family": "Merriweather", - "category": "serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Open Sans Condensed", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "700" - ] - }, - { - "family": "Droid Sans", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Lora", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Ubuntu", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "700", - "700italic" - ] - }, - { - "family": "Droid Serif", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Playfair Display", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Arimo", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Noto Sans", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "PT Serif", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Titillium Web", - "category": "sans-serif", - "variants": [ - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "900" - ] - }, - { - "family": "PT Sans Narrow", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Muli", - "category": "sans-serif", - "variants": [ - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Indie Flower", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Bitter", - "category": "serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Poppins", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Inconsolata", - "category": "monospace", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Dosis", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Fjalla One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Oxygen", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "700" - ] - }, - { - "family": "Hind", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Cabin", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Anton", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Arvo", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Noto Serif", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Crimson Text", - "category": "serif", - "variants": [ - "regular", - "italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Lobster", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Yanone Kaffeesatz", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "700" - ] - }, - { - "family": "Nunito", - "category": "sans-serif", - "variants": [ - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Bree Serif", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Catamaran", - "category": "sans-serif", - "variants": [ - "100", - "200", - "300", - "regular", - "500", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Libre Baskerville", - "category": "serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Abel", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Josefin Sans", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Fira Sans", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Gloria Hallelujah", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Abril Fatface", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Exo 2", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Merriweather Sans", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic", - "800", - "800italic" - ] - }, - { - "family": "Pacifico", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Roboto Mono", - "category": "monospace", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "700", - "700italic" - ] - }, - { - "family": "Varela Round", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Asap", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "500", - "500italic", - "700", - "700italic" - ] - }, - { - "family": "Amatic SC", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Quicksand", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "700" - ] - }, - { - "family": "Karla", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Ubuntu Condensed", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Signika", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "600", - "700" - ] - }, - { - "family": "Alegreya", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Questrial", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Rubik", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Shadows Into Light", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "PT Sans Caption", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Archivo Narrow", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Play", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Cuprum", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Dancing Script", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Rokkitt", - "category": "serif", - "variants": [ - "100", - "200", - "300", - "regular", - "500", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Work Sans", - "category": "sans-serif", - "variants": [ - "100", - "200", - "300", - "regular", - "500", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Francois One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Vollkorn", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Source Code Pro", - "category": "monospace", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700", - "900" - ] - }, - { - "family": "Exo", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Maven Pro", - "category": "sans-serif", - "variants": [ - "regular", - "500", - "700", - "900" - ] - }, - { - "family": "Architects Daughter", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Orbitron", - "category": "sans-serif", - "variants": [ - "regular", - "500", - "700", - "900" - ] - }, - { - "family": "Pathway Gothic One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Acme", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Ropa Sans", - "category": "sans-serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Patua One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "EB Garamond", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Lobster Two", - "category": "display", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Crete Round", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Cinzel", - "category": "serif", - "variants": [ - "regular", - "700", - "900" - ] - }, - { - "family": "Josefin Slab", - "category": "serif", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Source Serif Pro", - "category": "serif", - "variants": [ - "regular", - "600", - "700" - ] - }, - { - "family": "Alegreya Sans", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Comfortaa", - "category": "display", - "variants": [ - "300", - "regular", - "700" - ] - }, - { - "family": "Russo One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "News Cycle", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "ABeeZee", - "category": "sans-serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Yellowtail", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Noticia Text", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Monda", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Quattrocento Sans", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Hammersmith One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Libre Franklin", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Satisfy", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Pontano Sans", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Righteous", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Poiret One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "BenchNine", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "700" - ] - }, - { - "family": "Arapey", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Kaushan Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Economica", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Kanit", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Old Standard TT", - "category": "serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Sanchez", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Courgette", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Quattrocento", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Domine", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Gudea", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Permanent Marker", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Armata", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Cantarell", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Archivo Black", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Istok Web", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Cardo", - "category": "serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Playfair Display SC", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Passion One", - "category": "display", - "variants": [ - "regular", - "700", - "900" - ] - }, - { - "family": "Tinos", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Cookie", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Cormorant Garamond", - "category": "serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Philosopher", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Yantramanav", - "category": "sans-serif", - "variants": [ - "100", - "300", - "regular", - "500", - "700", - "900" - ] - }, - { - "family": "Chewy", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Antic Slab", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Handlee", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Teko", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Boogaloo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Vidaloka", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Audiowide", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Coming Soon", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Alfa Slab One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Cabin Condensed", - "category": "sans-serif", - "variants": [ - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Ruda", - "category": "sans-serif", - "variants": [ - "regular", - "700", - "900" - ] - }, - { - "family": "Ek Mukta", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Changa One", - "category": "display", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Tangerine", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Great Vibes", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Sintony", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Khand", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Bevan", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kalam", - "category": "handwriting", - "variants": [ - "300", - "regular", - "700" - ] - }, - { - "family": "Days One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Bangers", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rajdhani", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Droid Sans Mono", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Kreon", - "category": "serif", - "variants": [ - "300", - "regular", - "700" - ] - }, - { - "family": "Rambla", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Shrikhand", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fredoka One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Shadows Into Light Two", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Playball", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Neuton", - "category": "serif", - "variants": [ - "200", - "300", - "regular", - "italic", - "700", - "800" - ] - }, - { - "family": "Copse", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Didact Gothic", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Signika Negative", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "600", - "700" - ] - }, - { - "family": "Amiri", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Gentium Book Basic", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Glegoo", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Oleo Script", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Voltaire", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Actor", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Amaranth", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Paytone One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Volkhov", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Sorts Mill Goudy", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Bad Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Coda", - "category": "display", - "variants": [ - "regular", - "800" - ] - }, - { - "family": "Damion", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Sacramento", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Squada One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rock Salt", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Adamina", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Alice", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Cantata One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Luckiest Guy", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rochester", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Covered By Your Grace", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Heebo", - "category": "sans-serif", - "variants": [ - "100", - "300", - "regular", - "500", - "700", - "800", - "900" - ] - }, - { - "family": "VT323", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Nothing You Could Do", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Patrick Hand", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Gentium Basic", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Nobile", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Rancho", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Marck Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Special Elite", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Julius Sans One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Varela", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "PT Mono", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Alex Brush", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Homemade Apple", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Scada", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Jura", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600" - ] - }, - { - "family": "Antic", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Gochi Hand", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Sarala", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Electrolize", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sigmar One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Candal", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Prata", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Homenaje", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Pinyon Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Unica One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Basic", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Neucha", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Convergence", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Molengo", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Caveat Brush", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Monoton", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Calligraffitti", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Kameron", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Share", - "category": "display", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Alegreya Sans SC", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Enriqueta", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Martel", - "category": "serif", - "variants": [ - "200", - "300", - "regular", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Black Ops One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Just Another Hand", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Caveat", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "PT Serif Caption", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Ultra", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Ubuntu Mono", - "category": "monospace", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Carme", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Cousine", - "category": "monospace", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Cherry Cream Soda", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Reenie Beanie", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Hind Siliguri", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Bubblegum Sans", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Aldrich", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Lustria", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Alef", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Freckle Face", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fanwood Text", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Advent Pro", - "category": "sans-serif", - "variants": [ - "100", - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Allura", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Ceviche One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Press Start 2P", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Overlock", - "category": "display", - "variants": [ - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Niconne", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Limelight", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Frank Ruhl Libre", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "700", - "900" - ] - }, - { - "family": "Allerta Stencil", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Marcellus", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Pragati Narrow", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Michroma", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Fauna One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Syncopate", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Telex", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Marvel", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Cabin Sketch", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Hanuman", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Cairo", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "600", - "700", - "900" - ] - }, - { - "family": "Chivo", - "category": "sans-serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Allerta", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Fugaz One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Viga", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Ruslan Display", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nixie One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Marmelad", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Average", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Spinnaker", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Leckerli One", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Judson", - "category": "serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Lusitana", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Montserrat Alternates", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Contrail One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Oranienbaum", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Hind Vadodara", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Rufina", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Quantico", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Concert One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Marcellus SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Jockey One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Parisienne", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Carter One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Arbutus Slab", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Slabo 13px", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Tauri", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Goudy Bookletter 1911", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Carrois Gothic", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sue Ellen Francisco", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Walter Turncoat", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Annie Use Your Telescope", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Puritan", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Grand Hotel", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Yesteryear", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Jaldi", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Khula", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "600", - "700", - "800" - ] - }, - { - "family": "Cinzel Decorative", - "category": "display", - "variants": [ - "regular", - "700", - "900" - ] - }, - { - "family": "Crafty Girls", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Merienda", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Hind Guntur", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Cutive", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Prompt", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Coustard", - "category": "serif", - "variants": [ - "regular", - "900" - ] - }, - { - "family": "Arima Madurai", - "category": "display", - "variants": [ - "100", - "200", - "300", - "regular", - "500", - "700", - "800", - "900" - ] - }, - { - "family": "Doppio One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Radley", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Fontdiner Swanky", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Iceland", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Alegreya SC", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic", - "900", - "900italic" - ] - }, - { - "family": "Halant", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Schoolbell", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Waiting for the Sunrise", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Italianno", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Fredericka the Great", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Average Sans", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Rosario", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Mr Dafoe", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Port Lligat Slab", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Aclonica", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Graduate", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Racing Sans One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Berkshire Swash", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Forum", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Anonymous Pro", - "category": "monospace", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Love Ya Like A Sister", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nunito Sans", - "category": "sans-serif", - "variants": [ - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Magra", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Lateef", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Assistant", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "600", - "700", - "800" - ] - }, - { - "family": "Six Caps", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Gilda Display", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Oregano", - "category": "display", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Metrophobic", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Lalezar", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Caudex", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Kelly Slab", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Reem Kufi", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Cambay", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Gruppo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Give You Glory", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "GFS Didot", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Duru Sans", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Andika", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Tenor Sans", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Knewave", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Averia Serif Libre", - "category": "display", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Eczar", - "category": "serif", - "variants": [ - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Inder", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Martel Sans", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Trocchi", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Wire One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Petit Formal Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Mako", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Frijole", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Zeyada", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Slackey", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Karma", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Mate", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Belleza", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Montez", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Quando", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Capriola", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Lilita One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Trirong", - "category": "serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Lekton", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Just Me Again Down Here", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Bowlby One SC", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "The Girl Next Door", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Happy Monkey", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Merienda One", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Alike", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Chelsea Market", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Unkempt", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Anaheim", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Strait", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Brawler", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Clicker Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Delius", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Mouse Memoirs", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "IM Fell Double Pica", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Crushed", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rammetto One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Prosto One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kranky", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "IM Fell English", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Aladin", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Mr De Haviland", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "NTR", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Londrina Solid", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Skranji", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Allan", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Baumans", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ovo", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Changa", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Lemon", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Federo", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Herr Von Muellerhoff", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Arizonia", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Bowlby One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Orienta", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Short Stack", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Bungee Inline", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Andada", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Baloo Paaji", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Oxygen Mono", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Yeseva One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "UnifrakturMaguntia", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Bentham", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Londrina Outline", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Pompiere", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Gabriela", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Qwigley", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Square", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Poly", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Sniglet", - "category": "display", - "variants": [ - "regular", - "800" - ] - }, - { - "family": "Patrick Hand SC", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Gravitas One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Khmer", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Shojumaru", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kurale", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Gafata", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Biryani", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Cambo", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Titan One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Carrois Gothic SC", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "La Belle Aurore", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Holtwood One SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Oleo Script Swash Caps", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Headland One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Cherry Swash", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Belgrano", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Norican", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Mountains of Christmas", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Julee", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Ramabhadra", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Mallanna", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Kristi", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Imprima", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Lily Script One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Chau Philomene One", - "category": "sans-serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Bilbo Swash Caps", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Finger Paint", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Voces", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Itim", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Megrim", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Simonetta", - "category": "display", - "variants": [ - "regular", - "italic", - "900", - "900italic" - ] - }, - { - "family": "Cutive Mono", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Stardos Stencil", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "IM Fell DW Pica", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Unna", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Loved by the King", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Prociono", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Corben", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Amiko", - "category": "sans-serif", - "variants": [ - "regular", - "600", - "700" - ] - }, - { - "family": "Denk One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Palanquin", - "category": "sans-serif", - "variants": [ - "100", - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Baloo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fondamento", - "category": "handwriting", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Seaweed Script", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Shanti", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Wendy One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Raleway Dots", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Amethysta", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Vast Shadow", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Stalemate", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Fira Mono", - "category": "monospace", - "variants": [ - "regular", - "500", - "700" - ] - }, - { - "family": "Expletus Sans", - "category": "display", - "variants": [ - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Scheherazade", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Fenix", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Delius Swash Caps", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Rouge Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Life Savers", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "IM Fell English SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Meddon", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Tienne", - "category": "serif", - "variants": [ - "regular", - "700", - "900" - ] - }, - { - "family": "Over the Rainbow", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Share Tech Mono", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Abhaya Libre", - "category": "serif", - "variants": [ - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Kotta One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Pridi", - "category": "serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Euphoria Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Engagement", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Podkova", - "category": "serif", - "variants": [ - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Salsa", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Sofia", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Suranna", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Mada", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "900" - ] - }, - { - "family": "Chonburi", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ledger", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Italiana", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Dawning of a New Day", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Nokora", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Angkor", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Medula One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Taviraj", - "category": "serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Vampiro One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Englebert", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Mono", - "category": "monospace", - "variants": [ - "regular" - ] - }, - { - "family": "Dorsa", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Averia Sans Libre", - "category": "display", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Cedarville Cursive", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Geo", - "category": "sans-serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Rationale", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Balthazar", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sunshiney", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Aguafina Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Mystery Quest", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fjord One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Fira Sans Extra Condensed", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Kadwa", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "McLaren", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rye", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Sail", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Athiti", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Rosarivo", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Kite One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Odor Mean Chey", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Numans", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Artifika", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Poller One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Gurajada", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Inika", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Mandali", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Bungee Shade", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Suwannaphum", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Mate SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Creepster", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Arsenal", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Montserrat Subrayada", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Metamorphous", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Palanquin Dark", - "category": "sans-serif", - "variants": [ - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Coda Caption", - "category": "sans-serif", - "variants": [ - "800" - ] - }, - { - "family": "Dynalight", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Maitree", - "category": "serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "IM Fell French Canon", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Amarante", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Quintessential", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Codystar", - "category": "display", - "variants": [ - "300", - "regular" - ] - }, - { - "family": "Cantora One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Aref Ruqaa", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Griffy", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Revalia", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Buenard", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Donegal One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "IM Fell DW Pica SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Habibi", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Share Tech", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Flamenco", - "category": "display", - "variants": [ - "300", - "regular" - ] - }, - { - "family": "Mitr", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Maiden Orange", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Diplomata SC", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Cormorant", - "category": "serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Delius Unicase", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Stoke", - "category": "serif", - "variants": [ - "300", - "regular" - ] - }, - { - "family": "Vibur", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Sarpanch", - "category": "sans-serif", - "variants": [ - "regular", - "500", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Baloo Bhaina", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Baloo Tamma", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Averia Libre", - "category": "display", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Esteban", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Battambang", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Bokor", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Wallpoet", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "IM Fell Great Primer", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Tulpen One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Proza Libre", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic" - ] - }, - { - "family": "IM Fell French Canon SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Vesper Libre", - "category": "serif", - "variants": [ - "regular", - "500", - "700", - "900" - ] - }, - { - "family": "Rozha One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sansita", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Kavoon", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Della Respira", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Milonga", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Condiment", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Junge", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "New Rocker", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Chicle", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Mrs Saint Delafield", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "League Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Miniver", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Galindo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Moul", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Amatica SC", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Stint Ultra Expanded", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Yrsa", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Stint Ultra Condensed", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Suez One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Text Me One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Buda", - "category": "display", - "variants": [ - "300" - ] - }, - { - "family": "Ruluko", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sonsie One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Krona One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Elsie", - "category": "display", - "variants": [ - "regular", - "900" - ] - }, - { - "family": "Pangolin", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Linden Hill", - "category": "serif", - "variants": [ - "regular", - "italic" - ] - }, - { - "family": "Secular One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "IM Fell Double Pica SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Alike Angular", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sancreek", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Bilbo", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Antic Didone", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Paprika", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Asul", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "David Libre", - "category": "serif", - "variants": [ - "regular", - "500", - "700" - ] - }, - { - "family": "Almendra", - "category": "serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Sriracha", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Miriam Libre", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Ribeye", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Swanky and Moo Moo", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Trade Winds", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Overlock SC", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Round", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Cagliostro", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Glass Antiqua", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Offside", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "El Messiri", - "category": "sans-serif", - "variants": [ - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Bigshot One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "IM Fell Great Primer SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Akronim", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fira Sans Condensed", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Nosifer", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Autour One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Pirata One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Port Lligat Sans", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Scope One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sumana", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Lemonada", - "category": "display", - "variants": [ - "300", - "regular", - "600", - "700" - ] - }, - { - "family": "Montaga", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Iceberg", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ruthie", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Content", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Henny Penny", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Slim", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Hind Madurai", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Harmattan", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "UnifrakturCook", - "category": "display", - "variants": [ - "700" - ] - }, - { - "family": "Sarina", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Bubbler One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Dekko", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Redressed", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Laila", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Faster One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Arya", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Peralta", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Meie Script", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Overpass", - "category": "sans-serif", - "variants": [ - "100", - "100italic", - "200", - "200italic", - "300", - "300italic", - "regular", - "italic", - "600", - "600italic", - "700", - "700italic", - "800", - "800italic", - "900", - "900italic" - ] - }, - { - "family": "Monsieur La Doulaise", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Bungee", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Snippet", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Emilys Candy", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Trykker", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "MedievalSharp", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Space Mono", - "category": "monospace", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Croissant One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Monofett", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Lovers Quarrel", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Oldenburg", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Galdeano", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Spicy Rice", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Wellfleet", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Germania One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "GFS Neohellenic", - "category": "sans-serif", - "variants": [ - "regular", - "italic", - "700", - "700italic" - ] - }, - { - "family": "Baloo Thambi", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Jolly Lodger", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rubik Mono One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Pattaya", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Joti One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Siemreap", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ranga", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Chango", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Miltonian Tattoo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Koulen", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Eagle Lake", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Flat", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Petrona", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Jacques Francois", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Amita", - "category": "handwriting", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Plaster", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ramaraja", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Sura", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Kenia", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fresca", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Jomhuria", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Lancelot", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Pavanam", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Rum Raisin", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Almendra SC", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Purple Purse", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kumar One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Modern Antiqua", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Piedra", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Irish Grover", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Molle", - "category": "handwriting", - "variants": [ - "italic" - ] - }, - { - "family": "Cormorant Infant", - "category": "serif", - "variants": [ - "300", - "300italic", - "regular", - "italic", - "500", - "500italic", - "600", - "600italic", - "700", - "700italic" - ] - }, - { - "family": "Margarine", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Sahitya", - "category": "serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Mukta Vaani", - "category": "sans-serif", - "variants": [ - "200", - "300", - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Astloch", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Snowburst One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rhodium Libre", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Smythe", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Asset", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ewert", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Keania One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ranchers", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Gorditas", - "category": "display", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Sirin Stencil", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Averia Gruesa Libre", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Trochut", - "category": "display", - "variants": [ - "regular", - "italic", - "700" - ] - }, - { - "family": "Baloo Chettan", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kdam Thmor", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Timmana", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Original Surfer", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Supermercado One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Mirza", - "category": "display", - "variants": [ - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Passero One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Oval", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Caesar Dressing", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Taprom", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fascinate", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Seymour One", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Freehand", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ravi Prakash", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Coiny", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Atomic Age", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Jacques Francois Shadow", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Diplomata", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Dr Sugiyama", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Miltonian", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ribeye Marrow", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Elsie Swash Caps", - "category": "display", - "variants": [ - "regular", - "900" - ] - }, - { - "family": "Felipa", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Galada", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Script", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Bayon", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Underdog", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Devonshire", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Atma", - "category": "display", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Londrina Shadow", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Sofadi One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Tillana", - "category": "handwriting", - "variants": [ - "regular", - "500", - "600", - "700", - "800" - ] - }, - { - "family": "Inknut Antiqua", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700", - "800", - "900" - ] - }, - { - "family": "Goblin One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rakkas", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Metal", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Farsan", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Londrina Sketch", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Nova Cut", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "BioRhyme", - "category": "serif", - "variants": [ - "200", - "300", - "regular", - "700", - "800" - ] - }, - { - "family": "Warnes", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Romanesco", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Fascinate Inline", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Mrs Sheppards", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Princess Sofia", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Modak", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Spirax", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Cormorant Upright", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Geostar Fill", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Cormorant SC", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Baloo Bhai", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Sree Krushnadevaraya", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Smokum", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Arbutus", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fruktur", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Geostar", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Marko One", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Erica One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Yatra One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Uncial Antiqua", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Combo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Gidugu", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Aubrey", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Jim Nightshade", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Butterfly Kids", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Metal Mania", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Macondo", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Chenla", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Miss Fajardose", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Macondo Swash Caps", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Barrio", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Sevillana", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Bigelow Rules", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Rasa", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Risque", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Federant", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Dangrek", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Chathura", - "category": "sans-serif", - "variants": [ - "100", - "300", - "regular", - "700", - "800" - ] - }, - { - "family": "Almendra Display", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Chela One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Bonbon", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Stalinist One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Mr Bedfort", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Eater", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Fasthand", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Mogra", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Padauk", - "category": "sans-serif", - "variants": [ - "regular", - "700" - ] - }, - { - "family": "Preahvihear", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Flavors", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Ruge Boogie", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Tenali Ramakrishna", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Unlock", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Butcherman", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Baloo Da", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Lakki Reddy", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Cormorant Unicase", - "category": "serif", - "variants": [ - "300", - "regular", - "500", - "600", - "700" - ] - }, - { - "family": "Katibeh", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Asar", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Emblema One", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Moulpali", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Meera Inimai", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Kantumruy", - "category": "sans-serif", - "variants": [ - "300", - "regular", - "700" - ] - }, - { - "family": "Suravaram", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Bungee Hairline", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Overpass Mono", - "category": "monospace", - "variants": [ - "300", - "regular", - "600", - "700" - ] - }, - { - "family": "Peddana", - "category": "serif", - "variants": [ - "regular" - ] - }, - { - "family": "Bahiana", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kumar One Outline", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Hanalei Fill", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Dhurjati", - "category": "sans-serif", - "variants": [ - "regular" - ] - }, - { - "family": "Hanalei", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "Kavivanar", - "category": "handwriting", - "variants": [ - "regular" - ] - }, - { - "family": "Bungee Outline", - "category": "display", - "variants": [ - "regular" - ] - }, - { - "family": "BioRhyme Expanded", - "category": "serif", - "variants": [ - "200", - "300", - "regular", - "700", - "800" - ] - } -] diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/js/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/js/customizer.js deleted file mode 100644 index f214b655..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/js/customizer.js +++ /dev/null @@ -1,250 +0,0 @@ -function gp_premium_typography_live_update( id, selector, property, unit, media, settings ) { - settings = typeof settings !== 'undefined' ? settings : 'generate_settings'; - wp.customize( settings + '[' + id + ']', function( value ) { - value.bind( function( newval ) { - // Get our unit if applicable - unit = typeof unit !== 'undefined' ? unit : ''; - - var isTablet = ( 'tablet' == id.substring( 0, 6 ) ) ? true : false, - isMobile = ( 'mobile' == id.substring( 0, 6 ) ) ? true : false; - - if ( isTablet ) { - if ( '' == wp.customize(settings + '[' + id + ']').get() ) { - var desktopID = id.replace( 'tablet_', '' ); - newval = wp.customize(settings + '[' + desktopID + ']').get(); - } - } - - if ( isMobile ) { - if ( '' == wp.customize(settings + '[' + id + ']').get() ) { - var desktopID = id.replace( 'mobile_', '' ); - newval = wp.customize(settings + '[' + desktopID + ']').get(); - } - } - - if ( 'buttons_font_size' == id && '' == wp.customize('generate_settings[buttons_font_size]').get() ) { - newval = wp.customize('generate_settings[body_font_size]').get(); - } - - if ( 'single_post_title_weight' == id && '' == wp.customize('generate_settings[single_post_title_weight]').get() ) { - newval = wp.customize('generate_settings[heading_1_weight]').get(); - } - - if ( 'single_post_title_transform' == id && '' == wp.customize('generate_settings[single_post_title_transform]').get() ) { - newval = wp.customize('generate_settings[heading_1_transform]').get(); - } - - if ( 'archive_post_title_weight' == id && '' == wp.customize('generate_settings[archive_post_title_weight]').get() ) { - newval = wp.customize('generate_settings[heading_2_weight]').get(); - } - - if ( 'archive_post_title_transform' == id && '' == wp.customize('generate_settings[archive_post_title_transform]').get() ) { - newval = wp.customize('generate_settings[heading_2_transform]').get(); - } - - // We're using a desktop value - if ( ! isTablet && ! isMobile ) { - - var tabletValue = ( typeof wp.customize(settings + '[tablet_' + id + ']') !== 'undefined' ) ? wp.customize(settings + '[tablet_' + id + ']').get() : '', - mobileValue = ( typeof wp.customize(settings + '[mobile_' + id + ']') !== 'undefined' ) ? wp.customize(settings + '[mobile_' + id + ']').get() : ''; - - // The tablet setting exists, mobile doesn't - if ( '' !== tabletValue && '' == mobileValue ) { - media = gp_typography.desktop + ', ' + gp_typography.mobile; - } - - // The tablet setting doesn't exist, mobile does - if ( '' == tabletValue && '' !== mobileValue ) { - media = gp_typography.desktop + ', ' + gp_typography.tablet; - } - - // The tablet setting doesn't exist, neither does mobile - if ( '' == tabletValue && '' == mobileValue ) { - media = gp_typography.desktop + ', ' + gp_typography.tablet + ', ' + gp_typography.mobile; - } - - } - - // Check if media query - media_query = typeof media !== 'undefined' ? 'media="' + media + '"' : ''; - - jQuery( 'head' ).append( '' ); - setTimeout(function() { - jQuery( 'style#' + id ).not( ':last' ).remove(); - }, 1000); - - setTimeout("jQuery('body').trigger('generate_spacing_updated');", 1000); - } ); - } ); -} - -/** - * Body font size, weight and transform - */ -gp_premium_typography_live_update( 'body_font_size', 'body, button, input, select, textarea', 'font-size', 'px' ); -gp_premium_typography_live_update( 'body_line_height', 'body', 'line-height', '' ); -gp_premium_typography_live_update( 'paragraph_margin', 'p, .entry-content > [class*="wp-block-"]:not(:last-child)', 'margin-bottom', 'em' ); -gp_premium_typography_live_update( 'body_font_weight', 'body, button, input, select, textarea', 'font-weight' ); -gp_premium_typography_live_update( 'body_font_transform', 'body, button, input, select, textarea', 'text-transform' ); - -/** - * Top bar font size, weight and transform - */ -gp_premium_typography_live_update( 'top_bar_font_size', '.top-bar', 'font-size', 'px' ); -gp_premium_typography_live_update( 'top_bar_font_weight', '.top-bar', 'font-weight' ); -gp_premium_typography_live_update( 'top_bar_font_transform', '.top-bar', 'text-transform' ); - -/** - * Site title font size, weight and transform - */ -gp_premium_typography_live_update( 'site_title_font_size', '.main-title, .navigation-branding .main-title', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'tablet_site_title_font_size', '.main-title, .navigation-branding .main-title', 'font-size', 'px', gp_typography.tablet ); -gp_premium_typography_live_update( 'mobile_site_title_font_size', '.main-title, .navigation-branding .main-title', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'site_title_font_weight', '.main-title, .navigation-branding .main-title', 'font-weight' ); -gp_premium_typography_live_update( 'site_title_font_transform', '.main-title, .navigation-branding .main-title', 'text-transform' ); - -/** - * Site description font size, weight and transform - */ -gp_premium_typography_live_update( 'site_tagline_font_size', '.site-description', 'font-size', 'px' ); -gp_premium_typography_live_update( 'site_tagline_font_weight', '.site-description', 'font-weight' ); -gp_premium_typography_live_update( 'site_tagline_font_transform', '.site-description', 'text-transform' ); - -/** - * Main navigation font size, weight and transform - */ -gp_premium_typography_live_update( 'navigation_font_size', '.main-navigation a, .menu-toggle, .main-navigation .menu-bar-items', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'tablet_navigation_font_size', '.main-navigation a, .menu-toggle, .main-navigation .menu-bar-items', 'font-size', 'px', gp_typography.tablet ); -gp_premium_typography_live_update( 'mobile_navigation_font_size', '.main-navigation:not(.slideout-navigation) a, .menu-toggle, .main-navigation .menu-bar-items', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'navigation_font_weight', '.main-navigation a, .menu-toggle', 'font-weight' ); -gp_premium_typography_live_update( 'navigation_font_transform', '.main-navigation a, .menu-toggle', 'text-transform' ); - -/** - * Site title when in navigation. - */ - gp_premium_typography_live_update( 'navigation_site_title_font_size', '.navigation-branding .main-title', 'font-size', 'px', gp_typography.desktop ); - gp_premium_typography_live_update( 'tablet_navigation_site_title_font_size', '.navigation-branding .main-title', 'font-size', 'px', gp_typography.tablet ); - gp_premium_typography_live_update( 'mobile_navigation_site_title_font_size', '.navigation-branding .main-title', 'font-size', 'px', gp_typography.mobile ); - -/** - * Secondary navigation font size, weight and transform - */ -gp_premium_typography_live_update( 'secondary_navigation_font_size', '.secondary-navigation .main-nav ul li a,.secondary-navigation .menu-toggle, .secondary-navigation .top-bar, .secondary-navigation .secondary-menu-bar-items', 'font-size', 'px', '', 'generate_secondary_nav_settings' ); -gp_premium_typography_live_update( 'secondary_navigation_font_weight', '.secondary-navigation .main-nav ul li a,.secondary-navigation .menu-toggle, .secondary-navigation .top-bar', 'font-weight', '', '', 'generate_secondary_nav_settings' ); -gp_premium_typography_live_update( 'secondary_navigation_font_transform', '.secondary-navigation .main-nav ul li a,.secondary-navigation .menu-toggle, .secondary-navigation .top-bar', 'text-transform', '', '', 'generate_secondary_nav_settings' ); - -/** - * Buttons - */ -gp_premium_typography_live_update( 'buttons_font_size', 'button:not(.menu-toggle),html input[type="button"],input[type="reset"],input[type="submit"],.button,.button:visited,.wp-block-button .wp-block-button__link,.woocommerce #respond input#submit, .woocommerce a.button, .woocommerce button.button, .woocommerce input.button', 'font-size', 'px' ); -gp_premium_typography_live_update( 'buttons_font_weight', 'button:not(.menu-toggle),html input[type="button"],input[type="reset"],input[type="submit"],.button,.button:visited,.wp-block-button .wp-block-button__link,.woocommerce #respond input#submit, .woocommerce a.button, .woocommerce button.button, .woocommerce input.button', 'font-weight' ); -gp_premium_typography_live_update( 'buttons_font_transform', 'button:not(.menu-toggle),html input[type="button"],input[type="reset"],input[type="submit"],.button,.button:visited,.wp-block-button .wp-block-button__link,.woocommerce #respond input#submit, .woocommerce a.button, .woocommerce button.button, .woocommerce input.button', 'text-transform' ); - -/** - * H1 font size, weight and transform - */ -gp_premium_typography_live_update( 'heading_1_font_size', 'h1', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'mobile_heading_1_font_size', 'h1', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'heading_1_weight', 'h1', 'font-weight' ); -gp_premium_typography_live_update( 'heading_1_transform', 'h1', 'text-transform' ); -gp_premium_typography_live_update( 'heading_1_line_height', 'h1', 'line-height', 'em' ); -gp_premium_typography_live_update( 'heading_1_margin_bottom', 'h1', 'margin-bottom', 'px' ); - -/** - * Single content title (h1) - */ -gp_premium_typography_live_update( 'single_post_title_font_size', 'h1.entry-title', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'single_post_title_font_size_mobile', 'h1.entry-title', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'single_post_title_weight', 'h1.entry-title', 'font-weight' ); -gp_premium_typography_live_update( 'single_post_title_transform', 'h1.entry-title', 'text-transform' ); -gp_premium_typography_live_update( 'single_post_title_line_height', 'h1.entry-title', 'line-height', 'em' ); - -/** - * H2 font size, weight and transform - */ -gp_premium_typography_live_update( 'heading_2_font_size', 'h2', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'mobile_heading_2_font_size', 'h2', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'heading_2_weight', 'h2', 'font-weight' ); -gp_premium_typography_live_update( 'heading_2_transform', 'h2', 'text-transform' ); -gp_premium_typography_live_update( 'heading_2_line_height', 'h2', 'line-height', 'em' ); -gp_premium_typography_live_update( 'heading_2_margin_bottom', 'h2', 'margin-bottom', 'px' ); - -/** - * Archive post title (h1) - */ -gp_premium_typography_live_update( 'archive_post_title_font_size', 'h2.entry-title', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'archive_post_title_font_size_mobile', 'h2.entry-title', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'archive_post_title_weight', 'h2.entry-title', 'font-weight' ); -gp_premium_typography_live_update( 'archive_post_title_transform', 'h2.entry-title', 'text-transform' ); -gp_premium_typography_live_update( 'archive_post_title_line_height', 'h2.entry-title', 'line-height', 'em' ); - -/** - * H3 font size, weight and transform - */ -gp_premium_typography_live_update( 'heading_3_font_size', 'h3', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'mobile_heading_3_font_size', 'h3', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'heading_3_weight', 'h3', 'font-weight' ); -gp_premium_typography_live_update( 'heading_3_transform', 'h3', 'text-transform' ); -gp_premium_typography_live_update( 'heading_3_line_height', 'h3', 'line-height', 'em' ); -gp_premium_typography_live_update( 'heading_3_margin_bottom', 'h3', 'margin-bottom', 'px' ); - -/** - * H4 font size, weight and transform - */ -gp_premium_typography_live_update( 'heading_4_font_size', 'h4', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'mobile_heading_4_font_size', 'h4', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'heading_4_weight', 'h4', 'font-weight' ); -gp_premium_typography_live_update( 'heading_4_transform', 'h4', 'text-transform' ); -gp_premium_typography_live_update( 'heading_4_line_height', 'h4', 'line-height', 'em' ); - -/** - * H5 font size, weight and transform - */ -gp_premium_typography_live_update( 'heading_5_font_size', 'h5', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'mobile_heading_5_font_size', 'h5', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'heading_5_weight', 'h5', 'font-weight' ); -gp_premium_typography_live_update( 'heading_5_transform', 'h5', 'text-transform' ); -gp_premium_typography_live_update( 'heading_5_line_height', 'h5', 'line-height', 'em' ); - -/** - * H6 font size, weight and transform - */ -gp_premium_typography_live_update( 'heading_6_font_size', 'h6', 'font-size', 'px' ); -gp_premium_typography_live_update( 'heading_6_weight', 'h6', 'font-weight' ); -gp_premium_typography_live_update( 'heading_6_transform', 'h6', 'text-transform' ); -gp_premium_typography_live_update( 'heading_6_line_height', 'h6', 'line-height', 'em' ); - -/** - * Widget title font size, weight and transform - */ -gp_premium_typography_live_update( 'widget_title_font_size', '.widget-title', 'font-size', 'px' ); -gp_premium_typography_live_update( 'widget_title_font_weight', '.widget-title', 'font-weight' ); -gp_premium_typography_live_update( 'widget_title_font_transform', '.widget-title', 'text-transform' ); -gp_premium_typography_live_update( 'widget_title_separator', '.widget-title', 'margin-bottom', 'px' ); -gp_premium_typography_live_update( 'widget_content_font_size', '.sidebar .widget, .footer-widgets .widget', 'font-size', 'px' ); - -/** - * Footer font size, weight and transform - */ -gp_premium_typography_live_update( 'footer_font_size', '.site-info', 'font-size', 'px' ); -gp_premium_typography_live_update( 'footer_weight', '.site-info', 'font-weight' ); -gp_premium_typography_live_update( 'footer_transform', '.site-info', 'text-transform' ); -gp_premium_typography_live_update( 'footer_line_height', '.site-info', 'line-height', 'em' ); - -/** - * WooCommerce product title - */ -gp_premium_typography_live_update( 'wc_product_title_font_size', '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'mobile_wc_product_title_font_size', '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'wc_product_title_font_weight', '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title', 'font-weight' ); -gp_premium_typography_live_update( 'wc_product_title_font_transform', '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title', 'text-transform' ); - -gp_premium_typography_live_update( 'wc_related_product_title_font_size', '.woocommerce .up-sells ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce .cross-sells ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce .related ul.products li.product .woocommerce-LoopProduct-link h2', 'font-size', 'px' ); - -/** - * Slideout navigation font size, weight and transform - */ -gp_premium_typography_live_update( 'slideout_font_size', '.slideout-navigation.main-navigation .main-nav ul li a', 'font-size', 'px', gp_typography.desktop ); -gp_premium_typography_live_update( 'slideout_mobile_font_size', '.slideout-navigation.main-navigation .main-nav ul li a', 'font-size', 'px', gp_typography.mobile ); -gp_premium_typography_live_update( 'slideout_font_weight', '.slideout-navigation.main-navigation .main-nav ul li a', 'font-weight' ); -gp_premium_typography_live_update( 'slideout_font_transform', '.slideout-navigation.main-navigation .main-nav ul li a', 'text-transform' ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/migration.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/migration.php deleted file mode 100644 index c2ea0e08..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/migration.php +++ /dev/null @@ -1,359 +0,0 @@ - $generate_settings[ $setting ], - 'variants' => $variants, - 'category' => $category ? $category : 'sans-serif', - ); - } - - if ( function_exists( 'generate_secondary_nav_get_defaults' ) ) { - $secondary_nav_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - - $secondary_nav_id = strtolower( str_replace( ' ', '_', $secondary_nav_settings[ 'font_secondary_navigation' ] ) ); - - if ( ! array_key_exists( $secondary_nav_id, $select_fonts ) && ! in_array( $secondary_nav_settings[ 'font_secondary_navigation' ], generate_typography_default_fonts() ) ) { - $variants = get_theme_mod( 'font_secondary_navigation_variants', array() ); - $category = get_theme_mod( 'font_secondary_navigation_category' ); - - if ( ! empty( $variants ) && ! is_array( $variants ) ) { - $variants = explode( ',', $variants ); - } - - if ( ! $variants ) { - if ( ! $all_fonts ) { - $all_fonts = generate_get_all_google_fonts(); - } - - if ( array_key_exists( $secondary_nav_id, $all_fonts ) ) { - $variants = $all_fonts[ $secondary_nav_id ]['variants']; - } - } - - if ( ! $category ) { - if ( ! $all_fonts ) { - $all_fonts = generate_get_all_google_fonts(); - } - - if ( array_key_exists( $secondary_nav_id, $all_fonts ) ) { - $category = $all_fonts[ $secondary_nav_id ]['category']; - } - } - - $fonts[ $secondary_nav_id ] = array( - 'name' => $secondary_nav_settings[ 'font_secondary_navigation' ], - 'variants' => $variants, - 'category' => $category ? $category : 'sans-serif', - ); - } - } - - return $fonts; - } -} - -if ( ! function_exists( 'generate_typography_set_font_data' ) ) { - add_action( 'admin_init', 'generate_typography_set_font_data' ); - /** - * This function will check to see if your category and variants are saved - * If not, it will set them for you, and won't run again - * - * @since 1.2.90 - */ - function generate_typography_set_font_data() { - // Bail if we don't have our defaults - if ( ! function_exists( 'generate_get_default_fonts' ) ) { - return; - } - - // Get our defaults - $defaults = generate_get_default_fonts(); - - // Get our settings - $generate_settings = wp_parse_args( - get_option( 'generate_settings', array() ), - generate_get_default_fonts() - ); - - // We need to loop through these settings - $font_settings = array( - 'font_body', - 'font_site_title', - 'font_site_tagline', - 'font_navigation', - 'font_widget_title', - 'font_heading_1', - 'font_heading_2', - 'font_heading_3' - ); - - // Add secondary navigation to the array last if it exists - if ( function_exists( 'generate_secondary_nav_get_defaults' ) ) { - $font_settings[ 'font_secondary_navigation' ] = 'font_secondary_navigation'; - } - - // Start looping - foreach( $font_settings as $setting ) { - - // Change our variables for the secondary navigation - this will run last - if ( function_exists( 'generate_secondary_nav_get_defaults' ) && 'font_secondary_navigation' == $setting ) { - $generate_settings = wp_parse_args( - get_option( 'generate_secondary_nav_settings', array() ), - generate_secondary_nav_get_defaults() - ); - $defaults = generate_secondary_nav_get_defaults(); - } - - // We don't need to do this if we're using the default font, as these values have defaults already - if ( $defaults[ $setting ] == $generate_settings[ $setting ] ) { - continue; - } - - // Don't need to continue if we're using a system font or our default font - if ( in_array( $generate_settings[ $setting ], generate_typography_default_fonts() ) || 'Open Sans' == $generate_settings[ $setting ] ) { - continue; - } - - // Don't continue if our category and variants are already set - if ( get_theme_mod( $setting . '_category' ) && get_theme_mod( $setting . '_variants' ) ) { - continue; - } - - // Get all of our fonts - $fonts = generate_get_all_google_fonts(); - - // Get the ID from our font - $id = strtolower( str_replace( ' ', '_', $generate_settings[ $setting ] ) ); - - // If the ID doesn't exist within our fonts, we can bail - if ( ! array_key_exists( $id, $fonts ) ) { - continue; - } - - // Let's grab our category to go with our font - $category = ! empty( $fonts[$id]['category'] ) ? $fonts[$id]['category'] : ''; - - // Grab all of the variants associated with our font - $variants = $fonts[$id]['variants']; - - // Loop through our variants and put them into an array, then turn them into a comma separated list - $output = array(); - if ( $variants ) { - foreach ( $variants as $variant ) { - $output[] = $variant; - } - - $variants = implode( ',', $output ); - } - - // Set our theme mods with our new settings - if ( '' !== $category ) { - set_theme_mod( $setting . '_category', $category ); - } - - if ( '' !== $variants ) { - set_theme_mod( $setting . '_variants', $variants ); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/secondary-nav-fonts.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/secondary-nav-fonts.php deleted file mode 100644 index 76081000..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/secondary-nav-fonts.php +++ /dev/null @@ -1,176 +0,0 @@ -get_section( 'secondary_nav_section' ) ) { - return; - } - - // Get our controls - require_once GP_LIBRARY_DIRECTORY . 'customizer-helpers.php'; - - // Get our defaults - $defaults = generate_secondary_nav_get_defaults(); - - // Register our custom controls - if ( method_exists( $wp_customize,'register_control_type' ) ) { - $wp_customize->register_control_type( 'GeneratePress_Pro_Typography_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Pro_Range_Slider_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Add our section - $wp_customize->add_section( - 'secondary_font_section', - array( - 'title' => __( 'Secondary Navigation', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'description' => '', - 'priority' => 51, - 'panel' => 'generate_typography_panel' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_secondary_navigation_typography_shortcuts', - array( - 'section' => 'secondary_font_section', - 'element' => __( 'Secondary Navigation', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'secondary_nav_section', - 'colors' => 'secondary_navigation_color_section', - 'backgrounds' => 'secondary_bg_images_section', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - // Font family - $wp_customize->add_setting( - 'generate_secondary_nav_settings[font_secondary_navigation]', - array( - 'default' => $defaults['font_secondary_navigation'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_text_field' - ) - ); - - // Category - $wp_customize->add_setting( - 'font_secondary_navigation_category', - array( - 'default' => $defaults['font_secondary_navigation_category'], - 'sanitize_callback' => 'sanitize_text_field' - ) - ); - - // Variants - $wp_customize->add_setting( - 'font_secondary_navigation_variants', - array( - 'default' => $defaults['font_secondary_navigation_variants'], - 'sanitize_callback' => 'generate_premium_sanitize_variants' - ) - ); - - // Font weight - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_navigation_font_weight]', - array( - 'default' => $defaults['secondary_navigation_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage' - ) - ); - - // Font transform - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_navigation_font_transform]', - array( - 'default' => $defaults['secondary_navigation_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'google_font_site_secondary_navigation_control', - array( - 'section' => 'secondary_font_section', - 'settings' => array( - 'family' => 'generate_secondary_nav_settings[font_secondary_navigation]', - 'variant' => 'font_secondary_navigation_variants', - 'category' => 'font_secondary_navigation_category', - 'weight' => 'generate_secondary_nav_settings[secondary_navigation_font_weight]', - 'transform' => 'generate_secondary_nav_settings[secondary_navigation_font_transform]', - ), - ) - ) - ); - - // Font size - $wp_customize->add_setting( - 'generate_secondary_nav_settings[secondary_navigation_font_size]', - array( - 'default' => $defaults['secondary_navigation_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_secondary_nav_settings[secondary_navigation_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'secondary_font_section', - 'priority' => 165, - 'settings' => array( - 'desktop' => 'generate_secondary_nav_settings[secondary_navigation_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 6, - 'max' => 30, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/slideout-nav-fonts.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/slideout-nav-fonts.php deleted file mode 100644 index a6619549..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/slideout-nav-fonts.php +++ /dev/null @@ -1,149 +0,0 @@ -register_control_type( 'GeneratePress_Pro_Range_Slider_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Pro_Typography_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Bail if Menu Plus isn't activated - if ( ! $wp_customize->get_section( 'menu_plus_slideout_menu' ) ) { - return; - } - - $wp_customize->add_section( - 'generate_slideout_typography', - array( - 'title' => __( 'Off Canvas Panel', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 52, - 'panel' => 'generate_typography_panel' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_off_canvas_panel_typography_shortcuts', - array( - 'section' => 'generate_slideout_typography', - 'element' => esc_html__( 'Off Canvas Panel', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'slideout_color_section', - 'layout' => 'menu_plus_slideout_menu', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 1, - ) - ) - ); - - $wp_customize->add_setting( - 'generate_settings[slideout_font_weight]', - array( - 'default' => $defaults['slideout_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage' - ) - ); - - // Text transform - $wp_customize->add_setting( - 'generate_settings[slideout_font_transform]', - array( - 'default' => $defaults['slideout_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'slideout_navigation_typography', - array( - 'label' => esc_html__( 'Menu Items', 'gp-premium' ), - 'section' => 'generate_slideout_typography', - 'settings' => array( - 'weight' => 'generate_settings[slideout_font_weight]', - 'transform' => 'generate_settings[slideout_font_transform]', - ), - ) - ) - ); - - // Font size - $wp_customize->add_setting( - 'generate_settings[slideout_font_size]', - array( - 'default' => $defaults['slideout_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_setting( - 'generate_settings[slideout_mobile_font_size]', - array( - 'default' => $defaults['slideout_mobile_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[slideout_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'generate_slideout_typography', - 'settings' => array( - 'desktop' => 'generate_settings[slideout_font_size]', - 'mobile' => 'generate_settings[slideout_mobile_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/woocommerce-fonts.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/woocommerce-fonts.php deleted file mode 100644 index b1d0b3c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/functions/woocommerce-fonts.php +++ /dev/null @@ -1,179 +0,0 @@ -register_control_type( 'GeneratePress_Pro_Range_Slider_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Pro_Typography_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - // Bail if WooCommerce isn't activated - if ( ! $wp_customize->get_section( 'generate_woocommerce_typography' ) ) { - return; - } - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_woocommerce_typography_shortcuts', - array( - 'section' => 'generate_woocommerce_typography', - 'element' => __( 'WooCommerce', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_woocommerce_layout', - 'colors' => 'generate_woocommerce_colors', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - // WooCommerce - $wp_customize->add_setting( - 'generate_settings[wc_product_title_font_weight]', - array( - 'default' => $defaults['wc_product_title_font_weight'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage' - ) - ); - - // Text transform - $wp_customize->add_setting( - 'generate_settings[wc_product_title_font_transform]', - array( - 'default' => $defaults['wc_product_title_font_transform'], - 'type' => 'option', - 'sanitize_callback' => 'sanitize_key', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Typography_Customize_Control( - $wp_customize, - 'google_wc_product_title_control', - array( - 'label' => __( 'Shop Product Titles', 'gp-premium' ), - 'section' => 'generate_woocommerce_typography', - 'settings' => array( - 'weight' => 'generate_settings[wc_product_title_font_weight]', - 'transform' => 'generate_settings[wc_product_title_font_transform]', - ), - ) - ) - ); - - // Font size - $wp_customize->add_setting( - 'generate_settings[wc_product_title_font_size]', - array( - 'default' => $defaults['wc_product_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_setting( - 'generate_settings[mobile_wc_product_title_font_size]', - array( - 'default' => $defaults['mobile_wc_product_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[wc_product_title_font_size]', - array( - 'description' => __( 'Font size', 'gp-premium' ), - 'section' => 'generate_woocommerce_typography', - 'priority' => 240, - 'settings' => array( - 'desktop' => 'generate_settings[wc_product_title_font_size]', - 'mobile' => 'generate_settings[mobile_wc_product_title_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - // Font size - $wp_customize->add_setting( - 'generate_settings[wc_related_product_title_font_size]', - array( - 'default' => $defaults['wc_related_product_title_font_size'], - 'type' => 'option', - 'sanitize_callback' => 'absint', - 'transport' => 'postMessage' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'generate_settings[wc_related_product_title_font_size]', - array( - 'description' => __( 'Related/upsell title font size', 'gp-premium' ), - 'section' => 'generate_woocommerce_typography', - 'priority' => 240, - 'settings' => array( - 'desktop' => 'generate_settings[wc_related_product_title_font_size]', - 'mobile' => 'generate_settings[mobile_wc_product_title_font_size]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 80, - 'step' => 1, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/generate-fonts.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/generate-fonts.php deleted file mode 100644 index fd8a9939..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/typography/generate-fonts.php +++ /dev/null @@ -1,20 +0,0 @@ -add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_woocommerce_colors_shortcuts', - array( - 'section' => 'generate_woocommerce_colors', - 'element' => __( 'WooCommerce', 'gp-premium' ), - 'shortcuts' => array( - 'layout' => 'generate_woocommerce_layout', - 'typography' => 'generate_woocommerce_typography', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - $color_defaults = generate_get_color_defaults(); - - $wp_customize->add_section( - 'generate_woocommerce_colors', - array( - 'title' => __( 'Colors', 'gp-premium' ), - 'priority' => 40, - 'panel' => 'woocommerce', - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_button_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Buttons', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-button-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_alt_button_background', - 'generate_woocommerce_colors', - 'woocommerce-button-colors', - array( - 'generate_settings[wc_alt_button_background]' => array( - 'default_value' => $color_defaults['wc_alt_button_background'], - 'label' => __( 'Alt Button Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.woocommerce #respond input#submit.alt, .woocommerce a.button.alt, .woocommerce button.button.alt, .woocommerce input.button.alt, .woocommerce #respond input#submit.alt.disabled, .woocommerce #respond input#submit.alt.disabled:hover, .woocommerce #respond input#submit.alt:disabled, .woocommerce #respond input#submit.alt:disabled:hover, .woocommerce #respond input#submit.alt:disabled[disabled], .woocommerce #respond input#submit.alt:disabled[disabled]:hover, .woocommerce a.button.alt.disabled, .woocommerce a.button.alt.disabled:hover, .woocommerce a.button.alt:disabled, .woocommerce a.button.alt:disabled:hover, .woocommerce a.button.alt:disabled[disabled], .woocommerce a.button.alt:disabled[disabled]:hover, .woocommerce button.button.alt.disabled, .woocommerce button.button.alt.disabled:hover, .woocommerce button.button.alt:disabled, .woocommerce button.button.alt:disabled:hover, .woocommerce button.button.alt:disabled[disabled], .woocommerce button.button.alt:disabled[disabled]:hover, .woocommerce input.button.alt.disabled, .woocommerce input.button.alt.disabled:hover, .woocommerce input.button.alt:disabled, .woocommerce input.button.alt:disabled:hover, .woocommerce input.button.alt:disabled[disabled], .woocommerce input.button.alt:disabled[disabled]:hover', - 'property' => 'background-color', - 'hide_label' => false, - ), - 'generate_settings[wc_alt_button_background_hover]' => array( - 'default_value' => $color_defaults['wc_alt_button_background_hover'], - 'label' => __( 'Alt Button Background Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '.woocommerce #respond input#submit.alt:hover, .woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover, .woocommerce input.button.alt:hover', - 'property' => 'background-color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_alt_button_text', - 'generate_woocommerce_colors', - 'woocommerce-button-colors', - array( - 'generate_settings[wc_alt_button_text]' => array( - 'default_value' => $color_defaults['wc_alt_button_text'], - 'label' => __( 'Alt Button Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.woocommerce #respond input#submit.alt, .woocommerce a.button.alt, .woocommerce button.button.alt, .woocommerce input.button.alt, .woocommerce #respond input#submit.alt.disabled, .woocommerce #respond input#submit.alt.disabled:hover, .woocommerce #respond input#submit.alt:disabled, .woocommerce #respond input#submit.alt:disabled:hover, .woocommerce #respond input#submit.alt:disabled[disabled], .woocommerce #respond input#submit.alt:disabled[disabled]:hover, .woocommerce a.button.alt.disabled, .woocommerce a.button.alt.disabled:hover, .woocommerce a.button.alt:disabled, .woocommerce a.button.alt:disabled:hover, .woocommerce a.button.alt:disabled[disabled], .woocommerce a.button.alt:disabled[disabled]:hover, .woocommerce button.button.alt.disabled, .woocommerce button.button.alt.disabled:hover, .woocommerce button.button.alt:disabled, .woocommerce button.button.alt:disabled:hover, .woocommerce button.button.alt:disabled[disabled], .woocommerce button.button.alt:disabled[disabled]:hover, .woocommerce input.button.alt.disabled, .woocommerce input.button.alt.disabled:hover, .woocommerce input.button.alt:disabled, .woocommerce input.button.alt:disabled:hover, .woocommerce input.button.alt:disabled[disabled], .woocommerce input.button.alt:disabled[disabled]:hover', - 'property' => 'color', - 'hide_label' => false, - ), - 'generate_settings[wc_alt_button_text_hover]' => array( - 'default_value' => $color_defaults['wc_alt_button_text_hover'], - 'label' => __( 'Alt Button Text Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '.woocommerce #respond input#submit.alt:hover, .woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover, .woocommerce input.button.alt:hover', - 'property' => 'color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_product_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Products', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-product-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_product_title', - 'generate_woocommerce_colors', - 'woocommerce-product-colors', - array( - 'generate_settings[wc_product_title_color]' => array( - 'default_value' => $color_defaults['wc_product_title_color'], - 'label' => __( 'Product Title', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '.woocommerce ul.products li.product .woocommerce-LoopProduct-link', - 'property' => 'color', - 'hide_label' => false, - ), - 'generate_settings[wc_product_title_color_hover]' => array( - 'default_value' => $color_defaults['wc_product_title_color_hover'], - 'label' => __( 'Product Title Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '.woocommerce ul.products li.product .woocommerce-LoopProduct-link:hover', - 'property' => 'color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_rating_stars', - 'generate_woocommerce_colors', - 'woocommerce-product-colors', - array( - 'generate_settings[wc_rating_stars]' => array( - 'default_value' => $color_defaults['wc_rating_stars'], - 'label' => __( 'Star Ratings', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce .star-rating span:before, .woocommerce p.stars:hover a::before', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_sale_sticker_background', - 'generate_woocommerce_colors', - 'woocommerce-product-colors', - array( - 'generate_settings[wc_sale_sticker_background]' => array( - 'default_value' => $color_defaults['wc_sale_sticker_background'], - 'label' => __( 'Sale Sticker Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce span.onsale', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_sale_sticker_text', - 'generate_woocommerce_colors', - 'woocommerce-product-colors', - array( - 'generate_settings[wc_sale_sticker_text]' => array( - 'default_value' => $color_defaults['wc_sale_sticker_text'], - 'label' => __( 'Sale Sticker Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce span.onsale', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_price_text', - 'generate_woocommerce_colors', - 'woocommerce-product-colors', - array( - 'generate_settings[wc_price_color]' => array( - 'default_value' => $color_defaults['wc_price_color'], - 'label' => __( 'Price', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce ul.products li.product .price, .woocommerce div.product p.price', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_panel_cart_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Sticky Panel Cart', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-panel-cart-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_panel_cart_background', - 'generate_woocommerce_colors', - 'woocommerce-panel-cart-colors', - array( - 'generate_settings[wc_panel_cart_background_color]' => array( - 'default_value' => $color_defaults['wc_panel_cart_background_color'], - 'label' => __( 'Background Color', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.add-to-cart-panel', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_panel_cart_text', - 'generate_woocommerce_colors', - 'woocommerce-panel-cart-colors', - array( - 'generate_settings[wc_panel_cart_text_color]' => array( - 'default_value' => $color_defaults['wc_panel_cart_text_color'], - 'label' => __( 'Text Color', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.add-to-cart-panel, .add-to-cart-panel a:not(.button)', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_panel_cart_button_background', - 'generate_woocommerce_colors', - 'woocommerce-panel-cart-colors', - array( - 'generate_settings[wc_panel_cart_button_background]' => array( - 'default_value' => $color_defaults['wc_panel_cart_button_background'], - 'label' => __( 'Button Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '#wc-sticky-cart-panel .button', - 'property' => 'background-color', - 'hide_label' => false, - ), - 'generate_settings[wc_panel_cart_button_background_hover]' => array( - 'default_value' => $color_defaults['wc_panel_cart_button_background_hover'], - 'label' => __( 'Button Background Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '#wc-sticky-cart-panel .button:hover, #wc-sticky-cart-panel .button:focus, #wc-sticky-cart-panel .button:active', - 'property' => 'background-color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_panel_cart_button_text', - 'generate_woocommerce_colors', - 'woocommerce-panel-cart-colors', - array( - 'generate_settings[wc_panel_cart_button_text]' => array( - 'default_value' => $color_defaults['wc_panel_cart_button_text'], - 'label' => __( 'Button Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '#wc-sticky-cart-panel .button', - 'property' => 'color', - 'hide_label' => false, - ), - 'generate_settings[wc_panel_cart_button_text_hover]' => array( - 'default_value' => $color_defaults['wc_panel_cart_button_text_hover'], - 'label' => __( 'Button Text Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '#wc-sticky-cart-panel .button:hover, #wc-sticky-cart-panel .button:focus, #wc-sticky-cart-panel .button:active', - 'property' => 'color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_mini_cart_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Menu Mini Cart', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-mini-cart-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_mini_cart_background', - 'generate_woocommerce_colors', - 'woocommerce-mini-cart-colors', - array( - 'generate_settings[wc_mini_cart_background_color]' => array( - 'default_value' => $color_defaults['wc_mini_cart_background_color'], - 'label' => __( 'Background Color', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '#wc-mini-cart', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_mini_cart_text', - 'generate_woocommerce_colors', - 'woocommerce-mini-cart-colors', - array( - 'generate_settings[wc_mini_cart_text_color]' => array( - 'default_value' => $color_defaults['wc_mini_cart_text_color'], - 'label' => __( 'Text Color', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '#wc-mini-cart', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_mini_cart_button_background', - 'generate_woocommerce_colors', - 'woocommerce-mini-cart-colors', - array( - 'generate_settings[wc_mini_cart_button_background]' => array( - 'default_value' => $color_defaults['wc_mini_cart_button_background'], - 'label' => __( 'Button Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '#wc-mini-cart .button', - 'property' => 'background-color', - 'hide_label' => false, - ), - 'generate_settings[wc_mini_cart_button_background_hover]' => array( - 'default_value' => $color_defaults['wc_mini_cart_button_background_hover'], - 'label' => __( 'Button Background Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '#wc-mini-cart .button:hover, #wc-mini-cart .button:focus, #wc-mini-cart .button:active', - 'property' => 'background-color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_mini_cart_button_text', - 'generate_woocommerce_colors', - 'woocommerce-mini-cart-colors', - array( - 'generate_settings[wc_mini_cart_button_text]' => array( - 'default_value' => $color_defaults['wc_mini_cart_button_text'], - 'label' => __( 'Button Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Initial Color', 'gp-premium' ), - 'element' => '#wc-mini-cart .button', - 'property' => 'color', - 'hide_label' => false, - ), - 'generate_settings[wc_mini_cart_button_text_hover]' => array( - 'default_value' => $color_defaults['wc_mini_cart_button_text_hover'], - 'label' => __( 'Button Text Hover', 'gp-premium' ), - 'tooltip' => __( 'Choose Hover Color', 'gp-premium' ), - 'element' => '#wc-mini-cart .button:hover, #wc-mini-cart .button:focus, #wc-mini-cart .button:active', - 'property' => 'color', - 'hide_label' => true, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_price_slider_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Price Slider Widget', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-price-slider-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_price_slider_background', - 'generate_woocommerce_colors', - 'woocommerce-price-slider-colors', - array( - 'generate_settings[wc_price_slider_background_color]' => array( - 'default_value' => $color_defaults['wc_price_slider_background_color'], - 'label' => __( 'Slider Background Color', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce .widget_price_filter .price_slider_wrapper .ui-widget-content', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_price_slider_bar', - 'generate_woocommerce_colors', - 'woocommerce-price-slider-colors', - array( - 'generate_settings[wc_price_slider_bar_color]' => array( - 'default_value' => $color_defaults['wc_price_slider_bar_color'], - 'label' => __( 'Slider Bar Color', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce .widget_price_filter .ui-slider .ui-slider-range, .woocommerce .widget_price_filter .ui-slider .ui-slider-handle', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_product_tabs_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Product Tabs', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-product-tabs-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_product_tab_text', - 'generate_woocommerce_colors', - 'woocommerce-product-tabs-colors', - array( - 'generate_settings[wc_product_tab]' => array( - 'default_value' => $color_defaults['wc_product_tab'], - 'label' => __( 'Product Tab Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce div.product .woocommerce-tabs ul.tabs li a', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_product_tab_text', - 'generate_woocommerce_colors', - 'woocommerce-product-tabs-colors', - array( - 'generate_settings[wc_product_tab_highlight]' => array( - 'default_value' => $color_defaults['wc_product_tab_highlight'], - 'label' => __( 'Product Tab Active', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover, .woocommerce div.product .woocommerce-tabs ul.tabs li.active a', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_woocommerce_messages_colors_title', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Messages', 'gp-premium' ), - 'choices' => array( - 'toggleId' => 'woocommerce-messages-colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_success_message_background', - 'generate_woocommerce_colors', - 'woocommerce-messages-colors', - array( - 'generate_settings[wc_success_message_background]' => array( - 'default_value' => $color_defaults['wc_success_message_background'], - 'label' => __( 'Success Message Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce-message', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_success_message_text', - 'generate_woocommerce_colors', - 'woocommerce-messages-colors', - array( - 'generate_settings[wc_success_message_text]' => array( - 'default_value' => $color_defaults['wc_success_message_text'], - 'label' => __( 'Success Message Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce-message', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_info_message_background', - 'generate_woocommerce_colors', - 'woocommerce-messages-colors', - array( - 'generate_settings[wc_info_message_background]' => array( - 'default_value' => $color_defaults['wc_info_message_background'], - 'label' => __( 'Info Message Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce-info', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_info_message_text', - 'generate_woocommerce_colors', - 'woocommerce-messages-colors', - array( - 'generate_settings[wc_info_message_text]' => array( - 'default_value' => $color_defaults['wc_info_message_text'], - 'label' => __( 'Info Message Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce-info', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_error_message_background', - 'generate_woocommerce_colors', - 'woocommerce-messages-colors', - array( - 'generate_settings[wc_error_message_background]' => array( - 'default_value' => $color_defaults['wc_error_message_background'], - 'label' => __( 'Error Message Background', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce-error', - 'property' => 'background-color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_color_field_group( - 'woocommerce_error_message_text', - 'generate_woocommerce_colors', - 'woocommerce-messages-colors', - array( - 'generate_settings[wc_error_message_text]' => array( - 'default_value' => $color_defaults['wc_error_message_text'], - 'label' => __( 'Error Message Text', 'gp-premium' ), - 'tooltip' => __( 'Choose Color', 'gp-premium' ), - 'element' => '.woocommerce-error', - 'property' => 'color', - 'hide_label' => false, - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'woocommerce_colors_redirect', - array( - 'section' => 'generate_colors_section', - 'title' => __( 'WooCommerce', 'gp-premium' ), - 'choices' => array( - 'sectionRedirect' => true, - 'toggleId' => 'generate_woocommerce_colors', - ), - ) - ); - - GeneratePress_Customize_Field::add_title( - 'generate_colors_redirect', - array( - 'section' => 'generate_woocommerce_colors', - 'title' => __( 'Other Theme Colors', 'gp-premium' ), - 'choices' => array( - 'sectionRedirect' => true, - 'toggleId' => 'generate_colors_section', - ), - ) - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.css deleted file mode 100644 index 1ec6d510..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.css +++ /dev/null @@ -1,198 +0,0 @@ -.woocommerce-product-gallery { - margin-right: 0; -} - -.woocommerce .woocommerce-ordering, -.woocommerce-page .woocommerce-ordering { - float: none; -} - -.woocommerce .woocommerce-ordering select { - max-width: 100%; -} - -.woocommerce #wc-column-container.wc-mobile-columns-1 .products, -.wc-related-upsell-mobile-columns-1 .related ul.products, -.wc-related-upsell-mobile-columns-1 .up-sells ul.products { - grid-template-columns: repeat(1, minmax(0, 1fr)); -} - -.woocommerce #wc-column-container.wc-mobile-columns-2 .products, -.wc-related-upsell-mobile-columns-2 .related ul.products, -.wc-related-upsell-mobile-columns-2 .up-sells ul.products { - grid-template-columns: repeat(2, minmax(0, 1fr)); -} - -.woocommerce #wc-column-container.wc-mobile-columns-3 .products, -.wc-related-upsell-mobile-columns-3 .related ul.products, -.wc-related-upsell-mobile-columns-3 .up-sells ul.products { - grid-template-columns: repeat(3, minmax(0, 1fr)); -} - -.woocommerce ul.products li.product a img { - width: auto; - margin-left: auto; - margin-right: auto; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs, -.woocommerce div.product .woocommerce-tabs .panel { - float: none; - width: 100%; -} - -.woocommerce div.product .woocommerce-tabs .panel { - margin-top: 20px; -} - -.wc-tabs .active a:after { - transform: rotate(90deg); - padding-right: 3px; -} - -.woocommerce .col2-set, -.woocommerce-page .col2-set { - width: 100%; - float: none; - margin-right: 0; -} - -#customer_details + #wc_checkout_add_ons, -#order_review, -#order_review_heading { - width: 100%; - float: none; - margin-right: 0; -} - -.woocommerce ul.products li.product.woocommerce-image-align-left .wc-product-image, -.woocommerce ul.products li.product.woocommerce-image-align-right .wc-product-image { - float: none; - margin: 0; -} - -.woocommerce ul.products li.product.woocommerce-image-align-left a .wc-product-image img, -.woocommerce ul.products li.product.woocommerce-image-align-right a .wc-product-image img { - width: 100%; -} - -.woocommerce .related ul.products li.product, -.woocommerce-page .related ul.products li.product, -.woocommerce-page[class*=columns-] .related ul.products li.product, -.woocommerce[class*=columns-] .related ul.products li.product, -.woocommerce .up-sells ul.products li.product, -.woocommerce-page .up-sells ul.products li.product, -.woocommerce-page[class*=columns-] .up-sells ul.products li.product, -.woocommerce[class*=columns-] .up-sells ul.products li.product { - width: 100%; - margin-left: 0; - margin-right: 0; -} - -.woocommerce form .woocommerce-billing-fields__field-wrapper .form-row-first, -.woocommerce form .woocommerce-billing-fields__field-wrapper .form-row-last, -.woocommerce-page form .woocommerce-billing-fields__field-wrapper .form-row-first, -.woocommerce-page form .woocommerce-billing-fields__field-wrapper .form-row-last { - float: none; - width: 100%; -} - -.woocommerce-account .woocommerce-MyAccount-navigation { - width: 100%; -} - -.woocommerce-MyAccount-navigation li.is-active a:after { - content: "\e901"; -} - -#wc-mini-cart { - display: none; -} - -.do-quantity-buttons div.quantity { - justify-content: flex-end; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs { - flex-direction: column; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs li { - border-left-width: 1px; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs li:last-child { - border-bottom-color: rgba(0, 0, 0, 0.08); - border-bottom-width: 1px; -} - -.woocommerce .coupon .button { - font-size: 14px; - padding: 10px; -} - -.woocommerce .woocommerce-ordering { - margin-bottom: 0; -} - -.add-to-cart-panel { - bottom: 0; - top: auto; - transform: translateY(0px) !important; -} - -.add-to-cart-panel .continue-shopping:not(.has-svg-icon):before { - content: "\f00d"; - font-family: 'GP Premium'; - line-height: 1em; - width: 1.28571429em; - text-align: center; - display: inline-block; - padding: 10px; -} - -#wc-sticky-cart-panel .quantity, -.add-to-cart-panel .continue-shopping-link { - display: none; -} - -.add-to-cart-panel .continue-shopping { - order: 5; - margin-left: auto; - margin-right: 0; - position: absolute; - top: -20px; - left: 10px; - height: 50px; - width: 50px; - text-align: center; - border-radius: 50%; - line-height: 50px; - cursor: pointer; -} - -.add-to-cart-panel .continue-shopping .gp-icon { - display: block; -} - -.add-to-cart-panel .product-image, -.add-to-cart-panel .cart { - flex-shrink: 0; -} - -.add-to-cart-panel .product-title { - padding-right: 20px; - margin-left: 10px; -} - -.add-to-cart-panel .cart-info { - margin-right: auto; -} - -.add-to-cart-panel .product-price { - font-size: 13px; -} - -.add-to-cart-panel:not(.item-added):not(.show-sticky-add-to-cart) { - pointer-events: none; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.min.css deleted file mode 100644 index 6c944aa9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce-mobile.min.css +++ /dev/null @@ -1 +0,0 @@ -.woocommerce-product-gallery{margin-right:0}.woocommerce .woocommerce-ordering,.woocommerce-page .woocommerce-ordering{float:none}.woocommerce .woocommerce-ordering select{max-width:100%}.wc-related-upsell-mobile-columns-1 .related ul.products,.wc-related-upsell-mobile-columns-1 .up-sells ul.products,.woocommerce #wc-column-container.wc-mobile-columns-1 .products{grid-template-columns:repeat(1,minmax(0,1fr))}.wc-related-upsell-mobile-columns-2 .related ul.products,.wc-related-upsell-mobile-columns-2 .up-sells ul.products,.woocommerce #wc-column-container.wc-mobile-columns-2 .products{grid-template-columns:repeat(2,minmax(0,1fr))}.wc-related-upsell-mobile-columns-3 .related ul.products,.wc-related-upsell-mobile-columns-3 .up-sells ul.products,.woocommerce #wc-column-container.wc-mobile-columns-3 .products{grid-template-columns:repeat(3,minmax(0,1fr))}.woocommerce ul.products li.product a img{width:auto;margin-left:auto;margin-right:auto}.woocommerce div.product .woocommerce-tabs .panel,.woocommerce div.product .woocommerce-tabs ul.tabs{float:none;width:100%}.woocommerce div.product .woocommerce-tabs .panel{margin-top:20px}.wc-tabs .active a:after{transform:rotate(90deg);padding-right:3px}.woocommerce .col2-set,.woocommerce-page .col2-set{width:100%;float:none;margin-right:0}#customer_details+#wc_checkout_add_ons,#order_review,#order_review_heading{width:100%;float:none;margin-right:0}.woocommerce ul.products li.product.woocommerce-image-align-left .wc-product-image,.woocommerce ul.products li.product.woocommerce-image-align-right .wc-product-image{float:none;margin:0}.woocommerce ul.products li.product.woocommerce-image-align-left a .wc-product-image img,.woocommerce ul.products li.product.woocommerce-image-align-right a .wc-product-image img{width:100%}.woocommerce .related ul.products li.product,.woocommerce .up-sells ul.products li.product,.woocommerce-page .related ul.products li.product,.woocommerce-page .up-sells ul.products li.product,.woocommerce-page[class*=columns-] .related ul.products li.product,.woocommerce-page[class*=columns-] .up-sells ul.products li.product,.woocommerce[class*=columns-] .related ul.products li.product,.woocommerce[class*=columns-] .up-sells ul.products li.product{width:100%;margin-left:0;margin-right:0}.woocommerce form .woocommerce-billing-fields__field-wrapper .form-row-first,.woocommerce form .woocommerce-billing-fields__field-wrapper .form-row-last,.woocommerce-page form .woocommerce-billing-fields__field-wrapper .form-row-first,.woocommerce-page form .woocommerce-billing-fields__field-wrapper .form-row-last{float:none;width:100%}.woocommerce-account .woocommerce-MyAccount-navigation{width:100%}.woocommerce-MyAccount-navigation li.is-active a:after{content:"\e901"}#wc-mini-cart{display:none}.do-quantity-buttons div.quantity{justify-content:flex-end}.woocommerce div.product .woocommerce-tabs ul.tabs{flex-direction:column}.woocommerce div.product .woocommerce-tabs ul.tabs li{border-left-width:1px}.woocommerce div.product .woocommerce-tabs ul.tabs li:last-child{border-bottom-color:rgba(0,0,0,.08);border-bottom-width:1px}.woocommerce .coupon .button{font-size:14px;padding:10px}.woocommerce .woocommerce-ordering{margin-bottom:0}.add-to-cart-panel{bottom:0;top:auto;transform:translateY(0)!important}.add-to-cart-panel .continue-shopping:not(.has-svg-icon):before{content:"\f00d";font-family:'GP Premium';line-height:1em;width:1.28571429em;text-align:center;display:inline-block;padding:10px}#wc-sticky-cart-panel .quantity,.add-to-cart-panel .continue-shopping-link{display:none}.add-to-cart-panel .continue-shopping{order:5;margin-left:auto;margin-right:0;position:absolute;top:-20px;left:10px;height:50px;width:50px;text-align:center;border-radius:50%;line-height:50px;cursor:pointer}.add-to-cart-panel .continue-shopping .gp-icon{display:block}.add-to-cart-panel .cart,.add-to-cart-panel .product-image{flex-shrink:0}.add-to-cart-panel .product-title{padding-right:20px;margin-left:10px}.add-to-cart-panel .cart-info{margin-right:auto}.add-to-cart-panel .product-price{font-size:13px}.add-to-cart-panel:not(.item-added):not(.show-sticky-add-to-cart){pointer-events:none} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.css deleted file mode 100644 index d1505f49..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.css +++ /dev/null @@ -1,1283 +0,0 @@ -@supports (display: grid) { - .woocommerce ul.products li.product { - display: flex; - flex-direction: column; - } -} - -.woocommerce ul.products li.product.woocommerce-image-align-left, -.woocommerce ul.products li.product.woocommerce-image-align-right { - display: block; -} - -.woocommerce ul.products li.product .woocommerce-LoopProduct-link { - display: block; - margin-bottom: auto; -} - -.woocommerce ul.products li.product .button { - margin-left: auto; - margin-right: auto; -} - -.woocommerce ul.products li.product.woocommerce-text-align-left .button { - margin-left: 0; -} - -.woocommerce ul.products li.product.woocommerce-text-align-right .button { - margin-right: 0; -} - -.woocommerce ul.products li.product .woocommerce-LoopProduct-link > *:not(:first-child) { - margin-top: 10px; - margin-bottom: 0; -} - -.woocommerce ul.products li.product .woocommerce-LoopProduct-link > .secondary-image + img { - margin-top: 0; -} - -.woocommerce ul.products li.product .onsale, -.woocommerce span.onsale { - position: relative; - border-radius: 0; - min-height: 15px; - min-width: initial; - font-weight: inherit; - font-size: inherit; - padding: 8px 13px; - line-height: 1; - display: inline-block; - top: auto; - left: auto; - font-size: 80%; - text-transform: uppercase; - font-weight: bold; -} - -.woocommerce ul.products li.product.sales-flash-overlay .onsale { - position: absolute; - top: 0; - right: 0; - margin: 0; -} - -.single-product span.onsale { - margin-bottom: 15px; -} - -.woocommerce-product-gallery { - margin-right: 4%; -} - -.rtl .woocommerce-product-gallery { - margin-right: 0; - margin-left: 4%; -} - -.woocommerce div.product div.images .flex-control-thumbs li { - max-width: 100px; - padding-top: 5px; - padding-right: 5px; - box-sizing: border-box; -} - -.woocommerce ul.products li.product .woocommerce-loop-product__title { - padding: 0; -} - -.woocommerce .page-header-image-single { - display: none; -} - -.woocommerce .entry-content, -.woocommerce .product .entry-summary { - margin-top: 0; -} - -.related.products { - clear: both; -} - -.checkout-subscribe-prompt.clear { - visibility: visible; - height: initial; - width: initial; -} - -.woocommerce .add_to_cart_button + .added_to_cart { - display: none; -} - -.woocommerce-result-count { - font-size: 14px; - padding: 10px 0; - border: 1px solid transparent; -} - -.woocommerce-ordering select { - font-size: 14px; - font-weight: 500; - padding: 10px 40px 10px 12px; - -webkit-appearance: none; - -moz-appearance: none; - width: 100%; - background: transparent; - border-color: rgba(0, 0, 0, 0.1); - color: inherit; - cursor: pointer; -} - -.woocommerce-ordering select::-ms-expand { - display: none; -} - -.woocommerce-ordering:after { - content: "\e903"; - font-family: "GP Premium"; - display: inline-block; - position: absolute; - pointer-events: none; - color: inherit; - top: 10px; - right: 15px; - font-size: 16px; -} - -.woocommerce-ordering select option { - color: initial; -} - -.woocommerce .woocommerce-ordering, -.woocommerce .woocommerce-result-count { - margin-bottom: 30px; -} - -.woocommerce-variation-add-to-cart { - display: flex; - flex-wrap: wrap; -} - -/* Columns */ -@supports (display: grid) { - #wc-column-container .product { - float: none; - width: auto; - margin: 0; - } - .woocommerce .wc-columns-container .products::after, - .woocommerce .wc-columns-container .products::before, - .woocommerce .related ul.products::after, - .woocommerce .related ul.products::before, - .woocommerce .up-sells ul.products::after, - .woocommerce .up-sells ul.products::before { - display: none; - } - .wc-columns-container .products, - .woocommerce .related ul.products, - .woocommerce .up-sells ul.products { - display: grid; - grid-gap: 50px; - width: 100%; - } - .wc-columns-container.wc-columns-6 .products, - .wc-related-upsell-columns-6 .related ul.products, - .wc-related-upsell-columns-6 .up-sells ul.products { - grid-template-columns: repeat(6, minmax(0, 1fr)); - } - .wc-columns-container.wc-columns-5 .products, - .wc-related-upsell-columns-5 .related ul.products, - .wc-related-upsell-columns-5 .up-sells ul.products { - grid-template-columns: repeat(5, minmax(0, 1fr)); - } - .woocommerce .wc-columns-container.wc-columns-4 .products, - .wc-related-upsell-columns-4 .related ul.products, - .wc-related-upsell-columns-4 .up-sells ul.products { - grid-template-columns: repeat(4, minmax(0, 1fr)); - } - .woocommerce .wc-columns-container.wc-columns-3 .products, - .wc-related-upsell-columns-3 .related ul.products, - .wc-related-upsell-columns-3 .up-sells ul.products { - grid-template-columns: repeat(3, minmax(0, 1fr)); - } - .woocommerce .wc-columns-container.wc-columns-2 .products, - .wc-related-upsell-columns-2 .related ul.products, - .wc-related-upsell-columns-2 .up-sells ul.products { - grid-template-columns: repeat(2, minmax(0, 1fr)); - } - .woocommerce .wc-columns-container.wc-columns-1 .products, - .wc-related-upsell-columns-1 .related ul.products, - .wc-related-upsell-columns-1 .up-sells ul.products { - width: 100%; - } - .woocommerce .wc-columns-1 ul.products li.product, - .woocommerce-page .wc-columns-1 ul.products li.product { - margin-left: 0; - margin-right: 0; - } -} - -/* Mini Cart */ -#wc-mini-cart ul.woocommerce-mini-cart { - position: relative; - left: auto; - right: auto; - opacity: 1; - pointer-events: auto; - height: auto; - width: auto; - float: none; - background-color: transparent; - box-shadow: 0 0 0; - visibility: visible; -} - -.wc-mini-cart { - position: absolute; - width: 300px; - right: 0; - box-shadow: 0 2px 2px rgba(0, 0, 0, 0.1); - z-index: 99999; - left: -99999px; - opacity: 0; - height: 0; - overflow: hidden; - pointer-events: none; - transition: opacity 80ms linear; - transition-delay: 0s; - visibility: hidden; -} - -.wc-menu-item:hover .wc-mini-cart, -.wc-menu-item.sfHover .wc-mini-cart { - left: auto; - opacity: 1; - transition-delay: 150ms; - pointer-events: auto; - height: auto; - overflow: visible; - visibility: visible; -} - -.dropdown-click ul li.wc-menu-item:hover ul { - display: block; -} - -.sidebar .wc-mini-cart { - right: 100%; - top: 0; -} - -.sidebar .wc-mini-cart .widget { - background: none; -} - -body:not(.using-mouse) .wc-menu-item.sfHover .wc-mini-cart { - display: none; -} - -.wc-menu-item .sub-menu { - left: auto; - right: 0; - width: 300px; -} - -.wc-menu-item .wc-mini-cart .widget_shopping_cart_content li:hover a, -.wc-menu-item .wc-mini-cart .widget_shopping_cart_content li.sfHover a { - background: none; -} - -.wc-menu-item .wc-mini-cart .widget_shopping_cart { - padding: 15px; -} - -.woocommerce.widget_shopping_cart .cart_list li { - padding: 0 0 0 4em; - margin: 0; - box-sizing: border-box; - min-height: 3em; -} - -.woocommerce.widget_shopping_cart { - font-size: 14px; -} - -.widget_shopping_cart .woocommerce-mini-cart__buttons { - margin-bottom: 0; - display: flex; -} - -.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a { - margin: 0; - width: calc(50% - 10px); - text-align: center; - padding: 10px 15px; - line-height: inherit; - font-size: 14px; -} - -.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a:first-child { - margin-right: 2px; -} - -.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a:last-child { - margin-left: 2px; -} - -.woocommerce.widget_shopping_cart .cart_list li a.remove { - right: 0; - left: auto; - height: 20px; - width: 20px; - border-width: 1px; - border-style: solid; - border-radius: 50%; - padding: 0; - font-size: 16px; - line-height: 17px; - font-weight: normal; - position: relative; - float: right; -} - -.woocommerce ul.cart_list li img { - position: absolute; - left: 0; - width: 3em; - height: auto; - top: 0; - margin-left: 0; -} - -#wc-mini-cart .woocommerce-mini-cart-item a { - padding: 0; -} - -.woocommerce-mini-cart-item .quantity { - font-size: 12px; - display: block; -} - -.woocommerce.widget_shopping_cart .total { - margin: 15px 0; - padding: 15px; - background: rgba(0, 0, 0, 0.05); - border: 0; - font-size: 14px; -} - -#wc-mini-cart .total { - padding: 15px; - margin: 15px -15px 15px; - text-align: left; -} - -#generate-slideout-menu .total { - padding: 10px 20px; - margin: 20px -20px 20px; -} - -#generate-slideout-menu.do-overlay .total { - margin: 20px 0; -} - -.woocommerce.widget_shopping_cart a.button.wc-forward:after { - display: none; -} - -.woocommerce.widget_shopping_cart .cart_list li.woocommerce-mini-cart-item:not(:last-child) { - margin-bottom: 15px; -} - -.rtl .wc-mini-cart .woocommerce.widget_shopping_cart .cart_list li { - padding: 0 4em 0 0; -} - -.rtl .wc-mini-cart .woocommerce.widget_shopping_cart .cart_list li a.remove { - float: left; -} - -.rtl .wc-mini-cart .woocommerce ul.cart_list li img { - right: 0; -} - -.slideout-widget .widget_shopping_cart_content, -.slideout-widget .widget_shopping_cart_content a { - font-size: 14px; -} - -#generate-slideout-menu.do-overlay li.woocommerce-mini-cart-item { - text-align: left; -} - -#wc-mini-cart a:not(.button) { - font-family: inherit; -} - -.wc-menu-item:not(.has-items) .wc-mini-cart { - display: none; -} - -.woocommerce-mini-cart__empty-message { - margin-bottom: 0; -} - -.secondary-nav-aligned-right .secondary-navigation ul.woocommerce-mini-cart, -.secondary-nav-aligned-center .secondary-navigation ul.woocommerce-mini-cart { - font-size: inherit; -} - -#wc-mini-cart .widgettitle { - display: none; -} - -/* Related/Upsell products */ -@supports (display: grid) { - .woocommerce .related ul.products li.product, - .woocommerce .up-sells ul.products li.product { - width: auto; - margin-left: 0; - margin-right: 0; - margin-bottom: 0; - } -} - -.woocommerce #respond input#submit, -.woocommerce a.button, -.woocommerce button.button, -.woocommerce input.button { - border-radius: 0px; - font-weight: inherit; - font-size: inherit; - line-height: inherit; - padding: 10px 20px; -} - -ul.products .woocommerce-text-align-center { - text-align: center; -} - -ul.products li.product.woocommerce-text-align-center .price, -ul.products li.product.woocommerce-text-align-center .star-rating { - margin-left: auto; - margin-right: auto; -} - -ul.products li.product.woocommerce-text-align-right .price, -ul.products li.product.woocommerce-text-align-right .star-rating { - margin-left: auto; -} - -.woocommerce .star-rating:before { - color: rgba(0, 0, 0, 0.4); -} - -.woocommerce p.stars a { - color: rgba(0, 0, 0, 0.4); -} - -.woocommerce p.stars.selected a:before { - color: #ffa200; -} - -.woocommerce ul.products li.product .price del { - display: inline; - padding-right: 10px; -} - -ul.products .woocommerce-text-align-right { - text-align: right; -} - -/*-------------------------------------------------------------- -# Single Product ---------------------------------------------------------------*/ -.woocommerce #content div.product div.images, -.woocommerce div.product div.images, -.woocommerce-page #content div.product div.images, -.woocommerce-page div.product div.images { - width: 50%; -} - -.woocommerce #content div.product div.summary, -.woocommerce div.product div.summary, -.woocommerce-page #content div.product div.summary, -.woocommerce-page div.product div.summary { - width: auto; - float: none; - overflow: hidden; -} - -.product_meta { - font-size: 80%; - border-top: 1px solid rgba(0, 0, 0, 0.1); - padding-top: 30px; -} - -.product_meta > span { - display: block; -} - -.up-sells { - margin-top: 40px; -} - -.woocommerce div.product.do-quantity-buttons form.cart, -.add-to-cart-panel form.cart { - display: flex; - flex-wrap: wrap; -} - -.woocommerce div.product form.cart > *:not(.quantity):not(.single_add_to_cart_button) { - width: 100%; -} - -.add-to-cart-panel form.cart { - flex-shrink: 0; -} - -.woocommerce .quantity .qty { - height: 100%; - width: auto; - max-width: 80px; - background: transparent; - border: 1px solid rgba(0, 0, 0, 0.1); - padding: 0 10px; - height: 50px; -} - -.do-quantity-buttons .quantity:not(.buttons-added) .qty { - width: 50px; -} - -.do-quantity-buttons div.quantity, -.add-to-cart-panel .cart.do-quantity-buttons div.quantity { - display: flex; - align-items: center; -} - -.woocommerce form .quantity.buttons-added .qty, -.woocommerce form .quantity.buttons-added .minus, -.woocommerce form .quantity.buttons-added .plus, -.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):before, -.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):after { - display: block; - width: 50px; - height: 100%; - min-height: 50px; - background-color: transparent; - border: 1px solid rgba(0, 0, 0, 0.1); - margin: 0; - padding: 0; - text-align: center; - vertical-align: middle; - -moz-appearance: textfield !important; - -webkit-appearance: none; - border-radius: 0; - color: inherit; - box-sizing: border-box; - text-decoration: none; -} - -.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):before, -.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):after, -.woocommerce form .quantity.buttons-added .minus, -.woocommerce form .quantity.buttons-added .plus { - display: flex; - align-items: center; - justify-content: center; -} - -.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):before { - content: "-"; - border-right: 0; -} - -.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):after { - content: "+"; - border-left: 0; -} - -.woocommerce form .quantity.buttons-added .qty:focus { - border-color: rgba(0, 0, 0, 0.1); -} - -.do-quantity-buttons form .quantity input[type=number]::-webkit-inner-spin-button, -.do-quantity-buttons form .quantity input[type=number]::-webkit-outer-spin-button { - -webkit-appearance: none; - margin: 0; -} - -.woocommerce form .quantity.buttons-added .minus, -.do-quantity-buttons form .quantity:not(.buttons-added):before { - border-right-width: 0; -} - -.woocommerce form .quantity.buttons-added .plus, -.do-quantity-buttons form .quantity:not(.buttons-added):after { - border-left-width: 0; -} - -.do-quantity-buttons .elementor-add-to-cart form .quantity:not(.buttons-added):before, -.do-quantity-buttons .elementor-add-to-cart form .quantity:not(.buttons-added):after, -.do-quantity-buttons form .quantity.hidden { - display: none; -} - -.woocommerce div.product form.cart div.quantity.hidden { - margin: 0; -} - -/*-------------------------------------------------------------- -## Tabs ---------------------------------------------------------------*/ -.woocommerce div.product .woocommerce-tabs ul.tabs li::after, -.woocommerce div.product .woocommerce-tabs ul.tabs li::before, -.woocommerce div.product .woocommerce-tabs ul.tabs::before { - display: none; - border: 0; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs { - display: flex; - margin-left: 0; - padding-left: 0; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs li { - background-color: rgba(0, 0, 0, 0.02); - margin: 0; - border-radius: 0; - border-width: 1px 1px 0 0; - border-color: rgba(0, 0, 0, 0.08); -} - -.woocommerce div.product .woocommerce-tabs ul.tabs li:first-child { - border-left-width: 1px; -} - -.woocommerce-ordering { - float: left; - margin-right: 1em; - margin-bottom: 0; - position: relative; - padding: 0; -} - -/*-------------------------------------------------------------- -# Menu Item ---------------------------------------------------------------*/ -nav li.wc-menu-item { - float: right; -} - -.cart-contents > span { - line-height: 0; -} - -.cart-contents > span:not(:empty) { - margin-left: 10px; -} - -.rtl .cart-contents > span:not(:empty) { - margin-left: 0; - margin-right: 10px; -} - -.cart-contents > span.gp-icon { - margin-left: 0; -} - -.rtl .cart-contents > span.gp-icon { - margin-right: 0; -} - -nav span.count { - font-size: 0.8em; - opacity: 0.5; -} - -/*-------------------------------------------------------------- -# Cart ---------------------------------------------------------------*/ -.woocommerce a.remove { - color: inherit !important; - background: transparent !important; - border: 1px solid !important; - border-color: inherit; - font-weight: normal; - font-size: 16px; - width: 20px; - height: 20px; - line-height: 17px; - font-family: -apple-system, system-ui, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol" !important; -} - -.woocommerce a.remove:hover { - color: inherit !important; - background: transparent !important; - opacity: 0.7; -} - -.woocommerce .star-rating:before { - opacity: 0.25; - content: "SSSSS"; -} - -.woocommerce div.product .woocommerce-product-rating { - margin: 1em 0; -} - -.woocommerce div.product p.price, -.woocommerce div.product span.price { - color: inherit; -} - -.wc-has-gallery .secondary-image { - position: absolute; - opacity: 0; - transition: opacity 100ms ease-in-out; - left: 50%; - transform: translate(-50%, 0px); - top: 0; -} - -.wc-has-gallery picture.secondary-image { - width: 100%; - height: 100%; -} - -.wc-product-image:hover .secondary-image { - opacity: 1; -} - -.woocommerce ul.products li.product a img { - margin-bottom: 0; -} - -.woocommerce div.product .woocommerce-tabs ul.tabs li a, -.woocommerce div.product .woocommerce-tabs ul.tabs li.active a { - color: initial; -} - -.woocommerce ul.products li.product .price, .woocommerce div.product p.price { - font-weight: bold; -} - -div.woocommerce-message a.button, -div.woocommerce-message a.button:hover, -div.woocommerce-message a.button:focus, -div.woocommerce-info a.button, -div.woocommerce-info a.button:hover, -div.woocommerce-info a.button:focus, -div.woocommerce-error a.button, -div.woocommerce-error a.button:hover, -div.woocommerce-error a.button:focus { - background: transparent; - padding: 0; -} - -.woocommerce-error a, -.woocommerce-info a, -.woocommerce-message a { - font-weight: bold; -} - -.woocommerce-error, -.woocommerce-info, -.woocommerce-message { - padding: 20px 30px; - border: 0; - border-left: 10px solid rgba(0, 0, 0, 0.3); -} - -.woocommerce-message::before, -.woocommerce-info::before, -.woocommerce-error::before { - display: none; -} - -a.button.wc-forward:after { - content: "\e901"; - font-family: "GP Premium"; - line-height: 1em; - padding-left: 10px; - position: relative; - top: 2px; -} - -.rtl a.button.wc-forward:after { - display: none; -} - -.woocommerce-checkout .col2-set .col-2, -.woocommerce-checkout .col2-set .col-1 { - float: none; - width: 100%; - margin: 0; -} - -.woocommerce-checkout .col2-set { - width: 52.9411764706%; - float: left; - margin-right: 5.8823529412%; -} - -.rtl.woocommerce-checkout .col2-set { - float: right; - margin-right: 0; - margin-left: 5.8823529412%; -} - -#customer_details + #wc_checkout_add_ons, -#order_review, -#order_review_heading { - width: 41.1764705882%; - float: right; - margin-right: 0; -} - -.woocommerce-additional-fields > h3 { - margin-top: 20px; -} - -.woocommerce table.shop_table, -.woocommerce table.shop_table tfoot th, -.woocommerce table.shop_table tfoot td { - border: 0; - border-radius: 0; -} - -.woocommerce table.shop_table th { - background-color: rgba(0, 0, 0, 0.03); -} - -.woocommerce table.shop_table th, -.woocommerce table.shop_table td { - padding: 20px; - border: 0; -} - -.woocommerce table.shop_table td { - background-color: rgba(0, 0, 0, 0.005); - border-bottom: 1px solid rgba(0, 0, 0, 0.1); -} - -#add_payment_method .cart-collaterals .cart_totals tr td, -#add_payment_method .cart-collaterals .cart_totals tr th, -.woocommerce-cart .cart-collaterals .cart_totals tr td, -.woocommerce-cart .cart-collaterals .cart_totals tr th, -.woocommerce-checkout .cart-collaterals .cart_totals tr td, -.woocommerce-checkout .cart-collaterals .cart_totals tr th { - border-top: 0; -} - -#add_payment_method #payment, -.woocommerce-cart #payment, -.woocommerce-checkout #payment, -#add_payment_method #payment div.payment_box, -.woocommerce-cart #payment div.payment_box, -.woocommerce-checkout #payment div.payment_box { - background-color: transparent; - color: inherit; -} - -#add_payment_method #payment div.payment_box:before, -.woocommerce-cart #payment div.payment_box:before, -.woocommerce-checkout #payment div.payment_box:before { - display: none; -} - -#payment .payment_methods > .wc_payment_method > label { - padding: 20px; - background-color: rgba(0, 0, 0, 0.04); - display: block; - cursor: pointer; -} - -#payment .payment_methods li.wc_payment_method > input[type=radio]:first-child:checked + label { - font-weight: bold; - background-color: rgba(0, 0, 0, 0.07); -} - -#payment .payment_methods li.wc_payment_method > input[type=radio]:first-child { - clip: rect(1px, 1px, 1px, 1px); - position: absolute !important; -} - -#payment .payment_methods > .wc_payment_method > label:before { - display: inline-block; - font-size: inherit; - -webkit-font-smoothing: antialiased; - content: "\e902"; - margin-right: .5407911001em; - transition: color,ease,.2s; - font-family: "GP Premium"; -} - -#payment .payment_methods li.wc_payment_method > input[type=radio]:first-child:checked + label:before { - content: "\e904"; -} - -#add_payment_method #payment ul.payment_methods, -.woocommerce-cart #payment ul.payment_methods, -.woocommerce-checkout #payment ul.payment_methods { - padding: 0; - border: 0; -} - -.woocommerce #payment #place_order, -.woocommerce-page #payment #place_order { - float: none; - width: 100%; - padding-top: 20px; - padding-bottom: 20px; - font-weight: bold; - font-size: 150%; -} - -#add_payment_method #payment div.form-row, -.woocommerce-cart #payment div.form-row, -.woocommerce-checkout #payment div.form-row { - padding-left: 0; - padding-right: 0; - padding-top: 0; -} - -#add_payment_method #payment ul.payment_methods li img, -.woocommerce-cart #payment ul.payment_methods li img, -.woocommerce-checkout #payment ul.payment_methods li img { - float: right; -} - -#add_payment_method #payment .payment_method_paypal .about_paypal, -.woocommerce-cart #payment .payment_method_paypal .about_paypal, -.woocommerce-checkout #payment .payment_method_paypal .about_paypal { - float: none; - display: inline-block; - line-height: 1; -} - -a.checkout-button:after { - display: none; -} - -.woocommerce #content table.cart td.actions .input-text, -.woocommerce table.cart td.actions .input-text, -.woocommerce-page #content table.cart td.actions .input-text, -.woocommerce-page table.cart td.actions .input-text { - width: 150px; - padding: 10px 15px; -} - -.woocommerce .coupon .button { - border: 1px solid transparent; -} - -.woocommerce ul.products li.product .woocommerce-product-details__short-description p:last-child { - margin-bottom: 0; -} - -.wc-product-image { - text-align: center; -} - -.woocommerce-text-align-left .wc-product-image { - text-align: left; -} - -.woocommerce-text-align-right .wc-product-image { - text-align: right; -} - -.inside-wc-product-image { - position: relative; - display: inline-block; -} - -.woocommerce ul.products li.product.woocommerce-image-align-left .wc-product-image { - float: left; - margin-right: 2em; -} - -.woocommerce ul.products li.product.woocommerce-image-align-right .wc-product-image { - float: right; - margin-left: 2em; -} - -.woocommerce ul.products li.product.woocommerce-image-align-left a .wc-product-image img, -.woocommerce ul.products li.product.woocommerce-image-align-right a .wc-product-image img { - width: auto; -} - -.woocommerce-cart ul.products li.product.woocommerce-image-align-left .wc-product-image, -.woocommerce-cart ul.products li.product.woocommerce-image-align-right .wc-product-image { - float: none; - margin: 0; -} - -.woocommerce-cart ul.products li.product.woocommerce-image-align-left a .wc-product-image img, -.woocommerce-cart ul.products li.product.woocommerce-image-align-right a .wc-product-image img { - width: 100%; -} - -.woocommerce .widget_price_filter .price_slider_amount .button { - font-size: 1em; - line-height: normal; -} - -.woocommerce .related ul.products li.product a img, -.woocommerce .up-sells ul.products li.product a img { - margin-bottom: 0; -} - -.woocommerce-review-link { - font-size: 80%; -} - -.woocommerce-Reviews .comment-reply-title { - font-size: 120%; - font-weight: bold; - display: block; - margin-bottom: 10px; -} - -.woocommerce-MyAccount-navigation ul { - margin: 0; - border-top: 1px solid rgba(0, 0, 0, 0.1); -} - -.site-main .woocommerce-MyAccount-navigation li { - margin: 0; - padding: 0; -} - -.woocommerce-MyAccount-navigation li a { - display: block; - padding: 20px 0; - border-bottom: 1px solid rgba(0, 0, 0, 0.1); - font-size: 85%; -} - -.woocommerce-MyAccount-navigation li.is-active a { - font-weight: bold; -} - -.woocommerce-MyAccount-navigation li a:hover { - border-bottom: 1px solid rgba(0, 0, 0, 0.2); -} - -.woocommerce-MyAccount-navigation li.is-active a:after { - font-family: "GP Premium"; - content: "\e901"; - float: right; - font-weight: bold; - font-size: 115%; -} - -.woocommerce-account .woocommerce-MyAccount-navigation { - width: 25%; -} - -.woocommerce #payment .terms { - padding: 20px; -} - -h2.woocommerce-loop-category__title mark { - background: none; - font-size: 80%; - opacity: 0.5; -} - -.woocommerce form.checkout_coupon, -.woocommerce form.login, -.woocommerce form.register { - padding: 0; - margin: 0 0 1.5em; - border: 0; -} - -#ship-to-different-address { - padding: 3px; - font-size: inherit; -} - -.woocommerce-image-align-left .products ul, -.woocommerce-image-align-left ul.products, -.woocommerce-image-align-left .products ul:after, -.woocommerce-image-align-left ul.products:after, -.woocommerce-image-align-right .products ul, -.woocommerce-image-align-right ul.products, -.woocommerce-image-align-right .products ul:after, -.woocommerce-image-align-right ul.products:after { - clear: none; -} - -.woocommerce nav.woocommerce-pagination { - margin-top: 60px; - clear: both; -} - -.woocommerce input.button:disabled, -.woocommerce input.button:disabled[disabled], -.woocommerce input.button:disabled:hover, -.woocommerce input.button:disabled[disabled]:hover { - background-color: transparent; - color: initial; - opacity: 0.3; -} - -.entry-summary + .up-sells { - clear: both; -} - -.woocommerce form .form-row input.input-text, -.woocommerce form .form-row textarea { - line-height: 1.5; -} - -.main-navigation a.cart-contents:not(.has-svg-icon):before, -.secondary-navigation a.cart-contents:not(.has-svg-icon):before { - content: "\f07a"; - display: inline-block; - font-family: "GP Premium"; - font-style: normal; - font-weight: normal; - font-variant: normal; - text-transform: none; - line-height: 1; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} - -.main-navigation a.cart-contents:not(.has-svg-icon).shopping-bag:before, -.secondary-navigation a.cart-contents:not(.has-svg-icon).shopping-bag:before { - content: "\f290"; -} - -.main-navigation a.cart-contents:not(.has-svg-icon).shopping-basket:before, -.secondary-navigation a.cart-contents:not(.has-svg-icon).shopping-basket:before { - content: "\f291"; -} - -.cart-contents > span.number-of-items { - font-size: 11px; - display: inline-block; - background: rgba(255, 255, 255, 0.1); - line-height: 1.7em; - height: 1.7em; - width: 1.7em; - text-align: center; - border-radius: 50%; - margin-left: 5px; - position: relative; - top: -5px; - display: none; -} - -.cart-contents > span.number-of-items.no-items { - display: none; -} - -.woocommerce-MyAccount-navigation ul { - list-style-type: none; -} - -/* Fix BlockUI */ -form.checkout:after, -form.checkout:before { - content: ''; - display: table; -} - -form.checkout:after { - clear: both; -} - -/* Add to Cart panel */ -.add-to-cart-panel { - position: fixed; - top: 0; - left: 0; - right: 0; - background: #fff; - padding: 20px; - opacity: 0; - transition: opacity 500ms ease-in-out, transform 500ms ease-in-out; - box-shadow: 0 2px 2px -2px rgba(0, 0, 0, 0.2); - z-index: 101; - font-size: 90%; - box-sizing: border-box; - transform: translateY(-100%); -} - -.add-to-cart-panel.item-added, -.add-to-cart-panel.show-sticky-add-to-cart { - opacity: 1; -} - -.add-to-cart-panel > div { - display: flex; - align-items: center; -} - -.add-to-cart-panel .continue-shopping { - margin-right: auto; -} - -.add-to-cart-panel .continue-shopping .gp-icon { - display: none; -} - -.add-to-cart-panel .cart-info { - margin-right: 20px; -} - -.add-to-cart-panel img { - height: 50px; - width: auto; - vertical-align: middle; -} - -.add-to-cart-panel .product-title { - margin-left: 20px; - margin-right: auto; - font-weight: 600; - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; -} - -.add-to-cart-panel .product-price { - margin-right: 20px; -} - -.add-to-cart-panel div.quantity { - margin-right: 4px; -} - -.add-to-cart-panel .cart-data { - font-size: 12px; -} - -.add-to-cart-panel del { - opacity: 0.4; -} - -.do-quantity-buttons input.qty::-webkit-outer-spin-button, -.do-quantity-buttons input.qty::-webkit-inner-spin-button { - -webkit-appearance: none; -} - -.wc-menu-cart-activated .menu-toggle { - text-align: left; -} - -.woocommerce-order-received .woocommerce-customer-details .col2-set { - float: none; - width: auto; -} - -.woocommerce-order-received .woocommerce-customer-details .col2-set .col-1 { - margin-bottom: 1.5em; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.min.css b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.min.css deleted file mode 100644 index efa4afcc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/css/woocommerce.min.css +++ /dev/null @@ -1 +0,0 @@ -@supports (display:grid){.woocommerce ul.products li.product{display:flex;flex-direction:column}}.woocommerce ul.products li.product.woocommerce-image-align-left,.woocommerce ul.products li.product.woocommerce-image-align-right{display:block}.woocommerce ul.products li.product .woocommerce-LoopProduct-link{display:block;margin-bottom:auto}.woocommerce ul.products li.product .button{margin-left:auto;margin-right:auto}.woocommerce ul.products li.product.woocommerce-text-align-left .button{margin-left:0}.woocommerce ul.products li.product.woocommerce-text-align-right .button{margin-right:0}.woocommerce ul.products li.product .woocommerce-LoopProduct-link>:not(:first-child){margin-top:10px;margin-bottom:0}.woocommerce ul.products li.product .woocommerce-LoopProduct-link>.secondary-image+img{margin-top:0}.woocommerce span.onsale,.woocommerce ul.products li.product .onsale{position:relative;border-radius:0;min-height:15px;min-width:initial;font-weight:inherit;font-size:inherit;padding:8px 13px;line-height:1;display:inline-block;top:auto;left:auto;font-size:80%;text-transform:uppercase;font-weight:700}.woocommerce ul.products li.product.sales-flash-overlay .onsale{position:absolute;top:0;right:0;margin:0}.single-product span.onsale{margin-bottom:15px}.woocommerce-product-gallery{margin-right:4%}.rtl .woocommerce-product-gallery{margin-right:0;margin-left:4%}.woocommerce div.product div.images .flex-control-thumbs li{max-width:100px;padding-top:5px;padding-right:5px;box-sizing:border-box}.woocommerce ul.products li.product .woocommerce-loop-product__title{padding:0}.woocommerce .page-header-image-single{display:none}.woocommerce .entry-content,.woocommerce .product .entry-summary{margin-top:0}.related.products{clear:both}.checkout-subscribe-prompt.clear{visibility:visible;height:initial;width:initial}.woocommerce .add_to_cart_button+.added_to_cart{display:none}.woocommerce-result-count{font-size:14px;padding:10px 0;border:1px solid transparent}.woocommerce-ordering select{font-size:14px;font-weight:500;padding:10px 40px 10px 12px;-webkit-appearance:none;-moz-appearance:none;width:100%;background:0 0;border-color:rgba(0,0,0,.1);color:inherit;cursor:pointer}.woocommerce-ordering select::-ms-expand{display:none}.woocommerce-ordering:after{content:"\e903";font-family:"GP Premium";display:inline-block;position:absolute;pointer-events:none;color:inherit;top:10px;right:15px;font-size:16px}.woocommerce-ordering select option{color:initial}.woocommerce .woocommerce-ordering,.woocommerce .woocommerce-result-count{margin-bottom:30px}.woocommerce-variation-add-to-cart{display:flex;flex-wrap:wrap}@supports (display:grid){#wc-column-container .product{float:none;width:auto;margin:0}.woocommerce .related ul.products::after,.woocommerce .related ul.products::before,.woocommerce .up-sells ul.products::after,.woocommerce .up-sells ul.products::before,.woocommerce .wc-columns-container .products::after,.woocommerce .wc-columns-container .products::before{display:none}.wc-columns-container .products,.woocommerce .related ul.products,.woocommerce .up-sells ul.products{display:grid;grid-gap:50px;width:100%}.wc-columns-container.wc-columns-6 .products,.wc-related-upsell-columns-6 .related ul.products,.wc-related-upsell-columns-6 .up-sells ul.products{grid-template-columns:repeat(6,minmax(0,1fr))}.wc-columns-container.wc-columns-5 .products,.wc-related-upsell-columns-5 .related ul.products,.wc-related-upsell-columns-5 .up-sells ul.products{grid-template-columns:repeat(5,minmax(0,1fr))}.wc-related-upsell-columns-4 .related ul.products,.wc-related-upsell-columns-4 .up-sells ul.products,.woocommerce .wc-columns-container.wc-columns-4 .products{grid-template-columns:repeat(4,minmax(0,1fr))}.wc-related-upsell-columns-3 .related ul.products,.wc-related-upsell-columns-3 .up-sells ul.products,.woocommerce .wc-columns-container.wc-columns-3 .products{grid-template-columns:repeat(3,minmax(0,1fr))}.wc-related-upsell-columns-2 .related ul.products,.wc-related-upsell-columns-2 .up-sells ul.products,.woocommerce .wc-columns-container.wc-columns-2 .products{grid-template-columns:repeat(2,minmax(0,1fr))}.wc-related-upsell-columns-1 .related ul.products,.wc-related-upsell-columns-1 .up-sells ul.products,.woocommerce .wc-columns-container.wc-columns-1 .products{width:100%}.woocommerce .wc-columns-1 ul.products li.product,.woocommerce-page .wc-columns-1 ul.products li.product{margin-left:0;margin-right:0}}#wc-mini-cart ul.woocommerce-mini-cart{position:relative;left:auto;right:auto;opacity:1;pointer-events:auto;height:auto;width:auto;float:none;background-color:transparent;box-shadow:0 0 0;visibility:visible}.wc-mini-cart{position:absolute;width:300px;right:0;box-shadow:0 2px 2px rgba(0,0,0,.1);z-index:99999;left:-99999px;opacity:0;height:0;overflow:hidden;pointer-events:none;transition:opacity 80ms linear;transition-delay:0s;visibility:hidden}.wc-menu-item.sfHover .wc-mini-cart,.wc-menu-item:hover .wc-mini-cart{left:auto;opacity:1;transition-delay:150ms;pointer-events:auto;height:auto;overflow:visible;visibility:visible}.dropdown-click ul li.wc-menu-item:hover ul{display:block}.sidebar .wc-mini-cart{right:100%;top:0}.sidebar .wc-mini-cart .widget{background:0 0}body:not(.using-mouse) .wc-menu-item.sfHover .wc-mini-cart{display:none}.wc-menu-item .sub-menu{left:auto;right:0;width:300px}.wc-menu-item .wc-mini-cart .widget_shopping_cart_content li.sfHover a,.wc-menu-item .wc-mini-cart .widget_shopping_cart_content li:hover a{background:0 0}.wc-menu-item .wc-mini-cart .widget_shopping_cart{padding:15px}.woocommerce.widget_shopping_cart .cart_list li{padding:0 0 0 4em;margin:0;box-sizing:border-box;min-height:3em}.woocommerce.widget_shopping_cart{font-size:14px}.widget_shopping_cart .woocommerce-mini-cart__buttons{margin-bottom:0;display:flex}.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a{margin:0;width:calc(50% - 10px);text-align:center;padding:10px 15px;line-height:inherit;font-size:14px}.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a:first-child{margin-right:2px}.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a:last-child{margin-left:2px}.woocommerce.widget_shopping_cart .cart_list li a.remove{right:0;left:auto;height:20px;width:20px;border-width:1px;border-style:solid;border-radius:50%;padding:0;font-size:16px;line-height:17px;font-weight:400;position:relative;float:right}.woocommerce ul.cart_list li img{position:absolute;left:0;width:3em;height:auto;top:0;margin-left:0}#wc-mini-cart .woocommerce-mini-cart-item a{padding:0}.woocommerce-mini-cart-item .quantity{font-size:12px;display:block}.woocommerce.widget_shopping_cart .total{margin:15px 0;padding:15px;background:rgba(0,0,0,.05);border:0;font-size:14px}#wc-mini-cart .total{padding:15px;margin:15px -15px 15px;text-align:left}#generate-slideout-menu .total{padding:10px 20px;margin:20px -20px 20px}#generate-slideout-menu.do-overlay .total{margin:20px 0}.woocommerce.widget_shopping_cart a.button.wc-forward:after{display:none}.woocommerce.widget_shopping_cart .cart_list li.woocommerce-mini-cart-item:not(:last-child){margin-bottom:15px}.rtl .wc-mini-cart .woocommerce.widget_shopping_cart .cart_list li{padding:0 4em 0 0}.rtl .wc-mini-cart .woocommerce.widget_shopping_cart .cart_list li a.remove{float:left}.rtl .wc-mini-cart .woocommerce ul.cart_list li img{right:0}.slideout-widget .widget_shopping_cart_content,.slideout-widget .widget_shopping_cart_content a{font-size:14px}#generate-slideout-menu.do-overlay li.woocommerce-mini-cart-item{text-align:left}#wc-mini-cart a:not(.button){font-family:inherit}.wc-menu-item:not(.has-items) .wc-mini-cart{display:none}.woocommerce-mini-cart__empty-message{margin-bottom:0}.secondary-nav-aligned-center .secondary-navigation ul.woocommerce-mini-cart,.secondary-nav-aligned-right .secondary-navigation ul.woocommerce-mini-cart{font-size:inherit}#wc-mini-cart .widgettitle{display:none}@supports (display:grid){.woocommerce .related ul.products li.product,.woocommerce .up-sells ul.products li.product{width:auto;margin-left:0;margin-right:0;margin-bottom:0}}.woocommerce #respond input#submit,.woocommerce a.button,.woocommerce button.button,.woocommerce input.button{border-radius:0;font-weight:inherit;font-size:inherit;line-height:inherit;padding:10px 20px}ul.products .woocommerce-text-align-center{text-align:center}ul.products li.product.woocommerce-text-align-center .price,ul.products li.product.woocommerce-text-align-center .star-rating{margin-left:auto;margin-right:auto}ul.products li.product.woocommerce-text-align-right .price,ul.products li.product.woocommerce-text-align-right .star-rating{margin-left:auto}.woocommerce .star-rating:before{color:rgba(0,0,0,.4)}.woocommerce p.stars a{color:rgba(0,0,0,.4)}.woocommerce p.stars.selected a:before{color:#ffa200}.woocommerce ul.products li.product .price del{display:inline;padding-right:10px}ul.products .woocommerce-text-align-right{text-align:right}.woocommerce #content div.product div.images,.woocommerce div.product div.images,.woocommerce-page #content div.product div.images,.woocommerce-page div.product div.images{width:50%}.woocommerce #content div.product div.summary,.woocommerce div.product div.summary,.woocommerce-page #content div.product div.summary,.woocommerce-page div.product div.summary{width:auto;float:none;overflow:hidden}.product_meta{font-size:80%;border-top:1px solid rgba(0,0,0,.1);padding-top:30px}.product_meta>span{display:block}.up-sells{margin-top:40px}.add-to-cart-panel form.cart,.woocommerce div.product.do-quantity-buttons form.cart{display:flex;flex-wrap:wrap}.woocommerce div.product form.cart>:not(.quantity):not(.single_add_to_cart_button){width:100%}.add-to-cart-panel form.cart{flex-shrink:0}.woocommerce .quantity .qty{height:100%;width:auto;max-width:80px;background:0 0;border:1px solid rgba(0,0,0,.1);padding:0 10px;height:50px}.do-quantity-buttons .quantity:not(.buttons-added) .qty{width:50px}.add-to-cart-panel .cart.do-quantity-buttons div.quantity,.do-quantity-buttons div.quantity{display:flex;align-items:center}.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):after,.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):before,.woocommerce form .quantity.buttons-added .minus,.woocommerce form .quantity.buttons-added .plus,.woocommerce form .quantity.buttons-added .qty{display:block;width:50px;height:100%;min-height:50px;background-color:transparent;border:1px solid rgba(0,0,0,.1);margin:0;padding:0;text-align:center;vertical-align:middle;-moz-appearance:textfield!important;-webkit-appearance:none;border-radius:0;color:inherit;box-sizing:border-box;text-decoration:none}.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):after,.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):before,.woocommerce form .quantity.buttons-added .minus,.woocommerce form .quantity.buttons-added .plus{display:flex;align-items:center;justify-content:center}.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):before{content:"-";border-right:0}.do-quantity-buttons form .quantity:not(.buttons-added):not(.hidden):after{content:"+";border-left:0}.woocommerce form .quantity.buttons-added .qty:focus{border-color:rgba(0,0,0,.1)}.do-quantity-buttons form .quantity input[type=number]::-webkit-inner-spin-button,.do-quantity-buttons form .quantity input[type=number]::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}.do-quantity-buttons form .quantity:not(.buttons-added):before,.woocommerce form .quantity.buttons-added .minus{border-right-width:0}.do-quantity-buttons form .quantity:not(.buttons-added):after,.woocommerce form .quantity.buttons-added .plus{border-left-width:0}.do-quantity-buttons .elementor-add-to-cart form .quantity:not(.buttons-added):after,.do-quantity-buttons .elementor-add-to-cart form .quantity:not(.buttons-added):before,.do-quantity-buttons form .quantity.hidden{display:none}.woocommerce div.product form.cart div.quantity.hidden{margin:0}.woocommerce div.product .woocommerce-tabs ul.tabs li::after,.woocommerce div.product .woocommerce-tabs ul.tabs li::before,.woocommerce div.product .woocommerce-tabs ul.tabs::before{display:none;border:0}.woocommerce div.product .woocommerce-tabs ul.tabs{display:flex;margin-left:0;padding-left:0}.woocommerce div.product .woocommerce-tabs ul.tabs li{background-color:rgba(0,0,0,.02);margin:0;border-radius:0;border-width:1px 1px 0 0;border-color:rgba(0,0,0,.08)}.woocommerce div.product .woocommerce-tabs ul.tabs li:first-child{border-left-width:1px}.woocommerce-ordering{float:left;margin-right:1em;margin-bottom:0;position:relative;padding:0}nav li.wc-menu-item{float:right}.cart-contents>span{line-height:0}.cart-contents>span:not(:empty){margin-left:10px}.rtl .cart-contents>span:not(:empty){margin-left:0;margin-right:10px}.cart-contents>span.gp-icon{margin-left:0}.rtl .cart-contents>span.gp-icon{margin-right:0}nav span.count{font-size:.8em;opacity:.5}.woocommerce a.remove{color:inherit!important;background:0 0!important;border:1px solid!important;border-color:inherit;font-weight:400;font-size:16px;width:20px;height:20px;line-height:17px;font-family:-apple-system,system-ui,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol"!important}.woocommerce a.remove:hover{color:inherit!important;background:0 0!important;opacity:.7}.woocommerce .star-rating:before{opacity:.25;content:"SSSSS"}.woocommerce div.product .woocommerce-product-rating{margin:1em 0}.woocommerce div.product p.price,.woocommerce div.product span.price{color:inherit}.wc-has-gallery .secondary-image{position:absolute;opacity:0;transition:opacity .1s ease-in-out;left:50%;transform:translate(-50%,0);top:0}.wc-has-gallery picture.secondary-image{width:100%;height:100%}.wc-product-image:hover .secondary-image{opacity:1}.woocommerce ul.products li.product a img{margin-bottom:0}.woocommerce div.product .woocommerce-tabs ul.tabs li a,.woocommerce div.product .woocommerce-tabs ul.tabs li.active a{color:initial}.woocommerce div.product p.price,.woocommerce ul.products li.product .price{font-weight:700}div.woocommerce-error a.button,div.woocommerce-error a.button:focus,div.woocommerce-error a.button:hover,div.woocommerce-info a.button,div.woocommerce-info a.button:focus,div.woocommerce-info a.button:hover,div.woocommerce-message a.button,div.woocommerce-message a.button:focus,div.woocommerce-message a.button:hover{background:0 0;padding:0}.woocommerce-error a,.woocommerce-info a,.woocommerce-message a{font-weight:700}.woocommerce-error,.woocommerce-info,.woocommerce-message{padding:20px 30px;border:0;border-left:10px solid rgba(0,0,0,.3)}.woocommerce-error::before,.woocommerce-info::before,.woocommerce-message::before{display:none}a.button.wc-forward:after{content:"\e901";font-family:"GP Premium";line-height:1em;padding-left:10px;position:relative;top:2px}.rtl a.button.wc-forward:after{display:none}.woocommerce-checkout .col2-set .col-1,.woocommerce-checkout .col2-set .col-2{float:none;width:100%;margin:0}.woocommerce-checkout .col2-set{width:52.9411764706%;float:left;margin-right:5.8823529412%}.rtl.woocommerce-checkout .col2-set{float:right;margin-right:0;margin-left:5.8823529412%}#customer_details+#wc_checkout_add_ons,#order_review,#order_review_heading{width:41.1764705882%;float:right;margin-right:0}.woocommerce-additional-fields>h3{margin-top:20px}.woocommerce table.shop_table,.woocommerce table.shop_table tfoot td,.woocommerce table.shop_table tfoot th{border:0;border-radius:0}.woocommerce table.shop_table th{background-color:rgba(0,0,0,.03)}.woocommerce table.shop_table td,.woocommerce table.shop_table th{padding:20px;border:0}.woocommerce table.shop_table td{background-color:rgba(0,0,0,.005);border-bottom:1px solid rgba(0,0,0,.1)}#add_payment_method .cart-collaterals .cart_totals tr td,#add_payment_method .cart-collaterals .cart_totals tr th,.woocommerce-cart .cart-collaterals .cart_totals tr td,.woocommerce-cart .cart-collaterals .cart_totals tr th,.woocommerce-checkout .cart-collaterals .cart_totals tr td,.woocommerce-checkout .cart-collaterals .cart_totals tr th{border-top:0}#add_payment_method #payment,#add_payment_method #payment div.payment_box,.woocommerce-cart #payment,.woocommerce-cart #payment div.payment_box,.woocommerce-checkout #payment,.woocommerce-checkout #payment div.payment_box{background-color:transparent;color:inherit}#add_payment_method #payment div.payment_box:before,.woocommerce-cart #payment div.payment_box:before,.woocommerce-checkout #payment div.payment_box:before{display:none}#payment .payment_methods>.wc_payment_method>label{padding:20px;background-color:rgba(0,0,0,.04);display:block;cursor:pointer}#payment .payment_methods li.wc_payment_method>input[type=radio]:first-child:checked+label{font-weight:700;background-color:rgba(0,0,0,.07)}#payment .payment_methods li.wc_payment_method>input[type=radio]:first-child{clip:rect(1px,1px,1px,1px);position:absolute!important}#payment .payment_methods>.wc_payment_method>label:before{display:inline-block;font-size:inherit;-webkit-font-smoothing:antialiased;content:"\e902";margin-right:.5407911001em;transition:color,ease,.2s;font-family:"GP Premium"}#payment .payment_methods li.wc_payment_method>input[type=radio]:first-child:checked+label:before{content:"\e904"}#add_payment_method #payment ul.payment_methods,.woocommerce-cart #payment ul.payment_methods,.woocommerce-checkout #payment ul.payment_methods{padding:0;border:0}.woocommerce #payment #place_order,.woocommerce-page #payment #place_order{float:none;width:100%;padding-top:20px;padding-bottom:20px;font-weight:700;font-size:150%}#add_payment_method #payment div.form-row,.woocommerce-cart #payment div.form-row,.woocommerce-checkout #payment div.form-row{padding-left:0;padding-right:0;padding-top:0}#add_payment_method #payment ul.payment_methods li img,.woocommerce-cart #payment ul.payment_methods li img,.woocommerce-checkout #payment ul.payment_methods li img{float:right}#add_payment_method #payment .payment_method_paypal .about_paypal,.woocommerce-cart #payment .payment_method_paypal .about_paypal,.woocommerce-checkout #payment .payment_method_paypal .about_paypal{float:none;display:inline-block;line-height:1}a.checkout-button:after{display:none}.woocommerce #content table.cart td.actions .input-text,.woocommerce table.cart td.actions .input-text,.woocommerce-page #content table.cart td.actions .input-text,.woocommerce-page table.cart td.actions .input-text{width:150px;padding:10px 15px}.woocommerce .coupon .button{border:1px solid transparent}.woocommerce ul.products li.product .woocommerce-product-details__short-description p:last-child{margin-bottom:0}.wc-product-image{text-align:center}.woocommerce-text-align-left .wc-product-image{text-align:left}.woocommerce-text-align-right .wc-product-image{text-align:right}.inside-wc-product-image{position:relative;display:inline-block}.woocommerce ul.products li.product.woocommerce-image-align-left .wc-product-image{float:left;margin-right:2em}.woocommerce ul.products li.product.woocommerce-image-align-right .wc-product-image{float:right;margin-left:2em}.woocommerce ul.products li.product.woocommerce-image-align-left a .wc-product-image img,.woocommerce ul.products li.product.woocommerce-image-align-right a .wc-product-image img{width:auto}.woocommerce-cart ul.products li.product.woocommerce-image-align-left .wc-product-image,.woocommerce-cart ul.products li.product.woocommerce-image-align-right .wc-product-image{float:none;margin:0}.woocommerce-cart ul.products li.product.woocommerce-image-align-left a .wc-product-image img,.woocommerce-cart ul.products li.product.woocommerce-image-align-right a .wc-product-image img{width:100%}.woocommerce .widget_price_filter .price_slider_amount .button{font-size:1em;line-height:normal}.woocommerce .related ul.products li.product a img,.woocommerce .up-sells ul.products li.product a img{margin-bottom:0}.woocommerce-review-link{font-size:80%}.woocommerce-Reviews .comment-reply-title{font-size:120%;font-weight:700;display:block;margin-bottom:10px}.woocommerce-MyAccount-navigation ul{margin:0;border-top:1px solid rgba(0,0,0,.1)}.site-main .woocommerce-MyAccount-navigation li{margin:0;padding:0}.woocommerce-MyAccount-navigation li a{display:block;padding:20px 0;border-bottom:1px solid rgba(0,0,0,.1);font-size:85%}.woocommerce-MyAccount-navigation li.is-active a{font-weight:700}.woocommerce-MyAccount-navigation li a:hover{border-bottom:1px solid rgba(0,0,0,.2)}.woocommerce-MyAccount-navigation li.is-active a:after{font-family:"GP Premium";content:"\e901";float:right;font-weight:700;font-size:115%}.woocommerce-account .woocommerce-MyAccount-navigation{width:25%}.woocommerce #payment .terms{padding:20px}h2.woocommerce-loop-category__title mark{background:0 0;font-size:80%;opacity:.5}.woocommerce form.checkout_coupon,.woocommerce form.login,.woocommerce form.register{padding:0;margin:0 0 1.5em;border:0}#ship-to-different-address{padding:3px;font-size:inherit}.woocommerce-image-align-left .products ul,.woocommerce-image-align-left .products ul:after,.woocommerce-image-align-left ul.products,.woocommerce-image-align-left ul.products:after,.woocommerce-image-align-right .products ul,.woocommerce-image-align-right .products ul:after,.woocommerce-image-align-right ul.products,.woocommerce-image-align-right ul.products:after{clear:none}.woocommerce nav.woocommerce-pagination{margin-top:60px;clear:both}.woocommerce input.button:disabled,.woocommerce input.button:disabled:hover,.woocommerce input.button:disabled[disabled],.woocommerce input.button:disabled[disabled]:hover{background-color:transparent;color:initial;opacity:.3}.entry-summary+.up-sells{clear:both}.woocommerce form .form-row input.input-text,.woocommerce form .form-row textarea{line-height:1.5}.main-navigation a.cart-contents:not(.has-svg-icon):before,.secondary-navigation a.cart-contents:not(.has-svg-icon):before{content:"\f07a";display:inline-block;font-family:"GP Premium";font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.main-navigation a.cart-contents:not(.has-svg-icon).shopping-bag:before,.secondary-navigation a.cart-contents:not(.has-svg-icon).shopping-bag:before{content:"\f290"}.main-navigation a.cart-contents:not(.has-svg-icon).shopping-basket:before,.secondary-navigation a.cart-contents:not(.has-svg-icon).shopping-basket:before{content:"\f291"}.cart-contents>span.number-of-items{font-size:11px;display:inline-block;background:rgba(255,255,255,.1);line-height:1.7em;height:1.7em;width:1.7em;text-align:center;border-radius:50%;margin-left:5px;position:relative;top:-5px;display:none}.cart-contents>span.number-of-items.no-items{display:none}.woocommerce-MyAccount-navigation ul{list-style-type:none}form.checkout:after,form.checkout:before{content:'';display:table}form.checkout:after{clear:both}.add-to-cart-panel{position:fixed;top:0;left:0;right:0;background:#fff;padding:20px;opacity:0;transition:opacity .5s ease-in-out,transform .5s ease-in-out;box-shadow:0 2px 2px -2px rgba(0,0,0,.2);z-index:101;font-size:90%;box-sizing:border-box;transform:translateY(-100%)}.add-to-cart-panel.item-added,.add-to-cart-panel.show-sticky-add-to-cart{opacity:1}.add-to-cart-panel>div{display:flex;align-items:center}.add-to-cart-panel .continue-shopping{margin-right:auto}.add-to-cart-panel .continue-shopping .gp-icon{display:none}.add-to-cart-panel .cart-info{margin-right:20px}.add-to-cart-panel img{height:50px;width:auto;vertical-align:middle}.add-to-cart-panel .product-title{margin-left:20px;margin-right:auto;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.add-to-cart-panel .product-price{margin-right:20px}.add-to-cart-panel div.quantity{margin-right:4px}.add-to-cart-panel .cart-data{font-size:12px}.add-to-cart-panel del{opacity:.4}.do-quantity-buttons input.qty::-webkit-inner-spin-button,.do-quantity-buttons input.qty::-webkit-outer-spin-button{-webkit-appearance:none}.wc-menu-cart-activated .menu-toggle{text-align:left}.woocommerce-order-received .woocommerce-customer-details .col2-set{float:none;width:auto}.woocommerce-order-received .woocommerce-customer-details .col2-set .col-1{margin-bottom:1.5em} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/customizer/customizer.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/customizer/customizer.php deleted file mode 100644 index a03e0370..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/customizer/customizer.php +++ /dev/null @@ -1,1031 +0,0 @@ -register_control_type( 'GeneratePress_Title_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Pro_Range_Slider_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Information_Customize_Control' ); - $wp_customize->register_control_type( 'GeneratePress_Section_Shortcut_Control' ); - } - - $wp_customize->add_section( - 'generate_woocommerce_layout', - array( - 'title' => __( 'WooCommerce', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 100, - 'panel' => 'generate_layout_panel' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Section_Shortcut_Control( - $wp_customize, - 'generate_woocommerce_layout_shortcuts', - array( - 'section' => 'generate_woocommerce_layout', - 'element' => __( 'WooCommerce', 'gp-premium' ), - 'shortcuts' => array( - 'colors' => 'generate_woocommerce_colors', - 'typography' => 'generate_woocommerce_typography', - ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname', - 'priority' => 0, - ) - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_general_title', - array( - 'section' => 'generate_woocommerce_layout', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'General', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname' - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[cart_menu_item]', - array( - 'default' => $defaults['cart_menu_item'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[cart_menu_item]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display cart in menu', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[cart_menu_item]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[menu_mini_cart]', - array( - 'default' => $defaults['menu_mini_cart'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[menu_mini_cart]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display mini cart sub-menu', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[menu_mini_cart]', - 'active_callback' => 'generate_premium_wc_menu_item_active', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[cart_menu_item_icon]', - array( - 'default' => $defaults['cart_menu_item_icon'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[cart_menu_item_icon]', - array( - 'type' => 'select', - 'label' => __( 'Menu Item Icon', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'choices' => array( - 'shopping-cart' => __( 'Shopping Cart', 'gp-premium' ), - 'shopping-bag' => __( 'Shopping Bag', 'gp-premium' ), - 'shopping-basket' => __( 'Shopping Basket', 'gp-premium' ), - ), - 'settings' => 'generate_woocommerce_settings[cart_menu_item_icon]', - 'active_callback' => 'generatepress_wc_menu_cart_active', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[cart_menu_item_content]', - array( - 'default' => $defaults['cart_menu_item_content'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[cart_menu_item_content]', - array( - 'type' => 'select', - 'label' => __( 'Menu Item Content', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'choices' => array( - 'amount' => __( 'Amount', 'gp-premium' ), - 'number' => __( 'Number of Items', 'gp-premium' ), - ), - 'settings' => 'generate_woocommerce_settings[cart_menu_item_content]', - 'active_callback' => 'generatepress_wc_menu_cart_active', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[breadcrumbs]', - array( - 'default' => $defaults['breadcrumbs'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[breadcrumbs]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display breadcrumbs', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[breadcrumbs]', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_shop_page_title', - array( - 'section' => 'generate_woocommerce_layout', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Shop', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname' - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[sidebar_layout]', - array( - 'default' => $defaults['sidebar_layout'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[sidebar_layout]', - array( - 'type' => 'select', - 'label' => __( 'Sidebar Layout', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'choices' => array( - 'left-sidebar' => __( 'Sidebar / Content', 'gp-premium' ), - 'right-sidebar' => __( 'Content / Sidebar', 'gp-premium' ), - 'no-sidebar' => __( 'Content (no sidebars)', 'gp-premium' ), - 'both-sidebars' => __( 'Sidebar / Content / Sidebar', 'gp-premium' ), - 'both-left' => __( 'Sidebar / Sidebar / Content', 'gp-premium' ), - 'both-right' => __( 'Content / Sidebar / Sidebar', 'gp-premium' ) - ), - 'settings' => 'generate_woocommerce_settings[sidebar_layout]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[columns]', array( - 'default' => $defaults['columns'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[tablet_columns]', array( - 'default' => $defaults['tablet_columns'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[mobile_columns]', array( - 'default' => $defaults['mobile_columns'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'gp_woocommerce_columns', - array( - 'label' => __( 'Product Columns', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => array( - 'desktop' => 'generate_woocommerce_settings[columns]', - 'tablet' => 'generate_woocommerce_settings[tablet_columns]', - 'mobile' => 'generate_woocommerce_settings[mobile_columns]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 1, - 'max' => 6, - 'step' => 1, - 'edit' => false, - 'unit' => 'Col', - ), - 'tablet' => array( - 'min' => 1, - 'max' => 3, - 'step' => 1, - 'edit' => false, - 'unit' => 'Col', - ), - 'mobile' => array( - 'min' => 1, - 'max' => 3, - 'step' => 1, - 'edit' => false, - 'unit' => 'Col', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[columns_gap]', array( - 'default' => $defaults['columns_gap'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[tablet_columns_gap]', array( - 'default' => $defaults['tablet_columns_gap'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint' - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[mobile_columns_gap]', array( - 'default' => $defaults['mobile_columns_gap'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'generate_premium_sanitize_empty_absint' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'gp_woocommerce_column_gap', - array( - 'label' => __( 'Column Gap', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => array( - 'desktop' => 'generate_woocommerce_settings[columns_gap]', - 'tablet' => 'generate_woocommerce_settings[tablet_columns_gap]', - 'mobile' => 'generate_woocommerce_settings[mobile_columns_gap]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 0, - 'max' => 100, - 'step' => 5, - 'edit' => true, - 'unit' => 'px', - ), - 'tablet' => array( - 'min' => 0, - 'max' => 100, - 'step' => 5, - 'edit' => true, - 'unit' => 'px', - ), - 'mobile' => array( - 'min' => 0, - 'max' => 100, - 'step' => 5, - 'edit' => true, - 'unit' => 'px', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_image_alignment]', - array( - 'default' => $defaults['product_archive_image_alignment'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_image_alignment]', - array( - 'type' => 'radio', - 'label' => __( 'Image Alignment', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'choices' => array( - 'left' => __( 'Left', 'gp-premium' ), - 'center' => __( 'Center', 'gp-premium' ), - 'right' => __( 'Right', 'gp-premium' ), - ), - 'settings' => 'generate_woocommerce_settings[product_archive_image_alignment]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[products_per_page]', - array( - 'default' => $defaults['products_per_page'], - 'type' => 'option', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[products_per_page]', - array( - 'type' => 'text', - 'label' => __( 'Products Per Page', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[products_per_page]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_alignment]', - array( - 'default' => $defaults['product_archive_alignment'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_alignment]', - array( - 'type' => 'radio', - 'label' => __( 'Text Alignment', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'choices' => array( - 'left' => __( 'Left', 'gp-premium' ), - 'center' => __( 'Center', 'gp-premium' ), - 'right' => __( 'Right', 'gp-premium' ), - ), - 'settings' => 'generate_woocommerce_settings[product_archive_alignment]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[off_canvas_panel_on_add_to_cart]', - array( - 'default' => $defaults['off_canvas_panel_on_add_to_cart'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[off_canvas_panel_on_add_to_cart]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display cart panel on add to cart', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[off_canvas_panel_on_add_to_cart]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[shop_page_title]', - array( - 'default' => $defaults['shop_page_title'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[shop_page_title]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display page title', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[shop_page_title]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_results_count]', - array( - 'default' => $defaults['product_results_count'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_results_count]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display product results count', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_results_count]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_sorting]', - array( - 'default' => $defaults['product_sorting'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_sorting]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display product sorting', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_sorting]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_image]', - array( - 'default' => $defaults['product_archive_image'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_image]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display product image', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_image]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_secondary_image]', - array( - 'default' => $defaults['product_secondary_image'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_secondary_image]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display secondary image on hover', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_secondary_image]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_title]', - array( - 'default' => $defaults['product_archive_title'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_title]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display product title', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_title]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_sale_flash]', - array( - 'default' => $defaults['product_archive_sale_flash'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_sale_flash]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display sale flash', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_sale_flash]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_sale_flash_overlay]', - array( - 'default' => $defaults['product_archive_sale_flash_overlay'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_sale_flash_overlay]', - array( - 'type' => 'checkbox', - 'label' => __( 'Sale flash over image', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_sale_flash_overlay]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_rating]', - array( - 'default' => $defaults['product_archive_rating'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_rating]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display rating', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_rating]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_price]', - array( - 'default' => $defaults['product_archive_price'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_price]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display price', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_price]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_add_to_cart]', - array( - 'default' => $defaults['product_archive_add_to_cart'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_add_to_cart]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display add to cart button', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_add_to_cart]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_archive_description]', - array( - 'default' => $defaults['product_archive_description'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_archive_description]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display short description', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_archive_description]', - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_single_product_title', - array( - 'section' => 'generate_woocommerce_layout', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Single Product', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname' - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[single_sidebar_layout]', - array( - 'default' => $defaults['single_sidebar_layout'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_choices' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[single_sidebar_layout]', - array( - 'type' => 'select', - 'label' => __( 'Sidebar Layout', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'choices' => array( - 'inherit' => __( 'Inherit', 'gp-premium' ), - 'left-sidebar' => __( 'Sidebar / Content', 'gp-premium' ), - 'right-sidebar' => __( 'Content / Sidebar', 'gp-premium' ), - 'no-sidebar' => __( 'Content (no sidebars)', 'gp-premium' ), - 'both-sidebars' => __( 'Sidebar / Content / Sidebar', 'gp-premium' ), - 'both-left' => __( 'Sidebar / Sidebar / Content', 'gp-premium' ), - 'both-right' => __( 'Content / Sidebar / Sidebar', 'gp-premium' ) - ), - 'settings' => 'generate_woocommerce_settings[single_sidebar_layout]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[single_product_image_width]', array( - 'default' => $defaults['single_product_image_width'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'gp_woocommerce_single_product_image_width', - array( - 'label' => __( 'Product Image Area Width', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => array( - 'desktop' => 'generate_woocommerce_settings[single_product_image_width]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 10, - 'max' => 100, - 'step' => 5, - 'edit' => true, - 'unit' => '%', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[sticky_add_to_cart_panel]', - array( - 'default' => $defaults['sticky_add_to_cart_panel'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[sticky_add_to_cart_panel]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display add to cart panel on scroll', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[sticky_add_to_cart_panel]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[quantity_buttons]', - array( - 'default' => $defaults['quantity_buttons'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[quantity_buttons]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display quantity buttons', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[quantity_buttons]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[single_product_sale_flash]', - array( - 'default' => $defaults['single_product_sale_flash'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[single_product_sale_flash]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display sale flash', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[single_product_sale_flash]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_tabs]', - array( - 'default' => $defaults['product_tabs'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_tabs]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display product tabs', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_tabs]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_related]', - array( - 'default' => $defaults['product_related'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_related]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display related products', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_related]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_upsells]', - array( - 'default' => $defaults['product_upsells'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_upsells]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display upsell products', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_upsells]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[related_upsell_columns]', array( - 'default' => $defaults['related_upsell_columns'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[tablet_related_upsell_columns]', array( - 'default' => $defaults['tablet_related_upsell_columns'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[mobile_related_upsell_columns]', array( - 'default' => $defaults['mobile_related_upsell_columns'], - 'type' => 'option', - 'capability' => 'edit_theme_options', - 'sanitize_callback' => 'absint' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Pro_Range_Slider_Control( - $wp_customize, - 'gp_woocommerce_related_upsell_columns', - array( - 'label' => __( 'Related/Upsell Columns', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => array( - 'desktop' => 'generate_woocommerce_settings[related_upsell_columns]', - 'tablet' => 'generate_woocommerce_settings[tablet_related_upsell_columns]', - 'mobile' => 'generate_woocommerce_settings[mobile_related_upsell_columns]', - ), - 'choices' => array( - 'desktop' => array( - 'min' => 1, - 'max' => 6, - 'step' => 1, - 'edit' => false, - 'unit' => 'Col', - ), - 'tablet' => array( - 'min' => 1, - 'max' => 3, - 'step' => 1, - 'edit' => false, - 'unit' => 'Col', - ), - 'mobile' => array( - 'min' => 1, - 'max' => 3, - 'step' => 1, - 'edit' => false, - 'unit' => 'Col', - ), - ), - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_meta]', - array( - 'default' => $defaults['product_meta'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_meta]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display product meta data', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_meta]', - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[product_description]', - array( - 'default' => $defaults['product_description'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[product_description]', - array( - 'type' => 'checkbox', - 'label' => __( 'Display short description', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[product_description]', - ) - ); - - $wp_customize->add_section( - 'generate_woocommerce_colors', - array( - 'title' => __( 'WooCommerce', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 200, - 'panel' => 'generate_colors_panel' - ) - ); - - $wp_customize->add_section( - 'generate_woocommerce_typography', - array( - 'title' => __( 'WooCommerce', 'gp-premium' ), - 'capability' => 'edit_theme_options', - 'priority' => 200, - 'panel' => 'generate_typography_panel' - ) - ); - - $wp_customize->add_control( - new GeneratePress_Title_Customize_Control( - $wp_customize, - 'generate_woocommerce_checkout_title', - array( - 'section' => 'generate_woocommerce_layout', - 'type' => 'generatepress-customizer-title', - 'title' => __( 'Checkout', 'gp-premium' ), - 'settings' => ( isset( $wp_customize->selective_refresh ) ) ? array() : 'blogname' - ) - ) - ); - - $wp_customize->add_setting( - 'generate_woocommerce_settings[distraction_free]', - array( - 'default' => $defaults['distraction_free'], - 'type' => 'option', - 'sanitize_callback' => 'generate_premium_sanitize_checkbox' - ) - ); - - $wp_customize->add_control( - 'generate_woocommerce_settings[distraction_free]', - array( - 'type' => 'checkbox', - 'label' => __( 'Distraction-free mode', 'gp-premium' ), - 'description' => __( 'Remove unnecessary distractions like sidebars, footer widgets and sticky menus.', 'gp-premium' ), - 'section' => 'generate_woocommerce_layout', - 'settings' => 'generate_woocommerce_settings[distraction_free]', - ) - ); - -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/customizer/js/customizer.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/customizer/js/customizer.js deleted file mode 100644 index a455a2f7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/customizer/js/customizer.js +++ /dev/null @@ -1,6 +0,0 @@ -jQuery( function( $ ) { - $( '#customize-control-generate_woocommerce_primary_button_message a' ).on( 'click', function( e ) { - e.preventDefault(); - wp.customize.control( 'generate_settings[form_button_background_color]' ).focus(); - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/functions.php b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/functions.php deleted file mode 100644 index b22c8ae8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/functions.php +++ /dev/null @@ -1,1571 +0,0 @@ - true, - 'cart_menu_item_icon' => 'shopping-cart', - 'cart_menu_item_content' => 'amount', - 'menu_mini_cart' => false, - 'off_canvas_panel_on_add_to_cart' => false, - 'sticky_add_to_cart_panel' => false, - 'sidebar_layout' => 'right-sidebar', - 'single_sidebar_layout' => 'inherit', - 'products_per_page' => 9, - 'columns' => 4, - 'tablet_columns' => 2, - 'mobile_columns' => 1, - 'columns_gap' => 50, - 'tablet_columns_gap' => '', - 'mobile_columns_gap' => '', - 'related_upsell_columns' => 4, - 'tablet_related_upsell_columns' => 2, - 'mobile_related_upsell_columns' => 1, - 'product_archive_image_alignment' => 'center', - 'product_archive_alignment' => 'center', - 'shop_page_title' => true, - 'product_results_count' => true, - 'product_sorting' => true, - 'product_archive_image' => true, - 'product_secondary_image' => true, - 'product_archive_title' => true, - 'product_archive_sale_flash' => true, - 'product_archive_sale_flash_overlay' => true, - 'product_archive_rating' => true, - 'product_archive_price' => true, - 'product_archive_add_to_cart' => true, - 'single_product_sale_flash' => true, - 'single_product_image_width' => '50', - 'product_tabs' => true, - 'product_related' => true, - 'product_upsells' => true, - 'product_meta' => true, - 'product_description' => true, - 'quantity_buttons' => true, - 'breadcrumbs' => true, - 'distraction_free' => true, - 'product_archive_description' => false, - ) ); -} - -add_filter( 'generate_color_option_defaults', 'generatepress_wc_color_defaults' ); -/** - * Set the WC color option defaults. - * - * @since 1.3 - */ -function generatepress_wc_color_defaults( $defaults ) { - $defaults[ 'wc_alt_button_background' ] = '#1e73be'; - $defaults[ 'wc_alt_button_background_hover' ] = '#377fbf'; - $defaults[ 'wc_alt_button_text' ] = '#ffffff'; - $defaults[ 'wc_alt_button_text_hover' ] = '#ffffff'; - $defaults[ 'wc_rating_stars' ] = '#ffa200'; - $defaults[ 'wc_sale_sticker_background' ] = '#222222'; - $defaults[ 'wc_sale_sticker_text' ] = '#ffffff'; - $defaults[ 'wc_price_color' ] = '#222222'; - $defaults[ 'wc_product_tab' ] = '#222222'; - $defaults[ 'wc_product_tab_highlight' ] = '#1e73be'; - $defaults[ 'wc_success_message_background' ] = '#0b9444'; - $defaults[ 'wc_success_message_text' ] = '#ffffff'; - $defaults[ 'wc_info_message_background' ] = '#1e73be'; - $defaults[ 'wc_info_message_text' ] = '#ffffff'; - $defaults[ 'wc_error_message_background' ] = '#e8626d'; - $defaults[ 'wc_error_message_text' ] = '#ffffff'; - $defaults[ 'wc_product_title_color' ] = ''; - $defaults[ 'wc_product_title_color_hover' ] = ''; - - $defaults['wc_mini_cart_background_color'] = '#ffffff'; - $defaults['wc_mini_cart_text_color'] = '#000000'; - $defaults['wc_mini_cart_button_background'] = ''; - $defaults['wc_mini_cart_button_text'] = ''; - $defaults['wc_mini_cart_button_background_hover'] = ''; - $defaults['wc_mini_cart_button_text_hover'] = ''; - - $defaults['wc_panel_cart_background_color'] = '#ffffff'; - $defaults['wc_panel_cart_text_color'] = '#000000'; - $defaults['wc_panel_cart_button_background'] = ''; - $defaults['wc_panel_cart_button_text'] = ''; - $defaults['wc_panel_cart_button_background_hover'] = ''; - $defaults['wc_panel_cart_button_text_hover'] = ''; - - $defaults['wc_price_slider_background_color'] = '#dddddd'; - $defaults['wc_price_slider_bar_color'] = '#666666'; - - return $defaults; -} - -add_filter( 'generate_font_option_defaults', 'generatepress_wc_typography_defaults' ); -/** - * Set the WC typography option defaults. - * - * @since 1.3 - */ -function generatepress_wc_typography_defaults( $defaults ) { - $defaults[ 'wc_product_title_font_weight' ] = 'normal'; - $defaults[ 'wc_product_title_font_transform' ] = 'none'; - $defaults[ 'wc_product_title_font_size' ] = '20'; - $defaults[ 'mobile_wc_product_title_font_size' ] = ''; - $defaults[ 'wc_related_product_title_font_size' ] = '20'; - return $defaults; -} - -add_filter( 'generate_navigation_class', 'generatepress_wc_navigation_class' ); -/** - * Add navigation class when the menu icon is enabled. - * - * @since 1.3 - */ -function generatepress_wc_navigation_class( $classes ) { - $classes[] = ( generatepress_wc_get_setting( 'cart_menu_item' ) ) ? 'wc-menu-cart-activated' : ''; - return $classes; -} - -add_filter( 'post_class', 'generatepress_wc_post_class' ); -add_filter( 'product_cat_class', 'generatepress_wc_post_class' ); -/** - * Add post classes to the products. - * - * @since 1.3 - * - * @param array $classes Existing product classes. - * @return array - */ -function generatepress_wc_post_class( $classes ) { - if ( 'product' == get_post_type() ) { - $classes[] = ( generatepress_wc_get_setting( 'product_archive_sale_flash_overlay' ) && generatepress_wc_get_setting( 'product_archive_image' ) ) ? 'sales-flash-overlay' : ''; - $classes[] = 'woocommerce-text-align-' . generatepress_wc_get_setting( 'product_archive_alignment' ); - - if ( is_single() ) { - $classes[] = 'wc-related-upsell-columns-' . generatepress_wc_get_setting( 'related_upsell_columns' ); - $classes[] = 'wc-related-upsell-tablet-columns-' . generatepress_wc_get_setting( 'tablet_related_upsell_columns' ); - $classes[] = 'wc-related-upsell-mobile-columns-' . generatepress_wc_get_setting( 'mobile_related_upsell_columns' ); - } else { - $classes[] = 'woocommerce-image-align-' . generatepress_wc_get_setting( 'product_archive_image_alignment' ); - } - } - - if ( 'product' === get_post_type() || is_cart() ) { - if ( generatepress_wc_get_setting( 'quantity_buttons' ) ) { - $classes[] = 'do-quantity-buttons'; - $product = wc_get_product( get_the_ID() ); - - $check_stock = is_callable( array( $product, 'managing_stock' ) ) && - is_callable( array( $product, 'get_stock_quantity' ) ) && - is_callable( array( $product, 'backorders_allowed' ) ) && - is_callable( array( $product, 'is_sold_individually' ) ) && - function_exists( 'is_product' ) && - is_product() && - defined( 'WC_VERSION' ); - - if ( $check_stock && version_compare( WC_VERSION, '7.4.0', '>=' ) ) { - $managing_stock = $product->managing_stock(); - $stock_quantity = $product->get_stock_quantity(); - $backorders_allowed = $product->backorders_allowed(); - $sold_individually = $product->is_sold_individually(); - - if ( $sold_individually || ( $managing_stock && $stock_quantity < 2 && ! $backorders_allowed ) ) { - $classes = array_diff( $classes, array( 'do-quantity-buttons' ) ); - } - } - } - } - - return $classes; -} - -add_action( 'woocommerce_before_shop_loop', 'generatepress_wc_before_shop_loop' ); -/** - * Add opening element inside shop page. - * - * @since 1.3 - */ -function generatepress_wc_before_shop_loop() { - $classes = apply_filters( 'generate_woocommerce_container_classes', array( - 'wc-columns-container', - 'wc-columns-' . generatepress_wc_get_setting( 'columns' ), - 'wc-tablet-columns-' . generatepress_wc_get_setting( 'tablet_columns' ), - 'wc-mobile-columns-' . generatepress_wc_get_setting( 'mobile_columns' ), - ) ); - - $classes = array_map('esc_attr', $classes); - echo '
            '; -} - -add_action( 'woocommerce_after_shop_loop', 'generatepress_wc_after_shop_loop' ); -/** - * Add closing element inside shop page. - * - * @since 1.3 - */ -function generatepress_wc_after_shop_loop() { - echo '
            '; -} - -add_action( 'wp_enqueue_scripts', 'generatepress_wc_scripts', 100 ); -/** - * Add scripts and styles. - * - * @since 1.3 - */ -function generatepress_wc_scripts() { - if ( ! function_exists( 'is_checkout' ) ) { - return; - } - - $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min'; - wp_enqueue_style( 'generate-woocommerce', plugin_dir_url( __FILE__ ) . "css/woocommerce{$suffix}.css", array(), GENERATE_WOOCOMMERCE_VERSION ); - wp_enqueue_style( 'generate-woocommerce-mobile', plugin_dir_url( __FILE__ ) . "css/woocommerce-mobile{$suffix}.css", array(), GENERATE_WOOCOMMERCE_VERSION, generate_premium_get_media_query( 'mobile' ) ); - - if ( - generatepress_wc_get_setting( 'cart_menu_item' ) || - generatepress_wc_get_setting( 'off_canvas_panel_on_add_to_cart' ) || - generatepress_wc_show_sticky_add_to_cart() || - generatepress_wc_get_setting( 'quantity_buttons' ) - ) { - wp_enqueue_script( 'generate-woocommerce', plugin_dir_url( __FILE__ ) . "js/woocommerce{$suffix}.js", array( 'jquery' ), GENERATE_WOOCOMMERCE_VERSION, true ); - } - - $show_add_to_cart_panel = false; - - if ( ! is_singular() && generatepress_wc_get_setting( 'off_canvas_panel_on_add_to_cart' ) ) { - $show_add_to_cart_panel = true; - } - - wp_localize_script( - 'generate-woocommerce', - 'generateWooCommerce', - array( - 'quantityButtons' => generatepress_wc_get_setting( 'quantity_buttons' ), - 'stickyAddToCart' => generatepress_wc_show_sticky_add_to_cart(), - 'addToCartPanel' => apply_filters( 'generate_woocommerce_show_add_to_cart_panel', $show_add_to_cart_panel ), - ) - ); - - if ( generatepress_wc_get_setting( 'distraction_free' ) && is_checkout() ) { - wp_dequeue_script( 'generate-advanced-sticky' ); - wp_dequeue_script( 'generate-sticky' ); - } - - $font_icons = true; - - if ( function_exists( 'generate_get_option' ) ) { - if ( 'font' !== generate_get_option( 'icons' ) ) { - $font_icons = false; - } - } - - if ( $font_icons ) { - wp_enqueue_style( 'gp-premium-icons' ); - } -} - -/** - * Wrapper class to get the options. - * - * @since 1.3 - * - * @return string $setting The option name. - * @return string The value. - */ -function generatepress_wc_get_setting( $setting ) { - $settings = wp_parse_args( - get_option( 'generate_woocommerce_settings', array() ), - generatepress_wc_defaults() - ); - - return $settings[ $setting ]; -} - -add_filter( 'generate_sidebar_layout', 'generatepress_wc_sidebar_layout' ); -/** - * Set the WC sidebars. - * - * @since 1.3 - * - * @param string Existing layout - * @return string New layout - */ -function generatepress_wc_sidebar_layout( $layout ) { - if ( function_exists( 'is_woocommerce' ) && is_woocommerce() ) { - $layout = generatepress_wc_get_setting( 'sidebar_layout' ); - - if ( is_single() ) { - if ( 'inherit' !== generatepress_wc_get_setting( 'single_sidebar_layout' ) ) { - $layout = generatepress_wc_get_setting( 'single_sidebar_layout' ); - } - - if ( get_post_meta( get_the_ID(), '_generate-sidebar-layout-meta', true ) ) { - $layout = get_post_meta( get_the_ID(), '_generate-sidebar-layout-meta', true ); - } - } - } - - return $layout; -} - -add_filter( 'loop_shop_columns', 'generatepress_wc_product_columns', 999 ); -/** - * Set the WC column number. - * - * @since 1.3 - */ -function generatepress_wc_product_columns() { - return generatepress_wc_get_setting( 'columns' ); -} - -add_filter( 'loop_shop_per_page', 'generatepress_wc_products_per_page', 20 ); -/** - * Set the WC products per page. - * - * @since 1.3 - */ -function generatepress_wc_products_per_page() { - return generatepress_wc_get_setting( 'products_per_page' ); -} - -add_action( 'wp', 'generatepress_wc_setup' ); -/** - * Set up WC. - * - * @since 1.3 - */ -function generatepress_wc_setup() { - - // Add support for WC features - add_theme_support( 'wc-product-gallery-zoom' ); - add_theme_support( 'wc-product-gallery-lightbox' ); - add_theme_support( 'wc-product-gallery-slider' ); - - remove_action( 'wp_enqueue_scripts', 'generate_woocommerce_css', 100 ); - - remove_action( 'woocommerce_before_shop_loop', 'woocommerce_catalog_ordering', 30 ); - add_action( 'woocommerce_before_shop_loop', 'woocommerce_catalog_ordering', 10 ); - - add_action( 'woocommerce_before_shop_loop_item_title', 'generatepress_wc_image_wrapper_open', 8 ); - add_action( 'woocommerce_before_subcategory_title', 'generatepress_wc_image_wrapper_open', 8 ); - add_action( 'woocommerce_shop_loop_item_title', 'generatepress_wc_image_wrapper_close', 8 ); - add_action( 'woocommerce_before_subcategory_title', 'generatepress_wc_image_wrapper_close', 20 ); - - $archive_results_count = generatepress_wc_get_setting( 'product_results_count' ); - $archive_sorting = generatepress_wc_get_setting( 'product_sorting' ); - $archive_image = generatepress_wc_get_setting( 'product_archive_image' ); - $archive_sale_flash = generatepress_wc_get_setting( 'product_archive_sale_flash' ); - $archive_sale_flash_overlay = generatepress_wc_get_setting( 'product_archive_sale_flash_overlay' ); - $archive_rating = generatepress_wc_get_setting( 'product_archive_rating' ); - $archive_price = generatepress_wc_get_setting( 'product_archive_price' ); - $archive_add_to_cart = generatepress_wc_get_setting( 'product_archive_add_to_cart' ); - $archive_title = generatepress_wc_get_setting( 'product_archive_title' ); - $single_product_sale_flash = generatepress_wc_get_setting( 'single_product_sale_flash' ); - $product_tabs = generatepress_wc_get_setting( 'product_tabs' ); - $product_related = generatepress_wc_get_setting( 'product_related' ); - $product_upsells = generatepress_wc_get_setting( 'product_upsells' ); - $product_meta = generatepress_wc_get_setting( 'product_meta' ); - $product_description = generatepress_wc_get_setting( 'product_description' ); - $breadcrumbs = generatepress_wc_get_setting( 'breadcrumbs' ); - $page_title = generatepress_wc_get_setting( 'shop_page_title' ); - $distraction_free = generatepress_wc_get_setting( 'distraction_free' ); - $archive_description = generatepress_wc_get_setting( 'product_archive_description' ); - - if ( false === $page_title ) { - add_filter( 'woocommerce_show_page_title', '__return_false' ); - } - - if ( false === $archive_results_count ) { - remove_action( 'woocommerce_after_shop_loop', 'woocommerce_result_count', 20 ); - remove_action( 'woocommerce_before_shop_loop', 'woocommerce_result_count', 20 ); - } - - if ( false === $archive_sorting ) { - remove_action( 'woocommerce_before_shop_loop', 'woocommerce_catalog_ordering', 10 ); - } - - if ( false === $archive_image ) { - remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_template_loop_product_thumbnail', 10 ); - } - - if ( false === $archive_sale_flash_overlay ) { - remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 10 ); - add_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 6 ); - } - - if ( false === $archive_sale_flash ) { - if ( false === $archive_sale_flash_overlay ) { - remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 6 ); - } else { - remove_action( 'woocommerce_before_shop_loop_item_title', 'woocommerce_show_product_loop_sale_flash', 10 ); - } - } - - if ( false === $single_product_sale_flash ) { - remove_action( 'woocommerce_before_single_product_summary', 'woocommerce_show_product_sale_flash', 10 ); - } - - if ( false === $archive_rating ) { - remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_rating', 5 ); - } - - if ( false === $archive_price ) { - remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_price', 10 ); - } - - if ( false === $archive_add_to_cart ) { - remove_action( 'woocommerce_after_shop_loop_item', 'woocommerce_template_loop_add_to_cart', 10 ); - } - - if ( false === $archive_title ) { - remove_action( 'woocommerce_shop_loop_item_title', 'woocommerce_template_loop_product_title', 10 ); - } - - if ( false === $product_tabs ) { - remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_product_data_tabs', 10 ); - } - - if ( false === $product_related ) { - remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20 ); - } - - if ( false === $product_upsells ) { - remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_upsell_display', 15 ); - } - - if ( false === $product_meta ) { - remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_meta', 40 ); - } - - if ( false === $product_description ) { - remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_excerpt', 20 ); - } - - if ( false === $breadcrumbs ) { - remove_action( 'woocommerce_before_main_content', 'woocommerce_breadcrumb', 20, 0); - } - - if ( true === $distraction_free ) { - add_filter( 'generate_sidebar_layout', 'generatepress_wc_checkout_sidebar_layout' ); - add_filter( 'generate_footer_widgets', 'generatepress_wc_checkout_footer_widgets' ); - } - - if ( true === $archive_description && ! is_single() && ! is_cart() ) { - add_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_single_excerpt', 5 ); - add_action( 'woocommerce_after_subcategory_title', 'generatepress_wc_category_description', 12 ); - } -} - -/** - * Set the WC checkout sidebar layout. - * - * @since 1.3 - * - * @param string $layout Existing sidebar layout. - * @return string New sidebar layout. - */ -function generatepress_wc_checkout_sidebar_layout( $layout ) { - if ( ! function_exists( 'is_checkout' ) ) { - return $layout; - } - - if ( is_checkout() ) { - return 'no-sidebar'; - } - - return $layout; -} - -/** - * Set the WC checkout footer widgets. - * - * @since 1.3 - * - * @param int $widgets Existing number of widgets. - * @return int New number of widgets. - */ -function generatepress_wc_checkout_footer_widgets( $widgets ) { - if ( ! function_exists( 'is_checkout' ) ) { - return $widgets; - } - - if ( is_checkout() ) { - return '0'; - } - - return $widgets; -} - -add_filter( 'wp_nav_menu_items', 'generatepress_wc_menu_cart', 10, 2 ); -/** - * Add the WC cart menu item. - * - * @since 1.3 - * - * @param string $nav The HTML list content for the menu items. - * @param stdClass $args An object containing wp_nav_menu() arguments. - * @return string The search icon menu item. - */ -function generatepress_wc_menu_cart( $nav, $args ) { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - return $nav; - } - - // If our primary menu is set, add the search icon. - if ( apply_filters( 'generate_woocommerce_menu_item_location', 'primary' ) === $args->theme_location && generatepress_wc_get_setting( 'cart_menu_item' ) ) { - if ( ! class_exists( 'WooCommerce' ) ) { - return; - } - - if ( ! isset( WC()->cart ) ) { - return; - } - - $has_items = false; - - if ( ! WC()->cart->is_empty() ) { - $has_items = 'has-items'; - } - - return sprintf( - '%1$s - ', - $nav, - generatepress_wc_cart_link(), - is_cart() ? 'current-menu-item' : '', - $has_items - ); - } - - // Our primary menu isn't set, return the regular nav. - return $nav; -} - -add_action( 'wp', 'generatepress_wc_add_menu_bar_items' ); -/** - * Add to the menu bar items. - * - * @since 1.11.0 - */ -function generatepress_wc_add_menu_bar_items() { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - if ( 'secondary' === apply_filters( 'generate_woocommerce_menu_item_location', 'primary' ) && generatepress_wc_get_setting( 'cart_menu_item' ) ) { - add_action( 'generate_secondary_menu_bar_items', 'generate_wc_do_cart_secondary_menu_item', 5 ); - } - - if ( 'primary' === apply_filters( 'generate_woocommerce_menu_item_location', 'primary' ) && generatepress_wc_get_setting( 'cart_menu_item' ) ) { - add_action( 'generate_menu_bar_items', 'generate_wc_do_cart_menu_item', 5 ); - } - } -} - -/** - * Add the cart menu item to the secondary navigation. - */ -function generate_wc_do_cart_secondary_menu_item() { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - if ( 'secondary' === apply_filters( 'generate_woocommerce_menu_item_location', 'primary' ) && generatepress_wc_get_setting( 'cart_menu_item' ) ) { - if ( ! class_exists( 'WooCommerce' ) ) { - return; - } - - if ( ! isset( WC()->cart ) ) { - return; - } - - $has_items = false; - - if ( ! WC()->cart->is_empty() ) { - $has_items = 'has-items'; - } - - printf( - ' - %1$s - ', - generatepress_wc_cart_link(), - is_cart() ? 'current-menu-item' : '', - $has_items - ); - } - } -} - -/** - * Add the cart menu item to the navigation. - * - * @since 1.11.0 - */ -function generate_wc_do_cart_menu_item() { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - if ( 'primary' === apply_filters( 'generate_woocommerce_menu_item_location', 'primary' ) && generatepress_wc_get_setting( 'cart_menu_item' ) ) { - if ( ! class_exists( 'WooCommerce' ) ) { - return; - } - - if ( ! isset( WC()->cart ) ) { - return; - } - - $has_items = false; - - if ( ! WC()->cart->is_empty() ) { - $has_items = 'has-items'; - } - - printf( - ' - %1$s - ', - generatepress_wc_cart_link(), - is_cart() ? 'current-menu-item' : '', - $has_items - ); - } - } -} - -/** - * Build the menu cart link. - * - * @since 1.3 - */ -function generatepress_wc_cart_link() { - // Kept for backward compatibility. - $legacy_icon = apply_filters( 'generate_woocommerce_menu_cart_icon', '' ); - - // Get the icon type. - $icon_type = generatepress_wc_get_setting( 'cart_menu_item_icon' ); - - $icon = ''; - - if ( function_exists( 'generate_get_svg_icon' ) ) { - $icon = generate_get_svg_icon( $icon_type ); - } - - ob_start(); - - if ( ! class_exists( 'WooCommerce' ) ) { - return; - } - - if ( ! isset( WC()->cart ) ) { - return; - } - - $no_items = ''; - - if ( ! WC()->cart->get_cart_contents_count() > 0 ) { - $no_items = 'no-items'; - } - - printf( - '%5$s%6$s%7$s%8$s', - esc_url( wc_get_cart_url() ), - esc_attr( $icon_type ), - $icon ? 'has-svg-icon' : '', - esc_attr__( 'View your shopping cart', 'gp-premium' ), - $icon, - sprintf( - '%2$s', - $no_items, - WC()->cart->get_cart_contents_count() - ), - $legacy_icon, - WC()->cart->subtotal > 0 ? wp_kses_data( WC()->cart->get_cart_subtotal() ) : '' - ); - - if ( generatepress_wc_get_setting( 'menu_mini_cart' ) && ! is_cart() ) : ?> - - cart ) ) { - $fragments['.cart-contents span.amount'] = ( WC()->cart->subtotal > 0 ) ? '' . wp_kses_data( WC()->cart->get_cart_subtotal() ) . '' : ''; - $fragments['.cart-contents span.number-of-items'] = ( WC()->cart->get_cart_contents_count() > 0 ) ? '' . wp_kses_data( WC()->cart->get_cart_contents_count() ) . '' : ''; - } - - return $fragments; -} - -/** - * Add the cart icon in the mobile menu. - * - * @since 1.3 - */ -function generatepress_wc_mobile_cart_link() { - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - return; - } - - if ( ! generatepress_wc_get_setting( 'cart_menu_item' ) || 'primary' !== apply_filters( 'generate_woocommerce_menu_item_location', 'primary' ) ) { - return; - } - - if ( ! class_exists( 'WooCommerce' ) ) { - return; - } - - if ( ! isset( WC()->cart ) ) { - return; - } - - $has_items = false; - - if ( ! WC()->cart->is_empty() ) { - $has_items = ' has-items'; - } - ?> -
            - - -
            - set_selector( '.woocommerce ul.products li.product .woocommerce-LoopProduct-link' ); - $css->add_property( 'color', esc_attr( $settings['wc_product_title_color'] ) ); - - // Product title color hover. - $css->set_selector( '.woocommerce ul.products li.product .woocommerce-LoopProduct-link:hover' ); - $css->add_property( 'color', esc_attr( $settings['wc_product_title_color_hover'] ) ); - - if ( ! $using_dynamic_typography ) { - // Product title font size. - $css->set_selector( '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title' ); - $css->add_property( 'font-weight', esc_attr( $settings['wc_product_title_font_weight'] ) ); - $css->add_property( 'text-transform', esc_attr( $settings['wc_product_title_font_transform'] ) ); - $css->add_property( 'font-size', esc_attr( $settings['wc_product_title_font_size'] ), false, 'px' ); - - $css->set_selector( '.woocommerce .up-sells ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce .cross-sells ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce .related ul.products li.product .woocommerce-LoopProduct-link h2' ); - if ( '' !== $settings['wc_related_product_title_font_size'] ) { - $css->add_property( 'font-size', esc_attr( $settings['wc_related_product_title_font_size'] ), false, 'px' ); - } - } - - // Primary button. - $css->set_selector( '.woocommerce #respond input#submit, .woocommerce a.button, .woocommerce button.button, .woocommerce input.button, .wc-block-components-button' ); - $css->add_property( 'color', esc_attr( $settings['form_button_text_color'] ) ); - $css->add_property( 'background-color', esc_attr( $settings['form_button_background_color'] ) ); - $css->add_property( 'text-decoration', 'none' ); - - if ( ! $using_dynamic_typography && isset( $settings['buttons_font_size'] ) ) { - $css->add_property( 'font-weight', esc_attr( $settings['buttons_font_weight'] ) ); - $css->add_property( 'text-transform', esc_attr( $settings['buttons_font_transform'] ) ); - - if ( '' !== $settings['buttons_font_size'] ) { - $css->add_property( 'font-size', absint( $settings['buttons_font_size'] ), false, 'px' ); - } - } - - if ( $using_dynamic_typography && class_exists( 'GeneratePress_Typography' ) ) { - $typography = generate_get_option( 'typography' ); - - foreach ( (array) $typography as $key => $data ) { - if ( 'buttons' === $data['selector'] ) { - $unit = isset( $data['fontSizeUnit'] ) ? $data['fontSizeUnit'] : ''; - - if ( ! empty( $data['fontSize'] ) ) { - - // Check for legacy font size values. - // @see https://github.com/tomusborne/generatepress/pull/548. - if ( is_numeric( $data['fontSize'] ) ) { - $data['fontSize'] = floatval( $data['fontSize'] ); - - if ( ! $unit ) { - $unit = 'px'; - } - } - - $css->add_property( 'font-size', esc_attr( $data['fontSize'] ), false, $unit ); - } - - if ( ! empty( $data['fontWeight'] ) ) { - $css->add_property( 'font-weight', esc_attr( $data['fontWeight'] ) ); - } - - if ( ! empty( $data['textTransform'] ) ) { - $css->add_property( 'text-transform', esc_attr( $data['textTransform'] ) ); - } - - if ( ! empty( $data['fontSizeTablet'] ) ) { - $css->start_media_query( generate_premium_get_media_query( 'tablet' ) ); - - // Check for legacy font size values. - // @see https://github.com/tomusborne/generatepress/pull/548. - if ( is_numeric( $data['fontSizeTablet'] ) ) { - $data['fontSizeTablet'] = floatval( $data['fontSizeTablet'] ); - - if ( ! $unit ) { - $unit = 'px'; - } - } - - $css->add_property( 'font-size', esc_attr( $data['fontSizeTablet'] ), false, $unit ); - $css->stop_media_query(); - } - - if ( ! empty( $data['fontSizeMobile'] ) ) { - $css->start_media_query( generate_premium_get_media_query( 'mobile' ) ); - - // Check for legacy font size values. - // @see https://github.com/tomusborne/generatepress/pull/548. - if ( is_numeric( $data['fontSizeMobile'] ) ) { - $data['fontSizeMobile'] = floatval( $data['fontSizeMobile'] ); - - if ( ! $unit ) { - $unit = 'px'; - } - } - - $css->add_property( 'font-size', esc_attr( $data['fontSizeMobile'] ), false, $unit ); - $css->stop_media_query(); - } - } - } - } - - // Primary button hover. - $css->set_selector( '.woocommerce #respond input#submit:hover, .woocommerce a.button:hover, .woocommerce button.button:hover, .woocommerce input.button:hover, .wc-block-components-button:hover' ); - $css->add_property( 'color', esc_attr( $settings['form_button_text_color_hover'] ) ); - $css->add_property( 'background-color', esc_attr( $settings['form_button_background_color_hover'] ) ); - - // Alt button. - $css->set_selector( '.woocommerce #respond input#submit.alt, .woocommerce a.button.alt, .woocommerce button.button.alt, .woocommerce input.button.alt, .woocommerce #respond input#submit.alt.disabled, .woocommerce #respond input#submit.alt.disabled:hover, .woocommerce #respond input#submit.alt:disabled, .woocommerce #respond input#submit.alt:disabled:hover, .woocommerce #respond input#submit.alt:disabled[disabled], .woocommerce #respond input#submit.alt:disabled[disabled]:hover, .woocommerce a.button.alt.disabled, .woocommerce a.button.alt.disabled:hover, .woocommerce a.button.alt:disabled, .woocommerce a.button.alt:disabled:hover, .woocommerce a.button.alt:disabled[disabled], .woocommerce a.button.alt:disabled[disabled]:hover, .woocommerce button.button.alt.disabled, .woocommerce button.button.alt.disabled:hover, .woocommerce button.button.alt:disabled, .woocommerce button.button.alt:disabled:hover, .woocommerce button.button.alt:disabled[disabled], .woocommerce button.button.alt:disabled[disabled]:hover, .woocommerce input.button.alt.disabled, .woocommerce input.button.alt.disabled:hover, .woocommerce input.button.alt:disabled, .woocommerce input.button.alt:disabled:hover, .woocommerce input.button.alt:disabled[disabled], .woocommerce input.button.alt:disabled[disabled]:hover' ); - $css->add_property( 'color', esc_attr( $settings['wc_alt_button_text'] ) ); - $css->add_property( 'background-color', esc_attr( $settings['wc_alt_button_background'] ) ); - - // Alt button hover. - $css->set_selector( '.woocommerce #respond input#submit.alt:hover, .woocommerce a.button.alt:hover, .woocommerce button.button.alt:hover, .woocommerce input.button.alt:hover' ); - $css->add_property( 'color', esc_attr( $settings['wc_alt_button_text_hover'] ) ); - $css->add_property( 'background-color', esc_attr( $settings['wc_alt_button_background_hover'] ) ); - - // WooBlocks panel button font-size. - // We don't want to treat this like a normal button. - $css->set_selector( 'button.wc-block-components-panel__button' ); - $css->add_property( 'font-size', 'inherit' ); - - // Star rating. - $css->set_selector( '.woocommerce .star-rating span:before, .woocommerce p.stars:hover a::before' ); - $css->add_property( 'color', esc_attr( $settings['wc_rating_stars'] ) ); - - // Sale sticker. - $css->set_selector( '.woocommerce span.onsale' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_sale_sticker_background'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_sale_sticker_text'] ) ); - - // Price. - $css->set_selector( '.woocommerce ul.products li.product .price, .woocommerce div.product p.price' ); - $css->add_property( 'color', esc_attr( $settings['wc_price_color'] ) ); - - // Product tab. - $css->set_selector( '.woocommerce div.product .woocommerce-tabs ul.tabs li a' ); - $css->add_property( 'color', esc_attr( $settings['wc_product_tab'] ) ); - - // Highlight product tab. - $css->set_selector( '.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover, .woocommerce div.product .woocommerce-tabs ul.tabs li.active a' ); - $css->add_property( 'color', esc_attr( $settings['wc_product_tab_highlight'] ) ); - - // Success message. - $css->set_selector( '.woocommerce-message' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_success_message_background'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_success_message_text'] ) ); - - $css->set_selector( 'div.woocommerce-message a.button, div.woocommerce-message a.button:focus, div.woocommerce-message a.button:hover, div.woocommerce-message a, div.woocommerce-message a:focus, div.woocommerce-message a:hover' ); - $css->add_property( 'color', esc_attr( $settings['wc_success_message_text'] ) ); - - // Info message. - $css->set_selector( '.woocommerce-info' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_info_message_background'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_info_message_text'] ) ); - - $css->set_selector( 'div.woocommerce-info a.button, div.woocommerce-info a.button:focus, div.woocommerce-info a.button:hover, div.woocommerce-info a, div.woocommerce-info a:focus, div.woocommerce-info a:hover' ); - $css->add_property( 'color', esc_attr( $settings['wc_info_message_text'] ) ); - - // Info message. - $css->set_selector( '.woocommerce-error' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_error_message_background'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_error_message_text'] ) ); - - $css->set_selector( 'div.woocommerce-error a.button, div.woocommerce-error a.button:focus, div.woocommerce-error a.button:hover, div.woocommerce-error a, div.woocommerce-error a:focus, div.woocommerce-error a:hover' ); - $css->add_property( 'color', esc_attr( $settings['wc_error_message_text'] ) ); - - // Archive short description. - $css->set_selector( '.woocommerce-product-details__short-description' ); - if ( '' !== $settings['content_text_color'] ) { - $css->add_property( 'color', esc_attr( $settings['content_text_color'] ) ); - } else { - $css->add_property( 'color', esc_attr( $settings['text_color'] ) ); - } - - $css->set_selector( '#wc-mini-cart' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_mini_cart_background_color'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_mini_cart_text_color'] ) ); - - $css->set_selector( '#wc-mini-cart a:not(.button), #wc-mini-cart a.remove' ); - $css->add_property( 'color', esc_attr( $settings['wc_mini_cart_text_color'] ) ); - - $css->set_selector( '#wc-mini-cart .button' ); - if ( $settings['wc_mini_cart_button_background'] ) { - $css->add_property( 'background-color', esc_attr( $settings['wc_mini_cart_button_background'] ) ); - } - - if ( $settings['wc_mini_cart_button_text'] ) { - $css->add_property( 'color', esc_attr( $settings['wc_mini_cart_button_text'] ) ); - } else { - $css->add_property( 'color', esc_attr( $settings['form_button_text_color'] ) ); - } - - $css->set_selector( '#wc-mini-cart .button:hover, #wc-mini-cart .button:focus, #wc-mini-cart .button:active' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_mini_cart_button_background_hover'] ) ); - - if ( $settings['wc_mini_cart_button_text_hover'] ) { - $css->add_property( 'color', esc_attr( $settings['wc_mini_cart_button_text_hover'] ) ); - } else { - $css->add_property( 'color', esc_attr( $settings['form_button_text_color_hover'] ) ); - } - - $css->set_selector( '.woocommerce #content div.product div.images, .woocommerce div.product div.images, .woocommerce-page #content div.product div.images, .woocommerce-page div.product div.images' ); - $css->add_property( 'width', absint( generatepress_wc_get_setting( 'single_product_image_width' ) ), false, '%' ); - - if ( ! $using_dynamic_typography && function_exists( 'generate_get_font_family_css' ) ) { - $buttons_family = generate_get_font_family_css( 'font_buttons', 'generate_settings', generate_get_default_fonts() ); - $css->set_selector( '.woocommerce.widget_shopping_cart .woocommerce-mini-cart__buttons a' ); - $css->add_property( 'font-family', $buttons_family ); - } - - $css->set_selector( '.add-to-cart-panel' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_panel_cart_background_color'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_panel_cart_text_color'] ) ); - - $css->set_selector( '.add-to-cart-panel a:not(.button)' ); - $css->add_property( 'color', esc_attr( $settings['wc_panel_cart_text_color'] ) ); - - $css->set_selector( '#wc-sticky-cart-panel .button' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_panel_cart_button_background'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_panel_cart_button_text'] ) ); - - $css->set_selector( '#wc-sticky-cart-panel .button:hover, #wc-sticky-cart-panel .button:focus, #wc-sticky-cart-panel .button:active' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_panel_cart_button_background_hover'] ) ); - $css->add_property( 'color', esc_attr( $settings['wc_panel_cart_button_text_hover'] ) ); - - $transparent_border_color = $settings['text_color']; - - if ( $settings['content_text_color'] ) { - $transparent_border_color = $settings['content_text_color']; - } - - $transparent_border_color = generate_premium_check_text_color( $transparent_border_color ); - - if ( 'light' === $transparent_border_color ) { - $transparent_border_elements = '.woocommerce-ordering select, .variations .value select'; - - if ( generatepress_wc_get_setting( 'quantity_buttons' ) ) { - $transparent_border_elements = '.woocommerce form .quantity.buttons-added .qty, .woocommerce form .quantity.buttons-added .minus, .woocommerce form .quantity.buttons-added .plus, .do-quantity-buttons form .quantity:not(.buttons-added):before, .do-quantity-buttons form .quantity:not(.buttons-added):after, .woocommerce-ordering select, .variations .value select'; - } - - $css->set_selector( $transparent_border_elements ); - $css->add_property( 'border-color', 'rgba(255,255,255,0.1)' ); - - if ( generatepress_wc_get_setting( 'sticky_add_to_cart_panel' ) ) { - $css->set_selector( '#wc-sticky-cart-panel .quantity.buttons-added .qty, #wc-sticky-cart-panel .quantity.buttons-added .minus, #wc-sticky-cart-panel .quantity.buttons-added .plus' ); - $css->add_property( 'border-color', 'rgba(255,255,255,0.1)' ); - } - } - - $css->set_selector( '.woocommerce .widget_price_filter .price_slider_wrapper .ui-widget-content' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_price_slider_background_color'] ) ); - - $css->set_selector( '.woocommerce .widget_price_filter .ui-slider .ui-slider-range, .woocommerce .widget_price_filter .ui-slider .ui-slider-handle' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_price_slider_bar_color'] ) ); - - if ( 'number' === generatepress_wc_get_setting( 'cart_menu_item_content' ) ) { - $nav_text_color = generate_premium_check_text_color( $settings['navigation_text_color'] ); - - $css->set_selector( '.cart-contents > span.number-of-items' ); - if ( 'light' === $nav_text_color ) { - $css->add_property( 'background-color', 'rgba(255,255,255,0.1)' ); - } else { - $css->add_property( 'background-color', 'rgba(0,0,0,0.05)' ); - } - - $css->set_selector( '.cart-contents .amount' ); - $css->add_property( 'display', 'none' ); - - $css->set_selector( '.cart-contents > span.number-of-items' ); - $css->add_property( 'display', 'inline-block' ); - } - - $font_icons = true; - - if ( function_exists( 'generate_get_option' ) ) { - if ( 'font' !== generate_get_option( 'icons' ) ) { - $font_icons = false; - } - } - - if ( ! $font_icons ) { - $css->set_selector( '.woocommerce-MyAccount-navigation li.is-active a:after, a.button.wc-forward:after' ); - $css->add_property( 'display', 'none' ); - - $css->set_selector( '#payment .payment_methods>.wc_payment_method>label:before' ); - $css->add_property( 'font-family', 'WooCommerce' ); - $css->add_property( 'content', '"\e039"' ); - - $css->set_selector( '#payment .payment_methods li.wc_payment_method>input[type=radio]:first-child:checked+label:before' ); - $css->add_property( 'content', '"\e03c"' ); - - $css->set_selector( '.woocommerce-ordering:after' ); - $css->add_property( 'font-family', 'WooCommerce' ); - $css->add_property( 'content', '"\e00f"' ); - } - - $css->set_selector( '.wc-columns-container .products, .woocommerce .related ul.products, .woocommerce .up-sells ul.products' ); - - if ( '' !== generatepress_wc_get_setting( 'columns_gap' ) ) { - $css->add_property( 'grid-gap', generatepress_wc_get_setting( 'columns_gap' ), false, 'px' ); - } - - $css->start_media_query( generate_premium_get_media_query( 'tablet' ) ); - $css->set_selector( '.wc-columns-container .products, .woocommerce .related ul.products, .woocommerce .up-sells ul.products' ); - - if ( '' !== generatepress_wc_get_setting( 'tablet_columns_gap' ) ) { - $css->add_property( 'grid-gap', generatepress_wc_get_setting( 'tablet_columns_gap' ), false, 'px' ); - } - - if ( 3 === generatepress_wc_get_setting( 'tablet_columns' ) ) { - $css->set_selector( '.woocommerce .wc-columns-container.wc-tablet-columns-3 .products' ); - $css->add_property( '-ms-grid-columns', '(1fr)[3]' ); - $css->add_property( 'grid-template-columns', 'repeat(3, 1fr)' ); - } - - if ( 2 === generatepress_wc_get_setting( 'tablet_columns' ) ) { - $css->set_selector( '.woocommerce .wc-columns-container.wc-tablet-columns-2 .products' ); - $css->add_property( '-ms-grid-columns', '(1fr)[2]' ); - $css->add_property( 'grid-template-columns', 'repeat(2, 1fr)' ); - } - - if ( 1 === generatepress_wc_get_setting( 'tablet_columns' ) ) { - $css->set_selector( '.woocommerce .wc-columns-container.wc-tablet-columns-1 .products' ); - $css->add_property( 'width', '100%' ); - $css->add_property( '-ms-grid-columns', '1fr' ); - $css->add_property( 'grid-template-columns', '1fr' ); - } - - if ( 3 === generatepress_wc_get_setting( 'tablet_related_upsell_columns' ) ) { - $css->set_selector( '.wc-related-upsell-tablet-columns-3 .related ul.products, .wc-related-upsell-tablet-columns-3 .up-sells ul.products' ); - $css->add_property( '-ms-grid-columns', '(1fr)[3]' ); - $css->add_property( 'grid-template-columns', 'repeat(3, 1fr)' ); - } - - if ( 2 === generatepress_wc_get_setting( 'tablet_related_upsell_columns' ) ) { - $css->set_selector( '.wc-related-upsell-tablet-columns-2 .related ul.products, .wc-related-upsell-tablet-columns-2 .up-sells ul.products' ); - $css->add_property( '-ms-grid-columns', '(1fr)[2]' ); - $css->add_property( 'grid-template-columns', 'repeat(2, 1fr)' ); - } - - if ( 1 === generatepress_wc_get_setting( 'tablet_related_upsell_columns' ) ) { - $css->set_selector( '.wc-related-upsell-tablet-columns-1 .related ul.products, .wc-related-upsell-tablet-columns-1 .up-sells ul.products' ); - $css->add_property( 'width', '100%' ); - $css->add_property( '-ms-grid-columns', '1fr' ); - $css->add_property( 'grid-template-columns', '1fr' ); - } - $css->stop_media_query(); - - $css->start_media_query( generate_premium_get_media_query( 'mobile' ) ); - if ( ! $using_dynamic_typography ) { - $css->set_selector( '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title' ); - if ( '' !== $settings[ 'mobile_wc_product_title_font_size' ] ) { - $css->add_property( 'font-size', esc_attr( $settings[ 'mobile_wc_product_title_font_size' ] ), false, 'px' ); - } - } - - $css->set_selector( '.add-to-cart-panel .continue-shopping' ); - $css->add_property( 'background-color', esc_attr( $settings['wc_panel_cart_background_color'] ) ); - - $css->set_selector( '.wc-columns-container .products, .woocommerce .related ul.products, .woocommerce .up-sells ul.products' ); - - if ( '' !== generatepress_wc_get_setting( 'mobile_columns_gap' ) ) { - $css->add_property( 'grid-gap', generatepress_wc_get_setting( 'mobile_columns_gap' ), false, 'px' ); - } - - $css->set_selector( '.woocommerce #content div.product div.images,.woocommerce div.product div.images,.woocommerce-page #content div.product div.images,.woocommerce-page div.product div.images' ); - $css->add_property( 'width', '100%' ); - $css->stop_media_query(); - - $using_flex = false; - - if ( function_exists( 'generate_is_using_flexbox' ) && generate_is_using_flexbox() ) { - $using_flex = true; - } - - $css->start_media_query( generate_premium_get_media_query( 'mobile-menu' ) ); - if ( ! $using_flex ) { - $css->set_selector( '.mobile-bar-items + .menu-toggle' ); - $css->add_property( 'text-align', 'left' ); - } - - $css->set_selector( 'nav.toggled .main-nav li.wc-menu-item' ); - $css->add_property( 'display', 'none !important' ); - - if ( ! $using_flex ) { - $css->set_selector( 'body.nav-search-enabled .wc-menu-cart-activated:not(#mobile-header) .mobile-bar-items' ); - $css->add_property( 'float', 'right' ); - $css->add_property( 'position', 'relative' ); - - $css->set_selector( '.nav-search-enabled .wc-menu-cart-activated:not(#mobile-header) .menu-toggle' ); - $css->add_property( 'float', 'left' ); - $css->add_property( 'width', 'auto' ); - } - - $css->set_selector( '.mobile-bar-items.wc-mobile-cart-items' ); - $css->add_property( 'z-index', '1' ); - $css->stop_media_query(); - - return $css->css_output(); -} - -add_action( 'wp_enqueue_scripts', 'generatepress_wc_enqueue_css', 100 ); -/** - * Enqueue our dynamic CSS. - * - * @since 1.3 - */ -function generatepress_wc_enqueue_css() { - wp_add_inline_style( 'generate-woocommerce', generatepress_wc_css() ); - - if ( class_exists( 'GeneratePress_Typography' ) ) { - wp_add_inline_style( 'generate-woocommerce', GeneratePress_Typography::get_css( 'woocommerce' ) ); - } -} - -/** - * Open WC image wrapper. - * - * @since 1.3 - */ -function generatepress_wc_image_wrapper_open() { - if ( generatepress_wc_get_setting( 'product_archive_image' ) ) { - echo '
            '; - } -} - -/** - * Close WC image wrapper. - * - * @since 1.3 - */ -function generatepress_wc_image_wrapper_close() { - if ( generatepress_wc_get_setting( 'product_archive_image' ) ) { - echo '
            '; - } -} - -add_filter( 'post_class', 'generatepress_wc_product_has_gallery' ); -add_filter( 'product_cat_class', 'generatepress_wc_product_has_gallery' ); -/** - * Add product image post classes to products. - * - * @since 1.3 - * - * @param array $classes Existing classes. - * @return array New classes. - */ -function generatepress_wc_product_has_gallery( $classes ) { - - $post_type = get_post_type( get_the_ID() ); - - if ( 'product' === $post_type && method_exists( 'WC_Product', 'get_gallery_image_ids' ) ) { - $product = wc_get_product( get_the_ID() ); - $attachment_ids = $product->get_gallery_image_ids(); - - if ( $attachment_ids && generatepress_wc_get_setting( 'product_secondary_image' ) && generatepress_wc_get_setting( 'product_archive_image' ) && has_post_thumbnail() ) { - $classes[] = 'wc-has-gallery'; - } - } - - return $classes; -} - -add_action( 'woocommerce_before_shop_loop_item_title', 'generatepress_wc_secondary_product_image' ); -/** - * Add secondary product image. - * - * @since 1.3 - */ -function generatepress_wc_secondary_product_image() { - $post_type = get_post_type( get_the_ID() ); - - if ( 'product' === $post_type && method_exists( 'WC_Product', 'get_gallery_image_ids' ) ) { - $product = wc_get_product( get_the_ID() ); - $attachment_ids = $product->get_gallery_image_ids(); - - if ( $attachment_ids && generatepress_wc_get_setting( 'product_secondary_image' ) && generatepress_wc_get_setting( 'product_archive_image' ) && has_post_thumbnail() ) { - $secondary_image_id = $attachment_ids['0']; - echo wp_get_attachment_image( $secondary_image_id, 'woocommerce_thumbnail', '', $attr = array( 'class' => 'secondary-image attachment-shop-catalog' ) ); - } - } -} - -add_filter( 'woocommerce_product_get_rating_html', 'generatepress_wc_rating_html', 10, 2 ); -/** - * Always show ratings area to make sure products are similar heights. - * - * @since 1.3.1 - * - * @param string $rating_html - * @param int $rating - * @return string - */ -function generatepress_wc_rating_html( $rating_html, $rating ) { - if ( $rating > 0 ) { - $title = sprintf( __( 'Rated %s out of 5', 'gp-premium' ), $rating ); - } else { - $title = __( 'Not yet rated', 'gp-premium' ); - $rating = 0; - } - - $rating_html = '
            '; - $rating_html .= '' . $rating . ' ' . __( 'out of 5', 'gp-premium' ) . ''; - $rating_html .= '
            '; - - return $rating_html; -} - -/** - * Add WC category description. - * - * @since 1.3 - * - * @param array $category - * @return string - */ -function generatepress_wc_category_description( $category ) { - $prod_term = get_term( $category->term_id, 'product_cat' ); - $description = $prod_term->description; - echo '
            ' . $description . '
            '; -} - -add_action( 'generate_after_footer', 'generatepress_wc_add_to_cart_helper' ); -/** - * Adds a sticky/slide down navigation with add to cart details. - * - * @since 1.8 - */ -function generatepress_wc_add_to_cart_helper() { - if ( ! generatepress_wc_get_setting( 'off_canvas_panel_on_add_to_cart' ) && ! generatepress_wc_get_setting( 'sticky_add_to_cart_panel' ) ) { - return; - } - - $outer_classes = array( - 'add-to-cart-panel', - ); - - $inner_classes = array( - 'inside-add-to-cart-panel', - ); - - if ( function_exists( 'generate_get_option' ) ) { - if ( 'contained-nav' === generate_get_option( 'nav_layout_setting' ) ) { - $outer_classes[] = 'grid-container grid-parent'; - } - - if ( 'contained' === generate_get_option( 'nav_inner_width' ) ) { - $inner_classes[] = 'grid-container grid-parent'; - } - } - ?> -
            -
            - - -
            - - -
            - -
            -
            - -
            - -
            - cart ) ) { - echo sprintf( _n( '%d item', '%d items', WC()->cart->get_cart_contents_count(), 'gp-premium' ), WC()->cart->get_cart_contents_count() ); ?> - cart->get_cart_total(); - } - ?> -
            -
            - - - %s -
            ', - esc_url( wc_get_checkout_url() ), - esc_html__( 'Checkout', 'gp-premium' ) - ) - ); - ?> - -
            - -
            - -
            - -
            - - get_price() ) : ?> -
            - get_price_html(); ?> -
            - is_type( 'simple' ) ) { - $args = array( - 'min_value' => apply_filters( 'woocommerce_quantity_input_min', $product->get_min_purchase_quantity(), $product ), - 'max_value' => apply_filters( 'woocommerce_quantity_input_max', $product->get_max_purchase_quantity(), $product ), - ); - - $action = sprintf( - '
            - %3$s - -
            ', - esc_url( $product->add_to_cart_url() ), - $quantity_buttons, - woocommerce_quantity_input( $args, $product, false ), - esc_html( $product->add_to_cart_text() ) - ); - } - - if ( $product->is_type( 'variable' ) ) { - $action = sprintf( - '', - esc_html( $product->add_to_cart_text() ) - ); - } - - if ( $product->is_type( 'external' ) ) { - $action = sprintf( - '
            - -
            ', - esc_url( $product->add_to_cart_url() ), - esc_html( $product->add_to_cart_text() ) - ); - } - - echo apply_filters( 'generate_wc_sticky_add_to_cart_action', $action, $product ); // phpcs:ignore -- No escaping needed. - endif; - ?> - -
            - - cart ) ) { - $fragments['.add-to-cart-panel .cart-data'] = '
            ' . sprintf( _n( '%d item', '%d items', WC()->cart->get_cart_contents_count(), 'gp-premium' ), WC()->cart->get_cart_contents_count() ) . ' - ' . WC()->cart->get_cart_total() . '
            '; - } - - return $fragments; -} - -/** - * If we should display the sticky add to cart panel. - * - * @since 1.8 - */ -function generatepress_wc_show_sticky_add_to_cart() { - if ( ! function_exists( 'wc_get_product' ) ) { - return false; - } - - $product = wc_get_product( get_the_ID() ); - $show = false; - - if ( ! $product || ! generatepress_wc_get_setting( 'sticky_add_to_cart_panel' ) || ! is_singular( 'product' ) ) { - return false; - } - - if ( ( $product->is_type( 'simple' ) || $product->is_type( 'variable' ) ) && $product->is_purchasable() && $product->is_in_stock() ) { - $show = true; - } - - if ( $product->is_type( 'external' ) ) { - $show = true; - } - - return apply_filters( 'generate_wc_show_sticky_add_to_cart', $show ); -} - -/** - * Checks if a color is light or dark. - * - * @since 1.8 - * @param string $color The color to check. - */ -function generate_premium_check_text_color( $color ) { - // Get the hex value if we're using variables. - if ( function_exists( 'generate_get_option' ) && strpos( $color, 'var(' ) !== false ) { - $global_colors = generate_get_option( 'global_colors' ); - $found_color = false; - - // Remove whitespace if it's been added. - $color = str_replace( ' ', '', $color ); - - foreach ( (array) $global_colors as $key => $data ) { - // Check for the full variable - var(--color) - or a variable with a fallback - var(--color,#fff). - if ( 'var(--' . $data['slug'] . ')' === $color || strpos( $color, 'var(--' . $data['slug'] . ',' ) !== false ) { - $color = $data['color']; - $found_color = true; - break; - } - } - - // If we didn't find the hex value, bail. - if ( ! $found_color ) { - return; - } - } - - $r = hexdec( substr( $color, 1, 2 ) ); - $g = hexdec( substr( $color, 3, 2 ) ); - $b = hexdec( substr( $color, 5, 2 ) ); - $yiq = ( ( $r * 299 ) + ( $g * 587 ) + ( $b * 114 ) ) / 1000; - - return ( $yiq >= 128 ) ? 'light' : 'dark'; -} - -add_filter( 'generate_typography_css_selector', 'generate_woocommerce_typography_selectors' ); -/** - * Add the WooCommerce typography CSS selectors. - * - * @since 2.1.0 - * @param string $selector The selector we're targeting. - */ -function generate_woocommerce_typography_selectors( $selector ) { - switch ( $selector ) { - case 'woocommerce-catalog-product-titles': - $selector = '.woocommerce ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce ul.products li.product .woocommerce-loop-category__title'; - break; - - case 'woocommerce-related-product-titles': - $selector = '.woocommerce .up-sells ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce .cross-sells ul.products li.product .woocommerce-LoopProduct-link h2, .woocommerce .related ul.products li.product .woocommerce-LoopProduct-link h2'; - break; - } - - return $selector; -} diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/js/woocommerce.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/js/woocommerce.js deleted file mode 100644 index 6950977f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/js/woocommerce.js +++ /dev/null @@ -1,285 +0,0 @@ -jQuery( function( $ ) { - var debounce = function( callback, wait ) { - var timeout; - - return function() { - clearTimeout( timeout ); - - timeout = setTimeout( function() { - timeout = undefined; - callback.call(); - }, wait ); - }; - }; - - $( 'body' ).on( 'added_to_cart', function() { - if ( ! $( '.wc-menu-item' ).hasClass( 'has-items' ) ) { - $( '.wc-menu-item' ).addClass( 'has-items' ); - } - - if ( ! $( '.wc-mobile-cart-items' ).hasClass( 'has-items' ) ) { - $( '.wc-mobile-cart-items' ).addClass( 'has-items' ); - } - } ); - - $( 'body' ).on( 'removed_from_cart', function() { - var numberOfItems = $( '.number-of-items' ); - - if ( numberOfItems.length ) { - if ( numberOfItems.hasClass( 'no-items' ) ) { - $( '.wc-menu-item' ).removeClass( 'has-items' ); - $( '.wc-mobile-cart-items' ).removeClass( 'has-items' ); - } - } - } ); - - if ( generateWooCommerce.addToCartPanel ) { - $( document.body ).on( 'added_to_cart', function() { - var adminBar = $( '#wpadminbar' ), - stickyNav = $( '.navigation-stick' ), - top = 0; - - if ( adminBar.length ) { - top = adminBar.outerHeight(); - } - - if ( stickyNav.length && '0px' === stickyNav.css( 'top' ) ) { - top = top + stickyNav.outerHeight(); - } - - $( '.add-to-cart-panel' ).addClass( 'item-added' ).css( { - '-webkit-transform': 'translateY(' + top + 'px)', - '-ms-transform': 'translateY(' + top + 'px)', - transform: 'translateY(' + top + 'px)', - } ); - } ); - - $( '.add-to-cart-panel .continue-shopping' ).on( 'click', function( e ) { - e.preventDefault(); - - $( '.add-to-cart-panel' ).removeClass( 'item-added' ).css( { - '-webkit-transform': 'translateY(-100%)', - '-ms-transform': 'translateY(-100%)', - transform: 'translateY(-100%)', - } ); - } ); - - $( window ).on( 'scroll', debounce( function() { - var panel = $( '.add-to-cart-panel' ); - - if ( panel.hasClass( 'item-added' ) ) { - panel.removeClass( 'item-added' ).css( { - '-webkit-transform': 'translateY(-100%)', - '-ms-transform': 'translateY(-100%)', - transform: 'translateY(-100%)', - } ); - } - }, 250 ) ); - } - - if ( generateWooCommerce.stickyAddToCart ) { - var lastScroll = 0; - var scrollDownTimeout = 300; - - $( window ).on( 'scroll', debounce( function() { - var adminBar = $( '#wpadminbar' ), - stickyNav = $( '.navigation-stick' ), - stuckElement = $( '.stuckElement' ), - top = 0, - scrollTop = $( window ).scrollTop(), - panel = $( '.add-to-cart-panel' ), - panelPosition = panel.offset().top + panel.outerHeight(), - button = $( '.single_add_to_cart_button' ), - buttonTop = button.offset().top, - buttonHeight = button.outerHeight(), - footerTop = $( '.site-footer' ).offset().top; - - if ( stuckElement.length === 0 ) { - scrollDownTimeout = 0; - } - - if ( scrollTop > ( buttonTop + buttonHeight ) && panelPosition < footerTop ) { - setTimeout( function() { - if ( adminBar.length ) { - top = adminBar.outerHeight(); - } - - if ( stickyNav.length ) { - if ( stickyNav.hasClass( 'auto-hide-sticky' ) ) { - if ( scrollTop < lastScroll && '0px' === stickyNav.css( 'top' ) ) { - top = top + stickyNav.outerHeight(); - } else { - top = top; - } - - lastScroll = scrollTop; - } else { - top = top + stickyNav.outerHeight(); - } - } - - panel.addClass( 'show-sticky-add-to-cart' ).css( { - '-webkit-transform': 'translateY(' + top + 'px)', - '-ms-transform': 'translateY(' + top + 'px)', - transform: 'translateY(' + top + 'px)', - } ); - }, scrollDownTimeout ); - } else { - panel.removeClass( 'show-sticky-add-to-cart' ).css( { - '-webkit-transform': '', - '-ms-transform': '', - transform: '', - } ); - } - }, 50 ) ); - - $( '.go-to-variables' ).on( 'click', function( e ) { - e.preventDefault(); - - var offset = 0, - stickyNav = $( '.navigation-stick' ), - adminBar = $( '#wpadminbar' ); - - if ( stickyNav.length ) { - offset = stickyNav.outerHeight(); - } - - if ( adminBar.length ) { - offset = offset + adminBar.outerHeight(); - } - - $( 'html, body' ).animate( { - scrollTop: $( '.variations' ).offset().top - offset, - }, 250 ); - } ); - } - - $( function() { - 'use strict'; - - if ( generateWooCommerce.quantityButtons ) { - generateQuantityButtons(); - } - } ); - - $( document ).ajaxComplete( function() { - 'use strict'; - - if ( generateWooCommerce.quantityButtons ) { - generateQuantityButtons(); - } - } ); - - function generateQuantityButtons() { - // Check if we have an overwrite hook for this function - try { - return generateWooCommerce.hooks.generateQuantityButtons(); - } catch ( e ) { - // No hook in place, carry on - } - - // Grab the FIRST available cart form on the page - var cart = $( '.woocommerce div.product form.cart' ).first(); - - // Check if we see elementor style classes - if ( cart.closest( '.elementor-add-to-cart' ).length ) { - // Found classes, remove them and finish here - $( '.elementor.product' ).removeClass( 'do-quantity-buttons' ); - return; - } - - // Grab all the quantity boxes that need dynamic buttons adding - var quantityBoxes; - - try { - // Is there a hook available? - quantityBoxes = generateWooCommerce.selectors.generateQuantityButtons.quantityBoxes; - } catch ( e ) { - // Use the default plugin selector functionality - quantityBoxes = $( '.cart div.quantity:not(.buttons-added), .cart td.quantity:not(.buttons-added)' ).find( '.qty' ); - } - - // Test the elements have length and greater than 0 - // Try, catch here to provide basic error checking on hooked data - try { - // Nothing found... stop here - if ( quantityBoxes.length === 0 ) { - return false; - } - } catch ( e ) { - return false; - } - - // Allow the each loop callback to be completely overwritten - var quantityBoxesCallback; - - try { - // Try assign a hooked callback - quantityBoxesCallback = generateWooCommerce.callbacks.generateQuantityButtons.quantityBoxes; - } catch ( e ) { - // Use the default callback handler - quantityBoxesCallback = function( key, value ) { - var box = $( value ); - - // Check allowed types - if ( [ 'date', 'hidden' ].indexOf( box.prop( 'type' ) ) !== -1 ) { - return; - } - - // Add plus and minus icons - box.parent().addClass( 'buttons-added' ).prepend( '-' ); - box.after( '+' ); - - // Enforce min value on the input - var min = parseFloat( $( this ).attr( 'min' ) ); - - if ( min && min > 0 && parseFloat( $( this ).val() ) < min ) { - $( this ).val( min ); - } - - // Add event handlers to plus and minus (within this scope) - box.parent().find( '.plus, .minus' ).on( 'click', function() { - // Get values - var currentQuantity = parseFloat( box.val() ), - maxQuantity = parseFloat( box.attr( 'max' ) ), - minQuantity = parseFloat( box.attr( 'min' ) ), - step = box.attr( 'step' ); - - // Fallback default values - if ( ! currentQuantity || '' === currentQuantity || 'NaN' === currentQuantity ) { - currentQuantity = 0; - } - - if ( '' === maxQuantity || 'NaN' === maxQuantity ) { - maxQuantity = ''; - } - - if ( '' === minQuantity || 'NaN' === minQuantity ) { - minQuantity = 0; - } - - if ( 'any' === step || '' === step || undefined === step || 'NaN' === parseFloat( step ) ) { - step = 1; - } - - if ( $( this ).is( '.plus' ) ) { - if ( maxQuantity && ( maxQuantity === currentQuantity || currentQuantity > maxQuantity ) ) { - box.val( maxQuantity ); - } else { - box.val( currentQuantity + parseFloat( step ) ); - } - } else if ( minQuantity && ( minQuantity === currentQuantity || currentQuantity < minQuantity ) ) { - box.val( minQuantity ); - } else if ( currentQuantity > 0 ) { - box.val( currentQuantity - parseFloat( step ) ); - } - - // Trigger change event - box.trigger( 'change' ); - } ); - }; - } - - $.each( quantityBoxes, quantityBoxesCallback ); - } -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/js/woocommerce.min.js b/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/js/woocommerce.min.js deleted file mode 100644 index 97f0e7aa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/gp-premium/woocommerce/functions/js/woocommerce.min.js +++ /dev/null @@ -1 +0,0 @@ -jQuery(function(d){function t(t,a){var e;return function(){clearTimeout(e),e=setTimeout(function(){e=void 0,t.call()},a)}}var m,u;function a(){try{return generateWooCommerce.hooks.generateQuantityButtons()}catch(t){}var a,e;if(d(".woocommerce div.product form.cart").first().closest(".elementor-add-to-cart").length)d(".elementor.product").removeClass("do-quantity-buttons");else{try{a=generateWooCommerce.selectors.generateQuantityButtons.quantityBoxes}catch(t){a=d(".cart div.quantity:not(.buttons-added), .cart td.quantity:not(.buttons-added)").find(".qty")}try{if(0===a.length)return}catch(t){return}try{e=generateWooCommerce.callbacks.generateQuantityButtons.quantityBoxes}catch(t){e=function(t,a){var s=d(a);-1===["date","hidden"].indexOf(s.prop("type"))&&(s.parent().addClass("buttons-added").prepend('-'),s.after('+'),(a=parseFloat(d(this).attr("min")))&&0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - gp_elements - - - _generate_element_content - _generate_element_type - _generate_block_type - _generate_element_display_conditions - _generate_element_exclude_conditions - _generate_element_user_conditions - _generate_hook - _generate_hook_execute_shortcodes - _generate_hook_execute_php - _generate_hook_priority - _generate_hook_disable_site_header - _generate_hook_disable_site_footer - _generate_hero_custom_classes - _generate_hero_container - _generate_hero_inner_container - _generate_hero_horizontal_alignment - _generate_hero_padding_top - _generate_hero_padding_right - _generate_hero_padding_bottom - _generate_hero_padding_left - _generate_hero_padding_top_unit - _generate_hero_padding_right_unit - _generate_hero_padding_bottom_unit - _generate_hero_padding_left_unit - _generate_hero_padding_top_mobile - _generate_hero_padding_right_mobile - _generate_hero_padding_bottom_mobile - _generate_hero_padding_left_mobile - _generate_hero_padding_top_unit_mobile - _generate_hero_padding_right_unit_mobile - _generate_hero_padding_bottom_unit_mobile - _generate_hero_padding_left_unit_mobile - _generate_hero_background_image - _generate_hero_background_position - _generate_hero_background_parallax - _generate_hero_disable_featured_image - _generate_hero_background_overlay - _generate_hero_background_color - _generate_hero_text_color - _generate_hero_link_color - _generate_hero_background_link_color_hover - _generate_site_header_merge - _generate_site_header_height - _generate_site_header_height_mobile - _generate_site_header_background_color - _generate_site_header_title_color - _generate_site_header_tagline_color - _generate_site_logo - _generate_retina_logo - _generate_navigation_logo - _generate_mobile_logo - _generate_navigation_location - _generate_navigation_colors - _generate_navigation_background_color - _generate_navigation_text_color - _generate_navigation_background_color_hover - _generate_navigation_text_color_hover - _generate_navigation_background_color_current - _generate_navigation_text_color_current - _generate_sidebar_layout - _generate_footer_widgets - _generate_disable_site_header - _generate_disable_top_bar - _generate_disable_primary_navigation - _generate_disable_secondary_navigation - _generate_disable_featured_image - _generate_disable_content_title - _generate_disable_footer - _generate_content_area - _generate_content_width - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/CHANGELOG.md deleted file mode 100644 index 9e4d2bc5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/CHANGELOG.md +++ /dev/null @@ -1,321 +0,0 @@ -# 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). - -## 4.0.0 - 2025-03-24 - -### Changed -- Scanner: add threat count to tab [#40056] -- Scanner: animated the "scan in progress" placeholder image [#39825] -- General: indicate compatibility with the upcoming version of WordPress - 6.7. [#39786] -- General: Update package dependencies. [#42511] - -### Removed -- Firewall: removed "new" badge from tab. [#41902] -- General: Update minimum PHP version to 7.2. [#40147] -- General: Update minimum WordPress version to 6.6. [#40146] - -## 3.1.1 - 2024-10-17 -### Changed -- Firewall: Fix backwards compatibility for sites running standalone mode with outdated packages autoloaded. - -## 3.1.0 - 2024-10-15 -### Added -- Firewall: Adds stat cards showing recent block counts [#35739] -- Auto-Fixers: Adds handling for long-running fixers [#39301] - -### Changed -- Firewall: added help text for IP list formatting rules [#39448] -- Updated package dependencies. [#39707] - -### Removed -- Security Scanning: disabled database threat category [#39467] - -### Fixed -- Minor fixes and improvements. - -## 3.0.2 - 2024-09-06 -### Changed -- Internal updates. - -## 3.0.1 - 2024-09-06 -### Added -- Threats List: Add pagination. [#39058] - -### Changed -- Admin menu: change order of Jetpack sub-menu items. [#39095] -- Updated package dependencies. [#39176] - -### Fixed -- Security Scanning: Adds a background to the scan progress bar. [#38847] -- General: Delete relevant Protect options on deactivation. [#38815] -- Auto Fixers: Disable the unignore threats button when a fixer is in progress. [#38898] -- Security Scanning: Fix the threat fixed on date in the history view. [#39164] -- General: Improves the manual scan link button loading state. [#38897] - -## 3.0.0-beta - 2024-08-09 -### Added -- Firewall: add dedicated WAF allow and block list toggles [#38265] -- General: add "contact support" links [#38416] -- Security Scanning: add threats history view [#38117] - -### Changed -- General: indicate compatibility with the upcoming version of WordPress - 6.6. [#37962] - -### Removed -- General: update WordPress version requirements to WordPress 6.5. [#38382] - -### Fixed -- Fix an issue where the connection error hook was always resetting the notice [#38120] -- Fix image optimization [#38573] -- Fix in-progress threat fixer loading indicator [#38051] -- Fix threat fix modal title [#38312] - -## 2.2.0 - 2024-05-24 -### Added -- Add data to WAF logs and a toggle for users to opt-in to share more data with us if needed. [#36377] -- Trigger a red bubble notification when a bad install is detected. [#36449] - -### Changed -- Update WordPress minimum version requirement to WordPress 6.4. [#37047] -- Only show installation errors on the plugins page. [#36390] - -### Fixed -- Jetpack Protect Footer: ensure that "Go to cloud" links are not shown when on a platform with no firewall support. [#36794] - -## 2.1.0 - 2024-03-14 -### Added -- Added onboarding flows. [#34649] -- Added firewall standalone mode indicator. [#34840] - -### Changed -- General: indicate compatibility with the upcoming version of WordPress, 6.5. [#35820] -- Use blog ID instead of site slug in checkout links. [#35004] -- Updated package dependencies. [#36325] -- Updated package lockfile. [#35672] - -### Fixed -- Prevent text orphans in the site scanning header. [#35935] - -## 2.0.0 - 2024-01-18 -### Changed -- Firewall: use datetime versioning for rules file updates. [#34698] -- General: unify display of notifications across Scan and Firewall screens [#34702] -- General: indicate full compatibility with the latest version of WordPress, 6.4. [#33776] -- General: update PHP requirement to PHP 7.0+ [#34126] -- General: update WordPress version requirements to WordPress 6.3. [#34127] -- General: update package dependencies. [#34882] -- General: update lockfile. [#33607] - -### Fixed -- Fix Modal component overflow scrolling. [#34475] -- Fix Popover component styling. [#34424] -- Improved helper script installer logging. [#34297] - -## 1.4.2 - 2023-10-19 -### Changed -- General: update WordPress version requirements to WordPress 6.2. [#32762] [#32772] -- Updated Jetpack submenu sort order so individual features are alpha-sorted. [#32958] -- Updated method used to render Connection initial state. [#32499] -- Updated package dependencies. [#33692] - -## 1.4.1 - 2023-07-18 -### Changed -- Brute Force Protection: add access to feature in environments that otherwise do not support the WAF. [#31952] -- General: indicate full compatibility with the latest version of WordPress, 6.3. [#31910] -- Update WordPress version requirements. Now requires version 6.1. [#30120] -- Update package dependencies. [#31952] - -### Fixed -- Scan: Fixed sorting of threats by severity. [#31124] -- License Activation: add filtering for unattached and unrevoked licenses within upgrade flow check. [#31086] - -## 1.4.0 - 2023-05-05 -### Added -- Add brute force protection. [#28401] - -### Changed -- General: indicate full compatibility with the latest version of WordPress, 6.2. [#29341] -- Improve the firewall status heading to provide more information based on the current configuration. [#28401] -- Updated package dependencies. [#29480] - -## 1.3.0 - 2023-03-13 -### Added -- Add ability to toggle automatic and manual firewall rules independently. [#27726] -- Add improved messaging for currently enabled firewall features. [#27845] -- Disable Jetpack Firewall on unsupported environments. [#27939] -- Add link to pricing page for getting started with an existing plan or license key. [#27745] - -### Changed -- Updated package dependencies. [#29297] -- Update to React 18. [#28710] -- Use `flex-start`/`flex-end` instead of `start`/`end` for better browser compatibility. [#28530] - -### Fixed -- Fix connection button loading indicators. [#28514] -- Fix Protect status report caching. [#28766] -- Remove unnecessary full path from example in UI. [#29037] -- Other assorted fixes for minor bugs and grammar. [#27846] [#28091] [#28397] [#28273] - -## 1.2.0 - 2023-01-16 -### Added -- Add web application firewall (WAF) features [#27528] -- Add progress bar to site scannnig screen [#27171] - -### Fixed -- Poll for scan status while scanner is provisioning [#28275] -- Bug fixes - -## 1.1.2 - 2022-11-30 -### Changed -- changed description and author [#27618] -- Updated package dependencies. [#27043] - -## 1.1.1 - 2022-11-18 -### Fixed -- Fix issue with plugin activation. - -## 1.1.0 - 2022-11-17 -### Added -- Add features for paid Jetpack Scan users, including file and database threats, on-demand scanning, and threat auto-fixers. - -### Changed -- Compatibility: WordPress 6.1 compatibility - -### Fixed -- Adjust alignment of spinner icon and loading text on the in-progress scan screen. - -## 1.0.4 - 2022-08-29 -### Fixed -- Fixed NaN error that prevented the pricing interstitial from rendering. - -## 1.0.3 - 2022-08-26 -### Added -- Added a default 'See all results' label to the mobile navigation button. -- Added a spinner to the in progress scan page in admin -- Added JITM functionality -- Added threat descriptions. -- My Jetpack includes JITMs - -### Changed -- Add condition to check plugin activation context before redirecting - -### Fixed -- Fixed alignment of long navigation item labels on mobile screen sizes. - -## 1.0.2 - 2022-07-27 -### Changed -- Updated package dependencies. - -### Fixed -- Fix protect admin toolbar icon display when Jetpack enabled and connected -- Minor bug fix - added isset() checks for report data properties - -## 1.0.1 - 2022-07-07 -### Added -- Added two new FAQ entries -- Protect: record even just after the site is registered - -### Changed -- Moved normalization of the Protect status report data to the server side. -- Renamed `master` references to `trunk` -- Reorder JS imports for `import/order` eslint rule. - -### Fixed -- Fixed bug that would not display Core vulnerabilities. -- Removed legacy code and documentation and adds new docs for the debug helper plugin. -- Fixed recommendation for plugins that don't have a fix yet -- Protect: Fix visual issue of the Interstitial page - -## 1.0.0 - 2022-05-31 -### Added -- Add additional tracking events -- Add Alert icon to the error admin page -- Add checks to the Site Health page -- Add custom hook to handle viewport sizes via CSS -- Add error message when adding plugin fails -- Add first approach of Interstitial page -- Add Jetpack Scan to promotion section when site doesn't have Security bundle -- Add missing prop-types module dependency -- Add Navigation dropdown mode and use it for small/medium screens -- Add ProductOffer component -- Add product offer component -- Add title and redirect for vul at wpscan -- Add 'get themes' to synced callables in Protect -- Add installedThemes to the initial state -- Add notifications to the menu item and the admin bar -- Add status polling to the Protect admin page. -- Added details to the FAQ question on how Jetpack Protect is different from other Jetpack products. -- Added Jetpack Protect readme file for the plugin listing. -- Added option to display terms of service below product activation button. -- Added Social card to My Jetpack. -- Added the list of installed plugins to the initial state -- Change ConnectScreen by the Interstitial component -- Creates Status Class -- Empty state screen -- Expose and use IconsCard component -- Flush cache on plugin deactivation -- Footer component -- Handle error in the UI -- Hooks on plugin activation and deactivation -- Hook to read data from the initial state -- Implement Footer -- Implement Add Security bundle workflow -- Introduce Accordion component -- Introduce Navigation component -- Introduce Summary component -- Introduce VulnerabilitiesList component -- JS Components: Introduce Alert component. Add error to ProductOffer components -- More options to the testing api responses -- Record admin page-view and get security from footer events -- Render Security component with data provided by wpcom -- Request and expose to the client the Security bundle data -- Update logo - -### Changed -- Add empty state for no vuls -- Add popover at Badge -- Cache empty statuses for a short period of time -- Changed connection screen to the one that does not require a product -- Changed the method used to disconnect -- Changed the wording for the initial screen. -- Change expiration time of plugin cache -- Clean connection data. Update to latest connection API -- Configure Sync to only what we need to sync -- Janitorial: require a more recent version of WordPress now that WP 6.0 is coming out. -- JS Components: Add subTitle prop to ProductOffer component -- JS Components: iterate over Dialog component -- Improve Dialog layout in medium viewport size -- Move VulnerabilitiesList to section hero -- New VulsList -- Redesign Summary component -- Re-implement "Your results will be ready soon" layout -- Re-implement Admin page by using Dialog component -- Remove use of `pnpx` in preparation for pnpm 7.0. -- Replace deprecated external-link variation by using isExternalLink prop -- Require only site level connection -- Truncate items at NavigationGroup -- Tweak footer -- Update Footer and VulsList for small/medium viewport -- Update Navigation to be external controlled -- Update Protect icon -- Update VulnerabilitiesList to remove severity and add fixed in -- Updated package dependencies. -- Update package.json metadata. -- Updates CTA wording to reduce confusion when user already has Jetpack Security Bundle which includes Jetpack Scan -- Update the Status when connection is established -- Use data provided by My Jetpack to render Product offer -- Use weight Button prop to style the "learn more" footer link -- Use a different copy when there are no found vulnerabilities but there are still some unchecked items - -### Removed -- Removed Full Sync from loaded modules as Full Sync Immediately is present by default now - -### Fixed -- Adjust spacing and overflow properties of the navigation labels to improve display of long names. -- Fix Connectino initialization -- Fix fatal when checking whether site site has vuls -- Fix right margin in primary layout diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.eot b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.eot deleted file mode 100644 index 51f012dd..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.eot and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.svg deleted file mode 100644 index 51e14560..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.svg +++ /dev/null @@ -1,11 +0,0 @@ - - - -Generated by IcoMoon - - - - - - - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.ttf b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.ttf deleted file mode 100644 index c44c262f..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.ttf and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.woff b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.woff deleted file mode 100644 index dc898ac5..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/fonts/jetpack-protect.woff and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/jetpack-protect.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/jetpack-protect.css deleted file mode 100644 index d194c5b1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/assets/jetpack-protect.css +++ /dev/null @@ -1,30 +0,0 @@ -@font-face { - font-family: 'jetpack-protect'; - src: url('fonts/jetpack-protect.eot?31wpn'); - src: url('fonts/jetpack-protect.eot?31wpn#iefix') format('embedded-opentype'), - url('fonts/jetpack-protect.ttf?31wpn') format('truetype'), - url('fonts/jetpack-protect.woff?31wpn') format('woff'), - url('fonts/jetpack-protect.svg?31wpn#jetpack-protect') format('svg'); - font-weight: normal; - font-style: normal; - font-display: block; - } - -[class^="jp-protect-icon"], [class*=" jp-protect-icon"] { - /* use !important to prevent issues with browser extensions that change fonts */ - font-family: 'jetpack-protect' !important; - speak: never; - font-style: normal; - font-weight: normal; - font-variant: normal; - text-transform: none; - line-height: 1; - - /* Better Font Rendering =========== */ - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} - -.jp-protect-icon:before { - content: "\e900"; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.asset.php deleted file mode 100644 index 14de1bb2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('jetpack-connection', 'jetpack-script-data', 'moment', 'react', 'react-dom', 'react-jsx-runtime', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-date', 'wp-element', 'wp-i18n', 'wp-polyfill', 'wp-primitives', 'wp-url'), 'version' => '5a27a9f58fb4802d8a58'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.css deleted file mode 100644 index 4dcb512e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.css +++ /dev/null @@ -1 +0,0 @@ -._aiMxmJRAw5jRPbZFX57{background-color:var(--jp-gray-90);border-radius:var(--jp-border-radius);color:var(--jp-white);display:flex;overflow:hidden;z-index:1}._aiMxmJRAw5jRPbZFX57.eWgNBUaexiR66ZI1Px4U{border-left:4px solid var(--jp-yellow-20);margin-bottom:calc(var(--spacing-base)*3)}._aiMxmJRAw5jRPbZFX57.ZGELG1CO333FilJXOaeI{margin-left:calc(var(--spacing-base)*3);position:fixed;right:calc(var(--spacing-base)*3);top:calc(var(--spacing-base)*6)}@media(max-width:782px){._aiMxmJRAw5jRPbZFX57.ZGELG1CO333FilJXOaeI{top:calc(var(--spacing-base)*8)}}._aiMxmJRAw5jRPbZFX57 a,._aiMxmJRAw5jRPbZFX57 a:active,._aiMxmJRAw5jRPbZFX57 a:hover,._aiMxmJRAw5jRPbZFX57 a:link,._aiMxmJRAw5jRPbZFX57 a:visited{color:var(--jp-white)}.BnI88X_e8ItF1c9Uozmj{background-color:var(--jp-yellow-30);fill:var(--jp-white);align-items:center;display:flex;justify-content:center;padding:calc(var(--spacing-base)*1.5)}.hRRUwTCPRpurhMwRNZkg .BnI88X_e8ItF1c9Uozmj{background-color:var(--jp-green-50)}.Z6q3IxY_uR1y2lAPTkVF .BnI88X_e8ItF1c9Uozmj{background-color:var(--jp-red)}.eWgNBUaexiR66ZI1Px4U .BnI88X_e8ItF1c9Uozmj{fill:var(--jp-yellow-50);background-color:var(--jp-yellow-5)}.ST8sowTbBVLRPrk4ZQrn{font-size:14px;padding:calc(var(--spacing-base)*1.75)}.eWgNBUaexiR66ZI1Px4U .ST8sowTbBVLRPrk4ZQrn{background-color:var(--jp-yellow-5);color:var(--jp-gray-90)}.lMkO08Vd8YQMfwrwaI8u{fill:var(--jp-gray);align-items:center;background:#0000;border:none;cursor:pointer;display:flex;justify-content:center;padding:calc(var(--spacing-base)*1.5)}._Wc3apZobag_9Ag_THTb{display:flex;justify-content:space-between}.WQVtrU6q0L1Igcj7wCrQ{margin:0;padding:0}.UujoBFTnQNY2cWU2SIsH{font-size:var(--font-headline-medium);font-weight:700;line-height:52px}.TeGO5V_thHw5lDAm1_2M{font-weight:700}.TeGO5V_thHw5lDAm1_2M,.WolQzb2MsSgiNmLtc7_j{font-size:var(--font-headline-small);line-height:40px}.WolQzb2MsSgiNmLtc7_j{font-weight:400}.hUB0JT8p1T2Hw28N6qC8{font-weight:500}.gKZWDv5chz3_O3Syp74H,.hUB0JT8p1T2Hw28N6qC8{font-size:var(--font-title-medium);line-height:32px}.gKZWDv5chz3_O3Syp74H{font-weight:600}.zY2No8Ga4b8shbOQGhnv{font-size:var(--font-title-small);font-weight:500;line-height:30px}.tIj0D1t8Cc892ikmgFPZ{font-size:var(--font-body);font-weight:400;line-height:24px}.KdcN0BnOaVeVhyLRKqhS{font-size:var(--font-body-small);font-weight:400;line-height:24px}.dso3Rh3tl3Xv1GumBktz{font-weight:400}.dso3Rh3tl3Xv1GumBktz,.mQ1UlbN9u4Mg9byO8m7v{font-size:var(--font-body-extra-small);line-height:20px}.mQ1UlbN9u4Mg9byO8m7v{font-weight:700}.PItlW5vRExLnTj4a8eLE{font-size:var(--font-body-extra-small);font-weight:600;line-height:16px}.TwRpPlktzxhmFVeua7P5{margin:calc(var( --spacing-base )*0)}.zVfqx7gyb3o9mxfGynn1{margin-left:calc(var( --spacing-base )*0);margin-right:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy{margin-bottom:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy,.xqDIp6cNVr_E6RXaiPyD{margin-top:calc(var( --spacing-base )*0)}.S8EwaXk1kyPizt6x4WH2{margin-right:calc(var( --spacing-base )*0)}.ODX5Vr1TARoLFkDDFooD{margin-bottom:calc(var( --spacing-base )*0)}.cphJ8dCpfimnky7P2FHg{margin-left:calc(var( --spacing-base )*0)}.PFgIhNxIyiSuNvQjAIYj{margin:calc(var( --spacing-base )*1)}.M2jKmUzDxvJjjVEPU3zn{margin-left:calc(var( --spacing-base )*1);margin-right:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk{margin-bottom:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk,.rcTN5uw9xIEeMEGL3Xi_{margin-top:calc(var( --spacing-base )*1)}.CQSkybjq2TcRM1Xo9COV{margin-right:calc(var( --spacing-base )*1)}.hfqOWgq6_MEGdFE82eOY{margin-bottom:calc(var( --spacing-base )*1)}.I8MxZQYTbuu595yfesWA{margin-left:calc(var( --spacing-base )*1)}.kQkc6rmdpvLKPkyoJtVQ{margin:calc(var( --spacing-base )*2)}.j6vFPxWuu4Jan2ldoxpp{margin-left:calc(var( --spacing-base )*2);margin-right:calc(var( --spacing-base )*2)}.hqr39dC4H_AbactPAkCG{margin-bottom:calc(var( --spacing-base )*2)}.c3dQnMi16C6J6Ecy4283,.hqr39dC4H_AbactPAkCG{margin-top:calc(var( --spacing-base )*2)}.YNZmHOuRo6hU7zzKfPdP{margin-right:calc(var( --spacing-base )*2)}.Db8lbak1_wunpPk8NwKU{margin-bottom:calc(var( --spacing-base )*2)}.ftsYE5J9hLzquQ0tA5dY{margin-left:calc(var( --spacing-base )*2)}.Det4MHzLUW7EeDnafPzq{margin:calc(var( --spacing-base )*3)}.h_8EEAztC29Vve1datb5{margin-left:calc(var( --spacing-base )*3);margin-right:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM{margin-bottom:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM,.soADBBkcIKCBXzCTuV9_{margin-top:calc(var( --spacing-base )*3)}.zSX59ziEaEWGjnpZa4uV{margin-right:calc(var( --spacing-base )*3)}.yrVTnq_WBMbejg89c2ZQ{margin-bottom:calc(var( --spacing-base )*3)}.UKtHPJnI2cXBWtPDm5hM{margin-left:calc(var( --spacing-base )*3)}.guexok_Tqd5Tf52hRlbT{margin:calc(var( --spacing-base )*4)}.oS1E2KfTBZkJ3F0tN7T6{margin-left:calc(var( --spacing-base )*4);margin-right:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd{margin-bottom:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd,.ot2kkMcYHv53hLZ4LSn0{margin-top:calc(var( --spacing-base )*4)}.A1krOZZhlQ6Sp8Cy4bly{margin-right:calc(var( --spacing-base )*4)}.pkDbXXXL32237M0hokEh{margin-bottom:calc(var( --spacing-base )*4)}.XXv4kDTGvEnQeuGKOPU3{margin-left:calc(var( --spacing-base )*4)}.yGqHk1a57gaISwkXwXe6{margin:calc(var( --spacing-base )*5)}.X8cghM358X3DkXLc9aNK{margin-left:calc(var( --spacing-base )*5);margin-right:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f{margin-bottom:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f,.yqeuzwyGQ7zG0avrGqi_{margin-top:calc(var( --spacing-base )*5)}.g9emeCkuHvYhveiJbfXO{margin-right:calc(var( --spacing-base )*5)}.Lvk3dqcyHbZ07QCRlrUQ{margin-bottom:calc(var( --spacing-base )*5)}.r3yQECDQ9qX0XZzXlVAg{margin-left:calc(var( --spacing-base )*5)}.aQhlPwht2Cz1X_63Miw0{margin:calc(var( --spacing-base )*6)}.JyHb0vK3wJgpblL9s5j8{margin-left:calc(var( --spacing-base )*6);margin-right:calc(var( --spacing-base )*6)}.cY2gULL1lAv6WPNIRuf3{margin-bottom:calc(var( --spacing-base )*6)}.NBWQ9Lwhh_fnry3lg_p7,.cY2gULL1lAv6WPNIRuf3{margin-top:calc(var( --spacing-base )*6)}.yIOniNe5E40C8fWvBm5V{margin-right:calc(var( --spacing-base )*6)}.t30usboNSyqfQWIwHvT3{margin-bottom:calc(var( --spacing-base )*6)}.Nm_TyFkYCMhOoghoToKJ{margin-left:calc(var( --spacing-base )*6)}.C4qJKoBXpgKtpmrqtEKB{margin:calc(var( --spacing-base )*7)}.S93Srbu6NQ_PBr7DmTiD{margin-left:calc(var( --spacing-base )*7);margin-right:calc(var( --spacing-base )*7)}.fJj8k6gGJDks3crUZxOS{margin-bottom:calc(var( --spacing-base )*7)}.cW6D6djs7Ppm7fD7TeoV,.fJj8k6gGJDks3crUZxOS{margin-top:calc(var( --spacing-base )*7)}.DuCnqNfcxcP3Z__Yo5Ro{margin-right:calc(var( --spacing-base )*7)}.im8407m2fw5vOg7O2zsw{margin-bottom:calc(var( --spacing-base )*7)}.G0fbeBgvz2sh3uTP9gNl{margin-left:calc(var( --spacing-base )*7)}.kvW3sBCxRxUqz1jrVMJl{margin:calc(var( --spacing-base )*8)}.tOjEqjLONQdkiYx_XRnw{margin-left:calc(var( --spacing-base )*8);margin-right:calc(var( --spacing-base )*8)}.op5hFSx318zgxsoZZNLN{margin-bottom:calc(var( --spacing-base )*8)}.c9WfNHP6TFKWIfLxv52J,.op5hFSx318zgxsoZZNLN{margin-top:calc(var( --spacing-base )*8)}.sBA75QqcqRwwYSHJh2wc{margin-right:calc(var( --spacing-base )*8)}.GpL6idrXmSOM6jB8Ohsf{margin-bottom:calc(var( --spacing-base )*8)}.HbtWJoQwpgGycz8dGzeT{margin-left:calc(var( --spacing-base )*8)}.uxX3khU88VQ_Ah49Ejsa{padding:calc(var( --spacing-base )*0)}.KX0FhpBKwKzs9fOUdbNz{padding-left:calc(var( --spacing-base )*0);padding-right:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz{padding-bottom:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz,.emxLHRjQuJsImnPbQIzE{padding-top:calc(var( --spacing-base )*0)}.kJ8WzlpTVgdViXt8ukP9{padding-right:calc(var( --spacing-base )*0)}.tg_UIUI11VBzrTAn2AzJ{padding-bottom:calc(var( --spacing-base )*0)}.uczvl8kaz84oPQJ2DB2R{padding-left:calc(var( --spacing-base )*0)}.o7UHPcdVK3lt7q3lqV4o{padding:calc(var( --spacing-base )*1)}.IDqEOxvDoYrFYxELPmtX{padding-left:calc(var( --spacing-base )*1);padding-right:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2{padding-bottom:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2,.npy3hw4A5QSkDicb2CJJ{padding-top:calc(var( --spacing-base )*1)}.LgbptTApNY5NwLQvEFAt{padding-right:calc(var( --spacing-base )*1)}.WZQy2SZuZso59bUsXXyl{padding-bottom:calc(var( --spacing-base )*1)}.o331apInxNunbYB3SfPE{padding-left:calc(var( --spacing-base )*1)}.fMPIyD9Vqki1Lrc_yJnG{padding:calc(var( --spacing-base )*2)}.i2pMcTcdrr10IQoiSm_L{padding-left:calc(var( --spacing-base )*2);padding-right:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH{padding-bottom:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH,.o9bGieUKcYc8o0Ij9oZX{padding-top:calc(var( --spacing-base )*2)}.SwZcFez1RDqWsOFjB5iG{padding-right:calc(var( --spacing-base )*2)}.eHpLc_idmuEqeqCTvqkN{padding-bottom:calc(var( --spacing-base )*2)}.vU39i2B4P1fUTMB2l6Vo{padding-left:calc(var( --spacing-base )*2)}.JHWNzBnE29awhdu5BEh1{padding:calc(var( --spacing-base )*3)}.X72lGbb56L3KFzC2xQ9N{padding-left:calc(var( --spacing-base )*3);padding-right:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e{padding-bottom:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e,.srV0KSDC83a2fiimSMMQ{padding-top:calc(var( --spacing-base )*3)}.lUWfkmbQjCskhcNwkyCm{padding-right:calc(var( --spacing-base )*3)}.Ts0dIlc3aTSL7V4cIHis{padding-bottom:calc(var( --spacing-base )*3)}.CzlqQXXhX6MvorArFZ8B{padding-left:calc(var( --spacing-base )*3)}.TqMPkQtR_DdZuKb5vBoV{padding:calc(var( --spacing-base )*4)}.a7UrjhI69Vetlcj9ZVzz{padding-left:calc(var( --spacing-base )*4);padding-right:calc(var( --spacing-base )*4)}.StEhBzGs2Gi5dDEkjhAv{padding-bottom:calc(var( --spacing-base )*4)}.FGneZfZyvYrt1dG0zcnm,.StEhBzGs2Gi5dDEkjhAv{padding-top:calc(var( --spacing-base )*4)}.APEH216rpdlJWgD2fHc8{padding-right:calc(var( --spacing-base )*4)}.oGwXC3ohCic9XnAj6x69{padding-bottom:calc(var( --spacing-base )*4)}.U6gnT9y42ViPNOcNzBwb{padding-left:calc(var( --spacing-base )*4)}.IpdRLBwnHqbqFrixgbYC{padding:calc(var( --spacing-base )*5)}.HgNeXvkBa9o3bQ5fvFZm{padding-left:calc(var( --spacing-base )*5);padding-right:calc(var( --spacing-base )*5)}.tJtFZM3XfPG9v9TSDfN1{padding-bottom:calc(var( --spacing-base )*5)}.PdifHW45QeXYfK568uD8,.tJtFZM3XfPG9v9TSDfN1{padding-top:calc(var( --spacing-base )*5)}.mbLkWTTZ0Za_BBbFZ5b2{padding-right:calc(var( --spacing-base )*5)}.vVWpZpLlWrkTt0hMk8XU{padding-bottom:calc(var( --spacing-base )*5)}.RxfaJj5a1Nt6IavEo5Zl{padding-left:calc(var( --spacing-base )*5)}.SppJULDGdnOGcjZNCYBy{padding:calc(var( --spacing-base )*6)}.palY2nLwdoyooPUm9Hhk{padding-left:calc(var( --spacing-base )*6);padding-right:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_{padding-bottom:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_,.YEEJ9b90ueQaPfiU8aeN{padding-top:calc(var( --spacing-base )*6)}.QE0ssnsKvWJMqlhPbY5u{padding-right:calc(var( --spacing-base )*6)}.n8yA3jHlMRyLd5UIfoND{padding-bottom:calc(var( --spacing-base )*6)}.tXHmxYnHzbwtfxEaG51n{padding-left:calc(var( --spacing-base )*6)}.kBTsPKkO_3g_tLkj77Um{padding:calc(var( --spacing-base )*7)}.RyhrFx6Y1FGDrGAAyaxm{padding-left:calc(var( --spacing-base )*7);padding-right:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO{padding-bottom:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO,.vQVSq6SvWKbOMu6r4H6b{padding-top:calc(var( --spacing-base )*7)}.oBy5__aEADMsH46mrgFX{padding-right:calc(var( --spacing-base )*7)}.KVEXoJqf1s92j0JMdNmN{padding-bottom:calc(var( --spacing-base )*7)}.ZMXGNrNaKW3k_3TLz0Fq{padding-left:calc(var( --spacing-base )*7)}.tuiR9PhkHXhGyEgzRZRI{padding:calc(var( --spacing-base )*8)}.U7454qyWkQNa2iaSJziu{padding-left:calc(var( --spacing-base )*8);padding-right:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8{padding-bottom:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8,.X1rm9DQ1zLGLfogja5Gn{padding-top:calc(var( --spacing-base )*8)}.JS7G6kAuqJo5GIuF8S5t{padding-right:calc(var( --spacing-base )*8)}.Y8F9ga1TDCMbM1lj4gUz{padding-bottom:calc(var( --spacing-base )*8)}.AJuyNGrI63BOWql719H8{padding-left:calc(var( --spacing-base )*8)}.zI5tJ_qhWE6Oe6Lk75GY{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);--wp-admin-border-width-focus:1.51px;border-radius:var(--jp-border-radius);font-weight:600;justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo{height:calc(var(--spacing-base)*5);padding:var(--spacing-base);width:calc(var(--spacing-base)*5)}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo>svg:first-child{margin:0;padding:0}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo.Na39I683LAaSA99REg14{height:calc(var(--spacing-base)*4);min-width:calc(var(--spacing-base)*4);padding:calc(var(--spacing-base)/2);width:calc(var(--spacing-base)*4)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body);height:auto;line-height:24px;padding:var(--spacing-base) calc(var(--spacing-base)*3)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK{padding:var(--spacing-base) calc(var(--spacing-base)*2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body-extra-small);height:auto;line-height:20px;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK>svg:first-child{margin-right:calc(var(--spacing-base)/2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo)>.components-spinner{height:20px}.zI5tJ_qhWE6Oe6Lk75GY.lZAo6_oGfclXOO9CC6Rd{font-weight:400}.zI5tJ_qhWE6Oe6Lk75GY.xJDOiJxTt0R_wSl8Ipz_{min-width:100%}.zI5tJ_qhWE6Oe6Lk75GY.is-primary:disabled,.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:disabled{background:var(--jp-gray);color:var(--jp-gray-20)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary{background:var(--jp-white);box-shadow:inset 0 0 0 1.51px var(--jp-black)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:active:not(:disabled),.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:hover:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-link.Na39I683LAaSA99REg14,.zI5tJ_qhWE6Oe6Lk75GY.is-link.ipS7tKy9GntCS4R3vekF{padding:0}.zI5tJ_qhWE6Oe6Lk75GY.is-link:hover:not(:disabled){text-decoration-thickness:3px}.zI5tJ_qhWE6Oe6Lk75GY.is-link:focus:not(:disabled){text-decoration-line:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:not(:disabled){background:var(--jp-red-50);box-shadow:inset 0 0 0 1px var(--jp-red-50);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:hover:not(:disabled){background:var(--jp-red-60);box-shadow:inset 0 0 0 1px var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:focus:not(:disabled){background:var(--jp-red-70);box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:active:not(:disabled){background:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:not(:disabled){background:var(--jp-white);box-shadow:inset 0 0 0 1.5px var(--jp-red-50);color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:hover:not(:disabled){background:var(--jp-red-0);box-shadow:inset 0 0 0 1.5px var(--jp-red-60);color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:active:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:not(:disabled){color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:hover:not(:disabled){box-shadow:none;color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6{position:relative}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6.has-icon{justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>:not(.components-spinner){visibility:hidden}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>.components-spinner{margin:0;position:absolute}.CDuBjJp_8jxzx5j6Nept{margin-left:calc(var(--spacing-base)/2)}.kdsaL7c4bpTwf_A4fIUT{padding-bottom:calc(var(--spacing-base)*6);padding-top:calc(var(--spacing-base)*6);text-align:center}.b0eN3as5AgxQW7EAkarg{margin-bottom:0}@keyframes rotate-spinner{to{transform:rotate(1turn)}}.jp-components-spinner{align-items:center;display:flex}.jp-components-spinner__inner,.jp-components-spinner__outer{animation:3s linear infinite;animation-name:rotate-spinner;border:.1em solid #0000;border-radius:50%;box-sizing:border-box;margin:auto}.jp-components-spinner__outer{border-top-color:#fff}.jp-components-spinner__inner{border-right-color:#fff;border-top-color:#fff;height:100%;opacity:.4;width:100%}.NHzH3tt6CypjZ92CvK9x{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:flex;padding:calc(var(--spacing-base)*2)}.NHzH3tt6CypjZ92CvK9x:first-of-type{border-top-left-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius)}.NHzH3tt6CypjZ92CvK9x:last-of-type{border-bottom-left-radius:var(--jp-border-radius);border-bottom-right-radius:var(--jp-border-radius)}.NHzH3tt6CypjZ92CvK9x+.NHzH3tt6CypjZ92CvK9x{border-top:0}.D9zvYDUrOP_zwSm0yJMs{margin-right:calc(var(--spacing-base)*2);min-width:24px}._XISfmbjoVlqhB61hHYn{width:100%}.AQDPBnMZFu7BOBuo8mYW{font-size:18px;font-weight:600;line-height:24px;margin-bottom:0}.cZ9s5eCAZe3R82Y6Ru3z{color:var(--jp-gray-80);font-size:14px;line-height:21px}.AKnbWQiViZ2O_dwCV8Fw,.W6alQ2_S5Rh06djX9m27{align-self:center;margin-left:calc(var(--spacing-base)*2);margin-right:var(--spacing-base)}.VLE2X0rP3Ug4QHebdiJd{background-color:var(--jp-gray-0);border-radius:4px;color:var(--jp-gray-80);display:inline-block;font-size:13px;font-weight:400;line-height:16px;padding:4px 8px}.VLE2X0rP3Ug4QHebdiJd.hEfxH6nau4tQkeE4BNms{background-color:var(--jp-green-5);color:var(--jp-green-50)}.VLE2X0rP3Ug4QHebdiJd.Snl4I6aKbXFIrcWaSIC0{background-color:var(--jp-yellow-5);color:var(--jp-yellow-60)}.VLE2X0rP3Ug4QHebdiJd.zvZFUdy480Xv3IHYbX6a{background-color:var(--jp-red-5);color:var(--jp-red-70)}.uUEJGMrSV3XoBwX5xEwA{display:flex;justify-content:space-between}.sQkG5Cu80gPaeFj3L_wa{margin-bottom:calc(var(--spacing-base)*5)}.oIl6GCMeUnzE0inXbuj9{display:flex;justify-content:space-between}.RP2MVoGqaCFXPKZhhxQ1{margin-bottom:calc(var(--spacing-base)*5)}.YpEs8b7KE7fzVuXUbOEb{display:flex;justify-content:space-between}.EqpwvErHtRi_WQkJKgi1{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:flex;margin-bottom:calc(var(--spacing-base)*3);padding:calc(var(--spacing-base)*2)}.EicvN1QaJu5OJLzdUN5A{margin-right:calc(var(--spacing-base)*2);min-width:24px}.b7ynAmUwGlxK_vxyIN0y{width:100%}.uSV9HYRxjL4S6zIZDlqP{font-size:18px;font-weight:600;line-height:24px;margin-bottom:0}.XpW8Mvw_XFEbqxUdw155{color:var(--jp-gray-80);font-size:14px;line-height:21px}.Fkj60BmQ5sUo9zHcJwVv{align-self:center;margin-left:calc(var(--spacing-base)*2);margin-right:var(--spacing-base)}.XLzPr74ad3osCq9kxy2q{display:flex;justify-content:space-between}.jNlU3vgp4xEGwmX5aTyK{background-color:var(--jp-gray-5)}.gE8s4nh3f7iGIBrFeyCT{list-style-type:disc;padding-left:calc(var(--spacing-base)*2.5)}.L9hh_sX51PzO41icwJlh{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:flex;margin-bottom:calc(var(--spacing-base)*3);padding:calc(var(--spacing-base)*2)}.o8E4Bv6U0d7USFxSjRCj{margin-right:calc(var(--spacing-base)*2);min-width:24px}.sT31awD6bHO8KJewvmaO{width:100%}.VVTRIG51r8ORUIBPs5gN{font-size:18px;font-weight:600;line-height:24px;margin-bottom:0}.AiaWRbRLFT9xvP9vn5jA{color:var(--jp-gray-80);font-size:14px;line-height:21px}.MP1wWkqvqfvAc7Izl7x4{align-self:center;margin-left:calc(var(--spacing-base)*2);margin-right:var(--spacing-base)}.i9X_KxEJiGpRT7q_RU6i{display:flex;justify-content:space-between}.WtVEv641JBaLl929sZq2{align-items:flex-start;background-color:#00000040;bottom:0;display:flex;justify-content:center;left:0;overflow-y:auto;padding-top:calc(var(--spacing-base)*12 + 2px);position:fixed;right:0;top:0;z-index:1000001}.G0aPt7WmA1rkUE0wcTno{background:var(--jp-white);border:1px solid var(--jp-gray);border-radius:calc(var(--jp-border-radius)*2);box-shadow:0 8px 20px #00000040;padding:calc(var(--spacing-base)*4);position:relative;width:616px}.VkrhWjfEIlIwYEumycbP{background:none;border:none;cursor:pointer;padding:0;position:absolute;right:calc(var(--spacing-base)*3);top:calc(var(--spacing-base)*3)}.yFzeV4cmWRbZKk5tIyEw{display:block}.lyrXe0pA852TUmyekDb5{display:flex}.KgEeDTKgTC5ZjzYlbTqN{color:var(--jp-black);font-size:var(--font-body);line-height:1.5;margin-right:calc(var(--spacing-base)*4);padding:var(--spacing-base) 0;text-decoration:none}.KgEeDTKgTC5ZjzYlbTqN:last-child{margin-right:0}.KgEeDTKgTC5ZjzYlbTqN:focus,.KgEeDTKgTC5ZjzYlbTqN:hover{border-bottom-color:var(--jp-green);box-shadow:none;color:var(--jp-green)}.Lv4WoNVkeJntqvUyG4dX{border-bottom:1px solid var(--jp-black)}.YXKeyNLeZvIdah_5_5GR{white-space:nowrap}.vvXnRXxrU1kP1KsdSr4J{margin-top:calc(var(--spacing-base)*3*-1)}.aDCTkUFaJEeZzYYE6qv5{background-color:var(--jp-green);border-radius:32px;color:var(--jp-white);font-size:12px;letter-spacing:-2%;line-height:1;margin-left:var(--spacing-base);padding:calc(var(--spacing-base)/2) var(--spacing-base);position:relative;top:-1px}.jp-dashboard-footer{align-items:center;color:var(--jp-black);display:flex;flex-wrap:wrap;font-size:var(--font-body-extra-small);line-height:1.333;max-width:1128px;width:100%}.jp-dashboard-footer a{text-decoration:none}.jp-dashboard-footer a:any-link,.jp-dashboard-footer a[role=button]{color:inherit}.jp-dashboard-footer a:hover{text-decoration:underline;text-decoration-thickness:1.5px}.jp-dashboard-footer a:focus{box-shadow:none;outline-width:0}.jp-dashboard-footer a:focus-visible{border-radius:2px;box-shadow:none;outline:1.5px solid currentColor;outline-offset:3px}.jp-dashboard-footer.is-sm>ul{gap:.125rem}.jp-dashboard-footer.is-md,.jp-dashboard-footer.is-sm>ul{align-items:flex-start;flex-direction:column}.jp-dashboard-footer>ul{align-items:center;display:flex;flex-wrap:wrap;gap:1rem;list-style:none;margin:0;padding:0;width:100%}.jp-dashboard-footer>ul>li{margin-bottom:0}.jp-dashboard-footer>ul>li>a{align-items:center;display:flex;gap:.25rem;min-height:44px}.jp-dashboard-footer__accessible-external-link{border:0;clip:rect(1px,1px,1px,1px);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;overflow-wrap:normal;padding:0;position:absolute;width:1px}.jp-dashboard-footer__jp-item{font-weight:600;padding-inline-end:1rem}.jp-dashboard-footer.is-sm .jp-dashboard-footer__jp-item{padding-bottom:1rem}.jp-dashboard-footer.is-lg .jp-dashboard-footer__a8c-item{margin-inline-start:auto}.jp-dashboard-footer.is-sm .jp-dashboard-footer__a8c-item{padding-top:1rem}.jp-dashboard-footer__a8c-item>a,.jp-dashboard-footer__jp-item>a{text-decoration:none}@media(max-width:599px){.RuVLl3q4lxTQa3wbhBJB{grid-column-end:span 1}.f9LZTRG4MMK42rS89afW{grid-column-start:1}.bHe_zKxjjpUwHw_MdYE1{grid-column-end:2}.QZbNrOqE2aNSn50xVhpU{grid-column-end:span 2}.ev7W3z7zVYPeHAlYqZjf{grid-column-start:2}.NJWd1m_e7lOiPYru2ZMP{grid-column-end:3}.Xc6nt1Qc1DI0Z2A3gt1r{grid-column-end:span 3}.UIcN_GXiPRoIsin8Kohg{grid-column-start:3}.GRKCyqb5LufCSCgykKFc{grid-column-end:4}.i_qTq8gqhhC3vIUepVRB{grid-column-end:span 4}.G3qaZ3Jpbvam_1XvGxgc{grid-column-start:4}.VRCNYKZtO9zukEwmgP1y{grid-column-end:5}}@media(min-width:600px)and (max-width:959px){.tRm008K_WJL79WoNZTNL{grid-column-end:span 1}.l5T2P_bgKts4tdaRkS1d{grid-column-start:1}.zOCxfLZpF6BlgC7a_Yq1{grid-column-end:2}.F80DdgVn0m5OpvtSQWka{grid-column-end:span 2}.oI1c7JYfiJtMQHbhngtU{grid-column-start:2}.pMQtA_4jh1_1lVknqEP5{grid-column-end:3}.VenqMpdgyKQVUNNQcfqd{grid-column-end:span 3}.seNYL99uoczf9V4MxBxT{grid-column-start:3}.YKfF1HFhI9KygA5l3b2J{grid-column-end:4}.yAi0Cv1xDWkoqsaUhvhR{grid-column-end:span 4}.ubhnyZOnkgxNhh6XtVWv{grid-column-start:4}.RGOPGQbWMJ9Ei5oFxS7X{grid-column-end:5}.Sz1E2aWbX483ijdi6yge{grid-column-end:span 5}.tku6_bRYrX9tMbgYGmIl{grid-column-start:5}.b5JHttOhSEcI1WBlqAjk{grid-column-end:6}.FboSx5MoKTAWbxXyYlCw{grid-column-end:span 6}.Jhs8yEEmodG30edbJvag{grid-column-start:6}.IpzbbKVqEqPcfIGkXkwt{grid-column-end:7}.mhCPwfAZ4Kmm_empzJAq{grid-column-end:span 7}.x034ilrJF7rO9UJB2rI1{grid-column-start:7}.Wt8t2e16viRrOJ1lLA5v{grid-column-end:8}.S6pIrEy9AMLKx9bgh_Ae{grid-column-end:span 8}.kEfI4tGyuWfHTlRnvIab{grid-column-start:8}.PUzX4RRsKq1dnsz3gebS{grid-column-end:9}}@media(min-width:960px){.X_pdcLJikd8LS_YAdJlB{grid-column-end:span 1}.tl936d14Huby4khYp05X{grid-column-start:1}.hnge0LnR69d3NXEtEE1t{grid-column-end:2}.fj0NUMuyZQcPNgKcjp5Z{grid-column-end:span 2}.R2ncBX7a2NigdYCcV1OX{grid-column-start:2}.t8vMSDVYno9k9itRwnXb{grid-column-end:3}.wsDuEN2GqHx6qzo8dUdk{grid-column-end:span 3}.cIEVPUweWtLBy3xaXnMx{grid-column-start:3}.fajUWBwu1m2B479j3jmz{grid-column-end:4}.YR0c7fQTgMkDdWzwSyLp{grid-column-end:span 4}.xlwp8BmplxkKNMI7gamo{grid-column-start:4}._C4O1w9DUqx1m3gPf8aA{grid-column-end:5}.Z54F1hAErckAIrKlxnXW{grid-column-end:span 5}.ezSDWkRHmKSxDJXxuiOH{grid-column-start:5}.T0ChoeAjGJjkkNrYhD4g{grid-column-end:6}.qtMoMPF6yHvGJnWHSsde{grid-column-end:span 6}.gdoywN5VPiWERfIBqkph{grid-column-start:6}.wUev_VH5uf_pwFFlbnAU{grid-column-end:7}.egIPDFJsOpownTClq9XP{grid-column-end:span 7}.yGhp9yoAW7k0kQik9AB7{grid-column-start:7}.SJ43U9mR5wUg5V2qBeQA{grid-column-end:8}.cTuyHfMwSUJxN_HdIEgd{grid-column-end:span 8}.smCr8DaIagcumdvdldiK{grid-column-start:8}.T03NHzQJvzwL6wAfIiTL{grid-column-end:9}.pMvxM3RJGjqyNdf9qg1Y{grid-column-end:span 9}.iIVpNRwEnQ_JI5gpp9EN{grid-column-start:9}.ZbQ4u4vGSX5rJOje4uGL{grid-column-end:10}.gKb5wuIDAlKGbrjK2vxy{grid-column-end:span 10}.Z7pINdImE2WJiYnZBTqm{grid-column-start:10}.ZTxp6qpvwurMdOnLLSz1{grid-column-end:11}.NnQTlbfnxPDR6cQ7rygg{grid-column-end:span 11}.O137wZd6Yl0olSA9PsXR{grid-column-start:11}.zf2OJtQ2MPz6SDoh6CB0{grid-column-end:12}.U3H6UHW6HqRt9hdzVg3O{grid-column-end:span 12}.zynnNeS_ZBTxABcVpUQH{grid-column-start:12}.vI8tltFZtFUNAy9Iag9s{grid-column-end:13}}.SqdhUZkXCRuIpErj1B3z{--max-container-width:1128px;--vertical-gutter:24px;--horizontal-spacing:8px;column-gap:var(--vertical-gutter);display:grid;margin:0 auto;max-width:var(--max-container-width);width:100%}@media(max-width:599px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(4,minmax(0,1fr));padding:0 16px}}@media(min-width:600px)and (max-width:959px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(8,minmax(0,1fr));padding:0 18px}}@media(min-width:960px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(12,minmax(0,1fr));padding:0 24px}}.SqdhUZkXCRuIpErj1B3z.OZC_9a1LhpWF9dv15Gdh{max-width:none;padding:unset}.sexr0jUxC1jVixdKiDnC{margin-left:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-left:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.sexr0jUxC1jVixdKiDnC .iWGAhN9gOB48g0jEO1OQ{align-items:center;display:flex;gap:8px}.sexr0jUxC1jVixdKiDnC .JOYmuxQjG4FArIIUxJfA{background:#d63638;color:#fff;cursor:pointer;font-size:9px;font-weight:700;letter-spacing:.2em;text-shadow:none;text-transform:uppercase}.rigH8UdiDrmmSLQMUurD{background-color:var(--jp-white);border:1px solid var(--jp-gray-10);border-radius:var(--jp-border-radius);color:var(--jp-black);display:block;font-size:var(--font-body);letter-spacing:-.02em;line-height:1.5;padding:var(--spacing-base) calc(var(--spacing-base)*1.5);transition:box-shadow .1s ease-out;width:100%}.rigH8UdiDrmmSLQMUurD::placeholder{color:var(--jp-gray-20)}.rigH8UdiDrmmSLQMUurD:focus{box-shadow:0 0 0 2px var(--jp-green-5)}.rigH8UdiDrmmSLQMUurD:focus,.rigH8UdiDrmmSLQMUurD:hover:not(:disabled){border:1px solid var(--jp-green)}.rigH8UdiDrmmSLQMUurD:disabled{background-color:var(--jp-gray-0);color:var(--jp-gray-30)}.V8FDM08CpcwQs4UwN2nI{color:var(--jp-black);display:block;font-size:var(--font-title-small);font-weight:600;margin-bottom:var(--spacing-base)}.WjKn66iJO4hAZYE6o9b3{font-weight:700}.IS5K46VvD7VX5YtlwbMI,.eDfoDi2nArFY_KiYIwKh{margin-bottom:calc(var(--spacing-base)*7);margin-top:calc(var(--spacing-base)*7)}.XKUO6pX9vFbOUplFfCW2{margin-top:calc(var(--spacing-base)*3)}.gridicon{fill:currentColor;display:inline-block}.gridicon.needs-offset g{transform:translate(1px,1px)}.gridicon.needs-offset-x g{transform:translate(1px)}.gridicon.needs-offset-y g{transform:translateY(1px)}:root{--font-title-large:36px;--font-title-small:24px;--font-body:16px;--font-label:12px;--jp-black:#000;--jp-black-80:#2c3338;--jp-white:#fff;--jp-white-off:#f9f9f6;--jp-gray:#dcdcde;--jp-gray-0:#f6f7f7;--jp-gray-5:#dcdcde;--jp-gray-10:#c3c4c7;--jp-gray-20:#a7aaad;--jp-gray-30:#8c8f94;--jp-gray-40:#787c82;--jp-gray-50:#646970;--jp-gray-60:#50575e;--jp-gray-70:#3c434a;--jp-gray-80:#2c3338;--jp-gray-90:#1d2327;--jp-gray-100:#101517;--jp-gray-off:#e2e2df;--jp-yellow-5:#f5e6b3;--jp-yellow-10:#f2cf75;--jp-yellow-40:#c08c00;--jp-orange-20:#faa754;--jp-blue-5:#ced9f2;--jp-red-0:#f7ebec;--jp-red-50:#d63638;--jp-red-60:#b32d2e;--jp-red-80:#8a2424;--jp-red:#d63639;--jp-pink:#c9356e;--jp-green-0:#f0f2eb;--jp-green-5:#d0e6b8;--jp-green-10:#9dd977;--jp-green-20:#64ca43;--jp-green-30:#2fb41f;--jp-green-40:#069e08;--jp-green-50:#008710;--jp-green-60:#007117;--jp-green-70:#005b18;--jp-green-80:#004515;--jp-green-90:#003010;--jp-green-100:#001c09;--jp-green:#069e08;--jp-green-primary:var(--jp-green-40);--jp-green-secondary:var(--jp-green-30);--jp-border-radius:4px;--jp-border-radius-rna:8px;--jp-menu-border-height:1px;--jp-underline-thickness:2px;--jp-modal-padding-large:32px;--jp-modal-padding:24px;--jp-modal-padding-small:16px;--jp-modal-radius:8px;--jp-button-padding:8px;--jp-button-radius:4px;--jp-gap:16px;--jp-highlight:#3858e9}:where(body){font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0;min-height:100%;padding:0}.jp-wrap{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.jp-row{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.jp-row{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.jp-row{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.sm-col-span-1{grid-column-end:span 1}.sm-col-span-2{grid-column-end:span 2}.sm-col-span-3{grid-column-end:span 3}.sm-col-span-4{grid-column-end:span 4}@media(min-width:600px){.md-col-span-1{grid-column-end:span 1}.md-col-span-2{grid-column-end:span 2}.md-col-span-3{grid-column-end:span 3}.md-col-span-4{grid-column-end:span 4}.md-col-span-5{grid-column-end:span 5}.md-col-span-6{grid-column-end:span 6}.md-col-span-7{grid-column-end:span 7}.md-col-span-8{grid-column-end:span 8}}@media(min-width:960px){.lg-col-span-1{grid-column-end:span 1}.lg-col-span-2{grid-column-end:span 2}.lg-col-span-3{grid-column-end:span 3}.lg-col-span-4{grid-column-end:span 4}.lg-col-span-5{grid-column-end:span 5}.lg-col-span-6{grid-column-end:span 6}.lg-col-span-7{grid-column-end:span 7}.lg-col-span-8{grid-column-end:span 8}.lg-col-span-9{grid-column-end:span 9}.lg-col-span-10{grid-column-end:span 10}.lg-col-span-11{grid-column-end:span 11}.lg-col-span-12{grid-column-end:span 12}}@media(max-width:960px){.md-col-span-0{display:none}}@media(max-width:600px){.sm-col-span-0{display:none}}.jp-cut{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);margin:32px 0;padding:16px 64px 16px 24px;position:relative;text-decoration:none}.jp-cut,.jp-cut span{display:block}.jp-cut span:last-of-type{font-weight:600}.jp-cut:focus span:last-of-type,.jp-cut:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.jp-cut:focus:after,.jp-cut:hover:after{transform:translateY(-50%) translateX(8px)}.jp-cut:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;position:absolute;right:24px;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.components-popover:not(.is-without-arrow):before{border-color:var(--jp-gray)}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=left] .components-popover__content{margin-right:-62px}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=right] .components-popover__content{margin-left:-62px}.icon-tooltip-helper .components-popover[data-y-axis=bottom] .components-popover__content{top:2px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:before{top:-6px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:after{top:-4px!important}.icon-tooltip-helper .components-popover[data-y-axis=top] .components-popover__content{bottom:10px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:before{bottom:3px}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:after{bottom:4px}.icon-tooltip-helper.is-wide .components-popover__content{width:440px}.icon-tooltip-wrapper{color:var(--jp-black);display:inline-block;position:relative}.icon-tooltip-wrapper .components-button.is-link:focus:not(:disabled){box-shadow:none}.icon-tooltip-helper{height:18px;left:-53px;pointer-events:none;position:absolute;top:0;width:124px}.icon-tooltip-container{pointer-events:all}.icon-tooltip-container .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;margin:0 10px;max-width:90vw;outline:none;padding:24px;white-space:normal;width:304px}.icon-tooltip-title{font-size:16px;font-weight:600;line-height:19px}.icon-tooltip-title:not(:last-child){margin-bottom:8px}.icon-tooltip-content{font-size:14px;font-weight:400;line-height:24px}.icon-tooltip-content ul{list-style-type:disc;margin:0 0 0 1rem}.icon-tooltip-content ul li:last-child{margin-bottom:0}.msOlyh2T7D6uhbM6AROg{align-items:center;background:none;border:2px solid var(--jp-green-40);border-radius:var(--jp-border-radius);color:var(--jp-gray-80);display:flex;gap:calc(var(--spacing-base)*3);justify-content:space-between;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);position:relative;text-align:left;width:100%}.msOlyh2T7D6uhbM6AROg a,.msOlyh2T7D6uhbM6AROg button{all:unset;color:var(--jp-gray-80);cursor:pointer}.msOlyh2T7D6uhbM6AROg a:after,.msOlyh2T7D6uhbM6AROg button:after{content:"";height:100%;left:0;position:absolute;top:0;width:100%}.msOlyh2T7D6uhbM6AROg:focus-within{border-color:var(--jp-black)}.msOlyh2T7D6uhbM6AROg:focus-within .cPN7USVqSBpxUswfDtUZ,.msOlyh2T7D6uhbM6AROg:hover .cPN7USVqSBpxUswfDtUZ{transform:translateX(calc(var(--spacing-base)*2))}.msOlyh2T7D6uhbM6AROg:focus-within .EmnJAyEzzn1QpA8HtypY,.msOlyh2T7D6uhbM6AROg:hover .EmnJAyEzzn1QpA8HtypY{text-decoration:underline;text-decoration-thickness:2px}.EmnJAyEzzn1QpA8HtypY,.msOlyh2T7D6uhbM6AROg .EmnJAyEzzn1QpA8HtypY{font-weight:700}.cPN7USVqSBpxUswfDtUZ{fill:var(--jp-green-40);pointer-events:none;transition:transform .1s ease-out}.vV7YZikAz0oHYsuvtxMq{display:inline;margin:0 0 0 calc(var(--spacing-base)/3);vertical-align:middle}.vV7YZikAz0oHYsuvtxMq svg{position:relative;z-index:10}.T1YaMupeZmBIpXZHY9EZ{display:inline}.pVJWvyeviifcrLbZZxCj{align-items:flex-start}.pVJWvyeviifcrLbZZxCj,.segmN0DtUjey3r5zVPON{display:flex;flex-direction:column;justify-content:center}.segmN0DtUjey3r5zVPON{align-items:flex-end}.lolS8hq75wfk687xQjbY{margin-bottom:calc(var(--spacing-base)/2*-1);margin-left:var(--spacing-base)}.HC8zzYgv0GvkecCkpyld{width:fit-content}.XJqRbP_azFalXqUoYPtl{margin-top:calc(var(--spacing-base)*3 + 1px)}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off);padding-top:1px}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aLWBKY0yRghEk7tNCgK3{fill:var(--color-bluesky)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.af4Y_zItXvLAOEoSDPSv{fill:var(--color-twitter)}.cbOwD8Y4tFjwimmtchQI.f68aqF3XSD1OBvXR1get{fill:var(--color-linkedin)}.cbOwD8Y4tFjwimmtchQI.xFI0dt3UiXRlRQdqPWkx{fill:var(--color-tumblr)}.cbOwD8Y4tFjwimmtchQI.q7JEoyymveP6kF747M43{fill:var(--color-gplus)}.cbOwD8Y4tFjwimmtchQI.DKOBOTVmTLbh26gUH_73{fill:var(--color-mastodon)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw{fill:var(--color-nextdoor)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.cL3m0xBYTYhIKI7lCqDB{fill:var(--color-instagram)}.cbOwD8Y4tFjwimmtchQI.fftumuc_lJ6v0tq4UMVR{fill:var(--color-whatsapp)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI{fill:var(--color-threads)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI.social-logo{border-radius:40%}.L1LjeCYPldBcTLILS13l{max-width:calc(744px + var(--spacing-base)*6);width:100%}.JWWznnb8sAKHIOhE59_z{display:flex}.JWWznnb8sAKHIOhE59_z:not(:first-child){margin-top:calc(var(--spacing-base)*7)}.kV5wl2UResIqqBdSTuQr{margin-right:calc(var(--spacing-base)*2);padding-top:calc(var(--spacing-base)/2)}@media(min-width:600px){.kV5wl2UResIqqBdSTuQr{margin-right:calc(var(--spacing-base)*5)}}.oePuSIKcH_JzEhDJcHh8{width:100%}.mxYw7vghJF8H8C0FjvPz{align-items:center;display:flex}.lyiOCAyjT_eQyDg8Ier_ .oePuSIKcH_JzEhDJcHh8{opacity:.5}.IclfL4iNXTZfBAbHZdog>:last-child{margin-top:calc(var(--spacing-base)*2)}@media(min-width:600px){.IclfL4iNXTZfBAbHZdog{display:flex;justify-content:space-between}}.bOadM4auwszaOl0el95T{display:flex;flex-wrap:wrap;margin-top:calc(var(--spacing-base)*2)}.G7vkgqk8AEd6pRbNUyE4{color:var(--jp-green-50);margin-right:calc(var(--spacing-base)/2)}.qnlbRElIsj4nB45F5s3a{color:var(--jp-gray-50)}.TvvdPGzRa_ubn3BnQOnQ{color:var(--jp-red-50)}.yAFMUkq1ot9DZF05RUwG{margin-top:calc(var(--spacing-base)*3)}@media(min-width:600px){.yAFMUkq1ot9DZF05RUwG{padding-left:calc(var(--spacing-base)*11)}}.qoajQ2Ew8eYJgdbssSg9{margin-top:calc(var(--spacing-base)*3)}.EbfrbByI7NQ2_MD_gDXp{align-items:center;border:1px solid var(--jp-gray-30);border-radius:4px;color:var(--jp-gray-30);display:flex;font-size:12px;height:21px;margin-bottom:calc(var(--spacing-base)*2);margin-left:var(--spacing-base);padding:calc(var(--spacing-base)/2)}.hCwaBLH_6dELyWWwB8S1{padding:calc(var(--spacing-base)*3);width:304px}.V3U9oKSdRmKjOQ523C86{display:flex;justify-content:space-between}.OSrT4pA4vIGzg9EE6rcv{margin:calc(var(--spacing-base)*-1) calc(var(--spacing-base)*-3)}.OSrT4pA4vIGzg9EE6rcv:focus,.OSrT4pA4vIGzg9EE6rcv:focus:not(:disabled){box-shadow:none}.rbL50q3wwzE6X7VBHcmW{display:flex;justify-content:flex-end}.g593fzjQCE_4rNiiwLdg{line-height:1;margin-bottom:calc(var(--spacing-base)*1.5)}.CIp_BwDbLdjYPSVrreqg{align-items:flex-start;justify-content:space-between}.CIp_BwDbLdjYPSVrreqg,.m2epTt5F7wBQNcMdguwQ{display:flex;margin-top:calc(var(--spacing-base)*2)}.m2epTt5F7wBQNcMdguwQ{justify-content:right}.HrEvG7sxsWbTLD0sk477{border-bottom:2px solid var(--jp-gray-5);margin-top:calc(var(--spacing-base)*7)}.WIttYmnC0O4JKFyPgkTW{padding:calc(var(--spacing-base)*2);width:250px}.p1_cy4ERoY1_uwtgq3Tn{align-items:center;display:flex}.ehnXRuGNl9ZnPh6c1Pa3{display:flex;flex-wrap:wrap;margin-left:auto}.ehnXRuGNl9ZnPh6c1Pa3>:first-child{margin-right:calc(var(--spacing-base)*3)}.ehnXRuGNl9ZnPh6c1Pa3 .q8mOIlVn7qA44s7ysC5Z{opacity:.5}.IxCDeZ2a0wRu3AQbqGuG{align-items:center;display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*3);width:100%}.YIQOtwFZuyfirlpFfjDb{white-space:nowrap}@media(max-width:1115px){.ehnXRuGNl9ZnPh6c1Pa3{margin-top:calc(var(--spacing-base)*3)}}@media(max-width:599px){.ehnXRuGNl9ZnPh6c1Pa3{margin-top:calc(var(--spacing-base)*3)}.ehnXRuGNl9ZnPh6c1Pa3>:first-child{margin-bottom:var(--spacing-base);margin-right:0}.IxCDeZ2a0wRu3AQbqGuG{margin-bottom:0}}.x8nPhsBEpxvgCxHNbCXo{display:flex}.x8nPhsBEpxvgCxHNbCXo .b_pwVVOoMN73AXhJNbgr{margin-right:var(--spacing-base);margin-top:calc(var(--spacing-base)/2)}.MWO4b3hqGdH8p1Vt9zmQ{margin-left:calc(var(--spacing-base)/2);max-height:20px}.DuflEZ86axRQGuMhmH3n{color:var(--jp-gray-20)}.ywr2PcNYcX5_sEzdvHAS{color:var(--jp-gray-70);font-weight:400;line-height:24px}.e_wseeb7HqoyLjv9N_ww{background-color:var(--jp-white-off)}.mzfjOg8s_uehdCmNjX0P,.nxtQ3M8WCX69d_NjShwZ{align-items:flex-start;display:flex;flex-direction:column;gap:calc(var(--spacing-base)*2)}.mzfjOg8s_uehdCmNjX0P .components-toggle-control__label,.nxtQ3M8WCX69d_NjShwZ .components-toggle-control__label{font-size:var(--font-body);font-weight:500}.mzfjOg8s_uehdCmNjX0P .components-base-control__help,.nxtQ3M8WCX69d_NjShwZ .components-base-control__help{color:inherit}.VfIXL69k_I0zUU0s7LqM{background-color:var(--jp-white);border-radius:calc(var(--jp-border-radius)*2);box-shadow:0 4px 40px #00000014;display:flex}.VfIXL69k_I0zUU0s7LqM.SvvAonSzsVSo_5Hu6Goz{align-items:center;padding:calc(var(--spacing-base)*2);width:358px}.VfIXL69k_I0zUU0s7LqM.SvvAonSzsVSo_5Hu6Goz .dwXtyo4qYbpJ2b3rZL1N{align-items:center;display:flex;overflow:hidden;width:100%}.VfIXL69k_I0zUU0s7LqM.SvvAonSzsVSo_5Hu6Goz .WxFqmtANZGuBRdR2NewQ{flex-grow:1;margin:0 calc(var(--spacing-base)*2)}.VfIXL69k_I0zUU0s7LqM.ee2TJQm2FgpSRwchomAH{--square-stat-vertical-spacing:calc(var( --spacing-base )*2);--square-stat-horizontal-spacing:calc(var( --spacing-base )*3);flex-direction:column;height:168px;justify-content:space-between;padding:var(--square-stat-vertical-spacing) var(--square-stat-horizontal-spacing);width:168px}.VfIXL69k_I0zUU0s7LqM.ee2TJQm2FgpSRwchomAH .WxFqmtANZGuBRdR2NewQ{margin-bottom:calc(var(--spacing-base)/2)}.VfIXL69k_I0zUU0s7LqM .mgcKzhKqFk7UOZ156QPT{overflow:hidden;text-overflow:ellipsis}.VfIXL69k_I0zUU0s7LqM .h_uY7ygjuMtuY4ZWJz1R{color:var(--jp-green-40);display:flex;fill:var(--jp-green-40)}.bZ4b33s2MdcOjaDKBbeV{--spacing-base:8px;--wp-admin-border-width-focus:1.5px;align-items:center;display:flex;white-space:nowrap}.UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-gray-50);border-radius:50%;flex-shrink:0;height:.666em;width:.666em}.QuS0vdcr87FsiBvSSrvA{font-weight:600;line-height:1.666;margin-left:calc(var(--spacing-base)/2)}.bZ4b33s2MdcOjaDKBbeV.bGx0wbQAwuY7k8P3PHVQ a,.bZ4b33s2MdcOjaDKBbeV.bGx0wbQAwuY7k8P3PHVQ span{color:var(--jp-green-50)}.bZ4b33s2MdcOjaDKBbeV.bGx0wbQAwuY7k8P3PHVQ .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-green-50)}.bZ4b33s2MdcOjaDKBbeV.wR8Cz8uHgObTQavolv5y a,.bZ4b33s2MdcOjaDKBbeV.wR8Cz8uHgObTQavolv5y span{color:var(--jp-gray-50)}.bZ4b33s2MdcOjaDKBbeV.wR8Cz8uHgObTQavolv5y .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-gray-50)}.bZ4b33s2MdcOjaDKBbeV.IzbBYGwBKhSYFUQlIMww a,.bZ4b33s2MdcOjaDKBbeV.IzbBYGwBKhSYFUQlIMww span{color:var(--jp-red-50)}.bZ4b33s2MdcOjaDKBbeV.IzbBYGwBKhSYFUQlIMww .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-red-50)}.bZ4b33s2MdcOjaDKBbeV.Kdvp_HJf89IBrZuCaLm8 a,.bZ4b33s2MdcOjaDKBbeV.Kdvp_HJf89IBrZuCaLm8 span{color:var(--jp-yellow-30)}.bZ4b33s2MdcOjaDKBbeV.Kdvp_HJf89IBrZuCaLm8 .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-yellow-30)}.bZ4b33s2MdcOjaDKBbeV.hVf5vsbBWm8OFye7cy7a a,.bZ4b33s2MdcOjaDKBbeV.hVf5vsbBWm8OFye7cy7a span{color:var(--jp-blue-40)}.bZ4b33s2MdcOjaDKBbeV.hVf5vsbBWm8OFye7cy7a .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-blue-40)}.gecp_0Z0owRZtj8JAYir{--base-width:8px;--track-width:calc(var(--base-width)*6)}.gecp_0Z0owRZtj8JAYir.qgKXEdMmHsIK84VDnLO2{--base-width:6px}.gecp_0Z0owRZtj8JAYir.Vy6dbB4PsGKm8BDqzJ9J .components-toggle-control__label{display:none}.gecp_0Z0owRZtj8JAYir .components-form-toggle{--wp-admin-theme-color:var( --jp-green-40 );height:calc(var(--base-width)*3)}.gecp_0Z0owRZtj8JAYir .components-form-toggle__input:focus+.components-form-toggle__track{box-shadow:0 0 0 2px var(--jp-white),0 0 0 4px var(--jp-green-50)}.gecp_0Z0owRZtj8JAYir .components-form-toggle .components-form-toggle__track{border-radius:12px;border-width:2px;height:calc(var(--base-width)*3);width:var(--track-width)}.gecp_0Z0owRZtj8JAYir .components-form-toggle .components-form-toggle__thumb{height:calc(var(--base-width)*2);left:calc(var(--base-width)/2);top:calc(var(--base-width)/2);width:calc(var(--base-width)*2)}.gecp_0Z0owRZtj8JAYir .components-form-toggle.is-checked .components-form-toggle__thumb{transform:translateX(calc(var(--base-width)*3))}.gecp_0Z0owRZtj8JAYir .components-toggle-control__help{margin-inline-start:calc(var(--track-width) + var(--spacing-base))}.gecp_0Z0owRZtj8JAYir.ykWv7fKpkVW_vpAoddu4 .components-form-toggle{opacity:.6}.VHYulMcpzbr10HWR0iSE{align-items:flex-start;border:1px solid var(--jp-black);border-color:var(--jp-gray-5);border-left-width:6px;border-radius:4px;display:flex;font-size:var(--font-body);padding:24px 31px 27px 18px}.FGpSkMCiIHQjszcV0dbn{height:calc(var(--spacing-base)*3);margin-right:20px;width:calc(var(--spacing-base)*3)}.KoWZcCwhW13xvkEb0QON{background-color:#0000;border:none;cursor:pointer;outline:none;padding:0}.KoWZcCwhW13xvkEb0QON svg{display:block}@media screen and (max-width:600px){.VHYulMcpzbr10HWR0iSE{box-shadow:0 4px 8px #00000008,0 1px 2px #0000000f;padding-top:68px;position:relative}.FGpSkMCiIHQjszcV0dbn{left:24px;position:absolute;top:24px}.KoWZcCwhW13xvkEb0QON{position:absolute;right:24px;top:24px}}.smrfczkC53EaFM8OJUXs{flex-grow:1}.IKYRWoPwt9xOVEx1wzNS{font-weight:600;margin-bottom:8px}.qM0qY6mPYp1MPN54A3Kg{align-items:center;display:flex;flex-wrap:wrap;margin-top:20px;row-gap:20px}@media screen and (max-width:600px){.qM0qY6mPYp1MPN54A3Kg{justify-content:center}}.qM0qY6mPYp1MPN54A3Kg a,.qM0qY6mPYp1MPN54A3Kg a:active,.qM0qY6mPYp1MPN54A3Kg a:focus,.qM0qY6mPYp1MPN54A3Kg a:hover{color:var(--jp-black)}.qM0qY6mPYp1MPN54A3Kg>*{margin-right:24px}.A5YkDkkXuiYgavrY6Nux{border-left-color:var(--jp-red)}.A5YkDkkXuiYgavrY6Nux .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-red)}.cT5rwuPMZzWvi5o6shMl{border-left-color:var(--jp-yellow-20)}.cT5rwuPMZzWvi5o6shMl .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-yellow-20)}.yo0O3uvNomPsYUXFCpAS{border-left-color:var(--black)}.yo0O3uvNomPsYUXFCpAS .y_IPyP1wIAOhyNaqvXJq{fill:var(--black)}.oZdDFf1jBLkzn5ICCC6x{border-left-color:var(--jp-green)}.oZdDFf1jBLkzn5ICCC6x .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-green)}._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box}.GqFcAwJvIrg1v7f6QUfw{display:flex;flex-direction:column;min-height:230px;padding:calc(var(--spacing-base)*3);width:304px}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S{display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*2)}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S .KnqJLKwSceJTwFJrPGHq{max-width:226px}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S .PJU0_yA9jNf7ao0jhHut{background-color:var(--jp-white);color:var(--jp-gray-90);flex-shrink:0;height:calc(var(--spacing-base)*3);min-width:unset;width:calc(var(--spacing-base)*3)}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S .PJU0_yA9jNf7ao0jhHut:hover:not(:focus){box-shadow:none}.GqFcAwJvIrg1v7f6QUfw .rrORM3zqHfGvqiPduEXY{align-items:flex-end;display:flex;flex-grow:1;height:calc(var(--spacing-base)*6);justify-content:flex-end;margin-top:calc(var(--spacing-base)*2)}.GqFcAwJvIrg1v7f6QUfw .rrORM3zqHfGvqiPduEXY .Q7fUcDUGhteXEr18rZPC{color:var(--jp-gray-60);flex-grow:1;margin-bottom:var(--spacing-base)}.GqFcAwJvIrg1v7f6QUfw .rrORM3zqHfGvqiPduEXY .S5LAeskUiEQ0JlPhr0Ze{flex-shrink:0}.OtDl6kocO_m2s9sRHaqX{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;max-height:600px;width:100%}.BjwJh1S1YVPI7AjmTx6a+.BjwJh1S1YVPI7AjmTx6a{margin-top:calc(var(--spacing-base)*5)}.YWfK8VTp2wnByBauYPKg{background-color:var(--jp-gray-0);overflow-x:scroll;padding:calc(var(--spacing-base)*3)}.pkw2LnOTd8VvQ3oT8sXQ{justify-content:flex-end;margin-top:calc(var(--spacing-base)*3);padding-top:calc(var(--spacing-base)*3)}.ap6lG79CncSqdigJS_WA{margin-top:calc(var(--spacing-base)*4)}.uym7dGHhp6ifjF57yOAO{align-items:flex-end;display:flex;margin-bottom:calc(var(--spacing-base)*2.25)}.e_2eFTR8RyHwmfeqJL4F{flex:1;margin-bottom:0}.IKQVU01PrDMMV5UFLOKv{display:flex;gap:calc(var(--spacing-base)*2)}.pkw2LnOTd8VvQ3oT8sXQ{border-top:1px solid var(--jp-gray);display:flex;justify-content:right;padding-top:calc(var(--spacing-base)*4);width:100%}.pkw2LnOTd8VvQ3oT8sXQ>:last-child{margin-left:calc(var(--spacing-base)*2)}.qazuloIt0teplSEwxRN0{background-color:#fff;border:1px solid var(--jp-gray);border-bottom:none;color:var(--jp-gray-50);display:grid;grid-template-columns:repeat(9,1fr);padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);width:100%}.qazuloIt0teplSEwxRN0>span:first-child{grid-column:1/7}.qazuloIt0teplSEwxRN0>span:not(:first-child){text-align:center}.iJ_biSBRDribuNKX0Zuw{margin:calc(var(--spacing-base)*4) calc(var(--spacing-base)*8);text-align:center}@media(max-width:599px){.uym7dGHhp6ifjF57yOAO{margin-bottom:calc(var(--spacing-base)*3)}.e_2eFTR8RyHwmfeqJL4F{display:none}.pkw2LnOTd8VvQ3oT8sXQ{justify-content:center}.pkw2LnOTd8VvQ3oT8sXQ>*{width:50%}}.v640YfEL85A9rCvyHSzW{align-items:center;display:flex;gap:4px;justify-content:center;margin-bottom:calc(var(--spacing-base)*2);margin-top:calc(var(--spacing-base)*4)}.v640YfEL85A9rCvyHSzW button{font-size:var(--font-body);height:auto;line-height:32px;min-width:32px;padding:0 var(--spacing-base);width:auto}.v640YfEL85A9rCvyHSzW button.gfxpe4zp6ShFsIsce8Ii,.v640YfEL85A9rCvyHSzW button.gfxpe4zp6ShFsIsce8Ii:hover:not(:disabled){background:none;color:var(--jp-black)}.x8UuVEhWucPfdq0hEJg6{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius)}.x8UuVEhWucPfdq0hEJg6>:not(:last-child){border-bottom:1px solid var(--jp-gray)}.eb6Ovfvm1yONz4mdOwbH{background-color:var(--jp-white)}.jF9LXpXR3TxZVDw7TVXT{align-items:center;background:none;border:none;box-sizing:border-box;cursor:pointer;display:grid;grid-template-columns:repeat(9,1fr);margin:0;outline-color:var(--jp-black);padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);text-align:start;width:100%}.jF9LXpXR3TxZVDw7TVXT>:first-of-type{grid-column:1/8}.jF9LXpXR3TxZVDw7TVXT>:last-of-type{grid-column:9}.jF9LXpXR3TxZVDw7TVXT:hover{background:var(--jp-gray-0)}.lNQgAfpwdAUSOLZd8dlD{align-items:center;display:flex;font-size:var(--font-body-small);font-weight:400}.WRQwDYPdffWznX158azR{margin-right:var(--spacing-base)}.dJx9pvlYjDnKn11n5wo8{font-weight:600;margin-bottom:var(--spacing-base);margin-left:calc(var(--spacing-base)*4)}.EKcbLuSblRc7UpzgsFXw{align-items:center}.ILMBWlMLcXc0n97IisrG{overflow:hidden;transform-origin:top center}.T8XIzCNJBQy1UETN5gjU{max-height:0;padding:0;transform:scaleY(0);transition:all .1s}.kWoHGiaZSbq9XJVyUOMC{max-height:1000px;padding:calc(var(--spacing-base)*4) calc(var(--spacing-base)*7);transform:scaleY(1);transition:max-height .3s,transform .2s}.HQgjxePFDRJHamBAGcVU{background-color:var(--jp-white);border-radius:var(--jp-border-radius);box-shadow:0 0 40px #00000014;margin:0}.KtdsNIMumOoHNWMLmuAJ{align-items:center;display:flex;justify-content:space-between;margin:0;padding:calc(var(--spacing-base)*2);text-align:left}.KtdsNIMumOoHNWMLmuAJ.ewyV4ZGn34WDNXmK3ej2{cursor:pointer;outline-color:var(--jp-black)}.KtdsNIMumOoHNWMLmuAJ.ewyV4ZGn34WDNXmK3ej2:focus:not(.owofT85W_XvVdb5vr1GN),.KtdsNIMumOoHNWMLmuAJ.ewyV4ZGn34WDNXmK3ej2:hover:not(.owofT85W_XvVdb5vr1GN){background-color:var(--jp-gray-0)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN{background-color:var(--jp-black)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN .NESnw2xCLrBpP6WlYZL4{color:var(--jp-white)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN .aohnd_y_1lrMuww8NH63{fill:var(--jp-white)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN .Rnas_2_2_eLZSYfZ347E{background-color:var(--jp-red);border:1px solid var(--jp-red);color:var(--jp-white)}.NESnw2xCLrBpP6WlYZL4{align-items:center;display:flex;overflow-x:hidden;padding-right:var(--spacing-base)}.m4_14yNRByDyO9yf9pGg{display:block;overflow-x:hidden;text-overflow:ellipsis}.aohnd_y_1lrMuww8NH63{margin-right:calc(var(--spacing-base)*2)}.Rnas_2_2_eLZSYfZ347E{align-items:center;border:1px solid var(--jp-red-60);border-radius:50%;box-sizing:border-box;color:var(--jp-red-60);display:flex;justify-content:center;min-width:30px;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.X8NRHUTBa_4wDvoHN9TT{fill:var(--jp-green-50)}.CsuOteurQlJm4IjXqyZ0{fill:var(--jp-gray-20)}.fvbewglUxEvV1o04yzzp{--icon-size:28px;--item-spacing:calc(var( --spacing-base )*2);--left-spacing:calc(var( --icon-size ) + var( --item-spacing ));list-style:none}.DINy59MKjwiQanaoDTiV{padding:calc(var(--spacing-base)*2)}.XoacHJljw8zRW_fkBSyg{padding:0}.mXM4WZRePVTa07dhQ6MD{margin-left:var(--left-spacing)}.sI3V8khLdCqxkhJQ_XnI{display:flex;justify-content:flex-start;padding:calc(var(--spacing-base)*2)}.hgdxMuIvZwTZ0sfXaols{padding:calc(var(--spacing-base)*2);width:250px}.UErHS2HAh1gszGfYuVIf{align-items:center;background-color:var(--jp-white);border:1px solid var(--jp-gray-10);border-radius:var(--jp-border-radius);display:flex;justify-content:space-between;padding:calc(var(--spacing-base)*2);width:100%}.lEhH1hvCcxLVFMHI8Gwv{display:flex;justify-content:flex-start}.c57Vj4QhAHwcK_HZMxtN{margin-right:var(--spacing-base)}.sfXsfklfkeSRtE9ivQwF{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:inline-block;width:100%}.sfXsfklfkeSRtE9ivQwF>:not(:last-child){border-bottom:1px solid var(--jp-gray)}.ozRrKPlj1QFGUyd3oVke{background-color:var(--jp-white)}.PyvnSHQuuUkZvVsArigy{align-items:center;background:none;border:none;box-sizing:border-box;cursor:pointer;display:grid;grid-template-columns:repeat(9,1fr);margin:0;outline-color:var(--jp-black);padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);text-align:start;width:100%}.PyvnSHQuuUkZvVsArigy>:first-of-type{grid-column:1/7}.PyvnSHQuuUkZvVsArigy>:last-of-type{grid-column:9}.PyvnSHQuuUkZvVsArigy>:not(:first-child){margin:auto}.PyvnSHQuuUkZvVsArigy:hover{background:var(--jp-gray-0)}.u9Xod5s8bCRNj9MR1Drl{align-items:center;display:flex;font-size:var(--font-body-small);font-weight:400}.IbeyulkpO9kjYJ4OkYUD{margin-right:var(--spacing-base)}.KiCgmjHm2f0JDU3cMsgf{font-weight:600}.KiCgmjHm2f0JDU3cMsgf,.kh5zuLR1zNf7KCsxhAZ5{margin-bottom:var(--spacing-base);margin-left:calc(var(--spacing-base)*4)}.kh5zuLR1zNf7KCsxhAZ5{font-size:var(--font-body-small);font-weight:400}.z1z63g62c73XbcPk9DWc{background-color:var(--jp-gray-50);display:inline-block;height:4px;margin:2px 12px;width:4px}.kJ8t3FAtd5VAYjk31SfA{align-items:center}.JP0IJZcYRohfgntEozjm{overflow:hidden;transform-origin:top center}.y7c6zi2wjEnbW3F29fmP{max-height:0;padding:0;transform:scaleY(0);transition:all .1s}.wQWiN_J0SqgduvadyGnm{max-height:1000px;padding:calc(var(--spacing-base)*4) calc(var(--spacing-base)*7);transform:scaleY(1);transition:max-height .3s,transform .2s}.v1fUFCBPmd6miSCf_ehK{fill:var(--jp-green-40)}.oR9QG6gRLvyzqiuIarmu{border-radius:32px;flex-shrink:0;font-size:12px;font-style:normal;font-weight:600;line-height:16px;margin-left:calc(var(--spacing-base)*4);padding:calc(var(--spacing-base)/2);position:relative;text-align:center;width:60px}.oR9QG6gRLvyzqiuIarmu.bZ8KDXMWoim85Zv31E7E{background-color:#008a20;color:var(--jp-white)}.oR9QG6gRLvyzqiuIarmu.uYEkrN4rh8n5cs3aPrYC{background-color:var(--jp-gray-50);color:var(--jp-white)}.WOX88CWB12lzxcMcl_ns{color:#008a20}.H2J5mHqyiBHXCAyZ4KGa{color:inherit}.H2J5mHqyiBHXCAyZ4KGa:focus,.H2J5mHqyiBHXCAyZ4KGa:hover{box-shadow:none;color:inherit}.BT16ByfO8ktYf15hbMG8{margin-left:calc(var(--spacing-base)/2);max-height:20px}.Gi6geVLkEyrClNXuJ34I{color:var(--jp-red)}.Q02oRBdY3ZpNGOF2Y1iV{color:var(--jp-gray-70);font-weight:400;line-height:24px}@media(max-width:599px){.PyvnSHQuuUkZvVsArigy{display:grid;grid-auto-rows:minmax(auto,auto)}.PyvnSHQuuUkZvVsArigy>:first-child{grid-column:1/8;grid-row:1}.PyvnSHQuuUkZvVsArigy>:nth-child(2){grid-row:2;padding-left:calc(var(--spacing-base)*4)}.PyvnSHQuuUkZvVsArigy>:nth-child(3){grid-row:2}.PyvnSHQuuUkZvVsArigy>:nth-child(3) span{margin-top:var(--spacing-base);position:absolute}.PyvnSHQuuUkZvVsArigy>:last-child{grid-column:10;grid-row:1/3}.oR9QG6gRLvyzqiuIarmu{display:none}}@media(max-width:1200px){.kh5zuLR1zNf7KCsxhAZ5{display:grid}.z1z63g62c73XbcPk9DWc{display:none}}.SunkAzopVEoBZbCUFkpe{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:monospace;overflow-x:auto;padding:0}.s6eJjt_RVhQ8mEG1qQYb{background-color:var(--jp-red-0)}.cW2860S1RCjdsufX8ds_{display:flex;flex-direction:column;text-align:right}.hU_xmjv3sGJgIvV_26Ik{background-color:var(--jp-gray-10);color:var(--font-body);padding:0 calc(var(--spacing-base)/2)}.hU_xmjv3sGJgIvV_26Ik.s6eJjt_RVhQ8mEG1qQYb{background-color:var(--jp-red-50);color:var(--jp-white)}.O5ZaHoo1pFRkk_GUUczG{display:flex;flex:1;flex-direction:column;overflow-x:visible;white-space:pre}.UoS_E4HwI88HfDMpNtvB{padding-left:var(--spacing-base)}.ZotWIwUISq6XCpIyD8k7{background-color:var(--jp-red);border-radius:calc(var(--jp-border-radius)/2);color:var(--jp-white);padding:calc(var(--spacing-base)/4) calc(var(--spacing-base)/2)}.HPsJA6B0f3Bd2tZgEr7v{font-size:var(--font-body);line-height:1.5}.WA0OogO0bZSYbqUPL9aa{background-color:var(--jp-gray-10);font-weight:600;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.Z1NxA7aDh5LEYjbLLKbF{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:Courier\ 10 Pitch,Courier,monospace;overflow-x:auto;white-space:pre}.aeQS3Qb4g1FwDY0HaZKb{background-color:var(--jp-gray-10);color:var(--jp-gray-50);display:flex;flex-direction:column;padding:0 var(--spacing-base);text-align:right}.ESXyHLdGmRLZMv7_Ei9d{display:flex;flex-direction:column;flex-grow:1;overflow-x:visible}.ESXyHLdGmRLZMv7_Ei9d del,.ESXyHLdGmRLZMv7_Ei9d div,.ESXyHLdGmRLZMv7_Ei9d ins{padding:0 var(--spacing-base);text-decoration:none}.ESXyHLdGmRLZMv7_Ei9d del{background-color:var(--jp-red-0);color:var(--jp-red-60)}.ESXyHLdGmRLZMv7_Ei9d ins{background-color:var(--jp-green-5);color:var(--jp-green-60)}.XqQBRzrxyMhhZvPXIHgk .components-button{box-shadow:inset 0 0 0 1.5px var(--jp-gray);position:relative}.XqQBRzrxyMhhZvPXIHgk .components-button:first-child{border-radius:var(--jp-border-radius) 0 0 var(--jp-border-radius)}.XqQBRzrxyMhhZvPXIHgk .components-button:last-child{border-radius:0 var(--jp-border-radius) var(--jp-border-radius) 0}.XqQBRzrxyMhhZvPXIHgk .components-button:hover{z-index:1}.XqQBRzrxyMhhZvPXIHgk .components-button+.components-button{margin-left:-1.5px}.iN9oF7KagtrwaFKTquqW{align-items:center;display:flex}.IZTexE5bnJrB25jtwXBW{height:54px;width:54px;fill:var(--jp-red);margin-left:-8px;margin-right:var(--spacing-base)}.YzqaprEdVpBoBJesZixw{margin-top:calc(var(--spacing-base)*3)}.AMcxtVDLtWB2EJJJU5NQ{height:auto;max-width:100%;position:relative;width:330px}.vtViVIQmuI1n8HDxrkNy{animation:BJ0WjZD0MlRR_Usu8HEd 4s ease-in-out .8s infinite normal forwards;opacity:0;position:relative;transform:translateY(24px)}.vtViVIQmuI1n8HDxrkNy:nth-of-type(2){animation-delay:.6s}.vtViVIQmuI1n8HDxrkNy:nth-of-type(3){animation-delay:.7s}@keyframes BJ0WjZD0MlRR_Usu8HEd{0%{opacity:0;transform:translateY(24px)}20%{opacity:1;transform:translateY(0)}50%{opacity:1;transform:translateY(0)}60%{opacity:0;transform:translateY(-48px)}to{opacity:0;transform:translateY(-48px)}}@media(prefers-reduced-motion:reduce){.vtViVIQmuI1n8HDxrkNy{animation:none}}.vzMlFr1AXWqefpRrb976{align-items:center;display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*2)}.gYSOMa4xxLXmsNzvFPkW{background-color:var(--jp-gray-5);border-radius:calc(var(--spacing-base)*3);width:100%}.hNJWdt5qmZkWYAH_vjIp{background-color:var(--jp-green-40);border-radius:calc(var(--spacing-base)*3);height:9px;transition:width .2s}.DHMUfGyHbl5BgD5vjxVz{color:var(--jp-gray-90);font-weight:600;line-height:24px;margin-left:auto;padding-left:var(--spacing-base)}.cAbGtJDGgLubucBnz7vM{background-color:var(--jp-white)}.KmIjHqrMs3duMPaUf50k{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;max-height:600px;width:100%}.bpW3MfTt3siOyvw1ZsuF{font-weight:700}.DJS67UCXVaM7nIMJePYQ{align-items:flex-end;display:flex;justify-content:flex-end;margin-bottom:calc(var(--spacing-base)*2.25)}.s4378tf2MiM0bMIxQZkI{flex:1;margin-bottom:0}.jifq7nsF5kZYrcpGQ35V{display:flex;gap:calc(var(--spacing-base)*2)}@media(max-width:599px){.DJS67UCXVaM7nIMJePYQ{margin-bottom:calc(var(--spacing-base)*3)}.s4378tf2MiM0bMIxQZkI{display:none}}.yjKVIZH3KLvJeygIzaZn{margin-top:calc(var(--spacing-base)*3)}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50);text-decoration:underline;white-space:nowrap}.p4qz2tkq0p9hxucJ6Qk2{--padding:calc(var(--spacing-base)*4);color:var(--jp-black)}.lbNDyXioOwvyvbALtCBm{--gap:calc(var(--spacing-base)*3);padding:var(--padding) 0;position:relative}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm{column-gap:var(--gap);display:grid;grid-auto-flow:column;grid-template-columns:repeat(var(--columns),1fr);grid-template-rows:repeat(var(--rows),minmax(min-content,max-content))}.cLaNK_XcbTGlRQ4Tp43Q{margin-top:var(--padding)}.s2Lsn4kbm6BrS3DSndRB .cLaNK_XcbTGlRQ4Tp43Q{display:contents}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>*{background:var(--jp-white);position:relative}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>:after{bottom:0;box-shadow:0 4px 24px #0000000d;content:"";left:0;position:absolute;right:0;top:0;z-index:-1}.cLaNK_XcbTGlRQ4Tp43Q>:first-child{border-top-left-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius);border-width:1px 1px 0}.cLaNK_XcbTGlRQ4Tp43Q>:last-child{border-bottom-left-radius:var(--jp-border-radius);border-bottom-right-radius:var(--jp-border-radius);border-width:0 1px 1px}.DAkZc1P9A3K12fjEliMg{display:flex;flex-direction:column;justify-content:space-between;padding:var(--padding)}.WUBuYABl8nymjs9NnCEL{align-items:center;display:flex;padding-bottom:calc(var(--spacing-base)*2);position:relative}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)){padding-top:calc(var(--spacing-base)*2)}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{background-color:var(--jp-gray);content:"";height:1px;left:var(--padding);position:absolute;right:var(--padding);top:0;z-index:5}.s2Lsn4kbm6BrS3DSndRB .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{left:0;right:unset;width:calc(100% + var(--gap))}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm>:last-child .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{width:100%}.ANtCFeb41NhA8PA3H7ZN,.WUBuYABl8nymjs9NnCEL:last-of-type{padding-bottom:var(--padding)}.Ql2gy_148yW8Vw5vhaKD{padding-left:var(--padding);padding-right:var(--padding)}.EAQrAnQEW1z1BfdY5gbC{margin:0 var(--spacing-base);fill:var(--jp-gray);flex-shrink:0}.EAQrAnQEW1z1BfdY5gbC.JDSTlLoOC_4aUoH2oNM2{fill:var(--jp-green-40)}.EAQrAnQEW1z1BfdY5gbC.zNdQRJ1w7BvaQOYyqzHK{fill:var(--jp-red-50)}.lr7vbX95SKtoe7DarJcZ{margin-left:auto}.s2Lsn4kbm6BrS3DSndRB .lr7vbX95SKtoe7DarJcZ{margin:0 var(--spacing-base);top:1px}.WUBuYABl8nymjs9NnCEL .KRrGp2xdkeBOxLZeuQ6X{fill:var(--jp-gray-20);flex-shrink:0}.H_ZJiRVJg0LiMXPGOcmt{text-align:center;width:fit-content}.H_ZJiRVJg0LiMXPGOcmt>a{color:#000}.s2Lsn4kbm6BrS3DSndRB .H_ZJiRVJg0LiMXPGOcmt{grid-column:2;overflow:hidden;padding-left:var(--padding);padding-right:var(--padding);white-space:nowrap}.x21z_DixObRDsDaWotP1{align-items:right;display:flex;justify-content:right;margin:0 calc(var(--spacing-base)*4)}.dovianZYLKhnbnh9I06o{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-end}.lljtQMhW7lq5tE5SDJEf{align-items:flex-start;display:flex;flex-basis:0;flex-grow:2}.lljtQMhW7lq5tE5SDJEf .NubApIV1vQCRUNprfm6b{margin-left:auto}.dhFQXpZfMwVI8vuYHnwC{align-items:flex-start;display:inline-flex;flex:0 0 auto;position:relative}.dhFQXpZfMwVI8vuYHnwC:first-child{margin-right:calc(var(--spacing-base)*2)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k{color:var(--jp-gray-20)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k:after{background:var(--jp-red);border-radius:var(--jp-border-radius);content:" ";display:block;height:3px;margin-top:-2px;pointer-events:none;position:absolute;top:50%;width:100%}.C64ZjjUAqJC1T2Sa7apS{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-start;margin-bottom:calc(var(--spacing-base)*3)}.UpZDGew6Ay1hPoP6eI7b{color:var(--jp-gray-40);font-size:var(--font-body-small);line-height:20px}.UpZDGew6Ay1hPoP6eI7b:after{content:"​"}.NubApIV1vQCRUNprfm6b{background-color:var(--jp-yellow-10);border-radius:4px;font-size:13px;font-weight:600;margin-left:var(--spacing-base);padding-left:var(--spacing-base);padding-right:var(--spacing-base)}.TDiiPbuW1Z0_05u_pvcK{font-weight:400}.T1f6nRmWifz5im6hB29M{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;width:100%}.Ki7ehROrWxWBIMIt8SUH:focus:not(:disabled){box-shadow:none}*{box-sizing:border-box}#jetpack-protect-root{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);--wp-admin-border-width-focus:1.51px;--actions-size:28px} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js deleted file mode 100644 index 630de61d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js +++ /dev/null @@ -1,77 +0,0 @@ -/*! For license information please see index.js.LICENSE.txt */ -(()=>{var e={9826:(e,t,a)=>{"use strict";a.d(t,{i:()=>r});const n={AED:{symbol:"د.إ.‏",grouping:",",decimal:".",precision:2},AFN:{symbol:"؋",grouping:",",decimal:".",precision:2},ALL:{symbol:"Lek",grouping:".",decimal:",",precision:2},AMD:{symbol:"֏",grouping:",",decimal:".",precision:2},ANG:{symbol:"ƒ",grouping:",",decimal:".",precision:2},AOA:{symbol:"Kz",grouping:",",decimal:".",precision:2},ARS:{symbol:"$",grouping:".",decimal:",",precision:2},AUD:{symbol:"A$",grouping:",",decimal:".",precision:2},AWG:{symbol:"ƒ",grouping:",",decimal:".",precision:2},AZN:{symbol:"₼",grouping:" ",decimal:",",precision:2},BAM:{symbol:"КМ",grouping:".",decimal:",",precision:2},BBD:{symbol:"Bds$",grouping:",",decimal:".",precision:2},BDT:{symbol:"৳",grouping:",",decimal:".",precision:0},BGN:{symbol:"лв.",grouping:" ",decimal:",",precision:2},BHD:{symbol:"د.ب.‏",grouping:",",decimal:".",precision:3},BIF:{symbol:"FBu",grouping:",",decimal:".",precision:0},BMD:{symbol:"$",grouping:",",decimal:".",precision:2},BND:{symbol:"$",grouping:".",decimal:",",precision:0},BOB:{symbol:"Bs",grouping:".",decimal:",",precision:2},BRL:{symbol:"R$",grouping:".",decimal:",",precision:2},BSD:{symbol:"$",grouping:",",decimal:".",precision:2},BTC:{symbol:"Ƀ",grouping:",",decimal:".",precision:2},BTN:{symbol:"Nu.",grouping:",",decimal:".",precision:1},BWP:{symbol:"P",grouping:",",decimal:".",precision:2},BYR:{symbol:"р.",grouping:" ",decimal:",",precision:2},BZD:{symbol:"BZ$",grouping:",",decimal:".",precision:2},CAD:{symbol:"C$",grouping:",",decimal:".",precision:2},CDF:{symbol:"FC",grouping:",",decimal:".",precision:2},CHF:{symbol:"CHF",grouping:"'",decimal:".",precision:2},CLP:{symbol:"$",grouping:".",decimal:",",precision:2},CNY:{symbol:"¥",grouping:",",decimal:".",precision:2},COP:{symbol:"$",grouping:".",decimal:",",precision:2},CRC:{symbol:"₡",grouping:".",decimal:",",precision:2},CUC:{symbol:"CUC",grouping:",",decimal:".",precision:2},CUP:{symbol:"$MN",grouping:",",decimal:".",precision:2},CVE:{symbol:"$",grouping:",",decimal:".",precision:2},CZK:{symbol:"Kč",grouping:" ",decimal:",",precision:2},DJF:{symbol:"Fdj",grouping:",",decimal:".",precision:0},DKK:{symbol:"kr.",grouping:"",decimal:",",precision:2},DOP:{symbol:"RD$",grouping:",",decimal:".",precision:2},DZD:{symbol:"د.ج.‏",grouping:",",decimal:".",precision:2},EGP:{symbol:"ج.م.‏",grouping:",",decimal:".",precision:2},ERN:{symbol:"Nfk",grouping:",",decimal:".",precision:2},ETB:{symbol:"ETB",grouping:",",decimal:".",precision:2},EUR:{symbol:"€",grouping:".",decimal:",",precision:2},FJD:{symbol:"FJ$",grouping:",",decimal:".",precision:2},FKP:{symbol:"£",grouping:",",decimal:".",precision:2},GBP:{symbol:"£",grouping:",",decimal:".",precision:2},GEL:{symbol:"Lari",grouping:" ",decimal:",",precision:2},GHS:{symbol:"₵",grouping:",",decimal:".",precision:2},GIP:{symbol:"£",grouping:",",decimal:".",precision:2},GMD:{symbol:"D",grouping:",",decimal:".",precision:2},GNF:{symbol:"FG",grouping:",",decimal:".",precision:0},GTQ:{symbol:"Q",grouping:",",decimal:".",precision:2},GYD:{symbol:"G$",grouping:",",decimal:".",precision:2},HKD:{symbol:"HK$",grouping:",",decimal:".",precision:2},HNL:{symbol:"L.",grouping:",",decimal:".",precision:2},HRK:{symbol:"kn",grouping:".",decimal:",",precision:2},HTG:{symbol:"G",grouping:",",decimal:".",precision:2},HUF:{symbol:"Ft",grouping:".",decimal:",",precision:0},IDR:{symbol:"Rp",grouping:".",decimal:",",precision:0},ILS:{symbol:"₪",grouping:",",decimal:".",precision:2},INR:{symbol:"₹",grouping:",",decimal:".",precision:2},IQD:{symbol:"د.ع.‏",grouping:",",decimal:".",precision:2},IRR:{symbol:"﷼",grouping:",",decimal:"/",precision:2},ISK:{symbol:"kr.",grouping:".",decimal:",",precision:0},JMD:{symbol:"J$",grouping:",",decimal:".",precision:2},JOD:{symbol:"د.ا.‏",grouping:",",decimal:".",precision:3},JPY:{symbol:"¥",grouping:",",decimal:".",precision:0},KES:{symbol:"S",grouping:",",decimal:".",precision:2},KGS:{symbol:"сом",grouping:" ",decimal:"-",precision:2},KHR:{symbol:"៛",grouping:",",decimal:".",precision:0},KMF:{symbol:"CF",grouping:",",decimal:".",precision:2},KPW:{symbol:"₩",grouping:",",decimal:".",precision:0},KRW:{symbol:"₩",grouping:",",decimal:".",precision:0},KWD:{symbol:"د.ك.‏",grouping:",",decimal:".",precision:3},KYD:{symbol:"$",grouping:",",decimal:".",precision:2},KZT:{symbol:"₸",grouping:" ",decimal:"-",precision:2},LAK:{symbol:"₭",grouping:",",decimal:".",precision:0},LBP:{symbol:"ل.ل.‏",grouping:",",decimal:".",precision:2},LKR:{symbol:"₨",grouping:",",decimal:".",precision:0},LRD:{symbol:"L$",grouping:",",decimal:".",precision:2},LSL:{symbol:"M",grouping:",",decimal:".",precision:2},LYD:{symbol:"د.ل.‏",grouping:",",decimal:".",precision:3},MAD:{symbol:"د.م.‏",grouping:",",decimal:".",precision:2},MDL:{symbol:"lei",grouping:",",decimal:".",precision:2},MGA:{symbol:"Ar",grouping:",",decimal:".",precision:0},MKD:{symbol:"ден.",grouping:".",decimal:",",precision:2},MMK:{symbol:"K",grouping:",",decimal:".",precision:2},MNT:{symbol:"₮",grouping:" ",decimal:",",precision:2},MOP:{symbol:"MOP$",grouping:",",decimal:".",precision:2},MRO:{symbol:"UM",grouping:",",decimal:".",precision:2},MTL:{symbol:"₤",grouping:",",decimal:".",precision:2},MUR:{symbol:"₨",grouping:",",decimal:".",precision:2},MVR:{symbol:"MVR",grouping:",",decimal:".",precision:1},MWK:{symbol:"MK",grouping:",",decimal:".",precision:2},MXN:{symbol:"MX$",grouping:",",decimal:".",precision:2},MYR:{symbol:"RM",grouping:",",decimal:".",precision:2},MZN:{symbol:"MT",grouping:",",decimal:".",precision:0},NAD:{symbol:"N$",grouping:",",decimal:".",precision:2},NGN:{symbol:"₦",grouping:",",decimal:".",precision:2},NIO:{symbol:"C$",grouping:",",decimal:".",precision:2},NOK:{symbol:"kr",grouping:" ",decimal:",",precision:2},NPR:{symbol:"₨",grouping:",",decimal:".",precision:2},NZD:{symbol:"NZ$",grouping:",",decimal:".",precision:2},OMR:{symbol:"﷼",grouping:",",decimal:".",precision:3},PAB:{symbol:"B/.",grouping:",",decimal:".",precision:2},PEN:{symbol:"S/.",grouping:",",decimal:".",precision:2},PGK:{symbol:"K",grouping:",",decimal:".",precision:2},PHP:{symbol:"₱",grouping:",",decimal:".",precision:2},PKR:{symbol:"₨",grouping:",",decimal:".",precision:2},PLN:{symbol:"zł",grouping:" ",decimal:",",precision:2},PYG:{symbol:"₲",grouping:".",decimal:",",precision:2},QAR:{symbol:"﷼",grouping:",",decimal:".",precision:2},RON:{symbol:"lei",grouping:".",decimal:",",precision:2},RSD:{symbol:"Дин.",grouping:".",decimal:",",precision:2},RUB:{symbol:"₽",grouping:" ",decimal:",",precision:2},RWF:{symbol:"RWF",grouping:" ",decimal:",",precision:2},SAR:{symbol:"﷼",grouping:",",decimal:".",precision:2},SBD:{symbol:"S$",grouping:",",decimal:".",precision:2},SCR:{symbol:"₨",grouping:",",decimal:".",precision:2},SDD:{symbol:"LSd",grouping:",",decimal:".",precision:2},SDG:{symbol:"£‏",grouping:",",decimal:".",precision:2},SEK:{symbol:"kr",grouping:",",decimal:".",precision:2},SGD:{symbol:"S$",grouping:",",decimal:".",precision:2},SHP:{symbol:"£",grouping:",",decimal:".",precision:2},SLL:{symbol:"Le",grouping:",",decimal:".",precision:2},SOS:{symbol:"S",grouping:",",decimal:".",precision:2},SRD:{symbol:"$",grouping:",",decimal:".",precision:2},STD:{symbol:"Db",grouping:",",decimal:".",precision:2},SVC:{symbol:"₡",grouping:",",decimal:".",precision:2},SYP:{symbol:"£",grouping:",",decimal:".",precision:2},SZL:{symbol:"E",grouping:",",decimal:".",precision:2},THB:{symbol:"฿",grouping:",",decimal:".",precision:2},TJS:{symbol:"TJS",grouping:" ",decimal:";",precision:2},TMT:{symbol:"m",grouping:" ",decimal:",",precision:0},TND:{symbol:"د.ت.‏",grouping:",",decimal:".",precision:3},TOP:{symbol:"T$",grouping:",",decimal:".",precision:2},TRY:{symbol:"TL",grouping:".",decimal:",",precision:2},TTD:{symbol:"TT$",grouping:",",decimal:".",precision:2},TVD:{symbol:"$T",grouping:",",decimal:".",precision:2},TWD:{symbol:"NT$",grouping:",",decimal:".",precision:2},TZS:{symbol:"TSh",grouping:",",decimal:".",precision:2},UAH:{symbol:"₴",grouping:" ",decimal:",",precision:2},UGX:{symbol:"USh",grouping:",",decimal:".",precision:2},USD:{symbol:"$",grouping:",",decimal:".",precision:2},UYU:{symbol:"$U",grouping:".",decimal:",",precision:2},UZS:{symbol:"сўм",grouping:" ",decimal:",",precision:2},VEB:{symbol:"Bs.",grouping:",",decimal:".",precision:2},VEF:{symbol:"Bs. F.",grouping:".",decimal:",",precision:2},VND:{symbol:"₫",grouping:".",decimal:",",precision:1},VUV:{symbol:"VT",grouping:",",decimal:".",precision:0},WST:{symbol:"WS$",grouping:",",decimal:".",precision:2},XAF:{symbol:"F",grouping:",",decimal:".",precision:2},XCD:{symbol:"$",grouping:",",decimal:".",precision:2},XOF:{symbol:"F",grouping:" ",decimal:",",precision:2},XPF:{symbol:"F",grouping:",",decimal:".",precision:2},YER:{symbol:"﷼",grouping:",",decimal:".",precision:2},ZAR:{symbol:"R",grouping:" ",decimal:",",precision:2},ZMW:{symbol:"ZK",grouping:",",decimal:".",precision:2},WON:{symbol:"₩",grouping:",",decimal:".",precision:2}};function r(e){return n[e]||{symbol:"$",grouping:",",decimal:".",precision:2}}},7397:(e,t,a)=>{"use strict";a.d(t,{vA:()=>c});var n=a(9826),r=a(8506);function c(e,t,a={}){const c=(0,n.i)(t);if(!c||isNaN(e))return null;const{decimal:s,grouping:i,precision:o,symbol:l}={...c,...a},u=e<0?"-":"",d=Math.abs(e),p=Math.floor(d);return{sign:u,symbol:l,integer:(0,r.A)(d,o,s,i).split(s)[0],fraction:o>0?(0,r.A)(d-p,o,s,i).slice(1):""}}},8506:(e,t,a)=>{"use strict";function n(e,t=0,a=".",n=","){const r=(e+"").replace(/[^0-9+\-Ee.]/g,""),c=isFinite(+r)?+r:0,s=isFinite(+t)?Math.abs(t):0,i=(s?function(e,t){const a=Math.pow(10,t);return""+(Math.round(e*a)/a).toFixed(t)}(c,s):""+Math.round(c)).split(".");return i[0].length>3&&(i[0]=i[0].replace(/\B(?=(?:\d{3})+(?!\d))/g,n)),(i[1]||"").lengthn})},6992:(e,t,a)=>{"use strict";function n(){return n=Object.assign?Object.assign.bind():function(e){for(var t=1;td,B6:()=>x,Gh:()=>z,HS:()=>O,Oi:()=>i,Rr:()=>p,TM:()=>s,pX:()=>H,pb:()=>M,rc:()=>r,tH:()=>D,ue:()=>g,yD:()=>P}),function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"}(r||(r={}));const c="popstate";function s(e){return void 0===e&&(e={}),m((function(e,t){let{pathname:a="/",search:n="",hash:r=""}=p(e.location.hash.substr(1));return a.startsWith("/")||a.startsWith(".")||(a="/"+a),u("",{pathname:a,search:n,hash:r},t.state&&t.state.usr||null,t.state&&t.state.key||"default")}),(function(e,t){let a=e.document.querySelector("base"),n="";if(a&&a.getAttribute("href")){let t=e.location.href,a=t.indexOf("#");n=-1===a?t:t.slice(0,a)}return n+"#"+("string"==typeof t?t:d(t))}),(function(e,t){o("/"===e.pathname.charAt(0),"relative pathnames are not supported in hash history.push("+JSON.stringify(t)+")")}),e)}function i(e,t){if(!1===e||null==e)throw new Error(t)}function o(e,t){if(!e){"undefined"!=typeof console&&console.warn(t);try{throw new Error(t)}catch(e){}}}function l(e,t){return{usr:e.state,key:e.key,idx:t}}function u(e,t,a,r){return void 0===a&&(a=null),n({pathname:"string"==typeof e?e:e.pathname,search:"",hash:""},"string"==typeof t?p(t):t,{state:a,key:t&&t.key||r||Math.random().toString(36).substr(2,8)})}function d(e){let{pathname:t="/",search:a="",hash:n=""}=e;return a&&"?"!==a&&(t+="?"===a.charAt(0)?a:"?"+a),n&&"#"!==n&&(t+="#"===n.charAt(0)?n:"#"+n),t}function p(e){let t={};if(e){let a=e.indexOf("#");a>=0&&(t.hash=e.substr(a),e=e.substr(0,a));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function m(e,t,a,s){void 0===s&&(s={});let{window:o=document.defaultView,v5Compat:p=!1}=s,m=o.history,h=r.Pop,g=null,v=f();function f(){return(m.state||{idx:null}).idx}function y(){h=r.Pop;let e=f(),t=null==e?null:e-v;v=e,g&&g({action:h,location:A.location,delta:t})}function E(e){let t="null"!==o.location.origin?o.location.origin:o.location.href,a="string"==typeof e?e:d(e);return a=a.replace(/ $/,"%20"),i(t,"No window.location.(origin|href) available to create URL for href: "+a),new URL(a,t)}null==v&&(v=0,m.replaceState(n({},m.state,{idx:v}),""));let A={get action(){return h},get location(){return e(o,m)},listen(e){if(g)throw new Error("A history only accepts one active listener");return o.addEventListener(c,y),g=e,()=>{o.removeEventListener(c,y),g=null}},createHref:e=>t(o,e),createURL:E,encodeLocation(e){let t=E(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:function(e,t){h=r.Push;let n=u(A.location,e,t);a&&a(n,e),v=f()+1;let c=l(n,v),s=A.createHref(n);try{m.pushState(c,"",s)}catch(e){if(e instanceof DOMException&&"DataCloneError"===e.name)throw e;o.location.assign(s)}p&&g&&g({action:h,location:A.location,delta:1})},replace:function(e,t){h=r.Replace;let n=u(A.location,e,t);a&&a(n,e),v=f();let c=l(n,v),s=A.createHref(n);m.replaceState(c,"",s),p&&g&&g({action:h,location:A.location,delta:0})},go:e=>m.go(e)};return A}var h;!function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"}(h||(h={}));new Set(["lazy","caseSensitive","path","id","index","children"]);function g(e,t,a){return void 0===a&&(a="/"),v(e,t,a,!1)}function v(e,t,a,n){let r=M(("string"==typeof t?p(t):t).pathname||"/",a);if(null==r)return null;let c=f(e);!function(e){e.sort(((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let a=e.length===t.length&&e.slice(0,-1).every(((e,a)=>e===t[a]));return a?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((e=>e.childrenIndex)),t.routesMeta.map((e=>e.childrenIndex)))))}(c);let s=null;for(let e=0;null==s&&e{let s={relativePath:void 0===c?e.path||"":c,caseSensitive:!0===e.caseSensitive,childrenIndex:r,route:e};s.relativePath.startsWith("/")&&(i(s.relativePath.startsWith(n),'Absolute route path "'+s.relativePath+'" nested under path "'+n+'" is not valid. An absolute child route path must start with the combined path of all its parent routes.'),s.relativePath=s.relativePath.slice(n.length));let o=O([n,s.relativePath]),l=a.concat(s);e.children&&e.children.length>0&&(i(!0!==e.index,'Index routes must not have child routes. Please remove all child routes from route path "'+o+'".'),f(e.children,t,l,o)),(null!=e.path||e.index)&&t.push({path:o,score:_(o,e.index),routesMeta:l})};return e.forEach(((e,t)=>{var a;if(""!==e.path&&null!=(a=e.path)&&a.includes("?"))for(let a of y(e.path))r(e,t,a);else r(e,t)})),t}function y(e){let t=e.split("/");if(0===t.length)return[];let[a,...n]=t,r=a.endsWith("?"),c=a.replace(/\?$/,"");if(0===n.length)return r?[c,""]:[c];let s=y(n.join("/")),i=[];return i.push(...s.map((e=>""===e?c:[c,e].join("/")))),r&&i.push(...s),i.map((t=>e.startsWith("/")&&""===t?"/":t))}const E=/^:[\w-]+$/,A=3,b=2,w=1,k=10,R=-2,C=e=>"*"===e;function _(e,t){let a=e.split("/"),n=a.length;return a.some(C)&&(n+=R),t&&(n+=b),a.filter((e=>!C(e))).reduce(((e,t)=>e+(E.test(t)?A:""===t?w:k)),n)}function j(e,t,a){void 0===a&&(a=!1);let{routesMeta:n}=e,r={},c="/",s=[];for(let e=0;e(n.push({paramName:t,isOptional:null!=a}),a?"/?([^\\/]+)?":"/([^\\/]+)")));e.endsWith("*")?(n.push({paramName:"*"}),r+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):a?r+="\\/*$":""!==e&&"/"!==e&&(r+="(?:(?=\\/|$))");let c=new RegExp(r,t?void 0:"i");return[c,n]}(e.path,e.caseSensitive,e.end),r=t.match(a);if(!r)return null;let c=r[0],s=c.replace(/(.)\/+$/,"$1"),i=r.slice(1);return{params:n.reduce(((e,t,a)=>{let{paramName:n,isOptional:r}=t;if("*"===n){let e=i[a]||"";s=c.slice(0,c.length-e.length).replace(/(.)\/+$/,"$1")}const o=i[a];return e[n]=r&&!o?void 0:(o||"").replace(/%2F/g,"/"),e}),{}),pathname:c,pathnameBase:s,pattern:e}}function S(e){try{return e.split("/").map((e=>decodeURIComponent(e).replace(/\//g,"%2F"))).join("/")}catch(t){return o(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding ('+t+")."),e}}function M(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let a=t.endsWith("/")?t.length-1:t.length,n=e.charAt(a);return n&&"/"!==n?null:e.slice(a)||"/"}function N(e,t,a,n){return"Cannot include a '"+e+"' character in a manually specified `to."+t+"` field ["+JSON.stringify(n)+"]. Please separate it out to the `to."+a+'` field. Alternatively you may provide the full path as a string in and the router will parse it for you.'}function L(e){return e.filter(((e,t)=>0===t||e.route.path&&e.route.path.length>0))}function P(e,t){let a=L(e);return t?a.map(((e,t)=>t===a.length-1?e.pathname:e.pathnameBase)):a.map((e=>e.pathnameBase))}function z(e,t,a,r){let c;void 0===r&&(r=!1),"string"==typeof e?c=p(e):(c=n({},e),i(!c.pathname||!c.pathname.includes("?"),N("?","pathname","search",c)),i(!c.pathname||!c.pathname.includes("#"),N("#","pathname","hash",c)),i(!c.search||!c.search.includes("#"),N("#","search","hash",c)));let s,o=""===e||""===c.pathname,l=o?"/":c.pathname;if(null==l)s=a;else{let e=t.length-1;if(!r&&l.startsWith("..")){let t=l.split("/");for(;".."===t[0];)t.shift(),e-=1;c.pathname=t.join("/")}s=e>=0?t[e]:"/"}let u=function(e,t){void 0===t&&(t="/");let{pathname:a,search:n="",hash:r=""}="string"==typeof e?p(e):e,c=a?a.startsWith("/")?a:function(e,t){let a=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((e=>{".."===e?a.length>1&&a.pop():"."!==e&&a.push(e)})),a.length>1?a.join("/"):"/"}(a,t):t;return{pathname:c,search:F(n),hash:V(r)}}(c,s),d=l&&"/"!==l&&l.endsWith("/"),m=(o||"."===l)&&a.endsWith("/");return u.pathname.endsWith("/")||!d&&!m||(u.pathname+="/"),u}const O=e=>e.join("/").replace(/\/\/+/g,"/"),I=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),F=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",V=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";class D extends Error{}function H(e){return null!=e&&"number"==typeof e.status&&"string"==typeof e.statusText&&"boolean"==typeof e.internal&&"data"in e}const T=["post","put","patch","delete"],B=(new Set(T),["get",...T]);new Set(B),new Set([301,302,303,307,308]),new Set([307,308]);Symbol("deferred")},1113:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});var n=a(6087);const r=(0,n.forwardRef)((function({icon:e,size:t=24,...a},r){return(0,n.cloneElement)(e,{width:t,height:t,...a,ref:r})}))},1797:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"m14.5 6.5-1 1 3.7 3.7H4v1.6h13.2l-3.7 3.7 1 1 5.6-5.5z"})})},3751:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4ZM12.75 8V13H11.25V8H12.75ZM12.75 14.5V16H11.25V14.5H12.75Z"})})},7267:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{fillRule:"evenodd",d:"M11.25 5h1.5v15h-1.5V5zM6 10h1.5v10H6V10zm12 4h-1.5v6H18v-6z",clipRule:"evenodd"})})},3883:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})})},4969:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)(n.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"})})},8888:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"})})},9115:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"})})},8248:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)(n.Path,{d:"M6.5 12.4L12 8l5.5 4.4-.9 1.2L12 10l-4.5 3.6-1-1.2z"})})},1249:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})})},991:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"m13.06 12 6.47-6.47-1.06-1.06L12 10.94 5.53 4.47 4.47 5.53 10.94 12l-6.47 6.47 1.06 1.06L12 13.06l6.47 6.47 1.06-1.06L13.06 12Z"})})},4314:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)(n.Path,{d:"M20.8 10.7l-4.3-4.3-1.1 1.1 4.3 4.3c.1.1.1.3 0 .4l-4.3 4.3 1.1 1.1 4.3-4.3c.7-.8.7-1.9 0-2.6zM4.2 11.8l4.3-4.3-1-1-4.3 4.3c-.7.7-.7 1.8 0 2.5l4.3 4.3 1.1-1.1-4.3-4.3c-.2-.1-.2-.3-.1-.4z"})})},2072:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)(n.Path,{d:"M17.2 10.9c-.5-1-1.2-2.1-2.1-3.2-.6-.9-1.3-1.7-2.1-2.6L12 4l-1 1.1c-.6.9-1.3 1.7-2 2.6-.8 1.2-1.5 2.3-2 3.2-.6 1.2-1 2.2-1 3 0 3.4 2.7 6.1 6.1 6.1s6.1-2.7 6.1-6.1c0-.8-.3-1.8-1-3zm-5.1 7.6c-2.5 0-4.6-2.1-4.6-4.6 0-.3.1-1 .8-2.3.5-.9 1.1-1.9 2-3.1.7-.9 1.3-1.7 1.8-2.3.7.8 1.3 1.6 1.8 2.3.8 1.1 1.5 2.2 2 3.1.7 1.3.8 2 .8 2.3 0 2.5-2.1 4.6-4.6 4.6z"})})},3512:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M19.5 4.5h-7V6h4.44l-5.97 5.97 1.06 1.06L18 7.06v4.44h1.5v-7Zm-13 1a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-3H17v3a.5.5 0 0 1-.5.5h-10a.5.5 0 0 1-.5-.5v-10a.5.5 0 0 1 .5-.5h3V5.5h-3Z"})})},1651:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"m3 5c0-1.10457.89543-2 2-2h13.5c1.1046 0 2 .89543 2 2v13.5c0 1.1046-.8954 2-2 2h-13.5c-1.10457 0-2-.8954-2-2zm2-.5h6v6.5h-6.5v-6c0-.27614.22386-.5.5-.5zm-.5 8v6c0 .2761.22386.5.5.5h6v-6.5zm8 0v6.5h6c.2761 0 .5-.2239.5-.5v-6zm0-8v6.5h6.5v-6c0-.27614-.2239-.5-.5-.5z",fillRule:"evenodd",clipRule:"evenodd"})})},9783:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,r.jsx)(n.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm.75 4v1.5h-1.5V8h1.5Zm0 8v-5h-1.5v5h1.5Z"})})},435:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M10.5 4v4h3V4H15v4h1.5a1 1 0 011 1v4l-3 4v2a1 1 0 01-1 1h-3a1 1 0 01-1-1v-2l-3-4V9a1 1 0 011-1H9V4h1.5zm.5 12.5v2h2v-2l3-4v-3H8v3l3 4z"})})},5302:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,r.jsx)(n.Path,{d:"M12 3.176l6.75 3.068v4.574c0 3.9-2.504 7.59-6.035 8.755a2.283 2.283 0 01-1.43 0c-3.53-1.164-6.035-4.856-6.035-8.755V6.244L12 3.176zM6.75 7.21v3.608c0 3.313 2.145 6.388 5.005 7.33.159.053.331.053.49 0 2.86-.942 5.005-4.017 5.005-7.33V7.21L12 4.824 6.75 7.21z",fillRule:"evenodd",clipRule:"evenodd"})})},4648:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5573),r=a(790);const c=(0,r.jsx)(n.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,r.jsx)(n.Path,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"})})},6185:e=>{"use strict";function t(e){return e&&"object"==typeof e?r(e)||c(e)?e:n(e)?function(e,t){if(e.map)return e.map(t);for(var a=[],n=0;n{t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const a="color: "+this.color;t.splice(1,0,a,"color: inherit");let n=0,r=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(n++,"%c"===e&&(r=n))})),t.splice(r,0,a)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=a(3212)(t);const{formatters:n}=e.exports;n.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},3212:(e,t,a)=>{e.exports=function(e){function t(e){let a,r,c,s=null;function i(...e){if(!i.enabled)return;const n=i,r=Number(new Date),c=r-(a||r);n.diff=c,n.prev=a,n.curr=r,a=r,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let s=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((a,r)=>{if("%%"===a)return"%";s++;const c=t.formatters[r];if("function"==typeof c){const t=e[s];a=c.call(n,t),e.splice(s,1),s--}return a})),t.formatArgs.call(n,e);(n.log||t.log).apply(n,e)}return i.namespace=e,i.useColors=t.useColors(),i.color=t.selectColor(e),i.extend=n,i.destroy=t.destroy,Object.defineProperty(i,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==s?s:(r!==t.namespaces&&(r=t.namespaces,c=t.enabled(e)),c),set:e=>{s=e}}),"function"==typeof t.init&&t.init(i),i}function n(e,a){const n=t(this.namespace+(void 0===a?":":a)+e);return n.log=this.log,n}function r(e,t){let a=0,n=0,r=-1,c=0;for(;a"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){t.save(e),t.namespaces=e,t.names=[],t.skips=[];const a=("string"==typeof e?e:"").trim().replace(" ",",").split(",").filter(Boolean);for(const e of a)"-"===e[0]?t.skips.push(e.slice(1)):t.names.push(e)},t.enabled=function(e){for(const a of t.skips)if(r(e,a))return!1;for(const a of t.names)if(r(e,a))return!0;return!1},t.humanize=a(4997),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((a=>{t[a]=e[a]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let a=0;for(let t=0;t{"use strict";a.d(t,{A:()=>n});const n={wrapper:"GqFcAwJvIrg1v7f6QUfw",header:"OENx8kmm62tkWGukzP2S",title:"KnqJLKwSceJTwFJrPGHq","close-button":"PJU0_yA9jNf7ao0jhHut",footer:"rrORM3zqHfGvqiPduEXY",steps:"Q7fUcDUGhteXEr18rZPC","action-button":"S5LAeskUiEQ0JlPhr0Ze"}},2021:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"admin-page":"sexr0jUxC1jVixdKiDnC",background:"vKQ11sLeAM45M04P1ccj","admin-page-header":"iWGAhN9gOB48g0jEO1OQ","sandbox-domain-badge":"JOYmuxQjG4FArIIUxJfA"}},654:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={section:"cAbGtJDGgLubucBnz7vM"}},6888:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"section-hero":"vMa4i_Dza2t5Zi_Bw9Nf"}},2451:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={badge:"VLE2X0rP3Ug4QHebdiJd","is-success":"hEfxH6nau4tQkeE4BNms","is-warning":"Snl4I6aKbXFIrcWaSIC0","is-danger":"zvZFUdy480Xv3IHYbX6a"}},2258:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={button:"zI5tJ_qhWE6Oe6Lk75GY","is-icon-button":"tuBt2DLqimiImoqVzPqo",small:"Na39I683LAaSA99REg14",normal:"ipS7tKy9GntCS4R3vekF",icon:"paGLQwtPEaJmtArCcmyK",regular:"lZAo6_oGfclXOO9CC6Rd","full-width":"xJDOiJxTt0R_wSl8Ipz_",loading:"q_tVWqMjl39RcY6WtQA6","external-icon":"CDuBjJp_8jxzx5j6Nept"}},2127:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={cut:"msOlyh2T7D6uhbM6AROg",icon:"cPN7USVqSBpxUswfDtUZ",cta:"EmnJAyEzzn1QpA8HtypY",iconContainer:"vV7YZikAz0oHYsuvtxMq",description:"T1YaMupeZmBIpXZHY9EZ"}},6373:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"diff-viewer":"HPsJA6B0f3Bd2tZgEr7v","diff-viewer__filename":"WA0OogO0bZSYbqUPL9aa","diff-viewer__file":"Z1NxA7aDh5LEYjbLLKbF","diff-viewer__line-numbers":"aeQS3Qb4g1FwDY0HaZKb","diff-viewer__lines":"ESXyHLdGmRLZMv7_Ei9d"}},3689:()=>{},4803:()=>{},2300:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"star-icon":"cuoSlhSNrqf1dozY22Xb",jetpack:"lAIiifeLMmZAPlQ9n9ZR","checkmark-icon":"JLquNpQVlysAamuh5lJO",socialIcon:"cbOwD8Y4tFjwimmtchQI",bluesky:"aLWBKY0yRghEk7tNCgK3",facebook:"aHOlEBGD5EA8NKRw3xTw",instagram:"cL3m0xBYTYhIKI7lCqDB",twitter:"af4Y_zItXvLAOEoSDPSv",linkedin:"f68aqF3XSD1OBvXR1get",tumblr:"xFI0dt3UiXRlRQdqPWkx",google:"q7JEoyymveP6kF747M43",mastodon:"DKOBOTVmTLbh26gUH_73",nextdoor:"n5XodNsuMfMAAvqHFmbw",whatsapp:"fftumuc_lJ6v0tq4UMVR",threads:"inzgC27qxdt7hSdhTWRI"}},4206:()=>{},8403:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)"}},7371:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)",smCols:"4",mdCols:"8",lgCols:"12","col-sm-1":"RuVLl3q4lxTQa3wbhBJB","col-sm-1-start":"f9LZTRG4MMK42rS89afW","col-sm-1-end":"bHe_zKxjjpUwHw_MdYE1","col-sm-2":"QZbNrOqE2aNSn50xVhpU","col-sm-2-start":"ev7W3z7zVYPeHAlYqZjf","col-sm-2-end":"NJWd1m_e7lOiPYru2ZMP","col-sm-3":"Xc6nt1Qc1DI0Z2A3gt1r","col-sm-3-start":"UIcN_GXiPRoIsin8Kohg","col-sm-3-end":"GRKCyqb5LufCSCgykKFc","col-sm-4":"i_qTq8gqhhC3vIUepVRB","col-sm-4-start":"G3qaZ3Jpbvam_1XvGxgc","col-sm-4-end":"VRCNYKZtO9zukEwmgP1y","col-md-1":"tRm008K_WJL79WoNZTNL","col-md-1-start":"l5T2P_bgKts4tdaRkS1d","col-md-1-end":"zOCxfLZpF6BlgC7a_Yq1","col-md-2":"F80DdgVn0m5OpvtSQWka","col-md-2-start":"oI1c7JYfiJtMQHbhngtU","col-md-2-end":"pMQtA_4jh1_1lVknqEP5","col-md-3":"VenqMpdgyKQVUNNQcfqd","col-md-3-start":"seNYL99uoczf9V4MxBxT","col-md-3-end":"YKfF1HFhI9KygA5l3b2J","col-md-4":"yAi0Cv1xDWkoqsaUhvhR","col-md-4-start":"ubhnyZOnkgxNhh6XtVWv","col-md-4-end":"RGOPGQbWMJ9Ei5oFxS7X","col-md-5":"Sz1E2aWbX483ijdi6yge","col-md-5-start":"tku6_bRYrX9tMbgYGmIl","col-md-5-end":"b5JHttOhSEcI1WBlqAjk","col-md-6":"FboSx5MoKTAWbxXyYlCw","col-md-6-start":"Jhs8yEEmodG30edbJvag","col-md-6-end":"IpzbbKVqEqPcfIGkXkwt","col-md-7":"mhCPwfAZ4Kmm_empzJAq","col-md-7-start":"x034ilrJF7rO9UJB2rI1","col-md-7-end":"Wt8t2e16viRrOJ1lLA5v","col-md-8":"S6pIrEy9AMLKx9bgh_Ae","col-md-8-start":"kEfI4tGyuWfHTlRnvIab","col-md-8-end":"PUzX4RRsKq1dnsz3gebS","col-lg-1":"X_pdcLJikd8LS_YAdJlB","col-lg-1-start":"tl936d14Huby4khYp05X","col-lg-1-end":"hnge0LnR69d3NXEtEE1t","col-lg-2":"fj0NUMuyZQcPNgKcjp5Z","col-lg-2-start":"R2ncBX7a2NigdYCcV1OX","col-lg-2-end":"t8vMSDVYno9k9itRwnXb","col-lg-3":"wsDuEN2GqHx6qzo8dUdk","col-lg-3-start":"cIEVPUweWtLBy3xaXnMx","col-lg-3-end":"fajUWBwu1m2B479j3jmz","col-lg-4":"YR0c7fQTgMkDdWzwSyLp","col-lg-4-start":"xlwp8BmplxkKNMI7gamo","col-lg-4-end":"_C4O1w9DUqx1m3gPf8aA","col-lg-5":"Z54F1hAErckAIrKlxnXW","col-lg-5-start":"ezSDWkRHmKSxDJXxuiOH","col-lg-5-end":"T0ChoeAjGJjkkNrYhD4g","col-lg-6":"qtMoMPF6yHvGJnWHSsde","col-lg-6-start":"gdoywN5VPiWERfIBqkph","col-lg-6-end":"wUev_VH5uf_pwFFlbnAU","col-lg-7":"egIPDFJsOpownTClq9XP","col-lg-7-start":"yGhp9yoAW7k0kQik9AB7","col-lg-7-end":"SJ43U9mR5wUg5V2qBeQA","col-lg-8":"cTuyHfMwSUJxN_HdIEgd","col-lg-8-start":"smCr8DaIagcumdvdldiK","col-lg-8-end":"T03NHzQJvzwL6wAfIiTL","col-lg-9":"pMvxM3RJGjqyNdf9qg1Y","col-lg-9-start":"iIVpNRwEnQ_JI5gpp9EN","col-lg-9-end":"ZbQ4u4vGSX5rJOje4uGL","col-lg-10":"gKb5wuIDAlKGbrjK2vxy","col-lg-10-start":"Z7pINdImE2WJiYnZBTqm","col-lg-10-end":"ZTxp6qpvwurMdOnLLSz1","col-lg-11":"NnQTlbfnxPDR6cQ7rygg","col-lg-11-start":"O137wZd6Yl0olSA9PsXR","col-lg-11-end":"zf2OJtQ2MPz6SDoh6CB0","col-lg-12":"U3H6UHW6HqRt9hdzVg3O","col-lg-12-start":"zynnNeS_ZBTxABcVpUQH","col-lg-12-end":"vI8tltFZtFUNAy9Iag9s"}},2420:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)",container:"SqdhUZkXCRuIpErj1B3z",fluid:"OZC_9a1LhpWF9dv15Gdh"}},5531:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"marked-lines":"SunkAzopVEoBZbCUFkpe","marked-lines__marked-line":"s6eJjt_RVhQ8mEG1qQYb","marked-lines__line-numbers":"cW2860S1RCjdsufX8ds_","marked-lines__line-number":"hU_xmjv3sGJgIvV_26Ik","marked-lines__lines":"O5ZaHoo1pFRkk_GUUczG","marked-lines__line":"UoS_E4HwI88HfDMpNtvB","marked-lines__mark":"ZotWIwUISq6XCpIyD8k7"}},7410:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={container:"VHYulMcpzbr10HWR0iSE","icon-wrapper":"FGpSkMCiIHQjszcV0dbn","close-button":"KoWZcCwhW13xvkEb0QON","main-content":"smrfczkC53EaFM8OJUXs",title:"IKYRWoPwt9xOVEx1wzNS","action-bar":"qM0qY6mPYp1MPN54A3Kg","is-error":"A5YkDkkXuiYgavrY6Nux",icon:"y_IPyP1wIAOhyNaqvXJq","is-warning":"cT5rwuPMZzWvi5o6shMl","is-info":"yo0O3uvNomPsYUXFCpAS","is-success":"oZdDFf1jBLkzn5ICCC6x"}},3142:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={container:"p4qz2tkq0p9hxucJ6Qk2",table:"lbNDyXioOwvyvbALtCBm","is-viewport-large":"s2Lsn4kbm6BrS3DSndRB",card:"cLaNK_XcbTGlRQ4Tp43Q","is-primary":"CYt1X0eH1icRjhtJ28jx",header:"DAkZc1P9A3K12fjEliMg",item:"WUBuYABl8nymjs9NnCEL","last-feature":"ANtCFeb41NhA8PA3H7ZN",value:"Ql2gy_148yW8Vw5vhaKD",icon:"EAQrAnQEW1z1BfdY5gbC","icon-check":"JDSTlLoOC_4aUoH2oNM2","icon-cross":"zNdQRJ1w7BvaQOYyqzHK",popover:"lr7vbX95SKtoe7DarJcZ","popover-icon":"KRrGp2xdkeBOxLZeuQ6X",tos:"H_ZJiRVJg0LiMXPGOcmt","tos-container":"x21z_DixObRDsDaWotP1"}},3407:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={container:"dovianZYLKhnbnh9I06o","price-container":"lljtQMhW7lq5tE5SDJEf","promo-label":"NubApIV1vQCRUNprfm6b",price:"dhFQXpZfMwVI8vuYHnwC","is-not-off-price":"eD7hzxFmdtG_MgmBtl_k",footer:"C64ZjjUAqJC1T2Sa7apS",legend:"UpZDGew6Ay1hPoP6eI7b",symbol:"TDiiPbuW1Z0_05u_pvcK"}},8325:()=>{},9439:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={wrapper:"VfIXL69k_I0zUU0s7LqM",horizontal:"SvvAonSzsVSo_5Hu6Goz",info:"dwXtyo4qYbpJ2b3rZL1N",label:"WxFqmtANZGuBRdR2NewQ",square:"ee2TJQm2FgpSRwchomAH",value:"mgcKzhKqFk7UOZ156QPT",icon:"h_uY7ygjuMtuY4ZWJz1R"}},416:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={status:"bZ4b33s2MdcOjaDKBbeV",status__indicator:"UzkzDaqt2mXprJh2OXRz",status__label:"QuS0vdcr87FsiBvSSrvA","is-active":"bGx0wbQAwuY7k8P3PHVQ","is-inactive":"wR8Cz8uHgObTQavolv5y","is-error":"IzbBYGwBKhSYFUQlIMww","is-action":"Kdvp_HJf89IBrZuCaLm8","is-initializing":"hVf5vsbBWm8OFye7cy7a"}},9634:()=>{},4495:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={reset:"WQVtrU6q0L1Igcj7wCrQ","headline-medium":"UujoBFTnQNY2cWU2SIsH","headline-small":"TeGO5V_thHw5lDAm1_2M","headline-small-regular":"WolQzb2MsSgiNmLtc7_j","title-medium":"hUB0JT8p1T2Hw28N6qC8","title-medium-semi-bold":"gKZWDv5chz3_O3Syp74H","title-small":"zY2No8Ga4b8shbOQGhnv",body:"tIj0D1t8Cc892ikmgFPZ","body-small":"KdcN0BnOaVeVhyLRKqhS","body-extra-small":"dso3Rh3tl3Xv1GumBktz","body-extra-small-bold":"mQ1UlbN9u4Mg9byO8m7v",label:"PItlW5vRExLnTj4a8eLE","m-0":"TwRpPlktzxhmFVeua7P5","mx-0":"zVfqx7gyb3o9mxfGynn1","my-0":"iSHVzNiB9iVleGljaQxy","mt-0":"xqDIp6cNVr_E6RXaiPyD","mr-0":"S8EwaXk1kyPizt6x4WH2","mb-0":"ODX5Vr1TARoLFkDDFooD","ml-0":"cphJ8dCpfimnky7P2FHg","m-1":"PFgIhNxIyiSuNvQjAIYj","mx-1":"M2jKmUzDxvJjjVEPU3zn","my-1":"io15gAh8tMTNbSEfwJKk","mt-1":"rcTN5uw9xIEeMEGL3Xi_","mr-1":"CQSkybjq2TcRM1Xo9COV","mb-1":"hfqOWgq6_MEGdFE82eOY","ml-1":"I8MxZQYTbuu595yfesWA","m-2":"kQkc6rmdpvLKPkyoJtVQ","mx-2":"j6vFPxWuu4Jan2ldoxpp","my-2":"hqr39dC4H_AbactPAkCG","mt-2":"c3dQnMi16C6J6Ecy4283","mr-2":"YNZmHOuRo6hU7zzKfPdP","mb-2":"Db8lbak1_wunpPk8NwKU","ml-2":"ftsYE5J9hLzquQ0tA5dY","m-3":"Det4MHzLUW7EeDnafPzq","mx-3":"h_8EEAztC29Vve1datb5","my-3":"YXIXJ0h1k47u6hzK8KcM","mt-3":"soADBBkcIKCBXzCTuV9_","mr-3":"zSX59ziEaEWGjnpZa4uV","mb-3":"yrVTnq_WBMbejg89c2ZQ","ml-3":"UKtHPJnI2cXBWtPDm5hM","m-4":"guexok_Tqd5Tf52hRlbT","mx-4":"oS1E2KfTBZkJ3F0tN7T6","my-4":"DN1OhhXi6AoBgEdDSbGd","mt-4":"ot2kkMcYHv53hLZ4LSn0","mr-4":"A1krOZZhlQ6Sp8Cy4bly","mb-4":"pkDbXXXL32237M0hokEh","ml-4":"XXv4kDTGvEnQeuGKOPU3","m-5":"yGqHk1a57gaISwkXwXe6","mx-5":"X8cghM358X3DkXLc9aNK","my-5":"GdfSmGwHlFnN2S6xBn1f","mt-5":"yqeuzwyGQ7zG0avrGqi_","mr-5":"g9emeCkuHvYhveiJbfXO","mb-5":"Lvk3dqcyHbZ07QCRlrUQ","ml-5":"r3yQECDQ9qX0XZzXlVAg","m-6":"aQhlPwht2Cz1X_63Miw0","mx-6":"JyHb0vK3wJgpblL9s5j8","my-6":"cY2gULL1lAv6WPNIRuf3","mt-6":"NBWQ9Lwhh_fnry3lg_p7","mr-6":"yIOniNe5E40C8fWvBm5V","mb-6":"t30usboNSyqfQWIwHvT3","ml-6":"Nm_TyFkYCMhOoghoToKJ","m-7":"C4qJKoBXpgKtpmrqtEKB","mx-7":"S93Srbu6NQ_PBr7DmTiD","my-7":"fJj8k6gGJDks3crUZxOS","mt-7":"cW6D6djs7Ppm7fD7TeoV","mr-7":"DuCnqNfcxcP3Z__Yo5Ro","mb-7":"im8407m2fw5vOg7O2zsw","ml-7":"G0fbeBgvz2sh3uTP9gNl","m-8":"kvW3sBCxRxUqz1jrVMJl","mx-8":"tOjEqjLONQdkiYx_XRnw","my-8":"op5hFSx318zgxsoZZNLN","mt-8":"c9WfNHP6TFKWIfLxv52J","mr-8":"sBA75QqcqRwwYSHJh2wc","mb-8":"GpL6idrXmSOM6jB8Ohsf","ml-8":"HbtWJoQwpgGycz8dGzeT","p-0":"uxX3khU88VQ_Ah49Ejsa","px-0":"KX0FhpBKwKzs9fOUdbNz","py-0":"PfK8vKDyN32dnimlzYjz","pt-0":"emxLHRjQuJsImnPbQIzE","pr-0":"kJ8WzlpTVgdViXt8ukP9","pb-0":"tg_UIUI11VBzrTAn2AzJ","pl-0":"uczvl8kaz84oPQJ2DB2R","p-1":"o7UHPcdVK3lt7q3lqV4o","px-1":"IDqEOxvDoYrFYxELPmtX","py-1":"DdywPW2qSYlu2pt8tpO2","pt-1":"npy3hw4A5QSkDicb2CJJ","pr-1":"LgbptTApNY5NwLQvEFAt","pb-1":"WZQy2SZuZso59bUsXXyl","pl-1":"o331apInxNunbYB3SfPE","p-2":"fMPIyD9Vqki1Lrc_yJnG","px-2":"i2pMcTcdrr10IQoiSm_L","py-2":"eA702gn32kwptiI1obXH","pt-2":"o9bGieUKcYc8o0Ij9oZX","pr-2":"SwZcFez1RDqWsOFjB5iG","pb-2":"eHpLc_idmuEqeqCTvqkN","pl-2":"vU39i2B4P1fUTMB2l6Vo","p-3":"JHWNzBnE29awhdu5BEh1","px-3":"X72lGbb56L3KFzC2xQ9N","py-3":"BzfNhRG8wXdCEB5ocQ6e","pt-3":"srV0KSDC83a2fiimSMMQ","pr-3":"lUWfkmbQjCskhcNwkyCm","pb-3":"Ts0dIlc3aTSL7V4cIHis","pl-3":"CzlqQXXhX6MvorArFZ8B","p-4":"TqMPkQtR_DdZuKb5vBoV","px-4":"a7UrjhI69Vetlcj9ZVzz","py-4":"StEhBzGs2Gi5dDEkjhAv","pt-4":"FGneZfZyvYrt1dG0zcnm","pr-4":"APEH216rpdlJWgD2fHc8","pb-4":"oGwXC3ohCic9XnAj6x69","pl-4":"U6gnT9y42ViPNOcNzBwb","p-5":"IpdRLBwnHqbqFrixgbYC","px-5":"HgNeXvkBa9o3bQ5fvFZm","py-5":"tJtFZM3XfPG9v9TSDfN1","pt-5":"PdifHW45QeXYfK568uD8","pr-5":"mbLkWTTZ0Za_BBbFZ5b2","pb-5":"vVWpZpLlWrkTt0hMk8XU","pl-5":"RxfaJj5a1Nt6IavEo5Zl","p-6":"SppJULDGdnOGcjZNCYBy","px-6":"palY2nLwdoyooPUm9Hhk","py-6":"WYw1JvZC0ppLdvSAPhr_","pt-6":"YEEJ9b90ueQaPfiU8aeN","pr-6":"QE0ssnsKvWJMqlhPbY5u","pb-6":"n8yA3jHlMRyLd5UIfoND","pl-6":"tXHmxYnHzbwtfxEaG51n","p-7":"kBTsPKkO_3g_tLkj77Um","px-7":"RyhrFx6Y1FGDrGAAyaxm","py-7":"CBwRpB0bDN3iEdQPPMJO","pt-7":"vQVSq6SvWKbOMu6r4H6b","pr-7":"oBy5__aEADMsH46mrgFX","pb-7":"KVEXoJqf1s92j0JMdNmN","pl-7":"ZMXGNrNaKW3k_3TLz0Fq","p-8":"tuiR9PhkHXhGyEgzRZRI","px-8":"U7454qyWkQNa2iaSJziu","py-8":"VLYIv2GVocjuN93e8HC8","pt-8":"X1rm9DQ1zLGLfogja5Gn","pr-8":"JS7G6kAuqJo5GIuF8S5t","pb-8":"Y8F9ga1TDCMbM1lj4gUz","pl-8":"AJuyNGrI63BOWql719H8"}},9422:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={global:"_fUXxnSp5pagKBp9gSN7"}},7021:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={toggle:"gecp_0Z0owRZtj8JAYir","is-small":"qgKXEdMmHsIK84VDnLO2","no-label":"Vy6dbB4PsGKm8BDqzJ9J","is-toggling":"ykWv7fKpkVW_vpAoddu4"}},1517:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={tab:"YXKeyNLeZvIdah_5_5GR",navigation:"vvXnRXxrU1kP1KsdSr4J",badge:"aDCTkUFaJEeZzYYE6qv5"}},6900:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"header-main":"pVJWvyeviifcrLbZZxCj","header-secondary":"segmN0DtUjey3r5zVPON","heading-icon":"lolS8hq75wfk687xQjbY",subheading:"HC8zzYgv0GvkecCkpyld","connection-error-col":"XJqRbP_azFalXqUoYPtl"}},3902:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"button-group":"XqQBRzrxyMhhZvPXIHgk"}},9370:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={loading:"kdsaL7c4bpTwf_A4fIUT",loading__message:"b0eN3as5AgxQW7EAkarg"}},2148:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={footer:"_Wc3apZobag_9Ag_THTb"}},8842:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={heading:"iN9oF7KagtrwaFKTquqW",warning:"IZTexE5bnJrB25jtwXBW","scan-navigation":"YzqaprEdVpBoBJesZixw"}},4047:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={list:"sQkG5Cu80gPaeFj3L_wa",footer:"oIl6GCMeUnzE0inXbuj9"}},2318:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={list:"RP2MVoGqaCFXPKZhhxQ1",footer:"YpEs8b7KE7fzVuXUbOEb"}},4493:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={accordion:"x8UuVEhWucPfdq0hEJg6","accordion-item":"eb6Ovfvm1yONz4mdOwbH","accordion-header":"jF9LXpXR3TxZVDw7TVXT","accordion-header-label":"lNQgAfpwdAUSOLZd8dlD","accordion-header-label-icon":"WRQwDYPdffWznX158azR","accordion-header-description":"dJx9pvlYjDnKn11n5wo8","accordion-header-button":"EKcbLuSblRc7UpzgsFXw","accordion-body":"ILMBWlMLcXc0n97IisrG","accordion-body-close":"T8XIzCNJBQy1UETN5gjU","accordion-body-open":"kWoHGiaZSbq9XJVyUOMC"}},4871:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={threat:"EqpwvErHtRi_WQkJKgi1",threat__icon:"EicvN1QaJu5OJLzdUN5A",threat__summary:"b7ynAmUwGlxK_vxyIN0y",threat__summary__label:"uSV9HYRxjL4S6zIZDlqP",threat__summary__title:"XpW8Mvw_XFEbqxUdw155",threat__severity:"Fkj60BmQ5sUo9zHcJwVv",footer:"XLzPr74ad3osCq9kxy2q"}},8044:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={inProgressAnimation:"AMcxtVDLtWB2EJJJU5NQ",inProgressAnimation__el:"vtViVIQmuI1n8HDxrkNy",inprogress:"BJ0WjZD0MlRR_Usu8HEd"}},7259:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={modal:"WtVEv641JBaLl929sZq2",modal__window:"G0aPt7WmA1rkUE0wcTno",modal__close:"VkrhWjfEIlIwYEumycbP",modal__close__icon:"yFzeV4cmWRbZKk5tIyEw"}},3066:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={navigation:"HQgjxePFDRJHamBAGcVU","navigation-item":"KtdsNIMumOoHNWMLmuAJ",clickable:"ewyV4ZGn34WDNXmK3ej2",selected:"owofT85W_XvVdb5vr1GN","navigation-item-label":"NESnw2xCLrBpP6WlYZL4","navigation-item-icon":"aohnd_y_1lrMuww8NH63","navigation-item-badge":"Rnas_2_2_eLZSYfZ347E","navigation-item-label-text":"m4_14yNRByDyO9yf9pGg","navigation-item-check-badge":"X8NRHUTBa_4wDvoHN9TT","navigation-item-info-badge":"CsuOteurQlJm4IjXqyZ0","navigation-group":"fvbewglUxEvV1o04yzzp","navigation-group-label":"DINy59MKjwiQanaoDTiV","navigation-group-content":"XoacHJljw8zRW_fkBSyg","navigation-group-list":"mXM4WZRePVTa07dhQ6MD","navigation-group-truncate":"sI3V8khLdCqxkhJQ_XnI","popover-text":"hgdxMuIvZwTZ0sfXaols","navigation-dropdown-button":"UErHS2HAh1gszGfYuVIf","navigation-dropdown-label":"lEhH1hvCcxLVFMHI8Gwv","navigation-dropdown-icon":"c57Vj4QhAHwcK_HZMxtN"}},600:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={notice:"_aiMxmJRAw5jRPbZFX57","notice--info":"eWgNBUaexiR66ZI1Px4U","notice--floating":"ZGELG1CO333FilJXOaeI",notice__icon:"BnI88X_e8ItF1c9Uozmj","notice--success":"hRRUwTCPRpurhMwRNZkg","notice--error":"Z6q3IxY_uR1y2lAPTkVF",notice__message:"ST8sowTbBVLRPrk4ZQrn",notice__close:"lMkO08Vd8YQMfwrwaI8u"}},7489:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={accordion:"sfXsfklfkeSRtE9ivQwF","accordion-item":"ozRrKPlj1QFGUyd3oVke","accordion-header":"PyvnSHQuuUkZvVsArigy","accordion-header-label":"u9Xod5s8bCRNj9MR1Drl","accordion-header-label-icon":"IbeyulkpO9kjYJ4OkYUD","accordion-header-description":"KiCgmjHm2f0JDU3cMsgf","accordion-header-status":"kh5zuLR1zNf7KCsxhAZ5","accordion-header-status-separator":"z1z63g62c73XbcPk9DWc","accordion-header-button":"kJ8t3FAtd5VAYjk31SfA","accordion-body":"JP0IJZcYRohfgntEozjm","accordion-body-close":"y7c6zi2wjEnbW3F29fmP","accordion-body-open":"wQWiN_J0SqgduvadyGnm","icon-check":"v1fUFCBPmd6miSCf_ehK","status-badge":"oR9QG6gRLvyzqiuIarmu",fixed:"bZ8KDXMWoim85Zv31E7E",ignored:"uYEkrN4rh8n5cs3aPrYC","is-fixed":"WOX88CWB12lzxcMcl_ns","support-link":"H2J5mHqyiBHXCAyZ4KGa","icon-tooltip":"BT16ByfO8ktYf15hbMG8","icon-tooltip__icon":"Gi6geVLkEyrClNXuJ34I","icon-tooltip__content":"Q02oRBdY3ZpNGOF2Y1iV"}},8744:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"progress-bar":"vzMlFr1AXWqefpRrb976","progress-bar__wrapper":"gYSOMa4xxLXmsNzvFPkW","progress-bar__bar":"hNJWdt5qmZkWYAH_vjIp","progress-bar__percent":"DHMUfGyHbl5BgD5vjxVz"}},1847:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={mark:"jNlU3vgp4xEGwmX5aTyK",list:"gE8s4nh3f7iGIBrFeyCT"}},4356:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={tabs:"lyrXe0pA852TUmyekDb5",tab:"KgEeDTKgTC5ZjzYlbTqN","tab--active":"Lv4WoNVkeJntqvUyG4dX"}},6578:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={textarea:"rigH8UdiDrmmSLQMUurD",label:"V8FDM08CpcwQs4UwN2nI"}},9054:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={threat:"NHzH3tt6CypjZ92CvK9x",threat__icon:"D9zvYDUrOP_zwSm0yJMs",threat__summary:"_XISfmbjoVlqhB61hHYn",threat__summary__label:"AQDPBnMZFu7BOBuo8mYW",threat__summary__title:"cZ9s5eCAZe3R82Y6Ru3z",threat__severity:"AKnbWQiViZ2O_dwCV8Fw",threat__checkbox:"W6alQ2_S5Rh06djX9m27"}},1476:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={empty:"OtDl6kocO_m2s9sRHaqX","threat-section":"BjwJh1S1YVPI7AjmTx6a","threat-filename":"YWfK8VTp2wnByBauYPKg","threat-footer":"pkw2LnOTd8VvQ3oT8sXQ","threat-item-cta":"ap6lG79CncSqdigJS_WA","list-header":"uym7dGHhp6ifjF57yOAO","list-title":"e_2eFTR8RyHwmfeqJL4F","list-header__controls":"IKQVU01PrDMMV5UFLOKv","accordion-header":"qazuloIt0teplSEwxRN0","manual-scan":"iJ_biSBRDribuNKX0Zuw","pagination-container":"v640YfEL85A9rCvyHSzW",unfocused:"gfxpe4zp6ShFsIsce8Ii"}},6834:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={threat:"L9hh_sX51PzO41icwJlh",threat__icon:"o8E4Bv6U0d7USFxSjRCj",threat__summary:"sT31awD6bHO8KJewvmaO",threat__summary__label:"VVTRIG51r8ORUIBPs5gN",threat__summary__title:"AiaWRbRLFT9xvP9vn5jA",threat__severity:"MP1wWkqvqfvAc7Izl7x4",footer:"i9X_KxEJiGpRT7q_RU6i"}},8340:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={footer:"uUEJGMrSV3XoBwX5xEwA"}},7642:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={container:"L1LjeCYPldBcTLILS13l","toggle-section":"JWWznnb8sAKHIOhE59_z","toggle-section__control":"kV5wl2UResIqqBdSTuQr","toggle-section__content":"oePuSIKcH_JzEhDJcHh8","toggle-section__title":"mxYw7vghJF8H8C0FjvPz","toggle-section--disabled":"lyiOCAyjT_eQyDg8Ier_","toggle-section__details":"IclfL4iNXTZfBAbHZdog","automatic-rules-stats":"bOadM4auwszaOl0el95T","automatic-rules-stats__version":"G7vkgqk8AEd6pRbNUyE4","automatic-rules-stats__last-updated":"qnlbRElIsj4nB45F5s3a","automatic-rules-stats__failed-install":"TvvdPGzRa_ubn3BnQOnQ","upgrade-trigger-section":"yAFMUkq1ot9DZF05RUwG","upgrade-prompt-button":"qoajQ2Ew8eYJgdbssSg9",badge:"EbfrbByI7NQ2_MD_gDXp",popover:"hCwaBLH_6dELyWWwB8S1",popover__header:"V3U9oKSdRmKjOQ523C86",popover__button:"OSrT4pA4vIGzg9EE6rcv",popover__footer:"rbL50q3wwzE6X7VBHcmW","allow-list-current-ip":"g593fzjQCE_4rNiiwLdg","allow-list-button-container":"CIp_BwDbLdjYPSVrreqg","block-list-button-container":"m2epTt5F7wBQNcMdguwQ",divider:"HrEvG7sxsWbTLD0sk477","popover-text":"WIttYmnC0O4JKFyPgkTW","firewall-subheading":"p1_cy4ERoY1_uwtgq3Tn","stat-card-wrapper":"ehnXRuGNl9ZnPh6c1Pa3",disabled:"q8mOIlVn7qA44s7ysC5Z","stat-card-icon":"IxCDeZ2a0wRu3AQbqGuG","stat-card-label":"YIQOtwFZuyfirlpFfjDb","share-data-section":"x8nPhsBEpxvgCxHNbCXo","share-data-toggle":"b_pwVVOoMN73AXhJNbgr","icon-tooltip":"MWO4b3hqGdH8p1Vt9zmQ","icon-tooltip__icon":"DuflEZ86axRQGuMhmH3n","icon-tooltip__content":"ywr2PcNYcX5_sEzdvHAS",footer:"e_wseeb7HqoyLjv9N_ww","standalone-mode":"nxtQ3M8WCX69d_NjShwZ","share-data":"mzfjOg8s_uehdCmNjX0P"}},5960:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={empty:"KmIjHqrMs3duMPaUf50k","subheading-content":"bpW3MfTt3siOyvw1ZsuF","list-header":"DJS67UCXVaM7nIMJePYQ","list-title":"s4378tf2MiM0bMIxQZkI","list-header__controls":"jifq7nsF5kZYrcpGQ35V","scan-navigation":"yjKVIZH3KLvJeygIzaZn"}},6359:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"subheading-content":"WjKn66iJO4hAZYE6o9b3","product-section":"IS5K46VvD7VX5YtlwbMI","info-section":"eDfoDi2nArFY_KiYIwKh","scan-navigation":"XKUO6pX9vFbOUplFfCW2"}},3961:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});const n={"protect-header":"T1f6nRmWifz5im6hB29M","get-started-button":"Ki7ehROrWxWBIMIt8SUH"}},5490:()=>{},4997:e=>{var t=1e3,a=60*t,n=60*a,r=24*n,c=7*r,s=365.25*r;function i(e,t,a,n){var r=t>=1.5*a;return Math.round(e/a)+" "+n+(r?"s":"")}e.exports=function(e,o){o=o||{};var l=typeof e;if("string"===l&&e.length>0)return function(e){if((e=String(e)).length>100)return;var i=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!i)return;var o=parseFloat(i[1]);switch((i[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return o*s;case"weeks":case"week":case"w":return o*c;case"days":case"day":case"d":return o*r;case"hours":case"hour":case"hrs":case"hr":case"h":return o*n;case"minutes":case"minute":case"mins":case"min":case"m":return o*a;case"seconds":case"second":case"secs":case"sec":case"s":return o*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return o;default:return}}(e);if("number"===l&&isFinite(e))return o.long?function(e){var c=Math.abs(e);if(c>=r)return i(e,c,r,"day");if(c>=n)return i(e,c,n,"hour");if(c>=a)return i(e,c,a,"minute");if(c>=t)return i(e,c,t,"second");return e+" ms"}(e):function(e){var c=Math.abs(e);if(c>=r)return Math.round(e/r)+"d";if(c>=n)return Math.round(e/n)+"h";if(c>=a)return Math.round(e/a)+"m";if(c>=t)return Math.round(e/t)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},5762:(e,t,a)=>{"use strict";var n=a(3761);function r(){}function c(){}c.resetWarningCache=r,e.exports=function(){function e(e,t,a,r,c,s){if(s!==n){var i=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw i.name="Invariant Violation",i}}function t(){return e}e.isRequired=e;var a={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:c,resetWarningCache:r};return a.PropTypes=a,a}},8120:(e,t,a)=>{e.exports=a(5762)()},3761:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},28:(e,t,a)=>{"use strict";a.d(t,{I9:()=>m,k2:()=>f});var n=a(1609),r=a(5795),c=a(9539),s=a(6992);function i(){return i=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(r[a]=e[a]);return r}new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);const l=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],u=["aria-current","caseSensitive","className","end","style","to","viewTransition","children"];try{window.__reactRouterVersion="6"}catch(e){}const d=n.createContext({isTransitioning:!1});new Map;const p=n.startTransition;r.flushSync,n.useId;function m(e){let{basename:t,children:a,future:r,window:i}=e,o=n.useRef();null==o.current&&(o.current=(0,s.TM)({window:i,v5Compat:!0}));let l=o.current,[u,d]=n.useState({action:l.action,location:l.location}),{v7_startTransition:m}=r||{},h=n.useCallback((e=>{m&&p?p((()=>d(e))):d(e)}),[d,m]);return n.useLayoutEffect((()=>l.listen(h)),[l,h]),n.useEffect((()=>(0,c.V8)(r)),[r]),n.createElement(c.Ix,{basename:t,children:a,location:u.location,navigationType:u.action,navigator:l,future:r})}const h="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,g=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,v=n.forwardRef((function(e,t){let a,{onClick:r,relative:u,reloadDocument:d,replace:p,state:m,target:v,to:f,preventScrollReset:y,viewTransition:E}=e,A=o(e,l),{basename:b}=n.useContext(c.jb),w=!1;if("string"==typeof f&&g.test(f)&&(a=f,h))try{let e=new URL(window.location.href),t=f.startsWith("//")?new URL(e.protocol+f):new URL(f),a=(0,s.pb)(t.pathname,b);t.origin===e.origin&&null!=a?f=a+t.search+t.hash:w=!0}catch(e){}let k=(0,c.$P)(f,{relative:u}),R=function(e,t){let{target:a,replace:r,state:i,preventScrollReset:o,relative:l,viewTransition:u}=void 0===t?{}:t,d=(0,c.Zp)(),p=(0,c.zy)(),m=(0,c.x$)(e,{relative:l});return n.useCallback((t=>{if(function(e,t){return!(0!==e.button||t&&"_self"!==t||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e))}(t,a)){t.preventDefault();let a=void 0!==r?r:(0,s.AO)(p)===(0,s.AO)(m);d(e,{replace:a,state:i,preventScrollReset:o,relative:l,viewTransition:u})}}),[p,d,m,r,i,a,e,o,l,u])}(f,{replace:p,state:m,target:v,preventScrollReset:y,relative:u,viewTransition:E});return n.createElement("a",i({},A,{href:a||k,onClick:w||d?r:function(e){r&&r(e),e.defaultPrevented||R(e)},ref:t,target:v}))}));const f=n.forwardRef((function(e,t){let{"aria-current":a="page",caseSensitive:r=!1,className:l="",end:p=!1,style:m,to:h,viewTransition:g,children:f}=e,E=o(e,u),b=(0,c.x$)(h,{relative:E.relative}),w=(0,c.zy)(),k=n.useContext(c.Rq),{navigator:R,basename:C}=n.useContext(c.jb),_=null!=k&&function(e,t){void 0===t&&(t={});let a=n.useContext(d);null==a&&(0,s.Oi)(!1);let{basename:r}=A(y.useViewTransitionState),i=(0,c.x$)(e,{relative:t.relative});if(!a.isTransitioning)return!1;let o=(0,s.pb)(a.currentLocation.pathname,r)||a.currentLocation.pathname,l=(0,s.pb)(a.nextLocation.pathname,r)||a.nextLocation.pathname;return null!=(0,s.B6)(i.pathname,l)||null!=(0,s.B6)(i.pathname,o)}(b)&&!0===g,j=R.encodeLocation?R.encodeLocation(b).pathname:b.pathname,x=w.pathname,S=k&&k.navigation&&k.navigation.location?k.navigation.location.pathname:null;r||(x=x.toLowerCase(),S=S?S.toLowerCase():null,j=j.toLowerCase()),S&&C&&(S=(0,s.pb)(S,C)||S);const M="/"!==j&&j.endsWith("/")?j.length-1:j.length;let N,L=x===j||!p&&x.startsWith(j)&&"/"===x.charAt(M),P=null!=S&&(S===j||!p&&S.startsWith(j)&&"/"===S.charAt(j.length)),z={isActive:L,isPending:P,isTransitioning:_},O=L?a:void 0;N="function"==typeof l?l(z):[l,L?"active":null,P?"pending":null,_?"transitioning":null].filter(Boolean).join(" ");let I="function"==typeof m?m(z):m;return n.createElement(v,i({},E,{"aria-current":O,className:N,ref:t,style:I,to:h,viewTransition:g}),"function"==typeof f?f(z):f)}));var y,E;function A(e){let t=n.useContext(c.sp);return t||(0,s.Oi)(!1),t}(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(y||(y={})),function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"}(E||(E={}))},9539:(e,t,a)=>{"use strict";a.d(t,{$P:()=>p,BV:()=>F,C5:()=>z,Ix:()=>I,Rq:()=>i,V8:()=>P,Zp:()=>v,g:()=>f,jb:()=>o,qh:()=>O,sp:()=>s,x$:()=>y,zy:()=>h});var n=a(1609),r=a(6992);function c(){return c=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0})),n.useCallback((function(n,r){void 0===r&&(r={}),a.current&&("number"==typeof n?e.navigate(n):e.navigate(n,c({fromRouteId:t},r)))}),[e,t])}():function(){m()||(0,r.Oi)(!1);let e=n.useContext(s),{basename:t,future:a,navigator:c}=n.useContext(o),{matches:i}=n.useContext(u),{pathname:l}=h(),d=JSON.stringify((0,r.yD)(i,a.v7_relativeSplatPath)),p=n.useRef(!1);return g((()=>{p.current=!0})),n.useCallback((function(a,n){if(void 0===n&&(n={}),!p.current)return;if("number"==typeof a)return void c.go(a);let s=(0,r.Gh)(a,JSON.parse(d),l,"path"===n.relative);null==e&&"/"!==t&&(s.pathname="/"===s.pathname?t:(0,r.HS)([t,s.pathname])),(n.replace?c.replace:c.push)(s,n.state,n)}),[t,c,d,l,e])}()}function f(){let{matches:e}=n.useContext(u),t=e[e.length-1];return t?t.params:{}}function y(e,t){let{relative:a}=void 0===t?{}:t,{future:c}=n.useContext(o),{matches:s}=n.useContext(u),{pathname:i}=h(),l=JSON.stringify((0,r.yD)(s,c.v7_relativeSplatPath));return n.useMemo((()=>(0,r.Gh)(e,JSON.parse(l),i,"path"===a)),[e,l,i,a])}function E(e,t,a,s){m()||(0,r.Oi)(!1);let{navigator:i}=n.useContext(o),{matches:d}=n.useContext(u),p=d[d.length-1],g=p?p.params:{},v=(p&&p.pathname,p?p.pathnameBase:"/");p&&p.route;let f,y=h();if(t){var E;let e="string"==typeof t?(0,r.Rr)(t):t;"/"===v||(null==(E=e.pathname)?void 0:E.startsWith(v))||(0,r.Oi)(!1),f=e}else f=y;let A=f.pathname||"/",b=A;if("/"!==v){let e=v.replace(/^\//,"").split("/");b="/"+A.replace(/^\//,"").split("/").slice(e.length).join("/")}let w=(0,r.ue)(e,{pathname:b});let k=R(w&&w.map((e=>Object.assign({},e,{params:Object.assign({},g,e.params),pathname:(0,r.HS)([v,i.encodeLocation?i.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?v:(0,r.HS)([v,i.encodeLocation?i.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])}))),d,a,s);return t&&k?n.createElement(l.Provider,{value:{location:c({pathname:"/",search:"",hash:"",state:null,key:"default"},f),navigationType:r.rc.Pop}},k):k}function A(){let e=function(){var e;let t=n.useContext(d),a=x(_.UseRouteError),r=S(_.UseRouteError);if(void 0!==t)return t;return null==(e=a.errors)?void 0:e[r]}(),t=(0,r.pX)(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),a=e instanceof Error?e.stack:null,c="rgba(200,200,200, 0.5)",s={padding:"0.5rem",backgroundColor:c};return n.createElement(n.Fragment,null,n.createElement("h2",null,"Unexpected Application Error!"),n.createElement("h3",{style:{fontStyle:"italic"}},t),a?n.createElement("pre",{style:s},a):null,null)}const b=n.createElement(A,null);class w extends n.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||"idle"!==t.revalidation&&"idle"===e.revalidation?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:void 0!==e.error?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error("React Router caught the following error during render",e,t)}render(){return void 0!==this.state.error?n.createElement(u.Provider,{value:this.props.routeContext},n.createElement(d.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function k(e){let{routeContext:t,match:a,children:r}=e,c=n.useContext(s);return c&&c.static&&c.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(c.staticContext._deepestRenderedBoundaryId=a.route.id),n.createElement(u.Provider,{value:t},r)}function R(e,t,a,c){var s;if(void 0===t&&(t=[]),void 0===a&&(a=null),void 0===c&&(c=null),null==e){var i;if(!a)return null;if(a.errors)e=a.matches;else{if(!(null!=(i=c)&&i.v7_partialHydration&&0===t.length&&!a.initialized&&a.matches.length>0))return null;e=a.matches}}let o=e,l=null==(s=a)?void 0:s.errors;if(null!=l){let e=o.findIndex((e=>e.route.id&&void 0!==(null==l?void 0:l[e.route.id])));e>=0||(0,r.Oi)(!1),o=o.slice(0,Math.min(o.length,e+1))}let u=!1,d=-1;if(a&&c&&c.v7_partialHydration)for(let e=0;e=0?o.slice(0,d+1):[o[0]];break}}}return o.reduceRight(((e,r,c)=>{let s,i=!1,p=null,m=null;var h;a&&(s=l&&r.route.id?l[r.route.id]:void 0,p=r.route.errorElement||b,u&&(d<0&&0===c?(h="route-fallback",!1||M[h]||(M[h]=!0),i=!0,m=null):d===c&&(i=!0,m=r.route.hydrateFallbackElement||null)));let g=t.concat(o.slice(0,c+1)),v=()=>{let t;return t=s?p:i?m:r.route.Component?n.createElement(r.route.Component,null):r.route.element?r.route.element:e,n.createElement(k,{match:r,routeContext:{outlet:e,matches:g,isDataRoute:null!=a},children:t})};return a&&(r.route.ErrorBoundary||r.route.errorElement||0===c)?n.createElement(w,{location:a.location,revalidation:a.revalidation,component:p,error:s,children:v(),routeContext:{outlet:null,matches:g,isDataRoute:!0}}):v()}),null)}var C=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(C||{}),_=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(_||{});function j(e){let t=n.useContext(s);return t||(0,r.Oi)(!1),t}function x(e){let t=n.useContext(i);return t||(0,r.Oi)(!1),t}function S(e){let t=function(){let e=n.useContext(u);return e||(0,r.Oi)(!1),e}(),a=t.matches[t.matches.length-1];return a.route.id||(0,r.Oi)(!1),a.route.id}const M={};const N={};const L=(e,t,a)=>{var n;N[n="⚠️ React Router Future Flag Warning: "+t+". You can use the `"+e+"` future flag to opt-in early. For more information, see "+a+"."]||(N[n]=!0,console.warn(n))};function P(e,t){void 0===(null==e?void 0:e.v7_startTransition)&&L("v7_startTransition","React Router will begin wrapping state updates in `React.startTransition` in v7","https://reactrouter.com/v6/upgrading/future#v7_starttransition"),void 0!==(null==e?void 0:e.v7_relativeSplatPath)||t&&t.v7_relativeSplatPath||L("v7_relativeSplatPath","Relative route resolution within Splat routes is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath"),t&&(void 0===t.v7_fetcherPersist&&L("v7_fetcherPersist","The persistence behavior of fetchers is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_fetcherpersist"),void 0===t.v7_normalizeFormMethod&&L("v7_normalizeFormMethod","Casing of `formMethod` fields is being normalized to uppercase in v7","https://reactrouter.com/v6/upgrading/future#v7_normalizeformmethod"),void 0===t.v7_partialHydration&&L("v7_partialHydration","`RouterProvider` hydration behavior is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_partialhydration"),void 0===t.v7_skipActionErrorRevalidation&&L("v7_skipActionErrorRevalidation","The revalidation behavior after 4xx/5xx `action` responses is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_skipactionerrorrevalidation"))}n.startTransition;function z(e){let{to:t,replace:a,state:c,relative:s}=e;m()||(0,r.Oi)(!1);let{future:i,static:l}=n.useContext(o),{matches:d}=n.useContext(u),{pathname:p}=h(),g=v(),f=(0,r.Gh)(t,(0,r.yD)(d,i.v7_relativeSplatPath),p,"path"===s),y=JSON.stringify(f);return n.useEffect((()=>g(JSON.parse(y),{replace:a,state:c,relative:s})),[g,y,s,a,c]),null}function O(e){(0,r.Oi)(!1)}function I(e){let{basename:t="/",children:a=null,location:s,navigationType:i=r.rc.Pop,navigator:u,static:d=!1,future:p}=e;m()&&(0,r.Oi)(!1);let h=t.replace(/^\/*/,"/"),g=n.useMemo((()=>({basename:h,navigator:u,static:d,future:c({v7_relativeSplatPath:!1},p)})),[h,p,u,d]);"string"==typeof s&&(s=(0,r.Rr)(s));let{pathname:v="/",search:f="",hash:y="",state:E=null,key:A="default"}=s,b=n.useMemo((()=>{let e=(0,r.pb)(v,h);return null==e?null:{location:{pathname:e,search:f,hash:y,state:E,key:A},navigationType:i}}),[h,v,f,y,E,A,i]);return null==b?null:n.createElement(o.Provider,{value:g},n.createElement(l.Provider,{children:a,value:b}))}function F(e){let{children:t,location:a}=e;return E(V(t),a)}new Promise((()=>{}));n.Component;function V(e,t){void 0===t&&(t=[]);let a=[];return n.Children.forEach(e,((e,c)=>{if(!n.isValidElement(e))return;let s=[...t,c];if(e.type===n.Fragment)return void a.push.apply(a,V(e.props.children,s));e.type!==O&&(0,r.Oi)(!1),e.props.index&&e.props.children&&(0,r.Oi)(!1);let i={id:e.props.id||s.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(i.children=V(e.props.children,s)),a.push(i)})),a}},372:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(6941);const r=a.n(n)()("dops:analytics");let c,s;window._tkq=window._tkq||[],window.ga=window.ga||function(){(window.ga.q=window.ga.q||[]).push(arguments)},window.ga.l=+new Date;const i={initialize:function(e,t,a){i.setUser(e,t),i.setSuperProps(a),i.identifyUser()},setGoogleAnalyticsEnabled:function(e,t=null){this.googleAnalyticsEnabled=e,this.googleAnalyticsKey=t},setMcAnalyticsEnabled:function(e){this.mcAnalyticsEnabled=e},setUser:function(e,t){s={ID:e,username:t}},setSuperProps:function(e){c=e},assignSuperProps:function(e){c=Object.assign(c||{},e)},mc:{bumpStat:function(e,t){const a=function(e,t){let a="";if("object"==typeof e){for(const t in e)a+="&x_"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);r("Bumping stats %o",e)}else a="&x_"+encodeURIComponent(e)+"="+encodeURIComponent(t),r('Bumping stat "%s" in group "%s"',t,e);return a}(e,t);i.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom-no-pv"+a+"&t="+Math.random())},bumpStatWithPageView:function(e,t){const a=function(e,t){let a="";if("object"==typeof e){for(const t in e)a+="&"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);r("Built stats %o",e)}else a="&"+encodeURIComponent(e)+"="+encodeURIComponent(t),r('Built stat "%s" in group "%s"',t,e);return a}(e,t);i.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom"+a+"&t="+Math.random())}},pageView:{record:function(e,t){i.tracks.recordPageView(e),i.ga.recordPageView(e,t)}},purchase:{record:function(e,t,a,n,r,c,s){i.ga.recordPurchase(e,t,a,n,r,c,s)}},tracks:{recordEvent:function(e,t){t=t||{},0===e.indexOf("akismet_")||0===e.indexOf("jetpack_")?(c&&(r("- Super Props: %o",c),t=Object.assign(t,c)),r('Record event "%s" called with props %s',e,JSON.stringify(t)),window._tkq.push(["recordEvent",e,t])):r('- Event name must be prefixed by "akismet_" or "jetpack_"')},recordJetpackClick:function(e){const t="object"==typeof e?e:{target:e};i.tracks.recordEvent("jetpack_wpa_click",t)},recordPageView:function(e){i.tracks.recordEvent("akismet_page_view",{path:e})},setOptOut:function(e){r("Pushing setOptOut: %o",e),window._tkq.push(["setOptOut",e])}},ga:{initialized:!1,initialize:function(){let e={};i.ga.initialized||(s&&(e={userId:"u-"+s.ID}),window.ga("create",this.googleAnalyticsKey,"auto",e),i.ga.initialized=!0)},recordPageView:function(e,t){i.ga.initialize(),r("Recording Page View ~ [URL: "+e+"] [Title: "+t+"]"),this.googleAnalyticsEnabled&&(window.ga("set","page",e),window.ga("send",{hitType:"pageview",page:e,title:t}))},recordEvent:function(e,t,a,n){i.ga.initialize();let c="Recording Event ~ [Category: "+e+"] [Action: "+t+"]";void 0!==a&&(c+=" [Option Label: "+a+"]"),void 0!==n&&(c+=" [Option Value: "+n+"]"),r(c),this.googleAnalyticsEnabled&&window.ga("send","event",e,t,a,n)},recordPurchase:function(e,t,a,n,r,c,s){window.ga("require","ecommerce"),window.ga("ecommerce:addTransaction",{id:e,revenue:n,currency:s}),window.ga("ecommerce:addItem",{id:e,name:t,sku:a,price:r,quantity:c}),window.ga("ecommerce:send")}},identifyUser:function(){s&&window._tkq.push(["identifyUser",s.ID,s.username])},setProperties:function(e){window._tkq.push(["setProperties",e])},clearedIdentity:function(){window._tkq.push(["clearIdentity"])}},o=i},5932:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>d});var n=a(6439),r=a(3832);function c(e){class t extends Error{constructor(...t){super(...t),this.name=e}}return t}const s=c("JsonParseError"),i=c("JsonParseAfterRedirectError"),o=c("Api404Error"),l=c("Api404AfterRedirectError"),u=c("FetchNetworkError");const d=new function(e,t){let a=e,c=e,s={"X-WP-Nonce":t},i={credentials:"same-origin",headers:s},o={method:"post",credentials:"same-origin",headers:Object.assign({},s,{"Content-type":"application/json"})},l=function(e){const t=e.split("?"),a=t.length>1?t[1]:"",n=a.length?a.split("&"):[];return n.push("_cacheBuster="+(new Date).getTime()),t[0]+"?"+n.join("&")};const u={setApiRoot(e){a=e},setWpcomOriginApiUrl(e){c=e},setApiNonce(e){s={"X-WP-Nonce":e},i={credentials:"same-origin",headers:s},o={method:"post",credentials:"same-origin",headers:Object.assign({},s,{"Content-type":"application/json"})}},setCacheBusterCallback:e=>{l=e},registerSite:(e,t,r)=>{const c={};return(0,n.jetpackConfigHas)("consumer_slug")&&(c.plugin_slug=(0,n.jetpackConfigGet)("consumer_slug")),null!==t&&(c.redirect_uri=t),r&&(c.from=r),h(`${a}jetpack/v4/connection/register`,o,{body:JSON.stringify(c)}).then(p).then(m)},fetchAuthorizationUrl:e=>d((0,r.addQueryArgs)(`${a}jetpack/v4/connection/authorize_url`,{no_iframe:"1",redirect_uri:e}),i).then(p).then(m),fetchSiteConnectionData:()=>d(`${a}jetpack/v4/connection/data`,i).then(m),fetchSiteConnectionStatus:()=>d(`${a}jetpack/v4/connection`,i).then(m),fetchSiteConnectionTest:()=>d(`${a}jetpack/v4/connection/test`,i).then(p).then(m),fetchUserConnectionData:()=>d(`${a}jetpack/v4/connection/data`,i).then(m),fetchUserTrackingSettings:()=>d(`${a}jetpack/v4/tracking/settings`,i).then(p).then(m),updateUserTrackingSettings:e=>h(`${a}jetpack/v4/tracking/settings`,o,{body:JSON.stringify(e)}).then(p).then(m),disconnectSite:()=>h(`${a}jetpack/v4/connection`,o,{body:JSON.stringify({isActive:!1})}).then(p).then(m),fetchConnectUrl:()=>d(`${a}jetpack/v4/connection/url`,i).then(p).then(m),unlinkUser:(e=!1,t={})=>{const n={linked:!1,force:!!e};return t.disconnectAllUsers&&(n["disconnect-all-users"]=!0),h(`${a}jetpack/v4/connection/user`,o,{body:JSON.stringify(n)}).then(p).then(m)},reconnect:()=>h(`${a}jetpack/v4/connection/reconnect`,o).then(p).then(m),fetchConnectedPlugins:()=>d(`${a}jetpack/v4/connection/plugins`,i).then(p).then(m),setHasSeenWCConnectionModal:()=>h(`${a}jetpack/v4/seen-wc-connection-modal`,o).then(p).then(m),fetchModules:()=>d(`${a}jetpack/v4/module/all`,i).then(p).then(m),fetchModule:e=>d(`${a}jetpack/v4/module/${e}`,i).then(p).then(m),activateModule:e=>h(`${a}jetpack/v4/module/${e}/active`,o,{body:JSON.stringify({active:!0})}).then(p).then(m),deactivateModule:e=>h(`${a}jetpack/v4/module/${e}/active`,o,{body:JSON.stringify({active:!1})}),updateModuleOptions:(e,t)=>h(`${a}jetpack/v4/module/${e}`,o,{body:JSON.stringify(t)}).then(p).then(m),updateSettings:e=>h(`${a}jetpack/v4/settings`,o,{body:JSON.stringify(e)}).then(p).then(m),getProtectCount:()=>d(`${a}jetpack/v4/module/protect/data`,i).then(p).then(m),resetOptions:e=>h(`${a}jetpack/v4/options/${e}`,o,{body:JSON.stringify({reset:!0})}).then(p).then(m),activateVaultPress:()=>h(`${a}jetpack/v4/plugins`,o,{body:JSON.stringify({slug:"vaultpress",status:"active"})}).then(p).then(m),getVaultPressData:()=>d(`${a}jetpack/v4/module/vaultpress/data`,i).then(p).then(m),installPlugin:(e,t)=>{const n={slug:e,status:"active"};return t&&(n.source=t),h(`${a}jetpack/v4/plugins`,o,{body:JSON.stringify(n)}).then(p).then(m)},activateAkismet:()=>h(`${a}jetpack/v4/plugins`,o,{body:JSON.stringify({slug:"akismet",status:"active"})}).then(p).then(m),getAkismetData:()=>d(`${a}jetpack/v4/module/akismet/data`,i).then(p).then(m),checkAkismetKey:()=>d(`${a}jetpack/v4/module/akismet/key/check`,i).then(p).then(m),checkAkismetKeyTyped:e=>h(`${a}jetpack/v4/module/akismet/key/check`,o,{body:JSON.stringify({api_key:e})}).then(p).then(m),getFeatureTypeStatus:e=>d(`${a}jetpack/v4/feature/${e}`,i).then(p).then(m),fetchStatsData:e=>d(function(e){let t=`${a}jetpack/v4/module/stats/data`;-1!==t.indexOf("?")?t+=`&range=${encodeURIComponent(e)}`:t+=`?range=${encodeURIComponent(e)}`;return t}(e),i).then(p).then(m).then(v),getPluginUpdates:()=>d(`${a}jetpack/v4/updates/plugins`,i).then(p).then(m),getPlans:()=>d(`${a}jetpack/v4/plans`,i).then(p).then(m),fetchSettings:()=>d(`${a}jetpack/v4/settings`,i).then(p).then(m),updateSetting:e=>h(`${a}jetpack/v4/settings`,o,{body:JSON.stringify(e)}).then(p).then(m),fetchSiteData:()=>d(`${a}jetpack/v4/site`,i).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteFeatures:()=>d(`${a}jetpack/v4/site/features`,i).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteProducts:()=>d(`${a}jetpack/v4/site/products`,i).then(p).then(m),fetchSitePurchases:()=>d(`${a}jetpack/v4/site/purchases`,i).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteBenefits:()=>d(`${a}jetpack/v4/site/benefits`,i).then(p).then(m).then((e=>JSON.parse(e.data))),fetchSiteDiscount:()=>d(`${a}jetpack/v4/site/discount`,i).then(p).then(m).then((e=>e.data)),fetchSetupQuestionnaire:()=>d(`${a}jetpack/v4/setup/questionnaire`,i).then(p).then(m),fetchRecommendationsData:()=>d(`${a}jetpack/v4/recommendations/data`,i).then(p).then(m),fetchRecommendationsProductSuggestions:()=>d(`${a}jetpack/v4/recommendations/product-suggestions`,i).then(p).then(m),fetchRecommendationsUpsell:()=>d(`${a}jetpack/v4/recommendations/upsell`,i).then(p).then(m),fetchRecommendationsConditional:()=>d(`${a}jetpack/v4/recommendations/conditional`,i).then(p).then(m),saveRecommendationsData:e=>h(`${a}jetpack/v4/recommendations/data`,o,{body:JSON.stringify({data:e})}).then(p),fetchProducts:()=>d(`${a}jetpack/v4/products`,i).then(p).then(m),fetchRewindStatus:()=>d(`${a}jetpack/v4/rewind`,i).then(p).then(m).then((e=>JSON.parse(e.data))),fetchScanStatus:()=>d(`${a}jetpack/v4/scan`,i).then(p).then(m).then((e=>JSON.parse(e.data))),dismissJetpackNotice:e=>h(`${a}jetpack/v4/notice/${e}`,o,{body:JSON.stringify({dismissed:!0})}).then(p).then(m),fetchPluginsData:()=>d(`${a}jetpack/v4/plugins`,i).then(p).then(m),fetchIntroOffers:()=>d(`${a}jetpack/v4/intro-offers`,i).then(p).then(m),fetchVerifySiteGoogleStatus:e=>d(null!==e?`${a}jetpack/v4/verify-site/google/${e}`:`${a}jetpack/v4/verify-site/google`,i).then(p).then(m),verifySiteGoogle:e=>h(`${a}jetpack/v4/verify-site/google`,o,{body:JSON.stringify({keyring_id:e})}).then(p).then(m),submitSurvey:e=>h(`${a}jetpack/v4/marketing/survey`,o,{body:JSON.stringify(e)}).then(p).then(m),saveSetupQuestionnaire:e=>h(`${a}jetpack/v4/setup/questionnaire`,o,{body:JSON.stringify(e)}).then(p).then(m),updateLicensingError:e=>h(`${a}jetpack/v4/licensing/error`,o,{body:JSON.stringify(e)}).then(p).then(m),updateLicenseKey:e=>h(`${a}jetpack/v4/licensing/set-license`,o,{body:JSON.stringify({license:e})}).then(p).then(m),getUserLicensesCounts:()=>d(`${a}jetpack/v4/licensing/user/counts`,i).then(p).then(m),getUserLicenses:()=>d(`${a}jetpack/v4/licensing/user/licenses`,i).then(p).then(m),updateLicensingActivationNoticeDismiss:e=>h(`${a}jetpack/v4/licensing/user/activation-notice-dismiss`,o,{body:JSON.stringify({last_detached_count:e})}).then(p).then(m),updateRecommendationsStep:e=>h(`${a}jetpack/v4/recommendations/step`,o,{body:JSON.stringify({step:e})}).then(p),confirmIDCSafeMode:()=>h(`${a}jetpack/v4/identity-crisis/confirm-safe-mode`,o).then(p),startIDCFresh:e=>h(`${a}jetpack/v4/identity-crisis/start-fresh`,o,{body:JSON.stringify({redirect_uri:e})}).then(p).then(m),migrateIDC:()=>h(`${a}jetpack/v4/identity-crisis/migrate`,o).then(p),attachLicenses:e=>h(`${a}jetpack/v4/licensing/attach-licenses`,o,{body:JSON.stringify({licenses:e})}).then(p).then(m),fetchSearchPlanInfo:()=>d(`${c}jetpack/v4/search/plan`,i).then(p).then(m),fetchSearchSettings:()=>d(`${c}jetpack/v4/search/settings`,i).then(p).then(m),updateSearchSettings:e=>h(`${c}jetpack/v4/search/settings`,o,{body:JSON.stringify(e)}).then(p).then(m),fetchSearchStats:()=>d(`${c}jetpack/v4/search/stats`,i).then(p).then(m),fetchWafSettings:()=>d(`${a}jetpack/v4/waf`,i).then(p).then(m),updateWafSettings:e=>h(`${a}jetpack/v4/waf`,o,{body:JSON.stringify(e)}).then(p).then(m),fetchWordAdsSettings:()=>d(`${a}jetpack/v4/wordads/settings`,i).then(p).then(m),updateWordAdsSettings:e=>h(`${a}jetpack/v4/wordads/settings`,o,{body:JSON.stringify(e)}),fetchSearchPricing:()=>d(`${c}jetpack/v4/search/pricing`,i).then(p).then(m),fetchMigrationStatus:()=>d(`${a}jetpack/v4/migration/status`,i).then(p).then(m),fetchBackupUndoEvent:()=>d(`${a}jetpack/v4/site/backup/undo-event`,i).then(p).then(m),fetchBackupPreflightStatus:()=>d(`${a}jetpack/v4/site/backup/preflight`,i).then(p).then(m)};function d(e,t){return fetch(l(e),t)}function h(e,t,a){return fetch(e,Object.assign({},t,a)).catch(g)}function v(e){return e.general&&void 0===e.general.response||e.week&&void 0===e.week.response||e.month&&void 0===e.month.response?e:{}}Object.assign(this,u)};function p(e){return e.status>=200&&e.status<300?e:404===e.status?new Promise((()=>{throw e.redirected?new l(e.redirected):new o})):e.json().catch((e=>h(e))).then((t=>{const a=new Error(`${t.message} (Status ${e.status})`);throw a.response=t,a.name="ApiError",a}))}function m(e){return e.json().catch((t=>h(t,e.redirected,e.url)))}function h(e,t,a){throw t?new i(a):new s}function g(){throw new u}},1330:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var n=a(6427),r=a(7723),c=a(991),s=a(1112),i=a(442),o=a(7425),l=a(723),u=a(8579);const __=r.__,d=({hideCloseButton:e=!1,title:t,children:a,step:d=null,totalSteps:p=null,buttonContent:m=null,buttonDisabled:h=!1,buttonHref:g=null,buttonExternalLink:v=!1,offset:f=32,onClose:y,onClick:E,...A})=>{const[b]=(0,i.A)("sm");if(!t||!a||!m)return null;A.position||(A.position=b?"top center":"middle right");const w={...A,offset:f,onClose:y},k=Number.isFinite(d)&&Number.isFinite(p);let R=null;return k&&(R=(0,r.sprintf)(/* translators: 1 Current step, 2 Total steps */ -__("%1$d of %2$d","jetpack-protect"),d,p)),React.createElement(n.Popover,w,React.createElement(l.Ay,null,React.createElement("div",{className:u.A.wrapper},React.createElement("div",{className:u.A.header},React.createElement(o.Ay,{variant:"title-small",className:u.A.title},t),!e&&React.createElement(React.Fragment,null,React.createElement(s.A,{size:"small",variant:"tertiary","aria-label":"close",className:u.A["close-button"],icon:c.A,iconSize:16,onClick:y}))),a,React.createElement("div",{className:u.A.footer},k&&React.createElement(o.Ay,{variant:"body",className:u.A.steps},R),React.createElement(s.A,{variant:"primary",className:u.A["action-button"],disabled:h,onClick:E,isExternalLink:v,href:g},m)))))}},2947:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(5932),r=a(7723),c=a(3022),s=a(1609),i=a(8250),o=a(7142),l=a(8509),u=a(5918),d=a(2021);const __=r.__,p=({children:e,moduleName:t=__("Jetpack","jetpack-protect"),moduleNameHref:a,showHeader:p=!0,showFooter:m=!0,useInternalLinks:h=!1,showBackground:g=!0,sandboxedDomain:v="",apiRoot:f="",apiNonce:y="",optionalMenuItems:E,header:A})=>{(0,s.useEffect)((()=>{n.Ay.setApiRoot(f),n.Ay.setApiNonce(y)}),[f,y]);const b=(0,c.A)(d.A["admin-page"],{[d.A.background]:g}),w=(0,s.useCallback)((async()=>{try{const e=await n.Ay.fetchSiteConnectionTest();window.alert(e.message)}catch(e){window.alert((0,r.sprintf)(/* translators: placeholder is an error message. */ -__("There was an error testing Jetpack. Error: %s","jetpack-protect"),e.message))}}),[]);return React.createElement("div",{className:b},p&&React.createElement(u.A,{horizontalSpacing:5},React.createElement(l.A,{className:(0,c.A)(d.A["admin-page-header"],"jp-admin-page-header")},A||React.createElement(o.A,null),v&&React.createElement("code",{className:d.A["sandbox-domain-badge"],onClick:w,onKeyDown:w,role:"button",tabIndex:0,title:`Sandboxing via ${v}. Click to test connection.`},"API Sandboxed"))),React.createElement(u.A,{fluid:!0,horizontalSpacing:0},React.createElement(l.A,null,e)),m&&React.createElement(u.A,{horizontalSpacing:5},React.createElement(l.A,null,React.createElement(i.A,{moduleName:t,moduleNameHref:a,menu:E,useInternalLinks:h}))))}},5640:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var n=a(1609),r=a.n(n),c=a(654);const s=({children:e})=>r().createElement("div",{className:c.A.section},e)},766:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var n=a(1609),r=a.n(n),c=a(6888);const s=({children:e})=>r().createElement("div",{className:c.A["section-hero"]},e)},8907:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(6072),r=a.n(n),c=a(7723),s=a(3022),i=a(1609),o=a.n(i);const __=c.__,l=({title:e=__("An Automattic Airline","jetpack-protect"),height:t=7,className:a,...n})=>o().createElement("svg",r()({role:"img",x:"0",y:"0",viewBox:"0 0 935 38.2",enableBackground:"new 0 0 935 38.2","aria-labelledby":"jp-automattic-byline-logo-title",height:t,className:(0,s.A)("jp-automattic-byline-logo",a)},n),o().createElement("desc",{id:"jp-automattic-byline-logo-title"},e),o().createElement("path",{d:"M317.1 38.2c-12.6 0-20.7-9.1-20.7-18.5v-1.2c0-9.6 8.2-18.5 20.7-18.5 12.6 0 20.8 8.9 20.8 18.5v1.2C337.9 29.1 329.7 38.2 317.1 38.2zM331.2 18.6c0-6.9-5-13-14.1-13s-14 6.1-14 13v0.9c0 6.9 5 13.1 14 13.1s14.1-6.2 14.1-13.1V18.6zM175 36.8l-4.7-8.8h-20.9l-4.5 8.8h-7L157 1.3h5.5L182 36.8H175zM159.7 8.2L152 23.1h15.7L159.7 8.2zM212.4 38.2c-12.7 0-18.7-6.9-18.7-16.2V1.3h6.6v20.9c0 6.6 4.3 10.5 12.5 10.5 8.4 0 11.9-3.9 11.9-10.5V1.3h6.7V22C231.4 30.8 225.8 38.2 212.4 38.2zM268.6 6.8v30h-6.7v-30h-15.5V1.3h37.7v5.5H268.6zM397.3 36.8V8.7l-1.8 3.1 -14.9 25h-3.3l-14.7-25 -1.8-3.1v28.1h-6.5V1.3h9.2l14 24.4 1.7 3 1.7-3 13.9-24.4h9.1v35.5H397.3zM454.4 36.8l-4.7-8.8h-20.9l-4.5 8.8h-7l19.2-35.5h5.5l19.5 35.5H454.4zM439.1 8.2l-7.7 14.9h15.7L439.1 8.2zM488.4 6.8v30h-6.7v-30h-15.5V1.3h37.7v5.5H488.4zM537.3 6.8v30h-6.7v-30h-15.5V1.3h37.7v5.5H537.3zM569.3 36.8V4.6c2.7 0 3.7-1.4 3.7-3.4h2.8v35.5L569.3 36.8 569.3 36.8zM628 11.3c-3.2-2.9-7.9-5.7-14.2-5.7 -9.5 0-14.8 6.5-14.8 13.3v0.7c0 6.7 5.4 13 15.3 13 5.9 0 10.8-2.8 13.9-5.7l4 4.2c-3.9 3.8-10.5 7.1-18.3 7.1 -13.4 0-21.6-8.7-21.6-18.3v-1.2c0-9.6 8.9-18.7 21.9-18.7 7.5 0 14.3 3.1 18 7.1L628 11.3zM321.5 12.4c1.2 0.8 1.5 2.4 0.8 3.6l-6.1 9.4c-0.8 1.2-2.4 1.6-3.6 0.8l0 0c-1.2-0.8-1.5-2.4-0.8-3.6l6.1-9.4C318.7 11.9 320.3 11.6 321.5 12.4L321.5 12.4z"}),o().createElement("path",{d:"M37.5 36.7l-4.7-8.9H11.7l-4.6 8.9H0L19.4 0.8H25l19.7 35.9H37.5zM22 7.8l-7.8 15.1h15.9L22 7.8zM82.8 36.7l-23.3-24 -2.3-2.5v26.6h-6.7v-36H57l22.6 24 2.3 2.6V0.8h6.7v35.9H82.8z"}),o().createElement("path",{d:"M719.9 37l-4.8-8.9H694l-4.6 8.9h-7.1l19.5-36h5.6l19.8 36H719.9zM704.4 8l-7.8 15.1h15.9L704.4 8zM733 37V1h6.8v36H733zM781 37c-1.8 0-2.6-2.5-2.9-5.8l-0.2-3.7c-0.2-3.6-1.7-5.1-8.4-5.1h-12.8V37H750V1h19.6c10.8 0 15.7 4.3 15.7 9.9 0 3.9-2 7.7-9 9 7 0.5 8.5 3.7 8.6 7.9l0.1 3c0.1 2.5 0.5 4.3 2.2 6.1V37H781zM778.5 11.8c0-2.6-2.1-5.1-7.9-5.1h-13.8v10.8h14.4c5 0 7.3-2.4 7.3-5.2V11.8zM794.8 37V1h6.8v30.4h28.2V37H794.8zM836.7 37V1h6.8v36H836.7zM886.2 37l-23.4-24.1 -2.3-2.5V37h-6.8V1h6.5l22.7 24.1 2.3 2.6V1h6.8v36H886.2zM902.3 37V1H935v5.6h-26v9.2h20v5.5h-20v10.1h26V37H902.3z"}))},4105:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(6072),r=a.n(n),c=a(3022),s=a(1609),i=a.n(s),o=a(2451);const l=({children:e,className:t,variant:a,...n})=>{const s=(0,c.A)(o.A.badge,{[o.A["is-success"]]:"success"===a,[o.A["is-warning"]]:"warning"===a,[o.A["is-danger"]]:"danger"===a},t);return i().createElement("span",r()({className:s},n),e)}},1112:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(6072),r=a.n(n),c=a(6427),s=a(7723),i=a(1113),o=a(3512),l=a(3022),u=a(1609),d=a.n(u),p=a(2258);const __=s.__,m=(0,u.forwardRef)(((e,t)=>{const{children:a,variant:n="primary",size:s="normal",weight:u="bold",icon:m,iconSize:h,disabled:g,isDestructive:v,isLoading:f,isExternalLink:y,className:E,text:A,fullWidth:b,...w}=e,k=(0,l.A)(p.A.button,E,{[p.A.normal]:"normal"===s,[p.A.small]:"small"===s,[p.A.icon]:Boolean(m),[p.A.loading]:f,[p.A.regular]:"regular"===u,[p.A["full-width"]]:b,[p.A["is-icon-button"]]:Boolean(m)&&!a});w.ref=t;const R="normal"===s?20:16,C=y&&d().createElement(d().Fragment,null,d().createElement(i.A,{size:R,icon:o.A,className:p.A["external-icon"]}),d().createElement(c.VisuallyHidden,{as:"span"},/* translators: accessibility text */ -__("(opens in a new tab)","jetpack-protect"))),_=y?"_blank":void 0,j=a?.[0]&&null!==a[0]&&"components-tooltip"!==a?.[0]?.props?.className;return d().createElement(c.Button,r()({target:_,variant:n,className:(0,l.A)(k,{"has-text":!!m&&j}),icon:y?void 0:m,iconSize:h,disabled:g,"aria-disabled":g,isDestructive:v,text:A},w),f&&d().createElement(c.Spinner,null),d().createElement("span",null,a),C)}));m.displayName="Button";const h=m},4437:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(1113),r=a(1797),c=a(3022),s=a(597),i=a(7425),o=a(2127);const l=({description:e,cta:t,onClick:a,href:l,openInNewTab:u=!1,className:d,tooltipText:p=""})=>{const m=void 0!==l?"a":"button",h="a"===m?{href:l,...u&&{target:"_blank"}}:{onClick:a};return React.createElement("div",{className:(0,c.A)(o.A.cut,d)},React.createElement("div",null,React.createElement("div",null,React.createElement(i.Ay,{className:o.A.description},e),p&&React.createElement(s.A,{className:o.A.iconContainer,iconSize:16,offset:4},React.createElement(i.Ay,{variant:"body-small"},p))),React.createElement("div",null,React.createElement(m,h,React.createElement(i.Ay,{className:o.A.cta},t)))),React.createElement(n.A,{icon:r.A,className:o.A.icon,size:30}))}},4252:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(1609),r=a(4433),c=a(680),s=a(6373);const i=({diff:e})=>React.createElement("div",{className:s.A["diff-viewer"]},(0,c.A)(e).map(((e,t)=>React.createElement(n.Fragment,{key:t},React.createElement("div",{key:`file-${t}`,className:s.A["diff-viewer__filename"]},(({oldFileName:e,newFileName:t})=>{const{prev:a,next:c}=(0,r.A)(e,t);return a.prefix+a.path===c.prefix+c.path?React.createElement(n.Fragment,null,a.prefix&&React.createElement("span",{className:s.A["diff-viewer__path-prefix"]},a.prefix),React.createElement("span",{className:s.A["diff-viewer__path"]},a.path)):React.createElement(n.Fragment,null,!!a.prefix&&React.createElement("span",{className:s.A["diff-viewer__path-prefix"]},a.prefix),React.createElement("span",{className:s.A["diff-viewer__path"]},a.path)," → ",!!c.prefix&&React.createElement("span",{className:s.A["diff-viewer__path-prefix"]},c.prefix),React.createElement("span",{className:s.A["diff-viewer__path"]},c.path))})(e)),React.createElement("div",{key:`diff-${t}`,className:s.A["diff-viewer__file"]},React.createElement("div",{key:"left-numbers",className:s.A["diff-viewer__line-numbers"]},e.hunks.map(((e,t)=>{let a=0;return e.lines.map(((n,r)=>React.createElement("div",{key:`${t}-${r}`},"+"===n[0]?" ":e.oldStart+a++)))}))),React.createElement("div",{key:"right-numbers",className:s.A["diff-viewer__line-numbers"]},e.hunks.map(((e,t)=>{let a=0;return e.lines.map(((n,r)=>React.createElement("div",{key:`${t}-${r}`},"-"===n[0]?" ":e.newStart+a++)))}))),React.createElement("div",{className:s.A["diff-viewer__lines"]},e.hunks.map(((e,t)=>e.lines.map(((e,a)=>{const n=e.slice(1).replace(/^\s*$/," "),r=`${t}-${a}`;switch(e[0]){case" ":return React.createElement("div",{key:r},n);case"-":return React.createElement("del",{key:r},n);case"+":return React.createElement("ins",{key:r},n);default:return}}))))))))))},4433:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const n=e=>{const t=e.lastIndexOf("/");return t>-1?{prefix:e.slice(0,t),path:e.slice(t)}:{prefix:"",path:e}};function r(e,t){const a=e.startsWith("a/")&&t.startsWith("b/");if((e=a?e.slice(2):e)===(t=a?t.slice(2):t)){const{prefix:t,path:a}=n(e);return{prev:{prefix:t,path:a},next:{prefix:t,path:a}}}const r=Math.max(e.length,t.length);for(let a=0,n=0;a{"use strict";function n(e){const t=e.split(/\n/),a=[];let n=0;function r(){const e={};for(a.push(e);nn})},1883:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(7723),r=a(3022),c=a(1609);a(3689);const __=n.__;class s extends c.Component{static defaultProps={"aria-hidden":"false",focusable:"true"};needsOffset(e,t){return["gridicons-arrow-left","gridicons-arrow-right","gridicons-calendar","gridicons-cart","gridicons-folder","gridicons-help-outline","gridicons-info","gridicons-info-outline","gridicons-posts","gridicons-star-outline","gridicons-star"].indexOf(e)>=0&&t%18==0}getSVGDescription(e){if("description"in this.props)return this.props.description;switch(e){default:return"";case"gridicons-audio":return __("Has audio.","jetpack-protect");case"gridicons-arrow-left":return __("Arrow left","jetpack-protect");case"gridicons-arrow-right":return __("Arrow right","jetpack-protect");case"gridicons-calendar":return __("Is an event.","jetpack-protect");case"gridicons-cart":return __("Is a product.","jetpack-protect");case"chevron-down":return __("Show filters","jetpack-protect");case"gridicons-comment":return __("Matching comment.","jetpack-protect");case"gridicons-cross":return __("Close.","jetpack-protect");case"gridicons-filter":return __("Toggle search filters.","jetpack-protect");case"gridicons-folder":return __("Category","jetpack-protect");case"gridicons-help-outline":return __("Help","jetpack-protect");case"gridicons-info":case"gridicons-info-outline":return __("Information.","jetpack-protect");case"gridicons-image-multiple":return __("Has multiple images.","jetpack-protect");case"gridicons-image":return __("Has an image.","jetpack-protect");case"gridicons-page":return __("Page","jetpack-protect");case"gridicons-post":return __("Post","jetpack-protect");case"gridicons-jetpack-search":case"gridicons-search":return __("Magnifying Glass","jetpack-protect");case"gridicons-tag":return __("Tag","jetpack-protect");case"gridicons-video":return __("Has a video.","jetpack-protect")}}renderIcon(e){switch(e){default:return null;case"gridicons-audio":return React.createElement("g",null,React.createElement("path",{d:"M8 4v10.184C7.686 14.072 7.353 14 7 14c-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3V7h7v4.184c-.314-.112-.647-.184-1-.184-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3V4H8z"}));case"gridicons-arrow-left":return React.createElement("g",null,React.createElement("path",{d:"M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z"}));case"gridicons-arrow-right":return React.createElement("g",null,React.createElement("path",{d:"M12 4l-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8-8-8z"}));case"gridicons-block":return React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zM4 12c0-4.418 3.582-8 8-8 1.848 0 3.545.633 4.9 1.686L5.686 16.9C4.633 15.545 4 13.848 4 12zm8 8c-1.848 0-3.546-.633-4.9-1.686L18.314 7.1C19.367 8.455 20 10.152 20 12c0 4.418-3.582 8-8 8z"}));case"gridicons-calendar":return React.createElement("g",null,React.createElement("path",{d:"M19 4h-1V2h-2v2H8V2H6v2H5c-1.105 0-2 .896-2 2v13c0 1.104.895 2 2 2h14c1.104 0 2-.896 2-2V6c0-1.104-.896-2-2-2zm0 15H5V8h14v11z"}));case"gridicons-cart":return React.createElement("g",null,React.createElement("path",{d:"M9 20c0 1.1-.9 2-2 2s-1.99-.9-1.99-2S5.9 18 7 18s2 .9 2 2zm8-2c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2zm.396-5c.937 0 1.75-.65 1.952-1.566L21 5H7V4c0-1.105-.895-2-2-2H3v2h2v11c0 1.105.895 2 2 2h12c0-1.105-.895-2-2-2H7v-2h10.396z"}));case"gridicons-checkmark":return React.createElement("g",null,React.createElement("path",{d:"M11 17.768l-4.884-4.884 1.768-1.768L11 14.232l8.658-8.658C17.823 3.39 15.075 2 12 2 6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10c0-1.528-.353-2.97-.966-4.266L11 17.768z"}));case"gridicons-chevron-left":return React.createElement("g",null,React.createElement("path",{d:"M16.443 7.41L15.0399 6L9.06934 12L15.0399 18L16.443 16.59L11.8855 12L16.443 7.41Z"}));case"gridicons-chevron-right":return React.createElement("g",null,React.createElement("path",{d:"M10.2366 6L8.8335 7.41L13.391 12L8.8335 16.59L10.2366 18L16.2072 12L10.2366 6Z"}));case"gridicons-chevron-down":return React.createElement("g",null,React.createElement("path",{d:"M20 9l-8 8-8-8 1.414-1.414L12 14.172l6.586-6.586"}));case"gridicons-comment":return React.createElement("g",null,React.createElement("path",{d:"M3 6v9c0 1.105.895 2 2 2h9v5l5.325-3.804c1.05-.75 1.675-1.963 1.675-3.254V6c0-1.105-.895-2-2-2H5c-1.105 0-2 .895-2 2z"}));case"gridicons-computer":return React.createElement("g",null,React.createElement("path",{d:"M20 2H4c-1.104 0-2 .896-2 2v12c0 1.104.896 2 2 2h6v2H7v2h10v-2h-3v-2h6c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm0 14H4V4h16v12z"}));case"gridicons-cross":return React.createElement("g",null,React.createElement("path",{d:"M18.36 19.78L12 13.41l-6.36 6.37-1.42-1.42L10.59 12 4.22 5.64l1.42-1.42L12 10.59l6.36-6.36 1.41 1.41L13.41 12l6.36 6.36z"}));case"gridicons-filter":return React.createElement("g",null,React.createElement("path",{d:"M10 19h4v-2h-4v2zm-4-6h12v-2H6v2zM3 5v2h18V5H3z"}));case"gridicons-folder":return React.createElement("g",null,React.createElement("path",{d:"M18 19H6c-1.1 0-2-.9-2-2V7c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2h7c1.1 0 2 .9 2 2v8c0 1.1-.9 2-2 2z"}));case"gridicons-help-outline":return React.createElement("g",null,React.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 13h-2v2h2v-2zm-1.962-2v-.528c0-.4.082-.74.246-1.017.163-.276.454-.546.87-.808.333-.21.572-.397.717-.565.146-.168.22-.36.22-.577 0-.172-.078-.308-.234-.41-.156-.1-.358-.15-.608-.15-.62 0-1.34.22-2.168.658l-.854-1.67c1.02-.58 2.084-.872 3.194-.872.913 0 1.63.202 2.15.603.52.4.78.948.78 1.64 0 .495-.116.924-.347 1.287-.23.362-.6.705-1.11 1.03-.43.278-.7.48-.807.61-.108.13-.163.282-.163.458V13h-1.885z"}));case"gridicons-image":return React.createElement("g",null,React.createElement("path",{d:"M13 9.5c0-.828.672-1.5 1.5-1.5s1.5.672 1.5 1.5-.672 1.5-1.5 1.5-1.5-.672-1.5-1.5zM22 6v12c0 1.105-.895 2-2 2H4c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2h16c1.105 0 2 .895 2 2zm-2 0H4v7.444L8 9l5.895 6.55 1.587-1.85c.798-.932 2.24-.932 3.037 0L20 15.426V6z"}));case"gridicons-image-multiple":return React.createElement("g",null,React.createElement("path",{d:"M15 7.5c0-.828.672-1.5 1.5-1.5s1.5.672 1.5 1.5S17.328 9 16.5 9 15 8.328 15 7.5zM4 20h14c0 1.105-.895 2-2 2H4c-1.1 0-2-.9-2-2V8c0-1.105.895-2 2-2v14zM22 4v12c0 1.105-.895 2-2 2H8c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zM8 4v6.333L11 7l4.855 5.395.656-.73c.796-.886 2.183-.886 2.977 0l.513.57V4H8z"}));case"gridicons-info":return React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"}));case"gridicons-info-outline":return React.createElement("g",null,React.createElement("path",{d:"M13 9h-2V7h2v2zm0 2h-2v6h2v-6zm-1-7c-4.411 0-8 3.589-8 8s3.589 8 8 8 8-3.589 8-8-3.589-8-8-8m0-2c5.523 0 10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2z"}));case"gridicons-jetpack-search":return React.createElement("g",null,React.createElement("path",{d:"M0 9.257C0 4.15 4.151 0 9.257 0c5.105 0 9.256 4.151 9.256 9.257a9.218 9.218 0 01-2.251 6.045l.034.033h1.053L24 22.01l-1.986 1.989-6.664-6.662v-1.055l-.033-.033a9.218 9.218 0 01-6.06 2.264C4.15 18.513 0 14.362 0 9.257zm4.169 1.537h4.61V1.82l-4.61 8.973zm5.547-3.092v8.974l4.61-8.974h-4.61z"}));case"gridicons-phone":return React.createElement("g",null,React.createElement("path",{d:"M16 2H8c-1.104 0-2 .896-2 2v16c0 1.104.896 2 2 2h8c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm-3 19h-2v-1h2v1zm3-2H8V5h8v14z"}));case"gridicons-pages":return React.createElement("g",null,React.createElement("path",{d:"M16 8H8V6h8v2zm0 2H8v2h8v-2zm4-6v12l-6 6H6c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zm-2 10V4H6v16h6v-4c0-1.105.895-2 2-2h4z"}));case"gridicons-posts":return React.createElement("g",null,React.createElement("path",{d:"M16 19H3v-2h13v2zm5-10H3v2h18V9zM3 5v2h11V5H3zm14 0v2h4V5h-4zm-6 8v2h10v-2H11zm-8 0v2h5v-2H3z"}));case"gridicons-search":return React.createElement("g",null,React.createElement("path",{d:"M21 19l-5.154-5.154C16.574 12.742 17 11.42 17 10c0-3.866-3.134-7-7-7s-7 3.134-7 7 3.134 7 7 7c1.42 0 2.742-.426 3.846-1.154L19 21l2-2zM5 10c0-2.757 2.243-5 5-5s5 2.243 5 5-2.243 5-5 5-5-2.243-5-5z"}));case"gridicons-star-outline":return React.createElement("g",null,React.createElement("path",{d:"M12 6.308l1.176 3.167.347.936.997.042 3.374.14-2.647 2.09-.784.62.27.963.91 3.25-2.813-1.872-.83-.553-.83.552-2.814 1.87.91-3.248.27-.962-.783-.62-2.648-2.092 3.374-.14.996-.04.347-.936L12 6.308M12 2L9.418 8.953 2 9.257l5.822 4.602L5.82 21 12 16.89 18.18 21l-2.002-7.14L22 9.256l-7.418-.305L12 2z"}));case"gridicons-star":return React.createElement("g",null,React.createElement("path",{d:"M12 2l2.582 6.953L22 9.257l-5.822 4.602L18.18 21 12 16.89 5.82 21l2.002-7.14L2 9.256l7.418-.304"}));case"gridicons-tag":return React.createElement("g",null,React.createElement("path",{d:"M20 2.007h-7.087c-.53 0-1.04.21-1.414.586L2.592 11.5c-.78.78-.78 2.046 0 2.827l7.086 7.086c.78.78 2.046.78 2.827 0l8.906-8.906c.376-.374.587-.883.587-1.413V4.007c0-1.105-.895-2-2-2zM17.007 9c-1.105 0-2-.895-2-2s.895-2 2-2 2 .895 2 2-.895 2-2 2z"}));case"gridicons-video":return React.createElement("g",null,React.createElement("path",{d:"M20 4v2h-2V4H6v2H4V4c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2v-2h2v2h12v-2h2v2c1.105 0 2-.895 2-2V6c0-1.105-.895-2-2-2zM6 16H4v-3h2v3zm0-5H4V8h2v3zm4 4V9l4.5 3-4.5 3zm10 1h-2v-3h2v3zm0-5h-2V8h2v3z"}));case"gridicons-lock":return React.createElement(React.Fragment,null,React.createElement("g",{id:"lock"},React.createElement("path",{d:"M18,8h-1V7c0-2.757-2.243-5-5-5S7,4.243,7,7v1H6c-1.105,0-2,0.895-2,2v10c0,1.105,0.895,2,2,2h12c1.105,0,2-0.895,2-2V10 C20,8.895,19.105,8,18,8z M9,7c0-1.654,1.346-3,3-3s3,1.346,3,3v1H9V7z M13,15.723V18h-2v-2.277c-0.595-0.346-1-0.984-1-1.723 c0-1.105,0.895-2,2-2s2,0.895,2,2C14,14.738,13.595,15.376,13,15.723z"})),React.createElement("g",{id:"Layer_1"}));case"gridicons-external":return React.createElement("g",null,React.createElement("path",{d:"M19 13v6c0 1.105-.895 2-2 2H5c-1.105 0-2-.895-2-2V7c0-1.105.895-2 2-2h6v2H5v12h12v-6h2zM13 3v2h4.586l-7.793 7.793 1.414 1.414L19 6.414V11h2V3h-8z"}))}}render(){const{size:e=24,className:t=""}=this.props,a=this.props.height||e,n=this.props.width||e,c=this.props.style||{height:a,width:n},s="gridicons-"+this.props.icon,i=(0,r.A)("gridicon",s,t,{"needs-offset":this.needsOffset(s,e)}),o=this.getSVGDescription(s);return React.createElement("svg",{className:i,focusable:this.props.focusable,height:a,onClick:this.props.onClick,style:c,viewBox:"0 0 24 24",width:n,xmlns:"http://www.w3.org/2000/svg","aria-hidden":this.props["aria-hidden"]},o?React.createElement("desc",null,o):null,this.renderIcon(s))}}const i=s},597:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(6427),r=a(3022),c=a(1609),s=a.n(c),i=a(1112),o=a(1883);a(4803);const l=e=>({"top-end":"top left",top:"top center","top-start":"top right","bottom-end":"bottom left",bottom:"bottom center","bottom-start":"bottom right"}[e]),u=({className:e="",iconClassName:t="",placement:a="bottom-end",animate:u=!0,iconCode:d="info-outline",iconSize:p=18,offset:m=10,title:h,children:g,popoverAnchorStyle:v="icon",forceShow:f=!1,hoverShow:y=!1,wide:E=!1,inline:A=!0,shift:b=!1})=>{const[w,k]=(0,c.useState)(!1),[R,C]=(0,c.useState)(null),_=(0,c.useCallback)((()=>k(!1)),[k]),j=(0,c.useCallback)((e=>{e.preventDefault(),k(!w)}),[w,k]),x={position:l(a),placement:a,animate:u,noArrow:!1,resize:!1,flip:!1,offset:m,focusOnMount:"container",onClose:_,className:"icon-tooltip-container",inline:A,shift:b},S="wrapper"===v,M=(0,r.A)("icon-tooltip-wrapper",e),N={left:S?0:-(62-p/2)+"px"},L=S&&f,P=(0,c.useCallback)((()=>{y&&(R&&(clearTimeout(R),C(null)),k(!0))}),[y,R]),z=(0,c.useCallback)((()=>{if(y){const e=setTimeout((()=>{k(!1),C(null)}),100);C(e)}}),[y]);return s().createElement("div",{className:M,"data-testid":"icon-tooltip_wrapper",onMouseEnter:P,onMouseLeave:z},!S&&s().createElement(i.A,{variant:"link",onMouseDown:j},s().createElement(o.A,{className:t,icon:d,size:p})),s().createElement("div",{className:(0,r.A)("icon-tooltip-helper",{"is-wide":E}),style:N},(L||w)&&s().createElement(n.Popover,x,s().createElement("div",null,h&&s().createElement("div",{className:"icon-tooltip-title"},h),s().createElement("div",{className:"icon-tooltip-content"},g)))))}},8478:(e,t,a)=>{"use strict";a.d(t,{Wy:()=>u});var n=a(6072),r=a.n(n),c=a(6427),s=a(3022),i=(a(4705),a(2300));const o=({className:e,size:t=24,viewBox:a="0 0 24 24",opacity:n=1,color:o="#2C3338",children:l})=>{const u={className:(0,s.A)(i.A.iconWrapper,e),width:t,height:t,viewBox:a,opacity:n,fill:void 0};return o&&(u.fill=o),React.createElement(c.SVG,r()({},u,{fillRule:"evenodd",clipRule:"evenodd",xmlns:"http://www.w3.org/2000/svg"}),React.createElement(c.G,{opacity:n},l))},l={...{"anti-spam":({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"M13.2,4.7l4.7,12.8c0.4,1.1,1,1.5,2.1,1.6c0.1,0,0.1,0,0.1,0l0.1,0.1l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1 s0,0.1-0.1,0.1c-0.1,0-0.1,0.1-0.1,0.1s-0.1,0-0.2,0h-5.1c-0.1,0-0.1,0-0.2,0c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1 c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1l0.1-0.1c0,0,0.1,0,0.2,0c0.5,0,1.1-0.2,1.1-0.8c0-0.3-0.1-0.5-0.2-0.8l-1.1-3.1 c-0.1-0.2-0.1-0.2-0.2-0.2h-4.3c-0.7,0-1.5,0-1.9,0.9l-1.1,2.4C7.1,17.6,7,17.8,7,18.1c0,0.8,1,0.9,1.6,0.9c0.1,0,0.1,0,0.2,0 L8.8,19l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1s-0.1,0.1-0.1,0.1l-0.1,0.1c-0.1,0-0.1,0-0.2,0H4.1c-0.1,0-0.1,0-0.1,0 c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1L4,19c0,0,0.1,0,0.1,0C5.2,19,5.5,18.5,6,17.5 l5.4-12.4c0.2-0.5,0.8-1,1.3-1C13,4.2,13.1,4.4,13.2,4.7z M9.1,13.1c0,0.1-0.1,0.1-0.1,0.2c0,0.1,0.1,0.1,0.1,0.1h4.4 c0.3,0,0.4-0.1,0.4-0.3c0-0.1,0-0.2-0.1-0.3l-1.2-3.5c-0.3-0.8-0.8-1.9-0.8-2.7c0-0.1,0-0.1-0.1-0.1c0,0-0.1,0-0.1,0.1 c-0.1,0.6-0.4,1.2-0.7,1.7L9.1,13.1z"}),React.createElement(c.Path,{d:"M13.2,4.7l4.7,12.8c0.4,1.1,1,1.5,2.1,1.6c0.1,0,0.1,0,0.1,0l0.1,0.1l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1 s0,0.1-0.1,0.1c-0.1,0-0.1,0.1-0.1,0.1s-0.1,0-0.2,0h-5.1c-0.1,0-0.1,0-0.2,0c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1 c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1l0.1-0.1c0,0,0.1,0,0.2,0c0.5,0,1.1-0.2,1.1-0.8c0-0.3-0.1-0.5-0.2-0.8l-1.1-3.1 c-0.1-0.2-0.1-0.2-0.2-0.2h-4.3c-0.7,0-1.5,0-1.9,0.9l-1.1,2.4C7.1,17.6,7,17.8,7,18.1c0,0.8,1,0.9,1.6,0.9c0.1,0,0.1,0,0.2,0 L8.8,19l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1s-0.1,0.1-0.1,0.1l-0.1,0.1c-0.1,0-0.1,0-0.2,0H4.1c-0.1,0-0.1,0-0.1,0 c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1L4,19c0,0,0.1,0,0.1,0C5.2,19,5.5,18.5,6,17.5 l5.4-12.4c0.2-0.5,0.8-1,1.3-1C13,4.2,13.1,4.4,13.2,4.7z M9.1,13.1c0,0.1-0.1,0.1-0.1,0.2c0,0.1,0.1,0.1,0.1,0.1h4.4 c0.3,0,0.4-0.1,0.4-0.3c0-0.1,0-0.2-0.1-0.3l-1.2-3.5c-0.3-0.8-0.8-1.9-0.8-2.7c0-0.1,0-0.1-0.1-0.1c0,0-0.1,0-0.1,0.1 c-0.1,0.6-0.4,1.2-0.7,1.7L9.1,13.1z"}),React.createElement(c.Path,{d:"M21.6,12.5c0,0.6-0.3,1-0.9,1c-0.6,0-0.8-0.3-0.8-0.8c0-0.6,0.4-1,0.9-1C21.3,11.7,21.6,12.1,21.6,12.5z"}),React.createElement(c.Path,{d:"M4.1,12.5c0,0.6-0.3,1-0.9,1s-0.8-0.3-0.8-0.8c0-0.6,0.4-1,0.9-1S4.1,12.1,4.1,12.5z"})),backup:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"M2.1,5.8c0-0.1,0-0.1,0-0.2c0-0.2,0.1-0.5,0.1-0.7c0.1-0.4,0.4-0.6,0.7-0.8l8.3-2.9c0.1-0.1,0.3-0.1,0.4-0.1l0.5,0.1 l8.3,2.9c0.3,0.2,0.5,0.4,0.7,0.7c0.2,0.2,0.2,0.4,0.2,0.7c0,0.1,0,0.1,0,0.2v0.1c-0.1,0.5-0.2,0.9-0.3,1.4 c-0.2,0.4-0.3,1.2-0.7,2.2c-0.3,1-0.7,2.1-1.1,3.1c-0.5,1-1,2.1-1.6,3.3s-1.4,2.3-2.2,3.5c-0.9,1.1-1.8,2.2-2.8,3.1 c-0.2,0.2-0.5,0.4-0.9,0.4c-0.3,0-0.6-0.1-0.9-0.4c-1.2-1.1-2.4-2.4-3.5-4c-1-1.6-1.9-3-2.5-4.3c-0.6-1.3-1.1-2.7-1.6-4 C2.8,8.7,2.5,7.6,2.3,7C2.3,6.5,2.1,6.1,2.1,5.8z M2.9,5.9c0,0.2,0.1,0.4,0.1,0.8C3.1,7,3.2,7.5,3.5,8.2C3.7,9,3.9,9.7,4.2,10.6 c0.3,0.7,0.7,1.7,1.1,2.7c0.4,1,1,2,1.5,2.9c0.5,1,1.2,1.9,1.9,2.9c0.8,1,1.6,1.9,2.4,2.6c0.2,0.2,0.4,0.2,0.5,0.2 c0.2,0,0.4-0.1,0.5-0.2c1.2-1,2.2-2.3,3.2-3.8c1-1.5,1.8-2.8,2.3-4c0.6-1.3,1.1-2.5,1.5-3.9c0.4-1.3,0.7-2.2,0.9-2.8 c0.1-0.5,0.2-1,0.3-1.3c0-0.1,0-0.1,0-0.1c0-0.2,0-0.3-0.1-0.4C20.3,5.2,20.2,5.1,20,5L12,2.1c0,0-0.1,0-0.2,0s-0.1,0-0.1,0h-0.2 l-8,2.8C3.2,5,3.1,5.2,3,5.3C2.9,5.5,2.9,5.6,2.9,5.8C2.9,5.8,2.9,5.8,2.9,5.9z M5.9,6.7h3l2.8,7l2.8-7h3c-0.1,0.1-0.2,0.5-0.3,0.8 C17,7.8,17,8.2,16.8,8.4c-0.1,0.3-0.2,0.5-0.4,0.8c0,0.1-0.1,0.1-0.1,0.1s-0.1,0.1-0.2,0.1c-0.1,0-0.1,0-0.1,0 c-0.1,0-0.2,0.1-0.2,0.2c0,0-0.1,0.1-0.1,0.1s-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.2c0,0.1-0.1,0.1-0.1,0.1l-0.4,1.1 c-1.3,3.3-2.1,5.2-2.3,5.8h-2.2l-1-2.4c-0.1-0.3-0.3-0.8-0.5-1.3c-0.1-0.3-0.3-0.8-0.5-1.3L8,10.8c-0.1-0.1-0.1-0.2-0.1-0.4 C7.8,10.2,7.7,10,7.7,9.8C7.6,9.7,7.5,9.5,7.4,9.4C7.3,9.3,7.3,9.3,7.3,9.3c-0.1,0-0.2,0-0.2,0s-0.1,0-0.1,0 C6.6,8.5,6.3,7.6,5.9,6.7z"})),boost:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M4.19505 16.2545C4.47368 16.561 4.94802 16.5836 5.25451 16.3049L10.2595 11.7549L14.2842 15.2765L19 10.5607V13.75H20.5V9.5V8.75239V8.7476V8H19.7529H19.7471H19H14.75V9.5H17.9393L14.2158 13.2235L10.2405 9.74507L4.2455 15.195C3.93901 15.4737 3.91642 15.948 4.19505 16.2545Z"})),crm:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"M15.5 9.5a1 1 0 1 0 0-2 1 1 0 0 0 0 2Zm0 1.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Zm-2.25 6v-2a2.75 2.75 0 0 0-2.75-2.75h-4A2.75 2.75 0 0 0 3.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5Zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0 1 20.25 15ZM9.5 8.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Zm1.5 0a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0Z"})),extras:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"M18.5 5.5V8H20V5.5h2.5V4H20V1.5h-1.5V4H16v1.5h2.5ZM12 4H6a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-6h-1.5v6a.5.5 0 0 1-.5.5H6a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5h6V4Z"})),protect:({opacity:e=1,size:t,className:a,color:n})=>React.createElement(o,{className:a,size:t,opacity:e,color:n},React.createElement(c.Path,{d:"M12 3.17627L18.75 6.24445V10.8183C18.75 14.7173 16.2458 18.4089 12.7147 19.5735C12.2507 19.7265 11.7493 19.7265 11.2853 19.5735C7.75416 18.4089 5.25 14.7173 5.25 10.8183V6.24445L12 3.17627ZM6.75 7.21032V10.8183C6.75 14.1312 8.89514 17.2057 11.7551 18.149C11.914 18.2014 12.086 18.2014 12.2449 18.149C15.1049 17.2057 17.25 14.1312 17.25 10.8183V7.21032L12 4.82396L6.75 7.21032Z"}),React.createElement(c.Path,{d:"M15.5291 10.0315L11.1818 14.358L8.47095 11.66L9.52907 10.5968L11.1818 12.2417L14.4709 8.96826L15.5291 10.0315Z"})),scan:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"m12 3.176 6.75 3.068v4.574c0 3.9-2.504 7.59-6.035 8.755a2.283 2.283 0 0 1-1.43 0c-3.53-1.164-6.035-4.856-6.035-8.755V6.244L12 3.176ZM6.75 7.21v3.608c0 3.313 2.145 6.388 5.005 7.33.159.053.331.053.49 0 2.86-.942 5.005-4.017 5.005-7.33V7.21L12 4.824 6.75 7.21Z"})),search:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"M17.5 11.5a4 4 0 1 1-8 0 4 4 0 0 1 8 0Zm1.5 0a5.5 5.5 0 0 1-9.142 4.121l-3.364 2.943-.988-1.128 3.373-2.952A5.5 5.5 0 1 1 19 11.5Z"})),social:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{d:"M15.5 3.97809V18.0219L7.5 15.5977V20H6V15.1431L3.27498 14.3173C2.22086 13.9979 1.5 13.0262 1.5 11.9248V10.0752C1.5 8.97375 2.22087 8.00207 3.27498 7.68264L15.5 3.97809ZM14 16L7.5 14.0303L7.5 7.96969L14 5.99999V16ZM6 8.42423L6 13.5757L3.70999 12.8818C3.28835 12.754 3 12.3654 3 11.9248V10.0752C3 9.63462 3.28835 9.24595 3.70999 9.11818L6 8.42423ZM17.5 11.75H21.5V10.25H17.5V11.75ZM21.5 16L17.5 15V13.5L21.5 14.5V16ZM17.5 8.5L21.5 7.5V6L17.5 7V8.5Z"})),star:({size:e,className:t=i.A["star-icon"],color:a})=>React.createElement(o,{className:t,size:e,color:a},React.createElement(c.Path,{d:"M12 2l2.582 6.953L22 9.257l-5.822 4.602L18.18 21 12 16.89 5.82 21l2.002-7.14L2 9.256l7.418-.304"})),videopress:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M4.3,6.2c0.8,0,1.6,0.6,1.8,1.4l2.3,7.9c0,0,0,0,0,0l2.7-9.3h1.5h4.2c2.9,0,4.9,1.9,4.9,4.7c0,2.9-2,4.7-5,4.7 h-2h-2.5l-0.5,1.5c-0.4,1.4-1.7,2.3-3.2,2.3c-1.4,0-2.7-0.9-3.2-2.3L2.5,8.7C2.1,7.4,3,6.2,4.3,6.2z M13,12.8h2.9c1.3,0,2-0.7,2-1.9 c0-1.2-0.8-1.8-2-1.8h-1.7L13,12.8z"})),jetpack:({size:e,className:t=i.A.jetpack,color:a})=>React.createElement(o,{className:t,size:e,color:a,viewBox:"0 0 32 32"},React.createElement(c.Path,{className:"jetpack-logo__icon-circle",d:"M16,0C7.2,0,0,7.2,0,16s7.2,16,16,16s16-7.2,16-16S24.8,0,16,0z"}),React.createElement(c.Polygon,{fill:"#fff",points:"15,19 7,19 15,3"}),React.createElement(c.Polygon,{fill:"#fff",points:"17,29 17,13 25,13"})),share:({size:e=16,className:t,color:a})=>React.createElement(o,{className:t,size:e,color:a,viewBox:"0 0 16 16"},React.createElement(c.Path,{fill:"#161722",fillRule:"evenodd",d:"M8.3 4.66C3.85 5.308.727 9.75.034 13.69l-.02.117c-.137.842.809 1.232 1.446.68 2.013-1.745 3.648-2.475 5.318-2.719a10.482 10.482 0 011.524-.103v2.792c0 .694.82 1.041 1.3.55l6.176-6.307a.79.79 0 00.012-1.088L9.614 1.004C9.14.496 8.301.84 8.301 1.542v3.117zm1.525-1.175v1.85a.773.773 0 01-.654.77l-.655.096c-2.133.311-3.987 1.732-5.295 3.672-.472.7-.854 1.44-1.143 2.18a12.32 12.32 0 011.675-.972c1.58-.75 3.048-.972 4.548-.972h.762a.77.77 0 01.762.779v1.69l4.347-4.44-4.347-4.653z",clipRule:"evenodd"})),ai:({size:e=24,color:t="#069e08"})=>React.createElement(o,{color:t,size:e,viewBox:"0 0 32 32"},React.createElement(c.Path,{className:"spark-first",d:"M9.33301 5.33325L10.4644 8.20188L13.333 9.33325L10.4644 10.4646L9.33301 13.3333L8.20164 10.4646L5.33301 9.33325L8.20164 8.20188L9.33301 5.33325Z"}),React.createElement(c.Path,{className:"spark-second",d:"M21.3333 5.33333L22.8418 9.15817L26.6667 10.6667L22.8418 12.1752L21.3333 16L19.8248 12.1752L16 10.6667L19.8248 9.15817L21.3333 5.33333Z"}),React.createElement(c.Path,{className:"spark-third",d:"M14.6667 13.3333L16.5523 18.1144L21.3333 20L16.5523 21.8856L14.6667 26.6667L12.781 21.8856L8 20L12.781 18.1144L14.6667 13.3333Z"})),stats:({opacity:e=1,size:t,color:a})=>React.createElement(o,{size:t,opacity:e,color:a},React.createElement(c.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M11.25 5H12.75V20H11.25V5ZM6 10H7.5V20H6V10ZM18 14H16.5V20H18V14Z"}))}};function u(e){return l[e]?l[e]:null}},8250:(e,t,a)=>{"use strict";a.d(t,{A:()=>y});var n=a(6072),r=a.n(n),c=a(7723),s=a(1113),i=a(3512),o=a(3022),l=a(1609),u=a.n(l),d=a(3924),p=a(1069),m=a(8907),h=(a(4206),a(7142)),g=a(442);const __=c.__,_x=c._x,v=()=>u().createElement(h.A,{logoColor:"#000",showText:!1,height:16,"aria-hidden":"true"}),f=()=>u().createElement(u().Fragment,null,u().createElement(s.A,{icon:i.A,size:16}),u().createElement("span",{className:"jp-dashboard-footer__accessible-external-link"},/* translators: accessibility text */ -__("(opens in a new tab)","jetpack-protect"))),y=({moduleName:e=__("Jetpack","jetpack-protect"),className:t,moduleNameHref:a="https://jetpack.com",menu:n,useInternalLinks:c,onAboutClick:s,onPrivacyClick:i,onTermsClick:l,...h})=>{const[y]=(0,g.A)("sm","<="),[E]=(0,g.A)("md","<="),[A]=(0,g.A)("lg",">"),b=(0,p.A)();let w=[{label:_x("About","Link to learn more about Jetpack.","jetpack-protect"),title:__("About Jetpack","jetpack-protect"),href:c?new URL("admin.php?page=jetpack_about",b).href:(0,d.A)("jetpack-about"),target:c?"_self":"_blank",onClick:s},{label:_x("Privacy","Shorthand for Privacy Policy.","jetpack-protect"),title:__("Automattic's Privacy Policy","jetpack-protect"),href:c?new URL("admin.php?page=jetpack#/privacy",b).href:(0,d.A)("a8c-privacy"),target:c?"_self":"_blank",onClick:i},{label:_x("Terms","Shorthand for Terms of Service.","jetpack-protect"),title:__("WordPress.com Terms of Service","jetpack-protect"),href:(0,d.A)("wpcom-tos"),target:"_blank",onClick:l}];n&&(w=[...w,...n]);const k=u().createElement(u().Fragment,null,u().createElement(v,null),e);return u().createElement("footer",r()({className:(0,o.A)("jp-dashboard-footer",{"is-sm":y,"is-md":E,"is-lg":A},t),"aria-label":__("Jetpack","jetpack-protect"),role:"contentinfo"},h),u().createElement("ul",null,u().createElement("li",{className:"jp-dashboard-footer__jp-item"},a?u().createElement("a",{href:a},k):k),w.map((e=>{const t="button"===e.role,a=!t&&"_blank"===e.target;return u().createElement("li",{key:e.label},u().createElement("a",{href:e.href,title:e.title,target:e.target,onClick:e.onClick,onKeyDown:e.onKeyDown,className:(0,o.A)("jp-dashboard-footer__menu-item",{"is-external":a}),role:e.role,rel:a?"noopener noreferrer":void 0,tabIndex:t?0:void 0},e.label,a&&u().createElement(f,null)))})),u().createElement("li",{className:"jp-dashboard-footer__a8c-item"},u().createElement("a",{href:c?new URL("admin.php?page=jetpack_about",b).href:(0,d.A)("a8c-about"),"aria-label":__("An Automattic Airline","jetpack-protect")},u().createElement(m.A,{"aria-hidden":"true"})))))}},7142:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(6072),r=a.n(n),c=a(7723),s=a(3022),i=a(1609),o=a.n(i);const __=c.__,l=({logoColor:e="#069e08",showText:t=!0,className:a,height:n=32,...c})=>{const i=t?"0 0 118 32":"0 0 32 32";return o().createElement("svg",r()({xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:i,className:(0,s.A)("jetpack-logo",a),"aria-labelledby":"jetpack-logo-title",height:n},c,{role:"img"}),o().createElement("title",{id:"jetpack-logo-title"},__("Jetpack Logo","jetpack-protect")),o().createElement("path",{fill:e,d:"M16,0C7.2,0,0,7.2,0,16s7.2,16,16,16s16-7.2,16-16S24.8,0,16,0z M15,19H7l8-16V19z M17,29V13h8L17,29z"}),t&&o().createElement(o().Fragment,null,o().createElement("path",{d:"M41.3,26.6c-0.5-0.7-0.9-1.4-1.3-2.1c2.3-1.4,3-2.5,3-4.6V8h-3V6h6v13.4C46,22.8,45,24.8,41.3,26.6z"}),o().createElement("path",{d:"M65,18.4c0,1.1,0.8,1.3,1.4,1.3c0.5,0,2-0.2,2.6-0.4v2.1c-0.9,0.3-2.5,0.5-3.7,0.5c-1.5,0-3.2-0.5-3.2-3.1V12H60v-2h2.1V7.1 H65V10h4v2h-4V18.4z"}),o().createElement("path",{d:"M71,10h3v1.3c1.1-0.8,1.9-1.3,3.3-1.3c2.5,0,4.5,1.8,4.5,5.6s-2.2,6.3-5.8,6.3c-0.9,0-1.3-0.1-2-0.3V28h-3V10z M76.5,12.3 c-0.8,0-1.6,0.4-2.5,1.2v5.9c0.6,0.1,0.9,0.2,1.8,0.2c2,0,3.2-1.3,3.2-3.9C79,13.4,78.1,12.3,76.5,12.3z"}),o().createElement("path",{d:"M93,22h-3v-1.5c-0.9,0.7-1.9,1.5-3.5,1.5c-1.5,0-3.1-1.1-3.1-3.2c0-2.9,2.5-3.4,4.2-3.7l2.4-0.3v-0.3c0-1.5-0.5-2.3-2-2.3 c-0.7,0-2.3,0.5-3.7,1.1L84,11c1.2-0.4,3-1,4.4-1c2.7,0,4.6,1.4,4.6,4.7L93,22z M90,16.4l-2.2,0.4c-0.7,0.1-1.4,0.5-1.4,1.6 c0,0.9,0.5,1.4,1.3,1.4s1.5-0.5,2.3-1V16.4z"}),o().createElement("path",{d:"M104.5,21.3c-1.1,0.4-2.2,0.6-3.5,0.6c-4.2,0-5.9-2.4-5.9-5.9c0-3.7,2.3-6,6.1-6c1.4,0,2.3,0.2,3.2,0.5V13 c-0.8-0.3-2-0.6-3.2-0.6c-1.7,0-3.2,0.9-3.2,3.6c0,2.9,1.5,3.8,3.3,3.8c0.9,0,1.9-0.2,3.2-0.7V21.3z"}),o().createElement("path",{d:"M110,15.2c0.2-0.3,0.2-0.8,3.8-5.2h3.7l-4.6,5.7l5,6.3h-3.7l-4.2-5.8V22h-3V6h3V15.2z"}),o().createElement("path",{d:"M58.5,21.3c-1.5,0.5-2.7,0.6-4.2,0.6c-3.6,0-5.8-1.8-5.8-6c0-3.1,1.9-5.9,5.5-5.9s4.9,2.5,4.9,4.9c0,0.8,0,1.5-0.1,2h-7.3 c0.1,2.5,1.5,2.8,3.6,2.8c1.1,0,2.2-0.3,3.4-0.7C58.5,19,58.5,21.3,58.5,21.3z M56,15c0-1.4-0.5-2.9-2-2.9c-1.4,0-2.3,1.3-2.4,2.9 C51.6,15,56,15,56,15z"})))}},1608:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(6072),r=a.n(n),c=a(7723),s=a(3022),i=a(1609),o=a.n(i);const __=c.__,l=({logoColor:e="#069e08",showText:t=!0,className:a,height:n=42,...c})=>{const i=t?"0 0 245 41":"0 0 41 41";return o().createElement("svg",r()({xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:i,className:(0,s.A)("jetpack-logo",a),"aria-labelledby":"jetpack-logo-title",height:n},c,{role:"img"}),o().createElement("title",{id:"jetpack-logo-title"},__("Jetpack Protect Logo","jetpack-protect")),o().createElement("path",{d:"M20.1063 40.2111C31.2106 40.2111 40.2126 31.2091 40.2126 20.1048C40.2126 9.00048 31.2106 0 20.1063 0C9.00197 0 0 9.00197 0 20.1063C0 31.2106 9.00197 40.2111 20.1063 40.2111Z",fill:e}),o().createElement("path",{d:"M21.104 16.7295V36.2209L31.1571 16.7295H21.104Z",fill:"white"}),o().createElement("path",{d:"M19.0701 23.4444V3.99023L9.05566 23.4444H19.0701Z",fill:"white"}),t&&o().createElement(o().Fragment,null,o().createElement("path",{d:"M159.347 27.3605H156.978V7.9082H162.371C163.176 7.9082 163.917 7.95666 164.596 8.05359C165.284 8.15051 165.914 8.30074 166.486 8.50428C167.649 8.92104 168.531 9.54619 169.132 10.3797C169.733 11.2036 170.033 12.2213 170.033 13.4328C170.033 14.4214 169.834 15.2937 169.437 16.0497C169.049 16.796 168.482 17.4211 167.736 17.9251C166.99 18.4291 166.079 18.812 165.003 19.0737C163.937 19.3257 162.725 19.4517 161.368 19.4517C160.719 19.4517 160.045 19.4226 159.347 19.3644V27.3605ZM159.347 17.1982C159.667 17.237 160.002 17.2661 160.35 17.2854C160.699 17.3048 161.029 17.3145 161.339 17.3145C162.454 17.3145 163.403 17.2273 164.189 17.0528C164.974 16.8784 165.613 16.6264 166.108 16.2968C166.602 15.9576 166.961 15.5505 167.183 15.0756C167.406 14.591 167.518 14.0434 167.518 13.4328C167.518 12.6768 167.334 12.0565 166.965 11.5719C166.607 11.0873 166.093 10.719 165.424 10.467C165.008 10.3119 164.528 10.2053 163.985 10.1471C163.442 10.0793 162.812 10.0453 162.095 10.0453H159.347V17.1982Z"}),o().createElement("path",{d:"M181.093 15.3809H180.919C180.386 15.3809 179.862 15.4294 179.349 15.5263C178.835 15.6232 178.35 15.7735 177.895 15.977C177.449 16.1708 177.042 16.4131 176.674 16.7039C176.315 16.9947 176.014 17.3388 175.772 17.7361V27.3605H173.519V13.5491H175.263L175.699 15.7444H175.743C175.966 15.3858 176.237 15.0514 176.557 14.7412C176.887 14.4311 177.255 14.1597 177.662 13.9271C178.069 13.6945 178.515 13.5152 179 13.3892C179.484 13.2535 179.993 13.1856 180.526 13.1856C180.623 13.1856 180.72 13.1905 180.817 13.2002C180.924 13.2002 181.016 13.205 181.093 13.2147V15.3809Z"}),o().createElement("path",{d:"M193.302 20.4694C193.302 19.6164 193.195 18.8604 192.982 18.2014C192.779 17.5326 192.488 16.9705 192.11 16.5149C191.741 16.0497 191.3 15.7008 190.787 15.4682C190.273 15.2258 189.711 15.1047 189.1 15.1047C188.49 15.1047 187.928 15.2258 187.414 15.4682C186.9 15.7008 186.454 16.0497 186.076 16.5149C185.708 16.9705 185.417 17.5326 185.204 18.2014C185.001 18.8604 184.899 19.6164 184.899 20.4694C184.899 21.3126 185.001 22.0686 185.204 22.7373C185.417 23.3964 185.713 23.9537 186.091 24.4092C186.469 24.8648 186.915 25.2137 187.428 25.456C187.942 25.6886 188.504 25.8049 189.115 25.8049C189.725 25.8049 190.283 25.6886 190.787 25.456C191.3 25.2137 191.741 24.8648 192.11 24.4092C192.488 23.9537 192.779 23.3964 192.982 22.7373C193.195 22.0686 193.302 21.3126 193.302 20.4694ZM195.657 20.4694C195.657 21.5549 195.502 22.5435 195.192 23.4352C194.882 24.3269 194.441 25.0926 193.869 25.7322C193.307 26.3622 192.623 26.8517 191.819 27.2006C191.015 27.5495 190.113 27.724 189.115 27.724C188.088 27.724 187.167 27.5495 186.353 27.2006C185.548 26.8517 184.86 26.3622 184.288 25.7322C183.726 25.0926 183.295 24.3269 182.994 23.4352C182.694 22.5435 182.544 21.5549 182.544 20.4694C182.544 19.3741 182.699 18.3807 183.009 17.489C183.319 16.5973 183.755 15.8316 184.317 15.1919C184.889 14.5522 185.577 14.0579 186.382 13.709C187.196 13.3601 188.102 13.1856 189.1 13.1856C190.118 13.1856 191.034 13.3601 191.848 13.709C192.662 14.0579 193.35 14.5522 193.913 15.1919C194.475 15.8316 194.906 16.5973 195.206 17.489C195.507 18.3807 195.657 19.3741 195.657 20.4694Z"}),o().createElement("path",{d:"M206.354 27.3896C206.16 27.4672 205.864 27.5398 205.467 27.6077C205.07 27.6755 204.595 27.7143 204.042 27.724C203.315 27.724 202.685 27.6319 202.152 27.4478C201.619 27.2733 201.173 27.0213 200.815 26.6918C200.466 26.3525 200.204 25.9455 200.03 25.4705C199.855 24.9956 199.768 24.4674 199.768 23.8859V15.4827H197.107V13.5491H199.768V9.76911H202.021V13.5491H206.15V15.4827H202.021V23.5369C202.021 23.8568 202.065 24.1524 202.152 24.4238C202.249 24.6952 202.395 24.9326 202.588 25.1362C202.792 25.33 203.049 25.4851 203.359 25.6014C203.669 25.708 204.042 25.7613 204.478 25.7613C204.779 25.7613 205.094 25.7371 205.423 25.6886C205.763 25.6402 206.073 25.5772 206.354 25.4996V27.3896Z"}),o().createElement("path",{d:"M214.681 15.1192C214.167 15.1192 213.687 15.221 213.242 15.4245C212.805 15.6281 212.423 15.9043 212.093 16.2532C211.764 16.6021 211.497 17.0141 211.293 17.489C211.09 17.9542 210.964 18.4534 210.915 18.9864H217.894C217.894 18.4437 217.821 17.9397 217.676 17.4744C217.54 16.9995 217.337 16.5876 217.065 16.2387C216.794 15.8898 216.459 15.6184 216.062 15.4245C215.665 15.221 215.204 15.1192 214.681 15.1192ZM215.917 25.7613C216.663 25.7613 217.341 25.7032 217.952 25.5869C218.572 25.4609 219.188 25.2864 219.798 25.0635V26.9389C219.304 27.1812 218.693 27.3702 217.967 27.5059C217.24 27.6513 216.459 27.724 215.626 27.724C214.637 27.724 213.707 27.598 212.835 27.346C211.972 27.094 211.216 26.6869 210.567 26.1248C209.917 25.5626 209.403 24.8309 209.025 23.9295C208.657 23.0184 208.473 21.9232 208.473 20.6438C208.473 19.3838 208.647 18.2934 208.996 17.3727C209.345 16.4422 209.811 15.6668 210.392 15.0465C210.974 14.4262 211.642 13.961 212.398 13.6509C213.154 13.3407 213.944 13.1856 214.768 13.1856C215.544 13.1856 216.266 13.3165 216.934 13.5782C217.613 13.8302 218.199 14.2324 218.693 14.7849C219.188 15.3373 219.575 16.0497 219.857 16.922C220.147 17.7943 220.293 18.8411 220.293 20.0623C220.293 20.1786 220.293 20.2804 220.293 20.3676C220.293 20.4451 220.288 20.6293 220.278 20.92H210.799C210.799 21.802 210.93 22.5532 211.192 23.1735C211.463 23.7841 211.827 24.2832 212.282 24.6709C212.747 25.0489 213.29 25.3252 213.91 25.4996C214.531 25.6741 215.199 25.7613 215.917 25.7613Z"}),o().createElement("path",{d:"M229.885 13.1856C230.553 13.1856 231.193 13.2583 231.804 13.4037C232.414 13.5394 232.938 13.7332 233.374 13.9852V15.8607C232.763 15.6281 232.201 15.4536 231.687 15.3373C231.174 15.221 230.65 15.1628 230.117 15.1628C229.555 15.1628 228.998 15.2549 228.445 15.4391C227.893 15.6232 227.398 15.9285 226.962 16.355C226.526 16.7718 226.172 17.3291 225.901 18.0269C225.639 18.7151 225.508 19.5728 225.508 20.6002C225.508 21.3465 225.605 22.0346 225.799 22.6646C226.003 23.2946 226.298 23.8423 226.686 24.3075C227.083 24.763 227.578 25.1216 228.169 25.3833C228.76 25.6353 229.444 25.7613 230.219 25.7613C230.781 25.7613 231.348 25.7032 231.92 25.5869C232.492 25.4609 233.049 25.2864 233.592 25.0635V26.9389C233.427 27.0358 233.209 27.1328 232.938 27.2297C232.676 27.3266 232.385 27.409 232.065 27.4768C231.745 27.5544 231.406 27.6125 231.048 27.6513C230.689 27.6998 230.33 27.724 229.972 27.724C229.041 27.724 228.159 27.5835 227.326 27.3024C226.502 27.0213 225.78 26.59 225.16 26.0085C224.539 25.4269 224.05 24.6903 223.691 23.7986C223.333 22.907 223.153 21.8505 223.153 20.6293C223.153 19.7182 223.245 18.8992 223.429 18.1723C223.623 17.4454 223.885 16.8057 224.215 16.2532C224.544 15.7008 224.927 15.2307 225.363 14.843C225.809 14.4553 226.279 14.1403 226.773 13.898C227.277 13.646 227.796 13.4667 228.329 13.3601C228.862 13.2438 229.381 13.1856 229.885 13.1856Z"}),o().createElement("path",{d:"M244.143 27.3896C243.949 27.4672 243.654 27.5398 243.256 27.6077C242.859 27.6755 242.384 27.7143 241.832 27.724C241.105 27.724 240.475 27.6319 239.942 27.4478C239.409 27.2733 238.963 27.0213 238.604 26.6918C238.255 26.3525 237.993 25.9455 237.819 25.4705C237.645 24.9956 237.557 24.4674 237.557 23.8859V15.4827H234.897V13.5491H237.557V9.76911H239.811V13.5491H243.94V15.4827H239.811V23.5369C239.811 23.8568 239.854 24.1524 239.942 24.4238C240.039 24.6952 240.184 24.9326 240.378 25.1362C240.581 25.33 240.838 25.4851 241.148 25.6014C241.458 25.708 241.832 25.7613 242.268 25.7613C242.568 25.7613 242.883 25.7371 243.213 25.6886C243.552 25.6402 243.862 25.5772 244.143 25.4996V27.3896Z"}),o().createElement("path",{d:"M51.9141 33.3819C51.3379 32.499 50.8019 31.6176 50.2644 30.7733C53.1038 29.0462 54.0626 27.666 54.0626 25.0559V9.97619H50.7245V7.09961H57.8236V24.2891C57.8236 28.6635 56.558 31.1188 51.9141 33.3819Z"}),o().createElement("path",{d:"M81.6522 23.0994C81.6522 24.557 82.6885 24.7104 83.3793 24.7104C84.0702 24.7104 85.0677 24.4796 85.8345 24.2503V26.9363C84.7595 27.2817 83.6473 27.5497 82.1122 27.5497C80.2705 27.5497 78.122 26.8589 78.122 23.6354V15.7307H76.1655V13.006H78.122V8.97852H81.6522V13.0075H86.1025V15.7322H81.6522V23.0994Z"}),o().createElement("path",{d:"M89.0193 34.7251V12.9691H92.3961V14.2734C93.7391 13.2371 95.2355 12.585 97.0773 12.585C100.262 12.585 102.795 14.8109 102.795 19.6067C102.795 24.3652 100.033 27.5113 95.4663 27.5113C94.3541 27.5113 93.4711 27.358 92.5495 27.1659V34.6864H89.0193V34.7251ZM96.1557 15.5017C95.1194 15.5017 93.8151 16.0005 92.5867 17.0755V24.4814C93.3535 24.6347 94.1605 24.7494 95.234 24.7494C97.7279 24.7494 99.1484 23.1756 99.1484 19.8762C99.1484 16.8447 98.1121 15.5017 96.1557 15.5017Z"}),o().createElement("path",{d:"M116.683 27.2051H113.384V25.6313H113.306C112.155 26.5142 110.735 27.4731 108.625 27.4731C106.783 27.4731 104.788 26.1301 104.788 23.4054C104.788 19.7605 107.896 19.0696 110.083 18.7629L113.19 18.3416V17.9202C113.19 16.001 112.423 15.3876 110.619 15.3876C109.736 15.3876 107.665 15.6556 105.976 16.3464L105.67 13.5071C107.205 12.9696 109.315 12.5869 111.08 12.5869C114.533 12.5869 116.759 13.9686 116.759 18.0736V27.2051H116.683ZM113.153 20.5675L110.236 21.0276C109.353 21.1422 108.433 21.6797 108.433 22.984C108.433 24.1349 109.085 24.7871 110.044 24.7871C111.08 24.7871 112.193 24.1736 113.152 23.4828V20.5675H113.153Z"}),o().createElement("path",{d:"M131.264 26.745C129.806 27.2438 128.502 27.5505 126.851 27.5505C121.556 27.5505 119.445 24.5191 119.445 20.1074C119.445 15.465 122.362 12.5869 127.08 12.5869C128.845 12.5869 129.92 12.8936 131.109 13.2778V16.2705C130.073 15.8863 128.577 15.465 127.119 15.465C124.97 15.465 123.129 16.6159 123.129 19.9153C123.129 23.5602 124.97 24.6739 127.311 24.6739C128.423 24.6739 129.652 24.4431 131.301 23.791V26.745H131.264Z"}),o().createElement("path",{d:"M137.941 19.1093C138.247 18.7639 138.478 18.4185 142.928 13.0077H147.532L141.776 19.7615L148.068 27.2432H143.464L137.978 20.4895V27.2432H134.449V7.09973H137.979V19.1093H137.941Z"}),o().createElement("path",{d:"M73.5167 26.7445C71.6749 27.3207 70.1011 27.55 68.2593 27.55C63.7316 27.55 60.9309 25.2869 60.9309 19.9908C60.9309 16.1152 63.3102 12.585 67.8752 12.585C72.403 12.585 73.9768 15.731 73.9768 18.7238C73.9768 19.7213 73.8993 20.2588 73.8621 20.8335H64.7306C64.808 23.9409 66.5724 24.6705 69.2197 24.6705C70.6773 24.6705 71.9816 24.325 73.4795 23.7875V26.7416H73.5167V26.7445ZM70.2947 18.4945C70.2947 16.7673 69.7185 15.271 67.8395 15.271C66.0751 15.271 65.0001 16.5365 64.7693 18.4945H70.2947Z"})))}},8509:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(3022),r=a(1609),c=a(7371);const s=Number(c.A.smCols),i=Number(c.A.mdCols),o=Number(c.A.lgCols),l=e=>{const{children:t,tagName:a="div",className:l}=e,u=Math.min(s,"number"==typeof e.sm?e.sm:s),d=Math.min(s,"object"==typeof e.sm?e.sm.start:0),p=Math.min(s,"object"==typeof e.sm?e.sm.end:0),m=Math.min(i,"number"==typeof e.md?e.md:i),h=Math.min(i,"object"==typeof e.md?e.md.start:0),g=Math.min(i,"object"==typeof e.md?e.md.end:0),v=Math.min(o,"number"==typeof e.lg?e.lg:o),f=Math.min(o,"object"==typeof e.lg?e.lg.start:0),y=Math.min(o,"object"==typeof e.lg?e.lg.end:0),E=(0,n.A)(l,{[c.A[`col-sm-${u}`]]:!(d&&p),[c.A[`col-sm-${d}-start`]]:d>0,[c.A[`col-sm-${p}-end`]]:p>0,[c.A[`col-md-${m}`]]:!(h&&g),[c.A[`col-md-${h}-start`]]:h>0,[c.A[`col-md-${g}-end`]]:g>0,[c.A[`col-lg-${v}`]]:!(f&&y),[c.A[`col-lg-${f}-start`]]:f>0,[c.A[`col-lg-${y}-end`]]:y>0});return(0,r.createElement)(a,{className:E},t)}},5918:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(3022),r=a(1609),c=a(2420);const s=({children:e,fluid:t=!1,tagName:a="div",className:s,horizontalGap:i=1,horizontalSpacing:o=1},l)=>{const u=(0,r.useMemo)((()=>{const e=`calc( var(--horizontal-spacing) * ${o} )`;return{paddingTop:e,paddingBottom:e,rowGap:`calc( var(--horizontal-spacing) * ${i} )`}}),[i,o]),d=(0,n.A)(s,c.A.container,{[c.A.fluid]:t});return(0,r.createElement)(a,{className:d,style:u,ref:l},e)},i=(0,r.forwardRef)(s)},442:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var n=a(9491),r=a(8403);const c=["sm","md","lg"],s=(e,t)=>{const a=Array.isArray(e)?e:[e],s=Array.isArray(t)?t:[t],[i,o,l]=c,u={sm:(0,n.useMediaQuery)(r.A[i]),md:(0,n.useMediaQuery)(r.A[o]),lg:(0,n.useMediaQuery)(r.A[l])};return a.map(((e,t)=>{const a=s[t];return a?((e,t,a)=>{const n=c.indexOf(e),r=n+1,s=t.includes("=");let i=[];return t.startsWith("<")&&(i=c.slice(0,s?r:n)),t.startsWith(">")&&(i=c.slice(s?n:r)),i?.length?i.some((e=>a[e])):a[e]})(e,a,u):u[e]}))}},5734:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(5531);const r=e=>React.createElement("mark",{key:e,className:n.A["marked-lines__mark"]},e),c=({context:e})=>{const{marks:t,...a}=e;return React.createElement("div",{className:n.A["marked-lines"]},React.createElement("div",{className:n.A["marked-lines__line-numbers"]},Object.keys(a).map((e=>{const a=Object.hasOwn(t,e);return React.createElement("div",{key:e,className:`${n.A["marked-lines__line-number"]} ${a?n.A["marked-lines__marked-line"]:""}`},e)}))),React.createElement("div",{className:n.A["marked-lines__lines"]},Object.keys(a).map((e=>{const c=a[e]||" ",s=Object.hasOwn(t,e);return React.createElement("div",{key:e,className:`${n.A["marked-lines__line"]} ${s?n.A["marked-lines__marked-line"]:""} `},React.createElement(React.Fragment,null,s?((e,t)=>{const[a,n]=e.reduce((([e,a],[n,c])=>{const s=t.slice(n,c);return[[...e,...n>a?[t.slice(a,n),r(s)]:[r(s)]],c]}),[[],0]);return n{"use strict";a.d(t,{A:()=>m});var n=a(3751),r=a(9783),c=a(3883),s=a(1113),i=a(991),o=a(3022),l=a(1609),u=a.n(l),d=a(7410);const p=e=>{switch(e){case"error":case"warning":default:return n.A;case"info":return r.A;case"success":return c.A}},m=({level:e="info",title:t,children:a,actions:n,hideCloseButton:r=!1,onClose:c})=>{const l=(0,o.A)(d.A.container,d.A[`is-${e}`]);return u().createElement("div",{className:l},u().createElement("div",{className:d.A["icon-wrapper"]},u().createElement(s.A,{icon:p(e),className:d.A.icon})),u().createElement("div",{className:d.A["main-content"]},t&&u().createElement("div",{className:d.A.title},t),a,n&&n.length>0&&u().createElement("div",{className:d.A["action-bar"]},n.map(((e,t)=>u().createElement("div",{key:t,className:d.A.action},e))))),!r&&u().createElement("button",{"aria-label":"close",className:d.A["close-button"],onClick:c},u().createElement(s.A,{icon:i.A})))}},7975:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});var n=a(1437);const r=(e,t={})=>{const a=(0,n.Y)();return new Intl.NumberFormat(a,t).format(e)}},9245:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>w,N0:()=>b,eY:()=>E,i7:()=>A});var n=a(7723),r=a(1113),c=a(3883),s=a(1249),i=a(3022),o=a(1609),l=a.n(o),u=a(597),d=a(442),p=a(5879),m=a(7425),h=a(3142);const __=n.__,g=__("Included","jetpack-protect"),v=__("Not included","jetpack-protect"),f=__("Coming soon","jetpack-protect"),y=(0,o.createContext)(void 0),E=({isIncluded:e=!1,isComingSoon:t=!1,index:a=0,label:p=null,tooltipInfo:E,tooltipTitle:A,tooltipClassName:b=""})=>{const[w]=(0,d.A)("lg"),k=(0,o.useContext)(y)[a],R=t||e,C=k.name,_=k.tooltipInfo,j=k.tooltipTitle,x=E||!w&&_,S=((e,t,a)=>e?{lg:f, -// translators: Name of the current feature -default:(0,n.sprintf)(__("%s coming soon","jetpack-protect"),a)}:{lg:t?g:v,default:t?a:(0,n.sprintf)(/* translators: Name of the current feature */ -__("%s not included","jetpack-protect"),a)})(t,e,C),M=w?S.lg:S.default;return l().createElement("div",{className:(0,i.A)(h.A.item,h.A.value)},l().createElement(r.A,{className:(0,i.A)(h.A.icon,R?h.A["icon-check"]:h.A["icon-cross"]),size:32,icon:R?c.A:s.A}),l().createElement(m.Ay,{variant:"body-small"},p||M),x&&l().createElement(u.A,{title:A||j,iconClassName:h.A["popover-icon"],className:(0,i.A)(h.A.popover,b),placement:"bottom-end",iconSize:14,offset:4,wide:Boolean(A&&E)},l().createElement(m.Ay,{variant:"body-small",component:"div"},E||_)))},A=({children:e})=>l().createElement("div",{className:h.A.header},e),b=({primary:e=!1,children:t})=>{let a=0;return l().createElement("div",{className:(0,i.A)(h.A.card,{[h.A["is-primary"]]:e})},o.Children.map(t,(e=>{const t=e;return t.type===E?(a++,(0,o.cloneElement)(t,{index:a-1})):t})))},w=({title:e,items:t,children:a,showIntroOfferDisclaimer:n=!1})=>{const[r]=(0,d.A)("lg");return l().createElement(y.Provider,{value:t},l().createElement("div",{className:(0,i.A)(h.A.container,{[h.A["is-viewport-large"]]:r}),style:{"--rows":t.length+1,"--columns":o.Children.toArray(a).length+1}},l().createElement("div",{className:h.A.table},l().createElement(m.Ay,{variant:"headline-small"},e),r&&t.map(((e,a)=>l().createElement("div",{className:(0,i.A)(h.A.item,{[h.A["last-feature"]]:a===t.length-1}),key:a},l().createElement(m.Ay,{variant:"body-small"},l().createElement("strong",null,e.name)),e.tooltipInfo&&l().createElement(u.A,{title:e.tooltipTitle,iconClassName:h.A["popover-icon"],className:h.A.popover,placement:e.tooltipPlacement?e.tooltipPlacement:"bottom-end",iconSize:14,offset:4,wide:Boolean(e.tooltipTitle&&e.tooltipInfo)},l().createElement(m.Ay,{variant:"body-small"},e.tooltipInfo))))),a)),l().createElement("div",{className:h.A["tos-container"]},l().createElement("div",{className:h.A.tos},n&&l().createElement(m.Ay,{variant:"body-small"},__("Reduced pricing is a limited offer for the first year and renews at regular price.","jetpack-protect")),l().createElement(p.A,{multipleButtons:!0}))))}},489:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(7723),r=a(3022),c=a(7425),s=a(2746),i=a(3407);const __=n.__,o=({price:e,offPrice:t,currency:a="",showNotOffPrice:n=!0,hideDiscountLabel:o=!0,promoLabel:l="",legend:u=__("/month, paid yearly","jetpack-protect"),isNotConvenientPrice:d=!1,hidePriceFraction:p=!1,children:m})=>{if(null==e&&null==t||!a)return null;n=n&&null!=t;const h="number"==typeof e&&"number"==typeof t?Math.floor((e-t)/e*100):0,g=!o&&h&&h>0?h+__("% off","jetpack-protect"):null;return React.createElement(React.Fragment,null,React.createElement("div",{className:i.A.container},React.createElement("div",{className:(0,r.A)(i.A["price-container"],"product-price_container")},React.createElement(s.g,{value:t??e,currency:a,isOff:!d,hidePriceFraction:p}),n&&React.createElement(s.g,{value:e,currency:a,isOff:!1,hidePriceFraction:p}),g&&React.createElement(c.Ay,{className:(0,r.A)(i.A["promo-label"],"product-price_promo_label")},g))),React.createElement("div",{className:i.A.footer},m||React.createElement(c.Ay,{className:(0,r.A)(i.A.legend,"product-price_legend")},u),l&&React.createElement(c.Ay,{className:(0,r.A)(i.A["promo-label"],"product-price_promo_label")},l)))}},2746:(e,t,a)=>{"use strict";a.d(t,{g:()=>i});var n=a(7397),r=a(3022),c=a(7425),s=a(3407);const i=({value:e,currency:t,isOff:a,hidePriceFraction:i})=>{const o=(0,r.A)(s.A.price,"product-price_price",{[s.A["is-not-off-price"]]:!a}),{symbol:l,integer:u,fraction:d}=(0,n.vA)(e,t),p=!i||!d.endsWith("00");return React.createElement(c.Ay,{className:o,variant:"headline-medium",component:"p"},React.createElement(c.Ay,{className:s.A.symbol,component:"sup",variant:"title-medium"},l),u,p&&React.createElement(c.Ay,{component:"sup",variant:"body-small","data-testid":"PriceFraction"},React.createElement("strong",null,d)))}},6461:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(8120),r=a.n(n),c=a(1609),s=a.n(c);a(8325);const i=({color:e="#FFFFFF",className:t="",size:a=20})=>{const n=t+" jp-components-spinner",r={width:a,height:a,fontSize:a,borderTopColor:e},c={borderTopColor:e,borderRightColor:e};return s().createElement("div",{className:n},s().createElement("div",{className:"jp-components-spinner__outer",style:r},s().createElement("div",{className:"jp-components-spinner__inner",style:c})))};i.propTypes={color:r().string,className:r().string,size:r().number};const o=i},3390:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(6427),r=a(3022),c=a(7975),s=a(7425),i=a(9439);const o=({className:e,hideValue:t,icon:a,label:o,value:l,variant:u="square"})=>{const d=(0,c.A)(l),p=(0,c.A)(l,{notation:"compact",compactDisplay:"short"});return React.createElement("div",{className:(0,r.A)(e,i.A.wrapper,i.A[u])},React.createElement("div",{className:(0,r.A)(i.A.icon)},a),React.createElement("div",{className:(0,r.A)(i.A.info)},React.createElement(s.Ay,{className:i.A.label},o),"square"===u?React.createElement(n.Tooltip,{text:d,placement:"top"},React.createElement(s.Ay,{variant:"headline-small",className:(0,r.A)(i.A.value)},t?"-":p)):React.createElement(s.Ay,{variant:"title-medium-semi-bold",className:(0,r.A)(i.A.value)},t?"-":d)))}},1158:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(7723),r=a(3022),c=a(7425),s=a(416);const __=n.__,i=({className:e,label:t,status:a="inactive"})=>{const n={active:__("Active","jetpack-protect"),error:__("Error","jetpack-protect"),action:__("Action needed","jetpack-protect"),inactive:__("Inactive","jetpack-protect"),initializing:__("Setting up","jetpack-protect")};return React.createElement(c.Ay,{variant:"body-extra-small",className:(0,r.A)(s.A.status,{[s.A[`is-${a}`]]:a},e)},React.createElement("span",{className:s.A.status__indicator}),React.createElement("span",{className:s.A.status__label},t||""===t?t:n[a]))}},5879:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(6072),r=a.n(n),c=a(6087),s=a(7723),i=a(3022),o=a(3924),l=a(7425);a(9634);const __=s.__,u=({multipleButtonsLabels:e})=>Array.isArray(e)&&e.length>1?(0,c.createInterpolateElement)((0,s.sprintf)(/* translators: %1$s is button label 1 and %2$s is button label 2 */ -__("By clicking %1$s or %2$s, you agree to our Terms of Service and to sync your site‘s data with us.","jetpack-protect"),e[0],e[1]),{strong:React.createElement("strong",null),tosLink:React.createElement(m,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(m,{slug:"jetpack-support-what-data-does-jetpack-sync"})}):(0,c.createInterpolateElement)(__("By clicking the buttons above, you agree to our Terms of Service and to sync your site‘s data with us.","jetpack-protect"),{tosLink:React.createElement(m,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(m,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),d=({agreeButtonLabel:e})=>(0,c.createInterpolateElement)((0,s.sprintf)(/* translators: %s is a button label */ -__("By clicking %s, you agree to our Terms of Service and to sync your site‘s data with us.","jetpack-protect"),e),{strong:React.createElement("strong",null),tosLink:React.createElement(m,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(m,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),p=()=>(0,c.createInterpolateElement)(__("By continuing you agree to our Terms of Service and to sync your site’s data with us. We’ll check if that email is linked to an existing WordPress.com account or create a new one instantly.","jetpack-protect"),{tosLink:React.createElement(m,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(m,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),m=({slug:e,children:t})=>React.createElement("a",{className:"terms-of-service__link",href:(0,o.A)(e),rel:"noopener noreferrer",target:"_blank"},t),h=({className:e,multipleButtons:t,agreeButtonLabel:a,isTextOnly:n,...c})=>React.createElement(l.Ay,r()({className:(0,i.A)(e,"terms-of-service")},c),n?React.createElement(p,null):t?React.createElement(u,{multipleButtonsLabels:t}):React.createElement(d,{agreeButtonLabel:a}))},110:(e,t,a)=>{"use strict";a.d(t,{Q:()=>n,Z:()=>r});const n={"headline-medium":"h1","headline-small":"h2","headline-small-regular":"h2","title-medium":"h3","title-medium-semi-bold":"h3","title-small":"h4",body:"p","body-small":"p","body-extra-small":"p","body-extra-small-bold":"p",label:"p"},r=["mt","mr","mb","ml","mx","my","m","pt","pr","pb","pl","px","py","p"]},7425:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>d,H3:()=>p,hE:()=>m});var n=a(6072),r=a.n(n),c=a(3022),s=a(1609),i=a.n(s),o=a(110),l=a(4495);const u=(0,s.forwardRef)((({variant:e="body",children:t,component:a,className:n,...u},d)=>{const p=a||o.Q[e]||"span",m=(0,s.useMemo)((()=>o.Z.reduce(((e,t)=>(void 0!==u[t]&&(e+=l.A[`${t}-${u[t]}`]+" ",delete u[t]),e)),"")),[u]);return i().createElement(p,r()({className:(0,c.A)(l.A.reset,l.A[e],n,m)},u,{ref:d}),t)}));u.displayName="Text";const d=u,p=({children:e,weight:t="bold",...a})=>{const n="headline-small"+("bold"===t?"":`-${t}`);return i().createElement(u,r()({variant:n,mb:3},a),e)},m=({children:e,size:t="medium",...a})=>i().createElement(u,r()({variant:`title-${t}`,mb:1},a),e)},723:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>p});var n=a(1609),r=a.n(n),c=a(9422);const s={"--font-headline-medium":"48px","--font-headline-small":"36px","--font-title-medium":"24px","--font-title-small":"20px","--font-body":"16px","--font-body-small":"14px","--font-body-extra-small":"12px","--font-title-large":"var(--font-headline-small)","--font-label":"var(--font-body-extra-small)"},i={"--jp-black":"#000000","--jp-black-80":"#2c3338","--jp-white":"#ffffff","--jp-white-off":"#f9f9f6","--jp-gray":"#dcdcde","--jp-gray-0":"#F6F7F7","--jp-gray-5":"var(--jp-gray)","--jp-gray-10":"#C3C4C7","--jp-gray-20":"#A7AAAD","--jp-gray-40":"#787C82","--jp-gray-50":"#646970","--jp-gray-60":"#50575E","--jp-gray-70":"#3C434A","--jp-gray-80":"#2C3338","--jp-gray-90":"#1d2327","--jp-gray-off":"#e2e2df","--jp-red-0":"#F7EBEC","--jp-red-5":"#FACFD2","--jp-red-40":"#E65054","--jp-red-50":"#D63638","--jp-red-60":"#B32D2E","--jp-red-70":"#8A2424","--jp-red-80":"#691C1C","--jp-red":"#d63639","--jp-yellow-5":"#F5E6B3","--jp-yellow-10":"#F2CF75","--jp-yellow-20":"#F0C930","--jp-yellow-30":"#DEB100","--jp-yellow-40":"#C08C00","--jp-yellow-50":"#9D6E00","--jp-yellow-60":"#7D5600","--jp-blue-20":"#68B3E8","--jp-blue-40":"#1689DB","--jp-pink":"#C9356E","--jp-green-0":"#f0f2eb","--jp-green-5":"#d0e6b8","--jp-green-10":"#9dd977","--jp-green-20":"#64ca43","--jp-green-30":"#2fb41f","--jp-green-40":"#069e08","--jp-green-50":"#008710","--jp-green-60":"#007117","--jp-green-70":"#005b18","--jp-green-80":"#004515","--jp-green-90":"#003010","--jp-green-100":"#001c09","--jp-green":"#069e08","--jp-green-primary":"var( --jp-green-40 )","--jp-green-secondary":"var( --jp-green-30 )"},o={"--jp-border-radius":"4px","--jp-menu-border-height":"1px","--jp-underline-thickness":"2px"},l={"--spacing-base":"8px"},u={},d=(e,t,a)=>{const n={...s,...i,...o,...l};for(const t in n)e.style.setProperty(t,n[t]);a&&e.classList.add(c.A.global),t&&(u[t]={provided:!0,root:e})},p=({children:e=null,targetDom:t,id:a,withGlobalStyles:c=!0})=>{const s=(0,n.useRef)(),i=u?.[a]?.provided;return(0,n.useLayoutEffect)((()=>{if(!i)return t?d(t,a,c):void(s?.current&&d(s.current,a,c))}),[t,s,i,a,c]),t?r().createElement(r().Fragment,null,e):r().createElement("div",{ref:s},e)}},1014:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(7723),r=a(4105);const _x=n._x,c=({severity:e})=>e>=5?React.createElement(r.A,{variant:"danger"},_x("Critical","Severity label for issues rated 5 or higher.","jetpack-protect")):e>=3&&e<5?React.createElement(r.A,{variant:"warning"},_x("High","Severity label for issues rated between 3 and 5.","jetpack-protect")):React.createElement(r.A,null,_x("Low","Severity label for issues rated below 3.","jetpack-protect"))},8316:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(6427),r=a(3022),c=a(1609),s=a(7021);const i=({checked:e,className:t,disabled:a,help:i,toggling:o,label:l,size:u="normal",onChange:d})=>{const p=void 0!==o?e&&!o||!e&&o:e,m=(0,c.useCallback)((e=>{o||d(e)}),[o,d]);return React.createElement(n.ToggleControl,{__nextHasNoMarginBottom:!0,checked:p,className:(0,r.A)(s.A.toggle,t,{[s.A["is-toggling"]]:o,[s.A["is-small"]]:"small"===u,[s.A["no-label"]]:!l}),disabled:a,help:i,label:l,onChange:m})}},1437:(e,t,a)=>{"use strict";a.d(t,{Y:()=>r});var n=a(8443);const r=()=>{const{l10n:{locale:e}}=(0,n.getSettings)();if(e)return(e=>{const t=e.match(/^([a-z]{2,3})(_[a-z]{2}|_[a-z][a-z0-9]{4,7})?(?:_.*)?$/i);return t?`${t[1]}${t[2]?t[2]:""}`.replace("_","-"):"en-US"})(e);return window?.window?.navigator?.language??"en-US"}},1069:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});var n=a(7999);function r(){return(0,n.getScriptData)()?.site?.admin_url||window.Initial_State?.adminUrl||window.Jetpack_Editor_Initial_State?.adminUrl||window?.myJetpackInitialState?.adminUrl||null}},3924:(e,t,a)=>{"use strict";function n(e,t={}){const a={};let n;if("undefined"!=typeof window&&(n=window?.JP_CONNECTION_INITIAL_STATE?.calypsoEnv),0===e.search("https://")){const t=new URL(e);e=`https://${t.host}${t.pathname}`,a.url=encodeURIComponent(e)}else a.source=encodeURIComponent(e);for(const e in t)a[e]=encodeURIComponent(t[e]);!Object.keys(a).includes("site")&&"undefined"!=typeof jetpack_redirects&&Object.hasOwn(jetpack_redirects,"currentSiteRawUrl")&&(a.site=jetpack_redirects.currentBlogID??jetpack_redirects.currentSiteRawUrl),n&&(a.calypso_env=n);return"https://jetpack.com/redirect/?"+Object.keys(a).map((e=>e+"="+a[e])).join("&")}a.d(t,{A:()=>n})},6439:(e,t,a)=>{let n={};try{n=a(6201)}catch{console.error("jetpackConfig is missing in your webpack config file. See @automattic/jetpack-config"),n={missingConfig:!0}}const r=e=>Object.hasOwn(n,e);e.exports={jetpackConfigHas:r,jetpackConfigGet:e=>{if(!r(e))throw'This app requires the "'+e+'" Jetpack Config to be defined in your webpack configuration file. See details in @automattic/jetpack-config package docs.';return n[e]}}},4705:(e,t,a)=>{"use strict";a(8992),a(1135)},1135:(e,t,a)=>{"use strict";a.d(t,{$:()=>n});const n=[{name:"amazon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M13.582 8.182c-1.648.185-3.802.308-5.344.984-1.781.769-3.03 2.337-3.03 4.644 0 2.953 1.86 4.429 4.253 4.429 2.02 0 3.125-.477 4.685-2.065.516.747.685 1.109 1.629 1.894a.59.59 0 0 0 .672-.066l.006.006c.567-.505 1.599-1.401 2.18-1.888.231-.188.19-.496.009-.754-.52-.718-1.072-1.303-1.072-2.634V8.305c0-1.876.133-3.599-1.249-4.891C15.23 2.369 13.422 2 12.04 2 9.336 2 6.318 3.01 5.686 6.351c-.068.355.191.542.423.594l2.754.298c.258-.013.445-.266.494-.523.236-1.151 1.2-1.706 2.284-1.706.584 0 1.249.215 1.595.738.398.584.346 1.384.346 2.061zm-.533 5.906c-.451.8-1.169 1.291-1.967 1.291-1.09 0-1.728-.83-1.728-2.061 0-2.42 2.171-2.86 4.227-2.86v.615c.001 1.108.027 2.031-.532 3.015m7.634 5.251C18.329 21.076 14.917 22 11.979 22c-4.118 0-7.826-1.522-10.632-4.057-.22-.199-.024-.471.241-.317 3.027 1.762 6.771 2.823 10.639 2.823 2.608 0 5.476-.541 8.115-1.66.397-.169.73.262.341.55m.653 1.704c-.194.163-.379.076-.293-.139.284-.71.92-2.298.619-2.684s-1.99-.183-2.749-.092c-.23.027-.266-.173-.059-.319 1.348-.946 3.555-.673 3.811-.356.26.32-.066 2.533-1.329 3.59"})))},{name:"behance",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M7.799 5.698c.589 0 1.12.051 1.606.156q.722.155 1.241.507.516.351.804.938c.188.387.281.871.281 1.443q0 .93-.421 1.551-.424.62-1.255 1.014 1.133.328 1.689 1.146.559.822.557 1.975 0 .935-.359 1.612a3.14 3.14 0 0 1-.973 1.114q-.613.432-1.399.637A6.1 6.1 0 0 1 7.963 18H2V5.698zm-.35 4.97q.721 0 1.192-.345.465-.344.463-1.119 0-.43-.152-.707a1.1 1.1 0 0 0-.416-.427 1.7 1.7 0 0 0-.596-.216 3.6 3.6 0 0 0-.697-.06H4.709v2.874zm.151 5.237q.401.001.759-.077c.243-.053.457-.137.637-.261.182-.12.332-.283.441-.491q.164-.31.163-.798-.002-.948-.533-1.357c-.356-.27-.83-.404-1.413-.404H4.709v3.388zm8.562-.041q.552.538 1.583.538.74 0 1.277-.374c.354-.248.571-.514.654-.79h2.155c-.347 1.072-.872 1.838-1.589 2.299-.708.463-1.572.693-2.58.693q-1.05 0-1.899-.337a4 4 0 0 1-1.439-.958 4.4 4.4 0 0 1-.904-1.484 5.4 5.4 0 0 1-.32-1.899q0-1 .329-1.863a4.4 4.4 0 0 1 .933-1.492q.607-.63 1.444-.994a4.6 4.6 0 0 1 1.857-.363q1.131-.001 1.98.44a3.94 3.94 0 0 1 1.389 1.181 4.8 4.8 0 0 1 .783 1.69q.24.947.171 1.983h-6.428c-.001.706.237 1.372.604 1.73m2.811-4.68c-.291-.321-.783-.496-1.384-.496q-.585 0-.973.2a2 2 0 0 0-.621.491 1.8 1.8 0 0 0-.328.628 2.7 2.7 0 0 0-.111.587h3.98c-.058-.625-.271-1.085-.563-1.41m-3.916-3.446h4.985V6.524h-4.985z"})))},{name:"blogger-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.779 9.904h-.981l-.021.001a1.163 1.163 0 0 1-1.16-1.079l-.001-.013A5.813 5.813 0 0 0 11.803 3H8.871a5.813 5.813 0 0 0-5.813 5.813v6.375a5.813 5.813 0 0 0 5.813 5.813h6.257a5.814 5.814 0 0 0 5.813-5.813l.002-4.121a1.164 1.164 0 0 0-1.164-1.163M8.726 7.713h3.291a1.117 1.117 0 1 1 0 2.234H8.726a1.117 1.117 0 1 1 0-2.234m6.601 8.657H8.72a1.057 1.057 0 1 1 0-2.114h6.607a1.057 1.057 0 1 1 0 2.114"})))},{name:"blogger",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M14.722 14.019a.654.654 0 0 1-.654.654H9.977a.654.654 0 0 1 0-1.308h4.091c.361 0 .654.293.654.654m-4.741-3.321h2.038a.692.692 0 0 0 0-1.384H9.981a.692.692 0 0 0 0 1.384M21 5v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2m-3.456 6.39a.72.72 0 0 0-.72-.72h-.607l-.013.001a.72.72 0 0 1-.718-.668l-.001-.008a3.6 3.6 0 0 0-3.599-3.599H10.07a3.6 3.6 0 0 0-3.599 3.599v3.947a3.6 3.6 0 0 0 3.599 3.599h3.874a3.6 3.6 0 0 0 3.599-3.599z"})))},{name:"bluesky",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.2 3.3c-.5-.2-1.4-.5-3.6 1C15.4 6 12.9 9.2 12 11c-.9-1.8-3.4-5-5.7-6.7-2.2-1.6-3-1.3-3.6-1S2 4.6 2 5.1s.3 4.7.5 5.4c.7 2.3 3.1 3.1 5.3 2.8-3.3.5-6.2 1.7-2.4 5.9 4.2 4.3 5.7-.9 6.5-3.6.8 2.7 1.7 7.7 6.4 3.6 3.6-3.6 1-5.4-2.3-5.9 2.2.2 4.6-.5 5.3-2.8.4-.7.7-4.8.7-5.4 0-.5-.1-1.5-.8-1.8"})))},{name:"codepen",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m22.016 8.84-.007-.037q-.006-.037-.015-.072-.007-.022-.013-.042l-.023-.062-.02-.042a.4.4 0 0 0-.03-.057l-.025-.038-.035-.052-.03-.037q-.021-.026-.043-.045-.015-.018-.035-.035a.4.4 0 0 0-.048-.04l-.037-.03-.015-.012-9.161-6.096a.86.86 0 0 0-.955 0L2.359 8.237l-.015.012-.038.028-.048.04a.638.638 0 0 0-.078.082q-.018.018-.03.037-.018.026-.035.052l-.025.038q-.016.031-.03.059l-.02.041a1 1 0 0 0-.034.106q-.01.034-.016.071-.003.02-.006.037a1 1 0 0 0-.009.114v6.093q0 .056.008.112l.007.038q.006.035.015.072a.2.2 0 0 0 .013.04q.01.032.022.063l.02.04a.4.4 0 0 0 .055.096l.035.052.03.037.042.045.035.035q.023.02.048.04l.038.03.013.01 9.163 6.095a.858.858 0 0 0 .959.004l9.163-6.095.015-.01q.02-.015.037-.03l.048-.04q.02-.017.035-.035.025-.024.043-.045l.03-.037.035-.052.025-.038a.4.4 0 0 0 .03-.058l.02-.04.023-.063c.003-.013.01-.027.013-.04q.009-.037.015-.072l.007-.037q.006-.062.007-.117V8.954a1 1 0 0 0-.008-.114m-9.154-4.376 6.751 4.49-3.016 2.013-3.735-2.492zm-1.724 0v4.009l-3.735 2.494-3.014-2.013zm-7.439 6.098L5.853 12l-2.155 1.438zm7.439 8.974-6.749-4.491 3.015-2.011 3.735 2.492zM12 14.035 8.953 12 12 9.966 15.047 12zm.862 5.501v-4.009l3.735-2.492 3.016 2.011zm7.441-6.098L18.147 12l2.156-1.438z"})))},{name:"deezer",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20.129 3.662c.222-1.287.548-2.096.909-2.098h.001c.673.002 1.219 2.809 1.219 6.274s-.546 6.274-1.22 6.274c-.276 0-.531-.477-.736-1.276-.324 2.926-.997 4.937-1.776 4.937-.603 0-1.144-1.208-1.507-3.114-.248 3.624-.872 6.195-1.602 6.195-.458 0-.875-1.019-1.184-2.678C13.861 21.6 13.003 24 12.002 24s-1.861-2.399-2.231-5.824c-.307 1.659-.724 2.678-1.184 2.678-.73 0-1.352-2.571-1.602-6.195-.363 1.905-.903 3.114-1.507 3.114-.778 0-1.452-2.011-1.776-4.937-.204.802-.46 1.276-.736 1.276-.674 0-1.22-2.809-1.22-6.274s.546-6.274 1.22-6.274c.362 0 .685.812.91 2.098.357-2.22.94-3.662 1.6-3.662.784 0 1.463 2.04 1.784 5.002.314-2.156.791-3.53 1.325-3.53.749 0 1.385 2.703 1.621 6.474.443-1.933 1.085-3.146 1.795-3.146s1.352 1.214 1.795 3.146c.237-3.771.872-6.474 1.621-6.474.533 0 1.009 1.374 1.325 3.53.321-2.962 1-5.002 1.784-5.002.658 0 1.244 1.443 1.603 3.662M0 7.221c0-1.549.31-2.805.692-2.805s.692 1.256.692 2.805-.31 2.805-.692 2.805S0 8.77 0 7.221m22.616 0c0-1.549.31-2.805.692-2.805S24 5.672 24 7.221s-.31 2.805-.692 2.805-.692-1.256-.692-2.805"})))},{name:"discord",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20.33 4.523A20 20 0 0 0 15.379 3a14 14 0 0 0-.634 1.289 18.4 18.4 0 0 0-5.495 0A14 14 0 0 0 8.615 3 20 20 0 0 0 3.66 4.527C.527 9.163-.323 13.684.102 18.141a20 20 0 0 0 6.073 3.049 14.7 14.7 0 0 0 1.301-2.097 13 13 0 0 1-2.048-.978q.258-.189.502-.378a14.27 14.27 0 0 0 12.142 0q.247.202.502.378a13 13 0 0 1-2.052.98 14.5 14.5 0 0 0 1.301 2.095 19.9 19.9 0 0 0 6.076-3.047c.498-5.168-.851-9.648-3.568-13.62M8.013 15.4c-1.183 0-2.161-1.074-2.161-2.395S6.796 10.6 8.01 10.6s2.183 1.083 2.163 2.405S9.22 15.4 8.013 15.4m7.974 0c-1.186 0-2.16-1.074-2.16-2.395s.944-2.405 2.16-2.405 2.178 1.083 2.157 2.405-.951 2.395-2.158 2.395"})))},{name:"dribbble",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10m8.434-8.631c-.292-.092-2.644-.794-5.32-.365 1.117 3.07 1.572 5.57 1.659 6.09a8.56 8.56 0 0 0 3.661-5.725m-5.098 6.507c-.127-.749-.623-3.361-1.822-6.477l-.056.019c-4.818 1.679-6.547 5.02-6.701 5.334A8.5 8.5 0 0 0 12 20.555a8.5 8.5 0 0 0 3.336-.679m-9.682-2.152c.193-.331 2.538-4.213 6.943-5.637q.167-.054.337-.102a29 29 0 0 0-.692-1.45c-4.266 1.277-8.405 1.223-8.778 1.216a8.497 8.497 0 0 0 2.19 5.973m-2.015-7.46c.382.005 3.901.02 7.897-1.041a55 55 0 0 0-3.167-4.94 8.57 8.57 0 0 0-4.73 5.981m6.359-6.555a46 46 0 0 1 3.187 5c3.037-1.138 4.323-2.867 4.477-3.085a8.51 8.51 0 0 0-7.664-1.915m8.614 2.903c-.18.243-1.612 2.078-4.77 3.367a27 27 0 0 1 .751 1.678c2.842-.357 5.666.215 5.948.275a8.5 8.5 0 0 0-1.929-5.32"})))},{name:"dropbox",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 6.134 6.069 9.797 2 6.54l5.883-3.843zm-10 6.92 5.883 3.843L12 13.459 6.069 9.797zm10 .405 4.116 3.439L22 13.054l-4.069-3.257zM22 6.54l-5.884-3.843L12 6.134l5.931 3.663zm-9.989 7.66-4.129 3.426-1.767-1.153v1.291l5.896 3.539 5.897-3.539v-1.291l-1.769 1.153z"})))},{name:"eventbrite",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M18.041 3.931 5.959 3A2.96 2.96 0 0 0 3 5.959v12.083A2.96 2.96 0 0 0 5.959 21l12.083-.931C19.699 19.983 21 18.744 21 17.11V6.89c0-1.634-1.259-2.863-2.959-2.959M16.933 8.17c-.082.215-.192.432-.378.551-.188.122-.489.132-.799.132-1.521 0-3.062-.048-4.607-.048q-.23 1.061-.451 2.128c.932-.004 1.873.005 2.81.005.726 0 1.462-.069 1.586.525.04.189-.001.426-.052.615-.105.38-.258.676-.625.783-.185.054-.408.058-.646.058-1.145 0-2.345.017-3.493.02-.169.772-.328 1.553-.489 2.333 1.57-.005 3.067-.041 4.633-.058.627-.007 1.085.194 1.009.85a2.2 2.2 0 0 1-.211.725c-.102.208-.248.376-.488.452-.237.075-.541.064-.862.078-.304.014-.614.008-.924.016-.309.009-.619.022-.919.022-1.253 0-2.429.08-3.683.073-.603-.004-1.014-.249-1.124-.757-.059-.273-.018-.58.036-.841a3543 3543 0 0 1 1.629-7.763c.056-.265.114-.511.225-.714a1.24 1.24 0 0 1 .79-.62c.368-.099.883-.047 1.344-.047.305 0 .612.008.914.016.925.026 1.817.03 2.747.053.304.007.615.016.915.016.621 0 1.17.073 1.245.614.039.288-.051.567-.132.783"})))},{name:"facebook",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.5 2 2 6.5 2 12c0 5 3.7 9.1 8.4 9.9v-7H7.9V12h2.5V9.8c0-2.5 1.5-3.9 3.8-3.9 1.1 0 2.2.2 2.2.2v2.5h-1.3c-1.2 0-1.6.8-1.6 1.6V12h2.8l-.4 2.9h-2.3v7C18.3 21.1 22 17 22 12c0-5.5-4.5-10-10-10"})))},{name:"fediverse",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 743 743"},React.createElement("g",null,React.createElement("path",{d:"M181.131 275.137a68.9 68.9 0 0 1-29.465 29.328l161.758 162.389 38.998-19.764zm213.363 214.187-38.998 19.764 81.963 82.283a68.9 68.9 0 0 1 29.471-29.332zM581.646 339.391l-91.576 46.41 6.752 43.189 103.616-52.513a68.9 68.9 0 0 1-18.792-37.086m-144.738 73.351L220.383 522.477a68.9 68.9 0 0 1 18.795 37.089L443.66 455.934zM367.275 142.438l-104.48 203.97 30.848 30.967 110.623-215.957a68.9 68.9 0 0 1-36.991-18.98M235.621 399.459l-52.922 103.314a68.9 68.9 0 0 1 36.987 18.979l46.781-91.328zM150.768 304.918a68.9 68.9 0 0 1-34.416 7.195 69 69 0 0 1-6.651-.695l30.903 197.662a68.9 68.9 0 0 1 34.416-7.195 69 69 0 0 1 6.646.695zM239.342 560.545c.707 4.589.949 9.239.72 13.877a68.9 68.9 0 0 1-7.267 27.18l197.629 31.712c-.708-4.59-.95-9.24-.723-13.878a68.9 68.9 0 0 1 7.27-27.178zM601.133 377.199l-91.219 178.082a68.9 68.9 0 0 1 36.994 18.983l91.217-178.08a68.9 68.9 0 0 1-36.992-18.985M476.723 125.33a68.9 68.9 0 0 1-29.471 29.332l141.266 141.811a68.9 68.9 0 0 1 29.468-29.332zM347.787 104.631l-178.576 90.498a68.9 68.9 0 0 1 18.793 37.086l178.574-90.502a68.9 68.9 0 0 1-18.791-37.082M446.926 154.826a68.9 68.9 0 0 1-34.983 7.483 69 69 0 0 1-6.029-.633l15.818 101.291 43.163 6.926zm-16 167.028 37.4 239.482a68.9 68.9 0 0 1 33.914-6.943q3.625.206 7.207.791L474.09 328.777zM188.131 232.975c.734 4.66.988 9.383.758 14.095a68.9 68.9 0 0 1-7.16 26.983l101.369 16.281 19.923-38.908zm173.736 27.9-19.926 38.912 239.514 38.467a69 69 0 0 1-.695-13.719 68.9 68.9 0 0 1 7.349-27.324z"}),React.createElement("path",{fillOpacity:".996",d:"M412.284 156.054c34.538 1.882 64.061-24.592 65.943-59.13s-24.592-64.062-59.131-65.943c-34.538-1.882-64.061 24.592-65.943 59.13s24.593 64.062 59.131 65.943M646.144 390.82c34.538 1.881 64.062-24.593 65.943-59.131s-24.592-64.061-59.13-65.943-64.062 24.593-65.943 59.131 24.592 64.061 59.13 65.943M495.086 685.719c34.538 1.881 64.062-24.592 65.943-59.13s-24.592-64.062-59.13-65.943-64.062 24.592-65.943 59.13 24.592 64.062 59.13 65.943M167.866 633.211c34.538 1.882 64.062-24.592 65.943-59.13s-24.592-64.062-59.13-65.943-64.062 24.592-65.943 59.13 24.592 64.062 59.13 65.943M116.692 305.86c34.538 1.882 64.062-24.592 65.943-59.13s-24.592-64.062-59.131-65.943c-34.538-1.881-64.061 24.592-65.943 59.13s24.593 64.062 59.131 65.943"})))},{name:"feed",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M2 8.667V12c5.515 0 10 4.485 10 10h3.333c0-7.363-5.97-13.333-13.333-13.333M2 2v3.333c9.19 0 16.667 7.477 16.667 16.667H22C22 10.955 13.045 2 2 2m2.5 15a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5"})))},{name:"flickr",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M6.5 7c-2.75 0-5 2.25-5 5s2.25 5 5 5 5-2.25 5-5-2.25-5-5-5m11 0c-2.75 0-5 2.25-5 5s2.25 5 5 5 5-2.25 5-5-2.25-5-5-5"})))},{name:"foursquare",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M17.573 2H6.905C5.434 2 5 3.107 5 3.805v16.948c0 .785.422 1.077.66 1.172.238.097.892.177 1.285-.275 0 0 5.035-5.843 5.122-5.93.132-.132.132-.132.262-.132h3.26c1.368 0 1.588-.977 1.732-1.552.078-.318.692-3.428 1.225-6.122l.675-3.368C19.56 2.893 19.14 2 17.573 2m-1.078 5.22c-.053.252-.372.518-.665.518h-4.157c-.467 0-.802.318-.802.787v.508c0 .467.337.798.805.798h3.528c.331 0 .655.362.583.715s-.407 2.102-.448 2.295c-.04.193-.262.523-.655.523h-2.88c-.523 0-.683.068-1.033.503-.35.437-3.505 4.223-3.505 4.223-.032.035-.063.027-.063-.015V4.852c0-.298.26-.648.648-.648h8.562c.315 0 .61.297.528.683z"})))},{name:"ghost",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M10.203 20.997H3.005v-3.599h7.198zm10.792-3.599h-7.193v3.599h7.193zm.003-7.198H3v3.599h17.998zm-7.195-7.197H3.005v3.599h10.798zm7.197 0h-3.599v3.599H21z"})))},{name:"git",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M23.519 10.947 13.053.482a1.543 1.543 0 0 0-2.183 0L8.696 2.656l2.756 2.756a1.83 1.83 0 0 1 1.886.439 1.84 1.84 0 0 1 .436 1.898l2.656 2.657a1.83 1.83 0 0 1 1.899.436 1.837 1.837 0 0 1 0 2.597 1.84 1.84 0 0 1-2.599 0 1.84 1.84 0 0 1-.4-1.998l-2.478-2.477v6.521a1.837 1.837 0 0 1 .485 2.945 1.837 1.837 0 0 1-2.597 0 1.837 1.837 0 0 1 0-2.598 1.8 1.8 0 0 1 .602-.401V8.85a1.8 1.8 0 0 1-.602-.4 1.84 1.84 0 0 1-.395-2.009L7.628 3.723.452 10.898a1.544 1.544 0 0 0 0 2.184l10.467 10.467a1.544 1.544 0 0 0 2.183 0l10.417-10.418a1.546 1.546 0 0 0 0-2.184"})))},{name:"github",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12c0 4.419 2.865 8.166 6.839 9.489.5.09.682-.218.682-.484 0-.236-.009-.866-.014-1.699-2.782.602-3.369-1.34-3.369-1.34-.455-1.157-1.11-1.465-1.11-1.465-.909-.62.069-.608.069-.608 1.004.071 1.532 1.03 1.532 1.03.891 1.529 2.341 1.089 2.91.833.091-.647.349-1.086.635-1.337-2.22-.251-4.555-1.111-4.555-4.943 0-1.091.39-1.984 1.03-2.682-.103-.254-.447-1.27.097-2.646 0 0 .84-.269 2.75 1.025A9.6 9.6 0 0 1 12 6.836c.85.004 1.705.114 2.504.336 1.909-1.294 2.748-1.025 2.748-1.025.546 1.376.202 2.394.1 2.646.64.699 1.026 1.591 1.026 2.682 0 3.841-2.337 4.687-4.565 4.935.359.307.679.917.679 1.852 0 1.335-.012 2.415-.012 2.741 0 .269.18.579.688.481A10 10 0 0 0 22 12c0-5.523-4.477-10-10-10"})))},{name:"google-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m-.05 16c-3.312 0-6-2.688-6-6s2.688-6 6-6c1.62 0 2.976.594 4.014 1.566L14.26 9.222c-.432-.408-1.188-.888-2.31-.888-1.986 0-3.606 1.65-3.606 3.672s1.62 3.672 3.606 3.672c2.298 0 3.144-1.59 3.3-2.532h-3.306v-2.238h5.616c.084.378.15.732.15 1.23 0 3.426-2.298 5.862-5.76 5.862"})))},{name:"google-plus-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M8 11h6.61c.06.35.11.7.11 1.16 0 4-2.68 6.84-6.72 6.84-3.87 0-7-3.13-7-7s3.13-7 7-7c1.89 0 3.47.69 4.69 1.83l-1.9 1.83c-.52-.5-1.43-1.08-2.79-1.08-2.39 0-4.34 1.98-4.34 4.42S5.61 16.42 8 16.42c2.77 0 3.81-1.99 3.97-3.02H8zm15 0h-2V9h-2v2h-2v2h2v2h2v-2h2"})))},{name:"google-plus",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m-1.919 14.05a4.051 4.051 0 0 1 0-8.1c1.094 0 2.009.401 2.709 1.057l-1.15 1.118a2.23 2.23 0 0 0-1.559-.599c-1.341 0-2.434 1.114-2.434 2.479s1.094 2.479 2.434 2.479c1.551 0 2.122-1.073 2.227-1.709h-2.232v-1.511h3.791c.057.255.101.494.101.83.001 2.312-1.55 3.956-3.887 3.956M19 12.75h-1.25V14h-1.5v-1.25H15v-1.5h1.25V10h1.5v1.25H19z"})))},{name:"google",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.02 10.18v3.73h5.51c-.26 1.57-1.67 4.22-5.5 4.22-3.31 0-6.01-2.75-6.01-6.12s2.7-6.12 6.01-6.12c1.87 0 3.13.8 3.85 1.48l2.84-2.76C16.99 2.99 14.73 2 12.03 2c-5.52 0-10 4.48-10 10s4.48 10 10 10c5.77 0 9.6-4.06 9.6-9.77 0-.83-.11-1.42-.25-2.05z"})))},{name:"instagram",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 4.622c2.403 0 2.688.009 3.637.052.877.04 1.354.187 1.671.31.42.163.72.358 1.035.673s.51.615.673 1.035c.123.317.27.794.31 1.671.043.949.052 1.234.052 3.637s-.009 2.688-.052 3.637c-.04.877-.187 1.354-.31 1.671-.163.42-.358.72-.673 1.035s-.615.51-1.035.673c-.317.123-.794.27-1.671.31-.949.043-1.233.052-3.637.052s-2.688-.009-3.637-.052c-.877-.04-1.354-.187-1.671-.31a2.8 2.8 0 0 1-1.035-.673 2.8 2.8 0 0 1-.673-1.035c-.123-.317-.27-.794-.31-1.671-.043-.949-.052-1.234-.052-3.637s.009-2.688.052-3.637c.04-.877.187-1.354.31-1.671.163-.42.358-.72.673-1.035s.615-.51 1.035-.673c.317-.123.794-.27 1.671-.31.949-.043 1.234-.052 3.637-.052M12 3c-2.444 0-2.751.01-3.711.054-.958.044-1.612.196-2.184.418a4.4 4.4 0 0 0-1.594 1.039c-.5.5-.808 1.002-1.038 1.594-.223.572-.375 1.226-.419 2.184C3.01 9.249 3 9.556 3 12s.01 2.751.054 3.711c.044.958.196 1.612.418 2.185.23.592.538 1.094 1.038 1.594s1.002.808 1.594 1.038c.572.222 1.227.375 2.185.418.96.044 1.267.054 3.711.054s2.751-.01 3.711-.054c.958-.044 1.612-.196 2.185-.418a4.4 4.4 0 0 0 1.594-1.038c.5-.5.808-1.002 1.038-1.594.222-.572.375-1.227.418-2.185.044-.96.054-1.267.054-3.711s-.01-2.751-.054-3.711c-.044-.958-.196-1.612-.418-2.185A4.4 4.4 0 0 0 19.49 4.51c-.5-.5-1.002-.808-1.594-1.038-.572-.222-1.227-.375-2.185-.418C14.751 3.01 14.444 3 12 3m0 4.378a4.622 4.622 0 1 0 0 9.244 4.622 4.622 0 0 0 0-9.244M12 15a3 3 0 1 1 0-6 3 3 0 0 1 0 6m4.804-8.884a1.08 1.08 0 1 0 .001 2.161 1.08 1.08 0 0 0-.001-2.161"})))},{name:"json-feed",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m8.522 17.424.027.027c1.076-1.076 1.854-.993 3.154.306l2.053 2.053c2.136 2.136 4.131 2.028 6.515-.356l.729-.728-1.548-1.548-.373.373c-1.349 1.349-2.293 1.366-3.585.075l-2.409-2.409c-1.242-1.242-2.475-1.366-3.659-.381l-.232-.232c1.01-1.225.911-2.368-.29-3.568l-2.16-2.162c-1.317-1.317-1.308-2.236.058-3.602l.372-.372-1.54-1.54-.728.729c-2.393 2.393-2.525 4.346-.439 6.433l1.78 1.78c1.3 1.3 1.383 2.095.315 3.163l.008.008a1.384 1.384 0 0 0 1.952 1.951"}),React.createElement("circle",{cx:"13.089",cy:"10.905",r:"1.383"}),React.createElement("circle",{cx:"16.349",cy:"7.644",r:"1.383"}),React.createElement("circle",{cx:"19.61",cy:"4.383",r:"1.383"})))},{name:"line",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M14.255 9.572v3.333c0 .084-.066.15-.15.15h-.534a.16.16 0 0 1-.122-.061l-1.528-2.063v1.978c0 .084-.066.15-.15.15h-.534a.15.15 0 0 1-.15-.15V9.576c0-.084.066-.15.15-.15h.529a.14.14 0 0 1 .122.066l1.528 2.063V9.577c0-.084.066-.15.15-.15h.534a.15.15 0 0 1 .155.145m-3.844-.15h-.534a.15.15 0 0 0-.15.15v3.333c0 .084.066.15.15.15h.534c.084 0 .15-.066.15-.15V9.572c0-.08-.066-.15-.15-.15m-1.289 2.794H7.664V9.572a.15.15 0 0 0-.15-.15H6.98a.15.15 0 0 0-.15.15v3.333q0 .062.042.103a.16.16 0 0 0 .103.042h2.142c.084 0 .15-.066.15-.15v-.534a.15.15 0 0 0-.145-.15m7.945-2.794h-2.142c-.08 0-.15.066-.15.15v3.333c0 .08.066.15.15.15h2.142c.084 0 .15-.066.15-.15v-.534a.15.15 0 0 0-.15-.15h-1.458v-.563h1.458c.084 0 .15-.066.15-.15v-.539a.15.15 0 0 0-.15-.15h-1.458v-.563h1.458c.084 0 .15-.066.15-.15v-.534c-.005-.08-.07-.15-.15-.15M22.5 5.33v13.373c-.005 2.1-1.725 3.802-3.83 3.797H5.297c-2.1-.005-3.802-1.73-3.797-3.83V5.297c.005-2.1 1.73-3.802 3.83-3.797h13.373c2.1.005 3.802 1.725 3.797 3.83m-2.888 5.747c0-3.422-3.431-6.206-7.645-6.206s-7.645 2.784-7.645 6.206c0 3.066 2.719 5.634 6.394 6.122.895.192.792.52.591 1.725-.033.192-.155.755.661.413s4.402-2.592 6.009-4.439c1.106-1.219 1.636-2.452 1.636-3.82"})))},{name:"link",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M17 13H7v-2h10zm1-6h-1c-1.631 0-3.065.792-3.977 2H18c1.103 0 2 .897 2 2v2c0 1.103-.897 2-2 2h-4.977c.913 1.208 2.347 2 3.977 2h1a4 4 0 0 0 4-4v-2a4 4 0 0 0-4-4M2 11v2a4 4 0 0 0 4 4h1c1.63 0 3.065-.792 3.977-2H6c-1.103 0-2-.897-2-2v-2c0-1.103.897-2 2-2h4.977C10.065 7.792 8.631 7 7 7H6a4 4 0 0 0-4 4"})))},{name:"linkedin",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.7 3H4.3A1.3 1.3 0 0 0 3 4.3v15.4A1.3 1.3 0 0 0 4.3 21h15.4a1.3 1.3 0 0 0 1.3-1.3V4.3A1.3 1.3 0 0 0 19.7 3M8.339 18.338H5.667v-8.59h2.672zM7.004 8.574a1.548 1.548 0 1 1-.002-3.096 1.548 1.548 0 0 1 .002 3.096m11.335 9.764H15.67v-4.177c0-.996-.017-2.278-1.387-2.278-1.389 0-1.601 1.086-1.601 2.206v4.249h-2.667v-8.59h2.559v1.174h.037c.356-.675 1.227-1.387 2.526-1.387 2.703 0 3.203 1.779 3.203 4.092v4.711z"})))},{name:"mail",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20 4H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2m0 4.236-8 4.882-8-4.882V6h16z"})))},{name:"mastodon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M11.973 2.352c-2.468.02-4.842.286-6.225.921 0 0-2.742 1.229-2.742 5.415 0 .958-.018 2.105.012 3.32.1 4.094.75 8.128 4.535 9.129 1.745.462 3.244.56 4.45.494 2.19-.122 3.417-.781 3.417-.781l-.072-1.588s-1.565.491-3.32.431c-1.74-.06-3.576-.188-3.858-2.324a4 4 0 0 1-.04-.598s1.709.416 3.874.516c1.324.06 2.563-.076 3.824-.226 2.418-.29 4.524-1.78 4.79-3.141.416-2.144.38-5.232.38-5.232 0-4.186-2.74-5.415-2.74-5.415-1.383-.635-3.76-.9-6.227-.921zM9.18 5.622c1.028 0 1.804.395 2.318 1.185l.502.84.5-.84c.514-.79 1.292-1.186 2.32-1.186.888 0 1.605.313 2.15.922q.795.915.794 2.469v5.068h-2.008V9.16c0-1.037-.438-1.562-1.31-1.562-.966 0-1.448.622-1.448 1.857v2.693h-1.996V9.455c0-1.235-.484-1.857-1.45-1.857-.872 0-1.308.525-1.308 1.562v4.92H6.236V9.012q-.001-1.554.793-2.469c.547-.609 1.263-.922 2.15-.922"})))},{name:"medium-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{fillRule:"nonzero",d:"M7.423 6c3.27 0 5.922 2.686 5.922 6s-2.651 6-5.922 6S1.5 15.313 1.5 12s2.652-6 5.923-6m9.458.351c1.635 0 2.961 2.53 2.961 5.65 0 3.118-1.325 5.648-2.96 5.648S13.92 15.119 13.92 12s1.325-5.649 2.96-5.649m4.577.589c.576 0 1.042 2.265 1.042 5.06s-.466 5.06-1.042 5.06c-.575 0-1.04-2.265-1.04-5.06s.465-5.06 1.04-5.06"})))},{name:"medium",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M3 3v18h18V3zm15 4.26-1 .93a.28.28 0 0 0-.11.27v6.8a.27.27 0 0 0 .11.27l.94.93v.2h-4.75v-.2l1-1c.09-.1.09-.12.09-.27V9.74l-2.71 6.9h-.37L8 9.74v4.62a.67.67 0 0 0 .17.54l1.27 1.54v.2H5.86v-.2l1.27-1.54a.64.64 0 0 0 .17-.54V9a.5.5 0 0 0-.16-.4L6 7.26v-.2h3.52L12.23 13l2.38-5.94H18z"})))},{name:"messenger",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.026.375C5.462.375.375 5.172.375 11.652c0 3.389 1.393 6.318 3.66 8.341.391.352.311.556.377 2.73a.934.934 0 0 0 1.307.823c2.48-1.092 2.512-1.178 2.933-1.064 7.185 1.977 14.973-2.621 14.973-10.83 0-6.48-5.035-11.277-11.599-11.277m6.996 8.678L15.6 14.47a1.75 1.75 0 0 1-2.527.465l-2.723-2.038a.7.7 0 0 0-.844 0l-3.674 2.786c-.49.372-1.133-.216-.802-.735l3.422-5.417a1.75 1.75 0 0 1 2.527-.465l2.722 2.037a.7.7 0 0 0 .844 0L18.22 8.32c.489-.374 1.132.213.801.732"})))},{name:"microblog",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.641 17.086c1.294-1.522 2.067-3.438 2.067-5.521 0-4.957-4.371-8.972-9.763-8.972s-9.763 4.015-9.763 8.972 4.371 8.972 9.763 8.972a10.5 10.5 0 0 0 3.486-.59.315.315 0 0 1 .356.112c.816 1.101 2.09 1.876 3.506 2.191a.194.194 0 0 0 .192-.309 3.82 3.82 0 0 1 .162-4.858zm-3.065-6.575-2.514 1.909.912 3.022a.286.286 0 0 1-.437.317l-2.592-1.802-2.592 1.802a.285.285 0 0 1-.436-.317l.912-3.022-2.515-1.909a.285.285 0 0 1 .167-.513l3.155-.066 1.038-2.981a.285.285 0 0 1 .539 0l1.038 2.981 3.155.066a.285.285 0 0 1 .17.513"})))},{name:"nextdoor",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",strokeMiterlimit:"10",viewBox:"0 0 130 130"},React.createElement("g",null,React.createElement("path",{d:"M64.25 3.531c-31.144.337-57.596 24.22-60.469 55.907-3.064 33.799 21.857 63.685 55.657 66.75s63.685-21.857 66.75-55.657-21.857-63.686-55.657-66.75a62 62 0 0 0-6.281-.25m3.938 34.907C82.468 38.438 93.5 48.58 93.5 61.5v27c0 .685-.565 1.25-1.25 1.25H80.906a1.267 1.267 0 0 1-1.25-1.25V63.375c0-5.58-4.309-11.937-11.469-11.937-7.47 0-11.468 6.357-11.468 11.937V88.5c0 .685-.565 1.25-1.25 1.25H44.125c-.68 0-1.219-.57-1.219-1.25V64.156c0-.74-.529-1.364-1.25-1.531-13.13-2.93-15.115-10.285-15.375-21.125-.005-.332.142-.67.375-.906.233-.237.543-.375.875-.375l11.688.062c.66.01 1.187.529 1.218 1.188.13 4.44.438 9.406 4.438 9.406.83 0 1.443-1.179 1.813-1.719 4.41-6.48 12.28-10.718 21.5-10.718"})))},{name:"patreon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20 7.408c-.003-2.299-1.746-4.182-3.79-4.862-2.54-.844-5.888-.722-8.312.453-2.939 1.425-3.862 4.545-3.896 7.656-.028 2.559.22 9.297 3.92 9.345 2.75.036 3.159-3.603 4.43-5.356.906-1.247 2.071-1.599 3.506-1.963 2.465-.627 4.146-2.626 4.142-5.273"})))},{name:"pinterest-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.289 2C6.617 2 3.606 5.648 3.606 9.622c0 1.846 1.025 4.146 2.666 4.878.25.111.381.063.439-.169.044-.175.267-1.029.365-1.428a.37.37 0 0 0-.091-.362c-.54-.63-.975-1.791-.975-2.873 0-2.777 2.194-5.464 5.933-5.464 3.23 0 5.49 2.108 5.49 5.122 0 3.407-1.794 5.768-4.13 5.768-1.291 0-2.257-1.021-1.948-2.277.372-1.495 1.089-3.112 1.089-4.191 0-.967-.542-1.775-1.663-1.775-1.319 0-2.379 1.309-2.379 3.059 0 1.115.394 1.869.394 1.869s-1.302 5.279-1.54 6.261c-.405 1.666.053 4.368.094 4.604.021.126.167.169.25.063.129-.165 1.699-2.419 2.142-4.051.158-.59.817-2.995.817-2.995.43.784 1.681 1.446 3.013 1.446 3.963 0 6.822-3.494 6.822-7.833C20.394 5.112 16.849 2 12.289 2"})))},{name:"pinterest",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12c0 4.236 2.636 7.855 6.356 9.312-.087-.791-.166-2.005.035-2.869.182-.78 1.173-4.971 1.173-4.971s-.299-.599-.299-1.484c0-1.39.806-2.429 1.809-2.429.853 0 1.265.641 1.265 1.409 0 .858-.546 2.141-.828 3.329-.236.996.499 1.807 1.481 1.807 1.777 0 3.144-1.874 3.144-4.579 0-2.394-1.72-4.068-4.177-4.068-2.845 0-4.515 2.134-4.515 4.34 0 .859.331 1.781.744 2.282a.3.3 0 0 1 .069.287c-.077.316-.246.995-.279 1.134-.044.183-.145.222-.334.134-1.249-.581-2.03-2.407-2.03-3.874 0-3.154 2.292-6.051 6.607-6.051 3.469 0 6.165 2.472 6.165 5.775 0 3.446-2.173 6.22-5.189 6.22-1.013 0-1.966-.526-2.292-1.148l-.623 2.377c-.226.869-.835 1.957-1.243 2.622.936.289 1.93.445 2.961.445 5.523 0 10-4.477 10-10S17.523 2 12 2"})))},{name:"pocket",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.927 4.194A1.82 1.82 0 0 0 20.222 3H3.839a1.823 1.823 0 0 0-1.813 1.814v6.035l.069 1.2c.29 2.73 1.707 5.115 3.899 6.778l.119.089.025.018a9.9 9.9 0 0 0 3.91 1.727 10.06 10.06 0 0 0 4.049-.014.3.3 0 0 0 .064-.023 9.9 9.9 0 0 0 3.753-1.691l.025-.018q.06-.043.119-.089c2.192-1.664 3.609-4.049 3.898-6.778l.069-1.2V4.814a1.8 1.8 0 0 0-.098-.62m-4.235 6.287-4.704 4.512a1.37 1.37 0 0 1-1.898 0l-4.705-4.512a1.371 1.371 0 1 1 1.898-1.979l3.756 3.601 3.755-3.601a1.372 1.372 0 0 1 1.898 1.979"})))},{name:"polldaddy",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.487 2 2 6.487 2 12c0 5.514 4.487 10 10 10 5.514 0 10-4.486 10-10 0-5.513-4.486-10-10-10m.991 1.68c2.361.084 4.657 1.251 6.197 3.136.283.334.541.693.774 1.067a7.78 7.78 0 0 0-6.094-2.94 7.76 7.76 0 0 0-5.896 2.703q-.008.006-.016.014l-.152.159-.031.032a6.12 6.12 0 0 0-1.633 4.165 6.15 6.15 0 0 0 6.143 6.143c.57 0 1.123-.081 1.649-.227-1.849.839-4.131.747-5.926-.324-1.841-1.089-3.171-3.111-3.433-5.313A7.39 7.39 0 0 1 6.69 6.137C8.294 4.5 10.634 3.563 12.991 3.68m3.373 8.519c-.049-2.024-1.587-3.889-3.544-4.174-1.927-.343-3.917.857-4.451 2.661a3.67 3.67 0 0 0 .2 2.653c.39.8 1.067 1.451 1.894 1.759 1.664.654 3.63-.27 4.173-1.863.593-1.58-.396-3.423-1.94-3.776-1.52-.407-3.161.757-3.204 2.243a2.36 2.36 0 0 0 .753 1.879c.501.476 1.23.667 1.871.529a2.07 2.07 0 0 0 1.469-1.134 1.91 1.91 0 0 0-.087-1.767c-.297-.513-.859-.863-1.429-.881a1.7 1.7 0 0 0-1.437.679 1.53 1.53 0 0 0-.18 1.489q.006.016.016.03c.193.634.774 1.1 1.467 1.117a1.6 1.6 0 0 1-.97-.183c-.466-.244-.809-.747-.893-1.29a1.8 1.8 0 0 1 .499-1.539 2.02 2.02 0 0 1 1.58-.606c.593.04 1.159.35 1.517.859.364.496.51 1.156.383 1.773-.116.62-.529 1.174-1.093 1.514a2.52 2.52 0 0 1-1.914.286c-.65-.161-1.226-.606-1.584-1.206a2.83 2.83 0 0 1-.341-2.031c.143-.7.573-1.321 1.176-1.753 1.193-.883 3.056-.751 4.106.411 1.106 1.1 1.327 3.027.406 4.371-.877 1.376-2.74 2.086-4.374 1.594-1.639-.449-2.913-2.079-3.031-3.853-.07-.884.13-1.797.583-2.577.445-.777 1.155-1.432 1.972-1.862 1.64-.88 3.816-.743 5.349.424 1.251.924 2.083 2.42 2.236 4.009l.001.03c0 2.9-2.359 5.26-5.26 5.26a5.2 5.2 0 0 1-1.947-.376 5 5 0 0 0 2.613-.079 4.96 4.96 0 0 0 2.514-1.751c.618-.828.95-1.861.901-2.869M12 21.113c-5.024 0-9.111-4.087-9.111-9.113 0-4.789 3.713-8.723 8.411-9.081a7 7 0 0 0-.397.06c-2.644.453-5.017 2.106-6.32 4.409-1.309 2.301-1.391 5.19-.3 7.527 1.056 2.34 3.253 4.156 5.776 4.553 2.497.44 5.133-.483 6.787-2.301 1.719-1.797 2.269-4.529 1.486-6.796-.583-1.81-1.976-3.331-3.7-4.046 3.417.594 6.174 3.221 6.174 6.781 0 1.004-.241 2.02-.657 2.966-1.498 2.984-4.586 5.041-8.149 5.041"})))},{name:"print",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M9 16h6v2H9zm13 1h-3v3a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-3H2V9a2 2 0 0 1 2-2h1V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v2h1a2 2 0 0 1 2 2zM7 7h10V5H7zm10 7H7v6h10zm3-3.5a1.5 1.5 0 1 0-3.001.001A1.5 1.5 0 0 0 20 10.5"})))},{name:"quora",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M47.736 16.521c-.41-.81-.898-1.631-1.846-1.631a1 1 0 0 0-.527.107l-.322-.644a2.93 2.93 0 0 1 1.836-.595c1.26 0 1.914.605 2.431 1.397a6.8 6.8 0 0 0 .449-2.675c0-2.773-.869-4.199-2.929-4.199-1.992 0-2.851 1.465-2.851 4.199s.859 4.17 2.851 4.17a4 4 0 0 0 .869-.107zm.498.966a6 6 0 0 1-1.367.185 5.27 5.27 0 0 1-5.263-5.204c0-3.114 2.558-5.233 5.263-5.233s5.282 2.109 5.282 5.233a5.08 5.08 0 0 1-1.992 4.072c.381.566.781.956 1.319.956.595 0 .839-.459.878-.82h.781c.049.488-.195 2.48-2.373 2.48-1.319 0-2.012-.761-2.529-1.66zm5.624-2.646v-3.563c0-.371-.146-.586-.615-.586h-.498v-.956h3.251v5.048c0 .849.459 1.231 1.161 1.231a1.56 1.56 0 0 0 1.465-.839V11.28c0-.371-.146-.586-.615-.586h-.527v-.957h3.28v5.302c0 .527.195.732.8.732h.107v.976l-2.929.468V16.21h-.057a3.12 3.12 0 0 1-2.509 1.152c-1.28 0-2.304-.644-2.304-2.558zm12.059 1.611c1.152 0 1.592-1.005 1.611-3.027.02-1.982-.459-2.929-1.611-2.929-1.005 0-1.641.956-1.641 2.929 0 2.021.625 3.027 1.641 3.027m0 .956a3.906 3.906 0 0 1-3.974-3.974c0-2.334 1.836-3.886 3.974-3.886 2.226 0 4.004 1.582 4.004 3.886a3.867 3.867 0 0 1-4.004 3.974m4.072-.146v-.956h.312c.781 0 .859-.224.859-.908v-4.121c0-.371-.215-.586-.732-.586h-.42v-.955h2.968l.146 1.553h.108c.371-1.113 1.221-1.699 2.051-1.699.693 0 1.221.39 1.221 1.181 0 .547-.264 1.093-1.005 1.093-.664 0-.8-.449-1.358-.449-.488 0-.869.468-.869 1.152v2.783c0 .673.166.908.937.908h.439v.956h-4.658zm9.901-1.093c.956 0 1.338-.898 1.338-1.797v-1.211c-.732.722-2.304.742-2.304 2.021 0 .625.371.986.966.986m1.387 0c-.39.752-1.191 1.26-2.314 1.26-1.309 0-2.148-.732-2.148-1.914 0-2.451 3.417-1.797 4.423-3.427v-.185c0-1.25-.488-1.445-1.035-1.445-1.524 0-.83 1.631-2.226 1.631-.673 0-.937-.371-.937-.859 0-.927 1.093-1.67 3.173-1.67 1.963 0 3.163.537 3.163 2.49v3.114q-.02.742.595.742a1 1 0 0 0 .449-.127l.254.615c-.205.312-.752.869-1.836.869-.908 0-1.465-.42-1.543-1.113h-.01zm-68.554 2.558c-.83-1.641-1.807-3.3-3.711-3.3a2.9 2.9 0 0 0-1.093.215l-.644-1.299a5.66 5.66 0 0 1 3.662-1.211c2.548 0 3.857 1.231 4.892 2.792q.917-2.012.908-5.38c0-5.585-1.748-8.417-5.829-8.417-4.033 0-5.76 2.87-5.76 8.417s1.738 8.397 5.76 8.397a5.9 5.9 0 0 0 1.748-.224zm.996 1.953a9.8 9.8 0 0 1-2.744.371C5.614 21.041.371 16.764.371 10.545.371 4.277 5.614 0 10.965 0c5.448 0 10.642 4.248 10.642 10.545a10.25 10.25 0 0 1-4.013 8.201c.732 1.152 1.563 1.914 2.665 1.914 1.201 0 1.689-.927 1.768-1.66h1.572c.088.966-.4 4.999-4.775 4.999-2.646 0-4.052-1.543-5.106-3.339z"})))},{name:"reddit",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M22 11.816a2.28 2.28 0 0 0-2.277-2.277c-.593 0-1.122.24-1.526.614-1.481-.965-3.455-1.594-5.647-1.69l1.171-3.702 3.18.748a1.88 1.88 0 0 0 1.876 1.862 1.88 1.88 0 0 0 1.877-1.878 1.88 1.88 0 0 0-1.877-1.877c-.769 0-1.431.466-1.72 1.13l-3.508-.826a.386.386 0 0 0-.46.261l-1.35 4.268c-2.316.038-4.411.67-5.97 1.671a2.24 2.24 0 0 0-1.492-.581A2.28 2.28 0 0 0 2 11.816c0 .814.433 1.523 1.078 1.925a4 4 0 0 0-.061.672c0 3.292 4.011 5.97 8.941 5.97s8.941-2.678 8.941-5.97q-.002-.32-.053-.632A2.26 2.26 0 0 0 22 11.816m-3.224-7.422a1.1 1.1 0 1 1-.001 2.199 1.1 1.1 0 0 1 .001-2.199M2.777 11.816c0-.827.672-1.5 1.499-1.5.313 0 .598.103.838.269-.851.676-1.477 1.479-1.812 2.36a1.48 1.48 0 0 1-.525-1.129m9.182 7.79c-4.501 0-8.164-2.329-8.164-5.193S7.457 9.22 11.959 9.22s8.164 2.329 8.164 5.193-3.663 5.193-8.164 5.193m8.677-6.605c-.326-.89-.948-1.701-1.797-2.384.248-.186.55-.301.883-.301.827 0 1.5.673 1.5 1.5.001.483-.23.911-.586 1.185m-11.64 1.703c-.76 0-1.397-.616-1.397-1.376s.637-1.397 1.397-1.397 1.376.637 1.376 1.397-.616 1.376-1.376 1.376m7.405-1.376c0 .76-.616 1.376-1.376 1.376s-1.399-.616-1.399-1.376.639-1.397 1.399-1.397 1.376.637 1.376 1.397m-1.172 3.38a.39.39 0 0 1 0 .55c-.674.674-1.727 1.002-3.219 1.002l-.011-.002-.011.002c-1.492 0-2.544-.328-3.218-1.002a.389.389 0 1 1 .55-.55c.521.521 1.394.775 2.669.775l.011.002.011-.002c1.275 0 2.148-.253 2.669-.775a.387.387 0 0 1 .549 0"})))},{name:"share",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M18 16c-.788 0-1.499.31-2.034.807L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.048 4.118A3 3 0 0 0 15 19a3 3 0 1 0 3-3"})))},{name:"skype",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m10.113 2.699.1-.02q.05.025.098.051zM2.72 10.223l-.017.103q.025.048.051.095zm18.555 3.548q.009-.053.018-.106-.025-.047-.052-.095zm-7.712 7.428q.049.027.096.053l.105-.017zM22 16.386a5.55 5.55 0 0 1-1.637 3.953 5.55 5.55 0 0 1-3.953 1.637 5.6 5.6 0 0 1-2.75-.725l.105-.017-.202-.035q.049.027.096.053a9.5 9.5 0 0 1-1.654.147 9.4 9.4 0 0 1-3.676-.743 9.4 9.4 0 0 1-3.002-2.023 9.4 9.4 0 0 1-2.023-3.002 9.4 9.4 0 0 1-.743-3.676c0-.546.049-1.093.142-1.628q.025.048.051.095l-.034-.199-.017.103A5.6 5.6 0 0 1 2 7.615c0-1.493.582-2.898 1.637-3.953A5.56 5.56 0 0 1 7.59 2.024c.915 0 1.818.228 2.622.655l-.1.02.199.031q-.049-.026-.098-.051l.004-.001a9.5 9.5 0 0 1 1.788-.169 9.41 9.41 0 0 1 6.678 2.766 9.4 9.4 0 0 1 2.024 3.002 9.4 9.4 0 0 1 .743 3.676c0 .575-.054 1.15-.157 1.712q-.025-.047-.052-.095l.034.201q.009-.053.018-.106c.461.829.707 1.767.707 2.721m-5.183-2.248c0-1.331-.613-2.743-3.033-3.282l-2.209-.49c-.84-.192-1.807-.444-1.807-1.237s.679-1.348 1.903-1.348c2.468 0 2.243 1.696 3.468 1.696.645 0 1.209-.379 1.209-1.031 0-1.521-2.435-2.663-4.5-2.663-2.242 0-4.63.952-4.63 3.488 0 1.221.436 2.521 2.839 3.123l2.984.745c.903.223 1.129.731 1.129 1.189 0 .762-.758 1.507-2.129 1.507-2.679 0-2.307-2.062-3.743-2.062-.645 0-1.113.444-1.113 1.078 0 1.236 1.501 2.886 4.856 2.886 3.195 0 4.776-1.538 4.776-3.599"})))},{name:"sms",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M17.696 4C20.069 4 22 5.973 22 8.398v4.357c0 2.04-1.368 3.783-3.261 4.266v4.427l-5.234-4.295h-7.2C3.93 17.153 2 15.18 2 12.755V8.398C2 5.973 3.931 4 6.304 4zM7.028 8.515c-.98 0-1.66.562-1.66 1.349-.009.497.322.91.985 1.178l.39.142c.242.097.305.171.305.297 0 .162-.131.251-.442.251s-.76-.135-1.004-.284l-.112.046-.215.868c.359.258.832.364 1.33.364 1.104 0 1.764-.523 1.764-1.333-.008-.574-.305-.956-.954-1.216l-.393-.146c-.266-.108-.341-.181-.341-.287 0-.152.131-.243.387-.243.274 0 .587.093.808.214l.109-.047.214-.837c-.315-.224-.741-.316-1.171-.316m10.302 0c-.98 0-1.66.562-1.66 1.349-.008.497.322.91.985 1.178l.39.142c.243.097.305.171.305.297 0 .162-.13.251-.442.251-.311 0-.76-.135-1.004-.284l-.112.046-.215.868c.359.258.832.364 1.33.364 1.104 0 1.764-.523 1.764-1.333-.008-.574-.305-.956-.954-1.216l-.393-.146c-.266-.108-.341-.181-.341-.287 0-.152.131-.243.387-.243.274 0 .587.093.808.214l.109-.047.214-.837c-.316-.224-.741-.316-1.171-.316m-3.733 0c-.297 0-.55.066-.78.202l-.144.098a2 2 0 0 0-.264.247l-.078.095-.027-.077c-.15-.34-.55-.565-1.033-.565l-.169.007a1.36 1.36 0 0 0-.896.42l-.08.09-.038-.363-.075-.067H8.994l-.075.079.024.634c.005.2.008.397.008.604v2.652l.075.075h1.178l.075-.075v-2.269q-.002-.168.042-.274c.083-.23.262-.392.496-.392.314 0 .483.267.483.753v2.182l.075.075h1.179l.075-.075v-2.277c0-.097.016-.213.043-.285.077-.224.26-.373.486-.373.33 0 .5.272.5.817v2.118l.074.075h1.179l.075-.075v-2.293c0-1.131-.537-1.763-1.39-1.763Z"})))},{name:"snapchat",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M11.989 1.728c3.221.001 5.904 2.683 5.908 5.912q.002 1.133.067 2.094a.737.737 0 0 0 .902.669l1.009-.237a.6.6 0 0 1 .129-.015c.256 0 .492.175.55.434a.74.74 0 0 1-.479.861l-1.532.618a.823.823 0 0 0-.485.98c1.229 4.543 4.661 4.071 4.661 4.662 0 .743-2.587.848-2.821 1.082s-.01 1.368-.532 1.588a1.1 1.1 0 0 1-.409.056c-.393 0-.95-.077-1.536-.077-.509 0-1.04.058-1.507.273-1.239.572-2.433 1.641-3.914 1.641S9.325 21.2 8.086 20.628c-.467-.216-.998-.273-1.507-.273-.586 0-1.143.077-1.536.077-.17 0-.31-.014-.409-.056-.522-.22-.299-1.354-.532-1.588s-2.821-.337-2.821-1.08c0-.592 3.432-.119 4.661-4.662a.824.824 0 0 0-.486-.98l-1.532-.618a.74.74 0 0 1-.479-.861.56.56 0 0 1 .679-.419l1.009.237q.086.02.169.02a.737.737 0 0 0 .733-.689q.065-.961.067-2.094c.004-3.229 2.666-5.91 5.887-5.912m0-1.281c-.961 0-1.898.194-2.784.574A7.2 7.2 0 0 0 6.93 2.572a7.2 7.2 0 0 0-1.539 2.282A7.1 7.1 0 0 0 4.82 7.64a33 33 0 0 1-.029 1.369l-.375-.088a2 2 0 0 0-.421-.049 1.86 1.86 0 0 0-1.135.389 1.84 1.84 0 0 0-.666 1.049 2.024 2.024 0 0 0 1.271 2.335l1.124.454c-.744 2.285-2.117 2.723-3.041 3.018a5 5 0 0 0-.659.246C.087 16.76 0 17.436 0 17.708c0 .521.247.996.694 1.339.223.17.499.311.844.43.47.162 1.016.265 1.459.347.021.164.053.341.106.518.22.738.684 1.069 1.034 1.217.332.14.676.156.905.156.224 0 .462-.018.713-.036.269-.02.548-.041.823-.041.426 0 .743.051.97.155.311.144.64.337.989.542.972.571 2.073 1.217 3.462 1.217s2.49-.647 3.462-1.217c.349-.205.679-.399.989-.542.226-.105.544-.155.97-.155.275 0 .554.021.823.041.251.019.488.036.713.036.229 0 .573-.016.905-.156.35-.147.814-.478 1.034-1.217.053-.178.084-.354.106-.518.443-.082.989-.185 1.459-.347.345-.119.621-.259.844-.43.448-.342.694-.818.694-1.339 0-.272-.087-.948-.891-1.347a5 5 0 0 0-.659-.246c-.924-.295-2.297-.733-3.041-3.018l1.124-.454a2.025 2.025 0 0 0 1.271-2.335 1.83 1.83 0 0 0-.666-1.049 1.86 1.86 0 0 0-1.556-.34l-.375.088a33 33 0 0 1-.029-1.369 7.1 7.1 0 0 0-.575-2.789c-.365-.853-.886-1.62-1.547-2.282s-1.428-1.182-2.28-1.547a7.1 7.1 0 0 0-2.786-.574"})))},{name:"soundcloud",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M23.587 13.923a3.303 3.303 0 0 1-3.344 3.117h-8.037a.674.674 0 0 1-.667-.67V7.717a.74.74 0 0 1 .444-.705s.739-.512 2.296-.512a5.27 5.27 0 0 1 2.702.742 5.35 5.35 0 0 1 2.516 3.485 3.1 3.1 0 0 1 .852-.116 3.217 3.217 0 0 1 3.237 3.312m-13.05-5.659c.242 2.935.419 5.612 0 8.538a.261.261 0 0 1-.519 0c-.39-2.901-.221-5.628 0-8.538a.26.26 0 0 1 .398-.25.26.26 0 0 1 .12.25zm-1.627 8.541a.273.273 0 0 1-.541 0 32.7 32.7 0 0 1 0-7.533.274.274 0 0 1 .544 0 29.4 29.4 0 0 1-.003 7.533m-1.63-7.788c.264 2.69.384 5.099-.003 7.782a.262.262 0 0 1-.522 0c-.374-2.649-.249-5.127 0-7.782a.264.264 0 0 1 .525 0m-1.631 7.792a.268.268 0 0 1-.532 0 27.6 27.6 0 0 1 0-7.034.27.27 0 1 1 .541 0 25.8 25.8 0 0 1-.01 7.034zm-1.63-5.276c.412 1.824.227 3.435-.015 5.294a.255.255 0 0 1-.504 0c-.22-1.834-.402-3.482-.015-5.295a.268.268 0 0 1 .535 0m-1.626-.277c.378 1.869.254 3.451-.01 5.325-.031.277-.506.28-.531 0-.239-1.846-.352-3.476-.01-5.325a.277.277 0 0 1 .551 0m-1.643.907c.396 1.239.261 2.246-.016 3.517a.258.258 0 0 1-.514 0c-.239-1.246-.336-2.274-.021-3.517a.276.276 0 0 1 .55 0z"})))},{name:"spotify",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m4.586 14.424a.62.62 0 0 1-.857.207c-2.348-1.435-5.304-1.76-8.785-.964a.622.622 0 1 1-.277-1.215c3.809-.871 7.077-.496 9.713 1.115a.623.623 0 0 1 .206.857M17.81 13.7a.78.78 0 0 1-1.072.257c-2.687-1.652-6.785-2.131-9.965-1.166A.779.779 0 1 1 6.32 11.3c3.632-1.102 8.147-.568 11.234 1.328a.78.78 0 0 1 .256 1.072m.105-2.835c-3.223-1.914-8.54-2.09-11.618-1.156a.935.935 0 1 1-.542-1.79c3.532-1.072 9.404-.865 13.115 1.338a.936.936 0 1 1-.955 1.608"})))},{name:"squarespace",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20.87 9.271a3.86 3.86 0 0 0-5.458 0l-6.141 6.141a.964.964 0 1 0 1.365 1.364l6.14-6.14a1.929 1.929 0 1 1 2.729 2.729l-6.022 6.022a1.93 1.93 0 0 0 2.729 0l4.658-4.658a3.86 3.86 0 0 0 0-5.458m-2.047 2.047a.965.965 0 0 0-1.365 0l-6.14 6.14a1.93 1.93 0 0 1-2.729 0 .964.964 0 1 0-1.364 1.364 3.86 3.86 0 0 0 5.458 0l6.14-6.14a.966.966 0 0 0 0-1.364m-2.047-6.141a3.86 3.86 0 0 0-5.458 0l-6.14 6.14a.964.964 0 1 0 1.364 1.364l6.141-6.14a1.93 1.93 0 0 1 2.729 0 .965.965 0 1 0 1.364-1.364m-2.047 2.047a.964.964 0 0 0-1.364 0l-6.14 6.141a1.929 1.929 0 1 1-2.729-2.729l6.022-6.022a1.93 1.93 0 0 0-2.729 0L3.13 9.271a3.86 3.86 0 0 0 5.458 5.458l6.14-6.141a.963.963 0 0 0 .001-1.364"})))},{name:"stackexchange",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M4 11.606h16v3.272H4zM4 7.377h16v3.272H4zM17.514 3H6.55C5.147 3 4 4.169 4 5.614v.848h16v-.85C20 4.167 18.895 3 17.514 3M4 15.813v.85c0 1.445 1.147 2.614 2.55 2.614h6.799v3.463l3.357-3.463h.744c1.402 0 2.55-1.169 2.55-2.614v-.85z"})))},{name:"stackoverflow",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M18.18 20.103V14.78h1.767v7.09H4v-7.09h1.767v5.323z"}),React.createElement("path",{d:"m7.717 14.275 8.673 1.813.367-1.744-8.673-1.813zm1.147-4.13 8.031 3.74.734-1.606-8.031-3.763zm2.226-3.946 6.815 5.667 1.124-1.354-6.815-5.667zM15.495 2l-1.423 1.055 5.277 7.113 1.423-1.055zM7.533 18.314h8.857v-1.767H7.533z"})))},{name:"stumbleupon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 4.294a4.47 4.47 0 0 0-4.471 4.471v6.353a1.059 1.059 0 1 1-2.118 0v-2.824H2v2.941a4.471 4.471 0 0 0 8.942 0v-6.47a1.059 1.059 0 1 1 2.118 0v1.294l1.412.647 2-.647V8.765A4.473 4.473 0 0 0 12 4.294m1.059 8.059v2.882a4.471 4.471 0 0 0 8.941 0v-2.824h-3.412v2.824a1.059 1.059 0 1 1-2.118 0v-2.882l-2 .647z"})))},{name:"substack",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.904 9.182H4.095V7.054h15.81v2.127M4.095 11.109V21L12 16.583 19.905 21v-9.891zM19.905 3H4.095v2.127h15.81z"})))},{name:"telegram",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m3.08 14.757s-.25.625-.936.325l-2.541-1.949-1.63 1.486s-.127.096-.266.036c0 0-.12-.011-.27-.486s-.911-2.972-.911-2.972L6 12.349s-.387-.137-.425-.438c-.037-.3.437-.462.437-.462l10.03-3.934s.824-.362.824.238z"})))},{name:"threads",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 192 192"},React.createElement("g",null,React.createElement("path",{d:"M141.537 88.988a67 67 0 0 0-2.518-1.143c-1.482-27.307-16.403-42.94-41.457-43.1h-.34c-14.986 0-27.449 6.396-35.12 18.036l13.779 9.452c5.73-8.695 14.724-10.548 21.348-10.548h.229c8.249.053 14.474 2.452 18.503 7.129 2.932 3.405 4.893 8.111 5.864 14.05-7.314-1.243-15.224-1.626-23.68-1.14-23.82 1.371-39.134 15.264-38.105 34.568.522 9.792 5.4 18.216 13.735 23.719 7.047 4.652 16.124 6.927 25.557 6.412 12.458-.683 22.231-5.436 29.049-14.127 5.178-6.6 8.453-15.153 9.899-25.93 5.937 3.583 10.337 8.298 12.767 13.966 4.132 9.635 4.373 25.468-8.546 38.376-11.319 11.308-24.925 16.2-45.488 16.351-22.809-.169-40.06-7.484-51.275-21.742C35.236 139.966 29.808 120.682 29.605 96c.203-24.682 5.63-43.966 16.133-57.317C56.954 24.425 74.204 17.11 97.013 16.94c22.975.17 40.526 7.52 52.171 21.847 5.71 7.026 10.015 15.86 12.853 26.162l16.147-4.308c-3.44-12.68-8.853-23.606-16.219-32.668C147.036 9.607 125.202.195 97.07 0h-.113C68.882.194 47.292 9.642 32.788 28.08 19.882 44.485 13.224 67.315 13.001 95.932L13 96v.067c.224 28.617 6.882 51.447 19.788 67.854C47.292 182.358 68.882 191.806 96.957 192h.113c24.96-.173 42.554-6.708 57.048-21.189 18.963-18.945 18.392-42.692 12.142-57.27-4.484-10.454-13.033-18.945-24.723-24.553M98.44 129.507c-10.44.588-21.286-4.098-21.82-14.135-.397-7.442 5.296-15.746 22.461-16.735q2.948-.17 5.79-.169c6.235 0 12.068.606 17.371 1.765-1.978 24.702-13.58 28.713-23.802 29.274"})))},{name:"tiktok-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M5 3a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2zm7.531 3h2.053s-.114 2.635 2.85 2.82v2.04s-1.582.099-2.85-.87l.021 4.207a3.804 3.804 0 1 1-3.802-3.802h.533v2.082a1.73 1.73 0 0 0-1.922.648 1.727 1.727 0 0 0 1.947 2.646 1.73 1.73 0 0 0 1.19-1.642z"})))},{name:"tiktok",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.22 2h3.42s-.19 4.394 4.75 4.702v3.396s-2.636.166-4.75-1.448l.037 7.012a6.338 6.338 0 1 1-6.34-6.339h.89v3.472a2.882 2.882 0 1 0 2.024 2.752z"})))},{name:"tripadvisor",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.01 9.859c.236-1.002.985-2.003.985-2.003l-3.341-.002C16.779 6.643 14.502 6 11.979 6 9.363 6 7 6.659 5.135 7.877L2 7.88s.74.988.98 1.983a4.98 4.98 0 0 0-.977 2.961 5.01 5.01 0 0 0 5.009 5.003 5 5 0 0 0 3.904-1.875l1.065 1.592 1.076-1.606a4.96 4.96 0 0 0 1.838 1.448 4.98 4.98 0 0 0 3.831.151 5.01 5.01 0 0 0 2.963-6.431 5 5 0 0 0-.679-1.247m-13.998 6.96a4 4 0 0 1-3.998-3.995 4 4 0 0 1 3.998-3.997 4 4 0 0 1 3.996 3.997 4 4 0 0 1-3.996 3.995m4.987-4.36A5.007 5.007 0 0 0 7.11 7.821c1.434-.613 3.081-.947 4.867-.947 1.798 0 3.421.324 4.853.966a4.984 4.984 0 0 0-4.831 4.619m6.288 4.134a3.97 3.97 0 0 1-3.058-.122 3.96 3.96 0 0 1-2.075-2.245v-.001a3.97 3.97 0 0 1 .118-3.056 3.97 3.97 0 0 1 2.246-2.077 4.005 4.005 0 0 1 5.135 2.366 4.006 4.006 0 0 1-2.366 5.135"}),React.createElement("path",{d:"M6.949 10.307a2.477 2.477 0 0 0-2.475 2.472 2.48 2.48 0 0 0 2.475 2.474 2.474 2.474 0 0 0 0-4.946m0 4.094a1.626 1.626 0 0 1-1.624-1.623 1.621 1.621 0 1 1 1.624 1.623M16.981 10.307a2.477 2.477 0 0 0-2.474 2.472 2.48 2.48 0 0 0 2.474 2.474 2.476 2.476 0 0 0 2.472-2.474 2.475 2.475 0 0 0-2.472-2.472m0 4.094a1.625 1.625 0 0 1-1.622-1.623 1.622 1.622 0 1 1 1.622 1.623"}),React.createElement("path",{d:"M7.778 12.778a.832.832 0 1 1-1.664.002.832.832 0 0 1 1.664-.002M16.981 11.947a.832.832 0 1 0 .002 1.666.832.832 0 0 0-.002-1.666"})))},{name:"tumblr-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M16.749 17.396c-.357.17-1.041.319-1.551.332-1.539.041-1.837-1.081-1.85-1.896V9.847h3.861v-2.91h-3.847V2.039h-2.817c-.046 0-.127.041-.138.144-.165 1.499-.867 4.13-3.783 5.181v2.484h1.945v6.282c0 2.151 1.587 5.206 5.775 5.135 1.413-.024 2.982-.616 3.329-1.126z"})))},{name:"tumblr",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2m-5.569 14.265c-2.446.042-3.372-1.742-3.372-2.998v-3.668H8.923v-1.45c1.703-.614 2.113-2.15 2.209-3.025.007-.06.054-.084.081-.084h1.645V8.9h2.246v1.7H12.85v3.495c.008.476.182 1.131 1.081 1.107.298-.008.697-.094.906-.194l.54 1.601c-.205.296-1.121.641-1.946.656"})))},{name:"twitch",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M16.499 8.089h-1.636v4.91h1.636zm-4.499 0h-1.637v4.91H12zM4.228 3.178 3 6.451v13.092h4.499V22h2.456l2.454-2.456h3.681L21 14.636V3.178zm15.136 10.638L16.5 16.681H12l-2.453 2.453V16.68H5.863V4.814h13.501z"})))},{name:"twitter-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M22.23 5.924a8.2 8.2 0 0 1-2.357.646 4.12 4.12 0 0 0 1.804-2.27 8.2 8.2 0 0 1-2.606.996 4.103 4.103 0 0 0-6.991 3.742 11.65 11.65 0 0 1-8.457-4.287 4.1 4.1 0 0 0-.556 2.063 4.1 4.1 0 0 0 1.825 3.415 4.1 4.1 0 0 1-1.859-.513v.052a4.104 4.104 0 0 0 3.292 4.023 4.1 4.1 0 0 1-1.853.07 4.11 4.11 0 0 0 3.833 2.85 8.24 8.24 0 0 1-5.096 1.756 8 8 0 0 1-.979-.057 11.6 11.6 0 0 0 6.29 1.843c7.547 0 11.675-6.252 11.675-11.675q0-.267-.012-.531a8.3 8.3 0 0 0 2.047-2.123"})))},{name:"twitter",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2m-2.534 6.71q.007.148.007.298c0 3.045-2.318 6.556-6.556 6.556a6.5 6.5 0 0 1-3.532-1.035q.27.032.55.032a4.63 4.63 0 0 0 2.862-.986 2.31 2.31 0 0 1-2.152-1.6 2.3 2.3 0 0 0 1.04-.04 2.306 2.306 0 0 1-1.848-2.259v-.029c.311.173.666.276 1.044.288a2.303 2.303 0 0 1-.713-3.076 6.54 6.54 0 0 0 4.749 2.407 2.305 2.305 0 0 1 3.926-2.101 4.6 4.6 0 0 0 1.463-.559 2.3 2.3 0 0 1-1.013 1.275c.466-.056.91-.18 1.323-.363-.31.461-.7.867-1.15 1.192"})))},{name:"untappd",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m11 13.299-5.824 8.133c-.298.416-.8.635-1.308.572-.578-.072-1.374-.289-2.195-.879S.392 19.849.139 19.323a1.4 1.4 0 0 1 .122-1.425l5.824-8.133a3.1 3.1 0 0 1 1.062-.927l1.146-.604c.23-.121.436-.283.608-.478.556-.631 2.049-2.284 4.696-4.957l.046-.212a.13.13 0 0 1 .096-.1l.146-.037a.135.135 0 0 0 .101-.141l-.015-.18a.13.13 0 0 1 .125-.142c.176-.005.518.046 1.001.393s.64.656.692.824a.13.13 0 0 1-.095.164l-.175.044a.13.13 0 0 0-.101.141l.012.15a.13.13 0 0 1-.063.123l-.186.112c-1.679 3.369-2.764 5.316-3.183 6.046a2.2 2.2 0 0 0-.257.73l-.205 1.281A3.1 3.1 0 0 1 11 13.3zm12.739 4.598-5.824-8.133a3.1 3.1 0 0 0-1.062-.927l-1.146-.605a2.1 2.1 0 0 1-.608-.478 51 51 0 0 0-.587-.654.09.09 0 0 0-.142.018 97 97 0 0 1-1.745 3.223 1.4 1.4 0 0 0-.171.485 3.5 3.5 0 0 0 0 1.103l.01.064c.075.471.259.918.536 1.305l5.824 8.133c.296.413.79.635 1.294.574a4.76 4.76 0 0 0 2.209-.881 4.76 4.76 0 0 0 1.533-1.802 1.4 1.4 0 0 0-.122-1.425zM8.306 3.366l.175.044a.134.134 0 0 1 .101.141l-.012.15a.13.13 0 0 0 .063.123l.186.112q.465.933.869 1.721c.026.051.091.06.129.019q.655-.703 1.585-1.668a.137.137 0 0 0 .003-.19c-.315-.322-.645-.659-1.002-1.02l-.046-.212a.13.13 0 0 0-.096-.099l-.146-.037a.135.135 0 0 1-.101-.141l.015-.18a.13.13 0 0 0-.123-.142c-.175-.005-.518.045-1.002.393-.483.347-.64.656-.692.824a.13.13 0 0 0 .095.164z"})))},{name:"vimeo",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M22.396 7.164q-.139 3.039-4.245 8.32Q13.907 21 10.97 21q-1.82 0-3.079-3.359l-1.68-6.159q-.934-3.36-2.005-3.36-.234.001-1.634.98l-.978-1.261q1.541-1.353 3.037-2.708 2.056-1.774 3.084-1.869 2.429-.234 2.99 3.321.607 3.836.841 4.769.7 3.181 1.542 3.181.653 0 1.963-2.065 1.307-2.063 1.401-3.142.187-1.781-1.401-1.782-.747.001-1.541.341 1.534-5.024 5.862-4.884 3.21.095 3.024 4.161"})))},{name:"vk",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{fillRule:"evenodd",d:"M1.687 1.687C0 3.374 0 6.09 0 11.52v.96c0 5.431 0 8.146 1.687 9.833S6.09 24 11.52 24h.96c5.431 0 8.146 0 9.833-1.687S24 17.91 24 12.48v-.96c0-5.431 0-8.146-1.687-9.833S17.91 0 12.48 0h-.96C6.09 0 3.374 0 1.687 1.687M4.05 7.3c.13 6.24 3.25 9.99 8.72 9.99h.31v-3.57c2.01.2 3.53 1.67 4.14 3.57h2.84c-.78-2.84-2.83-4.41-4.11-5.01 1.28-.74 3.08-2.54 3.51-4.98h-2.58c-.56 1.98-2.22 3.78-3.8 3.95V7.3H10.5v6.92c-1.6-.4-3.62-2.34-3.71-6.92z"})))},{name:"whatsapp",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m2.048 22 1.406-5.136a9.9 9.9 0 0 1-1.323-4.955C2.133 6.446 6.579 2 12.042 2a9.85 9.85 0 0 1 7.011 2.906 9.85 9.85 0 0 1 2.9 7.011c-.002 5.464-4.448 9.91-9.91 9.91h-.004a9.9 9.9 0 0 1-4.736-1.206zm5.497-3.172.301.179a8.2 8.2 0 0 0 4.193 1.148h.003c4.54 0 8.235-3.695 8.237-8.237a8.2 8.2 0 0 0-2.41-5.828 8.18 8.18 0 0 0-5.824-2.416c-4.544 0-8.239 3.695-8.241 8.237a8.2 8.2 0 0 0 1.259 4.384l.196.312-.832 3.04zm9.49-4.554c-.062-.103-.227-.165-.475-.289s-1.465-.723-1.692-.806-.392-.124-.557.124-.64.806-.784.971-.289.186-.536.062-1.046-.385-1.991-1.229c-.736-.657-1.233-1.468-1.378-1.715s-.015-.382.109-.505c.111-.111.248-.289.371-.434.124-.145.165-.248.248-.413s.041-.31-.021-.434-.557-1.343-.763-1.839c-.202-.483-.407-.417-.559-.425-.144-.007-.31-.009-.475-.009a.9.9 0 0 0-.66.31c-.226.248-.866.847-.866 2.066s.887 2.396 1.011 2.562 1.746 2.666 4.23 3.739c.591.255 1.052.408 1.412.522.593.189 1.133.162 1.56.098.476-.071 1.465-.599 1.671-1.177.206-.58.206-1.075.145-1.179"})))},{name:"woocommerce",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19 2H5C3.3 2 2 3.3 2 5v11c0 1.7 1.3 3 3 3h4l6 3-1-3h5c1.7 0 3-1.3 3-3V5c0-1.7-1.3-3-3-3m-1.6 4.5c-.4.8-.8 2.1-1 3.9-.3 1.8-.4 3.1-.3 4.1 0 .3 0 .5-.1.7s-.3.4-.6.4-.6-.1-.9-.4c-1-1-1.8-2.6-2.4-4.6-.7 1.4-1.2 2.4-1.6 3.1-.6 1.2-1.2 1.8-1.6 1.9-.3 0-.5-.2-.8-.7-.5-1.4-1.1-4.2-1.7-8.2 0-.3 0-.5.2-.7.1-.2.4-.3.7-.4.5 0 .9.2.9.8.3 2.3.7 4.2 1.1 5.7l2.4-4.5c.2-.4.4-.6.8-.6q.75 0 .9.9c.3 1.4.6 2.6 1 3.7.3-2.7.8-4.7 1.4-5.9.2-.3.4-.5.7-.5.2 0 .5.1.7.2q.3.3.3.6c0 .3 0 .4-.1.5"})))},{name:"wordpress",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.158 12.786 9.46 20.625a9 9 0 0 0 5.526-.144 1 1 0 0 1-.065-.124zM3.009 12a8.99 8.99 0 0 0 5.067 8.092L3.788 8.341A8.95 8.95 0 0 0 3.009 12m15.06-.454c0-1.112-.399-1.881-.741-2.48-.456-.741-.883-1.368-.883-2.109 0-.826.627-1.596 1.51-1.596q.06.002.116.007A8.96 8.96 0 0 0 12 3.009a8.98 8.98 0 0 0-7.512 4.052c.211.007.41.011.579.011.94 0 2.396-.114 2.396-.114.484-.028.541.684.057.741 0 0-.487.057-1.029.085l3.274 9.739 1.968-5.901-1.401-3.838c-.484-.028-.943-.085-.943-.085-.485-.029-.428-.769.057-.741 0 0 1.484.114 2.368.114.94 0 2.397-.114 2.397-.114.485-.028.542.684.057.741 0 0-.488.057-1.029.085l3.249 9.665.897-2.996q.684-1.753.684-2.907m1.82-3.86q.06.428.06.924c0 .912-.171 1.938-.684 3.22l-2.746 7.94a8.98 8.98 0 0 0 4.47-7.771 8.9 8.9 0 0 0-1.1-4.313M12 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10"})))},{name:"x",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M13.982 10.622 20.54 3h-1.554l-5.693 6.618L8.745 3H3.5l6.876 10.007L3.5 21h1.554l6.012-6.989L15.868 21h5.245zm-2.128 2.474-.697-.997-5.543-7.93H8l4.474 6.4.697.996 5.815 8.318h-2.387z"})))},{name:"xanga",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M9 9h6v6H9zM3 9h6V3H3zm12 0h6V3h-6zm0 12h6v-6h-6zM3 21h6v-6H3z"})))},{name:"youtube",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.8 8.001s-.195-1.378-.795-1.985c-.76-.797-1.613-.801-2.004-.847-2.799-.202-6.997-.202-6.997-.202h-.009s-4.198 0-6.997.202c-.39.047-1.242.051-2.003.847-.6.607-.795 1.985-.795 1.985S2 9.62 2 11.238v1.517c0 1.618.2 3.237.2 3.237s.195 1.378.795 1.985c.761.797 1.76.771 2.205.855 1.6.153 6.8.201 6.8.201s4.203-.006 7.001-.209c.391-.047 1.243-.051 2.004-.847.6-.607.795-1.985.795-1.985s.2-1.618.2-3.237v-1.517c0-1.618-.2-3.237-.2-3.237M9.935 14.594l-.001-5.62 5.404 2.82z"})))}]},8992:(e,t,a)=>{"use strict";a(6072);var n=a(8120),r=a.n(n),c=a(1609);a(1135);c.PureComponent,r().string.isRequired,r().number,r().func,r().string},295:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(1455),r=a.n(n),c=a(6185),s=a.n(c);const i={getWaf:()=>r()({path:"jetpack-protect/v1/waf",method:"GET"}).then(s()),toggleWaf:()=>r()({method:"POST",path:"jetpack-protect/v1/toggle-waf"}),updateWaf:e=>r()({method:"POST",path:"jetpack/v4/waf",data:e}).then(s()),wafSeen:()=>r()({path:"jetpack-protect/v1/waf-seen",method:"POST"}),wafUpgradeSeen:()=>r()({path:"jetpack-protect/v1/waf-upgrade-seen",method:"POST"}),getOnboardingProgress:()=>r()({path:"jetpack-protect/v1/onboarding-progress",method:"GET"}),completeOnboardingSteps:e=>r()({path:"jetpack-protect/v1/onboarding-progress",method:"POST",data:{step_ids:e}}),getScanHistory:()=>r()({path:"jetpack-protect/v1/scan-history",method:"GET"}).then(s()),scan:()=>r()({path:"jetpack-protect/v1/scan",method:"POST"}),getScanStatus:()=>r()({path:"jetpack-protect/v1/status?hard_refresh=true",method:"GET"}).then(s()),fixThreats:e=>r()({path:"jetpack-protect/v1/fix-threats",method:"POST",data:{threat_ids:e}}).then(s()),getFixersStatus:e=>{const t=e.reduce(((e,t)=>`${e}threat_ids[]=${t}&`),"jetpack-protect/v1/fix-threats-status?");return r()({path:t,method:"GET"}).then(s())},ignoreThreat:e=>r()({path:`jetpack-protect/v1/ignore-threat?threat_id=${e}`,method:"POST"}),unIgnoreThreat:e=>r()({path:`jetpack-protect/v1/unignore-threat?threat_id=${e}`,method:"POST"}),checkCredentials:()=>r()({path:"jetpack-protect/v1/check-credentials",method:"POST"}),checkPlan:()=>r()({path:"jetpack-protect/v1/check-plan",method:"GET"}),getProductData:()=>r()({path:"/my-jetpack/v1/site/products?products=scan",method:"GET"}).then((e=>s()(e?.scan)))}},1186:(e,t,a)=>{"use strict";a.d(t,{A:()=>f});var n=a(6072),r=a.n(n),c=a(2947),s=a(1608),i=a(5918),o=a(9384),l=a(7723),u=a(1609),d=a(9539),p=a(4537),m=a(9701),h=a(3041),g=a(241),v=a(1517);const __=l.__,f=({children:e})=>{const{notice:t}=(0,p.A)(),{isRegistered:a}=(0,o.useConnection)(),n=(0,d.Zp)(),{counts:{current:{threats:f}}}=(0,m.A)();return(0,u.useEffect)((()=>{a||n("/setup")}),[a,n]),a?React.createElement(c.A,{moduleName:__("Jetpack Protect","jetpack-protect"),header:React.createElement(s.A,null)},t&&React.createElement(h.A,r()({floating:!0,dismissable:!0},t)),React.createElement(i.A,{horizontalSpacing:0},React.createElement(g.A,{className:v.A.navigation},React.createElement(g.o,{link:"/scan",label:React.createElement("span",{className:v.A.tab},f>0?(0,l.sprintf)( -// translators: %d is the number of threats found. -__("Scan (%d)","jetpack-protect"),f):__("Scan","jetpack-protect"))}),React.createElement(g.o,{link:"/firewall",label:__("Firewall","jetpack-protect")}))),e):null}},7715:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(5918),r=a(8509),c=a(9384),s=a(6900);const i=()=>{const{hasConnectionError:e}=(0,c.useConnectionErrorNotice)();return React.createElement(n.A,{horizontalSpacing:0},e&&React.createElement(r.A,{className:s.A["connection-error-col"]},React.createElement(c.ConnectionError,null)),React.createElement(r.A,null,React.createElement("div",{id:"jp-admin-notices",className:"my-jetpack-jitm-card"})))}},7031:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(766),r=a(8478),c=a(7425),s=a(3127),i=a(7715),o=a(6900);const l=({main:e,secondary:t,preserveSecondaryOnMobile:a=!0,spacing:r=7})=>React.createElement(n.A,null,React.createElement(i.A,null),React.createElement(s.A,{spacing:r,gap:0,main:e,mainClassName:o.A["header-main"],secondary:t,secondaryClassName:o.A["header-secondary"],preserveSecondaryOnMobile:a,fluid:!1}));l.Heading=({children:e,showIcon:t=!1})=>{const a=(0,r.Wy)("protect");return React.createElement(c.H3,{className:o.A.heading,mt:2,mb:2},e,t&&React.createElement(a,{className:o.A["heading-icon"],size:32}))},l.Subheading=({children:e})=>React.createElement("div",{className:o.A.subheading},e);const u=l},4907:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var n=a(6072),r=a.n(n),c=a(1112),s=a(6427),i=a(1609),o=a.n(i),l=a(3902);function u({children:e,...t}){return o().createElement(s.ButtonGroup,r()({className:l.A["button-group"]},t),e)}u.Button=e=>o().createElement(c.A,e);const d=u},5747:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(6461),r=a(7723),c=a(2605),s=a(9417),i=a(9370);const __=r.__,o=({children:e})=>{const{data:t,isLoading:a}=(0,c.A)();return a?React.createElement("div",{className:i.A.loading},React.createElement(n.A,{color:"black",style:{color:"black",marginTop:0,marginLeft:0}}),React.createElement("p",{className:i.A.loading__message},__("Checking credentials…","jetpack-protect"))):t&&0!==t.length?e:React.createElement(s.A,null)}},9417:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(7425),r=a(1112),c=a(3924),s=a(7115),i=a(7723),o=a(1609),l=a(8140),u=a(2605),d=a(1009),p=a(3041),m=a(2148);const __=i.__,h=()=>{const e=(0,s.jE)(),{setModal:t}=(0,d.A)(),{data:a}=(0,u.A)(),{siteSuffix:i,blogID:h}=window.jetpackProtectInitialState;return(0,o.useEffect)((()=>{const t=setInterval((()=>{a&&0!==a.length||e.invalidateQueries({queryKey:[l.oA]})}),5e3);return()=>clearInterval(t)}),[e,a]),React.createElement(React.Fragment,null,React.createElement(n.Ay,{variant:"title-medium",mb:2},__("Site credentials needed","jetpack-protect")),React.createElement(p.A,{type:"info",message:__("Before Jetpack Protect can auto-fix threats on your site, it needs your server credentials.","jetpack-protect")}),React.createElement(n.Ay,{mb:3},__("Your server credentials allow Jetpack Protect to access the server that’s powering your website. This information is securely saved and only used to perform fix threats detected on your site.","jetpack-protect")),React.createElement(n.Ay,{mb:3},__("Once you’ve entered server credentials, Jetpack Protect will be fixing the selected threats.","jetpack-protect")),React.createElement("div",{className:m.A.footer},React.createElement(r.A,{variant:"secondary",onClick:e=>{e.preventDefault(),t({type:null})}},__("Not now","jetpack-protect")),React.createElement(r.A,{isExternalLink:!0,weight:"regular",href:(0,c.A)("jetpack-settings-security-credentials",{site:h??i})},__("Enter server credentials","jetpack-protect"))))}},2652:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(7425),r=a(7723),c=a(1113),s=a(3751),i=a(7031),o=a(9889),l=a(8842);const __=r.__,u=({baseErrorMessage:e,errorMessage:t,errorCode:a})=>{let r=t?`${t} (${a}).`:e;return r+=" "+__("Try again in a few minutes.","jetpack-protect"),React.createElement(i.A,{main:React.createElement(React.Fragment,null,React.createElement(i.A.Heading,null,React.createElement("div",{className:l.A.heading},React.createElement(c.A,{className:l.A.warning,icon:s.A,size:54}),__("An error occurred","jetpack-protect"))),React.createElement(i.A.Subheading,null,React.createElement(n.Ay,null,r)),React.createElement("div",{className:l.A["scan-navigation"]},React.createElement(o.A,null))),preserveSecondaryOnMobile:!1})}},8680:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var n=a(7425),r=a(1112),c=a(7723),s=a(1609),i=a(3657),o=a(1009),l=a(5747),u=a(1571),d=a(4031),p=a(4047);const __=c.__,m=({threatList:e=[]})=>{const{setModal:t}=(0,o.A)(),{fixThreats:a,isLoading:c}=(0,i.Ay)(),[m,h]=(0,s.useState)(e.map((({id:e})=>parseInt(e)))),g=(0,s.useCallback)((e=>{e.preventDefault(),t({type:null})}),[t]),v=(0,s.useCallback)((async e=>{e.preventDefault(),await a(m),t({type:null})}),[a,t,m]),f=(0,s.useCallback)(((e,t)=>{h(e?[...m,t.id]:m.filter((e=>e!==t.id)))}),[m]);return React.createElement(d.A,null,React.createElement(l.A,null,React.createElement(n.Ay,{variant:"title-medium",mb:2},__("Fix all threats","jetpack-protect")),React.createElement(n.Ay,{mb:3},__("Jetpack will be fixing the selected threats:","jetpack-protect")),React.createElement("div",{className:p.A.list},e.map((e=>React.createElement(u.A,{key:e.id,threat:e,fixAllDialog:!0,onCheckFix:f})))),React.createElement("div",{className:p.A.footer},React.createElement(r.A,{variant:"secondary",onClick:g},__("Cancel","jetpack-protect")),React.createElement(r.A,{isLoading:c,onClick:v,disabled:!m.length},__("Fix all threats","jetpack-protect")))))}},2607:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(7425),r=a(1112),c=a(7723),s=a(3657),i=a(1009),o=a(5747),l=a(1571),u=a(4031),d=a(2318);const __=c.__,p=({id:e,fixable:t,label:a,icon:c,severity:p})=>{const{setModal:m}=(0,i.A)(),{fixThreats:h,isLoading:g}=(0,s.Ay)();return React.createElement(u.A,null,React.createElement(o.A,null,React.createElement(n.Ay,{variant:"title-medium",mb:2},__("Fix Threat","jetpack-protect")),React.createElement(n.Ay,{mb:3},__("Jetpack will be fixing the selected threat:","jetpack-protect")),React.createElement("div",{className:d.A.list},React.createElement(l.A,{threat:{id:e,fixable:t,label:a,icon:c,severity:p},fixAllDialog:!1})),React.createElement("div",{className:d.A.footer},React.createElement(r.A,{variant:"secondary",onClick:e=>{e.preventDefault(),m({type:null})}},__("Cancel","jetpack-protect")),React.createElement(r.A,{isLoading:g,onClick:async t=>{t.preventDefault(),await h([e]),m({type:null})}},__("Fix threat","jetpack-protect")))))}},4114:(e,t,a)=>{"use strict";a.d(t,{A:()=>m,E:()=>p});var n=a(7425),r=a(1113),c=a(8248),s=a(4969),i=a(3022),o=a(1609),l=a.n(o),u=a(4493);const d=l().createContext(),p=({id:e,title:t,label:a,icon:p,children:m,onOpen:h})=>{const g=(0,o.useContext)(d),v=g?.open===e,f=g?.setOpen,y=(0,i.A)(u.A["accordion-body"],{[u.A["accordion-body-open"]]:v,[u.A["accordion-body-close"]]:!v}),E=(0,o.useCallback)((()=>{v||h?.(),f((t=>t===e?null:e))}),[v,h,f,e]);return l().createElement("div",{className:u.A["accordion-item"]},l().createElement("button",{className:u.A["accordion-header"],onClick:E},l().createElement("div",null,l().createElement(n.Ay,{className:u.A["accordion-header-label"],mb:1},l().createElement(r.A,{icon:p,className:u.A["accordion-header-label-icon"]}),a),l().createElement(n.Ay,{className:u.A["accordion-header-description"],variant:v?"title-small":"body"},t)),l().createElement("div",{className:u.A["accordion-header-button"]},l().createElement(r.A,{icon:v?c.A:s.A,size:38}))),l().createElement("div",{className:y,"aria-hidden":v?"false":"true"},m))},m=({children:e})=>{const[t,a]=(0,o.useState)();return l().createElement(d.Provider,{value:{open:t,setOpen:a}},l().createElement("div",{className:u.A.accordion},e))}},5920:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(3924),r=a(7425),c=a(1014),s=a(1112),i=a(6087),o=a(7723),l=a(1113),u=a(8847),d=a(1009),p=a(4031),m=a(4871);const __=o.__,h=({id:e,title:t,label:a,icon:o,severity:h})=>{const{setModal:g}=(0,d.A)(),v=(0,u.A)(),f=(0,n.A)("jetpack-protect-codeable-referral"),[y,E]=(0,i.useState)(!1);return React.createElement(p.A,null,React.createElement(r.Ay,{variant:"title-medium",mb:2},__("Do you really want to ignore this threat?","jetpack-protect")),React.createElement(r.Ay,{mb:3},__("Jetpack will ignore the threat:","jetpack-protect")),React.createElement("div",{className:m.A.threat},React.createElement(l.A,{icon:o,className:m.A.threat__icon}),React.createElement("div",{className:m.A.threat__summary},React.createElement(r.Ay,{className:m.A.threat__summary__label,mb:1},a),React.createElement(r.Ay,{className:m.A.threat__summary__title},t)),React.createElement("div",{className:m.A.threat__severity},React.createElement(c.A,{severity:h}))),React.createElement(r.Ay,{mb:4},(0,i.createInterpolateElement)(__("By choosing to ignore this threat, you acknowledge that you have reviewed the detected code. You are accepting the risks of maintaining a potentially malicious or vulnerable file on your site. If you are unsure, please request an estimate with Codeable.","jetpack-protect"),{codeableLink:React.createElement(s.A,{variant:"link",isExternalLink:!0,href:f})})),React.createElement("div",{className:m.A.footer},React.createElement(s.A,{variant:"secondary",onClick:e=>{e.preventDefault(),g({type:null})}},__("Cancel","jetpack-protect")),React.createElement(s.A,{isDestructive:!0,isLoading:y,onClick:async t=>{t.preventDefault(),E(!0),await v.mutateAsync(e),g({type:null}),E(!1)}},__("Ignore threat","jetpack-protect"))))}},9671:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});var n=a(8044);const r=()=>React.createElement("svg",{width:"440",height:"367",viewBox:"0 0 440 367",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:n.A.inProgressAnimation},React.createElement("g",{className:n.A.inProgressAnimation__el},React.createElement("g",{filter:"url(#filter_wordpress_el)"},React.createElement("rect",{className:"rect-1",x:"40",y:"211",width:"360",height:"116",rx:"4",fill:"white"})),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M127 269C127 253.572 114.428 241 99 241C83.544 241 71 253.572 71 269C71 284.456 83.544 297 99 297C114.428 297 127 284.456 127 269ZM92.784 284.036L83.236 258.416C84.776 258.36 86.512 258.192 86.512 258.192C87.912 258.024 87.744 255.028 86.344 255.084C86.344 255.084 82.284 255.392 79.708 255.392C79.204 255.392 78.672 255.392 78.084 255.364C82.536 248.532 90.236 244.108 99 244.108C105.524 244.108 111.46 246.544 115.94 250.66C114.036 250.352 111.32 251.752 111.32 255.084C111.32 256.898 112.286 258.455 113.372 260.205L113.372 260.205C113.527 260.454 113.683 260.706 113.84 260.964C114.82 262.672 115.38 264.772 115.38 267.852C115.38 272.024 111.46 281.852 111.46 281.852L102.976 258.416C104.488 258.36 105.272 257.94 105.272 257.94C106.672 257.8 106.504 254.44 105.104 254.524C105.104 254.524 101.072 254.86 98.44 254.86C96.004 254.86 91.916 254.524 91.916 254.524C90.516 254.44 90.348 257.884 91.748 257.94L94.324 258.164L97.852 267.712L92.784 284.036ZM119.809 268.837L119.748 269C117.719 274.341 115.706 279.728 113.696 285.105L113.696 285.106L113.696 285.106L113.694 285.111C112.986 287.004 112.279 288.896 111.572 290.784C119.048 286.472 123.892 278.212 123.892 269C123.892 264.688 122.912 260.712 120.952 257.1C121.794 263.568 120.5 267.002 119.809 268.837ZM88.08 291.652C79.736 287.62 74.108 278.884 74.108 269C74.108 265.36 74.752 262.056 76.124 258.948C76.9623 261.244 77.8006 263.542 78.6392 265.841L78.6401 265.843L78.6404 265.844C81.7786 274.446 84.9206 283.058 88.08 291.652ZM106.588 292.632L99.364 273.088C98.0331 277.014 96.6922 280.941 95.3474 284.879C94.4288 287.568 93.5084 290.264 92.588 292.968C94.604 293.584 96.788 293.892 99 293.892C101.66 293.892 104.18 293.444 106.588 292.632Z",fill:"#E9EFF5"}),React.createElement("path",{d:"M160 283C160 279.686 162.686 277 166 277H287C290.314 277 293 279.686 293 283C293 286.314 290.314 289 287 289H166C162.686 289 160 286.314 160 283Z",fill:"#E9EFF5"}),React.createElement("path",{d:"M160 255C160 251.686 162.686 249 166 249H360C363.314 249 366 251.686 366 255C366 258.314 363.314 261 360 261H166C162.686 261 160 258.314 160 255Z",fill:"#E9EFF5"})),React.createElement("g",{className:n.A.inProgressAnimation__el},React.createElement("g",{filter:"url(#filter_plugins_el)"},React.createElement("rect",{x:"72",y:"68",width:"168",height:"120",rx:"3",fill:"#A0C5D7"})),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M152 108L152 118H159.5V108L163.25 108V118H167C168.381 118 169.5 119.119 169.5 120.5V130.5L162 140.5V145.5C162 146.881 160.881 148 159.5 148H152C150.619 148 149.5 146.881 149.5 145.5V140.5L142 130.5V120.5C142 119.119 143.119 118 144.5 118H148.25L148.25 108L152 108ZM153.25 139.25V144.25H158.25V139.25L165.75 129.25V121.75H145.75V129.25L153.25 139.25Z",fill:"white"})),React.createElement("g",{className:n.A.inProgressAnimation__el},React.createElement("g",{filter:"url(#filter_themes_el)"},React.createElement("rect",{x:"272",y:"40",width:"96",height:"132",rx:"3",fill:"#EED77B"})),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M320.238 122.25C326.583 122.25 331.726 117.107 331.726 110.762C331.726 109.608 331.141 107.683 329.776 105.088C328.472 102.609 326.691 99.9488 324.845 97.4584C323.206 95.2483 321.561 93.2314 320.238 91.6723C318.915 93.2314 317.27 95.2483 315.631 97.4584C313.785 99.9488 312.004 102.609 310.7 105.088C309.335 107.683 308.75 109.608 308.75 110.762C308.75 117.107 313.893 122.25 320.238 122.25ZM317.739 88.8229C313.417 93.8726 305 104.507 305 110.762C305 119.178 311.822 126 320.238 126C328.654 126 335.476 119.178 335.476 110.762C335.476 104.507 327.06 93.8726 322.737 88.8229C321.243 87.078 320.238 86 320.238 86C320.238 86 319.233 87.078 317.739 88.8229Z",fill:"white"})),React.createElement("defs",null,React.createElement("filter",{id:"filter_wordpress_el",x:"0",y:"171",width:"440",height:"196",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},React.createElement("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),React.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),React.createElement("feOffset",null),React.createElement("feGaussianBlur",{stdDeviation:"20"}),React.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.08 0"}),React.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_2754_20065"}),React.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_2754_20065",result:"shape"})),React.createElement("filter",{id:"filter_plugins_el",x:"32",y:"28",width:"248",height:"200",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},React.createElement("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),React.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),React.createElement("feOffset",null),React.createElement("feGaussianBlur",{stdDeviation:"20"}),React.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.08 0"}),React.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_2754_20065"}),React.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_2754_20065",result:"shape"})),React.createElement("filter",{id:"filter_themes_el",x:"232",y:"0",width:"176",height:"212",filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},React.createElement("feFlood",{floodOpacity:"0",result:"BackgroundImageFix"}),React.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),React.createElement("feOffset",null),React.createElement("feGaussianBlur",{stdDeviation:"20"}),React.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.08 0"}),React.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_2754_20065"}),React.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_2754_20065",result:"shape"}))))},4440:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var n=a(7723),r=a(1113),c=a(991),s=a(1009),i=a(9417),o=a(8680),l=a(2607),u=a(5920),d=a(3144),p=a(9623),m=a(7259);const __=n.__,h={IGNORE_THREAT:u.A,UNIGNORE_THREAT:p.A,FIX_THREAT:l.A,FIX_ALL_THREATS:o.A,CREDENTIALS_NEEDED:i.A,STANDALONE_MODE:d.A},g=()=>{const{modal:e,setModal:t}=(0,s.A)();if(!e.type)return null;const a=h[e.type];return React.createElement("div",{className:m.A.modal},React.createElement("div",{className:m.A.modal__window},React.createElement("button",{onClick:e=>{e.preventDefault(),t({type:null})},className:m.A.modal__close,title:__("Close Modal Window","jetpack-protect")},React.createElement(r.A,{icon:c.A,size:24,className:m.A.modal__close__icon,"aria-label":__("Close Modal Window","jetpack-protect")})),React.createElement(a,e.props)))}},9278:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var n=a(7425),r=a(6427),c=a(7723),s=a(1113),i=a(9783),o=a(3883),l=a(8120),u=a.n(l),d=a(1609),p=a.n(d),m=a(2425),h=a(3066);const __=c.__,g=({count:e,checked:t})=>{const{data:a}=(0,m.Ay)(),{popoverText:c,badgeElement:l}=((e,t)=>t?0===e?{popoverText:__("No known threats found to affect this version","jetpack-protect"),badgeElement:p().createElement(s.A,{icon:o.A,size:28,className:h.A["navigation-item-check-badge"]})}:{popoverText:null,badgeElement:p().createElement(n.Ay,{variant:"body-extra-small",className:h.A["navigation-item-badge"],component:"div"},e)}:{popoverText:__("This item was added to your site after the most recent scan. We will check for threats during the next scheduled one.","jetpack-protect"),badgeElement:p().createElement(s.A,{icon:i.A,size:28,className:h.A["navigation-item-info-badge"]})})(e,t),[u,g]=(0,d.useState)(!1),v=(0,d.useMemo)((()=>(0,m.EV)(a)),[a]),f=(0,d.useCallback)((()=>{v||g(!0)}),[v]),y=(0,d.useCallback)((()=>{g(!1)}),[]);return p().createElement("div",{onMouseLeave:c?y:null,onMouseEnter:c?f:null,onClick:c?f:null,onFocus:c?f:null,onBlur:c?y:null,role:"presentation"},v?p().createElement(r.Spinner,null):l,u&&p().createElement(r.Popover,{noArrow:!1,inline:!0},p().createElement(n.Ay,{variant:"body-small",className:h.A["popover-text"]},c)))};g.propTypes={count:u().number,checked:u().bool};const v=g},5498:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(1112),r=a(7723),c=a(1609),s=a.n(c),i=a(1549),o=a(3066),l=a(43);const __=r.__,u=({icon:e,label:t,children:a})=>{const[u,d]=(0,c.useState)(!0),{mode:p}=(0,c.useContext)(l._),m=Array.isArray(a)&&a?.length>=8&&"list"===p,h=m&&u?a.slice(0,8):a,g=m?a?.length-8:0,v=(0,c.useCallback)((()=>{d((e=>!e))}),[]);return s().createElement("li",{tabIndex:-1,role:"menuitem",className:o.A["navigation-group"]},s().createElement(i.A,{icon:e,className:o.A["navigation-group-label"]},t),s().createElement("div",{className:o.A["navigation-group-list"]},s().createElement("ul",{className:o.A["navigation-group-content"]},h),m&&s().createElement("div",{className:o.A["navigation-group-truncate"]},s().createElement(n.A,{variant:"link",onClick:v},u?(0,r.sprintf)(/* translators: %s: Number of hide items */ -__("Show %s more","jetpack-protect"),g):(0,r.sprintf)(/* translators: %s: Number of hide items */ -__("Hide %s items","jetpack-protect"),g)))))}},59:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>f,Me:()=>d.A,s$:()=>p.A});var n=a(7425),r=a(6427),c=a(7723),s=a(1113),i=a(8248),o=a(4969),l=a(1609),u=a.n(l),d=a(5498),p=a(7366),m=a(3066),h=a(43);const __=c.__,g=({children:e})=>u().createElement("ul",{className:m.A.navigation,role:"menu"},e),v=({children:e,data:t})=>{const a=(0,l.useRef)(void 0),[c,d]=(0,l.useState)(!1),p=t?.items?.find((e=>e?.id===t?.selectedItem))??{label:__("See all results","jetpack-protect")},{label:h,icon:g}=p,v=(0,l.useCallback)((()=>{d((e=>!e))}),[]);return u().createElement("button",{className:m.A["navigation-dropdown-button"],onClick:v,ref:a},u().createElement("div",{className:m.A["navigation-dropdown-label"]},g&&u().createElement(s.A,{icon:g,className:m.A["navigation-dropdown-icon"]}),u().createElement(n.Ay,null,h)),u().createElement(s.A,{icon:c?i.A:o.A,size:32}),u().createElement(r.Popover,{position:"bottom center",anchorRef:a?.current,inline:!0},u().createElement("div",{style:{display:c?"block":"none",width:a?.current?.getBoundingClientRect?.()?.width}},e)))},f=({children:e,selected:t,onSelect:a,mode:n="list"})=>{const r=(0,h.A)({selected:t,onSelect:a}),c=(e=>{switch(e){case"list":default:return g;case"dropdown":return v}})(n);return u().createElement(h._.Provider,{value:{...r,mode:n}},u().createElement(c,{data:r},e))}},7366:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(3022),r=a(1609),c=a.n(r),s=a(9278),i=a(1549),o=a(3066),l=a(43);const u=({id:e,label:t,icon:a,badge:u,disabled:d,onClick:p,onKeyDown:m,onFocus:h,checked:g})=>{const v=(0,r.useContext)(l._),f=v?.selectedItem===e,y=v?.registerItem,E=v?.registerRef,A=v?.handleClickItem,b=v?.handleKeyDownItem,w=v?.handleFocusItem,k=(0,n.A)(o.A["navigation-item"],{[o.A.clickable]:!d,[o.A.selected]:f}),R=(0,r.useCallback)((t=>{p?.(t),A?.(e)}),[A,e,p]),C=(0,r.useCallback)((e=>{m?.(e),b?.(e)}),[b,m]),_=(0,r.useCallback)((t=>{E(t,e)}),[E,e]),j=(0,r.useCallback)((t=>{h?.(t),w?.(e)}),[w,e,h]);return(0,r.useEffect)((()=>{y({id:e,disabled:d,label:t,icon:a})}),[]),c().createElement("li",{className:k,onClick:d?null:R,onKeyDown:C,onFocus:d?null:j,role:"menuitem",tabIndex:d?-1:0,ref:_},c().createElement(i.A,{icon:a},t),c().createElement(s.A,{count:u,checked:g}))}},1549:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(7425),r=a(1113),c=a(3022),s=a(8120),i=a.n(s),o=a(1609),l=a.n(o),u=a(3066);const d=({icon:e,children:t,className:a})=>l().createElement(n.Ay,{className:(0,c.A)(u.A["navigation-item-label"],a)},e&&l().createElement(r.A,{icon:e,className:u.A["navigation-item-icon"],size:28}),l().createElement("span",{className:u.A["navigation-item-label-content"]},t));d.propTypes={icon:i().node,children:i().node.isRequired};const p=d},43:(e,t,a)=>{"use strict";a.d(t,{A:()=>c,_:()=>r});var n=a(1609);const r=a.n(n)().createContext(),c=({selected:e,onSelect:t})=>{const[a,r]=(0,n.useState)([]),[c,s]=(0,n.useState)([]),[i,o]=(0,n.useState)(),l=(e,t)=>{const n=e-1,r=n<0?t:n,c=a[r];return c?.disabled?l(r,t):c},u=(e,t)=>{const n=e+1,r=n>t?0:n,c=a[r];return c?.disabled?u(r,t):c};return{selectedItem:e,handleClickItem:e=>{t(e)},handleKeyDownItem:n=>{const r=n?.code,s=a.findIndex((t=>t?.id===e)),o=a.length-1;let d;if("ArrowUp"===r){const e=l(s,o);d=e?.id}else if("ArrowDown"===r){const e=u(s,o);d=e?.id}else"Enter"!==r&&"Space"!==r||!i||(d=i);if(d){const e=c[d];e?.focus(),t(d)}},handleFocusItem:e=>{o(e)},registerRef:(e,t)=>{s((a=>!a[t]&&e?{...a,[t]:e}:a))},registerItem:e=>{r((t=>{const a=[...t],n=e?.id,r=a.findIndex((e=>e?.id===n));return r>=0?a[r]=e:a.push(e),a}))},items:a}}},3041:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(7723),r=a(3883),c=a(3751),s=a(9783),i=a(1113),o=a(991),l=a(1609),u=a(4537),d=a(600);const __=n.__,p=({dismissable:e=!1,duration:t=null,floating:a=!1,message:n,type:p="success"})=>{const{clearNotice:m}=(0,u.A)();let h;switch(p){case"success":h=r.A;break;case"error":h=c.A;break;default:h=s.A}const g=(0,l.useCallback)((()=>{m()}),[m]);return(0,l.useEffect)((()=>{let e;return t&&(e=setTimeout(m,t)),()=>clearTimeout(e)}),[m,t,n]),React.createElement("div",{className:`${d.A.notice} ${d.A[`notice--${p}`]} ${a?d.A["notice--floating"]:""}`},React.createElement("div",{className:d.A.notice__icon},React.createElement(i.A,{icon:h})),React.createElement("div",{className:d.A.notice__message},n),e&&React.createElement("button",{className:d.A.notice__close,"aria-label":__("Dismiss notice.","jetpack-protect"),onClick:g},React.createElement(i.A,{icon:o.A})))}},4254:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(1330),r=a(7723),c=a(1609),s=a(1936);const __=r.__,i=({id:e,anchor:t,position:a})=>{const{stepsCount:r,currentStep:i,currentStepCount:o,completeCurrentStep:l,completeAllCurrentSteps:u}=(0,s.Ay)(),{setRenderedSteps:d}=(0,c.useContext)(s.OC);return(0,c.useEffect)((()=>(d((t=>[...t,e])),()=>{d((t=>t.filter((t=>t!==e))))})),[e,d]),i?.id!==e?null:React.createElement(n.A,{anchor:t,title:i.title,noArrow:!1,children:i.description,buttonContent:o{"use strict";a.d(t,{A:()=>_,S:()=>C});var n=a(7425),r=a(597),c=a(6461),s=a(442),i=a(1014),o=a(6427),l=a(8443),u=a(6087),d=a(7723),p=a(1113),m=a(3883),h=a(8248),g=a(4969),v=a(3022),f=a(1609),y=a.n(f),E=a(8140),A=a(3657),b=a(7489);const __=d.__,w=y().createContext(),k=({firstDetected:e,fixedOn:t,status:a})=>{const r=(0,f.useMemo)((()=>"fixed"===a?(0,d.sprintf)(/* translators: %s: Fixed on date */ -__("Threat fixed %s","jetpack-protect"),(0,l.dateI18n)("M j, Y",t)):"ignored"===a?__("Threat ignored","jetpack-protect"):null),[a,t]);return e&&y().createElement(y().Fragment,null,y().createElement(n.Ay,{className:b.A["accordion-header-status"]},(0,d.sprintf)(/* translators: %s: First detected date */ -__("Threat found %s","jetpack-protect"),(0,l.dateI18n)("M j, Y",e)),r&&y().createElement(y().Fragment,null,y().createElement("span",{className:b.A["accordion-header-status-separator"]}),y().createElement("span",{className:b.A[`is-${a}`]},r))),["fixed","ignored"].includes(a)&&y().createElement(R,{status:a}))},R=({status:e})=>y().createElement("div",{className:`${b.A["status-badge"]} ${b.A[e]}`},"fixed"===e?__("Fixed","jetpack-protect"):__("Ignored","jetpack-protect",0)),C=({id:e,title:t,label:a,icon:l,fixable:d,severity:R,children:C,firstDetected:_,fixedOn:j,onOpen:x,status:S,hideAutoFixColumn:M=!1})=>{const{open:N,setOpen:L}=(0,f.useContext)(w),P=N===e,{isThreatFixInProgress:z,isThreatFixStale:O}=(0,A.Ay)(),I=(0,f.useCallback)((()=>{P||x?.(),L((t=>t===e?null:e))}),[P,x,L,e]),[F]=(0,s.A)(["sm","lg"],[null,"<"]);return y().createElement("div",{className:b.A["accordion-item"]},y().createElement("button",{className:b.A["accordion-header"],onClick:I},y().createElement("div",null,y().createElement(n.Ay,{className:b.A["accordion-header-label"],mb:1},y().createElement(p.A,{icon:l,className:b.A["accordion-header-label-icon"]}),a),y().createElement(n.Ay,{className:b.A["accordion-header-description"],variant:P?"title-small":"body"},t),["fixed","ignored"].includes(S)&&y().createElement(k,{firstDetected:_,fixedOn:j,status:S})),y().createElement("div",null,y().createElement(i.A,{severity:R})),!M&&d&&y().createElement("div",null,(V=z(e),O(e)?y().createElement(r.A,{className:b.A["icon-tooltip"],iconClassName:b.A["icon-tooltip__icon"],iconSize:20,placement:"top",hoverShow:!0},y().createElement(n.Ay,{className:b.A["icon-tooltip__content"]},(0,u.createInterpolateElement)(__("The fixer is taking longer than expected. Please try again or contact support.","jetpack-protect"),{supportLink:y().createElement(o.ExternalLink,{className:b.A["support-link"],href:E.NW})}))):V?y().createElement(c.A,{color:"black"}):y().createElement(p.A,{icon:m.A,className:b.A["icon-check"],size:28})),F&&y().createElement("span",null,__("Auto-fix","jetpack-protect"))),y().createElement("div",{className:b.A["accordion-header-button"]},y().createElement(p.A,{icon:P?h.A:g.A,size:38}))),y().createElement("div",{className:(0,v.A)(b.A["accordion-body"],{[b.A["accordion-body-open"]]:P,[b.A["accordion-body-close"]]:!P}),"aria-hidden":!P},C));var V},_=({children:e})=>{const[t,a]=(0,f.useState)();return y().createElement(w.Provider,{value:{open:t,setOpen:a}},y().createElement("div",{className:b.A.accordion},e))}},5409:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(9539),r=a(5925);function c({children:e,redirect:t="/"}){const{hasPlan:a}=(0,r.Ay)();return a?e:React.createElement(n.C5,{to:t,replace:!0})}},9374:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var n=a(9245),r=a(489),c=a(1112),s=a(9384),i=a(7723),o=a(1609),l=a.n(o),u=a(9539),d=a(8590),p=a(1226),m=a(5925),h=a(9701);const __=i.__,g=()=>{const e=(0,u.Zp)(),{recordEvent:t}=(0,p.A)(),a=(0,d.A)(),{upgradePlan:i,isLoading:g}=(0,m.Ay)(),{registrationError:v}=(0,s.useConnection)({skipUserConnection:!0}),{jetpackScan:f}=(0,h.A)(),{pricingForUi:y}=f,{introductoryOffer:E,currencyCode:A="USD"}=y,b=y.cost?Math.ceil(y.cost/12*100)/100:null,w=E?.costPerInterval?Math.ceil(E.costPerInterval/12*100)/100:null,k=(0,o.useCallback)((()=>{t("jetpack_protect_pricing_table_get_scan_link_click"),i()}),[t,i]),R=(0,o.useCallback)((async()=>{t("jetpack_protect_connected_product_activated"),await a.mutateAsync(),e("/scan")}),[a,t,e]),C={title:__("Stay one step ahead of threats","jetpack-protect"),items:[{name:__("Scan for threats and vulnerabilities","jetpack-protect")},{name:__("Daily automated scans","jetpack-protect")},{name:__("Web Application Firewall","jetpack-protect")},{name:__("Brute force protection","jetpack-protect")},{name:__("Access to scan on Cloud","jetpack-protect")},{name:__("One-click auto fixes","jetpack-protect")},{name:__("Notifications","jetpack-protect")},{name:__("Severity labels","jetpack-protect")}]};return l().createElement(l().Fragment,null,l().createElement(n.Ay,C,l().createElement(n.N0,{primary:!0},l().createElement(n.i7,null,l().createElement(r.A,{price:b,offPrice:w,leyend:__("/month, billed yearly","jetpack-protect"),currency:A,hideDiscountLabel:!1}),l().createElement(c.A,{fullWidth:!0,onClick:k,isLoading:g,disabled:g||a.isPending},__("Get Jetpack Protect","jetpack-protect"))),l().createElement(n.eY,{isIncluded:!0,label:l().createElement("strong",null,__("Line by line malware scanning","jetpack-protect"))}),l().createElement(n.eY,{isIncluded:!0,label:l().createElement("strong",null,__("Plus on-demand manual scans","jetpack-protect"))}),l().createElement(n.eY,{isIncluded:!0,label:l().createElement("strong",null,__("Automatic protection and rule updates","jetpack-protect"))}),l().createElement(n.eY,{isIncluded:!0}),l().createElement(n.eY,{isIncluded:!0}),l().createElement(n.eY,{isIncluded:!0}),l().createElement(n.eY,{isIncluded:!0}),l().createElement(n.eY,{isIncluded:!0})),l().createElement(n.N0,null,l().createElement(n.i7,null,l().createElement(r.A,{price:0,leyend:__("Free forever","jetpack-protect"),currency:A,hidePriceFraction:!0}),l().createElement(c.A,{fullWidth:!0,variant:"secondary",onClick:R,isLoading:a.isPending,disabled:a.isPending||g,error:v?__("An error occurred. Please try again.","jetpack-protect"):null},__("Start for free","jetpack-protect"))),l().createElement(n.eY,{isIncluded:!0,label:__("Check items against database","jetpack-protect")}),l().createElement(n.eY,{isIncluded:!0}),l().createElement(n.eY,{isIncluded:!0,label:__("Manual rules only","jetpack-protect")}),l().createElement(n.eY,{isIncluded:!0}),l().createElement(n.eY,{isIncluded:!1}),l().createElement(n.eY,{isIncluded:!1}),l().createElement(n.eY,{isIncluded:!1}),l().createElement(n.eY,{isIncluded:!1}))))}},4256:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(3022),r=a(8744);const c=({className:e,total:t=100,value:a=0})=>{const c=Math.min(Math.round(a/t*100),100),s={width:`${c}%`};return React.createElement("div",{className:(0,n.A)(e,r.A["progress-bar"])},React.createElement("div",{className:r.A["progress-bar__wrapper"]},React.createElement("div",{"aria-valuemax":t,"aria-valuemin":0,"aria-valuenow":Math.min(a,t),className:r.A["progress-bar__bar"],role:"progressbar",style:s})),React.createElement("p",{className:r.A["progress-bar__percent"]},`${c}%`))}},7827:(e,t,a)=>{"use strict";function n(){return React.createElement("svg",{width:"80",height:"96",viewBox:"0 0 80 96",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M40 0.00634766L80 17.7891V44.2985C80 66.8965 65.1605 88.2927 44.2352 95.0425C41.4856 95.9295 38.5144 95.9295 35.7648 95.0425C14.8395 88.2927 0 66.8965 0 44.2985V17.7891L40 0.00634766Z",fill:"#069E08"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M60.9 33.6909L35.375 67.9124L19.2047 55.9263L22.7848 51.1264L34.1403 59.5436L56.0851 30.122L60.9 33.6909Z",fill:"white"}))}a.d(t,{A:()=>n})},3535:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var n=a(6072),r=a.n(n),c=a(1112),s=a(7723),i=a(1609),o=a.n(i),l=a(2425),u=a(240);const __=s.__,d=(0,i.forwardRef)((({variant:e="secondary",children:t,...a},n)=>{const s=(0,u.A)(),{data:d}=(0,l.Ay)(),p=(0,i.useMemo)((()=>s.isPending||(0,l.EV)(d)),[s.isPending,d]);return o().createElement(c.A,r()({ref:n,variant:e,onClick:e=>{e.preventDefault(),s.mutate()},disabled:p},a),t??__("Scan now","jetpack-protect"))}))},9889:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(7723),r=a(1609),c=a.n(r),s=a(9539),i=a(5925),o=a(4907);const __=n.__;function l(){const e=(0,s.Zp)(),t=(0,s.zy)(),{hasPlan:a}=(0,i.Ay)(),n="/scan"===t.pathname,l=t.pathname.includes("/scan/history"),u=(0,r.useCallback)((()=>e("/scan")),[e]),d=(0,r.useCallback)((()=>e("/scan/history")),[e]);return a&&(n||l)?c().createElement(c().Fragment,null,c().createElement(o.A,null,c().createElement(o.A.Button,{variant:n?"primary":"secondary",onClick:u},__("Scanner","jetpack-protect")),c().createElement(o.A.Button,{variant:l?"primary":"secondary",onClick:d},__("History","jetpack-protect")))):null}},3127:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(442),r=a(5918),c=a(8509),s=a(1609),i=a.n(s);const o=({spacing:e=0,gap:t=0,main:a,mainClassName:s,secondary:o,secondaryClassName:l,preserveSecondaryOnMobile:u=!1,fluid:d})=>{const[p,m]=(0,n.A)(["sm","lg"]),h=!u&&p;return i().createElement(r.A,{horizontalSpacing:e,horizontalGap:t,fluid:d},!h&&i().createElement(i().Fragment,null,i().createElement(c.A,{className:s,sm:12,md:4,lg:6},a),m&&i().createElement(c.A,{lg:1}),i().createElement(c.A,{className:l,sm:12,md:4,lg:5},o)),h&&i().createElement(c.A,null,a))}},3144:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(7425),r=a(6087),c=a(7723),s=a(1847);const __=c.__,i=()=>React.createElement(React.Fragment,null,React.createElement(n.Ay,{variant:"title-medium-semi-bold",mb:2},__("Enhanced protection","jetpack-protect")),React.createElement(n.Ay,{mb:2},__("Learn how you can execute Jetpack Firewall before WordPress initializes. This mode offers the most protection.","jetpack-protect")),React.createElement("ul",{className:s.A.list},React.createElement("li",{className:s.A["list-item"]},React.createElement(n.Ay,{variant:"body-small"},(0,r.createInterpolateElement)(__("To ensure the firewall can best protect your site, please update: auto_prepend_file PHP directive to point to wp-content/jetpack-waf/bootstrap.php Typically this is set either in an .htaccess file or in the global PHP configuration; contact your host for further assistance.","jetpack-protect"),{mark:React.createElement("mark",{className:s.A.mark})}))),React.createElement("li",{className:s.A["list-item"]},React.createElement(n.Ay,{variant:"body-small"},__("Don't forget to undo this action when Firewall is turned off, or when you uninstall Jetpack.","jetpack-protect")))))},241:(e,t,a)=>{"use strict";a.d(t,{A:()=>s,o:()=>c});var n=a(28),r=a(4356);const c=({label:e,link:t})=>React.createElement(n.k2,{to:t,className:({isActive:e})=>e?`${r.A.tab} ${r.A["tab--active"]}`:r.A.tab},e),s=({children:e,className:t=""})=>React.createElement("nav",{className:`${r.A.tabs} ${t}`},e)},4491:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});var n=a(6578);const r=({disabled:e=!1,id:t,label:a="",description:r="",placeholder:c="",rows:s=3,value:i="",onChange:o=()=>{}})=>React.createElement("div",null,Boolean(a)&&React.createElement("label",{className:n.A.label,htmlFor:t},a),Boolean(r)&&r,React.createElement("textarea",{className:n.A.textarea,disabled:e,placeholder:c,rows:s,id:t,name:t,onChange:o,value:i||""}))},1571:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var n=a(7425),r=a(1014),c=a(7723),s=a(1113),i=a(1609),o=a.n(i),l=a(9054);const __=c.__,u=e=>{switch(e.fixer){case"replace":return __("Jetpack Scan will replace the affected file or directory.","jetpack-protect");case"delete":return __("Jetpack Scan will delete the affected file or directory.","jetpack-protect");case"update":return e.target?(0,c.sprintf)(/* translators: %s: Version that the plugin will be upgraded to */ -__("Jetpack Scan will update to a newer version %s.","jetpack-protect"),e.target):__("Jetpack Scan will update to a newer version.","jetpack-protect");case"edit":return __("Jetpack Scan will edit the affected file or directory.","jetpack-protect");case"rollback":return e.target?(0,c.sprintf)(/* translators: %s: Version that the plugin will be upgraded to */ -__("Jetpack Scan will rollback the affected file to the version from %s.","jetpack-protect"),e.target):__("Jetpack Scan will rollback the affected file to an older (clean) version.","jetpack-protect");default:return __("Jetpack Scan will resolve the threat.","jetpack-protect")}};function d({threat:e,fixAllDialog:t,onCheckFix:a}){const[c,d]=(0,i.useState)(!0),p=(0,i.useCallback)((t=>{d(t.target.checked),a(t.target.checked,e)}),[a,e]);return o().createElement(o().Fragment,null,o().createElement("div",{className:l.A.threat},o().createElement(s.A,{icon:e.icon,className:l.A.threat__icon}),o().createElement("div",{className:l.A.threat__summary},o().createElement(n.Ay,{className:l.A.threat__summary__label,mb:1},e.label),o().createElement(n.Ay,{className:l.A.threat__summary__title},u(e.fixable))),o().createElement("div",{className:l.A.threat__severity},o().createElement(r.A,{severity:e.severity})),t&&o().createElement("div",{className:l.A.threat__checkbox},o().createElement("input",{type:"checkbox",checked:c,onChange:p,value:e.id}))))}},9314:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(7425),r=a(6087),c=a(7723),s=a(1609),i=a(2425),o=a(5925),l=a(9701),u=a(4254),d=a(3535),p=a(1476);const __=c.__,_n=c._n,m=()=>React.createElement("svg",{width:"80",height:"96",viewBox:"0 0 80 96",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M40 0.00634766L80 17.7891V44.2985C80 66.8965 65.1605 88.2927 44.2352 95.0425C41.4856 95.9295 38.5144 95.9295 35.7648 95.0425C14.8395 88.2927 0 66.8965 0 44.2985V17.7891L40 0.00634766Z",fill:"#069E08"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M60.9 33.6909L35.375 67.9124L19.2047 55.9263L22.7848 51.1264L34.1403 59.5436L56.0851 30.122L60.9 33.6909Z",fill:"white"})),h=()=>{const{lastChecked:e}=(0,l.A)(),{hasPlan:t}=(0,o.Ay)(),{data:a}=(0,i.Ay)(),[h,g]=(0,s.useState)(null),v=(0,s.useMemo)((()=>e?(e=>{const t=new Date,a=6e4*t.getTimezoneOffset(),n=Math.floor((new Date(t.getTime()+a).getTime()-e)/1e3);let r=n/31536e3;return r>1?(0,c.sprintf)( -// translators: placeholder is a number amount of years i.e. "5 years ago". -_n("%s year ago","%s years ago",Math.floor(r),"jetpack-protect"),Math.floor(r)):(r=n/2592e3,r>1?(0,c.sprintf)( -// translators: placeholder is a number amount of months i.e. "5 months ago". -_n("%s month ago","%s months ago",Math.floor(r),"jetpack-protect"),Math.floor(r)):(r=n/86400,r>1?(0,c.sprintf)( -// translators: placeholder is a number amount of days i.e. "5 days ago". -_n("%s day ago","%s days ago",Math.floor(r),"jetpack-protect"),Math.floor(r)):(r=n/3600,r>1?(0,c.sprintf)( -// translators: placeholder is a number amount of hours i.e. "5 hours ago". -_n("%s hour ago","%s hours ago",Math.floor(r),"jetpack-protect"),Math.floor(r)):(r=n/60,r>1?(0,c.sprintf)( -// translators: placeholder is a number amount of minutes i.e. "5 minutes ago". -_n("%s minute ago","%s minutes ago",Math.floor(r),"jetpack-protect"),Math.floor(r)):__("a few seconds ago","jetpack-protect")))))})(Date.parse(e)):null),[e]);return React.createElement("div",{className:p.A.empty},React.createElement(m,null),React.createElement(n.H3,{weight:"bold",mt:8},__("Don't worry about a thing","jetpack-protect")),React.createElement(n.Ay,{mb:4},v?(0,r.createInterpolateElement)((0,c.sprintf)( -// translators: placeholder is the amount of time since the last scan, i.e. "5 minutes ago". -__("The last Protect scan ran %s and everything looked great.","jetpack-protect"),v),{strong:React.createElement("strong",null)}):__("No threats have been detected by the current scan.","jetpack-protect")),t&&React.createElement(React.Fragment,null,React.createElement(d.A,{ref:g}),!(0,i.EV)(a)&&React.createElement(u.A,{id:"paid-daily-and-manual-scans",position:"bottom middle",anchor:h})))}},5190:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var n=a(1112),r=a(7425),c=a(4437),s=a(7723),i=a(1609),o=a.n(i),l=a(1226),u=a(5925),d=a(4114),p=a(4569),m=a(1476);const __=s.__,h=({description:e,fixedIn:t,icon:a,id:p,label:h,name:g,source:v,title:f,type:y})=>{const{recordEvent:E}=(0,l.A)(),{upgradePlan:A}=(0,u.Ay)(),b=(0,i.useCallback)((()=>{E("jetpack_protect_threat_list_get_scan_link_click"),A()}),[E,A]),w=v?o().createElement(n.A,{variant:"link",isExternalLink:!0,weight:"regular",href:v},__("See more technical details of this threat","jetpack-protect")):null;return o().createElement(d.E,{id:p,label:h,title:f,icon:a,onOpen:(0,i.useCallback)((()=>{["core","plugin","theme"].includes(y)&&E(`jetpack_protect_${y}_threat_open`)}),[E,y])},e&&o().createElement("div",{className:m.A["threat-section"]},o().createElement(r.Ay,{variant:"title-small",mb:2},__("What is the problem?","jetpack-protect")),o().createElement(r.Ay,{mb:2},e),w),t&&o().createElement("div",{className:m.A["threat-section"]},o().createElement(r.Ay,{variant:"title-small",mb:2},__("How to fix it?","jetpack-protect")),o().createElement(r.Ay,{mb:2},/* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ /* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ -(0,s.sprintf)(__("Update to %1$s %2$s","jetpack-protect"),g,t)),o().createElement(c.A,{description:__("Looking for advanced scan results and one-click fixes?","jetpack-protect"),cta:__("Upgrade Jetpack Protect now","jetpack-protect"),onClick:b,className:m.A["threat-item-cta"]})),!e&&o().createElement("div",{className:m.A["threat-section"]},w))},g=({list:e})=>o().createElement(p.A,{list:e},(({currentItems:e})=>o().createElement(d.A,null,e.map((({description:e,fixedIn:t,icon:a,id:n,label:r,name:c,source:s,table:i,title:l,type:u,version:d})=>o().createElement(h,{description:e,fixedIn:t,icon:a,id:n,label:r,key:n,name:c,source:s,table:i,title:l,type:u,version:d}))))))},5661:(e,t,a)=>{"use strict";a.d(t,{A:()=>k});var n=a(442),r=a(5918),c=a(8509),s=a(7425),i=a(1112),o=a(7723),l=a(1609),u=a.n(l),d=a(2425),p=a(3657),m=a(1009),h=a(5925),g=a(4254),v=a(3535),f=a(9314),y=a(5190),E=a(9395),A=a(6742),b=a(1476),w=a(993);const __=o.__,k=()=>{const{hasPlan:e}=(0,h.Ay)(),{item:t,list:a,selected:k,setSelected:R}=(0,w.A)(),[C]=(0,n.A)("sm"),{isThreatFixInProgress:_,isThreatFixStale:j}=(0,p.Ay)(),{data:x}=(0,d.Ay)(),S=(0,d.EV)(x),M=(0,l.useMemo)((()=>a.filter((e=>{const t=parseInt(e.id);return e.fixable&&!_(t)&&!j(t)}))),[a,_,j]),[N,L]=(0,l.useState)(null),[P,z]=(0,l.useState)(null),[O,I]=(0,l.useState)(null),[F,V]=(0,l.useState)(null),{setModal:D}=(0,m.A)(),H=(0,l.useCallback)((()=>{switch(k){case"all":return 1===a.length?__("All threats","jetpack-protect"):(0,o.sprintf)(/* translators: placeholder is the amount of threats found on the site. */ -__("All %s threats","jetpack-protect"),a.length);case"core":return(0,o.sprintf)(/* translators: placeholder is the amount of WordPress threats found on the site. */ -__("%1$s WordPress %2$s","jetpack-protect"),a.length,1===a.length?"threat":"threats");case"files":return(0,o.sprintf)(/* translators: placeholder is the amount of file threats found on the site. */ -__("%1$s file %2$s","jetpack-protect"),a.length,1===a.length?"threat":"threats");case"database":return(0,o.sprintf)(/* translators: placeholder is the amount of database threats found on the site. */ -__("%1$s database %2$s","jetpack-protect"),a.length,1===a.length?"threat":"threats");default:return(0,o.sprintf)(/* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ -__("%1$s %2$s in %3$s %4$s","jetpack-protect"),a.length,1===a.length?"threat":"threats",t?.name,t?.version)}}),[k,a,t]);return u().createElement(r.A,{fluid:!0,horizontalSpacing:0,horizontalGap:3},u().createElement(c.A,{lg:4},u().createElement("div",{ref:L},u().createElement(E.A,{selected:k,onSelect:R})),!S&&u().createElement(g.A,{id:e?"paid-scan-results":"free-scan-results",position:"top",anchor:N})),u().createElement(c.A,{lg:8},a?.length>0?u().createElement(u().Fragment,null,u().createElement("div",{className:b.A["list-header"]},u().createElement(s.hE,{className:b.A["list-title"]},H()),e&&u().createElement("div",{className:b.A["list-header__controls"]},M.length>0&&u().createElement(u().Fragment,null,u().createElement(i.A,{ref:I,variant:"primary",onClick:(T=M,e=>{e.preventDefault(),D({type:"FIX_ALL_THREATS",props:{threatList:T}})})},(0,o.sprintf)(/* translators: Translates to Show auto fixers $s: Number of fixable threats. */ -__("Show auto fixers (%s)","jetpack-protect"),M.length)),!S&&u().createElement(g.A,{id:"paid-fix-all-threats",position:C?"bottom right":"middle left",anchor:O}),u().createElement(v.A,{ref:V}),!S&&u().createElement(g.A,{id:"paid-daily-and-manual-scans",position:C?"bottom left":"middle left",anchor:F})))),e?u().createElement(u().Fragment,null,u().createElement("div",{ref:z},u().createElement(A.A,{list:a}),u().createElement("div",{className:b.A["manual-scan"]},u().createElement(s.Ay,{variant:"body-small",mb:4},__("If you have manually fixed any of the threats listed above, you can run a manual scan now or wait for Jetpack to scan your site later today.","jetpack-protect")),u().createElement(v.A,null))),!S&&u().createElement(g.A,{id:"paid-understand-severity",position:"top",anchor:P})):u().createElement(y.A,{list:a})):u().createElement(f.A,null)));var T}},9395:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var n=a(442),r=a(7723),c=a(3751),s=a(4648),i=a(435),o=a(2072),l=a(4314),u=a(1609),d=a(1226),p=a(5925),m=a(9701),h=a(59);const __=r.__,g=({selected:e,onSelect:t,sourceType:a="scan",statusFilter:r="all"})=>{const{hasPlan:g}=(0,p.Ay)(),{results:{plugins:v,themes:f},counts:{current:{threats:y,core:E,files:A}}}=(0,m.A)({sourceType:a,filter:{status:r}}),{recordEvent:b}=(0,d.A)(),[w]=(0,n.A)("lg","<"),k=(0,u.useCallback)((()=>{b("jetpack_protect_navigation_all_click")}),[b]),R=(0,u.useCallback)((()=>{b("jetpack_protect_navigation_core_click")}),[b]),C=(0,u.useCallback)((()=>{b("jetpack_protect_navigation_plugin_click")}),[b]),_=(0,u.useCallback)((()=>{b("jetpack_protect_navigation_theme_click")}),[b]),j=(0,u.useCallback)((()=>{b("jetpack_protect_navigation_file_click")}),[b]),x=(0,u.useMemo)((()=>"fixed"===r?__("All fixed threats","jetpack-protect"):"ignored"===r?__("All ignored threats","jetpack-protect",0):__("All threats","jetpack-protect")),[r]);return React.createElement(h.Ay,{selected:e,onSelect:t,mode:w?"dropdown":"list"},React.createElement(h.s$,{initial:!0,id:"all",label:x,icon:c.A,badge:y,disabled:y<=0,onClick:k,checked:!0}),React.createElement(h.s$,{id:"core",label:__("WordPress","jetpack-protect"),icon:s.A,badge:E,disabled:E<=0,onClick:R,checked:!0}),React.createElement(h.Me,{label:__("Plugins","jetpack-protect"),icon:i.A},v.map((({name:e,threats:t,checked:a})=>React.createElement(h.s$,{key:e,id:e,label:e,checked:a,badge:t?.length,disabled:t?.length<=0,onClick:C})))),React.createElement(h.Me,{label:__("Themes","jetpack-protect"),icon:o.A},f.map((({name:e,threats:t,checked:a})=>React.createElement(h.s$,{key:e,id:e,label:e,checked:a,badge:t?.length,disabled:t?.length<=0,onClick:_})))),g&&React.createElement(React.Fragment,null,React.createElement(h.s$,{id:"files",label:__("Files","jetpack-protect"),icon:l.A,badge:A,disabled:A<=0,onClick:j,checked:!0})))}},4569:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(1112),r=a(442),c=a(7723),s=a(8888),i=a(9115),o=a(1609),l=a.n(o),u=a(1476);const __=c.__,d=({pageNumber:e,currentPage:t,onPageChange:a})=>{const r=(0,o.useMemo)((()=>t===e),[t,e]),s=(0,o.useCallback)((()=>{a(e)}),[a,e]);return l().createElement(n.A,{size:"medium",className:r?null:u.A.unfocused,onClick:s,"aria-current":r?"page":void 0,"aria-label":(0,c.sprintf)(/* translators: placeholder is a page number, i.e. "Page 123" */ -__("Page %d","jetpack-protect"),e)},e)},p=({list:e,itemPerPage:t=10,children:a})=>{const[c]=(0,r.A)("sm"),[p,m]=(0,o.useState)(1),h=(0,o.useCallback)((()=>m(p-1)),[p,m]),g=(0,o.useCallback)((()=>m(p+1)),[p,m]),v=(0,o.useMemo)((()=>Math.ceil(e.length/t)),[e,t]),f=(0,o.useMemo)((()=>{const a=p*t,n=a-t;return e.slice(n,a)}),[p,e,t]),y=(0,o.useMemo)((()=>{if(c)return[p];const e=[1];return p>3&&v>4&&e.push("…"),1===p?e.push(p+1,p+2,p+3):2===p?e.push(p,p+1,p+2):p3&&e.push(p-2),p>2&&e.push(p-1),e.push(p)):p===v&&(p>=5&&e.push(p-3),p>=4&&e.push(p-2),e.push(p-1)),e[e.length-1]e<=v||isNaN(e)))}),[p,c,v]);return l().createElement(l().Fragment,null,a({currentItems:f}),v>1&&l().createElement("nav",{role:"navigation","aria-label":__("Threat list pages","jetpack-protect"),className:u.A["pagination-container"]},l().createElement(n.A,{onClick:h,disabled:1===p,variant:"link",icon:s.A,iconSize:24,"aria-label":__("Previous page","jetpack-protect")}),y.map(((e,t)=>"number"==typeof e?l().createElement(d,{key:e,pageNumber:e,currentPage:p,onPageChange:m}):l().createElement("span",{key:`ellipses_${t}`},e))),l().createElement(n.A,{onClick:g,disabled:p===v,variant:"link",icon:i.A,iconSize:24,"aria-label":__("Next page","jetpack-protect")})))}},6742:(e,t,a)=>{"use strict";a.d(t,{A:()=>y});var n=a(1112),r=a(7425),c=a(5734),s=a(4252),i=a(442),o=a(7723),l=a(1609),u=a.n(l),d=a(1226),p=a(3657),m=a(1009),h=a(2006),g=a(4569),v=a(1476);const __=o.__,f=({context:e,description:t,diff:a,filename:i,firstDetected:g,fixedIn:f,fixedOn:y,icon:E,fixable:A,id:b,label:w,name:k,source:R,title:C,type:_,severity:j,status:x,hideAutoFixColumn:S=!1})=>{const{setModal:M}=(0,m.A)(),{recordEvent:N}=(0,d.A)(),{isThreatFixInProgress:L,isThreatFixStale:P}=(0,p.Ay)(),z=L(b),O=P(b),I=R?u().createElement(n.A,{variant:"link",isExternalLink:!0,weight:"regular",href:R},__("See more technical details of this threat","jetpack-protect")):null;return u().createElement(h.S,{id:b,label:w,title:C,icon:E,fixable:A,severity:j,firstDetected:g,fixedOn:y,status:x,onOpen:(0,l.useCallback)((()=>{["core","plugin","theme","file","database"].includes(_)&&N(`jetpack_protect_${_}_threat_open`)}),[N,_]),hideAutoFixColumn:S},t&&u().createElement("div",{className:v.A["threat-section"]},u().createElement(r.Ay,{variant:"title-small",mb:2},"fixed"!==x?__("What is the problem?","jetpack-protect"):__("What was the problem?","jetpack-protect",0)),u().createElement(r.Ay,{mb:2},t),I),(i||e||a)&&u().createElement(r.Ay,{variant:"title-small",mb:2},__("The technical details","jetpack-protect")),i&&u().createElement(u().Fragment,null,u().createElement(r.Ay,{mb:2},/* translators: filename follows in separate line; e.g. "PHP.Injection.5 in: `post.php`" */ -__("Threat found in file:","jetpack-protect")),u().createElement("pre",{className:v.A["threat-filename"]},i)),e&&u().createElement(c.A,{context:e}),a&&u().createElement(s.A,{diff:a}),f&&"fixed"!==x&&u().createElement("div",{className:v.A["threat-section"]},u().createElement(r.Ay,{variant:"title-small",mb:2},__("How to fix it?","jetpack-protect")),u().createElement(r.Ay,{mb:2},/* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ /* translators: Translates to Update to. %1$s: Name. %2$s: Fixed version */ -(0,o.sprintf)(__("Update to %1$s %2$s","jetpack-protect"),k,f))),!t&&u().createElement("div",{className:v.A["threat-section"]},I),["ignored","current"].includes(x)&&u().createElement("div",{className:v.A["threat-footer"]},"ignored"===x&&u().createElement(n.A,{isDestructive:!0,variant:"secondary",onClick:e=>{e.preventDefault(),M({type:"UNIGNORE_THREAT",props:{id:b,label:w,title:C,icon:E,severity:j}})}},__("Unignore threat","jetpack-protect")),"current"===x&&u().createElement(u().Fragment,null,u().createElement(n.A,{isDestructive:!0,variant:"secondary",onClick:e=>{e.preventDefault(),M({type:"IGNORE_THREAT",props:{id:b,label:w,title:C,icon:E,severity:j}})},disabled:z||O},__("Ignore threat","jetpack-protect")),A&&u().createElement(n.A,{disabled:z||O,onClick:e=>{e.preventDefault(),M({type:"FIX_THREAT",props:{id:b,fixable:A,label:w,icon:E,severity:j}})}},__("Fix threat","jetpack-protect")))))},y=({list:e,hideAutoFixColumn:t=!1})=>{const[a]=(0,i.A)(["sm","lg"],[null,"<"]);return u().createElement(u().Fragment,null,!a&&u().createElement("div",{className:v.A["accordion-header"]},u().createElement("span",null,__("Details","jetpack-protect")),u().createElement("span",null,__("Severity","jetpack-protect")),!t&&u().createElement("span",null,__("Auto-fix","jetpack-protect")),u().createElement("span",null)),u().createElement(g.A,{list:e},(({currentItems:e})=>u().createElement(h.A,null,e.map((({context:e,description:a,diff:n,filename:r,firstDetected:c,fixedIn:s,fixedOn:i,icon:o,fixable:l,id:d,label:p,name:m,severity:h,source:g,table:v,title:y,type:E,version:A,status:b})=>u().createElement(f,{context:e,description:a,diff:n,filename:r,firstDetected:c,fixedIn:s,fixedOn:i,icon:o,fixable:l,id:d,key:d,label:p,name:m,severity:h,source:g,table:v,title:y,type:E,version:A,status:b,hideAutoFixColumn:t})))))))}},993:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(4648),r=a(4314),c=a(1651),s=a(435),i=a(2072),o=a(1609),l=a(9701);const u=(e,t)=>t.severity-e.severity,d=(e,t)=>"object"==typeof e&&0===Object.keys(e).length?[]:Array.isArray(e)?e.map((e=>d(e,t))).flat():e?.threats.map((a=>({...a,...e,...t}))),p=({source:e,status:t}={source:"scan",status:"all"})=>{const[a,p]=(0,o.useState)("all"),{results:{plugins:m,themes:h,core:g,files:v,database:f}}=(0,l.A)({sourceType:e,filter:{status:t,key:a}}),{unsortedList:y,item:E}=(0,o.useMemo)((()=>{if(a&&"all"!==a){switch(a){case"core":return{unsortedList:d(g,{icon:n.A}),item:g};case"files":return{unsortedList:d({threats:v},{icon:r.A}),item:v};case"database":return{unsortedList:d({threats:f},{icon:c.A}),item:f}}const e=m.find((e=>e?.name===a));if(e)return{unsortedList:d(e,{icon:s.A}),item:e};const t=h.find((e=>e?.name===a));if(t)return{unsortedList:d(t,{icon:i.A}),item:t}}return{unsortedList:[...d(g,{icon:n.A}),...d(m,{icon:s.A}),...d(h,{icon:i.A}),...d({threats:v},{icon:r.A}),...d({threats:f},{icon:c.A})],item:null}}),[g,f,v,m,a,h]),A=e=>e.name&&e.version?`${e.name} (${e.version})`:e.filename?e.filename.split("/").pop():e.table?e.table:void 0,b=(0,o.useMemo)((()=>y.sort(u).map((e=>({label:A(e),...e})))),[y]);return(0,o.useEffect)((()=>{"all"!==a&&"all"!==t&&0===b.length&&p("all")}),[a,t,E,b]),{item:E,list:b,selected:a,setSelected:p}}},9623:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var n=a(7425),r=a(1014),c=a(1112),s=a(7723),i=a(1113),o=a(1609),l=a(7208),u=a(1009),d=a(4031),p=a(6834);const __=s.__,m=({id:e,title:t,label:a,icon:s,severity:m})=>{const{setModal:h}=(0,u.A)(),g=(0,l.A)(),[v,f]=(0,o.useState)(!1);return React.createElement(d.A,null,React.createElement(n.Ay,{variant:"title-medium",mb:2},__("Do you really want to unignore this threat?","jetpack-protect")),React.createElement(n.Ay,{mb:3},__("Jetpack will unignore the threat:","jetpack-protect")),React.createElement("div",{className:p.A.threat},React.createElement(i.A,{icon:s,className:p.A.threat__icon}),React.createElement("div",{className:p.A.threat__summary},React.createElement(n.Ay,{className:p.A.threat__summary__label,mb:1},a),React.createElement(n.Ay,{className:p.A.threat__summary__title},t)),React.createElement("div",{className:p.A.threat__severity},React.createElement(r.A,{severity:m}))),React.createElement("div",{className:p.A.footer},React.createElement(c.A,{variant:"secondary",onClick:e=>{e.preventDefault(),h({type:null})}},__("Cancel","jetpack-protect")),React.createElement(c.A,{isDestructive:!0,isLoading:v,onClick:async t=>{t.preventDefault(),f(!0),await g.mutateAsync(e),h({type:null}),f(!1)}},__("Unignore threat","jetpack-protect"))))}},4031:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var n=a(9384),r=a(1221);const c=({children:e})=>{const{isUserConnected:t,hasConnectedOwner:a}=(0,n.useConnection)();return t&&a?e:React.createElement(r.A,null)}},1221:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(7425),r=a(1112),c=a(9384),s=a(7723),i=a(1009),o=a(3041),l=a(8340);const __=s.__,u=()=>{const{setModal:e}=(0,i.A)(),{userIsConnecting:t,handleConnectUser:a}=(0,c.useConnection)({redirectUri:"admin.php?page=jetpack-protect"});return React.createElement(React.Fragment,null,React.createElement(n.Ay,{variant:"title-medium",mb:2},__("User connection needed","jetpack-protect")),React.createElement(o.A,{type:"info",message:__("Before Jetpack Protect can ignore and auto-fix threats on your site, a user connection is needed.","jetpack-protect")}),React.createElement(n.Ay,{mb:3},__("A user connection provides Jetpack Protect the access necessary to perform these tasks.","jetpack-protect")),React.createElement(n.Ay,{mb:3},__("Once you’ve secured a user connection, all Jetpack Protect features will be available for use.","jetpack-protect")),React.createElement("div",{className:l.A.footer},React.createElement(r.A,{variant:"secondary",onClick:t=>{t.preventDefault(),e({type:null})}},__("Not now","jetpack-protect")),React.createElement(r.A,{isExternalLink:!0,weight:"regular",isLoading:t,onClick:a},__("Connect your user account","jetpack-protect"))))}},8140:(e,t,a)=>{"use strict";a.d(t,{Gs:()=>v,J3:()=>n,JD:()=>s,Mm:()=>o,NW:()=>c,Oz:()=>p,Ss:()=>m,VE:()=>h,X9:()=>d,_R:()=>i,kD:()=>g,oA:()=>u,pQ:()=>r,vI:()=>l,yN:()=>f});const n="jetpack_scan",r="https://wordpress.org/support/plugin/jetpack-protect/",c="https://jetpack.com/contact-support/?rel=support",s="optimistically_scanning",i="idle",o="unavailable",l=["provisioning","scheduled","scanning",s],u="credentials",d="fixers",p="has plan",m="history",h="onboarding progress",g="product data",v="scan status",f="waf"},7534:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(7115),r=a(4613),c=a(295),s=a(8140);function i(){const e=(0,n.jE)();return(0,r.n)({mutationFn:c.A.completeOnboardingSteps,onMutate:t=>{e.setQueryData([s.VE],(e=>[...e,...t]))}})}},5780:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var n=a(5104),r=a(295),c=a(8140);function s(){return(0,n.I)({queryKey:[c.VE],queryFn:r.A.getOnboardingProgress,initialData:window?.jetpackProtectInitialState?.onboardingProgress||[]})}},169:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(7115),r=a(4613),c=a(7723),s=a(295),i=a(8140),o=a(4537);const __=c.__;function l(){const e=(0,n.jE)(),{showSuccessNotice:t,showErrorNotice:a}=(0,o.A)();return(0,r.n)({mutationFn:s.A.fixThreats,onSuccess:a=>{if(!1===a.ok)throw new Error(a.error);if(Object.values(a.threats).every((e=>"error"in e)))throw new Error;e.setQueryData([i.X9],a),t(__("We're hard at work fixing this threat in the background. Please check back shortly.","jetpack-protect"))},onError:()=>{a(__("An error occurred fixing threats.","jetpack-protect"))}})}},8064:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var n=a(9384),r=a(7115),c=a(5104),s=a(7723),i=a(1609),o=a(295),l=a(8140),u=a(3657),d=a(4537);const __=s.__,_n=s._n,p=window.jetpackProtectInitialState?.fixerStatus||{ok:!0,threats:{}};function m({threatIds:e,usePolling:t}){const a=(0,r.jE)(),{showSuccessNotice:m,showErrorNotice:h}=(0,d.A)(),{isRegistered:g}=(0,n.useConnection)({autoTrigger:!1,from:"protect",redirectUri:null,skipUserConnection:!0}),v=(0,i.useCallback)(((e,t)=>{if(e.length>0){ -// Translators: %d is the number of threats, and %s is a list of threat IDs. -const t=_n("A threat could not be fixed.","%d threats could not be fixed.",e.length,"jetpack-protect");h((0,s.sprintf)(t,e.length))}else if(t.length>0){ -// Translators: %d is the number of threats, and %s is a list of threat IDs. -const e=_n("Threat fixed successfully.","%d threats fixed successfully.",t.length,"jetpack-protect");m((0,s.sprintf)(e,t.length))}}),[h,m]),f=(0,c.I)({queryKey:[l.X9],queryFn:async()=>{const t=await o.A.getFixersStatus(e),n=a.getQueryData([l.X9]);if(!1===t.ok)throw new Error(t.error);const r=[],c=[];return Object.keys(t.threats||{}).forEach((e=>{const s=t.threats[e];if(!0===n.ok){const t=n.threats?.[e];t&&"in_progress"===t.status&&("in_progress"===s.status?!(0,u.UM)(t.lastUpdated)&&(0,u.UM)(s.lastUpdated)&&c.push(e):(a.invalidateQueries({queryKey:[l.Gs]}),a.invalidateQueries({queryKey:[l.Ss]}),"fixed"===s.status?r.push(e):c.push(e)))}})),v(c,r),t},retry:!1,refetchInterval(e){if(!t||!e.state.data)return!1;const a=e.state.data;if(!0===a.ok){if(Object.values(a.threats).some((e=>"status"in e&&"in_progress"===e.status&&!(0,u.UM)(e.lastUpdated))))return e.state.dataUpdateCount<5?5e3:15e3}return!1},initialData:p,enabled:g});return(0,i.useEffect)((()=>{f.isError&&f.error&&(a.setQueryData([l.X9],p),h(__("An error occurred while fetching fixers status.","jetpack-protect")))}),[f.isError,f.error,a,h]),f}},1859:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(9384),r=a(5104),c=a(6185),s=a.n(c),i=a(295),o=a(8140);function l(){const{isRegistered:e}=(0,n.useConnection)({autoTrigger:!1,from:"protect",redirectUri:null,skipUserConnection:!0});return(0,r.I)({queryKey:[o.Ss],queryFn:i.A.getScanHistory,initialData:s()(window.jetpackProtectInitialState?.scanHistory),enabled:e})}},8847:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(7115),r=a(4613),c=a(7723),s=a(295),i=a(8140),o=a(4537);const __=c.__;function l(){const e=(0,n.jE)(),{showSuccessNotice:t,showErrorNotice:a}=(0,o.A)();return(0,r.n)({mutationFn:async t=>{const a=await s.A.ignoreThreat(t);return await Promise.all([e.refetchQueries({queryKey:[i.Gs]}),e.refetchQueries({queryKey:[i.Ss]})]),a},onSuccess:()=>{t(__("Threat ignored.","jetpack-protect"))},onError:()=>{a(__("An error occurred ignoring the threat.","jetpack-protect"))}})}},2425:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>p,EV:()=>d});var n=a(9384),r=a(7115),c=a(5104),s=a(6185),i=a.n(s),o=a(295),l=a(8140);const u=e=>{if("idle"!==e.status)return!1;const t=Number(localStorage.getItem("last_requested_scan"));if(!t)return!1;if(tt)},d=e=>{const t=!e?.lastChecked&&[l._R,l.Mm].includes(e?.status),a=l.vI.indexOf(e?.status)>=0;return t||a};function p({usePolling:e}={}){const t=(0,r.jE)(),{isRegistered:a}=(0,n.useConnection)({autoTrigger:!1,from:"protect",redirectUri:null,skipUserConnection:!0});return(0,c.I)({queryKey:[l.Gs],queryFn:async()=>{const e=await o.A.getScanStatus();return u(e)?t.getQueryData([l.Gs]):e},initialData:i()(window?.jetpackProtectInitialState?.status),enabled:a,refetchInterval(t){if(!e)return!1;const a=t.state.dataUpdateCount<5?5e3:15e3;return!!d(t.state.data)&&a}})}},240:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(7115),r=a(4613),c=a(295),s=a(8140);function i(){const e=(0,n.jE)();return(0,r.n)({mutationFn:c.A.scan,onMutate(){e.setQueryData([s.Gs],(e=>({...e,status:s.JD})))},onSuccess(){e.setQueryData([s.Gs],(e=>({...e,status:s.JD}))),localStorage.setItem("last_requested_scan",Date.now().toString())},onError(){e.invalidateQueries({queryKey:[s.Gs]})}})}},7208:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(7115),r=a(4613),c=a(7723),s=a(295),i=a(8140),o=a(4537);const __=c.__;function l(){const e=(0,n.jE)(),{showSuccessNotice:t,showErrorNotice:a}=(0,o.A)();return(0,r.n)({mutationFn:async t=>{const a=await s.A.unIgnoreThreat(t);return await Promise.all([e.refetchQueries({queryKey:[i.Gs]}),e.refetchQueries({queryKey:[i.Ss]})]),a},onSuccess:()=>{t(__("Threat is no longer ignored.","jetpack-protect"))},onError:()=>{a(__("An error occurred un-ignoring the threat.","jetpack-protect"))}})}},8590:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(9384),r=a(7115),c=a(4613),s=a(7723),i=a(8140),o=a(4537);const __=s.__;function l(){const e=(0,r.jE)(),{showErrorNotice:t}=(0,o.A)(),{handleRegisterSite:a}=(0,n.useConnection)({autoTrigger:!1,from:"protect",redirectUri:null,skipUserConnection:!0});return(0,c.n)({mutationFn:a,onSuccess:async()=>{e.setQueryData([i.Gs],(e=>({...e,status:i.JD}))),e.invalidateQueries({queryKey:[i.Ss]}),e.invalidateQueries({queryKey:[i.yN]}),e.invalidateQueries({queryKey:[i.Oz]}),e.invalidateQueries({queryKey:[i.oA]})},onError:()=>{t(__("Could not connect site.","jetpack-protect"))}})}},2605:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(9384),r=a(5104),c=a(295),s=a(8140);function i(){const{isRegistered:e}=(0,n.useConnection)({autoTrigger:!1,from:"protect",redirectUri:null,skipUserConnection:!0});return(0,r.I)({queryKey:[s.oA],queryFn:c.A.checkCredentials,initialData:window?.jetpackProtectInitialState?.credentials,enabled:e})}},6829:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(9384),r=a(5104),c=a(295),s=a(8140);function i(){const{isRegistered:e}=(0,n.useConnection)({autoTrigger:!1,from:"protect",redirectUri:null,skipUserConnection:!0});return(0,r.I)({queryKey:[s.Oz],queryFn:c.A.checkPlan,initialData:!!window?.jetpackProtectInitialState?.hasPlan,enabled:e})}},7651:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(5104),r=a(6185),c=a.n(r),s=a(295),i=a(8140);function o(){return(0,n.I)({queryKey:[i.kD],queryFn:s.A.getProductData,initialData:c()(window?.jetpackProtectInitialState?.jetpackScan)})}},9481:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var n=a(7115),r=a(4613),c=a(7723),s=a(295),i=a(8140),o=a(4537);const __=c.__;function l(){const e=(0,n.jE)(),{showSuccessNotice:t,showErrorNotice:a}=(0,o.A)();return(0,r.n)({mutationFn:s.A.toggleWaf,onSuccess:()=>{t(__("WAF module enabled.","jetpack-protect"))},onError:()=>{a(__("An error occurred enabling the WAF module.","jetpack-protect"))},onSettled:()=>{e.invalidateQueries({queryKey:[i.yN]})}})}},3990:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var n=a(7115),r=a(4613),c=a(6087),s=a(7723),i=a(6185),o=a.n(i),l=a(295),u=a(8140),d=a(4537);const __=s.__;function p(){const e=(0,n.jE)(),{showSuccessNotice:t,showSavingNotice:a,showErrorNotice:s}=(0,d.A)(),i=(0,c.useCallback)((e=>{switch(e.code){case"file_system_error":return __("A filesystem error occurred.","jetpack-protect");case"rules_api_error":return __("An error occurred retrieving the latest firewall rules from Jetpack.","jetpack-protect");default:return __("An error occurred.","jetpack-protect")}}),[]);return(0,r.n)({mutationFn:l.A.updateWaf,onMutate:t=>{a();const n=e.getQueryData([u.yN]);return e.setQueryData([u.yN],(e=>({...e,config:{...e.config,...o()(t)}}))),{initialValue:n}},onSuccess:()=>{t(__("Changes saved.","jetpack-protect"))},onError:(t,a,n)=>{e.setQueryData([u.yN],n.initialValue),s(i(t))}})}},5728:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(5104),r=a(6185),c=a.n(r),s=a(295),i=a(8140);function o(){return(0,n.I)({queryKey:[i.yN],queryFn:s.A.getWaf,initialData:c()(window?.jetpackProtectInitialState?.waf)})}},5632:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var n=a(7115),r=a(4613),c=a(295),s=a(8140);function i(){const e=(0,n.jE)();return(0,r.n)({mutationFn:c.A.wafUpgradeSeen,onMutate:()=>{e.setQueryData([s.yN],(e=>({...e,upgradeIsSeen:!0})))}})}},1226:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var n=a(372),r=a(9384),c=a(1609);const s=({pageViewEventName:e,pageViewNamespace:t="jetpack",pageViewSuffix:a="page_view",pageViewEventProperties:s={}}={})=>{const{isUserConnected:i,isRegistered:o,userConnectionData:l}=(0,r.useConnection)(),{login:u,ID:d}=l.currentUser?.wpcomUser||{},{tracks:p}=n.A,{recordEvent:m}=p,h=(0,c.useCallback)((async(e,t)=>{m(e,t)}),[m]),g=(0,c.useCallback)(((e,t,a=()=>{})=>(a="function"==typeof t?t:a,t="function"==typeof t?{}:t,()=>h(e,t).then(a))),[h]);(0,c.useEffect)((()=>{i&&d&&u&&n.A.initialize(d,u)}),[i,d,u]);const v=e?`${t}_${e}_${a}`:null;return(0,c.useEffect)((()=>{o&&v&&m(v,s)}),[]),{recordEvent:h,recordEventHandler:g}}},3657:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>l,UM:()=>i});var n=a(1609),r=a(169),c=a(8064),s=a(2425);const i=e=>{const t=new Date,a=new Date(e);return t.getTime()-a.getTime()>=864e5},o=e=>"status"in e&&"in_progress"===e.status&&i(e.lastUpdated);function l(){const{data:e}=(0,s.Ay)(),t=(0,r.A)(),{data:a}=(0,c.A)({threatIds:e.fixableThreatIds,usePolling:!0}),i=(0,n.useCallback)((e=>{if(!1===a.ok)return!1;const t=a.threats?.[e];return t&&"status"in t&&"in_progress"===t.status}),[a]),l=(0,n.useCallback)((e=>{if(!1===a.ok)return!1;const t=a?.threats?.[e];return!!t&&o(t)}),[a]);return{fixableThreatIds:e.fixableThreatIds,fixersStatus:a,fixThreats:t.mutateAsync,isLoading:t.isPending,isThreatFixInProgress:i,isThreatFixStale:l}}},1009:(e,t,a)=>{"use strict";a.d(t,{A:()=>i,Z:()=>s});var n=a(1609),r=a.n(n);const c=(0,n.createContext)({modal:null,setModal:null}),s=({children:e})=>{const[t,a]=(0,n.useState)({});return r().createElement(c.Provider,{value:{modal:t,setModal:a}},e)};function i(){const{modal:e,setModal:t}=(0,n.useContext)(c);return{modal:e,setModal:t}}},4537:(e,t,a)=>{"use strict";a.d(t,{A:()=>d,m:()=>u});var n=a(6427),r=a(6087),c=a(7723),s=a(1609),i=a(8140),o=a(5925);const __=c.__,l=(0,s.createContext)(void 0),u=({children:e})=>{const[t,a]=(0,s.useState)(null);return React.createElement(l.Provider,{value:{notice:t,setNotice:a}},e)};function d(){const{hasPlan:e}=(0,o.Ay)(),{notice:t,setNotice:a}=(0,s.useContext)(l),c=(0,s.useCallback)((()=>{a(null)}),[a]),u=(0,s.useCallback)((e=>{a({type:"success",dismissable:!0,duration:7500,message:e})}),[a]);return{notice:t,clearNotice:c,showSavingNotice:(0,s.useCallback)((e=>{a({type:"info",dismissable:!1,message:e||__("Saving Changes…","jetpack-protect")})}),[a]),showSuccessNotice:u,showErrorNotice:(0,s.useCallback)((t=>{a({type:"error",dismissable:!0,message:React.createElement(React.Fragment,null,t||__("An error occurred.","jetpack-protect")," ",(0,r.createInterpolateElement)(__("Please try again or contact support.","jetpack-protect"),{supportLink:React.createElement(n.ExternalLink,{href:e?i.NW:i.pQ})}))})}),[e,a])}}},1936:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>l,Ll:()=>o,OC:()=>i,dn:()=>s});var n=a(1609),r=a(7534),c=a(5780);const s=(0,n.createContext)([]),i=(0,n.createContext)([]),o=({children:e})=>{const[t,a]=(0,n.useState)([]);return React.createElement(i.Provider,{value:{renderedSteps:t,setRenderedSteps:a}},e)},l=()=>{const e=(0,n.useContext)(s),{renderedSteps:t}=(0,n.useContext)(i),{data:a}=(0,c.A)(),o=(0,r.A)(),{currentStep:l,currentStepCount:u,stepsCount:d}=(0,n.useMemo)((()=>e.reduce(((e,n)=>(t.includes(n.id)&&(e.stepsCount++,e.currentStep||-1!==(a||[]).indexOf(n.id)||(e.currentStep=n,e.currentStepCount=e.stepsCount)),e)),{currentStep:null,currentStepCount:null,stepsCount:0})),[a,t,e]),p=(0,n.useCallback)((()=>{l&&o.mutate([l.id])}),[l,o]),m=(0,n.useCallback)((()=>{const t=e.reduce(((e,t)=>(t.id.startsWith("free-")&&e.push(t.id),e)),[]);o.mutate(t)}),[e,o]),h=(0,n.useCallback)((()=>{const t=e.reduce(((e,t)=>(t.id.startsWith("paid-")&&e.push(t.id),e)),[]);o.mutate(t)}),[e,o]),g=(0,n.useCallback)((()=>{l.id.startsWith("paid-")?h():m()}),[m,h,l]);return{progress:a,stepsCount:d,currentStep:l,currentStepCount:u,completeCurrentStep:p,completeAllCurrentSteps:g}}},5925:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>d,sT:()=>l});var n=a(9384),r=a(1609),c=a(295),s=a(8140),i=a(6829);const o=(0,r.createContext)({hasCheckoutStarted:!1,setHasCheckoutStarted:()=>{}}),l=({children:e})=>{const[t,a]=(0,r.useState)(!1);return React.createElement(o.Provider,{value:{hasCheckoutStarted:t,setHasCheckoutStarted:a}},e)},u=()=>(0,r.useContext)(o);function d({redirectUrl:e}={}){const{adminUrl:t}=window.jetpackProtectInitialState||{},{data:a,isLoading:o}=(0,i.A)(),{hasCheckoutStarted:l,setHasCheckoutStarted:d}=u(),{run:p}=(0,n.useProductCheckoutWorkflow)({productSlug:s.J3,redirectUrl:e||t,siteProductAvailabilityHandler:c.A.checkPlan,useBlogIdSuffix:!0,connectAfterCheckout:!1,from:()=>"protect"});return{hasPlan:a,upgradePlan:(0,r.useCallback)((()=>{d(!0),p()}),[p,d]),isLoading:o||l}}},9701:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(7723),r=a(1609),c=a(1859),s=a(2425),i=a(7651);const __=n.__,o=["all","core","plugins","themes","files","database"],l=(e,t,a)=>Array.isArray(e)?e.filter((e=>(!t.status||"all"===t.status||e.status===t.status)&&(!t.key||"all"===t.key||t.key===a))):[];function u({sourceType:e,filter:t}={sourceType:"scan",filter:{status:null,key:null}}){const{data:a}=(0,s.Ay)(),{data:n}=(0,c.A)(),{data:u}=(0,i.A)(),{counts:d,results:p,error:m,lastChecked:h,hasUncheckedItems:g}=(0,r.useMemo)((()=>{const r="history"===e?{...n}:{...a},c={results:{core:[],plugins:[],themes:[],files:[],database:[]},counts:{all:{threats:0,core:0,plugins:0,themes:0,files:0,database:0},current:{threats:0,core:0,plugins:0,themes:0,files:0,database:0}},error:null,lastChecked:r.lastChecked||null,hasUncheckedItems:r.hasUncheckedItems||!1},s=(e,a)=>{if(!Array.isArray(e))return[];e.forEach((e=>{c.counts.all[a]+=e?.threats?.length||0,c.counts.all.threats+=e?.threats?.length||0;const n=l(e?.threats||[],t,o.includes(t.key)?a:e?.name);c.results[a].push({...e,threats:n}),c.counts.current[a]+=n.length,c.counts.current.threats+=n.length}))},i=(e,a)=>{if(!Array.isArray(e))return[];c.counts.all[a]+=e.length,c.counts.all.threats+=e.length;const n=l(e,t,a);c.results[a]=[...c.results[a],...n],c.counts.current[a]+=n.length,c.counts.current.threats+=n.length};let u=Array.isArray(r.core)?r.core:[];return r?.core?.threats&&(u=[r.core]),s(u,"core"),s(r?.plugins,"plugins"),s(r?.themes,"themes"),i(r?.files,"files"),i(r?.database,"database"),r.error&&(c.error={message:r.errorMessage||__("An error occurred.","jetpack-protect"),code:r.errorCode||500}),c}),[n,e,a,t]);return{results:p,counts:d,error:m,lastChecked:h,hasUncheckedItems:g,jetpackScan:u}}},6516:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(1609),r=a(9481),c=a(3990),s=a(5728),i=a(1226);const o=()=>{const{recordEvent:e}=(0,i.A)(),{data:t}=(0,s.A)(),a=(0,c.A)(),o=(0,r.A)(),l=(0,n.useCallback)((async()=>{o.mutate()}),[o]),u=(0,n.useCallback)((async()=>!!t.isEnabled||await l()),[l,t.isEnabled]),d=(0,n.useCallback)((async()=>{const n=!t.config.jetpackWafAutomaticRules;await u(),await a.mutateAsync({jetpack_waf_automatic_rules:n}),e(n?"jetpack_protect_automatic_rules_enabled":"jetpack_protect_automatic_rules_disabled")}),[u,e,t.config.jetpackWafAutomaticRules,a]),p=(0,n.useCallback)((async()=>{const n=!t.config.jetpackWafIpAllowListEnabled;await a.mutateAsync({jetpack_waf_ip_allow_list_enabled:n}),e(n?"jetpack_protect_ip_allow_list_enabled":"jetpack_protect_ip_allow_list_disabled")}),[e,t.config.jetpackWafIpAllowListEnabled,a]),m=(0,n.useCallback)((async t=>{await a.mutateAsync({jetpack_waf_ip_allow_list:t}),e("jetpack_protect_ip_allow_list_updated")}),[e,a]),h=(0,n.useCallback)((async()=>{const n=!t.config.jetpackWafIpBlockListEnabled;await u(),await a.mutateAsync({jetpack_waf_ip_block_list_enabled:n}),e(n?"jetpack_protect_ip_block_list_enabled":"jetpack_protect_ip_block_list_disabled")}),[u,e,t.config.jetpackWafIpBlockListEnabled,a]),g=(0,n.useCallback)((async t=>{await u(),await a.mutateAsync({jetpack_waf_ip_block_list:t}),e("jetpack_protect_ip_block_list_updated")}),[u,a,e]),v=(0,n.useCallback)((async()=>{const n=!t.config.bruteForceProtection;await a.mutateAsync({brute_force_protection:n}),e(n?"jetpack_protect_brute_force_protection_enabled":"jetpack_protect_brute_force_protection_disabled")}),[e,t.config.bruteForceProtection,a]),f=(0,n.useCallback)((async()=>{const n=!t.config.jetpackWafShareData,r={jetpack_waf_share_data:n};n||(r.jetpack_waf_share_debug_data=!1),await a.mutateAsync(r),e(r?"jetpack_protect_share_data_enabled":"jetpack_protect_share_data_disabled")}),[e,t.config.jetpackWafShareData,a]),y=(0,n.useCallback)((async()=>{const n=!t.config.jetpackWafShareDebugData,r={jetpack_waf_share_debug_data:n};n&&(r.jetpack_waf_share_data=!0),await a.mutateAsync(r),e(n?"jetpack_protect_share_debug_data_enabled":"jetpack_protect_share_debug_data_disabled")}),[e,t.config.jetpackWafShareDebugData,a]);return{...t,isUpdating:a.isPending,isToggling:o.isPending,toggleWaf:l,toggleAutomaticRules:d,toggleIpAllowList:p,saveIpAllowList:m,toggleIpBlockList:h,saveIpBlockList:g,toggleBruteForceProtection:v,toggleShareData:f,toggleShareDebugData:y}}},6088:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var n=a(7425),r=a(1158),c=a(7723),s=a(1609),i=a(7031),o=a(6516),l=a(9347),u=a(5546);const __=c.__,d=()=>{const{config:{jetpackWafAutomaticRules:e,automaticRulesAvailable:t,standaloneMode:a,bruteForceProtection:c},isEnabled:d,wafSupported:p,isToggling:m}=(0,o.A)(),h=m?"loading":(p?d:c)?"on":"off",g=(0,s.useMemo)((()=>"on"===h?a?__("Standalone mode","jetpack-protect"):__("Active","jetpack-protect",0):__("Inactive","jetpack-protect")),[h,a]),v=(0,s.useMemo)((()=>"on"===h?React.createElement(React.Fragment,null,!p&&__("Brute force protection is active","jetpack-protect"),p&&(e?__("Automatic firewall is on","jetpack-protect"):__("Firewall is on","jetpack-protect",0))):"off"===h?React.createElement(React.Fragment,null,!p&&__("Brute force protection is disabled","jetpack-protect"),p&&(t?__("Automatic firewall is off","jetpack-protect"):__("Firewall is off","jetpack-protect",0))):"loading"===h?__("Automatic firewall is being set up","jetpack-protect"):null),[h,p,e,t]),f=(0,s.useMemo)((()=>"loading"===h?React.createElement(n.Ay,null,__("Please wait…","jetpack-protect")):React.createElement(u.A,null)),[h]);return React.createElement(i.A,{main:React.createElement(React.Fragment,null,React.createElement(r.A,{status:"on"===h?"active":"inactive",label:g}),React.createElement(i.A.Heading,null,v),React.createElement(i.A.Subheading,null,f)),secondary:p&&React.createElement(l.A,null)})}},8567:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var n=a(7425),r=a(1112),c=a(8316),s=a(5918),i=a(8509),o=a(7723),l=a(1609),u=a(1009),d=a(4537),p=a(6516),m=a(7642);const __=o.__,h=()=>{const{setModal:e}=(0,u.A)();return React.createElement("div",{className:m.A["standalone-mode"]},React.createElement(n.hE,{mb:0},__("Standalone mode","jetpack-protect")),React.createElement("div",null,React.createElement(n.Ay,null,__("Learn how you can execute the firewall before WordPress initializes.","jetpack-protect")),React.createElement(n.Ay,null,__("This mode offers the most protection.","jetpack-protect"))),React.createElement(r.A,{variant:"link",isExternalLink:!0,weight:"regular",onClick:t=>{t.preventDefault(),e({type:"STANDALONE_MODE"})}},__("Learn more","jetpack-protect")))},g=()=>{const{config:e,isUpdating:t,toggleShareData:a,toggleShareDebugData:r}=(0,p.A)(),{jetpackWafShareData:s,jetpackWafShareDebugData:i}=e||{},{showSuccessNotice:o,showErrorNotice:u}=(0,d.A)(),h=(0,l.useCallback)((async()=>{try{await a(),o(__("Changes saved.","jetpack-protect"))}catch{u()}}),[a,o,u]),g=(0,l.useCallback)((async()=>{try{await r(),o(__("Changes saved.","jetpack-protect"))}catch{u()}}),[r,o,u]);return React.createElement("div",{className:m.A["share-data"]},React.createElement(n.hE,{mb:0},__("Share data with Jetpack","jetpack-protect")),React.createElement(c.A,{className:m.A["share-data-toggle"],checked:!!s,onChange:h,disabled:t,size:"small",label:__("Share basic data","jetpack-protect"),help:__("Allow Jetpack to collect basic data from blocked requests to improve firewall protection and accuracy.","jetpack-protect")}),React.createElement(c.A,{className:m.A["share-data-toggle"],checked:!!i,onChange:g,disabled:t,size:"small",label:__("Share detailed data","jetpack-protect"),help:__("Allow Jetpack to collect detailed data from blocked requests to enhance firewall protection and accuracy.","jetpack-protect")}))},v=()=>{const{isEnabled:e}=(0,p.A)();return React.createElement("div",{className:m.A.footer},React.createElement(s.A,{horizontalSpacing:8,horizontalGap:7},React.createElement(i.A,{sm:12,md:6,lg:7},React.createElement(h,null)),e&&React.createElement(i.A,{sm:12,md:6,lg:5},React.createElement(g,null))))}},9347:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(442),r=a(7425),c=a(3390),s=a(7723),i=a(1113),o=a(5302),l=a(7267),u=a(1609),d=a(5925),p=a(6516),m=a(7642);const __=s.__,h=()=>{const{hasPlan:e}=(0,d.Ay)(),{config:{bruteForceProtection:t},isEnabled:a,wafSupported:h,stats:g}=(0,p.A)(),[v]=(0,n.A)(["sm","lg"],[null,"<"]),f=h?a:t,{currentDay:y,thirtyDays:E}=g?g.blockedRequests:{currentDay:0,thirtyDays:0},A=!f||!e,b=(0,u.useMemo)((()=>({className:A?m.A.disabled:m.A.active,variant:v?"horizontal":"square"})),[A,v]),w=(0,u.useCallback)((({icon:t})=>React.createElement("span",{className:m.A["stat-card-icon"]},React.createElement(i.A,{icon:t}),!v&&!e&&React.createElement(r.Ay,{variant:"label"},__("Paid feature","jetpack-protect")))),[v,e]),k=(0,u.useCallback)((({period:e,units:t})=>v?React.createElement("span",null,(0,s.sprintf)(/* translators: Translates to Blocked requests last %1$d: Number of units. %2$s: Unit of time (hours, days, etc) */ -__("Blocked requests last %1$d %2$s","jetpack-protect"),e,t)):React.createElement("span",{className:m.A["stat-card-label"]},React.createElement("span",null,__("Blocked requests","jetpack-protect")),React.createElement("br",null),React.createElement("span",null,(0,s.sprintf)(/* translators: Translates to Last %1$d: Number of units. %2$s: Unit of time (hours, days, etc) */ -__("Last %1$d %2$s","jetpack-protect"),e,t)))),[v]),R=(0,u.useMemo)((()=>({...b,icon:React.createElement(w,{icon:o.A}),label:React.createElement(k,{period:24,units:"hours"}),value:A?0:y})),[b,w,k,A,y]),C=(0,u.useMemo)((()=>({...b,icon:React.createElement(w,{icon:l.A}),label:React.createElement(k,{period:30,units:"days"}),value:A?0:E})),[b,w,k,A,E]);return React.createElement("div",{className:m.A["stat-card-wrapper"]},React.createElement(c.A,R),React.createElement(c.A,C))}},5546:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var n=a(597),r=a(7425),c=a(7723),s=a(1609),i=a(5925),o=a(6516),l=a(3969),u=a(7642);const __=c.__,d=()=>{const{hasPlan:e}=(0,i.Ay)(),{config:{jetpackWafAutomaticRules:t,jetpackWafIpBlockListEnabled:a,jetpackWafIpAllowListEnabled:c,automaticRulesAvailable:d,bruteForceProtection:p},wafSupported:m}=(0,o.A)(),h=a||c,g=(0,s.useMemo)((()=>({allRules:m&&t&&h,automaticRules:m&&t&&!h,manualRules:m&&!t&&h,noRules:m&&!t&&!h})),[m,t,h]),v=(0,s.useMemo)((()=>{const e=[];return m&&p&&e.push(__("Brute force protection is active.","jetpack-protect")),g.noRules&&e.push(__("There are no firewall rules applied.","jetpack-protect")),g.automaticRules&&e.push(__("Automatic firewall rules apply.","jetpack-protect")),g.manualRules&&e.push(__("Only manual IP list rules apply.","jetpack-protect")),g.allRules&&e.push(__("All firewall rules apply.","jetpack-protect")),e.join(" ")}),[m,p,g]),f=(0,s.useMemo)((()=>d?__("The free version of the firewall does not receive updates to automatic security rules.","jetpack-protect",0):__("The free version of the firewall only allows for use of manual rules.","jetpack-protect")),[d]);return React.createElement(React.Fragment,null,React.createElement("div",{className:u.A["firewall-subheading"]},React.createElement(r.Ay,null,v),!e&&(g.automaticRules||g.manualRules||g.allRules)?React.createElement(n.A,{className:u.A["icon-tooltip"],iconCode:"help-outline",iconSize:20,iconClassName:u.A["icon-tooltip__icon"],placement:"top",hoverShow:!0},React.createElement(r.Ay,null,f)):null),!e&&m&&React.createElement(l.A,null))}},3969:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var n=a(1112),r=a(7723),c=a(1609),s=a(1226),i=a(5925),o=a(6516),l=a(7642);const __=r.__,u=()=>{const{recordEvent:e}=(0,s.A)(),{adminUrl:t}=window.jetpackProtectInitialState||{},a=t+"#/firewall",{upgradePlan:r}=(0,i.Ay)({redirectUrl:a}),{config:{automaticRulesAvailable:u}}=(0,o.A)(),d=(0,c.useCallback)((()=>{e("jetpack_protect_waf_header_get_scan_link_click"),r()}),[e,r]);return React.createElement(n.A,{className:l.A["upgrade-prompt-button"],onClick:d},u?__("Upgrade to update automatic security rules","jetpack-protect",0):__("Upgrade to enable automatic firewall protection","jetpack-protect"))}},1671:(e,t,a)=>{"use strict";a.d(t,{A:()=>N});var n=a(442),r=a(7656),c=a(7425),s=a(1112),i=a(8316),o=a(4437),l=a(5918),u=a(8509),d=a(6427),p=a(6087),m=a(7723),h=a(1113),g=a(1249),v=a(6154),f=a.n(v),y=a(1609),E=a(1186),A=a(4491),b=a(8140),w=a(5632),k=a(1226),R=a(5925),C=a(6516),_=a(5285),j=a(6088),x=a(8567),S=a(7642);const __=m.__,M=window?.jetpackProtectInitialState?.adminUrl,N=()=>{const[e]=(0,n.A)(["sm","lg"],[null,"<"]),{config:{jetpackWafAutomaticRules:t,jetpackWafIpBlockListEnabled:a,jetpackWafIpAllowListEnabled:v,jetpackWafIpBlockList:N,jetpackWafIpAllowList:L,automaticRulesAvailable:P,bruteForceProtection:z},currentIp:O,isEnabled:I,upgradeIsSeen:F,displayUpgradeBadge:V,wafSupported:D,isUpdating:H,stats:T,toggleAutomaticRules:B,toggleIpAllowList:q,saveIpAllowList:U,toggleIpBlockList:$,saveIpBlockList:Q,toggleBruteForceProtection:J,toggleWaf:W}=(0,C.A)(),{hasPlan:Z}=(0,R.Ay)(),{upgradePlan:G}=(0,R.Ay)({redirectUrl:`${M}#/firewall`}),{recordEvent:K}=(0,k.A)(),X=(0,w.A)(),{automaticRulesLastUpdated:Y}=T,[ee,te]=(0,y.useState)(!1),[ae,ne]=(0,y.useState)({jetpack_waf_ip_block_list:N,jetpack_waf_ip_allow_list:L}),re=I&&!H,ce=I&&(Z||P),se=!H&&v,ie=ae.jetpack_waf_ip_block_list!==N,oe=ae.jetpack_waf_ip_allow_list!==L,le=!!ae.jetpack_waf_ip_block_list,ue=!!ae.jetpack_waf_ip_allow_list,de=I&&a,pe=(0,y.useCallback)((()=>{K("jetpack_protect_waf_page_get_scan_link_click"),G()}),[K,G]),me=(0,y.useCallback)((e=>{const{value:t,id:a}=e.target;ne({...ae,[a]:t})}),[ae]),he=(0,y.useCallback)((()=>{ne((e=>({...e,jetpack_waf_automatic_rules:!e.jetpack_waf_automatic_rules})));try{B(),te(!1)}catch{te(!0),ne((e=>({...e,jetpack_waf_automatic_rules:!e.jetpack_waf_automatic_rules})))}}),[B]),ge=(0,y.useCallback)((async()=>{await Q(ae.jetpack_waf_ip_block_list)}),[Q,ae.jetpack_waf_ip_block_list]),ve=(0,y.useCallback)((async()=>{await U(ae.jetpack_waf_ip_allow_list)}),[U,ae.jetpack_waf_ip_allow_list]),fe=(0,y.useCallback)((()=>{X.mutate()}),[X]),ye=(0,y.useMemo)((()=>ae.jetpack_waf_ip_allow_list?.includes(O)),[ae.jetpack_waf_ip_allow_list,O]),Ee=(0,y.useCallback)((()=>{const e=ae.jetpack_waf_ip_allow_list.length>0?`${ae.jetpack_waf_ip_allow_list}\n${O}`:O;ne((t=>({...t,jetpack_waf_ip_allow_list:e})))}),[ae.jetpack_waf_ip_allow_list,O]);(0,y.useEffect)((()=>{H||ne({jetpack_waf_ip_block_list:N,jetpack_waf_ip_allow_list:L})}),[N,L,H]),(0,k.A)({pageViewEventName:"protect_waf",pageViewEventProperties:{has_plan:Z}});const Ae=React.createElement(r.A,{level:"error",title:"Jetpack Firewall is currently disabled.",children:React.createElement(c.Ay,null,__("Re-enable the Firewall to continue.","jetpack-protect")),actions:[React.createElement(s.A,{key:"enable",variant:"link",onClick:W,isLoading:H,disabled:H},__("Enable Firewall","jetpack-protect"))],hideCloseButton:!0}),be=React.createElement(React.Fragment,null,React.createElement("div",{className:`${S.A["toggle-section"]} ${ce?"":S.A["toggle-section--disabled"]}`},React.createElement("div",{className:S.A["toggle-section__control"]},React.createElement(i.A,{checked:!!ce&&t,onChange:he,disabled:!re||!ce||H}),Z&&!1===F&&React.createElement(d.Popover,{noArrow:!1,offset:8,position:"top right",inline:!0},React.createElement("div",{className:S.A.popover},React.createElement("div",{className:S.A.popover__header},React.createElement(c.Ay,{className:S.A.popover__title,variant:"title-small"},__("Thanks for upgrading!","jetpack-protect")),React.createElement(s.A,{className:S.A.popover__button,variant:"icon"},React.createElement(h.A,{onClick:fe,icon:g.A,size:24,"aria-label":__("Close Window","jetpack-protect")}))),React.createElement(c.Ay,{className:S.A.popover__description,variant:"body",mt:2,mb:3},__("Turn on Automatic firewall protection to apply the latest security rules.","jetpack-protect")),React.createElement("div",{className:S.A.popover__footer},React.createElement(s.A,{onClick:fe},__("Got it","jetpack-protect")))))),React.createElement("div",{className:S.A["toggle-section__content"]},React.createElement("div",{className:S.A["toggle-section__title"]},React.createElement(c.Ay,{variant:"title-medium",mb:2},__("Automatic firewall protection","jetpack-protect")),!e&&Z&&V&&React.createElement("span",{className:S.A.badge},__("NOW AVAILABLE","jetpack-protect"))),React.createElement(c.Ay,null,__("Block untrusted traffic by scanning every request made to your site. Jetpack’s security rules are always up-to-date to protect against the latest threats.","jetpack-protect")),React.createElement("div",{className:S.A["toggle-section__details"]},t&&Y&&!ee&&React.createElement("div",{className:S.A["automatic-rules-stats"]},React.createElement(c.Ay,{className:S.A["automatic-rules-stats__version"],variant:"body-small"},__("Automatic security rules installed.","jetpack-protect")),React.createElement(c.Ay,{className:S.A["automatic-rules-stats__last-updated"],variant:"body-small"},(0,m.sprintf)( -// translators: placeholder is the date latest rules were updated i.e. "September 23, 2022". -__("Last updated on %s.","jetpack-protect"),f().unix(Y).format("MMMM D, YYYY")))),ee&&React.createElement(React.Fragment,null,React.createElement(c.Ay,{className:S.A["automatic-rules-stats__failed-install"],variant:"body-small",mt:2},__("Failed to update automatic firewall rules.","jetpack-protect")),React.createElement(s.A,{variant:"link",href:Z?b.NW:b.pQ},React.createElement(c.Ay,{variant:"body-small"},__("Contact support","jetpack-protect"))))))),!Z&&React.createElement("div",{className:S.A["upgrade-trigger-section"]},React.createElement(o.A,{className:S.A["upgrade-trigger"],description:ce?__("Your site is not receiving the latest updates to automatic rules","jetpack-protect",0):__("Set up automatic rules with one click","jetpack-protect"),cta:ce?__("Upgrade to keep your site secure with up-to-date firewall rules","jetpack-protect",0):__("Upgrade to enable automatic firewall protection","jetpack-protect"),onClick:pe}))),we=React.createElement("div",{className:S.A["toggle-section"]},React.createElement("div",{className:S.A["toggle-section__control"]},React.createElement(i.A,{checked:z,onChange:J,disabled:H})),React.createElement("div",{className:S.A["toggle-section__content"]},React.createElement(c.Ay,{variant:"title-medium",mb:2},__("Brute force protection","jetpack-protect")),React.createElement(c.Ay,null,__("Prevent bots and hackers from attempting to log in to your website with common username and password combinations.","jetpack-protect")))),ke=React.createElement("div",{className:`${S.A["toggle-section"]} ${I?"":S.A["toggle-section--disabled"]}`},React.createElement("div",{className:S.A["toggle-section__control"]},React.createElement(i.A,{checked:de,onChange:$,disabled:!re})),React.createElement("div",{className:S.A["toggle-section__content"]},React.createElement(c.Ay,{variant:"title-medium",mb:2},__("Block IP addresses","jetpack-protect")),React.createElement(c.Ay,{mb:1},__("Stop specific visitors from accessing your site by their IP address.","jetpack-protect")),(de||le)&&React.createElement("div",{className:S.A["manual-rules-section"]},React.createElement(A.A,{id:"jetpack_waf_ip_block_list",placeholder:__("Example:","jetpack-protect")+"\n12.12.12.1\n12.12.12.2",rows:3,value:ae.jetpack_waf_ip_block_list,onChange:me,disabled:!re||!de}),de&&React.createElement(c.Ay,{variant:"body-extra-small",mt:1},__("IPv4 and IPv6 supported. Separate IPs with commas, spaces, or new lines. To specify a range, use CIDR notation (i.e. 12.12.12.0/24) or enter the low value and high value separated by a dash (i.e. 12.12.12.0–12.12.12.255).","jetpack-protect"))),de&&React.createElement("div",{className:S.A["block-list-button-container"]},React.createElement(s.A,{onClick:ge,isLoading:H,disabled:!re||!ie},__("Save block list","jetpack-protect"))))),Re=React.createElement(React.Fragment,null,React.createElement("div",{className:S.A["toggle-section"]},React.createElement("div",{className:S.A["toggle-section__control"]},React.createElement(i.A,{checked:v,onChange:q,disabled:H})),React.createElement("div",{className:S.A["toggle-section__content"]},React.createElement(c.Ay,{variant:"title-medium",mb:2},__("Trusted IP addresses","jetpack-protect")),React.createElement(c.Ay,{mb:1},__("IP addresses added to this list are always allowed to access your site, regardless of any other Jetpack security settings.","jetpack-protect")),(v||ue)&&React.createElement("div",{className:S.A["manual-rules-section"]},React.createElement(A.A,{id:"jetpack_waf_ip_allow_list",placeholder:__("Example:","jetpack-protect")+"\n12.12.12.1\n12.12.12.2",rows:3,value:ae.jetpack_waf_ip_allow_list,onChange:me,disabled:!se}),v&&React.createElement(c.Ay,{variant:"body-extra-small",mt:1},__("IPv4 and IPv6 supported. Separate IPs with commas, spaces, or new lines. To specify a range, use CIDR notation (i.e. 12.12.12.0/24) or enter the low value and high value separated by a dash (i.e. 12.12.12.0–12.12.12.255).","jetpack-protect"))),v&&React.createElement("div",{className:S.A["allow-list-button-container"]},React.createElement("div",null,React.createElement(c.Ay,{variant:"body-small",className:S.A["allow-list-current-ip"]},(0,p.createInterpolateElement)((0,m.sprintf)( -// translators: placeholder is the user's current IP address. -__("Your current IP: %s","jetpack-protect"),O),{strong:React.createElement("strong",null)})),React.createElement(s.A,{variant:"secondary",size:"small",onClick:Ee,disabled:!se||ye||H},__("+ Add to Allow List","jetpack-protect"))),React.createElement(s.A,{onClick:ve,isLoading:H,disabled:H||!oe},__("Save allow list","jetpack-protect"))))));return React.createElement(E.A,null,React.createElement(j.A,null),React.createElement(l.A,{className:S.A.container,horizontalSpacing:8,horizontalGap:4},D&&!I&&React.createElement(u.A,null,Ae," "),React.createElement(u.A,null,React.createElement("div",{className:S.A["toggle-wrapper"]},D&&be,we,D&&React.createElement(React.Fragment,null,ke,React.createElement("div",{className:S.A.divider})),Re))),D?React.createElement(x.A,null):React.createElement(_.A,null))}},2014:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var n=a(1158),r=a(7425),c=a(8443),s=a(7723),i=a(1609),o=a(9539),l=a(7031),u=a(2652),d=a(9889),p=a(993),m=a(9701),h=a(5960);const __=s.__,g=()=>{const{filter:e="all"}=(0,o.g)(),{list:t}=(0,p.A)({source:"history",status:e}),{counts:a,error:g}=(0,m.A)({sourceType:"history",filter:{status:e}}),{threats:v}=a.all,f=(0,i.useMemo)((()=>t.length?t.reduce(((e,t)=>new Date(t.firstDetected)0?(0,s.sprintf)(/* translators: %s: Total number of threats */ -__("%1$s previously active %2$s","jetpack-protect"),v,1===v?"threat":"threats"):__("No previously active threats","jetpack-protect")),React.createElement(l.A.Subheading,null,React.createElement(r.Ay,null,f?React.createElement("span",{className:h.A["subheading-content"]},(0,s.sprintf)(/* translators: %s: Oldest first detected date */ -__("%s - Today","jetpack-protect"),(0,c.dateI18n)("F jS g:i A",f,!1))):__("Most recent results","jetpack-protect"))),React.createElement("div",{className:h.A["scan-navigation"]},React.createElement(d.A,null)))})}},5717:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var n=a(5640),r=a(5918),c=a(8509),s=a(7425),i=a(7723),o=a(1609),l=a(9539),u=a(1186),d=a(7827),p=a(9395),m=a(6742),h=a(993),g=a(1226),v=a(5925),f=a(9701),y=a(5285),E=a(2014),A=a(2621),b=a(5960);const __=i.__,_n=i._n,w=()=>{(0,g.A)({pageViewEventName:"protect_scan_history"});const{hasPlan:e}=(0,v.Ay)(),{filter:t="all"}=(0,l.g)(),{item:a,list:w,selected:k,setSelected:R}=(0,h.A)({source:"history",status:t}),{counts:C,error:_}=(0,f.A)({sourceType:"history",filter:{status:t}}),{threats:j}=C.all,{counts:x}=(0,f.A)({sourceType:"history",filter:{status:"fixed",key:k}}),{threats:S}=x.current,{counts:M}=(0,f.A)({sourceType:"history",filter:{status:"ignored",key:k}}),{threats:N}=M.current,L=(0,o.useCallback)((()=>{switch(k){case"all":if(1===w.length)switch(t){case"fixed":return __("All fixed threats","jetpack-protect");case"ignored":return __("All ignored threats","jetpack-protect",0);default:return __("All threats","jetpack-protect")}switch(t){case"fixed":return(0,i.sprintf)(/* translators: placeholder is the amount of fixed threats found on the site. */ -__("All %s fixed threats","jetpack-protect"),w.length);case"ignored":return(0,i.sprintf)(/* translators: placeholder is the amount of ignored threats found on the site. */ -__("All %s ignored threats","jetpack-protect"),w.length);default:return(0,i.sprintf)(/* translators: placeholder is the amount of threats found on the site. */ -__("All %s threats","jetpack-protect"),w.length)}case"core":switch(t){case"fixed":return(0,i.sprintf)(/* translators: placeholder is the amount of fixed WordPress threats found on the site. */ -_n("%1$s fixed WordPress threat","%1$s fixed WordPress threats",w.length,"jetpack-protect"),w.length);case"ignored":return(0,i.sprintf)(/* translators: placeholder is the amount of ignored WordPress threats found on the site. */ -_n("%1$s ignored WordPress threat","%1$s ignored WordPress threats",w.length,"jetpack-protect"),w.length);default:return(0,i.sprintf)(/* translators: placeholder is the amount of WordPress threats found on the site. */ -_n("%1$s WordPress threat","%1$s WordPress threats",w.length,"jetpack-protect"),w.length)}case"files":switch(t){case"fixed":return(0,i.sprintf)(/* translators: placeholder is the amount of fixed file threats found on the site. */ -_n("%1$s fixed file threat","%1$s fixed file threats",w.length,"jetpack-protect"),w.length);case"ignored":return(0,i.sprintf)(/* translators: placeholder is the amount of ignored file threats found on the site. */ -_n("%1$s ignored file threat","%1$s ignored file threats",w.length,"jetpack-protect"),w.length);default:return(0,i.sprintf)(/* translators: placeholder is the amount of file threats found on the site. */ -_n("%1$s file threat","%1$s file threats",w.length,"jetpack-protect"),w.length)}case"database":switch(t){case"fixed":return(0,i.sprintf)(/* translators: placeholder is the amount of fixed database threats found on the site. */ -_n("%1$s fixed database threat","%1$s fixed database threats",w.length,"jetpack-protect"),w.length);case"ignored":return(0,i.sprintf)(/* translators: placeholder is the amount of ignored database threats found on the site. */ -_n("%1$s ignored database threat","%1$s ignored database threats",w.length,"jetpack-protect"),w.length);default:return(0,i.sprintf)(/* translators: placeholder is the amount of database threats found on the site. */ -_n("%1$s database threat","%1$s database threats",w.length,"jetpack-protect"),w.length)}default:switch(t){case"fixed":return(0,i.sprintf)(/* translators: Translates to "123 fixed threats in Example Plugin (1.2.3)" */ -_n("%1$s fixed threat in %2$s %3$s","%1$s fixed threats in %2$s %3$s",w.length,"jetpack-protect"),w.length,a?.name,a?.version);case"ignored":return(0,i.sprintf)(/* translators: Translates to "123 ignored threats in Example Plugin (1.2.3)" */ -_n("%1$s ignored threat in %2$s %3$s","%1$s ignored threats in %2$s %3$s",w.length,"jetpack-protect"),w.length,a?.name,a?.version);default:return(0,i.sprintf)(/* translators: Translates to "123 threats in Example Plugin (1.2.3)" */ -_n("%1$s threat in %2$s %3$s","%1$s threats in %2$s %3$s",w.length,"jetpack-protect"),w.length,a?.name,a?.version)}}}),[k,w.length,t,a?.name,a?.version]);return e?0===w.length&&"all"!==t?React.createElement(l.C5,{to:"/scan/history"}):React.createElement(u.A,null,React.createElement(E.A,null),(!_||j)&&React.createElement(n.A,null,React.createElement(r.A,{horizontalSpacing:7,horizontalGap:4},React.createElement(c.A,null,React.createElement(r.A,{fluid:!0,horizontalSpacing:0,horizontalGap:3},React.createElement(c.A,{lg:4},React.createElement(p.A,{selected:k,onSelect:R,sourceType:"history",statusFilter:t})),React.createElement(c.A,{lg:8},w.length>0?React.createElement("div",null,React.createElement("div",{className:b.A["list-header"]},React.createElement(s.hE,{className:b.A["list-title"]},L()),React.createElement("div",{className:b.A["list-header__controls"]},React.createElement(A.A,{numFixed:S,numIgnored:N}))),React.createElement(m.A,{list:w,hideAutoFixColumn:!0})):React.createElement(React.Fragment,null,React.createElement("div",{className:b.A["list-header"]},React.createElement("div",{className:b.A["list-header__controls"]},React.createElement(A.A,null))),React.createElement("div",{className:b.A.empty},React.createElement(d.A,null),React.createElement(s.H3,{weight:"bold",mt:8},__("Don't worry about a thing","jetpack-protect")),React.createElement(s.Ay,{mb:4},(0,i.sprintf)(/* translators: %s: Filter type */ -__("There are no%sthreats in your scan history.","jetpack-protect"),"all"===t?" ":` ${t} `))))))))),React.createElement(y.A,null)):React.createElement(l.C5,{to:"/scan"})}},2621:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var n=a(7723),r=a(1609),c=a.n(r),s=a(9539),i=a(4907);const __=n.__;function o({numFixed:e,numIgnored:t}){const a=(0,s.Zp)(),{filter:n="all"}=(0,s.g)(),o=(0,r.useCallback)((e=>()=>a(e)),[a]);return c().createElement(i.A,null,c().createElement(i.A.Button,{variant:"all"===n?"primary":"secondary",onClick:o("/scan/history")},__("All","jetpack-protect")),c().createElement(i.A.Button,{variant:"fixed"===n?"primary":"secondary",onClick:o("/scan/history/fixed"),disabled:!e},__("Fixed","jetpack-protect")),c().createElement(i.A.Button,{variant:"ignored"===n?"primary":"secondary",onClick:o("/scan/history/ignored"),disabled:!t},__("Ignored","jetpack-protect")))}},5148:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var n=a(5640),r=a(5918),c=a(8509),s=a(1186),i=a(5661),o=a(2425),l=a(1226),u=a(1936),d=a(5925),p=a(9701),m=a(3411),h=a(4446),g=a(5285);const v=()=>{const{hasPlan:e}=(0,d.Ay)(),{counts:{current:{threats:t}},lastChecked:a}=(0,p.A)(),{data:v}=(0,o.Ay)({usePolling:!0});let f;return f=v.error?"error":a?"active":"in_progress",(0,l.A)({pageViewEventName:"protect_admin",pageViewEventProperties:{check_status:f,has_plan:e}}),React.createElement(u.dn.Provider,{value:m.A},React.createElement(s.A,null,React.createElement(h.A,null),(!v.error||t)&&React.createElement(n.A,null,React.createElement(r.A,{horizontalSpacing:7,horizontalGap:4},React.createElement(c.A,null,React.createElement(i.A,null)))),React.createElement(g.A,null)))}},3411:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var n=a(6072),r=a.n(n),c=a(7425),s=a(1112),i=a(3924),o=a(6087),l=a(7723),u=a(1226),d=a(5925);const __=l.__,{siteSuffix:p}=window.jetpackProtectInitialState,m=__("Your scan results","jetpack-protect"),h=React.createElement(c.Ay,null,__("Navigate through the results of the scan on your WordPress installation, plugins, themes, and other files","jetpack-protect")),g=e=>{const{upgradePlan:t}=(0,d.Ay)(),{recordEvent:a}=(0,u.A)(),n=(0,o.useCallback)((()=>{a("jetpack_protect_onboarding_get_scan_link_click"),t()}),[a,t]);return React.createElement(s.A,r()({variant:"link",weight:"regular",onClick:n},e))},v=[{id:"free-scan-results",title:m,description:h},{id:"free-daily-scans",title:__("Daily automated scans","jetpack-protect"),description:React.createElement(c.Ay,null,(0,o.createInterpolateElement)(__("We run daily automated scans. Do you want to be able to scan manually? Upgrade","jetpack-protect"),{upgradeLink:React.createElement(g,null)}))},{id:"paid-scan-results",title:m,description:h},{id:"paid-fix-all-threats",title:__("Auto-fix with one click","jetpack-protect"),description:React.createElement(c.Ay,null,__("Jetpack Protect offers one-click fixes for most threats. Press this button to be safe again.","jetpack-protect"),React.createElement("br",null),React.createElement("br",null),(0,o.createInterpolateElement)(__("Note that you'll have to input your server credentials first.","jetpack-protect"),{credentialsLink:React.createElement(s.A,{variant:"link",weight:"regular",href:(0,i.A)("jetpack-settings-security-credentials",{site:p})})}))},{id:"paid-understand-severity",title:__("Understand severity","jetpack-protect"),description:React.createElement(c.Ay,null,__("Learn how critical these threats are for the security of your site by glancing at the severity labels.","jetpack-protect"))},{id:"paid-daily-and-manual-scans",title:__("Daily & manual scanning","jetpack-protect"),description:React.createElement(c.Ay,null,__("We run daily automated scans but you can also run on-demand scans if you want to check the latest status.","jetpack-protect"))}]},4446:(e,t,a)=>{"use strict";a.d(t,{A:()=>y});var n=a(442),r=a(1158),c=a(7425),s=a(8443),i=a(7723),o=a(1609),l=a(7031),u=a(2652),d=a(4254),p=a(9889),m=a(2425),h=a(5925),g=a(9701),v=a(3752),f=a(6359);const __=i.__,_n=i._n,y=()=>{const{hasPlan:e}=(0,h.Ay)(),[t]=(0,n.A)("sm"),{counts:{current:{threats:a}},lastChecked:y}=(0,g.A)(),{data:E}=(0,m.Ay)(),[A,b]=(0,o.useState)(null);let w=null;return y&&(w=new Date(y+" UTC").getTime()),(0,m.EV)(E)?React.createElement(v.A,null):E.error?React.createElement(u.A,{baseErrorMessage:__("We are having problems scanning your site.","jetpack-protect"),errorMessage:E.errorMessage,errorCode:E.errorCode}):React.createElement(l.A,{main:React.createElement(React.Fragment,null,React.createElement(r.A,{status:"active",label:__("Active","jetpack-protect")}),React.createElement(l.A.Heading,{showIcon:!0},a>0?(0,i.sprintf)(/* translators: %s: Total number of threats/vulnerabilities */ -__("%1$s %2$s found","jetpack-protect"),a,e?_n("threat","threats",a,"jetpack-protect"):_n("vulnerability","vulnerabilities",a,"jetpack-protect")):(0,i.sprintf)(/* translators: %s: Pluralized type of threat/vulnerability */ -__("No %s found","jetpack-protect"),e?__("threats","jetpack-protect"):__("vulnerabilities","jetpack-protect",0))),React.createElement(l.A.Subheading,null,React.createElement(React.Fragment,null,React.createElement(c.Ay,{ref:b},w?React.createElement(React.Fragment,null,React.createElement("span",{className:f.A["subheading-content"]},(0,s.dateI18n)("F jS g:i A",w,!1))," ",__("results","jetpack-protect")):__("Most recent results","jetpack-protect")),!e&&React.createElement(d.A,{id:"free-daily-scans",position:t?"bottom":"middle right",anchor:A}))),React.createElement("div",{className:f.A["scan-navigation"]},React.createElement(p.A,null)))})}},5285:(e,t,a)=>{"use strict";a.d(t,{A:()=>E});var n=a(3924),r=a(7425),c=a(1112),s=a(4437),i=a(5918),o=a(8509),l=a(7723),u=a(1609),d=a.n(u),p=a(3127),m=a(1226),h=a(5925),g=a(6516),v=a(6359);const __=l.__,f=()=>{const{recordEvent:e}=(0,m.A)(),{hasPlan:t,upgradePlan:a}=(0,h.Ay)(),{siteSuffix:i,blogID:o}=window.jetpackProtectInitialState||{},l=(0,u.useCallback)((()=>{e("jetpack_protect_footer_get_scan_link_click"),a()}),[e,a]);if(t){const e=(0,n.A)("jetpack-scan-dash",{site:o??i});return d().createElement("div",{className:v.A["product-section"]},d().createElement(r.hE,null,__("Get access to our Cloud","jetpack-protect")),d().createElement(r.Ay,{mb:3},__("With your Protect upgrade, you have free access to scan your site on our Cloud, so you can be aware and fix your threats even if your site goes down.","jetpack-protect")),d().createElement(c.A,{variant:"secondary",weight:"regular",href:e},__("Go to Cloud","jetpack-protect")))}return d().createElement("div",{className:v.A["product-section"]},d().createElement(r.hE,null,__("Advanced scan results","jetpack-protect")),d().createElement(r.Ay,{mb:3},__("Upgrade Jetpack Protect to get advanced scan tools, including one-click fixes for most threats and malware scanning.","jetpack-protect")),d().createElement(s.A,{description:__("Looking for advanced scan results and one-click fixes?","jetpack-protect"),cta:__("Upgrade Jetpack Protect now","jetpack-protect"),onClick:l}))},y=()=>{const{hasPlan:e}=(0,h.Ay)(),{globalStats:t}=(0,g.A)(),a=parseInt(t?.totalVulnerabilities),s=isNaN(a)?"50,000":a.toLocaleString();if(e){const e=(0,n.A)("protect-footer-learn-more-scan");return d().createElement("div",{className:v.A["info-section"]},d().createElement(r.hE,null,__("Line-by-line scanning","jetpack-protect")),d().createElement(r.Ay,{mb:2},__("We actively review line-by-line of your site files to identify threats and vulnerabilities. Jetpack monitors millions of websites to keep your site secure all the time.","jetpack-protect")," ",d().createElement(c.A,{variant:"link",target:"_blank",weight:"regular",href:e},__("Learn more","jetpack-protect"))))}const i=(0,n.A)("jetpack-protect-footer-learn-more");return d().createElement("div",{className:v.A["info-section"]},d().createElement(r.hE,null,(0,l.sprintf)( -// translators: placeholder is the number of total vulnerabilities i.e. "22,000". -__("Over %s listed vulnerabilities","jetpack-protect"),s)),d().createElement(r.Ay,{mb:3},(0,l.sprintf)( -// translators: placeholder is the number of total vulnerabilities i.e. "22,000". -__("Every day we check your plugin, theme, and WordPress versions against our %s listed vulnerabilities powered by WPScan, an Automattic brand.","jetpack-protect"),s)),d().createElement(c.A,{variant:"link",isExternalLink:!0,href:i,weight:"regular"},__("Learn more","jetpack-protect")))},E=()=>{const{waf:e}=window.jetpackProtectInitialState||{};return e.wafSupported?d().createElement(p.A,{main:d().createElement(f,null),secondary:d().createElement(y,null),preserveSecondaryOnMobile:!0}):d().createElement(i.A,{horizontalSpacing:0,horizontalGap:0,fluid:!1},d().createElement(o.A,null,d().createElement(y,null)))}},3752:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var n=a(7425),r=a(7723),c=a(7031),s=a(9671),i=a(4256),o=a(9889),l=a(2425),u=a(5925),d=a(6516),p=a(6359);const __=r.__,m=()=>{const{hasPlan:e}=(0,u.Ay)(),{globalStats:t}=(0,d.A)(),{data:a}=(0,l.Ay)({usePolling:!0}),m=parseInt(t?.totalVulnerabilities||"0"),h=isNaN(m)?"50,000":m.toLocaleString();return React.createElement(c.A,{main:React.createElement(React.Fragment,null,React.createElement(c.A.Heading,null,__("Your results will be ready soon","jetpack-protect")),React.createElement(c.A.Subheading,null,React.createElement(React.Fragment,null,e&&React.createElement(i.A,{className:p.A.progress,value:a?.currentProgress,total:100}),React.createElement(n.Ay,null,(0,r.sprintf)( -// translators: placeholder is the number of total vulnerabilities i.e. "22,000". -__("We are scanning for security threats from our more than %s listed vulnerabilities, powered by WPScan. This could take a minute or two.","jetpack-protect"),h)))),React.createElement("div",{className:p.A["scan-navigation"]},React.createElement(o.A,null))),secondary:React.createElement(s.A,null),preserveSecondaryOnMobile:!1,spacing:4})}},2970:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var n=a(2947),r=a(1608),c=a(7425),s=a(766),i=a(5918),o=a(8509),l=a(6087),u=a(7723),d=a(9374),p=a(1226),m=a(3961);const __=u.__,h=()=>((0,p.A)({pageViewEventName:"protect_interstitial"}),React.createElement(n.A,{moduleName:__("Jetpack Protect","jetpack-protect"),header:React.createElement("div",{className:m.A["protect-header"]},React.createElement(r.A,null),React.createElement(c.Ay,{variant:"body-small"},(0,l.createInterpolateElement)(__("Already have an existing plan or license key? Click here to get started","jetpack-protect"),{a:React.createElement("a",{href:"admin.php?page=my-jetpack#/add-license"})})))},React.createElement(s.A,null,React.createElement(i.A,{horizontalSpacing:3,horizontalGap:3},React.createElement(o.A,{sm:4,md:8,lg:12},React.createElement(d.A,null))))))},6201:e=>{"use strict";e.exports={consumer_slug:"jetpack-protect"}},9384:e=>{"use strict";e.exports=window.JetpackConnection},7999:e=>{"use strict";e.exports=window.JetpackScriptDataModule},1609:e=>{"use strict";e.exports=window.React},5795:e=>{"use strict";e.exports=window.ReactDOM},790:e=>{"use strict";e.exports=window.ReactJSXRuntime},6154:e=>{"use strict";e.exports=window.moment},1455:e=>{"use strict";e.exports=window.wp.apiFetch},6427:e=>{"use strict";e.exports=window.wp.components},9491:e=>{"use strict";e.exports=window.wp.compose},8443:e=>{"use strict";e.exports=window.wp.date},6087:e=>{"use strict";e.exports=window.wp.element},7723:e=>{"use strict";e.exports=window.wp.i18n},5573:e=>{"use strict";e.exports=window.wp.primitives},3832:e=>{"use strict";e.exports=window.wp.url},6072:e=>{function t(){return e.exports=t=Object.assign?Object.assign.bind():function(e){for(var t=1;t{"use strict";a.d(t,{m:()=>c});var n=a(5530),r=a(698),c=new class extends n.Q{#e;#t;#a;constructor(){super(),this.#a=e=>{if(!r.S$&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}}}onSubscribe(){this.#t||this.setEventListener(this.#a)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#a=e,this.#t?.(),this.#t=e((e=>{"boolean"==typeof e?this.setFocused(e):this.onFocus()}))}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){this.listeners.forEach((e=>{e()}))}isFocused(){return"boolean"==typeof this.#e?this.#e:"hidden"!==globalThis.document?.visibilityState}}},9101:(e,t,a)=>{"use strict";a.d(t,{PL:()=>r});var n=a(698);function r(e){return{onFetch:(t,a)=>{const r=async()=>{const a=t.options,r=t.fetchOptions?.meta?.fetchMore?.direction,i=t.state.data?.pages||[],o=t.state.data?.pageParams||[],l={pages:[],pageParams:[]};let u=!1;const d=t.options.queryFn||(()=>Promise.reject(new Error(`Missing queryFn: '${t.options.queryHash}'`))),p=async(e,a,r)=>{if(u)return Promise.reject();if(null==a&&e.pages.length)return Promise.resolve(e);const c={queryKey:t.queryKey,pageParam:a,direction:r?"backward":"forward",meta:t.options.meta};var s;s=c,Object.defineProperty(s,"signal",{enumerable:!0,get:()=>(t.signal.aborted?u=!0:t.signal.addEventListener("abort",(()=>{u=!0})),t.signal)});const i=await d(c),{maxPages:o}=t.options,l=r?n.ZZ:n.y9;return{pages:l(e.pages,i,o),pageParams:l(e.pageParams,a,o)}};let m;if(r&&i.length){const e="backward"===r,t={pages:i,pageParams:o},n=(e?s:c)(a,t);m=await p(t,n,e)}else{m=await p(l,o[0]??a.initialPageParam);const t=e??i.length;for(let e=1;et.options.persister?.(r,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},a):t.fetchFn=r}}}function c(e,{pages:t,pageParams:a}){const n=t.length-1;return e.getNextPageParam(t[n],t,a[n],a)}function s(e,{pages:t,pageParams:a}){return e.getPreviousPageParam?.(t[0],t,a[0],a)}},4352:(e,t,a)=>{"use strict";a.d(t,{$:()=>i,s:()=>s});var n=a(1795),r=a(1450),c=a(4610),s=class extends r.k{#n;#r;#c;#s;constructor(e){super(),this.mutationId=e.mutationId,this.#r=e.defaultOptions,this.#c=e.mutationCache,this.#n=[],this.state=e.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options={...this.#r,...e},this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#n.includes(e)||(this.#n.push(e),this.clearGcTimeout(),this.#c.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#n=this.#n.filter((t=>t!==e)),this.scheduleGc(),this.#c.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#n.length||("pending"===this.state.status?this.scheduleGc():this.#c.remove(this))}continue(){return this.#s?.continue()??this.execute(this.state.variables)}async execute(e){const t=()=>(this.#s=(0,c.II)({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(e,t)=>{this.#i({type:"failed",failureCount:e,error:t})},onPause:()=>{this.#i({type:"pause"})},onContinue:()=>{this.#i({type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.#s.promise),a="pending"===this.state.status;try{if(!a){this.#i({type:"pending",variables:e}),await(this.#c.config.onMutate?.(e,this));const t=await(this.options.onMutate?.(e));t!==this.state.context&&this.#i({type:"pending",context:t,variables:e})}const n=await t();return await(this.#c.config.onSuccess?.(n,e,this.state.context,this)),await(this.options.onSuccess?.(n,e,this.state.context)),await(this.#c.config.onSettled?.(n,null,this.state.variables,this.state.context,this)),await(this.options.onSettled?.(n,null,e,this.state.context)),this.#i({type:"success",data:n}),n}catch(t){try{throw await(this.#c.config.onError?.(t,e,this.state.context,this)),await(this.options.onError?.(t,e,this.state.context)),await(this.#c.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this)),await(this.options.onSettled?.(void 0,t,e,this.state.context)),t}finally{this.#i({type:"error",error:t})}}}#i(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"pending":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!(0,c.v_)(this.options.networkMode),status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}})(this.state),n.j.batch((()=>{this.#n.forEach((t=>{t.onMutationUpdate(e)})),this.#c.notify({mutation:this,type:"updated",action:e})}))}};function i(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}},7708:(e,t,a)=>{"use strict";a.d(t,{q:()=>i});var n=a(1795),r=a(4352),c=a(698),s=a(5530),i=class extends s.Q{constructor(e={}){super(),this.config=e,this.#o=[],this.#l=0}#o;#l;#u;build(e,t,a){const n=new r.s({mutationCache:this,mutationId:++this.#l,options:e.defaultMutationOptions(t),state:a});return this.add(n),n}add(e){this.#o.push(e),this.notify({type:"added",mutation:e})}remove(e){this.#o=this.#o.filter((t=>t!==e)),this.notify({type:"removed",mutation:e})}clear(){n.j.batch((()=>{this.#o.forEach((e=>{this.remove(e)}))}))}getAll(){return this.#o}find(e){const t={exact:!0,...e};return this.#o.find((e=>(0,c.nJ)(t,e)))}findAll(e={}){return this.#o.filter((t=>(0,c.nJ)(e,t)))}notify(e){n.j.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}resumePausedMutations(){return this.#u=(this.#u??Promise.resolve()).then((()=>{const e=this.#o.filter((e=>e.state.isPaused));return n.j.batch((()=>e.reduce(((e,t)=>e.then((()=>t.continue().catch(c.lQ)))),Promise.resolve())))})).then((()=>{this.#u=void 0})),this.#u}}},4158:(e,t,a)=>{"use strict";a.d(t,{_:()=>i});var n=a(4352),r=a(1795),c=a(5530),s=a(698),i=class extends c.Q{#d;#p=void 0;#m;#h;constructor(e,t){super(),this.#d=e,this.setOptions(t),this.bindMethods(),this.#g()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){const t=this.options;this.options=this.#d.defaultMutationOptions(e),(0,s.f8)(t,this.options)||this.#d.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#m,observer:this}),t?.mutationKey&&this.options.mutationKey&&(0,s.EN)(t.mutationKey)!==(0,s.EN)(this.options.mutationKey)?this.reset():this.#m?.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#m?.removeObserver(this)}onMutationUpdate(e){this.#g(),this.#v(e)}getCurrentResult(){return this.#p}reset(){this.#m?.removeObserver(this),this.#m=void 0,this.#g(),this.#v()}mutate(e,t){return this.#h=t,this.#m?.removeObserver(this),this.#m=this.#d.getMutationCache().build(this.#d,this.options),this.#m.addObserver(this),this.#m.execute(e)}#g(){const e=this.#m?.state??(0,n.$)();this.#p={...e,isPending:"pending"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset}}#v(e){r.j.batch((()=>{if(this.#h&&this.hasListeners()){const t=this.#p.variables,a=this.#p.context;"success"===e?.type?(this.#h.onSuccess?.(e.data,t,a),this.#h.onSettled?.(e.data,null,t,a)):"error"===e?.type&&(this.#h.onError?.(e.error,t,a),this.#h.onSettled?.(void 0,e.error,t,a))}this.listeners.forEach((e=>{e(this.#p)}))}))}}},1795:(e,t,a)=>{"use strict";a.d(t,{j:()=>n});var n=function(){let e=[],t=0,a=e=>{e()},n=e=>{e()},r=e=>setTimeout(e,0);const c=n=>{t?e.push(n):r((()=>{a(n)}))},s=()=>{const t=e;e=[],t.length&&r((()=>{n((()=>{t.forEach((e=>{a(e)}))}))}))};return{batch:e=>{let a;t++;try{a=e()}finally{t--,t||s()}return a},batchCalls:e=>(...t)=>{c((()=>{e(...t)}))},schedule:c,setNotifyFunction:e=>{a=e},setBatchNotifyFunction:e=>{n=e},setScheduler:e=>{r=e}}}()},5873:(e,t,a)=>{"use strict";a.d(t,{t:()=>c});var n=a(5530),r=a(698),c=new class extends n.Q{#f=!0;#t;#a;constructor(){super(),this.#a=e=>{if(!r.S$&&window.addEventListener){const t=()=>e(!0),a=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",a,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",a)}}}}onSubscribe(){this.#t||this.setEventListener(this.#a)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#a=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#f!==e&&(this.#f=e,this.listeners.forEach((t=>{t(e)})))}isOnline(){return this.#f}}},4135:(e,t,a)=>{"use strict";a.d(t,{X:()=>i});var n=a(698),r=a(1795),c=a(4610),s=a(1450),i=class extends s.k{#y;#E;#A;#b;#s;#n;#r;#w;constructor(e){super(),this.#w=!1,this.#r=e.defaultOptions,this.#k(e.options),this.#n=[],this.#A=e.cache,this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#y=e.state||function(e){const t="function"==typeof e.initialData?e.initialData():e.initialData,a=void 0!==t,n=a?"function"==typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:a?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:a?"success":"pending",fetchStatus:"idle"}}(this.options),this.state=this.#y,this.scheduleGc()}get meta(){return this.options.meta}#k(e){this.options={...this.#r,...e},this.updateGcTime(this.options.gcTime)}optionalRemove(){this.#n.length||"idle"!==this.state.fetchStatus||this.#A.remove(this)}setData(e,t){const a=(0,n.pl)(this.state.data,e,this.options);return this.#i({data:a,type:"success",dataUpdatedAt:t?.updatedAt,manual:t?.manual}),a}setState(e,t){this.#i({type:"setState",state:e,setStateOptions:t})}cancel(e){const t=this.#b;return this.#s?.cancel(e),t?t.then(n.lQ).catch(n.lQ):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#y)}isActive(){return this.#n.some((e=>!1!==e.options.enabled))}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.#n.some((e=>e.getCurrentResult().isStale))}isStaleByTime(e=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!(0,n.j3)(this.state.dataUpdatedAt,e)}onFocus(){const e=this.#n.find((e=>e.shouldFetchOnWindowFocus()));e?.refetch({cancelRefetch:!1}),this.#s?.continue()}onOnline(){const e=this.#n.find((e=>e.shouldFetchOnReconnect()));e?.refetch({cancelRefetch:!1}),this.#s?.continue()}addObserver(e){this.#n.includes(e)||(this.#n.push(e),this.clearGcTimeout(),this.#A.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.#n.includes(e)&&(this.#n=this.#n.filter((t=>t!==e)),this.#n.length||(this.#s&&(this.#w?this.#s.cancel({revert:!0}):this.#s.cancelRetry()),this.scheduleGc()),this.#A.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.#n.length}invalidate(){this.state.isInvalidated||this.#i({type:"invalidate"})}fetch(e,t){if("idle"!==this.state.fetchStatus)if(this.state.dataUpdatedAt&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#b)return this.#s?.continueRetry(),this.#b;if(e&&this.#k(e),!this.options.queryFn){const e=this.#n.find((e=>e.options.queryFn));e&&this.#k(e.options)}const a=new AbortController,n={queryKey:this.queryKey,meta:this.meta},r=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(this.#w=!0,a.signal)})};r(n);const s={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>this.options.queryFn?(this.#w=!1,this.options.persister?this.options.persister(this.options.queryFn,n,this):this.options.queryFn(n)):Promise.reject(new Error(`Missing queryFn: '${this.options.queryHash}'`))};r(s),this.options.behavior?.onFetch(s,this),this.#E=this.state,"idle"!==this.state.fetchStatus&&this.state.fetchMeta===s.fetchOptions?.meta||this.#i({type:"fetch",meta:s.fetchOptions?.meta});const i=e=>{(0,c.wm)(e)&&e.silent||this.#i({type:"error",error:e}),(0,c.wm)(e)||(this.#A.config.onError?.(e,this),this.#A.config.onSettled?.(this.state.data,e,this)),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.#s=(0,c.II)({fn:s.fetchFn,abort:a.abort.bind(a),onSuccess:e=>{void 0!==e?(this.setData(e),this.#A.config.onSuccess?.(e,this),this.#A.config.onSettled?.(e,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1):i(new Error(`${this.queryHash} data is undefined`))},onError:i,onFail:(e,t)=>{this.#i({type:"failed",failureCount:e,error:t})},onPause:()=>{this.#i({type:"pause"})},onContinue:()=>{this.#i({type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode}),this.#b=this.#s.promise,this.#b}#i(e){this.state=(t=>{switch(e.type){case"failed":return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...t,fetchStatus:"paused"};case"continue":return{...t,fetchStatus:"fetching"};case"fetch":return{...t,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:e.meta??null,fetchStatus:(0,c.v_)(this.options.networkMode)?"fetching":"paused",...!t.dataUpdatedAt&&{error:null,status:"pending"}};case"success":return{...t,data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:e.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const a=e.error;return(0,c.wm)(a)&&a.revert&&this.#E?{...this.#E,fetchStatus:"idle"}:{...t,error:a,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error"};case"invalidate":return{...t,isInvalidated:!0};case"setState":return{...t,...e.state}}})(this.state),r.j.batch((()=>{this.#n.forEach((e=>{e.onQueryUpdate()})),this.#A.notify({query:this,type:"updated",action:e})}))}}},3205:(e,t,a)=>{"use strict";a.d(t,{$:()=>i});var n=a(698),r=a(4135),c=a(1795),s=a(5530),i=class extends s.Q{constructor(e={}){super(),this.config=e,this.#R=new Map}#R;build(e,t,a){const c=t.queryKey,s=t.queryHash??(0,n.F$)(c,t);let i=this.get(s);return i||(i=new r.X({cache:this,queryKey:c,queryHash:s,options:e.defaultQueryOptions(t),state:a,defaultOptions:e.getQueryDefaults(c)}),this.add(i)),i}add(e){this.#R.has(e.queryHash)||(this.#R.set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=this.#R.get(e.queryHash);t&&(e.destroy(),t===e&&this.#R.delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){c.j.batch((()=>{this.getAll().forEach((e=>{this.remove(e)}))}))}get(e){return this.#R.get(e)}getAll(){return[...this.#R.values()]}find(e){const t={exact:!0,...e};return this.getAll().find((e=>(0,n.MK)(t,e)))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter((t=>(0,n.MK)(e,t))):t}notify(e){c.j.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}onFocus(){c.j.batch((()=>{this.getAll().forEach((e=>{e.onFocus()}))}))}onOnline(){c.j.batch((()=>{this.getAll().forEach((e=>{e.onOnline()}))}))}}},116:(e,t,a)=>{"use strict";a.d(t,{E:()=>u});var n=a(698),r=a(3205),c=a(7708),s=a(2464),i=a(5873),o=a(1795),l=a(9101),u=class{#C;#c;#r;#_;#j;#x;#S;#M;constructor(e={}){this.#C=e.queryCache||new r.$,this.#c=e.mutationCache||new c.q,this.#r=e.defaultOptions||{},this.#_=new Map,this.#j=new Map,this.#x=0}mount(){this.#x++,1===this.#x&&(this.#S=s.m.subscribe((()=>{s.m.isFocused()&&(this.resumePausedMutations(),this.#C.onFocus())})),this.#M=i.t.subscribe((()=>{i.t.isOnline()&&(this.resumePausedMutations(),this.#C.onOnline())})))}unmount(){this.#x--,0===this.#x&&(this.#S?.(),this.#S=void 0,this.#M?.(),this.#M=void 0)}isFetching(e){return this.#C.findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return this.#c.findAll({...e,status:"pending"}).length}getQueryData(e){return this.#C.find({queryKey:e})?.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);return void 0!==t?Promise.resolve(t):this.fetchQuery(e)}getQueriesData(e){return this.getQueryCache().findAll(e).map((({queryKey:e,state:t})=>[e,t.data]))}setQueryData(e,t,a){const r=this.#C.find({queryKey:e}),c=r?.state.data,s=(0,n.Zw)(t,c);if(void 0===s)return;const i=this.defaultQueryOptions({queryKey:e});return this.#C.build(this,i).setData(s,{...a,manual:!0})}setQueriesData(e,t,a){return o.j.batch((()=>this.getQueryCache().findAll(e).map((({queryKey:e})=>[e,this.setQueryData(e,t,a)]))))}getQueryState(e){return this.#C.find({queryKey:e})?.state}removeQueries(e){const t=this.#C;o.j.batch((()=>{t.findAll(e).forEach((e=>{t.remove(e)}))}))}resetQueries(e,t){const a=this.#C,n={type:"active",...e};return o.j.batch((()=>(a.findAll(e).forEach((e=>{e.reset()})),this.refetchQueries(n,t))))}cancelQueries(e={},t={}){const a={revert:!0,...t},r=o.j.batch((()=>this.#C.findAll(e).map((e=>e.cancel(a)))));return Promise.all(r).then(n.lQ).catch(n.lQ)}invalidateQueries(e={},t={}){return o.j.batch((()=>{if(this.#C.findAll(e).forEach((e=>{e.invalidate()})),"none"===e.refetchType)return Promise.resolve();const a={...e,type:e.refetchType??e.type??"active"};return this.refetchQueries(a,t)}))}refetchQueries(e={},t){const a={...t,cancelRefetch:t?.cancelRefetch??!0},r=o.j.batch((()=>this.#C.findAll(e).filter((e=>!e.isDisabled())).map((e=>{let t=e.fetch(void 0,a);return a.throwOnError||(t=t.catch(n.lQ)),"paused"===e.state.fetchStatus?Promise.resolve():t}))));return Promise.all(r).then(n.lQ)}fetchQuery(e){const t=this.defaultQueryOptions(e);void 0===t.retry&&(t.retry=!1);const a=this.#C.build(this,t);return a.isStaleByTime(t.staleTime)?a.fetch(t):Promise.resolve(a.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(n.lQ).catch(n.lQ)}fetchInfiniteQuery(e){return e.behavior=(0,l.PL)(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(n.lQ).catch(n.lQ)}resumePausedMutations(){return this.#c.resumePausedMutations()}getQueryCache(){return this.#C}getMutationCache(){return this.#c}getDefaultOptions(){return this.#r}setDefaultOptions(e){this.#r=e}setQueryDefaults(e,t){this.#_.set((0,n.EN)(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...this.#_.values()];let a={};return t.forEach((t=>{(0,n.Cp)(e,t.queryKey)&&(a={...a,...t.defaultOptions})})),a}setMutationDefaults(e,t){this.#j.set((0,n.EN)(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...this.#j.values()];let a={};return t.forEach((t=>{(0,n.Cp)(e,t.mutationKey)&&(a={...a,...t.defaultOptions})})),a}defaultQueryOptions(e){if(e?._defaulted)return e;const t={...this.#r.queries,...e?.queryKey&&this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=(0,n.F$)(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.throwOnError&&(t.throwOnError=!!t.suspense),void 0===t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#r.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#C.clear(),this.#c.clear()}}},3397:(e,t,a)=>{"use strict";a.d(t,{$:()=>o});var n=a(698),r=a(1795),c=a(2464),s=a(5530),i=a(4610),o=class extends s.Q{constructor(e,t){super(),this.options=t,this.#d=e,this.#N=null,this.bindMethods(),this.setOptions(t)}#d;#L=void 0;#P=void 0;#p=void 0;#z;#O;#N;#I;#F;#V;#D;#H;#T;#B=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(this.#L.addObserver(this),l(this.#L,this.options)?this.#q():this.updateResult(),this.#U())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return u(this.#L,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return u(this.#L,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#$(),this.#Q(),this.#L.removeObserver(this)}setOptions(e,t){const a=this.options,r=this.#L;if(this.options=this.#d.defaultQueryOptions(e),(0,n.f8)(a,this.options)||this.#d.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#L,observer:this}),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled)throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=a.queryKey),this.#J();const c=this.hasListeners();c&&d(this.#L,r,this.options,a)&&this.#q(),this.updateResult(t),!c||this.#L===r&&this.options.enabled===a.enabled&&this.options.staleTime===a.staleTime||this.#W();const s=this.#Z();!c||this.#L===r&&this.options.enabled===a.enabled&&s===this.#T||this.#G(s)}getOptimisticResult(e){const t=this.#d.getQueryCache().build(this.#d,e),a=this.createResult(t,e);return function(e,t){if(!(0,n.f8)(e.getCurrentResult(),t))return!0;return!1}(this,a)&&(this.#p=a,this.#O=this.options,this.#z=this.#L.state),a}getCurrentResult(){return this.#p}trackResult(e){const t={};return Object.keys(e).forEach((a=>{Object.defineProperty(t,a,{configurable:!1,enumerable:!0,get:()=>(this.#B.add(a),e[a])})})),t}getCurrentQuery(){return this.#L}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=this.#d.defaultQueryOptions(e),a=this.#d.getQueryCache().build(this.#d,t);return a.isFetchingOptimistic=!0,a.fetch().then((()=>this.createResult(a,t)))}fetch(e){return this.#q({...e,cancelRefetch:e.cancelRefetch??!0}).then((()=>(this.updateResult(),this.#p)))}#q(e){this.#J();let t=this.#L.fetch(this.options,e);return e?.throwOnError||(t=t.catch(n.lQ)),t}#W(){if(this.#$(),n.S$||this.#p.isStale||!(0,n.gn)(this.options.staleTime))return;const e=(0,n.j3)(this.#p.dataUpdatedAt,this.options.staleTime)+1;this.#D=setTimeout((()=>{this.#p.isStale||this.updateResult()}),e)}#Z(){return("function"==typeof this.options.refetchInterval?this.options.refetchInterval(this.#L):this.options.refetchInterval)??!1}#G(e){this.#Q(),this.#T=e,!n.S$&&!1!==this.options.enabled&&(0,n.gn)(this.#T)&&0!==this.#T&&(this.#H=setInterval((()=>{(this.options.refetchIntervalInBackground||c.m.isFocused())&&this.#q()}),this.#T))}#U(){this.#W(),this.#G(this.#Z())}#$(){this.#D&&(clearTimeout(this.#D),this.#D=void 0)}#Q(){this.#H&&(clearInterval(this.#H),this.#H=void 0)}createResult(e,t){const a=this.#L,r=this.options,c=this.#p,s=this.#z,o=this.#O,u=e!==a?e.state:this.#P,{state:m}=e;let h,{error:g,errorUpdatedAt:v,fetchStatus:f,status:y}=m,E=!1;if(t._optimisticResults){const n=this.hasListeners(),c=!n&&l(e,t),s=n&&d(e,a,t,r);(c||s)&&(f=(0,i.v_)(e.options.networkMode)?"fetching":"paused",m.dataUpdatedAt||(y="pending")),"isRestoring"===t._optimisticResults&&(f="idle")}if(t.select&&void 0!==m.data)if(c&&m.data===s?.data&&t.select===this.#I)h=this.#F;else try{this.#I=t.select,h=t.select(m.data),h=(0,n.pl)(c?.data,h,t),this.#F=h,this.#N=null}catch(e){this.#N=e}else h=m.data;if(void 0!==t.placeholderData&&void 0===h&&"pending"===y){let e;if(c?.isPlaceholderData&&t.placeholderData===o?.placeholderData)e=c.data;else if(e="function"==typeof t.placeholderData?t.placeholderData(this.#V?.state.data,this.#V):t.placeholderData,t.select&&void 0!==e)try{e=t.select(e),this.#N=null}catch(e){this.#N=e}void 0!==e&&(y="success",h=(0,n.pl)(c?.data,e,t),E=!0)}this.#N&&(g=this.#N,h=this.#F,v=Date.now(),y="error");const A="fetching"===f,b="pending"===y,w="error"===y,k=b&&A;return{status:y,fetchStatus:f,isPending:b,isSuccess:"success"===y,isError:w,isInitialLoading:k,isLoading:k,data:h,dataUpdatedAt:m.dataUpdatedAt,error:g,errorUpdatedAt:v,failureCount:m.fetchFailureCount,failureReason:m.fetchFailureReason,errorUpdateCount:m.errorUpdateCount,isFetched:m.dataUpdateCount>0||m.errorUpdateCount>0,isFetchedAfterMount:m.dataUpdateCount>u.dataUpdateCount||m.errorUpdateCount>u.errorUpdateCount,isFetching:A,isRefetching:A&&!b,isLoadingError:w&&0===m.dataUpdatedAt,isPaused:"paused"===f,isPlaceholderData:E,isRefetchError:w&&0!==m.dataUpdatedAt,isStale:p(e,t),refetch:this.refetch}}updateResult(e){const t=this.#p,a=this.createResult(this.#L,this.options);if(this.#z=this.#L.state,this.#O=this.options,void 0!==this.#z.data&&(this.#V=this.#L),(0,n.f8)(a,t))return;this.#p=a;const r={};!1!==e?.listeners&&(()=>{if(!t)return!0;const{notifyOnChangeProps:e}=this.options,a="function"==typeof e?e():e;if("all"===a||!a&&!this.#B.size)return!0;const n=new Set(a??this.#B);return this.options.throwOnError&&n.add("error"),Object.keys(this.#p).some((e=>{const a=e;return this.#p[a]!==t[a]&&n.has(a)}))})()&&(r.listeners=!0),this.#v({...r,...e})}#J(){const e=this.#d.getQueryCache().build(this.#d,this.options);if(e===this.#L)return;const t=this.#L;this.#L=e,this.#P=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#U()}#v(e){r.j.batch((()=>{e.listeners&&this.listeners.forEach((e=>{e(this.#p)})),this.#d.getQueryCache().notify({query:this.#L,type:"observerResultsUpdated"})}))}};function l(e,t){return function(e,t){return!(!1===t.enabled||e.state.dataUpdatedAt||"error"===e.state.status&&!1===t.retryOnMount)}(e,t)||e.state.dataUpdatedAt>0&&u(e,t,t.refetchOnMount)}function u(e,t,a){if(!1!==t.enabled){const n="function"==typeof a?a(e):a;return"always"===n||!1!==n&&p(e,t)}return!1}function d(e,t,a,n){return!1!==a.enabled&&(e!==t||!1===n.enabled)&&(!a.suspense||"error"!==e.state.status)&&p(e,a)}function p(e,t){return e.isStaleByTime(t.staleTime)}},1450:(e,t,a)=>{"use strict";a.d(t,{k:()=>r});var n=a(698),r=class{#K;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),(0,n.gn)(this.gcTime)&&(this.#K=setTimeout((()=>{this.optionalRemove()}),this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(n.S$?1/0:3e5))}clearGcTimeout(){this.#K&&(clearTimeout(this.#K),this.#K=void 0)}}},4610:(e,t,a)=>{"use strict";a.d(t,{II:()=>u,v_:()=>i,wm:()=>l});var n=a(2464),r=a(5873),c=a(698);function s(e){return Math.min(1e3*2**e,3e4)}function i(e){return"online"!==(e??"online")||r.t.isOnline()}var o=class{constructor(e){this.revert=e?.revert,this.silent=e?.silent}};function l(e){return e instanceof o}function u(e){let t,a,l,u=!1,d=0,p=!1;const m=new Promise(((e,t)=>{a=e,l=t})),h=()=>!n.m.isFocused()||"always"!==e.networkMode&&!r.t.isOnline(),g=n=>{p||(p=!0,e.onSuccess?.(n),t?.(),a(n))},v=a=>{p||(p=!0,e.onError?.(a),t?.(),l(a))},f=()=>new Promise((a=>{t=e=>{const t=p||!h();return t&&a(e),t},e.onPause?.()})).then((()=>{t=void 0,p||e.onContinue?.()})),y=()=>{if(p)return;let t;try{t=e.fn()}catch(e){t=Promise.reject(e)}Promise.resolve(t).then(g).catch((t=>{if(p)return;const a=e.retry??(c.S$?0:3),n=e.retryDelay??s,r="function"==typeof n?n(d,t):n,i=!0===a||"number"==typeof a&&d{if(h())return f()})).then((()=>{u?v(t):y()}))):v(t)}))};return i(e.networkMode)?y():f().then(y),{promise:m,cancel:t=>{p||(v(new o(t)),e.abort?.())},continue:()=>{const e=t?.();return e?m:Promise.resolve()},cancelRetry:()=>{u=!0},continueRetry:()=>{u=!1}}}},5530:(e,t,a)=>{"use strict";a.d(t,{Q:()=>n});var n=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}}},698:(e,t,a)=>{"use strict";a.d(t,{Cp:()=>p,EN:()=>d,F$:()=>u,MK:()=>o,S$:()=>n,ZZ:()=>b,Zw:()=>c,f8:()=>h,gn:()=>s,j3:()=>i,lQ:()=>r,nJ:()=>l,pl:()=>E,y9:()=>A,yy:()=>y});var n="undefined"==typeof window||"Deno"in window;function r(){}function c(e,t){return"function"==typeof e?e(t):e}function s(e){return"number"==typeof e&&e>=0&&e!==1/0}function i(e,t){return Math.max(e+(t||0)-Date.now(),0)}function o(e,t){const{type:a="all",exact:n,fetchStatus:r,predicate:c,queryKey:s,stale:i}=e;if(s)if(n){if(t.queryHash!==u(s,t.options))return!1}else if(!p(t.queryKey,s))return!1;if("all"!==a){const e=t.isActive();if("active"===a&&!e)return!1;if("inactive"===a&&e)return!1}return("boolean"!=typeof i||t.isStale()===i)&&((void 0===r||r===t.state.fetchStatus)&&!(c&&!c(t)))}function l(e,t){const{exact:a,status:n,predicate:r,mutationKey:c}=e;if(c){if(!t.options.mutationKey)return!1;if(a){if(d(t.options.mutationKey)!==d(c))return!1}else if(!p(t.options.mutationKey,c))return!1}return(!n||t.state.status===n)&&!(r&&!r(t))}function u(e,t){return(t?.queryKeyHashFn||d)(e)}function d(e){return JSON.stringify(e,((e,t)=>v(t)?Object.keys(t).sort().reduce(((e,a)=>(e[a]=t[a],e)),{}):t))}function p(e,t){return e===t||typeof e==typeof t&&(!(!e||!t||"object"!=typeof e||"object"!=typeof t)&&!Object.keys(t).some((a=>!p(e[a],t[a]))))}function m(e,t){if(e===t)return e;const a=g(e)&&g(t);if(a||v(e)&&v(t)){const n=a?e:Object.keys(e),r=n.length,c=a?t:Object.keys(t),s=c.length,i=a?[]:{};let o=0;for(let r=0;r{setTimeout(t,e)}))}function E(e,t,a){return"function"==typeof a.structuralSharing?a.structuralSharing(e,t):!1!==a.structuralSharing?m(e,t):t}function A(e,t,a=0){const n=[...e,t];return a&&n.length>a?n.slice(1):n}function b(e,t,a=0){const n=[t,...e];return a&&n.length>a?n.slice(0,-1):n}},1462:(e,t,a)=>{"use strict";a.d(t,{E:()=>n});var n=function(){return null}},7115:(e,t,a)=>{"use strict";a.d(t,{Ht:()=>i,jE:()=>s});var n=a(1609),r=a(790),c=n.createContext(void 0),s=e=>{const t=n.useContext(c);if(e)return e;if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},i=({client:e,children:t})=>(n.useEffect((()=>(e.mount(),()=>{e.unmount()})),[e]),(0,r.jsx)(c.Provider,{value:e,children:t}))},9690:(e,t,a)=>{"use strict";a.d(t,{h:()=>s});var n=a(1609);a(790);function r(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var c=n.createContext(r()),s=()=>n.useContext(c)},4804:(e,t,a)=>{"use strict";a.d(t,{$1:()=>i,LJ:()=>c,wZ:()=>s});var n=a(1609),r=a(5492),c=(e,t)=>{(e.suspense||e.throwOnError)&&(t.isReset()||(e.retryOnMount=!1))},s=e=>{n.useEffect((()=>{e.clearReset()}),[e])},i=({result:e,errorResetBoundary:t,throwOnError:a,query:n})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(0,r.G)(a,[e.error,n])},4796:(e,t,a)=>{"use strict";a.d(t,{w:()=>c});var n=a(1609),r=n.createContext(!1),c=()=>n.useContext(r);r.Provider},937:(e,t,a)=>{"use strict";a.d(t,{EU:()=>r,iL:()=>c,tu:()=>n});var n=e=>{e.suspense&&"number"!=typeof e.staleTime&&(e.staleTime=1e3)},r=(e,t)=>e?.suspense&&t.isPending,c=(e,t,a)=>t.fetchOptimistic(e).catch((()=>{a.clearReset()}))},4611:(e,t,a)=>{"use strict";a.d(t,{t:()=>u});var n=a(1609),r=a(1795),c=a(9690),s=a(7115),i=a(4796),o=a(4804),l=a(937);function u(e,t,a){const u=(0,s.jE)(a),d=(0,i.w)(),p=(0,c.h)(),m=u.defaultQueryOptions(e);m._optimisticResults=d?"isRestoring":"optimistic",(0,l.tu)(m),(0,o.LJ)(m,p),(0,o.wZ)(p);const[h]=n.useState((()=>new t(u,m))),g=h.getOptimisticResult(m);if(n.useSyncExternalStore(n.useCallback((e=>{const t=d?()=>{}:h.subscribe(r.j.batchCalls(e));return h.updateResult(),t}),[h,d]),(()=>h.getCurrentResult()),(()=>h.getCurrentResult())),n.useEffect((()=>{h.setOptions(m,{listeners:!1})}),[m,h]),(0,l.EU)(m,g))throw(0,l.iL)(m,h,p);if((0,o.$1)({result:g,errorResetBoundary:p,throwOnError:m.throwOnError,query:u.getQueryCache().get(m.queryHash)}))throw g.error;return m.notifyOnChangeProps?g:h.trackResult(g)}},4613:(e,t,a)=>{"use strict";a.d(t,{n:()=>o});var n=a(1609),r=a(4158),c=a(1795),s=a(7115),i=a(5492);function o(e,t){const a=(0,s.jE)(t),[o]=n.useState((()=>new r._(a,e)));n.useEffect((()=>{o.setOptions(e)}),[o,e]);const u=n.useSyncExternalStore(n.useCallback((e=>o.subscribe(c.j.batchCalls(e))),[o]),(()=>o.getCurrentResult()),(()=>o.getCurrentResult())),d=n.useCallback(((e,t)=>{o.mutate(e,t).catch(l)}),[o]);if(u.error&&(0,i.G)(o.options.throwOnError,[u.error]))throw u.error;return{...u,mutate:d,mutateAsync:u.mutate}}function l(){}},5104:(e,t,a)=>{"use strict";a.d(t,{I:()=>c});var n=a(3397),r=a(4611);function c(e,t){return(0,r.t)(e,n.$,t)}},5492:(e,t,a)=>{"use strict";function n(e,t){return"function"==typeof e?e(...t):!!e}a.d(t,{G:()=>n})},3022:(e,t,a)=>{"use strict";function n(e){var t,a,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var c=e.length;for(t=0;tr});const r=function(){for(var e,t,a=0,r="",c=arguments.length;a{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t},a.d=(e,t)=>{for(var n in t)a.o(t,n)&&!a.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e=a(723),t=a(116),n=a(7115),r=a(1462),c=a(6087),s=a(1609),i=a.n(s),o=a(9539),l=a(28),u=a(4440),d=a(5409),p=a(1009),m=a(4537),h=a(1936),g=a(5925),v=a(1671),f=a(5148),y=a(5717),E=a(2970);a(5490);const A=new t.E({defaultOptions:{queries:{staleTime:1/0}}});function b(){const e=(0,o.zy)();return(0,s.useEffect)((()=>window.scrollTo(0,0)),[e]),null}!function(){const t=document.getElementById("jetpack-protect-root");if(null===t)return;const a=i().createElement(n.Ht,{client:A},i().createElement(e.Ay,null,i().createElement(m.m,null,i().createElement(p.Z,null,i().createElement(g.sT,null,i().createElement(h.Ll,null,i().createElement(l.I9,null,i().createElement(b,null),i().createElement(o.BV,null,i().createElement(o.qh,{path:"/setup",element:i().createElement(E.A,null)}),i().createElement(o.qh,{path:"/scan",element:i().createElement(f.A,null)}),i().createElement(o.qh,{path:"/scan/history",element:i().createElement(d.A,null,i().createElement(y.A,null))}),i().createElement(o.qh,{path:"/scan/history/:filter",element:i().createElement(d.A,null,i().createElement(y.A,null))}),i().createElement(o.qh,{path:"/firewall",element:i().createElement(v.A,null)}),i().createElement(o.qh,{path:"*",element:i().createElement(o.C5,{to:"/scan",replace:!0})}))),i().createElement(u.A,null)))))),i().createElement(r.E,{initialIsOpen:!1}));c.createRoot(t).render(a)}()})()})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js.LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js.LICENSE.txt deleted file mode 100644 index 08d80297..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.js.LICENSE.txt +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Exposes number format capability - * - * @copyright Copyright (c) 2013 Kevin van Zonneveld (http://kvz.io) and Contributors (http://phpjs.org/authors). - * @license See CREDITS.md - * @see https://github.com/kvz/phpjs/blob/ffe1356af23a6f2512c84c954dd4e828e92579fa/functions/strings/number_format.js - */ - -/** - * @remix-run/router v1.21.0 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */ - -/** - * React Router DOM v6.28.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */ - -/** - * React Router v6.28.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.rtl.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.rtl.css deleted file mode 100644 index 51f747c5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/build/index.rtl.css +++ /dev/null @@ -1 +0,0 @@ -._aiMxmJRAw5jRPbZFX57{background-color:var(--jp-gray-90);border-radius:var(--jp-border-radius);color:var(--jp-white);display:flex;overflow:hidden;z-index:1}._aiMxmJRAw5jRPbZFX57.eWgNBUaexiR66ZI1Px4U{border-right:4px solid var(--jp-yellow-20);margin-bottom:calc(var(--spacing-base)*3)}._aiMxmJRAw5jRPbZFX57.ZGELG1CO333FilJXOaeI{left:calc(var(--spacing-base)*3);margin-right:calc(var(--spacing-base)*3);position:fixed;top:calc(var(--spacing-base)*6)}@media(max-width:782px){._aiMxmJRAw5jRPbZFX57.ZGELG1CO333FilJXOaeI{top:calc(var(--spacing-base)*8)}}._aiMxmJRAw5jRPbZFX57 a,._aiMxmJRAw5jRPbZFX57 a:active,._aiMxmJRAw5jRPbZFX57 a:hover,._aiMxmJRAw5jRPbZFX57 a:link,._aiMxmJRAw5jRPbZFX57 a:visited{color:var(--jp-white)}.BnI88X_e8ItF1c9Uozmj{background-color:var(--jp-yellow-30);fill:var(--jp-white);align-items:center;display:flex;justify-content:center;padding:calc(var(--spacing-base)*1.5)}.hRRUwTCPRpurhMwRNZkg .BnI88X_e8ItF1c9Uozmj{background-color:var(--jp-green-50)}.Z6q3IxY_uR1y2lAPTkVF .BnI88X_e8ItF1c9Uozmj{background-color:var(--jp-red)}.eWgNBUaexiR66ZI1Px4U .BnI88X_e8ItF1c9Uozmj{fill:var(--jp-yellow-50);background-color:var(--jp-yellow-5)}.ST8sowTbBVLRPrk4ZQrn{font-size:14px;padding:calc(var(--spacing-base)*1.75)}.eWgNBUaexiR66ZI1Px4U .ST8sowTbBVLRPrk4ZQrn{background-color:var(--jp-yellow-5);color:var(--jp-gray-90)}.lMkO08Vd8YQMfwrwaI8u{fill:var(--jp-gray);align-items:center;background:#0000;border:none;cursor:pointer;display:flex;justify-content:center;padding:calc(var(--spacing-base)*1.5)}._Wc3apZobag_9Ag_THTb{display:flex;justify-content:space-between}.WQVtrU6q0L1Igcj7wCrQ{margin:0;padding:0}.UujoBFTnQNY2cWU2SIsH{font-size:var(--font-headline-medium);font-weight:700;line-height:52px}.TeGO5V_thHw5lDAm1_2M{font-weight:700}.TeGO5V_thHw5lDAm1_2M,.WolQzb2MsSgiNmLtc7_j{font-size:var(--font-headline-small);line-height:40px}.WolQzb2MsSgiNmLtc7_j{font-weight:400}.hUB0JT8p1T2Hw28N6qC8{font-weight:500}.gKZWDv5chz3_O3Syp74H,.hUB0JT8p1T2Hw28N6qC8{font-size:var(--font-title-medium);line-height:32px}.gKZWDv5chz3_O3Syp74H{font-weight:600}.zY2No8Ga4b8shbOQGhnv{font-size:var(--font-title-small);font-weight:500;line-height:30px}.tIj0D1t8Cc892ikmgFPZ{font-size:var(--font-body);font-weight:400;line-height:24px}.KdcN0BnOaVeVhyLRKqhS{font-size:var(--font-body-small);font-weight:400;line-height:24px}.dso3Rh3tl3Xv1GumBktz{font-weight:400}.dso3Rh3tl3Xv1GumBktz,.mQ1UlbN9u4Mg9byO8m7v{font-size:var(--font-body-extra-small);line-height:20px}.mQ1UlbN9u4Mg9byO8m7v{font-weight:700}.PItlW5vRExLnTj4a8eLE{font-size:var(--font-body-extra-small);font-weight:600;line-height:16px}.TwRpPlktzxhmFVeua7P5{margin:calc(var( --spacing-base )*0)}.zVfqx7gyb3o9mxfGynn1{margin-left:calc(var( --spacing-base )*0);margin-right:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy{margin-bottom:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy,.xqDIp6cNVr_E6RXaiPyD{margin-top:calc(var( --spacing-base )*0)}.S8EwaXk1kyPizt6x4WH2{margin-left:calc(var( --spacing-base )*0)}.ODX5Vr1TARoLFkDDFooD{margin-bottom:calc(var( --spacing-base )*0)}.cphJ8dCpfimnky7P2FHg{margin-right:calc(var( --spacing-base )*0)}.PFgIhNxIyiSuNvQjAIYj{margin:calc(var( --spacing-base )*1)}.M2jKmUzDxvJjjVEPU3zn{margin-left:calc(var( --spacing-base )*1);margin-right:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk{margin-bottom:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk,.rcTN5uw9xIEeMEGL3Xi_{margin-top:calc(var( --spacing-base )*1)}.CQSkybjq2TcRM1Xo9COV{margin-left:calc(var( --spacing-base )*1)}.hfqOWgq6_MEGdFE82eOY{margin-bottom:calc(var( --spacing-base )*1)}.I8MxZQYTbuu595yfesWA{margin-right:calc(var( --spacing-base )*1)}.kQkc6rmdpvLKPkyoJtVQ{margin:calc(var( --spacing-base )*2)}.j6vFPxWuu4Jan2ldoxpp{margin-left:calc(var( --spacing-base )*2);margin-right:calc(var( --spacing-base )*2)}.hqr39dC4H_AbactPAkCG{margin-bottom:calc(var( --spacing-base )*2)}.c3dQnMi16C6J6Ecy4283,.hqr39dC4H_AbactPAkCG{margin-top:calc(var( --spacing-base )*2)}.YNZmHOuRo6hU7zzKfPdP{margin-left:calc(var( --spacing-base )*2)}.Db8lbak1_wunpPk8NwKU{margin-bottom:calc(var( --spacing-base )*2)}.ftsYE5J9hLzquQ0tA5dY{margin-right:calc(var( --spacing-base )*2)}.Det4MHzLUW7EeDnafPzq{margin:calc(var( --spacing-base )*3)}.h_8EEAztC29Vve1datb5{margin-left:calc(var( --spacing-base )*3);margin-right:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM{margin-bottom:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM,.soADBBkcIKCBXzCTuV9_{margin-top:calc(var( --spacing-base )*3)}.zSX59ziEaEWGjnpZa4uV{margin-left:calc(var( --spacing-base )*3)}.yrVTnq_WBMbejg89c2ZQ{margin-bottom:calc(var( --spacing-base )*3)}.UKtHPJnI2cXBWtPDm5hM{margin-right:calc(var( --spacing-base )*3)}.guexok_Tqd5Tf52hRlbT{margin:calc(var( --spacing-base )*4)}.oS1E2KfTBZkJ3F0tN7T6{margin-left:calc(var( --spacing-base )*4);margin-right:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd{margin-bottom:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd,.ot2kkMcYHv53hLZ4LSn0{margin-top:calc(var( --spacing-base )*4)}.A1krOZZhlQ6Sp8Cy4bly{margin-left:calc(var( --spacing-base )*4)}.pkDbXXXL32237M0hokEh{margin-bottom:calc(var( --spacing-base )*4)}.XXv4kDTGvEnQeuGKOPU3{margin-right:calc(var( --spacing-base )*4)}.yGqHk1a57gaISwkXwXe6{margin:calc(var( --spacing-base )*5)}.X8cghM358X3DkXLc9aNK{margin-left:calc(var( --spacing-base )*5);margin-right:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f{margin-bottom:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f,.yqeuzwyGQ7zG0avrGqi_{margin-top:calc(var( --spacing-base )*5)}.g9emeCkuHvYhveiJbfXO{margin-left:calc(var( --spacing-base )*5)}.Lvk3dqcyHbZ07QCRlrUQ{margin-bottom:calc(var( --spacing-base )*5)}.r3yQECDQ9qX0XZzXlVAg{margin-right:calc(var( --spacing-base )*5)}.aQhlPwht2Cz1X_63Miw0{margin:calc(var( --spacing-base )*6)}.JyHb0vK3wJgpblL9s5j8{margin-left:calc(var( --spacing-base )*6);margin-right:calc(var( --spacing-base )*6)}.cY2gULL1lAv6WPNIRuf3{margin-bottom:calc(var( --spacing-base )*6)}.NBWQ9Lwhh_fnry3lg_p7,.cY2gULL1lAv6WPNIRuf3{margin-top:calc(var( --spacing-base )*6)}.yIOniNe5E40C8fWvBm5V{margin-left:calc(var( --spacing-base )*6)}.t30usboNSyqfQWIwHvT3{margin-bottom:calc(var( --spacing-base )*6)}.Nm_TyFkYCMhOoghoToKJ{margin-right:calc(var( --spacing-base )*6)}.C4qJKoBXpgKtpmrqtEKB{margin:calc(var( --spacing-base )*7)}.S93Srbu6NQ_PBr7DmTiD{margin-left:calc(var( --spacing-base )*7);margin-right:calc(var( --spacing-base )*7)}.fJj8k6gGJDks3crUZxOS{margin-bottom:calc(var( --spacing-base )*7)}.cW6D6djs7Ppm7fD7TeoV,.fJj8k6gGJDks3crUZxOS{margin-top:calc(var( --spacing-base )*7)}.DuCnqNfcxcP3Z__Yo5Ro{margin-left:calc(var( --spacing-base )*7)}.im8407m2fw5vOg7O2zsw{margin-bottom:calc(var( --spacing-base )*7)}.G0fbeBgvz2sh3uTP9gNl{margin-right:calc(var( --spacing-base )*7)}.kvW3sBCxRxUqz1jrVMJl{margin:calc(var( --spacing-base )*8)}.tOjEqjLONQdkiYx_XRnw{margin-left:calc(var( --spacing-base )*8);margin-right:calc(var( --spacing-base )*8)}.op5hFSx318zgxsoZZNLN{margin-bottom:calc(var( --spacing-base )*8)}.c9WfNHP6TFKWIfLxv52J,.op5hFSx318zgxsoZZNLN{margin-top:calc(var( --spacing-base )*8)}.sBA75QqcqRwwYSHJh2wc{margin-left:calc(var( --spacing-base )*8)}.GpL6idrXmSOM6jB8Ohsf{margin-bottom:calc(var( --spacing-base )*8)}.HbtWJoQwpgGycz8dGzeT{margin-right:calc(var( --spacing-base )*8)}.uxX3khU88VQ_Ah49Ejsa{padding:calc(var( --spacing-base )*0)}.KX0FhpBKwKzs9fOUdbNz{padding-left:calc(var( --spacing-base )*0);padding-right:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz{padding-bottom:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz,.emxLHRjQuJsImnPbQIzE{padding-top:calc(var( --spacing-base )*0)}.kJ8WzlpTVgdViXt8ukP9{padding-left:calc(var( --spacing-base )*0)}.tg_UIUI11VBzrTAn2AzJ{padding-bottom:calc(var( --spacing-base )*0)}.uczvl8kaz84oPQJ2DB2R{padding-right:calc(var( --spacing-base )*0)}.o7UHPcdVK3lt7q3lqV4o{padding:calc(var( --spacing-base )*1)}.IDqEOxvDoYrFYxELPmtX{padding-left:calc(var( --spacing-base )*1);padding-right:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2{padding-bottom:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2,.npy3hw4A5QSkDicb2CJJ{padding-top:calc(var( --spacing-base )*1)}.LgbptTApNY5NwLQvEFAt{padding-left:calc(var( --spacing-base )*1)}.WZQy2SZuZso59bUsXXyl{padding-bottom:calc(var( --spacing-base )*1)}.o331apInxNunbYB3SfPE{padding-right:calc(var( --spacing-base )*1)}.fMPIyD9Vqki1Lrc_yJnG{padding:calc(var( --spacing-base )*2)}.i2pMcTcdrr10IQoiSm_L{padding-left:calc(var( --spacing-base )*2);padding-right:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH{padding-bottom:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH,.o9bGieUKcYc8o0Ij9oZX{padding-top:calc(var( --spacing-base )*2)}.SwZcFez1RDqWsOFjB5iG{padding-left:calc(var( --spacing-base )*2)}.eHpLc_idmuEqeqCTvqkN{padding-bottom:calc(var( --spacing-base )*2)}.vU39i2B4P1fUTMB2l6Vo{padding-right:calc(var( --spacing-base )*2)}.JHWNzBnE29awhdu5BEh1{padding:calc(var( --spacing-base )*3)}.X72lGbb56L3KFzC2xQ9N{padding-left:calc(var( --spacing-base )*3);padding-right:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e{padding-bottom:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e,.srV0KSDC83a2fiimSMMQ{padding-top:calc(var( --spacing-base )*3)}.lUWfkmbQjCskhcNwkyCm{padding-left:calc(var( --spacing-base )*3)}.Ts0dIlc3aTSL7V4cIHis{padding-bottom:calc(var( --spacing-base )*3)}.CzlqQXXhX6MvorArFZ8B{padding-right:calc(var( --spacing-base )*3)}.TqMPkQtR_DdZuKb5vBoV{padding:calc(var( --spacing-base )*4)}.a7UrjhI69Vetlcj9ZVzz{padding-left:calc(var( --spacing-base )*4);padding-right:calc(var( --spacing-base )*4)}.StEhBzGs2Gi5dDEkjhAv{padding-bottom:calc(var( --spacing-base )*4)}.FGneZfZyvYrt1dG0zcnm,.StEhBzGs2Gi5dDEkjhAv{padding-top:calc(var( --spacing-base )*4)}.APEH216rpdlJWgD2fHc8{padding-left:calc(var( --spacing-base )*4)}.oGwXC3ohCic9XnAj6x69{padding-bottom:calc(var( --spacing-base )*4)}.U6gnT9y42ViPNOcNzBwb{padding-right:calc(var( --spacing-base )*4)}.IpdRLBwnHqbqFrixgbYC{padding:calc(var( --spacing-base )*5)}.HgNeXvkBa9o3bQ5fvFZm{padding-left:calc(var( --spacing-base )*5);padding-right:calc(var( --spacing-base )*5)}.tJtFZM3XfPG9v9TSDfN1{padding-bottom:calc(var( --spacing-base )*5)}.PdifHW45QeXYfK568uD8,.tJtFZM3XfPG9v9TSDfN1{padding-top:calc(var( --spacing-base )*5)}.mbLkWTTZ0Za_BBbFZ5b2{padding-left:calc(var( --spacing-base )*5)}.vVWpZpLlWrkTt0hMk8XU{padding-bottom:calc(var( --spacing-base )*5)}.RxfaJj5a1Nt6IavEo5Zl{padding-right:calc(var( --spacing-base )*5)}.SppJULDGdnOGcjZNCYBy{padding:calc(var( --spacing-base )*6)}.palY2nLwdoyooPUm9Hhk{padding-left:calc(var( --spacing-base )*6);padding-right:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_{padding-bottom:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_,.YEEJ9b90ueQaPfiU8aeN{padding-top:calc(var( --spacing-base )*6)}.QE0ssnsKvWJMqlhPbY5u{padding-left:calc(var( --spacing-base )*6)}.n8yA3jHlMRyLd5UIfoND{padding-bottom:calc(var( --spacing-base )*6)}.tXHmxYnHzbwtfxEaG51n{padding-right:calc(var( --spacing-base )*6)}.kBTsPKkO_3g_tLkj77Um{padding:calc(var( --spacing-base )*7)}.RyhrFx6Y1FGDrGAAyaxm{padding-left:calc(var( --spacing-base )*7);padding-right:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO{padding-bottom:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO,.vQVSq6SvWKbOMu6r4H6b{padding-top:calc(var( --spacing-base )*7)}.oBy5__aEADMsH46mrgFX{padding-left:calc(var( --spacing-base )*7)}.KVEXoJqf1s92j0JMdNmN{padding-bottom:calc(var( --spacing-base )*7)}.ZMXGNrNaKW3k_3TLz0Fq{padding-right:calc(var( --spacing-base )*7)}.tuiR9PhkHXhGyEgzRZRI{padding:calc(var( --spacing-base )*8)}.U7454qyWkQNa2iaSJziu{padding-left:calc(var( --spacing-base )*8);padding-right:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8{padding-bottom:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8,.X1rm9DQ1zLGLfogja5Gn{padding-top:calc(var( --spacing-base )*8)}.JS7G6kAuqJo5GIuF8S5t{padding-left:calc(var( --spacing-base )*8)}.Y8F9ga1TDCMbM1lj4gUz{padding-bottom:calc(var( --spacing-base )*8)}.AJuyNGrI63BOWql719H8{padding-right:calc(var( --spacing-base )*8)}.zI5tJ_qhWE6Oe6Lk75GY{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);--wp-admin-border-width-focus:1.51px;border-radius:var(--jp-border-radius);font-weight:600;justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo{height:calc(var(--spacing-base)*5);padding:var(--spacing-base);width:calc(var(--spacing-base)*5)}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo>svg:first-child{margin:0;padding:0}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo.Na39I683LAaSA99REg14{height:calc(var(--spacing-base)*4);min-width:calc(var(--spacing-base)*4);padding:calc(var(--spacing-base)/2);width:calc(var(--spacing-base)*4)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body);height:auto;line-height:24px;padding:var(--spacing-base) calc(var(--spacing-base)*3)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK{padding:var(--spacing-base) calc(var(--spacing-base)*2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body-extra-small);height:auto;line-height:20px;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK>svg:first-child{margin-left:calc(var(--spacing-base)/2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo)>.components-spinner{height:20px}.zI5tJ_qhWE6Oe6Lk75GY.lZAo6_oGfclXOO9CC6Rd{font-weight:400}.zI5tJ_qhWE6Oe6Lk75GY.xJDOiJxTt0R_wSl8Ipz_{min-width:100%}.zI5tJ_qhWE6Oe6Lk75GY.is-primary:disabled,.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:disabled{background:var(--jp-gray);color:var(--jp-gray-20)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary{background:var(--jp-white);box-shadow:inset 0 0 0 1.51px var(--jp-black)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:active:not(:disabled),.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:hover:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-link.Na39I683LAaSA99REg14,.zI5tJ_qhWE6Oe6Lk75GY.is-link.ipS7tKy9GntCS4R3vekF{padding:0}.zI5tJ_qhWE6Oe6Lk75GY.is-link:hover:not(:disabled){text-decoration-thickness:3px}.zI5tJ_qhWE6Oe6Lk75GY.is-link:focus:not(:disabled){text-decoration-line:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:not(:disabled){background:var(--jp-red-50);box-shadow:inset 0 0 0 1px var(--jp-red-50);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:hover:not(:disabled){background:var(--jp-red-60);box-shadow:inset 0 0 0 1px var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:focus:not(:disabled){background:var(--jp-red-70);box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:active:not(:disabled){background:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:not(:disabled){background:var(--jp-white);box-shadow:inset 0 0 0 1.5px var(--jp-red-50);color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:hover:not(:disabled){background:var(--jp-red-0);box-shadow:inset 0 0 0 1.5px var(--jp-red-60);color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:active:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:not(:disabled){color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:hover:not(:disabled){box-shadow:none;color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6{position:relative}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6.has-icon{justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>:not(.components-spinner){visibility:hidden}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>.components-spinner{margin:0;position:absolute}.CDuBjJp_8jxzx5j6Nept{margin-right:calc(var(--spacing-base)/2)}.kdsaL7c4bpTwf_A4fIUT{padding-bottom:calc(var(--spacing-base)*6);padding-top:calc(var(--spacing-base)*6);text-align:center}.b0eN3as5AgxQW7EAkarg{margin-bottom:0}@keyframes rotate-spinner{to{transform:rotate(-1turn)}}.jp-components-spinner{align-items:center;display:flex}.jp-components-spinner__inner,.jp-components-spinner__outer{animation:3s linear infinite;animation-name:rotate-spinner;border:.1em solid #0000;border-radius:50%;box-sizing:border-box;margin:auto}.jp-components-spinner__outer{border-top-color:#fff}.jp-components-spinner__inner{border-left-color:#fff;border-top-color:#fff;height:100%;opacity:.4;width:100%}.NHzH3tt6CypjZ92CvK9x{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:flex;padding:calc(var(--spacing-base)*2)}.NHzH3tt6CypjZ92CvK9x:first-of-type{border-top-left-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius)}.NHzH3tt6CypjZ92CvK9x:last-of-type{border-bottom-left-radius:var(--jp-border-radius);border-bottom-right-radius:var(--jp-border-radius)}.NHzH3tt6CypjZ92CvK9x+.NHzH3tt6CypjZ92CvK9x{border-top:0}.D9zvYDUrOP_zwSm0yJMs{margin-left:calc(var(--spacing-base)*2);min-width:24px}._XISfmbjoVlqhB61hHYn{width:100%}.AQDPBnMZFu7BOBuo8mYW{font-size:18px;font-weight:600;line-height:24px;margin-bottom:0}.cZ9s5eCAZe3R82Y6Ru3z{color:var(--jp-gray-80);font-size:14px;line-height:21px}.AKnbWQiViZ2O_dwCV8Fw,.W6alQ2_S5Rh06djX9m27{align-self:center;margin-left:var(--spacing-base);margin-right:calc(var(--spacing-base)*2)}.VLE2X0rP3Ug4QHebdiJd{background-color:var(--jp-gray-0);border-radius:4px;color:var(--jp-gray-80);display:inline-block;font-size:13px;font-weight:400;line-height:16px;padding:4px 8px}.VLE2X0rP3Ug4QHebdiJd.hEfxH6nau4tQkeE4BNms{background-color:var(--jp-green-5);color:var(--jp-green-50)}.VLE2X0rP3Ug4QHebdiJd.Snl4I6aKbXFIrcWaSIC0{background-color:var(--jp-yellow-5);color:var(--jp-yellow-60)}.VLE2X0rP3Ug4QHebdiJd.zvZFUdy480Xv3IHYbX6a{background-color:var(--jp-red-5);color:var(--jp-red-70)}.uUEJGMrSV3XoBwX5xEwA{display:flex;justify-content:space-between}.sQkG5Cu80gPaeFj3L_wa{margin-bottom:calc(var(--spacing-base)*5)}.oIl6GCMeUnzE0inXbuj9{display:flex;justify-content:space-between}.RP2MVoGqaCFXPKZhhxQ1{margin-bottom:calc(var(--spacing-base)*5)}.YpEs8b7KE7fzVuXUbOEb{display:flex;justify-content:space-between}.EqpwvErHtRi_WQkJKgi1{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:flex;margin-bottom:calc(var(--spacing-base)*3);padding:calc(var(--spacing-base)*2)}.EicvN1QaJu5OJLzdUN5A{margin-left:calc(var(--spacing-base)*2);min-width:24px}.b7ynAmUwGlxK_vxyIN0y{width:100%}.uSV9HYRxjL4S6zIZDlqP{font-size:18px;font-weight:600;line-height:24px;margin-bottom:0}.XpW8Mvw_XFEbqxUdw155{color:var(--jp-gray-80);font-size:14px;line-height:21px}.Fkj60BmQ5sUo9zHcJwVv{align-self:center;margin-left:var(--spacing-base);margin-right:calc(var(--spacing-base)*2)}.XLzPr74ad3osCq9kxy2q{display:flex;justify-content:space-between}.jNlU3vgp4xEGwmX5aTyK{background-color:var(--jp-gray-5)}.gE8s4nh3f7iGIBrFeyCT{list-style-type:disc;padding-right:calc(var(--spacing-base)*2.5)}.L9hh_sX51PzO41icwJlh{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:flex;margin-bottom:calc(var(--spacing-base)*3);padding:calc(var(--spacing-base)*2)}.o8E4Bv6U0d7USFxSjRCj{margin-left:calc(var(--spacing-base)*2);min-width:24px}.sT31awD6bHO8KJewvmaO{width:100%}.VVTRIG51r8ORUIBPs5gN{font-size:18px;font-weight:600;line-height:24px;margin-bottom:0}.AiaWRbRLFT9xvP9vn5jA{color:var(--jp-gray-80);font-size:14px;line-height:21px}.MP1wWkqvqfvAc7Izl7x4{align-self:center;margin-left:var(--spacing-base);margin-right:calc(var(--spacing-base)*2)}.i9X_KxEJiGpRT7q_RU6i{display:flex;justify-content:space-between}.WtVEv641JBaLl929sZq2{align-items:flex-start;background-color:#00000040;bottom:0;display:flex;justify-content:center;left:0;overflow-y:auto;padding-top:calc(var(--spacing-base)*12 + 2px);position:fixed;right:0;top:0;z-index:1000001}.G0aPt7WmA1rkUE0wcTno{background:var(--jp-white);border:1px solid var(--jp-gray);border-radius:calc(var(--jp-border-radius)*2);box-shadow:0 8px 20px #00000040;padding:calc(var(--spacing-base)*4);position:relative;width:616px}.VkrhWjfEIlIwYEumycbP{background:none;border:none;cursor:pointer;left:calc(var(--spacing-base)*3);padding:0;position:absolute;top:calc(var(--spacing-base)*3)}.yFzeV4cmWRbZKk5tIyEw{display:block}.lyrXe0pA852TUmyekDb5{display:flex}.KgEeDTKgTC5ZjzYlbTqN{color:var(--jp-black);font-size:var(--font-body);line-height:1.5;margin-left:calc(var(--spacing-base)*4);padding:var(--spacing-base) 0;text-decoration:none}.KgEeDTKgTC5ZjzYlbTqN:last-child{margin-left:0}.KgEeDTKgTC5ZjzYlbTqN:focus,.KgEeDTKgTC5ZjzYlbTqN:hover{border-bottom-color:var(--jp-green);box-shadow:none;color:var(--jp-green)}.Lv4WoNVkeJntqvUyG4dX{border-bottom:1px solid var(--jp-black)}.YXKeyNLeZvIdah_5_5GR{white-space:nowrap}.vvXnRXxrU1kP1KsdSr4J{margin-top:calc(var(--spacing-base)*3*-1)}.aDCTkUFaJEeZzYYE6qv5{background-color:var(--jp-green);border-radius:32px;color:var(--jp-white);font-size:12px;letter-spacing:-2%;line-height:1;margin-right:var(--spacing-base);padding:calc(var(--spacing-base)/2) var(--spacing-base);position:relative;top:-1px}.jp-dashboard-footer{align-items:center;color:var(--jp-black);display:flex;flex-wrap:wrap;font-size:var(--font-body-extra-small);line-height:1.333;max-width:1128px;width:100%}.jp-dashboard-footer a{text-decoration:none}.jp-dashboard-footer a:any-link,.jp-dashboard-footer a[role=button]{color:inherit}.jp-dashboard-footer a:hover{text-decoration:underline;text-decoration-thickness:1.5px}.jp-dashboard-footer a:focus{box-shadow:none;outline-width:0}.jp-dashboard-footer a:focus-visible{border-radius:2px;box-shadow:none;outline:1.5px solid currentColor;outline-offset:3px}.jp-dashboard-footer.is-sm>ul{gap:.125rem}.jp-dashboard-footer.is-md,.jp-dashboard-footer.is-sm>ul{align-items:flex-start;flex-direction:column}.jp-dashboard-footer>ul{align-items:center;display:flex;flex-wrap:wrap;gap:1rem;list-style:none;margin:0;padding:0;width:100%}.jp-dashboard-footer>ul>li{margin-bottom:0}.jp-dashboard-footer>ul>li>a{align-items:center;display:flex;gap:.25rem;min-height:44px}.jp-dashboard-footer__accessible-external-link{border:0;clip:rect(1px,1px,1px,1px);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;overflow-wrap:normal;padding:0;position:absolute;width:1px}.jp-dashboard-footer__jp-item{font-weight:600;padding-inline-end:1rem}.jp-dashboard-footer.is-sm .jp-dashboard-footer__jp-item{padding-bottom:1rem}.jp-dashboard-footer.is-lg .jp-dashboard-footer__a8c-item{margin-inline-start:auto}.jp-dashboard-footer.is-sm .jp-dashboard-footer__a8c-item{padding-top:1rem}.jp-dashboard-footer__a8c-item>a,.jp-dashboard-footer__jp-item>a{text-decoration:none}@media(max-width:599px){.RuVLl3q4lxTQa3wbhBJB{grid-column-end:span 1}.f9LZTRG4MMK42rS89afW{grid-column-start:1}.bHe_zKxjjpUwHw_MdYE1{grid-column-end:2}.QZbNrOqE2aNSn50xVhpU{grid-column-end:span 2}.ev7W3z7zVYPeHAlYqZjf{grid-column-start:2}.NJWd1m_e7lOiPYru2ZMP{grid-column-end:3}.Xc6nt1Qc1DI0Z2A3gt1r{grid-column-end:span 3}.UIcN_GXiPRoIsin8Kohg{grid-column-start:3}.GRKCyqb5LufCSCgykKFc{grid-column-end:4}.i_qTq8gqhhC3vIUepVRB{grid-column-end:span 4}.G3qaZ3Jpbvam_1XvGxgc{grid-column-start:4}.VRCNYKZtO9zukEwmgP1y{grid-column-end:5}}@media(min-width:600px)and (max-width:959px){.tRm008K_WJL79WoNZTNL{grid-column-end:span 1}.l5T2P_bgKts4tdaRkS1d{grid-column-start:1}.zOCxfLZpF6BlgC7a_Yq1{grid-column-end:2}.F80DdgVn0m5OpvtSQWka{grid-column-end:span 2}.oI1c7JYfiJtMQHbhngtU{grid-column-start:2}.pMQtA_4jh1_1lVknqEP5{grid-column-end:3}.VenqMpdgyKQVUNNQcfqd{grid-column-end:span 3}.seNYL99uoczf9V4MxBxT{grid-column-start:3}.YKfF1HFhI9KygA5l3b2J{grid-column-end:4}.yAi0Cv1xDWkoqsaUhvhR{grid-column-end:span 4}.ubhnyZOnkgxNhh6XtVWv{grid-column-start:4}.RGOPGQbWMJ9Ei5oFxS7X{grid-column-end:5}.Sz1E2aWbX483ijdi6yge{grid-column-end:span 5}.tku6_bRYrX9tMbgYGmIl{grid-column-start:5}.b5JHttOhSEcI1WBlqAjk{grid-column-end:6}.FboSx5MoKTAWbxXyYlCw{grid-column-end:span 6}.Jhs8yEEmodG30edbJvag{grid-column-start:6}.IpzbbKVqEqPcfIGkXkwt{grid-column-end:7}.mhCPwfAZ4Kmm_empzJAq{grid-column-end:span 7}.x034ilrJF7rO9UJB2rI1{grid-column-start:7}.Wt8t2e16viRrOJ1lLA5v{grid-column-end:8}.S6pIrEy9AMLKx9bgh_Ae{grid-column-end:span 8}.kEfI4tGyuWfHTlRnvIab{grid-column-start:8}.PUzX4RRsKq1dnsz3gebS{grid-column-end:9}}@media(min-width:960px){.X_pdcLJikd8LS_YAdJlB{grid-column-end:span 1}.tl936d14Huby4khYp05X{grid-column-start:1}.hnge0LnR69d3NXEtEE1t{grid-column-end:2}.fj0NUMuyZQcPNgKcjp5Z{grid-column-end:span 2}.R2ncBX7a2NigdYCcV1OX{grid-column-start:2}.t8vMSDVYno9k9itRwnXb{grid-column-end:3}.wsDuEN2GqHx6qzo8dUdk{grid-column-end:span 3}.cIEVPUweWtLBy3xaXnMx{grid-column-start:3}.fajUWBwu1m2B479j3jmz{grid-column-end:4}.YR0c7fQTgMkDdWzwSyLp{grid-column-end:span 4}.xlwp8BmplxkKNMI7gamo{grid-column-start:4}._C4O1w9DUqx1m3gPf8aA{grid-column-end:5}.Z54F1hAErckAIrKlxnXW{grid-column-end:span 5}.ezSDWkRHmKSxDJXxuiOH{grid-column-start:5}.T0ChoeAjGJjkkNrYhD4g{grid-column-end:6}.qtMoMPF6yHvGJnWHSsde{grid-column-end:span 6}.gdoywN5VPiWERfIBqkph{grid-column-start:6}.wUev_VH5uf_pwFFlbnAU{grid-column-end:7}.egIPDFJsOpownTClq9XP{grid-column-end:span 7}.yGhp9yoAW7k0kQik9AB7{grid-column-start:7}.SJ43U9mR5wUg5V2qBeQA{grid-column-end:8}.cTuyHfMwSUJxN_HdIEgd{grid-column-end:span 8}.smCr8DaIagcumdvdldiK{grid-column-start:8}.T03NHzQJvzwL6wAfIiTL{grid-column-end:9}.pMvxM3RJGjqyNdf9qg1Y{grid-column-end:span 9}.iIVpNRwEnQ_JI5gpp9EN{grid-column-start:9}.ZbQ4u4vGSX5rJOje4uGL{grid-column-end:10}.gKb5wuIDAlKGbrjK2vxy{grid-column-end:span 10}.Z7pINdImE2WJiYnZBTqm{grid-column-start:10}.ZTxp6qpvwurMdOnLLSz1{grid-column-end:11}.NnQTlbfnxPDR6cQ7rygg{grid-column-end:span 11}.O137wZd6Yl0olSA9PsXR{grid-column-start:11}.zf2OJtQ2MPz6SDoh6CB0{grid-column-end:12}.U3H6UHW6HqRt9hdzVg3O{grid-column-end:span 12}.zynnNeS_ZBTxABcVpUQH{grid-column-start:12}.vI8tltFZtFUNAy9Iag9s{grid-column-end:13}}.SqdhUZkXCRuIpErj1B3z{--max-container-width:1128px;--vertical-gutter:24px;--horizontal-spacing:8px;column-gap:var(--vertical-gutter);display:grid;margin:0 auto;max-width:var(--max-container-width);width:100%}@media(max-width:599px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(4,minmax(0,1fr));padding:0 16px}}@media(min-width:600px)and (max-width:959px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(8,minmax(0,1fr));padding:0 18px}}@media(min-width:960px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(12,minmax(0,1fr));padding:0 24px}}.SqdhUZkXCRuIpErj1B3z.OZC_9a1LhpWF9dv15Gdh{max-width:none;padding:unset}.sexr0jUxC1jVixdKiDnC{margin-right:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-right:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.sexr0jUxC1jVixdKiDnC .iWGAhN9gOB48g0jEO1OQ{align-items:center;display:flex;gap:8px}.sexr0jUxC1jVixdKiDnC .JOYmuxQjG4FArIIUxJfA{background:#d63638;color:#fff;cursor:pointer;font-size:9px;font-weight:700;letter-spacing:.2em;text-shadow:none;text-transform:uppercase}.rigH8UdiDrmmSLQMUurD{background-color:var(--jp-white);border:1px solid var(--jp-gray-10);border-radius:var(--jp-border-radius);color:var(--jp-black);display:block;font-size:var(--font-body);letter-spacing:-.02em;line-height:1.5;padding:var(--spacing-base) calc(var(--spacing-base)*1.5);transition:box-shadow .1s ease-out;width:100%}.rigH8UdiDrmmSLQMUurD::placeholder{color:var(--jp-gray-20)}.rigH8UdiDrmmSLQMUurD:focus{box-shadow:0 0 0 2px var(--jp-green-5)}.rigH8UdiDrmmSLQMUurD:focus,.rigH8UdiDrmmSLQMUurD:hover:not(:disabled){border:1px solid var(--jp-green)}.rigH8UdiDrmmSLQMUurD:disabled{background-color:var(--jp-gray-0);color:var(--jp-gray-30)}.V8FDM08CpcwQs4UwN2nI{color:var(--jp-black);display:block;font-size:var(--font-title-small);font-weight:600;margin-bottom:var(--spacing-base)}.WjKn66iJO4hAZYE6o9b3{font-weight:700}.IS5K46VvD7VX5YtlwbMI,.eDfoDi2nArFY_KiYIwKh{margin-bottom:calc(var(--spacing-base)*7);margin-top:calc(var(--spacing-base)*7)}.XKUO6pX9vFbOUplFfCW2{margin-top:calc(var(--spacing-base)*3)}.gridicon{fill:currentColor;display:inline-block}.gridicon.needs-offset g{transform:translate(-1px,1px)}.gridicon.needs-offset-x g{transform:translate(-1px)}.gridicon.needs-offset-y g{transform:translateY(1px)}:root{--font-title-large:36px;--font-title-small:24px;--font-body:16px;--font-label:12px;--jp-black:#000;--jp-black-80:#2c3338;--jp-white:#fff;--jp-white-off:#f9f9f6;--jp-gray:#dcdcde;--jp-gray-0:#f6f7f7;--jp-gray-5:#dcdcde;--jp-gray-10:#c3c4c7;--jp-gray-20:#a7aaad;--jp-gray-30:#8c8f94;--jp-gray-40:#787c82;--jp-gray-50:#646970;--jp-gray-60:#50575e;--jp-gray-70:#3c434a;--jp-gray-80:#2c3338;--jp-gray-90:#1d2327;--jp-gray-100:#101517;--jp-gray-off:#e2e2df;--jp-yellow-5:#f5e6b3;--jp-yellow-10:#f2cf75;--jp-yellow-40:#c08c00;--jp-orange-20:#faa754;--jp-blue-5:#ced9f2;--jp-red-0:#f7ebec;--jp-red-50:#d63638;--jp-red-60:#b32d2e;--jp-red-80:#8a2424;--jp-red:#d63639;--jp-pink:#c9356e;--jp-green-0:#f0f2eb;--jp-green-5:#d0e6b8;--jp-green-10:#9dd977;--jp-green-20:#64ca43;--jp-green-30:#2fb41f;--jp-green-40:#069e08;--jp-green-50:#008710;--jp-green-60:#007117;--jp-green-70:#005b18;--jp-green-80:#004515;--jp-green-90:#003010;--jp-green-100:#001c09;--jp-green:#069e08;--jp-green-primary:var(--jp-green-40);--jp-green-secondary:var(--jp-green-30);--jp-border-radius:4px;--jp-border-radius-rna:8px;--jp-menu-border-height:1px;--jp-underline-thickness:2px;--jp-modal-padding-large:32px;--jp-modal-padding:24px;--jp-modal-padding-small:16px;--jp-modal-radius:8px;--jp-button-padding:8px;--jp-button-radius:4px;--jp-gap:16px;--jp-highlight:#3858e9}:where(body){font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0;min-height:100%;padding:0}.jp-wrap{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.jp-row{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.jp-row{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.jp-row{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.sm-col-span-1{grid-column-end:span 1}.sm-col-span-2{grid-column-end:span 2}.sm-col-span-3{grid-column-end:span 3}.sm-col-span-4{grid-column-end:span 4}@media(min-width:600px){.md-col-span-1{grid-column-end:span 1}.md-col-span-2{grid-column-end:span 2}.md-col-span-3{grid-column-end:span 3}.md-col-span-4{grid-column-end:span 4}.md-col-span-5{grid-column-end:span 5}.md-col-span-6{grid-column-end:span 6}.md-col-span-7{grid-column-end:span 7}.md-col-span-8{grid-column-end:span 8}}@media(min-width:960px){.lg-col-span-1{grid-column-end:span 1}.lg-col-span-2{grid-column-end:span 2}.lg-col-span-3{grid-column-end:span 3}.lg-col-span-4{grid-column-end:span 4}.lg-col-span-5{grid-column-end:span 5}.lg-col-span-6{grid-column-end:span 6}.lg-col-span-7{grid-column-end:span 7}.lg-col-span-8{grid-column-end:span 8}.lg-col-span-9{grid-column-end:span 9}.lg-col-span-10{grid-column-end:span 10}.lg-col-span-11{grid-column-end:span 11}.lg-col-span-12{grid-column-end:span 12}}@media(max-width:960px){.md-col-span-0{display:none}}@media(max-width:600px){.sm-col-span-0{display:none}}.jp-cut{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);margin:32px 0;padding:16px 24px 16px 64px;position:relative;text-decoration:none}.jp-cut,.jp-cut span{display:block}.jp-cut span:last-of-type{font-weight:600}.jp-cut:focus span:last-of-type,.jp-cut:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.jp-cut:focus:after,.jp-cut:hover:after{transform:translateY(-50%) translateX(-8px)}.jp-cut:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;left:24px;position:absolute;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.components-popover:not(.is-without-arrow):before{border-color:var(--jp-gray)}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=left] .components-popover__content{margin-left:-62px}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=right] .components-popover__content{margin-right:-62px}.icon-tooltip-helper .components-popover[data-y-axis=bottom] .components-popover__content{top:2px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:before{top:-6px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:after{top:-4px!important}.icon-tooltip-helper .components-popover[data-y-axis=top] .components-popover__content{bottom:10px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:before{bottom:3px}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:after{bottom:4px}.icon-tooltip-helper.is-wide .components-popover__content{width:440px}.icon-tooltip-wrapper{color:var(--jp-black);display:inline-block;position:relative}.icon-tooltip-wrapper .components-button.is-link:focus:not(:disabled){box-shadow:none}.icon-tooltip-helper{height:18px;pointer-events:none;position:absolute;right:-53px;top:0;width:124px}.icon-tooltip-container{pointer-events:all}.icon-tooltip-container .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;margin:0 10px;max-width:90vw;outline:none;padding:24px;white-space:normal;width:304px}.icon-tooltip-title{font-size:16px;font-weight:600;line-height:19px}.icon-tooltip-title:not(:last-child){margin-bottom:8px}.icon-tooltip-content{font-size:14px;font-weight:400;line-height:24px}.icon-tooltip-content ul{list-style-type:disc;margin:0 1rem 0 0}.icon-tooltip-content ul li:last-child{margin-bottom:0}.msOlyh2T7D6uhbM6AROg{align-items:center;background:none;border:2px solid var(--jp-green-40);border-radius:var(--jp-border-radius);color:var(--jp-gray-80);display:flex;gap:calc(var(--spacing-base)*3);justify-content:space-between;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);position:relative;text-align:right;width:100%}.msOlyh2T7D6uhbM6AROg a,.msOlyh2T7D6uhbM6AROg button{all:unset;color:var(--jp-gray-80);cursor:pointer}.msOlyh2T7D6uhbM6AROg a:after,.msOlyh2T7D6uhbM6AROg button:after{content:"";height:100%;position:absolute;right:0;top:0;width:100%}.msOlyh2T7D6uhbM6AROg:focus-within{border-color:var(--jp-black)}.msOlyh2T7D6uhbM6AROg:focus-within .cPN7USVqSBpxUswfDtUZ,.msOlyh2T7D6uhbM6AROg:hover .cPN7USVqSBpxUswfDtUZ{transform:translateX(calc((var(--spacing-base)*2)*-1))}.msOlyh2T7D6uhbM6AROg:focus-within .EmnJAyEzzn1QpA8HtypY,.msOlyh2T7D6uhbM6AROg:hover .EmnJAyEzzn1QpA8HtypY{text-decoration:underline;text-decoration-thickness:2px}.EmnJAyEzzn1QpA8HtypY,.msOlyh2T7D6uhbM6AROg .EmnJAyEzzn1QpA8HtypY{font-weight:700}.cPN7USVqSBpxUswfDtUZ{fill:var(--jp-green-40);pointer-events:none;transition:transform .1s ease-out}.vV7YZikAz0oHYsuvtxMq{display:inline;margin:0 calc(var(--spacing-base)/3) 0 0;vertical-align:middle}.vV7YZikAz0oHYsuvtxMq svg{position:relative;z-index:10}.T1YaMupeZmBIpXZHY9EZ{display:inline}.pVJWvyeviifcrLbZZxCj{align-items:flex-start}.pVJWvyeviifcrLbZZxCj,.segmN0DtUjey3r5zVPON{display:flex;flex-direction:column;justify-content:center}.segmN0DtUjey3r5zVPON{align-items:flex-end}.lolS8hq75wfk687xQjbY{margin-bottom:calc(var(--spacing-base)/2*-1);margin-right:var(--spacing-base)}.HC8zzYgv0GvkecCkpyld{width:fit-content}.XJqRbP_azFalXqUoYPtl{margin-top:calc(var(--spacing-base)*3 + 1px)}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off);padding-top:1px}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aLWBKY0yRghEk7tNCgK3{fill:var(--color-bluesky)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.af4Y_zItXvLAOEoSDPSv{fill:var(--color-twitter)}.cbOwD8Y4tFjwimmtchQI.f68aqF3XSD1OBvXR1get{fill:var(--color-linkedin)}.cbOwD8Y4tFjwimmtchQI.xFI0dt3UiXRlRQdqPWkx{fill:var(--color-tumblr)}.cbOwD8Y4tFjwimmtchQI.q7JEoyymveP6kF747M43{fill:var(--color-gplus)}.cbOwD8Y4tFjwimmtchQI.DKOBOTVmTLbh26gUH_73{fill:var(--color-mastodon)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw{fill:var(--color-nextdoor)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.cL3m0xBYTYhIKI7lCqDB{fill:var(--color-instagram)}.cbOwD8Y4tFjwimmtchQI.fftumuc_lJ6v0tq4UMVR{fill:var(--color-whatsapp)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI{fill:var(--color-threads)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI.social-logo{border-radius:40%}.L1LjeCYPldBcTLILS13l{max-width:calc(744px + var(--spacing-base)*6);width:100%}.JWWznnb8sAKHIOhE59_z{display:flex}.JWWznnb8sAKHIOhE59_z:not(:first-child){margin-top:calc(var(--spacing-base)*7)}.kV5wl2UResIqqBdSTuQr{margin-left:calc(var(--spacing-base)*2);padding-top:calc(var(--spacing-base)/2)}@media(min-width:600px){.kV5wl2UResIqqBdSTuQr{margin-left:calc(var(--spacing-base)*5)}}.oePuSIKcH_JzEhDJcHh8{width:100%}.mxYw7vghJF8H8C0FjvPz{align-items:center;display:flex}.lyiOCAyjT_eQyDg8Ier_ .oePuSIKcH_JzEhDJcHh8{opacity:.5}.IclfL4iNXTZfBAbHZdog>:last-child{margin-top:calc(var(--spacing-base)*2)}@media(min-width:600px){.IclfL4iNXTZfBAbHZdog{display:flex;justify-content:space-between}}.bOadM4auwszaOl0el95T{display:flex;flex-wrap:wrap;margin-top:calc(var(--spacing-base)*2)}.G7vkgqk8AEd6pRbNUyE4{color:var(--jp-green-50);margin-left:calc(var(--spacing-base)/2)}.qnlbRElIsj4nB45F5s3a{color:var(--jp-gray-50)}.TvvdPGzRa_ubn3BnQOnQ{color:var(--jp-red-50)}.yAFMUkq1ot9DZF05RUwG{margin-top:calc(var(--spacing-base)*3)}@media(min-width:600px){.yAFMUkq1ot9DZF05RUwG{padding-right:calc(var(--spacing-base)*11)}}.qoajQ2Ew8eYJgdbssSg9{margin-top:calc(var(--spacing-base)*3)}.EbfrbByI7NQ2_MD_gDXp{align-items:center;border:1px solid var(--jp-gray-30);border-radius:4px;color:var(--jp-gray-30);display:flex;font-size:12px;height:21px;margin-bottom:calc(var(--spacing-base)*2);margin-right:var(--spacing-base);padding:calc(var(--spacing-base)/2)}.hCwaBLH_6dELyWWwB8S1{padding:calc(var(--spacing-base)*3);width:304px}.V3U9oKSdRmKjOQ523C86{display:flex;justify-content:space-between}.OSrT4pA4vIGzg9EE6rcv{margin:calc(var(--spacing-base)*-1) calc(var(--spacing-base)*-3)}.OSrT4pA4vIGzg9EE6rcv:focus,.OSrT4pA4vIGzg9EE6rcv:focus:not(:disabled){box-shadow:none}.rbL50q3wwzE6X7VBHcmW{display:flex;justify-content:flex-end}.g593fzjQCE_4rNiiwLdg{line-height:1;margin-bottom:calc(var(--spacing-base)*1.5)}.CIp_BwDbLdjYPSVrreqg{align-items:flex-start;justify-content:space-between}.CIp_BwDbLdjYPSVrreqg,.m2epTt5F7wBQNcMdguwQ{display:flex;margin-top:calc(var(--spacing-base)*2)}.m2epTt5F7wBQNcMdguwQ{justify-content:right}.HrEvG7sxsWbTLD0sk477{border-bottom:2px solid var(--jp-gray-5);margin-top:calc(var(--spacing-base)*7)}.WIttYmnC0O4JKFyPgkTW{padding:calc(var(--spacing-base)*2);width:250px}.p1_cy4ERoY1_uwtgq3Tn{align-items:center;display:flex}.ehnXRuGNl9ZnPh6c1Pa3{display:flex;flex-wrap:wrap;margin-right:auto}.ehnXRuGNl9ZnPh6c1Pa3>:first-child{margin-left:calc(var(--spacing-base)*3)}.ehnXRuGNl9ZnPh6c1Pa3 .q8mOIlVn7qA44s7ysC5Z{opacity:.5}.IxCDeZ2a0wRu3AQbqGuG{align-items:center;display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*3);width:100%}.YIQOtwFZuyfirlpFfjDb{white-space:nowrap}@media(max-width:1115px){.ehnXRuGNl9ZnPh6c1Pa3{margin-top:calc(var(--spacing-base)*3)}}@media(max-width:599px){.ehnXRuGNl9ZnPh6c1Pa3{margin-top:calc(var(--spacing-base)*3)}.ehnXRuGNl9ZnPh6c1Pa3>:first-child{margin-bottom:var(--spacing-base);margin-left:0}.IxCDeZ2a0wRu3AQbqGuG{margin-bottom:0}}.x8nPhsBEpxvgCxHNbCXo{display:flex}.x8nPhsBEpxvgCxHNbCXo .b_pwVVOoMN73AXhJNbgr{margin-left:var(--spacing-base);margin-top:calc(var(--spacing-base)/2)}.MWO4b3hqGdH8p1Vt9zmQ{margin-right:calc(var(--spacing-base)/2);max-height:20px}.DuflEZ86axRQGuMhmH3n{color:var(--jp-gray-20)}.ywr2PcNYcX5_sEzdvHAS{color:var(--jp-gray-70);font-weight:400;line-height:24px}.e_wseeb7HqoyLjv9N_ww{background-color:var(--jp-white-off)}.mzfjOg8s_uehdCmNjX0P,.nxtQ3M8WCX69d_NjShwZ{align-items:flex-start;display:flex;flex-direction:column;gap:calc(var(--spacing-base)*2)}.mzfjOg8s_uehdCmNjX0P .components-toggle-control__label,.nxtQ3M8WCX69d_NjShwZ .components-toggle-control__label{font-size:var(--font-body);font-weight:500}.mzfjOg8s_uehdCmNjX0P .components-base-control__help,.nxtQ3M8WCX69d_NjShwZ .components-base-control__help{color:inherit}.VfIXL69k_I0zUU0s7LqM{background-color:var(--jp-white);border-radius:calc(var(--jp-border-radius)*2);box-shadow:0 4px 40px #00000014;display:flex}.VfIXL69k_I0zUU0s7LqM.SvvAonSzsVSo_5Hu6Goz{align-items:center;padding:calc(var(--spacing-base)*2);width:358px}.VfIXL69k_I0zUU0s7LqM.SvvAonSzsVSo_5Hu6Goz .dwXtyo4qYbpJ2b3rZL1N{align-items:center;display:flex;overflow:hidden;width:100%}.VfIXL69k_I0zUU0s7LqM.SvvAonSzsVSo_5Hu6Goz .WxFqmtANZGuBRdR2NewQ{flex-grow:1;margin:0 calc(var(--spacing-base)*2)}.VfIXL69k_I0zUU0s7LqM.ee2TJQm2FgpSRwchomAH{--square-stat-vertical-spacing:calc(var( --spacing-base )*2);--square-stat-horizontal-spacing:calc(var( --spacing-base )*3);flex-direction:column;height:168px;justify-content:space-between;padding:var(--square-stat-vertical-spacing) var(--square-stat-horizontal-spacing);width:168px}.VfIXL69k_I0zUU0s7LqM.ee2TJQm2FgpSRwchomAH .WxFqmtANZGuBRdR2NewQ{margin-bottom:calc(var(--spacing-base)/2)}.VfIXL69k_I0zUU0s7LqM .mgcKzhKqFk7UOZ156QPT{overflow:hidden;text-overflow:ellipsis}.VfIXL69k_I0zUU0s7LqM .h_uY7ygjuMtuY4ZWJz1R{color:var(--jp-green-40);display:flex;fill:var(--jp-green-40)}.bZ4b33s2MdcOjaDKBbeV{--spacing-base:8px;--wp-admin-border-width-focus:1.5px;align-items:center;display:flex;white-space:nowrap}.UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-gray-50);border-radius:50%;flex-shrink:0;height:.666em;width:.666em}.QuS0vdcr87FsiBvSSrvA{font-weight:600;line-height:1.666;margin-right:calc(var(--spacing-base)/2)}.bZ4b33s2MdcOjaDKBbeV.bGx0wbQAwuY7k8P3PHVQ a,.bZ4b33s2MdcOjaDKBbeV.bGx0wbQAwuY7k8P3PHVQ span{color:var(--jp-green-50)}.bZ4b33s2MdcOjaDKBbeV.bGx0wbQAwuY7k8P3PHVQ .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-green-50)}.bZ4b33s2MdcOjaDKBbeV.wR8Cz8uHgObTQavolv5y a,.bZ4b33s2MdcOjaDKBbeV.wR8Cz8uHgObTQavolv5y span{color:var(--jp-gray-50)}.bZ4b33s2MdcOjaDKBbeV.wR8Cz8uHgObTQavolv5y .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-gray-50)}.bZ4b33s2MdcOjaDKBbeV.IzbBYGwBKhSYFUQlIMww a,.bZ4b33s2MdcOjaDKBbeV.IzbBYGwBKhSYFUQlIMww span{color:var(--jp-red-50)}.bZ4b33s2MdcOjaDKBbeV.IzbBYGwBKhSYFUQlIMww .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-red-50)}.bZ4b33s2MdcOjaDKBbeV.Kdvp_HJf89IBrZuCaLm8 a,.bZ4b33s2MdcOjaDKBbeV.Kdvp_HJf89IBrZuCaLm8 span{color:var(--jp-yellow-30)}.bZ4b33s2MdcOjaDKBbeV.Kdvp_HJf89IBrZuCaLm8 .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-yellow-30)}.bZ4b33s2MdcOjaDKBbeV.hVf5vsbBWm8OFye7cy7a a,.bZ4b33s2MdcOjaDKBbeV.hVf5vsbBWm8OFye7cy7a span{color:var(--jp-blue-40)}.bZ4b33s2MdcOjaDKBbeV.hVf5vsbBWm8OFye7cy7a .UzkzDaqt2mXprJh2OXRz{background-color:var(--jp-blue-40)}.gecp_0Z0owRZtj8JAYir{--base-width:8px;--track-width:calc(var(--base-width)*6)}.gecp_0Z0owRZtj8JAYir.qgKXEdMmHsIK84VDnLO2{--base-width:6px}.gecp_0Z0owRZtj8JAYir.Vy6dbB4PsGKm8BDqzJ9J .components-toggle-control__label{display:none}.gecp_0Z0owRZtj8JAYir .components-form-toggle{--wp-admin-theme-color:var( --jp-green-40 );height:calc(var(--base-width)*3)}.gecp_0Z0owRZtj8JAYir .components-form-toggle__input:focus+.components-form-toggle__track{box-shadow:0 0 0 2px var(--jp-white),0 0 0 4px var(--jp-green-50)}.gecp_0Z0owRZtj8JAYir .components-form-toggle .components-form-toggle__track{border-radius:12px;border-width:2px;height:calc(var(--base-width)*3);width:var(--track-width)}.gecp_0Z0owRZtj8JAYir .components-form-toggle .components-form-toggle__thumb{height:calc(var(--base-width)*2);right:calc(var(--base-width)/2);top:calc(var(--base-width)/2);width:calc(var(--base-width)*2)}.gecp_0Z0owRZtj8JAYir .components-form-toggle.is-checked .components-form-toggle__thumb{transform:translateX(calc((var(--base-width)*3)*-1))}.gecp_0Z0owRZtj8JAYir .components-toggle-control__help{margin-inline-start:calc(var(--track-width) + var(--spacing-base))}.gecp_0Z0owRZtj8JAYir.ykWv7fKpkVW_vpAoddu4 .components-form-toggle{opacity:.6}.VHYulMcpzbr10HWR0iSE{align-items:flex-start;border:1px solid var(--jp-black);border-color:var(--jp-gray-5);border-radius:4px;border-right-width:6px;display:flex;font-size:var(--font-body);padding:24px 18px 27px 31px}.FGpSkMCiIHQjszcV0dbn{height:calc(var(--spacing-base)*3);margin-left:20px;width:calc(var(--spacing-base)*3)}.KoWZcCwhW13xvkEb0QON{background-color:#0000;border:none;cursor:pointer;outline:none;padding:0}.KoWZcCwhW13xvkEb0QON svg{display:block}@media screen and (max-width:600px){.VHYulMcpzbr10HWR0iSE{box-shadow:0 4px 8px #00000008,0 1px 2px #0000000f;padding-top:68px;position:relative}.FGpSkMCiIHQjszcV0dbn{position:absolute;right:24px;top:24px}.KoWZcCwhW13xvkEb0QON{left:24px;position:absolute;top:24px}}.smrfczkC53EaFM8OJUXs{flex-grow:1}.IKYRWoPwt9xOVEx1wzNS{font-weight:600;margin-bottom:8px}.qM0qY6mPYp1MPN54A3Kg{align-items:center;display:flex;flex-wrap:wrap;margin-top:20px;row-gap:20px}@media screen and (max-width:600px){.qM0qY6mPYp1MPN54A3Kg{justify-content:center}}.qM0qY6mPYp1MPN54A3Kg a,.qM0qY6mPYp1MPN54A3Kg a:active,.qM0qY6mPYp1MPN54A3Kg a:focus,.qM0qY6mPYp1MPN54A3Kg a:hover{color:var(--jp-black)}.qM0qY6mPYp1MPN54A3Kg>*{margin-left:24px}.A5YkDkkXuiYgavrY6Nux{border-right-color:var(--jp-red)}.A5YkDkkXuiYgavrY6Nux .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-red)}.cT5rwuPMZzWvi5o6shMl{border-right-color:var(--jp-yellow-20)}.cT5rwuPMZzWvi5o6shMl .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-yellow-20)}.yo0O3uvNomPsYUXFCpAS{border-right-color:var(--black)}.yo0O3uvNomPsYUXFCpAS .y_IPyP1wIAOhyNaqvXJq{fill:var(--black)}.oZdDFf1jBLkzn5ICCC6x{border-right-color:var(--jp-green)}.oZdDFf1jBLkzn5ICCC6x .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-green)}._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box}.GqFcAwJvIrg1v7f6QUfw{display:flex;flex-direction:column;min-height:230px;padding:calc(var(--spacing-base)*3);width:304px}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S{display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*2)}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S .KnqJLKwSceJTwFJrPGHq{max-width:226px}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S .PJU0_yA9jNf7ao0jhHut{background-color:var(--jp-white);color:var(--jp-gray-90);flex-shrink:0;height:calc(var(--spacing-base)*3);min-width:unset;width:calc(var(--spacing-base)*3)}.GqFcAwJvIrg1v7f6QUfw .OENx8kmm62tkWGukzP2S .PJU0_yA9jNf7ao0jhHut:hover:not(:focus){box-shadow:none}.GqFcAwJvIrg1v7f6QUfw .rrORM3zqHfGvqiPduEXY{align-items:flex-end;display:flex;flex-grow:1;height:calc(var(--spacing-base)*6);justify-content:flex-end;margin-top:calc(var(--spacing-base)*2)}.GqFcAwJvIrg1v7f6QUfw .rrORM3zqHfGvqiPduEXY .Q7fUcDUGhteXEr18rZPC{color:var(--jp-gray-60);flex-grow:1;margin-bottom:var(--spacing-base)}.GqFcAwJvIrg1v7f6QUfw .rrORM3zqHfGvqiPduEXY .S5LAeskUiEQ0JlPhr0Ze{flex-shrink:0}.OtDl6kocO_m2s9sRHaqX{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;max-height:600px;width:100%}.BjwJh1S1YVPI7AjmTx6a+.BjwJh1S1YVPI7AjmTx6a{margin-top:calc(var(--spacing-base)*5)}.YWfK8VTp2wnByBauYPKg{background-color:var(--jp-gray-0);overflow-x:scroll;padding:calc(var(--spacing-base)*3)}.pkw2LnOTd8VvQ3oT8sXQ{justify-content:flex-end;margin-top:calc(var(--spacing-base)*3);padding-top:calc(var(--spacing-base)*3)}.ap6lG79CncSqdigJS_WA{margin-top:calc(var(--spacing-base)*4)}.uym7dGHhp6ifjF57yOAO{align-items:flex-end;display:flex;margin-bottom:calc(var(--spacing-base)*2.25)}.e_2eFTR8RyHwmfeqJL4F{flex:1;margin-bottom:0}.IKQVU01PrDMMV5UFLOKv{display:flex;gap:calc(var(--spacing-base)*2)}.pkw2LnOTd8VvQ3oT8sXQ{border-top:1px solid var(--jp-gray);display:flex;justify-content:right;padding-top:calc(var(--spacing-base)*4);width:100%}.pkw2LnOTd8VvQ3oT8sXQ>:last-child{margin-right:calc(var(--spacing-base)*2)}.qazuloIt0teplSEwxRN0{background-color:#fff;border:1px solid var(--jp-gray);border-bottom:none;color:var(--jp-gray-50);display:grid;grid-template-columns:repeat(9,1fr);padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);width:100%}.qazuloIt0teplSEwxRN0>span:first-child{grid-column:1/7}.qazuloIt0teplSEwxRN0>span:not(:first-child){text-align:center}.iJ_biSBRDribuNKX0Zuw{margin:calc(var(--spacing-base)*4) calc(var(--spacing-base)*8);text-align:center}@media(max-width:599px){.uym7dGHhp6ifjF57yOAO{margin-bottom:calc(var(--spacing-base)*3)}.e_2eFTR8RyHwmfeqJL4F{display:none}.pkw2LnOTd8VvQ3oT8sXQ{justify-content:center}.pkw2LnOTd8VvQ3oT8sXQ>*{width:50%}}.v640YfEL85A9rCvyHSzW{align-items:center;display:flex;gap:4px;justify-content:center;margin-bottom:calc(var(--spacing-base)*2);margin-top:calc(var(--spacing-base)*4)}.v640YfEL85A9rCvyHSzW button{font-size:var(--font-body);height:auto;line-height:32px;min-width:32px;padding:0 var(--spacing-base);width:auto}.v640YfEL85A9rCvyHSzW button.gfxpe4zp6ShFsIsce8Ii,.v640YfEL85A9rCvyHSzW button.gfxpe4zp6ShFsIsce8Ii:hover:not(:disabled){background:none;color:var(--jp-black)}.x8UuVEhWucPfdq0hEJg6{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius)}.x8UuVEhWucPfdq0hEJg6>:not(:last-child){border-bottom:1px solid var(--jp-gray)}.eb6Ovfvm1yONz4mdOwbH{background-color:var(--jp-white)}.jF9LXpXR3TxZVDw7TVXT{align-items:center;background:none;border:none;box-sizing:border-box;cursor:pointer;display:grid;grid-template-columns:repeat(9,1fr);margin:0;outline-color:var(--jp-black);padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);text-align:start;width:100%}.jF9LXpXR3TxZVDw7TVXT>:first-of-type{grid-column:1/8}.jF9LXpXR3TxZVDw7TVXT>:last-of-type{grid-column:9}.jF9LXpXR3TxZVDw7TVXT:hover{background:var(--jp-gray-0)}.lNQgAfpwdAUSOLZd8dlD{align-items:center;display:flex;font-size:var(--font-body-small);font-weight:400}.WRQwDYPdffWznX158azR{margin-left:var(--spacing-base)}.dJx9pvlYjDnKn11n5wo8{font-weight:600;margin-bottom:var(--spacing-base);margin-right:calc(var(--spacing-base)*4)}.EKcbLuSblRc7UpzgsFXw{align-items:center}.ILMBWlMLcXc0n97IisrG{overflow:hidden;transform-origin:top center}.T8XIzCNJBQy1UETN5gjU{max-height:0;padding:0;transform:scaleY(0);transition:all .1s}.kWoHGiaZSbq9XJVyUOMC{max-height:1000px;padding:calc(var(--spacing-base)*4) calc(var(--spacing-base)*7);transform:scaleY(1);transition:max-height .3s,transform .2s}.HQgjxePFDRJHamBAGcVU{background-color:var(--jp-white);border-radius:var(--jp-border-radius);box-shadow:0 0 40px #00000014;margin:0}.KtdsNIMumOoHNWMLmuAJ{align-items:center;display:flex;justify-content:space-between;margin:0;padding:calc(var(--spacing-base)*2);text-align:right}.KtdsNIMumOoHNWMLmuAJ.ewyV4ZGn34WDNXmK3ej2{cursor:pointer;outline-color:var(--jp-black)}.KtdsNIMumOoHNWMLmuAJ.ewyV4ZGn34WDNXmK3ej2:focus:not(.owofT85W_XvVdb5vr1GN),.KtdsNIMumOoHNWMLmuAJ.ewyV4ZGn34WDNXmK3ej2:hover:not(.owofT85W_XvVdb5vr1GN){background-color:var(--jp-gray-0)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN{background-color:var(--jp-black)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN .NESnw2xCLrBpP6WlYZL4{color:var(--jp-white)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN .aohnd_y_1lrMuww8NH63{fill:var(--jp-white)}.KtdsNIMumOoHNWMLmuAJ.owofT85W_XvVdb5vr1GN .Rnas_2_2_eLZSYfZ347E{background-color:var(--jp-red);border:1px solid var(--jp-red);color:var(--jp-white)}.NESnw2xCLrBpP6WlYZL4{align-items:center;display:flex;overflow-x:hidden;padding-left:var(--spacing-base)}.m4_14yNRByDyO9yf9pGg{display:block;overflow-x:hidden;text-overflow:ellipsis}.aohnd_y_1lrMuww8NH63{margin-left:calc(var(--spacing-base)*2)}.Rnas_2_2_eLZSYfZ347E{align-items:center;border:1px solid var(--jp-red-60);border-radius:50%;box-sizing:border-box;color:var(--jp-red-60);display:flex;justify-content:center;min-width:30px;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.X8NRHUTBa_4wDvoHN9TT{fill:var(--jp-green-50)}.CsuOteurQlJm4IjXqyZ0{fill:var(--jp-gray-20)}.fvbewglUxEvV1o04yzzp{--icon-size:28px;--item-spacing:calc(var( --spacing-base )*2);--left-spacing:calc(var( --icon-size ) + var( --item-spacing ));list-style:none}.DINy59MKjwiQanaoDTiV{padding:calc(var(--spacing-base)*2)}.XoacHJljw8zRW_fkBSyg{padding:0}.mXM4WZRePVTa07dhQ6MD{margin-right:var(--left-spacing)}.sI3V8khLdCqxkhJQ_XnI{display:flex;justify-content:flex-start;padding:calc(var(--spacing-base)*2)}.hgdxMuIvZwTZ0sfXaols{padding:calc(var(--spacing-base)*2);width:250px}.UErHS2HAh1gszGfYuVIf{align-items:center;background-color:var(--jp-white);border:1px solid var(--jp-gray-10);border-radius:var(--jp-border-radius);display:flex;justify-content:space-between;padding:calc(var(--spacing-base)*2);width:100%}.lEhH1hvCcxLVFMHI8Gwv{display:flex;justify-content:flex-start}.c57Vj4QhAHwcK_HZMxtN{margin-left:var(--spacing-base)}.sfXsfklfkeSRtE9ivQwF{border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);display:inline-block;width:100%}.sfXsfklfkeSRtE9ivQwF>:not(:last-child){border-bottom:1px solid var(--jp-gray)}.ozRrKPlj1QFGUyd3oVke{background-color:var(--jp-white)}.PyvnSHQuuUkZvVsArigy{align-items:center;background:none;border:none;box-sizing:border-box;cursor:pointer;display:grid;grid-template-columns:repeat(9,1fr);margin:0;outline-color:var(--jp-black);padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);text-align:start;width:100%}.PyvnSHQuuUkZvVsArigy>:first-of-type{grid-column:1/7}.PyvnSHQuuUkZvVsArigy>:last-of-type{grid-column:9}.PyvnSHQuuUkZvVsArigy>:not(:first-child){margin:auto}.PyvnSHQuuUkZvVsArigy:hover{background:var(--jp-gray-0)}.u9Xod5s8bCRNj9MR1Drl{align-items:center;display:flex;font-size:var(--font-body-small);font-weight:400}.IbeyulkpO9kjYJ4OkYUD{margin-left:var(--spacing-base)}.KiCgmjHm2f0JDU3cMsgf{font-weight:600}.KiCgmjHm2f0JDU3cMsgf,.kh5zuLR1zNf7KCsxhAZ5{margin-bottom:var(--spacing-base);margin-right:calc(var(--spacing-base)*4)}.kh5zuLR1zNf7KCsxhAZ5{font-size:var(--font-body-small);font-weight:400}.z1z63g62c73XbcPk9DWc{background-color:var(--jp-gray-50);display:inline-block;height:4px;margin:2px 12px;width:4px}.kJ8t3FAtd5VAYjk31SfA{align-items:center}.JP0IJZcYRohfgntEozjm{overflow:hidden;transform-origin:top center}.y7c6zi2wjEnbW3F29fmP{max-height:0;padding:0;transform:scaleY(0);transition:all .1s}.wQWiN_J0SqgduvadyGnm{max-height:1000px;padding:calc(var(--spacing-base)*4) calc(var(--spacing-base)*7);transform:scaleY(1);transition:max-height .3s,transform .2s}.v1fUFCBPmd6miSCf_ehK{fill:var(--jp-green-40)}.oR9QG6gRLvyzqiuIarmu{border-radius:32px;flex-shrink:0;font-size:12px;font-style:normal;font-weight:600;line-height:16px;margin-right:calc(var(--spacing-base)*4);padding:calc(var(--spacing-base)/2);position:relative;text-align:center;width:60px}.oR9QG6gRLvyzqiuIarmu.bZ8KDXMWoim85Zv31E7E{background-color:#008a20;color:var(--jp-white)}.oR9QG6gRLvyzqiuIarmu.uYEkrN4rh8n5cs3aPrYC{background-color:var(--jp-gray-50);color:var(--jp-white)}.WOX88CWB12lzxcMcl_ns{color:#008a20}.H2J5mHqyiBHXCAyZ4KGa{color:inherit}.H2J5mHqyiBHXCAyZ4KGa:focus,.H2J5mHqyiBHXCAyZ4KGa:hover{box-shadow:none;color:inherit}.BT16ByfO8ktYf15hbMG8{margin-right:calc(var(--spacing-base)/2);max-height:20px}.Gi6geVLkEyrClNXuJ34I{color:var(--jp-red)}.Q02oRBdY3ZpNGOF2Y1iV{color:var(--jp-gray-70);font-weight:400;line-height:24px}@media(max-width:599px){.PyvnSHQuuUkZvVsArigy{display:grid;grid-auto-rows:minmax(auto,auto)}.PyvnSHQuuUkZvVsArigy>:first-child{grid-column:1/8;grid-row:1}.PyvnSHQuuUkZvVsArigy>:nth-child(2){grid-row:2;padding-right:calc(var(--spacing-base)*4)}.PyvnSHQuuUkZvVsArigy>:nth-child(3){grid-row:2}.PyvnSHQuuUkZvVsArigy>:nth-child(3) span{margin-top:var(--spacing-base);position:absolute}.PyvnSHQuuUkZvVsArigy>:last-child{grid-column:10;grid-row:1/3}.oR9QG6gRLvyzqiuIarmu{display:none}}@media(max-width:1200px){.kh5zuLR1zNf7KCsxhAZ5{display:grid}.z1z63g62c73XbcPk9DWc{display:none}}.SunkAzopVEoBZbCUFkpe{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:monospace;overflow-x:auto;padding:0}.s6eJjt_RVhQ8mEG1qQYb{background-color:var(--jp-red-0)}.cW2860S1RCjdsufX8ds_{display:flex;flex-direction:column;text-align:left}.hU_xmjv3sGJgIvV_26Ik{background-color:var(--jp-gray-10);color:var(--font-body);padding:0 calc(var(--spacing-base)/2)}.hU_xmjv3sGJgIvV_26Ik.s6eJjt_RVhQ8mEG1qQYb{background-color:var(--jp-red-50);color:var(--jp-white)}.O5ZaHoo1pFRkk_GUUczG{display:flex;flex:1;flex-direction:column;overflow-x:visible;white-space:pre}.UoS_E4HwI88HfDMpNtvB{padding-right:var(--spacing-base)}.ZotWIwUISq6XCpIyD8k7{background-color:var(--jp-red);border-radius:calc(var(--jp-border-radius)/2);color:var(--jp-white);padding:calc(var(--spacing-base)/4) calc(var(--spacing-base)/2)}.HPsJA6B0f3Bd2tZgEr7v{font-size:var(--font-body);line-height:1.5}.WA0OogO0bZSYbqUPL9aa{background-color:var(--jp-gray-10);font-weight:600;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.Z1NxA7aDh5LEYjbLLKbF{background-color:var(--jp-gray-0);display:flex;flex-direction:row;font-family:Courier\ 10 Pitch,Courier,monospace;overflow-x:auto;white-space:pre}.aeQS3Qb4g1FwDY0HaZKb{background-color:var(--jp-gray-10);color:var(--jp-gray-50);display:flex;flex-direction:column;padding:0 var(--spacing-base);text-align:left}.ESXyHLdGmRLZMv7_Ei9d{display:flex;flex-direction:column;flex-grow:1;overflow-x:visible}.ESXyHLdGmRLZMv7_Ei9d del,.ESXyHLdGmRLZMv7_Ei9d div,.ESXyHLdGmRLZMv7_Ei9d ins{padding:0 var(--spacing-base);text-decoration:none}.ESXyHLdGmRLZMv7_Ei9d del{background-color:var(--jp-red-0);color:var(--jp-red-60)}.ESXyHLdGmRLZMv7_Ei9d ins{background-color:var(--jp-green-5);color:var(--jp-green-60)}.XqQBRzrxyMhhZvPXIHgk .components-button{box-shadow:inset 0 0 0 1.5px var(--jp-gray);position:relative}.XqQBRzrxyMhhZvPXIHgk .components-button:first-child{border-radius:0 var(--jp-border-radius) var(--jp-border-radius) 0}.XqQBRzrxyMhhZvPXIHgk .components-button:last-child{border-radius:var(--jp-border-radius) 0 0 var(--jp-border-radius)}.XqQBRzrxyMhhZvPXIHgk .components-button:hover{z-index:1}.XqQBRzrxyMhhZvPXIHgk .components-button+.components-button{margin-right:-1.5px}.iN9oF7KagtrwaFKTquqW{align-items:center;display:flex}.IZTexE5bnJrB25jtwXBW{height:54px;width:54px;fill:var(--jp-red);margin-left:var(--spacing-base);margin-right:-8px}.YzqaprEdVpBoBJesZixw{margin-top:calc(var(--spacing-base)*3)}.AMcxtVDLtWB2EJJJU5NQ{height:auto;max-width:100%;position:relative;width:330px}.vtViVIQmuI1n8HDxrkNy{animation:BJ0WjZD0MlRR_Usu8HEd 4s ease-in-out .8s infinite normal forwards;opacity:0;position:relative;transform:translateY(24px)}.vtViVIQmuI1n8HDxrkNy:nth-of-type(2){animation-delay:.6s}.vtViVIQmuI1n8HDxrkNy:nth-of-type(3){animation-delay:.7s}@keyframes BJ0WjZD0MlRR_Usu8HEd{0%{opacity:0;transform:translateY(24px)}20%{opacity:1;transform:translateY(0)}50%{opacity:1;transform:translateY(0)}60%{opacity:0;transform:translateY(-48px)}to{opacity:0;transform:translateY(-48px)}}@media(prefers-reduced-motion:reduce){.vtViVIQmuI1n8HDxrkNy{animation:none}}.vzMlFr1AXWqefpRrb976{align-items:center;display:flex;justify-content:space-between;margin-bottom:calc(var(--spacing-base)*2)}.gYSOMa4xxLXmsNzvFPkW{background-color:var(--jp-gray-5);border-radius:calc(var(--spacing-base)*3);width:100%}.hNJWdt5qmZkWYAH_vjIp{background-color:var(--jp-green-40);border-radius:calc(var(--spacing-base)*3);height:9px;transition:width .2s}.DHMUfGyHbl5BgD5vjxVz{color:var(--jp-gray-90);font-weight:600;line-height:24px;margin-right:auto;padding-right:var(--spacing-base)}.cAbGtJDGgLubucBnz7vM{background-color:var(--jp-white)}.KmIjHqrMs3duMPaUf50k{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;max-height:600px;width:100%}.bpW3MfTt3siOyvw1ZsuF{font-weight:700}.DJS67UCXVaM7nIMJePYQ{align-items:flex-end;display:flex;justify-content:flex-end;margin-bottom:calc(var(--spacing-base)*2.25)}.s4378tf2MiM0bMIxQZkI{flex:1;margin-bottom:0}.jifq7nsF5kZYrcpGQ35V{display:flex;gap:calc(var(--spacing-base)*2)}@media(max-width:599px){.DJS67UCXVaM7nIMJePYQ{margin-bottom:calc(var(--spacing-base)*3)}.s4378tf2MiM0bMIxQZkI{display:none}}.yjKVIZH3KLvJeygIzaZn{margin-top:calc(var(--spacing-base)*3)}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50);text-decoration:underline;white-space:nowrap}.p4qz2tkq0p9hxucJ6Qk2{--padding:calc(var(--spacing-base)*4);color:var(--jp-black)}.lbNDyXioOwvyvbALtCBm{--gap:calc(var(--spacing-base)*3);padding:var(--padding) 0;position:relative}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm{column-gap:var(--gap);display:grid;grid-auto-flow:column;grid-template-columns:repeat(var(--columns),1fr);grid-template-rows:repeat(var(--rows),minmax(min-content,max-content))}.cLaNK_XcbTGlRQ4Tp43Q{margin-top:var(--padding)}.s2Lsn4kbm6BrS3DSndRB .cLaNK_XcbTGlRQ4Tp43Q{display:contents}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>*{background:var(--jp-white);position:relative}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>:after{bottom:0;box-shadow:0 4px 24px #0000000d;content:"";left:0;position:absolute;right:0;top:0;z-index:-1}.cLaNK_XcbTGlRQ4Tp43Q>:first-child{border-top-left-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius);border-width:1px 1px 0}.cLaNK_XcbTGlRQ4Tp43Q>:last-child{border-bottom-left-radius:var(--jp-border-radius);border-bottom-right-radius:var(--jp-border-radius);border-width:0 1px 1px}.DAkZc1P9A3K12fjEliMg{display:flex;flex-direction:column;justify-content:space-between;padding:var(--padding)}.WUBuYABl8nymjs9NnCEL{align-items:center;display:flex;padding-bottom:calc(var(--spacing-base)*2);position:relative}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)){padding-top:calc(var(--spacing-base)*2)}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{background-color:var(--jp-gray);content:"";height:1px;left:var(--padding);position:absolute;right:var(--padding);top:0;z-index:5}.s2Lsn4kbm6BrS3DSndRB .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{left:unset;right:0;width:calc(100% + var(--gap))}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm>:last-child .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{width:100%}.ANtCFeb41NhA8PA3H7ZN,.WUBuYABl8nymjs9NnCEL:last-of-type{padding-bottom:var(--padding)}.Ql2gy_148yW8Vw5vhaKD{padding-left:var(--padding);padding-right:var(--padding)}.EAQrAnQEW1z1BfdY5gbC{margin:0 var(--spacing-base);fill:var(--jp-gray);flex-shrink:0}.EAQrAnQEW1z1BfdY5gbC.JDSTlLoOC_4aUoH2oNM2{fill:var(--jp-green-40)}.EAQrAnQEW1z1BfdY5gbC.zNdQRJ1w7BvaQOYyqzHK{fill:var(--jp-red-50)}.lr7vbX95SKtoe7DarJcZ{margin-right:auto}.s2Lsn4kbm6BrS3DSndRB .lr7vbX95SKtoe7DarJcZ{margin:0 var(--spacing-base);top:1px}.WUBuYABl8nymjs9NnCEL .KRrGp2xdkeBOxLZeuQ6X{fill:var(--jp-gray-20);flex-shrink:0}.H_ZJiRVJg0LiMXPGOcmt{text-align:center;width:fit-content}.H_ZJiRVJg0LiMXPGOcmt>a{color:#000}.s2Lsn4kbm6BrS3DSndRB .H_ZJiRVJg0LiMXPGOcmt{grid-column:2;overflow:hidden;padding-left:var(--padding);padding-right:var(--padding);white-space:nowrap}.x21z_DixObRDsDaWotP1{align-items:right;display:flex;justify-content:right;margin:0 calc(var(--spacing-base)*4)}.dovianZYLKhnbnh9I06o{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-end}.lljtQMhW7lq5tE5SDJEf{align-items:flex-start;display:flex;flex-basis:0;flex-grow:2}.lljtQMhW7lq5tE5SDJEf .NubApIV1vQCRUNprfm6b{margin-right:auto}.dhFQXpZfMwVI8vuYHnwC{align-items:flex-start;display:inline-flex;flex:0 0 auto;position:relative}.dhFQXpZfMwVI8vuYHnwC:first-child{margin-left:calc(var(--spacing-base)*2)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k{color:var(--jp-gray-20)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k:after{background:var(--jp-red);border-radius:var(--jp-border-radius);content:" ";display:block;height:3px;margin-top:-2px;pointer-events:none;position:absolute;top:50%;width:100%}.C64ZjjUAqJC1T2Sa7apS{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-start;margin-bottom:calc(var(--spacing-base)*3)}.UpZDGew6Ay1hPoP6eI7b{color:var(--jp-gray-40);font-size:var(--font-body-small);line-height:20px}.UpZDGew6Ay1hPoP6eI7b:after{content:"​"}.NubApIV1vQCRUNprfm6b{background-color:var(--jp-yellow-10);border-radius:4px;font-size:13px;font-weight:600;margin-right:var(--spacing-base);padding-left:var(--spacing-base);padding-right:var(--spacing-base)}.TDiiPbuW1Z0_05u_pvcK{font-weight:400}.T1f6nRmWifz5im6hB29M{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;width:100%}.Ki7ehROrWxWBIMIt8SUH:focus:not(:disabled){box-shadow:none}*{box-sizing:border-box}#jetpack-protect-root{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);--wp-admin-border-width-focus:1.51px;--actions-size:28px} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/composer.json deleted file mode 100644 index 7a752c8f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/composer.json +++ /dev/null @@ -1,77 +0,0 @@ -{ - "name": "automattic/jetpack-protect", - "description": "Social plugin", - "type": "wordpress-plugin", - "license": "GPL-2.0-or-later", - "require": { - "ext-json": "*", - "automattic/jetpack-assets": "^4.0.14", - "automattic/jetpack-admin-ui": "^0.5.7", - "automattic/jetpack-autoloader": "^5.0.5", - "automattic/jetpack-composer-plugin": "^4.0.4", - "automattic/jetpack-config": "^3.0.1", - "automattic/jetpack-my-jetpack": "^5.9.1", - "automattic/jetpack-plugins-installer": "^0.5.4", - "automattic/jetpack-sync": "^4.9.2", - "automattic/jetpack-transport-helper": "^0.3.1", - "automattic/jetpack-plans": "^0.6.1", - "automattic/jetpack-waf": "^0.23.8", - "automattic/jetpack-status": "^5.0.10", - "automattic/jetpack-protect-status": "^0.5.8" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ], - "build-development": [ - "pnpm run build" - ], - "build-production": [ - "pnpm run build-production-concurrently" - ], - "watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run watch" - ] - }, - "repositories": [], - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "mirror-repo": "Automattic/jetpack-protect-plugin", - "autorelease": true, - "autotagger": { - "v": false - }, - "release-branch-prefix": "protect", - "wp-plugin-slug": "jetpack-protect", - "wp-svn-autopublish": true, - "version-constants": { - "JETPACK_PROTECT_VERSION": "jetpack-protect.php" - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true, - "automattic/jetpack-autoloader": true, - "automattic/jetpack-composer-plugin": true - }, - "autoloader-suffix": "c4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ4_0_0" - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack-protect.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack-protect.php deleted file mode 100644 index ccfa93b8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack-protect.php +++ /dev/null @@ -1,140 +0,0 @@ - array( - 'plugin' => 'Jetpack Protect', - ), - ); - - return $slugs; - } - ); - - add_action( - 'admin_notices', - function () { - if ( get_current_screen()->id !== 'plugins' ) { - return; - } - - $message = sprintf( - wp_kses( - /* translators: Placeholder is a link to a support document. */ - __( 'Your installation of Jetpack Protect is incomplete. If you installed Jetpack Protect from GitHub, please refer to this document to set up your development environment. Jetpack Protect must have Composer dependencies installed and built via the build command.', 'jetpack-protect' ), - array( - 'a' => array( - 'href' => array(), - 'target' => array(), - 'rel' => array(), - ), - ) - ), - 'https://github.com/Automattic/jetpack/blob/trunk/docs/development-environment.md#building-your-project' - ); - wp_admin_notice( - $message, - array( - 'type' => 'error', - 'dismissible' => true, - ) - ); - } - ); - - return; -} - -// Redirect to plugin page when the plugin is activated. -add_action( 'activated_plugin', 'jetpack_protect_plugin_activation' ); - -/** - * Redirects to plugin page when the plugin is activated - * - * @param string $plugin Path to the plugin file relative to the plugins directory. - */ -function jetpack_protect_plugin_activation( $plugin ) { - if ( - JETPACK_PROTECT_ROOT_FILE_RELATIVE_PATH === $plugin && - ( new \Automattic\Jetpack\Paths() )->is_current_request_activating_plugin_from_plugins_screen( JETPACK_PROTECT_ROOT_FILE_RELATIVE_PATH ) - ) { - wp_safe_redirect( esc_url( admin_url( 'admin.php?page=jetpack-protect' ) ) ); - exit( 0 ); - } -} - -// Add "Settings" link to plugins page. -add_filter( - 'plugin_action_links_' . JETPACK_PROTECT_FOLDER . '/jetpack-protect.php', - function ( $actions ) { - $settings_link = '' . __( 'Dashboard', 'jetpack-protect' ) . ''; - array_unshift( $actions, $settings_link ); - - return $actions; - } -); - -register_activation_hook( __FILE__, array( 'Jetpack_Protect', 'plugin_activation' ) ); -register_deactivation_hook( __FILE__, array( 'Jetpack_Protect', 'plugin_deactivation' ) ); - -// Main plugin class. -new Jetpack_Protect(); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/CHANGELOG.md deleted file mode 100644 index 8453869d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/CHANGELOG.md +++ /dev/null @@ -1,206 +0,0 @@ -# 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). - -## [3.0.4] - 2025-03-21 -### Changed -- Internal updates. - -## [3.0.3] - 2025-03-12 -### Changed -- Internal updates. - -## [3.0.2] - 2025-03-05 -### Changed -- Internal updates. - -## [3.0.1] - 2025-02-24 -### Changed -- Update dependencies. - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.0.4] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.0.3] - 2024-09-30 -### Fixed -- Added a check for function presence to avoid fatal errors. [#39581] - -## [2.0.2] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [2.0.1] - 2024-03-12 -### Changed -- Internal updates. - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.4.22] - 2023-09-19 - -- Minor internal updates. - -## [1.4.21] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.4.20] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.4.19] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.4.18] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.4.17] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.4.16] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.4.15] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.4.14] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.4.13] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.4.12] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.4.11] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.4.10] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.4.9] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.4.8] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.4.7] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.4.6] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.4.5] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- updated annotations versions - -## [1.4.4] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.4.3] - 2021-04-08 -### Changed -- Packaging and build changes, no change to the package itself. - -## [1.4.2] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.4.1] - 2021-02-05 - -- CI: Make tests more generic - -## [1.4.0] - 2021-01-20 - -- Add mirror-repo information to all current composer packages - -## [1.3.0] - 2020-12-17 - -- Coverage Update whitelist for backend tests -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.2.0] - 2020-09-17 - -## [1.1.1] - 2020-09-17 - -- a8c-mc-stats: Do not distribute test files - -## [1.1.0] - 2020-08-13 - -- CI: Try collect js coverage - -## 1.0.0 - 2020-07-27 - -- Creates the MC Stats package - -[3.0.4]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v2.0.4...v3.0.0 -[2.0.4]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.22...v2.0.0 -[1.4.22]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.21...v1.4.22 -[1.4.21]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.20...v1.4.21 -[1.4.20]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.19...v1.4.20 -[1.4.19]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.18...v1.4.19 -[1.4.18]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.17...v1.4.18 -[1.4.17]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.16...v1.4.17 -[1.4.16]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.15...v1.4.16 -[1.4.15]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.14...v1.4.15 -[1.4.14]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.13...v1.4.14 -[1.4.13]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.12...v1.4.13 -[1.4.12]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.11...v1.4.12 -[1.4.11]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.10...v1.4.11 -[1.4.10]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.9...v1.4.10 -[1.4.9]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.8...v1.4.9 -[1.4.8]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.7...v1.4.8 -[1.4.7]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.6...v1.4.7 -[1.4.6]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.5...v1.4.6 -[1.4.5]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.4...v1.4.5 -[1.4.4]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.3...v1.4.4 -[1.4.3]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.2...v1.4.3 -[1.4.2]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.1...v1.4.2 -[1.4.1]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.4.0...v1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.1.1...v1.2.0 -[1.1.1]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v1.0.0...v1.1.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/composer.json deleted file mode 100644 index 702dd274..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/composer.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "name": "automattic/jetpack-a8c-mc-stats", - "description": "Used to record internal usage stats for Automattic. Not visible to site owners.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-a8c-mc-stats", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/src/class-a8c-mc-stats.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/src/class-a8c-mc-stats.php deleted file mode 100644 index 53ab5618..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-a8c-mc-stats/src/class-a8c-mc-stats.php +++ /dev/null @@ -1,182 +0,0 @@ -use_transparent_pixel = $use_transparent_pixel; - } - - /** - * Store a stat for later output. - * - * @param string $group The stat group. - * @param string $name The stat name to bump. - * - * @return boolean true if stat successfully added - */ - public function add( $group, $name ) { - - if ( ! \is_string( $group ) || ! \is_string( $name ) ) { - return false; - } - - if ( ! isset( $this->stats[ $group ] ) ) { - $this->stats[ $group ] = array(); - } - - if ( \in_array( $name, $this->stats[ $group ], true ) ) { - return false; - } - - $this->stats[ $group ][] = $name; - - return true; - } - - /** - * Gets current stats stored to be processed - * - * @return array $stats - */ - public function get_current_stats() { - return $this->stats; - } - - /** - * Return the stats from a group in an array ready to be added as parameters in a query string - * - * @param string $group_name The name of the group to retrieve. - * @return array Array with one item, where the key is the prefixed group and the value are all stats concatenated with a comma. If group not found, an empty array will be returned - */ - public function get_group_query_args( $group_name ) { - $stats = $this->get_current_stats(); - if ( isset( $stats[ $group_name ] ) && ! empty( $stats[ $group_name ] ) ) { - return array( "x_jetpack-{$group_name}" => implode( ',', $stats[ $group_name ] ) ); - } - return array(); - } - - /** - * Gets a list of trac URLs for every stored URL - * - * @return array An array of URLs - */ - public function get_stats_urls() { - - $urls = array(); - - foreach ( $this->get_current_stats() as $group => $stat ) { - $group_query_string = $this->get_group_query_args( $group ); - $urls[] = $this->build_stats_url( $group_query_string ); - } - - return $urls; - } - - /** - * Outputs the tracking pixels for the current stats and empty the stored stats from the object - * - * @return void - */ - public function do_stats() { - $urls = $this->get_stats_urls(); - foreach ( $urls as $url ) { - echo ''; - } - $this->stats = array(); - } - - /** - * Pings the stats server for the current stats and empty the stored stats from the object - * - * @return void - */ - public function do_server_side_stats() { - $urls = $this->get_stats_urls(); - foreach ( $urls as $url ) { - $this->do_server_side_stat( $url ); - } - $this->stats = array(); - } - - /** - * Runs stats code for a one-off, server-side. - * - * @param string $url string The URL to be pinged. Should include `x_jetpack-{$group}={$stats}` or whatever we want to store. - * - * @return bool If it worked. - */ - public function do_server_side_stat( $url ) { - $response = wp_remote_get( esc_url_raw( $url ) ); - if ( is_wp_error( $response ) ) { - return false; - } - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - return false; - } - - return true; - } - - /** - * Builds the stats url. - * - * @param array $args array|string The arguments to append to the URL. - * - * @return string The URL to be pinged. - */ - public function build_stats_url( $args ) { - $defaults = array( - 'v' => 'wpcom2', - // phpcs:ignore WordPress.WP.AlternativeFunctions.rand_rand -- There can be a case where pluggables are not yet loaded. - 'rand' => md5( ( function_exists( 'wp_rand' ) ? wp_rand( 0, 999 ) : rand( 0, 999 ) ) . time() ), - ); - $args = wp_parse_args( $args, $defaults ); - $gifname = true === $this->use_transparent_pixel ? 'b.gif' : 'g.gif'; - - /** - * Filter the URL used as the Stats tracking pixel. - * - * @since-jetpack 2.3.2 - * @since 1.0.0 - * - * @param string $url Base URL used as the Stats tracking pixel. - */ - $base_url = apply_filters( - 'jetpack_stats_base_url', - 'https://pixel.wp.com/' . $gifname - ); - $url = add_query_arg( $args, $base_url ); - return $url; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/CHANGELOG.md deleted file mode 100644 index b3e636ab..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/CHANGELOG.md +++ /dev/null @@ -1,243 +0,0 @@ -# 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). - -## [0.5.7] - 2025-03-21 -### Changed -- Internal updates. - -## [0.5.6] - 2025-03-17 -### Changed -- Internal updates. - -## [0.5.5] - 2025-03-12 -### Changed -- Internal updates. - -## [0.5.4] - 2025-03-05 -### Changed -- Internal updates. - -## [0.5.3] - 2025-02-24 -### Changed -- Update dependencies. - -## [0.5.2] - 2025-02-03 -### Added -- Add `remove_menu` method to `Admin_Menu` class. [#41422] - -## [0.5.1] - 2024-11-25 -### Changed -- Update dependencies. [#40286] - -## [0.5.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.4.6] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [0.4.5] - 2024-09-05 -### Changed -- Jetpack menu: only register Jetpack admin page for contributor roles and above. [#39081] - -## [0.4.4] - 2024-08-29 -### Changed -- Admin menu: change order of Jetpack sub-menu items [#39095] - -## [0.4.3] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [0.4.2] - 2024-04-22 -### Changed -- Internal updates. - -## [0.4.1] - 2024-03-12 -### Changed -- Internal updates. - -## [0.4.0] - 2024-03-01 -### Added -- Register menus in network admin as well as regular admin. [#36058] - -## [0.3.2] - 2024-01-29 -### Fixed -- Wait until 'admin_menu' action to call `add_menu()`, to avoid triggering the l10n load too early. [#35279] - -## [0.3.1] - 2023-11-24 - -## [0.3.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [0.2.25] - 2023-11-14 - -## [0.2.24] - 2023-10-30 -### Fixed -- Handle Akismet submenu even if Jetpack is present, as Jetpack now relies on this package to do so. [#33559] - -## [0.2.23] - 2023-09-19 -### Changed -- Updated Jetpack submenu sort order so individual features are alpha-sorted. [#32958] - -## [0.2.22] - 2023-09-11 -### Fixed -- Akismet: update naming to common form [#32908] - -## [0.2.21] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [0.2.20] - 2023-04-25 -### Fixed -- Avoid errors when used in combination with an older version of the Logo package. [#30136] - -## [0.2.19] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.2.18] - 2023-04-04 -### Changed -- Menu icon: update to latest version of the Jetpack logo [#29418] - -## [0.2.17] - 2023-02-20 -### Changed -- Minor internal updates. - -## [0.2.16] - 2023-01-25 -### Changed -- Minor internal updates. - -## [0.2.15] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [0.2.14] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [0.2.13] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [0.2.12] - 2022-09-20 -### Changed -- Updated package dependencies. - -## [0.2.11] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [0.2.10] - 2022-07-12 -### Changed -- Updated package dependencies. - -## [0.2.9] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [0.2.8] - 2022-06-14 -### Changed -- Updated package dependencies. - -## [0.2.7] - 2022-04-26 -### Changed -- Update package.json metadata. - -## [0.2.6] - 2022-04-05 -### Changed -- Updated package dependencies. - -## [0.2.5] - 2022-03-08 -### Fixed -- Do not handle Akismet submenu if Jetpack plugin is present - -## [0.2.4] - 2022-02-09 -### Added -- Support for akismet menu with stand-alone plugins - -### Fixed -- Fixes menu order working around a bug in add_submenu_page - -## [0.2.3] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [0.2.2] - 2022-01-18 -### Changed -- General: update required node version to v16.13.2 - -## [0.2.1] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [0.2.0] - 2021-12-14 -### Added -- New method to get the top level menu item - -## [0.1.1] - 2021-11-17 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## 0.1.0 - 2021-10-13 -### Added -- Created the package. - -### Changed -- Updated package dependencies. - -### Fixed -- Fixing menu visibility issues. - -[0.5.7]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.6...0.5.7 -[0.5.6]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.5...0.5.6 -[0.5.5]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.4...0.5.5 -[0.5.4]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.3...0.5.4 -[0.5.3]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.2...0.5.3 -[0.5.2]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.1...0.5.2 -[0.5.1]: https://github.com/Automattic/jetpack-admin-ui/compare/0.5.0...0.5.1 -[0.5.0]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.6...0.5.0 -[0.4.6]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.5...0.4.6 -[0.4.5]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.4...0.4.5 -[0.4.4]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.3...0.4.4 -[0.4.3]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.2...0.4.3 -[0.4.2]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.1...0.4.2 -[0.4.1]: https://github.com/Automattic/jetpack-admin-ui/compare/0.4.0...0.4.1 -[0.4.0]: https://github.com/Automattic/jetpack-admin-ui/compare/0.3.2...0.4.0 -[0.3.2]: https://github.com/Automattic/jetpack-admin-ui/compare/0.3.1...0.3.2 -[0.3.1]: https://github.com/Automattic/jetpack-admin-ui/compare/0.3.0...0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.25...0.3.0 -[0.2.25]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.24...0.2.25 -[0.2.24]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.23...0.2.24 -[0.2.23]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.22...0.2.23 -[0.2.22]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.21...0.2.22 -[0.2.21]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.20...0.2.21 -[0.2.20]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.19...0.2.20 -[0.2.19]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.18...0.2.19 -[0.2.18]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.17...0.2.18 -[0.2.17]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.16...0.2.17 -[0.2.16]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.15...0.2.16 -[0.2.15]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.14...0.2.15 -[0.2.14]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.13...0.2.14 -[0.2.13]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.12...0.2.13 -[0.2.12]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.11...0.2.12 -[0.2.11]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.10...0.2.11 -[0.2.10]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.9...0.2.10 -[0.2.9]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.8...0.2.9 -[0.2.8]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.7...0.2.8 -[0.2.7]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.6...0.2.7 -[0.2.6]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.5...0.2.6 -[0.2.5]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.4...0.2.5 -[0.2.4]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.3...0.2.4 -[0.2.3]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.2...0.2.3 -[0.2.2]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.1...0.2.2 -[0.2.1]: https://github.com/Automattic/jetpack-admin-ui/compare/0.2.0...0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-admin-ui/compare/0.1.1...0.2.0 -[0.1.1]: https://github.com/Automattic/jetpack-admin-ui/compare/0.1.0...0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/composer.json deleted file mode 100644 index d8abc675..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/composer.json +++ /dev/null @@ -1,56 +0,0 @@ -{ - "name": "automattic/jetpack-admin-ui", - "description": "Generic Jetpack wp-admin UI elements", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-logo": "^3.0.4", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-admin-ui", - "textdomain": "jetpack-admin-ui", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-admin-ui/compare/${old}...${new}" - }, - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-admin-menu.php" - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php deleted file mode 100644 index e9d402d3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php +++ /dev/null @@ -1,228 +0,0 @@ -get_base64_logo() - : 'dashicons-admin-plugins'; - - if ( ! $jetpack_plugin_present ) { - add_menu_page( - 'Jetpack', - 'Jetpack', - 'edit_posts', - 'jetpack', - '__return_null', - $icon, - 3 - ); - - // If Jetpack plugin is not present, user will only be able to see this menu if they have enough capability to at least one of the sub menus being added. - $can_see_toplevel_menu = false; - } - - /** - * The add_sub_menu function has a bug and will not keep the right order of menu items. - * - * @see https://core.trac.wordpress.org/ticket/52035 - * Let's order the items before registering them. - * Since this all happens after the Jetpack plugin menu items were added, all items will be added after Jetpack plugin items - unless position is very low number (smaller than the number of menu items present in Jetpack plugin). - */ - usort( - self::$menu_items, - function ( $a, $b ) { - $position_a = empty( $a['position'] ) ? 0 : $a['position']; - $position_b = empty( $b['position'] ) ? 0 : $b['position']; - $result = $position_a <=> $position_b; - - if ( 0 === $result ) { - $result = strcmp( $a['menu_title'], $b['menu_title'] ); - } - - return $result; - } - ); - - foreach ( self::$menu_items as $menu_item ) { - if ( ! current_user_can( $menu_item['capability'] ) ) { - continue; - } - - $can_see_toplevel_menu = true; - - add_submenu_page( - 'jetpack', - $menu_item['page_title'], - $menu_item['menu_title'], - $menu_item['capability'], - $menu_item['menu_slug'], - $menu_item['function'], - $menu_item['position'] - ); - } - - if ( ! $jetpack_plugin_present ) { - remove_submenu_page( 'jetpack', 'jetpack' ); - } - - if ( ! $can_see_toplevel_menu ) { - remove_menu_page( 'jetpack' ); - } - } - - /** - * Adds a new submenu to the Jetpack Top level menu - * - * The parameters this method accepts are the same as @see add_submenu_page. This class will - * aggreagate all menu items registered by stand-alone plugins and make sure they all go under the same - * Jetpack top level menu. It will also handle the top level menu registration in case the Jetpack plugin is not present. - * - * @param string $page_title The text to be displayed in the title tags of the page when the menu - * is selected. - * @param string $menu_title The text to be used for the menu. - * @param string $capability The capability required for this menu to be displayed to the user. - * @param string $menu_slug The slug name to refer to this menu by. Should be unique for this menu - * and only include lowercase alphanumeric, dashes, and underscores characters - * to be compatible with sanitize_key(). - * @param callable $function The function to be called to output the content for this page. - * @param int $position The position in the menu order this item should appear. Leave empty typically. - * - * @return string The resulting page's hook_suffix - */ - public static function add_menu( $page_title, $menu_title, $capability, $menu_slug, $function, $position = null ) { - self::init(); - self::$menu_items[] = compact( 'page_title', 'menu_title', 'capability', 'menu_slug', 'function', 'position' ); - - /** - * Let's return the page hook so consumers can use. - * We know all pages will be under Jetpack top level menu page, so we can hardcode the first part of the string. - * Using get_plugin_page_hookname here won't work because the top level page is not registered yet. - */ - return 'jetpack_page_' . $menu_slug; - } - - /** - * Removes an already added submenu - * - * @param string $menu_slug The slug of the submenu to remove. - * - * @return array|false The removed submenu on success, false if not found. - */ - public static function remove_menu( $menu_slug ) { - - foreach ( self::$menu_items as $index => $menu_item ) { - if ( $menu_item['menu_slug'] === $menu_slug ) { - unset( self::$menu_items[ $index ] ); - - return $menu_item; - } - } - - return false; - } - - /** - * Gets the slug for the first item under the Jetpack top level menu - * - * @return string|null - */ - public static function get_top_level_menu_item_slug() { - global $submenu; - if ( ! empty( $submenu['jetpack'] ) ) { - $item = reset( $submenu['jetpack'] ); - if ( isset( $item[2] ) ) { - return $item[2]; - } - } - } - - /** - * Gets the URL for the first item under the Jetpack top level menu - * - * @param string $fallback If Jetpack menu is not there or no children is found, return this fallback instead. Default to admin_url(). - * @return string - */ - public static function get_top_level_menu_item_url( $fallback = false ) { - $slug = self::get_top_level_menu_item_slug(); - - if ( $slug ) { - $url = menu_page_url( $slug, false ); - return $url; - } - - $url = $fallback ? $fallback : admin_url(); - return $url; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/CHANGELOG.md deleted file mode 100644 index 674e9916..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/CHANGELOG.md +++ /dev/null @@ -1,729 +0,0 @@ -# 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). - -## [4.0.14] - 2025-03-21 -### Changed -- Internal updates. - -## [4.0.13] - 2025-03-18 -### Changed -- Update dependencies. [#42545] - -## [4.0.12] - 2025-03-17 -### Changed -- Internal updates. - -## [4.0.11] - 2025-03-12 -### Changed -- Internal updates. - -## [4.0.10] - 2025-03-05 -### Changed -- Internal updates. - -## [4.0.9] - 2025-03-03 -### Changed -- Update package dependencies. [#42163] - -## [4.0.8] - 2025-02-24 -### Added -- User data: Add permissions to the current user object. [#41859] - -## [4.0.7] - 2025-02-17 -### Changed -- Update dependencies. - -## [4.0.6] - 2025-02-11 -### Changed -- Update dependencies. - -## [4.0.5] - 2025-02-05 -### Changed -- Updated package dependencies. [#41491] - -## [4.0.4] - 2025-02-03 -### Changed -- Updated package dependencies. [#41286] - -## [4.0.3] - 2025-01-20 -### Changed -- Updated package dependencies. [#41099] - -## [4.0.2] - 2024-12-16 -### Changed -- Updated package dependencies. [#40564] - -## [4.0.1] - 2024-12-04 -### Changed -- Updated package dependencies. [#40363] - -## [4.0.0] - 2024-11-25 -### Changed -- Updated package dependencies. [#40258] [#40288] - -### Removed -- Remove JSX runtime polyfill, now that we've dropped support for WordPress < 6.6. [#40200] - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.3.14] - 2024-11-11 -### Changed -- Updated package dependencies. [#39999] - -## [2.3.13] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.3.12] - 2024-10-29 -### Changed -- Internal updates. - -## [2.3.11] - 2024-10-29 -### Fixed -- Fixed the outdated JS build for script-data [#39937] - -## [2.3.10] - 2024-10-10 -### Changed -- Updated package dependencies. - -## [2.3.9] - 2024-10-07 -### Changed -- Updated package dependencies. [#39594] - -## [2.3.8] - 2024-09-10 -### Changed -- Updated package dependencies. [#39302] - -## [2.3.7] - 2024-09-05 -### Changed -- Internal updates. - -## [2.3.6] - 2024-09-05 -### Changed -- Updated package dependencies. [#39176] - -### Fixed -- Fixed script data not available in block editor iframe [#39221] - -## [2.3.5] - 2024-08-29 -### Changed -- Updated package dependencies. [#39111] - -## [2.3.4] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [2.3.3] - 2024-08-21 -### Changed -- i18n loader script & React JSX runtime: load scripts in the footer. [#38929] - -## [2.3.2] - 2024-08-15 -### Changed -- Updated package dependencies. [#38662] - -## [2.3.1] - 2024-08-12 -### Fixed -- Fixed variable names. [#38606] - -## [2.3.0] - 2024-08-08 -### Added -- Added jetpack-initial-state package to consolidate the logic for Initial state. [#38430] - -## [2.2.0] - 2024-07-23 -### Added -- Assets: Add JSX runtime polyfill `react-jsx-runtime` for WordPress < 6.6. [#38428] - -## [2.1.13] - 2024-07-03 -### Changed -- Updated package dependencies. [#38132] - -## [2.1.12] - 2024-06-05 -### Changed -- Updated package dependencies. [#37669] - -## [2.1.11] - 2024-05-20 -### Changed -- Internal updates. - -## [2.1.10] - 2024-05-16 -### Added -- Assets: Adding comments to explain why we use variables within translation functions [#37397] - -### Changed -- Updated package dependencies. [#37379] - -## [2.1.9] - 2024-05-06 -### Changed -- Updated package dependencies. [#37147] - -## [2.1.8] - 2024-04-22 -### Changed -- Internal updates. - -## [2.1.7] - 2024-04-08 -### Changed -- Updated package dependencies. [#36760] - -## [2.1.6] - 2024-03-27 -### Changed -- Updated package dependencies. [#36585] - -## [2.1.5] - 2024-03-18 -### Changed -- Internal updates. - -## [2.1.4] - 2024-03-12 -### Changed -- Internal updates. - -## [2.1.3] - 2024-03-12 -### Changed -- Updated package dependencies. [#36325] - -## [2.1.2] - 2024-03-04 -### Changed -- Updated package dependencies. [#36095] - -## [2.1.1] - 2024-02-13 -### Changed -- Updated package dependencies. [#35608] - -## [2.1.0] - 2024-02-05 -### Added -- Add support for script enqueuing strategies implemented in WordPress 6.3 [#34072] - -### Changed -- Updated package dependencies. [#35384] - -## [2.0.4] - 2024-01-04 -### Changed -- Updated package dependencies. [#34815] - -## [2.0.3] - 2023-12-11 -### Changed -- Updated package dependencies. [#34492] - -## [2.0.2] - 2023-12-03 -### Changed -- Updated package dependencies. [#34411] [#34427] - -## [2.0.1] - 2023-11-21 - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.18.15] - 2023-11-14 -### Changed -- Updated package dependencies. [#34093] - -## [1.18.14] - 2023-11-03 - -## [1.18.13] - 2023-10-19 -### Changed -- Updated package dependencies. [#33687] - -## [1.18.12] - 2023-10-10 -### Changed -- Updated package dependencies. [#33428] - -### Fixed -- Pass `false`, not `null`, to `WP_Scripts->add()`. [#33513] - -## [1.18.11] - 2023-09-19 - -- Minor internal updates. - -## [1.18.10] - 2023-09-04 -### Changed -- Updated package dependencies. [#32803] - -## [1.18.9] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.18.8] - 2023-08-09 -### Changed -- Updated package dependencies. [#32166] - -## [1.18.7] - 2023-07-11 -### Changed -- Updated package dependencies. [#31785] - -## [1.18.6] - 2023-07-05 -### Changed -- Updated package dependencies. [#31659] - -## [1.18.5] - 2023-06-21 -### Changed -- Updated package dependencies. [#31468] - -## [1.18.4] - 2023-06-06 -### Changed -- Updated package dependencies. [#31129] - -## [1.18.3] - 2023-05-15 -### Changed -- Internal updates. - -## [1.18.2] - 2023-05-02 -### Changed -- Updated package dependencies. [#30375] - -## [1.18.1] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.18.0] - 2023-04-04 -### Changed -- Async script enqueuing: switch to static method. [#29780] -- Updated package dependencies. [#29854] - -## [1.17.34] - 2023-03-20 -### Changed -- Updated package dependencies. [#29471] - -## [1.17.33] - 2023-03-08 -### Changed -- Updated package dependencies. [#29216] - -## [1.17.32] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.17.31] - 2023-02-15 -### Changed -- Update to React 18. [#28710] - -## [1.17.30] - 2023-01-25 -### Changed -- Minor internal updates. - -## [1.17.29] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.17.28] - 2022-12-02 -### Changed -- Updated package dependencies. - -## [1.17.27] - 2022-11-28 -### Changed -- Updated package dependencies. [#27576] - -## [1.17.26] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.17.25] - 2022-11-08 -### Changed -- Updated package dependencies. [#27289] - -## [1.17.24] - 2022-11-01 -### Changed -- Updated package dependencies. - -## [1.17.23] - 2022-10-13 -### Changed -- Updated package dependencies. [#26791] - -## [1.17.22] - 2022-10-05 -### Changed -- Updated package dependencies. [#26568] - -## [1.17.21] - 2022-08-25 -### Changed -- Updated package dependencies. [#25814] - -## [1.17.20] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.17.19] - 2022-07-12 -### Changed -- Updated package dependencies. - -## [1.17.18] - 2022-07-06 -### Changed -- Updated package dependencies - -## [1.17.17] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.17.16] - 2022-06-14 - -## [1.17.15] - 2022-06-08 -### Changed -- Reorder JS imports for `import/order` eslint rule. [#24601] - -## [1.17.14] - 2022-05-18 -### Changed -- Updated package dependencies [#24372] - -## [1.17.13] - 2022-05-10 -### Changed -- Updated package dependencies. [#24302] - -## [1.17.12] - 2022-05-04 -### Added -- Add missing JavaScript dependencies, and fix a test. [#24096] - -## [1.17.11] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.17.10] - 2022-04-19 -### Fixed -- Assets: Defer the enqueued script instead of its translations - -## [1.17.9] - 2022-04-05 -### Changed -- Updated package dependencies. - -## [1.17.8] - 2022-03-29 -### Changed -- Updated package dependencies. - -## [1.17.7] - 2022-03-23 -### Changed -- Updated package dependencies. - -## [1.17.6] - 2022-03-02 -### Changed -- Updated package dependencies. - -## [1.17.5] - 2022-02-16 -### Changed -- Updated package dependencies. - -## [1.17.4] - 2022-02-09 -### Changed -- Updated package dependencies. - -## [1.17.3] - 2022-02-02 -### Fixed -- Fixed minor coding standard violation. - -## [1.17.2] - 2022-02-01 -### Changed -- Build: remove unneeded files from production build. - -## [1.17.1] - 2022-01-27 -### Changed -- Updated package dependencies. - -## [1.17.0] - 2022-01-25 -### Added -- Accept package path prefixes from jetpack-composer-plugin and use them when lazy-loading JS translations. -- Generate the `wp-jp-i18n-loader` module needed by the new i18n-loader-webpack-plugin. - -### Deprecated -- Deprecated the `wp-jp-i18n-state` module. - -## [1.16.2] - 2022-01-18 -### Fixed -- Handle the case where `WP_LANG_DIR` is in `WP_CONTENT_DIR`, but `WP_CONTENT_DIR` is not in `ABSPATH`. - -## [1.16.1] - 2022-01-05 -### Fixed -- Don't issue a "doing it wrong" warning for registering aliases during plugin activation. - -## [1.16.0] - 2022-01-04 -### Added -- Document use of jetpack-assets, jetpack-composer-plugin, and i18n-loader-webpack-plugin together. - -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies -- Updated package textdomain from `jetpack` to `jetpack-assets`. - -## [1.15.0] - 2021-12-20 -### Added -- Add `alias_textdomain()`. - -## [1.14.0] - 2021-12-14 -### Added -- Generate `wp-jp-i18n-state` script. - -## [1.13.1] - 2021-11-22 -### Fixed -- Call `_doing_it_wrong` correctly. - -## [1.13.0] - 2021-11-22 -### Added -- Have `Assets::register_script()` accept a textdomain for `wp_set_script_translations` (and complain if no textdomain is passed when `wp-i18n` is depended on). - -### Changed -- Updated package dependencies - -### Fixed -- Added missing option doc for `Assets::register_script()`. - -## [1.12.0] - 2021-11-15 -### Added -- Add `Assets::register_script()` for easier loading of Webpack-built scripts. - -## [1.11.10] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.11.9] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.11.8] - 2021-10-06 -### Changed -- Updated package dependencies - -## [1.11.7] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.11.6] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- update annotations versions - -## [1.11.5] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.11.4] - 2021-04-08 -### Changed -- Packaging and build changes, no change to the package itself. - -## [1.11.3] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.11.2] - 2021-02-23 - -- CI: Make tests more generic - -## [1.11.1] - 2021-01-26 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.11.0] - 2021-01-05 - -- Update dependency brain/monkey to v2.6.0 - -## [1.10.0] - 2020-12-08 - -- Assets: introduce new method to process static resources -- Assets: Use defer for script tags -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.9.1] - 2020-11-24 - -- Update dependency brain/monkey to v2.5.0 -- Updated PHPCS: Packages and Debugger - -## [1.9.0] - 2020-10-27 - -- Instagram oEmbed: Simplify - -## [1.8.0] - 2020-09-29 - -- Consolidate the Lazy Images package to rely on the Assets package - -## [1.7.0] - 2020-08-25 - -- Packages: Update filenames after #16810 -- CI: Try collect js coverage -- Docker: Add package testing shortcut - -## [1.6.0] - 2020-07-28 - -- Various: Use wp_resource_hints - -## [1.5.0] - 2020-06-30 - -- PHPCS: Clean up the packages -- WooCommerce Analytics: avoid 404 error when enqueuing script - -## [1.4.0] - 2020-05-26 - -- Add Jetpack Scan threat notifications - -## [1.3.0] - 2020-04-28 - -- Update dependencies to latest stable - -## [1.2.0] - 2020-03-31 - -- Update dependencies to latest stable - -## [1.1.1] - 2020-01-27 - -- Pin dependency brain/monkey to 2.4.0 - -## [1.1.0] - 2020-01-14 - -- Packages: Various improvements for wp.com or self-contained consumers - -## [1.0.3] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.0.1] - 2019-10-28 - -- PHPCS: JITM and Assets packages -- Packages: Add gitattributes files to all packages that need th… - -## 1.0.0 - 2019-09-14 - -- Statically access asset tools - -[4.0.14]: https://github.com/Automattic/jetpack-assets/compare/v4.0.13...v4.0.14 -[4.0.13]: https://github.com/Automattic/jetpack-assets/compare/v4.0.12...v4.0.13 -[4.0.12]: https://github.com/Automattic/jetpack-assets/compare/v4.0.11...v4.0.12 -[4.0.11]: https://github.com/Automattic/jetpack-assets/compare/v4.0.10...v4.0.11 -[4.0.10]: https://github.com/Automattic/jetpack-assets/compare/v4.0.9...v4.0.10 -[4.0.9]: https://github.com/Automattic/jetpack-assets/compare/v4.0.8...v4.0.9 -[4.0.8]: https://github.com/Automattic/jetpack-assets/compare/v4.0.7...v4.0.8 -[4.0.7]: https://github.com/Automattic/jetpack-assets/compare/v4.0.6...v4.0.7 -[4.0.6]: https://github.com/Automattic/jetpack-assets/compare/v4.0.5...v4.0.6 -[4.0.5]: https://github.com/Automattic/jetpack-assets/compare/v4.0.4...v4.0.5 -[4.0.4]: https://github.com/Automattic/jetpack-assets/compare/v4.0.3...v4.0.4 -[4.0.3]: https://github.com/Automattic/jetpack-assets/compare/v4.0.2...v4.0.3 -[4.0.2]: https://github.com/Automattic/jetpack-assets/compare/v4.0.1...v4.0.2 -[4.0.1]: https://github.com/Automattic/jetpack-assets/compare/v4.0.0...v4.0.1 -[4.0.0]: https://github.com/Automattic/jetpack-assets/compare/v3.0.0...v4.0.0 -[3.0.0]: https://github.com/Automattic/jetpack-assets/compare/v2.3.14...v3.0.0 -[2.3.14]: https://github.com/Automattic/jetpack-assets/compare/v2.3.13...v2.3.14 -[2.3.13]: https://github.com/Automattic/jetpack-assets/compare/v2.3.12...v2.3.13 -[2.3.12]: https://github.com/Automattic/jetpack-assets/compare/v2.3.11...v2.3.12 -[2.3.11]: https://github.com/Automattic/jetpack-assets/compare/v2.3.10...v2.3.11 -[2.3.10]: https://github.com/Automattic/jetpack-assets/compare/v2.3.9...v2.3.10 -[2.3.9]: https://github.com/Automattic/jetpack-assets/compare/v2.3.8...v2.3.9 -[2.3.8]: https://github.com/Automattic/jetpack-assets/compare/v2.3.7...v2.3.8 -[2.3.7]: https://github.com/Automattic/jetpack-assets/compare/v2.3.6...v2.3.7 -[2.3.6]: https://github.com/Automattic/jetpack-assets/compare/v2.3.5...v2.3.6 -[2.3.5]: https://github.com/Automattic/jetpack-assets/compare/v2.3.4...v2.3.5 -[2.3.4]: https://github.com/Automattic/jetpack-assets/compare/v2.3.3...v2.3.4 -[2.3.3]: https://github.com/Automattic/jetpack-assets/compare/v2.3.2...v2.3.3 -[2.3.2]: https://github.com/Automattic/jetpack-assets/compare/v2.3.1...v2.3.2 -[2.3.1]: https://github.com/Automattic/jetpack-assets/compare/v2.3.0...v2.3.1 -[2.3.0]: https://github.com/Automattic/jetpack-assets/compare/v2.2.0...v2.3.0 -[2.2.0]: https://github.com/Automattic/jetpack-assets/compare/v2.1.13...v2.2.0 -[2.1.13]: https://github.com/Automattic/jetpack-assets/compare/v2.1.12...v2.1.13 -[2.1.12]: https://github.com/Automattic/jetpack-assets/compare/v2.1.11...v2.1.12 -[2.1.11]: https://github.com/Automattic/jetpack-assets/compare/v2.1.10...v2.1.11 -[2.1.10]: https://github.com/Automattic/jetpack-assets/compare/v2.1.9...v2.1.10 -[2.1.9]: https://github.com/Automattic/jetpack-assets/compare/v2.1.8...v2.1.9 -[2.1.8]: https://github.com/Automattic/jetpack-assets/compare/v2.1.7...v2.1.8 -[2.1.7]: https://github.com/Automattic/jetpack-assets/compare/v2.1.6...v2.1.7 -[2.1.6]: https://github.com/Automattic/jetpack-assets/compare/v2.1.5...v2.1.6 -[2.1.5]: https://github.com/Automattic/jetpack-assets/compare/v2.1.4...v2.1.5 -[2.1.4]: https://github.com/Automattic/jetpack-assets/compare/v2.1.3...v2.1.4 -[2.1.3]: https://github.com/Automattic/jetpack-assets/compare/v2.1.2...v2.1.3 -[2.1.2]: https://github.com/Automattic/jetpack-assets/compare/v2.1.1...v2.1.2 -[2.1.1]: https://github.com/Automattic/jetpack-assets/compare/v2.1.0...v2.1.1 -[2.1.0]: https://github.com/Automattic/jetpack-assets/compare/v2.0.4...v2.1.0 -[2.0.4]: https://github.com/Automattic/jetpack-assets/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-assets/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-assets/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-assets/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-assets/compare/v1.18.15...v2.0.0 -[1.18.15]: https://github.com/Automattic/jetpack-assets/compare/v1.18.14...v1.18.15 -[1.18.14]: https://github.com/Automattic/jetpack-assets/compare/v1.18.13...v1.18.14 -[1.18.13]: https://github.com/Automattic/jetpack-assets/compare/v1.18.12...v1.18.13 -[1.18.12]: https://github.com/Automattic/jetpack-assets/compare/v1.18.11...v1.18.12 -[1.18.11]: https://github.com/Automattic/jetpack-assets/compare/v1.18.10...v1.18.11 -[1.18.10]: https://github.com/Automattic/jetpack-assets/compare/v1.18.9...v1.18.10 -[1.18.9]: https://github.com/Automattic/jetpack-assets/compare/v1.18.8...v1.18.9 -[1.18.8]: https://github.com/Automattic/jetpack-assets/compare/v1.18.7...v1.18.8 -[1.18.7]: https://github.com/Automattic/jetpack-assets/compare/v1.18.6...v1.18.7 -[1.18.6]: https://github.com/Automattic/jetpack-assets/compare/v1.18.5...v1.18.6 -[1.18.5]: https://github.com/Automattic/jetpack-assets/compare/v1.18.4...v1.18.5 -[1.18.4]: https://github.com/Automattic/jetpack-assets/compare/v1.18.3...v1.18.4 -[1.18.3]: https://github.com/Automattic/jetpack-assets/compare/v1.18.2...v1.18.3 -[1.18.2]: https://github.com/Automattic/jetpack-assets/compare/v1.18.1...v1.18.2 -[1.18.1]: https://github.com/Automattic/jetpack-assets/compare/v1.18.0...v1.18.1 -[1.18.0]: https://github.com/Automattic/jetpack-assets/compare/v1.17.34...v1.18.0 -[1.17.34]: https://github.com/Automattic/jetpack-assets/compare/v1.17.33...v1.17.34 -[1.17.33]: https://github.com/Automattic/jetpack-assets/compare/v1.17.32...v1.17.33 -[1.17.32]: https://github.com/Automattic/jetpack-assets/compare/v1.17.31...v1.17.32 -[1.17.31]: https://github.com/Automattic/jetpack-assets/compare/v1.17.30...v1.17.31 -[1.17.30]: https://github.com/Automattic/jetpack-assets/compare/v1.17.29...v1.17.30 -[1.17.29]: https://github.com/Automattic/jetpack-assets/compare/v1.17.28...v1.17.29 -[1.17.28]: https://github.com/Automattic/jetpack-assets/compare/v1.17.27...v1.17.28 -[1.17.27]: https://github.com/Automattic/jetpack-assets/compare/v1.17.26...v1.17.27 -[1.17.26]: https://github.com/Automattic/jetpack-assets/compare/v1.17.25...v1.17.26 -[1.17.25]: https://github.com/Automattic/jetpack-assets/compare/v1.17.24...v1.17.25 -[1.17.24]: https://github.com/Automattic/jetpack-assets/compare/v1.17.23...v1.17.24 -[1.17.23]: https://github.com/Automattic/jetpack-assets/compare/v1.17.22...v1.17.23 -[1.17.22]: https://github.com/Automattic/jetpack-assets/compare/v1.17.21...v1.17.22 -[1.17.21]: https://github.com/Automattic/jetpack-assets/compare/v1.17.20...v1.17.21 -[1.17.20]: https://github.com/Automattic/jetpack-assets/compare/v1.17.19...v1.17.20 -[1.17.19]: https://github.com/Automattic/jetpack-assets/compare/v1.17.18...v1.17.19 -[1.17.18]: https://github.com/Automattic/jetpack-assets/compare/v1.17.17...v1.17.18 -[1.17.17]: https://github.com/Automattic/jetpack-assets/compare/v1.17.16...v1.17.17 -[1.17.16]: https://github.com/Automattic/jetpack-assets/compare/v1.17.15...v1.17.16 -[1.17.15]: https://github.com/Automattic/jetpack-assets/compare/v1.17.14...v1.17.15 -[1.17.14]: https://github.com/Automattic/jetpack-assets/compare/v1.17.13...v1.17.14 -[1.17.13]: https://github.com/Automattic/jetpack-assets/compare/v1.17.12...v1.17.13 -[1.17.12]: https://github.com/Automattic/jetpack-assets/compare/v1.17.11...v1.17.12 -[1.17.11]: https://github.com/Automattic/jetpack-assets/compare/v1.17.10...v1.17.11 -[1.17.10]: https://github.com/Automattic/jetpack-assets/compare/v1.17.9...v1.17.10 -[1.17.9]: https://github.com/Automattic/jetpack-assets/compare/v1.17.8...v1.17.9 -[1.17.8]: https://github.com/Automattic/jetpack-assets/compare/v1.17.7...v1.17.8 -[1.17.7]: https://github.com/Automattic/jetpack-assets/compare/v1.17.6...v1.17.7 -[1.17.6]: https://github.com/Automattic/jetpack-assets/compare/v1.17.5...v1.17.6 -[1.17.5]: https://github.com/Automattic/jetpack-assets/compare/v1.17.4...v1.17.5 -[1.17.4]: https://github.com/Automattic/jetpack-assets/compare/v1.17.3...v1.17.4 -[1.17.3]: https://github.com/Automattic/jetpack-assets/compare/v1.17.2...v1.17.3 -[1.17.2]: https://github.com/Automattic/jetpack-assets/compare/v1.17.1...v1.17.2 -[1.17.1]: https://github.com/Automattic/jetpack-assets/compare/v1.17.0...v1.17.1 -[1.17.0]: https://github.com/Automattic/jetpack-assets/compare/v1.16.2...v1.17.0 -[1.16.2]: https://github.com/Automattic/jetpack-assets/compare/v1.16.1...v1.16.2 -[1.16.1]: https://github.com/Automattic/jetpack-assets/compare/v1.16.0...v1.16.1 -[1.16.0]: https://github.com/Automattic/jetpack-assets/compare/v1.15.0...v1.16.0 -[1.15.0]: https://github.com/Automattic/jetpack-assets/compare/v1.14.0...v1.15.0 -[1.14.0]: https://github.com/Automattic/jetpack-assets/compare/v1.13.1...v1.14.0 -[1.13.1]: https://github.com/Automattic/jetpack-assets/compare/v1.13.0...v1.13.1 -[1.13.0]: https://github.com/Automattic/jetpack-assets/compare/v1.12.0...v1.13.0 -[1.12.0]: https://github.com/Automattic/jetpack-assets/compare/v1.11.10...v1.12.0 -[1.11.10]: https://github.com/Automattic/jetpack-assets/compare/v1.11.9...v1.11.10 -[1.11.9]: https://github.com/Automattic/jetpack-assets/compare/v1.11.8...v1.11.9 -[1.11.8]: https://github.com/Automattic/jetpack-assets/compare/v1.11.7...v1.11.8 -[1.11.7]: https://github.com/Automattic/jetpack-assets/compare/v1.11.6...v1.11.7 -[1.11.6]: https://github.com/Automattic/jetpack-assets/compare/v1.11.5...v1.11.6 -[1.11.5]: https://github.com/Automattic/jetpack-assets/compare/v1.11.4...v1.11.5 -[1.11.4]: https://github.com/Automattic/jetpack-assets/compare/v1.11.3...v1.11.4 -[1.11.3]: https://github.com/Automattic/jetpack-assets/compare/v1.11.2...v1.11.3 -[1.11.2]: https://github.com/Automattic/jetpack-assets/compare/v1.11.1...v1.11.2 -[1.11.1]: https://github.com/Automattic/jetpack-assets/compare/v1.11.0...v1.11.1 -[1.11.0]: https://github.com/Automattic/jetpack-assets/compare/v1.10.0...v1.11.0 -[1.10.0]: https://github.com/Automattic/jetpack-assets/compare/v1.9.1...v1.10.0 -[1.9.1]: https://github.com/Automattic/jetpack-assets/compare/v1.9.0...v1.9.1 -[1.9.0]: https://github.com/Automattic/jetpack-assets/compare/v1.8.0...v1.9.0 -[1.8.0]: https://github.com/Automattic/jetpack-assets/compare/v1.7.0...v1.8.0 -[1.7.0]: https://github.com/Automattic/jetpack-assets/compare/v1.6.0...v1.7.0 -[1.6.0]: https://github.com/Automattic/jetpack-assets/compare/v1.5.0...v1.6.0 -[1.5.0]: https://github.com/Automattic/jetpack-assets/compare/v1.4.0...v1.5.0 -[1.4.0]: https://github.com/Automattic/jetpack-assets/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-assets/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-assets/compare/v1.1.1...v1.2.0 -[1.1.1]: https://github.com/Automattic/jetpack-assets/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-assets/compare/v1.0.3...v1.1.0 -[1.0.3]: https://github.com/Automattic/jetpack-assets/compare/v1.0.1...v1.0.3 -[1.0.1]: https://github.com/Automattic/jetpack-assets/compare/v1.0.0...v1.0.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/actions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/actions.php deleted file mode 100644 index 487100d8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/actions.php +++ /dev/null @@ -1,25 +0,0 @@ - 1, - 'function' => array( Automattic\Jetpack\Assets::class, 'wp_default_scripts_hook' ), - ); - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $wp_filter['plugins_loaded'][1][] = array( - 'accepted_args' => 0, - 'function' => array( Automattic\Jetpack\Assets\Script_Data::class, 'configure' ), - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.asset.php deleted file mode 100644 index cb123d3a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('wp-i18n'), 'version' => 'becd7d9884bc1b331e45'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.js deleted file mode 100644 index 2712dfa9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/i18n-loader.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{var e={477:function(e){e.exports=function(e){function r(t){if(n[t])return n[t].exports;var o=n[t]={i:t,l:!1,exports:{}};return e[t].call(o.exports,o,o.exports,r),o.l=!0,o.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,n,t){r.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=1)}([function(e,r,n){"use strict";function t(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(r,"__esModule",{value:!0});var o=function(){function e(e,r){for(var n=0;n>>32-o)+n&4294967295}},{key:"ff",value:function(r,n,t,o,a,i,f){return e.cmn(n&t|~n&o,r,n,a,i,f)}},{key:"gg",value:function(r,n,t,o,a,i,f){return e.cmn(n&o|t&~o,r,n,a,i,f)}},{key:"hh",value:function(r,n,t,o,a,i,f){return e.cmn(n^t^o,r,n,a,i,f)}},{key:"ii",value:function(r,n,t,o,a,i,f){return e.cmn(t^(n|~o),r,n,a,i,f)}},{key:"md51",value:function(r){for(var n=r.length,t=[1732584193,-271733879,-1732584194,271733878],o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],a=0,i=64;i<=n;i+=64)e.md5cycle(t,e.md5blk(r.substring(i-64,i)));for(r=r.substring(i-64),i=0,a=r.length;i>2]|=r.charCodeAt(i)<<(i%4<<3);if(o[i>>2]|=128<<(i%4<<3),i>55)for(e.md5cycle(t,o),i=0;i<16;i++)o[i]=0;return o[14]=8*n,e.md5cycle(t,o),t}},{key:"md5blk",value:function(e){for(var r=[],n=0;n<64;n+=4)r[n>>2]=e.charCodeAt(n)+(e.charCodeAt(n+1)<<8)+(e.charCodeAt(n+2)<<16)+(e.charCodeAt(n+3)<<24);return r}},{key:"rhex",value:function(r){var n="";return n+=e.hexArray[r>>4&15]+e.hexArray[15&r],n+=e.hexArray[r>>12&15]+e.hexArray[r>>8&15],(n+=e.hexArray[r>>20&15]+e.hexArray[r>>16&15])+(e.hexArray[r>>28&15]+e.hexArray[r>>24&15])}},{key:"hex",value:function(r){for(var n=r.length,t=0;t{const t=n(723),{default:o}=n(477),a={plugin:"plugins/",theme:"themes/",core:""},i=(e,r)=>Object.prototype.hasOwnProperty.call(e,r);e.exports={state:{baseUrl:null,locale:null,domainMap:{},domainPaths:{}},async downloadI18n(e,r,n){const f=this.state;if(!f||"string"!=typeof f.baseUrl)throw new Error("wp.jpI18nLoader.state is not set");if("en_US"===f.locale)return;if("undefined"==typeof fetch)throw new Error("Fetch API is not available.");const u=i(f.domainPaths,r)?f.domainPaths[r]:"";let c,h;const l=e.indexOf("?");l>=0?(c=o.hash(u+e.substring(0,l)),h=e.substring(l)):(c=o.hash(u+e),h="");const s=i(f.domainMap,r)?f.domainMap[r]:a[n]+r,g=await fetch(`${f.baseUrl}${s}-${f.locale}-${c}.json${h}`);if(!g.ok)throw new Error(`HTTP request failed: ${g.status} ${g.statusText}`);const d=await g.json(),p=i(d.locale_data,r)?d.locale_data[r]:d.locale_data.messages;p[""].domain=r,t.setLocaleData(p,r)}}},723:e=>{"use strict";e.exports=window.wp.i18n}},r={};var n=function n(t){var o=r[t];if(void 0!==o)return o.exports;var a=r[t]={exports:{}};return e[t].call(a.exports,a,a.exports,n),a.exports}(305);(window.wp=window.wp||{}).jpI18nLoader=n})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/jetpack-script-data.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/jetpack-script-data.asset.php deleted file mode 100644 index d992ed4e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/jetpack-script-data.asset.php +++ /dev/null @@ -1 +0,0 @@ - array(), 'version' => '7f1c9fc474dccfef702f'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/jetpack-script-data.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/jetpack-script-data.js deleted file mode 100644 index 05b7d3f7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/build/jetpack-script-data.js +++ /dev/null @@ -1 +0,0 @@ -!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.JetpackScriptDataModule=t():e.JetpackScriptDataModule=t()}(globalThis,(()=>(()=>{"use strict";var e={729:(e,t,r)=>{r.d(t,{$8:()=>n.$8,IT:()=>n.IT,L2:()=>n.L2,Sy:()=>n.Sy,au:()=>n.au,d9:()=>n.d9,d_:()=>n.d_,e5:()=>n.e5,hT:()=>n.hT,lI:()=>n.lI,mH:()=>n.mH,oQ:()=>n.oQ,sV:()=>n.sV});var n=r(336)},336:(e,t,r)=>{function n(){return window.JetpackScriptData}function o(){return n().site}function i(e=""){return`${n().site.admin_url}${e}`}function u(e=""){return i(`admin.php?page=jetpack${e}`)}function a(e=""){return i(`admin.php?page=my-jetpack${e}`)}function c(){return n().site.plan?.features?.active??[]}function s(e){return c().includes(e)}function p(){return"wpcom"===n().site?.host}function d(){return"atomic"===n().site?.host}function f(){return"woa"===n().site?.host}function l(){return p()||f()}function m(){return"unknown"===n()?.site?.host}function S(e){return n().user.current_user.capabilities[e]}r.d(t,{$8:()=>l,IT:()=>s,L2:()=>m,Sy:()=>p,au:()=>n,d9:()=>d,d_:()=>S,e5:()=>a,hT:()=>i,lI:()=>f,mH:()=>c,oQ:()=>u,sV:()=>o})}},t={};function r(n){var o=t[n];if(void 0!==o)return o.exports;var i=t[n]={exports:{}};return e[n](i,i.exports,r),i.exports}r.d=(e,t)=>{for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var n={};r.r(n),r.d(n,{currentUserCan:()=>o.d_,getActiveFeatures:()=>o.mH,getAdminUrl:()=>o.hT,getJetpackAdminPageUrl:()=>o.oQ,getMyJetpackUrl:()=>o.e5,getScriptData:()=>o.au,getSiteData:()=>o.sV,isAtomicSite:()=>o.d9,isJetpackSelfHostedSite:()=>o.L2,isSimpleSite:()=>o.Sy,isWoASite:()=>o.lI,isWpcomPlatformSite:()=>o.$8,siteHasFeature:()=>o.IT});var o=r(729);return n})())); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/composer.json deleted file mode 100644 index 28811daa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/composer.json +++ /dev/null @@ -1,59 +0,0 @@ -{ - "name": "automattic/jetpack-assets", - "description": "Asset management utilities for Jetpack ecosystem packages", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-constants": "^3.0.5" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "wikimedia/testing-access-wrapper": "^1.0 || ^2.0 || ^3.0", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "src/" - ] - }, - "scripts": { - "build-development": [ - "pnpm run build" - ], - "build-production": [ - "pnpm run build-production" - ], - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": "pnpm concurrently --names php,js 'php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"' 'pnpm:test-coverage'", - "test-js": [ - "pnpm run test" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-assets", - "textdomain": "jetpack-assets", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-assets/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "4.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php deleted file mode 100644 index 71725eec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php +++ /dev/null @@ -1,763 +0,0 @@ - array( string target_domain, string target_type, string semver, string path_prefix ) )`. - */ - private static $domain_map = array(); - - /** - * Constructor. - * - * Static-only class, so nothing here. - */ - private function __construct() {} - - // //////////////////// - // region Async script loading - - /** - * Get the singleton instance of the class. - * - * @return Assets - */ - public static function instance() { - if ( ! isset( self::$instance ) ) { - self::$instance = new Assets(); - } - - return self::$instance; - } - - /** - * A public method for adding the async script. - * - * @deprecated Since 2.1.0, the `strategy` feature should be used instead, with the "defer" setting. - * - * @param string $script_handle Script handle. - */ - public static function add_async_script( $script_handle ) { - _deprecated_function( __METHOD__, '2.1.0' ); - - wp_script_add_data( $script_handle, 'strategy', 'defer' ); - } - - /** - * Add an async attribute to scripts that can be loaded deferred. - * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/script - * - * @deprecated Since 2.1.0, the `strategy` feature should be used instead. - * - * @param string $tag The - ' . esc_html__( 'Every Jetpack site needs at least one connected admin for the features to work properly. Please connect to your WordPress.com account via the button below. Once you connect, you may refresh this page to see an option to change the connection owner.', 'jetpack-connection' ) . '

            '; - $connect_url = $connection_manager->get_authorization_url(); - $connect_url = add_query_arg( 'from', 'delete_connection_owner_notice', $connect_url ); - echo "" . esc_html__( 'Connect to WordPress.com', 'jetpack-connection' ) . ''; - } - - echo '

            '; - printf( - wp_kses( - /* translators: URL to Jetpack support doc regarding the primary user. */ - __( "Learn more about the connection owner and what will break if you do not have one.", 'jetpack-connection' ), - array( - 'a' => array( - 'href' => true, - 'target' => true, - 'rel' => true, - ), - ) - ), - esc_url( Redirect::get_url( 'jetpack-support-primary-user' ) ) - ); - echo '

            '; - echo '

            '; - printf( - wp_kses( - /* translators: URL to contact Jetpack support. */ - __( 'As always, feel free to contact our support team if you have any questions.', 'jetpack-connection' ), - array( - 'a' => array( - 'href' => true, - 'target' => true, - 'rel' => true, - ), - ) - ), - esc_url( Redirect::get_url( 'jetpack-contact-support' ) ) - ); - echo '

            '; - echo ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php deleted file mode 100644 index 55b65b62..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php +++ /dev/null @@ -1,780 +0,0 @@ - [ - * $user_id => [ - * $error_details - * ] - * ] - * ] - * - * For each error code we store a maximum of 5 errors for 5 different user ids. - * - * An user ID can be - * * 0 for blog tokens - * * positive integer for user tokens - * * 'invalid' for malformed tokens - * - * @since 1.14.2 - */ -class Error_Handler { - - /** - * The name of the option that stores the errors - * - * @since 1.14.2 - * - * @var string - */ - const STORED_ERRORS_OPTION = 'jetpack_connection_xmlrpc_errors'; - - /** - * The name of the option that stores the errors - * - * @since 1.14.2 - * - * @var string - */ - const STORED_VERIFIED_ERRORS_OPTION = 'jetpack_connection_xmlrpc_verified_errors'; - - /** - * The prefix of the transient that controls the gate for each error code - * - * @since 1.14.2 - * - * @var string - */ - const ERROR_REPORTING_GATE = 'jetpack_connection_error_reporting_gate_'; - - /** - * Time in seconds a test should live in the database before being discarded - * - * @since 1.14.2 - */ - const ERROR_LIFE_TIME = DAY_IN_SECONDS; - - /** - * The error code for event tracking purposes. - * If there are many, only the first error code will be tracked. - * - * @var string - */ - private $error_code; - - /** - * List of known errors. Only error codes in this list will be handled - * - * @since 1.14.2 - * - * @var array - */ - public $known_errors = array( - 'malformed_token', - 'malformed_user_id', - 'unknown_user', - 'no_user_tokens', - 'empty_master_user_option', - 'no_token_for_user', - 'token_malformed', - 'user_id_mismatch', - 'no_possible_tokens', - 'no_valid_user_token', - 'no_valid_blog_token', - 'unknown_token', - 'could_not_sign', - 'invalid_scheme', - 'invalid_secret', - 'invalid_token', - 'token_mismatch', - 'invalid_body', - 'invalid_signature', - 'invalid_body_hash', - 'invalid_nonce', - 'signature_mismatch', - 'invalid_connection_owner', - ); - - /** - * Holds the instance of this singleton class - * - * @since 1.14.2 - * - * @var Error_Handler $instance - */ - public static $instance = null; - - /** - * Initialize instance, hookds and load verified errors handlers - * - * @since 1.14.2 - */ - private function __construct() { - defined( 'JETPACK__ERRORS_PUBLIC_KEY' ) || define( 'JETPACK__ERRORS_PUBLIC_KEY', 'KdZY80axKX+nWzfrOcizf0jqiFHnrWCl9X8yuaClKgM=' ); - - add_action( 'rest_api_init', array( $this, 'register_verify_error_endpoint' ) ); - - // Handle verified errors on admin pages. - add_action( 'admin_init', array( $this, 'handle_verified_errors' ) ); - - // If the site gets reconnected, clear errors. - add_action( 'jetpack_site_registered', array( $this, 'delete_all_errors' ) ); - add_action( 'jetpack_get_site_data_success', array( $this, 'delete_all_api_errors' ) ); - add_filter( 'jetpack_connection_disconnect_site_wpcom', array( $this, 'delete_all_errors_and_return_unfiltered_value' ) ); - add_filter( 'jetpack_connection_delete_all_tokens', array( $this, 'delete_all_errors_and_return_unfiltered_value' ) ); - add_action( 'jetpack_unlinked_user', array( $this, 'delete_all_errors' ) ); - add_action( 'jetpack_updated_user_token', array( $this, 'delete_all_errors' ) ); - } - - /** - * Gets the list of verified errors and act upon them - * - * @since 1.14.2 - * - * @return void - */ - public function handle_verified_errors() { - $verified_errors = $this->get_verified_errors(); - foreach ( array_keys( $verified_errors ) as $error_code ) { - switch ( $error_code ) { - case 'malformed_token': - case 'token_malformed': - case 'no_possible_tokens': - case 'no_valid_user_token': - case 'no_valid_blog_token': - case 'unknown_token': - case 'could_not_sign': - case 'invalid_token': - case 'token_mismatch': - case 'invalid_signature': - case 'signature_mismatch': - case 'no_user_tokens': - case 'no_token_for_user': - case 'invalid_connection_owner': - add_action( 'admin_notices', array( $this, 'generic_admin_notice_error' ) ); - add_action( 'react_connection_errors_initial_state', array( $this, 'jetpack_react_dashboard_error' ) ); - $this->error_code = $error_code; - - // Since we are only generically handling errors, we don't need to trigger error messages for each one of them. - break 2; - } - } - } - - /** - * Gets the instance of this singleton class - * - * @since 1.14.2 - * - * @return Error_Handler $instance - */ - public static function get_instance() { - if ( self::$instance === null ) { - self::$instance = new self(); - } - return self::$instance; - } - - /** - * Keep track of a connection error that was encountered - * - * @param \WP_Error $error The error object. - * @param boolean $force Force the report, even if should_report_error is false. - * @param boolean $skip_wpcom_verification Set to 'true' to verify the error locally and skip the WP.com verification. - * - * @return void - * @since 1.14.2 - */ - public function report_error( \WP_Error $error, $force = false, $skip_wpcom_verification = false ) { - if ( in_array( $error->get_error_code(), $this->known_errors, true ) && $this->should_report_error( $error ) || $force ) { - $stored_error = $this->store_error( $error ); - if ( $stored_error ) { - $skip_wpcom_verification ? $this->verify_error( $stored_error ) : $this->send_error_to_wpcom( $stored_error ); - } - } - } - - /** - * Checks the status of the gate - * - * This protects the site (and WPCOM) against over loads. - * - * @since 1.14.2 - * - * @param \WP_Error $error the error object. - * @return boolean $should_report True if gate is open and the error should be reported. - */ - public function should_report_error( \WP_Error $error ) { - if ( defined( 'JETPACK_DEV_DEBUG' ) && JETPACK_DEV_DEBUG ) { - return true; - } - - /** - * Whether to bypass the gate for the error handling - * - * By default, we only process errors once an hour for each error code. - * This is done to avoid overflows. If you need to disable this gate, you can set this variable to true. - * - * This filter is useful for unit testing - * - * @since 1.14.2 - * - * @param boolean $bypass_gate whether to bypass the gate. Default is false, do not bypass. - */ - $bypass_gate = apply_filters( 'jetpack_connection_bypass_error_reporting_gate', false ); - if ( true === $bypass_gate ) { - return true; - } - - $transient = self::ERROR_REPORTING_GATE . $error->get_error_code(); - - if ( get_transient( $transient ) ) { - return false; - } - - set_transient( $transient, true, HOUR_IN_SECONDS ); - return true; - } - - /** - * Stores the error in the database so we know there is an issue and can inform the user - * - * @since 1.14.2 - * - * @param \WP_Error $error the error object. - * @return boolean|array False if stored errors were not updated and the error array if it was successfully stored. - */ - public function store_error( \WP_Error $error ) { - - $stored_errors = $this->get_stored_errors(); - $error_array = $this->wp_error_to_array( $error ); - $error_code = $error->get_error_code(); - $user_id = $error_array['user_id']; - - if ( ! isset( $stored_errors[ $error_code ] ) || ! is_array( $stored_errors[ $error_code ] ) ) { - $stored_errors[ $error_code ] = array(); - } - - $stored_errors[ $error_code ][ $user_id ] = $error_array; - - // Let's store a maximum of 5 different user ids for each error code. - $error_code_count = is_countable( $stored_errors[ $error_code ] ) ? count( $stored_errors[ $error_code ] ) : 0; - if ( $error_code_count > 5 ) { - // array_shift will destroy keys here because they are numeric, so manually remove first item. - $keys = array_keys( $stored_errors[ $error_code ] ); - unset( $stored_errors[ $error_code ][ $keys[0] ] ); - } - - if ( update_option( self::STORED_ERRORS_OPTION, $stored_errors ) ) { - return $error_array; - } - - return false; - } - - /** - * Converts a WP_Error object in the array representation we store in the database - * - * @since 1.14.2 - * - * @param \WP_Error $error the error object. - * @return boolean|array False if error is invalid or the error array - */ - public function wp_error_to_array( \WP_Error $error ) { - - $data = $error->get_error_data(); - - if ( ! isset( $data['signature_details'] ) || ! is_array( $data['signature_details'] ) ) { - return false; - } - - $signature_details = $data['signature_details']; - - if ( ! isset( $signature_details['token'] ) ) { - return false; - } - - $user_id = $this->get_user_id_from_token( $signature_details['token'] ); - - $error_array = array( - 'error_code' => $error->get_error_code(), - 'user_id' => $user_id, - 'error_message' => $error->get_error_message(), - 'error_data' => $signature_details, - 'timestamp' => time(), - 'nonce' => wp_generate_password( 10, false ), - 'error_type' => empty( $data['error_type'] ) ? '' : $data['error_type'], - ); - - return $error_array; - } - - /** - * Sends the error to WP.com to be verified - * - * @since 1.14.2 - * - * @param array $error_array The array representation of the error as it is stored in the database. - * @return bool - */ - public function send_error_to_wpcom( $error_array ) { - - $blog_id = \Jetpack_Options::get_option( 'id' ); - - $encrypted_data = $this->encrypt_data_to_wpcom( $error_array ); - - if ( false === $encrypted_data ) { - return false; - } - - $args = array( - 'body' => array( - 'error_data' => $encrypted_data, - ), - ); - - // send encrypted data to WP.com Public-API v2. - wp_remote_post( "https://public-api.wordpress.com/wpcom/v2/sites/{$blog_id}/jetpack-report-error/", $args ); - return true; - } - - /** - * Encrypt data to be sent over to WP.com - * - * @since 1.14.2 - * - * @param array|string $data the data to be encoded. - * @return boolean|string The encoded string on success, false on failure - */ - public function encrypt_data_to_wpcom( $data ) { - - try { - // phpcs:disable WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - // phpcs:disable WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - $encrypted_data = base64_encode( sodium_crypto_box_seal( wp_json_encode( $data ), base64_decode( JETPACK__ERRORS_PUBLIC_KEY ) ) ); - // phpcs:enable WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - // phpcs:enable WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - } catch ( \SodiumException $e ) { - // error encrypting data. - return false; - } - - return $encrypted_data; - } - - /** - * Extracts the user ID from a token - * - * @since 1.14.2 - * - * @param string $token the token used to make the request. - * @return string $the user id or `invalid` if user id not present. - */ - public function get_user_id_from_token( $token ) { - $user_id = 'invalid'; - - if ( $token ) { - $parsed_token = explode( ':', wp_unslash( $token ) ); - - if ( isset( $parsed_token[2] ) && ctype_digit( $parsed_token[2] ) ) { - $user_id = $parsed_token[2]; - } - } - - return $user_id; - } - - /** - * Gets the reported errors stored in the database - * - * @since 1.14.2 - * - * @return array $errors - */ - public function get_stored_errors() { - - $stored_errors = get_option( self::STORED_ERRORS_OPTION ); - - if ( ! is_array( $stored_errors ) ) { - $stored_errors = array(); - } - - $stored_errors = $this->garbage_collector( $stored_errors ); - - return $stored_errors; - } - - /** - * Gets the verified errors stored in the database - * - * @since 1.14.2 - * - * @return array $errors - */ - public function get_verified_errors() { - - $verified_errors = get_option( self::STORED_VERIFIED_ERRORS_OPTION ); - - if ( ! is_array( $verified_errors ) ) { - $verified_errors = array(); - } - - $verified_errors = $this->garbage_collector( $verified_errors ); - - return $verified_errors; - } - - /** - * Removes expired errors from the array - * - * This method is called by get_stored_errors and get_verified errors and filters their result - * Whenever a new error is stored to the database or verified, this will be triggered and the - * expired error will be permantently removed from the database - * - * @since 1.14.2 - * - * @param array $errors array of errors as stored in the database. - * @return array - */ - private function garbage_collector( $errors ) { - foreach ( $errors as $error_code => $users ) { - foreach ( $users as $user_id => $error ) { - if ( self::ERROR_LIFE_TIME < time() - (int) $error['timestamp'] ) { - unset( $errors[ $error_code ][ $user_id ] ); - } - } - } - // Clear empty error codes. - $errors = array_filter( - $errors, - function ( $user_errors ) { - return ! empty( $user_errors ); - } - ); - return $errors; - } - - /** - * Delete all stored and verified errors from the database - * - * @since 1.14.2 - * - * @return void - */ - public function delete_all_errors() { - $this->delete_stored_errors(); - $this->delete_verified_errors(); - } - - /** - * Delete all stored and verified API errors from the database, leave the non-API errors intact. - * - * @since 1.54.0 - * - * @return void - */ - public function delete_all_api_errors() { - $type_filter = function ( $errors ) { - if ( is_array( $errors ) ) { - foreach ( $errors as $key => $error ) { - if ( ! empty( $error['error_type'] ) && in_array( $error['error_type'], array( 'xmlrpc', 'rest' ), true ) ) { - unset( $errors[ $key ] ); - } - } - } - - return count( $errors ) ? $errors : null; - }; - - $stored_errors = $this->get_stored_errors(); - if ( is_array( $stored_errors ) && count( $stored_errors ) ) { - $stored_errors = array_filter( array_map( $type_filter, $stored_errors ) ); - if ( count( $stored_errors ) ) { - update_option( static::STORED_ERRORS_OPTION, $stored_errors ); - } else { - delete_option( static::STORED_ERRORS_OPTION ); - } - } - - $verified_errors = $this->get_verified_errors(); - if ( is_array( $verified_errors ) && count( $verified_errors ) ) { - $verified_errors = array_filter( array_map( $type_filter, $verified_errors ) ); - if ( count( $verified_errors ) ) { - update_option( static::STORED_VERIFIED_ERRORS_OPTION, $verified_errors ); - } else { - delete_option( static::STORED_VERIFIED_ERRORS_OPTION ); - } - } - } - - /** - * Delete all stored and verified errors from the database and returns unfiltered value - * - * This is used to hook into a couple of filters that expect true to not short circuit the disconnection flow - * - * @since 8.9.0 - * - * @param mixed $check The input sent by the filter. - * @return boolean - */ - public function delete_all_errors_and_return_unfiltered_value( $check ) { - $this->delete_all_errors(); - return $check; - } - - /** - * Delete the reported errors stored in the database - * - * @since 1.14.2 - * - * @return boolean True, if option is successfully deleted. False on failure. - */ - public function delete_stored_errors() { - return delete_option( self::STORED_ERRORS_OPTION ); - } - - /** - * Delete the verified errors stored in the database - * - * @since 1.14.2 - * - * @return boolean True, if option is successfully deleted. False on failure. - */ - public function delete_verified_errors() { - return delete_option( self::STORED_VERIFIED_ERRORS_OPTION ); - } - - /** - * Gets an error based on the nonce - * - * Receives a nonce and finds the related error. - * - * @since 1.14.2 - * - * @param string $nonce The nonce created for the error we want to get. - * @return null|array Returns the error array representation or null if error not found. - */ - public function get_error_by_nonce( $nonce ) { - $errors = $this->get_stored_errors(); - foreach ( $errors as $user_group ) { - foreach ( $user_group as $error ) { - if ( $error['nonce'] === $nonce ) { - return $error; - } - } - } - return null; - } - - /** - * Adds an error to the verified error list - * - * @since 1.14.2 - * - * @param array $error The error array, as it was saved in the unverified errors list. - * @return void - */ - public function verify_error( $error ) { - - $verified_errors = $this->get_verified_errors(); - $error_code = $error['error_code']; - $user_id = $error['user_id']; - - if ( ! isset( $verified_errors[ $error_code ] ) ) { - $verified_errors[ $error_code ] = array(); - } - - $verified_errors[ $error_code ][ $user_id ] = $error; - - update_option( self::STORED_VERIFIED_ERRORS_OPTION, $verified_errors ); - } - - /** - * Register REST API end point for error hanlding. - * - * @since 1.14.2 - * - * @return void - */ - public function register_verify_error_endpoint() { - register_rest_route( - 'jetpack/v4', - '/verify_xmlrpc_error', - array( - 'methods' => \WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'verify_xml_rpc_error' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'nonce' => array( - 'required' => true, - 'type' => 'string', - ), - ), - ) - ); - } - - /** - * Handles verification that a xml rpc error is legit and came from WordPres.com - * - * @since 1.14.2 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return boolean - */ - public function verify_xml_rpc_error( \WP_REST_Request $request ) { - $error = $this->get_error_by_nonce( $request['nonce'] ); - - if ( $error ) { - $this->verify_error( $error ); - return new \WP_REST_Response( true, 200 ); - } - - return new \WP_REST_Response( false, 200 ); - } - - /** - * Prints a generic error notice for all connection errors - * - * @since 8.9.0 - * - * @return void - */ - public function generic_admin_notice_error() { - // do not add admin notice to the jetpack dashboard. - global $pagenow; - if ( 'admin.php' === $pagenow || isset( $_GET['page'] ) && 'jetpack' === $_GET['page'] ) { // phpcs:ignore - return; - } - - if ( ! current_user_can( 'jetpack_connect' ) ) { - return; - } - - /** - * Filters the message to be displayed in the admin notices area when there's a connection error. - * - * By default we don't display any errors. - * - * Return an empty value to disable the message. - * - * @since 8.9.0 - * - * @param string $message The error message. - * @param array $errors The array of errors. See Automattic\Jetpack\Connection\Error_Handler for details on the array structure. - */ - $message = apply_filters( 'jetpack_connection_error_notice_message', '', $this->get_verified_errors() ); - - /** - * Fires inside the admin_notices hook just before displaying the error message for a broken connection. - * - * If you want to disable the default message from being displayed, return an empty value in the jetpack_connection_error_notice_message filter. - * - * @since 8.9.0 - * - * @param array $errors The array of errors. See Automattic\Jetpack\Connection\Error_Handler for details on the array structure. - */ - do_action( 'jetpack_connection_error_notice', $this->get_verified_errors() ); - - if ( empty( $message ) ) { - return; - } - - wp_admin_notice( - esc_html( $message ), - array( - 'type' => 'error', - 'dismissible' => true, - 'additional_classes' => array( 'jetpack-message', 'jp-connect' ), - 'attributes' => array( 'style' => 'display:block !important;' ), - ) - ); - } - - /** - * Adds the error message to the Jetpack React Dashboard - * - * @since 8.9.0 - * - * @param array $errors The array of errors. See Automattic\Jetpack\Connection\Error_Handler for details on the array structure. - * @return array - */ - public function jetpack_react_dashboard_error( $errors ) { - $errors[] = array( - 'code' => 'connection_error', - 'message' => __( 'Your connection with WordPress.com seems to be broken. If you\'re experiencing issues, please try reconnecting.', 'jetpack-connection' ), - 'action' => 'reconnect', - 'data' => array( 'api_error_code' => $this->error_code ), - ); - return $errors; - } - - /** - * Check REST API response for errors, and report them to WP.com if needed. - * - * @see wp_remote_request() For more information on the $http_response array format. - * @param array|\WP_Error $http_response The response or WP_Error on failure. - * @param array $auth_data Auth data, allowed keys: `token`, `timestamp`, `nonce`, `body-hash`. - * @param string $url Request URL. - * @param string $method Request method. - * @param string $error_type The source of an error: 'xmlrpc' or 'rest'. - * - * @return void - */ - public function check_api_response_for_errors( $http_response, $auth_data, $url, $method, $error_type ) { - if ( 200 === wp_remote_retrieve_response_code( $http_response ) || ! is_array( $auth_data ) || ! $url || ! $method ) { - return; - } - - $body_raw = wp_remote_retrieve_body( $http_response ); - if ( ! $body_raw ) { - return; - } - - $body = json_decode( $body_raw, true ); - if ( empty( $body['error'] ) || ( ! is_string( $body['error'] ) && ! is_int( $body['error'] ) ) ) { - return; - } - - $error = new \WP_Error( - $body['error'], - empty( $body['message'] ) ? '' : $body['message'], - array( - 'signature_details' => array( - 'token' => empty( $auth_data['token'] ) ? '' : $auth_data['token'], - 'timestamp' => empty( $auth_data['timestamp'] ) ? '' : $auth_data['timestamp'], - 'nonce' => empty( $auth_data['nonce'] ) ? '' : $auth_data['nonce'], - 'body_hash' => empty( $auth_data['body_hash'] ) ? '' : $auth_data['body_hash'], - 'method' => $method, - 'url' => $url, - ), - 'error_type' => in_array( $error_type, array( 'xmlrpc', 'rest' ), true ) ? $error_type : '', - ) - ); - - $this->report_error( $error, false, true ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php deleted file mode 100644 index cc32b536..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php +++ /dev/null @@ -1,310 +0,0 @@ -cron_name, array( $this, 'cron_exec' ) ); - - if ( ! wp_next_scheduled( $this->cron_name ) ) { - // Deal with the old pre-3.0 weekly one. - $timestamp = wp_next_scheduled( 'jetpack_heartbeat' ); - if ( $timestamp ) { - wp_unschedule_event( $timestamp, 'jetpack_heartbeat' ); - } - - wp_schedule_event( time(), 'daily', $this->cron_name ); - } - - add_filter( 'jetpack_xmlrpc_unauthenticated_methods', array( __CLASS__, 'jetpack_xmlrpc_methods' ) ); - - if ( defined( 'WP_CLI' ) && WP_CLI ) { - WP_CLI::add_command( 'jetpack-heartbeat', array( $this, 'cli_callback' ) ); - } - - add_action( 'rest_api_init', array( $this, 'initialize_rest_api' ) ); - } - - /** - * Method that gets executed on the wp-cron call - * - * @since 1.0.0 - * @since-jetpack 2.3.3 - * @global string $wp_version - */ - public function cron_exec() { - - $a8c_mc_stats = new A8c_Mc_Stats(); - - /* - * This should run daily. Figuring in for variances in - * WP_CRON, don't let it run more than every 23 hours at most. - * - * i.e. if it ran less than 23 hours ago, fail out. - */ - $last = (int) Jetpack_Options::get_option( 'last_heartbeat' ); - if ( $last && ( $last + DAY_IN_SECONDS - HOUR_IN_SECONDS > time() ) ) { - return; - } - - /* - * Check for an identity crisis - * - * If one exists: - * - Bump stat for ID crisis - * - Email site admin about potential ID crisis - */ - - // Coming Soon! - - foreach ( self::generate_stats_array( 'v2-' ) as $key => $value ) { - if ( is_array( $value ) ) { - foreach ( $value as $v ) { - $a8c_mc_stats->add( $key, (string) $v ); - } - } else { - $a8c_mc_stats->add( $key, (string) $value ); - } - } - - Jetpack_Options::update_option( 'last_heartbeat', time() ); - - $a8c_mc_stats->do_server_side_stats(); - - /** - * Fires when we synchronize all registered options on heartbeat. - * - * @since 3.3.0 - */ - do_action( 'jetpack_heartbeat' ); - } - - /** - * Generates heartbeat stats data. - * - * @param string $prefix Prefix to add before stats identifier. - * - * @return array The stats array. - */ - public static function generate_stats_array( $prefix = '' ) { - - /** - * This filter is used to build the array of stats that are bumped once a day by Jetpack Heartbeat. - * - * Filter the array and add key => value pairs where - * * key is the stat group name - * * value is the stat name. - * - * Example: - * add_filter( 'jetpack_heartbeat_stats_array', function( $stats ) { - * $stats['is-https'] = is_ssl() ? 'https' : 'http'; - * }); - * - * This will bump the stats for the 'is-https/https' or 'is-https/http' stat. - * - * @param array $stats The stats to be filtered. - * @param string $prefix The prefix that will automatically be added at the begining at each stat group name. - */ - $stats = apply_filters( 'jetpack_heartbeat_stats_array', array(), $prefix ); - $return = array(); - - // Apply prefix to stats. - foreach ( $stats as $stat => $value ) { - $return[ "$prefix$stat" ] = $value; - } - - return $return; - } - - /** - * Registers jetpack.getHeartbeatData xmlrpc method - * - * @param array $methods The list of methods to be filtered. - * @return array $methods - */ - public static function jetpack_xmlrpc_methods( $methods ) { - $methods['jetpack.getHeartbeatData'] = array( __CLASS__, 'xmlrpc_data_response' ); - return $methods; - } - - /** - * Handles the response for the jetpack.getHeartbeatData xmlrpc method - * - * @param array $params The parameters received in the request. - * @return array $params all the stats that heartbeat handles. - */ - public static function xmlrpc_data_response( $params = array() ) { - // The WordPress XML-RPC server sets a default param of array() - // if no argument is passed on the request and the method handlers get this array in $params. - // generate_stats_array() needs a string as first argument. - $params = empty( $params ) ? '' : $params; - return self::generate_stats_array( $params ); - } - - /** - * Clear scheduled events - * - * @return void - */ - public function deactivate() { - // Deal with the old pre-3.0 weekly one. - $timestamp = wp_next_scheduled( 'jetpack_heartbeat' ); - if ( $timestamp ) { - wp_unschedule_event( $timestamp, 'jetpack_heartbeat' ); - } - - $timestamp = wp_next_scheduled( $this->cron_name ); - wp_unschedule_event( $timestamp, $this->cron_name ); - } - - /** - * Interact with the Heartbeat - * - * ## OPTIONS - * - * inspect (default): Gets the list of data that is going to be sent in the heartbeat and the date/time of the last heartbeat - * - * @param array $args Arguments passed via CLI. - * - * @return void - */ - public function cli_callback( $args ) { - - $allowed_args = array( - 'inspect', - ); - - if ( isset( $args[0] ) && ! in_array( $args[0], $allowed_args, true ) ) { - /* translators: %s is a command like "prompt" */ - WP_CLI::error( sprintf( __( '%s is not a valid command.', 'jetpack-connection' ), $args[0] ) ); - } - - $stats = self::generate_stats_array(); - $formatted_stats = array(); - - foreach ( $stats as $stat_name => $bin ) { - $formatted_stats[] = array( - 'Stat name' => $stat_name, - 'Bin' => $bin, - ); - } - - WP_CLI\Utils\format_items( 'table', $formatted_stats, array( 'Stat name', 'Bin' ) ); - - $last_heartbeat = Jetpack_Options::get_option( 'last_heartbeat' ); - - if ( $last_heartbeat ) { - $last_date = gmdate( 'Y-m-d H:i:s', $last_heartbeat ); - /* translators: %s is the full datetime of the last heart beat e.g. 2020-01-01 12:21:23 */ - WP_CLI::line( sprintf( __( 'Last heartbeat sent at: %s', 'jetpack-connection' ), $last_date ) ); - } - } - - /** - * Initialize the heartbeat REST API. - * - * @return void - */ - public function initialize_rest_api() { - register_rest_route( - 'jetpack/v4', - '/heartbeat/data', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( $this, 'rest_heartbeat_data' ), - 'permission_callback' => array( $this, 'rest_heartbeat_data_permission_check' ), - 'args' => array( - 'prefix' => array( - 'description' => __( 'Prefix to add before the stats identifiers.', 'jetpack-connection' ), - 'type' => 'string', - ), - ), - ) - ); - } - - /** - * Endpoint to retrieve the heartbeat data. - * - * @param WP_REST_Request $request The request data. - * - * @since 2.7.0 - * - * @return array - */ - public function rest_heartbeat_data( WP_REST_Request $request ) { - return static::generate_stats_array( $request->get_param( 'prefix' ) ); - } - - /** - * Check permissions for the `get_heartbeat_data` endpoint. - * - * @return true|WP_Error - */ - public function rest_heartbeat_data_permission_check() { - if ( current_user_can( 'jetpack_connect' ) ) { - return true; - } - - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'invalid_permission_heartbeat_data', REST_Connector::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php deleted file mode 100644 index 5f44ab4a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php +++ /dev/null @@ -1,73 +0,0 @@ - esc_url_raw( rest_url() ), - 'apiNonce' => wp_create_nonce( 'wp_rest' ), - 'registrationNonce' => wp_create_nonce( 'jetpack-registration-nonce' ), - 'connectionStatus' => REST_Connector::connection_status( false ), - 'userConnectionData' => REST_Connector::get_user_connection_data( false ), - 'connectedPlugins' => REST_Connector::get_connection_plugins( false ), - 'wpVersion' => $wp_version, - 'siteSuffix' => $status->get_site_suffix(), - 'connectionErrors' => Error_Handler::get_instance()->get_verified_errors(), - 'isOfflineMode' => $status->is_offline_mode(), - 'calypsoEnv' => ( new Status\Host() )->get_calypso_env(), - ); - } - - /** - * Set the connection script data. - * - * @param array $data The script data. - */ - public static function set_connection_script_data( $data ) { - - $data['connection'] = self::get_data(); - - return $data; - } - - /** - * Render the initial state into a JavaScript variable. - * - * @return string - */ - public static function render() { - return 'var JP_CONNECTION_INITIAL_STATE; typeof JP_CONNECTION_INITIAL_STATE === "object" || (JP_CONNECTION_INITIAL_STATE = JSON.parse(decodeURIComponent("' . rawurlencode( wp_json_encode( self::get_data() ) ) . '")));'; - } - - /** - * Render the initial state using an inline script. - * - * @param string $handle The JS script handle. - * - * @return void - */ - public static function render_script( $handle ) { - wp_add_inline_script( $handle, static::render(), 'before' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php deleted file mode 100644 index 73af0210..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php +++ /dev/null @@ -1,2768 +0,0 @@ -set_plugin_instance( new Plugin( $plugin_slug ) ); - } - } - - /** - * Initializes required listeners. This is done separately from the constructors - * because some objects sometimes need to instantiate separate objects of this class. - * - * @todo Implement a proper nonce verification. - */ - public static function configure() { - $manager = new self(); - - add_filter( - 'jetpack_constant_default_value', - __NAMESPACE__ . '\Utils::jetpack_api_constant_filter', - 10, - 2 - ); - - $manager->setup_xmlrpc_handlers( - null, - $manager->has_connected_owner(), - $manager->verify_xml_rpc_signature() - ); - - $manager->error_handler = Error_Handler::get_instance(); - - if ( $manager->is_connected() ) { - add_filter( 'xmlrpc_methods', array( $manager, 'public_xmlrpc_methods' ) ); - add_filter( 'shutdown', array( new Package_Version_Tracker(), 'maybe_update_package_versions' ) ); - } - - // This runs on priority 11 - at least one api method in the connection package is set to override a previously - // existing method from the Jetpack plugin. Running later than Jetpack's api init ensures the override is successful. - add_action( 'rest_api_init', array( $manager, 'initialize_rest_api_registration_connector' ), 11 ); - - ( new Nonce_Handler() )->init_schedule(); - - add_action( 'plugins_loaded', __NAMESPACE__ . '\Plugin_Storage::configure', 100 ); - - add_filter( 'map_meta_cap', array( $manager, 'jetpack_connection_custom_caps' ), 1, 4 ); - - Heartbeat::init(); - add_filter( 'jetpack_heartbeat_stats_array', array( $manager, 'add_stats_to_heartbeat' ) ); - - Webhooks::init( $manager ); - - // Unlink user before deleting the user from WP.com. - add_action( 'deleted_user', array( $manager, 'disconnect_user_force' ), 9, 1 ); - add_action( 'remove_user_from_blog', array( $manager, 'disconnect_user_force' ), 9, 1 ); - - $manager->add_connection_status_invalidation_hooks(); - - // Set up package version hook. - add_filter( 'jetpack_package_versions', __NAMESPACE__ . '\Package_Version::send_package_version_to_tracker' ); - - if ( defined( 'JETPACK__SANDBOX_DOMAIN' ) && JETPACK__SANDBOX_DOMAIN ) { - ( new Server_Sandbox() )->init(); - } - - // Initialize connection notices. - new Connection_Notice(); - - // Initialize token locks. - new Tokens_Locks(); - - // Initial Partner management. - Partner::init(); - } - - /** - * Adds hooks to invalidate the memoized connection status. - */ - private function add_connection_status_invalidation_hooks() { - if ( self::$connection_invalidators_added ) { - return; - } - - // Force is_connected() to recompute after important actions. - add_action( 'jetpack_site_registered', array( $this, 'reset_connection_status' ) ); - add_action( 'jetpack_site_disconnected', array( $this, 'reset_connection_status' ) ); - add_action( 'jetpack_sync_register_user', array( $this, 'reset_connection_status' ) ); - add_action( 'pre_update_jetpack_option_id', array( $this, 'reset_connection_status' ) ); - add_action( 'pre_update_jetpack_option_blog_token', array( $this, 'reset_connection_status' ) ); - add_action( 'pre_update_jetpack_option_user_token', array( $this, 'reset_connection_status' ) ); - add_action( 'pre_update_jetpack_option_user_tokens', array( $this, 'reset_connection_status' ) ); - // phpcs:ignore WPCUT.SwitchBlog.SwitchBlog -- wpcom flags **every** use of switch_blog, apparently expecting valid instances to ignore or suppress the sniff. - add_action( 'switch_blog', array( $this, 'reset_connection_status' ) ); - - self::$connection_invalidators_added = true; - } - - /** - * Sets up the XMLRPC request handlers. - * - * @since 1.25.0 Deprecate $is_active param. - * @since 2.8.4 Deprecate $request_params param. - * - * @param array|null $deprecated Deprecated. Not used. - * @param bool $has_connected_owner Whether the site has a connected owner. - * @param bool $is_signed whether the signature check has been successful. - * @param Jetpack_XMLRPC_Server $xmlrpc_server (optional) an instance of the server to use instead of instantiating a new one. - */ - public function setup_xmlrpc_handlers( - $deprecated, - $has_connected_owner, - $is_signed, - ?Jetpack_XMLRPC_Server $xmlrpc_server = null - ) { - add_filter( 'xmlrpc_blog_options', array( $this, 'xmlrpc_options' ), 1000, 2 ); - if ( $deprecated !== null ) { - _deprecated_argument( __METHOD__, '2.8.4' ); - } - // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- We are using the 'for' request param to early return unless it's 'jetpack'. - if ( ! isset( $_GET['for'] ) || 'jetpack' !== $_GET['for'] ) { - return false; - } - - // Alternate XML-RPC, via ?for=jetpack&jetpack=comms. - // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- This just determines whether to handle the request as an XML-RPC request. The actual XML-RPC endpoints do the appropriate nonce checking where applicable. Plus we make sure to clear all cookies via require_jetpack_authentication called later in method. - if ( isset( $_GET['jetpack'] ) && 'comms' === $_GET['jetpack'] ) { - if ( ! Constants::is_defined( 'XMLRPC_REQUEST' ) ) { - // Use the real constant here for WordPress' sake. - define( 'XMLRPC_REQUEST', true ); - } - - add_action( 'template_redirect', array( $this, 'alternate_xmlrpc' ) ); - - add_filter( 'xmlrpc_methods', array( $this, 'remove_non_jetpack_xmlrpc_methods' ), 1000 ); - } - - if ( ! Constants::get_constant( 'XMLRPC_REQUEST' ) ) { - return false; - } - - // Display errors can cause the XML to be not well formed. - // This only affects Jetpack XML-RPC endpoints received from WordPress.com servers. - // All other XML-RPC requests are unaffected. - @ini_set( 'display_errors', false ); // phpcs:ignore - - if ( $xmlrpc_server ) { - $this->xmlrpc_server = $xmlrpc_server; - } else { - $this->xmlrpc_server = new Jetpack_XMLRPC_Server(); - } - - $this->require_jetpack_authentication(); - - if ( $is_signed ) { - // If the site is connected either at a site or user level and the request is signed, expose the methods. - // The callback is responsible to determine whether the request is signed with blog or user token and act accordingly. - // The actual API methods. - $callback = array( $this->xmlrpc_server, 'xmlrpc_methods' ); - - // Hack to preserve $HTTP_RAW_POST_DATA. - add_filter( 'xmlrpc_methods', array( $this, 'xmlrpc_methods' ) ); - - } elseif ( $has_connected_owner && ! $is_signed ) { - // The jetpack.authorize method should be available for unauthenticated users on a site with an - // active Jetpack connection, so that additional users can link their account. - $callback = array( $this->xmlrpc_server, 'authorize_xmlrpc_methods' ); - } else { - // Any other unsigned request should expose the bootstrap methods. - $callback = array( $this->xmlrpc_server, 'bootstrap_xmlrpc_methods' ); - new XMLRPC_Connector( $this ); - } - - add_filter( 'xmlrpc_methods', $callback ); - - // Now that no one can authenticate, and we're whitelisting all XML-RPC methods, force enable_xmlrpc on. - add_filter( 'pre_option_enable_xmlrpc', '__return_true' ); - return true; - } - - /** - * Initializes the REST API connector on the init hook. - */ - public function initialize_rest_api_registration_connector() { - new REST_Connector( $this ); - } - - /** - * Since a lot of hosts use a hammer approach to "protecting" WordPress sites, - * and just blanket block all requests to /xmlrpc.php, or apply other overly-sensitive - * security/firewall policies, we provide our own alternate XML RPC API endpoint - * which is accessible via a different URI. Most of the below is copied directly - * from /xmlrpc.php so that we're replicating it as closely as possible. - * - * @todo Tighten $wp_xmlrpc_server_class a bit to make sure it doesn't do bad things. - * - * @return never - */ - public function alternate_xmlrpc() { - // Some browser-embedded clients send cookies. We don't want them. - $_COOKIE = array(); - - include_once ABSPATH . 'wp-admin/includes/admin.php'; - include_once ABSPATH . WPINC . '/class-IXR.php'; - include_once ABSPATH . WPINC . '/class-wp-xmlrpc-server.php'; - - /** - * Filters the class used for handling XML-RPC requests. - * - * @since 1.7.0 - * @since-jetpack 3.1.0 - * - * @param string $class The name of the XML-RPC server class. - */ - $wp_xmlrpc_server_class = apply_filters( 'wp_xmlrpc_server_class', 'wp_xmlrpc_server' ); - $wp_xmlrpc_server = new $wp_xmlrpc_server_class(); - - // Fire off the request. - nocache_headers(); - $wp_xmlrpc_server->serve_request(); - - exit( 0 ); - } - - /** - * Removes all XML-RPC methods that are not `jetpack.*`. - * Only used in our alternate XML-RPC endpoint, where we want to - * ensure that Core and other plugins' methods are not exposed. - * - * @param array $methods a list of registered WordPress XMLRPC methods. - * @return array filtered $methods - */ - public function remove_non_jetpack_xmlrpc_methods( $methods ) { - $jetpack_methods = array(); - - foreach ( $methods as $method => $callback ) { - if ( str_starts_with( $method, 'jetpack.' ) ) { - $jetpack_methods[ $method ] = $callback; - } - } - - return $jetpack_methods; - } - - /** - * Removes all other authentication methods not to allow other - * methods to validate unauthenticated requests. - */ - public function require_jetpack_authentication() { - // Don't let anyone authenticate. - $_COOKIE = array(); - remove_all_filters( 'authenticate' ); - remove_all_actions( 'wp_login_failed' ); - - if ( $this->is_connected() ) { - // Allow Jetpack authentication. - add_filter( 'authenticate', array( $this, 'authenticate_jetpack' ), 10, 3 ); - } - } - - /** - * Authenticates XML-RPC and other requests from the Jetpack Server - * - * @param WP_User|Mixed $user user object if authenticated. - * @param String $username username. - * @param String $password password string. - * @return WP_User|Mixed authenticated user or error. - */ - public function authenticate_jetpack( $user, $username, $password ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - if ( is_a( $user, '\\WP_User' ) ) { - return $user; - } - - $token_details = $this->verify_xml_rpc_signature(); - - if ( ! $token_details ) { - return $user; - } - - if ( 'user' !== $token_details['type'] ) { - return $user; - } - - if ( ! $token_details['user_id'] ) { - return $user; - } - - nocache_headers(); - - return new \WP_User( $token_details['user_id'] ); - } - - /** - * Verifies the signature of the current request. - * - * @return false|array - */ - public function verify_xml_rpc_signature() { - if ( $this->xmlrpc_verification === null ) { - $this->xmlrpc_verification = $this->internal_verify_xml_rpc_signature(); - - if ( is_wp_error( $this->xmlrpc_verification ) ) { - /** - * Action for logging XMLRPC signature verification errors. This data is sensitive. - * - * @since 1.7.0 - * @since-jetpack 7.5.0 - * - * @param WP_Error $signature_verification_error The verification error - */ - do_action( 'jetpack_verify_signature_error', $this->xmlrpc_verification ); - - Error_Handler::get_instance()->report_error( $this->xmlrpc_verification ); - - } - } - - return is_wp_error( $this->xmlrpc_verification ) ? false : $this->xmlrpc_verification; - } - - /** - * Verifies the signature of the current request. - * - * This function has side effects and should not be used. Instead, - * use the memoized version `->verify_xml_rpc_signature()`. - * - * @internal - * @todo Refactor to use proper nonce verification. - */ - private function internal_verify_xml_rpc_signature() { - // phpcs:disable WordPress.Security.NonceVerification.Recommended, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - // It's not for us. - if ( ! isset( $_GET['token'] ) || empty( $_GET['signature'] ) ) { - return false; - } - - $signature_details = array( - 'token' => isset( $_GET['token'] ) ? wp_unslash( $_GET['token'] ) : '', - 'timestamp' => isset( $_GET['timestamp'] ) ? wp_unslash( $_GET['timestamp'] ) : '', - 'nonce' => isset( $_GET['nonce'] ) ? wp_unslash( $_GET['nonce'] ) : '', - 'body_hash' => isset( $_GET['body-hash'] ) ? wp_unslash( $_GET['body-hash'] ) : '', - 'method' => isset( $_SERVER['REQUEST_METHOD'] ) ? wp_unslash( $_SERVER['REQUEST_METHOD'] ) : null, - 'url' => wp_unslash( ( isset( $_SERVER['HTTP_HOST'] ) ? $_SERVER['HTTP_HOST'] : null ) . ( isset( $_SERVER['REQUEST_URI'] ) ? $_SERVER['REQUEST_URI'] : null ) ), // Temp - will get real signature URL later. - 'signature' => isset( $_GET['signature'] ) ? wp_unslash( $_GET['signature'] ) : '', - ); - - $error_type = 'xmlrpc'; - - // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged - @list( $token_key, $version, $user_id ) = explode( ':', wp_unslash( $_GET['token'] ) ); - // phpcs:enable WordPress.Security.NonceVerification.Recommended, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - - $jetpack_api_version = Constants::get_constant( 'JETPACK__API_VERSION' ); - - if ( - empty( $token_key ) - || empty( $version ) - || (string) $jetpack_api_version !== $version - ) { - return new \WP_Error( 'malformed_token', 'Malformed token in request', compact( 'signature_details', 'error_type' ) ); - } - - if ( '0' === $user_id ) { - $token_type = 'blog'; - $user_id = 0; - } else { - $token_type = 'user'; - if ( empty( $user_id ) || ! ctype_digit( $user_id ) ) { - return new \WP_Error( - 'malformed_user_id', - 'Malformed user_id in request', - compact( 'signature_details', 'error_type' ) - ); - } - $user_id = (int) $user_id; - - $user = new \WP_User( $user_id ); - if ( ! $user || ! $user->exists() ) { - return new \WP_Error( - 'unknown_user', - sprintf( 'User %d does not exist', $user_id ), - compact( 'signature_details', 'error_type' ) - ); - } - } - - $token = $this->get_tokens()->get_access_token( $user_id, $token_key, false ); - if ( is_wp_error( $token ) ) { - $token->add_data( compact( 'signature_details', 'error_type' ) ); - return $token; - } elseif ( ! $token ) { - return new \WP_Error( - 'unknown_token', - sprintf( 'Token %s:%s:%d does not exist', $token_key, $version, $user_id ), - compact( 'signature_details', 'error_type' ) - ); - } - - $jetpack_signature = new \Jetpack_Signature( $token->secret, (int) \Jetpack_Options::get_option( 'time_diff' ) ); - // phpcs:disable WordPress.Security.NonceVerification.Missing -- Used to verify a cryptographic signature of the post data. Also a nonce is verified later in the function. - if ( isset( $_POST['_jetpack_is_multipart'] ) ) { - $post_data = $_POST; // We need all of $_POST in order to verify a cryptographic signature of the post data. - $file_hashes = array(); - foreach ( $post_data as $post_data_key => $post_data_value ) { - if ( ! str_starts_with( $post_data_key, '_jetpack_file_hmac_' ) ) { - continue; - } - $post_data_key = substr( $post_data_key, strlen( '_jetpack_file_hmac_' ) ); - $file_hashes[ $post_data_key ] = $post_data_value; - } - - foreach ( $file_hashes as $post_data_key => $post_data_value ) { - unset( $post_data[ "_jetpack_file_hmac_{$post_data_key}" ] ); - $post_data[ $post_data_key ] = $post_data_value; - } - - ksort( $post_data ); - - $body = http_build_query( stripslashes_deep( $post_data ) ); - } elseif ( $this->raw_post_data === null ) { - $body = file_get_contents( 'php://input' ); - } else { - $body = null; - } - // phpcs:enable - - $signature = $jetpack_signature->sign_current_request( - array( 'body' => $body === null ? $this->raw_post_data : $body ) - ); - - $signature_details['url'] = $jetpack_signature->current_request_url; - - if ( ! $signature ) { - return new \WP_Error( - 'could_not_sign', - 'Unknown signature error', - compact( 'signature_details', 'error_type' ) - ); - } elseif ( is_wp_error( $signature ) ) { - return $signature; - } - - // phpcs:disable WordPress.Security.NonceVerification.Recommended - $timestamp = (int) $_GET['timestamp']; - $nonce = wp_unslash( (string) $_GET['nonce'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- WP Core doesn't sanitize nonces either. - // phpcs:enable WordPress.Security.NonceVerification.Recommended - - // Use up the nonce regardless of whether the signature matches. - if ( ! ( new Nonce_Handler() )->add( $timestamp, $nonce ) ) { - return new \WP_Error( - 'invalid_nonce', - 'Could not add nonce', - compact( 'signature_details', 'error_type' ) - ); - } - - // Be careful about what you do with this debugging data. - // If a malicious requester has access to the expected signature, - // bad things might be possible. - $signature_details['expected'] = $signature; - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! hash_equals( $signature, wp_unslash( $_GET['signature'] ) ) ) { - return new \WP_Error( - 'signature_mismatch', - 'Signature mismatch', - compact( 'signature_details', 'error_type' ) - ); - } - - /** - * Action for additional token checking. - * - * @since 1.7.0 - * @since-jetpack 7.7.0 - * - * @param array $post_data request data. - * @param array $token_data token data. - */ - return apply_filters( - 'jetpack_signature_check_token', - array( - 'type' => $token_type, - 'token_key' => $token_key, - 'user_id' => $token->external_user_id, - ), - $token, - $this->raw_post_data - ); - } - - /** - * Returns true if the current site is connected to WordPress.com and has the minimum requirements to enable Jetpack UI. - * - * This method is deprecated since version 1.25.0 of this package. Please use has_connected_owner instead. - * - * Since this method has a wide spread use, we decided not to throw any deprecation warnings for now. - * - * @deprecated 1.25.0 - * @see Manager::has_connected_owner - * @return Boolean is the site connected? - */ - public function is_active() { - return (bool) $this->get_tokens()->get_access_token( true ); - } - - /** - * Obtains an instance of the Tokens class. - * - * @return Tokens the Tokens object - */ - public function get_tokens() { - return new Tokens(); - } - - /** - * Returns true if the site has both a token and a blog id, which indicates a site has been registered. - * - * @access public - * @deprecated 1.12.1 Use is_connected instead - * @see Manager::is_connected - * - * @return bool - */ - public function is_registered() { - _deprecated_function( __METHOD__, '1.12.1' ); - return $this->is_connected(); - } - - /** - * Returns true if the site has both a token and a blog id, which indicates a site has been connected. - * - * @access public - * @since 1.21.1 - * - * @return bool - */ - public function is_connected() { - if ( self::$is_connected === null ) { - if ( ! self::$connection_invalidators_added ) { - $this->add_connection_status_invalidation_hooks(); - } - - $has_blog_id = (bool) \Jetpack_Options::get_option( 'id' ); - if ( $has_blog_id ) { - $has_blog_token = (bool) $this->get_tokens()->get_access_token(); - self::$is_connected = ( $has_blog_id && $has_blog_token ); - } else { - // Short-circuit, no need to check for tokens if there's no blog ID. - self::$is_connected = false; - } - } - return self::$is_connected; - } - - /** - * Resets the memoized connection status. - * This will force the connection status to be recomputed on the next check. - * - * @since 5.0.0 - */ - public function reset_connection_status() { - self::$is_connected = null; - } - - /** - * Returns true if the site has at least one connected administrator. - * - * @access public - * @since 1.21.1 - * - * @return bool - */ - public function has_connected_admin() { - return (bool) count( $this->get_connected_users( 'manage_options' ) ); - } - - /** - * Returns true if the site has any connected user. - * - * @access public - * @since 1.21.1 - * - * @return bool - */ - public function has_connected_user() { - return (bool) count( $this->get_connected_users( 'any', 1 ) ); - } - - /** - * Returns an array of users that have user tokens for communicating with wpcom. - * Able to select by specific capability. - * - * @since 9.9.1 Added $limit parameter. - * - * @param string $capability The capability of the user. - * @param int|null $limit How many connected users to get before returning. - * @return WP_User[] Array of WP_User objects if found. - */ - public function get_connected_users( $capability = 'any', $limit = null ) { - $connected_users = array(); - $user_tokens = $this->get_tokens()->get_user_tokens(); - - if ( ! is_array( $user_tokens ) || empty( $user_tokens ) ) { - return $connected_users; - } - $connected_user_ids = array_keys( $user_tokens ); - - if ( ! empty( $connected_user_ids ) ) { - foreach ( $connected_user_ids as $id ) { - // Check for capability. - if ( 'any' !== $capability && ! user_can( $id, $capability ) ) { - continue; - } - - $user_data = get_userdata( $id ); - if ( $user_data instanceof \WP_User ) { - $connected_users[] = $user_data; - if ( $limit && count( $connected_users ) >= $limit ) { - return $connected_users; - } - } - } - } - - return $connected_users; - } - - /** - * Returns true if the site has a connected Blog owner (master_user). - * - * @access public - * @since 1.21.1 - * - * @return bool - */ - public function has_connected_owner() { - return (bool) $this->get_connection_owner_id(); - } - - /** - * Returns true if the site is connected only at a site level. - * - * Note that we are explicitly checking for the existence of the master_user option in order to account for cases where we don't have any user tokens (user-level connection) but the master_user option is set, which could be the result of a problematic user connection. - * - * @access public - * @since 1.25.0 - * @deprecated 1.27.0 - * - * @return bool - */ - public function is_userless() { - _deprecated_function( __METHOD__, '1.27.0', 'Automattic\\Jetpack\\Connection\\Manager::is_site_connection' ); - return $this->is_site_connection(); - } - - /** - * Returns true if the site is connected only at a site level. - * - * Note that we are explicitly checking for the existence of the master_user option in order to account for cases where we don't have any user tokens (user-level connection) but the master_user option is set, which could be the result of a problematic user connection. - * - * @access public - * @since 1.27.0 - * - * @return bool - */ - public function is_site_connection() { - return $this->is_connected() && ! $this->has_connected_user() && ! \Jetpack_Options::get_option( 'master_user' ); - } - - /** - * Checks to see if the connection owner of the site is missing. - * - * @return bool - */ - public function is_missing_connection_owner() { - $connection_owner = $this->get_connection_owner_id(); - if ( ! get_user_by( 'id', $connection_owner ) ) { - return true; - } - - return false; - } - - /** - * Returns true if the user with the specified identifier is connected to - * WordPress.com. - * - * @param int $user_id the user identifier. Default is the current user. - * @return bool Boolean is the user connected? - */ - public function is_user_connected( $user_id = false ) { - $user_id = false === $user_id ? get_current_user_id() : absint( $user_id ); - if ( ! $user_id ) { - return false; - } - - return (bool) $this->get_tokens()->get_access_token( $user_id ); - } - - /** - * Returns the local user ID of the connection owner. - * - * @return bool|int Returns the ID of the connection owner or False if no connection owner found. - */ - public function get_connection_owner_id() { - $owner = $this->get_connection_owner(); - return $owner instanceof \WP_User ? $owner->ID : false; - } - - /** - * Get the wpcom user data of the current|specified connected user. - * - * @todo Refactor to properly load the XMLRPC client independently. - * - * @param Integer $user_id the user identifier. - * @return bool|array An array with the WPCOM user data on success, false otherwise. - */ - public function get_connected_user_data( $user_id = null ) { - if ( ! $user_id ) { - $user_id = get_current_user_id(); - } - - // Check if the user is connected and return false otherwise. - if ( ! $this->is_user_connected( $user_id ) ) { - return false; - } - - $transient_key = "jetpack_connected_user_data_$user_id"; - $cached_user_data = get_transient( $transient_key ); - - if ( $cached_user_data ) { - return $cached_user_data; - } - - $xml = new Jetpack_IXR_Client( - array( - 'user_id' => $user_id, - ) - ); - $xml->query( 'wpcom.getUser' ); - - if ( ! $xml->isError() ) { - $user_data = $xml->getResponse(); - set_transient( $transient_key, $xml->getResponse(), DAY_IN_SECONDS ); - return $user_data; - } - - return false; - } - - /** - * Returns a user object of the connection owner. - * - * @return WP_User|false False if no connection owner found. - */ - public function get_connection_owner() { - - $user_id = \Jetpack_Options::get_option( 'master_user' ); - - if ( ! $user_id ) { - return false; - } - - // Make sure user is connected. - $user_token = $this->get_tokens()->get_access_token( $user_id ); - - $connection_owner = false; - - if ( $user_token && is_object( $user_token ) && isset( $user_token->external_user_id ) ) { - $connection_owner = get_userdata( $user_token->external_user_id ); - } - - if ( $connection_owner === false ) { - Error_Handler::get_instance()->report_error( - new WP_Error( - 'invalid_connection_owner', - 'Invalid connection owner', - array( - 'user_id' => $user_id, - 'has_user_token' => (bool) $user_token, - 'error_type' => 'connection', - 'signature_details' => array( - 'token' => '', - ), - ) - ), - false, - true - ); - } - - return $connection_owner; - } - - /** - * Returns true if the provided user is the Jetpack connection owner. - * If user ID is not specified, the current user will be used. - * - * @param Integer|Boolean $user_id the user identifier. False for current user. - * @return Boolean True the user the connection owner, false otherwise. - */ - public function is_connection_owner( $user_id = false ) { - if ( ! $user_id ) { - $user_id = get_current_user_id(); - } - - return ( (int) $user_id ) === $this->get_connection_owner_id(); - } - - /** - * Connects the user with a specified ID to a WordPress.com user using the - * remote login flow. - * - * @access public - * - * @param Integer $user_id (optional) the user identifier, defaults to current user. - * @param String $redirect_url the URL to redirect the user to for processing, defaults to - * admin_url(). - * @return WP_Error only in case of a failed user lookup. - */ - public function connect_user( $user_id = null, $redirect_url = null ) { - $user = null; - if ( null === $user_id ) { - $user = wp_get_current_user(); - } else { - $user = get_user_by( 'ID', $user_id ); - } - - if ( empty( $user ) ) { - return new \WP_Error( 'user_not_found', 'Attempting to connect a non-existent user.' ); - } - - if ( null === $redirect_url ) { - $redirect_url = admin_url(); - } - - // Using wp_redirect intentionally because we're redirecting outside. - wp_redirect( $this->get_authorization_url( $user, $redirect_url ) ); // phpcs:ignore WordPress.Security.SafeRedirect - exit( 0 ); - } - - /** - * Force user disconnect. - * - * @param int $user_id Local (external) user ID. - * @param bool $disconnect_all_users Whether to disconnect all users before disconnecting the primary user. - * - * @return bool - */ - public function disconnect_user_force( $user_id, $disconnect_all_users = false ) { - if ( ! (int) $user_id ) { - // Missing user ID. - return false; - } - // If we are disconnecting the primary user we may need to disconnect all other users first - if ( $user_id === $this->get_connection_owner_id() && $disconnect_all_users && ! $this->disconnect_all_users_except_primary() ) { - return false; - } - - return $this->disconnect_user( $user_id, true, true ); - } - - /** - * Disconnects all users except the primary user. - * - * @return bool - */ - public function disconnect_all_users_except_primary() { - - $all_connected_users = $this->get_connected_users(); - - foreach ( $all_connected_users as $user ) { - // Skip the primary. - if ( $user->ID === $this->get_connection_owner_id() ) { - continue; - } - $disconnected = $this->disconnect_user( $user->ID, false, true ); - // If we fail to disconnect any user, we should not proceed with disconnecting the primary user. - if ( ! $disconnected ) { - return false; - } - } - - return true; - } - - /** - * Unlinks the current user from the linked WordPress.com user. - * - * @access public - * @static - * - * @todo Refactor to properly load the XMLRPC client independently. - * - * @param Integer $user_id the user identifier. - * @param bool $can_overwrite_primary_user Allow for the primary user to be disconnected. - * @param bool $force_disconnect_locally Disconnect user locally even if we were unable to disconnect them from WP.com. - * @return Boolean Whether the disconnection of the user was successful. - */ - public function disconnect_user( $user_id = null, $can_overwrite_primary_user = false, $force_disconnect_locally = false ) { - $user_id = empty( $user_id ) ? get_current_user_id() : (int) $user_id; - $is_primary_user = Jetpack_Options::get_option( 'master_user' ) === $user_id; - - if ( $is_primary_user && ! $can_overwrite_primary_user ) { - return false; - } - - if ( in_array( $user_id, self::$disconnected_users, true ) ) { - // The user is already disconnected. - return false; - } - - // Attempt to disconnect the user from WordPress.com. - $is_disconnected_from_wpcom = $this->unlink_user_from_wpcom( $user_id ); - - $is_disconnected_locally = false; - if ( $is_disconnected_from_wpcom || $force_disconnect_locally ) { - // Disconnect the user locally. - $is_disconnected_locally = $this->get_tokens()->disconnect_user( $user_id ); - - if ( $is_disconnected_locally ) { - // Delete cached connected user data. - $transient_key = "jetpack_connected_user_data_$user_id"; - delete_transient( $transient_key ); - - /** - * Fires after the current user has been unlinked from WordPress.com. - * - * @since 1.7.0 - * @since-jetpack 4.1.0 - * - * @param int $user_id The current user's ID. - */ - do_action( 'jetpack_unlinked_user', $user_id ); - - if ( $is_primary_user ) { - Jetpack_Options::delete_option( 'master_user' ); - } - } - } - - self::$disconnected_users[] = $user_id; - - return $is_disconnected_from_wpcom && $is_disconnected_locally; - } - - /** - * Request to wpcom for a user to be unlinked from their WordPress.com account - * - * @param int $user_id The user identifier. - * - * @return bool Whether the disconnection of the user was successful. - */ - public function unlink_user_from_wpcom( $user_id ) { - // Attempt to disconnect the user from WordPress.com. - $xml = new Jetpack_IXR_Client(); - - $xml->query( 'jetpack.unlink_user', $user_id ); - if ( $xml->isError() ) { - return false; - } - - return (bool) $xml->getResponse(); - } - - /** - * Update the connection owner. - * - * @since 1.29.0 - * - * @param Integer $new_owner_id The ID of the user to become the connection owner. - * - * @return true|WP_Error True if owner successfully changed, WP_Error otherwise. - */ - public function update_connection_owner( $new_owner_id ) { - $roles = new Roles(); - if ( ! user_can( $new_owner_id, $roles->translate_role_to_cap( 'administrator' ) ) ) { - return new WP_Error( - 'new_owner_not_admin', - __( 'New owner is not admin', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - - $old_owner_id = $this->get_connection_owner_id(); - - if ( $old_owner_id === $new_owner_id ) { - return new WP_Error( - 'new_owner_is_existing_owner', - __( 'New owner is same as existing owner', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - - if ( ! $this->is_user_connected( $new_owner_id ) ) { - return new WP_Error( - 'new_owner_not_connected', - __( 'New owner is not connected', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - - // Notify WPCOM about the connection owner change. - $owner_updated_wpcom = $this->update_connection_owner_wpcom( $new_owner_id ); - - if ( $owner_updated_wpcom ) { - // Update the connection owner in Jetpack only if they were successfully updated on WPCOM. - // This will ensure consistency with WPCOM. - \Jetpack_Options::update_option( 'master_user', $new_owner_id ); - - // Track it. - ( new Tracking() )->record_user_event( 'set_connection_owner_success' ); - - return true; - } - return new WP_Error( - 'error_setting_new_owner', - __( 'Could not confirm new owner.', 'jetpack-connection' ), - array( 'status' => 500 ) - ); - } - - /** - * Request to WPCOM to update the connection owner. - * - * @since 1.29.0 - * - * @param Integer $new_owner_id The ID of the user to become the connection owner. - * - * @return Boolean Whether the ownership transfer was successful. - */ - public function update_connection_owner_wpcom( $new_owner_id ) { - // Notify WPCOM about the connection owner change. - $xml = new Jetpack_IXR_Client( - array( - 'user_id' => get_current_user_id(), - ) - ); - $xml->query( - 'jetpack.switchBlogOwner', - array( - 'new_blog_owner' => $new_owner_id, - ) - ); - if ( $xml->isError() ) { - return false; - } - - return (bool) $xml->getResponse(); - } - - /** - * Returns the requested Jetpack API URL. - * - * @param String $relative_url the relative API path. - * @return String API URL. - */ - public function api_url( $relative_url ) { - $api_base = Constants::get_constant( 'JETPACK__API_BASE' ); - $api_version = '/' . Constants::get_constant( 'JETPACK__API_VERSION' ) . '/'; - - /** - * Filters the API URL that Jetpack uses for server communication. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param String $url the generated URL. - * @param String $relative_url the relative URL that was passed as an argument. - * @param String $api_base the API base string that is being used. - * @param String $api_version the API version string that is being used. - */ - return apply_filters( - 'jetpack_api_url', - rtrim( $api_base . $relative_url, '/\\' ) . $api_version, - $relative_url, - $api_base, - $api_version - ); - } - - /** - * Returns the Jetpack XMLRPC WordPress.com API endpoint URL. - * - * @return String XMLRPC API URL. - */ - public function xmlrpc_api_url() { - $base = preg_replace( - '#(https?://[^?/]+)(/?.*)?$#', - '\\1', - Constants::get_constant( 'JETPACK__API_BASE' ) - ); - return untrailingslashit( $base ) . '/xmlrpc.php'; - } - - /** - * Attempts Jetpack registration which sets up the site for connection. Should - * remain public because the call to action comes from the current site, not from - * WordPress.com. - * - * @param String $api_endpoint (optional) an API endpoint to use, defaults to 'register'. - * @return true|WP_Error The error object. - */ - public function register( $api_endpoint = 'register' ) { - // Clean-up leftover tokens just in-case. - // This fixes an edge case that was preventing users to register when the blog token was missing but - // there were still leftover user tokens present. - $this->delete_all_connection_tokens( true ); - - add_action( 'pre_update_jetpack_option_register', array( '\\Jetpack_Options', 'delete_option' ) ); - $secrets = ( new Secrets() )->generate( 'register', get_current_user_id(), 600 ); - - if ( false === $secrets ) { - return new WP_Error( 'cannot_save_secrets', __( 'Jetpack experienced an issue trying to save options (cannot_save_secrets). We suggest that you contact your hosting provider, and ask them for help checking that the options table is writable on your site.', 'jetpack-connection' ) ); - } - - if ( - empty( $secrets['secret_1'] ) || - empty( $secrets['secret_2'] ) || - empty( $secrets['exp'] ) - ) { - return new \WP_Error( 'missing_secrets' ); - } - - // Better to try (and fail) to set a higher timeout than this system - // supports than to have register fail for more users than it should. - $timeout = $this->set_min_time_limit( 60 ) / 2; - - $gmt_offset = get_option( 'gmt_offset' ); - if ( ! $gmt_offset ) { - $gmt_offset = 0; - } - - $stats_options = get_option( 'stats_options' ); - $stats_id = isset( $stats_options['blog_id'] ) - ? $stats_options['blog_id'] - : null; - - /* This action is documented in src/class-package-version-tracker.php */ - $package_versions = apply_filters( 'jetpack_package_versions', array() ); - - $active_plugins_using_connection = Plugin_Storage::get_all(); - - /** - * Filters the request body for additional property addition. - * - * @since 1.7.0 - * @since-jetpack 7.7.0 - * - * @param array $post_data request data. - * @param Array $token_data token data. - */ - $body = apply_filters( - 'jetpack_register_request_body', - array_merge( - array( - 'siteurl' => Urls::site_url(), - 'home' => Urls::home_url(), - 'gmt_offset' => $gmt_offset, - 'timezone_string' => (string) get_option( 'timezone_string' ), - 'site_name' => (string) get_option( 'blogname' ), - 'secret_1' => $secrets['secret_1'], - 'secret_2' => $secrets['secret_2'], - 'site_lang' => get_locale(), - 'timeout' => $timeout, - 'stats_id' => $stats_id, - 'state' => get_current_user_id(), - 'site_created' => $this->get_assumed_site_creation_date(), - 'jetpack_version' => Constants::get_constant( 'JETPACK__VERSION' ), - 'ABSPATH' => Constants::get_constant( 'ABSPATH' ), - 'current_user_email' => wp_get_current_user()->user_email, - 'connect_plugin' => $this->get_plugin() ? $this->get_plugin()->get_slug() : null, - 'package_versions' => $package_versions, - 'active_connected_plugins' => $active_plugins_using_connection, - ), - self::$extra_register_params - ) - ); - - $args = array( - 'method' => 'POST', - 'body' => $body, - 'headers' => array( - 'Accept' => 'application/json', - ), - 'timeout' => $timeout, - ); - - $args['body'] = static::apply_activation_source_to_args( $args['body'] ); - - // TODO: fix URLs for bad hosts. - $response = Client::_wp_remote_request( - $this->api_url( $api_endpoint ), - $args, - true - ); - - // Make sure the response is valid and does not contain any Jetpack errors. - $registration_details = $this->validate_remote_register_response( $response ); - - if ( is_wp_error( $registration_details ) ) { - return $registration_details; - } elseif ( ! $registration_details ) { - return new \WP_Error( - 'unknown_error', - 'Unknown error registering your Jetpack site.', - wp_remote_retrieve_response_code( $response ) - ); - } - - if ( empty( $registration_details->jetpack_secret ) || ! is_string( $registration_details->jetpack_secret ) ) { - return new \WP_Error( - 'jetpack_secret', - 'Unable to validate registration of your Jetpack site.', - wp_remote_retrieve_response_code( $response ) - ); - } - - if ( isset( $registration_details->jetpack_public ) ) { - $jetpack_public = (int) $registration_details->jetpack_public; - } else { - $jetpack_public = false; - } - - Jetpack_Options::update_options( - array( - 'id' => (int) $registration_details->jetpack_id, - 'public' => $jetpack_public, - ) - ); - - update_option( Package_Version_Tracker::PACKAGE_VERSION_OPTION, $package_versions ); - - $this->get_tokens()->update_blog_token( (string) $registration_details->jetpack_secret ); - - if ( ! Jetpack_Options::get_option( 'id' ) || ! $this->get_tokens()->get_access_token() ) { - return new WP_Error( - 'connection_data_save_failed', - 'Failed to save connection data in the database' - ); - } - - $alternate_authorization_url = isset( $registration_details->alternate_authorization_url ) ? $registration_details->alternate_authorization_url : ''; - - add_filter( - 'jetpack_register_site_rest_response', - function ( $response ) use ( $alternate_authorization_url ) { - $response['alternateAuthorizeUrl'] = $alternate_authorization_url; - return $response; - } - ); - - /** - * Fires when a site is registered on WordPress.com. - * - * @since 1.7.0 - * @since-jetpack 3.7.0 - * - * @param int $json->jetpack_id Jetpack Blog ID. - * @param string $json->jetpack_secret Jetpack Blog Token. - * @param int|bool $jetpack_public Is the site public. - */ - do_action( - 'jetpack_site_registered', - $registration_details->jetpack_id, - $registration_details->jetpack_secret, - $jetpack_public - ); - - if ( isset( $registration_details->token ) ) { - /** - * Fires when a user token is sent along with the registration data. - * - * @since 1.7.0 - * @since-jetpack 7.6.0 - * - * @param object $token the administrator token for the newly registered site. - */ - do_action( 'jetpack_site_registered_user_token', $registration_details->token ); - } - - return true; - } - - /** - * Attempts Jetpack registration. - * - * @param bool $tos_agree Whether the user agreed to TOS. - * - * @return bool|WP_Error - */ - public function try_registration( $tos_agree = true ) { - if ( $tos_agree ) { - $terms_of_service = new Terms_Of_Service(); - $terms_of_service->agree(); - } - - /** - * Action fired when the user attempts the registration. - * - * @since 1.26.0 - */ - $pre_register = apply_filters( 'jetpack_pre_register', null ); - - if ( is_wp_error( $pre_register ) ) { - return $pre_register; - } - - $tracking_data = array(); - - if ( null !== $this->get_plugin() ) { - $tracking_data['plugin_slug'] = $this->get_plugin()->get_slug(); - } - - $tracking = new Tracking(); - $tracking->record_user_event( 'jpc_register_begin', $tracking_data ); - - add_filter( 'jetpack_register_request_body', array( Utils::class, 'filter_register_request_body' ) ); - - $result = $this->register(); - - remove_filter( 'jetpack_register_request_body', array( Utils::class, 'filter_register_request_body' ) ); - - // If there was an error with registration and the site was not registered, record this so we can show a message. - if ( ! $result || is_wp_error( $result ) ) { - return $result; - } - - return true; - } - - /** - * Adds a parameter to the register request body - * - * @since 1.26.0 - * - * @param string $name The name of the parameter to be added. - * @param string $value The value of the parameter to be added. - * - * @throws \InvalidArgumentException If supplied arguments are not strings. - * @return void - */ - public function add_register_request_param( $name, $value ) { - if ( ! is_string( $name ) || ! is_string( $value ) ) { - throw new \InvalidArgumentException( 'name and value must be strings' ); - } - self::$extra_register_params[ $name ] = $value; - } - - /** - * Takes the response from the Jetpack register new site endpoint and - * verifies it worked properly. - * - * @since 1.7.0 - * @since-jetpack 2.6.0 - * - * @param Mixed $response the response object, or the error object. - * @return string|WP_Error A JSON object on success or WP_Error on failures - **/ - protected function validate_remote_register_response( $response ) { - if ( is_wp_error( $response ) ) { - return new \WP_Error( - 'register_http_request_failed', - $response->get_error_message() - ); - } - - $code = wp_remote_retrieve_response_code( $response ); - $entity = wp_remote_retrieve_body( $response ); - - if ( $entity ) { - $registration_response = json_decode( $entity ); - } else { - $registration_response = false; - } - - $code_type = (int) ( $code / 100 ); - if ( 5 === $code_type ) { - return new \WP_Error( 'wpcom_5??', $code ); - } elseif ( 408 === $code ) { - return new \WP_Error( 'wpcom_408', $code ); - } elseif ( ! empty( $registration_response->error ) ) { - if ( - 'xml_rpc-32700' === $registration_response->error - && ! function_exists( 'xml_parser_create' ) - ) { - $error_description = __( "PHP's XML extension is not available. Jetpack requires the XML extension to communicate with WordPress.com. Please contact your hosting provider to enable PHP's XML extension.", 'jetpack-connection' ); - } else { - $error_description = isset( $registration_response->error_description ) - ? (string) $registration_response->error_description - : ''; - } - - return new \WP_Error( - (string) $registration_response->error, - $error_description, - $code - ); - } elseif ( 200 !== $code ) { - return new \WP_Error( 'wpcom_bad_response', $code ); - } - - // Jetpack ID error block. - if ( empty( $registration_response->jetpack_id ) ) { - return new \WP_Error( - 'jetpack_id', - /* translators: %s is an error message string */ - sprintf( __( 'Error Details: Jetpack ID is empty. Do not publicly post this error message! %s', 'jetpack-connection' ), $entity ), - $entity - ); - } elseif ( ! is_scalar( $registration_response->jetpack_id ) ) { - return new \WP_Error( - 'jetpack_id', - /* translators: %s is an error message string */ - sprintf( __( 'Error Details: Jetpack ID is not a scalar. Do not publicly post this error message! %s', 'jetpack-connection' ), $entity ), - $entity - ); - } elseif ( preg_match( '/[^0-9]/', $registration_response->jetpack_id ) ) { - return new \WP_Error( - 'jetpack_id', - /* translators: %s is an error message string */ - sprintf( __( 'Error Details: Jetpack ID begins with a numeral. Do not publicly post this error message! %s', 'jetpack-connection' ), $entity ), - $entity - ); - } - - return $registration_response; - } - - /** - * Adds a used nonce to a list of known nonces. - * - * @param int $timestamp the current request timestamp. - * @param string $nonce the nonce value. - * @return bool whether the nonce is unique or not. - * - * @deprecated since 1.24.0 - * @see Nonce_Handler::add() - */ - public function add_nonce( $timestamp, $nonce ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Nonce_Handler::add' ); - return ( new Nonce_Handler() )->add( $timestamp, $nonce ); - } - - /** - * Cleans nonces that were saved when calling ::add_nonce. - * - * @todo Properly prepare the query before executing it. - * - * @param bool $all whether to clean even non-expired nonces. - * - * @deprecated since 1.24.0 - * @see Nonce_Handler::clean_all() - */ - public function clean_nonces( $all = false ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Nonce_Handler::clean_all' ); - ( new Nonce_Handler() )->clean_all( $all ? PHP_INT_MAX : ( time() - Nonce_Handler::LIFETIME ) ); - } - - /** - * Sets the Connection custom capabilities. - * - * @param string[] $caps Array of the user's capabilities. - * @param string $cap Capability name. - * @param int $user_id The user ID. - * @param array $args Adds the context to the cap. Typically the object ID. - */ - public function jetpack_connection_custom_caps( $caps, $cap, $user_id, $args ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - switch ( $cap ) { - case 'jetpack_connect': - case 'jetpack_reconnect': - $is_offline_mode = ( new Status() )->is_offline_mode(); - if ( $is_offline_mode ) { - $caps = array( 'do_not_allow' ); - break; - } - // Pass through. If it's not offline mode, these should match disconnect. - // Let users disconnect if it's offline mode, just in case things glitch. - case 'jetpack_disconnect': - /** - * Filters the jetpack_disconnect capability. - * - * @since 1.14.2 - * - * @param array An array containing the capability name. - */ - $caps = apply_filters( 'jetpack_disconnect_cap', array( 'manage_options' ) ); - break; - case 'jetpack_connect_user': - $is_offline_mode = ( new Status() )->is_offline_mode(); - if ( $is_offline_mode ) { - $caps = array( 'do_not_allow' ); - break; - } - // With site connections in mind, non-admin users can connect their account only if a connection owner exists. - $caps = $this->has_connected_owner() ? array( 'read' ) : array( 'manage_options' ); - break; - case 'jetpack_unlink_user': - $is_offline_mode = ( new Status() )->is_offline_mode(); - if ( $is_offline_mode ) { - $caps = array( 'do_not_allow' ); - break; - } - - // Non-admins can always disconnect - $caps = array( 'read' ); - break; - } - return $caps; - } - - /** - * Builds the timeout limit for queries talking with the wpcom servers. - * - * Based on local php max_execution_time in php.ini - * - * @since 1.7.0 - * @since-jetpack 5.4.0 - * @return int - **/ - public function get_max_execution_time() { - $timeout = (int) ini_get( 'max_execution_time' ); - - // Ensure exec time set in php.ini. - if ( ! $timeout ) { - $timeout = 30; - } - return $timeout; - } - - /** - * Sets a minimum request timeout, and returns the current timeout - * - * @since 1.7.0 - * @since-jetpack 5.4.0 - * @param Integer $min_timeout the minimum timeout value. - **/ - public function set_min_time_limit( $min_timeout ) { - $timeout = $this->get_max_execution_time(); - if ( $timeout < $min_timeout ) { - $timeout = $min_timeout; - set_time_limit( $timeout ); - } - return $timeout; - } - - /** - * Get our assumed site creation date. - * Calculated based on the earlier date of either: - * - Earliest admin user registration date. - * - Earliest date of post of any post type. - * - * @since 1.7.0 - * @since-jetpack 7.2.0 - * - * @return string Assumed site creation date and time. - */ - public function get_assumed_site_creation_date() { - $cached_date = get_transient( 'jetpack_assumed_site_creation_date' ); - if ( ! empty( $cached_date ) ) { - return $cached_date; - } - - /** - * We don't use the 'ID' field, but need it to overcome a WP caching bug: https://core.trac.wordpress.org/ticket/62003 - * - * @todo Remote the 'ID' field from users fetching when the issue is fixed and Jetpack-supported WP versions move beyond it. - */ - $earliest_registered_users = get_users( - array( - 'role' => 'administrator', - 'orderby' => 'user_registered', - 'order' => 'ASC', - 'fields' => array( 'ID', 'user_registered' ), - 'number' => 1, - ) - ); - $earliest_registration_date = $earliest_registered_users[0]->user_registered; - - $earliest_posts = get_posts( - array( - 'posts_per_page' => 1, - 'post_type' => 'any', - 'post_status' => 'any', - 'orderby' => 'date', - 'order' => 'ASC', - ) - ); - - // If there are no posts at all, we'll count only on user registration date. - if ( $earliest_posts ) { - $earliest_post_date = $earliest_posts[0]->post_date; - } else { - $earliest_post_date = PHP_INT_MAX; - } - - $assumed_date = min( $earliest_registration_date, $earliest_post_date ); - set_transient( 'jetpack_assumed_site_creation_date', $assumed_date ); - - return $assumed_date; - } - - /** - * Adds the activation source string as a parameter to passed arguments. - * - * @todo Refactor to use rawurlencode() instead of urlencode(). - * - * @param array $args arguments that need to have the source added. - * @return array $amended arguments. - */ - public static function apply_activation_source_to_args( $args ) { - list( $activation_source_name, $activation_source_keyword ) = get_option( 'jetpack_activation_source' ); - - if ( $activation_source_name ) { - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode - $args['_as'] = urlencode( $activation_source_name ); - } - - if ( $activation_source_keyword ) { - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.urlencode_urlencode - $args['_ak'] = urlencode( $activation_source_keyword ); - } - - return $args; - } - - /** - * Generates two secret tokens and the end of life timestamp for them. - * - * @param String $action The action name. - * @param Integer $user_id The user identifier. - * @param Integer $exp Expiration time in seconds. - */ - public function generate_secrets( $action, $user_id = false, $exp = 600 ) { - return ( new Secrets() )->generate( $action, $user_id, $exp ); - } - - /** - * Returns two secret tokens and the end of life timestamp for them. - * - * @deprecated 1.24.0 Use Automattic\Jetpack\Connection\Secrets->get() instead. - * - * @param String $action The action name. - * @param Integer $user_id The user identifier. - * @return string|array an array of secrets or an error string. - */ - public function get_secrets( $action, $user_id ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Secrets->get' ); - return ( new Secrets() )->get( $action, $user_id ); - } - - /** - * Deletes secret tokens in case they, for example, have expired. - * - * @deprecated 1.24.0 Use Automattic\Jetpack\Connection\Secrets->delete() instead. - * - * @param String $action The action name. - * @param Integer $user_id The user identifier. - */ - public function delete_secrets( $action, $user_id ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Secrets->delete' ); - ( new Secrets() )->delete( $action, $user_id ); - } - - /** - * Deletes all connection tokens and transients from the local Jetpack site. - * If the plugin object has been provided in the constructor, the function first checks - * whether it's the only active connection. - * If there are any other connections, the function will do nothing and return `false` - * (unless `$ignore_connected_plugins` is set to `true`). - * - * @param bool $ignore_connected_plugins Delete the tokens even if there are other connected plugins. - * - * @return bool True if disconnected successfully, false otherwise. - */ - public function delete_all_connection_tokens( $ignore_connected_plugins = false ) { - // refuse to delete if we're not the last Jetpack plugin installed. - if ( ! $ignore_connected_plugins && null !== $this->plugin && ! $this->plugin->is_only() ) { - return false; - } - - /** - * Fires upon the disconnect attempt. - * Return `false` to prevent the disconnect. - * - * @since 1.14.2 - */ - if ( ! apply_filters( 'jetpack_connection_delete_all_tokens', true ) ) { - return false; - } - - \Jetpack_Options::delete_option( - array( - 'master_user', - 'time_diff', - 'fallback_no_verify_ssl_certs', - ) - ); - - ( new Secrets() )->delete_all(); - $this->get_tokens()->delete_all(); - - // Delete cached connected user data. - $transient_key = 'jetpack_connected_user_data_' . get_current_user_id(); - delete_transient( $transient_key ); - - // Delete all XML-RPC errors. - Error_Handler::get_instance()->delete_all_errors(); - - return true; - } - - /** - * Tells WordPress.com to disconnect the site and clear all tokens from cached site. - * If the plugin object has been provided in the constructor, the function first check - * whether it's the only active connection. - * If there are any other connections, the function will do nothing and return `false` - * (unless `$ignore_connected_plugins` is set to `true`). - * - * @param bool $ignore_connected_plugins Delete the tokens even if there are other connected plugins. - * - * @return bool True if disconnected successfully, false otherwise. - */ - public function disconnect_site_wpcom( $ignore_connected_plugins = false ) { - if ( ! $ignore_connected_plugins && null !== $this->plugin && ! $this->plugin->is_only() ) { - return false; - } - - if ( ( new Status() )->is_offline_mode() && ! apply_filters( 'jetpack_connection_disconnect_site_wpcom_offline_mode', false ) ) { - // Prevent potential disconnect of the live site by removing WPCOM tokens. - return false; - } - - /** - * Fires upon the disconnect attempt. - * Return `false` to prevent the disconnect. - * - * @since 1.14.2 - */ - if ( ! apply_filters( 'jetpack_connection_disconnect_site_wpcom', true, $this ) ) { - return false; - } - - $xml = new Jetpack_IXR_Client(); - $xml->query( 'jetpack.deregister', get_current_user_id() ); - - return true; - } - - /** - * Disconnect the plugin and remove the tokens. - * This function will automatically perform "soft" or "hard" disconnect depending on whether other plugins are using the connection. - * This is a proxy method to simplify the Connection package API. - * - * @see Manager::disconnect_site() - * - * @param boolean $disconnect_wpcom Should disconnect_site_wpcom be called. - * @param bool $ignore_connected_plugins Delete the tokens even if there are other connected plugins. - * @return bool - */ - public function remove_connection( $disconnect_wpcom = true, $ignore_connected_plugins = false ) { - - $this->disconnect_site( $disconnect_wpcom, $ignore_connected_plugins ); - - return true; - } - - /** - * Completely clearing up the connection, and initiating reconnect. - * - * @return true|WP_Error True if reconnected successfully, a `WP_Error` object otherwise. - */ - public function reconnect() { - ( new Tracking() )->record_user_event( 'restore_connection_reconnect' ); - - $this->disconnect_site_wpcom( true ); - - return $this->register(); - } - - /** - * Validate the tokens, and refresh the invalid ones. - * - * @return string|bool|WP_Error True if connection restored or string indicating what's to be done next. A `WP_Error` object or false otherwise. - */ - public function restore() { - // If this is a site connection we need to trigger a full reconnection as our only secure means of - // communication with WPCOM, aka the blog token, is compromised. - if ( $this->is_site_connection() ) { - return $this->reconnect(); - } - - $validate_tokens_response = $this->get_tokens()->validate(); - - // If token validation failed, trigger a full reconnection. - if ( is_array( $validate_tokens_response ) && - isset( $validate_tokens_response['blog_token']['is_healthy'] ) && - isset( $validate_tokens_response['user_token']['is_healthy'] ) ) { - $blog_token_healthy = $validate_tokens_response['blog_token']['is_healthy']; - $user_token_healthy = $validate_tokens_response['user_token']['is_healthy']; - } else { - $blog_token_healthy = false; - $user_token_healthy = false; - } - - // Tokens are both valid, or both invalid. We can't fix the problem we don't see, so the full reconnection is needed. - if ( $blog_token_healthy === $user_token_healthy ) { - $result = $this->reconnect(); - return ( true === $result ) ? 'authorize' : $result; - } - - if ( ! $blog_token_healthy ) { - return $this->refresh_blog_token(); - } - - if ( ! $user_token_healthy ) { - return ( true === $this->refresh_user_token() ) ? 'authorize' : false; - } - - return false; - } - - /** - * Responds to a WordPress.com call to register the current site. - * Should be changed to protected. - * - * @param array $registration_data Array of [ secret_1, user_id ]. - */ - public function handle_registration( array $registration_data ) { - list( $registration_secret_1, $registration_user_id ) = $registration_data; - if ( empty( $registration_user_id ) ) { - return new \WP_Error( 'registration_state_invalid', __( 'Invalid Registration State', 'jetpack-connection' ), 400 ); - } - - return ( new Secrets() )->verify( 'register', $registration_secret_1, (int) $registration_user_id ); - } - - /** - * Perform the API request to validate the blog and user tokens. - * - * @deprecated 1.24.0 Use Automattic\Jetpack\Connection\Tokens->validate_tokens() instead. - * - * @param int|null $user_id ID of the user we need to validate token for. Current user's ID by default. - * - * @return array|false|WP_Error The API response: `array( 'blog_token_is_healthy' => true|false, 'user_token_is_healthy' => true|false )`. - */ - public function validate_tokens( $user_id = null ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Tokens->validate' ); - return $this->get_tokens()->validate( $user_id ); - } - - /** - * Verify a Previously Generated Secret. - * - * @deprecated 1.24.0 Use Automattic\Jetpack\Connection\Secrets->verify() instead. - * - * @param string $action The type of secret to verify. - * @param string $secret_1 The secret string to compare to what is stored. - * @param int $user_id The user ID of the owner of the secret. - * @return \WP_Error|string WP_Error on failure, secret_2 on success. - */ - public function verify_secrets( $action, $secret_1, $user_id ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Secrets->verify' ); - return ( new Secrets() )->verify( $action, $secret_1, $user_id ); - } - - /** - * Responds to a WordPress.com call to authorize the current user. - * Should be changed to protected. - */ - public function handle_authorization() { - } - - /** - * Obtains the auth token. - * - * @param array $data The request data. - * @return object|\WP_Error Returns the auth token on success. - * Returns a \WP_Error on failure. - */ - public function get_token( $data ) { - return $this->get_tokens()->get( $data, $this->api_url( 'token' ) ); - } - - /** - * Builds a URL to the Jetpack connection auth page. - * - * @since 2.7.6 Added optional $from and $raw parameters. - * - * @param WP_User|null $user (optional) defaults to the current logged in user. - * @param string|null $redirect (optional) a redirect URL to use instead of the default. - * @param bool|string $from If not false, adds 'from=$from' param to the connect URL. - * @param bool $raw If true, URL will not be escaped. - * - * @return string Connect URL. - */ - public function get_authorization_url( $user = null, $redirect = null, $from = false, $raw = false ) { - if ( empty( $user ) ) { - $user = wp_get_current_user(); - } - - $roles = new Roles(); - $role = $roles->translate_user_to_role( $user ); - $signed_role = $this->get_tokens()->sign_role( $role ); - - /** - * Filter the URL of the first time the user gets redirected back to your site for connection - * data processing. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param string $redirect_url Defaults to the site admin URL. - */ - $processing_url = apply_filters( 'jetpack_connect_processing_url', admin_url( 'admin.php' ) ); - - /** - * Filter the URL to redirect the user back to when the authorization process - * is complete. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param string $redirect_url Defaults to the site URL. - */ - $redirect = apply_filters( 'jetpack_connect_redirect_url', $redirect ); - - $secrets = ( new Secrets() )->generate( 'authorize', $user->ID, 2 * HOUR_IN_SECONDS ); - - /** - * Filter the type of authorization. - * 'calypso' completes authorization on wordpress.com/jetpack/connect - * while 'jetpack' ( or any other value ) completes the authorization at jetpack.wordpress.com. - * - * @since 1.7.0 - * @since-jetpack 4.3.3 - * - * @param string $auth_type Defaults to 'calypso', can also be 'jetpack'. - */ - $auth_type = apply_filters( 'jetpack_auth_type', 'calypso' ); - - /** - * Filters the user connection request data for additional property addition. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param array $request_data request data. - */ - $body = apply_filters( - 'jetpack_connect_request_body', - array( - 'response_type' => 'code', - 'client_id' => \Jetpack_Options::get_option( 'id' ), - 'redirect_uri' => add_query_arg( - array( - 'handler' => 'jetpack-connection-webhooks', - 'action' => 'authorize', - '_wpnonce' => wp_create_nonce( "jetpack-authorize_{$role}_{$redirect}" ), - 'redirect' => $redirect ? rawurlencode( $redirect ) : false, - ), - esc_url( $processing_url ) - ), - 'state' => $user->ID, - 'scope' => $signed_role, - 'user_email' => $user->user_email, - 'user_login' => $user->user_login, - 'is_active' => $this->has_connected_owner(), // TODO Deprecate this. - 'jp_version' => (string) Constants::get_constant( 'JETPACK__VERSION' ), - 'auth_type' => $auth_type, - 'secret' => $secrets['secret_1'], - 'blogname' => get_option( 'blogname' ), - 'site_url' => Urls::site_url(), - 'home_url' => Urls::home_url(), - 'site_icon' => get_site_icon_url(), - 'site_lang' => get_locale(), - 'site_created' => $this->get_assumed_site_creation_date(), - 'allow_site_connection' => ! $this->has_connected_owner(), - 'calypso_env' => ( new Host() )->get_calypso_env(), - 'source' => ( new Host() )->get_source_query(), - ) - ); - - $body = static::apply_activation_source_to_args( urlencode_deep( $body ) ); - - $api_url = $this->api_url( 'authorize' ); - - $url = add_query_arg( $body, $api_url ); - - if ( is_network_admin() ) { - $url = add_query_arg( 'is_multisite', network_admin_url( 'admin.php?page=jetpack-settings' ), $url ); - } - - if ( $from ) { - $url = add_query_arg( 'from', $from, $url ); - } - - if ( $raw ) { - $url = esc_url_raw( $url ); - } - - /** - * Filter the URL used when connecting a user to a WordPress.com account. - * - * @since 2.0.0 - * @since 2.7.6 Added $raw parameter. - * - * @param string $url Connection URL. - * @param bool $raw If true, URL will not be escaped. - */ - return apply_filters( 'jetpack_build_authorize_url', $url, $raw ); - } - - /** - * Authorizes the user by obtaining and storing the user token. - * - * @param array $data The request data. - * @return string|\WP_Error Returns a string on success. - * Returns a \WP_Error on failure. - */ - public function authorize( $data = array() ) { - /** - * Action fired when user authorization starts. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - */ - do_action( 'jetpack_authorize_starting' ); - - $roles = new Roles(); - $role = $roles->translate_current_user_to_role(); - - if ( ! $role ) { - return new \WP_Error( 'no_role', 'Invalid request.', 400 ); - } - - $cap = $roles->translate_role_to_cap( $role ); - if ( ! $cap ) { - return new \WP_Error( 'no_cap', 'Invalid request.', 400 ); - } - - if ( ! empty( $data['error'] ) ) { - return new \WP_Error( $data['error'], 'Error included in the request.', 400 ); - } - - if ( ! isset( $data['state'] ) ) { - return new \WP_Error( 'no_state', 'Request must include state.', 400 ); - } - - if ( ! ctype_digit( $data['state'] ) ) { - return new \WP_Error( $data['error'], 'State must be an integer.', 400 ); - } - - $current_user_id = get_current_user_id(); - if ( $current_user_id !== (int) $data['state'] ) { - return new \WP_Error( 'wrong_state', 'State does not match current user.', 400 ); - } - - if ( empty( $data['code'] ) ) { - return new \WP_Error( 'no_code', 'Request must include an authorization code.', 400 ); - } - - $token = $this->get_tokens()->get( $data, $this->api_url( 'token' ) ); - - if ( is_wp_error( $token ) ) { - $code = $token->get_error_code(); - if ( empty( $code ) ) { - $code = 'invalid_token'; - } - return new \WP_Error( $code, $token->get_error_message(), 400 ); - } - - if ( ! $token ) { - return new \WP_Error( 'no_token', 'Error generating token.', 400 ); - } - - $is_connection_owner = ! $this->has_connected_owner(); - - $this->get_tokens()->update_user_token( $current_user_id, sprintf( '%s.%d', $token, $current_user_id ), $is_connection_owner ); - - /** - * Fires after user has successfully received an auth token. - * - * @since 1.7.0 - * @since-jetpack 3.9.0 - */ - do_action( 'jetpack_user_authorized' ); - - if ( ! $is_connection_owner ) { - /** - * Action fired when a secondary user has been authorized. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - */ - do_action( 'jetpack_authorize_ending_linked' ); - return 'linked'; - } - - /** - * Action fired when the master user has been authorized. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param array $data The request data. - */ - do_action( 'jetpack_authorize_ending_authorized', $data ); - - \Jetpack_Options::delete_raw_option( 'jetpack_last_connect_url_check' ); - - ( new Nonce_Handler() )->reschedule(); - - return 'authorized'; - } - - /** - * Disconnects from the Jetpack servers. - * Forgets all connection details and tells the Jetpack servers to do the same. - * - * @param boolean $disconnect_wpcom Should disconnect_site_wpcom be called. - * @param bool $ignore_connected_plugins Delete the tokens even if there are other connected plugins. - */ - public function disconnect_site( $disconnect_wpcom = true, $ignore_connected_plugins = true ) { - if ( ! $ignore_connected_plugins && null !== $this->plugin && ! $this->plugin->is_only() ) { - return false; - } - - wp_clear_scheduled_hook( 'jetpack_clean_nonces' ); - - ( new Nonce_Handler() )->clean_all(); - - Heartbeat::init()->deactivate(); - - /** - * Fires before a site is disconnected. - * - * @since 1.36.3 - */ - do_action( 'jetpack_site_before_disconnected' ); - - // If the site is in an IDC because sync is not allowed, - // let's make sure to not disconnect the production site. - if ( $disconnect_wpcom ) { - $tracking = new Tracking(); - $tracking->record_user_event( 'disconnect_site', array() ); - - $this->disconnect_site_wpcom( $ignore_connected_plugins ); - } - - $this->delete_all_connection_tokens( $ignore_connected_plugins ); - - // Remove tracked package versions, since they depend on the Jetpack Connection. - delete_option( Package_Version_Tracker::PACKAGE_VERSION_OPTION ); - - $jetpack_unique_connection = \Jetpack_Options::get_option( 'unique_connection' ); - if ( $jetpack_unique_connection ) { - // Check then record unique disconnection if site has never been disconnected previously. - if ( - 1 === $jetpack_unique_connection['disconnected'] ) { - $jetpack_unique_connection['disconnected'] = 1; - } else { - if ( 0 === $jetpack_unique_connection['disconnected'] ) { - $a8c_mc_stats_instance = new A8c_Mc_Stats(); - $a8c_mc_stats_instance->add( 'connections', 'unique-disconnect' ); - $a8c_mc_stats_instance->do_server_side_stats(); - } - // increment number of times disconnected. - $jetpack_unique_connection['disconnected'] += 1; - } - - \Jetpack_Options::update_option( 'unique_connection', $jetpack_unique_connection ); - } - - /** - * Fires when a site is disconnected. - * - * @since 1.30.1 - */ - do_action( 'jetpack_site_disconnected' ); - } - - /** - * The Base64 Encoding of the SHA1 Hash of the Input. - * - * @param string $text The string to hash. - * @return string - */ - public function sha1_base64( $text ) { - return base64_encode( sha1( $text, true ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - } - - /** - * This function mirrors Jetpack_Data::is_usable_domain() in the WPCOM codebase. - * - * @param string $domain The domain to check. - * - * @return bool|WP_Error - */ - public function is_usable_domain( $domain ) { - - // If it's empty, just fail out. - if ( ! $domain ) { - return new \WP_Error( - 'fail_domain_empty', - /* translators: %1$s is a domain name. */ - sprintf( __( 'Domain `%1$s` just failed is_usable_domain check as it is empty.', 'jetpack-connection' ), $domain ) - ); - } - - /** - * Skips the usuable domain check when connecting a site. - * - * Allows site administrators with domains that fail gethostname-based checks to pass the request to WP.com - * - * @since 1.7.0 - * @since-jetpack 4.1.0 - * - * @param bool If the check should be skipped. Default false. - */ - if ( apply_filters( 'jetpack_skip_usuable_domain_check', false ) ) { - return true; - } - - // None of the explicit localhosts. - $forbidden_domains = array( - 'wordpress.com', - 'localhost', - 'localhost.localdomain', - 'local.wordpress.test', // VVV pattern. - 'local.wordpress-trunk.test', // VVV pattern. - 'src.wordpress-develop.test', // VVV pattern. - 'build.wordpress-develop.test', // VVV pattern. - ); - if ( in_array( $domain, $forbidden_domains, true ) ) { - return new \WP_Error( - 'fail_domain_forbidden', - sprintf( - /* translators: %1$s is a domain name. */ - __( - 'Domain `%1$s` just failed is_usable_domain check as it is in the forbidden array.', - 'jetpack-connection' - ), - $domain - ) - ); - } - - // No .test or .local domains. - if ( preg_match( '#\.(test|local)$#i', $domain ) ) { - return new \WP_Error( - 'fail_domain_tld', - sprintf( - /* translators: %1$s is a domain name. */ - __( - 'Domain `%1$s` just failed is_usable_domain check as it uses an invalid top level domain.', - 'jetpack-connection' - ), - $domain - ) - ); - } - - // No WPCOM subdomains. - if ( preg_match( '#\.WordPress\.com$#i', $domain ) ) { - return new \WP_Error( - 'fail_subdomain_wpcom', - sprintf( - /* translators: %1$s is a domain name. */ - __( - 'Domain `%1$s` just failed is_usable_domain check as it is a subdomain of WordPress.com.', - 'jetpack-connection' - ), - $domain - ) - ); - } - - // If PHP was compiled without support for the Filter module (very edge case). - if ( ! function_exists( 'filter_var' ) ) { - // Just pass back true for now, and let wpcom sort it out. - return true; - } - - $domain = preg_replace( '#^https?://#', '', untrailingslashit( $domain ) ); - - if ( filter_var( $domain, FILTER_VALIDATE_IP ) - && ! filter_var( $domain, FILTER_VALIDATE_IP, FILTER_FLAG_NO_PRIV_RANGE | FILTER_FLAG_NO_RES_RANGE ) - ) { - return new \WP_Error( - 'fail_ip_forbidden', - sprintf( - /* translators: %1$s is a domain name. */ - __( - 'IP address `%1$s` just failed is_usable_domain check as it is in the private network.', - 'jetpack-connection' - ), - $domain - ) - ); - } - - return true; - } - - /** - * Gets the requested token. - * - * @deprecated 1.24.0 Use Automattic\Jetpack\Connection\Tokens->get_access_token() instead. - * - * @param int|false $user_id false: Return the Blog Token. int: Return that user's User Token. - * @param string|false $token_key If provided, check that the token matches the provided input. - * @param bool|true $suppress_errors If true, return a falsy value when the token isn't found; When false, return a descriptive WP_Error when the token isn't found. - * - * @return object|false - * - * @see $this->get_tokens()->get_access_token() - */ - public function get_access_token( $user_id = false, $token_key = false, $suppress_errors = true ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Tokens->get_access_token' ); - return $this->get_tokens()->get_access_token( $user_id, $token_key, $suppress_errors ); - } - - /** - * In some setups, $HTTP_RAW_POST_DATA can be emptied during some IXR_Server paths - * since it is passed by reference to various methods. - * Capture it here so we can verify the signature later. - * - * @param array $methods an array of available XMLRPC methods. - * @return array the same array, since this method doesn't add or remove anything. - */ - public function xmlrpc_methods( $methods ) { - $this->raw_post_data = isset( $GLOBALS['HTTP_RAW_POST_DATA'] ) ? $GLOBALS['HTTP_RAW_POST_DATA'] : null; - return $methods; - } - - /** - * Resets the raw post data parameter for testing purposes. - */ - public function reset_raw_post_data() { - $this->raw_post_data = null; - } - - /** - * Registering an additional method. - * - * @param array $methods an array of available XMLRPC methods. - * @return array the amended array in case the method is added. - */ - public function public_xmlrpc_methods( $methods ) { - if ( array_key_exists( 'wp.getOptions', $methods ) ) { - $methods['wp.getOptions'] = array( $this, 'jetpack_get_options' ); - } - return $methods; - } - - /** - * Handles a getOptions XMLRPC method call. - * - * @param array $args method call arguments. - * @return array|IXR_Error An amended XMLRPC server options array. - */ - public function jetpack_get_options( $args ) { - global $wp_xmlrpc_server; - - $wp_xmlrpc_server->escape( $args ); - - $username = $args[1]; - $password = $args[2]; - - $user = $wp_xmlrpc_server->login( $username, $password ); - if ( ! $user ) { - return $wp_xmlrpc_server->error; - } - - $options = array(); - $user_data = $this->get_connected_user_data(); - if ( is_array( $user_data ) ) { - $options['jetpack_user_id'] = array( - 'desc' => __( 'The WP.com user ID of the connected user', 'jetpack-connection' ), - 'readonly' => true, - 'value' => $user_data['ID'], - ); - $options['jetpack_user_login'] = array( - 'desc' => __( 'The WP.com username of the connected user', 'jetpack-connection' ), - 'readonly' => true, - 'value' => $user_data['login'], - ); - $options['jetpack_user_email'] = array( - 'desc' => __( 'The WP.com user email of the connected user', 'jetpack-connection' ), - 'readonly' => true, - 'value' => $user_data['email'], - ); - $options['jetpack_user_site_count'] = array( - 'desc' => __( 'The number of sites of the connected WP.com user', 'jetpack-connection' ), - 'readonly' => true, - 'value' => $user_data['site_count'], - ); - } - $wp_xmlrpc_server->blog_options = array_merge( $wp_xmlrpc_server->blog_options, $options ); - $args = stripslashes_deep( $args ); - return $wp_xmlrpc_server->wp_getOptions( $args ); - } - - /** - * Adds Jetpack-specific options to the output of the XMLRPC options method. - * - * @param array $options standard Core options. - * @return array amended options. - */ - public function xmlrpc_options( $options ) { - $jetpack_client_id = false; - if ( $this->is_connected() ) { - $jetpack_client_id = \Jetpack_Options::get_option( 'id' ); - } - $options['jetpack_version'] = array( - 'desc' => __( 'Jetpack Plugin Version', 'jetpack-connection' ), - 'readonly' => true, - 'value' => Constants::get_constant( 'JETPACK__VERSION' ), - ); - - $options['jetpack_client_id'] = array( - 'desc' => __( 'The Client ID/WP.com Blog ID of this site', 'jetpack-connection' ), - 'readonly' => true, - 'value' => $jetpack_client_id, - ); - return $options; - } - - /** - * Resets the saved authentication state in between testing requests. - */ - public function reset_saved_auth_state() { - $this->xmlrpc_verification = null; - } - - /** - * Sign a user role with the master access token. - * If not specified, will default to the current user. - * - * @access public - * - * @param string $role User role. - * @param int $user_id ID of the user. - * @return string Signed user role. - */ - public function sign_role( $role, $user_id = null ) { - return $this->get_tokens()->sign_role( $role, $user_id ); - } - - /** - * Set the plugin instance. - * - * @param Plugin $plugin_instance The plugin instance. - * - * @return $this - */ - public function set_plugin_instance( Plugin $plugin_instance ) { - $this->plugin = $plugin_instance; - - return $this; - } - - /** - * Retrieve the plugin management object. - * - * @return Plugin|null - */ - public function get_plugin() { - return $this->plugin; - } - - /** - * Get all connected plugins information, excluding those disconnected by user. - * WARNING: the method cannot be called until Plugin_Storage::configure is called, which happens on plugins_loaded - * Even if you don't use Jetpack Config, it may be introduced later by other plugins, - * so please make sure not to run the method too early in the code. - * - * @return array|WP_Error - */ - public function get_connected_plugins() { - $maybe_plugins = Plugin_Storage::get_all(); - - if ( $maybe_plugins instanceof WP_Error ) { - return $maybe_plugins; - } - - return $maybe_plugins; - } - - /** - * Force plugin disconnect. After its called, the plugin will not be allowed to use the connection. - * Note: this method does not remove any access tokens. - * - * @deprecated since 1.39.0 - * @return bool - */ - public function disable_plugin() { - return null; - } - - /** - * Force plugin reconnect after user-initiated disconnect. - * After its called, the plugin will be allowed to use the connection again. - * Note: this method does not initialize access tokens. - * - * @deprecated since 1.39.0. - * @return bool - */ - public function enable_plugin() { - return null; - } - - /** - * Whether the plugin is allowed to use the connection, or it's been disconnected by user. - * If no plugin slug was passed into the constructor, always returns true. - * - * @deprecated 1.42.0 This method no longer has a purpose after the removal of the soft disconnect feature. - * - * @return bool - */ - public function is_plugin_enabled() { - return true; - } - - /** - * Perform the API request to refresh the blog token. - * Note that we are making this request on behalf of the Jetpack master user, - * given they were (most probably) the ones that registered the site at the first place. - * - * @return WP_Error|bool The result of updating the blog_token option. - */ - public function refresh_blog_token() { - ( new Tracking() )->record_user_event( 'restore_connection_refresh_blog_token' ); - - $blog_id = \Jetpack_Options::get_option( 'id' ); - if ( ! $blog_id ) { - return new WP_Error( 'site_not_registered', 'Site not registered.' ); - } - - $url = sprintf( - '%s/%s/v%s/%s', - Constants::get_constant( 'JETPACK__WPCOM_JSON_API_BASE' ), - 'wpcom', - '2', - 'sites/' . $blog_id . '/jetpack-refresh-blog-token' - ); - $method = 'POST'; - $user_id = get_current_user_id(); - - $response = Client::remote_request( compact( 'url', 'method', 'user_id' ) ); - - if ( is_wp_error( $response ) ) { - return new WP_Error( 'refresh_blog_token_http_request_failed', $response->get_error_message() ); - } - - $code = wp_remote_retrieve_response_code( $response ); - $entity = wp_remote_retrieve_body( $response ); - - if ( $entity ) { - $json = json_decode( $entity ); - } else { - $json = false; - } - - if ( 200 !== $code ) { - if ( empty( $json->code ) ) { - return new WP_Error( 'unknown', '', $code ); - } - - /* translators: Error description string. */ - $error_description = isset( $json->message ) ? sprintf( __( 'Error Details: %s', 'jetpack-connection' ), (string) $json->message ) : ''; - - return new WP_Error( (string) $json->code, $error_description, $code ); - } - - if ( empty( $json->jetpack_secret ) || ! is_scalar( $json->jetpack_secret ) ) { - return new WP_Error( 'jetpack_secret', '', $code ); - } - - Error_Handler::get_instance()->delete_all_errors(); - - return $this->get_tokens()->update_blog_token( (string) $json->jetpack_secret ); - } - - /** - * Disconnect the user from WP.com, and initiate the reconnect process. - * - * @return bool - */ - public function refresh_user_token() { - ( new Tracking() )->record_user_event( 'restore_connection_refresh_user_token' ); - $this->disconnect_user( null, true, true ); - return true; - } - - /** - * Fetches a signed token. - * - * @deprecated 1.24.0 Use Automattic\Jetpack\Connection\Tokens->get_signed_token() instead. - * - * @param object $token the token. - * @return WP_Error|string a signed token - */ - public function get_signed_token( $token ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Tokens->get_signed_token' ); - return $this->get_tokens()->get_signed_token( $token ); - } - - /** - * If the site-level connection is active, add the list of plugins using connection to the heartbeat (except Jetpack itself) - * - * @param array $stats The Heartbeat stats array. - * @return array $stats - */ - public function add_stats_to_heartbeat( $stats ) { - - if ( ! $this->is_connected() ) { - return $stats; - } - - $active_plugins_using_connection = Plugin_Storage::get_all(); - foreach ( array_keys( $active_plugins_using_connection ) as $plugin_slug ) { - if ( 'jetpack' !== $plugin_slug ) { - $stats_group = isset( $active_plugins_using_connection['jetpack'] ) ? 'combined-connection' : 'standalone-connection'; - $stats[ $stats_group ][] = $plugin_slug; - } - } - return $stats; - } - - /** - * Get the WPCOM or self-hosted site ID. - * - * @param bool $quiet Return null instead of an error. - * - * @return int|WP_Error|null - */ - public static function get_site_id( $quiet = false ) { - $is_wpcom = ( defined( 'IS_WPCOM' ) && IS_WPCOM ); - $site_id = $is_wpcom ? get_current_blog_id() : \Jetpack_Options::get_option( 'id' ); - if ( ! $site_id ) { - return $quiet - ? null - : new \WP_Error( - 'unavailable_site_id', - __( 'Sorry, something is wrong with your Jetpack connection.', 'jetpack-connection' ), - 403 - ); - } - return (int) $site_id; - } - - /** - * Check if Jetpack is ready for uninstall cleanup. - * - * @param string $current_plugin_slug The current plugin's slug. - * - * @return bool - */ - public static function is_ready_for_cleanup( $current_plugin_slug ) { - $active_plugins = get_option( Plugin_Storage::ACTIVE_PLUGINS_OPTION_NAME ); - - return empty( $active_plugins ) || ! is_array( $active_plugins ) - || ( count( $active_plugins ) === 1 && array_key_exists( $current_plugin_slug, $active_plugins ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php deleted file mode 100644 index 48e14a15..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php +++ /dev/null @@ -1,212 +0,0 @@ -db = $wpdb; - } - - /** - * Scheduling the WP-cron cleanup event. - */ - public function init_schedule() { - add_action( 'jetpack_clean_nonces', array( __CLASS__, 'clean_scheduled' ) ); - if ( ! wp_next_scheduled( 'jetpack_clean_nonces' ) ) { - wp_schedule_event( time(), 'hourly', 'jetpack_clean_nonces' ); - } - } - - /** - * Reschedule the WP-cron cleanup event to make it start sooner. - */ - public function reschedule() { - wp_clear_scheduled_hook( 'jetpack_clean_nonces' ); - wp_schedule_event( time(), 'hourly', 'jetpack_clean_nonces' ); - } - - /** - * Adds a used nonce to a list of known nonces. - * - * @param int $timestamp the current request timestamp. - * @param string $nonce the nonce value. - * - * @return bool whether the nonce is unique or not. - */ - public function add( $timestamp, $nonce ) { - if ( isset( static::$nonces_used_this_request[ "$timestamp:$nonce" ] ) ) { - return static::$nonces_used_this_request[ "$timestamp:$nonce" ]; - } - - // This should always have gone through Jetpack_Signature::sign_request() first to check $timestamp and $nonce. - $timestamp = (int) $timestamp; - $nonce = esc_sql( $nonce ); - - // Raw query so we can avoid races: add_option will also update. - $show_errors = $this->db->hide_errors(); - - // Running `try...finally` to make sure that we re-enable errors in case of an exception. - try { - $old_nonce = $this->db->get_row( - $this->db->prepare( "SELECT 1 FROM `{$this->db->options}` WHERE option_name = %s", "jetpack_nonce_{$timestamp}_{$nonce}" ) - ); - - if ( $old_nonce === null ) { - $return = (bool) $this->db->query( - $this->db->prepare( - "INSERT INTO `{$this->db->options}` (`option_name`, `option_value`, `autoload`) VALUES (%s, %s, %s)", - "jetpack_nonce_{$timestamp}_{$nonce}", - time(), - 'no' - ) - ); - } else { - $return = false; - } - } finally { - $this->db->show_errors( $show_errors ); - } - - static::$nonces_used_this_request[ "$timestamp:$nonce" ] = $return; - - return $return; - } - - /** - * Removing all existing nonces, or at least as many as possible. - * Capped at 20 seconds to avoid breaking the site. - * - * @param int $cutoff_timestamp All nonces added before this timestamp will be removed. - * @param int $time_limit How long the cleanup can run (in seconds). - * - * @return true - */ - public function clean_all( $cutoff_timestamp = PHP_INT_MAX, $time_limit = 20 ) { - // phpcs:ignore Generic.CodeAnalysis.ForLoopWithTestFunctionCall.NotAllowed - for ( $end_time = time() + $time_limit; time() < $end_time; ) { - $result = $this->delete( static::CLEAN_ALL_LIMIT_PER_BATCH, $cutoff_timestamp ); - - if ( ! $result ) { - break; - } - } - - return true; - } - - /** - * Scheduled clean up of the expired nonces. - */ - public static function clean_scheduled() { - /** - * Adjust the time limit for the scheduled cleanup. - * - * @since 9.5.0 - * - * @param int $time_limit How long the cleanup can run (in seconds). - */ - $time_limit = apply_filters( 'jetpack_connection_nonce_cleanup_runtime_limit', static::SCHEDULED_CLEANUP_TIME_LIMIT ); - - ( new static() )->clean_all( time() - static::LIFETIME, $time_limit ); - } - - /** - * Delete the nonces. - * - * @param int $limit How many nonces to delete. - * @param null|int $cutoff_timestamp All nonces added before this timestamp will be removed. - * - * @return int|false Number of removed nonces, or `false` if nothing to remove (or in case of a database error). - */ - public function delete( $limit = 10, $cutoff_timestamp = null ) { - global $wpdb; - - $ids = $wpdb->get_col( - $wpdb->prepare( - "SELECT option_id FROM `{$wpdb->options}`" - . " WHERE `option_name` >= 'jetpack_nonce_' AND `option_name` < %s" - . ' LIMIT %d', - 'jetpack_nonce_' . $cutoff_timestamp, - $limit - ) - ); - - if ( ! is_array( $ids ) ) { - // There's an error and we can't proceed. - return false; - } - - // Removing zeroes in case AUTO_INCREMENT of the options table is broken, and all ID's are zeroes. - $ids = array_filter( $ids ); - - if ( array() === $ids ) { - // There's nothing to remove. - return false; - } - - $ids_fill = implode( ', ', array_fill( 0, count( $ids ), '%d' ) ); - - $args = $ids; - $args[] = 'jetpack_nonce_%'; - - // The Code Sniffer is unable to understand what's going on... - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.PreparedSQLPlaceholders.ReplacementsWrongNumber - return $wpdb->query( $wpdb->prepare( "DELETE FROM `{$wpdb->options}` WHERE `option_id` IN ( {$ids_fill} ) AND option_name LIKE %s", $args ) ); - } - - /** - * Clean the cached nonces valid during the current request, therefore making them invalid. - * - * @return bool - */ - public static function invalidate_request_nonces() { - static::$nonces_used_this_request = array(); - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php deleted file mode 100644 index 2d1b3743..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php +++ /dev/null @@ -1,176 +0,0 @@ -is_rate_limiting() ) { - return; - } - - /** - * Obtains the package versions. - * - * @since 1.30.2 - * - * @param array An associative array of Jetpack package slugs and their corresponding versions as key/value pairs. - */ - $filter_versions = apply_filters( 'jetpack_package_versions', array() ); - - if ( ! is_array( $filter_versions ) ) { - return; - } - - $option_versions = get_option( self::PACKAGE_VERSION_OPTION, array() ); - - foreach ( $filter_versions as $package => $version ) { - if ( ! is_string( $package ) || ! is_string( $version ) ) { - unset( $filter_versions[ $package ] ); - } - } - - if ( ! is_array( $option_versions ) - || count( array_diff_assoc( $filter_versions, $option_versions ) ) - || count( array_diff_assoc( $option_versions, $filter_versions ) ) - ) { - $this->update_package_versions_option( $filter_versions ); - } - } - - /** - * Updates the package versions option. - * - * @param array $package_versions The package versions. - */ - protected function update_package_versions_option( $package_versions ) { - if ( ! $this->is_sync_enabled() ) { - $this->update_package_versions_via_remote_request( $package_versions ); - return; - } - - update_option( self::PACKAGE_VERSION_OPTION, $package_versions ); - } - - /** - * Whether Jetpack Sync is enabled. - * - * @return boolean true if Sync is present and enabled, false otherwise - */ - protected function is_sync_enabled() { - if ( class_exists( 'Automattic\Jetpack\Sync\Settings' ) && \Automattic\Jetpack\Sync\Settings::is_sync_enabled() ) { - - return true; - } - - return false; - } - - /** - * Fallback for updating the package versions via a remote request when Sync is not present. - * - * Updates the package versions as follows: - * - Sends the updated package versions to wpcom. - * - Updates the 'jetpack_package_versions' option. - * - * @param array $package_versions The package versions. - */ - protected function update_package_versions_via_remote_request( $package_versions ) { - $connection = new Manager(); - if ( ! $connection->is_connected() ) { - return; - } - - $site_id = \Jetpack_Options::get_option( 'id' ); - - $last_failed_attempt_within_hour = get_transient( self::CACHED_FAILED_REQUEST_KEY ); - - if ( $last_failed_attempt_within_hour ) { - return; - } - - $body = wp_json_encode( - array( - 'package_versions' => $package_versions, - ) - ); - - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%d/jetpack-package-versions', $site_id ), - '2', - array( - 'headers' => array( 'content-type' => 'application/json' ), - 'method' => 'POST', - ), - $body, - 'wpcom' - ); - - if ( 200 === wp_remote_retrieve_response_code( $response ) ) { - update_option( self::PACKAGE_VERSION_OPTION, $package_versions ); - } else { - set_transient( self::CACHED_FAILED_REQUEST_KEY, time(), self::CACHED_FAILED_REQUEST_EXPIRATION ); - } - } - - /** - * Check if version check is being rate limited, and update the rate limiting transient if needed. - * - * @return bool - */ - private function is_rate_limiting() { - if ( get_transient( static::RATE_LIMITER_KEY ) ) { - return true; - } - - set_transient( static::RATE_LIMITER_KEY, time(), static::RATE_LIMITER_TIMEOUT ); - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php deleted file mode 100644 index 91888c8a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php +++ /dev/null @@ -1,30 +0,0 @@ - array( - 'name' => 'IONOS', - 'logo' => array( - 'src' => '/images/ionos-logo.jpg', - 'width' => 119, - 'height' => 32, - ), - ), - ); - - /** - * A list of supported presets. - * - * @var array - */ - private static $supported_presets = array( - 'IONA' => 'jetpack_backup_daily', - ); - - /** - * Get singleton instance of class. - * - * @return Partner_Coupon - */ - public static function get_instance() { - if ( self::$instance === null ) { - self::$instance = new Partner_Coupon( array( Connection_Client::class, 'wpcom_json_api_request_as_blog' ) ); - } - - return self::$instance; - } - - /** - * Constructor. - * - * @param callable $request_as_blog Callable that executes a blog-authenticated request. - */ - public function __construct( $request_as_blog ) { - $this->request_as_blog = $request_as_blog; - } - - /** - * Register hooks to catch and purge coupon. - * - * @param string $plugin_slug The plugin slug to differentiate between Jetpack connections. - * @param string $redirect_location The location we should redirect to after catching the coupon. - */ - public static function register_coupon_admin_hooks( $plugin_slug, $redirect_location ) { - $instance = self::get_instance(); - - // We have to use an anonymous function, so we can pass along relevant information - // and not have to hardcode values for a single plugin. - // This open up the opportunity for e.g. the "all-in-one" and backup plugins - // to both implement partner coupon logic. - add_action( - 'admin_init', - function () use ( $plugin_slug, $redirect_location, $instance ) { - $instance->catch_coupon( $plugin_slug, $redirect_location ); - $instance->maybe_purge_coupon( $plugin_slug ); - } - ); - } - - /** - * Catch partner coupon and redirect to claim component. - * - * @param string $plugin_slug The plugin slug to differentiate between Jetpack connections. - * @param string $redirect_location The location we should redirect to after catching the coupon. - */ - public function catch_coupon( $plugin_slug, $redirect_location ) { - // Accept and store a partner coupon if present, and redirect to Jetpack connection screen. - $partner_coupon = isset( $_GET['jetpack-partner-coupon'] ) ? sanitize_text_field( wp_unslash( $_GET['jetpack-partner-coupon'] ) ) : false; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( $partner_coupon ) { - Jetpack_Options::update_options( - array( - self::$coupon_option => $partner_coupon, - self::$added_option => time(), - ) - ); - - $connection = new Connection_Manager( $plugin_slug ); - if ( $connection->is_connected() ) { - $redirect_location = add_query_arg( array( 'showCouponRedemption' => 1 ), $redirect_location ); - wp_safe_redirect( $redirect_location ); - } else { - wp_safe_redirect( $redirect_location ); - } - } - } - - /** - * Purge partner coupon. - * - * We try to remotely check if a coupon looks valid. We also automatically purge - * partner coupons after a certain amount of time to prevent unnecessary look-ups - * and/or promoting a product for months or years in the future due to unknown - * errors. - * - * @param string $plugin_slug The plugin slug to differentiate between Jetpack connections. - */ - public function maybe_purge_coupon( $plugin_slug ) { - // Only run coupon checks on Jetpack admin pages. - // The "admin-ui" package is responsible for registering the Jetpack admin - // page for all Jetpack plugins and has hardcoded the settings page to be - // "jetpack", so we shouldn't need to allow for dynamic/custom values. - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! isset( $_GET['page'] ) || 'jetpack' !== $_GET['page'] ) { - return; - } - - if ( ( new Status() )->is_offline_mode() ) { - return; - } - - $connection = new Connection_Manager( $plugin_slug ); - if ( ! $connection->is_connected() ) { - return; - } - - if ( $this->maybe_purge_coupon_by_added_date() ) { - return; - } - - // Limit checks to happen once a minute at most. - if ( get_transient( self::$last_check_transient ) ) { - return; - } - - set_transient( self::$last_check_transient, true, MINUTE_IN_SECONDS ); - - $this->maybe_purge_coupon_by_availability_check(); - } - - /** - * Purge coupon based on local added date. - * - * We automatically remove the coupon after a month to "self-heal" if - * something in the claim process has broken with the site. - * - * @return bool Return whether we should skip further purge checks. - */ - protected function maybe_purge_coupon_by_added_date() { - $date = Jetpack_Options::get_option( self::$added_option, '' ); - - if ( empty( $date ) ) { - return true; - } - - $expire_date = strtotime( '+30 days', $date ); - $today = time(); - - if ( $today >= $expire_date ) { - $this->delete_coupon_data(); - - return true; - } - - return false; - } - - /** - * Purge coupon based on availability check. - * - * @return bool Return whether we deleted coupon data. - */ - protected function maybe_purge_coupon_by_availability_check() { - $blog_id = Jetpack_Options::get_option( 'id', false ); - - if ( ! $blog_id ) { - return false; - } - - $coupon = self::get_coupon(); - - if ( ! $coupon ) { - return false; - } - - $response = call_user_func_array( - $this->request_as_blog, - array( - add_query_arg( - array( 'coupon_code' => $coupon['coupon_code'] ), - sprintf( - '/sites/%d/jetpack-partner/coupon/v1/site/coupon', - $blog_id - ) - ), - 2, - array( 'method' => 'GET' ), - null, - 'wpcom', - ) - ); - - $body = json_decode( wp_remote_retrieve_body( $response ), true ); - - if ( - 200 === wp_remote_retrieve_response_code( $response ) && - is_array( $body ) && - isset( $body['available'] ) && - false === $body['available'] - ) { - $this->delete_coupon_data(); - - return true; - } - - return false; - } - - /** - * Delete all coupon data. - */ - protected function delete_coupon_data() { - Jetpack_Options::delete_option( - array( - self::$coupon_option, - self::$added_option, - ) - ); - } - - /** - * Get partner coupon data. - * - * @return array|bool - */ - public static function get_coupon() { - $coupon_code = Jetpack_Options::get_option( self::$coupon_option, '' ); - - if ( ! is_string( $coupon_code ) || empty( $coupon_code ) ) { - return false; - } - - $instance = self::get_instance(); - $partner = $instance->get_coupon_partner( $coupon_code ); - - if ( ! $partner ) { - return false; - } - - $preset = $instance->get_coupon_preset( $coupon_code ); - - if ( ! $preset ) { - return false; - } - - $product = $instance->get_coupon_product( $preset ); - - if ( ! $product ) { - return false; - } - - return array( - 'coupon_code' => $coupon_code, - 'partner' => $partner, - 'preset' => $preset, - 'product' => $product, - ); - } - - /** - * Get coupon partner. - * - * @param string $coupon_code Coupon code to go through. - * @return array|bool - */ - private function get_coupon_partner( $coupon_code ) { - if ( ! is_string( $coupon_code ) || false === strpos( $coupon_code, '_' ) ) { - return false; - } - - $prefix = strtok( $coupon_code, '_' ); - $supported_partners = $this->get_supported_partners(); - - if ( ! isset( $supported_partners[ $prefix ] ) ) { - return false; - } - - return array( - 'name' => $supported_partners[ $prefix ]['name'], - 'prefix' => $prefix, - 'logo' => isset( $supported_partners[ $prefix ]['logo'] ) ? $supported_partners[ $prefix ]['logo'] : null, - ); - } - - /** - * Get coupon product. - * - * @param string $coupon_preset The preset we wish to find a product for. - * @return array|bool - */ - private function get_coupon_product( $coupon_preset ) { - if ( ! is_string( $coupon_preset ) ) { - return false; - } - - /** - * Allow for plugins to register supported products. - * - * @since 1.6.0 - * - * @param array A list of product details. - * @return array - */ - $product_details = apply_filters( 'jetpack_partner_coupon_products', array() ); - $product_slug = $this->get_supported_presets()[ $coupon_preset ]; - - foreach ( $product_details as $product ) { - if ( ! $this->array_keys_exist( array( 'title', 'slug', 'description', 'features' ), $product ) ) { - continue; - } - - if ( $product_slug === $product['slug'] ) { - return $product; - } - } - - return false; - } - - /** - * Checks if multiple keys are present in an array. - * - * @param array $needles The keys we wish to check for. - * @param array $haystack The array we want to compare keys against. - * - * @return bool - */ - private function array_keys_exist( $needles, $haystack ) { - foreach ( $needles as $needle ) { - if ( ! isset( $haystack[ $needle ] ) ) { - return false; - } - } - - return true; - } - - /** - * Get coupon preset. - * - * @param string $coupon_code Coupon code to go through. - * @return string|bool - */ - private function get_coupon_preset( $coupon_code ) { - if ( ! is_string( $coupon_code ) ) { - return false; - } - - $regex = '/^.*?_(?P.*?)_.+$/'; - $matches = array(); - - if ( ! preg_match( $regex, $coupon_code, $matches ) ) { - return false; - } - - return isset( $this->get_supported_presets()[ $matches['slug'] ] ) ? $matches['slug'] : false; - } - - /** - * Get supported partners. - * - * @return array - */ - private function get_supported_partners() { - /** - * Allow external code to add additional supported partners. - * - * @since partner-1.6.0 - * @since 2.0.0 - * - * @param array $supported_partners A list of supported partners. - * @return array - */ - return apply_filters( 'jetpack_partner_coupon_supported_partners', self::$supported_partners ); - } - - /** - * Get supported presets. - * - * @return array - */ - private function get_supported_presets() { - /** - * Allow external code to add additional supported presets. - * - * @since partner-1.6.0 - * @since 2.0.0 - * - * @param array $supported_presets A list of supported presets. - * @return array - */ - return apply_filters( 'jetpack_partner_coupon_supported_presets', self::$supported_presets ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-partner.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-partner.php deleted file mode 100644 index cfb7bb7e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-partner.php +++ /dev/null @@ -1,215 +0,0 @@ -add_code_as_query_arg( self::SUBSIDIARY_CODE, $url ); - } - - /** - * Adds the affiliate code to the passed URL. - * - * @param string $url The URL. - * - * @return string - */ - public function add_affiliate_code_as_query_arg( $url ) { - return $this->add_code_as_query_arg( self::AFFILIATE_CODE, $url ); - } - - /** - * Adds the partner subsidiary code to the passed array. - * - * @since partner-1.5.0 - * @since 2.0.0 - * - * @param array $params The parameters array. - * - * @return array - */ - public function add_subsidiary_id_to_params_array( $params ) { - if ( ! is_array( $params ) ) { - return $params; - } - return array_merge( $params, $this->get_code_as_array( self::SUBSIDIARY_CODE ) ); - } - - /** - * Adds the affiliate code to the passed array. - * - * @since partner-1.5.0 - * @since 2.0.0 - * - * @param array $params The parameters array. - * - * @return array - */ - public function add_affiliate_code_to_params_array( $params ) { - if ( ! is_array( $params ) ) { - return $params; - } - return array_merge( $params, $this->get_code_as_array( self::AFFILIATE_CODE ) ); - } - - /** - * Returns the passed URL with the partner code added as a URL query arg. - * - * @since partner-1.0.0 - * @since 2.0.0 - * - * @param string $type The partner code. - * @param string $url The URL where the partner subsidiary id will be added. - * - * @return string The passed URL with the partner code added. - */ - public function add_code_as_query_arg( $type, $url ) { - return add_query_arg( $this->get_code_as_array( $type ), $url ); - } - - /** - * Gets the partner code in an associative array format - * - * @since partner-1.5.0 - * @since 2.0.0 - * - * @param string $type The partner code. - * @return array - */ - private function get_code_as_array( $type ) { - switch ( $type ) { - case self::AFFILIATE_CODE: - $query_arg_name = 'aff'; - break; - case self::SUBSIDIARY_CODE: - $query_arg_name = 'subsidiaryId'; - break; - default: - return array(); - } - - $code = $this->get_partner_code( $type ); - - if ( '' === $code ) { - return array(); - } - - return array( $query_arg_name => $code ); - } - - /** - * Returns a partner code. - * - * @since partner-1.0.0 - * @since 2.0.0 - * - * @param string $type This can be either 'affiliate' or 'subsidiary'. Returns empty string when code is unknown. - * - * @return string The partner code. - */ - public function get_partner_code( $type ) { - switch ( $type ) { - case self::AFFILIATE_CODE: - /** - * Allow to filter the affiliate code. - * - * @since partner-1.0.0 - * @since-jetpack 6.9.0 - * @since 2.0.0 - * - * @param string $affiliate_code The affiliate code, blank by default. - */ - return apply_filters( 'jetpack_affiliate_code', get_option( 'jetpack_affiliate_code', '' ) ); - case self::SUBSIDIARY_CODE: - /** - * Allow to filter the partner subsidiary id. - * - * @since partner-1.0.0 - * @since 2.0.0 - * - * @param string $subsidiary_id The partner subsidiary id, blank by default. - */ - return apply_filters( - 'jetpack_partner_subsidiary_id', - get_option( 'jetpack_partner_subsidiary_id', '' ) - ); - default: - return ''; - } - } - - /** - * Resets the singleton for testing purposes. - */ - public static function reset() { - self::$instance = null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php deleted file mode 100644 index c6a73c3c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php +++ /dev/null @@ -1,260 +0,0 @@ -is_connected() ) { - return; - } - - $site_id = \Jetpack_Options::get_option( 'id' ); - - $body = wp_json_encode( - array( - 'active_connected_plugins' => self::$plugins, - ) - ); - - Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%d/jetpack-active-connected-plugins', $site_id ), - '2', - array( - 'headers' => array( 'content-type' => 'application/json' ), - 'method' => 'POST', - ), - $body, - 'wpcom' - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php deleted file mode 100644 index 80cd3df7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php +++ /dev/null @@ -1,100 +0,0 @@ -slug = $slug; - - // Initialize Users_Connection_Admin - $this->users_connection_admin = new Users_Connection_Admin(); - } - - /** - * Get the plugin slug. - * - * @return string - */ - public function get_slug() { - return $this->slug; - } - - /** - * Add the plugin connection info into Jetpack. - * - * @param string $name Plugin name, required. - * @param array $args Plugin arguments, optional. - * - * @return $this - * @see $this->arguments_whitelist - */ - public function add( $name, array $args = array() ) { - $args = compact( 'name' ) + array_intersect_key( $args, array_flip( $this->arguments_whitelist ) ); - - Plugin_Storage::upsert( $this->slug, $args ); - - return $this; - } - - /** - * Remove the plugin connection info from Jetpack. - * - * @return $this - */ - public function remove() { - Plugin_Storage::delete( $this->slug ); - - return $this; - } - - /** - * Determine if this plugin connection is the only one active at the moment, if any. - * - * @return bool - */ - public function is_only() { - $plugins = Plugin_Storage::get_all(); - - return ! $plugins || ( array_key_exists( $this->slug, $plugins ) && 1 === count( $plugins ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php deleted file mode 100644 index 47d1a0a0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php +++ /dev/null @@ -1,235 +0,0 @@ -connection_manager = new Manager(); - } - - /** - * Controls the single instance of this class. - * - * @static - */ - public static function init() { - if ( ! self::$instance ) { - self::$instance = new self(); - - add_filter( 'determine_current_user', array( self::$instance, 'wp_rest_authenticate' ) ); - add_filter( 'rest_authentication_errors', array( self::$instance, 'wp_rest_authentication_errors' ) ); - } - - return self::$instance; - } - - /** - * Authenticates requests from Jetpack server to WP REST API endpoints. - * Uses the existing XMLRPC request signing implementation. - * - * @param int|bool $user User ID if one has been determined, false otherwise. - * - * @return int|null The user id or null if the request was authenticated via blog token, or not authenticated at all. - */ - public function wp_rest_authenticate( $user ) { - if ( $this->doing_determine_current_user_filter ) { - return $user; - } - - $this->doing_determine_current_user_filter = true; - - try { - if ( ! empty( $user ) ) { - // Another authentication method is in effect. - return $user; - } - - add_filter( - 'jetpack_constant_default_value', - __NAMESPACE__ . '\Utils::jetpack_api_constant_filter', - 10, - 2 - ); - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! isset( $_GET['_for'] ) || 'jetpack' !== $_GET['_for'] ) { - // Nothing to do for this authentication method. - return null; - } - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! isset( $_GET['token'] ) && ! isset( $_GET['signature'] ) ) { - // Nothing to do for this authentication method. - return null; - } - - if ( ! isset( $_SERVER['REQUEST_METHOD'] ) ) { - $this->rest_authentication_status = new WP_Error( - 'rest_invalid_request', - __( 'The request method is missing.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - return null; - } - - // Only support specific request parameters that have been tested and - // are known to work with signature verification. A different method - // can be passed to the WP REST API via the '?_method=' parameter if - // needed. - if ( 'GET' !== $_SERVER['REQUEST_METHOD'] && 'POST' !== $_SERVER['REQUEST_METHOD'] ) { - $this->rest_authentication_status = new WP_Error( - 'rest_invalid_request', - __( 'This request method is not supported.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - return null; - } - if ( 'POST' !== $_SERVER['REQUEST_METHOD'] && ! empty( file_get_contents( 'php://input' ) ) ) { - $this->rest_authentication_status = new WP_Error( - 'rest_invalid_request', - __( 'This request method does not support body parameters.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - return null; - } - - $verified = $this->connection_manager->verify_xml_rpc_signature(); - - if ( - $verified && - isset( $verified['type'] ) && - 'blog' === $verified['type'] - ) { - // Site-level authentication successful. - $this->rest_authentication_status = true; - $this->rest_authentication_type = 'blog'; - return null; - } - - if ( - $verified && - isset( $verified['type'] ) && - 'user' === $verified['type'] && - ! empty( $verified['user_id'] ) - ) { - // User-level authentication successful. - $this->rest_authentication_status = true; - $this->rest_authentication_type = 'user'; - return $verified['user_id']; - } - - // Something else went wrong. Probably a signature error. - $this->rest_authentication_status = new WP_Error( - 'rest_invalid_signature', - __( 'The request is not signed correctly.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - return null; - } finally { - $this->doing_determine_current_user_filter = false; - } - } - - /** - * Report authentication status to the WP REST API. - * - * @param WP_Error|mixed $value Error from another authentication handler, null if we should handle it, or another value if not. - * @return WP_Error|boolean|null {@see WP_JSON_Server::check_authentication} - */ - public function wp_rest_authentication_errors( $value ) { - if ( null !== $value ) { - return $value; - } - return $this->rest_authentication_status; - } - - /** - * Resets the saved authentication state in between testing requests. - */ - public function reset_saved_auth_state() { - $this->rest_authentication_status = null; - $this->connection_manager->reset_saved_auth_state(); - } - - /** - * Whether the request was signed with a blog token. - * - * @since 1.29.0 - * - * @return bool True if the request was signed with a valid blog token, false otherwise. - */ - public static function is_signed_with_blog_token() { - $instance = self::init(); - - return true === $instance->rest_authentication_status && 'blog' === $instance->rest_authentication_type; - } - - /** - * Whether the request was signed with a user token. - * - * @since 6.7.0 - * - * @return bool True if the request was signed with a valid user token, false otherwise. - */ - public static function is_signed_with_user_token() { - $instance = self::init(); - - return true === $instance->rest_authentication_status && 'user' === $instance->rest_authentication_type; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php deleted file mode 100644 index 6504b488..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php +++ /dev/null @@ -1,1190 +0,0 @@ -connection = $connection; - - self::$user_permissions_error_msg = esc_html__( - 'You do not have the correct user permissions to perform this action. - Please contact your site admin if you think this is a mistake.', - 'jetpack-connection' - ); - - $jp_version = Constants::get_constant( 'JETPACK__VERSION' ); - - if ( ! $this->connection->has_connected_owner() ) { - // Register a site. - register_rest_route( - 'jetpack/v4', - '/verify_registration', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'verify_registration' ), - 'permission_callback' => '__return_true', - ) - ); - } - - // Authorize a remote user. - register_rest_route( - 'jetpack/v4', - '/remote_authorize', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::remote_authorize', - 'permission_callback' => '__return_true', - ) - ); - - // Authorize a remote user. - register_rest_route( - 'jetpack/v4', - '/remote_provision', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'remote_provision' ), - 'permission_callback' => array( $this, 'remote_provision_permission_check' ), - ) - ); - - register_rest_route( - 'jetpack/v4', - '/remote_register', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'remote_register' ), - 'permission_callback' => array( $this, 'remote_register_permission_check' ), - ) - ); - - // Connect a remote user. - register_rest_route( - 'jetpack/v4', - '/remote_connect', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'remote_connect' ), - 'permission_callback' => array( $this, 'remote_connect_permission_check' ), - ) - ); - - // The endpoint verifies blog connection and blog token validity. - register_rest_route( - 'jetpack/v4', - '/connection/check', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( $this, 'connection_check' ), - 'permission_callback' => array( $this, 'connection_check_permission_check' ), - ) - ); - - // Get current connection status of Jetpack. - register_rest_route( - 'jetpack/v4', - '/connection', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::connection_status', - 'permission_callback' => '__return_true', - ) - ); - - // Disconnect site. - register_rest_route( - 'jetpack/v4', - '/connection', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::disconnect_site', - 'permission_callback' => __CLASS__ . '::disconnect_site_permission_check', - 'args' => array( - 'isActive' => array( - 'description' => __( 'Set to false will trigger the site to disconnect.', 'jetpack-connection' ), - 'validate_callback' => function ( $value ) { - if ( false !== $value ) { - return new WP_Error( - 'rest_invalid_param', - __( 'The isActive argument should be set to false.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - - return true; - }, - 'required' => true, - ), - ), - ) - ); - - // Disconnect/unlink user from WordPress.com servers. - // this endpoint is set to override the older endpoint that was previously in the Jetpack plugin - // Override is here in case an older version of the Jetpack plugin is installed alongside an updated standalone - register_rest_route( - 'jetpack/v4', - '/connection/user', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::unlink_user', - 'permission_callback' => __CLASS__ . '::unlink_user_permission_callback', - ), - true // override other implementations - ); - - // We are only registering this route if Jetpack-the-plugin is not active or it's version is ge 10.0-alpha. - // The reason for doing so is to avoid conflicts between the Connection package and - // older versions of Jetpack, registering the same route twice. - if ( empty( $jp_version ) || version_compare( $jp_version, '10.0-alpha', '>=' ) ) { - // Get current user connection data. - register_rest_route( - 'jetpack/v4', - '/connection/data', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_user_connection_data', - 'permission_callback' => __CLASS__ . '::user_connection_data_permission_check', - ) - ); - } - - // Get list of plugins that use the Jetpack connection. - register_rest_route( - 'jetpack/v4', - '/connection/plugins', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( __CLASS__, 'get_connection_plugins' ), - 'permission_callback' => __CLASS__ . '::connection_plugins_permission_check', - ) - ); - - // Full or partial reconnect in case of connection issues. - register_rest_route( - 'jetpack/v4', - '/connection/reconnect', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'connection_reconnect' ), - 'permission_callback' => __CLASS__ . '::jetpack_reconnect_permission_check', - ) - ); - - // Register the site (get `blog_token`). - register_rest_route( - 'jetpack/v4', - '/connection/register', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( $this, 'connection_register' ), - 'permission_callback' => __CLASS__ . '::jetpack_register_permission_check', - 'args' => array( - 'from' => array( - 'description' => __( 'Indicates where the registration action was triggered for tracking/segmentation purposes', 'jetpack-connection' ), - 'type' => 'string', - ), - 'redirect_uri' => array( - 'description' => __( 'URI of the admin page where the user should be redirected after connection flow', 'jetpack-connection' ), - 'type' => 'string', - ), - 'plugin_slug' => array( - 'description' => __( 'Indicates from what plugin the request is coming from', 'jetpack-connection' ), - 'type' => 'string', - ), - ), - ) - ); - - // Get authorization URL. - register_rest_route( - 'jetpack/v4', - '/connection/authorize_url', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( $this, 'connection_authorize_url' ), - 'permission_callback' => __CLASS__ . '::user_connection_data_permission_check', - 'args' => array( - 'redirect_uri' => array( - 'description' => __( 'URI of the admin page where the user should be redirected after connection flow', 'jetpack-connection' ), - 'type' => 'string', - ), - ), - ) - ); - - // Provider-specific authorization URL endpoint - register_rest_route( - 'jetpack/v4', - '/connection/authorize_url/(?P[a-zA-Z]+)', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( $this, 'connection_authorize_url_provider' ), - 'permission_callback' => __CLASS__ . '::user_connection_data_permission_check', - 'args' => array( - 'provider' => array( - 'description' => __( 'Authentication provider (google, github, apple, link)', 'jetpack-connection' ), - 'type' => 'string', - 'required' => true, - 'enum' => array( 'google', 'github', 'apple', 'link' ), - ), - 'redirect_uri' => array( - 'description' => __( 'URI of the admin page where the user should be redirected after connection flow', 'jetpack-connection' ), - 'type' => 'string', - ), - 'email_address' => array( - 'description' => __( 'Email address for magic link authentication', 'jetpack-connection' ), - 'type' => 'string', - 'format' => 'email', - ), - ), - ) - ); - - register_rest_route( - 'jetpack/v4', - '/user-token', - array( - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( static::class, 'update_user_token' ), - 'permission_callback' => array( static::class, 'update_user_token_permission_check' ), - 'args' => array( - 'user_token' => array( - 'description' => __( 'New user token', 'jetpack-connection' ), - 'type' => 'string', - 'required' => true, - ), - 'is_connection_owner' => array( - 'description' => __( 'Is connection owner', 'jetpack-connection' ), - 'type' => 'boolean', - ), - ), - ), - ) - ); - - // Set the connection owner. - register_rest_route( - 'jetpack/v4', - '/connection/owner', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( static::class, 'set_connection_owner' ), - 'permission_callback' => array( static::class, 'set_connection_owner_permission_check' ), - 'args' => array( - 'owner' => array( - 'description' => __( 'New owner', 'jetpack-connection' ), - 'type' => 'integer', - 'required' => true, - ), - ), - ) - ); - } - - /** - * Handles verification that a site is registered. - * - * @since 1.7.0 - * @since-jetpack 5.4.0 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return string|WP_Error - */ - public function verify_registration( WP_REST_Request $request ) { - $registration_data = array( $request['secret_1'], $request['state'] ); - - return $this->connection->handle_registration( $registration_data ); - } - - /** - * Handles verification that a site is registered - * - * @since 1.7.0 - * @since-jetpack 5.4.0 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return array|WP_Error - */ - public static function remote_authorize( $request ) { - $xmlrpc_server = new Jetpack_XMLRPC_Server(); - $result = $xmlrpc_server->remote_authorize( $request ); - - if ( is_a( $result, 'IXR_Error' ) ) { - $result = new WP_Error( $result->code, $result->message ); - } - - return $result; - } - - /** - * Initiate the site provisioning process. - * - * @since 2.5.0 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return WP_Error|array - */ - public function remote_provision( WP_REST_Request $request ) { - $request_data = $request->get_params(); - - if ( current_user_can( 'jetpack_connect_user' ) ) { - $request_data['local_user'] = get_current_user_id(); - } - - $xmlrpc_server = new Jetpack_XMLRPC_Server(); - $result = $xmlrpc_server->remote_provision( $request_data ); - - if ( is_a( $result, 'IXR_Error' ) ) { - $result = new WP_Error( $result->code, $result->message ); - } - - return $result; - } - - /** - * Connect a remote user. - * - * @since 2.6.0 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return WP_Error|array - */ - public static function remote_connect( WP_REST_Request $request ) { - $xmlrpc_server = new Jetpack_XMLRPC_Server(); - $result = $xmlrpc_server->remote_connect( $request ); - - if ( is_a( $result, 'IXR_Error' ) ) { - $result = new WP_Error( $result->code, $result->message ); - } - - return $result; - } - - /** - * Register the site so that a plan can be provisioned. - * - * @since 2.5.0 - * - * @param WP_REST_Request $request The request object. - * - * @return WP_Error|array - */ - public function remote_register( WP_REST_Request $request ) { - $xmlrpc_server = new Jetpack_XMLRPC_Server(); - $result = $xmlrpc_server->remote_register( $request ); - - if ( is_a( $result, 'IXR_Error' ) ) { - $result = new WP_Error( $result->code, $result->message ); - } - - return $result; - } - - /** - * Remote provision endpoint permission check. - * - * @param WP_REST_Request $request The request object. - * - * @return true|WP_Error - */ - public function remote_provision_permission_check( WP_REST_Request $request ) { - if ( empty( $request['local_user'] ) && current_user_can( 'jetpack_connect_user' ) ) { - return true; - } - - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'invalid_permission_remote_provision', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Remote connect endpoint permission check. - * - * @return true|WP_Error - */ - public function remote_connect_permission_check() { - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'invalid_permission_remote_connect', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Remote register endpoint permission check. - * - * @return true|WP_Error - */ - public function remote_register_permission_check() { - if ( $this->connection->has_connected_owner() ) { - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'already_registered', __( 'Blog is already registered', 'jetpack-connection' ), 400 ); - } - - return true; - } - - /** - * Get connection status for this Jetpack site. - * - * @since 1.7.0 - * @since-jetpack 4.3.0 - * - * @param bool $rest_response Should we return a rest response or a simple array. Default to rest response. - * - * @return WP_REST_Response|array Connection information. - */ - public static function connection_status( $rest_response = true ) { - $status = new Status(); - $connection = new Manager(); - - $connection_status = array( - 'isActive' => $connection->has_connected_owner(), // TODO deprecate this. - 'isStaging' => $status->in_safe_mode(), // TODO deprecate this. - 'isRegistered' => $connection->is_connected(), - 'isUserConnected' => $connection->is_user_connected(), - 'hasConnectedOwner' => $connection->has_connected_owner(), - 'offlineMode' => array( - 'isActive' => $status->is_offline_mode(), - 'constant' => defined( 'JETPACK_DEV_DEBUG' ) && JETPACK_DEV_DEBUG, - 'url' => $status->is_local_site(), - /** This filter is documented in packages/status/src/class-status.php */ - 'filter' => ( apply_filters( 'jetpack_development_mode', false ) || apply_filters( 'jetpack_offline_mode', false ) ), // jetpack_development_mode is deprecated. - 'wpLocalConstant' => defined( 'WP_LOCAL_DEV' ) && WP_LOCAL_DEV, - ), - 'isPublic' => '1' == get_option( 'blog_public' ), // phpcs:ignore Universal.Operators.StrictComparisons.LooseEqual - ); - - /** - * Filters the connection status data. - * - * @since 1.25.0 - * - * @param array An array containing the connection status data. - */ - $connection_status = apply_filters( 'jetpack_connection_status', $connection_status ); - - if ( $rest_response ) { - return rest_ensure_response( - $connection_status - ); - } else { - return $connection_status; - } - } - - /** - * Get plugins connected to the Jetpack. - * - * @param bool $rest_response Should we return a rest response or a simple array. Default to rest response. - * - * @since 1.13.1 - * @since 1.38.0 Added $rest_response param. - * - * @return WP_REST_Response|WP_Error Response or error object, depending on the request result. - */ - public static function get_connection_plugins( $rest_response = true ) { - $plugins = ( new Manager() )->get_connected_plugins(); - - if ( is_wp_error( $plugins ) ) { - return $plugins; - } - - array_walk( - $plugins, - function ( &$data, $slug ) { - $data['slug'] = $slug; - } - ); - - if ( $rest_response ) { - return rest_ensure_response( array_values( $plugins ) ); - } - - return array_values( $plugins ); - } - - /** - * Verify that user can view Jetpack admin page and can activate plugins. - * - * @since 1.15.0 - * - * @return bool|WP_Error Whether user has the capability 'activate_plugins'. - */ - public static function activate_plugins_permission_check() { - if ( current_user_can( 'activate_plugins' ) ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_activate_plugins', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Permission check for the connection_plugins endpoint - * - * @return bool|WP_Error - */ - public static function connection_plugins_permission_check() { - if ( true === static::activate_plugins_permission_check() ) { - return true; - } - - if ( true === static::is_request_signed_by_jetpack_debugger() ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_activate_plugins', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Permission check for the disconnect site endpoint. - * - * @since 1.30.1 - * - * @since 5.1.0 Modified the permission check to accept requests signed with blog tokens. - * - * @return bool|WP_Error True if user is able to disconnect the site or the request is signed with a blog token (aka a direct request from WPCOM). - */ - public static function disconnect_site_permission_check() { - if ( current_user_can( 'jetpack_disconnect' ) ) { - return true; - } - - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'invalid_user_permission_jetpack_disconnect', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Verify that a user can use the /connection/user endpoint. Has to be a registered user and be currently linked. - * - * @since 6.3.3 - * - * @return bool|WP_Error True if user is able to unlink. - */ - public static function unlink_user_permission_callback() { - // This is a mapped capability - // phpcs:ignore WordPress.WP.Capabilities.Unknown - if ( current_user_can( 'jetpack_unlink_user' ) && ( new Manager() )->is_user_connected( get_current_user_id() ) ) { - return true; - } - - return new WP_Error( - 'invalid_user_permission_unlink_user', - self::get_user_permissions_error_msg(), - array( 'status' => rest_authorization_required_code() ) - ); - } - - /** - * Get miscellaneous user data related to the connection. Similar data available in old "My Jetpack". - * Information about the master/primary user. - * Information about the current user. - * - * @param bool $rest_response Should we return a rest response or a simple array. Default to rest response. - * - * @since 1.30.1 - * - * @return \WP_REST_Response|array - */ - public static function get_user_connection_data( $rest_response = true ) { - $blog_id = \Jetpack_Options::get_option( 'id' ); - - $connection = new Manager(); - - $current_user = wp_get_current_user(); - $connection_owner = $connection->get_connection_owner(); - - $owner_display_name = false === $connection_owner ? null : $connection_owner->display_name; - - $is_user_connected = $connection->is_user_connected(); - $is_master_user = false === $connection_owner ? false : ( $current_user->ID === $connection_owner->ID ); - $wpcom_user_data = $connection->get_connected_user_data(); - - // Add connected user gravatar to the returned wpcom_user_data. - // Probably we shouldn't do this when $wpcom_user_data is false, but we have been since 2016 so - // clients probably expect that by now. - if ( false === $wpcom_user_data ) { - $wpcom_user_data = array(); - } - $wpcom_user_data['avatar'] = ( ! empty( $wpcom_user_data['email'] ) ? - get_avatar_url( - $wpcom_user_data['email'], - array( - 'size' => 64, - 'default' => 'mysteryman', - ) - ) - : false ); - - $current_user_connection_data = array( - 'isConnected' => $is_user_connected, - 'isMaster' => $is_master_user, - 'username' => $current_user->user_login, - 'id' => $current_user->ID, - 'blogId' => $blog_id, - 'wpcomUser' => $wpcom_user_data, - 'gravatar' => get_avatar_url( $current_user->ID ), - 'permissions' => array( - 'connect' => current_user_can( 'jetpack_connect' ), - 'connect_user' => current_user_can( 'jetpack_connect_user' ), - // This is a mapped capability - // phpcs:ignore WordPress.WP.Capabilities.Unknown - 'unlink_user' => current_user_can( 'jetpack_unlink_user' ), - 'disconnect' => current_user_can( 'jetpack_disconnect' ), - 'manage_options' => current_user_can( 'manage_options' ), - ), - ); - - /** - * Filters the current user connection data. - * - * @since 1.30.1 - * - * @param array An array containing the current user connection data. - */ - $current_user_connection_data = apply_filters( 'jetpack_current_user_connection_data', $current_user_connection_data ); - - $response = array( - 'currentUser' => $current_user_connection_data, - 'connectionOwner' => $owner_display_name, - 'isRegistered' => $connection->is_connected(), - ); - - if ( $rest_response ) { - return rest_ensure_response( $response ); - } - - return $response; - } - - /** - * Permission check for the connection/data endpoint - * - * @return bool|WP_Error - */ - public static function user_connection_data_permission_check() { - if ( current_user_can( 'jetpack_connect_user' ) ) { - return true; - } - - return new WP_Error( - 'invalid_user_permission_user_connection_data', - self::get_user_permissions_error_msg(), - array( 'status' => rest_authorization_required_code() ) - ); - } - - /** - * Verifies if the request was signed with the Jetpack Debugger key - * - * @param string|null $pub_key The public key used to verify the signature. Default is the Jetpack Debugger key. This is used for testing purposes. - * - * @return bool - */ - public static function is_request_signed_by_jetpack_debugger( $pub_key = null ) { - // phpcs:disable WordPress.Security.NonceVerification.Recommended - if ( ! isset( $_GET['signature'] ) || ! isset( $_GET['timestamp'] ) || ! isset( $_GET['url'] ) || ! isset( $_GET['rest_route'] ) ) { - return false; - } - - // signature timestamp must be within 5min of current time. - if ( abs( time() - (int) $_GET['timestamp'] ) > 300 ) { - return false; - } - - $signature = base64_decode( filter_var( wp_unslash( $_GET['signature'] ) ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - - $signature_data = wp_json_encode( - array( - 'rest_route' => filter_var( wp_unslash( $_GET['rest_route'] ) ), - 'timestamp' => (int) $_GET['timestamp'], - 'url' => filter_var( wp_unslash( $_GET['url'] ) ), - ) - ); - - if ( - ! function_exists( 'openssl_verify' ) - || 1 !== openssl_verify( - $signature_data, - $signature, - $pub_key ? $pub_key : static::JETPACK__DEBUGGER_PUBLIC_KEY - ) - ) { - return false; - } - - // phpcs:enable WordPress.Security.NonceVerification.Recommended - - return true; - } - - /** - * Verify that user is allowed to disconnect Jetpack. - * - * @since 1.15.0 - * - * @return bool|WP_Error Whether user has the capability 'jetpack_disconnect'. - */ - public static function jetpack_reconnect_permission_check() { - if ( current_user_can( 'jetpack_reconnect' ) ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_jetpack_disconnect', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Returns generic error message when user is not allowed to perform an action. - * - * @return string The error message. - */ - public static function get_user_permissions_error_msg() { - return self::$user_permissions_error_msg; - } - - /** - * The endpoint tried to partially or fully reconnect the website to WP.com. - * - * @since 1.15.0 - * - * @return \WP_REST_Response|WP_Error - */ - public function connection_reconnect() { - $response = array(); - - $next = null; - - $result = $this->connection->restore(); - - if ( is_wp_error( $result ) ) { - $response = $result; - } elseif ( is_string( $result ) ) { - $next = $result; - } else { - $next = true === $result ? 'completed' : 'failed'; - } - - switch ( $next ) { - case 'authorize': - $response['status'] = 'in_progress'; - $response['authorizeUrl'] = $this->connection->get_authorization_url(); - break; - case 'completed': - $response['status'] = 'completed'; - /** - * Action fired when reconnection has completed successfully. - * - * @since 1.18.1 - */ - do_action( 'jetpack_reconnection_completed' ); - break; - case 'failed': - $response = new WP_Error( 'Reconnect failed' ); - break; - } - - return rest_ensure_response( $response ); - } - - /** - * Verify that user is allowed to connect Jetpack. - * - * @since 1.26.0 - * - * @return bool|WP_Error Whether user has the capability 'jetpack_connect'. - */ - public static function jetpack_register_permission_check() { - if ( current_user_can( 'jetpack_connect' ) ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_jetpack_connect', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * The endpoint tried to connect Jetpack site to WPCOM. - * - * @since 1.7.0 - * @since 6.7.0 No longer needs `registration_nonce`. - * @since-jetpack 7.7.0 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public function connection_register( $request ) { - if ( isset( $request['from'] ) ) { - $this->connection->add_register_request_param( 'from', (string) $request['from'] ); - } - - if ( ! empty( $request['plugin_slug'] ) ) { - // If `plugin_slug` matches a plugin using the connection, let's inform the plugin that is establishing the connection. - $connected_plugin = Plugin_Storage::get_one( (string) $request['plugin_slug'] ); - if ( ! is_wp_error( $connected_plugin ) && ! empty( $connected_plugin ) ) { - $this->connection->set_plugin_instance( new Plugin( (string) $request['plugin_slug'] ) ); - } - } - - $result = $this->connection->try_registration(); - - if ( is_wp_error( $result ) ) { - return $result; - } - - $redirect_uri = $request->get_param( 'redirect_uri' ) ? admin_url( $request->get_param( 'redirect_uri' ) ) : null; - - $authorize_url = ( new Authorize_Redirect( $this->connection ) )->build_authorize_url( $redirect_uri ); - - /** - * Filters the response of jetpack/v4/connection/register endpoint - * - * @param array $response Array response - * @since 1.27.0 - */ - $response_body = apply_filters( - 'jetpack_register_site_rest_response', - array() - ); - - // We manipulate the alternate URLs after the filter is applied, so they can not be overwritten. - $response_body['authorizeUrl'] = $authorize_url; - if ( ! empty( $response_body['alternateAuthorizeUrl'] ) ) { - $response_body['alternateAuthorizeUrl'] = Redirect::get_url( $response_body['alternateAuthorizeUrl'] ); - } - - return rest_ensure_response( $response_body ); - } - - /** - * Get the authorization URL. - * - * @since 1.27.0 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public function connection_authorize_url( $request ) { - $redirect_uri = $request->get_param( 'redirect_uri' ) ? admin_url( $request->get_param( 'redirect_uri' ) ) : null; - $authorize_url = $this->connection->get_authorization_url( null, $redirect_uri ); - - return rest_ensure_response( - array( - 'authorizeUrl' => $authorize_url, - ) - ); - } - - /** - * The endpoint tried to partially or fully reconnect the website to WP.com. - * - * @since 1.29.0 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public static function update_user_token( $request ) { - $token_parts = explode( '.', $request['user_token'] ); - - if ( count( $token_parts ) !== 3 || ! (int) $token_parts[2] || ! ctype_digit( $token_parts[2] ) ) { - return new WP_Error( 'invalid_argument_user_token', esc_html__( 'Invalid user token is provided', 'jetpack-connection' ) ); - } - - $user_id = (int) $token_parts[2]; - - if ( false === get_userdata( $user_id ) ) { - return new WP_Error( 'invalid_argument_user_id', esc_html__( 'Invalid user id is provided', 'jetpack-connection' ) ); - } - - $connection = new Manager(); - - if ( ! $connection->is_connected() ) { - return new WP_Error( 'site_not_connected', esc_html__( 'Site is not connected', 'jetpack-connection' ) ); - } - - $is_connection_owner = isset( $request['is_connection_owner'] ) - ? (bool) $request['is_connection_owner'] - : ( new Manager() )->get_connection_owner_id() === $user_id; - - ( new Tokens() )->update_user_token( $user_id, $request['user_token'], $is_connection_owner ); - - /** - * Fires when the user token gets successfully replaced. - * - * @since 1.29.0 - * - * @param int $user_id User ID. - * @param string $token New user token. - */ - do_action( 'jetpack_updated_user_token', $user_id, $request['user_token'] ); - - return rest_ensure_response( - array( - 'success' => true, - ) - ); - } - - /** - * Disconnects Jetpack from the WordPress.com Servers - * - * @since 1.30.1 - * - * @return bool|WP_Error True if Jetpack successfully disconnected. - */ - public static function disconnect_site() { - $connection = new Manager(); - - if ( $connection->is_connected() ) { - $connection->disconnect_site(); - return rest_ensure_response( array( 'code' => 'success' ) ); - } - - return new WP_Error( - 'disconnect_failed', - esc_html__( 'Failed to disconnect the site as it appears already disconnected.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - - /** - * Unlinks current user from the WordPress.com Servers. - * - * @since 6.3.3 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return bool|WP_Error True if user successfully unlinked. - */ - public static function unlink_user( $request ) { - - if ( ! isset( $request['linked'] ) || false !== $request['linked'] ) { - return new WP_Error( 'invalid_param', esc_html__( 'Invalid Parameter', 'jetpack-connection' ), array( 'status' => 404 ) ); - } - - // If the user is also connection owner, we need to disconnect all users. Since disconnecting all users is a destructive action, we need to pass a parameter to confirm the action. - $disconnect_all_users = false; - - if ( ( new Manager() )->get_connection_owner_id() === get_current_user_id() ) { - if ( isset( $request['disconnect-all-users'] ) && false !== $request['disconnect-all-users'] ) { - $disconnect_all_users = true; - } else { - return new WP_Error( 'unlink_user_failed', esc_html__( 'Unable to unlink the connection owner.', 'jetpack-connection' ), array( 'status' => 400 ) ); - } - } - - // Allow admins to force a disconnect by passing the "force" parameter - // This allows an admin to disconnect themselves - if ( isset( $request['force'] ) && false !== $request['force'] && current_user_can( 'manage_options' ) && ( new Manager( 'jetpack' ) )->disconnect_user_force( get_current_user_id(), $disconnect_all_users ) ) { - return rest_ensure_response( - array( - 'code' => 'success', - ) - ); - } elseif ( ( new Manager( 'jetpack' ) )->disconnect_user() ) { - return rest_ensure_response( - array( - 'code' => 'success', - ) - ); - } - - return new WP_Error( 'unlink_user_failed', esc_html__( 'Was not able to unlink the user. Please try again.', 'jetpack-connection' ), array( 'status' => 400 ) ); - } - - /** - * Verify that the API client is allowed to replace user token. - * - * @since 1.29.0 - * - * @return bool|WP_Error - */ - public static function update_user_token_permission_check() { - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'invalid_permission_update_user_token', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Change the connection owner. - * - * @since 1.29.0 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public static function set_connection_owner( $request ) { - $new_owner_id = $request['owner']; - - $owner_set = ( new Manager() )->update_connection_owner( $new_owner_id ); - - if ( is_wp_error( $owner_set ) ) { - return $owner_set; - } - - return rest_ensure_response( - array( - 'code' => 'success', - ) - ); - } - - /** - * Check that user has permission to change the master user. - * - * @since 1.7.0 - * @since-jetpack 6.2.0 - * @since-jetpack 7.7.0 Update so that any user with jetpack_disconnect privs can set owner. - * - * @return bool|WP_Error True if user is able to change master user. - */ - public static function set_connection_owner_permission_check() { - if ( current_user_can( 'jetpack_disconnect' ) ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_set_connection_owner', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * The endpoint verifies blog connection and blog token validity. - * - * @since 2.7.0 - * - * @return mixed|null - */ - public function connection_check() { - /** - * Filters the successful response of the REST API test_connection method - * - * @param string $response The response string. - */ - $status = apply_filters( 'jetpack_rest_connection_check_response', 'success' ); - - return rest_ensure_response( - array( - 'status' => $status, - ) - ); - } - - /** - * Remote connect endpoint permission check. - * - * @return true|WP_Error - */ - public function connection_check_permission_check() { - if ( current_user_can( 'jetpack_connect' ) ) { - return true; - } - - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( 'invalid_permission_connection_check', self::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Provider-specific authorization URL endpoint - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public function connection_authorize_url_provider( $request ) { - $provider = $request['provider']; - $redirect_uri = $request['redirect_uri'] ?? ''; - - // Validate magic link parameters if provider is 'link' - if ( 'link' === $provider ) { - if ( empty( $request['email_address'] ) ) { - return new WP_Error( - 'missing_email', - __( 'Email address is required for magic link authentication.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - - // Sanitize email address - $email = sanitize_email( $request['email_address'] ); - if ( ! is_email( $email ) ) { - return new WP_Error( - 'invalid_email', - __( 'Invalid email address format.', 'jetpack-connection' ), - array( 'status' => 400 ) - ); - } - } - - $authorize_url = ( new Authorize_Redirect( $this->connection ) )->build_authorize_url( - $redirect_uri, - false, - false, - $provider, - array( - 'email_address' => $email ?? '', - ) - ); - - return rest_ensure_response( - array( - 'authorizeUrl' => $authorize_url, - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php deleted file mode 100644 index 6f5de990..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php +++ /dev/null @@ -1,282 +0,0 @@ - time() - ) { - return $secrets[ $secret_name ]; - } - - $secret_value = array( - 'secret_1' => call_user_func( $callable ), - 'secret_2' => call_user_func( $callable ), - 'exp' => time() + $exp, - ); - - $secrets[ $secret_name ] = $secret_value; - - $res = Jetpack_Options::update_raw_option( self::LEGACY_SECRETS_OPTION_NAME, $secrets ); - return $res ? $secrets[ $secret_name ] : false; - } - - /** - * Returns two secret tokens and the end of life timestamp for them. - * - * @param String $action The action name. - * @param Integer $user_id The user identifier. - * @return string|array an array of secrets or an error string. - */ - public function get( $action, $user_id ) { - $secret_name = 'jetpack_' . $action . '_' . $user_id; - $secrets = Jetpack_Options::get_raw_option( - self::LEGACY_SECRETS_OPTION_NAME, - array() - ); - - if ( ! isset( $secrets[ $secret_name ] ) ) { - return self::SECRETS_MISSING; - } - - if ( $secrets[ $secret_name ]['exp'] < time() ) { - $this->delete( $action, $user_id ); - return self::SECRETS_EXPIRED; - } - - return $secrets[ $secret_name ]; - } - - /** - * Deletes secret tokens in case they, for example, have expired. - * - * @param String $action The action name. - * @param Integer $user_id The user identifier. - */ - public function delete( $action, $user_id ) { - $secret_name = 'jetpack_' . $action . '_' . $user_id; - $secrets = Jetpack_Options::get_raw_option( - self::LEGACY_SECRETS_OPTION_NAME, - array() - ); - if ( isset( $secrets[ $secret_name ] ) ) { - unset( $secrets[ $secret_name ] ); - Jetpack_Options::update_raw_option( self::LEGACY_SECRETS_OPTION_NAME, $secrets ); - } - } - - /** - * Verify a Previously Generated Secret. - * - * @param string $action The type of secret to verify. - * @param string $secret_1 The secret string to compare to what is stored. - * @param int $user_id The user ID of the owner of the secret. - * @return WP_Error|string WP_Error on failure, secret_2 on success. - */ - public function verify( $action, $secret_1, $user_id ) { - $allowed_actions = array( 'register', 'authorize', 'publicize' ); - if ( ! in_array( $action, $allowed_actions, true ) ) { - return new WP_Error( 'unknown_verification_action', 'Unknown Verification Action', 400 ); - } - - $user = get_user_by( 'id', $user_id ); - - /** - * We've begun verifying the previously generated secret. - * - * @since 1.7.0 - * @since-jetpack 7.5.0 - * - * @param string $action The type of secret to verify. - * @param \WP_User $user The user object. - */ - do_action( 'jetpack_verify_secrets_begin', $action, $user ); - - /** Closure to run the 'fail' action and return an error. */ - $return_error = function ( WP_Error $error ) use ( $action, $user ) { - /** - * Verifying of the previously generated secret has failed. - * - * @since 1.7.0 - * @since-jetpack 7.5.0 - * - * @param string $action The type of secret to verify. - * @param \WP_User $user The user object. - * @param WP_Error $error The error object. - */ - do_action( 'jetpack_verify_secrets_fail', $action, $user, $error ); - - return $error; - }; - - $stored_secrets = $this->get( $action, $user_id ); - $this->delete( $action, $user_id ); - - $error = null; - if ( empty( $secret_1 ) ) { - $error = $return_error( - new WP_Error( - 'verify_secret_1_missing', - /* translators: "%s" is the name of a paramter. It can be either "secret_1" or "state". */ - sprintf( __( 'The required "%s" parameter is missing.', 'jetpack-connection' ), 'secret_1' ), - 400 - ) - ); - } elseif ( ! is_string( $secret_1 ) ) { - $error = $return_error( - new WP_Error( - 'verify_secret_1_malformed', - /* translators: "%s" is the name of a paramter. It can be either "secret_1" or "state". */ - sprintf( __( 'The required "%s" parameter is malformed.', 'jetpack-connection' ), 'secret_1' ), - 400 - ) - ); - } elseif ( empty( $user_id ) ) { - // $user_id is passed around during registration as "state". - $error = $return_error( - new WP_Error( - 'state_missing', - /* translators: "%s" is the name of a paramter. It can be either "secret_1" or "state". */ - sprintf( __( 'The required "%s" parameter is missing.', 'jetpack-connection' ), 'state' ), - 400 - ) - ); - } elseif ( ! ctype_digit( (string) $user_id ) ) { - $error = $return_error( - new WP_Error( - 'state_malformed', - /* translators: "%s" is the name of a paramter. It can be either "secret_1" or "state". */ - sprintf( __( 'The required "%s" parameter is malformed.', 'jetpack-connection' ), 'state' ), - 400 - ) - ); - } elseif ( self::SECRETS_MISSING === $stored_secrets ) { - $error = $return_error( - new WP_Error( - 'verify_secrets_missing', - __( 'Verification secrets not found', 'jetpack-connection' ), - 400 - ) - ); - } elseif ( self::SECRETS_EXPIRED === $stored_secrets ) { - $error = $return_error( - new WP_Error( - 'verify_secrets_expired', - __( 'Verification took too long', 'jetpack-connection' ), - 400 - ) - ); - } elseif ( ! $stored_secrets ) { - $error = $return_error( - new WP_Error( - 'verify_secrets_empty', - __( 'Verification secrets are empty', 'jetpack-connection' ), - 400 - ) - ); - } elseif ( is_wp_error( $stored_secrets ) ) { - $stored_secrets->add_data( 400 ); - $error = $return_error( $stored_secrets ); - } elseif ( empty( $stored_secrets['secret_1'] ) || empty( $stored_secrets['secret_2'] ) || empty( $stored_secrets['exp'] ) ) { - $error = $return_error( - new WP_Error( - 'verify_secrets_incomplete', - __( 'Verification secrets are incomplete', 'jetpack-connection' ), - 400 - ) - ); - } elseif ( ! hash_equals( $secret_1, $stored_secrets['secret_1'] ) ) { - $error = $return_error( - new WP_Error( - 'verify_secrets_mismatch', - __( 'Secret mismatch', 'jetpack-connection' ), - 400 - ) - ); - } - - // Something went wrong during the checks, returning the error. - if ( ! empty( $error ) ) { - return $error; - } - - /** - * We've succeeded at verifying the previously generated secret. - * - * @since 1.7.0 - * @since-jetpack 7.5.0 - * - * @param string $action The type of secret to verify. - * @param \WP_User $user The user object. - */ - do_action( 'jetpack_verify_secrets_success', $action, $user ); - - return $stored_secrets['secret_2']; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php deleted file mode 100644 index a9ca288e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php +++ /dev/null @@ -1,243 +0,0 @@ - new URL, 'host' => new Host, 'new_signature => New signature if url was changed ] - */ - public function server_sandbox_request_parameters( $sandbox, $url, $headers, $data = null, $method = 'GET' ) { - $host = ''; - $new_signature = ''; - - if ( ! is_string( $sandbox ) || ! is_string( $url ) ) { - return array( - 'url' => $url, - 'host' => $host, - 'new_signature' => $new_signature, - ); - } - - $url_host = wp_parse_url( $url, PHP_URL_HOST ); - - switch ( $url_host ) { - case 'public-api.wordpress.com': - case 'jetpack.wordpress.com': - case 'jetpack.com': - case 'dashboard.wordpress.com': - $host = isset( $headers['Host'] ) ? $headers['Host'] : $url_host; - $original_url = $url; - $url = preg_replace( - '@^(https?://)' . preg_quote( $url_host, '@' ) . '(?=[/?#].*|$)@', - '${1}' . $sandbox, - $url, - 1 - ); - - /** - * Whether to add the X Debug query parameter to the request made to the Sandbox - * - * @since 1.36.0 - * - * @param bool $add_parameter Whether to add the parameter to the request or not. Default is to false. - * @param string $url The URL of the request being made. - * @param string $host The host of the request being made. - */ - if ( apply_filters( 'jetpack_sandbox_add_profile_parameter', false, $url, $host ) ) { - $url = add_query_arg( 'XDEBUG_PROFILE', 1, $url ); - - // URL has been modified since the signature was created. We'll need a new one. - $original_url = add_query_arg( 'XDEBUG_PROFILE', 1, $original_url ); - $new_signature = $this->get_new_signature( $original_url, $headers, $data, $method ); - - } - } - - return compact( 'url', 'host', 'new_signature' ); - } - - /** - * Gets a new signature for the request - * - * @param string $url The new URL to be signed. - * @param array $headers The headers of the request about to be made. - * @param string $data The body of request about to be made. - * @param string $method The method of the request about to be made. - * @return string|null - */ - private function get_new_signature( $url, $headers, $data, $method ) { - - if ( ! empty( $headers['Authorization'] ) ) { - $a_headers = $this->extract_authorization_headers( $headers ); - if ( ! empty( $a_headers ) ) { - $token_details = explode( ':', $a_headers['token'] ); - - if ( count( $token_details ) === 3 ) { - $user_id = $token_details[2]; - $token = ( new Tokens() )->get_access_token( $user_id ); - $time_diff = (int) \Jetpack_Options::get_option( 'time_diff' ); - $jetpack_signature = new \Jetpack_Signature( $token->secret, $time_diff ); - - $signature = $jetpack_signature->sign_request( - $a_headers['token'], - $a_headers['timestamp'], - $a_headers['nonce'], - $a_headers['body-hash'], - $method, - $url, - $data, - false - ); - - if ( $signature && ! is_wp_error( $signature ) ) { - return $signature; - } elseif ( is_wp_error( $signature ) ) { - $this->log_new_signature_error( $signature->get_error_message() ); - } - } else { - $this->log_new_signature_error( 'Malformed token on Authorization Header' ); - } - } else { - $this->log_new_signature_error( 'Error extracting Authorization Header' ); - } - } else { - $this->log_new_signature_error( 'Empty Authorization Header' ); - } - } - - /** - * Logs error if the attempt to create a new signature fails - * - * @param string $message The error message. - * @return void - */ - private function log_new_signature_error( $message ) { - if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) { - error_log( sprintf( "SANDBOXING: Error re-signing the request. '%s'", $message ) ); // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_error_log - } - } - - /** - * Extract the values in the Authorization header into an array - * - * @param array $headers The headers of the request about to be made. - * @return array|null - */ - public function extract_authorization_headers( $headers ) { - if ( ! empty( $headers['Authorization'] ) && is_string( $headers['Authorization'] ) ) { - $header = str_replace( 'X_JETPACK ', '', $headers['Authorization'] ); - $vars = explode( ' ', $header ); - $result = array(); - foreach ( $vars as $var ) { - $elements = explode( '"', $var ); - if ( count( $elements ) === 3 ) { - $result[ substr( $elements[0], 0, -1 ) ] = $elements[1]; - } - } - return $result; - } - } - - /** - * Modifies parameters of request in order to send the request to the - * server specified by `JETPACK__SANDBOX_DOMAIN`. - * - * Attached to the `requests-requests.before_request` filter. - * - * @param string $url URL of request about to be made. - * @param array $headers Headers of request about to be made. - * @param array|string $data Data of request about to be made. - * @param string $type Type of request about to be made. - * @return void - */ - public function server_sandbox( &$url, &$headers, &$data = null, &$type = null ) { - if ( ! Constants::get_constant( 'JETPACK__SANDBOX_DOMAIN' ) ) { - return; - } - - $original_url = $url; - - $request_parameters = $this->server_sandbox_request_parameters( Constants::get_constant( 'JETPACK__SANDBOX_DOMAIN' ), $url, $headers, $data, $type ); - - $url = $request_parameters['url']; - - if ( $request_parameters['host'] ) { - $headers['Host'] = $request_parameters['host']; - - if ( $request_parameters['new_signature'] ) { - $headers['Authorization'] = preg_replace( '/signature=\"[^\"]+\"/', 'signature="' . $request_parameters['new_signature'] . '"', $headers['Authorization'] ); - } - - if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) { - error_log( sprintf( "SANDBOXING via '%s': '%s'", Constants::get_constant( 'JETPACK__SANDBOX_DOMAIN' ), $original_url ) ); // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_error_log - } - } - } - - /** - * Adds a "Jetpack API Sandboxed" item to the admin bar if the JETPACK__SANDBOX_DOMAIN - * constant is set. - * - * Attached to the `admin_bar_menu` action. - * - * @param \WP_Admin_Bar $wp_admin_bar The WP_Admin_Bar instance. - */ - public function admin_bar_add_sandbox_item( $wp_admin_bar ) { - if ( ! Constants::get_constant( 'JETPACK__SANDBOX_DOMAIN' ) ) { - return; - } - - $node = array( - 'id' => 'jetpack-connection-api-sandbox', - 'title' => 'Jetpack API Sandboxed', - 'meta' => array( - 'title' => 'Sandboxing via ' . Constants::get_constant( 'JETPACK__SANDBOX_DOMAIN' ), - ), - ); - - $wp_admin_bar->add_menu( $node ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php deleted file mode 100644 index b208123f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php +++ /dev/null @@ -1,111 +0,0 @@ -set_agree(); - /** - * Acton fired when the master user has agreed to the terms of service. - * - * @since 1.0.4 - * @since-jetpack 7.9.0 - */ - do_action( 'jetpack_agreed_to_terms_of_service' ); - } - - /** - * Allow the site to reject to the terms of service. - */ - public function reject() { - $this->set_reject(); - /** - * Acton fired when the master user has revoked their agreement to the terms of service. - * - * @since 1.0.4 - * @since-jetpack 7.9.1 - */ - do_action( 'jetpack_reject_terms_of_service' ); - } - - /** - * Returns whether the master user has agreed to the terms of service. - * - * The following conditions have to be met in order to agree to the terms of service. - * 1. The master user has gone though the connect flow. - * 2. The site is not in dev mode. - * 3. The master user of the site is still connected (deprecated @since 1.4.0). - * - * @return bool - */ - public function has_agreed() { - if ( $this->is_offline_mode() ) { - return false; - } - /** - * Before 1.4.0 we used to also check if the master user of the site is connected - * by calling the Connection related `is_active` method. - * As of 1.4.0 we have removed this check in order to resolve the - * circular dependencies it was introducing to composer packages. - * - * @since 1.4.0 - */ - return $this->get_raw_has_agreed(); - } - - /** - * Abstracted for testing purposes. - * Tells us if the site is in dev mode. - * - * @return bool - */ - protected function is_offline_mode() { - return ( new Status() )->is_offline_mode(); - } - - /** - * Gets just the Jetpack Option that contains the terms of service state. - * Abstracted for testing purposes. - * - * @return bool - */ - protected function get_raw_has_agreed() { - return \Jetpack_Options::get_option( self::OPTION_NAME, false ); - } - - /** - * Sets the correct Jetpack Option to mark the that the site has agreed to the terms of service. - * Abstracted for testing purposes. - */ - protected function set_agree() { - \Jetpack_Options::update_option( self::OPTION_NAME, true ); - } - - /** - * Sets the correct Jetpack Option to mark that the site has rejected the terms of service. - * Abstracted for testing purposes. - */ - protected function set_reject() { - \Jetpack_Options::update_option( self::OPTION_NAME, false ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens-locks.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens-locks.php deleted file mode 100644 index e6819a7c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens-locks.php +++ /dev/null @@ -1,76 +0,0 @@ -init_aiowpm(); - - static::$is_initialized = true; - } - - /** - * Set the token lock for AIOWPM plugin export. - * - * @param array $params The filter parameters. - * - * @return array - */ - public function aiowpm_set_lock( $params ) { - ( new Tokens() )->set_lock(); - return $params; - } - - /** - * Remove the token lock for AIOWPM plugin export. - * - * @param array $params The filter parameters. - * - * @return array - */ - public function aiowpm_remove_lock( $params ) { - ( new Tokens() )->remove_lock(); - return $params; - } - - /** - * Initialize the All-in-One-WP-Migration plugin hooks. - * - * @return void - */ - private function init_aiowpm() { - add_filter( 'ai1wm_export', array( $this, 'aiowpm_set_lock' ), 180 ); - add_filter( 'ai1wm_export', array( $this, 'aiowpm_remove_lock' ), 250 ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php deleted file mode 100644 index 1b10356d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php +++ /dev/null @@ -1,687 +0,0 @@ -remove_lock(); - } - - /** - * Perform the API request to validate the blog and user tokens. - * - * @param int|null $user_id ID of the user we need to validate token for. Current user's ID by default. - * - * @return array|false|WP_Error The API response: `array( 'blog_token_is_healthy' => true|false, 'user_token_is_healthy' => true|false )`. - */ - public function validate( $user_id = null ) { - $blog_id = Jetpack_Options::get_option( 'id' ); - if ( ! $blog_id ) { - return new WP_Error( 'site_not_registered', 'Site not registered.' ); - } - $url = sprintf( - '%s/%s/v%s/%s', - Constants::get_constant( 'JETPACK__WPCOM_JSON_API_BASE' ), - 'wpcom', - '2', - 'sites/' . $blog_id . '/jetpack-token-health' - ); - - $user_token = $this->get_access_token( $user_id ? $user_id : get_current_user_id() ); - $blog_token = $this->get_access_token(); - - // Cannot validate non-existent tokens. - if ( false === $user_token || false === $blog_token ) { - return false; - } - - $method = 'POST'; - $body = array( - 'user_token' => $this->get_signed_token( $user_token ), - 'blog_token' => $this->get_signed_token( $blog_token ), - ); - $response = Client::_wp_remote_request( $url, compact( 'body', 'method' ) ); - - if ( is_wp_error( $response ) || ! wp_remote_retrieve_body( $response ) || 200 !== wp_remote_retrieve_response_code( $response ) ) { - return false; - } - - $body = json_decode( wp_remote_retrieve_body( $response ), true ); - - return $body ? $body : false; - } - - /** - * Perform the API request to validate only the blog. - * - * @return bool|WP_Error Boolean with the test result. WP_Error if test cannot be performed. - */ - public function validate_blog_token() { - $blog_id = Jetpack_Options::get_option( 'id' ); - if ( ! $blog_id ) { - return new WP_Error( 'site_not_registered', 'Site not registered.' ); - } - $url = sprintf( - '%s/%s/v%s/%s', - Constants::get_constant( 'JETPACK__WPCOM_JSON_API_BASE' ), - 'wpcom', - '2', - 'sites/' . $blog_id . '/jetpack-token-health/blog' - ); - - $method = 'GET'; - $response = Client::remote_request( compact( 'url', 'method' ) ); - - if ( is_wp_error( $response ) || ! wp_remote_retrieve_body( $response ) || 200 !== wp_remote_retrieve_response_code( $response ) ) { - return false; - } - - $body = json_decode( wp_remote_retrieve_body( $response ), true ); - - return is_array( $body ) && isset( $body['is_healthy'] ) && true === $body['is_healthy']; - } - - /** - * Obtains the auth token. - * - * @param array $data The request data. - * @param string $token_api_url The URL of the Jetpack "token" API. - * @return object|WP_Error Returns the auth token on success. - * Returns a WP_Error on failure. - */ - public function get( $data, $token_api_url ) { - $roles = new Roles(); - $role = $roles->translate_current_user_to_role(); - - if ( ! $role ) { - return new WP_Error( 'role', __( 'An administrator for this blog must set up the Jetpack connection.', 'jetpack-connection' ) ); - } - - $client_secret = $this->get_access_token(); - if ( ! $client_secret ) { - return new WP_Error( 'client_secret', __( 'You need to register your Jetpack before connecting it.', 'jetpack-connection' ) ); - } - - /** - * Filter the URL of the first time the user gets redirected back to your site for connection - * data processing. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param string $redirect_url Defaults to the site admin URL. - */ - $processing_url = apply_filters( 'jetpack_token_processing_url', admin_url( 'admin.php' ) ); - - $redirect = isset( $data['redirect'] ) ? esc_url_raw( (string) $data['redirect'] ) : ''; - - /** - * Filter the URL to redirect the user back to when the authentication process - * is complete. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param string $redirect_url Defaults to the site URL. - */ - $redirect = apply_filters( 'jetpack_token_redirect_url', $redirect ); - - $redirect_uri = ( 'calypso' === $data['auth_type'] ) - ? $data['redirect_uri'] - : add_query_arg( - array( - 'handler' => 'jetpack-connection-webhooks', - 'action' => 'authorize', - '_wpnonce' => wp_create_nonce( "jetpack-authorize_{$role}_{$redirect}" ), - 'redirect' => $redirect ? rawurlencode( $redirect ) : false, - ), - esc_url( $processing_url ) - ); - - /** - * Filters the token request data. - * - * @since 1.7.0 - * @since-jetpack 8.0.0 - * - * @param array $request_data request data. - */ - $body = apply_filters( - 'jetpack_token_request_body', - array( - 'client_id' => Jetpack_Options::get_option( 'id' ), - 'client_secret' => $client_secret->secret, - 'grant_type' => 'authorization_code', - 'code' => $data['code'], - 'redirect_uri' => $redirect_uri, - ) - ); - - $args = array( - 'method' => 'POST', - 'body' => $body, - 'headers' => array( - 'Accept' => 'application/json', - ), - ); - add_filter( 'http_request_timeout', array( $this, 'return_30' ), PHP_INT_MAX - 1 ); - $response = Client::_wp_remote_request( $token_api_url, $args ); - remove_filter( 'http_request_timeout', array( $this, 'return_30' ), PHP_INT_MAX - 1 ); - - if ( is_wp_error( $response ) ) { - return new WP_Error( 'token_http_request_failed', $response->get_error_message() ); - } - - $code = wp_remote_retrieve_response_code( $response ); - $entity = wp_remote_retrieve_body( $response ); - - if ( $entity ) { - $json = json_decode( $entity ); - } else { - $json = false; - } - - if ( 200 !== $code || ! empty( $json->error ) ) { - if ( empty( $json->error ) ) { - return new WP_Error( 'unknown', '', $code ); - } - - /* translators: Error description string. */ - $error_description = isset( $json->error_description ) ? sprintf( __( 'Error Details: %s', 'jetpack-connection' ), (string) $json->error_description ) : ''; - - return new WP_Error( (string) $json->error, $error_description, $code ); - } - - if ( empty( $json->access_token ) || ! is_scalar( $json->access_token ) ) { - return new WP_Error( 'access_token', '', $code ); - } - - if ( empty( $json->token_type ) || 'X_JETPACK' !== strtoupper( $json->token_type ) ) { - return new WP_Error( 'token_type', '', $code ); - } - - if ( empty( $json->scope ) ) { - return new WP_Error( 'scope', 'No Scope', $code ); - } - - // TODO: get rid of the error silencer. - // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged - @list( $role, $hmac ) = explode( ':', $json->scope ); - if ( empty( $role ) || empty( $hmac ) ) { - return new WP_Error( 'scope', 'Malformed Scope', $code ); - } - - if ( $this->sign_role( $role ) !== $json->scope ) { - return new WP_Error( 'scope', 'Invalid Scope', $code ); - } - - $cap = $roles->translate_role_to_cap( $role ); - if ( ! $cap ) { - return new WP_Error( 'scope', 'No Cap', $code ); - } - - if ( ! current_user_can( $cap ) ) { - return new WP_Error( 'scope', 'current_user_cannot', $code ); - } - - return (string) $json->access_token; - } - - /** - * Enters a user token into the user_tokens option - * - * @param int $user_id The user id. - * @param string $token The user token. - * @param bool $is_master_user Whether the user is the master user. - * @return bool - */ - public function update_user_token( $user_id, $token, $is_master_user ) { - // Not designed for concurrent updates. - $user_tokens = $this->get_user_tokens(); - if ( ! is_array( $user_tokens ) ) { - $user_tokens = array(); - } - $user_tokens[ $user_id ] = $token; - if ( $is_master_user ) { - $master_user = $user_id; - $options = compact( 'user_tokens', 'master_user' ); - } else { - $options = compact( 'user_tokens' ); - } - return Jetpack_Options::update_options( $options ); - } - - /** - * Sign a user role with the master access token. - * If not specified, will default to the current user. - * - * @access public - * - * @param string $role User role. - * @param int $user_id ID of the user. - * @return string Signed user role. - */ - public function sign_role( $role, $user_id = null ) { - if ( empty( $user_id ) ) { - $user_id = (int) get_current_user_id(); - } - - if ( ! $user_id ) { - return false; - } - - $token = $this->get_access_token(); - if ( ! $token || is_wp_error( $token ) ) { - return false; - } - - return $role . ':' . hash_hmac( 'md5', "{$role}|{$user_id}", $token->secret ); - } - - /** - * Increases the request timeout value to 30 seconds. - * - * @return int Returns 30. - */ - public function return_30() { - return 30; - } - - /** - * Gets the requested token. - * - * Tokens are one of two types: - * 1. Blog Tokens: These are the "main" tokens. Each site typically has one Blog Token, - * though some sites can have multiple "Special" Blog Tokens (see below). These tokens - * are not associated with a user account. They represent the site's connection with - * the Jetpack servers. - * 2. User Tokens: These are "sub-"tokens. Each connected user account has one User Token. - * - * All tokens look like "{$token_key}.{$private}". $token_key is a public ID for the - * token, and $private is a secret that should never be displayed anywhere or sent - * over the network; it's used only for signing things. - * - * Blog Tokens can be "Normal" or "Special". - * * Normal: The result of a normal connection flow. They look like - * "{$random_string_1}.{$random_string_2}" - * That is, $token_key and $private are both random strings. - * Sites only have one Normal Blog Token. Normal Tokens are found in either - * Jetpack_Options::get_option( 'blog_token' ) (usual) or the JETPACK_BLOG_TOKEN - * constant (rare). - * * Special: A connection token for sites that have gone through an alternative - * connection flow. They look like: - * ";{$special_id}{$special_version};{$wpcom_blog_id};.{$random_string}" - * That is, $private is a random string and $token_key has a special structure with - * lots of semicolons. - * Most sites have zero Special Blog Tokens. Special tokens are only found in the - * JETPACK_BLOG_TOKEN constant. - * - * In particular, note that Normal Blog Tokens never start with ";" and that - * Special Blog Tokens always do. - * - * When searching for a matching Blog Tokens, Blog Tokens are examined in the following - * order: - * 1. Defined Special Blog Tokens (via the JETPACK_BLOG_TOKEN constant) - * 2. Stored Normal Tokens (via Jetpack_Options::get_option( 'blog_token' )) - * 3. Defined Normal Tokens (via the JETPACK_BLOG_TOKEN constant) - * - * @param int|false $user_id false: Return the Blog Token. int: Return that user's User Token. - * @param string|false $token_key If provided, check that the token matches the provided input. - * @param bool|true $suppress_errors If true, return a falsy value when the token isn't found; When false, return a descriptive WP_Error when the token isn't found. - * - * @return object|false|WP_Error - */ - public function get_access_token( $user_id = false, $token_key = false, $suppress_errors = true ) { - if ( $this->is_locked() ) { - $this->delete_all(); - return false; - } - - $possible_special_tokens = array(); - $possible_normal_tokens = array(); - $user_tokens = $this->get_user_tokens(); - - if ( $user_id ) { - if ( ! $user_tokens ) { - return $suppress_errors ? false : new WP_Error( 'no_user_tokens', __( 'No user tokens found', 'jetpack-connection' ) ); - } - if ( true === $user_id ) { // connection owner. - $user_id = Jetpack_Options::get_option( 'master_user' ); - if ( ! $user_id ) { - return $suppress_errors ? false : new WP_Error( 'empty_master_user_option', __( 'No primary user defined', 'jetpack-connection' ) ); - } - } - if ( ! isset( $user_tokens[ $user_id ] ) || ! $user_tokens[ $user_id ] ) { - // translators: %s is the user ID. - return $suppress_errors ? false : new WP_Error( 'no_token_for_user', sprintf( __( 'No token for user %d', 'jetpack-connection' ), $user_id ) ); - } - $user_token_chunks = explode( '.', $user_tokens[ $user_id ] ); - if ( empty( $user_token_chunks[1] ) || empty( $user_token_chunks[2] ) ) { - // translators: %s is the user ID. - return $suppress_errors ? false : new WP_Error( 'token_malformed', sprintf( __( 'Token for user %d is malformed', 'jetpack-connection' ), $user_id ) ); - } - if ( $user_token_chunks[2] !== (string) $user_id ) { - // translators: %1$d is the ID of the requested user. %2$d is the user ID found in the token. - return $suppress_errors ? false : new WP_Error( 'user_id_mismatch', sprintf( __( 'Requesting user_id %1$d does not match token user_id %2$d', 'jetpack-connection' ), $user_id, $user_token_chunks[2] ) ); - } - $possible_normal_tokens[] = "{$user_token_chunks[0]}.{$user_token_chunks[1]}"; - } else { - $stored_blog_token = Jetpack_Options::get_option( 'blog_token' ); - if ( $stored_blog_token ) { - $possible_normal_tokens[] = $stored_blog_token; - } - - $defined_tokens_string = Constants::get_constant( 'JETPACK_BLOG_TOKEN' ); - - if ( $defined_tokens_string ) { - $defined_tokens = explode( ',', $defined_tokens_string ); - foreach ( $defined_tokens as $defined_token ) { - if ( ';' === $defined_token[0] ) { - $possible_special_tokens[] = $defined_token; - } else { - $possible_normal_tokens[] = $defined_token; - } - } - } - } - - if ( self::MAGIC_NORMAL_TOKEN_KEY === $token_key ) { - $possible_tokens = $possible_normal_tokens; - } else { - $possible_tokens = array_merge( $possible_special_tokens, $possible_normal_tokens ); - } - - if ( ! $possible_tokens ) { - // If no user tokens were found, it would have failed earlier, so this is about blog token. - return $suppress_errors ? false : new WP_Error( 'no_possible_tokens', __( 'No blog token found', 'jetpack-connection' ) ); - } - - $valid_token = false; - - if ( false === $token_key ) { - // Use first token. - $valid_token = $possible_tokens[0]; - } elseif ( self::MAGIC_NORMAL_TOKEN_KEY === $token_key ) { - // Use first normal token. - $valid_token = $possible_tokens[0]; // $possible_tokens only contains normal tokens because of earlier check. - } else { - // Use the token matching $token_key or false if none. - // Ensure we check the full key. - $token_check = rtrim( $token_key, '.' ) . '.'; - - foreach ( $possible_tokens as $possible_token ) { - if ( hash_equals( substr( $possible_token, 0, strlen( $token_check ) ), $token_check ) ) { - $valid_token = $possible_token; - break; - } - } - } - - if ( ! $valid_token ) { - if ( $user_id ) { - // translators: %d is the user ID. - return $suppress_errors ? false : new WP_Error( 'no_valid_user_token', sprintf( __( 'Invalid token for user %d', 'jetpack-connection' ), $user_id ) ); - } else { - return $suppress_errors ? false : new WP_Error( 'no_valid_blog_token', __( 'Invalid blog token', 'jetpack-connection' ) ); - } - } - - return (object) array( - 'secret' => $valid_token, - 'external_user_id' => (int) $user_id, - ); - } - - /** - * Updates the blog token to a new value. - * - * @access public - * - * @param string $token the new blog token value. - * @return Boolean Whether updating the blog token was successful. - */ - public function update_blog_token( $token ) { - return Jetpack_Options::update_option( 'blog_token', $token ); - } - - /** - * Unlinks the current user from the linked WordPress.com user. - * - * @access public - * @static - * - * @todo Refactor to properly load the XMLRPC client independently. - * - * @param int $user_id The user identifier. - * - * @return bool Whether the disconnection of the user was successful. - */ - public function disconnect_user( $user_id ) { - $tokens = $this->get_user_tokens(); - if ( ! $tokens ) { - return false; - } - - if ( ! isset( $tokens[ $user_id ] ) ) { - return false; - } - - unset( $tokens[ $user_id ] ); - - $this->update_user_tokens( $tokens ); - - return true; - } - - /** - * Returns an array of user_id's that have user tokens for communicating with wpcom. - * Able to select by specific capability. - * - * @deprecated 1.30.0 - * @see Manager::get_connected_users - * - * @param string $capability The capability of the user. - * @param int|null $limit How many connected users to get before returning. - * @return array Array of WP_User objects if found. - */ - public function get_connected_users( $capability = 'any', $limit = null ) { - _deprecated_function( __METHOD__, '1.30.0' ); - return ( new Manager( 'jetpack' ) )->get_connected_users( $capability, $limit ); - } - - /** - * Fetches a signed token. - * - * @param object $token the token. - * @return WP_Error|string a signed token - */ - public function get_signed_token( $token ) { - if ( ! isset( $token->secret ) || empty( $token->secret ) ) { - return new WP_Error( 'invalid_token' ); - } - - list( $token_key, $token_secret ) = explode( '.', $token->secret ); - - $token_key = sprintf( - '%s:%d:%d', - $token_key, - Constants::get_constant( 'JETPACK__API_VERSION' ), - $token->external_user_id - ); - - $timestamp = time(); - - if ( function_exists( 'wp_generate_password' ) ) { - $nonce = wp_generate_password( 10, false ); - } else { - $nonce = substr( sha1( wp_rand( 0, 1000000 ) ), 0, 10 ); - } - - $normalized_request_string = implode( - "\n", - array( - $token_key, - $timestamp, - $nonce, - ) - ) . "\n"; - - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - $signature = base64_encode( hash_hmac( 'sha1', $normalized_request_string, $token_secret, true ) ); - - $auth = array( - 'token' => $token_key, - 'timestamp' => $timestamp, - 'nonce' => $nonce, - 'signature' => $signature, - ); - - $header_pieces = array(); - foreach ( $auth as $key => $value ) { - $header_pieces[] = sprintf( '%s="%s"', $key, $value ); - } - - return implode( ' ', $header_pieces ); - } - - /** - * Gets the list of user tokens - * - * @since 1.30.0 - * - * @return bool|array An array of user tokens where keys are user IDs and values are the tokens. False if no user token is found. - */ - public function get_user_tokens() { - return Jetpack_Options::get_option( 'user_tokens' ); - } - - /** - * Updates the option that stores the user tokens - * - * @since 1.30.0 - * - * @param array $tokens An array of user tokens where keys are user IDs and values are the tokens. - * @return bool Was the option successfully updated? - * - * @todo add validate the input. - */ - public function update_user_tokens( $tokens ) { - return Jetpack_Options::update_option( 'user_tokens', $tokens ); - } - - /** - * Lock the tokens to the current site URL. - * - * @param int $timespan How long the tokens should be locked, in seconds. - * - * @return bool - */ - public function set_lock( $timespan = HOUR_IN_SECONDS ) { - try { - $expires = ( new DateTime() )->add( DateInterval::createFromDateString( (int) $timespan . ' seconds' ) ); - } catch ( Exception $e ) { - return false; - } - - if ( false === $expires ) { - return false; - } - - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - return Jetpack_Options::update_option( 'token_lock', $expires->format( static::DATE_FORMAT_ATOM ) . '|||' . base64_encode( Urls::site_url() ) ); - } - - /** - * Remove the site lock from tokens. - * - * @return bool - */ - public function remove_lock() { - Jetpack_Options::delete_option( 'token_lock' ); - - return true; - } - - /** - * Check if the domain is locked, remove the lock if needed. - * Possible scenarios: - * - lock expired, site URL matches the lock URL: remove the lock, return false. - * - lock not expired, site URL matches the lock URL: return false. - * - site URL does not match the lock URL (expiration date is ignored): return true, do not remove the lock. - * - * @return bool - */ - public function is_locked() { - $the_lock = Jetpack_Options::get_option( 'token_lock' ); - if ( ! $the_lock ) { - // Not locked. - return false; - } - - $the_lock = explode( '|||', $the_lock, 2 ); - if ( count( $the_lock ) !== 2 ) { - // Something's wrong with the lock. - $this->remove_lock(); - return false; - } - - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - $locked_site_url = base64_decode( $the_lock[1] ); - $expires = $the_lock[0]; - - $expiration_date = DateTime::createFromFormat( static::DATE_FORMAT_ATOM, $expires ); - if ( false === $expiration_date || ! $locked_site_url ) { - // Something's wrong with the lock. - $this->remove_lock(); - return false; - } - - if ( Urls::site_url() === $locked_site_url ) { - if ( new DateTime() > $expiration_date ) { - // Site lock expired. - // Site URL matches, removing the lock. - $this->remove_lock(); - } - - return false; - } - - // Site URL doesn't match. - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php deleted file mode 100644 index 3efc7537..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php +++ /dev/null @@ -1,323 +0,0 @@ -product_name = $product_name; - $this->connection = $connection; - if ( $this->connection === null ) { - // TODO We should always pass a Connection. - $this->connection = new Connection\Manager(); - } - - if ( ! did_action( 'jetpack_set_tracks_ajax_hook' ) ) { - add_action( 'wp_ajax_jetpack_tracks', array( $this, 'ajax_tracks' ) ); - - /** - * Fires when the Tracking::ajax_tracks() callback has been hooked to the - * wp_ajax_jetpack_tracks action. This action is used to ensure that - * the callback is hooked only once. - * - * @since 1.13.11 - */ - do_action( 'jetpack_set_tracks_ajax_hook' ); - } - } - - /** - * Universal method for for all tracking events triggered via the JavaScript client. - * - * @access public - */ - public function ajax_tracks() { - // Check for nonce. - if ( - empty( $_REQUEST['tracksNonce'] ) - || ! wp_verify_nonce( $_REQUEST['tracksNonce'], 'jp-tracks-ajax-nonce' ) // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- WP core doesn't pre-sanitize nonces either. - ) { - wp_send_json_error( - __( 'You aren’t authorized to do that.', 'jetpack-connection' ), - 403 - ); - } - - if ( ! isset( $_REQUEST['tracksEventName'] ) || ! isset( $_REQUEST['tracksEventType'] ) ) { - wp_send_json_error( - __( 'No valid event name or type.', 'jetpack-connection' ), - 403 - ); - } - - $tracks_data = array(); - if ( 'click' === $_REQUEST['tracksEventType'] && isset( $_REQUEST['tracksEventProp'] ) ) { - if ( is_array( $_REQUEST['tracksEventProp'] ) ) { - $tracks_data = array_map( 'filter_var', wp_unslash( $_REQUEST['tracksEventProp'] ) ); - } else { - $tracks_data = array( 'clicked' => filter_var( wp_unslash( $_REQUEST['tracksEventProp'] ) ) ); - } - } - - $this->record_user_event( filter_var( wp_unslash( $_REQUEST['tracksEventName'] ) ), $tracks_data, null, false ); - - wp_send_json_success(); - } - - /** - * Register script necessary for tracking. - * - * @param boolean $enqueue Also enqueue? defaults to false. - */ - public static function register_tracks_functions_scripts( $enqueue = false ) { - - // Register jp-tracks as it is a dependency. - wp_register_script( - 'jp-tracks', - '//stats.wp.com/w.js', - array(), - gmdate( 'YW' ), - true - ); - - Assets::register_script( - 'jp-tracks-functions', - '../dist/tracks-callables.js', - __FILE__, - array( - 'dependencies' => array( 'jp-tracks' ), - 'enqueue' => $enqueue, - 'in_footer' => true, - ) - ); - } - - /** - * Enqueue script necessary for tracking. - */ - public function enqueue_tracks_scripts() { - Assets::register_script( - 'jptracks', - '../dist/tracks-ajax.js', - __FILE__, - array( - 'dependencies' => array( 'jquery' ), - 'enqueue' => true, - 'in_footer' => true, - ) - ); - - wp_localize_script( - 'jptracks', - 'jpTracksAJAX', - array( - 'ajaxurl' => admin_url( 'admin-ajax.php' ), - 'jpTracksAJAX_nonce' => wp_create_nonce( 'jp-tracks-ajax-nonce' ), - ) - ); - } - - /** - * Send an event in Tracks. - * - * @param string $event_type Type of the event. - * @param array $data Data to send with the event. - * @param mixed $user Username, user_id, or WP_User object. - * @param bool $use_product_prefix Whether to use the object's product name as a prefix to the event type. If - * set to false, the prefix will be 'jetpack_'. - */ - public function record_user_event( $event_type, $data = array(), $user = null, $use_product_prefix = true ) { - if ( ! $user ) { - $user = wp_get_current_user(); - } - $site_url = get_option( 'siteurl' ); - - $data['_via_ua'] = isset( $_SERVER['HTTP_USER_AGENT'] ) ? filter_var( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) : ''; - $data['_via_ip'] = isset( $_SERVER['REMOTE_ADDR'] ) ? filter_var( wp_unslash( $_SERVER['REMOTE_ADDR'] ) ) : ''; - $data['_lg'] = isset( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) ? filter_var( wp_unslash( $_SERVER['HTTP_ACCEPT_LANGUAGE'] ) ) : ''; - $data['blog_url'] = $site_url; - $data['blog_id'] = \Jetpack_Options::get_option( 'id' ); - - // Top level events should not be namespaced. - if ( '_aliasUser' !== $event_type ) { - $prefix = $use_product_prefix ? $this->product_name : 'jetpack'; - $event_type = $prefix . '_' . $event_type; - } - - $data['jetpack_version'] = defined( 'JETPACK__VERSION' ) ? JETPACK__VERSION : '0'; - - return $this->tracks_record_event( $user, $event_type, $data ); - } - - /** - * Record an event in Tracks - this is the preferred way to record events from PHP. - * - * @param mixed $user username, user_id, or WP_User object. - * @param string $event_name The name of the event. - * @param array $properties Custom properties to send with the event. - * @param int $event_timestamp_millis The time in millis since 1970-01-01 00:00:00 when the event occurred. - * - * @return bool true for success | \WP_Error if the event pixel could not be fired - */ - public function tracks_record_event( $user, $event_name, $properties = array(), $event_timestamp_millis = false ) { - - // We don't want to track user events during unit tests/CI runs. - if ( $user instanceof \WP_User && 'wptests_capabilities' === $user->cap_key ) { - return false; - } - $terms_of_service = new Terms_Of_Service(); - $status = new Status(); - // Don't track users who have not agreed to our TOS. - if ( ! $this->should_enable_tracking( $terms_of_service, $status ) ) { - return false; - } - - $event_obj = $this->tracks_build_event_obj( $user, $event_name, $properties, $event_timestamp_millis ); - - if ( is_wp_error( $event_obj->error ) ) { - return $event_obj->error; - } - - return $event_obj->record(); - } - - /** - * Determines whether tracking should be enabled. - * - * @param \Automattic\Jetpack\Terms_Of_Service $terms_of_service A Terms_Of_Service object. - * @param \Automattic\Jetpack\Status $status A Status object. - * - * @return boolean True if tracking should be enabled, else false. - */ - public function should_enable_tracking( $terms_of_service, $status ) { - if ( $status->is_offline_mode() ) { - return false; - } - - return $terms_of_service->has_agreed() || $this->connection->is_user_connected(); - } - - /** - * Procedurally build a Tracks Event Object. - * NOTE: Use this only when the simpler Automattic\Jetpack\Tracking->jetpack_tracks_record_event() function won't work for you. - * - * @param \WP_User $user WP_User object. - * @param string $event_name The name of the event. - * @param array $properties Custom properties to send with the event. - * @param int $event_timestamp_millis The time in millis since 1970-01-01 00:00:00 when the event occurred. - * - * @return \Jetpack_Tracks_Event|\WP_Error - */ - private function tracks_build_event_obj( $user, $event_name, $properties = array(), $event_timestamp_millis = false ) { - $identity = $this->tracks_get_identity( $user->ID ); - - $properties['user_lang'] = $user->get( 'WPLANG' ); - - $blog_details = array( - 'blog_lang' => isset( $properties['blog_lang'] ) ? $properties['blog_lang'] : get_bloginfo( 'language' ), - 'blog_id' => \Jetpack_Options::get_option( 'id' ), - ); - - $timestamp = ( false !== $event_timestamp_millis ) ? $event_timestamp_millis : round( microtime( true ) * 1000 ); - $timestamp_string = is_string( $timestamp ) ? $timestamp : number_format( $timestamp, 0, '', '' ); - - return new \Jetpack_Tracks_Event( - array_merge( - $blog_details, - (array) $properties, - $identity, - array( - '_en' => $event_name, - '_ts' => $timestamp_string, - ) - ) - ); - } - - /** - * Get the identity to send to tracks. - * - * @param int $user_id The user id of the local user. - * - * @return array $identity - */ - public function tracks_get_identity( $user_id ) { - - // Meta is set, and user is still connected. Use WPCOM ID. - $wpcom_id = get_user_meta( $user_id, 'jetpack_tracks_wpcom_id', true ); - if ( $wpcom_id && is_string( $wpcom_id ) && $this->connection->is_user_connected( $user_id ) ) { - return array( - '_ut' => 'wpcom:user_id', - '_ui' => $wpcom_id, - ); - } - - // User is connected, but no meta is set yet. Use WPCOM ID and set meta. - if ( $this->connection->is_user_connected( $user_id ) ) { - $wpcom_user_data = $this->connection->get_connected_user_data( $user_id ); - $wpcom_id = $wpcom_user_data['ID'] ?? null; - - if ( is_string( $wpcom_id ) ) { - update_user_meta( $user_id, 'jetpack_tracks_wpcom_id', $wpcom_id ); - - return array( - '_ut' => 'wpcom:user_id', - '_ui' => $wpcom_id, - ); - } - } - - // User isn't linked at all. Fall back to anonymous ID. - $anon_id = get_user_meta( $user_id, 'jetpack_tracks_anon_id', true ); - if ( ! $anon_id ) { - $anon_id = \Jetpack_Tracks_Client::get_anon_id(); - add_user_meta( $user_id, 'jetpack_tracks_anon_id', $anon_id, false ); - } - - if ( ! isset( $_COOKIE['tk_ai'] ) && ! headers_sent() ) { - setcookie( 'tk_ai', $anon_id, 0, COOKIEPATH, COOKIE_DOMAIN, is_ssl(), false ); // phpcs:ignore Jetpack.Functions.SetCookie -- This is a random string and should be fine. - } - - return array( - '_ut' => 'anon', - '_ui' => $anon_id, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php deleted file mode 100644 index f8c22cee..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php +++ /dev/null @@ -1,192 +0,0 @@ -is_wpcom_simple() ) { - return; - } - - add_filter( 'manage_users_columns', array( $this, 'add_connection_column' ) ); - add_filter( 'manage_users_custom_column', array( $this, 'render_connection_column' ), 9, 3 ); // Priority 9 to run before SSO - add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts' ) ); - add_action( 'admin_print_styles-users.php', array( $this, 'add_connection_column_styles' ) ); - } - - /** - * Add the connection column to the users list table. - * - * @param array $columns The current columns. - * @return array Modified columns. - */ - public function add_connection_column( $columns ) { - $columns[ self::COLUMN_ID ] = sprintf( - ' - %1$s - - ', - esc_html__( 'WordPress.com account', 'jetpack-connection' ), - esc_attr__( 'Tooltip', 'jetpack-connection' ) - ); - return $columns; - } - - /** - * Render the connection column content. - * - * @param string $output Custom column output. - * @param string $column_name Column name. - * @param int $user_id ID of the currently-listed user. - * @return string - */ - public function render_connection_column( $output, $column_name, $user_id ) { - if ( self::COLUMN_ID !== $column_name ) { - return $output; - } - - if ( ( new Manager() )->is_user_connected( $user_id ) ) { - return sprintf( - '%2$s', - esc_attr__( 'This user has connected their WordPress.com account.', 'jetpack-connection' ), - esc_html__( 'Connected', 'jetpack-connection' ) - ); - } - - return $output; - } - - /** - * Enqueue scripts and styles. - * - * @param string $hook The current admin page. - */ - public function enqueue_scripts( $hook ) { - if ( 'users.php' !== $hook ) { - return; - } - - Assets::register_script( - 'jetpack-users-connection', - '../dist/jetpack-users-connection.js', - __FILE__, - array( - 'strategy' => 'defer', - 'in_footer' => true, - 'enqueue' => true, - 'version' => Package_Version::PACKAGE_VERSION, - 'deps' => array( 'wp-i18n' ), - - ) - ); - - wp_localize_script( - 'jetpack-users-connection', - 'jetpackConnectionTooltips', - array( - 'columnTooltip' => esc_html__( 'Connecting a WordPress.com account unlocks Jetpack’s full suite of features including secure logins.', 'jetpack-connection' ), - ) - ); - } - - /** - * Add styles for the connection column. - */ - public function add_connection_column_styles() { - ?> - - update_user_token() instead. - * - * @param int $user_id The user id. - * @param string $token The user token. - * @param bool $is_master_user Whether the user is the master user. - * @return bool - */ - public static function update_user_token( $user_id, $token, $is_master_user ) { - _deprecated_function( __METHOD__, '1.24.0', 'Automattic\\Jetpack\\Connection\\Tokens->update_user_token' ); - return ( new Tokens() )->update_user_token( $user_id, $token, $is_master_user ); - } - - /** - * Filters the value of the api constant. - * - * @param String $constant_value The constant value. - * @param String $constant_name The constant name. - * @return mixed | null - */ - public static function jetpack_api_constant_filter( $constant_value, $constant_name ) { - if ( $constant_value !== null ) { - // If the constant value was already set elsewhere, use that value. - return $constant_value; - } - - if ( defined( "self::DEFAULT_$constant_name" ) ) { - return constant( "self::DEFAULT_$constant_name" ); - } - - return null; - } - - /** - * Add a filter to initialize default values of the constants. - */ - public static function init_default_constants() { - add_filter( - 'jetpack_constant_default_value', - array( __CLASS__, 'jetpack_api_constant_filter' ), - 10, - 2 - ); - } - - /** - * Filters the registration request body to include tracking properties. - * - * @param array $properties Already prepared tracking properties. - * @return array amended properties. - */ - public static function filter_register_request_body( $properties ) { - $tracking = new Tracking(); - $tracks_identity = $tracking->tracks_get_identity( get_current_user_id() ); - - return array_merge( - $properties, - array( - '_ui' => $tracks_identity['_ui'], - '_ut' => $tracks_identity['_ut'], - ) - ); - } - - /** - * Generate a new user from a SSO attempt. - * - * @param object $user_data WordPress.com user information. - */ - public static function generate_user( $user_data ) { - $username = $user_data->login; - /** - * Determines how many times the SSO module can attempt to randomly generate a user. - * - * @module sso - * - * @since jetpack-4.3.2 - * - * @param int 5 By default, SSO will attempt to random generate a user up to 5 times. - */ - $num_tries = (int) apply_filters( 'jetpack_sso_allowed_username_generate_retries', 5 ); - - $exists = username_exists( $username ); - $tries = 0; - while ( $exists && $tries++ < $num_tries ) { - $username = $user_data->login . '_' . $user_data->ID . '_' . wp_rand(); - $exists = username_exists( $username ); - } - - if ( $exists ) { - return false; - } - - $user = (object) array(); - $user->user_pass = wp_generate_password( 20 ); - $user->user_login = wp_slash( $username ); - $user->user_email = wp_slash( $user_data->email ); - $user->display_name = $user_data->display_name; - $user->first_name = $user_data->first_name; - $user->last_name = $user_data->last_name; - $user->url = $user_data->url; - $user->description = $user_data->description; - - if ( isset( $user_data->role ) && $user_data->role ) { - $user->role = $user_data->role; - } - - $created_user_id = wp_insert_user( $user ); - - update_user_meta( $created_user_id, 'wpcom_user_id', $user_data->ID ); - return get_userdata( $created_user_id ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php deleted file mode 100644 index 94fd3df6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php +++ /dev/null @@ -1,217 +0,0 @@ -connection = $connection; - } - - /** - * Initialize the webhooks. - * - * @param Manager $connection The Connection Manager object. - */ - public static function init( $connection ) { - $webhooks = new static( $connection ); - - add_action( 'init', array( $webhooks, 'controller' ) ); - add_action( 'load-toplevel_page_jetpack', array( $webhooks, 'fallback_jetpack_controller' ) ); - } - - /** - * Jetpack plugin used to trigger this webhooks in Jetpack::admin_page_load() - * - * The Jetpack toplevel menu is still accessible for stand-alone plugins, and while there's no content for that page, there are still - * actions from Calypso and WPCOM that reach that route regardless of the site having the Jetpack plugin or not. That's why we are still handling it here. - */ - public function fallback_jetpack_controller() { - $this->controller( true ); - } - - /** - * The "controller" decides which handler we need to run. - * - * @param bool $force Do not check if it's a webhook request and just run the controller. - */ - public function controller( $force = false ) { - if ( ! $force ) { - // The nonce is verified in specific handlers. - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( empty( $_GET['handler'] ) || 'jetpack-connection-webhooks' !== $_GET['handler'] ) { - return; - } - } - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( isset( $_GET['connect_url_redirect'] ) ) { - $this->handle_connect_url_redirect(); - } - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( empty( $_GET['action'] ) ) { - return; - } - - // The nonce is verified in specific handlers. - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - switch ( $_GET['action'] ) { - case 'authorize': - $this->handle_authorize(); - $this->do_exit(); - break; // @phan-suppress-current-line PhanPluginUnreachableCode -- Safer to include it even though do_exit never returns. - case 'authorize_redirect': - $this->handle_authorize_redirect(); - $this->do_exit(); - break; // @phan-suppress-current-line PhanPluginUnreachableCode -- Safer to include it even though do_exit never returns. - // Class Jetpack::admin_page_load() still handles other cases. - } - } - - /** - * Perform the authorization action. - */ - public function handle_authorize() { - if ( $this->connection->is_connected() && $this->connection->is_user_connected() ) { - $redirect_url = apply_filters( 'jetpack_client_authorize_already_authorized_url', admin_url() ); - wp_safe_redirect( $redirect_url ); - - return; - } - do_action( 'jetpack_client_authorize_processing' ); - - $data = stripslashes_deep( $_GET ); // We need all request data under the context of an authorization request. - $data['auth_type'] = 'client'; - $roles = new Roles(); - $role = $roles->translate_current_user_to_role(); - $redirect = isset( $data['redirect'] ) ? esc_url_raw( (string) $data['redirect'] ) : ''; - - check_admin_referer( "jetpack-authorize_{$role}_{$redirect}" ); - - $tracking = new Tracking(); - - $result = $this->connection->authorize( $data ); - - if ( is_wp_error( $result ) ) { - do_action( 'jetpack_client_authorize_error', $result ); - - $tracking->record_user_event( - 'jpc_client_authorize_fail', - array( - 'error_code' => $result->get_error_code(), - 'error_message' => $result->get_error_message(), - ) - ); - } else { - /** - * Fires after the Jetpack client is authorized to communicate with WordPress.com. - * - * @param int Jetpack Blog ID. - * - * @since 1.7.0 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_client_authorized', Jetpack_Options::get_option( 'id' ) ); - - $tracking->record_user_event( 'jpc_client_authorize_success' ); - } - - $fallback_redirect = apply_filters( 'jetpack_client_authorize_fallback_url', admin_url() ); - $redirect = wp_validate_redirect( $redirect ) ? $redirect : $fallback_redirect; - - wp_safe_redirect( $redirect ); - } - - /** - * The authorhize_redirect webhook handler - */ - public function handle_authorize_redirect() { - $authorize_redirect_handler = new Webhooks\Authorize_Redirect( $this->connection ); - $authorize_redirect_handler->handle(); - } - - /** - * The `exit` is wrapped into a method so we could mock it. - * - * @return never - */ - protected function do_exit() { - exit( 0 ); - } - - /** - * Handle the `connect_url_redirect` action, - * which is usually called to repeat an attempt for user to authorize the connection. - * - * @return void - */ - public function handle_connect_url_redirect() { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- no site changes. - $from = ! empty( $_GET['from'] ) ? sanitize_text_field( wp_unslash( $_GET['from'] ) ) : 'iframe'; - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- no site changes, sanitization happens in get_authorization_url() - $redirect = ! empty( $_GET['redirect_after_auth'] ) ? wp_unslash( $_GET['redirect_after_auth'] ) : false; - - add_filter( 'allowed_redirect_hosts', array( Host::class, 'allow_wpcom_environments' ) ); - - if ( ! $this->connection->is_user_connected() ) { - if ( ! $this->connection->is_connected() ) { - $this->connection->register(); - } - - $connect_url = add_query_arg( 'from', $from, $this->connection->get_authorization_url( null, $redirect ) ); - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- no site changes. - if ( isset( $_GET['notes_iframe'] ) ) { - $connect_url .= '¬es_iframe'; - } - wp_safe_redirect( $connect_url ); - $this->do_exit(); - } elseif ( ! isset( $_GET['calypso_env'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- no site changes. - ( new CookieState() )->state( 'message', 'already_authorized' ); - wp_safe_redirect( $redirect ); - $this->do_exit(); - } else { - if ( 'connect-after-checkout' === $from && $redirect ) { - wp_safe_redirect( $redirect ); - $this->do_exit(); - } - $connect_url = add_query_arg( - array( - 'from' => $from, - 'already_authorized' => true, - ), - $this->connection->get_authorization_url() - ); - wp_safe_redirect( $connect_url ); - $this->do_exit(); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php deleted file mode 100644 index bc525104..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php +++ /dev/null @@ -1,106 +0,0 @@ - [ - * $user_id => [ - * arrat of Jetpack_IXR_ClientMulticall - * ] - * ] - * ] - * - * @var array - */ - public static $clients = array(); - - /** - * Adds a new XMLRPC call to the queue to be processed on shutdown - * - * @param string $method The XML-RPC method. - * @param integer $user_id The user ID used to make the request (will use this user's token); Use 0 for the blog token. - * @param mixed ...$args This function accepts any number of additional arguments, that will be passed to the call. - * @return void - */ - public static function add_call( $method, $user_id = 0, ...$args ) { - global $blog_id; - - $client_blog_id = is_multisite() ? $blog_id : 0; - - if ( ! isset( self::$clients[ $client_blog_id ] ) ) { - self::$clients[ $client_blog_id ] = array(); - } - - if ( ! isset( self::$clients[ $client_blog_id ][ $user_id ] ) ) { - self::$clients[ $client_blog_id ][ $user_id ] = new Jetpack_IXR_ClientMulticall( array( 'user_id' => $user_id ) ); - } - - // https://plugins.trac.wordpress.org/ticket/2041 - if ( function_exists( 'ignore_user_abort' ) ) { - ignore_user_abort( true ); - } - - array_unshift( $args, $method ); - - call_user_func_array( array( self::$clients[ $client_blog_id ][ $user_id ], 'addCall' ), $args ); - - if ( false === has_action( 'shutdown', array( 'Automattic\Jetpack\Connection\XMLRPC_Async_Call', 'do_calls' ) ) ) { - add_action( 'shutdown', array( 'Automattic\Jetpack\Connection\XMLRPC_Async_Call', 'do_calls' ) ); - } - } - - /** - * Trigger the calls at shutdown - * - * @return void - */ - public static function do_calls() { - foreach ( self::$clients as $client_blog_id => $blog_clients ) { - if ( $client_blog_id > 0 ) { - $switch_success = switch_to_blog( $client_blog_id ); - - if ( ! $switch_success ) { - continue; - } - } - - foreach ( $blog_clients as $client ) { - if ( empty( $client->calls ) ) { - continue; - } - - flush(); - $client->query(); - } - - if ( $client_blog_id > 0 ) { - restore_current_blog(); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php deleted file mode 100644 index a5693cf2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php +++ /dev/null @@ -1,85 +0,0 @@ -connection = $connection; - - // Adding the filter late to avoid being overwritten by Jetpack's XMLRPC server. - add_filter( 'xmlrpc_methods', array( $this, 'xmlrpc_methods' ), 20 ); - } - - /** - * Attached to the `xmlrpc_methods` filter. - * - * @param array $methods The already registered XML-RPC methods. - * @return array - */ - public function xmlrpc_methods( $methods ) { - return array_merge( - $methods, - array( - 'jetpack.verifyRegistration' => array( $this, 'verify_registration' ), - ) - ); - } - - /** - * Handles verification that a site is registered. - * - * @param array $registration_data The data sent by the XML-RPC client: - * [ $secret_1, $user_id ]. - * - * @return string|IXR_Error - */ - public function verify_registration( $registration_data ) { - return $this->output( $this->connection->handle_registration( $registration_data ) ); - } - - /** - * Normalizes output for XML-RPC. - * - * @param mixed $data The data to output. - */ - private function output( $data ) { - if ( is_wp_error( $data ) ) { - $code = $data->get_error_data(); - if ( ! $code ) { - $code = -10520; - } - - if ( ! class_exists( IXR_Error::class ) ) { - require_once ABSPATH . WPINC . '/class-IXR.php'; - } - return new IXR_Error( - $code, - sprintf( 'Jetpack: [%s] %s', $data->get_error_code(), $data->get_error_message() ) - ); - } - - return $data; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/admin-bar.scss b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/admin-bar.scss deleted file mode 100644 index 262b0819..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/admin-bar.scss +++ /dev/null @@ -1,30 +0,0 @@ -#wpadminbar #wp-admin-bar-jetpack-idc { - margin-right: 5px; - - .jp-idc-admin-bar { - border-radius: 2px; - font-weight: 500; - font-size: 14px; - line-height: 20px; - color: #EFEFF0; - padding: 6px 8px; - } - - &.hide { - display: none; - } - - .dashicons { - font-family: 'dashicons'; - margin-top: -6px; - - &:before { - font-size: 18px; - } - } - - .ab-item { - padding: 0; - background: #E68B28; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/admin.jsx b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/admin.jsx deleted file mode 100644 index 8d731738..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/admin.jsx +++ /dev/null @@ -1,62 +0,0 @@ -import { IDCScreen } from '@automattic/jetpack-idc'; -import * as WPElement from '@wordpress/element'; -import React from 'react'; - -import './admin-bar.scss'; -import './style.scss'; - -/** - * The initial renderer function. - */ -function render() { - if ( ! Object.hasOwn( window, 'JP_IDENTITY_CRISIS__INITIAL_STATE' ) ) { - return; - } - - const container = document.getElementById( - window.JP_IDENTITY_CRISIS__INITIAL_STATE.containerID || 'jp-identity-crisis-container' - ); - - if ( null === container ) { - return; - } - - const { - WP_API_root, - WP_API_nonce, - wpcomHomeUrl, - currentUrl, - redirectUri, - tracksUserData, - tracksEventData, - isSafeModeConfirmed, - consumerData, - isAdmin, - possibleDynamicSiteUrlDetected, - isDevelopmentSite, - } = window.JP_IDENTITY_CRISIS__INITIAL_STATE; - - if ( ! isSafeModeConfirmed ) { - const component = ( - - ); - WPElement.createRoot( container ).render( component ); - } -} - -window.addEventListener( 'load', () => render() ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/style.scss b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/style.scss deleted file mode 100644 index 14f09db9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/_inc/style.scss +++ /dev/null @@ -1,9 +0,0 @@ -#jp-identity-crisis-container .jp-idc__idc-screen { - margin-top: 40px; - margin-bottom: 40px; -} - -#jp-identity-crisis-container.notice { - background: none; - border: none; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-exception.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-exception.php deleted file mode 100644 index f6bd4140..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-exception.php +++ /dev/null @@ -1,13 +0,0 @@ -disconnect_site( true ); - } else { - $connection->disconnect_site( false ); - } - - delete_option( static::PERSISTENT_BLOG_ID_OPTION_NAME ); - - // Clear IDC options. - self::clear_all_idc_options(); - } - - /** - * Filter to prevent site from disconnecting from WPCOM if it's in an IDC. - * - * @see jetpack_connection_disconnect_site_wpcom filter. - * - * @return bool False if the site is in IDC, true otherwise. - */ - public static function jetpack_connection_disconnect_site_wpcom_filter() { - return ! self::validate_sync_error_idc_option(); - } - - /** - * This method loops through the array of processed items from sync and checks if one of the items was the - * home_url or site_url callable. If so, then we delete the jetpack_migrate_for_idc option. - * - * @param array $processed_items Array of processed items that were synced to WordPress.com. - */ - public function maybe_clear_migrate_option( $processed_items ) { - foreach ( (array) $processed_items as $item ) { - - // First, is this item a jetpack_sync_callable action? If so, then proceed. - $callable_args = ( is_array( $item ) && isset( $item[0] ) && isset( $item[1] ) && 'jetpack_sync_callable' === $item[0] ) - ? $item[1] - : null; - - // Second, if $callable_args is set, check if the callable was home_url or site_url. If so, - // clear the migrate option. - if ( - isset( $callable_args[0] ) - && ( 'home_url' === $callable_args[0] || 'site_url' === $callable_args[1] ) - ) { - Jetpack_Options::delete_option( 'migrate_for_idc' ); - break; - } - } - } - - /** - * WordPress init. - * - * @return void - */ - public function wordpress_init() { - if ( current_user_can( 'jetpack_disconnect' ) ) { - if ( - isset( $_GET['jetpack_idc_clear_confirmation'] ) && isset( $_GET['_wpnonce'] ) && - wp_verify_nonce( $_GET['_wpnonce'], 'jetpack_idc_clear_confirmation' ) // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- WordPress core doesn't unslash or verify nonces either. - ) { - Jetpack_Options::delete_option( 'safe_mode_confirmed' ); - self::$is_safe_mode_confirmed = false; - } else { - self::$is_safe_mode_confirmed = (bool) Jetpack_Options::get_option( 'safe_mode_confirmed' ); - } - } - - // 121 Priority so that it's the most inner Jetpack item in the admin bar. - add_action( 'admin_bar_menu', array( $this, 'display_admin_bar_button' ), 121 ); - - UI::init(); - } - - /** - * Add the idc query arguments to the url. - * - * @param string $url The remote request url. - */ - public function add_idc_query_args_to_url( $url ) { - $status = new Status(); - if ( ! is_string( $url ) - || $status->is_offline_mode() - || self::validate_sync_error_idc_option() ) { - return $url; - } - $home_url = Urls::home_url(); - $site_url = Urls::site_url(); - $hostname = wp_parse_url( $site_url, PHP_URL_HOST ); - - // If request is from an IP, make sure ip_requester option is set - if ( self::url_is_ip( $hostname ) ) { - self::maybe_update_ip_requester( $hostname ); - } - - $query_args = array( - 'home' => $home_url, - 'siteurl' => $site_url, - ); - - if ( self::should_handle_idc() ) { - $query_args['idc'] = true; - } - - if ( \Jetpack_Options::get_option( 'migrate_for_idc', false ) ) { - $query_args['migrate_for_idc'] = true; - } - - if ( is_multisite() ) { - $query_args['multisite'] = true; - } - - return add_query_arg( $query_args, $url ); - } - - /** - * Renders the admin bar button. - * - * @return void - */ - public function display_admin_bar_button() { - global $wp_admin_bar; - - $href = is_admin() - ? add_query_arg( 'jetpack_idc_clear_confirmation', '1' ) - : add_query_arg( 'jetpack_idc_clear_confirmation', '1', admin_url() ); - - $href = wp_nonce_url( $href, 'jetpack_idc_clear_confirmation' ); - - $consumer_data = UI::get_consumer_data(); - $label = isset( $consumer_data['customContent']['adminBarSafeModeLabel'] ) - ? esc_html( $consumer_data['customContent']['adminBarSafeModeLabel'] ) - : esc_html__( 'Jetpack Safe Mode', 'jetpack-connection' ); - - $title = sprintf( - '', - '', - $label - ); - - $menu = array( - 'id' => 'jetpack-idc', - 'title' => $title, - 'href' => esc_url( $href ), - 'parent' => 'top-secondary', - ); - - if ( ! self::$is_safe_mode_confirmed ) { - $menu['meta'] = array( - 'class' => 'hide', - ); - } - - $wp_admin_bar->add_node( $menu ); - } - - /** - * Checks if the site is currently in an identity crisis. - * - * @return array|bool Array of options that are in a crisis, or false if everything is OK. - */ - public static function check_identity_crisis() { - $connection = new Connection_Manager( 'jetpack' ); - - if ( ! $connection->is_connected() || ( new Status() )->is_offline_mode() || ! self::validate_sync_error_idc_option() ) { - return false; - } - return Jetpack_Options::get_option( 'sync_error_idc' ); - } - - /** - * Checks the HTTP response body for the 'idc_detected' key. If the key exists, - * checks the idc_detected value for a valid idc error. - * - * @param array|WP_Error $http_response The HTTP response. - * - * @return bool Whether the site is in an identity crisis. - */ - public function check_http_response_for_idc_detected( $http_response ) { - if ( ! is_array( $http_response ) ) { - return false; - } - $response_body = json_decode( wp_remote_retrieve_body( $http_response ), true ); - - if ( isset( $response_body['idc_detected'] ) ) { - return $this->check_response_for_idc( $response_body['idc_detected'] ); - } - - if ( isset( $response_body['migrated_for_idc'] ) ) { - Jetpack_Options::delete_option( 'migrate_for_idc' ); - } - - return false; - } - - /** - * Checks the WPCOM response to determine if the site is in an identity crisis. Updates the - * sync_error_idc option if it is. - * - * @param array $response The response data. - * - * @return bool Whether the site is in an identity crisis. - */ - public function check_response_for_idc( $response ) { - if ( is_array( $response ) && isset( $response['error_code'] ) ) { - $error_code = $response['error_code']; - $allowed_idc_error_codes = array( - 'jetpack_url_mismatch', - 'jetpack_home_url_mismatch', - 'jetpack_site_url_mismatch', - ); - - if ( in_array( $error_code, $allowed_idc_error_codes, true ) ) { - Jetpack_Options::update_option( - 'sync_error_idc', - self::get_sync_error_idc_option( $response ) - ); - } - - return true; - } - - return false; - } - - /** - * Clears all IDC specific options. This method is used on disconnect and reconnect. - * - * @return void - */ - public static function clear_all_idc_options() { - // If the site is currently in IDC, let's also clear the VaultPress connection options. - // We have to check if the site is in IDC, otherwise we'd be clearing the VaultPress - // connection any time the Jetpack connection is cycled. - if ( self::validate_sync_error_idc_option() ) { - delete_option( 'vaultpress' ); - delete_option( 'vaultpress_auto_register' ); - } - - Jetpack_Options::delete_option( - array( - 'sync_error_idc', - 'safe_mode_confirmed', - 'migrate_for_idc', - ) - ); - - delete_transient( 'jetpack_idc_possible_dynamic_site_url_detected' ); - } - - /** - * Checks whether the sync_error_idc option is valid or not, and if not, will do cleanup. - * - * @return bool - * @since-jetpack 5.4.0 Do not call get_sync_error_idc_option() unless site is in IDC - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - public static function validate_sync_error_idc_option() { - $is_valid = false; - - // Is the site opted in and does the stored sync_error_idc option match what we now generate? - $sync_error = Jetpack_Options::get_option( 'sync_error_idc' ); - if ( $sync_error && self::should_handle_idc() ) { - $local_options = self::get_sync_error_idc_option(); - - // Ensure all values are set. - if ( isset( $sync_error['home'] ) && isset( $local_options['home'] ) && isset( $sync_error['siteurl'] ) && isset( $local_options['siteurl'] ) ) { - // If the WP.com expected home and siteurl match local home and siteurl it is not valid IDC. - if ( - isset( $sync_error['wpcom_home'] ) && - isset( $sync_error['wpcom_siteurl'] ) && - $sync_error['wpcom_home'] === $local_options['home'] && - $sync_error['wpcom_siteurl'] === $local_options['siteurl'] - ) { - // Enable migrate_for_idc so that sync actions are accepted. - Jetpack_Options::update_option( 'migrate_for_idc', true ); - } elseif ( $sync_error['home'] === $local_options['home'] && $sync_error['siteurl'] === $local_options['siteurl'] ) { - $is_valid = true; - } - } - } - - /** - * Filters whether the sync_error_idc option is valid. - * - * @param bool $is_valid If the sync_error_idc is valid or not. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - $is_valid = (bool) apply_filters( 'jetpack_sync_error_idc_validation', $is_valid ); - - if ( ! $is_valid && $sync_error ) { - // Since the option exists, and did not validate, delete it. - Jetpack_Options::delete_option( 'sync_error_idc' ); - } - - return $is_valid; - } - - /** - * Reverses WP.com URLs stored in sync_error_idc option. - * - * @param array $sync_error error option containing reversed URLs. - * @return array - */ - public static function reverse_wpcom_urls_for_idc( $sync_error ) { - if ( isset( $sync_error['reversed_url'] ) ) { - if ( array_key_exists( 'wpcom_siteurl', $sync_error ) ) { - $sync_error['wpcom_siteurl'] = strrev( $sync_error['wpcom_siteurl'] ); - } - if ( array_key_exists( 'wpcom_home', $sync_error ) ) { - $sync_error['wpcom_home'] = strrev( $sync_error['wpcom_home'] ); - } - } - return $sync_error; - } - - /** - * Normalizes a url by doing three things: - * - Strips protocol - * - Strips www - * - Adds a trailing slash - * - * @param string $url URL to parse. - * - * @return WP_Error|string - * @since 0.2.0 - * @since-jetpack 4.4.0 - */ - public static function normalize_url_protocol_agnostic( $url ) { - $parsed_url = wp_parse_url( trailingslashit( esc_url_raw( $url ) ) ); - if ( ! $parsed_url || empty( $parsed_url['host'] ) || empty( $parsed_url['path'] ) ) { - return new WP_Error( - 'cannot_parse_url', - sprintf( - /* translators: %s: URL to parse. */ - esc_html__( 'Cannot parse URL %s', 'jetpack-connection' ), - $url - ) - ); - } - - // Strip www and protocols. - $url = preg_replace( '/^www\./i', '', $parsed_url['host'] . $parsed_url['path'] ); - - return $url; - } - - /** - * Gets the value that is to be saved in the jetpack_sync_error_idc option. - * - * @param array $response HTTP response. - * - * @return array Array of the local urls, wpcom urls, and error code. - * @since 0.2.0 - * @since-jetpack 4.4.0 - * @since-jetpack 5.4.0 Add transient since home/siteurl retrieved directly from DB. - */ - public static function get_sync_error_idc_option( $response = array() ) { - // Since the local options will hit the database directly, store the values - // in a transient to allow for autoloading and caching on subsequent views. - $local_options = get_transient( 'jetpack_idc_local' ); - if ( false === $local_options ) { - $local_options = array( - 'home' => Urls::home_url(), - 'siteurl' => Urls::site_url(), - ); - set_transient( 'jetpack_idc_local', $local_options, MINUTE_IN_SECONDS ); - } - - $options = array_merge( $local_options, $response ); - - $returned_values = array(); - foreach ( $options as $key => $option ) { - if ( 'error_code' === $key ) { - $returned_values[ $key ] = $option; - continue; - } - - $normalized_url = self::normalize_url_protocol_agnostic( $option ); - if ( is_wp_error( $normalized_url ) ) { - continue; - } - - $returned_values[ $key ] = $normalized_url; - } - // We need to protect WPCOM URLs from search & replace by reversing them. See https://wp.me/pf5801-3R - // Add 'reversed_url' key for backward compatibility - if ( array_key_exists( 'wpcom_home', $returned_values ) && array_key_exists( 'wpcom_siteurl', $returned_values ) ) { - $returned_values['reversed_url'] = true; - $returned_values = self::reverse_wpcom_urls_for_idc( $returned_values ); - } - - return $returned_values; - } - - /** - * Returns the value of the jetpack_should_handle_idc filter or constant. - * If set to true, the site will be put into staging mode. - * - * This method uses both the current jetpack_should_handle_idc filter - * and constant to determine whether an IDC should be handled. - * - * @return bool - * @since 0.2.6 - */ - public static function should_handle_idc() { - if ( Constants::is_defined( 'JETPACK_SHOULD_HANDLE_IDC' ) ) { - $default = Constants::get_constant( 'JETPACK_SHOULD_HANDLE_IDC' ); - } else { - $default = ! Constants::is_defined( 'SUNRISE' ) && ! is_multisite(); - } - - /** - * Allows sites to opt in for IDC mitigation which blocks the site from syncing to WordPress.com when the home - * URL or site URL do not match what WordPress.com expects. The default value is either true, or the value of - * JETPACK_SHOULD_HANDLE_IDC constant if set. - * - * @param bool $default Whether the site is opted in to IDC mitigation. - * - * @since 0.2.6 - */ - return (bool) apply_filters( 'jetpack_should_handle_idc', $default ); - } - - /** - * Whether the site is undergoing identity crisis. - * - * @return bool - */ - public static function has_identity_crisis() { - return false !== static::check_identity_crisis() && ! static::$is_safe_mode_confirmed; - } - - /** - * Whether an admin has confirmed safe mode. - * Unlike `static::$is_safe_mode_confirmed` this function always returns the actual flag value. - * - * @return bool - */ - public static function safe_mode_is_confirmed() { - return Jetpack_Options::get_option( 'safe_mode_confirmed' ); - } - - /** - * Returns the mismatched URLs. - * - * @return array|bool The mismatched urls, or false if the site is not connected, offline, in safe mode, or the IDC error is not valid. - */ - public static function get_mismatched_urls() { - if ( ! static::has_identity_crisis() ) { - return false; - } - - $data = static::check_identity_crisis(); - - if ( ! $data || - ! isset( $data['error_code'] ) || - ! isset( $data['wpcom_home'] ) || - ! isset( $data['home'] ) || - ! isset( $data['wpcom_siteurl'] ) || - ! isset( $data['siteurl'] ) - ) { - // The jetpack_sync_error_idc option is missing a key. - return false; - } - - if ( 'jetpack_site_url_mismatch' === $data['error_code'] ) { - return array( - 'wpcom_url' => $data['wpcom_siteurl'], - 'current_url' => $data['siteurl'], - ); - } - - return array( - 'wpcom_url' => $data['wpcom_home'], - 'current_url' => $data['home'], - ); - } - - /** - * Try to detect $_SERVER['HTTP_HOST'] being used within WP_SITEURL or WP_HOME definitions inside of wp-config. - * - * If `HTTP_HOST` usage is found, it's possbile (though not certain) that site URLs are dynamic. - * - * When a site URL is dynamic, it can lead to a Jetpack IDC. If potentially dynamic usage is detected, - * helpful support info will be shown on the IDC UI about setting a static site/home URL. - * - * @return bool True if potentially dynamic site urls were detected in wp-config, false otherwise. - */ - public static function detect_possible_dynamic_site_url() { - $transient_key = 'jetpack_idc_possible_dynamic_site_url_detected'; - $transient_val = get_transient( $transient_key ); - - if ( false !== $transient_val ) { - return (bool) $transient_val; - } - - $path = self::locate_wp_config(); - $wp_config = $path ? file_get_contents( $path ) : false; // phpcs:ignore WordPress.WP.AlternativeFunctions.file_get_contents_file_get_contents - if ( $wp_config ) { - $matched = preg_match( - '/define ?\( ?[\'"](?:WP_SITEURL|WP_HOME).+(?:HTTP_HOST).+\);/', - $wp_config - ); - - if ( $matched ) { - set_transient( $transient_key, 1, HOUR_IN_SECONDS ); - return true; - } - } - - set_transient( $transient_key, 0, HOUR_IN_SECONDS ); - return false; - } - - /** - * Gets path to WordPress configuration. - * Source: https://github.com/wp-cli/wp-cli/blob/master/php/utils.php - * - * @return string - */ - public static function locate_wp_config() { - static $path; - - if ( null === $path ) { - $path = false; - - if ( getenv( 'WP_CONFIG_PATH' ) && file_exists( getenv( 'WP_CONFIG_PATH' ) ) ) { - $path = getenv( 'WP_CONFIG_PATH' ); - } elseif ( file_exists( ABSPATH . 'wp-config.php' ) ) { - $path = ABSPATH . 'wp-config.php'; - } elseif ( file_exists( dirname( ABSPATH ) . '/wp-config.php' ) && ! file_exists( dirname( ABSPATH ) . '/wp-settings.php' ) ) { - $path = dirname( ABSPATH ) . '/wp-config.php'; - } - - if ( $path ) { - $path = realpath( $path ); - } - } - - return $path; - } - - /** - * Adds `url_secret` to the `jetpack.idcUrlValidation` URL validation endpoint. - * Adds `url_secret_error` in case of an error. - * - * @param array $response The endpoint response that we're modifying. - * - * @return array - * - * phpcs:ignore Squiz.Commenting.FunctionCommentThrowTag -- The exception is being caught, false positive. - */ - public static function add_secret_to_url_validation_response( array $response ) { - try { - $secret = new URL_Secret(); - - $secret->create(); - - if ( $secret->exists() ) { - $response['url_secret'] = $secret->get_secret(); - } - } catch ( Exception $e ) { - $response['url_secret_error'] = new WP_Error( 'unable_to_create_url_secret', $e->getMessage() ); - } - - return $response; - } - - /** - * Check if URL is an IP. - * - * @param string $hostname The hostname to check. - * @return bool - */ - public static function url_is_ip( $hostname = null ) { - - if ( ! $hostname ) { - $hostname = wp_parse_url( Urls::site_url(), PHP_URL_HOST ); - } - - $is_ip = filter_var( $hostname, FILTER_VALIDATE_IP ) !== false ? $hostname : false; - return $is_ip; - } - - /** - * Add IDC-related data to the registration query. - * - * @param array $params The existing query params. - * - * @return array - */ - public static function register_request_body( array $params ) { - $persistent_blog_id = get_option( static::PERSISTENT_BLOG_ID_OPTION_NAME ); - if ( $persistent_blog_id ) { - $params['persistent_blog_id'] = $persistent_blog_id; - $params['url_secret'] = URL_Secret::create_secret( 'registration_request_url_secret_failed' ); - } - - return $params; - } - - /** - * Set the necessary options when site gets registered. - * - * @param int $blog_id The blog ID. - * - * @return void - */ - public static function site_registered( $blog_id ) { - update_option( static::PERSISTENT_BLOG_ID_OPTION_NAME, (int) $blog_id, false ); - } - - /** - * Check if we need to update the ip_requester option. - * - * @param string $hostname The hostname to check. - * - * @return void - */ - public static function maybe_update_ip_requester( $hostname ) { - // Check if transient exists - $transient_key = ip2long( $hostname ); - if ( $transient_key && ! get_transient( 'jetpack_idc_ip_requester_' . $transient_key ) ) { - self::set_ip_requester_for_idc( $hostname, $transient_key ); - } - } - - /** - * If URL is an IP, add the IP value to the ip_requester option with its expiry value. - * - * @param string $hostname The hostname to check. - * @param int $transient_key The transient key. - */ - public static function set_ip_requester_for_idc( $hostname, $transient_key ) { - // Check if option exists - $data = Jetpack_Options::get_option( 'identity_crisis_ip_requester' ); - - $ip_requester = array( - 'ip' => $hostname, - 'expires_at' => time() + 360, - ); - - // If not set, initialize it - if ( empty( $data ) ) { - $data = array( $ip_requester ); - } else { - $updated_data = array(); - $updated_value = false; - - // Remove expired values and update existing IP - foreach ( $data as $item ) { - if ( time() > $item['expires_at'] ) { - continue; // Skip expired IP - } - - if ( $item['ip'] === $hostname ) { - $item['expires_at'] = time() + 360; - $updated_value = true; - } - - $updated_data[] = $item; - } - - if ( ! $updated_value || empty( $updated_data ) ) { - $updated_data[] = $ip_requester; - } - - $data = $updated_data; - } - - self::update_ip_requester( $data, $transient_key ); - } - - /** - * Update the ip_requester option and set a transient to expire in 5 minutes. - * - * @param array $data The data to be updated. - * @param int $transient_key The transient key. - * - * @return void - */ - public static function update_ip_requester( $data, $transient_key ) { - // Update the option - $updated = Jetpack_Options::update_option( 'identity_crisis_ip_requester', $data ); - // Set a transient to expire in 5 minutes - if ( $updated ) { - $transient_name = 'jetpack_idc_ip_requester_' . $transient_key; - set_transient( $transient_name, $data, 300 ); - } - } - - /** - * Adds `ip_requester` to the `jetpack.idcUrlValidation` URL validation endpoint. - * - * @param array $response The enpoint response that we're modifying. - * - * @return array - */ - public static function add_ip_requester_to_url_validation_response( array $response ) { - $requesters = Jetpack_Options::get_option( 'identity_crisis_ip_requester' ); - if ( $requesters ) { - // Loop through the requesters and add the IP to the response if it's not expired - $i = 0; - foreach ( $requesters as $ip ) { - if ( $ip['expires_at'] > time() ) { - $response['ip_requester'][] = $ip['ip']; - } - // Limit the response to five IPs - $i = ++$i; - if ( $i === 5 ) { - break; - } - } - } - return $response; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-rest-endpoints.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-rest-endpoints.php deleted file mode 100644 index b3547811..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-rest-endpoints.php +++ /dev/null @@ -1,322 +0,0 @@ - WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::confirm_safe_mode', - 'permission_callback' => __CLASS__ . '::identity_crisis_mitigation_permission_check', - ) - ); - - // Handles the request to migrate stats and subscribers during an identity crisis. - register_rest_route( - 'jetpack/v4', - 'identity-crisis/migrate', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::migrate_stats_and_subscribers', - 'permission_callback' => __CLASS__ . '::identity_crisis_mitigation_permission_check', - ) - ); - - // IDC resolve: create an entirely new shadow site for this URL. - register_rest_route( - 'jetpack/v4', - '/identity-crisis/start-fresh', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::start_fresh_connection', - 'permission_callback' => __CLASS__ . '::identity_crisis_mitigation_permission_check', - 'args' => array( - 'redirect_uri' => array( - 'description' => __( 'URI of the admin page where the user should be redirected after connection flow', 'jetpack-connection' ), - 'type' => 'string', - ), - ), - ) - ); - - // Fetch URL and secret for IDC check. - register_rest_route( - 'jetpack/v4', - '/identity-crisis/idc-url-validation', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( static::class, 'validate_urls_and_set_secret' ), - 'permission_callback' => array( static::class, 'url_secret_permission_check' ), - ) - ); - - // Fetch URL verification secret. - register_rest_route( - 'jetpack/v4', - '/identity-crisis/url-secret', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => array( static::class, 'fetch_url_secret' ), - 'permission_callback' => array( static::class, 'url_secret_permission_check' ), - ) - ); - - // Fetch URL verification secret. - register_rest_route( - 'jetpack/v4', - '/identity-crisis/compare-url-secret', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => array( static::class, 'compare_url_secret' ), - 'permission_callback' => array( static::class, 'compare_url_secret_permission_check' ), - 'args' => array( - 'secret' => array( - 'description' => __( 'URL secret to compare to the ones stored in the database.', 'jetpack-connection' ), - 'type' => 'string', - 'required' => true, - ), - ), - ) - ); - } - - /** - * Handles identity crisis mitigation, confirming safe mode for this site. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - * - * @return bool | WP_Error True if option is properly set. - */ - public static function confirm_safe_mode() { - $updated = Jetpack_Options::update_option( 'safe_mode_confirmed', true ); - if ( $updated ) { - return rest_ensure_response( - array( - 'code' => 'success', - ) - ); - } - - return new WP_Error( - 'error_setting_jetpack_safe_mode', - esc_html__( 'Could not confirm safe mode.', 'jetpack-connection' ), - array( 'status' => 500 ) - ); - } - - /** - * Handles identity crisis mitigation, migrating stats and subscribers from old url to this, new url. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - * - * @return bool | WP_Error True if option is properly set. - */ - public static function migrate_stats_and_subscribers() { - if ( Jetpack_Options::get_option( 'sync_error_idc' ) && ! Jetpack_Options::delete_option( 'sync_error_idc' ) ) { - return new WP_Error( - 'error_deleting_sync_error_idc', - esc_html__( 'Could not delete sync error option.', 'jetpack-connection' ), - array( 'status' => 500 ) - ); - } - - if ( Jetpack_Options::get_option( 'migrate_for_idc' ) || Jetpack_Options::update_option( 'migrate_for_idc', true ) ) { - return rest_ensure_response( - array( - 'code' => 'success', - ) - ); - } - return new WP_Error( - 'error_setting_jetpack_migrate', - esc_html__( 'Could not confirm migration.', 'jetpack-connection' ), - array( 'status' => 500 ) - ); - } - - /** - * This IDC resolution will disconnect the site and re-connect to a completely new - * and separate shadow site than the original. - * - * It will first will disconnect the site without phoning home as to not disturb the production site. - * It then builds a fresh connection URL and sends it back along with the response. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public static function start_fresh_connection( $request ) { - /** - * Fires when Users have requested through Identity Crisis for the connection to be reset. - * Should be used to disconnect any connections and reset options. - * - * @since 0.2.0 - */ - do_action( 'jetpack_idc_disconnect' ); - - $connection = new Connection_Manager(); - $result = $connection->try_registration( true ); - - // early return if site registration fails. - if ( ! $result || is_wp_error( $result ) ) { - return rest_ensure_response( $result ); - } - - $redirect_uri = $request->get_param( 'redirect_uri' ) ? admin_url( $request->get_param( 'redirect_uri' ) ) : null; - - /** - * Filters the connection url that users should be redirected to for re-establishing their connection. - * - * @since 0.2.0 - * - * @param \WP_REST_Response|WP_Error $connection_url Connection URL user should be redirected to. - */ - return apply_filters( 'jetpack_idc_authorization_url', rest_ensure_response( $connection->get_authorization_url( null, $redirect_uri ) ) ); - } - - /** - * Verify that user can mitigate an identity crisis. - * - * @since 0.2.0 - * @since-jetpack 4.4.0 - * - * @return true|WP_Error True if the user has capability 'jetpack_disconnect', an error object otherwise. - */ - public static function identity_crisis_mitigation_permission_check() { - if ( current_user_can( 'jetpack_disconnect' ) ) { - return true; - } - $error_msg = esc_html__( - 'You do not have the correct user permissions to perform this action. - Please contact your site admin if you think this is a mistake.', - 'jetpack-connection' - ); - - return new WP_Error( 'invalid_user_permission_identity_crisis', $error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Endpoint for URL validation and creating a secret. - * - * @since 0.18.0 - * - * @return array - */ - public static function validate_urls_and_set_secret() { - $xmlrpc_server = new Jetpack_XMLRPC_Server(); - $result = $xmlrpc_server->validate_urls_for_idc_mitigation(); - - return $result; - } - - /** - * Endpoint for fetching the existing secret. - * - * @return WP_Error|\WP_REST_Response - */ - public static function fetch_url_secret() { - $secret = new URL_Secret(); - - if ( ! $secret->exists() ) { - return new WP_Error( 'missing_url_secret', esc_html__( 'URL secret does not exist.', 'jetpack-connection' ) ); - } - - return rest_ensure_response( - array( - 'code' => 'success', - 'data' => array( - 'secret' => $secret->get_secret(), - 'expires_at' => $secret->get_expires_at(), - ), - ) - ); - } - - /** - * Endpoint for comparing the existing secret. - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return WP_Error|\WP_REST_Response - */ - public static function compare_url_secret( $request ) { - $match = false; - - $storage = new URL_Secret(); - - if ( $storage->exists() ) { - $remote_secret = $request->get_param( 'secret' ); - $match = $remote_secret && hash_equals( $storage->get_secret(), $remote_secret ); - } - - return rest_ensure_response( - array( - 'code' => 'success', - 'match' => $match, - ) - ); - } - - /** - * Verify url_secret create/fetch permissions (valid blog token authentication). - * - * @return true|WP_Error - */ - public static function url_secret_permission_check() { - return Rest_Authentication::is_signed_with_blog_token() - ? true - : new WP_Error( - 'invalid_user_permission_identity_crisis', - esc_html__( 'You do not have the correct user permissions to perform this action.', 'jetpack-connection' ), - array( 'status' => rest_authorization_required_code() ) - ); - } - - /** - * The endpoint is only available on non-connected sites. - * use `/identity-crisis/url-secret` for connected sites. - * - * @return true|WP_Error - */ - public static function compare_url_secret_permission_check() { - return ( new Connection_Manager() )->is_connected() - ? new WP_Error( - 'invalid_connection_status', - esc_html__( 'The endpoint is not available on connected sites.', 'jetpack-connection' ), - array( 'status' => 403 ) - ) - : true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-ui.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-ui.php deleted file mode 100644 index da8e908d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-ui.php +++ /dev/null @@ -1,208 +0,0 @@ - true, - 'textdomain' => 'jetpack-connection', - ) - ); - Assets::enqueue_script( 'jp_identity_crisis_banner' ); - wp_add_inline_script( 'jp_identity_crisis_banner', static::get_initial_state(), 'before' ); - - add_action( 'admin_notices', array( static::class, 'render_container' ) ); - } - } - - /** - * Create the container element for the IDC banner. - */ - public static function render_container() { - ?> -
            - esc_url_raw( rest_url() ), - 'WP_API_nonce' => wp_create_nonce( 'wp_rest' ), - 'wpcomHomeUrl' => ( is_array( $idc_urls ) && array_key_exists( 'wpcom_url', $idc_urls ) ) ? $idc_urls['wpcom_url'] : null, - 'currentUrl' => ( is_array( $idc_urls ) && array_key_exists( 'current_url', $idc_urls ) ) ? $idc_urls['current_url'] : null, - 'redirectUri' => isset( $_SERVER['REQUEST_URI'] ) ? str_replace( '/wp-admin/', '/', filter_var( wp_unslash( $_SERVER['REQUEST_URI'] ) ) ) : '', - 'tracksUserData' => Jetpack_Tracks_Client::get_connected_user_tracks_identity(), - 'tracksEventData' => array( - 'isAdmin' => $is_admin, - 'currentScreen' => $current_screen ? $current_screen->id : false, - 'blogID' => Jetpack_Options::get_option( 'id' ), - 'platform' => static::get_platform(), - ), - 'isSafeModeConfirmed' => Identity_Crisis::$is_safe_mode_confirmed, - 'consumerData' => static::get_consumer_data(), - 'isAdmin' => $is_admin, - 'possibleDynamicSiteUrlDetected' => $possible_dynamic_site_url_detected, - 'isDevelopmentSite' => $is_development_site, - - /** - * Use the filter to provide custom HTML elecontainer ID. - * - * @since 0.10.0 - * - * @param string|null $containerID The container ID. - */ - 'containerID' => apply_filters( 'identity_crisis_container_id', null ), - ); - } - - /** - * Get the package consumer data. - * - * @return array - */ - public static function get_consumer_data() { - if ( null !== static::$consumers ) { - return static::$consumers; - } - - $consumers = apply_filters( 'jetpack_idc_consumers', array() ); - - if ( ! $consumers ) { - return array(); - } - - usort( - $consumers, - function ( $c1, $c2 ) { - $priority1 = ( array_key_exists( 'priority', $c1 ) && (int) $c1['priority'] ) ? (int) $c1['priority'] : 10; - $priority2 = ( array_key_exists( 'priority', $c2 ) && (int) $c2['priority'] ) ? (int) $c2['priority'] : 10; - - return $priority1 <=> $priority2; - } - ); - - $consumer_chosen = null; - $consumer_url_length = 0; - foreach ( $consumers as &$consumer ) { - if ( empty( $consumer['admin_page'] ) || ! is_string( $consumer['admin_page'] ) ) { - continue; - } - - if ( isset( $consumer['customContent'] ) && is_callable( $consumer['customContent'] ) ) { - $consumer['customContent'] = call_user_func( $consumer['customContent'] ); - } - - if ( isset( $_SERVER['REQUEST_URI'] ) && str_starts_with( filter_var( wp_unslash( $_SERVER['REQUEST_URI'] ) ), $consumer['admin_page'] ) && strlen( $consumer['admin_page'] ) > $consumer_url_length ) { - $consumer_chosen = $consumer; - $consumer_url_length = strlen( $consumer['admin_page'] ); - } - } - unset( $consumer ); - - static::$consumers = $consumer_chosen ? $consumer_chosen : array_shift( $consumers ); - - return static::$consumers; - } - - /** - * Get the site platform. - * - * @return string - */ - private static function get_platform() { - $host = new Host(); - - if ( $host->is_woa_site() ) { - return 'woa'; - } - - if ( $host->is_vip_site() ) { - return 'vip'; - } - - if ( $host->is_newspack_site() ) { - return 'newspack'; - } - - return 'self-hosted'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-url-secret.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-url-secret.php deleted file mode 100644 index e2ff3f8b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-url-secret.php +++ /dev/null @@ -1,159 +0,0 @@ -fetch(); - - if ( $secret_data !== null ) { - $this->secret = $secret_data['secret']; - $this->expires_at = $secret_data['expires_at']; - } - } - - /** - * Fetch the URL secret from the database. - * - * @return array|null - */ - private function fetch() { - $data = Jetpack_Options::get_option( static::OPTION_KEY ); - - if ( $data === false || empty( $data['secret'] ) || empty( $data['expires_at'] ) ) { - return null; - } - - if ( time() > $data['expires_at'] ) { - Jetpack_Options::delete_option( static::OPTION_KEY ); - return null; - } - - return $data; - } - - /** - * Create new secret and save it in the options. - * - * @throws Exception Thrown if unable to save the new secret. - * - * @return bool - */ - public function create() { - $secret_data = array( - 'secret' => $this->generate_secret(), - 'expires_at' => strval( time() + static::LIFESPAN ), - ); - - $result = Jetpack_Options::update_option( static::OPTION_KEY, $secret_data ); - - if ( ! $result ) { - throw new Exception( esc_html__( 'Unable to save new URL secret', 'jetpack-connection' ) ); - } - - $this->secret = $secret_data['secret']; - $this->expires_at = $secret_data['expires_at']; - - return true; - } - - /** - * Get the URL secret. - * - * @return string|null - */ - public function get_secret() { - return $this->secret; - } - - /** - * Get the URL secret expiration date. - * - * @return string|null - */ - public function get_expires_at() { - return $this->expires_at; - } - - /** - * Check if the secret exists. - * - * @return bool - */ - public function exists() { - return $this->secret && $this->expires_at; - } - - /** - * Generate the secret string. - * - * @return string - */ - private function generate_secret() { - return wp_generate_password( 12, false ); - } - - /** - * Generate secret for response. - * - * @param string $flow used to tell which flow generated the exception. - * @return string|null - */ - public static function create_secret( $flow = 'generating_secret_failed' ) { - $secret_value = null; - try { - - $secret = new self(); - $secret->create(); - - if ( $secret->exists() ) { - $secret_value = $secret->get_secret(); - } - } catch ( Exception $e ) { - // Track the error and proceed. - ( new Tracking() )->record_user_event( $flow, array( 'current_url' => Urls::site_url() ) ); - } - return $secret_value; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php deleted file mode 100644 index 804f3848..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php +++ /dev/null @@ -1,17 +0,0 @@ -role = apply_filters( 'jetpack_force_2fa_cap', 'manage_options' ); - - // Bail if Jetpack SSO is not active - if ( ! ( new Modules() )->is_active( 'sso' ) ) { - add_action( 'admin_notices', array( $this, 'admin_notice' ) ); - return; - } - - $this->force_2fa(); - } - - /** - * Display an admin notice if Jetpack SSO is not active. - */ - public function admin_notice() { - /** - * Filter if an admin notice is deplayed when Force 2FA is required, but SSO is not enabled. - * Defaults to true. - * - * @param bool $display_notice Whether to display the notice. - * @return bool - * @since jetpack-12.7 - * @module SSO - */ - if ( apply_filters( 'jetpack_force_2fa_dependency_notice', true ) && current_user_can( $this->role ) ) { - wp_admin_notice( - esc_html__( 'Jetpack Force 2FA requires Jetpack’s SSO feature.', 'jetpack-connection' ), - array( - 'type' => 'warning', - ) - ); - } - } - - /** - * Force 2FA when using Jetpack SSO and force Jetpack SSO. - * - * @return void - */ - private function force_2fa() { - // Allows WP.com login to a local account if it matches the local account. - add_filter( 'jetpack_sso_match_by_email', '__return_true', 9999 ); - - // multisite - if ( is_multisite() ) { - - // Hide the login form - add_filter( 'jetpack_remove_login_form', '__return_true', 9999 ); - add_filter( 'jetpack_sso_bypass_login_forward_wpcom', '__return_true', 9999 ); - add_filter( 'jetpack_sso_display_disclaimer', '__return_false', 9999 ); - - add_filter( - 'wp_authenticate_user', - function () { - return new WP_Error( 'wpcom-required', $this->get_login_error_message() ); }, - 9999 - ); - - add_filter( 'jetpack_sso_require_two_step', '__return_true' ); - - add_filter( 'allow_password_reset', '__return_false' ); - } else { - // Not multisite. - - // Completely disable the standard login form for admins. - add_filter( - 'wp_authenticate_user', - function ( $user ) { - if ( is_wp_error( $user ) ) { - return $user; - } - if ( $user->has_cap( $this->role ) ) { - return new WP_Error( 'wpcom-required', $this->get_login_error_message(), $user->user_login ); - } - return $user; - }, - 9999 - ); - - add_filter( - 'allow_password_reset', - function ( $allow, $user_id ) { - if ( user_can( $user_id, $this->role ) ) { - return false; - } - return $allow; }, - 9999, - 2 - ); - - add_action( 'jetpack_sso_pre_handle_login', array( $this, 'jetpack_set_two_step' ) ); - } - } - - /** - * Specifically set the two step filter for Jetpack SSO. - * - * @param Object $user_data The user data from WordPress.com. - * - * @return void - */ - public function jetpack_set_two_step( $user_data ) { - $user = SSO::get_user_by_wpcom_id( $user_data->ID ); - - // Borrowed from Jetpack. Ignores the match_by_email setting. - if ( empty( $user ) ) { - $user = get_user_by( 'email', $user_data->email ); - } - - if ( $user && $user->has_cap( $this->role ) ) { - add_filter( 'jetpack_sso_require_two_step', '__return_true' ); - } - } - - /** - * Get the login error message. - * - * @return string - */ - private function get_login_error_message() { - /** - * Filter the login error message. - * Defaults to a message that explains the user must use a WordPress.com account with 2FA enabled. - * - * @param string $message The login error message. - * @return string - * @since jetpack-12.7 - * @module SSO - */ - return apply_filters( - 'jetpack_force_2fa_login_error_message', - sprintf( 'For added security, please log in using your WordPress.com account.

            Note: Your account must have Two Step Authentication enabled, which can be configured from Security Settings.', 'https://support.wordpress.com/security/two-step-authentication/', 'https://wordpress.com/me/security/two-step' ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-helpers.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-helpers.php deleted file mode 100644 index 2fdf7369..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-helpers.php +++ /dev/null @@ -1,387 +0,0 @@ - $original_request ) - ); - } - - /** - * Check if the site has a custom login page URL, and return it. - * If default login page URL is used (`wp-login.php`), `null` will be returned. - * - * @return string|null - */ - public static function get_custom_login_url() { - $login_url = wp_login_url(); - - if ( str_ends_with( $login_url, 'wp-login.php' ) ) { - // No custom URL found. - return null; - } - - $site_url = trailingslashit( site_url() ); - - if ( ! str_starts_with( $login_url, $site_url ) ) { - // Something went wrong, we can't properly extract the custom URL. - return null; - } - - // Extracting the "path" part of the URL, because we don't need the `site_url` part. - return str_ireplace( $site_url, '', $login_url ); - } - - /** - * Clear the cookies that store the profile information for the last - * WPCOM user to connect. - */ - public static function clear_wpcom_profile_cookies() { - if ( isset( $_COOKIE[ 'jetpack_sso_wpcom_name_' . COOKIEHASH ] ) ) { - setcookie( - 'jetpack_sso_wpcom_name_' . COOKIEHASH, - ' ', - time() - YEAR_IN_SECONDS, - COOKIEPATH, - COOKIE_DOMAIN, - is_ssl(), - true - ); - } - - if ( isset( $_COOKIE[ 'jetpack_sso_wpcom_gravatar_' . COOKIEHASH ] ) ) { - setcookie( - 'jetpack_sso_wpcom_gravatar_' . COOKIEHASH, - ' ', - time() - YEAR_IN_SECONDS, - COOKIEPATH, - COOKIE_DOMAIN, - is_ssl(), - true - ); - } - } - - /** - * Remove an SSO connection for a user. - * - * @param int $user_id The local user id. - */ - public static function delete_connection_for_user( $user_id ) { - $wpcom_user_id = get_user_meta( $user_id, 'wpcom_user_id', true ); - if ( ! $wpcom_user_id ) { - return; - } - - $xml = new Jetpack_IXR_Client( - array( - 'wpcom_user_id' => $user_id, - ) - ); - $xml->query( 'jetpack.sso.removeUser', $wpcom_user_id ); - - if ( $xml->isError() ) { - return false; - } - - // Clean up local data stored for SSO. - delete_user_meta( $user_id, 'wpcom_user_id' ); - delete_user_meta( $user_id, 'wpcom_user_data' ); - self::clear_wpcom_profile_cookies(); - - return $xml->getResponse(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-notices.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-notices.php deleted file mode 100644 index 289ba6c7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-notices.php +++ /dev/null @@ -1,272 +0,0 @@ -Security Settings to configure Two-step Authentication for your account.', - 'jetpack-connection' - ), - array( 'a' => array( 'href' => array() ) ) - ), - Redirect::get_url( 'calypso-me-security-two-step' ), - Redirect::get_url( 'wpcom-support-security-two-step-authentication' ) - ); - - $message .= sprintf( '

            %s

            ', $error ); - - return $message; - } - - /** - * Error message displayed when the user tries to SSO, but match by email - * is off and they already have an account with their email address on - * this site. - * - * @param string $message Error message. - * @return string - */ - public static function error_msg_email_already_exists( $message ) { - $error = sprintf( - wp_kses( - /* translators: login URL */ - __( - 'You already have an account on this site. Please sign in with your username and password and then connect to WordPress.com.', - 'jetpack-connection' - ), - array( 'a' => array( 'href' => array() ) ) - ), - esc_url_raw( add_query_arg( 'jetpack-sso-show-default-form', '1', wp_login_url() ) ) - ); - - $message .= sprintf( '

            %s

            ', $error ); - - return $message; - } - - /** - * Error message that is displayed when the current site is in an identity crisis and SSO can not be used. - * - * @since jetpack-4.3.2 - * - * @param string $message Error Message. - * - * @return string - */ - public static function error_msg_identity_crisis( $message ) { - $error = esc_html__( 'Logging in with WordPress.com is not currently available because this site is experiencing connection problems.', 'jetpack-connection' ); - $message .= sprintf( '

            %s

            ', $error ); - return $message; - } - - /** - * Error message that is displayed when we are not able to verify the SSO nonce due to an XML error or - * failed validation. In either case, we prompt the user to try again or log in with username and password. - * - * @since jetpack-4.3.2 - * - * @param string $message Error message. - * - * @return string - */ - public static function error_invalid_response_data( $message ) { - $error = esc_html__( - 'There was an error logging you in via WordPress.com, please try again or try logging in with your username and password.', - 'jetpack-connection' - ); - $message .= sprintf( '

            %s

            ', $error ); - return $message; - } - - /** - * Error message that is displayed when we were not able to automatically create an account for a user - * after a user has logged in via SSO. By default, this message is triggered after trying to create an account 5 times. - * - * @since jetpack-4.3.2 - * - * @param string $message Error message. - * - * @return string - */ - public static function error_unable_to_create_user( $message ) { - $error = esc_html__( - 'There was an error creating a user for you. Please contact the administrator of your site.', - 'jetpack-connection' - ); - $message .= sprintf( '

            %s

            ', $error ); - return $message; - } - - /** - * When the default login form is hidden, this method is called on the 'authenticate' filter with a priority of 30. - * This method disables the ability to submit the default login form. - * - * @param WP_User|WP_Error $user Either the user attempting to login or an existing authentication failure. - * - * @return WP_Error - */ - public static function disable_default_login_form( $user ) { - if ( is_wp_error( $user ) ) { - return $user; - } - - /** - * Since we're returning an error that will be shown as a red notice, let's remove the - * informational "blue" notice. - */ - remove_filter( 'login_message', array( static::class, 'msg_login_by_jetpack' ) ); - return new WP_Error( 'jetpack_sso_required', self::get_sso_required_message() ); - } - - /** - * Message displayed when the site admin has disabled the default WordPress - * login form in Settings > General > Secure Sign On - * - * @since jetpack-2.7 - * @param string $message Error message. - * - * @return string - **/ - public static function msg_login_by_jetpack( $message ) { - $message .= sprintf( '

            %s

            ', self::get_sso_required_message() ); - return $message; - } - - /** - * Get the message for SSO required. - * - * @return string - */ - public static function get_sso_required_message() { - $msg = esc_html__( - 'A WordPress.com account is required to access this site. Click the button below to sign in or create a free WordPress.com account.', - 'jetpack-connection' - ); - - /** - * Filter the message displayed when the default WordPress login form is disabled. - * - * @module sso - * - * @since jetpack-2.8.0 - * - * @param string $msg Disclaimer when default WordPress login form is disabled. - */ - return apply_filters( 'jetpack_sso_disclaimer_message', $msg ); - } - - /** - * Message displayed when the user can not be found after approving the SSO process on WordPress.com - * - * @param string $message Error message. - * - * @return string - */ - public static function cant_find_user( $message ) { - $error = __( - "We couldn't find your account. If you already have an account, make sure you have connected to WordPress.com.", - 'jetpack-connection' - ); - - /** - * Filters the "couldn't find your account" notice after an attempted SSO. - * - * @module sso - * - * @since jetpack-10.5.0 - * - * @param string $error Error text. - */ - $error = apply_filters( 'jetpack_sso_unknown_user_notice', $error ); - - $message .= sprintf( '

            %s

            ', esc_html( $error ) ); - - return $message; - } - - /** - * Error message that is displayed when the current site is in an identity crisis and SSO can not be used. - * - * @since jetpack-4.4.0 - * @deprecated since 2.10.0 - * - * @param string $message Error message. - * - * @return string - */ - public static function sso_not_allowed_in_staging( $message ) { - _deprecated_function( __FUNCTION__, '2.10.0', 'sso_not_allowed_in_safe_mode' ); - $error = __( - 'Logging in with WordPress.com is disabled for sites that are in staging mode.', - 'jetpack-connection' - ); - - /** - * Filters the disallowed notice for staging sites attempting SSO. - * - * @module sso - * - * @since jetpack-10.5.0 - * - * @param string $error Error text. - */ - $error = apply_filters_deprecated( 'jetpack_sso_disallowed_staging_notice', array( $error ), '2.9.1', 'jetpack_sso_disallowed_safe_mode_notice' ); - $message .= sprintf( '

            %s

            ', esc_html( $error ) ); - return $message; - } - - /** - * Error message that is displayed when the current site is in an identity crisis and SSO can not be used. - * - * @since 2.10.0 - * - * @param string $message Error message. - * - * @return string - */ - public static function sso_not_allowed_in_safe_mode( $message ) { - $error = __( - 'Logging in with WordPress.com is disabled for sites that are in safe mode.', - 'jetpack-connection' - ); - - /** - * Filters the disallowed notice for sites in safe mode attempting SSO. - * - * @module sso - * - * @since 2.10.0 - * - * @param string $error Error text. - */ - $error = apply_filters( 'jetpack_sso_disallowed_safe_mode_notice', $error ); - $message .= sprintf( '

            %s

            ', esc_html( $error ) ); - return $message; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-sso.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-sso.php deleted file mode 100644 index 5fddfccc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-sso.php +++ /dev/null @@ -1,1276 +0,0 @@ -is_user_connected() && - ! is_multisite() && - /** - * Toggle the ability to invite new users to create a WordPress.com account. - * - * @module sso - * - * @since 2.7.2 - * - * @param bool true Whether to allow admins to invite new users to create a WordPress.com account. - */ - apply_filters( 'jetpack_sso_invite_new_users_wpcom', true ) - ) { - new User_Admin(); - } - } - - /** - * Returns the single instance of the Automattic\Jetpack\Connection\SSO object - * - * @since jetpack-2.8 - * @return \Automattic\Jetpack\Connection\SSO - */ - public static function get_instance() { - if ( self::$instance !== null ) { - return self::$instance; - } - - self::$instance = new SSO(); - return self::$instance; - } - - /** - * Add SSO callables to the sync whitelist. - * - * @since 2.8.1 - * - * @param array $callables list of callables. - * - * @return array list of callables. - */ - public function sync_sso_callables( $callables ) { - $sso_callables = array( - 'sso_is_two_step_required' => array( Helpers::class, 'is_two_step_required' ), - 'sso_should_hide_login_form' => array( Helpers::class, 'should_hide_login_form' ), - 'sso_match_by_email' => array( Helpers::class, 'match_by_email' ), - 'sso_new_user_override' => array( Helpers::class, 'new_user_override' ), - 'sso_bypass_default_login_form' => array( Helpers::class, 'bypass_login_forward_wpcom' ), - ); - - return array_merge( $callables, $sso_callables ); - } - - /** - * Safety heads-up added to the logout messages when SSO is enabled. - * Some folks on a shared computer don't know that they need to log out of WordPress.com as well. - * - * @param WP_Error $errors WP_Error object. - */ - public function sso_reminder_logout_wpcom( $errors ) { - if ( ( new Host() )->is_wpcom_platform() ) { - return $errors; - } - - if ( ! empty( $errors->errors['loggedout'] ) ) { - $logout_message = wp_kses( - sprintf( - /* translators: %1$s is a link to the WordPress.com account settings page. */ - __( 'If you are on a shared computer, remember to also log out of WordPress.com.', 'jetpack-connection' ), - 'https://wordpress.com/me' - ), - array( - 'a' => array( - 'href' => array(), - ), - ) - ); - $errors->add( 'jetpack-sso-show-logout', $logout_message, 'message' ); - } - return $errors; - } - - /** - * If jetpack_force_logout == 1 in current user meta the user will be forced - * to logout and reauthenticate with the site. - **/ - public function maybe_logout_user() { - global $current_user; - - if ( 1 === (int) $current_user->jetpack_force_logout ) { - delete_user_meta( $current_user->ID, 'jetpack_force_logout' ); - Helpers::delete_connection_for_user( $current_user->ID ); - wp_logout(); - wp_safe_redirect( wp_login_url() ); - exit( 0 ); - } - } - - /** - * Adds additional methods the WordPress xmlrpc API for handling SSO specific features - * - * @param array $methods API methods. - * @return array - **/ - public function xmlrpc_methods( $methods ) { - $methods['jetpack.userDisconnect'] = array( $this, 'xmlrpc_user_disconnect' ); - return $methods; - } - - /** - * Marks a user's profile for disconnect from WordPress.com and forces a logout - * the next time the user visits the site. - * - * @param int $user_id User to disconnect from the site. - **/ - public function xmlrpc_user_disconnect( $user_id ) { - $user_query = new WP_User_Query( - array( - 'meta_key' => 'wpcom_user_id', - 'meta_value' => $user_id, - ) - ); - $user = $user_query->get_results(); - $user = $user[0]; - - if ( $user instanceof WP_User ) { - $user = wp_set_current_user( $user->ID ); - update_user_meta( $user->ID, 'jetpack_force_logout', '1' ); - Helpers::delete_connection_for_user( $user->ID ); - return true; - } - return false; - } - - /** - * Enqueues scripts and styles necessary for SSO login. - */ - public function login_enqueue_scripts() { - global $action; - - if ( ! Helpers::display_sso_form_for_action( $action ) ) { - return; - } - - Assets::register_script( - 'jetpack-sso-login', - '../../dist/jetpack-sso-login.js', - __FILE__, - array( - 'enqueue' => true, - 'version' => Package_Version::PACKAGE_VERSION, - ) - ); - } - - /** - * Adds Jetpack SSO classes to login body - * - * @param array $classes Array of classes to add to body tag. - * @return array Array of classes to add to body tag. - */ - public function login_body_class( $classes ) { - global $action; - - if ( ! Helpers::display_sso_form_for_action( $action ) ) { - return $classes; - } - - // Always add the jetpack-sso class so that we can add SSO specific styling even when the SSO form isn't being displayed. - $classes[] = 'jetpack-sso'; - - if ( ! ( new Status() )->in_safe_mode() ) { - /** - * Should we show the SSO login form? - * - * $_GET['jetpack-sso-default-form'] is used to provide a fallback in case JavaScript is not enabled. - * - * The default_to_sso_login() method allows us to dynamically decide whether we show the SSO login form or not. - * The SSO module uses the method to display the default login form if we can not find a user to log in via SSO. - * But, the method could be filtered by a site admin to always show the default login form if that is preferred. - */ - if ( empty( $_GET['jetpack-sso-show-default-form'] ) && Helpers::show_sso_login() ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $classes[] = 'jetpack-sso-form-display'; - } - } - - return $classes; - } - - /** - * Inlined admin styles for SSO. - */ - public function print_inline_admin_css() { - ?> - - General > Secure Sign On that allows users to - * turn off the login form on wp-login.php - * - * @since jetpack-2.7 - **/ - public function register_settings() { - - add_settings_section( - 'jetpack_sso_settings', - __( 'Secure Sign On', 'jetpack-connection' ), - '__return_false', - 'jetpack-sso' - ); - - /* - * Settings > General > Secure Sign On - * Require two step authentication - */ - register_setting( - 'jetpack-sso', - 'jetpack_sso_require_two_step', - array( $this, 'validate_jetpack_sso_require_two_step' ) - ); - - add_settings_field( - 'jetpack_sso_require_two_step', - '', // Output done in render $callback: __( 'Require Two-Step Authentication' , 'jetpack-connection' ). - array( $this, 'render_require_two_step' ), - 'jetpack-sso', - 'jetpack_sso_settings' - ); - - /* - * Settings > General > Secure Sign On - */ - register_setting( - 'jetpack-sso', - 'jetpack_sso_match_by_email', - array( $this, 'validate_jetpack_sso_match_by_email' ) - ); - - add_settings_field( - 'jetpack_sso_match_by_email', - '', // Output done in render $callback: __( 'Match by Email' , 'jetpack-connection' ). - array( $this, 'render_match_by_email' ), - 'jetpack-sso', - 'jetpack_sso_settings' - ); - } - - /** - * Builds the display for the checkbox allowing user to require two step - * auth be enabled on WordPress.com accounts before login. Displays in Settings > General - * - * @since jetpack-2.7 - **/ - public function render_require_two_step() { - ?> - - General. - * - * @param bool $input The jetpack_sso_require_two_step option setting. - * - * @since jetpack-2.7 - * @return int - **/ - public function validate_jetpack_sso_require_two_step( $input ) { - return ( ! empty( $input ) ) ? 1 : 0; - } - - /** - * Builds the display for the checkbox allowing the user to allow matching logins by email - * Displays in Settings > General - * - * @since jetpack-2.9 - **/ - public function render_match_by_email() { - ?> - - General. - * - * @param bool $input The jetpack_sso_match_by_email option setting. - * - * @since jetpack-2.9 - * @return int - **/ - public function validate_jetpack_sso_match_by_email( $input ) { - return ( ! empty( $input ) ) ? 1 : 0; - } - - /** - * Checks to determine if the user wants to login on wp-login - * - * This function mostly exists to cover the exceptions to login - * that may exist as other parameters to $_GET[action] as $_GET[action] - * does not have to exist. By default WordPress assumes login if an action - * is not set, however this may not be true, as in the case of logout - * where $_GET[loggedout] is instead set - * - * @return boolean - **/ - private function wants_to_login() { - $wants_to_login = false; - - // Cover default WordPress behavior. - $action = isset( $_REQUEST['action'] ) ? filter_var( wp_unslash( $_REQUEST['action'] ) ) : 'login'; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - - // And now the exceptions. - $action = isset( $_GET['loggedout'] ) ? 'loggedout' : $action; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - - if ( Helpers::display_sso_form_for_action( $action ) ) { - $wants_to_login = true; - } - - return $wants_to_login; - } - - /** - * Initialization for a SSO request. - */ - public function login_init() { - global $action; - - $tracking = new Tracking(); - - if ( Helpers::should_hide_login_form() ) { - /** - * Since the default authenticate filters fire at priority 20 for checking username and password, - * let's fire at priority 30. wp_authenticate_spam_check is fired at priority 99, but since we return a - * WP_Error in disable_default_login_form, then we won't trigger spam processing logic. - */ - add_filter( 'authenticate', array( Notices::class, 'disable_default_login_form' ), 30 ); - - /** - * Filter the display of the disclaimer message appearing when default WordPress login form is disabled. - * - * @module sso - * - * @since jetpack-2.8.0 - * - * @param bool true Should the disclaimer be displayed. Default to true. - */ - $display_sso_disclaimer = apply_filters( 'jetpack_sso_display_disclaimer', true ); - if ( $display_sso_disclaimer ) { - add_filter( 'login_message', array( Notices::class, 'msg_login_by_jetpack' ) ); - } - } - - if ( 'jetpack-sso' === $action ) { - if ( isset( $_GET['result'] ) && isset( $_GET['user_id'] ) && isset( $_GET['sso_nonce'] ) && 'success' === $_GET['result'] ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $this->handle_login(); - $this->display_sso_login_form(); - } elseif ( ( new Status() )->in_safe_mode() ) { - add_filter( 'login_message', array( Notices::class, 'sso_not_allowed_in_safe_mode' ) ); - } else { - // Is it wiser to just use wp_redirect than do this runaround to wp_safe_redirect? - add_filter( 'allowed_redirect_hosts', array( Helpers::class, 'allowed_redirect_hosts' ) ); - $reauth = ! empty( $_GET['force_reauth'] ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $sso_url = $this->get_sso_url_or_die( $reauth ); - - $tracking->record_user_event( 'sso_login_redirect_success' ); - wp_safe_redirect( $sso_url ); - exit( 0 ); - } - } elseif ( Helpers::display_sso_form_for_action( $action ) ) { - - // Save cookies so we can handle redirects after SSO. - static::save_cookies(); - - /** - * Check to see if the site admin wants to automagically forward the user - * to the WordPress.com login page AND that the request to wp-login.php - * is not something other than login (Like logout!) - */ - if ( Helpers::bypass_login_forward_wpcom() && $this->wants_to_login() ) { - add_filter( 'allowed_redirect_hosts', array( Helpers::class, 'allowed_redirect_hosts' ) ); - $reauth = ! empty( $_GET['force_reauth'] ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $sso_url = $this->get_sso_url_or_die( $reauth ); - $tracking->record_user_event( 'sso_login_redirect_bypass_success' ); - wp_safe_redirect( $sso_url ); - exit( 0 ); - } - - $this->display_sso_login_form(); - } - } - - /** - * Ensures that we can get a nonce from WordPress.com via XML-RPC before setting - * up the hooks required to display the SSO form. - */ - public function display_sso_login_form() { - add_filter( 'login_body_class', array( $this, 'login_body_class' ) ); - add_action( 'login_head', array( $this, 'print_inline_admin_css' ) ); - - if ( ( new Status() )->in_safe_mode() ) { - add_filter( 'login_message', array( Notices::class, 'sso_not_allowed_in_safe_mode' ) ); - return; - } - - $sso_nonce = self::request_initial_nonce(); - if ( is_wp_error( $sso_nonce ) ) { - return; - } - - add_action( 'login_form', array( $this, 'login_form' ) ); - add_action( 'login_enqueue_scripts', array( $this, 'login_enqueue_scripts' ) ); - } - - /** - * Conditionally save the redirect_to url as a cookie. - * - * @since jetpack-4.6.0 Renamed to save_cookies from maybe_save_redirect_cookies - */ - public static function save_cookies() { - if ( headers_sent() ) { - return new WP_Error( 'headers_sent', __( 'Cannot deal with cookie redirects, as headers are already sent.', 'jetpack-connection' ) ); - } - - setcookie( - 'jetpack_sso_original_request', - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Sniff misses the wrapping esc_url_raw(). - esc_url_raw( set_url_scheme( ( isset( $_SERVER['HTTP_HOST'] ) ? wp_unslash( $_SERVER['HTTP_HOST'] ) : '' ) . ( isset( $_SERVER['REQUEST_URI'] ) ? wp_unslash( $_SERVER['REQUEST_URI'] ) : '' ) ) ), - time() + HOUR_IN_SECONDS, - COOKIEPATH, - COOKIE_DOMAIN, - is_ssl(), - true - ); - - if ( ! empty( $_GET['redirect_to'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended - // If we have something to redirect to. - $url = esc_url_raw( wp_unslash( $_GET['redirect_to'] ) ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - setcookie( 'jetpack_sso_redirect_to', $url, time() + HOUR_IN_SECONDS, COOKIEPATH, COOKIE_DOMAIN, is_ssl(), true ); - } elseif ( ! empty( $_COOKIE['jetpack_sso_redirect_to'] ) ) { - // Otherwise, if it's already set, purge it. - setcookie( 'jetpack_sso_redirect_to', ' ', time() - YEAR_IN_SECONDS, COOKIEPATH, COOKIE_DOMAIN, is_ssl(), true ); - } - } - - /** - * Outputs the Jetpack SSO button and description as well as the toggle link - * for switching between Jetpack SSO and default login. - */ - public function login_form() { - $site_name = get_bloginfo( 'name' ); - if ( ! $site_name ) { - $site_name = get_bloginfo( 'url' ); - } - - $display_name = ! empty( $_COOKIE[ 'jetpack_sso_wpcom_name_' . COOKIEHASH ] ) - ? sanitize_text_field( wp_unslash( $_COOKIE[ 'jetpack_sso_wpcom_name_' . COOKIEHASH ] ) ) - : false; - $gravatar = ! empty( $_COOKIE[ 'jetpack_sso_wpcom_gravatar_' . COOKIEHASH ] ) - ? esc_url_raw( wp_unslash( $_COOKIE[ 'jetpack_sso_wpcom_gravatar_' . COOKIEHASH ] ) ) - : false; - - ?> -
            - -
            - - -

            - %s', 'jetpack-connection' ), esc_html( $display_name ) ), - array( 'span' => true ) - ); - ?> -

            -
            - - - - -
            - build_sso_button( array(), true ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Escaping done in build_sso_button() ?> - - - - - - -

            - -

            - -
            - - -
            - -
            - - - - - - - - - -
            - is_user_connected() ) { - Helpers::delete_connection_for_user( get_current_user_id() ); - } - } - - /** - * Retrieves nonce used for SSO form. - * - * @return string|WP_Error - */ - public static function request_initial_nonce() { - $nonce = ! empty( $_COOKIE['jetpack_sso_nonce'] ) - ? sanitize_key( wp_unslash( $_COOKIE['jetpack_sso_nonce'] ) ) - : false; - - if ( ! $nonce ) { - $xml = new Jetpack_IXR_Client(); - $xml->query( 'jetpack.sso.requestNonce' ); - - if ( $xml->isError() ) { - return new WP_Error( $xml->getErrorCode(), $xml->getErrorMessage() ); - } - - $nonce = sanitize_key( $xml->getResponse() ); - - setcookie( - 'jetpack_sso_nonce', - $nonce, - time() + ( 10 * MINUTE_IN_SECONDS ), - COOKIEPATH, - COOKIE_DOMAIN, - is_ssl(), - true - ); - } - - return $nonce; - } - - /** - * The function that actually handles the login! - */ - public function handle_login() { - $wpcom_nonce = isset( $_GET['sso_nonce'] ) ? sanitize_key( $_GET['sso_nonce'] ) : ''; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $wpcom_user_id = isset( $_GET['user_id'] ) ? (int) $_GET['user_id'] : 0; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - - $xml = new Jetpack_IXR_Client(); - $xml->query( 'jetpack.sso.validateResult', $wpcom_nonce, $wpcom_user_id ); - - $user_data = $xml->isError() ? false : $xml->getResponse(); - if ( empty( $user_data ) ) { - add_filter( 'jetpack_sso_default_to_sso_login', '__return_false' ); - add_filter( 'login_message', array( Notices::class, 'error_invalid_response_data' ) ); - return; - } - - $user_data = (object) $user_data; - $user = null; - - /** - * Fires before Jetpack's SSO modifies the log in form. - * - * @module sso - * - * @since jetpack-2.6.0 - * - * @param object $user_data WordPress.com User information. - */ - do_action( 'jetpack_sso_pre_handle_login', $user_data ); - - $tracking = new Tracking(); - - if ( Helpers::is_two_step_required() && 0 === (int) $user_data->two_step_enabled ) { - $this->user_data = $user_data; - - $tracking->record_user_event( - 'sso_login_failed', - array( - 'error_message' => 'error_msg_enable_two_step', - ) - ); - - $error = new WP_Error( 'two_step_required', __( 'You must have Two-Step Authentication enabled on your WordPress.com account.', 'jetpack-connection' ) ); - - /** This filter is documented in core/src/wp-includes/pluggable.php */ - do_action( 'wp_login_failed', $user_data->login, $error ); - add_filter( 'login_message', array( Notices::class, 'error_msg_enable_two_step' ) ); - return; - } - - $user_found_with = ''; - if ( empty( $user ) && isset( $user_data->external_user_id ) ) { - $user_found_with = 'external_user_id'; - $user = get_user_by( 'id', (int) $user_data->external_user_id ); - if ( $user ) { - $expected_id = get_user_meta( $user->ID, 'wpcom_user_id', true ); - if ( $expected_id && $expected_id != $user_data->ID ) { // phpcs:ignore WordPress.PHP.StrictComparisons.LooseComparison, Universal.Operators.StrictComparisons.LooseNotEqual - $error = new WP_Error( 'expected_wpcom_user', __( 'Something got a little mixed up and an unexpected WordPress.com user logged in.', 'jetpack-connection' ) ); - - $tracking->record_user_event( - 'sso_login_failed', - array( - 'error_message' => 'error_unexpected_wpcom_user', - ) - ); - - /** This filter is documented in core/src/wp-includes/pluggable.php */ - do_action( 'wp_login_failed', $user_data->login, $error ); - add_filter( 'login_message', array( Notices::class, 'error_invalid_response_data' ) ); // @todo Need to have a better notice. This is only for the sake of testing the validation. - return; - } - update_user_meta( $user->ID, 'wpcom_user_id', $user_data->ID ); - } - } - - // If we don't have one by wpcom_user_id, try by the email? - if ( empty( $user ) && Helpers::match_by_email() ) { - $user_found_with = 'match_by_email'; - $user = get_user_by( 'email', $user_data->email ); - if ( $user ) { - update_user_meta( $user->ID, 'wpcom_user_id', $user_data->ID ); - } - } - - // If we've still got nothing, create the user. - $new_user_override_role = Helpers::new_user_override( $user_data ); - if ( empty( $user ) && ( get_option( 'users_can_register' ) || $new_user_override_role ) ) { - /** - * If not matching by email we still need to verify the email does not exist - * or this blows up - * - * If match_by_email is true, we know the email doesn't exist, as it would have - * been found in the first pass. If get_user_by( 'email' ) doesn't find the - * user, then we know that email is unused, so it's safe to add. - */ - if ( Helpers::match_by_email() || ! get_user_by( 'email', $user_data->email ) ) { - - if ( $new_user_override_role ) { - $user_data->role = $new_user_override_role; - } - - $user = Utils::generate_user( $user_data ); - if ( ! $user ) { - $tracking->record_user_event( - 'sso_login_failed', - array( - 'error_message' => 'could_not_create_username', - ) - ); - add_filter( 'login_message', array( Notices::class, 'error_unable_to_create_user' ) ); - return; - } - - $user_found_with = $new_user_override_role - ? 'user_created_new_user_override' - : 'user_created_users_can_register'; - } else { - $tracking->record_user_event( - 'sso_login_failed', - array( - 'error_message' => 'error_msg_email_already_exists', - ) - ); - - $this->user_data = $user_data; - add_action( 'login_message', array( Notices::class, 'error_msg_email_already_exists' ) ); - return; - } - } - - /** - * Fires after we got login information from WordPress.com. - * - * @module sso - * - * @since jetpack-2.6.0 - * - * @param WP_User|false|null $user Local User information. - * @param object $user_data WordPress.com User Login information. - */ - do_action( 'jetpack_sso_handle_login', $user, $user_data ); - - if ( $user ) { - // Cache the user's details, so we can present it back to them on their user screen. - update_user_meta( $user->ID, 'wpcom_user_data', $user_data ); - - add_filter( 'auth_cookie_expiration', array( Helpers::class, 'extend_auth_cookie_expiration_for_sso' ) ); - wp_set_auth_cookie( $user->ID, true ); - remove_filter( 'auth_cookie_expiration', array( Helpers::class, 'extend_auth_cookie_expiration_for_sso' ) ); - - /** This filter is documented in core/src/wp-includes/user.php */ - do_action( 'wp_login', $user->user_login, $user ); - - wp_set_current_user( $user->ID ); - - $_request_redirect_to = isset( $_REQUEST['redirect_to'] ) ? esc_url_raw( wp_unslash( $_REQUEST['redirect_to'] ) ) : ''; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $redirect_to = user_can( $user, 'edit_posts' ) ? admin_url() : self::profile_page_url(); - - // If we have a saved redirect to request in a cookie. - if ( ! empty( $_COOKIE['jetpack_sso_redirect_to'] ) ) { - // Set that as the requested redirect to. - $redirect_to = esc_url_raw( wp_unslash( $_COOKIE['jetpack_sso_redirect_to'] ) ); - $_request_redirect_to = $redirect_to; - } - - $json_api_auth_environment = Helpers::get_json_api_auth_environment(); - - $is_json_api_auth = ! empty( $json_api_auth_environment ); - $is_user_connected = ( new Manager() )->is_user_connected( $user->ID ); - $roles = new Roles(); - $tracking->record_user_event( - 'sso_user_logged_in', - array( - 'user_found_with' => $user_found_with, - 'user_connected' => (bool) $is_user_connected, - 'user_role' => $roles->translate_current_user_to_role(), - 'is_json_api_auth' => $is_json_api_auth, - ) - ); - - if ( $is_json_api_auth ) { - $authorize_json_api = new Authorize_Json_Api(); - $authorize_json_api->verify_json_api_authorization_request( $json_api_auth_environment ); - $authorize_json_api->store_json_api_authorization_token( $user->user_login, $user ); - - } elseif ( ! $is_user_connected ) { - wp_safe_redirect( - add_query_arg( - array( - 'redirect_to' => $redirect_to, - 'request_redirect_to' => $_request_redirect_to, - 'calypso_env' => ( new Host() )->get_calypso_env(), - 'jetpack-sso-auth-redirect' => '1', - ), - admin_url() - ) - ); - exit( 0 ); - } - - add_filter( 'allowed_redirect_hosts', array( Helpers::class, 'allowed_redirect_hosts' ) ); - wp_safe_redirect( - /** This filter is documented in core/src/wp-login.php */ - apply_filters( 'login_redirect', $redirect_to, $_request_redirect_to, $user ) - ); - exit( 0 ); - } - - add_filter( 'jetpack_sso_default_to_sso_login', '__return_false' ); - - $tracking->record_user_event( - 'sso_login_failed', - array( - 'error_message' => 'cant_find_user', - ) - ); - - $this->user_data = $user_data; - - $error = new WP_Error( 'account_not_found', __( 'Account not found. If you already have an account, make sure you have connected to WordPress.com.', 'jetpack-connection' ) ); - - /** This filter is documented in core/src/wp-includes/pluggable.php */ - do_action( 'wp_login_failed', $user_data->login, $error ); - add_filter( 'login_message', array( Notices::class, 'cant_find_user' ) ); - } - - /** - * Retrieve the admin profile page URL. - */ - public static function profile_page_url() { - return admin_url( 'profile.php' ); - } - - /** - * Builds the "Login to WordPress.com" button that is displayed on the login page as well as user profile page. - * - * @param array $args An array of arguments to add to the SSO URL. - * @param boolean $is_primary If the button have the `button-primary` class. - * @return string Returns the HTML markup for the button. - */ - public function build_sso_button( $args = array(), $is_primary = false ) { - $url = $this->build_sso_button_url( $args ); - $classes = $is_primary - ? 'jetpack-sso button button-primary' - : 'jetpack-sso button'; - - return sprintf( - '%3$s %4$s', - esc_url( $url ), - $classes, - '', - esc_html__( 'Log in with WordPress.com', 'jetpack-connection' ) - ); - } - - /** - * Builds a URL with `jetpack-sso` action and option args which is used to setup SSO. - * - * @param array $args An array of arguments to add to the SSO URL. - * @return string The URL used for SSO. - */ - public function build_sso_button_url( $args = array() ) { - $defaults = array( - 'action' => 'jetpack-sso', - ); - - $args = wp_parse_args( $args, $defaults ); - - if ( ! empty( $_GET['redirect_to'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $args['redirect_to'] = rawurlencode( esc_url_raw( wp_unslash( $_GET['redirect_to'] ) ) ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - } - - return add_query_arg( $args, wp_login_url() ); - } - - /** - * Retrieves a WordPress.com SSO URL with appropriate query parameters or dies. - * - * @param boolean $reauth If the user be forced to reauthenticate on WordPress.com. - * @param array $args Optional query parameters. - * @return string The WordPress.com SSO URL. - */ - public function get_sso_url_or_die( $reauth = false, $args = array() ) { - $custom_login_url = Helpers::get_custom_login_url(); - if ( $custom_login_url ) { - $args['login_url'] = rawurlencode( $custom_login_url ); - } - - if ( empty( $reauth ) ) { - $sso_redirect = $this->build_sso_url( $args ); - } else { - Helpers::clear_wpcom_profile_cookies(); - $sso_redirect = $this->build_reauth_and_sso_url( $args ); - } - - // If there was an error retrieving the SSO URL, then error. - if ( is_wp_error( $sso_redirect ) ) { - $error_message = sanitize_text_field( - sprintf( '%s: %s', $sso_redirect->get_error_code(), $sso_redirect->get_error_message() ) - ); - $tracking = new Tracking(); - $tracking->record_user_event( - 'sso_login_redirect_failed', - array( - 'error_message' => $error_message, - ) - ); - wp_die( esc_html( $error_message ) ); - } - - return $sso_redirect; - } - - /** - * Build WordPress.com SSO URL with appropriate query parameters. - * - * @param array $args Optional query parameters. - * @return string|WP_Error WordPress.com SSO URL - */ - public function build_sso_url( $args = array() ) { - $sso_nonce = ! empty( $args['sso_nonce'] ) ? $args['sso_nonce'] : self::request_initial_nonce(); - $defaults = array( - 'action' => 'jetpack-sso', - 'site_id' => Manager::get_site_id( true ), - 'sso_nonce' => $sso_nonce, - 'calypso_auth' => '1', - ); - - $args = wp_parse_args( $args, $defaults ); - - if ( is_wp_error( $sso_nonce ) ) { - return $sso_nonce; - } - - return add_query_arg( $args, 'https://wordpress.com/wp-login.php' ); - } - - /** - * Build WordPress.com SSO URL with appropriate query parameters, - * including the parameters necessary to force the user to reauthenticate - * on WordPress.com. - * - * @param array $args Optional query parameters. - * @return string|WP_Error WordPress.com SSO URL - */ - public function build_reauth_and_sso_url( $args = array() ) { - $sso_nonce = ! empty( $args['sso_nonce'] ) ? $args['sso_nonce'] : self::request_initial_nonce(); - $redirect = $this->build_sso_url( - array( - 'force_auth' => '1', - 'sso_nonce' => $sso_nonce, - ) - ); - - if ( is_wp_error( $redirect ) ) { - return $redirect; - } - - $defaults = array( - 'action' => 'jetpack-sso', - 'site_id' => Manager::get_site_id( true ), - 'sso_nonce' => $sso_nonce, - 'reauth' => '1', - 'redirect_to' => rawurlencode( $redirect ), - 'calypso_auth' => '1', - ); - - $args = wp_parse_args( $args, $defaults ); - - if ( is_wp_error( $args['sso_nonce'] ) ) { - return $args['sso_nonce']; - } - - return add_query_arg( $args, 'https://wordpress.com/wp-login.php' ); - } - - /** - * Determines local user associated with a given WordPress.com user ID. - * - * @since jetpack-2.6.0 - * - * @param int $wpcom_user_id User ID from WordPress.com. - * @return null|object Local user object if found, null if not. - */ - public static function get_user_by_wpcom_id( $wpcom_user_id ) { - $user_query = new WP_User_Query( - array( - 'meta_key' => 'wpcom_user_id', - 'meta_value' => (int) $wpcom_user_id, - 'number' => 1, - ) - ); - - $users = $user_query->get_results(); - return $users ? array_shift( $users ) : null; - } - - /** - * When jetpack-sso-auth-redirect query parameter is set, will redirect user to - * WordPress.com authorization flow. - * - * We redirect here instead of in handle_login() because Jetpack::init()->build_connect_url - * calls menu_page_url() which doesn't work properly until admin menus are registered. - */ - public function maybe_authorize_user_after_sso() { - if ( empty( $_GET['jetpack-sso-auth-redirect'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended - return; - } - - $redirect_to = ! empty( $_GET['redirect_to'] ) ? esc_url_raw( wp_unslash( $_GET['redirect_to'] ) ) : admin_url(); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $request_redirect_to = ! empty( $_GET['request_redirect_to'] ) ? esc_url_raw( wp_unslash( $_GET['request_redirect_to'] ) ) : $redirect_to; // phpcs:ignore WordPress.Security.NonceVerification.Recommended - - /** This filter is documented in core/src/wp-login.php */ - $redirect_after_auth = apply_filters( 'login_redirect', $redirect_to, $request_redirect_to, wp_get_current_user() ); - - /** - * Since we are passing this redirect to WordPress.com and therefore can not use wp_safe_redirect(), - * let's sanitize it here to make sure it's safe. If the redirect is not safe, then use admin_url(). - */ - $redirect_after_auth = wp_sanitize_redirect( $redirect_after_auth ); - $redirect_after_auth = wp_validate_redirect( $redirect_after_auth, admin_url() ); - - /** - * Return the raw connect URL with our redirect and attribute connection to SSO. - * We remove any other filters that may be turning on the in-place connection - * since we will be redirecting the user as opposed to iFraming. - */ - remove_all_filters( 'jetpack_use_iframe_authorization_flow' ); - add_filter( 'jetpack_use_iframe_authorization_flow', '__return_false' ); - - $connection = new Manager( 'jetpack-connection' ); - $connect_url = ( new Authorize_Redirect( $connection ) )->build_authorize_url( $redirect_after_auth, 'sso', true ); - - add_filter( 'allowed_redirect_hosts', array( Helpers::class, 'allowed_redirect_hosts' ) ); - wp_safe_redirect( $connect_url ); - exit( 0 ); - } - - /** - * Cache user's display name and Gravatar so it can be displayed on the login screen. These cookies are - * stored when the user logs out, and then deleted when the user logs in. - */ - public function store_wpcom_profile_cookies_on_logout() { - $user_id = get_current_user_id(); - if ( ! ( new Manager() )->is_user_connected( $user_id ) ) { - return; - } - - $user_data = $this->get_user_data( $user_id ); - if ( ! $user_data ) { - return; - } - - setcookie( - 'jetpack_sso_wpcom_name_' . COOKIEHASH, - $user_data->display_name, - time() + WEEK_IN_SECONDS, - COOKIEPATH, - COOKIE_DOMAIN, - is_ssl(), - true - ); - - setcookie( - 'jetpack_sso_wpcom_gravatar_' . COOKIEHASH, - get_avatar_url( - $user_data->email, - array( - 'size' => 144, - 'default' => 'mystery', - ) - ), - time() + WEEK_IN_SECONDS, - COOKIEPATH, - COOKIE_DOMAIN, - is_ssl(), - true - ); - } - - /** - * Determines if a local user is connected to WordPress.com - * - * @since jetpack-2.8 - * @param integer $user_id - Local user id. - * @return boolean - **/ - public function is_user_connected( $user_id ) { - return $this->get_user_data( $user_id ); - } - - /** - * Retrieves a user's WordPress.com data - * - * @since jetpack-2.8 - * @param integer $user_id - Local user id. - * @return mixed null or stdClass - **/ - public function get_user_data( $user_id ) { - return get_user_meta( $user_id, 'wpcom_user_data', true ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-user-admin.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-user-admin.php deleted file mode 100644 index 06977da2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/class-user-admin.php +++ /dev/null @@ -1,1322 +0,0 @@ - 'defer', - 'in_footer' => true, - 'enqueue' => true, - ) - ); - } - - /** - * Intercept the arguments for building the table, and create WP_User_Query instance - * - * @param array $args The search arguments. - * - * @return array - */ - public function set_user_query( $args ) { - self::$user_search = new WP_User_Query( $args ); - return $args; - } - - /** - * Revokes WordPress.com invitation. - * - * @param int $user_id The user ID. - * @return mixed Response from the API call or false on failure. - */ - public function revoke_user_invite( $user_id ) { - try { - $has_pending_invite = self::has_pending_wpcom_invite( $user_id ); - - if ( $has_pending_invite ) { - $response = self::send_revoke_wpcom_invite( $has_pending_invite ); - $event = 'sso_user_invite_revoked'; - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $body = json_decode( wp_remote_retrieve_body( $response ) ); - $tracking_event_data = array( - 'success' => 'false', - 'error_code' => 'invalid-revoke-api-error', - ); - - if ( ! empty( $body ) && ! empty( $body->message ) ) { - $tracking_event_data['error_message'] = $body->message; - } - self::$tracking->record_user_event( - $event, - $tracking_event_data - ); - return $response; - } - - $body = json_decode( $response['body'] ); - - if ( ! $body->deleted ) { - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => 'invalid-invite-revoke', - ) - ); - } else { - self::$tracking->record_user_event( $event, array( 'success' => 'true' ) ); - } - - return $response; - } else { - // Delete external contributor if it exists. - $wpcom_user_data = ( new Manager() )->get_connected_user_data( $user_id ); - if ( isset( $wpcom_user_data['ID'] ) ) { - return self::delete_external_contributor( $wpcom_user_data['ID'] ); - } - } - } catch ( \Exception $e ) { - return false; - } - } - - /** - * Renders invitations errors/success messages in users.php. - */ - public function handle_invitation_results() { - $valid_nonce = isset( $_GET['_wpnonce'] ) - ? wp_verify_nonce( sanitize_key( $_GET['_wpnonce'] ), 'jetpack-sso-invite-user' ) - : false; - - if ( ! $valid_nonce || ! isset( $_GET['jetpack-sso-invite-user'] ) ) { - return; - } - if ( $_GET['jetpack-sso-invite-user'] === 'success' ) { - return wp_admin_notice( __( 'User was invited successfully!', 'jetpack-connection' ), array( 'type' => 'success' ) ); - } - if ( $_GET['jetpack-sso-invite-user'] === 'reinvited-success' ) { - return wp_admin_notice( __( 'User was re-invited successfully!', 'jetpack-connection' ), array( 'type' => 'success' ) ); - } - - if ( $_GET['jetpack-sso-invite-user'] === 'successful-revoke' ) { - return wp_admin_notice( __( 'User invite revoked successfully.', 'jetpack-connection' ), array( 'type' => 'success' ) ); - } - - if ( $_GET['jetpack-sso-invite-user'] === 'failed' && isset( $_GET['jetpack-sso-api-error-message'] ) ) { - return wp_admin_notice( wp_kses( wp_unslash( $_GET['jetpack-sso-api-error-message'] ), array() ), array( 'type' => 'error' ) ); - } - - if ( $_GET['jetpack-sso-invite-user'] === 'failed' && isset( $_GET['jetpack-sso-invite-error'] ) ) { - switch ( $_GET['jetpack-sso-invite-error'] ) { - case 'invalid-user': - return wp_admin_notice( __( 'Tried to invite a user that doesn’t exist.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-email': - return wp_admin_notice( __( 'Tried to invite a user that doesn’t have an email address.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-user-permissions': - return wp_admin_notice( __( 'You don’t have permission to invite users.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-user-revoke': - return wp_admin_notice( __( 'Tried to revoke an invite for a user that doesn’t exist.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-invite-revoke': - return wp_admin_notice( __( 'Tried to revoke an invite that doesn’t exist.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-revoke-permissions': - return wp_admin_notice( __( 'You don’t have permission to revoke invites.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'empty-invite': - return wp_admin_notice( __( 'There is no previous invite for this user', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-invite': - return wp_admin_notice( __( 'Attempted to send a new invitation to a user using an invite that doesn’t exist.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'error-revoke': - return wp_admin_notice( __( 'An error has occurred when revoking the invite for the user.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - case 'invalid-revoke-api-error': - return wp_admin_notice( __( 'An error has occurred when revoking the user invite.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - default: - return wp_admin_notice( __( 'An error has occurred when inviting the user to the site.', 'jetpack-connection' ), array( 'type' => 'error' ) ); - } - } - } - - /** - * Invites a user to connect to WordPress.com to allow them to log in via SSO. - */ - public function invite_user_to_wpcom() { - check_admin_referer( 'jetpack-sso-invite-user', 'invite_nonce' ); - $nonce = wp_create_nonce( 'jetpack-sso-invite-user' ); - $event = 'sso_user_invite_sent'; - - if ( ! current_user_can( 'create_users' ) ) { - $error = 'invalid-user-permissions'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, - '_wpnonce' => $nonce, - ); - return self::create_error_notice_and_redirect( $query_params ); - } elseif ( isset( $_GET['user_id'] ) ) { - $user_id = intval( wp_unslash( $_GET['user_id'] ) ); - $user = get_user_by( 'id', $user_id ); - $user_email = $user->user_email; - - if ( ! $user || ! $user_email ) { - $reason = ! $user ? 'invalid-user' : 'invalid-email'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $reason, - '_wpnonce' => $nonce, - ); - - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $reason, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - $blog_id = Manager::get_site_id( true ); - $roles = new Roles(); - $user_role = $roles->translate_user_to_role( $user ); - - $url = '/sites/' . $blog_id . '/invites/new'; - $response = Client::wpcom_json_api_request_as_user( - $url, - 'v2', - array( - 'method' => 'POST', - ), - array( - 'invitees' => array( - array( - 'email_or_username' => $user_email, - 'role' => $user_role, - ), - ), - ), - 'wpcom' - ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $error_code = 'invalid-invite-api-error'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error_code, - '_wpnonce' => $nonce, - ); - - $tracking_event_data = array( - 'success' => 'false', - 'error_code' => $error_code, - ); - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - if ( ! empty( $body ) && ! empty( $body->message ) ) { - $query_params['jetpack-sso-api-error-message'] = $body->message; - $tracking_event_data['error_message'] = $body->message; - } - - self::$tracking->record_user_event( - $event, - $tracking_event_data - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - // access the first item since we're inviting one user. - if ( is_array( $body ) && ! empty( $body ) ) { - $body = $body[0]; - } - - $query_params = array( - 'jetpack-sso-invite-user' => $body->success ? 'success' : 'failed', - '_wpnonce' => $nonce, - ); - - if ( ! $body->success && $body->errors ) { - $response_error = array_keys( (array) $body->errors ); - $query_params['jetpack-sso-invite-error'] = $response_error[0]; - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $response_error[0], - ) - ); - } else { - self::$tracking->record_user_event( $event, array( 'success' => 'true' ) ); - } - - return self::create_error_notice_and_redirect( $query_params ); - } else { - $error = 'invalid-user'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, - '_wpnonce' => $nonce, - ); - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $error, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - wp_die(); - } - - /** - * Revokes a user's invitation to connect to WordPress.com. - * - * @param string $invite_id The ID of the invite to revoke. - */ - public function send_revoke_wpcom_invite( $invite_id ) { - $blog_id = Manager::get_site_id( true ); - - $url = '/sites/' . $blog_id . '/invites/delete'; - return Client::wpcom_json_api_request_as_user( - $url, - 'v2', - array( - 'method' => 'POST', - ), - array( - 'invite_ids' => array( $invite_id ), - ), - 'wpcom' - ); - } - - /** - * Handles logic to revoke user invite. - */ - public function handle_request_revoke_invite() { - check_admin_referer( 'jetpack-sso-revoke-user-invite', 'revoke_invite_nonce' ); - $nonce = wp_create_nonce( 'jetpack-sso-invite-user' ); - $event = 'sso_user_invite_revoked'; - if ( ! current_user_can( 'promote_users' ) ) { - $error = 'invalid-revoke-permissions'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, - '_wpnonce' => $nonce, - ); - - return self::create_error_notice_and_redirect( $query_params ); - } elseif ( isset( $_GET['user_id'] ) ) { - $user_id = intval( wp_unslash( $_GET['user_id'] ) ); - $user = get_user_by( 'id', $user_id ); - if ( ! $user ) { - $error = 'invalid-user-revoke'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, - '_wpnonce' => $nonce, - ); - - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $error, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - if ( ! isset( $_GET['invite_id'] ) ) { - $error = 'invalid-invite-revoke'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, - '_wpnonce' => $nonce, - ); - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $error, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - $invite_id = sanitize_text_field( wp_unslash( $_GET['invite_id'] ) ); - $response = self::send_revoke_wpcom_invite( $invite_id ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $error = 'invalid-revoke-api-error'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, // general error message - '_wpnonce' => $nonce, - ); - - $tracking_event_data = array( - 'success' => 'false', - 'error_code' => $error, - ); - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - if ( ! empty( $body ) && ! empty( $body->message ) ) { - $query_params['jetpack-sso-api-error-message'] = $body->message; - $tracking_event_data['error_message'] = $body->message; - } - - self::$tracking->record_user_event( - $event, - $tracking_event_data - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - $body = json_decode( $response['body'] ); - $query_params = array( - 'jetpack-sso-invite-user' => $body->deleted ? 'successful-revoke' : 'failed', - '_wpnonce' => $nonce, - ); - if ( ! $body->deleted ) { // no invite was deleted, probably it does not exist - $error = 'invalid-invite-revoke'; - $query_params['jetpack-sso-invite-error'] = $error; - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $error, - ) - ); - } else { - self::$tracking->record_user_event( $event, array( 'success' => 'true' ) ); - } - return self::create_error_notice_and_redirect( $query_params ); - } else { - $error = 'invalid-user-revoke'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $error, - '_wpnonce' => $nonce, - ); - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $error, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - wp_die(); - } - - /** - * Handles resend user invite. - */ - public function handle_request_resend_invite() { - check_admin_referer( 'jetpack-sso-resend-user-invite', 'resend_invite_nonce' ); - $nonce = wp_create_nonce( 'jetpack-sso-invite-user' ); - $event = 'sso_user_invite_resend'; - if ( ! current_user_can( 'create_users' ) ) { - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => 'invalid-user-permissions', - '_wpnonce' => $nonce, - ); - return self::create_error_notice_and_redirect( $query_params ); - } elseif ( isset( $_GET['invite_id'] ) ) { - $invite_slug = sanitize_text_field( wp_unslash( $_GET['invite_id'] ) ); - $blog_id = Manager::get_site_id( true ); - $url = '/sites/' . $blog_id . '/invites/resend'; - $response = Client::wpcom_json_api_request_as_user( - $url, - 'v2', - array( - 'method' => 'POST', - ), - array( - 'invite_slug' => $invite_slug, - ), - 'wpcom' - ); - - $status_code = wp_remote_retrieve_response_code( $response ); - - if ( 200 !== $status_code ) { - $message_type = $status_code === 404 ? 'invalid-invite' : ''; // empty is the general error message - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => $message_type, - '_wpnonce' => $nonce, - ); - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $message_type, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - - $body = json_decode( $response['body'] ); - $invite_response_message = $body->success ? 'reinvited-success' : 'failed'; - $query_params = array( - 'jetpack-sso-invite-user' => $invite_response_message, - '_wpnonce' => $nonce, - ); - - if ( ! $body->success ) { - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $invite_response_message, - ) - ); - } else { - self::$tracking->record_user_event( $event, array( 'success' => 'true' ) ); - } - - return self::create_error_notice_and_redirect( $query_params ); - } else { - $error = 'empty-invite'; - $query_params = array( - 'jetpack-sso-invite-user' => 'failed', - 'jetpack-sso-invite-error' => 'empty-invite', - '_wpnonce' => $nonce, - ); - self::$tracking->record_user_event( - $event, - array( - 'success' => 'false', - 'error_message' => $error, - ) - ); - return self::create_error_notice_and_redirect( $query_params ); - } - } - - /** - * Adds 'Revoke invite' and 'Resend invite' link to user table row actions. - * Removes 'Reset password' link. - * - * @param array $actions - User row actions. - * @param WP_User $user_object - User object. - */ - public function jetpack_user_table_row_actions( $actions, $user_object ) { - $user_id = $user_object->ID; - $has_pending_invite = self::has_pending_wpcom_invite( $user_id ); - - if ( current_user_can( 'promote_users' ) && $has_pending_invite ) { - $nonce = wp_create_nonce( 'jetpack-sso-revoke-user-invite' ); - $actions['sso_revoke_invite'] = sprintf( - '%s', - add_query_arg( - array( - 'action' => 'jetpack_revoke_invite_user_to_wpcom', - 'user_id' => $user_id, - 'revoke_invite_nonce' => $nonce, - 'invite_id' => $has_pending_invite, - ), - admin_url( 'admin-post.php' ) - ), - esc_html__( 'Revoke invite', 'jetpack-connection' ) - ); - } - if ( current_user_can( 'promote_users' ) && $has_pending_invite ) { - $nonce = wp_create_nonce( 'jetpack-sso-resend-user-invite' ); - $actions['sso_resend_invite'] = sprintf( - '%s', - add_query_arg( - array( - 'action' => 'jetpack_resend_invite_user_to_wpcom', - 'user_id' => $user_id, - 'resend_invite_nonce' => $nonce, - 'invite_id' => $has_pending_invite, - ), - admin_url( 'admin-post.php' ) - ), - esc_html__( 'Resend invite', 'jetpack-connection' ) - ); - } - - if ( - current_user_can( 'promote_users' ) - && ( - $has_pending_invite - || ( new Manager() )->is_user_connected( $user_id ) - ) - ) { - unset( $actions['resetpassword'] ); - } - - return $actions; - } - - /** - * Render the invitation email message. - */ - public function render_invitation_email_message() { - $message = wp_kses( - __( - 'We highly recommend inviting users to join WordPress.com and log in securely using Secure Sign On to ensure maximum security and efficiency.', - 'jetpack-connection' - ), - array( - 'a' => array( - 'class' => array(), - 'href' => array(), - 'rel' => array(), - 'target' => array(), - ), - ) - ); - wp_admin_notice( - $message, - array( - 'id' => 'invitation_message', - 'type' => 'info', - 'dismissible' => false, - 'additional_classes' => array( 'jetpack-sso-admin-create-user-invite-message' ), - ) - ); - } - - /** - * Render a note that wp.com invites will be automatically revoked. - */ - public function render_invitations_notices_for_deleted_users() { - check_admin_referer( 'bulk-users' ); - - // When one user is deleted, the param is `user`, when multiple users are deleted, the param is `users`. - // We start with `users` and fallback to `user`. - $user_id = isset( $_GET['user'] ) ? intval( wp_unslash( $_GET['user'] ) ) : null; - $user_ids = isset( $_GET['users'] ) ? array_map( 'intval', wp_unslash( $_GET['users'] ) ) : array( $user_id ); - - $users_with_invites = array_filter( - $user_ids, - function ( $user_id ) { - return $user_id !== null && self::has_pending_wpcom_invite( $user_id ); - } - ); - - $users_with_invites = array_map( - function ( $user_id ) { - $user = get_user_by( 'id', $user_id ); - return $user->user_login; - }, - $users_with_invites - ); - - $invites_count = count( $users_with_invites ); - if ( $invites_count > 0 ) { - $users_with_invites = implode( ', ', $users_with_invites ); - $message = wp_kses( - sprintf( - /* translators: %s is a comma-separated list of user logins. */ - _n( - 'WordPress.com invitation will be automatically revoked for user: %s.', - 'WordPress.com invitations will be automatically revoked for users: %s.', - $invites_count, - 'jetpack-connection' - ), - $users_with_invites - ), - array( 'strong' => true ) - ); - wp_admin_notice( - $message, - array( - 'id' => 'invitation_message', - 'type' => 'info', - 'dismissible' => false, - 'additional_classes' => array( 'jetpack-sso-admin-create-user-invite-message' ), - ) - ); - } - } - - /** - * Render WordPress.com invite checkbox for new user registration. - * - * @param string $type The type of new user form the hook follows. - */ - public function render_wpcom_invite_checkbox( $type ) { - /* - * Only check this box by default on WordPress.com sites - * that do not use the WooCommerce plugin. - */ - $is_checked = ( new Host() )->is_wpcom_platform() && ! class_exists( 'WooCommerce' ); - - if ( $type === 'add-new-user' ) { - ?> - - - - - -
            - - -
            - - - - -
            -
            - is_wpcom_platform() ) { - return; - } - - if ( $type === 'add-new-user' ) { - ?> - - - - - -
            - - -
            - - - - -
            -
            - - - - - - -
            - - -
            - 500 - ) { - $errors->add( - 'custom_email_message', - wp_kses( - __( 'Error: The custom message is too long. Please keep it under 500 characters.', 'jetpack-connection' ), - array( - 'strong' => array(), - ) - ) - ); - } - - $site_id = Manager::get_site_id( true ); - if ( ! $site_id ) { - $errors->add( - 'invalid_site_id', - wp_kses( - __( 'Error: Invalid site ID.', 'jetpack-connection' ), - array( - 'strong' => array(), - ) - ) - ); - } - - // Bail if there are any errors. - if ( $errors->has_errors() ) { - return $errors; - } - - $new_user_request = array( - 'email_or_username' => sanitize_email( $user->user_email ), - 'role' => sanitize_key( $user->role ), - ); - - if ( - isset( $_POST['custom_email_message'] ) - && strlen( sanitize_text_field( wp_unslash( $_POST['custom_email_message'] ) ) ) > 0 - ) { - $new_user_request['message'] = sanitize_text_field( wp_unslash( $_POST['custom_email_message'] ) ); - } - - if ( isset( $_POST['user_external_contractor'] ) ) { - $new_user_request['is_external'] = true; - } - - $response = Client::wpcom_json_api_request_as_user( - sprintf( - '/sites/%d/invites/new', - (int) $site_id - ), - '2', // Api version - array( - 'method' => 'POST', - ), - array( - 'invitees' => array( $new_user_request ), - ) - ); - - $event_name = 'sso_new_user_invite_sent'; - $custom_message_sent = isset( $new_user_request['message'] ) ? 'true' : 'false'; - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $errors->add( - 'invitation_not_sent', - wp_kses( - __( 'Error: The user invitation email could not be sent, the user account was not created.', 'jetpack-connection' ), - array( - 'strong' => array(), - ) - ) - ); - self::$tracking->record_user_event( - $event_name, - array( - 'success' => 'false', - 'error' => wp_remote_retrieve_body( $response ), // Get as much information as possible. - ) - ); - } else { - self::$tracking->record_user_event( - $event_name, - array( - 'success' => 'true', - 'custom_message_sent' => $custom_message_sent, - ) - ); - } - - return $errors; - } - - /** - * Deprecated method. Adds a column in the user admin table to display user connection status and actions. - * - * @param array $columns User list table columns. - * @return array - * @deprecated 6.5.0 - */ - public function jetpack_user_connected_th( $columns ) { - _deprecated_function( __METHOD__, 'package-6.5.0' ); - return $columns; - } - - /** - * Executed when our WP_User_Query instance is set, and we don't have cached invites. - * This function uses the user emails and the 'are-users-invited' endpoint to build the cache. - * - * @return void - */ - private static function rebuild_invite_cache() { - $blog_id = Manager::get_site_id( true ); - - if ( self::$cached_invites === null && self::$user_search !== null ) { - - self::$cached_invites = array(); - - $results = self::$user_search->get_results(); - - $user_emails = array_reduce( - $results, - function ( $current, $item ) { - if ( ! ( new Manager() )->is_user_connected( $item->ID ) ) { - $current[] = rawurlencode( $item->user_email ); - } else { - self::$cached_invites[] = array( - 'email_or_username' => $item->user_email, - 'invited' => false, - 'invite_code' => '', - ); - } - return $current; - }, - array() - ); - - if ( ! empty( $user_emails ) ) { - $url = '/sites/' . $blog_id . '/invites/are-users-invited'; - - $response = Client::wpcom_json_api_request_as_user( - $url, - 'v2', - array( - 'method' => 'POST', - ), - array( 'users' => $user_emails ), - 'wpcom' - ); - - if ( 200 === wp_remote_retrieve_response_code( $response ) ) { - $body = json_decode( $response['body'], true ); - - // ensure array_merge happens with the right parameters - if ( empty( $body ) ) { - $body = array(); - } - - self::$cached_invites = array_merge( self::$cached_invites, $body ); - } - } - } - } - - /** - * Check if there is cached invite for a user email. - * - * @access private - * @static - * - * @param string $email The user email. - * - * @return array|void Returns the cached invite if found. - */ - public static function get_pending_cached_wpcom_invite( $email ) { - if ( self::$cached_invites === null ) { - self::rebuild_invite_cache(); - } - - if ( ! empty( self::$cached_invites ) && is_array( self::$cached_invites ) ) { - $index = array_search( $email, array_column( self::$cached_invites, 'email_or_username' ), true ); - if ( $index !== false ) { - return self::$cached_invites[ $index ]; - } - } - } - - /** - * Check if a given user is invited to the site. - * - * @access private - * @static - * @param int $user_id The user ID. - * - * @return false|string returns the user invite code if the user is invited, false otherwise. - */ - private static function has_pending_wpcom_invite( $user_id ) { - $blog_id = Manager::get_site_id( true ); - $user = get_user_by( 'id', $user_id ); - $cached_invite = self::get_pending_cached_wpcom_invite( $user->user_email ); - - if ( $cached_invite ) { - return $cached_invite['invite_code']; - } - - $url = '/sites/' . $blog_id . '/invites/is-invited'; - $url = add_query_arg( - array( - 'email_or_username' => rawurlencode( $user->user_email ), - ), - $url - ); - $response = Client::wpcom_json_api_request_as_user( - $url, - 'v2', - array(), - null, - 'wpcom' - ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - return false; - } - - $body_response = wp_remote_retrieve_body( $response ); - if ( empty( $body_response ) ) { - return false; - } - - $body = json_decode( $body_response, true ); - if ( ! empty( $body['invite_code'] ) ) { - return $body['invite_code']; - } - - return false; - } - - /** - * Delete an external contributor from the site. - * - * @access private - * @static - * @param int $user_id The user ID. - * - * @return bool Returns true if the user was successfully deleted, false otherwise. - */ - private static function delete_external_contributor( $user_id ) { - $blog_id = Manager::get_site_id( true ); - $url = '/sites/' . $blog_id . '/external-contributors/remove'; - $response = Client::wpcom_json_api_request_as_user( - $url, - 'v2', - array( - 'method' => 'POST', - ), - array( - 'user_id' => $user_id, - ), - 'wpcom' - ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - return false; - } - - return true; - } - - /** - * Show Jetpack SSO user connection status. - * - * @param string $val HTML for the column. - * @param string $col User list table column. - * @param int $user_id User ID. - * @return string Modified column content. - */ - public function jetpack_show_connection_status( $val, $col, $user_id ) { - if ( 'user_jetpack' !== $col ) { - return $val; - } - - // Get base connection status from parent - $connection_status = parent::render_connection_column( '', $col, $user_id ); - - // If user is not connected, check for pending invite - if ( ! $connection_status ) { - $has_pending_invite = self::has_pending_wpcom_invite( $user_id ); - if ( $has_pending_invite ) { - return sprintf( - '%2$s', - esc_attr__( 'This user didn’t accept the invitation to join this site yet.', 'jetpack-connection' ), - esc_html__( 'Pending invite', 'jetpack-connection' ) - ); - } - - // Show invite button for non-connected users - $nonce = wp_create_nonce( 'jetpack-sso-invite-user' ); - return sprintf( - ' - %2$s - - %3$s - - ', - add_query_arg( - array( - 'user_id' => $user_id, - 'invite_nonce' => $nonce, - 'action' => 'jetpack_invite_user_to_wpcom', - ), - admin_url( 'admin-post.php' ) - ), - esc_html__( 'Send invite', 'jetpack-connection' ), - esc_attr__( 'This user doesn’t have a Jetpack SSO connection to WordPress.com. Invite them to the site to increase security and improve their experience.', 'jetpack-connection' ), - esc_attr__( 'Tooltip', 'jetpack-connection' ) - ); - } - - return $connection_status; - } - - /** - * Creates error notices and redirects the user to the previous page. - * - * @param array $query_params - query parameters added to redirection URL. - * @phan-suppress PhanPluginNeverReturnMethod - */ - public function create_error_notice_and_redirect( $query_params ) { - $ref = wp_get_referer(); - if ( empty( $ref ) ) { - $ref = network_admin_url( 'users.php' ); - } - - $url = add_query_arg( - $query_params, - $ref - ); - wp_safe_redirect( $url ); - exit; - } - - /** - * Style the Jetpack user rows and columns. - */ - public function jetpack_user_table_styles() { - ?> - - 'defer', - 'in_footer' => true, - 'enqueue' => true, - 'version' => Package_Version::PACKAGE_VERSION, - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-admin-create-user.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-admin-create-user.css deleted file mode 100644 index 176fb8ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-admin-create-user.css +++ /dev/null @@ -1,21 +0,0 @@ -.jetpack-sso-admin-create-user-invite-message { - width: 550px; -} - -.jetpack-sso-admin-create-user-invite-message-link-sso { - text-decoration: none; -} - -#createuser .form-field textarea { - width: 25em; -} - -#createuser .form-field [type=checkbox] { - width: 1rem; -} - -#custom_email_message_description { - max-width: 25rem; - color: #646970; - font-size: 12px; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-admin-create-user.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-admin-create-user.js deleted file mode 100644 index 0c8449c7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-admin-create-user.js +++ /dev/null @@ -1,45 +0,0 @@ -document.addEventListener( 'DOMContentLoaded', function () { - const sendUserNotificationCheckbox = document.getElementById( 'send_user_notification' ); - const userExternalContractorCheckbox = document.getElementById( 'user_external_contractor' ); - const inviteUserWpcomCheckbox = document.getElementById( 'invite_user_wpcom' ); - const customEmailMessageBlock = document.getElementById( 'custom_email_message_block' ); - - if ( inviteUserWpcomCheckbox && sendUserNotificationCheckbox && customEmailMessageBlock ) { - // Toggle Send User Notification checkbox enabled/disabled based on Invite User checkbox - // Enable External Contractor checkbox if Invite User checkbox is checked - // Show/hide the external email message field. - inviteUserWpcomCheckbox.addEventListener( 'change', function () { - sendUserNotificationCheckbox.disabled = inviteUserWpcomCheckbox.checked; - if ( inviteUserWpcomCheckbox.checked ) { - sendUserNotificationCheckbox.checked = false; - if ( userExternalContractorCheckbox ) { - userExternalContractorCheckbox.disabled = false; - } - customEmailMessageBlock.style.display = 'table'; - } else { - if ( userExternalContractorCheckbox ) { - userExternalContractorCheckbox.disabled = true; - userExternalContractorCheckbox.checked = false; - } - customEmailMessageBlock.style.display = 'none'; - } - } ); - - // On load, disable Send User Notification checkbox - // and show the custom email message if Invite User checkbox is checked - if ( inviteUserWpcomCheckbox.checked ) { - sendUserNotificationCheckbox.disabled = true; - sendUserNotificationCheckbox.checked = false; - customEmailMessageBlock.style.display = 'table'; - } - - // On load, disable External Contractor checkbox - // and hide the custom email message if Invite User checkbox is unchecked - if ( ! inviteUserWpcomCheckbox.checked ) { - if ( userExternalContractorCheckbox ) { - userExternalContractorCheckbox.disabled = true; - } - customEmailMessageBlock.style.display = 'none'; - } - } -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-login.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-login.css deleted file mode 100644 index db2b261e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-login.css +++ /dev/null @@ -1,164 +0,0 @@ -#loginform { - /* We set !important because sometimes static is added inline */ - position: relative !important; - padding-bottom: 92px; -} - -.jetpack-sso-repositioned #loginform { - padding-bottom: 26px; -} - -#loginform #jetpack-sso-wrap, -#loginform #jetpack-sso-wrap * { - box-sizing: border-box; -} - - -#jetpack-sso-wrap__action, -#jetpack-sso-wrap__user { - display: none; -} - -.jetpack-sso-form-display #jetpack-sso-wrap__action, -.jetpack-sso-form-display #jetpack-sso-wrap__user { - display: block; -} - -#jetpack-sso-wrap { - position: absolute; - bottom: 20px; - padding: 0 24px; - margin-left: -24px; - margin-right: -24px; - width: 100%; -} - -.jetpack-sso-repositioned #jetpack-sso-wrap { - position: relative; - bottom: auto; - padding: 0; - margin-top: 16px; - margin-left: 0; - margin-right: 0; -} - -.jetpack-sso-form-display #jetpack-sso-wrap { - position: relative; - bottom: auto; - padding: 0; - margin-top: 0; - margin-left: 0; - margin-right: 0; -} - -#loginform #jetpack-sso-wrap p { - color: #777777; - margin-bottom: 16px; -} - -#jetpack-sso-wrap a { - display: block; - width: 100%; - text-align: center; - text-decoration: none; -} - -#jetpack-sso-wrap .jetpack-sso-toggle.wpcom { - display: none; -} - -.jetpack-sso-form-display #jetpack-sso-wrap .jetpack-sso-toggle.wpcom { - display: block; -} - - -.jetpack-sso-form-display #jetpack-sso-wrap .jetpack-sso-toggle.default { - display: none; -} - - -.jetpack-sso-form-display #loginform>p, -.jetpack-sso-form-display #loginform>div { - display: none; -} - -.jetpack-sso-form-display #loginform #jetpack-sso-wrap { - display: block; -} - -.jetpack-sso-form-display #loginform { - padding: 26px 24px; -} - -.jetpack-sso-or { - margin-bottom: 16px; - position: relative; - text-align: center; -} - -.jetpack-sso-or:before { - background: #dcdcde; - content: ''; - height: 1px; - position: absolute; - left: 0; - top: 50%; - width: 100%; -} - -.jetpack-sso-or span { - background: #fff; - color: #777; - position: relative; - padding: 0 8px; - text-transform: uppercase -} - -#jetpack-sso-wrap .button { - display: flex; - justify-content: center; - align-items: center; - height: 36px; - margin-bottom: 16px; - width: 100%; -} - -#jetpack-sso-wrap .button .genericon-wordpress { - font-size: 24px; - margin-right: 4px; -} - -#jetpack-sso-wrap__user img { - border-radius: 50%; - display: block; - margin: 0 auto 16px; -} - -#jetpack-sso-wrap__user h2 { - font-size: 21px; - font-weight: 300; - margin-bottom: 16px; - text-align: center; -} - -#jetpack-sso-wrap__user h2 span { - font-weight: bold; -} - -.jetpack-sso-wrap__reauth { - margin-bottom: 16px; -} - -.jetpack-sso-form-display #nav { - display: none; -} - -.jetpack-sso-form-display #backtoblog { - margin: 24px 0 0; -} - -.jetpack-sso-clear:after { - content: ""; - display: table; - clear: both; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-login.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-login.js deleted file mode 100644 index 980741be..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-login.js +++ /dev/null @@ -1,27 +0,0 @@ -document.addEventListener( 'DOMContentLoaded', () => { - const body = document.querySelector( 'body' ), - toggleSSO = document.querySelector( '.jetpack-sso-toggle' ), - userLogin = document.getElementById( 'user_login' ), - userPassword = document.getElementById( 'user_pass' ), - ssoWrap = document.getElementById( 'jetpack-sso-wrap' ), - loginForm = document.getElementById( 'loginform' ), - overflow = document.createElement( 'div' ); - - overflow.className = 'jetpack-sso-clear'; - - loginForm.appendChild( overflow ); - overflow.appendChild( document.querySelector( 'p.forgetmenot' ) ); - overflow.appendChild( document.querySelector( 'p.submit' ) ); - - loginForm.appendChild( ssoWrap ); - body.classList.add( 'jetpack-sso-repositioned' ); - - toggleSSO.addEventListener( 'click', e => { - e.preventDefault(); - body.classList.toggle( 'jetpack-sso-form-display' ); - if ( ! body.classList.contains( 'jetpack-sso-form-display' ) ) { - userLogin.focus(); - userPassword.disabled = false; - } - } ); -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-users.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-users.js deleted file mode 100644 index 778eab06..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/sso/jetpack-sso-users.js +++ /dev/null @@ -1,64 +0,0 @@ -document.addEventListener( 'DOMContentLoaded', function () { - document - .querySelectorAll( '.jetpack-sso-invitation-tooltip-icon:not(.sso-disconnected-user)' ) - .forEach( function ( tooltip ) { - tooltip.innerHTML += ' [?]'; - - const tooltipTextbox = document.createElement( 'span' ); - tooltipTextbox.classList.add( 'jetpack-sso-invitation-tooltip' ); - - const tooltipString = window.Jetpack_SSOTooltip.tooltipString; - tooltipTextbox.innerHTML += tooltipString; - - tooltip.addEventListener( 'mouseenter', appendTooltip ); - tooltip.addEventListener( 'focus', appendTooltip ); - tooltip.addEventListener( 'mouseleave', removeTooltip ); - tooltip.addEventListener( 'blur', removeTooltip ); - - /** - * Display the tooltip textbox. - */ - function appendTooltip() { - tooltip.appendChild( tooltipTextbox ); - tooltipTextbox.style.display = 'block'; - } - - /** - * Remove the tooltip textbox. - */ - function removeTooltip() { - // Only remove tooltip if the element isn't currently active. - if ( tooltip.ownerDocument.activeElement === tooltip ) { - return; - } - tooltip.removeChild( tooltipTextbox ); - } - } ); - document - .querySelectorAll( '.jetpack-sso-invitation-tooltip-icon:not(.jetpack-sso-status-column)' ) - .forEach( function ( tooltip ) { - tooltip.addEventListener( 'mouseenter', appendSSOInvitationTooltip ); - tooltip.addEventListener( 'focus', appendSSOInvitationTooltip ); - tooltip.addEventListener( 'mouseleave', removeSSOInvitationTooltip ); - tooltip.addEventListener( 'blur', removeSSOInvitationTooltip ); - } ); - - /** - * Display the SSO invitation tooltip textbox. - */ - function appendSSOInvitationTooltip() { - this.querySelector( '.jetpack-sso-invitation-tooltip' ).style.display = 'block'; - } - - /** - * Remove the SSO invitation tooltip textbox. - * - * @param {Event} event - Triggering event. - */ - function removeSSOInvitationTooltip( event ) { - if ( event.target.ownerDocument.activeElement === event.target ) { - return; - } - this.querySelector( '.jetpack-sso-invitation-tooltip' ).style.display = 'none'; - } -} ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/traits/trait-wpcom-rest-api-proxy-request.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/traits/trait-wpcom-rest-api-proxy-request.php deleted file mode 100644 index f6b38cf8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/traits/trait-wpcom-rest-api-proxy-request.php +++ /dev/null @@ -1,151 +0,0 @@ -rest_base, '/' ) ) . ( $path ? '/' . rawurldecode( ltrim( $path, '/' ) ) : '' ); - $query_params = $request->get_query_params(); - $manager = new Manager(); - - /* - * A rest_route parameter can be added when using plain permalinks. - * It is not necessary to pass them to WordPress.com, - * and may even cause issues with some endpoints. - * Let's remove it. - */ - if ( isset( $query_params['rest_route'] ) ) { - unset( $query_params['rest_route'] ); - } - $api_url = add_query_arg( $query_params, $path ); - - $request_options = array_replace_recursive( - array( - 'headers' => array( - 'Content-Type' => 'application/json', - 'X-Forwarded-For' => ( new Visitor() )->get_ip( true ), - ), - 'method' => $request->get_method(), - ), - $request_options - ); - - // If no body is present, passing it as $request->get_body() will cause an error. - $body = $request->get_body() ? $request->get_body() : null; - - $response = new WP_Error( - 'rest_unauthorized', - __( 'Please connect your user account to WordPress.com', 'jetpack-connection' ), - array( 'status' => rest_authorization_required_code() ) - ); - - if ( 'user' === $context ) { - if ( ! $manager->is_user_connected() ) { - if ( false === $allow_fallback_to_blog ) { - return $response; - } - - $context = 'blog'; - } else { - $response = Client::wpcom_json_api_request_as_user( $api_url, $this->version, $request_options, $body, $this->base_api_path ); - } - } - - if ( 'blog' === $context ) { - if ( ! $manager->is_connected() ) { - return $response; - } - - $response = Client::wpcom_json_api_request_as_blog( $api_url, $this->version, $request_options, $body, $this->base_api_path ); - } - - if ( is_wp_error( $response ) ) { - return $response; - } - - $response_status = wp_remote_retrieve_response_code( $response ); - $response_body = json_decode( wp_remote_retrieve_body( $response ), true ); - - if ( $response_status >= 400 ) { - $code = $response_body['code'] ?? 'unknown_error'; - $message = $response_body['message'] ?? __( 'An unknown error occurred.', 'jetpack-connection' ); - - return new WP_Error( $code, $message, array( 'status' => $response_status ) ); - } - - return $response_body; - } - - /** - * Proxy request to wpcom servers on behalf of a user. - * - * @param WP_REST_Request $request Request to proxy. - * @param string $path Path to append to the rest base. - * @param array $request_options Request options to pass to wp_remote_request. - * - * @return mixed|WP_Error Response from wpcom servers or an error. - */ - public function proxy_request_to_wpcom_as_user( $request, $path = '', $request_options = array() ) { - return $this->proxy_request_to_wpcom( $request, $path, 'user', false, $request_options ); - } - - /** - * Proxy request to wpcom servers using the Site-level Connection (blog token). - * - * @param WP_REST_Request $request Request to proxy. - * @param string $path Path to append to the rest base. - * @param array $request_options Request options to pass to wp_remote_request. - * - * @return mixed|WP_Error Response from wpcom servers or an error. - */ - public function proxy_request_to_wpcom_as_blog( $request, $path = '', $request_options = array() ) { - return $this->proxy_request_to_wpcom( $request, $path, 'blog', false, $request_options ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php deleted file mode 100644 index ddd24e4b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php +++ /dev/null @@ -1,251 +0,0 @@ -connection = $connection; - } - - /** - * Handle the webhook - * - * This method implements what's in Jetpack::admin_page_load when the Jetpack plugin is not present - * - * @return never - */ - public function handle() { - - add_filter( - 'allowed_redirect_hosts', - function ( $domains ) { - $domains[] = 'jetpack.com'; - $domains[] = 'jetpack.wordpress.com'; - $domains[] = 'wordpress.com'; - // Calypso envs. - $domains[] = 'calypso.localhost'; - $domains[] = 'wpcalypso.wordpress.com'; - $domains[] = 'horizon.wordpress.com'; - return array_unique( $domains ); - } - ); - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $dest_url = empty( $_GET['dest_url'] ) ? null : esc_url_raw( wp_unslash( $_GET['dest_url'] ) ); - - if ( ! $dest_url || ( 0 === stripos( $dest_url, 'https://jetpack.com/' ) && 0 === stripos( $dest_url, 'https://wordpress.com/' ) ) ) { - // The destination URL is missing or invalid, nothing to do here. - exit( 0 ); - } - - // The user is either already connected, or finished the connection process. - if ( $this->connection->is_connected() && $this->connection->is_user_connected() ) { - if ( class_exists( '\Automattic\Jetpack\Licensing' ) && method_exists( '\Automattic\Jetpack\Licensing', 'handle_user_connected_redirect' ) ) { - Licensing::instance()->handle_user_connected_redirect( $dest_url ); - } - - wp_safe_redirect( $dest_url ); - exit( 0 ); - } elseif ( ! empty( $_GET['done'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended - // The user decided not to proceed with setting up the connection. - - wp_safe_redirect( Admin_Menu::get_top_level_menu_item_url() ); - exit( 0 ); - } - - $redirect_args = array( - 'page' => 'jetpack', - 'action' => 'authorize_redirect', - 'dest_url' => rawurlencode( $dest_url ), - 'done' => '1', - ); - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! empty( $_GET['from'] ) && 'jetpack_site_only_checkout' === $_GET['from'] ) { - $redirect_args['from'] = 'jetpack_site_only_checkout'; - } - - wp_safe_redirect( $this->build_authorize_url( add_query_arg( $redirect_args, admin_url( 'admin.php' ) ) ) ); - exit( 0 ); - } - - /** - * Create the Jetpack authorization URL. - * - * @since 2.7.6 Added optional $from and $raw parameters. - * @since 6.8.0 Added optional $provider and $provider_args parameters. - * - * @param bool|string $redirect URL to redirect to. - * @param bool|string $from If not false, adds 'from=$from' param to the connect URL. - * @param bool $raw If true, URL will not be escaped. - * @param string|null $provider The authentication provider (google, github, apple, link). - * @param array|null $provider_args Additional provider-specific arguments. - * - * @todo Update default value for redirect since the called function expects a string. - * - * @return mixed|void - */ - public function build_authorize_url( $redirect = false, $from = false, $raw = false, $provider = null, $provider_args = null ) { - - add_filter( 'jetpack_connect_request_body', array( __CLASS__, 'filter_connect_request_body' ) ); - add_filter( 'jetpack_connect_redirect_url', array( __CLASS__, 'filter_connect_redirect_url' ) ); - - $url = $this->connection->get_authorization_url( wp_get_current_user(), $redirect, $from, $raw ); - - // If a provider is specified, modify the URL to use the provider-specific endpoint - if ( $provider && in_array( $provider, array( 'google', 'github', 'apple', 'link' ), true ) ) { - // Parse the URL to modify it safely - $url_parts = wp_parse_url( $url ); - - if ( ! empty( $url_parts['host'] ) && ! empty( $url_parts['path'] ) ) { - // Build the new URL using wordpress.com as the host - $url_parts['host'] = 'wordpress.com'; - $url_parts['path'] = '/log-in/jetpack/' . $provider; - - // Preserve the query parameters - $query_params = array(); - if ( ! empty( $url_parts['query'] ) ) { - parse_str( $url_parts['query'], $query_params ); - } - - // Add magic link specific parameters if provider is 'link' - if ( 'link' === $provider && is_array( $provider_args ) && ! empty( $provider_args['email_address'] ) ) { - $query_params['email_address'] = $provider_args['email_address']; - // Add flag to trigger magic link flow - $query_params['auto_trigger'] = '1'; - } - - // URL encode all parameter values - $query_params = array_map( 'rawurlencode', $query_params ); - - // Rebuild the URL - $url = 'https://' . $url_parts['host'] . $url_parts['path']; - if ( ! empty( $query_params ) ) { - $url = add_query_arg( $query_params, $url ); - } - } - } - - remove_filter( 'jetpack_connect_request_body', array( __CLASS__, 'filter_connect_request_body' ) ); - remove_filter( 'jetpack_connect_redirect_url', array( __CLASS__, 'filter_connect_redirect_url' ) ); - - /** - * Filter the URL used when authorizing a user to a WordPress.com account. - * - * @since jetpack-8.9.0 - * @since 2.7.6 Added $raw parameter. - * @since 6.8.0 Added $provider and $provider_args parameters. - * - * @param string $url Connection URL. - * @param bool $raw If true, URL will not be escaped. - * @param string|null $provider The authentication provider if specified. - * @param array|null $provider_args Additional provider-specific arguments. - */ - return apply_filters( 'jetpack_build_authorize_url', $url, $raw, $provider, $provider_args ); - } - - /** - * Filters the redirection URL that is used for connect requests. The redirect - * URL should return the user back to the My Jetpack page. - * - * @param string $redirect the default redirect URL used by the package. - * @return string the modified URL. - */ - public static function filter_connect_redirect_url( $redirect ) { - $jetpack_admin_page = esc_url_raw( admin_url( 'admin.php?page=my-jetpack' ) ); - $redirect = $redirect - ? wp_validate_redirect( esc_url_raw( $redirect ), $jetpack_admin_page ) - : $jetpack_admin_page; - - if ( - class_exists( 'Jetpack_Network' ) - && isset( $_REQUEST['is_multisite'] ) // phpcs:ignore WordPress.Security.NonceVerification.Recommended - ) { - $redirect = Jetpack_Network::init()->get_url( 'network_admin_page' ); - } - - return $redirect; - } - - /** - * Filters the connection URL parameter array. - * - * @param array $args default URL parameters used by the package. - * @return array the modified URL arguments array. - */ - public static function filter_connect_request_body( $args ) { - if ( - Constants::is_defined( 'JETPACK__GLOTPRESS_LOCALES_PATH' ) - && include_once Constants::get_constant( 'JETPACK__GLOTPRESS_LOCALES_PATH' ) - ) { - $gp_locale = GP_Locales::by_field( 'wp_locale', get_locale() ); - $args['locale'] = isset( $gp_locale ) && isset( $gp_locale->slug ) - ? $gp_locale->slug - : ''; - } - - $tracking = new Tracking(); - $tracks_identity = $tracking->tracks_get_identity( $args['state'] ); - - $args = array_merge( - $args, - array( - '_ui' => $tracks_identity['_ui'], - '_ut' => $tracks_identity['_ut'], - ) - ); - - $calypso_env = ( new Host() )->get_calypso_env(); - - if ( ! empty( $calypso_env ) ) { - $args['calypso_env'] = $calypso_env; - } - - return $args; - } - - /** - * Return Calypso environment value; used for developing Jetpack and pairing - * it with different Calypso enrionments, such as localhost. - * Copied from Jetpack class. - * - * @deprecated 2.7.6 - * - * @since 1.37.1 - * - * @return string Calypso environment - */ - public static function get_calypso_env() { - _deprecated_function( __METHOD__, '2.7.6', 'Automattic\\Jetpack\\Status\\Host::get_calypso_env' ); - - return ( new Host() )->get_calypso_env(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/CHANGELOG.md deleted file mode 100644 index a80b9126..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/CHANGELOG.md +++ /dev/null @@ -1,249 +0,0 @@ -# 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). - -## [3.0.5] - 2025-03-21 -### Changed -- Internal updates. - -## [3.0.4] - 2025-03-12 -### Changed -- Internal updates. - -## [3.0.3] - 2025-03-05 -### Changed -- Internal updates. - -## [3.0.2] - 2025-02-24 -### Changed -- Update dependencies. - -## [3.0.1] - 2024-11-25 -### Changed -- Updated package dependencies. [#40258] - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.0.5] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.0.4] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [2.0.3] - 2024-05-29 -### Fixed -- Fix phpdoc type on `Constants::set_constant()` value parameter. [#37606] - -## [2.0.2] - 2024-04-30 -### Changed -- Internal updates. - -## [2.0.1] - 2024-03-12 -### Changed -- Internal updates. - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.6.23] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.6.22] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.6.21] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.6.20] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.6.19] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.6.18] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.6.17] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.6.16] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.6.15] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.6.14] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.6.13] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.6.12] - 2021-11-22 -### Changed -- Updated package dependencies - -## [1.6.11] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.6.10] - 2021-10-26 -### Fixed -- Updated is_true docblock to be more accurate. - -## [1.6.9] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.6.8] - 2021-10-06 -### Changed -- Updated package dependencies - -## [1.6.7] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.6.6] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- Updated versions in annotations - -## [1.6.5] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.6.4] - 2021-04-08 -### Changed -- Packaging and build changes, no change to the package itself. - -## [1.6.3] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.6.2] - 2021-02-05 - -- CI: Make tests more generic - -## [1.6.1] - 2021-01-19 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.6.0] - 2020-12-14 - -- Update dependency brain/monkey to v2.6.0 -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.5.1] - 2020-10-28 - -- Updated PHPCS: Packages and Debugger - -## [1.5.0] - 2020-08-13 - -- CI: Try collect js coverage -- Docker: Add package testing shortcut - -## [1.4.0] - 2020-07-01 - -- Package Unit tests: update test file names to make sure they runs in Travis - -## [1.3.0] - 2020-06-22 - -- PHPCS: Clean up the packages - -## [1.2.0] - 2020-04-15 - -- Use jp.com redirect in all links -- Connection: add a filter for setting Jetpack api constants - -## [1.1.3] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.1.2] - 2019-10-28 - -- Packages: Add gitattributes files to all packages that need th… - -## [1.1.1] - 2019-09-20 - -- Docs: Unify usage of @package phpdoc tags - -## [1.1.0] - 2019-09-14 - -## 1.0.0 - 2019-07-09 - -- Packages: Finish the constants package - -[3.0.5]: https://github.com/Automattic/jetpack-constants/compare/v3.0.4...v3.0.5 -[3.0.4]: https://github.com/Automattic/jetpack-constants/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-constants/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-constants/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-constants/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-constants/compare/v2.0.5...v3.0.0 -[2.0.5]: https://github.com/Automattic/jetpack-constants/compare/v2.0.4...v2.0.5 -[2.0.4]: https://github.com/Automattic/jetpack-constants/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-constants/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-constants/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-constants/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-constants/compare/v1.6.23...v2.0.0 -[1.6.23]: https://github.com/Automattic/jetpack-constants/compare/v1.6.22...v1.6.23 -[1.6.22]: https://github.com/Automattic/jetpack-constants/compare/v1.6.21...v1.6.22 -[1.6.21]: https://github.com/Automattic/jetpack-constants/compare/v1.6.20...v1.6.21 -[1.6.20]: https://github.com/Automattic/jetpack-constants/compare/v1.6.19...v1.6.20 -[1.6.19]: https://github.com/Automattic/jetpack-constants/compare/v1.6.18...v1.6.19 -[1.6.18]: https://github.com/Automattic/jetpack-constants/compare/v1.6.17...v1.6.18 -[1.6.17]: https://github.com/Automattic/jetpack-constants/compare/v1.6.16...v1.6.17 -[1.6.16]: https://github.com/Automattic/jetpack-constants/compare/v1.6.15...v1.6.16 -[1.6.15]: https://github.com/Automattic/jetpack-constants/compare/v1.6.14...v1.6.15 -[1.6.14]: https://github.com/Automattic/jetpack-constants/compare/v1.6.13...v1.6.14 -[1.6.13]: https://github.com/Automattic/jetpack-constants/compare/v1.6.12...v1.6.13 -[1.6.12]: https://github.com/Automattic/jetpack-constants/compare/v1.6.11...v1.6.12 -[1.6.11]: https://github.com/Automattic/jetpack-constants/compare/v1.6.10...v1.6.11 -[1.6.10]: https://github.com/Automattic/jetpack-constants/compare/v1.6.9...v1.6.10 -[1.6.9]: https://github.com/Automattic/jetpack-constants/compare/v1.6.8...v1.6.9 -[1.6.8]: https://github.com/Automattic/jetpack-constants/compare/v1.6.7...v1.6.8 -[1.6.7]: https://github.com/Automattic/jetpack-constants/compare/v1.6.6...v1.6.7 -[1.6.6]: https://github.com/Automattic/jetpack-constants/compare/v1.6.5...v1.6.6 -[1.6.5]: https://github.com/Automattic/jetpack-constants/compare/v1.6.4...v1.6.5 -[1.6.4]: https://github.com/Automattic/jetpack-constants/compare/v1.6.3...v1.6.4 -[1.6.3]: https://github.com/Automattic/jetpack-constants/compare/v1.6.2...v1.6.3 -[1.6.2]: https://github.com/Automattic/jetpack-constants/compare/v1.6.1...v1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-constants/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-constants/compare/v1.5.1...v1.6.0 -[1.5.1]: https://github.com/Automattic/jetpack-constants/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-constants/compare/v1.4.0...v1.5.0 -[1.4.0]: https://github.com/Automattic/jetpack-constants/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-constants/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-constants/compare/v1.1.3...v1.2.0 -[1.1.3]: https://github.com/Automattic/jetpack-constants/compare/v1.1.2...v1.1.3 -[1.1.2]: https://github.com/Automattic/jetpack-constants/compare/v1.1.1...v1.1.2 -[1.1.1]: https://github.com/Automattic/jetpack-constants/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-constants/compare/v1.0.0...v1.1.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/composer.json deleted file mode 100644 index 278c4369..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/composer.json +++ /dev/null @@ -1,46 +0,0 @@ -{ - "name": "automattic/jetpack-constants", - "description": "A wrapper for defining constants in a more testable way.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-constants", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-constants/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php deleted file mode 100644 index 45768a94..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php +++ /dev/null @@ -1,124 +0,0 @@ -= 7.0. [#34192] - -## [1.5.1] - 2023-11-14 - -## [1.5.0] - 2023-11-13 -### Added -- Added 'cookieinformationscanner' and 'facebookexternalhit' to the bot user agent list. [#34026] - -## [1.4.27] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.4.26] - 2023-06-12 -### Fixed -- Catch PHP notice if User Agent is not available [#31279] - -## [1.4.25] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.4.24] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.4.23] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.4.22] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.4.21] - 2022-11-22 -### Added -- Add a guard in `functions.php` against being loaded twice from different copies of the package. [#27475] - -### Changed -- Updated package dependencies. [#27043] - -## [1.4.20] - 2022-11-07 -### Fixed -- Ensure that User_Agent is loaded in environments without autoload enabled. (e.g.: WordPress.com and Super Cache) [#27223] - -## [1.4.19] - 2022-10-25 -### Changed -- Update `wp_unslash` wrapper to possibly run on wpcom before WordPress is loaded. [#26971] - -## [1.4.18] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.4.17] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.4.16] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.4.15] - 2022-04-19 -### Changed -- PHPCS: Fix `WordPress.Security.ValidatedSanitizedInput` - -## [1.4.14] - 2022-03-29 -### Changed -- Microperformance: Use === null instead of is_null - -## [1.4.13] - 2022-02-09 -### Fixed -- Fixed some new PHPCS warnings. - -## [1.4.12] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.4.11] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.4.10] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.4.9] - 2021-11-16 -### Fixed -- Verify $_SERVER['HTTP_USER_AGENT'] exists before use. - -## [1.4.8] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.4.7] - 2021-10-19 -### Deprecated -- General: remove numerous long-deprecated functions. - -## [1.4.6] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.4.5] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.4.4] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.4.3] - 2021-08-31 -### Changed -- Run composer update on test-php command instead of phpunit. -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- Updated versions in annotations. - -## [1.4.2] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.4.1] - 2021-04-27 -### Changed -- Updated package dependencies. - -## [1.4.0] - 2021-03-30 -### Added -- Added Opera Desktop detection -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.3.2] - 2021-02-05 - -- CI: Make tests more generic - -## [1.3.1] - 2021-01-19 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.3.0] - 2020-12-09 - -- Codesniffer: Update mediawiki/mediawiki-codesniffer dependency -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.2.1] - 2020-11-10 - -- Improve PHP 8 compatibility -- Updated PHPCS: Packages and Debugger - -## [1.2.0] - 2020-10-19 - -- Replaced intval() with (int) as part of issue #17432. - -## [1.1.0] - 2020-08-13 - -- CI: Try collect js coverage - -## 1.0.0 - 2020-06-25 - -- Moving jetpack_is_mobile into a package - -[3.0.5]: https://github.com/Automattic/jetpack-device-detection/compare/v3.0.4...v3.0.5 -[3.0.4]: https://github.com/Automattic/jetpack-device-detection/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-device-detection/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-device-detection/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-device-detection/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.6...v3.0.0 -[2.1.6]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.5...v2.1.6 -[2.1.5]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.4...v2.1.5 -[2.1.4]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.3...v2.1.4 -[2.1.3]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.2...v2.1.3 -[2.1.2]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.1...v2.1.2 -[2.1.1]: https://github.com/Automattic/jetpack-device-detection/compare/v2.1.0...v2.1.1 -[2.1.0]: https://github.com/Automattic/jetpack-device-detection/compare/v2.0.1...v2.1.0 -[2.0.1]: https://github.com/Automattic/jetpack-device-detection/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.5.1...v2.0.0 -[1.5.1]: https://github.com/Automattic/jetpack-device-detection/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.27...v1.5.0 -[1.4.27]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.26...v1.4.27 -[1.4.26]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.25...v1.4.26 -[1.4.25]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.24...v1.4.25 -[1.4.24]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.23...v1.4.24 -[1.4.23]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.22...v1.4.23 -[1.4.22]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.21...v1.4.22 -[1.4.21]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.20...v1.4.21 -[1.4.20]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.19...v1.4.20 -[1.4.19]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.18...v1.4.19 -[1.4.18]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.17...v1.4.18 -[1.4.17]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.16...v1.4.17 -[1.4.16]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.15...v1.4.16 -[1.4.15]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.14...v1.4.15 -[1.4.14]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.13...v1.4.14 -[1.4.13]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.12...v1.4.13 -[1.4.12]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.11...v1.4.12 -[1.4.11]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.10...v1.4.11 -[1.4.10]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.9...v1.4.10 -[1.4.9]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.8...v1.4.9 -[1.4.8]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.7...v1.4.8 -[1.4.7]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.6...v1.4.7 -[1.4.6]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.5...v1.4.6 -[1.4.5]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.4...v1.4.5 -[1.4.4]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.3...v1.4.4 -[1.4.3]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.2...v1.4.3 -[1.4.2]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.1...v1.4.2 -[1.4.1]: https://github.com/Automattic/jetpack-device-detection/compare/v1.4.0...v1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.3.2...v1.4.0 -[1.3.2]: https://github.com/Automattic/jetpack-device-detection/compare/v1.3.1...v1.3.2 -[1.3.1]: https://github.com/Automattic/jetpack-device-detection/compare/v1.3.0...v1.3.1 -[1.3.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.2.1...v1.3.0 -[1.2.1]: https://github.com/Automattic/jetpack-device-detection/compare/v1.2.0...v1.2.1 -[1.2.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.1.0...v1.2.0 -[1.1.0]: https://github.com/Automattic/jetpack-device-detection/compare/v1.0.0...v1.1.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/composer.json deleted file mode 100644 index 96803d29..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/composer.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "name": "automattic/jetpack-device-detection", - "description": "A way to detect device types based on User-Agent header.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-device-detection", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-device-detection/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php deleted file mode 100644 index 62361d7e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php +++ /dev/null @@ -1,255 +0,0 @@ - (bool) Whether the current device is a mobile phone. - * 'is_smartphone' => (bool) Whether the current device is a smartphone. - * 'is_tablet' => (bool) Whether the current device is a tablet device. - * 'is_handheld' => (bool) Whether the current device is a handheld device. - * 'is_desktop' => (bool) Whether the current device is a laptop / desktop device. - * 'platform' => (string) Detected platform. - * 'is_phone_matched_ua' => (string) Matched UA. - * ); - */ - public static function get_info( $ua = '' ) { - // Return memoized result if available. - // phpcs:disable WordPress.Security.ValidatedSanitizedInput - $memo_key = ! empty( $ua ) ? $ua : ( $_SERVER['HTTP_USER_AGENT'] ?? '' ); - // Note: UA string used raw for compatibility reasons. - // No sanitization is needed as the value is never output or persisted, and is only used for memoization. - // phpcs:enable WordPress.Security.ValidatedSanitizedInput - if ( isset( self::$get_info_memo[ $memo_key ] ) ) { - return self::$get_info_memo[ $memo_key ]; - } - - $ua_info = new User_Agent_Info( $ua ); - - $info = array( - 'is_phone' => self::is_mobile( 'any', false, $ua_info ), - 'is_phone_matched_ua' => self::is_mobile( 'any', true, $ua_info ), - 'is_smartphone' => self::is_mobile( 'smart', false, $ua_info ), - 'is_tablet' => $ua_info->is_tablet(), - 'platform' => $ua_info->get_platform(), - 'desktop_platform' => $ua_info->get_desktop_platform(), - 'browser' => $ua_info->get_browser(), - ); - - $info['is_handheld'] = $info['is_phone'] || $info['is_tablet']; - $info['is_desktop'] = ! $info['is_handheld']; - - if ( function_exists( 'apply_filters' ) ) { - /** - * Filter the value of Device_Detection::get_info. - * - * @since 1.0.0 - * - * @param array $info Array of device information. - * @param string $ua User agent string passed to Device_Detection::get_info. - * @param User_Agent_Info $ua_info Instance of Automattic\Jetpack\Device_Detection\User_Agent_Info. - */ - $info = apply_filters( 'jetpack_device_detection_get_info', $info, $ua, $ua_info ); - } - - // Memoize the result. - self::$get_info_memo[ $memo_key ] = $info; - if ( count( self::$get_info_memo ) > self::$max_memo_size ) { - array_shift( self::$get_info_memo ); - } - - return $info; - } - - /** - * Detects phone devices. - * - * @param string $ua User-Agent string. - * - * @return bool - */ - public static function is_phone( $ua = '' ) { - $device_info = self::get_info( $ua ); - return true === $device_info['is_phone']; - } - - /** - * Detects smartphone devices. - * - * @param string $ua User-Agent string. - * - * @return bool - */ - public static function is_smartphone( $ua = '' ) { - $device_info = self::get_info( $ua ); - return true === $device_info['is_smartphone']; - } - - /** - * Detects tablet devices. - * - * @param string $ua User-Agent string. - * - * @return bool - */ - public static function is_tablet( $ua = '' ) { - $device_info = self::get_info( $ua ); - return true === $device_info['is_tablet']; - } - - /** - * Detects desktop devices. - * - * @param string $ua User-Agent string. - * - * @return bool - */ - public static function is_desktop( $ua = '' ) { - $device_info = self::get_info( $ua ); - return true === $device_info['is_desktop']; - } - - /** - * Detects handheld (i.e. phone + tablet) devices. - * - * @param string $ua User-Agent string. - * - * @return bool - */ - public static function is_handheld( $ua = '' ) { - $device_info = self::get_info( $ua ); - return true === $device_info['is_handheld']; - } - - /** - * Determine if the current User Agent matches the passed $kind. - * - * @param string $kind Category of mobile device to check for. Either: any, dumb, smart. - * @param bool $return_matched_agent Boolean indicating if the UA should be returned. - * @param User_Agent_Info $ua_info Boolean indicating if the UA should be returned. - * - * @return bool|string Boolean indicating if current UA matches $kind. If `$return_matched_agent` is true, returns the UA string. - */ - private static function is_mobile( $kind, $return_matched_agent, $ua_info ) { - $kinds = array( - 'smart' => false, - 'dumb' => false, - 'any' => false, - ); - $first_run = true; - $matched_agent = ''; - - // If an invalid kind is passed in, reset it to default. - if ( ! isset( $kinds[ $kind ] ) ) { - $kind = 'any'; - } - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( filter_var( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) ); - if ( strpos( $agent, 'ipad' ) ) { - return false; - } - - // Remove Samsung Galaxy tablets (SCH-I800) from being mobile devices. - if ( strpos( $agent, 'sch-i800' ) ) { - return false; - } - - if ( $ua_info->is_android_tablet() && false === $ua_info->is_kindle_touch() ) { - return false; - } - - if ( $ua_info->is_blackberry_tablet() ) { - return false; - } - - if ( $first_run ) { - $first_run = false; - - // checks for iPhoneTier devices & RichCSS devices. - if ( $ua_info->isTierIphone() || $ua_info->isTierRichCSS() ) { - $kinds['smart'] = true; - $matched_agent = $ua_info->matched_agent; - } - - if ( ! $kinds['smart'] ) { - // if smart, we are not dumb so no need to check. - $dumb_agents = $ua_info->dumb_agents; - - foreach ( $dumb_agents as $dumb_agent ) { - if ( false !== strpos( $agent, $dumb_agent ) ) { - $kinds['dumb'] = true; - $matched_agent = $dumb_agent; - - break; - } - } - - if ( ! $kinds['dumb'] ) { - if ( isset( $_SERVER['HTTP_X_WAP_PROFILE'] ) ) { - $kinds['dumb'] = true; - $matched_agent = 'http_x_wap_profile'; - } elseif ( isset( $_SERVER['HTTP_ACCEPT'] ) && ( preg_match( '/wap\.|\.wap/i', $_SERVER['HTTP_ACCEPT'] ) || false !== strpos( strtolower( $_SERVER['HTTP_ACCEPT'] ), 'application/vnd.wap.xhtml+xml' ) ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- This is doing the validating. - $kinds['dumb'] = true; - $matched_agent = 'vnd.wap.xhtml+xml'; - } - } - } - - if ( $kinds['dumb'] || $kinds['smart'] ) { - $kinds['any'] = true; - } - } - - $value = $kinds[ $kind ]; - - if ( $return_matched_agent ) { - $value = $matched_agent; - } - return $value; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php deleted file mode 100644 index 96fb68cd..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php +++ /dev/null @@ -1,1755 +0,0 @@ -useragent = $ua; - } elseif ( ! empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - $this->useragent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This class is all about validating. - } - } - - /** - * This method detects the mobile User Agent name. - * - * @return string The matched User Agent name, false otherwise. - */ - public function get_mobile_user_agent_name() { - if ( static::is_chrome_for_iOS() ) { // Keep this check before the safari rule. - return 'chrome-for-ios'; - } elseif ( static::is_iphone_or_ipod( 'iphone-safari' ) ) { - return 'iphone'; - } elseif ( static::is_ipad( 'ipad-safari' ) ) { - return 'ipad'; - } elseif ( static::is_android_tablet() ) { // Keep this check before the android rule. - return 'android_tablet'; - } elseif ( static::is_android() ) { - return 'android'; - } elseif ( static::is_blackberry_10() ) { - return 'blackberry_10'; - } elseif ( static::is_blackbeberry() ) { - return 'blackberry'; - } elseif ( static::is_WindowsPhone7() ) { - return 'win7'; - } elseif ( static::is_windows_phone_8() ) { - return 'winphone8'; - } elseif ( static::is_opera_mini() ) { - return 'opera-mini'; - } elseif ( static::is_opera_mini_dumb() ) { - return 'opera-mini-dumb'; - } elseif ( static::is_opera_mobile() ) { - return 'opera-mobi'; - } elseif ( static::is_blackberry_tablet() ) { - return 'blackberry_tablet'; - } elseif ( static::is_kindle_fire() ) { - return 'kindle-fire'; - } elseif ( static::is_PalmWebOS() ) { - return 'webos'; - } elseif ( static::is_S60_OSSBrowser() ) { - return 'series60'; - } elseif ( static::is_firefox_os() ) { - return 'firefoxOS'; - } elseif ( static::is_firefox_mobile() ) { - return 'firefox_mobile'; - } elseif ( static::is_MaemoTablet() ) { - return 'maemo'; - } elseif ( static::is_MeeGo() ) { - return 'meego'; - } elseif ( static::is_TouchPad() ) { - return 'hp_tablet'; - } elseif ( static::is_facebook_for_iphone() ) { - return 'facebook-for-iphone'; - } elseif ( static::is_facebook_for_ipad() ) { - return 'facebook-for-ipad'; - } elseif ( static::is_twitter_for_iphone() ) { - return 'twitter-for-iphone'; - } elseif ( static::is_twitter_for_ipad() ) { - return 'twitter-for-ipad'; - } elseif ( static::is_wordpress_for_ios() ) { - return 'ios-app'; - } elseif ( static::is_iphone_or_ipod( 'iphone-not-safari' ) ) { - return 'iphone-unknown'; - } elseif ( static::is_ipad( 'ipad-not-safari' ) ) { - return 'ipad-unknown'; - } elseif ( static::is_Nintendo_3DS() ) { - return 'nintendo-3ds'; - } else { - $agent = $this->useragent; - $dumb_agents = $this->dumb_agents; - foreach ( $dumb_agents as $dumb_agent ) { - if ( false !== strpos( $agent, $dumb_agent ) ) { - return $dumb_agent; - } - } - } - - return false; - } - - /** - * This method detects the mobile device's platform. All return strings are from the class constants. - * Note that this function returns the platform name, not the UA name/type. You should use a different function - * if you need to test the UA capabilites. - * - * @return string|bool Name of the platform, false otherwise. - */ - public function get_platform() { - if ( isset( $this->platform ) ) { - return $this->platform; - } - - if ( empty( $this->useragent ) ) { - return false; - } - - if ( strpos( $this->useragent, 'windows phone' ) !== false ) { - $this->platform = self::PLATFORM_WINDOWS; - } elseif ( strpos( $this->useragent, 'windows ce' ) !== false ) { - $this->platform = self::PLATFORM_WINDOWS; - } elseif ( strpos( $this->useragent, 'ipad' ) !== false ) { - $this->platform = self::PLATFORM_IPAD; - } elseif ( strpos( $this->useragent, 'ipod' ) !== false ) { - $this->platform = self::PLATFORM_IPOD; - } elseif ( strpos( $this->useragent, 'iphone' ) !== false ) { - $this->platform = self::PLATFORM_IPHONE; - } elseif ( strpos( $this->useragent, 'android' ) !== false ) { - if ( static::is_android_tablet() ) { - $this->platform = self::PLATFORM_ANDROID_TABLET; - } else { - $this->platform = self::PLATFORM_ANDROID; - } - } elseif ( static::is_kindle_fire() ) { - $this->platform = self::PLATFORM_ANDROID_TABLET; - } elseif ( static::is_blackberry_10() ) { - $this->platform = self::PLATFORM_BLACKBERRY_10; - } elseif ( strpos( $this->useragent, 'blackberry' ) !== false ) { - $this->platform = self::PLATFORM_BLACKBERRY; - } elseif ( static::is_blackberry_tablet() ) { - $this->platform = self::PLATFORM_BLACKBERRY; - } elseif ( static::is_symbian_platform() ) { - $this->platform = self::PLATFORM_SYMBIAN; - } elseif ( static::is_symbian_s40_platform() ) { - $this->platform = self::PLATFORM_SYMBIAN_S40; - } elseif ( static::is_J2ME_platform() ) { - $this->platform = self::PLATFORM_J2ME_MIDP; - } elseif ( static::is_firefox_os() ) { - $this->platform = self::PLATFORM_FIREFOX_OS; - } else { - $this->platform = false; - } - - return $this->platform; - } - - /** - * Returns the platform for desktops - * - * @return string - */ - public function get_desktop_platform() { - $ua = $this->useragent; - if ( empty( $ua ) ) { - return false; - } - $platform = self::OTHER; - - if ( static::is_linux_desktop() ) { - $platform = self::PLATFORM_DESKTOP_LINUX; - } elseif ( static::is_mac_desktop() ) { - $platform = self::PLATFORM_DESKTOP_MAC; - } elseif ( static::is_windows_desktop() ) { - $platform = self::PLATFORM_DESKTOP_WINDOWS; - } elseif ( static::is_chrome_desktop() ) { - $platform = self::PLATFORM_DESKTOP_CHROME; - } - return $platform; - } - - /** - * A simple pattern matching method for extracting the browser from the user agent. - * - * @return string - */ - public function get_browser() { - $ua = $this->useragent; - if ( empty( $ua ) ) { - return self::OTHER; - } - - if ( static::is_opera_mini() || static::is_opera_mobile() || static::is_opera_desktop() || static::is_opera_mini_dumb() ) { - return self::BROWSER_OPERA; - } elseif ( static::is_edge_browser() ) { - return self::BROWSER_EDGE; - } elseif ( static::is_chrome_desktop() || self::is_chrome_for_iOS() ) { - return self::BROWSER_CHROME; - } elseif ( static::is_safari_browser() ) { - return self::BROWSER_SAFARI; - } elseif ( static::is_firefox_mobile() || static::is_firefox_desktop() ) { - return self::BROWSER_FIREFOX; - } elseif ( static::is_ie_browser() ) { - return self::BROWSER_IE; - } - return self::OTHER; - } - - /** - * This method detects for UA which can display iPhone-optimized web content. - * Includes iPhone, iPod Touch, Android, WebOS, Fennec (Firefox mobile), etc. - */ - public function isTierIphone() { - if ( isset( $this->isTierIphone ) ) { - return $this->isTierIphone; - } - if ( $this->is_iphoneOrIpod() ) { - $this->matched_agent = 'iphone'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_android() ) { - $this->matched_agent = 'android'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_windows_phone_8() ) { - $this->matched_agent = 'winphone8'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_WindowsPhone7() ) { - $this->matched_agent = 'win7'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_blackberry_10() ) { - $this->matched_agent = 'blackberry-10'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_blackbeberry() && 'blackberry-webkit' === static::detect_blackberry_browser_version() ) { - $this->matched_agent = 'blackberry-webkit'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_blackberry_tablet() ) { - $this->matched_agent = 'blackberry_tablet'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_PalmWebOS() ) { - $this->matched_agent = 'webos'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_TouchPad() ) { - $this->matched_agent = 'hp_tablet'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_firefox_os() ) { - $this->matched_agent = 'firefoxOS'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_firefox_mobile() ) { - $this->matched_agent = 'fennec'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_opera_mobile() ) { - $this->matched_agent = 'opera-mobi'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_MaemoTablet() ) { - $this->matched_agent = 'maemo'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_MeeGo() ) { - $this->matched_agent = 'meego'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_kindle_touch() ) { - $this->matched_agent = 'kindle-touch'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } elseif ( static::is_Nintendo_3DS() ) { - $this->matched_agent = 'nintendo-3ds'; - $this->isTierIphone = true; - $this->isTierRichCss = false; - $this->isTierGenericMobile = false; - } else { - $this->isTierIphone = false; - } - return $this->isTierIphone; - } - - /** - * This method detects for UA which are likely to be capable - * but may not necessarily support JavaScript. - * Excludes all iPhone Tier UA. - */ - public function isTierRichCss() { - if ( isset( $this->isTierRichCss ) ) { - return $this->isTierRichCss; - } - if ( $this->isTierIphone() ) { - return false; - } - - // The following devices are explicitly ok. - if ( static::is_S60_OSSBrowser() ) { - $this->matched_agent = 'series60'; - $this->isTierIphone = false; - $this->isTierRichCss = true; - $this->isTierGenericMobile = false; - } elseif ( static::is_opera_mini() ) { - $this->matched_agent = 'opera-mini'; - $this->isTierIphone = false; - $this->isTierRichCss = true; - $this->isTierGenericMobile = false; - } elseif ( static::is_blackbeberry() ) { - $detectedDevice = static::detect_blackberry_browser_version(); - if ( - 'blackberry-5' === $detectedDevice - || 'blackberry-4.7' === $detectedDevice - || 'blackberry-4.6' === $detectedDevice - ) { - $this->matched_agent = $detectedDevice; - $this->isTierIphone = false; - $this->isTierRichCss = true; - $this->isTierGenericMobile = false; - } - } else { - $this->isTierRichCss = false; - } - - return $this->isTierRichCss; - } - - /** - * Detects if the user is using a tablet. - * props Corey Gilmore, BGR.com - * - * @return bool - */ - public function is_tablet() { - return ( 0 // Never true, but makes it easier to manage our list of tablet conditions. - || self::is_ipad() - || self::is_android_tablet() - || self::is_blackberry_tablet() - || self::is_kindle_fire() - || self::is_MaemoTablet() - || self::is_TouchPad() - ); - } - - /** - * Detects if the current UA is the default iPhone or iPod Touch Browser. - * - * DEPRECATED: use is_iphone_or_ipod - */ - public function is_iphoneOrIpod() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( ( strpos( $ua, 'iphone' ) !== false ) || ( strpos( $ua, 'ipod' ) !== false ) ) { - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * Detects if the current UA is iPhone Mobile Safari or another iPhone or iPod Touch Browser. - * - * They type can check for any iPhone, an iPhone using Safari, or an iPhone using something other than Safari. - * - * Note: If you want to check for Opera mini, Opera mobile or Firefox mobile (or any 3rd party iPhone browser), - * you should put the check condition before the check for 'iphone-any' or 'iphone-not-safari'. - * Otherwise those browsers will be 'catched' by the iphone string. - * - * @param string $type Type of iPhone detection. - */ - public static function is_iphone_or_ipod( $type = 'iphone-any' ) { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $is_iphone = ( strpos( $ua, 'iphone' ) !== false ) || ( strpos( $ua, 'ipod' ) !== false ); - $is_safari = ( false !== strpos( $ua, 'safari' ) ); - - if ( 'iphone-safari' === $type ) { - return $is_iphone && $is_safari; - } elseif ( 'iphone-not-safari' === $type ) { - return $is_iphone && ! $is_safari; - } else { - return $is_iphone; - } - } - - /** - * Detects if the current UA is Chrome for iOS - * - * The User-Agent string in Chrome for iOS is the same as the Mobile Safari User-Agent, with CriOS/ instead of Version/. - * - Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_1_1 like Mac OS X; en) AppleWebKit/534.46.0 (KHTML, like Gecko) CriOS/19.0.1084.60 Mobile/9B206 Safari/7534.48.3 - */ - public static function is_chrome_for_iOS() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - if ( self::is_iphone_or_ipod( 'iphone-safari' ) === false ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'crios/' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current UA is Twitter for iPhone - * - * Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_3_5 like Mac OS X; nb-no) AppleWebKit/533.17.9 (KHTML, like Gecko) Mobile/8L1 Twitter for iPhone - * Mozilla/5.0 (iPhone; CPU iPhone OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 Twitter for iPhone - */ - public static function is_twitter_for_iphone() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'ipad' ) !== false ) { - return false; - } - - if ( strpos( $ua, 'twitter for iphone' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current UA is Twitter for iPad - * - * Old version 4.X - Mozilla/5.0 (iPad; U; CPU OS 4_3_5 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Mobile/8L1 Twitter for iPad - * Ver 5.0 or Higher - Mozilla/5.0 (iPad; CPU OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 Twitter for iPhone - */ - public static function is_twitter_for_ipad() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'twitter for ipad' ) !== false ) { - return true; - } elseif ( strpos( $ua, 'ipad' ) !== false && strpos( $ua, 'twitter for iphone' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current UA is Facebook for iPhone - * - Facebook 4020.0 (iPhone; iPhone OS 5.0.1; fr_FR) - * - Mozilla/5.0 (iPhone; U; CPU iPhone OS 5_0 like Mac OS X; en_US) AppleWebKit (KHTML, like Gecko) Mobile [FBAN/FBForIPhone;FBAV/4.0.2;FBBV/4020.0;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/5.0;FBSS/2; FBCR/O2;FBID/phone;FBLC/en_US;FBSF/2.0] - * - Mozilla/5.0 (iPhone; CPU iPhone OS 5_1_1 like Mac OS X) AppleWebKit/534.46 (KHTML, like Gecko) Mobile/9B206 [FBAN/FBIOS;FBAV/5.0;FBBV/47423;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/5.1.1;FBSS/2; FBCR/3ITA;FBID/phone;FBLC/en_US] - */ - public static function is_facebook_for_iphone() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( false === strpos( $ua, 'iphone' ) ) { - return false; - } - - if ( false !== strpos( $ua, 'facebook' ) && false === strpos( $ua, 'ipad' ) ) { - return true; - } elseif ( false !== strpos( $ua, 'fbforiphone' ) && false === strpos( $ua, 'tablet' ) ) { - return true; - } elseif ( false !== strpos( $ua, 'fban/fbios;' ) && false === strpos( $ua, 'tablet' ) ) { // FB app v5.0 or higher. - return true; - } else { - return false; - } - } - - /** - * Detects if the current UA is Facebook for iPad - * - Facebook 4020.0 (iPad; iPhone OS 5.0.1; en_US) - * - Mozilla/5.0 (iPad; U; CPU iPhone OS 5_0 like Mac OS X; en_US) AppleWebKit (KHTML, like Gecko) Mobile [FBAN/FBForIPhone;FBAV/4.0.2;FBBV/4020.0;FBDV/iPad2,1;FBMD/iPad;FBSN/iPhone OS;FBSV/5.0;FBSS/1; FBCR/;FBID/tablet;FBLC/en_US;FBSF/1.0] - * - Mozilla/5.0 (iPad; CPU OS 6_0 like Mac OS X) AppleWebKit/536.26 (KHTML, like Gecko) Mobile/10A403 [FBAN/FBIOS;FBAV/5.0;FBBV/47423;FBDV/iPad2,1;FBMD/iPad;FBSN/iPhone OS;FBSV/6.0;FBSS/1; FBCR/;FBID/tablet;FBLC/en_US] - */ - public static function is_facebook_for_ipad() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( false === strpos( $ua, 'ipad' ) ) { - return false; - } - - if ( false !== strpos( $ua, 'facebook' ) || false !== strpos( $ua, 'fbforiphone' ) || false !== strpos( $ua, 'fban/fbios;' ) ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current UA is WordPress for iOS - */ - public static function is_wordpress_for_ios() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( false !== strpos( $ua, 'wp-iphone' ) ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current device is an iPad. - * They type can check for any iPad, an iPad using Safari, or an iPad using something other than Safari. - * - * Note: If you want to check for Opera mini, Opera mobile or Firefox mobile (or any 3rd party iPad browser), - * you should put the check condition before the check for 'iphone-any' or 'iphone-not-safari'. - * Otherwise those browsers will be 'catched' by the ipad string. - * - * @param string $type iPad type. - */ - public static function is_ipad( $type = 'ipad-any' ) { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $is_ipad = ( false !== strpos( $ua, 'ipad' ) ); - $is_safari = ( false !== strpos( $ua, 'safari' ) ); - - if ( 'ipad-safari' === $type ) { - return $is_ipad && $is_safari; - } elseif ( 'ipad-not-safari' === $type ) { - return $is_ipad && ! $is_safari; - } else { - return $is_ipad; - } - } - - /** - * Detects if the current browser is Firefox Mobile (Fennec) - * - * See http://www.useragentstring.com/pages/Fennec/ - * Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.1.1) Gecko/20110415 Firefox/4.0.2pre Fennec/4.0.1 - * Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1b2pre) Gecko/20081015 Fennec/1.0a1 - */ - public static function is_firefox_mobile() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'fennec' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current browser is Firefox for desktop - * - * See https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/User-Agent/Firefox - * Mozilla/5.0 (platform; rv:geckoversion) Gecko/geckotrail Firefox/firefoxversion - * The platform section will include 'Mobile' for phones and 'Tablet' for tablets. - */ - public static function is_firefox_desktop() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( false !== strpos( $ua, 'firefox' ) && false === strpos( $ua, 'mobile' ) && false === strpos( $ua, 'tablet' ) ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current browser is FirefoxOS Native browser - * - * Mozilla/5.0 (Mobile; rv:14.0) Gecko/14.0 Firefox/14.0 - */ - public static function is_firefox_os() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'mozilla' ) !== false && strpos( $ua, 'mobile' ) !== false && strpos( $ua, 'gecko' ) !== false && strpos( $ua, 'firefox' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detect Safari browser - */ - public static function is_safari_browser() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - if ( false === strpos( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ), 'Safari' ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - return true; - } - - /** - * Detect Edge browser - */ - public static function is_edge_browser() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - if ( false === strpos( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ), 'Edge' ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - return true; - } - - /** - * Detect Edge browser - */ - public static function is_ie_browser() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - $ua = wp_unslash( $_SERVER['HTTP_USER_AGENT'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( false === ( strpos( $ua, 'MSIE' ) || strpos( $ua, 'Trident/7' ) ) ) { - return false; - } - return true; - } - - /** - * Detect modern Opera desktop - * - * Mozilla/5.0 (Macintosh; Intel Mac OS X 11_2_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/88.0.4324.182 Safari/537.36 OPR/74.0.3911.203 - * - * Looking for "OPR/" specifically. - */ - public static function is_opera_desktop() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - if ( false === strpos( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ), 'OPR/' ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - - return true; - } - - /** - * Detects if the current browser is Opera Mobile - * - * What is the difference between Opera Mobile and Opera Mini? - * - Opera Mobile is a full Internet browser for mobile devices. - * - Opera Mini always uses a transcoder to convert the page for a small display. - * (it uses Opera advanced server compression technology to compress web content before it gets to a device. - * The rendering engine is on Opera's server.) - * - * Opera/9.80 (Windows NT 6.1; Opera Mobi/14316; U; en) Presto/2.7.81 Version/11.00" - * Opera/9.50 (Nintendo DSi; Opera/507; U; en-US) - */ - public static function is_opera_mobile() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'opera' ) !== false && strpos( $ua, 'mobi' ) !== false ) { - return true; - } elseif ( strpos( $ua, 'opera' ) !== false && strpos( $ua, 'nintendo dsi' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current browser is Opera Mini - * - * Opera/8.01 (J2ME/MIDP; Opera Mini/3.0.6306/1528; en; U; ssr) - * Opera/9.80 (Android;Opera Mini/6.0.24212/24.746 U;en) Presto/2.5.25 Version/10.5454 - * Opera/9.80 (iPhone; Opera Mini/5.0.019802/18.738; U; en) Presto/2.4.15 - * Opera/9.80 (J2ME/iPhone;Opera Mini/5.0.019802/886; U; ja) Presto/2.4.15 - * Opera/9.80 (J2ME/iPhone;Opera Mini/5.0.019802/886; U; ja) Presto/2.4.15 - * Opera/9.80 (Series 60; Opera Mini/5.1.22783/23.334; U; en) Presto/2.5.25 Version/10.54 - * Opera/9.80 (BlackBerry; Opera Mini/5.1.22303/22.387; U; en) Presto/2.5.25 Version/10.54 - */ - public static function is_opera_mini() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $ua, 'opera' ) !== false && strpos( $ua, 'mini' ) !== false ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current browser is Opera Mini, but not on a smart device OS(Android, iOS, etc) - * Used to send users on dumb devices to m.wor - */ - public static function is_opera_mini_dumb() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( self::is_opera_mini() ) { - if ( strpos( $ua, 'android' ) !== false || strpos( $ua, 'iphone' ) !== false || strpos( $ua, 'ipod' ) !== false - || strpos( $ua, 'ipad' ) !== false || strpos( $ua, 'blackberry' ) !== false ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * Detects if the current browser is a Windows Phone 7 device. - * ex: Mozilla/4.0 (compatible; MSIE 7.0; Windows Phone OS 7.0; Trident/3.1; IEMobile/7.0; LG; GW910) - */ - public static function is_WindowsPhone7() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( false === strpos( $ua, 'windows phone os 7' ) ) { - return false; - } elseif ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } - - /** - * Detects if the current browser is a Windows Phone 8 device. - * ex: Mozilla/5.0 (compatible; MSIE 10.0; Windows Phone 8.0; Trident/6.0; ARM; Touch; IEMobile/10.0; ; [;]) - */ - public static function is_windows_phone_8() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( strpos( $ua, 'windows phone 8' ) === false ) { - return false; - } else { - return true; - } - } - - /** - * Detects if the current browser is on a Palm device running the new WebOS. This EXCLUDES TouchPad. - * - * Ex1: Mozilla/5.0 (webOS/1.4.0; U; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Version/1.0 Safari/532.2 Pre/1.1 - * Ex2: Mozilla/5.0 (webOS/1.4.0; U; en-US) AppleWebKit/532.2 (KHTML, like Gecko) Version/1.0 Safari/532.2 Pixi/1.1 - */ - public static function is_PalmWebOS() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( false === strpos( $ua, 'webos' ) ) { - return false; - } elseif ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } - - /** - * Detects if the current browser is the HP TouchPad default browser. This excludes phones wt WebOS. - * - * TouchPad Emulator: Mozilla/5.0 (hp-desktop; Linux; hpwOS/2.0; U; it-IT) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 Desktop/1.0 - * TouchPad: Mozilla/5.0 (hp-tablet; Linux; hpwOS/3.0.0; U; en-US) AppleWebKit/534.6 (KHTML, like Gecko) wOSBrowser/233.70 Safari/534.6 TouchPad/1.0 - */ - public static function is_TouchPad() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $http_user_agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( false !== strpos( $http_user_agent, 'hp-tablet' ) || false !== strpos( $http_user_agent, 'hpwos' ) || false !== strpos( $http_user_agent, 'touchpad' ) ) { - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * Detects if the current browser is the Series 60 Open Source Browser. - * - * OSS Browser 3.2 on E75: Mozilla/5.0 (SymbianOS/9.3; U; Series60/3.2 NokiaE75-1/110.48.125 Profile/MIDP-2.1 Configuration/CLDC-1.1 ) AppleWebKit/413 (KHTML, like Gecko) Safari/413 - * - * 7.0 Browser (Nokia 5800 XpressMusic (v21.0.025)) : Mozilla/5.0 (SymbianOS/9.4; U; Series60/5.0 Nokia5800d-1/21.0.025; Profile/MIDP-2.1 Configuration/CLDC-1.1 ) AppleWebKit/413 (KHTML, like Gecko) Safari/413 - * - * Browser 7.1 (Nokia N97 (v12.0.024)) : Mozilla/5.0 (SymbianOS/9.4; Series60/5.0 NokiaN97-1/12.0.024; Profile/MIDP-2.1 Configuration/CLDC-1.1; en-us) AppleWebKit/525 (KHTML, like Gecko) BrowserNG/7.1.12344 - */ - public static function is_S60_OSSBrowser() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } - - $pos_webkit = strpos( $agent, 'webkit' ); - if ( false !== $pos_webkit ) { - // First, test for WebKit, then make sure it's either Symbian or S60. - if ( strpos( $agent, 'symbian' ) !== false || strpos( $agent, 'series60' ) !== false ) { - return true; - } else { - return false; - } - } elseif ( strpos( $agent, 'symbianos' ) !== false && strpos( $agent, 'series60' ) !== false ) { - return true; - } elseif ( strpos( $agent, 'nokia' ) !== false && strpos( $agent, 'series60' ) !== false ) { - return true; - } - - return false; - } - - /** - * Detects if the device platform is the Symbian Series 60. - */ - public static function is_symbian_platform() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $pos_webkit = strpos( $agent, 'webkit' ); - if ( false !== $pos_webkit ) { - // First, test for WebKit, then make sure it's either Symbian or S60. - if ( strpos( $agent, 'symbian' ) !== false || strpos( $agent, 'series60' ) !== false ) { - return true; - } else { - return false; - } - } elseif ( strpos( $agent, 'symbianos' ) !== false && strpos( $agent, 'series60' ) !== false ) { - return true; - } elseif ( strpos( $agent, 'nokia' ) !== false && strpos( $agent, 'series60' ) !== false ) { - return true; - } elseif ( strpos( $agent, 'opera mini' ) !== false ) { - if ( strpos( $agent, 'symbianos' ) !== false || strpos( $agent, 'symbos' ) !== false || strpos( $agent, 'series 60' ) !== false ) { - return true; - } - } - - return false; - } - - /** - * Detects if the device platform is the Symbian Series 40. - * Nokia Browser for Series 40 is a proxy based browser, previously known as Ovi Browser. - * This browser will report 'NokiaBrowser' in the header, however some older version will also report 'OviBrowser'. - */ - public static function is_symbian_s40_platform() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $agent, 'series40' ) !== false ) { - if ( strpos( $agent, 'nokia' ) !== false || strpos( $agent, 'ovibrowser' ) !== false || strpos( $agent, 'nokiabrowser' ) !== false ) { - return true; - } - } - - return false; - } - - /** - * Returns if the device belongs to J2ME capable family. - * - * @return bool - */ - public static function is_J2ME_platform() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( strpos( $agent, 'j2me/midp' ) !== false ) { - return true; - } elseif ( strpos( $agent, 'midp' ) !== false && strpos( $agent, 'cldc' ) ) { - return true; - } - return false; - } - - /** - * Detects if the current UA is on one of the Maemo-based Nokia Internet Tablets. - */ - public static function is_MaemoTablet() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $pos_maemo = strpos( $agent, 'maemo' ); - if ( false === $pos_maemo ) { - return false; - } - - // Must be Linux + Tablet, or else it could be something else. - if ( strpos( $agent, 'tablet' ) !== false && strpos( $agent, 'linux' ) !== false ) { - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * Detects if the current UA is a MeeGo device (Nokia Smartphone). - */ - public static function is_MeeGo() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( false === strpos( $ua, 'meego' ) ) { - return false; - } elseif ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } - - /** - * The is_webkit() method can be used to check the User Agent for an webkit generic browser. - */ - public static function is_webkit() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $pos_webkit = strpos( $agent, 'webkit' ); - - if ( false !== $pos_webkit ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current browser is the Native Android browser. - * - * @return boolean true if the browser is Android otherwise false - */ - public static function is_android() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos_android = strpos( $agent, 'android' ); - if ( false !== $pos_android ) { - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * Detects if the current browser is the Native Android Tablet browser. - * Assumes 'Android' should be in the user agent, but not 'mobile' - * - * @return boolean true if the browser is Android and not 'mobile' otherwise false - */ - public static function is_android_tablet() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $pos_android = strpos( $agent, 'android' ); - $pos_mobile = strpos( $agent, 'mobile' ); - $post_android_app = strpos( $agent, 'wp-android' ); - - if ( false !== $pos_android && false === $pos_mobile && false === $post_android_app ) { - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * Detects if the current browser is the Kindle Fire Native browser. - * - * Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us; Silk/1.1.0-84) AppleWebKit/533.16 (KHTML, like Gecko) Version/5.0 Safari/533.16 Silk-Accelerated=true - * Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_3; en-us; Silk/1.1.0-84) AppleWebKit/533.16 (KHTML, like Gecko) Version/5.0 Safari/533.16 Silk-Accelerated=false - * - * @return boolean true if the browser is Kindle Fire Native browser otherwise false - */ - public static function is_kindle_fire() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos_silk = strpos( $agent, 'silk/' ); - $pos_silk_acc = strpos( $agent, 'silk-accelerated=' ); - if ( false !== $pos_silk && false !== $pos_silk_acc ) { - return true; - } else { - return false; - } - } - - /** - * Detects if the current browser is the Kindle Touch Native browser - * - * Mozilla/5.0 (X11; U; Linux armv7l like Android; en-us) AppleWebKit/531.2+ (KHTML, like Gecko) Version/5.0 Safari/533.2+ Kindle/3.0+ - * - * @return boolean true if the browser is Kindle monochrome Native browser otherwise false - */ - public static function is_kindle_touch() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos_kindle_touch = strpos( $agent, 'kindle/3.0+' ); - if ( false !== $pos_kindle_touch && false === self::is_kindle_fire() ) { - return true; - } else { - return false; - } - } - - /** - * Detect if user agent is the WordPress.com Windows 8 app (used ONLY on the custom oauth stylesheet) - */ - public static function is_windows8_auth() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos = strpos( $agent, 'msauthhost' ); - if ( false !== $pos ) { - return true; - } else { - return false; - } - } - - /** - * Detect if user agent is the WordPress.com Windows 8 app. - */ - public static function is_wordpress_for_win8() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos = strpos( $agent, 'wp-windows8' ); - if ( false !== $pos ) { - return true; - } else { - return false; - } - } - - /** - * Detect if user agent is the WordPress.com Desktop app. - */ - public static function is_wordpress_desktop_app() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos = strpos( $agent, 'WordPressDesktop' ); - if ( false !== $pos ) { - return true; - } else { - return false; - } - } - - /** - * The is_blackberry_tablet() method can be used to check the User Agent for a RIM blackberry tablet. - * The user agent of the BlackBerry® Tablet OS follows a format similar to the following: - * Mozilla/5.0 (PlayBook; U; RIM Tablet OS 1.0.0; en-US) AppleWebKit/534.8+ (KHTML, like Gecko) Version/0.0.1 Safari/534.8+ - */ - public static function is_blackberry_tablet() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - $pos_playbook = stripos( $agent, 'PlayBook' ); - $pos_rim_tablet = stripos( $agent, 'RIM Tablet' ); - - if ( ( false === $pos_playbook ) || ( false === $pos_rim_tablet ) ) { - return false; - } else { - return true; - } - } - - /** - * The is_blackbeberry() method can be used to check the User Agent for a blackberry device. - * Note that opera mini on BB matches this rule. - */ - public static function is_blackbeberry() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $pos_blackberry = strpos( $agent, 'blackberry' ); - if ( false !== $pos_blackberry ) { - if ( self::is_opera_mini() || self::is_opera_mobile() || self::is_firefox_mobile() ) { - return false; - } else { - return true; - } - } else { - return false; - } - } - - /** - * The is_blackberry_10() method can be used to check the User Agent for a BlackBerry 10 device. - */ - public static function is_blackberry_10() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return ( strpos( $agent, 'bb10' ) !== false ) && ( strpos( $agent, 'mobile' ) !== false ); - } - - /** - * Determines whether a desktop platform is Linux OS - * - * @return bool - */ - public static function is_linux_desktop() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - if ( ! preg_match( '/linux/i', wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - return true; - } - - /** - * Determines whether a desktop platform is Mac OS - * - * @return bool - */ - public static function is_mac_desktop() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - if ( ! preg_match( '/macintosh|mac os x/i', wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - return true; - } - - /** - * Determines whether a desktop platform is Windows OS - * - * @return bool - */ - public static function is_windows_desktop() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - if ( ! preg_match( '/windows|win32/i', wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - return true; - } - - /** - * Determines whether a desktop platform is Chrome OS - * - * @return bool - */ - public static function is_chrome_desktop() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - if ( ! preg_match( '/chrome/i', wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - return false; - } - return true; - } - - /** - * Retrieve the blackberry OS version. - * - * Return strings are from the following list: - * - blackberry-10 - * - blackberry-7 - * - blackberry-6 - * - blackberry-torch //only the first edition. The 2nd edition has the OS7 onboard and doesn't need any special rule. - * - blackberry-5 - * - blackberry-4.7 - * - blackberry-4.6 - * - blackberry-4.5 - * - * @return string Version of the BB OS. - * If version is not found, get_blackbeberry_OS_version will return boolean false. - */ - public static function get_blackbeberry_OS_version() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - if ( self::is_blackberry_10() ) { - return 'blackberry-10'; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - $pos_blackberry = stripos( $agent, 'blackberry' ); - if ( false === $pos_blackberry ) { - // Not a blackberry device. - return false; - } - - // Blackberry devices OS 6.0 or higher. - // Mozilla/5.0 (BlackBerry; U; BlackBerry 9670; en) AppleWebKit/534.3+ (KHTML, like Gecko) Version/6.0.0.286 Mobile Safari/534.3+. - // Mozilla/5.0 (BlackBerry; U; BlackBerry 9800; en) AppleWebKit/534.1+ (KHTML, Like Gecko) Version/6.0.0.141 Mobile Safari/534.1+. - // Mozilla/5.0 (BlackBerry; U; BlackBerry 9900; en-US) AppleWebKit/534.11+ (KHTML, like Gecko) Version/7.0.0 Mobile Safari/534.11+. - $pos_webkit = stripos( $agent, 'webkit' ); - if ( false !== $pos_webkit ) { - // Detected blackberry webkit browser. - $pos_torch = stripos( $agent, 'BlackBerry 9800' ); - if ( false !== $pos_torch ) { - return 'blackberry-torch'; // Match the torch first edition. the 2nd edition should use the OS7 and doesn't need any special rule. - } elseif ( preg_match( '#Version\/([\d\.]+)#i', $agent, $matches ) ) { // Detecting the BB OS version for devices running OS 6.0 or higher. - $version = $matches[1]; - $version_num = explode( '.', $version ); - if ( false === is_array( $version_num ) || count( $version_num ) <= 1 ) { - return 'blackberry-6'; // not a BB device that match our rule. - } else { - return 'blackberry-' . $version_num[0]; - } - } else { - // if doesn't match returns the minimun version with a webkit browser. we should never fall here. - return 'blackberry-6'; // not a BB device that match our rule. - } - } - - // Blackberry devices <= 5.XX. - // BlackBerry9000/5.0.0.93 Profile/MIDP-2.0 Configuration/CLDC-1.1 VendorID/179. - if ( preg_match( '#BlackBerry\w+\/([\d\.]+)#i', $agent, $matches ) ) { - $version = $matches[1]; - } else { - return false; // not a BB device that match our rule. - } - - $version_num = explode( '.', $version ); - - if ( is_array( $version_num ) === false || count( $version_num ) <= 1 ) { - return false; - } - - $version_num_major = (int) $version_num[0]; - $version_num_minor = (int) $version_num[1]; - - if ( 5 === $version_num_major ) { - return 'blackberry-5'; - } elseif ( 4 === $version_num_major && 7 === $version_num_minor ) { - return 'blackberry-4.7'; - } elseif ( 4 === $version_num_major && 6 === $version_num_minor ) { - return 'blackberry-4.6'; - } elseif ( 4 === $version_num_major && 5 === $version_num_minor ) { - return 'blackberry-4.5'; - } else { - return false; - } - } - - /** - * Retrieve the blackberry browser version. - * - * Return string are from the following list: - * - blackberry-10 - * - blackberry-webkit - * - blackberry-5 - * - blackberry-4.7 - * - blackberry-4.6 - * - * @return string Type of the BB browser. - * If browser's version is not found, detect_blackbeberry_browser_version will return boolean false. - */ - public static function detect_blackberry_browser_version() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( self::is_blackberry_10() ) { - return 'blackberry-10'; - } - - $pos_blackberry = strpos( $agent, 'blackberry' ); - if ( false === $pos_blackberry ) { - // Not a blackberry device. - return false; - } - - $pos_webkit = strpos( $agent, 'webkit' ); - - if ( ! ( false === $pos_webkit ) ) { - return 'blackberry-webkit'; - } else { - if ( ! preg_match( '#BlackBerry\w+\/([\d\.]+)#i', $agent, $matches ) ) { - return false; // not a BB device that match our rule. - } - - $version_num = explode( '.', $matches[1] ); - - if ( false === is_array( $version_num ) || count( $version_num ) <= 1 ) { - return false; - } - - $version_num_major = (int) $version_num[0]; - $version_num_minor = (int) $version_num[1]; - - if ( 5 === $version_num_major ) { - return 'blackberry-5'; - } elseif ( 4 === $version_num_major && 7 === $version_num_minor ) { - return 'blackberry-4.7'; - } elseif ( 4 === $version_num_major && 6 === $version_num_minor ) { - return 'blackberry-4.6'; - } else { - // A very old BB device is found or this is a BB device that doesn't match our rules. - return false; - } - } - } - - /** - * Checks if a visitor is coming from one of the WordPress mobile apps. - * - * @return bool - */ - public static function is_mobile_app() { - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $agent = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - - if ( isset( $_SERVER['X_USER_AGENT'] ) && preg_match( '|wp-webos|', $_SERVER['X_USER_AGENT'] ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- This is validating. - return true; // Wp4webos 1.1 or higher. - } - - $app_agents = array( 'wp-android', 'wp-blackberry', 'wp-iphone', 'wp-nokia', 'wp-webos', 'wp-windowsphone' ); - // the mobile reader on iOS has an incorrect UA when loading the reader - // currently it is the default one provided by the iOS framework which - // causes problems with 2-step-auth - // User-Agent WordPress/3.1.4 CFNetwork/609 Darwin/13.0.0. - $app_agents[] = 'wordpress/3.1'; - - foreach ( $app_agents as $app_agent ) { - if ( false !== strpos( $agent, $app_agent ) ) { - return true; - } - } - return false; - } - - /** - * Detects if the current browser is Nintendo 3DS handheld. - * - * Example: Mozilla/5.0 (Nintendo 3DS; U; ; en) Version/1.7498.US - * can differ in language, version and region - */ - public static function is_Nintendo_3DS() { - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - $ua = strtolower( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - if ( strpos( $ua, 'nintendo 3ds' ) !== false ) { - return true; - } - return false; - } - - /** - * Was the current request made by a known bot? - * - * @return boolean - */ - public static function is_bot() { - static $is_bot = null; - - if ( empty( $_SERVER['HTTP_USER_AGENT'] ) ) { - return false; - } - - if ( $is_bot === null ) { - $is_bot = self::is_bot_user_agent( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- This is validating. - } - - return $is_bot; - } - - /** - * Is the given user-agent a known bot? - * If you want an is_bot check for the current request's UA, use is_bot() instead of passing a user-agent to this method. - * - * @param string $ua A user-agent string. - * - * @return boolean - */ - public static function is_bot_user_agent( $ua = null ) { - - if ( empty( $ua ) ) { - return false; - } - - $bot_agents = array( - 'alexa', - 'altavista', - 'ask jeeves', - 'attentio', - 'baiduspider', - 'bingbot', - 'chtml generic', - 'crawler', - 'fastmobilecrawl', - 'feedfetcher-google', - 'firefly', - 'froogle', - 'gigabot', - 'googlebot', - 'googlebot-mobile', - 'heritrix', - 'httrack', - 'ia_archiver', - 'irlbot', - 'iescholar', - 'infoseek', - 'jumpbot', - 'linkcheck', - 'lycos', - 'mediapartners', - 'mediobot', - 'motionbot', - 'msnbot', - 'mshots', - 'openbot', - 'pss-webkit-request', - 'pythumbnail', - 'scooter', - 'slurp', - 'snapbot', - 'spider', - 'taptubot', - 'technoratisnoop', - 'teoma', - 'twiceler', - 'yahooseeker', - 'yahooysmcm', - 'yammybot', - 'ahrefsbot', - 'pingdom.com_bot', - 'kraken', - 'yandexbot', - 'twitterbot', - 'tweetmemebot', - 'openhosebot', - 'queryseekerspider', - 'linkdexbot', - 'grokkit-crawler', - 'livelapbot', - 'germcrawler', - 'domaintunocrawler', - 'grapeshotcrawler', - 'cloudflare-alwaysonline', - 'cookieinformationscanner', // p1699315886066389-slack-C0438NHCLSY - 'facebookexternalhit', // https://www.facebook.com/externalhit_uatext.php - 'feedburner', - 'yacybot', // http://yacy.net/bot.html - 'trendictionbot', // http://www.trendiction.de/bot; - 'elisabot', - 'linkfluence', // http://linkfluence.com/ - 'semrushbot', // https://www.semrush.com/bot/ - 'archive.org_bot', // http://archive.org/details/archive.org_bot - 'ezlynxbot', // https://www.ezoic.com/bot - 'siteauditbot', // https://www.semrush.com/bot/ - 'snapchat', // https://developers.snap.com/robots - 'applebot', // https://support.apple.com/en-ca/HT204683 - 'bne.es_bot', // https://www.bne.es/es/colecciones/archivo-web-espanola/aviso-webmasters - 'google-safety;', // https://www.google.com/bot.html - 'mojeekbot', // https://www.mojeek.com/bot.html - 'linkwalker', // https://www.linkwalker.com/ - ); - - foreach ( $bot_agents as $bot_agent ) { - if ( false !== stripos( $ua, $bot_agent ) ) { - return true; - } - } - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/functions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/functions.php deleted file mode 100644 index a530e7f9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-device-detection/src/functions.php +++ /dev/null @@ -1,36 +0,0 @@ - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/build/index.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/build/index.asset.php deleted file mode 100644 index 2aa2511d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/build/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('react', 'react-jsx-runtime', 'wp-api-fetch', 'wp-url'), 'version' => '37d1ea057f1a1470ad33'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/build/index.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/build/index.js deleted file mode 100644 index 1b92d5f9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/build/index.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";var e={792:(e,t,n)=>{n.d(t,{A:()=>s});var r=n(790),i=n(609);const o={isEligible:!0};function s(e){const t=(t,n={})=>{const r={...o,...n},[,s]=(0,i.useReducer)((e=>e+1),0),a=(0,i.useRef)(t);if((0,i.useEffect)((()=>{let n=!0;return r.isEligible&&e.loadExperimentAssignment(t).then((()=>{n&&s()})),()=>{n=!1}}),[t,r.isEligible]),t===a.current||a.current.startsWith("explat_test")||e.config.logError({message:"[ExPlat] useExperiment: experimentName should never change between renders!"}),!r.isEligible)return[!1,null];const m=e.dangerouslyGetMaybeLoadedExperimentAssignment(t);return[!m,m]};return{useExperiment:t,Experiment:({defaultExperience:e,treatmentExperience:n,loadingExperience:i,name:o,options:s})=>{const[a,m]=t(o,s);return a?(0,r.jsx)(r.Fragment,{children:i}):m?.variationName?(0,r.jsx)(r.Fragment,{children:n}):(0,r.jsx)(r.Fragment,{children:e})},ProvideExperimentData:({children:e,name:n,options:r})=>{const[i,o]=t(n,r);return e(i,o)}}}},517:(e,t,n)=>{n.d(t,{kU:()=>c,pg:()=>u});var r=n(689),i=n(808),o=n(738),s=n(762),a=n(626);const m=1e4;Error;function c(e){if("undefined"==typeof window)throw new Error("Running outside of a browser context.");const t={},n=(...t)=>{try{e.logError(...t)}catch(e){}};try{(0,r.bZ)()}catch(e){n({message:e.message,source:"removeExpiredExperimentAssignments-error"})}return{loadExperimentAssignment:async c=>{try{if(!a.Eo(c))throw new Error(`Invalid experimentName: "${c}"`);const n=(0,r.B1)(c);if(n&&i.H2(n))return n;void 0===t[c]&&(t[c]=(t=>s.MC((async()=>{const n=await o.FI(e,t);return(0,r.a2)(n),n})))(c));let u=m;Math.random()>.5&&(u=5e3);const l=await s.BK(t[c](),u);if(!l)throw new Error("Could not fetch ExperimentAssignment");return l}catch(e){n({message:e.message,experimentName:c,source:"loadExperimentAssignment-initialError"})}try{const e=(0,r.B1)(c);if(e)return e;const t=(0,i.fj)(c);return(0,r.a2)(t),t}catch(e){return n({message:e.message,experimentName:c,source:"loadExperimentAssignment-fallbackError"}),(0,i.fj)(c)}},dangerouslyGetExperimentAssignment:t=>{try{if(!a.Eo(t))throw new Error(`Invalid experimentName: ${t}`);const i=(0,r.B1)(t);if(!i)throw new Error("Trying to dangerously get an ExperimentAssignment that hasn't loaded.");return e.isDevelopmentMode&&i&&s.XZ()-i.retrievedTimestamp<1e3&&n({message:"Warning: Trying to dangerously get an ExperimentAssignment too soon after loading it.",experimentName:t,source:"dangerouslyGetExperimentAssignment"}),i}catch(r){return e.isDevelopmentMode&&n({message:r.message,experimentName:t,source:"dangerouslyGetExperimentAssignment-error"}),(0,i.fj)(t)}},dangerouslyGetMaybeLoadedExperimentAssignment:t=>{try{if(!a.Eo(t))throw new Error(`Invalid experimentName: ${t}`);const e=(0,r.B1)(t);return e||null}catch(r){return e.isDevelopmentMode&&n({message:r.message,experimentName:t,source:"dangerouslyGetMaybeLoadedExperimentAssignment-error"}),(0,i.fj)(t)}},config:e}}function u(e){return{loadExperimentAssignment:async t=>(e.logError({message:"Attempting to load ExperimentAssignment in SSR context",experimentName:t}),(0,i.fj)(t)),dangerouslyGetExperimentAssignment:t=>(e.logError({message:"Attempting to dangerously get ExperimentAssignment in SSR context",experimentName:t}),(0,i.fj)(t)),dangerouslyGetMaybeLoadedExperimentAssignment:t=>(e.logError({message:"Attempting to dangerously get ExperimentAssignment in SSR context",experimentName:t}),(0,i.fj)(t)),config:e}}},226:(e,t,n)=>{n.d(t,{k:()=>i});var r=n(517);const i="undefined"==typeof window?r.pg:r.kU},689:(e,t,n)=>{n.d(t,{B1:()=>c,a2:()=>m,bZ:()=>p});var r=n(808),i=n(765),o=n(626);const s="explat-experiment-",a=e=>`${s}-${e}`;function m(e){o.zV(e);const t=c(e.experimentName);if(t&&e.retrievedTimestamp[...Array(e).keys()];function l(e){return e.startsWith(s)}function d(e){return e.slice(s.length+1)}function p(){u(i.A.length).map((e=>i.A.key(e))).filter(l).map(d).filter((e=>{try{if(r.H2(c(e)))return!1}catch(e){}return!0})).map(a).map((e=>i.A.removeItem(e)))}},808:(e,t,n)=>{n.d(t,{H2:()=>i,fj:()=>s,fn:()=>o});var r=n(762);function i(e){return r.XZ()({experimentName:e,variationName:null,retrievedTimestamp:r.XZ(),ttl:Math.max(o,t),isFallbackExperimentAssignment:!0})},765:(e,t,n)=>{n.d(t,{A:()=>i});let r={_data:{},setItem:function(e,t){this._data[e]=t},getItem:function(e){return this._data.hasOwnProperty(e)?this._data[e]:null},removeItem:function(e){delete this._data[e]},clear:function(){this._data={}},get length(){return Object.keys(this._data).length},key:function(e){const t=Object.keys(this._data);return e in t?t[e]:null}};try{window.localStorage&&(r=window.localStorage)}catch(e){}const i=r},738:(e,t,n)=>{n.d(t,{FI:()=>l});var r=n(808),i=n(765),o=n(762),s=n(626);function a(e){if(function(e){return(0,s.Gv)(e)&&(0,s.Gv)(e.variations)&&"number"==typeof e.ttl&&0{const t=await e();if(t)return i.A.setItem(m,t),i.A.setItem(c,String((0,o.XZ)())),t;const n=i.A.getItem(m),r=i.A.getItem(c);return n&&r&&(0,o.XZ)()-parseInt(r,10)<864e5?n:null};async function l(e,t){const n=(0,o.XZ)(),{variations:i,ttl:m}=a(await e.fetchExperimentAssignment({anonId:await u(e.getAnonId),experimentName:t})),c=Math.max(r.fn,m),l=Object.entries(i).map((([e,t])=>({experimentName:e,variationName:t,retrievedTimestamp:n,ttl:c}))).map(s.zV);if(l.length>1)throw new Error("Received multiple experiment assignments while trying to fetch exactly one.");if(0===l.length)return r.fj(t,c);const d=l[0];if(d.experimentName!==t)throw new Error("Newly fetched ExperimentAssignment's experiment name does not match request.");if(!r.H2(d))throw new Error("Newly fetched experiment isn't alive.");return d}},762:(e,t,n)=>{n.d(t,{BK:()=>s,If:()=>r,MC:()=>a,XZ:()=>o});const r=1e3;let i=Date.now();function o(){const e=Date.now();return i=isetTimeout((()=>n(new Error(`Promise has timed-out after ${t}ms.`))),t)))])}function a(e){let t=null;return()=>(t||(t=e().finally((()=>{t=null}))),t)}},626:(e,t,n)=>{function r(e){return"object"==typeof e&&null!==e}function i(e){return"string"==typeof e&&""!==e&&/^[a-z0-9_]*$/.test(e)}function o(e){if(!function(e){return r(e)&&i(e.experimentName)&&(i(e.variationName)||null===e.variationName)&&"number"==typeof e.retrievedTimestamp&&"number"==typeof e.ttl&&0!==e.ttl}(e))throw new Error("Invalid ExperimentAssignment");return e}n.d(t,{Eo:()=>i,Gv:()=>r,zV:()=>o})},172:(e,t)=>{t.qg=function(e,t){const n=new a,r=e.length;if(r<2)return n;const i=t?.decode||u;let o=0;do{const t=e.indexOf("=",o);if(-1===t)break;const s=e.indexOf(";",o),a=-1===s?r:s;if(t>a){o=e.lastIndexOf(";",t-1)+1;continue}const u=m(e,o,t),l=c(e,t,u),d=e.slice(u,l);if(void 0===n[d]){let r=m(e,t+1,a),o=c(e,a,r);const s=i(e.slice(r,o));n[d]=s}o=a+1}while(o{const e=function(){};return e.prototype=Object.create(null),e})();function m(e,t,n){do{const n=e.charCodeAt(t);if(32!==n&&9!==n)return t}while(++tn;){const n=e.charCodeAt(--t);if(32!==n&&9!==n)return t+1}return n}function u(e){if(-1===e.indexOf("%"))return e;try{return decodeURIComponent(e)}catch(t){return e}}},889:(e,t,n)=>{n.d(t,{Ck:()=>s,wf:()=>o});var r=n(172);let i=null;const o=async()=>{let e=0;return i=new Promise((t=>{const n=()=>{const i=(0,r.qg)(document.cookie).tk_ai||null;"string"!=typeof i||""===i?99<=e?t(null):(e+=1,setTimeout(n,50)):t(i)};n()})),i},s=async()=>await i},222:(e,t,n)=>{n.d(t,{V:()=>m,z:()=>a});var r=n(455),i=n.n(r),o=n(832);const s=(e=!1)=>async({experimentName:t,anonId:n})=>{if(!n)throw new Error("Tracking is disabled, can't fetch experimentAssignment");const r={experiment_name:t,anon_id:n??void 0,as_connected_user:e},s=(0,o.addQueryArgs)("jetpack/v4/explat/assignments",r);return await i()({path:s})},a=s(!1),m=s(!0)},69:(e,t,n)=>{n.d(t,{v:()=>i});var r=n(382);const i=e=>{const t=e=>{r.D&&console.error("[ExPlat] Unable to send error to server:",e)};try{const{message:n,...i}=e,o={message:n,properties:{...i,context:"explat",explat_client:"jetpack"}};if(r.D)console.error("[ExPlat] ",e.message,e);else{const e=new window.FormData;e.append("error",JSON.stringify(o)),window.fetch("https://public-api.wordpress.com/rest/v1.1/js-error",{method:"POST",body:e}).catch(t)}}catch(e){t(e)}}},382:(e,t,n)=>{n.d(t,{D:()=>r});const r=!1},609:e=>{e.exports=window.React},790:e=>{e.exports=window.ReactJSXRuntime},455:e=>{e.exports=window.wp.apiFetch},832:e=>{e.exports=window.wp.url}},t={};function n(r){var i=t[r];if(void 0!==i)return i.exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t);var r=n(226),i=n(792),o=n(889),s=n(222),a=n(69),m=n(382);(0,o.wf)().catch((e=>(0,a.v)({message:e.message})));const c=(0,r.k)({fetchExperimentAssignment:s.z,getAnonId:o.Ck,logError:a.v,isDevelopmentMode:m.D}),{loadExperimentAssignment:u,dangerouslyGetExperimentAssignment:l}=c,{useExperiment:d,Experiment:p,ProvideExperimentData:g}=(0,i.A)(c),f=(0,r.k)({fetchExperimentAssignment:s.V,getAnonId:o.Ck,logError:a.v,isDevelopmentMode:m.D}),{loadExperimentAssignment:x,dangerouslyGetExperimentAssignment:E}=f,{useExperiment:h,Experiment:w,ProvideExperimentData:y}=(0,i.A)(f)})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/composer.json deleted file mode 100644 index 669b543b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/composer.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "name": "automattic/jetpack-explat", - "description": "A package for running A/B tests on the Experimentation Platform (ExPlat) in the plugin.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-connection": "^6.7.7" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": "pnpm concurrently --names php,js 'php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"' 'pnpm:test-coverage'", - "test-php": [ - "@composer phpunit" - ], - "test-js": [ - "pnpm run test" - ], - "test-js-watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run test --watch" - ], - "build-development": [ - "pnpm run build" - ], - "build-production": [ - "NODE_ENV=production pnpm run build" - ], - "watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run watch" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "branch-alias": { - "dev-trunk": "0.2.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-explat/compare/v${old}...v${new}" - }, - "mirror-repo": "Automattic/jetpack-explat", - "textdomain": "jetpack-explat", - "version-constants": { - "::PACKAGE_VERSION": "src/class-explat.php" - } - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/global.d.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/global.d.ts deleted file mode 100644 index 9eed072d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/global.d.ts +++ /dev/null @@ -1,9 +0,0 @@ -export declare global { - namespace NodeJS { - interface ProcessEnv { - NODE_ENV: 'development' | 'production' | 'test'; - } - } -} - -export {}; diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/class-explat.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/class-explat.php deleted file mode 100644 index 757ff58a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/class-explat.php +++ /dev/null @@ -1,44 +0,0 @@ - WP_REST_Server::READABLE, - 'callback' => array( $this, 'get_assignments' ), - 'permission_callback' => '__return_true', - 'args' => array( - 'experiment_name' => array( - 'type' => 'string', - ), - 'anon_id' => array( - 'type' => 'string', - ), - 'as_connected_user' => array( - 'type' => 'boolean', - ), - ), - ) - ); - } - - /** - * Get the assignments for a given experiment and anon_id - * - * @param WP_REST_Request $request The REST request object. - * @return WP_REST_Response|WP_Error - */ - public function get_assignments( $request ) { - $response = null; - $is_user_connected = ( new Jetpack_Connection() )->is_user_connected(); - $request_path = '/experiments/' . self::EXPLAT_API_VERSION . '/assignments/jetpack'; - $args = array( - 'experiment_name' => $request['experiment_name'], - 'anon_id' => $request['anon_id'], - ); - - if ( $request['as_connected_user'] && $is_user_connected ) { - $response = Client::wpcom_json_api_request_as_user( - add_query_arg( $args, $request_path ), - 'v2' - ); - } else { - $response = wp_remote_get( - add_query_arg( $args, self::WPCOM_API_BASE_URL . $request_path ) - ); - } - - if ( is_wp_error( $response ) ) { - return new WP_Error( - 'wp_error_fetching_assignment', - $response->get_error_message(), - array( 'status' => 500 ) - ); - } - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( 200 !== $response_code ) { - return new WP_Error( - 'http_error_fetching_assignment', - wp_remote_retrieve_response_message( $response ), - array( 'status' => $response_code ) - ); - } - - return rest_ensure_response( - json_decode( wp_remote_retrieve_body( $response ), true ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/anon.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/anon.ts deleted file mode 100644 index 488dc8ea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/anon.ts +++ /dev/null @@ -1,61 +0,0 @@ -/** - * External dependencies - */ -import { parse as cookieParse } from 'cookie'; - -let initializeAnonIdPromise: Promise< string | null > | null = null; -const anonIdPollingIntervalMilliseconds = 50; -const anonIdPollingIntervalMaxAttempts = 100; // 50 * 100 = 5000 = 5 seconds - -/** - * Gather w.js anonymous cookie, tk_ai - * - * @return {?string} The anonymous cookie value, or null if it doesn't exist - */ -export const readAnonCookie = (): string | null => { - return cookieParse( document.cookie ).tk_ai || null; -}; - -/** - * Initializes the anonId: - * - Polls for AnonId receival - * - Should only be called once at startup - * - Happens to be safe to call multiple times if it is necessary to reset the anonId - something like this was necessary for testing. - * - * This purely for boot-time initialization, in usual circumstances it will be retrieved within 100-300ms, it happens in parallel booting - * so should only delay experiment loading that much for boot-time experiments. In some circumstances such as a very slow connection this - * can take a lot longer. - * - * The state of initializeAnonIdPromise should be used rather than the return of this function. - * The return is only avaliable to make this easier to test. - * - * Throws on error. - * - * @return {Promise} The anonymous cookie value, or null if it doesn't exist - */ -export const initializeAnonId = async (): Promise< string | null > => { - let attempt = 0; - initializeAnonIdPromise = new Promise( res => { - const poll = () => { - const anonId = readAnonCookie(); - if ( typeof anonId === 'string' && anonId !== '' ) { - res( anonId ); - return; - } - - if ( anonIdPollingIntervalMaxAttempts - 1 <= attempt ) { - res( null ); - return; - } - attempt += 1; - setTimeout( poll, anonIdPollingIntervalMilliseconds ); - }; - poll(); - } ); - - return initializeAnonIdPromise; -}; - -export const getAnonId = async (): Promise< string | null > => { - return await initializeAnonIdPromise; -}; diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/assignment.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/assignment.ts deleted file mode 100644 index 80bd7d8f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/assignment.ts +++ /dev/null @@ -1,29 +0,0 @@ -import apiFetch from '@wordpress/api-fetch'; -import { addQueryArgs } from '@wordpress/url'; - -const fetchExperimentAssignment = - ( asConnectedUser = false ) => - async ( { - experimentName, - anonId, - }: { - experimentName: string; - anonId: string | null; - } ): Promise< unknown > => { - if ( ! anonId ) { - throw new Error( `Tracking is disabled, can't fetch experimentAssignment` ); - } - - const params = { - experiment_name: experimentName, - anon_id: anonId ?? undefined, - as_connected_user: asConnectedUser, - }; - - const assignmentsRequestUrl = addQueryArgs( 'jetpack/v4/explat/assignments', params ); - - return await apiFetch( { path: assignmentsRequestUrl } ); - }; - -export const fetchExperimentAssignmentAnonymously = fetchExperimentAssignment( false ); -export const fetchExperimentAssignmentWithAuth = fetchExperimentAssignment( true ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/error.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/error.ts deleted file mode 100644 index 84c19118..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/error.ts +++ /dev/null @@ -1,39 +0,0 @@ -/** - * Internal dependencies - */ -import { isDevelopmentMode } from './utils'; - -export const logError = ( error: Record< string, string > & { message: string } ): void => { - const onLoggingError = ( e: unknown ) => { - if ( isDevelopmentMode ) { - console.error( '[ExPlat] Unable to send error to server:', e ); // eslint-disable-line no-console - } - }; - - try { - const { message, ...properties } = error; - const logStashError = { - message, - properties: { - ...properties, - context: 'explat', - explat_client: 'jetpack', - }, - }; - - if ( isDevelopmentMode ) { - console.error( '[ExPlat] ', error.message, error ); // eslint-disable-line no-console - } else { - const body = new window.FormData(); - body.append( 'error', JSON.stringify( logStashError ) ); - window - .fetch( 'https://public-api.wordpress.com/rest/v1.1/js-error', { - method: 'POST', - body, - } ) - .catch( onLoggingError ); - } - } catch ( e ) { - onLoggingError( e ); - } -}; diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/index.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/index.ts deleted file mode 100644 index b21c993f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/index.ts +++ /dev/null @@ -1,51 +0,0 @@ -/** - * External dependencies - */ -import { createExPlatClient } from '@automattic/explat-client'; -import createExPlatClientReactHelpers from '@automattic/explat-client-react-helpers'; -/** - * Internal dependencies - */ -import { getAnonId, initializeAnonId } from './anon'; -import { - fetchExperimentAssignmentAnonymously, - fetchExperimentAssignmentWithAuth, -} from './assignment'; -import { logError } from './error'; -import { isDevelopmentMode } from './utils'; - -export const initializeExPlat = (): void => { - initializeAnonId().catch( e => logError( { message: e.message } ) ); -}; - -initializeExPlat(); - -const exPlatClient = createExPlatClient( { - fetchExperimentAssignment: fetchExperimentAssignmentAnonymously, - getAnonId, - logError, - isDevelopmentMode, -} ); - -export const { loadExperimentAssignment, dangerouslyGetExperimentAssignment } = exPlatClient; - -export const { useExperiment, Experiment, ProvideExperimentData } = - createExPlatClientReactHelpers( exPlatClient ); - -const exPlatClientWithAuth = createExPlatClient( { - fetchExperimentAssignment: fetchExperimentAssignmentWithAuth, - getAnonId, - logError, - isDevelopmentMode, -} ); - -export const { - loadExperimentAssignment: loadExperimentAssignmentWithAuth, - dangerouslyGetExperimentAssignment: dangerouslyGetExperimentAssignmentWithAuth, -} = exPlatClientWithAuth; - -export const { - useExperiment: useExperimentWithAuth, - Experiment: ExperimentWithAuth, - ProvideExperimentData: ProvideExperimentDataWithAuth, -} = createExPlatClientReactHelpers( exPlatClientWithAuth ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/utils.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/utils.ts deleted file mode 100644 index 75694463..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-explat/src/client/utils.ts +++ /dev/null @@ -1,4 +0,0 @@ -/** - * Boolean determining if environment is development. - */ -export const isDevelopmentMode = process.env.NODE_ENV === 'development'; diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/CHANGELOG.md deleted file mode 100644 index 19fe45eb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/CHANGELOG.md +++ /dev/null @@ -1,111 +0,0 @@ -# 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). - -## [0.4.6] - 2025-03-21 -### Changed -- Internal updates. - -## [0.4.5] - 2025-03-17 -### Changed -- Internal updates. - -## [0.4.4] - 2025-03-12 -### Changed -- Internal updates. - -## [0.4.3] - 2025-03-05 -### Changed -- Internal updates. - -## [0.4.2] - 2025-02-24 -### Changed -- Update dependencies. - -## [0.4.1] - 2024-11-25 -### Changed -- Update package dependencies. [#40258] - -## [0.4.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.3.1] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -### Fixed -- Fix PHPUnit coverage warnings. [#39989] - -## [0.3.0] - 2024-09-23 -### Added -- IP Utils: added support for CIDR ranges. [#39425] - -## [0.2.3] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [0.2.2] - 2024-03-12 -### Changed -- Internal updates. - -## [0.2.1] - 2023-11-21 -### Changed -- Added a note of non-usage of PHP8+ functions yet. [#34137] - -## [0.2.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [0.1.6] - 2023-09-19 - -- Minor internal updates. - -## [0.1.5] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [0.1.4] - 2023-05-29 -### Changed -- Internal updates. - -## [0.1.3] - 2023-05-11 - -- Updated package dependencies - -## [0.1.2] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.1.1] - 2023-03-28 -### Changed -- Update README.md [#28401] - -## 0.1.0 - 2023-02-28 -### Added -- Added a utility function to extract an array of IP addresses from a given string. [#29131] -- Add jetpack-ip package functionality [#28846] -- Initialized the package. [#28765] - -[0.4.6]: https://github.com/automattic/jetpack-ip/compare/v0.4.5...v0.4.6 -[0.4.5]: https://github.com/automattic/jetpack-ip/compare/v0.4.4...v0.4.5 -[0.4.4]: https://github.com/automattic/jetpack-ip/compare/v0.4.3...v0.4.4 -[0.4.3]: https://github.com/automattic/jetpack-ip/compare/v0.4.2...v0.4.3 -[0.4.2]: https://github.com/automattic/jetpack-ip/compare/v0.4.1...v0.4.2 -[0.4.1]: https://github.com/automattic/jetpack-ip/compare/v0.4.0...v0.4.1 -[0.4.0]: https://github.com/automattic/jetpack-ip/compare/v0.3.1...v0.4.0 -[0.3.1]: https://github.com/automattic/jetpack-ip/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/automattic/jetpack-ip/compare/v0.2.3...v0.3.0 -[0.2.3]: https://github.com/automattic/jetpack-ip/compare/v0.2.2...v0.2.3 -[0.2.2]: https://github.com/automattic/jetpack-ip/compare/v0.2.1...v0.2.2 -[0.2.1]: https://github.com/automattic/jetpack-ip/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/automattic/jetpack-ip/compare/v0.1.6...v0.2.0 -[0.1.6]: https://github.com/automattic/jetpack-ip/compare/v0.1.5...v0.1.6 -[0.1.5]: https://github.com/automattic/jetpack-ip/compare/v0.1.4...v0.1.5 -[0.1.4]: https://github.com/automattic/jetpack-ip/compare/v0.1.3...v0.1.4 -[0.1.3]: https://github.com/automattic/jetpack-ip/compare/v0.1.2...v0.1.3 -[0.1.2]: https://github.com/automattic/jetpack-ip/compare/v0.1.1...v0.1.2 -[0.1.1]: https://github.com/automattic/jetpack-ip/compare/v0.1.0...v0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/composer.json deleted file mode 100644 index 733cc629..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/composer.json +++ /dev/null @@ -1,50 +0,0 @@ -{ - "name": "automattic/jetpack-ip", - "description": "Utilities for working with IP addresses.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-ip", - "changelogger": { - "link-template": "https://github.com/automattic/jetpack-ip/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "0.4.x-dev" - }, - "textdomain": "jetpack-ip", - "version-constants": { - "::PACKAGE_VERSION": "src/class-utils.php" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php deleted file mode 100644 index 0b2318aa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php +++ /dev/null @@ -1,543 +0,0 @@ -trusted_header ) && isset( $_SERVER[ $trusted_header_data->trusted_header ] ) ) { - $ip = wp_unslash( $_SERVER[ $trusted_header_data->trusted_header ] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- clean_ip does it below. - $segments = $trusted_header_data->segments; - $reverse_order = $trusted_header_data->reverse; - } else { - $ip = isset( $_SERVER['REMOTE_ADDR'] ) ? wp_unslash( $_SERVER['REMOTE_ADDR'] ) : null; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- clean_ip does it below. - } - - if ( ! $ip ) { - return false; - } - - $ips = explode( ',', $ip ); - if ( ! isset( $segments ) || ! $segments ) { - $segments = 1; - } - if ( isset( $reverse_order ) && $reverse_order ) { - $ips = array_reverse( $ips ); - } - $ip_count = count( $ips ); - if ( 1 === $ip_count ) { - return self::clean_ip( $ips[0] ); - } elseif ( $ip_count >= $segments ) { - $the_one = $ip_count - $segments; - return self::clean_ip( $ips[ $the_one ] ); - } else { - return self::clean_ip( isset( $_SERVER['REMOTE_ADDR'] ) ? wp_unslash( $_SERVER['REMOTE_ADDR'] ) : null ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- clean_ip does it. - } - } - - /** - * Clean IP address. - * - * @param string $ip The IP address to clean. - * @return string|false The cleaned IP address. - */ - public static function clean_ip( $ip ) { - - // Some misconfigured servers give back extra info, which comes after "unless". - $ips = explode( ' unless ', $ip ); - $ip = $ips[0]; - - $ip = strtolower( trim( $ip ) ); - - // Check for IPv4 with port. - if ( preg_match( '/^(\d+\.\d+\.\d+\.\d+):\d+$/', $ip, $matches ) ) { - $ip = $matches[1]; - } - - // Check for IPv6 (or IPvFuture) with brackets and optional port. - if ( preg_match( '/^\[([a-z0-9\-._~!$&\'()*+,;=:]+)\](?::\d+)?$/', $ip, $matches ) ) { - $ip = $matches[1]; - } - - // Check for IPv4 IP cast as IPv6. - if ( preg_match( '/^::ffff:(\d+\.\d+\.\d+\.\d+)$/', $ip, $matches ) ) { - $ip = $matches[1]; - } - - // Validate and return. - return filter_var( $ip, FILTER_VALIDATE_IP ) ? $ip : false; - } - - /** - * Checks an IP to see if it is within a private range. - * - * @param int $ip IP address. - * @return bool True if IP address is private, false otherwise. - */ - public static function ip_is_private( $ip ) { - // We are dealing with ipv6, so we can simply rely on filter_var. - // Note: str_contains() is not used here, as wp-includes/compat.php may not be loaded in this file. - if ( false === strpos( $ip, '.' ) ) { - return ! filter_var( $ip, FILTER_VALIDATE_IP, FILTER_FLAG_NO_PRIV_RANGE | FILTER_FLAG_NO_RES_RANGE ); - } - // We are dealing with ipv4. - $private_ip4_addresses = array( - '10.0.0.0|10.255.255.255', // Single class A network. - '172.16.0.0|172.31.255.255', // 16 contiguous class B network. - '192.168.0.0|192.168.255.255', // 256 contiguous class C network. - '169.254.0.0|169.254.255.255', // Link-local address also referred to as Automatic Private IP Addressing. - '127.0.0.0|127.255.255.255', // localhost. - ); - $long_ip = ip2long( $ip ); - if ( -1 !== $long_ip ) { - foreach ( $private_ip4_addresses as $pri_addr ) { - list ( $start, $end ) = explode( '|', $pri_addr ); - if ( $long_ip >= ip2long( $start ) && $long_ip <= ip2long( $end ) ) { - return true; - } - } - } - return false; - } - - /** - * Validate an IP address. - * - * @param string $ip IP address. - * @return bool True if valid, false otherwise. - */ - private static function validate_ip_address( string $ip ) { - return filter_var( $ip, FILTER_VALIDATE_IP ); - } - - /** - * Validate an array of IP addresses. - * - * @param array $ips List of IP addresses. - * @return bool True if all IPs are valid, false otherwise. - */ - private static function validate_ip_addresses( array $ips ) { - foreach ( $ips as $ip ) { - if ( ! self::validate_ip_address( $ip ) ) { - return false; - } - } - return true; - } - - /** - * Uses inet_pton if available to convert an IP address to a binary string. - * Returns false if an invalid IP address is given. - * - * @param mixed $ip IP address. - * @return int|string|bool - */ - public static function convert_ip_address( $ip ) { - return inet_pton( $ip ); - } - - /** - * Determines the IP version of the given IP address. - * - * @param string $ip IP address. - * @return string|false 'ipv4', 'ipv6', or false if invalid. - */ - public static function get_ip_version( $ip ) { - if ( filter_var( $ip, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4 ) ) { - return 'ipv4'; - } elseif ( filter_var( $ip, FILTER_VALIDATE_IP, FILTER_FLAG_IPV6 ) ) { - return 'ipv6'; - } else { - return false; - } - } - - /** - * Extracts IP addresses from a given string. - * - * Supports IPv4 and IPv6 ranges in both hyphen and CIDR notation. - * - * @param string $ips List of IPs. - * @return array List of valid IP addresses or ranges. - */ - public static function get_ip_addresses_from_string( $ips ) { - // Split the string by spaces, commas, and semicolons. - $ips = preg_split( '/[\s,;]/', (string) $ips ); - - $result = array(); - - foreach ( $ips as $ip ) { - $ip = trim( $ip ); - - // Check for CIDR notation - if ( strpos( $ip, '/' ) !== false ) { - if ( self::validate_cidr( $ip ) ) { - $result[] = $ip; - } - continue; - } - - // Validate both IP values from the hyphen range. - $range = explode( '-', $ip ); - if ( count( $range ) === 2 ) { - if ( self::validate_ip_range( $range[0], $range[1] ) ) { - $result[] = $ip; - } - continue; - } - - // Validate the single IP value. - if ( filter_var( $ip, FILTER_VALIDATE_IP ) !== false ) { - $result[] = $ip; - } - } - - return $result; - } - - /** - * Validates CIDR notation for IPv4 and IPv6 addresses. - * - * @param string $cidr CIDR notation IP address. - * @return bool True if valid, false otherwise. - */ - public static function validate_cidr( $cidr ) { - // Split the CIDR notation into IP address and prefix length using the '/' separator. - $parts = explode( '/', $cidr ); - if ( count( $parts ) !== 2 ) { - return false; // Invalid CIDR notation if it doesn't contain exactly one '/'. - } - - list( $ip, $netmask ) = $parts; - - // Validate the IP address. - if ( ! filter_var( $ip, FILTER_VALIDATE_IP ) ) { - return false; - } - - $ip_version = self::get_ip_version( $ip ); - if ( ! $ip_version ) { - return false; // Invalid IP address. - } - - // Validate the netmask based on the IP version. - if ( ! self::validate_netmask( $netmask, $ip_version ) ) { - return false; - } - - return true; - } - - /** - * Checks if an IP address is within a CIDR range. - * Supports both IPv4 and IPv6. - * - * @param string $ip IP address. - * @param string $cidr CIDR notation IP range. - * @return bool True if IP is within the range, false otherwise. - */ - public static function ip_in_cidr( $ip, $cidr ) { - // Parse the CIDR notation to extract the base IP address and netmask prefix length. - $parsed_cidr = self::parse_cidr( $cidr ); - if ( ! $parsed_cidr ) { - return false; - } - list( $range, $netmask ) = $parsed_cidr; - - // Determine the IP version (IPv4 or IPv6) of both the input IP and the CIDR range IP. - $ip_version = self::get_ip_version( $ip ); - $range_version = self::get_ip_version( $range ); - - // Ensure both IP addresses are valid and of the same IP version. - if ( ! $ip_version || ! $range_version || $ip_version !== $range_version ) { - return false; - } - - // Validate the netmask based on the IP version. - if ( ! self::validate_netmask( $netmask, $ip_version ) ) { - return false; - } - - if ( $ip_version === 'ipv4' ) { - return self::ip_in_ipv4_cidr( $ip, $range, $netmask ); - } else { - return self::ip_in_ipv6_cidr( $ip, $range, $netmask ); - } - } - - /** - * Parses the CIDR notation into network address and netmask. - * - * @param string $cidr CIDR notation IP range. - * @return array|false Array containing network address and netmask, or false on failure. - */ - public static function parse_cidr( $cidr ) { - $cidr_parts = explode( '/', $cidr, 2 ); - if ( count( $cidr_parts ) !== 2 ) { - return false; // Invalid CIDR notation - } - list( $range, $netmask ) = $cidr_parts; - - // Determine IP version - $ip_version = self::get_ip_version( $range ); - if ( ! $ip_version ) { - return false; // Invalid IP address - } - - // Validate netmask range - if ( ! self::validate_netmask( $netmask, $ip_version ) ) { - return false; // Netmask out of range - } - - return array( $range, (int) $netmask ); - } - - /** - * Validates the netmask based on IP version. - * - * @param string|int $netmask Netmask value. - * @param string $ip_version 'ipv4' or 'ipv6'. - * @return bool True if valid, false otherwise. - */ - public static function validate_netmask( $netmask, $ip_version ) { - // Ensure that $netmask is an integer - if ( ! ctype_digit( (string) $netmask ) ) { - return false; - } - $netmask = (int) $netmask; - - // Validate the netmask based on the IP version. - if ( $ip_version === 'ipv4' ) { - return ( $netmask >= 0 && $netmask <= 32 ); - } elseif ( $ip_version === 'ipv6' ) { - return ( $netmask >= 0 && $netmask <= 128 ); - } else { - return false; - } - } - - /** - * Checks if an IPv4 address is within a CIDR range. - * - * @param string $ip IPv4 address to check. - * @param string $range IPv4 network address. - * @param int $netmask Netmask value. - * @return bool True if IP is within the range, false otherwise. - */ - public static function ip_in_ipv4_cidr( $ip, $range, $netmask ) { - // Validate arguments. - if ( ! self::validate_ip_addresses( array( $ip, $range ) ) || ! self::validate_netmask( $netmask, 'ipv4' ) ) { - return false; // Invalid IP address or netmask. - } - - // Convert IP addresses from their dotted representation to 32-bit unsigned integers. - $ip_long = ip2long( $ip ); - $range_long = ip2long( $range ); - - // Check if the conversion was successful. - if ( $ip_long === false || $range_long === false ) { - return false; // One of the IP addresses is invalid. - } - - /** - * Create the subnet mask as a 32-bit unsigned integer. - * - * Explanation: - * - (32 - $netmask) calculates the number of host bits (the bits not used for the network address). - * - (1 << (32 - $netmask)) shifts the number 1 left by the number of host bits. - * This results in a number where there is a single 1 followed by zeros equal to the number of host bits. - * - Subtracting 1 gives us a number where the host bits are all 1s. - * - Applying the bitwise NOT operator (~) inverts the bits, turning all host bits to 0 and network bits to 1. - * This results in the subnet mask having 1s in the network portion and 0s in the host portion. - * - * Example for netmask = 24: - * - (32 - 24) = 8 - * - (1 << 8) = 256 (binary: 00000000 00000000 00000001 00000000) - * - 256 - 1 = 255 (binary: 00000000 00000000 00000000 11111111) - * - ~255 = 4294967040 (binary: 11111111 11111111 11111111 00000000) - */ - $mask = ~ ( ( 1 << ( 32 - $netmask ) ) - 1 ); - - /** - * Use bitwise AND to apply the subnet mask to both the IP address and the network address. - * - ($ip_long & $mask) isolates the network portion of the IP address. - * - ($range_long & $mask) isolates the network portion of the CIDR range. - * - If both network portions are equal, the IP address belongs to the same subnet and is within the CIDR range. - */ - return ( $ip_long & $mask ) === ( $range_long & $mask ); - } - - /** - * Checks if an IPv6 address is within a CIDR range. - * - * @param string $ip IPv6 address to check. - * @param string $range IPv6 network address. - * @param int $netmask Netmask value. - * @return bool True if IP is within the range, false otherwise. - */ - public static function ip_in_ipv6_cidr( $ip, $range, $netmask ) { - // Validate arguments. - if ( ! self::validate_ip_addresses( array( $ip, $range ) ) || ! self::validate_netmask( $netmask, 'ipv6' ) ) { - return false; // Invalid IP address or netmask. - } - - // Convert IP addresses from their textual representation to binary strings. - $ip_bin = inet_pton( $ip ); - $range_bin = inet_pton( $range ); - - // Check if the conversion was successful. - if ( $ip_bin === false || $range_bin === false ) { - return false; // One of the IP addresses is invalid. - } - - /** - * Calculate the subnet mask in binary form. - * - * IPv6 addresses are 128 bits long. - * The netmask defines how many bits are set to 1 in the subnet mask. - * - * - $netmask_full_bytes: Number of full bytes (each 8 bits) that are all 1s. - * - $netmask_remainder_bits: Remaining bits (less than 8) that need to be set to 1. - * - * For example, if $netmask = 65: - * - $netmask_full_bytes = floor(65 / 8) = 8 (since 8 * 8 = 64 bits) - * - $netmask_remainder_bits = 65 % 8 = 1 (1 bit remaining) - * - * We'll construct the subnet mask by: - * - Starting with $netmask_full_bytes of 0xff (11111111 in binary). - * - Adding a byte where the first $netmask_remainder_bits bits are 1, rest are 0. - * - Padding the rest with zeros to make it 16 bytes (128 bits) long. - */ - - // Number of full bytes (each full byte is 8 bits) in the netmask. - $netmask_full_bytes = (int) ( $netmask / 8 ); - - // Number of remaining bits in the last byte of the netmask. - $netmask_remainder_bits = $netmask % 8; - - // Start with a string of $netmask_full_bytes of 0xff bytes (each byte is 8 bits set to 1). - $netmask_bin = str_repeat( "\xff", $netmask_full_bytes ); - - if ( $netmask_remainder_bits > 0 ) { - // Create the last byte with $netmask_remainder_bits bits set to 1 from the left. - // - str_repeat('1', $netmask_remainder_bits): creates a string with the required number of '1's. - // - str_pad(...): pads the string on the right with '0's to make it 8 bits. - // - bindec(...): converts the binary string to a decimal number. - // - chr(...): gets the character corresponding to the byte value. - $last_byte = chr( bindec( str_pad( str_repeat( '1', $netmask_remainder_bits ), 8, '0', STR_PAD_RIGHT ) ) ); - // Append the last byte to the netmask binary string. - $netmask_bin .= $last_byte; - } - - // Pad the netmask binary string to 16 bytes (128 bits) with zeros (\x00). - $netmask_bin = str_pad( $netmask_bin, 16, "\x00" ); - - /** - * Use bitwise AND to apply the subnet mask to both the IP address and the network address. - * - ($ip_bin & $netmask_bin) isolates the network portion of the IP address. - * - ($range_bin & $netmask_bin) isolates the network portion of the CIDR range. - * - If both network portions are equal, the IP address belongs to the same subnet and is within the CIDR range. - */ - return ( $ip_bin & $netmask_bin ) === ( $range_bin & $netmask_bin ); - } - - /** - * Validates the low and high IP addresses of a range. - * - * Now supports IPv6 addresses. - * - * @param string $range_low Low IP address. - * @param string $range_high High IP address. - * @return bool True if the range is valid, false otherwise. - */ - public static function validate_ip_range( $range_low, $range_high ) { - // Validate that both IP addresses are valid. - if ( self::validate_ip_addresses( array( $range_low, $range_high ) ) === false ) { - return false; - } - - // Ensure both IPs are of the same version - $range_low_ip_version = self::get_ip_version( $range_low ); - $range_high_ip_version = self::get_ip_version( $range_high ); - - if ( $range_low_ip_version !== $range_high_ip_version || ! $range_low_ip_version || ! $range_high_ip_version ) { - return false; // Invalid or mixed IP versions. - } - - // Convert IP addresses to their packed binary representation. - $ip_low = inet_pton( $range_low ); - $ip_high = inet_pton( $range_high ); - - // Check if the conversion was successful. - if ( false === $ip_low || false === $ip_high ) { - return false; - } - - // Compare the binary representations to ensure the low IP is not greater than the high IP. - if ( strcmp( $ip_low, $ip_high ) > 0 ) { - return false; - } - - return true; - } - - /** - * Checks that a given IP address is within a given range. - * - * Supports CIDR notation and hyphenated ranges for both IPv4 and IPv6. - * - * @param string $ip IP address. - * @param string $range_low Range low or CIDR notation. - * @param null|string $range_high Optional. Range high. Not used if $range_low is CIDR notation. - * @return bool - */ - public static function ip_address_is_in_range( $ip, $range_low, $range_high = null ) { - // Validate that all provided IP addresses are valid. - if ( $range_high !== null && ! self::validate_ip_addresses( array( $ip, $range_low, $range_high ) ) ) { - return false; - } else { - $range_low_parsed = self::parse_cidr( $range_low ); - if ( $range_low_parsed && ! self::validate_ip_addresses( array( $ip, $range_low_parsed[0] ) ) ) { - return false; - } - } - - if ( strpos( $range_low, '/' ) !== false ) { - // CIDR notation - if ( $range_high !== null ) { - // Invalid usage: CIDR notation with range high parameter - return false; - } - return self::ip_in_cidr( $ip, $range_low ); - } - - // Hyphenated range - if ( $range_high === null ) { - return false; // Invalid parameters - } - - $ip_num = inet_pton( $ip ); - $ip_low = inet_pton( $range_low ); - $ip_high = inet_pton( $range_high ); - if ( $ip_num && $ip_low && $ip_high && strcmp( $ip_num, $ip_low ) >= 0 && strcmp( $ip_num, $ip_high ) <= 0 ) { - return true; - } - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/CHANGELOG.md deleted file mode 100644 index 52cf2f9f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/CHANGELOG.md +++ /dev/null @@ -1,1060 +0,0 @@ -# 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). - -## [4.2.7] - 2025-03-24 -### Changed -- Allow JITM functionality to be enabled on Simple sites. [#41252] - -## [4.2.6] - 2025-03-21 -### Changed -- Internal updates. - -## [4.2.5] - 2025-03-18 -### Changed -- Update dependencies. [#42545] - -## [4.2.4] - 2025-03-17 -### Changed -- Internal updates. - -## [4.2.3] - 2025-03-17 -### Changed -- Internal updates. - -## [4.2.2] - 2025-03-12 -### Changed -- Internal updates. - -## [4.2.1] - 2025-03-05 -### Changed -- Internal updates. - -## [4.2.0] - 2025-03-03 -### Changed -- Replace more JITM jQuery Ajax calls with `@wordpress/api-fetch`. [#41990] -- Update package dependencies. [#42163] - -## [4.1.1] - 2025-02-24 -### Changed -- Refactor handling of JITM-approved screens. [#41748] - -## [4.1.0] - 2025-02-17 -### Changed -- Update AJAX calls to utilise @wordpress/api-fetch. [#41745] - -## [4.0.7] - 2025-02-12 -### Fixed -- Fix the query parameter used for JITM query strings. [#41542] - -## [4.0.6] - 2025-02-10 -### Changed -- Update package dependencies. [#41491] - -## [4.0.5] - 2025-02-03 -### Changed -- Update package dependencies. [#41286] -- Update the WooCommerce logo in Woo JITMs. [#41322] - -## [4.0.4] - 2025-01-20 -### Changed -- Updated package dependencies. [#41099] - -## [4.0.3] - 2024-12-16 -### Changed -- Updated package dependencies. [#40564] - -## [4.0.2] - 2024-12-04 -### Changed -- Updated package dependencies. [#40363] - -## [4.0.1] - 2024-11-25 -### Changed -- Updated package dependencies. [#40258] [#40288] - -## [4.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [3.1.29] - 2024-11-11 -### Changed -- Updated package dependencies. [#39999] - -## [3.1.28] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [3.1.27] - 2024-10-29 -### Changed -- Internal updates. - -## [3.1.26] - 2024-10-14 -### Changed -- Only include `wp-polyfill` as a script dependency when needed. [#39629] - -## [3.1.25] - 2024-10-10 -### Changed -- Updated package dependencies. [#39707] - -## [3.1.24] - 2024-10-07 -### Changed -- Updated package dependencies. [#39594] - -## [3.1.23] - 2024-09-23 -### Changed -- Update dependencies. - -## [3.1.22] - 2024-09-10 -### Changed -- Updated package dependencies. [#39302] - -## [3.1.21] - 2024-09-05 -### Changed -- Update dependencies. - -## [3.1.20] - 2024-09-05 -### Changed -- Updated package dependencies. [#39176] - -## [3.1.19] - 2024-08-29 -### Changed -- Updated package dependencies. [#39111] - -## [3.1.18] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [3.1.17] - 2024-08-19 -### Fixed -- Lossless image optimization for images (should improve performance with no visible changes). [#38750] - -## [3.1.16] - 2024-08-15 -### Changed -- Updated package dependencies. [#38662] - -## [3.1.15] - 2024-08-08 -### Fixed -- JITM: Fix background for RTL languages. [#38706] - -## [3.1.14] - 2024-07-18 -### Changed -- Update margins on jitms in my jetpack [#38283] - -## [3.1.13] - 2024-07-03 -### Changed -- Updated package dependencies. [#38132] - -## [3.1.12] - 2024-06-05 -### Changed -- Updated package dependencies. [#37669] - -## [3.1.11] - 2024-05-16 -### Changed -- Updated package dependencies. [#37379] - -## [3.1.10] - 2024-05-06 -### Changed -- Updated package dependencies. [#37147] - -## [3.1.9] - 2024-04-26 -### Changed -- Internal updates. - -## [3.1.8] - 2024-04-25 -### Changed -- Internal updates. - -## [3.1.7] - 2024-04-22 -### Changed -- Internal updates. - -## [3.1.6] - 2024-04-15 -### Changed -- Internal updates. - -## [3.1.5] - 2024-04-11 -### Changed -- Internal updates. - -## [3.1.4] - 2024-04-08 -### Changed -- Updated package dependencies. [#36760] - -## [3.1.3] - 2024-03-27 -### Changed -- Updated package dependencies. [#36585] - -## [3.1.2] - 2024-03-25 -### Changed -- Update Phan baselines [#36441] - -## [3.1.1] - 2024-03-14 -### Changed -- Internal updates. - -## [3.1.0] - 2024-03-12 -### Changed -- Performance: only enqueue the JITM JavaScript on pages where it will be used. [#35997] -- Updated package dependencies. [#36325] - -## [3.0.5] - 2024-03-04 -### Changed -- Updated package dependencies. [#36095] - -## [3.0.4] - 2024-02-13 -### Changed -- Updated package dependencies. [#35608] - -## [3.0.3] - 2024-02-05 -### Changed -- Updated package dependencies. [#35384] - -## [3.0.2] - 2024-01-04 -### Changed -- Updated package dependencies. [#34815] - -## [3.0.1] - 2023-12-03 -### Changed -- Updated package dependencies. [#34411] - -## [3.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -### Removed -- Removed the Partner package requirement. Relying on the Connection package instead. [#33832] - -## [2.5.3] - 2023-11-14 -### Changed -- Updated package dependencies. [#34093] - -## [2.5.2] - 2023-11-03 - -## [2.5.1] - 2023-10-19 -### Changed -- Updated package dependencies. [#33687] - -## [2.5.0] - 2023-10-10 -### Added -- JITMs can now redirect to a specific Jetpack settings page. [#32826] - -### Changed -- Update color of WooCommerce logo. [#33491] -- Updated package dependencies. [#33428] - -## [2.4.0] - 2023-09-28 -### Changed -- Moved tracking for JITM buttons into JITM script, added message_path property [#33252] - -## [2.3.19] - 2023-09-19 - -- Minor internal updates. - -## [2.3.18] - 2023-09-04 -### Changed -- Updated package dependencies. [#32803] - -## [2.3.17] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [2.3.16] - 2023-08-21 -### Fixed -- Update secondary button styling [#32503] - -## [2.3.15] - 2023-08-09 -### Changed -- Updated package dependencies. [#32166] - -## [2.3.14] - 2023-07-25 -### Changed -- Updated package dependencies. [#32040] - -## [2.3.13] - 2023-07-17 -### Changed -- Generate query string when using the WPCOM API to fetch JITMs [#31809] - -## [2.3.12] - 2023-07-11 -### Changed -- Updated package dependencies. [#31785] - -## [2.3.11] - 2023-07-05 -### Changed -- Updated package dependencies. [#31659] - -## [2.3.10] - 2023-06-23 -### Changed -- Updated package dependencies. [#31468] - -## [2.3.9] - 2023-06-06 -### Changed -- Updated package dependencies. [#31129] - -## [2.3.8] - 2023-05-08 -### Added -- JITM: Add jetpack-videopress to JITM refetch on hashchange list [#30465] - -## [2.3.7] - 2023-05-02 -### Changed -- Updated package dependencies. [#30375] - -## [2.3.6] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [2.3.5] - 2023-04-04 -### Added -- Add external link icons in JITM [#29654] - -### Changed -- Updated package dependencies. [#29854] - -## [2.3.4] - 2023-03-28 -### Fixed -- JITM: Fix button overflow when text length is too big [#29749] - -## [2.3.3] - 2023-03-27 -### Changed -- JITM: Update styles [#29709] - -## [2.3.2] - 2023-03-20 -### Changed -- Updated package dependencies. [#29471] - -## [2.3.1] - 2023-03-08 -### Changed -- Updated package dependencies. [#29216] - -## [2.3.0] - 2023-02-20 -### Changed -- Moving deleting connection owner notice from JITM to Connection package. [#28516] - -## [2.2.42] - 2023-02-15 -### Changed -- Update to React 18. [#28710] - -## [2.2.41] - 2023-02-06 -### Fixed -- JITM: minor fix for styles on Safari browser. - -## [2.2.40] - 2023-01-30 -### Changed -- Updated styles for Just in Time Messages (notices) [#27515] - -## [2.2.39] - 2023-01-25 -### Changed -- Minor internal updates. - -## [2.2.38] - 2023-01-23 -### Fixed -- Prevent the activation page from displaying the JP License Activation JITM. [#27959] - -## [2.2.37] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [2.2.36] - 2022-12-27 -### Removed -- Remove src/js files from final bundle [#27930] - -## [2.2.35] - 2022-12-02 -### Changed -- Updated package dependencies. [#27696] - -## [2.2.34] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [2.2.33] - 2022-11-08 -### Changed -- Updated package dependencies. [#27289] - -## [2.2.32] - 2022-11-07 -### Changed -- Updated package dependencies. [#27278] - -## [2.2.31] - 2022-11-01 -### Changed -- Updated package dependencies. [#27196] - -## [2.2.30] - 2022-10-25 -### Changed -- Updated package dependencies. [#26705] - -## [2.2.29] - 2022-10-13 -### Changed -- Updated package dependencies. [#26791] - -## [2.2.28] - 2022-10-05 -### Changed -- Updated package dependencies. [#26568] - -## [2.2.27] - 2022-09-08 -### Changed -- Updated package dependencies. - -## [2.2.26] - 2022-08-29 -### Changed -- Updated package dependencies. - -## [2.2.25] - 2022-08-25 -### Changed -- Updated package dependencies. [#25814] - -## [2.2.24] - 2022-08-23 -### Added -- Add custom styling rules for the JITMs displayed in My Jetpack. [#22452] -- Updated JITM readme. [#25739] - -### Changed -- Updated package dependencies. [#25628] - -## [2.2.23] - 2022-08-03 -### Changed -- Updated package dependencies. [#25300, #25315] - -## [2.2.22] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [2.2.21] - 2022-07-12 -### Changed -- Updated package dependencies. - -## [2.2.20] - 2022-06-21 -### Changed -- Renaming master to trunk. [#24661] - -## [2.2.19] - 2022-06-14 -### Changed -- Updated package dependencies. [#24529] - -## [2.2.18] - 2022-06-08 -### Changed -- Reorder JS imports for `import/order` eslint rule. [#24601] - -## [2.2.17] - 2022-05-18 -### Changed -- Updated package dependencies [#24372] - -## [2.2.16] - 2022-05-10 -### Changed -- Updated package dependencies. [#24302] - -## [2.2.15] - 2022-05-04 -### Changed -- Remove use of `pnpx` in preparation for pnpm 7.0. [#24210] -- Updated package dependencies. [#24095] - -### Deprecated -- Moved the options class into Connection. [#24095] - -## [2.2.14] - 2022-04-26 -### Changed -- Updated package dependencies. -- Update package.json metadata. - -## [2.2.13] - 2022-04-19 -### Changed -- PHPCS: Fix `WordPress.Security.ValidatedSanitizedInput` - -## [2.2.12] - 2022-04-12 -### Changed -- Updated package dependencies. - -## [2.2.11] - 2022-04-06 -### Changed -- Updated package dependencies - -### Removed -- Removed tracking dependency. - -## [2.2.10] - 2022-03-29 -### Changed -- Updated package dependencies. - -## [2.2.9] - 2022-03-23 -### Changed -- Updated package dependencies. - -## [2.2.8] - 2022-03-02 -### Changed -- Updated package dependencies - -## [2.2.7] - 2022-02-22 -### Changed -- Updated package dependencies. - -## [2.2.6] - 2022-02-16 -### Changed -- Updated package dependencies. - -## [2.2.5] - 2022-02-09 -### Changed -- Updated package dependencies. - -## [2.2.4] - 2022-02-02 -### Changed -- Build: remove unneeded files from production build. -- Update use of old jQuery interfaces - -## [2.2.3] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [2.2.2] - 2022-01-18 -### Changed -- General: update required node version to v16.13.2 - -## [2.2.1] - 2022-01-11 -### Changed -- Updated package dependencies. - -## [2.2.0] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies. -- Updated package textdomain from `jetpack` to `jetpack-jitm`. - -## [2.1.1] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [2.1.0] - 2021-11-30 -### Added -- Add proper JS and CSS builder. -- Adds filters to allow sideloading of the Jetpack Backup plugin through JITMs. -- JITM: Added ability to sideload Jetpack Boost plugin. - -### Changed -- Add `output.filename` in Webpack config to override changed default. -- Colors: update Jetpack Primary color to match latest brand book. - -### Fixed -- JITM: wrap CTA below text on small viewports - -## [2.0.8] - 2021-11-23 -### Changed -- Updated package dependencies. - -## [2.0.7] - 2021-11-16 -### Added -- Use monorepo `validate-es` script to validate Webpack builds. - -### Changed -- Updated package dependencies. - -## [2.0.6] - 2021-11-09 -### Changed -- Update webpack build config. - -## [2.0.5] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [2.0.4] - 2021-10-26 -### Changed -- Updated package dependencies. - -## [2.0.3] - 2021-10-19 -### Changed -- Updated package dependencies. - -## [2.0.2] - 2021-10-12 -### Changed -- Updated package dependencies - -## [2.0.1] - 2021-09-28 -### Changed -- Allow Node ^14.17.6 to be used in this project. This shouldn't change the behavior of the code itself. -- Updated package dependencies. - -## [2.0.0] - 2021-08-31 -### Changed -- Run composer update on test-php command instead of phpunit. -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- Update annotations versions. -- Updated package dependencies. -- Update to latest webpack, webpack-cli and calypso-build. -- Upgrade to Webpack 5. -- Use Node 16.7.0 in tooling. - -### Removed -- Removed IE11 support. - -## [1.16.2] - 2021-07-27 -### Changed -- Updated package dependencies. - -## [1.16.1] - 2021-06-29 -### Changed -- Update package dependencies. -- Update node version requirement to 14.16.1 -- Update the usage of Redirect lib and passes the unlinked param as a query argument. - -## [1.16.0] - 2021-05-25 -### Added -- JITM: allow the plugin to set the icon for pre-connection JITMs. -- JITM: move sync updated option hook to the JITM package. - -### Changed -- JITM: prevent JITMs from being registered more than once. -- JITM: remove jetpack-constants dependency from composer.json -- JITM: set the default values of the jetpack_just_in_time_msgs and jetpack_just_in_time_msg_cache filters to true. -- JITM: Use an action instead of a property to prevent JITMs from being registered multiple times -- JITM: Use the Device_Detection package to determine if the device is mobile. -- Updated package dependencies -- update jetpack-redirect dependency - -## [1.15.1] - 2021-05-03 -### Changed -- JITM: Use manager::get_authorization_url to obtain the authorization url in the user deletion notice. - -## [1.15.0] - 2021-04-27 -### Added -- Move JITM's REST API endpoints into the package - -### Changed -- Always display pre-connection JITMs, without the need to set a filter. -- Avoid wrapping text in the main CTA button. -- Bump JITM package version requirement. -- JITM: Update CTA redirect url with unlinked query arg to indicate current user is not connected. -- Update package dependencies. -- Use the a8c-mc-stats package to generate stats. - -## [1.14.1] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Use is_connected instead of is_active to instantiate Pre/Post_Connection_JITM -- Add a jetpack_pre_connection_jitms filter. -- Update colors to match upcoming WP 5.7 color changes -- Update Node to match latest LTS 12 -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.14.0] - 2021-02-23 - -- Recommendations: Hide JITMs when banner is displaying -- Setup Wizard: Remove setup wizard -- JITM: move jetpack-jitm.js to the JITM package -- CI: Make tests more generic - -## [1.13.5] - 2021-02-08 - -- Update dependencies to latest stable - -## [1.13.4] - 2021-01-28 - -- Update dependencies to latest stable - -## [1.13.3] - 2021-01-26 - -- Update dependencies to latest stable - -## [1.13.2] - 2021-01-26 - -- Update dependencies to latest stable - -## [1.13.1] - 2021-01-26 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.13.0] - 2021-01-05 - -- Update dependency brain/monkey to v2.6.0 -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.12.2] - 2020-12-09 - -- Update dependencies to latest stable - -## [1.12.1] - 2020-11-24 - -- Version packages for release - -## [1.12.0] - 2020-11-24 - -- Status: Introduce get_site_suffix method -- General: update minimum required version to WordPress 5.5 -- Updated PHPCS: Packages and Debugger - -## [1.11.2] - 2020-11-05 - -- Update dependencies to latest stable - -## [1.11.1] - 2020-10-29 - -- Update dependencies to latest stable - -## [1.11.0] - 2020-10-27 - -- JITM: add a Pre_Connection_JITM::generate_admin_url method -- JITM: use is_active from the connection package -- JITM: regenerate assets - -## [1.10.4] - 2020-10-14 - -- Update dependencies to latest stable - -## [1.10.3] - 2020-10-09 - -- Update dependencies to latest stable - -## [1.10.2] - 2020-10-06 - -- Update dependencies to latest stable - -## [1.10.1] - 2020-10-01 - -- Update dependencies to latest stable - -## [1.10.0] - 2020-09-29 - -- Update dependencies to latest stable - -## [1.9.1] - 2020-09-09 - -- Update dependencies to latest stable - -## [1.9.0] - 2020-08-26 - -- Compat: add new Creative Mail compat file -- Packages: Update filenames after #16810 -- CI: Try collect js coverage -- Docker: Add package testing shortcut - -## [1.8.2] - 2020-08-10 - -- Update dependencies to latest stable - -## [1.8.1] - 2020-08-10 - -- Update dependencies to latest stable - -## [1.8.0] - 2020-07-28 - -- Core Compat: Site Environment -- Core REST API: Add permission callback to delete_jitm_message endpoint - -## [1.7.2] - 2020-07-06 - -- Update dependencies to latest stable - -## [1.7.1] - 2020-07-01 - -- Update dependencies to latest stable - -## [1.7.0] - 2020-06-30 - -- PHPCS: Clean up the packages -- Hide pre-connection JITM on the posts page when few posts are published -- Jetpack Setup Wizard: Do not show pre-connection JITMs to non admins -- JITM: change 'setup' to 'set up' in pre-connection JITMs -- Pre-connection JITMS: Link to connect-in-place flow -- JITM: add Redirect use statement - -## [1.6.5] - 2020-06-01 - -- Hide pre-connection JITM on the posts page when few posts are published - -## [1.6.4] - 2020-06-01 - -- Update dependencies to latest stable - -## [1.6.3] - 2020-05-29 - -- Jetpack Setup Wizard: Do not show pre-connection JITMs to non admins - -## [1.6.2] - 2020-05-29 - -- JITM: change 'setup' to 'set up' in pre-connection JITMs -- Pre-connection JITMS: Link to connect-in-place flow - -## [1.6.1] - 2020-05-28 - -- JITM: add Redirect use statement - -## [1.6.0] - 2020-05-26 - -- JITM: expand docs and tests to account for pre-connection messages -- Improve responsiveness of JITMs -- JITM: fix the use statements -- Implement pre-connection JITMs -- JITM: Allow JITM on stats pages - -## [1.5.1] - 2020-04-30 - -- JITM: Allow JITM on stats pages - -## [1.5.0] - 2020-04-28 - -- Use jp.com redirect in all links - -## [1.4.0] - 2020-03-31 - -- Update dependencies to latest stable - -## [1.3.0] - 2020-03-31 - -- Use dynamic Jetpack logos on JITMs - -## [1.2.0] - 2020-02-25 - -- JITM: Show ToS update notice - -## [1.1.2] - 2020-02-14 - -- SSO: do not display JITM when not in wp-admin - -## [1.1.1] - 2020-01-23 - -- Moved JITM initialization to plugins_loaded. - -## [1.1.0] - 2020-01-07 - -- Add partner subsidiary id to upgrade URLs. - -## [1.0.10] - 2019-11-25 - -- Connection Owner Deletion Notice: Fix display bug and sanitize… - -## [1.0.9] - 2019-11-19 - -- Don't show JITMs on Gutenberg editor pages (for now) - -## [1.0.8] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.0.7] - 2019-11-08 - -- Remove unused get_emblem method - -## [1.0.6] - 2019-10-31 - -- Inherit 400 weight for button fonts - -## [1.0.5] - 2019-10-28 - -- PHPCS: JITM and Assets packages - -## [1.0.4] - 2019-10-24 - -- Update Jetpack button and card styles to match WordPress 5.3 - -## [1.0.3] - 2019-10-23 - -- Use spread operator instead of func_get_args - -## [1.0.2] - 2019-10-17 - -- Change the class in the add_filter() calls to $this. Also fix some - -## [1.0.1] - 2019-09-27 - -- Initial trial of prefer-dist -- JITM: Send the user's role in the request for JITM messages - -## 1.0.0 - 2019-09-14 - -- Update Jetpack to use new JITM package - -[4.2.7]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.6...v4.2.7 -[4.2.6]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.5...v4.2.6 -[4.2.5]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.4...v4.2.5 -[4.2.4]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.3...v4.2.4 -[4.2.3]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.2...v4.2.3 -[4.2.2]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.1...v4.2.2 -[4.2.1]: https://github.com/Automattic/jetpack-jitm/compare/v4.2.0...v4.2.1 -[4.2.0]: https://github.com/Automattic/jetpack-jitm/compare/v4.1.1...v4.2.0 -[4.1.1]: https://github.com/Automattic/jetpack-jitm/compare/v4.1.0...v4.1.1 -[4.1.0]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.7...v4.1.0 -[4.0.7]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.6...v4.0.7 -[4.0.6]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.5...v4.0.6 -[4.0.5]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.4...v4.0.5 -[4.0.4]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.3...v4.0.4 -[4.0.3]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.2...v4.0.3 -[4.0.2]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.1...v4.0.2 -[4.0.1]: https://github.com/Automattic/jetpack-jitm/compare/v4.0.0...v4.0.1 -[4.0.0]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.29...v4.0.0 -[3.1.29]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.28...v3.1.29 -[3.1.28]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.27...v3.1.28 -[3.1.27]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.26...v3.1.27 -[3.1.26]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.25...v3.1.26 -[3.1.25]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.24...v3.1.25 -[3.1.24]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.23...v3.1.24 -[3.1.23]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.22...v3.1.23 -[3.1.22]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.21...v3.1.22 -[3.1.21]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.20...v3.1.21 -[3.1.20]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.19...v3.1.20 -[3.1.19]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.18...v3.1.19 -[3.1.18]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.17...v3.1.18 -[3.1.17]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.16...v3.1.17 -[3.1.16]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.15...v3.1.16 -[3.1.15]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.14...v3.1.15 -[3.1.14]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.13...v3.1.14 -[3.1.13]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.12...v3.1.13 -[3.1.12]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.11...v3.1.12 -[3.1.11]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.10...v3.1.11 -[3.1.10]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.9...v3.1.10 -[3.1.9]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.8...v3.1.9 -[3.1.8]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.7...v3.1.8 -[3.1.7]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.6...v3.1.7 -[3.1.6]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.5...v3.1.6 -[3.1.5]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.4...v3.1.5 -[3.1.4]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.3...v3.1.4 -[3.1.3]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.2...v3.1.3 -[3.1.2]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.1...v3.1.2 -[3.1.1]: https://github.com/Automattic/jetpack-jitm/compare/v3.1.0...v3.1.1 -[3.1.0]: https://github.com/Automattic/jetpack-jitm/compare/v3.0.5...v3.1.0 -[3.0.5]: https://github.com/Automattic/jetpack-jitm/compare/v3.0.4...v3.0.5 -[3.0.4]: https://github.com/Automattic/jetpack-jitm/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-jitm/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-jitm/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-jitm/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-jitm/compare/v2.5.3...v3.0.0 -[2.5.3]: https://github.com/Automattic/jetpack-jitm/compare/v2.5.2...v2.5.3 -[2.5.2]: https://github.com/Automattic/jetpack-jitm/compare/v2.5.1...v2.5.2 -[2.5.1]: https://github.com/Automattic/jetpack-jitm/compare/v2.5.0...v2.5.1 -[2.5.0]: https://github.com/Automattic/jetpack-jitm/compare/v2.4.0...v2.5.0 -[2.4.0]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.19...v2.4.0 -[2.3.19]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.18...v2.3.19 -[2.3.18]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.17...v2.3.18 -[2.3.17]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.16...v2.3.17 -[2.3.16]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.15...v2.3.16 -[2.3.15]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.14...v2.3.15 -[2.3.14]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.13...v2.3.14 -[2.3.13]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.12...v2.3.13 -[2.3.12]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.11...v2.3.12 -[2.3.11]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.10...v2.3.11 -[2.3.10]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.9...v2.3.10 -[2.3.9]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.8...v2.3.9 -[2.3.8]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.7...v2.3.8 -[2.3.7]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.6...v2.3.7 -[2.3.6]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.5...v2.3.6 -[2.3.5]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.4...v2.3.5 -[2.3.4]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.3...v2.3.4 -[2.3.3]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.2...v2.3.3 -[2.3.2]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.1...v2.3.2 -[2.3.1]: https://github.com/Automattic/jetpack-jitm/compare/v2.3.0...v2.3.1 -[2.3.0]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.42...v2.3.0 -[2.2.42]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.41...v2.2.42 -[2.2.41]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.40...v2.2.41 -[2.2.40]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.39...v2.2.40 -[2.2.39]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.38...v2.2.39 -[2.2.38]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.37...v2.2.38 -[2.2.37]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.36...v2.2.37 -[2.2.36]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.35...v2.2.36 -[2.2.35]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.34...v2.2.35 -[2.2.34]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.33...v2.2.34 -[2.2.33]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.32...v2.2.33 -[2.2.32]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.31...v2.2.32 -[2.2.31]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.30...v2.2.31 -[2.2.30]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.29...v2.2.30 -[2.2.29]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.28...v2.2.29 -[2.2.28]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.27...v2.2.28 -[2.2.27]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.26...v2.2.27 -[2.2.26]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.25...v2.2.26 -[2.2.25]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.24...v2.2.25 -[2.2.24]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.23...v2.2.24 -[2.2.23]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.22...v2.2.23 -[2.2.22]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.21...v2.2.22 -[2.2.21]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.20...v2.2.21 -[2.2.20]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.19...v2.2.20 -[2.2.19]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.18...v2.2.19 -[2.2.18]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.17...v2.2.18 -[2.2.17]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.16...v2.2.17 -[2.2.16]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.15...v2.2.16 -[2.2.15]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.14...v2.2.15 -[2.2.14]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.13...v2.2.14 -[2.2.13]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.12...v2.2.13 -[2.2.12]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.11...v2.2.12 -[2.2.11]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.10...v2.2.11 -[2.2.10]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.9...v2.2.10 -[2.2.9]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.8...v2.2.9 -[2.2.8]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.7...v2.2.8 -[2.2.7]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.6...v2.2.7 -[2.2.6]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.5...v2.2.6 -[2.2.5]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.4...v2.2.5 -[2.2.4]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.3...v2.2.4 -[2.2.3]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.2...v2.2.3 -[2.2.2]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.1...v2.2.2 -[2.2.1]: https://github.com/Automattic/jetpack-jitm/compare/v2.2.0...v2.2.1 -[2.2.0]: https://github.com/Automattic/jetpack-jitm/compare/v2.1.1...v2.2.0 -[2.1.1]: https://github.com/Automattic/jetpack-jitm/compare/v2.1.0...v2.1.1 -[2.1.0]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.8...v2.1.0 -[2.0.8]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.7...v2.0.8 -[2.0.7]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.6...v2.0.7 -[2.0.6]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.5...v2.0.6 -[2.0.5]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.4...v2.0.5 -[2.0.4]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-jitm/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.16.2...v2.0.0 -[1.16.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.16.1...v1.16.2 -[1.16.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.16.0...v1.16.1 -[1.16.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.15.1...v1.16.0 -[1.15.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.15.0...v1.15.1 -[1.15.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.14.1...v1.15.0 -[1.14.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.14.0...v1.14.1 -[1.14.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.13.5...v1.14.0 -[1.13.5]: https://github.com/Automattic/jetpack-jitm/compare/v1.13.4...v1.13.5 -[1.13.4]: https://github.com/Automattic/jetpack-jitm/compare/v1.13.3...v1.13.4 -[1.13.3]: https://github.com/Automattic/jetpack-jitm/compare/v1.13.2...v1.13.3 -[1.13.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.13.1...v1.13.2 -[1.13.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.13.0...v1.13.1 -[1.13.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.12.2...v1.13.0 -[1.12.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.12.1...v1.12.2 -[1.12.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.12.0...v1.12.1 -[1.12.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.11.2...v1.12.0 -[1.11.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.11.1...v1.11.2 -[1.11.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.11.0...v1.11.1 -[1.11.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.10.4...v1.11.0 -[1.10.4]: https://github.com/Automattic/jetpack-jitm/compare/v1.10.3...v1.10.4 -[1.10.3]: https://github.com/Automattic/jetpack-jitm/compare/v1.10.2...v1.10.3 -[1.10.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.10.1...v1.10.2 -[1.10.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.10.0...v1.10.1 -[1.10.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.9.1...v1.10.0 -[1.9.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.9.0...v1.9.1 -[1.9.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.8.2...v1.9.0 -[1.8.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.8.1...v1.8.2 -[1.8.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.8.0...v1.8.1 -[1.8.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.7.2...v1.8.0 -[1.7.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.7.1...v1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.7.0...v1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.6.5...v1.7.0 -[1.6.5]: https://github.com/Automattic/jetpack-jitm/compare/v1.6.4...v1.6.5 -[1.6.4]: https://github.com/Automattic/jetpack-jitm/compare/v1.6.3...v1.6.4 -[1.6.3]: https://github.com/Automattic/jetpack-jitm/compare/v1.6.2...v1.6.3 -[1.6.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.6.1...v1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.5.1...v1.6.0 -[1.5.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.4.0...v1.5.0 -[1.4.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.1.2...v1.2.0 -[1.1.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.1.1...v1.1.2 -[1.1.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.10...v1.1.0 -[1.0.10]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.9...v1.0.10 -[1.0.9]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.8...v1.0.9 -[1.0.8]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.7...v1.0.8 -[1.0.7]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.6...v1.0.7 -[1.0.6]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.5...v1.0.6 -[1.0.5]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.4...v1.0.5 -[1.0.4]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.3...v1.0.4 -[1.0.3]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.2...v1.0.3 -[1.0.2]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.1...v1.0.2 -[1.0.1]: https://github.com/Automattic/jetpack-jitm/compare/v1.0.0...v1.0.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/images/background-f9c9ff650c08ee46f153.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/images/background-f9c9ff650c08ee46f153.png deleted file mode 100644 index 07ae0ef4..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/images/background-f9c9ff650c08ee46f153.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.asset.php deleted file mode 100644 index 93377922..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('jquery', 'wp-api-fetch', 'wp-polyfill', 'wp-url'), 'version' => '0997a33b24034e958e27'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.css deleted file mode 100644 index f8d6f089..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.css +++ /dev/null @@ -1 +0,0 @@ -.jitm-button{-webkit-appearance:none;appearance:none;background:#fff;border:1px solid #000;border-radius:4px;box-sizing:border-box;color:#000;cursor:pointer;display:inline-block;font-size:14px;font-weight:600;margin:0;min-width:90px;outline:0;overflow:hidden;padding:7px 14px 9px;text-align:center;text-decoration:none;text-overflow:ellipsis;vertical-align:top;width:100%}.jitm-button.is-primary{background:#000;color:#fff}.jitm-button.is-primary .gridicons-external-link{fill:#fff}.jitm-button.is-secondary .gridicons-external-link{fill:#000}.jitm-button.is-secondary:hover{background:#f6f7f7;color:#000}.jitm-button.is-secondary:hover .gridicons-external-link{fill:#000}.jitm-button:focus,.jitm-button:hover{background:#414141;border-color:#414141;color:#fff}.jitm-button:focus{box-shadow:0 0 0 1px #fff,0 0 0 3px #2271b1}.jitm-button:disabled,.jitm-button[disabled]{background:#dcdcde;border-color:#dcdcde;color:#a7aaad;cursor:default}.jitm-button.is-compact{font-size:14px;height:32px;line-height:1;white-space:nowrap}.jitm-button.is-compact .gridicon{margin-top:-8px;top:4px}.jitm-button.is-compact .gridicons-plus-small{margin-left:-4px}.jitm-button.is-compact .gridicons-plus-small:last-of-type{margin-left:0}.jitm-button.is-compact .gridicons-plus-small+.gridicon{margin-left:-4px}.jitm-button.is-compact .gridicons-external-link{margin:-3px 0 -3px 2px}.jitm-button.hidden{display:none}.jitm-card{background-color:#fff;border:1px solid #fff;border-radius:2px;box-shadow:0 1px 4px #00000029;box-sizing:border-box;clear:both;display:block;margin:3rem 1.25rem 0 auto;padding:1rem 1rem 1rem 1.25rem;position:relative}.jitm-card:after{clear:both;content:".";display:block;height:0;visibility:hidden}.jitm-card.is-compact{margin-bottom:.0625rem}@media(min-width:481px){.jitm-card.is-compact{margin-bottom:1px;padding:1rem 1.5rem}}.jitm-card.is-card-link{padding-right:3rem}.my-jetpack-jitm-card .jitm-card{margin-bottom:1.5rem;margin-right:0;margin-top:1.5rem}#screen-meta-links+.jitm-card{margin:2.5rem 1.5385em 0 auto}.post-php .jitm-card{margin-right:0}.jp-lower .jitm-card{margin:0 0 1.5rem}.jitm-banner.jitm-card{display:flex;position:relative;z-index:2}.jitm-banner.jitm-card:before{border-bottom-left-radius:1px;border-top-left-radius:1px;content:"";height:100%;left:0;position:absolute;top:0;width:4px}@media(max-width:480px){.jitm-banner.jitm-card{display:flex;flex-direction:column}}.jitm-banner.jitm-card.is-card-link{padding:.75rem 3rem .75rem 1rem}.jitm-banner.jitm-card.is-dismissible{padding-right:3rem}.jitm-banner.jitm-card:before{background-color:#4ab866}.jitm-banner.jitm-card .jitm-banner__icon{color:#4ab866}.jitm-banner.jitm-card .jitm-banner__icon-circle{background-color:#4ab866}.jitm-banner.jitm-card.is-upgrade-personal:before{background-color:#f0b849}.jitm-banner.jitm-card.is-upgrade-personal .jitm-banner__icon{color:#f0b849}.jitm-banner.jitm-card.is-upgrade-personal .jitm-banner__icon-circle{background-color:#f0b849}.jitm-banner.jitm-card.is-upgrade-premium:before{background-color:#069e08}.jitm-banner.jitm-card.is-upgrade-premium .jitm-banner__icon{color:#069e08}.jitm-banner.jitm-card.is-upgrade-premium .jitm-banner__icon-circle{background-color:#069e08}.jitm-banner.jitm-card.is-upgrade-business:before,.jitm-banner.jitm-card.woo-jitm:before{background-color:#855da6}.jitm-banner.jitm-card.is-upgrade-business .jitm-banner__icon,.jitm-banner.jitm-card.woo-jitm .jitm-banner__icon{color:#855da6}.jitm-banner.jitm-card.is-upgrade-business .jitm-banner__icon-circle,.jitm-banner.jitm-card.woo-jitm .jitm-banner__icon-circle{background-color:#855da6}.jitm-banner.jitm-card .jitm-card__link-indicator{align-items:center;color:#0087be;display:flex}.jitm-banner.jitm-card:hover{transition:all .1s ease-in-out}.jitm-banner.jitm-card:hover.is-card-link{box-shadow:0 0 0 1px #a2a2a2,0 2px 4px #d5d5d5}.jitm-banner.jitm-card:hover .jitm-card__link-indicator{color:#005082}@media(min-width:481px){.jitm-banner.jitm-card{padding:1rem 1rem 1rem 1.25rem}.jitm-banner.jitm-card.is-dismissible{padding-right:1rem}}.jitm-banner__buttons_container{display:flex;gap:1rem;height:50%;margin:auto 1rem auto 0;overflow:hidden}@media(min-width:481px){.jitm-banner__buttons_container{margin-left:1rem}}.jitm-banner__icons{display:flex}.jitm-banner__icons .jitm-banner__icon,.jitm-banner__icons .jitm-banner__icon-circle{border-radius:50%;flex-shrink:0;height:1.5rem;margin-right:1rem;margin-top:-.125rem;text-align:center;top:.25rem;width:1.5rem}.jitm-banner__icons .jitm-banner__icon{align-self:center;color:#fff;display:block}.jitm-banner__icons .jitm-banner__icon-circle{color:#fff;display:none;padding:.1875rem .25rem .25rem .1875rem}@media(min-width:481px){.jitm-banner__icons{align-items:center}.jitm-banner__icons .jitm-banner__icon{display:none}.jitm-banner__icons .jitm-banner__icon-circle{display:block}}.jitm-banner__icon-plan{display:flex;margin-right:1rem}.jitm-banner__icon-plan .dops-plan-icon{height:2rem;width:2rem}.jitm-banner__icon-plan .jp-emblem{position:relative;top:.125rem}@media(max-width:480px){.jitm-banner__icon-plan .jp-emblem{margin-bottom:1rem}}.jitm-banner__icon-plan .jp-emblem svg{height:2rem;width:2rem;fill:#069e08}.jitm-banner__icon-plan .jp-emblem .jitm-jp-logo{height:inherit;width:2.5rem;fill:inherit}@media(min-width:481px){.jitm-banner__icon-plan{align-items:center}}.jitm-banner__background{background-image:url(images/background-f9c9ff650c08ee46f153.png);background-position:100%;background-repeat:no-repeat;height:100%;left:0;position:absolute;top:0;width:100%;z-index:-1}.rtl .jitm-banner__background{background-position:0;transform:scaleX(-1)}.jitm-banner__content{align-items:center;display:flex;flex-grow:1;flex-shrink:100000;flex-wrap:wrap}@media(max-width:480px){.jitm-banner__content{margin-right:0}}@media(min-width:481px){.jitm-banner__content{flex-wrap:nowrap}}@media(max-width:960px){.jitm-banner__content{margin-right:5px}}.jitm-banner__info{flex-grow:1;line-height:1.4}@media(min-width:481px){.jitm-banner__info{flex-basis:50%}}@media(min-width:961px){.jitm-banner__info{flex-basis:70%}}.jitm-banner__info .jitm-banner__description,.jitm-banner__info .jitm-banner__description a,.jitm-banner__info .jitm-banner__title{color:#000}.jitm-banner__info .jitm-banner__title{font-size:.9375rem;font-weight:700;line-height:136%}.jitm-banner__info .jitm-banner__description{font-size:.8125rem;line-height:150%;margin-top:.125rem}.jitm-banner__info .banner__list{font-size:12px;list-style:none;margin:10px 0}.jitm-banner__info .banner__list li{margin:6px 0}.jitm-banner__info .banner__list li .gridicon{fill:#a2a2a2;display:inline;margin-right:12px;vertical-align:bottom}.jitm-banner__action{align-self:center;font-size:.75rem;overflow:hidden;text-align:left}.jitm-banner__action .jitm-banner__prices{display:flex;justify-content:flex-start}.jitm-banner__action .jitm-banner__prices .dops-plan-price{margin-bottom:0}.jitm-banner__action .jitm-banner__prices .dops-plan-price.is-discounted,.jitm-banner__action .jitm-banner__prices .dops-plan-price.is-discounted .dops-plan-price__currency-symbol{color:#414141}.has-call-to-action .jitm-banner__action .jitm-banner__prices .dops-plan-price{margin-bottom:.5rem}@media(max-width:480px){.jitm-banner__action{margin-top:1rem}}@media(min-width:481px){.jitm-banner__action{text-align:center;width:auto}.jitm-banner__action .is-dismissible{margin-top:2.5rem}.jitm-banner__action .jitm-banner__prices{justify-content:flex-end;text-align:right}}.jitm-banner__dismiss{display:block;line-height:.5;margin-bottom:auto;margin-top:auto;text-decoration:none}.jitm-banner__dismiss:before{color:#6f6f6f;content:"";font:400 20px/1 dashicons}@media(min-width:661px){.jitm-banner__dismiss{margin-right:-.5rem}}@media(max-width:480px){.jitm-banner__dismiss{align-items:center;display:flex;height:48px;justify-content:center;margin:0;position:absolute;right:0;top:0;width:48px}}.jitm-banner__action+.jitm-banner__dismiss{margin-left:.625rem}#dolly+.jitm-card{margin:3rem 1rem 0 auto} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.js deleted file mode 100644 index b5a112bc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.js +++ /dev/null @@ -1 +0,0 @@ -(()=>{"use strict";var t={428:t=>{t.exports=window.jQuery},455:t=>{t.exports=window.wp.apiFetch},832:t=>{t.exports=window.wp.url}},a={};function e(i){var n=a[i];if(void 0!==n)return n.exports;var c=a[i]={exports:{}};return t[i](c,c.exports,e),c.exports}e.n=t=>{var a=t&&t.__esModule?()=>t.default:()=>t;return e.d(a,{a:a}),a},e.d=(t,a)=>{for(var i in a)e.o(a,i)&&!e.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:a[i]})},e.o=(t,a)=>Object.prototype.hasOwnProperty.call(t,a);var i=e(428),n=e.n(i),c=e(455),s=e.n(c),r=e(832);n()(document).ready((function(t){const a="/wpcom/v3/jitm";var e={default:function(a){const e='\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t';var i='
            ';if(i+='
            ',i+='
            ',i+='
            '+a.content.icon+"
            ",i+='
            ',i+='
            '+a.content.message+"
            ",a.content.description&&""!==a.content.description){if(i+='
            '+a.content.description,a.content.list.length>0){i+='
            "}if(i+="
            ",i+="
            ",i+='
            ',a.activate_module&&(i+='",a.module_settings_link&&(i+='")),a.CTA.message){var s="jitm-button is-compact";a.CTA.primary&&null===a.activate_module?s+=" is-primary":s+=" is-secondary";var r=a.CTA.ajax_action,o=a.CTA.newWindow&&!r;i+='"}return i+="
            ",a.is_dismissible&&(i+=''),t(i+="
            ")}},i=function(){t(".jetpack-jitm-message").each((function(){var i=t(this),n=i.data("message-path"),c=i.data("query"),o=i.data("redirect"),d=location.hash;d=d.replace(/#\//,"_"),n.includes("jetpack_page_my-jetpack")?n=n.replace("jetpack_page_my-jetpack","jetpack_page_my-jetpack"+d):"_dashboard"!==d&&(n=n.replace("toplevel_page_jetpack","toplevel_page_jetpack"+d));var l=!!t(".jetpack-logo__masthead").length;s()({path:(0,r.addQueryArgs)(a,{message_path:n,query:c,full_jp_logo_exists:l}),method:"GET"}).then((function(n){const c=n?.[0];c?.content&&function(i,n,c){var r;(r=n.template)&&e[r]||(r="default"),n.url=n.url+"&redirect="+c;var o,d=e[r](n);d.find(".jitm-banner__dismiss").on("click",(o=d,function(t){t.preventDefault(),o.hide(),s()({path:a,method:"POST",data:{id:n.id,feature_class:n.feature_class}})})),t("#jp-admin-notices").length>0?(i.innerHTML=d,t("#jp-admin-notices").find(".jitm-card")&&t(".jitm-card").replaceWith(d),d.prependTo(t("#jp-admin-notices"))):i.replaceWith(d),d.find("#jitm-banner__activate a").on("click",(function(){var a=t(this);if(a.attr("disabled"))return!1;t.ajax({url:window.jitm_config.api_root+"jetpack/v4/module/"+a.data("module")+"/active",method:"POST",beforeSend:function(a){a.setRequestHeader("X-WP-Nonce",i.data("nonce")),t("#jitm-banner__activate a").text(window.jitm_config.activating_module_text),t("#jitm-banner__activate a").attr("disabled",!0)}}).done((function(){if(t("#jitm-banner__activate a").text(window.jitm_config.activated_module_text),t("#jitm-banner__activate a").attr("disabled",!0),a.data("settings_link"))return t("#jitm-banner__settings").show(),void t("#jitm-banner__activate").hide();setTimeout((function(){d.fadeOut("slow")}),2e3)}))})),d.find(".jitm-button[data-ajax-action]").on("click",(function(a){a.preventDefault();var e=t(this);return e.attr("disabled",!0),t.post(window.ajaxurl,{action:e.data("ajax-action"),_nonce:i.data("ajax-nonce")}).done((function(){d.fadeOut("slow")})).fail((function(){e.attr("disabled",!1)})),!1})),d.find(".jitm-button").on("click",(function(a){var e=t(this),i=e.attr("data-jptracks-name");if(void 0!==i){var n={clicked:e.attr("data-jptracks-prop")||!1,jitm_message_path:e.attr("data-jitm-path")||!1};window.jpTracksAJAX&&window.jpTracksAJAX.record_ajax_event(i,"click",n)}}))}(i,c,o)}))}))};i(),t(window).on("hashchange",(function(t){const a=t.originalEvent.newURL;if(["jetpack","my-jetpack","jetpack-backup","jetpack-boost","jetpack-protect","jetpack-search","jetpack-social","jetpack-videopress"].some((t=>a.includes(`admin.php?page=${t}`)))){var e=document.querySelector(".jitm-card");e&&e.remove(),i()}}))}))})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.rtl.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.rtl.css deleted file mode 100644 index b87e4632..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/build/index.rtl.css +++ /dev/null @@ -1 +0,0 @@ -.jitm-button{-webkit-appearance:none;appearance:none;background:#fff;border:1px solid #000;border-radius:4px;box-sizing:border-box;color:#000;cursor:pointer;display:inline-block;font-size:14px;font-weight:600;margin:0;min-width:90px;outline:0;overflow:hidden;padding:7px 14px 9px;text-align:center;text-decoration:none;text-overflow:ellipsis;vertical-align:top;width:100%}.jitm-button.is-primary{background:#000;color:#fff}.jitm-button.is-primary .gridicons-external-link{fill:#fff}.jitm-button.is-secondary .gridicons-external-link{fill:#000}.jitm-button.is-secondary:hover{background:#f6f7f7;color:#000}.jitm-button.is-secondary:hover .gridicons-external-link{fill:#000}.jitm-button:focus,.jitm-button:hover{background:#414141;border-color:#414141;color:#fff}.jitm-button:focus{box-shadow:0 0 0 1px #fff,0 0 0 3px #2271b1}.jitm-button:disabled,.jitm-button[disabled]{background:#dcdcde;border-color:#dcdcde;color:#a7aaad;cursor:default}.jitm-button.is-compact{font-size:14px;height:32px;line-height:1;white-space:nowrap}.jitm-button.is-compact .gridicon{margin-top:-8px;top:4px}.jitm-button.is-compact .gridicons-plus-small{margin-right:-4px}.jitm-button.is-compact .gridicons-plus-small:last-of-type{margin-right:0}.jitm-button.is-compact .gridicons-plus-small+.gridicon{margin-right:-4px}.jitm-button.is-compact .gridicons-external-link{margin:-3px 2px -3px 0}.jitm-button.hidden{display:none}.jitm-card{background-color:#fff;border:1px solid #fff;border-radius:2px;box-shadow:0 1px 4px #00000029;box-sizing:border-box;clear:both;display:block;margin:3rem auto 0 1.25rem;padding:1rem 1.25rem 1rem 1rem;position:relative}.jitm-card:after{clear:both;content:".";display:block;height:0;visibility:hidden}.jitm-card.is-compact{margin-bottom:.0625rem}@media(min-width:481px){.jitm-card.is-compact{margin-bottom:1px;padding:1rem 1.5rem}}.jitm-card.is-card-link{padding-left:3rem}.my-jetpack-jitm-card .jitm-card{margin-bottom:1.5rem;margin-left:0;margin-top:1.5rem}#screen-meta-links+.jitm-card{margin:2.5rem auto 0 1.5385em}.post-php .jitm-card{margin-left:0}.jp-lower .jitm-card{margin:0 0 1.5rem}.jitm-banner.jitm-card{display:flex;position:relative;z-index:2}.jitm-banner.jitm-card:before{border-bottom-right-radius:1px;border-top-right-radius:1px;content:"";height:100%;position:absolute;right:0;top:0;width:4px}@media(max-width:480px){.jitm-banner.jitm-card{display:flex;flex-direction:column}}.jitm-banner.jitm-card.is-card-link{padding:.75rem 1rem .75rem 3rem}.jitm-banner.jitm-card.is-dismissible{padding-left:3rem}.jitm-banner.jitm-card:before{background-color:#4ab866}.jitm-banner.jitm-card .jitm-banner__icon{color:#4ab866}.jitm-banner.jitm-card .jitm-banner__icon-circle{background-color:#4ab866}.jitm-banner.jitm-card.is-upgrade-personal:before{background-color:#f0b849}.jitm-banner.jitm-card.is-upgrade-personal .jitm-banner__icon{color:#f0b849}.jitm-banner.jitm-card.is-upgrade-personal .jitm-banner__icon-circle{background-color:#f0b849}.jitm-banner.jitm-card.is-upgrade-premium:before{background-color:#069e08}.jitm-banner.jitm-card.is-upgrade-premium .jitm-banner__icon{color:#069e08}.jitm-banner.jitm-card.is-upgrade-premium .jitm-banner__icon-circle{background-color:#069e08}.jitm-banner.jitm-card.is-upgrade-business:before,.jitm-banner.jitm-card.woo-jitm:before{background-color:#855da6}.jitm-banner.jitm-card.is-upgrade-business .jitm-banner__icon,.jitm-banner.jitm-card.woo-jitm .jitm-banner__icon{color:#855da6}.jitm-banner.jitm-card.is-upgrade-business .jitm-banner__icon-circle,.jitm-banner.jitm-card.woo-jitm .jitm-banner__icon-circle{background-color:#855da6}.jitm-banner.jitm-card .jitm-card__link-indicator{align-items:center;color:#0087be;display:flex}.jitm-banner.jitm-card:hover{transition:all .1s ease-in-out}.jitm-banner.jitm-card:hover.is-card-link{box-shadow:0 0 0 1px #a2a2a2,0 2px 4px #d5d5d5}.jitm-banner.jitm-card:hover .jitm-card__link-indicator{color:#005082}@media(min-width:481px){.jitm-banner.jitm-card{padding:1rem 1.25rem 1rem 1rem}.jitm-banner.jitm-card.is-dismissible{padding-left:1rem}}.jitm-banner__buttons_container{display:flex;gap:1rem;height:50%;margin:auto 0 auto 1rem;overflow:hidden}@media(min-width:481px){.jitm-banner__buttons_container{margin-right:1rem}}.jitm-banner__icons{display:flex}.jitm-banner__icons .jitm-banner__icon,.jitm-banner__icons .jitm-banner__icon-circle{border-radius:50%;flex-shrink:0;height:1.5rem;margin-left:1rem;margin-top:-.125rem;text-align:center;top:.25rem;width:1.5rem}.jitm-banner__icons .jitm-banner__icon{align-self:center;color:#fff;display:block}.jitm-banner__icons .jitm-banner__icon-circle{color:#fff;display:none;padding:.1875rem .1875rem .25rem .25rem}@media(min-width:481px){.jitm-banner__icons{align-items:center}.jitm-banner__icons .jitm-banner__icon{display:none}.jitm-banner__icons .jitm-banner__icon-circle{display:block}}.jitm-banner__icon-plan{display:flex;margin-left:1rem}.jitm-banner__icon-plan .dops-plan-icon{height:2rem;width:2rem}.jitm-banner__icon-plan .jp-emblem{position:relative;top:.125rem}@media(max-width:480px){.jitm-banner__icon-plan .jp-emblem{margin-bottom:1rem}}.jitm-banner__icon-plan .jp-emblem svg{height:2rem;width:2rem;fill:#069e08}.jitm-banner__icon-plan .jp-emblem .jitm-jp-logo{height:inherit;width:2.5rem;fill:inherit}@media(min-width:481px){.jitm-banner__icon-plan{align-items:center}}.jitm-banner__background{background-image:url(images/background-f9c9ff650c08ee46f153.png);background-position:0;background-repeat:no-repeat;height:100%;position:absolute;right:0;top:0;width:100%;z-index:-1}.rtl .jitm-banner__background{background-position:100%;transform:scaleX(-1)}.jitm-banner__content{align-items:center;display:flex;flex-grow:1;flex-shrink:100000;flex-wrap:wrap}@media(max-width:480px){.jitm-banner__content{margin-left:0}}@media(min-width:481px){.jitm-banner__content{flex-wrap:nowrap}}@media(max-width:960px){.jitm-banner__content{margin-left:5px}}.jitm-banner__info{flex-grow:1;line-height:1.4}@media(min-width:481px){.jitm-banner__info{flex-basis:50%}}@media(min-width:961px){.jitm-banner__info{flex-basis:70%}}.jitm-banner__info .jitm-banner__description,.jitm-banner__info .jitm-banner__description a,.jitm-banner__info .jitm-banner__title{color:#000}.jitm-banner__info .jitm-banner__title{font-size:.9375rem;font-weight:700;line-height:136%}.jitm-banner__info .jitm-banner__description{font-size:.8125rem;line-height:150%;margin-top:.125rem}.jitm-banner__info .banner__list{font-size:12px;list-style:none;margin:10px 0}.jitm-banner__info .banner__list li{margin:6px 0}.jitm-banner__info .banner__list li .gridicon{fill:#a2a2a2;display:inline;margin-left:12px;vertical-align:bottom}.jitm-banner__action{align-self:center;font-size:.75rem;overflow:hidden;text-align:right}.jitm-banner__action .jitm-banner__prices{display:flex;justify-content:flex-start}.jitm-banner__action .jitm-banner__prices .dops-plan-price{margin-bottom:0}.jitm-banner__action .jitm-banner__prices .dops-plan-price.is-discounted,.jitm-banner__action .jitm-banner__prices .dops-plan-price.is-discounted .dops-plan-price__currency-symbol{color:#414141}.has-call-to-action .jitm-banner__action .jitm-banner__prices .dops-plan-price{margin-bottom:.5rem}@media(max-width:480px){.jitm-banner__action{margin-top:1rem}}@media(min-width:481px){.jitm-banner__action{text-align:center;width:auto}.jitm-banner__action .is-dismissible{margin-top:2.5rem}.jitm-banner__action .jitm-banner__prices{justify-content:flex-end;text-align:left}}.jitm-banner__dismiss{display:block;line-height:.5;margin-bottom:auto;margin-top:auto;text-decoration:none}.jitm-banner__dismiss:before{color:#6f6f6f;content:"";font:400 20px/1 dashicons}@media(min-width:661px){.jitm-banner__dismiss{margin-left:-.5rem}}@media(max-width:480px){.jitm-banner__dismiss{align-items:center;display:flex;height:48px;justify-content:center;left:0;margin:0;position:absolute;top:0;width:48px}}.jitm-banner__action+.jitm-banner__dismiss{margin-right:.625rem}#dolly+.jitm-card{margin:3rem auto 0 1rem} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/composer.json deleted file mode 100644 index 25f8e365..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/composer.json +++ /dev/null @@ -1,67 +0,0 @@ -{ - "name": "automattic/jetpack-jitm", - "description": "Just in time messages for Jetpack", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-a8c-mc-stats": "^3.0.4", - "automattic/jetpack-assets": "^4.0.14", - "automattic/jetpack-connection": "^6.8.0", - "automattic/jetpack-device-detection": "^3.0.5", - "automattic/jetpack-logo": "^3.0.4", - "automattic/jetpack-redirect": "^3.0.5", - "automattic/jetpack-status": "^5.0.10" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "build-production": [ - "pnpm run build-production" - ], - "build-development": [ - "pnpm run build" - ], - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ], - "watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run watch" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-jitm", - "textdomain": "jetpack-jitm", - "version-constants": { - "::PACKAGE_VERSION": "src/class-jitm.php" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-jitm/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "4.2.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php deleted file mode 100644 index 616a4971..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php +++ /dev/null @@ -1,413 +0,0 @@ -register(); - } - - /** - * Pre/Post Connection JITM factory metod - * - * @return Post_Connection_JITM|Pre_Connection_JITM JITM instance. - */ - public static function get_instance() { - if ( self::is_connected() ) { - $jitm = new Post_Connection_JITM(); - } else { - $jitm = new Pre_Connection_JITM(); - } - return $jitm; - } - - /** - * Sets up JITM action callbacks if needed. - */ - public function register() { - if ( did_action( 'jetpack_registered_jitms' ) ) { - // JITMs have already been registered. - return; - } - - if ( ! $this->jitms_enabled() ) { - // Do nothing. - return; - } - - add_action( 'rest_api_init', array( __NAMESPACE__ . '\\Rest_Api_Endpoints', 'register_endpoints' ) ); - - add_action( 'current_screen', array( $this, 'prepare_jitms' ) ); - - /** - * These are sync actions that we need to keep track of for jitms. - */ - add_filter( 'jetpack_sync_before_send_updated_option', array( $this, 'jetpack_track_last_sync_callback' ), 99 ); - - /** - * Fires when the JITMs are registered. This action is used to ensure that - * JITMs are registered only once. - * - * @since 1.16.0 - */ - do_action( 'jetpack_registered_jitms' ); - } - - /** - * Checks the jetpack_just_in_time_msgs filters and whether the site - * is offline to determine whether JITMs are enabled. - * - * @return bool True if JITMs are enabled, else false. - */ - public function jitms_enabled() { - /** - * Filter to turn off all just in time messages - * - * @since 1.1.0 - * @since-jetpack 3.7.0 - * @since-jetpack 5.4.0 Correct docblock to reflect default arg value - * - * @param bool true Whether to show just in time messages. - */ - if ( ! apply_filters( 'jetpack_just_in_time_msgs', true ) ) { - return false; - } - - // Folks cannot connect to WordPress.com and won't really be able to act on the pre-connection messages. So bail. - if ( ( new Status() )->is_offline_mode() ) { - return false; - } - - return true; - } - - /** - * Prepare actions according to screen and post type. - * - * @since 1.1.0 - * @since-jetpack 3.8.2 - * - * @uses Jetpack_Autoupdate::get_possible_failures() - * - * @param \WP_Screen $screen WP Core's screen object. - */ - public function prepare_jitms( $screen ) { - /** - * Filter to hide JITMs on certain screens. - * - * @since 1.14.0 - * - * @param bool true Whether to show just in time messages. - * @param string $string->id The ID of the current screen. - */ - if ( apply_filters( 'jetpack_display_jitms_on_screen', true, $screen->id ) ) { - add_action( 'admin_enqueue_scripts', array( $this, 'jitm_enqueue_files' ) ); - add_action( 'admin_notices', array( $this, 'ajax_message' ) ); - add_action( 'edit_form_top', array( $this, 'ajax_message' ) ); - } - } - - /** - * Check if the current page is a Jetpack or WooCommerce admin page. - * Noting that this is a very basic check, and pages from other plugins may also match. - * - * @since 3.1.0 - * - * @return bool True if the current page is a Jetpack or WooCommerce admin page, else false. - */ - public function is_a8c_admin_page() { - if ( ! function_exists( 'get_current_screen' ) ) { - return false; - } - - $current_screen = get_current_screen(); - - // We never want to show JITMs on the block editor. - if ( - method_exists( $current_screen, 'is_block_editor' ) - && $current_screen->is_block_editor() - ) { - return false; - } - - return ( - $current_screen - && $current_screen->id - && (bool) preg_match( - '/' . implode( '|', self::APPROVED_SCREEN_IDS ) . '/', - $current_screen->id - ) - ); - } - - /** - * Function to enqueue jitm css and js - */ - public function jitm_enqueue_files() { - // Only load those files on the Jetpack or Woo admin pages. - if ( ! $this->is_a8c_admin_page() ) { - return; - } - - Assets::register_script( - 'jetpack-jitm', - '../build/index.js', - __FILE__, - array( - 'in_footer' => true, - 'dependencies' => array( 'jquery' ), - 'enqueue' => true, - ) - ); - wp_localize_script( - 'jetpack-jitm', - 'jitm_config', - array( - 'api_root' => esc_url_raw( rest_url() ), - 'activate_module_text' => esc_html__( 'Activate', 'jetpack-jitm' ), - 'activated_module_text' => esc_html__( 'Activated', 'jetpack-jitm' ), - 'activating_module_text' => esc_html__( 'Activating', 'jetpack-jitm' ), - 'settings_module_text' => esc_html__( 'Settings', 'jetpack-jitm' ), - 'nonce' => wp_create_nonce( 'wp_rest' ), - ) - ); - } - - /** - * Is the current page a block editor page? - * - * @since 1.1.0 - * @since-jetpack 8.0.0 - * - * @deprecated 3.1.0 - */ - public function is_gutenberg_page() { - _deprecated_function( __METHOD__, '3.1.0' ); - $current_screen = get_current_screen(); - return ( method_exists( $current_screen, 'is_block_editor' ) && $current_screen->is_block_editor() ); - } - - /** - * Get's the current message path for display of a JITM - * - * @return string The message path - */ - public function get_message_path() { - $screen = get_current_screen(); - - return 'wp:' . $screen->id . ':' . current_filter(); - } - - /** - * Injects the dom to show a JITM inside of wp-admin. - */ - public function ajax_message() { - if ( ! is_admin() ) { - return; - } - - // Only add this to specifically allowed pages. - if ( ! $this->is_a8c_admin_page() ) { - return; - } - - $message_path = $this->get_message_path(); - $query_string = _http_build_query( $_GET, '', ',' ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - $current_screen = isset( $_SERVER['REQUEST_URI'] ) ? wp_unslash( $_SERVER['REQUEST_URI'] ) : ''; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- Escaped below - ?> -
            - = $feb_4_date; - - switch ( $content_icon ) { - case 'jetpack': - $jetpack_logo = new Jetpack_Logo(); - $content_icon = ''; - break; - case 'woocommerce': - // After Feb 4th 2025, we can remove this date condition check ( & filter) and the old svg logo. - /** - * Filter to force display the new Woo logo in Woo JITM's, or not. - * - * @since 4.0.5 - * - * @param bool $show_woo_logo Whether to show the new Woo logo or not. - */ - $content_icon = apply_filters( 'jetpack_jitm_use_new_woo_logo', $show_new_logo ) - // New Woo logo - ? '' - // Old Woo logo - : ''; - break; - default: - $content_icon = ''; - break; - } - return $content_icon; - } - - /** - * Returns an array containing the supported icons for JITMs. - * - * The list includes an empty string, which is used when no icon should be displayed. - * - * @return array The list of supported icons. - */ - public function get_supported_icons() { - return array( - 'jetpack', - 'woocommerce', - '', - ); - } - - /** - * Stores dismiss data into an option - * - * @param string $key Dismiss key. - */ - public function save_dismiss( $key ) { - $hide_jitm = \Jetpack_Options::get_option( 'hide_jitm' ); - if ( ! is_array( $hide_jitm ) ) { - $hide_jitm = array(); - } - - if ( ! isset( $hide_jitm[ $key ] ) || ! is_array( $hide_jitm[ $key ] ) ) { - $hide_jitm[ $key ] = array( - 'last_dismissal' => 0, - 'number' => 0, - ); - } - - $hide_jitm[ $key ] = array( - 'last_dismissal' => time(), - 'number' => $hide_jitm[ $key ]['number'] + 1, - ); - - \Jetpack_Options::update_option( 'hide_jitm', $hide_jitm ); - } - - /** - * Sets the 'jetpack_last_plugin_sync' transient when the active_plugins option is synced. - * - * @param array $params The action parameters. - * - * @return array Returns the action parameters unchanged. - */ - public function jetpack_track_last_sync_callback( $params ) { - /** - * This filter is documented in the Automattic\Jetpack\JITMS\Post_Connection_JITM class. - */ - if ( ! apply_filters( 'jetpack_just_in_time_msg_cache', true ) ) { - return $params; - } - - if ( is_array( $params ) && isset( $params[0] ) ) { - $option = $params[0]; - if ( 'active_plugins' === $option ) { - // Use the cache if we can, but not terribly important if it gets evicted. - set_transient( 'jetpack_last_plugin_sync', time(), HOUR_IN_SECONDS ); - } - } - - return $params; - } - - /** - * Check if the current site is connected. - * On WordPress.com Simple, it is always connected. - * - * @return bool true if the site is connected, false otherwise. - */ - private static function is_connected() { - if ( ( new Host() )->is_wpcom_simple() ) { - return true; - } - - $connection = new Connection_Manager(); - return $connection->is_connected(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php deleted file mode 100644 index 3b5fd3da..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php +++ /dev/null @@ -1,421 +0,0 @@ -tracking = new Tracking(); - } - - /** - * A special filter for WooCommerce, to set a message based on local state. - * - * @param object $content The current message. - * - * @return object The new message. - */ - public static function jitm_woocommerce_services_msg( $content ) { - if ( ! function_exists( 'wc_get_base_location' ) ) { - return $content; - } - - $base_location = wc_get_base_location(); - - switch ( $base_location['country'] ) { - case 'US': - $content->message = esc_html__( 'New free service: Show USPS shipping rates on your store! Added bonus: print shipping labels without leaving WooCommerce.', 'jetpack-jitm' ); - break; - case 'CA': - $content->message = esc_html__( 'New free service: Show Canada Post shipping rates on your store!', 'jetpack-jitm' ); - break; - default: - $content->message = ''; - } - - return $content; - } - - /** - * A special filter for WooCommerce Call To Action button - * - * @return string The new CTA - */ - public static function jitm_jetpack_woo_services_install() { - return wp_nonce_url( - add_query_arg( - array( - 'wc-services-action' => 'install', - ), - admin_url( 'admin.php?page=wc-settings' ) - ), - 'wc-services-install' - ); - } - - /** - * A special filter for WooCommerce Call To Action button. - * - * @return string The new CTA - */ - public static function jitm_jetpack_woo_services_activate() { - return wp_nonce_url( - add_query_arg( - array( - 'wc-services-action' => 'activate', - ), - admin_url( 'admin.php?page=wc-settings' ) - ), - 'wc-services-install' - ); - } - - /** - * A special filter used in the CTA of a JITM offering to install the Creative Mail plugin. - * - * @return string The new CTA - */ - public static function jitm_jetpack_creative_mail_install() { - return wp_nonce_url( - add_query_arg( - array( - 'creative-mail-action' => 'install', - ), - admin_url( 'edit.php?post_type=feedback' ) - ), - 'creative-mail-install' - ); - } - - /** - * A special filter used in the CTA of a JITM offering to activate the Creative Mail plugin. - * - * @return string The new CTA - */ - public static function jitm_jetpack_creative_mail_activate() { - return wp_nonce_url( - add_query_arg( - array( - 'creative-mail-action' => 'activate', - ), - admin_url( 'edit.php?post_type=feedback' ) - ), - 'creative-mail-install' - ); - } - - /** - * A special filter used in the CTA of a JITM offering to install the Jetpack Backup plugin. - * - * @return string The new CTA - */ - public static function jitm_jetpack_backup_install() { - return wp_nonce_url( - add_query_arg( - array( - 'jetpack-backup-action' => 'install', - ), - admin_url( 'admin.php?page=jetpack' ) - ), - 'jetpack-backup-install' - ); - } - - /** - * A special filter used in the CTA of a JITM offering to activate the Jetpack Backup plugin. - * - * @return string The new CTA - */ - public static function jitm_jetpack_backup_activate() { - return wp_nonce_url( - add_query_arg( - array( - 'jetpack-backup-action' => 'activate', - ), - admin_url( 'admin.php?page=jetpack' ) - ), - 'jetpack-backup-install' - ); - } - - /** - * A special filter used in the CTA of a JITM offering to install the Jetpack Boost plugin. - * - * @return string The new CTA - */ - public static function jitm_jetpack_boost_install() { - return wp_nonce_url( - add_query_arg( - array( - 'jetpack-boost-action' => 'install', - ), - admin_url( 'admin.php?page=jetpack' ) - ), - 'jetpack-boost-install' - ); - } - - /** - * A special filter used in the CTA of a JITM offering to activate the Jetpack Boost plugin. - * - * @return string The new CTA - */ - public static function jitm_jetpack_boost_activate() { - return wp_nonce_url( - add_query_arg( - array( - 'jetpack-boost-action' => 'activate', - ), - admin_url( 'admin.php?page=jetpack' ) - ), - 'jetpack-boost-install' - ); - } - - /** - * Dismisses a JITM feature class so that it will no longer be shown. - * - * @param string $id The id of the JITM that was dismissed. - * @param string $feature_class The feature class of the JITM that was dismissed. - * - * @return bool Always true. - */ - public function dismiss( $id, $feature_class ) { - $this->tracking->record_user_event( - 'jitm_dismiss_client', - array( - 'jitm_id' => $id, - 'feature_class' => $feature_class, - ) - ); - $this->save_dismiss( $feature_class ); - return true; - } - - /** - * Asks the wpcom API for the current message to display keyed on query string and message path. - * - * For sites running on the Dotcom Simple codebase, the network request is bypassed - * via Client::wpcom_json_api_request_as_blog allowing for the JITM\Engine to be called - * directly. - * - * @param string $message_path The message path to ask for. - * @param string $query The query string originally from the front end. - * @param bool $full_jp_logo_exists If there is a full Jetpack logo already on the page. - * - * @return array The JITM's to show, or an empty array if there is nothing to show - */ - public function get_messages( $message_path, $query, $full_jp_logo_exists ) { - // WooCommerce Services. - add_filter( 'jitm_woocommerce_services_msg', array( $this, 'jitm_woocommerce_services_msg' ) ); - add_filter( 'jitm_jetpack_woo_services_install', array( $this, 'jitm_jetpack_woo_services_install' ) ); - add_filter( 'jitm_jetpack_woo_services_activate', array( $this, 'jitm_jetpack_woo_services_activate' ) ); - - // Creative Mail. - add_filter( 'jitm_jetpack_creative_mail_install', array( $this, 'jitm_jetpack_creative_mail_install' ) ); - add_filter( 'jitm_jetpack_creative_mail_activate', array( $this, 'jitm_jetpack_creative_mail_activate' ) ); - - // Jetpack Backup. - add_filter( 'jitm_jetpack_backup_install', array( $this, 'jitm_jetpack_backup_install' ) ); - add_filter( 'jitm_jetpack_backup_activate', array( $this, 'jitm_jetpack_backup_activate' ) ); - - // Jetpack Boost. - add_filter( 'jitm_jetpack_boost_install', array( $this, 'jitm_jetpack_boost_install' ) ); - add_filter( 'jitm_jetpack_boost_activate', array( $this, 'jitm_jetpack_boost_activate' ) ); - - $user = wp_get_current_user(); - - // Unauthenticated or invalid requests just bail. - if ( ! $user ) { - return array(); - } - - $user_roles = implode( ',', $user->roles ); - $site_id = \Jetpack_Options::get_option( 'id' ); - - // Build our jitm request. - $path = add_query_arg( - array( - 'external_user_id' => urlencode_deep( $user->ID ), - 'user_roles' => urlencode_deep( $user_roles ), - 'query_string' => urlencode_deep( build_query( $query ) ), - 'mobile_browser' => Device_Detection::is_smartphone() ? 1 : 0, - '_locale' => get_user_locale(), - ), - sprintf( '/sites/%d/jitm/%s', $site_id, $message_path ) - ); - - // Attempt to get from cache. - $envelopes = get_transient( 'jetpack_jitm_' . substr( md5( $path ), 0, 31 ) ); - - // If something is in the cache and it was put in the cache after the last sync we care about, use it. - $use_cache = false; - - /** - * Filter to turn off jitm caching - * - * @since 1.1.0 - * @since-jetpack 5.4.0 - * - * @param bool true Whether to cache just in time messages - */ - if ( apply_filters( 'jetpack_just_in_time_msg_cache', true ) ) { - $use_cache = true; - } - - if ( $use_cache ) { - $last_sync = (int) get_transient( 'jetpack_last_plugin_sync' ); - $from_cache = $envelopes && $last_sync > 0 && $last_sync < $envelopes['last_response_time']; - } else { - $from_cache = false; - } - - // Otherwise, ask again. - if ( ! $from_cache ) { - $wpcom_response = Client::wpcom_json_api_request_as_blog( - $path, - '2', - array( - 'user_id' => $user->ID, - 'user_roles' => implode( ',', $user->roles ), - ), - null, - 'wpcom' - ); - - // silently fail...might be helpful to track it? - if ( is_wp_error( $wpcom_response ) ) { - return array(); - } - - $envelopes = json_decode( $wpcom_response['body'] ); - - if ( ! is_array( $envelopes ) ) { - return array(); - } - - $expiration = isset( $envelopes[0] ) ? $envelopes[0]->ttl : 300; - - // Do not cache if expiration is 0 or we're not using the cache. - if ( 0 !== $expiration && $use_cache ) { - $envelopes['last_response_time'] = time(); - - set_transient( 'jetpack_jitm_' . substr( md5( $path ), 0, 31 ), $envelopes, $expiration ); - } - } - - $hidden_jitms = \Jetpack_Options::get_option( 'hide_jitm' ); - unset( $envelopes['last_response_time'] ); - - /** - * Allow adding your own custom JITMs after a set of JITMs has been received. - * - * @since 1.1.0 - * @since-jetpack 6.9.0 - * @since-jetpack 8.3.0 - Added Message path. - * - * @param array $envelopes array of existing JITMs. - * @param string $message_path The message path to ask for. - */ - $envelopes = apply_filters( 'jetpack_jitm_received_envelopes', $envelopes, $message_path ); - - foreach ( $envelopes as $idx => &$envelope ) { - - $dismissed_feature = isset( $hidden_jitms[ $envelope->feature_class ] ) && is_array( $hidden_jitms[ $envelope->feature_class ] ) ? $hidden_jitms[ $envelope->feature_class ] : null; - - // If the this feature class has been dismissed and the request has not passed the ttl, skip it as it's been dismissed. - if ( is_array( $dismissed_feature ) && ( time() - $dismissed_feature['last_dismissal'] < $envelope->expires || $dismissed_feature['number'] >= $envelope->max_dismissal ) ) { - unset( $envelopes[ $idx ] ); - continue; - } - - $this->tracking->record_user_event( - 'jitm_view_client', - array( - 'jitm_id' => $envelope->id, - 'jitm_message_path' => $message_path, - ) - ); - - $url_params = array( - 'u' => $user->ID, - ); - - // Get affiliate code and add it to the array of URL parameters. - $aff = Partner::init()->get_partner_code( Partner::AFFILIATE_CODE ); - if ( '' !== $aff ) { - $url_params['aff'] = $aff; - } - - // Check if the current user has connected their WP.com account - // and if not add this information to the the array of URL parameters. - if ( ! ( new Manager() )->is_user_connected( $user->ID ) ) { - $url_params['query'] = 'unlinked=1'; - } - $envelope->url = esc_url( Redirect::get_url( "jitm-$envelope->id", $url_params ) ); - - $stats = new A8c_Mc_Stats(); - - $envelope->jitm_stats_url = $stats->build_stats_url( array( 'x_jetpack-jitm' => $envelope->id ) ); - - // phpcs:disable WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - // $CTA is not valid per PHPCS, but it is part of the return from WordPress.com, so allowing. - if ( $envelope->CTA->hook ) { - $envelope->url = apply_filters( 'jitm_' . $envelope->CTA->hook, $envelope->url ); - unset( $envelope->CTA->hook ); - } - // phpcs:enable - - if ( isset( $envelope->content->hook ) ) { - $envelope->content = apply_filters( 'jitm_' . $envelope->content->hook, $envelope->content ); - unset( $envelope->content->hook ); - } - - // No point in showing an empty message. - if ( empty( $envelope->content->message ) ) { - unset( $envelopes[ $idx ] ); - continue; - } - - $envelope->content->icon = $this->generate_icon( $envelope->content->icon, $full_jp_logo_exists ); - $envelope->message_path = esc_attr( $message_path ); - - $stats->add( 'jitm', $envelope->id . '-viewed' ); - $stats->do_server_side_stats(); - } - - return $envelopes; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php deleted file mode 100644 index 89cd030d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php +++ /dev/null @@ -1,173 +0,0 @@ -validate_messages( $messages ); - - $formatted_messages = array(); - - foreach ( $messages as $message ) { - if ( ! preg_match( $message['message_path'], $message_path ) ) { - continue; - } - - $obj = new \stdClass(); - $obj->CTA = array( // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - 'message' => $message['button_caption'], - 'newWindow' => false, - ); - $obj->url = $message['button_link']; - $obj->id = $message['id']; - $obj->is_dismissible = true; - $obj->content = array( - 'message' => $message['message'], - 'description' => $message['description'], - 'list' => array(), - 'icon' => $this->get_message_icon( $message ), - ); - - $formatted_messages[] = $obj; - } - - return $formatted_messages; - } - - /** - * Validates that each of the messages contains all of the required keys: - * - id - * - message_path - * - message - * - description - * - button_link - * - button_caption - * - * @param array $messages An array of JITM messages. - * - * @return array An array of JITM messages that contain all of the required keys. - */ - private function validate_messages( $messages ) { - if ( ! is_array( $messages ) ) { - return array(); - } - - $expected_keys = array_flip( array( 'id', 'message_path', 'message', 'description', 'button_link', 'button_caption' ) ); - - foreach ( $messages as $index => $message ) { - if ( count( array_intersect_key( $expected_keys, $message ) ) !== count( $expected_keys ) ) { - // Remove any messages that are missing expected keys. - unset( $messages[ $index ] ); - } - } - - return $messages; - } - - /** - * Get the icon for the message. - * - * The message may contain an 'icon' key. If the value of the 'icon' key matches a supported icon (or empty string), the value is used. - * If the message does not contain an icon key or if the value does not match a supported icon, the Jetpack icon is used by default. - * - * @param array $message A pre-connection JITM. - * - * @return string The icon to use in the JITM. - */ - private function get_message_icon( $message ) { - // Default to the Jetpack icon. - $icon = 'jetpack'; - - if ( ! isset( $message['icon'] ) ) { - return $icon; - } - - $supported_icons = $this->get_supported_icons(); - - if ( in_array( $message['icon'], $supported_icons, true ) ) { - // Only use the message icon if it's a supported icon or an empty string (for no icon). - $icon = $message['icon']; - } - - return $icon; - } - - /** - * Retrieve the current message to display keyed on query string and message path - * - * @param string $message_path The message path to ask for. - * @param string $query The query string originally from the front end. Unused in this subclass. - * @param bool $full_jp_logo_exists If there is a full Jetpack logo already on the page. - * - * @return array The JITMs to show, or an empty array if there is nothing to show - */ - public function get_messages( $message_path, $query, $full_jp_logo_exists ) { - // Ensure only admins see pre-connection JITMs since only they can connect to WordPress.com - // and enable modules. - if ( ! current_user_can( 'install_plugins' ) ) { - return array(); - } - - $messages = $this->filter_messages( $message_path ); - - if ( empty( $messages ) ) { - return array(); - } - - $hidden_jitms = \Jetpack_Options::get_option( 'hide_jitm' ); - - foreach ( $messages as $idx => &$envelope ) { - $dismissed_feature = isset( $hidden_jitms[ 'pre-connection-' . $envelope->id ] ) && - is_array( $hidden_jitms[ 'pre-connection-' . $envelope->id ] ) ? $hidden_jitms[ 'pre-connection-' . $envelope->id ] : null; - - if ( is_array( $dismissed_feature ) ) { - unset( $messages[ $idx ] ); - continue; - } - - $envelope->content['icon'] = $this->generate_icon( $envelope->content['icon'], $full_jp_logo_exists ); - } - - return $messages; - } - - /** - * Dismisses a JITM ID so that it will no longer be shown. - * - * @param string $id The id of the JITM that was dismissed. - * - * @return bool Always true - */ - public function dismiss( $id ) { - $this->save_dismiss( 'pre-connection-' . $id ); - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php deleted file mode 100644 index 5a8e62c4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php +++ /dev/null @@ -1,95 +0,0 @@ - WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_jitm_message', - 'permission_callback' => '__return_true', - ) - ); - - register_rest_route( - 'jetpack/v4', - '/jitm', - array( - 'methods' => WP_REST_Server::CREATABLE, - 'callback' => __CLASS__ . '::delete_jitm_message', - 'permission_callback' => __CLASS__ . '::delete_jitm_message_permission_callback', - ) - ); - } - - /** - * Asks for a jitm, unless they've been disabled, in which case it returns an empty array - * - * @param WP_REST_Request $request The request object. - * - * @return array An array of jitms - */ - public static function get_jitm_message( $request ) { - $jitm = JITM::get_instance(); - - if ( ! $jitm->jitms_enabled() ) { - return array(); - } - - // add the search term to the query params if it exists - $query_param = $request['query'] ?? ''; - - return $jitm->get_messages( $request['message_path'], urldecode_deep( array( 'query' => $query_param ) ), 'true' === $request['full_jp_logo_exists'] ); - } - - /** - * Dismisses a jitm. - * - * @param WP_REST_Request $request The request object. - * - * @return bool Always True - */ - public static function delete_jitm_message( $request ) { - $jitm = JITM::get_instance(); - - if ( ! $jitm->jitms_enabled() ) { - return true; - } - - return $jitm->dismiss( $request['id'], $request['feature_class'] ); - } - - /** - * Verify that the user can dismiss JITM messages. - * - * @return bool|WP_Error True if user is able to dismiss JITM messages. - */ - public static function delete_jitm_message_permission_callback() { - if ( current_user_can( 'read' ) ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_jetpack_delete_jitm_message', REST_Connector::get_user_permissions_error_msg(), array( 'status' => rest_authorization_required_code() ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/css/jetpack-admin-jitm.scss b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/css/jetpack-admin-jitm.scss deleted file mode 100644 index e054d763..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/css/jetpack-admin-jitm.scss +++ /dev/null @@ -1,516 +0,0 @@ -// Just in Time Messaging - message prompts - -// TODO: Switch to using the `@automattic/jetpack-base-styles` package when its ready. -@import '../../plugins/jetpack/_inc/client/scss/functions/rem'; -@import '../../plugins/jetpack/_inc/client/scss/variables/colors'; -@import '../../plugins/jetpack/_inc/client/scss/mixins/breakpoints'; -@import '../../plugins/jetpack/_inc/client/scss/calypso-colors'; - -@mixin clear-fix { - &::after { - content: "."; - display: block; - height: 0; - clear: both; - visibility: hidden; - } -} - -@mixin jitm-banner-color( $color ) { - &::before { - background-color: $color; - } - - .jitm-banner__icon { - color: $color; - } - - .jitm-banner__icon-circle { - background-color: $color; - } -} - -// New JITMS - modified calypso banner styles -$blue-medium-dark: #2271b1; -$jp-gray: #dcdcde; -$jp-gray-0: #f6f7f7; -$jp-gray-20: #a7aaad; - -.jitm-button { - border-style: solid; - border-width: 1px; - cursor: pointer; - display: inline-block; - margin: 0; - outline: 0; - overflow: hidden; - text-overflow: ellipsis; - text-decoration: none; - vertical-align: top; - box-sizing: border-box; - font-size: 14px; - border-radius: 4px; - padding: 7px 14px 9px; - -webkit-appearance: none; - appearance: none; - text-align: center; - min-width: 90px; - font-weight: 600; - border-color: black; - background: $white; - color: black; - width: 100%; - - // Primary buttons - &.is-primary { - background: black; - color: $white; - .gridicons-external-link { - fill: $white; - } - } - - // Secondary buttons - &.is-secondary { - .gridicons-external-link { - fill: black; - } - &:hover{ - color: black; - background: $jp-gray-0; - .gridicons-external-link { - fill: black; - } - } - } - - &:hover, - &:focus { - border-color: $gray-dark; - background: $gray-dark; - color: $white; - } - &:focus { - box-shadow: - 0 0 0 1px $white, - 0 0 0 3px $blue-medium-dark; - } - - &[disabled], - &:disabled { - color: $jp-gray-20; - background: $jp-gray; - border-color: $jp-gray; - cursor: default; - } - &.is-compact { - height: 32px; - font-size: 14px; - line-height: 1; - white-space: nowrap; - - .gridicon { - top: 4px; - margin-top: -8px; - } - // Make the left margin of the small plus icon visually less huge - .gridicons-plus-small { - margin-left: -4px; - } - // Reset the left margin if the button contains only the plus icon - .gridicons-plus-small:last-of-type { - margin-left: 0; - } - // Make plus icon nudged closer to adjacent icons for add-people and add-plugin type buttons - .gridicons-plus-small + .gridicon { - margin-left: -4px; - } - - // Properly align icon with the button text - .gridicons-external-link { - margin: -3px 0 -3px 2px; - } - } - &.hidden { - display: none; - } -} - -.jitm-card { - display: block; - clear: both; - position: relative; - margin: rem( 48px ) rem( 20px ) 0 auto; - padding: rem( 16px ); - padding-left: rem( 20px ); - box-sizing: border-box; - background-color: $white; - border: 1px solid $white; - border-radius: 2px; - box-shadow: 0px 1px 4px rgba(0, 0, 0, 0.16); - - @include clear-fix; - - // Compact Card - &.is-compact { - margin-bottom: rem( 1px ); - - @include breakpoint( ">480px" ) { - margin-bottom: 1px; - padding: rem( 16px ) rem( 24px ); - } - } - - &.is-card-link { - padding-right: rem( 48px ); - } -} - -// Minor adjustments for the display in My Jetpack. -.my-jetpack-jitm-card { - .jitm-card { - margin-right: 0; - margin-bottom: 1.5rem; - margin-top: 1.5rem; - } -} - -// if JITM appears directly below WordPress "help" menu adjust margins -#screen-meta-links+.jitm-card { - margin: rem( 40px ) 1.5385em 0 auto; -} - -// if JITM appears directly below WordPress hello dolly adjust margins -#dolly+.jitm-card { - margin: 3rem 1rem 0 auto; -} - -// remove right margin for jitms in the editor -.post-php .jitm-card { - margin-right: 0; -} - - // if JITM appears inside of the jetpack dashboard adjust margins - .jp-lower .jitm-card { - margin: 0 0 rem( 24px ); - } - -.jitm-banner.jitm-card { - display: flex; - position: relative; - z-index: 2; - - &::before { - content: ''; - width: 4px; - position: absolute; - top: 0; - left: 0; - height: 100%; - border-top-left-radius: 1px; - border-bottom-left-radius: 1px; - } - - @include breakpoint( "<480px" ) { - display: flex; - flex-direction: column; - } - - &.is-card-link { - padding: rem( 12px ) rem( 48px ) rem( 12px ) rem( 16px ); - } - &.is-dismissible { - padding-right: rem( 48px ); - } - - @include jitm-banner-color( $alert-green ); - - &.is-upgrade-personal { - @include jitm-banner-color( $alert-yellow ); - } - &.is-upgrade-premium { - @include jitm-banner-color( #069e08 ); - } - &.is-upgrade-business, - &.woo-jitm { - @include jitm-banner-color( $alert-purple ); - } - - .jitm-card__link-indicator { - align-items: center; - color: $blue-wordpress; - display: flex; - } - - &:hover { - transition: all 100ms ease-in-out; - &.is-card-link { - box-shadow: 0 0 0 1px $gray, 0 2px 4px lighten( $gray, 20% ); - } - .jitm-card__link-indicator { - color: $blue-dark; - } - } - - @include breakpoint( ">480px" ) { - padding: rem( 16px ); - padding-left: rem( 20px ); - - &.is-dismissible { - padding-right: rem( 16px ); - } - } -} - -.jitm-banner__buttons_container { - display: flex; - height: 50%; - margin: auto rem( 16px ) auto 0; - gap: rem( 16px ); - overflow: hidden; - - @include breakpoint( ">480px" ) { - margin-left: rem( 16px ); - } -} - -.jitm-banner__icons { - display: flex; - - .jitm-banner__icon, - .jitm-banner__icon-circle { - border-radius: 50%; - flex-shrink: 0; - height: rem( 24px ); - width: rem( 24px ); - margin-right: rem( 16px ); - margin-top: rem( -2px ); - text-align: center; - top: rem( 4px ); - } - - .jitm-banner__icon { - align-self: center; - color: $white; - display: block; - } - - .jitm-banner__icon-circle { - color: white; - display: none; - padding: rem( 3px ) rem( 4px ) rem( 4px ) rem( 3px ); - } - - @include breakpoint( ">480px" ) { - align-items: center; - - .jitm-banner__icon { - display: none; - } - .jitm-banner__icon-circle { - display: block; - } - } -} - -.jitm-banner__icon-plan { - display: flex; - margin-right: rem( 16px ); - - .dops-plan-icon { - height: rem( 32px ); - width: rem( 32px ); - } - - .jp-emblem { - position: relative; - top: rem( 2px ); - - @include breakpoint( "<480px" ) { - margin-bottom: rem( 16px ); - } - - svg { - height: rem( 32px ); - width: rem( 32px ); - fill: $green-primary; - } - - .jitm-jp-logo { - height: inherit; - width: rem( 40px ); - fill: inherit; - } - } - - @include breakpoint( ">480px" ) { - align-items: center; - } -} - -.jitm-banner__background { - position: absolute; - top: 0; - left: 0; - width: 100%; - height: 100%; - background-image: url( "../images/background.png" ); - background-repeat: no-repeat; - background-position: right center; - z-index: -1; - - .rtl & { - background-position: left center; - transform: scaleX(-1); - } -} - -.jitm-banner__content { - align-items: center; - display: flex; - flex-grow: 1; - flex-wrap: wrap; - flex-shrink: 100000; - - @include breakpoint( "<480px" ) { - margin-right: 0; - } - - @include breakpoint( ">480px" ) { - flex-wrap: nowrap; - } - - @include breakpoint( "<960px" ) { - margin-right: 5px; - } -} - -.jitm-banner__info { - flex-grow: 1; - line-height: 1.4; - - @include breakpoint( ">480px" ) { - flex-basis: 50%; - } - - @include breakpoint( ">960px" ) { - flex-basis: 70%; - } - - .jitm-banner__title, - .jitm-banner__description, - .jitm-banner__description a { - color: black; - } - - .jitm-banner__title { - font-size: rem( 15px ); - font-weight: 700; - line-height: 136%; - } - - .jitm-banner__description { - font-size: rem( 13px ); - line-height: 150%; - margin-top: rem( 2px ); - } - - .banner__list { - font-size: 12px; - list-style: none; - margin: 10px 0; - li { - margin: 6px 0; - .gridicon { - fill: $gray; - display: inline; - margin-right: 12px; - vertical-align: bottom; - } - } - } -} - -.jitm-banner__action { - align-self: center; - font-size: rem( 12px ); - text-align: left; - overflow: hidden; - - .jitm-banner__prices { - display: flex; - justify-content: flex-start; - - .dops-plan-price { - margin-bottom: 0; - } - - .dops-plan-price.is-discounted, - .dops-plan-price.is-discounted .dops-plan-price__currency-symbol { - color: $gray-dark; - } - - .has-call-to-action & .dops-plan-price { - margin-bottom: rem( 8px ); - } - } - - @include breakpoint( "<480px" ) { - margin-top: 1rem; - } - - @include breakpoint( ">480px" ) { - text-align: center; - width: auto; - - .is-dismissible { - margin-top: rem( 40px ); - } - - .jitm-banner__prices { - justify-content: flex-end; - text-align: right; - } - } -} - -.jitm-banner__dismiss { - display: block; - text-decoration: none; - line-height: .5; - margin-top: auto; - margin-bottom: auto; - - &::before { - color: darken($gray, 20%); - font: 400 20px/1 dashicons; - content: '\f335'; - } - - @include breakpoint( ">660px" ) { - margin-right: rem( -8px ); - } - - @include breakpoint( "<480px" ) { - position: absolute; - top: 0; - right: 0; - - display: flex; - justify-content: center; - align-items: center; - margin: 0; - - // Minimum touch area - width: 48px; - height: 48px; - } -} - -.jitm-banner__action + .jitm-banner__dismiss { - margin-left: rem( 10px ); -} - -#dolly + .jitm-card { - margin: 3rem 1rem 0 auto; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/images/background.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/images/background.png deleted file mode 100644 index 07ae0ef4..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-jitm/src/images/background.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/CHANGELOG.md deleted file mode 100644 index a83d63df..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/CHANGELOG.md +++ /dev/null @@ -1,415 +0,0 @@ -# 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). - -## [3.0.8] - 2025-03-21 -### Changed -- Internal updates. - -## [3.0.7] - 2025-03-12 -### Changed -- Internal updates. - -## [3.0.6] - 2025-03-05 -### Changed -- Internal updates. - -## [3.0.5] - 2025-02-24 -### Changed -- Update dependencies. - -## [3.0.4] - 2025-02-03 -### Changed -- Internal updates. - -## [3.0.3] - 2025-01-20 -### Changed -- Code: Use function-style exit() and die() with a default status code of 0. [#41167] - -## [3.0.2] - 2024-12-02 -### Changed -- Exclude revoked licenses from results when filtering unattached licenses in `Licensing::get_user_licenses()`. Only unattached and valid licenses are now returned. [#40215] - -## [3.0.1] - 2024-11-25 -### Changed -- Updated dependencies. [#40286] - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.0.12] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.0.11] - 2024-10-29 -### Changed -- Internal updates. - -## [2.0.10] - 2024-09-23 -### Changed -- Update dependencies. - -## [2.0.9] - 2024-09-05 -### Changed -- Update dependencies. - -## [2.0.8] - 2024-09-05 -### Changed -- Update dependencies. - -## [2.0.7] - 2024-08-26 -### Changed -- Updated package dependencies. [#39004] - -## [2.0.6] - 2024-08-19 -### Changed -- Internal updates. - -## [2.0.5] - 2024-04-22 -### Changed -- Internal updates. - -## [2.0.4] - 2024-04-08 -### Changed -- Internal updates. - -## [2.0.3] - 2024-03-25 -### Changed -- Internal updates. - -## [2.0.2] - 2024-03-14 -### Changed -- Internal updates. - -## [2.0.1] - 2023-11-21 - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.8.4] - 2023-09-19 - -- Minor internal updates. - -## [1.8.3] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.8.2] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.8.1] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.8.0] - 2023-02-08 -### Added -- After connection flow, load unattached licenses. If any of them match the product that's being connected, redirect users to the license activation page. [#28509] - -## [1.7.14] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.7.13] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.7.12] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.7.11] - 2022-10-25 -### Changed -- Updated package dependencies. [#26705] - -## [1.7.10] - 2022-09-20 -### Changed -- Updated package dependencies. - -## [1.7.9] - 2022-09-08 -### Changed -- Updated package dependencies. - -## [1.7.8] - 2022-08-29 -### Changed -- Updated package dependencies. - -## [1.7.7] - 2022-08-23 -### Changed -- Updated package dependencies. [#25628] - -## [1.7.6] - 2022-08-03 -### Changed -- Updated package dependencies. [#25300, #25315] - -## [1.7.5] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.7.4] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.7.3] - 2022-06-14 -### Changed -- Updated package dependencies. [#24529] - -## [1.7.2] - 2022-05-04 -### Changed -- Updated package dependencies. [#24095] - -### Deprecated -- Moved the options class into Connection. [#24095] - -## [1.7.1] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.7.0] - 2022-04-19 -### Changed -- Moved licensing endpoints from the Jetpack plugin to the Licensing package - -## [1.6.4] - 2022-04-12 -### Changed -- Updated package dependencies. - -## [1.6.3] - 2022-03-02 -### Changed -- Updated package dependencies. - -## [1.6.2] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.6.1] - 2022-01-18 -### Changed -- Updated package dependencies. - -## [1.6.0] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies -- Updated package textdomain from `jetpack` to `jetpack-licensing`. - -## [1.5.4] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.5.3] - 2021-12-03 -### Changed -- Increases the timeout of the license activation request from 10 to 30 seconds. - -## [1.5.2] - 2021-11-30 -### Changed -- Updated package dependencies. - -## [1.5.1] - 2021-11-23 -### Changed -- Updated package dependencies. - -## [1.5.0] - 2021-11-16 -### Added -- Add a test for update to WPCOM return change. -- Added get_license_activation_notice_dismiss() function. - -## [1.4.9] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.4.8] - 2021-10-19 -### Changed -- Updated package dependencies. - -## [1.4.7] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.4.6] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.4.5] - 2021-08-31 -### Changed -- Run composer update on test-php command instead of phpunit. -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- Updated versions in annotations. - -## [1.4.4] - 2021-07-27 -### Changed -- Updated package dependencies. - -## [1.4.3] - 2021-06-29 -### Changed -- Updated package dependencies. - -## [1.4.2] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.4.1] - 2021-04-27 -### Changed -- Updated package dependencies. - -## [1.4.0] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies -- Dashboard: add new option to input license key. - -### Changed -- Replace usage of deprecated is_active method -- Update package dependencies. - -### Fixed -- Fix stored licenses not being attached on option creation -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.3.4] - 2021-02-23 - -- CI: Make tests more generic -- codesniffer: Hack around mediawiki-codesniffer bug - -## [1.3.3] - 2021-02-08 - -- Update dependencies to latest stable - -## [1.3.2] - 2021-01-28 - -- Update dependencies to latest stable - -## [1.3.1] - 2021-01-26 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.3.0] - 2021-01-05 - -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.2.4] - 2020-11-24 - -- Version packages for release - -## [1.2.3] - 2020-11-24 - -- Updated PHPCS: Packages and Debugger - -## [1.2.2] - 2020-11-05 - -- Update dependencies to latest stable - -## [1.2.1] - 2020-10-29 - -- Update dependencies to latest stable - -## [1.2.0] - 2020-10-27 - -- Licensing: use Oxford comma in error message - -## [1.1.4] - 2020-10-14 - -- Update dependencies to latest stable - -## [1.1.3] - 2020-10-09 - -- Update dependencies to latest stable - -## [1.1.2] - 2020-10-06 - -- Update dependencies to latest stable - -## [1.1.1] - 2020-10-01 - -- Update dependencies to latest stable - -## [1.1.0] - 2020-09-29 - -- Update dependencies to latest stable - -## 1.0.0 - 2020-09-24 - -- Licensing: Add support for Jetpack licenses - -[3.0.8]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.7...v3.0.8 -[3.0.7]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.6...v3.0.7 -[3.0.6]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.5...v3.0.6 -[3.0.5]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.4...v3.0.5 -[3.0.4]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-licensing/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.12...v3.0.0 -[2.0.12]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.11...v2.0.12 -[2.0.11]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.10...v2.0.11 -[2.0.10]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.9...v2.0.10 -[2.0.9]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.8...v2.0.9 -[2.0.8]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.7...v2.0.8 -[2.0.7]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.6...v2.0.7 -[2.0.6]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.5...v2.0.6 -[2.0.5]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.4...v2.0.5 -[2.0.4]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-licensing/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.8.4...v2.0.0 -[1.8.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.8.3...v1.8.4 -[1.8.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.8.2...v1.8.3 -[1.8.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.8.1...v1.8.2 -[1.8.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.8.0...v1.8.1 -[1.8.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.14...v1.8.0 -[1.7.14]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.13...v1.7.14 -[1.7.13]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.12...v1.7.13 -[1.7.12]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.11...v1.7.12 -[1.7.11]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.10...v1.7.11 -[1.7.10]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.9...v1.7.10 -[1.7.9]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.8...v1.7.9 -[1.7.8]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.7...v1.7.8 -[1.7.7]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.6...v1.7.7 -[1.7.6]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.5...v1.7.6 -[1.7.5]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.4...v1.7.5 -[1.7.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.3...v1.7.4 -[1.7.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.2...v1.7.3 -[1.7.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.1...v1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.7.0...v1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.6.4...v1.7.0 -[1.6.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.6.3...v1.6.4 -[1.6.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.6.2...v1.6.3 -[1.6.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.6.1...v1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.5.4...v1.6.0 -[1.5.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.5.3...v1.5.4 -[1.5.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.5.2...v1.5.3 -[1.5.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.5.1...v1.5.2 -[1.5.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.9...v1.5.0 -[1.4.9]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.8...v1.4.9 -[1.4.8]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.7...v1.4.8 -[1.4.7]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.6...v1.4.7 -[1.4.6]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.5...v1.4.6 -[1.4.5]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.4...v1.4.5 -[1.4.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.3...v1.4.4 -[1.4.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.2...v1.4.3 -[1.4.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.1...v1.4.2 -[1.4.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.4.0...v1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.3.4...v1.4.0 -[1.3.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.3.3...v1.3.4 -[1.3.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.3.2...v1.3.3 -[1.3.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.3.1...v1.3.2 -[1.3.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.3.0...v1.3.1 -[1.3.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.2.4...v1.3.0 -[1.2.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.2.3...v1.2.4 -[1.2.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.2.2...v1.2.3 -[1.2.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.2.1...v1.2.2 -[1.2.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.2.0...v1.2.1 -[1.2.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.1.4...v1.2.0 -[1.1.4]: https://github.com/Automattic/jetpack-licensing/compare/v1.1.3...v1.1.4 -[1.1.3]: https://github.com/Automattic/jetpack-licensing/compare/v1.1.2...v1.1.3 -[1.1.2]: https://github.com/Automattic/jetpack-licensing/compare/v1.1.1...v1.1.2 -[1.1.1]: https://github.com/Automattic/jetpack-licensing/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-licensing/compare/v1.0.0...v1.1.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/composer.json deleted file mode 100644 index 9f6194fa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/composer.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "name": "automattic/jetpack-licensing", - "description": "Everything needed to manage Jetpack licenses client-side.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-connection": "^6.7.7" - }, - "require-dev": { - "automattic/jetpack-test-environment": "@dev", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-licensing", - "textdomain": "jetpack-licensing", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-licensing/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php deleted file mode 100644 index 0972505a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php +++ /dev/null @@ -1,449 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_licensing_error', - 'permission_callback' => __CLASS__ . '::can_manage_options_check', - ), - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::update_licensing_error', - 'permission_callback' => __CLASS__ . '::can_manage_options_check', - 'args' => array( - 'error' => array( - 'required' => true, - 'type' => 'string', - 'validate_callback' => __CLASS__ . '::validate_string', - 'sanitize_callback' => 'sanitize_text_field', - ), - ), - ), - ) - ); - - /** - * Sets a license. This is still used as part of the first pass at licensing done for partners. - * - * See https://github.com/Automattic/jetpack/pull/23687 for more details. - */ - register_rest_route( - 'jetpack/v4', - '/licensing/set-license', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::set_jetpack_license', - 'permission_callback' => __CLASS__ . '::set_jetpack_license_key_permission_check', - 'args' => array( - 'license' => array( - 'required' => true, - 'type' => 'string', - 'validate_callback' => __CLASS__ . '::validate_string', - 'sanitize_callback' => 'sanitize_text_field', - ), - ), - ) - ); - - /** - * Get Jetpack user licenses. - */ - register_rest_route( - 'jetpack/v4', - 'licensing/user/licenses', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_user_licenses', - 'permission_callback' => __CLASS__ . '::user_licensing_permission_check', - ) - ); - - /** - * Get Jetpack user license counts. - */ - register_rest_route( - 'jetpack/v4', - 'licensing/user/counts', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_user_license_counts', - 'permission_callback' => __CLASS__ . '::user_licensing_permission_check', - ) - ); - - /** - * Update user-licensing activation notice dismiss info. - */ - register_rest_route( - 'jetpack/v4', - 'licensing/user/activation-notice-dismiss', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::update_licensing_activation_notice_dismiss', - 'permission_callback' => __CLASS__ . '::user_licensing_permission_check', - 'args' => array( - 'last_detached_count' => array( - 'required' => true, - 'type' => 'integer', - 'validate_callback' => __CLASS__ . '::validate_non_neg_int', - ), - ), - ) - ); - - /** - * Attach licenses to user account - */ - register_rest_route( - 'jetpack/v4', - '/licensing/attach-licenses', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::attach_jetpack_licenses', - 'permission_callback' => __CLASS__ . '::user_licensing_permission_check', - 'args' => array( - 'licenses' => array( - 'required' => true, - 'type' => 'array', - 'items' => array( - 'type' => 'string', - ), - ), - ), - ) - ); - } - - /** - * Verify that the user can set a Jetpack license key - * - * @since 1.7.0 - * - * @since-jetpack 9.5.0 - * - * @return bool|WP_Error True if user is able to set a Jetpack license key - */ - public static function set_jetpack_license_key_permission_check() { - if ( Licensing::instance()->is_licensing_input_enabled() ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_set_jetpack_license_key', self::$user_permissions_error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Verify that user can view and update user-licensing data. - * - * @since 1.7.0 - * - * @return bool Whether the user is currently connected and they are the connection owner. - */ - public static function user_licensing_permission_check() { - $connection_manager = new Connection_Manager( 'jetpack' ); - - if ( $connection_manager->is_user_connected() && $connection_manager->is_connection_owner() ) { - return true; - } - - return new WP_Error( 'invalid_permission_manage_user_licenses', self::$user_permissions_error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Verify that user can manage_options - * - * @since 1.7.0 - * - * @return bool Whether user has the capability 'manage_options'. - */ - public static function can_manage_options_check() { - if ( current_user_can( 'manage_options' ) ) { - return true; - } - - return new WP_Error( 'invalid_user_permission_view_admin', self::$user_permissions_error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Validates that the parameter is a string. - * - * @since 1.7.0 - * - * @since-jetpack 4.3.0 - * - * @param string $value Value to check. - * @param WP_REST_Request $request The request sent to the WP REST API. - * @param string $param Name of the parameter passed to endpoint holding $value. - * - * @return bool|WP_Error - */ - public static function validate_string( $value, $request, $param ) { - if ( ! is_string( $value ) ) { - /* translators: %s: The literal parameter name. Should not be translated. */ - return new WP_Error( 'invalid_param', sprintf( esc_html__( '%s must be a string.', 'jetpack-licensing' ), $param ) ); - } - return true; - } - - /** - * Validates that the parameter is a non-negative integer (includes 0). - * - * @since 1.7.0 - * - * @since-jetpack 10.4.0 - * - * @param int $value Value to check. - * @param WP_REST_Request $request The request sent to the WP REST API. - * @param string $param Name of the parameter passed to endpoint holding $value. - * - * @return bool|WP_Error - */ - public static function validate_non_neg_int( $value, $request, $param ) { - if ( ! is_numeric( $value ) || $value < 0 ) { - return new WP_Error( - 'invalid_param', - /* translators: %s: The literal parameter name. Should not be translated. */ - sprintf( esc_html__( '%s must be a non-negative integer.', 'jetpack-licensing' ), $param ) - ); - } - return true; - } - - /** - * Update the last licensing error message. - * - * @since 1.7.0 - * - * @since-jetpack 9.0.0 - * - * @param WP_REST_Request $request The request. - * - * @return bool true. - */ - public static function update_licensing_error( $request ) { - Licensing::instance()->log_error( $request['error'] ); - - return true; - } - - /** - * Get the last licensing error message, if any. - * - * @since 1.7.0 - * - * @since-jetpack 9.0.0 - * - * @return string Licensing error message or empty string. - */ - public static function get_licensing_error() { - return Licensing::instance()->last_error(); - } - - /** - * Set a Jetpack license - * - * @since 1.7.0 - * - * @since-jetpack 9.6.0 - * - * @param WP_REST_Request $request The request. - * - * @return WP_REST_Response|WP_Error A response object if the option was successfully updated, or a WP_Error if it failed. - */ - public static function set_jetpack_license( $request ) { - $license = trim( sanitize_text_field( $request['license'] ) ); - - if ( Licensing::instance()->append_license( $license ) ) { - return rest_ensure_response( array( 'code' => 'success' ) ); - } - - return new WP_Error( - 'setting_license_key_failed', - esc_html__( 'Could not set this license key. Please try again.', 'jetpack-licensing' ), - array( 'status' => 500 ) - ); - } - - /** - * Gets the users licenses. - * - * @since 1.7.0 - * - * @since-jetpack 10.4.0 - * - * @return string|WP_Error A JSON object of user licenses if the request was successful, or a WP_Error otherwise. - */ - public static function get_user_licenses() { - $wpcom_request = Client::wpcom_json_api_request_as_user( - '/jetpack-licensing/user/licenses', - '2', - array( - 'method' => 'GET', - 'headers' => array( - 'Content-Type' => 'application/json', - 'X-Forwarded-For' => ( new Visitor() )->get_ip( true ), - ), - ) - ); - - $response_code = wp_remote_retrieve_response_code( $wpcom_request ); - if ( 200 === $response_code ) { - $licenses = json_decode( wp_remote_retrieve_body( $wpcom_request ) ); - return $licenses; - } else { - return new WP_Error( - 'failed_to_fetch_data', - esc_html__( 'Unable to fetch the requested data.', 'jetpack-licensing' ), - array( 'status' => $response_code ) - ); - } - } - - /** - * Gets the users licenses counts. - * - * @since 1.7.0 - * - * @since-jetpack 10.4.0 - * - * @return string|WP_Error A JSON object of user license counts if the request was successful, or a WP_Error otherwise. - */ - public static function get_user_license_counts() { - $wpcom_request = Client::wpcom_json_api_request_as_user( - '/jetpack-licensing/user/licenses/counts', - '2', - array( - 'method' => 'GET', - 'headers' => array( - 'Content-Type' => 'application/json', - 'X-Forwarded-For' => ( new Visitor() )->get_ip( true ), - ), - ) - ); - - $response_code = wp_remote_retrieve_response_code( $wpcom_request ); - if ( 200 === $response_code ) { - $license_counts = json_decode( wp_remote_retrieve_body( $wpcom_request ) ); - return $license_counts; - } else { - return new WP_Error( - 'failed_to_fetch_data', - esc_html__( 'Unable to fetch the requested data.', 'jetpack-licensing' ), - array( 'status' => $response_code ) - ); - } - } - - /** - * Update the user-licenses activation notice dismissal data. - * - * @since 1.7.0 - * - * @since-jetpack 10.4.0 - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return array|WP_Error - */ - public static function update_licensing_activation_notice_dismiss( $request ) { - - if ( ! isset( $request['last_detached_count'] ) ) { - return new WP_Error( 'invalid_param', esc_html__( 'Missing parameter "last_detached_count".', 'jetpack-licensing' ), array( 'status' => 404 ) ); - } - - $default = array( - 'last_detached_count' => null, - 'last_dismissed_time' => null, - ); - $last_detached_count = ( '' === $request['last_detached_count'] ) - ? $default['last_detached_count'] - : $request['last_detached_count']; - $last_dismissed_time = ( '' === $request['last_detached_count'] ) - ? $default['last_dismissed_time'] - // Use UTC timezone and convert to ISO8601 format(DateTime::W3C) for best compatibility with JavaScript Date in all browsers. - : ( new \DateTime( 'NOW', new \DateTimeZone( 'UTC' ) ) )->format( \DateTime::W3C ); - - $notice_data = array( - 'last_detached_count' => $last_detached_count, - 'last_dismissed_time' => $last_dismissed_time, - ); - - Jetpack_Options::update_option( 'licensing_activation_notice_dismiss', $notice_data, true ); - return rest_ensure_response( $notice_data ); - } - - /** - * Attach Jetpack licenses - * - * @since 1.7.0 - * - * @since-jetpack 10.4.0 - * - * @param WP_REST_Request $request The request. - * - * @return WP_REST_Response|WP_Error A response object - */ - public static function attach_jetpack_licenses( $request ) { - $licenses = array_map( - function ( $license ) { - return trim( sanitize_text_field( $license ) ); - }, - $request['licenses'] - ); - return rest_ensure_response( Licensing::instance()->attach_licenses( $licenses ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php deleted file mode 100644 index 1cdaa4a8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php +++ /dev/null @@ -1,359 +0,0 @@ -register_endpoints(); - } - - /** - * Get Jetpack connection manager instance. - * - * @return Connection_Manager - */ - protected function connection() { - static $connection; - - if ( null === $connection ) { - $connection = new Connection_Manager(); - } - - return $connection; - } - - /** - * Get the last license attach request error that has occurred, if any. - * - * @return string Human-readable error message or an empty string. - */ - public function last_error() { - return Jetpack_Options::get_option( 'licensing_error', '' ); - } - - /** - * Log an error to be surfaced to the user at a later time. - * - * @param string $error Human-readable error message. - * @return void - */ - public function log_error( $error ) { - $substr = function_exists( 'mb_substr' ) ? 'mb_substr' : 'substr'; - Jetpack_Options::update_option( 'licensing_error', $substr( $error, 0, 1024 ) ); - } - - /** - * Get all stored licenses. - * - * @return string[] License keys. - */ - public function stored_licenses() { - $licenses = (array) get_option( self::LICENSES_OPTION_NAME, array() ); - $licenses = array_filter( $licenses, 'is_scalar' ); - $licenses = array_map( 'strval', $licenses ); - $licenses = array_filter( $licenses ); - - return $licenses; - } - - /** - * Append a license - * - * @param string $license A jetpack license key. - * @return bool True if the option was updated with the new license, false otherwise. - */ - public function append_license( $license ) { - $licenses = $this->stored_licenses(); - - array_push( $licenses, $license ); - - return update_option( self::LICENSES_OPTION_NAME, $licenses ); - } - - /** - * Make an authenticated WP.com XMLRPC multicall request to attach the provided license keys. - * - * @param string[] $licenses License keys to attach. - * @return Jetpack_IXR_ClientMulticall - */ - protected function attach_licenses_request( array $licenses ) { - $xml = new Jetpack_IXR_ClientMulticall( array( 'timeout' => 30 ) ); - - foreach ( $licenses as $license ) { - $xml->addCall( 'jetpack.attachLicense', $license ); - } - - $xml->query(); - - return $xml; - } - - /** - * Attach the given licenses. - * - * @param string[] $licenses Licenses to attach. - * @return array|WP_Error Results for each license (which may include WP_Error instances) or a WP_Error instance. - */ - public function attach_licenses( array $licenses ) { - if ( ! $this->connection()->has_connected_owner() ) { - return new WP_Error( 'not_connected', __( 'Jetpack doesn\'t have a connected owner.', 'jetpack-licensing' ) ); - } - - if ( empty( $licenses ) ) { - return array(); - } - - $xml = $this->attach_licenses_request( $licenses ); - - if ( $xml->isError() ) { - $error = new WP_Error( 'request_failed', __( 'License attach request failed.', 'jetpack-licensing' ) ); - $error->add( $xml->getErrorCode(), $xml->getErrorMessage() ); - return $error; - } - - $results = array_map( - function ( $response ) { - if ( isset( $response['faultCode'] ) || isset( $response['faultString'] ) ) { - return new WP_Error( $response['faultCode'], $response['faultString'] ); - } - - return $response; - }, - (array) $xml->getResponse() - ); - - return $results; - } - - /** - * Attach all stored licenses. - * - * @return array|WP_Error Results for each license (which may include WP_Error instances) or a WP_Error instance. - */ - public function attach_stored_licenses() { - $licenses = $this->stored_licenses(); - $results = $this->attach_licenses( $licenses ); - - if ( is_wp_error( $results ) ) { - if ( 'request_failed' === $results->get_error_code() ) { - $this->log_error( - __( 'Failed to attach your Jetpack license(s). Please try reconnecting Jetpack.', 'jetpack-licensing' ) - ); - } - - return $results; - } - - $failed = array(); - - foreach ( $results as $index => $result ) { - if ( isset( $licenses[ $index ] ) && is_wp_error( $result ) ) { - $failed[] = $licenses[ $index ]; - } - } - - if ( ! empty( $failed ) ) { - $this->log_error( - sprintf( - /* translators: %s is a comma-separated list of license keys. */ - __( 'The following Jetpack licenses are invalid, already in use, or revoked: %s', 'jetpack-licensing' ), - implode( ', ', $failed ) - ) - ); - } - - return $results; - } - - /** - * Attach all stored licenses during connection flow for the connection owner. - * - * @return void - */ - public function attach_stored_licenses_on_connection() { - if ( $this->connection()->is_connection_owner() ) { - $this->attach_stored_licenses(); - } - } - - /** - * Is the current user allowed to use the Licensing Input UI? - * - * @since 1.4.0 - * @return bool - */ - public static function is_licensing_input_enabled() { - /** - * Filter that checks if the user is allowed to see the Licensing UI. `true` enables it. - * - * @since 1.4.0 - * - * @param bool False by default. - */ - return apply_filters( 'jetpack_licensing_ui_enabled', false ) && current_user_can( 'jetpack_connect_user' ); - } - - /** - * Gets the user-licensing activation notice dismissal info. - * - * @since 10.4.0 - * @return array - */ - public function get_license_activation_notice_dismiss() { - - $default = array( - 'last_detached_count' => null, - 'last_dismissed_time' => null, - ); - - if ( $this->connection()->is_user_connected() && $this->connection()->is_connection_owner() ) { - return Jetpack_Options::get_option( 'licensing_activation_notice_dismiss', $default ); - } - - return $default; - } - - /** - * Load current user's licenses. - * - * @param bool $unattached_only Only return unattached and not revoked licenses. - * - * @return array - */ - public function get_user_licenses( $unattached_only = false ) { - $licenses = Endpoints::get_user_licenses(); - - if ( empty( $licenses->items ) ) { - return array(); - } - - $items = $licenses->items; - - if ( $unattached_only ) { - $items = array_filter( - $items, - static function ( $item ) { - return $item->attached_at === null && $item->revoked_at === null; - } - ); - } - - return $items; - } - - /** - * If the destination URL is checkout page, - * see if there are unattached licenses they could use instead of getting a new one. - * If found, redirect the user to license activation. - * - * @param string $dest_url User's destination URL. - * - * @return void - */ - public function handle_user_connected_redirect( $dest_url ) { - if ( ! preg_match( '#^https://[^/]+/checkout/#i', $dest_url ) ) { - return; - } - - $licenses = $this->get_user_licenses( true ); - $plugin_slug = null; - - $query_string = wp_parse_url( $dest_url, PHP_URL_QUERY ); - if ( $query_string ) { - parse_str( $query_string, $query_args ); - - if ( $query_args['redirect_to'] - && preg_match( '/^admin\.php\?page=(jetpack-\w+)/i', $query_args['redirect_to'], $matches ) - ) { - $plugin_slug = $matches[1]; - } - } - - /** - * Check for the user's unattached licenses. - * - * @since 3.8.2 - * - * @param bool $has_license Whether a license was already found. - * @param array $licenses Unattached licenses belonging to the user. - * @param string $plugin_slug Slug of the plugin that initiated the flow. - */ - if ( $plugin_slug && count( $licenses ) - && apply_filters( 'jetpack_connection_user_has_license', false, $licenses, $plugin_slug ) - ) { - wp_safe_redirect( '/wp-admin/admin.php?page=my-jetpack#/add-license' ); - exit( 0 ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/CHANGELOG.md deleted file mode 100644 index 89fcd8e2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/CHANGELOG.md +++ /dev/null @@ -1,253 +0,0 @@ -# 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). - -## [3.0.4] - 2025-03-21 -### Changed -- Internal updates. - -## [3.0.3] - 2025-03-12 -### Changed -- Internal updates. - -## [3.0.2] - 2025-03-05 -### Changed -- Internal updates. - -## [3.0.1] - 2025-02-24 -### Changed -- Update dependencies. - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.0.5] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.0.4] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [2.0.3] - 2024-05-20 -### Changed -- Replaced heredoc syntax with strings. [#37396] - -## [2.0.2] - 2024-03-18 -### Changed -- Internal updates. - -## [2.0.1] - 2024-03-12 -### Changed -- Internal updates. - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.6.3] - 2023-09-19 - -- Minor internal updates. - -## [1.6.2] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.6.1] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.6.0] - 2023-04-04 -### Added -- Add new method to get a base64 encoded SVG of the Jetpack logo. [#29418] - -## [1.5.22] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.5.21] - 2023-01-30 -### Changed -- Updated styles for Just in Time Messages (notices) [#27515] - -## [1.5.20] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.5.19] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.5.18] - 2022-11-07 -### Changed -- Updated package dependencies. - -## [1.5.17] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.5.16] - 2022-06-21 -### Changed -- Renaming master to trunk. [#24661] - -## [1.5.15] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.5.14] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.5.13] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.5.12] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.5.11] - 2021-11-30 -### Changed -- Colors: update Jetpack Primary color to match latest brand book. - -## [1.5.10] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.5.9] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.5.8] - 2021-10-07 -### Changed -- Updated package dependencies - -## [1.5.7] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.5.6] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- update annotations versions - -## [1.5.5] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.5.4] - 2021-04-27 -### Changed -- Updated package dependencies. - -## [1.5.3] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.5.2] - 2021-02-05 - -- CI: Make tests more generic - -## [1.5.1] - 2021-01-19 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.5.0] - 2020-12-07 - -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.4.0] - 2020-08-13 - -- CI: Try collect js coverage - -## [1.3.0] - 2020-06-22 - -- PHPCS: Clean up the packages -- PHPCS Updates after WPCS 2.3 - -## [1.2.0] - 2020-03-27 - -- Use dynamic Jetpack logos on JITMs - -## [1.1.4] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.1.2] - 2019-10-28 - -- Packages: Add gitattributes files to all packages that need th… - -## [1.1.1] - 2019-09-20 - -- Docs: Unify usage of @package phpdoc tags - -## [1.1.0] - 2019-06-11 - -- Feature/jetpack packages pt 1. (May 31 - June 6) -- Update/package logo add gray -- Packages: Move JITM tests to package and fix deps -- Update Jetpack to use new JITM package -- Packages: Make logo package tests independent - -## 1.0.0 - 2019-05-29 - -- Packages: Add a basic Jetpack Logo package - -[3.0.4]: https://github.com/Automattic/jetpack-logo/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-logo/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-logo/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-logo/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-logo/compare/v2.0.5...v3.0.0 -[2.0.5]: https://github.com/Automattic/jetpack-logo/compare/v2.0.4...v2.0.5 -[2.0.4]: https://github.com/Automattic/jetpack-logo/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-logo/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-logo/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-logo/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-logo/compare/v1.6.3...v2.0.0 -[1.6.3]: https://github.com/Automattic/jetpack-logo/compare/v1.6.2...v1.6.3 -[1.6.2]: https://github.com/Automattic/jetpack-logo/compare/v1.6.1...v1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-logo/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-logo/compare/v1.5.22...v1.6.0 -[1.5.22]: https://github.com/Automattic/jetpack-logo/compare/v1.5.21...v1.5.22 -[1.5.21]: https://github.com/Automattic/jetpack-logo/compare/v1.5.20...v1.5.21 -[1.5.20]: https://github.com/Automattic/jetpack-logo/compare/v1.5.19...v1.5.20 -[1.5.19]: https://github.com/Automattic/jetpack-logo/compare/v1.5.18...v1.5.19 -[1.5.18]: https://github.com/Automattic/jetpack-logo/compare/v1.5.17...v1.5.18 -[1.5.17]: https://github.com/Automattic/jetpack-logo/compare/v1.5.16...v1.5.17 -[1.5.16]: https://github.com/Automattic/jetpack-logo/compare/v1.5.15...v1.5.16 -[1.5.15]: https://github.com/Automattic/jetpack-logo/compare/v1.5.14...v1.5.15 -[1.5.14]: https://github.com/Automattic/jetpack-logo/compare/v1.5.13...v1.5.14 -[1.5.13]: https://github.com/Automattic/jetpack-logo/compare/v1.5.12...v1.5.13 -[1.5.12]: https://github.com/Automattic/jetpack-logo/compare/v1.5.11...v1.5.12 -[1.5.11]: https://github.com/Automattic/jetpack-logo/compare/v1.5.10...v1.5.11 -[1.5.10]: https://github.com/Automattic/jetpack-logo/compare/v1.5.9...v1.5.10 -[1.5.9]: https://github.com/Automattic/jetpack-logo/compare/v1.5.8...v1.5.9 -[1.5.8]: https://github.com/Automattic/jetpack-logo/compare/v1.5.7...v1.5.8 -[1.5.7]: https://github.com/Automattic/jetpack-logo/compare/v1.5.6...v1.5.7 -[1.5.6]: https://github.com/Automattic/jetpack-logo/compare/v1.5.5...v1.5.6 -[1.5.5]: https://github.com/Automattic/jetpack-logo/compare/v1.5.4...v1.5.5 -[1.5.4]: https://github.com/Automattic/jetpack-logo/compare/v1.5.3...v1.5.4 -[1.5.3]: https://github.com/Automattic/jetpack-logo/compare/v1.5.2...v1.5.3 -[1.5.2]: https://github.com/Automattic/jetpack-logo/compare/v1.5.1...v1.5.2 -[1.5.1]: https://github.com/Automattic/jetpack-logo/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-logo/compare/v1.4.0...v1.5.0 -[1.4.0]: https://github.com/Automattic/jetpack-logo/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-logo/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-logo/compare/v1.1.4...v1.2.0 -[1.1.4]: https://github.com/Automattic/jetpack-logo/compare/v1.1.2...v1.1.4 -[1.1.2]: https://github.com/Automattic/jetpack-logo/compare/v1.1.1...v1.1.2 -[1.1.1]: https://github.com/Automattic/jetpack-logo/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-logo/compare/v1.0.0...v1.1.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/composer.json deleted file mode 100644 index 6c957c4d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/composer.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "name": "automattic/jetpack-logo", - "description": "A logo for Jetpack", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-logo", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-logo/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php deleted file mode 100644 index 31b5b501..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php +++ /dev/null @@ -1,122 +0,0 @@ - tag. - * - jetpack-logo__icon-circle: the circle of the Jetpack mark. - * - jetpack-logo__icon-triangle: two shapes that correspond to each triangle in the Jetpack mark. - * - jetpack-logo__icon-text: the Jetpack lettering. - * - * @var string - */ -const JETPACK_LOGO_SVG = ' - -'; - -/** - * Create and render a Jetpack logo. - */ -class Logo { - - /** - * Return the Jetpack logo. - * - * @return string The Jetpack logo. - */ - public function render() { - return JETPACK_LOGO_SVG; - } - - /** - * Return string containing the Jetpack logo. - * - * @since 1.1.4 - * @since-jetpack 7.5.0 - * - * @param bool $logotype Should we use the full logotype (logo + text). Default to false. - * - * @return string - */ - public function get_jp_emblem( $logotype = false ) { - $logo_text = $this->get_jp_logo_parts(); - return sprintf( - '%2$s', - ( true === $logotype ? '118' : '32' ), - ( true === $logotype ? $logo_text['logo'] . $logo_text['text'] : $logo_text['logo'] ) - ); - } - - /** - * Return string containing the Jetpack logo in a slightly larger format than get_jp_emblem(). - * - * @since 1.1.4 - * @param bool $logotype Should we use the full logotype (logo + text). Default to false. - * @return string - */ - public function get_jp_emblem_larger( $logotype = false ) { - $logo_text = $this->get_jp_logo_parts(); - return sprintf( - '', - ( true === $logotype ? '118' : '32' ), - ( true === $logotype ? $logo_text['logo'] . $logo_text['text'] : $logo_text['logo'] ) - ); - } - - /** - * Return array containing the Jetpack logo and text - * - * @since 1.6.0 - Added $color parameter. - * - * @param string $color The color of the logo. - * - * @return array - */ - private function get_jp_logo_parts( $color = '#069e08' ) { - return array( - 'logo' => '', - 'text' => ' - - - - - - ', - ); - } - - /** - * Return a base64 encoded SVG of the Jetpack logo. - * Can be used as a data URI to use the logo inline in CSS. - * - * @since 1.6.0 - * - * @param string $color The color of the logo. - * - * @return string - */ - public function get_base64_logo( $color = '#ffffff' ) { - $logo_text = $this->get_jp_logo_parts( $color ); - $base_logo = sprintf( - '%1$s', - $logo_text['logo'] - ); - $encoded_logo = base64_encode( $base_logo ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode -- The encoded version is used as data URI to use the logo in CSS. - - return 'data:image/svg+xml;base64,' . $encoded_logo; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/CHANGELOG.md deleted file mode 100644 index 352b1d6b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/CHANGELOG.md +++ /dev/null @@ -1,2314 +0,0 @@ -# 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). - -## [5.9.1] - 2025-03-24 -### Changed -- Update dependencies. [#38910] - -## [5.9.0] - 2025-03-24 -### Added -- Add an email input to the social login form, allowing users to log into Jetpack seamlessly through a magic link. [#42600] -- Add a new social login form to the onboarding screen for first-time Jetpack connections. [#42561] - -## [5.8.0] - 2025-03-21 -### Added -- Introduce a new onboarding screen to provide clear, step-by-step instructions for new users connecting to Jetpack. [#42523] - -### Fixed -- Enable screen readers to read Boost score. [#42306] - -## [5.7.3] - 2025-03-19 -### Changed -- Update dependencies. [#38910] - -## [5.7.2] - 2025-03-18 -### Changed -- Update package dependencies. [#42509] [#42511] - -### Fixed -- My Jetpack: Add legacy properties back to `get_info()` function. [#42542] -- Product Interstitial Modal: Fix not running custom onClick events if a customModalTrigger was used. [#42527] - -## [5.7.1] - 2025-03-17 -### Fixed -- Allow screen readers to read stats. [#42275] - -## [5.7.0] - 2025-03-17 -### Changed -- Call Protect and VideoPress product data on the frontend and remove from window state. [#42411] -- My Jetpack: Move Red Bubble notifications out of myJetpackInitialState. [#42271] -- UI: Upgrade CTAs on the Jetpack Boost admin now opens a modal instead of navigating to the upgrade page. [#42309] - -### Fixed -- My Jetpack: Fix interstitial modal that was displaying the discounted price when user had already used up the discount. [#42349] - -## [5.6.0] - 2025-03-12 -### Added -- Add QueryProvider to ProductInterstitialModal for extendability. [#42307] -- Provide connection data to footer component. [#42000] -- Stats: Add highlights heading level as prop. [#42165] - -### Changed -- Load agency data from frontend instead of backend. [#42330] - -## [5.5.3] - 2025-03-10 -### Changed -- Persist cookies for dismissable banners longer than session. [#42305] - -## [5.5.2] - 2025-03-05 -### Changed -- Remove purchases from window state and query entirely using state query on front end. [#42154] -- Update package dependencies. [#42162] - -## [5.5.1] - 2025-03-03 -### Added -- Update interstitial modal to accept custom trigger. [#41621] - -### Changed -- Load product data requiring an http request async on the frontend. [#41965] -- Move the getting of product ownership data entirely to the frontend. [#42080] -- Move update to historically active modules to frontend. [#42133] -- Update package dependencies. [#42081] [#42163] - -### Fixed -- Fix skip to main content feature [#42042] - -## [5.5.0] - 2025-02-24 -### Changed -- Allow users to manage user connection in My Jetpack. [#41398] -- Move backup endpoint to product class. [#41730] -- Update package dependencies. [#41955] - -### Removed -- Script data: Remove unused property. [#41890] - -### Fixed -- Code: Prevent dynamic class properties. [#41857] -- Fix My Jetpack display for non-admin users. [#41398] -- Improve accessibility for product card actions with ARIA labelling. [#41896] -- Increase product card status contrast ratio. [#41896] -- Move product card status before action for screen readers. [#41896] - -## [5.4.5] - 2025-02-17 -### Changed -- Social: Update manage module link to point to the new Social admin page. [#41741] - -## [5.4.4] - 2025-02-12 -### Changed -- Performance: Cache scan calls if no threats are found. [#41614] - -## [5.4.3] - 2025-02-11 -### Added -- My Jetpack: Allow product notices to be closed with persistence. [#41617] - -### Changed -- Make entire row of dataview clickable when on mobile [#41643] - -## [5.4.2] - 2025-02-10 -### Added -- Add filter to unowned list of products. [#41312] -- Add mobile CTA to DataViews table. [#41554] - -### Changed -- Cache calls to backup API in My Jetpack. [#41608] -- Update package dependencies. [#41491] [#41577] -- Update the unowned section from a product grid to a product list. [#41312] - -### Fixed -- Fix bug where firewall was displayed as active if automatic rules were enabled but firewall was off. [#41560] - -## [5.4.1] - 2025-02-03 -### Added -- My Jetpack: Add red bubble and notice when pain plan is missing plugin. [#41013] - -### Changed -- Make Action Button component more reusable. [#41361] -- Replace Jetpack AI upgrade page with a modal. [#41301] -- Update package dependencies. [#41286] -- Update My Jetpack interstitial modal with new styles and layout. [#41300] - -### Fixed -- AI: Avoid using relative URLs in admin URLs to support sites where WordPress is installed in a subdirectory. [#41459] -- Code: Remove extra params on function calls. [#41263] -- My Jetpack: Fix secondary action of Protect card when plugin is not installed. [#41347] - -## [5.4.0] - 2025-01-23 -### Added -- Adding new modal based interstitial component. [#40945] - -### Fixed -- Fix bug where My Jetpack would throw critical error if only a standalone plugin is not installed. [#41192] - -## [5.3.3] - 2025-01-20 -### Added -- Add caching for the red bubble alerts for My Jetpack. [#41131] -- Add option for devs to reset jetpack options from My Jetpack footer. [#40943] -- Add sandboxed tag to My Jetpack. [#40971] - -### Changed -- Updated package dependencies. [#41099] - -## [5.3.2] - 2025-01-14 -### Fixed -- Fix bug where description doesn't show up on backup card in specific scenarios. [#40904] - -## [5.3.1] - 2025-01-10 -### Added -- Add new WAF status on Protect card for when WAF is unsupported. [#40880] - -### Changed -- Show an upgrade CTA anytime a product has an available upgrade. [#40900] - -## [5.3.0] - 2025-01-06 -### Added -- My Jetpack: Added a new status for when Protect detects threats on the site. [#40628] -- My Jetpack: Adds a red bubble and notice when Protect threats are detected. [#40719] -- My Jetpack: introduce feature cards for recommendations in My Jetpack. [#40639] - -### Changed -- Updated package dependencies. [#40705] [#40798] [#40810] [#40841] - -### Fixed -- Tests: Fix failure on 31 December. [#40781] - -## [5.2.0] - 2024-12-23 -### Added -- My Jetpack: add features as possible modules to the recommendations list. [#40492] - -### Changed -- My Jetpack: Add 'Needs attention' status to Backup product card when Backups are failing. [#40454] -- My Jetpack: Add red bubble and notice/banner when Backup has 'needs-attention' status. [#40512] -- My Jetpack: Plans section: Improvements to how we display plan expiration date. [#40575] -- My Jetpack: Protect card- Fixed Tooltip placement & content issues. [#40691] -- Unify connection flows in My Jetpack. [#40632] - -### Fixed -- Fix an issue where high posts counts would cause backend issues for the get_raw_post_type_breakdown function used in My Jetpack. Sites with over 100,000 posts can now have this query managed remotely. [#40635] -- Fix issue where backup card was not updating after site connection in some situations. [#40653] - -## [5.1.2] - 2024-12-16 -### Added -- Add AI to Complete feature copy. [#40577] - -### Changed -- Remove purchase related elements when Complete is on site. [#40554] -- Updated package dependencies. [#40564] - -### Fixed -- Fixed lints following ESLint rule changes for TS. [#40584] -- My Jetpack: fix animation flick on connection screen in My Jetpack. [#40533] - -## [5.1.1] - 2024-12-04 -### Changed -- Updated package dependencies. [#40363] - -## [5.1.0] - 2024-12-02 -### Added -- Add animation during site connection. [#40343] -- Add "loading" animation to recommendations step. [#40405] - -### Changed -- Fix usage of random() in animation to prevent build step from generating a different CSS file every time. [#40413] - -### Removed -- Remove experiment code. [#40406] - -### Fixed -- Fix My Jetpack recommendation card styling on mobile [#40370] - -## [5.0.4] - 2024-11-28 -### Added -- Added "Expired" & "Expires soon" statuses to My Jetpack product cards. [#39816] - -### Changed -- Social | Changed My Jetpack CTA for Social from "Learn more" to "Activate" [#40359] - -### Fixed -- Fix stats not showing sale discount [#40348] - -## [5.0.3] - 2024-11-26 -### Changed -- Update dependencies. [#38910] - -## [5.0.2] - 2024-11-25 -### Added -- Add bundles to recommendations and add interstitials for them [#40281] -- Add growth upsell to Stats and Social interstitials [#40236] - -### Changed -- Notices: do not display the Jetpack Manage banners for accounts enrolled into our agency program. [#40251] -- Remove creator card and update paid plan checks to account for growth [#40192] -- Updated dependencies. [#40286] -- Updated feature for stats in growth to 10K instead of 100K [#40312] -- Updated package dependencies. [#40288] - -## [5.0.1] - 2024-11-18 -### Changed -- Update dependencies. [#38910] - -## [5.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [4.37.0] - 2024-11-11 -### Added -- My Jetpack: update the recommendations section in My Jetpack to include a slider interaction for the cards. [#39850] - -### Changed -- Admin: Updating deprecation notices. [#39567] -- Updated package dependencies. [#39999] [#40000] [#40060] - -## [4.36.0] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -### Changed -- My Jetpack: Add experiment to the post-connection flow in My Jetpack. [#39902] -- Skip pricing page when connecting via block editor. [#39865] - -### Removed -- My Jetpack: Remove A/B test code in My Jetpack. [#39928] - -## [4.35.16] - 2024-10-29 -### Changed -- Components: Add __nextHasNoMarginBottom to BaseControl-based components, preventing deprecation notices. [#39877] - -## [4.35.15] - 2024-10-17 -### Fixed -- Fix the "Missing site connection" notice. [#39809] - -## [4.35.14] - 2024-10-15 -### Changed -- Update dependencies. [#38910] - -## [4.35.13] - 2024-10-14 -### Changed -- Only include `wp-polyfill` as a script dependency when needed. [#39629] - -## [4.35.12] - 2024-10-10 -### Changed -- Update Boost's pricing table to include latest feature list. [#39130] -- Updated package dependencies. [#39669] [#39707] - -### Fixed -- Fixed My Jetpack recommendations VideoPress product card not showing Purchase and Learn more buttons. [#39612] - -## [4.35.11] - 2024-10-07 -### Changed -- Updated package dependencies. [#39594] - -## [4.35.10] - 2024-10-02 -### Changed -- Internal updates. - -## [4.35.9] - 2024-09-30 -### Changed -- Fix parameters to allow for connectAfterCheckout flow from recommendation card [#39578] -- My Jetpack Welcome Flow: Display default recommendations upfront first, then offer optional survey for customized recommendations. [#39485] - -### Fixed -- Fixed a bug where the purchases and highlights APIs were being called without a valid Jetpack connection [#39522] -- My Jetpack: visual update to make the GlobalNotice component look better on mobile. [#39537] - -## [4.35.8] - 2024-09-25 -### Changed -- Update dependencies. [#38910] - -## [4.35.7] - 2024-09-23 -### Changed -- Get active element from tooltip button's document rather than the global `document`. [#39364] -- My Jetpack product interstitial: Don't show intro offer price if user is not eligible for the offer. [#39403] -- Send non-connected users to a "connect after checkout" flow [#39444] - -### Fixed -- Fix issue on interstitials show both buttons loading when only one is pressed [#39356] -- Fix issue where recommendations are showing slightly before the welcome banner dismisses [#39383] - -## [4.35.6] - 2024-09-16 -### Added -- Add new action myjetpack_enqueue_scripts [#39380] - -### Changed -- My Jetpack: Always show the purchase link regardless of the number of plans owned. [#39299] -- Updated package dependencies. [#39332] - -## [4.35.5] - 2024-09-10 -### Changed -- Updated package dependencies. [#39302] - -## [4.35.4] - 2024-09-09 -### Added -- Jetpack AI: add fair usage policy link to the Jetpack AI product interstitial. [#39281] - -### Changed -- Updated package dependencies. [#39278] - -### Fixed -- Jetpack AI: fix default_content filter so it doesn't enforce parameter type [#39276] - -## [4.35.3] - 2024-09-06 -### Fixed -- Optimize repeated requests for unavailable WPCOM. [#39218] - -## [4.35.2] - 2024-09-06 -### Changed -- Internal updates. - -## [4.35.1] - 2024-09-05 -### Changed -- Internal updates. - -## [4.35.0] - 2024-09-05 -### Added -- My Jetpack: add support for feature-specific handling to product interstitials. [#38661] - -### Changed -- Jetpack AI product page: add fair usage link on over quota notice [#39192] -- Updated package dependencies. [#39176] - -### Fixed -- Gracefully fail when user data fetch failed. [#39179] - -## [4.34.0] - 2024-09-02 -### Changed -- My Jetpack: show over quota notice and period usage counter for unlimited plans [#39129] -- We update Welcome Flow A/B experiment to test other things [#39154] - -### Fixed -- My Jetpack: change Jetpack AI post checkout URL so the redirect works [#39166] - -## [4.33.1] - 2024-08-29 -### Changed -- Admin menu: change order of Jetpack sub-menu items [#39095] -- My Jetpack: reflect tier filters properly on product class and UI. Fix little nuances with date constructor [#39074] -- Updated package dependencies. [#39111] - -### Fixed -- Don't consider user lifecycle status when repeating evaluation [#39069] -- My Jetpack: Fix the popover and active button of the Bboost card are overlapping [#39067] - -## [4.33.0] - 2024-08-26 -### Added -- Add context switching to videopress card from yearly views to monthly views [#38979] - -### Changed -- My Jetpack: AI product class to handle better disabling tiers [#38989] -- Updated package dependencies. [#39004] - -### Fixed -- allow user currency in My Jetpack pricing [#38977] -- Fix tooltip title for videopress card [#39030] - -## [4.32.4] - 2024-08-21 -### Changed -- Removed unnecessary WAF dependency in My Jetpack. [#38942] - -### Fixed -- Notification bubbles: avoid PHP warning when information is missing. [#38963] -- Revert recent SVG image optimizations. [#38981] - -## [4.32.3] - 2024-08-19 -### Added -- Add stat trends for videopress card. [#38868] -- Add tooltip to VideoPress card. [#38842] -- Add value to active card state on VideoPress My Jetpack card. [#38812] - -### Changed -- Updated package dependencies. [#38893] - -### Fixed -- Lossless image optimization for images (should improve performance with no visible changes). [#38750] -- My Jetpack: ensure product screens redirect to the correct post-checkout URLs. [#38704] - -## [4.32.2] - 2024-08-15 -### Changed -- Updated package dependencies. [#38665] - -### Fixed -- fix empty hrefs causing page reload [#38845] - -## [4.32.1] - 2024-08-09 -### Added -- Add value to the inactive state on the VideoPress card in My Jetpack [#38748] - -### Changed -- Update uses of useConnection to useMyJetpackConnection and improve typing in a few places [#38721] - -### Removed -- Tests: Removed react-test-renderer. [#38755] - -### Fixed -- My Jetpack: fix a bug where a user would see and infinite loading spinner when trying to connect Jetpack with one click in the Welcome flow. [#38813] - -## [4.32.0] - 2024-08-05 -### Added -- Add Tracks events for Welcome Flow [#38641] - -### Changed -- change Jetpack AI product page link redirect [#38691] -- copy updates [#38648] -- Modify the Google Analytics notice to notify of the feature removal. [#38701] - -## [4.31.0] - 2024-08-01 -### Added -- Update Welcome Banner and set async site-only connection [#38534] - -### Changed -- Fixup versions [#38612] -- My Jetpack: modify Jetpack AI product class and interstitial links [#38602] -- React: Changing global JSX namespace to React.JSX [#38585] - -## [4.30.0] - 2024-07-29 -### Added -- Async card update after async site connection [#38549] -- My Jetpack: add A/A experiment to test for correct random assignment and prevent bias in metric performance. [#38327] -- Show View button on product card along with upgrade cta [#38550] - -### Changed -- Final minor enhancements to the Protect product card in My Jetpack. [#38420] - -### Removed -- Remove functionality that hid 1 value on the backup card for mid-sized screens [#38441] - -### Fixed -- Include Jetpack Legacy plans when checking if user has social included with plan [#38516] -- Update all tracks to snake case, camel case is not supported [#38576] - -## [4.29.0] - 2024-07-22 -### Added -- Added the auto-firewall status to the Protect product card in My Jetpack. [#38332] -- Added the number of logins blocked to the Protect card in My Jetpack. [#38396] - -### Changed -- Connection Screen: Removed mention of Stats from the list of available free features. [#38328] -- Display My Jetpack products segemented by ownership. [#38283] -- My Jetpack: Updated social icons in the connection screen. [#38334] -- Updated statuses to make more sense in relation to ownership. [#38390] - -## [4.28.0] - 2024-07-15 -### Added -- Add scan/threat info to the Protect card in My Jetpack. [#38165] - -### Changed -- Protect card: Add the Last scan time (with tooltip) based on product state. [#38091] -- Updated package dependencies. [#38091] - -### Fixed -- Fix Learn More link destination when the site was never connected. [#38225] - -## [4.27.2] - 2024-07-10 -### Fixed -- Social: Fixed plan slug [#38222] - -## [4.27.1] - 2024-07-03 -### Changed -- Updated package dependencies. [#38132] - -## [4.27.0] - 2024-07-01 -### Added -- Add the Google Analytics deprecation notice. [#38078] - -### Changed -- Reduce amount of historically active modules updates by only triggering on activation of plugin is a jetpack plugin [#38065] - -### Fixed -- Fix an issue where the connection error hook was always resetting the notice [#38120] - -## [4.26.0] - 2024-06-27 -### Changed -- Jetpack AI: Add Title Optimization section on the product page. [#38072] - -## [4.25.4] - 2024-06-26 -### Fixed -- Move historically active modules sync to admin_init [#38041] - -## [4.25.3] - 2024-06-24 -### Added -- Add more default args for tracks events [#37974] - -## [4.25.2] - 2024-06-21 -### Fixed -- Remove the need for api requests in broken modules check [#37908] - -## [4.25.1] - 2024-06-17 -### Fixed -- Remove check for broken modules from red bubble connection check [#37911] - -## [4.25.0] - 2024-06-17 -### Changed -- Show tooltip on card hover instead of letter hover [#37858] -- Update connection footer to conditionally render warnings or errors [#37802] -- Update connection status card tests to TS [#37829] - -## [4.24.7] - 2024-06-13 -### Changed -- Updated package dependencies. [#37796] - -## [4.24.6] - 2024-06-11 -### Changed -- Conditionally show connection banner as error or info [#37707] -- Updated package dependencies. [#37779] - -## [4.24.5] - 2024-06-10 -### Changed -- Change codebase to use clsx instead of classnames. [#37708] - -## [4.24.4] - 2024-06-10 -### Added -- Add mechanism to track previously working plugins [#37537] - -### Changed -- Move PRODUCT_STATUSES to constants file [#37748] -- Send user to siteless pricing page if site is not connected [#37667] - -## [4.24.3] - 2024-06-05 -### Changed -- Updated package dependencies. [#37669] - -## [4.24.2] - 2024-06-03 -### Changed -- Update ToS wording. [#37536] -- Update CTA on A4A banner in My Jetpack. [#37628] - -## [4.24.1] - 2024-05-24 -### Changed -- Update Search to require user connection. [#37496] - -## [4.24.0] - 2024-05-23 -### Changed -- Improve the active/inactive statuses on My Jetpack. [#37217] - -## [4.23.3] - 2024-05-20 -### Added -- Add tracks events for dropdown on action buttons. [#37292] - -### Changed -- Updated package dependencies. [#37379] [#37380] [#37382] - -## [4.23.2] - 2024-05-09 -### Changed -- My Jetpack Agency banner copy change. [#37248] - -### Fixed -- Fix typo [#37303] - -## [4.23.1] - 2024-05-08 -### Changed -- Update dependencies. - -## [4.23.0] - 2024-05-06 -### Added -- Add a has_free_offering boolean on My Jetpack products. [#36710] -- Add copy for AI features on connection screen. [#37218] -- Define `$module_name` static property on `Hybrid_Product` (defaulting to null). [#37201] -- Jetpack AI: Add new badge to Featured Image video on the product page. [#37197] -- My Jetpack: Add errors from the connection package to the new notice component. [#36840] - -### Changed -- Change "go back" in My Jetpack interstitials to always return to the My Jetpack page. [#36685] -- Fix z-index issue and close action button dropdown when clicked outside. [#37169] -- Jetpack AI: Add featured image generation as a feature on the product interstitial. [#37199] -- Jetpack AI: Include video about featured image generation on the product page. [#37192] -- Updated package dependencies. [#37147] [#37148] [#37160] - -## [4.22.3] - 2024-04-29 -### Changed -- Internal updates. - -## [4.22.2] - 2024-04-25 -### Fixed -- My Jetpack: Fix issue where the TOS component was being called inside of a

            , throwing a warning that

            can't be a descendant of

            . This also fixes the font size of the TOS text. [#37034] - -## [4.22.1] - 2024-04-22 -### Changed -- Internal updates. - -## [4.22.0] - 2024-04-11 -### Added -- Add new tracking event for product activations made through My Jetpack [#36745] -- My Jetpack: add a way to connect a Jetpack site to WordPress.com asynchronously and update the message in the notice to reflect that. [#36771] - -### Fixed -- Ensure page_view gets loaded before product_card_loaded [#36790] - -## [4.21.0] - 2024-04-08 -### Added -- Add 'from' property to connection call to WP.com. [#36741] -- My Jetpack: Update Notice component to allow adding a loading text when an action is in a loading state. Add a new resetNotice action to NoticeContext. [#36614] - -### Changed -- My Jetpack: Show Boost score increase in Boost product card. [#36072] -- Updated package dependencies. [#36756] [#36760] [#36761] -- Update My Jetpack to use the Notice component from @automattic/jetpack-components and be more consistent with the other notices in Jetpack. [#36711] - -### Removed -- My Jetpack: Removed custom Notice component from My Jetpack. [#36772] -- My Jetpack: Remove red bubble from connection notice in favor of using the status of the Notice component. [#36773] - -### Fixed -- Fix cache on front end request for boost speed scores [#36700] -- fix tier upgrades in my Jetpack [#36705] - -## [4.20.2] - 2024-04-02 -### Fixed -- Fix Boost score inconsistency [#36679] - -## [4.20.1] - 2024-04-01 -### Added -- Change Phan baselines. [#36627] - -## [4.20.0] - 2024-03-29 -### Added -- Track active red bubble slugs on My Jetpack page view [#36611] - -### Fixed -- Better handling on product interstitial pages if the site already has a paid product [#36570] -- Shows Jetpack CRM card as active on My Jetpack if the plugin is installed and active [#36594] - -## [4.19.0] - 2024-03-27 -### Added -- Add red bubble to notices tied to red bubble notifications [#36543] -- My Jetpack: add a version of WordPress' Notice component to My Jetpack considering the context of how we use notices on that screen [#36551] - -### Changed -- Updated package dependencies. [#36539, #36585] - -### Fixed -- Fixed Jetpack Creator going to the wrong screen when the free version is selected" [#36547] -- Fixes some pricing showing twice by connecting sites that select a free option [#36533] - -## [4.18.0] - 2024-03-25 -### Added -- Hook into red bubble notification when bad installation is detected [#36449] -- Jetpack AI: add notices on product page for exhausted requests [#35910] -- Jetpack AI: add plans/tier information on product page and corresponding CTAs [#35910] -- Jetpack AI: add support and create post links on product page [#35910] -- My Jetpack: add AI product page view event [#36488] -- My Jetpack: add feedback link on Jetpack AI product page [#35910] -- My Jetpack: AI pricing table is skipped once the user has opted for the free version [#35910] -- My Jetpack: change AI product for tiered pricing table display [#35910] - -### Changed -- Add notice priorities to My Jetpack [#36438] -- Jetpack AI: address responsive issues on the styles [#35910] -- My Jetpack: AI product page styles update and responsive fixes [#35910] -- My Jetpack: change AI card action button target for upgraded users, point to product page [#35910] - -### Removed -- My Jetpack: remove Jetpack AI code added throughout the new product page project [#35910] -- Removed reference to Creator Network, which is being deprecated. [#36168] - -### Fixed -- Boost tooltips: fix typo in string. [#36520] -- My Jetpack: fix AI interstitial "remain free" flow [#35910] -- My Jetpack: fix interstitial event property malformed name productSlug -> product_slug [#36486] -- My Jetpack: fix spacing issues on the new product page [#35910] -- My Jetpack: new AI interstitial margin on admin page was messing with correct top spacing [#35910] - -## [4.17.1] - 2024-03-18 -### Added -- Add a loaded event for My Jetpack product cards [#36397] - -## [4.17.0] - 2024-03-14 -### Changed -- Rewrite My Jetpack hooks to Typescript [#36288] - -## [4.16.0] - 2024-03-12 -### Added -- Add a red bubble notification that shows if the site is disconnected [#36263] -- Add README to data directory [#36301] -- Add whitelist to show errors only for certain queries [#36261] - -### Changed -- Migrate Stats counts out of redux and into tanstack queries [#36195] -- Replace window state calls with util function [#36271] -- Rewrite My Jetpack utils to typescript [#36296] -- Show small stats card in table if large stats card isn't showing [#36136] -- Updated package dependencies. [#36325] -- Update query hooks for my-jetpack data" [#36257] -- Update useMyJetpackConnection hook to TypeScript [#36300] - -### Removed -- Removing redux store [#36256] - -## [4.15.0] - 2024-03-07 -### Added -- Refactor My Jetpack's backup related redux state to react query. [#35982] - -### Changed -- Migrate dismiss welcome banner to tanstack [#36199] -- Migrate global notices to context [#36201] -- Migrate My Jetpack's licenses query and state to react-query [#36029] -- Moved lifecycle stats function out of redux [#36205] -- Updating purchase related redux data to tanstack/react [#35994] - -### Removed -- Connected Product offer is not being used, removing it to clean up a bit [#36203] - -### Fixed -- fix a few My Jetpack bugs when main plugin is not installed [#36139] -- Intersitital tables were not visibly loading when pressed [#36236] - -## [4.14.0] - 2024-03-04 -### Changed -- Migrate My Jetpack zendesk state to react-query [#36028] -- Updated package dependencies. - -### Fixed -- Add registration nonce to connect screen in My Jetpack [#36133] - -## [4.13.0] - 2024-03-01 -### Added -- Add site lifecycle status guess to My Jetpack [#35815] - -### Changed -- Changed product plan checks on My Jetpack cards [#36046] -- Display different Boost card tooltip content based on score letter grade. [#35863] -- Improve consistency and fix bugs in product start and checkout flows [#35908] -- Instanciate the Boost Score API (new Speed_Score()) in My Jetpack. [#36080] -- My Jetpack: add Tracks events to connection section [#35804] -- Refactor react-query to reduce code repetition [#35990] - -### Fixed -- fixed the purchase query for the boost card [#36004] - -## [4.12.1] - 2024-02-27 -### Added -- My Jetpack: Add an info popover in the Boost product card. [#35731] - -## [4.12.0] - 2024-02-26 -### Changed -- My Jetpack: decouple Jetpack AI insterstitial component [#35836] -- Remove translation of product names [#35830] -- Updating purchases state to use data query instead of redux [#35697] - -### Removed -- Remove kebab menu on My Jetpack cards [#35829] - -## [4.11.0] - 2024-02-22 -### Added -- Adding accesible text for external links on connection page and footer [#35733] - -### Changed -- change status and action of My Jetpack cards when plugin is missing [#35718] -- ESlint: disabled redundant role rule [#35800] -- My Jetpack: add product slugs to click events on interstitials [#35740] -- My Jetpack: let tier data pass on quantity data to checkout process for proper checkout URL crafting [#35817] -- Updated package dependencies. [#35793] - -### Fixed -- Backup Card: made stats readable by screen readers [#35786] -- Connection Screen: make VoiceOver announce lists as such [#35736] -- Do not initialize My Jetpack when in Offline mode. [#35807] -- Fix wrong prop type passed to ConnectedProductCard [#35789] - -## [4.10.0] - 2024-02-19 -### Added -- Add Boost Speed Score into My Jetpack Boost product card [#35606] -- Add connection indicator for screen readers [#35714] - -### Fixed -- Improved accessibility of Dismiss button in Connection Banner [#35694] -- My Jeptack Connection: Make footer logos a list for better screen readers interpretation. [#35667] -- My Jetpack: add label for screen readers to connect page close button [#35712] - -## [4.9.2] - 2024-02-13 -### Changed -- My Jetpack: various improvements to the Stats card. [#35355] -- Updated package dependencies. [#35608] - -## [4.9.1] - 2024-02-12 -### Added -- Add My Jetpack link to standalone plugins missing it [#35523] - -## [4.9.0] - 2024-02-07 -### Changed -- Add pricing info for AI and CRM on My Jetpack [#35457] -- Update the description of some cards to better describe the product on My Jetpack page [#35428] - -### Fixed -- Fixes issue on My Jetpack interstitials where some prices are 1 cent off [#35492] - -## [4.8.0] - 2024-02-05 -### Added -- Add tracking info to the Jetpack Manage Banner CTA [#35378] -- My Jetpack: support redirect_to parameter on the product interstitial. [#35263] - -### Changed -- Update CTA copy on the connection banner to make it clear which type of connection we are going to request [#35401] -- Updated package dependencies. -- Update product cards on My Jetpack to always display the status indidicator. [#35377] - -### Fixed -- Fix issue where most products are not installing their standalone product upon purchase [#35399] - -## [4.7.0] - 2024-01-29 -### Changed -- Update the UpsellBanner to use the Card component from WP components. [#35223] - -### Removed -- UpsellBanner component moved to js-packages/components [#35228] - -## [4.6.2] - 2024-01-22 -### Added -- My Jetpack: add contact us event for Jetpack AI [#35136] - -## [4.6.1] - 2024-01-22 -### Changed -- Display Jetpack Protect product card for all users. [#35142] -- Ensure that interstitial tables go straight to checkout just like insterstitial cards [#35049] - -## [4.6.0] - 2024-01-18 -### Added -- Add hosting provider check. [#34864] -- Add Jetpack Manage banner. [#35078] - -## [4.5.0] - 2024-01-18 -### Changed -- Use blog ID instead of site slug in checkout URL. [#34976] - -## [4.4.0] - 2024-01-15 -### Changed -- add plan check to My Jetpack Akismet product card [#34905] -- Prevent new users from seeing JITMs [#34927] -- To avoid displaying the Welcome banner to every user, now we only display it to new users. [#34883] - -## [4.3.0] - 2024-01-08 -### Added -- Add a check to determine if a user is "new" to Jetpack. [#34821] -- Add a button that links to the connection screen to the Welcome Banner in My Jetpack. [#34858] - -### Changed -- Add a product interstitial in My Jetpack for stats. [#34772] -- Added an image to Social interstitial. [#34814] -- Update Akismet card on My Jetpack to go to interstitial screen when there is no API key. [#34817] - -## [4.2.1] - 2024-01-04 -### Changed -- Updated package dependencies. [#34815] [#34816] - -### Fixed -- My Jetpack: Jetpack footer links are now consistent with footers in rest of Jetpack screens. [#34787] - -## [4.2.0] - 2024-01-02 -### Fixed -- Show JP Creator as active when JP Complete is purchased. [#34806] - -## [4.1.4] - 2023-12-20 -### Changed -- Updated package dependencies. [#34694] - -## [4.1.3] - 2023-12-11 -### Changed -- Updated Jetpack AI interstitial to repeat the feature's list on all the tiers. [#34541] - -## [4.1.2] - 2023-12-06 -### Changed -- Updated package dependencies. [#34416] - -### Fixed -- Creator Card: fix typo. [#34478] - -## [4.1.1] - 2023-12-05 -### Fixed -- My Jetpack: Fix outdated product cache issue when enabling tiers. [#34428] - -## [4.1.0] - 2023-12-03 -### Added -- Added Jetpack Creator to My Jetpack. [#34307] -- Added the welcome banner to My Jetpack. [#34384] -- Display a "Jetpack Manage" menu item to connected users. [#34353] -- Updated connection message to only display if the welcome banner has been dismissed. [#34420] - -### Changed -- Updated package dependencies. [#34411] [#34427] -- Updated the API calls used for My Jetpack backup card. [#34197] -- Updated the CTAs in My Jetpack for more clarity and to avoid inconsistencies. [#34300] - -### Fixed -- Dashboard: Prevented display of any notices from third-party services. [#34364] -- Fixed checkout error while selling the unlimited Jetpack AI plan. [#34339] -- Fixed Jetpack AI bi-yearly plan on product card. [#34276] -- Fixed product card menus. [#34285] - -## [4.0.3] - 2023-11-24 -### Changed -- Changed Jetpack AI insterstitial contact link to Jetpack Redirect. [#34252] -- Link Jetpack AI Contact Us button to support email on interstitial page. [#34240] -- Removed hardcoded tiers from Jetpack AI interstitial. [#34259] -- Trust next tier provided by the Jetpack AI feature endpoint. [#34239] - -## [4.0.2] - 2023-11-21 -### Changed -- Replace usage of strpos() with str_contains(). [#34137] - -## [4.0.1] - 2023-11-21 -### Added -- Marked Jetpack AI as upgradable in the interstitial page. [#34215] - -## [4.0.0] - 2023-11-20 -### Added -- Display an "Activity Log" menu item to connected users. [#34174] -- Added direct checkout support for products with quantity-based plans. [#34177] -- Added Jetpack AI prices by tier to the interstitial page. [#34196] - -### Changed -- Replaced usage of strpos() with str_starts_with(). [#34135] -- Updated required PHP version to >= 7.0. [#34126] -- Removed condition from the backup undoable event call, this datapoint will be removed. [#33997] - -## [3.12.2] - 2023-11-14 -### Changed -- My Jetpack: Fix a bug causing PHP fatal errors when the Jetpack AI feature information is not available. [#34095] -- Updated package dependencies. [#34093] - -## [3.12.1] - 2023-11-13 -### Changed -- AI Assistant: Updated the text and image for the interstitial based on AI plan tiers. [#33981] -- AI Assistant: Removed the ToS notice from the interstitial page. [#34076] - -## [3.12.0] - 2023-11-08 -### Added -- Updated purchased state for VaultPress backup card on My Jetpack. [#33927] - -## [3.11.1] - 2023-11-03 - -## [3.11.0] - 2023-10-30 -### Added -- Add site data to unpurchased state of VaultPress Backup card to My Jetpack. [#33607] - -## [3.10.0] - 2023-10-23 -### Added -- Add jetpack-plans dependency. It will be use to restore the reverted change on #33410. [#33706] - -### Changed -- Update checkout flow to connect "After" checkout vs before (if not connected). [#33257] - -### Fixed -- Use Current_Plan to check/return from has_required_plan on VP product class. [#33708] - -## [3.9.1] - 2023-10-19 -### Changed -- Make has_required_plan return true (as it was before #33410) as a way to revert the change. [#33697] -- Updated package dependencies. [#33687] - -## [3.9.0] - 2023-10-17 -### Added -- Add has_required_plan method for VideoPress product class, check plan purchase exists for site [#33410] - -### Changed -- Updated package dependencies. [#33646] - -## [3.8.2] - 2023-10-16 -### Changed -- Updated package dependencies. [#33429, #33584] - -## [3.8.1] - 2023-10-10 -### Changed -- Changes title of the my-jetpack page to "My Jetpack" [#33486] -- Updated package dependencies. [#33428] - -### Fixed -- My Jetpack: fix fatal error [#33523] -- My Jetpack: fix Stats card status when not connected [#33521] - -## [3.8.0] - 2023-10-03 -### Added -- Display a new section on My Jetpack to display the stats of the site. [#33283] - -## [3.7.0] - 2023-09-28 -### Added -- Add a section to display stats from Jetpack Stats in My Jetpack [#33160] - -### Changed -- Redirect to a proper upgrade page for free license owners [#33297] - -## [3.6.0] - 2023-09-25 -### Added -- Add barebones infrastructure for querying jetpack product data. [#33095] - -### Changed -- Stats: link to purchase page within WP Admin. [#33227] - -## [3.5.0] - 2023-09-19 -### Changed -- Added support for upgradable products. Updated the Stats card to handle upgradeable products. [#33058] -- Updated Jetpack submenu sort order so individual features are alpha-sorted. [#32958] - -### Fixed -- My Jetpack: Add AI Assistant Monthly to required plan check [#33078] - -## [3.4.5] - 2023-09-13 -### Changed -- Updated package dependencies. [#33001] - -## [3.4.4] - 2023-09-11 -### Changed -- General: remove WP 6.1 backwards compatibility checks [#32772] - -### Fixed -- Stats: stop showing upgrade button for sites with Complete plan [#32870] - -## [3.4.3] - 2023-09-04 -### Changed -- Updated package dependencies. [#32803] [#32804] - -## [3.4.2] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [3.4.1] - 2023-08-22 -### Changed -- Connection: allow dismissing the IDC modal. [#32594] - -## [3.4.0] - 2023-08-21 -### Added -- Support Jetpack AI Yearly offering [#32130] - -### Changed -- Use the new method to render Connection initial state. [#32499] - -## [3.3.3] - 2023-08-14 -### Added -- Make My Jetpack the default WP-Admin page for Jetpack. [#32385] - -### Changed -- Start showing My Jetpack for authors, editors, and contributors [#32420] - -## [3.3.2] - 2023-08-09 -### Fixed -- Revert My Jetpack as first menu item. [#32384] - -## [3.3.1] - 2023-08-09 -### Changed -- Updated package dependencies. [#32166] - -## [3.3.0] - 2023-08-07 -### Added -- Add Identity Crisis screen modal. [#32249] - -### Changed -- Move 'My Jetpack' sub-menu item to first position. [#32240] - -### Fixed -- Fix IDC modal height issue. [#32316] - -## [3.2.1] - 2023-08-01 -### Added -- Add transient caching for zendesk jwt auth token. [#32140] - -### Changed -- My Jetpack: Rename the namespace of the JWT endpoint, and register it only when it isn't already registered [#32081] - -## [3.2.0] - 2023-07-25 -### Added -- My Jetpack: register jetpack-ai-jwt endpoint [#31965] -- My Jetpack: release Paid Stats to the public [#32020] - -### Changed -- My Jetpack: changed Stats features wording [#32046] -- Updated package dependencies. [#31999] [#32040] - -### Fixed -- Make Jetpack logo in footer smaller [#31627] -- My Jetpack: enabled Stats purchase flow returning to Stats Dashboard [#31959] - -## [3.1.3] - 2023-07-17 -### Changed -- Updated package dependencies. [#31872] - -### Fixed -- Hide connection owner information if the data is invalid -- Don't suggest user connection if user is already connected, but connection owner is invalid [#31618] - -## [3.1.2] - 2023-07-11 -### Changed -- Updated package dependencies. [#31785] - -## [3.1.1] - 2023-07-10 -### Fixed -- Make product card primary buttons links when applicable [#31611] - -## [3.1.0] - 2023-07-05 -### Added -- Added Jetpack Stats card to My Jetpack [#31589] - -### Changed -- Jetpack Stats: Enable skipping interstitial page [#31629] -- Updated package dependencies. [#31659] - -### Fixed -- My Jetpack: hide Stats card for standalone plugins [#31689] -- Organize product cards in list [#31606] - -## [3.0.0] - 2023-06-26 -### Added -- Add authentication to Zendesk chat. [#31339] -- Stats: add stats card to my Jetpack. [#31531] - -## [2.15.0] - 2023-06-23 -### Added -- My Jetpack: add Stats product [#31368] - -### Changed -- Updated package dependencies. [#31468] - -## [2.14.3] - 2023-06-12 -### Added -- My Jetpack: populate the Jetpack AI product with feature data [#31238] - -## [2.14.2] - 2023-06-06 -### Changed -- Filter out revoked licenses from the license activation options. [#31088] -- Updated package dependencies. [#31129] - -## [2.14.1] - 2023-05-29 -### Added -- My Jetpack: Add new Jetpack AI card [#30904] - -### Changed -- My Jetpack: Enable Jetpack AI card [#30988] -- My Jetpack: Update AI class to be product and not module [#30905] -- My Jetpack: Update AI interstitial background [#30992] - -## [2.14.0] - 2023-05-22 -### Added -- Added ability to purchase Jetpack AI monthly product [#30793] -- Added tier data to the Boost product to support a pricing table interstitial page. [#29931] - -## [2.13.0] - 2023-05-15 -### Added -- Added My Jetpack interstitial for Jetpack AI [#30543] - -## [2.12.2] - 2023-05-11 -### Changed -- PHP 8.1 compatibility updates [#30517] - -## [2.12.1] - 2023-05-08 -### Added -- My Jetpack: Add deactivate plugin menu action on product card [#30489] - -### Changed -- My Jetpack: Remove icon from plugin activation action in product card [#30458] -- My Jetpack: Remove manage option from menu [#30440] -- My Jetpack: Remove product card icon [#30441] -- My Jetpack: Set a post-checkout redirect destination on the "Purchase a plan" link. [#27693] - -### Fixed -- My Jetpack: Add check for product status before requesting stats [#30430] -- My Jetpack: Reload page after successful license activation [#30364] -- My Jetpack: Use a single column for the page title section [#30406] - -## [2.12.0] - 2023-05-02 -### Added -- Add API to query Zendesk chat availability and use it to conditionally display zendesk chat. [#29942] -- Add pricing table interstitial view for Jetpack Protect. [#29930] -- My Jetpack: Add product detail table component for comparing product tiers. [#29759] - -### Changed -- My Jetpack: Move logic out of Product Card component. [#30274] -- Updated package dependencies. - -### Fixed -- Fix activation and layout on Protect interstatial page. [#29525] -- My Jetpack: Keep product card action button disabled while installing standalone plugin. [#30346] - -## [2.11.0] - 2023-05-01 -### Added -- Added Jetpack Starter bundle post-activation screen and plan header [#30368] - -## [2.10.3] - 2023-04-25 -### Added -- My Jetpack: Add flags field in initial state [#30241] -- My Jetpack: Add Install/Activate menu actions based on the standalone plugin status. [#30153] -- My Jetpack: Add neutral color in contextual card [#30250] -- My Jetpack: Add side-effect action to request the standalone plugin installation on the backend. [#30143] -- My Jetpack: Add stats to VideoPress card [#30197] -- My Jetpack: Enable menu for all hybrid products [#30247] -- My Jetpack: Reload page after standalone action [#30221] - -### Changed -- My Jetpack: Connect the standalone plugin menu options so they trigger the installation and activation when clicked. [#30168] -- MyJetpack: set the Social standalone page as the default admin one [#30193] -- MyJetpack: Try to activate the product module after installing the standalone plugin [#30215] -- Updated package dependencies. [#30015] - -## [2.10.2] - 2023-04-17 -### Added -- Ad missing TOS in Jetpack interstitial. [#29683] -- My Jetpack: Add endpoint to install the standalone plugin for hybrid products. [#30045] -- My Jetpack: Expose information about standalone plugin status on My Jetpack product initial state. [#29977] - -### Changed -- Backup and Scan: redirect after checkout to Jetpack recommendations page if Jetpack plugin is active. Otherwise, redirect back to plugin admin page. [#29708] -- My Jetpack: Adjustments in Product Card [#30014] -- Updated package dependencies. [#30019] - -## [2.10.1] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] -- My Jetpack: Introduce absent_with_plan status [#29920] - -### Changed -- My Jetpack: Turn Search into a hybrid product to handle it as module and as standalone plugin. [#29946] -- My Jetpack: Turn Social into a hybrid product to handle it as module and as standalone plugin. [#29935] -- My Jetpack: Turn VaultPress Backup into a Hybrid product to handle it as module and as standalone plugin. [#29928] -- My Jetpack: Turn VideoPress into a Hybrid product to handle it as module and as standalone plugin. [#29918] - -## [2.10.0] - 2023-04-04 -### Added -- My Jetpack: Adds a selector, reducer and resolver machinery to fetch product stats. [#29764] -- My Jetpack: Enhance Product Card [#29787] -- My Jetpack: Introduce menu in Product Card [#29815] - -### Changed -- * Updated add-anti-spam path to add-akismet to match the product key - * Updated product interstitial component to accept an existingLicenseKeyUrl - * Updated product interstitial component to display a product name instead of a title where preferProductName is set - * Make is_plugin_active available from the API [#29598] -- My Jetpack: Change the bottom of My Jetpack screen to use single-column rows on small viewports. [#29844] -- Updated package dependencies. [#29854] - -## [2.9.2] - 2023-04-03 -### Changed -- Internal updates. - -## [2.9.1] - 2023-03-28 -### Changed -- Move GoldenTokenModal component to licensing package. [#29748] - -## [2.9.0] - 2023-03-27 -### Added -- Adds new route for Golden Token. Also the experience of redeeming one [#29644] -- Clarified when license activation fails that a user connection is required, added a link to complete the connection, and added functionality to redirect back to license activation when the connection is done. [#29443] - -## [2.8.1] - 2023-03-20 -### Changed -- Product Interstitial: Use browser history to go back, in case they're coming from somewhere outside of the app. [#29138] -- Updated My Jetpack wpwrap color to --jp-white-off [#29568] -- Updated package dependencies. [#29471] - -## [2.8.0] - 2023-03-13 -### Added -- Add Zendesk chat module to My Jetpack page [#28712] - -## [2.7.13] - 2023-03-08 -### Changed -- Updated package dependencies. [#29216] - -## [2.7.12] - 2023-02-28 -### Changed -- Update billing language [#29126] - -## [2.7.11] - 2023-02-20 -### Fixed -- My Jetpack: Fix button to add bundle in product interstitial component [#28984] - -## [2.7.10] - 2023-02-15 -### Changed -- Update to React 18. [#28710] - -## [2.7.9] - 2023-02-08 -### Changed -- Updated package dependencies. [#28682, #28700] - -## [2.7.8] - 2023-02-06 -### Changed -- Updated package dependencies. - -## [2.7.7] - 2023-01-26 -### Changed -- Use `flex-start` instead of `start` for better browser compatibility. [#28530] - -## [2.7.6] - 2023-01-25 -### Changed -- Minor internal updates. - -## [2.7.5] - 2023-01-23 -### Fixed -- Components: Fix usage of box-sizing across the elements [#28489] -- Fixes the price display for products with intro offers for the first month. [#28424] - -## [2.7.4] - 2023-01-16 -### Changed -- Updated package dependencies. [#28303] - -## [2.7.3] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [2.7.2] - 2023-01-02 -### Added -- My Jetpack: Move VideoPress from Hybrid [#28097] - -### Changed -- My Jetpack: Move Search out of hybrid and deprecate Hybrid_Product class [#28113] - -## [2.7.1] - 2022-12-27 -### Changed -- Fix layout visual issues [#28055] -- My Jetpack: Move Backup out of hybrid product [#28022] -- My Jetpack: Move Social out of hybrid product [#28074] - -## [2.7.0] - 2022-12-19 -### Added -- Implement detached licenses redux store. [#27609] - -### Changed -- Updated package dependencies. [#27916] - -### Fixed -- Add translation context to Security product name. [#27920] - -## [2.6.1] - 2022-12-12 -### Changed -- Updated package dependencies. [#27888] - -## [2.6.0] - 2022-12-05 -### Changed -- Improve design of the error notice. [#27340] -- Updated package dependencies. [#27340] - -## [2.5.2] - 2022-12-02 -### Changed -- My Jetpack: Requires connection only if needed [#27615] -- Updated package dependencies. [#27697] - -## [2.5.1] - 2022-11-30 - -## [2.5.0] - 2022-11-28 -### Changed -- My Jetpack: rename Backup and Anti-Spam to new product names [#27377] -- Show My Jetpack even if site is disconnected [#26967] -- Updated package dependencies. [#27576] - -## [2.4.1] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [2.4.0] - 2022-11-17 -### Added -- Added Jetpack Protect to My Jetpack. [#26069] - -### Changed -- Updated package dependencies. [#26736] - -## [2.3.5] - 2022-11-10 -### Changed -- Updated package dependencies. [#27319] - -## [2.3.4] - 2022-11-08 -### Changed -- Updated package dependencies. [#27289] - -## [2.3.3] - 2022-11-01 -### Changed -- Updated package dependencies. [#27196] - -## [2.3.2] - 2022-10-25 -### Changed -- Updated package dependencies. [#26705] - -## [2.3.1] - 2022-10-25 -### Added -- Add a flag to indicate if the pricing is introductory with product price [#26982] -- My Jetpack: Support trial [#27033] - -### Changed -- Search: now support 38 languages [#27025] - -### Fixed -- Don't show old price when it's the same as new one [#27015] -- Search: check if free plan and new pricing is active using wpcom API [#27016] - -## [2.3.0] - 2022-10-19 -### Added -- Added support for free product and added free product for Search [#26808] - -### Changed -- Updated package dependencies. [#26883] - -## [2.2.3] - 2022-10-17 -### Changed -- Updated package dependencies. [#26851] - -## [2.2.2] - 2022-10-13 -### Changed -- Updated package dependencies. [#26790] - -## [2.2.1] - 2022-10-11 -### Changed -- Updated package dependencies. [#25973] - -## [2.2.0] - 2022-10-05 -### Added -- Integrate the new connection error message React component into My Jetpack. [#26485] -- Search: add post type breakdown endpoint [#26463] -- Trigger restore connection flow. [#26489] - -### Changed -- Updated package dependencies. [#26457] - -## [2.1.1] - 2022-09-27 -### Changed -- Updated package dependencies. - -## [2.1.0] - 2022-09-20 -### Added -- Added the ConnectionErrorNotice React component. [#26259] - -### Changed -- Updated package dependencies. - -### Fixed -- Fixed the tests for the Module_Product class by creating and using a sample, test-only module product class as the test subject instead of relying on Videopress or other concrete products. [#26227] - -## [2.0.5] - 2022-09-08 -### Changed -- Change VideoPress into a Hybrid product in My Jetpack [#25954] -- Updated package dependencies. - -## [2.0.4] - 2022-08-31 -### Added -- Allow plugins to override a product class. [#25891] - -### Changed -- Updated package dependencies. [#25856] - -## [2.0.3] - 2022-08-29 -### Changed -- Updated package dependencies. - -## [2.0.2] - 2022-08-25 -### Changed -- Activate plugins in normal mode to trigger plugin_activated hooks [#25727] -- Updated package dependencies. [#25814] - -### Fixed -- Licensing: do not enable the Licensing UI if My Jetpack cannot be enabled. [#25667] -- Search: increased search plan/pricing API timeouts to 5s [#25775] - -## [2.0.1] - 2022-08-23 -### Added -- My Jetpack: Add container for JITMs [#22452] - -### Changed -- Updated package dependencies. [#25338, #25339, #25377, #25422, #25628, #25762, #25764] - -## [2.0.0] - 2022-08-09 -### Added -- Make product cards compatible with disclaimers and add disclaimer for backup card [#25265] - -### Changed -- Search: changed to only require site level connection [#24477] - -## [1.8.3] - 2022-08-03 -### Changed -- Updated package dependencies. [#25300, #25315] - -## [1.8.2] - 2022-07-27 -### Changed -- My Jetpack: changed link used in ProductCard component to a button when the plugin is absent - -## [1.8.1] - 2022-07-26 -### Changed -- My Jetpack: changed button used in ProductCard component from WordPress to Jetpack default [#25146] -- Updated package dependencies. [#25147] - -## [1.8.0] - 2022-07-19 -### Added -- My Jetpack: scroll window to top on route change [#25086] - -### Changed -- Updated package dependencies. [#24710] - -## [1.7.4] - 2022-07-12 -### Changed -- Updated package dependencies. [#25048, #25055] - -## [1.7.3] - 2022-07-06 -### Added -- Display alert when we cant automatically install the plugin [#24884] - -### Changed -- Updated package dependencies. [#24923] - -## [1.7.2] - 2022-06-28 -### Changed -- Disambiguate redirectUrls vars [#24839] -- Search: use centralized search pricing API [#24795] -- Updated package dependencies. [#24826] - -### Fixed -- Search Pricing: fix pricing fetch issue before site is connected [#24826] - -## [1.7.1] - 2022-06-21 -### Fixed -- My Jetpack: Replace wordpress from PNG to SVG at Connection [#24793] - -## [1.7.0] - 2022-06-21 -### Changed -- My Jetpack: set products grid to 3x3 for large viewport size -- Renaming master to trunk. -- Renaming `master` references to `trunk` - -## [1.6.2] - 2022-06-14 -### Changed -- Updated package dependencies. [#24529] - -## [1.6.1] - 2022-06-08 -### Changed -- Reorder JS imports for `import/order` eslint rule. [#24601] -- Updated package dependencies. [#24510] - -## [1.6.0] - 2022-05-30 -### Added -- Added Social to My Jetpack. - -### Changed -- Make My Jetpack use the new Modules class -- Replace deprecated external-link variation by using isExternalLink prop -- Updated package dependencies - -## [1.5.0] - 2022-05-24 -### Changed -- Default licensing UI in My Jetpack to be enabled [#24396] -- Updated package dependencies. [#24449] - -## [1.4.1] - 2022-05-19 -### Changed -- Updated package dependencies. [#24395] - -## [1.4.0] - 2022-05-18 -### Added -- Added a filter to allow stand-alone plugins to add product specific activation routines [#24334] -- My Jetpack: Add Protect class [#24347] -- My Jetpack: compute Search plugin price based on price tier [#24337] - -### Changed -- Add tiered pricing copy and update titles for Jetpack Search [#24357] -- Hide Activate a license link if there is no user connection since user connection is required [#24251] -- My Jetpack Hybrid products: Install Jetpack if stand-alone plugin installation fails [#24335] -- Updated Jetpack Scan feature list. [#23863] [#23795] [#24361] [#24372] - -## [1.3.0] - 2022-05-10 -### Changed -- Adds from arg to connection screen in My Jetpack so that we can begin tracking connections originating from My Jetpack [#24283] -- Updated package dependencies. [#24189] -- Updated references to old licensing activation UI to licensing activation UI in My Jetpack [#24189] - -## [1.2.1] - 2022-05-04 -### Added -- Add missing JavaScript dependencies. [#24096] - -### Changed -- My Jetpack: remove duplicated site suffix stored on rawUrl. Use siteSuffix instead. [#24094] -- Updated package dependencies. [#24095] [#24198] - -### Deprecated -- Moved the options class into Connection. [#24095] - -## [1.2.0] - 2022-04-26 -### Added -- Added activation screen component to My Jetpack licensing page - -### Changed -- Updated package dependencies. -- Update package.json metadata. - -## [1.1.0] - 2022-04-19 -### Added -- Adds a skeleton for the licensing UI along with a feature flag -- Better error handling for when the WPCOM server is unreachable -- Introduced ConnectedProductOffer component - -### Changed -- Turn Search into a Hybrid Product -- Updated package dependencies -- use connected plugin list from the connection store and ask for an update after activating a product - -## [1.0.2] - 2022-04-12 -### Changed -- Updated package dependencies. - -### Fixed -- Fixed bug in checkout URLs for sites installed in subdirs. - -## [1.0.1] - 2022-04-06 -### Removed -- Removed tracking dependency. - -## [1.0.0] - 2022-04-05 -### Added -- My Jetpack: improve Product and Interstitial components. - -### Changed -- Bump My Jetpack package to major version 1.0.0. -- My Jetpack: align price boxes in the interstitial product page. -- Updated package dependencies. - -## [0.6.13] - 2022-03-31 -### Added -- Added tracking events to Plans section external links - -### Changed -- My Jetpack: tweak plans section typography and descriptive text - -## [0.6.12] - 2022-03-29 -### Added -- Add missing JS peer dependencies. - -### Changed -- Microperformance: Use === null instead of is_null -- My Jetpack: Moved in product icon components -- My Jetpack: Tweak plan sections styles/sizes -- My Jetpack: Update ProductDetailCard to use components and theme variables -- My Jetpack: Use components to render headers elements -- Use different URLs for manage and purchase links in plans section - -### Fixed -- My Jetpack: Connect Screen logos quality - -## [0.6.11] - 2022-03-23 -### Added -- My Jetpack: add error styles to the whole Product card component -- My Jetpack: Make whole Product card clickable - -### Changed -- Changed opacity of product icons to 40% -- Changed title -- Improved should_initialize method -- My Jetpack: remove dropdown from CTA button in Product cards -- My Jetpack: Use Text and CSS vars on ProductCard -- Updated Boost product icon for clarity -- Updated package dependencies. -- Updated package dependencies. -- Updated styles for each product card status -- Update organization and copy of the Plans section - -### Removed -- My Jetpack: Remove client code that allows to deactivate a product - -### Fixed -- Fix Plans section top margin for plan list -- My Jetpack: jetpack_my_jetpack_should_initialize filter now respected when set to true. - -## [0.6.10] - 2022-03-15 -### Changed -- Make Backup go through the purchase flow after activation -- My Jetpack: Use ThemeProvider instead base-styles -- Updated package dependencies - -### Removed -- Removed Beta badge from menu item - -## [0.6.9] - 2022-03-09 -### Changed -- Updated package dependencies. - -## [0.6.8] - 2022-03-08 -### Added -- Added connected plugins slugs to My Jetpack tracking events -- Add link to jetpack.com in the footer -- My Jetpack: Add jetpack features link on connection screen -- My Jetpack: tidy Product card component -- My Jetpack: update Spinner in checkout button - -### Changed -- Components: update attributes used within the Button component to match recent deprecations and changes. -- My Jetpack: Add Connected Product Card stories -- My Jetpack: Add connection screen footer -- My Jetpack: clean/tidy Product data -- My Jetpack: Remove Layout component -- Only consider Backup product active when the plan is purchased - -### Fixed -- Fixed Backup flow when Jetpack plugin is active -- My Jetpack: align CTA buttons of My Jetpack overview -- My Jetpack: Fix button height in the Interstitial pages - -## [0.6.7] - 2022-03-02 -### Added -- Add My Jetpack action link to all Jetpack plugins -- My Jetpack: Handle cosmetic tweaks -- My Jetpack: Pass requiresUserConnection to ConnectionStatusCard - -### Changed -- Refactor and simplify Products class -- Updated package dependencies. - -### Fixed -- Disable browser cache for My Jetpack -- My Jetpack: fix products card section story -- My Jetpack: fix stories for the Interstitial pages - -## [0.6.6] - 2022-02-28 -### Fixed -- Re-doing 0.6.5 to fixup bad release. - -## [0.6.5] - 2022-02-28 -### Changed -- Tweak product card box model. - -### Fixed -- Use namespace in My Jetpack REST Products class to prevent fatal - -## [0.6.4] - 2022-02-25 -### Added -- Activate Jetpack plugin from Extras product card -- Added list of connected plugins to Disconnect dialog in My Jetpack -- Add Extras interstitial page -- My Jetpack: Handle cosmetic tweaks -- My Jetpack: Remove global notices when in my jetpack page -- My Jetpack: set height of Jetpack logo in the footer -- My Jetpack: tweak height of Jetpack Logo -- My Jetpack: update Product logos - -### Changed -- Disable My Jetpack on MS -- My Jetpack: compress extras product image -- Updated package dependencies. -- Update My Jetpack dashboard headline - -### Removed -- Remove unnecessary line from My Jetpack Initial state - -### Fixed -- Fix beta badge for RTL languages -- Handle plugin activating from Hybrid class -- Memoized RecordEvent from usAnalytics hook -- My Jetpack: Fix post activation url redirect -- My Jetpack: Move product list that requires user connection to selector -- Products::get_products_names should not load all product information -- Update automattic logo href in the footer - -## [0.6.3] - 2022-02-22 -### Changed -- Updated inline documentation - -### Fixed -- Use Jetpack namespace to fix fatal error - -## [0.6.2] - 2022-02-22 -### Added -- Add Beta badge -- Add Extras class -- Apply coupon discount to Product price when it exists -- Filesystem write access to the initial state -- Improve Product detail layout -- Implement close link on layout nav -- Prevent calling activation hook when activating backup - -### Changed -- Bump package versions. -- Improve My Jetpack link styles -- Improve redirect process after installing Product -- Fix interstitial CTA buttons layout -- Move from isPressed to CSS vars -- Redirect connect user to connection interstitial -- Point the link of the Manage button of CRM to its dashboard -- Redirect to post_activation_url after product activation from iterstitial screen -- Remove conditional loading depending on constant -- Send My Jetpack version with fired events -- Update the layout of interstitial page when it has an upgradable bundle - -### Fixed -- Check if product is active before checking if requires plan -- Fix check for plugin installation for hybrid products -- Fix click on security and add click on My Jetpack interstitial -- Fix clicks on VideoPress and CRM cards -- Fix Product prices -- Make Scan and Search interstitials install the plugin -- Purchases: ensure we retrieve translated version of active purchases -- Return needs purchase status for products module - -## [0.6.1] - 2022-02-16 -### Added -- Add Anti-Spam Product detail card -- Add CRM interstitial page -- Added wpcom plan slug to product info -- add manage and post activation urls -- Add Scan product: interstitial, route, data, etc... -- Add Security Product Bundle -- Add VideoPress data -- Add VideoPress interstitial cmp. Story. -- Add `#/add-videopress` route -- Change the discount value for all Products to 50 -- checks and activation for Security Bundle -- consume prices dynamically -- Do not show Porduct price when plan has required plan -- Finish Backup, Anti-Spam and Scan interstitial pages -- Fire Tracks Event when user clicks on Product Interstitial Back link -- Install proudcts from interstitial pages -- Make click on Fix connection show connection route -- package version to main class -- Pull product discount from wpcom -- Refactoring -> add icons component -> tweak icons for interstitial pages -- Register `#/add-anti-spam` route. Connect with interstitial page -- Restore Security bundle card in the UI -- Set default values for product data in the client (custom hook) -- set product status as error if active and requiring a missing user connection -- Set properly the checkout link for Products -- Set unlink=1 in the checkout URL when the user is not connected -- Tidy Product stories -- Update Backup product data. Tweak Icon. -- Update mock data for Search product. useMyJetpackNavigate() hook - -### Changed -- Adapt Scan actiavtion behavior as it is not a module -- Add global notices for activate/deactivate failures -- Add manage redirect -- Apply correct style for CTA buttons on Interstitial -- Avoid usage of 100vh on layout -- Fix setting height of the Product title in the detail component -- Implement is fulfilled handler for product resolver -- Improve global notice layout -- Reduce size of boost and search interstitial images -- Update structure with Layout component -- Only pass a productUrl if the product is not free on interstitial pages -- Only show the deactivate action when it makes sense -- Pass slug prop to event firing on product card button actions instead of name -- Remove unnecessary payload from request to activate or deactivate a product -- Replace renderActionButton function for ActionButton component -- Updated package dependencies. -- Use useMyJetpackNavigate when it's worth it - -### Fixed -- Fixed connection check labels and error message -- Fix upgradability for anti-spam and backup products -- Remove duplicted Icon in Product Card story -- Use key when looping through product detail icons - -## [0.6.0] - 2022-02-09 -### Added -- Add Boost interstitial cmp. -- Add has_required_plan to product info and implement method in Search -- Add Product princign harcoded data -- Add search product data -- Add title and features to products data -- anti spam product class -- Connect Boost card with the interstitial page via /add-boost root -- Fire Tracks event when clicking CTA button on product Interstitial page -- Fire Tracks event when clicking Manage button on product card -- Fire Tracks event when clickn Add link on My Jetpack product card -- Fire Tracks event when showing the Interstitial page -- Implement Free price for Boost product -- Implement Search product interstitial -- Introduce basic Layout component. Add GoBackLink component -- Introduce ProductDetailCard component -- My Jetpack: Add Connection screen -- Pass slug prop to ProductCard' -- Plan verification for Backup and Scan -- Restore getProduct() resolver -- Set the checkout URL for the Product detail component -- useCallback for functions that are bound to onEvents - -### Changed -- My Jetpack: Implement handler of connection notices -- My Jetpack: Update notice style and implements redirect for connection route -- Support multiple possible folder for each plugin -- Updated package dependencies - -### Removed -- dependency from search package - -### Fixed -- Fix My Jetpack's reducer for SET_PRODUCT_STATUS -- Fix the redirect URL value -- Show discounted price in Product Detail card -- typo - -## [0.5.0] - 2022-02-02 -### Added -- Added plugin installation functionality -- Adds Tracks events for activating and deactivating products from the product cards -- Fixes stories for ProductCard component -- Handle when site is not connected -- Initial approach to handle global notice -- Module Products -- My Jetpack: Add route handling -- My Jetpack: connect all product cards with data provider -- My Jetpack: connect Backup product class with Product class. Add long description and features fields. -- My Jetpack: handle redirect when no connection #22549 -- My Jetpack: reorganize stores by project/name -- Remove getProduct() resolver -- Support to Hybrid products -- Tweak dimms of the Product card status -- Update data handling - Implement request status in Product Card -- User connection requirement to product info -- uses the Plugin Installer package to safely checks plugins statuses - -### Changed -- Added filter for disabling the initialization of the My Jetpack package -- Build: remove unneeded files from production build. -- Do not initialize My Jetpack id site is not connected -- My Jetpack: Refactor styles to use layout components and theme provider -- My Jetpack: Update gap between product cards section -- Pick API root and nonce values from a new window var myJetpackRest -- Updated package dependencies. -- Update plugin absent status consistently - -### Fixed -- added unit test mock for new global variable myJetpackRest -- Fix tests -- Fix unsafe optional chaining. -- my-jetpack: fix tracking event when activating product -- Resolved minor code standard violation after implementing a stricter rule. - -## [0.4.0] - 2022-01-25 -### Added -- add API endpoints to manipulate products -- Added css module for My Jetpack Plans Section -- Added useAnalytics hook -- Added Visitor class for status regarding the site visitor. -- Add first data approach -- Add Products and REST_Products basic classes -- Adds very basic product cards section component to my jetpack -- My Jetpack: Add Product Card component -- My Jetpack: check user connectivity before to hit wpcom side -- My Jetpack: Implement data handling for enable/disable products -- Removed endpoint plans superseded by purchases - -### Changed -- Add Connections Section wrapping the Connection Status Card to My Jetpack -- Build: do not ship raw files in production bundle. - -### Removed -- Remove unused usePlans() custom react hook - -### Fixed -- Fixed svg attribute strokeWidth for Boost Card - -## [0.3.3] - 2022-01-18 -### Added -- Added redux store specific to my-jetpack -- Implement plans list properly in the PlansSection -- My Jetpack: Add scripts for JS tests -- My Jetpack: Include wordpress components as dep -- Reduxify purchases data - -### Changed -- General: update required node version to v16.13.2 -- Properly style the Plans Section according to proposed design -- Updated package dependencies. - -## [0.3.2] - 2022-01-13 -### Added -- My Jetpack: add story to `` component -- My Jetpack: first PlanSection implementation - -### Fixed -- Rename method enqueue_scritps to enqueue_scripts - -## [0.3.1] - 2022-01-11 -### Added -- Add devvelopment testing instructions to doc. - -### Changed -- Updated package dependencies. - -### Removed -- Remove use of deprecated `~` in sass-loader imports. - -## [0.3.0] - 2022-01-04 -### Changed -- Drop isRegistered and isUserConnected params from ConnectionStatusCard component -- Switch to pcov for code coverage. -- Updated package dependencies. -- Updated package textdomain from `jetpack` to `jetpack-my-jetpack`. - -## [0.2.0] - 2021-12-14 -### Added -- Added Connection Status Card to the page. -- Janitorial: add watch command to the plugin. - -### Changed -- Adapt to new layout components. -- Build: do not ship scss and jsx files in production build. - -### Fixed -- Build minimized JS for the production build. -- Fix JavaScript i18n strings. - -## [0.1.3] - 2021-12-07 -### Changed -- Updated package dependencies. - -## [0.1.2] - 2021-11-30 -### Added -- Janitorial: create mirror repo for the package. - -### Changed -- Remove now-redundant `output.filename` from Webpack config. - -## 0.1.1 - 2021-11-23 -### Changed -- Updated package dependencies. - -## 0.1.0 - 2021-11-17 -### Added -- Created package - -[5.9.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.9.0...5.9.1 -[5.9.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.8.0...5.9.0 -[5.8.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.7.3...5.8.0 -[5.7.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.7.2...5.7.3 -[5.7.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.7.1...5.7.2 -[5.7.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.7.0...5.7.1 -[5.7.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.6.0...5.7.0 -[5.6.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.5.3...5.6.0 -[5.5.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.5.2...5.5.3 -[5.5.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.5.1...5.5.2 -[5.5.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.5.0...5.5.1 -[5.5.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.4.5...5.5.0 -[5.4.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.4.4...5.4.5 -[5.4.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.4.3...5.4.4 -[5.4.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.4.2...5.4.3 -[5.4.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.4.1...5.4.2 -[5.4.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.4.0...5.4.1 -[5.4.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.3.3...5.4.0 -[5.3.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.3.2...5.3.3 -[5.3.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.3.1...5.3.2 -[5.3.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.3.0...5.3.1 -[5.3.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.2.0...5.3.0 -[5.2.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.1.2...5.2.0 -[5.1.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.1.1...5.1.2 -[5.1.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.1.0...5.1.1 -[5.1.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.0.4...5.1.0 -[5.0.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.0.3...5.0.4 -[5.0.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.0.2...5.0.3 -[5.0.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.0.1...5.0.2 -[5.0.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/5.0.0...5.0.1 -[5.0.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.37.0...5.0.0 -[4.37.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.36.0...4.37.0 -[4.36.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.16...4.36.0 -[4.35.16]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.15...4.35.16 -[4.35.15]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.14...4.35.15 -[4.35.14]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.13...4.35.14 -[4.35.13]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.12...4.35.13 -[4.35.12]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.11...4.35.12 -[4.35.11]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.10...4.35.11 -[4.35.10]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.9...4.35.10 -[4.35.9]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.8...4.35.9 -[4.35.8]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.7...4.35.8 -[4.35.7]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.6...4.35.7 -[4.35.6]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.5...4.35.6 -[4.35.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.4...4.35.5 -[4.35.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.3...4.35.4 -[4.35.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.2...4.35.3 -[4.35.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.1...4.35.2 -[4.35.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.35.0...4.35.1 -[4.35.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.34.0...4.35.0 -[4.34.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.33.1...4.34.0 -[4.33.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.33.0...4.33.1 -[4.33.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.32.4...4.33.0 -[4.32.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.32.3...4.32.4 -[4.32.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.32.2...4.32.3 -[4.32.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.32.1...4.32.2 -[4.32.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.32.0...4.32.1 -[4.32.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.31.0...4.32.0 -[4.31.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.30.0...4.31.0 -[4.30.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.29.0...4.30.0 -[4.29.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.28.0...4.29.0 -[4.28.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.27.2...4.28.0 -[4.27.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.27.1...4.27.2 -[4.27.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.27.0...4.27.1 -[4.27.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.26.0...4.27.0 -[4.26.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.25.4...4.26.0 -[4.25.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.25.3...4.25.4 -[4.25.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.25.2...4.25.3 -[4.25.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.25.1...4.25.2 -[4.25.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.25.0...4.25.1 -[4.25.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.7...4.25.0 -[4.24.7]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.6...4.24.7 -[4.24.6]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.5...4.24.6 -[4.24.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.4...4.24.5 -[4.24.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.3...4.24.4 -[4.24.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.2...4.24.3 -[4.24.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.1...4.24.2 -[4.24.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.24.0...4.24.1 -[4.24.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.23.3...4.24.0 -[4.23.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.23.2...4.23.3 -[4.23.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.23.1...4.23.2 -[4.23.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.23.0...4.23.1 -[4.23.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.22.3...4.23.0 -[4.22.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.22.2...4.22.3 -[4.22.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.22.1...4.22.2 -[4.22.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.22.0...4.22.1 -[4.22.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.21.0...4.22.0 -[4.21.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.20.2...4.21.0 -[4.20.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.20.1...4.20.2 -[4.20.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.20.0...4.20.1 -[4.20.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.19.0...4.20.0 -[4.19.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.18.0...4.19.0 -[4.18.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.17.1...4.18.0 -[4.17.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.17.0...4.17.1 -[4.17.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.16.0...4.17.0 -[4.16.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.15.0...4.16.0 -[4.15.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.14.0...4.15.0 -[4.14.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.13.0...4.14.0 -[4.13.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.12.1...4.13.0 -[4.12.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.12.0...4.12.1 -[4.12.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.11.0...4.12.0 -[4.11.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.10.0...4.11.0 -[4.10.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.9.2...4.10.0 -[4.9.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.9.1...4.9.2 -[4.9.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.9.0...4.9.1 -[4.9.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.8.0...4.9.0 -[4.8.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.7.0...4.8.0 -[4.7.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.6.2...4.7.0 -[4.6.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.6.1...4.6.2 -[4.6.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.6.0...4.6.1 -[4.6.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.5.0...4.6.0 -[4.5.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.4.0...4.5.0 -[4.4.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.3.0...4.4.0 -[4.3.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.2.1...4.3.0 -[4.2.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.2.0...4.2.1 -[4.2.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.1.4...4.2.0 -[4.1.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.1.3...4.1.4 -[4.1.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.1.2...4.1.3 -[4.1.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.1.1...4.1.2 -[4.1.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.1.0...4.1.1 -[4.1.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.0.3...4.1.0 -[4.0.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.0.2...4.0.3 -[4.0.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.0.1...4.0.2 -[4.0.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/4.0.0...4.0.1 -[4.0.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.12.2...4.0.0 -[3.12.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.12.1...3.12.2 -[3.12.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.12.0...3.12.1 -[3.12.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.11.1...3.12.0 -[3.11.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.11.0...3.11.1 -[3.11.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.10.0...3.11.0 -[3.10.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.9.1...3.10.0 -[3.9.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.9.0...3.9.1 -[3.9.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.8.2...3.9.0 -[3.8.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.8.1...3.8.2 -[3.8.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.8.0...3.8.1 -[3.8.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.7.0...3.8.0 -[3.7.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.6.0...3.7.0 -[3.6.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.5.0...3.6.0 -[3.5.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.4.5...3.5.0 -[3.4.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.4.4...3.4.5 -[3.4.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.4.3...3.4.4 -[3.4.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.4.2...3.4.3 -[3.4.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.4.1...3.4.2 -[3.4.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.4.0...3.4.1 -[3.4.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.3.3...3.4.0 -[3.3.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.3.2...3.3.3 -[3.3.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.3.1...3.3.2 -[3.3.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.3.0...3.3.1 -[3.3.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.2.1...3.3.0 -[3.2.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.2.0...3.2.1 -[3.2.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.1.3...3.2.0 -[3.1.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.1.2...3.1.3 -[3.1.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.1.1...3.1.2 -[3.1.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.1.0...3.1.1 -[3.1.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/3.0.0...3.1.0 -[3.0.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.15.0...3.0.0 -[2.15.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.14.3...2.15.0 -[2.14.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.14.2...2.14.3 -[2.14.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.14.1...2.14.2 -[2.14.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.14.0...2.14.1 -[2.14.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.13.0...2.14.0 -[2.13.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.12.2...2.13.0 -[2.12.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.12.1...2.12.2 -[2.12.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.12.0...2.12.1 -[2.12.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.11.0...2.12.0 -[2.11.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.10.3...2.11.0 -[2.10.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.10.2...2.10.3 -[2.10.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.10.1...2.10.2 -[2.10.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.10.0...2.10.1 -[2.10.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.9.2...2.10.0 -[2.9.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.9.1...2.9.2 -[2.9.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.9.0...2.9.1 -[2.9.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.8.1...2.9.0 -[2.8.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.8.0...2.8.1 -[2.8.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.13...2.8.0 -[2.7.13]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.12...2.7.13 -[2.7.12]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.11...2.7.12 -[2.7.11]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.10...2.7.11 -[2.7.10]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.9...2.7.10 -[2.7.9]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.8...2.7.9 -[2.7.8]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.7...2.7.8 -[2.7.7]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.6...2.7.7 -[2.7.6]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.5...2.7.6 -[2.7.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.4...2.7.5 -[2.7.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.3...2.7.4 -[2.7.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.2...2.7.3 -[2.7.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.1...2.7.2 -[2.7.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.7.0...2.7.1 -[2.7.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.6.1...2.7.0 -[2.6.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.6.0...2.6.1 -[2.6.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.5.2...2.6.0 -[2.5.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.5.1...2.5.2 -[2.5.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.5.0...2.5.1 -[2.5.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.4.1...2.5.0 -[2.4.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.4.0...2.4.1 -[2.4.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.3.5...2.4.0 -[2.3.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.3.4...2.3.5 -[2.3.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.3.3...2.3.4 -[2.3.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.3.2...2.3.3 -[2.3.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.3.1...2.3.2 -[2.3.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.3.0...2.3.1 -[2.3.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.2.3...2.3.0 -[2.2.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.2.2...2.2.3 -[2.2.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.2.1...2.2.2 -[2.2.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.2.0...2.2.1 -[2.2.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.1.1...2.2.0 -[2.1.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.1.0...2.1.1 -[2.1.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.0.5...2.1.0 -[2.0.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.0.4...2.0.5 -[2.0.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.0.3...2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.0.2...2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.0.1...2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/2.0.0...2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.8.3...2.0.0 -[1.8.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.8.2...1.8.3 -[1.8.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.8.1...1.8.2 -[1.8.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.8.0...1.8.1 -[1.8.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.7.4...1.8.0 -[1.7.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.7.3...1.7.4 -[1.7.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.7.2...1.7.3 -[1.7.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.7.1...1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.7.0...1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.6.2...1.7.0 -[1.6.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.6.1...1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.6.0...1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.5.0...1.6.0 -[1.5.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.4.1...1.5.0 -[1.4.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.4.0...1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.3.0...1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.2.1...1.3.0 -[1.2.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.2.0...1.2.1 -[1.2.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.1.0...1.2.0 -[1.1.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.0.2...1.1.0 -[1.0.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.0.1...1.0.2 -[1.0.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/1.0.0...1.0.1 -[1.0.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.13...1.0.0 -[0.6.13]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.12...0.6.13 -[0.6.12]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.11...0.6.12 -[0.6.11]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.10...0.6.11 -[0.6.10]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.9...0.6.10 -[0.6.9]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.8...0.6.9 -[0.6.8]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.7...0.6.8 -[0.6.7]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.6...0.6.7 -[0.6.6]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.5...0.6.6 -[0.6.5]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.4...0.6.5 -[0.6.4]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.3...0.6.4 -[0.6.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.2...0.6.3 -[0.6.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.1...0.6.2 -[0.6.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.6.0...0.6.1 -[0.6.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.5.0...0.6.0 -[0.5.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.4.0...0.5.0 -[0.4.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.3.3...0.4.0 -[0.3.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.3.2...0.3.3 -[0.3.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.3.1...0.3.2 -[0.3.1]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.3.0...0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.2.0...0.3.0 -[0.2.0]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.1.3...0.2.0 -[0.1.3]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.1.2...0.1.3 -[0.1.2]: https://github.com/Automattic/jetpack-my-jetpack/compare/0.1.1...0.1.2 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/apple-36e00ab02e6fed6f51dd.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/apple-36e00ab02e6fed6f51dd.svg deleted file mode 100644 index 7b1aacc6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/apple-36e00ab02e6fed6f51dd.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/apple-92dacafad84e79708a74.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/apple-92dacafad84e79708a74.svg deleted file mode 100644 index 478fcfd9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/apple-92dacafad84e79708a74.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/boost-9e9a227e7e7280d0aa85.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/boost-9e9a227e7e7280d0aa85.png deleted file mode 100644 index 4e7cb0ce..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/boost-9e9a227e7e7280d0aa85.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/cloud-81ac85ba680343200f54.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/cloud-81ac85ba680343200f54.svg deleted file mode 100644 index a033545d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/cloud-81ac85ba680343200f54.svg +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/complete-f4bd1db5fb786efbc9d5.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/complete-f4bd1db5fb786efbc9d5.png deleted file mode 100644 index 2bd5b625..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/complete-f4bd1db5fb786efbc9d5.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/connect-c399837fe1621b176d10.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/connect-c399837fe1621b176d10.png deleted file mode 100644 index 47797572..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/connect-c399837fe1621b176d10.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/crm-8a2b204e2c720730e928.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/crm-8a2b204e2c720730e928.png deleted file mode 100644 index 3984395b..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/crm-8a2b204e2c720730e928.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/empty-avatar-fea23feddfa99b07c2e8.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/empty-avatar-fea23feddfa99b07c2e8.svg deleted file mode 100644 index d648cc87..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/empty-avatar-fea23feddfa99b07c2e8.svg +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/evaluation-blank-fbbfbcd75b50ade0f092.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/evaluation-blank-fbbfbcd75b50ade0f092.png deleted file mode 100644 index 99ef2671..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/evaluation-blank-fbbfbcd75b50ade0f092.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/evaluation-selected-196d1790b76830f9b73a.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/evaluation-selected-196d1790b76830f9b73a.png deleted file mode 100644 index 1ff0ab37..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/evaluation-selected-196d1790b76830f9b73a.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/extras-c6bd0796750901faa7fd.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/extras-c6bd0796750901faa7fd.png deleted file mode 100644 index 93435375..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/extras-c6bd0796750901faa7fd.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/github-45c648158e3e86b560f5.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/github-45c648158e3e86b560f5.svg deleted file mode 100644 index e7ae694e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/github-45c648158e3e86b560f5.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/github-523373a4447a46c189a1.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/github-523373a4447a46c189a1.svg deleted file mode 100644 index 8a7617a8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/github-523373a4447a46c189a1.svg +++ /dev/null @@ -1,15 +0,0 @@ - - - - - - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/google-a444c8c0f0c0108836d8.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/google-a444c8c0f0c0108836d8.svg deleted file mode 100644 index 4fff614a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/google-a444c8c0f0c0108836d8.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/google-dec2a429bf1d8e83f9ad.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/google-dec2a429bf1d8e83f9ad.svg deleted file mode 100644 index 5794583d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/google-dec2a429bf1d8e83f9ad.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/grow-your-audience-ddf8016fd72419f4e80e.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/grow-your-audience-ddf8016fd72419f4e80e.png deleted file mode 100644 index 7d385bff..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/grow-your-audience-ddf8016fd72419f4e80e.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-5e94ec9a207b87fe38d7.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-5e94ec9a207b87fe38d7.svg deleted file mode 100644 index 1289f870..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-5e94ec9a207b87fe38d7.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-9de1caef5eb5c22da5d6.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-9de1caef5eb5c22da5d6.svg deleted file mode 100644 index f8dbeb91..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-9de1caef5eb5c22da5d6.svg +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-ai-d29bf65dcea46074d72f.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-ai-d29bf65dcea46074d72f.png deleted file mode 100644 index b77ec6b9..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-ai-d29bf65dcea46074d72f.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-gray-7eeb5eb060c8adea8622.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-gray-7eeb5eb060c8adea8622.svg deleted file mode 100644 index 5a2a8b5f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-gray-7eeb5eb060c8adea8622.svg +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-lock-cef570e11997f185e23d.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-lock-cef570e11997f185e23d.png deleted file mode 100644 index bc305002..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-lock-cef570e11997f185e23d.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-success-c5c132e713a79e05985f.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-success-c5c132e713a79e05985f.png deleted file mode 100644 index 3a84fe15..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-license-activation-with-success-c5c132e713a79e05985f.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-manage-3a7ecaa604823c98c3cf.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-manage-3a7ecaa604823c98c3cf.svg deleted file mode 100644 index 1cbd2e82..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/jetpack-manage-3a7ecaa604823c98c3cf.svg +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/search-d177a31292d96d5ccbc2.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/search-d177a31292d96d5ccbc2.png deleted file mode 100644 index a5d1e8d7..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/search-d177a31292d96d5ccbc2.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/security-53b7f3ddc8dcbe17b0c1.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/security-53b7f3ddc8dcbe17b0c1.png deleted file mode 100644 index f26e97c8..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/security-53b7f3ddc8dcbe17b0c1.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-inactive-cba3b43d918377b506e5.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-inactive-cba3b43d918377b506e5.svg deleted file mode 100644 index 5afa85d0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-inactive-cba3b43d918377b506e5.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-off-47426e7b562ef20ae513.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-off-47426e7b562ef20ae513.svg deleted file mode 100644 index e1f7f232..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-off-47426e7b562ef20ae513.svg +++ /dev/null @@ -1,5 +0,0 @@ - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-partial-48b279219c6389a129b9.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-partial-48b279219c6389a129b9.svg deleted file mode 100644 index 03b09674..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-partial-48b279219c6389a129b9.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-success-e64a26c3a6d0888fba06.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-success-e64a26c3a6d0888fba06.svg deleted file mode 100644 index 0f3ebeca..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/shield-success-e64a26c3a6d0888fba06.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/site-cards-29522f090d5422fd7afd.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/site-cards-29522f090d5422fd7afd.png deleted file mode 100644 index 83e562ed..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/site-cards-29522f090d5422fd7afd.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/stats-95b42796ede4f632b642.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/stats-95b42796ede4f632b642.png deleted file mode 100644 index bd003303..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/stats-95b42796ede4f632b642.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/videopress-9c064bc7b89c386e5e50.png b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/videopress-9c064bc7b89c386e5e50.png deleted file mode 100644 index f38227dc..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/videopress-9c064bc7b89c386e5e50.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/wordpress-1fc3e0ba6c52e9707900.svg b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/wordpress-1fc3e0ba6c52e9707900.svg deleted file mode 100644 index b1cd75b6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/images/wordpress-1fc3e0ba6c52e9707900.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.asset.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.asset.php deleted file mode 100644 index f2d8d8c9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.asset.php +++ /dev/null @@ -1 +0,0 @@ - array('jetpack-connection', 'jetpack-script-data', 'lodash', 'react', 'react-dom', 'react-jsx-runtime', 'wp-api-fetch', 'wp-components', 'wp-compose', 'wp-data', 'wp-date', 'wp-dom-ready', 'wp-element', 'wp-hooks', 'wp-i18n', 'wp-notices', 'wp-plugins', 'wp-polyfill', 'wp-primitives', 'wp-private-apis', 'wp-url', 'wp-warning'), 'version' => 'd453c42f6395d98c7008'); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.css deleted file mode 100644 index 30f7d9e4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.css +++ /dev/null @@ -1 +0,0 @@ -.activation-screen-error__message{align-items:flex-start;display:flex;flex-direction:row;margin-top:calc(var(--spacing-base)*.5);max-width:500px}.activation-screen-error__message svg{margin-left:-3px}.activation-screen-error__message span{font-size:13px;font-weight:500;letter-spacing:-.044em;line-height:20px}.activation-screen-error__message--error{color:var(--jp-red)}.activation-screen-error__message--error svg{fill:var(--jp-red)}.activation-screen-error__message--success{color:var(--jp-green)}.activation-screen-error__message--success svg{fill:var(--jp-green)}.activation-screen-error__info{background-color:var(--jp-gray-0);border:1px solid var(--jp-green-0);border-radius:var(--jp-border-radius);color:var(--jp-gray-80);font-size:var(--font-body-small);line-height:calc(var(--font-title-small) - 2px);margin:32px 0 8px;padding:var(--jp-modal-padding-small)}.activation-screen-error__info>p{font-size:var(--font-body-small);margin:0 0 1em}.activation-screen-error__info>p:last-child{margin-bottom:0}.activation-screen-error__info ol>li::marker{font-weight:700}.activation-screen-error__info a{color:var(--jp-green-50)}.activation-screen-error__info a:active,.activation-screen-error__info a:hover{color:var(--jp-green-70)}.jp-license-activation-screen-controls .activation-screen-error__info>p{font-size:var(--font-body-small);margin:0 0 1em}.jp-license-activation-screen-controls .activation-screen-error__info>p:last-child{margin-bottom:0}.jp-license-activation-screen-controls{background:var(--jp-white);display:flex;flex-direction:column;justify-content:space-between;padding:32px}.jp-license-activation-screen-controls h1{font-size:44px;font-weight:700;line-height:1.4;margin:.67em 0}.jp-license-activation-screen-controls p{font-size:var(--font-body);margin:1em 0}.jp-license-activation-screen-controls label{font-size:var(--font-body);font-weight:600}@media screen and (min-width:780px){.jp-license-activation-screen-controls{padding:64px}}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success{margin-top:10px;max-width:500px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field .components-input-control__label.components-input-control__label.components-input-control__label,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error .components-input-control__label.components-input-control__label.components-input-control__label,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success .components-input-control__label.components-input-control__label.components-input-control__label{font-size:var(--font-body);font-weight:600}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field select.components-select-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error select.components-select-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success select.components-select-control__input{border-radius:var(--jp-border-radius);font-size:18px;line-height:24px;margin:0;min-height:48px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field input.components-text-control__input{border:1px solid var(--jp-gray-40)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error select.components-select-control__input{border:1px solid var(--jp-red)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success select.components-select-control__input{border:1px solid var(--jp-green)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active{background-color:var(--jp-black);border-radius:4px;color:var(--jp-white);display:flex;font-size:16px;font-size:var(--font-body);font-style:normal;font-weight:600;justify-content:center;line-height:24px;margin-top:24px;min-height:48px;min-width:158px;padding:13.5px 45px;width:100%}@media screen and (min-width:480px){.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active{width:auto}}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active:hover,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:hover{background-color:var(--jp-black-80);color:var(--jp-white)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active:focus,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:focus{background-color:var(--jp-black-80);border:1px solid var(--jp-white);color:var(--jp-white)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active:disabled,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active[disabled],.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:disabled,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button[disabled]{background-color:var(--jp-gray);color:var(--jp-gray-20)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button .jp-components-spinner,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active .jp-components-spinner{width:100%}@keyframes rotate-spinner{to{transform:rotate(1turn)}}.jp-components-spinner{align-items:center;display:flex}.jp-components-spinner__inner,.jp-components-spinner__outer{animation:3s linear infinite;animation-name:rotate-spinner;border:.1em solid transparent;border-radius:50%;box-sizing:border-box;margin:auto}.jp-components-spinner__outer{border-top-color:#fff}.jp-components-spinner__inner{border-right-color:#fff;border-top-color:#fff;height:100%;opacity:.4;width:100%}.jp-license-activation-screen-illustration{align-items:center;background:var(--jp-white-off);display:flex;flex-direction:column;justify-content:space-between;padding:32px}.jp-license-activation-screen-illustration--wrapper{display:flex;flex:1}.jp-license-activation-screen-illustration--wrapper img{align-self:center;height:auto;max-width:100%}.jp-license-activation-screen-illustration--support-link{flex:0}.components-button.jp-license-activation-screen-success-info--button,.components-button.jp-license-activation-screen-success-info--button:active,.components-button.jp-license-activation-screen-success-info--button:visited{background-color:var(--jp-black);border-radius:4px;color:var(--jp-white);font-size:16px;font-size:var(--font-body);font-style:normal;font-weight:600;justify-content:center;line-height:24px;margin:0 40px 20px 0;min-height:48px;min-width:158px;padding:13.5px 45px;width:100%}@media screen and (min-width:480px){.components-button.jp-license-activation-screen-success-info--button,.components-button.jp-license-activation-screen-success-info--button:active,.components-button.jp-license-activation-screen-success-info--button:visited{width:auto}}.components-button.jp-license-activation-screen-success-info--button:active:hover,.components-button.jp-license-activation-screen-success-info--button:hover,.components-button.jp-license-activation-screen-success-info--button:visited:hover{background-color:var(--jp-black-80);color:var(--jp-white)}.components-button.jp-license-activation-screen-success-info--button:active:focus,.components-button.jp-license-activation-screen-success-info--button:focus,.components-button.jp-license-activation-screen-success-info--button:visited:focus{background-color:var(--jp-black-80);border:1px solid var(--jp-white);color:var(--jp-white)}.components-button.jp-license-activation-screen-success-info--button:active:disabled,.components-button.jp-license-activation-screen-success-info--button:active[disabled],.components-button.jp-license-activation-screen-success-info--button:disabled,.components-button.jp-license-activation-screen-success-info--button:visited:disabled,.components-button.jp-license-activation-screen-success-info--button:visited[disabled],.components-button.jp-license-activation-screen-success-info--button[disabled]{background-color:var(--jp-gray);color:var(--jp-gray-20)}.components-button.jp-license-activation-screen-success-info--button .jp-components-spinner,.components-button.jp-license-activation-screen-success-info--button:active .jp-components-spinner,.components-button.jp-license-activation-screen-success-info--button:visited .jp-components-spinner{width:100%}.jp-license-activation-screen-success-info--product-details h1{line-height:52px}.jp-license-activation-screen-success-info--product-details a{color:var(--jp-black);text-decoration:underline!important}.jp-license-activation-screen-success-info--external-link{color:var(--jp-black);font-size:16px;font-style:normal;font-weight:600;text-decoration:underline!important;white-space:nowrap}.jp-license-activation-screen-success-info{background:var(--jp-white);display:flex;flex-direction:column;justify-content:space-between;padding:32px}.jp-license-activation-screen-success-info h1{font-size:44px;font-weight:700;line-height:1.4;margin:.67em 0}.jp-license-activation-screen-success-info p{font-size:var(--font-body);margin:1em 0}.jp-license-activation-screen-success-info label{font-size:var(--font-body);font-weight:600}@media screen and (min-width:780px){.jp-license-activation-screen-success-info{padding:64px}}@media screen and (max-width:480px){.jp-license-activation-screen-success-info .jp-license-activation-screen-success-info--buttons{text-align:center}}.EiaNctK1_P9pPqOeiaSI{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ogHZg_sJCljylz3VJfsf{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.ogHZg_sJCljylz3VJfsf{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.ogHZg_sJCljylz3VJfsf{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.zv7eGvijKRkbPVakubHw{grid-column-end:span 1}.VoJNoiya_1ck3_kXS6_C{grid-column-end:span 2}.ecv0NO526NoTNbpALA1A{grid-column-end:span 3}.OfBdkceMzeHvRbzhqDlP{grid-column-end:span 4}@media(min-width:600px){.JLb3NpEKN8pOaWd7K1bu{grid-column-end:span 1}.fsMPGqPKE4mjMIPFwl77{grid-column-end:span 2}.DIK_zdaGAQ09eKspBJ4E{grid-column-end:span 3}.shXYpxPu3WCJsR8aOHtz{grid-column-end:span 4}.s7ElrOqG_yGd5SIfwqOR{grid-column-end:span 5}.Cxml9uzGvArAL8_RDs_p{grid-column-end:span 6}.aANxBKDGx72eDqU0iUPj{grid-column-end:span 7}.XxyzuTY3mnQcl9EGZadm{grid-column-end:span 8}}@media(min-width:960px){.Sfo4WaSNIWInJ93Abd3w{grid-column-end:span 1}.tQS7SKUGrU4THhWMysbo{grid-column-end:span 2}.I94U7mpY4h16pcOksZNF{grid-column-end:span 3}.uWMb9k77kQxBdS5MTt0s{grid-column-end:span 4}.rKwEEZQxK9s_POMg5Jss{grid-column-end:span 5}.UcPXX_s06IPCkF7ZjH3D{grid-column-end:span 6}.CrQdtiCFkRbzY6K2dFvt{grid-column-end:span 7}.rEUALOmOdUBXO0Us871z{grid-column-end:span 8}.NqXa9TlcTEviVsB53hBV{grid-column-end:span 9}.OnWVeiQiwgQ9lzdGPW66{grid-column-end:span 10}.D2PkTcy7b8u2K9QXY6VQ{grid-column-end:span 11}.EcqBhzAyxo5RDc2Y6m7K{grid-column-end:span 12}}@media(max-width:960px){.gB1mWzHOM38d80lrhBRX{display:none}}@media(max-width:600px){.KNQXLP78ejczOkour3zg{display:none}}.rBVbaVWBnBRtTMrUKZxm{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);display:block;margin:32px 0;padding:16px 64px 16px 24px;position:relative;text-decoration:none}.rBVbaVWBnBRtTMrUKZxm span{display:block}.rBVbaVWBnBRtTMrUKZxm span:last-of-type{font-weight:600}.rBVbaVWBnBRtTMrUKZxm:focus span:last-of-type,.rBVbaVWBnBRtTMrUKZxm:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.rBVbaVWBnBRtTMrUKZxm:focus:after,.rBVbaVWBnBRtTMrUKZxm:hover:after{transform:translateY(-50%) translateX(8px)}.rBVbaVWBnBRtTMrUKZxm:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;position:absolute;right:24px;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.gfM_DIJrVbRhmKdAphIm{background:var(--jp-white);border-radius:var(--jp-modal-radius);box-shadow:0 12px 16px -.5px rgba(0,0,0,.15);height:max-content;margin:3rem auto;max-width:414px;overflow:hidden;position:relative;transition:height .25s cubic-bezier(.59,.37,.18,1.19) 0;width:90%;will-change:height}.gfM_DIJrVbRhmKdAphIm>div:first-child{padding:0}.gfM_DIJrVbRhmKdAphIm *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.gfM_DIJrVbRhmKdAphIm p{color:var(--jp-black)}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN{display:none}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh{height:614px;transition-delay:2.15s}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh h2{margin-top:0}._j4GWTmW5psCHFYh6R0x{align-self:flex-start;margin-top:var(--jp-gap)!important;padding:8px var(--jp-modal-padding-small)!important;width:100%}.saSAjv8yulVXQDoqDJEI{font-weight:500;line-height:110%;margin-bottom:8px}.O_hcdbeMivIhBn7ApDnS{line-height:140%}@media(min-width:760px){.gfM_DIJrVbRhmKdAphIm{height:740px;max-width:1360px;position:relative;width:95%}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN{display:block;left:64px;position:absolute;top:64px;z-index:99}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN clipPath,.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN path{fill:#000}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN path.FCnyb_xCK7DhJ63p6TEd{fill:#fff}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh{height:740px;transition-delay:0}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN clipPath,.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN path{transition:fill 2s ease .5s;fill:#fff}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN path.FCnyb_xCK7DhJ63p6TEd{transition:fill 2s ease .5s;fill:#000}}@keyframes OmAVpCQ270MqI4IsT9Ky{20%{transform:translateY(0) scale(1)}65%{transform:translateY(16%) scale(1.4)}to{transform:translateY(0) scale(1)}}.Qn5xayjI_jH2m1d6BEoq{border-radius:var(--jp-button-radius);display:flex;height:50%;justify-content:center;min-height:400px;overflow:hidden;position:relative;transition:height .55s cubic-bezier(.59,.37,.18,1) 0s;will-change:height}.pnwbCuWbV0PNQr1LFpRh .Qn5xayjI_jH2m1d6BEoq{height:100%;transition-delay:.65s}.pnwbCuWbV0PNQr1LFpRh .Qn5xayjI_jH2m1d6BEoq video{animation:OmAVpCQ270MqI4IsT9Ky 1.5s ease-in-out forwards}.Qn5xayjI_jH2m1d6BEoq video{height:100%;left:0;object-fit:cover;position:absolute;top:0;transform:scale(1);transition:all .85s cubic-bezier(1,0,.39,1) 0s;width:100%;will-change:transform}@media(min-width:760px){@keyframes Axe8f2LgqEBZHVcsRgY5{0%{animation-timing-function:cubic-bezier(.86,0,.07,1);left:60%;top:32px}50%{animation-timing-function:cubic-bezier(.17,.84,.44,1);bottom:32px;left:32px;top:32px;width:100%}to{left:32px;width:40%}}.Qn5xayjI_jH2m1d6BEoq{border-radius:12px;bottom:32px;display:block;height:auto;left:60%;overflow:hidden;position:absolute;right:32px;top:32px;transition-delay:0;transition:width .55s ease 0s;z-index:3}.Qn5xayjI_jH2m1d6BEoq video{height:100%;left:0;object-fit:cover;position:absolute;top:0;width:100%}.pnwbCuWbV0PNQr1LFpRh .Qn5xayjI_jH2m1d6BEoq{animation-delay:.25s;animation-duration:2s;animation-fill-mode:forwards;animation-name:Axe8f2LgqEBZHVcsRgY5;height:auto}}.iBMDoShSmqpt72YfJb36{padding:var(--jp-modal-padding)}.iBMDoShSmqpt72YfJb36 h2{font-size:clamp(1.5rem,-.7353rem + 4.7059vw,3.5rem)}.iBMDoShSmqpt72YfJb36 p{font-size:clamp(1rem,.6974rem + 1.1696vw,1.75rem)}.iBMDoShSmqpt72YfJb36 p.eQG1KKK8jjKtQyzfv573{display:none;font-size:clamp(1.25rem,1.1491rem + .3899vw,1.5rem)}@media(min-width:760px){.iBMDoShSmqpt72YfJb36{bottom:15%;display:flex;flex-direction:column;gap:64px;left:64px;padding:0 var(--jp-modal-padding) 0 0;position:absolute;width:55%}.iBMDoShSmqpt72YfJb36 .l35bIyiqYJiZ6tVYvJtC{align-items:flex-start;display:flex;flex-direction:column;gap:16px;padding:0 32px 0 0}.iBMDoShSmqpt72YfJb36 .l35bIyiqYJiZ6tVYvJtC h2,.iBMDoShSmqpt72YfJb36 .l35bIyiqYJiZ6tVYvJtC p{margin:0}.iBMDoShSmqpt72YfJb36 p.eQG1KKK8jjKtQyzfv573{display:block}.iBMDoShSmqpt72YfJb36 ._j4GWTmW5psCHFYh6R0x{align-self:flex-start;padding:16px var(--jp-modal-padding-large)!important;width:auto}.pnwbCuWbV0PNQr1LFpRh .iBMDoShSmqpt72YfJb36{left:-20px;opacity:0;transition:all .55s cubic-bezier(.59,.37,.18,1) .3s}}.HQVDZ6J3x6SJNYFX5khS{background:var(--jp-white);left:0;opacity:0;position:absolute;top:100%;transition:transform .45s cubic-bezier(.59,.37,.18,1) 2s,opacity .45s linear;width:100%;will-change:transform,opacity;z-index:2}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS{opacity:1;transform:translateY(-100%);transition-delay:2s}@media(min-width:760px){.HQVDZ6J3x6SJNYFX5khS{align-items:flex-end;bottom:5%;container-type:inline-size;display:flex;flex-direction:column;gap:40px;left:45%;padding:0;right:32px;transform:translateY(0);transition-delay:0;transition:none;width:auto}.HQVDZ6J3x6SJNYFX5khS h2{width:100%}.HQVDZ6J3x6SJNYFX5khS ._j4GWTmW5psCHFYh6R0x{margin-right:var(--jp-modal-padding-large)}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS{bottom:12%;left:45%;opacity:1;right:32px;top:unset;transform:translateY(0);transition:all .45s cubic-bezier(.59,.37,.18,1) 2s,opacity .45s linear;transition-delay:2s;width:auto}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS .l35bIyiqYJiZ6tVYvJtC{padding-left:32px}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS ._j4GWTmW5psCHFYh6R0x{align-self:flex-end}}.KdvmPIjelQIFiPQGuIYf{background:var(--jp-gray-0);display:flex;flex-direction:column;gap:var(--jp-gap)}.KdvmPIjelQIFiPQGuIYf div{background-color:var(--jp-white);border:1px solid var(--jp-gray-10);border-radius:var(--jp-button-radius);box-shadow:0 0 40px 0 rgba(0,0,0,.08);flex:1;padding:var(--jp-modal-padding)}.KdvmPIjelQIFiPQGuIYf h3{font-size:24px;line-height:normal;margin:0}.KdvmPIjelQIFiPQGuIYf p{font-size:14px}@media(min-width:760px){.KdvmPIjelQIFiPQGuIYf{flex-direction:row;padding:var(--jp-modal-padding-large)}.KdvmPIjelQIFiPQGuIYf div{border:none;box-shadow:0 2px 16px rgba(0,0,0,.08),0 2px 2px rgba(0,0,0,.1)}.KdvmPIjelQIFiPQGuIYf div p{margin:8px 0}.KdvmPIjelQIFiPQGuIYf svg{margin-bottom:var(--jp-modal-padding-small)}}@container (max-width: 600px){.KdvmPIjelQIFiPQGuIYf div{padding:var(--jp-modal-padding-small)}}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aLWBKY0yRghEk7tNCgK3{fill:var(--color-bluesky)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.af4Y_zItXvLAOEoSDPSv{fill:var(--color-twitter)}.cbOwD8Y4tFjwimmtchQI.f68aqF3XSD1OBvXR1get{fill:var(--color-linkedin)}.cbOwD8Y4tFjwimmtchQI.xFI0dt3UiXRlRQdqPWkx{fill:var(--color-tumblr)}.cbOwD8Y4tFjwimmtchQI.q7JEoyymveP6kF747M43{fill:var(--color-gplus)}.cbOwD8Y4tFjwimmtchQI.DKOBOTVmTLbh26gUH_73{fill:var(--color-mastodon)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw{fill:var(--color-nextdoor)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.cL3m0xBYTYhIKI7lCqDB{fill:var(--color-instagram)}.cbOwD8Y4tFjwimmtchQI.fftumuc_lJ6v0tq4UMVR{fill:var(--color-whatsapp)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI{fill:var(--color-threads)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI.social-logo{border-radius:40%}.SqdhUZkXCRuIpErj1B3z{--max-container-width:1128px;--vertical-gutter:24px;--horizontal-spacing:8px;column-gap:var(--vertical-gutter);display:grid;margin:0 auto;max-width:var(--max-container-width);width:100%}@media(max-width:599px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(4,minmax(0,1fr));padding:0 16px}}@media(min-width:600px)and (max-width:959px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(8,minmax(0,1fr));padding:0 18px}}@media(min-width:960px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(12,minmax(0,1fr));padding:0 24px}}.SqdhUZkXCRuIpErj1B3z.OZC_9a1LhpWF9dv15Gdh{max-width:none;padding:unset}@media(max-width:599px){.RuVLl3q4lxTQa3wbhBJB{grid-column-end:span 1}.f9LZTRG4MMK42rS89afW{grid-column-start:1}.bHe_zKxjjpUwHw_MdYE1{grid-column-end:2}.QZbNrOqE2aNSn50xVhpU{grid-column-end:span 2}.ev7W3z7zVYPeHAlYqZjf{grid-column-start:2}.NJWd1m_e7lOiPYru2ZMP{grid-column-end:3}.Xc6nt1Qc1DI0Z2A3gt1r{grid-column-end:span 3}.UIcN_GXiPRoIsin8Kohg{grid-column-start:3}.GRKCyqb5LufCSCgykKFc{grid-column-end:4}.i_qTq8gqhhC3vIUepVRB{grid-column-end:span 4}.G3qaZ3Jpbvam_1XvGxgc{grid-column-start:4}.VRCNYKZtO9zukEwmgP1y{grid-column-end:5}}@media(min-width:600px)and (max-width:959px){.tRm008K_WJL79WoNZTNL{grid-column-end:span 1}.l5T2P_bgKts4tdaRkS1d{grid-column-start:1}.zOCxfLZpF6BlgC7a_Yq1{grid-column-end:2}.F80DdgVn0m5OpvtSQWka{grid-column-end:span 2}.oI1c7JYfiJtMQHbhngtU{grid-column-start:2}.pMQtA_4jh1_1lVknqEP5{grid-column-end:3}.VenqMpdgyKQVUNNQcfqd{grid-column-end:span 3}.seNYL99uoczf9V4MxBxT{grid-column-start:3}.YKfF1HFhI9KygA5l3b2J{grid-column-end:4}.yAi0Cv1xDWkoqsaUhvhR{grid-column-end:span 4}.ubhnyZOnkgxNhh6XtVWv{grid-column-start:4}.RGOPGQbWMJ9Ei5oFxS7X{grid-column-end:5}.Sz1E2aWbX483ijdi6yge{grid-column-end:span 5}.tku6_bRYrX9tMbgYGmIl{grid-column-start:5}.b5JHttOhSEcI1WBlqAjk{grid-column-end:6}.FboSx5MoKTAWbxXyYlCw{grid-column-end:span 6}.Jhs8yEEmodG30edbJvag{grid-column-start:6}.IpzbbKVqEqPcfIGkXkwt{grid-column-end:7}.mhCPwfAZ4Kmm_empzJAq{grid-column-end:span 7}.x034ilrJF7rO9UJB2rI1{grid-column-start:7}.Wt8t2e16viRrOJ1lLA5v{grid-column-end:8}.S6pIrEy9AMLKx9bgh_Ae{grid-column-end:span 8}.kEfI4tGyuWfHTlRnvIab{grid-column-start:8}.PUzX4RRsKq1dnsz3gebS{grid-column-end:9}}@media(min-width:960px){.X_pdcLJikd8LS_YAdJlB{grid-column-end:span 1}.tl936d14Huby4khYp05X{grid-column-start:1}.hnge0LnR69d3NXEtEE1t{grid-column-end:2}.fj0NUMuyZQcPNgKcjp5Z{grid-column-end:span 2}.R2ncBX7a2NigdYCcV1OX{grid-column-start:2}.t8vMSDVYno9k9itRwnXb{grid-column-end:3}.wsDuEN2GqHx6qzo8dUdk{grid-column-end:span 3}.cIEVPUweWtLBy3xaXnMx{grid-column-start:3}.fajUWBwu1m2B479j3jmz{grid-column-end:4}.YR0c7fQTgMkDdWzwSyLp{grid-column-end:span 4}.xlwp8BmplxkKNMI7gamo{grid-column-start:4}._C4O1w9DUqx1m3gPf8aA{grid-column-end:5}.Z54F1hAErckAIrKlxnXW{grid-column-end:span 5}.ezSDWkRHmKSxDJXxuiOH{grid-column-start:5}.T0ChoeAjGJjkkNrYhD4g{grid-column-end:6}.qtMoMPF6yHvGJnWHSsde{grid-column-end:span 6}.gdoywN5VPiWERfIBqkph{grid-column-start:6}.wUev_VH5uf_pwFFlbnAU{grid-column-end:7}.egIPDFJsOpownTClq9XP{grid-column-end:span 7}.yGhp9yoAW7k0kQik9AB7{grid-column-start:7}.SJ43U9mR5wUg5V2qBeQA{grid-column-end:8}.cTuyHfMwSUJxN_HdIEgd{grid-column-end:span 8}.smCr8DaIagcumdvdldiK{grid-column-start:8}.T03NHzQJvzwL6wAfIiTL{grid-column-end:9}.pMvxM3RJGjqyNdf9qg1Y{grid-column-end:span 9}.iIVpNRwEnQ_JI5gpp9EN{grid-column-start:9}.ZbQ4u4vGSX5rJOje4uGL{grid-column-end:10}.gKb5wuIDAlKGbrjK2vxy{grid-column-end:span 10}.Z7pINdImE2WJiYnZBTqm{grid-column-start:10}.ZTxp6qpvwurMdOnLLSz1{grid-column-end:11}.NnQTlbfnxPDR6cQ7rygg{grid-column-end:span 11}.O137wZd6Yl0olSA9PsXR{grid-column-start:11}.zf2OJtQ2MPz6SDoh6CB0{grid-column-end:12}.U3H6UHW6HqRt9hdzVg3O{grid-column-end:span 12}.zynnNeS_ZBTxABcVpUQH{grid-column-start:12}.vI8tltFZtFUNAy9Iag9s{grid-column-end:13}}.zI5tJ_qhWE6Oe6Lk75GY{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);--wp-admin-border-width-focus:1.51px;border-radius:var(--jp-border-radius);font-weight:600;justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo{height:calc(var(--spacing-base)*5);padding:var(--spacing-base);width:calc(var(--spacing-base)*5)}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo>svg:first-child{margin:0;padding:0}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo.Na39I683LAaSA99REg14{height:calc(var(--spacing-base)*4);min-width:calc(var(--spacing-base)*4);padding:calc(var(--spacing-base)/2);width:calc(var(--spacing-base)*4)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body);height:auto;line-height:24px;padding:var(--spacing-base) calc(var(--spacing-base)*3)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK{padding:var(--spacing-base) calc(var(--spacing-base)*2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body-extra-small);height:auto;line-height:20px;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK>svg:first-child{margin-right:calc(var(--spacing-base)/2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo)>.components-spinner{height:20px}.zI5tJ_qhWE6Oe6Lk75GY.lZAo6_oGfclXOO9CC6Rd{font-weight:400}.zI5tJ_qhWE6Oe6Lk75GY.xJDOiJxTt0R_wSl8Ipz_{min-width:100%}.zI5tJ_qhWE6Oe6Lk75GY.is-primary:disabled,.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:disabled{background:var(--jp-gray);color:var(--jp-gray-20)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary{background:var(--jp-white);box-shadow:inset 0 0 0 1.51px var(--jp-black)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:active:not(:disabled),.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:hover:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-link.Na39I683LAaSA99REg14,.zI5tJ_qhWE6Oe6Lk75GY.is-link.ipS7tKy9GntCS4R3vekF{padding:0}.zI5tJ_qhWE6Oe6Lk75GY.is-link:hover:not(:disabled){text-decoration-thickness:3px}.zI5tJ_qhWE6Oe6Lk75GY.is-link:focus:not(:disabled){text-decoration-line:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:not(:disabled){background:var(--jp-red-50);box-shadow:inset 0 0 0 1px var(--jp-red-50);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:hover:not(:disabled){background:var(--jp-red-60);box-shadow:inset 0 0 0 1px var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:focus:not(:disabled){background:var(--jp-red-70);box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:active:not(:disabled){background:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:not(:disabled){background:var(--jp-white);box-shadow:inset 0 0 0 1.5px var(--jp-red-50);color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:hover:not(:disabled){background:var(--jp-red-0);box-shadow:inset 0 0 0 1.5px var(--jp-red-60);color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:active:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:not(:disabled){color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:hover:not(:disabled){box-shadow:none;color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6{position:relative}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6.has-icon{justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>:not(.components-spinner){visibility:hidden}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>.components-spinner{margin:0;position:absolute}.CDuBjJp_8jxzx5j6Nept{margin-left:calc(var(--spacing-base)/2)}.jp-license-activation-screen{border-radius:4px;box-shadow:0 4px 24px 0 rgba(0,0,0,.149);display:flex;flex-direction:column;min-height:540px;overflow:hidden}@media screen and (min-width:780px){.jp-license-activation-screen{flex-direction:row}}.block-editor-block-list__layout .block-editor-block-list__block.has-warning.is-interactive>*{pointer-events:auto;user-select:auto}.block-editor-block-list__layout .block-editor-block-list__block.has-warning.is-interactive:after{content:none}.hdasSNj9k3Sc5PwXK4uE{margin-right:4px;width:16px}.eWN8Hj0SBRDq1F48n_Fg{--gray-70:#3c434a;align-items:center;color:var(--gray-70);display:flex;font-size:14px;text-decoration:none}.jp-dashboard-footer{align-items:center;color:var(--jp-black);display:flex;flex-wrap:wrap;font-size:var(--font-body-extra-small);line-height:1.333;max-width:1128px;width:100%}.jp-dashboard-footer a{text-decoration:none}.jp-dashboard-footer a:any-link,.jp-dashboard-footer a[role=button]{color:inherit}.jp-dashboard-footer a:hover{text-decoration:underline;text-decoration-thickness:1.5px}.jp-dashboard-footer a:focus{box-shadow:none;outline-width:0}.jp-dashboard-footer a:focus-visible{border-radius:2px;box-shadow:none;outline:1.5px solid currentColor;outline-offset:3px}.jp-dashboard-footer.is-sm>ul{gap:.125rem}.jp-dashboard-footer.is-md,.jp-dashboard-footer.is-sm>ul{align-items:flex-start;flex-direction:column}.jp-dashboard-footer>ul{align-items:center;display:flex;flex-wrap:wrap;gap:1rem;list-style:none;margin:0;padding:0;width:100%}.jp-dashboard-footer>ul>li{margin-bottom:0}.jp-dashboard-footer>ul>li>a{align-items:center;display:flex;gap:.25rem;min-height:44px}.jp-dashboard-footer__accessible-external-link{border:0;clip:rect(1px,1px,1px,1px);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;overflow-wrap:normal;padding:0;position:absolute;width:1px}.jp-dashboard-footer__jp-item{font-weight:600;padding-inline-end:1rem}.jp-dashboard-footer.is-sm .jp-dashboard-footer__jp-item{padding-bottom:1rem}.jp-dashboard-footer.is-lg .jp-dashboard-footer__a8c-item{margin-inline-start:auto}.jp-dashboard-footer.is-sm .jp-dashboard-footer__a8c-item{padding-top:1rem}.jp-dashboard-footer__a8c-item>a,.jp-dashboard-footer__jp-item>a{text-decoration:none}.sexr0jUxC1jVixdKiDnC{margin-left:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-left:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.sexr0jUxC1jVixdKiDnC .iWGAhN9gOB48g0jEO1OQ{align-items:center;display:flex;gap:8px}.sexr0jUxC1jVixdKiDnC .JOYmuxQjG4FArIIUxJfA{background:#d63638;color:#fff;cursor:pointer;font-size:9px;font-weight:700;letter-spacing:.2em;text-shadow:none;text-transform:uppercase}.rV_5QyvhDnsVjCX4pb0h{--gray-90:#1e1e1e;fill:var(--gray-90);width:24px}.MO1jDNY8VPqeNS9xL8jE{align-items:center;display:flex;text-decoration:none}.zvd4dCB_bBDiXJKKDqXm{position:relative}.ly4o9lSswAGHFXqGUEIO{position:absolute;right:32px;top:32px;z-index:1}.u64Go3kwEZ7MD9eji0H1{color:var(--jp-gray-50);font-size:13px;margin-bottom:8px;width:60%}._RT41NE3LU4R0ubcij2y{align-items:center;display:flex;gap:8px}._RT41NE3LU4R0ubcij2y li{background:none!important;margin:0!important;padding:0!important}.cFGWJeRiGHjAr8D7CWJW{max-width:110px}.Iz3l7a05TP6HK9S92TIL{width:16px}.lmQ0wFmnk4kKkGVjokPA{height:18px}.ZSFTmY3zE3VP4w0QeaqV{width:16px}.AoIs8wD92wKR8RpQj6Uc{align-items:center;display:inline-flex}.WQVtrU6q0L1Igcj7wCrQ{margin:0;padding:0}.UujoBFTnQNY2cWU2SIsH{font-size:var(--font-headline-medium);font-weight:700;line-height:52px}.TeGO5V_thHw5lDAm1_2M{font-weight:700}.TeGO5V_thHw5lDAm1_2M,.WolQzb2MsSgiNmLtc7_j{font-size:var(--font-headline-small);line-height:40px}.WolQzb2MsSgiNmLtc7_j{font-weight:400}.hUB0JT8p1T2Hw28N6qC8{font-weight:500}.gKZWDv5chz3_O3Syp74H,.hUB0JT8p1T2Hw28N6qC8{font-size:var(--font-title-medium);line-height:32px}.gKZWDv5chz3_O3Syp74H{font-weight:600}.zY2No8Ga4b8shbOQGhnv{font-size:var(--font-title-small);font-weight:500;line-height:30px}.tIj0D1t8Cc892ikmgFPZ{font-size:var(--font-body);font-weight:400;line-height:24px}.KdcN0BnOaVeVhyLRKqhS{font-size:var(--font-body-small);font-weight:400;line-height:24px}.dso3Rh3tl3Xv1GumBktz{font-weight:400}.dso3Rh3tl3Xv1GumBktz,.mQ1UlbN9u4Mg9byO8m7v{font-size:var(--font-body-extra-small);line-height:20px}.mQ1UlbN9u4Mg9byO8m7v{font-weight:700}.PItlW5vRExLnTj4a8eLE{font-size:var(--font-body-extra-small);font-weight:600;line-height:16px}.TwRpPlktzxhmFVeua7P5{margin:calc(var( --spacing-base )*0)}.zVfqx7gyb3o9mxfGynn1{margin-left:calc(var( --spacing-base )*0);margin-right:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy{margin-bottom:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy,.xqDIp6cNVr_E6RXaiPyD{margin-top:calc(var( --spacing-base )*0)}.S8EwaXk1kyPizt6x4WH2{margin-right:calc(var( --spacing-base )*0)}.ODX5Vr1TARoLFkDDFooD{margin-bottom:calc(var( --spacing-base )*0)}.cphJ8dCpfimnky7P2FHg{margin-left:calc(var( --spacing-base )*0)}.PFgIhNxIyiSuNvQjAIYj{margin:calc(var( --spacing-base )*1)}.M2jKmUzDxvJjjVEPU3zn{margin-left:calc(var( --spacing-base )*1);margin-right:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk{margin-bottom:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk,.rcTN5uw9xIEeMEGL3Xi_{margin-top:calc(var( --spacing-base )*1)}.CQSkybjq2TcRM1Xo9COV{margin-right:calc(var( --spacing-base )*1)}.hfqOWgq6_MEGdFE82eOY{margin-bottom:calc(var( --spacing-base )*1)}.I8MxZQYTbuu595yfesWA{margin-left:calc(var( --spacing-base )*1)}.kQkc6rmdpvLKPkyoJtVQ{margin:calc(var( --spacing-base )*2)}.j6vFPxWuu4Jan2ldoxpp{margin-left:calc(var( --spacing-base )*2);margin-right:calc(var( --spacing-base )*2)}.hqr39dC4H_AbactPAkCG{margin-bottom:calc(var( --spacing-base )*2)}.c3dQnMi16C6J6Ecy4283,.hqr39dC4H_AbactPAkCG{margin-top:calc(var( --spacing-base )*2)}.YNZmHOuRo6hU7zzKfPdP{margin-right:calc(var( --spacing-base )*2)}.Db8lbak1_wunpPk8NwKU{margin-bottom:calc(var( --spacing-base )*2)}.ftsYE5J9hLzquQ0tA5dY{margin-left:calc(var( --spacing-base )*2)}.Det4MHzLUW7EeDnafPzq{margin:calc(var( --spacing-base )*3)}.h_8EEAztC29Vve1datb5{margin-left:calc(var( --spacing-base )*3);margin-right:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM{margin-bottom:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM,.soADBBkcIKCBXzCTuV9_{margin-top:calc(var( --spacing-base )*3)}.zSX59ziEaEWGjnpZa4uV{margin-right:calc(var( --spacing-base )*3)}.yrVTnq_WBMbejg89c2ZQ{margin-bottom:calc(var( --spacing-base )*3)}.UKtHPJnI2cXBWtPDm5hM{margin-left:calc(var( --spacing-base )*3)}.guexok_Tqd5Tf52hRlbT{margin:calc(var( --spacing-base )*4)}.oS1E2KfTBZkJ3F0tN7T6{margin-left:calc(var( --spacing-base )*4);margin-right:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd{margin-bottom:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd,.ot2kkMcYHv53hLZ4LSn0{margin-top:calc(var( --spacing-base )*4)}.A1krOZZhlQ6Sp8Cy4bly{margin-right:calc(var( --spacing-base )*4)}.pkDbXXXL32237M0hokEh{margin-bottom:calc(var( --spacing-base )*4)}.XXv4kDTGvEnQeuGKOPU3{margin-left:calc(var( --spacing-base )*4)}.yGqHk1a57gaISwkXwXe6{margin:calc(var( --spacing-base )*5)}.X8cghM358X3DkXLc9aNK{margin-left:calc(var( --spacing-base )*5);margin-right:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f{margin-bottom:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f,.yqeuzwyGQ7zG0avrGqi_{margin-top:calc(var( --spacing-base )*5)}.g9emeCkuHvYhveiJbfXO{margin-right:calc(var( --spacing-base )*5)}.Lvk3dqcyHbZ07QCRlrUQ{margin-bottom:calc(var( --spacing-base )*5)}.r3yQECDQ9qX0XZzXlVAg{margin-left:calc(var( --spacing-base )*5)}.aQhlPwht2Cz1X_63Miw0{margin:calc(var( --spacing-base )*6)}.JyHb0vK3wJgpblL9s5j8{margin-left:calc(var( --spacing-base )*6);margin-right:calc(var( --spacing-base )*6)}.cY2gULL1lAv6WPNIRuf3{margin-bottom:calc(var( --spacing-base )*6)}.NBWQ9Lwhh_fnry3lg_p7,.cY2gULL1lAv6WPNIRuf3{margin-top:calc(var( --spacing-base )*6)}.yIOniNe5E40C8fWvBm5V{margin-right:calc(var( --spacing-base )*6)}.t30usboNSyqfQWIwHvT3{margin-bottom:calc(var( --spacing-base )*6)}.Nm_TyFkYCMhOoghoToKJ{margin-left:calc(var( --spacing-base )*6)}.C4qJKoBXpgKtpmrqtEKB{margin:calc(var( --spacing-base )*7)}.S93Srbu6NQ_PBr7DmTiD{margin-left:calc(var( --spacing-base )*7);margin-right:calc(var( --spacing-base )*7)}.fJj8k6gGJDks3crUZxOS{margin-bottom:calc(var( --spacing-base )*7)}.cW6D6djs7Ppm7fD7TeoV,.fJj8k6gGJDks3crUZxOS{margin-top:calc(var( --spacing-base )*7)}.DuCnqNfcxcP3Z__Yo5Ro{margin-right:calc(var( --spacing-base )*7)}.im8407m2fw5vOg7O2zsw{margin-bottom:calc(var( --spacing-base )*7)}.G0fbeBgvz2sh3uTP9gNl{margin-left:calc(var( --spacing-base )*7)}.kvW3sBCxRxUqz1jrVMJl{margin:calc(var( --spacing-base )*8)}.tOjEqjLONQdkiYx_XRnw{margin-left:calc(var( --spacing-base )*8);margin-right:calc(var( --spacing-base )*8)}.op5hFSx318zgxsoZZNLN{margin-bottom:calc(var( --spacing-base )*8)}.c9WfNHP6TFKWIfLxv52J,.op5hFSx318zgxsoZZNLN{margin-top:calc(var( --spacing-base )*8)}.sBA75QqcqRwwYSHJh2wc{margin-right:calc(var( --spacing-base )*8)}.GpL6idrXmSOM6jB8Ohsf{margin-bottom:calc(var( --spacing-base )*8)}.HbtWJoQwpgGycz8dGzeT{margin-left:calc(var( --spacing-base )*8)}.uxX3khU88VQ_Ah49Ejsa{padding:calc(var( --spacing-base )*0)}.KX0FhpBKwKzs9fOUdbNz{padding-left:calc(var( --spacing-base )*0);padding-right:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz{padding-bottom:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz,.emxLHRjQuJsImnPbQIzE{padding-top:calc(var( --spacing-base )*0)}.kJ8WzlpTVgdViXt8ukP9{padding-right:calc(var( --spacing-base )*0)}.tg_UIUI11VBzrTAn2AzJ{padding-bottom:calc(var( --spacing-base )*0)}.uczvl8kaz84oPQJ2DB2R{padding-left:calc(var( --spacing-base )*0)}.o7UHPcdVK3lt7q3lqV4o{padding:calc(var( --spacing-base )*1)}.IDqEOxvDoYrFYxELPmtX{padding-left:calc(var( --spacing-base )*1);padding-right:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2{padding-bottom:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2,.npy3hw4A5QSkDicb2CJJ{padding-top:calc(var( --spacing-base )*1)}.LgbptTApNY5NwLQvEFAt{padding-right:calc(var( --spacing-base )*1)}.WZQy2SZuZso59bUsXXyl{padding-bottom:calc(var( --spacing-base )*1)}.o331apInxNunbYB3SfPE{padding-left:calc(var( --spacing-base )*1)}.fMPIyD9Vqki1Lrc_yJnG{padding:calc(var( --spacing-base )*2)}.i2pMcTcdrr10IQoiSm_L{padding-left:calc(var( --spacing-base )*2);padding-right:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH{padding-bottom:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH,.o9bGieUKcYc8o0Ij9oZX{padding-top:calc(var( --spacing-base )*2)}.SwZcFez1RDqWsOFjB5iG{padding-right:calc(var( --spacing-base )*2)}.eHpLc_idmuEqeqCTvqkN{padding-bottom:calc(var( --spacing-base )*2)}.vU39i2B4P1fUTMB2l6Vo{padding-left:calc(var( --spacing-base )*2)}.JHWNzBnE29awhdu5BEh1{padding:calc(var( --spacing-base )*3)}.X72lGbb56L3KFzC2xQ9N{padding-left:calc(var( --spacing-base )*3);padding-right:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e{padding-bottom:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e,.srV0KSDC83a2fiimSMMQ{padding-top:calc(var( --spacing-base )*3)}.lUWfkmbQjCskhcNwkyCm{padding-right:calc(var( --spacing-base )*3)}.Ts0dIlc3aTSL7V4cIHis{padding-bottom:calc(var( --spacing-base )*3)}.CzlqQXXhX6MvorArFZ8B{padding-left:calc(var( --spacing-base )*3)}.TqMPkQtR_DdZuKb5vBoV{padding:calc(var( --spacing-base )*4)}.a7UrjhI69Vetlcj9ZVzz{padding-left:calc(var( --spacing-base )*4);padding-right:calc(var( --spacing-base )*4)}.StEhBzGs2Gi5dDEkjhAv{padding-bottom:calc(var( --spacing-base )*4)}.FGneZfZyvYrt1dG0zcnm,.StEhBzGs2Gi5dDEkjhAv{padding-top:calc(var( --spacing-base )*4)}.APEH216rpdlJWgD2fHc8{padding-right:calc(var( --spacing-base )*4)}.oGwXC3ohCic9XnAj6x69{padding-bottom:calc(var( --spacing-base )*4)}.U6gnT9y42ViPNOcNzBwb{padding-left:calc(var( --spacing-base )*4)}.IpdRLBwnHqbqFrixgbYC{padding:calc(var( --spacing-base )*5)}.HgNeXvkBa9o3bQ5fvFZm{padding-left:calc(var( --spacing-base )*5);padding-right:calc(var( --spacing-base )*5)}.tJtFZM3XfPG9v9TSDfN1{padding-bottom:calc(var( --spacing-base )*5)}.PdifHW45QeXYfK568uD8,.tJtFZM3XfPG9v9TSDfN1{padding-top:calc(var( --spacing-base )*5)}.mbLkWTTZ0Za_BBbFZ5b2{padding-right:calc(var( --spacing-base )*5)}.vVWpZpLlWrkTt0hMk8XU{padding-bottom:calc(var( --spacing-base )*5)}.RxfaJj5a1Nt6IavEo5Zl{padding-left:calc(var( --spacing-base )*5)}.SppJULDGdnOGcjZNCYBy{padding:calc(var( --spacing-base )*6)}.palY2nLwdoyooPUm9Hhk{padding-left:calc(var( --spacing-base )*6);padding-right:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_{padding-bottom:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_,.YEEJ9b90ueQaPfiU8aeN{padding-top:calc(var( --spacing-base )*6)}.QE0ssnsKvWJMqlhPbY5u{padding-right:calc(var( --spacing-base )*6)}.n8yA3jHlMRyLd5UIfoND{padding-bottom:calc(var( --spacing-base )*6)}.tXHmxYnHzbwtfxEaG51n{padding-left:calc(var( --spacing-base )*6)}.kBTsPKkO_3g_tLkj77Um{padding:calc(var( --spacing-base )*7)}.RyhrFx6Y1FGDrGAAyaxm{padding-left:calc(var( --spacing-base )*7);padding-right:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO{padding-bottom:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO,.vQVSq6SvWKbOMu6r4H6b{padding-top:calc(var( --spacing-base )*7)}.oBy5__aEADMsH46mrgFX{padding-right:calc(var( --spacing-base )*7)}.KVEXoJqf1s92j0JMdNmN{padding-bottom:calc(var( --spacing-base )*7)}.ZMXGNrNaKW3k_3TLz0Fq{padding-left:calc(var( --spacing-base )*7)}.tuiR9PhkHXhGyEgzRZRI{padding:calc(var( --spacing-base )*8)}.U7454qyWkQNa2iaSJziu{padding-left:calc(var( --spacing-base )*8);padding-right:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8{padding-bottom:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8,.X1rm9DQ1zLGLfogja5Gn{padding-top:calc(var( --spacing-base )*8)}.JS7G6kAuqJo5GIuF8S5t{padding-right:calc(var( --spacing-base )*8)}.Y8F9ga1TDCMbM1lj4gUz{padding-bottom:calc(var( --spacing-base )*8)}.AJuyNGrI63BOWql719H8{padding-left:calc(var( --spacing-base )*8)}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50);text-decoration:underline;white-space:nowrap}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe{align-items:center;display:flex;gap:var(--spacing-base);margin-bottom:calc(var(--spacing-base)*3)}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .VmtuLc2xRqmsO6cK8qjF{position:relative;width:54px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .MdTRfQ3eo5qZKChZlzNj,.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .PbEpL02SEH9VNAlbKCfV{width:32px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .TD4AUM9gcTVAB6JHB5ZR{border-radius:50%;margin-left:-10px;position:absolute;width:32px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .yjl73qv0VWoPP8IhGreh{border-top-style:solid;border-top:2px dashed var(--jp-black);height:0;width:67px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .J0GIu2rNR7rXocQTyd8p{border-color:var(--jp-red)}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .rAV2E93SG8WpokuGk9jh{border-color:var(--jp-yellow-50)}.kezuOHNvu9vdvlJ86Fwg .YZ7FNKEm9qpvQ4ZkbAz5{transform:rotate(180deg)}.kezuOHNvu9vdvlJ86Fwg .TYNMsILey2vUwnyZSjJU{align-self:flex-end;margin-bottom:2px}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz{margin-bottom:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz,.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp{align-items:center;display:flex;gap:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.J0GIu2rNR7rXocQTyd8p{color:var(--jp-red);fill:var(--jp-red)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.rAV2E93SG8WpokuGk9jh{color:var(--jp-yellow-50);fill:var(--jp-yellow-50)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.q4_FOHifGawULuFBZke9 svg{fill:var(--jp-green-50)}.jUxY9oXwnEDQLadQBNQp{animation:odHEpyTWVIDgdJClTyHg 1s linear infinite alternate;border-radius:var(--jp-border-radius-rna);color:transparent}.Vzu6IGmwfFGn5RPCIWOY{margin-bottom:1rem}@keyframes odHEpyTWVIDgdJClTyHg{0%{background-color:#f5f5f5}to{background-color:#e2e2e2}}.IorMv97NU2iEXtcbbVoN{background:var(--jp-white);border-radius:calc(var(--jp-border-radius)/2);box-shadow:0 1px 1px 0 rgba(0,0,0,.1),0 1px 1.5px 0 rgba(0,0,0,.1),0 2px 3px -.5px rgba(0,0,0,.1);left:0;padding:var(--spacing-base);position:absolute;top:calc(100% + var(--spacing-base));z-index:1}.IorMv97NU2iEXtcbbVoN ._I09VyiyxzT6EKE6RwVF{align-items:center;background-color:var(--jp-white);border:none;cursor:pointer;display:flex;gap:calc(var(--spacing-base)*7);padding:var(--spacing-base);width:100%}.IorMv97NU2iEXtcbbVoN ._I09VyiyxzT6EKE6RwVF:hover{background-color:var(--jp-gray-0)}.IorMv97NU2iEXtcbbVoN .Gmum0UGKXz4YlMG9Fwgm{align-items:center;display:flex;font-size:var(--font-label);gap:calc(var(--spacing-base)*.5)}.IorMv97NU2iEXtcbbVoN .przPMe99k8Mad0jsxI1R{background-color:var(--jp-green-50);height:25px;width:25px}.vRIYDzW5yrfnUoDPdBAN{display:flex;position:relative}.vRIYDzW5yrfnUoDPdBAN .KIyEfIhAZ4TElM0K5kuH{align-items:center;border:.5px solid var(--jp-black);border-bottom-right-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius);box-shadow:inset 0 0 0 1px var(--jp-black);cursor:pointer;display:flex;justify-content:center;padding:0}.vRIYDzW5yrfnUoDPdBAN .V4VpHqht9Rm42tiZfsxU{background-color:var(--jp-black);margin-left:.5px}.vRIYDzW5yrfnUoDPdBAN .vZfbVKYvaUjhpAuMD9jg{background-color:var(--jp-white);border-left-width:0;margin-left:-.5px}.SlMzf1xQ5c9GfEx2RQgv a,.SlMzf1xQ5c9GfEx2RQgv button{border-bottom-right-radius:0;border-top-right-radius:0}.OpMBda4vebhRbW8Fm6YC{background:var(--jp-white);border:1px solid var(--jp-gray-5);border-radius:var(--jp-border-radius-rna);box-shadow:0 4px 12px 0 rgba(0,0,0,.06);display:flex;flex-direction:column;height:100%;padding:calc(var(--spacing-base)*3)}.OpMBda4vebhRbW8Fm6YC.BghJAx9hSagUdHWOUaYE{background:none;background-color:var(--jp-white-off);color:var(--jp-black-80);text-decoration:none}.OpMBda4vebhRbW8Fm6YC.BghJAx9hSagUdHWOUaYE:focus{background-color:var(--jp-white);box-shadow:0 0 0 1.5px var(--jp-black);outline:3px solid transparent}.OpMBda4vebhRbW8Fm6YC.IWsEW5nnNWUqqcT3K5L1{box-shadow:0 0 0 1.5px var(--jp-red-60)}.r3UCwgwCthua6lDCvIBI{align-items:center;display:flex;gap:var(--spacing-base);justify-content:space-between;margin-bottom:var(--spacing-base);width:100%}.r3UCwgwCthua6lDCvIBI h3{font-weight:700}.vpluqUMgmwx9_f8wCVIn{align-items:center;display:flex;flex-wrap:wrap-reverse;gap:var(--spacing-base);height:100%}.pIsYsXFAJ9KX2VrS5rmY{min-height:200px;position:relative}.pIsYsXFAJ9KX2VrS5rmY.Pp9cMIaESLYelLOX3tkI{border-color:var(--jp-red-50);border-width:1px}.pIsYsXFAJ9KX2VrS5rmY.NhOH6VeEpSrNGAPQik0w{border-color:#deb100;border-width:1px}.gmPKCDKZcfQt9WieTyKS{flex-grow:1}.fDBaV7I4yUO6w5AWVEtr{align-items:center;display:flex;flex-direction:row-reverse;flex-wrap:wrap;justify-content:space-between;margin-top:auto;min-height:28px;padding-top:calc(var(--spacing-base)*3);width:100%}.SelsBZT7eIWRQyl1dasZ{display:flex;gap:var(--spacing-base);justify-content:flex-start}.LHYJUrOej3toDvOAiz4k{align-items:center;display:flex;gap:var(--spacing-base);justify-content:space-between;margin-bottom:calc(var(--spacing-base)*.5);width:100%}.LHYJUrOej3toDvOAiz4k h3{font-weight:700;line-height:28px}.aZvwqVNw6rvImSxn0DM9{align-items:baseline;display:flex;gap:calc(var(--spacing-base)*.5);margin-bottom:var(--spacing-base)}.R4OXFRkmlHAH8ScIgYXh{color:var(--jp-gray-100);font-size:var(--font-body);font-weight:600}.R4OXFRkmlHAH8ScIgYXh.g0_8bbVjnVh0D_pS264j{color:var(--jp-gray-30);text-decoration:line-through}.nqFgW_S2jbHPu9yPq9E_{color:var(--jp-gray-30);font-size:var(--font-body-extra-small)}.f5VJYwuJmjxH8PVxEbbv{align-items:center;display:flex;height:28px;white-space:nowrap}.f5VJYwuJmjxH8PVxEbbv:before{border-radius:50%;content:"";display:inline-block;height:8px;margin-right:var(--spacing-base);width:8px}.f5VJYwuJmjxH8PVxEbbv.ry3pxoGtmQ0ZeSwp7F_3{color:var(--jp-green-50)}.f5VJYwuJmjxH8PVxEbbv.ry3pxoGtmQ0ZeSwp7F_3:before{background:var(--jp-green-50)}.f5VJYwuJmjxH8PVxEbbv.LZzE3EG7m3CDR46wwwEr{color:var(--jp-gray-50)}.f5VJYwuJmjxH8PVxEbbv.LZzE3EG7m3CDR46wwwEr:before{background:var(--jp-gray-50)}.f5VJYwuJmjxH8PVxEbbv.TZUP7W6QYGajITiMNYas{color:var(--jp-yellow-50)}.f5VJYwuJmjxH8PVxEbbv.TZUP7W6QYGajITiMNYas:before{background:var(--jp-yellow-50)}.f5VJYwuJmjxH8PVxEbbv.Vx_jpT02r8W6NfsRSB02{color:var(--jp-red-60)}.f5VJYwuJmjxH8PVxEbbv.Vx_jpT02r8W6NfsRSB02:before{background:var(--jp-red-60)}.f5VJYwuJmjxH8PVxEbbv.PdsJCfyyjSgrNDheF2qi:before{animation:dWP7ypkVXudMbAa38W5Z .5s linear infinite}@keyframes dWP7ypkVXudMbAa38W5Z{0%{opacity:0}50%{opacity:.5}to{opacity:0}}.info-tooltip__button{align-items:center;background:transparent;border:none;color:var(--jp-gray-50);cursor:pointer;display:flex;padding:2px}.info-tooltip__button svg{margin:0 auto}.info-tooltip__content h3{color:var(--jp-black);font-size:var(--font-title-small);font-weight:500;line-height:calc(var(--font-title-small) + 6px);margin:0 0 calc(var(--spacing-base)*2)}.info-tooltip__content p{color:var(--jp-gray-70);font-size:var(--font-body);line-height:var(--font-title-small);margin-bottom:0}.info-tooltip__content p a{color:var(--jp-black);text-decoration:underline}.info-tooltip__content p a:focus,.info-tooltip__content p a:hover{text-decoration:none}.gridicon{fill:currentColor;display:inline-block}.gridicon.needs-offset g{transform:translate(1px,1px)}.gridicon.needs-offset-x g{transform:translate(1px)}.gridicon.needs-offset-y g{transform:translateY(1px)}.wI7QgVzPXvVVu6kfnTT8{align-items:center;color:var(--jp-black);display:flex;justify-content:space-between;margin-top:1rem}.wI7QgVzPXvVVu6kfnTT8 .eqyxcUmdF0s3gmmlZGyD{display:flex;gap:1.5rem}.wI7QgVzPXvVVu6kfnTT8 .gxY6D0PeVtGk9iSB5E_u{align-items:center;display:flex;font-size:var(--font-body-small);gap:2px;margin:0}.wI7QgVzPXvVVu6kfnTT8 .D_uE0LD5CvpfM2FNp55k{align-items:center;display:flex;gap:2px}.wI7QgVzPXvVVu6kfnTT8 .VTBUdi1D4DW34F0yixMk{font-size:var(--font-body-small);margin:0}.BXQQYCO_pEmYmzBBwYxR{align-items:center;color:var(--jp-black);display:flex;gap:.25rem;margin-top:1rem}.BXQQYCO_pEmYmzBBwYxR .qdvOzzbrd3KQK7DNg8eg{font-size:var(--font-body-small);margin:0}.PFbMp_gtGLBMWbbYtO0q{display:flex;flex-grow:1;flex-wrap:wrap;gap:.25rem;justify-content:space-between}.ZFCNMiywyFvaifoIQI5w{color:var(--jp-gray-40)}.eKy3yAPsoarwSQMou_kk{align-items:center;display:flex;font-weight:500;gap:.25rem}.eKy3yAPsoarwSQMou_kk svg.Bt6AOGkWP6xSfUbq2QBQ{fill:var(--jp-red-60)}.GA8m1YdHe3xODczqUUor{align-items:flex-start;color:var(--jp-gray-50);display:flex;font-size:var(--font-body-extra-small);gap:.25rem;line-height:var(--font-title-small)}.GA8m1YdHe3xODczqUUor .KixWjGbAhopt1dR0Hv9n{padding-top:calc(var(--jp-underline-thickness)*2)}.GA8m1YdHe3xODczqUUor .KixWjGbAhopt1dR0Hv9n>svg{fill:var(--jp-red)}.GA8m1YdHe3xODczqUUor .iGcRsZkwWJW_WJglA1oO{font-size:var(--font-label);font-weight:400;line-height:20px}.value-section__heading{color:var(--jp-gray-100);font-weight:500}.mj-boost-speed-score{margin:calc(var(--spacing-base)*-1);margin-bottom:0;padding:calc(var(--spacing-base))}.mj-boost-speed-score__grade{align-items:center;column-gap:1em;display:flex;font-size:var(--font-body-small);justify-content:space-between;line-height:24px;margin:8px 0}.mj-boost-speed-score__grade--letter{all:unset;border-radius:var(--jp-border-radius);color:var(--jp-green);cursor:pointer;font-size:var(--font-title-small);font-weight:700;line-height:24px;padding:0 5px}.mj-boost-speed-score__grade--letter:focus{outline:1px dotted var(--jp-black)}.boost-score-tooltip__heading{color:#000;font-size:var(--font-title-small);line-height:30px;margin:0}.boost-score-tooltip__content{font-size:var(--font-body);line-height:24px}.boost-score-tooltip__parent{max-width:340px;min-height:150px;padding:24px;width:calc(100vw - 64px)}@media(min-width:783px){.boost-score-tooltip__parent{width:100vw}}.boost-score-tooltip__parent p:last-child{margin-bottom:0}.mj-boost-speed-score__bar .jb-score-bar__label{display:none}.mj-boost-speed-score__bar .jb-score-bar__filler{border-radius:12px;min-width:49px}.mj-boost-speed-score__bar .jb-score-bar__bounds{border-radius:12px;height:24px;margin-left:0}.mj-boost-speed-score__bar .jb-score-bar__score{border-radius:12px;height:24px;width:30px}.mj-boost-speed-score__increase{align-items:center;color:var(--jp-green-50);display:flex;font-size:var(--font-body-small);line-height:28px;position:absolute;right:24px;top:26px;fill:var(--jp-green-50)}.jb-score-bar__label,.jb-score-bar__loading,.jb-score-bar__score{align-items:center;background-color:#fff;border:2px solid transparent;border-radius:42px;display:flex;height:42px}.jb-score-bar{color:var(--jp-gray-70);display:flex;width:100%}.jb-score-bar--mobile{margin-bottom:1.5rem}@media(max-width:767px){.jb-score-bar{flex-direction:column}.jb-score-bar__label{background-color:transparent}}.jb-score-bar__loading{align-items:center;display:flex;justify-content:center;width:42px}.jb-score-bar__label{display:grid;grid-template-columns:24px 1fr;grid-column-gap:10px;font-size:14px;justify-content:center;position:relative}@media(min-width:768px){.jb-score-bar__label{padding-left:15px;padding-right:15px;width:200px;z-index:50}}.jb-score-bar__score{border-radius:100%;font-weight:700;height:42px;justify-content:center;position:absolute;right:-1px;width:42px}.jb-score-bar__bounds{background-color:#f1f1f1;border-radius:21px;display:flex;height:42px;max-width:100%;position:relative;width:100%;z-index:40}@media(min-width:768px){.jb-score-bar__bounds{margin-left:-21px;width:calc(100% + 21px)}}.jb-score-bar__filler{border-radius:0 42px 42px 0;display:flex;justify-content:flex-end;min-width:85px;position:relative;transition:width .3s ease-in-out;width:0;will-change:width}@media(max-width:767px){.jb-score-bar__filler{border-radius:inherit;min-width:43px}}.jb-score-bar__no_boost_score{--clearance-space:74px;background:#fff;background-clip:padding-box;border:2px solid transparent;border-radius:50%;cursor:pointer;font-size:.7em;height:28px;line-height:1.625;padding:3px;position:absolute;text-align:center;top:6px;width:28px;z-index:2}.jb-score-bar__no_boost_score:hover{border:2px solid hsla(0,0%,100%,.5)}.jb-score-bar__no_boost_score:after{border-bottom:6px solid #fff;border-left:6px solid transparent;border-right:6px solid transparent;content:" ";height:0;left:6px;position:absolute;top:28px;width:0}.jb-score-bar__no_boost_score_tooltip{background:#fff;border-radius:4px;box-shadow:0 0 20px 0 hsla(0,0%,67%,.28);display:none;left:-10em;margin:0 16px;padding:16px;position:absolute;top:-62px;width:20em}.jb-score-bar__no_boost_score_tooltip:after{border-left:6px solid transparent;border-right:6px solid transparent;border-top:6px solid #fff;bottom:-6px;content:" ";height:0;left:10em;margin:0 -10px;position:absolute;width:0}.jb-score-bar__no_boost_score:hover .jb-score-bar__no_boost_score_tooltip{display:block}.jb-score-bar .fill-loading{background-color:var(--jp-white)}.jb-score-bar .fill-good{background-color:var(--jp-green)}.jb-score-bar .fill-mediocre{background-color:var(--jp-orange-20)}.jb-score-bar .fill-bad{background-color:var(--jp-red-50)}.g4lyov8aMDggdD4yOi1p{align-items:baseline;display:flex;margin-top:calc(var(--spacing-base)/2)}.g4lyov8aMDggdD4yOi1p .Ys5ScZ_dYn2O2AzDE5Yi{font-size:32px;font-weight:400;line-height:36px;margin-right:var(--spacing-base)}.sUNg_b7XteVXOrpHAkJg :last-child{margin-top:4px}.cF6QAJf1vXXAMuutXPcq{align-items:baseline;display:flex}.cF6QAJf1vXXAMuutXPcq.coY634LconQ7gzDDNJeu{color:var(--jp-gray-10);fill:var(--jp-gray-10)}.cF6QAJf1vXXAMuutXPcq.kyqpwKaL2FyQ8CtxJQ0f{color:var(--jp-green-50);fill:var(--jp-green-50)}.cF6QAJf1vXXAMuutXPcq.aXf37lEOcjpNV8ImLaYK{color:var(--jp-red-40);fill:var(--jp-red-40)}.cF6QAJf1vXXAMuutXPcq .OyGdoGzsQ48VaVVR99_H{left:2px;position:relative;top:2px}.cF6QAJf1vXXAMuutXPcq .cKLicfMCaDSGPlX222jF{font-size:14px;font-weight:600;line-height:24px}.ZaPXoMGC_e8NfFoBgA95,.gb2kSZHPauLu96D9HAIg{margin-bottom:1.5rem}.qpN923qyxjI06NCgFC8j>li{margin-bottom:0}.hpd1bQCLIZYXpZJa22qw{color:var(--jp-gray-100);font-size:var(--font-body-extra-small);font-weight:500;line-height:var(--font-title-small);margin-bottom:calc(var(--spacing-base) + 2px)}.info-tooltip__content{max-width:340px;min-height:150px;padding:24px;width:calc(100vw - 64px)}.components-popover.is-expanded .info-tooltip__content{max-width:unset;width:auto}@media screen and (min-width:599px)and (max-width:1290px){ul.qpN923qyxjI06NCgFC8j{grid-template-columns:repeat(auto-fill,minmax(300px,1fr))}ul.qpN923qyxjI06NCgFC8j>li{grid-column-end:auto}}.value-section{display:flex;justify-content:space-between;margin-top:calc(var(--spacing-base)/2)}.value-section>div{align-items:flex-start;display:flex;flex-direction:column}.value-section__heading{align-items:center;display:flex;text-wrap:nowrap}.value-section__last-scan{align-items:center;column-gap:1px;display:flex;justify-content:flex-end;margin-top:var(--spacing-base);position:absolute;right:calc(var(--spacing-base)*3);width:calc(57% - var(--spacing-base)*3)}.value-section__last-scan div{color:var(--jp-gray-50);font-size:var(--font-body-extra-small);line-height:var(--font-body);text-align:right}@media(max-width:480px){.value-section__last-scan{width:calc(53% - var(--spacing-base)*3)}}.value-section__data{align-items:center;color:var(--jp-gray-50);display:flex;flex:1;font-size:var(--font-body-extra-small);font-weight:500;justify-content:center;line-height:var(--font-title-small)}.value-section__status-icon{display:block;margin-right:calc(var(--spacing-base) - 2px)}.value-section__status-text{letter-spacing:-.24px;margin-right:1px}.scan-threats__threat-count{color:var(--jp-black);font-size:calc(var(--font-title-large) - 4px);font-weight:400;line-height:var(--font-title-large)}.scan-threats__critical-threats{align-items:center;display:flex}.scan-threats__critical-threat-container{margin-left:1px}.scan-threats__critical-threat-container>button>svg{fill:var(--jp-red-50)}.scan-threats__critical-threat-count{color:var(--jp-red-50);margin-left:calc(var(--spacing-base)/4)}.logins_blocked__count{color:var(--jp-black);font-size:calc(var(--font-headline-small) - 4px);font-weight:400;line-height:var(--font-title-large)}.videopress-card__video-count{color:var(--jp-gray-90);display:flex;font-size:calc(var(--font-headline-small) - 4px);line-height:1.125;margin-top:calc(var(--spacing-base)/2)}.videopress-card__video-count .videopress-card__tooltip{height:18px}p.description{color:var(--jp-gray-70);font-size:var(--font-body-small);margin:0 0 1rem}.videopress-card__value-section{display:flex;gap:.75rem;justify-content:space-between}.videopress-card__value-section__container{align-items:flex-start;display:flex;flex-direction:column}.videopress-card__value-section__value-container{align-items:flex-end;display:flex;flex-wrap:wrap}.videopress-card__value-section__value{color:var(--jp-gray-90);font-size:calc(var(--font-headline-small) - 4px);line-height:1}.videopress-card__value-section__previous-value{align-items:center;display:flex;font-size:var(--font-body-extra-small);font-weight:600;line-height:18px}.videopress-card__value-section__previous-value.increase *{color:var(--jp-green-50);fill:var(--jp-green-50)}.videopress-card__value-section__previous-value.decrease *{color:var(--jp-red-50);fill:var(--jp-red-50)}.videopress-card__value-section__heading{align-items:center;display:flex;text-wrap:nowrap}.videopress-card__no-video-tooltip .info-tooltip__button{display:inline;vertical-align:middle}.iG63b_J1HNfT8xEIq619{margin-bottom:.75rem}.T8UhA3lZQjpZsyaah9J6{width:200px}.Tobf3RFq_fT42YGp_h4g{font-size:var(--font-body)}ul.g69ZGQc9wey1u1beD0IP{grid-auto-flow:column;grid-template-columns:repeat(5,100%);overflow-x:auto;scroll-behavior:smooth;scroll-snap-type:x mandatory;scrollbar-width:none;-ms-overflow-style:none}ul.g69ZGQc9wey1u1beD0IP::-webkit-scrollbar{display:none}ul.g69ZGQc9wey1u1beD0IP li{grid-column:unset;grid-column-end:unset;max-width:100%;scroll-snap-align:start;width:100%}@media screen and (min-width:601px){ul.g69ZGQc9wey1u1beD0IP{grid-template-columns:repeat(5,1fr)}ul.g69ZGQc9wey1u1beD0IP li{width:420px}}@media screen and (min-width:1025px){ul.g69ZGQc9wey1u1beD0IP li{width:320px}}.aWIwsRSR2EZlTGwFYt5J{transition:all .3s ease}.DzezAg6fdaIC26GPBCvD:not(:disabled):hover{transform:translateX(-4px)}.buuFW6iZyD5Nnljxcxj8:not(:disabled):hover{transform:translateX(4px)}.HeJe1crc9XaWWpLvIPit .components-modal__frame{border-bottom-left-radius:4px;border-left:4px solid #e68b28;border-top-left-radius:4px;max-height:100%}.HeJe1crc9XaWWpLvIPit .components-modal__content{margin-top:0;padding:0}.HeJe1crc9XaWWpLvIPit .components-modal__header{display:none}.HeJe1crc9XaWWpLvIPit .or0JUScxkJPmNsfrxkEK .jp-idc__idc-screen{border:0}.components-surface.components-card{border-radius:var(--jp-border-radius-rna)}.upsell-banner{background:#f9f9f6;background:linear-gradient(133deg,#ced9f2,#f9f9f6 10%,#f9f9f6 80%,#f5e6b3);display:flex;flex-direction:column}@media screen and (min-width:660px){.upsell-banner{flex-direction:row}}.upsell-banner.components-card__body.components-card-body{border-radius:var(--jp-border-radius-rna);padding:36px}.upsell-banner .upsell-banner--icon{align-items:flex-start;display:flex;margin-bottom:16px;margin-right:0;margin-top:16px}@media screen and (min-width:660px){.upsell-banner .upsell-banner--icon{align-items:center;margin-bottom:0;margin-right:28px;margin-top:0}}.upsell-banner .upsell-banner--content{display:flex;flex:1;flex-direction:column;justify-content:space-between}@media screen and (min-width:660px){.upsell-banner .upsell-banner--content{flex-direction:row}}.upsell-banner .upsell-banner--content .upsell-banner--content-info{display:flex;flex-direction:column}.upsell-banner .upsell-banner--content .upsell-banner--content-info h3{font-size:1.5rem;font-weight:500;line-height:32px;margin:0}.upsell-banner .upsell-banner--content .upsell-banner--content-info p{font-size:1rem;margin:8px 0 0}.upsell-banner .upsell-banner--content .upsell-banner--content-cta{align-items:center;display:flex;flex-direction:row;margin-left:0;margin-top:16px}@media screen and (min-width:660px){.upsell-banner .upsell-banner--content .upsell-banner--content-cta{margin-left:16px;margin-top:0}}.upsell-banner .upsell-banner--content .upsell-banner--content-cta .upsell-banner--content-cta-button{box-shadow:inset 0 0 0 1.5px #000;font-weight:400;padding:8px 16px;white-space:nowrap}.upsell-banner .upsell-banner--content .upsell-banner--content-cta .upsell-banner--content-cta-button.secondary{background-color:var(--jp-white);color:var(--jp-black)}.upsell-banner .upsell-banner--content .upsell-banner--content-cta .upsell-banner--content-cta-button.primary{margin-left:8px}.yWUvvF4WJLNDSpMgBMfm{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ka1fVHj2HOkHjhdoEFOZ{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.ka1fVHj2HOkHjhdoEFOZ{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.ka1fVHj2HOkHjhdoEFOZ{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.JMOO4Y_9yhTO9lwLnRUx{grid-column-end:span 1}.PFDPAqk51qox_ChLqJwm{grid-column-end:span 2}.ault0jHVfWpShqOGooIP{grid-column-end:span 3}.GqpvdRzmzPJELtSm4FEN{grid-column-end:span 4}@media(min-width:600px){.Ym4_YneEGD_iZD6W1C2o{grid-column-end:span 1}.NbvHnnDtWw8n9BEUQ0Oy{grid-column-end:span 2}.ElMT7rhxe5ZJKO41MnhW{grid-column-end:span 3}.yKjnqjibn_wW_1tWWt5Q{grid-column-end:span 4}.Pb30lOcQFpzUX57GwflS{grid-column-end:span 5}.pC1wxc_R8y4pNILHsiiY{grid-column-end:span 6}.pChscSCnudQoWGjMFKI_{grid-column-end:span 7}.qw1H2gAgF3lDCI2Tbkmb{grid-column-end:span 8}}@media(min-width:960px){.VzcA_rrxBK3g4ozA0oD9{grid-column-end:span 1}.pNAa7O2adRZD8Slgk9iR{grid-column-end:span 2}.tlIMLlipexblj8CeOx4B{grid-column-end:span 3}.Dvt0u5l2Rr1BhBmvYAzl{grid-column-end:span 4}.BiUsgNTc0tyc7tC5jnzE{grid-column-end:span 5}.ulJXAsj7G2ROJ1g3_s28{grid-column-end:span 6}.HsoVlyVLsXYClx9Atox0{grid-column-end:span 7}.oXxjRQNNj2cfIpFBqC1W{grid-column-end:span 8}.qXgUn4Adg9xE_JnbuDio{grid-column-end:span 9}.xMpqTLiLfYFEJiRPQQQq{grid-column-end:span 10}.IiGo3Sz2FDZN7_eGElwA{grid-column-end:span 11}.Om8BNCjfgqQ_wmPQjfOY{grid-column-end:span 12}}@media(max-width:960px){.t10ZWzP7ADjJnR4tqxRS{display:none}}@media(max-width:600px){.eOUlZG8Pelh_Xj0aSoHG{display:none}}.l546LrwBEePz434NFK5Q{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);display:block;margin:32px 0;padding:16px 64px 16px 24px;position:relative;text-decoration:none}.l546LrwBEePz434NFK5Q span{display:block}.l546LrwBEePz434NFK5Q span:last-of-type{font-weight:600}.l546LrwBEePz434NFK5Q:focus span:last-of-type,.l546LrwBEePz434NFK5Q:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.l546LrwBEePz434NFK5Q:focus:after,.l546LrwBEePz434NFK5Q:hover:after{transform:translateY(-50%) translateX(8px)}.l546LrwBEePz434NFK5Q:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;position:absolute;right:24px;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.Q7w4fcEcemZ2nlwaYNog{fill:var(--jp-yellow-30)!important;display:inline-block!important;width:1.1em!important}.AoNQsOaTt6gSf0H6Yasz{display:inline-block;position:relative}.v13ZwGzUnecPA7Y3URAl{height:18px;left:-53px;pointer-events:none;position:absolute;top:0;width:124px}.EeDbu9pXFWTsCzfTpv2v{pointer-events:all}.BmSvoIi3rErkcrRiOi2W{color:var(--jp-black);font-size:16px;font-weight:600;line-height:19px}.BmSvoIi3rErkcrRiOi2W:not(:last-child){margin-bottom:8px}.mojRoVuWdDJo0E6LEjJw{font-size:14px;font-weight:400;line-height:24px}.golden-token-icon-tooltip .components-popover:not([data-y-axis=middle])[data-x-axis=left] .components-popover__content{margin-right:-62px}.golden-token-icon-tooltip .components-popover:not([data-y-axis=middle])[data-x-axis=right] .components-popover__content{margin-left:-62px}.golden-token-icon-tooltip .components-popover[data-y-axis=bottom] .components-popover__content{top:2px!important}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:before{top:-6px!important}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:after{top:-4px!important}.golden-token-icon-tooltip .components-popover[data-y-axis=top] .components-popover__content{bottom:10px!important}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=top]:before{bottom:3px}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=top]:after{bottom:4px}.golden-token-icon-tooltip .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;outline:none;padding:24px;white-space:normal;width:304px}.golden-token-icon-tooltip .components-button.is-link:focus:not(:disabled){box-shadow:none}.wiobThfXJCuhGNrbFIT6 a,.wiobThfXJCuhGNrbFIT6 a:active,.wiobThfXJCuhGNrbFIT6 a:hover{color:var(--jp-black)}.pm2EPQZx6p2VQSiiVCpX{margin-bottom:calc(var(--spacing-base)*3)}.VgAxgahF9bC2M__FiIgV{display:flex}.dbRwkMLqcMF67njPoAF7{margin-right:8px}.V8N_dXausMNmQUO_ROa1{color:var(--jp-red-60)}.jYhEGFLjpRv6QV1Ti7dQ{color:var(--jp-yellow-40)}.Doju0RxvvN9JS12mf489{line-height:calc(var(--spacing-base)*3);margin:0 0 var(--spacing-base) 0}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color--rgb:0,124,186;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-10--rgb:0,107,161;--wp-admin-theme-color-darker-20:#005a87;--wp-admin-theme-color-darker-20--rgb:0,90,135;--wp-block-synced-color:#7a00df;--wp-block-synced-color--rgb:122,0,223;--wp-bound-block-color:var(--wp-block-synced-color)}.dataviews-wrapper{box-sizing:border-box;container:dataviews-wrapper/inline-size;display:flex;flex-direction:column;font-size:13px;height:100%;line-height:1.4;overflow:auto;scroll-padding-bottom:64px}.dataviews-filters__container,.dataviews__view-actions{box-sizing:border-box;flex-shrink:0;left:0;padding:16px 48px;position:sticky}@media not (prefers-reduced-motion){.dataviews-filters__container,.dataviews__view-actions{transition:padding .1s ease-out}}.dataviews-loading,.dataviews-no-results{align-items:center;display:flex;flex-grow:1;justify-content:center;padding:0 48px}@media not (prefers-reduced-motion){.dataviews-loading,.dataviews-no-results{transition:padding .1s ease-out}}@container (max-width: 430px){.dataviews-filters__container,.dataviews__view-actions{padding:12px 24px}.dataviews-loading,.dataviews-no-results{padding-left:24px;padding-right:24px}}.dataviews-title-field{font-size:13px;font-weight:500;width:100%}.dataviews-title-field,.dataviews-title-field a{color:#2f2f2f;text-overflow:ellipsis;white-space:nowrap}.dataviews-title-field a{display:block;flex-grow:0;overflow:hidden;text-decoration:none}.dataviews-title-field a:hover{color:var(--wp-admin-theme-color)}.dataviews-title-field a:focus{border-radius:2px;box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color,#007cba);color:var(--wp-admin-theme-color--rgb)}.dataviews-title-field button.components-button.is-link{color:#1e1e1e;display:block;font-weight:inherit;overflow:hidden;text-decoration:none;text-overflow:ellipsis;white-space:nowrap;width:100%}.dataviews-title-field button.components-button.is-link:hover{color:var(--wp-admin-theme-color)}.dataviews-title-field--clickable{color:#2f2f2f;cursor:pointer}.dataviews-title-field--clickable:hover{color:var(--wp-admin-theme-color)}.dataviews-title-field--clickable:focus{border-radius:2px;box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color,#007cba);color:var(--wp-admin-theme-color--rgb)}.dataviews-bulk-actions-footer__item-count{color:#1e1e1e;font-size:11px;font-weight:500;text-transform:uppercase}.dataviews-bulk-actions-footer__container{margin-right:auto;min-height:32px}.dataviews-filters__button{position:relative}.dataviews-filters__container{padding-top:0}.dataviews-filters__reset-button.dataviews-filters__reset-button[aria-disabled=true],.dataviews-filters__reset-button.dataviews-filters__reset-button[aria-disabled=true]:hover{opacity:0}.dataviews-filters__reset-button.dataviews-filters__reset-button[aria-disabled=true]:focus{opacity:1}.dataviews-filters__summary-popover{font-size:13px;line-height:1.4}.dataviews-filters__summary-popover .components-popover__content{border-radius:4px;width:230px}.dataviews-filters__summary-popover.components-dropdown__content .components-popover__content{padding:0}.dataviews-filters__summary-operators-container{padding:8px 8px 0}.dataviews-filters__summary-operators-container:has(+.dataviews-filters__search-widget-listbox){border-bottom:1px solid #e0e0e0;padding-bottom:8px}.dataviews-filters__summary-operators-container:empty{display:none}.dataviews-filters__summary-operators-container .dataviews-filters__summary-operators-filter-name{color:#757575}.dataviews-filters__summary-chip-container{position:relative;white-space:pre-wrap}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip{align-items:center;background:#f0f0f0;border:1px solid transparent;border-radius:16px;box-sizing:border-box;color:#2f2f2f;cursor:pointer;display:flex;min-height:32px;padding:4px 12px;position:relative}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-reset{padding-inline-end:28px}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip:focus-visible,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip:hover,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip[aria-expanded=true]{background:#e0e0e0;color:#1e1e1e}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-values{background:rgba(var(--wp-admin-theme-color--rgb),.04);color:var(--wp-admin-theme-color)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-values:hover,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-values[aria-expanded=true]{background:rgba(var(--wp-admin-theme-color--rgb),.12)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip:focus-visible{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:none}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip .dataviews-filters-__summary-filter-text-name{font-weight:500}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove{align-items:center;background:transparent;border:0;border-radius:50%;cursor:pointer;display:flex;height:24px;justify-content:center;padding:0;position:absolute;right:4px;top:50%;transform:translateY(-50%);width:24px}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove svg{fill:#757575}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:focus,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:hover{background:#e0e0e0}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:focus svg,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:hover svg{fill:#1e1e1e}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove.has-values svg{fill:var(--wp-admin-theme-color)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove.has-values:hover{background:rgba(var(--wp-admin-theme-color--rgb),.08)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:focus-visible{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:none}.dataviews-filters__search-widget-filter-combobox-list{border-top:1px solid #e0e0e0;max-height:184px;overflow:auto;padding:4px}.dataviews-filters__search-widget-filter-combobox-list .dataviews-filters__search-widget-filter-combobox-item-value [data-user-value]{font-weight:600}.dataviews-filters__search-widget-listbox{overflow:auto;padding:4px}.dataviews-filters__search-widget-listitem{align-items:center;border-radius:2px;box-sizing:border-box;cursor:default;display:flex;gap:8px;margin-block-end:2px;padding:8px 12px}.dataviews-filters__search-widget-listitem:last-child{margin-block-end:0}.dataviews-filters__search-widget-listitem:focus,.dataviews-filters__search-widget-listitem:hover,.dataviews-filters__search-widget-listitem[data-active-item]{background-color:var(--wp-admin-theme-color);color:#fff}.dataviews-filters__search-widget-listitem:focus .dataviews-filters__search-widget-listitem-check,.dataviews-filters__search-widget-listitem:hover .dataviews-filters__search-widget-listitem-check,.dataviews-filters__search-widget-listitem[data-active-item] .dataviews-filters__search-widget-listitem-check{fill:#fff}.dataviews-filters__search-widget-listitem:focus .dataviews-filters__search-widget-listitem-description,.dataviews-filters__search-widget-listitem:hover .dataviews-filters__search-widget-listitem-description,.dataviews-filters__search-widget-listitem[data-active-item] .dataviews-filters__search-widget-listitem-description{color:#fff}.dataviews-filters__search-widget-listitem .dataviews-filters__search-widget-listitem-check{flex-shrink:0;height:24px;width:24px}.dataviews-filters__search-widget-listitem .dataviews-filters__search-widget-listitem-description{color:#757575;display:block;font-size:12px;line-height:16px;overflow:hidden;text-overflow:ellipsis}.dataviews-filters__search-widget-filter-combobox__wrapper{padding:8px;position:relative}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{background:#f0f0f0;border:none;border-radius:2px;box-shadow:0 0 0 transparent;display:block;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;height:32px;line-height:normal;margin-left:0;margin-right:0;padding:0 32px 0 8px;width:100%}@media not (prefers-reduced-motion){.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{transition:box-shadow .1s linear}}@media(min-width:600px){.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{font-size:13px;line-height:normal}}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-moz-placeholder{color:rgba(30,30,30,.62)}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width:600px){.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{font-size:13px}}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input:focus{background:#fff;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color)}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::placeholder{color:#757575}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-cancel-button,.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-decoration,.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-results-button,.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-results-decoration{-webkit-appearance:none}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__icon{align-items:center;display:flex;justify-content:center;position:absolute;right:12px;top:50%;transform:translateY(-50%);width:24px}.dataviews-filters__container-visibility-toggle{flex-shrink:0;position:relative}.dataviews-filters-toggle__count{background:var(--wp-admin-theme-color,#3858e9);border-radius:8px;box-sizing:border-box;color:#fff;font-size:11px;height:16px;line-height:16px;min-width:16px;outline:var(--wp-admin-border-width-focus) solid #fff;padding:0 4px;position:absolute;right:0;text-align:center;top:0;transform:translate(50%,-50%)}.dataviews-search{width:fit-content}.dataviews-footer{background-color:#fff;border-top:1px solid #f0f0f0;bottom:0;flex-shrink:0;left:0;padding:12px 48px;position:sticky;z-index:2}@media not (prefers-reduced-motion){.dataviews-footer{transition:padding .1s ease-out}}@container (max-width: 430px){.dataviews-footer{padding:12px 24px}}@container (max-width: 560px){.dataviews-footer{flex-direction:column!important}.dataviews-footer .dataviews-bulk-actions-footer__container{width:100%}.dataviews-footer .dataviews-bulk-actions-footer__item-count{flex-grow:1}.dataviews-footer .dataviews-pagination{justify-content:space-between;width:100%}}.dataviews-pagination__page-select{font-size:11px;font-weight:500;text-transform:uppercase}@media(min-width:600px){.dataviews-pagination__page-select .components-select-control__input{font-size:11px!important;font-weight:500}}.dataviews-action-modal{z-index:1000001}.dataviews-selection-checkbox{--checkbox-input-size:24px;flex-shrink:0;line-height:0}@media(min-width:600px){.dataviews-selection-checkbox{--checkbox-input-size:16px}}.dataviews-selection-checkbox .components-checkbox-control__input-container{margin:0}.dataviews-view-config{container-type:inline-size;font-size:13px;line-height:1.4;width:320px}.dataviews-config__popover.is-expanded .dataviews-config__popover-content-wrapper{height:100%;overflow-y:scroll}.dataviews-config__popover.is-expanded .dataviews-config__popover-content-wrapper .dataviews-view-config{width:auto}.dataviews-view-config__sort-direction .components-toggle-group-control-option-base{text-transform:uppercase}.dataviews-settings-section__title.dataviews-settings-section__title{font-size:15px;line-height:24px}.dataviews-settings-section__sidebar{grid-column:span 4}.dataviews-settings-section__content,.dataviews-settings-section__content>*{grid-column:span 8}.dataviews-settings-section__content .is-divided-in-two{display:contents}.dataviews-settings-section__content .is-divided-in-two>*{grid-column:span 4}.dataviews-settings-section:has(.dataviews-settings-section__content:empty){display:none}@container (max-width: 500px){.dataviews-settings-section.dataviews-settings-section{grid-template-columns:repeat(2,1fr)}.dataviews-settings-section.dataviews-settings-section .dataviews-settings-section__content,.dataviews-settings-section.dataviews-settings-section .dataviews-settings-section__sidebar{grid-column:span 2}}.dataviews-field-control__field{height:32px}.dataviews-field-control__actions{position:absolute;top:-9999em}.dataviews-field-control__actions.dataviews-field-control__actions{gap:4px}.dataviews-field-control__field.is-interacting .dataviews-field-control__actions,.dataviews-field-control__field:focus-within .dataviews-field-control__actions,.dataviews-field-control__field:hover .dataviews-field-control__actions{position:unset;top:unset}.dataviews-field-control__icon{display:flex;width:24px}.dataviews-field-control__label-sub-label-container{flex-grow:1}.dataviews-field-control__label{display:block}.dataviews-field-control__sub-label{color:#757575;font-size:11px;font-style:normal;margin-bottom:0;margin-top:8px}.dataviews-view-grid{container-type:inline-size;grid-template-rows:max-content;margin-bottom:auto;padding:0 48px 24px}@media not (prefers-reduced-motion){.dataviews-view-grid{transition:padding .1s ease-out}}.dataviews-view-grid .dataviews-view-grid__card{height:100%;justify-content:flex-start;position:relative}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__title-actions{padding:8px 0 4px}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__title-field{align-items:center;display:flex;min-height:24px}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__title-field--clickable{width:fit-content}.dataviews-view-grid .dataviews-view-grid__card.is-selected .dataviews-view-grid__fields .dataviews-view-grid__field .dataviews-view-grid__field-value{color:#1e1e1e}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__media:focus:after,.dataviews-view-grid .dataviews-view-grid__card.is-selected .dataviews-view-grid__media:after{background-color:rgba(var(--wp-admin-theme-color--rgb),.08)}.dataviews-view-grid .dataviews-view-grid__card.is-selected .dataviews-view-grid__media:after{box-shadow:inset 0 0 0 1px var(--wp-admin-theme-color)}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__media:focus:after{box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color)}.dataviews-view-grid .dataviews-view-grid__media{aspect-ratio:1/1;background-color:#f0f0f0;border-radius:4px;min-height:200px;position:relative;width:100%}.dataviews-view-grid .dataviews-view-grid__media img{height:100%;object-fit:cover;width:100%}.dataviews-view-grid .dataviews-view-grid__media:after{border-radius:4px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1);content:"";height:100%;left:0;pointer-events:none;position:absolute;top:0;width:100%}.dataviews-view-grid .dataviews-view-grid__fields{font-size:12px;line-height:16px;position:relative}.dataviews-view-grid .dataviews-view-grid__fields:not(:empty){padding:0 0 12px}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field-value:not(:empty){line-height:20px;min-height:24px;padding-top:2px}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field{align-items:center;min-height:24px}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field .dataviews-view-grid__field-name{color:#757575;width:35%}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field .dataviews-view-grid__field-value{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:65%}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field:not(:has(.dataviews-view-grid__field-value:not(:empty))){display:none}.dataviews-view-grid .dataviews-view-grid__badge-fields:not(:empty){padding-bottom:12px}@container (max-width: 480px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(1,minmax(0,1fr));padding-left:24px;padding-right:24px}}@container (min-width: 480px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@container (min-width: 780px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}@container (min-width: 1140px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(4,minmax(0,1fr))}}@container (min-width: 1520px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(5,minmax(0,1fr))}}.dataviews-view-grid__field-value:empty,.dataviews-view-grid__field:empty{display:none}.dataviews-view-grid__card .dataviews-selection-checkbox{left:8px;position:absolute;top:-9999em;z-index:1}.dataviews-view-grid__card.is-selected .dataviews-selection-checkbox,.dataviews-view-grid__card:focus-within .dataviews-selection-checkbox,.dataviews-view-grid__card:hover .dataviews-selection-checkbox{top:8px}.dataviews-view-grid__media--clickable{cursor:pointer}div.dataviews-view-list{list-style-type:none}.dataviews-view-list{margin:0 0 auto}.dataviews-view-list div[role=row]{border-top:1px solid #f0f0f0;margin:0}.dataviews-view-list div[role=row] .dataviews-view-list__item-wrapper{box-sizing:border-box;padding:16px 24px;position:relative}.dataviews-view-list div[role=row] .dataviews-view-list__item-actions{flex:0;overflow:hidden}.dataviews-view-list div[role=row] .dataviews-view-list__item-actions>div{height:24px}.dataviews-view-list div[role=row] .dataviews-view-list__item-actions .components-button{opacity:0;position:relative;z-index:1}.dataviews-view-list div[role=row]:where(.is-selected,.is-hovered,:focus-within) .dataviews-view-list__item-actions{flex-basis:min-content;overflow:unset;padding-inline-end:4px}.dataviews-view-list div[role=row]:where(.is-selected,.is-hovered,:focus-within) .dataviews-view-list__item-actions .components-button{opacity:1}.dataviews-view-list div[role=row].is-selected.is-selected,.dataviews-view-list div[role=row].is-selected.is-selected+div[role=row]{border-top:1px solid rgba(var(--wp-admin-theme-color--rgb),.12)}.dataviews-view-list div[role=row]:not(.is-selected) .dataviews-view-list__title-field{color:#1e1e1e}.dataviews-view-list div[role=row]:not(.is-selected).is-hovered,.dataviews-view-list div[role=row]:not(.is-selected):focus-within,.dataviews-view-list div[role=row]:not(.is-selected):hover{background-color:#f8f8f8;color:var(--wp-admin-theme-color)}.dataviews-view-list div[role=row]:not(.is-selected).is-hovered .dataviews-view-list__fields,.dataviews-view-list div[role=row]:not(.is-selected).is-hovered .dataviews-view-list__title-field,.dataviews-view-list div[role=row]:not(.is-selected):focus-within .dataviews-view-list__fields,.dataviews-view-list div[role=row]:not(.is-selected):focus-within .dataviews-view-list__title-field,.dataviews-view-list div[role=row]:not(.is-selected):hover .dataviews-view-list__fields,.dataviews-view-list div[role=row]:not(.is-selected):hover .dataviews-view-list__title-field{color:var(--wp-admin-theme-color)}.dataviews-view-list div[role=row].is-selected .dataviews-view-list__item-wrapper,.dataviews-view-list div[role=row].is-selected:focus-within .dataviews-view-list__item-wrapper{background-color:rgba(var(--wp-admin-theme-color--rgb),.04);color:#1e1e1e}.dataviews-view-list div[role=row].is-selected .dataviews-view-list__item-wrapper .dataviews-view-list__fields,.dataviews-view-list div[role=row].is-selected .dataviews-view-list__item-wrapper .dataviews-view-list__title-field,.dataviews-view-list div[role=row].is-selected:focus-within .dataviews-view-list__item-wrapper .dataviews-view-list__fields,.dataviews-view-list div[role=row].is-selected:focus-within .dataviews-view-list__item-wrapper .dataviews-view-list__title-field{color:var(--wp-admin-theme-color)}.dataviews-view-list .dataviews-view-list__item{appearance:none;background:none;border:none;cursor:pointer;inset:0;padding:0;position:absolute;scroll-margin:8px 0;z-index:1}.dataviews-view-list .dataviews-view-list__item:focus-visible{outline:none}.dataviews-view-list .dataviews-view-list__item:focus-visible:before{border-radius:2px;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);content:"";inset:var(--wp-admin-border-width-focus);outline:2px solid transparent;position:absolute}.dataviews-view-list .dataviews-view-list__title-field{flex:1;line-height:24px;min-height:24px;overflow:hidden}.dataviews-view-list .dataviews-view-list__title-field:has(a,button){z-index:1}.dataviews-view-list .dataviews-view-list__media-wrapper{background-color:#f0f0f0;border-radius:4px;flex-shrink:0;height:52px;overflow:hidden;position:relative;width:52px}.dataviews-view-list .dataviews-view-list__media-wrapper img{height:100%;object-fit:cover;width:100%}.dataviews-view-list .dataviews-view-list__media-wrapper:after{border-radius:4px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1);content:"";height:100%;left:0;position:absolute;top:0;width:100%}.dataviews-view-list .dataviews-view-list__field-wrapper{flex-grow:1;min-height:52px}.dataviews-view-list .dataviews-view-list__fields{color:#757575;display:flex;flex-wrap:wrap;font-size:12px;gap:12px;row-gap:4px}.dataviews-view-list .dataviews-view-list__fields:empty{display:none}.dataviews-view-list .dataviews-view-list__fields .dataviews-view-list__field:has(.dataviews-view-list__field-value:empty){display:none}.dataviews-view-list .dataviews-view-list__fields .dataviews-view-list__field-value{align-items:center;display:flex;line-height:20px;min-height:24px}.dataviews-view-list+.dataviews-pagination{justify-content:space-between}.dataviews-view-table{border-collapse:collapse;border-color:inherit;color:#757575;margin-bottom:auto;position:relative;text-indent:0;width:100%}.dataviews-view-table th{color:#1e1e1e;font-size:13px;font-weight:400;text-align:left}.dataviews-view-table td,.dataviews-view-table th{padding:12px;white-space:nowrap}.dataviews-view-table td.dataviews-view-table__actions-column,.dataviews-view-table th.dataviews-view-table__actions-column{text-align:right}.dataviews-view-table td.dataviews-view-table__checkbox-column,.dataviews-view-table th.dataviews-view-table__checkbox-column{padding-right:0;width:1%}.dataviews-view-table tr{border-top:1px solid #f0f0f0}.dataviews-view-table tr .dataviews-view-table-header-button{gap:4px}.dataviews-view-table tr td:first-child,.dataviews-view-table tr th:first-child{padding-left:48px}.dataviews-view-table tr td:first-child .dataviews-view-table-header-button,.dataviews-view-table tr th:first-child .dataviews-view-table-header-button{margin-left:-8px}.dataviews-view-table tr td:last-child,.dataviews-view-table tr th:last-child{padding-right:48px}.dataviews-view-table tr:last-child{border-bottom:0}.dataviews-view-table tr.is-hovered{background-color:#f8f8f8}.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input{opacity:0}.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input:checked,.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input:focus,.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input:indeterminate{opacity:1}.dataviews-view-table tr .dataviews-item-actions .components-button:not(.dataviews-all-actions-button){opacity:0}.dataviews-view-table tr.is-hovered .components-checkbox-control__input,.dataviews-view-table tr.is-hovered .dataviews-item-actions .components-button:not(.dataviews-all-actions-button),.dataviews-view-table tr:focus-within .components-checkbox-control__input,.dataviews-view-table tr:focus-within .dataviews-item-actions .components-button:not(.dataviews-all-actions-button),.dataviews-view-table tr:hover .components-checkbox-control__input,.dataviews-view-table tr:hover .dataviews-item-actions .components-button:not(.dataviews-all-actions-button){opacity:1}@media(hover:none){.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input,.dataviews-view-table tr .dataviews-item-actions .components-button:not(.dataviews-all-actions-button){opacity:1}}.dataviews-view-table tr.is-selected{background-color:rgba(var(--wp-admin-theme-color--rgb),.04);color:#757575}.dataviews-view-table tr.is-selected,.dataviews-view-table tr.is-selected+tr{border-top:1px solid rgba(var(--wp-admin-theme-color--rgb),.12)}.dataviews-view-table tr.is-selected:hover{background-color:rgba(var(--wp-admin-theme-color--rgb),.08)}.dataviews-view-table thead{inset-block-start:0;position:sticky;z-index:1}.dataviews-view-table thead tr{border:0}.dataviews-view-table thead th{background-color:#fff;font-size:11px;font-weight:500;padding-bottom:8px;padding-left:12px;padding-top:8px;text-transform:uppercase}.dataviews-view-table thead th:has(.dataviews-view-table-header-button):not(:first-child){padding-left:4px}.dataviews-view-table tbody td{vertical-align:top}.dataviews-view-table tbody .dataviews-view-table__cell-content-wrapper{align-items:center;display:flex;min-height:32px}.dataviews-view-table tbody .components-v-stack>.dataviews-view-table__cell-content-wrapper:not(:first-child){min-height:0}.dataviews-view-table .dataviews-view-table-header-button{font-size:11px;font-weight:500;padding:4px 8px;text-transform:uppercase}.dataviews-view-table .dataviews-view-table-header-button:not(:hover){color:#1e1e1e}.dataviews-view-table .dataviews-view-table-header-button span{speak:none}.dataviews-view-table .dataviews-view-table-header-button span:empty{display:none}.dataviews-view-table .dataviews-view-table-header{padding-left:4px}.dataviews-view-table .dataviews-view-table__actions-column{width:1%}.dataviews-view-table:has(tr.is-selected) .components-checkbox-control__input{opacity:1}.dataviews-view-table.has-compact-density thead th:has(.dataviews-view-table-header-button):not(:first-child){padding-left:0}.dataviews-view-table.has-compact-density td,.dataviews-view-table.has-compact-density th{padding:4px 8px}.dataviews-view-table.has-comfortable-density td,.dataviews-view-table.has-comfortable-density th{padding:16px 12px}.dataviews-view-table.has-comfortable-density td.dataviews-view-table__checkbox-column,.dataviews-view-table.has-comfortable-density th.dataviews-view-table__checkbox-column,.dataviews-view-table.has-compact-density td.dataviews-view-table__checkbox-column,.dataviews-view-table.has-compact-density th.dataviews-view-table__checkbox-column{padding-right:0}@container (max-width: 430px){.dataviews-view-table tr td:first-child,.dataviews-view-table tr th:first-child{padding-left:24px}.dataviews-view-table tr td:last-child,.dataviews-view-table tr th:last-child{padding-right:24px}}.dataviews-view-table-selection-checkbox{--checkbox-input-size:24px}@media(min-width:600px){.dataviews-view-table-selection-checkbox{--checkbox-input-size:16px}}.dataviews-column-primary__media{max-width:60px}.dataviews-controls__datetime{border:none;padding:0}.dataforms-layouts-panel__field{align-items:flex-start!important;justify-content:flex-start!important;min-height:32px;width:100%}.dataforms-layouts-panel__field-label{align-items:center;display:flex;flex-shrink:0;hyphens:auto;line-height:20px;min-height:32px;padding:6px 0;width:38%}.dataforms-layouts-panel__field-control{align-items:center;display:flex;flex-grow:1;min-height:32px}.dataforms-layouts-panel__field-control .components-button{max-width:100%;min-height:32px;text-align:left;text-wrap:balance;text-wrap:pretty;white-space:normal}.dataforms-layouts-panel__field-control .components-dropdown{max-width:100%}.dataforms-layouts-panel__field-dropdown .components-popover__content{min-width:320px;padding:16px}.dataforms-layouts-panel__dropdown-header{margin-bottom:16px}.components-popover.components-dropdown__content.dataforms-layouts-panel__field-dropdown{z-index:159990}.dataforms-layouts-regular__field{align-items:flex-start!important;justify-content:flex-start!important;min-height:32px;width:100%}.dataforms-layouts-regular__field .components-base-control__label{font-size:inherit;font-weight:400;text-transform:none}.dataforms-layouts-regular__field-label{align-items:center;display:flex;flex-shrink:0;hyphens:auto;line-height:20px;min-height:32px;padding:6px 0;width:38%}.dataforms-layouts-regular__field-control{align-items:center;display:flex;flex-grow:1;min-height:32px}:root{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color--rgb:56,88,233;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-10--rgb:33,69,230;--wp-admin-theme-color-darker-20:#183ad6;--wp-admin-theme-color-darker-20--rgb:24,58,214;--wp-admin-border-width-focus:2px}@media(min-resolution:192dpi){:root{--wp-admin-border-width-focus:1.5px}}@media not (prefers-reduced-motion){.components-animate__appear{animation:components-animate__appear-animation .1s cubic-bezier(0,0,.2,1) 0s;animation-fill-mode:forwards}}.components-animate__appear.is-from-top,.components-animate__appear.is-from-top.is-from-left{transform-origin:top left}.components-animate__appear.is-from-top.is-from-right{transform-origin:top right}.components-animate__appear.is-from-bottom,.components-animate__appear.is-from-bottom.is-from-left{transform-origin:bottom left}.components-animate__appear.is-from-bottom.is-from-right{transform-origin:bottom right}@keyframes components-animate__appear-animation{0%{transform:translateY(-2em) scaleY(0) scaleX(0)}to{transform:translateY(0) scaleY(1) scaleX(1)}}@media not (prefers-reduced-motion){.components-animate__slide-in{animation:components-animate__slide-in-animation .1s cubic-bezier(0,0,.2,1);animation-fill-mode:forwards}.components-animate__slide-in.is-from-left{transform:translateX(100%)}.components-animate__slide-in.is-from-right{transform:translateX(-100%)}}@keyframes components-animate__slide-in-animation{to{transform:translateX(0)}}@media not (prefers-reduced-motion){.components-animate__loading{animation:components-animate__loading 1.6s ease-in-out infinite}}@keyframes components-animate__loading{0%{opacity:.5}50%{opacity:1}to{opacity:.5}}.components-autocomplete__popover .components-popover__content{min-width:200px;padding:8px}.components-autocomplete__result.components-button{display:flex;height:auto;min-height:36px;text-align:left;width:100%}.components-autocomplete__result.components-button:focus:not(:disabled){box-shadow:inset 0 0 0 1px #fff,0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.components-badge{align-items:center;background-color:color-mix(in srgb,#fff 90%,var(--base-color));border-radius:2px;box-sizing:border-box;color:color-mix(in srgb,#000 50%,var(--base-color));display:inline-flex;font-size:12px;font-weight:400;gap:2px;line-height:20px;max-width:100%;min-height:24px;padding:0 8px}.components-badge *,.components-badge :after,.components-badge :before{box-sizing:inherit}.components-badge:where(.is-default){background-color:#f0f0f0;color:#2f2f2f}.components-badge.has-icon{padding-inline-start:4px}.components-badge.is-info{--base-color:#3858e9}.components-badge.is-warning{--base-color:#f0b849}.components-badge.is-error{--base-color:#cc1818}.components-badge.is-success{--base-color:#4ab866}.components-badge__icon{flex-shrink:0}.components-badge__content{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.components-button-group{display:inline-block}.components-button-group .components-button{border-radius:0;box-shadow:inset 0 0 0 1px #1e1e1e;color:#1e1e1e;display:inline-flex}.components-button-group .components-button+.components-button{margin-left:-1px}.components-button-group .components-button:first-child{border-radius:2px 0 0 2px}.components-button-group .components-button:last-child{border-radius:0 2px 2px 0}.components-button-group .components-button.is-primary,.components-button-group .components-button:focus{position:relative;z-index:1}.components-button-group .components-button.is-primary{box-shadow:inset 0 0 0 1px #1e1e1e}.components-button{align-items:center;-webkit-appearance:none;background:none;border:0;border-radius:2px;box-sizing:border-box;color:var(--wp-components-color-foreground,#1e1e1e);cursor:pointer;display:inline-flex;font-family:inherit;font-size:13px;height:36px;margin:0;padding:6px 12px;text-decoration:none}@media not (prefers-reduced-motion){.components-button{transition:box-shadow .1s linear}}.components-button.is-next-40px-default-size{height:40px}.components-button:hover:not(:disabled,[aria-disabled=true]),.components-button[aria-expanded=true]{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button:focus:not(:disabled){box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:3px solid transparent}.components-button.is-primary{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:var(--wp-components-color-accent-inverted,#fff);outline:1px solid transparent;text-decoration:none;text-shadow:none;white-space:nowrap}.components-button.is-primary:hover:not(:disabled){background:var(--wp-components-color-accent-darker-10,var(--wp-admin-theme-color-darker-10,#2145e6));color:var(--wp-components-color-accent-inverted,#fff)}.components-button.is-primary:active:not(:disabled){background:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6));border-color:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6));color:var(--wp-components-color-accent-inverted,#fff)}.components-button.is-primary:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--wp-components-color-background,#fff),0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button.is-primary:disabled,.components-button.is-primary:disabled:active:enabled,.components-button.is-primary[aria-disabled=true],.components-button.is-primary[aria-disabled=true]:active:enabled,.components-button.is-primary[aria-disabled=true]:enabled{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:hsla(0,0%,100%,.4);outline:none}.components-button.is-primary:disabled:active:enabled:focus:enabled,.components-button.is-primary:disabled:focus:enabled,.components-button.is-primary[aria-disabled=true]:active:enabled:focus:enabled,.components-button.is-primary[aria-disabled=true]:enabled:focus:enabled,.components-button.is-primary[aria-disabled=true]:focus:enabled{box-shadow:inset 0 0 0 1px var(--wp-components-color-background,#fff),0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button.is-primary.is-busy,.components-button.is-primary.is-busy:disabled,.components-button.is-primary.is-busy[aria-disabled=true]{background-image:linear-gradient(-45deg,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 33%,var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6)) 33%,var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6)) 70%,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 70%);background-size:100px 100%;border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:var(--wp-components-color-accent-inverted,#fff)}.components-button.is-secondary,.components-button.is-tertiary{outline:1px solid transparent}.components-button.is-secondary:active:not(:disabled),.components-button.is-tertiary:active:not(:disabled){box-shadow:none}.components-button.is-secondary:disabled,.components-button.is-secondary[aria-disabled=true],.components-button.is-secondary[aria-disabled=true]:hover,.components-button.is-tertiary:disabled,.components-button.is-tertiary[aria-disabled=true],.components-button.is-tertiary[aria-disabled=true]:hover{background:transparent;color:#949494;transform:none}.components-button.is-secondary{background:transparent;box-shadow:inset 0 0 0 1px var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)),0 0 0 currentColor;color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:1px solid transparent;white-space:nowrap}.components-button.is-secondary:hover:not(:disabled,[aria-disabled=true],.is-pressed){background:color-mix(in srgb,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 4%,transparent);box-shadow:inset 0 0 0 1px var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6));color:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6))}.components-button.is-secondary:disabled:not(:focus),.components-button.is-secondary[aria-disabled=true]:hover:not(:focus),.components-button.is-secondary[aria-disabled=true]:not(:focus){box-shadow:inset 0 0 0 1px #ddd}.components-button.is-secondary:focus:not(:disabled){box-shadow:0 0 0 currentColor inset,0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button.is-tertiary{background:transparent;color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));white-space:nowrap}.components-button.is-tertiary:hover:not(:disabled,[aria-disabled=true]){background:color-mix(in srgb,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 4%,transparent);color:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6))}.components-button.is-tertiary:active:not(:disabled,[aria-disabled=true]){background:color-mix(in srgb,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 8%,transparent)}p+.components-button.is-tertiary{margin-left:-6px}.components-button.is-tertiary:disabled:not(:focus),.components-button.is-tertiary[aria-disabled=true]:hover:not(:focus),.components-button.is-tertiary[aria-disabled=true]:not(:focus){box-shadow:none;outline:none}.components-button.is-destructive{--wp-components-color-accent:#cc1818;--wp-components-color-accent-darker-10:#9e1313;--wp-components-color-accent-darker-20:#710d0d}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link){color:#cc1818}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):hover:not(:disabled,[aria-disabled=true]){color:#710d0d}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #cc1818}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):active:not(:disabled,[aria-disabled=true]){background:#ccc}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):disabled,.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link)[aria-disabled=true]{color:#949494}.components-button.is-destructive.is-secondary:hover:not(:disabled,[aria-disabled=true]),.components-button.is-destructive.is-tertiary:hover:not(:disabled,[aria-disabled=true]){background:rgba(204,24,24,.04)}.components-button.is-destructive.is-secondary:active:not(:disabled,[aria-disabled=true]),.components-button.is-destructive.is-tertiary:active:not(:disabled,[aria-disabled=true]){background:rgba(204,24,24,.08)}.components-button.is-link{background:none;border:0;border-radius:0;box-shadow:none;color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));height:auto;margin:0;outline:none;padding:0;text-align:left;text-decoration:underline}@media not (prefers-reduced-motion){.components-button.is-link{transition-duration:.05s;transition-property:border,background,color;transition-timing-function:ease-in-out}}.components-button.is-link:focus{border-radius:2px}.components-button.is-link:disabled,.components-button.is-link[aria-disabled=true]{color:#949494}.components-button:not(:disabled,[aria-disabled=true]):active{color:var(--wp-components-color-foreground,#1e1e1e)}.components-button:disabled,.components-button[aria-disabled=true]{color:#949494;cursor:default}.components-button.is-busy,.components-button.is-secondary.is-busy,.components-button.is-secondary.is-busy:disabled,.components-button.is-secondary.is-busy[aria-disabled=true]{background-image:linear-gradient(-45deg,#fafafa 33%,#e0e0e0 0,#e0e0e0 70%,#fafafa 0);background-size:100px 100%}@media not (prefers-reduced-motion){.components-button.is-busy,.components-button.is-secondary.is-busy,.components-button.is-secondary.is-busy:disabled,.components-button.is-secondary.is-busy[aria-disabled=true]{animation:components-button__busy-animation 2.5s linear infinite}}.components-button.is-compact{height:32px}.components-button.is-compact.has-icon:not(.has-text){min-width:32px;padding:0;width:32px}.components-button.is-small{font-size:11px;height:24px;line-height:22px;padding:0 8px}.components-button.is-small.has-icon:not(.has-text){min-width:24px;padding:0;width:24px}.components-button.has-icon{justify-content:center;min-width:36px;padding:6px}.components-button.has-icon.is-next-40px-default-size{min-width:40px}.components-button.has-icon .dashicon{align-items:center;box-sizing:content-box;display:inline-flex;justify-content:center;padding:2px}.components-button.has-icon.has-text{gap:4px;justify-content:start;padding-left:8px;padding-right:12px}.components-button.is-pressed,.components-button.is-pressed:hover{color:var(--wp-components-color-foreground-inverted,#fff)}.components-button.is-pressed:hover:not(:disabled,[aria-disabled=true]),.components-button.is-pressed:not(:disabled,[aria-disabled=true]){background:var(--wp-components-color-foreground,#1e1e1e)}.components-button.is-pressed:disabled,.components-button.is-pressed[aria-disabled=true]{color:#949494}.components-button.is-pressed:disabled:not(.is-primary):not(.is-secondary):not(.is-tertiary),.components-button.is-pressed[aria-disabled=true]:not(.is-primary):not(.is-secondary):not(.is-tertiary){background:#949494;color:var(--wp-components-color-foreground-inverted,#fff)}.components-button.is-pressed:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--wp-components-color-background,#fff),0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent}.components-button svg{fill:currentColor;outline:none}@media(forced-colors:active){.components-button svg{fill:CanvasText}}.components-button .components-visually-hidden{height:auto}@keyframes components-button__busy-animation{0%{background-position:200px 0}}.components-checkbox-control{--checkbox-input-size:24px;--checkbox-input-margin:8px}@media(min-width:600px){.components-checkbox-control{--checkbox-input-size:16px}}.components-checkbox-control__label{cursor:pointer;line-height:var(--checkbox-input-size)}.components-checkbox-control__input[type=checkbox]{appearance:none;background:#fff;border:1px solid #1e1e1e;border-radius:2px;box-shadow:0 0 0 transparent;clear:none;color:#1e1e1e;cursor:pointer;display:inline-block;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;height:var(--checkbox-input-size);line-height:normal;line-height:0;margin:0 4px 0 0;outline:0;padding:6px 8px;padding:0!important;text-align:center;transition:none;vertical-align:top;width:var(--checkbox-input-size)}@media not (prefers-reduced-motion){.components-checkbox-control__input[type=checkbox]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-checkbox-control__input[type=checkbox]{font-size:13px;line-height:normal}}.components-checkbox-control__input[type=checkbox]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-checkbox-control__input[type=checkbox]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-checkbox-control__input[type=checkbox]:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-checkbox-control__input[type=checkbox]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox]:checked{background:var(--wp-admin-theme-color);border-color:var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox]:checked::-ms-check{opacity:0}.components-checkbox-control__input[type=checkbox]:checked:before,.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{color:#fff;margin:-3px -5px}@media(min-width:782px){.components-checkbox-control__input[type=checkbox]:checked:before,.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{margin:-4px 0 0 -5px}}.components-checkbox-control__input[type=checkbox][aria-checked=mixed]{background:var(--wp-admin-theme-color);border-color:var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{content:"";display:inline-block;float:left;font:normal 30px/1 dashicons;vertical-align:middle;width:16px;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}@media(min-width:782px){.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{float:none;font-size:21px}}.components-checkbox-control__input[type=checkbox]:disabled,.components-checkbox-control__input[type=checkbox][aria-disabled=true]{background:#f0f0f0;border-color:#ddd;cursor:default;opacity:1}@media not (prefers-reduced-motion){.components-checkbox-control__input[type=checkbox]{transition:border-color .1s ease-in-out}}.components-checkbox-control__input[type=checkbox]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 0 calc(var(--wp-admin-border-width-focus)*2) var(--wp-admin-theme-color);outline:2px solid transparent;outline-offset:2px}.components-checkbox-control__input[type=checkbox]:checked,.components-checkbox-control__input[type=checkbox]:indeterminate{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-checkbox-control__input[type=checkbox]:checked::-ms-check,.components-checkbox-control__input[type=checkbox]:indeterminate::-ms-check{opacity:0}.components-checkbox-control__input[type=checkbox]:checked:before{content:none}.components-checkbox-control__input-container{aspect-ratio:1;display:inline-block;flex-shrink:0;line-height:1;margin-right:var(--checkbox-input-margin);position:relative;vertical-align:middle;width:var(--checkbox-input-size)}svg.components-checkbox-control__checked,svg.components-checkbox-control__indeterminate{--checkmark-size:var(--checkbox-input-size);fill:#fff;cursor:pointer;height:var(--checkmark-size);left:50%;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);-webkit-user-select:none;user-select:none;width:var(--checkmark-size)}@media(min-width:600px){svg.components-checkbox-control__checked,svg.components-checkbox-control__indeterminate{--checkmark-size:calc(var(--checkbox-input-size) + 4px)}}.components-checkbox-control__help{display:inline-block;margin-inline-start:calc(var(--checkbox-input-size) + var(--checkbox-input-margin))}.components-circular-option-picker{display:inline-block;min-width:188px;width:100%}.components-circular-option-picker .components-circular-option-picker__custom-clear-wrapper{display:flex;justify-content:flex-end;margin-top:12px}.components-circular-option-picker .components-circular-option-picker__swatches{display:flex;flex-wrap:wrap;gap:12px;position:relative;z-index:1}.components-circular-option-picker>:not(.components-circular-option-picker__swatches){position:relative;z-index:0}.components-circular-option-picker__option-wrapper{display:inline-block;height:28px;transform:scale(1);vertical-align:top;width:28px}@media not (prefers-reduced-motion){.components-circular-option-picker__option-wrapper{transition:transform .1s ease;will-change:transform}}.components-circular-option-picker__option-wrapper:hover{transform:scale(1.2)}.components-circular-option-picker__option-wrapper>div{height:100%;width:100%}.components-circular-option-picker__option-wrapper:before{background:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' fill='none'%3E%3Cpath fill='%23555D65' d='M6 8V6H4v2zm2 0V6h2v2zm2 8H8v-2h2zm2 0v-2h2v2zm0 2v-2h-2v2H8v2h2v-2zm2 0v2h-2v-2zm2 0h-2v-2h2z'/%3E%3Cpath fill='%23555D65' fill-rule='evenodd' d='M18 18h2v-2h-2v-2h2v-2h-2v-2h2V8h-2v2h-2V8h-2v2h2v2h-2v2h2v2h2zm-2-4v-2h2v2z' clip-rule='evenodd'/%3E%3Cpath fill='%23555D65' d='M18 18v2h-2v-2z'/%3E%3Cpath fill='%23555D65' fill-rule='evenodd' d='M8 10V8H6v2H4v2h2v2H4v2h2v2H4v2h2v2H4v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h2V4h-2v2h-2V4h-2v2h-2V4h-2v2h-2V4h-2v2h2v2h-2v2zm0 2v-2H6v2zm2 0v-2h2v2zm0 2v-2H8v2H6v2h2v2H6v2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h-2v2h-2V6h-2v2h-2v2h2v2h-2v2z' clip-rule='evenodd'/%3E%3Cpath fill='%23555D65' fill-rule='evenodd' d='M4 0H2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h2V4h-2V2h2V0h-2v2h-2V0h-2v2h-2V0h-2v2h-2V0h-2v2h-2V0h-2v2H8V0H6v2H4zm0 4V2H2v2zm2 0V2h2v2zm0 2V4H4v2H2v2h2v2H2v2h2v2H2v2h2v2H2v2h2v2H2v2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h2V4h-2V2h-2v2h-2V2h-2v2h-2V2h-2v2h-2V2h-2v2H8v2z' clip-rule='evenodd'/%3E%3C/svg%3E");border-radius:50%;bottom:1px;content:"";left:1px;position:absolute;right:1px;top:1px;z-index:-1}.components-circular-option-picker__option{aspect-ratio:1;background:transparent;border:none;border-radius:50%;box-shadow:inset 0 0 0 14px;cursor:pointer;display:inline-block;height:100%!important;vertical-align:top}@media not (prefers-reduced-motion){.components-circular-option-picker__option{transition:box-shadow .1s ease}}.components-circular-option-picker__option:hover{box-shadow:inset 0 0 0 14px!important}.components-circular-option-picker__option[aria-pressed=true],.components-circular-option-picker__option[aria-selected=true]{box-shadow:inset 0 0 0 4px;overflow:visible;position:relative;z-index:1}.components-circular-option-picker__option[aria-pressed=true]+svg,.components-circular-option-picker__option[aria-selected=true]+svg{border-radius:50%;left:2px;pointer-events:none;position:absolute;top:2px;z-index:2}.components-circular-option-picker__option:after{border:1px solid transparent;border-radius:50%;bottom:-1px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.2);box-sizing:inherit;content:"";left:-1px;position:absolute;right:-1px;top:-1px}.components-circular-option-picker__option:focus:after{border:2px solid #757575;border-radius:50%;box-shadow:inset 0 0 0 2px #fff;content:"";height:calc(100% + 4px);left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:calc(100% + 4px)}.components-circular-option-picker__option.components-button:focus{background-color:transparent;box-shadow:inset 0 0 0 14px;outline:none}.components-circular-option-picker__button-action .components-circular-option-picker__option{background:#fff;color:#fff}.components-circular-option-picker__dropdown-link-action{margin-right:16px}.components-circular-option-picker__dropdown-link-action .components-button{line-height:22px}.components-palette-edit__popover-gradient-picker{padding:8px;width:260px}.components-dropdown-menu__menu .components-palette-edit__menu-button{width:100%}.component-color-indicator{background:#fff linear-gradient(-45deg,transparent 48%,#ddd 0,#ddd 52%,transparent 0);border-radius:50%;box-shadow:inset 0 0 0 1px rgba(0,0,0,.2);display:inline-block;height:20px;padding:0;width:20px}.components-combobox-control{width:100%}input.components-combobox-control__input[type=text]{border:none;box-shadow:none;font-family:inherit;font-size:16px;line-height:inherit;margin:0;min-height:auto;padding:2px;width:100%}@media(min-width:600px){input.components-combobox-control__input[type=text]{font-size:13px}}input.components-combobox-control__input[type=text]:focus{box-shadow:none;outline:none}.components-combobox-control__suggestions-container{align-items:flex-start;border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;display:flex;flex-wrap:wrap;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;line-height:normal;padding:0;width:100%}@media not (prefers-reduced-motion){.components-combobox-control__suggestions-container{transition:box-shadow .1s linear}}@media(min-width:600px){.components-combobox-control__suggestions-container{font-size:13px;line-height:normal}}.components-combobox-control__suggestions-container:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-combobox-control__suggestions-container::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-combobox-control__suggestions-container::-moz-placeholder{color:rgba(30,30,30,.62)}.components-combobox-control__suggestions-container:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-combobox-control__suggestions-container:focus-within{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-combobox-control__suggestions-container .components-spinner{margin:0}.components-color-palette__custom-color-wrapper{position:relative;z-index:0}.components-color-palette__custom-color-button{background:none;border:none;border-radius:4px 4px 0 0;box-shadow:inset 0 0 0 1px rgba(0,0,0,.2);box-sizing:border-box;cursor:pointer;height:64px;outline:1px solid transparent;position:relative;width:100%}.components-color-palette__custom-color-button:focus{box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline-width:2px}.components-color-palette__custom-color-button:after{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,24px 24px;background-size:48px 48px;border-radius:3px 3px 0 0;content:"";inset:1px;position:absolute;z-index:-1}.components-color-palette__custom-color-text-wrapper{border-radius:0 0 4px 4px;box-shadow:inset 0 -1px 0 0 rgba(0,0,0,.2),inset 1px 0 0 0 rgba(0,0,0,.2),inset -1px 0 0 0 rgba(0,0,0,.2);font-size:13px;padding:12px 16px;position:relative}.components-color-palette__custom-color-name{color:var(--wp-components-color-foreground,#1e1e1e);margin:0 1px}.components-color-palette__custom-color-value{color:#757575}.components-color-palette__custom-color-value--is-hex{text-transform:uppercase}.components-color-palette__custom-color-value:empty:after{content:"​";visibility:hidden}.components-custom-gradient-picker__gradient-bar{border-radius:2px;height:48px;position:relative;width:100%;z-index:1}.components-custom-gradient-picker__gradient-bar.has-gradient{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,12px 12px;background-size:24px 24px}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__gradient-bar-background{inset:0;position:absolute}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__markers-container{margin-left:auto;margin-right:auto;position:relative;width:calc(100% - 48px)}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-dropdown{display:flex;height:16px;position:absolute;top:16px;width:16px}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__insert-point-dropdown{background:#fff;border-radius:50%;color:#1e1e1e;height:inherit;min-width:16px!important;padding:2px;position:relative;width:inherit}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__insert-point-dropdown svg{height:100%;width:100%}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-button{border-radius:50%;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 2px 0 rgba(0,0,0,.25);height:inherit;outline:2px solid transparent;padding:0;width:inherit}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-button.is-active,.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-button:focus{box-shadow:inset 0 0 0 calc(var(--wp-admin-border-width-focus)*2) #fff,0 0 2px 0 rgba(0,0,0,.25);outline:1.5px solid transparent}.components-custom-gradient-picker__remove-control-point-wrapper{padding-bottom:8px}.components-custom-gradient-picker__inserter{direction:ltr}.components-custom-gradient-picker__liner-gradient-indicator{display:inline-block;flex:0 auto;height:20px;width:20px}.components-custom-gradient-picker__ui-line{position:relative;z-index:0}.block-editor-dimension-control .components-base-control__field{align-items:center;display:flex}.block-editor-dimension-control .components-base-control__label{align-items:center;display:flex;margin-bottom:0;margin-right:1em}.block-editor-dimension-control .components-base-control__label .dashicon{margin-right:.5em}.block-editor-dimension-control.is-manual .components-base-control__label{width:10em}body.is-dragging-components-draggable{cursor:move;cursor:grabbing!important}.components-draggable__invisible-drag-image{height:50px;left:-1000px;position:fixed;width:50px}.components-draggable__clone{background:transparent;padding:0;pointer-events:none;position:fixed;z-index:1000000000}.components-drop-zone{border-radius:2px;bottom:0;left:0;opacity:0;position:absolute;right:0;top:0;visibility:hidden;z-index:40}.components-drop-zone.is-active{opacity:1;visibility:visible}.components-drop-zone .components-drop-zone__content{align-items:center;background-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));bottom:0;color:#fff;display:flex;height:100%;justify-content:center;left:0;opacity:0;pointer-events:none;position:absolute;right:0;text-align:center;top:0;width:100%;z-index:50}.components-drop-zone .components-drop-zone__content-inner{opacity:0;transform:scale(.9)}.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content{opacity:1}@media not (prefers-reduced-motion){.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content{transition:opacity .2s ease-in-out}}.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content-inner{opacity:1;transform:scale(1)}@media not (prefers-reduced-motion){.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content-inner{transition:opacity .1s ease-in-out .1s,transform .1s ease-in-out .1s}}.components-drop-zone__content-icon,.components-drop-zone__content-text{display:block}.components-drop-zone__content-icon{line-height:0;margin:0 auto 8px;fill:currentColor;pointer-events:none}.components-drop-zone__content-text{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px}.components-dropdown{display:inline-block}.components-dropdown__content .components-popover__content{padding:8px}.components-dropdown__content .components-popover__content:has(.components-menu-group){padding:0}.components-dropdown__content .components-popover__content:has(.components-menu-group) .components-dropdown-menu__menu>.components-menu-item__button,.components-dropdown__content .components-popover__content:has(.components-menu-group)>.components-menu-item__button{margin:8px;width:auto}.components-dropdown__content [role=menuitem]{white-space:nowrap}.components-dropdown__content .components-menu-group{padding:8px}.components-dropdown__content .components-menu-group+.components-menu-group{border-top:1px solid #ccc;padding:8px}.components-dropdown__content.is-alternate .components-menu-group+.components-menu-group{border-color:#1e1e1e}.components-dropdown-menu__toggle{vertical-align:top}.components-dropdown-menu__menu{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;line-height:1.4;width:100%}.components-dropdown-menu__menu .components-dropdown-menu__menu-item,.components-dropdown-menu__menu .components-menu-item{cursor:pointer;outline:none;padding:6px;white-space:nowrap;width:100%}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.has-separator,.components-dropdown-menu__menu .components-menu-item.has-separator{margin-top:6px;overflow:visible;position:relative}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.has-separator:before,.components-dropdown-menu__menu .components-menu-item.has-separator:before{background-color:#ddd;box-sizing:content-box;content:"";display:block;height:1px;left:0;position:absolute;right:0;top:-3px}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.is-active .dashicon,.components-dropdown-menu__menu .components-dropdown-menu__menu-item.is-active svg,.components-dropdown-menu__menu .components-menu-item.is-active .dashicon,.components-dropdown-menu__menu .components-menu-item.is-active svg{background:#1e1e1e;border-radius:1px;box-shadow:0 0 0 1px #1e1e1e;color:#fff}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.is-icon-only,.components-dropdown-menu__menu .components-menu-item.is-icon-only{width:auto}.components-dropdown-menu__menu .components-menu-item__button,.components-dropdown-menu__menu .components-menu-item__button.components-button{height:auto;min-height:40px;padding-left:8px;padding-right:8px;text-align:left}.components-duotone-picker__color-indicator:before{background:transparent}.components-duotone-picker__color-indicator>.components-button,.components-duotone-picker__color-indicator>.components-button.is-pressed:hover:not(:disabled){background:linear-gradient(-45deg,transparent 48%,#ddd 0,#ddd 52%,transparent 0);color:transparent}.components-duotone-picker__color-indicator>.components-button:not([aria-disabled=true]):active{color:transparent}.components-color-list-picker,.components-color-list-picker__swatch-button{width:100%}.components-color-list-picker__color-picker{margin:8px 0}.components-color-list-picker__swatch-color{margin:2px}.components-external-link{text-decoration:none}.components-external-link__contents{text-decoration:underline}.components-external-link__icon{font-weight:400;margin-left:.5ch}.components-form-toggle{display:inline-block;height:16px;position:relative}.components-form-toggle .components-form-toggle__track{background-color:#fff;border:1px solid #949494;border-radius:8px;box-sizing:border-box;content:"";display:inline-block;height:16px;overflow:hidden;position:relative;vertical-align:top;width:32px}@media not (prefers-reduced-motion){.components-form-toggle .components-form-toggle__track{transition:background-color .2s ease,border-color .2s ease}}.components-form-toggle .components-form-toggle__track:after{border-top:16px solid transparent;box-sizing:border-box;content:"";inset:0;opacity:0;position:absolute}@media not (prefers-reduced-motion){.components-form-toggle .components-form-toggle__track:after{transition:opacity .2s ease}}.components-form-toggle .components-form-toggle__thumb{background-color:#1e1e1e;border:6px solid transparent;border-radius:50%;box-shadow:0 1px 1px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.02),0 3px 3px rgba(0,0,0,.02),0 4px 4px rgba(0,0,0,.01);box-sizing:border-box;display:block;height:12px;left:2px;position:absolute;top:2px;width:12px}@media not (prefers-reduced-motion){.components-form-toggle .components-form-toggle__thumb{transition:transform .2s ease,background-color .2s ease-out}}.components-form-toggle.is-checked .components-form-toggle__track{background-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-form-toggle.is-checked .components-form-toggle__track:after{opacity:1}.components-form-toggle .components-form-toggle__input:focus+.components-form-toggle__track{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 0 calc(var(--wp-admin-border-width-focus)*2) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent;outline-offset:2px}.components-form-toggle.is-checked .components-form-toggle__thumb{background-color:#fff;border-width:0;transform:translateX(16px)}.components-disabled .components-form-toggle,.components-form-toggle.is-disabled{opacity:.3}.components-form-toggle input.components-form-toggle__input[type=checkbox]{border:none;height:100%;left:0;margin:0;opacity:0;padding:0;position:absolute;top:0;width:100%;z-index:1}.components-form-toggle input.components-form-toggle__input[type=checkbox]:checked{background:none}.components-form-toggle input.components-form-toggle__input[type=checkbox]:before{content:""}.components-form-toggle input.components-form-toggle__input[type=checkbox]:not(:disabled,[aria-disabled=true]){cursor:pointer}.components-form-token-field__input-container{border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;cursor:text;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;line-height:normal;padding:0;width:100%}@media not (prefers-reduced-motion){.components-form-token-field__input-container{transition:box-shadow .1s linear}}@media(min-width:600px){.components-form-token-field__input-container{font-size:13px;line-height:normal}}.components-form-token-field__input-container:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-form-token-field__input-container::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-form-token-field__input-container::-moz-placeholder{color:rgba(30,30,30,.62)}.components-form-token-field__input-container:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-form-token-field__input-container.is-disabled{background:#ddd;border-color:#ddd}.components-form-token-field__input-container.is-active{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-form-token-field__input-container input[type=text].components-form-token-field__input{background:inherit;border:0;box-shadow:none;color:#1e1e1e;display:inline-block;flex:1;font-family:inherit;font-size:16px;margin-left:4px;max-width:100%;min-height:24px;min-width:50px;padding:0;width:100%}@media(min-width:600px){.components-form-token-field__input-container input[type=text].components-form-token-field__input{font-size:13px}}.components-form-token-field.is-active .components-form-token-field__input-container input[type=text].components-form-token-field__input,.components-form-token-field__input-container input[type=text].components-form-token-field__input:focus{box-shadow:none;outline:none}.components-form-token-field__input-container .components-form-token-field__token+input[type=text].components-form-token-field__input{width:auto}.components-form-token-field__token{color:#1e1e1e;display:flex;font-size:13px;max-width:100%}.components-form-token-field__token.is-success .components-form-token-field__remove-token,.components-form-token-field__token.is-success .components-form-token-field__token-text{background:#4ab866}.components-form-token-field__token.is-error .components-form-token-field__remove-token,.components-form-token-field__token.is-error .components-form-token-field__token-text{background:#cc1818}.components-form-token-field__token.is-validating .components-form-token-field__remove-token,.components-form-token-field__token.is-validating .components-form-token-field__token-text{color:#757575}.components-form-token-field__token.is-borderless{padding:0 24px 0 0;position:relative}.components-form-token-field__token.is-borderless .components-form-token-field__token-text{background:transparent}.components-form-token-field__token.is-borderless:not(.is-disabled) .components-form-token-field__token-text{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-form-token-field__token.is-borderless .components-form-token-field__remove-token{background:transparent;color:#757575;position:absolute;right:0;top:1px}.components-form-token-field__token.is-borderless.is-success .components-form-token-field__token-text{color:#4ab866}.components-form-token-field__token.is-borderless.is-error .components-form-token-field__token-text{color:#cc1818;padding:0 4px 0 6px}.components-form-token-field__token.is-borderless.is-validating .components-form-token-field__token-text{color:#1e1e1e}.components-form-token-field__remove-token.components-button,.components-form-token-field__token-text{background:#ddd;display:inline-block;height:auto;min-width:unset}@media not (prefers-reduced-motion){.components-form-token-field__remove-token.components-button,.components-form-token-field__token-text{transition:all .2s cubic-bezier(.4,1,.4,1)}}.components-form-token-field__token-text{border-radius:1px 0 0 1px;line-height:24px;overflow:hidden;padding:0 0 0 8px;text-overflow:ellipsis;white-space:nowrap}.components-form-token-field__remove-token.components-button{border-radius:0 1px 1px 0;color:#1e1e1e;line-height:10px;overflow:initial}.components-form-token-field__remove-token.components-button:hover:not(:disabled){color:#1e1e1e}.components-form-token-field__suggestions-list{box-shadow:inset 0 1px 0 0 #949494;flex:1 0 100%;list-style:none;margin:0;max-height:128px;min-width:100%;overflow-y:auto;padding:0}@media not (prefers-reduced-motion){.components-form-token-field__suggestions-list{transition:all .15s ease-in-out}}.components-form-token-field__suggestion{box-sizing:border-box;color:#1e1e1e;display:block;font-size:13px;margin:0;min-height:32px;padding:8px 12px}.components-form-token-field__suggestion.is-selected{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:#fff}.components-form-token-field__suggestion[aria-disabled=true]{color:#949494;pointer-events:none}.components-form-token-field__suggestion[aria-disabled=true].is-selected{background-color:rgba(var(--wp-components-color-accent--rgb,var(--wp-admin-theme-color--rgb)),.04)}.components-form-token-field__suggestion:not(.is-empty){cursor:pointer}@media(min-width:600px){.components-guide{width:600px}}.components-guide .components-modal__content{margin-top:0;padding:0}.components-guide .components-modal__content:before{content:none}.components-guide .components-modal__header{border-bottom:none;height:60px;padding:0;position:sticky}.components-guide .components-modal__header .components-button{align-self:flex-start;margin:8px 8px 0 0;position:static}.components-guide .components-modal__header .components-button:hover svg{fill:#fff}.components-guide .components-guide__container{display:flex;flex-direction:column;justify-content:space-between;margin-top:-60px;min-height:100%}.components-guide .components-guide__page{display:flex;flex-direction:column;justify-content:center;position:relative}@media(min-width:600px){.components-guide .components-guide__page{min-height:300px}}.components-guide .components-guide__footer{align-content:center;display:flex;height:36px;justify-content:center;margin:0 0 24px;padding:0 32px;position:relative;width:100%}.components-guide .components-guide__page-control{margin:0;text-align:center}.components-guide .components-guide__page-control li{display:inline-block;margin:0}.components-guide .components-guide__page-control .components-button{color:#e0e0e0;margin:-6px 0}.components-guide .components-guide__page-control li[aria-current=step] .components-button{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-modal__frame.components-guide{border:none;max-height:575px;min-width:312px}@media(max-width:600px){.components-modal__frame.components-guide{margin:auto;max-width:calc(100vw - 32px)}}.components-button.components-guide__back-button,.components-button.components-guide__finish-button,.components-button.components-guide__forward-button{position:absolute}.components-button.components-guide__back-button{left:32px}.components-button.components-guide__finish-button,.components-button.components-guide__forward-button{right:32px}[role=region]{position:relative}[role=region].interface-interface-skeleton__content:focus-visible:after{bottom:0;content:"";left:0;outline-color:var(--wp-admin-theme-color);outline-offset:calc(var(--wp-admin-border-width-focus)*-2/var(--wp-block-editor-iframe-zoom-out-scale, 1));outline-style:solid;outline-width:calc(var(--wp-admin-border-width-focus)*2/var(--wp-block-editor-iframe-zoom-out-scale, 1));pointer-events:none;position:absolute;right:0;top:0;z-index:1000000}.is-focusing-regions [role=region]:focus:after{bottom:0;content:"";left:0;pointer-events:none;position:absolute;right:0;top:0;z-index:1000000}.is-focusing-regions .editor-post-publish-panel,.is-focusing-regions .interface-interface-skeleton__actions .editor-layout__toggle-entities-saved-states-panel,.is-focusing-regions .interface-interface-skeleton__actions .editor-layout__toggle-publish-panel,.is-focusing-regions .interface-interface-skeleton__sidebar .editor-layout__toggle-sidebar-panel,.is-focusing-regions [role=region]:focus:after,.is-focusing-regions.is-distraction-free .interface-interface-skeleton__header .edit-post-header{outline-color:var(--wp-admin-theme-color);outline-offset:calc(var(--wp-admin-border-width-focus)*-2/var(--wp-block-editor-iframe-zoom-out-scale, 1));outline-style:solid;outline-width:calc(var(--wp-admin-border-width-focus)*2/var(--wp-block-editor-iframe-zoom-out-scale, 1))}.components-menu-group+.components-menu-group{border-top:1px solid #1e1e1e;padding-top:8px}.components-menu-group+.components-menu-group.has-hidden-separator{border-top:none;margin-top:0;padding-top:0}.components-menu-group:has(>div:empty){display:none}.components-menu-group__label{color:#757575;font-size:11px;font-weight:500;margin-bottom:12px;margin-top:4px;padding:0 8px;text-transform:uppercase;white-space:nowrap}.components-menu-item__button,.components-menu-item__button.components-button{width:100%}.components-menu-item__button.components-button[role=menuitemcheckbox] .components-menu-item__item:only-child,.components-menu-item__button.components-button[role=menuitemradio] .components-menu-item__item:only-child,.components-menu-item__button[role=menuitemcheckbox] .components-menu-item__item:only-child,.components-menu-item__button[role=menuitemradio] .components-menu-item__item:only-child{box-sizing:initial;padding-right:48px}.components-menu-item__button .components-menu-items__item-icon,.components-menu-item__button.components-button .components-menu-items__item-icon{display:inline-block;flex:0 0 auto}.components-menu-item__button .components-menu-items__item-icon.has-icon-right,.components-menu-item__button.components-button .components-menu-items__item-icon.has-icon-right{margin-left:24px;margin-right:-2px}.components-menu-item__button .components-menu-item__shortcut+.components-menu-items__item-icon.has-icon-right,.components-menu-item__button.components-button .components-menu-item__shortcut+.components-menu-items__item-icon.has-icon-right{margin-left:8px}.components-menu-item__button .block-editor-block-icon,.components-menu-item__button.components-button .block-editor-block-icon{margin-left:-2px;margin-right:8px}.components-menu-item__button.components-button.is-primary,.components-menu-item__button.is-primary{justify-content:center}.components-menu-item__button.components-button.is-primary .components-menu-item__item,.components-menu-item__button.is-primary .components-menu-item__item{margin-right:0}.components-menu-item__button.components-button:disabled.is-tertiary,.components-menu-item__button.components-button[aria-disabled=true].is-tertiary,.components-menu-item__button:disabled.is-tertiary,.components-menu-item__button[aria-disabled=true].is-tertiary{background:none;color:var(--wp-components-color-accent-darker-10,var(--wp-admin-theme-color-darker-10,#2145e6));opacity:.3}.components-menu-item__info-wrapper{display:flex;flex-direction:column;margin-right:auto}.components-menu-item__info{color:#757575;font-size:12px;margin-top:4px;white-space:normal}.components-menu-item__item{align-items:center;display:inline-flex;margin-right:auto;min-width:160px;white-space:nowrap}.components-menu-item__shortcut{align-self:center;color:currentColor;display:none;margin-left:auto;margin-right:0;padding-left:24px}@media(min-width:480px){.components-menu-item__shortcut{display:inline}}.components-menu-items-choice,.components-menu-items-choice.components-button{height:auto;min-height:40px}.components-menu-items-choice svg,.components-menu-items-choice.components-button svg{margin-right:12px}.components-menu-items-choice.components-button.has-icon,.components-menu-items-choice.has-icon{padding-left:12px}.components-modal__screen-overlay{background-color:rgba(0,0,0,.35);bottom:0;display:flex;left:0;position:fixed;right:0;top:0;z-index:100000}@keyframes __wp-base-styles-fade-in{0%{opacity:0}to{opacity:1}}@media not (prefers-reduced-motion){.components-modal__screen-overlay{animation:__wp-base-styles-fade-in .08s linear 0s;animation-fill-mode:forwards}}@keyframes __wp-base-styles-fade-out{0%{opacity:1}to{opacity:0}}@media not (prefers-reduced-motion){.components-modal__screen-overlay.is-animating-out{animation:__wp-base-styles-fade-out .08s linear 80ms;animation-fill-mode:forwards}}.components-modal__frame{animation-fill-mode:forwards;animation-name:components-modal__appear-animation;animation-timing-function:cubic-bezier(.29,0,0,1);background:#fff;border-radius:8px 8px 0 0;box-shadow:0 5px 15px rgba(0,0,0,.08),0 15px 27px rgba(0,0,0,.07),0 30px 36px rgba(0,0,0,.04),0 50px 43px rgba(0,0,0,.02);box-sizing:border-box;display:flex;margin:40px 0 0;overflow:hidden;width:100%}.components-modal__frame *,.components-modal__frame :after,.components-modal__frame :before{box-sizing:inherit}@media not (prefers-reduced-motion){.components-modal__frame{animation-duration:var(--modal-frame-animation-duration)}}.components-modal__screen-overlay.is-animating-out .components-modal__frame{animation-name:components-modal__disappear-animation;animation-timing-function:cubic-bezier(1,0,.2,1)}@media(min-width:600px){.components-modal__frame{border-radius:8px;margin:auto;max-height:calc(100% - 120px);max-width:calc(100% - 32px);min-width:350px;width:auto}}@media(min-width:600px)and (min-width:600px){.components-modal__frame.is-full-screen{height:calc(100% - 32px);max-height:none;width:calc(100% - 32px)}}@media(min-width:600px)and (min-width:782px){.components-modal__frame.is-full-screen{height:calc(100% - 80px);max-width:none;width:calc(100% - 80px)}}@media(min-width:600px){.components-modal__frame.has-size-large,.components-modal__frame.has-size-medium,.components-modal__frame.has-size-small{width:100%}.components-modal__frame.has-size-small{max-width:384px}.components-modal__frame.has-size-medium{max-width:512px}.components-modal__frame.has-size-large{max-width:840px}}@media(min-width:960px){.components-modal__frame{max-height:70%}}@keyframes components-modal__appear-animation{0%{opacity:0;transform:scale(.9)}to{opacity:1;transform:scale(1)}}@keyframes components-modal__disappear-animation{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.9)}}.components-modal__header{align-items:center;border-bottom:1px solid transparent;box-sizing:border-box;display:flex;flex-direction:row;height:72px;justify-content:space-between;left:0;padding:24px 32px 8px;position:absolute;top:0;width:100%;z-index:10}.components-modal__header .components-modal__header-heading{font-size:1.2rem;font-weight:600}.components-modal__header h1{line-height:1;margin:0}.components-modal__content.has-scrolled-content:not(.hide-header) .components-modal__header{border-bottom-color:#ddd}.components-modal__header+p{margin-top:0}.components-modal__header-heading-container{align-items:center;display:flex;flex-direction:row;flex-grow:1;justify-content:left}.components-modal__header-icon-container{display:inline-block}.components-modal__header-icon-container svg{max-height:36px;max-width:36px;padding:8px}.components-modal__content{flex:1;margin-top:72px;overflow:auto;padding:4px 32px 32px}.components-modal__content.hide-header{margin-top:0;padding-top:32px}.components-modal__content.is-scrollable:focus-visible{box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent;outline-offset:-2px}.components-notice{align-items:center;background-color:#fff;border-left:4px solid var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:#1e1e1e;display:flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;padding:8px 12px}.components-notice.is-dismissible{position:relative}.components-notice.is-success{background-color:#eff9f1;border-left-color:#4ab866}.components-notice.is-warning{background-color:#fef8ee;border-left-color:#f0b849}.components-notice.is-error{background-color:#f4a2a2;border-left-color:#cc1818}.components-notice__content{flex-grow:1;margin:4px 25px 4px 0}.components-notice__actions{display:flex;flex-wrap:wrap}.components-notice__action.components-button{margin-right:8px}.components-notice__action.components-button,.components-notice__action.components-button.is-link{margin-left:12px}.components-notice__action.components-button.is-secondary{vertical-align:initial}.components-notice__dismiss{align-self:flex-start;color:#757575;flex-shrink:0}.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):focus,.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):not(.is-secondary):active,.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):not(.is-secondary):hover{background-color:transparent;color:#1e1e1e}.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):not(.is-secondary):hover{box-shadow:none}.components-notice-list{box-sizing:border-box;max-width:100vw}.components-notice-list .components-notice__content{line-height:2;margin-bottom:12px;margin-top:12px}.components-notice-list .components-notice__action.components-button{display:block;margin-left:0;margin-top:8px}.components-panel{background:#fff;border:1px solid #e0e0e0}.components-panel>.components-panel__body:first-child,.components-panel>.components-panel__header:first-child{margin-top:-1px}.components-panel>.components-panel__body:last-child,.components-panel>.components-panel__header:last-child{border-bottom-width:0}.components-panel+.components-panel{margin-top:-1px}.components-panel__body{border-bottom:1px solid #e0e0e0;border-top:1px solid #e0e0e0}.components-panel__body h3{margin:0 0 .5em}.components-panel__body.is-opened{padding:16px}.components-panel__header{align-items:center;border-bottom:1px solid #ddd;box-sizing:content-box;display:flex;flex-shrink:0;height:47px;justify-content:space-between;padding:0 16px}.components-panel__header h2{color:inherit;font-size:inherit;margin:0}.components-panel__body+.components-panel__body,.components-panel__body+.components-panel__header,.components-panel__header+.components-panel__body,.components-panel__header+.components-panel__header{margin-top:-1px}.components-panel__body>.components-panel__body-title{display:block;font-size:inherit;margin-bottom:0;margin-top:0;padding:0}@media not (prefers-reduced-motion){.components-panel__body>.components-panel__body-title{transition:background .1s ease-in-out}}.components-panel__body.is-opened>.components-panel__body-title{margin:-16px -16px 5px}.components-panel__body>.components-panel__body-title:hover{background:#f0f0f0;border:none}.components-panel__body-toggle.components-button{border:none;box-shadow:none;color:#1e1e1e;font-weight:500;height:auto;outline:none;padding:16px 48px 16px 16px;position:relative;text-align:left;width:100%}@media not (prefers-reduced-motion){.components-panel__body-toggle.components-button{transition:background .1s ease-in-out}}.components-panel__body-toggle.components-button:focus{border-radius:0;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-panel__body-toggle.components-button .components-panel__arrow{color:#1e1e1e;position:absolute;right:16px;top:50%;transform:translateY(-50%);fill:currentColor}@media not (prefers-reduced-motion){.components-panel__body-toggle.components-button .components-panel__arrow{transition:color .1s ease-in-out}}body.rtl .components-panel__body-toggle.components-button .dashicons-arrow-right{-ms-filter:fliph;filter:FlipH;margin-top:-10px;transform:scaleX(-1)}.components-panel__icon{color:#757575;margin:-2px 0 -2px 6px}.components-panel__body-toggle-icon{margin-right:-5px}.components-panel__color-title{float:left;height:19px}.components-panel__row{align-items:center;display:flex;justify-content:space-between;margin-top:8px;min-height:36px}.components-panel__row select{min-width:0}.components-panel__row label{flex-shrink:0;margin-right:12px;max-width:75%}.components-panel__row:empty,.components-panel__row:first-of-type{margin-top:0}.components-panel .circle-picker{padding-bottom:20px}.components-placeholder.components-placeholder{align-items:flex-start;box-sizing:border-box;color:#1e1e1e;display:flex;flex-direction:column;font-size:13px;gap:16px;margin:0;padding:24px;position:relative;text-align:left;width:100%;-moz-font-smoothing:subpixel-antialiased;-webkit-font-smoothing:subpixel-antialiased;background-color:#fff;border-radius:2px;box-shadow:inset 0 0 0 1px #1e1e1e;outline:1px solid transparent}.components-placeholder__error,.components-placeholder__fieldset,.components-placeholder__instructions,.components-placeholder__label{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;font-weight:400;letter-spacing:normal;line-height:normal;text-transform:none}.components-placeholder__label{align-items:center;display:flex;font-weight:600}.components-placeholder__label .block-editor-block-icon,.components-placeholder__label .dashicon,.components-placeholder__label>svg{margin-right:4px;fill:currentColor}@media(forced-colors:active){.components-placeholder__label .block-editor-block-icon,.components-placeholder__label .dashicon,.components-placeholder__label>svg{fill:CanvasText}}.components-placeholder__label:empty{display:none}.components-placeholder__fieldset,.components-placeholder__fieldset form{display:flex;flex-direction:row;flex-wrap:wrap;gap:16px;justify-content:flex-start;width:100%}.components-placeholder__fieldset form p,.components-placeholder__fieldset p{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px}.components-placeholder__fieldset.is-column-layout,.components-placeholder__fieldset.is-column-layout form{flex-direction:column}.components-placeholder__input[type=url]{border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;flex:1 1 auto;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;line-height:normal;padding:6px 8px}@media not (prefers-reduced-motion){.components-placeholder__input[type=url]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-placeholder__input[type=url]{font-size:13px;line-height:normal}}.components-placeholder__input[type=url]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-placeholder__input[type=url]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-placeholder__input[type=url]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-placeholder__input[type=url]:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-placeholder__error{gap:8px;width:100%}.components-placeholder__fieldset .components-button:not(.is-link)~.components-button.is-link{margin-left:10px;margin-right:10px}.components-placeholder__fieldset .components-button:not(.is-link)~.components-button.is-link:last-child{margin-right:0}.components-placeholder.is-medium .components-placeholder__instructions,.components-placeholder.is-small .components-placeholder__instructions{display:none}.components-placeholder.is-medium .components-placeholder__fieldset,.components-placeholder.is-medium .components-placeholder__fieldset form,.components-placeholder.is-small .components-placeholder__fieldset,.components-placeholder.is-small .components-placeholder__fieldset form{flex-direction:column}.components-placeholder.is-medium .components-button,.components-placeholder.is-medium .components-placeholder__fieldset>*,.components-placeholder.is-small .components-button,.components-placeholder.is-small .components-placeholder__fieldset>*{justify-content:center;width:100%}.components-placeholder.is-small{padding:16px}.components-placeholder.has-illustration{-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);backface-visibility:hidden;background-color:transparent;border-radius:0;box-shadow:none;color:inherit;display:flex;overflow:hidden}.is-dark-theme .components-placeholder.has-illustration{background-color:rgba(0,0,0,.1)}.components-placeholder.has-illustration .components-placeholder__fieldset{margin-left:0;margin-right:0}.components-placeholder.has-illustration .components-button,.components-placeholder.has-illustration .components-placeholder__instructions,.components-placeholder.has-illustration .components-placeholder__label{opacity:0;pointer-events:none}@media not (prefers-reduced-motion){.components-placeholder.has-illustration .components-button,.components-placeholder.has-illustration .components-placeholder__instructions,.components-placeholder.has-illustration .components-placeholder__label{transition:opacity .1s linear}}.is-selected>.components-placeholder.has-illustration .components-button,.is-selected>.components-placeholder.has-illustration .components-placeholder__instructions,.is-selected>.components-placeholder.has-illustration .components-placeholder__label{opacity:1;pointer-events:auto}.components-placeholder.has-illustration:before{background:currentColor;bottom:0;content:"";left:0;opacity:.1;pointer-events:none;position:absolute;right:0;top:0}.is-selected .components-placeholder.has-illustration{overflow:auto}.components-placeholder__preview{display:flex;justify-content:center}.components-placeholder__illustration{box-sizing:content-box;height:100%;left:50%;position:absolute;top:50%;transform:translate(-50%,-50%);width:100%;stroke:currentColor;opacity:.25}.components-popover{box-sizing:border-box;will-change:transform;z-index:1000000}.components-popover *,.components-popover :after,.components-popover :before{box-sizing:inherit}.components-popover.is-expanded{bottom:0;left:0;position:fixed;right:0;top:0;z-index:1000000!important}.components-popover__content{background:#fff;border-radius:4px;box-shadow:0 0 0 1px #ccc,0 2px 3px rgba(0,0,0,.05),0 4px 5px rgba(0,0,0,.04),0 12px 12px rgba(0,0,0,.03),0 16px 16px rgba(0,0,0,.02);box-sizing:border-box;width:min-content}.is-alternate .components-popover__content{border-radius:2px;box-shadow:0 0 0 1px #1e1e1e}.is-unstyled .components-popover__content{background:none;border-radius:0;box-shadow:none}.components-popover.is-expanded .components-popover__content{box-shadow:0 -1px 0 0 #ccc;height:calc(100% - 48px);overflow-y:visible;position:static;width:auto}.components-popover.is-expanded.is-alternate .components-popover__content{box-shadow:0 -1px 0 #1e1e1e}.components-popover__header{align-items:center;background:#fff;display:flex;height:48px;justify-content:space-between;padding:0 8px 0 16px}.components-popover__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:100%}.components-popover__close.components-button{z-index:5}.components-popover__arrow{display:flex;height:14px;pointer-events:none;position:absolute;width:14px}.components-popover__arrow:before{background-color:#fff;content:"";height:2px;left:1px;position:absolute;right:1px;top:-1px}.components-popover__arrow.is-top{bottom:-14px!important;transform:rotate(0)}.components-popover__arrow.is-right{left:-14px!important;transform:rotate(90deg)}.components-popover__arrow.is-bottom{top:-14px!important;transform:rotate(180deg)}.components-popover__arrow.is-left{right:-14px!important;transform:rotate(-90deg)}.components-popover__triangle{display:block;flex:1}.components-popover__triangle-bg{fill:#fff}.components-popover__triangle-border{fill:transparent;stroke-width:1px;stroke:#ccc}.is-alternate .components-popover__triangle-border{stroke:#1e1e1e}.components-radio-control{border:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;margin:0;padding:0}.components-radio-control__group-wrapper.has-help{margin-block-end:12px}.components-radio-control__option{align-items:center;column-gap:8px;display:grid;grid-template-columns:auto 1fr;grid-template-rows:auto minmax(0,max-content)}.components-radio-control__input[type=radio]{appearance:none;border:1px solid #1e1e1e;border-radius:2px;border-radius:50%;box-shadow:0 0 0 transparent;cursor:pointer;display:inline-flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;grid-column:1;grid-row:1;height:24px;line-height:normal;margin:0;max-width:24px;min-width:24px;padding:0;position:relative;transition:none;width:24px}@media not (prefers-reduced-motion){.components-radio-control__input[type=radio]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-radio-control__input[type=radio]{font-size:13px;line-height:normal}}.components-radio-control__input[type=radio]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color)}.components-radio-control__input[type=radio]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-radio-control__input[type=radio]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-radio-control__input[type=radio]:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width:600px){.components-radio-control__input[type=radio]{height:16px;max-width:16px;min-width:16px;width:16px}}.components-radio-control__input[type=radio]:checked:before{background-color:#fff;border:4px solid #fff;box-sizing:inherit;height:12px;left:50%;margin:0;position:absolute;top:50%;transform:translate(-50%,-50%);width:12px}@media(min-width:600px){.components-radio-control__input[type=radio]:checked:before{height:8px;width:8px}}.components-radio-control__input[type=radio]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px var(--wp-admin-theme-color)}.components-radio-control__input[type=radio]:checked{background:var(--wp-admin-theme-color);border:none}.components-radio-control__input[type=radio]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 0 calc(var(--wp-admin-border-width-focus)*2) var(--wp-admin-theme-color);outline:2px solid transparent;outline-offset:2px}.components-radio-control__input[type=radio]:checked{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-radio-control__input[type=radio]:checked:before{border-radius:50%;content:""}.components-radio-control__label{cursor:pointer;grid-column:2;grid-row:1;line-height:24px}@media(min-width:600px){.components-radio-control__label{line-height:16px}}.components-radio-control__option-description{grid-column:2;grid-row:2;padding-block-start:4px}.components-radio-control__option-description.components-radio-control__option-description{margin-top:0}.components-resizable-box__handle{display:none;height:23px;width:23px;z-index:2}.components-resizable-box__container.has-show-handle .components-resizable-box__handle{display:block}.components-resizable-box__handle>div{height:100%;outline:none;position:relative;width:100%;z-index:2}.components-resizable-box__container>img{width:inherit}.components-resizable-box__handle:after{background:#fff;border-radius:50%;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)),0 1px 1px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.02),0 3px 3px rgba(0,0,0,.02),0 4px 4px rgba(0,0,0,.01);content:"";cursor:inherit;display:block;height:15px;outline:2px solid transparent;position:absolute;right:calc(50% - 8px);top:calc(50% - 8px);width:15px}.components-resizable-box__side-handle:before{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-radius:9999px;content:"";cursor:inherit;display:block;height:3px;opacity:0;position:absolute;right:calc(50% - 1px);top:calc(50% - 1px);width:3px}@media not (prefers-reduced-motion){.components-resizable-box__side-handle:before{transition:transform .1s ease-in;will-change:transform}}.components-resizable-box__corner-handle,.components-resizable-box__side-handle{z-index:2}.components-resizable-box__side-handle.components-resizable-box__handle-bottom,.components-resizable-box__side-handle.components-resizable-box__handle-bottom:before,.components-resizable-box__side-handle.components-resizable-box__handle-top,.components-resizable-box__side-handle.components-resizable-box__handle-top:before{border-left:0;border-right:0;left:0;width:100%}.components-resizable-box__side-handle.components-resizable-box__handle-left,.components-resizable-box__side-handle.components-resizable-box__handle-left:before,.components-resizable-box__side-handle.components-resizable-box__handle-right,.components-resizable-box__side-handle.components-resizable-box__handle-right:before{border-bottom:0;border-top:0;height:100%;top:0}@media not (prefers-reduced-motion){.components-resizable-box__side-handle.components-resizable-box__handle-bottom:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-bottom:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:hover:before{animation:components-resizable-box__top-bottom-animation .1s ease-out 0s;animation-fill-mode:forwards}.components-resizable-box__side-handle.components-resizable-box__handle-left:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-left:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:hover:before{animation:components-resizable-box__left-right-animation .1s ease-out 0s;animation-fill-mode:forwards}}@media not all and (min-resolution:0.001dpcm){@supports(-webkit-appearance:none){.components-resizable-box__side-handle.components-resizable-box__handle-bottom:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-bottom:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-left:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-left:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:hover:before{animation:none}}}@keyframes components-resizable-box__top-bottom-animation{0%{opacity:0;transform:scaleX(0)}to{opacity:1;transform:scaleX(1)}}@keyframes components-resizable-box__left-right-animation{0%{opacity:0;transform:scaleY(0)}to{opacity:1;transform:scaleY(1)}}/*!rtl:begin:ignore*/.components-resizable-box__handle-right{right:-11.5px}.components-resizable-box__handle-left{left:-11.5px}.components-resizable-box__handle-top{top:-11.5px}.components-resizable-box__handle-bottom{bottom:-11.5px}/*!rtl:end:ignore*/.components-responsive-wrapper{align-items:center;display:flex;justify-content:center;max-width:100%;position:relative}.components-responsive-wrapper__content{display:block;max-width:100%;width:100%}.components-sandbox{overflow:hidden}iframe.components-sandbox{width:100%}body.lockscroll,html.lockscroll{overflow:hidden}.components-select-control__input{outline:0;-webkit-tap-highlight-color:rgba(0,0,0,0)!important}@media(max-width:782px){.components-base-control .components-base-control__field .components-select-control__input{font-size:16px}}.components-snackbar{-webkit-backdrop-filter:blur(16px) saturate(180%);backdrop-filter:blur(16px) saturate(180%);background:rgba(0,0,0,.85);border-radius:4px;box-shadow:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);box-sizing:border-box;color:#fff;cursor:pointer;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;max-width:600px;padding:12px 20px;pointer-events:auto;width:100%}@media(min-width:600px){.components-snackbar{width:fit-content}}.components-snackbar:focus{box-shadow:inset 0 0 0 1px #fff,0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-snackbar.components-snackbar-explicit-dismiss{cursor:default}.components-snackbar .components-snackbar__content-with-icon{padding-left:24px;position:relative}.components-snackbar .components-snackbar__icon{left:-8px;position:absolute;top:-2.9px}.components-snackbar .components-snackbar__dismiss-button{cursor:pointer;margin-left:24px}.components-snackbar__action.components-button{color:#fff;flex-shrink:0;margin-left:32px}.components-snackbar__action.components-button:focus{box-shadow:none;outline:1px dotted #fff}.components-snackbar__action.components-button:hover{color:currentColor;text-decoration:none}.components-snackbar__content{align-items:baseline;display:flex;justify-content:space-between;line-height:1.4}.components-snackbar-list{box-sizing:border-box;pointer-events:none;position:absolute;width:100%;z-index:100000}.components-snackbar-list__notice-container{padding-top:8px;position:relative}.components-tab-panel__tabs{align-items:stretch;display:flex;flex-direction:row}.components-tab-panel__tabs[aria-orientation=vertical]{flex-direction:column}.components-tab-panel__tabs-item{background:transparent;border:none;border-radius:0;box-shadow:none;cursor:pointer;font-weight:500;height:48px!important;margin-left:0;padding:3px 16px;position:relative}.components-tab-panel__tabs-item:focus:not(:disabled){box-shadow:none;outline:none;position:relative}.components-tab-panel__tabs-item:after{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-radius:0;bottom:0;content:"";height:calc(var(--wp-admin-border-width-focus)*0);left:0;pointer-events:none;position:absolute;right:0}@media not (prefers-reduced-motion){.components-tab-panel__tabs-item:after{transition:all .1s linear}}.components-tab-panel__tabs-item.is-active:after{height:calc(var(--wp-admin-border-width-focus)*1);outline:2px solid transparent;outline-offset:-1px}.components-tab-panel__tabs-item:before{border-radius:2px;bottom:12px;box-shadow:0 0 0 0 transparent;content:"";left:12px;pointer-events:none;position:absolute;right:12px;top:12px}@media not (prefers-reduced-motion){.components-tab-panel__tabs-item:before{transition:all .1s linear}}.components-tab-panel__tabs-item:focus-visible:before{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent}.components-tab-panel__tab-content:focus{box-shadow:none;outline:none}.components-tab-panel__tab-content:focus-visible{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent;outline-offset:0}.components-text-control__input,.components-text-control__input[type=color],.components-text-control__input[type=date],.components-text-control__input[type=datetime-local],.components-text-control__input[type=datetime],.components-text-control__input[type=email],.components-text-control__input[type=month],.components-text-control__input[type=number],.components-text-control__input[type=password],.components-text-control__input[type=tel],.components-text-control__input[type=text],.components-text-control__input[type=time],.components-text-control__input[type=url],.components-text-control__input[type=week]{border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;height:32px;line-height:normal;margin:0;padding:6px 8px;width:100%}@media not (prefers-reduced-motion){.components-text-control__input,.components-text-control__input[type=color],.components-text-control__input[type=date],.components-text-control__input[type=datetime-local],.components-text-control__input[type=datetime],.components-text-control__input[type=email],.components-text-control__input[type=month],.components-text-control__input[type=number],.components-text-control__input[type=password],.components-text-control__input[type=tel],.components-text-control__input[type=text],.components-text-control__input[type=time],.components-text-control__input[type=url],.components-text-control__input[type=week]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-text-control__input,.components-text-control__input[type=color],.components-text-control__input[type=date],.components-text-control__input[type=datetime-local],.components-text-control__input[type=datetime],.components-text-control__input[type=email],.components-text-control__input[type=month],.components-text-control__input[type=number],.components-text-control__input[type=password],.components-text-control__input[type=tel],.components-text-control__input[type=text],.components-text-control__input[type=time],.components-text-control__input[type=url],.components-text-control__input[type=week]{font-size:13px;line-height:normal}}.components-text-control__input:focus,.components-text-control__input[type=color]:focus,.components-text-control__input[type=date]:focus,.components-text-control__input[type=datetime-local]:focus,.components-text-control__input[type=datetime]:focus,.components-text-control__input[type=email]:focus,.components-text-control__input[type=month]:focus,.components-text-control__input[type=number]:focus,.components-text-control__input[type=password]:focus,.components-text-control__input[type=tel]:focus,.components-text-control__input[type=text]:focus,.components-text-control__input[type=time]:focus,.components-text-control__input[type=url]:focus,.components-text-control__input[type=week]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-text-control__input::-webkit-input-placeholder,.components-text-control__input[type=color]::-webkit-input-placeholder,.components-text-control__input[type=date]::-webkit-input-placeholder,.components-text-control__input[type=datetime-local]::-webkit-input-placeholder,.components-text-control__input[type=datetime]::-webkit-input-placeholder,.components-text-control__input[type=email]::-webkit-input-placeholder,.components-text-control__input[type=month]::-webkit-input-placeholder,.components-text-control__input[type=number]::-webkit-input-placeholder,.components-text-control__input[type=password]::-webkit-input-placeholder,.components-text-control__input[type=tel]::-webkit-input-placeholder,.components-text-control__input[type=text]::-webkit-input-placeholder,.components-text-control__input[type=time]::-webkit-input-placeholder,.components-text-control__input[type=url]::-webkit-input-placeholder,.components-text-control__input[type=week]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-text-control__input::-moz-placeholder,.components-text-control__input[type=color]::-moz-placeholder,.components-text-control__input[type=date]::-moz-placeholder,.components-text-control__input[type=datetime-local]::-moz-placeholder,.components-text-control__input[type=datetime]::-moz-placeholder,.components-text-control__input[type=email]::-moz-placeholder,.components-text-control__input[type=month]::-moz-placeholder,.components-text-control__input[type=number]::-moz-placeholder,.components-text-control__input[type=password]::-moz-placeholder,.components-text-control__input[type=tel]::-moz-placeholder,.components-text-control__input[type=text]::-moz-placeholder,.components-text-control__input[type=time]::-moz-placeholder,.components-text-control__input[type=url]::-moz-placeholder,.components-text-control__input[type=week]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-text-control__input:-ms-input-placeholder,.components-text-control__input[type=color]:-ms-input-placeholder,.components-text-control__input[type=date]:-ms-input-placeholder,.components-text-control__input[type=datetime-local]:-ms-input-placeholder,.components-text-control__input[type=datetime]:-ms-input-placeholder,.components-text-control__input[type=email]:-ms-input-placeholder,.components-text-control__input[type=month]:-ms-input-placeholder,.components-text-control__input[type=number]:-ms-input-placeholder,.components-text-control__input[type=password]:-ms-input-placeholder,.components-text-control__input[type=tel]:-ms-input-placeholder,.components-text-control__input[type=text]:-ms-input-placeholder,.components-text-control__input[type=time]:-ms-input-placeholder,.components-text-control__input[type=url]:-ms-input-placeholder,.components-text-control__input[type=week]:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-text-control__input.is-next-40px-default-size,.components-text-control__input[type=color].is-next-40px-default-size,.components-text-control__input[type=date].is-next-40px-default-size,.components-text-control__input[type=datetime-local].is-next-40px-default-size,.components-text-control__input[type=datetime].is-next-40px-default-size,.components-text-control__input[type=email].is-next-40px-default-size,.components-text-control__input[type=month].is-next-40px-default-size,.components-text-control__input[type=number].is-next-40px-default-size,.components-text-control__input[type=password].is-next-40px-default-size,.components-text-control__input[type=tel].is-next-40px-default-size,.components-text-control__input[type=text].is-next-40px-default-size,.components-text-control__input[type=time].is-next-40px-default-size,.components-text-control__input[type=url].is-next-40px-default-size,.components-text-control__input[type=week].is-next-40px-default-size{height:40px;padding-left:12px;padding-right:12px}.components-text-control__input[type=email],.components-text-control__input[type=url]{direction:ltr}.components-tip{color:#757575;display:flex}.components-tip svg{align-self:center;fill:#f0b849;flex-shrink:0;margin-right:16px}.components-tip p{margin:0}.components-toggle-control__label{line-height:16px}.components-toggle-control__label:not(.is-disabled){cursor:pointer}.components-toggle-control__help{display:inline-block;margin-inline-start:40px}.components-accessible-toolbar{border:1px solid #1e1e1e;border-radius:2px;display:inline-flex;flex-shrink:0}.components-accessible-toolbar>.components-toolbar-group:last-child{border-right:none}.components-accessible-toolbar.is-unstyled{border:none}.components-accessible-toolbar.is-unstyled>.components-toolbar-group{border-right:none}.components-accessible-toolbar[aria-orientation=vertical],.components-toolbar[aria-orientation=vertical]{align-items:center;display:flex;flex-direction:column}.components-accessible-toolbar .components-button,.components-toolbar .components-button{height:48px;padding-left:16px;padding-right:16px;position:relative;z-index:1}.components-accessible-toolbar .components-button:focus:not(:disabled),.components-toolbar .components-button:focus:not(:disabled){box-shadow:none;outline:none}.components-accessible-toolbar .components-button:before,.components-toolbar .components-button:before{border-radius:2px;content:"";display:block;height:32px;left:8px;position:absolute;right:8px;z-index:-1}@media not (prefers-reduced-motion){.components-accessible-toolbar .components-button:before,.components-toolbar .components-button:before{animation:components-button__appear-animation .1s ease;animation-fill-mode:forwards}}.components-accessible-toolbar .components-button svg,.components-toolbar .components-button svg{margin-left:auto;margin-right:auto;position:relative}.components-accessible-toolbar .components-button.is-pressed,.components-accessible-toolbar .components-button.is-pressed:hover,.components-toolbar .components-button.is-pressed,.components-toolbar .components-button.is-pressed:hover{background:transparent}.components-accessible-toolbar .components-button.is-pressed:before,.components-toolbar .components-button.is-pressed:before{background:#1e1e1e}.components-accessible-toolbar .components-button:focus:before,.components-toolbar .components-button:focus:before{box-shadow:inset 0 0 0 1px #fff,0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.components-accessible-toolbar .components-button.has-icon.has-icon,.components-toolbar .components-button.has-icon.has-icon{min-width:48px;padding-left:8px;padding-right:8px}@keyframes components-button__appear-animation{0%{transform:scaleY(0)}to{transform:scaleY(1)}}.components-toolbar__control.components-button{position:relative}.components-toolbar__control.components-button[data-subscript] svg{padding:5px 10px 5px 0}.components-toolbar__control.components-button[data-subscript]:after{bottom:10px;content:attr(data-subscript);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;font-weight:600;line-height:12px;position:absolute;right:8px}.components-toolbar__control.components-button:not(:disabled).is-pressed[data-subscript]:after{color:#fff}.components-toolbar-group{background-color:#fff;border-right:1px solid #1e1e1e;display:inline-flex;flex-shrink:0;flex-wrap:wrap;line-height:0;min-height:48px;padding-left:6px;padding-right:6px}.components-toolbar-group .components-toolbar-group.components-toolbar-group{border-width:0;margin:0}.components-toolbar-group .components-button.components-button,.components-toolbar-group .components-button.has-icon.has-icon{justify-content:center;min-width:36px;padding-left:6px;padding-right:6px}.components-toolbar-group .components-button.components-button svg,.components-toolbar-group .components-button.has-icon.has-icon svg{min-width:24px}.components-toolbar-group .components-button.components-button:before,.components-toolbar-group .components-button.has-icon.has-icon:before{left:2px;right:2px}.components-toolbar{background-color:#fff;border:1px solid #1e1e1e;display:inline-flex;flex-shrink:0;flex-wrap:wrap;margin:0;min-height:48px}.components-toolbar .components-toolbar.components-toolbar{border-width:0;margin:0}div.components-toolbar>div{display:flex;margin:0}div.components-toolbar>div+div.has-left-divider{margin-left:6px;overflow:visible;position:relative}div.components-toolbar>div+div.has-left-divider:before{background-color:#ddd;box-sizing:content-box;content:"";display:inline-block;height:20px;left:-3px;position:absolute;top:8px;width:1px}.components-tooltip{background:#000;border-radius:2px;box-shadow:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);color:#f0f0f0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:12px;line-height:1.4;padding:4px 8px;text-align:center;z-index:1000002}.components-tooltip__shortcut{margin-left:8px}:root{--tag-color:#daffdc}div.dataviews-wrapper div.dataviews-filters__container{padding-left:24px}div.dataviews-wrapper svg.table-view-icon{height:52px;width:52px}div.dataviews-wrapper button[aria-controls=dataviews-view-config-dropdown-0]{display:none}div.dataviews-wrapper div.dataviews__view-actions{align-items:center;justify-content:flex-start;padding-left:24px;padding-right:24px}div.dataviews-wrapper button.components-button.is-secondary{font-weight:400;padding:calc(var(--spacing-base)/2) var(--spacing-base)}div.dataviews-wrapper div.components-base-control__field{margin-bottom:0}div.dataviews-wrapper div.components-toggle-group-control{min-height:32px;padding:0}div.dataviews-wrapper div.dataviews-title-field{font-size:var(--font-title-small)}div.dataviews-wrapper span.dataviews-view-list__field-value{font-size:var(--font-body-small)}div.dataviews-wrapper div.dataviews-view-list div[role=row]{border:none}div.dataviews-wrapper div.dataviews-view-list div[role=row] .dataviews-view-list__fields{flex-wrap:nowrap;justify-content:space-between;margin-right:30px}@media(min-width:783px){div.dataviews-wrapper div.dataviews-view-list div[role=row] .dataviews-view-list__fields{flex-wrap:wrap;margin-right:0}}div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected).is-hovered,div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected):hover{background-color:transparent}div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected).is-hovered .dataviews-view-list__fields,div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected):hover .dataviews-view-list__fields{color:#757575}@media(min-width:783px){div.dataviews-wrapper button.dataviews-view-list__item{display:none}}div.dataviews-filters__search-widget-listitem span,span.dataviews-filters__summary-filter-text-value{text-transform:capitalize}div.dataviews-filters__search-widget-listitem:hover,div.dataviews-filters__search-widget-listitem[data-active-item]{background-color:var(--tag-color);color:var(--jp-gray-70)}div.dataviews-filters__search-widget-listitem:hover span.dataviews-filters__search-widget-listitem-check{fill:var(--jp-gray-70)}div.dataviews-filters__summary-chip-container button.dataviews-filters__summary-chip-remove.has-values:hover,div.dataviews-filters__summary-chip-container div.dataviews-filters__summary-chip.has-values:hover,div.dataviews-filters__summary-chip-container div.dataviews-filters__summary-chip.has-values[aria-expanded=true]{background-color:var(--tag-color)}button.product-list-item-chevron{align-items:center;background:transparent;border:none;cursor:pointer;display:flex;justify-content:center;outline-color:var(--jp-green-40);padding:0;position:absolute;right:30px;top:calc(50% - 12px)}.Jvb1njqMy7ML1zikhbWn{margin-top:1rem}.mpr8_ygU8woV4bVR1xvw{align-items:center;display:flex;font-size:var(--font-title-small);font-weight:500;line-height:1.5;margin-bottom:.5rem;margin-top:0}.gwO_Q0L0jbwMARVlBezu{color:var(--jp-gray-60);font-family:SF Pro Text,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:var(--font-body-small);font-weight:400;letter-spacing:-.15px;line-height:20px;margin-left:.75rem}.qwy7CsLeEbXvaPwgC9WV{display:flex;flex-flow:row nowrap;max-width:100%;overflow-x:scroll;padding:1px;scrollbar-width:none}.qwy7CsLeEbXvaPwgC9WV::-webkit-scrollbar{display:none}.qwy7CsLeEbXvaPwgC9WV .Hrbg7DeSJs6gas9zdPDR{border-color:var(--jp-gray-5);border-radius:5px;margin-bottom:0;margin-right:1.5rem;min-width:180px;padding:1rem 1.5rem;width:100%}@media only screen and (min-width:960px){.qwy7CsLeEbXvaPwgC9WV .Hrbg7DeSJs6gas9zdPDR{min-width:220px}}.qwy7CsLeEbXvaPwgC9WV .Hrbg7DeSJs6gas9zdPDR:last-child{margin-right:0}.NFpbo5AINn6I6avKFGby{margin-bottom:1.5rem}.aoQZCG0JeyWmy2J6vVxF{font-weight:500;line-height:20px;margin-bottom:.25rem}.M6ApyXg79vuXo6GwDkbO{align-items:flex-end;display:flex;flex-wrap:wrap;font-size:36px;font-weight:400;line-height:40px}.M6ApyXg79vuXo6GwDkbO.DYHb5e6QhgXejWyo9s78{cursor:pointer}.OlInbY5YnDO06MEQHv98{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;line-height:1;margin-right:.5rem}.EtbKbd5m85w7oYT4stIs{color:var(--jp-gray-20);display:none;font-size:var(--font-body-small);font-weight:600;line-height:24px;fill:var(--jp-gray-20)}@media screen and (min-width:960px){.EtbKbd5m85w7oYT4stIs{align-items:center;display:flex}}.EtbKbd5m85w7oYT4stIs.Awr7zl75sfAsFPHK9kDG{color:var(--jp-red-50);fill:var(--jp-red-50)}.EtbKbd5m85w7oYT4stIs.QFSZbIKFdWO3HEPBZyhc{color:var(--jp-green-50);fill:var(--jp-green-50)}.GgJAnS4gaEEGmRCP5n8y{align-content:flex-end;display:flex}.mjiNtwdbKpfo9edGVes4{margin-right:2px}.pAt4v_KG9Ir19wNcEtEj{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin-top:calc(var(--spacing-base)*2.5);min-height:28px;width:100%}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off);padding-top:1px}.jrGNTKcgeXk9HKzolut9{position:relative}.jrGNTKcgeXk9HKzolut9>.wg3mZsoPekZWlBgOvdZ6{overflow:hidden;padding:0}.jrGNTKcgeXk9HKzolut9>.wg3mZsoPekZWlBgOvdZ6.aDxB89WgtARQqNWd4ZeK:before{background-color:var(--jp-red-50);border:2px solid var(--jp-white-off);border-radius:50%;content:"";height:18px;left:-11px;position:absolute;top:-11px;width:18px}.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR{background-color:var(--jp-white);border-radius:50%;box-shadow:0 0 5px 1px rgba(0,0,0,.1);padding:8px;position:absolute;right:16px;top:16px;transform:scale(.75)}.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR:focus,.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR:hover{background-color:var(--jp-white)}.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR:disabled{pointer-events:none}.z5EQSkU36nsjxHEBSfNN{padding:0}.MwBwVaEj6u_zRgfrFR9b{padding:24px 16px}@media screen and (min-width:600){.MwBwVaEj6u_zRgfrFR9b{padding:32px 24px}}@media screen and (min-width:960px){.MwBwVaEj6u_zRgfrFR9b{padding:48px 12px 48px 48px}}.UgPNtuFW7lTJ06k39EsK{background-image:url(images/evaluation-blank-fbbfbcd75b50ade0f092.png),radial-gradient(circle at 40% 70%,rgba(206,217,242,.75) 0,hsla(0,0%,100%,0) 40%),radial-gradient(circle at 80% 80%,rgba(6,158,8,.15) 5%,hsla(0,0%,100%,0) 50%),radial-gradient(circle at 80% 20%,hsla(46,77%,83%,.75) 0,hsla(0,0%,100%,0) 50%);background-position:75%;background-repeat:no-repeat;background-size:393px,cover,cover,cover}.UgPNtuFW7lTJ06k39EsK.ilVOud0_OCGK4HciazB_{background-image:url(images/evaluation-selected-196d1790b76830f9b73a.png),radial-gradient(circle at 40% 70%,rgba(206,217,242,.75) 0,hsla(0,0%,100%,0) 40%),radial-gradient(circle at 80% 80%,rgba(6,158,8,.15) 5%,hsla(0,0%,100%,0) 50%),radial-gradient(circle at 80% 20%,hsla(46,77%,83%,.75) 0,hsla(0,0%,100%,0) 50%)}.EtcggGK0Bk8POQD986Og{background-image:url(images/site-cards-29522f090d5422fd7afd.png),radial-gradient(circle at 90% 30%,rgba(6,158,8,.15) 0,hsla(0,0%,100%,0) 35%),radial-gradient(circle at 75% 65%,rgba(206,217,242,.5) 5%,hsla(0,0%,100%,0) 15%),radial-gradient(circle at 90% 90%,hsla(46,77%,83%,.5) 0,hsla(0,0%,100%,0) 25%);background-repeat:no-repeat;background-size:cover}@media screen and (max-width:960px){.EtcggGK0Bk8POQD986Og{background-image:url(images/site-cards-29522f090d5422fd7afd.png),radial-gradient(circle at 55% 30%,rgba(6,158,8,.15) 0,hsla(0,0%,100%,0) 100%),radial-gradient(circle at 25% 40%,rgba(206,217,242,.5) 5%,hsla(0,0%,100%,0) 50%),radial-gradient(circle at 50% 85%,hsla(46,77%,83%,.3) 0,hsla(0,0%,100%,0) 35%);min-height:160px;order:-1}}.TSiu5sC6MdANROjUkUJM{margin-top:24px}.iqJfpZM9IYXuFSXvuoEe{font-size:16px!important;margin-top:16px}.Vozbq8Inlk5SxoVnn2G5{column-gap:40px;display:flex;flex-direction:row;margin-top:64px}.s_V1BM1Wtt3He4eF2TCu{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3);text-decoration:none!important}.FMZ2bZdjMxKFePbMwRi3{align-items:center;background-image:radial-gradient(circle at 80% 80%,rgba(6,158,8,.15) 5%,hsla(0,0%,100%,0) 50%);background-position:100% 80%;background-repeat:no-repeat;background-size:cover;display:flex;flex-direction:column;justify-content:center;padding:144px 32px}.eShkT8UhgFL0N__pJEA8{display:flex;justify-content:center;margin-bottom:24px}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF{color:var(--jp-green-40);height:88px;transform:scale(1.3);transition:transform .3s ease-out;width:88px}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .Ktcwz9OsGT_3yNKZq6BA,.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .WQpz4j3rH6uEqAXwDrR8,.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .jkWzdt8A2twwREkaF2qX,.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .lZq4cdGYKYAgiVEYCtXw{opacity:0}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .jkWzdt8A2twwREkaF2qX{stroke-dasharray:276;stroke-dashoffset:276;animation:w9IUcbm9vJHQeg2OXhtF 2s ease-out forwards}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .lZq4cdGYKYAgiVEYCtXw{animation:xAohbjzRzlC5o13repbp .5s ease-in-out 1.5s forwards}.eShkT8UhgFL0N__pJEA8.iOKKzf48kelOFS8vRBwR .GZ2uVyfGabA_66Y8nmuF{animation:OrGIdZzrmFu39hFSKNfg 1s ease-out .3s forwards;transform:scale(1.4)}.eShkT8UhgFL0N__pJEA8.iOKKzf48kelOFS8vRBwR .GZ2uVyfGabA_66Y8nmuF .Ktcwz9OsGT_3yNKZq6BA,.eShkT8UhgFL0N__pJEA8.iOKKzf48kelOFS8vRBwR .GZ2uVyfGabA_66Y8nmuF .WQpz4j3rH6uEqAXwDrR8{animation:xAohbjzRzlC5o13repbp .85s ease-out .3s forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .GZ2uVyfGabA_66Y8nmuF{animation:none;transform:scale(1.4)}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .GZ2uVyfGabA_66Y8nmuF .Ktcwz9OsGT_3yNKZq6BA,.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .GZ2uVyfGabA_66Y8nmuF .WQpz4j3rH6uEqAXwDrR8{opacity:1}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z{position:absolute;top:0;transform:translateX(10px)}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g{opacity:0;transform:translateY(-200px)}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:first-child{--duration:0.6s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(2){--duration:0.8s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(3){--duration:1s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(4){--duration:0.7s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(5){--duration:0.9s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(6){--duration:1.1s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(7){--duration:0.75s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(8){--duration:1.1s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}@keyframes w9IUcbm9vJHQeg2OXhtF{0%{opacity:1;stroke-dashoffset:276}to{opacity:1;stroke-dashoffset:0}}@keyframes xAohbjzRzlC5o13repbp{to{opacity:1}}@keyframes OrGIdZzrmFu39hFSKNfg{25%{transform:scale(1.25)}to{transform:scale(1.4)}}@keyframes _brJ7gDgGneDqAzmDSZG{0%{transform:translateY(-300px)}to{transform:translateY(0)}}.jErCC9oKHSM15BxzFyQK{margin-bottom:0}.oVoYbwbFB6U2o90Njusk>div{background-color:var(--jp-white);font-size:16px;line-height:24px;margin:0;position:relative}.oVoYbwbFB6U2o90Njusk>div .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}@media screen and (min-width:960px){.oVoYbwbFB6U2o90Njusk>div .components-notice__content{gap:6rem}}.oVoYbwbFB6U2o90Njusk>div .is-link{color:var(--jp-black);font-size:16px;font-weight:600;padding:var(--spacing-base) calc(var(--spacing-base)*3)!important;white-space:nowrap}.oVoYbwbFB6U2o90Njusk>div .components-notice__dismiss{align-self:center}.oVoYbwbFB6U2o90Njusk>div .components-notice__action{align-items:center;background:#000;border-radius:var(--jp-border-radius);color:var(--jp-white);cursor:pointer;font-size:16px;font-weight:600;height:auto;justify-content:center;letter-spacing:-.01em;line-height:24px;margin-left:0;margin-top:24px;padding:8px 24px;text-decoration:none}@media screen and (min-width:960px){.oVoYbwbFB6U2o90Njusk>div .components-notice__action{margin-left:calc(var(--spacing-base)*2 + 24px)}}.oVoYbwbFB6U2o90Njusk>div.Snc8NEmDelsbhlH4285s .components-notice__action{margin-left:0;margin-top:0;white-space:nowrap}.oVoYbwbFB6U2o90Njusk>div.Snc8NEmDelsbhlH4285s .components-notice__content{align-items:center;flex-direction:row}@media screen and (max-width:600px){.oVoYbwbFB6U2o90Njusk>div{padding-top:24px}.oVoYbwbFB6U2o90Njusk>div>div:has(svg){position:static}}.oVoYbwbFB6U2o90Njusk .R5tvcsARTGN0A_z3DygA{min-width:auto}.wBVXH4OTNwLHPRpN4nsq{display:flex;flex-grow:1;margin-right:var(--spacing-base)}.wBVXH4OTNwLHPRpN4nsq a{color:var(--jp-black)}.wBVXH4OTNwLHPRpN4nsq a:focus,.wBVXH4OTNwLHPRpN4nsq a:hover{text-decoration:underline;text-decoration-thickness:2px}.wBVXH4OTNwLHPRpN4nsq .terms-of-service{color:var(--jp-gray-70);font-size:var(--font-body-small)}.wBVXH4OTNwLHPRpN4nsq>svg{fill:var(--jp-red-60);align-self:flex-start;flex-shrink:0;margin-right:calc(var(--spacing-base)*2)}.wBVXH4OTNwLHPRpN4nsq>svg.F1qvEnFfHs5nz3zFZUOV{fill:none}.wBVXH4OTNwLHPRpN4nsq .products-list{margin:10px 0}.wBVXH4OTNwLHPRpN4nsq .products-list .product-badge{background-color:#f1f1f1;border-radius:6px;display:inline-block;margin:4px 8px 4px 0;padding:2px 8px}.wBVXH4OTNwLHPRpN4nsq .plugins-list .plugin-item>span{font-size:calc(var(--font-body-extra-small) + 1px);margin-inline-start:5px}.SrQxAOBa5ZaSKP8wlut9{border-bottom:none;margin:0}.TcCZnGE6mad8Dvz9pCZi{background:url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgZmlsbD0ibm9uZSI+PHBhdGggc3Ryb2tlPSIjRDYzNjM5IiBzdHJva2Utd2lkdGg9IjEuNSIgZD0iTTEyIDIwYTggOCAwIDEgMCAwLTE2IDggOCAwIDAgMCAwIDE2WiIvPjxwYXRoIGZpbGw9IiNENjM2MzkiIGQ9Ik0xMyA3aC0ydjZoMnpNMTMgMTVoLTJ2MmgyeiIvPjwvc3ZnPg==) no-repeat 0 0;color:var(--jp-red);line-height:25px;padding-left:25px}._mn6o2Dtm5pfFWc8_A1K{--spacing-base:8px;min-width:264px}.VHYulMcpzbr10HWR0iSE{align-items:flex-start;border:1px solid var(--jp-black);border-color:var(--jp-gray-5);border-left-width:6px;border-radius:4px;display:flex;font-size:var(--font-body);padding:24px 31px 27px 18px}.FGpSkMCiIHQjszcV0dbn{height:calc(var(--spacing-base)*3);margin-right:20px;width:calc(var(--spacing-base)*3)}.KoWZcCwhW13xvkEb0QON{background-color:transparent;border:none;cursor:pointer;outline:none;padding:0}.KoWZcCwhW13xvkEb0QON svg{display:block}@media screen and (max-width:600px){.VHYulMcpzbr10HWR0iSE{box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);padding-top:68px;position:relative}.FGpSkMCiIHQjszcV0dbn{left:24px;position:absolute;top:24px}.KoWZcCwhW13xvkEb0QON{position:absolute;right:24px;top:24px}}.smrfczkC53EaFM8OJUXs{flex-grow:1}.IKYRWoPwt9xOVEx1wzNS{font-weight:600;margin-bottom:8px}.qM0qY6mPYp1MPN54A3Kg{align-items:center;display:flex;flex-wrap:wrap;margin-top:20px;row-gap:20px}@media screen and (max-width:600px){.qM0qY6mPYp1MPN54A3Kg{justify-content:center}}.qM0qY6mPYp1MPN54A3Kg a,.qM0qY6mPYp1MPN54A3Kg a:active,.qM0qY6mPYp1MPN54A3Kg a:focus,.qM0qY6mPYp1MPN54A3Kg a:hover{color:var(--jp-black)}.qM0qY6mPYp1MPN54A3Kg>*{margin-right:24px}.A5YkDkkXuiYgavrY6Nux{border-left-color:var(--jp-red)}.A5YkDkkXuiYgavrY6Nux .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-red)}.cT5rwuPMZzWvi5o6shMl{border-left-color:var(--jp-yellow-20)}.cT5rwuPMZzWvi5o6shMl .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-yellow-20)}.yo0O3uvNomPsYUXFCpAS{border-left-color:var(--black)}.yo0O3uvNomPsYUXFCpAS .y_IPyP1wIAOhyNaqvXJq{fill:var(--black)}.oZdDFf1jBLkzn5ICCC6x{border-left-color:var(--jp-green)}.oZdDFf1jBLkzn5ICCC6x .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-green)}.jT9Kt2ZTvxPKDQ1pa7sN.components-snackbar-list{inset-block-end:0;inset-block-start:auto;inset-inline:0;position:fixed;z-index:100001}@media(min-width:600px){.jT9Kt2ZTvxPKDQ1pa7sN.components-snackbar-list{inset-block-start:4rem;inset-inline:unset;inset-inline-end:1rem;width:auto}}@media(min-width:782px){.jT9Kt2ZTvxPKDQ1pa7sN.components-snackbar-list{inset-block-start:3rem}}.cAbGtJDGgLubucBnz7vM{background-color:var(--jp-white)}.XsCIqtbkjCGvQuTEqP12{display:flex;flex-direction:column;gap:16px;max-width:450px;width:100%}.FuIWMXR9G82lNoOWSg7Z{font-size:32px;font-weight:500;line-height:40px}.VqV6BERV7qt2YRiC8ant{color:var(--jp-gray-100,#101517);font-size:16px;font-weight:400;line-height:24px;margin-bottom:29px}.H7h4wR1WKIziIFiwJpzN{align-items:center;align-self:stretch;background:transparent;border:1px solid #ccc;border-radius:var(--jp-button-radius);box-shadow:none;display:flex;justify-content:center;margin-bottom:0;padding:14px 16px;width:100%}.H7h4wR1WKIziIFiwJpzN:hover{cursor:pointer}.pSJyHDRGl_R9CF7J_wzX{color:var(--jp-gray-80,#2c3338);font-size:15px;font-style:normal;font-weight:500;line-height:20px;margin-left:-20px;text-align:center;width:100%}.TnFm4M8CVuTak6Vq2NsE{align-items:center;display:flex;margin:20px 0;text-transform:uppercase;width:100%}.TnFm4M8CVuTak6Vq2NsE span{color:var(--jp-gray-60,#50575e);margin:0 16px;white-space:nowrap}.TnFm4M8CVuTak6Vq2NsE .eKWjmNNdlY3uWjVgR8RI{background:rgba(0,0,0,.1);flex:1;height:1px}.Scnx4BQ8P2bIZ0YxBThk{display:flex;flex-direction:column;gap:16px}.Scnx4BQ8P2bIZ0YxBThk .Ps4m_56jJQ5YgQb25OW0{border:1px solid var(--jp-gray-60,#949494);border-radius:var(--jp-button-radius);box-sizing:border-box;color:var(--jp-gray-50,#646970);font-size:15px;line-height:20px;margin:0;padding:12px 16px;width:100%}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI{background:var(--jp-green-60,#007117);border:1px solid var(--jp-green-60,#007117);border-radius:var(--jp-button-radius);box-sizing:border-box;color:var(--jp-white,#fff);font-size:16px;font-weight:500;line-height:24px;padding:12px 16px;width:100%}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:focus,.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:hover{background:var(--jp-green-70,#00801a);cursor:pointer}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:focus{border-color:var(--jp-white,#fff);outline:2px solid var(--jp-green-60,#007117)}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:disabled{background:var(--jp-gray,#dcdcde);border-color:var(--jp-gray,#dcdcde);color:var(--jp-gray-50,#646970);cursor:unset}.IySisqLBT5FBSpx8ksyG{color:var(--jp-gray-50,#646970);font-size:13px;line-height:20px;margin-top:8px}.IySisqLBT5FBSpx8ksyG .terms-of-service__link{color:var(--jp-gray-50,#646970);text-decoration:underline}body{font-family:SF Pro Text,-apple-system,BlinkMacSystemFont,Avenir Next,Avenir,Segoe UI,Helvetica Neue,Helvetica,Cantarell,Ubuntu,Roboto,Noto Sans,Arial,sans-serif}#wpwrap{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility}.hs8vtMKdbmvStRLqOShe{position:absolute}.a2dTOxFWByKrVw1RIDQT{--max-container-width:100%;background-color:var(--jp-white,#fff);height:100vh;overflow-y:hidden;width:100%}.q0k48EMOblqQLxSxIKZa{overflow:hidden}.w9obJdf7GdvAmyMTJp12{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center}@media screen and (max-width:600px){.w9obJdf7GdvAmyMTJp12{justify-content:flex-start;padding-top:72px}}.Jqm3k3aZ4rGDtBCVeocD{border-radius:12px;max-height:100%}.Jqm3k3aZ4rGDtBCVeocD img{display:block;object-fit:cover;width:100%}@media screen and (max-width:600px){.PhMWEQDEAfUHteBMf1hM{display:none}}.q0T8YyQxRawhpDtvJjxI{background-color:var(--jp-white);height:100%;padding:calc(var(--spacing-base)*8);position:relative}.B7JDqI_vtKxSy5GjvqA1{display:flex;flex-direction:column;height:100%}.zj7xadmhIWeuf7ZwvVTS{align-items:center;background:var(--jp-black);border-radius:var(--jp-border-radius) var(--jp-border-radius) 0 0;color:var(--jp-white);display:flex;height:calc(var(--spacing-base)*4);left:0;padding:0 var(--spacing-base);position:absolute;top:0;width:100%}.GsioW6IsC8EMYE3U6788{fill:var(--jp-white);margin-right:var(--spacing-base)}.cfEO8udWbRGPFJzW8Jg5,.dbz07JqxOlivjKO4vBEF{align-items:center;display:flex;height:calc(var(--spacing-base)*4);margin-bottom:calc(var(--spacing-base)*4)}.zlh3zbjUe4Z8cBs7uVVe{fill:#8c8f94;height:24px;line-height:24px}.qoZuzG5EcDa231hC6t0P{align-items:center;display:flex;justify-content:center}.qoZuzG5EcDa231hC6t0P svg{margin-right:var(--spacing-base)}.Q6uUUQCPWS6_6nLxIn68{display:inline-block;min-height:42px;padding:.5em 2em;text-align:center;width:100%}.Q6uUUQCPWS6_6nLxIn68 .YU4iBCRze09ZP3iCsdcb{margin:0}.Q6uUUQCPWS6_6nLxIn68.components-button.is-primary{height:auto;white-space:normal}.Q6uUUQCPWS6_6nLxIn68.is-secondary:hover:not(:disabled){background-color:var(--jp-black);color:var(--jp-white)}.OrQG7DjDd9Ha2Xj1Mx3L{margin-top:calc(var(--spacing-base)*2)}.Q1jaYDpa2AVfJpA29wT0{flex-grow:1;margin:0;margin-bottom:calc(var(--spacing-base)*2);padding:0}.Q1jaYDpa2AVfJpA29wT0 li{align-items:flex-start;display:flex;list-style:none;margin-bottom:var(--spacing-base)}.Q1jaYDpa2AVfJpA29wT0 svg{fill:var(--jp-green-primary);flex-shrink:0;margin-right:var(--spacing-base)}.HL4gSxsF0skYGhGuqH90 li:last-of-type{font-weight:700}.sEcLfpWjo0GF7QrxD3Lt{margin-top:calc(var(--spacing-base)*2)}.xgv3jRkeF39aEQELCwru{align-items:flex-end;color:var(--jp-black);display:flex;flex-wrap:wrap;gap:calc(var(--spacing-base)*2)}.twlleZ5Ehq4bB7CvKVSW{position:relative}.twlleZ5Ehq4bB7CvKVSW.Qg4rPEvXsqmod1s_31d8{color:var(--jp-gray-20)}.twlleZ5Ehq4bB7CvKVSW.Qg4rPEvXsqmod1s_31d8:after{background:var(--jp-red);border-radius:var(--jp-border-radius);content:" ";display:block;height:3px;margin-top:-2px;pointer-events:none;position:absolute;top:50%;width:100%}.ApsgxIornVy_3KnciVeJ{color:var(--jp-gray-40);margin-bottom:calc(var(--spacing-base)*3)}.NMxcZL17aEP7v81uG3zD{margin-top:calc(var(--spacing-base)*5)}.gCTKfAPzJqZas7CaRbKN{margin-bottom:calc(var(--spacing-base)*4)}.demNsMJjhi7BLY7xhjU5{align-items:center;display:flex;font-size:var(--font-body);line-height:calc(var(--spacing-base)*3);margin:calc(var(--spacing-base)*2) 0;min-height:calc(var(--spacing-base)*3)}.QiUjdjJSkqh6nH7YMG5A{align-self:flex-start;height:calc(var(--spacing-base)*3);margin-right:calc(var(--spacing-base)/2);width:calc(var(--spacing-base)*3)}.Q080AHcq29J2fc68Hhk5{color:var(--jp-red)}.Q080AHcq29J2fc68Hhk5 .hYWbIwhppukXmGnsiT9H{fill:var(--jp-red)}.JjHuxWly0HI9C60gorbq{color:var(--jp-yellow-40)}.JjHuxWly0HI9C60gorbq .hYWbIwhppukXmGnsiT9H{fill:var(--jp-yellow-40)}.Cm8ZFHi3mngl4cj9Gatx{color:var(--jp-blue-40)}.Cm8ZFHi3mngl4cj9Gatx .hYWbIwhppukXmGnsiT9H{fill:var(--jp-blue-40)}.ytGBsU015p3LGwOPwFDx{color:var(--jp-green)}.ytGBsU015p3LGwOPwFDx .hYWbIwhppukXmGnsiT9H{fill:var(--jp-green)}.iSc4n8zVaElbs0TPAWH5{align-items:center;display:flex;gap:20px;height:700px;justify-content:center;margin-top:2rem}:root{--font-title-large:36px;--font-title-small:24px;--font-body:16px;--font-label:12px;--jp-black:#000;--jp-black-80:#2c3338;--jp-white:#fff;--jp-white-off:#f9f9f6;--jp-gray:#dcdcde;--jp-gray-0:#f6f7f7;--jp-gray-5:#dcdcde;--jp-gray-10:#c3c4c7;--jp-gray-20:#a7aaad;--jp-gray-30:#8c8f94;--jp-gray-40:#787c82;--jp-gray-50:#646970;--jp-gray-60:#50575e;--jp-gray-70:#3c434a;--jp-gray-80:#2c3338;--jp-gray-90:#1d2327;--jp-gray-100:#101517;--jp-gray-off:#e2e2df;--jp-yellow-5:#f5e6b3;--jp-yellow-10:#f2cf75;--jp-yellow-40:#c08c00;--jp-orange-20:#faa754;--jp-blue-5:#ced9f2;--jp-red-0:#f7ebec;--jp-red-50:#d63638;--jp-red-60:#b32d2e;--jp-red-80:#8a2424;--jp-red:#d63639;--jp-pink:#c9356e;--jp-green-0:#f0f2eb;--jp-green-5:#d0e6b8;--jp-green-10:#9dd977;--jp-green-20:#64ca43;--jp-green-30:#2fb41f;--jp-green-40:#069e08;--jp-green-50:#008710;--jp-green-60:#007117;--jp-green-70:#005b18;--jp-green-80:#004515;--jp-green-90:#003010;--jp-green-100:#001c09;--jp-green:#069e08;--jp-green-primary:var(--jp-green-40);--jp-green-secondary:var(--jp-green-30);--jp-border-radius:4px;--jp-border-radius-rna:8px;--jp-menu-border-height:1px;--jp-underline-thickness:2px;--jp-modal-padding-large:32px;--jp-modal-padding:24px;--jp-modal-padding-small:16px;--jp-modal-radius:8px;--jp-button-padding:8px;--jp-button-radius:4px;--jp-gap:16px;--jp-highlight:#3858e9}:where(body){font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0;min-height:100%;padding:0}.jp-wrap{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.jp-row{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.jp-row{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.jp-row{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.sm-col-span-1{grid-column-end:span 1}.sm-col-span-2{grid-column-end:span 2}.sm-col-span-3{grid-column-end:span 3}.sm-col-span-4{grid-column-end:span 4}@media(min-width:600px){.md-col-span-1{grid-column-end:span 1}.md-col-span-2{grid-column-end:span 2}.md-col-span-3{grid-column-end:span 3}.md-col-span-4{grid-column-end:span 4}.md-col-span-5{grid-column-end:span 5}.md-col-span-6{grid-column-end:span 6}.md-col-span-7{grid-column-end:span 7}.md-col-span-8{grid-column-end:span 8}}@media(min-width:960px){.lg-col-span-1{grid-column-end:span 1}.lg-col-span-2{grid-column-end:span 2}.lg-col-span-3{grid-column-end:span 3}.lg-col-span-4{grid-column-end:span 4}.lg-col-span-5{grid-column-end:span 5}.lg-col-span-6{grid-column-end:span 6}.lg-col-span-7{grid-column-end:span 7}.lg-col-span-8{grid-column-end:span 8}.lg-col-span-9{grid-column-end:span 9}.lg-col-span-10{grid-column-end:span 10}.lg-col-span-11{grid-column-end:span 11}.lg-col-span-12{grid-column-end:span 12}}@media(max-width:960px){.md-col-span-0{display:none}}@media(max-width:600px){.sm-col-span-0{display:none}}.jp-cut{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);margin:32px 0;padding:16px 64px 16px 24px;position:relative;text-decoration:none}.jp-cut,.jp-cut span{display:block}.jp-cut span:last-of-type{font-weight:600}.jp-cut:focus span:last-of-type,.jp-cut:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.jp-cut:focus:after,.jp-cut:hover:after{transform:translateY(-50%) translateX(8px)}.jp-cut:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;position:absolute;right:24px;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.components-popover:not(.is-without-arrow):before{border-color:var(--jp-gray)}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=left] .components-popover__content{margin-right:-62px}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=right] .components-popover__content{margin-left:-62px}.icon-tooltip-helper .components-popover[data-y-axis=bottom] .components-popover__content{top:2px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:before{top:-6px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:after{top:-4px!important}.icon-tooltip-helper .components-popover[data-y-axis=top] .components-popover__content{bottom:10px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:before{bottom:3px}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:after{bottom:4px}.icon-tooltip-helper.is-wide .components-popover__content{width:440px}.icon-tooltip-wrapper{color:var(--jp-black);display:inline-block;position:relative}.icon-tooltip-wrapper .components-button.is-link:focus:not(:disabled){box-shadow:none}.icon-tooltip-helper{height:18px;left:-53px;pointer-events:none;position:absolute;top:0;width:124px}.icon-tooltip-container{pointer-events:all}.icon-tooltip-container .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;margin:0 10px;max-width:90vw;outline:none;padding:24px;white-space:normal;width:304px}.icon-tooltip-title{font-size:16px;font-weight:600;line-height:19px}.icon-tooltip-title:not(:last-child){margin-bottom:8px}.icon-tooltip-content{font-size:14px;font-weight:400;line-height:24px}.icon-tooltip-content ul{list-style-type:disc;margin:0 0 0 1rem}.icon-tooltip-content ul li:last-child{margin-bottom:0}.p4qz2tkq0p9hxucJ6Qk2{--padding:calc(var(--spacing-base)*4);color:var(--jp-black)}.lbNDyXioOwvyvbALtCBm{--gap:calc(var(--spacing-base)*3);padding:var(--padding) 0;position:relative}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm{column-gap:var(--gap);display:grid;grid-auto-flow:column;grid-template-columns:repeat(var(--columns),1fr);grid-template-rows:repeat(var(--rows),minmax(min-content,max-content))}.cLaNK_XcbTGlRQ4Tp43Q{margin-top:var(--padding)}.s2Lsn4kbm6BrS3DSndRB .cLaNK_XcbTGlRQ4Tp43Q{display:contents}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>*{background:var(--jp-white);position:relative}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>:after{bottom:0;box-shadow:0 4px 24px rgba(0,0,0,.05);content:"";left:0;position:absolute;right:0;top:0;z-index:-1}.cLaNK_XcbTGlRQ4Tp43Q>:first-child{border-top-left-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius);border-width:1px 1px 0}.cLaNK_XcbTGlRQ4Tp43Q>:last-child{border-bottom-left-radius:var(--jp-border-radius);border-bottom-right-radius:var(--jp-border-radius);border-width:0 1px 1px}.DAkZc1P9A3K12fjEliMg{display:flex;flex-direction:column;justify-content:space-between;padding:var(--padding)}.WUBuYABl8nymjs9NnCEL{align-items:center;display:flex;padding-bottom:calc(var(--spacing-base)*2);position:relative}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)){padding-top:calc(var(--spacing-base)*2)}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{background-color:var(--jp-gray);content:"";height:1px;left:var(--padding);position:absolute;right:var(--padding);top:0;z-index:5}.s2Lsn4kbm6BrS3DSndRB .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{left:0;right:unset;width:calc(100% + var(--gap))}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm>:last-child .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{width:100%}.ANtCFeb41NhA8PA3H7ZN,.WUBuYABl8nymjs9NnCEL:last-of-type{padding-bottom:var(--padding)}.Ql2gy_148yW8Vw5vhaKD{padding-left:var(--padding);padding-right:var(--padding)}.EAQrAnQEW1z1BfdY5gbC{margin:0 var(--spacing-base);fill:var(--jp-gray);flex-shrink:0}.EAQrAnQEW1z1BfdY5gbC.JDSTlLoOC_4aUoH2oNM2{fill:var(--jp-green-40)}.EAQrAnQEW1z1BfdY5gbC.zNdQRJ1w7BvaQOYyqzHK{fill:var(--jp-red-50)}.lr7vbX95SKtoe7DarJcZ{margin-left:auto}.s2Lsn4kbm6BrS3DSndRB .lr7vbX95SKtoe7DarJcZ{margin:0 var(--spacing-base);top:1px}.WUBuYABl8nymjs9NnCEL .KRrGp2xdkeBOxLZeuQ6X{fill:var(--jp-gray-20);flex-shrink:0}.H_ZJiRVJg0LiMXPGOcmt{text-align:center;width:fit-content}.H_ZJiRVJg0LiMXPGOcmt>a{color:#000}.s2Lsn4kbm6BrS3DSndRB .H_ZJiRVJg0LiMXPGOcmt{grid-column:2;overflow:hidden;padding-left:var(--padding);padding-right:var(--padding);white-space:nowrap}.x21z_DixObRDsDaWotP1{align-items:right;display:flex;justify-content:right;margin:0 calc(var(--spacing-base)*4)}.dovianZYLKhnbnh9I06o{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-end}.lljtQMhW7lq5tE5SDJEf{align-items:flex-start;display:flex;flex-basis:0;flex-grow:2}.lljtQMhW7lq5tE5SDJEf .NubApIV1vQCRUNprfm6b{margin-left:auto}.dhFQXpZfMwVI8vuYHnwC{align-items:flex-start;display:inline-flex;flex:0 0 auto;position:relative}.dhFQXpZfMwVI8vuYHnwC:first-child{margin-right:calc(var(--spacing-base)*2)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k{color:var(--jp-gray-20)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k:after{background:var(--jp-red);border-radius:var(--jp-border-radius);content:" ";display:block;height:3px;margin-top:-2px;pointer-events:none;position:absolute;top:50%;width:100%}.C64ZjjUAqJC1T2Sa7apS{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-start;margin-bottom:calc(var(--spacing-base)*3)}.UpZDGew6Ay1hPoP6eI7b{color:var(--jp-gray-40);font-size:var(--font-body-small);line-height:20px}.UpZDGew6Ay1hPoP6eI7b:after{content:"​"}.NubApIV1vQCRUNprfm6b{background-color:var(--jp-yellow-10);border-radius:4px;font-size:13px;font-weight:600;margin-left:var(--spacing-base);padding-left:var(--spacing-base);padding-right:var(--spacing-base)}.TDiiPbuW1Z0_05u_pvcK{font-weight:400}.SWwV4Pw6OZ5vU3PqPXmr{--product-card-shadow:rgb(0 0 0/3%);background-color:var(--jp-white);border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);box-shadow:0 2px 6px var(--product-card-shadow),0 1px 2px var(--product-card-shadow)}.r7tUofa9Z3A5ziKVR1H7{align-items:center;display:flex}.r7tUofa9Z3A5ziKVR1H7 img{object-fit:cover;width:100%}.i_AnOR3MaQLraGvb2QU5{background-color:#f9f9f6}.YcYvLvdvWrb1EUZoVsE8{display:flex;flex-wrap:wrap;gap:calc(var(--horizontal-spacing)*2);justify-content:space-between}.uGTTsKoIOoZdYhk6uPnl{white-space:nowrap}.uGTTsKoIOoZdYhk6uPnl>span{font-size:var(--font-body-small)}.NzDTsxhX8D1mlckNpewR{font-weight:400!important}.svE2cJL5t2FarzcDQYNe{--product-card-shadow:rgb(0 0 0/3%);background-color:var(--jp-white);border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);box-shadow:0 2px 6px var(--product-card-shadow),0 1px 2px var(--product-card-shadow)}.dvEJEDNTnmVfVxtLa4uU{align-items:center;display:flex}.dvEJEDNTnmVfVxtLa4uU img{object-fit:cover;width:100%}.K1VY4DNP8PHMWAEVBC_h{background-color:#f9f9f6}.nk_COGPrkBNLp7lVt4sQ{display:flex;flex-wrap:wrap;gap:calc(var(--horizontal-spacing)*2);justify-content:space-between}.ukgQ5TmLablG3svUKjdw{white-space:nowrap}.ukgQ5TmLablG3svUKjdw>span{font-size:var(--font-body-small)}.Vofm70ADXSe43GamWEaF{font-weight:400!important}.EUcF2LKeC2GyhWD2FKCP{background-color:var(--jp-white);height:100%;padding:calc(var(--spacing-base)*8);position:relative}.Bm21LIBQtpRo3ZhOxXBG{display:flex;gap:calc(var(--spacing-base)*2)}.jwIGzADCnBI_ai9xYYiS{align-items:center;display:flex;flex-wrap:nowrap;font-size:22px;padding-bottom:calc(var(--spacing-base)*3);padding-top:calc(var(--spacing-base)*3)}.jwIGzADCnBI_ai9xYYiS .fTbxuhh_SfMgenyWvGN0{padding-bottom:calc(var(--spacing-base)/3);padding-left:var(--spacing-base)}.eR56lApoP14RIBAhO1UN{display:flex;flex-wrap:wrap;gap:calc(var(--spacing-base)*6);justify-content:space-between;margin:0 auto;max-width:1128px}@media only screen and (max-width:1366px){.eR56lApoP14RIBAhO1UN{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3)}}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD{display:flex;flex:1;flex-direction:column;justify-content:center}@media screen and (min-width:960px){.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD{max-width:70%}}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD .vAGLpjIGi6GA8ghbumN7{font-size:36px;font-weight:700;line-height:40px}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD .oag8YaslCEiUVu8GKKL3{font-weight:400;margin:calc(var(--spacing-base)*3) 0}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD .FhH03GPt9FK1VH9NZhYA{align-self:flex-start;font-size:16px;font-weight:500;letter-spacing:-.01em;line-height:24px;padding:var(--spacing-base) calc(var(--spacing-base)*3)}.eR56lApoP14RIBAhO1UN .VUXAtah2JvUCNc4cXjPp{align-items:center;display:flex;flex-wrap:wrap;gap:calc(var(--spacing-base)*3);justify-content:flex-end}@media only screen and (max-width:430px){.eR56lApoP14RIBAhO1UN .VUXAtah2JvUCNc4cXjPp{flex:1}}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw{border-color:var(--jp-gray-5);border-radius:5px;flex-grow:0;height:168px;margin-bottom:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);width:168px}@media only screen and (max-width:960px){.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw{width:30vw}}@media only screen and (max-width:430px){.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw{min-width:168px;width:100%}}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw>div:first-child{display:flex;flex-direction:column;justify-content:space-between}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw .Ll1l9bEuf5G5oh3AENep{fill:var(--jp-green)}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw .WrzTysWiqUiuEPvpFqau{margin-bottom:var(--spacing-base)}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw .d4faYkf9yL7oW7pwcjmP{font-size:36px;font-weight:700}.acffvOSYc5S8x4P_AYnQ{font-size:16px;line-height:24px;padding-bottom:calc(var(--spacing-base)*6);padding-top:calc(var(--spacing-base)*6)}.acffvOSYc5S8x4P_AYnQ:first-child{padding-bottom:0;padding-top:0}.acffvOSYc5S8x4P_AYnQ:nth-child(2n){background-color:var(--jp-white-off);padding-bottom:calc(var(--spacing-base)*8);padding-top:calc(var(--spacing-base)*8)}@media only screen and (max-width:960px){.acffvOSYc5S8x4P_AYnQ:nth-child(2n){padding-bottom:calc(var(--spacing-base)*6);padding-top:calc(var(--spacing-base)*6)}}.acffvOSYc5S8x4P_AYnQ a{color:inherit}.acffvOSYc5S8x4P_AYnQ .M5YNmgy60Q_UtaxKgQcv{margin:0 auto;max-width:744px}@media only screen and (max-width:1366px){.acffvOSYc5S8x4P_AYnQ .M5YNmgy60Q_UtaxKgQcv{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3)}}.acffvOSYc5S8x4P_AYnQ .HJiOvun8sHkiFpNL0sl6{margin:0 auto;max-width:1128px}@media only screen and (max-width:1366px){.acffvOSYc5S8x4P_AYnQ .HJiOvun8sHkiFpNL0sl6{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3)}}.acffvOSYc5S8x4P_AYnQ .mXinUJfpSTS9EVB8M8K_{font-size:34px;font-weight:400;line-height:40px;margin:0}.acffvOSYc5S8x4P_AYnQ .QKjsnliPyLu4n08yVUUM{font-size:16px}.acffvOSYc5S8x4P_AYnQ .xQJJkJ4v7Jm8iSJ0z0Dj{font-size:48px;line-height:24px;margin-bottom:calc(var(--spacing-base)*6)}.VWIBGwuHqtAKg_5Hch92{flex-direction:column}.VWIBGwuHqtAKg_5Hch92,.VWIBGwuHqtAKg_5Hch92 .mnkNhprYIatxfziERMwM{display:flex;gap:calc(var(--spacing-base)*3);padding:calc(var(--spacing-base)*2) 0}.VWIBGwuHqtAKg_5Hch92 .mnkNhprYIatxfziERMwM{flex-wrap:wrap;min-height:190px}.VWIBGwuHqtAKg_5Hch92 .WEiaYLqJwV2IzC8LD9Fs{background-color:var(--jp-white-off);border-radius:calc(var(--spacing-base)/2);height:157.5px;width:280px}.VWIBGwuHqtAKg_5Hch92 .WEiaYLqJwV2IzC8LD9Fs iframe{border-radius:inherit}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU{display:flex;flex:1;flex-direction:column;gap:var(--spacing-base);min-width:280px}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU ._OeUvI9GrP00qh6Uk7Tg{font-size:20px;font-weight:500;line-height:22px}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU .C6I5jYHW2IJSDBoKvhcB{color:var(--jp-gray-60);flex-grow:1;font-size:16px;font-weight:300;line-height:24px}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU .XdnAdAwkxAW5yvUx3NRr{font-size:15px;padding-left:0;text-decoration:underline}.MCKgMfLVZtkgWu5m5u6L{margin-bottom:calc(var(--spacing-base)*8)}.c0SItK48SRkWfZUCECbZ{border:1px solid var(--jp-green-40);border-radius:4px;color:var(--jp-green-40);font-size:12px;font-weight:500;height:22px;margin-left:5px;padding:2px 8px;position:relative;text-transform:uppercase;top:-2px}.uPEKVw20OlWzA_8u7YAc{--font-headline-medium:48px;--font-headline-small:36px;--font-title-medium:24px;--font-body:16px;--font-body-small:14px;--font-body-extra-small:14px;--spacing-base:8px;max-height:calc(100% - 24px)}.uPEKVw20OlWzA_8u7YAc .components-modal__header+div{height:100%}.uPEKVw20OlWzA_8u7YAc .components-modal__content{margin:40px;padding:0}.uPEKVw20OlWzA_8u7YAc .components-modal__header{border-bottom:0;height:40px;padding:8px 8px 0}.uPEKVw20OlWzA_8u7YAc .dZO6FXcGE5vhcJ8Y_C9w{height:100%;padding:8px}@media(max-height:768px){.FmxgyZZvzjuwp3GbBNv1{overflow:scroll;padding-bottom:24px;padding-top:24px}.FmxgyZZvzjuwp3GbBNv1 .uPEKVw20OlWzA_8u7YAc{max-height:unset}}.EtaGFgAv0H3akflLBvof,.f6I4877w7XpHhEnooqks{display:flex;flex-direction:column;gap:1rem;justify-content:space-between}.EtaGFgAv0H3akflLBvof{flex:1}.KGwdaPYtQhRLcUVbDyy9 .product-price_container{align-items:center}.IwiPAQFH04pNmEH07X9N{display:flex;flex-direction:row;gap:8px 24px}.DKmru53sFgfEs9AgBdqM{justify-content:center}.DKmru53sFgfEs9AgBdqM,.DKmru53sFgfEs9AgBdqM img{align-items:center;display:flex;height:auto;max-width:100%;overflow:hidden}.DKmru53sFgfEs9AgBdqM img{max-height:100%;object-fit:contain}.anXLrcgHHsm2LnEfXUVk{padding-top:56.25%;position:relative;width:100%}.anXLrcgHHsm2LnEfXUVk iframe{border:none;height:100%;left:0;position:absolute;top:0;width:100%}.pbC573UpPZ3Z1WF6H0rZ{display:flex;flex-direction:column}.uQb9f6VHehuQfLoouBsQ{flex-grow:1;margin:0;margin-bottom:calc(var(--spacing-base)*2);padding:0}.uQb9f6VHehuQfLoouBsQ li{align-items:flex-start;display:flex;list-style:none;margin-bottom:var(--spacing-base)}.uQb9f6VHehuQfLoouBsQ svg{fill:var(--jp-green-primary);flex-shrink:0;margin-right:var(--spacing-base)}._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box}#my-jetpack-container{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);height:100%}#my-jetpack-container .jp-dashboard-footer__jetpack-symbol{height:16px}#my-jetpack-container:has(.my-jetpack-deprecate-notice-title) .jetpack-deprecation-notice-link{color:inherit;font-weight:600;padding-right:5px}#my-jetpack-container .my-jetpack-deprecate-notice-title{font-weight:600}#wpbody-content>.notice{display:none!important}#wpwrap{background-color:var(--jp-white-off)}.jetpack-admin-full-screen #wpwrap{top:0}.jetpack-admin-full-screen #wpadminbar{display:none}.jetpack-admin-full-screen #wpbody-content{min-height:100vh!important;padding-bottom:0}.jetpack-admin-full-screen #adminmenumain,.jetpack-admin-full-screen #wpcontent>*,.jetpack-admin-full-screen #wpfooter,.jetpack-admin-full-screen .error,.jetpack-admin-full-screen .notice,.jetpack-admin-full-screen .updated{display:none}.jetpack-admin-full-screen #wpcontent{margin-left:0!important;padding-left:0!important}.jetpack-admin-full-screen #wpcontent>#wpbody{display:block;margin-top:0!important;padding-top:0!important} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js deleted file mode 100644 index ff82863f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js +++ /dev/null @@ -1,186 +0,0 @@ -/*! For license information please see index.js.LICENSE.txt */ -(()=>{var e={79826:(e,t,a)=>{"use strict";a.d(t,{i:()=>o});const r={AED:{symbol:"د.إ.‏",grouping:",",decimal:".",precision:2},AFN:{symbol:"؋",grouping:",",decimal:".",precision:2},ALL:{symbol:"Lek",grouping:".",decimal:",",precision:2},AMD:{symbol:"֏",grouping:",",decimal:".",precision:2},ANG:{symbol:"ƒ",grouping:",",decimal:".",precision:2},AOA:{symbol:"Kz",grouping:",",decimal:".",precision:2},ARS:{symbol:"$",grouping:".",decimal:",",precision:2},AUD:{symbol:"A$",grouping:",",decimal:".",precision:2},AWG:{symbol:"ƒ",grouping:",",decimal:".",precision:2},AZN:{symbol:"₼",grouping:" ",decimal:",",precision:2},BAM:{symbol:"КМ",grouping:".",decimal:",",precision:2},BBD:{symbol:"Bds$",grouping:",",decimal:".",precision:2},BDT:{symbol:"৳",grouping:",",decimal:".",precision:0},BGN:{symbol:"лв.",grouping:" ",decimal:",",precision:2},BHD:{symbol:"د.ب.‏",grouping:",",decimal:".",precision:3},BIF:{symbol:"FBu",grouping:",",decimal:".",precision:0},BMD:{symbol:"$",grouping:",",decimal:".",precision:2},BND:{symbol:"$",grouping:".",decimal:",",precision:0},BOB:{symbol:"Bs",grouping:".",decimal:",",precision:2},BRL:{symbol:"R$",grouping:".",decimal:",",precision:2},BSD:{symbol:"$",grouping:",",decimal:".",precision:2},BTC:{symbol:"Ƀ",grouping:",",decimal:".",precision:2},BTN:{symbol:"Nu.",grouping:",",decimal:".",precision:1},BWP:{symbol:"P",grouping:",",decimal:".",precision:2},BYR:{symbol:"р.",grouping:" ",decimal:",",precision:2},BZD:{symbol:"BZ$",grouping:",",decimal:".",precision:2},CAD:{symbol:"C$",grouping:",",decimal:".",precision:2},CDF:{symbol:"FC",grouping:",",decimal:".",precision:2},CHF:{symbol:"CHF",grouping:"'",decimal:".",precision:2},CLP:{symbol:"$",grouping:".",decimal:",",precision:2},CNY:{symbol:"¥",grouping:",",decimal:".",precision:2},COP:{symbol:"$",grouping:".",decimal:",",precision:2},CRC:{symbol:"₡",grouping:".",decimal:",",precision:2},CUC:{symbol:"CUC",grouping:",",decimal:".",precision:2},CUP:{symbol:"$MN",grouping:",",decimal:".",precision:2},CVE:{symbol:"$",grouping:",",decimal:".",precision:2},CZK:{symbol:"Kč",grouping:" ",decimal:",",precision:2},DJF:{symbol:"Fdj",grouping:",",decimal:".",precision:0},DKK:{symbol:"kr.",grouping:"",decimal:",",precision:2},DOP:{symbol:"RD$",grouping:",",decimal:".",precision:2},DZD:{symbol:"د.ج.‏",grouping:",",decimal:".",precision:2},EGP:{symbol:"ج.م.‏",grouping:",",decimal:".",precision:2},ERN:{symbol:"Nfk",grouping:",",decimal:".",precision:2},ETB:{symbol:"ETB",grouping:",",decimal:".",precision:2},EUR:{symbol:"€",grouping:".",decimal:",",precision:2},FJD:{symbol:"FJ$",grouping:",",decimal:".",precision:2},FKP:{symbol:"£",grouping:",",decimal:".",precision:2},GBP:{symbol:"£",grouping:",",decimal:".",precision:2},GEL:{symbol:"Lari",grouping:" ",decimal:",",precision:2},GHS:{symbol:"₵",grouping:",",decimal:".",precision:2},GIP:{symbol:"£",grouping:",",decimal:".",precision:2},GMD:{symbol:"D",grouping:",",decimal:".",precision:2},GNF:{symbol:"FG",grouping:",",decimal:".",precision:0},GTQ:{symbol:"Q",grouping:",",decimal:".",precision:2},GYD:{symbol:"G$",grouping:",",decimal:".",precision:2},HKD:{symbol:"HK$",grouping:",",decimal:".",precision:2},HNL:{symbol:"L.",grouping:",",decimal:".",precision:2},HRK:{symbol:"kn",grouping:".",decimal:",",precision:2},HTG:{symbol:"G",grouping:",",decimal:".",precision:2},HUF:{symbol:"Ft",grouping:".",decimal:",",precision:0},IDR:{symbol:"Rp",grouping:".",decimal:",",precision:0},ILS:{symbol:"₪",grouping:",",decimal:".",precision:2},INR:{symbol:"₹",grouping:",",decimal:".",precision:2},IQD:{symbol:"د.ع.‏",grouping:",",decimal:".",precision:2},IRR:{symbol:"﷼",grouping:",",decimal:"/",precision:2},ISK:{symbol:"kr.",grouping:".",decimal:",",precision:0},JMD:{symbol:"J$",grouping:",",decimal:".",precision:2},JOD:{symbol:"د.ا.‏",grouping:",",decimal:".",precision:3},JPY:{symbol:"¥",grouping:",",decimal:".",precision:0},KES:{symbol:"S",grouping:",",decimal:".",precision:2},KGS:{symbol:"сом",grouping:" ",decimal:"-",precision:2},KHR:{symbol:"៛",grouping:",",decimal:".",precision:0},KMF:{symbol:"CF",grouping:",",decimal:".",precision:2},KPW:{symbol:"₩",grouping:",",decimal:".",precision:0},KRW:{symbol:"₩",grouping:",",decimal:".",precision:0},KWD:{symbol:"د.ك.‏",grouping:",",decimal:".",precision:3},KYD:{symbol:"$",grouping:",",decimal:".",precision:2},KZT:{symbol:"₸",grouping:" ",decimal:"-",precision:2},LAK:{symbol:"₭",grouping:",",decimal:".",precision:0},LBP:{symbol:"ل.ل.‏",grouping:",",decimal:".",precision:2},LKR:{symbol:"₨",grouping:",",decimal:".",precision:0},LRD:{symbol:"L$",grouping:",",decimal:".",precision:2},LSL:{symbol:"M",grouping:",",decimal:".",precision:2},LYD:{symbol:"د.ل.‏",grouping:",",decimal:".",precision:3},MAD:{symbol:"د.م.‏",grouping:",",decimal:".",precision:2},MDL:{symbol:"lei",grouping:",",decimal:".",precision:2},MGA:{symbol:"Ar",grouping:",",decimal:".",precision:0},MKD:{symbol:"ден.",grouping:".",decimal:",",precision:2},MMK:{symbol:"K",grouping:",",decimal:".",precision:2},MNT:{symbol:"₮",grouping:" ",decimal:",",precision:2},MOP:{symbol:"MOP$",grouping:",",decimal:".",precision:2},MRO:{symbol:"UM",grouping:",",decimal:".",precision:2},MTL:{symbol:"₤",grouping:",",decimal:".",precision:2},MUR:{symbol:"₨",grouping:",",decimal:".",precision:2},MVR:{symbol:"MVR",grouping:",",decimal:".",precision:1},MWK:{symbol:"MK",grouping:",",decimal:".",precision:2},MXN:{symbol:"MX$",grouping:",",decimal:".",precision:2},MYR:{symbol:"RM",grouping:",",decimal:".",precision:2},MZN:{symbol:"MT",grouping:",",decimal:".",precision:0},NAD:{symbol:"N$",grouping:",",decimal:".",precision:2},NGN:{symbol:"₦",grouping:",",decimal:".",precision:2},NIO:{symbol:"C$",grouping:",",decimal:".",precision:2},NOK:{symbol:"kr",grouping:" ",decimal:",",precision:2},NPR:{symbol:"₨",grouping:",",decimal:".",precision:2},NZD:{symbol:"NZ$",grouping:",",decimal:".",precision:2},OMR:{symbol:"﷼",grouping:",",decimal:".",precision:3},PAB:{symbol:"B/.",grouping:",",decimal:".",precision:2},PEN:{symbol:"S/.",grouping:",",decimal:".",precision:2},PGK:{symbol:"K",grouping:",",decimal:".",precision:2},PHP:{symbol:"₱",grouping:",",decimal:".",precision:2},PKR:{symbol:"₨",grouping:",",decimal:".",precision:2},PLN:{symbol:"zł",grouping:" ",decimal:",",precision:2},PYG:{symbol:"₲",grouping:".",decimal:",",precision:2},QAR:{symbol:"﷼",grouping:",",decimal:".",precision:2},RON:{symbol:"lei",grouping:".",decimal:",",precision:2},RSD:{symbol:"Дин.",grouping:".",decimal:",",precision:2},RUB:{symbol:"₽",grouping:" ",decimal:",",precision:2},RWF:{symbol:"RWF",grouping:" ",decimal:",",precision:2},SAR:{symbol:"﷼",grouping:",",decimal:".",precision:2},SBD:{symbol:"S$",grouping:",",decimal:".",precision:2},SCR:{symbol:"₨",grouping:",",decimal:".",precision:2},SDD:{symbol:"LSd",grouping:",",decimal:".",precision:2},SDG:{symbol:"£‏",grouping:",",decimal:".",precision:2},SEK:{symbol:"kr",grouping:",",decimal:".",precision:2},SGD:{symbol:"S$",grouping:",",decimal:".",precision:2},SHP:{symbol:"£",grouping:",",decimal:".",precision:2},SLL:{symbol:"Le",grouping:",",decimal:".",precision:2},SOS:{symbol:"S",grouping:",",decimal:".",precision:2},SRD:{symbol:"$",grouping:",",decimal:".",precision:2},STD:{symbol:"Db",grouping:",",decimal:".",precision:2},SVC:{symbol:"₡",grouping:",",decimal:".",precision:2},SYP:{symbol:"£",grouping:",",decimal:".",precision:2},SZL:{symbol:"E",grouping:",",decimal:".",precision:2},THB:{symbol:"฿",grouping:",",decimal:".",precision:2},TJS:{symbol:"TJS",grouping:" ",decimal:";",precision:2},TMT:{symbol:"m",grouping:" ",decimal:",",precision:0},TND:{symbol:"د.ت.‏",grouping:",",decimal:".",precision:3},TOP:{symbol:"T$",grouping:",",decimal:".",precision:2},TRY:{symbol:"TL",grouping:".",decimal:",",precision:2},TTD:{symbol:"TT$",grouping:",",decimal:".",precision:2},TVD:{symbol:"$T",grouping:",",decimal:".",precision:2},TWD:{symbol:"NT$",grouping:",",decimal:".",precision:2},TZS:{symbol:"TSh",grouping:",",decimal:".",precision:2},UAH:{symbol:"₴",grouping:" ",decimal:",",precision:2},UGX:{symbol:"USh",grouping:",",decimal:".",precision:2},USD:{symbol:"$",grouping:",",decimal:".",precision:2},UYU:{symbol:"$U",grouping:".",decimal:",",precision:2},UZS:{symbol:"сўм",grouping:" ",decimal:",",precision:2},VEB:{symbol:"Bs.",grouping:",",decimal:".",precision:2},VEF:{symbol:"Bs. F.",grouping:".",decimal:",",precision:2},VND:{symbol:"₫",grouping:".",decimal:",",precision:1},VUV:{symbol:"VT",grouping:",",decimal:".",precision:0},WST:{symbol:"WS$",grouping:",",decimal:".",precision:2},XAF:{symbol:"F",grouping:",",decimal:".",precision:2},XCD:{symbol:"$",grouping:",",decimal:".",precision:2},XOF:{symbol:"F",grouping:" ",decimal:",",precision:2},XPF:{symbol:"F",grouping:",",decimal:".",precision:2},YER:{symbol:"﷼",grouping:",",decimal:".",precision:2},ZAR:{symbol:"R",grouping:" ",decimal:",",precision:2},ZMW:{symbol:"ZK",grouping:",",decimal:".",precision:2},WON:{symbol:"₩",grouping:",",decimal:".",precision:2}};function o(e){return r[e]||{symbol:"$",grouping:",",decimal:".",precision:2}}},67397:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>n,vA:()=>l});var r=a(79826),o=a(88506);function n(e,t,a={}){const n=(0,r.i)(t);if(!n||isNaN(e))return null;const{decimal:l,grouping:s,precision:i,symbol:c}={...n,...a},u=e<0?"-":"";let d=(0,o.A)(Math.abs(e),i,l,s);return a.stripZeros&&(d=function(e,t){const a=new RegExp(`\\${t}0+$`);return e.replace(a,"")}(d,l)),`${u}${c}${d}`}function l(e,t,a={}){const n=(0,r.i)(t);if(!n||isNaN(e))return null;const{decimal:l,grouping:s,precision:i,symbol:c}={...n,...a},u=e<0?"-":"",d=Math.abs(e),v=Math.floor(d);return{sign:u,symbol:c,integer:(0,o.A)(d,i,l,s).split(l)[0],fraction:i>0?(0,o.A)(d-v,i,l,s).slice(1):""}}},88506:(e,t,a)=>{"use strict";function r(e,t=0,a=".",r=","){const o=(e+"").replace(/[^0-9+\-Ee.]/g,""),n=isFinite(+o)?+o:0,l=isFinite(+t)?Math.abs(t):0,s=(l?function(e,t){const a=Math.pow(10,t);return""+(Math.round(e*a)/a).toFixed(t)}(n,l):""+Math.round(n)).split(".");return s[0].length>3&&(s[0]=s[0].replace(/\B(?=(?:\d{3})+(?!\d))/g,r)),(s[1]||"").lengthr})},64370:(e,t,a)=>{"use strict";a.r(t),a.d(t,{arrow:()=>R,autoPlacement:()=>C,autoUpdate:()=>_,computePosition:()=>z,detectOverflow:()=>k,flip:()=>A,getOverflowAncestors:()=>n.v9,hide:()=>P,inline:()=>M,limitShift:()=>V,offset:()=>E,platform:()=>y,shift:()=>j,size:()=>S});var r=a(39175),o=a(159),n=a(81289);function l(e){const t=(0,n.L9)(e);let a=parseFloat(t.width)||0,o=parseFloat(t.height)||0;const l=(0,n.sb)(e),s=l?e.offsetWidth:a,i=l?e.offsetHeight:o,c=(0,r.LI)(a)!==s||(0,r.LI)(o)!==i;return c&&(a=s,o=i),{width:a,height:o,$:c}}function s(e){return(0,n.vq)(e)?e:e.contextElement}function i(e){const t=s(e);if(!(0,n.sb)(t))return(0,r.Jx)(1);const a=t.getBoundingClientRect(),{width:o,height:i,$:c}=l(t);let u=(c?(0,r.LI)(a.width):a.width)/o,d=(c?(0,r.LI)(a.height):a.height)/i;return u&&Number.isFinite(u)||(u=1),d&&Number.isFinite(d)||(d=1),{x:u,y:d}}const c=(0,r.Jx)(0);function u(e){const t=(0,n.zk)(e);return(0,n.Tc)()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:c}function d(e,t,a,o){void 0===t&&(t=!1),void 0===a&&(a=!1);const l=e.getBoundingClientRect(),c=s(e);let d=(0,r.Jx)(1);t&&(o?(0,n.vq)(o)&&(d=i(o)):d=i(e));const v=function(e,t,a){return void 0===t&&(t=!1),!(!a||t&&a!==(0,n.zk)(e))&&t}(c,a,o)?u(c):(0,r.Jx)(0);let p=(l.left+v.x)/d.x,m=(l.top+v.y)/d.y,h=l.width/d.x,f=l.height/d.y;if(c){const e=(0,n.zk)(c),t=o&&(0,n.vq)(o)?(0,n.zk)(o):o;let a=e,r=(0,n._m)(a);for(;r&&o&&t!==a;){const e=i(r),t=r.getBoundingClientRect(),o=(0,n.L9)(r),l=t.left+(r.clientLeft+parseFloat(o.paddingLeft))*e.x,s=t.top+(r.clientTop+parseFloat(o.paddingTop))*e.y;p*=e.x,m*=e.y,h*=e.x,f*=e.y,p+=l,m+=s,a=(0,n.zk)(r),r=(0,n._m)(a)}}return(0,r.B1)({width:h,height:f,x:p,y:m})}function v(e,t){const a=(0,n.CP)(e).scrollLeft;return t?t.left+a:d((0,n.ep)(e)).left+a}function p(e,t,a){void 0===a&&(a=!1);const r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-(a?0:v(e,r)),y:r.top+t.scrollTop}}function m(e,t,a){let o;if("viewport"===t)o=function(e,t){const a=(0,n.zk)(e),r=(0,n.ep)(e),o=a.visualViewport;let l=r.clientWidth,s=r.clientHeight,i=0,c=0;if(o){l=o.width,s=o.height;const e=(0,n.Tc)();(!e||e&&"fixed"===t)&&(i=o.offsetLeft,c=o.offsetTop)}return{width:l,height:s,x:i,y:c}}(e,a);else if("document"===t)o=function(e){const t=(0,n.ep)(e),a=(0,n.CP)(e),o=e.ownerDocument.body,l=(0,r.T9)(t.scrollWidth,t.clientWidth,o.scrollWidth,o.clientWidth),s=(0,r.T9)(t.scrollHeight,t.clientHeight,o.scrollHeight,o.clientHeight);let i=-a.scrollLeft+v(e);const c=-a.scrollTop;return"rtl"===(0,n.L9)(o).direction&&(i+=(0,r.T9)(t.clientWidth,o.clientWidth)-l),{width:l,height:s,x:i,y:c}}((0,n.ep)(e));else if((0,n.vq)(t))o=function(e,t){const a=d(e,!0,"fixed"===t),o=a.top+e.clientTop,l=a.left+e.clientLeft,s=(0,n.sb)(e)?i(e):(0,r.Jx)(1);return{width:e.clientWidth*s.x,height:e.clientHeight*s.y,x:l*s.x,y:o*s.y}}(t,a);else{const a=u(e);o={x:t.x-a.x,y:t.y-a.y,width:t.width,height:t.height}}return(0,r.B1)(o)}function h(e,t){const a=(0,n.$4)(e);return!(a===t||!(0,n.vq)(a)||(0,n.eu)(a))&&("fixed"===(0,n.L9)(a).position||h(a,t))}function f(e,t,a){const o=(0,n.sb)(t),l=(0,n.ep)(t),s="fixed"===a,i=d(e,!0,s,t);let c={scrollLeft:0,scrollTop:0};const u=(0,r.Jx)(0);if(o||!o&&!s)if(("body"!==(0,n.mq)(t)||(0,n.ZU)(l))&&(c=(0,n.CP)(t)),o){const e=d(t,!0,s,t);u.x=e.x+t.clientLeft,u.y=e.y+t.clientTop}else l&&(u.x=v(l));const m=!l||o||s?(0,r.Jx)(0):p(l,c);return{x:i.left+c.scrollLeft-u.x-m.x,y:i.top+c.scrollTop-u.y-m.y,width:i.width,height:i.height}}function g(e){return"static"===(0,n.L9)(e).position}function w(e,t){if(!(0,n.sb)(e)||"fixed"===(0,n.L9)(e).position)return null;if(t)return t(e);let a=e.offsetParent;return(0,n.ep)(e)===a&&(a=a.ownerDocument.body),a}function b(e,t){const a=(0,n.zk)(e);if((0,n.Tf)(e))return a;if(!(0,n.sb)(e)){let t=(0,n.$4)(e);for(;t&&!(0,n.eu)(t);){if((0,n.vq)(t)&&!g(t))return t;t=(0,n.$4)(t)}return a}let r=w(e,t);for(;r&&(0,n.Lv)(r)&&g(r);)r=w(r,t);return r&&(0,n.eu)(r)&&g(r)&&!(0,n.sQ)(r)?a:r||(0,n.gJ)(e)||a}const y={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:a,offsetParent:o,strategy:l}=e;const s="fixed"===l,c=(0,n.ep)(o),u=!!t&&(0,n.Tf)(t.floating);if(o===c||u&&s)return a;let v={scrollLeft:0,scrollTop:0},m=(0,r.Jx)(1);const h=(0,r.Jx)(0),f=(0,n.sb)(o);if((f||!f&&!s)&&(("body"!==(0,n.mq)(o)||(0,n.ZU)(c))&&(v=(0,n.CP)(o)),(0,n.sb)(o))){const e=d(o);m=i(o),h.x=e.x+o.clientLeft,h.y=e.y+o.clientTop}const g=!c||f||s?(0,r.Jx)(0):p(c,v,!0);return{width:a.width*m.x,height:a.height*m.y,x:a.x*m.x-v.scrollLeft*m.x+h.x+g.x,y:a.y*m.y-v.scrollTop*m.y+h.y+g.y}},getDocumentElement:n.ep,getClippingRect:function(e){let{element:t,boundary:a,rootBoundary:o,strategy:l}=e;const s=[..."clippingAncestors"===a?(0,n.Tf)(t)?[]:function(e,t){const a=t.get(e);if(a)return a;let r=(0,n.v9)(e,[],!1).filter((e=>(0,n.vq)(e)&&"body"!==(0,n.mq)(e))),o=null;const l="fixed"===(0,n.L9)(e).position;let s=l?(0,n.$4)(e):e;for(;(0,n.vq)(s)&&!(0,n.eu)(s);){const t=(0,n.L9)(s),a=(0,n.sQ)(s);a||"fixed"!==t.position||(o=null),(l?!a&&!o:!a&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||(0,n.ZU)(s)&&!a&&h(e,s))?r=r.filter((e=>e!==s)):o=t,s=(0,n.$4)(s)}return t.set(e,r),r}(t,this._c):[].concat(a),o],i=s[0],c=s.reduce(((e,a)=>{const o=m(t,a,l);return e.top=(0,r.T9)(o.top,e.top),e.right=(0,r.jk)(o.right,e.right),e.bottom=(0,r.jk)(o.bottom,e.bottom),e.left=(0,r.T9)(o.left,e.left),e}),m(t,i,l));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}},getOffsetParent:b,getElementRects:async function(e){const t=this.getOffsetParent||b,a=this.getDimensions,r=await a(e.floating);return{reference:f(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:a}=l(e);return{width:t,height:a}},getScale:i,isElement:n.vq,isRTL:function(e){return"rtl"===(0,n.L9)(e).direction}};function x(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function _(e,t,a,o){void 0===o&&(o={});const{ancestorScroll:l=!0,ancestorResize:i=!0,elementResize:c="function"==typeof ResizeObserver,layoutShift:u="function"==typeof IntersectionObserver,animationFrame:v=!1}=o,p=s(e),m=l||i?[...p?(0,n.v9)(p):[],...(0,n.v9)(t)]:[];m.forEach((e=>{l&&e.addEventListener("scroll",a,{passive:!0}),i&&e.addEventListener("resize",a)}));const h=p&&u?function(e,t){let a,o=null;const l=(0,n.ep)(e);function s(){var e;clearTimeout(a),null==(e=o)||e.disconnect(),o=null}return function n(i,c){void 0===i&&(i=!1),void 0===c&&(c=1),s();const u=e.getBoundingClientRect(),{left:d,top:v,width:p,height:m}=u;if(i||t(),!p||!m)return;const h={rootMargin:-(0,r.RI)(v)+"px "+-(0,r.RI)(l.clientWidth-(d+p))+"px "+-(0,r.RI)(l.clientHeight-(v+m))+"px "+-(0,r.RI)(d)+"px",threshold:(0,r.T9)(0,(0,r.jk)(1,c))||1};let f=!0;function g(t){const r=t[0].intersectionRatio;if(r!==c){if(!f)return n();r?n(!1,r):a=setTimeout((()=>{n(!1,1e-7)}),1e3)}1!==r||x(u,e.getBoundingClientRect())||n(),f=!1}try{o=new IntersectionObserver(g,{...h,root:l.ownerDocument})}catch(e){o=new IntersectionObserver(g,h)}o.observe(e)}(!0),s}(p,a):null;let f,g=-1,w=null;c&&(w=new ResizeObserver((e=>{let[r]=e;r&&r.target===p&&w&&(w.unobserve(t),cancelAnimationFrame(g),g=requestAnimationFrame((()=>{var e;null==(e=w)||e.observe(t)}))),a()})),p&&!v&&w.observe(p),w.observe(t));let b=v?d(e):null;return v&&function t(){const r=d(e);b&&!x(b,r)&&a();b=r,f=requestAnimationFrame(t)}(),a(),()=>{var e;m.forEach((e=>{l&&e.removeEventListener("scroll",a),i&&e.removeEventListener("resize",a)})),null==h||h(),null==(e=w)||e.disconnect(),w=null,v&&cancelAnimationFrame(f)}}const k=o.HN,E=o.cY,C=o.RK,j=o.BN,A=o.UU,S=o.Ej,P=o.jD,R=o.UE,M=o.mG,V=o.ER,z=(e,t,a)=>{const r=new Map,n={platform:y,...a},l={...n.platform,_c:r};return(0,o.rD)(e,t,{...n,platform:l})}},36992:(e,t,a)=>{"use strict";function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;td,Gh:()=>H,HS:()=>L,Oi:()=>s,Rr:()=>v,TM:()=>l,pX:()=>T,pb:()=>R,rc:()=>o,tH:()=>B,ue:()=>h,yD:()=>z}),function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"}(o||(o={}));const n="popstate";function l(e){return void 0===e&&(e={}),p((function(e,t){let{pathname:a="/",search:r="",hash:o=""}=v(e.location.hash.substr(1));return a.startsWith("/")||a.startsWith(".")||(a="/"+a),u("",{pathname:a,search:r,hash:o},t.state&&t.state.usr||null,t.state&&t.state.key||"default")}),(function(e,t){let a=e.document.querySelector("base"),r="";if(a&&a.getAttribute("href")){let t=e.location.href,a=t.indexOf("#");r=-1===a?t:t.slice(0,a)}return r+"#"+("string"==typeof t?t:d(t))}),(function(e,t){i("/"===e.pathname.charAt(0),"relative pathnames are not supported in hash history.push("+JSON.stringify(t)+")")}),e)}function s(e,t){if(!1===e||null==e)throw new Error(t)}function i(e,t){if(!e){"undefined"!=typeof console&&console.warn(t);try{throw new Error(t)}catch(e){}}}function c(e,t){return{usr:e.state,key:e.key,idx:t}}function u(e,t,a,o){return void 0===a&&(a=null),r({pathname:"string"==typeof e?e:e.pathname,search:"",hash:""},"string"==typeof t?v(t):t,{state:a,key:t&&t.key||o||Math.random().toString(36).substr(2,8)})}function d(e){let{pathname:t="/",search:a="",hash:r=""}=e;return a&&"?"!==a&&(t+="?"===a.charAt(0)?a:"?"+a),r&&"#"!==r&&(t+="#"===r.charAt(0)?r:"#"+r),t}function v(e){let t={};if(e){let a=e.indexOf("#");a>=0&&(t.hash=e.substr(a),e=e.substr(0,a));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function p(e,t,a,l){void 0===l&&(l={});let{window:i=document.defaultView,v5Compat:v=!1}=l,p=i.history,m=o.Pop,h=null,f=g();function g(){return(p.state||{idx:null}).idx}function w(){m=o.Pop;let e=g(),t=null==e?null:e-f;f=e,h&&h({action:m,location:y.location,delta:t})}function b(e){let t="null"!==i.location.origin?i.location.origin:i.location.href,a="string"==typeof e?e:d(e);return a=a.replace(/ $/,"%20"),s(t,"No window.location.(origin|href) available to create URL for href: "+a),new URL(a,t)}null==f&&(f=0,p.replaceState(r({},p.state,{idx:f}),""));let y={get action(){return m},get location(){return e(i,p)},listen(e){if(h)throw new Error("A history only accepts one active listener");return i.addEventListener(n,w),h=e,()=>{i.removeEventListener(n,w),h=null}},createHref:e=>t(i,e),createURL:b,encodeLocation(e){let t=b(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:function(e,t){m=o.Push;let r=u(y.location,e,t);a&&a(r,e),f=g()+1;let n=c(r,f),l=y.createHref(r);try{p.pushState(n,"",l)}catch(e){if(e instanceof DOMException&&"DataCloneError"===e.name)throw e;i.location.assign(l)}v&&h&&h({action:m,location:y.location,delta:1})},replace:function(e,t){m=o.Replace;let r=u(y.location,e,t);a&&a(r,e),f=g();let n=c(r,f),l=y.createHref(r);p.replaceState(n,"",l),v&&h&&h({action:m,location:y.location,delta:0})},go:e=>p.go(e)};return y}var m;!function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"}(m||(m={}));new Set(["lazy","caseSensitive","path","id","index","children"]);function h(e,t,a){return void 0===a&&(a="/"),f(e,t,a,!1)}function f(e,t,a,r){let o=R(("string"==typeof t?v(t):t).pathname||"/",a);if(null==o)return null;let n=g(e);!function(e){e.sort(((e,t)=>e.score!==t.score?t.score-e.score:function(e,t){let a=e.length===t.length&&e.slice(0,-1).every(((e,a)=>e===t[a]));return a?e[e.length-1]-t[t.length-1]:0}(e.routesMeta.map((e=>e.childrenIndex)),t.routesMeta.map((e=>e.childrenIndex)))))}(n);let l=null;for(let e=0;null==l&&e{let l={relativePath:void 0===n?e.path||"":n,caseSensitive:!0===e.caseSensitive,childrenIndex:o,route:e};l.relativePath.startsWith("/")&&(s(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path "'+r+'" is not valid. An absolute child route path must start with the combined path of all its parent routes.'),l.relativePath=l.relativePath.slice(r.length));let i=L([r,l.relativePath]),c=a.concat(l);e.children&&e.children.length>0&&(s(!0!==e.index,'Index routes must not have child routes. Please remove all child routes from route path "'+i+'".'),g(e.children,t,c,i)),(null!=e.path||e.index)&&t.push({path:i,score:j(i,e.index),routesMeta:c})};return e.forEach(((e,t)=>{var a;if(""!==e.path&&null!=(a=e.path)&&a.includes("?"))for(let a of w(e.path))o(e,t,a);else o(e,t)})),t}function w(e){let t=e.split("/");if(0===t.length)return[];let[a,...r]=t,o=a.endsWith("?"),n=a.replace(/\?$/,"");if(0===r.length)return o?[n,""]:[n];let l=w(r.join("/")),s=[];return s.push(...l.map((e=>""===e?n:[n,e].join("/")))),o&&s.push(...l),s.map((t=>e.startsWith("/")&&""===t?"/":t))}const b=/^:[\w-]+$/,y=3,x=2,_=1,k=10,E=-2,C=e=>"*"===e;function j(e,t){let a=e.split("/"),r=a.length;return a.some(C)&&(r+=E),t&&(r+=x),a.filter((e=>!C(e))).reduce(((e,t)=>e+(b.test(t)?y:""===t?_:k)),r)}function A(e,t,a){void 0===a&&(a=!1);let{routesMeta:r}=e,o={},n="/",l=[];for(let e=0;e(r.push({paramName:t,isOptional:null!=a}),a?"/?([^\\/]+)?":"/([^\\/]+)")));e.endsWith("*")?(r.push({paramName:"*"}),o+="*"===e||"/*"===e?"(.*)$":"(?:\\/(.+)|\\/*)$"):a?o+="\\/*$":""!==e&&"/"!==e&&(o+="(?:(?=\\/|$))");let n=new RegExp(o,t?void 0:"i");return[n,r]}(e.path,e.caseSensitive,e.end),o=t.match(a);if(!o)return null;let n=o[0],l=n.replace(/(.)\/+$/,"$1"),s=o.slice(1);return{params:r.reduce(((e,t,a)=>{let{paramName:r,isOptional:o}=t;if("*"===r){let e=s[a]||"";l=n.slice(0,n.length-e.length).replace(/(.)\/+$/,"$1")}const i=s[a];return e[r]=o&&!i?void 0:(i||"").replace(/%2F/g,"/"),e}),{}),pathname:n,pathnameBase:l,pattern:e}}function P(e){try{return e.split("/").map((e=>decodeURIComponent(e).replace(/\//g,"%2F"))).join("/")}catch(t){return i(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent encoding ('+t+")."),e}}function R(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let a=t.endsWith("/")?t.length-1:t.length,r=e.charAt(a);return r&&"/"!==r?null:e.slice(a)||"/"}function M(e,t,a,r){return"Cannot include a '"+e+"' character in a manually specified `to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the `to."+a+'` field. Alternatively you may provide the full path as a string in and the router will parse it for you.'}function V(e){return e.filter(((e,t)=>0===t||e.route.path&&e.route.path.length>0))}function z(e,t){let a=V(e);return t?a.map(((e,t)=>t===a.length-1?e.pathname:e.pathnameBase)):a.map((e=>e.pathnameBase))}function H(e,t,a,o){let n;void 0===o&&(o=!1),"string"==typeof e?n=v(e):(n=r({},e),s(!n.pathname||!n.pathname.includes("?"),M("?","pathname","search",n)),s(!n.pathname||!n.pathname.includes("#"),M("#","pathname","hash",n)),s(!n.search||!n.search.includes("#"),M("#","search","hash",n)));let l,i=""===e||""===n.pathname,c=i?"/":n.pathname;if(null==c)l=a;else{let e=t.length-1;if(!o&&c.startsWith("..")){let t=c.split("/");for(;".."===t[0];)t.shift(),e-=1;n.pathname=t.join("/")}l=e>=0?t[e]:"/"}let u=function(e,t){void 0===t&&(t="/");let{pathname:a,search:r="",hash:o=""}="string"==typeof e?v(e):e,n=a?a.startsWith("/")?a:function(e,t){let a=t.replace(/\/+$/,"").split("/");return e.split("/").forEach((e=>{".."===e?a.length>1&&a.pop():"."!==e&&a.push(e)})),a.length>1?a.join("/"):"/"}(a,t):t;return{pathname:n,search:N(r),hash:I(o)}}(n,l),d=c&&"/"!==c&&c.endsWith("/"),p=(i||"."===c)&&a.endsWith("/");return u.pathname.endsWith("/")||!d&&!p||(u.pathname+="/"),u}const L=e=>e.join("/").replace(/\/\/+/g,"/"),O=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),N=e=>e&&"?"!==e?e.startsWith("?")?e:"?"+e:"",I=e=>e&&"#"!==e?e.startsWith("#")?e:"#"+e:"";class B extends Error{}function T(e){return null!=e&&"number"==typeof e.status&&"string"==typeof e.statusText&&"boolean"==typeof e.internal&&"data"in e}const F=["post","put","patch","delete"],D=(new Set(F),["get",...F]);new Set(D),new Set([301,302,303,307,308]),new Set([307,308]);Symbol("deferred")},51113:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(86087);const o=(0,r.forwardRef)((function({icon:e,size:t=24,...a},o){return(0,r.cloneElement)(e,{width:t,height:t,...a,ref:o})}))},83203:(e,t,a)=>{"use strict";a.r(t),a.d(t,{Icon:()=>r.A,addCard:()=>o.A,addSubmenu:()=>n.A,addTemplate:()=>l.A,alignCenter:()=>s.A,alignJustify:()=>i.A,alignLeft:()=>c.A,alignNone:()=>u.A,alignRight:()=>d.A,archive:()=>v.A,arrowDown:()=>p.A,arrowDownRight:()=>m.A,arrowLeft:()=>h.A,arrowRight:()=>f.A,arrowUp:()=>g.A,arrowUpLeft:()=>w.A,aspectRatio:()=>y.A,atSymbol:()=>b.A,audio:()=>x.A,background:()=>_.A,backup:()=>k.A,bell:()=>E.A,bellUnread:()=>C.A,blockDefault:()=>j.A,blockMeta:()=>A.A,blockTable:()=>S.A,border:()=>P.A,box:()=>R.A,brush:()=>M.A,bug:()=>V.A,button:()=>z.A,buttons:()=>H.A,calendar:()=>L.A,cancelCircleFilled:()=>O.A,caption:()=>N.A,capturePhoto:()=>I.A,captureVideo:()=>B.A,category:()=>T.A,caution:()=>F.A,cautionFilled:()=>D.A,chartBar:()=>G.A,check:()=>U.A,chevronDown:()=>q.A,chevronDownSmall:()=>Z.A,chevronLeft:()=>W.A,chevronLeftSmall:()=>$.A,chevronRight:()=>J.A,chevronRightSmall:()=>K.A,chevronUp:()=>Q.A,chevronUpDown:()=>Y.A,classic:()=>X.A,close:()=>ee.A,closeSmall:()=>te.A,cloud:()=>oe.A,cloudDownload:()=>ae.A,cloudUpload:()=>re.A,code:()=>ne.A,cog:()=>le.A,color:()=>se.A,column:()=>ie.A,columns:()=>ce.A,comment:()=>ve.A,commentAuthorAvatar:()=>pe.A,commentAuthorName:()=>me.A,commentContent:()=>he.A,commentEditLink:()=>ge.A,commentReplyLink:()=>fe.A,connection:()=>we.A,copy:()=>ue.A,copySmall:()=>de.A,cover:()=>be.A,create:()=>ye.A,crop:()=>xe.A,currencyDollar:()=>_e.A,currencyEuro:()=>ke.A,currencyPound:()=>Ee.A,customLink:()=>_a.A,customPostType:()=>Ce.A,desktop:()=>je.A,details:()=>Ae.A,download:()=>Ve.A,drafts:()=>Se.A,dragHandle:()=>Pe.A,drawerLeft:()=>Re.A,drawerRight:()=>Me.A,edit:()=>ze.A,envelope:()=>He.A,error:()=>Oe.A,external:()=>Le.A,file:()=>Ne.A,filter:()=>Ie.A,flipHorizontal:()=>Be.A,flipVertical:()=>Te.A,footer:()=>co.A,formatBold:()=>Fe.A,formatCapitalize:()=>De.A,formatIndent:()=>Ge.A,formatIndentRTL:()=>Ue.A,formatItalic:()=>qe.A,formatListBullets:()=>Ze.A,formatListBulletsRTL:()=>We.A,formatListNumbered:()=>$e.A,formatListNumberedRTL:()=>Je.A,formatLowercase:()=>Qe.A,formatLtr:()=>Ke.A,formatOutdent:()=>Ye.A,formatOutdentRTL:()=>Xe.A,formatRtl:()=>et.A,formatStrikethrough:()=>tt.A,formatUnderline:()=>at.A,formatUppercase:()=>rt.A,fullscreen:()=>ot.A,funnel:()=>nt.A,gallery:()=>lt.A,globe:()=>st.A,grid:()=>it.A,group:()=>ct.A,handle:()=>ut.A,header:()=>uo.A,heading:()=>gt.A,headingLevel1:()=>dt.A,headingLevel2:()=>vt.A,headingLevel3:()=>pt.A,headingLevel4:()=>mt.A,headingLevel5:()=>ht.A,headingLevel6:()=>ft.A,help:()=>wt.A,helpFilled:()=>bt.A,home:()=>_t.A,homeButton:()=>kt.A,html:()=>Et.A,image:()=>Ct.A,inbox:()=>yt.A,info:()=>jt.A,insertAfter:()=>At.A,insertBefore:()=>St.A,institution:()=>xt.A,justifyBottom:()=>Pt.A,justifyCenter:()=>Mt.A,justifyCenterVertical:()=>Vt.A,justifyLeft:()=>Rt.A,justifyRight:()=>zt.A,justifySpaceBetween:()=>Ht.A,justifySpaceBetweenVertical:()=>Lt.A,justifyStretch:()=>Ot.A,justifyStretchVertical:()=>Nt.A,justifyTop:()=>It.A,key:()=>Bt.A,keyboard:()=>Tt.A,keyboardClose:()=>Ft.A,keyboardReturn:()=>Dt.A,language:()=>Gt.A,layout:()=>Ut.A,levelUp:()=>qt.A,lifesaver:()=>Zt.A,lineDashed:()=>Wt.A,lineDotted:()=>$t.A,lineSolid:()=>Jt.A,link:()=>Kt.A,linkOff:()=>Qt.A,list:()=>Yt.A,listItem:()=>Xt.A,listView:()=>ea.A,lock:()=>ta.A,lockOutline:()=>aa.A,lockSmall:()=>ra.A,login:()=>oa.A,loop:()=>na.A,mapMarker:()=>la.A,media:()=>sa.A,mediaAndText:()=>ia.A,megaphone:()=>ca.A,menu:()=>ua.A,mobile:()=>da.A,more:()=>va.A,moreHorizontal:()=>pa.A,moreHorizontalMobile:()=>ma.A,moreVertical:()=>ha.A,moveTo:()=>fa.A,navigation:()=>ga.A,next:()=>Xa.A,notAllowed:()=>wa.A,notFound:()=>ba.A,offline:()=>er.A,overlayText:()=>ya.A,page:()=>ka.A,pageBreak:()=>xa.A,pages:()=>Ea.A,paragraph:()=>Ca.A,payment:()=>ja.A,pencil:()=>Va.A,pending:()=>Aa.A,people:()=>za.A,percent:()=>Sa.A,pin:()=>Ha.A,pinSmall:()=>La.A,plugins:()=>Oa.A,plus:()=>Ba.A,plusCircle:()=>Ia.A,plusCircleFilled:()=>Na.A,positionCenter:()=>Pa.A,positionLeft:()=>Ra.A,positionRight:()=>Ma.A,post:()=>Ta.A,postAuthor:()=>Fa.A,postCategories:()=>Da.A,postComments:()=>Ua.A,postCommentsCount:()=>qa.A,postCommentsForm:()=>Za.A,postContent:()=>Ga.A,postDate:()=>Wa.A,postExcerpt:()=>$a.A,postFeaturedImage:()=>Ja.A,postList:()=>Ka.A,postTerms:()=>Qa.A,preformatted:()=>tr.A,previous:()=>Ya.A,published:()=>ar.A,pullLeft:()=>rr.A,pullRight:()=>or.A,pullquote:()=>nr.A,queryPagination:()=>lr.A,queryPaginationNext:()=>sr.A,queryPaginationNumbers:()=>ir.A,queryPaginationPrevious:()=>cr.A,quote:()=>ur.A,receipt:()=>dr.A,redo:()=>vr.A,removeBug:()=>pr.A,removeSubmenu:()=>mr.A,replace:()=>hr.A,reset:()=>fr.A,resizeCornerNE:()=>gr.A,reusableBlock:()=>wr.A,rotateLeft:()=>xr.A,rotateRight:()=>_r.A,row:()=>br.A,rss:()=>kr.A,scheduled:()=>Ar.A,search:()=>Er.A,seen:()=>Cr.A,send:()=>Sr.A,separator:()=>Pr.A,settings:()=>Rr.A,shadow:()=>Mr.A,share:()=>Vr.A,shield:()=>zr.A,shipping:()=>Ur.A,shortcode:()=>Hr.A,shuffle:()=>Lr.A,sidebar:()=>vo.A,sidesAll:()=>po.A,sidesAxial:()=>mo.A,sidesBottom:()=>ho.A,sidesHorizontal:()=>fo.A,sidesLeft:()=>go.A,sidesRight:()=>wo.A,sidesTop:()=>bo.A,sidesVertical:()=>yo.A,siteLogo:()=>Or.A,square:()=>qr.A,stack:()=>Nr.A,starEmpty:()=>Ir.A,starFilled:()=>Br.A,starHalf:()=>Tr.A,store:()=>Fr.A,stretchFullWidth:()=>Dr.A,stretchWide:()=>Zr.A,styles:()=>Gr.A,subscript:()=>Wr.A,superscript:()=>$r.A,swatch:()=>Jr.A,symbol:()=>yr.A,symbolFilled:()=>so.A,table:()=>ro.A,tableColumnAfter:()=>Kr.A,tableColumnBefore:()=>Qr.A,tableColumnDelete:()=>Yr.A,tableOfContents:()=>Xr.A,tableRowAfter:()=>eo.A,tableRowBefore:()=>to.A,tableRowDelete:()=>ao.A,tablet:()=>Eo.A,tag:()=>oo.A,termDescription:()=>io.A,textColor:()=>xo.A,textHorizontal:()=>_o.A,textVertical:()=>ko.A,thumbsDown:()=>no.A,thumbsUp:()=>lo.A,tip:()=>jo.A,title:()=>Co.A,tool:()=>Ao.A,trash:()=>So.A,trendingDown:()=>Po.A,trendingUp:()=>Ro.A,typography:()=>Mo.A,undo:()=>Vo.A,ungroup:()=>zo.A,unlock:()=>Ho.A,unseen:()=>jr.A,update:()=>Lo.A,upload:()=>Oo.A,verse:()=>No.A,video:()=>Io.A,warning:()=>D.A,widget:()=>Bo.A,wordpress:()=>To.A});var r=a(51113),o=a(13523),n=a(47920),l=a(74423),s=a(47894),i=a(56091),c=a(99710),u=a(5817),d=a(71241),v=a(46685),p=a(66955),m=a(4132),h=a(7474),f=a(71797),g=a(62510),w=a(2250),b=a(62599),y=a(1561),x=a(22593),_=a(29551),k=a(8701),E=a(4262),C=a(43804),j=a(96630),A=a(23726),S=a(57003),P=a(44525),R=a(23654),M=a(45955),V=a(53073),z=a(27375),H=a(4490),L=a(25877),O=a(28695),N=a(17913),I=a(92340),B=a(77711),T=a(67451),F=a(73718),D=a(23751),G=a(7267),U=a(83883),q=a(64969),Z=a(23823),W=a(68888),$=a(48690),J=a(29115),K=a(65437),Q=a(98248),Y=a(56469),X=a(69043),ee=a(10991),te=a(31249),ae=a(40199),re=a(48570),oe=a(67534),ne=a(44314),le=a(62800),se=a(12072),ie=a(92225),ce=a(37556),ue=a(56530),de=a(53496),ve=a(91338),pe=a(64092),me=a(26550),he=a(16994),fe=a(35432),ge=a(73800),we=a(84763),be=a(25780),ye=a(2751),xe=a(10637),_e=a(24995),ke=a(42004),Ee=a(93147),Ce=a(82268),je=a(93115),Ae=a(57189),Se=a(6291),Pe=a(69828),Re=a(86198),Me=a(37057),Ve=a(16307),ze=a(92687),He=a(42663),Le=a(53512),Oe=a(74117),Ne=a(18293),Ie=a(15433),Be=a(51517),Te=a(67448),Fe=a(7490),De=a(1135),Ge=a(3571),Ue=a(69992),qe=a(64125),Ze=a(89761),We=a(53730),$e=a(93346),Je=a(53117),Ke=a(34083),Qe=a(60996),Ye=a(70868),Xe=a(86707),et=a(89387),tt=a(60550),at=a(18701),rt=a(80145),ot=a(39662),nt=a(8679),lt=a(28541),st=a(84066),it=a(71651),ct=a(36844),ut=a(40693),dt=a(88576),vt=a(99577),pt=a(86794),mt=a(6835),ht=a(98732),ft=a(5429),gt=a(96925),wt=a(10748),bt=a(2453),yt=a(34259),xt=a(78329),_t=a(13400),kt=a(14365),Et=a(88074),Ct=a(95938),jt=a(19783),At=a(65545),St=a(53916),Pt=a(98339),Rt=a(51349),Mt=a(11177),Vt=a(35980),zt=a(96692),Ht=a(53057),Lt=a(99556),Ot=a(75911),Nt=a(59210),It=a(81037),Bt=a(72896),Tt=a(33602),Ft=a(95855),Dt=a(76277),Gt=a(65281),Ut=a(20757),qt=a(11871),Zt=a(41496),Wt=a(6055),$t=a(6002),Jt=a(10895),Kt=a(87603),Qt=a(35855),Yt=a(92011),Xt=a(62011),ea=a(19601),ta=a(84008),aa=a(7827),ra=a(47714),oa=a(23250),na=a(72525),la=a(50828),sa=a(21679),ia=a(83391),ca=a(8933),ua=a(78136),da=a(82065),va=a(57054),pa=a(28231),ma=a(42778),ha=a(31597),fa=a(22374),ga=a(81385),wa=a(18887),ba=a(11995),ya=a(43411),xa=a(78982),_a=a(77617),ka=a(59892),Ea=a(94299),Ca=a(70413),ja=a(95501),Aa=a(8436),Sa=a(13822),Pa=a(72816),Ra=a(96504),Ma=a(71643),Va=a(78938),za=a(15788),Ha=a(36304),La=a(83594),Oa=a(30435),Na=a(17809),Ia=a(73632),Ba=a(45459),Ta=a(69457),Fa=a(36037),Da=a(94706),Ga=a(41417),Ua=a(25816),qa=a(90754),Za=a(93803),Wa=a(76982),$a=a(88669),Ja=a(54424),Ka=a(30),Qa=a(5015),Ya=a(56026),Xa=a(64222),er=a(93512),tr=a(6584),ar=a(64609),rr=a(52812),or=a(78887),nr=a(31798),lr=a(13968),sr=a(58324),ir=a(79843),cr=a(57524),ur=a(91535),dr=a(49695),vr=a(86299),pr=a(81884),mr=a(5903),hr=a(36667),fr=a(84832),gr=a(32128),wr=a(40502),br=a(71743),yr=a(28687),xr=a(80828),_r=a(60503),kr=a(4335),Er=a(58535),Cr=a(58824),jr=a(52259),Ar=a(27268),Sr=a(67709),Pr=a(13976),Rr=a(20066),Mr=a(37759),Vr=a(80596),zr=a(65302),Hr=a(88944),Lr=a(77846),Or=a(11194),Nr=a(33371),Ir=a(61871),Br=a(77136),Tr=a(41137),Fr=a(45422),Dr=a(36111),Gr=a(29753),Ur=a(24233),qr=a(26992),Zr=a(46048),Wr=a(30838),$r=a(36935),Jr=a(30959),Kr=a(31181),Qr=a(13488),Yr=a(93664),Xr=a(27672),eo=a(51917),to=a(87504),ao=a(55104),ro=a(18495),oo=a(211),no=a(50347),lo=a(7598),so=a(97572),io=a(90254),co=a(96252),uo=a(4282),vo=a(37631),po=a(88305),mo=a(65483),ho=a(7731),fo=a(81808),go=a(25125),wo=a(94916),bo=a(88061),yo=a(37870),xo=a(43886),_o=a(90153),ko=a(7583),Eo=a(21955),Co=a(11269),jo=a(35170),Ao=a(71041),So=a(76673),Po=a(36707),Ro=a(92614),Mo=a(74426),Vo=a(95789),zo=a(68113),Ho=a(375),Lo=a(83822),Oo=a(7326),No=a(43610),Io=a(70396),Bo=a(5559),To=a(94648)},13523:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18.5 5.5V8H20V5.5h2.5V4H20V1.5h-1.5V4H16v1.5h2.5zM12 4H6a2 2 0 00-2 2v12a2 2 0 002 2h12a2 2 0 002-2v-6h-1.5v6a.5.5 0 01-.5.5H6a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5h6V4z"})})},47920:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M2 12c0 3.6 2.4 5.5 6 5.5h.5V19l3-2.5-3-2.5v2H8c-2.5 0-4.5-1.5-4.5-4s2-4.5 4.5-4.5h3.5V6H8c-3.6 0-6 2.4-6 6zm19.5-1h-8v1.5h8V11zm0 5h-8v1.5h8V16zm0-10h-8v1.5h8V6z"})})},74423:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M18.5 5.5V8H20V5.5H22.5V4H20V1.5H18.5V4H16V5.5H18.5ZM13.9624 4H6C4.89543 4 4 4.89543 4 6V18C4 19.1046 4.89543 20 6 20H18C19.1046 20 20 19.1046 20 18V10.0391H18.5V18C18.5 18.2761 18.2761 18.5 18 18.5H10L10 10.4917L16.4589 10.5139L16.4641 9.01389L5.5 8.97618V6C5.5 5.72386 5.72386 5.5 6 5.5H13.9624V4ZM5.5 10.4762V18C5.5 18.2761 5.72386 18.5 6 18.5H8.5L8.5 10.4865L5.5 10.4762Z"})})},47894:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7.5 5.5h9V4h-9v1.5Zm-3.5 7h16V11H4v1.5Zm3.5 7h9V18h-9v1.5Z"})})},56091:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 12.8h16v-1.5H4v1.5zm0 7h12.4v-1.5H4v1.5zM4 4.3v1.5h16V4.3H4z"})})},99710:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M13 5.5H4V4h9v1.5Zm7 7H4V11h16v1.5Zm-7 7H4V18h9v1.5Z"})})},5817:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 5.5H5V4h14v1.5ZM19 20H5v-1.5h14V20ZM5 9h14v6H5V9Z"})})},71241:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11.111 5.5H20V4h-8.889v1.5ZM4 12.5h16V11H4v1.5Zm7.111 7H20V18h-8.889v1.5Z"})})},46685:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M11.934 7.406a1 1 0 0 0 .914.594H19a.5.5 0 0 1 .5.5v9a.5.5 0 0 1-.5.5H5a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5h5.764a.5.5 0 0 1 .447.276l.723 1.63Zm1.064-1.216a.5.5 0 0 0 .462.31H19a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h5.764a2 2 0 0 1 1.789 1.106l.445 1.084ZM8.5 10.5h7V12h-7v-1.5Zm7 3.5h-7v1.5h7V14Z"})})},4132:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M10 18h8v-8h-1.5v5.5L7 6 6 7l9.5 9.5H10V18Z"})})},66955:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m16.5 13.5-3.7 3.7V4h-1.5v13.2l-3.8-3.7-1 1 5.5 5.6 5.5-5.6z"})})},7474:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20 11.2H6.8l3.7-3.7-1-1L3.9 12l5.6 5.5 1-1-3.7-3.7H20z"})})},71797:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m14.5 6.5-1 1 3.7 3.7H4v1.6h13.2l-3.7 3.7 1 1 5.6-5.5z"})})},2250:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M14 6H6v8h1.5V8.5L17 18l1-1-9.5-9.5H14V6Z"})})},62510:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 3.9 6.5 9.5l1 1 3.8-3.7V20h1.5V6.8l3.7 3.7 1-1z"})})},1561:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18.5 5.5h-13c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2v-9c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5h-13c-.3 0-.5-.2-.5-.5v-9c0-.3.2-.5.5-.5h13c.3 0 .5.2.5.5v9zM6.5 12H8v-2h2V8.5H6.5V12zm9.5 2h-2v1.5h3.5V12H16v2z"})})},62599:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M12.5939 21C14.1472 21 16.1269 20.5701 17.0711 20.1975L16.6447 18.879C16.0964 19.051 14.3299 19.6242 12.6548 19.6242C7.4467 19.6242 4.67513 16.8726 4.67513 12C4.67513 7.21338 7.50762 4.34713 12.2893 4.34713C17.132 4.34713 19.4162 7.55732 19.4162 10.7675C19.4162 14.035 19.0508 15.4968 17.4975 15.4968C16.5838 15.4968 16.0964 14.7803 16.0964 13.9777V7.5H14.4822V8.30255H14.3909C14.1777 7.67198 12.9898 7.12739 11.467 7.2707C9.18274 7.5 7.4467 9.27707 7.4467 11.8567C7.4467 14.5796 8.81726 16.672 11.467 16.758C13.203 16.8153 14.1168 16.0127 14.4822 15.1815H14.5736C14.7563 16.414 16.401 16.8439 17.467 16.8439C20.6954 16.8439 21 13.5764 21 10.7962C21 6.86943 18.0761 3 12.3807 3C6.50254 3 3 6.3535 3 11.9427C3 17.7325 6.38071 21 12.5939 21ZM11.7107 15.2962C9.73096 15.2962 9.03046 13.6051 9.03046 11.7707C9.03046 10.1083 10.0355 8.67516 11.7716 8.67516C13.599 8.67516 14.5736 9.36306 14.5736 11.7707C14.5736 14.1497 13.7513 15.2962 11.7107 15.2962Z"})})},22593:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17.7 4.3c-1.2 0-2.8 0-3.8 1-.6.6-.9 1.5-.9 2.6V14c-.6-.6-1.5-1-2.5-1C8.6 13 7 14.6 7 16.5S8.6 20 10.5 20c1.5 0 2.8-1 3.3-2.3.5-.8.7-1.8.7-2.5V7.9c0-.7.2-1.2.5-1.6.6-.6 1.8-.6 2.8-.6h.3V4.3h-.4z"})})},29551:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M11.53 4.47a.75.75 0 1 0-1.06 1.06l8 8a.75.75 0 1 0 1.06-1.06l-8-8Zm5 1a.75.75 0 1 0-1.06 1.06l2 2a.75.75 0 1 0 1.06-1.06l-2-2Zm-11.06 10a.75.75 0 0 1 1.06 0l2 2a.75.75 0 1 1-1.06 1.06l-2-2a.75.75 0 0 1 0-1.06Zm.06-5a.75.75 0 0 0-1.06 1.06l8 8a.75.75 0 1 0 1.06-1.06l-8-8Zm-.06-3a.75.75 0 0 1 1.06 0l10 10a.75.75 0 1 1-1.06 1.06l-10-10a.75.75 0 0 1 0-1.06Zm3.06-2a.75.75 0 0 0-1.06 1.06l10 10a.75.75 0 1 0 1.06-1.06l-10-10Z"})})},8701:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5.5 12h1.75l-2.5 3-2.5-3H4a8 8 0 113.134 6.35l.907-1.194A6.5 6.5 0 105.5 12zm9.53 1.97l-2.28-2.28V8.5a.75.75 0 00-1.5 0V12a.747.747 0 00.218.529l1.282-.84-1.28.842 2.5 2.5a.75.75 0 101.06-1.061z"})})},43804:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"M13.969 4.39A5.088 5.088 0 0 0 12 4C9.2 4 7 6.2 7 9v2.5c0 1.353-.17 2.368-.976 3-.267.209-.602.376-1.024.5v1h14v-1c-.422-.124-.757-.291-1.024-.5-.806-.632-.976-1.647-.976-3V11c-.53 0-1.037-.103-1.5-.29v.79c0 .93.066 1.98.515 2.897l.053.103H7.932l.053-.103c.449-.917.515-1.967.515-2.897V9c0-1.972 1.528-3.5 3.5-3.5.43 0 .838.072 1.214.206.167-.488.425-.933.755-1.316Zm-3.961 13.618c0-.176.023-.346.065-.508h3.854A1.996 1.996 0 0 1 12 20a1.991 1.991 0 0 1-1.992-1.992Z"}),(0,o.jsx)(r.Circle,{cx:"17",cy:"7",r:"2.5"})]})},4262:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M17 11.5c0 1.353.17 2.368.976 3 .266.209.602.376 1.024.5v1H5v-1c.422-.124.757-.291 1.024-.5.806-.632.976-1.647.976-3V9c0-2.8 2.2-5 5-5s5 2.2 5 5v2.5ZM15.5 9v2.5c0 .93.066 1.98.515 2.897l.053.103H7.932a4.018 4.018 0 0 0 .053-.103c.449-.917.515-1.967.515-2.897V9c0-1.972 1.528-3.5 3.5-3.5s3.5 1.528 3.5 3.5Zm-5.492 9.008c0-.176.023-.346.065-.508h3.854A1.996 1.996 0 0 1 12 20c-1.1 0-1.992-.892-1.992-1.992Z"})})},96630:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 8h-1V6h-5v2h-2V6H6v2H5c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-8c0-1.1-.9-2-2-2zm.5 10c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5v-8c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v8z"})})},23726:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M8.95 11.25H4v1.5h4.95v4.5H13V18c0 1.1.9 2 2 2h3c1.1 0 2-.9 2-2v-3c0-1.1-.9-2-2-2h-3c-1.1 0-2 .9-2 2v.75h-2.55v-7.5H13V9c0 1.1.9 2 2 2h3c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3c-1.1 0-2 .9-2 2v.75H8.95v4.5ZM14.5 15v3c0 .3.2.5.5.5h3c.3 0 .5-.2.5-.5v-3c0-.3-.2-.5-.5-.5h-3c-.3 0-.5.2-.5.5Zm0-6V6c0-.3.2-.5.5-.5h3c.3 0 .5.2.5.5v3c0 .3-.2.5-.5.5h-3c-.3 0-.5-.2-.5-.5Z",clipRule:"evenodd"})})},57003:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5 4.5h14c.3 0 .5.2.5.5v3.5h-15V5c0-.3.2-.5.5-.5zm8 5.5h6.5v3.5H13V10zm-1.5 3.5h-7V10h7v3.5zm-7 5.5v-4h7v4.5H5c-.3 0-.5-.2-.5-.5zm14.5.5h-6V15h6.5v4c0 .3-.2.5-.5.5z"})})},44525:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"m6.6 15.6-1.2.8c.6.9 1.3 1.6 2.2 2.2l.8-1.2c-.7-.5-1.3-1.1-1.8-1.8zM5.5 12c0-.4 0-.9.1-1.3l-1.5-.3c0 .5-.1 1.1-.1 1.6s.1 1.1.2 1.6l1.5-.3c-.2-.4-.2-.9-.2-1.3zm11.9-3.6 1.2-.8c-.6-.9-1.3-1.6-2.2-2.2l-.8 1.2c.7.5 1.3 1.1 1.8 1.8zM5.3 7.6l1.2.8c.5-.7 1.1-1.3 1.8-1.8l-.7-1.3c-.9.6-1.7 1.4-2.3 2.3zm14.5 2.8-1.5.3c.1.4.1.8.1 1.3s0 .9-.1 1.3l1.5.3c.1-.5.2-1 .2-1.6s-.1-1.1-.2-1.6zM12 18.5c-.4 0-.9 0-1.3-.1l-.3 1.5c.5.1 1 .2 1.6.2s1.1-.1 1.6-.2l-.3-1.5c-.4.1-.9.1-1.3.1zm3.6-1.1.8 1.2c.9-.6 1.6-1.3 2.2-2.2l-1.2-.8c-.5.7-1.1 1.3-1.8 1.8zM10.4 4.2l.3 1.5c.4-.1.8-.1 1.3-.1s.9 0 1.3.1l.3-1.5c-.5-.1-1.1-.2-1.6-.2s-1.1.1-1.6.2z"})})},23654:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M5 5.5h14a.5.5 0 01.5.5v1.5a.5.5 0 01-.5.5H5a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM4 9.232A2 2 0 013 7.5V6a2 2 0 012-2h14a2 2 0 012 2v1.5a2 2 0 01-1 1.732V18a2 2 0 01-2 2H6a2 2 0 01-2-2V9.232zm1.5.268V18a.5.5 0 00.5.5h12a.5.5 0 00.5-.5V9.5h-13z",clipRule:"evenodd"})})},45955:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 20h8v-1.5H4V20zM18.9 3.5c-.6-.6-1.5-.6-2.1 0l-7.2 7.2c-.4-.1-.7 0-1.1.1-.5.2-1.5.7-1.9 2.2-.4 1.7-.8 2.2-1.1 2.7-.1.1-.2.3-.3.4l-.6 1.1H6c2 0 3.4-.4 4.7-1.4.8-.6 1.2-1.4 1.3-2.3 0-.3 0-.5-.1-.7L19 5.7c.5-.6.5-1.6-.1-2.2zM9.7 14.7c-.7.5-1.5.8-2.4 1 .2-.5.5-1.2.8-2.3.2-.6.4-1 .8-1.1.5-.1 1 .1 1.3.3.2.2.3.5.2.8 0 .3-.1.9-.7 1.3z"})})},53073:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6.13 5.5l1.926 1.927A4.975 4.975 0 007.025 10H5v1.5h2V13H5v1.5h2.1a5.002 5.002 0 009.8 0H19V13h-2v-1.5h2V10h-2.025a4.979 4.979 0 00-1.167-2.74l1.76-1.76-1.061-1.06-1.834 1.834A4.977 4.977 0 0012 5.5c-1.062 0-2.046.33-2.855.895L7.19 4.44 6.13 5.5zm2.37 5v3a3.5 3.5 0 107 0v-3a3.5 3.5 0 10-7 0z",fillRule:"evenodd",clipRule:"evenodd"})})},27375:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M8 12.5h8V11H8v1.5Z M19 6.5H5a2 2 0 0 0-2 2V15a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V8.5a2 2 0 0 0-2-2ZM5 8h14a.5.5 0 0 1 .5.5V15a.5.5 0 0 1-.5.5H5a.5.5 0 0 1-.5-.5V8.5A.5.5 0 0 1 5 8Z"})})},4490:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M14.5 17.5H9.5V16H14.5V17.5Z M14.5 8H9.5V6.5H14.5V8Z M7 3.5H17C18.1046 3.5 19 4.39543 19 5.5V9C19 10.1046 18.1046 11 17 11H7C5.89543 11 5 10.1046 5 9V5.5C5 4.39543 5.89543 3.5 7 3.5ZM17 5H7C6.72386 5 6.5 5.22386 6.5 5.5V9C6.5 9.27614 6.72386 9.5 7 9.5H17C17.2761 9.5 17.5 9.27614 17.5 9V5.5C17.5 5.22386 17.2761 5 17 5Z M7 13H17C18.1046 13 19 13.8954 19 15V18.5C19 19.6046 18.1046 20.5 17 20.5H7C5.89543 20.5 5 19.6046 5 18.5V15C5 13.8954 5.89543 13 7 13ZM17 14.5H7C6.72386 14.5 6.5 14.7239 6.5 15V18.5C6.5 18.7761 6.72386 19 7 19H17C17.2761 19 17.5 18.7761 17.5 18.5V15C17.5 14.7239 17.2761 14.5 17 14.5Z"})})},25877:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7h15v12zM9 10H7v2h2v-2zm0 4H7v2h2v-2zm4-4h-2v2h2v-2zm4 0h-2v2h2v-2zm-4 4h-2v2h2v-2zm4 0h-2v2h2v-2z"})})},28695:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M12 21C16.9706 21 21 16.9706 21 12C21 7.02944 16.9706 3 12 3C7.02944 3 3 7.02944 3 12C3 16.9706 7.02944 21 12 21ZM15.5303 8.46967C15.8232 8.76256 15.8232 9.23744 15.5303 9.53033L13.0607 12L15.5303 14.4697C15.8232 14.7626 15.8232 15.2374 15.5303 15.5303C15.2374 15.8232 14.7626 15.8232 14.4697 15.5303L12 13.0607L9.53033 15.5303C9.23744 15.8232 8.76256 15.8232 8.46967 15.5303C8.17678 15.2374 8.17678 14.7626 8.46967 14.4697L10.9393 12L8.46967 9.53033C8.17678 9.23744 8.17678 8.76256 8.46967 8.46967C8.76256 8.17678 9.23744 8.17678 9.53033 8.46967L12 10.9393L14.4697 8.46967C14.7626 8.17678 15.2374 8.17678 15.5303 8.46967Z"})})},17913:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M6 5.5h12a.5.5 0 0 1 .5.5v12a.5.5 0 0 1-.5.5H6a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5ZM4 6a2 2 0 0 1 2-2h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6Zm4 10h2v-1.5H8V16Zm5 0h-2v-1.5h2V16Zm1 0h2v-1.5h-2V16Z"})})},92340:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M12 9.2c-2.2 0-3.9 1.8-3.9 4s1.8 4 3.9 4 4-1.8 4-4-1.8-4-4-4zm0 6.5c-1.4 0-2.4-1.1-2.4-2.5s1.1-2.5 2.4-2.5 2.5 1.1 2.5 2.5-1.1 2.5-2.5 2.5zM20.2 8c-.1 0-.3 0-.5-.1l-2.5-.8c-.4-.1-.8-.4-1.1-.8l-1-1.5c-.4-.5-1-.9-1.7-.9h-2.9c-.6.1-1.2.4-1.6 1l-1 1.5c-.3.3-.6.6-1.1.7l-2.5.8c-.2.1-.4.1-.6.1-1 .2-1.7.9-1.7 1.9v8.3c0 1 .9 1.9 2 1.9h16c1.1 0 2-.8 2-1.9V9.9c0-1-.7-1.7-1.8-1.9zm.3 10.1c0 .2-.2.4-.5.4H4c-.3 0-.5-.2-.5-.4V9.9c0-.1.2-.3.5-.4.2 0 .5-.1.8-.2l2.5-.8c.7-.2 1.4-.6 1.8-1.3l1-1.5c.1-.1.2-.2.4-.2h2.9c.2 0 .3.1.4.2l1 1.5c.4.7 1.1 1.1 1.9 1.4l2.5.8c.3.1.6.1.8.2.3 0 .4.2.4.4v8.1z"})})},77711:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M14 5H4c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm.5 12c0 .3-.2.5-.5.5H4c-.3 0-.5-.2-.5-.5V7c0-.3.2-.5.5-.5h10c.3 0 .5.2.5.5v10zm2.5-7v4l5 3V7l-5 3zm3.5 4.4l-2-1.2v-2.3l2-1.2v4.7z"})})},67451:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M6 5.5h3a.5.5 0 01.5.5v3a.5.5 0 01-.5.5H6a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM4 6a2 2 0 012-2h3a2 2 0 012 2v3a2 2 0 01-2 2H6a2 2 0 01-2-2V6zm11-.5h3a.5.5 0 01.5.5v3a.5.5 0 01-.5.5h-3a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM13 6a2 2 0 012-2h3a2 2 0 012 2v3a2 2 0 01-2 2h-3a2 2 0 01-2-2V6zm5 8.5h-3a.5.5 0 00-.5.5v3a.5.5 0 00.5.5h3a.5.5 0 00.5-.5v-3a.5.5 0 00-.5-.5zM15 13a2 2 0 00-2 2v3a2 2 0 002 2h3a2 2 0 002-2v-3a2 2 0 00-2-2h-3zm-9 1.5h3a.5.5 0 01.5.5v3a.5.5 0 01-.5.5H6a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5zM4 15a2 2 0 012-2h3a2 2 0 012 2v3a2 2 0 01-2 2H6a2 2 0 01-2-2v-3z",fillRule:"evenodd",clipRule:"evenodd"})})},23751:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4ZM12.75 8V13H11.25V8H12.75ZM12.75 14.5V16H11.25V14.5H12.75Z"})})},73718:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-.75 12v-1.5h1.5V16h-1.5Zm0-8v5h1.5V8h-1.5Z"})})},7267:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M11.25 5h1.5v15h-1.5V5zM6 10h1.5v10H6V10zm12 4h-1.5v6H18v-6z",clipRule:"evenodd"})})},83883:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})})},23823:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"m15.99 10.889-3.988 3.418-3.988-3.418.976-1.14 3.012 2.582 3.012-2.581.976 1.139Z"})})},64969:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"})})},48690:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m13.1 16-3.4-4 3.4-4 1.1 1-2.6 3 2.6 3-1.1 1z"})})},68888:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"})})},65437:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M10.8622 8.04053L14.2805 12.0286L10.8622 16.0167L9.72327 15.0405L12.3049 12.0286L9.72327 9.01672L10.8622 8.04053Z"})})},29115:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"})})},56469:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m12 20-4.5-3.6-.9 1.2L12 22l5.5-4.4-.9-1.2L12 20zm0-16 4.5 3.6.9-1.2L12 2 6.5 6.4l.9 1.2L12 4z"})})},98248:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M6.5 12.4L12 8l5.5 4.4-.9 1.2L12 10l-4.5 3.6-1-1.2z"})})},69043:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M20 6H4c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5H4c-.3 0-.5-.2-.5-.5V8c0-.3.2-.5.5-.5h16c.3 0 .5.2.5.5v9zM10 10H8v2h2v-2zm-5 2h2v-2H5v2zm8-2h-2v2h2v-2zm-5 6h8v-2H8v2zm6-4h2v-2h-2v2zm3 0h2v-2h-2v2zm0 4h2v-2h-2v2zM5 16h2v-2H5v2z"})})},31249:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})})},10991:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m13.06 12 6.47-6.47-1.06-1.06L12 10.94 5.53 4.47 4.47 5.53 10.94 12l-6.47 6.47 1.06 1.06L12 13.06l6.47 6.47 1.06-1.06L13.06 12Z"})})},40199:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.3 10.1002C17.3 7.6002 15.2 5.7002 12.5 5.7002C10.3 5.7002 8.4 7.1002 7.9 9.0002H7.7C5.7 9.0002 4 10.7002 4 12.8002C4 14.9002 5.7 16.6002 7.7 16.6002V15.2002C6.5 15.2002 5.5 14.1002 5.5 12.9002C5.5 11.7002 6.5 10.5002 7.7 10.5002H9L9.3 9.4002C9.7 8.1002 11 7.2002 12.5 7.2002C14.3 7.2002 15.8 8.5002 15.8 10.1002V11.4002L17.1 11.6002C17.9 11.7002 18.5 12.5002 18.5 13.4002C18.5 14.4002 17.7 15.2002 16.8 15.2002H16.5V16.6002H16.7C18.5 16.6002 19.9 15.1002 19.9 13.3002C20 11.7002 18.8 10.4002 17.3 10.1002Z M9.8806 13.7576L8.81995 14.8182L12.0019 18.0002L15.1851 14.8171L14.1244 13.7564L12.7551 15.1257L12.7551 10.0002L11.2551 10.0002V15.1321L9.8806 13.7576Z"})})},48570:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.3 10.1C17.3 7.60001 15.2 5.70001 12.5 5.70001C10.3 5.70001 8.4 7.10001 7.9 9.00001H7.7C5.7 9.00001 4 10.7 4 12.8C4 14.9 5.7 16.6 7.7 16.6H9.5V15.2H7.7C6.5 15.2 5.5 14.1 5.5 12.9C5.5 11.7 6.5 10.5 7.7 10.5H9L9.3 9.40001C9.7 8.10001 11 7.20001 12.5 7.20001C14.3 7.20001 15.8 8.50001 15.8 10.1V11.4L17.1 11.6C17.9 11.7 18.5 12.5 18.5 13.4C18.5 14.4 17.7 15.2 16.8 15.2H14.5V16.6H16.7C18.5 16.6 19.9 15.1 19.9 13.3C20 11.7 18.8 10.4 17.3 10.1Z M14.1245 14.2426L15.1852 13.182L12.0032 10L8.82007 13.1831L9.88072 14.2438L11.25 12.8745V18H12.75V12.8681L14.1245 14.2426Z"})})},67534:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.3 10.1c0-2.5-2.1-4.4-4.8-4.4-2.2 0-4.1 1.4-4.6 3.3h-.2C5.7 9 4 10.7 4 12.8c0 2.1 1.7 3.8 3.7 3.8h9c1.8 0 3.2-1.5 3.2-3.3.1-1.6-1.1-2.9-2.6-3.2zm-.5 5.1h-9c-1.2 0-2.2-1.1-2.2-2.3s1-2.4 2.2-2.4h1.3l.3-1.1c.4-1.3 1.7-2.2 3.2-2.2 1.8 0 3.3 1.3 3.3 2.9v1.3l1.3.2c.8.1 1.4.9 1.4 1.8-.1 1-.9 1.8-1.8 1.8z"})})},44314:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M20.8 10.7l-4.3-4.3-1.1 1.1 4.3 4.3c.1.1.1.3 0 .4l-4.3 4.3 1.1 1.1 4.3-4.3c.7-.8.7-1.9 0-2.6zM4.2 11.8l4.3-4.3-1-1-4.3 4.3c-.7.7-.7 1.8 0 2.5l4.3 4.3 1.1-1.1-4.3-4.3c-.2-.1-.2-.3-.1-.4z"})})},62800:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M10.289 4.836A1 1 0 0111.275 4h1.306a1 1 0 01.987.836l.244 1.466c.787.26 1.503.679 2.108 1.218l1.393-.522a1 1 0 011.216.437l.653 1.13a1 1 0 01-.23 1.273l-1.148.944a6.025 6.025 0 010 2.435l1.149.946a1 1 0 01.23 1.272l-.653 1.13a1 1 0 01-1.216.437l-1.394-.522c-.605.54-1.32.958-2.108 1.218l-.244 1.466a1 1 0 01-.987.836h-1.306a1 1 0 01-.986-.836l-.244-1.466a5.995 5.995 0 01-2.108-1.218l-1.394.522a1 1 0 01-1.217-.436l-.653-1.131a1 1 0 01.23-1.272l1.149-.946a6.026 6.026 0 010-2.435l-1.148-.944a1 1 0 01-.23-1.272l.653-1.131a1 1 0 011.217-.437l1.393.522a5.994 5.994 0 012.108-1.218l.244-1.466zM14.929 12a3 3 0 11-6 0 3 3 0 016 0z",clipRule:"evenodd"})})},12072:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17.2 10.9c-.5-1-1.2-2.1-2.1-3.2-.6-.9-1.3-1.7-2.1-2.6L12 4l-1 1.1c-.6.9-1.3 1.7-2 2.6-.8 1.2-1.5 2.3-2 3.2-.6 1.2-1 2.2-1 3 0 3.4 2.7 6.1 6.1 6.1s6.1-2.7 6.1-6.1c0-.8-.3-1.8-1-3zm-5.1 7.6c-2.5 0-4.6-2.1-4.6-4.6 0-.3.1-1 .8-2.3.5-.9 1.1-1.9 2-3.1.7-.9 1.3-1.7 1.8-2.3.7.8 1.3 1.6 1.8 2.3.8 1.1 1.5 2.2 2 3.1.7 1.3.8 2 .8 2.3 0 2.5-2.1 4.6-4.6 4.6z"})})},92225:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 6H6c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zM6 17.5c-.3 0-.5-.2-.5-.5V8c0-.3.2-.5.5-.5h3v10H6zm13.5-.5c0 .3-.2.5-.5.5h-3v-10h3c.3 0 .5.2.5.5v9z"})})},37556:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M15 7.5h-5v10h5v-10Zm1.5 0v10H19a.5.5 0 0 0 .5-.5V8a.5.5 0 0 0-.5-.5h-2.5ZM6 7.5h2.5v10H6a.5.5 0 0 1-.5-.5V8a.5.5 0 0 1 .5-.5ZM6 6h13a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2Z"})})},64092:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M7.25 16.437a6.5 6.5 0 1 1 9.5 0V16A2.75 2.75 0 0 0 14 13.25h-4A2.75 2.75 0 0 0 7.25 16v.437Zm1.5 1.193a6.47 6.47 0 0 0 3.25.87 6.47 6.47 0 0 0 3.25-.87V16c0-.69-.56-1.25-1.25-1.25h-4c-.69 0-1.25.56-1.25 1.25v1.63ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm10-2a2 2 0 1 1-4 0 2 2 0 0 1 4 0Z",clipRule:"evenodd"})})},26550:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:[(0,o.jsx)(r.Path,{d:"M18 4H6c-1.1 0-2 .9-2 2v12.9c0 .6.5 1.1 1.1 1.1.3 0 .5-.1.8-.3L8.5 17H18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5H7.9l-2.4 2.4V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v9z",fillRule:"evenodd",clipRule:"evenodd"}),(0,o.jsx)(r.Path,{d:"M15 15V15C15 13.8954 14.1046 13 13 13L11 13C9.89543 13 9 13.8954 9 15V15",fillRule:"evenodd",clipRule:"evenodd"}),(0,o.jsx)(r.Circle,{cx:"12",cy:"9",r:"2",fillRule:"evenodd",clipRule:"evenodd"})]})},16994:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M6.68822 16.625L5.5 17.8145L5.5 5.5L18.5 5.5L18.5 16.625L6.68822 16.625ZM7.31 18.125L19 18.125C19.5523 18.125 20 17.6773 20 17.125L20 5C20 4.44772 19.5523 4 19 4H5C4.44772 4 4 4.44772 4 5V19.5247C4 19.8173 4.16123 20.086 4.41935 20.2237C4.72711 20.3878 5.10601 20.3313 5.35252 20.0845L7.31 18.125ZM16 9.99997H8V8.49997H16V9.99997ZM8 14H13V12.5H8V14Z"})})},73800:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"m6.249 11.065.44-.44h3.186l-1.5 1.5H7.31l-1.957 1.96A.792.792 0 0 1 4 13.524V5a1 1 0 0 1 1-1h8a1 1 0 0 1 1 1v1.5L12.5 8V5.5h-7v6.315l.749-.75ZM20 19.75H7v-1.5h13v1.5Zm0-12.653-8.967 9.064L8 17l.867-2.935L17.833 5 20 7.097Z"})})},35432:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M6.68822 10.625L6.24878 11.0649L5.5 11.8145L5.5 5.5L12.5 5.5V8L14 6.5V5C14 4.44772 13.5523 4 13 4H5C4.44772 4 4 4.44771 4 5V13.5247C4 13.8173 4.16123 14.086 4.41935 14.2237C4.72711 14.3878 5.10601 14.3313 5.35252 14.0845L7.31 12.125H8.375L9.875 10.625H7.31H6.68822ZM14.5605 10.4983L11.6701 13.75H16.9975C17.9963 13.75 18.7796 14.1104 19.3553 14.7048C19.9095 15.2771 20.2299 16.0224 20.4224 16.7443C20.7645 18.0276 20.7543 19.4618 20.7487 20.2544C20.7481 20.345 20.7475 20.4272 20.7475 20.4999L19.2475 20.5001C19.2475 20.4191 19.248 20.3319 19.2484 20.2394V20.2394C19.2526 19.4274 19.259 18.2035 18.973 17.1307C18.8156 16.5401 18.586 16.0666 18.2778 15.7483C17.9909 15.4521 17.5991 15.25 16.9975 15.25H11.8106L14.5303 17.9697L13.4696 19.0303L8.96956 14.5303L13.4394 9.50171L14.5605 10.4983Z"})})},91338:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18 4H6c-1.1 0-2 .9-2 2v12.9c0 .6.5 1.1 1.1 1.1.3 0 .5-.1.8-.3L8.5 17H18c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5H7.9l-2.4 2.4V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v9z"})})},84763:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",fillRule:"evenodd",children:(0,o.jsx)(r.Path,{d:"M19.53 4.47a.75.75 0 0 1 0 1.06L17.06 8l.77.769a3.155 3.155 0 0 1 .685 3.439 3.15 3.15 0 0 1-.685 1.022v.001L13.23 17.83v.001a3.15 3.15 0 0 1-4.462 0L8 17.06l-2.47 2.47a.75.75 0 0 1-1.06-1.06L6.94 16l-.77-.769a3.154 3.154 0 0 1-.685-3.439 3.15 3.15 0 0 1 .685-1.023l4.599-4.598a3.152 3.152 0 0 1 4.462 0l.769.768 2.47-2.47a.75.75 0 0 1 1.06 0Zm-2.76 7.7L15 13.94 10.06 9l1.771-1.77a1.65 1.65 0 0 1 2.338 0L16.77 9.83a1.649 1.649 0 0 1 0 2.338h-.001ZM13.94 15 9 10.06l-1.77 1.771a1.65 1.65 0 0 0 0 2.338l2.601 2.602a1.649 1.649 0 0 0 2.338 0v-.001L13.94 15Z"})})},53496:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.625 5.5h9.75c.069 0 .125.056.125.125v9.75a.125.125 0 0 1-.125.125h-9.75a.125.125 0 0 1-.125-.125v-9.75c0-.069.056-.125.125-.125ZM4 5.625C4 4.728 4.728 4 5.625 4h9.75C16.273 4 17 4.728 17 5.625v9.75c0 .898-.727 1.625-1.625 1.625h-9.75A1.625 1.625 0 0 1 4 15.375v-9.75Zm14.5 11.656v-9H20v9C20 18.8 18.77 20 17.251 20H6.25v-1.5h11.001c.69 0 1.249-.528 1.249-1.219Z"})})},56530:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5 4.5h11a.5.5 0 0 1 .5.5v11a.5.5 0 0 1-.5.5H5a.5.5 0 0 1-.5-.5V5a.5.5 0 0 1 .5-.5ZM3 5a2 2 0 0 1 2-2h11a2 2 0 0 1 2 2v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5Zm17 3v10.75c0 .69-.56 1.25-1.25 1.25H6v1.5h12.75a2.75 2.75 0 0 0 2.75-2.75V8H20Z"})})},25780:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18.7 3H5.3C4 3 3 4 3 5.3v13.4C3 20 4 21 5.3 21h13.4c1.3 0 2.3-1 2.3-2.3V5.3C21 4 20 3 18.7 3zm.8 15.7c0 .4-.4.8-.8.8H5.3c-.4 0-.8-.4-.8-.8V5.3c0-.4.4-.8.8-.8h6.2v8.9l2.5-3.1 2.5 3.1V4.5h2.2c.4 0 .8.4.8.8v13.4z"})})},2751:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16 11.2h-3.2V8h-1.6v3.2H8v1.6h3.2V16h1.6v-3.2H16z"})})},10637:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18 20v-2h2v-1.5H7.75a.25.25 0 0 1-.25-.25V4H6v2H4v1.5h2v8.75c0 .966.784 1.75 1.75 1.75h8.75v2H18ZM9.273 7.5h6.977a.25.25 0 0 1 .25.25v6.977H18V7.75A1.75 1.75 0 0 0 16.25 6H9.273v1.5Z"})})},24995:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M3.25 12a8.75 8.75 0 1117.5 0 8.75 8.75 0 01-17.5 0zM12 4.75a7.25 7.25 0 100 14.5 7.25 7.25 0 000-14.5zm-1.338 4.877c-.314.22-.412.452-.412.623 0 .171.098.403.412.623.312.218.783.377 1.338.377.825 0 1.605.233 2.198.648.59.414 1.052 1.057 1.052 1.852 0 .795-.461 1.438-1.052 1.852-.41.286-.907.486-1.448.582v.316a.75.75 0 01-1.5 0v-.316a3.64 3.64 0 01-1.448-.582c-.59-.414-1.052-1.057-1.052-1.852a.75.75 0 011.5 0c0 .171.098.403.412.623.312.218.783.377 1.338.377s1.026-.159 1.338-.377c.314-.22.412-.452.412-.623 0-.171-.098-.403-.412-.623-.312-.218-.783-.377-1.338-.377-.825 0-1.605-.233-2.198-.648-.59-.414-1.052-1.057-1.052-1.852 0-.795.461-1.438 1.052-1.852a3.64 3.64 0 011.448-.582V7.5a.75.75 0 011.5 0v.316c.54.096 1.039.296 1.448.582.59.414 1.052 1.057 1.052 1.852a.75.75 0 01-1.5 0c0-.171-.098-.403-.412-.623-.312-.218-.783-.377-1.338-.377s-1.026.159-1.338.377z"})})},42004:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 3.25a8.75 8.75 0 100 17.5 8.75 8.75 0 000-17.5zM4.75 12a7.25 7.25 0 1114.5 0 7.25 7.25 0 01-14.5 0zm9.195 1.944a2.75 2.75 0 01-4.066-.194h.621a.75.75 0 000-1.5H9.262a2.767 2.767 0 010-.5H11.5a.75.75 0 000-1.5H9.88a2.75 2.75 0 014.066-.194.75.75 0 001.06-1.061 4.25 4.25 0 00-6.88 1.255H7.5a.75.75 0 000 1.5h.258c-.01.166-.01.334 0 .5H7.5a.75.75 0 000 1.5h.626a4.25 4.25 0 006.88 1.255.75.75 0 00-1.06-1.06z"})})},93147:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M3.25 12a8.75 8.75 0 1117.5 0 8.75 8.75 0 01-17.5 0zM12 4.75a7.25 7.25 0 100 14.5 7.25 7.25 0 000-14.5zm.25 4c-.787 0-1.425.638-1.425 1.425 0 .058.014.147.069.3.04.113.088.223.147.36a26.094 26.094 0 01.173.415H12.5a.75.75 0 010 1.5h-.953c.002.047.003.095.003.144 0 .617-.236 1.168-.511 1.606h3.386a.75.75 0 010 1.5H9.35a.75.75 0 01-.452-1.349l.007-.005a4.417 4.417 0 00.596-.581c.328-.39.549-.806.549-1.171 0-.05-.002-.097-.004-.144H9.5a.75.75 0 010-1.5h.088a5.875 5.875 0 01-.106-.27 2.382 2.382 0 01-.157-.805 2.925 2.925 0 015.637-1.097.75.75 0 01-1.39.563 1.426 1.426 0 00-1.322-.891zm-3.35 5.9l.45.6-.45-.6z"})})},77617:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12.5 14.5h-1V16h1c2.2 0 4-1.8 4-4s-1.8-4-4-4h-1v1.5h1c1.4 0 2.5 1.1 2.5 2.5s-1.1 2.5-2.5 2.5zm-4 1.5v-1.5h-1C6.1 14.5 5 13.4 5 12s1.1-2.5 2.5-2.5h1V8h-1c-2.2 0-4 1.8-4 4s1.8 4 4 4h1zm-1-3.2h5v-1.5h-5v1.5zM18 4H9c-1.1 0-2 .9-2 2v.5h1.5V6c0-.3.2-.5.5-.5h9c.3 0 .5.2.5.5v12c0 .3-.2.5-.5.5H9c-.3 0-.5-.2-.5-.5v-.5H7v.5c0 1.1.9 2 2 2h9c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2z"})})},82268:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 20h9v-1.5H4V20zm0-5.5V16h16v-1.5H4zm.8-4l.7.7 2-2V12h1V9.2l2 2 .7-.7-2-2H12v-1H9.2l2-2-.7-.7-2 2V4h-1v2.8l-2-2-.7.7 2 2H4v1h2.8l-2 2z"})})},93115:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20.5 16h-.7V8c0-1.1-.9-2-2-2H6.2c-1.1 0-2 .9-2 2v8h-.7c-.8 0-1.5.7-1.5 1.5h20c0-.8-.7-1.5-1.5-1.5zM5.7 8c0-.3.2-.5.5-.5h11.6c.3 0 .5.2.5.5v7.6H5.7V8z"})})},57189:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:[(0,o.jsx)(r.Path,{d:"M4 16h10v1.5H4V16Zm0-4.5h16V13H4v-1.5ZM10 7h10v1.5H10V7Z",fillRule:"evenodd",clipRule:"evenodd"}),(0,o.jsx)(r.Path,{d:"m4 5.25 4 2.5-4 2.5v-5Z"})]})},16307:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18 11.3l-1-1.1-4 4V3h-1.5v11.3L7 10.2l-1 1.1 6.2 5.8 5.8-5.8zm.5 3.7v3.5h-13V15H4v5h16v-5h-1.5z"})})},6291:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm8 4a4 4 0 0 0 4-4H8a4 4 0 0 0 4 4Z"})})},69828:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M8 7h2V5H8v2zm0 6h2v-2H8v2zm0 6h2v-2H8v2zm6-14v2h2V5h-2zm0 8h2v-2h-2v2zm0 6h2v-2h-2v2z"})})},86198:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM8.5 18.5H6c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h2.5v13zm10-.5c0 .3-.2.5-.5.5h-8v-13h8c.3 0 .5.2.5.5v12z"})})},37057:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-4 14.5H6c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h8v13zm4.5-.5c0 .3-.2.5-.5.5h-2.5v-13H18c.3 0 .5.2.5.5v12z"})})},92687:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=a(78938).A},42663:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M3 7c0-1.1.9-2 2-2h14a2 2 0 0 1 2 2v10a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V7Zm2-.5h14c.3 0 .5.2.5.5v1L12 13.5 4.5 7.9V7c0-.3.2-.5.5-.5Zm-.5 3.3V17c0 .3.2.5.5.5h14c.3 0 .5-.2.5-.5V9.8L12 15.4 4.5 9.8Z"})})},74117:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z"})})},53512:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19.5 4.5h-7V6h4.44l-5.97 5.97 1.06 1.06L18 7.06v4.44h1.5v-7Zm-13 1a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-3H17v3a.5.5 0 0 1-.5.5h-10a.5.5 0 0 1-.5-.5v-10a.5.5 0 0 1 .5-.5h3V5.5h-3Z"})})},18293:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12.848 8a1 1 0 0 1-.914-.594l-.723-1.63a.5.5 0 0 0-.447-.276H5a.5.5 0 0 0-.5.5v11.5a.5.5 0 0 0 .5.5h14a.5.5 0 0 0 .5-.5v-9A.5.5 0 0 0 19 8h-6.152Zm.612-1.5a.5.5 0 0 1-.462-.31l-.445-1.084A2 2 0 0 0 10.763 4H5a2 2 0 0 0-2 2v11.5a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-9a2 2 0 0 0-2-2h-5.54Z"})})},15433:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 4 4 19h16L12 4zm0 3.2 5.5 10.3H12V7.2z"})})},51517:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 6v12c0 1.1.9 2 2 2h3v-1.5H6c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h3V4H6c-1.1 0-2 .9-2 2zm7.2 16h1.5V2h-1.5v20zM15 5.5h1.5V4H15v1.5zm3.5.5H20c0-1.1-.9-2-2-2v1.5c.3 0 .5.2.5.5zm0 10.5H20v-2h-1.5v2zm0-3.5H20v-2h-1.5v2zm-.5 5.5V20c1.1 0 2-.9 2-2h-1.5c0 .3-.2.5-.5.5zM15 20h1.5v-1.5H15V20zm3.5-10.5H20v-2h-1.5v2z"})})},67448:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M2 11.2v1.5h20v-1.5H2zM5.5 6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v3H20V6c0-1.1-.9-2-2-2H6c-1.1 0-2 .9-2 2v3h1.5V6zm2 14h2v-1.5h-2V20zm3.5 0h2v-1.5h-2V20zm7-1.5V20c1.1 0 2-.9 2-2h-1.5c0 .3-.2.5-.5.5zm.5-2H20V15h-1.5v1.5zM5.5 18H4c0 1.1.9 2 2 2v-1.5c-.3 0-.5-.2-.5-.5zm0-3H4v1.5h1.5V15zm9 5h2v-1.5h-2V20z"})})},96252:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M18 5.5h-8v8h8.5V6a.5.5 0 00-.5-.5zm-9.5 8h-3V6a.5.5 0 01.5-.5h2.5v8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})})},7490:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M14.7 11.3c1-.6 1.5-1.6 1.5-3 0-2.3-1.3-3.4-4-3.4H7v14h5.8c1.4 0 2.5-.3 3.3-1 .8-.7 1.2-1.7 1.2-2.9.1-1.9-.8-3.1-2.6-3.7zm-5.1-4h2.3c.6 0 1.1.1 1.4.4.3.3.5.7.5 1.2s-.2 1-.5 1.2c-.3.3-.8.4-1.4.4H9.6V7.3zm4.6 9c-.4.3-1 .4-1.7.4H9.6v-3.9h2.9c.7 0 1.3.2 1.7.5.4.3.6.8.6 1.5s-.2 1.2-.6 1.5z"})})},1135:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7.1 6.8L3.1 18h1.6l1.1-3h4.3l1.1 3h1.6l-4-11.2H7.1zm-.8 6.8L8 8.9l1.7 4.7H6.3zm14.5-1.5c-.3-.6-.7-1.1-1.2-1.5-.6-.4-1.2-.6-1.9-.6-.5 0-.9.1-1.4.3-.4.2-.8.5-1.1.8V6h-1.4v12h1.3l.2-1c.2.4.6.6 1 .8.4.2.9.3 1.4.3.7 0 1.2-.2 1.8-.5.5-.4 1-.9 1.3-1.5.3-.6.5-1.3.5-2.1-.1-.6-.2-1.3-.5-1.9zm-1.7 4c-.4.5-.9.8-1.6.8s-1.2-.2-1.7-.7c-.4-.5-.7-1.2-.7-2.1 0-.9.2-1.6.7-2.1.4-.5 1-.7 1.7-.7s1.2.3 1.6.8c.4.5.6 1.2.6 2 .1.8-.2 1.4-.6 2z"})})},69992:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20 5.5H4V4H20V5.5ZM12 12.5H4V11H12V12.5ZM20 20V18.5H4V20H20ZM20.0303 9.03033L17.0607 12L20.0303 14.9697L18.9697 16.0303L15.4697 12.5303L14.9393 12L15.4697 11.4697L18.9697 7.96967L20.0303 9.03033Z"})})},3571:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 7.2v1.5h16V7.2H4zm8 8.6h8v-1.5h-8v1.5zm-8-3.5l3 3-3 3 1 1 4-4-4-4-1 1z"})})},64125:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12.5 5L10 19h1.9l2.5-14z"})})},53730:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 8.8h8.9V7.2H4v1.6zm0 7h8.9v-1.5H4v1.5zM18 13c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-3c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2z"})})},89761:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11.1 15.8H20v-1.5h-8.9v1.5zm0-8.6v1.5H20V7.2h-8.9zM6 13c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0-7c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})})},53117:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M3.8 15.8h8.9v-1.5H3.8v1.5zm0-7h8.9V7.2H3.8v1.6zm14.7-2.1V10h1V5.3l-2.2.7.3 1 .9-.3zm1.2 6.1c-.5-.6-1.2-.5-1.7-.4-.3.1-.5.2-.7.3l.1 1.1c.2-.2.5-.4.8-.5.3-.1.6 0 .7.1.2.3 0 .8-.2 1.1-.5.8-.9 1.6-1.4 2.5H20v-1h-.9c.3-.6.8-1.4.9-2.1 0-.3 0-.8-.3-1.1z"})})},93346:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11.1 15.8H20v-1.5h-8.9v1.5zm0-8.6v1.5H20V7.2h-8.9zM5 6.7V10h1V5.3L3.8 6l.4 1 .8-.3zm-.4 5.7c-.3.1-.5.2-.7.3l.1 1.1c.2-.2.5-.4.8-.5.3-.1.6 0 .7.1.2.3 0 .8-.2 1.1-.5.8-.9 1.6-1.4 2.5h2.7v-1h-1c.3-.6.8-1.4.9-2.1.1-.3 0-.8-.2-1.1-.5-.6-1.3-.5-1.7-.4z"})})},60996:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11 16.8c-.1-.1-.2-.3-.3-.5v-2.6c0-.9-.1-1.7-.3-2.2-.2-.5-.5-.9-.9-1.2-.4-.2-.9-.3-1.6-.3-.5 0-1 .1-1.5.2s-.9.3-1.2.6l.2 1.2c.4-.3.7-.4 1.1-.5.3-.1.7-.2 1-.2.6 0 1 .1 1.3.4.3.2.4.7.4 1.4-1.2 0-2.3.2-3.3.7s-1.4 1.1-1.4 2.1c0 .7.2 1.2.7 1.6.4.4 1 .6 1.8.6.9 0 1.7-.4 2.4-1.2.1.3.2.5.4.7.1.2.3.3.6.4.3.1.6.1 1.1.1h.1l.2-1.2h-.1c-.4.1-.6 0-.7-.1zM9.2 16c-.2.3-.5.6-.9.8-.3.1-.7.2-1.1.2-.4 0-.7-.1-.9-.3-.2-.2-.3-.5-.3-.9 0-.6.2-1 .7-1.3.5-.3 1.3-.4 2.5-.5v2zm10.6-3.9c-.3-.6-.7-1.1-1.2-1.5-.6-.4-1.2-.6-1.9-.6-.5 0-.9.1-1.4.3-.4.2-.8.5-1.1.8V6h-1.4v12h1.3l.2-1c.2.4.6.6 1 .8.4.2.9.3 1.4.3.7 0 1.2-.2 1.8-.5.5-.4 1-.9 1.3-1.5.3-.6.5-1.3.5-2.1-.1-.6-.2-1.3-.5-1.9zm-1.7 4c-.4.5-.9.8-1.6.8s-1.2-.2-1.7-.7c-.4-.5-.7-1.2-.7-2.1 0-.9.2-1.6.7-2.1.4-.5 1-.7 1.7-.7s1.2.3 1.6.8c.4.5.6 1.2.6 2s-.2 1.4-.6 2z"})})},34083:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M5.52 2h7.43c.55 0 1 .45 1 1s-.45 1-1 1h-1v13c0 .55-.45 1-1 1s-1-.45-1-1V5c0-.55-.45-1-1-1s-1 .45-1 1v12c0 .55-.45 1-1 1s-1-.45-1-1v-5.96h-.43C3.02 11.04 1 9.02 1 6.52S3.02 2 5.52 2zM14 14l5-4-5-4v8z"})})},86707:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20 5.5H4V4H20V5.5ZM12 12.5H4V11H12V12.5ZM20 20V18.5H4V20H20ZM15.4697 14.9697L18.4393 12L15.4697 9.03033L16.5303 7.96967L20.0303 11.4697L20.5607 12L20.0303 12.5303L16.5303 16.0303L15.4697 14.9697Z"})})},70868:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 7.2v1.5h16V7.2H4zm8 8.6h8v-1.5h-8v1.5zm-4-4.6l-4 4 4 4 1-1-3-3 3-3-1-1z"})})},89387:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M5.52 2h7.43c.55 0 1 .45 1 1s-.45 1-1 1h-1v13c0 .55-.45 1-1 1s-1-.45-1-1V5c0-.55-.45-1-1-1s-1 .45-1 1v12c0 .55-.45 1-1 1s-1-.45-1-1v-5.96h-.43C3.02 11.04 1 9.02 1 6.52S3.02 2 5.52 2zM19 6l-5 4 5 4V6zM5.52 2h7.43c.55 0 1 .45 1 1s-.45 1-1 1h-1v13c0 .55-.45 1-1 1s-1-.45-1-1V5c0-.55-.45-1-1-1s-1 .45-1 1v12c0 .55-.45 1-1 1s-1-.45-1-1v-5.96h-.43C3.02 11.04 1 9.02 1 6.52S3.02 2 5.52 2zM19 6l-5 4 5 4V6z"})})},60550:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9.1 9v-.5c0-.6.2-1.1.7-1.4.5-.3 1.2-.5 2-.5.7 0 1.4.1 2.1.3.7.2 1.4.5 2.1.9l.2-1.9c-.6-.3-1.2-.5-1.9-.7-.8-.1-1.6-.2-2.4-.2-1.5 0-2.7.3-3.6 1-.8.7-1.2 1.5-1.2 2.6V9h2zM20 12H4v1h8.3c.3.1.6.2.8.3.5.2.9.5 1.1.8.3.3.4.7.4 1.2 0 .7-.2 1.1-.8 1.5-.5.3-1.2.5-2.1.5-.8 0-1.6-.1-2.4-.3-.8-.2-1.5-.5-2.2-.8L7 18.1c.5.2 1.2.4 2 .6.8.2 1.6.3 2.4.3 1.7 0 3-.3 3.9-1 .9-.7 1.3-1.6 1.3-2.8 0-.9-.2-1.7-.7-2.2H20v-1z"})})},18701:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7 18v1h10v-1H7zm5-2c1.5 0 2.6-.4 3.4-1.2.8-.8 1.1-2 1.1-3.5V5H15v5.8c0 1.2-.2 2.1-.6 2.8-.4.7-1.2 1-2.4 1s-2-.3-2.4-1c-.4-.7-.6-1.6-.6-2.8V5H7.5v6.2c0 1.5.4 2.7 1.1 3.5.8.9 1.9 1.3 3.4 1.3z"})})},80145:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6.1 6.8L2.1 18h1.6l1.1-3h4.3l1.1 3h1.6l-4-11.2H6.1zm-.8 6.8L7 8.9l1.7 4.7H5.3zm15.1-.7c-.4-.5-.9-.8-1.6-1 .4-.2.7-.5.8-.9.2-.4.3-.9.3-1.4 0-.9-.3-1.6-.8-2-.6-.5-1.3-.7-2.4-.7h-3.5V18h4.2c1.1 0 2-.3 2.6-.8.6-.6 1-1.4 1-2.4-.1-.8-.3-1.4-.6-1.9zm-5.7-4.7h1.8c.6 0 1.1.1 1.4.4.3.2.5.7.5 1.3 0 .6-.2 1.1-.5 1.3-.3.2-.8.4-1.4.4h-1.8V8.2zm4 8c-.4.3-.9.5-1.5.5h-2.6v-3.8h2.6c1.4 0 2 .6 2 1.9.1.6-.1 1-.5 1.4z"})})},39662:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6 4a2 2 0 0 0-2 2v3h1.5V6a.5.5 0 0 1 .5-.5h3V4H6Zm3 14.5H6a.5.5 0 0 1-.5-.5v-3H4v3a2 2 0 0 0 2 2h3v-1.5Zm6 1.5v-1.5h3a.5.5 0 0 0 .5-.5v-3H20v3a2 2 0 0 1-2 2h-3Zm3-16a2 2 0 0 1 2 2v3h-1.5V6a.5.5 0 0 0-.5-.5h-3V4h3Z"})})},8679:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M10 17.5H14V16H10V17.5ZM6 6V7.5H18V6H6ZM8 12.5H16V11H8V12.5Z"})})},28541:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M16.375 4.5H4.625a.125.125 0 0 0-.125.125v8.254l2.859-1.54a.75.75 0 0 1 .68-.016l2.384 1.142 2.89-2.074a.75.75 0 0 1 .874 0l2.313 1.66V4.625a.125.125 0 0 0-.125-.125Zm.125 9.398-2.75-1.975-2.813 2.02a.75.75 0 0 1-.76.067l-2.444-1.17L4.5 14.583v1.792c0 .069.056.125.125.125h11.75a.125.125 0 0 0 .125-.125v-2.477ZM4.625 3C3.728 3 3 3.728 3 4.625v11.75C3 17.273 3.728 18 4.625 18h11.75c.898 0 1.625-.727 1.625-1.625V4.625C18 3.728 17.273 3 16.375 3H4.625ZM20 8v11c0 .69-.31 1-.999 1H6v1.5h13.001c1.52 0 2.499-.982 2.499-2.5V8H20Z",fillRule:"evenodd",clipRule:"evenodd"})})},84066:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 3.3c-4.8 0-8.8 3.9-8.8 8.8 0 4.8 3.9 8.8 8.8 8.8 4.8 0 8.8-3.9 8.8-8.8s-4-8.8-8.8-8.8zm6.5 5.5h-2.6C15.4 7.3 14.8 6 14 5c2 .6 3.6 2 4.5 3.8zm.7 3.2c0 .6-.1 1.2-.2 1.8h-2.9c.1-.6.1-1.2.1-1.8s-.1-1.2-.1-1.8H19c.2.6.2 1.2.2 1.8zM12 18.7c-1-.7-1.8-1.9-2.3-3.5h4.6c-.5 1.6-1.3 2.9-2.3 3.5zm-2.6-4.9c-.1-.6-.1-1.1-.1-1.8 0-.6.1-1.2.1-1.8h5.2c.1.6.1 1.1.1 1.8s-.1 1.2-.1 1.8H9.4zM4.8 12c0-.6.1-1.2.2-1.8h2.9c-.1.6-.1 1.2-.1 1.8 0 .6.1 1.2.1 1.8H5c-.2-.6-.2-1.2-.2-1.8zM12 5.3c1 .7 1.8 1.9 2.3 3.5H9.7c.5-1.6 1.3-2.9 2.3-3.5zM10 5c-.8 1-1.4 2.3-1.8 3.8H5.5C6.4 7 8 5.6 10 5zM5.5 15.3h2.6c.4 1.5 1 2.8 1.8 3.7-1.8-.6-3.5-2-4.4-3.7zM14 19c.8-1 1.4-2.2 1.8-3.7h2.6C17.6 17 16 18.4 14 19z"})})},71651:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m3 5c0-1.10457.89543-2 2-2h13.5c1.1046 0 2 .89543 2 2v13.5c0 1.1046-.8954 2-2 2h-13.5c-1.10457 0-2-.8954-2-2zm2-.5h6v6.5h-6.5v-6c0-.27614.22386-.5.5-.5zm-.5 8v6c0 .2761.22386.5.5.5h6v-6.5zm8 0v6.5h6c.2761 0 .5-.2239.5-.5v-6zm0-8v6.5h6.5v-6c0-.27614-.2239-.5-.5-.5z",fillRule:"evenodd",clipRule:"evenodd"})})},36844:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18 4h-7c-1.1 0-2 .9-2 2v3H6c-1.1 0-2 .9-2 2v7c0 1.1.9 2 2 2h7c1.1 0 2-.9 2-2v-3h3c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-4.5 14c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5v-7c0-.3.2-.5.5-.5h3V13c0 1.1.9 2 2 2h2.5v3zm0-4.5H11c-.3 0-.5-.2-.5-.5v-2.5H13c.3 0 .5.2.5.5v2.5zm5-.5c0 .3-.2.5-.5.5h-3V11c0-1.1-.9-2-2-2h-2.5V6c0-.3.2-.5.5-.5h7c.3 0 .5.2.5.5v7z"})})},40693:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M7 16.5h10V15H7v1.5zm0-9V9h10V7.5H7z"})})},4282:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18.5 10.5H10v8h8a.5.5 0 00.5-.5v-7.5zm-10 0h-3V18a.5.5 0 00.5.5h2.5v-8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})})},88576:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.6 7c-.6.9-1.5 1.7-2.6 2v1h2v7h2V7h-1.4zM11 11H7V7H5v10h2v-4h4v4h2V7h-2v4z"})})},99577:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9 11.1H5v-4H3v10h2v-4h4v4h2v-10H9v4zm8 4c.5-.4.6-.6 1.1-1.1.4-.4.8-.8 1.2-1.3.3-.4.6-.8.9-1.3.2-.4.3-.8.3-1.3 0-.4-.1-.9-.3-1.3-.2-.4-.4-.7-.8-1-.3-.3-.7-.5-1.2-.6-.5-.2-1-.2-1.5-.2-.4 0-.7 0-1.1.1-.3.1-.7.2-1 .3-.3.1-.6.3-.9.5-.3.2-.6.4-.8.7l1.2 1.2c.3-.3.6-.5 1-.7.4-.2.7-.3 1.2-.3s.9.1 1.3.4c.3.3.5.7.5 1.1 0 .4-.1.8-.4 1.1-.3.5-.6.9-1 1.2-.4.4-1 .9-1.6 1.4-.6.5-1.4 1.1-2.2 1.6v1.5h8v-2H17z"})})},86794:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9 11H5V7H3v10h2v-4h4v4h2V7H9v4zm11.3 1.7c-.4-.4-1-.7-1.6-.8v-.1c.6-.2 1.1-.5 1.5-.9.3-.4.5-.8.5-1.3 0-.4-.1-.8-.3-1.1-.2-.3-.5-.6-.8-.8-.4-.2-.8-.4-1.2-.5-.6-.1-1.1-.2-1.6-.2-.6 0-1.3.1-1.8.3s-1.1.5-1.6.9l1.2 1.4c.4-.2.7-.4 1.1-.6.3-.2.7-.3 1.1-.3.4 0 .8.1 1.1.3.3.2.4.5.4.8 0 .4-.2.7-.6.9-.7.3-1.5.5-2.2.4v1.6c.5 0 1 0 1.5.1.3.1.7.2 1 .3.2.1.4.2.5.4s.1.4.1.6c0 .3-.2.7-.5.8-.4.2-.9.3-1.4.3s-1-.1-1.4-.3c-.4-.2-.8-.4-1.2-.7L13 15.6c.5.4 1 .8 1.6 1 .7.3 1.5.4 2.3.4.6 0 1.1-.1 1.6-.2.4-.1.9-.2 1.3-.5.4-.2.7-.5.9-.9.2-.4.3-.8.3-1.2 0-.6-.3-1.1-.7-1.5z"})})},6835:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20 13V7h-3l-4 6v2h5v2h2v-2h1v-2h-1zm-2 0h-2.8L18 9v4zm-9-2H5V7H3v10h2v-4h4v4h2V7H9v4z"})})},98732:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9 11H5V7H3v10h2v-4h4v4h2V7H9v4zm11.7 1.2c-.2-.3-.5-.7-.8-.9-.3-.3-.7-.5-1.1-.6-.5-.1-.9-.2-1.4-.2-.2 0-.5.1-.7.1-.2.1-.5.1-.7.2l.1-1.9h4.3V7H14l-.3 5 1 .6.5-.2.4-.1c.1-.1.3-.1.4-.1h.5c.5 0 1 .1 1.4.4.4.2.6.7.6 1.1 0 .4-.2.8-.6 1.1-.4.3-.9.4-1.4.4-.4 0-.9-.1-1.3-.3-.4-.2-.7-.4-1.1-.7 0 0-1.1 1.4-1 1.5.5.4 1 .8 1.6 1 .7.3 1.5.4 2.3.4.5 0 1-.1 1.5-.3s.9-.4 1.3-.7c.4-.3.7-.7.9-1.1s.3-.9.3-1.4-.1-1-.3-1.4z"})})},5429:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20.7 12.4c-.2-.3-.4-.6-.7-.9s-.6-.5-1-.6c-.4-.2-.8-.2-1.2-.2-.5 0-.9.1-1.3.3s-.8.5-1.2.8c0-.5 0-.9.2-1.4l.6-.9c.2-.2.5-.4.8-.5.6-.2 1.3-.2 1.9 0 .3.1.6.3.8.5 0 0 1.3-1.3 1.3-1.4-.4-.3-.9-.6-1.4-.8-.6-.2-1.3-.3-2-.3-.6 0-1.1.1-1.7.4-.5.2-1 .5-1.4.9-.4.4-.8 1-1 1.6-.3.7-.4 1.5-.4 2.3s.1 1.5.3 2.1c.2.6.6 1.1 1 1.5.4.4.9.7 1.4.9 1 .3 2 .3 3 0 .4-.1.8-.3 1.2-.6.3-.3.6-.6.8-1 .2-.5.3-.9.3-1.4s-.1-.9-.3-1.3zm-2 2.1c-.1.2-.3.4-.4.5-.1.1-.3.2-.5.2-.2.1-.4.1-.6.1-.2.1-.5 0-.7-.1-.2 0-.3-.2-.5-.3-.1-.2-.3-.4-.4-.6-.2-.3-.3-.7-.3-1 .3-.3.6-.5 1-.7.3-.1.7-.2 1-.2.4 0 .8.1 1.1.3.3.3.4.7.4 1.1 0 .2 0 .5-.1.7zM9 11H5V7H3v10h2v-4h4v4h2V7H9v4z"})})},96925:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6 5V18.5911L12 13.8473L18 18.5911V5H6Z"})})},2453:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm-1 16v-2h2v2h-2zm2-3v-1.141A3.991 3.991 0 0016 10a4 4 0 00-8 0h2c0-1.103.897-2 2-2s2 .897 2 2-.897 2-2 2a1 1 0 00-1 1v2h2z"})})},10748:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 4.75a7.25 7.25 0 100 14.5 7.25 7.25 0 000-14.5zM3.25 12a8.75 8.75 0 1117.5 0 8.75 8.75 0 01-17.5 0zM12 8.75a1.5 1.5 0 01.167 2.99c-.465.052-.917.44-.917 1.01V14h1.5v-.845A3 3 0 109 10.25h1.5a1.5 1.5 0 011.5-1.5zM11.25 15v1.5h1.5V15h-1.5z"})})},14365:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M4.25 7A2.75 2.75 0 0 1 7 4.25h10A2.75 2.75 0 0 1 19.75 7v10A2.75 2.75 0 0 1 17 19.75H7A2.75 2.75 0 0 1 4.25 17V7ZM7 5.75c-.69 0-1.25.56-1.25 1.25v10c0 .69.56 1.25 1.25 1.25h10c.69 0 1.25-.56 1.25-1.25V7c0-.69-.56-1.25-1.25-1.25H7Z"})})},13400:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 4L4 7.9V20h16V7.9L12 4zm6.5 14.5H14V13h-4v5.5H5.5V8.8L12 5.7l6.5 3.1v9.7z"})})},88074:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M4.8 11.4H2.1V9H1v6h1.1v-2.6h2.7V15h1.1V9H4.8v2.4zm1.9-1.3h1.7V15h1.1v-4.9h1.7V9H6.7v1.1zM16.2 9l-1.5 2.7L13.3 9h-.9l-.8 6h1.1l.5-4 1.5 2.8 1.5-2.8.5 4h1.1L17 9h-.8zm3.8 5V9h-1.1v6h3.6v-1H20z"})})},95938:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5 4.5h14c.3 0 .5.2.5.5v8.4l-3-2.9c-.3-.3-.8-.3-1 0L11.9 14 9 12c-.3-.2-.6-.2-.8 0l-3.6 2.6V5c-.1-.3.1-.5.4-.5zm14 15H5c-.3 0-.5-.2-.5-.5v-2.4l4.1-3 3 1.9c.3.2.7.2.9-.1L16 12l3.5 3.4V19c0 .3-.2.5-.5.5z"})})},34259:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M6 5.5h12a.5.5 0 01.5.5v7H14a2 2 0 11-4 0H5.5V6a.5.5 0 01.5-.5zm-.5 9V18a.5.5 0 00.5.5h12a.5.5 0 00.5-.5v-3.5h-3.337a3.5 3.5 0 01-6.326 0H5.5zM4 13V6a2 2 0 012-2h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2v-5z",clipRule:"evenodd"})})},19783:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm.75 4v1.5h-1.5V8h1.5Zm0 8v-5h-1.5v5h1.5Z"})})},65545:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M9 12h2v-2h2V8h-2V6H9v2H7v2h2v2zm1 4c3.9 0 7-3.1 7-7s-3.1-7-7-7-7 3.1-7 7 3.1 7 7 7zm0-12c2.8 0 5 2.2 5 5s-2.2 5-5 5-5-2.2-5-5 2.2-5 5-5zM3 19h14v-2H3v2z"})})},53916:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M11 8H9v2H7v2h2v2h2v-2h2v-2h-2V8zm-1-4c-3.9 0-7 3.1-7 7s3.1 7 7 7 7-3.1 7-7-3.1-7-7-7zm0 12c-2.8 0-5-2.2-5-5s2.2-5 5-5 5 2.2 5 5-2.2 5-5 5zM3 1v2h14V1H3z"})})},78329:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M18.646 9H20V8l-1-.5L12 4 5 7.5 4 8v1h14.646zm-3-1.5L12 5.677 8.354 7.5h7.292zm-7.897 9.44v-6.5h-1.5v6.5h1.5zm5-6.5v6.5h-1.5v-6.5h1.5zm5 0v6.5h-1.5v-6.5h1.5zm2.252 8.81c0 .414-.334.75-.748.75H4.752a.75.75 0 010-1.5h14.5a.75.75 0 01.749.75z",clipRule:"evenodd"})})},98339:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M15 4H9v11h6V4zM4 18.5V20h16v-1.5H4z"})})},35980:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M20 11h-5V4H9v7H4v1.5h5V20h6v-7.5h5z"})})},11177:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12.5 15v5H11v-5H4V9h7V4h1.5v5h7v6h-7Z"})})},51349:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9 9v6h11V9H9zM4 20h1.5V4H4v16z"})})},96692:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 15h11V9H4v6zM18.5 4v16H20V4h-1.5z"})})},99556:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7 4H17V8L7 8V4ZM7 16L17 16V20L7 20V16ZM20 11.25H4V12.75H20V11.25Z"})})},53057:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9 15h6V9H9v6zm-5 5h1.5V4H4v16zM18.5 4v16H20V4h-1.5z"})})},59210:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 4L20 4L20 5.5L4 5.5L4 4ZM10 7L14 7L14 17L10 17L10 7ZM20 18.5L4 18.5L4 20L20 20L20 18.5Z"})})},75911:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 4H5.5V20H4V4ZM7 10L17 10V14L7 14V10ZM20 4H18.5V20H20V4Z"})})},81037:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9 20h6V9H9v11zM4 4v1.5h16V4H4z"})})},72896:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M9 13.5a1.5 1.5 0 100-3 1.5 1.5 0 000 3zM9 16a4.002 4.002 0 003.8-2.75H15V16h2.5v-2.75H19v-2.5h-6.2A4.002 4.002 0 005 12a4 4 0 004 4z",fillRule:"evenodd",clipRule:"evenodd"})})},95855:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M18,0 L2,0 C0.9,0 0.01,0.9 0.01,2 L0,12 C0,13.1 0.9,14 2,14 L18,14 C19.1,14 20,13.1 20,12 L20,2 C20,0.9 19.1,0 18,0 Z M18,12 L2,12 L2,2 L18,2 L18,12 Z M9,3 L11,3 L11,5 L9,5 L9,3 Z M9,6 L11,6 L11,8 L9,8 L9,6 Z M6,3 L8,3 L8,5 L6,5 L6,3 Z M6,6 L8,6 L8,8 L6,8 L6,6 Z M3,6 L5,6 L5,8 L3,8 L3,6 Z M3,3 L5,3 L5,5 L3,5 L3,3 Z M6,9 L14,9 L14,11 L6,11 L6,9 Z M12,6 L14,6 L14,8 L12,8 L12,6 Z M12,3 L14,3 L14,5 L12,5 L12,3 Z M15,6 L17,6 L17,8 L15,8 L15,6 Z M15,3 L17,3 L17,5 L15,5 L15,3 Z M10,20 L14,16 L6,16 L10,20 Z"})})},76277:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m6.734 16.106 2.176-2.38-1.093-1.028-3.846 4.158 3.846 4.158 1.093-1.028-2.176-2.38h2.811c1.125 0 2.25.03 3.374 0 1.428-.001 3.362-.25 4.963-1.277 1.66-1.065 2.868-2.906 2.868-5.859 0-2.479-1.327-4.896-3.65-5.93-1.82-.813-3.044-.8-4.806-.788l-.567.002v1.5c.184 0 .368 0 .553-.002 1.82-.007 2.704-.014 4.21.657 1.854.827 2.76 2.657 2.76 4.561 0 2.472-.973 3.824-2.178 4.596-1.258.807-2.864 1.04-4.163 1.04h-.02c-1.115.03-2.229 0-3.344 0H6.734Z"})})},33602:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m16 15.5h-8v-1.5h8zm-7.5-2.5h-2v-2h2zm3 0h-2v-2h2zm3 0h-2v-2h2zm3 0h-2v-2h2zm-9-3h-2v-2h2zm3 0h-2v-2h2zm3 0h-2v-2h2zm3 0h-2v-2h2z"}),(0,o.jsx)(r.Path,{d:"m18.5 6.5h-13a.5.5 0 0 0 -.5.5v9.5a.5.5 0 0 0 .5.5h13a.5.5 0 0 0 .5-.5v-9.5a.5.5 0 0 0 -.5-.5zm-13-1.5h13a2 2 0 0 1 2 2v9.5a2 2 0 0 1 -2 2h-13a2 2 0 0 1 -2-2v-9.5a2 2 0 0 1 2-2z"})]})},65281:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.5 10h-1.7l-3.7 10.5h1.7l.9-2.6h3.9l.9 2.6h1.7L17.5 10zm-2.2 6.3 1.4-4 1.4 4h-2.8zm-4.8-3.8c1.6-1.8 2.9-3.6 3.7-5.7H16V5.2h-5.8V3H8.8v2.2H3v1.5h9.6c-.7 1.6-1.8 3.1-3.1 4.6C8.6 10.2 7.8 9 7.2 8H5.6c.6 1.4 1.7 2.9 2.9 4.4l-2.4 2.4c-.3.4-.7.8-1.1 1.2l1 1 1.2-1.2c.8-.8 1.6-1.5 2.3-2.3.8.9 1.7 1.7 2.5 2.5l.6-1.5c-.7-.6-1.4-1.3-2.1-2z"})})},20757:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18 5.5H6a.5.5 0 00-.5.5v3h13V6a.5.5 0 00-.5-.5zm.5 5H10v8h8a.5.5 0 00.5-.5v-7.5zm-10 0h-3V18a.5.5 0 00.5.5h2.5v-8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})})},11871:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m13.53 8.47-1.06 1.06-2.72-2.72V12h-1.5V6.81L5.53 9.53 4.47 8.47 9 3.94l4.53 4.53Zm-1.802 7.968c1.307.697 3.235.812 5.772.812v1.5c-2.463 0-4.785-.085-6.478-.988a4.721 4.721 0 0 1-2.07-2.13C8.48 14.67 8.25 13.471 8.25 12h1.5c0 1.328.208 2.28.548 2.969.332.675.81 1.138 1.43 1.47Z"})})},41496:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M17.375 15.656A6.47 6.47 0 0018.5 12a6.47 6.47 0 00-.943-3.374l-1.262.813c.448.749.705 1.625.705 2.561a4.977 4.977 0 01-.887 2.844l1.262.813zm-1.951 1.87l-.813-1.261A4.976 4.976 0 0112 17c-.958 0-1.852-.27-2.613-.736l-.812 1.261A6.47 6.47 0 0012 18.5a6.47 6.47 0 003.424-.974zm-8.8-1.87A6.47 6.47 0 015.5 12c0-1.235.344-2.39.943-3.373l1.261.812A4.977 4.977 0 007 12c0 1.056.328 2.036.887 2.843l-1.262.813zm2.581-7.803A4.977 4.977 0 0112 7c1.035 0 1.996.314 2.794.853l.812-1.262A6.47 6.47 0 0012 5.5a6.47 6.47 0 00-3.607 1.092l.812 1.261zM12 20a8 8 0 100-16 8 8 0 000 16zm0-4.5a3.5 3.5 0 100-7 3.5 3.5 0 000 7z",clipRule:"evenodd"})})},6055:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M5 11.25h3v1.5H5v-1.5zm5.5 0h3v1.5h-3v-1.5zm8.5 0h-3v1.5h3v-1.5z",clipRule:"evenodd"})})},6002:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M5.25 11.25h1.5v1.5h-1.5v-1.5zm3 0h1.5v1.5h-1.5v-1.5zm4.5 0h-1.5v1.5h1.5v-1.5zm1.5 0h1.5v1.5h-1.5v-1.5zm4.5 0h-1.5v1.5h1.5v-1.5z",clipRule:"evenodd"})})},10895:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 11.25h14v1.5H5z"})})},35855:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.031 4.703 15.576 4l-1.56 3H14v.03l-2.324 4.47H9.5V13h1.396l-1.502 2.889h-.95a3.694 3.694 0 0 1 0-7.389H10V7H8.444a5.194 5.194 0 1 0 0 10.389h.17L7.5 19.53l1.416.719L15.049 8.5h.507a3.694 3.694 0 0 1 0 7.39H14v1.5h1.556a5.194 5.194 0 0 0 .273-10.383l1.202-2.304Z"})})},87603:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M10 17.389H8.444A5.194 5.194 0 1 1 8.444 7H10v1.5H8.444a3.694 3.694 0 0 0 0 7.389H10v1.5ZM14 7h1.556a5.194 5.194 0 0 1 0 10.39H14v-1.5h1.556a3.694 3.694 0 0 0 0-7.39H14V7Zm-4.5 6h5v-1.5h-5V13Z"})})},62011:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 11v1.5h8V11h-8zm-6-1c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"})})},19601:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M3 6h11v1.5H3V6Zm3.5 5.5h11V13h-11v-1.5ZM21 17H10v1.5h11V17Z"})})},92011:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M4 4v1.5h16V4H4zm8 8.5h8V11h-8v1.5zM4 20h16v-1.5H4V20zm4-8c0-1.1-.9-2-2-2s-2 .9-2 2 .9 2 2 2 2-.9 2-2z"})})},7827:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17 10h-1.2V7c0-2.1-1.7-3.8-3.8-3.8-2.1 0-3.8 1.7-3.8 3.8v3H7c-.6 0-1 .4-1 1v8c0 .6.4 1 1 1h10c.6 0 1-.4 1-1v-8c0-.6-.4-1-1-1zM9.8 7c0-1.2 1-2.2 2.2-2.2 1.2 0 2.2 1 2.2 2.2v3H9.8V7zm6.7 11.5h-9v-7h9v7z"})})},47714:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M15 11h-.2V9c0-1.5-1.2-2.8-2.8-2.8S9.2 7.5 9.2 9v2H9c-.6 0-1 .4-1 1v4c0 .6.4 1 1 1h6c.6 0 1-.4 1-1v-4c0-.6-.4-1-1-1zm-1.8 0h-2.5V9c0-.7.6-1.2 1.2-1.2s1.2.6 1.2 1.2v2z"})})},84008:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17 10h-1.2V7c0-2.1-1.7-3.8-3.8-3.8-2.1 0-3.8 1.7-3.8 3.8v3H7c-.6 0-1 .4-1 1v8c0 .6.4 1 1 1h10c.6 0 1-.4 1-1v-8c0-.6-.4-1-1-1zm-2.8 0H9.8V7c0-1.2 1-2.2 2.2-2.2s2.2 1 2.2 2.2v3z"})})},23250:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11 14.5l1.1 1.1 3-3 .5-.5-.6-.6-3-3-1 1 1.7 1.7H5v1.5h7.7L11 14.5zM16.8 5h-7c-1.1 0-2 .9-2 2v1.5h1.5V7c0-.3.2-.5.5-.5h7c.3 0 .5.2.5.5v10c0 .3-.2.5-.5.5h-7c-.3 0-.5-.2-.5-.5v-1.5H7.8V17c0 1.1.9 2 2 2h7c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2z"})})},72525:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18.1823 11.6392C18.1823 13.0804 17.0139 14.2487 15.5727 14.2487C14.3579 14.2487 13.335 13.4179 13.0453 12.2922L13.0377 12.2625L13.0278 12.2335L12.3985 10.377L12.3942 10.3785C11.8571 8.64997 10.246 7.39405 8.33961 7.39405C5.99509 7.39405 4.09448 9.29465 4.09448 11.6392C4.09448 13.9837 5.99509 15.8843 8.33961 15.8843C8.88499 15.8843 9.40822 15.781 9.88943 15.5923L9.29212 14.0697C8.99812 14.185 8.67729 14.2487 8.33961 14.2487C6.89838 14.2487 5.73003 13.0804 5.73003 11.6392C5.73003 10.1979 6.89838 9.02959 8.33961 9.02959C9.55444 9.02959 10.5773 9.86046 10.867 10.9862L10.8772 10.9836L11.4695 12.7311C11.9515 14.546 13.6048 15.8843 15.5727 15.8843C17.9172 15.8843 19.8178 13.9837 19.8178 11.6392C19.8178 9.29465 17.9172 7.39404 15.5727 7.39404C15.0287 7.39404 14.5066 7.4968 14.0264 7.6847L14.6223 9.20781C14.9158 9.093 15.2358 9.02959 15.5727 9.02959C17.0139 9.02959 18.1823 10.1979 18.1823 11.6392Z"})})},50828:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 9c-.8 0-1.5.7-1.5 1.5S11.2 12 12 12s1.5-.7 1.5-1.5S12.8 9 12 9zm0-5c-3.6 0-6.5 2.8-6.5 6.2 0 .8.3 1.8.9 3.1.5 1.1 1.2 2.3 2 3.6.7 1 3 3.8 3.2 3.9l.4.5.4-.5c.2-.2 2.6-2.9 3.2-3.9.8-1.2 1.5-2.5 2-3.6.6-1.3.9-2.3.9-3.1C18.5 6.8 15.6 4 12 4zm4.3 8.7c-.5 1-1.1 2.2-1.9 3.4-.5.7-1.7 2.2-2.4 3-.7-.8-1.9-2.3-2.4-3-.8-1.2-1.4-2.3-1.9-3.3-.6-1.4-.7-2.2-.7-2.5 0-2.6 2.2-4.7 5-4.7s5 2.1 5 4.7c0 .2-.1 1-.7 2.4z"})})},83391:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M3 6v11.5h8V6H3Zm11 3h7V7.5h-7V9Zm7 3.5h-7V11h7v1.5ZM14 16h7v-1.5h-7V16Z"})})},21679:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7 6.5 4 2.5-4 2.5z"}),(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"m5 3c-1.10457 0-2 .89543-2 2v14c0 1.1046.89543 2 2 2h14c1.1046 0 2-.8954 2-2v-14c0-1.10457-.8954-2-2-2zm14 1.5h-14c-.27614 0-.5.22386-.5.5v10.7072l3.62953-2.6465c.25108-.1831.58905-.1924.84981-.0234l2.92666 1.8969 3.5712-3.4719c.2911-.2831.7545-.2831 1.0456 0l2.9772 2.8945v-9.3568c0-.27614-.2239-.5-.5-.5zm-14.5 14.5v-1.4364l4.09643-2.987 2.99567 1.9417c.2936.1903.6798.1523.9307-.0917l3.4772-3.3806 3.4772 3.3806.0228-.0234v2.5968c0 .2761-.2239.5-.5.5h-14c-.27614 0-.5-.2239-.5-.5z"})]})},8933:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M6.863 13.644L5 13.25h-.5a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5H5L18 6.5h2V16h-2l-3.854-.815.026.008a3.75 3.75 0 01-7.31-1.549zm1.477.313a2.251 2.251 0 004.356.921l-4.356-.921zm-2.84-3.28L18.157 8h.343v6.5h-.343L5.5 11.823v-1.146z",clipRule:"evenodd"})})},78136:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 5v1.5h14V5H5zm0 7.8h14v-1.5H5v1.5zM5 19h14v-1.5H5V19z"})})},82065:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M15 4H9c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h6c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 14c0 .3-.2.5-.5.5H9c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h6c.3 0 .5.2.5.5v12zm-4.5-.5h2V16h-2v1.5z"})})},42778:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:[(0,o.jsx)(r.Path,{d:"M7.5 12C7.5 11.1716 6.82843 10.5 6 10.5C5.17157 10.5 4.5 11.1716 4.5 12C4.5 12.8284 5.17157 13.5 6 13.5C6.82843 13.5 7.5 12.8284 7.5 12Z"}),(0,o.jsx)(r.Path,{d:"M13.5 12C13.5 11.1716 12.8284 10.5 12 10.5C11.1716 10.5 10.5 11.1716 10.5 12C10.5 12.8284 11.1716 13.5 12 13.5C12.8284 13.5 13.5 12.8284 13.5 12Z"}),(0,o.jsx)(r.Path,{d:"M19.5 12C19.5 11.1716 18.8284 10.5 18 10.5C17.1716 10.5 16.5 11.1716 16.5 12C16.5 12.8284 17.1716 13.5 18 13.5C18.8284 13.5 19.5 12.8284 19.5 12Z"})]})},28231:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11 13h2v-2h-2v2zm-6 0h2v-2H5v2zm12-2v2h2v-2h-2z"})})},31597:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"})})},57054:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M4 9v1.5h16V9H4zm12 5.5h4V13h-4v1.5zm-6 0h4V13h-4v1.5zm-6 0h4V13H4v1.5z"})})},22374:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19.75 9c0-1.257-.565-2.197-1.39-2.858-.797-.64-1.827-1.017-2.815-1.247-1.802-.42-3.703-.403-4.383-.396L11 4.5V6l.177-.001c.696-.006 2.416-.02 4.028.356.887.207 1.67.518 2.216.957.52.416.829.945.829 1.688 0 .592-.167.966-.407 1.23-.255.281-.656.508-1.236.674-1.19.34-2.82.346-4.607.346h-.077c-1.692 0-3.527 0-4.942.404-.732.209-1.424.545-1.935 1.108-.526.579-.796 1.33-.796 2.238 0 1.257.565 2.197 1.39 2.858.797.64 1.827 1.017 2.815 1.247 1.802.42 3.703.403 4.383.396L13 19.5h.714V22L18 18.5 13.714 15v3H13l-.177.001c-.696.006-2.416.02-4.028-.356-.887-.207-1.67-.518-2.216-.957-.52-.416-.829-.945-.829-1.688 0-.592.167-.966.407-1.23.255-.281.656-.508 1.237-.674 1.189-.34 2.819-.346 4.606-.346h.077c1.692 0 3.527 0 4.941-.404.732-.209 1.425-.545 1.936-1.108.526-.579.796-1.33.796-2.238z"})})},81385:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M12 4c-4.4 0-8 3.6-8 8s3.6 8 8 8 8-3.6 8-8-3.6-8-8-8zm0 14.5c-3.6 0-6.5-2.9-6.5-6.5S8.4 5.5 12 5.5s6.5 2.9 6.5 6.5-2.9 6.5-6.5 6.5zM9 16l4.5-3L15 8.4l-4.5 3L9 16z"})})},64222:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6.6 6L5.4 7l4.5 5-4.5 5 1.1 1 5.5-6-5.4-6zm6 0l-1.1 1 4.5 5-4.5 5 1.1 1 5.5-6-5.5-6z"})})},18887:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5A6.5 6.5 0 0 1 6.93 7.931l9.139 9.138A6.473 6.473 0 0 1 12 18.5Zm5.123-2.498a6.5 6.5 0 0 0-9.124-9.124l9.124 9.124ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Z"})})},11995:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 5H5c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm.5 12c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7c0-.3.2-.5.5-.5h14c.3 0 .5.2.5.5v10zm-11-7.6h-.7l-3.1 4.3h2.8V15h1v-1.3h.7v-.8h-.7V9.4zm-.9 3.5H6.3l1.2-1.7v1.7zm5.6-3.2c-.4-.2-.8-.4-1.2-.4-.5 0-.9.1-1.2.4-.4.2-.6.6-.8 1-.2.4-.3.9-.3 1.5s.1 1.1.3 1.6c.2.4.5.8.8 1 .4.2.8.4 1.2.4.5 0 .9-.1 1.2-.4.4-.2.6-.6.8-1 .2-.4.3-1 .3-1.6 0-.6-.1-1.1-.3-1.5-.1-.5-.4-.8-.8-1zm0 3.6c-.1.3-.3.5-.5.7-.2.1-.4.2-.7.2-.3 0-.5-.1-.7-.2-.2-.1-.4-.4-.5-.7-.1-.3-.2-.7-.2-1.2 0-.7.1-1.2.4-1.5.3-.3.6-.5 1-.5s.7.2 1 .5c.3.3.4.8.4 1.5-.1.5-.1.9-.2 1.2zm5-3.9h-.7l-3.1 4.3h2.8V15h1v-1.3h.7v-.8h-.7V9.4zm-1 3.5H16l1.2-1.7v1.7z"})})},93512:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M1.36605 2.81332L2.30144 1.87332L13.5592 13.1867L12.6239 14.1267L7.92702 9.40666C6.74618 9.41999 5.57861 9.87999 4.68302 10.78L3.35623 9.44665C4.19874 8.60665 5.2071 8.03999 6.2818 7.75332L4.7958 6.25999C3.78744 6.67332 2.84542 7.29332 2.02944 8.11332L0.702656 6.77999C1.512 5.97332 2.42085 5.33332 3.3894 4.84665L1.36605 2.81332ZM15.2973 6.77999L13.9705 8.11332C12.3054 6.43999 10.1096 5.61332 7.92039 5.62666L6.20883 3.90665C9.41303 3.34665 12.8229 4.29332 15.2973 6.77999ZM10.1759 7.89332C11.0781 8.21332 11.9273 8.72665 12.6438 9.44665L12.1794 9.90665L10.1759 7.89332ZM6.00981 12.1133L8 14.1133L9.99018 12.1133C8.89558 11.0067 7.11105 11.0067 6.00981 12.1133Z"})})},43411:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12-9.8c.4 0 .8-.3.9-.7l1.1-3h3.6l.5 1.7h1.9L13 9h-2.2l-3.4 9.5H6c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v12H20V6c0-1.1-.9-2-2-2zm-6 7l1.4 3.9h-2.7L12 11z"})})},78982:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.5 9V6a2 2 0 0 0-2-2h-7a2 2 0 0 0-2 2v3H8V6a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 .5.5v3h1.5Zm0 6.5V18a2 2 0 0 1-2 2h-7a2 2 0 0 1-2-2v-2.5H8V18a.5.5 0 0 0 .5.5h7a.5.5 0 0 0 .5-.5v-2.5h1.5ZM4 13h16v-1.5H4V13Z"})})},59892:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"M15.5 7.5h-7V9h7V7.5Zm-7 3.5h7v1.5h-7V11Zm7 3.5h-7V16h7v-1.5Z"}),(0,o.jsx)(r.Path,{d:"M17 4H7a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2ZM7 5.5h10a.5.5 0 0 1 .5.5v12a.5.5 0 0 1-.5.5H7a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5Z"})]})},94299:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"M14.5 5.5h-7V7h7V5.5ZM7.5 9h7v1.5h-7V9Zm7 3.5h-7V14h7v-1.5Z"}),(0,o.jsx)(r.Path,{d:"M16 2H6a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2ZM6 3.5h10a.5.5 0 0 1 .5.5v12a.5.5 0 0 1-.5.5H6a.5.5 0 0 1-.5-.5V4a.5.5 0 0 1 .5-.5Z"}),(0,o.jsx)(r.Path,{d:"M20 8v11c0 .69-.31 1-.999 1H6v1.5h13.001c1.52 0 2.499-.982 2.499-2.5V8H20Z"})]})},70413:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m9.99609 14v-.2251l.00391.0001v6.225h1.5v-14.5h2.5v14.5h1.5v-14.5h3v-1.5h-8.50391c-2.76142 0-5 2.23858-5 5 0 2.7614 2.23858 5 5 5z"})})},95501:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M5.5 9.5v-2h13v2h-13zm0 3v4h13v-4h-13zM4 7a1 1 0 011-1h14a1 1 0 011 1v10a1 1 0 01-1 1H5a1 1 0 01-1-1V7z",clipRule:"evenodd"})})},78938:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m19 7-3-3-8.5 8.5-1 4 4-1L19 7Zm-7 11.5H5V20h7v-1.5Z"})})},8436:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm8 4a4 4 0 0 1-4-4h4V8a4 4 0 0 1 0 8Z"})})},15788:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M15.5 9.5a1 1 0 100-2 1 1 0 000 2zm0 1.5a2.5 2.5 0 100-5 2.5 2.5 0 000 5zm-2.25 6v-2a2.75 2.75 0 00-2.75-2.75h-4A2.75 2.75 0 003.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0120.25 15zM9.5 8.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0z",fillRule:"evenodd"})})},13822:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M6.5 8a1.5 1.5 0 103 0 1.5 1.5 0 00-3 0zM8 5a3 3 0 100 6 3 3 0 000-6zm6.5 11a1.5 1.5 0 103 0 1.5 1.5 0 00-3 0zm1.5-3a3 3 0 100 6 3 3 0 000-6zM5.47 17.41a.75.75 0 001.06 1.06L18.47 6.53a.75.75 0 10-1.06-1.06L5.47 17.41z",clipRule:"evenodd"})})},83594:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M10.97 10.159a3.382 3.382 0 0 0-2.857.955l1.724 1.723-2.836 2.913L7 17h1.25l2.913-2.837 1.723 1.723a3.38 3.38 0 0 0 .606-.825c.33-.63.446-1.343.35-2.032L17 10.695 13.305 7l-2.334 3.159Z"})})},36304:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m21.5 9.1-6.6-6.6-4.2 5.6c-1.2-.1-2.4.1-3.6.7-.1 0-.1.1-.2.1-.5.3-.9.6-1.2.9l3.7 3.7-5.7 5.7v1.1h1.1l5.7-5.7 3.7 3.7c.4-.4.7-.8.9-1.2.1-.1.1-.2.2-.3.6-1.1.8-2.4.6-3.6l5.6-4.1zm-7.3 3.5.1.9c.1.9 0 1.8-.4 2.6l-6-6c.8-.4 1.7-.5 2.6-.4l.9.1L15 4.9 19.1 9l-4.9 3.6z"})})},30435:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M10.5 4v4h3V4H15v4h1.5a1 1 0 011 1v4l-3 4v2a1 1 0 01-1 1h-3a1 1 0 01-1-1v-2l-3-4V9a1 1 0 011-1H9V4h1.5zm.5 12.5v2h2v-2l3-4v-3H8v3l3 4z"})})},17809:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M2 12C2 6.44444 6.44444 2 12 2C17.5556 2 22 6.44444 22 12C22 17.5556 17.5556 22 12 22C6.44444 22 2 17.5556 2 12ZM13 11V7H11V11H7V13H11V17H13V13H17V11H13Z"})})},73632:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M10 1c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7zm1-11H9v3H6v2h3v3h2v-3h3V9h-3V6zM10 1c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 16c-3.9 0-7-3.1-7-7s3.1-7 7-7 7 3.1 7 7-3.1 7-7 7zm1-11H9v3H6v2h3v3h2v-3h3V9h-3V6z"})})},45459:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11 12.5V17.5H12.5V12.5H17.5V11H12.5V6H11V11H6V12.5H11Z"})})},72816:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 5.5H5V4h14v1.5ZM19 20H5v-1.5h14V20ZM7 9h10v6H7V9Z"})})},96504:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 5.5h8V4H5v1.5ZM5 20h8v-1.5H5V20ZM19 9H5v6h14V9Z"})})},71643:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 5.5h-8V4h8v1.5ZM19 20h-8v-1.5h8V20ZM5 9h14v6H5V9Z"})})},36037:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M10 4.5a1 1 0 11-2 0 1 1 0 012 0zm1.5 0a2.5 2.5 0 11-5 0 2.5 2.5 0 015 0zm2.25 7.5v-1A2.75 2.75 0 0011 8.25H7A2.75 2.75 0 004.25 11v1h1.5v-1c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v1h1.5zM4 20h9v-1.5H4V20zm16-4H4v-1.5h16V16z",fillRule:"evenodd",clipRule:"evenodd"})})},94706:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M20 4H4v1.5h16V4zm-2 9h-3c-1.1 0-2 .9-2 2v3c0 1.1.9 2 2 2h3c1.1 0 2-.9 2-2v-3c0-1.1-.9-2-2-2zm.5 5c0 .3-.2.5-.5.5h-3c-.3 0-.5-.2-.5-.5v-3c0-.3.2-.5.5-.5h3c.3 0 .5.2.5.5v3zM4 9.5h9V8H4v1.5zM9 13H6c-1.1 0-2 .9-2 2v3c0 1.1.9 2 2 2h3c1.1 0 2-.9 2-2v-3c0-1.1-.9-2-2-2zm.5 5c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5v-3c0-.3.2-.5.5-.5h3c.3 0 .5.2.5.5v3z",fillRule:"evenodd",clipRule:"evenodd"})})},90754:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M13 8H4v1.5h9V8zM4 4v1.5h16V4H4zm9 8H5c-.6 0-1 .4-1 1v8.3c0 .3.2.7.6.8.1.1.2.1.3.1.2 0 .5-.1.6-.3l1.8-1.8H13c.6 0 1-.4 1-1V13c0-.6-.4-1-1-1zm-2.2 6.6H7l1.6-2.2c.3-.4.5-.7.6-.9.1-.2.2-.4.2-.5 0-.2-.1-.3-.1-.4-.1-.1-.2-.1-.4-.1s-.4 0-.6.1c-.3.1-.5.3-.7.4l-.2.2-.2-1.2.1-.1c.3-.2.5-.3.8-.4.3-.1.6-.1.9-.1.3 0 .6.1.9.2.2.1.4.3.6.5.1.2.2.5.2.7 0 .3-.1.6-.2.9-.1.3-.4.7-.7 1.1l-.5.6h1.6v1.2z"})})},93803:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M13 8H4v1.5h9V8zM4 4v1.5h16V4H4zm9 8H5c-.6 0-1 .4-1 1v8.3c0 .3.2.7.6.8.1.1.2.1.3.1.2 0 .5-.1.6-.3l1.8-1.8H13c.6 0 1-.4 1-1V13c0-.6-.4-1-1-1zm-.5 6.6H6.7l-1.2 1.2v-6.3h7v5.1z"})})},25816:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M14 10.1V4c0-.6-.4-1-1-1H5c-.6 0-1 .4-1 1v8.3c0 .3.2.7.6.8.1.1.2.1.3.1.2 0 .5-.1.6-.3l1.8-1.8H13c.6 0 1-.4 1-1zm-1.5-.5H6.7l-1.2 1.2V4.5h7v5.1zM19 12h-8c-.6 0-1 .4-1 1v6.1c0 .6.4 1 1 1h5.7l1.8 1.8c.1.2.4.3.6.3.1 0 .2 0 .3-.1.4-.1.6-.5.6-.8V13c0-.6-.4-1-1-1zm-.5 7.8l-1.2-1.2h-5.8v-5.1h7v6.3z"})})},41417:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 6h12V4.5H4V6Zm16 4.5H4V9h16v1.5ZM4 15h16v-1.5H4V15Zm0 4.5h16V18H4v1.5Z"})})},76982:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"M11.696 13.972c.356-.546.599-.958.728-1.235a1.79 1.79 0 00.203-.783c0-.264-.077-.47-.23-.618-.148-.153-.354-.23-.618-.23-.295 0-.569.07-.82.212a3.413 3.413 0 00-.738.571l-.147-1.188c.289-.234.59-.41.903-.526.313-.117.66-.175 1.041-.175.375 0 .695.08.959.24.264.153.46.362.59.626.135.265.203.556.203.876 0 .362-.08.734-.24 1.115-.154.381-.427.87-.82 1.466l-.756 1.152H14v1.106h-4l1.696-2.609z"}),(0,o.jsx)(r.Path,{d:"M19.5 7h-15v12a.5.5 0 00.5.5h14a.5.5 0 00.5-.5V7zM3 7V5a2 2 0 012-2h14a2 2 0 012 2v14a2 2 0 01-2 2H5a2 2 0 01-2-2V7z"})]})},88669:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M8.001 3.984V9.47c0 1.518-.98 2.5-2.499 2.5h-.5v-1.5h.5c.69 0 1-.31 1-1V6.984H4v-3h4.001ZM4 20h9v-1.5H4V20Zm16-4H4v-1.5h16V16ZM13.001 3.984V9.47c0 1.518-.98 2.5-2.499 2.5h-.5v-1.5h.5c.69 0 1-.31 1-1V6.984H9v-3h4.001Z"})})},54424:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19 3H5c-.6 0-1 .4-1 1v7c0 .5.4 1 1 1h14c.5 0 1-.4 1-1V4c0-.6-.4-1-1-1zM5.5 10.5v-.4l1.8-1.3 1.3.8c.3.2.7.2.9-.1L11 8.1l2.4 2.4H5.5zm13 0h-2.9l-4-4c-.3-.3-.8-.3-1.1 0L8.9 8l-1.2-.8c-.3-.2-.6-.2-.9 0l-1.3 1V4.5h13v6zM4 20h9v-1.5H4V20zm0-4h16v-1.5H4V16z"})})},30:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18 5.5H6a.5.5 0 0 0-.5.5v12a.5.5 0 0 0 .5.5h12a.5.5 0 0 0 .5-.5V6a.5.5 0 0 0-.5-.5ZM6 4h12a2 2 0 0 1 2 2v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2Zm1 5h1.5v1.5H7V9Zm1.5 4.5H7V15h1.5v-1.5ZM10 9h7v1.5h-7V9Zm7 4.5h-7V15h7v-1.5Z"})})},5015:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M8.1 12.3c.1.1.3.3.5.3.2.1.4.1.6.1.2 0 .4 0 .6-.1.2-.1.4-.2.5-.3l3-3c.3-.3.5-.7.5-1.1 0-.4-.2-.8-.5-1.1L9.7 3.5c-.1-.2-.3-.3-.5-.3H5c-.4 0-.8.4-.8.8v4.2c0 .2.1.4.2.5l3.7 3.6zM5.8 4.8h3.1l3.4 3.4v.1l-3 3 .5.5-.7-.5-3.3-3.4V4.8zM4 20h9v-1.5H4V20zm0-5.5V16h16v-1.5H4z"})})},69457:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m7.3 9.7 1.4 1.4c.2-.2.3-.3.4-.5 0 0 0-.1.1-.1.3-.5.4-1.1.3-1.6L12 7 9 4 7.2 6.5c-.6-.1-1.1 0-1.6.3 0 0-.1 0-.1.1-.3.1-.4.2-.6.4l1.4 1.4L4 11v1h1l2.3-2.3zM4 20h9v-1.5H4V20zm0-5.5V16h16v-1.5H4z"})})},6584:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18 4H6c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 14c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v12zM7 16.5h6V15H7v1.5zm4-4h6V11h-6v1.5zM9 11H7v1.5h2V11zm6 5.5h2V15h-2v1.5z"})})},56026:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11.6 7l-1.1-1L5 12l5.5 6 1.1-1L7 12l4.6-5zm6 0l-1.1-1-5.5 6 5.5 6 1.1-1-4.6-5 4.6-5z"})})},64609:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm11.53-1.47-1.06-1.06L11 12.94l-1.47-1.47-1.06 1.06L11 15.06l4.53-4.53Z"})})},52812:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 18h6V6H4v12zm9-9.5V10h7V8.5h-7zm0 7h7V14h-7v1.5z"})})},78887:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M14 6v12h6V6h-6zM4 10h7V8.5H4V10zm0 5.5h7V14H4v1.5z"})})},31798:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18 8H6c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2v-4c0-1.1-.9-2-2-2zm.5 6c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5v-4c0-.3.2-.5.5-.5h12c.3 0 .5.2.5.5v4zM4 4v1.5h16V4H4zm0 16h16v-1.5H4V20z"})})},58324:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 13.5h3v-3H5v3zm5 0h3v-3h-3v3zM17 9l-1 1 2 2-2 2 1 1 3-3-3-3z"})})},79843:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 13.5h6v-3H4v3zm8.2-2.5.8-.3V14h1V9.3l-2.2.7.4 1zm7.1-1.2c-.5-.6-1.2-.5-1.7-.4-.3.1-.5.2-.7.3l.1 1.1c.2-.2.5-.4.8-.5.3-.1.6 0 .7.1.2.3 0 .8-.2 1.1-.5.8-.9 1.6-1.4 2.5h2.7v-1h-.9c.3-.6.8-1.4.9-2.1 0-.3-.1-.8-.3-1.1z"})})},57524:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16 10.5v3h3v-3h-3zm-5 3h3v-3h-3v3zM7 9l-3 3 3 3 1-1-2-2 2-2-1-1z"})})},13968:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 13.5h6v-3H4v3zm8 0h3v-3h-3v3zm5-3v3h3v-3h-3z"})})},91535:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M13 6v6h5.2v4c0 .8-.2 1.4-.5 1.7-.6.6-1.6.6-2.5.5h-.3v1.5h.5c1 0 2.3-.1 3.3-1 .6-.6 1-1.6 1-2.8V6H13zm-9 6h5.2v4c0 .8-.2 1.4-.5 1.7-.6.6-1.6.6-2.5.5h-.3v1.5h.5c1 0 2.3-.1 3.3-1 .6-.6 1-1.6 1-2.8V6H4v6z"})})},49695:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M16.83 6.342l.602.3.625-.25.443-.176v12.569l-.443-.178-.625-.25-.603.301-1.444.723-2.41-.804-.475-.158-.474.158-2.41.803-1.445-.722-.603-.3-.625.25-.443.177V6.215l.443.178.625.25.603-.301 1.444-.722 2.41.803.475.158.474-.158 2.41-.803 1.445.722zM20 4l-1.5.6-1 .4-2-1-3 1-3-1-2 1-1-.4L5 4v17l1.5-.6 1-.4 2 1 3-1 3 1 2-1 1 .4 1.5.6V4zm-3.5 6.25v-1.5h-8v1.5h8zm0 3v-1.5h-8v1.5h8zm-8 3v-1.5h8v1.5h-8z",clipRule:"evenodd"})})},86299:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M15.6 6.5l-1.1 1 2.9 3.3H8c-.9 0-1.7.3-2.3.9-1.4 1.5-1.4 4.2-1.4 5.6v.2h1.5v-.3c0-1.1 0-3.5 1-4.5.3-.3.7-.5 1.3-.5h9.2L14.5 15l1.1 1.1 4.6-4.6-4.6-5z"})})},81884:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M8.45474 21.2069L16.4547 3.7069L15.5453 3.29114L14.2837 6.05081C13.5991 5.69873 12.8228 5.49999 12 5.49999C10.9385 5.49999 9.95431 5.83076 9.1448 6.39485L7.18994 4.44L6.12928 5.50066L8.05556 7.42694C7.49044 8.15127 7.12047 9.0353 7.02469 9.99999H5V11.5H7V13H5V14.5H7.10002C7.35089 15.7359 8.0576 16.8062 9.03703 17.5279L7.54526 20.7911L8.45474 21.2069ZM9.68024 16.1209C8.95633 15.4796 8.5 14.5431 8.5 13.5V10.5C8.5 8.567 10.067 6.99999 12 6.99999C12.6003 6.99999 13.1653 7.15111 13.659 7.41738L9.68024 16.1209ZM15.3555 9.50155L16.1645 7.73191C16.6053 8.39383 16.8926 9.16683 16.9753 9.99999H19V11.5H17V13H19V14.5H16.9C16.4367 16.7822 14.419 18.5 12 18.5C11.7508 18.5 11.5058 18.4818 11.2664 18.4466L11.928 16.9993C11.9519 16.9998 11.9759 17 12 17C13.933 17 15.5 15.433 15.5 13.5V10.5C15.5 10.1531 15.4495 9.81794 15.3555 9.50155Z"})})},5903:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"m13.955 20.748 8-17.5-.91-.416L19.597 6H13.5v1.5h5.411l-1.6 3.5H13.5v1.5h3.126l-1.6 3.5H13.5l.028 1.5h.812l-1.295 2.832.91.416ZM17.675 16l-.686 1.5h4.539L21.5 16h-3.825Zm2.286-5-.686 1.5H21.5V11h-1.54ZM2 12c0 3.58 2.42 5.5 6 5.5h.5V19l3-2.5-3-2.5v2H8c-2.48 0-4.5-1.52-4.5-4S5.52 7.5 8 7.5h3.5V6H8c-3.58 0-6 2.42-6 6Z"})})},36667:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16 10h4c.6 0 1-.4 1-1V5c0-.6-.4-1-1-1h-4c-.6 0-1 .4-1 1v4c0 .6.4 1 1 1zm-8 4H4c-.6 0-1 .4-1 1v4c0 .6.4 1 1 1h4c.6 0 1-.4 1-1v-4c0-.6-.4-1-1-1zm10-2.6L14.5 15l1.1 1.1 1.7-1.7c-.1 1.1-.3 2.3-.9 2.9-.3.3-.7.5-1.3.5h-4.5v1.5H15c.9 0 1.7-.3 2.3-.9 1-1 1.3-2.7 1.4-4l1.8 1.8 1.1-1.1-3.6-3.7zM6.8 9.7c.1-1.1.3-2.3.9-2.9.4-.4.8-.6 1.3-.6h4.5V4.8H9c-.9 0-1.7.3-2.3.9-1 1-1.3 2.7-1.4 4L3.5 8l-1 1L6 12.6 9.5 9l-1-1-1.7 1.7z"})})},84832:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7 11.5h10V13H7z"})})},32128:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M7 18h4.5v1.5h-7v-7H6V17L17 6h-4.5V4.5h7v7H18V7L7 18Z"})})},40502:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7 7.2h8.2L13.5 9l1.1 1.1 3.6-3.6-3.5-4-1.1 1 1.9 2.3H7c-.9 0-1.7.3-2.3.9-1.4 1.5-1.4 4.2-1.4 5.6v.2h1.5v-.3c0-1.1 0-3.5 1-4.5.3-.3.7-.5 1.2-.5zm13.8 4V11h-1.5v.3c0 1.1 0 3.5-1 4.5-.3.3-.7.5-1.3.5H8.8l1.7-1.7-1.1-1.1L5.9 17l3.5 4 1.1-1-1.9-2.3H17c.9 0 1.7-.3 2.3-.9 1.5-1.4 1.5-4.2 1.5-5.6z"})})},80828:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 4V2.2L9 4.8l3 2.5V5.5c3.6 0 6.5 2.9 6.5 6.5 0 2.9-1.9 5.3-4.5 6.2v.2l-.1-.2c-.4.1-.7.2-1.1.2l.2 1.5c.3 0 .6-.1 1-.2 3.5-.9 6-4 6-7.7 0-4.4-3.6-8-8-8zm-7.9 7l1.5.2c.1-1.2.5-2.3 1.2-3.2l-1.1-.9C4.8 8.2 4.3 9.6 4.1 11zm1.5 1.8l-1.5.2c.1.7.3 1.4.5 2 .3.7.6 1.3 1 1.8l1.2-.8c-.3-.5-.6-1-.8-1.5s-.4-1.1-.4-1.7zm1.5 5.5c1.1.9 2.4 1.4 3.8 1.6l.2-1.5c-1.1-.1-2.2-.5-3.1-1.2l-.9 1.1z"})})},60503:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M15.1 4.8l-3-2.5V4c-4.4 0-8 3.6-8 8 0 3.7 2.5 6.9 6 7.7.3.1.6.1 1 .2l.2-1.5c-.4 0-.7-.1-1.1-.2l-.1.2v-.2c-2.6-.8-4.5-3.3-4.5-6.2 0-3.6 2.9-6.5 6.5-6.5v1.8l3-2.5zM20 11c-.2-1.4-.7-2.7-1.6-3.8l-1.2.8c.7.9 1.1 2 1.3 3.1L20 11zm-1.5 1.8c-.1.5-.2 1.1-.4 1.6s-.5 1-.8 1.5l1.2.9c.4-.5.8-1.1 1-1.8s.5-1.3.5-2l-1.5-.2zm-5.6 5.6l.2 1.5c1.4-.2 2.7-.7 3.8-1.6l-.9-1.1c-.9.7-2 1.1-3.1 1.2z"})})},71743:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 6.5h5a2 2 0 0 1 2 2v7a2 2 0 0 1-2 2H4V16h5a.5.5 0 0 0 .5-.5v-7A.5.5 0 0 0 9 8H4V6.5Zm16 0h-5a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h5V16h-5a.5.5 0 0 1-.5-.5v-7A.5.5 0 0 1 15 8h5V6.5Z"})})},4335:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 10.2h-.8v1.5H5c1.9 0 3.8.8 5.1 2.1 1.4 1.4 2.1 3.2 2.1 5.1v.8h1.5V19c0-2.3-.9-4.5-2.6-6.2-1.6-1.6-3.8-2.6-6.1-2.6zm10.4-1.6C12.6 5.8 8.9 4.2 5 4.2h-.8v1.5H5c3.5 0 6.9 1.4 9.4 3.9s3.9 5.8 3.9 9.4v.8h1.5V19c0-3.9-1.6-7.6-4.4-10.4zM4 20h3v-3H4v3z"})})},27268:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm9 1V8h-1.5v3.5h-2V13H13Z"})})},58535:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M13 5c-3.3 0-6 2.7-6 6 0 1.4.5 2.7 1.3 3.7l-3.8 3.8 1.1 1.1 3.8-3.8c1 .8 2.3 1.3 3.7 1.3 3.3 0 6-2.7 6-6S16.3 5 13 5zm0 10.5c-2.5 0-4.5-2-4.5-4.5s2-4.5 4.5-4.5 4.5 2 4.5 4.5-2 4.5-4.5 4.5z"})})},58824:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M3.99961 13C4.67043 13.3354 4.6703 13.3357 4.67017 13.3359L4.67298 13.3305C4.67621 13.3242 4.68184 13.3135 4.68988 13.2985C4.70595 13.2686 4.7316 13.2218 4.76695 13.1608C4.8377 13.0385 4.94692 12.8592 5.09541 12.6419C5.39312 12.2062 5.84436 11.624 6.45435 11.0431C7.67308 9.88241 9.49719 8.75 11.9996 8.75C14.502 8.75 16.3261 9.88241 17.5449 11.0431C18.1549 11.624 18.6061 12.2062 18.9038 12.6419C19.0523 12.8592 19.1615 13.0385 19.2323 13.1608C19.2676 13.2218 19.2933 13.2686 19.3093 13.2985C19.3174 13.3135 19.323 13.3242 19.3262 13.3305L19.3291 13.3359C19.3289 13.3357 19.3288 13.3354 19.9996 13C20.6704 12.6646 20.6703 12.6643 20.6701 12.664L20.6697 12.6632L20.6688 12.6614L20.6662 12.6563L20.6583 12.6408C20.6517 12.6282 20.6427 12.6108 20.631 12.5892C20.6078 12.5459 20.5744 12.4852 20.5306 12.4096C20.4432 12.2584 20.3141 12.0471 20.1423 11.7956C19.7994 11.2938 19.2819 10.626 18.5794 9.9569C17.1731 8.61759 14.9972 7.25 11.9996 7.25C9.00203 7.25 6.82614 8.61759 5.41987 9.9569C4.71736 10.626 4.19984 11.2938 3.85694 11.7956C3.68511 12.0471 3.55605 12.2584 3.4686 12.4096C3.42484 12.4852 3.39142 12.5459 3.36818 12.5892C3.35656 12.6108 3.34748 12.6282 3.34092 12.6408L3.33297 12.6563L3.33041 12.6614L3.32948 12.6632L3.32911 12.664C3.32894 12.6643 3.32879 12.6646 3.99961 13ZM11.9996 16C13.9326 16 15.4996 14.433 15.4996 12.5C15.4996 10.567 13.9326 9 11.9996 9C10.0666 9 8.49961 10.567 8.49961 12.5C8.49961 14.433 10.0666 16 11.9996 16Z"})})},67709:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M6.332 5.748c-1.03-.426-2.06.607-1.632 1.636l1.702 3.93 7.481.575c.123.01.123.19 0 .2l-7.483.575-1.7 3.909c-.429 1.029.602 2.062 1.632 1.636l12.265-5.076c1.03-.426 1.03-1.884 0-2.31L6.332 5.748Z"})})},13976:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M4.5 12.5v4H3V7h1.5v3.987h15V7H21v9.5h-1.5v-4h-15Z"})})},20066:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m19 7.5h-7.628c-.3089-.87389-1.1423-1.5-2.122-1.5-.97966 0-1.81309.62611-2.12197 1.5h-2.12803v1.5h2.12803c.30888.87389 1.14231 1.5 2.12197 1.5.9797 0 1.8131-.62611 2.122-1.5h7.628z"}),(0,o.jsx)(r.Path,{d:"m19 15h-2.128c-.3089-.8739-1.1423-1.5-2.122-1.5s-1.8131.6261-2.122 1.5h-7.628v1.5h7.628c.3089.8739 1.1423 1.5 2.122 1.5s1.8131-.6261 2.122-1.5h2.128z"})]})},37759:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M12 8c-2.2 0-4 1.8-4 4s1.8 4 4 4 4-1.8 4-4-1.8-4-4-4zm0 6.5c-1.4 0-2.5-1.1-2.5-2.5s1.1-2.5 2.5-2.5 2.5 1.1 2.5 2.5-1.1 2.5-2.5 2.5zM12.8 3h-1.5v3h1.5V3zm-1.6 18h1.5v-3h-1.5v3zm6.8-9.8v1.5h3v-1.5h-3zm-12 0H3v1.5h3v-1.5zm9.7 5.6 2.1 2.1 1.1-1.1-2.1-2.1-1.1 1.1zM8.3 7.2 6.2 5.1 5.1 6.2l2.1 2.1 1.1-1.1zM5.1 17.8l1.1 1.1 2.1-2.1-1.1-1.1-2.1 2.1zM18.9 6.2l-1.1-1.1-2.1 2.1 1.1 1.1 2.1-2.1z"})})},80596:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M9 11.8l6.1-4.5c.1.4.4.7.9.7h2c.6 0 1-.4 1-1V5c0-.6-.4-1-1-1h-2c-.6 0-1 .4-1 1v.4l-6.4 4.8c-.2-.1-.4-.2-.6-.2H6c-.6 0-1 .4-1 1v2c0 .6.4 1 1 1h2c.2 0 .4-.1.6-.2l6.4 4.8v.4c0 .6.4 1 1 1h2c.6 0 1-.4 1-1v-2c0-.6-.4-1-1-1h-2c-.5 0-.8.3-.9.7L9 12.2v-.4z"})})},65302:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 3.176l6.75 3.068v4.574c0 3.9-2.504 7.59-6.035 8.755a2.283 2.283 0 01-1.43 0c-3.53-1.164-6.035-4.856-6.035-8.755V6.244L12 3.176zM6.75 7.21v3.608c0 3.313 2.145 6.388 5.005 7.33.159.053.331.053.49 0 2.86-.942 5.005-4.017 5.005-7.33V7.21L12 4.824 6.75 7.21z",fillRule:"evenodd",clipRule:"evenodd"})})},24233:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M3 6.75C3 5.784 3.784 5 4.75 5H15V7.313l.05.027 5.056 2.73.394.212v3.468a1.75 1.75 0 01-1.75 1.75h-.012a2.5 2.5 0 11-4.975 0H9.737a2.5 2.5 0 11-4.975 0H3V6.75zM13.5 14V6.5H4.75a.25.25 0 00-.25.25V14h.965a2.493 2.493 0 011.785-.75c.7 0 1.332.287 1.785.75H13.5zm4.535 0h.715a.25.25 0 00.25-.25v-2.573l-4-2.16v4.568a2.487 2.487 0 011.25-.335c.7 0 1.332.287 1.785.75zM6.282 15.5a1.002 1.002 0 00.968 1.25 1 1 0 10-.968-1.25zm9 0a1 1 0 101.937.498 1 1 0 00-1.938-.498z"})})},88944:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M16 4.2v1.5h2.5v12.5H16v1.5h4V4.2h-4zM4.2 19.8h4v-1.5H5.8V5.8h2.5V4.2h-4l-.1 15.6zm5.1-3.1l1.4.6 4-10-1.4-.6-4 10z"})})},77846:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/SVG",children:(0,o.jsx)(r.Path,{d:"M17.192 6.75L15.47 5.03l1.06-1.06 3.537 3.53-3.537 3.53-1.06-1.06 1.723-1.72h-3.19c-.602 0-.993.202-1.28.498-.309.319-.538.792-.695 1.383-.13.488-.222 1.023-.296 1.508-.034.664-.116 1.413-.303 2.117-.193.721-.513 1.467-1.068 2.04-.575.594-1.359.954-2.357.954H4v-1.5h4.003c.601 0 .993-.202 1.28-.498.308-.319.538-.792.695-1.383.149-.557.216-1.093.288-1.662l.039-.31a9.653 9.653 0 0 1 .272-1.653c.193-.722.513-1.467 1.067-2.04.576-.594 1.36-.954 2.358-.954h3.19zM8.004 6.75c.8 0 1.46.23 1.988.628a6.24 6.24 0 0 0-.684 1.396 1.725 1.725 0 0 0-.024-.026c-.287-.296-.679-.498-1.28-.498H4v-1.5h4.003zM12.699 14.726c-.161.459-.38.94-.684 1.396.527.397 1.188.628 1.988.628h3.19l-1.722 1.72 1.06 1.06L20.067 16l-3.537-3.53-1.06 1.06 1.723 1.72h-3.19c-.602 0-.993-.202-1.28-.498a1.96 1.96 0 0 1-.024-.026z"})})},37631:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18 5.5H6a.5.5 0 00-.5.5v3h13V6a.5.5 0 00-.5-.5zm.5 5H10v8h8a.5.5 0 00.5-.5v-7.5zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"})})},88305:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z"})})},65483:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M8.2 5.3h8V3.8h-8v1.5zm0 14.5h8v-1.5h-8v1.5zm3.5-6.5h1v-1h-1v1zm1-6.5h-1v.5h1v-.5zm-1 4.5h1v-1h-1v1zm0-2h1v-1h-1v1zm0 7.5h1v-.5h-1v.5zm1-2.5h-1v1h1v-1zm-8.5 1.5h1.5v-8H4.2v8zm14.5-8v8h1.5v-8h-1.5zm-5 4.5v-1h-1v1h1zm-6.5 0h.5v-1h-.5v1zm3.5-1v1h1v-1h-1zm6 1h.5v-1h-.5v1zm-8-1v1h1v-1h-1zm6 0v1h1v-1h-1z"})})},7731:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z",style:{opacity:.25}}),(0,o.jsx)(r.Path,{d:"m16.5 19.5h-9v-1.5h9z"})]})},81808:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z",style:{opacity:.25}}),(0,o.jsx)(r.Path,{d:"m4.5 7.5v9h1.5v-9z"}),(0,o.jsx)(r.Path,{d:"m18 7.5v9h1.5v-9z"})]})},25125:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z",style:{opacity:.25}}),(0,o.jsx)(r.Path,{d:"m4.5 16.5v-9h1.5v9z"})]})},94916:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z",style:{opacity:.25}}),(0,o.jsx)(r.Path,{d:"m18 16.5v-9h1.5v9z"})]})},88061:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z",style:{opacity:.25}}),(0,o.jsx)(r.Path,{d:"m16.5 6h-9v-1.5h9z"})]})},37870:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9zm0 13.5h9v-1.5h-9zm-3-3h1.5v-9h-1.5zm13.5-9v9h1.5v-9z",style:{opacity:.25}}),(0,o.jsx)(r.Path,{d:"m7.5 6h9v-1.5h-9z"}),(0,o.jsx)(r.Path,{d:"m7.5 19.5h9v-1.5h-9z"})]})},11194:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 3c-5 0-9 4-9 9s4 9 9 9 9-4 9-9-4-9-9-9zm0 1.5c4.1 0 7.5 3.4 7.5 7.5v.1c-1.4-.8-3.3-1.7-3.4-1.8-.2-.1-.5-.1-.8.1l-2.9 2.1L9 11.3c-.2-.1-.4 0-.6.1l-3.7 2.2c-.1-.5-.2-1-.2-1.5 0-4.2 3.4-7.6 7.5-7.6zm0 15c-3.1 0-5.7-1.9-6.9-4.5l3.7-2.2 3.5 1.2c.2.1.5 0 .7-.1l2.9-2.1c.8.4 2.5 1.2 3.5 1.9-.9 3.3-3.9 5.8-7.4 5.8z"})})},26992:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fill:"none",d:"M5.75 12.75V18.25H11.25M12.75 5.75H18.25V11.25",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"square"})})},33371:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17.5 4v5a2 2 0 0 1-2 2h-7a2 2 0 0 1-2-2V4H8v5a.5.5 0 0 0 .5.5h7A.5.5 0 0 0 16 9V4h1.5Zm0 16v-5a2 2 0 0 0-2-2h-7a2 2 0 0 0-2 2v5H8v-5a.5.5 0 0 1 .5-.5h7a.5.5 0 0 1 .5.5v5h1.5Z"})})},61871:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M9.706 8.646a.25.25 0 01-.188.137l-4.626.672a.25.25 0 00-.139.427l3.348 3.262a.25.25 0 01.072.222l-.79 4.607a.25.25 0 00.362.264l4.138-2.176a.25.25 0 01.233 0l4.137 2.175a.25.25 0 00.363-.263l-.79-4.607a.25.25 0 01.072-.222l3.347-3.262a.25.25 0 00-.139-.427l-4.626-.672a.25.25 0 01-.188-.137l-2.069-4.192a.25.25 0 00-.448 0L9.706 8.646zM12 7.39l-.948 1.921a1.75 1.75 0 01-1.317.957l-2.12.308 1.534 1.495c.412.402.6.982.503 1.55l-.362 2.11 1.896-.997a1.75 1.75 0 011.629 0l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39z",clipRule:"evenodd"})})},77136:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M11.776 4.454a.25.25 0 01.448 0l2.069 4.192a.25.25 0 00.188.137l4.626.672a.25.25 0 01.139.426l-3.348 3.263a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.362.263l-4.138-2.175a.25.25 0 00-.232 0l-4.138 2.175a.25.25 0 01-.363-.263l.79-4.607a.25.25 0 00-.071-.222L4.754 9.881a.25.25 0 01.139-.426l4.626-.672a.25.25 0 00.188-.137l2.069-4.192z"})})},41137:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M9.518 8.783a.25.25 0 00.188-.137l2.069-4.192a.25.25 0 01.448 0l2.07 4.192a.25.25 0 00.187.137l4.626.672a.25.25 0 01.139.427l-3.347 3.262a.25.25 0 00-.072.222l.79 4.607a.25.25 0 01-.363.264l-4.137-2.176a.25.25 0 00-.233 0l-4.138 2.175a.25.25 0 01-.362-.263l.79-4.607a.25.25 0 00-.072-.222L4.753 9.882a.25.25 0 01.14-.427l4.625-.672zM12 14.533c.28 0 .559.067.814.2l1.895.997-.362-2.11a1.75 1.75 0 01.504-1.55l1.533-1.495-2.12-.308a1.75 1.75 0 01-1.317-.957L12 7.39v7.143z"})})},45422:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",d:"M19.75 11H21V8.667L19.875 4H4.125L3 8.667V11h1.25v8.75h15.5V11zm-1.5 0H5.75v7.25H10V13h4v5.25h4.25V11zm-5.5-5.5h2.067l.486 3.24.028.76H12.75v-4zm-3.567 0h2.067v4H8.669l.028-.76.486-3.24zm7.615 3.1l-.464-3.1h2.36l.806 3.345V9.5h-2.668l-.034-.9zM7.666 5.5h-2.36L4.5 8.845V9.5h2.668l.034-.9.464-3.1z",clipRule:"evenodd"})})},36111:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 4h14v11H5V4Zm11 16H8v-1.5h8V20Z"})})},46048:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16 5.5H8V4h8v1.5ZM16 20H8v-1.5h8V20ZM5 9h14v6H5V9Z"})})},29753:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M20 12a8 8 0 1 1-16 0 8 8 0 0 1 16 0Zm-1.5 0a6.5 6.5 0 0 1-6.5 6.5v-13a6.5 6.5 0 0 1 6.5 6.5Z"})})},30838:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16.9 18.3l.8-1.2c.4-.6.7-1.2.9-1.6.2-.4.3-.8.3-1.2 0-.3-.1-.7-.2-1-.1-.3-.4-.5-.6-.7-.3-.2-.6-.3-1-.3s-.8.1-1.1.2c-.3.1-.7.3-1 .6l.2 1.3c.3-.3.5-.5.8-.6s.6-.2.9-.2c.3 0 .5.1.7.2.2.2.2.4.2.7 0 .3-.1.5-.2.8-.1.3-.4.7-.8 1.3L15 19.4h4.3v-1.2h-2.4zM14.1 7.2h-2L9.5 11 6.9 7.2h-2l3.6 5.3L4.7 18h2l2.7-4 2.7 4h2l-3.8-5.5 3.8-5.3z"})})},36935:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M16.9 10.3l.8-1.3c.4-.6.7-1.2.9-1.6.2-.4.3-.8.3-1.2 0-.3-.1-.7-.2-1-.2-.2-.4-.4-.7-.6-.3-.2-.6-.3-1-.3s-.8.1-1.1.2c-.3.1-.7.3-1 .6l.1 1.3c.3-.3.5-.5.8-.6s.6-.2.9-.2c.3 0 .5.1.7.2.2.2.2.4.2.7 0 .3-.1.5-.2.8-.1.3-.4.7-.8 1.3l-1.8 2.8h4.3v-1.2h-2.2zm-2.8-3.1h-2L9.5 11 6.9 7.2h-2l3.6 5.3L4.7 18h2l2.7-4 2.7 4h2l-3.8-5.5 3.8-5.3z"})})},30959:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M5 17.7c.4.5.8.9 1.2 1.2l1.1-1.4c-.4-.3-.7-.6-1-1L5 17.7zM5 6.3l1.4 1.1c.3-.4.6-.7 1-1L6.3 5c-.5.4-.9.8-1.3 1.3zm.1 7.8l-1.7.5c.2.6.4 1.1.7 1.6l1.5-.8c-.2-.4-.4-.8-.5-1.3zM4.8 12v-.7L3 11.1v1.8l1.7-.2c.1-.2.1-.5.1-.7zm3 7.9c.5.3 1.1.5 1.6.7l.5-1.7c-.5-.1-.9-.3-1.3-.5l-.8 1.5zM19 6.3c-.4-.5-.8-.9-1.2-1.2l-1.1 1.4c.4.3.7.6 1 1L19 6.3zm-.1 3.6l1.7-.5c-.2-.6-.4-1.1-.7-1.6l-1.5.8c.2.4.4.8.5 1.3zM5.6 8.6l-1.5-.8c-.3.5-.5 1-.7 1.6l1.7.5c.1-.5.3-.9.5-1.3zm2.2-4.5l.8 1.5c.4-.2.8-.4 1.3-.5l-.5-1.7c-.6.2-1.1.4-1.6.7zm8.8 13.5l1.1 1.4c.5-.4.9-.8 1.2-1.2l-1.4-1.1c-.2.3-.5.6-.9.9zm1.8-2.2l1.5.8c.3-.5.5-1.1.7-1.6l-1.7-.5c-.1.5-.3.9-.5 1.3zm2.6-4.3l-1.7.2v1.4l1.7.2V12v-.9zM11.1 3l.2 1.7h1.4l.2-1.7h-1.8zm3 2.1c.5.1.9.3 1.3.5l.8-1.5c-.5-.3-1.1-.5-1.6-.7l-.5 1.7zM12 19.2h-.7l-.2 1.8h1.8l-.2-1.7c-.2-.1-.5-.1-.7-.1zm2.1-.3l.5 1.7c.6-.2 1.1-.4 1.6-.7l-.8-1.5c-.4.2-.8.4-1.3.5z"})})},97572:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M21.3 10.8l-5.6-5.6c-.7-.7-1.8-.7-2.5 0l-5.6 5.6c-.7.7-.7 1.8 0 2.5l5.6 5.6c.3.3.8.5 1.2.5s.9-.2 1.2-.5l5.6-5.6c.8-.7.8-1.9.1-2.5zm-17.6 1L10 5.5l-1-1-6.3 6.3c-.7.7-.7 1.8 0 2.5L9 19.5l1.1-1.1-6.3-6.3c-.2 0-.2-.2-.1-.3z"})})},28687:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M21.3 10.8l-5.6-5.6c-.7-.7-1.8-.7-2.5 0l-5.6 5.6c-.7.7-.7 1.8 0 2.5l5.6 5.6c.3.3.8.5 1.2.5s.9-.2 1.2-.5l5.6-5.6c.8-.7.8-1.9.1-2.5zm-1 1.4l-5.6 5.6c-.1.1-.3.1-.4 0l-5.6-5.6c-.1-.1-.1-.3 0-.4l5.6-5.6s.1-.1.2-.1.1 0 .2.1l5.6 5.6c.1.1.1.3 0 .4zm-16.6-.4L10 5.5l-1-1-6.3 6.3c-.7.7-.7 1.8 0 2.5L9 19.5l1.1-1.1-6.3-6.3c-.2 0-.2-.2-.1-.3z"})})},31181:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M14.08 12.864V9.216h3.648V7.424H14.08V3.776h-1.728v3.648H8.64v1.792h3.712v3.648zM0 17.92V0h20.48v17.92H0zM6.4 1.28H1.28v3.84H6.4V1.28zm0 5.12H1.28v3.84H6.4V6.4zm0 5.12H1.28v3.84H6.4v-3.84zM19.2 1.28H7.68v14.08H19.2V1.28z"})})},13488:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M6.4 3.776v3.648H2.752v1.792H6.4v3.648h1.728V9.216h3.712V7.424H8.128V3.776zM0 17.92V0h20.48v17.92H0zM12.8 1.28H1.28v14.08H12.8V1.28zm6.4 0h-5.12v3.84h5.12V1.28zm0 5.12h-5.12v3.84h5.12V6.4zm0 5.12h-5.12v3.84h5.12v-3.84z"})})},93664:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M6.4 9.98L7.68 8.7v-.256L6.4 7.164V9.98zm6.4-1.532l1.28-1.28V9.92L12.8 8.64v-.192zm7.68 9.472V0H0v17.92h20.48zm-1.28-2.56h-5.12v-1.024l-.256.256-1.024-1.024v1.792H7.68v-1.792l-1.024 1.024-.256-.256v1.024H1.28V1.28H6.4v2.368l.704-.704.576.576V1.216h5.12V3.52l.96-.96.32.32V1.216h5.12V15.36zm-5.76-2.112l-3.136-3.136-3.264 3.264-1.536-1.536 3.264-3.264L5.632 5.44l1.536-1.536 3.136 3.136 3.2-3.2 1.536 1.536-3.2 3.2 3.136 3.136-1.536 1.536z"})})},27672:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsxs)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:[(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M20 9.484h-8.889v-1.5H20v1.5Zm0 7h-4.889v-1.5H20v1.5Zm-14 .032a1 1 0 1 0 0-2 1 1 0 0 0 0 2Zm0 1a2 2 0 1 0 0-4 2 2 0 0 0 0 4Z"}),(0,o.jsx)(r.Path,{d:"M13 15.516a2 2 0 1 1-4 0 2 2 0 0 1 4 0ZM8 8.484a2 2 0 1 1-4 0 2 2 0 0 1 4 0Z"})]})},51917:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M13.824 10.176h-2.88v-2.88H9.536v2.88h-2.88v1.344h2.88v2.88h1.408v-2.88h2.88zM0 17.92V0h20.48v17.92H0zM6.4 1.28H1.28v3.84H6.4V1.28zm6.4 0H7.68v3.84h5.12V1.28zm6.4 0h-5.12v3.84h5.12V1.28zm0 5.056H1.28v9.024H19.2V6.336z"})})},87504:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M6.656 6.464h2.88v2.88h1.408v-2.88h2.88V5.12h-2.88V2.24H9.536v2.88h-2.88zM0 17.92V0h20.48v17.92H0zm7.68-2.56h5.12v-3.84H7.68v3.84zm-6.4 0H6.4v-3.84H1.28v3.84zM19.2 1.28H1.28v9.024H19.2V1.28zm0 10.24h-5.12v3.84h5.12v-3.84zM6.656 6.464h2.88v2.88h1.408v-2.88h2.88V5.12h-2.88V2.24H9.536v2.88h-2.88zM0 17.92V0h20.48v17.92H0zm7.68-2.56h5.12v-3.84H7.68v3.84zm-6.4 0H6.4v-3.84H1.28v3.84zM19.2 1.28H1.28v9.024H19.2V1.28zm0 10.24h-5.12v3.84h5.12v-3.84z"})})},55104:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M17.728 11.456L14.592 8.32l3.2-3.2-1.536-1.536-3.2 3.2L9.92 3.648 8.384 5.12l3.2 3.2-3.264 3.264 1.536 1.536 3.264-3.264 3.136 3.136 1.472-1.536zM0 17.92V0h20.48v17.92H0zm19.2-6.4h-.448l-1.28-1.28H19.2V6.4h-1.792l1.28-1.28h.512V1.28H1.28v3.84h6.208l1.28 1.28H1.28v3.84h7.424l-1.28 1.28H1.28v3.84H19.2v-3.84z"})})},18495:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4 6v11.5h16V6H4zm1.5 1.5h6V11h-6V7.5zm0 8.5v-3.5h6V16h-6zm13 0H13v-3.5h5.5V16zM13 11V7.5h5.5V11H13z"})})},21955:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M17 4H7c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 14c0 .3-.2.5-.5.5H7c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h10c.3 0 .5.2.5.5v12zm-7.5-.5h4V16h-4v1.5z"})})},211:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4.75 4a.75.75 0 0 0-.75.75v7.826c0 .2.08.39.22.53l6.72 6.716a2.313 2.313 0 0 0 3.276-.001l5.61-5.611-.531-.53.532.528a2.315 2.315 0 0 0 0-3.264L13.104 4.22a.75.75 0 0 0-.53-.22H4.75ZM19 12.576a.815.815 0 0 1-.236.574l-5.61 5.611a.814.814 0 0 1-1.153 0L5.5 12.264V5.5h6.763l6.5 6.502a.816.816 0 0 1 .237.574ZM8.75 9.75a1 1 0 1 0 0-2 1 1 0 0 0 0 2Z"})})},90254:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6.08 10.103h2.914L9.657 12h1.417L8.23 4H6.846L4 12h1.417l.663-1.897Zm1.463-4.137.994 2.857h-2l1.006-2.857ZM11 16H4v-1.5h7V16Zm1 0h8v-1.5h-8V16Zm-4 4H4v-1.5h4V20Zm7-1.5V20H9v-1.5h6Z"})})},43886:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12.9 6h-2l-4 11h1.9l1.1-3h4.2l1.1 3h1.9L12.9 6zm-2.5 6.5l1.5-4.9 1.7 4.9h-3.2z"})})},90153:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M8.2 14.4h3.9L13 17h1.7L11 6.5H9.3L5.6 17h1.7l.9-2.6zm2-5.5 1.4 4H8.8l1.4-4zm7.4 7.5-1.3.8.8 1.4H5.5V20h14.3l-2.2-3.6z"})})},7583:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M7 5.6v1.7l2.6.9v3.9L7 13v1.7L17.5 11V9.3L7 5.6zm4.2 6V8.8l4 1.4-4 1.4zm-5.7 5.6V5.5H4v14.3l3.6-2.2-.8-1.3-1.3.9z"})})},50347:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M19.8 4h-1.5l1 8h1.5l-1-8ZM17 5.8c-.1-1-1-1.8-2-1.8H6.8c-.9 0-1.7.6-1.9 1.4l-1.8 6C2.7 12.7 3.7 14 5 14h4.4l-.8 3.6c-.3 1.3.7 2.4 1.9 2.4h.2c.6 0 1.2-.3 1.6-.8l5-6.6c.3-.4.5-.9.4-1.5L17 5.7Zm-.9 5.9-5 6.6c0 .1-.2.2-.4.2h-.2c-.3 0-.6-.3-.5-.6l.8-3.6c.1-.4 0-.9-.3-1.3s-.7-.6-1.2-.6H4.9c-.3 0-.6-.3-.5-.6l1.8-6c0-.2.3-.4.5-.4h8.2c.3 0 .5.2.5.4l.7 5.4v.4Z"})})},7598:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m3 12 1 8h1.5l-1-8H3Zm15.8-2h-4.4l.8-3.6c.3-1.3-.7-2.4-1.9-2.4h-.2c-.6 0-1.2.3-1.6.8l-5 6.6c-.3.4-.4.8-.4 1.2v.2l.7 5.4v.2c.2.9 1 1.5 1.9 1.5h8.2c.9 0 1.7-.6 1.9-1.4l1.8-6c.4-1.3-.6-2.6-1.9-2.6Zm.5 2.1-1.8 6c0 .2-.3.4-.5.4H8.8c-.3 0-.5-.2-.5-.4l-.7-5.4v-.4l5-6.6c0-.1.2-.2.4-.2h.2c.3 0 .6.3.5.6l-.8 3.6c-.1.4 0 .9.3 1.3s.7.6 1.2.6h4.4c.3 0 .6.3.5.6Z"})})},35170:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M12 15.8c-3.7 0-6.8-3-6.8-6.8s3-6.8 6.8-6.8c3.7 0 6.8 3 6.8 6.8s-3.1 6.8-6.8 6.8zm0-12C9.1 3.8 6.8 6.1 6.8 9s2.4 5.2 5.2 5.2c2.9 0 5.2-2.4 5.2-5.2S14.9 3.8 12 3.8zM8 17.5h8V19H8zM10 20.5h4V22h-4z"})})},11269:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m4 5.5h2v6.5h1.5v-6.5h2v-1.5h-5.5zm16 10.5h-16v-1.5h16zm-7 4h-9v-1.5h9z"})})},71041:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M14.103 7.128l2.26-2.26a4 4 0 00-5.207 4.804L5.828 15a2 2 0 102.828 2.828l5.329-5.328a4 4 0 004.804-5.208l-2.261 2.26-1.912-.512-.513-1.912zm-7.214 9.64a.5.5 0 11.707-.707.5.5 0 01-.707.707z"})})},76673:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 5.5A2.25 2.25 0 0 0 9.878 7h4.244A2.251 2.251 0 0 0 12 5.5ZM12 4a3.751 3.751 0 0 0-3.675 3H5v1.5h1.27l.818 8.997a2.75 2.75 0 0 0 2.739 2.501h4.347a2.75 2.75 0 0 0 2.738-2.5L17.73 8.5H19V7h-3.325A3.751 3.751 0 0 0 12 4Zm4.224 4.5H7.776l.806 8.861a1.25 1.25 0 0 0 1.245 1.137h4.347a1.25 1.25 0 0 0 1.245-1.137l.805-8.861Z"})})},36707:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M4.195 8.245a.75.75 0 011.06-.05l5.004 4.55 4.025-3.521L19 13.939V10.75h1.5v5.75h-5.75V15h3.19l-3.724-3.723-3.975 3.478-5.995-5.45a.75.75 0 01-.051-1.06z"})})},92614:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M3.445 16.505a.75.75 0 001.06.05l5.005-4.55 4.024 3.521 4.716-4.715V14h1.5V8.25H14v1.5h3.19l-3.724 3.723L9.49 9.995l-5.995 5.45a.75.75 0 00-.05 1.06z"})})},74426:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6.9 7L3 17.8h1.7l1-2.8h4.1l1 2.8h1.7L8.6 7H6.9zm-.7 6.6l1.5-4.3 1.5 4.3h-3zM21.6 17c-.1.1-.2.2-.3.2-.1.1-.2.1-.4.1s-.3-.1-.4-.2c-.1-.1-.1-.3-.1-.6V12c0-.5 0-1-.1-1.4-.1-.4-.3-.7-.5-1-.2-.2-.5-.4-.9-.5-.4 0-.8-.1-1.3-.1s-1 .1-1.4.2c-.4.1-.7.3-1 .4-.2.2-.4.3-.6.5-.1.2-.2.4-.2.7 0 .3.1.5.2.8.2.2.4.3.8.3.3 0 .6-.1.8-.3.2-.2.3-.4.3-.7 0-.3-.1-.5-.2-.7-.2-.2-.4-.3-.6-.4.2-.2.4-.3.7-.4.3-.1.6-.1.8-.1.3 0 .6 0 .8.1.2.1.4.3.5.5.1.2.2.5.2.9v1.1c0 .3-.1.5-.3.6-.2.2-.5.3-.9.4-.3.1-.7.3-1.1.4-.4.1-.8.3-1.1.5-.3.2-.6.4-.8.7-.2.3-.3.7-.3 1.2 0 .6.2 1.1.5 1.4.3.4.9.5 1.6.5.5 0 1-.1 1.4-.3.4-.2.8-.6 1.1-1.1 0 .4.1.7.3 1 .2.3.6.4 1.2.4.4 0 .7-.1.9-.2.2-.1.5-.3.7-.4h-.3zm-3-.9c-.2.4-.5.7-.8.8-.3.2-.6.2-.8.2-.4 0-.6-.1-.9-.3-.2-.2-.3-.6-.3-1.1 0-.5.1-.9.3-1.2s.5-.5.8-.7c.3-.2.7-.3 1-.5.3-.1.6-.3.7-.6v3.4z"})})},95789:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18.3 11.7c-.6-.6-1.4-.9-2.3-.9H6.7l2.9-3.3-1.1-1-4.5 5L8.5 16l1-1-2.7-2.7H16c.5 0 .9.2 1.3.5 1 1 1 3.4 1 4.5v.3h1.5v-.2c0-1.5 0-4.3-1.5-5.7z"})})},68113:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18 4h-7c-1.1 0-2 .9-2 2v7c0 1.1.9 2 2 2h7c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm.5 9c0 .3-.2.5-.5.5h-7c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h7c.3 0 .5.2.5.5v7zm-5 5c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5v-7c0-.3.2-.5.5-.5h1V9H6c-1.1 0-2 .9-2 2v7c0 1.1.9 2 2 2h7c1.1 0 2-.9 2-2v-1h-1.5v1z"})})},375:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17 10h-1.2V7c0-2.1-1.7-3.8-3.8-3.8-2.1 0-3.8 1.7-3.8 3.8h1.5c0-1.2 1-2.2 2.2-2.2s2.2 1 2.2 2.2v3H7c-.6 0-1 .4-1 1v8c0 .6.4 1 1 1h10c.6 0 1-.4 1-1v-8c0-.6-.4-1-1-1z"})})},52259:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M20.7 12.7s0-.1-.1-.2c0-.2-.2-.4-.4-.6-.3-.5-.9-1.2-1.6-1.8-.7-.6-1.5-1.3-2.6-1.8l-.6 1.4c.9.4 1.6 1 2.1 1.5.6.6 1.1 1.2 1.4 1.6.1.2.3.4.3.5v.1l.7-.3.7-.3Zm-5.2-9.3-1.8 4c-.5-.1-1.1-.2-1.7-.2-3 0-5.2 1.4-6.6 2.7-.7.7-1.2 1.3-1.6 1.8-.2.3-.3.5-.4.6 0 0 0 .1-.1.2s0 0 .7.3l.7.3V13c0-.1.2-.3.3-.5.3-.4.7-1 1.4-1.6 1.2-1.2 3-2.3 5.5-2.3H13v.3c-.4 0-.8-.1-1.1-.1-1.9 0-3.5 1.6-3.5 3.5s.6 2.3 1.6 2.9l-2 4.4.9.4 7.6-16.2-.9-.4Zm-3 12.6c1.7-.2 3-1.7 3-3.5s-.2-1.4-.6-1.9L12.4 16Z"})})},83822:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"m11.3 17.2-5-5c-.1-.1-.1-.3 0-.4l2.3-2.3-1.1-1-2.3 2.3c-.7.7-.7 1.8 0 2.5l5 5H7.5v1.5h5.3v-5.2h-1.5v2.6zm7.5-6.4-5-5h2.7V4.2h-5.2v5.2h1.5V6.8l5 5c.1.1.1.3 0 .4l-2.3 2.3 1.1 1.1 2.3-2.3c.6-.7.6-1.9-.1-2.5z"})})},7326:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M18.5 15v3.5H13V6.7l4.5 4.1 1-1.1-6.2-5.8-5.8 5.8 1 1.1 4-4v11.7h-6V15H4v5h16v-5z"})})},43610:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M17.8 2l-.9.3c-.1 0-3.6 1-5.2 2.1C10 5.5 9.3 6.5 8.9 7.1c-.6.9-1.7 4.7-1.7 6.3l-.9 2.3c-.2.4 0 .8.4 1 .1 0 .2.1.3.1.3 0 .6-.2.7-.5l.6-1.5c.3 0 .7-.1 1.2-.2.7-.1 1.4-.3 2.2-.5.8-.2 1.6-.5 2.4-.8.7-.3 1.4-.7 1.9-1.2s.8-1.2 1-1.9c.2-.7.3-1.6.4-2.4.1-.8.1-1.7.2-2.5 0-.8.1-1.5.2-2.1V2zm-1.9 5.6c-.1.8-.2 1.5-.3 2.1-.2.6-.4 1-.6 1.3-.3.3-.8.6-1.4.9-.7.3-1.4.5-2.2.8-.6.2-1.3.3-1.8.4L15 7.5c.3-.3.6-.7 1-1.1 0 .4 0 .8-.1 1.2zM6 20h8v-1.5H6V20z"})})},70396:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:(0,o.jsx)(r.Path,{d:"M18.7 3H5.3C4 3 3 4 3 5.3v13.4C3 20 4 21 5.3 21h13.4c1.3 0 2.3-1 2.3-2.3V5.3C21 4 20 3 18.7 3zm.8 15.7c0 .4-.4.8-.8.8H5.3c-.4 0-.8-.4-.8-.8V5.3c0-.4.4-.8.8-.8h13.4c.4 0 .8.4.8.8v13.4zM10 15l5-3-5-3v6z"})})},5559:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,o.jsx)(r.Path,{d:"M6 3H8V5H16V3H18V5C19.1046 5 20 5.89543 20 7V19C20 20.1046 19.1046 21 18 21H6C4.89543 21 4 20.1046 4 19V7C4 5.89543 4.89543 5 6 5V3ZM18 6.5H6C5.72386 6.5 5.5 6.72386 5.5 7V8H18.5V7C18.5 6.72386 18.2761 6.5 18 6.5ZM18.5 9.5H5.5V19C5.5 19.2761 5.72386 19.5 6 19.5H18C18.2761 19.5 18.5 19.2761 18.5 19V9.5ZM11 11H13V13H11V11ZM7 11V13H9V11H7ZM15 13V11H17V13H15Z"})})},94648:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(5573),o=a(10790);const n=(0,o.jsx)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24",children:(0,o.jsx)(r.Path,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"})})},33752:e=>{function t(e){var a,r,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var n=e.length;for(a=0;a{t.formatArgs=function(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const a="color: "+this.color;t.splice(1,0,a,"color: inherit");let r=0,o=0;t[0].replace(/%[a-zA-Z%]/g,(e=>{"%%"!==e&&(r++,"%c"===e&&(o=r))})),t.splice(o,0,a)},t.save=function(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}},t.load=function(){let e;try{e=t.storage.getItem("debug")}catch(e){}!e&&"undefined"!=typeof process&&"env"in process&&(e=process.env.DEBUG);return e},t.useColors=function(){if("undefined"!=typeof window&&window.process&&("renderer"===window.process.type||window.process.__nwjs))return!0;if("undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return"undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},t.storage=function(){try{return localStorage}catch(e){}}(),t.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.log=console.debug||console.log||(()=>{}),e.exports=a(53212)(t);const{formatters:r}=e.exports;r.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}},53212:(e,t,a)=>{e.exports=function(e){function t(e){let a,o,n,l=null;function s(...e){if(!s.enabled)return;const r=s,o=Number(new Date),n=o-(a||o);r.diff=n,r.prev=a,r.curr=o,a=o,e[0]=t.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let l=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,((a,o)=>{if("%%"===a)return"%";l++;const n=t.formatters[o];if("function"==typeof n){const t=e[l];a=n.call(r,t),e.splice(l,1),l--}return a})),t.formatArgs.call(r,e);(r.log||t.log).apply(r,e)}return s.namespace=e,s.useColors=t.useColors(),s.color=t.selectColor(e),s.extend=r,s.destroy=t.destroy,Object.defineProperty(s,"enabled",{enumerable:!0,configurable:!1,get:()=>null!==l?l:(o!==t.namespaces&&(o=t.namespaces,n=t.enabled(e)),n),set:e=>{l=e}}),"function"==typeof t.init&&t.init(s),s}function r(e,a){const r=t(this.namespace+(void 0===a?":":a)+e);return r.log=this.log,r}function o(e,t){let a=0,r=0,o=-1,n=0;for(;a"-"+e))].join(",");return t.enable(""),e},t.enable=function(e){t.save(e),t.namespaces=e,t.names=[],t.skips=[];const a=("string"==typeof e?e:"").trim().replace(" ",",").split(",").filter(Boolean);for(const e of a)"-"===e[0]?t.skips.push(e.slice(1)):t.names.push(e)},t.enabled=function(e){for(const a of t.skips)if(o(e,a))return!1;for(const a of t.names)if(o(e,a))return!0;return!1},t.humanize=a(44997),t.destroy=function(){console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`.")},Object.keys(e).forEach((a=>{t[a]=e[a]})),t.names=[],t.skips=[],t.formatters={},t.selectColor=function(e){let a=0;for(let t=0;t{"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}t.A=void 0;var o,n=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!==r(e)&&"function"!=typeof e)return{default:e};var a=i(t);if(a&&a.has(e))return a.get(e);var o={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var l in e)if("default"!=l&&Object.prototype.hasOwnProperty.call(e,l)){var s=n?Object.getOwnPropertyDescriptor(e,l):null;s&&(s.get||s.set)?Object.defineProperty(o,l,s):o[l]=e[l]}return o.default=e,a&&a.set(e,o),o}(a(51609)),l=(o=a(28120))&&o.__esModule?o:{default:o},s=["size","onClick","icon","className"];function i(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,a=new WeakMap;return(i=function(e){return e?a:t})(e)}function c(){return c=Object.assign||function(e){for(var t,a=1;a{"use strict";a.d(t,{A:()=>r});const r={error:"TcCZnGE6mad8Dvz9pCZi",button:"_mn6o2Dtm5pfFWc8_A1K"}},8902:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"admin-page":"sexr0jUxC1jVixdKiDnC",background:"vKQ11sLeAM45M04P1ccj","admin-page-header":"iWGAhN9gOB48g0jEO1OQ","sandbox-domain-badge":"JOYmuxQjG4FArIIUxJfA"}},27507:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={section:"cAbGtJDGgLubucBnz7vM"}},48703:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"section-hero":"vMa4i_Dza2t5Zi_Bw9Nf"}},8953:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"demNsMJjhi7BLY7xhjU5","icon-wrapper":"QiUjdjJSkqh6nH7YMG5A","is-error":"Q080AHcq29J2fc68Hhk5",icon:"hYWbIwhppukXmGnsiT9H","is-warning":"JjHuxWly0HI9C60gorbq","is-info":"Cm8ZFHi3mngl4cj9Gatx","is-success":"ytGBsU015p3LGwOPwFDx"}},50315:()=>{},55369:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={button:"zI5tJ_qhWE6Oe6Lk75GY","is-icon-button":"tuBt2DLqimiImoqVzPqo",small:"Na39I683LAaSA99REg14",normal:"ipS7tKy9GntCS4R3vekF",icon:"paGLQwtPEaJmtArCcmyK",regular:"lZAo6_oGfclXOO9CC6Rd","full-width":"xJDOiJxTt0R_wSl8Ipz_",loading:"q_tVWqMjl39RcY6WtQA6","external-icon":"CDuBjJp_8jxzx5j6Nept"}},94347:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"global-notices":"jT9Kt2ZTvxPKDQ1pa7sN"}},40500:()=>{},50626:()=>{},9969:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"star-icon":"cuoSlhSNrqf1dozY22Xb",jetpack:"lAIiifeLMmZAPlQ9n9ZR","checkmark-icon":"JLquNpQVlysAamuh5lJO",socialIcon:"cbOwD8Y4tFjwimmtchQI",bluesky:"aLWBKY0yRghEk7tNCgK3",facebook:"aHOlEBGD5EA8NKRw3xTw",instagram:"cL3m0xBYTYhIKI7lCqDB",twitter:"af4Y_zItXvLAOEoSDPSv",linkedin:"f68aqF3XSD1OBvXR1get",tumblr:"xFI0dt3UiXRlRQdqPWkx",google:"q7JEoyymveP6kF747M43",mastodon:"DKOBOTVmTLbh26gUH_73",nextdoor:"n5XodNsuMfMAAvqHFmbw",whatsapp:"fftumuc_lJ6v0tq4UMVR",threads:"inzgC27qxdt7hSdhTWRI"}},68271:()=>{},15508:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)"}},11616:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)",smCols:"4",mdCols:"8",lgCols:"12","col-sm-1":"RuVLl3q4lxTQa3wbhBJB","col-sm-1-start":"f9LZTRG4MMK42rS89afW","col-sm-1-end":"bHe_zKxjjpUwHw_MdYE1","col-sm-2":"QZbNrOqE2aNSn50xVhpU","col-sm-2-start":"ev7W3z7zVYPeHAlYqZjf","col-sm-2-end":"NJWd1m_e7lOiPYru2ZMP","col-sm-3":"Xc6nt1Qc1DI0Z2A3gt1r","col-sm-3-start":"UIcN_GXiPRoIsin8Kohg","col-sm-3-end":"GRKCyqb5LufCSCgykKFc","col-sm-4":"i_qTq8gqhhC3vIUepVRB","col-sm-4-start":"G3qaZ3Jpbvam_1XvGxgc","col-sm-4-end":"VRCNYKZtO9zukEwmgP1y","col-md-1":"tRm008K_WJL79WoNZTNL","col-md-1-start":"l5T2P_bgKts4tdaRkS1d","col-md-1-end":"zOCxfLZpF6BlgC7a_Yq1","col-md-2":"F80DdgVn0m5OpvtSQWka","col-md-2-start":"oI1c7JYfiJtMQHbhngtU","col-md-2-end":"pMQtA_4jh1_1lVknqEP5","col-md-3":"VenqMpdgyKQVUNNQcfqd","col-md-3-start":"seNYL99uoczf9V4MxBxT","col-md-3-end":"YKfF1HFhI9KygA5l3b2J","col-md-4":"yAi0Cv1xDWkoqsaUhvhR","col-md-4-start":"ubhnyZOnkgxNhh6XtVWv","col-md-4-end":"RGOPGQbWMJ9Ei5oFxS7X","col-md-5":"Sz1E2aWbX483ijdi6yge","col-md-5-start":"tku6_bRYrX9tMbgYGmIl","col-md-5-end":"b5JHttOhSEcI1WBlqAjk","col-md-6":"FboSx5MoKTAWbxXyYlCw","col-md-6-start":"Jhs8yEEmodG30edbJvag","col-md-6-end":"IpzbbKVqEqPcfIGkXkwt","col-md-7":"mhCPwfAZ4Kmm_empzJAq","col-md-7-start":"x034ilrJF7rO9UJB2rI1","col-md-7-end":"Wt8t2e16viRrOJ1lLA5v","col-md-8":"S6pIrEy9AMLKx9bgh_Ae","col-md-8-start":"kEfI4tGyuWfHTlRnvIab","col-md-8-end":"PUzX4RRsKq1dnsz3gebS","col-lg-1":"X_pdcLJikd8LS_YAdJlB","col-lg-1-start":"tl936d14Huby4khYp05X","col-lg-1-end":"hnge0LnR69d3NXEtEE1t","col-lg-2":"fj0NUMuyZQcPNgKcjp5Z","col-lg-2-start":"R2ncBX7a2NigdYCcV1OX","col-lg-2-end":"t8vMSDVYno9k9itRwnXb","col-lg-3":"wsDuEN2GqHx6qzo8dUdk","col-lg-3-start":"cIEVPUweWtLBy3xaXnMx","col-lg-3-end":"fajUWBwu1m2B479j3jmz","col-lg-4":"YR0c7fQTgMkDdWzwSyLp","col-lg-4-start":"xlwp8BmplxkKNMI7gamo","col-lg-4-end":"_C4O1w9DUqx1m3gPf8aA","col-lg-5":"Z54F1hAErckAIrKlxnXW","col-lg-5-start":"ezSDWkRHmKSxDJXxuiOH","col-lg-5-end":"T0ChoeAjGJjkkNrYhD4g","col-lg-6":"qtMoMPF6yHvGJnWHSsde","col-lg-6-start":"gdoywN5VPiWERfIBqkph","col-lg-6-end":"wUev_VH5uf_pwFFlbnAU","col-lg-7":"egIPDFJsOpownTClq9XP","col-lg-7-start":"yGhp9yoAW7k0kQik9AB7","col-lg-7-end":"SJ43U9mR5wUg5V2qBeQA","col-lg-8":"cTuyHfMwSUJxN_HdIEgd","col-lg-8-start":"smCr8DaIagcumdvdldiK","col-lg-8-end":"T03NHzQJvzwL6wAfIiTL","col-lg-9":"pMvxM3RJGjqyNdf9qg1Y","col-lg-9-start":"iIVpNRwEnQ_JI5gpp9EN","col-lg-9-end":"ZbQ4u4vGSX5rJOje4uGL","col-lg-10":"gKb5wuIDAlKGbrjK2vxy","col-lg-10-start":"Z7pINdImE2WJiYnZBTqm","col-lg-10-end":"ZTxp6qpvwurMdOnLLSz1","col-lg-11":"NnQTlbfnxPDR6cQ7rygg","col-lg-11-start":"O137wZd6Yl0olSA9PsXR","col-lg-11-end":"zf2OJtQ2MPz6SDoh6CB0","col-lg-12":"U3H6UHW6HqRt9hdzVg3O","col-lg-12-start":"zynnNeS_ZBTxABcVpUQH","col-lg-12-end":"vI8tltFZtFUNAy9Iag9s"}},51519:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={sm:"(max-width: 599px)",md:"(min-width: 600px) and (max-width: 959px)",lg:"(min-width: 960px)",container:"SqdhUZkXCRuIpErj1B3z",fluid:"OZC_9a1LhpWF9dv15Gdh"}},4097:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"VHYulMcpzbr10HWR0iSE","icon-wrapper":"FGpSkMCiIHQjszcV0dbn","close-button":"KoWZcCwhW13xvkEb0QON","main-content":"smrfczkC53EaFM8OJUXs",title:"IKYRWoPwt9xOVEx1wzNS","action-bar":"qM0qY6mPYp1MPN54A3Kg","is-error":"A5YkDkkXuiYgavrY6Nux",icon:"y_IPyP1wIAOhyNaqvXJq","is-warning":"cT5rwuPMZzWvi5o6shMl","is-info":"yo0O3uvNomPsYUXFCpAS","is-success":"oZdDFf1jBLkzn5ICCC6x"}},13149:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"p4qz2tkq0p9hxucJ6Qk2",table:"lbNDyXioOwvyvbALtCBm","is-viewport-large":"s2Lsn4kbm6BrS3DSndRB",card:"cLaNK_XcbTGlRQ4Tp43Q","is-primary":"CYt1X0eH1icRjhtJ28jx",header:"DAkZc1P9A3K12fjEliMg",item:"WUBuYABl8nymjs9NnCEL","last-feature":"ANtCFeb41NhA8PA3H7ZN",value:"Ql2gy_148yW8Vw5vhaKD",icon:"EAQrAnQEW1z1BfdY5gbC","icon-check":"JDSTlLoOC_4aUoH2oNM2","icon-cross":"zNdQRJ1w7BvaQOYyqzHK",popover:"lr7vbX95SKtoe7DarJcZ","popover-icon":"KRrGp2xdkeBOxLZeuQ6X",tos:"H_ZJiRVJg0LiMXPGOcmt","tos-container":"x21z_DixObRDsDaWotP1"}},76066:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"dovianZYLKhnbnh9I06o","price-container":"lljtQMhW7lq5tE5SDJEf","promo-label":"NubApIV1vQCRUNprfm6b",price:"dhFQXpZfMwVI8vuYHnwC","is-not-off-price":"eD7hzxFmdtG_MgmBtl_k",footer:"C64ZjjUAqJC1T2Sa7apS",legend:"UpZDGew6Ay1hPoP6eI7b",symbol:"TDiiPbuW1Z0_05u_pvcK"}},49986:()=>{},36001:()=>{},63132:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={reset:"WQVtrU6q0L1Igcj7wCrQ","headline-medium":"UujoBFTnQNY2cWU2SIsH","headline-small":"TeGO5V_thHw5lDAm1_2M","headline-small-regular":"WolQzb2MsSgiNmLtc7_j","title-medium":"hUB0JT8p1T2Hw28N6qC8","title-medium-semi-bold":"gKZWDv5chz3_O3Syp74H","title-small":"zY2No8Ga4b8shbOQGhnv",body:"tIj0D1t8Cc892ikmgFPZ","body-small":"KdcN0BnOaVeVhyLRKqhS","body-extra-small":"dso3Rh3tl3Xv1GumBktz","body-extra-small-bold":"mQ1UlbN9u4Mg9byO8m7v",label:"PItlW5vRExLnTj4a8eLE","m-0":"TwRpPlktzxhmFVeua7P5","mx-0":"zVfqx7gyb3o9mxfGynn1","my-0":"iSHVzNiB9iVleGljaQxy","mt-0":"xqDIp6cNVr_E6RXaiPyD","mr-0":"S8EwaXk1kyPizt6x4WH2","mb-0":"ODX5Vr1TARoLFkDDFooD","ml-0":"cphJ8dCpfimnky7P2FHg","m-1":"PFgIhNxIyiSuNvQjAIYj","mx-1":"M2jKmUzDxvJjjVEPU3zn","my-1":"io15gAh8tMTNbSEfwJKk","mt-1":"rcTN5uw9xIEeMEGL3Xi_","mr-1":"CQSkybjq2TcRM1Xo9COV","mb-1":"hfqOWgq6_MEGdFE82eOY","ml-1":"I8MxZQYTbuu595yfesWA","m-2":"kQkc6rmdpvLKPkyoJtVQ","mx-2":"j6vFPxWuu4Jan2ldoxpp","my-2":"hqr39dC4H_AbactPAkCG","mt-2":"c3dQnMi16C6J6Ecy4283","mr-2":"YNZmHOuRo6hU7zzKfPdP","mb-2":"Db8lbak1_wunpPk8NwKU","ml-2":"ftsYE5J9hLzquQ0tA5dY","m-3":"Det4MHzLUW7EeDnafPzq","mx-3":"h_8EEAztC29Vve1datb5","my-3":"YXIXJ0h1k47u6hzK8KcM","mt-3":"soADBBkcIKCBXzCTuV9_","mr-3":"zSX59ziEaEWGjnpZa4uV","mb-3":"yrVTnq_WBMbejg89c2ZQ","ml-3":"UKtHPJnI2cXBWtPDm5hM","m-4":"guexok_Tqd5Tf52hRlbT","mx-4":"oS1E2KfTBZkJ3F0tN7T6","my-4":"DN1OhhXi6AoBgEdDSbGd","mt-4":"ot2kkMcYHv53hLZ4LSn0","mr-4":"A1krOZZhlQ6Sp8Cy4bly","mb-4":"pkDbXXXL32237M0hokEh","ml-4":"XXv4kDTGvEnQeuGKOPU3","m-5":"yGqHk1a57gaISwkXwXe6","mx-5":"X8cghM358X3DkXLc9aNK","my-5":"GdfSmGwHlFnN2S6xBn1f","mt-5":"yqeuzwyGQ7zG0avrGqi_","mr-5":"g9emeCkuHvYhveiJbfXO","mb-5":"Lvk3dqcyHbZ07QCRlrUQ","ml-5":"r3yQECDQ9qX0XZzXlVAg","m-6":"aQhlPwht2Cz1X_63Miw0","mx-6":"JyHb0vK3wJgpblL9s5j8","my-6":"cY2gULL1lAv6WPNIRuf3","mt-6":"NBWQ9Lwhh_fnry3lg_p7","mr-6":"yIOniNe5E40C8fWvBm5V","mb-6":"t30usboNSyqfQWIwHvT3","ml-6":"Nm_TyFkYCMhOoghoToKJ","m-7":"C4qJKoBXpgKtpmrqtEKB","mx-7":"S93Srbu6NQ_PBr7DmTiD","my-7":"fJj8k6gGJDks3crUZxOS","mt-7":"cW6D6djs7Ppm7fD7TeoV","mr-7":"DuCnqNfcxcP3Z__Yo5Ro","mb-7":"im8407m2fw5vOg7O2zsw","ml-7":"G0fbeBgvz2sh3uTP9gNl","m-8":"kvW3sBCxRxUqz1jrVMJl","mx-8":"tOjEqjLONQdkiYx_XRnw","my-8":"op5hFSx318zgxsoZZNLN","mt-8":"c9WfNHP6TFKWIfLxv52J","mr-8":"sBA75QqcqRwwYSHJh2wc","mb-8":"GpL6idrXmSOM6jB8Ohsf","ml-8":"HbtWJoQwpgGycz8dGzeT","p-0":"uxX3khU88VQ_Ah49Ejsa","px-0":"KX0FhpBKwKzs9fOUdbNz","py-0":"PfK8vKDyN32dnimlzYjz","pt-0":"emxLHRjQuJsImnPbQIzE","pr-0":"kJ8WzlpTVgdViXt8ukP9","pb-0":"tg_UIUI11VBzrTAn2AzJ","pl-0":"uczvl8kaz84oPQJ2DB2R","p-1":"o7UHPcdVK3lt7q3lqV4o","px-1":"IDqEOxvDoYrFYxELPmtX","py-1":"DdywPW2qSYlu2pt8tpO2","pt-1":"npy3hw4A5QSkDicb2CJJ","pr-1":"LgbptTApNY5NwLQvEFAt","pb-1":"WZQy2SZuZso59bUsXXyl","pl-1":"o331apInxNunbYB3SfPE","p-2":"fMPIyD9Vqki1Lrc_yJnG","px-2":"i2pMcTcdrr10IQoiSm_L","py-2":"eA702gn32kwptiI1obXH","pt-2":"o9bGieUKcYc8o0Ij9oZX","pr-2":"SwZcFez1RDqWsOFjB5iG","pb-2":"eHpLc_idmuEqeqCTvqkN","pl-2":"vU39i2B4P1fUTMB2l6Vo","p-3":"JHWNzBnE29awhdu5BEh1","px-3":"X72lGbb56L3KFzC2xQ9N","py-3":"BzfNhRG8wXdCEB5ocQ6e","pt-3":"srV0KSDC83a2fiimSMMQ","pr-3":"lUWfkmbQjCskhcNwkyCm","pb-3":"Ts0dIlc3aTSL7V4cIHis","pl-3":"CzlqQXXhX6MvorArFZ8B","p-4":"TqMPkQtR_DdZuKb5vBoV","px-4":"a7UrjhI69Vetlcj9ZVzz","py-4":"StEhBzGs2Gi5dDEkjhAv","pt-4":"FGneZfZyvYrt1dG0zcnm","pr-4":"APEH216rpdlJWgD2fHc8","pb-4":"oGwXC3ohCic9XnAj6x69","pl-4":"U6gnT9y42ViPNOcNzBwb","p-5":"IpdRLBwnHqbqFrixgbYC","px-5":"HgNeXvkBa9o3bQ5fvFZm","py-5":"tJtFZM3XfPG9v9TSDfN1","pt-5":"PdifHW45QeXYfK568uD8","pr-5":"mbLkWTTZ0Za_BBbFZ5b2","pb-5":"vVWpZpLlWrkTt0hMk8XU","pl-5":"RxfaJj5a1Nt6IavEo5Zl","p-6":"SppJULDGdnOGcjZNCYBy","px-6":"palY2nLwdoyooPUm9Hhk","py-6":"WYw1JvZC0ppLdvSAPhr_","pt-6":"YEEJ9b90ueQaPfiU8aeN","pr-6":"QE0ssnsKvWJMqlhPbY5u","pb-6":"n8yA3jHlMRyLd5UIfoND","pl-6":"tXHmxYnHzbwtfxEaG51n","p-7":"kBTsPKkO_3g_tLkj77Um","px-7":"RyhrFx6Y1FGDrGAAyaxm","py-7":"CBwRpB0bDN3iEdQPPMJO","pt-7":"vQVSq6SvWKbOMu6r4H6b","pr-7":"oBy5__aEADMsH46mrgFX","pb-7":"KVEXoJqf1s92j0JMdNmN","pl-7":"ZMXGNrNaKW3k_3TLz0Fq","p-8":"tuiR9PhkHXhGyEgzRZRI","px-8":"U7454qyWkQNa2iaSJziu","py-8":"VLYIv2GVocjuN93e8HC8","pt-8":"X1rm9DQ1zLGLfogja5Gn","pr-8":"JS7G6kAuqJo5GIuF8S5t","pb-8":"Y8F9ga1TDCMbM1lj4gUz","pl-8":"AJuyNGrI63BOWql719H8"}},69973:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={global:"_fUXxnSp5pagKBp9gSN7"}},85157:()=>{},45067:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"jp-wrap":"EiaNctK1_P9pPqOeiaSI","jp-row":"ogHZg_sJCljylz3VJfsf","sm-col-span-1":"zv7eGvijKRkbPVakubHw","sm-col-span-2":"VoJNoiya_1ck3_kXS6_C","sm-col-span-3":"ecv0NO526NoTNbpALA1A","sm-col-span-4":"OfBdkceMzeHvRbzhqDlP","md-col-span-1":"JLb3NpEKN8pOaWd7K1bu","md-col-span-2":"fsMPGqPKE4mjMIPFwl77","md-col-span-3":"DIK_zdaGAQ09eKspBJ4E","md-col-span-4":"shXYpxPu3WCJsR8aOHtz","md-col-span-5":"s7ElrOqG_yGd5SIfwqOR","md-col-span-6":"Cxml9uzGvArAL8_RDs_p","md-col-span-7":"aANxBKDGx72eDqU0iUPj","md-col-span-8":"XxyzuTY3mnQcl9EGZadm","lg-col-span-1":"Sfo4WaSNIWInJ93Abd3w","lg-col-span-2":"tQS7SKUGrU4THhWMysbo","lg-col-span-3":"I94U7mpY4h16pcOksZNF","lg-col-span-4":"uWMb9k77kQxBdS5MTt0s","lg-col-span-5":"rKwEEZQxK9s_POMg5Jss","lg-col-span-6":"UcPXX_s06IPCkF7ZjH3D","lg-col-span-7":"CrQdtiCFkRbzY6K2dFvt","lg-col-span-8":"rEUALOmOdUBXO0Us871z","lg-col-span-9":"NqXa9TlcTEviVsB53hBV","lg-col-span-10":"OnWVeiQiwgQ9lzdGPW66","lg-col-span-11":"D2PkTcy7b8u2K9QXY6VQ","lg-col-span-12":"EcqBhzAyxo5RDc2Y6m7K","md-col-span-0":"gB1mWzHOM38d80lrhBRX","sm-col-span-0":"KNQXLP78ejczOkour3zg","jp-cut":"rBVbaVWBnBRtTMrUKZxm",modal:"gfM_DIJrVbRhmKdAphIm","jetpack-logo":"zfJfONxRAw0fHjXUS7LN",animating:"pnwbCuWbV0PNQr1LFpRh",button:"_j4GWTmW5psCHFYh6R0x",headline:"saSAjv8yulVXQDoqDJEI",paragraph:"O_hcdbeMivIhBn7ApDnS","jetpack-logo-triangles":"FCnyb_xCK7DhJ63p6TEd","video-wrap":"Qn5xayjI_jH2m1d6BEoq",videoMove:"OmAVpCQ270MqI4IsT9Ky",slidein:"Axe8f2LgqEBZHVcsRgY5","content-wrap":"iBMDoShSmqpt72YfJb36","hi-user":"eQG1KKK8jjKtQyzfv573","content-wrap-text":"l35bIyiqYJiZ6tVYvJtC","powers-wrap":"HQVDZ6J3x6SJNYFX5khS","jetpack-products":"KdvmPIjelQIFiPQGuIYf"}},19686:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"action-button-dropdown":"IorMv97NU2iEXtcbbVoN","dropdown-item":"_I09VyiyxzT6EKE6RwVF","dropdown-item-label":"Gmum0UGKXz4YlMG9Fwgm","active-action-checkmark":"przPMe99k8Mad0jsxI1R","action-button":"vRIYDzW5yrfnUoDPdBAN","dropdown-chevron":"KIyEfIhAZ4TElM0K5kuH",primary:"V4VpHqht9Rm42tiZfsxU",secondary:"vZfbVKYvaUjhpAuMD9jg","has-additional-actions":"SlMzf1xQ5c9GfEx2RQgv"}},8757:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"OpMBda4vebhRbW8Fm6YC","is-link":"BghJAx9hSagUdHWOUaYE","has-error":"IWsEW5nnNWUqqcT3K5L1",title:"r3UCwgwCthua6lDCvIBI",name:"vpluqUMgmwx9_f8wCVIn"}},91469:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={icon:"rV_5QyvhDnsVjCX4pb0h",link:"MO1jDNY8VPqeNS9xL8jE"}},96007:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"relative-col":"zvd4dCB_bBDiXJKKDqXm","close-link":"ly4o9lSswAGHFXqGUEIO","account-description":"u64Go3kwEZ7MD9eji0H1","account-images":"_RT41NE3LU4R0ubcij2y",wordpress:"cFGWJeRiGHjAr8D7CWJW",google:"Iz3l7a05TP6HK9S92TIL",apple:"lmQ0wFmnk4kKkGVjokPA",github:"ZSFTmY3zE3VP4w0QeaqV","all-features":"AoIs8wD92wKR8RpQj6Uc"}},15200:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"connection-status-card":"kezuOHNvu9vdvlJ86Fwg",status:"qJizORs2q_CVCj9L6XLe","avatar-wrapper":"VmtuLc2xRqmsO6cK8qjF",cloud:"MdTRfQ3eo5qZKChZlzNj",jetpack:"PbEpL02SEH9VNAlbKCfV",avatar:"TD4AUM9gcTVAB6JHB5ZR",line:"yjl73qv0VWoPP8IhGreh",error:"J0GIu2rNR7rXocQTyd8p",warning:"rAV2E93SG8WpokuGk9jh",info:"YZ7FNKEm9qpvQ4ZkbAz5","connect-action":"TYNMsILey2vUwnyZSjJU","list-item":"oH9tzGE80LnB6Og69RFz","list-item-text":"xXVEWvQllVsFGmJY8WEp",success:"q4_FOHifGawULuFBZke9"}},66746:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={title:"iG63b_J1HNfT8xEIq619","dropdown-menu":"T8UhA3lZQjpZsyaah9J6","evaluation-footer-link":"Tobf3RFq_fT42YGp_h4g","recommendations-list":"g69ZGQc9wey1u1beD0IP","slider-button":"aWIwsRSR2EZlTGwFYt5J","prev-button":"DzezAg6fdaIC26GPBCvD","next-button":"buuFW6iZyD5Nnljxcxj8"}},21751:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={icon:"hdasSNj9k3Sc5PwXK4uE",link:"eWN8Hj0SBRDq1F48n_Fg"}},71587:()=>{},32976:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"jp-wrap":"yWUvvF4WJLNDSpMgBMfm","jp-row":"ka1fVHj2HOkHjhdoEFOZ","sm-col-span-1":"JMOO4Y_9yhTO9lwLnRUx","sm-col-span-2":"PFDPAqk51qox_ChLqJwm","sm-col-span-3":"ault0jHVfWpShqOGooIP","sm-col-span-4":"GqpvdRzmzPJELtSm4FEN","md-col-span-1":"Ym4_YneEGD_iZD6W1C2o","md-col-span-2":"NbvHnnDtWw8n9BEUQ0Oy","md-col-span-3":"ElMT7rhxe5ZJKO41MnhW","md-col-span-4":"yKjnqjibn_wW_1tWWt5Q","md-col-span-5":"Pb30lOcQFpzUX57GwflS","md-col-span-6":"pC1wxc_R8y4pNILHsiiY","md-col-span-7":"pChscSCnudQoWGjMFKI_","md-col-span-8":"qw1H2gAgF3lDCI2Tbkmb","lg-col-span-1":"VzcA_rrxBK3g4ozA0oD9","lg-col-span-2":"pNAa7O2adRZD8Slgk9iR","lg-col-span-3":"tlIMLlipexblj8CeOx4B","lg-col-span-4":"Dvt0u5l2Rr1BhBmvYAzl","lg-col-span-5":"BiUsgNTc0tyc7tC5jnzE","lg-col-span-6":"ulJXAsj7G2ROJ1g3_s28","lg-col-span-7":"HsoVlyVLsXYClx9Atox0","lg-col-span-8":"oXxjRQNNj2cfIpFBqC1W","lg-col-span-9":"qXgUn4Adg9xE_JnbuDio","lg-col-span-10":"xMpqTLiLfYFEJiRPQQQq","lg-col-span-11":"IiGo3Sz2FDZN7_eGElwA","lg-col-span-12":"Om8BNCjfgqQ_wmPQjfOY","md-col-span-0":"t10ZWzP7ADjJnR4tqxRS","sm-col-span-0":"eOUlZG8Pelh_Xj0aSoHG","jp-cut":"l546LrwBEePz434NFK5Q",logo:"Q7w4fcEcemZ2nlwaYNog",wrapper:"AoNQsOaTt6gSf0H6Yasz",helper:"v13ZwGzUnecPA7Y3URAl",container:"EeDbu9pXFWTsCzfTpv2v",title:"BmSvoIi3rErkcrRiOi2W",content:"mojRoVuWdDJo0E6LEjJw"}},90530:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={modal:"HeJe1crc9XaWWpLvIPit",container:"or0JUScxkJPmNsfrxkEK"}},42997:()=>{},99633:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={skeleton:"jUxY9oXwnEDQLadQBNQp","skeleton-loading":"odHEpyTWVIDgdJClTyHg",spaceBelow:"Vzu6IGmwfFGn5RPCIWOY"}},67328:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={heading:"jErCC9oKHSM15BxzFyQK",notice:"oVoYbwbFB6U2o90Njusk","bigger-than-medium":"Snc8NEmDelsbhlH4285s",cta:"R5tvcsARTGN0A_z3DygA",message:"wBVXH4OTNwLHPRpN4nsq",nofill:"F1qvEnFfHs5nz3zFZUOV",separator:"SrQxAOBa5ZaSKP8wlut9"}},89675:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"connection-form":"XsCIqtbkjCGvQuTEqP12",title:"FuIWMXR9G82lNoOWSg7Z",description:"VqV6BERV7qt2YRiC8ant","social-button":"H7h4wR1WKIziIFiwJpzN","social-button-text":"pSJyHDRGl_R9CF7J_wzX",separator:"TnFm4M8CVuTak6Vq2NsE",line:"eKWjmNNdlY3uWjVgR8RI","email-input-container":"Scnx4BQ8P2bIZ0YxBThk","email-input":"Ps4m_56jJQ5YgQb25OW0","submit-button":"IIUH0pxUdd27eEyqfQFI",tos:"IySisqLBT5FBSpx8ksyG"}},20260:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"jetpack-logo":"hs8vtMKdbmvStRLqOShe","onboarding-screen":"a2dTOxFWByKrVw1RIDQT",column:"q0k48EMOblqQLxSxIKZa","primary-column":"w9obJdf7GdvAmyMTJp12","seconday-column":"Jqm3k3aZ4rGDtBCVeocD",testimonials:"PhMWEQDEAfUHteBMf1hM"}},5423:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"wiobThfXJCuhGNrbFIT6","plan-container":"pm2EPQZx6p2VQSiiVCpX","expire-date":"VgAxgahF9bC2M__FiIgV","expire-date--with-icon":"dbRwkMLqcMF67njPoAF7","is-expired":"V8N_dXausMNmQUO_ROa1","is-expiring-soon":"jYhEGFLjpRv6QV1Ti7dQ","actions-list-item":"Doju0RxvvN9JS12mf489"}},76023:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"pIsYsXFAJ9KX2VrS5rmY","has-error":"Pp9cMIaESLYelLOX3tkI","has-warning":"NhOH6VeEpSrNGAPQik0w",description:"gmPKCDKZcfQt9WieTyKS",actions:"fDBaV7I4yUO6w5AWVEtr",buttons:"SelsBZT7eIWRQyl1dasZ",title:"LHYJUrOej3toDvOAiz4k",priceContainer:"aZvwqVNw6rvImSxn0DM9",price:"R4OXFRkmlHAH8ScIgYXh",discounted:"g0_8bbVjnVh0D_pS264j",term:"nqFgW_S2jbHPu9yPq9E_",status:"f5VJYwuJmjxH8PVxEbbv",active:"ry3pxoGtmQ0ZeSwp7F_3",inactive:"LZzE3EG7m3CDR46wwwEr",warning:"TZUP7W6QYGajITiMNYas",error:"Vx_jpT02r8W6NfsRSB02","is-fetching":"PdsJCfyyjSgrNDheF2qi","blink-animation":"dWP7ypkVXudMbAa38W5Z"}},52232:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"no-backup-stats":"wI7QgVzPXvVVu6kfnTT8","main-stats":"eqyxcUmdF0s3gmmlZGyD","main-stat":"gxY6D0PeVtGk9iSB5E_u","visual-stat":"D_uE0LD5CvpfM2FNp55k","more-stats":"VTBUdi1D4DW34F0yixMk",activity:"BXQQYCO_pEmYmzBBwYxR",summary:"qdvOzzbrd3KQK7DNg8eg",description:"PFbMp_gtGLBMWbbYtO0q",time:"ZFCNMiywyFvaifoIQI5w",backupWarning:"eKy3yAPsoarwSQMou_kk",iconError:"Bt6AOGkWP6xSfUbq2QBQ",backupErrorContainer:"GA8m1YdHe3xODczqUUor",iconContainer:"KixWjGbAhopt1dR0Hv9n",errorDescription:"iGcRsZkwWJW_WJglA1oO"}},14479:()=>{},6619:()=>{},10372:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"single-contextual-info":"g4lyov8aMDggdD4yOi1p","main-value":"Ys5ScZ_dYn2O2AzDE5Yi","single-contextual-info-placeholder":"sUNg_b7XteVXOrpHAkJg","contextual-percentage-change":"cF6QAJf1vXXAMuutXPcq",neutral:"coY634LconQ7gzDDNJeu",positive:"kyqpwKaL2FyQ8CtxJQ0f",negative:"aXf37lEOcjpNV8ImLaYK","change-icon":"OyGdoGzsQ48VaVVR99_H","change-values":"cKLicfMCaDSGPlX222jF",cardListTitle:"ZaPXoMGC_e8NfFoBgA95",fullStatsCard:"gb2kSZHPauLu96D9HAIg",cardlist:"qpN923qyxjI06NCgFC8j",valueSectionHeading:"hpd1bQCLIZYXpZJa22qw"}},20906:()=>{},21557:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={card:"q0T8YyQxRawhpDtvJjxI",container:"B7JDqI_vtKxSy5GjvqA1","card-header":"zj7xadmhIWeuf7ZwvVTS","product-bundle-icon":"GsioW6IsC8EMYE3U6788","product-bundle-icons":"dbz07JqxOlivjKO4vBEF","product-icon":"cfEO8udWbRGPFJzW8Jg5","plus-icon":"zlh3zbjUe4Z8cBs7uVVe","product-has-required-plan":"qoZuzG5EcDa231hC6t0P","checkout-button":"Q6uUUQCPWS6_6nLxIn68","components-spinner":"YU4iBCRze09ZP3iCsdcb","free-product-checkout-button":"OrQG7DjDd9Ha2Xj1Mx3L",features:"Q1jaYDpa2AVfJpA29wT0","highlight-last-feature":"HL4gSxsF0skYGhGuqH90",disclaimers:"sEcLfpWjo0GF7QrxD3Lt","price-container":"xgv3jRkeF39aEQELCwru",price:"twlleZ5Ehq4bB7CvKVSW","is-old":"Qg4rPEvXsqmod1s_31d8","price-description":"ApsgxIornVy_3KnciVeJ","supporting-info":"NMxcZL17aEP7v81uG3zD","tos-container":"gCTKfAPzJqZas7CaRbKN"}},68957:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={loadingBlockContainer:"iSc4n8zVaElbs0TPAWH5"}},34291:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"component-product-interstitial-modal":"uPEKVw20OlWzA_8u7YAc",wrapper:"dZO6FXcGE5vhcJ8Y_C9w","component-product-interstitial-modal__overlay":"FmxgyZZvzjuwp3GbBNv1",primary:"f6I4877w7XpHhEnooqks","primary-content":"EtaGFgAv0H3akflLBvof","price-container":"KGwdaPYtQhRLcUVbDyy9","primary-footer":"IwiPAQFH04pNmEH07X9N",secondary:"DKmru53sFgfEs9AgBdqM","modal-with-video":"anXLrcgHHsm2LnEfXUVk",additional:"pbC573UpPZ3Z1WF6H0rZ",features:"uQb9f6VHehuQfLoouBsQ"}},67691:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"svE2cJL5t2FarzcDQYNe",imageContainer:"dvEJEDNTnmVfVxtLa4uU",aiImageContainer:"K1VY4DNP8PHMWAEVBC_h","product-interstitial__header":"nk_COGPrkBNLp7lVt4sQ","product-interstitial__license-activation-link":"ukgQ5TmLablG3svUKjdw","not-strong":"Vofm70ADXSe43GamWEaF",card:"EUcF2LKeC2GyhWD2FKCP","buttons-row":"Bm21LIBQtpRo3ZhOxXBG","product-interstitial__product-header":"jwIGzADCnBI_ai9xYYiS","product-interstitial__product-header-name":"fTbxuhh_SfMgenyWvGN0","product-interstitial__hero-section":"eR56lApoP14RIBAhO1UN","product-interstitial__hero-content":"vHnITd5JOCOgxCgXTgoD","product-interstitial__hero-heading":"vAGLpjIGi6GA8ghbumN7","product-interstitial__hero-sub-heading":"oag8YaslCEiUVu8GKKL3","product-interstitial__hero-cta":"FhH03GPt9FK1VH9NZhYA","product-interstitial__hero-side":"VUXAtah2JvUCNc4cXjPp","stats-card":"dyPAjc3M4y3Q6gJfWnjw","stats-card-icon-check":"Ll1l9bEuf5G5oh3AENep","product-interstitial__stats-card-text":"WrzTysWiqUiuEPvpFqau","product-interstitial__stats-card-value":"d4faYkf9yL7oW7pwcjmP","product-interstitial__section":"acffvOSYc5S8x4P_AYnQ","product-interstitial__section-wrapper":"M5YNmgy60Q_UtaxKgQcv","product-interstitial__section-wrapper-wide":"HJiOvun8sHkiFpNL0sl6","product-interstitial__section-heading":"mXinUJfpSTS9EVB8M8K_","product-interstitial__section-sub-heading":"QKjsnliPyLu4n08yVUUM","product-interstitial__section-emoji":"xQJJkJ4v7Jm8iSJ0z0Dj","product-interstitial__usage-videos":"VWIBGwuHqtAKg_5Hch92","product-interstitial__usage-videos-item":"mnkNhprYIatxfziERMwM","product-interstitial__usage-videos-video":"WEiaYLqJwV2IzC8LD9Fs","product-interstitial__usage-videos-content":"GJlowVsJybna1MFcIiIU","product-interstitial__usage-videos-heading":"_OeUvI9GrP00qh6Uk7Tg","product-interstitial__usage-videos-text":"C6I5jYHW2IJSDBoKvhcB","product-interstitial__usage-videos-link":"XdnAdAwkxAW5yvUx3NRr","product-interstitial__ai-notice":"MCKgMfLVZtkgWu5m5u6L","product-interstitial__new-badge":"c0SItK48SRkWfZUCECbZ"}},9851:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={container:"SWwV4Pw6OZ5vU3PqPXmr",imageContainer:"r7tUofa9Z3A5ziKVR1H7",aiImageContainer:"i_AnOR3MaQLraGvb2QU5","product-interstitial__header":"YcYvLvdvWrb1EUZoVsE8","product-interstitial__license-activation-link":"uGTTsKoIOoZdYhk6uPnl","not-strong":"NzDTsxhX8D1mlckNpewR"}},76812:()=>{},71070:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={"section-stats-highlights":"Jvb1njqMy7ML1zikhbWn","section-title":"mpr8_ygU8woV4bVR1xvw","section-description":"gwO_Q0L0jbwMARVlBezu","cards-list":"qwy7CsLeEbXvaPwgC9WV","stats-card":"Hrbg7DeSJs6gas9zdPDR","stats-card-icon":"NFpbo5AINn6I6avKFGby","stats-card-heading":"aoQZCG0JeyWmy2J6vVxF","stats-card-count":"M6ApyXg79vuXo6GwDkbO","is-pointer":"DYHb5e6QhgXejWyo9s78","stats-card-count-value":"OlInbY5YnDO06MEQHv98","stats-card-difference":"EtbKbd5m85w7oYT4stIs","stats-card-difference--positive":"Awr7zl75sfAsFPHK9kDG","stats-card-difference--negative":"QFSZbIKFdWO3HEPBZyhc","stats-card-difference-icon":"GgJAnS4gaEEGmRCP5n8y","stats-card-difference-absolute-value":"mjiNtwdbKpfo9edGVes4",actions:"pAt4v_KG9Ir19wNcEtEj"}},52290:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r={banner:"jrGNTKcgeXk9HKzolut9","banner-card":"wg3mZsoPekZWlBgOvdZ6","is-mandatory":"aDxB89WgtARQqNWd4ZeK",dismiss:"sGP8lxDpRSjt0Fh7wxoR","banner-content":"z5EQSkU36nsjxHEBSfNN","banner-description":"MwBwVaEj6u_zRgfrFR9b","banner-image-evaluation":"UgPNtuFW7lTJ06k39EsK","is-selected":"ilVOud0_OCGK4HciazB_","banner-image":"EtcggGK0Bk8POQD986Og",form:"TSiu5sC6MdANROjUkUJM","form-checkbox":"iqJfpZM9IYXuFSXvuoEe","form-actions":"Vozbq8Inlk5SxoVnn2G5","form-link-action":"s_V1BM1Wtt3He4eF2TCu","loading-banner":"FMZ2bZdjMxKFePbMwRi3","loader-container":"eShkT8UhgFL0N__pJEA8",logo:"GZ2uVyfGabA_66Y8nmuF","circle-outline":"jkWzdt8A2twwREkaF2qX","circle-fill":"Ktcwz9OsGT_3yNKZq6BA","triangles-outline":"lZq4cdGYKYAgiVEYCtXw","triangles-fill":"WQpz4j3rH6uEqAXwDrR8",drawCircle:"w9IUcbm9vJHQeg2OXhtF",fadeIn:"xAohbjzRzlC5o13repbp","connection-ready":"iOKKzf48kelOFS8vRBwR",popIn:"OrGIdZzrmFu39hFSKNfg",recommendations:"OqFqx9KLY3auyUaWh5tp","products-icons":"JdllqWQef8TBWPF5UT6Z",slideDown:"_brJ7gDgGneDqAzmDSZG"}},75001:()=>{},44997:e=>{var t=1e3,a=60*t,r=60*a,o=24*r,n=7*o,l=365.25*o;function s(e,t,a,r){var o=t>=1.5*a;return Math.round(e/a)+" "+r+(o?"s":"")}e.exports=function(e,i){i=i||{};var c=typeof e;if("string"===c&&e.length>0)return function(e){if((e=String(e)).length>100)return;var s=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(!s)return;var i=parseFloat(s[1]);switch((s[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return i*l;case"weeks":case"week":case"w":return i*n;case"days":case"day":case"d":return i*o;case"hours":case"hour":case"hrs":case"hr":case"h":return i*r;case"minutes":case"minute":case"mins":case"min":case"m":return i*a;case"seconds":case"second":case"secs":case"sec":case"s":return i*t;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return i;default:return}}(e);if("number"===c&&isFinite(e))return i.long?function(e){var n=Math.abs(e);if(n>=o)return s(e,n,o,"day");if(n>=r)return s(e,n,r,"hour");if(n>=a)return s(e,n,a,"minute");if(n>=t)return s(e,n,t,"second");return e+" ms"}(e):function(e){var n=Math.abs(e);if(n>=o)return Math.round(e/o)+"d";if(n>=r)return Math.round(e/r)+"h";if(n>=a)return Math.round(e/a)+"m";if(n>=t)return Math.round(e/t)+"s";return e+"ms"}(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},15762:(e,t,a)=>{"use strict";var r=a(53761);function o(){}function n(){}n.resetWarningCache=o,e.exports=function(){function e(e,t,a,o,n,l){if(l!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var a={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:n,resetWarningCache:o};return a.PropTypes=a,a}},28120:(e,t,a)=>{e.exports=a(15762)()},53761:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},70028:(e,t,a)=>{"use strict";a.d(t,{I9:()=>v,N_:()=>h,ok:()=>w});var r=a(51609),o=a(75795),n=a(29539),l=a(36992);function s(){return s=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0||(o[a]=e[a]);return o}function c(e){return void 0===e&&(e=""),new URLSearchParams("string"==typeof e||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce(((t,a)=>{let r=e[a];return t.concat(Array.isArray(r)?r.map((e=>[a,e])):[[a,r]])}),[]))}new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);const u=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"];try{window.__reactRouterVersion="6"}catch(e){}new Map;const d=r.startTransition;o.flushSync,r.useId;function v(e){let{basename:t,children:a,future:o,window:s}=e,i=r.useRef();null==i.current&&(i.current=(0,l.TM)({window:s,v5Compat:!0}));let c=i.current,[u,v]=r.useState({action:c.action,location:c.location}),{v7_startTransition:p}=o||{},m=r.useCallback((e=>{p&&d?d((()=>v(e))):v(e)}),[v,p]);return r.useLayoutEffect((()=>c.listen(m)),[c,m]),r.useEffect((()=>(0,n.V8)(o)),[o]),r.createElement(n.Ix,{basename:t,children:a,location:u.location,navigationType:u.action,navigator:c,future:o})}const p="undefined"!=typeof window&&void 0!==window.document&&void 0!==window.document.createElement,m=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,h=r.forwardRef((function(e,t){let a,{onClick:o,relative:c,reloadDocument:d,replace:v,state:h,target:f,to:g,preventScrollReset:w,viewTransition:b}=e,y=i(e,u),{basename:x}=r.useContext(n.jb),_=!1;if("string"==typeof g&&m.test(g)&&(a=g,p))try{let e=new URL(window.location.href),t=g.startsWith("//")?new URL(e.protocol+g):new URL(g),a=(0,l.pb)(t.pathname,x);t.origin===e.origin&&null!=a?g=a+t.search+t.hash:_=!0}catch(e){}let k=(0,n.$P)(g,{relative:c}),E=function(e,t){let{target:a,replace:o,state:s,preventScrollReset:i,relative:c,viewTransition:u}=void 0===t?{}:t,d=(0,n.Zp)(),v=(0,n.zy)(),p=(0,n.x$)(e,{relative:c});return r.useCallback((t=>{if(function(e,t){return!(0!==e.button||t&&"_self"!==t||function(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}(e))}(t,a)){t.preventDefault();let a=void 0!==o?o:(0,l.AO)(v)===(0,l.AO)(p);d(e,{replace:a,state:s,preventScrollReset:i,relative:c,viewTransition:u})}}),[v,d,p,o,s,a,e,i,c,u])}(g,{replace:v,state:h,target:f,preventScrollReset:w,relative:c,viewTransition:b});return r.createElement("a",s({},y,{href:a||k,onClick:_||d?o:function(e){o&&o(e),e.defaultPrevented||E(e)},ref:t,target:f}))}));var f,g;function w(e){let t=r.useRef(c(e)),a=r.useRef(!1),o=(0,n.zy)(),l=r.useMemo((()=>function(e,t){let a=c(e);return t&&t.forEach(((e,r)=>{a.has(r)||t.getAll(r).forEach((e=>{a.append(r,e)}))})),a}(o.search,a.current?null:t.current)),[o.search]),s=(0,n.Zp)(),i=r.useCallback(((e,t)=>{const r=c("function"==typeof e?e(l):e);a.current=!0,s("?"+r,t)}),[s,l]);return[l,i]}(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(f||(f={})),function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"}(g||(g={}))},29539:(e,t,a)=>{"use strict";a.d(t,{$P:()=>v,BV:()=>N,C5:()=>H,Ix:()=>O,V8:()=>z,Zp:()=>f,g:()=>g,jb:()=>i,qh:()=>L,x$:()=>w,zy:()=>m});var r=a(51609),o=a(36992);function n(){return n=Object.assign?Object.assign.bind():function(e){for(var t=1;t{a.current=!0})),r.useCallback((function(r,o){void 0===o&&(o={}),a.current&&("number"==typeof r?e.navigate(r):e.navigate(r,n({fromRouteId:t},o)))}),[e,t])}():function(){p()||(0,o.Oi)(!1);let e=r.useContext(l),{basename:t,future:a,navigator:n}=r.useContext(i),{matches:s}=r.useContext(u),{pathname:c}=m(),d=JSON.stringify((0,o.yD)(s,a.v7_relativeSplatPath)),v=r.useRef(!1);return h((()=>{v.current=!0})),r.useCallback((function(a,r){if(void 0===r&&(r={}),!v.current)return;if("number"==typeof a)return void n.go(a);let l=(0,o.Gh)(a,JSON.parse(d),c,"path"===r.relative);null==e&&"/"!==t&&(l.pathname="/"===l.pathname?t:(0,o.HS)([t,l.pathname])),(r.replace?n.replace:n.push)(l,r.state,r)}),[t,n,d,c,e])}()}function g(){let{matches:e}=r.useContext(u),t=e[e.length-1];return t?t.params:{}}function w(e,t){let{relative:a}=void 0===t?{}:t,{future:n}=r.useContext(i),{matches:l}=r.useContext(u),{pathname:s}=m(),c=JSON.stringify((0,o.yD)(l,n.v7_relativeSplatPath));return r.useMemo((()=>(0,o.Gh)(e,JSON.parse(c),s,"path"===a)),[e,c,s,a])}function b(e,t,a,l){p()||(0,o.Oi)(!1);let{navigator:s}=r.useContext(i),{matches:d}=r.useContext(u),v=d[d.length-1],h=v?v.params:{},f=(v&&v.pathname,v?v.pathnameBase:"/");v&&v.route;let g,w=m();if(t){var b;let e="string"==typeof t?(0,o.Rr)(t):t;"/"===f||(null==(b=e.pathname)?void 0:b.startsWith(f))||(0,o.Oi)(!1),g=e}else g=w;let y=g.pathname||"/",x=y;if("/"!==f){let e=f.replace(/^\//,"").split("/");x="/"+y.replace(/^\//,"").split("/").slice(e.length).join("/")}let _=(0,o.ue)(e,{pathname:x});let k=E(_&&_.map((e=>Object.assign({},e,{params:Object.assign({},h,e.params),pathname:(0,o.HS)([f,s.encodeLocation?s.encodeLocation(e.pathname).pathname:e.pathname]),pathnameBase:"/"===e.pathnameBase?f:(0,o.HS)([f,s.encodeLocation?s.encodeLocation(e.pathnameBase).pathname:e.pathnameBase])}))),d,a,l);return t&&k?r.createElement(c.Provider,{value:{location:n({pathname:"/",search:"",hash:"",state:null,key:"default"},g),navigationType:o.rc.Pop}},k):k}function y(){let e=function(){var e;let t=r.useContext(d),a=S(j.UseRouteError),o=P(j.UseRouteError);if(void 0!==t)return t;return null==(e=a.errors)?void 0:e[o]}(),t=(0,o.pX)(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),a=e instanceof Error?e.stack:null,n="rgba(200,200,200, 0.5)",l={padding:"0.5rem",backgroundColor:n};return r.createElement(r.Fragment,null,r.createElement("h2",null,"Unexpected Application Error!"),r.createElement("h3",{style:{fontStyle:"italic"}},t),a?r.createElement("pre",{style:l},a):null,null)}const x=r.createElement(y,null);class _ extends r.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||"idle"!==t.revalidation&&"idle"===e.revalidation?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:void 0!==e.error?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){console.error("React Router caught the following error during render",e,t)}render(){return void 0!==this.state.error?r.createElement(u.Provider,{value:this.props.routeContext},r.createElement(d.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function k(e){let{routeContext:t,match:a,children:o}=e,n=r.useContext(l);return n&&n.static&&n.staticContext&&(a.route.errorElement||a.route.ErrorBoundary)&&(n.staticContext._deepestRenderedBoundaryId=a.route.id),r.createElement(u.Provider,{value:t},o)}function E(e,t,a,n){var l;if(void 0===t&&(t=[]),void 0===a&&(a=null),void 0===n&&(n=null),null==e){var s;if(!a)return null;if(a.errors)e=a.matches;else{if(!(null!=(s=n)&&s.v7_partialHydration&&0===t.length&&!a.initialized&&a.matches.length>0))return null;e=a.matches}}let i=e,c=null==(l=a)?void 0:l.errors;if(null!=c){let e=i.findIndex((e=>e.route.id&&void 0!==(null==c?void 0:c[e.route.id])));e>=0||(0,o.Oi)(!1),i=i.slice(0,Math.min(i.length,e+1))}let u=!1,d=-1;if(a&&n&&n.v7_partialHydration)for(let e=0;e=0?i.slice(0,d+1):[i[0]];break}}}return i.reduceRight(((e,o,n)=>{let l,s=!1,v=null,p=null;var m;a&&(l=c&&o.route.id?c[o.route.id]:void 0,v=o.route.errorElement||x,u&&(d<0&&0===n?(m="route-fallback",!1||R[m]||(R[m]=!0),s=!0,p=null):d===n&&(s=!0,p=o.route.hydrateFallbackElement||null)));let h=t.concat(i.slice(0,n+1)),f=()=>{let t;return t=l?v:s?p:o.route.Component?r.createElement(o.route.Component,null):o.route.element?o.route.element:e,r.createElement(k,{match:o,routeContext:{outlet:e,matches:h,isDataRoute:null!=a},children:t})};return a&&(o.route.ErrorBoundary||o.route.errorElement||0===n)?r.createElement(_,{location:a.location,revalidation:a.revalidation,component:v,error:l,children:f(),routeContext:{outlet:null,matches:h,isDataRoute:!0}}):f()}),null)}var C=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(C||{}),j=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(j||{});function A(e){let t=r.useContext(l);return t||(0,o.Oi)(!1),t}function S(e){let t=r.useContext(s);return t||(0,o.Oi)(!1),t}function P(e){let t=function(){let e=r.useContext(u);return e||(0,o.Oi)(!1),e}(),a=t.matches[t.matches.length-1];return a.route.id||(0,o.Oi)(!1),a.route.id}const R={};const M={};const V=(e,t,a)=>{var r;M[r="⚠️ React Router Future Flag Warning: "+t+". You can use the `"+e+"` future flag to opt-in early. For more information, see "+a+"."]||(M[r]=!0,console.warn(r))};function z(e,t){void 0===(null==e?void 0:e.v7_startTransition)&&V("v7_startTransition","React Router will begin wrapping state updates in `React.startTransition` in v7","https://reactrouter.com/v6/upgrading/future#v7_starttransition"),void 0!==(null==e?void 0:e.v7_relativeSplatPath)||t&&t.v7_relativeSplatPath||V("v7_relativeSplatPath","Relative route resolution within Splat routes is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath"),t&&(void 0===t.v7_fetcherPersist&&V("v7_fetcherPersist","The persistence behavior of fetchers is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_fetcherpersist"),void 0===t.v7_normalizeFormMethod&&V("v7_normalizeFormMethod","Casing of `formMethod` fields is being normalized to uppercase in v7","https://reactrouter.com/v6/upgrading/future#v7_normalizeformmethod"),void 0===t.v7_partialHydration&&V("v7_partialHydration","`RouterProvider` hydration behavior is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_partialhydration"),void 0===t.v7_skipActionErrorRevalidation&&V("v7_skipActionErrorRevalidation","The revalidation behavior after 4xx/5xx `action` responses is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_skipactionerrorrevalidation"))}r.startTransition;function H(e){let{to:t,replace:a,state:n,relative:l}=e;p()||(0,o.Oi)(!1);let{future:s,static:c}=r.useContext(i),{matches:d}=r.useContext(u),{pathname:v}=m(),h=f(),g=(0,o.Gh)(t,(0,o.yD)(d,s.v7_relativeSplatPath),v,"path"===l),w=JSON.stringify(g);return r.useEffect((()=>h(JSON.parse(w),{replace:a,state:n,relative:l})),[h,w,l,a,n]),null}function L(e){(0,o.Oi)(!1)}function O(e){let{basename:t="/",children:a=null,location:l,navigationType:s=o.rc.Pop,navigator:u,static:d=!1,future:v}=e;p()&&(0,o.Oi)(!1);let m=t.replace(/^\/*/,"/"),h=r.useMemo((()=>({basename:m,navigator:u,static:d,future:n({v7_relativeSplatPath:!1},v)})),[m,v,u,d]);"string"==typeof l&&(l=(0,o.Rr)(l));let{pathname:f="/",search:g="",hash:w="",state:b=null,key:y="default"}=l,x=r.useMemo((()=>{let e=(0,o.pb)(f,m);return null==e?null:{location:{pathname:e,search:g,hash:w,state:b,key:y},navigationType:s}}),[m,f,g,w,b,y,s]);return null==x?null:r.createElement(i.Provider,{value:h},r.createElement(c.Provider,{children:a,value:x}))}function N(e){let{children:t,location:a}=e;return b(I(t),a)}new Promise((()=>{}));r.Component;function I(e,t){void 0===t&&(t=[]);let a=[];return r.Children.forEach(e,((e,n)=>{if(!r.isValidElement(e))return;let l=[...t,n];if(e.type===r.Fragment)return void a.push.apply(a,I(e.props.children,l));e.type!==L&&(0,o.Oi)(!1),e.props.index&&e.props.children&&(0,o.Oi)(!1);let s={id:e.props.id||l.join("-"),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,loader:e.props.loader,action:e.props.action,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:null!=e.props.ErrorBoundary||null!=e.props.errorElement,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(s.children=I(e.props.children,l)),a.push(s)})),a}},44775:e=>{var t={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","Ấ":"A","Ắ":"A","Ẳ":"A","Ẵ":"A","Ặ":"A","Æ":"AE","Ầ":"A","Ằ":"A","Ȃ":"A","Ả":"A","Ạ":"A","Ẩ":"A","Ẫ":"A","Ậ":"A","Ç":"C","Ḉ":"C","È":"E","É":"E","Ê":"E","Ë":"E","Ế":"E","Ḗ":"E","Ề":"E","Ḕ":"E","Ḝ":"E","Ȇ":"E","Ẻ":"E","Ẽ":"E","Ẹ":"E","Ể":"E","Ễ":"E","Ệ":"E","Ì":"I","Í":"I","Î":"I","Ï":"I","Ḯ":"I","Ȋ":"I","Ỉ":"I","Ị":"I","Ð":"D","Ñ":"N","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","Ố":"O","Ṍ":"O","Ṓ":"O","Ȏ":"O","Ỏ":"O","Ọ":"O","Ổ":"O","Ỗ":"O","Ộ":"O","Ờ":"O","Ở":"O","Ỡ":"O","Ớ":"O","Ợ":"O","Ù":"U","Ú":"U","Û":"U","Ü":"U","Ủ":"U","Ụ":"U","Ử":"U","Ữ":"U","Ự":"U","Ý":"Y","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","ấ":"a","ắ":"a","ẳ":"a","ẵ":"a","ặ":"a","æ":"ae","ầ":"a","ằ":"a","ȃ":"a","ả":"a","ạ":"a","ẩ":"a","ẫ":"a","ậ":"a","ç":"c","ḉ":"c","è":"e","é":"e","ê":"e","ë":"e","ế":"e","ḗ":"e","ề":"e","ḕ":"e","ḝ":"e","ȇ":"e","ẻ":"e","ẽ":"e","ẹ":"e","ể":"e","ễ":"e","ệ":"e","ì":"i","í":"i","î":"i","ï":"i","ḯ":"i","ȋ":"i","ỉ":"i","ị":"i","ð":"d","ñ":"n","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","ố":"o","ṍ":"o","ṓ":"o","ȏ":"o","ỏ":"o","ọ":"o","ổ":"o","ỗ":"o","ộ":"o","ờ":"o","ở":"o","ỡ":"o","ớ":"o","ợ":"o","ù":"u","ú":"u","û":"u","ü":"u","ủ":"u","ụ":"u","ử":"u","ữ":"u","ự":"u","ý":"y","ÿ":"y","Ā":"A","ā":"a","Ă":"A","ă":"a","Ą":"A","ą":"a","Ć":"C","ć":"c","Ĉ":"C","ĉ":"c","Ċ":"C","ċ":"c","Č":"C","č":"c","C̆":"C","c̆":"c","Ď":"D","ď":"d","Đ":"D","đ":"d","Ē":"E","ē":"e","Ĕ":"E","ĕ":"e","Ė":"E","ė":"e","Ę":"E","ę":"e","Ě":"E","ě":"e","Ĝ":"G","Ǵ":"G","ĝ":"g","ǵ":"g","Ğ":"G","ğ":"g","Ġ":"G","ġ":"g","Ģ":"G","ģ":"g","Ĥ":"H","ĥ":"h","Ħ":"H","ħ":"h","Ḫ":"H","ḫ":"h","Ĩ":"I","ĩ":"i","Ī":"I","ī":"i","Ĭ":"I","ĭ":"i","Į":"I","į":"i","İ":"I","ı":"i","IJ":"IJ","ij":"ij","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","Ḱ":"K","ḱ":"k","K̆":"K","k̆":"k","Ĺ":"L","ĺ":"l","Ļ":"L","ļ":"l","Ľ":"L","ľ":"l","Ŀ":"L","ŀ":"l","Ł":"l","ł":"l","Ḿ":"M","ḿ":"m","M̆":"M","m̆":"m","Ń":"N","ń":"n","Ņ":"N","ņ":"n","Ň":"N","ň":"n","ʼn":"n","N̆":"N","n̆":"n","Ō":"O","ō":"o","Ŏ":"O","ŏ":"o","Ő":"O","ő":"o","Œ":"OE","œ":"oe","P̆":"P","p̆":"p","Ŕ":"R","ŕ":"r","Ŗ":"R","ŗ":"r","Ř":"R","ř":"r","R̆":"R","r̆":"r","Ȓ":"R","ȓ":"r","Ś":"S","ś":"s","Ŝ":"S","ŝ":"s","Ş":"S","Ș":"S","ș":"s","ş":"s","Š":"S","š":"s","Ţ":"T","ţ":"t","ț":"t","Ț":"T","Ť":"T","ť":"t","Ŧ":"T","ŧ":"t","T̆":"T","t̆":"t","Ũ":"U","ũ":"u","Ū":"U","ū":"u","Ŭ":"U","ŭ":"u","Ů":"U","ů":"u","Ű":"U","ű":"u","Ų":"U","ų":"u","Ȗ":"U","ȗ":"u","V̆":"V","v̆":"v","Ŵ":"W","ŵ":"w","Ẃ":"W","ẃ":"w","X̆":"X","x̆":"x","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Y̆":"Y","y̆":"y","Ź":"Z","ź":"z","Ż":"Z","ż":"z","Ž":"Z","ž":"z","ſ":"s","ƒ":"f","Ơ":"O","ơ":"o","Ư":"U","ư":"u","Ǎ":"A","ǎ":"a","Ǐ":"I","ǐ":"i","Ǒ":"O","ǒ":"o","Ǔ":"U","ǔ":"u","Ǖ":"U","ǖ":"u","Ǘ":"U","ǘ":"u","Ǚ":"U","ǚ":"u","Ǜ":"U","ǜ":"u","Ứ":"U","ứ":"u","Ṹ":"U","ṹ":"u","Ǻ":"A","ǻ":"a","Ǽ":"AE","ǽ":"ae","Ǿ":"O","ǿ":"o","Þ":"TH","þ":"th","Ṕ":"P","ṕ":"p","Ṥ":"S","ṥ":"s","X́":"X","x́":"x","Ѓ":"Г","ѓ":"г","Ќ":"К","ќ":"к","A̋":"A","a̋":"a","E̋":"E","e̋":"e","I̋":"I","i̋":"i","Ǹ":"N","ǹ":"n","Ồ":"O","ồ":"o","Ṑ":"O","ṑ":"o","Ừ":"U","ừ":"u","Ẁ":"W","ẁ":"w","Ỳ":"Y","ỳ":"y","Ȁ":"A","ȁ":"a","Ȅ":"E","ȅ":"e","Ȉ":"I","ȉ":"i","Ȍ":"O","ȍ":"o","Ȑ":"R","ȑ":"r","Ȕ":"U","ȕ":"u","B̌":"B","b̌":"b","Č̣":"C","č̣":"c","Ê̌":"E","ê̌":"e","F̌":"F","f̌":"f","Ǧ":"G","ǧ":"g","Ȟ":"H","ȟ":"h","J̌":"J","ǰ":"j","Ǩ":"K","ǩ":"k","M̌":"M","m̌":"m","P̌":"P","p̌":"p","Q̌":"Q","q̌":"q","Ř̩":"R","ř̩":"r","Ṧ":"S","ṧ":"s","V̌":"V","v̌":"v","W̌":"W","w̌":"w","X̌":"X","x̌":"x","Y̌":"Y","y̌":"y","A̧":"A","a̧":"a","B̧":"B","b̧":"b","Ḑ":"D","ḑ":"d","Ȩ":"E","ȩ":"e","Ɛ̧":"E","ɛ̧":"e","Ḩ":"H","ḩ":"h","I̧":"I","i̧":"i","Ɨ̧":"I","ɨ̧":"i","M̧":"M","m̧":"m","O̧":"O","o̧":"o","Q̧":"Q","q̧":"q","U̧":"U","u̧":"u","X̧":"X","x̧":"x","Z̧":"Z","z̧":"z","й":"и","Й":"И","ё":"е","Ё":"Е"},a=Object.keys(t).join("|"),r=new RegExp(a,"g"),o=new RegExp(a,"");function n(e){return t[e]}var l=function(e){return e.replace(r,n)};e.exports=l,e.exports.has=function(e){return!!e.match(o)},e.exports.remove=l},90372:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(46941);const o=a.n(r)()("dops:analytics");let n,l;window._tkq=window._tkq||[],window.ga=window.ga||function(){(window.ga.q=window.ga.q||[]).push(arguments)},window.ga.l=+new Date;const s={initialize:function(e,t,a){s.setUser(e,t),s.setSuperProps(a),s.identifyUser()},setGoogleAnalyticsEnabled:function(e,t=null){this.googleAnalyticsEnabled=e,this.googleAnalyticsKey=t},setMcAnalyticsEnabled:function(e){this.mcAnalyticsEnabled=e},setUser:function(e,t){l={ID:e,username:t}},setSuperProps:function(e){n=e},assignSuperProps:function(e){n=Object.assign(n||{},e)},mc:{bumpStat:function(e,t){const a=function(e,t){let a="";if("object"==typeof e){for(const t in e)a+="&x_"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);o("Bumping stats %o",e)}else a="&x_"+encodeURIComponent(e)+"="+encodeURIComponent(t),o('Bumping stat "%s" in group "%s"',t,e);return a}(e,t);s.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom-no-pv"+a+"&t="+Math.random())},bumpStatWithPageView:function(e,t){const a=function(e,t){let a="";if("object"==typeof e){for(const t in e)a+="&"+encodeURIComponent(t)+"="+encodeURIComponent(e[t]);o("Built stats %o",e)}else a="&"+encodeURIComponent(e)+"="+encodeURIComponent(t),o('Built stat "%s" in group "%s"',t,e);return a}(e,t);s.mcAnalyticsEnabled&&((new Image).src=document.location.protocol+"//pixel.wp.com/g.gif?v=wpcom"+a+"&t="+Math.random())}},pageView:{record:function(e,t){s.tracks.recordPageView(e),s.ga.recordPageView(e,t)}},purchase:{record:function(e,t,a,r,o,n,l){s.ga.recordPurchase(e,t,a,r,o,n,l)}},tracks:{recordEvent:function(e,t){t=t||{},0===e.indexOf("akismet_")||0===e.indexOf("jetpack_")?(n&&(o("- Super Props: %o",n),t=Object.assign(t,n)),o('Record event "%s" called with props %s',e,JSON.stringify(t)),window._tkq.push(["recordEvent",e,t])):o('- Event name must be prefixed by "akismet_" or "jetpack_"')},recordJetpackClick:function(e){const t="object"==typeof e?e:{target:e};s.tracks.recordEvent("jetpack_wpa_click",t)},recordPageView:function(e){s.tracks.recordEvent("akismet_page_view",{path:e})},setOptOut:function(e){o("Pushing setOptOut: %o",e),window._tkq.push(["setOptOut",e])}},ga:{initialized:!1,initialize:function(){let e={};s.ga.initialized||(l&&(e={userId:"u-"+l.ID}),window.ga("create",this.googleAnalyticsKey,"auto",e),s.ga.initialized=!0)},recordPageView:function(e,t){s.ga.initialize(),o("Recording Page View ~ [URL: "+e+"] [Title: "+t+"]"),this.googleAnalyticsEnabled&&(window.ga("set","page",e),window.ga("send",{hitType:"pageview",page:e,title:t}))},recordEvent:function(e,t,a,r){s.ga.initialize();let n="Recording Event ~ [Category: "+e+"] [Action: "+t+"]";void 0!==a&&(n+=" [Option Label: "+a+"]"),void 0!==r&&(n+=" [Option Value: "+r+"]"),o(n),this.googleAnalyticsEnabled&&window.ga("send","event",e,t,a,r)},recordPurchase:function(e,t,a,r,o,n,l){window.ga("require","ecommerce"),window.ga("ecommerce:addTransaction",{id:e,revenue:r,currency:l}),window.ga("ecommerce:addItem",{id:e,name:t,sku:a,price:o,quantity:n}),window.ga("ecommerce:send")}},identifyUser:function(){l&&window._tkq.push(["identifyUser",l.ID,l.username])},setProperties:function(e){window._tkq.push(["setProperties",e])},clearedIdentity:function(){window._tkq.push(["clearIdentity"])}},i=s},5932:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>d});var r=a(56439),o=a(93832);function n(e){class t extends Error{constructor(...t){super(...t),this.name=e}}return t}const l=n("JsonParseError"),s=n("JsonParseAfterRedirectError"),i=n("Api404Error"),c=n("Api404AfterRedirectError"),u=n("FetchNetworkError");const d=new function(e,t){let a=e,n=e,l={"X-WP-Nonce":t},s={credentials:"same-origin",headers:l},i={method:"post",credentials:"same-origin",headers:Object.assign({},l,{"Content-type":"application/json"})},c=function(e){const t=e.split("?"),a=t.length>1?t[1]:"",r=a.length?a.split("&"):[];return r.push("_cacheBuster="+(new Date).getTime()),t[0]+"?"+r.join("&")};const u={setApiRoot(e){a=e},setWpcomOriginApiUrl(e){n=e},setApiNonce(e){l={"X-WP-Nonce":e},s={credentials:"same-origin",headers:l},i={method:"post",credentials:"same-origin",headers:Object.assign({},l,{"Content-type":"application/json"})}},setCacheBusterCallback:e=>{c=e},registerSite:(e,t,o)=>{const n={};return(0,r.jetpackConfigHas)("consumer_slug")&&(n.plugin_slug=(0,r.jetpackConfigGet)("consumer_slug")),null!==t&&(n.redirect_uri=t),o&&(n.from=o),m(`${a}jetpack/v4/connection/register`,i,{body:JSON.stringify(n)}).then(v).then(p)},fetchAuthorizationUrl:e=>d((0,o.addQueryArgs)(`${a}jetpack/v4/connection/authorize_url`,{no_iframe:"1",redirect_uri:e}),s).then(v).then(p),fetchSiteConnectionData:()=>d(`${a}jetpack/v4/connection/data`,s).then(p),fetchSiteConnectionStatus:()=>d(`${a}jetpack/v4/connection`,s).then(p),fetchSiteConnectionTest:()=>d(`${a}jetpack/v4/connection/test`,s).then(v).then(p),fetchUserConnectionData:()=>d(`${a}jetpack/v4/connection/data`,s).then(p),fetchUserTrackingSettings:()=>d(`${a}jetpack/v4/tracking/settings`,s).then(v).then(p),updateUserTrackingSettings:e=>m(`${a}jetpack/v4/tracking/settings`,i,{body:JSON.stringify(e)}).then(v).then(p),disconnectSite:()=>m(`${a}jetpack/v4/connection`,i,{body:JSON.stringify({isActive:!1})}).then(v).then(p),fetchConnectUrl:()=>d(`${a}jetpack/v4/connection/url`,s).then(v).then(p),unlinkUser:(e=!1,t={})=>{const r={linked:!1,force:!!e};return t.disconnectAllUsers&&(r["disconnect-all-users"]=!0),m(`${a}jetpack/v4/connection/user`,i,{body:JSON.stringify(r)}).then(v).then(p)},reconnect:()=>m(`${a}jetpack/v4/connection/reconnect`,i).then(v).then(p),fetchConnectedPlugins:()=>d(`${a}jetpack/v4/connection/plugins`,s).then(v).then(p),setHasSeenWCConnectionModal:()=>m(`${a}jetpack/v4/seen-wc-connection-modal`,i).then(v).then(p),fetchModules:()=>d(`${a}jetpack/v4/module/all`,s).then(v).then(p),fetchModule:e=>d(`${a}jetpack/v4/module/${e}`,s).then(v).then(p),activateModule:e=>m(`${a}jetpack/v4/module/${e}/active`,i,{body:JSON.stringify({active:!0})}).then(v).then(p),deactivateModule:e=>m(`${a}jetpack/v4/module/${e}/active`,i,{body:JSON.stringify({active:!1})}),updateModuleOptions:(e,t)=>m(`${a}jetpack/v4/module/${e}`,i,{body:JSON.stringify(t)}).then(v).then(p),updateSettings:e=>m(`${a}jetpack/v4/settings`,i,{body:JSON.stringify(e)}).then(v).then(p),getProtectCount:()=>d(`${a}jetpack/v4/module/protect/data`,s).then(v).then(p),resetOptions:e=>m(`${a}jetpack/v4/options/${e}`,i,{body:JSON.stringify({reset:!0})}).then(v).then(p),activateVaultPress:()=>m(`${a}jetpack/v4/plugins`,i,{body:JSON.stringify({slug:"vaultpress",status:"active"})}).then(v).then(p),getVaultPressData:()=>d(`${a}jetpack/v4/module/vaultpress/data`,s).then(v).then(p),installPlugin:(e,t)=>{const r={slug:e,status:"active"};return t&&(r.source=t),m(`${a}jetpack/v4/plugins`,i,{body:JSON.stringify(r)}).then(v).then(p)},activateAkismet:()=>m(`${a}jetpack/v4/plugins`,i,{body:JSON.stringify({slug:"akismet",status:"active"})}).then(v).then(p),getAkismetData:()=>d(`${a}jetpack/v4/module/akismet/data`,s).then(v).then(p),checkAkismetKey:()=>d(`${a}jetpack/v4/module/akismet/key/check`,s).then(v).then(p),checkAkismetKeyTyped:e=>m(`${a}jetpack/v4/module/akismet/key/check`,i,{body:JSON.stringify({api_key:e})}).then(v).then(p),getFeatureTypeStatus:e=>d(`${a}jetpack/v4/feature/${e}`,s).then(v).then(p),fetchStatsData:e=>d(function(e){let t=`${a}jetpack/v4/module/stats/data`;-1!==t.indexOf("?")?t+=`&range=${encodeURIComponent(e)}`:t+=`?range=${encodeURIComponent(e)}`;return t}(e),s).then(v).then(p).then(f),getPluginUpdates:()=>d(`${a}jetpack/v4/updates/plugins`,s).then(v).then(p),getPlans:()=>d(`${a}jetpack/v4/plans`,s).then(v).then(p),fetchSettings:()=>d(`${a}jetpack/v4/settings`,s).then(v).then(p),updateSetting:e=>m(`${a}jetpack/v4/settings`,i,{body:JSON.stringify(e)}).then(v).then(p),fetchSiteData:()=>d(`${a}jetpack/v4/site`,s).then(v).then(p).then((e=>JSON.parse(e.data))),fetchSiteFeatures:()=>d(`${a}jetpack/v4/site/features`,s).then(v).then(p).then((e=>JSON.parse(e.data))),fetchSiteProducts:()=>d(`${a}jetpack/v4/site/products`,s).then(v).then(p),fetchSitePurchases:()=>d(`${a}jetpack/v4/site/purchases`,s).then(v).then(p).then((e=>JSON.parse(e.data))),fetchSiteBenefits:()=>d(`${a}jetpack/v4/site/benefits`,s).then(v).then(p).then((e=>JSON.parse(e.data))),fetchSiteDiscount:()=>d(`${a}jetpack/v4/site/discount`,s).then(v).then(p).then((e=>e.data)),fetchSetupQuestionnaire:()=>d(`${a}jetpack/v4/setup/questionnaire`,s).then(v).then(p),fetchRecommendationsData:()=>d(`${a}jetpack/v4/recommendations/data`,s).then(v).then(p),fetchRecommendationsProductSuggestions:()=>d(`${a}jetpack/v4/recommendations/product-suggestions`,s).then(v).then(p),fetchRecommendationsUpsell:()=>d(`${a}jetpack/v4/recommendations/upsell`,s).then(v).then(p),fetchRecommendationsConditional:()=>d(`${a}jetpack/v4/recommendations/conditional`,s).then(v).then(p),saveRecommendationsData:e=>m(`${a}jetpack/v4/recommendations/data`,i,{body:JSON.stringify({data:e})}).then(v),fetchProducts:()=>d(`${a}jetpack/v4/products`,s).then(v).then(p),fetchRewindStatus:()=>d(`${a}jetpack/v4/rewind`,s).then(v).then(p).then((e=>JSON.parse(e.data))),fetchScanStatus:()=>d(`${a}jetpack/v4/scan`,s).then(v).then(p).then((e=>JSON.parse(e.data))),dismissJetpackNotice:e=>m(`${a}jetpack/v4/notice/${e}`,i,{body:JSON.stringify({dismissed:!0})}).then(v).then(p),fetchPluginsData:()=>d(`${a}jetpack/v4/plugins`,s).then(v).then(p),fetchIntroOffers:()=>d(`${a}jetpack/v4/intro-offers`,s).then(v).then(p),fetchVerifySiteGoogleStatus:e=>d(null!==e?`${a}jetpack/v4/verify-site/google/${e}`:`${a}jetpack/v4/verify-site/google`,s).then(v).then(p),verifySiteGoogle:e=>m(`${a}jetpack/v4/verify-site/google`,i,{body:JSON.stringify({keyring_id:e})}).then(v).then(p),submitSurvey:e=>m(`${a}jetpack/v4/marketing/survey`,i,{body:JSON.stringify(e)}).then(v).then(p),saveSetupQuestionnaire:e=>m(`${a}jetpack/v4/setup/questionnaire`,i,{body:JSON.stringify(e)}).then(v).then(p),updateLicensingError:e=>m(`${a}jetpack/v4/licensing/error`,i,{body:JSON.stringify(e)}).then(v).then(p),updateLicenseKey:e=>m(`${a}jetpack/v4/licensing/set-license`,i,{body:JSON.stringify({license:e})}).then(v).then(p),getUserLicensesCounts:()=>d(`${a}jetpack/v4/licensing/user/counts`,s).then(v).then(p),getUserLicenses:()=>d(`${a}jetpack/v4/licensing/user/licenses`,s).then(v).then(p),updateLicensingActivationNoticeDismiss:e=>m(`${a}jetpack/v4/licensing/user/activation-notice-dismiss`,i,{body:JSON.stringify({last_detached_count:e})}).then(v).then(p),updateRecommendationsStep:e=>m(`${a}jetpack/v4/recommendations/step`,i,{body:JSON.stringify({step:e})}).then(v),confirmIDCSafeMode:()=>m(`${a}jetpack/v4/identity-crisis/confirm-safe-mode`,i).then(v),startIDCFresh:e=>m(`${a}jetpack/v4/identity-crisis/start-fresh`,i,{body:JSON.stringify({redirect_uri:e})}).then(v).then(p),migrateIDC:()=>m(`${a}jetpack/v4/identity-crisis/migrate`,i).then(v),attachLicenses:e=>m(`${a}jetpack/v4/licensing/attach-licenses`,i,{body:JSON.stringify({licenses:e})}).then(v).then(p),fetchSearchPlanInfo:()=>d(`${n}jetpack/v4/search/plan`,s).then(v).then(p),fetchSearchSettings:()=>d(`${n}jetpack/v4/search/settings`,s).then(v).then(p),updateSearchSettings:e=>m(`${n}jetpack/v4/search/settings`,i,{body:JSON.stringify(e)}).then(v).then(p),fetchSearchStats:()=>d(`${n}jetpack/v4/search/stats`,s).then(v).then(p),fetchWafSettings:()=>d(`${a}jetpack/v4/waf`,s).then(v).then(p),updateWafSettings:e=>m(`${a}jetpack/v4/waf`,i,{body:JSON.stringify(e)}).then(v).then(p),fetchWordAdsSettings:()=>d(`${a}jetpack/v4/wordads/settings`,s).then(v).then(p),updateWordAdsSettings:e=>m(`${a}jetpack/v4/wordads/settings`,i,{body:JSON.stringify(e)}),fetchSearchPricing:()=>d(`${n}jetpack/v4/search/pricing`,s).then(v).then(p),fetchMigrationStatus:()=>d(`${a}jetpack/v4/migration/status`,s).then(v).then(p),fetchBackupUndoEvent:()=>d(`${a}jetpack/v4/site/backup/undo-event`,s).then(v).then(p),fetchBackupPreflightStatus:()=>d(`${a}jetpack/v4/site/backup/preflight`,s).then(v).then(p)};function d(e,t){return fetch(c(e),t)}function m(e,t,a){return fetch(e,Object.assign({},t,a)).catch(h)}function f(e){return e.general&&void 0===e.general.response||e.week&&void 0===e.week.response||e.month&&void 0===e.month.response?e:{}}Object.assign(this,u)};function v(e){return e.status>=200&&e.status<300?e:404===e.status?new Promise((()=>{throw e.redirected?new c(e.redirected):new i})):e.json().catch((e=>m(e))).then((t=>{const a=new Error(`${t.message} (Status ${e.status})`);throw a.response=t,a.name="ApiError",a}))}function p(e){return e.json().catch((t=>m(t,e.redirected,e.url)))}function m(e,t,a){throw t?new s(a):new l}function h(){throw new u}},21197:(e,t,a)=>{"use strict";a.d(t,{h:()=>l});var r=a(27723),o=a(75289),n=a(34144);const __=r.__;class l extends Error{constructor(e,t,a){super(),this.httpCode=e,this.body=t,this.parseError=a}get message(){switch(this.httpCode){case 403:return this.getRestApiErrorMessage();case 200:if(this.parseError)return(0,r.sprintf)(/* Translators: %s refers to a browser-supplied error message (hopefully already in the right language) */ -__("Received invalid response while communicating with your WordPress site: %s","jetpack-my-jetpack"),this.parseError.message)}return(0,r.sprintf)(/* Translators: %d refers to numeric HTTP error code */ -__("HTTP %d error received while communicating with the server.","jetpack-my-jetpack"),this.httpCode)}getDisplayBody(){return(0,n.O)(this.body)?JSON.stringify(this.body,null," "):(0,o.w)(this.body,"").substring(0,1e3)}getRestApiErrorMessage(){return __("Your site's REST API does not seem to be accessible. Jetpack Boost requires access to your REST API in order to receive site performance scores. Please make sure that your site's REST API is active and accessible, and try again.","jetpack-my-jetpack")}}},15098:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(27723),o=a(21197),n=a(18882);const __=r.__;async function l(e,t,a,o=null,l){const s={method:e,mode:"cors",headers:{"X-WP-Nonce":l}};"post"!==e&&"delete"!==e||!o||(s.body=JSON.stringify(o),s.headers["Content-Type"]="application/json");const i=function(e,t){return t+n.K+n.L+e}(a,t);let c;try{c=await fetch(i,s)}catch(e){const t=s;delete t.body,delete t.headers["X-WP-Nonce"];const a={requestInitiator:window.location.href,requestUrl:i,requestArgs:t,originalErrorMessage:e.toString()};throw new Error((0,r.sprintf)(/* Translators: %s refers to a string representation of an error object containing useful debug information */ -__("An error occurred while trying to communicate with the site REST API. Extra debug info: %s","jetpack-my-jetpack"),JSON.stringify(a)))}return c}async function s(e,t,a,r=null,n){const s=await l(e,t,a,r,n);let i,c;try{i=await s.text()}catch(e){throw new o.h(s.status,null,e)}try{c=JSON.parse(i)}catch(e){throw new o.h(s.status,i,e)}if(!s.ok)throw new o.h(s.status,c,null);return c}const i={get:function(e,t,a){return s("get",e,t,null,a)},post:function(e,t,a=null,r){return s("post",e,t,a,r)}}},18882:(e,t,a)=>{"use strict";a.d(t,{K:()=>r,L:()=>o});const r="jetpack-boost/v1",o=""},58454:(e,t,a)=>{"use strict";a.d(t,{T:()=>m,US:()=>h,sE:()=>v});var r=a(27723),o=a(15098),n=a(4753),l=a(75289),s=a(34144),i=a(28991),c=a(93470);const __=r.__,u=12e4,d=5e3;async function v(e=!1,t,a,r){const n=p(await o.A.post(t,e?"/speed-scores/refresh":"/speed-scores",{url:a},r));return n.scores?n.scores:await async function(e,t,a){return(0,i.A)({timeout:u,interval:d,timeoutError:__("Timed out while waiting for speed-score.","jetpack-my-jetpack"),callback:async r=>{const n=p(await o.A.post(e,"/speed-scores",{url:t},a));n.scores&&r(n.scores)}})}(t,a,r)}function p(e){if(e.error){const t=__("An unknown error occurred while requesting metrics","jetpack-my-jetpack");throw(0,c.g)(e.error,t)}if((0,s.O)(e.scores))return{status:"success",scores:{current:(0,s.O)(e.scores.current)?{mobile:(0,n.G)(e.scores.current.mobile,0),desktop:(0,n.G)(e.scores.current.desktop,0)}:{mobile:0,desktop:0},noBoost:(0,s.O)(e.scores.noBoost)?{mobile:(0,n.G)(e.scores.noBoost.mobile,0),desktop:(0,n.G)(e.scores.noBoost.desktop,0)}:null,isStale:!!e.scores.isStale}};const t=(0,l.w)(e.status);if(!t)throw new Error(__("Invalid response while requesting metrics","jetpack-my-jetpack"));return{status:t}}function m(e,t){const a=(e+t)/2;return a>90?"A":a>75?"B":a>50?"C":a>35?"D":a>25?"E":"F"}function h(e){const t=new Date(e),a=(new Date).valueOf()-t.valueOf();return Math.floor(a/864e5)}},4753:(e,t,a)=>{"use strict";function r(e,t=void 0){if("number"==typeof e)return e;if("string"==typeof e){const t=parseFloat(e);if(!isNaN(t))return t}return t}a.d(t,{G:()=>r})},75289:(e,t,a)=>{"use strict";function r(e,t=void 0){return"string"==typeof e?e:e&&e.toString instanceof Function?e.toString():t}a.d(t,{w:()=>r})},34144:(e,t,a)=>{"use strict";function r(e){return!!e&&e instanceof Object&&!(e instanceof Array)}a.d(t,{O:()=>r})},28991:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(27723);const __=r.__;async function o({interval:e,callback:t,timeout:a,timeoutError:r}){let o,n;return new Promise(((l,s)=>{o=setTimeout((()=>{s(new Error(r||__("Timed out","jetpack-my-jetpack")))}),a||12e4),n=setInterval((async()=>{try{await Promise.resolve(t(l))}catch(e){s(e)}}),e)})).finally((()=>{clearTimeout(o),clearInterval(n)}))}},93470:(e,t,a)=>{"use strict";function r(e,t){return e instanceof Error?e:"string"==typeof e||e instanceof String?new Error(e.toString()):e.message?new Error(e.message):t?new Error(t):new Error(JSON.stringify(e))}a.d(t,{g:()=>r})},18089:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var r=a(56427),o=a(27723),n=a(13022),l=a(28120),s=a.n(l),i=a(51609),c=a.n(i),u=a(51112),d=a(29548);const __=o.__,v=e=>{const{label:t,onClick:a,isLoading:o=!1,loadingText:l,isDisabled:s,displayError:i=!1,errorMessage:v=__("An error occurred. Please try again.","jetpack-my-jetpack"),variant:p="primary",isExternalLink:m=!1,customClass:h}=e,f=l||c().createElement(r.Spinner,null);return c().createElement(c().Fragment,null,c().createElement(u.A,{className:(0,n.A)(d.A.button,"jp-action-button--button",h),label:t,onClick:a,variant:m?"link":p,isExternalLink:m,disabled:o||s},o?f:t),i&&c().createElement("p",{className:(0,n.A)(d.A.error,"jp-action-button__error")},v))};v.propTypes={label:s().string.isRequired,onClick:s().func,isLoading:s().bool,isDisabled:s().bool,displayError:s().bool,errorMessage:s().oneOfType([s().string,s().element]),variant:s().arrayOf(s().oneOf(["primary","secondary","link"])),isExternalLink:s().bool};const p=v},42947:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var r=a(5932),o=a(27723),n=a(13022),l=a(51609),s=a(38250),i=a(67142),c=a(28509),u=a(75918),d=a(8902);const __=o.__,v=({children:e,moduleName:t=__("Jetpack","jetpack-my-jetpack"),moduleNameHref:a,showHeader:v=!0,showFooter:p=!0,useInternalLinks:m=!1,showBackground:h=!0,sandboxedDomain:f="",apiRoot:g="",apiNonce:w="",optionalMenuItems:b,header:y})=>{(0,l.useEffect)((()=>{r.Ay.setApiRoot(g),r.Ay.setApiNonce(w)}),[g,w]);const x=(0,n.A)(d.A["admin-page"],{[d.A.background]:h}),_=(0,l.useCallback)((async()=>{try{const e=await r.Ay.fetchSiteConnectionTest();window.alert(e.message)}catch(e){window.alert((0,o.sprintf)(/* translators: placeholder is an error message. */ -__("There was an error testing Jetpack. Error: %s","jetpack-my-jetpack"),e.message))}}),[]);return React.createElement("div",{className:x},v&&React.createElement(u.A,{horizontalSpacing:5},React.createElement(c.A,{className:(0,n.A)(d.A["admin-page-header"],"jp-admin-page-header")},y||React.createElement(i.A,null),f&&React.createElement("code",{className:d.A["sandbox-domain-badge"],onClick:_,onKeyDown:_,role:"button",tabIndex:0,title:`Sandboxing via ${f}. Click to test connection.`},"API Sandboxed"))),React.createElement(u.A,{fluid:!0,horizontalSpacing:0},React.createElement(c.A,null,e)),p&&React.createElement(u.A,{horizontalSpacing:5},React.createElement(c.A,null,React.createElement(s.A,{moduleName:t,moduleNameHref:a,menu:b,useInternalLinks:m}))))}},95640:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(51609),o=a.n(r),n=a(27507);const l=({children:e})=>o().createElement("div",{className:n.A.section},e)},90766:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(51609),o=a.n(r),n=a(48703);const l=({children:e})=>o().createElement("div",{className:n.A["section-hero"]},e)},42266:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var r=a(23751),o=a(19783),n=a(83883),l=a(51113),s=a(13022),i=a(51609),c=a.n(i),u=a(8953);const d=e=>{switch(e){case"error":case"warning":default:return r.A;case"info":return o.A;case"success":return n.A}},v=({level:e="warning",children:t,showIcon:a=!0,className:r})=>{const o=(0,s.A)(u.A.container,u.A[`is-${e}`],r);return c().createElement("div",{className:o},a&&c().createElement("div",{className:u.A["icon-wrapper"]},c().createElement(l.A,{icon:d(e),className:u.A.icon})),c().createElement("div",null,t))}},48907:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(96072),o=a.n(r),n=a(27723),l=a(13022),s=a(51609),i=a.n(s);const __=n.__,c=({title:e=__("An Automattic Airline","jetpack-my-jetpack"),height:t=7,className:a,...r})=>i().createElement("svg",o()({role:"img",x:"0",y:"0",viewBox:"0 0 935 38.2",enableBackground:"new 0 0 935 38.2","aria-labelledby":"jp-automattic-byline-logo-title",height:t,className:(0,l.A)("jp-automattic-byline-logo",a)},r),i().createElement("desc",{id:"jp-automattic-byline-logo-title"},e),i().createElement("path",{d:"M317.1 38.2c-12.6 0-20.7-9.1-20.7-18.5v-1.2c0-9.6 8.2-18.5 20.7-18.5 12.6 0 20.8 8.9 20.8 18.5v1.2C337.9 29.1 329.7 38.2 317.1 38.2zM331.2 18.6c0-6.9-5-13-14.1-13s-14 6.1-14 13v0.9c0 6.9 5 13.1 14 13.1s14.1-6.2 14.1-13.1V18.6zM175 36.8l-4.7-8.8h-20.9l-4.5 8.8h-7L157 1.3h5.5L182 36.8H175zM159.7 8.2L152 23.1h15.7L159.7 8.2zM212.4 38.2c-12.7 0-18.7-6.9-18.7-16.2V1.3h6.6v20.9c0 6.6 4.3 10.5 12.5 10.5 8.4 0 11.9-3.9 11.9-10.5V1.3h6.7V22C231.4 30.8 225.8 38.2 212.4 38.2zM268.6 6.8v30h-6.7v-30h-15.5V1.3h37.7v5.5H268.6zM397.3 36.8V8.7l-1.8 3.1 -14.9 25h-3.3l-14.7-25 -1.8-3.1v28.1h-6.5V1.3h9.2l14 24.4 1.7 3 1.7-3 13.9-24.4h9.1v35.5H397.3zM454.4 36.8l-4.7-8.8h-20.9l-4.5 8.8h-7l19.2-35.5h5.5l19.5 35.5H454.4zM439.1 8.2l-7.7 14.9h15.7L439.1 8.2zM488.4 6.8v30h-6.7v-30h-15.5V1.3h37.7v5.5H488.4zM537.3 6.8v30h-6.7v-30h-15.5V1.3h37.7v5.5H537.3zM569.3 36.8V4.6c2.7 0 3.7-1.4 3.7-3.4h2.8v35.5L569.3 36.8 569.3 36.8zM628 11.3c-3.2-2.9-7.9-5.7-14.2-5.7 -9.5 0-14.8 6.5-14.8 13.3v0.7c0 6.7 5.4 13 15.3 13 5.9 0 10.8-2.8 13.9-5.7l4 4.2c-3.9 3.8-10.5 7.1-18.3 7.1 -13.4 0-21.6-8.7-21.6-18.3v-1.2c0-9.6 8.9-18.7 21.9-18.7 7.5 0 14.3 3.1 18 7.1L628 11.3zM321.5 12.4c1.2 0.8 1.5 2.4 0.8 3.6l-6.1 9.4c-0.8 1.2-2.4 1.6-3.6 0.8l0 0c-1.2-0.8-1.5-2.4-0.8-3.6l6.1-9.4C318.7 11.9 320.3 11.6 321.5 12.4L321.5 12.4z"}),i().createElement("path",{d:"M37.5 36.7l-4.7-8.9H11.7l-4.6 8.9H0L19.4 0.8H25l19.7 35.9H37.5zM22 7.8l-7.8 15.1h15.9L22 7.8zM82.8 36.7l-23.3-24 -2.3-2.5v26.6h-6.7v-36H57l22.6 24 2.3 2.6V0.8h6.7v35.9H82.8z"}),i().createElement("path",{d:"M719.9 37l-4.8-8.9H694l-4.6 8.9h-7.1l19.5-36h5.6l19.8 36H719.9zM704.4 8l-7.8 15.1h15.9L704.4 8zM733 37V1h6.8v36H733zM781 37c-1.8 0-2.6-2.5-2.9-5.8l-0.2-3.7c-0.2-3.6-1.7-5.1-8.4-5.1h-12.8V37H750V1h19.6c10.8 0 15.7 4.3 15.7 9.9 0 3.9-2 7.7-9 9 7 0.5 8.5 3.7 8.6 7.9l0.1 3c0.1 2.5 0.5 4.3 2.2 6.1V37H781zM778.5 11.8c0-2.6-2.1-5.1-7.9-5.1h-13.8v10.8h14.4c5 0 7.3-2.4 7.3-5.2V11.8zM794.8 37V1h6.8v30.4h28.2V37H794.8zM836.7 37V1h6.8v36H836.7zM886.2 37l-23.4-24.1 -2.3-2.5V37h-6.8V1h6.5l22.7 24.1 2.3 2.6V1h6.8v36H886.2zM902.3 37V1H935v5.6h-26v9.2h20v5.5h-20v10.1h26V37H902.3z"}))},10580:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(27723),o=a(13022),n=a(11883);a(50315);const __=r.__,l=({score:e,isLoading:t,showPrevScores:a,active:r,prevScore:l=0,scoreBarType:s,noBoostScoreTooltip:i})=>{if(!r)return null;const c=l/e*100,u=__("Desktop score","jetpack-my-jetpack"),d=__("Mobile score","jetpack-my-jetpack");return React.createElement("div",{className:(0,o.A)("jb-score-bar",`jb-score-bar--${s}`)},React.createElement("div",{className:"jb-score-bar__label"},"desktop"===s?React.createElement(n.A,{icon:"computer",size:24}):React.createElement(n.A,{icon:"phone",size:24}),React.createElement("div",null,"desktop"===s?u:d)),React.createElement("div",{className:"jb-score-bar__bounds"},React.createElement("div",{className:(0,o.A)("jb-score-bar__filler",t&&!e?"fill-loading":e>70?"fill-good":e>50?"fill-mediocre":"fill-bad"),style:{width:`${e}%`}},t?React.createElement("div",{className:"jb-score-bar__loading"},React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 128 128"},React.createElement("g",null,React.createElement("path",{d:"M64 0a7 7 0 11-7 7 7 7 0 017-7zm29.86 12.2a2.8 2.8 0 11-3.83 1.02 2.8 2.8 0 013.83-1.02zm22.16 21.68a3.15 3.15 0 11-4.3-1.15 3.15 3.15 0 014.3 1.15zm.87 60.53a4.2 4.2 0 11-1.57-5.7 4.2 4.2 0 011.54 5.73zm7.8-30.5a3.85 3.85 0 11-3.85-3.85 3.85 3.85 0 013.85 3.84zm-30 53.2a4.55 4.55 0 111.66-6.23 4.55 4.55 0 01-1.67 6.22zM64 125.9a4.9 4.9 0 114.9-4.9 4.9 4.9 0 01-4.9 4.9zm-31.06-8.22a5.25 5.25 0 117.17-1.93 5.25 5.25 0 01-7.14 1.93zM9.9 95.1a5.6 5.6 0 117.65 2.06A5.6 5.6 0 019.9 95.1zM1.18 63.9a5.95 5.95 0 115.95 5.94 5.95 5.95 0 01-5.96-5.94zm8.1-31.6a6.3 6.3 0 112.32 8.6 6.3 6.3 0 01-2.3-8.6zM32.25 8.87a6.65 6.65 0 11-2.44 9.1 6.65 6.65 0 012.46-9.1z"}),React.createElement("animateTransform",{attributeName:"transform",type:"rotate",values:"0 64 64;30 64 64;60 64 64;90 64 64;120 64 64;150 64 64;180 64 64;210 64 64;240 64 64;270 64 64;300 64 64;330 64 64",calcMode:"discrete",dur:"1080ms",repeatCount:"indefinite"})))):React.createElement("div",{className:"jb-score-bar__score"},e),a&&!!l&&l{"use strict";a.d(t,{A:()=>m});var r=a(96072),o=a.n(r),n=a(56427),l=a(27723),s=a(51113),i=a(53512),c=a(13022),u=a(51609),d=a.n(u),v=a(55369);const __=l.__,p=(0,u.forwardRef)(((e,t)=>{const{children:a,variant:r="primary",size:l="normal",weight:u="bold",icon:p,iconSize:m,disabled:h,isDestructive:f,isLoading:g,isExternalLink:w,className:b,text:y,fullWidth:x,..._}=e,k=(0,c.A)(v.A.button,b,{[v.A.normal]:"normal"===l,[v.A.small]:"small"===l,[v.A.icon]:Boolean(p),[v.A.loading]:g,[v.A.regular]:"regular"===u,[v.A["full-width"]]:x,[v.A["is-icon-button"]]:Boolean(p)&&!a});_.ref=t;const E="normal"===l?20:16,C=w&&d().createElement(d().Fragment,null,d().createElement(s.A,{size:E,icon:i.A,className:v.A["external-icon"]}),d().createElement(n.VisuallyHidden,{as:"span"},/* translators: accessibility text */ -__("(opens in a new tab)","jetpack-my-jetpack"))),j=w?"_blank":void 0,A=a?.[0]&&null!==a[0]&&"components-tooltip"!==a?.[0]?.props?.className;return d().createElement(n.Button,o()({target:j,variant:r,className:(0,c.A)(k,{"has-text":!!p&&A}),icon:w?void 0:p,iconSize:m,disabled:h,"aria-disabled":h,isDestructive:f,text:y},_),g&&d().createElement(n.Spinner,null),d().createElement("span",null,a),C)}));p.displayName="Button";const m=p},59244:(e,t,a)=>{"use strict";a.d(t,{D:()=>l});var r=a(56427),o=a(94347),n=a(63406);function l({maxVisibleNotices:e=3}){const{getNotices:t,removeNotice:a}=(0,n.I)(),l=t().filter((({type:e})=>"snackbar"===e)).slice(-e);return React.createElement(r.SnackbarList,{notices:l,className:o.A["global-notices"],onRemove:a})}},63406:(e,t,a)=>{"use strict";a.d(t,{I:()=>n});var r=a(47143),o=a(692);function n(){const e=(0,r.useDispatch)(o.store),t=(0,r.useSelect)((e=>e(o.store).getNotices()),[]);return{...e,createNotice:(t,a,r)=>e.createNotice(t,a,{type:"snackbar",...r}),createErrorNotice:(t,a)=>e.createErrorNotice(t,{type:"snackbar",...a}),createInfoNotice:(t,a)=>e.createInfoNotice(t,{type:"snackbar",...a}),createSuccessNotice:(t,a)=>e.createSuccessNotice(t,{type:"snackbar",...a}),createWarningNotice:(t,a)=>e.createWarningNotice(t,{type:"snackbar",...a}),getNotices:()=>t}}},11883:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(27723),o=a(13022),n=a(51609);a(40500);const __=r.__;class l extends n.Component{static defaultProps={"aria-hidden":"false",focusable:"true"};needsOffset(e,t){return["gridicons-arrow-left","gridicons-arrow-right","gridicons-calendar","gridicons-cart","gridicons-folder","gridicons-help-outline","gridicons-info","gridicons-info-outline","gridicons-posts","gridicons-star-outline","gridicons-star"].indexOf(e)>=0&&t%18==0}getSVGDescription(e){if("description"in this.props)return this.props.description;switch(e){default:return"";case"gridicons-audio":return __("Has audio.","jetpack-my-jetpack");case"gridicons-arrow-left":return __("Arrow left","jetpack-my-jetpack");case"gridicons-arrow-right":return __("Arrow right","jetpack-my-jetpack");case"gridicons-calendar":return __("Is an event.","jetpack-my-jetpack");case"gridicons-cart":return __("Is a product.","jetpack-my-jetpack");case"chevron-down":return __("Show filters","jetpack-my-jetpack");case"gridicons-comment":return __("Matching comment.","jetpack-my-jetpack");case"gridicons-cross":return __("Close.","jetpack-my-jetpack");case"gridicons-filter":return __("Toggle search filters.","jetpack-my-jetpack");case"gridicons-folder":return __("Category","jetpack-my-jetpack");case"gridicons-help-outline":return __("Help","jetpack-my-jetpack");case"gridicons-info":case"gridicons-info-outline":return __("Information.","jetpack-my-jetpack");case"gridicons-image-multiple":return __("Has multiple images.","jetpack-my-jetpack");case"gridicons-image":return __("Has an image.","jetpack-my-jetpack");case"gridicons-page":return __("Page","jetpack-my-jetpack");case"gridicons-post":return __("Post","jetpack-my-jetpack");case"gridicons-jetpack-search":case"gridicons-search":return __("Magnifying Glass","jetpack-my-jetpack");case"gridicons-tag":return __("Tag","jetpack-my-jetpack");case"gridicons-video":return __("Has a video.","jetpack-my-jetpack")}}renderIcon(e){switch(e){default:return null;case"gridicons-audio":return React.createElement("g",null,React.createElement("path",{d:"M8 4v10.184C7.686 14.072 7.353 14 7 14c-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3V7h7v4.184c-.314-.112-.647-.184-1-.184-1.657 0-3 1.343-3 3s1.343 3 3 3 3-1.343 3-3V4H8z"}));case"gridicons-arrow-left":return React.createElement("g",null,React.createElement("path",{d:"M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z"}));case"gridicons-arrow-right":return React.createElement("g",null,React.createElement("path",{d:"M12 4l-1.41 1.41L16.17 11H4v2h12.17l-5.58 5.59L12 20l8-8-8-8z"}));case"gridicons-block":return React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zM4 12c0-4.418 3.582-8 8-8 1.848 0 3.545.633 4.9 1.686L5.686 16.9C4.633 15.545 4 13.848 4 12zm8 8c-1.848 0-3.546-.633-4.9-1.686L18.314 7.1C19.367 8.455 20 10.152 20 12c0 4.418-3.582 8-8 8z"}));case"gridicons-calendar":return React.createElement("g",null,React.createElement("path",{d:"M19 4h-1V2h-2v2H8V2H6v2H5c-1.105 0-2 .896-2 2v13c0 1.104.895 2 2 2h14c1.104 0 2-.896 2-2V6c0-1.104-.896-2-2-2zm0 15H5V8h14v11z"}));case"gridicons-cart":return React.createElement("g",null,React.createElement("path",{d:"M9 20c0 1.1-.9 2-2 2s-1.99-.9-1.99-2S5.9 18 7 18s2 .9 2 2zm8-2c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2zm.396-5c.937 0 1.75-.65 1.952-1.566L21 5H7V4c0-1.105-.895-2-2-2H3v2h2v11c0 1.105.895 2 2 2h12c0-1.105-.895-2-2-2H7v-2h10.396z"}));case"gridicons-checkmark":return React.createElement("g",null,React.createElement("path",{d:"M11 17.768l-4.884-4.884 1.768-1.768L11 14.232l8.658-8.658C17.823 3.39 15.075 2 12 2 6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10c0-1.528-.353-2.97-.966-4.266L11 17.768z"}));case"gridicons-chevron-left":return React.createElement("g",null,React.createElement("path",{d:"M16.443 7.41L15.0399 6L9.06934 12L15.0399 18L16.443 16.59L11.8855 12L16.443 7.41Z"}));case"gridicons-chevron-right":return React.createElement("g",null,React.createElement("path",{d:"M10.2366 6L8.8335 7.41L13.391 12L8.8335 16.59L10.2366 18L16.2072 12L10.2366 6Z"}));case"gridicons-chevron-down":return React.createElement("g",null,React.createElement("path",{d:"M20 9l-8 8-8-8 1.414-1.414L12 14.172l6.586-6.586"}));case"gridicons-comment":return React.createElement("g",null,React.createElement("path",{d:"M3 6v9c0 1.105.895 2 2 2h9v5l5.325-3.804c1.05-.75 1.675-1.963 1.675-3.254V6c0-1.105-.895-2-2-2H5c-1.105 0-2 .895-2 2z"}));case"gridicons-computer":return React.createElement("g",null,React.createElement("path",{d:"M20 2H4c-1.104 0-2 .896-2 2v12c0 1.104.896 2 2 2h6v2H7v2h10v-2h-3v-2h6c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm0 14H4V4h16v12z"}));case"gridicons-cross":return React.createElement("g",null,React.createElement("path",{d:"M18.36 19.78L12 13.41l-6.36 6.37-1.42-1.42L10.59 12 4.22 5.64l1.42-1.42L12 10.59l6.36-6.36 1.41 1.41L13.41 12l6.36 6.36z"}));case"gridicons-filter":return React.createElement("g",null,React.createElement("path",{d:"M10 19h4v-2h-4v2zm-4-6h12v-2H6v2zM3 5v2h18V5H3z"}));case"gridicons-folder":return React.createElement("g",null,React.createElement("path",{d:"M18 19H6c-1.1 0-2-.9-2-2V7c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2h7c1.1 0 2 .9 2 2v8c0 1.1-.9 2-2 2z"}));case"gridicons-help-outline":return React.createElement("g",null,React.createElement("path",{d:"M12 4c4.41 0 8 3.59 8 8s-3.59 8-8 8-8-3.59-8-8 3.59-8 8-8m0-2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 13h-2v2h2v-2zm-1.962-2v-.528c0-.4.082-.74.246-1.017.163-.276.454-.546.87-.808.333-.21.572-.397.717-.565.146-.168.22-.36.22-.577 0-.172-.078-.308-.234-.41-.156-.1-.358-.15-.608-.15-.62 0-1.34.22-2.168.658l-.854-1.67c1.02-.58 2.084-.872 3.194-.872.913 0 1.63.202 2.15.603.52.4.78.948.78 1.64 0 .495-.116.924-.347 1.287-.23.362-.6.705-1.11 1.03-.43.278-.7.48-.807.61-.108.13-.163.282-.163.458V13h-1.885z"}));case"gridicons-image":return React.createElement("g",null,React.createElement("path",{d:"M13 9.5c0-.828.672-1.5 1.5-1.5s1.5.672 1.5 1.5-.672 1.5-1.5 1.5-1.5-.672-1.5-1.5zM22 6v12c0 1.105-.895 2-2 2H4c-1.105 0-2-.895-2-2V6c0-1.105.895-2 2-2h16c1.105 0 2 .895 2 2zm-2 0H4v7.444L8 9l5.895 6.55 1.587-1.85c.798-.932 2.24-.932 3.037 0L20 15.426V6z"}));case"gridicons-image-multiple":return React.createElement("g",null,React.createElement("path",{d:"M15 7.5c0-.828.672-1.5 1.5-1.5s1.5.672 1.5 1.5S17.328 9 16.5 9 15 8.328 15 7.5zM4 20h14c0 1.105-.895 2-2 2H4c-1.1 0-2-.9-2-2V8c0-1.105.895-2 2-2v14zM22 4v12c0 1.105-.895 2-2 2H8c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zM8 4v6.333L11 7l4.855 5.395.656-.73c.796-.886 2.183-.886 2.977 0l.513.57V4H8z"}));case"gridicons-info":return React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"}));case"gridicons-info-outline":return React.createElement("g",null,React.createElement("path",{d:"M13 9h-2V7h2v2zm0 2h-2v6h2v-6zm-1-7c-4.411 0-8 3.589-8 8s3.589 8 8 8 8-3.589 8-8-3.589-8-8-8m0-2c5.523 0 10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2z"}));case"gridicons-jetpack-search":return React.createElement("g",null,React.createElement("path",{d:"M0 9.257C0 4.15 4.151 0 9.257 0c5.105 0 9.256 4.151 9.256 9.257a9.218 9.218 0 01-2.251 6.045l.034.033h1.053L24 22.01l-1.986 1.989-6.664-6.662v-1.055l-.033-.033a9.218 9.218 0 01-6.06 2.264C4.15 18.513 0 14.362 0 9.257zm4.169 1.537h4.61V1.82l-4.61 8.973zm5.547-3.092v8.974l4.61-8.974h-4.61z"}));case"gridicons-phone":return React.createElement("g",null,React.createElement("path",{d:"M16 2H8c-1.104 0-2 .896-2 2v16c0 1.104.896 2 2 2h8c1.104 0 2-.896 2-2V4c0-1.104-.896-2-2-2zm-3 19h-2v-1h2v1zm3-2H8V5h8v14z"}));case"gridicons-pages":return React.createElement("g",null,React.createElement("path",{d:"M16 8H8V6h8v2zm0 2H8v2h8v-2zm4-6v12l-6 6H6c-1.105 0-2-.895-2-2V4c0-1.105.895-2 2-2h12c1.105 0 2 .895 2 2zm-2 10V4H6v16h6v-4c0-1.105.895-2 2-2h4z"}));case"gridicons-posts":return React.createElement("g",null,React.createElement("path",{d:"M16 19H3v-2h13v2zm5-10H3v2h18V9zM3 5v2h11V5H3zm14 0v2h4V5h-4zm-6 8v2h10v-2H11zm-8 0v2h5v-2H3z"}));case"gridicons-search":return React.createElement("g",null,React.createElement("path",{d:"M21 19l-5.154-5.154C16.574 12.742 17 11.42 17 10c0-3.866-3.134-7-7-7s-7 3.134-7 7 3.134 7 7 7c1.42 0 2.742-.426 3.846-1.154L19 21l2-2zM5 10c0-2.757 2.243-5 5-5s5 2.243 5 5-2.243 5-5 5-5-2.243-5-5z"}));case"gridicons-star-outline":return React.createElement("g",null,React.createElement("path",{d:"M12 6.308l1.176 3.167.347.936.997.042 3.374.14-2.647 2.09-.784.62.27.963.91 3.25-2.813-1.872-.83-.553-.83.552-2.814 1.87.91-3.248.27-.962-.783-.62-2.648-2.092 3.374-.14.996-.04.347-.936L12 6.308M12 2L9.418 8.953 2 9.257l5.822 4.602L5.82 21 12 16.89 18.18 21l-2.002-7.14L22 9.256l-7.418-.305L12 2z"}));case"gridicons-star":return React.createElement("g",null,React.createElement("path",{d:"M12 2l2.582 6.953L22 9.257l-5.822 4.602L18.18 21 12 16.89 5.82 21l2.002-7.14L2 9.256l7.418-.304"}));case"gridicons-tag":return React.createElement("g",null,React.createElement("path",{d:"M20 2.007h-7.087c-.53 0-1.04.21-1.414.586L2.592 11.5c-.78.78-.78 2.046 0 2.827l7.086 7.086c.78.78 2.046.78 2.827 0l8.906-8.906c.376-.374.587-.883.587-1.413V4.007c0-1.105-.895-2-2-2zM17.007 9c-1.105 0-2-.895-2-2s.895-2 2-2 2 .895 2 2-.895 2-2 2z"}));case"gridicons-video":return React.createElement("g",null,React.createElement("path",{d:"M20 4v2h-2V4H6v2H4V4c-1.105 0-2 .895-2 2v12c0 1.105.895 2 2 2v-2h2v2h12v-2h2v2c1.105 0 2-.895 2-2V6c0-1.105-.895-2-2-2zM6 16H4v-3h2v3zm0-5H4V8h2v3zm4 4V9l4.5 3-4.5 3zm10 1h-2v-3h2v3zm0-5h-2V8h2v3z"}));case"gridicons-lock":return React.createElement(React.Fragment,null,React.createElement("g",{id:"lock"},React.createElement("path",{d:"M18,8h-1V7c0-2.757-2.243-5-5-5S7,4.243,7,7v1H6c-1.105,0-2,0.895-2,2v10c0,1.105,0.895,2,2,2h12c1.105,0,2-0.895,2-2V10 C20,8.895,19.105,8,18,8z M9,7c0-1.654,1.346-3,3-3s3,1.346,3,3v1H9V7z M13,15.723V18h-2v-2.277c-0.595-0.346-1-0.984-1-1.723 c0-1.105,0.895-2,2-2s2,0.895,2,2C14,14.738,13.595,15.376,13,15.723z"})),React.createElement("g",{id:"Layer_1"}));case"gridicons-external":return React.createElement("g",null,React.createElement("path",{d:"M19 13v6c0 1.105-.895 2-2 2H5c-1.105 0-2-.895-2-2V7c0-1.105.895-2 2-2h6v2H5v12h12v-6h2zM13 3v2h4.586l-7.793 7.793 1.414 1.414L19 6.414V11h2V3h-8z"}))}}render(){const{size:e=24,className:t=""}=this.props,a=this.props.height||e,r=this.props.width||e,n=this.props.style||{height:a,width:r},l="gridicons-"+this.props.icon,s=(0,o.A)("gridicon",l,t,{"needs-offset":this.needsOffset(l,e)}),i=this.getSVGDescription(l);return React.createElement("svg",{className:s,focusable:this.props.focusable,height:a,onClick:this.props.onClick,style:n,viewBox:"0 0 24 24",width:r,xmlns:"http://www.w3.org/2000/svg","aria-hidden":this.props["aria-hidden"]},i?React.createElement("desc",null,i):null,this.renderIcon(l))}}const s=l},40597:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(56427),o=a(13022),n=a(51609),l=a.n(n),s=a(51112),i=a(11883);a(50626);const c=e=>({"top-end":"top left",top:"top center","top-start":"top right","bottom-end":"bottom left",bottom:"bottom center","bottom-start":"bottom right"}[e]),u=({className:e="",iconClassName:t="",placement:a="bottom-end",animate:u=!0,iconCode:d="info-outline",iconSize:v=18,offset:p=10,title:m,children:h,popoverAnchorStyle:f="icon",forceShow:g=!1,hoverShow:w=!1,wide:b=!1,inline:y=!0,shift:x=!1})=>{const[_,k]=(0,n.useState)(!1),[E,C]=(0,n.useState)(null),j=(0,n.useCallback)((()=>k(!1)),[k]),A=(0,n.useCallback)((e=>{e.preventDefault(),k(!_)}),[_,k]),S={position:c(a),placement:a,animate:u,noArrow:!1,resize:!1,flip:!1,offset:p,focusOnMount:"container",onClose:j,className:"icon-tooltip-container",inline:y,shift:x},P="wrapper"===f,R=(0,o.A)("icon-tooltip-wrapper",e),M={left:P?0:-(62-v/2)+"px"},V=P&&g,z=(0,n.useCallback)((()=>{w&&(E&&(clearTimeout(E),C(null)),k(!0))}),[w,E]),H=(0,n.useCallback)((()=>{if(w){const e=setTimeout((()=>{k(!1),C(null)}),100);C(e)}}),[w]);return l().createElement("div",{className:R,"data-testid":"icon-tooltip_wrapper",onMouseEnter:z,onMouseLeave:H},!P&&l().createElement(s.A,{variant:"link",onMouseDown:A},l().createElement(i.A,{className:t,icon:d,size:v})),l().createElement("div",{className:(0,o.A)("icon-tooltip-helper",{"is-wide":b}),style:M},(V||_)&&l().createElement(r.Popover,S,l().createElement("div",null,m&&l().createElement("div",{className:"icon-tooltip-title"},m),l().createElement("div",{className:"icon-tooltip-content"},h)))))}},78478:(e,t,a)=>{"use strict";a.d(t,{Gg:()=>c,KH:()=>v,Nr:()=>u,Wy:()=>m,sT:()=>d});var r=a(96072),o=a.n(r),n=a(56427),l=a(13022),s=(a(84705),a(9969));const i=({className:e,size:t=24,viewBox:a="0 0 24 24",opacity:r=1,color:i="#2C3338",children:c})=>{const u={className:(0,l.A)(s.A.iconWrapper,e),width:t,height:t,viewBox:a,opacity:r,fill:void 0};return i&&(u.fill=i),React.createElement(n.SVG,o()({},u,{fillRule:"evenodd",clipRule:"evenodd",xmlns:"http://www.w3.org/2000/svg"}),React.createElement(n.G,{opacity:r},c))},c=({size:e,className:t=s.A["star-icon"],color:a})=>React.createElement(i,{className:t,size:e,color:a},React.createElement(n.Path,{d:"M12 2l2.582 6.953L22 9.257l-5.822 4.602L18.18 21 12 16.89 5.82 21l2.002-7.14L2 9.256l7.418-.304"})),u=({size:e,className:t=s.A["checkmark-icon"],color:a})=>React.createElement(i,{className:t,size:e,color:a},React.createElement(n.Path,{d:"M11 17.768l-4.884-4.884 1.768-1.768L11 14.232l8.658-8.658C17.823 3.39 15.075 2 12 2 6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10c0-1.528-.353-2.97-.966-4.266L11 17.768z"})),d=({size:e,className:t=s.A.jetpack,color:a})=>React.createElement(i,{className:t,size:e,color:a,viewBox:"0 0 32 32"},React.createElement(n.Path,{className:"jetpack-logo__icon-circle",d:"M16,0C7.2,0,0,7.2,0,16s7.2,16,16,16s16-7.2,16-16S24.8,0,16,0z"}),React.createElement(n.Polygon,{fill:"#fff",points:"15,19 7,19 15,3"}),React.createElement(n.Polygon,{fill:"#fff",points:"17,29 17,13 25,13"})),v=({size:e=24,color:t="#069e08"})=>React.createElement(i,{color:t,size:e,viewBox:"0 0 32 32"},React.createElement(n.Path,{className:"spark-first",d:"M9.33301 5.33325L10.4644 8.20188L13.333 9.33325L10.4644 10.4646L9.33301 13.3333L8.20164 10.4646L5.33301 9.33325L8.20164 8.20188L9.33301 5.33325Z"}),React.createElement(n.Path,{className:"spark-second",d:"M21.3333 5.33333L22.8418 9.15817L26.6667 10.6667L22.8418 12.1752L21.3333 16L19.8248 12.1752L16 10.6667L19.8248 9.15817L21.3333 5.33333Z"}),React.createElement(n.Path,{className:"spark-third",d:"M14.6667 13.3333L16.5523 18.1144L21.3333 20L16.5523 21.8856L14.6667 26.6667L12.781 21.8856L8 20L12.781 18.1144L14.6667 13.3333Z"})),p={...{"anti-spam":({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"M13.2,4.7l4.7,12.8c0.4,1.1,1,1.5,2.1,1.6c0.1,0,0.1,0,0.1,0l0.1,0.1l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1 s0,0.1-0.1,0.1c-0.1,0-0.1,0.1-0.1,0.1s-0.1,0-0.2,0h-5.1c-0.1,0-0.1,0-0.2,0c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1 c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1l0.1-0.1c0,0,0.1,0,0.2,0c0.5,0,1.1-0.2,1.1-0.8c0-0.3-0.1-0.5-0.2-0.8l-1.1-3.1 c-0.1-0.2-0.1-0.2-0.2-0.2h-4.3c-0.7,0-1.5,0-1.9,0.9l-1.1,2.4C7.1,17.6,7,17.8,7,18.1c0,0.8,1,0.9,1.6,0.9c0.1,0,0.1,0,0.2,0 L8.8,19l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1s-0.1,0.1-0.1,0.1l-0.1,0.1c-0.1,0-0.1,0-0.2,0H4.1c-0.1,0-0.1,0-0.1,0 c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1L4,19c0,0,0.1,0,0.1,0C5.2,19,5.5,18.5,6,17.5 l5.4-12.4c0.2-0.5,0.8-1,1.3-1C13,4.2,13.1,4.4,13.2,4.7z M9.1,13.1c0,0.1-0.1,0.1-0.1,0.2c0,0.1,0.1,0.1,0.1,0.1h4.4 c0.3,0,0.4-0.1,0.4-0.3c0-0.1,0-0.2-0.1-0.3l-1.2-3.5c-0.3-0.8-0.8-1.9-0.8-2.7c0-0.1,0-0.1-0.1-0.1c0,0-0.1,0-0.1,0.1 c-0.1,0.6-0.4,1.2-0.7,1.7L9.1,13.1z"}),React.createElement(n.Path,{d:"M13.2,4.7l4.7,12.8c0.4,1.1,1,1.5,2.1,1.6c0.1,0,0.1,0,0.1,0l0.1,0.1l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1 s0,0.1-0.1,0.1c-0.1,0-0.1,0.1-0.1,0.1s-0.1,0-0.2,0h-5.1c-0.1,0-0.1,0-0.2,0c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1 c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1l0.1-0.1c0,0,0.1,0,0.2,0c0.5,0,1.1-0.2,1.1-0.8c0-0.3-0.1-0.5-0.2-0.8l-1.1-3.1 c-0.1-0.2-0.1-0.2-0.2-0.2h-4.3c-0.7,0-1.5,0-1.9,0.9l-1.1,2.4C7.1,17.6,7,17.8,7,18.1c0,0.8,1,0.9,1.6,0.9c0.1,0,0.1,0,0.2,0 L8.8,19l0.1,0.1c0,0.1,0,0.1,0,0.2c0,0.1,0,0.1,0,0.1s-0.1,0.1-0.1,0.1l-0.1,0.1c-0.1,0-0.1,0-0.2,0H4.1c-0.1,0-0.1,0-0.1,0 c-0.1,0-0.1-0.1-0.1-0.1l-0.1-0.1c0-0.1,0-0.1,0-0.1c0-0.1,0-0.1,0-0.2s0-0.1,0.1-0.1L4,19c0,0,0.1,0,0.1,0C5.2,19,5.5,18.5,6,17.5 l5.4-12.4c0.2-0.5,0.8-1,1.3-1C13,4.2,13.1,4.4,13.2,4.7z M9.1,13.1c0,0.1-0.1,0.1-0.1,0.2c0,0.1,0.1,0.1,0.1,0.1h4.4 c0.3,0,0.4-0.1,0.4-0.3c0-0.1,0-0.2-0.1-0.3l-1.2-3.5c-0.3-0.8-0.8-1.9-0.8-2.7c0-0.1,0-0.1-0.1-0.1c0,0-0.1,0-0.1,0.1 c-0.1,0.6-0.4,1.2-0.7,1.7L9.1,13.1z"}),React.createElement(n.Path,{d:"M21.6,12.5c0,0.6-0.3,1-0.9,1c-0.6,0-0.8-0.3-0.8-0.8c0-0.6,0.4-1,0.9-1C21.3,11.7,21.6,12.1,21.6,12.5z"}),React.createElement(n.Path,{d:"M4.1,12.5c0,0.6-0.3,1-0.9,1s-0.8-0.3-0.8-0.8c0-0.6,0.4-1,0.9-1S4.1,12.1,4.1,12.5z"})),backup:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"M2.1,5.8c0-0.1,0-0.1,0-0.2c0-0.2,0.1-0.5,0.1-0.7c0.1-0.4,0.4-0.6,0.7-0.8l8.3-2.9c0.1-0.1,0.3-0.1,0.4-0.1l0.5,0.1 l8.3,2.9c0.3,0.2,0.5,0.4,0.7,0.7c0.2,0.2,0.2,0.4,0.2,0.7c0,0.1,0,0.1,0,0.2v0.1c-0.1,0.5-0.2,0.9-0.3,1.4 c-0.2,0.4-0.3,1.2-0.7,2.2c-0.3,1-0.7,2.1-1.1,3.1c-0.5,1-1,2.1-1.6,3.3s-1.4,2.3-2.2,3.5c-0.9,1.1-1.8,2.2-2.8,3.1 c-0.2,0.2-0.5,0.4-0.9,0.4c-0.3,0-0.6-0.1-0.9-0.4c-1.2-1.1-2.4-2.4-3.5-4c-1-1.6-1.9-3-2.5-4.3c-0.6-1.3-1.1-2.7-1.6-4 C2.8,8.7,2.5,7.6,2.3,7C2.3,6.5,2.1,6.1,2.1,5.8z M2.9,5.9c0,0.2,0.1,0.4,0.1,0.8C3.1,7,3.2,7.5,3.5,8.2C3.7,9,3.9,9.7,4.2,10.6 c0.3,0.7,0.7,1.7,1.1,2.7c0.4,1,1,2,1.5,2.9c0.5,1,1.2,1.9,1.9,2.9c0.8,1,1.6,1.9,2.4,2.6c0.2,0.2,0.4,0.2,0.5,0.2 c0.2,0,0.4-0.1,0.5-0.2c1.2-1,2.2-2.3,3.2-3.8c1-1.5,1.8-2.8,2.3-4c0.6-1.3,1.1-2.5,1.5-3.9c0.4-1.3,0.7-2.2,0.9-2.8 c0.1-0.5,0.2-1,0.3-1.3c0-0.1,0-0.1,0-0.1c0-0.2,0-0.3-0.1-0.4C20.3,5.2,20.2,5.1,20,5L12,2.1c0,0-0.1,0-0.2,0s-0.1,0-0.1,0h-0.2 l-8,2.8C3.2,5,3.1,5.2,3,5.3C2.9,5.5,2.9,5.6,2.9,5.8C2.9,5.8,2.9,5.8,2.9,5.9z M5.9,6.7h3l2.8,7l2.8-7h3c-0.1,0.1-0.2,0.5-0.3,0.8 C17,7.8,17,8.2,16.8,8.4c-0.1,0.3-0.2,0.5-0.4,0.8c0,0.1-0.1,0.1-0.1,0.1s-0.1,0.1-0.2,0.1c-0.1,0-0.1,0-0.1,0 c-0.1,0-0.2,0.1-0.2,0.2c0,0-0.1,0.1-0.1,0.1s-0.1,0.1-0.1,0.1c0,0,0,0.1-0.1,0.2c0,0.1-0.1,0.1-0.1,0.1l-0.4,1.1 c-1.3,3.3-2.1,5.2-2.3,5.8h-2.2l-1-2.4c-0.1-0.3-0.3-0.8-0.5-1.3c-0.1-0.3-0.3-0.8-0.5-1.3L8,10.8c-0.1-0.1-0.1-0.2-0.1-0.4 C7.8,10.2,7.7,10,7.7,9.8C7.6,9.7,7.5,9.5,7.4,9.4C7.3,9.3,7.3,9.3,7.3,9.3c-0.1,0-0.2,0-0.2,0s-0.1,0-0.1,0 C6.6,8.5,6.3,7.6,5.9,6.7z"})),boost:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M4.19505 16.2545C4.47368 16.561 4.94802 16.5836 5.25451 16.3049L10.2595 11.7549L14.2842 15.2765L19 10.5607V13.75H20.5V9.5V8.75239V8.7476V8H19.7529H19.7471H19H14.75V9.5H17.9393L14.2158 13.2235L10.2405 9.74507L4.2455 15.195C3.93901 15.4737 3.91642 15.948 4.19505 16.2545Z"})),crm:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"M15.5 9.5a1 1 0 1 0 0-2 1 1 0 0 0 0 2Zm0 1.5a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5Zm-2.25 6v-2a2.75 2.75 0 0 0-2.75-2.75h-4A2.75 2.75 0 0 0 3.75 15v2h1.5v-2c0-.69.56-1.25 1.25-1.25h4c.69 0 1.25.56 1.25 1.25v2h1.5Zm7-2v2h-1.5v-2c0-.69-.56-1.25-1.25-1.25H15v-1.5h2.5A2.75 2.75 0 0 1 20.25 15ZM9.5 8.5a1 1 0 1 1-2 0 1 1 0 0 1 2 0Zm1.5 0a2.5 2.5 0 1 1-5 0 2.5 2.5 0 0 1 5 0Z"})),extras:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"M18.5 5.5V8H20V5.5h2.5V4H20V1.5h-1.5V4H16v1.5h2.5ZM12 4H6a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-6h-1.5v6a.5.5 0 0 1-.5.5H6a.5.5 0 0 1-.5-.5V6a.5.5 0 0 1 .5-.5h6V4Z"})),protect:({opacity:e=1,size:t,className:a,color:r})=>React.createElement(i,{className:a,size:t,opacity:e,color:r},React.createElement(n.Path,{d:"M12 3.17627L18.75 6.24445V10.8183C18.75 14.7173 16.2458 18.4089 12.7147 19.5735C12.2507 19.7265 11.7493 19.7265 11.2853 19.5735C7.75416 18.4089 5.25 14.7173 5.25 10.8183V6.24445L12 3.17627ZM6.75 7.21032V10.8183C6.75 14.1312 8.89514 17.2057 11.7551 18.149C11.914 18.2014 12.086 18.2014 12.2449 18.149C15.1049 17.2057 17.25 14.1312 17.25 10.8183V7.21032L12 4.82396L6.75 7.21032Z"}),React.createElement(n.Path,{d:"M15.5291 10.0315L11.1818 14.358L8.47095 11.66L9.52907 10.5968L11.1818 12.2417L14.4709 8.96826L15.5291 10.0315Z"})),scan:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"m12 3.176 6.75 3.068v4.574c0 3.9-2.504 7.59-6.035 8.755a2.283 2.283 0 0 1-1.43 0c-3.53-1.164-6.035-4.856-6.035-8.755V6.244L12 3.176ZM6.75 7.21v3.608c0 3.313 2.145 6.388 5.005 7.33.159.053.331.053.49 0 2.86-.942 5.005-4.017 5.005-7.33V7.21L12 4.824 6.75 7.21Z"})),search:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"M17.5 11.5a4 4 0 1 1-8 0 4 4 0 0 1 8 0Zm1.5 0a5.5 5.5 0 0 1-9.142 4.121l-3.364 2.943-.988-1.128 3.373-2.952A5.5 5.5 0 1 1 19 11.5Z"})),social:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{d:"M15.5 3.97809V18.0219L7.5 15.5977V20H6V15.1431L3.27498 14.3173C2.22086 13.9979 1.5 13.0262 1.5 11.9248V10.0752C1.5 8.97375 2.22087 8.00207 3.27498 7.68264L15.5 3.97809ZM14 16L7.5 14.0303L7.5 7.96969L14 5.99999V16ZM6 8.42423L6 13.5757L3.70999 12.8818C3.28835 12.754 3 12.3654 3 11.9248V10.0752C3 9.63462 3.28835 9.24595 3.70999 9.11818L6 8.42423ZM17.5 11.75H21.5V10.25H17.5V11.75ZM21.5 16L17.5 15V13.5L21.5 14.5V16ZM17.5 8.5L21.5 7.5V6L17.5 7V8.5Z"})),star:c,videopress:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M4.3,6.2c0.8,0,1.6,0.6,1.8,1.4l2.3,7.9c0,0,0,0,0,0l2.7-9.3h1.5h4.2c2.9,0,4.9,1.9,4.9,4.7c0,2.9-2,4.7-5,4.7 h-2h-2.5l-0.5,1.5c-0.4,1.4-1.7,2.3-3.2,2.3c-1.4,0-2.7-0.9-3.2-2.3L2.5,8.7C2.1,7.4,3,6.2,4.3,6.2z M13,12.8h2.9c1.3,0,2-0.7,2-1.9 c0-1.2-0.8-1.8-2-1.8h-1.7L13,12.8z"})),jetpack:d,share:({size:e=16,className:t,color:a})=>React.createElement(i,{className:t,size:e,color:a,viewBox:"0 0 16 16"},React.createElement(n.Path,{fill:"#161722",fillRule:"evenodd",d:"M8.3 4.66C3.85 5.308.727 9.75.034 13.69l-.02.117c-.137.842.809 1.232 1.446.68 2.013-1.745 3.648-2.475 5.318-2.719a10.482 10.482 0 011.524-.103v2.792c0 .694.82 1.041 1.3.55l6.176-6.307a.79.79 0 00.012-1.088L9.614 1.004C9.14.496 8.301.84 8.301 1.542v3.117zm1.525-1.175v1.85a.773.773 0 01-.654.77l-.655.096c-2.133.311-3.987 1.732-5.295 3.672-.472.7-.854 1.44-1.143 2.18a12.32 12.32 0 011.675-.972c1.58-.75 3.048-.972 4.548-.972h.762a.77.77 0 01.762.779v1.69l4.347-4.44-4.347-4.653z",clipRule:"evenodd"})),ai:v,stats:({opacity:e=1,size:t,color:a})=>React.createElement(i,{size:t,opacity:e,color:a},React.createElement(n.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M11.25 5H12.75V20H11.25V5ZM6 10H7.5V20H6V10ZM18 14H16.5V20H18V14Z"}))}};function m(e){return p[e]?p[e]:null}},38250:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(96072),o=a.n(r),n=a(27723),l=a(51113),s=a(53512),i=a(13022),c=a(51609),u=a.n(c),d=a(3924),v=a(61069),p=a(48907),m=(a(68271),a(67142)),h=a(60442);const __=n.__,_x=n._x,f=()=>u().createElement(m.A,{logoColor:"#000",showText:!1,height:16,"aria-hidden":"true"}),g=()=>u().createElement(u().Fragment,null,u().createElement(l.A,{icon:s.A,size:16}),u().createElement("span",{className:"jp-dashboard-footer__accessible-external-link"},/* translators: accessibility text */ -__("(opens in a new tab)","jetpack-my-jetpack"))),w=({moduleName:e=__("Jetpack","jetpack-my-jetpack"),className:t,moduleNameHref:a="https://jetpack.com",menu:r,useInternalLinks:n,onAboutClick:l,onPrivacyClick:s,onTermsClick:c,...m})=>{const[w]=(0,h.A)("sm","<="),[b]=(0,h.A)("md","<="),[y]=(0,h.A)("lg",">"),x=(0,v.A)();let _=[{label:_x("About","Link to learn more about Jetpack.","jetpack-my-jetpack"),title:__("About Jetpack","jetpack-my-jetpack"),href:n?new URL("admin.php?page=jetpack_about",x).href:(0,d.A)("jetpack-about"),target:n?"_self":"_blank",onClick:l},{label:_x("Privacy","Shorthand for Privacy Policy.","jetpack-my-jetpack"),title:__("Automattic's Privacy Policy","jetpack-my-jetpack"),href:n?new URL("admin.php?page=jetpack#/privacy",x).href:(0,d.A)("a8c-privacy"),target:n?"_self":"_blank",onClick:s},{label:_x("Terms","Shorthand for Terms of Service.","jetpack-my-jetpack"),title:__("WordPress.com Terms of Service","jetpack-my-jetpack"),href:(0,d.A)("wpcom-tos"),target:"_blank",onClick:c}];r&&(_=[..._,...r]);const k=u().createElement(u().Fragment,null,u().createElement(f,null),e);return u().createElement("footer",o()({className:(0,i.A)("jp-dashboard-footer",{"is-sm":w,"is-md":b,"is-lg":y},t),"aria-label":__("Jetpack","jetpack-my-jetpack"),role:"contentinfo"},m),u().createElement("ul",null,u().createElement("li",{className:"jp-dashboard-footer__jp-item"},a?u().createElement("a",{href:a},k):k),_.map((e=>{const t="button"===e.role,a=!t&&"_blank"===e.target;return u().createElement("li",{key:e.label},u().createElement("a",{href:e.href,title:e.title,target:e.target,onClick:e.onClick,onKeyDown:e.onKeyDown,className:(0,i.A)("jp-dashboard-footer__menu-item",{"is-external":a}),role:e.role,rel:a?"noopener noreferrer":void 0,tabIndex:t?0:void 0},e.label,a&&u().createElement(g,null)))})),u().createElement("li",{className:"jp-dashboard-footer__a8c-item"},u().createElement("a",{href:n?new URL("admin.php?page=jetpack_about",x).href:(0,d.A)("a8c-about"),"aria-label":__("An Automattic Airline","jetpack-my-jetpack")},u().createElement(p.A,{"aria-hidden":"true"})))))}},67142:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(96072),o=a.n(r),n=a(27723),l=a(13022),s=a(51609),i=a.n(s);const __=n.__,c=({logoColor:e="#069e08",showText:t=!0,className:a,height:r=32,...n})=>{const s=t?"0 0 118 32":"0 0 32 32";return i().createElement("svg",o()({xmlns:"http://www.w3.org/2000/svg",x:"0px",y:"0px",viewBox:s,className:(0,l.A)("jetpack-logo",a),"aria-labelledby":"jetpack-logo-title",height:r},n,{role:"img"}),i().createElement("title",{id:"jetpack-logo-title"},__("Jetpack Logo","jetpack-my-jetpack")),i().createElement("path",{fill:e,d:"M16,0C7.2,0,0,7.2,0,16s7.2,16,16,16s16-7.2,16-16S24.8,0,16,0z M15,19H7l8-16V19z M17,29V13h8L17,29z"}),t&&i().createElement(i().Fragment,null,i().createElement("path",{d:"M41.3,26.6c-0.5-0.7-0.9-1.4-1.3-2.1c2.3-1.4,3-2.5,3-4.6V8h-3V6h6v13.4C46,22.8,45,24.8,41.3,26.6z"}),i().createElement("path",{d:"M65,18.4c0,1.1,0.8,1.3,1.4,1.3c0.5,0,2-0.2,2.6-0.4v2.1c-0.9,0.3-2.5,0.5-3.7,0.5c-1.5,0-3.2-0.5-3.2-3.1V12H60v-2h2.1V7.1 H65V10h4v2h-4V18.4z"}),i().createElement("path",{d:"M71,10h3v1.3c1.1-0.8,1.9-1.3,3.3-1.3c2.5,0,4.5,1.8,4.5,5.6s-2.2,6.3-5.8,6.3c-0.9,0-1.3-0.1-2-0.3V28h-3V10z M76.5,12.3 c-0.8,0-1.6,0.4-2.5,1.2v5.9c0.6,0.1,0.9,0.2,1.8,0.2c2,0,3.2-1.3,3.2-3.9C79,13.4,78.1,12.3,76.5,12.3z"}),i().createElement("path",{d:"M93,22h-3v-1.5c-0.9,0.7-1.9,1.5-3.5,1.5c-1.5,0-3.1-1.1-3.1-3.2c0-2.9,2.5-3.4,4.2-3.7l2.4-0.3v-0.3c0-1.5-0.5-2.3-2-2.3 c-0.7,0-2.3,0.5-3.7,1.1L84,11c1.2-0.4,3-1,4.4-1c2.7,0,4.6,1.4,4.6,4.7L93,22z M90,16.4l-2.2,0.4c-0.7,0.1-1.4,0.5-1.4,1.6 c0,0.9,0.5,1.4,1.3,1.4s1.5-0.5,2.3-1V16.4z"}),i().createElement("path",{d:"M104.5,21.3c-1.1,0.4-2.2,0.6-3.5,0.6c-4.2,0-5.9-2.4-5.9-5.9c0-3.7,2.3-6,6.1-6c1.4,0,2.3,0.2,3.2,0.5V13 c-0.8-0.3-2-0.6-3.2-0.6c-1.7,0-3.2,0.9-3.2,3.6c0,2.9,1.5,3.8,3.3,3.8c0.9,0,1.9-0.2,3.2-0.7V21.3z"}),i().createElement("path",{d:"M110,15.2c0.2-0.3,0.2-0.8,3.8-5.2h3.7l-4.6,5.7l5,6.3h-3.7l-4.2-5.8V22h-3V6h3V15.2z"}),i().createElement("path",{d:"M58.5,21.3c-1.5,0.5-2.7,0.6-4.2,0.6c-3.6,0-5.8-1.8-5.8-6c0-3.1,1.9-5.9,5.5-5.9s4.9,2.5,4.9,4.9c0,0.8,0,1.5-0.1,2h-7.3 c0.1,2.5,1.5,2.8,3.6,2.8c1.1,0,2.2-0.3,3.4-0.7C58.5,19,58.5,21.3,58.5,21.3z M56,15c0-1.4-0.5-2.9-2-2.9c-1.4,0-2.3,1.3-2.4,2.9 C51.6,15,56,15,56,15z"})))}},28509:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(13022),o=a(51609),n=a(11616);const l=Number(n.A.smCols),s=Number(n.A.mdCols),i=Number(n.A.lgCols),c=e=>{const{children:t,tagName:a="div",className:c}=e,u=Math.min(l,"number"==typeof e.sm?e.sm:l),d=Math.min(l,"object"==typeof e.sm?e.sm.start:0),v=Math.min(l,"object"==typeof e.sm?e.sm.end:0),p=Math.min(s,"number"==typeof e.md?e.md:s),m=Math.min(s,"object"==typeof e.md?e.md.start:0),h=Math.min(s,"object"==typeof e.md?e.md.end:0),f=Math.min(i,"number"==typeof e.lg?e.lg:i),g=Math.min(i,"object"==typeof e.lg?e.lg.start:0),w=Math.min(i,"object"==typeof e.lg?e.lg.end:0),b=(0,r.A)(c,{[n.A[`col-sm-${u}`]]:!(d&&v),[n.A[`col-sm-${d}-start`]]:d>0,[n.A[`col-sm-${v}-end`]]:v>0,[n.A[`col-md-${p}`]]:!(m&&h),[n.A[`col-md-${m}-start`]]:m>0,[n.A[`col-md-${h}-end`]]:h>0,[n.A[`col-lg-${f}`]]:!(g&&w),[n.A[`col-lg-${g}-start`]]:g>0,[n.A[`col-lg-${w}-end`]]:w>0});return(0,o.createElement)(a,{className:b},t)}},75918:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(13022),o=a(51609),n=a(51519);const l=({children:e,fluid:t=!1,tagName:a="div",className:l,horizontalGap:s=1,horizontalSpacing:i=1},c)=>{const u=(0,o.useMemo)((()=>{const e=`calc( var(--horizontal-spacing) * ${i} )`;return{paddingTop:e,paddingBottom:e,rowGap:`calc( var(--horizontal-spacing) * ${s} )`}}),[s,i]),d=(0,r.A)(l,n.A.container,{[n.A.fluid]:t});return(0,o.createElement)(a,{className:d,style:u,ref:c},e)},s=(0,o.forwardRef)(l)},60442:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(29491),o=a(15508);const n=["sm","md","lg"],l=(e,t)=>{const a=Array.isArray(e)?e:[e],l=Array.isArray(t)?t:[t],[s,i,c]=n,u={sm:(0,r.useMediaQuery)(o.A[s]),md:(0,r.useMediaQuery)(o.A[i]),lg:(0,r.useMediaQuery)(o.A[c])};return a.map(((e,t)=>{const a=l[t];return a?((e,t,a)=>{const r=n.indexOf(e),o=r+1,l=t.includes("=");let s=[];return t.startsWith("<")&&(s=n.slice(0,l?o:r)),t.startsWith(">")&&(s=n.slice(l?r:o)),s?.length?s.some((e=>a[e])):a[e]})(e,a,u):u[e]}))}},47656:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var r=a(23751),o=a(19783),n=a(83883),l=a(51113),s=a(10991),i=a(13022),c=a(51609),u=a.n(c),d=a(4097);const v=e=>{switch(e){case"error":case"warning":default:return r.A;case"info":return o.A;case"success":return n.A}},p=({level:e="info",title:t,children:a,actions:r,hideCloseButton:o=!1,onClose:n})=>{const c=(0,i.A)(d.A.container,d.A[`is-${e}`]);return u().createElement("div",{className:c},u().createElement("div",{className:d.A["icon-wrapper"]},u().createElement(l.A,{icon:v(e),className:d.A.icon})),u().createElement("div",{className:d.A["main-content"]},t&&u().createElement("div",{className:d.A.title},t),a,r&&r.length>0&&u().createElement("div",{className:d.A["action-bar"]},r.map(((e,t)=>u().createElement("div",{key:t,className:d.A.action},e))))),!o&&u().createElement("button",{"aria-label":"close",className:d.A["close-button"],onClick:n},u().createElement(l.A,{icon:s.A})))}},37975:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(51437);const o=(e,t={})=>{const a=(0,r.Y)();return new Intl.NumberFormat(a,t).format(e)}},79245:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>_,N0:()=>x,eY:()=>b,i7:()=>y});var r=a(27723),o=a(51113),n=a(83883),l=a(31249),s=a(13022),i=a(51609),c=a.n(i),u=a(40597),d=a(60442),v=a(85879),p=a(47425),m=a(13149);const __=r.__,h=__("Included","jetpack-my-jetpack"),f=__("Not included","jetpack-my-jetpack"),g=__("Coming soon","jetpack-my-jetpack"),w=(0,i.createContext)(void 0),b=({isIncluded:e=!1,isComingSoon:t=!1,index:a=0,label:v=null,tooltipInfo:b,tooltipTitle:y,tooltipClassName:x=""})=>{const[_]=(0,d.A)("lg"),k=(0,i.useContext)(w)[a],E=t||e,C=k.name,j=k.tooltipInfo,A=k.tooltipTitle,S=b||!_&&j,P=((e,t,a)=>e?{lg:g, -// translators: Name of the current feature -default:(0,r.sprintf)(__("%s coming soon","jetpack-my-jetpack"),a)}:{lg:t?h:f,default:t?a:(0,r.sprintf)(/* translators: Name of the current feature */ -__("%s not included","jetpack-my-jetpack"),a)})(t,e,C),R=_?P.lg:P.default;return c().createElement("div",{className:(0,s.A)(m.A.item,m.A.value)},c().createElement(o.A,{className:(0,s.A)(m.A.icon,E?m.A["icon-check"]:m.A["icon-cross"]),size:32,icon:E?n.A:l.A}),c().createElement(p.Ay,{variant:"body-small"},v||R),S&&c().createElement(u.A,{title:y||A,iconClassName:m.A["popover-icon"],className:(0,s.A)(m.A.popover,x),placement:"bottom-end",iconSize:14,offset:4,wide:Boolean(y&&b)},c().createElement(p.Ay,{variant:"body-small",component:"div"},b||j)))},y=({children:e})=>c().createElement("div",{className:m.A.header},e),x=({primary:e=!1,children:t})=>{let a=0;return c().createElement("div",{className:(0,s.A)(m.A.card,{[m.A["is-primary"]]:e})},i.Children.map(t,(e=>{const t=e;return t.type===b?(a++,(0,i.cloneElement)(t,{index:a-1})):t})))},_=({title:e,items:t,children:a,showIntroOfferDisclaimer:r=!1})=>{const[o]=(0,d.A)("lg");return c().createElement(w.Provider,{value:t},c().createElement("div",{className:(0,s.A)(m.A.container,{[m.A["is-viewport-large"]]:o}),style:{"--rows":t.length+1,"--columns":i.Children.toArray(a).length+1}},c().createElement("div",{className:m.A.table},c().createElement(p.Ay,{variant:"headline-small"},e),o&&t.map(((e,a)=>c().createElement("div",{className:(0,s.A)(m.A.item,{[m.A["last-feature"]]:a===t.length-1}),key:a},c().createElement(p.Ay,{variant:"body-small"},c().createElement("strong",null,e.name)),e.tooltipInfo&&c().createElement(u.A,{title:e.tooltipTitle,iconClassName:m.A["popover-icon"],className:m.A.popover,placement:e.tooltipPlacement?e.tooltipPlacement:"bottom-end",iconSize:14,offset:4,wide:Boolean(e.tooltipTitle&&e.tooltipInfo)},c().createElement(p.Ay,{variant:"body-small"},e.tooltipInfo))))),a)),c().createElement("div",{className:m.A["tos-container"]},c().createElement("div",{className:m.A.tos},r&&c().createElement(p.Ay,{variant:"body-small"},__("Reduced pricing is a limited offer for the first year and renews at regular price.","jetpack-my-jetpack")),c().createElement(v.A,{multipleButtons:!0}))))}},489:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(27723),o=a(13022),n=a(47425),l=a(72746),s=a(76066);const __=r.__,i=({price:e,offPrice:t,currency:a="",showNotOffPrice:r=!0,hideDiscountLabel:i=!0,promoLabel:c="",legend:u=__("/month, paid yearly","jetpack-my-jetpack"),isNotConvenientPrice:d=!1,hidePriceFraction:v=!1,children:p})=>{if(null==e&&null==t||!a)return null;r=r&&null!=t;const m="number"==typeof e&&"number"==typeof t?Math.floor((e-t)/e*100):0,h=!i&&m&&m>0?m+__("% off","jetpack-my-jetpack"):null;return React.createElement(React.Fragment,null,React.createElement("div",{className:s.A.container},React.createElement("div",{className:(0,o.A)(s.A["price-container"],"product-price_container")},React.createElement(l.g,{value:t??e,currency:a,isOff:!d,hidePriceFraction:v}),r&&React.createElement(l.g,{value:e,currency:a,isOff:!1,hidePriceFraction:v}),h&&React.createElement(n.Ay,{className:(0,o.A)(s.A["promo-label"],"product-price_promo_label")},h))),React.createElement("div",{className:s.A.footer},p||React.createElement(n.Ay,{className:(0,o.A)(s.A.legend,"product-price_legend")},u),c&&React.createElement(n.Ay,{className:(0,o.A)(s.A["promo-label"],"product-price_promo_label")},c)))}},72746:(e,t,a)=>{"use strict";a.d(t,{g:()=>s});var r=a(67397),o=a(13022),n=a(47425),l=a(76066);const s=({value:e,currency:t,isOff:a,hidePriceFraction:s})=>{const i=(0,o.A)(l.A.price,"product-price_price",{[l.A["is-not-off-price"]]:!a}),{symbol:c,integer:u,fraction:d}=(0,r.vA)(e,t),v=!s||!d.endsWith("00");return React.createElement(n.Ay,{className:i,variant:"headline-medium",component:"p"},React.createElement(n.Ay,{className:l.A.symbol,component:"sup",variant:"title-medium"},c),u,v&&React.createElement(n.Ay,{component:"sup",variant:"body-small","data-testid":"PriceFraction"},React.createElement("strong",null,d)))}},56461:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(28120),o=a.n(r),n=a(51609),l=a.n(n);a(49986);const s=({color:e="#FFFFFF",className:t="",size:a=20})=>{const r=t+" jp-components-spinner",o={width:a,height:a,fontSize:a,borderTopColor:e},n={borderTopColor:e,borderRightColor:e};return l().createElement("div",{className:r},l().createElement("div",{className:"jp-components-spinner__outer",style:o},l().createElement("div",{className:"jp-components-spinner__inner",style:n})))};s.propTypes={color:o().string,className:o().string,size:o().number};const i=s},85879:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var r=a(96072),o=a.n(r),n=a(86087),l=a(27723),s=a(13022),i=a(3924),c=a(47425);a(36001);const __=l.__,u=({multipleButtonsLabels:e})=>Array.isArray(e)&&e.length>1?(0,n.createInterpolateElement)((0,l.sprintf)(/* translators: %1$s is button label 1 and %2$s is button label 2 */ -__("By clicking %1$s or %2$s, you agree to our Terms of Service and to sync your site‘s data with us.","jetpack-my-jetpack"),e[0],e[1]),{strong:React.createElement("strong",null),tosLink:React.createElement(p,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(p,{slug:"jetpack-support-what-data-does-jetpack-sync"})}):(0,n.createInterpolateElement)(__("By clicking the buttons above, you agree to our Terms of Service and to sync your site‘s data with us.","jetpack-my-jetpack"),{tosLink:React.createElement(p,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(p,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),d=({agreeButtonLabel:e})=>(0,n.createInterpolateElement)((0,l.sprintf)(/* translators: %s is a button label */ -__("By clicking %s, you agree to our Terms of Service and to sync your site‘s data with us.","jetpack-my-jetpack"),e),{strong:React.createElement("strong",null),tosLink:React.createElement(p,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(p,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),v=()=>(0,n.createInterpolateElement)(__("By continuing you agree to our Terms of Service and to sync your site’s data with us. We’ll check if that email is linked to an existing WordPress.com account or create a new one instantly.","jetpack-my-jetpack"),{tosLink:React.createElement(p,{slug:"wpcom-tos"}),shareDetailsLink:React.createElement(p,{slug:"jetpack-support-what-data-does-jetpack-sync"})}),p=({slug:e,children:t})=>React.createElement("a",{className:"terms-of-service__link",href:(0,i.A)(e),rel:"noopener noreferrer",target:"_blank"},t),m=({className:e,multipleButtons:t,agreeButtonLabel:a,isTextOnly:r,...n})=>React.createElement(c.Ay,o()({className:(0,s.A)(e,"terms-of-service")},n),r?React.createElement(v,null):t?React.createElement(u,{multipleButtonsLabels:t}):React.createElement(d,{agreeButtonLabel:a}))},10110:(e,t,a)=>{"use strict";a.d(t,{Q:()=>r,Z:()=>o});const r={"headline-medium":"h1","headline-small":"h2","headline-small-regular":"h2","title-medium":"h3","title-medium-semi-bold":"h3","title-small":"h4",body:"p","body-small":"p","body-extra-small":"p","body-extra-small-bold":"p",label:"p"},o=["mt","mr","mb","ml","mx","my","m","pt","pr","pb","pl","px","py","p"]},47425:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>d,H3:()=>v,hE:()=>p});var r=a(96072),o=a.n(r),n=a(13022),l=a(51609),s=a.n(l),i=a(10110),c=a(63132);const u=(0,l.forwardRef)((({variant:e="body",children:t,component:a,className:r,...u},d)=>{const v=a||i.Q[e]||"span",p=(0,l.useMemo)((()=>i.Z.reduce(((e,t)=>(void 0!==u[t]&&(e+=c.A[`${t}-${u[t]}`]+" ",delete u[t]),e)),"")),[u]);return s().createElement(v,o()({className:(0,n.A)(c.A.reset,c.A[e],r,p)},u,{ref:d}),t)}));u.displayName="Text";const d=u,v=({children:e,weight:t="bold",...a})=>{const r="headline-small"+("bold"===t?"":`-${t}`);return s().createElement(u,o()({variant:r,mb:3},a),e)},p=({children:e,size:t="medium",...a})=>s().createElement(u,o()({variant:`title-${t}`,mb:1},a),e)},50723:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>v});var r=a(51609),o=a.n(r),n=a(69973);const l={"--font-headline-medium":"48px","--font-headline-small":"36px","--font-title-medium":"24px","--font-title-small":"20px","--font-body":"16px","--font-body-small":"14px","--font-body-extra-small":"12px","--font-title-large":"var(--font-headline-small)","--font-label":"var(--font-body-extra-small)"},s={"--jp-black":"#000000","--jp-black-80":"#2c3338","--jp-white":"#ffffff","--jp-white-off":"#f9f9f6","--jp-gray":"#dcdcde","--jp-gray-0":"#F6F7F7","--jp-gray-5":"var(--jp-gray)","--jp-gray-10":"#C3C4C7","--jp-gray-20":"#A7AAAD","--jp-gray-40":"#787C82","--jp-gray-50":"#646970","--jp-gray-60":"#50575E","--jp-gray-70":"#3C434A","--jp-gray-80":"#2C3338","--jp-gray-90":"#1d2327","--jp-gray-off":"#e2e2df","--jp-red-0":"#F7EBEC","--jp-red-5":"#FACFD2","--jp-red-40":"#E65054","--jp-red-50":"#D63638","--jp-red-60":"#B32D2E","--jp-red-70":"#8A2424","--jp-red-80":"#691C1C","--jp-red":"#d63639","--jp-yellow-5":"#F5E6B3","--jp-yellow-10":"#F2CF75","--jp-yellow-20":"#F0C930","--jp-yellow-30":"#DEB100","--jp-yellow-40":"#C08C00","--jp-yellow-50":"#9D6E00","--jp-yellow-60":"#7D5600","--jp-blue-20":"#68B3E8","--jp-blue-40":"#1689DB","--jp-pink":"#C9356E","--jp-green-0":"#f0f2eb","--jp-green-5":"#d0e6b8","--jp-green-10":"#9dd977","--jp-green-20":"#64ca43","--jp-green-30":"#2fb41f","--jp-green-40":"#069e08","--jp-green-50":"#008710","--jp-green-60":"#007117","--jp-green-70":"#005b18","--jp-green-80":"#004515","--jp-green-90":"#003010","--jp-green-100":"#001c09","--jp-green":"#069e08","--jp-green-primary":"var( --jp-green-40 )","--jp-green-secondary":"var( --jp-green-30 )"},i={"--jp-border-radius":"4px","--jp-menu-border-height":"1px","--jp-underline-thickness":"2px"},c={"--spacing-base":"8px"},u={},d=(e,t,a)=>{const r={...l,...s,...i,...c};for(const t in r)e.style.setProperty(t,r[t]);a&&e.classList.add(n.A.global),t&&(u[t]={provided:!0,root:e})},v=({children:e=null,targetDom:t,id:a,withGlobalStyles:n=!0})=>{const l=(0,r.useRef)(),s=u?.[a]?.provided;return(0,r.useLayoutEffect)((()=>{if(!s)return t?d(t,a,n):void(l?.current&&d(l.current,a,n))}),[t,l,s,a,n]),t?o().createElement(o().Fragment,null,e):o().createElement("div",{ref:l},e)}},67506:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(56427),o=a(86087),n=a(51609),l=a.n(n),s=a(51112);a(85157);const i=e=>{const{icon:t,title:a,description:n,primaryCtaLabel:i,primaryCtaURL:c,primaryCtaIsExternalLink:u,primaryCtaOnClick:d,secondaryCtaLabel:v,secondaryCtaURL:p,secondaryCtaIsExternalLink:m,secondaryCtaOnClick:h}=e;return l().createElement(r.Card,{isRounded:!0,size:"large"},l().createElement(r.CardBody,{className:"upsell-banner",size:"large"},t&&l().createElement("div",{className:"upsell-banner--icon"},l().createElement("img",{src:t,alt:""})),l().createElement("div",{className:"upsell-banner--content"},l().createElement("div",{className:"upsell-banner--content-info"},l().createElement("h3",null,a),l().createElement("p",null,(0,o.createInterpolateElement)(n,{br:l().createElement("br",null)}))),l().createElement("div",{className:"upsell-banner--content-cta"},v&&p&&l().createElement(s.A,{className:"upsell-banner--content-cta-button secondary",href:p,onClick:h??void 0,isExternalLink:m},v),i&&c&&l().createElement(s.A,{className:"upsell-banner--content-cta-button primary",href:c,onClick:d??void 0,isExternalLink:u},i)))))}},31984:(e,t,a)=>{"use strict";a.d(t,{o:()=>r});const r="d729d42c-b547-4750-a6f6-8b30534a5f12"},18587:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(51609),o=a(31984);const n=({jwt_token:e})=>{const t=(0,r.useCallback)((()=>{"undefined"!=typeof window&&"function"==typeof window.zE&&window.zE("messenger","loginUser",(function(t){t(e)}))}),[e]);return(0,r.useEffect)((()=>{const e=document.createElement("script"),a=document.getElementById("zendesk-chat-container");e.src="https://static.zdassets.com/ekr/snippet.js?key="+encodeURIComponent(o.o),e.type="text/javascript",e.id="ze-snippet",e.onload=()=>{t()},a&&a.appendChild(e)}),[t]),React.createElement("div",{"data-testid":"zendesk-chat-container",id:"zendesk-chat-container"})}},51437:(e,t,a)=>{"use strict";a.d(t,{Y:()=>o});var r=a(38443);const o=()=>{const{l10n:{locale:e}}=(0,r.getSettings)();if(e)return(e=>{const t=e.match(/^([a-z]{2,3})(_[a-z]{2}|_[a-z][a-z0-9]{4,7})?(?:_.*)?$/i);return t?`${t[1]}${t[2]?t[2]:""}`.replace("_","-"):"en-US"})(e);return window?.window?.navigator?.language??"en-US"}},61069:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(97999);function o(){return(0,r.getScriptData)()?.site?.admin_url||window.Initial_State?.adminUrl||window.Jetpack_Editor_Initial_State?.adminUrl||window?.myJetpackInitialState?.adminUrl||null}},3924:(e,t,a)=>{"use strict";function r(e,t={}){const a={};let r;if("undefined"!=typeof window&&(r=window?.JP_CONNECTION_INITIAL_STATE?.calypsoEnv),0===e.search("https://")){const t=new URL(e);e=`https://${t.host}${t.pathname}`,a.url=encodeURIComponent(e)}else a.source=encodeURIComponent(e);for(const e in t)a[e]=encodeURIComponent(t[e]);!Object.keys(a).includes("site")&&"undefined"!=typeof jetpack_redirects&&Object.hasOwn(jetpack_redirects,"currentSiteRawUrl")&&(a.site=jetpack_redirects.currentBlogID??jetpack_redirects.currentSiteRawUrl),r&&(a.calypso_env=r);return"https://jetpack.com/redirect/?"+Object.keys(a).map((e=>e+"="+a[e])).join("&")}a.d(t,{A:()=>r})},56439:(e,t,a)=>{let r={};try{r=a(25990)}catch{console.error("jetpackConfig is missing in your webpack config file. See @automattic/jetpack-config"),r={missingConfig:!0}}const o=e=>Object.hasOwn(r,e);e.exports={jetpackConfigHas:o,jetpackConfigGet:e=>{if(!o(e))throw'This app requires the "'+e+'" Jetpack Config to be defined in your webpack configuration file. See details in @automattic/jetpack-config package docs.';return r[e]}}},59534:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(90372),o=a(67142),n=a(56461),l=a(56427),s=a(86087),i=a(27723),c=a(28120),u=a.n(c),d=a(51609),v=a.n(d),p=a(9144),m=a(18269);const __=i.__,h=e=>{const{className:t,disabled:a,onChange:r,value:o}=e;return v().createElement(l.TextControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,className:t,label:__("License key","jetpack-my-jetpack"),value:o,onChange:r,disabled:a})},f=e=>{const{className:t,availableLicenses:a,disabled:r,onChange:o,value:n}=e,[s,c]=(0,d.useState)(""),u=null===a,p=(0,d.useMemo)((()=>u?[{label:__("Fetching available licenses…","jetpack-my-jetpack"),value:""}]:[...a.map((({product:e,license_key:t})=>({label:(0,i.sprintf)(/* translators: placeholder is the product name and license key */ -__("%1$s - %2$s","jetpack-my-jetpack"),e,t),value:t}))),{label:__("I want to add a license key manually","jetpack-my-jetpack"),value:""}]),[a,u]);(0,d.useEffect)((()=>{c(p?.length?p[0].value:"")}),[p]);const m=(0,d.useCallback)((e=>{c(e),o(e)}),[o]);return v().createElement(v().Fragment,null,v().createElement(l.SelectControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,className:t,disabled:r,label:__("Select a license key","jetpack-my-jetpack"),value:s,options:p,onChange:m}),!u&&!s&&v().createElement(l.TextControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,className:t,label:__("Input a license key","jetpack-my-jetpack"),value:n,onChange:o,disabled:r}))},g=e=>{const{activateLicense:t,availableLicenses:a,fetchingAvailableLicenses:i,isActivating:c,license:u,licenseError:g,onLicenseChange:w}=e;(0,d.useEffect)((()=>{r.A.tracks.recordEvent("jetpack_wpa_license_key_activation_view")}),[]);const b=g?.match(/\[[a-z_]+\]/),y=b&&b[0],{ACTIVE_ON_SAME_SITE:x}=m.a,_=x===y,k=(0,d.useMemo)((()=>g?_?"jp-license-activation-screen-controls--license-field-with-success":"jp-license-activation-screen-controls--license-field-with-error":"jp-license-activation-screen-controls--license-field"),[g,_]),E=a&&a.length;return v().createElement("div",{className:"jp-license-activation-screen-controls"},v().createElement("div",{className:"jp-license-activation-screen-controls--content"},v().createElement(o.A,{showText:!1,height:48}),v().createElement("h1",null,__("Add a license key","jetpack-my-jetpack")),v().createElement("p",null,(0,s.createInterpolateElement)(__("Check your email for your license key. You should have received it after making your purchase.","jetpack-my-jetpack"),{strong:v().createElement("strong",null)})),i||E?v().createElement(f,{className:k,disabled:i||c,onChange:w,availableLicenses:i?null:a,value:u}):v().createElement(h,{className:k,disabled:c,onChange:w,value:u}),g&&v().createElement(p.A,{licenseError:g,errorType:y})),v().createElement("div",null,v().createElement(l.Button,{className:"jp-license-activation-screen-controls--button",onClick:t,disabled:!u},c?v().createElement(n.A,null):__("Activate","jetpack-my-jetpack"))))};g.propTypes={activateLicense:u().func.isRequired,availableLicenses:u().array,fetchingAvailableLicenses:u().bool,isActivating:u().bool.isRequired,license:u().string.isRequired,licenseError:u().string,onLicenseChange:u().func.isRequired,siteUrl:u().string.isRequired};const w=g},18269:(e,t,a)=>{"use strict";a.d(t,{a:()=>r});const r={NOT_SAME_OWNER:"[not_same_owner]",ACTIVE_ON_SAME_SITE:"[active_on_same_site]",ATTACHED_LICENSE:"[attached_license]",PRODUCT_INCOMPATIBILITY:"[product_incompatibility]",REVOKED_LICENSE:"[revoked_license]",INVALID_INPUT:"[invalid_input]",MULTISITE_INCOMPATIBILITY:"[multisite_incompatibility]"}},9144:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(90372),o=a(51113),n=a(83883),l=a(23751),s=a(51609),i=a.n(s),c=a(18269),u=a(40635);const d=({licenseError:e,errorType:t})=>{(0,s.useEffect)((()=>{e&&r.A.tracks.recordEvent("jetpack_wpa_license_activation_error_view",{error:e,error_type:t})}),[e,t]);const{errorMessage:a,errorInfo:d}=(0,u.d)(e,t);if(!e)return null;const{ACTIVE_ON_SAME_SITE:v}=c.a,p=v===t,m=p?"activation-screen-error__message--success":"activation-screen-error__message--error";return i().createElement(i().Fragment,null,i().createElement("div",{className:`activation-screen-error__message ${m}`},i().createElement(o.A,{icon:p?n.A:l.A,size:20}),i().createElement("span",null,a)),d&&i().createElement("div",{className:"activation-screen-error__info"},d))}},40635:(e,t,a)=>{"use strict";a.d(t,{d:()=>u});var r=a(3924),o=a(56427),n=a(86087),l=a(27723),s=a(51609),i=a.n(s),c=a(18269);const __=l.__,u=(e,t)=>{if(!e)return{errorMessage:null,errorInfo:null};const a=(0,n.createInterpolateElement)(__("Need help? Get in touch.","jetpack-my-jetpack"),{a:i().createElement(o.ExternalLink,{href:(0,r.A)("jetpack-support-license-activation"),rel:"noopener noreferrer"})});switch(t){case c.a.NOT_SAME_OWNER:return{errorMessage:__("The account that purchased the plan and the account managing this site are different.","jetpack-my-jetpack"),errorInfo:i().createElement(i().Fragment,null,i().createElement("p",null,(0,n.createInterpolateElement)(__("Follow these steps to resolve it.","jetpack-my-jetpack"),{a:i().createElement(o.ExternalLink,{rel:"noopener noreferrer",href:(0,r.A)("jetpack-support-activate-license",{anchor:"different-user"})})})),i().createElement("ol",null,i().createElement("li",null,__("Disconnect Jetpack from your site.","jetpack-my-jetpack")),i().createElement("li",null,__("Log in to the WordPress.com account that purchased the plan.","jetpack-my-jetpack")),i().createElement("li",null,__("Reconnect Jetpack.","jetpack-my-jetpack"))),i().createElement("p",null,a))};case c.a.ACTIVE_ON_SAME_SITE:return{errorMessage:__("This license is already active on your site.","jetpack-my-jetpack"),errorInfo:null};case c.a.ATTACHED_LICENSE:return{errorMessage:__("This license is already active on another website","jetpack-my-jetpack"),errorInfo:i().createElement("ul",null,i().createElement("li",null,(0,n.createInterpolateElement)(__("If you would like to transfer it, please get in touch.","jetpack-my-jetpack"),{a:i().createElement(o.ExternalLink,{rel:"noopener noreferrer",href:(0,r.A)("jetpack-support-license-activation")})})),i().createElement("li",null,(0,n.createInterpolateElement)(__("To use Jetpack on both sites, please buy another license.","jetpack-my-jetpack"),{a:i().createElement(o.ExternalLink,{rel:"noopener noreferrer",href:(0,r.A)("my-jetpack-my-plans-purchase-no-site")})})))};case c.a.PRODUCT_INCOMPATIBILITY:return{errorMessage:__("Your site already has an active Jetpack plan of equal or higher value.","jetpack-my-jetpack"),errorInfo:i().createElement(i().Fragment,null,i().createElement("p",null,__("It looks like your website already has a Jetpack plan that’s equal to or better than the one you’re trying to activate.","jetpack-my-jetpack")),i().createElement("p",null,__("You can either use this license on a different site or cancel your current plan for a refund.","jetpack-my-jetpack")),i().createElement("p",null,a))};case c.a.REVOKED_LICENSE:return{errorMessage:__("The subscription is no longer active or has expired. Please purchase a new license.","jetpack-my-jetpack"),errorInfo:i().createElement("p",null,a)};case c.a.INVALID_INPUT:return{errorMessage:__("Unable to validate this license key.","jetpack-my-jetpack"),errorInfo:i().createElement(i().Fragment,null,i().createElement("p",null,__("Please take a moment to check the license key from your purchase confirmation email—it might have a small typo.","jetpack-my-jetpack")),i().createElement("p",null,a))};case c.a.MULTISITE_INCOMPATIBILITY:{const t=e.match(/We.re sorry, (.*) is not compatible/),r=t&&t[1];return{errorMessage:(0,l.sprintf)(/* translators: %s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Boost, etc., which the product name should not be translated. */ -__("We’re sorry, %s is not compatible with multisite WordPress installations at this time.","jetpack-my-jetpack"),r),errorInfo:i().createElement(i().Fragment,null,i().createElement("p",null,__("This Jetpack plan doesn’t work with Multisite WordPress setups. Please use it on a single-site installation or consider canceling for a refund.","jetpack-my-jetpack")),i().createElement("p",null,a))}}default:return{errorMessage:e,errorInfo:i().createElement("p",null,a)}}}},5986:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(3924),o=a(86087),n=a(27723),l=a(28120),s=a.n(l),i=a(51609),c=a.n(i);const __=n.__,u=e=>{const{imageUrl:t,showSupportLink:a=!1}=e;return c().createElement("div",{className:"jp-license-activation-screen-illustration"},c().createElement("div",{className:"jp-license-activation-screen-illustration--wrapper"},c().createElement("img",{className:"jp-license-activation-screen-illustration--img",src:t,alt:""})),a&&c().createElement("p",{className:"jp-license-activation-screen-illustration--support-link"},(0,o.createInterpolateElement)(__("Do you need help? Contact us.","jetpack-my-jetpack"),{a:c().createElement("a",{href:(0,r.A)("jetpack-support-license-activation")})})))};u.propTypes={imageUrl:s().string.isRequired,showSupportLink:s().bool};const d=u},23806:(e,t,a)=>{"use strict";a.d(t,{A:()=>v});var r=a(67142),o=a(28120),n=a.n(o),l=a(51609),s=a.n(l),i=a(48354),c=a(88560),u=a(28547);const d=e=>{const{productId:t,siteRawUrl:a,siteAdminUrl:o,currentRecommendationsStep:n}=e;return s().createElement("div",{className:"jp-license-activation-screen-success-info"},s().createElement("div",{className:"jp-license-activation-screen-success-info--content"},s().createElement(r.A,{showText:!1,height:48})),s().createElement(c.A,{siteRawUrl:a,productId:t}),s().createElement("div",{className:"jp-license-activation-screen-success-info--buttons"},s().createElement(i.F,{currentRecommendationsStep:n,siteAdminUrl:o,siteRawUrl:a,productId:t}),s().createElement(u.m,{siteRawUrl:a,productId:t})))};d.propTypes={siteRawUrl:n().string,productId:n().number,siteAdminUrl:n().string,currentRecommendationsStep:n().string};const v=d},48354:(e,t,a)=>{"use strict";a.d(t,{F:()=>p});var r=a(56461),o=a(3924),n=a(56427),l=a(27723),s=a(28120),i=a.n(s),c=a(51609),u=a.n(c),d=a(73010),v=a(21183);const __=l.__,p=e=>{const{currentRecommendationsStep:t,siteAdminUrl:a,siteRawUrl:l,productId:s}=e,[i,c]=(0,d.A)(),p=e=>i.map((e=>e.name)).includes(e),m=(0,v.p)(s),h=p("Jetpack"),f=p("Jetpack Social"),g="jetpack_social_advanced"===m||"jetpack_social_basic"===m,w=p("Jetpack Protect");if(c)return u().createElement(n.Button,{className:"jp-license-activation-screen-success-info--button"},u().createElement(r.A,null));if(g&&(h||f))return u().createElement(n.Button,{className:"jp-license-activation-screen-success-info--button",href:a+(h?"admin.php?page=jetpack#/recommendations/"+("jetpack_social_advanced"===m?"welcome-social-advanced":"welcome-social-basic"):"admin.php?page=jetpack-social")},__("Configure my site","jetpack-my-jetpack"));if("jetpack_scan"===m){const e=w?a+"admin.php?page=jetpack-protect":(0,o.A)("jetpack-license-activation-success-scan",{site:l});return u().createElement(n.Button,{className:"jp-license-activation-screen-success-info--button",href:e},__("View scan results","jetpack-my-jetpack"))}return"not-started"===t?u().createElement(n.Button,{className:"jp-license-activation-screen-success-info--button",href:a+"admin.php?page=jetpack#/recommendations"},__("Configure my site","jetpack-my-jetpack")):u().createElement(n.Button,{className:"jp-license-activation-screen-success-info--button",href:(0,o.A)("license-activation-view-my-plans",{site:l})},__("View my plans","jetpack-my-jetpack"))};p.propTypes={siteAdminUrl:i().string.isRequired,currentRecommendationsStep:i().string,siteRawUrl:i().string.isRequired}},28547:(e,t,a)=>{"use strict";a.d(t,{m:()=>d});var r=a(3924),o=a(56427),n=a(27723),l=a(28120),s=a.n(l),i=a(51609),c=a.n(i),u=a(21183);const __=n.__,d=e=>{const{productId:t,siteRawUrl:a}=e,n={jetpack_backup:{text:__("View latest backup","jetpack-my-jetpack"),redirectSource:"jetpack-license-activation-success-backup"},jetpack_complete:{text:__("View latest backup","jetpack-my-jetpack"),redirectSource:"jetpack-license-activation-success-backup"},jetpack_scan:{text:__("View my plans","jetpack-my-jetpack"),redirectSource:"license-activation-view-my-plans"},jetpack_search:{text:__("Configure search","jetpack-my-jetpack"),redirectSource:"jetpack-license-activation-success-search"},jetpack_security:{text:__("View latest backup","jetpack-my-jetpack"),redirectSource:"jetpack-license-activation-success-backup"},default:null}[(0,u.p)(t)];return c().createElement(c().Fragment,null,n&&c().createElement(o.ExternalLink,{className:"jp-license-activation-screen-success-info--external-link",href:(0,r.A)(n.redirectSource,{site:a})},n.text))};d.propTypes={siteRawUrl:s().string,productId:s().number}},49051:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(90372),o=a(5932),n=a(86087),l=a(27723),s=a(28120),i=a.n(s),c=a(51609),u=a.n(c),d=a(59534),v=a(5986),p=a(23806),m=a(47129),h=a(96309),f=a(97139);const __=l.__,g=e=>{const{availableLicenses:t=[],currentRecommendationsStep:a,fetchingAvailableLicenses:l=!1,onActivationSuccess:s=()=>null,siteAdminUrl:i,siteRawUrl:g,startingLicense:w,displayName:b=""}=e,[y,x]=(0,c.useState)(w??""),[_,k]=(0,c.useState)(null),[E,C]=(0,c.useState)(!1),[j,A]=(0,c.useState)(null);(0,c.useEffect)((()=>{t&&t[0]&&x(t[0].license_key)}),[t]);const S=(0,c.useCallback)((()=>E?Promise.resolve():y.length<1?(k(__("This is not a valid license key. Please try again.","jetpack-my-jetpack")),Promise.resolve()):(k(null),C(!0),r.A.tracks.recordJetpackClick({target:"license_activation_button"}),o.Ay.attachLicenses([y]).then((e=>{const t=(e=>{let t=e;for(;Array.isArray(t)&&t.length>0;)t=t[0];if(t?.activatedProductId)return t.activatedProductId;if(t?.errors)for(const e in t.errors)if(t.errors[e].length>0)throw new Error(t.errors[e][0]);throw new Error(__("An unknown error occurred during license activation. Please try again.","jetpack-my-jetpack"))})(e);A(t),s(t),r.A.tracks.recordEvent("jetpack_wpa_license_activation_success")})).catch((e=>{r.A.tracks.recordEvent("jetpack_wpa_license_activation_error");"invalid_permission_manage_user_licenses"===e.response?.code?k((0,n.createInterpolateElement)(__("You either do not have permissions to perform this action or a user account needs to be connected. Click here to connect your user account or contact your administrator.","jetpack-my-jetpack"),{connectLink:u().createElement("a",{href:"admin.php?page=my-jetpack#/connection?returnTo=add-license"})})):k(e.message)})).finally((()=>{C(!1)})))),[E,y,s]);return null!==j&&y.startsWith("jetpack-golden-token")?u().createElement(m.A,{tokenRedeemed:!0,displayName:b}):null!==j?u().createElement("div",{className:"jp-license-activation-screen"},u().createElement(p.A,{siteRawUrl:g,productId:j,siteAdminUrl:i,currentRecommendationsStep:a}),u().createElement(v.A,{imageUrl:f,showSupportLink:!1})):u().createElement("div",{className:"jp-license-activation-screen"},u().createElement(d.A,{availableLicenses:t,activateLicense:S,fetchingAvailableLicenses:l,isActivating:E,license:y,licenseError:_,onLicenseChange:x,siteUrl:g}),u().createElement(v.A,{imageUrl:h,showSupportLink:!0}))};g.propTypes={availableLicenses:i().array,currentRecommendationsStep:i().string,fetchingAvailableLicenses:i().bool,onActivationSuccess:i().func,siteAdminUrl:i().string.isRequired,siteRawUrl:i().string.isRequired,startingLicense:i().string,displayName:i().string};const w=g},47129:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(78478),o=a(75918),n=a(28509),l=a(67142),s=a(51112),i=a(56427),c=a(27723),u=a(13022),d=a(28120),v=a.n(d),p=a(51609),m=a.n(p),h=a(45067);const __=c.__,_x=c._x,f=e=>{document.referrer.includes(window.location.host)?(e.preventDefault(),history.back()):(e.preventDefault(),window.location.href=window?.myJetpackInitialState?.myJetpackUrl)};function g({redeemClick:e,displayName:t,onModalClose:a=f,tokenRedeemed:d=!1}){const[v,g]=(0,p.useState)(!1),w=(0,p.useRef)(null);(0,p.useEffect)((()=>{setTimeout((()=>{w?.current?.play()}),500)}),[w]);const b=(0,r.Wy)("scan"),y=(0,r.Wy)("backup"),x=(0,p.useCallback)((t=>{e?.(t),g(!0),w.current.play()}),[w,e]),_=(0,p.useCallback)((()=>{v&&w.current.play()}),[v]),k=(0,u.A)(h.A.modal,{[h.A.animating]:v});return m().createElement("div",null,m().createElement(i.Modal,{className:k,onRequestClose:a,isDismissible:!1,__experimentalHideHeader:!0},m().createElement(o.A,{horizontalSpacing:3,horizontalGap:3},m().createElement(n.A,null,m().createElement(l.A,{className:h.A["jetpack-logo"]}),m().createElement("div",{className:h.A["video-wrap"],onClick:_,role:"presentation"},m().createElement("video",{ref:w,src:"https://videos.files.wordpress.com/oSlNIBQO/jetpack-golden-token.mp4",muted:"muted"})),m().createElement("div",{className:h.A["content-wrap"]},m().createElement("div",{className:h.A["content-wrap-text"]},t.length>0&&m().createElement("p",{className:h.A["hi-user"]},(0,c.sprintf)(/* Translators: %s is the user's display name. */ -__("Hey, %s","jetpack-my-jetpack"),t)),m().createElement("h2",{className:h.A.headline},__("You have been gifted a Jetpack Golden Token.","jetpack-my-jetpack")),m().createElement("p",null,d&&__("This unlocked a lifetime of Jetpack powers for your website. Your exclusive Jetpack Experience is already active.","jetpack-my-jetpack"),!d&&__("This unlocks a lifetime of Jetpack powers for your website. Your exclusive Jetpack Experience awaits.","jetpack-my-jetpack"))),m().createElement(s.A,{variant:"primary",weight:"regular",onClick:x,className:h.A.button},d&&__("Awesome!","jetpack-my-jetpack"),!d&&__("Redeem your token","jetpack-my-jetpack"))),m().createElement("div",{className:`${h.A["powers-wrap"]} ${h.A["content-wrap"]}`},m().createElement("div",{className:h.A["content-wrap-text"]},m().createElement("h2",{className:h.A.headline},__("Super powers are ready!","jetpack-my-jetpack")),m().createElement("p",{className:h.A.paragraph},__("Your Jetpack Golden Token provides a lifetime license for this website and includes the following products:","jetpack-my-jetpack"))),m().createElement("div",{className:h.A["jetpack-products"]},m().createElement("div",null,m().createElement(y,null),m().createElement("h3",null,__("VaultPress Backup","jetpack-my-jetpack")),m().createElement("p",null,__("Save every change and get back online quickly with one‑click restores.","jetpack-my-jetpack"))),m().createElement("div",null,m().createElement(b,null),m().createElement("h3",null,_x("Scan","Plugin name (noun).","jetpack-my-jetpack")),m().createElement("p",null,__("Automated scanning and one‑click fixes to keep your site ahead of security threats.","jetpack-my-jetpack")))),m().createElement(s.A,{variant:"primary",weight:"regular",onClick:x,href:window?.myJetpackInitialState?.myJetpackUrl,className:h.A.button},__("Explore your new powers","jetpack-my-jetpack")))))))}g.propTypes={redeemClick:v().func,tokenRedeemed:v().bool,displayName:v().string,onModalClose:v().func};const w=g},41040:(e,t,a)=>{"use strict";a.d(t,{_:()=>o.A,b:()=>r.A});var r=a(49051),o=a(47129)},85985:(e,t,a)=>{"use strict";a.d(t,{pg:()=>r.A});a(52810),a(54815);var r=a(41409);a(82034),a(65595),a(53265),a(73489),a(47119),a(58406),a(76923),a(30335),a(88290),a(9061),a(25929),a(5765)},5765:(e,t,a)=>{"use strict";a(98490)},52810:(e,t,a)=>{"use strict";a(38377).T["Jetpack Green 40"]},30335:(e,t,a)=>{"use strict";a(86087)},54815:(e,t,a)=>{"use strict";a(97999)},73489:(e,t,a)=>{"use strict";var r=a(90372);a(39384),a(86087);const{tracks:o}=r.A,{recordEvent:n}=o},47119:(e,t,a)=>{"use strict";a(47143),a(86087),a(66087)},76923:(e,t,a)=>{"use strict";a(47143),a(86087),a(88290)},58406:(e,t,a)=>{"use strict";a(86087)},25929:(e,t,a)=>{"use strict";a(47143),a(52619),a(53265),a(47119)},9520:(e,t,a)=>{"use strict";var r=a(46941),o=a.n(r);window,o()("shared-extension-utils:connection")},9061:(e,t,a)=>{"use strict";a(9520)},27105:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>d,E9:()=>u});var r=a(47143),o=a(62634),n=a(94478),l=a(88290);const s="SET_JETPACK_MODULES";function i(e){return u({isLoading:e})}function c(e,t){return{type:"SET_MODULE_UPDATING",name:e,isUpdating:t}}function u(e){return{type:s,options:e}}const d={updateJetpackModuleStatus:function*(e){try{yield c(e.name,!0),yield(0,n.sB)(e);const t=yield(0,n.wz)();return yield u({data:t}),!0}catch{const e=(0,r.select)(l.F).getJetpackModules();return yield u(e),!1}finally{yield c(e.name,!1)}},setJetpackModules:u,fetchModules:function*(){if((0,o.Sy)())return!0;try{yield i(!0);const e=yield(0,n.wz)();return yield u({data:e}),!0}catch{const e=(0,r.select)(l.F).getJetpackModules();return yield u(e),!1}finally{yield i(!1)}}}},94478:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>c,sB:()=>i,wz:()=>s});var r=a(1455),o=a.n(r);const n="FETCH_JETPACK_MODULES",l="UPDATE_JETPACK_MODULE_STATUS",s=()=>({type:n}),i=e=>({type:l,settings:e}),c={[n]:function(){return o()({path:"/jetpack/v4/module/all",method:"GET"})},[l]:function({settings:e}){return o()({path:`/jetpack/v4/module/${e.name}/active`,method:"POST",data:{active:e.active}})}}},88290:(e,t,a)=>{"use strict";a.d(t,{F:()=>c});var r=a(47143),o=a(27105),n=a(94478),l=a(38862),s=a(62701),i=a(31640);const c="jetpack-modules",u=(0,r.createReduxStore)(c,{reducer:l.A,actions:o.Ay,controls:n.Ay,resolvers:s.A,selectors:i.A});(0,r.register)(u);const d=window?.Initial_State?.getModules||window?.Jetpack_Editor_Initial_State?.modules||null;null!==d&&(0,r.dispatch)(c).setJetpackModules({data:{...d}})},38862:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});const r={isLoading:!1,isUpdating:{},data:{}},o=(e=r,t)=>{switch(t.type){case"SET_JETPACK_MODULES":return{...e,...t.options};case"SET_MODULE_UPDATING":return{...e,isUpdating:{...e.isUpdating,[t.name]:t.isUpdating}}}return e}},62701:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(27105),o=a(94478);const n={getJetpackModules:function*(){try{const e=yield(0,o.wz)();if(e)return(0,r.E9)({data:e})}catch(e){console.error(e)}}}},31640:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(62634);const o={getJetpackModules:e=>e.data,isModuleActive:(e,t)=>(0,r.Sy)()||(e?.data?.[t]?.activated??!1),areModulesLoading:e=>e.isLoading??!1,isModuleUpdating:(e,t)=>e?.isUpdating?.[t]??!1}},53265:(e,t,a)=>{"use strict";var r=a(27723);a(93832),a(66087),a(54815);const __=r.__;__("Upgrade your plan to use video covers","jetpack-my-jetpack"),__("Upgrade your plan to upload audio","jetpack-my-jetpack")},82034:(e,t,a)=>{"use strict";a(92279)},41409:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(97999);function o(){const{connectedPlugins:e,connectionStatus:t}=(0,r.getScriptData)()?.connection??{};return t?.isActive&&e?.some((({slug:e})=>"jetpack"===e))}},62634:(e,t,a)=>{"use strict";function r(){return"object"==typeof window&&"string"==typeof window._currentSiteType?window._currentSiteType:null}function o(){return"simple"===r()}a.d(t,{Sy:()=>o})},65595:(e,t,a)=>{"use strict";a(96072),a(29491)},84705:(e,t,a)=>{"use strict";a(58992),a(91135)},91135:(e,t,a)=>{"use strict";a.d(t,{$:()=>r});const r=[{name:"amazon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M13.582 8.182c-1.648.185-3.802.308-5.344.984-1.781.769-3.03 2.337-3.03 4.644 0 2.953 1.86 4.429 4.253 4.429 2.02 0 3.125-.477 4.685-2.065.516.747.685 1.109 1.629 1.894a.59.59 0 0 0 .672-.066l.006.006c.567-.505 1.599-1.401 2.18-1.888.231-.188.19-.496.009-.754-.52-.718-1.072-1.303-1.072-2.634V8.305c0-1.876.133-3.599-1.249-4.891C15.23 2.369 13.422 2 12.04 2 9.336 2 6.318 3.01 5.686 6.351c-.068.355.191.542.423.594l2.754.298c.258-.013.445-.266.494-.523.236-1.151 1.2-1.706 2.284-1.706.584 0 1.249.215 1.595.738.398.584.346 1.384.346 2.061zm-.533 5.906c-.451.8-1.169 1.291-1.967 1.291-1.09 0-1.728-.83-1.728-2.061 0-2.42 2.171-2.86 4.227-2.86v.615c.001 1.108.027 2.031-.532 3.015m7.634 5.251C18.329 21.076 14.917 22 11.979 22c-4.118 0-7.826-1.522-10.632-4.057-.22-.199-.024-.471.241-.317 3.027 1.762 6.771 2.823 10.639 2.823 2.608 0 5.476-.541 8.115-1.66.397-.169.73.262.341.55m.653 1.704c-.194.163-.379.076-.293-.139.284-.71.92-2.298.619-2.684s-1.99-.183-2.749-.092c-.23.027-.266-.173-.059-.319 1.348-.946 3.555-.673 3.811-.356.26.32-.066 2.533-1.329 3.59"})))},{name:"behance",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M7.799 5.698c.589 0 1.12.051 1.606.156q.722.155 1.241.507.516.351.804.938c.188.387.281.871.281 1.443q0 .93-.421 1.551-.424.62-1.255 1.014 1.133.328 1.689 1.146.559.822.557 1.975 0 .935-.359 1.612a3.14 3.14 0 0 1-.973 1.114q-.613.432-1.399.637A6.1 6.1 0 0 1 7.963 18H2V5.698zm-.35 4.97q.721 0 1.192-.345.465-.344.463-1.119 0-.43-.152-.707a1.1 1.1 0 0 0-.416-.427 1.7 1.7 0 0 0-.596-.216 3.6 3.6 0 0 0-.697-.06H4.709v2.874zm.151 5.237q.401.001.759-.077c.243-.053.457-.137.637-.261.182-.12.332-.283.441-.491q.164-.31.163-.798-.002-.948-.533-1.357c-.356-.27-.83-.404-1.413-.404H4.709v3.388zm8.562-.041q.552.538 1.583.538.74 0 1.277-.374c.354-.248.571-.514.654-.79h2.155c-.347 1.072-.872 1.838-1.589 2.299-.708.463-1.572.693-2.58.693q-1.05 0-1.899-.337a4 4 0 0 1-1.439-.958 4.4 4.4 0 0 1-.904-1.484 5.4 5.4 0 0 1-.32-1.899q0-1 .329-1.863a4.4 4.4 0 0 1 .933-1.492q.607-.63 1.444-.994a4.6 4.6 0 0 1 1.857-.363q1.131-.001 1.98.44a3.94 3.94 0 0 1 1.389 1.181 4.8 4.8 0 0 1 .783 1.69q.24.947.171 1.983h-6.428c-.001.706.237 1.372.604 1.73m2.811-4.68c-.291-.321-.783-.496-1.384-.496q-.585 0-.973.2a2 2 0 0 0-.621.491 1.8 1.8 0 0 0-.328.628 2.7 2.7 0 0 0-.111.587h3.98c-.058-.625-.271-1.085-.563-1.41m-3.916-3.446h4.985V6.524h-4.985z"})))},{name:"blogger-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.779 9.904h-.981l-.021.001a1.163 1.163 0 0 1-1.16-1.079l-.001-.013A5.813 5.813 0 0 0 11.803 3H8.871a5.813 5.813 0 0 0-5.813 5.813v6.375a5.813 5.813 0 0 0 5.813 5.813h6.257a5.814 5.814 0 0 0 5.813-5.813l.002-4.121a1.164 1.164 0 0 0-1.164-1.163M8.726 7.713h3.291a1.117 1.117 0 1 1 0 2.234H8.726a1.117 1.117 0 1 1 0-2.234m6.601 8.657H8.72a1.057 1.057 0 1 1 0-2.114h6.607a1.057 1.057 0 1 1 0 2.114"})))},{name:"blogger",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M14.722 14.019a.654.654 0 0 1-.654.654H9.977a.654.654 0 0 1 0-1.308h4.091c.361 0 .654.293.654.654m-4.741-3.321h2.038a.692.692 0 0 0 0-1.384H9.981a.692.692 0 0 0 0 1.384M21 5v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2m-3.456 6.39a.72.72 0 0 0-.72-.72h-.607l-.013.001a.72.72 0 0 1-.718-.668l-.001-.008a3.6 3.6 0 0 0-3.599-3.599H10.07a3.6 3.6 0 0 0-3.599 3.599v3.947a3.6 3.6 0 0 0 3.599 3.599h3.874a3.6 3.6 0 0 0 3.599-3.599z"})))},{name:"bluesky",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.2 3.3c-.5-.2-1.4-.5-3.6 1C15.4 6 12.9 9.2 12 11c-.9-1.8-3.4-5-5.7-6.7-2.2-1.6-3-1.3-3.6-1S2 4.6 2 5.1s.3 4.7.5 5.4c.7 2.3 3.1 3.1 5.3 2.8-3.3.5-6.2 1.7-2.4 5.9 4.2 4.3 5.7-.9 6.5-3.6.8 2.7 1.7 7.7 6.4 3.6 3.6-3.6 1-5.4-2.3-5.9 2.2.2 4.6-.5 5.3-2.8.4-.7.7-4.8.7-5.4 0-.5-.1-1.5-.8-1.8"})))},{name:"codepen",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m22.016 8.84-.007-.037q-.006-.037-.015-.072-.007-.022-.013-.042l-.023-.062-.02-.042a.4.4 0 0 0-.03-.057l-.025-.038-.035-.052-.03-.037q-.021-.026-.043-.045-.015-.018-.035-.035a.4.4 0 0 0-.048-.04l-.037-.03-.015-.012-9.161-6.096a.86.86 0 0 0-.955 0L2.359 8.237l-.015.012-.038.028-.048.04a.638.638 0 0 0-.078.082q-.018.018-.03.037-.018.026-.035.052l-.025.038q-.016.031-.03.059l-.02.041a1 1 0 0 0-.034.106q-.01.034-.016.071-.003.02-.006.037a1 1 0 0 0-.009.114v6.093q0 .056.008.112l.007.038q.006.035.015.072a.2.2 0 0 0 .013.04q.01.032.022.063l.02.04a.4.4 0 0 0 .055.096l.035.052.03.037.042.045.035.035q.023.02.048.04l.038.03.013.01 9.163 6.095a.858.858 0 0 0 .959.004l9.163-6.095.015-.01q.02-.015.037-.03l.048-.04q.02-.017.035-.035.025-.024.043-.045l.03-.037.035-.052.025-.038a.4.4 0 0 0 .03-.058l.02-.04.023-.063c.003-.013.01-.027.013-.04q.009-.037.015-.072l.007-.037q.006-.062.007-.117V8.954a1 1 0 0 0-.008-.114m-9.154-4.376 6.751 4.49-3.016 2.013-3.735-2.492zm-1.724 0v4.009l-3.735 2.494-3.014-2.013zm-7.439 6.098L5.853 12l-2.155 1.438zm7.439 8.974-6.749-4.491 3.015-2.011 3.735 2.492zM12 14.035 8.953 12 12 9.966 15.047 12zm.862 5.501v-4.009l3.735-2.492 3.016 2.011zm7.441-6.098L18.147 12l2.156-1.438z"})))},{name:"deezer",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20.129 3.662c.222-1.287.548-2.096.909-2.098h.001c.673.002 1.219 2.809 1.219 6.274s-.546 6.274-1.22 6.274c-.276 0-.531-.477-.736-1.276-.324 2.926-.997 4.937-1.776 4.937-.603 0-1.144-1.208-1.507-3.114-.248 3.624-.872 6.195-1.602 6.195-.458 0-.875-1.019-1.184-2.678C13.861 21.6 13.003 24 12.002 24s-1.861-2.399-2.231-5.824c-.307 1.659-.724 2.678-1.184 2.678-.73 0-1.352-2.571-1.602-6.195-.363 1.905-.903 3.114-1.507 3.114-.778 0-1.452-2.011-1.776-4.937-.204.802-.46 1.276-.736 1.276-.674 0-1.22-2.809-1.22-6.274s.546-6.274 1.22-6.274c.362 0 .685.812.91 2.098.357-2.22.94-3.662 1.6-3.662.784 0 1.463 2.04 1.784 5.002.314-2.156.791-3.53 1.325-3.53.749 0 1.385 2.703 1.621 6.474.443-1.933 1.085-3.146 1.795-3.146s1.352 1.214 1.795 3.146c.237-3.771.872-6.474 1.621-6.474.533 0 1.009 1.374 1.325 3.53.321-2.962 1-5.002 1.784-5.002.658 0 1.244 1.443 1.603 3.662M0 7.221c0-1.549.31-2.805.692-2.805s.692 1.256.692 2.805-.31 2.805-.692 2.805S0 8.77 0 7.221m22.616 0c0-1.549.31-2.805.692-2.805S24 5.672 24 7.221s-.31 2.805-.692 2.805-.692-1.256-.692-2.805"})))},{name:"discord",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20.33 4.523A20 20 0 0 0 15.379 3a14 14 0 0 0-.634 1.289 18.4 18.4 0 0 0-5.495 0A14 14 0 0 0 8.615 3 20 20 0 0 0 3.66 4.527C.527 9.163-.323 13.684.102 18.141a20 20 0 0 0 6.073 3.049 14.7 14.7 0 0 0 1.301-2.097 13 13 0 0 1-2.048-.978q.258-.189.502-.378a14.27 14.27 0 0 0 12.142 0q.247.202.502.378a13 13 0 0 1-2.052.98 14.5 14.5 0 0 0 1.301 2.095 19.9 19.9 0 0 0 6.076-3.047c.498-5.168-.851-9.648-3.568-13.62M8.013 15.4c-1.183 0-2.161-1.074-2.161-2.395S6.796 10.6 8.01 10.6s2.183 1.083 2.163 2.405S9.22 15.4 8.013 15.4m7.974 0c-1.186 0-2.16-1.074-2.16-2.395s.944-2.405 2.16-2.405 2.178 1.083 2.157 2.405-.951 2.395-2.158 2.395"})))},{name:"dribbble",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10m8.434-8.631c-.292-.092-2.644-.794-5.32-.365 1.117 3.07 1.572 5.57 1.659 6.09a8.56 8.56 0 0 0 3.661-5.725m-5.098 6.507c-.127-.749-.623-3.361-1.822-6.477l-.056.019c-4.818 1.679-6.547 5.02-6.701 5.334A8.5 8.5 0 0 0 12 20.555a8.5 8.5 0 0 0 3.336-.679m-9.682-2.152c.193-.331 2.538-4.213 6.943-5.637q.167-.054.337-.102a29 29 0 0 0-.692-1.45c-4.266 1.277-8.405 1.223-8.778 1.216a8.497 8.497 0 0 0 2.19 5.973m-2.015-7.46c.382.005 3.901.02 7.897-1.041a55 55 0 0 0-3.167-4.94 8.57 8.57 0 0 0-4.73 5.981m6.359-6.555a46 46 0 0 1 3.187 5c3.037-1.138 4.323-2.867 4.477-3.085a8.51 8.51 0 0 0-7.664-1.915m8.614 2.903c-.18.243-1.612 2.078-4.77 3.367a27 27 0 0 1 .751 1.678c2.842-.357 5.666.215 5.948.275a8.5 8.5 0 0 0-1.929-5.32"})))},{name:"dropbox",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 6.134 6.069 9.797 2 6.54l5.883-3.843zm-10 6.92 5.883 3.843L12 13.459 6.069 9.797zm10 .405 4.116 3.439L22 13.054l-4.069-3.257zM22 6.54l-5.884-3.843L12 6.134l5.931 3.663zm-9.989 7.66-4.129 3.426-1.767-1.153v1.291l5.896 3.539 5.897-3.539v-1.291l-1.769 1.153z"})))},{name:"eventbrite",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M18.041 3.931 5.959 3A2.96 2.96 0 0 0 3 5.959v12.083A2.96 2.96 0 0 0 5.959 21l12.083-.931C19.699 19.983 21 18.744 21 17.11V6.89c0-1.634-1.259-2.863-2.959-2.959M16.933 8.17c-.082.215-.192.432-.378.551-.188.122-.489.132-.799.132-1.521 0-3.062-.048-4.607-.048q-.23 1.061-.451 2.128c.932-.004 1.873.005 2.81.005.726 0 1.462-.069 1.586.525.04.189-.001.426-.052.615-.105.38-.258.676-.625.783-.185.054-.408.058-.646.058-1.145 0-2.345.017-3.493.02-.169.772-.328 1.553-.489 2.333 1.57-.005 3.067-.041 4.633-.058.627-.007 1.085.194 1.009.85a2.2 2.2 0 0 1-.211.725c-.102.208-.248.376-.488.452-.237.075-.541.064-.862.078-.304.014-.614.008-.924.016-.309.009-.619.022-.919.022-1.253 0-2.429.08-3.683.073-.603-.004-1.014-.249-1.124-.757-.059-.273-.018-.58.036-.841a3543 3543 0 0 1 1.629-7.763c.056-.265.114-.511.225-.714a1.24 1.24 0 0 1 .79-.62c.368-.099.883-.047 1.344-.047.305 0 .612.008.914.016.925.026 1.817.03 2.747.053.304.007.615.016.915.016.621 0 1.17.073 1.245.614.039.288-.051.567-.132.783"})))},{name:"facebook",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.5 2 2 6.5 2 12c0 5 3.7 9.1 8.4 9.9v-7H7.9V12h2.5V9.8c0-2.5 1.5-3.9 3.8-3.9 1.1 0 2.2.2 2.2.2v2.5h-1.3c-1.2 0-1.6.8-1.6 1.6V12h2.8l-.4 2.9h-2.3v7C18.3 21.1 22 17 22 12c0-5.5-4.5-10-10-10"})))},{name:"fediverse",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 743 743"},React.createElement("g",null,React.createElement("path",{d:"M181.131 275.137a68.9 68.9 0 0 1-29.465 29.328l161.758 162.389 38.998-19.764zm213.363 214.187-38.998 19.764 81.963 82.283a68.9 68.9 0 0 1 29.471-29.332zM581.646 339.391l-91.576 46.41 6.752 43.189 103.616-52.513a68.9 68.9 0 0 1-18.792-37.086m-144.738 73.351L220.383 522.477a68.9 68.9 0 0 1 18.795 37.089L443.66 455.934zM367.275 142.438l-104.48 203.97 30.848 30.967 110.623-215.957a68.9 68.9 0 0 1-36.991-18.98M235.621 399.459l-52.922 103.314a68.9 68.9 0 0 1 36.987 18.979l46.781-91.328zM150.768 304.918a68.9 68.9 0 0 1-34.416 7.195 69 69 0 0 1-6.651-.695l30.903 197.662a68.9 68.9 0 0 1 34.416-7.195 69 69 0 0 1 6.646.695zM239.342 560.545c.707 4.589.949 9.239.72 13.877a68.9 68.9 0 0 1-7.267 27.18l197.629 31.712c-.708-4.59-.95-9.24-.723-13.878a68.9 68.9 0 0 1 7.27-27.178zM601.133 377.199l-91.219 178.082a68.9 68.9 0 0 1 36.994 18.983l91.217-178.08a68.9 68.9 0 0 1-36.992-18.985M476.723 125.33a68.9 68.9 0 0 1-29.471 29.332l141.266 141.811a68.9 68.9 0 0 1 29.468-29.332zM347.787 104.631l-178.576 90.498a68.9 68.9 0 0 1 18.793 37.086l178.574-90.502a68.9 68.9 0 0 1-18.791-37.082M446.926 154.826a68.9 68.9 0 0 1-34.983 7.483 69 69 0 0 1-6.029-.633l15.818 101.291 43.163 6.926zm-16 167.028 37.4 239.482a68.9 68.9 0 0 1 33.914-6.943q3.625.206 7.207.791L474.09 328.777zM188.131 232.975c.734 4.66.988 9.383.758 14.095a68.9 68.9 0 0 1-7.16 26.983l101.369 16.281 19.923-38.908zm173.736 27.9-19.926 38.912 239.514 38.467a69 69 0 0 1-.695-13.719 68.9 68.9 0 0 1 7.349-27.324z"}),React.createElement("path",{fillOpacity:".996",d:"M412.284 156.054c34.538 1.882 64.061-24.592 65.943-59.13s-24.592-64.062-59.131-65.943c-34.538-1.882-64.061 24.592-65.943 59.13s24.593 64.062 59.131 65.943M646.144 390.82c34.538 1.881 64.062-24.593 65.943-59.131s-24.592-64.061-59.13-65.943-64.062 24.593-65.943 59.131 24.592 64.061 59.13 65.943M495.086 685.719c34.538 1.881 64.062-24.592 65.943-59.13s-24.592-64.062-59.13-65.943-64.062 24.592-65.943 59.13 24.592 64.062 59.13 65.943M167.866 633.211c34.538 1.882 64.062-24.592 65.943-59.13s-24.592-64.062-59.13-65.943-64.062 24.592-65.943 59.13 24.592 64.062 59.13 65.943M116.692 305.86c34.538 1.882 64.062-24.592 65.943-59.13s-24.592-64.062-59.131-65.943c-34.538-1.881-64.061 24.592-65.943 59.13s24.593 64.062 59.131 65.943"})))},{name:"feed",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M2 8.667V12c5.515 0 10 4.485 10 10h3.333c0-7.363-5.97-13.333-13.333-13.333M2 2v3.333c9.19 0 16.667 7.477 16.667 16.667H22C22 10.955 13.045 2 2 2m2.5 15a2.5 2.5 0 1 0 0 5 2.5 2.5 0 0 0 0-5"})))},{name:"flickr",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M6.5 7c-2.75 0-5 2.25-5 5s2.25 5 5 5 5-2.25 5-5-2.25-5-5-5m11 0c-2.75 0-5 2.25-5 5s2.25 5 5 5 5-2.25 5-5-2.25-5-5-5"})))},{name:"foursquare",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M17.573 2H6.905C5.434 2 5 3.107 5 3.805v16.948c0 .785.422 1.077.66 1.172.238.097.892.177 1.285-.275 0 0 5.035-5.843 5.122-5.93.132-.132.132-.132.262-.132h3.26c1.368 0 1.588-.977 1.732-1.552.078-.318.692-3.428 1.225-6.122l.675-3.368C19.56 2.893 19.14 2 17.573 2m-1.078 5.22c-.053.252-.372.518-.665.518h-4.157c-.467 0-.802.318-.802.787v.508c0 .467.337.798.805.798h3.528c.331 0 .655.362.583.715s-.407 2.102-.448 2.295c-.04.193-.262.523-.655.523h-2.88c-.523 0-.683.068-1.033.503-.35.437-3.505 4.223-3.505 4.223-.032.035-.063.027-.063-.015V4.852c0-.298.26-.648.648-.648h8.562c.315 0 .61.297.528.683z"})))},{name:"ghost",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M10.203 20.997H3.005v-3.599h7.198zm10.792-3.599h-7.193v3.599h7.193zm.003-7.198H3v3.599h17.998zm-7.195-7.197H3.005v3.599h10.798zm7.197 0h-3.599v3.599H21z"})))},{name:"git",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M23.519 10.947 13.053.482a1.543 1.543 0 0 0-2.183 0L8.696 2.656l2.756 2.756a1.83 1.83 0 0 1 1.886.439 1.84 1.84 0 0 1 .436 1.898l2.656 2.657a1.83 1.83 0 0 1 1.899.436 1.837 1.837 0 0 1 0 2.597 1.84 1.84 0 0 1-2.599 0 1.84 1.84 0 0 1-.4-1.998l-2.478-2.477v6.521a1.837 1.837 0 0 1 .485 2.945 1.837 1.837 0 0 1-2.597 0 1.837 1.837 0 0 1 0-2.598 1.8 1.8 0 0 1 .602-.401V8.85a1.8 1.8 0 0 1-.602-.4 1.84 1.84 0 0 1-.395-2.009L7.628 3.723.452 10.898a1.544 1.544 0 0 0 0 2.184l10.467 10.467a1.544 1.544 0 0 0 2.183 0l10.417-10.418a1.546 1.546 0 0 0 0-2.184"})))},{name:"github",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12c0 4.419 2.865 8.166 6.839 9.489.5.09.682-.218.682-.484 0-.236-.009-.866-.014-1.699-2.782.602-3.369-1.34-3.369-1.34-.455-1.157-1.11-1.465-1.11-1.465-.909-.62.069-.608.069-.608 1.004.071 1.532 1.03 1.532 1.03.891 1.529 2.341 1.089 2.91.833.091-.647.349-1.086.635-1.337-2.22-.251-4.555-1.111-4.555-4.943 0-1.091.39-1.984 1.03-2.682-.103-.254-.447-1.27.097-2.646 0 0 .84-.269 2.75 1.025A9.6 9.6 0 0 1 12 6.836c.85.004 1.705.114 2.504.336 1.909-1.294 2.748-1.025 2.748-1.025.546 1.376.202 2.394.1 2.646.64.699 1.026 1.591 1.026 2.682 0 3.841-2.337 4.687-4.565 4.935.359.307.679.917.679 1.852 0 1.335-.012 2.415-.012 2.741 0 .269.18.579.688.481A10 10 0 0 0 22 12c0-5.523-4.477-10-10-10"})))},{name:"google-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m-.05 16c-3.312 0-6-2.688-6-6s2.688-6 6-6c1.62 0 2.976.594 4.014 1.566L14.26 9.222c-.432-.408-1.188-.888-2.31-.888-1.986 0-3.606 1.65-3.606 3.672s1.62 3.672 3.606 3.672c2.298 0 3.144-1.59 3.3-2.532h-3.306v-2.238h5.616c.084.378.15.732.15 1.23 0 3.426-2.298 5.862-5.76 5.862"})))},{name:"google-plus-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M8 11h6.61c.06.35.11.7.11 1.16 0 4-2.68 6.84-6.72 6.84-3.87 0-7-3.13-7-7s3.13-7 7-7c1.89 0 3.47.69 4.69 1.83l-1.9 1.83c-.52-.5-1.43-1.08-2.79-1.08-2.39 0-4.34 1.98-4.34 4.42S5.61 16.42 8 16.42c2.77 0 3.81-1.99 3.97-3.02H8zm15 0h-2V9h-2v2h-2v2h2v2h2v-2h2"})))},{name:"google-plus",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m-1.919 14.05a4.051 4.051 0 0 1 0-8.1c1.094 0 2.009.401 2.709 1.057l-1.15 1.118a2.23 2.23 0 0 0-1.559-.599c-1.341 0-2.434 1.114-2.434 2.479s1.094 2.479 2.434 2.479c1.551 0 2.122-1.073 2.227-1.709h-2.232v-1.511h3.791c.057.255.101.494.101.83.001 2.312-1.55 3.956-3.887 3.956M19 12.75h-1.25V14h-1.5v-1.25H15v-1.5h1.25V10h1.5v1.25H19z"})))},{name:"google",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.02 10.18v3.73h5.51c-.26 1.57-1.67 4.22-5.5 4.22-3.31 0-6.01-2.75-6.01-6.12s2.7-6.12 6.01-6.12c1.87 0 3.13.8 3.85 1.48l2.84-2.76C16.99 2.99 14.73 2 12.03 2c-5.52 0-10 4.48-10 10s4.48 10 10 10c5.77 0 9.6-4.06 9.6-9.77 0-.83-.11-1.42-.25-2.05z"})))},{name:"instagram",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 4.622c2.403 0 2.688.009 3.637.052.877.04 1.354.187 1.671.31.42.163.72.358 1.035.673s.51.615.673 1.035c.123.317.27.794.31 1.671.043.949.052 1.234.052 3.637s-.009 2.688-.052 3.637c-.04.877-.187 1.354-.31 1.671-.163.42-.358.72-.673 1.035s-.615.51-1.035.673c-.317.123-.794.27-1.671.31-.949.043-1.233.052-3.637.052s-2.688-.009-3.637-.052c-.877-.04-1.354-.187-1.671-.31a2.8 2.8 0 0 1-1.035-.673 2.8 2.8 0 0 1-.673-1.035c-.123-.317-.27-.794-.31-1.671-.043-.949-.052-1.234-.052-3.637s.009-2.688.052-3.637c.04-.877.187-1.354.31-1.671.163-.42.358-.72.673-1.035s.615-.51 1.035-.673c.317-.123.794-.27 1.671-.31.949-.043 1.234-.052 3.637-.052M12 3c-2.444 0-2.751.01-3.711.054-.958.044-1.612.196-2.184.418a4.4 4.4 0 0 0-1.594 1.039c-.5.5-.808 1.002-1.038 1.594-.223.572-.375 1.226-.419 2.184C3.01 9.249 3 9.556 3 12s.01 2.751.054 3.711c.044.958.196 1.612.418 2.185.23.592.538 1.094 1.038 1.594s1.002.808 1.594 1.038c.572.222 1.227.375 2.185.418.96.044 1.267.054 3.711.054s2.751-.01 3.711-.054c.958-.044 1.612-.196 2.185-.418a4.4 4.4 0 0 0 1.594-1.038c.5-.5.808-1.002 1.038-1.594.222-.572.375-1.227.418-2.185.044-.96.054-1.267.054-3.711s-.01-2.751-.054-3.711c-.044-.958-.196-1.612-.418-2.185A4.4 4.4 0 0 0 19.49 4.51c-.5-.5-1.002-.808-1.594-1.038-.572-.222-1.227-.375-2.185-.418C14.751 3.01 14.444 3 12 3m0 4.378a4.622 4.622 0 1 0 0 9.244 4.622 4.622 0 0 0 0-9.244M12 15a3 3 0 1 1 0-6 3 3 0 0 1 0 6m4.804-8.884a1.08 1.08 0 1 0 .001 2.161 1.08 1.08 0 0 0-.001-2.161"})))},{name:"json-feed",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m8.522 17.424.027.027c1.076-1.076 1.854-.993 3.154.306l2.053 2.053c2.136 2.136 4.131 2.028 6.515-.356l.729-.728-1.548-1.548-.373.373c-1.349 1.349-2.293 1.366-3.585.075l-2.409-2.409c-1.242-1.242-2.475-1.366-3.659-.381l-.232-.232c1.01-1.225.911-2.368-.29-3.568l-2.16-2.162c-1.317-1.317-1.308-2.236.058-3.602l.372-.372-1.54-1.54-.728.729c-2.393 2.393-2.525 4.346-.439 6.433l1.78 1.78c1.3 1.3 1.383 2.095.315 3.163l.008.008a1.384 1.384 0 0 0 1.952 1.951"}),React.createElement("circle",{cx:"13.089",cy:"10.905",r:"1.383"}),React.createElement("circle",{cx:"16.349",cy:"7.644",r:"1.383"}),React.createElement("circle",{cx:"19.61",cy:"4.383",r:"1.383"})))},{name:"line",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M14.255 9.572v3.333c0 .084-.066.15-.15.15h-.534a.16.16 0 0 1-.122-.061l-1.528-2.063v1.978c0 .084-.066.15-.15.15h-.534a.15.15 0 0 1-.15-.15V9.576c0-.084.066-.15.15-.15h.529a.14.14 0 0 1 .122.066l1.528 2.063V9.577c0-.084.066-.15.15-.15h.534a.15.15 0 0 1 .155.145m-3.844-.15h-.534a.15.15 0 0 0-.15.15v3.333c0 .084.066.15.15.15h.534c.084 0 .15-.066.15-.15V9.572c0-.08-.066-.15-.15-.15m-1.289 2.794H7.664V9.572a.15.15 0 0 0-.15-.15H6.98a.15.15 0 0 0-.15.15v3.333q0 .062.042.103a.16.16 0 0 0 .103.042h2.142c.084 0 .15-.066.15-.15v-.534a.15.15 0 0 0-.145-.15m7.945-2.794h-2.142c-.08 0-.15.066-.15.15v3.333c0 .08.066.15.15.15h2.142c.084 0 .15-.066.15-.15v-.534a.15.15 0 0 0-.15-.15h-1.458v-.563h1.458c.084 0 .15-.066.15-.15v-.539a.15.15 0 0 0-.15-.15h-1.458v-.563h1.458c.084 0 .15-.066.15-.15v-.534c-.005-.08-.07-.15-.15-.15M22.5 5.33v13.373c-.005 2.1-1.725 3.802-3.83 3.797H5.297c-2.1-.005-3.802-1.73-3.797-3.83V5.297c.005-2.1 1.73-3.802 3.83-3.797h13.373c2.1.005 3.802 1.725 3.797 3.83m-2.888 5.747c0-3.422-3.431-6.206-7.645-6.206s-7.645 2.784-7.645 6.206c0 3.066 2.719 5.634 6.394 6.122.895.192.792.52.591 1.725-.033.192-.155.755.661.413s4.402-2.592 6.009-4.439c1.106-1.219 1.636-2.452 1.636-3.82"})))},{name:"link",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M17 13H7v-2h10zm1-6h-1c-1.631 0-3.065.792-3.977 2H18c1.103 0 2 .897 2 2v2c0 1.103-.897 2-2 2h-4.977c.913 1.208 2.347 2 3.977 2h1a4 4 0 0 0 4-4v-2a4 4 0 0 0-4-4M2 11v2a4 4 0 0 0 4 4h1c1.63 0 3.065-.792 3.977-2H6c-1.103 0-2-.897-2-2v-2c0-1.103.897-2 2-2h4.977C10.065 7.792 8.631 7 7 7H6a4 4 0 0 0-4 4"})))},{name:"linkedin",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.7 3H4.3A1.3 1.3 0 0 0 3 4.3v15.4A1.3 1.3 0 0 0 4.3 21h15.4a1.3 1.3 0 0 0 1.3-1.3V4.3A1.3 1.3 0 0 0 19.7 3M8.339 18.338H5.667v-8.59h2.672zM7.004 8.574a1.548 1.548 0 1 1-.002-3.096 1.548 1.548 0 0 1 .002 3.096m11.335 9.764H15.67v-4.177c0-.996-.017-2.278-1.387-2.278-1.389 0-1.601 1.086-1.601 2.206v4.249h-2.667v-8.59h2.559v1.174h.037c.356-.675 1.227-1.387 2.526-1.387 2.703 0 3.203 1.779 3.203 4.092v4.711z"})))},{name:"mail",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20 4H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V6a2 2 0 0 0-2-2m0 4.236-8 4.882-8-4.882V6h16z"})))},{name:"mastodon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M11.973 2.352c-2.468.02-4.842.286-6.225.921 0 0-2.742 1.229-2.742 5.415 0 .958-.018 2.105.012 3.32.1 4.094.75 8.128 4.535 9.129 1.745.462 3.244.56 4.45.494 2.19-.122 3.417-.781 3.417-.781l-.072-1.588s-1.565.491-3.32.431c-1.74-.06-3.576-.188-3.858-2.324a4 4 0 0 1-.04-.598s1.709.416 3.874.516c1.324.06 2.563-.076 3.824-.226 2.418-.29 4.524-1.78 4.79-3.141.416-2.144.38-5.232.38-5.232 0-4.186-2.74-5.415-2.74-5.415-1.383-.635-3.76-.9-6.227-.921zM9.18 5.622c1.028 0 1.804.395 2.318 1.185l.502.84.5-.84c.514-.79 1.292-1.186 2.32-1.186.888 0 1.605.313 2.15.922q.795.915.794 2.469v5.068h-2.008V9.16c0-1.037-.438-1.562-1.31-1.562-.966 0-1.448.622-1.448 1.857v2.693h-1.996V9.455c0-1.235-.484-1.857-1.45-1.857-.872 0-1.308.525-1.308 1.562v4.92H6.236V9.012q-.001-1.554.793-2.469c.547-.609 1.263-.922 2.15-.922"})))},{name:"medium-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{fillRule:"nonzero",d:"M7.423 6c3.27 0 5.922 2.686 5.922 6s-2.651 6-5.922 6S1.5 15.313 1.5 12s2.652-6 5.923-6m9.458.351c1.635 0 2.961 2.53 2.961 5.65 0 3.118-1.325 5.648-2.96 5.648S13.92 15.119 13.92 12s1.325-5.649 2.96-5.649m4.577.589c.576 0 1.042 2.265 1.042 5.06s-.466 5.06-1.042 5.06c-.575 0-1.04-2.265-1.04-5.06s.465-5.06 1.04-5.06"})))},{name:"medium",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M3 3v18h18V3zm15 4.26-1 .93a.28.28 0 0 0-.11.27v6.8a.27.27 0 0 0 .11.27l.94.93v.2h-4.75v-.2l1-1c.09-.1.09-.12.09-.27V9.74l-2.71 6.9h-.37L8 9.74v4.62a.67.67 0 0 0 .17.54l1.27 1.54v.2H5.86v-.2l1.27-1.54a.64.64 0 0 0 .17-.54V9a.5.5 0 0 0-.16-.4L6 7.26v-.2h3.52L12.23 13l2.38-5.94H18z"})))},{name:"messenger",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.026.375C5.462.375.375 5.172.375 11.652c0 3.389 1.393 6.318 3.66 8.341.391.352.311.556.377 2.73a.934.934 0 0 0 1.307.823c2.48-1.092 2.512-1.178 2.933-1.064 7.185 1.977 14.973-2.621 14.973-10.83 0-6.48-5.035-11.277-11.599-11.277m6.996 8.678L15.6 14.47a1.75 1.75 0 0 1-2.527.465l-2.723-2.038a.7.7 0 0 0-.844 0l-3.674 2.786c-.49.372-1.133-.216-.802-.735l3.422-5.417a1.75 1.75 0 0 1 2.527-.465l2.722 2.037a.7.7 0 0 0 .844 0L18.22 8.32c.489-.374 1.132.213.801.732"})))},{name:"microblog",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.641 17.086c1.294-1.522 2.067-3.438 2.067-5.521 0-4.957-4.371-8.972-9.763-8.972s-9.763 4.015-9.763 8.972 4.371 8.972 9.763 8.972a10.5 10.5 0 0 0 3.486-.59.315.315 0 0 1 .356.112c.816 1.101 2.09 1.876 3.506 2.191a.194.194 0 0 0 .192-.309 3.82 3.82 0 0 1 .162-4.858zm-3.065-6.575-2.514 1.909.912 3.022a.286.286 0 0 1-.437.317l-2.592-1.802-2.592 1.802a.285.285 0 0 1-.436-.317l.912-3.022-2.515-1.909a.285.285 0 0 1 .167-.513l3.155-.066 1.038-2.981a.285.285 0 0 1 .539 0l1.038 2.981 3.155.066a.285.285 0 0 1 .17.513"})))},{name:"nextdoor",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",strokeMiterlimit:"10",viewBox:"0 0 130 130"},React.createElement("g",null,React.createElement("path",{d:"M64.25 3.531c-31.144.337-57.596 24.22-60.469 55.907-3.064 33.799 21.857 63.685 55.657 66.75s63.685-21.857 66.75-55.657-21.857-63.686-55.657-66.75a62 62 0 0 0-6.281-.25m3.938 34.907C82.468 38.438 93.5 48.58 93.5 61.5v27c0 .685-.565 1.25-1.25 1.25H80.906a1.267 1.267 0 0 1-1.25-1.25V63.375c0-5.58-4.309-11.937-11.469-11.937-7.47 0-11.468 6.357-11.468 11.937V88.5c0 .685-.565 1.25-1.25 1.25H44.125c-.68 0-1.219-.57-1.219-1.25V64.156c0-.74-.529-1.364-1.25-1.531-13.13-2.93-15.115-10.285-15.375-21.125-.005-.332.142-.67.375-.906.233-.237.543-.375.875-.375l11.688.062c.66.01 1.187.529 1.218 1.188.13 4.44.438 9.406 4.438 9.406.83 0 1.443-1.179 1.813-1.719 4.41-6.48 12.28-10.718 21.5-10.718"})))},{name:"patreon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20 7.408c-.003-2.299-1.746-4.182-3.79-4.862-2.54-.844-5.888-.722-8.312.453-2.939 1.425-3.862 4.545-3.896 7.656-.028 2.559.22 9.297 3.92 9.345 2.75.036 3.159-3.603 4.43-5.356.906-1.247 2.071-1.599 3.506-1.963 2.465-.627 4.146-2.626 4.142-5.273"})))},{name:"pinterest-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.289 2C6.617 2 3.606 5.648 3.606 9.622c0 1.846 1.025 4.146 2.666 4.878.25.111.381.063.439-.169.044-.175.267-1.029.365-1.428a.37.37 0 0 0-.091-.362c-.54-.63-.975-1.791-.975-2.873 0-2.777 2.194-5.464 5.933-5.464 3.23 0 5.49 2.108 5.49 5.122 0 3.407-1.794 5.768-4.13 5.768-1.291 0-2.257-1.021-1.948-2.277.372-1.495 1.089-3.112 1.089-4.191 0-.967-.542-1.775-1.663-1.775-1.319 0-2.379 1.309-2.379 3.059 0 1.115.394 1.869.394 1.869s-1.302 5.279-1.54 6.261c-.405 1.666.053 4.368.094 4.604.021.126.167.169.25.063.129-.165 1.699-2.419 2.142-4.051.158-.59.817-2.995.817-2.995.43.784 1.681 1.446 3.013 1.446 3.963 0 6.822-3.494 6.822-7.833C20.394 5.112 16.849 2 12.289 2"})))},{name:"pinterest",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12c0 4.236 2.636 7.855 6.356 9.312-.087-.791-.166-2.005.035-2.869.182-.78 1.173-4.971 1.173-4.971s-.299-.599-.299-1.484c0-1.39.806-2.429 1.809-2.429.853 0 1.265.641 1.265 1.409 0 .858-.546 2.141-.828 3.329-.236.996.499 1.807 1.481 1.807 1.777 0 3.144-1.874 3.144-4.579 0-2.394-1.72-4.068-4.177-4.068-2.845 0-4.515 2.134-4.515 4.34 0 .859.331 1.781.744 2.282a.3.3 0 0 1 .069.287c-.077.316-.246.995-.279 1.134-.044.183-.145.222-.334.134-1.249-.581-2.03-2.407-2.03-3.874 0-3.154 2.292-6.051 6.607-6.051 3.469 0 6.165 2.472 6.165 5.775 0 3.446-2.173 6.22-5.189 6.22-1.013 0-1.966-.526-2.292-1.148l-.623 2.377c-.226.869-.835 1.957-1.243 2.622.936.289 1.93.445 2.961.445 5.523 0 10-4.477 10-10S17.523 2 12 2"})))},{name:"pocket",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.927 4.194A1.82 1.82 0 0 0 20.222 3H3.839a1.823 1.823 0 0 0-1.813 1.814v6.035l.069 1.2c.29 2.73 1.707 5.115 3.899 6.778l.119.089.025.018a9.9 9.9 0 0 0 3.91 1.727 10.06 10.06 0 0 0 4.049-.014.3.3 0 0 0 .064-.023 9.9 9.9 0 0 0 3.753-1.691l.025-.018q.06-.043.119-.089c2.192-1.664 3.609-4.049 3.898-6.778l.069-1.2V4.814a1.8 1.8 0 0 0-.098-.62m-4.235 6.287-4.704 4.512a1.37 1.37 0 0 1-1.898 0l-4.705-4.512a1.371 1.371 0 1 1 1.898-1.979l3.756 3.601 3.755-3.601a1.372 1.372 0 0 1 1.898 1.979"})))},{name:"polldaddy",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.487 2 2 6.487 2 12c0 5.514 4.487 10 10 10 5.514 0 10-4.486 10-10 0-5.513-4.486-10-10-10m.991 1.68c2.361.084 4.657 1.251 6.197 3.136.283.334.541.693.774 1.067a7.78 7.78 0 0 0-6.094-2.94 7.76 7.76 0 0 0-5.896 2.703q-.008.006-.016.014l-.152.159-.031.032a6.12 6.12 0 0 0-1.633 4.165 6.15 6.15 0 0 0 6.143 6.143c.57 0 1.123-.081 1.649-.227-1.849.839-4.131.747-5.926-.324-1.841-1.089-3.171-3.111-3.433-5.313A7.39 7.39 0 0 1 6.69 6.137C8.294 4.5 10.634 3.563 12.991 3.68m3.373 8.519c-.049-2.024-1.587-3.889-3.544-4.174-1.927-.343-3.917.857-4.451 2.661a3.67 3.67 0 0 0 .2 2.653c.39.8 1.067 1.451 1.894 1.759 1.664.654 3.63-.27 4.173-1.863.593-1.58-.396-3.423-1.94-3.776-1.52-.407-3.161.757-3.204 2.243a2.36 2.36 0 0 0 .753 1.879c.501.476 1.23.667 1.871.529a2.07 2.07 0 0 0 1.469-1.134 1.91 1.91 0 0 0-.087-1.767c-.297-.513-.859-.863-1.429-.881a1.7 1.7 0 0 0-1.437.679 1.53 1.53 0 0 0-.18 1.489q.006.016.016.03c.193.634.774 1.1 1.467 1.117a1.6 1.6 0 0 1-.97-.183c-.466-.244-.809-.747-.893-1.29a1.8 1.8 0 0 1 .499-1.539 2.02 2.02 0 0 1 1.58-.606c.593.04 1.159.35 1.517.859.364.496.51 1.156.383 1.773-.116.62-.529 1.174-1.093 1.514a2.52 2.52 0 0 1-1.914.286c-.65-.161-1.226-.606-1.584-1.206a2.83 2.83 0 0 1-.341-2.031c.143-.7.573-1.321 1.176-1.753 1.193-.883 3.056-.751 4.106.411 1.106 1.1 1.327 3.027.406 4.371-.877 1.376-2.74 2.086-4.374 1.594-1.639-.449-2.913-2.079-3.031-3.853-.07-.884.13-1.797.583-2.577.445-.777 1.155-1.432 1.972-1.862 1.64-.88 3.816-.743 5.349.424 1.251.924 2.083 2.42 2.236 4.009l.001.03c0 2.9-2.359 5.26-5.26 5.26a5.2 5.2 0 0 1-1.947-.376 5 5 0 0 0 2.613-.079 4.96 4.96 0 0 0 2.514-1.751c.618-.828.95-1.861.901-2.869M12 21.113c-5.024 0-9.111-4.087-9.111-9.113 0-4.789 3.713-8.723 8.411-9.081a7 7 0 0 0-.397.06c-2.644.453-5.017 2.106-6.32 4.409-1.309 2.301-1.391 5.19-.3 7.527 1.056 2.34 3.253 4.156 5.776 4.553 2.497.44 5.133-.483 6.787-2.301 1.719-1.797 2.269-4.529 1.486-6.796-.583-1.81-1.976-3.331-3.7-4.046 3.417.594 6.174 3.221 6.174 6.781 0 1.004-.241 2.02-.657 2.966-1.498 2.984-4.586 5.041-8.149 5.041"})))},{name:"print",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M9 16h6v2H9zm13 1h-3v3a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-3H2V9a2 2 0 0 1 2-2h1V5a2 2 0 0 1 2-2h10a2 2 0 0 1 2 2v2h1a2 2 0 0 1 2 2zM7 7h10V5H7zm10 7H7v6h10zm3-3.5a1.5 1.5 0 1 0-3.001.001A1.5 1.5 0 0 0 20 10.5"})))},{name:"quora",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M47.736 16.521c-.41-.81-.898-1.631-1.846-1.631a1 1 0 0 0-.527.107l-.322-.644a2.93 2.93 0 0 1 1.836-.595c1.26 0 1.914.605 2.431 1.397a6.8 6.8 0 0 0 .449-2.675c0-2.773-.869-4.199-2.929-4.199-1.992 0-2.851 1.465-2.851 4.199s.859 4.17 2.851 4.17a4 4 0 0 0 .869-.107zm.498.966a6 6 0 0 1-1.367.185 5.27 5.27 0 0 1-5.263-5.204c0-3.114 2.558-5.233 5.263-5.233s5.282 2.109 5.282 5.233a5.08 5.08 0 0 1-1.992 4.072c.381.566.781.956 1.319.956.595 0 .839-.459.878-.82h.781c.049.488-.195 2.48-2.373 2.48-1.319 0-2.012-.761-2.529-1.66zm5.624-2.646v-3.563c0-.371-.146-.586-.615-.586h-.498v-.956h3.251v5.048c0 .849.459 1.231 1.161 1.231a1.56 1.56 0 0 0 1.465-.839V11.28c0-.371-.146-.586-.615-.586h-.527v-.957h3.28v5.302c0 .527.195.732.8.732h.107v.976l-2.929.468V16.21h-.057a3.12 3.12 0 0 1-2.509 1.152c-1.28 0-2.304-.644-2.304-2.558zm12.059 1.611c1.152 0 1.592-1.005 1.611-3.027.02-1.982-.459-2.929-1.611-2.929-1.005 0-1.641.956-1.641 2.929 0 2.021.625 3.027 1.641 3.027m0 .956a3.906 3.906 0 0 1-3.974-3.974c0-2.334 1.836-3.886 3.974-3.886 2.226 0 4.004 1.582 4.004 3.886a3.867 3.867 0 0 1-4.004 3.974m4.072-.146v-.956h.312c.781 0 .859-.224.859-.908v-4.121c0-.371-.215-.586-.732-.586h-.42v-.955h2.968l.146 1.553h.108c.371-1.113 1.221-1.699 2.051-1.699.693 0 1.221.39 1.221 1.181 0 .547-.264 1.093-1.005 1.093-.664 0-.8-.449-1.358-.449-.488 0-.869.468-.869 1.152v2.783c0 .673.166.908.937.908h.439v.956h-4.658zm9.901-1.093c.956 0 1.338-.898 1.338-1.797v-1.211c-.732.722-2.304.742-2.304 2.021 0 .625.371.986.966.986m1.387 0c-.39.752-1.191 1.26-2.314 1.26-1.309 0-2.148-.732-2.148-1.914 0-2.451 3.417-1.797 4.423-3.427v-.185c0-1.25-.488-1.445-1.035-1.445-1.524 0-.83 1.631-2.226 1.631-.673 0-.937-.371-.937-.859 0-.927 1.093-1.67 3.173-1.67 1.963 0 3.163.537 3.163 2.49v3.114q-.02.742.595.742a1 1 0 0 0 .449-.127l.254.615c-.205.312-.752.869-1.836.869-.908 0-1.465-.42-1.543-1.113h-.01zm-68.554 2.558c-.83-1.641-1.807-3.3-3.711-3.3a2.9 2.9 0 0 0-1.093.215l-.644-1.299a5.66 5.66 0 0 1 3.662-1.211c2.548 0 3.857 1.231 4.892 2.792q.917-2.012.908-5.38c0-5.585-1.748-8.417-5.829-8.417-4.033 0-5.76 2.87-5.76 8.417s1.738 8.397 5.76 8.397a5.9 5.9 0 0 0 1.748-.224zm.996 1.953a9.8 9.8 0 0 1-2.744.371C5.614 21.041.371 16.764.371 10.545.371 4.277 5.614 0 10.965 0c5.448 0 10.642 4.248 10.642 10.545a10.25 10.25 0 0 1-4.013 8.201c.732 1.152 1.563 1.914 2.665 1.914 1.201 0 1.689-.927 1.768-1.66h1.572c.088.966-.4 4.999-4.775 4.999-2.646 0-4.052-1.543-5.106-3.339z"})))},{name:"reddit",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M22 11.816a2.28 2.28 0 0 0-2.277-2.277c-.593 0-1.122.24-1.526.614-1.481-.965-3.455-1.594-5.647-1.69l1.171-3.702 3.18.748a1.88 1.88 0 0 0 1.876 1.862 1.88 1.88 0 0 0 1.877-1.878 1.88 1.88 0 0 0-1.877-1.877c-.769 0-1.431.466-1.72 1.13l-3.508-.826a.386.386 0 0 0-.46.261l-1.35 4.268c-2.316.038-4.411.67-5.97 1.671a2.24 2.24 0 0 0-1.492-.581A2.28 2.28 0 0 0 2 11.816c0 .814.433 1.523 1.078 1.925a4 4 0 0 0-.061.672c0 3.292 4.011 5.97 8.941 5.97s8.941-2.678 8.941-5.97q-.002-.32-.053-.632A2.26 2.26 0 0 0 22 11.816m-3.224-7.422a1.1 1.1 0 1 1-.001 2.199 1.1 1.1 0 0 1 .001-2.199M2.777 11.816c0-.827.672-1.5 1.499-1.5.313 0 .598.103.838.269-.851.676-1.477 1.479-1.812 2.36a1.48 1.48 0 0 1-.525-1.129m9.182 7.79c-4.501 0-8.164-2.329-8.164-5.193S7.457 9.22 11.959 9.22s8.164 2.329 8.164 5.193-3.663 5.193-8.164 5.193m8.677-6.605c-.326-.89-.948-1.701-1.797-2.384.248-.186.55-.301.883-.301.827 0 1.5.673 1.5 1.5.001.483-.23.911-.586 1.185m-11.64 1.703c-.76 0-1.397-.616-1.397-1.376s.637-1.397 1.397-1.397 1.376.637 1.376 1.397-.616 1.376-1.376 1.376m7.405-1.376c0 .76-.616 1.376-1.376 1.376s-1.399-.616-1.399-1.376.639-1.397 1.399-1.397 1.376.637 1.376 1.397m-1.172 3.38a.39.39 0 0 1 0 .55c-.674.674-1.727 1.002-3.219 1.002l-.011-.002-.011.002c-1.492 0-2.544-.328-3.218-1.002a.389.389 0 1 1 .55-.55c.521.521 1.394.775 2.669.775l.011.002.011-.002c1.275 0 2.148-.253 2.669-.775a.387.387 0 0 1 .549 0"})))},{name:"share",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M18 16c-.788 0-1.499.31-2.034.807L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0 .24.04.47.09.7L8.04 9.81C7.5 9.31 6.79 9 6 9c-1.66 0-3 1.34-3 3s1.34 3 3 3c.79 0 1.5-.31 2.04-.81l7.048 4.118A3 3 0 0 0 15 19a3 3 0 1 0 3-3"})))},{name:"skype",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m10.113 2.699.1-.02q.05.025.098.051zM2.72 10.223l-.017.103q.025.048.051.095zm18.555 3.548q.009-.053.018-.106-.025-.047-.052-.095zm-7.712 7.428q.049.027.096.053l.105-.017zM22 16.386a5.55 5.55 0 0 1-1.637 3.953 5.55 5.55 0 0 1-3.953 1.637 5.6 5.6 0 0 1-2.75-.725l.105-.017-.202-.035q.049.027.096.053a9.5 9.5 0 0 1-1.654.147 9.4 9.4 0 0 1-3.676-.743 9.4 9.4 0 0 1-3.002-2.023 9.4 9.4 0 0 1-2.023-3.002 9.4 9.4 0 0 1-.743-3.676c0-.546.049-1.093.142-1.628q.025.048.051.095l-.034-.199-.017.103A5.6 5.6 0 0 1 2 7.615c0-1.493.582-2.898 1.637-3.953A5.56 5.56 0 0 1 7.59 2.024c.915 0 1.818.228 2.622.655l-.1.02.199.031q-.049-.026-.098-.051l.004-.001a9.5 9.5 0 0 1 1.788-.169 9.41 9.41 0 0 1 6.678 2.766 9.4 9.4 0 0 1 2.024 3.002 9.4 9.4 0 0 1 .743 3.676c0 .575-.054 1.15-.157 1.712q-.025-.047-.052-.095l.034.201q.009-.053.018-.106c.461.829.707 1.767.707 2.721m-5.183-2.248c0-1.331-.613-2.743-3.033-3.282l-2.209-.49c-.84-.192-1.807-.444-1.807-1.237s.679-1.348 1.903-1.348c2.468 0 2.243 1.696 3.468 1.696.645 0 1.209-.379 1.209-1.031 0-1.521-2.435-2.663-4.5-2.663-2.242 0-4.63.952-4.63 3.488 0 1.221.436 2.521 2.839 3.123l2.984.745c.903.223 1.129.731 1.129 1.189 0 .762-.758 1.507-2.129 1.507-2.679 0-2.307-2.062-3.743-2.062-.645 0-1.113.444-1.113 1.078 0 1.236 1.501 2.886 4.856 2.886 3.195 0 4.776-1.538 4.776-3.599"})))},{name:"sms",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M17.696 4C20.069 4 22 5.973 22 8.398v4.357c0 2.04-1.368 3.783-3.261 4.266v4.427l-5.234-4.295h-7.2C3.93 17.153 2 15.18 2 12.755V8.398C2 5.973 3.931 4 6.304 4zM7.028 8.515c-.98 0-1.66.562-1.66 1.349-.009.497.322.91.985 1.178l.39.142c.242.097.305.171.305.297 0 .162-.131.251-.442.251s-.76-.135-1.004-.284l-.112.046-.215.868c.359.258.832.364 1.33.364 1.104 0 1.764-.523 1.764-1.333-.008-.574-.305-.956-.954-1.216l-.393-.146c-.266-.108-.341-.181-.341-.287 0-.152.131-.243.387-.243.274 0 .587.093.808.214l.109-.047.214-.837c-.315-.224-.741-.316-1.171-.316m10.302 0c-.98 0-1.66.562-1.66 1.349-.008.497.322.91.985 1.178l.39.142c.243.097.305.171.305.297 0 .162-.13.251-.442.251-.311 0-.76-.135-1.004-.284l-.112.046-.215.868c.359.258.832.364 1.33.364 1.104 0 1.764-.523 1.764-1.333-.008-.574-.305-.956-.954-1.216l-.393-.146c-.266-.108-.341-.181-.341-.287 0-.152.131-.243.387-.243.274 0 .587.093.808.214l.109-.047.214-.837c-.316-.224-.741-.316-1.171-.316m-3.733 0c-.297 0-.55.066-.78.202l-.144.098a2 2 0 0 0-.264.247l-.078.095-.027-.077c-.15-.34-.55-.565-1.033-.565l-.169.007a1.36 1.36 0 0 0-.896.42l-.08.09-.038-.363-.075-.067H8.994l-.075.079.024.634c.005.2.008.397.008.604v2.652l.075.075h1.178l.075-.075v-2.269q-.002-.168.042-.274c.083-.23.262-.392.496-.392.314 0 .483.267.483.753v2.182l.075.075h1.179l.075-.075v-2.277c0-.097.016-.213.043-.285.077-.224.26-.373.486-.373.33 0 .5.272.5.817v2.118l.074.075h1.179l.075-.075v-2.293c0-1.131-.537-1.763-1.39-1.763Z"})))},{name:"snapchat",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M11.989 1.728c3.221.001 5.904 2.683 5.908 5.912q.002 1.133.067 2.094a.737.737 0 0 0 .902.669l1.009-.237a.6.6 0 0 1 .129-.015c.256 0 .492.175.55.434a.74.74 0 0 1-.479.861l-1.532.618a.823.823 0 0 0-.485.98c1.229 4.543 4.661 4.071 4.661 4.662 0 .743-2.587.848-2.821 1.082s-.01 1.368-.532 1.588a1.1 1.1 0 0 1-.409.056c-.393 0-.95-.077-1.536-.077-.509 0-1.04.058-1.507.273-1.239.572-2.433 1.641-3.914 1.641S9.325 21.2 8.086 20.628c-.467-.216-.998-.273-1.507-.273-.586 0-1.143.077-1.536.077-.17 0-.31-.014-.409-.056-.522-.22-.299-1.354-.532-1.588s-2.821-.337-2.821-1.08c0-.592 3.432-.119 4.661-4.662a.824.824 0 0 0-.486-.98l-1.532-.618a.74.74 0 0 1-.479-.861.56.56 0 0 1 .679-.419l1.009.237q.086.02.169.02a.737.737 0 0 0 .733-.689q.065-.961.067-2.094c.004-3.229 2.666-5.91 5.887-5.912m0-1.281c-.961 0-1.898.194-2.784.574A7.2 7.2 0 0 0 6.93 2.572a7.2 7.2 0 0 0-1.539 2.282A7.1 7.1 0 0 0 4.82 7.64a33 33 0 0 1-.029 1.369l-.375-.088a2 2 0 0 0-.421-.049 1.86 1.86 0 0 0-1.135.389 1.84 1.84 0 0 0-.666 1.049 2.024 2.024 0 0 0 1.271 2.335l1.124.454c-.744 2.285-2.117 2.723-3.041 3.018a5 5 0 0 0-.659.246C.087 16.76 0 17.436 0 17.708c0 .521.247.996.694 1.339.223.17.499.311.844.43.47.162 1.016.265 1.459.347.021.164.053.341.106.518.22.738.684 1.069 1.034 1.217.332.14.676.156.905.156.224 0 .462-.018.713-.036.269-.02.548-.041.823-.041.426 0 .743.051.97.155.311.144.64.337.989.542.972.571 2.073 1.217 3.462 1.217s2.49-.647 3.462-1.217c.349-.205.679-.399.989-.542.226-.105.544-.155.97-.155.275 0 .554.021.823.041.251.019.488.036.713.036.229 0 .573-.016.905-.156.35-.147.814-.478 1.034-1.217.053-.178.084-.354.106-.518.443-.082.989-.185 1.459-.347.345-.119.621-.259.844-.43.448-.342.694-.818.694-1.339 0-.272-.087-.948-.891-1.347a5 5 0 0 0-.659-.246c-.924-.295-2.297-.733-3.041-3.018l1.124-.454a2.025 2.025 0 0 0 1.271-2.335 1.83 1.83 0 0 0-.666-1.049 1.86 1.86 0 0 0-1.556-.34l-.375.088a33 33 0 0 1-.029-1.369 7.1 7.1 0 0 0-.575-2.789c-.365-.853-.886-1.62-1.547-2.282s-1.428-1.182-2.28-1.547a7.1 7.1 0 0 0-2.786-.574"})))},{name:"soundcloud",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M23.587 13.923a3.303 3.303 0 0 1-3.344 3.117h-8.037a.674.674 0 0 1-.667-.67V7.717a.74.74 0 0 1 .444-.705s.739-.512 2.296-.512a5.27 5.27 0 0 1 2.702.742 5.35 5.35 0 0 1 2.516 3.485 3.1 3.1 0 0 1 .852-.116 3.217 3.217 0 0 1 3.237 3.312m-13.05-5.659c.242 2.935.419 5.612 0 8.538a.261.261 0 0 1-.519 0c-.39-2.901-.221-5.628 0-8.538a.26.26 0 0 1 .398-.25.26.26 0 0 1 .12.25zm-1.627 8.541a.273.273 0 0 1-.541 0 32.7 32.7 0 0 1 0-7.533.274.274 0 0 1 .544 0 29.4 29.4 0 0 1-.003 7.533m-1.63-7.788c.264 2.69.384 5.099-.003 7.782a.262.262 0 0 1-.522 0c-.374-2.649-.249-5.127 0-7.782a.264.264 0 0 1 .525 0m-1.631 7.792a.268.268 0 0 1-.532 0 27.6 27.6 0 0 1 0-7.034.27.27 0 1 1 .541 0 25.8 25.8 0 0 1-.01 7.034zm-1.63-5.276c.412 1.824.227 3.435-.015 5.294a.255.255 0 0 1-.504 0c-.22-1.834-.402-3.482-.015-5.295a.268.268 0 0 1 .535 0m-1.626-.277c.378 1.869.254 3.451-.01 5.325-.031.277-.506.28-.531 0-.239-1.846-.352-3.476-.01-5.325a.277.277 0 0 1 .551 0m-1.643.907c.396 1.239.261 2.246-.016 3.517a.258.258 0 0 1-.514 0c-.239-1.246-.336-2.274-.021-3.517a.276.276 0 0 1 .55 0z"})))},{name:"spotify",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m4.586 14.424a.62.62 0 0 1-.857.207c-2.348-1.435-5.304-1.76-8.785-.964a.622.622 0 1 1-.277-1.215c3.809-.871 7.077-.496 9.713 1.115a.623.623 0 0 1 .206.857M17.81 13.7a.78.78 0 0 1-1.072.257c-2.687-1.652-6.785-2.131-9.965-1.166A.779.779 0 1 1 6.32 11.3c3.632-1.102 8.147-.568 11.234 1.328a.78.78 0 0 1 .256 1.072m.105-2.835c-3.223-1.914-8.54-2.09-11.618-1.156a.935.935 0 1 1-.542-1.79c3.532-1.072 9.404-.865 13.115 1.338a.936.936 0 1 1-.955 1.608"})))},{name:"squarespace",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M20.87 9.271a3.86 3.86 0 0 0-5.458 0l-6.141 6.141a.964.964 0 1 0 1.365 1.364l6.14-6.14a1.929 1.929 0 1 1 2.729 2.729l-6.022 6.022a1.93 1.93 0 0 0 2.729 0l4.658-4.658a3.86 3.86 0 0 0 0-5.458m-2.047 2.047a.965.965 0 0 0-1.365 0l-6.14 6.14a1.93 1.93 0 0 1-2.729 0 .964.964 0 1 0-1.364 1.364 3.86 3.86 0 0 0 5.458 0l6.14-6.14a.966.966 0 0 0 0-1.364m-2.047-6.141a3.86 3.86 0 0 0-5.458 0l-6.14 6.14a.964.964 0 1 0 1.364 1.364l6.141-6.14a1.93 1.93 0 0 1 2.729 0 .965.965 0 1 0 1.364-1.364m-2.047 2.047a.964.964 0 0 0-1.364 0l-6.14 6.141a1.929 1.929 0 1 1-2.729-2.729l6.022-6.022a1.93 1.93 0 0 0-2.729 0L3.13 9.271a3.86 3.86 0 0 0 5.458 5.458l6.14-6.141a.963.963 0 0 0 .001-1.364"})))},{name:"stackexchange",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M4 11.606h16v3.272H4zM4 7.377h16v3.272H4zM17.514 3H6.55C5.147 3 4 4.169 4 5.614v.848h16v-.85C20 4.167 18.895 3 17.514 3M4 15.813v.85c0 1.445 1.147 2.614 2.55 2.614h6.799v3.463l3.357-3.463h.744c1.402 0 2.55-1.169 2.55-2.614v-.85z"})))},{name:"stackoverflow",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M18.18 20.103V14.78h1.767v7.09H4v-7.09h1.767v5.323z"}),React.createElement("path",{d:"m7.717 14.275 8.673 1.813.367-1.744-8.673-1.813zm1.147-4.13 8.031 3.74.734-1.606-8.031-3.763zm2.226-3.946 6.815 5.667 1.124-1.354-6.815-5.667zM15.495 2l-1.423 1.055 5.277 7.113 1.423-1.055zM7.533 18.314h8.857v-1.767H7.533z"})))},{name:"stumbleupon",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 4.294a4.47 4.47 0 0 0-4.471 4.471v6.353a1.059 1.059 0 1 1-2.118 0v-2.824H2v2.941a4.471 4.471 0 0 0 8.942 0v-6.47a1.059 1.059 0 1 1 2.118 0v1.294l1.412.647 2-.647V8.765A4.473 4.473 0 0 0 12 4.294m1.059 8.059v2.882a4.471 4.471 0 0 0 8.941 0v-2.824h-3.412v2.824a1.059 1.059 0 1 1-2.118 0v-2.882l-2 .647z"})))},{name:"substack",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19.904 9.182H4.095V7.054h15.81v2.127M4.095 11.109V21L12 16.583 19.905 21v-9.891zM19.905 3H4.095v2.127h15.81z"})))},{name:"telegram",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m3.08 14.757s-.25.625-.936.325l-2.541-1.949-1.63 1.486s-.127.096-.266.036c0 0-.12-.011-.27-.486s-.911-2.972-.911-2.972L6 12.349s-.387-.137-.425-.438c-.037-.3.437-.462.437-.462l10.03-3.934s.824-.362.824.238z"})))},{name:"threads",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 192 192"},React.createElement("g",null,React.createElement("path",{d:"M141.537 88.988a67 67 0 0 0-2.518-1.143c-1.482-27.307-16.403-42.94-41.457-43.1h-.34c-14.986 0-27.449 6.396-35.12 18.036l13.779 9.452c5.73-8.695 14.724-10.548 21.348-10.548h.229c8.249.053 14.474 2.452 18.503 7.129 2.932 3.405 4.893 8.111 5.864 14.05-7.314-1.243-15.224-1.626-23.68-1.14-23.82 1.371-39.134 15.264-38.105 34.568.522 9.792 5.4 18.216 13.735 23.719 7.047 4.652 16.124 6.927 25.557 6.412 12.458-.683 22.231-5.436 29.049-14.127 5.178-6.6 8.453-15.153 9.899-25.93 5.937 3.583 10.337 8.298 12.767 13.966 4.132 9.635 4.373 25.468-8.546 38.376-11.319 11.308-24.925 16.2-45.488 16.351-22.809-.169-40.06-7.484-51.275-21.742C35.236 139.966 29.808 120.682 29.605 96c.203-24.682 5.63-43.966 16.133-57.317C56.954 24.425 74.204 17.11 97.013 16.94c22.975.17 40.526 7.52 52.171 21.847 5.71 7.026 10.015 15.86 12.853 26.162l16.147-4.308c-3.44-12.68-8.853-23.606-16.219-32.668C147.036 9.607 125.202.195 97.07 0h-.113C68.882.194 47.292 9.642 32.788 28.08 19.882 44.485 13.224 67.315 13.001 95.932L13 96v.067c.224 28.617 6.882 51.447 19.788 67.854C47.292 182.358 68.882 191.806 96.957 192h.113c24.96-.173 42.554-6.708 57.048-21.189 18.963-18.945 18.392-42.692 12.142-57.27-4.484-10.454-13.033-18.945-24.723-24.553M98.44 129.507c-10.44.588-21.286-4.098-21.82-14.135-.397-7.442 5.296-15.746 22.461-16.735q2.948-.17 5.79-.169c6.235 0 12.068.606 17.371 1.765-1.978 24.702-13.58 28.713-23.802 29.274"})))},{name:"tiktok-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M5 3a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2zm7.531 3h2.053s-.114 2.635 2.85 2.82v2.04s-1.582.099-2.85-.87l.021 4.207a3.804 3.804 0 1 1-3.802-3.802h.533v2.082a1.73 1.73 0 0 0-1.922.648 1.727 1.727 0 0 0 1.947 2.646 1.73 1.73 0 0 0 1.19-1.642z"})))},{name:"tiktok",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.22 2h3.42s-.19 4.394 4.75 4.702v3.396s-2.636.166-4.75-1.448l.037 7.012a6.338 6.338 0 1 1-6.34-6.339h.89v3.472a2.882 2.882 0 1 0 2.024 2.752z"})))},{name:"tripadvisor",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.01 9.859c.236-1.002.985-2.003.985-2.003l-3.341-.002C16.779 6.643 14.502 6 11.979 6 9.363 6 7 6.659 5.135 7.877L2 7.88s.74.988.98 1.983a4.98 4.98 0 0 0-.977 2.961 5.01 5.01 0 0 0 5.009 5.003 5 5 0 0 0 3.904-1.875l1.065 1.592 1.076-1.606a4.96 4.96 0 0 0 1.838 1.448 4.98 4.98 0 0 0 3.831.151 5.01 5.01 0 0 0 2.963-6.431 5 5 0 0 0-.679-1.247m-13.998 6.96a4 4 0 0 1-3.998-3.995 4 4 0 0 1 3.998-3.997 4 4 0 0 1 3.996 3.997 4 4 0 0 1-3.996 3.995m4.987-4.36A5.007 5.007 0 0 0 7.11 7.821c1.434-.613 3.081-.947 4.867-.947 1.798 0 3.421.324 4.853.966a4.984 4.984 0 0 0-4.831 4.619m6.288 4.134a3.97 3.97 0 0 1-3.058-.122 3.96 3.96 0 0 1-2.075-2.245v-.001a3.97 3.97 0 0 1 .118-3.056 3.97 3.97 0 0 1 2.246-2.077 4.005 4.005 0 0 1 5.135 2.366 4.006 4.006 0 0 1-2.366 5.135"}),React.createElement("path",{d:"M6.949 10.307a2.477 2.477 0 0 0-2.475 2.472 2.48 2.48 0 0 0 2.475 2.474 2.474 2.474 0 0 0 0-4.946m0 4.094a1.626 1.626 0 0 1-1.624-1.623 1.621 1.621 0 1 1 1.624 1.623M16.981 10.307a2.477 2.477 0 0 0-2.474 2.472 2.48 2.48 0 0 0 2.474 2.474 2.476 2.476 0 0 0 2.472-2.474 2.475 2.475 0 0 0-2.472-2.472m0 4.094a1.625 1.625 0 0 1-1.622-1.623 1.622 1.622 0 1 1 1.622 1.623"}),React.createElement("path",{d:"M7.778 12.778a.832.832 0 1 1-1.664.002.832.832 0 0 1 1.664-.002M16.981 11.947a.832.832 0 1 0 .002 1.666.832.832 0 0 0-.002-1.666"})))},{name:"tumblr-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M16.749 17.396c-.357.17-1.041.319-1.551.332-1.539.041-1.837-1.081-1.85-1.896V9.847h3.861v-2.91h-3.847V2.039h-2.817c-.046 0-.127.041-.138.144-.165 1.499-.867 4.13-3.783 5.181v2.484h1.945v6.282c0 2.151 1.587 5.206 5.775 5.135 1.413-.024 2.982-.616 3.329-1.126z"})))},{name:"tumblr",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2m-5.569 14.265c-2.446.042-3.372-1.742-3.372-2.998v-3.668H8.923v-1.45c1.703-.614 2.113-2.15 2.209-3.025.007-.06.054-.084.081-.084h1.645V8.9h2.246v1.7H12.85v3.495c.008.476.182 1.131 1.081 1.107.298-.008.697-.094.906-.194l.54 1.601c-.205.296-1.121.641-1.946.656"})))},{name:"twitch",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M16.499 8.089h-1.636v4.91h1.636zm-4.499 0h-1.637v4.91H12zM4.228 3.178 3 6.451v13.092h4.499V22h2.456l2.454-2.456h3.681L21 14.636V3.178zm15.136 10.638L16.5 16.681H12l-2.453 2.453V16.68H5.863V4.814h13.501z"})))},{name:"twitter-alt",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M22.23 5.924a8.2 8.2 0 0 1-2.357.646 4.12 4.12 0 0 0 1.804-2.27 8.2 8.2 0 0 1-2.606.996 4.103 4.103 0 0 0-6.991 3.742 11.65 11.65 0 0 1-8.457-4.287 4.1 4.1 0 0 0-.556 2.063 4.1 4.1 0 0 0 1.825 3.415 4.1 4.1 0 0 1-1.859-.513v.052a4.104 4.104 0 0 0 3.292 4.023 4.1 4.1 0 0 1-1.853.07 4.11 4.11 0 0 0 3.833 2.85 8.24 8.24 0 0 1-5.096 1.756 8 8 0 0 1-.979-.057 11.6 11.6 0 0 0 6.29 1.843c7.547 0 11.675-6.252 11.675-11.675q0-.267-.012-.531a8.3 8.3 0 0 0 2.047-2.123"})))},{name:"twitter",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2m-2.534 6.71q.007.148.007.298c0 3.045-2.318 6.556-6.556 6.556a6.5 6.5 0 0 1-3.532-1.035q.27.032.55.032a4.63 4.63 0 0 0 2.862-.986 2.31 2.31 0 0 1-2.152-1.6 2.3 2.3 0 0 0 1.04-.04 2.306 2.306 0 0 1-1.848-2.259v-.029c.311.173.666.276 1.044.288a2.303 2.303 0 0 1-.713-3.076 6.54 6.54 0 0 0 4.749 2.407 2.305 2.305 0 0 1 3.926-2.101 4.6 4.6 0 0 0 1.463-.559 2.3 2.3 0 0 1-1.013 1.275c.466-.056.91-.18 1.323-.363-.31.461-.7.867-1.15 1.192"})))},{name:"untappd",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m11 13.299-5.824 8.133c-.298.416-.8.635-1.308.572-.578-.072-1.374-.289-2.195-.879S.392 19.849.139 19.323a1.4 1.4 0 0 1 .122-1.425l5.824-8.133a3.1 3.1 0 0 1 1.062-.927l1.146-.604c.23-.121.436-.283.608-.478.556-.631 2.049-2.284 4.696-4.957l.046-.212a.13.13 0 0 1 .096-.1l.146-.037a.135.135 0 0 0 .101-.141l-.015-.18a.13.13 0 0 1 .125-.142c.176-.005.518.046 1.001.393s.64.656.692.824a.13.13 0 0 1-.095.164l-.175.044a.13.13 0 0 0-.101.141l.012.15a.13.13 0 0 1-.063.123l-.186.112c-1.679 3.369-2.764 5.316-3.183 6.046a2.2 2.2 0 0 0-.257.73l-.205 1.281A3.1 3.1 0 0 1 11 13.3zm12.739 4.598-5.824-8.133a3.1 3.1 0 0 0-1.062-.927l-1.146-.605a2.1 2.1 0 0 1-.608-.478 51 51 0 0 0-.587-.654.09.09 0 0 0-.142.018 97 97 0 0 1-1.745 3.223 1.4 1.4 0 0 0-.171.485 3.5 3.5 0 0 0 0 1.103l.01.064c.075.471.259.918.536 1.305l5.824 8.133c.296.413.79.635 1.294.574a4.76 4.76 0 0 0 2.209-.881 4.76 4.76 0 0 0 1.533-1.802 1.4 1.4 0 0 0-.122-1.425zM8.306 3.366l.175.044a.134.134 0 0 1 .101.141l-.012.15a.13.13 0 0 0 .063.123l.186.112q.465.933.869 1.721c.026.051.091.06.129.019q.655-.703 1.585-1.668a.137.137 0 0 0 .003-.19c-.315-.322-.645-.659-1.002-1.02l-.046-.212a.13.13 0 0 0-.096-.099l-.146-.037a.135.135 0 0 1-.101-.141l.015-.18a.13.13 0 0 0-.123-.142c-.175-.005-.518.045-1.002.393-.483.347-.64.656-.692.824a.13.13 0 0 0 .095.164z"})))},{name:"vimeo",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M22.396 7.164q-.139 3.039-4.245 8.32Q13.907 21 10.97 21q-1.82 0-3.079-3.359l-1.68-6.159q-.934-3.36-2.005-3.36-.234.001-1.634.98l-.978-1.261q1.541-1.353 3.037-2.708 2.056-1.774 3.084-1.869 2.429-.234 2.99 3.321.607 3.836.841 4.769.7 3.181 1.542 3.181.653 0 1.963-2.065 1.307-2.063 1.401-3.142.187-1.781-1.401-1.782-.747.001-1.541.341 1.534-5.024 5.862-4.884 3.21.095 3.024 4.161"})))},{name:"vk",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{fillRule:"evenodd",d:"M1.687 1.687C0 3.374 0 6.09 0 11.52v.96c0 5.431 0 8.146 1.687 9.833S6.09 24 11.52 24h.96c5.431 0 8.146 0 9.833-1.687S24 17.91 24 12.48v-.96c0-5.431 0-8.146-1.687-9.833S17.91 0 12.48 0h-.96C6.09 0 3.374 0 1.687 1.687M4.05 7.3c.13 6.24 3.25 9.99 8.72 9.99h.31v-3.57c2.01.2 3.53 1.67 4.14 3.57h2.84c-.78-2.84-2.83-4.41-4.11-5.01 1.28-.74 3.08-2.54 3.51-4.98h-2.58c-.56 1.98-2.22 3.78-3.8 3.95V7.3H10.5v6.92c-1.6-.4-3.62-2.34-3.71-6.92z"})))},{name:"whatsapp",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"m2.048 22 1.406-5.136a9.9 9.9 0 0 1-1.323-4.955C2.133 6.446 6.579 2 12.042 2a9.85 9.85 0 0 1 7.011 2.906 9.85 9.85 0 0 1 2.9 7.011c-.002 5.464-4.448 9.91-9.91 9.91h-.004a9.9 9.9 0 0 1-4.736-1.206zm5.497-3.172.301.179a8.2 8.2 0 0 0 4.193 1.148h.003c4.54 0 8.235-3.695 8.237-8.237a8.2 8.2 0 0 0-2.41-5.828 8.18 8.18 0 0 0-5.824-2.416c-4.544 0-8.239 3.695-8.241 8.237a8.2 8.2 0 0 0 1.259 4.384l.196.312-.832 3.04zm9.49-4.554c-.062-.103-.227-.165-.475-.289s-1.465-.723-1.692-.806-.392-.124-.557.124-.64.806-.784.971-.289.186-.536.062-1.046-.385-1.991-1.229c-.736-.657-1.233-1.468-1.378-1.715s-.015-.382.109-.505c.111-.111.248-.289.371-.434.124-.145.165-.248.248-.413s.041-.31-.021-.434-.557-1.343-.763-1.839c-.202-.483-.407-.417-.559-.425-.144-.007-.31-.009-.475-.009a.9.9 0 0 0-.66.31c-.226.248-.866.847-.866 2.066s.887 2.396 1.011 2.562 1.746 2.666 4.23 3.739c.591.255 1.052.408 1.412.522.593.189 1.133.162 1.56.098.476-.071 1.465-.599 1.671-1.177.206-.58.206-1.075.145-1.179"})))},{name:"woocommerce",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M19 2H5C3.3 2 2 3.3 2 5v11c0 1.7 1.3 3 3 3h4l6 3-1-3h5c1.7 0 3-1.3 3-3V5c0-1.7-1.3-3-3-3m-1.6 4.5c-.4.8-.8 2.1-1 3.9-.3 1.8-.4 3.1-.3 4.1 0 .3 0 .5-.1.7s-.3.4-.6.4-.6-.1-.9-.4c-1-1-1.8-2.6-2.4-4.6-.7 1.4-1.2 2.4-1.6 3.1-.6 1.2-1.2 1.8-1.6 1.9-.3 0-.5-.2-.8-.7-.5-1.4-1.1-4.2-1.7-8.2 0-.3 0-.5.2-.7.1-.2.4-.3.7-.4.5 0 .9.2.9.8.3 2.3.7 4.2 1.1 5.7l2.4-4.5c.2-.4.4-.6.8-.6q.75 0 .9.9c.3 1.4.6 2.6 1 3.7.3-2.7.8-4.7 1.4-5.9.2-.3.4-.5.7-.5.2 0 .5.1.7.2q.3.3.3.6c0 .3 0 .4-.1.5"})))},{name:"wordpress",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M12.158 12.786 9.46 20.625a9 9 0 0 0 5.526-.144 1 1 0 0 1-.065-.124zM3.009 12a8.99 8.99 0 0 0 5.067 8.092L3.788 8.341A8.95 8.95 0 0 0 3.009 12m15.06-.454c0-1.112-.399-1.881-.741-2.48-.456-.741-.883-1.368-.883-2.109 0-.826.627-1.596 1.51-1.596q.06.002.116.007A8.96 8.96 0 0 0 12 3.009a8.98 8.98 0 0 0-7.512 4.052c.211.007.41.011.579.011.94 0 2.396-.114 2.396-.114.484-.028.541.684.057.741 0 0-.487.057-1.029.085l3.274 9.739 1.968-5.901-1.401-3.838c-.484-.028-.943-.085-.943-.085-.485-.029-.428-.769.057-.741 0 0 1.484.114 2.368.114.94 0 2.397-.114 2.397-.114.485-.028.542.684.057.741 0 0-.488.057-1.029.085l3.249 9.665.897-2.996q.684-1.753.684-2.907m1.82-3.86q.06.428.06.924c0 .912-.171 1.938-.684 3.22l-2.746 7.94a8.98 8.98 0 0 0 4.47-7.771 8.9 8.9 0 0 0-1.1-4.313M12 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10"})))},{name:"x",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M13.982 10.622 20.54 3h-1.554l-5.693 6.618L8.745 3H3.5l6.876 10.007L3.5 21h1.554l6.012-6.989L15.868 21h5.245zm-2.128 2.474-.697-.997-5.543-7.93H8l4.474 6.4.697.996 5.815 8.318h-2.387z"})))},{name:"xanga",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M9 9h6v6H9zM3 9h6V3H3zm12 0h6V3h-6zm0 12h6v-6h-6zM3 21h6v-6H3z"})))},{name:"youtube",svg:React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement("g",null,React.createElement("path",{d:"M21.8 8.001s-.195-1.378-.795-1.985c-.76-.797-1.613-.801-2.004-.847-2.799-.202-6.997-.202-6.997-.202h-.009s-4.198 0-6.997.202c-.39.047-1.242.051-2.003.847-.6.607-.795 1.985-.795 1.985S2 9.62 2 11.238v1.517c0 1.618.2 3.237.2 3.237s.195 1.378.795 1.985c.761.797 1.76.771 2.205.855 1.6.153 6.8.201 6.8.201s4.203-.006 7.001-.209c.391-.047 1.243-.051 2.004-.847.6-.607.795-1.985.795-1.985s.2-1.618.2-3.237v-1.517c0-1.618-.2-3.237-.2-3.237M9.935 14.594l-.001-5.62 5.404 2.82z"})))}]},58992:(e,t,a)=>{"use strict";a(96072);var r=a(28120),o=a.n(r),n=a(51609);a(91135);n.PureComponent,o().string.isRequired,o().number,o().func,o().string},17885:(e,t,a)=>{"use strict";a.d(t,{A:()=>E});var r=a(96072),o=a.n(r),n=a(51112),l=a(27723),s=a(51113),i=a(53512),c=a(83883),u=a(64969),d=a(13022),v=a(51609),p=a(38837),m=a(41526),h=a(55394),f=a(74923),g=a(65350),w=a(64526),b=a(51870),y=a(33981),x=a(51413),_=a(19686);const __=l.__,k=e=>`action-button-label-${e}`,E=({slug:e,additionalActions:t,primaryActionOverride:a,fixSiteConnectionHandler:r,setIsActionLoading:l,className:E,tracksIdentifier:C,labelSuffixId:j})=>{const{data:{ownedProducts:A}}=(0,g.A)(),[S,P]=(0,v.useState)(!1),[R,M]=(0,v.useState)({}),{detail:V,isLoading:z}=(0,f.A)(e),{manageUrl:H,purchaseUrl:L,managePaidPlanPurchaseUrl:O,renewPaidPlanPurchaseUrl:N,status:I,requiresUserConnection:B}=V,{siteIsRegistering:T,isRegistered:F,isUserConnected:D}=(0,b.A)(),G=!H,U=(0,v.useRef)(null),q=(0,v.useRef)(null),{recordEvent:Z}=(0,w.A)(),W=(0,y.A)(p.NM.ConnectionSkipPricing),{activate:$,isPending:J}=(0,m.A)(e),{install:K,isPending:Q}=(0,h.A)(e),Y=J||z||Q||T&&I===p.hp.SITE_CONNECTION_ERROR,X=t?.length>0,ee=A?.includes(e),te=`${k(e)} ${j||""}`.trim(),ae=(0,v.useMemo)((()=>({variant:Y?void 0:"primary",disabled:Y,size:"small",weight:"regular",className:E})),[Y,E]),re=(0,v.useCallback)((()=>{F&&D||!B?(Z(`jetpack_myjetpack_${C}_activate_click`,{product:e}),$()):W()}),[$,F,D,B,W,Z,e,C]),oe=(0,v.useCallback)((()=>{Z(`jetpack_myjetpack_${C}_learnmore_click`,{product:e})}),[e,Z,C]),ne=(0,v.useCallback)((()=>{Z(`jetpack_myjetpack_${C}_fixconnection_click`,{product:e})}),[e,Z,C]),le=(0,v.useCallback)((()=>{Z(`jetpack_myjetpack_${C}_add_click`,{product:e})}),[e,Z,C]),se=(0,v.useCallback)((()=>{Z(`jetpack_myjetpack_${C}_manage_click`,{product:e})}),[e,Z,C]),ie=(0,v.useCallback)((()=>{Z(`jetpack_myjetpack_${C}_install_standalone_plugin_click`,{product:e}),K()}),[e,K,Z,C]),ce=(0,v.useMemo)((()=>{switch(I){case p.hp.ABSENT:{const t=__("Learn more","jetpack-my-jetpack");return{...ae,href:`#/add-${e}`,variant:"primary",label:t,onClick:oe,"aria-labelledby":te,...a?.[p.hp.ABSENT]??{}}}case p.hp.ABSENT_WITH_PLAN:{const e=__("Install Plugin","jetpack-my-jetpack");return{...ae,variant:"primary",label:e,onClick:ie,"aria-labelledby":te,...a?.[p.hp.ABSENT_WITH_PLAN]??{}}}case p.hp.NEEDS_FIRST_SITE_CONNECTION:return{...ae,href:L||`#/add-${e}`,variant:"primary",label:__("Learn more","jetpack-my-jetpack"),onClick:le,"aria-labelledby":te,...a?.[p.hp.NEEDS_FIRST_SITE_CONNECTION]??{}};case p.hp.NEEDS_PLAN:{const t=__("Get plan","jetpack-my-jetpack"),r=__("Learn more","jetpack-my-jetpack"),o=ee?t:r;return{...ae,href:L||`#/add-${e}`,variant:"primary",label:o,onClick:le,"aria-labelledby":te,...a?.[p.hp.NEEDS_PLAN]??{}}}case p.hp.CAN_UPGRADE:return{...ae,href:L||`#/add-${e}`,variant:"primary",label:__("Upgrade","jetpack-my-jetpack"),onClick:le,"aria-labelledby":te,...a?.[p.hp.CAN_UPGRADE]??{}};case p.hp.ACTIVE:{const e=__("View","jetpack-my-jetpack");return{...ae,disabled:G||ae?.disabled,href:H,variant:"secondary",label:e,onClick:se,"aria-labelledby":te,...a?.[p.hp.ACTIVE]??{}}}case p.hp.SITE_CONNECTION_ERROR:return{...ae,variant:"primary",label:__("Connect","jetpack-my-jetpack"),onClick:r,"aria-labelledby":te,...a?.[p.hp.SITE_CONNECTION_ERROR]??{}};case p.hp.USER_CONNECTION_ERROR:return{href:"#/connection?skip_pricing=true",variant:"primary",label:__("Connect","jetpack-my-jetpack"),onClick:ne,"aria-labelledby":te,...a?.[p.hp.USER_CONNECTION_ERROR]??{}};case p.hp.INACTIVE:case p.hp.MODULE_DISABLED:case p.hp.NEEDS_ACTIVATION:return{...ae,variant:"secondary",label:__("Activate","jetpack-my-jetpack"),onClick:re,"aria-labelledby":te,...a?.[p.hp.INACTIVE]??{}};case p.hp.EXPIRING_SOON:return{...ae,href:N,variant:"primary",label:__("Renew my plan","jetpack-my-jetpack"),"aria-labelledby":te,...a?.[p.hp.EXPIRING_SOON]??{}};case p.hp.EXPIRED:return{...ae,href:O,variant:"primary",label:__("Resume my plan","jetpack-my-jetpack"),"aria-labelledby":te,...a?.[p.hp.EXPIRED]??{}};case p.hp.NEEDS_ATTENTION__ERROR:{const t={...ae,href:H,variant:"primary",label:__("Troubleshoot","jetpack-my-jetpack"),"aria-labelledby":te,...a?.[p.hp.NEEDS_ATTENTION__ERROR]??{}};switch(e){case"backup":return{...t,href:"https://jetpack.com/support/backup/troubleshooting-jetpack-backup/"};case"protect":return{...t,label:__("Fix threats","jetpack-my-jetpack")};default:return t}}case p.hp.NEEDS_ATTENTION__WARNING:{const t={...ae,href:H,variant:"primary",label:__("Troubleshoot","jetpack-my-jetpack"),"aria-labelledby":te,...a?.[p.hp.NEEDS_ATTENTION__WARNING]??{}};return"protect"===e?{...t,label:__("Fix threats","jetpack-my-jetpack")}:{...t}}default:return{...ae,href:L||`#/add-${e}`,label:__("Learn more","jetpack-my-jetpack"),onClick:le,"aria-labelledby":te}}}),[I,ae,e,L,G,H,a,ee,O,N,le,r,ne,re,ie,oe,se,te]),ue=(0,v.useMemo)((()=>X?[...t,ce]:[ce]),[t,ce,X]),de=(0,v.useCallback)((()=>{Z(`jetpack_myjetpack_${C}_dropdown_toggle`,{product:e,state:S?"closed":"open"})}),[S,Z,e,C]),ve=(0,v.useCallback)((()=>{P(!S),de()}),[S,de]);(0,v.useEffect)((()=>{M(ue[0])}),[ue]),(0,v.useEffect)((()=>{l&&l(Y)}),[Y,l]),(0,x.A)(U,(e=>{q.current.contains(e.target)||(P(!1),de())}));const pe=X&&React.createElement("div",{ref:U,className:_.A["action-button-dropdown"]},React.createElement("ul",{className:_.A["dropdown-menu"]},[...t,ce].map((({label:t,isExternalLink:a},r)=>React.createElement("li",{key:r},React.createElement("button",{onClick:()=>{M(ue[r]),P(!1),Z(`jetpack_myjetpack_${C}_dropdown_action_click`,{product:e,action:t})},className:_.A["dropdown-item"]},React.createElement("div",{className:_.A["dropdown-item-label"]},t,a&&React.createElement(s.A,{icon:i.A,size:16})),t===R.label&&React.createElement("div",{className:_.A["active-action-checkmark"]},React.createElement(s.A,{icon:c.A,size:24,fill:"white"}))))))));return React.createElement(React.Fragment,null,React.createElement("div",{className:(0,d.A)(_.A["action-button"],X?_.A["has-additional-actions"]:null)},React.createElement(n.A,o()({},ae,R,{id:k(e)}),R.label),X&&React.createElement("button",{className:(0,d.A)(_.A["dropdown-chevron"],"primary"===R.variant?_.A.primary:_.A.secondary),onClick:ve,ref:q},React.createElement(s.A,{icon:u.A,size:24,fill:"primary"===R.variant?"white":"black"})),S&&pe))}},96214:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(51112),o=a(27723);const __=o.__,n=e=>{const{shouldShowButton:t=()=>!0,...a}={size:"small",variant:"secondary",weight:"regular",label:__("Learn more","jetpack-my-jetpack"),...e};return!!t()&&React.createElement(r.A,a,a.label)}},48848:(e,t,a)=>{"use strict";a.d(t,{A:()=>f});var r=a(42947),o=a(75918),n=a(28509),l=a(41040),s=a(85985),i=a(51609),c=a.n(i),u=a(31504),d=a(40357),v=a(68242),p=a(64526),m=a(51870),h=a(11617);function f(){const{recordEvent:e}=(0,p.A)(),{data:t=[],isLoading:a}=(0,d.A)({name:u.Md,queryFn:async e=>(await e.getUserLicenses())?.items}),{userConnectionData:f}=(0,m.A)(),[g,w]=(0,i.useState)(!1),b=f?.currentUser?.wpcomUser?.display_name||f?.currentUser?.wpcomUser?.login||f?.currentUser?.username,y=(0,i.useCallback)((()=>{e("jetpack_myjetpack_license_activation_back_link_click")}),[e]),x=(0,i.useCallback)((()=>{w(!0)}),[]),_=(0,i.useMemo)((()=>t.filter((({attached_at:e,revoked_at:t})=>null===e&&null===t))),[t]),{siteSuffix:k="",adminUrl:E=""}=(0,v.A$)();return c().createElement(r.A,{showHeader:!1,showBackground:!1,useInternalLinks:(0,s.pg)()},c().createElement(o.A,{horizontalSpacing:3,horizontalGap:3},c().createElement(n.A,null,c().createElement(h.A,{onClick:y,reload:g})),c().createElement(n.A,null,c().createElement(l.b,{currentRecommendationsStep:null,availableLicenses:_,fetchingAvailableLicenses:a,onActivationSuccess:x,siteAdminUrl:E,siteRawUrl:k,displayName:b}))))}},62450:(e,t,a)=>{"use strict";a.d(t,{A:()=>u,O:()=>i});var r=a(47425),o=a(13022),n=a(28120),l=a.n(n),s=a(8757);const i=e=>{const{children:t,className:a,onMouseEnter:r,onMouseLeave:n}=e,l=(0,o.A)(s.A.container,a);return React.createElement("div",{onMouseEnter:r,onMouseLeave:n,onFocus:r,onBlur:n,className:l},t)},c=e=>{const{title:t,headerRightContent:a,className:o,children:n,onMouseEnter:l,onMouseLeave:c,titleId:u}=e;return React.createElement(i,{className:o,onMouseEnter:l,onMouseLeave:c},React.createElement("div",{className:s.A.title},React.createElement("div",{className:s.A.name},React.createElement(r.Ay,{variant:"title-medium",id:u||null},t)),a),n)};c.propTypes={children:l().node,title:l().string.isRequired,className:l().string,headerRightContent:l().node,onMouseEnter:l().func,onMouseLeave:l().func,titleId:l().string};const u=c},72191:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(51113),o=a(10991),n=a(13022),l=a(51609),s=a.n(l),i=a(70028),c=a(91469);const u=({className:e,accessibleName:t})=>s().createElement(i.N_,{to:"/",className:(0,n.A)(c.A.link,e),"aria-label":t||null},s().createElement(r.A,{icon:o.A,className:c.A.icon}))},6176:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(47425),o=a(51609),n=a(74923),l=a(51870),s=a(72434),i=a(5410);const c=({admin:e,recommendation:t,slug:a,children:c,isDataLoading:u,Description:d=null,additionalActions:v=null,secondaryAction:p=null,upgradeInInterstitial:m=!1,primaryActionOverride:h,onMouseEnter:f,onMouseLeave:g,customLoadTracks:w})=>{const{isRegistered:b}=(0,l.A)(),{detail:y,refetch:x}=(0,n.A)(a),{name:_,description:k,status:E,manageUrl:C}=y;return(0,o.useEffect)((()=>{b&&x()}),[b,E,x]),React.createElement(i.Ay,{name:_,Description:d||(()=>{const e=(0,s.A)(k);return React.createElement(r.Ay,{variant:"body-small",style:{flexGrow:1,marginBottom:"1rem"}},e)}),status:E,admin:e,recommendation:t,isDataLoading:u,additionalActions:v,primaryActionOverride:h,secondaryAction:p,slug:a,upgradeInInterstitial:m,onMouseEnter:f,onMouseLeave:g,customLoadTracks:w,manageUrl:C},c)}},15403:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var r=a(96072),o=a.n(r),n=a(3924),l=a(39384),s=a(56427),i=a(27723),c=a(51113),u=a(53512),d=a(18395),v=a(96007);const __=i.__,p=e=>{const{title:t}=e;return React.createElement(l.ConnectScreen,o()({buttonLabel:__("Connect your user account","jetpack-my-jetpack"),loadingLabel:__("Connecting your account…","jetpack-my-jetpack"),images:[d],from:"my-jetpack"},e,{title:t||__("Unlock all the amazing features of Jetpack by connecting now","jetpack-my-jetpack")}),React.createElement("ul",{role:"list"},React.createElement("li",null,__("Receive instant downtime alerts","jetpack-my-jetpack")),React.createElement("li",null,__("Automatically share your content on social media","jetpack-my-jetpack")),React.createElement("li",null,__("Let your subscribers know when you post","jetpack-my-jetpack")),React.createElement("li",null,__("Receive notifications about new likes and comments","jetpack-my-jetpack")),React.createElement("li",null,__("Let visitors share your content on social media","jetpack-my-jetpack")),React.createElement("li",null,__("Create better content with powerful AI tools","jetpack-my-jetpack")),React.createElement("li",null,__("And more!","jetpack-my-jetpack")," ",React.createElement("a",{href:(0,n.A)("jetpack-features"),target:"_blank",className:v.A["all-features"],rel:"noreferrer"},__("See all Jetpack features","jetpack-my-jetpack"),React.createElement(c.A,{icon:u.A}),React.createElement(s.VisuallyHidden,{as:"span"},/* translators: accessibility text */ -__("(opens in a new tab)","jetpack-my-jetpack"))))))}},85242:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(27723),o=a(42822),n=a(35975),l=a(35519),s=a(96007),i=a(6579);const __=r.__,c=()=>React.createElement(React.Fragment,null,React.createElement("div",{className:s.A["account-description"]},__("On the next screen, you can connect with an existing account from any of these services or create a new one.","jetpack-my-jetpack")),React.createElement("ul",{className:s.A["account-images"],role:"list"},React.createElement("li",null,React.createElement("img",{src:i,className:s.A.wordpress,alt:"WordPress.com"})),React.createElement("li",null,React.createElement("img",{src:l,className:s.A.google,alt:"Google"})),React.createElement("li",null,React.createElement("img",{src:o,className:s.A.apple,alt:"Apple"})),React.createElement("li",null,React.createElement("img",{src:n,className:s.A.github,alt:"GitHub"}))))},91499:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var r=a(42947),o=a(75918),n=a(28509),l=a(85985),s=a(27723),i=a(70028),c=a(51870),u=a(25994),d=a(72191),v=a(15403),p=a(85242),m=a(96007);const __=s.__,h=()=>{const[e]=(0,i.ok)(),t="true"===e.get("skip_pricing"),a=(0,u.A)(),{apiRoot:s,apiNonce:h,registrationNonce:f}=(0,c.A)();return React.createElement(r.A,{showHeader:!1,showBackground:!1,useInternalLinks:(0,l.pg)()},React.createElement(o.A,{horizontalSpacing:8,horizontalGap:0},React.createElement(n.A,{className:m.A["relative-col"]},React.createElement(d.A,{className:m.A["close-link"],accessibleName:__("Go back to previous screen","jetpack-my-jetpack")})),React.createElement(n.A,null,React.createElement(v.A,{from:"my-jetpack",redirectUri:a,apiRoot:s,apiNonce:h,registrationNonce:f,skipPricingPage:t,footer:React.createElement(p.A,null)}))))}},84596:(e,t,a)=>{"use strict";a.d(t,{A:()=>S});var r=a(47425),o=a(51112),n=a(3924),l=a(39384),s=a(47143),i=a(27723),c=a(83883),u=a(19783),d=a(7827),v=a(51113),p=a(13022),m=a(51609),h=a(488),f=a(68242),g=a(18117),w=a(64526),b=a(36312),y=a(51870),x=a(95042),_=a(33168),k=a(17757),E=a(87319),C=a(15200);const __=i.__,j=({text:e,actionText:t,onClick:a,status:o="success"})=>{let n=c.A,l="";return"info"===o&&(n=null,l=""),"success"===o&&(n=c.A,l=C.A.success),"error"===o&&(n=u.A,l=C.A.error),"warning"===o&&(n=u.A,l=C.A.warning),"unlock"===o&&(n=d.A,l=""),React.createElement("div",{className:C.A["list-item"]},React.createElement(r.Ay,{className:(0,p.A)(C.A["list-item-text"],l)},n&&React.createElement(v.A,{icon:n}),React.createElement("span",null,e)),t&&"success"!==o&&React.createElement(A,{actionText:t,onClick:a}))},A=({actionText:e,onClick:t})=>React.createElement(o.A,{variant:"link",weight:"regular",onClick:t},e),S=({apiRoot:e,apiNonce:t,redirectUri:a=null,title:c=__("Connection","jetpack-my-jetpack"),connectionInfoText:u=__("Jetpack connects your site and user account to the WordPress.com cloud to provide more powerful features.","jetpack-my-jetpack"),onDisconnected:d,connectedPlugins:v,connectedSiteId:S,context:P,onConnectUser:R=null})=>{const{isRegistered:M,isUserConnected:V,userConnectionData:z,hasConnectedOwner:H}=(0,y.A)({redirectUri:a}),{siteIsRegistering:L}=(0,y.A)({skipUserConnection:!0,redirectUri:a}),{lifecycleStats:O}=(0,f.A$)(),{recordEvent:N}=(0,w.A)(),[I,B]=(0,m.useState)(!1),{setConnectionStatus:T,setUserIsConnecting:F}=(0,s.useDispatch)(l.CONNECTION_STORE_ID),D=R||F,G=z.currentUser?.wpcomUser?.avatar,U=z.currentUser?.permissions?.manage_options,{brokenModules:q}=O||{},{data:Z,isLoading:W,isError:$}=(0,h.V)(),J=(0,m.useMemo)((()=>!W&&!$&&(0,g.A)(Z).length>0),[W,$,Z]),K=q?.needs_user_connection.length>0,Q=q?.needs_site_connection.length>0,Y=(0,m.useMemo)((()=>({user_connection_broken_modules:q?.needs_user_connection.join(", "),site_connection_broken_modules:q?.needs_site_connection.join(", ")})),[q]),X=(0,m.useCallback)((e=>t=>{t&&t.preventDefault(),N("jetpack_myjetpack_connection_manage_dialog_click",{...Y,connection_type:e}),B(!0)}),[N,B,Y]),ee=X("user"),te=X("site"),ae=(0,m.useCallback)((e=>{e&&e.preventDefault(),B(!1)}),[B]),re=(0,m.useCallback)((e=>{e&&e.preventDefault(),T({isActive:!1,isRegistered:!1,isUserConnected:!1}),d?.()}),[d,T]),oe=(0,m.useCallback)((e=>{e&&e.preventDefault(),T({isUserConnected:!1}),d?.()}),[d,T]),ne=(0,m.useCallback)((()=>{N("jetpack_myjetpack_connection_learnmore_link_click",Y)}),[N,Y]),le=(0,m.useCallback)((e=>{e&&e.preventDefault(),N("jetpack_myjetpack_connection_connect_user_click",Y),D()}),[D,N,Y]),{connectSite:se}=(0,b.A)({tracksInfo:{event:"jetpack_myjetpack_connection_connect_site",properties:Y}}),ie=(({isRegistered:e,hasSiteConnectionBrokenModules:t,handleConnectSite:a,siteIsRegistering:r,openManageSiteConnectionDialog:o})=>r?{text:__("Connecting your site…","jetpack-my-jetpack"),status:"info"}:e?{onClick:o,text:__("Site connected.","jetpack-my-jetpack"),actionText:__("Manage","jetpack-my-jetpack"),status:"success"}:t?{onClick:a,text:__("Missing site connection to enable some features.","jetpack-my-jetpack"),actionText:__("Connect","jetpack-my-jetpack"),status:"error"}:{onClick:a,text:__("Start with Jetpack.","jetpack-my-jetpack"),actionText:__("Connect your site with one click","jetpack-my-jetpack"),status:"warning"})({isRegistered:M,hasSiteConnectionBrokenModules:Q,handleConnectSite:se,siteIsRegistering:L,openManageSiteConnectionDialog:te}),ce=(({hasProductsThatRequireUserConnection:e,hasUserConnectionBrokenModules:t,isUserConnected:a,hasConnectedOwner:r,userConnectionData:o,openManageUserConnectionDialog:n,handleConnectUser:l})=>{if(!o.currentUser?.permissions?.manage_options&&!a&&!r)return{text:__("A site admin will need to connect before you are able to sign in","jetpack-my-jetpack"),status:"warning"};if(!e&&!t&&!a)return{onClick:l,text:__("Unlock more of Jetpack","jetpack-my-jetpack"),actionText:__("Sign in","jetpack-my-jetpack"),status:"unlock"};if(e&&!a&&!t){let e=__("Some features require authentication.","jetpack-my-jetpack");return o.currentUser?.permissions?.manage_options||(e=__("Unlock more of Jetpack","jetpack-my-jetpack")),{onClick:l,text:e,actionText:__("Sign in","jetpack-my-jetpack"),status:"warning"}}if(t)return{onClick:l,text:__("Missing authentication to enable all features.","jetpack-my-jetpack"),actionText:__("Sign in","jetpack-my-jetpack"),status:"error"};let s=null;return s=o.currentUser?.isMaster?o.currentUser?.wpcomUser?.display_name?(0,i.sprintf)(/* translators: %1$s is user name, %2$s is the user email */ -__("Connected as %1$s (Owner) (%2$s).","jetpack-my-jetpack"),o.currentUser?.wpcomUser?.display_name,o.currentUser?.wpcomUser?.email):__("User connected (Owner).","jetpack-my-jetpack"):o.currentUser?.wpcomUser?.display_name?(0,i.sprintf)(/* translators: %1$s is user name, %2$s is the user email */ -__("Connected as %1$s (%2$s).","jetpack-my-jetpack"),o.currentUser?.wpcomUser?.display_name,o.currentUser?.wpcomUser?.email):__("User connected.","jetpack-my-jetpack"),{onClick:n,actionText:__("Manage","jetpack-my-jetpack"),text:s,status:"success"}})({hasProductsThatRequireUserConnection:J,hasUserConnectionBrokenModules:K,isUserConnected:V,hasConnectedOwner:H,userConnectionData:z,openManageUserConnectionDialog:ee,handleConnectUser:le});return React.createElement("div",{className:C.A["connection-status-card"]},React.createElement(r.H3,null,c),React.createElement(r.Ay,{variant:"body",mb:3},`${u} `,React.createElement(o.A,{href:(0,n.A)("why-the-wordpress-com-connection-is-important-for-jetpack"),variant:"link",weight:"regular",isExternalLink:!0,onClick:ne},__("Learn more about connections","jetpack-my-jetpack"))),React.createElement("div",{className:C.A.status},React.createElement("img",{src:x,alt:"",className:C.A.cloud}),React.createElement("div",{className:(0,p.A)(C.A.line,M?"":Q?C.A.error:C.A.warning)}),React.createElement("div",{className:C.A["avatar-wrapper"]},React.createElement("img",{src:M?E:k,alt:"",className:C.A.jetpack}),(J||K)&&React.createElement("img",{src:V&&G?G:_,alt:"",className:C.A.avatar})),(M&&U||V)&&React.createElement("div",{className:C.A["connect-action"]},React.createElement(A,{onClick:te,actionText:__("Manage","jetpack-my-jetpack")}))),React.createElement("div",null,React.createElement(j,ie),z?.connectionOwner&&!z.currentUser?.isMaster&&React.createElement(j,{text:(0,i.sprintf)(/* translators: placeholder is the username of the Jetpack connection owner */ -__("Also connected: %s (Owner).","jetpack-my-jetpack"),z.connectionOwner)}),M&&React.createElement(j,ce)),React.createElement(l.ManageConnectionDialog,{apiRoot:e,apiNonce:t,onDisconnected:re,onUnlinked:oe,connectedPlugins:v,connectedSiteId:S,connectedUser:z,isOpen:I,onClose:ae,context:P}))}},43593:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(51609),o=a(38837),n=a(488),l=a(18117),s=a(51870),i=a(33981),c=a(84596);function u(){const{apiRoot:e,apiNonce:t,topJetpackMenuItemUrl:a,connectedPlugins:u}=(0,s.A)(),d=(0,i.A)(o.NM.ConnectionSkipPricing),{data:v,isLoading:p,isError:m}=(0,n.V)(),h=(0,r.useMemo)((()=>p||m?[]:(0,l.A)(v)),[v,p,m]);return React.createElement(c.A,{apiRoot:e,apiNonce:t,redirectUri:a,onConnectUser:d,connectedPlugins:u,requiresUserConnection:h.length>0,onDisconnected:()=>document?.location?.reload(!0)})}},35167:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(75918),o=a(28509),n=a(47425),l=a(56427),s=a(27723),i=a(42778),c=a(68888),u=a(29115),d=a(13022),v=a(51609),p=a(83804),m=a(64526),h=a(81434),f=a(89674),g=a(66746);const __=s.__,_n=s._n,w=()=>{const e=(0,v.useRef)(null),{recordEvent:t}=(0,m.A)(),{recommendedModules:a,redoEvaluation:s,removeEvaluationResult:w,isProductOwnershipLoading:b}=(0,p.A)(),[y,x]=(0,v.useState)(!0),[_,k]=(0,v.useState)(!1),E=(0,v.useCallback)((()=>{if(e.current){const{scrollLeft:t,scrollWidth:a,clientWidth:r}=e.current;x(0===t),k(t+r>=a)}}),[e]),C=(e,t,a=24)=>{if(e.current){const r=e.current.querySelector("li").clientWidth;e.current.scrollBy({left:t*(r+a),behavior:"smooth"})}},j=(0,v.useCallback)((()=>{C(e,1),t("jetpack_myjetpack_recommendations_slide_arrow_click",{direction:"next"})}),[t,e]),A=(0,v.useCallback)((()=>{C(e,-1),t("jetpack_myjetpack_recommendations_slide_arrow_click",{direction:"previous"})}),[t,e]),S=_n("Our recommendation for you","Our recommendations for you",a.length,"jetpack-my-jetpack"),P=__("Redo","jetpack-my-jetpack"),R=__("Dismiss","jetpack-my-jetpack");return(0,v.useEffect)((()=>{const t=e.current;if(t)return t.addEventListener("scroll",E),E(),()=>{t.removeEventListener("scroll",E)}}),[E]),(0,v.useEffect)((()=>{t("jetpack_myjetpack_evaluation_recommendations_view",{modules:a})}),[a,t]),React.createElement(r.A,{horizontalGap:2,horizontalSpacing:6},React.createElement(o.A,null,React.createElement(l.Flex,null,React.createElement(l.FlexItem,null,React.createElement(n.Ay,{variant:"headline-small",className:g.A.title},S),React.createElement(n.Ay,null,__("Here are the tools that we think will help you reach your website goals:","jetpack-my-jetpack"))),React.createElement(l.FlexItem,null,React.createElement(l.DropdownMenu,{menuProps:{className:g.A["dropdown-menu"]},popoverProps:{position:"bottom left"},icon:i.A,label:__("Recommendations menu","jetpack-my-jetpack"),controls:[{title:P,onClick:s},{title:R,onClick:w}]})))),React.createElement(o.A,null,React.createElement(r.A,{ref:e,tagName:"ul",className:g.A["recommendations-list"],horizontalGap:4,horizontalSpacing:2,fluid:!0},a.map((e=>{const t=e.replace("feature_",""),a=f.z[t];return b?React.createElement(o.A,{tagName:"li",key:e,lg:4},React.createElement(h.A,{width:"100%",height:"200px"})):a&&React.createElement(o.A,{tagName:"li",key:e,lg:4},React.createElement(a,{recommendation:!0}))}))),React.createElement(l.Flex,{align:"center",justify:"center"},React.createElement(l.FlexItem,null,React.createElement(l.Button,{className:(0,d.A)(g.A["slider-button"],g.A["prev-button"]),onClick:A,disabled:y,"aria-disabled":y,"aria-label":__("Previous","jetpack-my-jetpack")},React.createElement(l.Icon,{icon:c.A}))),React.createElement(l.FlexItem,null,React.createElement(l.Button,{className:(0,d.A)(g.A["slider-button"],g.A["next-button"]),onClick:j,disabled:_,"aria-disabled":_,"aria-label":__("Next","jetpack-my-jetpack")},React.createElement(l.Icon,{icon:u.A}))))))}},11617:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(27723),o=a(51113),n=a(7474),l=a(51609),s=a.n(l),i=a(70028),c=a(21751);const __=r.__;const u=function({onClick:e=()=>{},reload:t}){const a=t?"/?reload=true":"/";return s().createElement(i.N_,{to:a,className:c.A.link,onClick:e},s().createElement(o.A,{icon:n.A,className:c.A.icon}),__("Go back","jetpack-my-jetpack"))}},1651:(e,t,a)=>{"use strict";a.d(t,{k:()=>d});var r=a(51112),o=a(78478),n=a(56427),l=a(38443),s=a(27723),i=a(13022),c=a(51609),u=a(32976);a(71587);const __=s.__;function d({productName:e,giftedDate:t}){const[a,d]=(0,c.useState)(!1),v=(0,c.useCallback)((()=>d(!0)),[d]),p={position:"top center",placement:"top",animate:!0,noArrow:!1,resize:!1,flip:!1,offset:6,focusOnMount:"container",onClose:(0,c.useCallback)((()=>d(!1)),[d]),className:u.A.container},m=(0,i.A)(u.A.wrapper,"golden-token-icon-tooltip");return React.createElement("div",{className:m},React.createElement(r.A,{variant:"link",onClick:v},React.createElement(o.sT,{className:u.A.logo})),React.createElement("div",{className:u.A.helper},a&&React.createElement(n.Popover,p,React.createElement("div",null,React.createElement("div",{className:u.A.title},e),React.createElement("div",{className:u.A.content},(0,s.sprintf)( -// translators: %1$s is a product name, %2$s is the date the product was gifted. -__("%1$s was gifted on %2$s. It gives you access to a lifetime subscription of Jetpack VaultPress Backup and Jetpack Scan.","jetpack-my-jetpack"),e,(0,l.dateI18n)("F j, Y",t)))))))}},56894:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(56427),o=a(51609),n=a.n(o),l=a(90530);const s=function(){const[e,t]=(0,o.useState)(!0),a=(0,o.useCallback)((()=>t(!1)),[]);if(!e)return null;if(!Object.hasOwn(window,"JP_IDENTITY_CRISIS__INITIAL_STATE"))return null;const{containerID:s,isSafeModeConfirmed:i}=window.JP_IDENTITY_CRISIS__INITIAL_STATE;return!s||i?null:n().createElement(r.Modal,{onRequestClose:a,overlayClassName:l.A.modal},n().createElement("div",{id:s,className:l.A.container}))}},12660:(e,t,a)=>{"use strict";a.d(t,{I:()=>u});var r=a(96072),o=a.n(r),n=a(11883),l=a(56427),s=a(29491),i=a(51609),c=a(64526);a(42997);const u=({children:e,className:t,icon:a="info-outline",iconSize:r=14,tracksEventName:u,tracksEventProps:d={},...v})=>{const{recordEvent:p}=(0,c.A)(),m=(0,i.useRef)(),h=(0,s.useViewportMatch)("medium","<"),[f,g]=(0,i.useState)(!1),w=(0,i.useCallback)((()=>g((e=>(!0==!e&&u&&p(`jetpack_${u}`,{page:"my-jetpack",...d}),!e)))),[p,u,d]),b=(0,i.useCallback)((()=>{m.current&&!m.current.contains(m.current.ownerDocument.activeElement)&&g(!1)}),[g,m]);return React.createElement("span",{className:t},React.createElement("button",{className:"info-tooltip__button",onClick:w,ref:m},React.createElement(n.A,{icon:a,size:r})),f&&React.createElement(l.Popover,o()({placement:h?"top-end":"right",noArrow:!1,offset:10,focusOnMount:"container",onClose:b},v),React.createElement("div",{className:"info-tooltip__content"},e)))}},23449:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(67506),o=a(3924),n=a(27723),l=a(51609),s=a.n(l),i=a(64526),c=a(64576);const __=n.__,u=e=>{const{isAgencyAccount:t=!1}=e,{recordEvent:a}=(0,i.A)();(0,l.useEffect)((()=>{a("jetpack_myjetpack_manage_banner_view",{})}),[a]);const n=(0,l.useCallback)((e=>{a("jetpack_myjetpack_manage_banner_click",{target:e,feature:"manage"})}),[a]),u=(0,l.useCallback)((()=>{n("jp-agencies-register-interest")}),[n]);return t?null:s().createElement(r.A,{icon:c,title:__("Manage client sites and grow your business","jetpack-my-jetpack"),description:__("Are you an agency or freelancer? We’re working on a new partnership program bringing together the best of Jetpack, Woo, WordPress.com, and Pressable. Get bulk discounts, referral commissions, and more.","jetpack-my-jetpack"),primaryCtaLabel:__("Sign up now","jetpack-my-jetpack"),primaryCtaURL:(0,o.A)("jetpack-for-agencies-register-interest"),primaryCtaIsExternalLink:!0,primaryCtaOnClick:u})}},81434:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(13022),o=a(99633);const n=({height:e,width:t,spaceBelow:a=!1})=>React.createElement("div",{className:(0,r.A)(o.A.skeleton,a&&o.A.spaceBelow),style:{height:e,width:t}})},52912:(e,t,a)=>{"use strict";a.d(t,{A:()=>G});var r=a(96072),o=a.n(r),n=a(60442),l=a(18089),s=a(47656),i=a(42947),c=a(59244),u=a(75918),d=a(28509),v=a(95640),p=a(18587),m=a(85985),h=a(27723),f=a(13022),g=a(51609),w=a(76007),b=a(41521),y=a(31504),x=a(83804),_=a(58402),k=a(62902),E=a(280),C=a(68242),j=a(16700),A=a(13244),S=a(89812),P=a(64526),R=a(31368),M=a(51870),V=a(7436),z=a(43593),H=a(35167),L=a(56894),O=a(23449),N=a(81434),I=a(78932),B=a(25487),T=a(36007),F=a(67328);const __=h.__,_x=h._x,D=({message:e,title:t,options:a})=>{const{recordEvent:r}=(0,P.A)();(0,g.useEffect)((()=>{const e=a?.tracksArgs||{};r("jetpack_myjetpack_global_notice_view",{notice_id:a.id,...e})}),[a.id,r,a?.tracksArgs]);const[i]=(0,n.A)(["md"],[">"]),c=a.actions?.map((e=>React.createElement(l.A,o()({key:e.key||e.label,customClass:F.A.cta},e))));return React.createElement("div",{className:(0,f.A)(F.A.notice,{[F.A["bigger-than-medium"]]:i})},React.createElement(s.A,o()({hideCloseButton:!0},a,{title:t,actions:c}),React.createElement("div",{className:F.A.message},e)))};function G(){const[e,t]=(0,g.useState)({isLoading:!1,variation:"control"});(0,V.A)();const{isAtomic:a=!1,adminUrl:r,sandboxedDomain:o,isDevVersion:n,userIsAdmin:l}=(0,C.A$)(),{isWelcomeBannerVisible:s}=(0,S.A)(),{isSectionVisible:h}=(0,x.A)(),{siteIsRegistered:f,apiRoot:G,apiNonce:U}=(0,M.A)(),{currentNotice:q}=(0,g.useContext)(w.g),{message:Z,title:W,options:$}=q||{},{data:J,isLoading:K}=(0,E.A)({name:y._,query:{path:y.rR}}),{data:Q,isLoading:Y}=(0,E.A)({name:y.nw,query:{path:y.O2}}),{data:X,isLoading:ee,isError:te}=(0,E.A)({name:y.uh,query:{path:y.jr}}),{data:ae,isLoading:re,isError:oe}=(0,k.A)(),ne=(0,_.A)();(0,g.useEffect)((()=>{ne()}),[ne]);const le=J?.is_available,se=Q?.user?.jwt,ie=!Y&&!K&&le&&se,ce=(0,R.A)(),{recordEvent:ue}=(0,P.A)(),[de,ve]=(0,g.useState)(!1);if((0,g.useLayoutEffect)((()=>{let e={};!oe&&Object.keys(ae)?.length&&(e={red_bubble_alerts:Object.keys(ae).join(",")}),re||ue("jetpack_myjetpack_page_view",{...e})}),[ue,ae,oe,re]),window.location.hash.includes("?reload=true")&&(window.history.replaceState(null,"",window.location.href.replace("?reload=true","")),window.location.reload(),ve(!0)),de)return null;const pe={label:_x("Reset Options (dev only)","Button for option to reset Jetpack Options","jetpack-my-jetpack"),title:__("Reset Options","jetpack-my-jetpack"),role:"button",onClick:()=>(0,A.A)(),onKeyDown:e=>(0,j.A)(e,(()=>(0,A.A)()))};return React.createElement(i.A,{siteAdminUrl:r,sandboxedDomain:o,apiRoot:G,apiNonce:U,optionalMenuItems:n&&l?[pe]:[],useInternalLinks:(0,m.pg)()},React.createElement("h1",{className:"screen-reader-text"},__("My Jetpack","jetpack-my-jetpack")),React.createElement("hr",{className:F.A.separator}),React.createElement(L.A,null),React.createElement(c.D,null),!ce&&React.createElement(u.A,{horizontalSpacing:0},React.createElement(d.A,null,React.createElement("div",{id:"jp-admin-notices",className:"my-jetpack-jitm-card"}))),s&&l?React.createElement(T.A,{welcomeFlowExperiment:e,setWelcomeFlowExperiment:t},Z&&(f||$?.id===b.l.options.id)&&React.createElement(D,{message:Z,title:W,options:$})):Z&&React.createElement(u.A,{horizontalSpacing:3,horizontalGap:3},React.createElement(d.A,null,React.createElement(D,{message:Z,title:W,options:$}))),!s&&h&&l&&React.createElement(H.A,null),React.createElement(B.A,null),l&&React.createElement(u.A,{horizontalSpacing:6,horizontalGap:Z?3:6},React.createElement(d.A,null,ee?React.createElement(N.A,{height:"200px",width:"100%"}):!te&&X.isEnabled&&React.createElement(O.A,{isAgencyAccount:X.isAgencyAccount}))),React.createElement(v.A,null,React.createElement(u.A,{horizontalSpacing:8},React.createElement(d.A,{sm:4,md:4,lg:6},React.createElement(I.A,null)),React.createElement(d.A,{sm:4,md:4,lg:6},!a&&React.createElement(z.A,null)))),ie&&React.createElement(p.A,{jwt_token:se}))}},63291:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(47425),o=a(85879),n=a(27723),l=a(72434),s=a(89675),i=a(3775),c=a(42162);const __=n.__,u=()=>React.createElement("div",{className:s.A.separator},React.createElement("div",{className:s.A.line}),React.createElement("span",null,__("or","jetpack-my-jetpack")),React.createElement("div",{className:s.A.line})),d=()=>{const e=__("Start with Jetpack for free","jetpack-my-jetpack"),t=__("Log in with your WordPress.com account to supercharge your site with powerful growth, performance, and security tools.","jetpack-my-jetpack");return React.createElement("div",{className:s.A["connection-form"]},React.createElement(r.Ay,{variant:"headline-medium",className:s.A.title},(0,l.A)(e)),React.createElement(r.Ay,{variant:"body",className:s.A.description},(0,l.A)(t)),React.createElement(c.A,{service:"google"}),React.createElement(c.A,{service:"apple"}),React.createElement(c.A,{service:"github"}),React.createElement(c.A,{service:"jetpack"}),React.createElement(u,null),React.createElement(i.A,{isDisabled:!1}),React.createElement(o.A,{isTextOnly:!0,className:s.A.tos}))}},3775:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(27723),o=a(51609),n=a(89675);const __=r.__,l=({isDisabled:e})=>{const[t,a]=(0,o.useState)(""),r=(0,o.useCallback)((e=>{a(e.target.value)}),[a]),l=(0,o.useCallback)((e=>{e.preventDefault()}),[]);return React.createElement("form",{onSubmit:l,className:n.A["email-input-container"]},React.createElement("input",{className:n.A["email-input"],type:"email",autoComplete:"email",spellCheck:!1,autoCorrect:"off",name:"user-email",placeholder:__("Enter your email address","jetpack-my-jetpack"),value:t,disabled:e,onInput:r}),React.createElement("button",{className:n.A["submit-button"],disabled:e||!t},__("Start with email","jetpack-my-jetpack")))}},42162:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(27723),o=a(33320),n=a(70261),l=a(71909),s=a(38846),i=a(89675);const __=r.__,c=({service:e})=>{const t={google:{label:__("Start with Google","jetpack-my-jetpack"),icon:l},apple:{label:__("Start with Apple","jetpack-my-jetpack"),icon:o},github:{label:__("Start with GitHub","jetpack-my-jetpack"),icon:n},jetpack:{label:__("Start with Jetpack app","jetpack-my-jetpack"),icon:s}};return React.createElement("button",{className:i.A["social-button"]},React.createElement("img",{src:t[e].icon,alt:t[e].label}),React.createElement("span",{className:i.A["social-button-text"]},t[e].label))}},87494:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(75918),o=a(67142),n=a(28509),l=a(13022),s=a(65049),i=a(63291),c=a(91912),u=a(20260);const d=()=>((0,s.x)(),React.createElement(r.A,{horizontalSpacing:3,horizontalGap:0,className:u.A["onboarding-screen"]},React.createElement(o.A,{height:24,showText:!1,className:u.A["jetpack-logo"]}),React.createElement(n.A,{sm:4,md:4,lg:6,className:(0,l.A)(u.A.column,u.A["primary-column"])},React.createElement(i.A,null)),React.createElement(n.A,{sm:4,md:4,lg:6,className:(0,l.A)(u.A.column,u.A["seconday-column"],u.A.testimonials)},React.createElement("img",{src:c,alt:"Onboarding Screen"}))))},78932:(e,t,a)=>{"use strict";a.d(t,{A:()=>j});var r=a(47425),o=a(51112),n=a(38443),l=a(27723),s=a(13022),i=a(51609),c=a(38837),u=a(31504),d=a(74923),v=a(280),p=a(68242),m=a(64526),h=a(51870),f=a(33981),g=a(46256),w=a(93542),b=a(28252),y=a(1651),x=a(5423);const __=l.__,_n=l._n,_=({purchase:e})=>{const{product_name:t}=e;return React.createElement("div",{className:x.A["plan-container"]},React.createElement(r.hE,null,t),React.createElement(k,{purchase:e}))},k=({purchase:e})=>{const{ID:t,expiry_date:a,expiry_status:u,partner_name:d,product_name:v,product_slug:p,subscribed_date:m,domain:h}=e,f=`https://wordpress.com/me/purchases/${h}/${t}`,g=`https://wordpress.com/checkout/${p}/renew/${t}/${h}`,w=c.hp.EXPIRED===u,_=c.hp.EXPIRING_SOON===u,k=w||_,E=(0,s.A)({[x.A["is-expired"]]:w,[x.A["is-expiring-soon"]]:_}),C=(0,i.useCallback)((()=>{const e=(0,n.getDate)(m);e.setFullYear(e.getFullYear()+100);const t=(0,n.dateI18n)("F jS, Y",a??e);return k?_?(0,l.sprintf)( -// translators: %1$s is the formatted date to display, i.e.- November 24th, 2024 -__("Expiring soon on %1$s","jetpack-my-jetpack"),t):(0,l.sprintf)( -// translators: %1$s is the formatted date to display, i.e.- November 24th, 2024 -__("Expired on %1$s","jetpack-my-jetpack"),t):!a&&d?(0,l.sprintf)( -// translators: %1$s is the name of the hosting partner. i.e.- Bluehost, InMotion, Pressable, Jurassic Ninja, etc.. -__("Managed by: %1$s","jetpack-my-jetpack"),d):(0,l.sprintf)( -// translators: %1$s is the formatted date to display, i.e.- November 24th, 2024 -__("Expires on %1$s","jetpack-my-jetpack"),t)}),[a,k,_,d,m]),j=(0,i.useCallback)((()=>k?_?React.createElement(o.A,{href:g,isExternalLink:!0,variant:"link",weight:"regular"},__("Renew subscription","jetpack-my-jetpack")):React.createElement(o.A,{href:f,isExternalLink:!0,variant:"link",weight:"regular"},__("Resume subscription","jetpack-my-jetpack")):null),[k,_,f,g]);return(0,b.b)(e)?React.createElement(r.Ay,{variant:"body",className:x.A["expire-date"]},React.createElement("span",{className:x.A["expire-date--with-icon"]},__("Never Expires","jetpack-my-jetpack")),React.createElement(y.k,{productName:v,giftedDate:m})):React.createElement(React.Fragment,null,React.createElement(r.Ay,{variant:"body",className:(0,s.A)(x.A["expire-date"],E)},C()),k&&React.createElement(r.Ay,null,j()))},E=({numberOfPurchases:e=0})=>React.createElement(React.Fragment,null,React.createElement(r.H3,null,_n("Your plan","Your plans",e,"jetpack-my-jetpack")),0===e&&React.createElement(r.Ay,{variant:"body"},__("Want to power up your Jetpack?","jetpack-my-jetpack"))),C=({numberOfPurchases:e})=>{const{recordEvent:t}=(0,m.A)(),{isUserConnected:a}=(0,h.A)(),{detail:r}=(0,d.A)("complete"),n=r.hasPaidPlanForProduct,l=_n("Manage your plan","Manage your plans",e,"jetpack-my-jetpack"),s=__("Purchase a plan","jetpack-my-jetpack"),u=(0,i.useCallback)((()=>{t("jetpack_myjetpack_plans_manage_click")}),[t]),v=(0,i.useCallback)((()=>{t("jetpack_myjetpack_plans_purchase_click")}),[t]),b=(0,f.A)(c.NM.ConnectionSkipPricing),y=(0,i.useCallback)((()=>{t("jetpack_myjetpack_activate_license_click"),a||b()}),[b,a,t]);let _=__("Activate a license","jetpack-my-jetpack");a||(_=__("Activate a license (requires a user connection)","jetpack-my-jetpack"));const{loadAddLicenseScreen:k="",adminUrl:E=""}=(0,p.A$)();return React.createElement("ul",null,e>0&&React.createElement("li",{className:x.A["actions-list-item"]},React.createElement(o.A,{onClick:u,href:(0,g.A)(),weight:"regular",variant:"link",isExternalLink:!0},l)),!n&&React.createElement("li",{className:x.A["actions-list-item"]},React.createElement(o.A,{onClick:v,href:(0,w.A)(),weight:"regular",variant:"link",isExternalLink:!0},s)),!n&&k&&React.createElement("li",{className:x.A["actions-list-item"]},React.createElement(o.A,{onClick:y,href:a?`${E}admin.php?page=my-jetpack#/add-license`:void 0,variant:"link",weight:"regular"},_)))},j=()=>{const e=!!(0,p.A$)("userIsAdmin"),{isSiteConnected:t}=(0,h.A)(),a=(0,v.A)({name:u.Ck,query:{path:u.tb},options:{enabled:t}}),{isLoading:r,isError:o}=a,n=a.data,l=n&&!r&&!o,s=l?n.length:0;return React.createElement("div",{className:x.A.container},React.createElement(E,{numberOfPurchases:s}),React.createElement("div",{className:x.A.purchasesSection},l&&n.map((e=>React.createElement(_,{key:`purchase-${e.product_name}`,purchase:e})))),e&&React.createElement(C,{numberOfPurchases:s}))}},5410:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>x});var r=a(27723),o=a(13022),n=a(51609),l=a(38837),s=a(488),i=a(65350),c=a(64526),u=a(36312),d=a(51870),v=a(17885),p=a(96214),m=a(62450),h=a(81434),f=a(56710),g=a(27879),w=a(12854),b=a(76023);const __=r.__,y=e=>`product-card-title-${e}`,x=e=>{const{name:t,Description:a,status:r,admin:x,isDataLoading:_,slug:k,additionalActions:E,primaryActionOverride:C,children:j,onMouseEnter:A,onMouseLeave:S,recommendation:P,customLoadTracks:R,manageUrl:M}=e;let{secondaryAction:V}=e;const[z,H]=(0,n.useState)(!1),{data:{ownedProducts:L}}=(0,i.A)(),O=L?.includes(k),N=r===l.hp.EXPIRED||r===l.hp.NEEDS_ATTENTION__ERROR,I=r===l.hp.EXPIRING_SOON||r===l.hp.NEEDS_ATTENTION__WARNING,B=r===l.hp.ABSENT||r===l.hp.ABSENT_WITH_PLAN,T=r===l.hp.NEEDS_PLAN,F=(0,o.A)({[b.A.plugin_absent]:B,[b.A["is-purchase-required"]]:T,[b.A["is-link"]]:B,[b.A["has-error"]]:N,[b.A["has-warning"]]:I}),{isLoading:D}=(0,s.V)(),[G,U]=(0,n.useState)(!1),{recordEvent:q}=(0,c.A)(),{siteIsRegistering:Z,isUserConnected:W}=(0,d.A)(),{connectSite:$}=(0,u.A)({tracksInfo:{event:"jetpack_myjetpack_product_card_fix_site_connection",properties:{}}}),J=G||Z&&r===l.hp.SITE_CONNECTION_ERROR,K=(0,n.useCallback)((()=>{q("jetpack_myjetpack_product_card_manage_click",{product:k})}),[k,q]);V||r!==l.hp.CAN_UPGRADE||"protect"===k&&!W||(V={href:M,label:__("View","jetpack-my-jetpack"),onClick:K});const Q=(0,n.useCallback)((({e:e})=>{$(e)}),[$]);return(0,n.useEffect)((()=>{!_&&!D&&!z&&(H(!0),q("jetpack_myjetpack_product_card_load",{product:k,status:r,...R}))}),[q,k,r,R,_,D,z,H]),React.createElement(m.A,{title:t||k,className:(0,o.A)(b.A.container,F),headerRightContent:null,onMouseEnter:A,onMouseLeave:S,titleId:y(k)},P&&React.createElement(f.A,{slug:k}),D?React.createElement(h.A,{height:"25px",width:"100%",spaceBelow:!0}):React.createElement(a,null),_?React.createElement("span",{className:b.A.loading},__("Loading…","jetpack-my-jetpack")):j,P?React.createElement(g.A,{slug:k}):React.createElement("div",{className:b.A.actions},React.createElement(w.A,{status:r,isFetching:J,isInstallingStandalone:!1,isOwned:O,suppressNeedsAttention:"protect"===k}),x&&React.createElement("div",{className:b.A.buttons},V&&V?.positionFirst&&React.createElement(p.A,V),React.createElement(v.A,{slug:k,additionalActions:E,primaryActionOverride:C,fixSiteConnectionHandler:Q,setIsActionLoading:U,tracksIdentifier:"product_card",labelSuffixId:y(k)}),V&&!V?.positionFirst&&x&&React.createElement(p.A,V))))}},56710:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(67397),o=a(27723),n=a(13022),l=a(74923),s=a(81434),i=a(76023),c=a(56147);const __=o.__,u=({slug:e})=>{const{isLoading:t}=(0,l.A)(e),{discountPrice:a,fullPrice:o,currencyCode:u,isFeature:d,hasFreeOffering:v}=(0,c.A)(e),p=d&&v&&!o;return t?React.createElement("div",{className:i.A.priceContainer},React.createElement(s.A,{width:"100%",height:"20px"})):React.createElement("div",{className:i.A.priceContainer},a&&React.createElement("span",{className:i.A.price},(0,r.Ay)(a,u)),React.createElement("span",{className:(0,n.A)(i.A.price,{[i.A.discounted]:a})},!p&&(0,r.Ay)(o,u),p&&__("Free","jetpack-my-jetpack")),!p&&React.createElement("span",{className:i.A.term},__("/month, billed yearly","jetpack-my-jetpack")))}},27879:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(96072),o=a.n(r),n=a(51112),l=a(13022),s=a(76023),i=a(56147);const c=({slug:e})=>{const{secondaryAction:t,primaryAction:a,isFeature:r,isActivating:c,isInstalling:u}=(0,i.A)(e);return React.createElement("div",{className:s.A.actions},React.createElement("div",{className:(0,l.A)(s.A.buttons,s.A.upsell)},a&&React.createElement(n.A,o()({size:"small",disabled:r&&(c||u)},a),a.label),t&&React.createElement(n.A,o()({size:"small",variant:"secondary",disabled:c},t),t.label)))}},12854:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(47425),o=a(27723),n=a(13022),l=a(38837),s=a(76023);const __=o.__,i=({status:e,isFetching:t,isInstallingStandalone:a,isOwned:o,suppressNeedsAttention:i=!1})=>{const c=((e,t,a)=>{switch(e){case l.hp.ACTIVE:case l.hp.CAN_UPGRADE:return __("Active","jetpack-my-jetpack");case l.hp.EXPIRING_SOON:return __("Expires soon","jetpack-my-jetpack");case l.hp.EXPIRED:return __("Expired plan","jetpack-my-jetpack");case l.hp.INACTIVE:case l.hp.MODULE_DISABLED:case l.hp.NEEDS_ACTIVATION:case l.hp.NEEDS_FIRST_SITE_CONNECTION:case l.hp.ABSENT:return __("Inactive","jetpack-my-jetpack");case l.hp.ABSENT_WITH_PLAN:return __("Needs Plugin","jetpack-my-jetpack");case l.hp.USER_CONNECTION_ERROR:return __("Needs user account","jetpack-my-jetpack");case l.hp.SITE_CONNECTION_ERROR:return __("Needs connection","jetpack-my-jetpack");case l.hp.NEEDS_PLAN:{const e=__("Needs plan","jetpack-my-jetpack"),a=__("Inactive","jetpack-my-jetpack");return t?e:a}case l.hp.NEEDS_ATTENTION__WARNING:case l.hp.NEEDS_ATTENTION__ERROR:{const e=__("Active","jetpack-my-jetpack"),t=__("Needs attention","jetpack-my-jetpack");return a?e:t}default:return __("Inactive","jetpack-my-jetpack")}})(e,o,i),u=(0,n.A)(s.A.status,((e,t,a)=>{switch(e){case l.hp.ACTIVE:case l.hp.CAN_UPGRADE:return s.A.active;case l.hp.ABSENT_WITH_PLAN:case l.hp.SITE_CONNECTION_ERROR:case l.hp.USER_CONNECTION_ERROR:case l.hp.EXPIRING_SOON:return s.A.warning;case l.hp.INACTIVE:case l.hp.NEEDS_FIRST_SITE_CONNECTION:case l.hp.NEEDS_ACTIVATION:return s.A.inactive;case l.hp.NEEDS_PLAN:return t?s.A.warning:s.A.inactive;case l.hp.EXPIRED:case l.hp.NEEDS_ATTENTION__WARNING:return a?s.A.active:s.A.warning;case l.hp.NEEDS_ATTENTION__ERROR:return a?s.A.active:s.A.error;default:return s.A.inactive}})(e,o,i),{[s.A["is-fetching"]]:t||a});return React.createElement(r.Ay,{variant:"label",className:u},c)}},56147:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var r=a(39384),o=a(27723),n=a(51609),l=a(38837),s=a(41526),i=a(55394),c=a(74923),u=a(68242),d=a(64526),v=a(51870);const __=o.__,p=(e,{onCheckout:t,onActivate:a,onInstall:r,onManage:o})=>{const n=e.status===l.hp.ACTIVE&&(e.isUpgradableByBundle.length||e.isUpgradable),s=e?.pricingForUi?.fullPrice||e?.pricingForUi?.tiers?.upgraded?.fullPrice;return e.status===l.hp.CAN_UPGRADE||n?s?{label:__("Upgrade","jetpack-my-jetpack"),onClick:t}:null:e.isFeature?((e,{onActivate:t,onInstall:a,onManage:r})=>{switch(e.status){case l.hp.MODULE_DISABLED:return{label:__("Activate","jetpack-my-jetpack"),onClick:t};case l.hp.ABSENT:return{label:__("Install","jetpack-my-jetpack"),onClick:a};case l.hp.USER_CONNECTION_ERROR:return{label:__("Connect","jetpack-my-jetpack"),href:"#/connection"};default:return{label:__("Manage","jetpack-my-jetpack"),href:e.manageUrl,onClick:r}}})(e,{onActivate:a,onInstall:r,onManage:o}):{label:__("Purchase","jetpack-my-jetpack"),onClick:t}},m=(e,t)=>{if(e.isFeature)return null;!e.isPluginActive||e.status===l.hp.NEEDS_ACTIVATION||(e.status,l.hp.NEEDS_PLAN);return{label:__("Learn more","jetpack-my-jetpack"),href:`#/add-${e.slug}`}},h=e=>{const{recordEvent:t}=(0,d.A)(),{detail:a}=(0,c.A)(e),{wpcomProductSlug:o,wpcomFreeProductSlug:l,...h}=(e=>{const{tiers:t,wpcomFreeProductSlug:a,introductoryOffer:r}=e||{};if(t){const{discountPrice:e,fullPrice:r,currencyCode:o,wpcomProductSlug:n,quantity:l,introductoryOffer:s}=t.upgraded;return{wpcomFreeProductSlug:a,wpcomProductSlug:l?`${n}:-q-${l}`:n,discountPrice:e&&e!==r&&!s?.reason?e/12:null,fullPrice:r?r/12:0,currencyCode:o??"USD"}}const{discountPrice:o,discountPricePerMonth:n,fullPrice:l,fullPricePerMonth:s,currencyCode:i,wpcomProductSlug:c}=e||{};return{wpcomFreeProductSlug:a,wpcomProductSlug:c,discountPrice:o&&o!==l&&!r?.reason?n:null,fullPrice:s??0,currencyCode:i??"USD"}})(a.pricingForUi),{install:f,isPending:g}=(0,i.A)(e),{isUserConnected:w}=(0,v.A)(),{myJetpackUrl:b,siteSuffix:y}=(0,u.A$)(),{activate:x,isPending:_}=(0,s.A)(e),{run:k}=(0,r.useProductCheckoutWorkflow)({from:"my-jetpack",productSlug:o,redirectUrl:b,connectAfterCheckout:!w,siteSuffix:y}),{run:E}=(0,r.useProductCheckoutWorkflow)({from:"my-jetpack",productSlug:l,redirectUrl:b,connectAfterCheckout:!w,siteSuffix:y}),C=(0,n.useCallback)((()=>{l?E():x()}),[x,E,l]),j=(0,n.useCallback)((()=>{if(t("jetpack_myjetpack_evaluation_recommendations_checkout_click",{slug:e}),"crm"===e)return x(),void window.open("https://jetpackcrm.com/pricing/","_blank");k()}),[x,t,k,e]),A=(0,n.useCallback)((()=>{t("jetpack_myjetpack_evaluation_recommendations_install_plugin_click",{product:e}),f()}),[e,f,t]),S=(0,n.useCallback)((()=>{t("jetpack_myjetpack_evaluation_recommendations_manage_click",{product:e})}),[e,t]);return{secondaryAction:m(a),primaryAction:p(a,{onCheckout:j,onActivate:C,onInstall:A,onManage:S}),isFeature:a.isFeature,hasFreeOffering:a.hasFreeOffering,isActivating:_,isInstalling:g,...h}}},48412:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(96072),o=a.n(r),n=a(31504),l=a(6176);const s=e=>React.createElement(l.A,o()({slug:n.D_.JETPACK_AI,upgradeInInterstitial:!0},e))},89674:(e,t,a)=>{"use strict";a.d(t,{z:()=>b});var r=a(48412),o=a(36724),n=a(30161),l=a(59838),s=a(15375),i=a(91686),c=a(95383),u=a(55243),d=a(74274),v=a(32917),p=a(30414),m=a(37014),h=a(44169),f=a(57769),g=a(4073),w=a(7631);const b={backup:n.A,protect:d.A,"anti-spam":o.A,boost:l.A,search:p.A,videopress:w.A,stats:g.A,crm:i.A,social:f.A,ai:r.A,"jetpack-ai":r.A,security:m.A,growth:c.A,complete:s.A,extras:null,scan:null,creator:null,"brute-force":null,newsletter:u.A,"related-posts":v.A,"site-accelerator":h.A}},36724:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(96072),o=a.n(r),n=a(28120),l=a.n(n),s=a(31504),i=a(6176);const c=e=>React.createElement(i.A,o()({slug:s.D_.ANTI_SPAM},e));c.propTypes={admin:l().bool};const u=c},30161:(e,t,a)=>{"use strict";a.d(t,{A:()=>C});var r=a(96072),o=a.n(r),n=a(47425),l=a(3924),s=a(27723),i=a(82290),c=a(28120),u=a.n(c),d=a(38837),v=a(31504),p=a(74923),m=a(280),h=a(68242),f=a(64526),g=a(40271),w=a(6176),b=a(12660),y=a(81434),x=a(52232);const __=s.__,_n=s._n,_=v.D_.BACKUP,k=e=>{const{detail:t}=(0,p.A)(_),{status:a,doesModuleNeedAttention:r}=t,l=!!r,{status:s}=r||{},c=a===d.hp.ACTIVE||a===d.hp.CAN_UPGRADE,{reasonContent:u,isLoading:v}=(0,g.A)()||{},{title:m,text:h}=u||{};if(c)return React.createElement(E,o()({slug:_},e));const f=a===d.hp.NEEDS_ATTENTION__ERROR&&l;return React.createElement(w.A,o()({slug:_,Description:f&&(()=>null)},e),v&&React.createElement(y.A,{height:"75px",width:"100%"}),f&&!v&&React.createElement("div",{className:x.A.backupErrorContainer},React.createElement("div",{className:x.A.iconContainer},React.createElement(i.A,{icon:"notice",size:16,className:x.A.iconError})),React.createElement("div",{className:x.A.contentContainer},React.createElement(n.Ay,{variant:"body-small",className:"value-section__heading"},__("The last backup attempt failed.","jetpack-my-jetpack"),React.createElement(b.I,{tracksEventName:"backup_card_tooltip_open",tracksEventProps:{location:"backup-error",status:a,backup_status:s,feature:"jetpack-backup"},expandOnMobile:!0},React.createElement(React.Fragment,null,React.createElement("h3",null,m),React.createElement("p",null,h),React.createElement("p",null,__("Check out our troubleshooting guide or contact your hosting provider to resolve the issue.","jetpack-my-jetpack"))))),React.createElement(n.Ay,{variant:"body-small",className:x.A.error_description},__("Check out our troubleshooting guide.","jetpack-my-jetpack")))))},E=e=>{const{data:t,isLoading:a}=(0,m.A)({name:v.Dz,query:{path:v.DB}}),r=t?.last_rewindable_event,c=r?.published,u=t?.undo_backup_id,{recordEvent:d}=(0,f.A)(),{siteSuffix:p=""}=(0,h.A$)(),g={href:(0,l.A)("jetpack-backup-undo-cta",{path:u,site:p}),size:"small",variant:"primary",weight:"regular",label:__("Undo","jetpack-my-jetpack"),onClick:()=>{d("jetpack_myjetpack_backup_card_undo_click",{product:e.slug,undo_backup_id:u})},isExternalLink:!0};return React.createElement(w.A,o()({},e,{showMenu:!0,isDataLoading:a,Description:r?()=>React.createElement(n.Ay,{variant:"body-small",className:x.A.description},React.createElement("span",null,__("Activity Detected","jetpack-my-jetpack")),React.createElement("span",{className:x.A.time},(e=>{if(!e)return"";const t=new Date-new Date(e);if(t>0){const e=Math.floor(t/864e5),a=Math.floor(t%864e5/36e5),r=Math.floor(t%36e5/6e4),o=Math.floor(t%6e4/1e3);return e>0?(0,s.sprintf)( -// translators: %s is the number of days since the last backup -_n("%s day ago","%s days ago",e,"jetpack-my-jetpack"),e):a>0?(0,s.sprintf)( -// translators: %s is the number of hours since the last backup -_n("%s hour ago","%s hours ago",a,"jetpack-my-jetpack"),a):r>0?(0,s.sprintf)( -// translators: %s is the number of minutes since the last backup -_n("%s minute ago","%s minutes ago",r,"jetpack-my-jetpack"),r):(0,s.sprintf)( -// translators: %s is the number of seconds since the last backup -_n("%s second ago","%s seconds ago",o,"jetpack-my-jetpack"),o)}})(c))):null,additionalActions:r?[g]:[]}),r?React.createElement("div",{className:x.A.activity},React.createElement(i.A,{icon:r.gridicon,size:24}),React.createElement("p",{className:x.A.summary},r.summary)):null)};k.propTypes={admin:u().bool};const C=k},79520:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(58454),o=a(56461),n=a(10580),l=a(56427),s=a(29491),i=a(27723),c=a(51113),u=a(62510),d=a(51609),v=a(38837),p=a(74923),m=a(68242),h=a(64526),f=a(51870),g=a(76683);a(14479);const __=i.__,w=()=>{const{recordEvent:e}=(0,h.A)(),[t,a]=(0,d.useState)(!1),[w,b]=(0,d.useState)(""),[y,x]=(0,d.useState)(null),[_,k]=(0,d.useState)(null),[E,C]=(0,d.useState)(!1),[j,A]=(0,d.useState)(!1),[S,P]=(0,d.useState)(!1),R=(0,s.useViewportMatch)("medium","<"),{siteUrl:M="",latestBoostSpeedScores:V}=(0,m.A$)(),{apiRoot:z,apiNonce:H,isSiteConnected:L}=(0,f.A)(),{detail:O}=(0,p.A)("boost"),{status:N}=O,I=N===v.hp.ACTIVE||N===v.hp.CAN_UPGRADE,B=(e,t)=>{const{mobile:a,desktop:r}=t||{};var o,n;a&&r&&e((o=a,n=r,Math.round((o+n)/2)))},T=e=>{const{scores:t,previousScores:a}=e||{};B(x,t),B(k,a),(e=>{const{mobile:t,desktop:a}=e||{};t&&a&&b((0,r.T)(t,a))})(t)},F=async()=>{L?(a(!0),(0,r.sE)(!0,z,M,H).then((e=>{const t=(0,r.T)(e.current.mobile,e.current.desktop);b(t),B(x,e.current),B(k,V.scores),a(!1)})).catch((t=>{e("jetpack_boost_speed_score_error",{feature:"jetpack-boost",position:"my-jetpack",error:t}),V&&V.scores?T(V):C(!0),a(!1)}))):C(!0)},D=(0,d.useMemo)((()=>_&&y?y<_?null:y-_:null),[y,_]),G=(0,g.R)({speedLetterGrade:w,boostScoreIncrease:D}),U=(0,d.useCallback)((()=>{A(!0)}),[A]),q=(0,d.useCallback)((()=>{A(!1)}),[A]);return(0,d.useEffect)((()=>{V?I?(0,r.US)(1e3*V.timestamp)<1?T(V):F():(0,r.US)(1e3*V.timestamp)<14?T(V):F():F()}),[]),(0,d.useEffect)((()=>{t||!j||S||(e("jetpack_boost_card_tooltip_viewed",{feature:"jetpack-boost",position:"my-jetpack"}),P(!0))}),[t,j,e,S]),!E&&React.createElement("div",{className:"mj-boost-speed-score",role:"presentation",onMouseEnter:U,onMouseLeave:q,onClick:j?q:U,onFocus:U,onBlur:q},t?React.createElement(o.A,{color:"#23282d",size:16}):React.createElement(React.Fragment,null,React.createElement("div",{className:"screen-reader-text"},((e,t,a,r)=>{if(!e||"number"!=typeof t)return"";const o=[];return o.push((0,i.sprintf)( -// translators: %1$s: speed grade (e.g. 'A'), %2$s: numerical speed score (e.g. '95'). -__("Your website’s overall speed score is %1$s, or %2$s out of 100.","jetpack-my-jetpack"),e,t)),"number"==typeof a&&o.push(a>0?(0,i.sprintf)( -// translators: %s: score increase (e.g. '10') -__("Your website’s overall speed score increased by %s.","jetpack-my-jetpack"),a):(0,i.sprintf)( -// translators: %s: score increase (e.g. '10') -__("Your website’s overall speed score decreased by %s.","jetpack-my-jetpack"),a)),r&&o.push(r),o.join(" ")})(w,y,D,G)),React.createElement("div",{"aria-hidden":"true"},React.createElement("div",{className:"mj-boost-speed-score__grade"},React.createElement("span",null,__("Your website’s overall speed score:","jetpack-my-jetpack")),React.createElement("span",{className:"mj-boost-speed-score__grade--letter"},w,!t&&j&&React.createElement(l.Popover,{placement:R?"top-end":"top-start",noArrow:!1,offset:10},React.createElement("div",{className:"boost-score-tooltip__parent"},React.createElement("p",{className:"boost-score-tooltip__heading"},__("Site speed performance:","jetpack-my-jetpack")," ",w),React.createElement("p",{className:"boost-score-tooltip__content"},G))))),React.createElement("div",{className:"mj-boost-speed-score__bar"},React.createElement(n.A,{score:y,active:y>0,isLoading:t,showPrevScores:!1,scoreBarType:"desktop",noBoostScoreTooltip:null})),!!D&&React.createElement("div",{className:"mj-boost-speed-score__increase"},React.createElement(c.A,{size:18,icon:u.A}),React.createElement("span",null,D)))))}},59838:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(96072),o=a.n(r),n=a(27723),l=a(38837),s=a(31504),i=a(6176),c=a(79520);const __=n.__,u=e=>{const t={[l.hp.ABSENT]:{label:__("Boost your site","jetpack-my-jetpack")}};return React.createElement(i.A,o()({slug:s.D_.BOOST,primaryActionOverride:t},e),React.createElement(c.A,null))}},76683:(e,t,a)=>{"use strict";a.d(t,{R:()=>n});var r=a(27723),o=a(74923);const __=r.__;function n({speedLetterGrade:e,boostScoreIncrease:t}){const{detail:a}=(0,o.A)("boost"),{isPluginActive:n,hasPaidPlanForProduct:l}=a;if(n){if(l){if(t)return(0,r.sprintf)(/* translators: %d is the number (positive integer) of points the speed has increased */ -__("Your speed has improved by %d points! Boost is working to enhance your performance with automated tools.","jetpack-my-jetpack"),t);switch(e){case"A":return __("Your site is fast! Boost is working to enhance your performance with automated tools.","jetpack-my-jetpack");case"B":case"C":case"D":case"E":case"F":return __("Visit the Boost dashboard to view your historical speed scores and manage your product settings.","jetpack-my-jetpack");default:return __("Visit the Boost dashboard to view your site’s speed scores and manage your product settings.","jetpack-my-jetpack")}}if(t)return(0,r.sprintf)(/* translators: %d is the number (integer) of points the speed has increased */ -__("Your speed has improved by %d points! Upgrade Boost to unlock automated CSS and image optimization tools to maintain your high score.","jetpack-my-jetpack"),t);switch(e){case"A":return __("Your site is fast! But maintaining a high speed isn’t easy. Upgrade Boost to use automated CSS and image optimization tools to improve your performance on the go.","jetpack-my-jetpack");case"B":return __("You are one step away from making your site blazing fast. Upgrade Boost to use automated CSS and image optimization tools to improve your performance.","jetpack-my-jetpack");default:return __("Improve your performance with automated CSS and image optimization tools by upgrading Boost.","jetpack-my-jetpack")}}switch(e){case"A":return __("Your site is fast! But maintaining a high speed isn’t easy. Use Boost’s automated acceleration tools to optimize your performance on the go.","jetpack-my-jetpack");case"B":return __("You are one step away from making your site blazing fast. Install Boost to enhance your site’s performance like top websites, no developer needed.","jetpack-my-jetpack");default:return __("Your site needs performance improvements. Make your site blazing fast with Boost’s simple dashboard and acceleration tools.","jetpack-my-jetpack")}}},15375:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(6176);const n=({admin:e,recommendation:t})=>React.createElement(o.A,{slug:r.D_.COMPLETE,showMenu:!0,admin:e,recommendation:t})},91686:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(96072),o=a.n(r),n=a(28120),l=a.n(n),s=a(31504),i=a(6176);const c=e=>React.createElement(i.A,o()({slug:s.D_.CRM},e));c.propTypes={admin:l().bool};const u=c},95383:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(6176);const n=({admin:e,recommendation:t})=>React.createElement(o.A,{slug:r.D_.GROWTH,showMenu:!0,admin:e,recommendation:t})},25487:(e,t,a)=>{"use strict";a.d(t,{A:()=>A});var r=a(28509),o=a(75918),n=a(90766),l=a(47425),s=a(27723),i=a(51609),c=a(31504),u=a(65350),d=a(68242),v=a(81434),p=a(31421),m=a(1035),h=a(48412),f=a(36724),g=a(30161),w=a(59838),b=a(91686),y=a(74274),x=a(30414),_=a(57769),k=a(4073),E=a(10372),C=a(7631);const __=s.__,j=({slugs:e,isLoading:t})=>{const a=[...Array(9).keys()],{showFullJetpackStatsCard:n=!1}=(0,d.A$)("myJetpackFlags"),{userIsAdmin:l=!1}=(0,d.A$)(),s={backup:g.A,protect:y.A,"anti-spam":f.A,boost:w.A,search:x.A,videopress:C.A,stats:k.A,crm:b.A,social:_.A,"jetpack-ai":h.A},i=e.filter((e=>(e!==c.D_.STATS||!n)&&!!s[e]));return React.createElement(React.Fragment,null,t&&React.createElement(r.A,{className:E.A.fullStatsCard},React.createElement(v.A,{width:"100%",height:"350px"})),!t&&e.includes("stats")&&n&&React.createElement(r.A,{className:E.A.fullStatsCard},React.createElement(m.A,null)),React.createElement(o.A,{className:E.A.cardlist,tagName:"ul",fluid:!0,horizontalSpacing:0,horizontalGap:3},t?a.map(((e,t)=>React.createElement(r.A,{tagName:"li",sm:4,md:4,lg:4,key:t},React.createElement(v.A,{width:"100%",height:"200px"})))):i.map((e=>{const t=s[e];return React.createElement(r.A,{tagName:"li",sm:4,md:4,lg:4,key:e},React.createElement(t,{admin:"1"===l}))}))))},A=({noticeMessage:e})=>{const{data:{ownedProducts:t,unownedProducts:a},isLoading:s}=(0,u.A)(),[c,v]=(0,i.useState)(!0);(0,i.useEffect)((()=>{s||requestAnimationFrame((()=>v(!1)))}));const{canUserViewStats:m,userIsAdmin:h}=(0,d.A$)(),f=(0,i.useMemo)((()=>t.length>0?__("Discover more","jetpack-my-jetpack"):__("Discover all Jetpack Products","jetpack-my-jetpack")),[t.length]),g=(0,i.useCallback)((e=>{const t=["extras","scan","security","ai","creator","growth","complete","site-accelerator","newsletter","related-posts","brute-force"];return m||t.push("stats"),e.filter((e=>!t.includes(e)))}),[m]),w=g(t),b=g(a);return React.createElement(React.Fragment,null,(c||w.length>0)&&React.createElement(n.A,null,React.createElement(o.A,{horizontalSpacing:6,horizontalGap:e?3:6},React.createElement(r.A,null,React.createElement(r.A,{sm:4,md:8,lg:12,className:E.A.cardListTitle},React.createElement(l.Ay,{variant:"headline-small"},__("My products","jetpack-my-jetpack"))),React.createElement(j,{isLoading:c,slugs:w})))),h&&b.length>0&&React.createElement(o.A,{horizontalSpacing:6,horizontalGap:e?3:6},React.createElement(r.A,null,React.createElement(r.A,{sm:4,md:8,lg:12,className:E.A.cardListTitle},React.createElement(l.Ay,{variant:"headline-small"},f)),React.createElement(p.A,{products:b}))))}},55243:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(6176);const n=({admin:e,recommendation:t})=>React.createElement(o.A,{slug:r.D_.NEWSLETTER,admin:e,recommendation:t})},23293:(e,t,a)=>{"use strict";a.d(t,{Q:()=>m});var r=a(29491),o=a(27723),n=a(13022),l=a(74923),s=a(51870),i=a(12660),c=a(10372),u=a(96068),d=a(90850),v=a(24516),p=a(57915);const __=o.__,m=({data:e})=>{const{detail:t}=(0,l.A)("protect"),{isPluginActive:a=!1}=t||{},{isSiteConnected:r}=(0,s.A)(),{jetpack_waf_automatic_rules:o,waf_enabled:n}=e?.wafConfig||{};return a&&r?o&&n?React.createElement(h,{data:e,status:"active"}):React.createElement(h,{data:e,status:"inactive"}):React.createElement(h,{data:e,status:"off"})},h=({status:e,data:t})=>{const a=(0,r.useViewportMatch)("medium","<"),{detail:o}=(0,l.A)("protect"),{hasPaidPlanForProduct:s=!1}=o||{},m=(0,p.T)(t),{autoFirewallTooltip:h}=m;return"active"===e?React.createElement(React.Fragment,null,React.createElement("div",{className:c.A.valueSectionHeading},__("Auto-Firewall","jetpack-my-jetpack")),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:v,alt:__("Shield icon - Auto-Firewall Status: On","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("On","jetpack-my-jetpack")))):"inactive"===e?React.createElement(React.Fragment,null,React.createElement("div",{className:(0,n.A)(c.A.valueSectionHeading,"value-section__heading")},__("Auto-Firewall","jetpack-my-jetpack"),React.createElement(i.I,{tracksEventName:"protect_card_tooltip_open",tracksEventProps:{location:"auto-firewall",status:e,feature:"jetpack-protect",has_paid_plan:s},placement:a?"top":"right"},React.createElement("h3",null,h.title),React.createElement("p",null,h.text))),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:u,alt:__("Shield icon - Auto-Firewall Status: Inactive","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("Inactive","jetpack-my-jetpack")))):React.createElement(React.Fragment,null,React.createElement("div",{className:c.A.valueSectionHeading},__("Auto-Firewall","jetpack-my-jetpack")),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:d,alt:__("Shield icon - Auto-Firewall Status: Off","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("Off","jetpack-my-jetpack"))))}},74274:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(96072),o=a.n(r),n=a(31504),l=a(6176),s=a(57765);const i=e=>React.createElement(l.A,o()({},e,{slug:n.D_.PROTECT,upgradeInInterstitial:!0}),React.createElement(s.A,null))},66:(e,t,a)=>{"use strict";a.d(t,{f:()=>m});var r=a(27723),o=a(13022),n=a(74923),l=a(51870),s=a(56581),i=a(23658),c=a(12660),u=a(10372),d=a(90850),v=a(64538),p=a(57915);const __=r.__,m=({data:e})=>{const{detail:t}=(0,n.A)("protect"),{isPluginActive:a=!1}=t||{},{isSiteConnected:r}=(0,l.A)(),{blocked_logins:o,brute_force_protection:s}=e?.wafConfig||{};return(a||(0,i.w)())&&r?s?React.createElement(h,{data:e,status:"active"}):React.createElement(h,{data:e,status:"inactive"}):r&&o>0?React.createElement(h,{data:e,status:"inactive"}):React.createElement(h,{data:e,status:"off"})},h=({status:e,data:t})=>{const{blocked_logins:a}=t?.wafConfig||{},r=(0,p.T)(t),{blockedLoginsTooltip:n}=r;return"active"===e?a>0?React.createElement(React.Fragment,null,React.createElement("div",{className:u.A.valueSectionHeading},__("Logins Blocked","jetpack-my-jetpack")),React.createElement("div",{className:"value-section__data"},React.createElement("div",{className:"logins_blocked__count"},(0,s.A)(a)))):React.createElement(React.Fragment,null,React.createElement("div",{className:(0,o.A)(u.A.valueSectionHeading,"value-section__heading")},__("Logins Blocked","jetpack-my-jetpack"),React.createElement(c.I,{tracksEventName:"protect_card_tooltip_open",tracksEventProps:{location:"blocked-logins",status:e,feature:"jetpack-protect",message:"no data yet"}},React.createElement("h3",null,n.title),React.createElement("p",null,n.text))),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:v,alt:__("Shield icon - Brute Force Protection Status: Active","jetpack-my-jetpack")})))):"inactive"===e?React.createElement(React.Fragment,null,React.createElement("div",{className:(0,o.A)(u.A.valueSectionHeading,"value-section__heading")},__("Logins Blocked","jetpack-my-jetpack"),React.createElement(c.I,{tracksEventName:"protect_card_tooltip_open",tracksEventProps:{location:"blocked-logins",feature:"jetpack-protect",status:e}},React.createElement("h3",null,n.title),React.createElement("p",null,n.text))),React.createElement("div",{className:"value-section__data"},a>0?React.createElement(React.Fragment,null,React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:d,alt:__("Shield icon - Brute Force Protection Status: Inactive","jetpack-my-jetpack")})),React.createElement("div",{className:"logins_blocked__count"},(0,s.A)(a))):React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:d,alt:__("Shield icon - Brute Force Protection Status: Inactive","jetpack-my-jetpack")})))):React.createElement(React.Fragment,null,React.createElement("div",{className:u.A.valueSectionHeading},__("Logins Blocked","jetpack-my-jetpack")),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:d,alt:__("Shield icon - Brute Force Protection Status: Off","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("Off","jetpack-my-jetpack"))))}},57765:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var r=a(31504),o=a(74923),n=a(280),l=a(12660),s=a(81434),i=a(23293),c=a(66),u=a(61512),d=a(52584),v=a(57915);a(6619);const p=()=>{const{detail:e,isLoading:t}=(0,o.A)("protect"),{isPluginActive:a=!1}=e||{},{data:p,isLoading:m}=(0,n.A)({name:r.Re,query:{path:r.es}}),h=(0,d.A)(p),f=(0,v.T)(p),{pluginsThemesTooltip:g}=f,w=t||m;return React.createElement(React.Fragment,null,React.createElement("div",{className:"value-section__last-scan"},w?React.createElement(s.A,{width:"150px",height:"16px"}):h&&React.createElement("div",null,h),!a&&React.createElement(l.I,{tracksEventName:"protect_card_tooltip_open",tracksEventProps:{location:"plugins&themes",feature:"jetpack-protect",status:"inactive"}},React.createElement("h3",null,g.title),React.createElement("p",null,g.text))),React.createElement("div",{className:"value-section"},React.createElement("div",{className:"value-section__scan-threats"},w?React.createElement(s.A,{width:"75px",height:"50px"}):React.createElement(u.v,{data:p})),React.createElement("div",{className:"value-section__auto-firewall"},w?React.createElement(s.A,{width:"75px",height:"50px"}):React.createElement(i.Q,{data:p})),React.createElement("div",{className:"value-section__logins-blocked"},w?React.createElement(s.A,{width:"75px",height:"50px"}):React.createElement(c.f,{data:p}))))}},61512:(e,t,a)=>{"use strict";a.d(t,{v:()=>w});var r=a(11883),o=a(56427),n=a(29491),l=a(27723),s=a(13022),i=a(51609),c=a(74923),u=a(64526),d=a(51870),v=a(12660),p=a(10372),m=a(90850),h=a(64538),f=a(24516),g=a(57915);const __=l.__,w=({data:e})=>{const{detail:t}=(0,c.A)("protect"),{isPluginActive:a=!1,hasPaidPlanForProduct:r}=t||{},{isSiteConnected:o}=(0,d.A)(),{plugins:n,themes:l,num_threats:s=0}=e?.scanData||{},u=(0,i.useMemo)((()=>{const{core:t,database:a,files:r,num_plugins_threats:o,num_themes_threats:s}=e?.scanData||{};return[...o?n.reduce(((e,t)=>e.concat(t.threats)),[]):[],...s?l.reduce(((e,t)=>e.concat(t.threats)),[]):[],...t?.threats??[],...a??[],...r??[]].reduce(((e,t)=>t.severity>=5?e+=1:e),0)}),[n,l,e?.scanData]);return a&&o?r?s?React.createElement(b,{data:e,numThreats:s,criticalThreatCount:u}):React.createElement(y,{data:e,status:"success"}):s?React.createElement(b,{data:e,numThreats:s}):React.createElement(y,{data:e,status:"partial"}):React.createElement(y,{data:e,status:"off"})},b=({data:e,numThreats:t,criticalThreatCount:a})=>{const{recordEvent:l}=(0,u.A)(),c=(0,i.useRef)(),d=(0,n.useViewportMatch)("medium","<"),[m,h]=(0,i.useState)(!1),f=(0,g.T)(e),{scanThreatsTooltip:w}=f,b=(0,i.useCallback)((()=>h((e=>(!0==!e&&l("jetpack_protect_card_tooltip_open",{page:"my-jetpack",feature:"jetpack-protect",location:"scan",has_paid_plan:!0,threats:t}),!e)))),[t,l]),y=(0,i.useCallback)((()=>{c.current&&!c.current.contains(c.current.ownerDocument.activeElement)&&h(!1)}),[h,c]);return a?React.createElement(React.Fragment,null,React.createElement("div",{className:(0,s.A)(p.A.valueSectionHeading,"value-section__heading")},__("Threats","jetpack-my-jetpack"),React.createElement("div",{className:"scan-threats__critical-threat-container"},React.createElement("button",{className:"info-tooltip__button",onClick:b,ref:c},React.createElement(r.A,{className:"scan_threats__icon-critical",icon:"info",size:14}),React.createElement("span",{className:"scan-threats__critical-threat-count"},a)),m&&React.createElement(o.Popover,{placement:d?"top-end":"right",noArrow:!1,offset:10,focusOnMount:"container",onClose:y},React.createElement("div",{className:"info-tooltip__content"},React.createElement("h3",null,w.title),React.createElement("p",null,w.text))))),React.createElement("div",{className:"value-section__data"},React.createElement("div",{className:"scan-threats__critical-threats"},React.createElement("div",{className:"scan-threats__threat-count"},t)))):React.createElement(React.Fragment,null,React.createElement("div",{className:(0,s.A)(p.A.valueSectionHeading,"value-section__heading")},__("Threats","jetpack-my-jetpack"),React.createElement(v.I,{tracksEventName:"protect_card_tooltip_open",tracksEventProps:{location:"threats",feature:"jetpack-protect",has_paid_plan:!0,threats:t}},React.createElement("h3",null,w.title),React.createElement("p",null,w.text))),React.createElement("div",{className:"value-section__data"},React.createElement("div",{className:"scan-threats__threat-count"},t)))},y=({data:e,status:t})=>{const a=(0,g.T)(e),{scanThreatsTooltip:r}=a;return"success"===t?React.createElement(React.Fragment,null,React.createElement("div",{className:p.A.valueSectionHeading},__("Scan","jetpack-my-jetpack")),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:f,alt:__("Shield icon - Scan Status: Secure","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("Secure","jetpack-my-jetpack")))):"partial"===t?React.createElement(React.Fragment,null,React.createElement("div",{className:(0,s.A)(p.A.valueSectionHeading,"value-section__heading")},__("Scan","jetpack-my-jetpack"),React.createElement(v.I,{tracksEventName:"protect_card_tooltip_open",tracksEventProps:{location:"scan",status:t,feature:"jetpack-protect",has_paid_plan:!1,threats:0}},React.createElement("h3",null,r.title),React.createElement("p",null,r.text))),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:h,alt:__("Shield icon - Scan Status: Partial","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("Partial","jetpack-my-jetpack")))):React.createElement(React.Fragment,null,React.createElement("div",{className:p.A.valueSectionHeading},__("Scan","jetpack-my-jetpack")),React.createElement("div",{className:"value-section__data"},React.createElement("div",null,React.createElement("img",{className:"value-section__status-icon",src:m,alt:__("Shield icon - Scan Status: Off","jetpack-my-jetpack")})),React.createElement("div",{className:"value-section__status-text"},__("Off","jetpack-my-jetpack"))))}},52584:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(27723),o=a(51609),n=a(74923),l=a(68242),s=a(14542);const __=r.__,_n=r._n,i=e=>{const{detail:t}=(0,n.A)("protect"),{isPluginActive:a=!1}=t||{},{plugins:i,themes:c}=(0,l.A$)(),{plugins:u,themes:d,last_checked:v=null}=e?.scanData||{},p=u?.length||Object.keys(i).length,m=d?.length||Object.keys(c).length,h=!!v&&(0,s._)(Date.parse(v));return(0,o.useMemo)((()=>a?h?(0,r.sprintf)(/* translators: %s is how long ago since the last scan took place, i.e.- "17 hours ago" */ -__("Last scan: %s","jetpack-my-jetpack"),h):null:(0,r.sprintf)(/* translators: %d is the number of plugins installed on the site. */ -_n("%d plugin","%d plugins",p,"jetpack-my-jetpack"),p)+" "+/* translators: The ampersand symbol here (&) is meaning "and". */ -__("&","jetpack-my-jetpack")+" "+(0,r.sprintf)(/* translators: %d is the number of themes installed on the site. */ -_n("%d theme","%d themes",m,"jetpack-my-jetpack").replace(" "," "),m)),[a,h,p,m])}},57915:(e,t,a)=>{"use strict";a.d(t,{T:()=>d});var r=a(86087),o=a(27723),n=a(51609),l=a(31504),s=a(74923),i=a(68242),c=a(64526),u=a(23658);const __=o.__,_n=o._n,d=e=>{const t=l.D_.PROTECT,{detail:a}=(0,s.A)(t),{standalonePluginInfo:d,hasPaidPlanForProduct:v,manageUrl:p}=a||{},{isStandaloneActive:m}=d||{},{recordEvent:h}=(0,c.A)(),{plugins:f,themes:g}=(0,i.A$)(),{plugins:w,themes:b,num_threats:y=0,threats:x=[]}=e?.scanData||{},{jetpack_waf_automatic_rules:_,blocked_logins:k,brute_force_protection:E,waf_supported:C,waf_enabled:j}=e?.wafConfig||{},A=w?.length||Object.keys(f).length,S=b?.length||Object.keys(g).length,P=(0,n.useMemo)((()=>x.length?x.reduce(((e,t)=>t.severity>=5?e+=1:e),0):0),[x]),R=(0,n.useMemo)((()=>m?"admin.php?page=jetpack-protect#/firewall":(0,u.w)()?"admin.php?page=jetpack#/settings":null),[m]),M=(0,n.useCallback)((()=>{h("jetpack_protect_card_tooltip_content_link_click",{page:"my-jetpack",feature:"jetpack-protect",location:"auto-firewall-tooltip",path:R})}),[h,R]),V=(0,n.useCallback)((()=>{h("jetpack_protect_card_tooltip_content_link_click",{page:"my-jetpack",feature:"jetpack-protect",location:"scan-threats-tooltip",path:p})}),[h,p]),z=m||(0,u.w)(),H=(0,n.useMemo)((()=>0===k?E?{title:__("Brute Force Protection: Active","jetpack-my-jetpack"),text:__("Brute Force Protection is actively blocking malicious login attempts. The number of blocked login attempts will display here soon!","jetpack-my-jetpack")}:{title:__("Brute Force Protection: Inactive","jetpack-my-jetpack"),text:R?(0,r.createInterpolateElement)((0,o.sprintf)(/* translators: %s is the location/page where the settings are located. Either "firewall settings" or "Jetpack settings". */ -__("Brute Force Protection is disabled and not actively blocking malicious login attempts. Go to %s to activate it.","jetpack-my-jetpack"),m?"firewall settings":"Jetpack settings"),{a:(0,n.createElement)("a",{href:R,onClick:M})}):__("Brute Force Protection is disabled and not actively blocking malicious login attempts.","jetpack-my-jetpack")}:E?void 0:z?{title:__("Brute Force Protection: Inactive","jetpack-my-jetpack"),text:R?(0,r.createInterpolateElement)((0,o.sprintf)(/* translators: %s is the location/page where the settings are located. Either "firewall settings" or "Jetpack settings". */ -__("Brute Force Protection is disabled and not actively blocking malicious login attempts. Go to %s to activate it.","jetpack-my-jetpack"),m?"firewall settings":"Jetpack settings"),{a:(0,n.createElement)("a",{href:R,onClick:M})}):__("Brute Force Protection is disabled and not actively blocking malicious login attempts.","jetpack-my-jetpack")}:{title:__("Brute Force Protection: Inactive","jetpack-my-jetpack"),text:__("For Brute Force Protection, activate the Jetpack or Protect plugin and enable it in settings.","jetpack-my-jetpack")}),[k,E,z,m,R,M]);return{pluginsThemesTooltip:{title:__("Improve site safety: secure plugins & themes","jetpack-my-jetpack"),text:(0,o.sprintf)(/* translators: %1$s the singular or plural of number of plugin(s), and %2$s is the singular or plural of the number of theme(s). */ -__("Your site has %1$s and %2$s lacking security measures. Improve your site’s safety by adding protection at no cost.","jetpack-my-jetpack"),(0,o.sprintf)(/* translators: %d is the number of plugins installed on the site. */ -_n("%d plugin","%d plugins",A,"jetpack-my-jetpack"),A),(0,o.sprintf)(/* translators: %d is the number of themes installed on the site. */ -_n("%d theme","%d themes",S,"jetpack-my-jetpack"),S))},scanThreatsTooltip:v&&y?{title:__("Auto-fix threats","jetpack-my-jetpack"),text:P?(0,r.createInterpolateElement)((0,o.sprintf)(/* translators: %1$s is the number of threats, %2$s is the numner of critical threats on the site, and %3$s is either "Scan" or "Protect" (the type of dashboard). */ -__("The last scan identified %1$s (%2$d critical). But don’t worry, Protect is usually able to “Auto-fix” threats, in most cases. Visit the %3$s dashboard to view more details.","jetpack-my-jetpack"),(0,o.sprintf)(/* translators: %d is the number of detected scan threats on the site. */ -_n("%d threat","%d threats",y,"jetpack-my-jetpack"),y),P,m?"Protect":"Scan"),{a:(0,n.createElement)("a",{href:p,onClick:V})}):(0,r.createInterpolateElement)((0,o.sprintf)(/* translators: %1$s is the singular or plural of number of detected threats on the site, and %2$s is either "Scan" or "Protect" (the type of dashboard). */ -__("The last scan identified %1$s. But don’t worry, Protect is usually able to “Auto-fix” threats, in most cases. Visit the %2$s dashboard to view more details.","jetpack-my-jetpack"),(0,o.sprintf)(/* translators: %d is the number of detected scan threats on the site. */ -_n("%d threat","%d threats",y,"jetpack-my-jetpack"),y),m?"Protect":"Scan"),{a:(0,n.createElement)("a",{href:p,onClick:V})})}:{title:__("Elevate your malware protection","jetpack-my-jetpack"),text:__("We’ve checked items against our database, and all appears well. For a more detailed, line-by-line malware scan, consider upgrading your plan.","jetpack-my-jetpack")},autoFirewallTooltip:(!v||_&&j)&&C?{title:__("Auto-Firewall: Inactive","jetpack-my-jetpack"),text:__("Upgrade required for activation. Manual rules available.","jetpack-my-jetpack")}:{title:__("Auto-Firewall: Inactive","jetpack-my-jetpack"),text:C?(0,r.createInterpolateElement)(__("You have Auto-Firewall disabled, visit your Protect firewall settings to activate.","jetpack-my-jetpack"),{a:(0,n.createElement)("a",{href:R,onClick:M})}):__("Auto-Firewall is disabled as your hosting provider already includes a built-in firewall with similar rules for your site.","jetpack-my-jetpack")},blockedLoginsTooltip:H}}},32917:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(6176);const n=({admin:e,recommendation:t})=>React.createElement(o.A,{slug:r.D_.RELATED_POSTS,admin:e,recommendation:t})},30414:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(96072),o=a.n(r),n=a(28120),l=a.n(n),s=a(31504),i=a(6176);const c=e=>React.createElement(i.A,o()({slug:s.D_.SEARCH,showMenu:!0},e));c.propTypes={admin:l().bool};const u=c},37014:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(6176);const n=({admin:e,recommendation:t})=>React.createElement(o.A,{slug:r.D_.SECURITY,showMenu:!0,admin:e,recommendation:t})},44169:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(6176);const n=({admin:e,recommendation:t})=>React.createElement(o.A,{slug:r.D_.SITE_ACCELERATOR,admin:e,recommendation:t})},57769:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(96072),o=a.n(r),n=a(28120),l=a.n(n),s=a(31504),i=a(6176);const c=e=>React.createElement(i.A,o()({slug:s.D_.SOCIAL,showMenu:!0},e));c.propTypes={admin:l().bool};const u=c},4073:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(96072),o=a.n(r),n=a(28120),l=a.n(n),s=a(31504),i=a(6176);const c=e=>React.createElement(i.A,o()({slug:s.D_.STATS,showMenu:!0},e));c.propTypes={admin:l().bool};const u=c},7631:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var r=a(96072),o=a.n(r),n=a(47425),l=a(51609),s=a(38837),i=a(31504),c=a(74923),u=a(280),d=a(6176),v=a(12660),p=a(56544),m=a(83554),h=a(77167);a(20906);const f=i.D_.VIDEOPRESS,g=e=>{const{detail:t,isLoading:a}=(0,c.A)(f),{data:r,isLoading:g}=(0,u.A)({name:i.Yr,query:{path:i.PM}}),w=a||g,{status:b}=t||{},{activeAndNoVideos:y}=(0,p.A)(r),{videoCount:x=0,featuredStats:_}=r||{},k=b===s.hp.ACTIVE||b===s.hp.CAN_UPGRADE,E=(0,m.A)({isPluginActive:k,videoCount:x}),C=(0,l.useMemo)((()=>({stats_period:_?.period,video_count:x})),[_,x]),j=(0,l.useCallback)((()=>React.createElement(n.Ay,{variant:"body-small",className:"description"},E||t.description,k&&!x&&React.createElement(v.I,{className:"videopress-card__no-video-tooltip",tracksEventName:"videopress_card_tooltip_open",tracksEventProps:{location:"description",feature:"jetpack-videopress",status:b,video_count:x}},React.createElement("h3",null,y.title),React.createElement("p",null,y.text)))),[E,t.description,x,b,y,k]);return React.createElement(d.A,o()({},e,{slug:f,showMenu:!0,Description:j,customLoadTracks:C}),React.createElement(h.A,{isPluginActive:k,data:r,isLoading:w}))}},56544:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(3924),o=a(86087),n=a(27723),l=a(51609),s=a(64526);const __=n.__,_n=n._n,i=e=>{const{recordEvent:t}=(0,s.A)(),{featuredStats:a,videoCount:i=0}=e||{},{period:c}=a||{},u=(0,r.A)("jetpack-videopress-my-jetpack-tooltip"),d=(0,l.useCallback)((()=>{t("jetpack_videopress_card_tooltip_content_link_click",{location:"video_count",feature:"jetpack-videopress",page:"my-jetpack",path:u})}),[t,u]),v={title:__("The finest video for WordPress","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)((0,n.sprintf)( -// translators: %d is the number of videos in the Media Library that could benefit from VideoPress. -_n("You have %d video in your Media Library that could benefit from VideoPress. Start hosting it today to unlock multiple benefits: enhanced quality add-free streaming, faster load times, customizable player controls.","You have %d videos in your Media Library that could benefit from VideoPress. Start hosting them today to unlock multiple benefits: enhanced quality add-free streaming, faster load times, customizable player controls.",i,"jetpack-my-jetpack"),i),{a:(0,l.createElement)("a",{href:u,target:"_blank",rel:"noreferrer noopener",onClick:d})})},p={title:__("The finest video for WordPress","jetpack-my-jetpack"),text:__("Give your videos a boost! 🚀 Try hosting with VideoPress for superior quality and performance.","jetpack-my-jetpack")},m={title:__("High-quality video, wherever your audience is","jetpack-my-jetpack"),text:__("Success! 🌟 Your video is live and gathering views.","jetpack-my-jetpack")},h=__("30-Day views","jetpack-my-jetpack"),f=__("Yearly views","jetpack-my-jetpack"),g=__("This metric shows your total video views over the past 30 days, compared to the previous 30 days.","jetpack-my-jetpack"),w=__("This metric shows your total video views over the past year.","jetpack-my-jetpack"),b={title:"day"===c?h:f,text:"day"===c?g:w},y=__("This metric shows your total video viewing time over the past 30 days, compared to the previous 30 days.","jetpack-my-jetpack"),x=__("This metric shows total video viewing time for the last year.","jetpack-my-jetpack");return{inactiveWithVideos:v,activeAndNoVideos:p,viewsWithoutPlan:m,viewsWithPlan:b,watchTime:{title:__("Total time watched","jetpack-my-jetpack"),text:"day"===c?y:x}}}},83554:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(27723),o=a(72434);const __=r.__,n=({isPluginActive:e,videoCount:t})=>!e&&t?(0,o.A)(__("Load your existing videos faster and without ads.","jetpack-my-jetpack")):e&&!t?(0,o.A)(__("Stunning-quality, ad-free video in the WordPress Editor. Begin by uploading your first video.","jetpack-my-jetpack")):""},77167:(e,t,a)=>{"use strict";a.d(t,{A:()=>g});var r=a(27723),o=a(51113),n=a(62510),l=a(66955),s=a(13022),i=a(31504),c=a(74923),u=a(56581),d=a(32753),v=a(12660),p=a(81434),m=a(10372),h=a(56544);a(20906);const __=r.__,f=({value:e,previousValue:t,formattedValue:a,formattedDifference:r,period:i})=>{const c=e>t;return React.createElement("div",{className:"videopress-card__value-section__value-container"},React.createElement("span",{className:"videopress-card__value-section__value"},a),e!==t&&"day"===i&&React.createElement("div",{className:(0,s.A)("videopress-card__value-section__previous-value",c?"increase":"decrease")},React.createElement(o.A,{size:18,icon:c?n.A:l.A}),React.createElement("span",null,r)))},g=({isPluginActive:e,data:t,isLoading:a})=>{const{detail:r}=(0,c.A)(i.D_.VIDEOPRESS),{status:o,hasPaidPlanForProduct:n}=r||{},{videoCount:l,featuredStats:g}=t||{},{inactiveWithVideos:w,viewsWithoutPlan:b,viewsWithPlan:y,watchTime:x}=(0,h.A)(t);if(!l&&!a)return null;const _={feature:"jetpack-videopress",has_paid_plan:n,status:o};if(!e)return React.createElement("div",{className:"videopress-card__value-section"},React.createElement("div",{className:"videopress-card__value-section__container"},React.createElement("span",{className:m.A.valueSectionHeading},__("Existing videos","jetpack-my-jetpack"),a?React.createElement(p.A,{height:"32px",width:"100%"}):React.createElement(React.Fragment,null,React.createElement(v.I,{className:"videopress-card__no-video-tooltip",tracksEventName:"videopress_card_tooltip_open",tracksEventProps:{location:"existing_videos",feature:"jetpack-videopress",status:o,video_count:l}},React.createElement("h3",null,w.title),React.createElement("p",null,w.text)))),React.createElement("span",{className:"videopress-card__video-count"},l)));const k=g?.data?.views?.current,E=g?.data?.watch_time?.current,C=g?.data?.views?.previous,j=g?.data?.watch_time?.previous,A=g?.period,S=Math.abs(k-C),P=Math.abs(E-j);if(!a&&(void 0===k||void 0===E))return null;const R=__("30-Day views","jetpack-my-jetpack"),M=__("Yearly views","jetpack-my-jetpack");return React.createElement("div",{className:"videopress-card__value-section"},React.createElement("div",{className:"videopress-card__value-section__container"},React.createElement("span",{className:(0,s.A)(m.A.valueSectionHeading,"videopress-card__value-section__heading")},"day"===A?R:M,React.createElement(v.I,{tracksEventName:"videopress_card_tooltip_open",tracksEventProps:{location:"views",current_views:k,previous_views:C,period:A,..._}},n||0===k?React.createElement(React.Fragment,null,React.createElement("h3",null,y.title),React.createElement("p",null,y.text)):React.createElement(React.Fragment,null,React.createElement("h3",null,b.title),React.createElement("p",null,b.text)))),a?React.createElement(p.A,{height:"32px",width:"100%"}):React.createElement(f,{value:k,previousValue:C,formattedValue:(0,u.A)(k),formattedDifference:(0,u.A)(S),period:A})),React.createElement("div",{className:"videopress-card__value-section__container"},React.createElement("span",{className:(0,s.A)(m.A.valueSectionHeading,"videopress-card__value-section__heading")},__("Total time watched","jetpack-my-jetpack"),React.createElement(v.I,{tracksEventName:"videopress_card_tooltip_open",tracksEventProps:{location:"watch_time",current_watch_time:E,previous_watch_time:j,period:A,..._}},React.createElement("h3",null,x.title),React.createElement("p",null,x.text))),a?React.createElement(p.A,{height:"32px",width:"100%"}):React.createElement(f,{value:E,previousValue:j,formattedValue:(0,d.A)(E),formattedDifference:(0,d.A)(P),period:A})))}},73614:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(56427),o=a(28120),n=a.n(o),l=a(51609),s=a.n(l);const i=({children:e,className:t,href:a,isLoading:o=!1,onClick:n,isPrimary:l=!0,disabled:i=!1})=>s().createElement(r.Button,{onClick:n,className:t,href:a,variant:l?"primary":"secondary",disabled:o||i},o?s().createElement(r.Spinner,null):e);i.propTypes={className:n().string,isLoading:n().bool,isPrimary:n().bool,disabled:n().bool};const c=i},14720:(e,t,a)=>{"use strict";a.d(t,{A:()=>j});var r=a(67397),o=a(47425),n=a(78478),l=a(42266),s=a(85879),i=a(39384),c=a(56427),u=a(27723),d=a(51113),v=a(45459),p=a(83883),m=a(13022),h=a(51609),f=a.n(h),g=a(74923),w=a(68242),b=a(64526),y=a(1524),x=a(81434),_=a(73614),k=a(21557);const __=u.__;function E({value:e,currency:t,isOld:a}){if(!e||!t)return null;const n=(0,r.vA)(e,t),l=(0,m.A)(k.A.price,{[k.A["is-old"]]:a});return f().createElement(o.Ay,{className:l,variant:"headline-medium",component:"p"},f().createElement(o.Ay,{component:"sup",variant:"title-medium"},n.symbol),n.integer,f().createElement(o.Ay,{component:"sup",variant:"title-medium"},n.fraction))}const C=({component:e,onClick:t,hasMainCheckoutStarted:a,isFetching:r,isFetchingSuccess:n,cantInstallPlugin:l,isPrimary:s,className:i,label:c})=>{const[u,d]=(0,h.useState)(!1);(0,h.useEffect)((()=>{r||n||d(!1)}),[r,n]);const v=a||u,p=a||l||r||n;return f().createElement(o.Ay,{component:e,onClick:()=>{d(!0),t()},isLoading:v,disabled:p,isPrimary:s,className:i,variant:"body"},c)},j=({slug:e,onClick:t,trackButtonClick:a=()=>{},className:r,preferProductName:j,supportingInfo:A,ctaButtonLabel:S=null,hideTOS:P=!1,quantity:R=null,highlightLastFeature:M=!1,isFetching:V=!1,isFetchingSuccess:z=!1,isUpsell:H=!1})=>{const{fileSystemWriteAccess:L="no",siteSuffix:O="",adminUrl:N="",myJetpackCheckoutUri:I=""}=(0,w.A$)(),{detail:B,isLoading:T}=(0,g.A)(e),{name:F,title:D,longDescription:G,features:U,disclaimers:q,pricingForUi:Z,isBundle:W,supportedProducts:$,hasPaidPlanForProduct:J,status:K,pluginSlug:Q,postCheckoutUrl:Y}=B,X=W&&H,ee="plugin_absent"===K&&"no"===L,{isFree:te,trialAvailable:ae,fullPricePerMonth:re,currencyCode:oe,discountPricePerMonth:ne,wpcomProductSlug:le,wpcomFreeProductSlug:se,introductoryOffer:ie,productTerm:ce}=Z||{},{recordEvent:ue}=(0,b.A)(),de=!te&&!J||null!=R,ve=(0,y.y)(),pe=(0,h.useCallback)((()=>Y||(ve||I)),[Y,ve,I])(),{run:me,hasCheckoutStarted:he}=(0,i.useProductCheckoutWorkflow)({productSlug:le,redirectUrl:pe,siteSuffix:O,adminUrl:N,connectAfterCheckout:!0,from:"my-jetpack",quantity:R,useBlogIdSuffix:!0}),{run:fe,hasCheckoutStarted:ge}=(0,i.useProductCheckoutWorkflow)({productSlug:se,redirectUrl:pe,siteSuffix:O,adminUrl:N,connectAfterCheckout:!0,from:"my-jetpack",quantity:R,useBlogIdSuffix:!0}),we=X?$.join("_plus_").split("_").map(((e,t)=>{if("plus"===e)return f().createElement(d.A,{className:k.A["plus-icon"],key:`icon-plugs${t}`,icon:v.A,size:14});const a=(0,n.Wy)(e);return f().createElement(a,{key:e,size:24})})):null;let be;be="month"===ie?.intervalUnit&&1===ie?.intervalCount?(0,u.sprintf)( -// translators: %s is the monthly price for a product -__("trial for the first month, then $%s /month, billed yearly","jetpack-my-jetpack"),re):"year"===ce?__("/month, paid yearly","jetpack-my-jetpack"):__("/month","jetpack-my-jetpack",0);const ye=(0,h.useCallback)((t=>{ue("jetpack_myjetpack_product_card_disclaimer_click",{id:t,product:e})}),[e,ue]);function xe({slug:e}){const t=(0,n.Wy)(e);return t?f().createElement("div",{className:k.A["product-icon"]},f().createElement(t,null)):null}const _e=(!X||X&&!J)&&ae,ke=F&&j?F:D,Ee=!X&&J?(0,u.sprintf)(/* translators: placeholder is product name. */ -__("Install %s","jetpack-my-jetpack"),ke):(0,u.sprintf)(/* translators: placeholder is product name. */ -__("Get %s","jetpack-my-jetpack"),ke),Ce=S||Ee,je=(0,h.useCallback)((()=>{a({cta_text:Ce}),t?.(me,B)}),[t,a,me,B,Ce]),Ae=(0,h.useCallback)((()=>{a({custom_slug:se,cta_text:"Start for free"}),t?.(fe,B)}),[t,a,fe,se,B]),Se=ie?.reason?re:ne;return f().createElement("div",{className:(0,m.A)(k.A.card,r,{[k.A["is-bundle-card"]]:X})},X&&f().createElement("div",{className:k.A["card-header"]},f().createElement(n.Gg,{className:k.A["product-bundle-icon"],size:16}),f().createElement(o.Ay,{variant:"label"},__("Popular upgrade","jetpack-my-jetpack"))),f().createElement("div",{className:k.A.container},X&&f().createElement("div",{className:k.A["product-bundle-icons"]},we),f().createElement(xe,{slug:e}),f().createElement(o.H3,null,ke),T?f().createElement(x.A,{width:"100%",height:"75px",spaceBelow:!0}):f().createElement(o.Ay,{mb:3},G),T?f().createElement(x.A,{width:"100%",height:"250px",spaceBelow:!0}):f().createElement("ul",{className:(0,m.A)(k.A.features,{[k.A["highlight-last-feature"]]:M})},U.map(((e,t)=>f().createElement(o.Ay,{component:"li",key:`feature-${t}`,variant:"body"},f().createElement(d.A,{icon:p.A,size:24}),e)))),T&&f().createElement(x.A,{width:"100%",height:"70px",spaceBelow:!0}),de&&Se&&f().createElement(f().Fragment,null,f().createElement("div",{className:k.A["price-container"]},f().createElement(E,{value:Se,currency:oe,isOld:!1}),Se0&&f().createElement("div",{className:k.A.disclaimers},q.map(((e,t)=>{const{text:a,link_text:r=null,url:n=null}=e;return f().createElement(o.Ay,{key:`disclaimer-${t}`,component:"p",variant:"body-small"},`${a} `,n&&r&&f().createElement(c.ExternalLink,{onClick:()=>ye(t),href:n,target:"_blank",rel:"noopener noreferrer"},r))}))),X&&J&&f().createElement("div",{className:k.A["product-has-required-plan"]},f().createElement(n.Nr,{size:36}),f().createElement(o.Ay,null,__("Active on your site","jetpack-my-jetpack"))),A&&f().createElement(o.Ay,{className:k.A["supporting-info"],variant:"body-extra-small"},A)))}},33574:(e,t,a)=>{"use strict";a.d(t,{A:()=>x});var r=a(79245),o=a(489),n=a(51112),l=a(47656),s=a(47425),i=a(39384),c=a(27723),u=a(28120),d=a.n(u),v=a(51609),p=a(488),m=a(74923),h=a(68242),f=a(1524),g=a(81434),w=a(68957);const __=c.__,b=({cantInstallPlugin:e,onProductButtonClick:t,detail:a,isFetching:l,isFetchingSuccess:s,tier:u,trackProductButtonClick:d,preferProductName:m,feature:w})=>{const[b,y]=(0,v.useState)(!1),{isLoading:x}=(0,p.V)(),{siteSuffix:_="",myJetpackCheckoutUri:k="",adminUrl:E=""}=(0,h.A$)(),{name:C,featuresByTier:j=[],title:A,postCheckoutUrl:S,postCheckoutUrlsByFeature:P,isBundle:R,hasPaidPlanForProduct:M}=a,V=a?.pricingForUi?.tiers||{},{callToAction:z,currencyCode:H,fullPrice:L,introductoryOffer:O,isFree:N,wpcomProductSlug:I,quantity:B=null}=V[u]||{};(0,v.useEffect)((()=>{l||s||y(!1)}),[l,s]);const T=(0,f.y)(),F=(0,v.useCallback)((()=>w&&P?.[w]?P[w]:S||(T||k)),[w,P,S,T,k])(),{run:D,hasCheckoutStarted:G}=(0,i.useProductCheckoutWorkflow)({from:"my-jetpack",productSlug:I,redirectUrl:F,connectAfterCheckout:!0,siteSuffix:_,useBlogIdSuffix:!0,quantity:B,adminUrl:E}),U=L?Math.round(L/12*100)/100:null,q=O?.costPerInterval?Math.round(O.costPerInterval/12*100)/100:null,Z="month"===O?.intervalUnit&&1===O?.intervalCount,W=Z?(0,c.sprintf)( -// translators: %s is the monthly price for a product -__("trial for the first month, then $%s /month, billed yearly","jetpack-my-jetpack"),U):__("/month, paid yearly","jetpack-my-jetpack",0),$=C&&m?C:A,J=!R&&M?(0,c.sprintf)(/* translators: placeholder is product name. */ -__("Install %s","jetpack-my-jetpack"),$):(0,c.sprintf)(/* translators: placeholder is product name. */ -__("Get %s","jetpack-my-jetpack"),$),K=z||(N?__("Start for Free","jetpack-my-jetpack"):J),Q=(0,v.useCallback)((()=>{y(!0),d({is_free_plan:N,cta_text:K}),t?.(D,a,u)}),[d,t,D,a,u,N,K]),Y=G||b,X=G||e||l||s,ee=!O?.reason;return React.createElement(r.N0,{primary:!N},React.createElement(r.i7,null,x&&React.createElement(g.A,{width:"100%",height:"70px",spaceBelow:!0}),N?React.createElement(o.A,{price:0,legend:"",currency:"USD",hidePriceFraction:!0}):!M&&React.createElement(o.A,{price:U,offPrice:ee?q:U,legend:W,currency:H,hideDiscountLabel:Z,showNotOffPrice:ee,hidePriceFraction:!0}),React.createElement(n.A,{fullWidth:!0,variant:N?"secondary":"primary",onClick:Q,isLoading:Y,disabled:X},K)),j.map(((e,t)=>{const{included:a,description:o,struck_description:n,info:l}=e.tiers[u],s=n||o?React.createElement(React.Fragment,null,n?React.createElement(React.Fragment,null,React.createElement("del",null,n)," "):null,o?React.createElement("strong",null,o):null):null;return React.createElement(r.eY,{key:t,isIncluded:a,label:s,tooltipTitle:l?.title,tooltipInfo:l?.content?React.createElement("div",{dangerouslySetInnerHTML:{__html:l?.content}}):null,tooltipClassName:l?.class})})))};b.propTypes={cantInstallPlugin:d().bool.isRequired,onProductButtonClick:d().func.isRequired,detail:d().object.isRequired,tier:d().string.isRequired,trackProductButtonClick:d().func.isRequired,preferProductName:d().bool.isRequired};const y=({slug:e,onProductButtonClick:t,trackProductButtonClick:a,isFetching:o,isFetchingSuccess:i,preferProductName:u,feature:d})=>{const{fileSystemWriteAccess:p="no"}=(0,h.A$)(),{detail:f,isLoading:y}=(0,m.A)(e),{description:x,featuresByTier:_=[],pluginSlug:k,status:E,tiers:C=[],hasPaidPlanForProduct:j,title:A}=f,S=f?.pricingForUi||{},P=[...Array(3).keys()],R="plugin_absent"===E&&"no"===p,M=R&&React.createElement(l.A,{level:"error",hideCloseButton:!0,title:React.createElement(s.Ay,null,(0,c.sprintf)( -// translators: %s is the plugin name. -__("Due to your server settings, we can't automatically install the plugin for you. Please manually install the %s plugin.","jetpack-my-jetpack"),A)),actions:[React.createElement(n.A,{key:"get",variant:"secondary",href:`https://wordpress.org/plugins/${k}`,isExternalLink:!0},__("Get plugin","jetpack-my-jetpack"))]}),V=(0,v.useMemo)((()=>_.map((e=>({name:e?.name,tooltipTitle:e?.info?.title,tooltipInfo:e?.info?.content?React.createElement("div",{dangerouslySetInnerHTML:{__html:e?.info?.content}}):null})))),[_]);return React.createElement(React.Fragment,null,M,y?React.createElement("div",{className:w.A.loadingBlockContainer},P.map(((e,t)=>React.createElement(g.A,{key:t,width:"100%",height:"700px"})))):React.createElement(r.Ay,{title:x,items:V},C.map(((e,r)=>j&&(e=>{if(y)return!1;const{isFree:t}=S?.[e]||{};return t})(e)?null:React.createElement(b,{key:r,tier:e,feature:d,detail:f,isFetching:o,isFetchingSuccess:i,onProductButtonClick:t,trackProductButtonClick:a,primary:0===r,cantInstallPlugin:R,preferProductName:u})))))};y.propTypes={slug:d().string.isRequired,onProductButtonClick:d().func.isRequired,trackProductButtonClick:d().func.isRequired,isFetching:d().bool.isRequired,preferProductName:d().bool.isRequired};const x=y},21022:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(47425),o=a(51113),n=a(83883),l=a(13022),s=a(81434),i=a(34291);const c=({features:e,isLoading:t,className:a})=>{if(!t&&!e?.length)return null;const c=[...Array(8).keys()];return React.createElement("ul",{className:(0,l.A)(i.A.features,a)},t?c.map(((e,t)=>React.createElement(s.A,{key:t,height:"25px",width:"100%",spaceBelow:!0}))):e.map(((e,t)=>React.createElement(r.Ay,{component:"li",key:`feature-${t}`,variant:"body"},React.createElement(o.A,{icon:n.A,size:24}),e))))}},46397:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(51112),o=a(39384),n=a(27723),l=a(51609),s=a(74923),i=a(68242),c=a(1524),u=a(34291);const __=n.__,d=({slug:e,buttonLabel:t,disabled:a,isExternalLink:n,href:d})=>{const{siteSuffix:v="",adminUrl:p="",myJetpackCheckoutUri:m=""}=(0,i.A$)(),{detail:h,isLoading:f}=(0,s.A)(e),{pricingForUi:g,postCheckoutUrl:w}=h,{wpcomProductSlug:b,tiers:y}=g||{},x="boost"!==e?b:y?.upgraded?.wpcomProductSlug,_=(0,c.y)(),k=(0,l.useCallback)((()=>w||(_||m)),[w,_,m])(),{run:E,hasCheckoutStarted:C}=(0,o.useProductCheckoutWorkflow)({productSlug:x,redirectUrl:k,siteSuffix:v,adminUrl:p,connectAfterCheckout:!0,from:"my-jetpack",quantity:null,useBlogIdSuffix:!0});return React.createElement(r.A,{variant:"primary",className:u.A["action-button"],isLoading:f||C,onClick:E,isExternalLink:n,href:d,disabled:a||f},t||__("Upgrade","jetpack-my-jetpack"))}},39368:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var r=a(51112),o=a(50723),n=a(75918),l=a(28509),s=a(47425),i=a(56427),c=a(27723),u=a(13022),d=a(51609),v=a(81434),p=a(34291);const __=c.__,m=e=>{const{title:t,description:a,className:c,children:m,customModalTrigger:h,modalTriggerButtonLabel:f,modalTriggerButtonVariant:g="primary",onOpen:w,onClose:b,onModalMainButtonClick:y,modalMainButton:x,isButtonDisabled:_,buttonHasExternalLink:k=!1,buttonHref:E,buttonLabel:C,secondaryButtonHasExternalLink:j=!0,secondaryButtonHref:A,secondaryColumn:S,isWithVideo:P=!0,additionalColumn:R=!1,priceComponent:M,isLoading:V}=e,[z,H]=(0,d.useState)(!1),L=(0,d.useCallback)((()=>{w?.(),H(!0)}),[w]),O=(0,d.useCallback)((()=>{b?.(),H(!1)}),[b]);if(!t||!f&&!h)return null;const N=h?(0,d.cloneElement)(h,{onClick:()=>{h.props.onClick?.(),L()}}):React.createElement(r.A,{variant:g,onClick:L},f),I=x&&(0,d.cloneElement)(x,{onClick:y,buttonLabel:C,disabled:_,isExternalLink:k,href:E});return React.createElement(React.Fragment,null,React.createElement(o.Ay,null,N,z&&React.createElement(i.Modal,{onRequestClose:O,className:(0,u.A)(p.A["component-product-interstitial-modal"],c),overlayClassName:p.A["component-product-interstitial-modal__overlay"]},React.createElement(n.A,{className:p.A.wrapper,horizontalSpacing:1,horizontalGap:2,fluid:!1},React.createElement(l.A,{sm:4,md:8,lg:4,className:p.A.primary},React.createElement("div",{className:p.A["primary-content"]},React.createElement("div",{className:p.A.header},React.createElement(s.Ay,{variant:"headline-small",className:p.A.title},t)),V?React.createElement(v.A,{height:"50px",width:"100%"}):a&&React.createElement(s.Ay,{variant:"body",className:p.A.description},a),m,V?React.createElement(v.A,{height:"100px",width:"100%"}):M&&React.createElement("div",{className:p.A["price-container"]},M)),React.createElement("div",{className:p.A["primary-footer"]},I,React.createElement(r.A,{variant:"link",isExternalLink:j,href:A},__("Learn more","jetpack-my-jetpack")))),React.createElement(l.A,{sm:4,md:R?4:8,lg:R?4:8,className:(0,u.A)(p.A.secondary,{[p.A["modal-with-video"]]:P})},S),R&&React.createElement(l.A,{sm:4,md:4,lg:4,className:p.A.additional},R)))))}},23116:(e,t,a)=>{"use strict";a.d(t,{A:()=>y});var r=a(96072),o=a.n(r),n=a(489),l=a(51112),s=a(3924),i=a(70116),c=a(77115),u=a(86087),d=a(27723),v=a(51609),p=a(74923),m=a(64526),h=a(81434),f=a(39368),g=a(46397),w=a(21022);const __=d.__,b=({slug:e,children:t,onOpen:a,onClose:r,description:i,features:c,...b})=>{const{recordEvent:y}=(0,m.A)(),{detail:x,isLoading:_}=(0,p.A)(e),{title:k,longDescription:E,features:C,pricingForUi:j}=x,A=i||E,S=c||C,P="boost"===e?j?.tiers?.upgraded:j;let R,M;"boost"===e?(R=P?.fullPrice/12,M=P?.discountPrice/12):(R=P?.fullPricePerMonth,M=P?.discountPricePerMonth);const{currencyCode:V,introductoryOffer:z,productTerm:H}=P||{};let L;L="month"===z?.intervalUnit&&1===z?.intervalCount?(0,d.sprintf)( -// translators: %s is the monthly price for a product -__("trial for the first month, then $%s /month, billed yearly","jetpack-my-jetpack"),R):"year"===H?__("/month, paid yearly","jetpack-my-jetpack"):__("/month","jetpack-my-jetpack",0);const O=z?.reason?R:M,N=_?React.createElement(h.A,{width:"100%",height:"100px"}):React.createElement(n.A,{currency:V,price:R,offPrice:O,showNotOffPrice:R>O,isNotConvenientPrice:!1,hidePriceFraction:!1,hideDiscountLabel:O>=R,legend:L}),I=(0,v.useCallback)((()=>{y("jetpack_modal_interstitial_open",{placement:"product-page",context:"my-jetpack",product_slug:e}),a?.()}),[y,e,a]),B=(0,v.useCallback)((()=>{y("jetpack_modal_interstitial_close",{placement:"product-page",context:"my-jetpack",product_slug:e}),r?.()}),[y,e,r]);let T=null;return"jetpack-ai"===e&&(T=React.createElement("p",null,(0,u.createInterpolateElement)(__("* Limits apply for high request capacity. Learn more about it here.","jetpack-my-jetpack"),{link:React.createElement(l.A,{href:(0,s.A)("ai-assistant-fair-usage-policy"),variant:"link",weight:"regular",size:"small",target:"_blank"})}))),React.createElement(f.A,o()({title:k,description:A,priceComponent:N,modalMainButton:React.createElement(g.A,{slug:e}),onOpen:I,onClose:B,isLoading:_},b),React.createElement(React.Fragment,null,(_||S)&&React.createElement(w.A,{isLoading:_,features:S}),T,t))},y=e=>{const t=new i.E;return React.createElement(c.Ht,{client:t},React.createElement(b,e))}},36092:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>O,C:()=>U,Gf:()=>Z,JM:()=>W,Ml:()=>J,NC:()=>$,QX:()=>F,Qt:()=>K,X7:()=>T,og:()=>G,qT:()=>D,t7:()=>q,wU:()=>N,xE:()=>I,yX:()=>B});var r=a(42947),o=a(75918),n=a(28509),l=a(47425),s=a(51112),i=a(85879),c=a(85985),u=a(86087),d=a(27723),v=a(13022),p=a(51609),m=a.n(p),h=a(29539),f=a(38837),g=a(41526),w=a(74923),b=a(68242),y=a(64526),x=a(13588),_=a(51870),k=a(33981),E=a(11617),C=a(14720),j=a(33574),A=a(58769),S=a(98019),P=a(25296),R=a(72279),M=a(17642),V=a(35148),z=a(59409),H=a(9851),L=a(5044);const __=d.__;function O({bundle:e,existingLicenseKeyUrl:t="admin.php?page=my-jetpack#/add-license",installsPlugin:a=!1,slug:h,supportingInfo:A,preferProductName:S=!1,children:P=null,imageContainerClassName:R="",ctaButtonLabel:M=null,hideTOS:V=!1,quantity:z=null,directCheckout:L=!1,highlightLastFeature:O=!1,ctaCallback:N=null,feature:I=null}){const{detail:B}=(0,w.A)(h),{detail:T}=(0,w.A)(e),{activate:F,isPending:D,isSuccess:G}=(0,g.A)(h);let U=B?.postActivationUrl||null;I&&B?.postActivationUrlsByFeature?.[I]&&(U=B.postActivationUrlsByFeature[I]);const{isUpgradableByBundle:q,pricingForUi:Z,isTieredPricing:W}=B,{recordEvent:$}=(0,y.A)(),{onClickGoBack:J}=(0,x.L)({slug:h}),{myJetpackCheckoutUri:K=""}=(0,b.A$)(),{siteIsRegistering:Q,handleRegisterSite:Y}=(0,_.A)({skipUserConnection:!0,redirectUri:U}),X=!V&&!!e,ee=B?.title,te=T?.title,ae=[/* translators: %s is the product name */ /* translators: %s is the product name */ -(0,d.sprintf)(__("Get %s","jetpack-my-jetpack"),ee),/* translators: %s is the bundled product name */ /* translators: %s is the bundled product name */ -(0,d.sprintf)(__("Get %s","jetpack-my-jetpack"),te)];(0,p.useEffect)((()=>{$("jetpack_myjetpack_product_interstitial_view",{product:h})}),[$,h]);const re=(0,p.useCallback)(((e=!1)=>e?"":"crm"===h?"jetpack-crm":Z?.tiers?.upgraded?.wpcomProductSlug?Z.tiers.upgraded.wpcomProductSlug:Z?.wpcomProductSlug),[h,Z]),oe=(0,p.useCallback)((t=>{const{customSlug:a=null,isFreePlan:r=!1,ctaText:o=null}=t||{};$("jetpack_myjetpack_product_interstitial_add_link_click",{product:a||(e??h),product_slug:re(r),cta_text:o})}),[$,h,re,e]),ne=(0,k.A)(f.NM.Home),le=(0,p.useCallback)(((e,t,a)=>{N?.({slug:h,product:t,tier:a}),t?.isBundle||L?e?.():F({productId:h},{onSettled:r=>{let o=r?.post_checkout_url||K;I&&r?.post_checkout_urls_by_feature?.[I]&&(o=r.post_checkout_urls_by_feature[I]);const n=t?.hasPaidPlanForProduct,l=a?t?.pricingForUi?.tiers?.[a]?.isFree:t?.pricingForUi?.isFree,s=!l&&!n||a&&t?.pricingForUi?.tiers?.[a]&&!l&&t?.isUpgradable;"zero-bs-crm"!==t.pluginSlug||n?s?e?.(null,o):Y().then((e=>{if(!e)return ne()})):window.location.href="https://jetpackcrm.com/pricing/"}})}),[K,I,N,h,L,F,Y,ne]);return m().createElement(r.A,{showHeader:!1,showBackground:!1,useInternalLinks:(0,c.pg)()},m().createElement(o.A,{horizontalSpacing:3,horizontalGap:3},m().createElement(n.A,{className:H.A["product-interstitial__header"]},m().createElement(E.A,{onClick:J}),t&&m().createElement(l.Ay,{variant:"body-small"},(0,u.createInterpolateElement)(__("Already have an existing plan or license key? Get started.","jetpack-my-jetpack"),{a:m().createElement(s.A,{className:H.A["product-interstitial__license-activation-link"],href:t,variant:"link"})}))),m().createElement(n.A,null,W?m().createElement(j.A,{slug:h,clickHandler:le,onProductButtonClick:le,trackProductButtonClick:oe,preferProductName:S,isFetching:D||Q,isFetchingSuccess:G,feature:I}):m().createElement(o.A,{className:q?null:H.A.container,horizontalSpacing:0,horizontalGap:0,fluid:!0},m().createElement(n.A,{sm:4,md:4,lg:7},m().createElement(C.A,{slug:h,trackButtonClick:oe,onClick:a?le:void 0,className:q?H.A.container:null,supportingInfo:A,preferProductName:S,ctaButtonLabel:M,hideTOS:V||X,quantity:z,highlightLastFeature:O,isFetching:D||Q,isFetchingSuccess:G})),m().createElement(n.A,{sm:4,md:4,lg:5,className:(0,v.A)(H.A.imageContainer,R)},e?m().createElement(C.A,{slug:e,trackButtonClick:oe,onClick:le,className:q?H.A.container:null,hideTOS:V||X,quantity:z,highlightLastFeature:O,isFetching:D,isFetchingSuccess:G,isUpsell:!0}):P))),m().createElement(n.A,null,X&&m().createElement("div",{className:H.A["tos-container"]},m().createElement(i.A,{multipleButtons:ae})))))}function N(){const e="anti-spam",{detail:t}=(0,w.A)(e),{isPluginActive:a}=t;return m().createElement(O,{slug:e,installsPlugin:!0,bundle:"security",existingLicenseKeyUrl:a?"admin.php?page=akismet-key-config":null,preferProductName:!0})}function I(){return m().createElement(O,{slug:"backup",installsPlugin:!0,bundle:"security"})}function B(){return m().createElement(O,{slug:"boost",installsPlugin:!0},m().createElement("img",{src:A,alt:"Boost"}))}function T(){return m().createElement(O,{slug:"crm",installsPlugin:!0},m().createElement("img",{src:P,alt:"CRM"}))}function F(){return m().createElement(O,{slug:"extras",installsPlugin:!0},m().createElement("img",{src:R,alt:"Extras"}))}function D(){const{feature:e}=(0,h.g)();return m().createElement(O,{slug:"protect",feature:e,installsPlugin:!0})}function G(){return m().createElement(O,{slug:"scan",installsPlugin:!0,bundle:"security"})}function U(){return m().createElement(O,{slug:"social",installsPlugin:!0,bundle:"growth"})}function q(){const{detail:e}=(0,w.A)("search");return m().createElement(O,{slug:"search",installsPlugin:!0,supportingInfo:(e?.pricingForUi?.trialAvailable?__("Jetpack Search Free supports up to 5,000 records and 500 search requests per month for free. You will be asked to upgrade to a paid plan if you exceed these limits for three continuous months.","jetpack-my-jetpack"):"")+__("For the paid plan, pricing will automatically adjust based on the number of records in your search index. If you grow into a new pricing tier, we'll let you know before your next billing cycle.","jetpack-my-jetpack")},m().createElement("img",{src:M,alt:"Search"}))}function Z(){return m().createElement(O,{slug:"stats",directCheckout:!0,installsPlugin:!0,ctaButtonLabel:__("Get Stats","jetpack-my-jetpack"),bundle:"growth"})}function W(){return m().createElement(O,{slug:"videopress",installsPlugin:!0},m().createElement("img",{src:L,alt:"VideoPress"}))}function $(){return m().createElement(O,{slug:"security",installsPlugin:!0},m().createElement("img",{src:V,alt:"Security"}))}function J(){return m().createElement(O,{slug:"growth",installsPlugin:!0},m().createElement("img",{src:z,alt:"Growth"}))}function K(){return m().createElement(O,{slug:"complete",installsPlugin:!0},m().createElement("img",{src:S,alt:"Complete"}))}},93418:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var r=a(51112),o=a(86087),n=a(27723),l=a(46941),s=a.n(l),i=a(51609),c=a(36092),u=a(74923),d=a(51870),v=a(19923),p=a(67691);const __=n.__,m=s()("my-jetpack:product-interstitial:jetpack-ai");function h(){const{detail:e}=(0,u.A)("jetpack-ai");m(e);const t=e?.aiAssistantFeature?.tierPlansEnabled||!1,{userConnectionData:a}=(0,d.A)(),{currentUser:n}=a,{wpcomUser:l}=n,s=`jetpack_ai_optfree_${n?.id||0}_${n?.blogId||0}_${l?.ID||0}`,h=(0,i.useCallback)((({tier:e})=>{"free"===e&&localStorage.setItem(s,!0)}),[s]),f=(0,o.createInterpolateElement)(__("* Limits apply for high request capacity. Learn more about it here.","jetpack-my-jetpack"),{link:React.createElement(r.A,{href:"https://jetpack.com/redirect/?source=ai-assistant-fair-usage-policy",variant:"link",weight:"regular",size:"small",target:"_blank"})});return React.createElement(c.Ay,{slug:"jetpack-ai",installsPlugin:!0,imageContainerClassName:p.A.aiImageContainer,hideTOS:!0,directCheckout:!1,ctaCallback:h,ctaButtonLabel:__("Upgrade","jetpack-my-jetpack"),supportingInfo:t?null:f},React.createElement("img",{src:v,alt:"Jetpack AI"}))}},8823:(e,t,a)=>{"use strict";a.d(t,{A:()=>V});var r=a(3924),o=a(42947),n=a(75918),l=a(28509),s=a(67142),i=a(78478),c=a(47656),u=a(85985),d=a(56427),v=a(86087),p=a(27723),m=a(51113),h=a(83883),f=a(10748),g=a(45459),w=a(13022),b=a(46941),y=a.n(b),x=a(51609),_=a(74923),k=a(64526),E=a(13588),C=a(51870),j=a(33981),A=a(11617),S=a(81434),P=a(23116),R=a(67691);const __=p.__,M=y()("my-jetpack:product-interstitial:jetpack-ai-product-page");function V(){const{onClickGoBack:e}=(0,E.L)("jetpack-ai"),{detail:t,isLoading:a}=(0,_.A)("jetpack-ai"),{description:b,aiAssistantFeature:y}=t,[V,z]=(0,x.useState)(!1),{isRegistered:H}=(0,C.A)(),L=__("Generate and edit content faster with Jetpack AI Assistant","jetpack-my-jetpack"),O=__("Create featured images with one click","jetpack-my-jetpack"),N=__("Optimize your titles effortlessly","jetpack-my-jetpack"),I=__("Build forms using prompts","jetpack-my-jetpack"),B=__("Get feedback on posts","jetpack-my-jetpack"),T=__("Make your writing easy to read","jetpack-my-jetpack");M(y);const{requestsCount:F=0,currentTier:D,nextTier:G,usagePeriod:U,isOverLimit:q,tierPlansEnabled:Z}=y||{},W=0===D?.value,$=1===D?.value,J=!W&&!$||$&&!Z,K=!$&&J&&!G&&D,Q=W&&20-F>=0?20-F:0,Y=J&&!W&&U,X=J||$,ee=(0,r.A)("jetpack-ai-tiers-more-requests-contact"),te=(0,r.A)("jetpack-ai-feedback"),ae=(0,r.A)("jetpack-ai-product-page-featured-image-link"),re=(0,r.A)("jetpack-ai-product-page-title-optimization-link"),oe=(0,r.A)("jetpack-ai-product-page-form-link"),ne=(0,r.A)("jetpack-ai-product-page-content-feedback-link"),le=(0,r.A)("jetpack-ai-product-page-breve"),se=H?"post-new.php?use_ai_block=1&_wpnonce="+window?.jetpackAi?.nonce:"#/connection",ie=__("Create new post","jetpack-my-jetpack"),ce=__("Connect to Jetpack to start using the AI Assistant","jetpack-my-jetpack"),ue=q&&J,de=q&&W,ve=D?.limit||0,pe=U?.requestsCount||0,me=Z?ve-pe>=0?ve-pe:0:pe,he=__("Requests this month","jetpack-my-jetpack"),fe=__("Requests for this month","jetpack-my-jetpack"),ge=__("You've reached your request limit for this month","jetpack-my-jetpack"),we=__("You've used all your free requests","jetpack-my-jetpack"),be=(0,p.sprintf)( -// translators: %d is the number of days left in the month. -__("Wait for %d days to reset your limit, or upgrade now to a higher tier for additional requests and keep your work moving forward.","jetpack-my-jetpack"),Math.floor((new Date(U?.nextStart||null)-new Date)/864e5)),ye=(0,v.createInterpolateElement)((0,p.sprintf)( -// translators: %d is the number of days left in the month. -__("Wait for %d days to reset your limit, per our fair usage policy.","jetpack-my-jetpack"),Math.floor((new Date(U?.nextStart||null)-new Date)/864e5)),{link:React.createElement("a",{href:(0,r.A)("ai-product-page-fair-usage-policy"),target:"_blank",rel:"noreferrer"})}),xe=Z?be:ye,_e=__("Reach for More with Jetpack AI! Upgrade now for additional requests and keep your momentum going.","jetpack-my-jetpack"),ke=(0,p.sprintf)( -// translators: %s is the next upgrade value -__("Get %s requests","jetpack-my-jetpack"),G?.value||"more"),Ee=__("Upgrade now","jetpack-my-jetpack"),Ce=(0,j.A)("/add-jetpack-ai"),{recordEvent:je}=(0,k.A)(),Ae=(0,x.useCallback)((()=>{je("jetpack_ai_upgrade_contact_us",{placement:"product-page"})}),[je]),Se=(0,x.useCallback)((()=>{je("jetpack_ai_upgrade_button",{placement:"product-page",context:"my-jetpack",current_tier_slug:D?.slug||"",requests_count:F}),Ce()}),[je,F,D,Ce]),Pe=(0,x.useCallback)((()=>{je("jetpack_ai_upgrade_button",{placement:"product-page",context:"my-jetpack",current_tier_slug:D?.slug||"",requests_count:F})}),[je,F,D]),Re=(0,x.useCallback)((()=>z(!1)),[]);(0,x.useEffect)((()=>{je("jetpack_ai_myjetpack_product_page_view",{current_tier_slug:D?.slug||"",requests_count:F})}),[F,D?.slug,je]),(0,x.useEffect)((()=>{z(ue||de)}),[ue,de]);const Me=React.createElement("span",{className:R.A["product-interstitial__new-badge"]},__("New","jetpack-my-jetpack")," ");return React.createElement(o.A,{showHeader:!1,showBackground:!0,useInternalLinks:(0,u.pg)()},React.createElement(n.A,{fluid:!0,horizontalSpacing:3,horizontalGap:2},React.createElement(l.A,{className:(0,w.A)(R.A["product-interstitial__section"])},React.createElement("div",{className:R.A["product-interstitial__section-wrapper-wide"]},React.createElement(A.A,{onClick:e})),React.createElement("div",{className:(0,w.A)(R.A["product-interstitial__section-wrapper-wide"],R.A["product-interstitial__product-header"])},React.createElement(s.A,null),React.createElement("div",{className:R.A["product-interstitial__product-header-name"]},__("AI Assistant","jetpack-my-jetpack")))),React.createElement(l.A,{className:(0,w.A)(R.A["product-interstitial__section"])},React.createElement("div",{className:R.A["product-interstitial__hero-section"]},React.createElement("div",{className:R.A["product-interstitial__hero-content"]},a?React.createElement(S.A,{height:"80px",width:"100%"}):React.createElement("h1",{className:R.A["product-interstitial__hero-heading"]},b),React.createElement("div",{className:R.A["product-interstitial__hero-sub-heading"]},__("Draft, transform, translate, and alter both new and existing content leveraging the capabilities of AI, inside the block editor.","jetpack-my-jetpack")),!K&&!$&&React.createElement(React.Fragment,null,React.createElement(P.A,{slug:"jetpack-ai",onOpen:Pe,modalTriggerButtonLabel:__("Get more requests","jetpack-my-jetpack"),buttonLabel:__("Upgrade","jetpack-my-jetpack"),isWithVideo:!0,secondaryColumn:React.createElement("div",null,React.createElement("iframe",{width:"621",height:"447",src:"https://video.wordpress.com/embed/whyeZF1t?cover=1&autoPlay=0&controls=0&loop=1&muted=0&persistVolume=1&playsinline=0&preloadContent=metadata&useAverageColor=1&posterUrl=https%3A%2F%2Fjetpack.com%2Fwp-content%2Fuploads%2F2024%2F09%2Fthumbnail-1.png&hd=1",allowFullScreen:!0,allow:"clipboard-write",title:__("Discover Jetpack AI","jetpack-my-jetpack")}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),secondaryButtonHref:"https://jetpack.com/ai/"})),K&&React.createElement(d.Button,{variant:"primary",onClick:Ae,href:ee,className:R.A["product-interstitial__hero-cta"]},__("Contact Us","jetpack-my-jetpack"))),React.createElement("div",{className:R.A["product-interstitial__hero-side"]},Y&&React.createElement(d.Card,{className:R.A["stats-card"]},React.createElement(i.KH,null),React.createElement("div",null,React.createElement("div",{className:R.A["product-interstitial__stats-card-text"]},Z?fe:he),React.createElement("div",{className:R.A["product-interstitial__stats-card-value"]},me))),X&&React.createElement(d.Card,{className:R.A["stats-card"]},React.createElement(m.A,{icon:h.A,className:R.A["stats-card-icon-check"]}),React.createElement("div",null,React.createElement("div",{className:R.A["product-interstitial__stats-card-text"]},__("All-time requests used","jetpack-my-jetpack")),React.createElement("div",{className:R.A["product-interstitial__stats-card-value"]},F))),W&&React.createElement(d.Card,{className:R.A["stats-card"]},React.createElement(m.A,{icon:h.A,className:R.A["stats-card-icon-check"]}),React.createElement("div",null,React.createElement("div",{className:R.A["product-interstitial__stats-card-text"]},__("Free requests available","jetpack-my-jetpack")),React.createElement("div",{className:R.A["product-interstitial__stats-card-value"]},Q)))))),React.createElement(l.A,{className:R.A["product-interstitial__section"]},React.createElement("div",{className:R.A["product-interstitial__section-wrapper"]},V&&React.createElement("div",{className:R.A["product-interstitial__ai-notice"]},React.createElement(c.A,{actions:Z?[React.createElement(d.Button,{key:"upgrade",isPrimary:!0,onClick:Se},ue?ke:Ee)]:{},onClose:Re,level:ue?"warning":"error",title:ue?ge:we},ue?xe:_e)),React.createElement("h2",{className:R.A["product-interstitial__section-heading"]},__("AI Features","jetpack-my-jetpack")),React.createElement("p",{className:R.A["product-interstitial__section-sub-heading"]},__("Discover all the Jetpack features powered by AI","jetpack-my-jetpack")),React.createElement("div",{className:R.A["product-interstitial__usage-videos"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-item"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-video"]},React.createElement("iframe",{width:"280",height:"157",src:"https://videopress.com/embed/2OU6GCMs?posterUrl=https%3A%2F%2Fjetpackme.files.wordpress.com%2F2024%2F07%2Fjetpack-ai-breve-poster.png%3Fw%3D560",allowFullScreen:!0,allow:"clipboard-write",title:T}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),React.createElement("div",{className:R.A["product-interstitial__usage-videos-content"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-heading"]},T,Me),React.createElement("div",{className:R.A["product-interstitial__usage-videos-text"]},__("Simplify your writing with AI suggestions to fix long sentences and complex words and sound more confident. As you type, check your Reading grade score to make sure it suits your audience.","jetpack-my-jetpack")),React.createElement(d.Button,{className:R.A["product-interstitial__usage-videos-link"],icon:f.A,target:"_blank",href:le},__("Learn more","jetpack-my-jetpack")))),React.createElement("div",{className:R.A["product-interstitial__usage-videos-item"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-video"]},React.createElement("iframe",{width:"280",height:"157",src:"https://videopress.com/embed/GdXmtVtW?posterUrl=https%3A%2F%2Fjetpackme.files.wordpress.com%2F2024%2F02%2Fimage-37.png%3Fw%3D560",allowFullScreen:!0,allow:"clipboard-write",title:L}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),React.createElement("div",{className:R.A["product-interstitial__usage-videos-content"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-heading"]},L),React.createElement("div",{className:R.A["product-interstitial__usage-videos-text"]},__("Use the AI block to generate content, or use our AI edit options in existing blocks. Use prompts or any of our recommended actions.","jetpack-my-jetpack")),React.createElement(d.Button,{className:R.A["product-interstitial__usage-videos-link"],icon:g.A,href:se},H?ie:ce))),React.createElement("div",{className:R.A["product-interstitial__usage-videos-item"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-video"]},React.createElement("iframe",{width:"280",height:"157",src:"https://videopress.com/embed/HJCf8cXc?posterUrl=https%3A%2F%2Fjetpackme.files.wordpress.com%2F2024%2F02%2Fone-click-featured-images.png%3Fw%3D560",allowFullScreen:!0,allow:"clipboard-write",title:O}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),React.createElement("div",{className:R.A["product-interstitial__usage-videos-content"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-heading"]},O),React.createElement("div",{className:R.A["product-interstitial__usage-videos-text"]},__("Create featured images to illustrate your content and make it more engaging with just one click. Use prompts to generate adjusted new featured images.","jetpack-my-jetpack")),React.createElement(d.Button,{className:R.A["product-interstitial__usage-videos-link"],icon:f.A,target:"_blank",href:ae},__("Learn about featured images","jetpack-my-jetpack")))),React.createElement("div",{className:R.A["product-interstitial__usage-videos-item"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-video"]},React.createElement("iframe",{width:"280",height:"157",src:"https://videopress.com/embed/xjy2weWj?posterUrl=https%3A%2F%2Fjetpackme.files.wordpress.com%2F2024%2F06%2Fjetpack-ai-title-optimization.png%3Fw%3D560",allowFullScreen:!0,allow:"clipboard-write",title:N}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),React.createElement("div",{className:R.A["product-interstitial__usage-videos-content"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-heading"]},N),React.createElement("div",{className:R.A["product-interstitial__usage-videos-text"]},__("Use AI to generate title suggestions based on your content, each with an explanation of why it works better. Save time and create engaging, SEO-friendly titles.","jetpack-my-jetpack")),React.createElement(d.Button,{className:R.A["product-interstitial__usage-videos-link"],icon:f.A,target:"_blank",href:re},__("Learn about Jetpack SEO tools","jetpack-my-jetpack")))),React.createElement("div",{className:R.A["product-interstitial__usage-videos-item"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-video"]},React.createElement("iframe",{width:"280",height:"157",src:"https://videopress.com/embed/OMI3zqid?posterUrl=https%3A%2F%2Fjetpackme.files.wordpress.com%2F2024%2F02%2Fimage-38.png%3Fw%3D560",allowFullScreen:!0,allow:"clipboard-write",title:I}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),React.createElement("div",{className:R.A["product-interstitial__usage-videos-content"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-heading"]},I),React.createElement("div",{className:R.A["product-interstitial__usage-videos-text"]},__("Quickly build forms using the Jetpack Forms block and AI. Use prompts to describe your form and AI will generate the elements in a few seconds.","jetpack-my-jetpack")),React.createElement(d.Button,{className:R.A["product-interstitial__usage-videos-link"],icon:f.A,target:"_blank",href:oe},__("Learn about forms","jetpack-my-jetpack")))),React.createElement("div",{className:R.A["product-interstitial__usage-videos-item"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-video"]},React.createElement("iframe",{width:"280",height:"157",src:"https://videopress.com/embed/0vb0OJm7?posterUrl=https%3A%2F%2Fjetpackme.files.wordpress.com%2F2024%2F02%2Fimage-39.png%3Fw%3D560",allowFullScreen:!0,allow:"clipboard-write",title:B}),React.createElement("script",{src:"https://videopress.com/videopress-iframe.js"})),React.createElement("div",{className:R.A["product-interstitial__usage-videos-content"]},React.createElement("div",{className:R.A["product-interstitial__usage-videos-heading"]},B),React.createElement("div",{className:R.A["product-interstitial__usage-videos-text"]},__("Get instant feedback on your post before publishing. AI will read your post and highlight opportunities to improve your publication.","jetpack-my-jetpack")),React.createElement(d.Button,{className:R.A["product-interstitial__usage-videos-link"],icon:f.A,target:"_blank",href:ne},__("Learn more","jetpack-my-jetpack"))))))),React.createElement(l.A,{className:R.A["product-interstitial__section"]},React.createElement("div",{className:R.A["product-interstitial__section-wrapper"]},React.createElement("div",{className:R.A["product-interstitial__section-emoji"]},"👋"),React.createElement("h2",{className:R.A["product-interstitial__section-heading"]},__("Do you have any feedback?","jetpack-my-jetpack")),React.createElement("p",{className:R.A["product-interstitial__section-sub-heading"]},__("Help us improving the accuracy of our results and feel free to give us ideas for future implementations and improvements.","jetpack-my-jetpack")," ",React.createElement(d.ExternalLink,{href:te},__("Share your feedback!","jetpack-my-jetpack")))))))}},38802:(e,t,a)=>{"use strict";a.d(t,{Ay:()=>l,SF:()=>r,p4:()=>s,su:()=>o,wT:()=>n});const r="title",o="status",n="category",l="description",s="icon"},54972:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("g",{clipPath:"url(#clip0_4668_7926)"},React.createElement("path",{d:"M34.214 21.6924L40.7619 38.9784C41.3267 40.4574 42.1943 40.9935 43.6778 41.1189C43.732 41.1213 43.7851 41.1349 43.8339 41.1588C43.8827 41.1828 43.926 41.2164 43.9613 41.2578C43.9966 41.2992 44.023 41.3474 44.039 41.3995C44.055 41.4516 44.0602 41.5063 44.0543 41.5605C44.0565 41.6164 44.0476 41.6722 44.0282 41.7247C44.0087 41.7771 43.9791 41.8252 43.9411 41.866C43.903 41.9069 43.8572 41.9398 43.8064 41.9628C43.7556 41.9858 43.7008 41.9985 43.6451 42.0001H36.473C36.415 42.0015 36.3574 41.9911 36.3035 41.9695C36.2496 41.948 36.2007 41.9157 36.1596 41.8746C36.1185 41.8335 36.0861 41.7845 36.0643 41.7305C36.0426 41.6765 36.032 41.6187 36.0331 41.5605C36.0288 41.504 36.0363 41.4473 36.055 41.3938C36.0736 41.3403 36.1031 41.2913 36.1415 41.2499C36.18 41.2084 36.2265 41.1753 36.2783 41.1528C36.33 41.1302 36.3859 41.1187 36.4423 41.1189C37.1626 41.1189 37.979 40.9299 37.979 40.0486C37.9727 39.6811 37.8977 39.3181 37.758 38.9784L36.1865 34.7899C36.1231 34.6009 36.0924 34.5372 35.9042 34.5372H29.9189C28.9777 34.5372 27.8175 34.5372 27.2834 35.7348L25.851 38.9784C25.7054 39.2727 25.6198 39.5933 25.5994 39.9213C25.5994 41.0552 27.0747 41.1189 27.8502 41.1189C27.9066 41.1187 27.9625 41.1302 28.0142 41.1528C28.066 41.1753 28.1126 41.2084 28.151 41.2499C28.1894 41.2913 28.2189 41.3403 28.2376 41.3938C28.2562 41.4473 28.2637 41.504 28.2595 41.5605C28.2606 41.6188 28.2499 41.6767 28.228 41.7307C28.2061 41.7847 28.1735 41.8337 28.1322 41.8747C28.0908 41.9156 28.0416 41.9477 27.9875 41.9689C27.9334 41.9901 27.8755 42 27.8175 41.998H21.4537C21.3958 41.9995 21.3382 41.989 21.2845 41.9674C21.2307 41.9459 21.1819 41.9135 21.1409 41.8724C21.1 41.8313 21.0678 41.7823 21.0463 41.7283C21.0248 41.6744 21.0144 41.6166 21.0158 41.5584C21.0116 41.502 21.019 41.4452 21.0377 41.3917C21.0563 41.3383 21.0858 41.2893 21.1242 41.2478C21.1627 41.2063 21.2092 41.1733 21.261 41.1507C21.3128 41.1282 21.3686 41.1166 21.425 41.1168C22.9618 41.0223 23.4713 40.2951 24.0585 38.9763L31.6173 22.3518C31.9631 21.6266 32.7161 20.998 33.4057 20.998C33.9009 21.0001 34.0585 21.2836 34.214 21.6924ZM28.4845 32.9637C28.4466 33.0197 28.4247 33.0851 28.4211 33.1527C28.4211 33.2164 28.4845 33.2472 28.6094 33.2472H34.8197C35.2576 33.2472 35.4458 33.1527 35.4458 32.8692C35.4452 32.727 35.4131 32.5866 35.3517 32.4584L33.6267 27.7974C33.2175 26.7272 32.6241 25.3118 32.4358 24.1451C32.4358 24.0834 32.4031 24.0506 32.3724 24.0506C32.3417 24.0506 32.311 24.0834 32.311 24.1451C32.0755 24.9473 31.7708 25.7274 31.4004 26.4766L28.4845 32.9637Z",fill:"#0CED57"}),React.createElement("path",{d:"M34.214 21.6924L40.7619 38.9784C41.3267 40.4574 42.1943 40.9935 43.6778 41.1189C43.732 41.1213 43.7851 41.1349 43.8339 41.1589C43.8827 41.1828 43.926 41.2164 43.9613 41.2578C43.9966 41.2992 44.023 41.3474 44.039 41.3995C44.055 41.4516 44.0602 41.5063 44.0543 41.5605C44.0565 41.6164 44.0476 41.6722 44.0282 41.7247C44.0087 41.7771 43.9791 41.8252 43.9411 41.866C43.903 41.9069 43.8572 41.9398 43.8064 41.9628C43.7556 41.9858 43.7008 41.9985 43.6451 42.0001H36.473C36.415 42.0015 36.3574 41.9911 36.3035 41.9695C36.2496 41.948 36.2007 41.9157 36.1596 41.8746C36.1185 41.8335 36.0861 41.7845 36.0643 41.7305C36.0426 41.6766 36.032 41.6187 36.0331 41.5605C36.0288 41.504 36.0363 41.4473 36.055 41.3938C36.0736 41.3403 36.1031 41.2913 36.1415 41.2499C36.18 41.2084 36.2265 41.1753 36.2783 41.1528C36.33 41.1302 36.3859 41.1187 36.4423 41.1189C37.1626 41.1189 37.979 40.9299 37.979 40.0486C37.9727 39.6811 37.8977 39.3181 37.758 38.9784L36.1865 34.7899C36.1231 34.6009 36.0924 34.5372 35.9042 34.5372H29.9189C28.9777 34.5372 27.8175 34.5372 27.2834 35.7348L25.851 38.9784C25.7054 39.2727 25.6198 39.5933 25.5994 39.9213C25.5994 41.0552 27.0747 41.1189 27.8502 41.1189C27.9066 41.1187 27.9625 41.1302 28.0142 41.1528C28.066 41.1753 28.1126 41.2084 28.151 41.2499C28.1894 41.2913 28.2189 41.3403 28.2376 41.3938C28.2562 41.4473 28.2637 41.504 28.2595 41.5605C28.2606 41.6188 28.2499 41.6767 28.228 41.7307C28.2061 41.7847 28.1735 41.8337 28.1322 41.8747C28.0908 41.9156 28.0416 41.9477 27.9875 41.9689C27.9334 41.9901 27.8755 42 27.8175 41.998H21.4537C21.3958 41.9995 21.3382 41.989 21.2845 41.9675C21.2307 41.9459 21.1819 41.9135 21.1409 41.8724C21.1 41.8313 21.0678 41.7823 21.0463 41.7283C21.0248 41.6744 21.0144 41.6166 21.0158 41.5584C21.0116 41.502 21.019 41.4452 21.0377 41.3918C21.0563 41.3383 21.0858 41.2893 21.1242 41.2478C21.1627 41.2063 21.2092 41.1733 21.261 41.1507C21.3128 41.1282 21.3686 41.1166 21.425 41.1168C22.9618 41.0223 23.4713 40.2951 24.0585 38.9763L31.6173 22.3518C31.9631 21.6266 32.7161 20.998 33.4057 20.998C33.9009 21.0001 34.0585 21.2836 34.214 21.6924ZM28.4845 32.9637C28.4466 33.0197 28.4247 33.0851 28.4211 33.1527C28.4211 33.2164 28.4845 33.2472 28.6094 33.2472H34.8197C35.2576 33.2472 35.4458 33.1527 35.4458 32.8692C35.4452 32.727 35.4131 32.5866 35.3517 32.4584L33.6267 27.7974C33.2175 26.7272 32.6241 25.3118 32.4358 24.1451C32.4358 24.0834 32.4031 24.0506 32.3724 24.0506C32.3417 24.0506 32.311 24.0834 32.311 24.1451C32.0755 24.9473 31.7708 25.7274 31.4004 26.4766L28.4845 32.9637Z",fill:"#0CED57"}),React.createElement("path",{d:"M46.0082 32.2219C46.0082 33.0312 45.5519 33.4893 44.7272 33.4893C43.9026 33.4893 43.5752 33.0682 43.5752 32.4252C43.5752 31.6159 44.052 31.1578 44.8561 31.1578C45.6603 31.1578 46.0082 31.5974 46.0082 32.2219Z",fill:"#0CED57"}),React.createElement("path",{d:"M21.4351 32.2487C21.4351 33.056 20.9768 33.5162 20.1542 33.5162C19.3316 33.5162 18.998 33.093 18.998 32.4501C18.998 31.6428 19.4748 31.1826 20.279 31.1826C21.0832 31.1826 21.4351 31.6243 21.4351 32.2487Z",fill:"#0CED57"})),React.createElement("defs",null,React.createElement("clipPath",{id:"clip0_4668_7926"},React.createElement("rect",{width:"27",height:"21",fill:"white",transform:"translate(19 21)"}))))},56222:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M26.5118 27.9597C26.4453 27.957 26.3784 27.9556 26.3113 27.9556C23.5621 27.9556 21.3335 30.2539 21.3335 33.0889C21.3335 35.924 23.5621 38.2223 26.3113 38.2223L26.3409 38.2221H38.376L38.3996 38.2223C40.756 38.2223 42.6663 36.2523 42.6663 33.8223C42.6663 31.6421 41.1288 29.8323 39.111 29.4831L39.1112 29.4223C39.1112 26.1823 36.2459 23.5557 32.7112 23.5557C29.7275 23.5557 27.2207 25.4273 26.5118 27.9597C26.5118 27.9597 26.5118 27.9597 26.5118 27.9597ZM37.0923 31.1635L37.1111 29.4609L37.1112 29.4223C37.1112 27.4471 35.3087 25.5557 32.7112 25.5557C30.5416 25.5557 28.8833 26.9074 28.4377 28.4989L28.0111 30.0227L26.4301 29.958C26.3908 29.9564 26.3512 29.9556 26.3113 29.9556C24.7243 29.9556 23.3335 31.3 23.3335 33.0889C23.3335 34.876 24.7213 36.2194 26.3063 36.2223L26.3349 36.2221H38.3874L38.3996 36.2223C39.5939 36.2223 40.6663 35.2061 40.6663 33.8223C40.6663 32.5872 39.8018 31.6324 38.7699 31.4539L37.0923 31.1635Z",fill:"#0CED57"}))},66155:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M37.3154 32L31.2603 25.3393L32.7401 23.994L40.0183 32L32.7401 40.006L31.2603 38.6606L37.3154 32ZM29.3154 32L23.2603 25.3393L24.7401 23.994L32.0183 32L24.7401 40.006L23.2603 38.6606L29.3154 32Z",fill:"#0CED57"}))},90638:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M36.6667 30.6667C38.5076 30.6667 40 29.1743 40 27.3333C40 25.4924 38.5076 24 36.6667 24C34.8257 24 33.3333 25.4924 33.3333 27.3333C33.3333 29.1743 34.8257 30.6667 36.6667 30.6667ZM36.6667 28.6667C37.403 28.6667 38 28.0697 38 27.3333C38 26.597 37.403 26 36.6667 26C35.9303 26 35.3333 26.597 35.3333 27.3333C35.3333 28.0697 35.9303 28.6667 36.6667 28.6667Z",fill:"#0CED57"}),React.createElement("path",{d:"M33.6667 38.6667V36C33.6667 33.975 32.025 32.3333 30 32.3333H24.6667C22.6416 32.3333 21 33.975 21 36V38.6667H23V36C23 35.0795 23.7462 34.3333 24.6667 34.3333H30C30.9205 34.3333 31.6667 35.0795 31.6667 36V38.6667H33.6667Z",fill:"#0CED57"}),React.createElement("path",{d:"M43 36V38.6667H41V36C41 35.0795 40.2538 34.3333 39.3333 34.3333H36V32.3333H39.3333C41.3584 32.3333 43 33.975 43 36Z",fill:"#0CED57"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M30.6667 27.3333C30.6667 29.1743 29.1743 30.6667 27.3333 30.6667C25.4924 30.6667 24 29.1743 24 27.3333C24 25.4924 25.4924 24 27.3333 24C29.1743 24 30.6667 25.4924 30.6667 27.3333ZM28.6667 27.3333C28.6667 28.0697 28.0697 28.6667 27.3333 28.6667C26.597 28.6667 26 28.0697 26 27.3333C26 26.597 26.597 26 27.3333 26C28.0697 26 28.6667 26.597 28.6667 27.3333Z",fill:"#0CED57"}))},41081:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{d:"M24.5 20L25.7728 23.2272L29 24.5L25.7728 25.7728L24.5 29L23.2272 25.7728L20 24.5L23.2272 23.2272L24.5 20Z",fill:"#0CED57"}),React.createElement("path",{d:"M38 20L39.6971 24.3029L44 26L39.6971 27.6971L38 32L36.3029 27.6971L32 26L36.3029 24.3029L38 20Z",fill:"#0CED57"}),React.createElement("path",{d:"M30.5 29L32.6213 34.3787L38 36.5L32.6213 38.6213L30.5 44L28.3787 38.6213L23 36.5L28.3787 34.3787L30.5 29Z",fill:"#0CED57"}))},38579:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M32 20.2349L41 24.3258V30.4242C41 35.6229 37.6611 40.545 32.9529 42.0978C32.3343 42.3019 31.6657 42.3019 31.0471 42.0978C26.3389 40.545 23 35.6229 23 30.4242V24.3258L32 20.2349ZM25 25.6136V30.4242C25 34.8415 27.8602 38.9408 31.6735 40.1985C31.8853 40.2683 32.1147 40.2683 32.3265 40.1985C36.1398 38.9408 39 34.8415 39 30.4242V25.6136L32 22.4318L25 25.6136Z",fill:"#0CED57"}))},49932:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M42 30.2586C42 34.8196 38.3025 38.5171 33.7414 38.5171C31.833 38.5171 30.0757 37.8698 28.6772 36.7827L23.4599 42L22 40.5401L27.2173 35.3228C26.1302 33.9243 25.4828 32.167 25.4828 30.2586C25.4828 25.6975 29.1803 22 33.7414 22C38.3025 22 42 25.6975 42 30.2586ZM39.9354 30.2586C39.9354 33.6794 37.1622 36.4525 33.7414 36.4525C30.3206 36.4525 27.5475 33.6794 27.5475 30.2586C27.5475 26.8377 30.3206 24.0646 33.7414 24.0646C37.1622 24.0646 39.9354 26.8377 39.9354 30.2586Z",fill:"#0CED57"}))},11733:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("g",null,React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M35.9287 23.8145V37.553L27.832 35.1813V39.4872H26.314V34.7366L23.557 33.929C22.4903 33.6165 21.7607 32.666 21.7607 31.5884V29.7791C21.7607 28.7015 22.4903 27.751 23.557 27.4385L35.9287 23.8145ZM34.4107 35.5751L27.832 33.648L27.832 27.7195L34.4107 25.7924V35.5751ZM26.314 28.1642L26.314 33.2033L23.9973 32.5247C23.5705 32.3997 23.2787 32.0194 23.2787 31.5884V29.7791C23.2787 29.348 23.5705 28.9678 23.9973 28.8428L26.314 28.1642ZM37.9529 31.4183H42.0009V29.9509H37.9529V31.4183ZM42.0009 35.575L37.9529 34.5967V33.1293L42.0009 34.1076V35.575ZM37.9529 28.2384L42.0009 27.2601V25.7927L37.9529 26.771V28.2384Z",fill:"#0CED57"})))},47587:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{d:"M31 22.6667H33V42.6667H31V22.6667Z",fill:"#0CED57"}),React.createElement("path",{d:"M24 29.3333H26V42.6667H24V29.3333Z",fill:"#0CED57"}),React.createElement("path",{d:"M40 34.6667H38V42.6667H40V34.6667Z",fill:"#0CED57"}))},17946:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=()=>React.createElement("svg",{className:"table-view-icon",width:"64",height:"64",viewBox:"0 0 64 64",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement("rect",{width:"64",height:"64",rx:"8",fill:"#003010"}),React.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M21.545 23C22.6814 23 23.6798 23.7522 23.991 24.8427L27.0674 35.6252C27.0705 35.6361 27.0755 35.6461 27.0821 35.6548L30.7267 23H32.7655H38.4016C42.352 23 45 25.5644 45 29.4466C45 33.3733 42.2825 35.8219 38.228 35.8219H35.5539H32.1081L31.4387 37.8894C30.8383 39.7436 29.1082 41 27.1553 41C25.2024 41 23.4722 39.7436 22.8719 37.8894L19.125 26.3175C18.5944 24.6788 19.8191 23 21.545 23ZM33.3536 31.9753H37.2556C38.9486 31.9753 39.9644 31.0048 39.9644 29.4466C39.9644 27.8795 38.9486 26.9534 37.2556 26.9534H34.9796L33.3536 31.9753Z",fill:"#0CED57"}))},31421:(e,t,a)=>{"use strict";a.d(t,{A:()=>j});var r=a(29491),o=a(3613),n=a(27723),l=a(51113),s=a(29115),i=a(51609),c=a(29539),u=a(488),d=a(64526),v=a(17885),p=a(38802),m=a(54972),h=a(56222),f=a(66155),g=a(90638),w=a(41081),b=a(38579),y=a(49932),x=a(11733),_=a(47587),k=a(17946);a(76812);const __=n.__,E={backup:h.A,protect:b.A,"anti-spam":m.A,"jetpack-ai":w.A,boost:f.A,search:y.A,videopress:k.A,stats:_.A,crm:g.A,social:x.A},C=e=>`product-title-${e}`,j=({products:e})=>{const t=(0,i.useCallback)((e=>e.product.slug),[]),a=(0,i.useCallback)((e=>{S(e)}),[]),{data:n,isLoading:m,isError:h}=(0,u.V)(),f=(0,r.useViewportMatch)("medium","<"),g=(0,c.Zp)(),{recordEvent:w}=(0,d.A)(),[b,y]=(0,i.useState)([]),x={list:{...{sort:{field:p.SF,direction:"asc"},type:"list",filters:[],page:1,perPage:10},fields:[p.Ay,p.su],titleField:p.SF,mediaField:p.p4,showMedia:!0}};(0,i.useEffect)((()=>{h||m||b.length||y(((e,t)=>[...new Set(e.map((e=>t[e].category)))].map((e=>({value:e,label:e}))))(e,n))}),[h,m,b,n,e]);const _=(0,i.useCallback)((e=>{w(`jetpack_myjetpack_product_list_item_${e}_learnmore_mobile_click`),g(`add-${e}`)}),[g,w]),k=(0,i.useCallback)((e=>{if(f){const t=e[0];_(t)}}),[_,f]),j=(0,i.useMemo)((()=>[{id:p.SF,label:__("Title","jetpack-my-jetpack"),enableGlobalSearch:!0,enableHiding:!1,getValue:({item:e})=>e.product.name,render:({item:e})=>{const{product:t}=e;return React.createElement("div",{id:C(t.slug)},t.name)}},{id:p.Ay,label:__("Description","jetpack-my-jetpack"),enableGlobalSearch:!0,enableHiding:!1,getValue:({item:e})=>e.product.description,render:({item:e})=>{const{product:t}=e;return React.createElement("div",null,t.description)}},{id:p.wT,label:__("Category","jetpack-my-jetpack"),enableGlobalSearch:!0,enableHiding:!0,filterBy:{isPrimary:!0,operators:["is"]},elements:b.length>1?b:[],isVisible:()=>!1,getValue:({item:e})=>e.product.category},{id:p.p4,label:__("Icon","jetpack-my-jetpack"),enableGlobalSearch:!1,enableHiding:!1,render({item:e}){const{product:t}=e,a=E[t.slug];return React.createElement(a,null)}},{id:p.su,label:"Status",enableGlobalSearch:!1,enableHiding:!1,getValue:({item:e})=>e.status,render:({item:e})=>{const{product:t}=e,{slug:a}=t;return f?React.createElement("button",{className:"product-list-item-chevron"},React.createElement(l.A,{icon:s.A,size:24})):React.createElement(v.A,{className:"product-list-item-cta",slug:a,tracksIdentifier:"product_list_item",labelSuffixId:C(a)})}}]),[f,_,b]),[A,S]=(0,i.useState)({type:"list",...x.list}),P=(0,i.useMemo)((()=>((e,t)=>e.map((e=>{const a=t[e],{description:r,name:o,status:n,slug:l,category:s}=a;return{product:{description:r,name:o,slug:l,category:s},status:n}})))(e,n)),[n,e]),{data:R,paginationInfo:M}=(0,i.useMemo)((()=>(0,o.Pp)(P,A,j)),[P,j,A]);return React.createElement(o.Vw,{actions:[],data:R,fields:j,view:A,getItemId:t,paginationInfo:M,onChangeView:a,defaultLayouts:x,onChangeSelection:k})}},48931:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(41040),o=a(27723),n=a(31504),l=a(280),s=a(51870),i=a(28252);const __=o.__,c=()=>{const{userConnectionData:e,isSiteConnected:t}=(0,s.A)(),a=e?.currentUser?.wpcomUser?.display_name||e?.currentUser?.wpcomUser?.login||e?.currentUser?.username,{isLoading:o,data:c}=(0,l.A)({name:n.Ck,query:{path:n.tb},options:{enabled:t}});if(o)return React.createElement(React.Fragment,null,__("Checking gold status…","jetpack-my-jetpack"));const u=(0,i.M)(c);return React.createElement(React.Fragment,null,React.createElement(r._,{tokenRedeemed:u,displayName:a}))}},49654:(e,t,a)=>{"use strict";a.d(t,{A:()=>f});var r=a(27723),o=a(51113),n=a(15788),l=a(61871),s=a(16994),i=a(51609),c=a.n(i),u=a(56581),d=a(90003),v=a(0),p=a(93336),m=a(71070);const __=r.__,_n=r._n,h=(e,t,a)=>{if("number"!=typeof t)return"";const o=[],n=(0,r.sprintf)(e(t),(0,u.A)(t));return o.push(n.endsWith(".")?n:`${n}.`),o.push((0,v.A)(e,t,a)),o.filter(Boolean).join(" ")},f=({counts:e,previousCounts:t,headingLevel:a})=>{const r=`h${a>=1&&a<=6?a:3}`;return c().createElement("div",{className:m.A["section-stats-highlights"]},c().createElement(r,{className:m.A["section-title"]},c().createElement("span",null,__("7-day highlights","jetpack-my-jetpack")),c().createElement("small",{className:m.A["section-description"]},__("Compared to previous period","jetpack-my-jetpack"))),c().createElement("ul",{className:m.A["cards-list"]},c().createElement(d.A,{heading:__("Views","jetpack-my-jetpack"),srText:h(( -// translators: %s: number of views -e=>_n("%s view","%s views",e,"jetpack-my-jetpack")),e?.views,t?.views),icon:c().createElement(o.A,{icon:p.A}),count:e?.views,previousCount:t?.views,as:"li"}),c().createElement(d.A,{heading:__("Visitors","jetpack-my-jetpack"),srText:h(( -// translators: %s: number of visitors -e=>_n("%s visitor","%s visitors",e,"jetpack-my-jetpack")),e?.visitors,t?.visitors),icon:c().createElement(o.A,{icon:n.A}),count:e?.visitors,previousCount:t?.visitors,as:"li"}),c().createElement(d.A,{heading:__("Likes","jetpack-my-jetpack"),srText:h(( -// translators: %s: number of likes -e=>_n("%s like","%s likes",e,"jetpack-my-jetpack")),e?.likes,t?.likes),icon:c().createElement(o.A,{icon:l.A}),count:e?.likes,previousCount:t?.likes,as:"li"}),c().createElement(d.A,{heading:__("Comments","jetpack-my-jetpack"),srText:h(( -// translators: %s: number of comments -e=>_n("%s comment","%s comments",e,"jetpack-my-jetpack")),e?.comments,t?.comments),icon:c().createElement(o.A,{icon:s.A}),count:e?.comments,previousCount:t?.comments,as:"li"})))}},90003:(e,t,a)=>{"use strict";a.d(t,{A:()=>h});var r=a(56427),o=a(51113),n=a(66955),l=a(62510),s=a(13022),i=a(28120),c=a.n(i),u=a(51609),d=a.n(u),v=a(56581),p=a(71070);const m=({count:e=0,previousCount:t=0,as:a="div",icon:i,heading:c,srText:u})=>{const m=(f=t,"number"!=typeof(h=e)||"number"!=typeof f?null:h-f);var h,f;const g=Math.abs(m),w=Number.isFinite(m)?((e,t)=>{if("number"!=typeof e||"number"!=typeof t)return null;if(0===e&&0===t)return 0;const a=e/t*100;return Math.abs(a)===1/0?100:Math.round(a)})(g,t):null;return d().createElement(r.Card,{className:p.A["stats-card"],as:a},d().createElement("span",{className:"screen-reader-text"},u),d().createElement("div",{"aria-hidden":"true"},i&&d().createElement("div",{className:p.A["stats-card-icon"]},i),c&&d().createElement("div",{className:p.A["stats-card-heading"]},c),d().createElement("div",{className:p.A["stats-card-count"]},d().createElement("span",{className:p.A["stats-card-count-value"],title:Number.isFinite(e)?String(e):void 0},(0,v.A)(e)),null!==m?d().createElement("span",{className:(0,s.A)(p.A["stats-card-difference"],{[p.A["stats-card-difference--positive"]]:m<0,[p.A["stats-card-difference--negative"]]:m>0})},d().createElement("span",{className:p.A["stats-card-difference-icon"],title:String(m)},m<0&&d().createElement(o.A,{size:18,icon:n.A}),m>0&&d().createElement(o.A,{size:18,icon:l.A})),d().createElement("span",{className:p.A["stats-card-difference-absolute-value"]},g>9999?(0,v.A)(g):(0,v.A)(g,{})),null!==w&&d().createElement("span",{className:p.A["stats-card-difference-absolute-percentage"]},"(",w,"%)")):null)))};m.propTypes={count:c().number,heading:c().node,icon:c().node,previousCount:c().number,srText:c().string};const h=m},0:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(27723),o=a(56581),n=a(88496);const __=r.__,l=(e,t,a)=>{if("number"!=typeof t||"number"!=typeof a)return"";const l=t-a;if(0===l)return __("No change since the previous period.","jetpack-my-jetpack");const s=e(Math.abs(l)),i=(0,r.sprintf)(s,(0,o.A)(Math.abs(l))),c=0!==a?Math.abs(l/a):null;return c?l>0?(0,r.sprintf)( -// translators: %1$s: stat difference (e.g. `5 views`), %2$s: stat difference percentage (e.g. `10%`) -__("An increase of %1$s or %2$s since the previous period.","jetpack-my-jetpack"),i,(0,n.A)(c)):(0,r.sprintf)( -// translators: %1$s: stat difference (e.g. `5 views`), %2$s: stat difference percentage (e.g. `10%`) -__("A decrease of %1$s or %2$s since the previous period.","jetpack-my-jetpack"),i,(0,n.A)(c)):l>0?(0,r.sprintf)( -// translators: %s: stat difference (e.g. `5 views`) -__("An increase of %s since the previous period.","jetpack-my-jetpack"),i):(0,r.sprintf)( -// translators: %s: stat difference (e.g. `5 views`) -__("A decrease of %s since the previous period.","jetpack-my-jetpack"),i)}},93336:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(56427);const o=React.createElement(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},React.createElement(r.Path,{d:"m4 13 .67.336.003-.005a2.42 2.42 0 0 1 .094-.17c.071-.122.18-.302.329-.52.298-.435.749-1.017 1.359-1.598C7.673 9.883 9.498 8.75 12 8.75s4.326 1.132 5.545 2.293c.61.581 1.061 1.163 1.36 1.599a8.29 8.29 0 0 1 .422.689l.002.005L20 13l.67-.336v-.003l-.003-.005-.008-.015-.028-.052a9.752 9.752 0 0 0-.489-.794 11.6 11.6 0 0 0-1.562-1.838C17.174 8.617 14.998 7.25 12 7.25S6.827 8.618 5.42 9.957c-.702.669-1.22 1.337-1.563 1.839a9.77 9.77 0 0 0-.516.845l-.008.015-.002.005-.001.002v.001L4 13Zm8 3a3.5 3.5 0 1 0 0-7 3.5 3.5 0 0 0 0 7Z"}))},1035:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var r=a(27723),o=a(51609),n=a(38837),l=a(31504),s=a(74923),i=a(280),c=a(68242),u=a(64526),d=a(51870),v=a(6176),p=a(49654);const __=r.__,m=()=>{const e="stats",{blogID:t,isSiteConnected:a}=(0,d.A)(),{detail:r}=(0,s.A)(e),{status:m}=r,h=!!(0,c.A$)("userIsAdmin"),{data:f}=(0,i.A)({name:l.MB,query:{path:(0,l.IM)(t)},options:{enabled:a}}),g=f?.past_seven_days||{},w=f?.between_past_eight_and_fifteen_days||{},{recordEvent:b}=(0,u.A)(),y=(0,o.useCallback)((()=>{b("jetpack_myjetpack_stats_card_seedetailedstats_click",{product:e})}),[b]),x=(0,o.useCallback)((()=>!(m!==n.hp.CAN_UPGRADE)),[m]),_={href:"admin.php?page=stats",label:__("View detailed stats","jetpack-my-jetpack"),onClick:y,shouldShowButton:x},k={[n.hp.ACTIVE]:{label:__("View detailed stats","jetpack-my-jetpack")},[n.hp.SITE_CONNECTION_ERROR]:{label:__("Connect Jetpack to use Stats","jetpack-my-jetpack")},[n.hp.NEEDS_FIRST_SITE_CONNECTION]:{href:`#/add-${e}`}};return React.createElement(v.A,{admin:h,slug:e,primaryActionOverride:k,secondaryAction:_,showMenu:!0},React.createElement(p.A,{counts:g,previousCounts:w,headingLevel:4}))}},7881:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(28509),o=a(47425),n=a(85879),l=a(51112),s=a(27723),i=a(36312),c=a(52290);const __=s.__,u=({isActivating:e})=>{const t=__("Activate Jetpack in one click","jetpack-my-jetpack"),{connectSite:a}=(0,i.A)({tracksInfo:{event:"jetpack_myjetpack_welcome_banner_connect_site",properties:{}}});return React.createElement(React.Fragment,null,React.createElement(r.A,{sm:6,md:8,lg:6,className:c.A["banner-description"]},React.createElement(o.Ay,{variant:"headline-small",mb:3},__("Welcome to Jetpack!","jetpack-my-jetpack")),React.createElement(o.Ay,{variant:"body",mb:2},__("Unlock the power of your WordPress site with Jetpack, the complete toolkit for enhancing your site’s security, speed, and growth.","jetpack-my-jetpack")),React.createElement(o.Ay,{variant:"body",mb:2},__("Jetpack works behind the scenes to keep your site safe, make it lightning-fast, and to help you get more traffic.","jetpack-my-jetpack")),React.createElement(n.A,{agreeButtonLabel:t,mb:4}),React.createElement(l.A,{variant:"primary",disabled:e,isLoading:e,onClick:a},e?__("Activating…","jetpack-my-jetpack"):t)),React.createElement(r.A,{sm:6,md:8,lg:6,className:c.A["banner-image"]}))}},36259:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var r=a(28509),o=a(47425),n=a(51112),l=a(56427),s=a(27723),i=a(13022),c=a(51609),u=a(52290);const __=s.__,d={protect:__("Protect my site","jetpack-my-jetpack"),performance:__("Improve my site‘s performance","jetpack-my-jetpack"),audience:__("Grow my audience","jetpack-my-jetpack"),content:__("Create quality content","jetpack-my-jetpack"),unsure:__("I don‘t know","jetpack-my-jetpack")},v={protect:!1,performance:!1,audience:!1,content:!1,unsure:!1},p=({onSkipOnboarding:e,onSubmitEvaluation:t})=>{const[a,s]=(0,c.useState)(v),p=(0,c.useCallback)((e=>t=>{s((a=>({...a,[e]:t})))}),[s]),m=(0,c.useCallback)((()=>t(a)),[t,a]),h=Object.values(a).some((e=>e));return React.createElement(React.Fragment,null,React.createElement(r.A,{sm:6,md:8,lg:6,className:u.A["banner-description"]},React.createElement(o.Ay,{variant:"headline-small",mb:3},__("What would you like Jetpack to do?","jetpack-my-jetpack")),React.createElement(o.Ay,{variant:"body",mb:2},__("Jetpack does a lot. Select the items that are most important to you and we‘ll find the Jetpack tools that are the best match for your site.","jetpack-my-jetpack")),React.createElement("form",{className:u.A.form},Object.entries(d).map((([e,t])=>React.createElement(l.CheckboxControl,{key:e,className:u.A["form-checkbox"],label:t,checked:a[e],onChange:p(e),__nextHasNoMarginBottom:!0}))),React.createElement("div",{className:u.A["form-actions"]},React.createElement(n.A,{variant:"primary",text:__("See solutions","jetpack-my-jetpack"),onClick:m,disabled:!h}),React.createElement(n.A,{variant:"link",className:u.A["form-link-action"],text:__("Skip onboarding","jetpack-my-jetpack"),onClick:e})))),React.createElement(r.A,{sm:6,md:8,lg:6,className:(0,i.A)(u.A["banner-image-evaluation"],{[u.A["is-selected"]]:h})}))}},75157:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(28509),o=a(47425),n=a(56427),l=a(27723),s=a(13022),i=a(30369),c=a(52290);const __=l.__,u=()=>React.createElement(n.SVG,{className:c.A.logo,viewBox:"0 0 88 88",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement(n.Path,{className:c.A["circle-outline"],d:"M44 86C67.196 86 86 67.196 86 44C86 20.804 67.196 2 44 2C20.804 2 2 20.804 2 44C2 67.196 20.804 86 44 86Z",stroke:"#003010",strokeWidth:"1"}),React.createElement(n.Path,{className:c.A["triangles-outline"],d:"M41.7319 8.73633V51.3088H19.8159L41.7319 8.73633ZM46.1835 79.2694V36.6129H68.1835L46.1835 79.2694Z",stroke:"#003010",strokeWidth:"1"}),React.createElement(n.Path,{className:c.A["circle-fill"],d:"M44 88C68.3005 88 88 68.3005 88 44C88 19.6995 68.3005 0 44 0C19.6995 0 0 19.6995 0 44C0 68.3005 19.6995 88 44 88Z",fill:"#003010"}),React.createElement(n.Path,{className:c.A["triangles-fill"],fillRule:"evenodd",clipRule:"evenodd",d:"M41.7319 8.73633V51.3088H19.8159L41.7319 8.73633ZM46.1835 79.2694V36.6129H68.1835L46.1835 79.2694Z",fill:"#48FF50"})),d=({type:e,isReady:t})=>{if("connecting"===e){const e=__("Connecting Jetpack","jetpack-my-jetpack"),a=__("Getting things ready in the background — almost there!","jetpack-my-jetpack"),n=(0,l.sprintf)(/* translators: %s: is an emoji */ -__("Jetpack is connected %s","jetpack-my-jetpack"),"🎉"),i=__("You’re connected and ready to fly!","jetpack-my-jetpack");return React.createElement(r.A,{className:c.A["loading-banner"]},React.createElement("div",{className:(0,s.A)(c.A["loader-container"],{[c.A["connection-ready"]]:t})},React.createElement(u,null)),React.createElement(o.Ay,{variant:"headline-small",mb:1},t?n:e),React.createElement(o.Ay,{variant:"body"},t?i:a))}return"recommendations"===e?React.createElement(r.A,{className:c.A["loading-banner"]},React.createElement("div",{className:(0,s.A)(c.A["loader-container"],c.A.recommendations)},React.createElement(i.A,null),React.createElement(u,null)),React.createElement(o.Ay,{variant:"headline-small",mb:1},__("Crafting your unique journey","jetpack-my-jetpack")),React.createElement(o.Ay,{variant:"body"},__("Hang tight while we personalize recommendations to suit your style.","jetpack-my-jetpack"))):React.createElement(React.Fragment,null)}},30369:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(56427),o=a(52290);const n=()=>React.createElement(r.SVG,{className:o.A["products-icons"],width:"379",height:"157",viewBox:"0 0 379 157",fill:"none",xmlns:"http://www.w3.org/2000/svg"},React.createElement(r.G,{className:o.A.people},React.createElement(r.Rect,{x:"334.012",y:"49.7305",width:"44.4222",height:"44.4222",rx:"22.2111",fill:"#003010"}),React.createElement(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M359.516 70.8799C360.852 70.8799 361.935 69.7967 361.935 68.4604C361.935 67.1242 360.852 66.041 359.516 66.041C358.179 66.041 357.096 67.1242 357.096 68.4604C357.096 69.7967 358.179 70.8799 359.516 70.8799ZM359.516 69.4282C360.05 69.4282 360.483 68.9949 360.483 68.4604C360.483 67.926 360.05 67.4927 359.516 67.4927C358.981 67.4927 358.548 67.926 358.548 68.4604C358.548 68.9949 358.981 69.4282 359.516 69.4282Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M357.338 76.6865V74.7509C357.338 73.2811 356.147 72.0896 354.677 72.0896H350.806C349.336 72.0896 348.144 73.2811 348.144 74.7509V76.6865H349.596V74.7509C349.596 74.0828 350.138 73.5412 350.806 73.5412H354.677C355.345 73.5412 355.886 74.0828 355.886 74.7509V76.6865H357.338Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M364.112 74.7509V76.6865H362.661V74.7509C362.661 74.0828 362.119 73.5412 361.451 73.5412H359.032V72.0896H361.451C362.921 72.0896 364.112 73.2811 364.112 74.7509Z",fill:"#0CED57"}),React.createElement(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M355.161 68.4604C355.161 69.7967 354.077 70.8799 352.741 70.8799C351.405 70.8799 350.322 69.7967 350.322 68.4604C350.322 67.1242 351.405 66.041 352.741 66.041C354.077 66.041 355.161 67.1242 355.161 68.4604ZM353.709 68.4604C353.709 68.9949 353.276 69.4282 352.741 69.4282C352.207 69.4282 351.773 68.9949 351.773 68.4604C351.773 67.926 352.207 67.4927 352.741 67.4927C353.276 67.4927 353.709 67.926 353.709 68.4604Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A.videopress},React.createElement(r.Rect,{x:"280",y:"10",width:"44.4222",height:"44.4222",rx:"22.2111",fill:"#003010"}),React.createElement(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M294.5269 25.5844C295.3517 25.5844 296.0764 26.1303 296.3023 26.9219L298.5352 34.7481C298.5375 34.756 298.5411 34.7632 298.5459 34.7696L301.1912 25.5844H302.6711H306.7619C309.6292 25.5844 311.5512 27.4457 311.5512 30.2635C311.5512 33.1136 309.5788 34.8909 306.6359 34.8909H304.695H302.1939L301.708 36.3915C301.2723 37.7373 300.0165 38.6493 298.599 38.6493C297.1815 38.6493 295.9258 37.7373 295.49 36.3915L292.7704 27.9923C292.3853 26.8029 293.2742 25.5844 294.5269 25.5844ZM303.0979 32.0989H305.9301C307.1589 32.0989 307.8962 31.3945 307.8962 30.2635C307.8962 29.126 307.1589 28.4539 305.9301 28.4539H304.2781L303.0979 32.0989Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A.shield},React.createElement(r.Rect,{x:"14.0122",y:"80.7305",width:"76.212",height:"76.212",rx:"38.106",fill:"#003010"}),React.createElement(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M51.9558 104.023L63.163 109.118V116.712C63.163 123.185 59.0053 129.315 53.1424 131.248C52.372 131.502 51.5396 131.502 50.7692 131.248C44.9063 129.315 40.7485 123.185 40.7485 116.712V109.118L51.9558 104.023ZM43.239 110.721V116.712C43.239 122.212 46.8007 127.317 51.5492 128.883C51.813 128.97 52.0986 128.97 52.3624 128.883C57.1109 127.317 60.6725 122.212 60.6725 116.712V110.721L51.9558 106.759L43.239 110.721Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A.akismet},React.createElement(r.Rect,{x:"69.0122",y:"20.7305",width:"54.212",height:"54.212",rx:"27.106",fill:"#003010"}),React.createElement(r.Path,{d:"M97.9649 38.592L103.765 53.9038C104.265 55.2138 105.034 55.6888 106.348 55.7997C106.396 55.8019 106.443 55.814 106.486 55.8352C106.529 55.8564 106.568 55.8862 106.599 55.9229C106.63 55.9595 106.654 56.0022 106.668 56.0483C106.682 56.0944 106.687 56.143 106.681 56.191C106.683 56.2405 106.675 56.2899 106.658 56.3364C106.641 56.3828 106.615 56.4254 106.581 56.4616C106.547 56.4978 106.507 56.527 106.462 56.5473C106.417 56.5677 106.368 56.5789 106.319 56.5803H99.9659C99.9145 56.5816 99.8634 56.5724 99.8157 56.5533C99.768 56.5342 99.7246 56.5055 99.6882 56.4692C99.6518 56.4328 99.6231 56.3894 99.6039 56.3416C99.5846 56.2937 99.5752 56.2425 99.5762 56.191C99.5724 56.1409 99.579 56.0906 99.5956 56.0433C99.6121 55.9959 99.6382 55.9525 99.6722 55.9158C99.7063 55.8791 99.7475 55.8498 99.7934 55.8298C99.8392 55.8098 99.8887 55.7996 99.9387 55.7997C100.577 55.7997 101.3 55.6323 101.3 54.8517C101.294 54.5262 101.228 54.2047 101.104 53.9038L99.7121 50.1936C99.6559 50.0262 99.6287 49.9698 99.462 49.9698H94.1604C93.3266 49.9698 92.2989 49.9698 91.8258 51.0306L90.5571 53.9038C90.4281 54.1644 90.3523 54.4484 90.3341 54.7389C90.3341 55.7433 91.641 55.7997 92.3279 55.7997C92.3779 55.7996 92.4274 55.8098 92.4732 55.8298C92.5191 55.8498 92.5603 55.8791 92.5944 55.9158C92.6284 55.9525 92.6545 55.9959 92.671 56.0433C92.6876 56.0906 92.6942 56.1409 92.6904 56.191C92.6914 56.2426 92.682 56.2939 92.6626 56.3417C92.6432 56.3896 92.6143 56.433 92.5777 56.4692C92.541 56.5055 92.4974 56.5339 92.4495 56.5527C92.4016 56.5715 92.3503 56.5803 92.2989 56.5785H86.662C86.6107 56.5798 86.5597 56.5706 86.5121 56.5514C86.4645 56.5323 86.4212 56.5037 86.3849 56.4673C86.3487 56.4308 86.3201 56.3874 86.3011 56.3396C86.282 56.2918 86.2729 56.2406 86.2741 56.1891C86.2703 56.1391 86.2769 56.0888 86.2935 56.0415C86.31 55.9941 86.3361 55.9507 86.3702 55.914C86.4042 55.8772 86.4454 55.848 86.4913 55.828C86.5371 55.808 86.5866 55.7978 86.6366 55.7979C87.9978 55.7142 88.4491 55.0701 88.9693 53.9019L95.6648 39.1761C95.9711 38.5338 96.6381 37.977 97.2489 37.977C97.6875 37.9788 97.8271 38.2299 97.9649 38.592ZM92.8898 48.576C92.8562 48.6257 92.8368 48.6835 92.8336 48.7434C92.8336 48.7998 92.8898 48.8271 93.0004 48.8271H98.5014C98.8892 48.8271 99.056 48.7434 99.056 48.4923C99.0555 48.3663 99.027 48.242 98.9726 48.1284L97.4447 43.9998C97.0822 43.0518 96.5565 41.7981 96.3898 40.7646C96.3898 40.71 96.3608 40.6809 96.3336 40.6809C96.3064 40.6809 96.2792 40.71 96.2792 40.7646C96.0706 41.4752 95.8007 42.1662 95.4726 42.8298L92.8898 48.576Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M97.9649 38.592L103.765 53.9038C104.265 55.2138 105.034 55.6888 106.348 55.7997C106.396 55.8019 106.443 55.814 106.486 55.8352C106.529 55.8564 106.568 55.8862 106.599 55.9229C106.63 55.9595 106.654 56.0022 106.668 56.0483C106.682 56.0944 106.687 56.143 106.681 56.191C106.683 56.2405 106.675 56.2899 106.658 56.3364C106.641 56.3828 106.615 56.4254 106.581 56.4616C106.547 56.4978 106.507 56.527 106.462 56.5473C106.417 56.5677 106.368 56.5789 106.319 56.5803H99.9659C99.9145 56.5816 99.8634 56.5724 99.8157 56.5533C99.768 56.5342 99.7246 56.5055 99.6882 56.4692C99.6518 56.4328 99.6231 56.3894 99.6039 56.3416C99.5846 56.2938 99.5752 56.2425 99.5762 56.191C99.5724 56.1409 99.579 56.0906 99.5956 56.0433C99.6121 55.9959 99.6382 55.9525 99.6722 55.9158C99.7063 55.8791 99.7475 55.8498 99.7934 55.8298C99.8392 55.8098 99.8887 55.7996 99.9387 55.7997C100.577 55.7997 101.3 55.6323 101.3 54.8517C101.294 54.5262 101.228 54.2047 101.104 53.9038L99.7121 50.1936C99.6559 50.0262 99.6287 49.9698 99.462 49.9698H94.1604C93.3266 49.9698 92.2989 49.9698 91.8258 51.0306L90.5571 53.9038C90.4281 54.1644 90.3523 54.4484 90.3341 54.7389C90.3341 55.7433 91.641 55.7997 92.3279 55.7997C92.3779 55.7996 92.4274 55.8098 92.4732 55.8298C92.5191 55.8498 92.5603 55.8791 92.5944 55.9158C92.6284 55.9525 92.6545 55.9959 92.671 56.0433C92.6876 56.0906 92.6942 56.1409 92.6904 56.191C92.6914 56.2426 92.682 56.2939 92.6626 56.3417C92.6432 56.3896 92.6143 56.433 92.5777 56.4692C92.541 56.5055 92.4974 56.5339 92.4495 56.5527C92.4016 56.5715 92.3503 56.5803 92.2989 56.5785H86.662C86.6107 56.5798 86.5597 56.5706 86.5121 56.5514C86.4645 56.5323 86.4212 56.5037 86.3849 56.4673C86.3487 56.4308 86.3201 56.3874 86.3011 56.3396C86.282 56.2918 86.2729 56.2406 86.2741 56.1891C86.2703 56.1391 86.2769 56.0888 86.2935 56.0415C86.31 55.9941 86.3361 55.9507 86.3702 55.914C86.4042 55.8772 86.4454 55.848 86.4913 55.828C86.5371 55.808 86.5866 55.7978 86.6366 55.7979C87.9978 55.7142 88.4491 55.0701 88.9693 53.9019L95.6648 39.1761C95.9711 38.5338 96.6381 37.977 97.2489 37.977C97.6875 37.9788 97.8271 38.2299 97.9649 38.592ZM92.8898 48.576C92.8562 48.6257 92.8368 48.6835 92.8336 48.7434C92.8336 48.7998 92.8898 48.8271 93.0004 48.8271H98.5014C98.8892 48.8271 99.056 48.7434 99.056 48.4923C99.0555 48.3663 99.027 48.242 98.9726 48.1284L97.4447 43.9998C97.0822 43.0518 96.5565 41.7981 96.3898 40.7646C96.3898 40.71 96.3608 40.6809 96.3336 40.6809C96.3064 40.6809 96.2792 40.71 96.2792 40.7646C96.0706 41.4752 95.8007 42.1662 95.4726 42.8298L92.8898 48.576Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M108.413 47.9182C108.413 48.6351 108.008 49.0409 107.278 49.0409C106.547 49.0409 106.257 48.6679 106.257 48.0983C106.257 47.3814 106.68 46.9756 107.392 46.9756C108.104 46.9756 108.413 47.365 108.413 47.9182Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M86.6465 47.9408C86.6465 48.6559 86.2405 49.0635 85.5119 49.0635C84.7832 49.0635 84.4878 48.6887 84.4878 48.1191C84.4878 47.404 84.9101 46.9965 85.6224 46.9965C86.3348 46.9965 86.6465 47.3877 86.6465 47.9408Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A.stars},React.createElement(r.Rect,{x:"168.012",y:"0.730469",width:"76.212",height:"76.212",rx:"38.106",fill:"#003010"}),React.createElement(r.Path,{d:"M197.184 24.5478L198.7 28.3908L202.543 29.9064L198.7 31.4221L197.184 35.2651L195.668 31.4221L191.825 29.9064L195.668 28.3908L197.184 24.5478Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M213.26 24.5477L215.281 29.6717L220.405 31.6925L215.281 33.7134L213.26 38.8374L211.239 33.7134L206.115 31.6925L211.239 29.6717L213.26 24.5477Z",fill:"#0CED57"}),React.createElement(r.Path,{d:"M204.329 35.2649L206.855 41.6699L213.26 44.196L206.855 46.7221L204.329 53.1271L201.803 46.7221L195.398 44.196L201.803 41.6699L204.329 35.2649Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A.search},React.createElement(r.Rect,{x:"250.012",y:"76.7305",width:"56.212",height:"56.212",rx:"28.106",fill:"#003010"}),React.createElement(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M287.184 103.116C287.184 107.306 283.788 110.702 279.599 110.702C277.846 110.702 276.232 110.107 274.948 109.109L270.156 113.9L268.815 112.56L273.607 107.768C272.608 106.483 272.014 104.869 272.014 103.116C272.014 98.9272 275.41 95.5312 279.599 95.5312C283.788 95.5312 287.184 98.9272 287.184 103.116ZM285.288 103.116C285.288 106.258 282.741 108.805 279.599 108.805C276.457 108.805 273.91 106.258 273.91 103.116C273.91 99.9745 276.457 97.4275 279.599 97.4275C282.741 97.4275 285.288 99.9745 285.288 103.116Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A.social},React.createElement(r.Rect,{x:"0.012207",y:"21.7305",width:"44.4222",height:"44.4222",rx:"22.2111",fill:"#003010"}),React.createElement(r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M25.3608 37.4654V48.3956L18.9181 46.5084V49.9341H17.7104L17.7104 46.1546L15.518 45.5124C14.6693 45.2638 14.0889 44.5075 14.0889 43.6503V42.2107C14.0889 41.3535 14.6693 40.5972 15.518 40.3486L25.3608 37.4654ZM24.1531 46.822L18.9181 45.2885L18.9181 40.5725L24.1531 39.039V46.822ZM17.7104 40.9263L17.7104 44.9347L15.8682 44.3951C15.5287 44.2957 15.2966 43.9932 15.2966 43.6503V42.2107C15.2966 41.8678 15.5287 41.5653 15.8682 41.4659L17.7104 40.9263ZM26.9733 43.5155H30.1939V42.3481H26.9733V43.5155ZM30.1939 46.8212L26.9733 46.0429V44.8754L30.1939 45.6537V46.8212ZM26.9733 40.9856L30.1939 40.2073V39.0398L26.9733 39.8181V40.9856Z",fill:"#0CED57"})),React.createElement(r.G,{className:o.A["empty-circle"]},React.createElement(r.Rect,{x:"110",y:"-30.2695",width:"44.4222",height:"44.4222",rx:"22.2111",fill:"#003010"})))},36007:(e,t,a)=>{"use strict";a.d(t,{A:()=>y});var r=a(75918),o=a(28509),n=a(51112),l=a(27723),s=a(10991),i=a(13022),c=a(51609),u=a(83804),d=a(89812),v=a(64526),p=a(31368),m=a(51870),h=a(62450),f=a(7881),g=a(36259),w=a(75157),b=a(52290);const __=l.__,y=({welcomeFlowExperiment:e,setWelcomeFlowExperiment:t,children:a})=>{const{recordEvent:l}=(0,v.A)(),{dismissWelcomeBanner:y}=(0,d.A)(),{recommendedModules:x,submitEvaluation:_,saveEvaluationResult:k}=(0,u.A)(),{siteIsRegistered:E,siteIsRegistering:C,isUserConnected:j,isSiteConnected:A}=(0,m.A)({skipUserConnection:!0}),[S,P]=(0,c.useState)(!1),[R,M]=(0,c.useState)(""),[V,z]=(0,c.useState)(null),H=(0,p.A)();(0,c.useEffect)((()=>{if("site-connecting"===R&&!C&&E){z(!0);const e=setTimeout((()=>z(!1)),3e3);return()=>clearTimeout(e)}}),[S,R,x,E,C]);const L=(0,c.useMemo)((()=>C||V||E&&"site-connecting"===R&&null===V?"site-connecting":!E||e.isLoading?"connection":S?"evaluation-processing":x||H?"evaluation":null),[E,V,C,R,e.isLoading,S,x,H]);(0,c.useEffect)((()=>{R!==L&&(l("jetpack_myjetpack_welcome_banner_step_view",{current_step:L}),M(L))}),[L,R,l]);const O=(0,c.useCallback)((()=>{l("jetpack_myjetpack_welcome_banner_dismiss_click",{current_step:L,is_user_connected:j,is_site_connected:A}),y()}),[l,L,j,A,y]),N=(0,c.useCallback)((()=>{l("jetpack_myjetpack_welcome_banner_skip_recommendations_click"),y()}),[y,l]),I=(0,c.useCallback)((async e=>{const t=Object.keys(e).filter((t=>e[t]));P(!0),l("jetpack_myjetpack_welcome_banner_evaluation_submit",{goals:t});try{const e=await _(t);await k(e),y()}catch{P(!1)}}),[y,l,k,_]);return(0,c.useEffect)((()=>{L||y()}),[L,y]),L?React.createElement(r.A,{horizontalSpacing:6,horizontalGap:2},a&&React.createElement(o.A,null,a),React.createElement(o.A,{lg:12,className:b.A.banner},React.createElement(h.O,{className:(0,i.A)(b.A["banner-card"],"connection"===L&&b.A["is-mandatory"])},React.createElement(r.A,{horizontalSpacing:0,horizontalGap:0,className:b.A["banner-content"]},"connection"===L&&React.createElement(f.A,{onUpdateWelcomeFlowExperiment:t,isActivating:C||e.isLoading}),"evaluation"===L&&React.createElement(g.A,{onSkipOnboarding:N,onSubmitEvaluation:I}),"evaluation-processing"===L&&React.createElement(w.A,{type:"recommendations"}),"site-connecting"===L&&React.createElement(w.A,{type:"connecting",isReady:A}))),React.createElement(n.A,{className:b.A.dismiss,variant:"secondary","aria-label":__("Don’t show the welcome message again","jetpack-my-jetpack"),size:"small",icon:s.A,disabled:C,onClick:O}))):null}},38837:(e,t,a)=>{"use strict";a.d(t,{ED:()=>o,NM:()=>l,OM:()=>r,hp:()=>s,mk:()=>n});const r="my-jetpack-my-plans-manage",o="my-jetpack-my-plans-purchase",n="my-jetpack-my-plans-purchase-no-site",l={Home:"/",Connection:"/connection",ConnectionSkipPricing:"/connection?skip_pricing=true",AddAkismet:"/add-akismet",AddAntiSpam:"/add-anti-spam",AddBackup:"/add-backup",AddBoost:"/add-boost",AddComplete:"/add-complete",AddCRM:"/add-crm",AddJetpackAI:"/add-jetpack-ai",AddExtras:"/add-extras",AddGrowth:"/add-growth",AddProtect:"/add-protect/:feature?",AddScan:"/add-scan",AddSocial:"/add-social",AddSearch:"/add-search",AddSecurity:"/add-security",AddVideoPress:"/add-videopress",AddStats:"/add-stats",AddLicense:"/add-license",JetpackAi:"/jetpack-ai",Onboarding:"/onboarding",RedeemToken:"/redeem-token"},s={ACTIVE:"active",INACTIVE:"inactive",MODULE_DISABLED:"module_disabled",SITE_CONNECTION_ERROR:"site_connection_error",ABSENT:"plugin_absent",ABSENT_WITH_PLAN:"plugin_absent_with_plan",NEEDS_PLAN:"needs_plan",NEEDS_ACTIVATION:"needs_activation",NEEDS_FIRST_SITE_CONNECTION:"needs_first_site_connection",USER_CONNECTION_ERROR:"user_connection_error",CAN_UPGRADE:"can_upgrade",EXPIRING_SOON:"expiring",EXPIRED:"expired",NEEDS_ATTENTION__ERROR:"needs_attention_error",NEEDS_ATTENTION__WARNING:"needs_attention_warning"}},73537:(e,t,a)=>{"use strict";a.d(t,{EX:()=>o,PG:()=>r,pv:()=>n});const r=100,o=200,n=300},76007:(e,t,a)=>{"use strict";a.d(t,{A:()=>l,g:()=>n});var r=a(51609);const o={message:"",title:null,options:{level:"info",priority:0}},n=(0,r.createContext)({currentNotice:o,setNotice:null,resetNotice:null}),l=({children:e})=>{const[t,a]=(0,r.useState)(o),l=(0,r.useCallback)((()=>{a(o)}),[]),s=(0,r.useCallback)(((e,r)=>{if(!t.message||e.options.priority>t.options.priority){const t={...e.options,onClose:e.options?.onClose||(e.options?.hideCloseButton?void 0:r)};l(),a({...e,options:t})}}),[t.message,t.options.priority,l]);return React.createElement(n.Provider,{value:{currentNotice:t,setNotice:s,resetNotice:l}},e)}},41521:(e,t,a)=>{"use strict";a.d(t,{l:()=>n});var r=a(27723),o=a(73537);const n={message:(0,r.__)("Site connection failed. Please try again.","jetpack-my-jetpack"),options:{id:"site-connection-error-notice",level:"error",actions:[],priority:o.pv,hideCloseButton:!1}}},56077:(e,t,a)=>{"use strict";a.d(t,{A:()=>l,_:()=>n});var r=a(51609);const o=(0,r.createContext)({state:{},setState:()=>{}}),n=(e,t)=>{const{state:a,setState:n}=(0,r.useContext)(o),{[e]:l=t}=a;(0,r.useEffect)((()=>{void 0===a[e]&&n((a=>({...a,[e]:t})))}),[t,e,n,a]);return[l,(0,r.useCallback)((t=>{n((a=>({...a,[e]:t})))}),[e,n])]},l=({children:e})=>{const[t,a]=(0,r.useState)({});return React.createElement(o.Provider,{value:{state:t,setState:a}},e)}},31504:(e,t,a)=>{"use strict";a.d(t,{AD:()=>u,Ck:()=>P,DB:()=>n,D_:()=>I,Dz:()=>j,E4:()=>z,FW:()=>x,Hm:()=>p,IM:()=>w,L6:()=>d,MB:()=>A,MD:()=>M,MX:()=>L,Md:()=>k,O2:()=>s,PM:()=>g,QO:()=>S,Re:()=>O,Rx:()=>y,Yr:()=>N,_:()=>E,dB:()=>R,dL:()=>h,es:()=>f,g_:()=>c,jE:()=>_,jf:()=>i,jr:()=>m,no:()=>v,nw:()=>C,pN:()=>V,rR:()=>l,tb:()=>o,uh:()=>H,xF:()=>b});const r="my-jetpack/v1",o=`${r}/site/purchases`,n=`${r}/site/backup/undo-event`,l=`${r}/chat/availability`,s=`${r}/chat/authentication`,i=`${r}/site/products`,c=`${r}/site/products-ownership`,u=`${r}/site/dismiss-welcome-banner`,d=`${r}/site/recommendations/evaluation`,v=`${r}/site/recommendations/evaluation/result`,p=`${r}/site/update-historically-active-modules`,m=`${r}/jetpack-manage/data`,h=`${r}/red-bubble-notifications`,f=`${r}/site/protect/data`,g=`${r}/site/videopress/data`,w=e=>`jetpack/v4/stats-app/sites/${e}/stats/highlights`,b="product",y="product ownership",x="activate product",_="install product",k="available licenses",E="chat availability",C="chat authentication",j="backup history",A="stats counts",S="dismiss welcome banner",P="purchases",R="evaluate site recommendations",M="save site evaluation result",V="remove site evaluation result",z="update historically active modules",H="get jetpack manage data",L="red bubble alerts",O="get protect data",N="get videopress data",I={ANTI_SPAM:"anti-spam",BACKUP:"backup",BOOST:"boost",BRUTE_FORCE:"brute-force",CRM:"crm",CREATOR:"creator",EXTRAS:"extras",JETPACK_AI:"jetpack-ai",NEWSLETTER:"newsletter",PROTECT:"protect",RELATED_POSTS:"related-posts",SCAN:"scan",SEARCH:"search",SITE_ACCELERATOR:"site-accelerator",SOCIAL:"social",STATS:"stats",VIDEOPRESS:"videopress",SECURITY:"security",GROWTH:"growth",COMPLETE:"complete"}},83804:(e,t,a)=>{"use strict";a.d(t,{A:()=>p});var r=a(27723),o=a(51609),n=a(56077),l=a(64526),s=a(31368),i=a(31504),c=a(65350),u=a(10929),d=a(68242),v=a(89812);const __=r.__,p=()=>{const{recordEvent:e}=(0,l.A)(),{isWelcomeBannerVisible:t,showWelcomeBanner:a}=(0,v.A)(),[r,p]=(0,n._)("recommendedModules",(0,d.A$)("recommendedModules").modules),[m,h]=(0,n._)("isFirstRun",(0,d.A$)("recommendedModules").isFirstRun),{data:{ownedProducts:f},isLoading:g}=(0,c.A)(),w=(0,s.A)(),b=(0,o.useMemo)((()=>{const e=f||[];return r?.filter((t=>!e.includes(t))).slice(0,5)}),[r,f]),y=(0,o.useMemo)((()=>{const{dismissed:e}=(0,d.A$)("recommendedModules");return!e&&!t&&w}),[t,w]),[x,_]=(0,n._)("recommendedModulesVisible",y&&!!b?.length),{mutate:k}=(0,u.A)({name:i.dB,query:{path:i.L6,method:"GET"},errorMessage:__("Failed to evaluate site recommendations","jetpack-my-jetpack")}),{mutate:E}=(0,u.A)({name:i.MD,query:{path:i.no,method:"POST"},errorMessage:__("Failed to save evaluation results. Please try again","jetpack-my-jetpack")}),{mutate:C}=(0,u.A)({name:i.pN,query:{path:i.no,method:"DELETE"},errorMessage:__("Failed to hide evaluation results. Please try again","jetpack-my-jetpack")});return{submitEvaluation:(0,o.useCallback)((e=>new Promise(((t,a)=>{k({queryParams:{goals:e}},{onSuccess:t,onError:a})}))),[k]),saveEvaluationResult:(0,o.useCallback)((e=>new Promise(((t,a)=>{E({data:{recommendations:e}},{onSuccess:e=>{p(e),_(!0),t()},onError:a})}))),[E,_,p]),removeEvaluationResult:(0,o.useCallback)((()=>{_(!1),C({},{onSuccess:()=>{h(!1),e("jetpack_myjetpack_evaluation_recommendations_dismiss_click")}})}),[C,e,h,_]),redoEvaluation:(0,o.useCallback)((()=>{_(!1),h(!1),a(),e("jetpack_myjetpack_evaluation_recommendations_redo_click")}),[e,h,_,a]),recommendedModules:b,isSectionVisible:x,isFirstRun:m,isProductOwnershipLoading:g}}},72447:(e,t,a)=>{"use strict";a.d(t,{M:()=>c});var r=a(27723),o=a(51609),n=a(73537),l=a(76007),s=a(31504);const __=r.__,i=[s.Ck,s.FW,s.jE,s.Re,s.Yr],c=({infoName:e,isError:t,overrideMessage:a})=>{const{setNotice:s}=(0,o.useContext)(l.g),c=a??(0,r.sprintf)( -// translators: %s is the name of the information being fetched, e.g. "site purchases". -__("There was an error fetching your %s information. Check your site connectivity and try again.","jetpack-my-jetpack"),e);(0,o.useEffect)((()=>{t&&i.includes(e)&&s({message:c,options:{id:"fetching-error-notice",level:"error",priority:n.PG}})}),[c,s,t,e])}},41526:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(63406),o=a(27723),n=a(64526),l=a(31504),s=a(10929),i=a(68242),c=a(4682);const __=o.__,u=e=>{const t=Array.isArray(e)?e:[e],{products:a,refetch:u}=(0,c.A)(t),{recordEvent:d}=(0,n.A)(),{createSuccessNotice:v}=(0,r.I)(),{mutate:p,isPending:m,isSuccess:h}=(0,s.A)({name:l.FW,query:{path:`${l.jf}/activate`,method:"POST",data:{products:t}},options:{onSuccess:()=>{a?.forEach((e=>{(e=>{const{standalonePluginInfo:t,isPluginActive:a}=e;return t?.hasStandalonePlugin?t?.isStandaloneActive:a})(e)||(d("jetpack_myjetpack_product_activated",{product:e.slug}),(e=>{const{items:t}=(0,i.A$)("products");"jetpack"!==t[e]?.plugin_slug&&t[e]?.standalone_plugin_info.has_standalone_plugin&&(window.myJetpackInitialState.products.items[e].standalone_plugin_info.is_standalone_active=!0,window.myJetpackInitialState.products.items[e].standalone_plugin_info.is_standalone_installed=!0)})(e.slug))})),u().then((()=>{v((0,o.sprintf)(/* translators: %s is either the product name, i.e.- "Jetpack Backup" or the word "Plugins". */ -__("%s activated successfully!","jetpack-my-jetpack"),1===a?.length?a[0].title:__("Plugins","jetpack-my-jetpack")))}))}},errorMessage:(0,o.sprintf)( -// translators: %s is the Jetpack product name or comma seperated list of multiple Jetpack product names. -__("There was a problem activating %s.","jetpack-my-jetpack"),a?.map((e=>e?.name)).join(", "))});return{activate:p,isPending:m,isSuccess:h}}},488:(e,t,a)=>{"use strict";a.d(t,{V:()=>s});var r=a(31504),o=a(280),n=a(68242),l=a(87451);const s=()=>{const{items:e}=(0,n.A$)("products"),{data:t,isLoading:a,isError:s}=(0,o.A)({name:`${r.xF}`,query:{path:`${r.jf}`},options:{enabled:!0}});if(!a&&!s)for(const[a,r]of Object.entries(e))t&&t[a]&&(e[a]={...r,...t[a]});return e?{data:Object.entries(e).reduce(((e,[t,a])=>({...e,[t]:(0,l.l)(a)})),{}),isLoading:a,isError:s}:{data:{},isLoading:!1,isError:!1}}},55394:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(63406),o=a(27723),n=a(31504),l=a(10929),s=a(4682);const __=o.__,i=e=>{const t=Array.isArray(e)?e:[e],{products:a,refetch:i}=(0,s.A)(t),{createSuccessNotice:c}=(0,r.I)(),u=(0,o.sprintf)(/* translators: %s is the name of a Jetpack plugin, i.e.- "VaultPress Backup" or "Boost" or "Social" or "Search" or "VideoPress", etc. */ -__("%s installed successfully!","jetpack-my-jetpack"),a[0]?.title),d=__("Plugins installed successfully!","jetpack-my-jetpack"),v=1===a?.length?u:d,{mutate:p,isPending:m}=(0,l.A)({name:n.jE,query:{path:`${n.jf}/install`,method:"POST",data:{products:t}},options:{onSuccess:()=>{i().then((()=>{c(v)}))}},errorMessage:(0,o.sprintf)( -// translators: %s is the Jetpack plugin name or comma seperated list of multiple Jetpack plugin names. -__("There was a problem installing and activating %s.","jetpack-my-jetpack"),a?.map((e=>e?.name)).join(", "))});return{install:p,isPending:m}}},74923:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(4682);const o=e=>{const{products:t,refetch:a,isLoading:o}=(0,r.A)([e]);return{detail:t[0],refetch:a,isLoading:o}}},65350:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(51609),o=a(56077),n=a(31504),l=a(280);const s=()=>{const[e,t]=(0,o._)("productsOwnership",{ownedProducts:[],unownedProducts:[]}),{data:a,refetch:s,isLoading:i}=(0,l.A)({name:`${n.Rx}`,query:{path:n.g_}});return(0,r.useEffect)((()=>{if(!i&&a){const{ownedProducts:e=[],unownedProducts:r=[]}=a;t({ownedProducts:e,unownedProducts:r})}}),[a,i,t]),{refetch:s,data:e,isLoading:i}}},4682:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(51609),o=a(31504),n=a(280),l=a(488);const s=e=>{const t=Array.isArray(e)?e:[e],{data:a,isLoading:s}=(0,l.V)(),i=t?.map((e=>a?.[e])),{refetch:c,isLoading:u}=(e=>{const t=e&&e?.length?`?products=${e?.join(",")}`:"";return(0,n.A)({name:`${o.xF}`,query:{path:`${o.jf}${t}`},options:{enabled:!1}})})(t);return{products:i,refetch:(0,r.useCallback)((()=>(async e=>{const{data:t,isError:a,isLoading:r}=await e(),o=window.myJetpackInitialState.products.items;a||r||Object.keys(t).forEach((e=>{window.myJetpackInitialState.products.items[e]={...o[e],...t[e]}}))})(c)),[c]),isLoading:u||s}}},58402:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(10929);const n=()=>{const{mutate:e}=(0,o.A)({name:r.E4,query:{path:r.Hm,method:"POST"},options:{onSuccess:e=>{e.length>0&&(window.myJetpackInitialState.lifecycleStats.historicallyActiveModules=e)}}});return e}},40357:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(5932),o=a(35104),n=a(72447),l=a(68242);const s=({name:e,queryFn:t,errorMessage:a})=>{const s=(0,o.I)({queryKey:[e],queryFn:()=>{const{apiRoot:e,apiNonce:a}=(0,l.qG)();return r.Ay.setApiRoot(e),r.Ay.setApiNonce(a),t(r.Ay)},refetchOnWindowFocus:!1,refetchIntervalInBackground:!1}),{isError:i,isLoading:c}=s;return(0,n.M)({infoName:e,isError:!c&&i,overrideMessage:a}),s}},62902:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(31504),o=a(280);const n=()=>{const e=document.cookie.split(";").map((e=>e.trim())).filter((e=>e.includes("_dismissed"))),{data:t={},isLoading:a,isError:n,refetch:l}=(0,o.A)({name:r.MX,query:{path:r.dL,method:"POST",data:{dismissal_cookies:e}}});return{data:t,isLoading:a,isError:n,refetch:l}}},10929:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(34613),o=a(1455),n=a.n(o),l=a(93832),s=a(72447);const i=({name:e,query:t,options:a,errorMessage:o})=>{const i=(0,r.n)({mutationKey:[e],mutationFn:e=>{const a=Object.assign({},t);return e&&"queryParams"in e&&(a.path=(0,l.addQueryArgs)(a.path,e.queryParams),delete e.queryParams),n()({...a,...e})},...a}),{isError:c,isPending:u}=i;return(0,s.M)({infoName:e,isError:!u&&c,overrideMessage:o}),i}},280:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(35104),o=a(1455),n=a.n(o),l=a(72447);const s=({name:e,query:t,options:a,errorMessage:o})=>{const s=(0,r.I)({queryKey:[e],queryFn:()=>n()(t),refetchOnWindowFocus:!1,refetchIntervalInBackground:!1,...a}),{error:i,isError:c,isLoading:u}=s;return(0,l.M)({infoName:e,isError:!u&&c&&"not_connected"!==i.code,overrideMessage:o}),s}},68242:(e,t,a)=>{"use strict";a.d(t,{A$:()=>r,SF:()=>n,qG:()=>o});const r=e=>e?window?.myJetpackInitialState?.[e]??{}:window?.myJetpackInitialState,o=()=>window?.myJetpackRest??{},n=e=>e?window?.JP_CONNECTION_INITIAL_STATE?.[e]??{}:window?.JP_CONNECTION_INITIAL_STATE},18117:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(38837);const o=e=>Object.values(e).filter((({requiresUserConnection:e,status:t})=>e&&(t===r.hp.ACTIVE||r.hp.USER_CONNECTION_ERROR))).map((({name:e})=>e))},16700:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=(e,t)=>{"Enter"!==e.key&&" "!==e.key||t()}},87451:(e,t,a)=>{"use strict";a.d(t,{l:()=>o});var r=a(68405);const o=e=>{const t=(0,r.A)(e);return t.features=t.features||[],t.supportedProducts=t.supportedProducts||[],t.pricingForUi&&(t.pricingForUi.fullPricePerMonth=(e=>"year"===e.pricingForUi.productTerm?Math.round(e.pricingForUi.fullPrice/12*100)/100:e.pricingForUi.fullPrice)(t),t.pricingForUi.discountPricePerMonth=(e=>"year"===e.pricingForUi.productTerm?Math.round(e.pricingForUi.discountPrice/12*100)/100:e.pricingForUi.discountPrice)(t)),t}},13244:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(5932),o=a(27723),n=a(68242);const __=o.__,l=async()=>{const{apiRoot:e,apiNonce:t}=(0,n.qG)();if(r.Ay.setApiRoot(e),r.Ay.setApiNonce(t),window.confirm(__("This will reset all Jetpack options, are you sure?","jetpack-my-jetpack")))try{"success"===(await r.Ay.resetOptions("options")).code&&window.alert(__("Options reset! Have fun messing them up again :-)","jetpack-my-jetpack"))}catch{window.alert(__("Options failed to reset.","jetpack-my-jetpack"))}}},68405:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});const r=e=>Array.isArray(e)?e.map((e=>r(e))):"object"==typeof e&&null!==e?Object.fromEntries(Object.entries(e).map((([e,t])=>[e.replace(/([-_][a-z])/gi,(e=>e.toUpperCase().replace(/[-_]/g,""))),r(t)]))):e,o=r},89812:(e,t,a)=>{"use strict";a.d(t,{A:()=>c});var r=a(27723),o=a(51609),n=a(56077),l=a(31504),s=a(62902),i=a(10929);const __=r.__,c=()=>{const{data:e,isLoading:t,isError:a,refetch:r}=(0,s.A)(),c=(0,o.useMemo)((()=>a||t?[]:Object.keys(e)),[a,t,e]),[u,d]=(0,n._)("isDismissingWelcomeBanner",!1),[v,p]=(0,n._)("isWelcomeBannerVisible",c.includes("welcome-banner-active"));(0,o.useEffect)((()=>{u?p(!1):c.includes("welcome-banner-active")&&p(!0)}),[u,c,p]);const{mutate:m}=(0,i.A)({name:l.QO,query:{path:l.AD,method:"POST"},errorMessage:__("Failed to dismiss the welcome banner. Please try again","jetpack-my-jetpack")});return{dismissWelcomeBanner:(0,o.useCallback)((()=>{d(!0),m(null,{onSuccess:async()=>{await r(),d(!1)}})}),[m,r,d]),showWelcomeBanner:(0,o.useCallback)((()=>{d(!1),p(!0)}),[p,d]),isWelcomeBannerVisible:v}}},64526:(e,t,a)=>{"use strict";a.d(t,{A:()=>s});var r=a(90372),o=a(51609),n=a(68242),l=a(51870);const s=()=>{const{isUserConnected:e,isSiteConnected:t,connectedPlugins:a,userConnectionData:s={}}=(0,l.A)(),{login:i,ID:c}=s.currentUser?.wpcomUser||{},{myJetpackVersion:u=""}=(0,n.A$)();(0,o.useEffect)((()=>{e&&c&&i&&r.A.initialize(c,i)}),[c,e,i]);const d=Object.keys(a||{}).sort().join(",").replaceAll("jetpack-","");return{recordEvent:(0,o.useCallback)(((a,o)=>{r.A.tracks.recordEvent(a,{...o,version:u,is_site_connected:t,is_user_connected:e,referring_plugins:d})}),[])}}},36312:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(3924),o=a(51609),n=a(76007),l=a(41521),s=a(65350),i=a(68242),c=a(51870),u=a(64526);const d=({tracksInfo:e})=>{const{event:t,properties:a}=e,{setNotice:d,resetNotice:v}=(0,o.useContext)(n.g),{recordEvent:p}=(0,u.A)(),{refetch:m}=(0,s.A)(),{siteSuffix:h,adminUrl:f,myJetpackCheckoutUri:g}=(0,i.A$)(),w=`&redirect_to=${g}`,b=`${`?connect_after_checkout=true&admin_url=${encodeURIComponent(f)}&from_site_slug=${h}&source=my-jetpack`}${w}&unlinked=1`,y=(0,r.A)("jetpack-my-jetpack-site-only-plans",{query:b}),{handleRegisterSite:x}=(0,c.A)({skipUserConnection:!0,redirectUri:w});return{connectSite:(0,o.useCallback)((async e=>{e&&e.preventDefault(),setTimeout((()=>{window.scrollTo({top:0,left:0,behavior:"smooth"})}),100),p(`${t}_click`,a);try{await x(),p(`${t}_success`,a),window.location.href=y}catch{d(l.l,v)}finally{m()}}),[x,y,p,m,v,d,a,t])}}},65049:(e,t,a)=>{"use strict";a.d(t,{x:()=>o});var r=a(51609);const o=()=>{(0,r.useEffect)((()=>{const e=document.documentElement.classList.contains("wp-toolbar");return document.body.classList.add("jetpack-admin-full-screen"),e&&document.documentElement.classList.remove("wp-toolbar"),()=>{document.body.classList.remove("jetpack-admin-full-screen"),e&&document.documentElement.classList.add("wp-toolbar")}}))}},13588:(e,t,a)=>{"use strict";a.d(t,{L:()=>s});var r=a(51609),o=a(38837),n=a(64526),l=a(33981);function s({slug:e}){const{recordEvent:t}=(0,n.A)(),a=(0,l.A)(o.NM.Home);return{onClickGoBack:(0,r.useCallback)((r=>{e&&t("jetpack_myjetpack_product_interstitial_back_link_click",{product:e}),document.referrer.includes(window.location.host)&&(r.preventDefault(),a())}),[t,e,a])}}},34847:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=(e,t,a)=>{if(!e||a)return"unknown";const{modules:r,jetpackPlugins:o,isSiteConnected:n,isUserConnected:l}=e;return 0===t.length&&r.length<3?l&&n||0!==r.length||1!==o.length?"new":"brand-new":1===t.length&&r.length<10?"settling-in":"established"}},31368:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(31504),o=a(280),n=a(68242),l=a(51870),s=a(34847);const i=()=>{const e=(0,n.A$)("lifecycleStats"),{isSiteConnected:t}=(0,l.A)(),{data:a,isLoading:i,isError:c}=(0,o.A)({name:r.Ck,query:{path:r.tb},options:{enabled:t}}),u=!a||c||i?[]:a;return["unknown","brand-new","new"].includes((0,s.A)(e,u,i))}},51870:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(39384),o=a(68242);const n=({skipUserConnection:e=!1,redirectUri:t=""}={})=>{const{apiRoot:a,apiNonce:n}=(0,o.qG)(),{topJetpackMenuItemUrl:l,blogID:s}=(0,o.A$)(),{registrationNonce:i}=(0,o.SF)(),c=(0,r.useConnection)({apiRoot:a,apiNonce:n,registrationNonce:i,skipUserConnection:e,from:"my-jetpack",redirectUri:t,autoTrigger:!1}),u=c.isRegistered,d=c.isRegistered,v=c.hasConnectedOwner;return{apiNonce:n,apiRoot:a,blogID:s,registrationNonce:i,...c,isSiteConnected:u,siteIsRegistered:d,topJetpackMenuItemUrl:l,hasConnectedOwner:v}}},33981:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(51609),o=a(29539);const n=e=>{const t=(0,o.Zp)();return(0,r.useCallback)((a=>t(e,a)),[t,e])}},25994:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(70028);const o=()=>{const[e]=(0,r.ok)(),t=e.get("returnTo");return t?`admin.php?page=my-jetpack#/${t}`:"admin.php?page=my-jetpack"}},38318:(e,t,a)=>{"use strict";a.d(t,{n:()=>c});var r=a(3924),o=a(56427),n=a(86087),l=a(27723),s=a(51609),i=a(68242);const __=l.__,_n=l._n,c=({alert:e,planName:t,planPurchaseId:a})=>{const{needs_installed:c,needs_activated_only:u}=e||{},d=(c?.length??0)+(u?.length??0),{siteSuffix:v}=(0,i.A$)(),p=(0,s.useMemo)((()=>c&&u?"install_activate":c?"install":"activate"),[u,c]),m={install_activate:__("Plugin installation and activation needed","jetpack-my-jetpack"),install:__("Plugin installation needed","jetpack-my-jetpack"),activate:__("Plugin activation needed","jetpack-my-jetpack")},h={install_activate:__("Some plugins need to be installed and/or activated","jetpack-my-jetpack"),install:__("Some plugins need to be installed","jetpack-my-jetpack"),activate:__("Some plugins need to be activated","jetpack-my-jetpack")},f={install_activate:(0,n.createInterpolateElement)((0,l.sprintf)( -// translators: %1$s is the name of the Jetpack paid plan, i.e.- "Jetpack Security", and %2$s word "plugin" as singular, or plural ("plugins"). -__("To get the most out of your %1$s paid subscription and have access to all it’s features, we recommend you install and/or activate the following %2$s:","jetpack-my-jetpack"),t,_n("plugin","plugins",d,"jetpack-my-jetpack")),{link:React.createElement(o.ExternalLink,{href:(0,r.A)("jetpack-subscription-renew",{site:v,path:a})})}),install:(0,n.createInterpolateElement)((0,l.sprintf)( -// translators: %1$s is the name of the Jetpack paid plan, i.e.- "Jetpack Security", and %2$s word "plugin" as singular, or plural ("plugins"). -__("To get the most out of your %1$s paid subscription and have access to all it’s features, we recommend you install and activate the following %2$s:","jetpack-my-jetpack"),t,_n("plugin","plugins",d,"jetpack-my-jetpack")),{link:React.createElement(o.ExternalLink,{href:(0,r.A)("jetpack-subscription-renew",{site:v,path:a})})}),activate:(0,n.createInterpolateElement)((0,l.sprintf)( -// translators: %1$s is the name of the Jetpack paid plan, i.e.- "Jetpack Security", and %2$s word "plugin" as singular, or plural ("plugins"). -__("To get the most out of your %1$s paid subscription and have access to all it’s features, we recommend you activate the following %2$s:","jetpack-my-jetpack"),t,_n("plugin","plugins",d,"jetpack-my-jetpack")),{link:React.createElement(o.ExternalLink,{href:(0,r.A)("jetpack-subscription-renew",{site:v,path:a})})})},g={install_activate:(0,l.sprintf)(/* translators: %1$s is "plugin" or "plugins" (singular/plural) */ -__("Install and/or activate %1$s in one click","jetpack-my-jetpack"),_n("plugin","plugins",d,"jetpack-my-jetpack")),install:(0,l.sprintf)(/* translators: %1$s is "plugin" or "plugins" (singular/plural) */ -__("Install and activate %1$s in one click","jetpack-my-jetpack"),_n("plugin","plugins",d,"jetpack-my-jetpack")),activate:(0,l.sprintf)(/* translators: %1$s is "plugin" or "plugins" (singular/plural) */ -__("Activate %1$s in one click","jetpack-my-jetpack"),_n("plugin","plugins",d,"jetpack-my-jetpack"))};return{noticeTitle:1===d?m[p]:h[p],noticeMessage:f[p],buttonLabel:g[p]}}},7436:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(62902),o=a(37898),n=a(15048),l=a(68245),s=a(75782),i=a(53866),c=a(247),u=a(52963);const d=()=>{const{isLoading:e,data:t}=(0,r.A)();(0,i.A)(t,e),(0,c.A)(t,e),(0,s.A)(t,e),(0,o.A)(t,e),(0,l.A)(),(0,u.A)(t,e),(0,n.A)(t,e)}},50977:(e,t,a)=>{"use strict";a.d(t,{j:()=>r});const r=({products:e})=>e?React.createElement("ul",{className:"products-list"},e.map(((e,t)=>React.createElement("li",{key:t,className:"product-badge"},e)))):null},37898:(e,t,a)=>{"use strict";a.d(t,{A:()=>f});var r=a(3924),o=a(28509),n=a(47425),l=a(38443),s=a(27723),i=a(51609),c=a(73537),u=a(76007),d=a(88220),v=a(79131),p=a(72434),m=a(64526),h=a(40271);const __=s.__,f=(e,t)=>{const{recordEvent:a}=(0,m.A)(),{setNotice:f,resetNotice:g}=(0,i.useContext)(u.g),{type:w,data:{status:b,last_updated:y}}=e?.backup_failure||{type:"error",data:{}},{reasonContent:x}=(0,h.A)()||{},{text:_}=x||{},{timezone:{offset:k}}=(0,l.getSettings)()||{offset:"0"},E=(0,l.dateI18n)("F jS, Y g:ia",(0,d.w)(y,parseInt(k))),C=(0,r.A)("jetpack-support-troubleshooting-backup"),j=(0,r.A)("jetpack-support"),A=__("Oops! We couldn’t back up your site","jetpack-my-jetpack"),S=(0,i.useCallback)((()=>{(0,v.A)("backup_failure_dismissed",7),delete e?.backup_failure,g()}),[e?.backup_failure,g]),P=(0,i.useCallback)((()=>{window.open(C),a("jetpack_my_jetpack_backup_needs_attention_notice_primary_cta_click",{backup_status:b})}),[a,b,C]),R=(0,i.useCallback)((()=>{window.open(j),a("jetpack_my_jetpack_backup_needs_attention_notice_secondary_cta_click",{backup_status:b})}),[a,b,j]);(0,i.useEffect)((()=>{if(!e?.backup_failure)return;const a=React.createElement(o.A,null,React.createElement(n.Ay,{mb:1},(0,p.A)((0,s.sprintf)( -// Translators: %1$s is the date the last backup took place, i.e.- "Dec 7, 2024" -__("The last backup attempted on %1$s was unsuccessful.","jetpack-my-jetpack"),E))),!t&&_&&React.createElement(n.Ay,{mb:1},(0,p.A)(_)),React.createElement(n.Ay,{mb:1},(0,p.A)(__("Check out our troubleshooting guide or contact your hosting provider to resolve the issue.","jetpack-my-jetpack")))),r={id:"backup-needs-attention-notice",level:w,actions:[{label:__("Read troubleshooting guide","jetpack-my-jetpack"),onClick:P,noDefaultClasses:!0},{label:__("Contact support","jetpack-my-jetpack"),onClick:R,isExternalLink:!0}],onClose:S,hideCloseButton:!1,priority:c.pv};t||f({title:A,message:a,options:r})}),[e,f,a,S,P,R,A,E,w,_,t])}},15048:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(27723),o=a(51609),n=a(73537),l=a(76007),s=a(64526);const __=r.__,i=(e,t)=>{const{setNotice:a}=(0,o.useContext)(l.g),{recordEvent:i}=(0,s.A)();(0,o.useEffect)((()=>{const o=t?[]:Object.keys(e).filter((e=>e.endsWith("-bad-installation")));if(0===o.length)return;const l=e[o[0]],{plugin:s}=l.data,c=(0,r.sprintf)( -// translators: %s is the name of the plugin that has a bad installation. -__("Your installation of %1$s is incomplete. If you installed %1$s from GitHub, please refer to the developer documentation to set up your development environment.","jetpack-my-jetpack"),s),u={id:"bad-installation-notice",level:"error",actions:[{label:__("See documentation","jetpack-my-jetpack"),onClick:()=>{window.open("https://github.com/Automattic/jetpack/blob/trunk/docs/development-environment.md"),i("jetpack_my_jetpack_bad_installation_notice_cta_click",{plugin:s})},noDefaultClasses:!0}],priority:n.EX};t||a({message:c,options:u})}),[e,a,i,t])}},68245:(e,t,a)=>{"use strict";a.d(t,{A:()=>d});var r=a(28509),o=a(47425),n=a(39384),l=a(27723),s=a(51609),i=a(73537),c=a(76007),u=a(64526);const __=l.__,d=()=>{const{setNotice:e,currentNotice:t}=(0,s.useContext)(c.g),{hasConnectionError:a,connectionErrorMessage:d}=(0,n.useConnectionErrorNotice)(),{restoreConnection:v,isRestoringConnection:p,restoreConnectionError:m}=(0,n.useRestoreConnection)(),{recordEvent:h}=(0,u.A)();(0,s.useEffect)((()=>{if(!a)return;let t=d;m&&(t=React.createElement(r.A,null,React.createElement(o.Ay,{mb:2},(0,l.sprintf)(/* translators: placeholder is the error. */ -__("There was an error reconnecting Jetpack. Error: %s","jetpack-my-jetpack"),m)),React.createElement(o.Ay,{mb:2},d)));const n=__("Reconnecting Jetpack…","jetpack-my-jetpack"),s={id:"connection-error-notice",level:"error",actions:[{label:__("Restore Connection","jetpack-my-jetpack"),onClick:()=>{v(),h("jetpack_my_jetpack_connection_error_notice_reconnect_cta_click")},isLoading:p,loadingText:n,noDefaultClasses:!0}],priority:i.pv+(p?1:0)};e({message:t,options:s})}),[e,h,a,d,v,p,m,t.options.priority])}},75782:(e,t,a)=>{"use strict";a.d(t,{A:()=>u});var r=a(27723),o=a(51609),n=a(73537),l=a(76007),s=a(79131),i=a(64526),c=a(77068);const __=r.__,u=(e,t)=>{const{setNotice:a,resetNotice:r}=(0,o.useContext)(l.g),{recordEvent:u}=(0,i.A)(),d=t?[]:Object.keys(e).filter((e=>e.endsWith("--plan_expiring_soon")||e.endsWith("--plan_expired"))),v=d.length&&d.filter((e=>e.endsWith("--plan_expired"))),p=d.length&&d.filter((e=>e.endsWith("--plan_expiring_soon"))),m=v.length?v[0]:p[0],h=m&&m.endsWith("--plan_expired"),f=h?"expired":"expiring-soon",{product_slug:g,product_name:w,expiry_date:b,manage_url:y,products_effected:x}=e?.[m]||{},{noticeTitle:_,noticeMessage:k,learnMoreUrl:E}=(0,c.t)({productSlug:g,expiredAlertType:f,productName:w,expiryDate:b,productsEffected:x})||{},C=(0,o.useMemo)((()=>h?`${g}--plan_expired`:`${g}--plan_expiring_soon`),[h,g]),j=(0,o.useCallback)((()=>{(0,s.A)(`${C}_dismissed`,7),delete e[m],r()}),[m,e,r,C]),A=(0,o.useCallback)((()=>{window.location.href=y,u(h?"jetpack_my_jetpack_plan_expired_notice_primary_cta_click":"jetpack_my_jetpack_plan_expiring_soon_notice_primary_cta_click",{product_slug:g})}),[h,y,g,u]),S=(0,o.useCallback)((()=>{window.open(E),u(h?"jetpack_my_jetpack_plan_expired_notice_secondary_cta_click":"jetpack_my_jetpack_plan_expiring_soon_notice_secondary_cta_click",{product_slug:g})}),[E,h,g,u]);(0,o.useEffect)((()=>{if(!m)return;const e=__("Resume my plan","jetpack-my-jetpack"),r=__("Renew my plan","jetpack-my-jetpack"),o={id:h?"plan-expired-notice":"plan-expiring-soon-notice",level:h?"error":"warning",actions:[{label:h?e:r,onClick:A,noDefaultClasses:!0},{label:__("Learn more","jetpack-my-jetpack"),onClick:S,isExternalLink:!0}],onClose:j,hideCloseButton:!1,priority:n.EX};t||a({title:_,message:k,options:o})}),[e,a,u,m,j,A,S,_,k,h,g,C,t])}},77068:(e,t,a)=>{"use strict";a.d(t,{t:()=>i});var r=a(28509),o=a(47425),n=a(38443),l=a(27723),s=a(50977);const __=l.__,i=({productSlug:e,expiredAlertType:t,productName:a,expiryDate:i,productsEffected:c})=>{if(!e)return null;const u=e.replace(/(?:_t1|_t2|_bi)?(?:_yearly|_monthly)/,""),d=(0,n.gmdateI18n)("M j, Y",i),v="expired"===t?(0,l.sprintf)( -// translators: %s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.. -__("Your %1$s plan has expired","jetpack-my-jetpack"),a):(0,l.sprintf)( -// translators: %1$s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.. -__("Heads up! Your %1$s plan is about to expire","jetpack-my-jetpack"),a);switch(u){case"jetpack_videopress":return{noticeTitle:v,noticeMessage:"expired"===t?React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2,mb:2},__("Your videos are no longer visible to your viewers, and you won’t be able to upload new content.","jetpack-my-jetpack")),React.createElement(o.Ay,{mb:2},__("Don’t worry—you can resume your plan anytime to restore your video library and continue uploading.","jetpack-my-jetpack")))):React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2,mb:2},__("Your videos will soon stop showing for your viewers, and you won’t be able to upload new content.","jetpack-my-jetpack")),React.createElement(o.Ay,{mb:2},(0,l.sprintf)( -// translators: %1$s is the product's expiration date, i.e.- "Nov 11, 2024" -__("To keep everything running smoothly, renew your plan by %1$s!","jetpack-my-jetpack"),d)))),learnMoreUrl:"https://jetpack.com/support/jetpack-videopress/#canceled-or-expired-videopress-plan"};case"jetpack_complete":case"jetpack_security":case"jetpack_growth":return{noticeTitle:v,noticeMessage:"expired"===t?React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2},(0,l.sprintf)( -// translators: %1$s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.. -__("%1$s provides paid features for the following products:","jetpack-my-jetpack"),a)),React.createElement(s.j,{products:c}),React.createElement(o.Ay,{mb:2},(0,l.sprintf)( -// translators: %1$s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.. -__("Since your %1$s plan is expired, the paid features for these products are no longer available for your site.","jetpack-my-jetpack"),a)),React.createElement(o.Ay,{mb:2},__("But don’t worry—you can resume your plan to restore your access to your plan’s paid features.","jetpack-my-jetpack")))):React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2},(0,l.sprintf)( -// translators: %1$s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.. -__("%1$s provides paid features for the following products:","jetpack-my-jetpack"),a)),React.createElement(s.j,{products:c}),React.createElement(o.Ay,{mb:2},(0,l.sprintf)( -// translators: %1$s is the product's expiration date, i.e.- "Nov 11, 2024" -__("Renew your plan by %1$s to continue to have access to the paid features of these products.","jetpack-my-jetpack"),d)))),learnMoreUrl:"https://jetpack.com/support/jetpack-billing-payments/"};default:return{noticeTitle:v,noticeMessage:"expired"===t?React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2,mb:2},(0,l.sprintf)( -// translators: %1$s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.. -__("Your %1$s subcription has expired. The paid features are no longer available.","jetpack-my-jetpack"),a)),React.createElement(o.Ay,{mb:2},__("Don’t worry—you can resume your plan anytime to restore your access to the upgraded features.","jetpack-my-jetpack")))):React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2,mb:2},(0,l.sprintf)( -// translators: %1$s is the Jetpack product name, i.e.- Jetpack Backup, Jetpack Security, etc.., %2$s is the product's expiration date, i.e.- "Nov 11, 2024". -__("Your %1$s subcription will be expiring soon on %2$s, and the paid features for this product will no longer be available.","jetpack-my-jetpack"),a,d)),React.createElement(o.Ay,{mb:2},__("To keep everything running smoothly, renew your plan today!","jetpack-my-jetpack")))),learnMoreUrl:"https://jetpack.com/support/jetpack-billing-payments/"}}}},40271:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(27723),o=a(51609),n=a(62902);const __=r.__,l=()=>{const{data:e,isLoading:t}=(0,n.A)(),{backup_failure:a}=e,l=a?.data?.status;return{isLoading:t,reasonContent:(0,o.useMemo)((()=>{switch(l){case"missing_plan":return{title:__("Missing Backup plan","jetpack-my-jetpack"),text:__("The site does not appear to have a valid Backup plan. Please purchase a Backup plan in order activate the features of Jetpack Backup.","jetpack-my-jetpack")};case"no_connected_jetpack":return{title:__("Not connected","jetpack-my-jetpack"),text:__("The site doesn’t appear to be connected. Backup requires an active Jetpack connection in order to function properly.","jetpack-my-jetpack")};case"no_connected_jetpack_with_credentials":return{title:__("Not connected","jetpack-my-jetpack"),text:__("The site doesn’t appear to be connected. Backup requires an active Jetpack connection in order to function properly, although successful Backups may still appear in the logs.","jetpack-my-jetpack")};case"vp_active_on_site":return{title:__("Backup plugin conflict","jetpack-my-jetpack"),text:__("We’ve detected VaultPress is currently active on the site. VaultPress and Jetpack Backup cannot run simultaneously. In order to activate Jetpack Backup, you will first need to deactivate VaultPress.","jetpack-my-jetpack")};case"vp_can_transfer":return{title:__("Transfer VaultPress","jetpack-my-jetpack"),text:__("We’ve detected VaultPress is currently active on the site, and we can automatically transfer it over to Jetpack Backup (Rewind), but you will need to trigger the transfer manually.","jetpack-my-jetpack")};case"host_not_supported":return{title:__("Host not supported","jetpack-my-jetpack"),text:__("Backup doesn’t currently support the host that the site is hosted on.","jetpack-my-jetpack")};case"multisite_not_supported":return{title:__("Multi-site not supported","jetpack-my-jetpack"),text:__("Backup can’t be activated on multi-site installations, neither the network site or its sub-sites.","jetpack-my-jetpack")};case"no_site_found":return{title:__("No site record","jetpack-my-jetpack"),text:__("The VaultPress API could not recognize the site ID associated with your site, or multiple site ID’s are associated with the same site domain.","jetpack-my-jetpack")};case"no-credentials":return{title:__("No credentials found","jetpack-my-jetpack"),text:__("No remote server credentials were found. Please add your website’s server credentials in Backup settings so Backup can fully function properly.","jetpack-my-jetpack")};case"no-credentials-atomic":return{title:__("No credentials (Atomic)","jetpack-my-jetpack"),text:__("There appears to be some issue with the Atomic API or a networking type issue. Please try again shortly to see if the issue has resolved.","jetpack-my-jetpack")};case"credential-error":return{title:__("Backup error","jetpack-my-jetpack"),text:__("Although the site appears to be up and accessible, and remote server credentials are set, Backup still encountered an error during the last backup attempt.","jetpack-my-jetpack")};case"http-only-error":return{title:__("Backup error","jetpack-my-jetpack"),text:__("Although the site appears to be up and accessible, Backup still encountered an error during the last backup attempt.","jetpack-my-jetpack")};case"not-accessible":return{title:__("Site unavailable","jetpack-my-jetpack"),text:__("Backup was unable to access your site during the last backup attempt. This could be due to networking issues, a block from your host, or other server issues.","jetpack-my-jetpack")};case"Kill switch active":case"backup-deactivated":return{title:__("Backup is deactivated","jetpack-my-jetpack"),text:__("It appear Backup has been manually deactivated, either by a site attribute or a general kill switch.","jetpack-my-jetpack")};case"error":return{title:__("Backup system error","jetpack-my-jetpack"),text:__("Backup has encountered a general system error and was unable to complete the last backup attempt.","jetpack-my-jetpack")};default:{if(!l)return{title:null,text:null};const e=l.split(/[_\s-]/);e[0]=e[0].charAt(0).toUpperCase()+e[0].slice(1);const t=e.join(" ");return{title:(0,r.sprintf)( -// translators: %s is the error code coming from the server (formatted, i.e.- first word capitalized, hypen's removed, etc. ) i.e.- 'Invalid credentials', 'File not found', etc. -__("%s error","jetpack-my-jetpack"),t),text:(0,r.sprintf)( -// translators: %s is the error code coming from the server. i.e.- 'invalid-credentials', 'file-not-found', etc. -__("Error code: %s","jetpack-my-jetpack"),l)}}}}),[l])}}},53866:(e,t,a)=>{"use strict";a.d(t,{A:()=>b});var r=a(28509),o=a(47425),n=a(56427),l=a(27723),s=a(51609),i=a(73537),c=a(76007),u=a(31504),d=a(41526),v=a(55394),p=a(280),m=a(68242),h=a(51870),f=a(79131),g=a(64526),w=a(38318);const __=l.__,_n=l._n,b=(e,t)=>{const{setNotice:a,resetNotice:b}=(0,s.useContext)(c.g),{recordEvent:y}=(0,g.A)(),{isSiteConnected:x}=(0,h.A)(),_=(0,p.A)({name:u.Ck,query:{path:u.tb},options:{enabled:x}}),{isLoading:k,isError:E}=_,C=_.data,j=C&&!k&&!E,A="object"==typeof e?Object.keys(e).length:0,S=(0,s.useMemo)((()=>t||0===A?[]:Object.keys(e).filter((e=>e.endsWith("--plugins_needing_installed_activated")))),[t,A,e]),P=e?.[S[0]],R=S[0],M=R?.split("--")[0],V=(0,s.useMemo)((()=>j&&C.find((e=>e.product_slug===M))),[j,M,C]),z=V&&V.product_name,{needs_installed:H,needs_activated_only:L}=P||{},O=(H?.length??0)+(L?.length??0),{products:{items:N}}=(0,m.A$)(),I=(0,s.useMemo)((()=>H&&L?"install_activate":H?"install":"activate"),[L,H]),B=(0,s.useCallback)(((e,t)=>({productSlug:e,pluginSlug:N[e].plugin_slug,pluginName:"jetpack"===N[e].plugin_slug?"Jetpack":N[e].title,action:t,pluginUri:`https://wordpress.org/plugins/${N[e].plugin_slug}/`})),[N]),T=(0,s.useMemo)((()=>{if(H&&L){const e=new Set;return[...[...H].map((e=>B(e,"install"))),...[...L].map((e=>B(e,"activate")))].filter((({pluginSlug:t})=>!e.has(t)&&e.add(t)))}if(H){const e=new Set;return H.map((e=>B(e,"install"))).filter((({pluginSlug:t})=>!e.has(t)&&e.add(t)))}const e=new Set;return L?.map((e=>B(e,"activate"))).filter((({pluginSlug:t})=>!e.has(t)&&e.add(t)))}),[B,L,H]),{noticeTitle:F,noticeMessage:D,buttonLabel:G}=(0,w.n)({alert:P,planName:z,planPurchaseId:V?.ID}),U=(0,s.useCallback)((e=>{if(!e)return[];return[...e].map((e=>({productSlug:e,pluginSlug:N[e].plugin_slug}))).sort(((e,t)=>"jetpack"===e.pluginSlug?1:"jetpack"===t.pluginSlug?-1:e.productSlug-t.productSlug)).map((({productSlug:e})=>e))}),[N]),q=U(H),Z=U(L),W=q.find((e=>"jetpack"===N[e].plugin_slug)),$=(0,s.useCallback)((()=>{(0,f.A)(`${M}--plugins_needing_installed_dismissed`,14),delete e[S[0]],b()}),[M,S,e,b]),{install:J,isPending:K}=(0,v.A)(q),{activate:Q,isPending:Y}=(0,d.A)(Z),X=(0,s.useCallback)((()=>{if(y("jetpack_my_jetpack_plugin_needs_installed_notice_cta_click"),q.length&&Z.length)return W?void Q(null,{onSuccess:()=>{J(null,{onSuccess:()=>{delete e[S[0]],b()}})}}):void J(null,{onSuccess:()=>{Q(null,{onSuccess:()=>{delete e[S[0]],b()}})}});q.length?J(null,{onSuccess:()=>{delete e[S[0]],b()}}):Z.length&&Q(null,{onSuccess:()=>{delete e[S[0]],b()}})}),[y,q,Z,W,J,Q,e,S,b]);(0,s.useEffect)((()=>{if(0===S.length||!j)return;const e={install:__("Needs installation and activation","jetpack-my-jetpack"),activate:__("Needs activation","jetpack-my-jetpack")},s=React.createElement(React.Fragment,null,React.createElement(r.A,null,React.createElement(o.Ay,{mt:2,mb:2},D),React.createElement("ul",{className:"plugins-list"},T?.length>0&&T.map(((t,a)=>React.createElement("li",{key:a,className:"plugin-item"},"activate"===t.action?React.createElement("a",{href:"/wp-admin/plugins.php"},t.pluginName):React.createElement(n.ExternalLink,{href:t.pluginUri},t.pluginName),React.createElement("span",null,"(",e[t.action],")"))))))),c=Y||K,u={id:"plugin_needs_installed_activated",level:"warning",actions:[{label:G,onClick:X,isLoading:c,loadingText:"activate"===I?(0,l.sprintf)(/* translators: %s is the singular or plural "plugin" or "plugins". */ -__("Activating %s…","jetpack-my-jetpack"),_n("plugin","plugins",O,"jetpack-my-jetpack")):(0,l.sprintf)(/* translators: %s is the singular or plural "plugin" or "plugins". */ -__("Installing and activating %s…","jetpack-my-jetpack"),_n("plugin","plugins",O,"jetpack-my-jetpack")),noDefaultClasses:!0}],onClose:$,hideCloseButton:!1,priority:i.EX+(c?1:0)};t||a({title:F,message:s,options:u})}),[I,F,D,G,j,O,$,X,z,V,T,S.length,a,K,Y,M,t])}},247:(e,t,a)=>{"use strict";a.d(t,{A:()=>m});var r=a(3924),o=a(28509),n=a(47425),l=a(27723),s=a(51609),i=a(73537),c=a(76007),u=a(74923),d=a(79131),v=a(72434),p=a(64526);const __=l.__,m=(e,t)=>{const{recordEvent:a}=(0,p.A)(),{setNotice:m,resetNotice:h}=(0,s.useContext)(c.g),{detail:f}=(0,u.A)("protect"),{hasPaidPlanForProduct:g,standalonePluginInfo:w,manageUrl:b}=f||{},{isStandaloneActive:y}=w||{},{type:x,data:{threat_count:_,critical_threat_count:k,fixable_threat_ids:E}}=e?.protect_has_threats||{type:"warning",data:{}},C=(0,r.A)("protect-footer-learn-more-scan",{anchor:"how-do-i-fix-threats"}),j=(0,l.sprintf)( -// translators: %s is the product name. Can be either "Scan" or "Protect". -__("%s found threats on your site","jetpack-my-jetpack"),g&&y?"Protect":"Scan"),A=(0,s.useCallback)((()=>{(0,d.A)("protect_threats_detected_dismissed",7),delete e?.protect_has_threats,h()}),[e?.protect_has_threats,h]),S=(0,s.useCallback)((()=>{window.open(b),a("jetpack_my_jetpack_protect_threats_detected_notice_primary_cta_click",{threat_count:_,critical_threat_count:k,fixable_threat_ids:E})}),[k,E,b,a,_]),P=(0,s.useCallback)((()=>{window.open(C),a("jetpack_my_jetpack_protect_threats_detected_notice_secondary_cta_click",{threat_count:_,critical_threat_count:k,fixable_threat_ids:E})}),[k,C,E,a,_]);(0,s.useEffect)((()=>{if(!e?.protect_has_threats)return;const a=React.createElement(o.A,null,React.createElement(n.Ay,{mb:1},(0,v.A)(__("We’ve detected some security threats that need your attention.","jetpack-my-jetpack"))),React.createElement(n.Ay,{mb:1},(0,v.A)((0,l.sprintf)( -// translators: %s is the product name. Can be either "Scan" or "Protect". -__("Visit the %s dashboard to view threat details, auto-fix threats, and keep your site safe.","jetpack-my-jetpack"),g&&y?"Protect":"Scan")))),r={id:"protect-threats-detected-notice",level:x,actions:[{label:__("Fix threats","jetpack-my-jetpack"),onClick:S,noDefaultClasses:!0},{label:__("Learn more","jetpack-my-jetpack"),onClick:P,isExternalLink:!0}],onClose:A,hideCloseButton:!1,priority:i.EX};t||m({title:j,message:a,options:r})}),[g,y,j,A,S,P,e?.protect_has_threats,m,x,t])}},52963:(e,t,a)=>{"use strict";a.d(t,{A:()=>w});var r=a(28509),o=a(47425),n=a(85879),l=a(27723),s=a(51609),i=a(38837),c=a(73537),u=a(76007),d=a(488),v=a(65350),p=a(18117),m=a(64526),h=a(36312),f=a(51870),g=a(33981);const __=l.__,w=(e,t)=>{const{recordEvent:a}=(0,m.A)(),{setNotice:w,resetNotice:b}=(0,s.useContext)(u.g),{siteIsRegistering:y,isSiteConnected:x}=(0,f.A)({skipUserConnection:!0}),{data:_,isLoading:k,isError:E}=(0,d.V)(),C=(0,g.A)(i.NM.ConnectionSkipPricing),j="missing-connection",A=e?.[j],{connectSite:S}=(0,h.A)({tracksInfo:{event:"jetpack_my_jetpack_site_connection_notice_cta",properties:{}}}),{refetch:P}=(0,v.A)(),R=(0,s.useMemo)((()=>t||k||E?[]:(0,p.A)(_)),[t,E,k,_]);(0,s.useEffect)((()=>{if(!A)return;const e="user"===A.type,s=(0,l.sprintf)(/* translators: placeholder is product name. */ -__("Jetpack %s needs a user connection to WordPress.com to be able to work.","jetpack-my-jetpack"),R[0]),i={message:1===R.length?s:__("Some products need a user connection to WordPress.com to be able to work.","jetpack-my-jetpack"),buttonLabel:__("Connect your user account","jetpack-my-jetpack"),title:__("Missing user connection","jetpack-my-jetpack")},u={message:__("Some products need a connection to WordPress.com to be able to work.","jetpack-my-jetpack"),buttonLabel:__("Connect your site","jetpack-my-jetpack"),title:__("Missing site connection","jetpack-my-jetpack")},d={id:j,level:A.is_error?"error":"info",actions:[{label:e?i.buttonLabel:u.buttonLabel,isLoading:y,loadingText:__("Connecting…","jetpack-my-jetpack"),onClick:({e:t})=>{e?(a("jetpack_my_jetpack_user_connection_notice_cta_click"),C()):S(t)},noDefaultClasses:!0}],priority:c.pv+(y?1:0),isRedBubble:!0,tracksArgs:{type:A.type,is_error:A.is_error}},v=e?i.message:React.createElement(r.A,null,React.createElement(o.Ay,{mb:2},u.message),React.createElement(n.A,{agreeButtonLabel:u.buttonLabel}));t||w({message:v,title:e?i.title:u.title,options:d})}),[x,S,C,_,a,e,b,w,y,A,P,R,t])}},51413:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});var r=a(51609);const o=(e,t)=>{(0,r.useEffect)((()=>{const a=a=>{a.target instanceof Element&&e.current&&!e.current.contains(a.target)&&t(a)};return document.addEventListener("mousedown",a),()=>{document.removeEventListener("mousedown",a)}}),[e,t])}},1524:(e,t,a)=>{"use strict";function r(){const e=window.location.search;return new URLSearchParams(e).has("redirect_to_referrer","1")&&""!==document.referrer?document.referrer:null}a.d(t,{y:()=>r})},90926:(e,t,a)=>{"use strict";a.d(t,{A:()=>i});var r=a(50723),o=a(70116),n=a(77115),l=a(76007),s=a(56077);const i=({children:e})=>{const t=new o.E;return React.createElement(r.Ay,null,React.createElement(l.A,null,React.createElement(s.A,null,React.createElement(n.Ht,{client:t},e))))}},88220:(e,t,a)=>{"use strict";a.d(t,{w:()=>o});var r=a(38443);function o(e,t){const a=(0,r.getDate)(e);return a.setHours(a.getHours()+t),a}},79131:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=(e,t)=>{const a=new Date(Date.now()+864e5*t);document.cookie=`${e}=1; expires=${a.toString()}; SameSite=None; Secure`}},56581:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(37975);const o={maximumFractionDigits:1,notation:"compact"},n=(e,t=o)=>null!==e&&Number.isFinite(e)?(0,r.A)(e,t):"-"},88496:(e,t,a)=>{"use strict";a.d(t,{A:()=>n});var r=a(37975);const o={style:"percent"},n=(e,t=o)=>null!==e&&Number.isFinite(e)?(t.style="percent",(0,r.A)(e,t)):"-"},32753:(e,t,a)=>{"use strict";a.d(t,{A:()=>r});const r=e=>{e=Math.floor(e);const t=Math.floor(e/24),a=Math.floor(t/365);if(a>0)return`${a}y ${t%365}d`;if(t>0)return`${t}d ${e%24}h`;const r=Math.floor(3600*e),o=Math.floor(r/60);return e>0?`${e}h ${o%60}m`:o>0?`${o}m ${r%60}s`:`${Math.floor(r)}s`}},46256:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(3924),o=a(38837),n=a(68242);const l=()=>{const{siteSuffix:e="",blogID:t}=(0,n.A$)();return(0,r.A)(o.OM,{site:t??e})}},93542:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(3924),o=a(38837),n=a(68242);const l=()=>{const{siteSuffix:e="",blogID:t,myJetpackCheckoutUri:a,lifecycleStats:l,siteSuffix:s,adminUrl:i}=(0,n.A$)(),{isSiteConnected:c,isUserConnected:u}=l,d=c&&u,v=d?o.ED:o.mk;return(0,r.A)(v,(()=>{const r=`${`redirect_to=${a}`}${d?"":`&connect_after_checkout=true&from_site_slug=${s}&admin_url=${i}&unlinked=1`}`;return d?{site:t??e,query:r}:{query:r}})())}},23658:(e,t,a)=>{"use strict";a.d(t,{w:()=>o});var r=a(68242);const o=()=>{const{plugins:e}=(0,r.A$)()||{},t=Object.values(e).find((e=>"Jetpack"===e?.Name));return t&&t.active}},28252:(e,t,a)=>{"use strict";a.d(t,{M:()=>o,b:()=>r});const r=({partner_slug:e})=>!!e&&"goldenticket"===e;function o(e){return!!Array.isArray(e)&&e.filter((e=>r(e))).length>0}},72434:(e,t,a)=>{"use strict";a.d(t,{A:()=>o});const r=/\s+(\S*)$/,o=(e,t=2)=>((e,t)=>{let a=0;if(e&&e.length>0){let o=e,n="";for(;a{"use strict";a.d(t,{_:()=>o});var r=a(27723);const _n=r._n,__=r.__;function o(e){const t=new Date,a=6e4*t.getTimezoneOffset(),o=Math.floor((new Date(t.getTime()+a).getTime()-e)/1e3);let n=o/31536e3;return n>1?(0,r.sprintf)( -// translators: placeholder is a number amount of years i.e. "5 years ago". -_n("%s year ago","%s years ago",Math.floor(n),"jetpack-my-jetpack"),Math.floor(n)):(n=o/2592e3,n>1?(0,r.sprintf)( -// translators: placeholder is a number amount of months i.e. "5 months ago". -_n("%s month ago","%s months ago",Math.floor(n),"jetpack-my-jetpack"),Math.floor(n)):(n=o/86400,n>1?(0,r.sprintf)( -// translators: placeholder is a number amount of days i.e. "5 days ago". -_n("%s day ago","%s days ago",Math.floor(n),"jetpack-my-jetpack"),Math.floor(n)):(n=o/3600,n>1?(0,r.sprintf)( -// translators: placeholder is a number amount of hours i.e. "5 hours ago". -_n("%s hour ago","%s hours ago",Math.floor(n),"jetpack-my-jetpack"),Math.floor(n)):(n=o/60,n>1?(0,r.sprintf)( -// translators: placeholder is a number amount of minutes i.e. "5 minutes ago". -_n("%s minute ago","%s minutes ago",Math.floor(n),"jetpack-my-jetpack"),Math.floor(n)):__("a few seconds ago","jetpack-my-jetpack")))))}},72423:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DataFormProvider=function({fields:e,children:t}){return(0,o.jsx)(n.Provider,{value:{fields:e},children:t})},t.default=void 0;var r=a(86087),o=a(10790);const n=(0,r.createContext)({fields:[]});t.default=n},44117:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,form:t,fields:a,onChange:i}){const c=(0,r.useMemo)((()=>(0,n.normalizeFields)(a)),[a]);if(!t.fields)return null;return(0,s.jsx)(o.DataFormProvider,{fields:c,children:(0,s.jsx)(l.DataFormLayout,{data:e,form:t,onChange:i})})};var r=a(86087),o=a(72423),n=a(53582),l=a(49901),s=a(10790)},10192:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.BulkActionsFooter=function(){const{data:e,selection:t,actions:a=h,onChangeSelection:r,getItemId:o}=(0,l.useContext)(c.default);return(0,d.jsx)(w,{selection:t,onChangeSelection:r,data:e,actions:a,getItemId:o})},t.BulkSelectionCheckbox=p,t.useHasAPossibleBulkAction=function(e,t){return(0,l.useMemo)((()=>e.some((e=>e.supportsBulk&&(!e.isEligible||e.isEligible(t))))),[e,t])},t.useSomeItemHasAPossibleBulkAction=function(e,t){return(0,l.useMemo)((()=>t.some((t=>e.some((e=>e.supportsBulk&&(!e.isEligible||e.isEligible(t))))))),[e,t])};var o=a(56427),n=a(27723),l=a(86087),s=a(47143),i=a(83203),c=r(a(60789)),u=a(97867),d=a(10790);function v({action:e,items:t,ActionTriggerComponent:a}){const[r,o]=(0,l.useState)(!1),n={action:e,onClick:()=>{o(!0)},items:t};return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(a,{...n}),r&&(0,d.jsx)(u.ActionModal,{action:e,items:t,closeModal:()=>o(!1)})]})}function p({selection:e,onChangeSelection:t,data:a,actions:r,getItemId:s}){const i=(0,l.useMemo)((()=>a.filter((e=>r.some((t=>t.supportsBulk&&(!t.isEligible||t.isEligible(e))))))),[a,r]),c=a.filter((t=>e.includes(s(t))&&i.includes(t))),u=c.length===i.length;return(0,d.jsx)(o.CheckboxControl,{className:"dataviews-view-table-selection-checkbox",__nextHasNoMarginBottom:!0,checked:u,indeterminate:!u&&!!c.length,onChange:()=>{t(u?[]:i.map((e=>s(e))))},"aria-label":u?(0,n.__)("Deselect all","jetpack-my-jetpack"):(0,n.__)("Select all","jetpack-my-jetpack")})}function m({action:e,onClick:t,isBusy:a,items:r}){const n="string"==typeof e.label?e.label:e.label(r);return(0,d.jsx)(o.Button,{disabled:a,accessibleWhenDisabled:!0,label:n,icon:e.icon,isDestructive:e.isDestructive,size:"compact",onClick:t,isBusy:a,tooltipPosition:"top"})}const h=[];function f({action:e,selectedItems:t,actionInProgress:a,setActionInProgress:r}){const o=(0,s.useRegistry)(),n=(0,l.useMemo)((()=>t.filter((t=>!e.isEligible||e.isEligible(t)))),[e,t]);return"RenderModal"in e?(0,d.jsx)(v,{action:e,items:n,ActionTriggerComponent:m},e.id):(0,d.jsx)(m,{action:e,onClick:async()=>{r(e.id),await e.callback(t,{registry:o}),r(null)},items:n,isBusy:a===e.id},e.id)}function g(e,t,a,r,l,s,c,u,v){const m=s.length>0?(0,n.sprintf)(/* translators: %d: number of items. */ /* translators: %d: number of items. */ -(0,n._n)("%d Item selected","%d Items selected",s.length,"jetpack-my-jetpack"),s.length):(0,n.sprintf)(/* translators: %d: number of items. */ /* translators: %d: number of items. */ -(0,n._n)("%d Item","%d Items",e.length,"jetpack-my-jetpack"),e.length);return(0,d.jsxs)(o.__experimentalHStack,{expanded:!1,className:"dataviews-bulk-actions-footer__container",spacing:3,children:[(0,d.jsx)(p,{selection:r,onChangeSelection:v,data:e,actions:t,getItemId:a}),(0,d.jsx)("span",{className:"dataviews-bulk-actions-footer__item-count",children:m}),(0,d.jsxs)(o.__experimentalHStack,{className:"dataviews-bulk-actions-footer__action-buttons",expanded:!1,spacing:1,children:[l.map((e=>(0,d.jsx)(f,{action:e,selectedItems:s,actionInProgress:c,setActionInProgress:u},e.id))),s.length>0&&(0,d.jsx)(o.Button,{icon:i.closeSmall,showTooltip:!0,tooltipPosition:"top",size:"compact",label:(0,n.__)("Cancel","jetpack-my-jetpack"),disabled:!!c,accessibleWhenDisabled:!1,onClick:()=>{v(h)}})]})]})}function w({selection:e,actions:t,onChangeSelection:a,data:r,getItemId:o}){const[n,s]=(0,l.useState)(null),i=(0,l.useRef)(null),c=(0,l.useMemo)((()=>t.filter((e=>e.supportsBulk))),[t]),u=(0,l.useMemo)((()=>r.filter((e=>c.some((t=>!t.isEligible||t.isEligible(e)))))),[r,c]),d=(0,l.useMemo)((()=>r.filter((t=>e.includes(o(t))&&u.includes(t)))),[e,r,o,u]),v=(0,l.useMemo)((()=>t.filter((e=>e.supportsBulk&&e.icon&&d.some((t=>!e.isEligible||e.isEligible(t)))))),[t,d]);return n?(i.current||(i.current=g(r,t,o,e,v,d,n,s,a)),i.current):(i.current&&(i.current=null),g(r,t,o,e,v,d,n,s,a))}},60789:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=a(86087),o=a(64116);const n=(0,r.createContext)({view:{type:o.LAYOUT_TABLE},onChangeView:()=>{},fields:[],data:[],paginationInfo:{totalItems:0,totalPages:0},selection:[],onChangeSelection:()=>{},setOpenedFilter:()=>{},openedFilter:null,getItemId:e=>e.id,isItemClickable:()=>!0,containerWidth:0});t.default=n},18645:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AddFilterMenu=c,t.default=void 0;var r=a(56427),o=a(27723),n=a(86087),l=a(40191),s=a(10790);const{Menu:i}=(0,l.unlock)(r.privateApis);function c({filters:e,view:t,onChangeView:a,setOpenedFilter:r,triggerProps:o}){const n=e.filter((e=>!e.isVisible));return(0,s.jsxs)(i,{children:[(0,s.jsx)(i.TriggerButton,{...o}),(0,s.jsx)(i.Popover,{children:n.map((e=>(0,s.jsx)(i.Item,{onClick:()=>{r(e.field),a({...t,page:1,filters:[...t.filters||[],{field:e.field,value:void 0,operator:e.operators[0]}]})},children:(0,s.jsx)(i.ItemLabel,{children:e.name})},e.field)))})]})}t.default=(0,n.forwardRef)((function({filters:e,view:t,onChangeView:a,setOpenedFilter:n},l){if(!e.length||e.every((({isPrimary:e})=>e)))return null;const i=e.filter((e=>!e.isVisible));return(0,s.jsx)(c,{triggerProps:{render:(0,s.jsx)(r.Button,{accessibleWhenDisabled:!0,size:"compact",className:"dataviews-filters-button",variant:"tertiary",disabled:!i.length,ref:l}),children:(0,o.__)("Add filter","jetpack-my-jetpack")},filters:e,view:t,onChangeView:a,setOpenedFilter:n})}))},33162:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({addFilterRef:e,openedFilter:t,...a}){const r=(0,s.useRef)(null),{filter:u,view:f,onChangeView:g}=a,w=f.filters?.find((e=>e.field===u.field)),b=u.elements.filter((e=>u.singleSelection?e.value===w?.value:w?.value?.includes(e.value))),y=u.isPrimary,x=void 0!==w?.value,_=!y||x;return(0,d.jsx)(n.Dropdown,{defaultOpen:t===u.field,contentClassName:"dataviews-filters__summary-popover",popoverProps:{placement:"bottom-start",role:"dialog"},onClose:()=>{r.current?.focus()},renderToggle:({isOpen:t,onToggle:a})=>(0,d.jsxs)("div",{className:"dataviews-filters__summary-chip-container",children:[(0,d.jsx)(n.Tooltip,{text:(0,l.sprintf)(/* translators: 1: Filter name. */ /* translators: 1: Filter name. */ -(0,l.__)("Filter by: %1$s","jetpack-my-jetpack"),u.name.toLowerCase()),placement:"top",children:(0,d.jsx)("div",{className:(0,o.default)("dataviews-filters__summary-chip",{"has-reset":_,"has-values":x}),role:"button",tabIndex:0,onClick:a,onKeyDown:e=>{[v,p].includes(e.key)&&(a(),e.preventDefault())},"aria-pressed":t,"aria-expanded":t,ref:r,children:(0,d.jsx)(m,{activeElements:b,filterInView:w,filter:u})})}),_&&(0,d.jsx)(n.Tooltip,{text:y?(0,l.__)("Reset","jetpack-my-jetpack"):(0,l.__)("Remove","jetpack-my-jetpack"),placement:"top",children:(0,d.jsx)("button",{className:(0,o.default)("dataviews-filters__summary-chip-remove",{"has-values":x}),onClick:()=>{g({...f,page:1,filters:f.filters?.filter((e=>e.field!==u.field))}),y?r.current?.focus():e.current?.focus()},children:(0,d.jsx)(n.Icon,{icon:i.closeSmall})})})]}),renderContent:()=>(0,d.jsxs)(n.__experimentalVStack,{spacing:0,justify:"flex-start",children:[(0,d.jsx)(h,{...a}),(0,d.jsx)(c.default,{...a})]})})};var o=r(a(33752)),n=a(56427),l=a(27723),s=a(86087),i=a(83203),c=r(a(33170)),u=a(64116),d=a(10790);const v="Enter",p=" ",m=({activeElements:e,filterInView:t,filter:a})=>{if(void 0===e||0===e.length)return a.name;const r={Name:(0,d.jsx)("span",{className:"dataviews-filters__summary-filter-text-name"}),Value:(0,d.jsx)("span",{className:"dataviews-filters__summary-filter-text-value"})};return t?.operator===u.OPERATOR_IS_ANY?(0,s.createInterpolateElement)((0,l.sprintf)(/* translators: 1: Filter name. 3: Filter value. e.g.: "Author is any: Admin, Editor". */ /* translators: 1: Filter name. 3: Filter value. e.g.: "Author is any: Admin, Editor". */ -(0,l.__)("%1$s is any: %2$s","jetpack-my-jetpack"),a.name,e.map((e=>e.label)).join(", ")),r):t?.operator===u.OPERATOR_IS_NONE?(0,s.createInterpolateElement)((0,l.sprintf)(/* translators: 1: Filter name. 3: Filter value. e.g.: "Author is none: Admin, Editor". */ /* translators: 1: Filter name. 3: Filter value. e.g.: "Author is none: Admin, Editor". */ -(0,l.__)("%1$s is none: %2$s","jetpack-my-jetpack"),a.name,e.map((e=>e.label)).join(", ")),r):t?.operator===u.OPERATOR_IS_ALL?(0,s.createInterpolateElement)((0,l.sprintf)(/* translators: 1: Filter name. 3: Filter value. e.g.: "Author is all: Admin, Editor". */ /* translators: 1: Filter name. 3: Filter value. e.g.: "Author is all: Admin, Editor". */ -(0,l.__)("%1$s is all: %2$s","jetpack-my-jetpack"),a.name,e.map((e=>e.label)).join(", ")),r):t?.operator===u.OPERATOR_IS_NOT_ALL?(0,s.createInterpolateElement)((0,l.sprintf)(/* translators: 1: Filter name. 3: Filter value. e.g.: "Author is not all: Admin, Editor". */ /* translators: 1: Filter name. 3: Filter value. e.g.: "Author is not all: Admin, Editor". */ -(0,l.__)("%1$s is not all: %2$s","jetpack-my-jetpack"),a.name,e.map((e=>e.label)).join(", ")),r):t?.operator===u.OPERATOR_IS?(0,s.createInterpolateElement)((0,l.sprintf)(/* translators: 1: Filter name. 3: Filter value. e.g.: "Author is: Admin". */ /* translators: 1: Filter name. 3: Filter value. e.g.: "Author is: Admin". */ -(0,l.__)("%1$s is: %2$s","jetpack-my-jetpack"),a.name,e[0].label),r):t?.operator===u.OPERATOR_IS_NOT?(0,s.createInterpolateElement)((0,l.sprintf)(/* translators: 1: Filter name. 3: Filter value. e.g.: "Author is not: Admin". */ /* translators: 1: Filter name. 3: Filter value. e.g.: "Author is not: Admin". */ -(0,l.__)("%1$s is not: %2$s","jetpack-my-jetpack"),a.name,e[0].label),r):(0,l.sprintf)(/* translators: 1: Filter name e.g.: "Unknown status for Author". */ /* translators: 1: Filter name e.g.: "Unknown status for Author". */ -(0,l.__)("Unknown status for %1$s","jetpack-my-jetpack"),a.name)};function h({filter:e,view:t,onChangeView:a}){const r=e.operators?.map((e=>({value:e,label:u.OPERATORS[e]?.label}))),o=t.filters?.find((t=>t.field===e.field)),s=o?.operator||e.operators[0];return r.length>1&&(0,d.jsxs)(n.__experimentalHStack,{spacing:2,justify:"flex-start",className:"dataviews-filters__summary-operators-container",children:[(0,d.jsx)(n.FlexItem,{className:"dataviews-filters__summary-operators-filter-name",children:e.name}),(0,d.jsx)(n.SelectControl,{label:(0,l.__)("Conditions","jetpack-my-jetpack"),value:s,options:r,onChange:r=>{var n,l;const s=r,i=o?[...(null!==(n=t.filters)&&void 0!==n?n:[]).map((t=>t.field===e.field?{...t,operator:s}:t))]:[...null!==(l=t.filters)&&void 0!==l?l:[],{field:e.field,operator:s,value:void 0}];a({...t,page:1,filters:i})},size:"small",__nextHasNoMarginBottom:!0,hideLabelFromVision:!0})]})}},2957:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.FiltersToggle=function({filters:e,view:t,onChangeView:a,setOpenedFilter:r,isShowingFilter:i,setIsShowingFilter:u}){const d=(0,o.useRef)(null),v=(0,o.useCallback)((e=>{a(e),u(!0)}),[a,u]),p=!!e.filter((e=>e.isVisible)).length;if(0===e.length)return null;const h={label:(0,s.__)("Add filter","jetpack-my-jetpack"),"aria-expanded":!1,isPressed:!1},f={label:(0,s._x)("Filter","verb","jetpack-my-jetpack"),"aria-expanded":i,isPressed:i,onClick:()=>{i||r(null),u(!i)}},w=(0,m.jsx)(n.Button,{ref:d,className:"dataviews-filters__visibility-toggle",size:"compact",icon:l.funnel,...p?f:h});return(0,m.jsx)("div",{className:"dataviews-filters__container-visibility-toggle",children:p?(0,m.jsx)(g,{buttonRef:d,filtersCount:t.filters?.length,children:w}):(0,m.jsx)(c.AddFilterMenu,{filters:e,view:t,onChangeView:v,setOpenedFilter:r,triggerProps:{render:w}})})},t.default=void 0,t.useFilters=f;var o=a(86087),n=a(56427),l=a(83203),s=a(27723),i=r(a(33162)),c=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=h(t);if(a&&a.has(e))return a.get(e);var r={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in e)if("default"!==n&&{}.hasOwnProperty.call(e,n)){var l=o?Object.getOwnPropertyDescriptor(e,n):null;l&&(l.get||l.set)?Object.defineProperty(r,n,l):r[n]=e[n]}return r.default=e,a&&a.set(e,r),r}(a(18645)),u=r(a(53196)),d=r(a(60789)),v=a(7912),p=a(64116),m=a(10790);function h(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,a=new WeakMap;return(h=function(e){return e?a:t})(e)}function f(e,t){return(0,o.useMemo)((()=>{const a=[];return e.forEach((e=>{if(!e.elements?.length)return;const r=(0,v.sanitizeOperators)(e);if(0===r.length)return;const o=!!e.filterBy?.isPrimary;a.push({field:e.id,name:e.label,elements:e.elements,singleSelection:r.some((e=>[p.OPERATOR_IS,p.OPERATOR_IS_NOT].includes(e))),operators:r,isVisible:o||!!t.filters?.some((t=>t.field===e.id&&p.ALL_OPERATORS.includes(t.operator))),isPrimary:o})})),a.sort(((e,t)=>e.isPrimary&&!t.isPrimary?-1:!e.isPrimary&&t.isPrimary?1:e.name.localeCompare(t.name))),a}),[e,t])}function g({buttonRef:e,filtersCount:t,children:a}){return(0,o.useEffect)((()=>()=>{e.current?.focus()}),[e]),(0,m.jsxs)(m.Fragment,{children:[a,!!t&&(0,m.jsx)("span",{className:"dataviews-filters-toggle__count",children:t})]})}t.default=(0,o.memo)((function(){const{fields:e,view:t,onChangeView:a,openedFilter:r,setOpenedFilter:l}=(0,o.useContext)(d.default),s=(0,o.useRef)(null),v=f(e,t),p=(0,m.jsx)(c.default,{filters:v,view:t,onChangeView:a,ref:s,setOpenedFilter:l},"add-filter"),h=v.filter((e=>e.isVisible));if(0===h.length)return null;const g=[...h.map((e=>(0,m.jsx)(i.default,{filter:e,view:t,onChangeView:a,addFilterRef:s,openedFilter:r},e.field))),p];return g.push((0,m.jsx)(u.default,{filters:v,view:t,onChangeView:a},"reset-filters")),(0,m.jsx)(n.__experimentalHStack,{justify:"flex-start",style:{width:"fit-content"},className:"dataviews-filters__container",wrap:!0,children:g})}))},53196:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({filters:e,view:t,onChangeView:a}){const l=!t.search&&!t.filters?.some((t=>{return void 0!==t.value||(a=t.field,!e.some((e=>e.field===a&&e.isPrimary)));var a}));return(0,n.jsx)(r.Button,{disabled:l,accessibleWhenDisabled:!0,size:"compact",variant:"tertiary",className:"dataviews-filters__reset-button",onClick:()=>{a({...t,page:1,search:"",filters:[]})},children:(0,o.__)("Reset","jetpack-my-jetpack")})};var r=a(56427),o=a(27723),n=a(10790)},33170:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){const t=e.filter.elements.length>10?x:y;return(0,v.jsx)(t,{...e})};var o=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=p(t);if(a&&a.has(e))return a.get(e);var r={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in e)if("default"!==n&&{}.hasOwnProperty.call(e,n)){var l=o?Object.getOwnPropertyDescriptor(e,n):null;l&&(l.get||l.set)?Object.defineProperty(r,n,l):r[n]=e[n]}return r.default=e,a&&a.set(e,r),r}(a(94083)),n=r(a(44775)),l=a(29491),s=a(27723),i=a(86087),c=a(56427),u=a(83203),d=a(5573),v=a(10790);function p(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,a=new WeakMap;return(p=function(e){return e?a:t})(e)}const m=(0,v.jsx)(d.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",children:(0,v.jsx)(d.Circle,{cx:12,cy:12,r:3})});function h(e=""){return(0,n.default)(e.trim().toLowerCase())}const f=[],g=(e,t)=>e.singleSelection?t?.value:Array.isArray(t?.value)?t.value:!Array.isArray(t?.value)&&t?.value?[t.value]:f,w=(e,t,a)=>e.singleSelection?a:Array.isArray(t?.value)?t.value.includes(a)?t.value.filter((e=>e!==a)):[...t.value,a]:[a];function b(e,t){return`${e}-${t}`}function y({view:e,filter:t,onChangeView:a}){const r=(0,l.useInstanceId)(y,"dataviews-filter-list-box"),[o,n]=(0,i.useState)(1===t.operators?.length?void 0:null),d=e.filters?.find((e=>e.field===t.field)),p=g(t,d);return(0,v.jsx)(c.Composite,{virtualFocus:!0,focusLoop:!0,activeId:o,setActiveId:n,role:"listbox",className:"dataviews-filters__search-widget-listbox","aria-label":(0,s.sprintf)(/* translators: List of items for a filter. 1: Filter name. e.g.: "List of: Author". */ /* translators: List of items for a filter. 1: Filter name. e.g.: "List of: Author". */ -(0,s.__)("List of: %1$s","jetpack-my-jetpack"),t.name),onFocusVisible:()=>{!o&&t.elements.length&&n(b(r,t.elements[0].value))},render:(0,v.jsx)(c.Composite.Typeahead,{}),children:t.elements.map((o=>(0,v.jsxs)(c.Composite.Hover,{render:(0,v.jsx)(c.Composite.Item,{id:b(r,o.value),render:(0,v.jsx)("div",{"aria-label":o.label,role:"option",className:"dataviews-filters__search-widget-listitem"}),onClick:()=>{var r,n;const l=d?[...(null!==(r=e.filters)&&void 0!==r?r:[]).map((e=>e.field===t.field?{...e,operator:d.operator||t.operators[0],value:w(t,d,o.value)}:e))]:[...null!==(n=e.filters)&&void 0!==n?n:[],{field:t.field,operator:t.operators[0],value:w(t,d,o.value)}];a({...e,page:1,filters:l})}}),children:[(0,v.jsxs)("span",{className:"dataviews-filters__search-widget-listitem-check",children:[t.singleSelection&&p===o.value&&(0,v.jsx)(c.Icon,{icon:m}),!t.singleSelection&&p.includes(o.value)&&(0,v.jsx)(c.Icon,{icon:u.check})]}),(0,v.jsx)("span",{children:o.label})]},o.value)))})}function x({view:e,filter:t,onChangeView:a}){const[r,n]=(0,i.useState)(""),l=(0,i.useDeferredValue)(r),d=e.filters?.find((e=>e.field===t.field)),p=g(t,d),f=(0,i.useMemo)((()=>{const e=h(l);return t.elements.filter((t=>h(t.label).includes(e)))}),[t.elements,l]);return(0,v.jsxs)(o.ComboboxProvider,{selectedValue:p,setSelectedValue:r=>{var o,n;const l=d?[...(null!==(o=e.filters)&&void 0!==o?o:[]).map((e=>e.field===t.field?{...e,operator:d.operator||t.operators[0],value:r}:e))]:[...null!==(n=e.filters)&&void 0!==n?n:[],{field:t.field,operator:t.operators[0],value:r}];a({...e,page:1,filters:l})},setValue:n,children:[(0,v.jsxs)("div",{className:"dataviews-filters__search-widget-filter-combobox__wrapper",children:[(0,v.jsx)(o.ComboboxLabel,{render:(0,v.jsx)(c.VisuallyHidden,{children:(0,s.__)("Search items","jetpack-my-jetpack")}),children:(0,s.__)("Search items","jetpack-my-jetpack")}),(0,v.jsx)(o.Combobox,{autoSelect:"always",placeholder:(0,s.__)("Search","jetpack-my-jetpack"),className:"dataviews-filters__search-widget-filter-combobox__input"}),(0,v.jsx)("div",{className:"dataviews-filters__search-widget-filter-combobox__icon",children:(0,v.jsx)(c.Icon,{icon:u.search})})]}),(0,v.jsxs)(o.ComboboxList,{className:"dataviews-filters__search-widget-filter-combobox-list",alwaysVisible:!0,children:[f.map((e=>(0,v.jsxs)(o.ComboboxItem,{resetValueOnSelect:!1,value:e.value,className:"dataviews-filters__search-widget-listitem",hideOnClick:!1,setValueOnClick:!1,focusOnHover:!0,children:[(0,v.jsxs)("span",{className:"dataviews-filters__search-widget-listitem-check",children:[t.singleSelection&&p===e.value&&(0,v.jsx)(c.Icon,{icon:m}),!t.singleSelection&&p.includes(e.value)&&(0,v.jsx)(c.Icon,{icon:u.check})]}),(0,v.jsxs)("span",{children:[(0,v.jsx)(o.ComboboxItemValue,{className:"dataviews-filters__search-widget-filter-combobox-item-value",value:e.label}),!!e.description&&(0,v.jsx)("span",{className:"dataviews-filters__search-widget-listitem-description",children:e.description})]})]},e.value))),!f.length&&(0,v.jsx)("p",{children:(0,s.__)("No results found","jetpack-my-jetpack")})]})]})}},77493:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){const{view:e,paginationInfo:{totalItems:t=0,totalPages:a},data:r,actions:v=d}=(0,n.useContext)(l.default),p=(0,i.useSomeItemHasAPossibleBulkAction)(v,r)&&[c.LAYOUT_TABLE,c.LAYOUT_GRID].includes(e.type);if(!t||!a||a<=1&&!p)return null;return!!t&&(0,u.jsxs)(o.__experimentalHStack,{expanded:!1,justify:"end",className:"dataviews-footer",children:[p&&(0,u.jsx)(i.BulkActionsFooter,{}),(0,u.jsx)(s.default,{})]})};var o=a(56427),n=a(86087),l=r(a(60789)),s=r(a(80382)),i=a(10192),c=a(64116),u=a(10790);const d=[]},97867:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ActionModal=m,t.ActionsMenuGroup=h,t.default=function({item:e,actions:t,isCompact:a}){const o=(0,s.useRegistry)(),{primaryActions:l,eligibleActions:i}=(0,n.useMemo)((()=>{const a=t.filter((t=>!t.isEligible||t.isEligible(e)));return{primaryActions:a.filter((e=>e.isPrimary&&!!e.icon)),eligibleActions:a}}),[t,e]);if(a)return(0,c.jsx)(f,{item:e,actions:i,isSmall:!0,registry:o});if(l.length===i.length)return(0,c.jsx)(g,{item:e,actions:l,registry:o});return(0,c.jsxs)(r.__experimentalHStack,{spacing:1,justify:"flex-end",className:"dataviews-item-actions",style:{flexShrink:"0",width:"auto"},children:[(0,c.jsx)(g,{item:e,actions:l,registry:o}),(0,c.jsx)(f,{item:e,actions:i,registry:o})]})};var r=a(56427),o=a(27723),n=a(86087),l=a(83203),s=a(47143),i=a(40191),c=a(10790);const{Menu:u,kebabCase:d}=(0,i.unlock)(r.privateApis);function v({action:e,onClick:t,items:a}){const o="string"==typeof e.label?e.label:e.label(a);return(0,c.jsx)(r.Button,{label:o,icon:e.icon,disabled:!!e.disabled,accessibleWhenDisabled:!0,isDestructive:e.isDestructive,size:"compact",onClick:t})}function p({action:e,onClick:t,items:a}){const r="string"==typeof e.label?e.label:e.label(a);return(0,c.jsx)(u.Item,{disabled:e.disabled,onClick:t,children:(0,c.jsx)(u.ItemLabel,{children:r})})}function m({action:e,items:t,closeModal:a}){const o="string"==typeof e.label?e.label:e.label(t);return(0,c.jsx)(r.Modal,{title:e.modalHeader||o,__experimentalHideHeader:!!e.hideModalHeader,onRequestClose:a,focusOnMount:"firstContentElement",size:"medium",overlayClassName:`dataviews-action-modal dataviews-action-modal__${d(e.id)}`,children:(0,c.jsx)(e.RenderModal,{items:t,closeModal:a})})}function h({actions:e,item:t,registry:a,setActiveModalAction:r}){return(0,c.jsx)(u.Group,{children:e.map((e=>(0,c.jsx)(p,{action:e,onClick:()=>{"RenderModal"in e?r(e):e.callback([t],{registry:a})},items:[t]},e.id)))})}function f({item:e,actions:t,isSmall:a,registry:s}){const[i,d]=(0,n.useState)(null);return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsxs)(u,{placement:"bottom-end",children:[(0,c.jsx)(u.TriggerButton,{render:(0,c.jsx)(r.Button,{size:a?"small":"compact",icon:l.moreVertical,label:(0,o.__)("Actions","jetpack-my-jetpack"),accessibleWhenDisabled:!0,disabled:!t.length,className:"dataviews-all-actions-button"})}),(0,c.jsx)(u.Popover,{children:(0,c.jsx)(h,{actions:t,item:e,registry:s,setActiveModalAction:d})})]}),!!i&&(0,c.jsx)(m,{action:i,items:[e],closeModal:()=>d(null)})]})}function g({item:e,actions:t,registry:a}){const[r,o]=(0,n.useState)(null);return Array.isArray(t)&&0!==t.length?(0,c.jsxs)(c.Fragment,{children:[t.map((t=>(0,c.jsx)(v,{action:t,onClick:()=>{"RenderModal"in t?o(t):t.callback([e],{registry:a})},items:[e]},t.id))),!!r&&(0,c.jsx)(m,{action:r,items:[e],closeModal:()=>o(null)})]}):null}},95284:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){const{actions:e=[],data:t,fields:a,getItemId:r,getItemLevel:i,isLoading:c,view:u,onChangeView:d,selection:v,onChangeSelection:p,setOpenedFilter:m,onClickItem:h,isItemClickable:f}=(0,o.useContext)(n.default),g=l.VIEW_LAYOUTS.find((e=>e.type===u.type))?.component;return(0,s.jsx)(g,{actions:e,data:t,fields:a,getItemId:r,getItemLevel:i,isLoading:c,onChangeView:d,onChangeSelection:p,selection:v,setOpenedFilter:m,onClickItem:h,isItemClickable:f,view:u})};var o=a(86087),n=r(a(60789)),l=a(9322),s=a(10790)},80382:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(56427),n=a(86087),l=a(27723),s=a(83203),i=r(a(60789)),c=a(10790);t.default=(0,n.memo)((function(){var e;const{view:t,onChangeView:a,paginationInfo:{totalItems:r=0,totalPages:u}}=(0,n.useContext)(i.default);if(!r||!u)return null;const d=null!==(e=t.page)&&void 0!==e?e:1,v=Array.from(Array(u)).map(((e,t)=>{const a=t+1;return{value:a.toString(),label:a.toString(),"aria-label":d===a?(0,l.sprintf)( -// translators: Current page number in total number of pages -// translators: Current page number in total number of pages -(0,l.__)("Page %1$s of %2$s","jetpack-my-jetpack"),d,u):a.toString()}}));return!!r&&1!==u&&(0,c.jsxs)(o.__experimentalHStack,{expanded:!1,className:"dataviews-pagination",justify:"end",spacing:6,children:[(0,c.jsx)(o.__experimentalHStack,{justify:"flex-start",expanded:!1,spacing:1,className:"dataviews-pagination__page-select",children:(0,n.createInterpolateElement)((0,l.sprintf)( -// translators: 1: Current page number, 2: Total number of pages. -// translators: 1: Current page number, 2: Total number of pages. -(0,l._x)("

            Page
            %1$s
            of %2$s
            ","paging","jetpack-my-jetpack"),"",u),{div:(0,c.jsx)("div",{"aria-hidden":!0}),CurrentPage:(0,c.jsx)(o.SelectControl,{"aria-label":(0,l.__)("Current page","jetpack-my-jetpack"),value:d.toString(),options:v,onChange:e=>{a({...t,page:+e})},size:"small",__nextHasNoMarginBottom:!0,variant:"minimal"})})}),(0,c.jsxs)(o.__experimentalHStack,{expanded:!1,spacing:1,children:[(0,c.jsx)(o.Button,{onClick:()=>a({...t,page:d-1}),disabled:1===d,accessibleWhenDisabled:!0,label:(0,l.__)("Previous page","jetpack-my-jetpack"),icon:(0,l.isRTL)()?s.next:s.previous,showTooltip:!0,size:"compact",tooltipPosition:"top"}),(0,c.jsx)(o.Button,{onClick:()=>a({...t,page:d+1}),disabled:d>=u,accessibleWhenDisabled:!0,label:(0,l.__)("Next page","jetpack-my-jetpack"),icon:(0,l.isRTL)()?s.previous:s.next,showTooltip:!0,size:"compact",tooltipPosition:"top"})]})]})}))},36310:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(27723),n=a(86087),l=a(56427),s=a(29491),i=r(a(60789)),c=a(10790);const u=(0,n.memo)((function({label:e}){const{view:t,onChangeView:a}=(0,n.useContext)(i.default),[r,u,d]=(0,s.useDebouncedInput)(t.search);(0,n.useEffect)((()=>{var e;u(null!==(e=t.search)&&void 0!==e?e:"")}),[t.search,u]);const v=(0,n.useRef)(a),p=(0,n.useRef)(t);(0,n.useEffect)((()=>{v.current=a,p.current=t}),[a,t]),(0,n.useEffect)((()=>{d!==p.current?.search&&v.current({...p.current,page:1,search:d})}),[d]);const m=e||(0,o.__)("Search","jetpack-my-jetpack");return(0,c.jsx)(l.SearchControl,{className:"dataviews-search",__nextHasNoMarginBottom:!0,onChange:u,value:r,label:m,placeholder:m,size:"compact"})}));t.default=u},10086:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({selection:e,onChangeSelection:t,item:a,getItemId:l,titleField:s,disabled:i}){const c=l(a),u=!i&&e.includes(c),d=s?.getValue?.({item:a})||(0,o.__)("(no title)","jetpack-my-jetpack");return(0,n.jsx)(r.CheckboxControl,{className:"dataviews-selection-checkbox",__nextHasNoMarginBottom:!0,"aria-label":d,"aria-disabled":i,checked:u,onChange:()=>{i||t(e.includes(c)?e.filter((e=>c!==e)):[...e,c])}})};var r=a(56427),o=a(27723),n=a(10790)},67724:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(a(33752)),n=a(56427),l=a(27723),s=a(86087),i=a(83203),c=r(a(10979)),u=a(29491),d=a(64116),v=a(9322),p=r(a(60789)),m=a(40191),h=a(10790);const{Menu:f}=(0,m.unlock)(n.privateApis),g={className:"dataviews-config__popover",placement:"bottom-end",offset:9};function w({defaultLayouts:e={list:{},grid:{},table:{}}}){const{view:t,onChangeView:a}=(0,s.useContext)(p.default),r=Object.keys(e);if(r.length<=1)return null;const o=v.VIEW_LAYOUTS.find((e=>t.type===e.type));return(0,h.jsxs)(f,{children:[(0,h.jsx)(f.TriggerButton,{render:(0,h.jsx)(n.Button,{size:"compact",icon:o?.icon,label:(0,l.__)("Layout","jetpack-my-jetpack")})}),(0,h.jsx)(f.Popover,{children:r.map((r=>{const o=v.VIEW_LAYOUTS.find((e=>e.type===r));return o?(0,h.jsx)(f.RadioItem,{value:r,name:"view-actions-available-view",checked:r===t.type,hideOnClick:!0,onChange:r=>{switch(r.target.value){case"list":case"grid":case"table":const o={...t};return"layout"in o&&delete o.layout,a({...o,type:r.target.value,...e[r.target.value]})}!0===globalThis.SCRIPT_DEBUG&&(0,c.default)("Invalid dataview")},children:(0,h.jsx)(f.ItemLabel,{children:o.label})},r):null}))})]})}function b(){const{view:e,fields:t,onChangeView:a}=(0,s.useContext)(p.default),r=(0,s.useMemo)((()=>t.filter((e=>!1!==e.enableSorting)).map((e=>({label:e.label,value:e.id})))),[t]);return(0,h.jsx)(n.SelectControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,label:(0,l.__)("Sort by","jetpack-my-jetpack"),value:e.sort?.field,options:r,onChange:t=>{a({...e,sort:{direction:e?.sort?.direction||"desc",field:t},showLevels:!1})}})}function y(){const{view:e,fields:t,onChangeView:a}=(0,s.useContext)(p.default);if(0===t.filter((e=>!1!==e.enableSorting)).length)return null;let r=e.sort?.direction;return!r&&e.sort?.field&&(r="desc"),(0,h.jsx)(n.__experimentalToggleGroupControl,{className:"dataviews-view-config__sort-direction",__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,isBlock:!0,label:(0,l.__)("Order","jetpack-my-jetpack"),value:r,onChange:r=>{"asc"!==r&&"desc"!==r?!0===globalThis.SCRIPT_DEBUG&&(0,c.default)("Invalid direction"):a({...e,sort:{direction:r,field:e.sort?.field||t.find((e=>!1!==e.enableSorting))?.id||""},showLevels:!1})},children:d.SORTING_DIRECTIONS.map((e=>(0,h.jsx)(n.__experimentalToggleGroupControlOptionIcon,{value:e,icon:d.sortIcons[e],label:d.sortLabels[e]},e)))})}const x=[10,20,50,100];function _(){const{view:e,onChangeView:t}=(0,s.useContext)(p.default);return(0,h.jsx)(n.__experimentalToggleGroupControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,isBlock:!0,label:(0,l.__)("Items per page","jetpack-my-jetpack"),value:e.perPage||10,disabled:!e?.sort?.field,onChange:a=>{const r="number"==typeof a||void 0===a?a:parseInt(a,10);t({...e,perPage:r,page:1})},children:x.map((e=>(0,h.jsx)(n.__experimentalToggleGroupControlOption,{value:e,label:e.toString()},e)))})}function k({previewOptions:e,onChangePreviewOption:t,onMenuOpenChange:a,activeOption:r}){return(0,h.jsxs)(f,{onOpenChange:a,children:[(0,h.jsx)(f.TriggerButton,{render:(0,h.jsx)(n.Button,{className:"dataviews-field-control__field-preview-options-button",size:"compact",icon:i.moreVertical,label:(0,l.__)("Preview","jetpack-my-jetpack")})}),(0,h.jsx)(f.Popover,{children:e?.map((({id:e,label:a})=>(0,h.jsx)(f.RadioItem,{value:e,checked:e===r,onChange:()=>{t?.(e),(e=>{setTimeout((()=>{const t=document.querySelector(`.dataviews-field-control__field-${e} .dataviews-field-control__field-preview-options-button`);t instanceof HTMLElement&&t.focus()}),50)})(e)},children:(0,h.jsx)(f.ItemLabel,{children:a})},e)))})]})}function E({field:e,label:t,description:a,isVisible:r,isFirst:c,isLast:u,canMove:d=!0,onToggleVisibility:v,onMoveUp:p,onMoveDown:m,previewOptions:f,onChangePreviewOption:g}){const[w,b]=(0,s.useState)(!1);return(0,h.jsx)(n.__experimentalItem,{children:(0,h.jsxs)(n.__experimentalHStack,{expanded:!0,className:(0,o.default)("dataviews-field-control__field",`dataviews-field-control__field-${e.id}`,{"is-interacting":w}),justify:"flex-start",children:[(0,h.jsx)("span",{className:"dataviews-field-control__icon",children:!d&&!e.enableHiding&&(0,h.jsx)(n.Icon,{icon:i.lock})}),(0,h.jsxs)("span",{className:"dataviews-field-control__label-sub-label-container",children:[(0,h.jsx)("span",{className:"dataviews-field-control__label",children:t||e.label}),a&&(0,h.jsx)("span",{className:"dataviews-field-control__sub-label",children:a})]}),(0,h.jsxs)(n.__experimentalHStack,{justify:"flex-end",expanded:!1,className:"dataviews-field-control__actions",children:[r&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(n.Button,{disabled:c||!d,accessibleWhenDisabled:!0,size:"compact",onClick:p,icon:i.chevronUp,label:c||!d?(0,l.__)("This field can't be moved up","jetpack-my-jetpack"):(0,l.sprintf)(/* translators: %s: field label */ /* translators: %s: field label */ -(0,l.__)("Move %s up","jetpack-my-jetpack"),e.label)}),(0,h.jsx)(n.Button,{disabled:u||!d,accessibleWhenDisabled:!0,size:"compact",onClick:m,icon:i.chevronDown,label:u||!d?(0,l.__)("This field can't be moved down","jetpack-my-jetpack"):(0,l.sprintf)(/* translators: %s: field label */ /* translators: %s: field label */ -(0,l.__)("Move %s down","jetpack-my-jetpack"),e.label)})]}),v&&(0,h.jsx)(n.Button,{className:"dataviews-field-control__field-visibility-button",disabled:!e.enableHiding,accessibleWhenDisabled:!0,size:"compact",onClick:()=>{v(),setTimeout((()=>{const t=document.querySelector(`.dataviews-field-control__field-${e.id} .dataviews-field-control__field-visibility-button`);t instanceof HTMLElement&&t.focus()}),50)},icon:r?i.unseen:i.seen,label:r?(0,l.sprintf)(/* translators: %s: field label */ /* translators: %s: field label */ -(0,l._x)("Hide %s","field","jetpack-my-jetpack"),e.label):(0,l.sprintf)(/* translators: %s: field label */ /* translators: %s: field label */ -(0,l._x)("Show %s","field","jetpack-my-jetpack"),e.label)}),f&&(0,h.jsx)(k,{previewOptions:f,onChangePreviewOption:g,onMenuOpenChange:b,activeOption:e.id})]})]})})}function C({index:e,field:t,view:a,onChangeView:r}){var o;const n=null!==(o=a.fields)&&void 0!==o?o:[],l=void 0!==e&&n.includes(t.id);return(0,h.jsx)(E,{field:t,isVisible:l,isFirst:void 0!==e&&e<1,isLast:void 0!==e&&e===n.length-1,onToggleVisibility:()=>{r({...a,fields:l?n.filter((e=>e!==t.id)):[...n,t.id]})},onMoveUp:void 0!==e?()=>{var o;r({...a,fields:[...null!==(o=n.slice(0,e-1))&&void 0!==o?o:[],t.id,n[e-1],...n.slice(e+1)]})}:void 0,onMoveDown:void 0!==e?()=>{var o;r({...a,fields:[...null!==(o=n.slice(0,e))&&void 0!==o?o:[],n[e+1],t.id,...n.slice(e+2)]})}:void 0})}function j(e){return!!e}function A(){var e;const{view:t,fields:a,onChangeView:r}=(0,s.useContext)(p.default),o=[t?.titleField,t?.mediaField,t?.descriptionField].filter(Boolean),i=null!==(e=t.fields)&&void 0!==e?e:[],c=a.filter((e=>!i.includes(e.id)&&!o.includes(e.id)&&"media"!==e.type)),u=i.map((e=>a.find((t=>t.id===e)))).filter(j);if(!u?.length&&!c?.length)return null;const d=a.find((e=>e.id===t.titleField)),v=a.find((e=>e.id===t.mediaField)),m=a.find((e=>e.id===t.descriptionField)),f=a.filter((e=>"media"===e.type));let g;if(f.length>1){var w;const e=j(v)&&(null===(w=t.showMedia)||void 0===w||w);g=j(v)&&(0,h.jsx)(E,{field:v,label:(0,l.__)("Preview","jetpack-my-jetpack"),description:v.label,isVisible:e,onToggleVisibility:()=>{r({...t,showMedia:!e})},canMove:!1,previewOptions:f.map((e=>({label:e.label,id:e.id}))),onChangePreviewOption:e=>r({...t,mediaField:e})},v.id)}const b=[{field:d,isVisibleFlag:"showTitle"},{field:v,isVisibleFlag:"showMedia",ui:g},{field:m,isVisibleFlag:"showDescription"}].filter((({field:e})=>j(e))),y=b.filter((({field:e,isVisibleFlag:a})=>{var r;return j(e)&&(null===(r=t[a])||void 0===r||r)})),x=b.filter((({field:e,isVisibleFlag:a})=>{var r;return j(e)&&!(null===(r=t[a])||void 0===r||r)}));return(0,h.jsxs)(n.__experimentalVStack,{className:"dataviews-field-control",spacing:6,children:[(0,h.jsx)(n.__experimentalVStack,{className:"dataviews-view-config__properties",spacing:0,children:(y.length>0||!!u?.length)&&(0,h.jsxs)(n.__experimentalItemGroup,{isBordered:!0,isSeparated:!0,children:[y.map((({field:e,isVisibleFlag:a,ui:o})=>null!=o?o:(0,h.jsx)(E,{field:e,isVisible:!0,onToggleVisibility:()=>{r({...t,[a]:!1})},canMove:!1},e.id))),u.map(((e,a)=>(0,h.jsx)(C,{field:e,view:t,onChangeView:r,index:a},e.id)))]})}),(!!c?.length||!!x.length)&&(0,h.jsxs)(n.__experimentalVStack,{spacing:4,children:[(0,h.jsx)(n.BaseControl.VisualLabel,{style:{margin:0},children:(0,l.__)("Hidden","jetpack-my-jetpack")}),(0,h.jsx)(n.__experimentalVStack,{className:"dataviews-view-config__properties",spacing:0,children:(0,h.jsxs)(n.__experimentalItemGroup,{isBordered:!0,isSeparated:!0,children:[x.length>0&&x.map((({field:e,isVisibleFlag:a,ui:o})=>null!=o?o:(0,h.jsx)(E,{field:e,isVisible:!1,onToggleVisibility:()=>{r({...t,[a]:!0})},canMove:!1},e.id))),c.map((e=>(0,h.jsx)(C,{field:e,view:t,onChangeView:r},e.id)))]})})]})]})}function S({title:e,description:t,children:a}){return(0,h.jsxs)(n.__experimentalGrid,{columns:12,className:"dataviews-settings-section",gap:4,children:[(0,h.jsxs)("div",{className:"dataviews-settings-section__sidebar",children:[(0,h.jsx)(n.__experimentalHeading,{level:2,className:"dataviews-settings-section__title",children:e}),t&&(0,h.jsx)(n.__experimentalText,{variant:"muted",className:"dataviews-settings-section__description",children:t})]}),(0,h.jsx)(n.__experimentalGrid,{columns:8,gap:4,className:"dataviews-settings-section__content",children:a})]})}function P(){const{view:e}=(0,s.useContext)(p.default),t=(0,u.useInstanceId)(R,"dataviews-view-config-dropdown"),a=v.VIEW_LAYOUTS.find((t=>t.type===e.type));return(0,h.jsx)(n.Dropdown,{expandOnMobile:!0,popoverProps:{...g,id:t},renderToggle:({onToggle:e,isOpen:a})=>(0,h.jsx)(n.Button,{size:"compact",icon:i.cog,label:(0,l._x)("View options","View is used as a noun","jetpack-my-jetpack"),onClick:e,"aria-expanded":a?"true":"false","aria-controls":t}),renderContent:()=>(0,h.jsx)(n.__experimentalDropdownContentWrapper,{paddingSize:"medium",className:"dataviews-config__popover-content-wrapper",children:(0,h.jsxs)(n.__experimentalVStack,{className:"dataviews-view-config",spacing:6,children:[(0,h.jsxs)(S,{title:(0,l.__)("Appearance","jetpack-my-jetpack"),children:[(0,h.jsxs)(n.__experimentalHStack,{expanded:!0,className:"is-divided-in-two",children:[(0,h.jsx)(b,{}),(0,h.jsx)(y,{})]}),!!a?.viewConfigOptions&&(0,h.jsx)(a.viewConfigOptions,{}),(0,h.jsx)(_,{})]}),(0,h.jsx)(S,{title:(0,l.__)("Properties","jetpack-my-jetpack"),children:(0,h.jsx)(A,{})})]})})})}function R({defaultLayouts:e={list:{},grid:{},table:{}}}){return(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)(w,{defaultLayouts:e}),(0,h.jsx)(P,{})]})}const M=(0,s.memo)(R);t.default=M},67807:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({view:e,onChangeView:t,fields:a,search:r=!0,searchLabel:h,actions:b=w,data:y,getItemId:x=f,getItemLevel:_,isLoading:k=!1,paginationInfo:E,defaultLayouts:C,selection:j,onChangeSelection:A,onClickItem:S,isItemClickable:P=g,header:R}){const[M,V]=(0,n.useState)(0),z=(0,l.useResizeObserver)((e=>{V(e[0].borderBoxSize[0].inlineSize)}),{box:"border-box"}),[H,L]=(0,n.useState)([]),O=void 0===j||void 0===A,N=O?H:j,[I,B]=(0,n.useState)(null);const T=(0,n.useMemo)((()=>(0,p.normalizeFields)(a)),[a]),F=(0,n.useMemo)((()=>N.filter((e=>y.some((t=>x(t)===e))))),[N,y,x]),D=(0,i.useFilters)(T,e),[G,U]=(0,n.useState)((()=>(D||[]).some((e=>e.isPrimary))));return(0,m.jsx)(s.default.Provider,{value:{view:e,onChangeView:t,fields:T,actions:b,data:y,isLoading:k,paginationInfo:E,selection:F,onChangeSelection:function(e){const t="function"==typeof e?e(N):e;O&&L(t),A&&A(t)},openedFilter:I,setOpenedFilter:B,getItemId:x,getItemLevel:_,isItemClickable:P,onClickItem:S,containerWidth:M},children:(0,m.jsxs)("div",{className:"dataviews-wrapper",ref:z,children:[(0,m.jsxs)(o.__experimentalHStack,{alignment:"top",justify:"space-between",className:"dataviews__view-actions",spacing:1,children:[(0,m.jsxs)(o.__experimentalHStack,{justify:"start",expanded:!1,className:"dataviews__search",children:[r&&(0,m.jsx)(d.default,{label:h}),(0,m.jsx)(i.FiltersToggle,{filters:D,view:e,onChangeView:t,setOpenedFilter:B,setIsShowingFilter:U,isShowingFilter:G})]}),(0,m.jsxs)(o.__experimentalHStack,{spacing:1,expanded:!1,style:{flexShrink:0},children:[(0,m.jsx)(v.default,{defaultLayouts:C}),R]})]}),G&&(0,m.jsx)(i.default,{}),(0,m.jsx)(c.default,{}),(0,m.jsx)(u.default,{})]})})};var o=a(56427),n=a(86087),l=a(29491),s=r(a(60789)),i=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=h(t);if(a&&a.has(e))return a.get(e);var r={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in e)if("default"!==n&&{}.hasOwnProperty.call(e,n)){var l=o?Object.getOwnPropertyDescriptor(e,n):null;l&&(l.get||l.set)?Object.defineProperty(r,n,l):r[n]=e[n]}return r.default=e,a&&a.set(e,r),r}(a(2957)),c=r(a(95284)),u=r(a(77493)),d=r(a(36310)),v=r(a(67724)),p=a(53582),m=a(10790);function h(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,a=new WeakMap;return(h=function(e){return e?a:t})(e)}const f=e=>e.id,g=()=>!0,w=[]},64116:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sortValues=t.sortLabels=t.sortIcons=t.sortArrows=t.SORTING_DIRECTIONS=t.OPERATOR_IS_NOT_ALL=t.OPERATOR_IS_NOT=t.OPERATOR_IS_NONE=t.OPERATOR_IS_ANY=t.OPERATOR_IS_ALL=t.OPERATOR_IS=t.OPERATORS=t.LAYOUT_TABLE=t.LAYOUT_LIST=t.LAYOUT_GRID=t.ALL_OPERATORS=void 0;var r=a(27723),o=a(83203);const n=t.OPERATOR_IS="is",l=t.OPERATOR_IS_NOT="isNot",s=t.OPERATOR_IS_ANY="isAny",i=t.OPERATOR_IS_NONE="isNone",c=t.OPERATOR_IS_ALL="isAll",u=t.OPERATOR_IS_NOT_ALL="isNotAll";t.ALL_OPERATORS=[n,l,s,i,c,u],t.OPERATORS={[n]:{key:"is-filter",label:(0,r.__)("Is","jetpack-my-jetpack")},[l]:{key:"is-not-filter",label:(0,r.__)("Is not","jetpack-my-jetpack")},[s]:{key:"is-any-filter",label:(0,r.__)("Is any","jetpack-my-jetpack")},[i]:{key:"is-none-filter",label:(0,r.__)("Is none","jetpack-my-jetpack")},[c]:{key:"is-all-filter",label:(0,r.__)("Is all","jetpack-my-jetpack")},[u]:{key:"is-not-all-filter",label:(0,r.__)("Is not all","jetpack-my-jetpack")}},t.SORTING_DIRECTIONS=["asc","desc"],t.sortArrows={asc:"↑",desc:"↓"},t.sortValues={asc:"ascending",desc:"descending"},t.sortLabels={asc:(0,r.__)("Sort ascending","jetpack-my-jetpack"),desc:(0,r.__)("Sort descending","jetpack-my-jetpack")},t.sortIcons={asc:o.arrowUp,desc:o.arrowDown},t.LAYOUT_TABLE="table",t.LAYOUT_GRID="grid",t.LAYOUT_LIST="list"},61428:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a,hideLabelFromVision:l}){const{id:s,label:i}=t,c=t.getValue({item:e}),u=(0,o.useCallback)((e=>a({[s]:e})),[s,a]);return(0,n.jsxs)("fieldset",{className:"dataviews-controls__datetime",children:[!l&&(0,n.jsx)(r.BaseControl.VisualLabel,{as:"legend",children:i}),l&&(0,n.jsx)(r.VisuallyHidden,{as:"legend",children:i}),(0,n.jsx)(r.TimePicker,{currentTime:c,onChange:u,hideLabelFromVision:!0})]})};var r=a(56427),o=a(86087),n=a(10790)},70105:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.getControl=function(e,t){if("function"==typeof e.Edit)return e.Edit;if("string"==typeof e.Edit)return u(e.Edit);if(e.elements)return u("select");if("string"==typeof t.Edit)return u(t.Edit);return t.Edit},t.getControlByType=u;var o=r(a(61428)),n=r(a(91179)),l=r(a(45434)),s=r(a(15381)),i=r(a(78466));const c={datetime:o.default,integer:n.default,radio:l.default,select:s.default,text:i.default};function u(e){if(Object.keys(c).includes(e))return c[e];throw"Control "+e+" not found"}},91179:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a,hideLabelFromVision:l}){var s;const{id:i,label:c,description:u}=t,d=null!==(s=t.getValue({item:e}))&&void 0!==s?s:"",v=(0,o.useCallback)((e=>a({[i]:Number(e)})),[i,a]);return(0,n.jsx)(r.__experimentalNumberControl,{label:c,help:u,value:d,onChange:v,__next40pxDefaultSize:!0,hideLabelFromVision:l})};var r=a(56427),o=a(86087),n=a(10790)},45434:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a,hideLabelFromVision:l}){const{id:s,label:i}=t,c=t.getValue({item:e}),u=(0,o.useCallback)((e=>a({[s]:e})),[s,a]);if(t.elements)return(0,n.jsx)(r.RadioControl,{label:i,onChange:u,options:t.elements,selected:c,hideLabelFromVision:l});return null};var r=a(56427),o=a(86087),n=a(10790)},15381:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a,hideLabelFromVision:s}){var i,c;const{id:u,label:d}=t,v=null!==(i=t.getValue({item:e}))&&void 0!==i?i:"",p=(0,o.useCallback)((e=>a({[u]:e})),[u,a]),m=[{label:(0,n.__)("Select item","jetpack-my-jetpack"),value:""},...null!==(c=t?.elements)&&void 0!==c?c:[]];return(0,l.jsx)(r.SelectControl,{label:d,value:v,options:m,onChange:p,__next40pxDefaultSize:!0,__nextHasNoMarginBottom:!0,hideLabelFromVision:s})};var r=a(56427),o=a(86087),n=a(27723),l=a(10790)},78466:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a,hideLabelFromVision:l}){const{id:s,label:i,placeholder:c}=t,u=t.getValue({item:e}),d=(0,o.useCallback)((e=>a({[s]:e})),[s,a]);return(0,n.jsx)(r.TextControl,{label:i,placeholder:c,value:null!=u?u:"",onChange:d,__next40pxDefaultSize:!0,__nextHasNoMarginBottom:!0,hideLabelFromVision:l})};var r=a(56427),o=a(86087),n=a(10790)},49901:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.DataFormLayout=function({data:e,form:t,onChange:a,children:r}){const{fields:d}=(0,n.useContext)(s.default);const v=(0,n.useMemo)((()=>(0,c.default)(t)),[t]);return(0,u.jsx)(o.__experimentalVStack,{spacing:2,children:v.map((t=>{const o=(0,l.getFormFieldLayout)(t.layout)?.component;if(!o)return null;const n=(0,i.isCombinedField)(t)?void 0:function(e){const t="string"==typeof e?e:e.id;return d.find((e=>e.id===t))}(t);return n&&n.isVisible&&!n.isVisible(e)?null:r?r(o,t):(0,u.jsx)(o,{data:e,field:t,onChange:a},t.id)}))})};var o=a(56427),n=a(86087),l=a(84551),s=r(a(72423)),i=a(98906),c=r(a(25087)),u=a(10790)},84551:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.getFormFieldLayout=function(e){return l.find((t=>t.type===e))};var o=r(a(36464)),n=r(a(52022));const l=[{type:"regular",component:o.default},{type:"panel",component:n.default}]},98906:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isCombinedField=function(e){return void 0!==e.children}},52022:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a}){var r;const{fields:n}=(0,l.useContext)(i.default),s=n.find((e=>{if((0,u.isCombinedField)(t)){const a=t.children.filter((e=>"string"==typeof e||!(0,u.isCombinedField)(e))),r="string"==typeof a[0]?a[0]:a[0].id;return e.id===r}return e.id===t.id})),c=null!==(r=t.labelPosition)&&void 0!==r?r:"side",[v,m]=(0,l.useState)(null);if(!s)return null;const h=(0,u.isCombinedField)(t)?t.label:s?.label;if("top"===c)return(0,d.jsxs)(o.__experimentalVStack,{className:"dataforms-layouts-panel__field",spacing:0,children:[(0,d.jsx)("div",{className:"dataforms-layouts-panel__field-label",style:{paddingBottom:0},children:h}),(0,d.jsx)("div",{className:"dataforms-layouts-panel__field-control",children:(0,d.jsx)(p,{field:t,popoverAnchor:v,fieldDefinition:s,data:e,onChange:a,labelPosition:c})})]});if("none"===c)return(0,d.jsx)("div",{className:"dataforms-layouts-panel__field",children:(0,d.jsx)(p,{field:t,popoverAnchor:v,fieldDefinition:s,data:e,onChange:a,labelPosition:c})});return(0,d.jsxs)(o.__experimentalHStack,{ref:m,className:"dataforms-layouts-panel__field",children:[(0,d.jsx)("div",{className:"dataforms-layouts-panel__field-label",children:h}),(0,d.jsx)("div",{className:"dataforms-layouts-panel__field-control",children:(0,d.jsx)(p,{field:t,popoverAnchor:v,fieldDefinition:s,data:e,onChange:a,labelPosition:c})})]})};var o=a(56427),n=a(27723),l=a(86087),s=a(83203),i=r(a(72423)),c=a(49901),u=a(98906),d=a(10790);function v({title:e,onClose:t}){return(0,d.jsx)(o.__experimentalVStack,{className:"dataforms-layouts-panel__dropdown-header",spacing:4,children:(0,d.jsxs)(o.__experimentalHStack,{alignment:"center",children:[e&&(0,d.jsx)(o.__experimentalHeading,{level:2,size:13,children:e}),(0,d.jsx)(o.__experimentalSpacer,{}),t&&(0,d.jsx)(o.Button,{label:(0,n.__)("Close","jetpack-my-jetpack"),icon:s.closeSmall,onClick:t,size:"small"})]})})}function p({fieldDefinition:e,popoverAnchor:t,labelPosition:a="side",data:r,onChange:s,field:i}){const p=(0,u.isCombinedField)(i)?i.label:e?.label,m=(0,l.useMemo)((()=>(0,u.isCombinedField)(i)?{type:"regular",fields:i.children.map((e=>"string"==typeof e?{id:e}:e))}:{type:"regular",fields:[{id:i.id}]}),[i]),h=(0,l.useMemo)((()=>({anchor:t,placement:"left-start",offset:36,shift:!0})),[t]);return(0,d.jsx)(o.Dropdown,{contentClassName:"dataforms-layouts-panel__field-dropdown",popoverProps:h,focusOnMount:!0,toggleProps:{size:"compact",variant:"tertiary",tooltipPosition:"middle left"},renderToggle:({isOpen:t,onToggle:l})=>(0,d.jsx)(o.Button,{className:"dataforms-layouts-panel__field-control",size:"compact",variant:["none","top"].includes(a)?"link":"tertiary","aria-expanded":t,"aria-label":(0,n.sprintf)( -// translators: %s: Field name. -// translators: %s: Field name. -(0,n._x)("Edit %s","field","jetpack-my-jetpack"),p),onClick:l,children:(0,d.jsx)(e.render,{item:r})}),renderContent:({onClose:e})=>(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(v,{title:p,onClose:e}),(0,d.jsx)(c.DataFormLayout,{data:r,form:m,onChange:s,children:(e,t)=>{var a;return(0,d.jsx)(e,{data:r,field:t,onChange:s,hideLabelFromVision:(null!==(a=m?.fields)&&void 0!==a?a:[]).length<2},t.id)}})]})})}},36464:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({data:e,field:t,onChange:a,hideLabelFromVision:r}){var d;const{fields:v}=(0,o.useContext)(l.default),p=(0,o.useMemo)((()=>(0,i.isCombinedField)(t)?{fields:t.children.map((e=>"string"==typeof e?{id:e}:e)),type:"regular"}:{type:"regular",fields:[]}),[t]);if((0,i.isCombinedField)(t))return(0,c.jsxs)(c.Fragment,{children:[!r&&t.label&&(0,c.jsx)(u,{title:t.label}),(0,c.jsx)(s.DataFormLayout,{data:e,form:p,onChange:a})]});const m=null!==(d=t.labelPosition)&&void 0!==d?d:"top",h=v.find((e=>e.id===t.id));if(!h)return null;if("side"===m)return(0,c.jsxs)(n.__experimentalHStack,{className:"dataforms-layouts-regular__field",children:[(0,c.jsx)("div",{className:"dataforms-layouts-regular__field-label",children:h.label}),(0,c.jsx)("div",{className:"dataforms-layouts-regular__field-control",children:(0,c.jsx)(h.Edit,{data:e,field:h,onChange:a,hideLabelFromVision:!0},h.id)})]});return(0,c.jsx)("div",{className:"dataforms-layouts-regular__field",children:(0,c.jsx)(h.Edit,{data:e,field:h,onChange:a,hideLabelFromVision:"none"===m||r})})};var o=a(86087),n=a(56427),l=r(a(72423)),s=a(49901),i=a(98906),c=a(10790);function u({title:e}){return(0,c.jsx)(n.__experimentalVStack,{className:"dataforms-layouts-regular__header",spacing:4,children:(0,c.jsxs)(n.__experimentalHStack,{alignment:"center",children:[(0,c.jsx)(n.__experimentalHeading,{level:2,size:13,children:e}),(0,c.jsx)(n.__experimentalSpacer,{})]})})}},95187:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({actions:e,data:t,fields:a,getItemId:r,isLoading:s,onChangeSelection:i,onClickItem:c,isItemClickable:u,selection:v,view:h}){var g;const w=a.find((e=>e.id===h?.titleField)),b=a.find((e=>e.id===h?.mediaField)),y=a.find((e=>e.id===h?.descriptionField)),x=null!==(g=h.fields)&&void 0!==g?g:[],{regularFields:_,badgeFields:k}=x.reduce(((e,t)=>{const r=a.find((e=>e.id===t));if(!r)return e;return e[h.layout?.badgeFields?.includes(t)?"badgeFields":"regularFields"].push(r),e}),{regularFields:[],badgeFields:[]}),E=!!t?.length,C=(0,p.useUpdatedPreviewSizeOnViewportChange)(),j=(0,d.useSomeItemHasAPossibleBulkAction)(e,t),A=C||h.layout?.previewSize,S=A?{gridTemplateColumns:`repeat(${A}, minmax(0, 1fr))`}:{};return(0,m.jsxs)(m.Fragment,{children:[E&&(0,m.jsx)(n.__experimentalGrid,{gap:8,columns:2,alignment:"top",className:"dataviews-view-grid",style:S,"aria-busy":s,children:t.map((t=>(0,m.jsx)(f,{view:h,selection:v,onChangeSelection:i,onClickItem:c,isItemClickable:u,getItemId:r,item:t,actions:e,mediaField:b,titleField:w,descriptionField:y,regularFields:_,badgeFields:k,hasBulkActions:j},r(t))))}),!E&&(0,m.jsx)("div",{className:(0,o.default)({"dataviews-loading":s,"dataviews-no-results":!s}),children:(0,m.jsx)("p",{children:s?(0,m.jsx)(n.Spinner,{}):(0,l.__)("No results","jetpack-my-jetpack")})})]})};var o=r(a(33752)),n=a(56427),l=a(27723),s=a(29491),i=a(40191),c=r(a(97867)),u=r(a(10086)),d=a(10192),v=r(a(69946)),p=a(9828),m=a(10790);const{Badge:h}=(0,i.unlock)(n.privateApis);function f({view:e,selection:t,onChangeSelection:a,onClickItem:r,isItemClickable:i,getItemId:p,item:g,actions:w,mediaField:b,titleField:y,descriptionField:x,regularFields:_,badgeFields:k,hasBulkActions:E}){const{showTitle:C=!0,showMedia:j=!0,showDescription:A=!0}=e,S=(0,d.useHasAPossibleBulkAction)(w,g),P=p(g),R=(0,s.useInstanceId)(f),M=t.includes(P),V=b?.render?(0,m.jsx)(b.render,{item:g}):null,z=C&&y?.render?(0,m.jsx)(y.render,{item:g}):null,H=(0,v.default)({item:g,isItemClickable:i,onClickItem:r,className:"dataviews-view-grid__media"}),L=(0,v.default)({item:g,isItemClickable:i,onClickItem:r,className:"dataviews-view-grid__title-field dataviews-title-field"});let O,N;return i(g)&&r&&(z?(O={"aria-labelledby":`dataviews-view-grid__title-field-${R}`},N={id:`dataviews-view-grid__title-field-${R}`}):O={"aria-label":(0,l.__)("Navigate to item","jetpack-my-jetpack")}),(0,m.jsxs)(n.__experimentalVStack,{spacing:0,className:(0,o.default)("dataviews-view-grid__card",{"is-selected":S&&M}),onClickCapture:e=>{if(e.ctrlKey||e.metaKey){if(e.stopPropagation(),e.preventDefault(),!S)return;a(t.includes(P)?t.filter((e=>P!==e)):[...t,P])}},children:[j&&V&&(0,m.jsx)("div",{...H,...O,children:V}),E&&j&&V&&(0,m.jsx)(u.default,{item:g,selection:t,onChangeSelection:a,getItemId:p,titleField:y,disabled:!S}),(0,m.jsxs)(n.__experimentalHStack,{justify:"space-between",className:"dataviews-view-grid__title-actions",children:[(0,m.jsx)("div",{...L,...N,children:z}),!!w?.length&&(0,m.jsx)(c.default,{item:g,actions:w,isCompact:!0})]}),(0,m.jsxs)(n.__experimentalVStack,{spacing:1,children:[A&&x?.render&&(0,m.jsx)(x.render,{item:g}),!!k?.length&&(0,m.jsx)(n.__experimentalHStack,{className:"dataviews-view-grid__badge-fields",spacing:2,wrap:!0,alignment:"top",justify:"flex-start",children:k.map((e=>(0,m.jsx)(h,{className:"dataviews-view-grid__field-value",children:(0,m.jsx)(e.render,{item:g})},e.id)))}),!!_?.length&&(0,m.jsx)(n.__experimentalVStack,{className:"dataviews-view-grid__fields",spacing:1,children:_.map((e=>(0,m.jsx)(n.Flex,{className:"dataviews-view-grid__field",gap:1,justify:"flex-start",expanded:!0,style:{height:"auto"},direction:"row",children:(0,m.jsxs)(m.Fragment,{children:[(0,m.jsx)(n.FlexItem,{className:"dataviews-view-grid__field-name",children:e.header}),(0,m.jsx)(n.FlexItem,{className:"dataviews-view-grid__field-value",style:{maxHeight:"none"},children:(0,m.jsx)(e.render,{item:g})})]})},e.id)))})]})]},P)}},9828:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){const e=d(),t=(0,l.useContext)(s.default),a=t.view,r=c[e],u=a.layout?.previewSize||r.default,v=(0,l.useMemo)((()=>Array.from({length:r.max-r.min+1},((e,t)=>({value:r.min+t})))),[r]);if("mobile"===e)return null;return(0,i.jsx)(o.RangeControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,showTooltip:!1,label:(0,n.__)("Preview size","jetpack-my-jetpack"),value:r.max+r.min-u,marks:v,min:r.min,max:r.max,withInputField:!1,onChange:(e=0)=>{t.onChangeView({...a,layout:{...a.layout,previewSize:r.max+r.min-e}})},step:1})},t.useUpdatedPreviewSizeOnViewportChange=function(){const e=(0,l.useContext)(s.default).view,t=d();return(0,l.useMemo)((()=>{const a=e.layout?.previewSize;let r;if(!a)return;const o=c[t];return ao.max&&(r=o.max),r}),[t,e])};var o=a(56427),n=a(27723),l=a(86087),s=r(a(60789)),i=a(10790);const c={xhuge:{min:3,max:6,default:5},huge:{min:2,max:4,default:4},xlarge:{min:2,max:3,default:3},large:{min:1,max:2,default:2},mobile:{min:1,max:2,default:2}},u={xhuge:1520,huge:1140,xlarge:780,large:480,mobile:0};function d(){const e=(0,l.useContext)(s.default).containerWidth;for(const[t,a]of Object.entries(u))if(e>=a)return t;return"mobile"}},9322:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.VIEW_LAYOUTS=void 0;var o=a(27723),n=a(83203),l=r(a(23517)),s=r(a(95187)),i=r(a(9247)),c=a(64116),u=r(a(9828)),d=r(a(26452));t.VIEW_LAYOUTS=[{type:c.LAYOUT_TABLE,label:(0,o.__)("Table","jetpack-my-jetpack"),component:l.default,icon:n.blockTable,viewConfigOptions:d.default},{type:c.LAYOUT_GRID,label:(0,o.__)("Grid","jetpack-my-jetpack"),component:s.default,icon:n.category,viewConfigOptions:u.default},{type:c.LAYOUT_LIST,label:(0,o.__)("List","jetpack-my-jetpack"),component:i.default,icon:(0,o.isRTL)()?n.formatListBulletsRTL:n.formatListBullets}]},9247:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t){var a;const{actions:r,data:c,fields:u,getItemId:d,isLoading:v,onChangeSelection:m,selection:g,view:y}=t,x=(0,n.useInstanceId)(e,"view-list"),_=c?.findLast((e=>g.includes(d(e)))),k=u.find((e=>e.id===y.titleField)),E=u.find((e=>e.id===y.mediaField)),C=u.find((e=>e.id===y.descriptionField)),j=(null!==(a=y?.fields)&&void 0!==a?a:[]).map((e=>u.find((t=>e===t.id)))).filter(b),A=e=>m([d(e)]),S=(0,s.useCallback)((e=>`${x}-${d(e)}`),[x,d]),P=(0,s.useCallback)(((e,t)=>t.startsWith(S(e))),[S]),[R,M]=(0,s.useState)(void 0);(0,s.useEffect)((()=>{_&&M(h(S(_)))}),[_,S]);const V=c.findIndex((e=>P(e,null!=R?R:""))),z=(0,n.usePrevious)(V),H=-1!==V,L=(0,s.useCallback)(((e,t)=>{const a=Math.min(c.length-1,Math.max(0,e));if(!c[a])return;const r=t(S(c[a]));M(r),document.getElementById(r)?.focus()}),[c,S]);(0,s.useEffect)((()=>{!H&&(void 0!==z&&-1!==z)&&L(z,h)}),[H,L,z]);const O=(0,s.useCallback)((e=>{"ArrowDown"===e.key&&(e.preventDefault(),L(V+1,f)),"ArrowUp"===e.key&&(e.preventDefault(),L(V-1,f))}),[L,V]),N=c?.length;if(!N)return(0,p.jsx)("div",{className:(0,o.default)({"dataviews-loading":v,"dataviews-no-results":!N&&!v}),children:!N&&(0,p.jsx)("p",{children:v?(0,p.jsx)(l.Spinner,{}):(0,i.__)("No results","jetpack-my-jetpack")})});return(0,p.jsx)(l.Composite,{id:x,render:(0,p.jsx)("div",{}),className:"dataviews-view-list",role:"grid",activeId:R,setActiveId:M,children:c.map((e=>{const t=S(e);return(0,p.jsx)(w,{view:y,idPrefix:t,actions:r,item:e,isSelected:e===_,onSelect:A,mediaField:E,titleField:k,descriptionField:C,otherFields:j,onDropdownTriggerKeyDown:O},t)}))})};var o=r(a(33752)),n=a(29491),l=a(56427),s=a(86087),i=a(27723),c=a(83203),u=a(47143),d=a(40191),v=a(97867),p=a(10790);const{Menu:m}=(0,d.unlock)(l.privateApis);function h(e){return`${e}-item-wrapper`}function f(e){return`${e}-dropdown`}function g({idPrefix:e,primaryAction:t,item:a}){const r=(0,u.useRegistry)(),[o,n]=(0,s.useState)(!1),i=function(e,t){return`${e}-primary-action-${t}`}(e,t.id),c="string"==typeof t.label?t.label:t.label([a]);return"RenderModal"in t?(0,p.jsx)("div",{role:"gridcell",children:(0,p.jsx)(l.Composite.Item,{id:i,render:(0,p.jsx)(l.Button,{label:c,disabled:!!t.disabled,accessibleWhenDisabled:!0,icon:t.icon,isDestructive:t.isDestructive,size:"small",onClick:()=>n(!0)}),children:o&&(0,p.jsx)(v.ActionModal,{action:t,items:[a],closeModal:()=>n(!1)})})},t.id):(0,p.jsx)("div",{role:"gridcell",children:(0,p.jsx)(l.Composite.Item,{id:i,render:(0,p.jsx)(l.Button,{label:c,disabled:!!t.disabled,accessibleWhenDisabled:!0,icon:t.icon,isDestructive:t.isDestructive,size:"small",onClick:()=>{t.callback([a],{registry:r})}})})},t.id)}function w({view:e,actions:t,idPrefix:a,isSelected:r,item:n,titleField:d,mediaField:w,descriptionField:b,onSelect:y,otherFields:x,onDropdownTriggerKeyDown:_}){const{showTitle:k=!0,showMedia:E=!0,showDescription:C=!0}=e,j=(0,s.useRef)(null),A=`${a}-label`,S=`${a}-description`,P=(0,u.useRegistry)(),[R,M]=(0,s.useState)(!1),[V,z]=(0,s.useState)(null),H=({type:e})=>{M("mouseenter"===e)};(0,s.useEffect)((()=>{r&&j.current?.scrollIntoView({behavior:"auto",block:"nearest",inline:"nearest"})}),[r]);const{primaryAction:L,eligibleActions:O}=(0,s.useMemo)((()=>{const e=t.filter((e=>!e.isEligible||e.isEligible(n)));return{primaryAction:e.filter((e=>e.isPrimary&&!!e.icon))[0],eligibleActions:e}}),[t,n]),N=L&&1===t.length,I=E&&w?.render?(0,p.jsx)("div",{className:"dataviews-view-list__media-wrapper",children:(0,p.jsx)(w.render,{item:n})}):null,B=k&&d?.render?(0,p.jsx)(d.render,{item:n}):null,T=O?.length>0&&(0,p.jsxs)(l.__experimentalHStack,{spacing:3,className:"dataviews-view-list__item-actions",children:[L&&(0,p.jsx)(g,{idPrefix:a,primaryAction:L,item:n}),!N&&(0,p.jsxs)("div",{role:"gridcell",children:[(0,p.jsxs)(m,{placement:"bottom-end",children:[(0,p.jsx)(m.TriggerButton,{render:(0,p.jsx)(l.Composite.Item,{id:f(a),render:(0,p.jsx)(l.Button,{size:"small",icon:c.moreVertical,label:(0,i.__)("Actions","jetpack-my-jetpack"),accessibleWhenDisabled:!0,disabled:!t.length,onKeyDown:_})})}),(0,p.jsx)(m.Popover,{children:(0,p.jsx)(v.ActionsMenuGroup,{actions:O,item:n,registry:P,setActiveModalAction:z})})]}),!!V&&(0,p.jsx)(v.ActionModal,{action:V,items:[n],closeModal:()=>z(null)})]})]});return(0,p.jsx)(l.Composite.Row,{ref:j,render:(0,p.jsx)("div",{}),role:"row",className:(0,o.default)({"is-selected":r,"is-hovered":R}),onMouseEnter:H,onMouseLeave:H,children:(0,p.jsxs)(l.__experimentalHStack,{className:"dataviews-view-list__item-wrapper",spacing:0,children:[(0,p.jsx)("div",{role:"gridcell",children:(0,p.jsx)(l.Composite.Item,{id:h(a),"aria-pressed":r,"aria-labelledby":A,"aria-describedby":S,className:"dataviews-view-list__item",onClick:()=>y(n)})}),(0,p.jsxs)(l.__experimentalHStack,{spacing:3,justify:"start",alignment:"flex-start",children:[I,(0,p.jsxs)(l.__experimentalVStack,{spacing:1,className:"dataviews-view-list__field-wrapper",children:[(0,p.jsxs)(l.__experimentalHStack,{spacing:0,children:[(0,p.jsx)("div",{className:"dataviews-title-field",id:A,children:B}),T]}),C&&b?.render&&(0,p.jsx)("div",{className:"dataviews-view-list__field",children:(0,p.jsx)(b.render,{item:n})}),(0,p.jsx)("div",{className:"dataviews-view-list__fields",id:S,children:x.map((e=>(0,p.jsxs)("div",{className:"dataviews-view-list__field",children:[(0,p.jsx)(l.VisuallyHidden,{as:"span",className:"dataviews-view-list__field-label",children:e.label}),(0,p.jsx)("span",{className:"dataviews-view-list__field-value",children:(0,p.jsx)(e.render,{item:n})})]},e.id)))})]})]})]})})}function b(e){return!!e}},48277:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=a(27723),o=a(83203),n=a(56427),l=a(86087),s=a(40191),i=a(7912),c=a(64116),u=a(10790);const{Menu:d}=(0,s.unlock)(n.privateApis);function v({children:e}){return l.Children.toArray(e).filter(Boolean).map(((e,t)=>(0,u.jsxs)(l.Fragment,{children:[t>0&&(0,u.jsx)(d.Separator,{}),e]},t)))}const p=(0,l.forwardRef)((function({fieldId:e,view:t,fields:a,onChangeView:l,onHide:s,setOpenedFilter:p,canMove:m=!0},h){var f;const g=null!==(f=t.fields)&&void 0!==f?f:[],w=g?.indexOf(e),b=t.sort?.field===e;let y=!1,x=!1,_=!1,k=[];const E=a.find((t=>t.id===e));if(!E)return null;y=!1!==E.enableHiding,x=!1!==E.enableSorting;const C=E.header;return k=(0,i.sanitizeOperators)(E),_=!(t.filters?.some((t=>e===t.field))||!E.elements?.length||!k.length||E.filterBy?.isPrimary),(0,u.jsxs)(d,{children:[(0,u.jsxs)(d.TriggerButton,{render:(0,u.jsx)(n.Button,{size:"compact",className:"dataviews-view-table-header-button",ref:h,variant:"tertiary"}),children:[C,t.sort&&b&&(0,u.jsx)("span",{"aria-hidden":"true",children:c.sortArrows[t.sort.direction]})]}),(0,u.jsx)(d.Popover,{style:{minWidth:"240px"},children:(0,u.jsxs)(v,{children:[x&&(0,u.jsx)(d.Group,{children:c.SORTING_DIRECTIONS.map((a=>{const r=t.sort&&b&&t.sort.direction===a,o=`${e}-${a}`;return(0,u.jsx)(d.RadioItem,{name:"view-table-sorting",value:o,checked:r,onChange:()=>{l({...t,sort:{field:e,direction:a},showLevels:!1})},children:(0,u.jsx)(d.ItemLabel,{children:c.sortLabels[a]})},o)}))}),_&&(0,u.jsx)(d.Group,{children:(0,u.jsx)(d.Item,{prefix:(0,u.jsx)(n.Icon,{icon:o.funnel}),onClick:()=>{p(e),l({...t,page:1,filters:[...t.filters||[],{field:e,value:void 0,operator:k[0]}]})},children:(0,u.jsx)(d.ItemLabel,{children:(0,r.__)("Add filter","jetpack-my-jetpack")})})}),(m||y)&&E&&(0,u.jsxs)(d.Group,{children:[m&&(0,u.jsx)(d.Item,{prefix:(0,u.jsx)(n.Icon,{icon:o.arrowLeft}),disabled:w<1,onClick:()=>{var a;l({...t,fields:[...null!==(a=g.slice(0,w-1))&&void 0!==a?a:[],e,g[w-1],...g.slice(w+1)]})},children:(0,u.jsx)(d.ItemLabel,{children:(0,r.__)("Move left","jetpack-my-jetpack")})}),m&&(0,u.jsx)(d.Item,{prefix:(0,u.jsx)(n.Icon,{icon:o.arrowRight}),disabled:w>=g.length-1,onClick:()=>{var a;l({...t,fields:[...null!==(a=g.slice(0,w))&&void 0!==a?a:[],g[w+1],e,...g.slice(w+2)]})},children:(0,u.jsx)(d.ItemLabel,{children:(0,r.__)("Move right","jetpack-my-jetpack")})}),y&&E&&(0,u.jsx)(d.Item,{prefix:(0,u.jsx)(n.Icon,{icon:o.unseen}),onClick:()=>{s(E),l({...t,fields:g.filter((t=>t!==e))})},children:(0,u.jsx)(d.ItemLabel,{children:(0,r.__)("Hide column","jetpack-my-jetpack")})})]})]})})]})}));t.default=p},27040:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=a(56427),n=r(a(69946)),l=a(10790);t.default=function({item:e,level:t,titleField:a,mediaField:r,descriptionField:s,onClickItem:i,isItemClickable:c}){const u=(0,n.default)({item:e,isItemClickable:c,onClickItem:i,className:"dataviews-view-table__cell-content-wrapper dataviews-title-field"});return(0,l.jsxs)(o.__experimentalHStack,{spacing:3,justify:"flex-start",children:[r&&(0,l.jsx)("div",{className:"dataviews-view-table__cell-content-wrapper dataviews-column-primary__media",children:(0,l.jsx)(r.render,{item:e})}),(0,l.jsxs)(o.__experimentalVStack,{spacing:0,children:[a&&(0,l.jsxs)("div",{...u,children:[void 0!==t&&(0,l.jsxs)("span",{className:"dataviews-view-table__level",children:["—".repeat(t)," "]}),(0,l.jsx)(a.render,{item:e})]}),s&&(0,l.jsx)(s.render,{item:e})]})]})}},26452:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){const e=(0,l.useContext)(s.default),t=e.view;return(0,i.jsxs)(o.__experimentalToggleGroupControl,{__nextHasNoMarginBottom:!0,size:"__unstable-large",label:(0,n.__)("Density","jetpack-my-jetpack"),value:t.layout?.density||"balanced",onChange:a=>{e.onChangeView({...t,layout:{...t.layout,density:a}})},isBlock:!0,children:[(0,i.jsx)(o.__experimentalToggleGroupControlOption,{value:"comfortable",label:(0,n._x)("Comfortable","Density option for DataView layout","jetpack-my-jetpack")},"comfortable"),(0,i.jsx)(o.__experimentalToggleGroupControlOption,{value:"balanced",label:(0,n._x)("Balanced","Density option for DataView layout","jetpack-my-jetpack")},"balanced"),(0,i.jsx)(o.__experimentalToggleGroupControlOption,{value:"compact",label:(0,n._x)("Compact","Density option for DataView layout","jetpack-my-jetpack")},"compact")]})};var o=a(56427),n=a(27723),l=a(86087),s=r(a(60789)),i=a(10790)},23517:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var o=r(a(33752)),n=a(27723),l=a(56427),s=a(86087),i=r(a(10086)),c=r(a(97867)),u=a(64116),d=a(10192),v=r(a(48277)),p=r(a(27040)),m=a(10790);function h({item:e,fields:t,column:a}){const r=t.find((e=>e.id===a));return r?(0,m.jsx)("div",{className:"dataviews-view-table__cell-content-wrapper",children:(0,m.jsx)(r.render,{item:e})}):null}function f({hasBulkActions:e,item:t,level:a,actions:r,fields:n,id:l,view:u,titleField:v,mediaField:f,descriptionField:g,selection:w,getItemId:b,isItemClickable:y,onClickItem:x,onChangeSelection:_}){var k;const E=(0,d.useHasAPossibleBulkAction)(r,t),C=E&&w.includes(l),[j,A]=(0,s.useState)(!1),{showTitle:S=!0,showMedia:P=!0,showDescription:R=!0}=u,M=(0,s.useRef)(!1),V=null!==(k=u.fields)&&void 0!==k?k:[],z=v&&S||f&&P||g&&R;return(0,m.jsxs)("tr",{className:(0,o.default)("dataviews-view-table__row",{"is-selected":E&&C,"is-hovered":j,"has-bulk-actions":E}),onMouseEnter:()=>{A(!0)},onMouseLeave:()=>{A(!1)},onTouchStart:()=>{M.current=!0},onClick:()=>{E&&(M.current||"Range"===document.getSelection()?.type||_(w.includes(l)?w.filter((e=>l!==e)):[l]))},children:[e&&(0,m.jsx)("td",{className:"dataviews-view-table__checkbox-column",children:(0,m.jsx)("div",{className:"dataviews-view-table__cell-content-wrapper",children:(0,m.jsx)(i.default,{item:t,selection:w,onChangeSelection:_,getItemId:b,titleField:v,disabled:!E})})}),z&&(0,m.jsx)("td",{children:(0,m.jsx)(p.default,{item:t,level:a,titleField:S?v:void 0,mediaField:P?f:void 0,descriptionField:R?g:void 0,isItemClickable:y,onClickItem:x})}),V.map((e=>{var a;const{width:r,maxWidth:o,minWidth:l}=null!==(a=u.layout?.styles?.[e])&&void 0!==a?a:{};return(0,m.jsx)("td",{style:{width:r,maxWidth:o,minWidth:l},children:(0,m.jsx)(h,{fields:n,item:t,column:e})},e)})),!!r?.length&&(0,m.jsx)("td",{className:"dataviews-view-table__actions-column",onClick:e=>e.stopPropagation(),children:(0,m.jsx)(c.default,{item:t,actions:r})})]})}t.default=function({actions:e,data:t,fields:a,getItemId:r,getItemLevel:i,isLoading:c=!1,onChangeView:p,onChangeSelection:h,selection:g,setOpenedFilter:w,onClickItem:b,isItemClickable:y,view:x}){var _;const k=(0,s.useRef)(new Map),E=(0,s.useRef)(),[C,j]=(0,s.useState)(),A=(0,d.useSomeItemHasAPossibleBulkAction)(e,t);(0,s.useEffect)((()=>{E.current&&(E.current.focus(),E.current=void 0)}));const S=(0,s.useId)();if(C)return E.current=C,void j(void 0);const P=e=>{const t=k.current.get(e.id),a=t?k.current.get(t.fallback):void 0;j(a?.node)},R=!!t?.length,M=a.find((e=>e.id===x.titleField)),V=a.find((e=>e.id===x.mediaField)),z=a.find((e=>e.id===x.descriptionField)),{showTitle:H=!0,showMedia:L=!0,showDescription:O=!0}=x,N=M&&H||V&&L||z&&O,I=null!==(_=x.fields)&&void 0!==_?_:[],B=(e,t)=>a=>{a?k.current.set(e,{node:a,fallback:I[t>0?t-1:1]}):k.current.delete(e)};return(0,m.jsxs)(m.Fragment,{children:[(0,m.jsxs)("table",{className:(0,o.default)("dataviews-view-table",{[`has-${x.layout?.density}-density`]:x.layout?.density&&["compact","comfortable"].includes(x.layout.density)}),"aria-busy":c,"aria-describedby":S,children:[(0,m.jsx)("thead",{children:(0,m.jsxs)("tr",{className:"dataviews-view-table__row",children:[A&&(0,m.jsx)("th",{className:"dataviews-view-table__checkbox-column",scope:"col",children:(0,m.jsx)(d.BulkSelectionCheckbox,{selection:g,onChangeSelection:h,data:t,actions:e,getItemId:r})}),N&&(0,m.jsx)("th",{scope:"col",children:M&&(0,m.jsx)(v.default,{ref:B(M.id,0),fieldId:M.id,view:x,fields:a,onChangeView:p,onHide:P,setOpenedFilter:w,canMove:!1})}),I.map(((e,t)=>{var r;const{width:o,maxWidth:n,minWidth:l}=null!==(r=x.layout?.styles?.[e])&&void 0!==r?r:{};return(0,m.jsx)("th",{style:{width:o,maxWidth:n,minWidth:l},"aria-sort":x.sort?.direction&&x.sort?.field===e?u.sortValues[x.sort.direction]:void 0,scope:"col",children:(0,m.jsx)(v.default,{ref:B(e,t),fieldId:e,view:x,fields:a,onChangeView:p,onHide:P,setOpenedFilter:w})},e)})),!!e?.length&&(0,m.jsx)("th",{className:"dataviews-view-table__actions-column",children:(0,m.jsx)("span",{className:"dataviews-view-table-header",children:(0,n.__)("Actions","jetpack-my-jetpack")})})]})}),(0,m.jsx)("tbody",{children:R&&t.map(((t,o)=>(0,m.jsx)(f,{item:t,level:x.showLevels&&"function"==typeof i?i(t):void 0,hasBulkActions:A,actions:e,fields:a,id:r(t)||o.toString(),view:x,titleField:M,mediaField:V,descriptionField:z,selection:g,getItemId:r,onChangeSelection:h,onClickItem:b,isItemClickable:y},r(t))))})]}),(0,m.jsx)("div",{className:(0,o.default)({"dataviews-loading":c,"dataviews-no-results":!R&&!c}),id:S,children:!R&&(0,m.jsx)("p",{children:c?(0,m.jsx)(l.Spinner,{}):(0,n.__)("No results","jetpack-my-jetpack")})})]})}},69946:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function({item:e,isItemClickable:t,onClickItem:a,className:r}){if(!t(e)||!a)return{className:r};return{className:r?`${r} ${r}--clickable`:void 0,role:"button",tabIndex:0,onClick:t=>{t.stopPropagation(),a(e)},onKeyDown:t=>{"Enter"!==t.key&&""!==t.key&&" "!==t.key||(t.stopPropagation(),a(e))}}}},8749:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={sort:function(e,t,a){const r=new Date(e).getTime(),o=new Date(t).getTime();return"asc"===a?r-o:o-r},isValid:function(e,t){if(t?.elements){const a=t?.elements.map((e=>e.value));if(!a.includes(e))return!1}return!0},Edit:"datetime"}},62158:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if("integer"===e)return o.default;if("text"===e)return n.default;if("datetime"===e)return l.default;return{sort:(e,t,a)=>"number"==typeof e&&"number"==typeof t?"asc"===a?e-t:t-e:"asc"===a?e.localeCompare(t):t.localeCompare(e),isValid:(e,t)=>{if(t?.elements){const a=t?.elements?.map((e=>e.value));if(!a.includes(e))return!1}return!0},Edit:()=>null}};var o=r(a(98468)),n=r(a(807)),l=r(a(8749))},98468:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={sort:function(e,t,a){return"asc"===a?e-t:t-e},isValid:function(e,t){if(""===e)return!1;if(!Number.isInteger(Number(e)))return!1;if(t?.elements){const a=t?.elements.map((e=>e.value));if(!a.includes(Number(e)))return!1}return!0},Edit:"integer"}},807:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={sort:function(e,t,a){return"asc"===a?e.localeCompare(t):t.localeCompare(e)},isValid:function(e,t){if(t?.elements){const a=t?.elements?.map((e=>e.value));if(!a.includes(e))return!1}return!0},Edit:"text"}},66323:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.filterSortAndPaginate=function(e,t,a){if(!e)return{data:i,paginationInfo:{totalItems:0,totalPages:0}};const r=(0,l.normalizeFields)(a);let o=[...e];if(t.search){const e=s(t.search);o=o.filter((t=>r.filter((e=>e.enableGlobalSearch)).map((e=>s(e.getValue({item:t})))).some((t=>t.includes(e)))))}t.filters&&t.filters?.length>0&&t.filters.forEach((e=>{const t=r.find((t=>t.id===e.field));t&&(e.operator===n.OPERATOR_IS_ANY&&e?.value?.length>0?o=o.filter((a=>{const r=t.getValue({item:a});return Array.isArray(r)?e.value.some((e=>r.includes(e))):"string"==typeof r&&e.value.includes(r)})):e.operator===n.OPERATOR_IS_NONE&&e?.value?.length>0?o=o.filter((a=>{const r=t.getValue({item:a});return Array.isArray(r)?!e.value.some((e=>r.includes(e))):"string"==typeof r&&!e.value.includes(r)})):e.operator===n.OPERATOR_IS_ALL&&e?.value?.length>0?o=o.filter((a=>e.value.every((e=>t.getValue({item:a})?.includes(e))))):e.operator===n.OPERATOR_IS_NOT_ALL&&e?.value?.length>0?o=o.filter((a=>e.value.every((e=>!t.getValue({item:a})?.includes(e))))):e.operator===n.OPERATOR_IS?o=o.filter((a=>e.value===t.getValue({item:a}))):e.operator===n.OPERATOR_IS_NOT&&(o=o.filter((a=>e.value!==t.getValue({item:a})))))}));if(t.sort){const e=t.sort.field,a=r.find((t=>t.id===e));a&&o.sort(((e,r)=>{var o;return a.sort(e,r,null!==(o=t.sort?.direction)&&void 0!==o?o:"desc")}))}let c=o.length,u=1;if(void 0!==t.page&&void 0!==t.perPage){const e=(t.page-1)*t.perPage;c=o?.length||0,u=Math.ceil(c/t.perPage),o=o?.slice(e,e+t.perPage)}return{data:o,paginationInfo:{totalItems:c,totalPages:u}}};var o=r(a(44775)),n=a(64116),l=a(53582);function s(e=""){return(0,o.default)(e.trim().toLowerCase())}const i=[]},3613:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"Vw",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(t,"Pp",{enumerable:!0,get:function(){return s.filterSortAndPaginate}});var o=r(a(67807)),n=r(a(44117)),l=a(9322),s=a(66323),i=a(61382)},40191:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.unlock=t.lock=void 0;var r=a(13053);const{lock:o,unlock:n}=(0,r.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/dataviews");t.unlock=n,t.lock=o},53582:(e,t,a)=>{"use strict";var r=a(98504);Object.defineProperty(t,"__esModule",{value:!0}),t.normalizeFields=function(e){return e.map((e=>{var t,a,r,s;const i=(0,o.default)(e.type),c=e.getValue||l(e.id),u=null!==(t=e.sort)&&void 0!==t?t:function(e,t,a){return i.sort(c({item:e}),c({item:t}),a)},d=null!==(a=e.isValid)&&void 0!==a?a:function(e,t){return i.isValid(c({item:e}),t)},v=(0,n.getControl)(e,i),p=e.render||(e.elements?({item:t})=>{const a=c({item:t});return e?.elements?.find((e=>e.value===a))?.label||c({item:t})}:c);return{...e,label:e.label||e.id,header:e.header||e.label||e.id,getValue:c,render:p,sort:u,isValid:d,Edit:v,enableHiding:null===(r=e.enableHiding)||void 0===r||r,enableSorting:null===(s=e.enableSorting)||void 0===s||s}}))};var o=r(a(62158)),n=a(70105);const l=e=>({item:t})=>{const a=e.split(".");let r=t;for(const e of a)r=r.hasOwnProperty(e)?r[e]:void 0;return r}},25087:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){var t,a,r;let o="regular";["regular","panel"].includes(null!==(t=e.type)&&void 0!==t?t:"")&&(o=e.type);const n=null!==(a=e.labelPosition)&&void 0!==a?a:"regular"===o?"top":"side";return(null!==(r=e.fields)&&void 0!==r?r:[]).map((e=>{var t,a;if("string"==typeof e)return{id:e,layout:o,labelPosition:n};const r=null!==(t=e.layout)&&void 0!==t?t:o,l=null!==(a=e.labelPosition)&&void 0!==a?a:"regular"===r?"top":"side";return{...e,layout:r,labelPosition:l}}))}},7912:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.sanitizeOperators=function(e){let t=e.filterBy?.operators;t&&Array.isArray(t)||(t=[r.OPERATOR_IS_ANY,r.OPERATOR_IS_NONE]);t=t.filter((e=>r.ALL_OPERATORS.includes(e))),(t.includes(r.OPERATOR_IS)||t.includes(r.OPERATOR_IS_NOT))&&(t=t.filter((e=>[r.OPERATOR_IS,r.OPERATOR_IS_NOT].includes(e))));return t};var r=a(64116)},61382:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isItemValid=function(e,t,a){return(0,r.normalizeFields)(t.filter((({id:e})=>!!a.fields?.includes(e)))).every((t=>t.isValid(e,{elements:t.elements})))};var r=a(53582)},61937:(e,t,a)=>{"use strict";var r=a(51609);var o="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=r.useState,l=r.useEffect,s=r.useLayoutEffect,i=r.useDebugValue;function c(e){var t=e.getSnapshot;e=e.value;try{var a=t();return!o(e,a)}catch(e){return!0}}var u="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var a=t(),r=n({inst:{value:a,getSnapshot:t}}),o=r[0].inst,u=r[1];return s((function(){o.value=a,o.getSnapshot=t,c(o)&&u({inst:o})}),[e,a,t]),l((function(){return c(o)&&u({inst:o}),e((function(){c(o)&&u({inst:o})}))}),[e]),i(a),a};t.useSyncExternalStore=void 0!==r.useSyncExternalStore?r.useSyncExternalStore:u},22484:(e,t,a)=>{"use strict";e.exports=a(61937)},96309:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-license-activation-with-lock-cef570e11997f185e23d.png"},97139:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-license-activation-with-success-c5c132e713a79e05985f.png"},42822:(e,t,a)=>{"use strict";e.exports=a.p+"images/apple-92dacafad84e79708a74.svg"},18395:(e,t,a)=>{"use strict";e.exports=a.p+"images/connect-c399837fe1621b176d10.png"},35975:(e,t,a)=>{"use strict";e.exports=a.p+"images/github-45c648158e3e86b560f5.svg"},35519:(e,t,a)=>{"use strict";e.exports=a.p+"images/google-dec2a429bf1d8e83f9ad.svg"},6579:(e,t,a)=>{"use strict";e.exports=a.p+"images/wordpress-1fc3e0ba6c52e9707900.svg"},95042:(e,t,a)=>{"use strict";e.exports=a.p+"images/cloud-81ac85ba680343200f54.svg"},33168:(e,t,a)=>{"use strict";e.exports=a.p+"images/empty-avatar-fea23feddfa99b07c2e8.svg"},17757:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-gray-7eeb5eb060c8adea8622.svg"},87319:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-9de1caef5eb5c22da5d6.svg"},64576:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-manage-3a7ecaa604823c98c3cf.svg"},91912:(e,t,a)=>{"use strict";e.exports=a.p+"images/grow-your-audience-ddf8016fd72419f4e80e.png"},33320:(e,t,a)=>{"use strict";e.exports=a.p+"images/apple-36e00ab02e6fed6f51dd.svg"},70261:(e,t,a)=>{"use strict";e.exports=a.p+"images/github-523373a4447a46c189a1.svg"},71909:(e,t,a)=>{"use strict";e.exports=a.p+"images/google-a444c8c0f0c0108836d8.svg"},38846:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-5e94ec9a207b87fe38d7.svg"},96068:(e,t,a)=>{"use strict";e.exports=a.p+"images/shield-inactive-cba3b43d918377b506e5.svg"},90850:(e,t,a)=>{"use strict";e.exports=a.p+"images/shield-off-47426e7b562ef20ae513.svg"},64538:(e,t,a)=>{"use strict";e.exports=a.p+"images/shield-partial-48b279219c6389a129b9.svg"},24516:(e,t,a)=>{"use strict";e.exports=a.p+"images/shield-success-e64a26c3a6d0888fba06.svg"},58769:(e,t,a)=>{"use strict";e.exports=a.p+"images/boost-9e9a227e7e7280d0aa85.png"},98019:(e,t,a)=>{"use strict";e.exports=a.p+"images/complete-f4bd1db5fb786efbc9d5.png"},25296:(e,t,a)=>{"use strict";e.exports=a.p+"images/crm-8a2b204e2c720730e928.png"},72279:(e,t,a)=>{"use strict";e.exports=a.p+"images/extras-c6bd0796750901faa7fd.png"},19923:(e,t,a)=>{"use strict";e.exports=a.p+"images/jetpack-ai-d29bf65dcea46074d72f.png"},17642:(e,t,a)=>{"use strict";e.exports=a.p+"images/search-d177a31292d96d5ccbc2.png"},35148:(e,t,a)=>{"use strict";e.exports=a.p+"images/security-53b7f3ddc8dcbe17b0c1.png"},59409:(e,t,a)=>{"use strict";e.exports=a.p+"images/stats-95b42796ede4f632b642.png"},5044:(e,t,a)=>{"use strict";e.exports=a.p+"images/videopress-9c064bc7b89c386e5e50.png"},25990:e=>{"use strict";e.exports={consumer_slug:"my_jetpack"}},39384:e=>{"use strict";e.exports=window.JetpackConnection},97999:e=>{"use strict";e.exports=window.JetpackScriptDataModule},51609:e=>{"use strict";e.exports=window.React},75795:e=>{"use strict";e.exports=window.ReactDOM},10790:e=>{"use strict";e.exports=window.ReactJSXRuntime},66087:e=>{"use strict";e.exports=window.lodash},1455:e=>{"use strict";e.exports=window.wp.apiFetch},56427:e=>{"use strict";e.exports=window.wp.components},29491:e=>{"use strict";e.exports=window.wp.compose},47143:e=>{"use strict";e.exports=window.wp.data},38443:e=>{"use strict";e.exports=window.wp.date},98490:e=>{"use strict";e.exports=window.wp.domReady},86087:e=>{"use strict";e.exports=window.wp.element},52619:e=>{"use strict";e.exports=window.wp.hooks},27723:e=>{"use strict";e.exports=window.wp.i18n},692:e=>{"use strict";e.exports=window.wp.notices},92279:e=>{"use strict";e.exports=window.wp.plugins},5573:e=>{"use strict";e.exports=window.wp.primitives},13053:e=>{"use strict";e.exports=window.wp.privateApis},93832:e=>{"use strict";e.exports=window.wp.url},10979:e=>{"use strict";e.exports=window.wp.warning},44536:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a,r="undefined"!=typeof window&&!!(null==(a=window.document)?void 0:a.createElement);function o(e){return e?"self"in e?e.document:e.ownerDocument||document:document}function n(e,t){return e===t||e.contains(t)}function l(e){return"IFRAME"===e.tagName}var s=["button","color","file","image","reset","submit"];function i(e){try{const t=e instanceof HTMLInputElement&&null!==e.selectionStart,a="TEXTAREA"===e.tagName;return t||a||!1}catch(e){return!1}}function c(e,t){const a=null==e?void 0:e.getAttribute("role");return a&&-1!==["dialog","menu","listbox","tree","grid"].indexOf(a)?a:t}function u(e){if(!e)return null;const t=e=>"auto"===e||"scroll"===e;if(e.clientHeight&&e.scrollHeight>e.clientHeight){const{overflowY:a}=getComputedStyle(e);if(t(a))return e}else if(e.clientWidth&&e.scrollWidth>e.clientWidth){const{overflowX:a}=getComputedStyle(e);if(t(a))return e}return u(e.parentElement)||document.scrollingElement||document.body}function d(e){const t=e.getBoundingClientRect(),a=u(e);if(!a)return!1;const r=a.getBoundingClientRect(),o="HTML"===a.tagName,n=o?r.top+a.scrollTop:r.top,l=o?a.clientHeight:r.bottom,s=o?r.left+a.scrollLeft:r.left,i=o?a.clientWidth:r.right,c=t.topl,p=t.right>i;return c||d||v||p}t.canUseDOM=r,t.getDocument=o,t.getWindow=function(e){return e?"self"in e?e.self:o(e).defaultView||window:self},t.getActiveElement=function e(t,a=!1){const{activeElement:r}=o(t);if(!(null==r?void 0:r.nodeName))return null;if(l(r)&&r.contentDocument)return e(r.contentDocument.body,a);if(a){const e=r.getAttribute("aria-activedescendant");if(e){const t=o(r).getElementById(e);if(t)return t}}return r},t.contains=n,t.isFrame=l,t.isButton=function(e){const t=e.tagName.toLowerCase();return"button"===t||!("input"!==t||!e.type)&&-1!==s.indexOf(e.type)},t.isVisible=function(e){if("function"==typeof e.checkVisibility)return e.checkVisibility();const t=e;return t.offsetWidth>0||t.offsetHeight>0||e.getClientRects().length>0},t.isTextField=i,t.isTextbox=function(e){return e.isContentEditable||i(e)},t.getTextboxValue=function(e){if(i(e))return e.value;if(e.isContentEditable){const t=o(e).createRange();return t.selectNodeContents(e),t.toString()}return""},t.getTextboxSelection=function(e){let t=0,a=0;if(i(e))t=e.selectionStart||0,a=e.selectionEnd||0;else if(e.isContentEditable){const r=o(e).getSelection();if((null==r?void 0:r.rangeCount)&&r.anchorNode&&n(e,r.anchorNode)&&r.focusNode&&n(e,r.focusNode)){const o=r.getRangeAt(0),n=o.cloneRange();n.selectNodeContents(e),n.setEnd(o.startContainer,o.startOffset),t=n.toString().length,n.setEnd(o.endContainer,o.endOffset),a=n.toString().length}}return{start:t,end:a}},t.getPopupRole=c,t.getPopupItemRole=function(e,t){var a;const r=c(e);return r&&null!=(a={menu:"menuitem",listbox:"option",tree:"treeitem"}[r])?a:t},t.scrollIntoViewIfNeeded=function(e,t){d(e)&&"scrollIntoView"in e&&e.scrollIntoView(t)},t.getScrollingElement=u,t.isPartiallyHidden=d,t.setSelectionRange=function(e,...t){/text|search|password|tel|url/i.test(e.type)&&e.setSelectionRange(...t)},t.sortBasedOnDOMPosition=function(e,t){const a=e.map(((e,t)=>[t,e]));let r=!1;return a.sort((([e,a],[o,n])=>{const l=t(a),s=t(n);return l===s?0:l&&s?function(e,t){return Boolean(t.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_PRECEDING)}(l,s)?(e>o&&(r=!0),-1):(et)):e}},87230:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=Object.defineProperty,r=Object.defineProperties,o=Object.getOwnPropertyDescriptors,n=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,i=(e,t,r)=>t in e?a(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;t.__spreadValues=(e,t)=>{for(var a in t||(t={}))l.call(t,a)&&i(e,a,t[a]);if(n)for(var a of n(t))s.call(t,a)&&i(e,a,t[a]);return e},t.__spreadProps=(e,t)=>r(e,o(t)),t.__objRest=(e,t)=>{var a={};for(var r in e)l.call(e,r)&&t.indexOf(r)<0&&(a[r]=e[r]);if(null!=e&&n)for(var r of n(e))t.indexOf(r)<0&&s.call(e,r)&&(a[r]=e[r]);return a}},67641:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2617),o=a(87230);function n(e,t){const a=e.__unstableInternals;return r.invariant.call(void 0,a,"Invalid store"),a[t]}function l(e,...t){let a=e,n=a,c=Symbol(),u=r.noop;const d=new Set,v=new Set,p=new Set,m=new Set,h=new Set,f=new WeakMap,g=new WeakMap,w=(e,t,a=m)=>(a.add(t),g.set(t,e),()=>{var e;null==(e=f.get(t))||e(),f.delete(t),g.delete(t),a.delete(t)}),b=(e,l,s=!1)=>{var i;if(!r.hasOwnProperty.call(void 0,a,e))return;const u=r.applyState.call(void 0,l,a[e]);if(u===a[e])return;if(!s)for(const a of t)null==(i=null==a?void 0:a.setState)||i.call(a,e,u);const d=a;a=o.__spreadProps.call(void 0,o.__spreadValues.call(void 0,{},a),{[e]:u});const p=Symbol();c=p,v.add(e);const w=(t,r,o)=>{var n;const l=g.get(t);l&&!l.some((t=>o?o.has(t):t===e))||(null==(n=f.get(t))||n(),f.set(t,t(a,r)))};for(const e of m)w(e,d);queueMicrotask((()=>{if(c!==p)return;const e=a;for(const e of h)w(e,n,v);n=e,v.clear()}))},y={getState:()=>a,setState:b,__unstableInternals:{setup:e=>(p.add(e),()=>p.delete(e)),init:()=>{const e=d.size,o=Symbol();d.add(o);const n=()=>{d.delete(o),d.size||u()};if(e)return n;const l=r.getKeys.call(void 0,a).map((e=>r.chain.call(void 0,...t.map((t=>{var a;const o=null==(a=null==t?void 0:t.getState)?void 0:a.call(t);if(o&&r.hasOwnProperty.call(void 0,o,e))return i(t,[e],(t=>{b(e,t[e],!0)}))}))))),c=[];for(const e of p)c.push(e());const v=t.map(s);return u=r.chain.call(void 0,...l,...c,...v),n},subscribe:(e,t)=>w(e,t),sync:(e,t)=>(f.set(t,t(a,a)),w(e,t)),batch:(e,t)=>(f.set(t,t(a,n)),w(e,t,h)),pick:e=>l(r.pick.call(void 0,a,e),y),omit:e=>l(r.omit.call(void 0,a,e),y)}};return y}function s(e,...t){if(e)return n(e,"init")(...t)}function i(e,...t){if(e)return n(e,"sync")(...t)}t.createStore=l,t.setup=function(e,...t){if(e)return n(e,"setup")(...t)},t.init=s,t.subscribe=function(e,...t){if(e)return n(e,"subscribe")(...t)},t.sync=i,t.batch=function(e,...t){if(e)return n(e,"batch")(...t)},t.omit=function(e,...t){if(e)return n(e,"omit")(...t)},t.pick=function(e,...t){if(e)return n(e,"pick")(...t)},t.mergeStore=function(...e){const t=l(e.reduce(((e,t)=>{var a;const r=null==(a=null==t?void 0:t.getState)?void 0:a.call(t);return r?Object.assign(e,r):e}),{}),...e);return Object.assign({},...e,t)},t.throwOnConflictingProps=function(e,t){}},88543:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67641),o=a(2617),n=a(44536),l=a(87230);t.createCollectionStore=function(e={}){var t;r.throwOnConflictingProps.call(void 0,e,e.store);const a=null==(t=e.store)?void 0:t.getState(),s=o.defaultValue.call(void 0,e.items,null==a?void 0:a.items,e.defaultItems,[]),i=new Map(s.map((e=>[e.id,e]))),c={items:s,renderedItems:o.defaultValue.call(void 0,null==a?void 0:a.renderedItems,[])},u=null==(d=e.store)?void 0:d.__unstablePrivateStore;var d;const v=r.createStore.call(void 0,{items:s,renderedItems:c.renderedItems},u),p=r.createStore.call(void 0,c,e.store),m=e=>{const t=n.sortBasedOnDOMPosition.call(void 0,e,(e=>e.element));v.setState("renderedItems",t),p.setState("renderedItems",t)};r.setup.call(void 0,p,(()=>r.init.call(void 0,v))),r.setup.call(void 0,v,(()=>r.batch.call(void 0,v,["items"],(e=>{p.setState("items",e.items)})))),r.setup.call(void 0,v,(()=>r.batch.call(void 0,v,["renderedItems"],(e=>{let t=!0,a=requestAnimationFrame((()=>{const{renderedItems:t}=p.getState();e.renderedItems!==t&&m(e.renderedItems)}));if("function"!=typeof IntersectionObserver)return()=>cancelAnimationFrame(a);const r=function(e){var t;const a=e.find((e=>!!e.element)),r=[...e].reverse().find((e=>!!e.element));let o=null==(t=null==a?void 0:a.element)?void 0:t.parentElement;for(;o&&(null==r?void 0:r.element);){if(r&&o.contains(r.element))return o;o=o.parentElement}return n.getDocument.call(void 0,o).body}(e.renderedItems),o=new IntersectionObserver((()=>{t?t=!1:(cancelAnimationFrame(a),a=requestAnimationFrame((()=>m(e.renderedItems))))}),{root:r});for(const t of e.renderedItems)t.element&&o.observe(t.element);return()=>{cancelAnimationFrame(a),o.disconnect()}}))));const h=(e,t,a=!1)=>{let r;t((t=>{const a=t.findIndex((({id:t})=>t===e.id)),o=t.slice();if(-1!==a){r=t[a];const n=l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},r),e);o[a]=n,i.set(e.id,n)}else o.push(e),i.set(e.id,e);return o}));return()=>{t((t=>{if(!r)return a&&i.delete(e.id),t.filter((({id:t})=>t!==e.id));const o=t.findIndex((({id:t})=>t===e.id));if(-1===o)return t;const n=t.slice();return n[o]=r,i.set(e.id,r),n}))}},f=e=>h(e,(e=>v.setState("items",e)),!0);return l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},p),{registerItem:f,renderItem:e=>o.chain.call(void 0,f(e),h(e,(e=>v.setState("renderedItems",e)))),item:e=>{if(!e)return null;let t=i.get(e);if(!t){const{items:a}=v.getState();t=a.find((t=>t.id===e)),t&&i.set(e,t)}return t||null},__unstablePrivateStore:v})}},92566:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(36321),o=a(67641),n=a(2617),l=a(87230);t.createPopoverStore=function(e={}){var t=e,{popover:a}=t,s=l.__objRest.call(void 0,t,["popover"]);const i=o.mergeStore.call(void 0,s.store,o.omit.call(void 0,a,["arrowElement","anchorElement","contentElement","popoverElement","disclosureElement"]));o.throwOnConflictingProps.call(void 0,s,i);const c=null==i?void 0:i.getState(),u=r.createDialogStore.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},s),{store:i})),d=n.defaultValue.call(void 0,s.placement,null==c?void 0:c.placement,"bottom"),v=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},u.getState()),{placement:d,currentPlacement:d,anchorElement:n.defaultValue.call(void 0,null==c?void 0:c.anchorElement,null),popoverElement:n.defaultValue.call(void 0,null==c?void 0:c.popoverElement,null),arrowElement:n.defaultValue.call(void 0,null==c?void 0:c.arrowElement,null),rendered:Symbol("rendered")}),p=o.createStore.call(void 0,v,u,i);return l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},u),p),{setAnchorElement:e=>p.setState("anchorElement",e),setPopoverElement:e=>p.setState("popoverElement",e),setArrowElement:e=>p.setState("arrowElement",e),render:()=>p.setState("rendered",Symbol("rendered"))})}},20329:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.toArray=function(e){return Array.isArray(e)?e:void 0!==e?[e]:[]},t.addItemToArray=function(e,t,a=-1){return a in e?[...e.slice(0,a),t,...e.slice(a)]:[...e,t]},t.flatten2DArray=function(e){const t=[];for(const a of e)t.push(...a);return t},t.reverseArray=function(e){return e.slice().reverse()}},39119:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(88543),o=a(20329),n=a(67641),l=a(2617),s=a(87230),i={id:null};function c(e,t){return e.find((e=>t?!e.disabled&&e.id!==t:!e.disabled))}function u(e,t){return e.filter((e=>e.rowId===t))}function d(e){const t=[];for(const a of e){const e=t.find((e=>{var t;return(null==(t=e[0])?void 0:t.rowId)===a.rowId}));e?e.push(a):t.push([a])}return t}function v(e){let t=0;for(const{length:a}of e)a>t&&(t=a);return t}t.createCompositeStore=function(e={}){var t;const a=null==(t=e.store)?void 0:t.getState(),p=r.createCollectionStore.call(void 0,e),m=l.defaultValue.call(void 0,e.activeId,null==a?void 0:a.activeId,e.defaultActiveId),h=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},p.getState()),{id:l.defaultValue.call(void 0,e.id,null==a?void 0:a.id,`id-${Math.random().toString(36).slice(2,8)}`),activeId:m,baseElement:l.defaultValue.call(void 0,null==a?void 0:a.baseElement,null),includesBaseElement:l.defaultValue.call(void 0,e.includesBaseElement,null==a?void 0:a.includesBaseElement,null===m),moves:l.defaultValue.call(void 0,null==a?void 0:a.moves,0),orientation:l.defaultValue.call(void 0,e.orientation,null==a?void 0:a.orientation,"both"),rtl:l.defaultValue.call(void 0,e.rtl,null==a?void 0:a.rtl,!1),virtualFocus:l.defaultValue.call(void 0,e.virtualFocus,null==a?void 0:a.virtualFocus,!1),focusLoop:l.defaultValue.call(void 0,e.focusLoop,null==a?void 0:a.focusLoop,!1),focusWrap:l.defaultValue.call(void 0,e.focusWrap,null==a?void 0:a.focusWrap,!1),focusShift:l.defaultValue.call(void 0,e.focusShift,null==a?void 0:a.focusShift,!1)}),f=n.createStore.call(void 0,h,p,e.store);n.setup.call(void 0,f,(()=>n.sync.call(void 0,f,["renderedItems","activeId"],(e=>{f.setState("activeId",(t=>{var a;return void 0!==t?t:null==(a=c(e.renderedItems))?void 0:a.id}))}))));const g=(e="next",t={})=>{var a,r;const n=f.getState(),{skip:l=0,activeId:p=n.activeId,focusShift:m=n.focusShift,focusLoop:h=n.focusLoop,focusWrap:g=n.focusWrap,includesBaseElement:w=n.includesBaseElement,renderedItems:b=n.renderedItems,rtl:y=n.rtl}=t,x="up"===e||"down"===e,_="next"===e||"down"===e,k=_?y&&!x:!y||x,E=m&&!l;let C=x?o.flatten2DArray.call(void 0,function(e,t,a){const r=v(e);for(const o of e)for(let e=0;ee.id===p));if(!j)return null==(r=c(C))?void 0:r.id;const A=C.some((e=>e.rowId)),S=C.indexOf(j),P=C.slice(S+1),R=u(P,j.rowId);if(l){const e=function(e,t){return e.filter((e=>t?!e.disabled&&e.id!==t:!e.disabled))}(R,p),t=e.slice(l)[0]||e[e.length-1];return null==t?void 0:t.id}const M=h&&(x?"horizontal"!==h:"vertical"!==h),V=A&&g&&(x?"horizontal"!==g:"vertical"!==g),z=_?(!A||x)&&M&&w:!!x&&w;if(M){const e=function(e,t,a=!1){const r=e.findIndex((e=>e.id===t));return[...e.slice(r+1),...a?[i]:[],...e.slice(0,r)]}(V&&!z?C:u(C,j.rowId),p,z),t=c(e,p);return null==t?void 0:t.id}if(V){const e=c(z?R:P,p);return z?(null==e?void 0:e.id)||null:null==e?void 0:e.id}const H=c(R,p);return!H&&z?null:null==H?void 0:H.id};return s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,s.__spreadValues.call(void 0,{},p),f),{setBaseElement:e=>f.setState("baseElement",e),setActiveId:e=>f.setState("activeId",e),move:e=>{void 0!==e&&(f.setState("activeId",e),f.setState("moves",(e=>e+1)))},first:()=>{var e;return null==(e=c(f.getState().renderedItems))?void 0:e.id},last:()=>{var e;return null==(e=c(o.reverseArray.call(void 0,f.getState().renderedItems)))?void 0:e.id},next:e=>(void 0!==e&&"number"==typeof e&&(e={skip:e}),g("next",e)),previous:e=>(void 0!==e&&"number"==typeof e&&(e={skip:e}),g("previous",e)),down:e=>(void 0!==e&&"number"==typeof e&&(e={skip:e}),g("down",e)),up:e=>(void 0!==e&&"number"==typeof e&&(e={skip:e}),g("up",e))})}},2617:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87230);function o(...e){}function n(e){return"object"==typeof e&&null!=e}function l(e,t){return"function"==typeof Object.hasOwn?Object.hasOwn(e,t):Object.prototype.hasOwnProperty.call(e,t)}t.noop=o,t.shallowEqual=function(e,t){if(e===t)return!0;if(!e)return!1;if(!t)return!1;if("object"!=typeof e)return!1;if("object"!=typeof t)return!1;const a=Object.keys(e),r=Object.keys(t),{length:o}=a;if(r.length!==o)return!1;for(const r of a)if(e[r]!==t[r])return!1;return!0},t.applyState=function(e,t){if(function(e){return"function"==typeof e}(e)){return e(function(e){return"function"==typeof e}(t)?t():t)}return e},t.isObject=n,t.isEmpty=function(e){return Array.isArray(e)?!e.length:n(e)?!Object.keys(e).length:null==e||""===e},t.isInteger=function(e){return"number"==typeof e?Math.floor(e)===e:String(Math.floor(Number(e)))===e},t.hasOwnProperty=l,t.chain=function(...e){return(...t)=>{for(const a of e)"function"==typeof a&&a(...t)}},t.cx=function(...e){return e.filter(Boolean).join(" ")||void 0},t.normalizeString=function(e){return e.normalize("NFD").replace(/[\u0300-\u036f]/g,"")},t.omit=function(e,t){const a=r.__spreadValues.call(void 0,{},e);for(const e of t)l(a,e)&&delete a[e];return a},t.pick=function(e,t){const a={};for(const r of t)l(e,r)&&(a[r]=e[r]);return a},t.identity=function(e){return e},t.beforePaint=function(e=o){const t=requestAnimationFrame(e);return()=>cancelAnimationFrame(t)},t.afterPaint=function(e=o){let t=requestAnimationFrame((()=>{t=requestAnimationFrame(e)}));return()=>cancelAnimationFrame(t)},t.invariant=function(e,t){if(!e){if("string"!=typeof t)throw new Error("Invariant failed");throw new Error(t)}},t.getKeys=function(e){return Object.keys(e)},t.isFalsyBooleanCallback=function(e,...t){const a="function"==typeof e?e(...t):e;return null!=a&&!a},t.disabledFromProps=function(e){return e.disabled||!0===e["aria-disabled"]||"true"===e["aria-disabled"]},t.removeUndefinedValues=function(e){const t={};for(const a in e)void 0!==e[a]&&(t[a]=e[a]);return t},t.defaultValue=function(...e){for(const t of e)if(void 0!==t)return t}},39653:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(92566),o=a(67641),n=a(2617),l=a(87230);t.createHovercardStore=function(e={}){var t;const a=null==(t=e.store)?void 0:t.getState(),s=r.createPopoverStore.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},e),{placement:n.defaultValue.call(void 0,e.placement,null==a?void 0:a.placement,"bottom")})),i=n.defaultValue.call(void 0,e.timeout,null==a?void 0:a.timeout,500),c=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},s.getState()),{timeout:i,showTimeout:n.defaultValue.call(void 0,e.showTimeout,null==a?void 0:a.showTimeout),hideTimeout:n.defaultValue.call(void 0,e.hideTimeout,null==a?void 0:a.hideTimeout),autoFocusOnShow:n.defaultValue.call(void 0,null==a?void 0:a.autoFocusOnShow,!1)}),u=o.createStore.call(void 0,c,s,e.store);return l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},s),u),{setAutoFocusOnShow:e=>u.setState("autoFocusOnShow",e)})}},37164:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119),o=a(67641),n=a(2617),l=a(87230);t.createMenubarStore=function(e={}){var t;const a=null==(t=e.store)?void 0:t.getState(),s=r.createCompositeStore.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},e),{orientation:n.defaultValue.call(void 0,e.orientation,null==a?void 0:a.orientation,"horizontal"),focusLoop:n.defaultValue.call(void 0,e.focusLoop,null==a?void 0:a.focusLoop,!0)})),i=l.__spreadValues.call(void 0,{},s.getState()),c=o.createStore.call(void 0,i,s,e.store);return l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},s),c)}},18889:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67641),o=a(2617),n=a(87230);t.createDisclosureStore=function(e={}){const t=r.mergeStore.call(void 0,e.store,r.omit.call(void 0,e.disclosure,["contentElement","disclosureElement"]));r.throwOnConflictingProps.call(void 0,e,t);const a=null==t?void 0:t.getState(),l=o.defaultValue.call(void 0,e.open,null==a?void 0:a.open,e.defaultOpen,!1),s=o.defaultValue.call(void 0,e.animated,null==a?void 0:a.animated,!1),i={open:l,animated:s,animating:!!s&&l,mounted:l,contentElement:o.defaultValue.call(void 0,null==a?void 0:a.contentElement,null),disclosureElement:o.defaultValue.call(void 0,null==a?void 0:a.disclosureElement,null)},c=r.createStore.call(void 0,i,t);return r.setup.call(void 0,c,(()=>r.sync.call(void 0,c,["animated","animating"],(e=>{e.animated||c.setState("animating",!1)})))),r.setup.call(void 0,c,(()=>r.subscribe.call(void 0,c,["open"],(()=>{c.getState().animated&&c.setState("animating",!0)})))),r.setup.call(void 0,c,(()=>r.sync.call(void 0,c,["open","animating"],(e=>{c.setState("mounted",e.open||e.animating)})))),n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},c),{disclosure:e.disclosure,setOpen:e=>c.setState("open",e),show:()=>c.setState("open",!0),hide:()=>c.setState("open",!1),toggle:()=>c.setState("open",(e=>!e)),stopAnimation:()=>c.setState("animating",!1),setContentElement:e=>c.setState("contentElement",e),setDisclosureElement:e=>c.setState("disclosureElement",e)})}},21585:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44536);function o(){return r.canUseDOM&&!!navigator.maxTouchPoints}function n(){return!!r.canUseDOM&&/mac|iphone|ipad|ipod/i.test(navigator.platform)}t.isTouchDevice=o,t.isApple=n,t.isSafari=function(){return r.canUseDOM&&n()&&/apple/i.test(navigator.vendor)},t.isFirefox=function(){return r.canUseDOM&&/firefox\//i.test(navigator.userAgent)},t.isMac=function(){return r.canUseDOM&&navigator.platform.startsWith("Mac")&&!o()}},36321:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(18889);t.createDialogStore=function(e={}){return r.createDisclosureStore.call(void 0,e)}},64054:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67641),o=a(2617),n=a(87230);t.createCheckboxStore=function(e={}){var t;r.throwOnConflictingProps.call(void 0,e,e.store);const a=null==(t=e.store)?void 0:t.getState(),l={value:o.defaultValue.call(void 0,e.value,null==a?void 0:a.value,e.defaultValue,!1)},s=r.createStore.call(void 0,l,e.store);return n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},s),{setValue:e=>s.setState("value",e)})}},75088:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(88543);a(67641),a(2617),a(44536),a(87230),t.createCollectionStore=r.createCollectionStore},45698:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119);a(88543),a(20329);var o=a(92566);a(36321),a(18889);var n=a(67641),l=a(2617),s=a(21585);a(44536);var i=a(87230),c=s.isSafari.call(void 0)&&s.isTouchDevice.call(void 0);t.createComboboxStore=function(e={}){var t=e,{tag:a}=t,s=i.__objRest.call(void 0,t,["tag"]);const u=n.mergeStore.call(void 0,s.store,n.pick.call(void 0,a,["value","rtl"]));n.throwOnConflictingProps.call(void 0,s,u);const d=null==a?void 0:a.getState(),v=null==u?void 0:u.getState(),p=l.defaultValue.call(void 0,s.activeId,null==v?void 0:v.activeId,s.defaultActiveId,null),m=r.createCompositeStore.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},s),{activeId:p,includesBaseElement:l.defaultValue.call(void 0,s.includesBaseElement,null==v?void 0:v.includesBaseElement,!0),orientation:l.defaultValue.call(void 0,s.orientation,null==v?void 0:v.orientation,"vertical"),focusLoop:l.defaultValue.call(void 0,s.focusLoop,null==v?void 0:v.focusLoop,!0),focusWrap:l.defaultValue.call(void 0,s.focusWrap,null==v?void 0:v.focusWrap,!0),virtualFocus:l.defaultValue.call(void 0,s.virtualFocus,null==v?void 0:v.virtualFocus,!0)})),h=o.createPopoverStore.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},s),{placement:l.defaultValue.call(void 0,s.placement,null==v?void 0:v.placement,"bottom-start")})),f=l.defaultValue.call(void 0,s.value,null==v?void 0:v.value,s.defaultValue,""),g=l.defaultValue.call(void 0,s.selectedValue,null==v?void 0:v.selectedValue,null==d?void 0:d.values,s.defaultSelectedValue,""),w=Array.isArray(g),b=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,{},m.getState()),h.getState()),{value:f,selectedValue:g,resetValueOnSelect:l.defaultValue.call(void 0,s.resetValueOnSelect,null==v?void 0:v.resetValueOnSelect,w),resetValueOnHide:l.defaultValue.call(void 0,s.resetValueOnHide,null==v?void 0:v.resetValueOnHide,w&&!a),activeValue:null==v?void 0:v.activeValue}),y=n.createStore.call(void 0,b,m,h,u);return c&&n.setup.call(void 0,y,(()=>n.sync.call(void 0,y,["virtualFocus"],(()=>{y.setState("virtualFocus",!1)})))),n.setup.call(void 0,y,(()=>{if(a)return l.chain.call(void 0,n.sync.call(void 0,y,["selectedValue"],(e=>{Array.isArray(e.selectedValue)&&a.setValues(e.selectedValue)})),n.sync.call(void 0,a,["values"],(e=>{y.setState("selectedValue",e.values)})))})),n.setup.call(void 0,y,(()=>n.sync.call(void 0,y,["resetValueOnHide","mounted"],(e=>{e.resetValueOnHide&&(e.mounted||y.setState("value",f))})))),n.setup.call(void 0,y,(()=>n.sync.call(void 0,y,["open"],(e=>{e.open||(y.setState("activeId",p),y.setState("moves",0))})))),n.setup.call(void 0,y,(()=>n.sync.call(void 0,y,["moves","activeId"],((e,t)=>{e.moves===t.moves&&y.setState("activeValue",void 0)})))),n.setup.call(void 0,y,(()=>n.batch.call(void 0,y,["moves","renderedItems"],((e,t)=>{if(e.moves===t.moves)return;const{activeId:a}=y.getState(),r=m.item(a);y.setState("activeValue",null==r?void 0:r.value)})))),i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,{},h),m),y),{tag:a,setValue:e=>y.setState("value",e),resetValue:()=>y.setState("value",b.value),setSelectedValue:e=>y.setState("selectedValue",e)})}},68702:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119);a(88543),a(20329),a(67641),a(2617),a(44536),a(87230),t.createCompositeStore=r.createCompositeStore},8448:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(36321);a(18889),a(67641),a(2617),a(87230),t.createDialogStore=r.createDialogStore},97438:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(18889);a(67641),a(2617),a(87230),t.createDisclosureStore=r.createDisclosureStore},12028:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(88543),o=a(67641),n=a(2617);a(44536);var l=a(87230);function s(){return new Promise((e=>requestAnimationFrame((()=>e()))))}function i(e){return Object.keys(e).some((t=>n.isObject.call(void 0,e[t])?i(e[t]):!!e[t]))}function c(e,t,a){var r;const[o,...n]=Array.isArray(t)?t:`${t}`.split(".");return null!=o&&e?n.length?c(e[o],n,a):null!=(r=e[o])?r:a:a}function u(e,t,a){const[r,...o]=Array.isArray(t)?t:`${t}`.split(".");if(null==r)return e;const s=r,i=n.isInteger.call(void 0,s),c=(i?e||[]:e||{})[s],d=o.length&&(Array.isArray(c)||n.isObject.call(void 0,c))?u(c,o,a):a;if(i){const t=Number(s);if(e&&Array.isArray(e))return[...e.slice(0,t),d,...e.slice(t+1)];const a=[];return a[t]=d,a}return l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},e),{[s]:d})}function d(e,t){const a={},r=Object.keys(e);for(const o of r){const r=e[o];Array.isArray(r)?a[o]=r.map((e=>n.isObject.call(void 0,e)?d(e,t):t)):n.isObject.call(void 0,r)?a[o]=d(r,t):a[o]=t}return a}function v(e,t=[]){return{get(a,r){if(["toString","valueOf",Symbol.toPrimitive].includes(r))return()=>t.join(".");const o=[...t,r],n=o.join(".");if(e[n])return e[n];const l=new Proxy(a,v(e,o));return e[n]=l,l}}}function p(){const e=Object.create(null);return new Proxy(Object.create(null),v(e))}t.createFormStore=function(e={}){var t;o.throwOnConflictingProps.call(void 0,e,e.store);const a=null==(t=e.store)?void 0:t.getState(),v=r.createCollectionStore.call(void 0,e),m=n.defaultValue.call(void 0,e.values,null==a?void 0:a.values,e.defaultValues,{}),h=n.defaultValue.call(void 0,e.errors,null==a?void 0:a.errors,e.defaultErrors,{}),f=n.defaultValue.call(void 0,e.touched,null==a?void 0:a.touched,e.defaultTouched,{}),g=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},v.getState()),{values:m,errors:h,touched:f,validating:n.defaultValue.call(void 0,null==a?void 0:a.validating,!1),submitting:n.defaultValue.call(void 0,null==a?void 0:a.submitting,!1),submitSucceed:n.defaultValue.call(void 0,null==a?void 0:a.submitSucceed,0),submitFailed:n.defaultValue.call(void 0,null==a?void 0:a.submitFailed,0),valid:!i(h)}),w=o.createStore.call(void 0,g,v,e.store),b=null==(y=e.store)?void 0:y.__unstableCallbacks;var y;const x=null==b?void 0:b.getState(),_={validate:(null==x?void 0:x.validate)||[],submit:(null==x?void 0:x.submit)||[]},k=o.createStore.call(void 0,_,b);o.setup.call(void 0,w,(()=>o.init.call(void 0,k)));const E=async()=>{w.setState("validating",!0),w.setState("errors",{});const e=k.getState().validate;try{for(const t of e)await t(w.getState());return await s(),!i(w.getState().errors)}finally{w.setState("validating",!1)}};return l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},v),w),{names:p(),setValues:e=>w.setState("values",e),getValue:e=>c(w.getState().values,e),setValue:(e,t)=>w.setState("values",(a=>{const r=c(a,e),o=n.applyState.call(void 0,t,r);return o===r?a:u(a,e,o)})),pushValue:(e,t)=>w.setState("values",(a=>{const r=c(a,e,[]);return u(a,e,[...r,t])})),removeValue:(e,t)=>w.setState("values",(a=>{const r=c(a,e,[]);return u(a,e,[...r.slice(0,t),null,...r.slice(t+1)])})),setErrors:e=>w.setState("errors",e),getError:e=>c(w.getState().errors,e),setError:(e,t)=>w.setState("errors",(a=>{const r=c(a,e),o=n.applyState.call(void 0,t,r);return o===r?a:u(a,e,o)})),setTouched:e=>w.setState("touched",e),getFieldTouched:e=>!!c(w.getState().touched,e),setFieldTouched:(e,t)=>w.setState("touched",(a=>{const r=c(a,e),o=n.applyState.call(void 0,t,r);return o===r?a:u(a,e,o)})),onValidate:e=>(k.setState("validate",(t=>[...t,e])),()=>{k.setState("validate",(t=>t.filter((t=>t!==e))))}),validate:E,onSubmit:e=>(k.setState("submit",(t=>[...t,e])),()=>{k.setState("submit",(t=>t.filter((t=>t!==e))))}),submit:async()=>{w.setState("submitting",!0),w.setState("touched",d(w.getState().values,!0));try{if(await E()){const e=k.getState().submit;for(const t of e)await t(w.getState());if(await s(),!i(w.getState().errors))return w.setState("submitSucceed",(e=>e+1)),!0}return w.setState("submitFailed",(e=>e+1)),!1}catch(e){throw w.setState("submitFailed",(e=>e+1)),e}finally{w.setState("submitting",!1)}},reset:()=>{w.setState("values",m),w.setState("errors",h),w.setState("touched",f),w.setState("validating",!1),w.setState("submitting",!1),w.setState("submitSucceed",0),w.setState("submitFailed",0)},__unstableCallbacks:k})},t.get=c,t.hasMessages=i},58702:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39653);a(92566),a(36321),a(18889),a(67641),a(2617),a(87230),t.createHovercardStore=r.createHovercardStore},81894:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39653),o=a(39119);a(88543),a(20329),a(92566),a(36321),a(18889);var n=a(67641),l=a(2617);a(44536);var s=a(87230);t.createMenuStore=function(e={}){var t=e,{combobox:a,parent:i,menubar:c}=t,u=s.__objRest.call(void 0,t,["combobox","parent","menubar"]);const d=!!c&&!i,v=n.mergeStore.call(void 0,u.store,n.pick.call(void 0,i,["values"]),n.omit.call(void 0,a,["arrowElement","anchorElement","contentElement","popoverElement","disclosureElement"]));n.throwOnConflictingProps.call(void 0,u,v);const p=v.getState(),m=o.createCompositeStore.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},u),{store:v,orientation:l.defaultValue.call(void 0,u.orientation,p.orientation,"vertical")})),h=r.createHovercardStore.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},u),{store:v,placement:l.defaultValue.call(void 0,u.placement,p.placement,"bottom-start"),timeout:l.defaultValue.call(void 0,u.timeout,p.timeout,d?0:150),hideTimeout:l.defaultValue.call(void 0,u.hideTimeout,p.hideTimeout,0)})),f=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,s.__spreadValues.call(void 0,{},m.getState()),h.getState()),{initialFocus:l.defaultValue.call(void 0,p.initialFocus,"container"),values:l.defaultValue.call(void 0,u.values,p.values,u.defaultValues,{})}),g=n.createStore.call(void 0,f,m,h,v);return n.setup.call(void 0,g,(()=>n.sync.call(void 0,g,["mounted"],(e=>{e.mounted||g.setState("activeId",null)})))),n.setup.call(void 0,g,(()=>n.sync.call(void 0,i,["orientation"],(e=>{g.setState("placement","vertical"===e.orientation?"right-start":"bottom-start")})))),s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,s.__spreadValues.call(void 0,s.__spreadValues.call(void 0,{},m),h),g),{combobox:a,parent:i,menubar:c,hideAll:()=>{h.hide(),null==i||i.hideAll()},setInitialFocus:e=>g.setState("initialFocus",e),setValues:e=>g.setState("values",e),setValue:(e,t)=>{"__proto__"!==e&&"constructor"!==e&&(Array.isArray(e)||g.setState("values",(a=>{const r=a[e],o=l.applyState.call(void 0,t,r);return o===r?a:s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},a),{[e]:void 0!==o&&o})})))}})}},49586:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(37164);a(39119),a(88543),a(20329),a(67641),a(2617),a(44536),a(87230),t.createMenubarStore=r.createMenubarStore},69414:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(92566);a(36321),a(18889),a(67641),a(2617),a(87230),t.createPopoverStore=r.createPopoverStore},56286:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119);a(88543),a(20329);var o=a(67641),n=a(2617);a(44536);var l=a(87230);t.createRadioStore=function(e={}){var t,a=l.__objRest.call(void 0,e,[]);const s=null==(t=a.store)?void 0:t.getState(),i=r.createCompositeStore.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},a),{focusLoop:n.defaultValue.call(void 0,a.focusLoop,null==s?void 0:s.focusLoop,!0)})),c=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},i.getState()),{value:n.defaultValue.call(void 0,a.value,null==s?void 0:s.value,a.defaultValue,null)}),u=o.createStore.call(void 0,c,i,a.store);return l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},i),u),{setValue:e=>u.setState("value",e)})}},11420:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119);a(88543);var o=a(20329),n=a(92566);a(36321),a(18889);var l=a(67641),s=a(2617);a(44536);var i=a(87230);t.createSelectStore=function(e={}){var t=e,{combobox:a}=t,c=i.__objRest.call(void 0,t,["combobox"]);const u=l.mergeStore.call(void 0,c.store,l.omit.call(void 0,a,["value","items","renderedItems","baseElement","arrowElement","anchorElement","contentElement","popoverElement","disclosureElement"]));l.throwOnConflictingProps.call(void 0,c,u);const d=u.getState(),v=r.createCompositeStore.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},c),{store:u,virtualFocus:s.defaultValue.call(void 0,c.virtualFocus,d.virtualFocus,!0),includesBaseElement:s.defaultValue.call(void 0,c.includesBaseElement,d.includesBaseElement,!1),activeId:s.defaultValue.call(void 0,c.activeId,d.activeId,c.defaultActiveId,null),orientation:s.defaultValue.call(void 0,c.orientation,d.orientation,"vertical")})),p=n.createPopoverStore.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},c),{store:u,placement:s.defaultValue.call(void 0,c.placement,d.placement,"bottom-start")})),m=new String(""),h=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,{},v.getState()),p.getState()),{value:s.defaultValue.call(void 0,c.value,d.value,c.defaultValue,m),setValueOnMove:s.defaultValue.call(void 0,c.setValueOnMove,d.setValueOnMove,!1),labelElement:s.defaultValue.call(void 0,d.labelElement,null),selectElement:s.defaultValue.call(void 0,d.selectElement,null),listElement:s.defaultValue.call(void 0,d.listElement,null)}),f=l.createStore.call(void 0,h,v,p,u);return l.setup.call(void 0,f,(()=>l.sync.call(void 0,f,["value","items"],(e=>{if(e.value!==m)return;if(!e.items.length)return;const t=e.items.find((e=>!e.disabled&&null!=e.value));null!=(null==t?void 0:t.value)&&f.setState("value",t.value)})))),l.setup.call(void 0,f,(()=>l.sync.call(void 0,f,["mounted"],(e=>{e.mounted||f.setState("activeId",h.activeId)})))),l.setup.call(void 0,f,(()=>l.sync.call(void 0,f,["mounted","items","value"],(e=>{if(a)return;if(e.mounted)return;const t=o.toArray.call(void 0,e.value),r=t[t.length-1];if(null==r)return;const n=e.items.find((e=>!e.disabled&&e.value===r));n&&f.setState("activeId",n.id)})))),l.setup.call(void 0,f,(()=>l.batch.call(void 0,f,["setValueOnMove","moves"],(e=>{const{mounted:t,value:a,activeId:r}=f.getState();if(!e.setValueOnMove&&t)return;if(Array.isArray(a))return;if(!e.moves)return;if(!r)return;const o=v.item(r);o&&!o.disabled&&null!=o.value&&f.setState("value",o.value)})))),i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,{},v),p),f),{combobox:a,setValue:e=>f.setState("value",e),setLabelElement:e=>f.setState("labelElement",e),setSelectElement:e=>f.setState("selectElement",e),setListElement:e=>f.setState("listElement",e)})}},95190:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119),o=a(88543);a(20329);var n=a(67641),l=a(2617);a(44536);var s=a(87230);t.createTabStore=function(e={}){var t=e,{composite:a,combobox:i}=t,c=s.__objRest.call(void 0,t,["composite","combobox"]);const u=["items","renderedItems","moves","orientation","virtualFocus","includesBaseElement","baseElement","focusLoop","focusShift","focusWrap"],d=n.mergeStore.call(void 0,c.store,n.omit.call(void 0,a,u),n.omit.call(void 0,i,u)),v=null==d?void 0:d.getState(),p=r.createCompositeStore.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},c),{store:d,includesBaseElement:l.defaultValue.call(void 0,c.includesBaseElement,null==v?void 0:v.includesBaseElement,!1),orientation:l.defaultValue.call(void 0,c.orientation,null==v?void 0:v.orientation,"horizontal"),focusLoop:l.defaultValue.call(void 0,c.focusLoop,null==v?void 0:v.focusLoop,!0)})),m=o.createCollectionStore.call(void 0),h=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},p.getState()),{selectedId:l.defaultValue.call(void 0,c.selectedId,null==v?void 0:v.selectedId,c.defaultSelectedId),selectOnMove:l.defaultValue.call(void 0,c.selectOnMove,null==v?void 0:v.selectOnMove,!0)}),f=n.createStore.call(void 0,h,p,d);n.setup.call(void 0,f,(()=>n.sync.call(void 0,f,["moves"],(()=>{const{activeId:e,selectOnMove:t}=f.getState();if(!t)return;if(!e)return;const a=p.item(e);a&&(a.dimmed||a.disabled||f.setState("selectedId",a.id))}))));let g=!0;n.setup.call(void 0,f,(()=>n.batch.call(void 0,f,["selectedId"],((e,t)=>{g?a&&e.selectedId===t.selectedId||f.setState("activeId",e.selectedId):g=!0})))),n.setup.call(void 0,f,(()=>n.sync.call(void 0,f,["selectedId","renderedItems"],(e=>{if(void 0!==e.selectedId)return;const{activeId:t,renderedItems:a}=f.getState(),r=p.item(t);if(!r||r.disabled||r.dimmed){const e=a.find((e=>!e.disabled&&!e.dimmed));f.setState("selectedId",null==e?void 0:e.id)}else f.setState("selectedId",r.id)})))),n.setup.call(void 0,f,(()=>n.sync.call(void 0,f,["renderedItems"],(e=>{const t=e.renderedItems;if(t.length)return n.sync.call(void 0,m,["renderedItems"],(e=>{const a=e.renderedItems;a.some((e=>!e.tabId))&&a.forEach(((e,a)=>{if(e.tabId)return;const r=t[a];r&&m.renderItem(s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},e),{tabId:r.id}))}))}))}))));let w=null;return n.setup.call(void 0,f,(()=>{const e=()=>{w=f.getState().selectedId},t=()=>{g=!1,f.setState("selectedId",w)};return a&&"setSelectElement"in a?l.chain.call(void 0,n.sync.call(void 0,a,["value"],e),n.sync.call(void 0,a,["mounted"],t)):i?l.chain.call(void 0,n.sync.call(void 0,i,["selectedValue"],e),n.sync.call(void 0,i,["mounted"],t)):void 0})),s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,s.__spreadValues.call(void 0,{},p),f),{panels:m,setSelectedId:e=>f.setState("selectedId",e),select:e=>{f.setState("selectedId",e),p.move(e)}})}},23902:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39119);a(88543),a(20329),a(67641);var o=a(2617);a(44536);var n=a(87230);t.createToolbarStore=function(e={}){var t;const a=null==(t=e.store)?void 0:t.getState();return r.createCompositeStore.call(void 0,n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},e),{orientation:o.defaultValue.call(void 0,e.orientation,null==a?void 0:a.orientation,"horizontal"),focusLoop:o.defaultValue.call(void 0,e.focusLoop,null==a?void 0:a.focusLoop,!0)}))}},30054:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39653);a(92566),a(36321),a(18889);var o=a(67641),n=a(2617),l=a(87230);t.createTooltipStore=function(e={}){var t;const a=null==(t=e.store)?void 0:t.getState(),s=r.createHovercardStore.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},e),{placement:n.defaultValue.call(void 0,e.placement,null==a?void 0:a.placement,"top"),hideTimeout:n.defaultValue.call(void 0,e.hideTimeout,null==a?void 0:a.hideTimeout,0)})),i=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},s.getState()),{type:n.defaultValue.call(void 0,e.type,null==a?void 0:a.type,"description"),skipTimeout:n.defaultValue.call(void 0,e.skipTimeout,null==a?void 0:a.skipTimeout,300)}),c=o.createStore.call(void 0,i,s,e.store);return l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{},s),c)}},11790:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(20329);a(87230),t.addItemToArray=r.addItemToArray,t.flatten2DArray=r.flatten2DArray,t.reverseArray=r.reverseArray,t.toArray=r.toArray},92725:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44536);a(87230),t.canUseDOM=r.canUseDOM,t.contains=r.contains,t.getActiveElement=r.getActiveElement,t.getDocument=r.getDocument,t.getPopupItemRole=r.getPopupItemRole,t.getPopupRole=r.getPopupRole,t.getScrollingElement=r.getScrollingElement,t.getTextboxSelection=r.getTextboxSelection,t.getTextboxValue=r.getTextboxValue,t.getWindow=r.getWindow,t.isButton=r.isButton,t.isFrame=r.isFrame,t.isPartiallyHidden=r.isPartiallyHidden,t.isTextField=r.isTextField,t.isTextbox=r.isTextbox,t.isVisible=r.isVisible,t.scrollIntoViewIfNeeded=r.scrollIntoViewIfNeeded,t.setSelectionRange=r.setSelectionRange,t.sortBasedOnDOMPosition=r.sortBasedOnDOMPosition},77328:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21585),o=a(44536),n=a(87230);t.addGlobalEventListener=function e(t,a,r,o=window){const n=[];try{o.document.addEventListener(t,a,r);for(const l of Array.from(o.frames))n.push(e(t,a,r,l))}catch(e){}return()=>{try{o.document.removeEventListener(t,a,r)}catch(e){}for(const e of n)e()}},t.fireBlurEvent=function(e,t){const a=new FocusEvent("blur",t),r=e.dispatchEvent(a),o=n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},t),{bubbles:!0});return e.dispatchEvent(new FocusEvent("focusout",o)),r},t.fireClickEvent=function(e,t){const a=new MouseEvent("click",t);return e.dispatchEvent(a)},t.fireEvent=function(e,t,a){const r=new Event(t,a);return e.dispatchEvent(r)},t.fireFocusEvent=function(e,t){const a=new FocusEvent("focus",t),r=e.dispatchEvent(a),o=n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},t),{bubbles:!0});return e.dispatchEvent(new FocusEvent("focusin",o)),r},t.fireKeyboardEvent=function(e,t,a){const r=new KeyboardEvent(t,a);return e.dispatchEvent(r)},t.getInputType=function(e){const t="nativeEvent"in e?e.nativeEvent:e;if(t&&"inputType"in t&&"string"==typeof t.inputType)return t.inputType},t.isDownloading=function(e){const t=e.currentTarget;if(!t)return!1;const a=t.tagName.toLowerCase();return!!e.altKey&&("a"===a||("button"===a&&"submit"===t.type||"input"===a&&"submit"===t.type))},t.isFocusEventOutside=function(e,t){const a=t||e.currentTarget,r=e.relatedTarget;return!r||!o.contains.call(void 0,a,r)},t.isOpeningInNewTab=function(e){const t=e.currentTarget;if(!t)return!1;const a=r.isApple.call(void 0);if(a&&!e.metaKey)return!1;if(!a&&!e.ctrlKey)return!1;const o=t.tagName.toLowerCase();return"a"===o||("button"===o&&"submit"===t.type||"input"===o&&"submit"===t.type)},t.isPortalEvent=function(e){return Boolean(e.currentTarget&&!o.contains.call(void 0,e.currentTarget,e.target))},t.isSelfTarget=function(e){return e.target===e.currentTarget},t.queueBeforeEvent=function(e,t,a,r){const o=(e=>{if(r){const t=setTimeout(e,r);return()=>clearTimeout(t)}const t=requestAnimationFrame(e);return()=>cancelAnimationFrame(t)})((()=>{e.removeEventListener(t,n,!0),a()})),n=()=>{o(),a()};return e.addEventListener(t,n,{once:!0,capture:!0}),o}},60877:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44536),o=a(87230),n="input:not([type='hidden']):not([disabled]), select:not([disabled]), textarea:not([disabled]), a[href], button:not([disabled]), [tabindex], summary, iframe, object, embed, area[href], audio[controls], video[controls], [contenteditable]:not([contenteditable='false'])";function l(e){return!!e.matches(n)&&(!!r.isVisible.call(void 0,e)&&!e.closest("[inert]"))}function s(e){if(!l(e))return!1;if(function(e){return Number.parseInt(e.getAttribute("tabindex")||"0",10)<0}(e))return!1;if(!("form"in e))return!0;if(!e.form)return!0;if(e.checked)return!0;if("radio"!==e.type)return!0;const t=e.form.elements.namedItem(e.name);if(!t)return!0;if(!("length"in t))return!0;const a=r.getActiveElement.call(void 0,e);return!a||(a===e||(!("form"in a)||(a.form!==e.form||a.name!==e.name)))}function i(e,t){const a=Array.from(e.querySelectorAll(n));t&&a.unshift(e);const o=a.filter(l);return o.forEach(((e,t)=>{if(r.isFrame.call(void 0,e)&&e.contentDocument){const a=e.contentDocument.body;o.splice(t,1,...i(a))}})),o}function c(e,t){const[a]=i(e,t);return a||null}function u(e,t,a){const o=Array.from(e.querySelectorAll(n)),l=o.filter(s);return t&&s(e)&&l.unshift(e),l.forEach(((e,t)=>{if(r.isFrame.call(void 0,e)&&e.contentDocument){const r=u(e.contentDocument.body,!1,a);l.splice(t,1,...r)}})),!l.length&&a?o:l}function d(e,t,a){const[r]=u(e,t,a);return r||null}function v(e,t,a){const r=u(e,t,a);return r[r.length-1]||null}function p(e,t,a,o){const n=r.getActiveElement.call(void 0,e),l=i(e,t),c=l.indexOf(n),u=l.slice(c+1);return u.find(s)||(a?l.find(s):null)||(o?u[0]:null)||null}function m(e,t,a,o){const n=r.getActiveElement.call(void 0,e),l=i(e,t).reverse(),c=l.indexOf(n),u=l.slice(c+1);return u.find(s)||(a?l.find(s):null)||(o?u[0]:null)||null}function h(e){const t=r.getActiveElement.call(void 0,e);if(!t)return!1;if(r.contains.call(void 0,e,t))return!0;const a=t.getAttribute("aria-activedescendant");return!!a&&("id"in e&&(a===e.id||!!e.querySelector(`#${CSS.escape(a)}`)))}function f(e){var t;const a=null!=(t=e.getAttribute("tabindex"))?t:"";e.setAttribute("data-tabindex",a),e.setAttribute("tabindex","-1")}t.disableFocus=f,t.disableFocusIn=function(e,t){const a=u(e,t);for(const e of a)f(e)},t.focusIfNeeded=function(e){!h(e)&&l(e)&&e.focus()},t.focusIntoView=function(e,t){"scrollIntoView"in e?(e.focus({preventScroll:!0}),e.scrollIntoView(o.__spreadValues.call(void 0,{block:"nearest",inline:"nearest"},t))):e.focus()},t.getAllFocusable=function(e){return i(document.body,e)},t.getAllFocusableIn=i,t.getAllTabbable=function(e){return u(document.body,!1,e)},t.getAllTabbableIn=u,t.getClosestFocusable=function(e){for(;e&&!l(e);)e=e.closest(n);return e||null},t.getFirstFocusable=function(e){return c(document.body,e)},t.getFirstFocusableIn=c,t.getFirstTabbable=function(e){return d(document.body,!1,e)},t.getFirstTabbableIn=d,t.getLastTabbable=function(e){return v(document.body,!1,e)},t.getLastTabbableIn=v,t.getNextTabbable=function(e,t){return p(document.body,!1,e,t)},t.getNextTabbableIn=p,t.getPreviousTabbable=function(e,t){return m(document.body,!1,e,t)},t.getPreviousTabbableIn=m,t.hasFocus=function(e){const t=r.getActiveElement.call(void 0,e);if(!t)return!1;if(t===e)return!0;const a=t.getAttribute("aria-activedescendant");return!!a&&a===e.id},t.hasFocusWithin=h,t.isFocusable=l,t.isTabbable=s,t.restoreFocusIn=function(e){const t=e.querySelectorAll("[data-tabindex]"),a=e=>{const t=e.getAttribute("data-tabindex");e.removeAttribute("data-tabindex"),t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")};e.hasAttribute("data-tabindex")&&a(e);for(const e of t)a(e)}},48959:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2617);a(87230),t.afterPaint=r.afterPaint,t.applyState=r.applyState,t.beforePaint=r.beforePaint,t.chain=r.chain,t.cx=r.cx,t.defaultValue=r.defaultValue,t.disabledFromProps=r.disabledFromProps,t.getKeys=r.getKeys,t.hasOwnProperty=r.hasOwnProperty,t.identity=r.identity,t.invariant=r.invariant,t.isEmpty=r.isEmpty,t.isFalsyBooleanCallback=r.isFalsyBooleanCallback,t.isInteger=r.isInteger,t.isObject=r.isObject,t.noop=r.noop,t.normalizeString=r.normalizeString,t.omit=r.omit,t.pick=r.pick,t.removeUndefinedValues=r.removeUndefinedValues,t.shallowEqual=r.shallowEqual},32314:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21585);a(44536),a(87230),t.isApple=r.isApple,t.isFirefox=r.isFirefox,t.isMac=r.isMac,t.isSafari=r.isSafari,t.isTouchDevice=r.isTouchDevice},8766:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67641);a(2617),a(87230),t.batch=r.batch,t.createStore=r.createStore,t.init=r.init,t.mergeStore=r.mergeStore,t.omit=r.omit,t.pick=r.pick,t.setup=r.setup,t.subscribe=r.subscribe,t.sync=r.sync,t.throwOnConflictingProps=r.throwOnConflictingProps},28293:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(12204),o=a(19387),n=a(8549),l=a(68842),s=a(21676),i=a(85325),c=a(48960),u=a(94818),d=a(49464),v=a(82203),p=a(32146),m=a(9018),h=a(77723),f=a(53944),g=a(87121),w=a(19652),b=a(95691),y=a(87636),x=a(80987),_=a(28148),k=a(92725),E=a(77328),C=a(60877),j=a(48959),A=a(32314),S=a(51609),P=a(10790),R=A.isSafari.call(void 0);function M(e,t=!1){if(!e)return null;const a="current"in e?e.current:e;return a?t?C.isFocusable.call(void 0,a)?a:null:a:null}var V=w.createHook.call(void 0,(function(e){var t=e,{store:a,open:w,onClose:A,focusable:V=!0,modal:z=!0,portal:H=!!z,backdrop:L=!!z,hideOnEscape:O=!0,hideOnInteractOutside:N=!0,getPersistentElements:I,preventBodyScroll:B=!!z,autoFocusOnShow:T=!0,autoFocusOnHide:F=!0,initialFocus:D,finalFocus:G,unmountOnHide:U,unstable_treeSnapshotKey:q}=t,Z=_.__objRest.call(void 0,t,["store","open","onClose","focusable","modal","portal","backdrop","hideOnEscape","hideOnInteractOutside","getPersistentElements","preventBodyScroll","autoFocusOnShow","autoFocusOnHide","initialFocus","finalFocus","unmountOnHide","unstable_treeSnapshotKey"]);const W=f.useDialogProviderContext.call(void 0),$=S.useRef.call(void 0,null),J=b.useDialogStore.call(void 0,{store:a||W,open:w,setOpen(e){if(e)return;const t=$.current;if(!t)return;const a=new Event("close",{bubbles:!1,cancelable:!0});A&&t.addEventListener("close",A,{once:!0}),t.dispatchEvent(a),a.defaultPrevented&&J.setOpen(!0)}}),{portalRef:K,domReady:Q}=x.usePortalRef.call(void 0,H,Z.portalRef),Y=Z.preserveTabOrder,X=y.useStoreState.call(void 0,J,(e=>Y&&!z&&e.mounted)),ee=x.useId.call(void 0,Z.id),te=y.useStoreState.call(void 0,J,"open"),ae=y.useStoreState.call(void 0,J,"mounted"),re=y.useStoreState.call(void 0,J,"contentElement"),oe=h.isHidden.call(void 0,ae,Z.hidden,Z.alwaysVisible);n.usePreventBodyScroll.call(void 0,re,ee,B&&!oe),s.useHideOnInteractOutside.call(void 0,J,N,Q);const{wrapElement:ne,nestedDialogs:le}=l.useNestedDialogs.call(void 0,J);Z=x.useWrapElement.call(void 0,Z,ne,[ne]),x.useSafeLayoutEffect.call(void 0,(()=>{if(!te)return;const e=$.current,t=k.getActiveElement.call(void 0,e,!0);t&&"BODY"!==t.tagName&&(e&&k.contains.call(void 0,e,t)||J.setDisclosureElement(t))}),[J,te]),R&&S.useEffect.call(void 0,(()=>{if(!ae)return;const{disclosureElement:e}=J.getState();if(!e)return;if(!k.isButton.call(void 0,e))return;const t=()=>{let t=!1;const a=()=>{t=!0};e.addEventListener("focusin",a,{capture:!0,once:!0}),E.queueBeforeEvent.call(void 0,e,"mouseup",(()=>{e.removeEventListener("focusin",a,!0),t||C.focusIfNeeded.call(void 0,e)}))};return e.addEventListener("mousedown",t),()=>{e.removeEventListener("mousedown",t)}}),[J,ae]),S.useEffect.call(void 0,(()=>{if(!ae)return;if(!Q)return;const e=$.current;if(!e)return;const t=k.getWindow.call(void 0,e),a=t.visualViewport||t,r=()=>{var a,r;const o=null!=(r=null==(a=t.visualViewport)?void 0:a.height)?r:t.innerHeight;e.style.setProperty("--dialog-viewport-height",`${o}px`)};return r(),a.addEventListener("resize",r),()=>{a.removeEventListener("resize",r)}}),[ae,Q]),S.useEffect.call(void 0,(()=>{if(!z)return;if(!ae)return;if(!Q)return;const e=$.current;if(!e)return;return e.querySelector("[data-dialog-dismiss]")?void 0:u.prependHiddenDismiss.call(void 0,e,J.hide)}),[J,z,ae,Q]),x.useSafeLayoutEffect.call(void 0,(()=>{if(!c.supportsInert.call(void 0))return;if(te)return;if(!ae)return;if(!Q)return;const e=$.current;return e?o.disableTree.call(void 0,e):void 0}),[te,ae,Q]);const se=te&&Q;x.useSafeLayoutEffect.call(void 0,(()=>{if(!ee)return;if(!se)return;const e=$.current;return d.createWalkTreeSnapshot.call(void 0,ee,[e])}),[ee,se,q]);const ie=x.useEvent.call(void 0,I);x.useSafeLayoutEffect.call(void 0,(()=>{if(!ee)return;if(!se)return;const{disclosureElement:e}=J.getState(),t=[$.current,...ie()||[],...le.map((e=>e.getState().contentElement))];return z?j.chain.call(void 0,i.markTreeOutside.call(void 0,ee,t),o.disableTreeOutside.call(void 0,ee,t)):i.markTreeOutside.call(void 0,ee,[e,...t])}),[ee,J,se,ie,le,z,q]);const ce=!!T,ue=x.useBooleanEvent.call(void 0,T),[de,ve]=S.useState.call(void 0,!1);S.useEffect.call(void 0,(()=>{if(!te)return;if(!ce)return;if(!Q)return;if(!(null==re?void 0:re.isConnected))return;const e=M(D,!0)||re.querySelector("[data-autofocus=true],[autofocus]")||C.getFirstTabbableIn.call(void 0,re,!0,H&&X)||re,t=C.isFocusable.call(void 0,e);ue(t?e:null)&&(ve(!0),queueMicrotask((()=>{e.focus(),R&&e.scrollIntoView({block:"nearest",inline:"nearest"})})))}),[te,ce,Q,re,D,H,X,ue]);const pe=!!F,me=x.useBooleanEvent.call(void 0,F),[he,fe]=S.useState.call(void 0,!1);S.useEffect.call(void 0,(()=>{if(te)return fe(!0),()=>fe(!1)}),[te]);const ge=S.useCallback.call(void 0,((e,t=!0)=>{const{disclosureElement:a}=J.getState();if(function(e){const t=k.getActiveElement.call(void 0);return!(!t||e&&k.contains.call(void 0,e,t)||!C.isFocusable.call(void 0,t))}(e))return;let r=M(G)||a;if(null==r?void 0:r.id){const e=k.getDocument.call(void 0,r),t=`[aria-activedescendant="${r.id}"]`,a=e.querySelector(t);a&&(r=a)}if(r&&!C.isFocusable.call(void 0,r)){const e=r.closest("[data-dialog]");if(null==e?void 0:e.id){const t=k.getDocument.call(void 0,e),a=`[aria-controls~="${e.id}"]`,o=t.querySelector(a);o&&(r=o)}}const o=r&&C.isFocusable.call(void 0,r);o||!t?me(o?r:null)&&o&&(null==r||r.focus()):requestAnimationFrame((()=>ge(e,!1)))}),[J,G,me]),we=S.useRef.call(void 0,!1);x.useSafeLayoutEffect.call(void 0,(()=>{if(te)return;if(!he)return;if(!pe)return;const e=$.current;we.current=!0,ge(e)}),[te,he,Q,pe,ge]),S.useEffect.call(void 0,(()=>{if(!he)return;if(!pe)return;const e=$.current;return()=>{we.current?we.current=!1:ge(e)}}),[he,pe,ge]);const be=x.useBooleanEvent.call(void 0,O);S.useEffect.call(void 0,(()=>{if(!Q)return;if(!ae)return;return E.addGlobalEventListener.call(void 0,"keydown",(e=>{if("Escape"!==e.key)return;if(e.defaultPrevented)return;const t=$.current;if(!t)return;if(i.isElementMarked.call(void 0,t))return;const a=e.target;if(!a)return;const{disclosureElement:r}=J.getState();("BODY"===a.tagName||k.contains.call(void 0,t,a)||!r||k.contains.call(void 0,r,a))&&be(e)&&J.hide()}),!0)}),[J,Q,ae,be]);const ye=(Z=x.useWrapElement.call(void 0,Z,(e=>P.jsx.call(void 0,p.HeadingLevel,{level:z?1:void 0,children:e})),[z])).hidden,xe=Z.alwaysVisible;Z=x.useWrapElement.call(void 0,Z,(e=>L?P.jsxs.call(void 0,P.Fragment,{children:[P.jsx.call(void 0,r.DialogBackdrop,{store:J,backdrop:L,hidden:ye,alwaysVisible:xe}),e]}):e),[J,L,ye,xe]);const[_e,ke]=S.useState.call(void 0),[Ee,Ce]=S.useState.call(void 0);return Z=x.useWrapElement.call(void 0,Z,(e=>P.jsx.call(void 0,f.DialogScopedContextProvider,{value:J,children:P.jsx.call(void 0,f.DialogHeadingContext.Provider,{value:ke,children:P.jsx.call(void 0,f.DialogDescriptionContext.Provider,{value:Ce,children:e})})})),[J]),Z=_.__spreadProps.call(void 0,_.__spreadValues.call(void 0,{id:ee,"data-dialog":"",role:"dialog",tabIndex:V?-1:void 0,"aria-labelledby":_e,"aria-describedby":Ee},Z),{ref:x.useMergeRefs.call(void 0,$,Z.ref)}),Z=v.useFocusableContainer.call(void 0,_.__spreadProps.call(void 0,_.__spreadValues.call(void 0,{},Z),{autoFocusOnShow:de})),Z=h.useDisclosureContent.call(void 0,_.__spreadValues.call(void 0,{store:J},Z)),Z=g.useFocusable.call(void 0,_.__spreadProps.call(void 0,_.__spreadValues.call(void 0,{},Z),{focusable:V})),Z=m.usePortal.call(void 0,_.__spreadProps.call(void 0,_.__spreadValues.call(void 0,{portal:H},Z),{portalRef:K,preserveTabOrder:X}))}));function z(e,t=f.useDialogProviderContext){return w.forwardRef.call(void 0,(function(a){const r=t(),o=a.store||r;return y.useStoreState.call(void 0,o,(e=>!a.unmountOnHide||(null==e?void 0:e.mounted)||!!a.open))?P.jsx.call(void 0,e,_.__spreadValues.call(void 0,{},a)):null}))}var H=z(w.forwardRef.call(void 0,(function(e){const t=V(e);return w.createElement.call(void 0,"div",t)})),f.useDialogProviderContext);t.useDialog=V,t.createDialogComponent=z,t.Dialog=H},66342:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(49190),o=a(51500),n=a(77018),l=a(19652),s=a(80987),i=a(28148),c=a(48959),u=a(10790),d=l.createHook.call(void 0,(function(e){var t=e,{store:a}=t,l=i.__objRest.call(void 0,t,["store"]);const d=n.usePopoverProviderContext.call(void 0);a=a||d,c.invariant.call(void 0,a,!1);const v=l.onClick,p=s.useEvent.call(void 0,(e=>{null==a||a.setAnchorElement(e.currentTarget),null==v||v(e)}));return l=s.useWrapElement.call(void 0,l,(e=>u.jsx.call(void 0,n.PopoverScopedContextProvider,{value:a,children:e})),[a]),l=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},l),{onClick:p}),l=o.usePopoverAnchor.call(void 0,i.__spreadValues.call(void 0,{store:a},l)),l=r.useDialogDisclosure.call(void 0,i.__spreadValues.call(void 0,{store:a},l))})),v=l.forwardRef.call(void 0,(function(e){const t=d(e);return l.createElement.call(void 0,"button",t)}));t.usePopoverDisclosure=d,t.PopoverDisclosure=v},80032:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(46423),o=a(87636),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(30054));function l(e,t,a){return o.useStoreProps.call(void 0,e,a,"type"),o.useStoreProps.call(void 0,e,a,"skipTimeout"),r.useHovercardStoreProps.call(void 0,e,t,a)}t.useTooltipStoreProps=l,t.useTooltipStore=function(e={}){const[t,a]=o.useStore.call(void 0,n.createTooltipStore,e);return l(t,a,e)}},9018:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(54844),o=a(67722),n=a(19652),l=a(80987),s=a(7219),i=a(28148),c=a(92725),u=a(77328),d=a(60877),v=a(51609),p=a(75795),m=a(10790);function h(e){queueMicrotask((()=>{null==e||e.focus()}))}var f=n.createHook.call(void 0,(function(e){var t=e,{preserveTabOrder:a,preserveTabOrderAnchor:n,portalElement:f,portalRef:g,portal:w=!0}=t,b=i.__objRest.call(void 0,t,["preserveTabOrder","preserveTabOrderAnchor","portalElement","portalRef","portal"]);const y=v.useRef.call(void 0,null),x=l.useMergeRefs.call(void 0,y,b.ref),_=v.useContext.call(void 0,o.PortalContext),[k,E]=v.useState.call(void 0,null),[C,j]=v.useState.call(void 0,null),A=v.useRef.call(void 0,null),S=v.useRef.call(void 0,null),P=v.useRef.call(void 0,null),R=v.useRef.call(void 0,null);return l.useSafeLayoutEffect.call(void 0,(()=>{const e=y.current;if(!e||!w)return void E(null);const t=function(e,t){return t?"function"==typeof t?t(e):t:c.getDocument.call(void 0,e).createElement("div")}(e,f);if(!t)return void E(null);const a=t.isConnected;if(!a){const a=_||function(e){return c.getDocument.call(void 0,e).body}(e);a.appendChild(t)}return t.id||(t.id=e.id?`portal/${e.id}`:function(e="id"){return`${e?`${e}-`:""}${Math.random().toString(36).slice(2,8)}`}()),E(t),s.setRef.call(void 0,g,t),a?void 0:()=>{t.remove(),s.setRef.call(void 0,g,null)}}),[w,f,_,g]),l.useSafeLayoutEffect.call(void 0,(()=>{if(!w)return;if(!a)return;if(!n)return;const e=c.getDocument.call(void 0,n).createElement("span");return e.style.position="fixed",n.insertAdjacentElement("afterend",e),j(e),()=>{e.remove(),j(null)}}),[w,a,n]),v.useEffect.call(void 0,(()=>{if(!k)return;if(!a)return;let e=0;const t=t=>{if(!u.isFocusEventOutside.call(void 0,t))return;const a="focusin"===t.type;if(cancelAnimationFrame(e),a)return d.restoreFocusIn.call(void 0,k);e=requestAnimationFrame((()=>{d.disableFocusIn.call(void 0,k,!0)}))};return k.addEventListener("focusin",t,!0),k.addEventListener("focusout",t,!0),()=>{cancelAnimationFrame(e),k.removeEventListener("focusin",t,!0),k.removeEventListener("focusout",t,!0)}}),[k,a]),b=l.useWrapElement.call(void 0,b,(e=>{if(e=m.jsx.call(void 0,o.PortalContext.Provider,{value:k||_,children:e}),!w)return e;if(!k)return m.jsx.call(void 0,"span",{ref:x,id:b.id,style:{position:"fixed"},hidden:!0});e=m.jsxs.call(void 0,m.Fragment,{children:[a&&k&&m.jsx.call(void 0,r.FocusTrap,{ref:S,"data-focus-trap":b.id,className:"__focus-trap-inner-before",onFocus:e=>{u.isFocusEventOutside.call(void 0,e,k)?h(d.getNextTabbable.call(void 0)):h(A.current)}}),e,a&&k&&m.jsx.call(void 0,r.FocusTrap,{ref:P,"data-focus-trap":b.id,className:"__focus-trap-inner-after",onFocus:e=>{u.isFocusEventOutside.call(void 0,e,k)?h(d.getPreviousTabbable.call(void 0)):h(R.current)}})]}),k&&(e=p.createPortal.call(void 0,e,k));let t=m.jsxs.call(void 0,m.Fragment,{children:[a&&k&&m.jsx.call(void 0,r.FocusTrap,{ref:A,"data-focus-trap":b.id,className:"__focus-trap-outer-before",onFocus:e=>{!(e.relatedTarget===R.current)&&u.isFocusEventOutside.call(void 0,e,k)?h(S.current):h(d.getPreviousTabbable.call(void 0))}}),a&&m.jsx.call(void 0,"span",{"aria-owns":null==k?void 0:k.id,style:{position:"fixed"}}),a&&k&&m.jsx.call(void 0,r.FocusTrap,{ref:R,"data-focus-trap":b.id,className:"__focus-trap-outer-after",onFocus:e=>{if(u.isFocusEventOutside.call(void 0,e,k))h(P.current);else{const e=d.getNextTabbable.call(void 0);if(e===S.current)return void requestAnimationFrame((()=>{var e;return null==(e=d.getNextTabbable.call(void 0))?void 0:e.focus()}));h(e)}}})]});return C&&a&&(t=p.createPortal.call(void 0,t,C)),m.jsxs.call(void 0,m.Fragment,{children:[t,e]})}),[k,_,w,b.id,a,C]),b=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},b),{ref:x})})),g=n.forwardRef.call(void 0,(function(e){const t=f(e);return n.createElement.call(void 0,"div",t)}));t.usePortal=f,t.Portal=g},39861:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(28293),o=a(77018),n=a(19652),l=a(80987),s=a(28148),i=a(48959),c=a(64370),u=a(51609),d=a(10790);function v(e=0,t=0,a=0,r=0){if("function"==typeof DOMRect)return new DOMRect(e,t,a,r);const o={x:e,y:t,width:a,height:r,top:t,right:e+a,bottom:t+r,left:e};return s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},o),{toJSON:()=>o})}function p(e,t){return{contextElement:e||void 0,getBoundingClientRect:()=>{const a=e,r=null==t?void 0:t(a);return r||!a?function(e){if(!e)return v();const{x:t,y:a,width:r,height:o}=e;return v(t,a,r,o)}(r):a.getBoundingClientRect()}}}function m(e){return/^(?:top|bottom|left|right)(?:-(?:start|end))?$/.test(e)}function h(e){const t=window.devicePixelRatio||1;return Math.round(e*t)/t}function f(e,t){return c.offset.call(void 0,(({placement:a})=>{var r;const o=((null==e?void 0:e.clientHeight)||0)/2,n="number"==typeof t.gutter?t.gutter+o:null!=(r=t.gutter)?r:o;return{crossAxis:!!a.split("-")[1]?void 0:t.shift,mainAxis:n,alignmentAxis:t.shift}}))}function g(e){if(!1===e.flip)return;const t="string"==typeof e.flip?e.flip.split(" "):void 0;return i.invariant.call(void 0,!t||t.every(m),!1),c.flip.call(void 0,{padding:e.overflowPadding,fallbackPlacements:t})}function w(e){if(e.slide||e.overlap)return c.shift.call(void 0,{mainAxis:e.slide,crossAxis:e.overlap,padding:e.overflowPadding,limiter:c.limitShift.call(void 0)})}function b(e){return c.size.call(void 0,{padding:e.overflowPadding,apply({elements:t,availableWidth:a,availableHeight:r,rects:o}){const n=t.floating,l=Math.round(o.reference.width);a=Math.floor(a),r=Math.floor(r),n.style.setProperty("--popover-anchor-width",`${l}px`),n.style.setProperty("--popover-available-width",`${a}px`),n.style.setProperty("--popover-available-height",`${r}px`),e.sameWidth&&(n.style.width=`${l}px`),e.fitViewport&&(n.style.maxWidth=`${a}px`,n.style.maxHeight=`${r}px`)}})}function y(e,t){if(e)return c.arrow.call(void 0,{element:e,padding:t.arrowPadding})}var x=n.createHook.call(void 0,(function(e){var t=e,{store:a,modal:n=!1,portal:v=!!n,preserveTabOrder:m=!0,autoFocusOnShow:x=!0,wrapperProps:_,fixed:k=!1,flip:E=!0,shift:C=0,slide:j=!0,overlap:A=!1,sameWidth:S=!1,fitViewport:P=!1,gutter:R,arrowPadding:M=4,overflowPadding:V=8,getAnchorRect:z,updatePosition:H}=t,L=s.__objRest.call(void 0,t,["store","modal","portal","preserveTabOrder","autoFocusOnShow","wrapperProps","fixed","flip","shift","slide","overlap","sameWidth","fitViewport","gutter","arrowPadding","overflowPadding","getAnchorRect","updatePosition"]);const O=o.usePopoverProviderContext.call(void 0);a=a||O,i.invariant.call(void 0,a,!1);const N=a.useState("arrowElement"),I=a.useState("anchorElement"),B=a.useState("disclosureElement"),T=a.useState("popoverElement"),F=a.useState("contentElement"),D=a.useState("placement"),G=a.useState("mounted"),U=a.useState("rendered"),q=u.useRef.call(void 0,null),[Z,W]=u.useState.call(void 0,!1),{portalRef:$,domReady:J}=l.usePortalRef.call(void 0,v,L.portalRef),K=l.useEvent.call(void 0,z),Q=l.useEvent.call(void 0,H),Y=!!H;l.useSafeLayoutEffect.call(void 0,(()=>{if(!(null==T?void 0:T.isConnected))return;T.style.setProperty("--popover-overflow-padding",`${V}px`);const e=p(I,K),t=async()=>{if(!G)return;N||(q.current=q.current||document.createElement("div"));const t=N||q.current,r=[f(t,{gutter:R,shift:C}),g({flip:E,overflowPadding:V}),w({slide:j,shift:C,overlap:A,overflowPadding:V}),y(t,{arrowPadding:M}),b({sameWidth:S,fitViewport:P,overflowPadding:V})],o=await c.computePosition.call(void 0,e,T,{placement:D,strategy:k?"fixed":"absolute",middleware:r});null==a||a.setState("currentPlacement",o.placement),W(!0);const n=h(o.x),l=h(o.y);if(Object.assign(T.style,{top:"0",left:"0",transform:`translate3d(${n}px,${l}px,0)`}),t&&o.middlewareData.arrow){const{x:e,y:a}=o.middlewareData.arrow,r=o.placement.split("-")[0],n=t.clientWidth/2,l=t.clientHeight/2,s=null!=e?e+n:-n,i=null!=a?a+l:-l;T.style.setProperty("--popover-transform-origin",{top:`${s}px calc(100% + ${l}px)`,bottom:`${s}px ${-l}px`,left:`calc(100% + ${n}px) ${i}px`,right:`${-n}px ${i}px`}[r]),Object.assign(t.style,{left:null!=e?`${e}px`:"",top:null!=a?`${a}px`:"",[r]:"100%"})}},r=c.autoUpdate.call(void 0,e,T,(async()=>{Y?(await Q({updatePosition:t}),W(!0)):await t()}),{elementResize:"function"==typeof ResizeObserver});return()=>{W(!1),r()}}),[a,U,T,N,I,T,D,G,J,k,E,C,j,A,S,P,R,M,V,K,Y,Q]),l.useSafeLayoutEffect.call(void 0,(()=>{if(!G)return;if(!J)return;if(!(null==T?void 0:T.isConnected))return;if(!(null==F?void 0:F.isConnected))return;const e=()=>{T.style.zIndex=getComputedStyle(F).zIndex};e();let t=requestAnimationFrame((()=>{t=requestAnimationFrame(e)}));return()=>cancelAnimationFrame(t)}),[G,J,T,F]);const X=k?"fixed":"absolute";return L=l.useWrapElement.call(void 0,L,(e=>d.jsx.call(void 0,"div",s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},_),{style:s.__spreadValues.call(void 0,{position:X,top:0,left:0,width:"max-content"},null==_?void 0:_.style),ref:null==a?void 0:a.setPopoverElement,children:e}))),[a,X,_]),L=l.useWrapElement.call(void 0,L,(e=>d.jsx.call(void 0,o.PopoverScopedContextProvider,{value:a,children:e})),[a]),L=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{"data-placing":!Z||void 0},L),{style:s.__spreadValues.call(void 0,{position:"relative"},L.style)}),L=r.useDialog.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{store:a,modal:n,portal:v,preserveTabOrder:m,preserveTabOrderAnchor:B||I,autoFocusOnShow:Z&&x},L),{portalRef:$}))})),_=r.createDialogComponent.call(void 0,n.forwardRef.call(void 0,(function(e){const t=x(e);return n.createElement.call(void 0,"div",t)})),o.usePopoverProviderContext);t.usePopover=x,t.Popover=_},12707:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19652),o=r.createHook.call(void 0,(function(e){return e})),n=r.forwardRef.call(void 0,(function(e){return r.createElement.call(void 0,"div",e)}));Object.assign(n,["a","button","details","dialog","div","form","h1","h2","h3","h4","h5","h6","header","img","input","label","li","nav","ol","p","section","select","span","summary","textarea","ul","svg"].reduce(((e,t)=>(e[t]=r.forwardRef.call(void 0,(function(e){return r.createElement.call(void 0,t,e)})),e)),{})),t.useRole=o,t.Role=n},9355:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87636),o=a(80987),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(75088));function l(e,t,a){return o.useUpdateEffect.call(void 0,t,[a.store]),r.useStoreProps.call(void 0,e,a,"items","setItems"),e}t.useCollectionStoreProps=l,t.useCollectionStore=function(e={}){const[t,a]=r.useStore.call(void 0,n.createCollectionStore,e);return l(t,a,e)}},45081:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.POPOVER_ARROW_PATH="M23,27.8c1.1,1.2,3.4,2.2,5,2.2h2H0h2c1.7,0,3.9-1,5-2.2l6.6-7.2c0.7-0.8,2-0.8,2.7,0L23,27.8L23,27.8z"},97322:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(90604),o=a(80231),n=a(19652),l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useHovercardScopedContext.call(void 0);return a=a||s,n=r.usePopoverDismiss.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"button",t)}));t.useHovercardDismiss=s,t.HovercardDismiss=i},70419:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(29842),o=a(19652),n=a(80987),l=a(28148),s=a(92725),i=a(51609),c="button",u=o.createHook.call(void 0,(function(e){const t=i.useRef.call(void 0,null),a=n.useTagName.call(void 0,t,c),[o,u]=i.useState.call(void 0,(()=>!!a&&s.isButton.call(void 0,{tagName:a,type:e.type})));return i.useEffect.call(void 0,(()=>{t.current&&u(s.isButton.call(void 0,t.current))}),[]),e=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{role:o||"a"===a?void 0:"button"},e),{ref:n.useMergeRefs.call(void 0,t,e.ref)}),e=r.useCommand.call(void 0,e)})),d=o.forwardRef.call(void 0,(function(e){const t=u(e);return o.createElement.call(void 0,c,t)}));t.useButton=u,t.Button=d},52954:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19652),o=a(28148),n=r.createHook.call(void 0,(function(e){var t=e,{orientation:a="horizontal"}=t,r=o.__objRest.call(void 0,t,["orientation"]);return r=o.__spreadValues.call(void 0,{role:"separator","aria-orientation":a},r)})),l=r.forwardRef.call(void 0,(function(e){const t=n(e);return r.createElement.call(void 0,"hr",t)}));t.useSeparator=n,t.Separator=l},99471:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=new WeakMap;function r(e,t,r){a.has(e)||a.set(e,new Map);const o=a.get(e),n=o.get(t);if(!n)return o.set(t,r()),()=>{var e;null==(e=o.get(t))||e(),o.delete(t)};const l=r(),s=()=>{l(),n(),o.delete(t)};return o.set(t,s),()=>{o.get(t)===s&&(l(),o.set(t,n))}}t.orchestrate=r,t.setAttribute=function(e,t,a){return r(e,t,(()=>{const r=e.getAttribute(t);return e.setAttribute(t,a),()=>{null==r?e.removeAttribute(t):e.setAttribute(t,r)}}))},t.setProperty=function(e,t,a){return r(e,t,(()=>{const r=t in e,o=e[t];return e[t]=a,()=>{r?e[t]=o:delete e[t]}}))},t.assignStyle=function(e,t){return e?r(e,"style",(()=>{const a=e.style.cssText;return Object.assign(e.style,t),()=>{e.style.cssText=a}})):()=>{}},t.setCSSProperty=function(e,t,a){return e?r(e,t,(()=>{const r=e.style.getPropertyValue(t);return e.style.setProperty(t,a),()=>{r?e.style.setProperty(t,r):e.style.removeProperty(t)}})):()=>{}}},77723:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53944),o=a(16299),n=a(19652),l=a(87636),s=a(80987),i=a(28148),c=a(48959),u=a(51609),d=a(75795),v=a(10790);function p(e,t){const a=setTimeout(t,e);return()=>clearTimeout(a)}function m(...e){return e.join(", ").split(", ").reduce(((e,t)=>{const a=t.endsWith("ms")?1:1e3,r=Number.parseFloat(t||"0s")*a;return r>e?r:e}),0)}function h(e,t,a){return!(a||!1===t||e&&!t)}var f=n.createHook.call(void 0,(function(e){var t=e,{store:a,alwaysVisible:n}=t,f=i.__objRest.call(void 0,t,["store","alwaysVisible"]);const g=o.useDisclosureProviderContext.call(void 0);a=a||g,c.invariant.call(void 0,a,!1);const w=u.useRef.call(void 0,null),b=s.useId.call(void 0,f.id),[y,x]=u.useState.call(void 0,null),_=a.useState("open"),k=a.useState("mounted"),E=a.useState("animated"),C=a.useState("contentElement"),j=l.useStoreState.call(void 0,a.disclosure,"contentElement");s.useSafeLayoutEffect.call(void 0,(()=>{w.current&&(null==a||a.setContentElement(w.current))}),[a]),s.useSafeLayoutEffect.call(void 0,(()=>{let e;return null==a||a.setState("animated",(t=>(e=t,!0))),()=>{void 0!==e&&(null==a||a.setState("animated",e))}}),[a]),s.useSafeLayoutEffect.call(void 0,(()=>{if(E){if(null==C?void 0:C.isConnected)return function(e){let t=requestAnimationFrame((()=>{t=requestAnimationFrame(e)}));return()=>cancelAnimationFrame(t)}((()=>{x(_?"enter":k?"leave":null)}));x(null)}}),[E,C,_,k]),s.useSafeLayoutEffect.call(void 0,(()=>{if(!a)return;if(!E)return;if(!y)return;if(!C)return;const e=()=>null==a?void 0:a.setState("animating",!1),t=()=>d.flushSync.call(void 0,e);if("leave"===y&&_)return;if("enter"===y&&!_)return;if("number"==typeof E){return p(E,t)}const{transitionDuration:r,animationDuration:o,transitionDelay:n,animationDelay:l}=getComputedStyle(C),{transitionDuration:s="0",animationDuration:i="0",transitionDelay:c="0",animationDelay:u="0"}=j?getComputedStyle(j):{},v=m(n,l,c,u)+m(r,o,s,i);if(!v)return"enter"===y&&a.setState("animated",!1),void e();return p(Math.max(v-1e3/60,0),t)}),[a,E,C,j,_,y]),f=s.useWrapElement.call(void 0,f,(e=>v.jsx.call(void 0,r.DialogScopedContextProvider,{value:a,children:e})),[a]);const A=h(k,f.hidden,n),S=f.style,P=u.useMemo.call(void 0,(()=>A?i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},S),{display:"none"}):S),[A,S]);return f=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{id:b,"data-open":_||void 0,"data-enter":"enter"===y||void 0,"data-leave":"leave"===y||void 0,hidden:A},f),{ref:s.useMergeRefs.call(void 0,b?a.setContentElement:null,w,f.ref),style:P}),c.removeUndefinedValues.call(void 0,f)})),g=n.forwardRef.call(void 0,(function(e){const t=f(e);return n.createElement.call(void 0,"div",t)})),w=n.forwardRef.call(void 0,(function(e){var t=e,{unmountOnHide:a}=t,r=i.__objRest.call(void 0,t,["unmountOnHide"]);const n=o.useDisclosureProviderContext.call(void 0),s=r.store||n;return!1===l.useStoreState.call(void 0,s,(e=>!a||(null==e?void 0:e.mounted)))?null:v.jsx.call(void 0,g,i.__spreadValues.call(void 0,{},r))}));t.isHidden=h,t.useDisclosureContent=f,t.DisclosureContent=w},48960:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.supportsInert=function(){return"inert"in HTMLElement.prototype}},21676:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(85325),o=a(91605),n=a(87121),l=a(87636),s=a(80987),i=a(28148),c=a(92725),u=a(77328),d=a(51609);function v({store:e,type:t,listener:a,capture:o,domReady:i}){const v=s.useEvent.call(void 0,a),p=l.useStoreState.call(void 0,e,"open"),m=d.useRef.call(void 0,!1);s.useSafeLayoutEffect.call(void 0,(()=>{if(!p)return;if(!i)return;const{contentElement:t}=e.getState();if(!t)return;const a=()=>{m.current=!0};return t.addEventListener("focusin",a,!0),()=>t.removeEventListener("focusin",a,!0)}),[e,p,i]),d.useEffect.call(void 0,(()=>{if(!p)return;return u.addGlobalEventListener.call(void 0,t,(t=>{const{contentElement:a,disclosureElement:o}=e.getState(),l=t.target;if(!a)return;if(!l)return;if(!function(e){return"HTML"===e.tagName||c.contains.call(void 0,c.getDocument.call(void 0,e).body,e)}(l))return;if(c.contains.call(void 0,a,l))return;if(function(e,t){if(!e)return!1;if(c.contains.call(void 0,e,t))return!0;const a=t.getAttribute("aria-activedescendant");if(a){const t=c.getDocument.call(void 0,e).getElementById(a);if(t)return c.contains.call(void 0,e,t)}return!1}(o,l))return;if(l.hasAttribute("data-focus-trap"))return;if(function(e,t){if(!("clientY"in e))return!1;const a=t.getBoundingClientRect();return 0!==a.width&&0!==a.height&&a.top<=e.clientY&&e.clientY<=a.top+a.height&&a.left<=e.clientX&&e.clientX<=a.left+a.width}(t,a))return;m.current&&!r.isElementMarked.call(void 0,l,a.id)||n.isSafariFocusAncestor.call(void 0,l)||v(t)}),o)}),[p,o])}function p(e,t){return"function"==typeof e?e(t):!!e}t.useHideOnInteractOutside=function(e,t,a){const n=l.useStoreState.call(void 0,e,"open"),s=o.usePreviousMouseDownRef.call(void 0,n),u={store:e,domReady:a,capture:!0};v(i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},u),{type:"click",listener:a=>{const{contentElement:o}=e.getState(),n=s.current;n&&c.isVisible.call(void 0,n)&&r.isElementMarked.call(void 0,n,null==o?void 0:o.id)&&p(t,a)&&e.hide()}})),v(i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},u),{type:"focusin",listener:a=>{const{contentElement:r}=e.getState();r&&a.target!==c.getDocument.call(void 0,r)&&p(t,a)&&e.hide()}})),v(i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},u),{type:"contextmenu",listener:a=>{p(t,a)&&e.hide()}}))}},90604:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(60762),o=a(77018),n=a(19652),l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.usePopoverScopedContext.call(void 0);return a=a||s,n=r.useDialogDismiss.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"button",t)}));t.usePopoverDismiss=s,t.PopoverDismiss=i},22225:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652),n=a(80987),l=a(28148),s=a(48959),i=a(51609),c=a(10790),u=o.createHook.call(void 0,(function(e){var t=e,{store:a,"aria-setsize":o,"aria-posinset":u}=t,d=l.__objRest.call(void 0,t,["store","aria-setsize","aria-posinset"]);const v=r.useCompositeContext.call(void 0);a=a||v,s.invariant.call(void 0,a,!1);const p=n.useId.call(void 0,d.id),m=a.useState((e=>e.baseElement||void 0)),h=i.useMemo.call(void 0,(()=>({id:p,baseElement:m,ariaSetSize:o,ariaPosInSet:u})),[p,m,o,u]);return d=n.useWrapElement.call(void 0,d,(e=>c.jsx.call(void 0,r.CompositeRowContext.Provider,{value:h,children:e})),[h]),d=l.__spreadValues.call(void 0,{id:p},d),s.removeUndefinedValues.call(void 0,d)})),d=o.forwardRef.call(void 0,(function(e){const t=u(e);return o.createElement.call(void 0,"div",t)}));t.useCompositeRow=u,t.CompositeRow=d},19652:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80987),o=a(7219),n=a(28148),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(51609)),s=a(10790);t.forwardRef=function(e){const t=l.forwardRef(((t,a)=>e(n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},t),{ref:a}))));return t.displayName=e.displayName||e.name,t},t.memo=function(e,t){return l.memo(e,t)},t.createElement=function(e,t){const a=t,{wrapElement:i,render:c}=a,u=n.__objRest.call(void 0,a,["wrapElement","render"]),d=r.useMergeRefs.call(void 0,t.ref,o.getRefProperty.call(void 0,c));let v;if(l.isValidElement(c)){const e=n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},c.props),{ref:d});v=l.cloneElement(c,o.mergeProps.call(void 0,u,e))}else v=c?c(u):s.jsx.call(void 0,e,n.__spreadValues.call(void 0,{},u));return i?i(v):v},t.createHook=function(e){const t=(t={})=>e(t);return t.displayName=e.name,t},t.createStoreContext=function(e=[],t=[]){const a=l.createContext(void 0),r=l.createContext(void 0),o=()=>l.useContext(a),i=t=>e.reduceRight(((e,a)=>s.jsx.call(void 0,a,n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},t),{children:e}))),s.jsx.call(void 0,a.Provider,n.__spreadValues.call(void 0,{},t)));return{context:a,scopedContext:r,useContext:o,useScopedContext:(e=!1)=>{const t=l.useContext(r),a=o();return e?t:t||a},useProviderContext:()=>{const e=l.useContext(r),t=o();if(!e||e!==t)return t},ContextProvider:i,ScopedContextProvider:e=>s.jsx.call(void 0,i,n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},e),{children:t.reduceRight(((t,a)=>s.jsx.call(void 0,a,n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},e),{children:t}))),s.jsx.call(void 0,r.Provider,n.__spreadValues.call(void 0,{},e)))}))}}},87636:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r,o=a(80987),n=a(28148),l=a(48959),s=a(8766),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(51609)),c=a(22484),u=(r=c)&&r.__esModule?r:{default:r},{useSyncExternalStore:d}=u.default;function v(e,t=l.identity){const a=i.useCallback((t=>e?s.subscribe.call(void 0,e,null,t):()=>{}),[e]),r=()=>{const a="string"==typeof t?t:null,r="function"==typeof t?t:null,o=null==e?void 0:e.getState();return r?r(o):o&&a&&l.hasOwnProperty.call(void 0,o,a)?o[a]:void 0};return d(a,r,r)}t.useStoreState=v,t.useStoreStateObject=function(e,t){const a=i.useRef({}),r=i.useCallback((t=>e?s.subscribe.call(void 0,e,null,t):()=>{}),[e]),o=()=>{const r=null==e?void 0:e.getState();let o=!1;const s=a.current;for(const e in t){const a=t[e];if("function"==typeof a){const t=a(r);t!==s[e]&&(s[e]=t,o=!0)}if("string"==typeof a){if(!r)continue;if(!l.hasOwnProperty.call(void 0,r,a))continue;const t=r[a];t!==s[e]&&(s[e]=t,o=!0)}}return o&&(a.current=n.__spreadValues.call(void 0,{},s)),a.current};return d(r,o,o)},t.useStoreProps=function(e,t,a,r){const n=l.hasOwnProperty.call(void 0,t,a)?t[a]:void 0,i=r?t[r]:void 0,c=o.useLiveRef.call(void 0,{value:n,setValue:i});o.useSafeLayoutEffect.call(void 0,(()=>s.sync.call(void 0,e,[a],((e,t)=>{const{value:r,setValue:o}=c.current;o&&e[a]!==t[a]&&e[a]!==r&&o(e[a])}))),[e,a]),o.useSafeLayoutEffect.call(void 0,(()=>{if(void 0!==n)return e.setState(a,n),s.batch.call(void 0,e,[a],(()=>{void 0!==n&&e.setState(a,n)}))}))},t.useStore=function(e,t){const[a,r]=i.useState((()=>e(t)));o.useSafeLayoutEffect.call(void 0,(()=>s.init.call(void 0,a)),[a]);const l=i.useCallback((e=>v(a,e)),[a]);return[i.useMemo((()=>n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{},a),{useState:l})),[a,l]),o.useEvent.call(void 0,(()=>{r((a=>e(n.__spreadValues.call(void 0,n.__spreadValues.call(void 0,{},t),a.getState()))))}))]}},30829:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(61150),o=a(96475),n=a(35973),l=a(19652),s=a(87636),i=a(80987),c=a(28148),u=a(92725),d=a(77328),v=a(60877),p=a(48959),m=a(51609),h=a(10790);function f(e){var t;return null!=(t={menu:"menuitem",listbox:"option",tree:"treeitem"}[e])?t:"option"}var g=l.createHook.call(void 0,(function(e){var t,a=e,{store:l,value:g,hideOnClick:w,setValueOnClick:b,selectValueOnClick:y=!0,resetValueOnSelect:x,focusOnHover:_=!1,moveOnKeyPress:k=!0,getItem:E}=a,C=c.__objRest.call(void 0,a,["store","value","hideOnClick","setValueOnClick","selectValueOnClick","resetValueOnSelect","focusOnHover","moveOnKeyPress","getItem"]);const j=o.useComboboxScopedContext.call(void 0);l=l||j,p.invariant.call(void 0,l,!1);const{resetValueOnSelectState:A,multiSelectable:S,selected:P}=s.useStoreStateObject.call(void 0,l,{resetValueOnSelectState:"resetValueOnSelect",multiSelectable:e=>Array.isArray(e.selectedValue),selected:e=>function(e,t){if(null!=t)return null!=e&&(Array.isArray(e)?e.includes(t):e===t)}(e.selectedValue,g)}),R=m.useCallback.call(void 0,(e=>{const t=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{},e),{value:g});return E?E(t):t}),[g,E]);b=null!=b?b:!S,w=null!=w?w:null!=g&&!S;const M=C.onClick,V=i.useBooleanEvent.call(void 0,b),z=i.useBooleanEvent.call(void 0,y),H=i.useBooleanEvent.call(void 0,null!=(t=null!=x?x:A)?t:S),L=i.useBooleanEvent.call(void 0,w),O=i.useEvent.call(void 0,(e=>{null==M||M(e),e.defaultPrevented||d.isDownloading.call(void 0,e)||d.isOpeningInNewTab.call(void 0,e)||(null!=g&&(z(e)&&(H(e)&&(null==l||l.resetValue()),null==l||l.setSelectedValue((e=>Array.isArray(e)?e.includes(g)?e.filter((e=>e!==g)):[...e,g]:g))),V(e)&&(null==l||l.setValue(g))),L(e)&&(null==l||l.hide()))})),N=C.onKeyDown,I=i.useEvent.call(void 0,(e=>{if(null==N||N(e),e.defaultPrevented)return;const t=null==l?void 0:l.getState().baseElement;if(!t)return;if(v.hasFocus.call(void 0,t))return;(1===e.key.length||"Backspace"===e.key||"Delete"===e.key)&&(queueMicrotask((()=>t.focus())),u.isTextField.call(void 0,t)&&(null==l||l.setValue(t.value)))}));S&&null!=P&&(C=c.__spreadValues.call(void 0,{"aria-selected":P},C)),C=i.useWrapElement.call(void 0,C,(e=>h.jsx.call(void 0,o.ComboboxItemValueContext.Provider,{value:g,children:h.jsx.call(void 0,o.ComboboxItemCheckedContext.Provider,{value:null!=P&&P,children:e})})),[g,P]);const B=m.useContext.call(void 0,o.ComboboxListRoleContext);C=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{role:f(B),children:g},C),{onClick:O,onKeyDown:I});const T=i.useBooleanEvent.call(void 0,k);return C=n.useCompositeItem.call(void 0,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{store:l},C),{getItem:R,moveOnKeyPress:e=>{if(!T(e))return!1;const t=new Event("combobox-item-move"),a=null==l?void 0:l.getState().baseElement;return null==a||a.dispatchEvent(t),!0}})),C=r.useCompositeHover.call(void 0,c.__spreadValues.call(void 0,{store:l,focusOnHover:_},C))})),w=l.memo.call(void 0,l.forwardRef.call(void 0,(function(e){const t=g(e);return l.createElement.call(void 0,"div",t)})));t.useComboboxItem=g,t.ComboboxItem=w},28148:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=Object.defineProperty,r=Object.defineProperties,o=Object.getOwnPropertyDescriptors,n=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,i=(e,t,r)=>t in e?a(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;t.__spreadValues=(e,t)=>{for(var a in t||(t={}))l.call(t,a)&&i(e,a,t[a]);if(n)for(var a of n(t))s.call(t,a)&&i(e,a,t[a]);return e},t.__spreadProps=(e,t)=>r(e,o(t)),t.__objRest=(e,t)=>{var a={};for(var r in e)l.call(e,r)&&t.indexOf(r)<0&&(a[r]=e[r]);if(null!=e&&n)for(var r of n(e))t.indexOf(r)<0&&s.call(e,r)&&(a[r]=e[r]);return a}},22510:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(35174),o=a(53944),n=a(19652),l=a(80987),s=a(28148),i=a(51609),c=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=s.__objRest.call(void 0,t,["store"]);const c=i.useContext.call(void 0,o.DialogHeadingContext),u=l.useId.call(void 0,n.id);return l.useSafeLayoutEffect.call(void 0,(()=>(null==c||c(u),()=>null==c?void 0:c(void 0))),[c,u]),n=s.__spreadValues.call(void 0,{id:u},n),n=r.useHeading.call(void 0,n)})),u=n.forwardRef.call(void 0,(function(e){const t=c(e);return n.createElement.call(void 0,"h1",t)}));t.useDialogHeading=c,t.DialogHeading=u},56203:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(70419),o=a(16299),n=a(19652),l=a(80987),s=a(28148),i=a(48959),c=a(51609),u=Symbol("disclosure"),d=n.createHook.call(void 0,(function(e){var t=e,{store:a,toggleOnClick:n=!0}=t,d=s.__objRest.call(void 0,t,["store","toggleOnClick"]);const v=o.useDisclosureProviderContext.call(void 0);a=a||v,i.invariant.call(void 0,a,!1);const p=c.useRef.call(void 0,null),[m,h]=c.useState.call(void 0,!1),f=a.useState("disclosureElement"),g=a.useState("open");c.useEffect.call(void 0,(()=>{let e=f===p.current;(null==f?void 0:f.isConnected)||(null==a||a.setDisclosureElement(p.current),e=!0),h(g&&e)}),[f,a,g]);const w=d.onClick,b=l.useBooleanEvent.call(void 0,n),[y,x]=l.useMetadataProps.call(void 0,d,u,!0),_=l.useEvent.call(void 0,(e=>{null==w||w(e),e.defaultPrevented||y||b(e)&&(null==a||a.setDisclosureElement(e.currentTarget),null==a||a.toggle())})),k=a.useState("contentElement");return d=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,s.__spreadValues.call(void 0,{"aria-expanded":m,"aria-controls":null==k?void 0:k.id},x),d),{ref:l.useMergeRefs.call(void 0,p,d.ref),onClick:_}),d=r.useButton.call(void 0,d)})),v=n.forwardRef.call(void 0,(function(e){const t=d(e);return n.createElement.call(void 0,"button",t)}));t.useDisclosure=d,t.Disclosure=v},26327:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isBackdrop=function(e,...t){if(!e)return!1;const a=e.getAttribute("data-backdrop");return null!=a&&(""===a||("true"===a||(!t.length||t.some((e=>a===e)))))}},77673:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77018),o=a(19652),n=a(28148),l=a(48959),s=a(51609),i=a(10790),c={top:"4,10 8,6 12,10",right:"6,4 10,8 6,12",bottom:"4,6 8,10 12,6",left:"10,4 6,8 10,12"},u=o.createHook.call(void 0,(function(e){var t=e,{store:a,placement:o}=t,u=n.__objRest.call(void 0,t,["store","placement"]);const d=r.usePopoverContext.call(void 0);a=a||d,l.invariant.call(void 0,a,!1);const v=a.useState((e=>o||e.placement)).split("-")[0],p=c[v],m=s.useMemo.call(void 0,(()=>i.jsx.call(void 0,"svg",{display:"block",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,viewBox:"0 0 16 16",height:"1em",width:"1em",children:i.jsx.call(void 0,"polyline",{points:p})})),[p]);return u=n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{children:m,"aria-hidden":!0},u),{style:n.__spreadValues.call(void 0,{width:"1em",height:"1em",pointerEvents:"none"},u.style)}),l.removeUndefinedValues.call(void 0,u)})),d=o.forwardRef.call(void 0,(function(e){const t=u(e);return o.createElement.call(void 0,"span",t)}));t.usePopoverDisclosureArrow=u,t.PopoverDisclosureArrow=d},91907:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9355),o=a(87636),n=a(80987),l=a(28148),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(12028)),i=a(51609);function c(e,t,a){e=r.useCollectionStoreProps.call(void 0,e,t,a),o.useStoreProps.call(void 0,e,a,"values","setValues"),o.useStoreProps.call(void 0,e,a,"errors","setErrors"),o.useStoreProps.call(void 0,e,a,"touched","setTouched");const s=i.useCallback.call(void 0,(t=>e.useState((()=>e.getValue(t)))),[e]),c=i.useCallback.call(void 0,(t=>{t=n.useEvent.call(void 0,t);const a=e.useState("items");i.useEffect.call(void 0,(()=>e.onValidate(t)),[a,t])}),[e]),u=i.useCallback.call(void 0,(t=>{t=n.useEvent.call(void 0,t);const a=e.useState("items");i.useEffect.call(void 0,(()=>e.onSubmit(t)),[a,t])}),[e]);return i.useMemo.call(void 0,(()=>l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},e),{useValue:s,useValidate:c,useSubmit:u})),[])}t.useFormStoreProps=c,t.useFormStore=function(e={}){const[t,a]=o.useStore.call(void 0,s.createFormStore,e);return c(t,a,e)}},42888:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(61150),o=a(72707),n=a(35973),l=a(19652),s=a(87636),i=a(80987),c=a(28148),u=a(92725),d=a(77328),v=a(48959),p=a(51609),m=a(10790);var h=l.createHook.call(void 0,(function(e){var t,a=e,{store:l,value:h,getItem:f,hideOnClick:g,setValueOnClick:w=null!=h,preventScrollOnKeyDown:b=!0,focusOnHover:y=!0}=a,x=c.__objRest.call(void 0,a,["store","value","getItem","hideOnClick","setValueOnClick","preventScrollOnKeyDown","focusOnHover"]);const _=o.useSelectScopedContext.call(void 0);l=l||_,v.invariant.call(void 0,l,!1);const k=i.useId.call(void 0,x.id),E=v.disabledFromProps.call(void 0,x),{listElement:C,multiSelectable:j,selected:A,autoFocus:S}=s.useStoreStateObject.call(void 0,l,{listElement:"listElement",multiSelectable:e=>Array.isArray(e.value),selected:e=>function(e,t){if(null!=t)return null!=e&&(Array.isArray(e)?e.includes(t):e===t)}(e.value,h),autoFocus:e=>null!=h&&(null!=e.value&&((e.activeId===k||!(null==l?void 0:l.item(e.activeId)))&&(Array.isArray(e.value)?e.value[e.value.length-1]===h:e.value===h)))}),P=p.useCallback.call(void 0,(e=>{const t=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{},e),{value:E?void 0:h,children:h});return f?f(t):t}),[E,h,f]);g=null!=g?g:null!=h&&!j;const R=x.onClick,M=i.useBooleanEvent.call(void 0,w),V=i.useBooleanEvent.call(void 0,g),z=i.useEvent.call(void 0,(e=>{null==R||R(e),e.defaultPrevented||d.isDownloading.call(void 0,e)||d.isOpeningInNewTab.call(void 0,e)||(M(e)&&null!=h&&(null==l||l.setValue((e=>Array.isArray(e)?e.includes(h)?e.filter((e=>e!==h)):[...e,h]:h))),V(e)&&(null==l||l.hide()))}));x=i.useWrapElement.call(void 0,x,(e=>m.jsx.call(void 0,o.SelectItemCheckedContext.Provider,{value:null!=A&&A,children:e})),[A]),x=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{id:k,role:u.getPopupItemRole.call(void 0,C),"aria-selected":A,children:h},x),{autoFocus:null!=(t=x.autoFocus)?t:S,onClick:z}),x=n.useCompositeItem.call(void 0,c.__spreadValues.call(void 0,{store:l,getItem:P,preventScrollOnKeyDown:b},x));const H=i.useBooleanEvent.call(void 0,y);return x=r.useCompositeHover.call(void 0,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{store:l},x),{focusOnHover(e){if(!H(e))return!1;const t=null==l?void 0:l.getState();return!!(null==t?void 0:t.open)}}))})),f=l.memo.call(void 0,l.forwardRef.call(void 0,(function(e){const t=h(e);return l.createElement.call(void 0,"div",t)})));t.useSelectItem=h,t.SelectItem=f},71385:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(85826),o=a(67804),n=a(29842),l=a(19652),s=a(87636),i=a(80987),c=a(28148),u=a(48959),d=a(51609),v=a(10790),p="input";function m(e,t){t?e.indeterminate=!0:e.indeterminate&&(e.indeterminate=!1)}function h(e){return Array.isArray(e)?e.toString():e}var f=l.createHook.call(void 0,(function(e){var t=e,{store:a,name:l,value:f,checked:g,defaultChecked:w}=t,b=c.__objRest.call(void 0,t,["store","name","value","checked","defaultChecked"]);const y=r.useCheckboxContext.call(void 0);a=a||y;const[x,_]=d.useState.call(void 0,null!=w&&w),k=s.useStoreState.call(void 0,a,(e=>{if(void 0!==g)return g;if(void 0===(null==e?void 0:e.value))return x;if(null!=f){if(Array.isArray(e.value)){const t=h(f);return e.value.includes(t)}return e.value===f}return!Array.isArray(e.value)&&("boolean"==typeof e.value&&e.value)})),E=d.useRef.call(void 0,null),C=function(e,t){return"input"===e&&(!t||"checkbox"===t)}(i.useTagName.call(void 0,E,p),b.type),j=k?"mixed"===k:void 0,A="mixed"!==k&&k,S=u.disabledFromProps.call(void 0,b),[P,R]=i.useForceUpdate.call(void 0);d.useEffect.call(void 0,(()=>{const e=E.current;e&&(m(e,j),C||(e.checked=A,void 0!==l&&(e.name=l),void 0!==f&&(e.value=`${f}`)))}),[P,j,C,A,l,f]);const M=b.onChange,V=i.useEvent.call(void 0,(e=>{if(S)return e.stopPropagation(),void e.preventDefault();if(m(e.currentTarget,j),C||(e.currentTarget.checked=!e.currentTarget.checked,R()),null==M||M(e),e.defaultPrevented)return;const t=e.currentTarget.checked;_(t),null==a||a.setValue((e=>{if(null==f)return t;const a=h(f);return Array.isArray(e)?t?e.includes(a)?e:[...e,a]:e.filter((e=>e!==a)):e!==a&&a}))})),z=b.onClick,H=i.useEvent.call(void 0,(e=>{null==z||z(e),e.defaultPrevented||C||V(e)}));return b=i.useWrapElement.call(void 0,b,(e=>v.jsx.call(void 0,o.CheckboxCheckedContext.Provider,{value:A,children:e})),[A]),b=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{role:C?void 0:"checkbox",type:C?"checkbox":void 0,"aria-checked":k},b),{ref:i.useMergeRefs.call(void 0,E,b.ref),onChange:V,onClick:H}),b=n.useCommand.call(void 0,c.__spreadValues.call(void 0,{clickOnEnter:!C},b)),u.removeUndefinedValues.call(void 0,c.__spreadValues.call(void 0,{name:C?l:void 0,value:C?f:void 0,checked:A},b))})),g=l.forwardRef.call(void 0,(function(e){const t=f(e);return l.createElement.call(void 0,p,t)}));t.useCheckbox=f,t.Checkbox=g},65320:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(99366),n=a(44448),l=a(87636),s=a(80987),i=a(28148),c=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(11420));function u(e){const t=r.useComboboxProviderContext.call(void 0);return e=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{combobox:void 0!==e.combobox?e.combobox:t}),o.useCompositeStoreOptions.call(void 0,e)}function d(e,t,a){return s.useUpdateEffect.call(void 0,t,[a.combobox]),l.useStoreProps.call(void 0,e,a,"value","setValue"),l.useStoreProps.call(void 0,e,a,"setValueOnMove"),Object.assign(n.usePopoverStoreProps.call(void 0,o.useCompositeStoreProps.call(void 0,e,t,a),t,a),{combobox:a.combobox})}t.useSelectStoreOptions=u,t.useSelectStoreProps=d,t.useSelectStore=function(e={}){e=u(e);const[t,a]=l.useStore.call(void 0,c.createSelectStore,e);return d(t,a,e)}},19387:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(70663),o=a(33043),n=a(26327),l=a(48960),s=a(49464),i=a(99471),c=a(92725),u=a(60877),d=a(48959);function v(e,t){if(!("style"in e))return d.noop;if(l.supportsInert.call(void 0))return i.setProperty.call(void 0,e,"inert",!0);const a=u.getAllTabbableIn.call(void 0,e,!0).map((e=>{if(null==t?void 0:t.some((t=>t&&c.contains.call(void 0,t,e))))return d.noop;const a=i.orchestrate.call(void 0,e,"focus",(()=>(e.focus=d.noop,()=>{delete e.focus})));return d.chain.call(void 0,i.setAttribute.call(void 0,e,"tabindex","-1"),a)}));return d.chain.call(void 0,...a,o.hideElementFromAccessibilityTree.call(void 0,e),i.assignStyle.call(void 0,e,{pointerEvents:"none",userSelect:"none",cursor:"default"}))}t.disableTree=v,t.disableTreeOutside=function(e,t){const a=[],o=t.map((e=>null==e?void 0:e.id));return s.walkTreeOutside.call(void 0,e,t,(e=>{n.isBackdrop.call(void 0,e,...o)||r.isFocusTrap.call(void 0,e,...o)||a.unshift(v(e,t))}),(e=>{e.hasAttribute("role")&&(t.some((t=>t&&c.contains.call(void 0,t,e)))||a.unshift(i.setAttribute.call(void 0,e,"role","none")))})),()=>{for(const e of a)e()}}},64494:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652).createStoreContext.call(void 0,[r.CompositeContextProvider],[r.CompositeScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.useRadioContext=n,t.useRadioScopedContext=l,t.useRadioProviderContext=s,t.RadioContextProvider=i,t.RadioScopedContextProvider=c},42076:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(57870),o=a(19652),n=a(51609),l=o.createStoreContext.call(void 0,[r.CollectionContextProvider],[r.CollectionScopedContextProvider]),s=l.useContext,i=l.useScopedContext,c=l.useProviderContext,u=l.ContextProvider,d=l.ScopedContextProvider,v=n.createContext.call(void 0,void 0),p=n.createContext.call(void 0,void 0);t.useCompositeContext=s,t.useCompositeScopedContext=i,t.useCompositeProviderContext=c,t.CompositeContextProvider=u,t.CompositeScopedContextProvider=d,t.CompositeItemContext=v,t.CompositeRowContext=p},89930:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(54871),o=a(99366),n=a(44448),l=a(87636),s=a(80987),i=a(28148),c=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(45698));function u(e){const t=r.useTagContext.call(void 0);return e=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{tag:void 0!==e.tag?e.tag:t}),o.useCompositeStoreOptions.call(void 0,e)}function d(e,t,a){return s.useUpdateEffect.call(void 0,t,[a.tag]),l.useStoreProps.call(void 0,e,a,"value","setValue"),l.useStoreProps.call(void 0,e,a,"selectedValue","setSelectedValue"),l.useStoreProps.call(void 0,e,a,"resetValueOnHide"),l.useStoreProps.call(void 0,e,a,"resetValueOnSelect"),Object.assign(o.useCompositeStoreProps.call(void 0,n.usePopoverStoreProps.call(void 0,e,t,a),t,a),{tag:a.tag})}t.useComboboxStoreOptions=u,t.useComboboxStoreProps=d,t.useComboboxStore=function(e={}){e=u(e);const[t,a]=l.useStore.call(void 0,c.createComboboxStore,e);return d(t,a,e)}},21236:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(57870),o=a(19652),n=a(80987),l=a(28148),s=a(48959),i=a(51609),c=o.createHook.call(void 0,(function(e){var t=e,{store:a,shouldRegisterItem:o=!0,getItem:c=s.identity,element:u}=t,d=l.__objRest.call(void 0,t,["store","shouldRegisterItem","getItem","element"]);const v=r.useCollectionContext.call(void 0);a=a||v;const p=n.useId.call(void 0,d.id),m=i.useRef.call(void 0,u);return i.useEffect.call(void 0,(()=>{const e=m.current;if(!p)return;if(!e)return;if(!o)return;const t=c({id:p,element:e});return null==a?void 0:a.renderItem(t)}),[p,o,c,a]),d=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},d),{ref:n.useMergeRefs.call(void 0,m,d.ref)}),s.removeUndefinedValues.call(void 0,d)})),u=o.forwardRef.call(void 0,(function(e){const t=c(e);return o.createElement.call(void 0,"div",t)}));t.useCollectionItem=c,t.CollectionItem=u},68842:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80987),o=a(48959),n=a(8766),l=a(51609),s=a(10790),i=l.createContext.call(void 0,{});t.useNestedDialogs=function(e){const t=l.useContext.call(void 0,i),[a,c]=l.useState.call(void 0,[]),u=l.useCallback.call(void 0,(e=>{var a;return c((t=>[...t,e])),o.chain.call(void 0,null==(a=t.add)?void 0:a.call(t,e),(()=>{c((t=>t.filter((t=>t!==e))))}))}),[t]);r.useSafeLayoutEffect.call(void 0,(()=>n.sync.call(void 0,e,["open","contentElement"],(a=>{var r;if(a.open&&a.contentElement)return null==(r=t.add)?void 0:r.call(t,e)}))),[e,t]);const d=l.useMemo.call(void 0,(()=>({store:e,add:u})),[e,u]);return{wrapElement:l.useCallback.call(void 0,(e=>s.jsx.call(void 0,i.Provider,{value:d,children:e})),[d]),nestedDialogs:a}}},16299:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19652).createStoreContext.call(void 0),o=r.useContext,n=r.useScopedContext,l=r.useProviderContext,s=r.ContextProvider,i=r.ScopedContextProvider;t.useDisclosureContext=o,t.useDisclosureScopedContext=n,t.useDisclosureProviderContext=l,t.DisclosureContextProvider=s,t.DisclosureScopedContextProvider=i},91605:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77328),o=a(51609);t.usePreviousMouseDownRef=function(e){const t=o.useRef.call(void 0);return o.useEffect.call(void 0,(()=>{if(!e)return void(t.current=null);return r.addGlobalEventListener.call(void 0,"mousedown",(e=>{t.current=e.target}),!0)}),[e]),t}},60762:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(70419),o=a(53944),n=a(19652),l=a(80987),s=a(28148),i=a(51609),c=a(10790),u=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=s.__objRest.call(void 0,t,["store"]);const u=o.useDialogScopedContext.call(void 0);a=a||u;const d=n.onClick,v=l.useEvent.call(void 0,(e=>{null==d||d(e),e.defaultPrevented||null==a||a.hide()})),p=i.useMemo.call(void 0,(()=>c.jsxs.call(void 0,"svg",{"aria-label":"Dismiss popup",display:"block",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,viewBox:"0 0 16 16",height:"1em",width:"1em",children:[c.jsx.call(void 0,"line",{x1:"4",y1:"4",x2:"12",y2:"12"}),c.jsx.call(void 0,"line",{x1:"4",y1:"12",x2:"12",y2:"4"})]})),[]);return n=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{"data-dialog-dismiss":"",children:p},n),{onClick:v}),n=r.useButton.call(void 0,n)})),d=n.forwardRef.call(void 0,(function(e){const t=u(e);return n.createElement.call(void 0,"button",t)}));t.useDialogDismiss=u,t.DialogDismiss=d},7219:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(28148),o=a(48959),n=a(51609);function l(e){return!!e&&(!!n.isValidElement.call(void 0,e)&&("ref"in e.props||"ref"in e))}t.setRef=function(e,t){"function"==typeof e?e(t):e&&(e.current=t)},t.isValidElementWithRef=l,t.getRefProperty=function(e){return l(e)?r.__spreadValues.call(void 0,{},e.props).ref||e.ref:null},t.mergeProps=function(e,t){const a=r.__spreadValues.call(void 0,{},e);for(const n in t){if(!o.hasOwnProperty.call(void 0,t,n))continue;if("className"===n){const r="className";a[r]=e[r]?`${e[r]} ${t[r]}`:t[r];continue}if("style"===n){const o="style";a[o]=e[o]?r.__spreadValues.call(void 0,r.__spreadValues.call(void 0,{},e[o]),t[o]):t[o];continue}const l=t[n];if("function"==typeof l&&n.startsWith("on")){const t=e[n];if("function"==typeof t){a[n]=(...e)=>{l(...e),t(...e)};continue}}a[n]=l}return a}},33043:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(26327),o=a(49464),n=a(99471);function l(e){return n.setAttribute.call(void 0,e,"aria-hidden","true")}t.hideElementFromAccessibilityTree=l,t.disableAccessibilityTreeOutside=function(e,t){const a=[],n=t.map((e=>null==e?void 0:e.id));return o.walkTreeOutside.call(void 0,e,t,(e=>{r.isBackdrop.call(void 0,e,...n)||a.unshift(l(e))})),()=>{for(const e of a)e()}}},29842:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87121),o=a(19652),n=a(80987),l=a(28148),s=a(92725),i=a(77328),c=a(48959),u=a(32314),d=a(51609);function v(e){if(!e.isTrusted)return!1;const t=e.currentTarget;return"Enter"===e.key?s.isButton.call(void 0,t)||"SUMMARY"===t.tagName||"A"===t.tagName:" "===e.key&&(s.isButton.call(void 0,t)||"SUMMARY"===t.tagName||"INPUT"===t.tagName||"SELECT"===t.tagName)}var p=Symbol("command"),m=o.createHook.call(void 0,(function(e){var t=e,{clickOnEnter:a=!0,clickOnSpace:o=!0}=t,m=l.__objRest.call(void 0,t,["clickOnEnter","clickOnSpace"]);const h=d.useRef.call(void 0,null),[f,g]=d.useState.call(void 0,!1);d.useEffect.call(void 0,(()=>{h.current&&g(s.isButton.call(void 0,h.current))}),[]);const[w,b]=d.useState.call(void 0,!1),y=d.useRef.call(void 0,!1),x=c.disabledFromProps.call(void 0,m),[_,k]=n.useMetadataProps.call(void 0,m,p,!0),E=m.onKeyDown,C=n.useEvent.call(void 0,(e=>{null==E||E(e);const t=e.currentTarget;if(e.defaultPrevented)return;if(_)return;if(x)return;if(!i.isSelfTarget.call(void 0,e))return;if(s.isTextField.call(void 0,t))return;if(t.isContentEditable)return;const r=a&&"Enter"===e.key,n=o&&" "===e.key,c="Enter"===e.key&&!a,d=" "===e.key&&!o;if(c||d)e.preventDefault();else if(r||n){const a=v(e);if(r){if(!a){e.preventDefault();const a=e,{view:r}=a,o=l.__objRest.call(void 0,a,["view"]),n=()=>i.fireClickEvent.call(void 0,t,o);u.isFirefox.call(void 0)?i.queueBeforeEvent.call(void 0,t,"keyup",n):queueMicrotask(n)}}else n&&(y.current=!0,a||(e.preventDefault(),b(!0)))}})),j=m.onKeyUp,A=n.useEvent.call(void 0,(e=>{if(null==j||j(e),e.defaultPrevented)return;if(_)return;if(x)return;if(e.metaKey)return;const t=o&&" "===e.key;if(y.current&&t&&(y.current=!1,!v(e))){e.preventDefault(),b(!1);const t=e.currentTarget,a=e,{view:r}=a,o=l.__objRest.call(void 0,a,["view"]);queueMicrotask((()=>i.fireClickEvent.call(void 0,t,o)))}}));return m=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,l.__spreadValues.call(void 0,{"data-active":w||void 0,type:f?"button":void 0},k),m),{ref:n.useMergeRefs.call(void 0,h,m.ref),onKeyDown:C,onKeyUp:A}),m=r.useFocusable.call(void 0,m)})),h=o.forwardRef.call(void 0,(function(e){const t=m(e);return o.createElement.call(void 0,"button",t)}));t.useCommand=m,t.Command=h},57870:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19652).createStoreContext.call(void 0),o=r.useContext,n=r.useScopedContext,l=r.useProviderContext,s=r.ContextProvider,i=r.ScopedContextProvider;t.useCollectionContext=o,t.useCollectionScopedContext=n,t.useCollectionProviderContext=l,t.CollectionContextProvider=s,t.CollectionScopedContextProvider=i},12204:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(85325),o=a(77723),n=a(12707),l=a(38980),s=a(87636),i=a(80987),c=a(28148),u=a(51609),d=a(10790);t.DialogBackdrop=function({store:e,backdrop:t,alwaysVisible:a,hidden:v}){const p=u.useRef.call(void 0,null),m=l.useDisclosureStore.call(void 0,{disclosure:e}),h=s.useStoreState.call(void 0,e,"contentElement");u.useEffect.call(void 0,(()=>{const e=p.current,t=h;e&&t&&(e.style.zIndex=getComputedStyle(t).zIndex)}),[h]),i.useSafeLayoutEffect.call(void 0,(()=>{const e=null==h?void 0:h.id;if(!e)return;const t=p.current;return t?r.markAncestor.call(void 0,t,e):void 0}),[h]);const f=o.useDisclosureContent.call(void 0,{ref:p,store:m,role:"presentation","data-backdrop":(null==h?void 0:h.id)||"",alwaysVisible:a,hidden:null!=v?v:void 0,style:{position:"fixed",top:0,right:0,bottom:0,left:0}});if(!t)return null;if(u.isValidElement.call(void 0,t))return d.jsx.call(void 0,n.Role,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{},f),{render:t}));const g="boolean"!=typeof t?t:"div";return d.jsx.call(void 0,n.Role,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{},f),{render:d.jsx.call(void 0,g,{})}))}},49190:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(56203),o=a(53944),n=a(19652),l=a(28148),s=a(92725),i=a(48959),c=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const c=o.useDialogProviderContext.call(void 0);a=a||c,i.invariant.call(void 0,a,!1);const u=a.useState("contentElement");return n=l.__spreadValues.call(void 0,{"aria-haspopup":s.getPopupRole.call(void 0,u,"dialog")},n),n=r.useDisclosure.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),u=n.forwardRef.call(void 0,(function(e){const t=c(e);return n.createElement.call(void 0,"button",t)}));t.useDialogDisclosure=c,t.DialogDisclosure=u},50864:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(85171),o=a(19652),n=a(80987),l=a(28148),s=a(48959),i=a(51609),c=o.createHook.call(void 0,(function(e){const t=i.useContext.call(void 0,r.GroupLabelContext),a=n.useId.call(void 0,e.id);return n.useSafeLayoutEffect.call(void 0,(()=>(null==t||t(a),()=>null==t?void 0:t(void 0))),[t,a]),e=l.__spreadValues.call(void 0,{id:a,"aria-hidden":!0},e),s.removeUndefinedValues.call(void 0,e)})),u=o.forwardRef.call(void 0,(function(e){const t=c(e);return o.createElement.call(void 0,"div",t)}));t.useGroupLabel=c,t.GroupLabel=u},48427:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652),n=a(51609),l=o.createStoreContext.call(void 0,[r.CompositeContextProvider],[r.CompositeScopedContextProvider]),s=l.useContext,i=l.useScopedContext,c=l.useProviderContext,u=l.ContextProvider,d=l.ScopedContextProvider,v=n.createContext.call(void 0,void 0);t.useMenubarContext=s,t.useMenubarScopedContext=i,t.useMenubarProviderContext=c,t.MenubarContextProvider=u,t.MenubarScopedContextProvider=d,t.MenuItemCheckedContext=v},59190:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(50864),o=a(19652),n=a(28148),l=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=n.__objRest.call(void 0,t,["store"]);return o=r.useGroupLabel.call(void 0,o)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"div",t)}));t.useCompositeGroupLabel=l,t.CompositeGroupLabel=s},35174:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(63215),o=a(19652),n=a(80987),l=a(28148),s=a(51609),i=a(10790),c=o.createHook.call(void 0,(function(e){const t=s.useRef.call(void 0,null),a=s.useContext.call(void 0,r.HeadingContext)||1,o=`h${a}`,c=n.useTagName.call(void 0,t,o),u=s.useMemo.call(void 0,(()=>!!c&&/^h\d$/.test(c)),[c]);return e=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{render:i.jsx.call(void 0,o,{}),role:u?void 0:"heading","aria-level":u?void 0:a},e),{ref:n.useMergeRefs.call(void 0,t,e.ref)})})),u=o.forwardRef.call(void 0,(function(e){const t=c(e);return o.createElement.call(void 0,"h1",t)}));t.useHeading=c,t.Heading=u},58058:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99992),o=a(19652),n=o.createHook.call(void 0,(function(e){return e=r.useDialogDescription.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"p",t)}));t.usePopoverDescription=n,t.PopoverDescription=l},67804:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51609).createContext.call(void 0,!1);t.CheckboxCheckedContext=r},9229:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(40227),o=a(42076),n=a(87121),l=a(19652),s=a(80987),i=a(28148),c=a(11790),u=a(92725),d=a(77328),v=a(60877),p=a(48959),m=a(51609),h=a(10790);function f(e,t,a){return s.useEvent.call(void 0,(o=>{var n;if(null==t||t(o),o.defaultPrevented)return;if(o.isPropagationStopped())return;if(!d.isSelfTarget.call(void 0,o))return;if(function(e){return"Shift"===e.key||"Control"===e.key||"Alt"===e.key||"Meta"===e.key}(o))return;if(function(e){const t=e.target;return!(t&&!u.isTextField.call(void 0,t)||1!==e.key.length||e.ctrlKey||e.metaKey)}(o))return;const l=e.getState(),s=null==(n=r.getEnabledItem.call(void 0,e,l.activeId))?void 0:n.element;if(!s)return;const c=o,{view:v}=c,p=i.__objRest.call(void 0,c,["view"]);s!==(null==a?void 0:a.current)&&s.focus(),d.fireKeyboardEvent.call(void 0,s,o.type,p)||o.preventDefault(),o.currentTarget.contains(s)&&o.stopPropagation()}))}var g=l.createHook.call(void 0,(function(e){var t=e,{store:a,composite:l=!0,focusOnMove:g=l,moveOnKeyPress:w=!0}=t,b=i.__objRest.call(void 0,t,["store","composite","focusOnMove","moveOnKeyPress"]);const y=o.useCompositeProviderContext.call(void 0);a=a||y,p.invariant.call(void 0,a,!1);const x=m.useRef.call(void 0,null),_=m.useRef.call(void 0,null),k=function(e){const[t,a]=m.useState.call(void 0,!1),o=m.useCallback.call(void 0,(()=>a(!0)),[]),n=e.useState((t=>r.getEnabledItem.call(void 0,e,t.activeId)));return m.useEffect.call(void 0,(()=>{const e=null==n?void 0:n.element;t&&e&&(a(!1),e.focus({preventScroll:!0}))}),[n,t]),o}(a),E=a.useState("moves"),[,C]=s.useTransactionState.call(void 0,l?a.setBaseElement:null);m.useEffect.call(void 0,(()=>{var e;if(!a)return;if(!E)return;if(!l)return;if(!g)return;const{activeId:t}=a.getState(),o=null==(e=r.getEnabledItem.call(void 0,a,t))?void 0:e.element;o&&v.focusIntoView.call(void 0,o)}),[a,E,l,g]),s.useSafeLayoutEffect.call(void 0,(()=>{if(!a)return;if(!E)return;if(!l)return;const{baseElement:e,activeId:t}=a.getState();if(!(null===t))return;if(!e)return;const r=_.current;_.current=null,r&&d.fireBlurEvent.call(void 0,r,{relatedTarget:e}),v.hasFocus.call(void 0,e)||e.focus()}),[a,E,l]);const j=a.useState("activeId"),A=a.useState("virtualFocus");s.useSafeLayoutEffect.call(void 0,(()=>{var e;if(!a)return;if(!l)return;if(!A)return;const t=_.current;if(_.current=null,!t)return;const o=(null==(e=r.getEnabledItem.call(void 0,a,j))?void 0:e.element)||u.getActiveElement.call(void 0,t);o!==t&&d.fireBlurEvent.call(void 0,t,{relatedTarget:o})}),[a,j,A,l]);const S=f(a,b.onKeyDownCapture,_),P=f(a,b.onKeyUpCapture,_),R=b.onFocusCapture,M=s.useEvent.call(void 0,(e=>{if(null==R||R(e),e.defaultPrevented)return;if(!a)return;const{virtualFocus:t}=a.getState();if(!t)return;const o=e.relatedTarget,n=r.silentlyFocused.call(void 0,e.currentTarget);d.isSelfTarget.call(void 0,e)&&n&&(e.stopPropagation(),_.current=o)})),V=b.onFocus,z=s.useEvent.call(void 0,(e=>{if(null==V||V(e),e.defaultPrevented)return;if(!l)return;if(!a)return;const{relatedTarget:t}=e,{virtualFocus:o}=a.getState();o?d.isSelfTarget.call(void 0,e)&&!r.isItem.call(void 0,a,t)&&queueMicrotask(k):d.isSelfTarget.call(void 0,e)&&a.setActiveId(null)})),H=b.onBlurCapture,L=s.useEvent.call(void 0,(e=>{var t;if(null==H||H(e),e.defaultPrevented)return;if(!a)return;const{virtualFocus:o,activeId:n}=a.getState();if(!o)return;const l=null==(t=r.getEnabledItem.call(void 0,a,n))?void 0:t.element,s=e.relatedTarget,i=r.isItem.call(void 0,a,s),c=_.current;if(_.current=null,d.isSelfTarget.call(void 0,e)&&i)s===l?c&&c!==s&&d.fireBlurEvent.call(void 0,c,e):l?d.fireBlurEvent.call(void 0,l,e):c&&d.fireBlurEvent.call(void 0,c,e),e.stopPropagation();else{!r.isItem.call(void 0,a,e.target)&&l&&d.fireBlurEvent.call(void 0,l,e)}})),O=b.onKeyDown,N=s.useBooleanEvent.call(void 0,w),I=s.useEvent.call(void 0,(e=>{var t;if(null==O||O(e),e.defaultPrevented)return;if(!a)return;if(!d.isSelfTarget.call(void 0,e))return;const{orientation:o,renderedItems:n,activeId:l}=a.getState(),s=r.getEnabledItem.call(void 0,a,l);if(null==(t=null==s?void 0:s.element)?void 0:t.isConnected)return;const i="horizontal"!==o,v="vertical"!==o,p=n.some((e=>!!e.rowId));if(("ArrowLeft"===e.key||"ArrowRight"===e.key||"Home"===e.key||"End"===e.key)&&u.isTextField.call(void 0,e.currentTarget))return;const m={ArrowUp:(p||i)&&(()=>{if(p){const e=function(e){return r.findFirstEnabledItem.call(void 0,c.flatten2DArray.call(void 0,c.reverseArray.call(void 0,r.groupItemsByRows.call(void 0,e))))}(n);return null==e?void 0:e.id}return null==a?void 0:a.last()}),ArrowRight:(p||v)&&a.first,ArrowDown:(p||i)&&a.first,ArrowLeft:(p||v)&&a.last,Home:a.first,End:a.last,PageUp:a.first,PageDown:a.last},h=m[e.key];if(h){const t=h();if(void 0!==t){if(!N(e))return;e.preventDefault(),a.move(t)}}}));b=s.useWrapElement.call(void 0,b,(e=>h.jsx.call(void 0,o.CompositeContextProvider,{value:a,children:e})),[a]);const B=a.useState((e=>{var t;if(a&&l&&e.virtualFocus)return null==(t=r.getEnabledItem.call(void 0,a,e.activeId))?void 0:t.id}));b=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{"aria-activedescendant":B},b),{ref:s.useMergeRefs.call(void 0,x,C,b.ref),onKeyDownCapture:S,onKeyUpCapture:P,onFocusCapture:M,onFocus:z,onBlurCapture:L,onKeyDown:I});const T=a.useState((e=>l&&(e.virtualFocus||null===e.activeId)));return b=n.useFocusable.call(void 0,i.__spreadValues.call(void 0,{focusable:T},b))})),w=l.forwardRef.call(void 0,(function(e){const t=g(e);return l.createElement.call(void 0,"div",t)}));t.useComposite=g,t.Composite=w},25275:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(35973),o=a(66485),n=a(19652),l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useToolbarContext.call(void 0);return a=a||s,n=r.useCompositeItem.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"button",t)})));t.useToolbarItem=s,t.ToolbarItem=i},63215:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51609).createContext.call(void 0,0);t.HeadingContext=r},7168:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(48427),o=a(42076),n=a(80231),l=a(19652),s=a(51609),i=l.createStoreContext.call(void 0,[o.CompositeContextProvider,n.HovercardContextProvider],[o.CompositeScopedContextProvider,n.HovercardScopedContextProvider]),c=i.useContext,u=i.useScopedContext,d=i.useProviderContext,v=i.ContextProvider,p=i.ScopedContextProvider,m=r.useMenubarContext,h=r.useMenubarScopedContext,f=r.useMenubarProviderContext,g=r.MenubarContextProvider,w=r.MenubarScopedContextProvider,b=s.createContext.call(void 0,void 0);t.useMenuContext=c,t.useMenuScopedContext=u,t.useMenuProviderContext=d,t.MenuContextProvider=v,t.MenuScopedContextProvider=p,t.useMenuBarContext=m,t.useMenuBarScopedContext=h,t.useMenuBarProviderContext=f,t.MenuBarContextProvider=g,t.MenuBarScopedContextProvider=w,t.MenuItemCheckedContext=b},54871:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652),n=a(51609),l=n.createContext.call(void 0,null),s=n.createContext.call(void 0,null),i=o.createStoreContext.call(void 0,[r.CompositeContextProvider],[r.CompositeScopedContextProvider]),c=i.useContext,u=i.useScopedContext,d=i.useProviderContext,v=i.ContextProvider,p=i.ScopedContextProvider;t.TagValueContext=l,t.TagRemoveIdContext=s,t.useTagContext=c,t.useTagScopedContext=u,t.useTagProviderContext=d,t.TagContextProvider=v,t.TagScopedContextProvider=p},89169:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80987),o=a(92725),n=a(51609),l=a(75795);t.useRootDialog=function({attribute:e,contentId:t,contentElement:a,enabled:s}){const[i,c]=r.useForceUpdate.call(void 0),u=n.useCallback.call(void 0,(()=>{if(!s)return!1;if(!a)return!1;const{body:r}=o.getDocument.call(void 0,a),n=r.getAttribute(e);return!n||n===t}),[i,s,a,e,t]);return n.useEffect.call(void 0,(()=>{if(!s)return;if(!t)return;if(!a)return;const{body:r}=o.getDocument.call(void 0,a);if(u())return r.setAttribute(e,t),()=>r.removeAttribute(e);const n=new MutationObserver((()=>l.flushSync.call(void 0,c)));return n.observe(r,{attributeFilter:[e]}),()=>n.disconnect()}),[i,s,t,a,u,e]),u}},80231:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77018),o=a(19652).createStoreContext.call(void 0,[r.PopoverContextProvider],[r.PopoverScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.useHovercardContext=n,t.useHovercardScopedContext=l,t.useHovercardProviderContext=s,t.HovercardContextProvider=i,t.HovercardScopedContextProvider=c},61150:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652),n=a(80987),l=a(28148),s=a(92725),i=a(60877),c=a(48959),u=a(51609);function d(e){const t=e.relatedTarget;return(null==t?void 0:t.nodeType)===Node.ELEMENT_NODE?t:null}var v=Symbol("composite-hover");var p=o.createHook.call(void 0,(function(e){var t=e,{store:a,focusOnHover:o=!0,blurOnHoverEnd:p=!!o}=t,m=l.__objRest.call(void 0,t,["store","focusOnHover","blurOnHoverEnd"]);const h=r.useCompositeContext.call(void 0);a=a||h,c.invariant.call(void 0,a,!1);const f=n.useIsMouseMoving.call(void 0),g=m.onMouseMove,w=n.useBooleanEvent.call(void 0,o),b=n.useEvent.call(void 0,(e=>{if(null==g||g(e),!e.defaultPrevented&&f()&&w(e)){if(!i.hasFocusWithin.call(void 0,e.currentTarget)){const e=null==a?void 0:a.getState().baseElement;e&&!i.hasFocus.call(void 0,e)&&e.focus()}null==a||a.setActiveId(e.currentTarget.id)}})),y=m.onMouseLeave,x=n.useBooleanEvent.call(void 0,p),_=n.useEvent.call(void 0,(e=>{var t;null==y||y(e),e.defaultPrevented||f()&&(function(e){const t=d(e);return!!t&&s.contains.call(void 0,e.currentTarget,t)}(e)||function(e){let t=d(e);if(!t)return!1;do{if(c.hasOwnProperty.call(void 0,t,v)&&t[v])return!0;t=t.parentElement}while(t);return!1}(e)||w(e)&&x(e)&&(null==a||a.setActiveId(null),null==(t=null==a?void 0:a.getState().baseElement)||t.focus()))})),k=u.useCallback.call(void 0,(e=>{e&&(e[v]=!0)}),[]);return m=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},m),{ref:n.useMergeRefs.call(void 0,k,m.ref),onMouseMove:b,onMouseLeave:_}),c.removeUndefinedValues.call(void 0,m)})),m=o.memo.call(void 0,o.forwardRef.call(void 0,(function(e){const t=p(e);return o.createElement.call(void 0,"div",t)})));t.useCompositeHover=p,t.CompositeHover=m},87121:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(73579),o=a(19652),n=a(80987),l=a(28148),s=a(92725),i=a(77328),c=a(60877),u=a(48959),d=a(32314),v=a(51609),p=d.isSafari.call(void 0),m=["text","search","url","tel","email","password","number","date","month","week","time","datetime","datetime-local"],h=Symbol("safariFocusAncestor");function f(e,t){e&&(e[h]=t)}function g(e){return!("input"!==e.tagName.toLowerCase()||!e.type)&&("radio"===e.type||"checkbox"===e.type)}function w(e,t,a,r,o){return e?t?a&&!r?-1:void 0:a?o:o||0:o}function b(e,t){return n.useEvent.call(void 0,(a=>{null==e||e(a),a.defaultPrevented||t&&(a.stopPropagation(),a.preventDefault())}))}var y=!0;function x(e){const t=e.target;t&&"hasAttribute"in t&&(t.hasAttribute("data-focus-visible")||(y=!1))}function _(e){e.metaKey||e.ctrlKey||e.altKey||(y=!0)}var k=o.createHook.call(void 0,(function(e){var t=e,{focusable:a=!0,accessibleWhenDisabled:o,autoFocus:d,onFocusVisible:h}=t,k=l.__objRest.call(void 0,t,["focusable","accessibleWhenDisabled","autoFocus","onFocusVisible"]);const E=v.useRef.call(void 0,null);v.useEffect.call(void 0,(()=>{a&&(i.addGlobalEventListener.call(void 0,"mousedown",x,!0),i.addGlobalEventListener.call(void 0,"keydown",_,!0))}),[a]),p&&v.useEffect.call(void 0,(()=>{if(!a)return;const e=E.current;if(!e)return;if(!g(e))return;const t=function(e){return"labels"in e?e.labels:null}(e);if(!t)return;const r=()=>queueMicrotask((()=>e.focus()));for(const e of t)e.addEventListener("mouseup",r);return()=>{for(const e of t)e.removeEventListener("mouseup",r)}}),[a]);const C=a&&u.disabledFromProps.call(void 0,k),j=!!C&&!o,[A,S]=v.useState.call(void 0,!1);v.useEffect.call(void 0,(()=>{a&&j&&A&&S(!1)}),[a,j,A]),v.useEffect.call(void 0,(()=>{if(!a)return;if(!A)return;const e=E.current;if(!e)return;if("undefined"==typeof IntersectionObserver)return;const t=new IntersectionObserver((()=>{c.isFocusable.call(void 0,e)||S(!1)}));return t.observe(e),()=>t.disconnect()}),[a,A]);const P=b(k.onKeyPressCapture,C),R=b(k.onMouseDownCapture,C),M=b(k.onClickCapture,C),V=k.onMouseDown,z=n.useEvent.call(void 0,(e=>{if(null==V||V(e),e.defaultPrevented)return;if(!a)return;const t=e.currentTarget;if(!p)return;if(i.isPortalEvent.call(void 0,e))return;if(!s.isButton.call(void 0,t)&&!g(t))return;let r=!1;const o=()=>{r=!0};t.addEventListener("focusin",o,{capture:!0,once:!0});const n=c.getClosestFocusable.call(void 0,t.parentElement);f(n,!0),i.queueBeforeEvent.call(void 0,t,"mouseup",(()=>{t.removeEventListener("focusin",o,!0),f(n,!1),r||c.focusIfNeeded.call(void 0,t)}))})),H=(e,t)=>{if(t&&(e.currentTarget=t),!a)return;const r=e.currentTarget;r&&c.hasFocus.call(void 0,r)&&(null==h||h(e),e.defaultPrevented||(r.dataset.focusVisible="true",S(!0)))},L=k.onKeyDownCapture,O=n.useEvent.call(void 0,(e=>{if(null==L||L(e),e.defaultPrevented)return;if(!a)return;if(A)return;if(e.metaKey)return;if(e.altKey)return;if(e.ctrlKey)return;if(!i.isSelfTarget.call(void 0,e))return;const t=e.currentTarget;i.queueBeforeEvent.call(void 0,t,"focusout",(()=>H(e,t)))})),N=k.onFocusCapture,I=n.useEvent.call(void 0,(e=>{if(null==N||N(e),e.defaultPrevented)return;if(!a)return;if(!i.isSelfTarget.call(void 0,e))return void S(!1);const t=e.currentTarget,r=()=>H(e,t);y||function(e){const{tagName:t,readOnly:a,type:r}=e;return"TEXTAREA"===t&&!a||("SELECT"===t&&!a||("INPUT"!==t||a?!!e.isContentEditable||!("combobox"!==e.getAttribute("role")||!e.dataset.name):m.includes(r)))}(e.target)?i.queueBeforeEvent.call(void 0,e.target,"focusout",r):S(!1)})),B=k.onBlur,T=n.useEvent.call(void 0,(e=>{null==B||B(e),a&&i.isFocusEventOutside.call(void 0,e)&&S(!1)})),F=v.useContext.call(void 0,r.FocusableContext),D=n.useEvent.call(void 0,(e=>{a&&d&&e&&F&&queueMicrotask((()=>{c.hasFocus.call(void 0,e)||c.isFocusable.call(void 0,e)&&e.focus()}))})),G=n.useTagName.call(void 0,E),U=a&&function(e){return!e||"button"===e||"summary"===e||"input"===e||"select"===e||"textarea"===e||"a"===e}(G),q=a&&function(e){return!e||"button"===e||"input"===e||"select"===e||"textarea"===e}(G),Z=k.style,W=v.useMemo.call(void 0,(()=>j?l.__spreadValues.call(void 0,{pointerEvents:"none"},Z):Z),[j,Z]);return k=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{"data-focus-visible":a&&A||void 0,"data-autofocus":d||void 0,"aria-disabled":C||void 0},k),{ref:n.useMergeRefs.call(void 0,E,D,k.ref),style:W,tabIndex:w(a,j,U,q,k.tabIndex),disabled:!(!q||!j)||void 0,contentEditable:C?void 0:k.contentEditable,onKeyPressCapture:P,onClickCapture:M,onMouseDownCapture:R,onMouseDown:z,onKeyDownCapture:O,onFocusCapture:I,onBlur:T}),u.removeUndefinedValues.call(void 0,k)})),E=o.forwardRef.call(void 0,(function(e){const t=k(e);return o.createElement.call(void 0,"div",t)}));t.isSafariFocusAncestor=function(e){return!!e&&!!e[h]},t.useFocusable=k,t.Focusable=E},80987:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7219),o=a(28148),n=a(92725),l=a(77328),s=a(51609),i=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(s),c=o.__spreadValues.call(void 0,{},i),u=c.useId,d=c.useDeferredValue,v=c.useInsertionEffect,p=n.canUseDOM?s.useLayoutEffect:s.useEffect;function m(e){const[t]=s.useState.call(void 0,e);return t}function h(e){const t=s.useRef.call(void 0,(()=>{throw new Error("Cannot call an event handler while rendering.")}));return v?v((()=>{t.current=e})):t.current=e,s.useCallback.call(void 0,((...e)=>{var a;return null==(a=t.current)?void 0:a.call(t,...e)}),[])}function f(...e){return s.useMemo.call(void 0,(()=>{if(e.some(Boolean))return t=>{for(const a of e)r.setRef.call(void 0,a,t)}}),e)}var g=!1,w=0,b=0;function y(e){(function(e){const t=e.movementX||e.screenX-w,a=e.movementY||e.screenY-b;return w=e.screenX,b=e.screenY,t||a||!1})(e)&&(g=!0)}function x(){g=!1}t.useSafeLayoutEffect=p,t.useInitialValue=m,t.useLazyValue=function(e){const t=s.useRef.call(void 0);return void 0===t.current&&(t.current=e()),t.current},t.useLiveRef=function(e){const t=s.useRef.call(void 0,e);return p((()=>{t.current=e})),t},t.usePreviousValue=function(e){const[t,a]=s.useState.call(void 0,e);return e!==t&&a(e),t},t.useEvent=h,t.useTransactionState=function(e){const[t,a]=s.useState.call(void 0,null);return p((()=>{if(null==t)return;if(!e)return;let a=null;return e((e=>(a=e,t))),()=>{e(a)}}),[t,e]),[t,a]},t.useMergeRefs=f,t.useId=function(e){if(u){const t=u();return e||t}const[t,a]=s.useState.call(void 0,e);return p((()=>{if(e||t)return;const r=Math.random().toString(36).slice(2,8);a(`id-${r}`)}),[e,t]),e||t},t.useDeferredValue=function(e){if(d)return d(e);const[t,a]=s.useState.call(void 0,e);return s.useEffect.call(void 0,(()=>{const t=requestAnimationFrame((()=>a(e)));return()=>cancelAnimationFrame(t)}),[e]),t},t.useTagName=function(e,t){const a=e=>{if("string"==typeof e)return e},[r,o]=s.useState.call(void 0,(()=>a(t)));return p((()=>{const r=e&&"current"in e?e.current:e;o((null==r?void 0:r.tagName.toLowerCase())||a(t))}),[e,t]),r},t.useAttribute=function(e,t,a){const r=m(a),[o,n]=s.useState.call(void 0,r);return s.useEffect.call(void 0,(()=>{const a=e&&"current"in e?e.current:e;if(!a)return;const o=()=>{const e=a.getAttribute(t);n(null==e?r:e)},l=new MutationObserver(o);return l.observe(a,{attributeFilter:[t]}),o(),()=>l.disconnect()}),[e,t,r]),o},t.useUpdateEffect=function(e,t){const a=s.useRef.call(void 0,!1);s.useEffect.call(void 0,(()=>{if(a.current)return e();a.current=!0}),t),s.useEffect.call(void 0,(()=>()=>{a.current=!1}),[])},t.useUpdateLayoutEffect=function(e,t){const a=s.useRef.call(void 0,!1);p((()=>{if(a.current)return e();a.current=!0}),t),p((()=>()=>{a.current=!1}),[])},t.useForceUpdate=function(){return s.useReducer.call(void 0,(()=>[]),[])},t.useBooleanEvent=function(e){return h("function"==typeof e?e:()=>e)},t.useWrapElement=function(e,t,a=[]){const r=s.useCallback.call(void 0,(a=>(e.wrapElement&&(a=e.wrapElement(a)),t(a))),[...a,e.wrapElement]);return o.__spreadProps.call(void 0,o.__spreadValues.call(void 0,{},e),{wrapElement:r})},t.usePortalRef=function(e=!1,t){const[a,r]=s.useState.call(void 0,null);return{portalRef:f(r,t),portalNode:a,domReady:!e||a}},t.useMetadataProps=function(e,t,a){const r=e.onLoadedMetadataCapture,n=s.useMemo.call(void 0,(()=>Object.assign((()=>{}),o.__spreadProps.call(void 0,o.__spreadValues.call(void 0,{},r),{[t]:a}))),[r,t,a]);return[null==r?void 0:r[t],{onLoadedMetadataCapture:n}]},t.useIsMouseMoving=function(){return s.useEffect.call(void 0,(()=>{l.addGlobalEventListener.call(void 0,"mousemove",y,!0),l.addGlobalEventListener.call(void 0,"mousedown",x,!0),l.addGlobalEventListener.call(void 0,"mouseup",x,!0),l.addGlobalEventListener.call(void 0,"keydown",x,!0),l.addGlobalEventListener.call(void 0,"scroll",x,!0)}),[]),h((()=>g))}},32146:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(63215),o=a(51609),n=a(10790);t.HeadingLevel=function({level:e,children:t}){const a=o.useContext.call(void 0,r.HeadingContext),l=Math.max(Math.min(e||a+1,6),1);return n.jsx.call(void 0,r.HeadingContext.Provider,{value:l,children:t})}},68725:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getEventPoint=function(e){return[e.clientX,e.clientY]},t.isPointInPolygon=function(e,t){const[a,r]=e;let o=!1;for(let e=t.length,n=0,l=e-1;n=u&&r0&&(r===u?r>d&&(o=!o):o=!o)}}else if(ii&&r<=u){if(0===v)return!0;v<0&&(r===u?r=c&&a<=s||a>=s&&a<=c))return!0}return o},t.getElementPolygon=function(e,t){const a=e.getBoundingClientRect(),{top:r,right:o,bottom:n,left:l}=a,[s,i]=function(e,t){const{top:a,right:r,bottom:o,left:n}=t,[l,s]=e;return[lr?"right":null,so?"bottom":null]}(t,a),c=[t];return s?("top"!==i&&c.push(["left"===s?l:o,r]),c.push(["left"===s?o:l,r]),c.push(["left"===s?o:l,n]),"bottom"!==i&&c.push(["left"===s?l:o,n])):"top"===i?(c.push([l,r]),c.push([l,n]),c.push([o,n]),c.push([o,r])):(c.push([l,n]),c.push([l,r]),c.push([o,r]),c.push([o,n])),c}},46503:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77673),o=a(72707),n=a(19652),l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useSelectContext.call(void 0);return a=a||s,n=r.usePopoverDisclosureArrow.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"span",t)}));t.useSelectArrow=s,t.SelectArrow=i},92526:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168),o=a(48427),n=a(61150),l=a(35973),s=a(19652),i=a(87636),c=a(80987),u=a(28148),d=a(92725),v=a(77328),p=a(60877),m=a(48959);var h=s.createHook.call(void 0,(function(e){var t=e,{store:a,hideOnClick:s=!0,preventScrollOnKeyDown:h=!0,focusOnHover:f,blurOnHoverEnd:g}=t,w=u.__objRest.call(void 0,t,["store","hideOnClick","preventScrollOnKeyDown","focusOnHover","blurOnHoverEnd"]);const b=r.useMenuScopedContext.call(void 0,!0),y=o.useMenubarScopedContext.call(void 0);a=a||b||y,m.invariant.call(void 0,a,!1);const x=w.onClick,_=c.useBooleanEvent.call(void 0,s),k="hideAll"in a?a.hideAll:void 0,E=!!k,C=c.useEvent.call(void 0,(e=>{if(null==x||x(e),e.defaultPrevented)return;if(v.isDownloading.call(void 0,e))return;if(v.isOpeningInNewTab.call(void 0,e))return;if(!k)return;"menu"!==e.currentTarget.getAttribute("aria-haspopup")&&_(e)&&k()})),j=i.useStoreState.call(void 0,a,(e=>"contentElement"in e?e.contentElement:null)),A=d.getPopupItemRole.call(void 0,j,"menuitem");return w=u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{role:A},w),{onClick:C}),w=l.useCompositeItem.call(void 0,u.__spreadValues.call(void 0,{store:a,preventScrollOnKeyDown:h},w)),w=n.useCompositeHover.call(void 0,u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{store:a},w),{focusOnHover(e){if(!a)return!1;if(!("function"==typeof f?f(e):null==f||f))return!1;const{baseElement:t,items:r}=a.getState();return E?(e.currentTarget.hasAttribute("aria-expanded")&&e.currentTarget.focus(),!0):!!function(e,t,a){var r;if(!e)return!1;if(p.hasFocusWithin.call(void 0,e))return!0;const o=null==t?void 0:t.find((e=>{var t;return e.element!==a&&"true"===(null==(t=e.element)?void 0:t.getAttribute("aria-expanded"))})),n=null==(r=null==o?void 0:o.element)?void 0:r.getAttribute("aria-controls");if(!n)return!1;const l=d.getDocument.call(void 0,e).getElementById(n);return!(!l||!p.hasFocusWithin.call(void 0,l)&&!l.querySelector("[role=menuitem][aria-expanded=true]"))}(t,r,e.currentTarget)&&(e.currentTarget.focus(),!0)},blurOnHoverEnd:e=>"function"==typeof g?g(e):null!=g?g:E})),w})),f=s.memo.call(void 0,s.forwardRef.call(void 0,(function(e){const t=h(e);return s.createElement.call(void 0,"div",t)})));t.useMenuItem=h,t.MenuItem=f},33356:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(22510),o=a(19652),n=o.createHook.call(void 0,(function(e){return e=r.useDialogHeading.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"h1",t)}));t.usePopoverHeading=n,t.PopoverHeading=l},54844:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(3578),o=a(19652),n=a(28148),l=o.createHook.call(void 0,(function(e){return e=n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{"data-focus-trap":"",tabIndex:0,"aria-hidden":!0},e),{style:n.__spreadValues.call(void 0,{position:"fixed",top:0,left:0},e.style)}),e=r.useVisuallyHidden.call(void 0,e)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"span",t)}));t.useFocusTrap=l,t.FocusTrap=s},40227:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(92725),o={id:null};var n=Symbol("FOCUS_SILENTLY");t.flipItems=function(e,t,a=!1){const r=e.findIndex((e=>e.id===t));return[...e.slice(r+1),...a?[o]:[],...e.slice(0,r)]},t.findFirstEnabledItem=function(e,t){return e.find((e=>t?!e.disabled&&e.id!==t:!e.disabled))},t.getEnabledItem=function(e,t){return t&&e.item(t)||null},t.groupItemsByRows=function(e){const t=[];for(const a of e){const e=t.find((e=>{var t;return(null==(t=e[0])?void 0:t.rowId)===a.rowId}));e?e.push(a):t.push([a])}return t},t.selectTextField=function(e,t=!1){if(r.isTextField.call(void 0,e))e.setSelectionRange(t?e.value.length:0,e.value.length);else if(e.isContentEditable){const a=r.getDocument.call(void 0,e).getSelection();null==a||a.selectAllChildren(e),t&&(null==a||a.collapseToEnd())}},t.focusSilently=function(e){e[n]=!0,e.focus({preventScroll:!0})},t.silentlyFocused=function(e){const t=e[n];return delete e[n],t},t.isItem=function(e,t,a){if(!t)return!1;if(t===a)return!1;const r=e.item(t.id);return!!r&&(!a||r.element!==a)}},35973:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21236),o=a(29842),n=a(40227),l=a(42076),s=a(19652),i=a(87636),c=a(80987),u=a(28148),d=a(92725),v=a(77328),p=a(48959),m=a(32314),h=a(51609),f=a(10790);function g(e,t=!1){const{top:a}=e.getBoundingClientRect();return t?a+e.clientHeight:a}function w(e,t,a,r=!1){var o;if(!t)return;if(!a)return;const{renderedItems:l}=t.getState(),s=d.getScrollingElement.call(void 0,e);if(!s)return;const i=function(e,t=!1){const a=e.clientHeight,{top:r}=e.getBoundingClientRect(),o=1.5*Math.max(.875*a,a-40),n=t?a-o+r:o+r;return"HTML"===e.tagName?n+e.scrollTop:n}(s,r);let c,u;for(let e=0;e=0){void 0!==u&&us||(e&&(null==S?void 0:S.baseElement)&&S.baseElement===e.baseElement?S.id:void 0),baseElement:e=>(null==e?void 0:e.baseElement)||void 0,isActiveItem:e=>!!e&&e.activeId===j,ariaSetSize:e=>null!=_?_:e&&(null==S?void 0:S.ariaSetSize)&&S.baseElement===e.baseElement?S.ariaSetSize:void 0,ariaPosInSet(e){if(null!=k)return k;if(!e)return;if(!(null==S?void 0:S.ariaPosInSet))return;if(S.baseElement!==e.baseElement)return;const t=e.renderedItems.filter((e=>e.rowId===R));return S.ariaPosInSet+t.findIndex((e=>e.id===j))},isTabbable(e){if(!(null==e?void 0:e.renderedItems.length))return!0;if(e.virtualFocus)return!1;if(y)return!0;if(null===e.activeId)return!1;const t=null==a?void 0:a.item(e.activeId);return!!(null==t?void 0:t.disabled)||(!(null==t?void 0:t.element)||e.activeId===j)}}),O=h.useCallback.call(void 0,(e=>{var t;const a=u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{},e),{id:j||e.id,rowId:R,disabled:!!P,children:null==(t=e.element)?void 0:t.textContent});return x?x(a):a}),[j,R,P,x]),N=E.onFocus,I=h.useRef.call(void 0,!1),B=c.useEvent.call(void 0,(e=>{if(null==N||N(e),e.defaultPrevented)return;if(v.isPortalEvent.call(void 0,e))return;if(!j)return;if(!a)return;if(function(e,t){return!v.isSelfTarget.call(void 0,e)&&n.isItem.call(void 0,t,e.target)}(e,a))return;const{virtualFocus:t,baseElement:r}=a.getState();if(a.setActiveId(j),d.isTextbox.call(void 0,e.currentTarget)&&n.selectTextField.call(void 0,e.currentTarget),!t)return;if(!v.isSelfTarget.call(void 0,e))return;if(o=e.currentTarget,d.isTextbox.call(void 0,o)||"INPUT"===o.tagName&&!d.isButton.call(void 0,o))return;var o;if(!(null==r?void 0:r.isConnected))return;m.isSafari.call(void 0)&&e.currentTarget.hasAttribute("data-autofocus")&&e.currentTarget.scrollIntoView({block:"nearest",inline:"nearest"}),I.current=!0;e.relatedTarget===r||n.isItem.call(void 0,a,e.relatedTarget)?n.focusSilently.call(void 0,r):r.focus()})),T=E.onBlurCapture,F=c.useEvent.call(void 0,(e=>{if(null==T||T(e),e.defaultPrevented)return;const t=null==a?void 0:a.getState();(null==t?void 0:t.virtualFocus)&&I.current&&(I.current=!1,e.preventDefault(),e.stopPropagation())})),D=E.onKeyDown,G=c.useBooleanEvent.call(void 0,g),U=c.useBooleanEvent.call(void 0,b),q=c.useEvent.call(void 0,(e=>{if(null==D||D(e),e.defaultPrevented)return;if(!v.isSelfTarget.call(void 0,e))return;if(!a)return;const{currentTarget:t}=e,r=a.getState(),o=a.item(j),n=!!(null==o?void 0:o.rowId),l="horizontal"!==r.orientation,s="vertical"!==r.orientation,i=()=>!!n||(!!s||(!r.baseElement||!d.isTextField.call(void 0,r.baseElement))),c={ArrowUp:(n||l)&&a.up,ArrowRight:(n||s)&&a.next,ArrowDown:(n||l)&&a.down,ArrowLeft:(n||s)&&a.previous,Home:()=>{if(i())return!n||e.ctrlKey?null==a?void 0:a.first():null==a?void 0:a.previous(-1)},End:()=>{if(i())return!n||e.ctrlKey?null==a?void 0:a.last():null==a?void 0:a.next(-1)},PageUp:()=>w(t,a,null==a?void 0:a.up,!0),PageDown:()=>w(t,a,null==a?void 0:a.down)}[e.key];if(c){if(d.isTextbox.call(void 0,t)){const a=d.getTextboxSelection.call(void 0,t),r=s&&"ArrowLeft"===e.key,o=s&&"ArrowRight"===e.key,n=l&&"ArrowUp"===e.key,i=l&&"ArrowDown"===e.key;if(o||i){const{length:e}=d.getTextboxValue.call(void 0,t);if(a.end!==e)return}else if((r||n)&&0!==a.start)return}const r=c();if(G(e)||void 0!==r){if(!U(e))return;e.preventDefault(),a.move(r)}}})),Z=h.useMemo.call(void 0,(()=>({id:j,baseElement:M})),[j,M]);return E=c.useWrapElement.call(void 0,E,(e=>f.jsx.call(void 0,l.CompositeItemContext.Provider,{value:Z,children:e})),[Z]),E=u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{id:j,"data-active-item":V||void 0},E),{ref:c.useMergeRefs.call(void 0,A,E.ref),tabIndex:L?E.tabIndex:-1,onFocus:B,onBlurCapture:F,onKeyDown:q}),E=o.useCommand.call(void 0,E),E=r.useCollectionItem.call(void 0,u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{store:a},E),{getItem:O,shouldRegisterItem:!!j&&E.shouldRegisterItem})),p.removeUndefinedValues.call(void 0,u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{},E),{"aria-setsize":z,"aria-posinset":H}))})),y=s.memo.call(void 0,s.forwardRef.call(void 0,(function(e){const t=b(e);return s.createElement.call(void 0,"button",t)})));t.useCompositeItem=b,t.CompositeItem=y},99103:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(77723),n=a(19652),l=a(80987),s=a(28148),i=a(48959),c=a(51609),u=a(10790),d=n.createHook.call(void 0,(function(e){var t=e,{store:a,alwaysVisible:n}=t,d=s.__objRest.call(void 0,t,["store","alwaysVisible"]);const v=r.useComboboxScopedContext.call(void 0,!0),p=r.useComboboxContext.call(void 0),m=!!(a=a||p)&&a===v;i.invariant.call(void 0,a,!1);const h=c.useRef.call(void 0,null),f=l.useId.call(void 0,d.id),g=a.useState("mounted"),w=o.isHidden.call(void 0,g,d.hidden,n),b=w?s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},d.style),{display:"none"}):d.style,y=a.useState((e=>Array.isArray(e.selectedValue))),x=l.useAttribute.call(void 0,h,"role",d.role),_=("listbox"===x||"tree"===x||"grid"===x)&&y||void 0,[k,E]=c.useState.call(void 0,!1),C=a.useState("contentElement");l.useSafeLayoutEffect.call(void 0,(()=>{if(!g)return;const e=h.current;if(!e)return;if(C!==e)return;const t=()=>{E(!!e.querySelector("[role='listbox']"))},a=new MutationObserver(t);return a.observe(e,{subtree:!0,childList:!0,attributeFilter:["role"]}),t(),()=>a.disconnect()}),[g,C]),k||(d=s.__spreadValues.call(void 0,{role:"listbox","aria-multiselectable":_},d)),d=l.useWrapElement.call(void 0,d,(e=>u.jsx.call(void 0,r.ComboboxScopedContextProvider,{value:a,children:u.jsx.call(void 0,r.ComboboxListRoleContext.Provider,{value:x,children:e})})),[a,x]);const j=!f||v&&m?null:a.setContentElement;return d=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{id:f,hidden:w},d),{ref:l.useMergeRefs.call(void 0,j,h,d.ref),style:b}),i.removeUndefinedValues.call(void 0,d)})),v=n.forwardRef.call(void 0,(function(e){const t=d(e);return n.createElement.call(void 0,"div",t)}));t.useComboboxList=d,t.ComboboxList=v},2627:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(21236),n=a(19652),l=a(80987),s=a(28148),i=a(92725),c=a(48959),u=a(51609);function d(e,t,a){return e.useState((e=>e.items.find((e=>e.type===a&&e.name===t))))}var v=n.createHook.call(void 0,(function(e){var t=e,{store:a,name:n,getItem:v,touchOnBlur:p=!0}=t,m=s.__objRest.call(void 0,t,["store","name","getItem","touchOnBlur"]);const h=r.useFormContext.call(void 0);a=a||h,c.invariant.call(void 0,a,!1);const f=`${n}`,g=l.useId.call(void 0,m.id),w=u.useRef.call(void 0,null);a.useValidate((async()=>{const e=function(e,t){const a=e.current;return a?a.name===t?a:a.form?a.form.elements.namedItem(t):i.getDocument.call(void 0,a).getElementsByName(t)[0]:null}(w,f);e&&(await Promise.resolve(),"validity"in e&&!e.validity.valid&&(null==a||a.setError(f,e.validationMessage)))}));const b=u.useCallback.call(void 0,(e=>{const t=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},e),{id:g||e.id,name:f,type:"field"});return v?v(t):t}),[g,f,v]),y=m.onBlur,x=l.useBooleanEvent.call(void 0,p),_=l.useEvent.call(void 0,(e=>{null==y||y(e),e.defaultPrevented||x(e)&&(null==a||a.setFieldTouched(f,!0))})),k=d(a,f,"label"),E=d(a,f,"error"),C=d(a,f,"description"),j=c.cx.call(void 0,null==E?void 0:E.id,null==C?void 0:C.id,m["aria-describedby"]),A=a.useState((()=>!!(null==a?void 0:a.getError(f))&&a.getFieldTouched(f)));return m=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{id:g,"aria-labelledby":null==k?void 0:k.id,"aria-invalid":A},m),{"aria-describedby":j||void 0,ref:l.useMergeRefs.call(void 0,w,m.ref),onBlur:_}),m=o.useCollectionItem.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{store:a},m),{name:f,getItem:b}))})),p=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=v(e);return n.createElement.call(void 0,"input",t)})));t.useFormControl=v,t.FormControl=p},86005:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(52954),o=a(42076),n=a(19652),l=a(28148),s=a(48959),i=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const i=o.useCompositeContext.call(void 0);a=a||i,s.invariant.call(void 0,a,!1);const c=a.useState((e=>"horizontal"===e.orientation?"vertical":"horizontal"));return n=r.useSeparator.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},n),{orientation:c}))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"hr",t)}));t.useCompositeSeparator=i,t.CompositeSeparator=c},39490:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(33356),o=a(19652),n=o.createHook.call(void 0,(function(e){return e=r.usePopoverHeading.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"h1",t)}));t.useHovercardHeading=n,t.HovercardHeading=l},44448:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(95691),o=a(87636),n=a(80987),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(69414));function s(e,t,a){return n.useUpdateEffect.call(void 0,t,[a.popover]),o.useStoreProps.call(void 0,e,a,"placement"),r.useDialogStoreProps.call(void 0,e,t,a)}t.usePopoverStoreProps=s,t.usePopoverStore=function(e={}){const[t,a]=o.useStore.call(void 0,l.createPopoverStore,e);return s(t,a,e)}},46423:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44448),o=a(87636),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(58702));function l(e,t,a){return o.useStoreProps.call(void 0,e,a,"timeout"),o.useStoreProps.call(void 0,e,a,"showTimeout"),o.useStoreProps.call(void 0,e,a,"hideTimeout"),r.usePopoverStoreProps.call(void 0,e,t,a)}t.useHovercardStoreProps=l,t.useHovercardStore=function(e={}){const[t,a]=o.useStore.call(void 0,n.createHovercardStore,e);return l(t,a,e)}},77864:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(58058),o=a(19652),n=o.createHook.call(void 0,(function(e){return e=r.usePopoverDescription.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"p",t)}));t.useHovercardDescription=n,t.HovercardDescription=l},51500:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77018),o=a(19652),n=a(80987),l=a(28148),s=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=l.__objRest.call(void 0,t,["store"]);const s=r.usePopoverProviderContext.call(void 0);return a=a||s,o=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},o),{ref:n.useMergeRefs.call(void 0,null==a?void 0:a.setAnchorElement,o.ref)})})),i=o.forwardRef.call(void 0,(function(e){const t=s(e);return o.createElement.call(void 0,"div",t)}));t.usePopoverAnchor=s,t.PopoverAnchor=i},72707:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(77018),n=a(19652),l=a(51609),s=n.createStoreContext.call(void 0,[o.PopoverContextProvider,r.CompositeContextProvider],[o.PopoverScopedContextProvider,r.CompositeScopedContextProvider]),i=s.useContext,c=s.useScopedContext,u=s.useProviderContext,d=s.ContextProvider,v=s.ScopedContextProvider,p=l.createContext.call(void 0,!1),m=l.createContext.call(void 0,null);t.useSelectContext=i,t.useSelectScopedContext=c,t.useSelectProviderContext=u,t.SelectContextProvider=d,t.SelectScopedContextProvider=v,t.SelectItemCheckedContext=p,t.SelectHeadingContext=m},85826:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19652).createStoreContext.call(void 0),o=r.useContext,n=r.useScopedContext,l=r.useProviderContext,s=r.ContextProvider,i=r.ScopedContextProvider;t.useCheckboxContext=o,t.useCheckboxScopedContext=n,t.useCheckboxProviderContext=l,t.CheckboxContextProvider=s,t.CheckboxScopedContextProvider=i},32087:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(40227),o=a(42076),n=a(19652),l=a(87636),s=a(80987),i=a(28148),c=a(92725),u=a(77328),d=a(60877),v=a(48959),p=a(51609);function m(e){d.restoreFocusIn.call(void 0,e);const t=d.getFirstTabbableIn.call(void 0,e);return d.disableFocusIn.call(void 0,e),t}var h=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=i.__objRest.call(void 0,t,["store"]);const h=o.useCompositeContext.call(void 0);a=a||h;const f=p.useRef.call(void 0,null),g=p.useRef.call(void 0,!1),w=(e=!1)=>{const t=f.current;if(!t)return;d.restoreFocusIn.call(void 0,t);const a=d.getFirstTabbableIn.call(void 0,t);a?(g.current=!0,queueMicrotask((()=>{a.focus(),(c.isTextField.call(void 0,a)||a.isContentEditable)&&r.selectTextField.call(void 0,a,e)}))):d.disableFocusIn.call(void 0,t)},b=l.useStoreState.call(void 0,a,"renderedItems");p.useEffect.call(void 0,(()=>{const e=f.current;if(!e)return;!g.current&&(null==b?void 0:b.length)&&d.disableFocusIn.call(void 0,e)}),[b]);const y=n.onFocus,x=s.useEvent.call(void 0,(e=>{if(null==y||y(e),e.defaultPrevented)return;if(!a)return;const t=g.current;if(u.isSelfTarget.call(void 0,e)){g.current=!1;const{baseElement:e}=a.getState(),t="[data-composite-container]",r=null==e?void 0:e.querySelectorAll(t);if(r)for(const e of r)d.disableFocusIn.call(void 0,e)}else t||(g.current=!0,d.restoreFocusIn.call(void 0,e.currentTarget),null==a||a.setState("moves",0))})),_=n.onBlur,k=s.useEvent.call(void 0,(e=>{null==_||_(e),e.defaultPrevented||u.isFocusEventOutside.call(void 0,e)&&(()=>{const e=f.current;e&&(g.current=!1,d.disableFocusIn.call(void 0,e))})()})),E=n.onKeyDown,C=s.useEvent.call(void 0,(e=>{if(null==E||E(e),e.defaultPrevented)return;if(e.altKey)return;if(e.ctrlKey)return;if(e.metaKey)return;if(e.shiftKey)return;const t=e.currentTarget;if(u.isSelfTarget.call(void 0,e)){if(1===e.key.length&&" "!==e.key){const a=m(t);if(!a)return;(c.isTextField.call(void 0,a)||a.isContentEditable)&&(e.stopPropagation(),w())}else if("Delete"===e.key||"Backspace"===e.key){const e=m(t);if(!e)return;if(c.isTextField.call(void 0,e)||e.isContentEditable){w();const e=()=>queueMicrotask((()=>t.focus()));t.addEventListener("input",e,{once:!0})}}}else if("Escape"===e.key)queueMicrotask((()=>t.focus()));else if("Enter"===e.key){const a=e.target;("INPUT"===a.tagName&&!c.isButton.call(void 0,a)||"TEXTAREA"===a.tagName||a.isContentEditable)&&(e.preventDefault(),queueMicrotask((()=>t.focus())))}})),j=n.onClick,A=s.useEvent.call(void 0,(e=>{null==j||j(e),e.defaultPrevented||u.isSelfTarget.call(void 0,e)&&!e.detail&&w(!0)}));return n=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{"data-composite-container":""},n),{ref:s.useMergeRefs.call(void 0,f,n.ref),onFocus:x,onBlur:k,onKeyDown:C,onClick:A}),v.removeUndefinedValues.call(void 0,n)})),f=n.forwardRef.call(void 0,(function(e){const t=h(e);return n.createElement.call(void 0,"div",t)}));t.useCompositeContainer=h,t.CompositeContainer=f},74581:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80231),o=a(19652).createStoreContext.call(void 0,[r.HovercardContextProvider],[r.HovercardScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.useTooltipContext=n,t.useTooltipScopedContext=l,t.useTooltipProviderContext=s,t.TooltipContextProvider=i,t.TooltipScopedContextProvider=c},99366:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9355),o=a(87636),n=a(80987),l=a(28148),s=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(68702));function i(e){const t=n.useId.call(void 0,e.id);return l.__spreadValues.call(void 0,{id:t},e)}function c(e,t,a){return e=r.useCollectionStoreProps.call(void 0,e,t,a),o.useStoreProps.call(void 0,e,a,"activeId","setActiveId"),o.useStoreProps.call(void 0,e,a,"includesBaseElement"),o.useStoreProps.call(void 0,e,a,"virtualFocus"),o.useStoreProps.call(void 0,e,a,"orientation"),o.useStoreProps.call(void 0,e,a,"rtl"),o.useStoreProps.call(void 0,e,a,"focusLoop"),o.useStoreProps.call(void 0,e,a,"focusWrap"),o.useStoreProps.call(void 0,e,a,"focusShift"),e}t.useCompositeStoreOptions=i,t.useCompositeStoreProps=c,t.useCompositeStore=function(e={}){e=i(e);const[t,a]=o.useStore.call(void 0,s.createCompositeStore,e);return c(t,a,e)}},91520:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(69349),o=a(19652),n=a(28148),l=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=n.__objRest.call(void 0,t,["store"]);return o=r.useGroup.call(void 0,o)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"div",t)}));t.useCompositeGroup=l,t.CompositeGroup=s},50858:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(48427),o=a(32413),n=a(10790);t.MenubarProvider=function(e={}){const t=o.useMenubarStore.call(void 0,e);return n.jsx.call(void 0,r.MenubarContextProvider,{value:t,children:e.children})}},79066:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(45081),o=a(77018),n=a(19652),l=a(80987),s=a(28148),i=a(92725),c=a(48959),u=a(51609),d=a(10790),v=30,p=v/2,m={top:`rotate(180 ${p} ${p})`,right:`rotate(-90 ${p} ${p})`,bottom:`rotate(0 ${p} ${p})`,left:`rotate(90 ${p} ${p})`};var h=n.createHook.call(void 0,(function(e){var t=e,{store:a,size:n=v}=t,p=s.__objRest.call(void 0,t,["store","size"]);const h=o.usePopoverContext.call(void 0);a=a||h,c.invariant.call(void 0,a,!1);const f=a.useState((e=>e.currentPlacement.split("-")[0])),g=function(e){const[t,a]=u.useState.call(void 0),r=e.useState("contentElement");return l.useSafeLayoutEffect.call(void 0,(()=>{if(!r)return;const e=i.getWindow.call(void 0,r).getComputedStyle(r);a(e)}),[r]),t}(a),w=(null==g?void 0:g.getPropertyValue("background-color"))||"none",b=(null==g?void 0:g.getPropertyValue(`border-${f}-color`))||"none",y=(null==g?void 0:g.getPropertyValue(`border-${f}-width`))||"0px",x=2*Number.parseInt(y)*(v/n),_=m[f],k=u.useMemo.call(void 0,(()=>d.jsx.call(void 0,"svg",{display:"block",viewBox:"0 0 30 30",children:d.jsxs.call(void 0,"g",{transform:_,children:[d.jsx.call(void 0,"path",{fill:"none",d:r.POPOVER_ARROW_PATH}),d.jsx.call(void 0,"path",{stroke:"none",d:r.POPOVER_ARROW_PATH})]})})),[_]);return p=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{children:k,"aria-hidden":!0},p),{ref:l.useMergeRefs.call(void 0,a.setArrowElement,p.ref),style:s.__spreadValues.call(void 0,{position:"absolute",fontSize:n,width:"1em",height:"1em",pointerEvents:"none",fill:w,stroke:b,strokeWidth:x},p.style)}),c.removeUndefinedValues.call(void 0,p)})),f=n.forwardRef.call(void 0,(function(e){const t=h(e);return n.createElement.call(void 0,"div",t)}));t.usePopoverArrow=h,t.PopoverArrow=f},96475:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(77018),n=a(19652),l=a(51609),s=l.createContext.call(void 0,void 0),i=n.createStoreContext.call(void 0,[o.PopoverContextProvider,r.CompositeContextProvider],[o.PopoverScopedContextProvider,r.CompositeScopedContextProvider]),c=i.useContext,u=i.useScopedContext,d=i.useProviderContext,v=i.ContextProvider,p=i.ScopedContextProvider,m=l.createContext.call(void 0,void 0),h=l.createContext.call(void 0,!1);t.ComboboxListRoleContext=s,t.useComboboxContext=c,t.useComboboxScopedContext=u,t.useComboboxProviderContext=d,t.ComboboxContextProvider=v,t.ComboboxScopedContextProvider=p,t.ComboboxItemValueContext=m,t.ComboboxItemCheckedContext=h},95691:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(38980),o=a(87636),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(8448));function l(e,t,a){return r.useDisclosureStoreProps.call(void 0,e,t,a)}t.useDialogStoreProps=l,t.useDialogStore=function(e={}){const[t,a]=o.useStore.call(void 0,n.createDialogStore,e);return l(t,a,e)}},73579:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51609).createContext.call(void 0,!0);t.FocusableContext=r},41196:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168),o=a(68666),n=a(9229),l=a(77723),s=a(19652),i=a(87636),c=a(80987),u=a(28148),d=a(48959),v=a(51609),p=a(10790);var m=s.createHook.call(void 0,(function(e){var t=e,{store:a,alwaysVisible:s,composite:m}=t,h=u.__objRest.call(void 0,t,["store","alwaysVisible","composite"]);const f=r.useMenuProviderContext.call(void 0);a=a||f,d.invariant.call(void 0,a,!1);const g=a.parent,w=a.menubar,b=!!g,y=c.useId.call(void 0,h.id),x=h.onKeyDown,_=a.useState((e=>e.placement.split("-")[0])),k=a.useState((e=>"both"===e.orientation?void 0:e.orientation)),E="vertical"!==k,C=i.useStoreState.call(void 0,w,(e=>!!e&&"vertical"!==e.orientation)),j=c.useEvent.call(void 0,(e=>{if(null==x||x(e),!e.defaultPrevented){if(b||w&&!E){const t={ArrowRight:()=>"left"===_&&!E,ArrowLeft:()=>"right"===_&&!E,ArrowUp:()=>"bottom"===_&&E,ArrowDown:()=>"top"===_&&E}[e.key];if(null==t?void 0:t())return e.stopPropagation(),e.preventDefault(),null==a?void 0:a.hide()}if(w){const t={ArrowRight:()=>{if(C)return w.next()},ArrowLeft:()=>{if(C)return w.previous()},ArrowDown:()=>{if(!C)return w.next()},ArrowUp:()=>{if(!C)return w.previous()}}[e.key],a=null==t?void 0:t();void 0!==a&&(e.stopPropagation(),e.preventDefault(),w.move(a))}}}));h=c.useWrapElement.call(void 0,h,(e=>p.jsx.call(void 0,r.MenuScopedContextProvider,{value:a,children:e})),[a]);const A=function(e){var t=e,{store:a}=t,r=u.__objRest.call(void 0,t,["store"]);const[o,n]=v.useState.call(void 0,void 0),l=r["aria-label"],s=i.useStoreState.call(void 0,a,"disclosureElement"),c=i.useStoreState.call(void 0,a,"contentElement");return v.useEffect.call(void 0,(()=>{const e=s;e&&c&&(l||c.hasAttribute("aria-label")?n(void 0):e.id&&n(e.id))}),[l,s,c]),o}(u.__spreadValues.call(void 0,{store:a},h)),S=a.useState("mounted"),P=l.isHidden.call(void 0,S,h.hidden,s),R=P?u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{},h.style),{display:"none"}):h.style;h=u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{id:y,"aria-labelledby":A,hidden:P},h),{ref:c.useMergeRefs.call(void 0,y?a.setContentElement:null,h.ref),style:R,onKeyDown:j});const M=!!a.combobox;return(m=null!=m?m:!M)&&(h=u.__spreadValues.call(void 0,{role:"menu","aria-orientation":k},h)),h=n.useComposite.call(void 0,u.__spreadValues.call(void 0,{store:a,composite:m},h)),h=o.useCompositeTypeahead.call(void 0,u.__spreadValues.call(void 0,{store:a,typeahead:!M},h))})),h=s.forwardRef.call(void 0,(function(e){const t=m(e);return s.createElement.call(void 0,"div",t)}));t.useMenuList=m,t.MenuList=h},44110:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99366),o=a(87636),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(23902));function l(e,t,a){return r.useCompositeStoreProps.call(void 0,e,t,a)}t.useToolbarStoreProps=l,t.useToolbarStore=function(e={}){const[t,a]=o.useStore.call(void 0,n.createToolbarStore,e);return l(t,a,e)}},15892:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652).createStoreContext.call(void 0,[r.CompositeContextProvider],[r.CompositeScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.useTabContext=n,t.useTabScopedContext=l,t.useTabProviderContext=s,t.TabContextProvider=i,t.TabScopedContextProvider=c},90041:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(64494),o=a(35973),n=a(19652),l=a(87636),s=a(80987),i=a(28148),c=a(48959),u=a(51609),d="input";var v=n.createHook.call(void 0,(function(e){var t=e,{store:a,name:n,value:v,checked:p}=t,m=i.__objRest.call(void 0,t,["store","name","value","checked"]);const h=r.useRadioContext.call(void 0);a=a||h;const f=s.useId.call(void 0,m.id),g=u.useRef.call(void 0,null),w=l.useStoreState.call(void 0,a,(e=>null!=p?p:function(e,t){if(void 0!==t)return null!=e&&null!=t?t===e:!!t}(v,null==e?void 0:e.value)));u.useEffect.call(void 0,(()=>{if(!f)return;if(!w)return;(null==a?void 0:a.getState().activeId)===f||null==a||a.setActiveId(f)}),[a,w,f]);const b=m.onChange,y=function(e,t){return"input"===e&&(!t||"radio"===t)}(s.useTagName.call(void 0,g,d),m.type),x=c.disabledFromProps.call(void 0,m),[_,k]=s.useForceUpdate.call(void 0);u.useEffect.call(void 0,(()=>{const e=g.current;e&&(y||(void 0!==w&&(e.checked=w),void 0!==n&&(e.name=n),void 0!==v&&(e.value=`${v}`)))}),[_,y,w,n,v]);const E=s.useEvent.call(void 0,(e=>{if(x)return e.preventDefault(),void e.stopPropagation();(null==a?void 0:a.getState().value)!==v&&(y||(e.currentTarget.checked=!0,k()),null==b||b(e),e.defaultPrevented||null==a||a.setValue(v))})),C=m.onClick,j=s.useEvent.call(void 0,(e=>{null==C||C(e),e.defaultPrevented||y||E(e)})),A=m.onFocus,S=s.useEvent.call(void 0,(e=>{if(null==A||A(e),e.defaultPrevented)return;if(!y)return;if(!a)return;const{moves:t,activeId:r}=a.getState();t&&(f&&r!==f||E(e))}));return m=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{id:f,role:y?void 0:"radio",type:y?"radio":void 0,"aria-checked":w},m),{ref:s.useMergeRefs.call(void 0,g,m.ref),onChange:E,onClick:j,onFocus:S}),m=o.useCompositeItem.call(void 0,i.__spreadValues.call(void 0,{store:a,clickOnEnter:!y},m)),c.removeUndefinedValues.call(void 0,i.__spreadValues.call(void 0,{name:y?n:void 0,value:y?v:void 0,checked:w},m))})),p=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=v(e);return n.createElement.call(void 0,d,t)})));t.useRadio=v,t.Radio=p},32564:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(72707),n=a(99366),l=a(87636),s=a(80987),i=a(28148),c=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(95190)),u=a(51609);function d(e,t,a){s.useUpdateEffect.call(void 0,t,[a.composite,a.combobox]),e=n.useCompositeStoreProps.call(void 0,e,t,a),l.useStoreProps.call(void 0,e,a,"selectedId","setSelectedId"),l.useStoreProps.call(void 0,e,a,"selectOnMove");const[r,o]=l.useStore.call(void 0,(()=>e.panels),{});return s.useUpdateEffect.call(void 0,o,[e,o]),Object.assign(u.useMemo.call(void 0,(()=>i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{panels:r})),[e,r]),{composite:a.composite,combobox:a.combobox})}t.useTabStoreProps=d,t.useTabStore=function(e={}){const t=r.useComboboxContext.call(void 0),a=o.useSelectContext.call(void 0)||t;e=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{composite:void 0!==e.composite?e.composite:a,combobox:void 0!==e.combobox?e.combobox:t});const[n,s]=l.useStore.call(void 0,c.createTabStore,e);return d(n,s,e)}},93704:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168),o=a(48427),n=a(96475),l=a(99366),s=a(46423),i=a(87636),c=a(80987),u=a(28148),d=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(81894));function v(e,t,a){return c.useUpdateEffect.call(void 0,t,[a.combobox,a.parent,a.menubar]),i.useStoreProps.call(void 0,e,a,"values","setValues"),Object.assign(s.useHovercardStoreProps.call(void 0,l.useCompositeStoreProps.call(void 0,e,t,a),t,a),{combobox:a.combobox,parent:a.parent,menubar:a.menubar})}t.useMenuStoreProps=v,t.useMenuStore=function(e={}){const t=r.useMenuContext.call(void 0),a=o.useMenubarContext.call(void 0),l=n.useComboboxProviderContext.call(void 0);e=u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{},e),{parent:void 0!==e.parent?e.parent:t,menubar:void 0!==e.menubar?e.menubar:a,combobox:void 0!==e.combobox?e.combobox:l});const[s,c]=i.useStore.call(void 0,d.createMenuStore,e);return v(s,c,e)}},32413:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99366),o=a(87636),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(49586));function l(e,t,a){return r.useCompositeStoreProps.call(void 0,e,t,a)}t.useMenubarStoreProps=l,t.useMenubarStore=function(e={}){const[t,a]=o.useStore.call(void 0,n.createMenubarStore,e);return l(t,a,e)}},67722:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51609).createContext.call(void 0,null);t.PortalContext=r},21407:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80231),o=a(87121),n=a(19652),l=a(80987),s=a(28148),i=a(77328),c=a(48959),u=a(51609),d=n.createHook.call(void 0,(function(e){var t=e,{store:a,showOnHover:n=!0}=t,d=s.__objRest.call(void 0,t,["store","showOnHover"]);const v=r.useHovercardProviderContext.call(void 0);a=a||v,c.invariant.call(void 0,a,!1);const p=c.disabledFromProps.call(void 0,d),m=u.useRef.call(void 0,0);u.useEffect.call(void 0,(()=>()=>window.clearTimeout(m.current)),[]),u.useEffect.call(void 0,(()=>i.addGlobalEventListener.call(void 0,"mouseleave",(e=>{if(!a)return;const{anchorElement:t}=a.getState();t&&e.target===t&&(window.clearTimeout(m.current),m.current=0)}),!0)),[a]);const h=d.onMouseMove,f=l.useBooleanEvent.call(void 0,n),g=l.useIsMouseMoving.call(void 0),w=l.useEvent.call(void 0,(e=>{if(null==h||h(e),p)return;if(!a)return;if(e.defaultPrevented)return;if(m.current)return;if(!g())return;if(!f(e))return;const t=e.currentTarget;a.setAnchorElement(t),a.setDisclosureElement(t);const{showTimeout:r,timeout:o}=a.getState(),n=()=>{m.current=0,g()&&(null==a||a.setAnchorElement(t),null==a||a.show(),queueMicrotask((()=>{null==a||a.setDisclosureElement(t)})))},l=null!=r?r:o;0===l?n():m.current=window.setTimeout(n,l)})),b=d.onClick,y=l.useEvent.call(void 0,(e=>{null==b||b(e),a&&(window.clearTimeout(m.current),m.current=0)})),x=u.useCallback.call(void 0,(e=>{if(!a)return;const{anchorElement:t}=a.getState();(null==t?void 0:t.isConnected)||a.setAnchorElement(e)}),[a]);return d=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},d),{ref:l.useMergeRefs.call(void 0,x,d.ref),onMouseMove:w,onClick:y}),d=o.useFocusable.call(void 0,d)})),v=n.forwardRef.call(void 0,(function(e){const t=d(e);return n.createElement.call(void 0,"a",t)}));t.useHovercardAnchor=d,t.HovercardAnchor=v},8549:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(89169),o=a(99471),n=a(92725),l=a(48959),s=a(32314),i=a(51609);t.usePreventBodyScroll=function(e,t,a){const c=r.useRootDialog.call(void 0,{attribute:"data-dialog-prevent-body-scroll",contentElement:e,contentId:t,enabled:a});i.useEffect.call(void 0,(()=>{if(!c())return;if(!e)return;const t=n.getDocument.call(void 0,e),a=n.getWindow.call(void 0,e),{documentElement:r,body:i}=t,u=r.style.getPropertyValue("--scrollbar-width"),d=u?Number.parseInt(u):a.innerWidth-r.clientWidth,v=function(e){const t=e.getBoundingClientRect().left;return Math.round(t)+e.scrollLeft?"paddingLeft":"paddingRight"}(r),p=s.isApple.call(void 0)&&!s.isMac.call(void 0);return l.chain.call(void 0,o.setCSSProperty.call(void 0,r,"--scrollbar-width",`${d}px`),p?(()=>{var e,t;const{scrollX:r,scrollY:n,visualViewport:l}=a,s=null!=(e=null==l?void 0:l.offsetLeft)?e:0,c=null!=(t=null==l?void 0:l.offsetTop)?t:0,u=o.assignStyle.call(void 0,i,{position:"fixed",overflow:"hidden",top:-(n-Math.floor(c))+"px",left:-(r-Math.floor(s))+"px",right:"0",[v]:`${d}px`});return()=>{u(),a.scrollTo({left:r,top:n,behavior:"instant"})}})():o.assignStyle.call(void 0,i,{overflow:"hidden",[v]:`${d}px`}))}),[c,e])}},70663:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isFocusTrap=function(e,...t){if(!e)return!1;const a=e.getAttribute("data-focus-trap");return null!=a&&(!t.length||""!==a&&t.some((e=>a===e)))}},26621:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87636),o=a(80987),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(64054));function l(e,t,a){return o.useUpdateEffect.call(void 0,t,[a.store]),r.useStoreProps.call(void 0,e,a,"value","setValue"),e}t.useCheckboxStoreProps=l,t.useCheckboxStore=function(e={}){const[t,a]=r.useStore.call(void 0,n.createCheckboxStore,e);return l(t,a,e)}},53944:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(16299),o=a(19652),n=a(51609),l=o.createStoreContext.call(void 0,[r.DisclosureContextProvider],[r.DisclosureScopedContextProvider]),s=l.useContext,i=l.useScopedContext,c=l.useProviderContext,u=l.ContextProvider,d=l.ScopedContextProvider,v=n.createContext.call(void 0,void 0),p=n.createContext.call(void 0,void 0);t.useDialogContext=s,t.useDialogScopedContext=i,t.useDialogProviderContext=c,t.DialogContextProvider=u,t.DialogScopedContextProvider=d,t.DialogHeadingContext=v,t.DialogDescriptionContext=p},12019:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99366),o=a(87636),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(56286));function l(e,t,a){return e=r.useCompositeStoreProps.call(void 0,e,t,a),o.useStoreProps.call(void 0,e,a,"value","setValue"),e}t.useRadioStoreProps=l,t.useRadioStore=function(e={}){const[t,a]=o.useStore.call(void 0,n.createRadioStore,e);return l(t,a,e)}},66485:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076),o=a(19652).createStoreContext.call(void 0,[r.CompositeContextProvider],[r.CompositeScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.useToolbarContext=n,t.useToolbarScopedContext=l,t.useToolbarProviderContext=s,t.ToolbarContextProvider=i,t.ToolbarScopedContextProvider=c},95563:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(69349),o=a(19652),n=a(28148),l=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=n.__objRest.call(void 0,t,["store"]);return o=r.useGroup.call(void 0,o)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"div",t)}));t.useFormGroup=l,t.FormGroup=s},18874:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(48427),o=a(32413),n=a(9229),l=a(19652),s=a(80987),i=a(28148),c=a(10790),u=l.createHook.call(void 0,(function(e){var t=e,{store:a,composite:l=!0,orientation:u,virtualFocus:d,focusLoop:v,rtl:p}=t,m=i.__objRest.call(void 0,t,["store","composite","orientation","virtualFocus","focusLoop","rtl"]);const h=r.useMenubarProviderContext.call(void 0);a=a||h;const f=o.useMenubarStore.call(void 0,{store:a,orientation:u,virtualFocus:d,focusLoop:v,rtl:p}),g=f.useState((e=>l&&"both"!==e.orientation?e.orientation:void 0));return m=s.useWrapElement.call(void 0,m,(e=>c.jsx.call(void 0,r.MenubarScopedContextProvider,{value:f,children:e})),[f]),l&&(m=i.__spreadValues.call(void 0,{role:"menubar","aria-orientation":g},m)),m=n.useComposite.call(void 0,i.__spreadValues.call(void 0,{store:f,composite:l},m))})),d=l.forwardRef.call(void 0,(function(e){const t=u(e);return l.createElement.call(void 0,"div",t)}));t.useMenubar=u,t.Menubar=d},94818:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(92725);t.prependHiddenDismiss=function(e,t){const a=r.getDocument.call(void 0,e).createElement("button");return a.type="button",a.tabIndex=-1,a.textContent="Dismiss popup",Object.assign(a.style,{border:"0px",clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:"0px",position:"absolute",whiteSpace:"nowrap",width:"1px"}),a.addEventListener("click",t),e.prepend(a),()=>{a.removeEventListener("click",t),a.remove()}}},85325:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(26327),o=a(49464),n=a(99471),l=a(48959);function s(e="",t=!1){return`__ariakit-dialog-${t?"ancestor":"outside"}${e?`-${e}`:""}`}function i(e,t=""){return l.chain.call(void 0,n.setProperty.call(void 0,e,s(),!0),n.setProperty.call(void 0,e,s(t),!0))}function c(e,t=""){return l.chain.call(void 0,n.setProperty.call(void 0,e,s("",!0),!0),n.setProperty.call(void 0,e,s(t,!0),!0))}t.markElement=i,t.markAncestor=c,t.isElementMarked=function(e,t){if(e[s(t,!0)])return!0;const a=s(t);for(;;){if(e[a])return!0;if(!e.parentElement)return!1;e=e.parentElement}},t.markTreeOutside=function(e,t){const a=[],n=t.map((e=>null==e?void 0:e.id));return o.walkTreeOutside.call(void 0,e,t,(t=>{r.isBackdrop.call(void 0,t,...n)||a.unshift(i(t,e))}),((t,r)=>{r.hasAttribute("data-dialog")&&r.id!==e||a.unshift(c(t,e))})),()=>{for(const e of a)e()}}},53443:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67804),o=a(19652),n=a(28148),l=a(48959),s=a(51609),i=a(10790),c=i.jsx.call(void 0,"svg",{display:"block",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,viewBox:"0 0 16 16",height:"1em",width:"1em",children:i.jsx.call(void 0,"polyline",{points:"4,8 7,12 12,4"})});var u=o.createHook.call(void 0,(function(e){var t=e,{store:a,checked:o}=t,i=n.__objRest.call(void 0,t,["store","checked"]);const u=s.useContext.call(void 0,r.CheckboxCheckedContext),d=function(e){return e.checked?e.children||c:"function"==typeof e.children?e.children:null}({checked:o=null!=o?o:u,children:i.children});return i=n.__spreadProps.call(void 0,n.__spreadValues.call(void 0,{"aria-hidden":!0},i),{children:d,style:n.__spreadValues.call(void 0,{width:"1em",height:"1em",pointerEvents:"none"},i.style)}),l.removeUndefinedValues.call(void 0,i)})),d=o.forwardRef.call(void 0,(function(e){const t=u(e);return o.createElement.call(void 0,"span",t)}));t.useCheckboxCheck=u,t.CheckboxCheck=d},82109:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(68725),o=a(39861),n=a(28293),l=a(80231),s=a(19652),i=a(80987),c=a(28148),u=a(92725),d=a(77328),v=a(60877),p=a(48959),m=a(8766),h=a(51609),f=a(10790);function g(e,t,a,r){return!!v.hasFocusWithin.call(void 0,t)||!!e&&(!!u.contains.call(void 0,t,e)||(!(!a||!u.contains.call(void 0,a,e))||!!(null==r?void 0:r.some((t=>g(e,t,a))))))}var w=h.createContext.call(void 0,null),b=s.createHook.call(void 0,(function(e){var t=e,{store:a,modal:n=!1,portal:s=!!n,hideOnEscape:v=!0,hideOnHoverOutside:b=!0,disablePointerEventsOnApproach:y=!!b}=t,x=c.__objRest.call(void 0,t,["store","modal","portal","hideOnEscape","hideOnHoverOutside","disablePointerEventsOnApproach"]);const _=l.useHovercardProviderContext.call(void 0);a=a||_,p.invariant.call(void 0,a,!1);const k=h.useRef.call(void 0,null),[E,C]=h.useState.call(void 0,[]),j=h.useRef.call(void 0,0),A=h.useRef.call(void 0,null),{portalRef:S,domReady:P}=i.usePortalRef.call(void 0,s,x.portalRef),R=i.useIsMouseMoving.call(void 0),M=!!b,V=i.useBooleanEvent.call(void 0,b),z=!!y,H=i.useBooleanEvent.call(void 0,y),L=a.useState("open"),O=a.useState("mounted");h.useEffect.call(void 0,(()=>{if(!P)return;if(!O)return;if(!M&&!z)return;const e=k.current;if(!e)return;return p.chain.call(void 0,d.addGlobalEventListener.call(void 0,"mousemove",(t=>{if(!a)return;if(!R())return;const{anchorElement:o,hideTimeout:n,timeout:l}=a.getState(),s=A.current,[i]=t.composedPath(),c=o;if(g(i,e,c,E))return A.current=i&&c&&u.contains.call(void 0,c,i)?r.getEventPoint.call(void 0,t):null,window.clearTimeout(j.current),void(j.current=0);if(!j.current){if(s){const a=r.getEventPoint.call(void 0,t),o=r.getElementPolygon.call(void 0,e,s);if(r.isPointInPolygon.call(void 0,a,o)){if(A.current=a,!H(t))return;return t.preventDefault(),void t.stopPropagation()}}V(t)&&(j.current=window.setTimeout((()=>{j.current=0,null==a||a.hide()}),null!=n?n:l))}}),!0),(()=>clearTimeout(j.current)))}),[a,R,P,O,M,z,E,H,V]),h.useEffect.call(void 0,(()=>{if(!P)return;if(!O)return;if(!z)return;const e=e=>{const t=k.current;if(!t)return;const a=A.current;if(!a)return;const o=r.getElementPolygon.call(void 0,t,a);if(r.isPointInPolygon.call(void 0,r.getEventPoint.call(void 0,e),o)){if(!H(e))return;e.preventDefault(),e.stopPropagation()}};return p.chain.call(void 0,d.addGlobalEventListener.call(void 0,"mouseenter",e,!0),d.addGlobalEventListener.call(void 0,"mouseover",e,!0),d.addGlobalEventListener.call(void 0,"mouseout",e,!0),d.addGlobalEventListener.call(void 0,"mouseleave",e,!0))}),[P,O,z,H]),h.useEffect.call(void 0,(()=>{P&&(L||null==a||a.setAutoFocusOnShow(!1))}),[a,P,L]);const N=i.useLiveRef.call(void 0,L);h.useEffect.call(void 0,(()=>{if(P)return()=>{N.current||null==a||a.setAutoFocusOnShow(!1)}}),[a,P]);const I=h.useContext.call(void 0,w);i.useSafeLayoutEffect.call(void 0,(()=>{if(n)return;if(!s)return;if(!O)return;if(!P)return;const e=k.current;return e?null==I?void 0:I(e):void 0}),[n,s,O,P]);const B=h.useCallback.call(void 0,(e=>{C((t=>[...t,e]));const t=null==I?void 0:I(e);return()=>{C((t=>t.filter((t=>t!==e)))),null==t||t()}}),[I]);x=i.useWrapElement.call(void 0,x,(e=>f.jsx.call(void 0,l.HovercardScopedContextProvider,{value:a,children:f.jsx.call(void 0,w.Provider,{value:B,children:e})})),[a,B]),x=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{},x),{ref:i.useMergeRefs.call(void 0,k,x.ref)}),x=function(e){var t=e,{store:a}=t,r=c.__objRest.call(void 0,t,["store"]);const[o,n]=h.useState.call(void 0,!1),l=a.useState("mounted");h.useEffect.call(void 0,(()=>{l||n(!1)}),[l]);const s=r.onFocus,u=i.useEvent.call(void 0,(e=>{null==s||s(e),e.defaultPrevented||n(!0)})),d=h.useRef.call(void 0,null);return h.useEffect.call(void 0,(()=>m.sync.call(void 0,a,["anchorElement"],(e=>{d.current=e.anchorElement}))),[]),c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{autoFocusOnHide:o,finalFocus:d},r),{onFocus:u})}(c.__spreadValues.call(void 0,{store:a},x));const T=a.useState((e=>n||e.autoFocusOnShow));return x=o.usePopover.call(void 0,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{store:a,modal:n,portal:s,autoFocusOnShow:T},x),{portalRef:S,hideOnEscape:e=>!p.isFalsyBooleanCallback.call(void 0,v,e)&&(requestAnimationFrame((()=>{requestAnimationFrame((()=>{null==a||a.hide()}))})),!0)}))})),y=n.createDialogComponent.call(void 0,s.forwardRef.call(void 0,(function(e){const t=b(e);return s.createElement.call(void 0,"div",t)})),l.useHovercardProviderContext);t.useHovercard=b,t.Hovercard=y},32816:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(68666),o=a(72707),n=a(9229),l=a(77723),s=a(19652),i=a(80987),c=a(28148),u=a(77328),d=a(48959),v=a(51609),p=a(10790),m=v.createContext.call(void 0,null),h=s.createHook.call(void 0,(function(e){var t=e,{store:a,resetOnEscape:s=!0,hideOnEnter:h=!0,focusOnMove:f=!0,composite:g,alwaysVisible:w}=t,b=c.__objRest.call(void 0,t,["store","resetOnEscape","hideOnEnter","focusOnMove","composite","alwaysVisible"]);const y=o.useSelectContext.call(void 0);a=a||y,d.invariant.call(void 0,a,!1);const x=i.useId.call(void 0,b.id),_=a.useState("value"),k=Array.isArray(_),[E,C]=v.useState.call(void 0,_),j=a.useState("mounted");v.useEffect.call(void 0,(()=>{j||C(_)}),[j,_]),s=s&&!k;const A=b.onKeyDown,S=i.useBooleanEvent.call(void 0,s),P=i.useBooleanEvent.call(void 0,h),R=i.useEvent.call(void 0,(e=>{null==A||A(e),e.defaultPrevented||("Escape"===e.key&&S(e)&&(null==a||a.setValue(E))," "!==e.key&&"Enter"!==e.key||u.isSelfTarget.call(void 0,e)&&P(e)&&(e.preventDefault(),null==a||a.hide()))})),M=v.useContext.call(void 0,o.SelectHeadingContext),V=v.useState.call(void 0),[z,H]=M||V,L=v.useMemo.call(void 0,(()=>[z,H]),[z]),[O,N]=v.useState.call(void 0,null),I=v.useContext.call(void 0,m);v.useEffect.call(void 0,(()=>{if(I)return I(a),()=>I(null)}),[I,a]),b=i.useWrapElement.call(void 0,b,(e=>p.jsx.call(void 0,o.SelectScopedContextProvider,{value:a,children:p.jsx.call(void 0,m.Provider,{value:N,children:p.jsx.call(void 0,o.SelectHeadingContext.Provider,{value:L,children:e})})})),[a,L]);const B=!!a.combobox;g=null!=g?g:!B&&O!==a;const[T,F]=i.useTransactionState.call(void 0,g?a.setListElement:null),D=i.useAttribute.call(void 0,T,"role",b.role),G=(g||("listbox"===D||"menu"===D||"tree"===D||"grid"===D))&&k||void 0,U=l.isHidden.call(void 0,j,b.hidden,w),q=U?c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{},b.style),{display:"none"}):b.style;g&&(b=c.__spreadValues.call(void 0,{role:"listbox","aria-multiselectable":G},b));const Z=a.useState((e=>{var t;return z||(null==(t=e.labelElement)?void 0:t.id)}));return b=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{id:x,"aria-labelledby":Z,hidden:U},b),{ref:i.useMergeRefs.call(void 0,F,b.ref),style:q,onKeyDown:R}),b=n.useComposite.call(void 0,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{store:a},b),{composite:g})),b=r.useCompositeTypeahead.call(void 0,c.__spreadValues.call(void 0,{store:a,typeahead:!B},b))})),f=s.forwardRef.call(void 0,(function(e){const t=h(e);return s.createElement.call(void 0,"div",t)}));t.useSelectList=h,t.SelectList=f},85171:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51609).createContext.call(void 0,void 0);t.GroupLabelContext=r},3578:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19652),o=a(28148),n=r.createHook.call(void 0,(function(e){return e=o.__spreadProps.call(void 0,o.__spreadValues.call(void 0,{},e),{style:o.__spreadValues.call(void 0,{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"},e.style)})})),l=r.forwardRef.call(void 0,(function(e){const t=n(e);return r.createElement.call(void 0,"span",t)}));t.useVisuallyHidden=n,t.VisuallyHidden=l},49464:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99471),o=a(92725),n=a(48959),l=["SCRIPT","STYLE"];function s(e){return`__ariakit-dialog-snapshot-${e}`}function i(e,t,a){return!l.includes(t.tagName)&&(!!function(e,t){const a=o.getDocument.call(void 0,t),r=s(e);if(!a.body[r])return!0;for(;;){if(t===a.body)return!1;if(t[r])return!0;if(!t.parentElement)return!1;t=t.parentElement}}(e,t)&&!a.some((e=>e&&o.contains.call(void 0,t,e))))}function c(e,t,a,r){for(let n of t){if(!(null==n?void 0:n.isConnected))continue;const l=t.some((e=>!!e&&(e!==n&&e.contains(n)))),s=o.getDocument.call(void 0,n),c=n;for(;n.parentElement&&n!==s.body;){if(null==r||r(n.parentElement,c),!l)for(const r of n.parentElement.children)i(e,r,t)&&a(r,c);n=n.parentElement}}}t.isValidElement=i,t.walkTreeOutside=c,t.createWalkTreeSnapshot=function(e,t){const{body:a}=o.getDocument.call(void 0,t[0]),l=[];return c(e,t,(t=>{l.push(r.setProperty.call(void 0,t,s(e),!0))})),n.chain.call(void 0,r.setProperty.call(void 0,a,s(e),!0),(()=>{for(const e of l)e()}))}},69349:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(85171),o=a(19652),n=a(80987),l=a(28148),s=a(48959),i=a(51609),c=a(10790),u=o.createHook.call(void 0,(function(e){const[t,a]=i.useState.call(void 0);return e=n.useWrapElement.call(void 0,e,(e=>c.jsx.call(void 0,r.GroupLabelContext.Provider,{value:a,children:e})),[]),e=l.__spreadValues.call(void 0,{role:"group","aria-labelledby":t},e),s.removeUndefinedValues.call(void 0,e)})),d=o.forwardRef.call(void 0,(function(e){const t=u(e);return o.createElement.call(void 0,"div",t)}));t.useGroup=u,t.Group=d},68666:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(40227),o=a(42076),n=a(19652),l=a(80987),s=a(28148),i=a(92725),c=a(77328),u=a(48959),d=a(51609),v="";function p(){v=""}function m(e,t){var a;const r=(null==(a=e.element)?void 0:a.textContent)||e.children||"value"in e&&e.value;return!!r&&u.normalizeString.call(void 0,r).trim().toLowerCase().startsWith(t.toLowerCase())}var h=n.createHook.call(void 0,(function(e){var t=e,{store:a,typeahead:n=!0}=t,h=s.__objRest.call(void 0,t,["store","typeahead"]);const f=o.useCompositeContext.call(void 0);a=a||f,u.invariant.call(void 0,a,!1);const g=h.onKeyDownCapture,w=d.useRef.call(void 0,0),b=l.useEvent.call(void 0,(e=>{if(null==g||g(e),e.defaultPrevented)return;if(!n)return;if(!a)return;if(!function(e){const t=e.target;return(!t||!i.isTextField.call(void 0,t))&&(!(" "!==e.key||!v.length)||1===e.key.length&&!e.ctrlKey&&!e.altKey&&!e.metaKey&&/^[\p{Letter}\p{Number}]$/u.test(e.key))}(e))return p();const{renderedItems:t,items:o,activeId:l,id:s}=a.getState();let u=function(e){return e.filter((e=>!e.disabled))}(o.length>t.length?o:t);const d=`[data-offscreen-id="${s}"]`,h=i.getDocument.call(void 0,e.currentTarget).querySelectorAll(d);for(const e of h){const t="true"===e.ariaDisabled||"disabled"in e&&!!e.disabled;u.push({id:e.id,element:e,disabled:t})}if(h.length&&(u=i.sortBasedOnDOMPosition.call(void 0,u,(e=>e.element))),!function(e,t){if(c.isSelfTarget.call(void 0,e))return!0;const a=e.target;return!!a&&t.some((e=>e.element===a))}(e,u))return p();e.preventDefault(),window.clearTimeout(w.current),w.current=window.setTimeout((()=>{v=""}),500);const f=e.key.toLowerCase();v+=f,u=function(e,t,a){if(!a)return e;const o=e.find((e=>e.id===a));return o&&m(o,t)?v!==t&&m(o,v)?e:(v=t,r.flipItems.call(void 0,e.filter((e=>m(e,v))),a).filter((e=>e.id!==a))):e}(u,f,l);const b=u.find((e=>m(e,v)));b?a.move(b.id):p()}));return h=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},h),{onKeyDownCapture:b}),u.removeUndefinedValues.call(void 0,h)})),f=n.forwardRef.call(void 0,(function(e){const t=h(e);return n.createElement.call(void 0,"div",t)}));t.useCompositeTypeahead=h,t.CompositeTypeahead=f},74525:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(57870),o=a(19652).createStoreContext.call(void 0,[r.CollectionContextProvider],[r.CollectionScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.useFormContext=n,t.useFormScopedContext=l,t.useFormProviderContext=s,t.FormContextProvider=i,t.FormScopedContextProvider=c},82203:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(73579),o=a(19652),n=a(80987),l=a(28148),s=a(10790),i=o.createHook.call(void 0,(function(e){var t=e,{autoFocusOnShow:a=!0}=t,o=l.__objRest.call(void 0,t,["autoFocusOnShow"]);return o=n.useWrapElement.call(void 0,o,(e=>s.jsx.call(void 0,r.FocusableContext.Provider,{value:a,children:e})),[a])})),c=o.forwardRef.call(void 0,(function(e){const t=i(e);return o.createElement.call(void 0,"div",t)}));t.useFocusableContainer=i,t.FocusableContainer=c},38980:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87636),o=a(80987),n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a]);return t.default=e,t}(a(97438));function l(e,t,a){return o.useUpdateEffect.call(void 0,t,[a.store,a.disclosure]),r.useStoreProps.call(void 0,e,a,"open","setOpen"),r.useStoreProps.call(void 0,e,a,"mounted","setMounted"),r.useStoreProps.call(void 0,e,a,"animated"),Object.assign(e,{disclosure:a.disclosure})}t.useDisclosureStoreProps=l,t.useDisclosureStore=function(e={}){const[t,a]=r.useStore.call(void 0,n.createDisclosureStore,e);return l(t,a,e)}},99992:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53944),o=a(19652),n=a(80987),l=a(28148),s=a(48959),i=a(51609),c=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=l.__objRest.call(void 0,t,["store"]);const c=i.useContext.call(void 0,r.DialogDescriptionContext),u=n.useId.call(void 0,o.id);return n.useSafeLayoutEffect.call(void 0,(()=>(null==c||c(u),()=>null==c?void 0:c(void 0))),[c,u]),o=l.__spreadValues.call(void 0,{id:u},o),s.removeUndefinedValues.call(void 0,o)})),u=o.forwardRef.call(void 0,(function(e){const t=c(e);return o.createElement.call(void 0,"p",t)}));t.useDialogDescription=c,t.DialogDescription=u},77018:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53944),o=a(19652).createStoreContext.call(void 0,[r.DialogContextProvider],[r.DialogScopedContextProvider]),n=o.useContext,l=o.useScopedContext,s=o.useProviderContext,i=o.ContextProvider,c=o.ScopedContextProvider;t.usePopoverContext=n,t.usePopoverScopedContext=l,t.usePopoverProviderContext=s,t.PopoverContextProvider=i,t.PopoverScopedContextProvider=c},58430:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(70419);a(29842),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.Button=r.Button,t.useButton=r.useButton},44587:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53443);a(67804),a(19652),a(80987),a(7219),a(28148),t.CheckboxCheck=r.CheckboxCheck,t.useCheckboxCheck=r.useCheckboxCheck},71986:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(85826);a(19652),a(80987),a(7219),a(28148),t.CheckboxContextProvider=r.CheckboxContextProvider,t.CheckboxScopedContextProvider=r.CheckboxScopedContextProvider,t.useCheckboxContext=r.useCheckboxContext,t.useCheckboxProviderContext=r.useCheckboxProviderContext,t.useCheckboxScopedContext=r.useCheckboxScopedContext},72714:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(26621),o=a(85826);a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.CheckboxProvider=function(e={}){const t=r.useCheckboxStore.call(void 0,e);return n.jsx.call(void 0,o.CheckboxContextProvider,{value:t,children:e.children})}},35048:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(26621);a(87636),a(80987),a(7219),a(28148),t.useCheckboxStore=r.useCheckboxStore,t.useCheckboxStoreProps=r.useCheckboxStoreProps},85848:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(71385);a(85826),a(67804),a(29842),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.Checkbox=r.Checkbox,t.useCheckbox=r.useCheckbox},42668:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(57870);a(19652),a(80987),a(7219),a(28148),t.CollectionContextProvider=r.CollectionContextProvider,t.CollectionScopedContextProvider=r.CollectionScopedContextProvider,t.useCollectionContext=r.useCollectionContext,t.useCollectionProviderContext=r.useCollectionProviderContext,t.useCollectionScopedContext=r.useCollectionScopedContext},99378:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21236);a(57870),a(19652),a(80987),a(7219),a(28148),t.CollectionItem=r.CollectionItem,t.useCollectionItem=r.useCollectionItem},60940:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9355),o=a(57870);a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.CollectionProvider=function(e={}){const t=r.useCollectionStore.call(void 0,e);return n.jsx.call(void 0,o.CollectionContextProvider,{value:t,children:e.children})}},27498:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9355);a(87636),a(80987),a(7219),a(28148),t.useCollectionStore=r.useCollectionStore,t.useCollectionStoreProps=r.useCollectionStoreProps},5238:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(57870),o=a(19652),n=a(80987);a(7219);var l=a(28148),s=a(48959),i=a(10790),c=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=l.__objRest.call(void 0,t,["store"]);const c=r.useCollectionProviderContext.call(void 0);return a=a||c,o=n.useWrapElement.call(void 0,o,(e=>i.jsx.call(void 0,r.CollectionScopedContextProvider,{value:a,children:e})),[a]),s.removeUndefinedValues.call(void 0,o)})),u=o.forwardRef.call(void 0,(function(e){const t=c(e);return o.createElement.call(void 0,"div",t)}));t.Collection=u,t.useCollection=c},67295:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(70419);a(29842),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(51609),u=a(10790),d=u.jsxs.call(void 0,"svg",{"aria-hidden":"true",display:"block",viewBox:"0 0 16 16",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,width:"1em",height:"1em",pointerEvents:"none",children:[u.jsx.call(void 0,"line",{x1:"5",y1:"5",x2:"11",y2:"11"}),u.jsx.call(void 0,"line",{x1:"5",y1:"11",x2:"11",y2:"5"})]}),v=n.createHook.call(void 0,(function(e){var t=e,{store:a,hideWhenEmpty:n}=t,v=s.__objRest.call(void 0,t,["store","hideWhenEmpty"]);const p=r.useComboboxProviderContext.call(void 0);a=a||p,i.invariant.call(void 0,a,!1);const m=v.onClick,h=l.useEvent.call(void 0,(e=>{null==m||m(e),e.defaultPrevented||(null==a||a.setValue(""),null==a||a.move(null))})),f=a.useState((e=>{var t;return null==(t=e.baseElement)?void 0:t.id})),g=a.useState((e=>""===e.value));return v=l.useWrapElement.call(void 0,v,(e=>n&&g?u.jsx.call(void 0,c.Fragment,{}):e),[n,g]),v=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{children:d,"aria-label":"Clear input","aria-controls":f},v),{onClick:h}),v=o.useButton.call(void 0,v)})),p=n.forwardRef.call(void 0,(function(e){const t=v(e);return n.createElement.call(void 0,"button",t)}));t.ComboboxCancel=p,t.useComboboxCancel=v},18038:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.ComboboxContextProvider=r.ComboboxContextProvider,t.ComboboxItemCheckedContext=r.ComboboxItemCheckedContext,t.ComboboxItemValueContext=r.ComboboxItemValueContext,t.ComboboxListRoleContext=r.ComboboxListRoleContext,t.ComboboxScopedContextProvider=r.ComboboxScopedContextProvider,t.useComboboxContext=r.useComboboxContext,t.useComboboxProviderContext=r.useComboboxProviderContext,t.useComboboxScopedContext=r.useComboboxScopedContext},30030:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(49190);a(56203),a(70419),a(29842),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(10790),u=c.jsx.call(void 0,"svg",{"aria-hidden":"true",display:"block",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,viewBox:"0 0 16 16",height:"1em",width:"1em",pointerEvents:"none",children:c.jsx.call(void 0,"polyline",{points:"4,6 8,10 12,6"})}),d=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=s.__objRest.call(void 0,t,["store"]);const c=r.useComboboxProviderContext.call(void 0);a=a||c,i.invariant.call(void 0,a,!1);const d=n.onMouseDown,v=l.useEvent.call(void 0,(e=>{null==d||d(e),e.preventDefault(),null==a||a.move(null)})),p=n.onClick,m=l.useEvent.call(void 0,(e=>{if(null==p||p(e),e.defaultPrevented)return;if(!a)return;const{baseElement:t}=a.getState();a.setDisclosureElement(t)})),h=a.useState("open");return n=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{children:u,tabIndex:-1,"aria-label":h?"Hide popup":"Show popup","aria-expanded":h},n),{onMouseDown:v,onClick:m}),n=o.useDialogDisclosure.call(void 0,s.__spreadValues.call(void 0,{store:a},n))})),v=n.forwardRef.call(void 0,(function(e){const t=d(e);return n.createElement.call(void 0,"button",t)}));t.ComboboxDisclosure=v,t.useComboboxDisclosure=d},98935:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(59190);a(50864),a(85171);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useCompositeGroupLabel.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"div",t)}));t.ComboboxGroupLabel=l,t.useComboboxGroupLabel=n},79334:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(91520);a(69349),a(85171);var o=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(92725),i=a(48959),c=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const c=o.useComboboxScopedContext.call(void 0);a=a||c,i.invariant.call(void 0,a,!1);const u=a.useState("contentElement");return"grid"===s.getPopupRole.call(void 0,u)&&(n=l.__spreadValues.call(void 0,{role:"rowgroup"},n)),n=r.useCompositeGroup.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),u=n.forwardRef.call(void 0,(function(e){const t=c(e);return n.createElement.call(void 0,"div",t)}));t.ComboboxGroup=u,t.useComboboxGroup=c},6439:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53443);a(67804);var o=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(51609),i=n.createHook.call(void 0,(function(e){var t=e,{store:a,checked:n}=t,i=l.__objRest.call(void 0,t,["store","checked"]);const c=s.useContext.call(void 0,o.ComboboxItemCheckedContext);return n=null!=n?n:c,i=r.useCheckboxCheck.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},i),{checked:n}))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"span",t)}));t.ComboboxItemCheck=c,t.useComboboxItemCheck=i},82616:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299);var o=a(19652),n=a(87636);a(80987),a(7219);var l=a(28148),s=a(11790),i=a(48959),c=a(51609),u=a(10790);function d(e){return i.normalizeString.call(void 0,e).toLowerCase()}var v=o.createHook.call(void 0,(function(e){var t=e,{store:a,value:o,userValue:v}=t,p=l.__objRest.call(void 0,t,["store","value","userValue"]);const m=r.useComboboxScopedContext.call(void 0);a=a||m;const h=c.useContext.call(void 0,r.ComboboxItemValueContext),f=null!=o?o:h,g=n.useStoreState.call(void 0,a,(e=>null!=v?v:null==e?void 0:e.value)),w=c.useMemo.call(void 0,(()=>{if(f)return g?function(e,t){if(!e)return e;if(!t)return e;const a=s.toArray.call(void 0,t).filter(Boolean).map(d),r=[],o=(e,t=!1)=>u.jsx.call(void 0,"span",{"data-autocomplete-value":t?"":void 0,"data-user-value":t?void 0:"",children:e},r.length),n=function(e){return e.sort((([e],[t])=>e-t))}(function(e){return e.filter((([e,t],a,r)=>!r.some((([r,o],n)=>n!==a&&r<=e&&r+o>=e+t))))}(function(e,t){const a=[];for(const r of t){let t=0;const o=r.length;for(;-1!==e.indexOf(r,t);){const n=e.indexOf(r,t);-1!==n&&a.push([n,o]),t=n+1}}return a}(d(e),new Set(a))));if(!n.length)return r.push(o(e,!0)),r;const[l]=n[0];return[e.slice(0,l),...n.flatMap((([t,a],r)=>{var o;const l=e.slice(t,t+a),s=null==(o=n[r+1])?void 0:o[0];return[l,e.slice(t+a,s)]}))].forEach(((e,t)=>{e&&r.push(o(e,t%2==0))})),r}(f,g):f}),[f,g]);return p=l.__spreadValues.call(void 0,{children:w},p),i.removeUndefinedValues.call(void 0,p)})),p=o.forwardRef.call(void 0,(function(e){const t=v(e);return o.createElement.call(void 0,"span",t)}));t.ComboboxItemValue=p,t.useComboboxItemValue=v},23140:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(30829);a(61150),a(96475),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.ComboboxItem=r.ComboboxItem,t.useComboboxItem=r.useComboboxItem},68529:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299);var o=a(19652);a(80987),a(7219);var n=a(28148),l=a(48959),s=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=n.__objRest.call(void 0,t,["store"]);const s=r.useComboboxProviderContext.call(void 0);a=a||s,l.invariant.call(void 0,a,!1);const i=a.useState((e=>{var t;return null==(t=e.baseElement)?void 0:t.id}));return o=n.__spreadValues.call(void 0,{htmlFor:i},o),l.removeUndefinedValues.call(void 0,o)})),i=o.memo.call(void 0,o.forwardRef.call(void 0,(function(e){const t=s(e);return o.createElement.call(void 0,"label",t)})));t.ComboboxLabel=i,t.useComboboxLabel=s},72305:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99103);a(96475),a(42076),a(57870),a(77723),a(77018),a(53944),a(16299),a(19652),a(87636),a(80987),a(7219),a(28148),t.ComboboxList=r.ComboboxList,t.useComboboxList=r.useComboboxList},87020:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99103),o=a(96475);a(42076),a(57870);var n=a(39861),l=a(28293);a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707),a(77018),a(53944),a(16299),a(87121),a(73579),a(3578);var s=a(19652);a(95691),a(38980);var i=a(87636);a(80987),a(7219);var c=a(28148),u=a(92725),d=a(48959),v=a(51609);var p=s.createHook.call(void 0,(function(e){var t=e,{store:a,modal:l,tabIndex:s,alwaysVisible:p,autoFocusOnHide:m=!0,hideOnInteractOutside:h=!0}=t,f=c.__objRest.call(void 0,t,["store","modal","tabIndex","alwaysVisible","autoFocusOnHide","hideOnInteractOutside"]);const g=o.useComboboxProviderContext.call(void 0);a=a||g,d.invariant.call(void 0,a,!1);const w=a.useState("baseElement"),b=v.useRef.call(void 0,!1),y=i.useStoreState.call(void 0,a.tag,(e=>null==e?void 0:e.renderedItems.length));return f=r.useComboboxList.call(void 0,c.__spreadValues.call(void 0,{store:a,alwaysVisible:p},f)),f=n.usePopover.call(void 0,c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{store:a,modal:l,alwaysVisible:p,backdrop:!1,autoFocusOnShow:!1,finalFocus:w,preserveTabOrderAnchor:null,unstable_treeSnapshotKey:y},f),{getPersistentElements(){var e;const t=(null==(e=f.getPersistentElements)?void 0:e.call(f))||[];if(!l)return t;if(!a)return t;const{contentElement:r,baseElement:o}=a.getState();if(!o)return t;const n=u.getDocument.call(void 0,o),s=[];if((null==r?void 0:r.id)&&s.push(`[aria-controls~="${r.id}"]`),(null==o?void 0:o.id)&&s.push(`[aria-controls~="${o.id}"]`),!s.length)return[...t,o];const i=s.join(","),c=n.querySelectorAll(i);return[...t,...c]},autoFocusOnHide:e=>!d.isFalsyBooleanCallback.call(void 0,m,e)&&(!b.current||(b.current=!1,!1)),hideOnInteractOutside(e){var t,r;const o=null==a?void 0:a.getState(),n=null==(t=null==o?void 0:o.contentElement)?void 0:t.id,l=null==(r=null==o?void 0:o.baseElement)?void 0:r.id;if(function(e,...t){if(!e)return!1;if("id"in e){const a=t.filter(Boolean).map((e=>`[aria-controls~="${e}"]`)).join(", ");return!!a&&e.matches(a)}return!1}(e.target,n,l))return!1;const s="function"==typeof h?h(e):h;return s&&(b.current="click"===e.type),s}}))})),m=l.createDialogComponent.call(void 0,s.forwardRef.call(void 0,(function(e){const t=p(e);return s.createElement.call(void 0,"div",t)})),o.useComboboxProviderContext);t.ComboboxPopover=m,t.useComboboxPopover=p},69198:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(89930),o=a(96475);a(54871),a(99366),a(9355),a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.ComboboxProvider=function(e={}){const t=r.useComboboxStore.call(void 0,e);return n.jsx.call(void 0,o.ComboboxContextProvider,{value:t,children:e.children})}},98739:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(22225),o=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(92725),i=a(48959),c=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const c=o.useComboboxScopedContext.call(void 0);a=a||c,i.invariant.call(void 0,a,!1);const u=a.useState("contentElement"),d="grid"===s.getPopupRole.call(void 0,u)?"row":"presentation";return n=l.__spreadValues.call(void 0,{role:d},n),n=r.useCompositeRow.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),u=n.forwardRef.call(void 0,(function(e){const t=c(e);return n.createElement.call(void 0,"div",t)}));t.ComboboxRow=u,t.useComboboxRow=c},15498:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(86005);a(52954),a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(48959),i=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const i=r.useComboboxScopedContext.call(void 0);return a=a||i,s.invariant.call(void 0,a,!1),n=o.useCompositeSeparator.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"hr",t)}));t.ComboboxSeparator=c,t.useComboboxSeparator=i},52652:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(89930);a(54871),a(99366),a(9355),a(42076),a(57870),a(19652),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.useComboboxStore=r.useComboboxStore,t.useComboboxStoreOptions=r.useComboboxStoreOptions,t.useComboboxStoreProps=r.useComboboxStoreProps},74592:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475);a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148);var o=a(48959);t.ComboboxValue=function({store:e,children:t}={}){const a=r.useComboboxContext.call(void 0);e=e||a,o.invariant.call(void 0,e,!1);const n=e.useState("value");return t?t(n):n}},98348:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(96475),o=a(51500),n=a(9229);a(40227),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579);var l=a(19652),s=a(80987);a(7219);var i=a(28148),c=a(92725),u=a(77328),d=a(60877),v=a(48959),p=a(8766),m=a(51609);function h(e,t,a){if(!a)return!1;const r=e.find((e=>!e.disabled&&e.value));return(null==r?void 0:r.value)===t}function f(e,t){return!!t&&(null!=e&&(e=v.normalizeString.call(void 0,e),t.length>e.length&&0===t.toLowerCase().indexOf(e.toLowerCase())))}var g=l.createHook.call(void 0,(function(e){var t=e,{store:a,focusable:l=!0,autoSelect:g=!1,getAutoSelectId:w,setValueOnChange:b,showMinLength:y=0,showOnChange:x,showOnMouseDown:_,showOnClick:k=_,showOnKeyDown:E,showOnKeyPress:C=E,blurActiveItemOnClick:j,setValueOnClick:A=!0,moveOnKeyPress:S=!0,autoComplete:P="list"}=t,R=i.__objRest.call(void 0,t,["store","focusable","autoSelect","getAutoSelectId","setValueOnChange","showMinLength","showOnChange","showOnMouseDown","showOnClick","showOnKeyDown","showOnKeyPress","blurActiveItemOnClick","setValueOnClick","moveOnKeyPress","autoComplete"]);const M=r.useComboboxProviderContext.call(void 0);a=a||M,v.invariant.call(void 0,a,!1);const V=m.useRef.call(void 0,null),[z,H]=s.useForceUpdate.call(void 0),L=m.useRef.call(void 0,!1),O=m.useRef.call(void 0,!1),N=a.useState((e=>e.virtualFocus&&g)),I="inline"===P||"both"===P,[B,T]=m.useState.call(void 0,I);s.useUpdateLayoutEffect.call(void 0,(()=>{I&&T(!0)}),[I]);const F=a.useState("value"),D=m.useRef.call(void 0);m.useEffect.call(void 0,(()=>p.sync.call(void 0,a,["selectedValue","activeId"],((e,t)=>{D.current=t.selectedValue}))),[]);const G=a.useState((e=>{var t;if(I&&B){if(e.activeValue&&Array.isArray(e.selectedValue)){if(e.selectedValue.includes(e.activeValue))return;if(null==(t=D.current)?void 0:t.includes(e.activeValue))return}return e.activeValue}})),U=a.useState("renderedItems"),q=a.useState("open"),Z=a.useState("contentElement"),W=m.useMemo.call(void 0,(()=>{if(!I)return F;if(!B)return F;if(h(U,G,N)){if(f(F,G)){const e=(null==G?void 0:G.slice(F.length))||"";return F+e}return F}return G||F}),[I,B,U,G,N,F]);m.useEffect.call(void 0,(()=>{const e=V.current;if(!e)return;const t=()=>T(!0);return e.addEventListener("combobox-item-move",t),()=>{e.removeEventListener("combobox-item-move",t)}}),[]),m.useEffect.call(void 0,(()=>{if(!I)return;if(!B)return;if(!G)return;if(!h(U,G,N))return;if(!f(F,G))return;let e=v.noop;return queueMicrotask((()=>{const t=V.current;if(!t)return;const{start:a,end:r}=c.getTextboxSelection.call(void 0,t),o=F.length,n=G.length;c.setSelectionRange.call(void 0,t,o,n),e=()=>{if(!d.hasFocus.call(void 0,t))return;const{start:e,end:l}=c.getTextboxSelection.call(void 0,t);e===o&&l===n&&c.setSelectionRange.call(void 0,t,a,r)}})),()=>e()}),[z,I,B,G,U,N,F]);const $=m.useRef.call(void 0,null),J=s.useEvent.call(void 0,w),K=m.useRef.call(void 0,null);m.useEffect.call(void 0,(()=>{if(!q)return;if(!Z)return;const e=c.getScrollingElement.call(void 0,Z);if(!e)return;$.current=e;const t=()=>{L.current=!1},r=()=>{if(!a)return;if(!L.current)return;const{activeId:e}=a.getState();null!==e&&e!==K.current&&(L.current=!1)},o={passive:!0,capture:!0};return e.addEventListener("wheel",t,o),e.addEventListener("touchmove",t,o),e.addEventListener("scroll",r,o),()=>{e.removeEventListener("wheel",t,!0),e.removeEventListener("touchmove",t,!0),e.removeEventListener("scroll",r,!0)}}),[q,Z,a]),s.useSafeLayoutEffect.call(void 0,(()=>{F&&(O.current||(L.current=!0))}),[F]),s.useSafeLayoutEffect.call(void 0,(()=>{"always"!==N&&q||(L.current=q)}),[N,q]);const Q=a.useState("resetValueOnSelect");s.useUpdateEffect.call(void 0,(()=>{var e,t;const r=L.current;if(!a)return;if(!q)return;if(!r&&!Q)return;const{baseElement:o,contentElement:n,activeId:l}=a.getState();if(!o||d.hasFocus.call(void 0,o)){if(null==n?void 0:n.hasAttribute("data-placing")){const e=new MutationObserver(H);return e.observe(n,{attributeFilter:["data-placing"]}),()=>e.disconnect()}if(N&&r){const t=J(U),r=void 0!==t?t:null!=(e=function(e){const t=e.find((e=>{var t;return!e.disabled&&"tab"!==(null==(t=e.element)?void 0:t.getAttribute("role"))}));return null==t?void 0:t.id}(U))?e:a.first();K.current=r,a.move(null!=r?r:null)}else{const e=null==(t=a.item(l||a.first()))?void 0:t.element;e&&"scrollIntoView"in e&&e.scrollIntoView({block:"nearest",inline:"nearest"})}}}),[a,q,z,F,N,Q,J,U]),m.useEffect.call(void 0,(()=>{if(!I)return;const e=V.current;if(!e)return;const t=[e,Z].filter((e=>!!e)),r=e=>{t.every((t=>u.isFocusEventOutside.call(void 0,e,t)))&&(null==a||a.setValue(W))};for(const e of t)e.addEventListener("focusout",r);return()=>{for(const e of t)e.removeEventListener("focusout",r)}}),[I,Z,a,W]);const Y=e=>e.currentTarget.value.length>=y,X=R.onChange,ee=s.useBooleanEvent.call(void 0,null!=x?x:Y),te=s.useBooleanEvent.call(void 0,null!=b?b:!a.tag),ae=s.useEvent.call(void 0,(e=>{if(null==X||X(e),e.defaultPrevented)return;if(!a)return;const t=e.currentTarget,{value:r,selectionStart:o,selectionEnd:n}=t,l=e.nativeEvent;if(L.current=!0,function(e){return"input"===e.type}(l)&&(l.isComposing&&(L.current=!1,O.current=!0),I)){const e="insertText"===l.inputType||"insertCompositionText"===l.inputType,t=o===r.length;T(e&&t)}if(te(e)){const e=r===a.getState().value;a.setValue(r),queueMicrotask((()=>{c.setSelectionRange.call(void 0,t,o,n)})),I&&N&&e&&H()}ee(e)&&a.show(),N&&L.current||a.setActiveId(null)})),re=R.onCompositionEnd,oe=s.useEvent.call(void 0,(e=>{L.current=!0,O.current=!1,null==re||re(e),e.defaultPrevented||N&&H()})),ne=R.onMouseDown,le=s.useBooleanEvent.call(void 0,null!=j?j:()=>!!(null==a?void 0:a.getState().includesBaseElement)),se=s.useBooleanEvent.call(void 0,A),ie=s.useBooleanEvent.call(void 0,null!=k?k:Y),ce=s.useEvent.call(void 0,(e=>{null==ne||ne(e),e.defaultPrevented||e.button||e.ctrlKey||a&&(le(e)&&a.setActiveId(null),se(e)&&a.setValue(W),ie(e)&&u.queueBeforeEvent.call(void 0,e.currentTarget,"mouseup",a.show))})),ue=R.onKeyDown,de=s.useBooleanEvent.call(void 0,null!=C?C:Y),ve=s.useEvent.call(void 0,(e=>{if(null==ue||ue(e),e.repeat||(L.current=!1),e.defaultPrevented)return;if(e.ctrlKey)return;if(e.altKey)return;if(e.shiftKey)return;if(e.metaKey)return;if(!a)return;const{open:t}=a.getState();t||"ArrowUp"!==e.key&&"ArrowDown"!==e.key||de(e)&&(e.preventDefault(),a.show())})),pe=R.onBlur,me=s.useEvent.call(void 0,(e=>{L.current=!1,null==pe||pe(e),e.defaultPrevented})),he=s.useId.call(void 0,R.id),fe=function(e){return"inline"===e||"list"===e||"both"===e||"none"===e}(P)?P:void 0,ge=a.useState((e=>null===e.activeId));return R=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{id:he,role:"combobox","aria-autocomplete":fe,"aria-haspopup":c.getPopupRole.call(void 0,Z,"listbox"),"aria-expanded":q,"aria-controls":null==Z?void 0:Z.id,"data-active-item":ge||void 0,value:W},R),{ref:s.useMergeRefs.call(void 0,V,R.ref),onChange:ae,onCompositionEnd:oe,onMouseDown:ce,onKeyDown:ve,onBlur:me}),R=n.useComposite.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{store:a,focusable:l},R),{moveOnKeyPress:e=>!v.isFalsyBooleanCallback.call(void 0,S,e)&&(I&&T(!0),!0)})),R=o.usePopoverAnchor.call(void 0,i.__spreadValues.call(void 0,{store:a},R)),i.__spreadValues.call(void 0,{autoComplete:"off"},R)})),w=l.forwardRef.call(void 0,(function(e){const t=g(e);return l.createElement.call(void 0,"input",t)}));t.Combobox=w,t.useCombobox=g},19188:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(29842);a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.Command=r.Command,t.useCommand=r.useCommand},31258:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42076);a(57870),a(19652),a(80987),a(7219),a(28148),t.CompositeContextProvider=r.CompositeContextProvider,t.CompositeItemContext=r.CompositeItemContext,t.CompositeRowContext=r.CompositeRowContext,t.CompositeScopedContextProvider=r.CompositeScopedContextProvider,t.useCompositeContext=r.useCompositeContext,t.useCompositeProviderContext=r.useCompositeProviderContext,t.useCompositeScopedContext=r.useCompositeScopedContext},827:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(59190);a(50864),a(85171),a(19652),a(80987),a(7219),a(28148),t.CompositeGroupLabel=r.CompositeGroupLabel,t.useCompositeGroupLabel=r.useCompositeGroupLabel},50682:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(91520);a(69349),a(85171),a(19652),a(80987),a(7219),a(28148),t.CompositeGroup=r.CompositeGroup,t.useCompositeGroup=r.useCompositeGroup},40973:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(61150);a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.CompositeHover=r.CompositeHover,t.useCompositeHover=r.useCompositeHover},58736:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(35973);a(21236),a(29842),a(40227),a(42076),a(57870),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.CompositeItem=r.CompositeItem,t.useCompositeItem=r.useCompositeItem},41810:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99366);a(9355);var o=a(42076);a(57870),a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.CompositeProvider=function(e={}){const t=r.useCompositeStore.call(void 0,e);return n.jsx.call(void 0,o.CompositeContextProvider,{value:t,children:e.children})}},65631:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(22225);a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.CompositeRow=r.CompositeRow,t.useCompositeRow=r.useCompositeRow},84334:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(86005);a(52954),a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.CompositeSeparator=r.CompositeSeparator,t.useCompositeSeparator=r.useCompositeSeparator},87888:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99366);a(9355),a(87636),a(80987),a(7219),a(28148),t.useCompositeStore=r.useCompositeStore,t.useCompositeStoreOptions=r.useCompositeStoreOptions,t.useCompositeStoreProps=r.useCompositeStoreProps},99684:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(68666);a(40227),a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.CompositeTypeahead=r.CompositeTypeahead,t.useCompositeTypeahead=r.useCompositeTypeahead},55488:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9229);a(40227),a(42076),a(57870),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.Composite=r.Composite,t.useComposite=r.useComposite},59988:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53944);a(16299),a(19652),a(80987),a(7219),a(28148),t.DialogContextProvider=r.DialogContextProvider,t.DialogDescriptionContext=r.DialogDescriptionContext,t.DialogHeadingContext=r.DialogHeadingContext,t.DialogScopedContextProvider=r.DialogScopedContextProvider,t.useDialogContext=r.useDialogContext,t.useDialogProviderContext=r.useDialogProviderContext,t.useDialogScopedContext=r.useDialogScopedContext},13387:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(99992);a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.DialogDescription=r.DialogDescription,t.useDialogDescription=r.useDialogDescription},78368:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(49190);a(56203),a(70419),a(29842),a(53944),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.DialogDisclosure=r.DialogDisclosure,t.useDialogDisclosure=r.useDialogDisclosure},54513:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(60762);a(70419),a(29842),a(53944),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.DialogDismiss=r.DialogDismiss,t.useDialogDismiss=r.useDialogDismiss},25111:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(22510);a(35174),a(63215),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.DialogHeading=r.DialogHeading,t.useDialogHeading=r.useDialogHeading},22292:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53944);a(16299),a(19652);var o=a(95691);a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.DialogProvider=function(e={}){const t=o.useDialogStore.call(void 0,e);return n.jsx.call(void 0,r.DialogContextProvider,{value:t,children:e.children})}},80466:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(95691);a(38980),a(87636),a(80987),a(7219),a(28148),t.useDialogStore=r.useDialogStore,t.useDialogStoreProps=r.useDialogStoreProps},27742:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(28293);a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707),a(53944),a(16299),a(87121),a(73579),a(3578),a(19652),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.Dialog=r.Dialog,t.createDialogComponent=r.createDialogComponent,t.useDialog=r.useDialog},48056:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77723);a(53944),a(16299),a(19652),a(87636),a(80987),a(7219),a(28148),t.DisclosureContent=r.DisclosureContent,t.isHidden=r.isHidden,t.useDisclosureContent=r.useDisclosureContent},34130:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(16299);a(19652),a(80987),a(7219),a(28148),t.DisclosureContextProvider=r.DisclosureContextProvider,t.DisclosureScopedContextProvider=r.DisclosureScopedContextProvider,t.useDisclosureContext=r.useDisclosureContext,t.useDisclosureProviderContext=r.useDisclosureProviderContext,t.useDisclosureScopedContext=r.useDisclosureScopedContext},41706:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(16299);a(19652);var o=a(38980);a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.DisclosureProvider=function(e={}){const t=o.useDisclosureStore.call(void 0,e);return n.jsx.call(void 0,r.DisclosureContextProvider,{value:t,children:e.children})}},93320:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(38980);a(87636),a(80987),a(7219),a(28148),t.useDisclosureStore=r.useDisclosureStore,t.useDisclosureStoreProps=r.useDisclosureStoreProps},50296:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(56203);a(70419),a(29842),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.Disclosure=r.Disclosure,t.useDisclosure=r.useDisclosure},44571:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(54844);a(3578);var o=a(19652),n=a(80987);a(7219);var l=a(28148),s=a(60877),i=a(48959),c=a(51609),u=a(10790),d=o.createHook.call(void 0,(function(e){var t=e,{enabled:a=!1}=t,o=l.__objRest.call(void 0,t,["enabled"]);const d=c.useRef.call(void 0,null);return o=n.useWrapElement.call(void 0,o,(e=>{const t=()=>a?u.jsx.call(void 0,r.FocusTrap,{onFocus:e=>{const t=d.current;if(!t)return;const a=s.getAllTabbableIn.call(void 0,t,!0),r=a[0],o=a[a.length-1];a.length?e.relatedTarget===r?null==o||o.focus():null==r||r.focus():t.focus()}}):null;return u.jsxs.call(void 0,u.Fragment,{children:[t(),e,t()]})}),[a]),o=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},o),{ref:n.useMergeRefs.call(void 0,d,o.ref)}),i.removeUndefinedValues.call(void 0,o)})),v=o.forwardRef.call(void 0,(function(e){const t=d(e);return o.createElement.call(void 0,"div",t)}));t.FocusTrapRegion=v,t.useFocusTrapRegion=d},46410:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(54844);a(3578),a(19652),a(80987),a(7219),a(28148),t.FocusTrap=r.FocusTrap,t.useFocusTrap=r.useFocusTrap},83056:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87121);a(73579),a(19652),a(80987),a(7219),a(28148),t.Focusable=r.Focusable,t.isSafariFocusAncestor=r.isSafariFocusAncestor,t.useFocusable=r.useFocusable},18460:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2627),o=a(74525),n=a(71385),l=a(26621);a(85826),a(67804),a(21236),a(29842),a(57870),a(87121),a(73579);var s=a(19652);a(87636),a(80987),a(7219);var i=a(28148),c=a(48959),u=s.createHook.call(void 0,(function(e){var t=e,{store:a,name:s,value:u,checked:d,defaultChecked:v}=t,p=i.__objRest.call(void 0,t,["store","name","value","checked","defaultChecked"]);const m=o.useFormContext.call(void 0);a=a||m,c.invariant.call(void 0,a,!1);const h=`${s}`,f=l.useCheckboxStore.call(void 0,{value:a.useValue(h),setValue:e=>null==a?void 0:a.setValue(h,e)});return p=n.useCheckbox.call(void 0,i.__spreadValues.call(void 0,{store:f,value:u,checked:d},p)),p=r.useFormControl.call(void 0,i.__spreadValues.call(void 0,{store:a,name:h,"aria-labelledby":void 0},p))})),d=s.memo.call(void 0,s.forwardRef.call(void 0,(function(e){const t=u(e);return s.createElement.call(void 0,"input",t)})));t.FormCheckbox=d,t.useFormCheckbox=u},49296:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525);a(57870),a(19652),a(80987),a(7219),a(28148),t.FormContextProvider=r.FormContextProvider,t.FormScopedContextProvider=r.FormScopedContextProvider,t.useFormContext=r.useFormContext,t.useFormProviderContext=r.useFormProviderContext,t.useFormScopedContext=r.useFormScopedContext},96254:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2627);a(74525),a(21236),a(57870),a(19652),a(80987),a(7219),a(28148),t.FormControl=r.FormControl,t.useFormControl=r.useFormControl},74695:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(21236);a(57870);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(51609),u=n.createHook.call(void 0,(function(e){var t=e,{store:a,name:n,getItem:u}=t,d=s.__objRest.call(void 0,t,["store","name","getItem"]);const v=r.useFormContext.call(void 0);a=a||v,i.invariant.call(void 0,a,!1);const p=l.useId.call(void 0,d.id),m=c.useRef.call(void 0,null),h=`${n}`,f=c.useCallback.call(void 0,(e=>{const t=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},e),{id:p||e.id,name:h,type:"description"});return u?u(t):t}),[p,h,u]);return d=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{id:p},d),{ref:l.useMergeRefs.call(void 0,m,d.ref)}),d=o.useCollectionItem.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{store:a},d),{getItem:f}))})),d=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=u(e);return n.createElement.call(void 0,"div",t)})));t.FormDescription=d,t.useFormDescription=u},40055:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(21236);a(57870);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(51609),u=n.createHook.call(void 0,(function(e){var t=e,{store:a,name:n,getItem:u}=t,d=s.__objRest.call(void 0,t,["store","name","getItem"]);const v=r.useFormContext.call(void 0);a=a||v,i.invariant.call(void 0,a,!1);const p=l.useId.call(void 0,d.id),m=c.useRef.call(void 0,null),h=`${n}`,f=c.useCallback.call(void 0,(e=>{const t=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},e),{id:p||e.id,name:h,type:"error"});return u?u(t):t}),[p,h,u]),g=a.useState((()=>{const e=null==a?void 0:a.getError(h);if(null!=e&&(null==a?void 0:a.getFieldTouched(h)))return e}));return d=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{id:p,role:"alert",children:g},d),{ref:l.useMergeRefs.call(void 0,m,d.ref)}),d=o.useCollectionItem.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{store:a},d),{getItem:f}))})),d=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=u(e);return n.createElement.call(void 0,"div",t)})));t.FormError=d,t.useFormError=u},26169:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2627);a(74525),a(21236),a(57870);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return r.useFormControl.call(void 0,e)})),l=o.memo.call(void 0,o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"input",t)})));t.FormField=l,t.useFormField=n},3301:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(50864);a(85171);var o=a(19652);a(80987),a(7219);var n=a(28148),l=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=n.__objRest.call(void 0,t,["store"]);return o=r.useGroupLabel.call(void 0,o)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"div",t)}));t.FormGroupLabel=s,t.useFormGroupLabel=l},16448:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(95563);a(69349),a(85171),a(19652),a(80987),a(7219),a(28148),t.FormGroup=r.FormGroup,t.useFormGroup=r.useFormGroup},57509:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2627),o=a(74525);a(21236),a(57870);var n=a(87121);a(73579);var l=a(19652),s=a(80987);a(7219);var i=a(28148),c=a(48959),u=l.createHook.call(void 0,(function(e){var t=e,{store:a,name:l}=t,u=i.__objRest.call(void 0,t,["store","name"]);const d=o.useFormContext.call(void 0);a=a||d,c.invariant.call(void 0,a,!1);const v=`${l}`,p=u.onChange,m=s.useEvent.call(void 0,(e=>{null==p||p(e),e.defaultPrevented||null==a||a.setValue(v,e.target.value)})),h=a.useValue(v);return u=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{value:h},u),{onChange:m}),u=n.useFocusable.call(void 0,u),u=r.useFormControl.call(void 0,i.__spreadValues.call(void 0,{store:a,name:v},u))})),d=l.memo.call(void 0,l.forwardRef.call(void 0,(function(e){const t=u(e);return l.createElement.call(void 0,"input",t)})));t.FormInput=d,t.useFormInput=u},30587:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(21236);a(57870);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(60877),c=a(48959),u=a(51609),d=a(10790);var v=n.createHook.call(void 0,(function(e){var t=e,{store:a,name:n,getItem:v}=t,p=s.__objRest.call(void 0,t,["store","name","getItem"]);const m=r.useFormContext.call(void 0);a=a||m,c.invariant.call(void 0,a,!1);const h=l.useId.call(void 0,p.id),f=u.useRef.call(void 0,null),g=`${n}`,w=u.useCallback.call(void 0,(e=>{const t=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},e),{id:h||e.id,name:g,type:"label"});return v?v(t):t}),[h,g,v]),b=a.useState((e=>e.items.find((e=>"field"===e.type&&e.name===g)))),y=l.useTagName.call(void 0,null==b?void 0:b.element,"input"),x="input"===(_=y)||"textarea"===_||"select"===_||"meter"===_||"progress"===_;var _;const k=p.onClick,E=l.useEvent.call(void 0,(e=>{if(null==k||k(e),e.defaultPrevented)return;if(x)return;const t=null==b?void 0:b.element;t&&queueMicrotask((()=>{const e=i.getFirstTabbableIn.call(void 0,t,!0,!0);null==e||e.focus();"combobox"!==(null==e?void 0:e.getAttribute("role"))&&(null==e||e.click())}))}));return p=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{id:h,render:x?d.jsx.call(void 0,"label",{}):d.jsx.call(void 0,"span",{}),htmlFor:x?null==b?void 0:b.id:void 0},p),{ref:l.useMergeRefs.call(void 0,f,p.ref),onClick:E}),x||(p=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},p),{style:s.__spreadValues.call(void 0,{cursor:"default"},p.style)})),p=o.useCollectionItem.call(void 0,s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{store:a},p),{getItem:w}))})),p=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=v(e);return n.createElement.call(void 0,"label",t)})));t.FormLabel=p,t.useFormLabel=v},23184:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(91907),o=a(74525);a(9355),a(57870),a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.FormProvider=function(e={}){const t=r.useFormStore.call(void 0,e);return n.jsx.call(void 0,o.FormContextProvider,{value:t,children:e.children})}},12563:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(70419),n=a(21236);a(29842),a(57870),a(87121),a(73579);var l=a(19652),s=a(80987);a(7219);var i=a(28148),c=a(48959),u=a(51609);var d=l.createHook.call(void 0,(function(e){var t=e,{store:a,value:l,name:d,getItem:v,autoFocusOnClick:p=!0}=t,m=i.__objRest.call(void 0,t,["store","value","name","getItem","autoFocusOnClick"]);const h=r.useFormContext.call(void 0);a=a||h,c.invariant.call(void 0,a,!1);const f=`${d}`,[g,w]=u.useState.call(void 0,!1);u.useEffect.call(void 0,(()=>{var e;if(!g)return;const t=function(e,t){if(!e)return[];const a=[];for(const r of e){if("field"!==r.type)continue;if(!r.name.startsWith(t))continue;const e=r.name.replace(/(\.\d+)\..+$/,"$1"),o=new RegExp(`^${e}`);a.some((e=>o.test(e.name)))||a.push(r)}return a}(null==a?void 0:a.getState().items,f),r=null==(e=null==t?void 0:t[t.length-1])?void 0:e.element;r&&(r.focus(),w(!1))}),[a,g,f]);const b=u.useCallback.call(void 0,(e=>{const t=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{type:"button",name:f});return v?v(t):t}),[f,v]),y=m.onClick,x=s.useEvent.call(void 0,(e=>{null==y||y(e),e.defaultPrevented||(null==a||a.pushValue(f,l),p&&w(!0))}));return m=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},m),{onClick:x}),m=o.useButton.call(void 0,m),m=n.useCollectionItem.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{store:a},m),{getItem:b}))})),v=l.forwardRef.call(void 0,(function(e){const t=d(e);return l.createElement.call(void 0,"button",t)}));t.FormPush=v,t.useFormPush=d},61802:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(95563);a(69349),a(85171);var o=a(19652);a(80987),a(7219);var n=a(28148),l=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=n.__objRest.call(void 0,t,["store"]);return o=n.__spreadValues.call(void 0,{role:"radiogroup"},o),o=r.useFormGroup.call(void 0,o)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"div",t)}));t.FormRadioGroup=s,t.useFormRadioGroup=l},78864:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2627),o=a(74525),n=a(90041);a(64494),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(87121),a(73579);var l=a(19652);a(87636);var s=a(80987);a(7219);var i=a(28148),c=a(48959),u=l.createHook.call(void 0,(function(e){var t=e,{store:a,name:l,value:u}=t,d=i.__objRest.call(void 0,t,["store","name","value"]);const v=o.useFormContext.call(void 0);a=a||v,c.invariant.call(void 0,a,!1);const p=`${l}`,m=d.onChange,h=s.useEvent.call(void 0,(e=>{null==m||m(e),e.defaultPrevented||null==a||a.setValue(p,u)})),f=d.checked,g=a.useState((()=>null!=f?f:(null==a?void 0:a.getValue(p))===u));return d=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},d),{checked:g,onChange:h}),d=n.useRadio.call(void 0,i.__spreadValues.call(void 0,{value:u},d)),d=r.useFormControl.call(void 0,i.__spreadValues.call(void 0,{store:a,name:p,"aria-labelledby":void 0},d))})),d=l.memo.call(void 0,l.forwardRef.call(void 0,(function(e){const t=u(e);return l.createElement.call(void 0,"input",t)})));t.FormRadio=d,t.useFormRadio=u},46595:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(70419);a(29842),a(57870),a(87121),a(73579);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(92725),c=a(48959);var u=n.createHook.call(void 0,(function(e){var t=e,{store:a,name:n,index:u,autoFocusOnClick:d=!0}=t,v=s.__objRest.call(void 0,t,["store","name","index","autoFocusOnClick"]);const p=r.useFormContext.call(void 0);a=a||p,c.invariant.call(void 0,a,!1);const m=`${n}`,h=v.onClick,f=l.useEvent.call(void 0,(e=>{var t;if(null==h||h(e),e.defaultPrevented)return;if(!a)return;if(a.removeValue(m,u),!d)return;const{items:r}=a.getState(),o=function(e,t,a){const r=null==e?void 0:e.filter((e=>"field"===e.type&&e.name.startsWith(t))),o=new RegExp(`^${t}\\.(\\d+)`),n=null==r?void 0:r.find((e=>{const t=e.name.replace(o,"$1");return Number.parseInt(t)>a}));return n||(null==r?void 0:r.reverse().find((e=>{const t=e.name.replace(o,"$1");return Number.parseInt(t)"button"===e.type&&e.name===t))}(r,m);null==(t=null==e?void 0:e.element)||t.focus()}}));return v=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{},v),{onClick:f}),v=o.useButton.call(void 0,v)})),d=n.forwardRef.call(void 0,(function(e){const t=u(e);return n.createElement.call(void 0,"button",t)}));t.FormRemove=d,t.useFormRemove=u},46820:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(70419);a(29842),a(57870),a(87121),a(73579);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(48959),i=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const i=r.useFormContext.call(void 0);return a=a||i,s.invariant.call(void 0,a,!1),n=l.__spreadValues.call(void 0,{type:"reset",disabled:a.useState("submitting")},n),n=o.useButton.call(void 0,n)})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"button",t)}));t.FormReset=c,t.useFormReset=i},55166:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(91907);a(9355),a(87636),a(80987),a(7219),a(28148),t.useFormStore=r.useFormStore,t.useFormStoreProps=r.useFormStoreProps},71451:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525),o=a(70419);a(29842),a(57870),a(87121),a(73579);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(48959),i=n.createHook.call(void 0,(function(e){var t=e,{store:a,accessibleWhenDisabled:n=!0}=t,i=l.__objRest.call(void 0,t,["store","accessibleWhenDisabled"]);const c=r.useFormContext.call(void 0);return a=a||c,s.invariant.call(void 0,a,!1),i=l.__spreadValues.call(void 0,{type:"submit",disabled:a.useState("submitting")},i),i=o.useButton.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},i),{accessibleWhenDisabled:n}))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"button",t)}));t.FormSubmit=c,t.useFormSubmit=i},18266:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74525);a(57870);var o=a(19652),n=a(80987);a(7219);var l=a(28148),s=a(92725),i=a(48959),c=a(51609),u=a(10790),d="form";var v=o.createHook.call(void 0,(function(e){var t=e,{store:a,validateOnChange:o=!0,validateOnBlur:v=!0,resetOnUnmount:p=!1,resetOnSubmit:m=!0,autoFocusOnSubmit:h=!0}=t,f=l.__objRest.call(void 0,t,["store","validateOnChange","validateOnBlur","resetOnUnmount","resetOnSubmit","autoFocusOnSubmit"]);const g=r.useFormContext.call(void 0);a=a||g,i.invariant.call(void 0,a,!1);const w=c.useRef.call(void 0,null),b=a.useState("values"),y=a.useState("submitSucceed"),x=a.useState("submitFailed"),_=a.useState("items"),k=n.useInitialValue.call(void 0,b);c.useEffect.call(void 0,(()=>p?null==a?void 0:a.reset:void 0),[p,a]),n.useUpdateEffect.call(void 0,(()=>{o&&b!==k&&(null==a||a.validate())}),[o,b,k,a]),c.useEffect.call(void 0,(()=>{m&&y&&(null==a||a.reset())}),[m,y,a]);const[E,C]=c.useState.call(void 0,!1);c.useEffect.call(void 0,(()=>{if(!E)return;if(!x)return;const e=function(e){return e.find((e=>{var t;return"field"===e.type&&"true"===(null==(t=e.element)?void 0:t.getAttribute("aria-invalid"))}))}(_),t=null==e?void 0:e.element;t&&(C(!1),t.focus(),s.isTextField.call(void 0,t)&&t.select())}),[h,x,_]);const j=f.onSubmit,A=n.useEvent.call(void 0,(e=>{null==j||j(e),e.defaultPrevented||(e.preventDefault(),null==a||a.submit(),h&&C(!0))})),S=f.onBlur,P=n.useEvent.call(void 0,(e=>{null==S||S(e),e.defaultPrevented||v&&a&&function(e,t){return t.some((t=>"field"===t.type&&t.element===e))}(e.target,a.getState().items)&&a.validate()})),R=f.onReset,M=n.useEvent.call(void 0,(e=>{null==R||R(e),e.defaultPrevented||(e.preventDefault(),null==a||a.reset())}));f=n.useWrapElement.call(void 0,f,(e=>u.jsx.call(void 0,r.FormScopedContextProvider,{value:a,children:e})),[a]);const V=n.useTagName.call(void 0,w,d);return f=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{role:"form"!==V?"form":void 0,noValidate:!0},f),{ref:n.useMergeRefs.call(void 0,w,f.ref),onSubmit:A,onBlur:P,onReset:M})})),p=o.forwardRef.call(void 0,(function(e){const t=v(e);return o.createElement.call(void 0,d,t)}));t.Form=p,t.useForm=v},30549:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(50864);a(85171),a(19652),a(80987),a(7219),a(28148),t.GroupLabel=r.GroupLabel,t.useGroupLabel=r.useGroupLabel},66128:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(69349);a(85171),a(19652),a(80987),a(7219),a(28148),t.Group=r.Group,t.useGroup=r.useGroup},94029:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32146);a(63215),a(28148),t.HeadingLevel=r.HeadingLevel},2720:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(35174);a(63215),a(19652),a(80987),a(7219),a(28148),t.Heading=r.Heading,t.useHeading=r.useHeading},54522:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21407);a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.HovercardAnchor=r.HovercardAnchor,t.useHovercardAnchor=r.useHovercardAnchor},40804:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(79066);a(45081);var o=a(80231);a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useHovercardContext.call(void 0);return a=a||s,n=r.usePopoverArrow.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"div",t)}));t.HovercardArrow=i,t.useHovercardArrow=s},41354:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80231);a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.HovercardContextProvider=r.HovercardContextProvider,t.HovercardScopedContextProvider=r.HovercardScopedContextProvider,t.useHovercardContext=r.useHovercardContext,t.useHovercardProviderContext=r.useHovercardProviderContext,t.useHovercardScopedContext=r.useHovercardScopedContext},54929:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77864);a(58058),a(99992),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.HovercardDescription=r.HovercardDescription,t.useHovercardDescription=r.useHovercardDescription},34650:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(49190);a(56203),a(70419),a(29842);var o=a(80231);a(77018),a(53944),a(16299),a(87121),a(73579);var n=a(3578),l=a(19652),s=a(80987);a(7219);var i=a(28148),c=a(92725),u=a(77328),d=a(48959),v=a(8766),p=a(51609),m=a(10790),h=l.createHook.call(void 0,(function(e){var t=e,{store:a}=t,l=i.__objRest.call(void 0,t,["store"]);const h=o.useHovercardProviderContext.call(void 0);a=a||h,d.invariant.call(void 0,a,!1);const[f,g]=p.useState.call(void 0,!1);p.useEffect.call(void 0,(()=>{if(!f)return;return u.addGlobalEventListener.call(void 0,"focusout",(e=>{if(!a)return;const t=e.relatedTarget;if(t){const{anchorElement:e,popoverElement:r,disclosureElement:o}=a.getState();if(e&&c.contains.call(void 0,e,t))return;if(r&&c.contains.call(void 0,r,t))return;if(o&&c.contains.call(void 0,o,t))return;if(t.hasAttribute("data-focus-trap"))return}g(!1)}),!0)}),[f,a]),p.useEffect.call(void 0,(()=>v.sync.call(void 0,a,["anchorElement"],(e=>{const t=e.anchorElement;if(!t)return;const a=new MutationObserver((()=>{t.hasAttribute("data-focus-visible")&&g(!0)}));return a.observe(t,{attributeFilter:["data-focus-visible"]}),()=>a.disconnect()}))),[a]);const w=l.onClick,b=s.useEvent.call(void 0,(e=>{null==w||w(e),e.defaultPrevented||null==a||a.setAutoFocusOnShow(!0)})),y=l.onFocus,x=s.useEvent.call(void 0,(e=>{null==y||y(e),e.defaultPrevented||g(!0)})),{style:_}=n.useVisuallyHidden.call(void 0);f||(l=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},l),{style:i.__spreadValues.call(void 0,i.__spreadValues.call(void 0,{},_),l.style)}));const k=m.jsx.call(void 0,"svg",{display:"block",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,viewBox:"0 0 16 16",height:"1em",width:"1em",children:m.jsx.call(void 0,"polyline",{points:"4,6 8,10 12,6"})});return l=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{children:k},l),{ref:s.useMergeRefs.call(void 0,a.setDisclosureElement,l.ref),onClick:b,onFocus:x}),l=r.useDialogDisclosure.call(void 0,i.__spreadValues.call(void 0,{store:a},l))})),f=l.forwardRef.call(void 0,(function(e){const t=h(e);return l.createElement.call(void 0,"button",t)}));t.HovercardDisclosure=f,t.useHovercardDisclosure=h},81439:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(97322);a(90604),a(60762),a(70419),a(29842),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.HovercardDismiss=r.HovercardDismiss,t.useHovercardDismiss=r.useHovercardDismiss},3129:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39490);a(33356),a(22510),a(35174),a(63215),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.HovercardHeading=r.HovercardHeading,t.useHovercardHeading=r.useHovercardHeading},95522:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80231);a(77018),a(53944),a(16299),a(19652);var o=a(46423);a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.HovercardProvider=function(e={}){const t=o.useHovercardStore.call(void 0,e);return n.jsx.call(void 0,r.HovercardContextProvider,{value:t,children:e.children})}},51776:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(46423);a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.useHovercardStore=r.useHovercardStore,t.useHovercardStoreProps=r.useHovercardStoreProps},32880:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(82109);a(68725),a(39861),a(28293),a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(3578),a(19652),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.Hovercard=r.Hovercard,t.useHovercard=r.useHovercard},79732:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168);a(48427);var o=a(79066);a(45081),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=r.useMenuContext.call(void 0);return a=a||s,o.usePopoverArrow.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"div",t)}));t.MenuArrow=i,t.useMenuArrow=s},97162:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(50858);a(48427),a(32413),a(99366),a(9355),a(42076),a(57870),a(19652),a(87636),a(80987),a(7219);var o=a(28148),n=a(51609),l=a(10790);t.MenuBarProvider=function(e={}){return n.useEffect.call(void 0,(()=>{0}),[]),l.jsx.call(void 0,r.MenubarProvider,o.__spreadValues.call(void 0,{},e))}},70856:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32413);a(99366),a(9355),a(87636),a(80987),a(7219),a(28148);var o=a(51609);t.useMenuBarStore=function(e={}){return o.useEffect.call(void 0,(()=>{0}),[]),r.useMenubarStore.call(void 0,e)},t.useMenuBarStoreProps=function(e,t,a){return r.useMenubarStoreProps.call(void 0,e,t,a)}},17848:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(18874);a(48427),a(32413),a(9229),a(40227),a(99366),a(9355),a(42076),a(57870),a(87121),a(73579);var o=a(19652);a(87636),a(80987),a(7219),a(28148);var n=a(51609),l=o.createHook.call(void 0,(function(e){return n.useEffect.call(void 0,(()=>{0}),[]),r.useMenubar.call(void 0,e)})),s=o.forwardRef.call(void 0,(function(e){const t=l(e);return o.createElement.call(void 0,"div",t)}));t.MenuBar=s,t.useMenuBar=l},84281:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168);a(48427);var o=a(77673);a(42076),a(57870),a(80231),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=r.useMenuContext.call(void 0);return a=a||s,n=o.usePopoverDisclosureArrow.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"span",t)}));t.MenuButtonArrow=i,t.useMenuButtonArrow=s},17517:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168);a(48427);var o=a(66342);a(49190),a(56203),a(51500),a(70419);var n=a(68666);a(29842);var l=a(21407);a(40227),a(42076),a(57870);var s=a(12707);a(80231),a(77018),a(53944),a(16299),a(87121),a(73579);var i=a(19652),c=a(87636),u=a(80987);a(7219);var d=a(28148),v=a(92725),p=a(48959),m=a(51609),h=a(10790);function f(e,t){return!!(null==e?void 0:e.some((e=>!!e.element&&(e.element!==t&&"true"===e.element.getAttribute("aria-expanded")))))}var g=i.createHook.call(void 0,(function(e){var t=e,{store:a,focusable:i,accessibleWhenDisabled:g,showOnHover:w}=t,b=d.__objRest.call(void 0,t,["store","focusable","accessibleWhenDisabled","showOnHover"]);const y=r.useMenuProviderContext.call(void 0);a=a||y,p.invariant.call(void 0,a,!1);const x=m.useRef.call(void 0,null),_=a.parent,k=a.menubar,E=!!_,C=!!k&&!E,j=p.disabledFromProps.call(void 0,b),A=()=>{const e=x.current;e&&(null==a||a.setDisclosureElement(e),null==a||a.setAnchorElement(e),null==a||a.show())},S=b.onFocus,P=u.useEvent.call(void 0,(e=>{if(null==S||S(e),j)return;if(e.defaultPrevented)return;if(null==a||a.setAutoFocusOnShow(!1),null==a||a.setActiveId(null),!k)return;if(!C)return;const{items:t}=k.getState();f(t,e.currentTarget)&&A()})),R=c.useStoreState.call(void 0,a,(e=>e.placement.split("-")[0])),M=b.onKeyDown,V=u.useEvent.call(void 0,(e=>{if(null==M||M(e),j)return;if(e.defaultPrevented)return;const t=function(e,t){return{ArrowDown:("bottom"===t||"top"===t)&&"first",ArrowUp:("bottom"===t||"top"===t)&&"last",ArrowRight:"right"===t&&"first",ArrowLeft:"left"===t&&"first"}[e.key]}(e,R);t&&(e.preventDefault(),A(),null==a||a.setAutoFocusOnShow(!0),null==a||a.setInitialFocus(t))})),z=b.onClick,H=u.useEvent.call(void 0,(e=>{if(null==z||z(e),e.defaultPrevented)return;if(!a)return;const t=!e.detail,{open:r}=a.getState();r&&!t||(E&&!t||a.setAutoFocusOnShow(!0),a.setInitialFocus(t?"first":"container")),E&&A()}));b=u.useWrapElement.call(void 0,b,(e=>h.jsx.call(void 0,r.MenuContextProvider,{value:a,children:e})),[a]),E&&(b=d.__spreadProps.call(void 0,d.__spreadValues.call(void 0,{},b),{render:h.jsx.call(void 0,s.Role.div,{render:b.render})}));const L=u.useId.call(void 0,b.id),O=c.useStoreState.call(void 0,(null==_?void 0:_.combobox)||_,"contentElement"),N=E||C?v.getPopupItemRole.call(void 0,O,"menuitem"):void 0,I=a.useState("contentElement");return b=d.__spreadProps.call(void 0,d.__spreadValues.call(void 0,{id:L,role:N,"aria-haspopup":v.getPopupRole.call(void 0,I,"menu")},b),{ref:u.useMergeRefs.call(void 0,x,b.ref),onFocus:P,onKeyDown:V,onClick:H}),b=l.useHovercardAnchor.call(void 0,d.__spreadProps.call(void 0,d.__spreadValues.call(void 0,{store:a,focusable:i,accessibleWhenDisabled:g},b),{showOnHover:e=>{if(!(()=>{if("function"==typeof w)return w(e);if(null!=w)return w;if(E)return!0;if(!k)return!1;const{items:t}=k.getState();return C&&f(t)})())return!1;const t=C?k:_;return!t||(t.setActiveId(e.currentTarget.id),!0)}})),b=o.usePopoverDisclosure.call(void 0,d.__spreadValues.call(void 0,{store:a,toggleOnClick:!E,focusable:i,accessibleWhenDisabled:g},b)),b=n.useCompositeTypeahead.call(void 0,d.__spreadValues.call(void 0,{store:a,typeahead:C},b))})),w=i.forwardRef.call(void 0,(function(e){const t=g(e);return i.createElement.call(void 0,"button",t)}));t.MenuButton=w,t.useMenuButton=g},66906:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168);a(48427),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.MenuBarContextProvider=r.MenuBarContextProvider,t.MenuBarScopedContextProvider=r.MenuBarScopedContextProvider,t.MenuContextProvider=r.MenuContextProvider,t.MenuItemCheckedContext=r.MenuItemCheckedContext,t.MenuScopedContextProvider=r.MenuScopedContextProvider,t.useMenuBarContext=r.useMenuBarContext,t.useMenuBarProviderContext=r.useMenuBarProviderContext,t.useMenuBarScopedContext=r.useMenuBarScopedContext,t.useMenuContext=r.useMenuContext,t.useMenuProviderContext=r.useMenuProviderContext,t.useMenuScopedContext=r.useMenuScopedContext},91425:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77864);a(58058),a(99992),a(53944),a(16299);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useHovercardDescription.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"p",t)}));t.MenuDescription=l,t.useMenuDescription=n},54415:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(97322),o=a(7168);a(48427),a(90604),a(60762),a(70419),a(29842),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useMenuScopedContext.call(void 0);return a=a||s,n=r.useHovercardDismiss.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"button",t)}));t.MenuDismiss=i,t.useMenuDismiss=s},15995:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(59190);a(50864),a(85171);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useCompositeGroupLabel.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"div",t)}));t.MenuGroupLabel=l,t.useMenuGroupLabel=n},45242:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(91520);a(69349),a(85171);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useCompositeGroup.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"div",t)}));t.MenuGroup=l,t.useMenuGroup=n},87593:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39490);a(33356),a(22510),a(35174),a(63215),a(53944),a(16299);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useHovercardHeading.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"h1",t)}));t.MenuHeading=l,t.useMenuHeading=n},42259:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168);a(48427);var o=a(53443);a(67804),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(51609),i=n.createHook.call(void 0,(function(e){var t=e,{store:a,checked:n}=t,i=l.__objRest.call(void 0,t,["store","checked"]);const c=s.useContext.call(void 0,r.MenuItemCheckedContext);return n=null!=n?n:c,i=o.useCheckboxCheck.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},i),{checked:n}))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"span",t)}));t.MenuItemCheck=c,t.useMenuItemCheck=i},2610:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(71385),o=a(26621);a(85826);var n=a(92526),l=a(7168);a(48427),a(61150),a(67804),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579);var s=a(19652);a(87636);var i=a(80987);a(7219);var c=a(28148),u=a(48959),d=a(51609);function v(e,t,a){if(void 0===t)return Array.isArray(e)?e:!!a;const r=function(e){return Array.isArray(e)?e.toString():e}(t);return Array.isArray(e)?a?e.includes(r)?e:[...e,r]:e.filter((e=>e!==r)):a?r:e!==r&&e}var p=s.createHook.call(void 0,(function(e){var t=e,{store:a,name:s,value:p,checked:m,defaultChecked:h,hideOnClick:f=!1}=t,g=c.__objRest.call(void 0,t,["store","name","value","checked","defaultChecked","hideOnClick"]);const w=l.useMenuScopedContext.call(void 0);a=a||w,u.invariant.call(void 0,a,!1);const b=i.useInitialValue.call(void 0,h);d.useEffect.call(void 0,(()=>{null==a||a.setValue(s,((e=[])=>b?v(e,p,!0):e))}),[a,s,p,b]),d.useEffect.call(void 0,(()=>{void 0!==m&&(null==a||a.setValue(s,(e=>v(e,p,m))))}),[a,s,p,m]);const y=o.useCheckboxStore.call(void 0,{value:a.useState((e=>e.values[s])),setValue(e){null==a||a.setValue(s,(()=>{if(void 0===m)return e;const t=v(e,p,m);return Array.isArray(t)&&Array.isArray(e)&&u.shallowEqual.call(void 0,e,t)?e:t}))}});return g=c.__spreadValues.call(void 0,{role:"menuitemcheckbox"},g),g=r.useCheckbox.call(void 0,c.__spreadValues.call(void 0,{store:y,name:s,value:p,checked:m},g)),g=n.useMenuItem.call(void 0,c.__spreadValues.call(void 0,{store:a,hideOnClick:f},g))})),m=s.memo.call(void 0,s.forwardRef.call(void 0,(function(e){const t=p(e);return s.createElement.call(void 0,"div",t)})));t.MenuItemCheckbox=m,t.useMenuItemCheckbox=p},70334:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(92526),o=a(7168);a(48427);var n=a(90041);a(64494),a(61150),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579);var l=a(19652);a(87636);var s=a(80987);a(7219);var i=a(28148),c=a(48959),u=a(51609),d=a(10790);function v(e,t,a){return void 0===a?e:a?t:e}var p=l.createHook.call(void 0,(function(e){var t=e,{store:a,name:l,value:p,checked:m,onChange:h,hideOnClick:f=!1}=t,g=i.__objRest.call(void 0,t,["store","name","value","checked","onChange","hideOnClick"]);const w=o.useMenuScopedContext.call(void 0);a=a||w,c.invariant.call(void 0,a,!1);const b=s.useInitialValue.call(void 0,g.defaultChecked);u.useEffect.call(void 0,(()=>{null==a||a.setValue(l,((e=!1)=>v(e,p,b)))}),[a,l,p,b]),u.useEffect.call(void 0,(()=>{void 0!==m&&(null==a||a.setValue(l,(e=>v(e,p,m))))}),[a,l,p,m]);const y=a.useState((e=>e.values[l]===p));return g=s.useWrapElement.call(void 0,g,(e=>d.jsx.call(void 0,o.MenuItemCheckedContext.Provider,{value:!!y,children:e})),[y]),g=i.__spreadValues.call(void 0,{role:"menuitemradio"},g),g=n.useRadio.call(void 0,i.__spreadValues.call(void 0,{name:l,value:p,checked:y,onChange(e){if(null==h||h(e),e.defaultPrevented)return;const t=e.currentTarget;null==a||a.setValue(l,(e=>v(e,p,null!=m?m:t.checked)))}},g)),g=r.useMenuItem.call(void 0,i.__spreadValues.call(void 0,{store:a,hideOnClick:f},g))})),m=l.memo.call(void 0,l.forwardRef.call(void 0,(function(e){const t=p(e);return l.createElement.call(void 0,"div",t)})));t.MenuItemRadio=m,t.useMenuItemRadio=p},28592:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(92526);a(7168),a(48427),a(61150),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.MenuItem=r.MenuItem,t.useMenuItem=r.useMenuItem},78933:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(41196);a(7168),a(48427),a(68666),a(9229),a(40227),a(42076),a(57870),a(77723),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.MenuList=r.MenuList,t.useMenuList=r.useMenuList},92466:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(93704),o=a(7168);a(48427),a(96475),a(99366),a(9355),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(19652),a(46423),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.MenuProvider=function(e={}){const t=r.useMenuStore.call(void 0,e);return n.jsx.call(void 0,o.MenuContextProvider,{value:t,children:e.children})}},75854:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(7168);a(48427);var o=a(86005);a(52954),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=r.useMenuContext.call(void 0);return a=a||s,n=o.useCompositeSeparator.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"hr",t)}));t.MenuSeparator=i,t.useMenuSeparator=s},84592:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(93704);a(7168),a(48427),a(96475),a(99366),a(9355),a(42076),a(57870),a(80231),a(77018),a(53944),a(16299),a(19652),a(46423),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.useMenuStore=r.useMenuStore,t.useMenuStoreProps=r.useMenuStoreProps},94112:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(41196),o=a(7168);a(48427),a(68666),a(9229),a(40227),a(42076),a(57870);var n=a(82109);a(68725),a(39861);var l=a(28293);a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707),a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(3578);var s=a(19652);a(95691),a(38980);var i=a(87636),c=a(80987);a(7219);var u=a(28148),d=a(77328),v=a(60877),p=a(48959),m=a(51609),h=s.createHook.call(void 0,(function(e){var t=e,{store:a,modal:l=!1,portal:s=!!l,hideOnEscape:h=!0,autoFocusOnShow:f=!0,hideOnHoverOutside:g,alwaysVisible:w}=t,b=u.__objRest.call(void 0,t,["store","modal","portal","hideOnEscape","autoFocusOnShow","hideOnHoverOutside","alwaysVisible"]);const y=o.useMenuProviderContext.call(void 0);a=a||y,p.invariant.call(void 0,a,!1);const x=m.useRef.call(void 0,null),_=a.parent,k=a.menubar,E=!!_,C=!!k&&!E;b=u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{},b),{ref:c.useMergeRefs.call(void 0,x,b.ref)});const j=r.useMenuList.call(void 0,u.__spreadValues.call(void 0,{store:a,alwaysVisible:w},b)),{"aria-labelledby":A}=j;b=u.__objRest.call(void 0,j,["aria-labelledby"]);const[S,P]=m.useState.call(void 0),R=a.useState("autoFocusOnShow"),M=a.useState("initialFocus"),V=a.useState("baseElement"),z=a.useState("renderedItems");m.useEffect.call(void 0,(()=>{let e=!1;return P((t=>{var a,r,o;if(e)return;if(!R)return;if(null==(a=null==t?void 0:t.current)?void 0:a.isConnected)return t;const n=m.createRef.call(void 0);switch(M){case"first":n.current=(null==(r=z.find((e=>!e.disabled&&e.element)))?void 0:r.element)||null;break;case"last":n.current=(null==(o=[...z].reverse().find((e=>!e.disabled&&e.element)))?void 0:o.element)||null;break;default:n.current=V}return n})),()=>{e=!0}}),[a,R,M,z,V]);const H=!E&&l,L=!!f,O=!!S||!!b.initialFocus||!!H,N=i.useStoreState.call(void 0,a.combobox||a,"contentElement"),I=i.useStoreState.call(void 0,(null==_?void 0:_.combobox)||_,"contentElement"),B=m.useMemo.call(void 0,(()=>{if(!I)return;if(!N)return;const e=N.getAttribute("role"),t=I.getAttribute("role");return"menu"!==t&&"menubar"!==t||"menu"!==e?I:void 0}),[N,I]);return void 0!==B&&(b=u.__spreadValues.call(void 0,{preserveTabOrderAnchor:B},b)),b=n.useHovercard.call(void 0,u.__spreadProps.call(void 0,u.__spreadValues.call(void 0,{store:a,alwaysVisible:w,initialFocus:S,autoFocusOnShow:L?O&&f:R||!!H},b),{hideOnEscape:e=>!p.isFalsyBooleanCallback.call(void 0,h,e)&&(null==a||a.hideAll(),!0),hideOnHoverOutside(e){const t=null==a?void 0:a.getState().disclosureElement;return!!("function"==typeof g?g(e):null!=g?g:E||C&&(!t||!v.hasFocusWithin.call(void 0,t)))&&(!!e.defaultPrevented||(!E||(!t||(d.fireEvent.call(void 0,t,"mouseout",e),!v.hasFocusWithin.call(void 0,t)||(requestAnimationFrame((()=>{v.hasFocusWithin.call(void 0,t)||null==a||a.hide()})),!1)))))},modal:H,portal:s,backdrop:!E&&b.backdrop})),b=u.__spreadValues.call(void 0,{"aria-labelledby":A},b)})),f=l.createDialogComponent.call(void 0,s.forwardRef.call(void 0,(function(e){const t=h(e);return s.createElement.call(void 0,"div",t)})),o.useMenuProviderContext);t.Menu=f,t.useMenu=h},21046:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(48427);a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.MenuItemCheckedContext=r.MenuItemCheckedContext,t.MenubarContextProvider=r.MenubarContextProvider,t.MenubarScopedContextProvider=r.MenubarScopedContextProvider,t.useMenubarContext=r.useMenubarContext,t.useMenubarProviderContext=r.useMenubarProviderContext,t.useMenubarScopedContext=r.useMenubarScopedContext},76590:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(50858);a(48427),a(32413),a(99366),a(9355),a(42076),a(57870),a(19652),a(87636),a(80987),a(7219),a(28148),t.MenubarProvider=r.MenubarProvider},60876:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32413);a(99366),a(9355),a(87636),a(80987),a(7219),a(28148),t.useMenubarStore=r.useMenubarStore,t.useMenubarStoreProps=r.useMenubarStoreProps},66732:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(18874);a(48427),a(32413),a(9229),a(40227),a(99366),a(9355),a(42076),a(57870),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.Menubar=r.Menubar,t.useMenubar=r.useMenubar},77850:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51500);a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.PopoverAnchor=r.PopoverAnchor,t.usePopoverAnchor=r.usePopoverAnchor},84612:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(79066);a(45081),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.PopoverArrow=r.PopoverArrow,t.usePopoverArrow=r.usePopoverArrow},61930:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77018);a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.PopoverContextProvider=r.PopoverContextProvider,t.PopoverScopedContextProvider=r.PopoverScopedContextProvider,t.usePopoverContext=r.usePopoverContext,t.usePopoverProviderContext=r.usePopoverProviderContext,t.usePopoverScopedContext=r.usePopoverScopedContext},47729:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(58058);a(99992),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.PopoverDescription=r.PopoverDescription,t.usePopoverDescription=r.usePopoverDescription},36526:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77673);a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.PopoverDisclosureArrow=r.PopoverDisclosureArrow,t.usePopoverDisclosureArrow=r.usePopoverDisclosureArrow},36634:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(66342);a(49190),a(56203),a(51500),a(70419),a(29842),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.PopoverDisclosure=r.PopoverDisclosure,t.usePopoverDisclosure=r.usePopoverDisclosure},26111:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(90604);a(60762),a(70419),a(29842),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(80987),a(7219),a(28148),t.PopoverDismiss=r.PopoverDismiss,t.usePopoverDismiss=r.usePopoverDismiss},39257:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(33356);a(22510),a(35174),a(63215),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.PopoverHeading=r.PopoverHeading,t.usePopoverHeading=r.usePopoverHeading},25570:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(77018);a(53944),a(16299),a(19652);var o=a(44448);a(95691),a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.PopoverProvider=function(e={}){const t=o.usePopoverStore.call(void 0,e);return n.jsx.call(void 0,r.PopoverContextProvider,{value:t,children:e.children})}},40416:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44448);a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.usePopoverStore=r.usePopoverStore,t.usePopoverStoreProps=r.usePopoverStoreProps},58416:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(39861);a(28293),a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707),a(77018),a(53944),a(16299),a(87121),a(73579),a(3578),a(19652),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.Popover=r.Popover,t.usePopover=r.usePopover},67548:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67722);a(28148),t.PortalContext=r.PortalContext},58502:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9018);a(54844),a(67722),a(3578),a(19652),a(80987),a(7219),a(28148),t.Portal=r.Portal,t.usePortal=r.usePortal},51298:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(64494);a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.RadioContextProvider=r.RadioContextProvider,t.RadioScopedContextProvider=r.RadioScopedContextProvider,t.useRadioContext=r.useRadioContext,t.useRadioProviderContext=r.useRadioProviderContext,t.useRadioScopedContext=r.useRadioScopedContext},3970:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(64494),o=a(9229);a(40227),a(42076),a(57870),a(87121),a(73579);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(10790),u=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=s.__objRest.call(void 0,t,["store"]);const u=r.useRadioProviderContext.call(void 0);return a=a||u,i.invariant.call(void 0,a,!1),n=l.useWrapElement.call(void 0,n,(e=>c.jsx.call(void 0,r.RadioScopedContextProvider,{value:a,children:e})),[a]),n=s.__spreadValues.call(void 0,{role:"radiogroup"},n),n=o.useComposite.call(void 0,s.__spreadValues.call(void 0,{store:a},n))})),d=n.forwardRef.call(void 0,(function(e){const t=u(e);return n.createElement.call(void 0,"div",t)}));t.RadioGroup=d,t.useRadioGroup=u},14490:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(12019),o=a(64494);a(99366),a(9355),a(42076),a(57870),a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.RadioProvider=function(e={}){const t=r.useRadioStore.call(void 0,e);return n.jsx.call(void 0,o.RadioContextProvider,{value:t,children:e.children})}},63512:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(12019);a(99366),a(9355),a(87636),a(80987),a(7219),a(28148),t.useRadioStore=r.useRadioStore,t.useRadioStoreProps=r.useRadioStoreProps},57672:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(90041);a(64494),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.Radio=r.Radio,t.useRadio=r.useRadio},2462:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(12707);a(19652),a(80987),a(7219),a(28148),t.Role=r.Role,t.useRole=r.useRole},92622:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(46503);a(77673),a(72707),a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.SelectArrow=r.SelectArrow,t.useSelectArrow=r.useSelectArrow},40432:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(72707);a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.SelectContextProvider=r.SelectContextProvider,t.SelectHeadingContext=r.SelectHeadingContext,t.SelectItemCheckedContext=r.SelectItemCheckedContext,t.SelectScopedContextProvider=r.SelectScopedContextProvider,t.useSelectContext=r.useSelectContext,t.useSelectProviderContext=r.useSelectProviderContext,t.useSelectScopedContext=r.useSelectScopedContext},45045:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(90604);a(60762),a(70419);var o=a(72707);a(29842),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useSelectScopedContext.call(void 0);return a=a||s,n=r.usePopoverDismiss.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"button",t)}));t.SelectDismiss=i,t.useSelectDismiss=s},42149:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(59190);a(50864),a(85171);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useCompositeGroupLabel.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"div",t)}));t.SelectGroupLabel=l,t.useSelectGroupLabel=n},18080:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(91520);a(69349),a(85171);var o=a(19652);a(80987),a(7219),a(28148);var n=o.createHook.call(void 0,(function(e){return e=r.useCompositeGroup.call(void 0,e)})),l=o.forwardRef.call(void 0,(function(e){const t=n(e);return o.createElement.call(void 0,"div",t)}));t.SelectGroup=l,t.useSelectGroup=n},26219:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(33356);a(22510),a(35174);var o=a(72707);a(42076),a(57870),a(63215),a(77018),a(53944),a(16299);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(51609),c=n.createHook.call(void 0,(function(e){const[,t]=i.useContext.call(void 0,o.SelectHeadingContext)||[],a=l.useId.call(void 0,e.id);return l.useSafeLayoutEffect.call(void 0,(()=>(null==t||t(a),()=>null==t?void 0:t(void 0))),[t,a]),e=s.__spreadValues.call(void 0,{id:a},e),e=r.usePopoverHeading.call(void 0,e)})),u=n.forwardRef.call(void 0,(function(e){const t=c(e);return n.createElement.call(void 0,"h1",t)}));t.SelectHeading=u,t.useSelectHeading=c},12933:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(53443);a(67804);var o=a(72707);a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(51609),i=n.createHook.call(void 0,(function(e){var t=e,{store:a,checked:n}=t,i=l.__objRest.call(void 0,t,["store","checked"]);const c=s.useContext.call(void 0,o.SelectItemCheckedContext);return n=null!=n?n:c,i=r.useCheckboxCheck.call(void 0,l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{},i),{checked:n}))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"span",t)}));t.SelectItemCheck=c,t.useSelectItemCheck=i},28670:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(42888);a(61150),a(72707),a(35973),a(21236),a(29842),a(40227),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.SelectItem=r.SelectItem,t.useSelectItem=r.useSelectItem},93019:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(72707);a(42076),a(57870),a(77018),a(53944),a(16299);var o=a(19652),n=a(80987);a(7219);var l=a(28148),s=a(48959),i=o.createHook.call(void 0,(function(e){var t=e,{store:a}=t,o=l.__objRest.call(void 0,t,["store"]);const i=r.useSelectProviderContext.call(void 0);a=a||i,s.invariant.call(void 0,a,!1);const c=n.useId.call(void 0,o.id),u=o.onClick,d=n.useEvent.call(void 0,(e=>{null==u||u(e),e.defaultPrevented||queueMicrotask((()=>{const e=null==a?void 0:a.getState().selectElement;null==e||e.focus()}))}));return o=l.__spreadProps.call(void 0,l.__spreadValues.call(void 0,{id:c},o),{ref:n.useMergeRefs.call(void 0,a.setLabelElement,o.ref),onClick:d,style:l.__spreadValues.call(void 0,{cursor:"default"},o.style)}),s.removeUndefinedValues.call(void 0,o)})),c=o.memo.call(void 0,o.forwardRef.call(void 0,(function(e){const t=i(e);return o.createElement.call(void 0,"div",t)})));t.SelectLabel=c,t.useSelectLabel=i},68175:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32816);a(68666),a(72707),a(9229),a(40227),a(42076),a(57870),a(77723),a(77018),a(53944),a(16299),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.SelectList=r.SelectList,t.useSelectList=r.useSelectList},21506:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32816);a(68666);var o=a(72707);a(9229),a(40227),a(42076),a(57870);var n=a(39861),l=a(28293);a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707),a(77018),a(53944),a(16299),a(87121),a(73579),a(3578);var s=a(19652);a(95691),a(38980),a(87636),a(80987),a(7219);var i=a(28148),c=s.createHook.call(void 0,(function(e){var t=e,{store:a,alwaysVisible:l}=t,s=i.__objRest.call(void 0,t,["store","alwaysVisible"]);const c=o.useSelectProviderContext.call(void 0);return a=a||c,s=r.useSelectList.call(void 0,i.__spreadValues.call(void 0,{store:a,alwaysVisible:l},s)),s=n.usePopover.call(void 0,i.__spreadValues.call(void 0,{store:a,alwaysVisible:l},s))})),u=l.createDialogComponent.call(void 0,s.forwardRef.call(void 0,(function(e){const t=c(e);return s.createElement.call(void 0,"div",t)})),o.useSelectProviderContext);t.SelectPopover=u,t.useSelectPopover=c},16016:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(65320);a(96475);var o=a(72707);a(99366),a(9355),a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.SelectProvider=function(e={}){const t=r.useSelectStore.call(void 0,e);return n.jsx.call(void 0,o.SelectContextProvider,{value:t,children:e.children})}},57197:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(22225),o=a(72707);a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(92725),i=a(48959),c=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const c=o.useSelectContext.call(void 0);a=a||c,i.invariant.call(void 0,a,!1);const u=a.useState("listElement"),d="grid"===s.getPopupRole.call(void 0,u)?"row":"presentation";return n=l.__spreadValues.call(void 0,{role:d},n),n=r.useCompositeRow.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),u=n.forwardRef.call(void 0,(function(e){const t=c(e);return n.createElement.call(void 0,"div",t)}));t.SelectRow=u,t.useSelectRow=c},67056:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(72707),o=a(86005);a(52954),a(42076),a(57870),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=r.useSelectContext.call(void 0);return a=a||s,n=o.useCompositeSeparator.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"hr",t)}));t.SelectSeparator=i,t.useSelectSeparator=s},30494:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(65320);a(96475),a(99366),a(9355),a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.useSelectStore=r.useSelectStore,t.useSelectStoreOptions=r.useSelectStoreOptions,t.useSelectStoreProps=r.useSelectStoreProps},28226:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(72707);a(42076),a(57870),a(77018),a(53944),a(16299),a(19652);var o=a(87636);a(80987),a(7219),a(28148),t.SelectValue=function({store:e,fallback:t,children:a}={}){const n=r.useSelectContext.call(void 0);e=e||n;const l=o.useStoreState.call(void 0,e,(e=>(null==e?void 0:e.value.length)?e.value:t));return a?a(l||""):l}},75418:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(66342);a(49190),a(56203),a(51500);var o=a(46503);a(77673),a(70419);var n=a(68666),l=a(72707);a(29842),a(40227),a(42076),a(57870),a(77018),a(53944),a(16299),a(87121),a(73579);var s=a(19652),i=a(80987);a(7219);var c=a(28148),u=a(11790),d=a(92725),v=a(77328),p=a(48959),m=a(51609),h=a(10790);function f(e,t){return()=>{const a=t();if(!a)return;let r=0,o=e.item(a);const n=o;for(;o&&null==o.value;){const a=t(++r);if(!a)return;if(o=e.item(a),o===n)break}return null==o?void 0:o.id}}var g=s.createHook.call(void 0,(function(e){var t=e,{store:a,name:s,form:g,required:w,showOnKeyDown:b=!0,moveOnKeyDown:y=!0,toggleOnPress:x=!0,toggleOnClick:_=x}=t,k=c.__objRest.call(void 0,t,["store","name","form","required","showOnKeyDown","moveOnKeyDown","toggleOnPress","toggleOnClick"]);const E=l.useSelectProviderContext.call(void 0);a=a||E,p.invariant.call(void 0,a,!1);const C=k.onKeyDown,j=i.useBooleanEvent.call(void 0,b),A=i.useBooleanEvent.call(void 0,y),S=a.useState("placement").split("-")[0],P=a.useState("value"),R=Array.isArray(P),M=i.useEvent.call(void 0,(e=>{var t;if(null==C||C(e),e.defaultPrevented)return;if(!a)return;const{orientation:r,items:o,activeId:n}=a.getState(),l="horizontal"!==r,s="vertical"!==r,i=!!(null==(t=o.find((e=>!e.disabled&&null!=e.value)))?void 0:t.rowId),c={ArrowUp:(i||l)&&f(a,a.up),ArrowRight:(i||s)&&f(a,a.next),ArrowDown:(i||l)&&f(a,a.down),ArrowLeft:(i||s)&&f(a,a.previous)}[e.key];c&&A(e)&&(e.preventDefault(),a.move(c()));const u="top"===S||"bottom"===S;({ArrowDown:u,ArrowUp:u,ArrowLeft:"left"===S,ArrowRight:"right"===S})[e.key]&&j(e)&&(e.preventDefault(),a.move(n),v.queueBeforeEvent.call(void 0,e.currentTarget,"keyup",a.show))}));k=i.useWrapElement.call(void 0,k,(e=>h.jsx.call(void 0,l.SelectScopedContextProvider,{value:a,children:e})),[a]);const[V,z]=m.useState.call(void 0,!1),H=m.useRef.call(void 0,!1);m.useEffect.call(void 0,(()=>{const e=H.current;H.current=!1,e||z(!1)}),[P]);const L=a.useState((e=>{var t;return null==(t=e.labelElement)?void 0:t.id})),O=k["aria-label"],N=k["aria-labelledby"]||L,I=a.useState((e=>{if(s)return e.items})),B=m.useMemo.call(void 0,(()=>[...new Set(null==I?void 0:I.map((e=>e.value)).filter((e=>null!=e)))]),[I]);k=i.useWrapElement.call(void 0,k,(e=>s?h.jsxs.call(void 0,h.Fragment,{children:[h.jsxs.call(void 0,"select",{style:{border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"},tabIndex:-1,"aria-hidden":!0,"aria-label":O,"aria-labelledby":N,name:s,form:g,required:w,value:P,multiple:R,onFocus:()=>{var e;return null==(e=null==a?void 0:a.getState().selectElement)?void 0:e.focus()},onChange:e=>{var t;H.current=!0,z(!0),null==a||a.setValue(R?(t=e.target,Array.from(t.selectedOptions).map((e=>e.value))):e.target.value)},children:[u.toArray.call(void 0,P).map((e=>null==e||B.includes(e)?null:h.jsx.call(void 0,"option",{value:e,children:e},e))),B.map((e=>h.jsx.call(void 0,"option",{value:e,children:e},e)))]}),e]}):e),[a,O,N,s,g,w,P,R,B]);const T=h.jsxs.call(void 0,h.Fragment,{children:[P,h.jsx.call(void 0,o.SelectArrow,{})]}),F=a.useState("contentElement");return k=c.__spreadProps.call(void 0,c.__spreadValues.call(void 0,{role:"combobox","aria-autocomplete":"none","aria-labelledby":L,"aria-haspopup":d.getPopupRole.call(void 0,F,"listbox"),"data-autofill":V||void 0,"data-name":s,children:T},k),{ref:i.useMergeRefs.call(void 0,a.setSelectElement,k.ref),onKeyDown:M}),k=r.usePopoverDisclosure.call(void 0,c.__spreadValues.call(void 0,{store:a,toggleOnClick:_},k)),k=n.useCompositeTypeahead.call(void 0,c.__spreadValues.call(void 0,{store:a},k))})),w=s.forwardRef.call(void 0,(function(e){const t=g(e);return s.createElement.call(void 0,"button",t)}));t.Select=w,t.useSelect=g},47440:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(52954);a(19652),a(80987),a(7219),a(28148),t.Separator=r.Separator,t.useSeparator=r.useSeparator},45914:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(15892);a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.TabContextProvider=r.TabContextProvider,t.TabScopedContextProvider=r.TabScopedContextProvider,t.useTabContext=r.useTabContext,t.useTabProviderContext=r.useTabProviderContext,t.useTabScopedContext=r.useTabScopedContext},2485:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(15892),o=a(9229);a(40227),a(42076),a(57870),a(87121),a(73579);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(10790),u=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=s.__objRest.call(void 0,t,["store"]);const u=r.useTabProviderContext.call(void 0);a=a||u,i.invariant.call(void 0,a,!1);const d=a.useState((e=>"both"===e.orientation?void 0:e.orientation));return n=l.useWrapElement.call(void 0,n,(e=>c.jsx.call(void 0,r.TabScopedContextProvider,{value:a,children:e})),[a]),a.composite&&(n=s.__spreadValues.call(void 0,{focusable:!1},n)),n=s.__spreadValues.call(void 0,{role:"tablist","aria-orientation":d},n),n=o.useComposite.call(void 0,s.__spreadValues.call(void 0,{store:a},n))})),d=n.forwardRef.call(void 0,(function(e){const t=u(e);return n.createElement.call(void 0,"div",t)}));t.TabList=d,t.useTabList=u},61477:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(15892),o=a(21236);a(42076),a(57870);var n=a(77723);a(53944),a(16299);var l=a(87121);a(73579);var s=a(19652),i=a(38980),c=a(87636),u=a(80987);a(7219);var d=a(28148),v=a(60877),p=a(48959),m=a(51609),h=a(10790),f=s.createHook.call(void 0,(function(e){var t=e,{store:a,unmountOnHide:s,tabId:f,getItem:g,scrollRestoration:w,scrollElement:b}=t,y=d.__objRest.call(void 0,t,["store","unmountOnHide","tabId","getItem","scrollRestoration","scrollElement"]);const x=r.useTabProviderContext.call(void 0);a=a||x,p.invariant.call(void 0,a,!1);const _=m.useRef.call(void 0,null),k=u.useId.call(void 0,y.id),E=c.useStoreState.call(void 0,a.panels,(()=>{var e;return f||(null==(e=null==a?void 0:a.panels.item(k))?void 0:e.tabId)})),C=c.useStoreState.call(void 0,a,(e=>!!E&&e.selectedId===E)),j=i.useDisclosureStore.call(void 0,{open:C}),A=c.useStoreState.call(void 0,j,"mounted"),S=m.useRef.call(void 0,new Map),P=u.useEvent.call(void 0,(()=>{const e=_.current;return e?b?"function"==typeof b?b(e):"current"in b?b.current:b:e:null}));m.useEffect.call(void 0,(()=>{var e,t;if(!w)return;if(!A)return;const a=P();if(!a)return;if("reset"===w)return void a.scroll(0,0);if(!E)return;const r=S.current.get(E);a.scroll(null!=(e=null==r?void 0:r.x)?e:0,null!=(t=null==r?void 0:r.y)?t:0);const o=()=>{S.current.set(E,{x:a.scrollLeft,y:a.scrollTop})};return a.addEventListener("scroll",o),()=>{a.removeEventListener("scroll",o)}}),[w,A,E,P,a]);const[R,M]=m.useState.call(void 0,!1);m.useEffect.call(void 0,(()=>{const e=_.current;if(!e)return;const t=v.getAllTabbableIn.call(void 0,e);M(!!t.length)}),[]);const V=m.useCallback.call(void 0,(e=>{const t=d.__spreadProps.call(void 0,d.__spreadValues.call(void 0,{},e),{id:k||e.id,tabId:f});return g?g(t):t}),[k,f,g]),z=y.onKeyDown,H=u.useEvent.call(void 0,(e=>{if(null==z||z(e),e.defaultPrevented)return;if(!(null==a?void 0:a.composite))return;const t={ArrowLeft:a.previous,ArrowRight:a.next,Home:a.first,End:a.last}[e.key];if(!t)return;const{selectedId:r}=a.getState(),o=t({activeId:r});o&&(e.preventDefault(),a.move(o))}));return y=u.useWrapElement.call(void 0,y,(e=>h.jsx.call(void 0,r.TabScopedContextProvider,{value:a,children:e})),[a]),y=d.__spreadProps.call(void 0,d.__spreadValues.call(void 0,{id:k,role:"tabpanel","aria-labelledby":E||void 0},y),{children:s&&!A?null:y.children,ref:u.useMergeRefs.call(void 0,_,y.ref),onKeyDown:H}),y=l.useFocusable.call(void 0,d.__spreadValues.call(void 0,{focusable:!a.composite&&!R},y)),y=n.useDisclosureContent.call(void 0,d.__spreadValues.call(void 0,{store:j},y)),y=o.useCollectionItem.call(void 0,d.__spreadProps.call(void 0,d.__spreadValues.call(void 0,{store:a.panels},y),{getItem:V}))})),g=s.forwardRef.call(void 0,(function(e){const t=f(e);return s.createElement.call(void 0,"div",t)}));t.TabPanel=g,t.useTabPanel=f},65362:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32564);a(96475),a(72707);var o=a(15892);a(99366),a(9355),a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.TabProvider=function(e={}){const t=r.useTabStore.call(void 0,e);return n.jsx.call(void 0,o.TabContextProvider,{value:t,children:e.children})}},93648:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32564);a(96475),a(72707),a(99366),a(9355),a(42076),a(57870),a(77018),a(53944),a(16299),a(19652),a(87636),a(80987),a(7219),a(28148),t.useTabStore=r.useTabStore,t.useTabStoreProps=r.useTabStoreProps},85248:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(15892),o=a(35973);a(21236),a(29842),a(40227),a(42076),a(57870),a(87121),a(73579);var n=a(19652),l=a(87636),s=a(80987);a(7219);var i=a(28148),c=a(48959),u=a(51609),d=a(10790),v=n.createHook.call(void 0,(function(e){var t,a=e,{store:n,getItem:v}=a,p=i.__objRest.call(void 0,a,["store","getItem"]);const m=r.useTabScopedContext.call(void 0);n=n||m,c.invariant.call(void 0,n,!1);const h=s.useId.call(void 0),f=p.id||h,g=c.disabledFromProps.call(void 0,p),w=u.useCallback.call(void 0,(e=>{const t=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{dimmed:g});return v?v(t):t}),[g,v]),b=p.onClick,y=s.useEvent.call(void 0,(e=>{null==b||b(e),e.defaultPrevented||null==n||n.setSelectedId(f)})),x=n.panels.useState((e=>{var t;return null==(t=e.items.find((e=>e.tabId===f)))?void 0:t.id})),_=!!h&&p.shouldRegisterItem,k=n.useState((e=>!!f&&e.activeId===f)),E=n.useState((e=>!!f&&e.selectedId===f)),C=n.useState((e=>!!n.item(e.activeId))),j=k||E&&!C,A=E||null==(t=p.accessibleWhenDisabled)||t;if(l.useStoreState.call(void 0,n.combobox||n.composite,"virtualFocus")&&(p=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},p),{tabIndex:-1})),p=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{id:f,role:"tab","aria-selected":E,"aria-controls":x||void 0},p),{onClick:y}),n.composite){const e={id:f,accessibleWhenDisabled:A,store:n.composite,shouldRegisterItem:j&&_,rowId:p.rowId,render:p.render};p=i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},p),{render:d.jsx.call(void 0,o.CompositeItem,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{render:n.combobox&&n.composite!==n.combobox?d.jsx.call(void 0,o.CompositeItem,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},e),{store:n.combobox})):e.render}))})}return p=o.useCompositeItem.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{store:n},p),{accessibleWhenDisabled:A,getItem:w,shouldRegisterItem:_}))})),p=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=v(e);return n.createElement.call(void 0,"button",t)})));t.Tab=p,t.useTab=v},27270:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(32087),o=a(25275);a(35973),a(21236),a(29842),a(40227);var n=a(66485);a(42076),a(57870),a(87121),a(73579);var l=a(19652);a(87636),a(80987),a(7219);var s=a(28148),i=l.createHook.call(void 0,(function(e){var t=e,{store:a}=t,l=s.__objRest.call(void 0,t,["store"]);const i=n.useToolbarContext.call(void 0);return a=a||i,l=r.useCompositeContainer.call(void 0,s.__spreadValues.call(void 0,{store:a},l)),l=o.useToolbarItem.call(void 0,s.__spreadValues.call(void 0,{store:a},l))})),c=l.memo.call(void 0,l.forwardRef.call(void 0,(function(e){const t=i(e);return l.createElement.call(void 0,"div",t)})));t.ToolbarContainer=c,t.useToolbarContainer=i},15634:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(66485);a(42076),a(57870),a(19652),a(80987),a(7219),a(28148),t.ToolbarContextProvider=r.ToolbarContextProvider,t.ToolbarScopedContextProvider=r.ToolbarScopedContextProvider,t.useToolbarContext=r.useToolbarContext,t.useToolbarProviderContext=r.useToolbarProviderContext,t.useToolbarScopedContext=r.useToolbarScopedContext},64759:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(25275);a(35973),a(21236),a(29842),a(40227);var o=a(66485);a(42076),a(57870),a(87121),a(73579);var n=a(19652);a(87636),a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useToolbarContext.call(void 0);return a=a||s,n=r.useToolbarItem.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.memo.call(void 0,n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"input",t)})));t.ToolbarInput=i,t.useToolbarInput=s},72168:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(25275);a(35973),a(21236),a(29842),a(40227),a(66485),a(42076),a(57870),a(87121),a(73579),a(19652),a(87636),a(80987),a(7219),a(28148),t.ToolbarItem=r.ToolbarItem,t.useToolbarItem=r.useToolbarItem},47114:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44110);a(99366),a(9355);var o=a(66485);a(42076),a(57870),a(19652),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.ToolbarProvider=function(e={}){const t=r.useToolbarStore.call(void 0,e);return n.jsx.call(void 0,o.ToolbarContextProvider,{value:t,children:e.children})}},92134:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(86005);a(52954);var o=a(66485);a(42076),a(57870);var n=a(19652);a(80987),a(7219);var l=a(28148),s=n.createHook.call(void 0,(function(e){var t=e,{store:a}=t,n=l.__objRest.call(void 0,t,["store"]);const s=o.useToolbarContext.call(void 0);return a=a||s,n=r.useCompositeSeparator.call(void 0,l.__spreadValues.call(void 0,{store:a},n))})),i=n.forwardRef.call(void 0,(function(e){const t=s(e);return n.createElement.call(void 0,"hr",t)}));t.ToolbarSeparator=i,t.useToolbarSeparator=s},65832:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44110);a(99366),a(9355),a(87636),a(80987),a(7219),a(28148),t.useToolbarStore=r.useToolbarStore,t.useToolbarStoreProps=r.useToolbarStoreProps},17016:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(9229);a(40227);var o=a(44110);a(99366),a(9355);var n=a(66485);a(42076),a(57870),a(87121),a(73579);var l=a(19652);a(87636);var s=a(80987);a(7219);var i=a(28148),c=a(10790),u=l.createHook.call(void 0,(function(e){var t=e,{store:a,orientation:l,virtualFocus:u,focusLoop:d,rtl:v}=t,p=i.__objRest.call(void 0,t,["store","orientation","virtualFocus","focusLoop","rtl"]);const m=n.useToolbarProviderContext.call(void 0);a=a||m;const h=o.useToolbarStore.call(void 0,{store:a,orientation:l,virtualFocus:u,focusLoop:d,rtl:v}),f=h.useState((e=>"both"===e.orientation?void 0:e.orientation));return p=s.useWrapElement.call(void 0,p,(e=>c.jsx.call(void 0,n.ToolbarScopedContextProvider,{value:h,children:e})),[h]),p=i.__spreadValues.call(void 0,{role:"toolbar","aria-orientation":f},p),p=r.useComposite.call(void 0,i.__spreadValues.call(void 0,{store:h},p))})),d=l.forwardRef.call(void 0,(function(e){const t=u(e);return l.createElement.call(void 0,"div",t)}));t.Toolbar=d,t.useToolbar=u},73234:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21407),o=a(74581);a(80231),a(77018),a(53944),a(16299),a(87121),a(73579);var n=a(19652),l=a(80987);a(7219);var s=a(28148),i=a(48959),c=a(8766),u=a(51609),d=c.createStore.call(void 0,{activeStore:null});function v(e){return()=>{const{activeStore:t}=d.getState();t===e&&d.setState("activeStore",null)}}var p=n.createHook.call(void 0,(function(e){var t=e,{store:a,showOnHover:n=!0}=t,p=s.__objRest.call(void 0,t,["store","showOnHover"]);const m=o.useTooltipProviderContext.call(void 0);a=a||m,i.invariant.call(void 0,a,!1);const h=u.useRef.call(void 0,!1);u.useEffect.call(void 0,(()=>c.sync.call(void 0,a,["mounted"],(e=>{e.mounted||(h.current=!1)}))),[a]),u.useEffect.call(void 0,(()=>{if(a)return i.chain.call(void 0,v(a),c.sync.call(void 0,a,["mounted","skipTimeout"],(e=>{if(!a)return;if(e.mounted){const{activeStore:e}=d.getState();return e!==a&&(null==e||e.hide()),d.setState("activeStore",a)}const t=setTimeout(v(a),e.skipTimeout);return()=>clearTimeout(t)})))}),[a]);const f=p.onMouseEnter,g=l.useEvent.call(void 0,(e=>{null==f||f(e),h.current=!0})),w=p.onFocusVisible,b=l.useEvent.call(void 0,(e=>{null==w||w(e),e.defaultPrevented||(null==a||a.setAnchorElement(e.currentTarget),null==a||a.show())})),y=p.onBlur,x=l.useEvent.call(void 0,(e=>{if(null==y||y(e),e.defaultPrevented)return;const{activeStore:t}=d.getState();h.current=!1,t===a&&d.setState("activeStore",null)})),_=a.useState("type"),k=a.useState((e=>{var t;return null==(t=e.contentElement)?void 0:t.id}));return p=s.__spreadProps.call(void 0,s.__spreadValues.call(void 0,{"aria-labelledby":"label"===_?k:void 0},p),{onMouseEnter:g,onFocusVisible:b,onBlur:x}),p=r.useHovercardAnchor.call(void 0,s.__spreadValues.call(void 0,{store:a,showOnHover(e){if(!h.current)return!1;if(i.isFalsyBooleanCallback.call(void 0,n,e))return!1;const{activeStore:t}=d.getState();return!t||(null==a||a.show(),!1)}},p))})),m=n.forwardRef.call(void 0,(function(e){const t=p(e);return n.createElement.call(void 0,"div",t)}));t.TooltipAnchor=m,t.useTooltipAnchor=p},99980:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(79066);a(45081);var o=a(74581);a(80231),a(77018),a(53944),a(16299);var n=a(19652);a(80987),a(7219);var l=a(28148),s=a(48959),i=n.createHook.call(void 0,(function(e){var t=e,{store:a,size:n=16}=t,i=l.__objRest.call(void 0,t,["store","size"]);const c=o.useTooltipContext.call(void 0);return a=a||c,s.invariant.call(void 0,a,!1),i=r.usePopoverArrow.call(void 0,l.__spreadValues.call(void 0,{store:a,size:n},i))})),c=n.forwardRef.call(void 0,(function(e){const t=i(e);return n.createElement.call(void 0,"div",t)}));t.TooltipArrow=c,t.useTooltipArrow=i},19122:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74581);a(80231),a(77018),a(53944),a(16299),a(19652),a(80987),a(7219),a(28148),t.TooltipContextProvider=r.TooltipContextProvider,t.TooltipScopedContextProvider=r.TooltipScopedContextProvider,t.useTooltipContext=r.useTooltipContext,t.useTooltipProviderContext=r.useTooltipProviderContext,t.useTooltipScopedContext=r.useTooltipScopedContext},54858:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(74581);a(80231),a(77018),a(53944),a(16299),a(19652);var o=a(80032);a(46423),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148);var n=a(10790);t.TooltipProvider=function(e={}){const t=o.useTooltipStore.call(void 0,e);return n.jsx.call(void 0,r.TooltipContextProvider,{value:t,children:e.children})}},11208:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80032);a(46423),a(44448),a(95691),a(38980),a(87636),a(80987),a(7219),a(28148),t.useTooltipStore=r.useTooltipStore,t.useTooltipStoreProps=r.useTooltipStoreProps},71128:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(82109);a(68725),a(39861);var o=a(28293);a(12204),a(19387),a(70663),a(33043),a(8549),a(89169),a(68842),a(21676),a(85325),a(26327),a(91605),a(48960),a(94818),a(49464),a(99471),a(82203),a(32146),a(9018),a(54844),a(67722),a(63215),a(77723),a(12707);var n=a(74581);a(80231),a(77018),a(53944),a(16299),a(87121),a(73579),a(3578);var l=a(19652);a(95691),a(38980),a(87636);var s=a(80987);a(7219);var i=a(28148),c=a(92725),u=a(48959),d=a(10790),v=l.createHook.call(void 0,(function(e){var t=e,{store:a,portal:o=!0,gutter:l=8,preserveTabOrder:v=!1,hideOnHoverOutside:p=!0,hideOnInteractOutside:m=!0}=t,h=i.__objRest.call(void 0,t,["store","portal","gutter","preserveTabOrder","hideOnHoverOutside","hideOnInteractOutside"]);const f=n.useTooltipProviderContext.call(void 0);a=a||f,u.invariant.call(void 0,a,!1),h=s.useWrapElement.call(void 0,h,(e=>d.jsx.call(void 0,n.TooltipScopedContextProvider,{value:a,children:e})),[a]);const g=a.useState((e=>"description"===e.type?"tooltip":"none"));return h=i.__spreadValues.call(void 0,{role:g},h),h=r.useHovercard.call(void 0,i.__spreadProps.call(void 0,i.__spreadValues.call(void 0,{},h),{store:a,portal:o,gutter:l,preserveTabOrder:v,hideOnHoverOutside(e){if(u.isFalsyBooleanCallback.call(void 0,p,e))return!1;const t=null==a?void 0:a.getState().anchorElement;return!t||!("focusVisible"in t.dataset)},hideOnInteractOutside:e=>{if(u.isFalsyBooleanCallback.call(void 0,m,e))return!1;const t=null==a?void 0:a.getState().anchorElement;return!t||!c.contains.call(void 0,t,e.target)}}))})),p=o.createDialogComponent.call(void 0,l.forwardRef.call(void 0,(function(e){const t=v(e);return l.createElement.call(void 0,"div",t)})),n.useTooltipProviderContext);t.Tooltip=p,t.useTooltip=v},45372:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87636);a(80987),a(7219),a(28148),t.useStore=r.useStore,t.useStoreProps=r.useStoreProps,t.useStoreState=r.useStoreState,t.useStoreStateObject=r.useStoreStateObject},46636:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(3578);a(19652),a(80987),a(7219),a(28148),t.VisuallyHidden=r.VisuallyHidden,t.useVisuallyHidden=r.useVisuallyHidden},65786:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(47440);t.Separator=r.Separator},70170:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(40416),o=a(61930),n=a(58416),l=a(25570),s=a(77850),i=a(84612),c=a(47729),u=a(36526),d=a(36634),v=a(26111),p=a(39257);t.usePopoverStore=r.usePopoverStore,t.usePopoverContext=o.usePopoverContext,t.Popover=n.Popover,t.PopoverProvider=l.PopoverProvider,t.PopoverAnchor=s.PopoverAnchor,t.PopoverArrow=i.PopoverArrow,t.PopoverDescription=c.PopoverDescription,t.PopoverDisclosureArrow=u.PopoverDisclosureArrow,t.PopoverDisclosure=d.PopoverDisclosure,t.PopoverDismiss=v.PopoverDismiss,t.PopoverHeading=p.PopoverHeading},10938:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(46636);t.VisuallyHidden=r.VisuallyHidden},2761:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2720),o=a(94029);t.Heading=r.Heading,t.HeadingLevel=o.HeadingLevel},15180:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(19188);t.Command=r.Command},66593:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(66128),o=a(30549);t.Group=r.Group,t.GroupLabel=o.GroupLabel},96493:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(87888),o=a(31258),n=a(55488),l=a(41810),s=a(827),i=a(50682),c=a(40973),u=a(58736),d=a(65631),v=a(84334),p=a(99684);t.useCompositeStore=r.useCompositeStore,t.useCompositeContext=o.useCompositeContext,t.Composite=n.Composite,t.CompositeProvider=l.CompositeProvider,t.CompositeGroupLabel=s.CompositeGroupLabel,t.CompositeGroup=i.CompositeGroup,t.CompositeHover=c.CompositeHover,t.CompositeItem=u.CompositeItem,t.CompositeRow=d.CompositeRow,t.CompositeSeparator=v.CompositeSeparator,t.CompositeTypeahead=p.CompositeTypeahead},69766:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(84592),o=a(66906),n=a(70856),l=a(94112),s=a(92466),i=a(17848),c=a(97162),u=a(79732),d=a(84281),v=a(17517),p=a(91425),m=a(54415),h=a(15995),f=a(45242),g=a(87593),w=a(42259),b=a(2610),y=a(70334),x=a(28592),_=a(78933),k=a(75854);t.useMenuStore=r.useMenuStore,t.useMenuContext=o.useMenuContext,t.useMenuBarContext=o.useMenuBarContext,t.useMenuBarStore=n.useMenuBarStore,t.Menu=l.Menu,t.MenuProvider=s.MenuProvider,t.MenuBar=i.MenuBar,t.MenuBarProvider=c.MenuBarProvider,t.MenuArrow=u.MenuArrow,t.MenuButtonArrow=d.MenuButtonArrow,t.MenuButton=v.MenuButton,t.MenuDescription=p.MenuDescription,t.MenuDismiss=m.MenuDismiss,t.MenuGroupLabel=h.MenuGroupLabel,t.MenuGroup=f.MenuGroup,t.MenuHeading=g.MenuHeading,t.MenuItemCheck=w.MenuItemCheck,t.MenuItemCheckbox=b.MenuItemCheckbox,t.MenuItemRadio=y.MenuItemRadio,t.MenuItem=x.MenuItem,t.MenuList=_.MenuList,t.MenuSeparator=k.MenuSeparator},25956:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(67548),o=a(58502);t.PortalContext=r.PortalContext,t.Portal=o.Portal},96098:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(21046),o=a(60876),n=a(66732),l=a(76590);t.useMenubarContext=r.useMenubarContext,t.useMenubarStore=o.useMenubarStore,t.Menubar=n.Menubar,t.MenubarProvider=l.MenubarProvider},48123:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(27498),o=a(42668),n=a(5238),l=a(60940),s=a(99378);t.useCollectionStore=r.useCollectionStore,t.useCollectionContext=o.useCollectionContext,t.Collection=n.Collection,t.CollectionProvider=l.CollectionProvider,t.CollectionItem=s.CollectionItem},56356:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(51776),o=a(41354),n=a(32880),l=a(95522),s=a(54522),i=a(40804),c=a(54929),u=a(34650),d=a(81439),v=a(3129);t.useHovercardStore=r.useHovercardStore,t.useHovercardContext=o.useHovercardContext,t.Hovercard=n.Hovercard,t.HovercardProvider=l.HovercardProvider,t.HovercardAnchor=s.HovercardAnchor,t.HovercardArrow=i.HovercardArrow,t.HovercardDescription=c.HovercardDescription,t.HovercardDisclosure=u.HovercardDisclosure,t.HovercardDismiss=d.HovercardDismiss,t.HovercardHeading=v.HovercardHeading},13561:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(63512),o=a(51298),n=a(57672),l=a(14490),s=a(3970);t.useRadioStore=r.useRadioStore,t.useRadioContext=o.useRadioContext,t.Radio=n.Radio,t.RadioProvider=l.RadioProvider,t.RadioGroup=s.RadioGroup},852:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(11208),o=a(19122),n=a(71128),l=a(54858),s=a(73234),i=a(99980);t.useTooltipStore=r.useTooltipStore,t.useTooltipContext=o.useTooltipContext,t.Tooltip=n.Tooltip,t.TooltipProvider=l.TooltipProvider,t.TooltipAnchor=s.TooltipAnchor,t.TooltipArrow=i.TooltipArrow},51043:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(93648),o=a(45914),n=a(85248),l=a(65362),s=a(2485),i=a(61477);t.useTabStore=r.useTabStore,t.useTabContext=o.useTabContext,t.Tab=n.Tab,t.TabProvider=l.TabProvider,t.TabList=s.TabList,t.TabPanel=i.TabPanel},82262:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(45372);t.useStoreState=r.useStoreState},54830:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(55166),o=a(49296),n=a(18266),l=a(23184),s=a(96254),i=a(18460),c=a(74695),u=a(40055),d=a(26169),v=a(3301),p=a(16448),m=a(57509),h=a(30587),f=a(12563),g=a(61802),w=a(78864),b=a(46595),y=a(46820),x=a(71451);t.useFormStore=r.useFormStore,t.useFormContext=o.useFormContext,t.Form=n.Form,t.FormProvider=l.FormProvider,t.FormControl=s.FormControl,t.FormCheckbox=i.FormCheckbox,t.FormDescription=c.FormDescription,t.FormError=u.FormError,t.FormField=d.FormField,t.FormGroupLabel=v.FormGroupLabel,t.FormGroup=p.FormGroup,t.FormInput=m.FormInput,t.FormLabel=h.FormLabel,t.FormPush=f.FormPush,t.FormRadioGroup=g.FormRadioGroup,t.FormRadio=w.FormRadio,t.FormRemove=b.FormRemove,t.FormReset=y.FormReset,t.FormSubmit=x.FormSubmit},94964:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(93320),o=a(34130),n=a(50296),l=a(41706),s=a(48056);t.useDisclosureStore=r.useDisclosureStore,t.useDisclosureContext=o.useDisclosureContext,t.Disclosure=n.Disclosure,t.DisclosureProvider=l.DisclosureProvider,t.DisclosureContent=s.DisclosureContent},25666:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(2462);t.Role=r.Role},95952:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(35048),o=a(71986),n=a(85848),l=a(72714),s=a(44587);t.useCheckboxStore=r.useCheckboxStore,t.useCheckboxContext=o.useCheckboxContext,t.Checkbox=n.Checkbox,t.CheckboxProvider=l.CheckboxProvider,t.CheckboxCheck=s.CheckboxCheck},99551:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(83056);t.Focusable=r.Focusable},7585:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80466),o=a(59988),n=a(27742),l=a(22292),s=a(13387),i=a(78368),c=a(54513),u=a(25111);t.useDialogStore=r.useDialogStore,t.useDialogContext=o.useDialogContext,t.Dialog=n.Dialog,t.DialogProvider=l.DialogProvider,t.DialogDescription=s.DialogDescription,t.DialogDisclosure=i.DialogDisclosure,t.DialogDismiss=c.DialogDismiss,t.DialogHeading=u.DialogHeading},75601:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(30494),o=a(40432),n=a(75418),l=a(16016),s=a(92622),i=a(45045),c=a(42149),u=a(18080),d=a(26219),v=a(12933),p=a(28670),m=a(93019),h=a(68175),f=a(21506),g=a(57197),w=a(67056),b=a(28226);t.useSelectStore=r.useSelectStore,t.useSelectContext=o.useSelectContext,t.Select=n.Select,t.SelectProvider=l.SelectProvider,t.SelectArrow=s.SelectArrow,t.SelectDismiss=i.SelectDismiss,t.SelectGroupLabel=c.SelectGroupLabel,t.SelectGroup=u.SelectGroup,t.SelectHeading=d.SelectHeading,t.SelectItemCheck=v.SelectItemCheck,t.SelectItem=p.SelectItem,t.SelectLabel=m.SelectLabel,t.SelectList=h.SelectList,t.SelectPopover=f.SelectPopover,t.SelectRow=g.SelectRow,t.SelectSeparator=w.SelectSeparator,t.SelectValue=b.SelectValue},80160:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(52652),o=a(18038),n=a(98348),l=a(69198),s=a(67295),i=a(30030),c=a(98935),u=a(79334),d=a(6439),v=a(82616),p=a(23140),m=a(68529),h=a(72305),f=a(87020),g=a(98739),w=a(15498),b=a(74592);t.useComboboxStore=r.useComboboxStore,t.useComboboxContext=o.useComboboxContext,t.Combobox=n.Combobox,t.ComboboxProvider=l.ComboboxProvider,t.ComboboxCancel=s.ComboboxCancel,t.ComboboxDisclosure=i.ComboboxDisclosure,t.ComboboxGroupLabel=c.ComboboxGroupLabel,t.ComboboxGroup=u.ComboboxGroup,t.ComboboxItemCheck=d.ComboboxItemCheck,t.ComboboxItemValue=v.ComboboxItemValue,t.ComboboxItem=p.ComboboxItem,t.ComboboxLabel=m.ComboboxLabel,t.ComboboxList=h.ComboboxList,t.ComboboxPopover=f.ComboboxPopover,t.ComboboxRow=g.ComboboxRow,t.ComboboxSeparator=w.ComboboxSeparator,t.ComboboxValue=b.ComboboxValue},49311:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(44571),o=a(46410);t.FocusTrapRegion=r.FocusTrapRegion,t.FocusTrap=o.FocusTrap},17351:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(65832),o=a(15634),n=a(17016),l=a(47114),s=a(27270),i=a(64759),c=a(72168),u=a(92134);t.useToolbarStore=r.useToolbarStore,t.useToolbarContext=o.useToolbarContext,t.Toolbar=n.Toolbar,t.ToolbarProvider=l.ToolbarProvider,t.ToolbarContainer=s.ToolbarContainer,t.ToolbarInput=i.ToolbarInput,t.ToolbarItem=c.ToolbarItem,t.ToolbarSeparator=u.ToolbarSeparator},51355:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(58430);t.Button=r.Button},94083:(e,t,a)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a(80160),o=a(48123),n=a(95952),l=a(51355),s=a(66593),i=a(54830),c=a(99551),u=a(49311),d=a(94964),v=a(7585),p=a(96493),m=a(15180),h=a(13561),f=a(25956),g=a(70170),w=a(96098),b=a(69766),y=a(56356),x=a(2761),_=a(10938),k=a(852),E=a(17351),C=a(51043),j=a(82262),A=a(65786),S=a(75601),P=a(25666);t.Button=l.Button,t.Checkbox=n.Checkbox,t.CheckboxCheck=n.CheckboxCheck,t.CheckboxProvider=n.CheckboxProvider,t.Collection=o.Collection,t.CollectionItem=o.CollectionItem,t.CollectionProvider=o.CollectionProvider,t.Combobox=r.Combobox,t.ComboboxCancel=r.ComboboxCancel,t.ComboboxDisclosure=r.ComboboxDisclosure,t.ComboboxGroup=r.ComboboxGroup,t.ComboboxGroupLabel=r.ComboboxGroupLabel,t.ComboboxItem=r.ComboboxItem,t.ComboboxItemCheck=r.ComboboxItemCheck,t.ComboboxItemValue=r.ComboboxItemValue,t.ComboboxLabel=r.ComboboxLabel,t.ComboboxList=r.ComboboxList,t.ComboboxPopover=r.ComboboxPopover,t.ComboboxProvider=r.ComboboxProvider,t.ComboboxRow=r.ComboboxRow,t.ComboboxSeparator=r.ComboboxSeparator,t.ComboboxValue=r.ComboboxValue,t.Command=m.Command,t.Composite=p.Composite,t.CompositeGroup=p.CompositeGroup,t.CompositeGroupLabel=p.CompositeGroupLabel,t.CompositeHover=p.CompositeHover,t.CompositeItem=p.CompositeItem,t.CompositeProvider=p.CompositeProvider,t.CompositeRow=p.CompositeRow,t.CompositeSeparator=p.CompositeSeparator,t.CompositeTypeahead=p.CompositeTypeahead,t.Dialog=v.Dialog,t.DialogDescription=v.DialogDescription,t.DialogDisclosure=v.DialogDisclosure,t.DialogDismiss=v.DialogDismiss,t.DialogHeading=v.DialogHeading,t.DialogProvider=v.DialogProvider,t.Disclosure=d.Disclosure,t.DisclosureContent=d.DisclosureContent,t.DisclosureProvider=d.DisclosureProvider,t.FocusTrap=u.FocusTrap,t.FocusTrapRegion=u.FocusTrapRegion,t.Focusable=c.Focusable,t.Form=i.Form,t.FormCheckbox=i.FormCheckbox,t.FormControl=i.FormControl,t.FormDescription=i.FormDescription,t.FormError=i.FormError,t.FormField=i.FormField,t.FormGroup=i.FormGroup,t.FormGroupLabel=i.FormGroupLabel,t.FormInput=i.FormInput,t.FormLabel=i.FormLabel,t.FormProvider=i.FormProvider,t.FormPush=i.FormPush,t.FormRadio=i.FormRadio,t.FormRadioGroup=i.FormRadioGroup,t.FormRemove=i.FormRemove,t.FormReset=i.FormReset,t.FormSubmit=i.FormSubmit,t.Group=s.Group,t.GroupLabel=s.GroupLabel,t.Heading=x.Heading,t.HeadingLevel=x.HeadingLevel,t.Hovercard=y.Hovercard,t.HovercardAnchor=y.HovercardAnchor,t.HovercardArrow=y.HovercardArrow,t.HovercardDescription=y.HovercardDescription,t.HovercardDisclosure=y.HovercardDisclosure,t.HovercardDismiss=y.HovercardDismiss,t.HovercardHeading=y.HovercardHeading,t.HovercardProvider=y.HovercardProvider,t.Menu=b.Menu,t.MenuArrow=b.MenuArrow,t.MenuBar=b.MenuBar,t.MenuBarProvider=b.MenuBarProvider,t.MenuButton=b.MenuButton,t.MenuButtonArrow=b.MenuButtonArrow,t.MenuDescription=b.MenuDescription,t.MenuDismiss=b.MenuDismiss,t.MenuGroup=b.MenuGroup,t.MenuGroupLabel=b.MenuGroupLabel,t.MenuHeading=b.MenuHeading,t.MenuItem=b.MenuItem,t.MenuItemCheck=b.MenuItemCheck,t.MenuItemCheckbox=b.MenuItemCheckbox,t.MenuItemRadio=b.MenuItemRadio,t.MenuList=b.MenuList,t.MenuProvider=b.MenuProvider,t.MenuSeparator=b.MenuSeparator,t.Menubar=w.Menubar,t.MenubarProvider=w.MenubarProvider,t.Popover=g.Popover,t.PopoverAnchor=g.PopoverAnchor,t.PopoverArrow=g.PopoverArrow,t.PopoverDescription=g.PopoverDescription,t.PopoverDisclosure=g.PopoverDisclosure,t.PopoverDisclosureArrow=g.PopoverDisclosureArrow,t.PopoverDismiss=g.PopoverDismiss,t.PopoverHeading=g.PopoverHeading,t.PopoverProvider=g.PopoverProvider,t.Portal=f.Portal,t.PortalContext=f.PortalContext,t.Radio=h.Radio,t.RadioGroup=h.RadioGroup,t.RadioProvider=h.RadioProvider,t.Role=P.Role,t.Select=S.Select,t.SelectArrow=S.SelectArrow,t.SelectDismiss=S.SelectDismiss,t.SelectGroup=S.SelectGroup,t.SelectGroupLabel=S.SelectGroupLabel,t.SelectHeading=S.SelectHeading,t.SelectItem=S.SelectItem,t.SelectItemCheck=S.SelectItemCheck,t.SelectLabel=S.SelectLabel,t.SelectList=S.SelectList,t.SelectPopover=S.SelectPopover,t.SelectProvider=S.SelectProvider,t.SelectRow=S.SelectRow,t.SelectSeparator=S.SelectSeparator,t.SelectValue=S.SelectValue,t.Separator=A.Separator,t.Tab=C.Tab,t.TabList=C.TabList,t.TabPanel=C.TabPanel,t.TabProvider=C.TabProvider,t.Toolbar=E.Toolbar,t.ToolbarContainer=E.ToolbarContainer,t.ToolbarInput=E.ToolbarInput,t.ToolbarItem=E.ToolbarItem,t.ToolbarProvider=E.ToolbarProvider,t.ToolbarSeparator=E.ToolbarSeparator,t.Tooltip=k.Tooltip,t.TooltipAnchor=k.TooltipAnchor,t.TooltipArrow=k.TooltipArrow,t.TooltipProvider=k.TooltipProvider,t.VisuallyHidden=_.VisuallyHidden,t.useCheckboxContext=n.useCheckboxContext,t.useCheckboxStore=n.useCheckboxStore,t.useCollectionContext=o.useCollectionContext,t.useCollectionStore=o.useCollectionStore,t.useComboboxContext=r.useComboboxContext,t.useComboboxStore=r.useComboboxStore,t.useCompositeContext=p.useCompositeContext,t.useCompositeStore=p.useCompositeStore,t.useDialogContext=v.useDialogContext,t.useDialogStore=v.useDialogStore,t.useDisclosureContext=d.useDisclosureContext,t.useDisclosureStore=d.useDisclosureStore,t.useFormContext=i.useFormContext,t.useFormStore=i.useFormStore,t.useHovercardContext=y.useHovercardContext,t.useHovercardStore=y.useHovercardStore,t.useMenuBarContext=b.useMenuBarContext,t.useMenuBarStore=b.useMenuBarStore,t.useMenuContext=b.useMenuContext,t.useMenuStore=b.useMenuStore,t.useMenubarContext=w.useMenubarContext,t.useMenubarStore=w.useMenubarStore,t.usePopoverContext=g.usePopoverContext,t.usePopoverStore=g.usePopoverStore,t.useRadioContext=h.useRadioContext,t.useRadioStore=h.useRadioStore,t.useSelectContext=S.useSelectContext,t.useSelectStore=S.useSelectStore,t.useStoreState=j.useStoreState,t.useTabContext=C.useTabContext,t.useTabStore=C.useTabStore,t.useToolbarContext=E.useToolbarContext,t.useToolbarStore=E.useToolbarStore,t.useTooltipContext=k.useTooltipContext,t.useTooltipStore=k.useTooltipStore},96072:e=>{function t(){return e.exports=t=Object.assign?Object.assign.bind():function(e){for(var t=1;t{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},159:(e,t,a)=>{"use strict";a.d(t,{BN:()=>f,ER:()=>g,Ej:()=>w,HN:()=>l,RK:()=>i,UE:()=>s,UU:()=>c,cY:()=>h,jD:()=>v,mG:()=>m,rD:()=>n});var r=a(39175);function o(e,t,a){let{reference:o,floating:n}=e;const l=(0,r.TV)(t),s=(0,r.Dz)(t),i=(0,r.sq)(s),c=(0,r.C0)(t),u="y"===l,d=o.x+o.width/2-n.width/2,v=o.y+o.height/2-n.height/2,p=o[i]/2-n[i]/2;let m;switch(c){case"top":m={x:d,y:o.y-n.height};break;case"bottom":m={x:d,y:o.y+o.height};break;case"right":m={x:o.x+o.width,y:v};break;case"left":m={x:o.x-n.width,y:v};break;default:m={x:o.x,y:o.y}}switch((0,r.Sg)(t)){case"start":m[s]-=p*(a&&u?-1:1);break;case"end":m[s]+=p*(a&&u?-1:1)}return m}const n=async(e,t,a)=>{const{placement:r="bottom",strategy:n="absolute",middleware:l=[],platform:s}=a,i=l.filter(Boolean),c=await(null==s.isRTL?void 0:s.isRTL(t));let u=await s.getElementRects({reference:e,floating:t,strategy:n}),{x:d,y:v}=o(u,r,c),p=r,m={},h=0;for(let a=0;a({name:"arrow",options:e,async fn(t){const{x:a,y:o,placement:n,rects:l,platform:s,elements:i,middlewareData:c}=t,{element:u,padding:d=0}=(0,r._3)(e,t)||{};if(null==u)return{};const v=(0,r.nI)(d),p={x:a,y:o},m=(0,r.Dz)(n),h=(0,r.sq)(m),f=await s.getDimensions(u),g="y"===m,w=g?"top":"left",b=g?"bottom":"right",y=g?"clientHeight":"clientWidth",x=l.reference[h]+l.reference[m]-p[m]-l.floating[h],_=p[m]-l.reference[m],k=await(null==s.getOffsetParent?void 0:s.getOffsetParent(u));let E=k?k[y]:0;E&&await(null==s.isElement?void 0:s.isElement(k))||(E=i.floating[y]||l.floating[h]);const C=x/2-_/2,j=E/2-f[h]/2-1,A=(0,r.jk)(v[w],j),S=(0,r.jk)(v[b],j),P=A,R=E-f[h]-S,M=E/2-f[h]/2+C,V=(0,r.qE)(P,M,R),z=!c.arrow&&null!=(0,r.Sg)(n)&&M!==V&&l.reference[h]/2-(M(0,r.Sg)(t)===e)),...a.filter((t=>(0,r.Sg)(t)!==e))]:a.filter((e=>(0,r.C0)(e)===e))).filter((a=>!e||(0,r.Sg)(a)===e||!!t&&(0,r.aD)(a)!==a))}(p||null,h,m):m,w=await l(t,f),b=(null==(a=i.autoPlacement)?void 0:a.index)||0,y=g[b];if(null==y)return{};const x=(0,r.w7)(y,s,await(null==u.isRTL?void 0:u.isRTL(d.floating)));if(c!==y)return{reset:{placement:g[0]}};const _=[w[(0,r.C0)(y)],w[x[0]],w[x[1]]],k=[...(null==(o=i.autoPlacement)?void 0:o.overflows)||[],{placement:y,overflows:_}],E=g[b+1];if(E)return{data:{index:b+1,overflows:k},reset:{placement:E}};const C=k.map((e=>{const t=(0,r.Sg)(e.placement);return[e.placement,t&&v?e.overflows.slice(0,2).reduce(((e,t)=>e+t),0):e.overflows[0],e.overflows]})).sort(((e,t)=>e[1]-t[1])),j=(null==(n=C.filter((e=>e[2].slice(0,(0,r.Sg)(e[0])?2:3).every((e=>e<=0))))[0])?void 0:n[0])||C[0][0];return j!==c?{data:{index:b+1,overflows:k},reset:{placement:j}}:{}}}},c=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var a,o;const{placement:n,middlewareData:s,rects:i,initialPlacement:c,platform:u,elements:d}=t,{mainAxis:v=!0,crossAxis:p=!0,fallbackPlacements:m,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:g=!0,...w}=(0,r._3)(e,t);if(null!=(a=s.arrow)&&a.alignmentOffset)return{};const b=(0,r.C0)(n),y=(0,r.TV)(c),x=(0,r.C0)(c)===c,_=await(null==u.isRTL?void 0:u.isRTL(d.floating)),k=m||(x||!g?[(0,r.bV)(c)]:(0,r.WJ)(c)),E="none"!==f;!m&&E&&k.push(...(0,r.lP)(c,g,f,_));const C=[c,...k],j=await l(t,w),A=[];let S=(null==(o=s.flip)?void 0:o.overflows)||[];if(v&&A.push(j[b]),p){const e=(0,r.w7)(n,i,_);A.push(j[e[0]],j[e[1]])}if(S=[...S,{placement:n,overflows:A}],!A.every((e=>e<=0))){var P,R;const e=((null==(P=s.flip)?void 0:P.index)||0)+1,t=C[e];if(t)return{data:{index:e,overflows:S},reset:{placement:t}};let a=null==(R=S.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:R.placement;if(!a)switch(h){case"bestFit":{var M;const e=null==(M=S.filter((e=>{if(E){const t=(0,r.TV)(e.placement);return t===y||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:M[0];e&&(a=e);break}case"initialPlacement":a=c}if(n!==a)return{reset:{placement:a}}}return{}}}};function u(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function d(e){return r.r_.some((t=>e[t]>=0))}const v=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:a}=t,{strategy:o="referenceHidden",...n}=(0,r._3)(e,t);switch(o){case"referenceHidden":{const e=u(await l(t,{...n,elementContext:"reference"}),a.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:d(e)}}}case"escaped":{const e=u(await l(t,{...n,altBoundary:!0}),a.floating);return{data:{escapedOffsets:e,escaped:d(e)}}}default:return{}}}}};function p(e){const t=(0,r.jk)(...e.map((e=>e.left))),a=(0,r.jk)(...e.map((e=>e.top)));return{x:t,y:a,width:(0,r.T9)(...e.map((e=>e.right)))-t,height:(0,r.T9)(...e.map((e=>e.bottom)))-a}}const m=function(e){return void 0===e&&(e={}),{name:"inline",options:e,async fn(t){const{placement:a,elements:o,rects:n,platform:l,strategy:s}=t,{padding:i=2,x:c,y:u}=(0,r._3)(e,t),d=Array.from(await(null==l.getClientRects?void 0:l.getClientRects(o.reference))||[]),v=function(e){const t=e.slice().sort(((e,t)=>e.y-t.y)),a=[];let o=null;for(let e=0;eo.height/2?a.push([r]):a[a.length-1].push(r),o=r}return a.map((e=>(0,r.B1)(p(e))))}(d),m=(0,r.B1)(p(d)),h=(0,r.nI)(i);const f=await l.getElementRects({reference:{getBoundingClientRect:function(){if(2===v.length&&v[0].left>v[1].right&&null!=c&&null!=u)return v.find((e=>c>e.left-h.left&&ce.top-h.top&&u=2){if("y"===(0,r.TV)(a)){const e=v[0],t=v[v.length-1],o="top"===(0,r.C0)(a),n=e.top,l=t.bottom,s=o?e.left:t.left,i=o?e.right:t.right;return{top:n,bottom:l,left:s,right:i,width:i-s,height:l-n,x:s,y:n}}const e="left"===(0,r.C0)(a),t=(0,r.T9)(...v.map((e=>e.right))),o=(0,r.jk)(...v.map((e=>e.left))),n=v.filter((a=>e?a.left===o:a.right===t)),l=n[0].top,s=n[n.length-1].bottom;return{top:l,bottom:s,left:o,right:t,width:t-o,height:s-l,x:o,y:l}}return m}},floating:o.floating,strategy:s});return n.reference.x!==f.reference.x||n.reference.y!==f.reference.y||n.reference.width!==f.reference.width||n.reference.height!==f.reference.height?{reset:{rects:f}}:{}}}};const h=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var a,o;const{x:n,y:l,placement:s,middlewareData:i}=t,c=await async function(e,t){const{placement:a,platform:o,elements:n}=e,l=await(null==o.isRTL?void 0:o.isRTL(n.floating)),s=(0,r.C0)(a),i=(0,r.Sg)(a),c="y"===(0,r.TV)(a),u=["left","top"].includes(s)?-1:1,d=l&&c?-1:1,v=(0,r._3)(t,e);let{mainAxis:p,crossAxis:m,alignmentAxis:h}="number"==typeof v?{mainAxis:v,crossAxis:0,alignmentAxis:null}:{mainAxis:v.mainAxis||0,crossAxis:v.crossAxis||0,alignmentAxis:v.alignmentAxis};return i&&"number"==typeof h&&(m="end"===i?-1*h:h),c?{x:m*d,y:p*u}:{x:p*u,y:m*d}}(t,e);return s===(null==(a=i.offset)?void 0:a.placement)&&null!=(o=i.arrow)&&o.alignmentOffset?{}:{x:n+c.x,y:l+c.y,data:{...c,placement:s}}}}},f=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:a,y:o,placement:n}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:c={fn:e=>{let{x:t,y:a}=e;return{x:t,y:a}}},...u}=(0,r._3)(e,t),d={x:a,y:o},v=await l(t,u),p=(0,r.TV)((0,r.C0)(n)),m=(0,r.PG)(p);let h=d[m],f=d[p];if(s){const e="y"===m?"bottom":"right",t=h+v["y"===m?"top":"left"],a=h-v[e];h=(0,r.qE)(t,h,a)}if(i){const e="y"===p?"bottom":"right",t=f+v["y"===p?"top":"left"],a=f-v[e];f=(0,r.qE)(t,f,a)}const g=c.fn({...t,[m]:h,[p]:f});return{...g,data:{x:g.x-a,y:g.y-o,enabled:{[m]:s,[p]:i}}}}}},g=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:a,y:o,placement:n,rects:l,middlewareData:s}=t,{offset:i=0,mainAxis:c=!0,crossAxis:u=!0}=(0,r._3)(e,t),d={x:a,y:o},v=(0,r.TV)(n),p=(0,r.PG)(v);let m=d[p],h=d[v];const f=(0,r._3)(i,t),g="number"==typeof f?{mainAxis:f,crossAxis:0}:{mainAxis:0,crossAxis:0,...f};if(c){const e="y"===p?"height":"width",t=l.reference[p]-l.floating[e]+g.mainAxis,a=l.reference[p]+l.reference[e]-g.mainAxis;ma&&(m=a)}if(u){var w,b;const e="y"===p?"width":"height",t=["top","left"].includes((0,r.C0)(n)),a=l.reference[v]-l.floating[e]+(t&&(null==(w=s.offset)?void 0:w[v])||0)+(t?0:g.crossAxis),o=l.reference[v]+l.reference[e]+(t?0:(null==(b=s.offset)?void 0:b[v])||0)-(t?g.crossAxis:0);ho&&(h=o)}return{[p]:m,[v]:h}}}},w=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var a,o;const{placement:n,rects:s,platform:i,elements:c}=t,{apply:u=()=>{},...d}=(0,r._3)(e,t),v=await l(t,d),p=(0,r.C0)(n),m=(0,r.Sg)(n),h="y"===(0,r.TV)(n),{width:f,height:g}=s.floating;let w,b;"top"===p||"bottom"===p?(w=p,b=m===(await(null==i.isRTL?void 0:i.isRTL(c.floating))?"start":"end")?"left":"right"):(b=p,w="end"===m?"top":"bottom");const y=g-v.top-v.bottom,x=f-v.left-v.right,_=(0,r.jk)(g-v[w],y),k=(0,r.jk)(f-v[b],x),E=!t.middlewareData.shift;let C=_,j=k;if(null!=(a=t.middlewareData.shift)&&a.enabled.x&&(j=x),null!=(o=t.middlewareData.shift)&&o.enabled.y&&(C=y),E&&!m){const e=(0,r.T9)(v.left,0),t=(0,r.T9)(v.right,0),a=(0,r.T9)(v.top,0),o=(0,r.T9)(v.bottom,0);h?j=f-2*(0!==e||0!==t?e+t:(0,r.T9)(v.left,v.right)):C=g-2*(0!==a||0!==o?a+o:(0,r.T9)(v.top,v.bottom))}await u({...t,availableWidth:j,availableHeight:C});const A=await i.getDimensions(c.floating);return f!==A.width||g!==A.height?{reset:{rects:!0}}:{}}}}},81289:(e,t,a)=>{"use strict";function r(){return"undefined"!=typeof window}function o(e){return s(e)?(e.nodeName||"").toLowerCase():"#document"}function n(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function l(e){var t;return null==(t=(s(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function s(e){return!!r()&&(e instanceof Node||e instanceof n(e).Node)}function i(e){return!!r()&&(e instanceof Element||e instanceof n(e).Element)}function c(e){return!!r()&&(e instanceof HTMLElement||e instanceof n(e).HTMLElement)}function u(e){return!(!r()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof n(e).ShadowRoot)}function d(e){const{overflow:t,overflowX:a,overflowY:r,display:o}=w(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+a)&&!["inline","contents"].includes(o)}function v(e){return["table","td","th"].includes(o(e))}function p(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(e){return!1}}))}function m(e){const t=f(),a=i(e)?w(e):e;return["transform","translate","scale","rotate","perspective"].some((e=>!!a[e]&&"none"!==a[e]))||!!a.containerType&&"normal"!==a.containerType||!t&&!!a.backdropFilter&&"none"!==a.backdropFilter||!t&&!!a.filter&&"none"!==a.filter||["transform","translate","scale","rotate","perspective","filter"].some((e=>(a.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(a.contain||"").includes(e)))}function h(e){let t=y(e);for(;c(t)&&!g(t);){if(m(t))return t;if(p(t))return null;t=y(t)}return null}function f(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function g(e){return["html","body","#document"].includes(o(e))}function w(e){return n(e).getComputedStyle(e)}function b(e){return i(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function y(e){if("html"===o(e))return e;const t=e.assignedSlot||e.parentNode||u(e)&&e.host||l(e);return u(t)?t.host:t}function x(e){const t=y(e);return g(t)?e.ownerDocument?e.ownerDocument.body:e.body:c(t)&&d(t)?t:x(t)}function _(e,t,a){var r;void 0===t&&(t=[]),void 0===a&&(a=!0);const o=x(e),l=o===(null==(r=e.ownerDocument)?void 0:r.body),s=n(o);if(l){const e=k(s);return t.concat(s,s.visualViewport||[],d(o)?o:[],e&&a?_(e):[])}return t.concat(o,_(o,[],a))}function k(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}a.d(t,{$4:()=>y,CP:()=>b,L9:()=>w,Lv:()=>v,Tc:()=>f,Tf:()=>p,ZU:()=>d,_m:()=>k,ep:()=>l,eu:()=>g,gJ:()=>h,mq:()=>o,sQ:()=>m,sb:()=>c,v9:()=>_,vq:()=>i,zk:()=>n})},39175:(e,t,a)=>{"use strict";a.d(t,{B1:()=>A,C0:()=>h,DD:()=>n,Dz:()=>y,Jx:()=>u,LI:()=>i,PG:()=>g,RI:()=>c,Sg:()=>f,T9:()=>s,TV:()=>b,WJ:()=>_,_3:()=>m,aD:()=>k,bV:()=>C,jk:()=>l,lP:()=>E,nI:()=>j,qE:()=>p,r_:()=>r,sq:()=>w,w7:()=>x});const r=["top","right","bottom","left"],o=["start","end"],n=r.reduce(((e,t)=>e.concat(t,t+"-"+o[0],t+"-"+o[1])),[]),l=Math.min,s=Math.max,i=Math.round,c=Math.floor,u=e=>({x:e,y:e}),d={left:"right",right:"left",bottom:"top",top:"bottom"},v={start:"end",end:"start"};function p(e,t,a){return s(e,l(t,a))}function m(e,t){return"function"==typeof e?e(t):e}function h(e){return e.split("-")[0]}function f(e){return e.split("-")[1]}function g(e){return"x"===e?"y":"x"}function w(e){return"y"===e?"height":"width"}function b(e){return["top","bottom"].includes(h(e))?"y":"x"}function y(e){return g(b(e))}function x(e,t,a){void 0===a&&(a=!1);const r=f(e),o=y(e),n=w(o);let l="x"===o?r===(a?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[n]>t.floating[n]&&(l=C(l)),[l,C(l)]}function _(e){const t=C(e);return[k(e),t,k(t)]}function k(e){return e.replace(/start|end/g,(e=>v[e]))}function E(e,t,a,r){const o=f(e);let n=function(e,t,a){const r=["left","right"],o=["right","left"],n=["top","bottom"],l=["bottom","top"];switch(e){case"top":case"bottom":return a?t?o:r:t?r:o;case"left":case"right":return t?n:l;default:return[]}}(h(e),"start"===a,r);return o&&(n=n.map((e=>e+"-"+o)),t&&(n=n.concat(n.map(k)))),n}function C(e){return e.replace(/left|right|bottom|top/g,(e=>d[e]))}function j(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function A(e){const{x:t,y:a,width:r,height:o}=e;return{width:r,height:o,top:a,left:t,right:t+r,bottom:a+o,x:t,y:a}}},82464:(e,t,a)=>{"use strict";a.d(t,{m:()=>n});var r=a(5530),o=a(20698),n=new class extends r.Q{#e;#t;#a;constructor(){super(),this.#a=e=>{if(!o.S$&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}}}onSubscribe(){this.#t||this.setEventListener(this.#a)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#a=e,this.#t?.(),this.#t=e((e=>{"boolean"==typeof e?this.setFocused(e):this.onFocus()}))}setFocused(e){this.#e!==e&&(this.#e=e,this.onFocus())}onFocus(){this.listeners.forEach((e=>{e()}))}isFocused(){return"boolean"==typeof this.#e?this.#e:"hidden"!==globalThis.document?.visibilityState}}},69101:(e,t,a)=>{"use strict";a.d(t,{PL:()=>o});var r=a(20698);function o(e){return{onFetch:(t,a)=>{const o=async()=>{const a=t.options,o=t.fetchOptions?.meta?.fetchMore?.direction,s=t.state.data?.pages||[],i=t.state.data?.pageParams||[],c={pages:[],pageParams:[]};let u=!1;const d=t.options.queryFn||(()=>Promise.reject(new Error(`Missing queryFn: '${t.options.queryHash}'`))),v=async(e,a,o)=>{if(u)return Promise.reject();if(null==a&&e.pages.length)return Promise.resolve(e);const n={queryKey:t.queryKey,pageParam:a,direction:o?"backward":"forward",meta:t.options.meta};var l;l=n,Object.defineProperty(l,"signal",{enumerable:!0,get:()=>(t.signal.aborted?u=!0:t.signal.addEventListener("abort",(()=>{u=!0})),t.signal)});const s=await d(n),{maxPages:i}=t.options,c=o?r.ZZ:r.y9;return{pages:c(e.pages,s,i),pageParams:c(e.pageParams,a,i)}};let p;if(o&&s.length){const e="backward"===o,t={pages:s,pageParams:i},r=(e?l:n)(a,t);p=await v(t,r,e)}else{p=await v(c,i[0]??a.initialPageParam);const t=e??s.length;for(let e=1;et.options.persister?.(o,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},a):t.fetchFn=o}}}function n(e,{pages:t,pageParams:a}){const r=t.length-1;return e.getNextPageParam(t[r],t,a[r],a)}function l(e,{pages:t,pageParams:a}){return e.getPreviousPageParam?.(t[0],t,a[0],a)}},4352:(e,t,a)=>{"use strict";a.d(t,{$:()=>s,s:()=>l});var r=a(31795),o=a(91450),n=a(14610),l=class extends o.k{#r;#o;#n;#l;constructor(e){super(),this.mutationId=e.mutationId,this.#o=e.defaultOptions,this.#n=e.mutationCache,this.#r=[],this.state=e.state||{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0},this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options={...this.#o,...e},this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#r.includes(e)||(this.#r.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#r=this.#r.filter((t=>t!==e)),this.scheduleGc(),this.#n.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#r.length||("pending"===this.state.status?this.scheduleGc():this.#n.remove(this))}continue(){return this.#l?.continue()??this.execute(this.state.variables)}async execute(e){const t=()=>(this.#l=(0,n.II)({fn:()=>this.options.mutationFn?this.options.mutationFn(e):Promise.reject(new Error("No mutationFn found")),onFail:(e,t)=>{this.#s({type:"failed",failureCount:e,error:t})},onPause:()=>{this.#s({type:"pause"})},onContinue:()=>{this.#s({type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.#l.promise),a="pending"===this.state.status;try{if(!a){this.#s({type:"pending",variables:e}),await(this.#n.config.onMutate?.(e,this));const t=await(this.options.onMutate?.(e));t!==this.state.context&&this.#s({type:"pending",context:t,variables:e})}const r=await t();return await(this.#n.config.onSuccess?.(r,e,this.state.context,this)),await(this.options.onSuccess?.(r,e,this.state.context)),await(this.#n.config.onSettled?.(r,null,this.state.variables,this.state.context,this)),await(this.options.onSettled?.(r,null,e,this.state.context)),this.#s({type:"success",data:r}),r}catch(t){try{throw await(this.#n.config.onError?.(t,e,this.state.context,this)),await(this.options.onError?.(t,e,this.state.context)),await(this.#n.config.onSettled?.(void 0,t,this.state.variables,this.state.context,this)),await(this.options.onSettled?.(void 0,t,e,this.state.context)),t}finally{this.#s({type:"error",error:t})}}}#s(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"pending":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!(0,n.v_)(this.options.networkMode),status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}})(this.state),r.j.batch((()=>{this.#r.forEach((t=>{t.onMutationUpdate(e)})),this.#n.notify({mutation:this,type:"updated",action:e})}))}};function s(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}},17708:(e,t,a)=>{"use strict";a.d(t,{q:()=>s});var r=a(31795),o=a(4352),n=a(20698),l=a(5530),s=class extends l.Q{constructor(e={}){super(),this.config=e,this.#i=[],this.#c=0}#i;#c;#u;build(e,t,a){const r=new o.s({mutationCache:this,mutationId:++this.#c,options:e.defaultMutationOptions(t),state:a});return this.add(r),r}add(e){this.#i.push(e),this.notify({type:"added",mutation:e})}remove(e){this.#i=this.#i.filter((t=>t!==e)),this.notify({type:"removed",mutation:e})}clear(){r.j.batch((()=>{this.#i.forEach((e=>{this.remove(e)}))}))}getAll(){return this.#i}find(e){const t={exact:!0,...e};return this.#i.find((e=>(0,n.nJ)(t,e)))}findAll(e={}){return this.#i.filter((t=>(0,n.nJ)(e,t)))}notify(e){r.j.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}resumePausedMutations(){return this.#u=(this.#u??Promise.resolve()).then((()=>{const e=this.#i.filter((e=>e.state.isPaused));return r.j.batch((()=>e.reduce(((e,t)=>e.then((()=>t.continue().catch(n.lQ)))),Promise.resolve())))})).then((()=>{this.#u=void 0})),this.#u}}},44158:(e,t,a)=>{"use strict";a.d(t,{_:()=>s});var r=a(4352),o=a(31795),n=a(5530),l=a(20698),s=class extends n.Q{#d;#v=void 0;#p;#m;constructor(e,t){super(),this.#d=e,this.setOptions(t),this.bindMethods(),this.#h()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){const t=this.options;this.options=this.#d.defaultMutationOptions(e),(0,l.f8)(t,this.options)||this.#d.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#p,observer:this}),t?.mutationKey&&this.options.mutationKey&&(0,l.EN)(t.mutationKey)!==(0,l.EN)(this.options.mutationKey)?this.reset():this.#p?.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#p?.removeObserver(this)}onMutationUpdate(e){this.#h(),this.#f(e)}getCurrentResult(){return this.#v}reset(){this.#p?.removeObserver(this),this.#p=void 0,this.#h(),this.#f()}mutate(e,t){return this.#m=t,this.#p?.removeObserver(this),this.#p=this.#d.getMutationCache().build(this.#d,this.options),this.#p.addObserver(this),this.#p.execute(e)}#h(){const e=this.#p?.state??(0,r.$)();this.#v={...e,isPending:"pending"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset}}#f(e){o.j.batch((()=>{if(this.#m&&this.hasListeners()){const t=this.#v.variables,a=this.#v.context;"success"===e?.type?(this.#m.onSuccess?.(e.data,t,a),this.#m.onSettled?.(e.data,null,t,a)):"error"===e?.type&&(this.#m.onError?.(e.error,t,a),this.#m.onSettled?.(void 0,e.error,t,a))}this.listeners.forEach((e=>{e(this.#v)}))}))}}},31795:(e,t,a)=>{"use strict";a.d(t,{j:()=>r});var r=function(){let e=[],t=0,a=e=>{e()},r=e=>{e()},o=e=>setTimeout(e,0);const n=r=>{t?e.push(r):o((()=>{a(r)}))},l=()=>{const t=e;e=[],t.length&&o((()=>{r((()=>{t.forEach((e=>{a(e)}))}))}))};return{batch:e=>{let a;t++;try{a=e()}finally{t--,t||l()}return a},batchCalls:e=>(...t)=>{n((()=>{e(...t)}))},schedule:n,setNotifyFunction:e=>{a=e},setBatchNotifyFunction:e=>{r=e},setScheduler:e=>{o=e}}}()},95873:(e,t,a)=>{"use strict";a.d(t,{t:()=>n});var r=a(5530),o=a(20698),n=new class extends r.Q{#g=!0;#t;#a;constructor(){super(),this.#a=e=>{if(!o.S$&&window.addEventListener){const t=()=>e(!0),a=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",a,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",a)}}}}onSubscribe(){this.#t||this.setEventListener(this.#a)}onUnsubscribe(){this.hasListeners()||(this.#t?.(),this.#t=void 0)}setEventListener(e){this.#a=e,this.#t?.(),this.#t=e(this.setOnline.bind(this))}setOnline(e){this.#g!==e&&(this.#g=e,this.listeners.forEach((t=>{t(e)})))}isOnline(){return this.#g}}},24135:(e,t,a)=>{"use strict";a.d(t,{X:()=>s});var r=a(20698),o=a(31795),n=a(14610),l=a(91450),s=class extends l.k{#w;#b;#y;#x;#l;#r;#o;#_;constructor(e){super(),this.#_=!1,this.#o=e.defaultOptions,this.#k(e.options),this.#r=[],this.#y=e.cache,this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#w=e.state||function(e){const t="function"==typeof e.initialData?e.initialData():e.initialData,a=void 0!==t,r=a?"function"==typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:a?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:a?"success":"pending",fetchStatus:"idle"}}(this.options),this.state=this.#w,this.scheduleGc()}get meta(){return this.options.meta}#k(e){this.options={...this.#o,...e},this.updateGcTime(this.options.gcTime)}optionalRemove(){this.#r.length||"idle"!==this.state.fetchStatus||this.#y.remove(this)}setData(e,t){const a=(0,r.pl)(this.state.data,e,this.options);return this.#s({data:a,type:"success",dataUpdatedAt:t?.updatedAt,manual:t?.manual}),a}setState(e,t){this.#s({type:"setState",state:e,setStateOptions:t})}cancel(e){const t=this.#x;return this.#l?.cancel(e),t?t.then(r.lQ).catch(r.lQ):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#w)}isActive(){return this.#r.some((e=>!1!==e.options.enabled))}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.#r.some((e=>e.getCurrentResult().isStale))}isStaleByTime(e=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!(0,r.j3)(this.state.dataUpdatedAt,e)}onFocus(){const e=this.#r.find((e=>e.shouldFetchOnWindowFocus()));e?.refetch({cancelRefetch:!1}),this.#l?.continue()}onOnline(){const e=this.#r.find((e=>e.shouldFetchOnReconnect()));e?.refetch({cancelRefetch:!1}),this.#l?.continue()}addObserver(e){this.#r.includes(e)||(this.#r.push(e),this.clearGcTimeout(),this.#y.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.#r.includes(e)&&(this.#r=this.#r.filter((t=>t!==e)),this.#r.length||(this.#l&&(this.#_?this.#l.cancel({revert:!0}):this.#l.cancelRetry()),this.scheduleGc()),this.#y.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.#r.length}invalidate(){this.state.isInvalidated||this.#s({type:"invalidate"})}fetch(e,t){if("idle"!==this.state.fetchStatus)if(this.state.dataUpdatedAt&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#x)return this.#l?.continueRetry(),this.#x;if(e&&this.#k(e),!this.options.queryFn){const e=this.#r.find((e=>e.options.queryFn));e&&this.#k(e.options)}const a=new AbortController,r={queryKey:this.queryKey,meta:this.meta},o=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(this.#_=!0,a.signal)})};o(r);const l={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>this.options.queryFn?(this.#_=!1,this.options.persister?this.options.persister(this.options.queryFn,r,this):this.options.queryFn(r)):Promise.reject(new Error(`Missing queryFn: '${this.options.queryHash}'`))};o(l),this.options.behavior?.onFetch(l,this),this.#b=this.state,"idle"!==this.state.fetchStatus&&this.state.fetchMeta===l.fetchOptions?.meta||this.#s({type:"fetch",meta:l.fetchOptions?.meta});const s=e=>{(0,n.wm)(e)&&e.silent||this.#s({type:"error",error:e}),(0,n.wm)(e)||(this.#y.config.onError?.(e,this),this.#y.config.onSettled?.(this.state.data,e,this)),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.#l=(0,n.II)({fn:l.fetchFn,abort:a.abort.bind(a),onSuccess:e=>{void 0!==e?(this.setData(e),this.#y.config.onSuccess?.(e,this),this.#y.config.onSettled?.(e,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1):s(new Error(`${this.queryHash} data is undefined`))},onError:s,onFail:(e,t)=>{this.#s({type:"failed",failureCount:e,error:t})},onPause:()=>{this.#s({type:"pause"})},onContinue:()=>{this.#s({type:"continue"})},retry:l.options.retry,retryDelay:l.options.retryDelay,networkMode:l.options.networkMode}),this.#x=this.#l.promise,this.#x}#s(e){this.state=(t=>{switch(e.type){case"failed":return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...t,fetchStatus:"paused"};case"continue":return{...t,fetchStatus:"fetching"};case"fetch":return{...t,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:e.meta??null,fetchStatus:(0,n.v_)(this.options.networkMode)?"fetching":"paused",...!t.dataUpdatedAt&&{error:null,status:"pending"}};case"success":return{...t,data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:e.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const a=e.error;return(0,n.wm)(a)&&a.revert&&this.#b?{...this.#b,fetchStatus:"idle"}:{...t,error:a,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error"};case"invalidate":return{...t,isInvalidated:!0};case"setState":return{...t,...e.state}}})(this.state),o.j.batch((()=>{this.#r.forEach((e=>{e.onQueryUpdate()})),this.#y.notify({query:this,type:"updated",action:e})}))}}},3205:(e,t,a)=>{"use strict";a.d(t,{$:()=>s});var r=a(20698),o=a(24135),n=a(31795),l=a(5530),s=class extends l.Q{constructor(e={}){super(),this.config=e,this.#E=new Map}#E;build(e,t,a){const n=t.queryKey,l=t.queryHash??(0,r.F$)(n,t);let s=this.get(l);return s||(s=new o.X({cache:this,queryKey:n,queryHash:l,options:e.defaultQueryOptions(t),state:a,defaultOptions:e.getQueryDefaults(n)}),this.add(s)),s}add(e){this.#E.has(e.queryHash)||(this.#E.set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=this.#E.get(e.queryHash);t&&(e.destroy(),t===e&&this.#E.delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){n.j.batch((()=>{this.getAll().forEach((e=>{this.remove(e)}))}))}get(e){return this.#E.get(e)}getAll(){return[...this.#E.values()]}find(e){const t={exact:!0,...e};return this.getAll().find((e=>(0,r.MK)(t,e)))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter((t=>(0,r.MK)(e,t))):t}notify(e){n.j.batch((()=>{this.listeners.forEach((t=>{t(e)}))}))}onFocus(){n.j.batch((()=>{this.getAll().forEach((e=>{e.onFocus()}))}))}onOnline(){n.j.batch((()=>{this.getAll().forEach((e=>{e.onOnline()}))}))}}},70116:(e,t,a)=>{"use strict";a.d(t,{E:()=>u});var r=a(20698),o=a(3205),n=a(17708),l=a(82464),s=a(95873),i=a(31795),c=a(69101),u=class{#C;#n;#o;#j;#A;#S;#P;#R;constructor(e={}){this.#C=e.queryCache||new o.$,this.#n=e.mutationCache||new n.q,this.#o=e.defaultOptions||{},this.#j=new Map,this.#A=new Map,this.#S=0}mount(){this.#S++,1===this.#S&&(this.#P=l.m.subscribe((()=>{l.m.isFocused()&&(this.resumePausedMutations(),this.#C.onFocus())})),this.#R=s.t.subscribe((()=>{s.t.isOnline()&&(this.resumePausedMutations(),this.#C.onOnline())})))}unmount(){this.#S--,0===this.#S&&(this.#P?.(),this.#P=void 0,this.#R?.(),this.#R=void 0)}isFetching(e){return this.#C.findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return this.#n.findAll({...e,status:"pending"}).length}getQueryData(e){return this.#C.find({queryKey:e})?.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);return void 0!==t?Promise.resolve(t):this.fetchQuery(e)}getQueriesData(e){return this.getQueryCache().findAll(e).map((({queryKey:e,state:t})=>[e,t.data]))}setQueryData(e,t,a){const o=this.#C.find({queryKey:e}),n=o?.state.data,l=(0,r.Zw)(t,n);if(void 0===l)return;const s=this.defaultQueryOptions({queryKey:e});return this.#C.build(this,s).setData(l,{...a,manual:!0})}setQueriesData(e,t,a){return i.j.batch((()=>this.getQueryCache().findAll(e).map((({queryKey:e})=>[e,this.setQueryData(e,t,a)]))))}getQueryState(e){return this.#C.find({queryKey:e})?.state}removeQueries(e){const t=this.#C;i.j.batch((()=>{t.findAll(e).forEach((e=>{t.remove(e)}))}))}resetQueries(e,t){const a=this.#C,r={type:"active",...e};return i.j.batch((()=>(a.findAll(e).forEach((e=>{e.reset()})),this.refetchQueries(r,t))))}cancelQueries(e={},t={}){const a={revert:!0,...t},o=i.j.batch((()=>this.#C.findAll(e).map((e=>e.cancel(a)))));return Promise.all(o).then(r.lQ).catch(r.lQ)}invalidateQueries(e={},t={}){return i.j.batch((()=>{if(this.#C.findAll(e).forEach((e=>{e.invalidate()})),"none"===e.refetchType)return Promise.resolve();const a={...e,type:e.refetchType??e.type??"active"};return this.refetchQueries(a,t)}))}refetchQueries(e={},t){const a={...t,cancelRefetch:t?.cancelRefetch??!0},o=i.j.batch((()=>this.#C.findAll(e).filter((e=>!e.isDisabled())).map((e=>{let t=e.fetch(void 0,a);return a.throwOnError||(t=t.catch(r.lQ)),"paused"===e.state.fetchStatus?Promise.resolve():t}))));return Promise.all(o).then(r.lQ)}fetchQuery(e){const t=this.defaultQueryOptions(e);void 0===t.retry&&(t.retry=!1);const a=this.#C.build(this,t);return a.isStaleByTime(t.staleTime)?a.fetch(t):Promise.resolve(a.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(r.lQ).catch(r.lQ)}fetchInfiniteQuery(e){return e.behavior=(0,c.PL)(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(r.lQ).catch(r.lQ)}resumePausedMutations(){return this.#n.resumePausedMutations()}getQueryCache(){return this.#C}getMutationCache(){return this.#n}getDefaultOptions(){return this.#o}setDefaultOptions(e){this.#o=e}setQueryDefaults(e,t){this.#j.set((0,r.EN)(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...this.#j.values()];let a={};return t.forEach((t=>{(0,r.Cp)(e,t.queryKey)&&(a={...a,...t.defaultOptions})})),a}setMutationDefaults(e,t){this.#A.set((0,r.EN)(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...this.#A.values()];let a={};return t.forEach((t=>{(0,r.Cp)(e,t.mutationKey)&&(a={...a,...t.defaultOptions})})),a}defaultQueryOptions(e){if(e?._defaulted)return e;const t={...this.#o.queries,...e?.queryKey&&this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=(0,r.F$)(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.throwOnError&&(t.throwOnError=!!t.suspense),void 0===t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#o.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#C.clear(),this.#n.clear()}}},93397:(e,t,a)=>{"use strict";a.d(t,{$:()=>i});var r=a(20698),o=a(31795),n=a(82464),l=a(5530),s=a(14610),i=class extends l.Q{constructor(e,t){super(),this.options=t,this.#d=e,this.#M=null,this.bindMethods(),this.setOptions(t)}#d;#V=void 0;#z=void 0;#v=void 0;#H;#L;#M;#O;#N;#I;#B;#T;#F;#D=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(this.#V.addObserver(this),c(this.#V,this.options)?this.#G():this.updateResult(),this.#U())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return u(this.#V,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return u(this.#V,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#q(),this.#Z(),this.#V.removeObserver(this)}setOptions(e,t){const a=this.options,o=this.#V;if(this.options=this.#d.defaultQueryOptions(e),(0,r.f8)(a,this.options)||this.#d.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#V,observer:this}),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled)throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=a.queryKey),this.#W();const n=this.hasListeners();n&&d(this.#V,o,this.options,a)&&this.#G(),this.updateResult(t),!n||this.#V===o&&this.options.enabled===a.enabled&&this.options.staleTime===a.staleTime||this.#$();const l=this.#J();!n||this.#V===o&&this.options.enabled===a.enabled&&l===this.#F||this.#K(l)}getOptimisticResult(e){const t=this.#d.getQueryCache().build(this.#d,e),a=this.createResult(t,e);return function(e,t){if(!(0,r.f8)(e.getCurrentResult(),t))return!0;return!1}(this,a)&&(this.#v=a,this.#L=this.options,this.#H=this.#V.state),a}getCurrentResult(){return this.#v}trackResult(e){const t={};return Object.keys(e).forEach((a=>{Object.defineProperty(t,a,{configurable:!1,enumerable:!0,get:()=>(this.#D.add(a),e[a])})})),t}getCurrentQuery(){return this.#V}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=this.#d.defaultQueryOptions(e),a=this.#d.getQueryCache().build(this.#d,t);return a.isFetchingOptimistic=!0,a.fetch().then((()=>this.createResult(a,t)))}fetch(e){return this.#G({...e,cancelRefetch:e.cancelRefetch??!0}).then((()=>(this.updateResult(),this.#v)))}#G(e){this.#W();let t=this.#V.fetch(this.options,e);return e?.throwOnError||(t=t.catch(r.lQ)),t}#$(){if(this.#q(),r.S$||this.#v.isStale||!(0,r.gn)(this.options.staleTime))return;const e=(0,r.j3)(this.#v.dataUpdatedAt,this.options.staleTime)+1;this.#B=setTimeout((()=>{this.#v.isStale||this.updateResult()}),e)}#J(){return("function"==typeof this.options.refetchInterval?this.options.refetchInterval(this.#V):this.options.refetchInterval)??!1}#K(e){this.#Z(),this.#F=e,!r.S$&&!1!==this.options.enabled&&(0,r.gn)(this.#F)&&0!==this.#F&&(this.#T=setInterval((()=>{(this.options.refetchIntervalInBackground||n.m.isFocused())&&this.#G()}),this.#F))}#U(){this.#$(),this.#K(this.#J())}#q(){this.#B&&(clearTimeout(this.#B),this.#B=void 0)}#Z(){this.#T&&(clearInterval(this.#T),this.#T=void 0)}createResult(e,t){const a=this.#V,o=this.options,n=this.#v,l=this.#H,i=this.#L,u=e!==a?e.state:this.#z,{state:p}=e;let m,{error:h,errorUpdatedAt:f,fetchStatus:g,status:w}=p,b=!1;if(t._optimisticResults){const r=this.hasListeners(),n=!r&&c(e,t),l=r&&d(e,a,t,o);(n||l)&&(g=(0,s.v_)(e.options.networkMode)?"fetching":"paused",p.dataUpdatedAt||(w="pending")),"isRestoring"===t._optimisticResults&&(g="idle")}if(t.select&&void 0!==p.data)if(n&&p.data===l?.data&&t.select===this.#O)m=this.#N;else try{this.#O=t.select,m=t.select(p.data),m=(0,r.pl)(n?.data,m,t),this.#N=m,this.#M=null}catch(e){this.#M=e}else m=p.data;if(void 0!==t.placeholderData&&void 0===m&&"pending"===w){let e;if(n?.isPlaceholderData&&t.placeholderData===i?.placeholderData)e=n.data;else if(e="function"==typeof t.placeholderData?t.placeholderData(this.#I?.state.data,this.#I):t.placeholderData,t.select&&void 0!==e)try{e=t.select(e),this.#M=null}catch(e){this.#M=e}void 0!==e&&(w="success",m=(0,r.pl)(n?.data,e,t),b=!0)}this.#M&&(h=this.#M,m=this.#N,f=Date.now(),w="error");const y="fetching"===g,x="pending"===w,_="error"===w,k=x&&y;return{status:w,fetchStatus:g,isPending:x,isSuccess:"success"===w,isError:_,isInitialLoading:k,isLoading:k,data:m,dataUpdatedAt:p.dataUpdatedAt,error:h,errorUpdatedAt:f,failureCount:p.fetchFailureCount,failureReason:p.fetchFailureReason,errorUpdateCount:p.errorUpdateCount,isFetched:p.dataUpdateCount>0||p.errorUpdateCount>0,isFetchedAfterMount:p.dataUpdateCount>u.dataUpdateCount||p.errorUpdateCount>u.errorUpdateCount,isFetching:y,isRefetching:y&&!x,isLoadingError:_&&0===p.dataUpdatedAt,isPaused:"paused"===g,isPlaceholderData:b,isRefetchError:_&&0!==p.dataUpdatedAt,isStale:v(e,t),refetch:this.refetch}}updateResult(e){const t=this.#v,a=this.createResult(this.#V,this.options);if(this.#H=this.#V.state,this.#L=this.options,void 0!==this.#H.data&&(this.#I=this.#V),(0,r.f8)(a,t))return;this.#v=a;const o={};!1!==e?.listeners&&(()=>{if(!t)return!0;const{notifyOnChangeProps:e}=this.options,a="function"==typeof e?e():e;if("all"===a||!a&&!this.#D.size)return!0;const r=new Set(a??this.#D);return this.options.throwOnError&&r.add("error"),Object.keys(this.#v).some((e=>{const a=e;return this.#v[a]!==t[a]&&r.has(a)}))})()&&(o.listeners=!0),this.#f({...o,...e})}#W(){const e=this.#d.getQueryCache().build(this.#d,this.options);if(e===this.#V)return;const t=this.#V;this.#V=e,this.#z=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#U()}#f(e){o.j.batch((()=>{e.listeners&&this.listeners.forEach((e=>{e(this.#v)})),this.#d.getQueryCache().notify({query:this.#V,type:"observerResultsUpdated"})}))}};function c(e,t){return function(e,t){return!(!1===t.enabled||e.state.dataUpdatedAt||"error"===e.state.status&&!1===t.retryOnMount)}(e,t)||e.state.dataUpdatedAt>0&&u(e,t,t.refetchOnMount)}function u(e,t,a){if(!1!==t.enabled){const r="function"==typeof a?a(e):a;return"always"===r||!1!==r&&v(e,t)}return!1}function d(e,t,a,r){return!1!==a.enabled&&(e!==t||!1===r.enabled)&&(!a.suspense||"error"!==e.state.status)&&v(e,a)}function v(e,t){return e.isStaleByTime(t.staleTime)}},91450:(e,t,a)=>{"use strict";a.d(t,{k:()=>o});var r=a(20698),o=class{#Q;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),(0,r.gn)(this.gcTime)&&(this.#Q=setTimeout((()=>{this.optionalRemove()}),this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(r.S$?1/0:3e5))}clearGcTimeout(){this.#Q&&(clearTimeout(this.#Q),this.#Q=void 0)}}},14610:(e,t,a)=>{"use strict";a.d(t,{II:()=>u,v_:()=>s,wm:()=>c});var r=a(82464),o=a(95873),n=a(20698);function l(e){return Math.min(1e3*2**e,3e4)}function s(e){return"online"!==(e??"online")||o.t.isOnline()}var i=class{constructor(e){this.revert=e?.revert,this.silent=e?.silent}};function c(e){return e instanceof i}function u(e){let t,a,c,u=!1,d=0,v=!1;const p=new Promise(((e,t)=>{a=e,c=t})),m=()=>!r.m.isFocused()||"always"!==e.networkMode&&!o.t.isOnline(),h=r=>{v||(v=!0,e.onSuccess?.(r),t?.(),a(r))},f=a=>{v||(v=!0,e.onError?.(a),t?.(),c(a))},g=()=>new Promise((a=>{t=e=>{const t=v||!m();return t&&a(e),t},e.onPause?.()})).then((()=>{t=void 0,v||e.onContinue?.()})),w=()=>{if(v)return;let t;try{t=e.fn()}catch(e){t=Promise.reject(e)}Promise.resolve(t).then(h).catch((t=>{if(v)return;const a=e.retry??(n.S$?0:3),r=e.retryDelay??l,o="function"==typeof r?r(d,t):r,s=!0===a||"number"==typeof a&&d{if(m())return g()})).then((()=>{u?f(t):w()}))):f(t)}))};return s(e.networkMode)?w():g().then(w),{promise:p,cancel:t=>{v||(f(new i(t)),e.abort?.())},continue:()=>{const e=t?.();return e?p:Promise.resolve()},cancelRetry:()=>{u=!0},continueRetry:()=>{u=!1}}}},5530:(e,t,a)=>{"use strict";a.d(t,{Q:()=>r});var r=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}}},20698:(e,t,a)=>{"use strict";a.d(t,{Cp:()=>v,EN:()=>d,F$:()=>u,MK:()=>i,S$:()=>r,ZZ:()=>x,Zw:()=>n,f8:()=>m,gn:()=>l,j3:()=>s,lQ:()=>o,nJ:()=>c,pl:()=>b,y9:()=>y,yy:()=>w});var r="undefined"==typeof window||"Deno"in window;function o(){}function n(e,t){return"function"==typeof e?e(t):e}function l(e){return"number"==typeof e&&e>=0&&e!==1/0}function s(e,t){return Math.max(e+(t||0)-Date.now(),0)}function i(e,t){const{type:a="all",exact:r,fetchStatus:o,predicate:n,queryKey:l,stale:s}=e;if(l)if(r){if(t.queryHash!==u(l,t.options))return!1}else if(!v(t.queryKey,l))return!1;if("all"!==a){const e=t.isActive();if("active"===a&&!e)return!1;if("inactive"===a&&e)return!1}return("boolean"!=typeof s||t.isStale()===s)&&((void 0===o||o===t.state.fetchStatus)&&!(n&&!n(t)))}function c(e,t){const{exact:a,status:r,predicate:o,mutationKey:n}=e;if(n){if(!t.options.mutationKey)return!1;if(a){if(d(t.options.mutationKey)!==d(n))return!1}else if(!v(t.options.mutationKey,n))return!1}return(!r||t.state.status===r)&&!(o&&!o(t))}function u(e,t){return(t?.queryKeyHashFn||d)(e)}function d(e){return JSON.stringify(e,((e,t)=>f(t)?Object.keys(t).sort().reduce(((e,a)=>(e[a]=t[a],e)),{}):t))}function v(e,t){return e===t||typeof e==typeof t&&(!(!e||!t||"object"!=typeof e||"object"!=typeof t)&&!Object.keys(t).some((a=>!v(e[a],t[a]))))}function p(e,t){if(e===t)return e;const a=h(e)&&h(t);if(a||f(e)&&f(t)){const r=a?e:Object.keys(e),o=r.length,n=a?t:Object.keys(t),l=n.length,s=a?[]:{};let i=0;for(let o=0;o{setTimeout(t,e)}))}function b(e,t,a){return"function"==typeof a.structuralSharing?a.structuralSharing(e,t):!1!==a.structuralSharing?p(e,t):t}function y(e,t,a=0){const r=[...e,t];return a&&r.length>a?r.slice(1):r}function x(e,t,a=0){const r=[t,...e];return a&&r.length>a?r.slice(0,-1):r}},77115:(e,t,a)=>{"use strict";a.d(t,{Ht:()=>s,jE:()=>l});var r=a(51609),o=a(10790),n=r.createContext(void 0),l=e=>{const t=r.useContext(n);if(e)return e;if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},s=({client:e,children:t})=>(r.useEffect((()=>(e.mount(),()=>{e.unmount()})),[e]),(0,o.jsx)(n.Provider,{value:e,children:t}))},89690:(e,t,a)=>{"use strict";a.d(t,{h:()=>l});var r=a(51609);a(10790);function o(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var n=r.createContext(o()),l=()=>r.useContext(n)},34804:(e,t,a)=>{"use strict";a.d(t,{$1:()=>s,LJ:()=>n,wZ:()=>l});var r=a(51609),o=a(55492),n=(e,t)=>{(e.suspense||e.throwOnError)&&(t.isReset()||(e.retryOnMount=!1))},l=e=>{r.useEffect((()=>{e.clearReset()}),[e])},s=({result:e,errorResetBoundary:t,throwOnError:a,query:r})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(0,o.G)(a,[e.error,r])},64796:(e,t,a)=>{"use strict";a.d(t,{w:()=>n});var r=a(51609),o=r.createContext(!1),n=()=>r.useContext(o);o.Provider},937:(e,t,a)=>{"use strict";a.d(t,{EU:()=>o,iL:()=>n,tu:()=>r});var r=e=>{e.suspense&&"number"!=typeof e.staleTime&&(e.staleTime=1e3)},o=(e,t)=>e?.suspense&&t.isPending,n=(e,t,a)=>t.fetchOptimistic(e).catch((()=>{a.clearReset()}))},4611:(e,t,a)=>{"use strict";a.d(t,{t:()=>u});var r=a(51609),o=a(31795),n=a(89690),l=a(77115),s=a(64796),i=a(34804),c=a(937);function u(e,t,a){const u=(0,l.jE)(a),d=(0,s.w)(),v=(0,n.h)(),p=u.defaultQueryOptions(e);p._optimisticResults=d?"isRestoring":"optimistic",(0,c.tu)(p),(0,i.LJ)(p,v),(0,i.wZ)(v);const[m]=r.useState((()=>new t(u,p))),h=m.getOptimisticResult(p);if(r.useSyncExternalStore(r.useCallback((e=>{const t=d?()=>{}:m.subscribe(o.j.batchCalls(e));return m.updateResult(),t}),[m,d]),(()=>m.getCurrentResult()),(()=>m.getCurrentResult())),r.useEffect((()=>{m.setOptions(p,{listeners:!1})}),[p,m]),(0,c.EU)(p,h))throw(0,c.iL)(p,m,v);if((0,i.$1)({result:h,errorResetBoundary:v,throwOnError:p.throwOnError,query:u.getQueryCache().get(p.queryHash)}))throw h.error;return p.notifyOnChangeProps?h:m.trackResult(h)}},34613:(e,t,a)=>{"use strict";a.d(t,{n:()=>i});var r=a(51609),o=a(44158),n=a(31795),l=a(77115),s=a(55492);function i(e,t){const a=(0,l.jE)(t),[i]=r.useState((()=>new o._(a,e)));r.useEffect((()=>{i.setOptions(e)}),[i,e]);const u=r.useSyncExternalStore(r.useCallback((e=>i.subscribe(n.j.batchCalls(e))),[i]),(()=>i.getCurrentResult()),(()=>i.getCurrentResult())),d=r.useCallback(((e,t)=>{i.mutate(e,t).catch(c)}),[i]);if(u.error&&(0,s.G)(i.options.throwOnError,[u.error]))throw u.error;return{...u,mutate:d,mutateAsync:u.mutate}}function c(){}},35104:(e,t,a)=>{"use strict";a.d(t,{I:()=>n});var r=a(93397),o=a(4611);function n(e,t){return(0,o.t)(e,r.$,t)}},55492:(e,t,a)=>{"use strict";function r(e,t){return"function"==typeof e?e(...t):!!e}a.d(t,{G:()=>r})},13022:(e,t,a)=>{"use strict";function r(e){var t,a,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var n=e.length;for(t=0;to});const o=function(){for(var e,t,a=0,o="",n=arguments.length;a{"use strict";a.d(t,{A:()=>u});var r=a(3924),o=a(86087),n=a(27723),l=a(28120),s=a(51609),i=a(21183);const __=n.__,c=e=>{const{productId:t,siteRawUrl:a}=e,n=`https://cloud.jetpack.com/landing/${a}`,l=(0,i.p)(t),c={jetpack_anti_spam:{title:__("Jetpack Anti-spam is active!","jetpack-my-jetpack"),text:__("We'll take care of everything from here. Now you can enjoy a spam-free site!","jetpack-my-jetpack")},jetpack_backup:{title:__("Jetpack Backup is active!","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)(__("You can see your backups and restore your site on cloud.jetpack.com. If you ever lose access to your site, you can restore it there.","jetpack-my-jetpack"),{a:s.createElement("a",{href:n})})},jetpack_complete:{title:__("Jetpack Complete is active!","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)(__("You can see your backups, security scans, and restore your site on cloud.jetpack.com. If you ever lose access to your site, you can restore it there.","jetpack-my-jetpack"),{a:s.createElement("a",{href:n})})},jetpack_scan:{title:__("Jetpack Scan is active!","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)(__("You can see your security scans on cloud.jetpack.com.","jetpack-my-jetpack"),{a:s.createElement("a",{href:n})})},jetpack_search:{title:__("Jetpack Search is active!","jetpack-my-jetpack"),text:__("Next, we'll help you customize the Search experience for your visitors.","jetpack-my-jetpack")},jetpack_security:{title:__("Jetpack Security is active!","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)(__("You can see your backups, security scans, and restore your site on cloud.jetpack.com. If you ever lose access to your site, you can restore it there.","jetpack-my-jetpack"),{a:s.createElement("a",{href:n})})},jetpack_videopress:{title:__("Jetpack VideoPress is active!","jetpack-my-jetpack"),text:__("Experience high-quality, ad-free video built specifically for WordPress.","jetpack-my-jetpack")},jetpack_social_advanced:{title:__("Jetpack Social Advanced is active!","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)(__("Create amazing link previews for your posts using Social Image Generator. Learn more here.

            Learn how to make the most out of Jetpack Social here.

            ","jetpack-my-jetpack"),{a:s.createElement("a",{href:(0,r.A)("jetpack-social-sig-support-page"),target:"_blank",rel:"noreferrer"}),br:s.createElement("br",null),link:s.createElement("a",{href:(0,r.A)("social-plugin-publicize-support-admin-page"),target:"_blank",rel:"noreferrer"})})},jetpack_social_basic:{title:__("Jetpack Social Basic is active!","jetpack-my-jetpack"),text:(0,o.createInterpolateElement)(__("Enjoy unlimited shares with Jetpack Social Basic. Learn how to make the most out of Jetpack Social here.","jetpack-my-jetpack"),{a:s.createElement("a",{href:(0,r.A)("social-plugin-publicize-support-admin-page"),target:"_blank",rel:"noreferrer"})})},default:{title:__("Your product is active!","jetpack-my-jetpack"),text:__("You're all set!","jetpack-my-jetpack")}};return s.createElement("div",{className:"jp-license-activation-screen-success-info--product-details"},s.createElement("h1",null,c[l].title," ",String.fromCodePoint(127881)),s.createElement("p",null,c[l].text))};c.propTypes={dashboardUrl:l.string,productId:l.number};const u=c},21183:(e,t,a)=>{"use strict";a.d(t,{p:()=>o});const r={jetpack_anti_spam:[2110,2111],jetpack_backup:[2100,2101,2102,2103,2112,2113,2114,2115],jetpack_complete:[2014,2015],jetpack_scan:[2106,2107,2108,2109],jetpack_search:[2104,2105],jetpack_security:[2010,2011,2012,2013,2016,2017,2019,2020],jetpack_videopress:[2116,2117],jetpack_social_advanced:[2602,2603,2604],jetpack_social_basic:[2503,2504,2037]};function o(e){return Object.keys(r).find((t=>r[t].includes(e)))||"default"}},73010:(e,t,a)=>{"use strict";a.d(t,{A:()=>l});var r=a(1455),o=a(86087);const n=async()=>(await r({path:"wp/v2/plugins"})).filter((e=>"active"===e.status));function l(){const[e,t]=(0,o.useState)([]),[a,r]=(0,o.useState)(!0),l=(0,o.useCallback)((async()=>{try{const e=await n();t(e)}catch{t([])}finally{r(!1)}}),[]);return(0,o.useEffect)((()=>{l()}),[l]),[e,a]}},38377:e=>{"use strict";e.exports=JSON.parse('{"T":{"White":"#fff","Black":"#000","Gray 0":"#f6f7f7","Gray 5":"#dcdcde","Gray 10":"#c3c4c7","Gray 20":"#a7aaad","Gray 30":"#8c8f94","Gray 40":"#787c82","Gray 50":"#646970","Gray 60":"#50575e","Gray 70":"#3c434a","Gray 80":"#2c3338","Gray 90":"#1d2327","Gray 100":"#101517","Gray":"#646970","Blue 0":"#fbfcfe","Blue 5":"#f7f8fe","Blue 10":"#d6ddf9","Blue 20":"#adbaf3","Blue 30":"#7b90ff","Blue 40":"#546ff3","Blue 50":"#3858e9","Blue 60":"#2a46ce","Blue 70":"#1d35b4","Blue 80":"#1f3286","Blue 90":"#14215a","Blue 100":"#0a112d","Blue":"#3858e9","WordPress Blue 0":"#fbfcfe","WordPress Blue 5":"#f7f8fe","WordPress Blue 10":"#d6ddf9","WordPress Blue 20":"#adbaf3","WordPress Blue 30":"#7b90ff","WordPress Blue 40":"#546ff3","WordPress Blue 50":"#3858e9","WordPress Blue 60":"#2a46ce","WordPress Blue 70":"#1d35b4","WordPress Blue 80":"#1f3286","WordPress Blue 90":"#14215a","WordPress Blue 100":"#0a112d","WordPress Blue":"#3858e9","Purple 0":"#f2e9ed","Purple 5":"#ebcee0","Purple 10":"#e3afd5","Purple 20":"#d48fc8","Purple 30":"#c475bd","Purple 40":"#b35eb1","Purple 50":"#984a9c","Purple 60":"#7c3982","Purple 70":"#662c6e","Purple 80":"#4d2054","Purple 90":"#35163b","Purple 100":"#1e0c21","Purple":"#984a9c","Pink 0":"#f5e9ed","Pink 5":"#f2ceda","Pink 10":"#f7a8c3","Pink 20":"#f283aa","Pink 30":"#eb6594","Pink 40":"#e34c84","Pink 50":"#c9356e","Pink 60":"#ab235a","Pink 70":"#8c1749","Pink 80":"#700f3b","Pink 90":"#4f092a","Pink 100":"#260415","Pink":"#c9356e","Red 0":"#f7ebec","Red 5":"#facfd2","Red 10":"#ffabaf","Red 20":"#ff8085","Red 30":"#f86368","Red 40":"#e65054","Red 50":"#d63638","Red 60":"#b32d2e","Red 70":"#8a2424","Red 80":"#691c1c","Red 90":"#451313","Red 100":"#240a0a","Red":"#d63638","Orange 0":"#f5ece6","Orange 5":"#f7dcc6","Orange 10":"#ffbf86","Orange 20":"#faa754","Orange 30":"#e68b28","Orange 40":"#d67709","Orange 50":"#b26200","Orange 60":"#8a4d00","Orange 70":"#704000","Orange 80":"#543100","Orange 90":"#361f00","Orange 100":"#1f1200","Orange":"#b26200","Yellow 0":"#f5f1e1","Yellow 5":"#f5e6b3","Yellow 10":"#f2d76b","Yellow 20":"#f0c930","Yellow 30":"#deb100","Yellow 40":"#c08c00","Yellow 50":"#9d6e00","Yellow 60":"#7d5600","Yellow 70":"#674600","Yellow 80":"#4f3500","Yellow 90":"#320","Yellow 100":"#1c1300","Yellow":"#9d6e00","Green 0":"#e6f2e8","Green 5":"#b8e6bf","Green 10":"#68de86","Green 20":"#1ed15a","Green 30":"#00ba37","Green 40":"#00a32a","Green 50":"#008a20","Green 60":"#007017","Green 70":"#005c12","Green 80":"#00450c","Green 90":"#003008","Green 100":"#001c05","Green":"#008a20","Celadon 0":"#e4f2ed","Celadon 5":"#a7e8d3","Celadon 10":"#66deb9","Celadon 20":"#31cc9f","Celadon 30":"#09b585","Celadon 40":"#009e73","Celadon 50":"#008763","Celadon 60":"#007053","Celadon 70":"#005c44","Celadon 80":"#004533","Celadon 90":"#003024","Celadon 100":"#001c15","Celadon":"#008763","Automattic Blue 0":"#ebf4fa","Automattic Blue 5":"#c4e2f5","Automattic Blue 10":"#88ccf2","Automattic Blue 20":"#5ab7e8","Automattic Blue 30":"#24a3e0","Automattic Blue 40":"#1490c7","Automattic Blue 50":"#0277a8","Automattic Blue 60":"#036085","Automattic Blue 70":"#02506e","Automattic Blue 80":"#02384d","Automattic Blue 90":"#022836","Automattic Blue 100":"#021b24","Automattic Blue":"#24a3e0","Simplenote Blue 0":"#e9ecf5","Simplenote Blue 5":"#ced9f2","Simplenote Blue 10":"#abc1f5","Simplenote Blue 20":"#84a4f0","Simplenote Blue 30":"#618df2","Simplenote Blue 40":"#4678eb","Simplenote Blue 50":"#3361cc","Simplenote Blue 60":"#1d4fc4","Simplenote Blue 70":"#113ead","Simplenote Blue 80":"#0d2f85","Simplenote Blue 90":"#09205c","Simplenote Blue 100":"#05102e","Simplenote Blue":"#3361cc","WooCommerce Purple 0":"#f2edff","WooCommerce Purple 5":"#e1d7ff","WooCommerce Purple 10":"#d1c1ff","WooCommerce Purple 20":"#b999ff","WooCommerce Purple 30":"#a77eff","WooCommerce Purple 40":"#873eff","WooCommerce Purple 50":"#720eec","WooCommerce Purple 60":"#6108ce","WooCommerce Purple 70":"#5007aa","WooCommerce Purple 80":"#3c087e","WooCommerce Purple 90":"#2c045d","WooCommerce Purple 100":"#1f0342","WooCommerce Purple":"#720eec","Jetpack Green 0":"#f0f2eb","Jetpack Green 5":"#d0e6b8","Jetpack Green 10":"#9dd977","Jetpack Green 20":"#64ca43","Jetpack Green 30":"#2fb41f","Jetpack Green 40":"#069e08","Jetpack Green 50":"#008710","Jetpack Green 60":"#007117","Jetpack Green 70":"#005b18","Jetpack Green 80":"#004515","Jetpack Green 90":"#003010","Jetpack Green 100":"#001c09","Jetpack Green":"#069e08"}}')}},t={};function a(r){var o=t[r];if(void 0!==o)return o.exports;var n=t[r]={exports:{}};return e[r](n,n.exports,a),n.exports}a.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t},a.d=(e,t)=>{for(var r in t)a.o(t,r)&&!a.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),a.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;a.g.importScripts&&(e=a.g.location+"");var t=a.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");if(r.length)for(var o=r.length-1;o>-1&&(!e||!/^http(s?):/.test(e));)e=r[o--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),a.p=e})(),(()=>{"use strict";var e=a(86087),t=a(51609),r=a(29539),o=a(70028),n=a(48848),l=a(91499),s=a(52912),i=a(87494),c=a(36092),u=a(93418),d=a(8823),v=a(48931),p=a(38837),m=a(68242),h=(a(75001),a(90926));function f(){const e=(0,r.zy)();return(0,t.useEffect)((()=>window.scrollTo(0,0)),[e]),null}const g=()=>{const{loadAddLicenseScreen:e}=(0,m.A$)();return React.createElement(h.A,null,React.createElement(o.I9,null,React.createElement(f,null),React.createElement(r.BV,null,React.createElement(r.qh,{path:p.NM.Home,element:React.createElement(s.A,null)}),React.createElement(r.qh,{path:p.NM.Connection,element:React.createElement(l.A,null)}),React.createElement(r.qh,{path:p.NM.AddAkismet,element:React.createElement(c.wU,null)}),React.createElement(r.qh,{path:p.NM.AddAntiSpam,element:React.createElement(r.C5,{replace:!0,to:p.NM.AddAkismet})}),React.createElement(r.qh,{path:p.NM.AddBackup,element:React.createElement(c.xE,null)}),React.createElement(r.qh,{path:p.NM.AddBoost,element:React.createElement(c.yX,null)}),React.createElement(r.qh,{path:p.NM.AddCRM,element:React.createElement(c.X7,null)}),React.createElement(r.qh,{path:p.NM.AddJetpackAI,element:React.createElement(u.A,null)}),React.createElement(r.qh,{path:p.NM.AddExtras,element:React.createElement(c.QX,null)}),React.createElement(r.qh,{path:p.NM.AddProtect,element:React.createElement(c.qT,null)}),React.createElement(r.qh,{path:p.NM.AddScan,element:React.createElement(c.og,null)}),React.createElement(r.qh,{path:p.NM.AddSocial,element:React.createElement(c.C,null)}),React.createElement(r.qh,{path:p.NM.AddSearch,element:React.createElement(c.t7,null)}),React.createElement(r.qh,{path:p.NM.AddVideoPress,element:React.createElement(c.JM,null)}),React.createElement(r.qh,{path:p.NM.AddStats,element:React.createElement(c.Gf,null)}),e&&React.createElement(r.qh,{path:p.NM.AddLicense,element:React.createElement(n.A,null)}),React.createElement(r.qh,{path:p.NM.JetpackAi,element:React.createElement(d.A,null)}),React.createElement(r.qh,{path:p.NM.AddSecurity,element:React.createElement(c.NC,null)}),React.createElement(r.qh,{path:p.NM.AddGrowth,element:React.createElement(c.Ml,null)}),React.createElement(r.qh,{path:p.NM.AddComplete,element:React.createElement(c.Qt,null)}),React.createElement(r.qh,{path:p.NM.Onboarding,element:React.createElement(i.A,null)}),React.createElement(r.qh,{path:p.NM.RedeemToken,element:React.createElement(v.A,null)}),React.createElement(r.qh,{path:"*",element:React.createElement(s.A,null)}))))};!function(){const t=document.getElementById("my-jetpack-container");null!==t&&(0,e.createRoot)(t).render(React.createElement(g,null))}()})()})(); \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js.LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js.LICENSE.txt deleted file mode 100644 index 5676d7d3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.js.LICENSE.txt +++ /dev/null @@ -1,50 +0,0 @@ -/* - * Exposes number format capability - * - * @copyright Copyright (c) 2013 Kevin van Zonneveld (http://kvz.io) and Contributors (http://phpjs.org/authors). - * @license See CREDITS.md - * @see https://github.com/kvz/phpjs/blob/ffe1356af23a6f2512c84c954dd4e828e92579fa/functions/strings/number_format.js - */ - -/** - * @license React - * use-sync-external-store-shim.production.js - * - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */ - -/** - * @remix-run/router v1.21.0 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */ - -/** - * React Router DOM v6.28.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */ - -/** - * React Router v6.28.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */ diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.rtl.css b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.rtl.css deleted file mode 100644 index 121d2393..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/build/index.rtl.css +++ /dev/null @@ -1 +0,0 @@ -.activation-screen-error__message{align-items:flex-start;display:flex;flex-direction:row;margin-top:calc(var(--spacing-base)*.5);max-width:500px}.activation-screen-error__message svg{margin-right:-3px}.activation-screen-error__message span{font-size:13px;font-weight:500;letter-spacing:-.044em;line-height:20px}.activation-screen-error__message--error{color:var(--jp-red)}.activation-screen-error__message--error svg{fill:var(--jp-red)}.activation-screen-error__message--success{color:var(--jp-green)}.activation-screen-error__message--success svg{fill:var(--jp-green)}.activation-screen-error__info{background-color:var(--jp-gray-0);border:1px solid var(--jp-green-0);border-radius:var(--jp-border-radius);color:var(--jp-gray-80);font-size:var(--font-body-small);line-height:calc(var(--font-title-small) - 2px);margin:32px 0 8px;padding:var(--jp-modal-padding-small)}.activation-screen-error__info>p{font-size:var(--font-body-small);margin:0 0 1em}.activation-screen-error__info>p:last-child{margin-bottom:0}.activation-screen-error__info ol>li::marker{font-weight:700}.activation-screen-error__info a{color:var(--jp-green-50)}.activation-screen-error__info a:active,.activation-screen-error__info a:hover{color:var(--jp-green-70)}.jp-license-activation-screen-controls .activation-screen-error__info>p{font-size:var(--font-body-small);margin:0 0 1em}.jp-license-activation-screen-controls .activation-screen-error__info>p:last-child{margin-bottom:0}.jp-license-activation-screen-controls{background:var(--jp-white);display:flex;flex-direction:column;justify-content:space-between;padding:32px}.jp-license-activation-screen-controls h1{font-size:44px;font-weight:700;line-height:1.4;margin:.67em 0}.jp-license-activation-screen-controls p{font-size:var(--font-body);margin:1em 0}.jp-license-activation-screen-controls label{font-size:var(--font-body);font-weight:600}@media screen and (min-width:780px){.jp-license-activation-screen-controls{padding:64px}}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success{margin-top:10px;max-width:500px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field .components-input-control__label.components-input-control__label.components-input-control__label,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error .components-input-control__label.components-input-control__label.components-input-control__label,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success .components-input-control__label.components-input-control__label.components-input-control__label{font-size:var(--font-body);font-weight:600}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field select.components-select-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error select.components-select-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success select.components-select-control__input{border-radius:var(--jp-border-radius);font-size:18px;line-height:24px;margin:0;min-height:48px}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field input.components-text-control__input{border:1px solid var(--jp-gray-40)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-error select.components-select-control__input{border:1px solid var(--jp-red)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success input.components-text-control__input,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--license-field-with-success select.components-select-control__input{border:1px solid var(--jp-green)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active{background-color:var(--jp-black);border-radius:4px;color:var(--jp-white);display:flex;font-size:16px;font-size:var(--font-body);font-style:normal;font-weight:600;justify-content:center;line-height:24px;margin-top:24px;min-height:48px;min-width:158px;padding:13.5px 45px;width:100%}@media screen and (min-width:480px){.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active{width:auto}}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active:hover,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:hover{background-color:var(--jp-black-80);color:var(--jp-white)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active:focus,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:focus{background-color:var(--jp-black-80);border:1px solid var(--jp-white);color:var(--jp-white)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active:disabled,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active[disabled],.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:disabled,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button[disabled]{background-color:var(--jp-gray);color:var(--jp-gray-20)}.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button .jp-components-spinner,.jp-license-activation-screen-controls .jp-license-activation-screen-controls--button:active .jp-components-spinner{width:100%}@keyframes rotate-spinner{to{transform:rotate(-1turn)}}.jp-components-spinner{align-items:center;display:flex}.jp-components-spinner__inner,.jp-components-spinner__outer{animation:3s linear infinite;animation-name:rotate-spinner;border:.1em solid transparent;border-radius:50%;box-sizing:border-box;margin:auto}.jp-components-spinner__outer{border-top-color:#fff}.jp-components-spinner__inner{border-left-color:#fff;border-top-color:#fff;height:100%;opacity:.4;width:100%}.jp-license-activation-screen-illustration{align-items:center;background:var(--jp-white-off);display:flex;flex-direction:column;justify-content:space-between;padding:32px}.jp-license-activation-screen-illustration--wrapper{display:flex;flex:1}.jp-license-activation-screen-illustration--wrapper img{align-self:center;height:auto;max-width:100%}.jp-license-activation-screen-illustration--support-link{flex:0}.components-button.jp-license-activation-screen-success-info--button,.components-button.jp-license-activation-screen-success-info--button:active,.components-button.jp-license-activation-screen-success-info--button:visited{background-color:var(--jp-black);border-radius:4px;color:var(--jp-white);font-size:16px;font-size:var(--font-body);font-style:normal;font-weight:600;justify-content:center;line-height:24px;margin:0 0 20px 40px;min-height:48px;min-width:158px;padding:13.5px 45px;width:100%}@media screen and (min-width:480px){.components-button.jp-license-activation-screen-success-info--button,.components-button.jp-license-activation-screen-success-info--button:active,.components-button.jp-license-activation-screen-success-info--button:visited{width:auto}}.components-button.jp-license-activation-screen-success-info--button:active:hover,.components-button.jp-license-activation-screen-success-info--button:hover,.components-button.jp-license-activation-screen-success-info--button:visited:hover{background-color:var(--jp-black-80);color:var(--jp-white)}.components-button.jp-license-activation-screen-success-info--button:active:focus,.components-button.jp-license-activation-screen-success-info--button:focus,.components-button.jp-license-activation-screen-success-info--button:visited:focus{background-color:var(--jp-black-80);border:1px solid var(--jp-white);color:var(--jp-white)}.components-button.jp-license-activation-screen-success-info--button:active:disabled,.components-button.jp-license-activation-screen-success-info--button:active[disabled],.components-button.jp-license-activation-screen-success-info--button:disabled,.components-button.jp-license-activation-screen-success-info--button:visited:disabled,.components-button.jp-license-activation-screen-success-info--button:visited[disabled],.components-button.jp-license-activation-screen-success-info--button[disabled]{background-color:var(--jp-gray);color:var(--jp-gray-20)}.components-button.jp-license-activation-screen-success-info--button .jp-components-spinner,.components-button.jp-license-activation-screen-success-info--button:active .jp-components-spinner,.components-button.jp-license-activation-screen-success-info--button:visited .jp-components-spinner{width:100%}.jp-license-activation-screen-success-info--product-details h1{line-height:52px}.jp-license-activation-screen-success-info--product-details a{color:var(--jp-black);text-decoration:underline!important}.jp-license-activation-screen-success-info--external-link{color:var(--jp-black);font-size:16px;font-style:normal;font-weight:600;text-decoration:underline!important;white-space:nowrap}.jp-license-activation-screen-success-info{background:var(--jp-white);display:flex;flex-direction:column;justify-content:space-between;padding:32px}.jp-license-activation-screen-success-info h1{font-size:44px;font-weight:700;line-height:1.4;margin:.67em 0}.jp-license-activation-screen-success-info p{font-size:var(--font-body);margin:1em 0}.jp-license-activation-screen-success-info label{font-size:var(--font-body);font-weight:600}@media screen and (min-width:780px){.jp-license-activation-screen-success-info{padding:64px}}@media screen and (max-width:480px){.jp-license-activation-screen-success-info .jp-license-activation-screen-success-info--buttons{text-align:center}}.EiaNctK1_P9pPqOeiaSI{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ogHZg_sJCljylz3VJfsf{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.ogHZg_sJCljylz3VJfsf{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.ogHZg_sJCljylz3VJfsf{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.zv7eGvijKRkbPVakubHw{grid-column-end:span 1}.VoJNoiya_1ck3_kXS6_C{grid-column-end:span 2}.ecv0NO526NoTNbpALA1A{grid-column-end:span 3}.OfBdkceMzeHvRbzhqDlP{grid-column-end:span 4}@media(min-width:600px){.JLb3NpEKN8pOaWd7K1bu{grid-column-end:span 1}.fsMPGqPKE4mjMIPFwl77{grid-column-end:span 2}.DIK_zdaGAQ09eKspBJ4E{grid-column-end:span 3}.shXYpxPu3WCJsR8aOHtz{grid-column-end:span 4}.s7ElrOqG_yGd5SIfwqOR{grid-column-end:span 5}.Cxml9uzGvArAL8_RDs_p{grid-column-end:span 6}.aANxBKDGx72eDqU0iUPj{grid-column-end:span 7}.XxyzuTY3mnQcl9EGZadm{grid-column-end:span 8}}@media(min-width:960px){.Sfo4WaSNIWInJ93Abd3w{grid-column-end:span 1}.tQS7SKUGrU4THhWMysbo{grid-column-end:span 2}.I94U7mpY4h16pcOksZNF{grid-column-end:span 3}.uWMb9k77kQxBdS5MTt0s{grid-column-end:span 4}.rKwEEZQxK9s_POMg5Jss{grid-column-end:span 5}.UcPXX_s06IPCkF7ZjH3D{grid-column-end:span 6}.CrQdtiCFkRbzY6K2dFvt{grid-column-end:span 7}.rEUALOmOdUBXO0Us871z{grid-column-end:span 8}.NqXa9TlcTEviVsB53hBV{grid-column-end:span 9}.OnWVeiQiwgQ9lzdGPW66{grid-column-end:span 10}.D2PkTcy7b8u2K9QXY6VQ{grid-column-end:span 11}.EcqBhzAyxo5RDc2Y6m7K{grid-column-end:span 12}}@media(max-width:960px){.gB1mWzHOM38d80lrhBRX{display:none}}@media(max-width:600px){.KNQXLP78ejczOkour3zg{display:none}}.rBVbaVWBnBRtTMrUKZxm{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);display:block;margin:32px 0;padding:16px 24px 16px 64px;position:relative;text-decoration:none}.rBVbaVWBnBRtTMrUKZxm span{display:block}.rBVbaVWBnBRtTMrUKZxm span:last-of-type{font-weight:600}.rBVbaVWBnBRtTMrUKZxm:focus span:last-of-type,.rBVbaVWBnBRtTMrUKZxm:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.rBVbaVWBnBRtTMrUKZxm:focus:after,.rBVbaVWBnBRtTMrUKZxm:hover:after{transform:translateY(-50%) translateX(-8px)}.rBVbaVWBnBRtTMrUKZxm:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;left:24px;position:absolute;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.gfM_DIJrVbRhmKdAphIm{background:var(--jp-white);border-radius:var(--jp-modal-radius);box-shadow:0 12px 16px -.5px rgba(0,0,0,.15);height:max-content;margin:3rem auto;max-width:414px;overflow:hidden;position:relative;transition:height .25s cubic-bezier(.59,.37,.18,1.19) 0;width:90%;will-change:height}.gfM_DIJrVbRhmKdAphIm>div:first-child{padding:0}.gfM_DIJrVbRhmKdAphIm *{box-sizing:border-box;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.gfM_DIJrVbRhmKdAphIm p{color:var(--jp-black)}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN{display:none}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh{height:614px;transition-delay:2.15s}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh h2{margin-top:0}._j4GWTmW5psCHFYh6R0x{align-self:flex-start;margin-top:var(--jp-gap)!important;padding:8px var(--jp-modal-padding-small)!important;width:100%}.saSAjv8yulVXQDoqDJEI{font-weight:500;line-height:110%;margin-bottom:8px}.O_hcdbeMivIhBn7ApDnS{line-height:140%}@media(min-width:760px){.gfM_DIJrVbRhmKdAphIm{height:740px;max-width:1360px;position:relative;width:95%}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN{display:block;position:absolute;right:64px;top:64px;z-index:99}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN clipPath,.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN path{fill:#000}.gfM_DIJrVbRhmKdAphIm .zfJfONxRAw0fHjXUS7LN path.FCnyb_xCK7DhJ63p6TEd{fill:#fff}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh{height:740px;transition-delay:0}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN clipPath,.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN path{transition:fill 2s ease .5s;fill:#fff}.gfM_DIJrVbRhmKdAphIm.pnwbCuWbV0PNQr1LFpRh .zfJfONxRAw0fHjXUS7LN path.FCnyb_xCK7DhJ63p6TEd{transition:fill 2s ease .5s;fill:#000}}@keyframes OmAVpCQ270MqI4IsT9Ky{20%{transform:translateY(0) scale(1)}65%{transform:translateY(16%) scale(1.4)}to{transform:translateY(0) scale(1)}}.Qn5xayjI_jH2m1d6BEoq{border-radius:var(--jp-button-radius);display:flex;height:50%;justify-content:center;min-height:400px;overflow:hidden;position:relative;transition:height .55s cubic-bezier(.59,.37,.18,1) 0s;will-change:height}.pnwbCuWbV0PNQr1LFpRh .Qn5xayjI_jH2m1d6BEoq{height:100%;transition-delay:.65s}.pnwbCuWbV0PNQr1LFpRh .Qn5xayjI_jH2m1d6BEoq video{animation:OmAVpCQ270MqI4IsT9Ky 1.5s ease-in-out forwards}.Qn5xayjI_jH2m1d6BEoq video{height:100%;object-fit:cover;position:absolute;right:0;top:0;transform:scale(1);transition:all .85s cubic-bezier(1,0,.39,1) 0s;width:100%;will-change:transform}@media(min-width:760px){@keyframes Axe8f2LgqEBZHVcsRgY5{0%{animation-timing-function:cubic-bezier(.86,0,.07,1);right:60%;top:32px}50%{animation-timing-function:cubic-bezier(.17,.84,.44,1);bottom:32px;right:32px;top:32px;width:100%}to{right:32px;width:40%}}.Qn5xayjI_jH2m1d6BEoq{border-radius:12px;bottom:32px;display:block;height:auto;left:32px;overflow:hidden;position:absolute;right:60%;top:32px;transition-delay:0;transition:width .55s ease 0s;z-index:3}.Qn5xayjI_jH2m1d6BEoq video{height:100%;object-fit:cover;position:absolute;right:0;top:0;width:100%}.pnwbCuWbV0PNQr1LFpRh .Qn5xayjI_jH2m1d6BEoq{animation-delay:.25s;animation-duration:2s;animation-fill-mode:forwards;animation-name:Axe8f2LgqEBZHVcsRgY5;height:auto}}.iBMDoShSmqpt72YfJb36{padding:var(--jp-modal-padding)}.iBMDoShSmqpt72YfJb36 h2{font-size:clamp(1.5rem,-.7353rem + 4.7059vw,3.5rem)}.iBMDoShSmqpt72YfJb36 p{font-size:clamp(1rem,.6974rem + 1.1696vw,1.75rem)}.iBMDoShSmqpt72YfJb36 p.eQG1KKK8jjKtQyzfv573{display:none;font-size:clamp(1.25rem,1.1491rem + .3899vw,1.5rem)}@media(min-width:760px){.iBMDoShSmqpt72YfJb36{bottom:15%;display:flex;flex-direction:column;gap:64px;padding:0 0 0 var(--jp-modal-padding);position:absolute;right:64px;width:55%}.iBMDoShSmqpt72YfJb36 .l35bIyiqYJiZ6tVYvJtC{align-items:flex-start;display:flex;flex-direction:column;gap:16px;padding:0 0 0 32px}.iBMDoShSmqpt72YfJb36 .l35bIyiqYJiZ6tVYvJtC h2,.iBMDoShSmqpt72YfJb36 .l35bIyiqYJiZ6tVYvJtC p{margin:0}.iBMDoShSmqpt72YfJb36 p.eQG1KKK8jjKtQyzfv573{display:block}.iBMDoShSmqpt72YfJb36 ._j4GWTmW5psCHFYh6R0x{align-self:flex-start;padding:16px var(--jp-modal-padding-large)!important;width:auto}.pnwbCuWbV0PNQr1LFpRh .iBMDoShSmqpt72YfJb36{opacity:0;right:-20px;transition:all .55s cubic-bezier(.59,.37,.18,1) .3s}}.HQVDZ6J3x6SJNYFX5khS{background:var(--jp-white);opacity:0;position:absolute;right:0;top:100%;transition:transform .45s cubic-bezier(.59,.37,.18,1) 2s,opacity .45s linear;width:100%;will-change:transform,opacity;z-index:2}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS{opacity:1;transform:translateY(-100%);transition-delay:2s}@media(min-width:760px){.HQVDZ6J3x6SJNYFX5khS{align-items:flex-end;bottom:5%;container-type:inline-size;display:flex;flex-direction:column;gap:40px;left:32px;padding:0;right:45%;transform:translateY(0);transition-delay:0;transition:none;width:auto}.HQVDZ6J3x6SJNYFX5khS h2{width:100%}.HQVDZ6J3x6SJNYFX5khS ._j4GWTmW5psCHFYh6R0x{margin-left:var(--jp-modal-padding-large)}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS{bottom:12%;left:32px;opacity:1;right:45%;top:unset;transform:translateY(0);transition:all .45s cubic-bezier(.59,.37,.18,1) 2s,opacity .45s linear;transition-delay:2s;width:auto}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS .l35bIyiqYJiZ6tVYvJtC{padding-right:32px}.pnwbCuWbV0PNQr1LFpRh .HQVDZ6J3x6SJNYFX5khS ._j4GWTmW5psCHFYh6R0x{align-self:flex-end}}.KdvmPIjelQIFiPQGuIYf{background:var(--jp-gray-0);display:flex;flex-direction:column;gap:var(--jp-gap)}.KdvmPIjelQIFiPQGuIYf div{background-color:var(--jp-white);border:1px solid var(--jp-gray-10);border-radius:var(--jp-button-radius);box-shadow:0 0 40px 0 rgba(0,0,0,.08);flex:1;padding:var(--jp-modal-padding)}.KdvmPIjelQIFiPQGuIYf h3{font-size:24px;line-height:normal;margin:0}.KdvmPIjelQIFiPQGuIYf p{font-size:14px}@media(min-width:760px){.KdvmPIjelQIFiPQGuIYf{flex-direction:row;padding:var(--jp-modal-padding-large)}.KdvmPIjelQIFiPQGuIYf div{border:none;box-shadow:0 2px 16px rgba(0,0,0,.08),0 2px 2px rgba(0,0,0,.1)}.KdvmPIjelQIFiPQGuIYf div p{margin:8px 0}.KdvmPIjelQIFiPQGuIYf svg{margin-bottom:var(--jp-modal-padding-small)}}@container (max-width: 600px){.KdvmPIjelQIFiPQGuIYf div{padding:var(--jp-modal-padding-small)}}.cuoSlhSNrqf1dozY22Xb{fill:#000}.JLquNpQVlysAamuh5lJO,.lAIiifeLMmZAPlQ9n9ZR{fill:var(--jp-green-primary)}.cbOwD8Y4tFjwimmtchQI{fill:#757575}.cbOwD8Y4tFjwimmtchQI.aLWBKY0yRghEk7tNCgK3{fill:var(--color-bluesky)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw{fill:var(--color-facebook)}.cbOwD8Y4tFjwimmtchQI.aHOlEBGD5EA8NKRw3xTw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.af4Y_zItXvLAOEoSDPSv{fill:var(--color-twitter)}.cbOwD8Y4tFjwimmtchQI.f68aqF3XSD1OBvXR1get{fill:var(--color-linkedin)}.cbOwD8Y4tFjwimmtchQI.xFI0dt3UiXRlRQdqPWkx{fill:var(--color-tumblr)}.cbOwD8Y4tFjwimmtchQI.q7JEoyymveP6kF747M43{fill:var(--color-gplus)}.cbOwD8Y4tFjwimmtchQI.DKOBOTVmTLbh26gUH_73{fill:var(--color-mastodon)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw{fill:var(--color-nextdoor)}.cbOwD8Y4tFjwimmtchQI.n5XodNsuMfMAAvqHFmbw.social-logo{border-radius:50%}.cbOwD8Y4tFjwimmtchQI.cL3m0xBYTYhIKI7lCqDB{fill:var(--color-instagram)}.cbOwD8Y4tFjwimmtchQI.fftumuc_lJ6v0tq4UMVR{fill:var(--color-whatsapp)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI{fill:var(--color-threads)}.cbOwD8Y4tFjwimmtchQI.inzgC27qxdt7hSdhTWRI.social-logo{border-radius:40%}.SqdhUZkXCRuIpErj1B3z{--max-container-width:1128px;--vertical-gutter:24px;--horizontal-spacing:8px;column-gap:var(--vertical-gutter);display:grid;margin:0 auto;max-width:var(--max-container-width);width:100%}@media(max-width:599px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(4,minmax(0,1fr));padding:0 16px}}@media(min-width:600px)and (max-width:959px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(8,minmax(0,1fr));padding:0 18px}}@media(min-width:960px){.SqdhUZkXCRuIpErj1B3z{grid-template-columns:repeat(12,minmax(0,1fr));padding:0 24px}}.SqdhUZkXCRuIpErj1B3z.OZC_9a1LhpWF9dv15Gdh{max-width:none;padding:unset}@media(max-width:599px){.RuVLl3q4lxTQa3wbhBJB{grid-column-end:span 1}.f9LZTRG4MMK42rS89afW{grid-column-start:1}.bHe_zKxjjpUwHw_MdYE1{grid-column-end:2}.QZbNrOqE2aNSn50xVhpU{grid-column-end:span 2}.ev7W3z7zVYPeHAlYqZjf{grid-column-start:2}.NJWd1m_e7lOiPYru2ZMP{grid-column-end:3}.Xc6nt1Qc1DI0Z2A3gt1r{grid-column-end:span 3}.UIcN_GXiPRoIsin8Kohg{grid-column-start:3}.GRKCyqb5LufCSCgykKFc{grid-column-end:4}.i_qTq8gqhhC3vIUepVRB{grid-column-end:span 4}.G3qaZ3Jpbvam_1XvGxgc{grid-column-start:4}.VRCNYKZtO9zukEwmgP1y{grid-column-end:5}}@media(min-width:600px)and (max-width:959px){.tRm008K_WJL79WoNZTNL{grid-column-end:span 1}.l5T2P_bgKts4tdaRkS1d{grid-column-start:1}.zOCxfLZpF6BlgC7a_Yq1{grid-column-end:2}.F80DdgVn0m5OpvtSQWka{grid-column-end:span 2}.oI1c7JYfiJtMQHbhngtU{grid-column-start:2}.pMQtA_4jh1_1lVknqEP5{grid-column-end:3}.VenqMpdgyKQVUNNQcfqd{grid-column-end:span 3}.seNYL99uoczf9V4MxBxT{grid-column-start:3}.YKfF1HFhI9KygA5l3b2J{grid-column-end:4}.yAi0Cv1xDWkoqsaUhvhR{grid-column-end:span 4}.ubhnyZOnkgxNhh6XtVWv{grid-column-start:4}.RGOPGQbWMJ9Ei5oFxS7X{grid-column-end:5}.Sz1E2aWbX483ijdi6yge{grid-column-end:span 5}.tku6_bRYrX9tMbgYGmIl{grid-column-start:5}.b5JHttOhSEcI1WBlqAjk{grid-column-end:6}.FboSx5MoKTAWbxXyYlCw{grid-column-end:span 6}.Jhs8yEEmodG30edbJvag{grid-column-start:6}.IpzbbKVqEqPcfIGkXkwt{grid-column-end:7}.mhCPwfAZ4Kmm_empzJAq{grid-column-end:span 7}.x034ilrJF7rO9UJB2rI1{grid-column-start:7}.Wt8t2e16viRrOJ1lLA5v{grid-column-end:8}.S6pIrEy9AMLKx9bgh_Ae{grid-column-end:span 8}.kEfI4tGyuWfHTlRnvIab{grid-column-start:8}.PUzX4RRsKq1dnsz3gebS{grid-column-end:9}}@media(min-width:960px){.X_pdcLJikd8LS_YAdJlB{grid-column-end:span 1}.tl936d14Huby4khYp05X{grid-column-start:1}.hnge0LnR69d3NXEtEE1t{grid-column-end:2}.fj0NUMuyZQcPNgKcjp5Z{grid-column-end:span 2}.R2ncBX7a2NigdYCcV1OX{grid-column-start:2}.t8vMSDVYno9k9itRwnXb{grid-column-end:3}.wsDuEN2GqHx6qzo8dUdk{grid-column-end:span 3}.cIEVPUweWtLBy3xaXnMx{grid-column-start:3}.fajUWBwu1m2B479j3jmz{grid-column-end:4}.YR0c7fQTgMkDdWzwSyLp{grid-column-end:span 4}.xlwp8BmplxkKNMI7gamo{grid-column-start:4}._C4O1w9DUqx1m3gPf8aA{grid-column-end:5}.Z54F1hAErckAIrKlxnXW{grid-column-end:span 5}.ezSDWkRHmKSxDJXxuiOH{grid-column-start:5}.T0ChoeAjGJjkkNrYhD4g{grid-column-end:6}.qtMoMPF6yHvGJnWHSsde{grid-column-end:span 6}.gdoywN5VPiWERfIBqkph{grid-column-start:6}.wUev_VH5uf_pwFFlbnAU{grid-column-end:7}.egIPDFJsOpownTClq9XP{grid-column-end:span 7}.yGhp9yoAW7k0kQik9AB7{grid-column-start:7}.SJ43U9mR5wUg5V2qBeQA{grid-column-end:8}.cTuyHfMwSUJxN_HdIEgd{grid-column-end:span 8}.smCr8DaIagcumdvdldiK{grid-column-start:8}.T03NHzQJvzwL6wAfIiTL{grid-column-end:9}.pMvxM3RJGjqyNdf9qg1Y{grid-column-end:span 9}.iIVpNRwEnQ_JI5gpp9EN{grid-column-start:9}.ZbQ4u4vGSX5rJOje4uGL{grid-column-end:10}.gKb5wuIDAlKGbrjK2vxy{grid-column-end:span 10}.Z7pINdImE2WJiYnZBTqm{grid-column-start:10}.ZTxp6qpvwurMdOnLLSz1{grid-column-end:11}.NnQTlbfnxPDR6cQ7rygg{grid-column-end:span 11}.O137wZd6Yl0olSA9PsXR{grid-column-start:11}.zf2OJtQ2MPz6SDoh6CB0{grid-column-end:12}.U3H6UHW6HqRt9hdzVg3O{grid-column-end:span 12}.zynnNeS_ZBTxABcVpUQH{grid-column-start:12}.vI8tltFZtFUNAy9Iag9s{grid-column-end:13}}.zI5tJ_qhWE6Oe6Lk75GY{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);--wp-admin-border-width-focus:1.51px;border-radius:var(--jp-border-radius);font-weight:600;justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo{height:calc(var(--spacing-base)*5);padding:var(--spacing-base);width:calc(var(--spacing-base)*5)}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo>svg:first-child{margin:0;padding:0}.zI5tJ_qhWE6Oe6Lk75GY.tuBt2DLqimiImoqVzPqo.Na39I683LAaSA99REg14{height:calc(var(--spacing-base)*4);min-width:calc(var(--spacing-base)*4);padding:calc(var(--spacing-base)/2);width:calc(var(--spacing-base)*4)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body);height:auto;line-height:24px;padding:var(--spacing-base) calc(var(--spacing-base)*3)}.zI5tJ_qhWE6Oe6Lk75GY.ipS7tKy9GntCS4R3vekF:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK{padding:var(--spacing-base) calc(var(--spacing-base)*2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo){font-size:var(--font-body-extra-small);height:auto;line-height:20px;padding:calc(var(--spacing-base)/2) var(--spacing-base)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo).paGLQwtPEaJmtArCcmyK>svg:first-child{margin-left:calc(var(--spacing-base)/2)}.zI5tJ_qhWE6Oe6Lk75GY.Na39I683LAaSA99REg14:not(.tuBt2DLqimiImoqVzPqo)>.components-spinner{height:20px}.zI5tJ_qhWE6Oe6Lk75GY.lZAo6_oGfclXOO9CC6Rd{font-weight:400}.zI5tJ_qhWE6Oe6Lk75GY.xJDOiJxTt0R_wSl8Ipz_{min-width:100%}.zI5tJ_qhWE6Oe6Lk75GY.is-primary:disabled,.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:disabled{background:var(--jp-gray);color:var(--jp-gray-20)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary{background:var(--jp-white);box-shadow:inset 0 0 0 1.51px var(--jp-black)}.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:active:not(:disabled),.zI5tJ_qhWE6Oe6Lk75GY.is-secondary:hover:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-link.Na39I683LAaSA99REg14,.zI5tJ_qhWE6Oe6Lk75GY.is-link.ipS7tKy9GntCS4R3vekF{padding:0}.zI5tJ_qhWE6Oe6Lk75GY.is-link:hover:not(:disabled){text-decoration-thickness:3px}.zI5tJ_qhWE6Oe6Lk75GY.is-link:focus:not(:disabled){text-decoration-line:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:not(:disabled){background:var(--jp-red-50);box-shadow:inset 0 0 0 1px var(--jp-red-50);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:hover:not(:disabled){background:var(--jp-red-60);box-shadow:inset 0 0 0 1px var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:focus:not(:disabled){background:var(--jp-red-70);box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-white)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-primary:active:not(:disabled){background:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary{box-shadow:none}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:not(:disabled){background:var(--jp-white);box-shadow:inset 0 0 0 1.5px var(--jp-red-50);color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:hover:not(:disabled){background:var(--jp-red-0);box-shadow:inset 0 0 0 1.5px var(--jp-red-60);color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-secondary:active:not(:disabled){background:var(--jp-gray-0)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:not(:disabled){color:var(--jp-red-50)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:hover:not(:disabled){box-shadow:none;color:var(--jp-red-60)}.zI5tJ_qhWE6Oe6Lk75GY.is-destructive.is-link:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--jp-white),0 0 0 var(--wp-admin-border-width-focus) var(--jp-red-70);color:var(--jp-red-70)}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6{position:relative}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6.has-icon{justify-content:center}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>:not(.components-spinner){visibility:hidden}.zI5tJ_qhWE6Oe6Lk75GY.q_tVWqMjl39RcY6WtQA6>.components-spinner{margin:0;position:absolute}.CDuBjJp_8jxzx5j6Nept{margin-right:calc(var(--spacing-base)/2)}.jp-license-activation-screen{border-radius:4px;box-shadow:0 4px 24px 0 rgba(0,0,0,.149);display:flex;flex-direction:column;min-height:540px;overflow:hidden}@media screen and (min-width:780px){.jp-license-activation-screen{flex-direction:row}}.block-editor-block-list__layout .block-editor-block-list__block.has-warning.is-interactive>*{pointer-events:auto;user-select:auto}.block-editor-block-list__layout .block-editor-block-list__block.has-warning.is-interactive:after{content:none}.hdasSNj9k3Sc5PwXK4uE{margin-left:4px;width:16px}.eWN8Hj0SBRDq1F48n_Fg{--gray-70:#3c434a;align-items:center;color:var(--gray-70);display:flex;font-size:14px;text-decoration:none}.jp-dashboard-footer{align-items:center;color:var(--jp-black);display:flex;flex-wrap:wrap;font-size:var(--font-body-extra-small);line-height:1.333;max-width:1128px;width:100%}.jp-dashboard-footer a{text-decoration:none}.jp-dashboard-footer a:any-link,.jp-dashboard-footer a[role=button]{color:inherit}.jp-dashboard-footer a:hover{text-decoration:underline;text-decoration-thickness:1.5px}.jp-dashboard-footer a:focus{box-shadow:none;outline-width:0}.jp-dashboard-footer a:focus-visible{border-radius:2px;box-shadow:none;outline:1.5px solid currentColor;outline-offset:3px}.jp-dashboard-footer.is-sm>ul{gap:.125rem}.jp-dashboard-footer.is-md,.jp-dashboard-footer.is-sm>ul{align-items:flex-start;flex-direction:column}.jp-dashboard-footer>ul{align-items:center;display:flex;flex-wrap:wrap;gap:1rem;list-style:none;margin:0;padding:0;width:100%}.jp-dashboard-footer>ul>li{margin-bottom:0}.jp-dashboard-footer>ul>li>a{align-items:center;display:flex;gap:.25rem;min-height:44px}.jp-dashboard-footer__accessible-external-link{border:0;clip:rect(1px,1px,1px,1px);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;overflow-wrap:normal;padding:0;position:absolute;width:1px}.jp-dashboard-footer__jp-item{font-weight:600;padding-inline-end:1rem}.jp-dashboard-footer.is-sm .jp-dashboard-footer__jp-item{padding-bottom:1rem}.jp-dashboard-footer.is-lg .jp-dashboard-footer__a8c-item{margin-inline-start:auto}.jp-dashboard-footer.is-sm .jp-dashboard-footer__a8c-item{padding-top:1rem}.jp-dashboard-footer__a8c-item>a,.jp-dashboard-footer__jp-item>a{text-decoration:none}.sexr0jUxC1jVixdKiDnC{margin-right:-20px}@media(max-width:782px){.sexr0jUxC1jVixdKiDnC{margin-right:-10px}}.sexr0jUxC1jVixdKiDnC.vKQ11sLeAM45M04P1ccj{background-color:var(--jp-white)}.sexr0jUxC1jVixdKiDnC .iWGAhN9gOB48g0jEO1OQ{align-items:center;display:flex;gap:8px}.sexr0jUxC1jVixdKiDnC .JOYmuxQjG4FArIIUxJfA{background:#d63638;color:#fff;cursor:pointer;font-size:9px;font-weight:700;letter-spacing:.2em;text-shadow:none;text-transform:uppercase}.rV_5QyvhDnsVjCX4pb0h{--gray-90:#1e1e1e;fill:var(--gray-90);width:24px}.MO1jDNY8VPqeNS9xL8jE{align-items:center;display:flex;text-decoration:none}.zvd4dCB_bBDiXJKKDqXm{position:relative}.ly4o9lSswAGHFXqGUEIO{left:32px;position:absolute;top:32px;z-index:1}.u64Go3kwEZ7MD9eji0H1{color:var(--jp-gray-50);font-size:13px;margin-bottom:8px;width:60%}._RT41NE3LU4R0ubcij2y{align-items:center;display:flex;gap:8px}._RT41NE3LU4R0ubcij2y li{background:none!important;margin:0!important;padding:0!important}.cFGWJeRiGHjAr8D7CWJW{max-width:110px}.Iz3l7a05TP6HK9S92TIL{width:16px}.lmQ0wFmnk4kKkGVjokPA{height:18px}.ZSFTmY3zE3VP4w0QeaqV{width:16px}.AoIs8wD92wKR8RpQj6Uc{align-items:center;display:inline-flex}.WQVtrU6q0L1Igcj7wCrQ{margin:0;padding:0}.UujoBFTnQNY2cWU2SIsH{font-size:var(--font-headline-medium);font-weight:700;line-height:52px}.TeGO5V_thHw5lDAm1_2M{font-weight:700}.TeGO5V_thHw5lDAm1_2M,.WolQzb2MsSgiNmLtc7_j{font-size:var(--font-headline-small);line-height:40px}.WolQzb2MsSgiNmLtc7_j{font-weight:400}.hUB0JT8p1T2Hw28N6qC8{font-weight:500}.gKZWDv5chz3_O3Syp74H,.hUB0JT8p1T2Hw28N6qC8{font-size:var(--font-title-medium);line-height:32px}.gKZWDv5chz3_O3Syp74H{font-weight:600}.zY2No8Ga4b8shbOQGhnv{font-size:var(--font-title-small);font-weight:500;line-height:30px}.tIj0D1t8Cc892ikmgFPZ{font-size:var(--font-body);font-weight:400;line-height:24px}.KdcN0BnOaVeVhyLRKqhS{font-size:var(--font-body-small);font-weight:400;line-height:24px}.dso3Rh3tl3Xv1GumBktz{font-weight:400}.dso3Rh3tl3Xv1GumBktz,.mQ1UlbN9u4Mg9byO8m7v{font-size:var(--font-body-extra-small);line-height:20px}.mQ1UlbN9u4Mg9byO8m7v{font-weight:700}.PItlW5vRExLnTj4a8eLE{font-size:var(--font-body-extra-small);font-weight:600;line-height:16px}.TwRpPlktzxhmFVeua7P5{margin:calc(var( --spacing-base )*0)}.zVfqx7gyb3o9mxfGynn1{margin-left:calc(var( --spacing-base )*0);margin-right:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy{margin-bottom:calc(var( --spacing-base )*0)}.iSHVzNiB9iVleGljaQxy,.xqDIp6cNVr_E6RXaiPyD{margin-top:calc(var( --spacing-base )*0)}.S8EwaXk1kyPizt6x4WH2{margin-left:calc(var( --spacing-base )*0)}.ODX5Vr1TARoLFkDDFooD{margin-bottom:calc(var( --spacing-base )*0)}.cphJ8dCpfimnky7P2FHg{margin-right:calc(var( --spacing-base )*0)}.PFgIhNxIyiSuNvQjAIYj{margin:calc(var( --spacing-base )*1)}.M2jKmUzDxvJjjVEPU3zn{margin-left:calc(var( --spacing-base )*1);margin-right:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk{margin-bottom:calc(var( --spacing-base )*1)}.io15gAh8tMTNbSEfwJKk,.rcTN5uw9xIEeMEGL3Xi_{margin-top:calc(var( --spacing-base )*1)}.CQSkybjq2TcRM1Xo9COV{margin-left:calc(var( --spacing-base )*1)}.hfqOWgq6_MEGdFE82eOY{margin-bottom:calc(var( --spacing-base )*1)}.I8MxZQYTbuu595yfesWA{margin-right:calc(var( --spacing-base )*1)}.kQkc6rmdpvLKPkyoJtVQ{margin:calc(var( --spacing-base )*2)}.j6vFPxWuu4Jan2ldoxpp{margin-left:calc(var( --spacing-base )*2);margin-right:calc(var( --spacing-base )*2)}.hqr39dC4H_AbactPAkCG{margin-bottom:calc(var( --spacing-base )*2)}.c3dQnMi16C6J6Ecy4283,.hqr39dC4H_AbactPAkCG{margin-top:calc(var( --spacing-base )*2)}.YNZmHOuRo6hU7zzKfPdP{margin-left:calc(var( --spacing-base )*2)}.Db8lbak1_wunpPk8NwKU{margin-bottom:calc(var( --spacing-base )*2)}.ftsYE5J9hLzquQ0tA5dY{margin-right:calc(var( --spacing-base )*2)}.Det4MHzLUW7EeDnafPzq{margin:calc(var( --spacing-base )*3)}.h_8EEAztC29Vve1datb5{margin-left:calc(var( --spacing-base )*3);margin-right:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM{margin-bottom:calc(var( --spacing-base )*3)}.YXIXJ0h1k47u6hzK8KcM,.soADBBkcIKCBXzCTuV9_{margin-top:calc(var( --spacing-base )*3)}.zSX59ziEaEWGjnpZa4uV{margin-left:calc(var( --spacing-base )*3)}.yrVTnq_WBMbejg89c2ZQ{margin-bottom:calc(var( --spacing-base )*3)}.UKtHPJnI2cXBWtPDm5hM{margin-right:calc(var( --spacing-base )*3)}.guexok_Tqd5Tf52hRlbT{margin:calc(var( --spacing-base )*4)}.oS1E2KfTBZkJ3F0tN7T6{margin-left:calc(var( --spacing-base )*4);margin-right:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd{margin-bottom:calc(var( --spacing-base )*4)}.DN1OhhXi6AoBgEdDSbGd,.ot2kkMcYHv53hLZ4LSn0{margin-top:calc(var( --spacing-base )*4)}.A1krOZZhlQ6Sp8Cy4bly{margin-left:calc(var( --spacing-base )*4)}.pkDbXXXL32237M0hokEh{margin-bottom:calc(var( --spacing-base )*4)}.XXv4kDTGvEnQeuGKOPU3{margin-right:calc(var( --spacing-base )*4)}.yGqHk1a57gaISwkXwXe6{margin:calc(var( --spacing-base )*5)}.X8cghM358X3DkXLc9aNK{margin-left:calc(var( --spacing-base )*5);margin-right:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f{margin-bottom:calc(var( --spacing-base )*5)}.GdfSmGwHlFnN2S6xBn1f,.yqeuzwyGQ7zG0avrGqi_{margin-top:calc(var( --spacing-base )*5)}.g9emeCkuHvYhveiJbfXO{margin-left:calc(var( --spacing-base )*5)}.Lvk3dqcyHbZ07QCRlrUQ{margin-bottom:calc(var( --spacing-base )*5)}.r3yQECDQ9qX0XZzXlVAg{margin-right:calc(var( --spacing-base )*5)}.aQhlPwht2Cz1X_63Miw0{margin:calc(var( --spacing-base )*6)}.JyHb0vK3wJgpblL9s5j8{margin-left:calc(var( --spacing-base )*6);margin-right:calc(var( --spacing-base )*6)}.cY2gULL1lAv6WPNIRuf3{margin-bottom:calc(var( --spacing-base )*6)}.NBWQ9Lwhh_fnry3lg_p7,.cY2gULL1lAv6WPNIRuf3{margin-top:calc(var( --spacing-base )*6)}.yIOniNe5E40C8fWvBm5V{margin-left:calc(var( --spacing-base )*6)}.t30usboNSyqfQWIwHvT3{margin-bottom:calc(var( --spacing-base )*6)}.Nm_TyFkYCMhOoghoToKJ{margin-right:calc(var( --spacing-base )*6)}.C4qJKoBXpgKtpmrqtEKB{margin:calc(var( --spacing-base )*7)}.S93Srbu6NQ_PBr7DmTiD{margin-left:calc(var( --spacing-base )*7);margin-right:calc(var( --spacing-base )*7)}.fJj8k6gGJDks3crUZxOS{margin-bottom:calc(var( --spacing-base )*7)}.cW6D6djs7Ppm7fD7TeoV,.fJj8k6gGJDks3crUZxOS{margin-top:calc(var( --spacing-base )*7)}.DuCnqNfcxcP3Z__Yo5Ro{margin-left:calc(var( --spacing-base )*7)}.im8407m2fw5vOg7O2zsw{margin-bottom:calc(var( --spacing-base )*7)}.G0fbeBgvz2sh3uTP9gNl{margin-right:calc(var( --spacing-base )*7)}.kvW3sBCxRxUqz1jrVMJl{margin:calc(var( --spacing-base )*8)}.tOjEqjLONQdkiYx_XRnw{margin-left:calc(var( --spacing-base )*8);margin-right:calc(var( --spacing-base )*8)}.op5hFSx318zgxsoZZNLN{margin-bottom:calc(var( --spacing-base )*8)}.c9WfNHP6TFKWIfLxv52J,.op5hFSx318zgxsoZZNLN{margin-top:calc(var( --spacing-base )*8)}.sBA75QqcqRwwYSHJh2wc{margin-left:calc(var( --spacing-base )*8)}.GpL6idrXmSOM6jB8Ohsf{margin-bottom:calc(var( --spacing-base )*8)}.HbtWJoQwpgGycz8dGzeT{margin-right:calc(var( --spacing-base )*8)}.uxX3khU88VQ_Ah49Ejsa{padding:calc(var( --spacing-base )*0)}.KX0FhpBKwKzs9fOUdbNz{padding-left:calc(var( --spacing-base )*0);padding-right:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz{padding-bottom:calc(var( --spacing-base )*0)}.PfK8vKDyN32dnimlzYjz,.emxLHRjQuJsImnPbQIzE{padding-top:calc(var( --spacing-base )*0)}.kJ8WzlpTVgdViXt8ukP9{padding-left:calc(var( --spacing-base )*0)}.tg_UIUI11VBzrTAn2AzJ{padding-bottom:calc(var( --spacing-base )*0)}.uczvl8kaz84oPQJ2DB2R{padding-right:calc(var( --spacing-base )*0)}.o7UHPcdVK3lt7q3lqV4o{padding:calc(var( --spacing-base )*1)}.IDqEOxvDoYrFYxELPmtX{padding-left:calc(var( --spacing-base )*1);padding-right:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2{padding-bottom:calc(var( --spacing-base )*1)}.DdywPW2qSYlu2pt8tpO2,.npy3hw4A5QSkDicb2CJJ{padding-top:calc(var( --spacing-base )*1)}.LgbptTApNY5NwLQvEFAt{padding-left:calc(var( --spacing-base )*1)}.WZQy2SZuZso59bUsXXyl{padding-bottom:calc(var( --spacing-base )*1)}.o331apInxNunbYB3SfPE{padding-right:calc(var( --spacing-base )*1)}.fMPIyD9Vqki1Lrc_yJnG{padding:calc(var( --spacing-base )*2)}.i2pMcTcdrr10IQoiSm_L{padding-left:calc(var( --spacing-base )*2);padding-right:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH{padding-bottom:calc(var( --spacing-base )*2)}.eA702gn32kwptiI1obXH,.o9bGieUKcYc8o0Ij9oZX{padding-top:calc(var( --spacing-base )*2)}.SwZcFez1RDqWsOFjB5iG{padding-left:calc(var( --spacing-base )*2)}.eHpLc_idmuEqeqCTvqkN{padding-bottom:calc(var( --spacing-base )*2)}.vU39i2B4P1fUTMB2l6Vo{padding-right:calc(var( --spacing-base )*2)}.JHWNzBnE29awhdu5BEh1{padding:calc(var( --spacing-base )*3)}.X72lGbb56L3KFzC2xQ9N{padding-left:calc(var( --spacing-base )*3);padding-right:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e{padding-bottom:calc(var( --spacing-base )*3)}.BzfNhRG8wXdCEB5ocQ6e,.srV0KSDC83a2fiimSMMQ{padding-top:calc(var( --spacing-base )*3)}.lUWfkmbQjCskhcNwkyCm{padding-left:calc(var( --spacing-base )*3)}.Ts0dIlc3aTSL7V4cIHis{padding-bottom:calc(var( --spacing-base )*3)}.CzlqQXXhX6MvorArFZ8B{padding-right:calc(var( --spacing-base )*3)}.TqMPkQtR_DdZuKb5vBoV{padding:calc(var( --spacing-base )*4)}.a7UrjhI69Vetlcj9ZVzz{padding-left:calc(var( --spacing-base )*4);padding-right:calc(var( --spacing-base )*4)}.StEhBzGs2Gi5dDEkjhAv{padding-bottom:calc(var( --spacing-base )*4)}.FGneZfZyvYrt1dG0zcnm,.StEhBzGs2Gi5dDEkjhAv{padding-top:calc(var( --spacing-base )*4)}.APEH216rpdlJWgD2fHc8{padding-left:calc(var( --spacing-base )*4)}.oGwXC3ohCic9XnAj6x69{padding-bottom:calc(var( --spacing-base )*4)}.U6gnT9y42ViPNOcNzBwb{padding-right:calc(var( --spacing-base )*4)}.IpdRLBwnHqbqFrixgbYC{padding:calc(var( --spacing-base )*5)}.HgNeXvkBa9o3bQ5fvFZm{padding-left:calc(var( --spacing-base )*5);padding-right:calc(var( --spacing-base )*5)}.tJtFZM3XfPG9v9TSDfN1{padding-bottom:calc(var( --spacing-base )*5)}.PdifHW45QeXYfK568uD8,.tJtFZM3XfPG9v9TSDfN1{padding-top:calc(var( --spacing-base )*5)}.mbLkWTTZ0Za_BBbFZ5b2{padding-left:calc(var( --spacing-base )*5)}.vVWpZpLlWrkTt0hMk8XU{padding-bottom:calc(var( --spacing-base )*5)}.RxfaJj5a1Nt6IavEo5Zl{padding-right:calc(var( --spacing-base )*5)}.SppJULDGdnOGcjZNCYBy{padding:calc(var( --spacing-base )*6)}.palY2nLwdoyooPUm9Hhk{padding-left:calc(var( --spacing-base )*6);padding-right:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_{padding-bottom:calc(var( --spacing-base )*6)}.WYw1JvZC0ppLdvSAPhr_,.YEEJ9b90ueQaPfiU8aeN{padding-top:calc(var( --spacing-base )*6)}.QE0ssnsKvWJMqlhPbY5u{padding-left:calc(var( --spacing-base )*6)}.n8yA3jHlMRyLd5UIfoND{padding-bottom:calc(var( --spacing-base )*6)}.tXHmxYnHzbwtfxEaG51n{padding-right:calc(var( --spacing-base )*6)}.kBTsPKkO_3g_tLkj77Um{padding:calc(var( --spacing-base )*7)}.RyhrFx6Y1FGDrGAAyaxm{padding-left:calc(var( --spacing-base )*7);padding-right:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO{padding-bottom:calc(var( --spacing-base )*7)}.CBwRpB0bDN3iEdQPPMJO,.vQVSq6SvWKbOMu6r4H6b{padding-top:calc(var( --spacing-base )*7)}.oBy5__aEADMsH46mrgFX{padding-left:calc(var( --spacing-base )*7)}.KVEXoJqf1s92j0JMdNmN{padding-bottom:calc(var( --spacing-base )*7)}.ZMXGNrNaKW3k_3TLz0Fq{padding-right:calc(var( --spacing-base )*7)}.tuiR9PhkHXhGyEgzRZRI{padding:calc(var( --spacing-base )*8)}.U7454qyWkQNa2iaSJziu{padding-left:calc(var( --spacing-base )*8);padding-right:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8{padding-bottom:calc(var( --spacing-base )*8)}.VLYIv2GVocjuN93e8HC8,.X1rm9DQ1zLGLfogja5Gn{padding-top:calc(var( --spacing-base )*8)}.JS7G6kAuqJo5GIuF8S5t{padding-left:calc(var( --spacing-base )*8)}.Y8F9ga1TDCMbM1lj4gUz{padding-bottom:calc(var( --spacing-base )*8)}.AJuyNGrI63BOWql719H8{padding-right:calc(var( --spacing-base )*8)}.terms-of-service{color:var(--jp-black);font-size:var(--font-body)}.terms-of-service .terms-of-service__link{color:var(--jp-green-50);text-decoration:underline;white-space:nowrap}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe{align-items:center;display:flex;gap:var(--spacing-base);margin-bottom:calc(var(--spacing-base)*3)}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .VmtuLc2xRqmsO6cK8qjF{position:relative;width:54px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .MdTRfQ3eo5qZKChZlzNj,.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .PbEpL02SEH9VNAlbKCfV{width:32px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .TD4AUM9gcTVAB6JHB5ZR{border-radius:50%;margin-right:-10px;position:absolute;width:32px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .yjl73qv0VWoPP8IhGreh{border-top-style:solid;border-top:2px dashed var(--jp-black);height:0;width:67px}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .J0GIu2rNR7rXocQTyd8p{border-color:var(--jp-red)}.kezuOHNvu9vdvlJ86Fwg .qJizORs2q_CVCj9L6XLe .rAV2E93SG8WpokuGk9jh{border-color:var(--jp-yellow-50)}.kezuOHNvu9vdvlJ86Fwg .YZ7FNKEm9qpvQ4ZkbAz5{transform:rotate(-180deg)}.kezuOHNvu9vdvlJ86Fwg .TYNMsILey2vUwnyZSjJU{align-self:flex-end;margin-bottom:2px}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz{margin-bottom:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .oH9tzGE80LnB6Og69RFz,.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp{align-items:center;display:flex;gap:var(--spacing-base)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.J0GIu2rNR7rXocQTyd8p{color:var(--jp-red);fill:var(--jp-red)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.rAV2E93SG8WpokuGk9jh{color:var(--jp-yellow-50);fill:var(--jp-yellow-50)}.kezuOHNvu9vdvlJ86Fwg .xXVEWvQllVsFGmJY8WEp.q4_FOHifGawULuFBZke9 svg{fill:var(--jp-green-50)}.jUxY9oXwnEDQLadQBNQp{animation:odHEpyTWVIDgdJClTyHg 1s linear infinite alternate;border-radius:var(--jp-border-radius-rna);color:transparent}.Vzu6IGmwfFGn5RPCIWOY{margin-bottom:1rem}@keyframes odHEpyTWVIDgdJClTyHg{0%{background-color:#f5f5f5}to{background-color:#e2e2e2}}.IorMv97NU2iEXtcbbVoN{background:var(--jp-white);border-radius:calc(var(--jp-border-radius)/2);box-shadow:0 1px 1px 0 rgba(0,0,0,.1),0 1px 1.5px 0 rgba(0,0,0,.1),0 2px 3px -.5px rgba(0,0,0,.1);padding:var(--spacing-base);position:absolute;right:0;top:calc(100% + var(--spacing-base));z-index:1}.IorMv97NU2iEXtcbbVoN ._I09VyiyxzT6EKE6RwVF{align-items:center;background-color:var(--jp-white);border:none;cursor:pointer;display:flex;gap:calc(var(--spacing-base)*7);padding:var(--spacing-base);width:100%}.IorMv97NU2iEXtcbbVoN ._I09VyiyxzT6EKE6RwVF:hover{background-color:var(--jp-gray-0)}.IorMv97NU2iEXtcbbVoN .Gmum0UGKXz4YlMG9Fwgm{align-items:center;display:flex;font-size:var(--font-label);gap:calc(var(--spacing-base)*.5)}.IorMv97NU2iEXtcbbVoN .przPMe99k8Mad0jsxI1R{background-color:var(--jp-green-50);height:25px;width:25px}.vRIYDzW5yrfnUoDPdBAN{display:flex;position:relative}.vRIYDzW5yrfnUoDPdBAN .KIyEfIhAZ4TElM0K5kuH{align-items:center;border:.5px solid var(--jp-black);border-bottom-left-radius:var(--jp-border-radius);border-top-left-radius:var(--jp-border-radius);box-shadow:inset 0 0 0 1px var(--jp-black);cursor:pointer;display:flex;justify-content:center;padding:0}.vRIYDzW5yrfnUoDPdBAN .V4VpHqht9Rm42tiZfsxU{background-color:var(--jp-black);margin-right:.5px}.vRIYDzW5yrfnUoDPdBAN .vZfbVKYvaUjhpAuMD9jg{background-color:var(--jp-white);border-right-width:0;margin-right:-.5px}.SlMzf1xQ5c9GfEx2RQgv a,.SlMzf1xQ5c9GfEx2RQgv button{border-bottom-left-radius:0;border-top-left-radius:0}.OpMBda4vebhRbW8Fm6YC{background:var(--jp-white);border:1px solid var(--jp-gray-5);border-radius:var(--jp-border-radius-rna);box-shadow:0 4px 12px 0 rgba(0,0,0,.06);display:flex;flex-direction:column;height:100%;padding:calc(var(--spacing-base)*3)}.OpMBda4vebhRbW8Fm6YC.BghJAx9hSagUdHWOUaYE{background:none;background-color:var(--jp-white-off);color:var(--jp-black-80);text-decoration:none}.OpMBda4vebhRbW8Fm6YC.BghJAx9hSagUdHWOUaYE:focus{background-color:var(--jp-white);box-shadow:0 0 0 1.5px var(--jp-black);outline:3px solid transparent}.OpMBda4vebhRbW8Fm6YC.IWsEW5nnNWUqqcT3K5L1{box-shadow:0 0 0 1.5px var(--jp-red-60)}.r3UCwgwCthua6lDCvIBI{align-items:center;display:flex;gap:var(--spacing-base);justify-content:space-between;margin-bottom:var(--spacing-base);width:100%}.r3UCwgwCthua6lDCvIBI h3{font-weight:700}.vpluqUMgmwx9_f8wCVIn{align-items:center;display:flex;flex-wrap:wrap-reverse;gap:var(--spacing-base);height:100%}.pIsYsXFAJ9KX2VrS5rmY{min-height:200px;position:relative}.pIsYsXFAJ9KX2VrS5rmY.Pp9cMIaESLYelLOX3tkI{border-color:var(--jp-red-50);border-width:1px}.pIsYsXFAJ9KX2VrS5rmY.NhOH6VeEpSrNGAPQik0w{border-color:#deb100;border-width:1px}.gmPKCDKZcfQt9WieTyKS{flex-grow:1}.fDBaV7I4yUO6w5AWVEtr{align-items:center;display:flex;flex-direction:row-reverse;flex-wrap:wrap;justify-content:space-between;margin-top:auto;min-height:28px;padding-top:calc(var(--spacing-base)*3);width:100%}.SelsBZT7eIWRQyl1dasZ{display:flex;gap:var(--spacing-base);justify-content:flex-start}.LHYJUrOej3toDvOAiz4k{align-items:center;display:flex;gap:var(--spacing-base);justify-content:space-between;margin-bottom:calc(var(--spacing-base)*.5);width:100%}.LHYJUrOej3toDvOAiz4k h3{font-weight:700;line-height:28px}.aZvwqVNw6rvImSxn0DM9{align-items:baseline;display:flex;gap:calc(var(--spacing-base)*.5);margin-bottom:var(--spacing-base)}.R4OXFRkmlHAH8ScIgYXh{color:var(--jp-gray-100);font-size:var(--font-body);font-weight:600}.R4OXFRkmlHAH8ScIgYXh.g0_8bbVjnVh0D_pS264j{color:var(--jp-gray-30);text-decoration:line-through}.nqFgW_S2jbHPu9yPq9E_{color:var(--jp-gray-30);font-size:var(--font-body-extra-small)}.f5VJYwuJmjxH8PVxEbbv{align-items:center;display:flex;height:28px;white-space:nowrap}.f5VJYwuJmjxH8PVxEbbv:before{border-radius:50%;content:"";display:inline-block;height:8px;margin-left:var(--spacing-base);width:8px}.f5VJYwuJmjxH8PVxEbbv.ry3pxoGtmQ0ZeSwp7F_3{color:var(--jp-green-50)}.f5VJYwuJmjxH8PVxEbbv.ry3pxoGtmQ0ZeSwp7F_3:before{background:var(--jp-green-50)}.f5VJYwuJmjxH8PVxEbbv.LZzE3EG7m3CDR46wwwEr{color:var(--jp-gray-50)}.f5VJYwuJmjxH8PVxEbbv.LZzE3EG7m3CDR46wwwEr:before{background:var(--jp-gray-50)}.f5VJYwuJmjxH8PVxEbbv.TZUP7W6QYGajITiMNYas{color:var(--jp-yellow-50)}.f5VJYwuJmjxH8PVxEbbv.TZUP7W6QYGajITiMNYas:before{background:var(--jp-yellow-50)}.f5VJYwuJmjxH8PVxEbbv.Vx_jpT02r8W6NfsRSB02{color:var(--jp-red-60)}.f5VJYwuJmjxH8PVxEbbv.Vx_jpT02r8W6NfsRSB02:before{background:var(--jp-red-60)}.f5VJYwuJmjxH8PVxEbbv.PdsJCfyyjSgrNDheF2qi:before{animation:dWP7ypkVXudMbAa38W5Z .5s linear infinite}@keyframes dWP7ypkVXudMbAa38W5Z{0%{opacity:0}50%{opacity:.5}to{opacity:0}}.info-tooltip__button{align-items:center;background:transparent;border:none;color:var(--jp-gray-50);cursor:pointer;display:flex;padding:2px}.info-tooltip__button svg{margin:0 auto}.info-tooltip__content h3{color:var(--jp-black);font-size:var(--font-title-small);font-weight:500;line-height:calc(var(--font-title-small) + 6px);margin:0 0 calc(var(--spacing-base)*2)}.info-tooltip__content p{color:var(--jp-gray-70);font-size:var(--font-body);line-height:var(--font-title-small);margin-bottom:0}.info-tooltip__content p a{color:var(--jp-black);text-decoration:underline}.info-tooltip__content p a:focus,.info-tooltip__content p a:hover{text-decoration:none}.gridicon{fill:currentColor;display:inline-block}.gridicon.needs-offset g{transform:translate(-1px,1px)}.gridicon.needs-offset-x g{transform:translate(-1px)}.gridicon.needs-offset-y g{transform:translateY(1px)}.wI7QgVzPXvVVu6kfnTT8{align-items:center;color:var(--jp-black);display:flex;justify-content:space-between;margin-top:1rem}.wI7QgVzPXvVVu6kfnTT8 .eqyxcUmdF0s3gmmlZGyD{display:flex;gap:1.5rem}.wI7QgVzPXvVVu6kfnTT8 .gxY6D0PeVtGk9iSB5E_u{align-items:center;display:flex;font-size:var(--font-body-small);gap:2px;margin:0}.wI7QgVzPXvVVu6kfnTT8 .D_uE0LD5CvpfM2FNp55k{align-items:center;display:flex;gap:2px}.wI7QgVzPXvVVu6kfnTT8 .VTBUdi1D4DW34F0yixMk{font-size:var(--font-body-small);margin:0}.BXQQYCO_pEmYmzBBwYxR{align-items:center;color:var(--jp-black);display:flex;gap:.25rem;margin-top:1rem}.BXQQYCO_pEmYmzBBwYxR .qdvOzzbrd3KQK7DNg8eg{font-size:var(--font-body-small);margin:0}.PFbMp_gtGLBMWbbYtO0q{display:flex;flex-grow:1;flex-wrap:wrap;gap:.25rem;justify-content:space-between}.ZFCNMiywyFvaifoIQI5w{color:var(--jp-gray-40)}.eKy3yAPsoarwSQMou_kk{align-items:center;display:flex;font-weight:500;gap:.25rem}.eKy3yAPsoarwSQMou_kk svg.Bt6AOGkWP6xSfUbq2QBQ{fill:var(--jp-red-60)}.GA8m1YdHe3xODczqUUor{align-items:flex-start;color:var(--jp-gray-50);display:flex;font-size:var(--font-body-extra-small);gap:.25rem;line-height:var(--font-title-small)}.GA8m1YdHe3xODczqUUor .KixWjGbAhopt1dR0Hv9n{padding-top:calc(var(--jp-underline-thickness)*2)}.GA8m1YdHe3xODczqUUor .KixWjGbAhopt1dR0Hv9n>svg{fill:var(--jp-red)}.GA8m1YdHe3xODczqUUor .iGcRsZkwWJW_WJglA1oO{font-size:var(--font-label);font-weight:400;line-height:20px}.value-section__heading{color:var(--jp-gray-100);font-weight:500}.mj-boost-speed-score{margin:calc(var(--spacing-base)*-1);margin-bottom:0;padding:calc(var(--spacing-base))}.mj-boost-speed-score__grade{align-items:center;column-gap:1em;display:flex;font-size:var(--font-body-small);justify-content:space-between;line-height:24px;margin:8px 0}.mj-boost-speed-score__grade--letter{all:unset;border-radius:var(--jp-border-radius);color:var(--jp-green);cursor:pointer;font-size:var(--font-title-small);font-weight:700;line-height:24px;padding:0 5px}.mj-boost-speed-score__grade--letter:focus{outline:1px dotted var(--jp-black)}.boost-score-tooltip__heading{color:#000;font-size:var(--font-title-small);line-height:30px;margin:0}.boost-score-tooltip__content{font-size:var(--font-body);line-height:24px}.boost-score-tooltip__parent{max-width:340px;min-height:150px;padding:24px;width:calc(100vw - 64px)}@media(min-width:783px){.boost-score-tooltip__parent{width:100vw}}.boost-score-tooltip__parent p:last-child{margin-bottom:0}.mj-boost-speed-score__bar .jb-score-bar__label{display:none}.mj-boost-speed-score__bar .jb-score-bar__filler{border-radius:12px;min-width:49px}.mj-boost-speed-score__bar .jb-score-bar__bounds{border-radius:12px;height:24px;margin-right:0}.mj-boost-speed-score__bar .jb-score-bar__score{border-radius:12px;height:24px;width:30px}.mj-boost-speed-score__increase{align-items:center;color:var(--jp-green-50);display:flex;font-size:var(--font-body-small);left:24px;line-height:28px;position:absolute;top:26px;fill:var(--jp-green-50)}.jb-score-bar__label,.jb-score-bar__loading,.jb-score-bar__score{align-items:center;background-color:#fff;border:2px solid transparent;border-radius:42px;display:flex;height:42px}.jb-score-bar{color:var(--jp-gray-70);display:flex;width:100%}.jb-score-bar--mobile{margin-bottom:1.5rem}@media(max-width:767px){.jb-score-bar{flex-direction:column}.jb-score-bar__label{background-color:transparent}}.jb-score-bar__loading{align-items:center;display:flex;justify-content:center;width:42px}.jb-score-bar__label{display:grid;grid-template-columns:24px 1fr;grid-column-gap:10px;font-size:14px;justify-content:center;position:relative}@media(min-width:768px){.jb-score-bar__label{padding-left:15px;padding-right:15px;width:200px;z-index:50}}.jb-score-bar__score{border-radius:100%;font-weight:700;height:42px;justify-content:center;left:-1px;position:absolute;width:42px}.jb-score-bar__bounds{background-color:#f1f1f1;border-radius:21px;display:flex;height:42px;max-width:100%;position:relative;width:100%;z-index:40}@media(min-width:768px){.jb-score-bar__bounds{margin-right:-21px;width:calc(100% + 21px)}}.jb-score-bar__filler{border-radius:42px 0 0 42px;display:flex;justify-content:flex-end;min-width:85px;position:relative;transition:width .3s ease-in-out;width:0;will-change:width}@media(max-width:767px){.jb-score-bar__filler{border-radius:inherit;min-width:43px}}.jb-score-bar__no_boost_score{--clearance-space:74px;background:#fff;background-clip:padding-box;border:2px solid transparent;border-radius:50%;cursor:pointer;font-size:.7em;height:28px;line-height:1.625;padding:3px;position:absolute;text-align:center;top:6px;width:28px;z-index:2}.jb-score-bar__no_boost_score:hover{border:2px solid hsla(0,0%,100%,.5)}.jb-score-bar__no_boost_score:after{border-bottom:6px solid #fff;border-left:6px solid transparent;border-right:6px solid transparent;content:" ";height:0;position:absolute;right:6px;top:28px;width:0}.jb-score-bar__no_boost_score_tooltip{background:#fff;border-radius:4px;box-shadow:0 0 20px 0 hsla(0,0%,67%,.28);display:none;margin:0 16px;padding:16px;position:absolute;right:-10em;top:-62px;width:20em}.jb-score-bar__no_boost_score_tooltip:after{border-left:6px solid transparent;border-right:6px solid transparent;border-top:6px solid #fff;bottom:-6px;content:" ";height:0;margin:0 -10px;position:absolute;right:10em;width:0}.jb-score-bar__no_boost_score:hover .jb-score-bar__no_boost_score_tooltip{display:block}.jb-score-bar .fill-loading{background-color:var(--jp-white)}.jb-score-bar .fill-good{background-color:var(--jp-green)}.jb-score-bar .fill-mediocre{background-color:var(--jp-orange-20)}.jb-score-bar .fill-bad{background-color:var(--jp-red-50)}.g4lyov8aMDggdD4yOi1p{align-items:baseline;display:flex;margin-top:calc(var(--spacing-base)/2)}.g4lyov8aMDggdD4yOi1p .Ys5ScZ_dYn2O2AzDE5Yi{font-size:32px;font-weight:400;line-height:36px;margin-left:var(--spacing-base)}.sUNg_b7XteVXOrpHAkJg :last-child{margin-top:4px}.cF6QAJf1vXXAMuutXPcq{align-items:baseline;display:flex}.cF6QAJf1vXXAMuutXPcq.coY634LconQ7gzDDNJeu{color:var(--jp-gray-10);fill:var(--jp-gray-10)}.cF6QAJf1vXXAMuutXPcq.kyqpwKaL2FyQ8CtxJQ0f{color:var(--jp-green-50);fill:var(--jp-green-50)}.cF6QAJf1vXXAMuutXPcq.aXf37lEOcjpNV8ImLaYK{color:var(--jp-red-40);fill:var(--jp-red-40)}.cF6QAJf1vXXAMuutXPcq .OyGdoGzsQ48VaVVR99_H{position:relative;right:2px;top:2px}.cF6QAJf1vXXAMuutXPcq .cKLicfMCaDSGPlX222jF{font-size:14px;font-weight:600;line-height:24px}.ZaPXoMGC_e8NfFoBgA95,.gb2kSZHPauLu96D9HAIg{margin-bottom:1.5rem}.qpN923qyxjI06NCgFC8j>li{margin-bottom:0}.hpd1bQCLIZYXpZJa22qw{color:var(--jp-gray-100);font-size:var(--font-body-extra-small);font-weight:500;line-height:var(--font-title-small);margin-bottom:calc(var(--spacing-base) + 2px)}.info-tooltip__content{max-width:340px;min-height:150px;padding:24px;width:calc(100vw - 64px)}.components-popover.is-expanded .info-tooltip__content{max-width:unset;width:auto}@media screen and (min-width:599px)and (max-width:1290px){ul.qpN923qyxjI06NCgFC8j{grid-template-columns:repeat(auto-fill,minmax(300px,1fr))}ul.qpN923qyxjI06NCgFC8j>li{grid-column-end:auto}}.value-section{display:flex;justify-content:space-between;margin-top:calc(var(--spacing-base)/2)}.value-section>div{align-items:flex-start;display:flex;flex-direction:column}.value-section__heading{align-items:center;display:flex;text-wrap:nowrap}.value-section__last-scan{align-items:center;column-gap:1px;display:flex;justify-content:flex-end;left:calc(var(--spacing-base)*3);margin-top:var(--spacing-base);position:absolute;width:calc(57% - var(--spacing-base)*3)}.value-section__last-scan div{color:var(--jp-gray-50);font-size:var(--font-body-extra-small);line-height:var(--font-body);text-align:left}@media(max-width:480px){.value-section__last-scan{width:calc(53% - var(--spacing-base)*3)}}.value-section__data{align-items:center;color:var(--jp-gray-50);display:flex;flex:1;font-size:var(--font-body-extra-small);font-weight:500;justify-content:center;line-height:var(--font-title-small)}.value-section__status-icon{display:block;margin-left:calc(var(--spacing-base) - 2px)}.value-section__status-text{letter-spacing:-.24px;margin-left:1px}.scan-threats__threat-count{color:var(--jp-black);font-size:calc(var(--font-title-large) - 4px);font-weight:400;line-height:var(--font-title-large)}.scan-threats__critical-threats{align-items:center;display:flex}.scan-threats__critical-threat-container{margin-right:1px}.scan-threats__critical-threat-container>button>svg{fill:var(--jp-red-50)}.scan-threats__critical-threat-count{color:var(--jp-red-50);margin-right:calc(var(--spacing-base)/4)}.logins_blocked__count{color:var(--jp-black);font-size:calc(var(--font-headline-small) - 4px);font-weight:400;line-height:var(--font-title-large)}.videopress-card__video-count{color:var(--jp-gray-90);display:flex;font-size:calc(var(--font-headline-small) - 4px);line-height:1.125;margin-top:calc(var(--spacing-base)/2)}.videopress-card__video-count .videopress-card__tooltip{height:18px}p.description{color:var(--jp-gray-70);font-size:var(--font-body-small);margin:0 0 1rem}.videopress-card__value-section{display:flex;gap:.75rem;justify-content:space-between}.videopress-card__value-section__container{align-items:flex-start;display:flex;flex-direction:column}.videopress-card__value-section__value-container{align-items:flex-end;display:flex;flex-wrap:wrap}.videopress-card__value-section__value{color:var(--jp-gray-90);font-size:calc(var(--font-headline-small) - 4px);line-height:1}.videopress-card__value-section__previous-value{align-items:center;display:flex;font-size:var(--font-body-extra-small);font-weight:600;line-height:18px}.videopress-card__value-section__previous-value.increase *{color:var(--jp-green-50);fill:var(--jp-green-50)}.videopress-card__value-section__previous-value.decrease *{color:var(--jp-red-50);fill:var(--jp-red-50)}.videopress-card__value-section__heading{align-items:center;display:flex;text-wrap:nowrap}.videopress-card__no-video-tooltip .info-tooltip__button{display:inline;vertical-align:middle}.iG63b_J1HNfT8xEIq619{margin-bottom:.75rem}.T8UhA3lZQjpZsyaah9J6{width:200px}.Tobf3RFq_fT42YGp_h4g{font-size:var(--font-body)}ul.g69ZGQc9wey1u1beD0IP{grid-auto-flow:column;grid-template-columns:repeat(5,100%);overflow-x:auto;scroll-behavior:smooth;scroll-snap-type:x mandatory;scrollbar-width:none;-ms-overflow-style:none}ul.g69ZGQc9wey1u1beD0IP::-webkit-scrollbar{display:none}ul.g69ZGQc9wey1u1beD0IP li{grid-column:unset;grid-column-end:unset;max-width:100%;scroll-snap-align:start;width:100%}@media screen and (min-width:601px){ul.g69ZGQc9wey1u1beD0IP{grid-template-columns:repeat(5,1fr)}ul.g69ZGQc9wey1u1beD0IP li{width:420px}}@media screen and (min-width:1025px){ul.g69ZGQc9wey1u1beD0IP li{width:320px}}.aWIwsRSR2EZlTGwFYt5J{transition:all .3s ease}.DzezAg6fdaIC26GPBCvD:not(:disabled):hover{transform:translateX(4px)}.buuFW6iZyD5Nnljxcxj8:not(:disabled):hover{transform:translateX(-4px)}.HeJe1crc9XaWWpLvIPit .components-modal__frame{border-bottom-right-radius:4px;border-right:4px solid #e68b28;border-top-right-radius:4px;max-height:100%}.HeJe1crc9XaWWpLvIPit .components-modal__content{margin-top:0;padding:0}.HeJe1crc9XaWWpLvIPit .components-modal__header{display:none}.HeJe1crc9XaWWpLvIPit .or0JUScxkJPmNsfrxkEK .jp-idc__idc-screen{border:0}.components-surface.components-card{border-radius:var(--jp-border-radius-rna)}.upsell-banner{background:#f9f9f6;background:linear-gradient(-133deg,#ced9f2,#f9f9f6 10%,#f9f9f6 80%,#f5e6b3);display:flex;flex-direction:column}@media screen and (min-width:660px){.upsell-banner{flex-direction:row}}.upsell-banner.components-card__body.components-card-body{border-radius:var(--jp-border-radius-rna);padding:36px}.upsell-banner .upsell-banner--icon{align-items:flex-start;display:flex;margin-bottom:16px;margin-left:0;margin-top:16px}@media screen and (min-width:660px){.upsell-banner .upsell-banner--icon{align-items:center;margin-bottom:0;margin-left:28px;margin-top:0}}.upsell-banner .upsell-banner--content{display:flex;flex:1;flex-direction:column;justify-content:space-between}@media screen and (min-width:660px){.upsell-banner .upsell-banner--content{flex-direction:row}}.upsell-banner .upsell-banner--content .upsell-banner--content-info{display:flex;flex-direction:column}.upsell-banner .upsell-banner--content .upsell-banner--content-info h3{font-size:1.5rem;font-weight:500;line-height:32px;margin:0}.upsell-banner .upsell-banner--content .upsell-banner--content-info p{font-size:1rem;margin:8px 0 0}.upsell-banner .upsell-banner--content .upsell-banner--content-cta{align-items:center;display:flex;flex-direction:row;margin-right:0;margin-top:16px}@media screen and (min-width:660px){.upsell-banner .upsell-banner--content .upsell-banner--content-cta{margin-right:16px;margin-top:0}}.upsell-banner .upsell-banner--content .upsell-banner--content-cta .upsell-banner--content-cta-button{box-shadow:inset 0 0 0 1.5px #000;font-weight:400;padding:8px 16px;white-space:nowrap}.upsell-banner .upsell-banner--content .upsell-banner--content-cta .upsell-banner--content-cta-button.secondary{background-color:var(--jp-white);color:var(--jp-black)}.upsell-banner .upsell-banner--content .upsell-banner--content-cta .upsell-banner--content-cta-button.primary{margin-right:8px}.yWUvvF4WJLNDSpMgBMfm{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.ka1fVHj2HOkHjhdoEFOZ{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.ka1fVHj2HOkHjhdoEFOZ{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.ka1fVHj2HOkHjhdoEFOZ{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.JMOO4Y_9yhTO9lwLnRUx{grid-column-end:span 1}.PFDPAqk51qox_ChLqJwm{grid-column-end:span 2}.ault0jHVfWpShqOGooIP{grid-column-end:span 3}.GqpvdRzmzPJELtSm4FEN{grid-column-end:span 4}@media(min-width:600px){.Ym4_YneEGD_iZD6W1C2o{grid-column-end:span 1}.NbvHnnDtWw8n9BEUQ0Oy{grid-column-end:span 2}.ElMT7rhxe5ZJKO41MnhW{grid-column-end:span 3}.yKjnqjibn_wW_1tWWt5Q{grid-column-end:span 4}.Pb30lOcQFpzUX57GwflS{grid-column-end:span 5}.pC1wxc_R8y4pNILHsiiY{grid-column-end:span 6}.pChscSCnudQoWGjMFKI_{grid-column-end:span 7}.qw1H2gAgF3lDCI2Tbkmb{grid-column-end:span 8}}@media(min-width:960px){.VzcA_rrxBK3g4ozA0oD9{grid-column-end:span 1}.pNAa7O2adRZD8Slgk9iR{grid-column-end:span 2}.tlIMLlipexblj8CeOx4B{grid-column-end:span 3}.Dvt0u5l2Rr1BhBmvYAzl{grid-column-end:span 4}.BiUsgNTc0tyc7tC5jnzE{grid-column-end:span 5}.ulJXAsj7G2ROJ1g3_s28{grid-column-end:span 6}.HsoVlyVLsXYClx9Atox0{grid-column-end:span 7}.oXxjRQNNj2cfIpFBqC1W{grid-column-end:span 8}.qXgUn4Adg9xE_JnbuDio{grid-column-end:span 9}.xMpqTLiLfYFEJiRPQQQq{grid-column-end:span 10}.IiGo3Sz2FDZN7_eGElwA{grid-column-end:span 11}.Om8BNCjfgqQ_wmPQjfOY{grid-column-end:span 12}}@media(max-width:960px){.t10ZWzP7ADjJnR4tqxRS{display:none}}@media(max-width:600px){.eOUlZG8Pelh_Xj0aSoHG{display:none}}.l546LrwBEePz434NFK5Q{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);display:block;margin:32px 0;padding:16px 24px 16px 64px;position:relative;text-decoration:none}.l546LrwBEePz434NFK5Q span{display:block}.l546LrwBEePz434NFK5Q span:last-of-type{font-weight:600}.l546LrwBEePz434NFK5Q:focus span:last-of-type,.l546LrwBEePz434NFK5Q:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.l546LrwBEePz434NFK5Q:focus:after,.l546LrwBEePz434NFK5Q:hover:after{transform:translateY(-50%) translateX(-8px)}.l546LrwBEePz434NFK5Q:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;left:24px;position:absolute;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.Q7w4fcEcemZ2nlwaYNog{fill:var(--jp-yellow-30)!important;display:inline-block!important;width:1.1em!important}.AoNQsOaTt6gSf0H6Yasz{display:inline-block;position:relative}.v13ZwGzUnecPA7Y3URAl{height:18px;pointer-events:none;position:absolute;right:-53px;top:0;width:124px}.EeDbu9pXFWTsCzfTpv2v{pointer-events:all}.BmSvoIi3rErkcrRiOi2W{color:var(--jp-black);font-size:16px;font-weight:600;line-height:19px}.BmSvoIi3rErkcrRiOi2W:not(:last-child){margin-bottom:8px}.mojRoVuWdDJo0E6LEjJw{font-size:14px;font-weight:400;line-height:24px}.golden-token-icon-tooltip .components-popover:not([data-y-axis=middle])[data-x-axis=left] .components-popover__content{margin-left:-62px}.golden-token-icon-tooltip .components-popover:not([data-y-axis=middle])[data-x-axis=right] .components-popover__content{margin-right:-62px}.golden-token-icon-tooltip .components-popover[data-y-axis=bottom] .components-popover__content{top:2px!important}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:before{top:-6px!important}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:after{top:-4px!important}.golden-token-icon-tooltip .components-popover[data-y-axis=top] .components-popover__content{bottom:10px!important}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=top]:before{bottom:3px}.golden-token-icon-tooltip .components-popover:not(.is-without-arrow)[data-y-axis=top]:after{bottom:4px}.golden-token-icon-tooltip .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;outline:none;padding:24px;white-space:normal;width:304px}.golden-token-icon-tooltip .components-button.is-link:focus:not(:disabled){box-shadow:none}.wiobThfXJCuhGNrbFIT6 a,.wiobThfXJCuhGNrbFIT6 a:active,.wiobThfXJCuhGNrbFIT6 a:hover{color:var(--jp-black)}.pm2EPQZx6p2VQSiiVCpX{margin-bottom:calc(var(--spacing-base)*3)}.VgAxgahF9bC2M__FiIgV{display:flex}.dbRwkMLqcMF67njPoAF7{margin-left:8px}.V8N_dXausMNmQUO_ROa1{color:var(--jp-red-60)}.jYhEGFLjpRv6QV1Ti7dQ{color:var(--jp-yellow-40)}.Doju0RxvvN9JS12mf489{line-height:calc(var(--spacing-base)*3);margin:0 0 var(--spacing-base) 0}:root{--wp-admin-theme-color:#007cba;--wp-admin-theme-color--rgb:0,124,186;--wp-admin-theme-color-darker-10:#006ba1;--wp-admin-theme-color-darker-10--rgb:0,107,161;--wp-admin-theme-color-darker-20:#005a87;--wp-admin-theme-color-darker-20--rgb:0,90,135;--wp-block-synced-color:#7a00df;--wp-block-synced-color--rgb:122,0,223;--wp-bound-block-color:var(--wp-block-synced-color)}.dataviews-wrapper{box-sizing:border-box;container:dataviews-wrapper/inline-size;display:flex;flex-direction:column;font-size:13px;height:100%;line-height:1.4;overflow:auto;scroll-padding-bottom:64px}.dataviews-filters__container,.dataviews__view-actions{box-sizing:border-box;flex-shrink:0;padding:16px 48px;position:sticky;right:0}@media not (prefers-reduced-motion){.dataviews-filters__container,.dataviews__view-actions{transition:padding .1s ease-out}}.dataviews-loading,.dataviews-no-results{align-items:center;display:flex;flex-grow:1;justify-content:center;padding:0 48px}@media not (prefers-reduced-motion){.dataviews-loading,.dataviews-no-results{transition:padding .1s ease-out}}@container (max-width: 430px){.dataviews-filters__container,.dataviews__view-actions{padding:12px 24px}.dataviews-loading,.dataviews-no-results{padding-left:24px;padding-right:24px}}.dataviews-title-field{font-size:13px;font-weight:500;width:100%}.dataviews-title-field,.dataviews-title-field a{color:#2f2f2f;text-overflow:ellipsis;white-space:nowrap}.dataviews-title-field a{display:block;flex-grow:0;overflow:hidden;text-decoration:none}.dataviews-title-field a:hover{color:var(--wp-admin-theme-color)}.dataviews-title-field a:focus{border-radius:2px;box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color,#007cba);color:var(--wp-admin-theme-color--rgb)}.dataviews-title-field button.components-button.is-link{color:#1e1e1e;display:block;font-weight:inherit;overflow:hidden;text-decoration:none;text-overflow:ellipsis;white-space:nowrap;width:100%}.dataviews-title-field button.components-button.is-link:hover{color:var(--wp-admin-theme-color)}.dataviews-title-field--clickable{color:#2f2f2f;cursor:pointer}.dataviews-title-field--clickable:hover{color:var(--wp-admin-theme-color)}.dataviews-title-field--clickable:focus{border-radius:2px;box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color,#007cba);color:var(--wp-admin-theme-color--rgb)}.dataviews-bulk-actions-footer__item-count{color:#1e1e1e;font-size:11px;font-weight:500;text-transform:uppercase}.dataviews-bulk-actions-footer__container{margin-left:auto;min-height:32px}.dataviews-filters__button{position:relative}.dataviews-filters__container{padding-top:0}.dataviews-filters__reset-button.dataviews-filters__reset-button[aria-disabled=true],.dataviews-filters__reset-button.dataviews-filters__reset-button[aria-disabled=true]:hover{opacity:0}.dataviews-filters__reset-button.dataviews-filters__reset-button[aria-disabled=true]:focus{opacity:1}.dataviews-filters__summary-popover{font-size:13px;line-height:1.4}.dataviews-filters__summary-popover .components-popover__content{border-radius:4px;width:230px}.dataviews-filters__summary-popover.components-dropdown__content .components-popover__content{padding:0}.dataviews-filters__summary-operators-container{padding:8px 8px 0}.dataviews-filters__summary-operators-container:has(+.dataviews-filters__search-widget-listbox){border-bottom:1px solid #e0e0e0;padding-bottom:8px}.dataviews-filters__summary-operators-container:empty{display:none}.dataviews-filters__summary-operators-container .dataviews-filters__summary-operators-filter-name{color:#757575}.dataviews-filters__summary-chip-container{position:relative;white-space:pre-wrap}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip{align-items:center;background:#f0f0f0;border:1px solid transparent;border-radius:16px;box-sizing:border-box;color:#2f2f2f;cursor:pointer;display:flex;min-height:32px;padding:4px 12px;position:relative}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-reset{padding-inline-end:28px}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip:focus-visible,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip:hover,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip[aria-expanded=true]{background:#e0e0e0;color:#1e1e1e}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-values{background:rgba(var(--wp-admin-theme-color--rgb),.04);color:var(--wp-admin-theme-color)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-values:hover,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip.has-values[aria-expanded=true]{background:rgba(var(--wp-admin-theme-color--rgb),.12)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip:focus-visible{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:none}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip .dataviews-filters-__summary-filter-text-name{font-weight:500}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove{align-items:center;background:transparent;border:0;border-radius:50%;cursor:pointer;display:flex;height:24px;justify-content:center;left:4px;padding:0;position:absolute;top:50%;transform:translateY(-50%);width:24px}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove svg{fill:#757575}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:focus,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:hover{background:#e0e0e0}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:focus svg,.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:hover svg{fill:#1e1e1e}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove.has-values svg{fill:var(--wp-admin-theme-color)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove.has-values:hover{background:rgba(var(--wp-admin-theme-color--rgb),.08)}.dataviews-filters__summary-chip-container .dataviews-filters__summary-chip-remove:focus-visible{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:none}.dataviews-filters__search-widget-filter-combobox-list{border-top:1px solid #e0e0e0;max-height:184px;overflow:auto;padding:4px}.dataviews-filters__search-widget-filter-combobox-list .dataviews-filters__search-widget-filter-combobox-item-value [data-user-value]{font-weight:600}.dataviews-filters__search-widget-listbox{overflow:auto;padding:4px}.dataviews-filters__search-widget-listitem{align-items:center;border-radius:2px;box-sizing:border-box;cursor:default;display:flex;gap:8px;margin-block-end:2px;padding:8px 12px}.dataviews-filters__search-widget-listitem:last-child{margin-block-end:0}.dataviews-filters__search-widget-listitem:focus,.dataviews-filters__search-widget-listitem:hover,.dataviews-filters__search-widget-listitem[data-active-item]{background-color:var(--wp-admin-theme-color);color:#fff}.dataviews-filters__search-widget-listitem:focus .dataviews-filters__search-widget-listitem-check,.dataviews-filters__search-widget-listitem:hover .dataviews-filters__search-widget-listitem-check,.dataviews-filters__search-widget-listitem[data-active-item] .dataviews-filters__search-widget-listitem-check{fill:#fff}.dataviews-filters__search-widget-listitem:focus .dataviews-filters__search-widget-listitem-description,.dataviews-filters__search-widget-listitem:hover .dataviews-filters__search-widget-listitem-description,.dataviews-filters__search-widget-listitem[data-active-item] .dataviews-filters__search-widget-listitem-description{color:#fff}.dataviews-filters__search-widget-listitem .dataviews-filters__search-widget-listitem-check{flex-shrink:0;height:24px;width:24px}.dataviews-filters__search-widget-listitem .dataviews-filters__search-widget-listitem-description{color:#757575;display:block;font-size:12px;line-height:16px;overflow:hidden;text-overflow:ellipsis}.dataviews-filters__search-widget-filter-combobox__wrapper{padding:8px;position:relative}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{background:#f0f0f0;border:none;border-radius:2px;box-shadow:0 0 0 transparent;display:block;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;height:32px;line-height:normal;margin-left:0;margin-right:0;padding:0 8px 0 32px;width:100%}@media not (prefers-reduced-motion){.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{transition:box-shadow .1s linear}}@media(min-width:600px){.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{font-size:13px;line-height:normal}}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-moz-placeholder{color:rgba(30,30,30,.62)}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width:600px){.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input{font-size:13px}}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input:focus{background:#fff;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color)}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::placeholder{color:#757575}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-cancel-button,.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-decoration,.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-results-button,.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__input::-webkit-search-results-decoration{-webkit-appearance:none}.dataviews-filters__search-widget-filter-combobox__wrapper .dataviews-filters__search-widget-filter-combobox__icon{align-items:center;display:flex;justify-content:center;left:12px;position:absolute;top:50%;transform:translateY(-50%);width:24px}.dataviews-filters__container-visibility-toggle{flex-shrink:0;position:relative}.dataviews-filters-toggle__count{background:var(--wp-admin-theme-color,#3858e9);border-radius:8px;box-sizing:border-box;color:#fff;font-size:11px;height:16px;left:0;line-height:16px;min-width:16px;outline:var(--wp-admin-border-width-focus) solid #fff;padding:0 4px;position:absolute;text-align:center;top:0;transform:translate(-50%,-50%)}.dataviews-search{width:fit-content}.dataviews-footer{background-color:#fff;border-top:1px solid #f0f0f0;bottom:0;flex-shrink:0;padding:12px 48px;position:sticky;right:0;z-index:2}@media not (prefers-reduced-motion){.dataviews-footer{transition:padding .1s ease-out}}@container (max-width: 430px){.dataviews-footer{padding:12px 24px}}@container (max-width: 560px){.dataviews-footer{flex-direction:column!important}.dataviews-footer .dataviews-bulk-actions-footer__container{width:100%}.dataviews-footer .dataviews-bulk-actions-footer__item-count{flex-grow:1}.dataviews-footer .dataviews-pagination{justify-content:space-between;width:100%}}.dataviews-pagination__page-select{font-size:11px;font-weight:500;text-transform:uppercase}@media(min-width:600px){.dataviews-pagination__page-select .components-select-control__input{font-size:11px!important;font-weight:500}}.dataviews-action-modal{z-index:1000001}.dataviews-selection-checkbox{--checkbox-input-size:24px;flex-shrink:0;line-height:0}@media(min-width:600px){.dataviews-selection-checkbox{--checkbox-input-size:16px}}.dataviews-selection-checkbox .components-checkbox-control__input-container{margin:0}.dataviews-view-config{container-type:inline-size;font-size:13px;line-height:1.4;width:320px}.dataviews-config__popover.is-expanded .dataviews-config__popover-content-wrapper{height:100%;overflow-y:scroll}.dataviews-config__popover.is-expanded .dataviews-config__popover-content-wrapper .dataviews-view-config{width:auto}.dataviews-view-config__sort-direction .components-toggle-group-control-option-base{text-transform:uppercase}.dataviews-settings-section__title.dataviews-settings-section__title{font-size:15px;line-height:24px}.dataviews-settings-section__sidebar{grid-column:span 4}.dataviews-settings-section__content,.dataviews-settings-section__content>*{grid-column:span 8}.dataviews-settings-section__content .is-divided-in-two{display:contents}.dataviews-settings-section__content .is-divided-in-two>*{grid-column:span 4}.dataviews-settings-section:has(.dataviews-settings-section__content:empty){display:none}@container (max-width: 500px){.dataviews-settings-section.dataviews-settings-section{grid-template-columns:repeat(2,1fr)}.dataviews-settings-section.dataviews-settings-section .dataviews-settings-section__content,.dataviews-settings-section.dataviews-settings-section .dataviews-settings-section__sidebar{grid-column:span 2}}.dataviews-field-control__field{height:32px}.dataviews-field-control__actions{position:absolute;top:-9999em}.dataviews-field-control__actions.dataviews-field-control__actions{gap:4px}.dataviews-field-control__field.is-interacting .dataviews-field-control__actions,.dataviews-field-control__field:focus-within .dataviews-field-control__actions,.dataviews-field-control__field:hover .dataviews-field-control__actions{position:unset;top:unset}.dataviews-field-control__icon{display:flex;width:24px}.dataviews-field-control__label-sub-label-container{flex-grow:1}.dataviews-field-control__label{display:block}.dataviews-field-control__sub-label{color:#757575;font-size:11px;font-style:normal;margin-bottom:0;margin-top:8px}.dataviews-view-grid{container-type:inline-size;grid-template-rows:max-content;margin-bottom:auto;padding:0 48px 24px}@media not (prefers-reduced-motion){.dataviews-view-grid{transition:padding .1s ease-out}}.dataviews-view-grid .dataviews-view-grid__card{height:100%;justify-content:flex-start;position:relative}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__title-actions{padding:8px 0 4px}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__title-field{align-items:center;display:flex;min-height:24px}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__title-field--clickable{width:fit-content}.dataviews-view-grid .dataviews-view-grid__card.is-selected .dataviews-view-grid__fields .dataviews-view-grid__field .dataviews-view-grid__field-value{color:#1e1e1e}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__media:focus:after,.dataviews-view-grid .dataviews-view-grid__card.is-selected .dataviews-view-grid__media:after{background-color:rgba(var(--wp-admin-theme-color--rgb),.08)}.dataviews-view-grid .dataviews-view-grid__card.is-selected .dataviews-view-grid__media:after{box-shadow:inset 0 0 0 1px var(--wp-admin-theme-color)}.dataviews-view-grid .dataviews-view-grid__card .dataviews-view-grid__media:focus:after{box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color)}.dataviews-view-grid .dataviews-view-grid__media{aspect-ratio:1/1;background-color:#f0f0f0;border-radius:4px;min-height:200px;position:relative;width:100%}.dataviews-view-grid .dataviews-view-grid__media img{height:100%;object-fit:cover;width:100%}.dataviews-view-grid .dataviews-view-grid__media:after{border-radius:4px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1);content:"";height:100%;pointer-events:none;position:absolute;right:0;top:0;width:100%}.dataviews-view-grid .dataviews-view-grid__fields{font-size:12px;line-height:16px;position:relative}.dataviews-view-grid .dataviews-view-grid__fields:not(:empty){padding:0 0 12px}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field-value:not(:empty){line-height:20px;min-height:24px;padding-top:2px}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field{align-items:center;min-height:24px}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field .dataviews-view-grid__field-name{color:#757575;width:35%}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field .dataviews-view-grid__field-value{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:65%}.dataviews-view-grid .dataviews-view-grid__fields .dataviews-view-grid__field:not(:has(.dataviews-view-grid__field-value:not(:empty))){display:none}.dataviews-view-grid .dataviews-view-grid__badge-fields:not(:empty){padding-bottom:12px}@container (max-width: 480px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(1,minmax(0,1fr));padding-left:24px;padding-right:24px}}@container (min-width: 480px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@container (min-width: 780px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}@container (min-width: 1140px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(4,minmax(0,1fr))}}@container (min-width: 1520px){.dataviews-view-grid.dataviews-view-grid{grid-template-columns:repeat(5,minmax(0,1fr))}}.dataviews-view-grid__field-value:empty,.dataviews-view-grid__field:empty{display:none}.dataviews-view-grid__card .dataviews-selection-checkbox{position:absolute;right:8px;top:-9999em;z-index:1}.dataviews-view-grid__card.is-selected .dataviews-selection-checkbox,.dataviews-view-grid__card:focus-within .dataviews-selection-checkbox,.dataviews-view-grid__card:hover .dataviews-selection-checkbox{top:8px}.dataviews-view-grid__media--clickable{cursor:pointer}div.dataviews-view-list{list-style-type:none}.dataviews-view-list{margin:0 0 auto}.dataviews-view-list div[role=row]{border-top:1px solid #f0f0f0;margin:0}.dataviews-view-list div[role=row] .dataviews-view-list__item-wrapper{box-sizing:border-box;padding:16px 24px;position:relative}.dataviews-view-list div[role=row] .dataviews-view-list__item-actions{flex:0;overflow:hidden}.dataviews-view-list div[role=row] .dataviews-view-list__item-actions>div{height:24px}.dataviews-view-list div[role=row] .dataviews-view-list__item-actions .components-button{opacity:0;position:relative;z-index:1}.dataviews-view-list div[role=row]:where(.is-selected,.is-hovered,:focus-within) .dataviews-view-list__item-actions{flex-basis:min-content;overflow:unset;padding-inline-end:4px}.dataviews-view-list div[role=row]:where(.is-selected,.is-hovered,:focus-within) .dataviews-view-list__item-actions .components-button{opacity:1}.dataviews-view-list div[role=row].is-selected.is-selected,.dataviews-view-list div[role=row].is-selected.is-selected+div[role=row]{border-top:1px solid rgba(var(--wp-admin-theme-color--rgb),.12)}.dataviews-view-list div[role=row]:not(.is-selected) .dataviews-view-list__title-field{color:#1e1e1e}.dataviews-view-list div[role=row]:not(.is-selected).is-hovered,.dataviews-view-list div[role=row]:not(.is-selected):focus-within,.dataviews-view-list div[role=row]:not(.is-selected):hover{background-color:#f8f8f8;color:var(--wp-admin-theme-color)}.dataviews-view-list div[role=row]:not(.is-selected).is-hovered .dataviews-view-list__fields,.dataviews-view-list div[role=row]:not(.is-selected).is-hovered .dataviews-view-list__title-field,.dataviews-view-list div[role=row]:not(.is-selected):focus-within .dataviews-view-list__fields,.dataviews-view-list div[role=row]:not(.is-selected):focus-within .dataviews-view-list__title-field,.dataviews-view-list div[role=row]:not(.is-selected):hover .dataviews-view-list__fields,.dataviews-view-list div[role=row]:not(.is-selected):hover .dataviews-view-list__title-field{color:var(--wp-admin-theme-color)}.dataviews-view-list div[role=row].is-selected .dataviews-view-list__item-wrapper,.dataviews-view-list div[role=row].is-selected:focus-within .dataviews-view-list__item-wrapper{background-color:rgba(var(--wp-admin-theme-color--rgb),.04);color:#1e1e1e}.dataviews-view-list div[role=row].is-selected .dataviews-view-list__item-wrapper .dataviews-view-list__fields,.dataviews-view-list div[role=row].is-selected .dataviews-view-list__item-wrapper .dataviews-view-list__title-field,.dataviews-view-list div[role=row].is-selected:focus-within .dataviews-view-list__item-wrapper .dataviews-view-list__fields,.dataviews-view-list div[role=row].is-selected:focus-within .dataviews-view-list__item-wrapper .dataviews-view-list__title-field{color:var(--wp-admin-theme-color)}.dataviews-view-list .dataviews-view-list__item{appearance:none;background:none;border:none;cursor:pointer;inset:0;padding:0;position:absolute;scroll-margin:8px 0;z-index:1}.dataviews-view-list .dataviews-view-list__item:focus-visible{outline:none}.dataviews-view-list .dataviews-view-list__item:focus-visible:before{border-radius:2px;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);content:"";inset:var(--wp-admin-border-width-focus);outline:2px solid transparent;position:absolute}.dataviews-view-list .dataviews-view-list__title-field{flex:1;line-height:24px;min-height:24px;overflow:hidden}.dataviews-view-list .dataviews-view-list__title-field:has(a,button){z-index:1}.dataviews-view-list .dataviews-view-list__media-wrapper{background-color:#f0f0f0;border-radius:4px;flex-shrink:0;height:52px;overflow:hidden;position:relative;width:52px}.dataviews-view-list .dataviews-view-list__media-wrapper img{height:100%;object-fit:cover;width:100%}.dataviews-view-list .dataviews-view-list__media-wrapper:after{border-radius:4px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1);content:"";height:100%;position:absolute;right:0;top:0;width:100%}.dataviews-view-list .dataviews-view-list__field-wrapper{flex-grow:1;min-height:52px}.dataviews-view-list .dataviews-view-list__fields{color:#757575;display:flex;flex-wrap:wrap;font-size:12px;gap:12px;row-gap:4px}.dataviews-view-list .dataviews-view-list__fields:empty{display:none}.dataviews-view-list .dataviews-view-list__fields .dataviews-view-list__field:has(.dataviews-view-list__field-value:empty){display:none}.dataviews-view-list .dataviews-view-list__fields .dataviews-view-list__field-value{align-items:center;display:flex;line-height:20px;min-height:24px}.dataviews-view-list+.dataviews-pagination{justify-content:space-between}.dataviews-view-table{border-collapse:collapse;border-color:inherit;color:#757575;margin-bottom:auto;position:relative;text-indent:0;width:100%}.dataviews-view-table th{color:#1e1e1e;font-size:13px;font-weight:400;text-align:right}.dataviews-view-table td,.dataviews-view-table th{padding:12px;white-space:nowrap}.dataviews-view-table td.dataviews-view-table__actions-column,.dataviews-view-table th.dataviews-view-table__actions-column{text-align:left}.dataviews-view-table td.dataviews-view-table__checkbox-column,.dataviews-view-table th.dataviews-view-table__checkbox-column{padding-left:0;width:1%}.dataviews-view-table tr{border-top:1px solid #f0f0f0}.dataviews-view-table tr .dataviews-view-table-header-button{gap:4px}.dataviews-view-table tr td:first-child,.dataviews-view-table tr th:first-child{padding-right:48px}.dataviews-view-table tr td:first-child .dataviews-view-table-header-button,.dataviews-view-table tr th:first-child .dataviews-view-table-header-button{margin-right:-8px}.dataviews-view-table tr td:last-child,.dataviews-view-table tr th:last-child{padding-left:48px}.dataviews-view-table tr:last-child{border-bottom:0}.dataviews-view-table tr.is-hovered{background-color:#f8f8f8}.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input{opacity:0}.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input:checked,.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input:focus,.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input:indeterminate{opacity:1}.dataviews-view-table tr .dataviews-item-actions .components-button:not(.dataviews-all-actions-button){opacity:0}.dataviews-view-table tr.is-hovered .components-checkbox-control__input,.dataviews-view-table tr.is-hovered .dataviews-item-actions .components-button:not(.dataviews-all-actions-button),.dataviews-view-table tr:focus-within .components-checkbox-control__input,.dataviews-view-table tr:focus-within .dataviews-item-actions .components-button:not(.dataviews-all-actions-button),.dataviews-view-table tr:hover .components-checkbox-control__input,.dataviews-view-table tr:hover .dataviews-item-actions .components-button:not(.dataviews-all-actions-button){opacity:1}@media(hover:none){.dataviews-view-table tr .components-checkbox-control__input.components-checkbox-control__input,.dataviews-view-table tr .dataviews-item-actions .components-button:not(.dataviews-all-actions-button){opacity:1}}.dataviews-view-table tr.is-selected{background-color:rgba(var(--wp-admin-theme-color--rgb),.04);color:#757575}.dataviews-view-table tr.is-selected,.dataviews-view-table tr.is-selected+tr{border-top:1px solid rgba(var(--wp-admin-theme-color--rgb),.12)}.dataviews-view-table tr.is-selected:hover{background-color:rgba(var(--wp-admin-theme-color--rgb),.08)}.dataviews-view-table thead{inset-block-start:0;position:sticky;z-index:1}.dataviews-view-table thead tr{border:0}.dataviews-view-table thead th{background-color:#fff;font-size:11px;font-weight:500;padding-bottom:8px;padding-right:12px;padding-top:8px;text-transform:uppercase}.dataviews-view-table thead th:has(.dataviews-view-table-header-button):not(:first-child){padding-right:4px}.dataviews-view-table tbody td{vertical-align:top}.dataviews-view-table tbody .dataviews-view-table__cell-content-wrapper{align-items:center;display:flex;min-height:32px}.dataviews-view-table tbody .components-v-stack>.dataviews-view-table__cell-content-wrapper:not(:first-child){min-height:0}.dataviews-view-table .dataviews-view-table-header-button{font-size:11px;font-weight:500;padding:4px 8px;text-transform:uppercase}.dataviews-view-table .dataviews-view-table-header-button:not(:hover){color:#1e1e1e}.dataviews-view-table .dataviews-view-table-header-button span{speak:none}.dataviews-view-table .dataviews-view-table-header-button span:empty{display:none}.dataviews-view-table .dataviews-view-table-header{padding-right:4px}.dataviews-view-table .dataviews-view-table__actions-column{width:1%}.dataviews-view-table:has(tr.is-selected) .components-checkbox-control__input{opacity:1}.dataviews-view-table.has-compact-density thead th:has(.dataviews-view-table-header-button):not(:first-child){padding-right:0}.dataviews-view-table.has-compact-density td,.dataviews-view-table.has-compact-density th{padding:4px 8px}.dataviews-view-table.has-comfortable-density td,.dataviews-view-table.has-comfortable-density th{padding:16px 12px}.dataviews-view-table.has-comfortable-density td.dataviews-view-table__checkbox-column,.dataviews-view-table.has-comfortable-density th.dataviews-view-table__checkbox-column,.dataviews-view-table.has-compact-density td.dataviews-view-table__checkbox-column,.dataviews-view-table.has-compact-density th.dataviews-view-table__checkbox-column{padding-left:0}@container (max-width: 430px){.dataviews-view-table tr td:first-child,.dataviews-view-table tr th:first-child{padding-right:24px}.dataviews-view-table tr td:last-child,.dataviews-view-table tr th:last-child{padding-left:24px}}.dataviews-view-table-selection-checkbox{--checkbox-input-size:24px}@media(min-width:600px){.dataviews-view-table-selection-checkbox{--checkbox-input-size:16px}}.dataviews-column-primary__media{max-width:60px}.dataviews-controls__datetime{border:none;padding:0}.dataforms-layouts-panel__field{align-items:flex-start!important;justify-content:flex-start!important;min-height:32px;width:100%}.dataforms-layouts-panel__field-label{align-items:center;display:flex;flex-shrink:0;hyphens:auto;line-height:20px;min-height:32px;padding:6px 0;width:38%}.dataforms-layouts-panel__field-control{align-items:center;display:flex;flex-grow:1;min-height:32px}.dataforms-layouts-panel__field-control .components-button{max-width:100%;min-height:32px;text-align:right;text-wrap:balance;text-wrap:pretty;white-space:normal}.dataforms-layouts-panel__field-control .components-dropdown{max-width:100%}.dataforms-layouts-panel__field-dropdown .components-popover__content{min-width:320px;padding:16px}.dataforms-layouts-panel__dropdown-header{margin-bottom:16px}.components-popover.components-dropdown__content.dataforms-layouts-panel__field-dropdown{z-index:159990}.dataforms-layouts-regular__field{align-items:flex-start!important;justify-content:flex-start!important;min-height:32px;width:100%}.dataforms-layouts-regular__field .components-base-control__label{font-size:inherit;font-weight:400;text-transform:none}.dataforms-layouts-regular__field-label{align-items:center;display:flex;flex-shrink:0;hyphens:auto;line-height:20px;min-height:32px;padding:6px 0;width:38%}.dataforms-layouts-regular__field-control{align-items:center;display:flex;flex-grow:1;min-height:32px}:root{--wp-admin-theme-color:#3858e9;--wp-admin-theme-color--rgb:56,88,233;--wp-admin-theme-color-darker-10:#2145e6;--wp-admin-theme-color-darker-10--rgb:33,69,230;--wp-admin-theme-color-darker-20:#183ad6;--wp-admin-theme-color-darker-20--rgb:24,58,214;--wp-admin-border-width-focus:2px}@media(min-resolution:192dpi){:root{--wp-admin-border-width-focus:1.5px}}@media not (prefers-reduced-motion){.components-animate__appear{animation:components-animate__appear-animation .1s cubic-bezier(0,0,.2,1) 0s;animation-fill-mode:forwards}}.components-animate__appear.is-from-top,.components-animate__appear.is-from-top.is-from-left{transform-origin:top right}.components-animate__appear.is-from-top.is-from-right{transform-origin:top left}.components-animate__appear.is-from-bottom,.components-animate__appear.is-from-bottom.is-from-left{transform-origin:bottom right}.components-animate__appear.is-from-bottom.is-from-right{transform-origin:bottom left}@keyframes components-animate__appear-animation{0%{transform:translateY(-2em) scaleY(0) scaleX(0)}to{transform:translateY(0) scaleY(1) scaleX(1)}}@media not (prefers-reduced-motion){.components-animate__slide-in{animation:components-animate__slide-in-animation .1s cubic-bezier(0,0,.2,1);animation-fill-mode:forwards}.components-animate__slide-in.is-from-left{transform:translateX(-100%)}.components-animate__slide-in.is-from-right{transform:translateX(100%)}}@keyframes components-animate__slide-in-animation{to{transform:translateX(0)}}@media not (prefers-reduced-motion){.components-animate__loading{animation:components-animate__loading 1.6s ease-in-out infinite}}@keyframes components-animate__loading{0%{opacity:.5}50%{opacity:1}to{opacity:.5}}.components-autocomplete__popover .components-popover__content{min-width:200px;padding:8px}.components-autocomplete__result.components-button{display:flex;height:auto;min-height:36px;text-align:right;width:100%}.components-autocomplete__result.components-button:focus:not(:disabled){box-shadow:inset 0 0 0 1px #fff,0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.components-badge{align-items:center;background-color:color-mix(in srgb,#fff 90%,var(--base-color));border-radius:2px;box-sizing:border-box;color:color-mix(in srgb,#000 50%,var(--base-color));display:inline-flex;font-size:12px;font-weight:400;gap:2px;line-height:20px;max-width:100%;min-height:24px;padding:0 8px}.components-badge *,.components-badge :after,.components-badge :before{box-sizing:inherit}.components-badge:where(.is-default){background-color:#f0f0f0;color:#2f2f2f}.components-badge.has-icon{padding-inline-start:4px}.components-badge.is-info{--base-color:#3858e9}.components-badge.is-warning{--base-color:#f0b849}.components-badge.is-error{--base-color:#cc1818}.components-badge.is-success{--base-color:#4ab866}.components-badge__icon{flex-shrink:0}.components-badge__content{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.components-button-group{display:inline-block}.components-button-group .components-button{border-radius:0;box-shadow:inset 0 0 0 1px #1e1e1e;color:#1e1e1e;display:inline-flex}.components-button-group .components-button+.components-button{margin-right:-1px}.components-button-group .components-button:first-child{border-radius:0 2px 2px 0}.components-button-group .components-button:last-child{border-radius:2px 0 0 2px}.components-button-group .components-button.is-primary,.components-button-group .components-button:focus{position:relative;z-index:1}.components-button-group .components-button.is-primary{box-shadow:inset 0 0 0 1px #1e1e1e}.components-button{align-items:center;-webkit-appearance:none;background:none;border:0;border-radius:2px;box-sizing:border-box;color:var(--wp-components-color-foreground,#1e1e1e);cursor:pointer;display:inline-flex;font-family:inherit;font-size:13px;height:36px;margin:0;padding:6px 12px;text-decoration:none}@media not (prefers-reduced-motion){.components-button{transition:box-shadow .1s linear}}.components-button.is-next-40px-default-size{height:40px}.components-button:hover:not(:disabled,[aria-disabled=true]),.components-button[aria-expanded=true]{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button:focus:not(:disabled){box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:3px solid transparent}.components-button.is-primary{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:var(--wp-components-color-accent-inverted,#fff);outline:1px solid transparent;text-decoration:none;text-shadow:none;white-space:nowrap}.components-button.is-primary:hover:not(:disabled){background:var(--wp-components-color-accent-darker-10,var(--wp-admin-theme-color-darker-10,#2145e6));color:var(--wp-components-color-accent-inverted,#fff)}.components-button.is-primary:active:not(:disabled){background:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6));border-color:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6));color:var(--wp-components-color-accent-inverted,#fff)}.components-button.is-primary:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--wp-components-color-background,#fff),0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button.is-primary:disabled,.components-button.is-primary:disabled:active:enabled,.components-button.is-primary[aria-disabled=true],.components-button.is-primary[aria-disabled=true]:active:enabled,.components-button.is-primary[aria-disabled=true]:enabled{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:hsla(0,0%,100%,.4);outline:none}.components-button.is-primary:disabled:active:enabled:focus:enabled,.components-button.is-primary:disabled:focus:enabled,.components-button.is-primary[aria-disabled=true]:active:enabled:focus:enabled,.components-button.is-primary[aria-disabled=true]:enabled:focus:enabled,.components-button.is-primary[aria-disabled=true]:focus:enabled{box-shadow:inset 0 0 0 1px var(--wp-components-color-background,#fff),0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button.is-primary.is-busy,.components-button.is-primary.is-busy:disabled,.components-button.is-primary.is-busy[aria-disabled=true]{background-image:linear-gradient(45deg,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 33%,var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6)) 33%,var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6)) 70%,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 70%);background-size:100px 100%;border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:var(--wp-components-color-accent-inverted,#fff)}.components-button.is-secondary,.components-button.is-tertiary{outline:1px solid transparent}.components-button.is-secondary:active:not(:disabled),.components-button.is-tertiary:active:not(:disabled){box-shadow:none}.components-button.is-secondary:disabled,.components-button.is-secondary[aria-disabled=true],.components-button.is-secondary[aria-disabled=true]:hover,.components-button.is-tertiary:disabled,.components-button.is-tertiary[aria-disabled=true],.components-button.is-tertiary[aria-disabled=true]:hover{background:transparent;color:#949494;transform:none}.components-button.is-secondary{background:transparent;box-shadow:inset 0 0 0 1px var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)),0 0 0 currentColor;color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:1px solid transparent;white-space:nowrap}.components-button.is-secondary:hover:not(:disabled,[aria-disabled=true],.is-pressed){background:color-mix(in srgb,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 4%,transparent);box-shadow:inset 0 0 0 1px var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6));color:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6))}.components-button.is-secondary:disabled:not(:focus),.components-button.is-secondary[aria-disabled=true]:hover:not(:focus),.components-button.is-secondary[aria-disabled=true]:not(:focus){box-shadow:inset 0 0 0 1px #ddd}.components-button.is-secondary:focus:not(:disabled){box-shadow:0 0 0 currentColor inset,0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-button.is-tertiary{background:transparent;color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));white-space:nowrap}.components-button.is-tertiary:hover:not(:disabled,[aria-disabled=true]){background:color-mix(in srgb,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 4%,transparent);color:var(--wp-components-color-accent-darker-20,var(--wp-admin-theme-color-darker-20,#183ad6))}.components-button.is-tertiary:active:not(:disabled,[aria-disabled=true]){background:color-mix(in srgb,var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)) 8%,transparent)}p+.components-button.is-tertiary{margin-right:-6px}.components-button.is-tertiary:disabled:not(:focus),.components-button.is-tertiary[aria-disabled=true]:hover:not(:focus),.components-button.is-tertiary[aria-disabled=true]:not(:focus){box-shadow:none;outline:none}.components-button.is-destructive{--wp-components-color-accent:#cc1818;--wp-components-color-accent-darker-10:#9e1313;--wp-components-color-accent-darker-20:#710d0d}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link){color:#cc1818}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):hover:not(:disabled,[aria-disabled=true]){color:#710d0d}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #cc1818}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):active:not(:disabled,[aria-disabled=true]){background:#ccc}.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link):disabled,.components-button.is-destructive:not(.is-primary):not(.is-secondary):not(.is-tertiary):not(.is-link)[aria-disabled=true]{color:#949494}.components-button.is-destructive.is-secondary:hover:not(:disabled,[aria-disabled=true]),.components-button.is-destructive.is-tertiary:hover:not(:disabled,[aria-disabled=true]){background:rgba(204,24,24,.04)}.components-button.is-destructive.is-secondary:active:not(:disabled,[aria-disabled=true]),.components-button.is-destructive.is-tertiary:active:not(:disabled,[aria-disabled=true]){background:rgba(204,24,24,.08)}.components-button.is-link{background:none;border:0;border-radius:0;box-shadow:none;color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));height:auto;margin:0;outline:none;padding:0;text-align:right;text-decoration:underline}@media not (prefers-reduced-motion){.components-button.is-link{transition-duration:.05s;transition-property:border,background,color;transition-timing-function:ease-in-out}}.components-button.is-link:focus{border-radius:2px}.components-button.is-link:disabled,.components-button.is-link[aria-disabled=true]{color:#949494}.components-button:not(:disabled,[aria-disabled=true]):active{color:var(--wp-components-color-foreground,#1e1e1e)}.components-button:disabled,.components-button[aria-disabled=true]{color:#949494;cursor:default}.components-button.is-busy,.components-button.is-secondary.is-busy,.components-button.is-secondary.is-busy:disabled,.components-button.is-secondary.is-busy[aria-disabled=true]{background-image:linear-gradient(45deg,#fafafa 33%,#e0e0e0 0,#e0e0e0 70%,#fafafa 0);background-size:100px 100%}@media not (prefers-reduced-motion){.components-button.is-busy,.components-button.is-secondary.is-busy,.components-button.is-secondary.is-busy:disabled,.components-button.is-secondary.is-busy[aria-disabled=true]{animation:components-button__busy-animation 2.5s linear infinite}}.components-button.is-compact{height:32px}.components-button.is-compact.has-icon:not(.has-text){min-width:32px;padding:0;width:32px}.components-button.is-small{font-size:11px;height:24px;line-height:22px;padding:0 8px}.components-button.is-small.has-icon:not(.has-text){min-width:24px;padding:0;width:24px}.components-button.has-icon{justify-content:center;min-width:36px;padding:6px}.components-button.has-icon.is-next-40px-default-size{min-width:40px}.components-button.has-icon .dashicon{align-items:center;box-sizing:content-box;display:inline-flex;justify-content:center;padding:2px}.components-button.has-icon.has-text{gap:4px;justify-content:start;padding-left:12px;padding-right:8px}.components-button.is-pressed,.components-button.is-pressed:hover{color:var(--wp-components-color-foreground-inverted,#fff)}.components-button.is-pressed:hover:not(:disabled,[aria-disabled=true]),.components-button.is-pressed:not(:disabled,[aria-disabled=true]){background:var(--wp-components-color-foreground,#1e1e1e)}.components-button.is-pressed:disabled,.components-button.is-pressed[aria-disabled=true]{color:#949494}.components-button.is-pressed:disabled:not(.is-primary):not(.is-secondary):not(.is-tertiary),.components-button.is-pressed[aria-disabled=true]:not(.is-primary):not(.is-secondary):not(.is-tertiary){background:#949494;color:var(--wp-components-color-foreground-inverted,#fff)}.components-button.is-pressed:focus:not(:disabled){box-shadow:inset 0 0 0 1px var(--wp-components-color-background,#fff),0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent}.components-button svg{fill:currentColor;outline:none}@media(forced-colors:active){.components-button svg{fill:CanvasText}}.components-button .components-visually-hidden{height:auto}@keyframes components-button__busy-animation{0%{background-position:200px 0}}.components-checkbox-control{--checkbox-input-size:24px;--checkbox-input-margin:8px}@media(min-width:600px){.components-checkbox-control{--checkbox-input-size:16px}}.components-checkbox-control__label{cursor:pointer;line-height:var(--checkbox-input-size)}.components-checkbox-control__input[type=checkbox]{appearance:none;background:#fff;border:1px solid #1e1e1e;border-radius:2px;box-shadow:0 0 0 transparent;clear:none;color:#1e1e1e;cursor:pointer;display:inline-block;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;height:var(--checkbox-input-size);line-height:normal;line-height:0;margin:0 0 0 4px;outline:0;padding:6px 8px;padding:0!important;text-align:center;transition:none;vertical-align:top;width:var(--checkbox-input-size)}@media not (prefers-reduced-motion){.components-checkbox-control__input[type=checkbox]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-checkbox-control__input[type=checkbox]{font-size:13px;line-height:normal}}.components-checkbox-control__input[type=checkbox]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-checkbox-control__input[type=checkbox]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-checkbox-control__input[type=checkbox]:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-checkbox-control__input[type=checkbox]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox]:checked{background:var(--wp-admin-theme-color);border-color:var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox]:checked::-ms-check{opacity:0}.components-checkbox-control__input[type=checkbox]:checked:before,.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{color:#fff;margin:-3px -5px}@media(min-width:782px){.components-checkbox-control__input[type=checkbox]:checked:before,.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{margin:-4px -5px 0 0}}.components-checkbox-control__input[type=checkbox][aria-checked=mixed]{background:var(--wp-admin-theme-color);border-color:var(--wp-admin-theme-color)}.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{content:"";display:inline-block;float:right;font:normal 30px/1 dashicons;vertical-align:middle;width:16px;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}@media(min-width:782px){.components-checkbox-control__input[type=checkbox][aria-checked=mixed]:before{float:none;font-size:21px}}.components-checkbox-control__input[type=checkbox]:disabled,.components-checkbox-control__input[type=checkbox][aria-disabled=true]{background:#f0f0f0;border-color:#ddd;cursor:default;opacity:1}@media not (prefers-reduced-motion){.components-checkbox-control__input[type=checkbox]{transition:border-color .1s ease-in-out}}.components-checkbox-control__input[type=checkbox]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 0 calc(var(--wp-admin-border-width-focus)*2) var(--wp-admin-theme-color);outline:2px solid transparent;outline-offset:2px}.components-checkbox-control__input[type=checkbox]:checked,.components-checkbox-control__input[type=checkbox]:indeterminate{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-checkbox-control__input[type=checkbox]:checked::-ms-check,.components-checkbox-control__input[type=checkbox]:indeterminate::-ms-check{opacity:0}.components-checkbox-control__input[type=checkbox]:checked:before{content:none}.components-checkbox-control__input-container{aspect-ratio:1;display:inline-block;flex-shrink:0;line-height:1;margin-left:var(--checkbox-input-margin);position:relative;vertical-align:middle;width:var(--checkbox-input-size)}svg.components-checkbox-control__checked,svg.components-checkbox-control__indeterminate{--checkmark-size:var(--checkbox-input-size);fill:#fff;cursor:pointer;height:var(--checkmark-size);pointer-events:none;position:absolute;right:50%;top:50%;transform:translate(50%,-50%);-webkit-user-select:none;user-select:none;width:var(--checkmark-size)}@media(min-width:600px){svg.components-checkbox-control__checked,svg.components-checkbox-control__indeterminate{--checkmark-size:calc(var(--checkbox-input-size) + 4px)}}.components-checkbox-control__help{display:inline-block;margin-inline-start:calc(var(--checkbox-input-size) + var(--checkbox-input-margin))}.components-circular-option-picker{display:inline-block;min-width:188px;width:100%}.components-circular-option-picker .components-circular-option-picker__custom-clear-wrapper{display:flex;justify-content:flex-end;margin-top:12px}.components-circular-option-picker .components-circular-option-picker__swatches{display:flex;flex-wrap:wrap;gap:12px;position:relative;z-index:1}.components-circular-option-picker>:not(.components-circular-option-picker__swatches){position:relative;z-index:0}.components-circular-option-picker__option-wrapper{display:inline-block;height:28px;transform:scale(1);vertical-align:top;width:28px}@media not (prefers-reduced-motion){.components-circular-option-picker__option-wrapper{transition:transform .1s ease;will-change:transform}}.components-circular-option-picker__option-wrapper:hover{transform:scale(1.2)}.components-circular-option-picker__option-wrapper>div{height:100%;width:100%}.components-circular-option-picker__option-wrapper:before{background:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' fill='none'%3E%3Cpath fill='%23555D65' d='M6 8V6H4v2zm2 0V6h2v2zm2 8H8v-2h2zm2 0v-2h2v2zm0 2v-2h-2v2H8v2h2v-2zm2 0v2h-2v-2zm2 0h-2v-2h2z'/%3E%3Cpath fill='%23555D65' fill-rule='evenodd' d='M18 18h2v-2h-2v-2h2v-2h-2v-2h2V8h-2v2h-2V8h-2v2h2v2h-2v2h2v2h2zm-2-4v-2h2v2z' clip-rule='evenodd'/%3E%3Cpath fill='%23555D65' d='M18 18v2h-2v-2z'/%3E%3Cpath fill='%23555D65' fill-rule='evenodd' d='M8 10V8H6v2H4v2h2v2H4v2h2v2H4v2h2v2H4v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h2V4h-2v2h-2V4h-2v2h-2V4h-2v2h-2V4h-2v2h2v2h-2v2zm0 2v-2H6v2zm2 0v-2h2v2zm0 2v-2H8v2H6v2h2v2H6v2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h-2v2h-2V6h-2v2h-2v2h2v2h-2v2z' clip-rule='evenodd'/%3E%3Cpath fill='%23555D65' fill-rule='evenodd' d='M4 0H2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v2H0v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h2V4h-2V2h2V0h-2v2h-2V0h-2v2h-2V0h-2v2h-2V0h-2v2h-2V0h-2v2H8V0H6v2H4zm0 4V2H2v2zm2 0V2h2v2zm0 2V4H4v2H2v2h2v2H2v2h2v2H2v2h2v2H2v2h2v2H2v2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h2v2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2v-2h-2v-2h2V8h-2V6h2V4h-2V2h-2v2h-2V2h-2v2h-2V2h-2v2h-2V2h-2v2H8v2z' clip-rule='evenodd'/%3E%3C/svg%3E");border-radius:50%;bottom:1px;content:"";left:1px;position:absolute;right:1px;top:1px;z-index:-1}.components-circular-option-picker__option{aspect-ratio:1;background:transparent;border:none;border-radius:50%;box-shadow:inset 0 0 0 14px;cursor:pointer;display:inline-block;height:100%!important;vertical-align:top}@media not (prefers-reduced-motion){.components-circular-option-picker__option{transition:box-shadow .1s ease}}.components-circular-option-picker__option:hover{box-shadow:inset 0 0 0 14px!important}.components-circular-option-picker__option[aria-pressed=true],.components-circular-option-picker__option[aria-selected=true]{box-shadow:inset 0 0 0 4px;overflow:visible;position:relative;z-index:1}.components-circular-option-picker__option[aria-pressed=true]+svg,.components-circular-option-picker__option[aria-selected=true]+svg{border-radius:50%;pointer-events:none;position:absolute;right:2px;top:2px;z-index:2}.components-circular-option-picker__option:after{border:1px solid transparent;border-radius:50%;bottom:-1px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.2);box-sizing:inherit;content:"";left:-1px;position:absolute;right:-1px;top:-1px}.components-circular-option-picker__option:focus:after{border:2px solid #757575;border-radius:50%;box-shadow:inset 0 0 0 2px #fff;content:"";height:calc(100% + 4px);position:absolute;right:50%;top:50%;transform:translate(50%,-50%);width:calc(100% + 4px)}.components-circular-option-picker__option.components-button:focus{background-color:transparent;box-shadow:inset 0 0 0 14px;outline:none}.components-circular-option-picker__button-action .components-circular-option-picker__option{background:#fff;color:#fff}.components-circular-option-picker__dropdown-link-action{margin-left:16px}.components-circular-option-picker__dropdown-link-action .components-button{line-height:22px}.components-palette-edit__popover-gradient-picker{padding:8px;width:260px}.components-dropdown-menu__menu .components-palette-edit__menu-button{width:100%}.component-color-indicator{background:#fff linear-gradient(45deg,transparent 48%,#ddd 0,#ddd 52%,transparent 0);border-radius:50%;box-shadow:inset 0 0 0 1px rgba(0,0,0,.2);display:inline-block;height:20px;padding:0;width:20px}.components-combobox-control{width:100%}input.components-combobox-control__input[type=text]{border:none;box-shadow:none;font-family:inherit;font-size:16px;line-height:inherit;margin:0;min-height:auto;padding:2px;width:100%}@media(min-width:600px){input.components-combobox-control__input[type=text]{font-size:13px}}input.components-combobox-control__input[type=text]:focus{box-shadow:none;outline:none}.components-combobox-control__suggestions-container{align-items:flex-start;border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;display:flex;flex-wrap:wrap;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;line-height:normal;padding:0;width:100%}@media not (prefers-reduced-motion){.components-combobox-control__suggestions-container{transition:box-shadow .1s linear}}@media(min-width:600px){.components-combobox-control__suggestions-container{font-size:13px;line-height:normal}}.components-combobox-control__suggestions-container:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-combobox-control__suggestions-container::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-combobox-control__suggestions-container::-moz-placeholder{color:rgba(30,30,30,.62)}.components-combobox-control__suggestions-container:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-combobox-control__suggestions-container:focus-within{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-combobox-control__suggestions-container .components-spinner{margin:0}.components-color-palette__custom-color-wrapper{position:relative;z-index:0}.components-color-palette__custom-color-button{background:none;border:none;border-radius:4px 4px 0 0;box-shadow:inset 0 0 0 1px rgba(0,0,0,.2);box-sizing:border-box;cursor:pointer;height:64px;outline:1px solid transparent;position:relative;width:100%}.components-color-palette__custom-color-button:focus{box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline-width:2px}.components-color-palette__custom-color-button:after{background-image:repeating-linear-gradient(-45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(-45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:100% 0,24px 24px;background-size:48px 48px;border-radius:3px 3px 0 0;content:"";inset:1px;position:absolute;z-index:-1}.components-color-palette__custom-color-text-wrapper{border-radius:0 0 4px 4px;box-shadow:inset 0 -1px 0 0 rgba(0,0,0,.2),inset -1px 0 0 0 rgba(0,0,0,.2),inset 1px 0 0 0 rgba(0,0,0,.2);font-size:13px;padding:12px 16px;position:relative}.components-color-palette__custom-color-name{color:var(--wp-components-color-foreground,#1e1e1e);margin:0 1px}.components-color-palette__custom-color-value{color:#757575}.components-color-palette__custom-color-value--is-hex{text-transform:uppercase}.components-color-palette__custom-color-value:empty:after{content:"​";visibility:hidden}.components-custom-gradient-picker__gradient-bar{border-radius:2px;height:48px;position:relative;width:100%;z-index:1}.components-custom-gradient-picker__gradient-bar.has-gradient{background-image:repeating-linear-gradient(-45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(-45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:100% 0,12px 12px;background-size:24px 24px}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__gradient-bar-background{inset:0;position:absolute}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__markers-container{margin-left:auto;margin-right:auto;position:relative;width:calc(100% - 48px)}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-dropdown{display:flex;height:16px;position:absolute;top:16px;width:16px}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__insert-point-dropdown{background:#fff;border-radius:50%;color:#1e1e1e;height:inherit;min-width:16px!important;padding:2px;position:relative;width:inherit}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__insert-point-dropdown svg{height:100%;width:100%}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-button{border-radius:50%;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 2px 0 rgba(0,0,0,.25);height:inherit;outline:2px solid transparent;padding:0;width:inherit}.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-button.is-active,.components-custom-gradient-picker__gradient-bar .components-custom-gradient-picker__control-point-button:focus{box-shadow:inset 0 0 0 calc(var(--wp-admin-border-width-focus)*2) #fff,0 0 2px 0 rgba(0,0,0,.25);outline:1.5px solid transparent}.components-custom-gradient-picker__remove-control-point-wrapper{padding-bottom:8px}.components-custom-gradient-picker__inserter{direction:rtl}.components-custom-gradient-picker__liner-gradient-indicator{display:inline-block;flex:0 auto;height:20px;width:20px}.components-custom-gradient-picker__ui-line{position:relative;z-index:0}.block-editor-dimension-control .components-base-control__field{align-items:center;display:flex}.block-editor-dimension-control .components-base-control__label{align-items:center;display:flex;margin-bottom:0;margin-left:1em}.block-editor-dimension-control .components-base-control__label .dashicon{margin-left:.5em}.block-editor-dimension-control.is-manual .components-base-control__label{width:10em}body.is-dragging-components-draggable{cursor:move;cursor:grabbing!important}.components-draggable__invisible-drag-image{height:50px;position:fixed;right:-1000px;width:50px}.components-draggable__clone{background:transparent;padding:0;pointer-events:none;position:fixed;z-index:1000000000}.components-drop-zone{border-radius:2px;bottom:0;left:0;opacity:0;position:absolute;right:0;top:0;visibility:hidden;z-index:40}.components-drop-zone.is-active{opacity:1;visibility:visible}.components-drop-zone .components-drop-zone__content{align-items:center;background-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));bottom:0;color:#fff;display:flex;height:100%;justify-content:center;left:0;opacity:0;pointer-events:none;position:absolute;right:0;text-align:center;top:0;width:100%;z-index:50}.components-drop-zone .components-drop-zone__content-inner{opacity:0;transform:scale(.9)}.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content{opacity:1}@media not (prefers-reduced-motion){.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content{transition:opacity .2s ease-in-out}}.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content-inner{opacity:1;transform:scale(1)}@media not (prefers-reduced-motion){.components-drop-zone.is-active.is-dragging-over-element .components-drop-zone__content-inner{transition:opacity .1s ease-in-out .1s,transform .1s ease-in-out .1s}}.components-drop-zone__content-icon,.components-drop-zone__content-text{display:block}.components-drop-zone__content-icon{line-height:0;margin:0 auto 8px;fill:currentColor;pointer-events:none}.components-drop-zone__content-text{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px}.components-dropdown{display:inline-block}.components-dropdown__content .components-popover__content{padding:8px}.components-dropdown__content .components-popover__content:has(.components-menu-group){padding:0}.components-dropdown__content .components-popover__content:has(.components-menu-group) .components-dropdown-menu__menu>.components-menu-item__button,.components-dropdown__content .components-popover__content:has(.components-menu-group)>.components-menu-item__button{margin:8px;width:auto}.components-dropdown__content [role=menuitem]{white-space:nowrap}.components-dropdown__content .components-menu-group{padding:8px}.components-dropdown__content .components-menu-group+.components-menu-group{border-top:1px solid #ccc;padding:8px}.components-dropdown__content.is-alternate .components-menu-group+.components-menu-group{border-color:#1e1e1e}.components-dropdown-menu__toggle{vertical-align:top}.components-dropdown-menu__menu{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;line-height:1.4;width:100%}.components-dropdown-menu__menu .components-dropdown-menu__menu-item,.components-dropdown-menu__menu .components-menu-item{cursor:pointer;outline:none;padding:6px;white-space:nowrap;width:100%}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.has-separator,.components-dropdown-menu__menu .components-menu-item.has-separator{margin-top:6px;overflow:visible;position:relative}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.has-separator:before,.components-dropdown-menu__menu .components-menu-item.has-separator:before{background-color:#ddd;box-sizing:content-box;content:"";display:block;height:1px;left:0;position:absolute;right:0;top:-3px}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.is-active .dashicon,.components-dropdown-menu__menu .components-dropdown-menu__menu-item.is-active svg,.components-dropdown-menu__menu .components-menu-item.is-active .dashicon,.components-dropdown-menu__menu .components-menu-item.is-active svg{background:#1e1e1e;border-radius:1px;box-shadow:0 0 0 1px #1e1e1e;color:#fff}.components-dropdown-menu__menu .components-dropdown-menu__menu-item.is-icon-only,.components-dropdown-menu__menu .components-menu-item.is-icon-only{width:auto}.components-dropdown-menu__menu .components-menu-item__button,.components-dropdown-menu__menu .components-menu-item__button.components-button{height:auto;min-height:40px;padding-left:8px;padding-right:8px;text-align:right}.components-duotone-picker__color-indicator:before{background:transparent}.components-duotone-picker__color-indicator>.components-button,.components-duotone-picker__color-indicator>.components-button.is-pressed:hover:not(:disabled){background:linear-gradient(45deg,transparent 48%,#ddd 0,#ddd 52%,transparent 0);color:transparent}.components-duotone-picker__color-indicator>.components-button:not([aria-disabled=true]):active{color:transparent}.components-color-list-picker,.components-color-list-picker__swatch-button{width:100%}.components-color-list-picker__color-picker{margin:8px 0}.components-color-list-picker__swatch-color{margin:2px}.components-external-link{text-decoration:none}.components-external-link__contents{text-decoration:underline}.components-external-link__icon{font-weight:400;margin-right:.5ch}.components-form-toggle{display:inline-block;height:16px;position:relative}.components-form-toggle .components-form-toggle__track{background-color:#fff;border:1px solid #949494;border-radius:8px;box-sizing:border-box;content:"";display:inline-block;height:16px;overflow:hidden;position:relative;vertical-align:top;width:32px}@media not (prefers-reduced-motion){.components-form-toggle .components-form-toggle__track{transition:background-color .2s ease,border-color .2s ease}}.components-form-toggle .components-form-toggle__track:after{border-top:16px solid transparent;box-sizing:border-box;content:"";inset:0;opacity:0;position:absolute}@media not (prefers-reduced-motion){.components-form-toggle .components-form-toggle__track:after{transition:opacity .2s ease}}.components-form-toggle .components-form-toggle__thumb{background-color:#1e1e1e;border:6px solid transparent;border-radius:50%;box-shadow:0 1px 1px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.02),0 3px 3px rgba(0,0,0,.02),0 4px 4px rgba(0,0,0,.01);box-sizing:border-box;display:block;height:12px;position:absolute;right:2px;top:2px;width:12px}@media not (prefers-reduced-motion){.components-form-toggle .components-form-toggle__thumb{transition:transform .2s ease,background-color .2s ease-out}}.components-form-toggle.is-checked .components-form-toggle__track{background-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-form-toggle.is-checked .components-form-toggle__track:after{opacity:1}.components-form-toggle .components-form-toggle__input:focus+.components-form-toggle__track{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 0 calc(var(--wp-admin-border-width-focus)*2) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent;outline-offset:2px}.components-form-toggle.is-checked .components-form-toggle__thumb{background-color:#fff;border-width:0;transform:translateX(-16px)}.components-disabled .components-form-toggle,.components-form-toggle.is-disabled{opacity:.3}.components-form-toggle input.components-form-toggle__input[type=checkbox]{border:none;height:100%;margin:0;opacity:0;padding:0;position:absolute;right:0;top:0;width:100%;z-index:1}.components-form-toggle input.components-form-toggle__input[type=checkbox]:checked{background:none}.components-form-toggle input.components-form-toggle__input[type=checkbox]:before{content:""}.components-form-toggle input.components-form-toggle__input[type=checkbox]:not(:disabled,[aria-disabled=true]){cursor:pointer}.components-form-token-field__input-container{border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;cursor:text;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;line-height:normal;padding:0;width:100%}@media not (prefers-reduced-motion){.components-form-token-field__input-container{transition:box-shadow .1s linear}}@media(min-width:600px){.components-form-token-field__input-container{font-size:13px;line-height:normal}}.components-form-token-field__input-container:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-form-token-field__input-container::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-form-token-field__input-container::-moz-placeholder{color:rgba(30,30,30,.62)}.components-form-token-field__input-container:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-form-token-field__input-container.is-disabled{background:#ddd;border-color:#ddd}.components-form-token-field__input-container.is-active{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-form-token-field__input-container input[type=text].components-form-token-field__input{background:inherit;border:0;box-shadow:none;color:#1e1e1e;display:inline-block;flex:1;font-family:inherit;font-size:16px;margin-right:4px;max-width:100%;min-height:24px;min-width:50px;padding:0;width:100%}@media(min-width:600px){.components-form-token-field__input-container input[type=text].components-form-token-field__input{font-size:13px}}.components-form-token-field.is-active .components-form-token-field__input-container input[type=text].components-form-token-field__input,.components-form-token-field__input-container input[type=text].components-form-token-field__input:focus{box-shadow:none;outline:none}.components-form-token-field__input-container .components-form-token-field__token+input[type=text].components-form-token-field__input{width:auto}.components-form-token-field__token{color:#1e1e1e;display:flex;font-size:13px;max-width:100%}.components-form-token-field__token.is-success .components-form-token-field__remove-token,.components-form-token-field__token.is-success .components-form-token-field__token-text{background:#4ab866}.components-form-token-field__token.is-error .components-form-token-field__remove-token,.components-form-token-field__token.is-error .components-form-token-field__token-text{background:#cc1818}.components-form-token-field__token.is-validating .components-form-token-field__remove-token,.components-form-token-field__token.is-validating .components-form-token-field__token-text{color:#757575}.components-form-token-field__token.is-borderless{padding:0 0 0 24px;position:relative}.components-form-token-field__token.is-borderless .components-form-token-field__token-text{background:transparent}.components-form-token-field__token.is-borderless:not(.is-disabled) .components-form-token-field__token-text{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-form-token-field__token.is-borderless .components-form-token-field__remove-token{background:transparent;color:#757575;left:0;position:absolute;top:1px}.components-form-token-field__token.is-borderless.is-success .components-form-token-field__token-text{color:#4ab866}.components-form-token-field__token.is-borderless.is-error .components-form-token-field__token-text{color:#cc1818;padding:0 6px 0 4px}.components-form-token-field__token.is-borderless.is-validating .components-form-token-field__token-text{color:#1e1e1e}.components-form-token-field__remove-token.components-button,.components-form-token-field__token-text{background:#ddd;display:inline-block;height:auto;min-width:unset}@media not (prefers-reduced-motion){.components-form-token-field__remove-token.components-button,.components-form-token-field__token-text{transition:all .2s cubic-bezier(.4,1,.4,1)}}.components-form-token-field__token-text{border-radius:0 1px 1px 0;line-height:24px;overflow:hidden;padding:0 8px 0 0;text-overflow:ellipsis;white-space:nowrap}.components-form-token-field__remove-token.components-button{border-radius:1px 0 0 1px;color:#1e1e1e;line-height:10px;overflow:initial}.components-form-token-field__remove-token.components-button:hover:not(:disabled){color:#1e1e1e}.components-form-token-field__suggestions-list{box-shadow:inset 0 1px 0 0 #949494;flex:1 0 100%;list-style:none;margin:0;max-height:128px;min-width:100%;overflow-y:auto;padding:0}@media not (prefers-reduced-motion){.components-form-token-field__suggestions-list{transition:all .15s ease-in-out}}.components-form-token-field__suggestion{box-sizing:border-box;color:#1e1e1e;display:block;font-size:13px;margin:0;min-height:32px;padding:8px 12px}.components-form-token-field__suggestion.is-selected{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:#fff}.components-form-token-field__suggestion[aria-disabled=true]{color:#949494;pointer-events:none}.components-form-token-field__suggestion[aria-disabled=true].is-selected{background-color:rgba(var(--wp-components-color-accent--rgb,var(--wp-admin-theme-color--rgb)),.04)}.components-form-token-field__suggestion:not(.is-empty){cursor:pointer}@media(min-width:600px){.components-guide{width:600px}}.components-guide .components-modal__content{margin-top:0;padding:0}.components-guide .components-modal__content:before{content:none}.components-guide .components-modal__header{border-bottom:none;height:60px;padding:0;position:sticky}.components-guide .components-modal__header .components-button{align-self:flex-start;margin:8px 0 0 8px;position:static}.components-guide .components-modal__header .components-button:hover svg{fill:#fff}.components-guide .components-guide__container{display:flex;flex-direction:column;justify-content:space-between;margin-top:-60px;min-height:100%}.components-guide .components-guide__page{display:flex;flex-direction:column;justify-content:center;position:relative}@media(min-width:600px){.components-guide .components-guide__page{min-height:300px}}.components-guide .components-guide__footer{align-content:center;display:flex;height:36px;justify-content:center;margin:0 0 24px;padding:0 32px;position:relative;width:100%}.components-guide .components-guide__page-control{margin:0;text-align:center}.components-guide .components-guide__page-control li{display:inline-block;margin:0}.components-guide .components-guide__page-control .components-button{color:#e0e0e0;margin:-6px 0}.components-guide .components-guide__page-control li[aria-current=step] .components-button{color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-modal__frame.components-guide{border:none;max-height:575px;min-width:312px}@media(max-width:600px){.components-modal__frame.components-guide{margin:auto;max-width:calc(100vw - 32px)}}.components-button.components-guide__back-button,.components-button.components-guide__finish-button,.components-button.components-guide__forward-button{position:absolute}.components-button.components-guide__back-button{right:32px}.components-button.components-guide__finish-button,.components-button.components-guide__forward-button{left:32px}[role=region]{position:relative}[role=region].interface-interface-skeleton__content:focus-visible:after{bottom:0;content:"";left:0;outline-color:var(--wp-admin-theme-color);outline-offset:calc(var(--wp-admin-border-width-focus)*-2/var(--wp-block-editor-iframe-zoom-out-scale, 1));outline-style:solid;outline-width:calc(var(--wp-admin-border-width-focus)*2/var(--wp-block-editor-iframe-zoom-out-scale, 1));pointer-events:none;position:absolute;right:0;top:0;z-index:1000000}.is-focusing-regions [role=region]:focus:after{bottom:0;content:"";left:0;pointer-events:none;position:absolute;right:0;top:0;z-index:1000000}.is-focusing-regions .editor-post-publish-panel,.is-focusing-regions .interface-interface-skeleton__actions .editor-layout__toggle-entities-saved-states-panel,.is-focusing-regions .interface-interface-skeleton__actions .editor-layout__toggle-publish-panel,.is-focusing-regions .interface-interface-skeleton__sidebar .editor-layout__toggle-sidebar-panel,.is-focusing-regions [role=region]:focus:after,.is-focusing-regions.is-distraction-free .interface-interface-skeleton__header .edit-post-header{outline-color:var(--wp-admin-theme-color);outline-offset:calc(var(--wp-admin-border-width-focus)*-2/var(--wp-block-editor-iframe-zoom-out-scale, 1));outline-style:solid;outline-width:calc(var(--wp-admin-border-width-focus)*2/var(--wp-block-editor-iframe-zoom-out-scale, 1))}.components-menu-group+.components-menu-group{border-top:1px solid #1e1e1e;padding-top:8px}.components-menu-group+.components-menu-group.has-hidden-separator{border-top:none;margin-top:0;padding-top:0}.components-menu-group:has(>div:empty){display:none}.components-menu-group__label{color:#757575;font-size:11px;font-weight:500;margin-bottom:12px;margin-top:4px;padding:0 8px;text-transform:uppercase;white-space:nowrap}.components-menu-item__button,.components-menu-item__button.components-button{width:100%}.components-menu-item__button.components-button[role=menuitemcheckbox] .components-menu-item__item:only-child,.components-menu-item__button.components-button[role=menuitemradio] .components-menu-item__item:only-child,.components-menu-item__button[role=menuitemcheckbox] .components-menu-item__item:only-child,.components-menu-item__button[role=menuitemradio] .components-menu-item__item:only-child{box-sizing:initial;padding-left:48px}.components-menu-item__button .components-menu-items__item-icon,.components-menu-item__button.components-button .components-menu-items__item-icon{display:inline-block;flex:0 0 auto}.components-menu-item__button .components-menu-items__item-icon.has-icon-right,.components-menu-item__button.components-button .components-menu-items__item-icon.has-icon-right{margin-left:-2px;margin-right:24px}.components-menu-item__button .components-menu-item__shortcut+.components-menu-items__item-icon.has-icon-right,.components-menu-item__button.components-button .components-menu-item__shortcut+.components-menu-items__item-icon.has-icon-right{margin-right:8px}.components-menu-item__button .block-editor-block-icon,.components-menu-item__button.components-button .block-editor-block-icon{margin-left:8px;margin-right:-2px}.components-menu-item__button.components-button.is-primary,.components-menu-item__button.is-primary{justify-content:center}.components-menu-item__button.components-button.is-primary .components-menu-item__item,.components-menu-item__button.is-primary .components-menu-item__item{margin-left:0}.components-menu-item__button.components-button:disabled.is-tertiary,.components-menu-item__button.components-button[aria-disabled=true].is-tertiary,.components-menu-item__button:disabled.is-tertiary,.components-menu-item__button[aria-disabled=true].is-tertiary{background:none;color:var(--wp-components-color-accent-darker-10,var(--wp-admin-theme-color-darker-10,#2145e6));opacity:.3}.components-menu-item__info-wrapper{display:flex;flex-direction:column;margin-left:auto}.components-menu-item__info{color:#757575;font-size:12px;margin-top:4px;white-space:normal}.components-menu-item__item{align-items:center;display:inline-flex;margin-left:auto;min-width:160px;white-space:nowrap}.components-menu-item__shortcut{align-self:center;color:currentColor;display:none;margin-left:0;margin-right:auto;padding-right:24px}@media(min-width:480px){.components-menu-item__shortcut{display:inline}}.components-menu-items-choice,.components-menu-items-choice.components-button{height:auto;min-height:40px}.components-menu-items-choice svg,.components-menu-items-choice.components-button svg{margin-left:12px}.components-menu-items-choice.components-button.has-icon,.components-menu-items-choice.has-icon{padding-right:12px}.components-modal__screen-overlay{background-color:rgba(0,0,0,.35);bottom:0;display:flex;left:0;position:fixed;right:0;top:0;z-index:100000}@keyframes __wp-base-styles-fade-in{0%{opacity:0}to{opacity:1}}@media not (prefers-reduced-motion){.components-modal__screen-overlay{animation:__wp-base-styles-fade-in .08s linear 0s;animation-fill-mode:forwards}}@keyframes __wp-base-styles-fade-out{0%{opacity:1}to{opacity:0}}@media not (prefers-reduced-motion){.components-modal__screen-overlay.is-animating-out{animation:__wp-base-styles-fade-out .08s linear 80ms;animation-fill-mode:forwards}}.components-modal__frame{animation-fill-mode:forwards;animation-name:components-modal__appear-animation;animation-timing-function:cubic-bezier(.29,0,0,1);background:#fff;border-radius:8px 8px 0 0;box-shadow:0 5px 15px rgba(0,0,0,.08),0 15px 27px rgba(0,0,0,.07),0 30px 36px rgba(0,0,0,.04),0 50px 43px rgba(0,0,0,.02);box-sizing:border-box;display:flex;margin:40px 0 0;overflow:hidden;width:100%}.components-modal__frame *,.components-modal__frame :after,.components-modal__frame :before{box-sizing:inherit}@media not (prefers-reduced-motion){.components-modal__frame{animation-duration:var(--modal-frame-animation-duration)}}.components-modal__screen-overlay.is-animating-out .components-modal__frame{animation-name:components-modal__disappear-animation;animation-timing-function:cubic-bezier(1,0,.2,1)}@media(min-width:600px){.components-modal__frame{border-radius:8px;margin:auto;max-height:calc(100% - 120px);max-width:calc(100% - 32px);min-width:350px;width:auto}}@media(min-width:600px)and (min-width:600px){.components-modal__frame.is-full-screen{height:calc(100% - 32px);max-height:none;width:calc(100% - 32px)}}@media(min-width:600px)and (min-width:782px){.components-modal__frame.is-full-screen{height:calc(100% - 80px);max-width:none;width:calc(100% - 80px)}}@media(min-width:600px){.components-modal__frame.has-size-large,.components-modal__frame.has-size-medium,.components-modal__frame.has-size-small{width:100%}.components-modal__frame.has-size-small{max-width:384px}.components-modal__frame.has-size-medium{max-width:512px}.components-modal__frame.has-size-large{max-width:840px}}@media(min-width:960px){.components-modal__frame{max-height:70%}}@keyframes components-modal__appear-animation{0%{opacity:0;transform:scale(.9)}to{opacity:1;transform:scale(1)}}@keyframes components-modal__disappear-animation{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.9)}}.components-modal__header{align-items:center;border-bottom:1px solid transparent;box-sizing:border-box;display:flex;flex-direction:row;height:72px;justify-content:space-between;padding:24px 32px 8px;position:absolute;right:0;top:0;width:100%;z-index:10}.components-modal__header .components-modal__header-heading{font-size:1.2rem;font-weight:600}.components-modal__header h1{line-height:1;margin:0}.components-modal__content.has-scrolled-content:not(.hide-header) .components-modal__header{border-bottom-color:#ddd}.components-modal__header+p{margin-top:0}.components-modal__header-heading-container{align-items:center;display:flex;flex-direction:row;flex-grow:1;justify-content:left}.components-modal__header-icon-container{display:inline-block}.components-modal__header-icon-container svg{max-height:36px;max-width:36px;padding:8px}.components-modal__content{flex:1;margin-top:72px;overflow:auto;padding:4px 32px 32px}.components-modal__content.hide-header{margin-top:0;padding-top:32px}.components-modal__content.is-scrollable:focus-visible{box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent;outline-offset:-2px}.components-notice{align-items:center;background-color:#fff;border-right:4px solid var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));color:#1e1e1e;display:flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;padding:8px 12px}.components-notice.is-dismissible{position:relative}.components-notice.is-success{background-color:#eff9f1;border-right-color:#4ab866}.components-notice.is-warning{background-color:#fef8ee;border-right-color:#f0b849}.components-notice.is-error{background-color:#f4a2a2;border-right-color:#cc1818}.components-notice__content{flex-grow:1;margin:4px 0 4px 25px}.components-notice__actions{display:flex;flex-wrap:wrap}.components-notice__action.components-button{margin-left:8px}.components-notice__action.components-button,.components-notice__action.components-button.is-link{margin-right:12px}.components-notice__action.components-button.is-secondary{vertical-align:initial}.components-notice__dismiss{align-self:flex-start;color:#757575;flex-shrink:0}.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):focus,.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):not(.is-secondary):active,.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):not(.is-secondary):hover{background-color:transparent;color:#1e1e1e}.components-notice__dismiss:not(:disabled):not([aria-disabled=true]):not(.is-secondary):hover{box-shadow:none}.components-notice-list{box-sizing:border-box;max-width:100vw}.components-notice-list .components-notice__content{line-height:2;margin-bottom:12px;margin-top:12px}.components-notice-list .components-notice__action.components-button{display:block;margin-right:0;margin-top:8px}.components-panel{background:#fff;border:1px solid #e0e0e0}.components-panel>.components-panel__body:first-child,.components-panel>.components-panel__header:first-child{margin-top:-1px}.components-panel>.components-panel__body:last-child,.components-panel>.components-panel__header:last-child{border-bottom-width:0}.components-panel+.components-panel{margin-top:-1px}.components-panel__body{border-bottom:1px solid #e0e0e0;border-top:1px solid #e0e0e0}.components-panel__body h3{margin:0 0 .5em}.components-panel__body.is-opened{padding:16px}.components-panel__header{align-items:center;border-bottom:1px solid #ddd;box-sizing:content-box;display:flex;flex-shrink:0;height:47px;justify-content:space-between;padding:0 16px}.components-panel__header h2{color:inherit;font-size:inherit;margin:0}.components-panel__body+.components-panel__body,.components-panel__body+.components-panel__header,.components-panel__header+.components-panel__body,.components-panel__header+.components-panel__header{margin-top:-1px}.components-panel__body>.components-panel__body-title{display:block;font-size:inherit;margin-bottom:0;margin-top:0;padding:0}@media not (prefers-reduced-motion){.components-panel__body>.components-panel__body-title{transition:background .1s ease-in-out}}.components-panel__body.is-opened>.components-panel__body-title{margin:-16px -16px 5px}.components-panel__body>.components-panel__body-title:hover{background:#f0f0f0;border:none}.components-panel__body-toggle.components-button{border:none;box-shadow:none;color:#1e1e1e;font-weight:500;height:auto;outline:none;padding:16px 16px 16px 48px;position:relative;text-align:right;width:100%}@media not (prefers-reduced-motion){.components-panel__body-toggle.components-button{transition:background .1s ease-in-out}}.components-panel__body-toggle.components-button:focus{border-radius:0;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-panel__body-toggle.components-button .components-panel__arrow{color:#1e1e1e;left:16px;position:absolute;top:50%;transform:translateY(-50%);fill:currentColor}@media not (prefers-reduced-motion){.components-panel__body-toggle.components-button .components-panel__arrow{transition:color .1s ease-in-out}}body.rtl .components-panel__body-toggle.components-button .dashicons-arrow-right{-ms-filter:fliph;filter:FlipH;margin-top:-10px;transform:scaleX(-1)}.components-panel__icon{color:#757575;margin:-2px 6px -2px 0}.components-panel__body-toggle-icon{margin-left:-5px}.components-panel__color-title{float:right;height:19px}.components-panel__row{align-items:center;display:flex;justify-content:space-between;margin-top:8px;min-height:36px}.components-panel__row select{min-width:0}.components-panel__row label{flex-shrink:0;margin-left:12px;max-width:75%}.components-panel__row:empty,.components-panel__row:first-of-type{margin-top:0}.components-panel .circle-picker{padding-bottom:20px}.components-placeholder.components-placeholder{align-items:flex-start;box-sizing:border-box;color:#1e1e1e;display:flex;flex-direction:column;font-size:13px;gap:16px;margin:0;padding:24px;position:relative;text-align:right;width:100%;-moz-font-smoothing:subpixel-antialiased;-webkit-font-smoothing:subpixel-antialiased;background-color:#fff;border-radius:2px;box-shadow:inset 0 0 0 1px #1e1e1e;outline:1px solid transparent}.components-placeholder__error,.components-placeholder__fieldset,.components-placeholder__instructions,.components-placeholder__label{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;font-weight:400;letter-spacing:normal;line-height:normal;text-transform:none}.components-placeholder__label{align-items:center;display:flex;font-weight:600}.components-placeholder__label .block-editor-block-icon,.components-placeholder__label .dashicon,.components-placeholder__label>svg{margin-left:4px;fill:currentColor}@media(forced-colors:active){.components-placeholder__label .block-editor-block-icon,.components-placeholder__label .dashicon,.components-placeholder__label>svg{fill:CanvasText}}.components-placeholder__label:empty{display:none}.components-placeholder__fieldset,.components-placeholder__fieldset form{display:flex;flex-direction:row;flex-wrap:wrap;gap:16px;justify-content:flex-start;width:100%}.components-placeholder__fieldset form p,.components-placeholder__fieldset p{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px}.components-placeholder__fieldset.is-column-layout,.components-placeholder__fieldset.is-column-layout form{flex-direction:column}.components-placeholder__input[type=url]{border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;flex:1 1 auto;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;line-height:normal;padding:6px 8px}@media not (prefers-reduced-motion){.components-placeholder__input[type=url]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-placeholder__input[type=url]{font-size:13px;line-height:normal}}.components-placeholder__input[type=url]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-placeholder__input[type=url]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-placeholder__input[type=url]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-placeholder__input[type=url]:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-placeholder__error{gap:8px;width:100%}.components-placeholder__fieldset .components-button:not(.is-link)~.components-button.is-link{margin-left:10px;margin-right:10px}.components-placeholder__fieldset .components-button:not(.is-link)~.components-button.is-link:last-child{margin-left:0}.components-placeholder.is-medium .components-placeholder__instructions,.components-placeholder.is-small .components-placeholder__instructions{display:none}.components-placeholder.is-medium .components-placeholder__fieldset,.components-placeholder.is-medium .components-placeholder__fieldset form,.components-placeholder.is-small .components-placeholder__fieldset,.components-placeholder.is-small .components-placeholder__fieldset form{flex-direction:column}.components-placeholder.is-medium .components-button,.components-placeholder.is-medium .components-placeholder__fieldset>*,.components-placeholder.is-small .components-button,.components-placeholder.is-small .components-placeholder__fieldset>*{justify-content:center;width:100%}.components-placeholder.is-small{padding:16px}.components-placeholder.has-illustration{-webkit-backdrop-filter:blur(100px);backdrop-filter:blur(100px);backface-visibility:hidden;background-color:transparent;border-radius:0;box-shadow:none;color:inherit;display:flex;overflow:hidden}.is-dark-theme .components-placeholder.has-illustration{background-color:rgba(0,0,0,.1)}.components-placeholder.has-illustration .components-placeholder__fieldset{margin-left:0;margin-right:0}.components-placeholder.has-illustration .components-button,.components-placeholder.has-illustration .components-placeholder__instructions,.components-placeholder.has-illustration .components-placeholder__label{opacity:0;pointer-events:none}@media not (prefers-reduced-motion){.components-placeholder.has-illustration .components-button,.components-placeholder.has-illustration .components-placeholder__instructions,.components-placeholder.has-illustration .components-placeholder__label{transition:opacity .1s linear}}.is-selected>.components-placeholder.has-illustration .components-button,.is-selected>.components-placeholder.has-illustration .components-placeholder__instructions,.is-selected>.components-placeholder.has-illustration .components-placeholder__label{opacity:1;pointer-events:auto}.components-placeholder.has-illustration:before{background:currentColor;bottom:0;content:"";left:0;opacity:.1;pointer-events:none;position:absolute;right:0;top:0}.is-selected .components-placeholder.has-illustration{overflow:auto}.components-placeholder__preview{display:flex;justify-content:center}.components-placeholder__illustration{box-sizing:content-box;height:100%;position:absolute;right:50%;top:50%;transform:translate(50%,-50%);width:100%;stroke:currentColor;opacity:.25}.components-popover{box-sizing:border-box;will-change:transform;z-index:1000000}.components-popover *,.components-popover :after,.components-popover :before{box-sizing:inherit}.components-popover.is-expanded{bottom:0;left:0;position:fixed;right:0;top:0;z-index:1000000!important}.components-popover__content{background:#fff;border-radius:4px;box-shadow:0 0 0 1px #ccc,0 2px 3px rgba(0,0,0,.05),0 4px 5px rgba(0,0,0,.04),0 12px 12px rgba(0,0,0,.03),0 16px 16px rgba(0,0,0,.02);box-sizing:border-box;width:min-content}.is-alternate .components-popover__content{border-radius:2px;box-shadow:0 0 0 1px #1e1e1e}.is-unstyled .components-popover__content{background:none;border-radius:0;box-shadow:none}.components-popover.is-expanded .components-popover__content{box-shadow:0 -1px 0 0 #ccc;height:calc(100% - 48px);overflow-y:visible;position:static;width:auto}.components-popover.is-expanded.is-alternate .components-popover__content{box-shadow:0 -1px 0 #1e1e1e}.components-popover__header{align-items:center;background:#fff;display:flex;height:48px;justify-content:space-between;padding:0 16px 0 8px}.components-popover__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:100%}.components-popover__close.components-button{z-index:5}.components-popover__arrow{display:flex;height:14px;pointer-events:none;position:absolute;width:14px}.components-popover__arrow:before{background-color:#fff;content:"";height:2px;left:1px;position:absolute;right:1px;top:-1px}.components-popover__arrow.is-top{bottom:-14px!important;transform:rotate(0)}.components-popover__arrow.is-right{right:-14px!important;transform:rotate(-90deg)}.components-popover__arrow.is-bottom{top:-14px!important;transform:rotate(-180deg)}.components-popover__arrow.is-left{left:-14px!important;transform:rotate(90deg)}.components-popover__triangle{display:block;flex:1}.components-popover__triangle-bg{fill:#fff}.components-popover__triangle-border{fill:transparent;stroke-width:1px;stroke:#ccc}.is-alternate .components-popover__triangle-border{stroke:#1e1e1e}.components-radio-control{border:0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;margin:0;padding:0}.components-radio-control__group-wrapper.has-help{margin-block-end:12px}.components-radio-control__option{align-items:center;column-gap:8px;display:grid;grid-template-columns:auto 1fr;grid-template-rows:auto minmax(0,max-content)}.components-radio-control__input[type=radio]{appearance:none;border:1px solid #1e1e1e;border-radius:2px;border-radius:50%;box-shadow:0 0 0 transparent;cursor:pointer;display:inline-flex;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;grid-column:1;grid-row:1;height:24px;line-height:normal;margin:0;max-width:24px;min-width:24px;padding:0;position:relative;transition:none;width:24px}@media not (prefers-reduced-motion){.components-radio-control__input[type=radio]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-radio-control__input[type=radio]{font-size:13px;line-height:normal}}.components-radio-control__input[type=radio]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color)}.components-radio-control__input[type=radio]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-radio-control__input[type=radio]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-radio-control__input[type=radio]:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width:600px){.components-radio-control__input[type=radio]{height:16px;max-width:16px;min-width:16px;width:16px}}.components-radio-control__input[type=radio]:checked:before{background-color:#fff;border:4px solid #fff;box-sizing:inherit;height:12px;margin:0;position:absolute;right:50%;top:50%;transform:translate(50%,-50%);width:12px}@media(min-width:600px){.components-radio-control__input[type=radio]:checked:before{height:8px;width:8px}}.components-radio-control__input[type=radio]:focus{box-shadow:0 0 0 2px #fff,0 0 0 4px var(--wp-admin-theme-color)}.components-radio-control__input[type=radio]:checked{background:var(--wp-admin-theme-color);border:none}.components-radio-control__input[type=radio]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) #fff,0 0 0 calc(var(--wp-admin-border-width-focus)*2) var(--wp-admin-theme-color);outline:2px solid transparent;outline-offset:2px}.components-radio-control__input[type=radio]:checked{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-color:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-radio-control__input[type=radio]:checked:before{border-radius:50%;content:""}.components-radio-control__label{cursor:pointer;grid-column:2;grid-row:1;line-height:24px}@media(min-width:600px){.components-radio-control__label{line-height:16px}}.components-radio-control__option-description{grid-column:2;grid-row:2;padding-block-start:4px}.components-radio-control__option-description.components-radio-control__option-description{margin-top:0}.components-resizable-box__handle{display:none;height:23px;width:23px;z-index:2}.components-resizable-box__container.has-show-handle .components-resizable-box__handle{display:block}.components-resizable-box__handle>div{height:100%;outline:none;position:relative;width:100%;z-index:2}.components-resizable-box__container>img{width:inherit}.components-resizable-box__handle:after{background:#fff;border-radius:50%;box-shadow:inset 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9)),0 1px 1px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.02),0 3px 3px rgba(0,0,0,.02),0 4px 4px rgba(0,0,0,.01);content:"";cursor:inherit;display:block;height:15px;left:calc(50% - 8px);outline:2px solid transparent;position:absolute;top:calc(50% - 8px);width:15px}.components-resizable-box__side-handle:before{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-radius:9999px;content:"";cursor:inherit;display:block;height:3px;left:calc(50% - 1px);opacity:0;position:absolute;top:calc(50% - 1px);width:3px}@media not (prefers-reduced-motion){.components-resizable-box__side-handle:before{transition:transform .1s ease-in;will-change:transform}}.components-resizable-box__corner-handle,.components-resizable-box__side-handle{z-index:2}.components-resizable-box__side-handle.components-resizable-box__handle-bottom,.components-resizable-box__side-handle.components-resizable-box__handle-bottom:before,.components-resizable-box__side-handle.components-resizable-box__handle-top,.components-resizable-box__side-handle.components-resizable-box__handle-top:before{border-left:0;border-right:0;right:0;width:100%}.components-resizable-box__side-handle.components-resizable-box__handle-left,.components-resizable-box__side-handle.components-resizable-box__handle-left:before,.components-resizable-box__side-handle.components-resizable-box__handle-right,.components-resizable-box__side-handle.components-resizable-box__handle-right:before{border-bottom:0;border-top:0;height:100%;top:0}@media not (prefers-reduced-motion){.components-resizable-box__side-handle.components-resizable-box__handle-bottom:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-bottom:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:hover:before{animation:components-resizable-box__top-bottom-animation .1s ease-out 0s;animation-fill-mode:forwards}.components-resizable-box__side-handle.components-resizable-box__handle-left:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-left:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:hover:before{animation:components-resizable-box__left-right-animation .1s ease-out 0s;animation-fill-mode:forwards}}@media not all and (min-resolution:0.001dpcm){@supports(-webkit-appearance:none){.components-resizable-box__side-handle.components-resizable-box__handle-bottom:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-bottom:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-left:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-left:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-right:hover:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:active:before,.components-resizable-box__side-handle.components-resizable-box__handle-top:hover:before{animation:none}}}@keyframes components-resizable-box__top-bottom-animation{0%{opacity:0;transform:scaleX(0)}to{opacity:1;transform:scaleX(1)}}@keyframes components-resizable-box__left-right-animation{0%{opacity:0;transform:scaleY(0)}to{opacity:1;transform:scaleY(1)}}.components-resizable-box__handle-right{right:-11.5px}.components-resizable-box__handle-left{left:-11.5px}.components-resizable-box__handle-top{top:-11.5px}.components-resizable-box__handle-bottom{bottom:-11.5px}.components-responsive-wrapper{align-items:center;display:flex;justify-content:center;max-width:100%;position:relative}.components-responsive-wrapper__content{display:block;max-width:100%;width:100%}.components-sandbox{overflow:hidden}iframe.components-sandbox{width:100%}body.lockscroll,html.lockscroll{overflow:hidden}.components-select-control__input{outline:0;-webkit-tap-highlight-color:rgba(0,0,0,0)!important}@media(max-width:782px){.components-base-control .components-base-control__field .components-select-control__input{font-size:16px}}.components-snackbar{-webkit-backdrop-filter:blur(16px) saturate(180%);backdrop-filter:blur(16px) saturate(180%);background:rgba(0,0,0,.85);border-radius:4px;box-shadow:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);box-sizing:border-box;color:#fff;cursor:pointer;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;max-width:600px;padding:12px 20px;pointer-events:auto;width:100%}@media(min-width:600px){.components-snackbar{width:fit-content}}.components-snackbar:focus{box-shadow:inset 0 0 0 1px #fff,0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9))}.components-snackbar.components-snackbar-explicit-dismiss{cursor:default}.components-snackbar .components-snackbar__content-with-icon{padding-right:24px;position:relative}.components-snackbar .components-snackbar__icon{position:absolute;right:-8px;top:-2.9px}.components-snackbar .components-snackbar__dismiss-button{cursor:pointer;margin-right:24px}.components-snackbar__action.components-button{color:#fff;flex-shrink:0;margin-right:32px}.components-snackbar__action.components-button:focus{box-shadow:none;outline:1px dotted #fff}.components-snackbar__action.components-button:hover{color:currentColor;text-decoration:none}.components-snackbar__content{align-items:baseline;display:flex;justify-content:space-between;line-height:1.4}.components-snackbar-list{box-sizing:border-box;pointer-events:none;position:absolute;width:100%;z-index:100000}.components-snackbar-list__notice-container{padding-top:8px;position:relative}.components-tab-panel__tabs{align-items:stretch;display:flex;flex-direction:row}.components-tab-panel__tabs[aria-orientation=vertical]{flex-direction:column}.components-tab-panel__tabs-item{background:transparent;border:none;border-radius:0;box-shadow:none;cursor:pointer;font-weight:500;height:48px!important;margin-right:0;padding:3px 16px;position:relative}.components-tab-panel__tabs-item:focus:not(:disabled){box-shadow:none;outline:none;position:relative}.components-tab-panel__tabs-item:after{background:var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));border-radius:0;bottom:0;content:"";height:calc(var(--wp-admin-border-width-focus)*0);left:0;pointer-events:none;position:absolute;right:0}@media not (prefers-reduced-motion){.components-tab-panel__tabs-item:after{transition:all .1s linear}}.components-tab-panel__tabs-item.is-active:after{height:calc(var(--wp-admin-border-width-focus)*1);outline:2px solid transparent;outline-offset:-1px}.components-tab-panel__tabs-item:before{border-radius:2px;bottom:12px;box-shadow:0 0 0 0 transparent;content:"";left:12px;pointer-events:none;position:absolute;right:12px;top:12px}@media not (prefers-reduced-motion){.components-tab-panel__tabs-item:before{transition:all .1s linear}}.components-tab-panel__tabs-item:focus-visible:before{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent}.components-tab-panel__tab-content:focus{box-shadow:none;outline:none}.components-tab-panel__tab-content:focus-visible{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent,var(--wp-admin-theme-color,#3858e9));outline:2px solid transparent;outline-offset:0}.components-text-control__input,.components-text-control__input[type=color],.components-text-control__input[type=date],.components-text-control__input[type=datetime-local],.components-text-control__input[type=datetime],.components-text-control__input[type=email],.components-text-control__input[type=month],.components-text-control__input[type=number],.components-text-control__input[type=password],.components-text-control__input[type=tel],.components-text-control__input[type=text],.components-text-control__input[type=time],.components-text-control__input[type=url],.components-text-control__input[type=week]{border:1px solid #949494;border-radius:2px;box-shadow:0 0 0 transparent;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:16px;height:32px;line-height:normal;margin:0;padding:6px 8px;width:100%}@media not (prefers-reduced-motion){.components-text-control__input,.components-text-control__input[type=color],.components-text-control__input[type=date],.components-text-control__input[type=datetime-local],.components-text-control__input[type=datetime],.components-text-control__input[type=email],.components-text-control__input[type=month],.components-text-control__input[type=number],.components-text-control__input[type=password],.components-text-control__input[type=tel],.components-text-control__input[type=text],.components-text-control__input[type=time],.components-text-control__input[type=url],.components-text-control__input[type=week]{transition:box-shadow .1s linear}}@media(min-width:600px){.components-text-control__input,.components-text-control__input[type=color],.components-text-control__input[type=date],.components-text-control__input[type=datetime-local],.components-text-control__input[type=datetime],.components-text-control__input[type=email],.components-text-control__input[type=month],.components-text-control__input[type=number],.components-text-control__input[type=password],.components-text-control__input[type=tel],.components-text-control__input[type=text],.components-text-control__input[type=time],.components-text-control__input[type=url],.components-text-control__input[type=week]{font-size:13px;line-height:normal}}.components-text-control__input:focus,.components-text-control__input[type=color]:focus,.components-text-control__input[type=date]:focus,.components-text-control__input[type=datetime-local]:focus,.components-text-control__input[type=datetime]:focus,.components-text-control__input[type=email]:focus,.components-text-control__input[type=month]:focus,.components-text-control__input[type=number]:focus,.components-text-control__input[type=password]:focus,.components-text-control__input[type=tel]:focus,.components-text-control__input[type=text]:focus,.components-text-control__input[type=time]:focus,.components-text-control__input[type=url]:focus,.components-text-control__input[type=week]:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 .5px var(--wp-admin-theme-color);outline:2px solid transparent}.components-text-control__input::-webkit-input-placeholder,.components-text-control__input[type=color]::-webkit-input-placeholder,.components-text-control__input[type=date]::-webkit-input-placeholder,.components-text-control__input[type=datetime-local]::-webkit-input-placeholder,.components-text-control__input[type=datetime]::-webkit-input-placeholder,.components-text-control__input[type=email]::-webkit-input-placeholder,.components-text-control__input[type=month]::-webkit-input-placeholder,.components-text-control__input[type=number]::-webkit-input-placeholder,.components-text-control__input[type=password]::-webkit-input-placeholder,.components-text-control__input[type=tel]::-webkit-input-placeholder,.components-text-control__input[type=text]::-webkit-input-placeholder,.components-text-control__input[type=time]::-webkit-input-placeholder,.components-text-control__input[type=url]::-webkit-input-placeholder,.components-text-control__input[type=week]::-webkit-input-placeholder{color:rgba(30,30,30,.62)}.components-text-control__input::-moz-placeholder,.components-text-control__input[type=color]::-moz-placeholder,.components-text-control__input[type=date]::-moz-placeholder,.components-text-control__input[type=datetime-local]::-moz-placeholder,.components-text-control__input[type=datetime]::-moz-placeholder,.components-text-control__input[type=email]::-moz-placeholder,.components-text-control__input[type=month]::-moz-placeholder,.components-text-control__input[type=number]::-moz-placeholder,.components-text-control__input[type=password]::-moz-placeholder,.components-text-control__input[type=tel]::-moz-placeholder,.components-text-control__input[type=text]::-moz-placeholder,.components-text-control__input[type=time]::-moz-placeholder,.components-text-control__input[type=url]::-moz-placeholder,.components-text-control__input[type=week]::-moz-placeholder{color:rgba(30,30,30,.62)}.components-text-control__input:-ms-input-placeholder,.components-text-control__input[type=color]:-ms-input-placeholder,.components-text-control__input[type=date]:-ms-input-placeholder,.components-text-control__input[type=datetime-local]:-ms-input-placeholder,.components-text-control__input[type=datetime]:-ms-input-placeholder,.components-text-control__input[type=email]:-ms-input-placeholder,.components-text-control__input[type=month]:-ms-input-placeholder,.components-text-control__input[type=number]:-ms-input-placeholder,.components-text-control__input[type=password]:-ms-input-placeholder,.components-text-control__input[type=tel]:-ms-input-placeholder,.components-text-control__input[type=text]:-ms-input-placeholder,.components-text-control__input[type=time]:-ms-input-placeholder,.components-text-control__input[type=url]:-ms-input-placeholder,.components-text-control__input[type=week]:-ms-input-placeholder{color:rgba(30,30,30,.62)}.components-text-control__input.is-next-40px-default-size,.components-text-control__input[type=color].is-next-40px-default-size,.components-text-control__input[type=date].is-next-40px-default-size,.components-text-control__input[type=datetime-local].is-next-40px-default-size,.components-text-control__input[type=datetime].is-next-40px-default-size,.components-text-control__input[type=email].is-next-40px-default-size,.components-text-control__input[type=month].is-next-40px-default-size,.components-text-control__input[type=number].is-next-40px-default-size,.components-text-control__input[type=password].is-next-40px-default-size,.components-text-control__input[type=tel].is-next-40px-default-size,.components-text-control__input[type=text].is-next-40px-default-size,.components-text-control__input[type=time].is-next-40px-default-size,.components-text-control__input[type=url].is-next-40px-default-size,.components-text-control__input[type=week].is-next-40px-default-size{height:40px;padding-left:12px;padding-right:12px}.components-text-control__input[type=email],.components-text-control__input[type=url]{direction:rtl}.components-tip{color:#757575;display:flex}.components-tip svg{align-self:center;fill:#f0b849;flex-shrink:0;margin-left:16px}.components-tip p{margin:0}.components-toggle-control__label{line-height:16px}.components-toggle-control__label:not(.is-disabled){cursor:pointer}.components-toggle-control__help{display:inline-block;margin-inline-start:40px}.components-accessible-toolbar{border:1px solid #1e1e1e;border-radius:2px;display:inline-flex;flex-shrink:0}.components-accessible-toolbar>.components-toolbar-group:last-child{border-left:none}.components-accessible-toolbar.is-unstyled{border:none}.components-accessible-toolbar.is-unstyled>.components-toolbar-group{border-left:none}.components-accessible-toolbar[aria-orientation=vertical],.components-toolbar[aria-orientation=vertical]{align-items:center;display:flex;flex-direction:column}.components-accessible-toolbar .components-button,.components-toolbar .components-button{height:48px;padding-left:16px;padding-right:16px;position:relative;z-index:1}.components-accessible-toolbar .components-button:focus:not(:disabled),.components-toolbar .components-button:focus:not(:disabled){box-shadow:none;outline:none}.components-accessible-toolbar .components-button:before,.components-toolbar .components-button:before{border-radius:2px;content:"";display:block;height:32px;left:8px;position:absolute;right:8px;z-index:-1}@media not (prefers-reduced-motion){.components-accessible-toolbar .components-button:before,.components-toolbar .components-button:before{animation:components-button__appear-animation .1s ease;animation-fill-mode:forwards}}.components-accessible-toolbar .components-button svg,.components-toolbar .components-button svg{margin-left:auto;margin-right:auto;position:relative}.components-accessible-toolbar .components-button.is-pressed,.components-accessible-toolbar .components-button.is-pressed:hover,.components-toolbar .components-button.is-pressed,.components-toolbar .components-button.is-pressed:hover{background:transparent}.components-accessible-toolbar .components-button.is-pressed:before,.components-toolbar .components-button.is-pressed:before{background:#1e1e1e}.components-accessible-toolbar .components-button:focus:before,.components-toolbar .components-button:focus:before{box-shadow:inset 0 0 0 1px #fff,0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.components-accessible-toolbar .components-button.has-icon.has-icon,.components-toolbar .components-button.has-icon.has-icon{min-width:48px;padding-left:8px;padding-right:8px}@keyframes components-button__appear-animation{0%{transform:scaleY(0)}to{transform:scaleY(1)}}.components-toolbar__control.components-button{position:relative}.components-toolbar__control.components-button[data-subscript] svg{padding:5px 0 5px 10px}.components-toolbar__control.components-button[data-subscript]:after{bottom:10px;content:attr(data-subscript);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;font-weight:600;left:8px;line-height:12px;position:absolute}.components-toolbar__control.components-button:not(:disabled).is-pressed[data-subscript]:after{color:#fff}.components-toolbar-group{background-color:#fff;border-left:1px solid #1e1e1e;display:inline-flex;flex-shrink:0;flex-wrap:wrap;line-height:0;min-height:48px;padding-left:6px;padding-right:6px}.components-toolbar-group .components-toolbar-group.components-toolbar-group{border-width:0;margin:0}.components-toolbar-group .components-button.components-button,.components-toolbar-group .components-button.has-icon.has-icon{justify-content:center;min-width:36px;padding-left:6px;padding-right:6px}.components-toolbar-group .components-button.components-button svg,.components-toolbar-group .components-button.has-icon.has-icon svg{min-width:24px}.components-toolbar-group .components-button.components-button:before,.components-toolbar-group .components-button.has-icon.has-icon:before{left:2px;right:2px}.components-toolbar{background-color:#fff;border:1px solid #1e1e1e;display:inline-flex;flex-shrink:0;flex-wrap:wrap;margin:0;min-height:48px}.components-toolbar .components-toolbar.components-toolbar{border-width:0;margin:0}div.components-toolbar>div{display:flex;margin:0}div.components-toolbar>div+div.has-left-divider{margin-right:6px;overflow:visible;position:relative}div.components-toolbar>div+div.has-left-divider:before{background-color:#ddd;box-sizing:content-box;content:"";display:inline-block;height:20px;position:absolute;right:-3px;top:8px;width:1px}.components-tooltip{background:#000;border-radius:2px;box-shadow:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);color:#f0f0f0;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:12px;line-height:1.4;padding:4px 8px;text-align:center;z-index:1000002}.components-tooltip__shortcut{margin-right:8px}:root{--tag-color:#daffdc}div.dataviews-wrapper div.dataviews-filters__container{padding-right:24px}div.dataviews-wrapper svg.table-view-icon{height:52px;width:52px}div.dataviews-wrapper button[aria-controls=dataviews-view-config-dropdown-0]{display:none}div.dataviews-wrapper div.dataviews__view-actions{align-items:center;justify-content:flex-start;padding-left:24px;padding-right:24px}div.dataviews-wrapper button.components-button.is-secondary{font-weight:400;padding:calc(var(--spacing-base)/2) var(--spacing-base)}div.dataviews-wrapper div.components-base-control__field{margin-bottom:0}div.dataviews-wrapper div.components-toggle-group-control{min-height:32px;padding:0}div.dataviews-wrapper div.dataviews-title-field{font-size:var(--font-title-small)}div.dataviews-wrapper span.dataviews-view-list__field-value{font-size:var(--font-body-small)}div.dataviews-wrapper div.dataviews-view-list div[role=row]{border:none}div.dataviews-wrapper div.dataviews-view-list div[role=row] .dataviews-view-list__fields{flex-wrap:nowrap;justify-content:space-between;margin-left:30px}@media(min-width:783px){div.dataviews-wrapper div.dataviews-view-list div[role=row] .dataviews-view-list__fields{flex-wrap:wrap;margin-left:0}}div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected).is-hovered,div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected):hover{background-color:transparent}div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected).is-hovered .dataviews-view-list__fields,div.dataviews-wrapper div.dataviews-view-list div[role=row]:not(.is-selected):hover .dataviews-view-list__fields{color:#757575}@media(min-width:783px){div.dataviews-wrapper button.dataviews-view-list__item{display:none}}div.dataviews-filters__search-widget-listitem span,span.dataviews-filters__summary-filter-text-value{text-transform:capitalize}div.dataviews-filters__search-widget-listitem:hover,div.dataviews-filters__search-widget-listitem[data-active-item]{background-color:var(--tag-color);color:var(--jp-gray-70)}div.dataviews-filters__search-widget-listitem:hover span.dataviews-filters__search-widget-listitem-check{fill:var(--jp-gray-70)}div.dataviews-filters__summary-chip-container button.dataviews-filters__summary-chip-remove.has-values:hover,div.dataviews-filters__summary-chip-container div.dataviews-filters__summary-chip.has-values:hover,div.dataviews-filters__summary-chip-container div.dataviews-filters__summary-chip.has-values[aria-expanded=true]{background-color:var(--tag-color)}button.product-list-item-chevron{align-items:center;background:transparent;border:none;cursor:pointer;display:flex;justify-content:center;left:30px;outline-color:var(--jp-green-40);padding:0;position:absolute;top:calc(50% - 12px)}.Jvb1njqMy7ML1zikhbWn{margin-top:1rem}.mpr8_ygU8woV4bVR1xvw{align-items:center;display:flex;font-size:var(--font-title-small);font-weight:500;line-height:1.5;margin-bottom:.5rem;margin-top:0}.gwO_Q0L0jbwMARVlBezu{color:var(--jp-gray-60);font-family:SF Pro Text,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:var(--font-body-small);font-weight:400;letter-spacing:-.15px;line-height:20px;margin-right:.75rem}.qwy7CsLeEbXvaPwgC9WV{display:flex;flex-flow:row nowrap;max-width:100%;overflow-x:scroll;padding:1px;scrollbar-width:none}.qwy7CsLeEbXvaPwgC9WV::-webkit-scrollbar{display:none}.qwy7CsLeEbXvaPwgC9WV .Hrbg7DeSJs6gas9zdPDR{border-color:var(--jp-gray-5);border-radius:5px;margin-bottom:0;margin-left:1.5rem;min-width:180px;padding:1rem 1.5rem;width:100%}@media only screen and (min-width:960px){.qwy7CsLeEbXvaPwgC9WV .Hrbg7DeSJs6gas9zdPDR{min-width:220px}}.qwy7CsLeEbXvaPwgC9WV .Hrbg7DeSJs6gas9zdPDR:last-child{margin-left:0}.NFpbo5AINn6I6avKFGby{margin-bottom:1.5rem}.aoQZCG0JeyWmy2J6vVxF{font-weight:500;line-height:20px;margin-bottom:.25rem}.M6ApyXg79vuXo6GwDkbO{align-items:flex-end;display:flex;flex-wrap:wrap;font-size:36px;font-weight:400;line-height:40px}.M6ApyXg79vuXo6GwDkbO.DYHb5e6QhgXejWyo9s78{cursor:pointer}.OlInbY5YnDO06MEQHv98{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;line-height:1;margin-left:.5rem}.EtbKbd5m85w7oYT4stIs{color:var(--jp-gray-20);display:none;font-size:var(--font-body-small);font-weight:600;line-height:24px;fill:var(--jp-gray-20)}@media screen and (min-width:960px){.EtbKbd5m85w7oYT4stIs{align-items:center;display:flex}}.EtbKbd5m85w7oYT4stIs.Awr7zl75sfAsFPHK9kDG{color:var(--jp-red-50);fill:var(--jp-red-50)}.EtbKbd5m85w7oYT4stIs.QFSZbIKFdWO3HEPBZyhc{color:var(--jp-green-50);fill:var(--jp-green-50)}.GgJAnS4gaEEGmRCP5n8y{align-content:flex-end;display:flex}.mjiNtwdbKpfo9edGVes4{margin-left:2px}.pAt4v_KG9Ir19wNcEtEj{align-items:center;display:flex;flex-wrap:wrap;justify-content:space-between;margin-top:calc(var(--spacing-base)*2.5);min-height:28px;width:100%}.vMa4i_Dza2t5Zi_Bw9Nf{background:var(--jp-white-off);padding-top:1px}.jrGNTKcgeXk9HKzolut9{position:relative}.jrGNTKcgeXk9HKzolut9>.wg3mZsoPekZWlBgOvdZ6{overflow:hidden;padding:0}.jrGNTKcgeXk9HKzolut9>.wg3mZsoPekZWlBgOvdZ6.aDxB89WgtARQqNWd4ZeK:before{background-color:var(--jp-red-50);border:2px solid var(--jp-white-off);border-radius:50%;content:"";height:18px;position:absolute;right:-11px;top:-11px;width:18px}.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR{background-color:var(--jp-white);border-radius:50%;box-shadow:0 0 5px 1px rgba(0,0,0,.1);left:16px;padding:8px;position:absolute;top:16px;transform:scale(.75)}.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR:focus,.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR:hover{background-color:var(--jp-white)}.jrGNTKcgeXk9HKzolut9>.sGP8lxDpRSjt0Fh7wxoR:disabled{pointer-events:none}.z5EQSkU36nsjxHEBSfNN{padding:0}.MwBwVaEj6u_zRgfrFR9b{padding:24px 16px}@media screen and (min-width:600){.MwBwVaEj6u_zRgfrFR9b{padding:32px 24px}}@media screen and (min-width:960px){.MwBwVaEj6u_zRgfrFR9b{padding:48px 48px 48px 12px}}.UgPNtuFW7lTJ06k39EsK{background-image:url(images/evaluation-blank-fbbfbcd75b50ade0f092.png),radial-gradient(circle at 40% 70%,rgba(206,217,242,.75) 0,hsla(0,0%,100%,0) 40%),radial-gradient(circle at 80% 80%,rgba(6,158,8,.15) 5%,hsla(0,0%,100%,0) 50%),radial-gradient(circle at 80% 20%,hsla(46,77%,83%,.75) 0,hsla(0,0%,100%,0) 50%);background-position:25%;background-repeat:no-repeat;background-size:393px,cover,cover,cover}.UgPNtuFW7lTJ06k39EsK.ilVOud0_OCGK4HciazB_{background-image:url(images/evaluation-selected-196d1790b76830f9b73a.png),radial-gradient(circle at 40% 70%,rgba(206,217,242,.75) 0,hsla(0,0%,100%,0) 40%),radial-gradient(circle at 80% 80%,rgba(6,158,8,.15) 5%,hsla(0,0%,100%,0) 50%),radial-gradient(circle at 80% 20%,hsla(46,77%,83%,.75) 0,hsla(0,0%,100%,0) 50%)}.EtcggGK0Bk8POQD986Og{background-image:url(images/site-cards-29522f090d5422fd7afd.png),radial-gradient(circle at 90% 30%,rgba(6,158,8,.15) 0,hsla(0,0%,100%,0) 35%),radial-gradient(circle at 75% 65%,rgba(206,217,242,.5) 5%,hsla(0,0%,100%,0) 15%),radial-gradient(circle at 90% 90%,hsla(46,77%,83%,.5) 0,hsla(0,0%,100%,0) 25%);background-repeat:no-repeat;background-size:cover}@media screen and (max-width:960px){.EtcggGK0Bk8POQD986Og{background-image:url(images/site-cards-29522f090d5422fd7afd.png),radial-gradient(circle at 55% 30%,rgba(6,158,8,.15) 0,hsla(0,0%,100%,0) 100%),radial-gradient(circle at 25% 40%,rgba(206,217,242,.5) 5%,hsla(0,0%,100%,0) 50%),radial-gradient(circle at 50% 85%,hsla(46,77%,83%,.3) 0,hsla(0,0%,100%,0) 35%);min-height:160px;order:-1}}.TSiu5sC6MdANROjUkUJM{margin-top:24px}.iqJfpZM9IYXuFSXvuoEe{font-size:16px!important;margin-top:16px}.Vozbq8Inlk5SxoVnn2G5{column-gap:40px;display:flex;flex-direction:row;margin-top:64px}.s_V1BM1Wtt3He4eF2TCu{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3);text-decoration:none!important}.FMZ2bZdjMxKFePbMwRi3{align-items:center;background-image:radial-gradient(circle at 80% 80%,rgba(6,158,8,.15) 5%,hsla(0,0%,100%,0) 50%);background-position:0 80%;background-repeat:no-repeat;background-size:cover;display:flex;flex-direction:column;justify-content:center;padding:144px 32px}.eShkT8UhgFL0N__pJEA8{display:flex;justify-content:center;margin-bottom:24px}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF{color:var(--jp-green-40);height:88px;transform:scale(1.3);transition:transform .3s ease-out;width:88px}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .Ktcwz9OsGT_3yNKZq6BA,.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .WQpz4j3rH6uEqAXwDrR8,.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .jkWzdt8A2twwREkaF2qX,.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .lZq4cdGYKYAgiVEYCtXw{opacity:0}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .jkWzdt8A2twwREkaF2qX{stroke-dasharray:276;stroke-dashoffset:276;animation:w9IUcbm9vJHQeg2OXhtF 2s ease-out forwards}.eShkT8UhgFL0N__pJEA8 .GZ2uVyfGabA_66Y8nmuF .lZq4cdGYKYAgiVEYCtXw{animation:xAohbjzRzlC5o13repbp .5s ease-in-out 1.5s forwards}.eShkT8UhgFL0N__pJEA8.iOKKzf48kelOFS8vRBwR .GZ2uVyfGabA_66Y8nmuF{animation:OrGIdZzrmFu39hFSKNfg 1s ease-out .3s forwards;transform:scale(1.4)}.eShkT8UhgFL0N__pJEA8.iOKKzf48kelOFS8vRBwR .GZ2uVyfGabA_66Y8nmuF .Ktcwz9OsGT_3yNKZq6BA,.eShkT8UhgFL0N__pJEA8.iOKKzf48kelOFS8vRBwR .GZ2uVyfGabA_66Y8nmuF .WQpz4j3rH6uEqAXwDrR8{animation:xAohbjzRzlC5o13repbp .85s ease-out .3s forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .GZ2uVyfGabA_66Y8nmuF{animation:none;transform:scale(1.4)}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .GZ2uVyfGabA_66Y8nmuF .Ktcwz9OsGT_3yNKZq6BA,.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .GZ2uVyfGabA_66Y8nmuF .WQpz4j3rH6uEqAXwDrR8{opacity:1}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z{position:absolute;top:0;transform:translateX(-10px)}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g{opacity:0;transform:translateY(-200px)}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:first-child{--duration:0.6s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(2){--duration:0.8s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(3){--duration:1s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(4){--duration:0.7s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(5){--duration:0.9s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(6){--duration:1.1s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(7){--duration:0.75s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}.eShkT8UhgFL0N__pJEA8.OqFqx9KLY3auyUaWh5tp .JdllqWQef8TBWPF5UT6Z>g:nth-child(8){--duration:1.1s;animation:xAohbjzRzlC5o13repbp .6s ease-in-out .2s forwards,_brJ7gDgGneDqAzmDSZG var(--duration) linear forwards}@keyframes w9IUcbm9vJHQeg2OXhtF{0%{opacity:1;stroke-dashoffset:276}to{opacity:1;stroke-dashoffset:0}}@keyframes xAohbjzRzlC5o13repbp{to{opacity:1}}@keyframes OrGIdZzrmFu39hFSKNfg{25%{transform:scale(1.25)}to{transform:scale(1.4)}}@keyframes _brJ7gDgGneDqAzmDSZG{0%{transform:translateY(-300px)}to{transform:translateY(0)}}.jErCC9oKHSM15BxzFyQK{margin-bottom:0}.oVoYbwbFB6U2o90Njusk>div{background-color:var(--jp-white);font-size:16px;line-height:24px;margin:0;position:relative}.oVoYbwbFB6U2o90Njusk>div .components-notice__content{align-items:flex-start;display:flex;flex-direction:column;margin:0;padding:12px 4px}@media screen and (min-width:960px){.oVoYbwbFB6U2o90Njusk>div .components-notice__content{gap:6rem}}.oVoYbwbFB6U2o90Njusk>div .is-link{color:var(--jp-black);font-size:16px;font-weight:600;padding:var(--spacing-base) calc(var(--spacing-base)*3)!important;white-space:nowrap}.oVoYbwbFB6U2o90Njusk>div .components-notice__dismiss{align-self:center}.oVoYbwbFB6U2o90Njusk>div .components-notice__action{align-items:center;background:#000;border-radius:var(--jp-border-radius);color:var(--jp-white);cursor:pointer;font-size:16px;font-weight:600;height:auto;justify-content:center;letter-spacing:-.01em;line-height:24px;margin-right:0;margin-top:24px;padding:8px 24px;text-decoration:none}@media screen and (min-width:960px){.oVoYbwbFB6U2o90Njusk>div .components-notice__action{margin-right:calc(var(--spacing-base)*2 + 24px)}}.oVoYbwbFB6U2o90Njusk>div.Snc8NEmDelsbhlH4285s .components-notice__action{margin-right:0;margin-top:0;white-space:nowrap}.oVoYbwbFB6U2o90Njusk>div.Snc8NEmDelsbhlH4285s .components-notice__content{align-items:center;flex-direction:row}@media screen and (max-width:600px){.oVoYbwbFB6U2o90Njusk>div{padding-top:24px}.oVoYbwbFB6U2o90Njusk>div>div:has(svg){position:static}}.oVoYbwbFB6U2o90Njusk .R5tvcsARTGN0A_z3DygA{min-width:auto}.wBVXH4OTNwLHPRpN4nsq{display:flex;flex-grow:1;margin-left:var(--spacing-base)}.wBVXH4OTNwLHPRpN4nsq a{color:var(--jp-black)}.wBVXH4OTNwLHPRpN4nsq a:focus,.wBVXH4OTNwLHPRpN4nsq a:hover{text-decoration:underline;text-decoration-thickness:2px}.wBVXH4OTNwLHPRpN4nsq .terms-of-service{color:var(--jp-gray-70);font-size:var(--font-body-small)}.wBVXH4OTNwLHPRpN4nsq>svg{fill:var(--jp-red-60);align-self:flex-start;flex-shrink:0;margin-left:calc(var(--spacing-base)*2)}.wBVXH4OTNwLHPRpN4nsq>svg.F1qvEnFfHs5nz3zFZUOV{fill:none}.wBVXH4OTNwLHPRpN4nsq .products-list{margin:10px 0}.wBVXH4OTNwLHPRpN4nsq .products-list .product-badge{background-color:#f1f1f1;border-radius:6px;display:inline-block;margin:4px 0 4px 8px;padding:2px 8px}.wBVXH4OTNwLHPRpN4nsq .plugins-list .plugin-item>span{font-size:calc(var(--font-body-extra-small) + 1px);margin-inline-start:5px}.SrQxAOBa5ZaSKP8wlut9{border-bottom:none;margin:0}.TcCZnGE6mad8Dvz9pCZi{background:url(data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyNCIgaGVpZ2h0PSIyNCIgZmlsbD0ibm9uZSI+PHBhdGggc3Ryb2tlPSIjRDYzNjM5IiBzdHJva2Utd2lkdGg9IjEuNSIgZD0iTTEyIDIwYTggOCAwIDEgMCAwLTE2IDggOCAwIDAgMCAwIDE2WiIvPjxwYXRoIGZpbGw9IiNENjM2MzkiIGQ9Ik0xMyA3aC0ydjZoMnpNMTMgMTVoLTJ2MmgyeiIvPjwvc3ZnPg==) no-repeat 100% 0;color:var(--jp-red);line-height:25px;padding-right:25px}._mn6o2Dtm5pfFWc8_A1K{--spacing-base:8px;min-width:264px}.VHYulMcpzbr10HWR0iSE{align-items:flex-start;border:1px solid var(--jp-black);border-color:var(--jp-gray-5);border-radius:4px;border-right-width:6px;display:flex;font-size:var(--font-body);padding:24px 18px 27px 31px}.FGpSkMCiIHQjszcV0dbn{height:calc(var(--spacing-base)*3);margin-left:20px;width:calc(var(--spacing-base)*3)}.KoWZcCwhW13xvkEb0QON{background-color:transparent;border:none;cursor:pointer;outline:none;padding:0}.KoWZcCwhW13xvkEb0QON svg{display:block}@media screen and (max-width:600px){.VHYulMcpzbr10HWR0iSE{box-shadow:0 4px 8px rgba(0,0,0,.03),0 1px 2px rgba(0,0,0,.06);padding-top:68px;position:relative}.FGpSkMCiIHQjszcV0dbn{position:absolute;right:24px;top:24px}.KoWZcCwhW13xvkEb0QON{left:24px;position:absolute;top:24px}}.smrfczkC53EaFM8OJUXs{flex-grow:1}.IKYRWoPwt9xOVEx1wzNS{font-weight:600;margin-bottom:8px}.qM0qY6mPYp1MPN54A3Kg{align-items:center;display:flex;flex-wrap:wrap;margin-top:20px;row-gap:20px}@media screen and (max-width:600px){.qM0qY6mPYp1MPN54A3Kg{justify-content:center}}.qM0qY6mPYp1MPN54A3Kg a,.qM0qY6mPYp1MPN54A3Kg a:active,.qM0qY6mPYp1MPN54A3Kg a:focus,.qM0qY6mPYp1MPN54A3Kg a:hover{color:var(--jp-black)}.qM0qY6mPYp1MPN54A3Kg>*{margin-left:24px}.A5YkDkkXuiYgavrY6Nux{border-right-color:var(--jp-red)}.A5YkDkkXuiYgavrY6Nux .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-red)}.cT5rwuPMZzWvi5o6shMl{border-right-color:var(--jp-yellow-20)}.cT5rwuPMZzWvi5o6shMl .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-yellow-20)}.yo0O3uvNomPsYUXFCpAS{border-right-color:var(--black)}.yo0O3uvNomPsYUXFCpAS .y_IPyP1wIAOhyNaqvXJq{fill:var(--black)}.oZdDFf1jBLkzn5ICCC6x{border-right-color:var(--jp-green)}.oZdDFf1jBLkzn5ICCC6x .y_IPyP1wIAOhyNaqvXJq{fill:var(--jp-green)}.jT9Kt2ZTvxPKDQ1pa7sN.components-snackbar-list{inset-block-end:0;inset-block-start:auto;inset-inline:0;position:fixed;z-index:100001}@media(min-width:600px){.jT9Kt2ZTvxPKDQ1pa7sN.components-snackbar-list{inset-block-start:4rem;inset-inline:unset;inset-inline-end:1rem;width:auto}}@media(min-width:782px){.jT9Kt2ZTvxPKDQ1pa7sN.components-snackbar-list{inset-block-start:3rem}}.cAbGtJDGgLubucBnz7vM{background-color:var(--jp-white)}.XsCIqtbkjCGvQuTEqP12{display:flex;flex-direction:column;gap:16px;max-width:450px;width:100%}.FuIWMXR9G82lNoOWSg7Z{font-size:32px;font-weight:500;line-height:40px}.VqV6BERV7qt2YRiC8ant{color:var(--jp-gray-100,#101517);font-size:16px;font-weight:400;line-height:24px;margin-bottom:29px}.H7h4wR1WKIziIFiwJpzN{align-items:center;align-self:stretch;background:transparent;border:1px solid #ccc;border-radius:var(--jp-button-radius);box-shadow:none;display:flex;justify-content:center;margin-bottom:0;padding:14px 16px;width:100%}.H7h4wR1WKIziIFiwJpzN:hover{cursor:pointer}.pSJyHDRGl_R9CF7J_wzX{color:var(--jp-gray-80,#2c3338);font-size:15px;font-style:normal;font-weight:500;line-height:20px;margin-right:-20px;text-align:center;width:100%}.TnFm4M8CVuTak6Vq2NsE{align-items:center;display:flex;margin:20px 0;text-transform:uppercase;width:100%}.TnFm4M8CVuTak6Vq2NsE span{color:var(--jp-gray-60,#50575e);margin:0 16px;white-space:nowrap}.TnFm4M8CVuTak6Vq2NsE .eKWjmNNdlY3uWjVgR8RI{background:rgba(0,0,0,.1);flex:1;height:1px}.Scnx4BQ8P2bIZ0YxBThk{display:flex;flex-direction:column;gap:16px}.Scnx4BQ8P2bIZ0YxBThk .Ps4m_56jJQ5YgQb25OW0{border:1px solid var(--jp-gray-60,#949494);border-radius:var(--jp-button-radius);box-sizing:border-box;color:var(--jp-gray-50,#646970);font-size:15px;line-height:20px;margin:0;padding:12px 16px;width:100%}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI{background:var(--jp-green-60,#007117);border:1px solid var(--jp-green-60,#007117);border-radius:var(--jp-button-radius);box-sizing:border-box;color:var(--jp-white,#fff);font-size:16px;font-weight:500;line-height:24px;padding:12px 16px;width:100%}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:focus,.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:hover{background:var(--jp-green-70,#00801a);cursor:pointer}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:focus{border-color:var(--jp-white,#fff);outline:2px solid var(--jp-green-60,#007117)}.Scnx4BQ8P2bIZ0YxBThk .IIUH0pxUdd27eEyqfQFI:disabled{background:var(--jp-gray,#dcdcde);border-color:var(--jp-gray,#dcdcde);color:var(--jp-gray-50,#646970);cursor:unset}.IySisqLBT5FBSpx8ksyG{color:var(--jp-gray-50,#646970);font-size:13px;line-height:20px;margin-top:8px}.IySisqLBT5FBSpx8ksyG .terms-of-service__link{color:var(--jp-gray-50,#646970);text-decoration:underline}body{font-family:SF Pro Text,-apple-system,BlinkMacSystemFont,Avenir Next,Avenir,Segoe UI,Helvetica Neue,Helvetica,Cantarell,Ubuntu,Roboto,Noto Sans,Arial,sans-serif}#wpwrap{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;text-rendering:optimizeLegibility}.hs8vtMKdbmvStRLqOShe{position:absolute}.a2dTOxFWByKrVw1RIDQT{--max-container-width:100%;background-color:var(--jp-white,#fff);height:100vh;overflow-y:hidden;width:100%}.q0k48EMOblqQLxSxIKZa{overflow:hidden}.w9obJdf7GdvAmyMTJp12{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center}@media screen and (max-width:600px){.w9obJdf7GdvAmyMTJp12{justify-content:flex-start;padding-top:72px}}.Jqm3k3aZ4rGDtBCVeocD{border-radius:12px;max-height:100%}.Jqm3k3aZ4rGDtBCVeocD img{display:block;object-fit:cover;width:100%}@media screen and (max-width:600px){.PhMWEQDEAfUHteBMf1hM{display:none}}.q0T8YyQxRawhpDtvJjxI{background-color:var(--jp-white);height:100%;padding:calc(var(--spacing-base)*8);position:relative}.B7JDqI_vtKxSy5GjvqA1{display:flex;flex-direction:column;height:100%}.zj7xadmhIWeuf7ZwvVTS{align-items:center;background:var(--jp-black);border-radius:var(--jp-border-radius) var(--jp-border-radius) 0 0;color:var(--jp-white);display:flex;height:calc(var(--spacing-base)*4);padding:0 var(--spacing-base);position:absolute;right:0;top:0;width:100%}.GsioW6IsC8EMYE3U6788{fill:var(--jp-white);margin-left:var(--spacing-base)}.cfEO8udWbRGPFJzW8Jg5,.dbz07JqxOlivjKO4vBEF{align-items:center;display:flex;height:calc(var(--spacing-base)*4);margin-bottom:calc(var(--spacing-base)*4)}.zlh3zbjUe4Z8cBs7uVVe{fill:#8c8f94;height:24px;line-height:24px}.qoZuzG5EcDa231hC6t0P{align-items:center;display:flex;justify-content:center}.qoZuzG5EcDa231hC6t0P svg{margin-left:var(--spacing-base)}.Q6uUUQCPWS6_6nLxIn68{display:inline-block;min-height:42px;padding:.5em 2em;text-align:center;width:100%}.Q6uUUQCPWS6_6nLxIn68 .YU4iBCRze09ZP3iCsdcb{margin:0}.Q6uUUQCPWS6_6nLxIn68.components-button.is-primary{height:auto;white-space:normal}.Q6uUUQCPWS6_6nLxIn68.is-secondary:hover:not(:disabled){background-color:var(--jp-black);color:var(--jp-white)}.OrQG7DjDd9Ha2Xj1Mx3L{margin-top:calc(var(--spacing-base)*2)}.Q1jaYDpa2AVfJpA29wT0{flex-grow:1;margin:0;margin-bottom:calc(var(--spacing-base)*2);padding:0}.Q1jaYDpa2AVfJpA29wT0 li{align-items:flex-start;display:flex;list-style:none;margin-bottom:var(--spacing-base)}.Q1jaYDpa2AVfJpA29wT0 svg{fill:var(--jp-green-primary);flex-shrink:0;margin-left:var(--spacing-base)}.HL4gSxsF0skYGhGuqH90 li:last-of-type{font-weight:700}.sEcLfpWjo0GF7QrxD3Lt{margin-top:calc(var(--spacing-base)*2)}.xgv3jRkeF39aEQELCwru{align-items:flex-end;color:var(--jp-black);display:flex;flex-wrap:wrap;gap:calc(var(--spacing-base)*2)}.twlleZ5Ehq4bB7CvKVSW{position:relative}.twlleZ5Ehq4bB7CvKVSW.Qg4rPEvXsqmod1s_31d8{color:var(--jp-gray-20)}.twlleZ5Ehq4bB7CvKVSW.Qg4rPEvXsqmod1s_31d8:after{background:var(--jp-red);border-radius:var(--jp-border-radius);content:" ";display:block;height:3px;margin-top:-2px;pointer-events:none;position:absolute;top:50%;width:100%}.ApsgxIornVy_3KnciVeJ{color:var(--jp-gray-40);margin-bottom:calc(var(--spacing-base)*3)}.NMxcZL17aEP7v81uG3zD{margin-top:calc(var(--spacing-base)*5)}.gCTKfAPzJqZas7CaRbKN{margin-bottom:calc(var(--spacing-base)*4)}.demNsMJjhi7BLY7xhjU5{align-items:center;display:flex;font-size:var(--font-body);line-height:calc(var(--spacing-base)*3);margin:calc(var(--spacing-base)*2) 0;min-height:calc(var(--spacing-base)*3)}.QiUjdjJSkqh6nH7YMG5A{align-self:flex-start;height:calc(var(--spacing-base)*3);margin-left:calc(var(--spacing-base)/2);width:calc(var(--spacing-base)*3)}.Q080AHcq29J2fc68Hhk5{color:var(--jp-red)}.Q080AHcq29J2fc68Hhk5 .hYWbIwhppukXmGnsiT9H{fill:var(--jp-red)}.JjHuxWly0HI9C60gorbq{color:var(--jp-yellow-40)}.JjHuxWly0HI9C60gorbq .hYWbIwhppukXmGnsiT9H{fill:var(--jp-yellow-40)}.Cm8ZFHi3mngl4cj9Gatx{color:var(--jp-blue-40)}.Cm8ZFHi3mngl4cj9Gatx .hYWbIwhppukXmGnsiT9H{fill:var(--jp-blue-40)}.ytGBsU015p3LGwOPwFDx{color:var(--jp-green)}.ytGBsU015p3LGwOPwFDx .hYWbIwhppukXmGnsiT9H{fill:var(--jp-green)}.iSc4n8zVaElbs0TPAWH5{align-items:center;display:flex;gap:20px;height:700px;justify-content:center;margin-top:2rem}:root{--font-title-large:36px;--font-title-small:24px;--font-body:16px;--font-label:12px;--jp-black:#000;--jp-black-80:#2c3338;--jp-white:#fff;--jp-white-off:#f9f9f6;--jp-gray:#dcdcde;--jp-gray-0:#f6f7f7;--jp-gray-5:#dcdcde;--jp-gray-10:#c3c4c7;--jp-gray-20:#a7aaad;--jp-gray-30:#8c8f94;--jp-gray-40:#787c82;--jp-gray-50:#646970;--jp-gray-60:#50575e;--jp-gray-70:#3c434a;--jp-gray-80:#2c3338;--jp-gray-90:#1d2327;--jp-gray-100:#101517;--jp-gray-off:#e2e2df;--jp-yellow-5:#f5e6b3;--jp-yellow-10:#f2cf75;--jp-yellow-40:#c08c00;--jp-orange-20:#faa754;--jp-blue-5:#ced9f2;--jp-red-0:#f7ebec;--jp-red-50:#d63638;--jp-red-60:#b32d2e;--jp-red-80:#8a2424;--jp-red:#d63639;--jp-pink:#c9356e;--jp-green-0:#f0f2eb;--jp-green-5:#d0e6b8;--jp-green-10:#9dd977;--jp-green-20:#64ca43;--jp-green-30:#2fb41f;--jp-green-40:#069e08;--jp-green-50:#008710;--jp-green-60:#007117;--jp-green-70:#005b18;--jp-green-80:#004515;--jp-green-90:#003010;--jp-green-100:#001c09;--jp-green:#069e08;--jp-green-primary:var(--jp-green-40);--jp-green-secondary:var(--jp-green-30);--jp-border-radius:4px;--jp-border-radius-rna:8px;--jp-menu-border-height:1px;--jp-underline-thickness:2px;--jp-modal-padding-large:32px;--jp-modal-padding:24px;--jp-modal-padding-small:16px;--jp-modal-radius:8px;--jp-button-padding:8px;--jp-button-radius:4px;--jp-gap:16px;--jp-highlight:#3858e9}:where(body){font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;margin:0;min-height:100%;padding:0}.jp-wrap{align-items:center;display:flex;flex-wrap:wrap;margin:0 auto;max-width:1128px}.jp-row{display:grid;grid-gap:24px;grid-template-columns:repeat(4,1fr);margin:0 16px;width:100%}@media(min-width:600px){.jp-row{grid-template-columns:repeat(8,1fr);margin:0 18px}}@media(min-width:960px){.jp-row{grid-template-columns:repeat(12,1fr);margin:0 24px;max-width:1128px}}.sm-col-span-1{grid-column-end:span 1}.sm-col-span-2{grid-column-end:span 2}.sm-col-span-3{grid-column-end:span 3}.sm-col-span-4{grid-column-end:span 4}@media(min-width:600px){.md-col-span-1{grid-column-end:span 1}.md-col-span-2{grid-column-end:span 2}.md-col-span-3{grid-column-end:span 3}.md-col-span-4{grid-column-end:span 4}.md-col-span-5{grid-column-end:span 5}.md-col-span-6{grid-column-end:span 6}.md-col-span-7{grid-column-end:span 7}.md-col-span-8{grid-column-end:span 8}}@media(min-width:960px){.lg-col-span-1{grid-column-end:span 1}.lg-col-span-2{grid-column-end:span 2}.lg-col-span-3{grid-column-end:span 3}.lg-col-span-4{grid-column-end:span 4}.lg-col-span-5{grid-column-end:span 5}.lg-col-span-6{grid-column-end:span 6}.lg-col-span-7{grid-column-end:span 7}.lg-col-span-8{grid-column-end:span 8}.lg-col-span-9{grid-column-end:span 9}.lg-col-span-10{grid-column-end:span 10}.lg-col-span-11{grid-column-end:span 11}.lg-col-span-12{grid-column-end:span 12}}@media(max-width:960px){.md-col-span-0{display:none}}@media(max-width:600px){.sm-col-span-0{display:none}}.jp-cut{border:2px solid var(--jp-green-primary);border-radius:var(--jp-border-radius);margin:32px 0;padding:16px 24px 16px 64px;position:relative;text-decoration:none}.jp-cut,.jp-cut span{display:block}.jp-cut span:last-of-type{font-weight:600}.jp-cut:focus span:last-of-type,.jp-cut:hover span:last-of-type{text-decoration:underline;text-decoration-thickness:var(--jp-underline-thickness)}.jp-cut:focus:after,.jp-cut:hover:after{transform:translateY(-50%) translateX(-8px)}.jp-cut:after{color:var(--jp-green-primary);content:"→";font-size:24px;font-weight:600;left:24px;position:absolute;top:50%;transform:translateY(-50%);transition:transform .15s ease-out}.components-popover:not(.is-without-arrow):before{border-color:var(--jp-gray)}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=left] .components-popover__content{margin-left:-62px}.icon-tooltip-helper .components-popover:not([data-y-axis=middle])[data-x-axis=right] .components-popover__content{margin-right:-62px}.icon-tooltip-helper .components-popover[data-y-axis=bottom] .components-popover__content{top:2px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:before{top:-6px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=bottom]:after{top:-4px!important}.icon-tooltip-helper .components-popover[data-y-axis=top] .components-popover__content{bottom:10px!important}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:before{bottom:3px}.icon-tooltip-helper .components-popover:not(.is-without-arrow)[data-y-axis=top]:after{bottom:4px}.icon-tooltip-helper.is-wide .components-popover__content{width:440px}.icon-tooltip-wrapper{color:var(--jp-black);display:inline-block;position:relative}.icon-tooltip-wrapper .components-button.is-link:focus:not(:disabled){box-shadow:none}.icon-tooltip-helper{height:18px;pointer-events:none;position:absolute;right:-53px;top:0;width:124px}.icon-tooltip-container{pointer-events:all}.icon-tooltip-container .components-popover__content{border:1px solid var(--jp-gray);border-radius:4px;margin:0 10px;max-width:90vw;outline:none;padding:24px;white-space:normal;width:304px}.icon-tooltip-title{font-size:16px;font-weight:600;line-height:19px}.icon-tooltip-title:not(:last-child){margin-bottom:8px}.icon-tooltip-content{font-size:14px;font-weight:400;line-height:24px}.icon-tooltip-content ul{list-style-type:disc;margin:0 1rem 0 0}.icon-tooltip-content ul li:last-child{margin-bottom:0}.p4qz2tkq0p9hxucJ6Qk2{--padding:calc(var(--spacing-base)*4);color:var(--jp-black)}.lbNDyXioOwvyvbALtCBm{--gap:calc(var(--spacing-base)*3);padding:var(--padding) 0;position:relative}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm{column-gap:var(--gap);display:grid;grid-auto-flow:column;grid-template-columns:repeat(var(--columns),1fr);grid-template-rows:repeat(var(--rows),minmax(min-content,max-content))}.cLaNK_XcbTGlRQ4Tp43Q{margin-top:var(--padding)}.s2Lsn4kbm6BrS3DSndRB .cLaNK_XcbTGlRQ4Tp43Q{display:contents}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>*{background:var(--jp-white);position:relative}.cLaNK_XcbTGlRQ4Tp43Q.CYt1X0eH1icRjhtJ28jx>:after{bottom:0;box-shadow:0 4px 24px rgba(0,0,0,.05);content:"";left:0;position:absolute;right:0;top:0;z-index:-1}.cLaNK_XcbTGlRQ4Tp43Q>:first-child{border-top-left-radius:var(--jp-border-radius);border-top-right-radius:var(--jp-border-radius);border-width:1px 1px 0}.cLaNK_XcbTGlRQ4Tp43Q>:last-child{border-bottom-left-radius:var(--jp-border-radius);border-bottom-right-radius:var(--jp-border-radius);border-width:0 1px 1px}.DAkZc1P9A3K12fjEliMg{display:flex;flex-direction:column;justify-content:space-between;padding:var(--padding)}.WUBuYABl8nymjs9NnCEL{align-items:center;display:flex;padding-bottom:calc(var(--spacing-base)*2);position:relative}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)){padding-top:calc(var(--spacing-base)*2)}.WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{background-color:var(--jp-gray);content:"";height:1px;left:var(--padding);position:absolute;right:var(--padding);top:0;z-index:5}.s2Lsn4kbm6BrS3DSndRB .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{left:unset;right:0;width:calc(100% + var(--gap))}.s2Lsn4kbm6BrS3DSndRB .lbNDyXioOwvyvbALtCBm>:last-child .WUBuYABl8nymjs9NnCEL:not(:nth-child(2)):before{width:100%}.ANtCFeb41NhA8PA3H7ZN,.WUBuYABl8nymjs9NnCEL:last-of-type{padding-bottom:var(--padding)}.Ql2gy_148yW8Vw5vhaKD{padding-left:var(--padding);padding-right:var(--padding)}.EAQrAnQEW1z1BfdY5gbC{margin:0 var(--spacing-base);fill:var(--jp-gray);flex-shrink:0}.EAQrAnQEW1z1BfdY5gbC.JDSTlLoOC_4aUoH2oNM2{fill:var(--jp-green-40)}.EAQrAnQEW1z1BfdY5gbC.zNdQRJ1w7BvaQOYyqzHK{fill:var(--jp-red-50)}.lr7vbX95SKtoe7DarJcZ{margin-right:auto}.s2Lsn4kbm6BrS3DSndRB .lr7vbX95SKtoe7DarJcZ{margin:0 var(--spacing-base);top:1px}.WUBuYABl8nymjs9NnCEL .KRrGp2xdkeBOxLZeuQ6X{fill:var(--jp-gray-20);flex-shrink:0}.H_ZJiRVJg0LiMXPGOcmt{text-align:center;width:fit-content}.H_ZJiRVJg0LiMXPGOcmt>a{color:#000}.s2Lsn4kbm6BrS3DSndRB .H_ZJiRVJg0LiMXPGOcmt{grid-column:2;overflow:hidden;padding-left:var(--padding);padding-right:var(--padding);white-space:nowrap}.x21z_DixObRDsDaWotP1{align-items:right;display:flex;justify-content:right;margin:0 calc(var(--spacing-base)*4)}.dovianZYLKhnbnh9I06o{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-end}.lljtQMhW7lq5tE5SDJEf{align-items:flex-start;display:flex;flex-basis:0;flex-grow:2}.lljtQMhW7lq5tE5SDJEf .NubApIV1vQCRUNprfm6b{margin-right:auto}.dhFQXpZfMwVI8vuYHnwC{align-items:flex-start;display:inline-flex;flex:0 0 auto;position:relative}.dhFQXpZfMwVI8vuYHnwC:first-child{margin-left:calc(var(--spacing-base)*2)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k{color:var(--jp-gray-20)}.dhFQXpZfMwVI8vuYHnwC.eD7hzxFmdtG_MgmBtl_k:after{background:var(--jp-red);border-radius:var(--jp-border-radius);content:" ";display:block;height:3px;margin-top:-2px;pointer-events:none;position:absolute;top:50%;width:100%}.C64ZjjUAqJC1T2Sa7apS{align-items:flex-start;display:flex;flex-wrap:wrap;justify-content:flex-start;margin-bottom:calc(var(--spacing-base)*3)}.UpZDGew6Ay1hPoP6eI7b{color:var(--jp-gray-40);font-size:var(--font-body-small);line-height:20px}.UpZDGew6Ay1hPoP6eI7b:after{content:"​"}.NubApIV1vQCRUNprfm6b{background-color:var(--jp-yellow-10);border-radius:4px;font-size:13px;font-weight:600;margin-right:var(--spacing-base);padding-left:var(--spacing-base);padding-right:var(--spacing-base)}.TDiiPbuW1Z0_05u_pvcK{font-weight:400}.SWwV4Pw6OZ5vU3PqPXmr{--product-card-shadow:rgb(0 0 0/3%);background-color:var(--jp-white);border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);box-shadow:0 2px 6px var(--product-card-shadow),0 1px 2px var(--product-card-shadow)}.r7tUofa9Z3A5ziKVR1H7{align-items:center;display:flex}.r7tUofa9Z3A5ziKVR1H7 img{object-fit:cover;width:100%}.i_AnOR3MaQLraGvb2QU5{background-color:#f9f9f6}.YcYvLvdvWrb1EUZoVsE8{display:flex;flex-wrap:wrap;gap:calc(var(--horizontal-spacing)*2);justify-content:space-between}.uGTTsKoIOoZdYhk6uPnl{white-space:nowrap}.uGTTsKoIOoZdYhk6uPnl>span{font-size:var(--font-body-small)}.NzDTsxhX8D1mlckNpewR{font-weight:400!important}.svE2cJL5t2FarzcDQYNe{--product-card-shadow:rgb(0 0 0/3%);background-color:var(--jp-white);border:1px solid var(--jp-gray);border-radius:var(--jp-border-radius);box-shadow:0 2px 6px var(--product-card-shadow),0 1px 2px var(--product-card-shadow)}.dvEJEDNTnmVfVxtLa4uU{align-items:center;display:flex}.dvEJEDNTnmVfVxtLa4uU img{object-fit:cover;width:100%}.K1VY4DNP8PHMWAEVBC_h{background-color:#f9f9f6}.nk_COGPrkBNLp7lVt4sQ{display:flex;flex-wrap:wrap;gap:calc(var(--horizontal-spacing)*2);justify-content:space-between}.ukgQ5TmLablG3svUKjdw{white-space:nowrap}.ukgQ5TmLablG3svUKjdw>span{font-size:var(--font-body-small)}.Vofm70ADXSe43GamWEaF{font-weight:400!important}.EUcF2LKeC2GyhWD2FKCP{background-color:var(--jp-white);height:100%;padding:calc(var(--spacing-base)*8);position:relative}.Bm21LIBQtpRo3ZhOxXBG{display:flex;gap:calc(var(--spacing-base)*2)}.jwIGzADCnBI_ai9xYYiS{align-items:center;display:flex;flex-wrap:nowrap;font-size:22px;padding-bottom:calc(var(--spacing-base)*3);padding-top:calc(var(--spacing-base)*3)}.jwIGzADCnBI_ai9xYYiS .fTbxuhh_SfMgenyWvGN0{padding-bottom:calc(var(--spacing-base)/3);padding-right:var(--spacing-base)}.eR56lApoP14RIBAhO1UN{display:flex;flex-wrap:wrap;gap:calc(var(--spacing-base)*6);justify-content:space-between;margin:0 auto;max-width:1128px}@media only screen and (max-width:1366px){.eR56lApoP14RIBAhO1UN{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3)}}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD{display:flex;flex:1;flex-direction:column;justify-content:center}@media screen and (min-width:960px){.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD{max-width:70%}}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD .vAGLpjIGi6GA8ghbumN7{font-size:36px;font-weight:700;line-height:40px}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD .oag8YaslCEiUVu8GKKL3{font-weight:400;margin:calc(var(--spacing-base)*3) 0}.eR56lApoP14RIBAhO1UN .vHnITd5JOCOgxCgXTgoD .FhH03GPt9FK1VH9NZhYA{align-self:flex-start;font-size:16px;font-weight:500;letter-spacing:-.01em;line-height:24px;padding:var(--spacing-base) calc(var(--spacing-base)*3)}.eR56lApoP14RIBAhO1UN .VUXAtah2JvUCNc4cXjPp{align-items:center;display:flex;flex-wrap:wrap;gap:calc(var(--spacing-base)*3);justify-content:flex-end}@media only screen and (max-width:430px){.eR56lApoP14RIBAhO1UN .VUXAtah2JvUCNc4cXjPp{flex:1}}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw{border-color:var(--jp-gray-5);border-radius:5px;flex-grow:0;height:168px;margin-bottom:0;padding:calc(var(--spacing-base)*2) calc(var(--spacing-base)*3);width:168px}@media only screen and (max-width:960px){.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw{width:30vw}}@media only screen and (max-width:430px){.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw{min-width:168px;width:100%}}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw>div:first-child{display:flex;flex-direction:column;justify-content:space-between}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw .Ll1l9bEuf5G5oh3AENep{fill:var(--jp-green)}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw .WrzTysWiqUiuEPvpFqau{margin-bottom:var(--spacing-base)}.eR56lApoP14RIBAhO1UN .dyPAjc3M4y3Q6gJfWnjw .d4faYkf9yL7oW7pwcjmP{font-size:36px;font-weight:700}.acffvOSYc5S8x4P_AYnQ{font-size:16px;line-height:24px;padding-bottom:calc(var(--spacing-base)*6);padding-top:calc(var(--spacing-base)*6)}.acffvOSYc5S8x4P_AYnQ:first-child{padding-bottom:0;padding-top:0}.acffvOSYc5S8x4P_AYnQ:nth-child(2n){background-color:var(--jp-white-off);padding-bottom:calc(var(--spacing-base)*8);padding-top:calc(var(--spacing-base)*8)}@media only screen and (max-width:960px){.acffvOSYc5S8x4P_AYnQ:nth-child(2n){padding-bottom:calc(var(--spacing-base)*6);padding-top:calc(var(--spacing-base)*6)}}.acffvOSYc5S8x4P_AYnQ a{color:inherit}.acffvOSYc5S8x4P_AYnQ .M5YNmgy60Q_UtaxKgQcv{margin:0 auto;max-width:744px}@media only screen and (max-width:1366px){.acffvOSYc5S8x4P_AYnQ .M5YNmgy60Q_UtaxKgQcv{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3)}}.acffvOSYc5S8x4P_AYnQ .HJiOvun8sHkiFpNL0sl6{margin:0 auto;max-width:1128px}@media only screen and (max-width:1366px){.acffvOSYc5S8x4P_AYnQ .HJiOvun8sHkiFpNL0sl6{padding-left:calc(var(--spacing-base)*3);padding-right:calc(var(--spacing-base)*3)}}.acffvOSYc5S8x4P_AYnQ .mXinUJfpSTS9EVB8M8K_{font-size:34px;font-weight:400;line-height:40px;margin:0}.acffvOSYc5S8x4P_AYnQ .QKjsnliPyLu4n08yVUUM{font-size:16px}.acffvOSYc5S8x4P_AYnQ .xQJJkJ4v7Jm8iSJ0z0Dj{font-size:48px;line-height:24px;margin-bottom:calc(var(--spacing-base)*6)}.VWIBGwuHqtAKg_5Hch92{flex-direction:column}.VWIBGwuHqtAKg_5Hch92,.VWIBGwuHqtAKg_5Hch92 .mnkNhprYIatxfziERMwM{display:flex;gap:calc(var(--spacing-base)*3);padding:calc(var(--spacing-base)*2) 0}.VWIBGwuHqtAKg_5Hch92 .mnkNhprYIatxfziERMwM{flex-wrap:wrap;min-height:190px}.VWIBGwuHqtAKg_5Hch92 .WEiaYLqJwV2IzC8LD9Fs{background-color:var(--jp-white-off);border-radius:calc(var(--spacing-base)/2);height:157.5px;width:280px}.VWIBGwuHqtAKg_5Hch92 .WEiaYLqJwV2IzC8LD9Fs iframe{border-radius:inherit}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU{display:flex;flex:1;flex-direction:column;gap:var(--spacing-base);min-width:280px}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU ._OeUvI9GrP00qh6Uk7Tg{font-size:20px;font-weight:500;line-height:22px}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU .C6I5jYHW2IJSDBoKvhcB{color:var(--jp-gray-60);flex-grow:1;font-size:16px;font-weight:300;line-height:24px}.VWIBGwuHqtAKg_5Hch92 .GJlowVsJybna1MFcIiIU .XdnAdAwkxAW5yvUx3NRr{font-size:15px;padding-right:0;text-decoration:underline}.MCKgMfLVZtkgWu5m5u6L{margin-bottom:calc(var(--spacing-base)*8)}.c0SItK48SRkWfZUCECbZ{border:1px solid var(--jp-green-40);border-radius:4px;color:var(--jp-green-40);font-size:12px;font-weight:500;height:22px;margin-right:5px;padding:2px 8px;position:relative;text-transform:uppercase;top:-2px}.uPEKVw20OlWzA_8u7YAc{--font-headline-medium:48px;--font-headline-small:36px;--font-title-medium:24px;--font-body:16px;--font-body-small:14px;--font-body-extra-small:14px;--spacing-base:8px;max-height:calc(100% - 24px)}.uPEKVw20OlWzA_8u7YAc .components-modal__header+div{height:100%}.uPEKVw20OlWzA_8u7YAc .components-modal__content{margin:40px;padding:0}.uPEKVw20OlWzA_8u7YAc .components-modal__header{border-bottom:0;height:40px;padding:8px 8px 0}.uPEKVw20OlWzA_8u7YAc .dZO6FXcGE5vhcJ8Y_C9w{height:100%;padding:8px}@media(max-height:768px){.FmxgyZZvzjuwp3GbBNv1{overflow:scroll;padding-bottom:24px;padding-top:24px}.FmxgyZZvzjuwp3GbBNv1 .uPEKVw20OlWzA_8u7YAc{max-height:unset}}.EtaGFgAv0H3akflLBvof,.f6I4877w7XpHhEnooqks{display:flex;flex-direction:column;gap:1rem;justify-content:space-between}.EtaGFgAv0H3akflLBvof{flex:1}.KGwdaPYtQhRLcUVbDyy9 .product-price_container{align-items:center}.IwiPAQFH04pNmEH07X9N{display:flex;flex-direction:row;gap:8px 24px}.DKmru53sFgfEs9AgBdqM{justify-content:center}.DKmru53sFgfEs9AgBdqM,.DKmru53sFgfEs9AgBdqM img{align-items:center;display:flex;height:auto;max-width:100%;overflow:hidden}.DKmru53sFgfEs9AgBdqM img{max-height:100%;object-fit:contain}.anXLrcgHHsm2LnEfXUVk{padding-top:56.25%;position:relative;width:100%}.anXLrcgHHsm2LnEfXUVk iframe{border:none;height:100%;position:absolute;right:0;top:0;width:100%}.pbC573UpPZ3Z1WF6H0rZ{display:flex;flex-direction:column}.uQb9f6VHehuQfLoouBsQ{flex-grow:1;margin:0;margin-bottom:calc(var(--spacing-base)*2);padding:0}.uQb9f6VHehuQfLoouBsQ li{align-items:flex-start;display:flex;list-style:none;margin-bottom:var(--spacing-base)}.uQb9f6VHehuQfLoouBsQ svg{fill:var(--jp-green-primary);flex-shrink:0;margin-left:var(--spacing-base)}._fUXxnSp5pagKBp9gSN7 *{box-sizing:border-box}#my-jetpack-container{--wp-admin-theme-color:var(--jp-black);--wp-admin-theme-color-darker-10:var(--jp-black-80);--wp-admin-theme-color-darker-20:var(--jp-black-80);height:100%}#my-jetpack-container .jp-dashboard-footer__jetpack-symbol{height:16px}#my-jetpack-container:has(.my-jetpack-deprecate-notice-title) .jetpack-deprecation-notice-link{color:inherit;font-weight:600;padding-left:5px}#my-jetpack-container .my-jetpack-deprecate-notice-title{font-weight:600}#wpbody-content>.notice{display:none!important}#wpwrap{background-color:var(--jp-white-off)}.jetpack-admin-full-screen #wpwrap{top:0}.jetpack-admin-full-screen #wpadminbar{display:none}.jetpack-admin-full-screen #wpbody-content{min-height:100vh!important;padding-bottom:0}.jetpack-admin-full-screen #adminmenumain,.jetpack-admin-full-screen #wpcontent>*,.jetpack-admin-full-screen #wpfooter,.jetpack-admin-full-screen .error,.jetpack-admin-full-screen .notice,.jetpack-admin-full-screen .updated{display:none}.jetpack-admin-full-screen #wpcontent{margin-right:0!important;padding-right:0!important}.jetpack-admin-full-screen #wpcontent>#wpbody{display:block;margin-top:0!important;padding-top:0!important} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/composer.json deleted file mode 100644 index 731f21ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/composer.json +++ /dev/null @@ -1,91 +0,0 @@ -{ - "name": "automattic/jetpack-my-jetpack", - "description": "WP Admin page with information and configuration shared among all Jetpack stand-alone plugins", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-admin-ui": "^0.5.7", - "automattic/jetpack-assets": "^4.0.14", - "automattic/jetpack-boost-speed-score": "^0.4.6", - "automattic/jetpack-connection": "^6.8.1", - "automattic/jetpack-explat": "^0.2.13", - "automattic/jetpack-jitm": "^4.2.7", - "automattic/jetpack-licensing": "^3.0.8", - "automattic/jetpack-plugins-installer": "^0.5.4", - "automattic/jetpack-redirect": "^3.0.5", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-plans": "^0.6.1", - "automattic/jetpack-status": "^5.0.10", - "automattic/jetpack-sync": "^4.9.2", - "automattic/jetpack-protect-status": "^0.5.8" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/", - "src/products" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": "pnpm concurrently --names php,js 'php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"' 'pnpm:test-coverage'", - "test-php": [ - "@composer phpunit" - ], - "test-js": [ - "pnpm run test" - ], - "test-js-watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run test --watch" - ], - "build-development": [ - "pnpm run build" - ], - "build-production": [ - "NODE_ENV=production pnpm run build" - ], - "watch": [ - "Composer\\Config::disableProcessTimeout", - "pnpm run watch" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-my-jetpack", - "textdomain": "jetpack-my-jetpack", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-my-jetpack/compare/${old}...${new}" - }, - "branch-alias": { - "dev-trunk": "5.9.x-dev" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-initializer.php" - }, - "dependencies": { - "test-only": [ - "packages/search", - "packages/videopress" - ] - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/global.d.ts b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/global.d.ts deleted file mode 100644 index 55655e55..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/global.d.ts +++ /dev/null @@ -1,725 +0,0 @@ -declare module '*.png'; -declare module '*.svg'; -declare module '*.jpeg'; -declare module '*.jpg'; -declare module '*.scss'; - -// These libraries don't have types, this suppresses the TypeScript errors -declare module '@wordpress/components'; -declare module '@wordpress/compose'; -declare module '@wordpress/icons'; -declare module '@automattic/jetpack-connection'; -declare module '@wordpress/url'; -declare module '@wordpress/i18n'; -declare module '@wordpress/element'; - -type ProductStatus = - | 'active' - | 'inactive' - | 'module_disabled' - | 'site_connection_error' - | 'plugin_absent' - | 'plugin_absent_with_plan' - | 'needs_plan' - | 'needs_activation' - | 'needs_first_site_connection' - | 'user_connection_error' - | 'can_upgrade' - | 'needs_attention' - | 'expired' - | 'expiring'; - -type JetpackModule = - | 'anti-spam' - | 'backup' - | 'boost' - | 'crm' - | 'creator' - | 'extras' - | 'ai' - | 'jetpack-ai' - | 'protect' - | 'scan' - | 'search' - | 'social' - | 'stats' - | 'videopress' - | 'security' - | 'growth' - | 'complete' - | 'site-accelerator' - | 'newsletter' - | 'related-posts' - | 'brute-force'; - -type JetpackModuleWithCard = - | 'anti-spam' - | 'backup' - | 'boost' - | 'crm' - | 'jetpack-ai' - | 'protect' - | 'search' - | 'social' - | 'stats' - | 'videopress'; - -type ThreatItem = { - // Protect API properties (free plan) - id: string; - title: string; - fixed_in: string; - description: string | null; - source: string | null; - // Scan API properties (paid plan) - context: string | null; - filename: string | null; - first_detected: string | null; - fixable: boolean | null; - severity: number | null; - signature: string | null; - status: number | null; -}; - -type ScanItem = { - checked: boolean; - name: string; - slug: string; - threats: ThreatItem[]; - type: string; - version: string; -}; - -type RewindStatus = - | 'missing_plan' - | 'no_connected_jetpack' - | 'no_connected_jetpack_with_credentials' - | 'vp_active_on_site' - | 'vp_can_transfer' - | 'host_not_supported' - | 'multisite_not_supported' - | 'no_site_found'; - -type BackupStatus = - | 'started' - | 'finished' - | 'no-credentials' - | 'backups-deactivated' - | 'no-credentials-atomic' - | 'credential-error' - | 'http-only-error' - | 'not-accessible' - | 'backup-deactivated' - | 'Kill switch active' - | 'error' - | 'error-will-retry'; - -type JetpackPlanSlug = - | 'jetpack_premium' - | 'jetpack_business' - | 'jetpack_free' - | 'jetpack_premium_monthly' - | 'jetpack_business_monthly' - | 'jetpack_personal' - | 'jetpack_personal_monthly' - | 'jetpack_security_daily' - | 'jetpack_security_daily_monthly' - | 'jetpack_security_realtime' - | 'jetpack_security_realtime_monthly' - | 'jetpack_growth_bi_yearly' - | 'jetpack_growth_yearly' - | 'jetpack_growth_monthly' - | 'jetpack_complete_bi_yearly' - | 'jetpack_complete' - | 'jetpack_complete_monthly' - | 'jetpack_security_t1_bi_yearly' - | 'jetpack_security_t1_yearly' - | 'jetpack_security_t1_monthly' - | 'jetpack_security_t2_yearly' - | 'jetpack_security_t2_monthly' - | 'jetpack_starter_yearly' - | 'jetpack_starter_monthly' - | 'jetpack_backup_daily' - | 'jetpack_backup_daily_monthly' - | 'jetpack_backup_realtime' - | 'jetpack_backup_realtime_monthly' - | 'jetpack_search_bi_yearly' - | 'jetpack_search' - | 'jetpack_search_monthly' - | 'jetpack_scan_bi_yearly' - | 'jetpack_scan' - | 'jetpack_scan_monthly' - | 'jetpack_scan_realtime' - | 'jetpack_scan_realtime_monthly' - | 'jetpack_anti_spam_bi_yearly' - | 'jetpack_anti_spam' - | 'jetpack_anti_spam_monthly' - | 'jetpack_backup_t1_bi_yearly' - | 'jetpack_backup_t1_yearly' - | 'jetpack_backup_t1_monthly' - | 'jetpack_backup_t2_yearly' - | 'jetpack_backup_t2_monthly' - | 'jetpack_backup_addon_storage_10gb_monthly' - | 'jetpack_backup_addon_storage_100gb_monthly' - | 'jetpack_backup_addon_storage_1tb_monthly' - | 'jetpack_backup_addon_storage_3tb_monthly' - | 'jetpack_backup_addon_storage_5tb_monthly' - | 'jetpack_videopress_bi_yearly' - | 'jetpack_videopress' - | 'jetpack_videopress_monthly' - | 'jetpack_backup_t0_yearly' - | 'jetpack_backup_t0_monthly' - | 'jetpack_search_free' - | 'jetpack_backup_one_time' - | 'jetpack_stats_free_yearly' - | 'jetpack_stats_pwyw_yearly' - | 'jetpack_stats_monthly' - | 'jetpack_stats_yearly' - | 'jetpack_stats_bi_yearly' - | 'jetpack_monitor_monthly' - | 'jetpack_monitor_yearly' - | 'jetpack_boost_bi_yearly' - | 'jetpack_boost_yearly' - | 'jetpack_boost_monthly' - | 'jetpack_ai_monthly' - | 'jetpack_ai_yearly' - | 'jetpack_ai_bi_yearly' - | 'jetpack_social_monthly' - | 'jetpack_social_basic_bi_yearly' - | 'jetpack_social_basic_yearly' - | 'jetpack_social_basic_monthly' - | 'jetpack_social_advanced_bi_yearly' - | 'jetpack_social_advanced_yearly' - | 'jetpack_social_advanced_monthly' - | 'jetpack_golden_token_lifetime' - | 'jetpack_creator_monthly' - | 'jetpack_creator_yearly' - | 'jetpack_creator_bi_yearly' - | 'jetpack_social_v1_monthly' - | 'jetpack_social_v1_yearly' - | 'jetpack_social_v1_bi_yearly'; - -type BadInstallPluginSlug = - | 'jetpack-beta' - | 'jetpack-videopress' - | 'jetpack-boost' - | 'jetpack-protect' - | 'jetpack-crm' - | 'jetpack-search' - | 'vaultpress' - | 'jetpack-social' - | 'jetpack' - | 'jetpack-starter' - | 'jetpack-vaultpress-backup'; - -type JetpackPluginDisplayName = - | 'Jetpack Beta' - | 'Jetpack VideoPress' - | 'Jetpack Boost' - | 'Jetpack Protect' - | 'Jetpack CRM' - | 'Jetpack Search' - | 'VaultPress' - | 'Jetpack Social' - | 'Jetpack' - | 'Jetpack Starter' - | 'Jetpack VaultPress Backup'; - -type JetpackProductName = - | 'Security Bundle' - | 'CRM' - | 'Newsletter' - | 'Site Accelerator' - | 'Social' - | 'VideoPress' - | 'Related Posts' - | 'Starter' - | 'Stats' - | 'Akismet Anti-spam' - | 'Growth Bundle' - | 'Search' - | 'AI' - | 'VaultPress Backup' - | 'Boost' - | 'Extras' - | 'Complete Bundle' - | 'Protect' - | 'Creator' - | 'Scan'; - -type PurchaseProductName = - | 'Jetpack Premium' - | 'Jetpack Personal' - | 'Jetpack Free' - | 'Jetpack Professional' - | 'Jetpack Security Daily' - | 'Jetpack Security Real-time' - | 'Jetpack Complete' - | 'Jetpack Security (10GB)' - | 'Jetpack Security (1TB)' - | 'Jetpack Growth' - | 'Jetpack Starter' - | 'Jetpack Creator' - | 'Jetpack Search Free' - | 'Jetpack Search' - | 'Jetpack Scan Daily' - | 'Jetpack Scan Realtime' - | 'Jetpack Akismet Anti-spam' - | 'Jetpack VaultPress Backup (1GB)' - | 'Jetpack VaultPress Backup (10GB)' - | 'Jetpack VaultPress Backup (1TB)' - | 'Jetpack VaultPress Backup (One-time)' - | 'Jetpack VaultPress Backup Add-on Storage (10GB)' - | 'Jetpack VaultPress Backup Add-on Storage (100GB)' - | 'Jetpack Anti-spam' - | 'Jetpack Backup' - | 'Jetpack Security' - | 'Jetpack CRM' - | 'Jetpack Social' - | 'Jetpack Boost' - | 'Jetpack Stats' - | 'Jetpack Protect' - | 'Jetpack VideoPress'; - -type PlanExpirationAlert = { - product_slug: JetpackPlanSlug; - product_name?: PurchaseProductName; - expiry_date?: string; - expiry_message?: string; - manage_url?: string; - products_effected?: JetpackProductName[]; -}; - -type PlanExpiredAlerts = Record< `${ JetpackPlanSlug }--plan_expired`, PlanExpirationAlert >; - -type MissingConnectionAlertData = { - type: 'site' | 'user'; - is_error: boolean; -}; - -type MissingConnectionAlert = Record< 'missing-connection', MissingConnectionAlertData >; - -type WelcomeBannerActiveAlert = Record< 'welcome-banner-active', null >; - -type BackupFailureAlertData = { - type: 'warning' | 'error'; - data: BackupNeedsAttentionData; -}; - -type BackupFailureAlert = Record< 'backup_failure', BackupFailureAlertData >; - -type ProtectHasThreatsAlertData = { - type: 'warning' | 'error'; - data: ProtectNeedsAttentionData; -}; - -type ProtectHasThreatsAlert = Record< 'protect_has_threats', ProtectHasThreatsAlertData >; - -type PluginsNeedingInstallAlertData = { - needs_installed?: JetpackModule[]; - needs_activated_only?: JetpackModule[]; -}; - -type PluginsNeedingInstallAlert = Record< - `${ JetpackPlanSlug }--plugins_needing_installed_activated`, - PluginsNeedingInstallAlertData ->; - -type RedBubbleAlerts = MissingConnectionAlert & - WelcomeBannerActiveAlert & - PlanExpiredAlerts & - BackupFailureAlert & - ProtectHasThreatsAlert & - PluginsNeedingInstallAlert; - -type BackupNeedsAttentionData = { - source: 'rewind' | 'last_backup'; - status: RewindStatus | BackupStatus; - last_updated: string; -}; - -type ProtectNeedsAttentionData = { - threat_count: number; - critical_threat_count: number; - fixable_threat_ids: number[]; -}; - -type Purchase = { - ID: string; - user_id: string; - blog_id: string; - product_id: string; - subscribed_date: string; - renew: string; - auto_renew: string; - renew_date: string; - inactive_date: string | null; - active: string; - meta: string | object; - ownership_id: string; - most_recent_renew_date: string; - amount: number; - expiry_date: string; - expiry_message: string; - expiry_sub_message: string; - expiry_status: string; - partner_name: string | null; - partner_slug: string | null; - partner_key_id: string | null; - subscription_status: string; - product_name: string; - product_slug: string; - product_type: string; - blog_created_date: string; - blogname: string; - domain: string; - description: string; - attached_to_purchase_id: string | null; - included_domain: string; - included_domain_purchase_amount: number; - currency_code: string; - currency_symbol: string; - renewal_price_tier_slug: string | null; - renewal_price_tier_usage_quantity: number | null; - current_price_tier_slug: string | null; - current_price_tier_usage_quantity: number | null; - price_tier_list: Array< object >; - price_text: string; - bill_period_label: string; - bill_period_days: number; - regular_price_text: string; - regular_price_integer: number; - product_display_price: string; - price_integer: number; - is_cancelable: boolean; - can_explicit_renew: boolean; - can_disable_auto_renew: boolean; - can_reenable_auto_renewal: boolean; - iap_purchase_management_link: string | null; - is_iap_purchase: boolean; - is_locked: boolean; - is_refundable: boolean; - refund_period_in_days: number; - is_renewable: boolean; - is_renewal: boolean; - has_private_registration: boolean; - refund_amount: number; - refund_integer: number; - refund_currency_symbol: string; - refund_text: string; - refund_options: object | null; - total_refund_amount: number; - total_refund_integer: number; - total_refund_currency: string; - total_refund_text: string; - check_dns: boolean; -}; - -type ProtectData = { - scanData: { - core: ScanItem; - current_progress?: string; - data_source: string; - database: string[]; - error: boolean; - error_code?: string; - error_message?: string; - files: string[]; - has_unchecked_items: boolean; - last_checked: string; - num_plugins_threats: number; - num_themes_threats: number; - num_threats: number; - plugins: ScanItem[]; - status: string; - themes: ScanItem[]; - threats?: ThreatItem[]; - }; - wafConfig: { - automatic_rules_available: boolean; - blocked_logins: number; - bootstrap_path: string; - brute_force_protection: boolean; - jetpack_waf_automatic_rules: '1' | ''; - jetpack_waf_ip_allow_list: '1' | ''; - jetpack_waf_ip_block_list: boolean; - jetpack_waf_ip_list: boolean; - jetpack_waf_share_data: '1' | ''; - jetpack_waf_share_debug_data: boolean; - standalone_mode: boolean; - waf_supported: boolean; - waf_enabled: boolean; - }; -}; - -type VideopressData = { - featuredStats?: { - label: string; - period: 'day' | 'year'; - data: { - views: { - current: number; - previous: number; - }; - impressions: { - current: number; - previous: number; - }; - watch_time: { - current: number; - previous: number; - }; - }; - }; - videoCount: number; -}; - -interface Window { - myJetpackInitialState?: { - siteSuffix: string; - siteUrl: string; - latestBoostSpeedScores: { - previousScores: { - desktop: number; - mobile: number; - }; - scores: { - desktop: number; - mobile: number; - }; - theme: string; - timestamp: number; - }; - IDCContainerID: string; - adminUrl: string; - blogID: string; - fileSystemWriteAccess: 'yes' | 'no'; - isStatsModuleActive: string; - canUserViewStats: boolean; - isUserFromKnownHost: string; - loadAddLicenseScreen: string; - myJetpackCheckoutUri: string; - myJetpackFlags: { - showFullJetpackStatsCard: boolean; - videoPressStats: boolean; - }; - purchaseToken: string; - lifecycleStats: { - historicallyActiveModules: JetpackModule[]; - brokenModules: { - needs_site_connection: JetpackModule[]; - needs_user_connection: JetpackModule[]; - }; - isSiteConnected: boolean; - isUserConnected: boolean; - jetpackPlugins: Array< string >; - modules: Array< string >; - }; - myJetpackUrl: string; - myJetpackVersion: string; - plugins: { - [ key: string ]: { - Name: string; - PluginURI: string; - Version: string; - Title: string; - Description: string; - Author: string; - AuthorName: string; - AuthorURI: string; - DomainPath: string; - textDomain: string; - RequiresPHP: string; - RequiresWP: string; - UpdateURI: string; - Network: boolean; - active: boolean; - }; - }; - products: { - items: { - [ key: string ]: { - class: string; - description: string; - category: 'security' | 'performance' | 'growth' | 'create' | 'management'; - disclaimers: Array< string[] >; - features: string[]; - has_free_offering: boolean; - feature_identifying_paid_plan: string; - has_paid_plan_for_product: boolean; - features_by_tier: Array< string >; - is_bundle: boolean; - is_feature: boolean; - is_plugin_active: boolean; - is_tiered_pricing: boolean; - is_upgradable: boolean; - is_upgradable_by_bundle: string[]; - long_description: string; - manage_url: string; - name: string; - plugin_slug: string; - post_activation_url: string; - post_checkout_url?: string; - manage_paid_plan_purchase_url?: string; - renew_paid_plan_purchase_url?: string; - pricing_for_ui?: { - available: boolean; - wpcom_product_slug: string; - wpcom_free_product_slug?: string; - product_term: string; - currency_code: string; - full_price: number; - full_price_per_month?: number; - discount_price: number; - discount_price_per_month?: number; - coupon_discount: number; - is_introductory_offer: boolean; - introductory_offer?: { - cost_per_interval: number; - interval_count: number; - interval_unit: string; - should_prorate_when_offer_ends: boolean; - transition_after_renewal_count: number; - usage_limit?: number; - reason?: { - errors: { - introductoryOfferRemovedSubscriptionFound: string[]; - }; - }; - }; - tiers?: { - [ key: string ]: { - available: boolean; - currencyCode: string; - discountPrice: number; - discountPricePerMonth?: number; - fullPrice: number; - fullPricePerMonth?: number; - introductoryOffer?: { - costPerInterval: number; - intervalCount: number; - intervalUnit: string; - shouldProrateWhenOfferEnds: boolean; - transitionAfterRenewalCount: number; - usageLimit?: number; - reason?: { - errors: { - introductoryOfferRemovedSubscriptionFound: string[]; - }; - }; - }; - isIntroductoryOffer: boolean; - productTerm: string; - wpcomProductSlug: string; - quantity: number; - }; - }; - }; - purchase_url?: string; - requires_user_connection: boolean; - slug: JetpackModule; - standalone_plugin_info: { - has_standalone_plugin: boolean; - is_standalone_installed: boolean; - is_standalone_active: boolean; - }; - status: ProductStatus; - supported_products: string[]; - tiers: string[]; - title: string; - wpcom_product_slug: string; - doesModuleNeedAttention: - | false - | { - type: 'warning' | 'error'; - data: BackupNeedsAttentionData | ProtectNeedsAttentionData; - status?: BackupStatus | RewindStatus; - }; - }; - }; - }; - recommendedModules: { - modules: JetpackModule[] | null; - dismissed: boolean; - isFirstRun: boolean; - }; - themes: { - [ key: string ]: { - Author: string; - Name: string; - RequiresPHP: string; - RequiresWP: string; - Status: string; - Template: string; - TextDomain: string; - ThemeURI: string; - Version: string; - active: boolean; - is_block_theme: boolean; - }; - }; - topJetpackMenuItemUrl: string; - isAtomic: boolean; - sandboxedDomain: string; - isDevVersion: boolean; - userIsAdmin: string; - }; - JP_CONNECTION_INITIAL_STATE: { - apiRoot: string; - apiNonce: string; - registrationNonce: string; - connectionStatus: { - isActive: boolean; - isStaging: boolean; - isRegistered: boolean; - isUserConnected: boolean; - hasConnectedOwner: boolean; - offlineMode: { - isActive: boolean; - constant: boolean; - url: boolean; - filter: boolean; - wpLocalConstant: boolean; - }; - isPublic: boolean; - }; - userConnectionData: { - currentUser: { - isConnected: boolean; - isMaster: boolean; - username: string; - id: number; - blogId: number; - wpcomUser: { - avatar: boolean; - display_name: string; - email: string; - }; - gravatar: string; - permissions: { - admin_page?: boolean; - connect: boolean; - connect_user: boolean; - disconnect: boolean; - edit_posts?: boolean; - manage_modules?: boolean; - manage_options?: boolean; - manage_plugins?: boolean; - network_admin?: boolean; - network_sites_page?: boolean; - publish_posts?: boolean; - view_stats?: boolean; - }; - }; - connectionOwner: null; - }; - connectedPlugins: object; - wpVersion: string; - siteSuffix: string; - connectionErrors: Array< string | object >; - }; - myJetpackRest?: { - apiRoot: string; - apiNonce: string; - }; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-activitylog.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-activitylog.php deleted file mode 100644 index 4de90c07..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-activitylog.php +++ /dev/null @@ -1,57 +0,0 @@ -is_user_connected() ) { - return; - } - - // Do not display the menu on Multisite. - if ( is_multisite() ) { - return; - } - - $args = array(); - - $blog_id = Connection_Manager::get_site_id( true ); - if ( $blog_id ) { - $args = array( 'site' => $blog_id ); - } - - return Admin_Menu::add_menu( - __( 'Activity Log', 'jetpack-my-jetpack' ), - _x( 'Activity Log', 'product name shown in menu', 'jetpack-my-jetpack' ) . ' ', - 'manage_options', - esc_url( Redirect::get_url( 'cloud-activity-log-wp-menu', $args ) ), - null, - 8 - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-historically-active-modules.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-historically-active-modules.php deleted file mode 100644 index d34ce482..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-historically-active-modules.php +++ /dev/null @@ -1,112 +0,0 @@ - \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::rest_trigger_historically_active_modules_update', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Check user capabilities to access historically active modules. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - return current_user_can( 'edit_posts' ); - } - - /** - * Update historically active Jetpack plugins - * Historically active is defined as the Jetpack plugins that are installed and active with the required connections - * This array will consist of any plugins that were active at one point in time and are still enabled on the site - * - * @return void - */ - public static function update_historically_active_jetpack_modules() { - $historically_active_modules = \Jetpack_Options::get_option( 'historically_active_modules', array() ); - $products = Products::get_products(); - $product_classes = Products::get_products_classes(); - - foreach ( $products as $product ) { - $product_slug = $product['slug']; - $status = $product_classes[ $product_slug ]::get_status(); - // We want to leave modules in the array if they've been active in the past - // and were not manually disabled by the user. - if ( in_array( $status, Products::$broken_module_statuses, true ) ) { - continue; - } - - // If the module is active and not already in the array, add it - if ( - in_array( $status, Products::$active_module_statuses, true ) && - ! in_array( $product_slug, $historically_active_modules, true ) - ) { - $historically_active_modules[] = $product_slug; - } - - // If the module has been disabled due to a manual user action, - // or because of a missing plan error, remove it from the array - if ( in_array( $status, Products::$disabled_module_statuses, true ) ) { - $historically_active_modules = array_values( array_diff( $historically_active_modules, array( $product_slug ) ) ); - } - } - - \Jetpack_Options::update_option( 'historically_active_modules', array_unique( $historically_active_modules ) ); - } - - /** - * REST API endpoint to trigger an update to the historically active Jetpack modules - * - * @return WP_Error|\WP_REST_Response - */ - public static function rest_trigger_historically_active_modules_update() { - self::update_historically_active_jetpack_modules(); - $historically_active_modules = \Jetpack_Options::get_option( 'historically_active_modules', array() ); - return rest_ensure_response( $historically_active_modules ); - } - - /** - * Set transient to queue an update to the historically active Jetpack modules on the next wp-admin load - * - * @param string $plugin The plugin that triggered the update. This will be present if the function was queued by a plugin activation. - * - * @return void - */ - public static function queue_historically_active_jetpack_modules_update( $plugin = null ) { - $plugin_filenames = Products::get_all_plugin_filenames(); - - if ( ! $plugin || in_array( $plugin, $plugin_filenames, true ) ) { - set_transient( self::UPDATE_HISTORICALLY_ACTIVE_JETPACK_MODULES_KEY, true ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php deleted file mode 100644 index 7d1a4a77..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php +++ /dev/null @@ -1,698 +0,0 @@ -initialize(); - } - - // Initialize Boost Speed Score - new Speed_Score( array(), 'jetpack-my-jetpack' ); - - // Add custom WP REST API endoints. - add_action( 'rest_api_init', array( __CLASS__, 'register_rest_endpoints' ) ); - - add_action( 'admin_menu', array( __CLASS__, 'add_my_jetpack_menu_item' ) ); - - add_action( 'admin_init', array( __CLASS__, 'setup_historically_active_jetpack_modules_sync' ) ); - // This is later than the admin-ui package, which runs on 1000 - add_action( 'admin_init', array( __CLASS__, 'maybe_show_red_bubble' ), 1001 ); - - //  Set up the ExPlat package endpoints - ExPlat::init(); - - // Sets up JITMS. - JITM::configure(); - - // Add "Activity Log" menu item. - Activitylog::init(); - - // Add "Jetpack Manage" menu item. - Jetpack_Manage::init(); - - /** - * Fires after the My Jetpack package is initialized - * - * @since 0.1.0 - */ - do_action( 'my_jetpack_init' ); - } - - /** - * Acts as a feature flag, returning a boolean for whether we should show the licensing UI. - * - * @since 1.2.0 - * - * @return boolean - */ - public static function is_licensing_ui_enabled() { - // Default changed to true in 1.5.0. - $is_enabled = true; - - /* - * Bail if My Jetpack is not enabled, - * and thus the licensing UI shouldn't be enabled either. - */ - if ( ! self::should_initialize() ) { - $is_enabled = false; - } - - /** - * Acts as a feature flag, returning a boolean for whether we should show the licensing UI. - * - * @param bool $is_enabled Defaults to true. - * - * @since 1.2.0 - * @since 1.5.0 Update default value to true. - */ - return apply_filters( - 'jetpack_my_jetpack_should_enable_add_license_screen', - $is_enabled - ); - } - - /** - * Add My Jetpack menu item to the admin menu. - * - * @return void - */ - public static function add_my_jetpack_menu_item() { - $page_suffix = Admin_Menu::add_menu( - __( 'My Jetpack', 'jetpack-my-jetpack' ), - __( 'My Jetpack', 'jetpack-my-jetpack' ), - 'edit_posts', - 'my-jetpack', - array( __CLASS__, 'admin_page' ), - -1 - ); - add_action( 'load-' . $page_suffix, array( __CLASS__, 'admin_init' ) ); - } - - /** - * Callback for the load my jetpack page hook. - * - * @return void - */ - public static function admin_init() { - self::$site_info = self::get_site_info(); - add_filter( 'identity_crisis_container_id', array( static::class, 'get_idc_container_id' ) ); - add_action( 'admin_enqueue_scripts', array( __CLASS__, 'enqueue_scripts' ) ); - // Product statuses are constantly changing, so we never want to cache the page. - header( 'Cache-Control: no-cache, no-store, must-revalidate' ); - header( 'Pragma: no-cache' ); - header( 'Expires: 0' ); - } - - /** - * Returns whether we are in condition to track to use - * Analytics functionality like Tracks, MC, or GA. - */ - public static function can_use_analytics() { - $status = new Status(); - $connection = new Connection_Manager(); - $tracking = new Tracking( 'jetpack', $connection ); - - return $tracking->should_enable_tracking( new Terms_Of_Service(), $status ); - } - - /** - * Enqueue admin page assets. - * - * @return void - */ - public static function enqueue_scripts() { - /** - * Fires after the My Jetpack page is initialized. - * Allows for enqueuing additional scripts only on the My Jetpack page. - * - * @since 4.35.7 - */ - do_action( 'myjetpack_enqueue_scripts' ); - Assets::register_script( - 'my_jetpack_main_app', - '../build/index.js', - __FILE__, - array( - 'enqueue' => true, - 'in_footer' => true, - 'textdomain' => 'jetpack-my-jetpack', - ) - ); - $modules = new Modules(); - $connection = new Connection_Manager(); - $speed_score_history = new Speed_Score_History( get_site_url() ); - $latest_score = $speed_score_history->latest(); - $previous_score = array(); - if ( $speed_score_history->count() > 1 ) { - $previous_score = $speed_score_history->latest( 1 ); - } - $latest_score['previousScores'] = $previous_score['scores'] ?? array(); - - $sandboxed_domain = ''; - $is_dev_version = false; - if ( class_exists( 'Jetpack' ) ) { - $is_dev_version = Jetpack::is_development_version(); - $sandboxed_domain = defined( 'JETPACK__SANDBOX_DOMAIN' ) ? JETPACK__SANDBOX_DOMAIN : ''; - } - - wp_localize_script( - 'my_jetpack_main_app', - 'myJetpackInitialState', - array( - 'products' => array( - 'items' => Products::get_products(), - ), - 'plugins' => Plugins_Installer::get_plugins(), - 'themes' => Sync_Functions::get_themes(), - 'myJetpackUrl' => admin_url( 'admin.php?page=my-jetpack' ), - 'myJetpackCheckoutUri' => admin_url( 'admin.php?page=my-jetpack' ), - 'topJetpackMenuItemUrl' => Admin_Menu::get_top_level_menu_item_url(), - 'siteSuffix' => ( new Status() )->get_site_suffix(), - 'siteUrl' => esc_url( get_site_url() ), - 'blogID' => Connection_Manager::get_site_id( true ), - 'myJetpackVersion' => self::PACKAGE_VERSION, - 'myJetpackFlags' => self::get_my_jetpack_flags(), - 'fileSystemWriteAccess' => self::has_file_system_write_access(), - 'loadAddLicenseScreen' => self::is_licensing_ui_enabled(), - 'adminUrl' => esc_url( admin_url() ), - 'IDCContainerID' => static::get_idc_container_id(), - 'userIsAdmin' => current_user_can( 'manage_options' ), - 'lifecycleStats' => array( - 'jetpackPlugins' => self::get_installed_jetpack_plugins(), - 'historicallyActiveModules' => \Jetpack_Options::get_option( 'historically_active_modules', array() ), - 'brokenModules' => Red_Bubble_Notifications::check_for_broken_modules(), - 'isSiteConnected' => $connection->is_connected(), - 'isUserConnected' => $connection->is_user_connected(), - 'modules' => self::get_active_modules(), - ), - 'recommendedModules' => array( - 'modules' => self::get_recommended_modules(), - 'isFirstRun' => \Jetpack_Options::get_option( 'recommendations_first_run', true ), - 'dismissed' => \Jetpack_Options::get_option( 'dismissed_recommendations', false ), - ), - 'isStatsModuleActive' => $modules->is_active( 'stats' ), - 'canUserViewStats' => current_user_can( 'manage_options' ) || current_user_can( 'view_stats' ), - 'sandboxedDomain' => $sandboxed_domain, - 'isDevVersion' => $is_dev_version, - 'isAtomic' => ( new Status_Host() )->is_woa_site(), - 'latestBoostSpeedScores' => $latest_score, - ) - ); - - wp_localize_script( - 'my_jetpack_main_app', - 'myJetpackRest', - array( - 'apiRoot' => esc_url_raw( rest_url() ), - 'apiNonce' => wp_create_nonce( 'wp_rest' ), - ) - ); - - // Connection Initial State. - Connection_Initial_State::render_script( 'my_jetpack_main_app' ); - - // Required for Analytics. - if ( self::can_use_analytics() ) { - Tracking::register_tracks_functions_scripts( true ); - } - } - - /** - * Get installed Jetpack plugins - * - * @return array - */ - public static function get_installed_jetpack_plugins() { - $plugin_slugs = array_keys( Plugins_Installer::get_plugins() ); - $plugin_slugs = array_map( - static function ( $slug ) { - $parts = explode( '/', $slug ); - if ( empty( $parts ) ) { - return ''; - } - // Return the last segment of the filepath without the PHP extension - return str_replace( '.php', '', $parts[ count( $parts ) - 1 ] ); - }, - $plugin_slugs - ); - - return array_values( array_intersect( self::JETPACK_PLUGIN_SLUGS, $plugin_slugs ) ); - } - - /** - * Get active modules (except ones enabled by default) - * - * @return array - */ - public static function get_active_modules() { - $modules = new Modules(); - $active_modules = $modules->get_active(); - - // if the Jetpack plugin is active, filter out the modules that are active by default - if ( class_exists( 'Jetpack' ) && ! empty( $active_modules ) ) { - $active_modules = array_diff( $active_modules, Jetpack::get_default_modules() ); - } - return array_values( $active_modules ); - } - - /** - * Determine if the current user is "new" to Jetpack - * This is used to vary some messaging in My Jetpack - * - * On the front-end, purchases are also taken into account - * - * @return bool - */ - public static function is_jetpack_user_new() { - // is the user connected? - $connection = new Connection_Manager(); - if ( $connection->is_user_connected() ) { - return false; - } - - // TODO: add a data point for the last known connection/ disconnection time - - // are any modules active? - $active_modules = self::get_active_modules(); - if ( ! empty( $active_modules ) ) { - return false; - } - - // check for other Jetpack plugins that are installed on the site (active or not) - // If there's more than one Jetpack plugin active, this user is not "new" - $plugin_slugs = array_keys( Plugins_Installer::get_plugins() ); - $plugin_slugs = array_map( - static function ( $slug ) { - $parts = explode( '/', $slug ); - if ( empty( $parts ) ) { - return ''; - } - // Return the last segment of the filepath without the PHP extension - return str_replace( '.php', '', $parts[ count( $parts ) - 1 ] ); - }, - $plugin_slugs - ); - $installed_jetpack_plugins = array_intersect( self::JETPACK_PLUGIN_SLUGS, $plugin_slugs ); - if ( is_countable( $installed_jetpack_plugins ) && count( $installed_jetpack_plugins ) >= 2 ) { - return false; - } - - // Does the site have any purchases? - $purchases = Wpcom_Products::get_site_current_purchases(); - if ( ! empty( $purchases ) && ! is_wp_error( $purchases ) ) { - return false; - } - - return true; - } - - /** - * Build flags for My Jetpack UI - * - * @return array - */ - public static function get_my_jetpack_flags() { - $flags = array( - 'videoPressStats' => Jetpack_Constants::is_true( 'JETPACK_MY_JETPACK_VIDEOPRESS_STATS_ENABLED' ), - 'showFullJetpackStatsCard' => class_exists( 'Jetpack' ), - ); - - return $flags; - } - - /** - * Echoes the admin page content. - * - * @return void - */ - public static function admin_page() { - echo '
            '; - } - - /** - * Register the REST API routes. - * - * @return void - */ - public static function register_rest_endpoints() { - new REST_Products(); - new REST_Purchases(); - new REST_Zendesk_Chat(); - new REST_AI(); - new REST_Recommendations_Evaluation(); - - Products::register_product_endpoints(); - Historically_Active_Modules::register_rest_endpoints(); - Jetpack_Manage::register_rest_endpoints(); - Red_Bubble_Notifications::register_rest_endpoints(); - - register_rest_route( - 'my-jetpack/v1', - 'site', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_site', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - - register_rest_route( - 'my-jetpack/v1', - 'site/dismiss-welcome-banner', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::dismiss_welcome_banner', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Check user capability to access the endpoint. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - return current_user_can( 'manage_options' ); - } - - /** - * Return true if we should initialize the My Jetpack admin page. - */ - public static function should_initialize() { - $should = true; - - if ( is_multisite() ) { - $should = false; - } - - // All options presented in My Jetpack require a connection to WordPress.com. - if ( ( new Status() )->is_offline_mode() ) { - $should = false; - } - - /** - * Allows filtering whether My Jetpack should be initialized. - * - * @since 0.5.0-alpha - * - * @param bool $shoud_initialize Should we initialize My Jetpack? - */ - return apply_filters( 'jetpack_my_jetpack_should_initialize', $should ); - } - - /** - * Hook into several connection-based actions to update the historically active Jetpack modules - * If the transient that indicates the list needs to be synced, update it and delete the transient - * - * @return void - */ - public static function setup_historically_active_jetpack_modules_sync() { - // yummmm. ham. - $ham = new Historically_Active_Modules(); - if ( get_transient( $ham::UPDATE_HISTORICALLY_ACTIVE_JETPACK_MODULES_KEY ) && ! wp_doing_ajax() ) { - $ham::update_historically_active_jetpack_modules(); - delete_transient( $ham::UPDATE_HISTORICALLY_ACTIVE_JETPACK_MODULES_KEY ); - } - - $actions = array( - 'jetpack_site_registered', - 'jetpack_user_authorized', - 'activated_plugin', - ); - - foreach ( $actions as $action ) { - add_action( $action, array( $ham, 'queue_historically_active_jetpack_modules_update' ), 5 ); - } - - // Modules are often updated async, so we need to update them right away as there will sometimes be no page reload. - add_action( 'jetpack_activate_module', array( $ham, 'update_historically_active_jetpack_modules' ), 5 ); - } - - /** - * Site full-data endpoint. - * - * @return object Site data. - */ - public static function get_site() { - $site_id = \Jetpack_Options::get_option( 'id' ); - $wpcom_endpoint = sprintf( '/sites/%d?force=wpcom', $site_id ); - $wpcom_api_version = '1.1'; - $response = Client::wpcom_json_api_request_as_blog( $wpcom_endpoint, $wpcom_api_version ); - $response_code = wp_remote_retrieve_response_code( $response ); - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( is_wp_error( $response ) || empty( $response['body'] ) ) { - return new WP_Error( 'site_data_fetch_failed', 'Site data fetch failed', array( 'status' => $response_code ) ); - } - - return rest_ensure_response( $body ); - } - - /** - * Populates the self::$site_info var with site data from the /sites/%d endpoint - * - * @return object|WP_Error - */ - public static function get_site_info() { - static $site_info = null; - - if ( $site_info !== null ) { - return $site_info; - } - - // Check for a cached value before doing lookup - $stored_site_info = get_transient( self::MY_JETPACK_SITE_INFO_TRANSIENT_KEY ); - if ( $stored_site_info !== false ) { - return $stored_site_info; - } - - $response = self::get_site(); - if ( is_wp_error( $response ) ) { - return $response; - } - $site_info = $response->data; - set_transient( self::MY_JETPACK_SITE_INFO_TRANSIENT_KEY, $site_info, DAY_IN_SECONDS ); - - return $site_info; - } - - /** - * Returns whether a site has been determined "commercial" or not. - * - * @return bool|null - */ - public static function is_commercial_site() { - if ( is_wp_error( self::$site_info ) ) { - return null; - } - - return empty( self::$site_info->options->is_commercial ) ? false : self::$site_info->options->is_commercial; - } - - /** - * Check if site is registered (has been connected before). - * - * @return bool - */ - public static function is_registered() { - return (bool) \Jetpack_Options::get_option( 'id' ); - } - - /** - * Dismiss the welcome banner. - * - * @return \WP_REST_Response - */ - public static function dismiss_welcome_banner() { - \Jetpack_Options::update_option( 'dismissed_welcome_banner', true ); - return rest_ensure_response( array( 'success' => true ) ); - } - - /** - * Returns true if the site has file write access to the plugins folder, false otherwise. - * - * @return string - **/ - public static function has_file_system_write_access() { - - $cache = get_transient( 'my_jetpack_write_access' ); - - if ( false !== $cache ) { - return $cache; - } - - if ( ! function_exists( 'get_filesystem_method' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - require_once ABSPATH . 'wp-admin/includes/template.php'; - - $write_access = 'no'; - - $filesystem_method = get_filesystem_method( array(), WP_PLUGIN_DIR ); - if ( 'direct' === $filesystem_method ) { - $write_access = 'yes'; - } - - if ( ! $write_access ) { - ob_start(); - $filesystem_credentials_are_stored = request_filesystem_credentials( self_admin_url() ); - ob_end_clean(); - - if ( $filesystem_credentials_are_stored ) { - $write_access = 'yes'; - } - } - - set_transient( 'my_jetpack_write_access', $write_access, 30 * MINUTE_IN_SECONDS ); - - return $write_access; - } - - /** - * Get container IDC for the IDC screen. - * - * @return string - */ - public static function get_idc_container_id() { - return static::IDC_CONTAINER_ID; - } - - /** - * Conditionally append the red bubble notification to the "Jetpack" menu item if there are alerts to show - * - * @return void - */ - public static function maybe_show_red_bubble() { - global $menu; - - // Don't show red bubble alerts for non-admin users - // These alerts are generally only actionable for admins - if ( ! current_user_can( 'manage_options' ) ) { - return; - } - $rbn = new Red_Bubble_Notifications(); - - // filters for the items in this file - add_filter( 'my_jetpack_red_bubble_notification_slugs', array( $rbn, 'add_red_bubble_alerts' ) ); - $red_bubble_alerts = array_filter( - $rbn::get_red_bubble_alerts(), - function ( $alert ) { - // We don't want to show the red bubble for silent alerts - return empty( $alert['is_silent'] ); - } - ); - - // The Jetpack menu item should be on index 3 - if ( - ! empty( $red_bubble_alerts ) && - is_countable( $red_bubble_alerts ) && - isset( $menu[3] ) && - $menu[3][0] === 'Jetpack' - ) { - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $menu[3][0] .= sprintf( ' %d', count( $red_bubble_alerts ) ); - } - } - - /** - * Get list of module names sorted by their recommendation score - * - * @return array|null - */ - public static function get_recommended_modules() { - $recommendations_evaluation = \Jetpack_Options::get_option( 'recommendations_evaluation', null ); - - if ( ! $recommendations_evaluation ) { - return null; - } - - arsort( $recommendations_evaluation ); // Sort by scores in descending order - - return array_keys( $recommendations_evaluation ); // Get only module names - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-jetpack-manage.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-jetpack-manage.php deleted file mode 100644 index 81fc9acc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-jetpack-manage.php +++ /dev/null @@ -1,172 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_jetpack_manage_data', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Check user capabilities to access historically active modules. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - return current_user_can( 'manage_options' ); - } - - /** - * The page to be added to submenu - * - * @return void|null|string The resulting page's hook_suffix - */ - public static function add_submenu_jetpack() { - // Do not display the menu if the user has < 2 sites. - if ( ! self::could_use_jp_manage( 2 ) ) { - return; - } - - $args = array(); - - $blog_id = Connection_Manager::get_site_id( true ); - if ( $blog_id ) { - $args = array( 'site' => $blog_id ); - } - - return Admin_Menu::add_menu( - __( 'Jetpack Manage', 'jetpack-my-jetpack' ), - _x( 'Jetpack Manage', 'product name shown in menu', 'jetpack-my-jetpack' ) . ' ', - 'manage_options', - esc_url( Redirect::get_url( 'cloud-manage-dashboard-wp-menu', $args ) ), - null, - 15 - ); - } - - /** - * Check if the user has enough sites to be able to use Jetpack Manage. - * - * @param int $min_sites Minimum number of sites to be able to use Jetpack Manage. - * - * @return bool Return true if the user has enough sites to be able to use Jetpack Manage. - */ - public static function could_use_jp_manage( $min_sites = 2 ) { - // Only proceed if the user is connected to WordPress.com. - if ( ! ( new Connection_Manager() )->is_user_connected() ) { - return false; - } - - // Do not display the menu if Jetpack plugin is not installed. - if ( ! class_exists( 'Jetpack' ) ) { - return false; - } - - // Do not display the menu on Multisite. - if ( is_multisite() ) { - return false; - } - - // Check if the user has the minimum number of sites. - $user_data = ( new Connection_Manager() )->get_connected_user_data( get_current_user_id() ); - if ( ! isset( $user_data['site_count'] ) || $user_data['site_count'] < $min_sites ) { - return false; - } - - return true; - } - - /** - * Check if the user is a partner/agency. - * - * @return bool Return true if the user is a partner/agency, otherwise false. - */ - public static function is_agency_account() { - // Only proceed if the user is connected to WordPress.com. - if ( ! ( new Connection_Manager() )->is_user_connected() ) { - return false; - } - - // Get the cached partner data. - $partner = get_transient( 'jetpack_partner_data' ); - - if ( $partner === false ) { - $wpcom_response = Client::wpcom_json_api_request_as_user( '/jetpack-partners' ); - - if ( 200 !== wp_remote_retrieve_response_code( $wpcom_response ) || is_wp_error( $wpcom_response ) ) { - return false; - } - - $partner_data = json_decode( wp_remote_retrieve_body( $wpcom_response ) ); - - // The jetpack-partners endpoint will return only one partner data into an array, it uses Jetpack_Partner::find_by_owner. - if ( ! is_array( $partner_data ) || count( $partner_data ) !== 1 || ! is_object( $partner_data[0] ) ) { - return false; - } - - $partner = $partner_data[0]; - - // Cache the partner data for 1 hour. - set_transient( 'jetpack_partner_data', $partner, HOUR_IN_SECONDS ); - } - - return $partner->partner_type === 'agency'; - } - - /** - * Get Jetpack Manage data for REST API. - * - * @return WP_Error|WP_REST_Response - */ - public static function get_jetpack_manage_data() { - $is_enabled = self::could_use_jp_manage(); - $is_agency_account = self::is_agency_account(); - - return rest_ensure_response( - array( - 'isEnabled' => $is_enabled, - 'isAgencyAccount' => $is_agency_account, - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php deleted file mode 100644 index 02e056d5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php +++ /dev/null @@ -1,465 +0,0 @@ - Products\Anti_Spam::class, - 'backup' => Products\Backup::class, - 'boost' => Products\Boost::class, - 'crm' => Products\Crm::class, - 'creator' => Products\Creator::class, - 'extras' => Products\Extras::class, - 'jetpack-ai' => Products\Jetpack_Ai::class, - // TODO: Remove this duplicate class ('ai')? See: https://github.com/Automattic/jetpack/pull/35910#pullrequestreview-2456462227 - 'ai' => Products\Jetpack_Ai::class, - 'scan' => Products\Scan::class, - 'search' => Products\Search::class, - 'social' => Products\Social::class, - 'security' => Products\Security::class, - 'protect' => Products\Protect::class, - 'videopress' => Products\Videopress::class, - 'stats' => Products\Stats::class, - 'growth' => Products\Growth::class, - 'complete' => Products\Complete::class, - // Features - 'newsletter' => Products\Newsletter::class, - 'site-accelerator' => Products\Site_Accelerator::class, - 'related-posts' => Products\Related_Posts::class, - ); - - /** - * This filter allows plugin to override the Product class of a given product. The new class must be a child class of the default one declared in My Jetpack - * - * For example, a stand-alone plugin could overwrite its product class to control specific behavior of the product in the My Jetpack page after it is active without having to commit changes to the My Jetpack package: - * - * add_filter( 'my_jetpack_products_classes', function( $classes ) { - * $classes['my_plugin'] = 'My_Plugin'; // a class that extends the original one declared in the My Jetpack package. - * return $classes - * } ); - * - * @param array $classes An array where the keys are the product slugs and the values are the class names. - */ - $final_classes = apply_filters( 'my_jetpack_products_classes', $classes ); - - // Check that the classes are still child of the same original classes. - foreach ( (array) $final_classes as $slug => $final_class ) { - if ( $final_class === $classes[ $slug ] ) { - continue; - } - if ( ! class_exists( $final_class ) || ! is_subclass_of( $final_class, $classes[ $slug ] ) ) { - throw new \Exception( 'You can only overwrite a Product class with a child of the original class.' ); - } - } - - return $final_classes; - } - - /** - * Register endpoints related to product classes - * - * @return void - */ - public static function register_product_endpoints() { - $classes = self::get_products_classes(); - - foreach ( $classes as $class ) { - $class::register_endpoints(); - } - } - - /** - * List of product slugs that are displayed on the main My Jetpack page - * - * @var array - */ - public static $shown_products = array( - 'anti-spam', - 'backup', - 'boost', - 'crm', - 'jetpack-ai', - 'search', - 'social', - 'protect', - 'videopress', - 'stats', - ); - - /** - * Gets the list of product slugs that are Not displayed on the main My Jetpack page - * - * @return array - */ - public static function get_not_shown_products() { - return array_diff( array_keys( static::get_products_classes() ), self::$shown_products ); - } - - /** - * Product data - * - * @param array $product_slugs (optional) An array of specified product slugs. - * @return array Jetpack products on the site and their availability. - */ - public static function get_products( $product_slugs = array() ) { - $all_classes = self::get_products_classes(); - $products = array(); - // If an array of $product_slugs are passed, return only the products specified in $product_slugs array - if ( $product_slugs ) { - foreach ( $product_slugs as $product_slug ) { - if ( isset( $all_classes[ $product_slug ] ) ) { - $class = $all_classes[ $product_slug ]; - $products[ $product_slug ] = $class::get_info(); - } - } - - return $products; - } - // Otherwise return All products. - foreach ( $all_classes as $slug => $class ) { - $products[ $slug ] = $class::get_info(); - } - - return $products; - } - - /** - * Get products data related to the wpcom api - * - * @param array $product_slugs - (optional) An array of specified product slugs. - * @return array - */ - public static function get_products_api_data( $product_slugs = array() ) { - $all_classes = self::get_products_classes(); - $products = array(); - // If an array of $product_slugs are passed, return only the products specified in $product_slugs array - if ( $product_slugs ) { - foreach ( $product_slugs as $product_slug ) { - if ( isset( $all_classes[ $product_slug ] ) ) { - $class = $all_classes[ $product_slug ]; - $products[ $product_slug ] = $class::get_wpcom_info(); - } - } - - return $products; - } - // Otherwise return All products. - foreach ( $all_classes as $slug => $class ) { - $products[ $slug ] = $class::get_wpcom_info(); - } - - return $products; - } - - /** - * Get a list of products sorted by whether or not the user owns them - * An owned product is defined as a product that is any of the following - * - Active - * - Has historically been active - * - The user has a plan that includes the product - * - The user has the standalone plugin for the product installed - * - * @param string $type The type of ownership to return ('owned' or 'unowned'). - * - * @return array - */ - public static function get_products_by_ownership( $type ) { - $owned_active_products = array(); - $owned_warning_products = array(); - $owned_inactive_products = array(); - $unowned_products = array(); - - foreach ( self::get_products_classes() as $class ) { - $product_slug = $class::$slug; - $status = $class::get_status(); - - if ( $class::is_owned() ) { - // This sorts the the products in the order of active -> warning -> inactive. - // This enables the frontend to display them in that order. - // This is not needed for unowned products as those will always have a status of 'inactive' - if ( in_array( $status, self::$active_module_statuses, true ) ) { - array_push( $owned_active_products, $product_slug ); - } elseif ( in_array( $status, self::$warning_module_statuses, true ) ) { - array_push( $owned_warning_products, $product_slug ); - } else { - array_push( $owned_inactive_products, $product_slug ); - } - continue; - } - - array_push( $unowned_products, $product_slug ); - } - - $data = array( - 'owned' => array_values( - array_unique( - array_merge( - $owned_active_products, - $owned_warning_products, - $owned_inactive_products - ) - ) - ), - 'unowned' => array_values( - array_unique( $unowned_products ) - ), - ); - - return $data[ $type ]; - } - - /** - * Get all plugin filenames associated with the products. - * - * @return array - */ - public static function get_all_plugin_filenames() { - $filenames = array(); - foreach ( self::get_products_classes() as $class ) { - if ( ! isset( $class::$plugin_filename ) ) { - continue; - } - - if ( is_array( $class::$plugin_filename ) ) { - $filenames = array_merge( $filenames, $class::$plugin_filename ); - } else { - $filenames[] = $class::$plugin_filename; - } - } - return $filenames; - } - - /** - * Get one product data by its slug - * - * @param string $product_slug The product slug. - * - * @return ?array - */ - public static function get_product( $product_slug ) { - $classes = self::get_products_classes(); - if ( isset( $classes[ $product_slug ] ) ) { - return $classes[ $product_slug ]::get_info(); - } - } - - /** - * Get one product Class name - * - * @param string $product_slug The product slug. - * - * @return ?string - */ - public static function get_product_class( $product_slug ) { - $classes = self::get_products_classes(); - if ( isset( $classes[ $product_slug ] ) ) { - return $classes[ $product_slug ]; - } - } - - /** - * Return product slugs list. - * - * @return array Product slugs array. - */ - public static function get_products_slugs() { - return array_keys( self::get_products_classes() ); - } - - /** - * Gets the json schema for the product data - * - * @return array - */ - public static function get_product_data_schema() { - return array( - 'title' => 'The requested product data', - 'type' => 'object', - 'properties' => array( - 'product' => array( - 'description' => __( 'Product slug', 'jetpack-my-jetpack' ), - 'type' => 'string', - 'enum' => __CLASS__ . '::get_product_slugs', - 'required' => false, - 'validate_callback' => __CLASS__ . '::check_product_argument', - ), - 'action' => array( - 'description' => __( 'Production action to execute', 'jetpack-my-jetpack' ), - 'type' => 'string', - 'enum' => array( 'activate', 'deactivate' ), - 'required' => false, - 'validate_callback' => __CLASS__ . '::check_product_argument', - ), - 'slug' => array( - 'title' => 'The product slug', - 'type' => 'string', - ), - 'name' => array( - 'title' => 'The product name', - 'type' => 'string', - ), - 'description' => array( - 'title' => 'The product description', - 'type' => 'string', - ), - 'status' => array( - 'title' => 'The product status', - 'type' => 'string', - 'enum' => self::$all_statuses, - ), - 'class' => array( - 'title' => 'The product class handler', - 'type' => 'string', - ), - ), - ); - } - - /** - * Extend actions links for plugins - * tied to the Products. - */ - public static function extend_plugins_action_links() { - $products = array( - 'backup', - 'boost', - 'crm', - 'videopress', - 'social', - 'protect', - 'crm', - 'search', - 'jetpack-ai', - ); - - // Add plugin action links for the core Jetpack plugin. - Product::extend_core_plugin_action_links(); - - // Add plugin action links to standalone products. - foreach ( $products as $product ) { - $class_name = self::get_product_class( $product ); - $class_name::extend_plugin_action_links(); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-red-bubble-notifications.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-red-bubble-notifications.php deleted file mode 100644 index 5d4302ae..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-red-bubble-notifications.php +++ /dev/null @@ -1,399 +0,0 @@ - \WP_REST_Server::CREATABLE, - 'callback' => __CLASS__ . '::rest_api_get_red_bubble_alerts', - 'permission_callback' => __CLASS__ . '::permissions_callback', - 'args' => array( - 'dismissal_cookies' => array( - 'type' => 'array', - 'description' => 'Array of dismissal cookies to set for the red bubble notifications.', - 'required' => false, - 'items' => array( - 'type' => 'string', - ), - 'sanitize_callback' => function ( $param ) { - return array_map( 'sanitize_text_field', $param ); - }, - ), - ), - ) - ); - } - - /** - * Check user capability to access the endpoint. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - return current_user_can( 'edit_posts' ); - } - - /** - * Gets the plugins that need installed or activated for each paid plan. - * - * @return array - */ - public static function get_paid_plans_plugins_requirements() { - $plugin_requirements = array(); - foreach ( Products::get_products_classes() as $slug => $product_class ) { - // Skip these- we don't show them in My Jetpack. - if ( in_array( $slug, Products::get_not_shown_products(), true ) ) { - continue; - } - if ( ! $product_class::has_paid_plan_for_product() ) { - continue; - } - $purchase = $product_class::get_paid_plan_purchase_for_product(); - if ( ! $purchase ) { - continue; - } - // Check if required plugin needs installed or activated. - if ( ! $product_class::is_plugin_installed() ) { - // Plugin needs installed (and activated) - $plugin_requirements[ $purchase->product_slug ]['needs_installed'][] = $product_class::$slug; - } elseif ( ! $product_class::is_plugin_active() ) { - // Plugin is installed, but not activated. - $plugin_requirements[ $purchase->product_slug ]['needs_activated_only'][] = $product_class::$slug; - } - } - - return $plugin_requirements; - } - - /** - * Check for features broken by a disconnected user or site - * - * @return array - */ - public static function check_for_broken_modules() { - $connection = new Connection_Manager(); - $is_user_connected = $connection->is_user_connected() || $connection->has_connected_owner(); - $is_site_connected = $connection->is_connected(); - $broken_modules = array( - 'needs_site_connection' => array(), - 'needs_user_connection' => array(), - ); - - if ( $is_user_connected && $is_site_connected ) { - return $broken_modules; - } - - $products = Products::get_products_classes(); - $historically_active_modules = Jetpack_Options::get_option( 'historically_active_modules', array() ); - - foreach ( $products as $product ) { - if ( ! in_array( $product::$slug, $historically_active_modules, true ) ) { - continue; - } - - if ( $product::$requires_user_connection && ! $is_user_connected ) { - if ( ! in_array( $product::$slug, $broken_modules['needs_user_connection'], true ) ) { - $broken_modules['needs_user_connection'][] = $product::$slug; - } - } elseif ( ! $is_site_connected ) { - if ( ! in_array( $product::$slug, $broken_modules['needs_site_connection'], true ) ) { - $broken_modules['needs_site_connection'][] = $product::$slug; - } - } - } - - return $broken_modules; - } - - /** - * Add an alert slug if the site is missing a site connection - * - * @param array $red_bubble_slugs - slugs that describe the reasons the red bubble is showing. - * @return array - */ - public static function alert_if_missing_connection( array $red_bubble_slugs ) { - $broken_modules = self::check_for_broken_modules(); - $connection = new Connection_Manager(); - - // Checking for site connection issues first. - if ( ! empty( $broken_modules['needs_site_connection'] ) ) { - $red_bubble_slugs[ self::MISSING_CONNECTION_NOTIFICATION_KEY ] = array( - 'type' => 'site', - 'is_error' => true, - ); - return $red_bubble_slugs; - } - - if ( ! empty( $broken_modules['needs_user_connection'] ) ) { - $red_bubble_slugs[ self::MISSING_CONNECTION_NOTIFICATION_KEY ] = array( - 'type' => 'user', - 'is_error' => true, - ); - return $red_bubble_slugs; - } - - if ( ! $connection->is_connected() ) { - $red_bubble_slugs[ self::MISSING_CONNECTION_NOTIFICATION_KEY ] = array( - 'type' => 'site', - 'is_error' => false, - ); - return $red_bubble_slugs; - } - - return $red_bubble_slugs; - } - - /** - * Add an alert slug if Backups are failing or having an issue. - * - * @param array $red_bubble_slugs - slugs that describe the reasons the red bubble is showing. - * @return array - */ - public static function alert_if_last_backup_failed( array $red_bubble_slugs ) { - // Make sure the Notice wasn't previously dismissed. - if ( ! empty( $_COOKIE['backup_failure_dismissed'] ) ) { - return $red_bubble_slugs; - } - // Make sure there's a Backup paid plan - if ( ! Products\Backup::is_plugin_active() || ! Products\Backup::has_paid_plan_for_product() ) { - return $red_bubble_slugs; - } - // Make sure the plan isn't just recently purchased in last 30min. - // Give some time to queue & run the first backup. - $purchase = Products\Backup::get_paid_plan_purchase_for_product(); - if ( $purchase ) { - $thirty_minutes_after_plan_purchase = strtotime( $purchase->subscribed_date . ' +30 minutes' ); - if ( strtotime( 'now' ) < $thirty_minutes_after_plan_purchase ) { - return $red_bubble_slugs; - } - } - - $backup_failed_status = Products\Backup::does_module_need_attention(); - if ( $backup_failed_status ) { - $red_bubble_slugs['backup_failure'] = $backup_failed_status; - } - - return $red_bubble_slugs; - } - - /** - * Add an alert slug if Protect has scan threats/vulnerabilities. - * - * @param array $red_bubble_slugs - slugs that describe the reasons the red bubble is showing. - * @return array - */ - public static function alert_if_protect_has_threats( array $red_bubble_slugs ) { - // Make sure the Notice hasn't been dismissed. - if ( ! empty( $_COOKIE['protect_threats_detected_dismissed'] ) ) { - return $red_bubble_slugs; - } - // Make sure we're dealing with the Protect product only - if ( ! Products\Protect::has_paid_plan_for_product() ) { - return $red_bubble_slugs; - } - - $protect_threats_status = Products\Protect::does_module_need_attention(); - - if ( $protect_threats_status ) { - $red_bubble_slugs['protect_has_threats'] = $protect_threats_status; - } - - return $red_bubble_slugs; - } - - /** - * Add an alert slug if any paid plan/products are expiring or expired. - * - * @param array $red_bubble_slugs - slugs that describe the reasons the red bubble is showing. - * @return array - */ - public static function alert_if_paid_plan_expiring( array $red_bubble_slugs ) { - $connection = new Connection_Manager(); - if ( ! $connection->is_connected() ) { - return $red_bubble_slugs; - } - $product_classes = Products::get_products_classes(); - - $products_included_in_expiring_plan = array(); - foreach ( $product_classes as $key => $product ) { - // Skip these- we don't show them in My Jetpack. - if ( in_array( $key, Products::get_not_shown_products(), true ) ) { - continue; - } - - if ( $product::has_paid_plan_for_product() ) { - $purchase = $product::get_paid_plan_purchase_for_product(); - if ( $purchase ) { - $redbubble_notice_data = array( - 'product_slug' => $purchase->product_slug, - 'product_name' => $purchase->product_name, - 'expiry_date' => $purchase->expiry_date, - 'expiry_message' => $purchase->expiry_message, - 'manage_url' => $product::get_manage_paid_plan_purchase_url(), - ); - - if ( $product::is_paid_plan_expired() && empty( $_COOKIE[ "$purchase->product_slug--plan_expired_dismissed" ] ) ) { - $red_bubble_slugs[ "$purchase->product_slug--plan_expired" ] = $redbubble_notice_data; - if ( ! $product::is_bundle_product() ) { - $products_included_in_expiring_plan[ "$purchase->product_slug--plan_expired" ][] = $product::get_name(); - } - } - if ( $product::is_paid_plan_expiring() && empty( $_COOKIE[ "$purchase->product_slug--plan_expiring_soon_dismissed" ] ) ) { - $red_bubble_slugs[ "$purchase->product_slug--plan_expiring_soon" ] = $redbubble_notice_data; - $red_bubble_slugs[ "$purchase->product_slug--plan_expiring_soon" ]['manage_url'] = $product::get_renew_paid_plan_purchase_url(); - if ( ! $product::is_bundle_product() ) { - $products_included_in_expiring_plan[ "$purchase->product_slug--plan_expiring_soon" ][] = $product::get_name(); - } - } - } - } - } - - foreach ( $products_included_in_expiring_plan as $expiring_plan => $products ) { - $red_bubble_slugs[ $expiring_plan ]['products_effected'] = $products; - } - - return $red_bubble_slugs; - } - - /** - * Add an alert slug if a site's paid plan requires a plugin install and/or activation. - * - * @param array $red_bubble_slugs - slugs that describe the reasons the red bubble is showing. - * @return array - */ - public static function alert_if_paid_plan_requires_plugin_install_or_activation( array $red_bubble_slugs ) { - $connection = new Connection_Manager(); - // Don't trigger red bubble (and show notice) when the site is not connected or if the - // user doesn't have plugin installation/activation permissions. - if ( ! $connection->is_connected() || ! current_user_can( 'activate_plugins' ) ) { - return $red_bubble_slugs; - } - - $plugins_needing_installed_activated = self::get_paid_plans_plugins_requirements(); - if ( empty( $plugins_needing_installed_activated ) ) { - return $red_bubble_slugs; - } - - foreach ( $plugins_needing_installed_activated as $plan_slug => $plugins_requirements ) { - if ( empty( $_COOKIE[ "$plan_slug--plugins_needing_installed_dismissed" ] ) ) { - $red_bubble_slugs[ "$plan_slug--plugins_needing_installed_activated" ] = $plugins_requirements; - } - } - - return $red_bubble_slugs; - } - - /** - * Add relevant red bubble notifications - * - * @param array $red_bubble_slugs - slugs that describe the reasons the red bubble is showing. - * @return array - */ - public static function add_red_bubble_alerts( array $red_bubble_slugs ) { - if ( wp_doing_ajax() ) { - return array(); - } - $connection = new Connection_Manager(); - $welcome_banner_dismissed = Jetpack_Options::get_option( 'dismissed_welcome_banner', false ); - if ( Initializer::is_jetpack_user_new() && ! $welcome_banner_dismissed ) { - $red_bubble_slugs['welcome-banner-active'] = array( - 'is_silent' => $connection->is_connected(), // we don't display the red bubble if the user is connected - ); - return $red_bubble_slugs; - } else { - return array_merge( - self::alert_if_missing_connection( $red_bubble_slugs ), - self::alert_if_last_backup_failed( $red_bubble_slugs ), - self::alert_if_paid_plan_expiring( $red_bubble_slugs ), - self::alert_if_protect_has_threats( $red_bubble_slugs ), - self::alert_if_paid_plan_requires_plugin_install_or_activation( $red_bubble_slugs ) - ); - } - } - - /** - * Collect all possible alerts that we might use a red bubble notification for - * - * @param bool $bypass_cache - whether to bypass the red bubble cache. - * @return array - */ - public static function get_red_bubble_alerts( bool $bypass_cache = false ) { - static $red_bubble_alerts = array(); - - // check for stored alerts - $stored_alerts = get_transient( self::MY_JETPACK_RED_BUBBLE_TRANSIENT_KEY ); - - // Cache bypass for red bubbles should only happen on the My Jetpack page - if ( $stored_alerts !== false && ! ( $bypass_cache ) ) { - return $stored_alerts; - } - - // go find the alerts - $red_bubble_alerts = apply_filters( 'my_jetpack_red_bubble_notification_slugs', $red_bubble_alerts ); - - // cache the alerts for one hour - set_transient( self::MY_JETPACK_RED_BUBBLE_TRANSIENT_KEY, $red_bubble_alerts, 3600 ); - - return $red_bubble_alerts; - } - - /** - * Get the red bubble alerts, bypassing cache when called via the REST API - * - * @param WP_REST_Request $request The REST API request object. - * - * @return WP_Error|WP_REST_Response - */ - public static function rest_api_get_red_bubble_alerts( $request ) { - add_filter( 'my_jetpack_red_bubble_notification_slugs', array( __CLASS__, 'add_red_bubble_alerts' ) ); - - $cookies = $request->get_param( 'dismissal_cookies' ); - - // Update $_COOKIE superglobal with the provided cookies - if ( ! empty( $cookies ) && is_array( $cookies ) ) { - foreach ( $cookies as $cookie_string ) { - // Parse cookie string in format "name=value" - $parts = explode( '=', $cookie_string, 2 ); - if ( count( $parts ) === 2 ) { - $name = trim( $parts[0] ); - $value = trim( $parts[1] ); - $_COOKIE[ $name ] = $value; - } - } - } - - $red_bubble_alerts = self::get_red_bubble_alerts( true ); - return rest_ensure_response( $red_bubble_alerts ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-ai.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-ai.php deleted file mode 100644 index 39698107..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-ai.php +++ /dev/null @@ -1,90 +0,0 @@ - \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::get_openai_jwt', - 'permission_callback' => function () { - return ( new Connection_Manager( 'jetpack' ) )->is_user_connected() && current_user_can( 'edit_posts' ); - }, - ) - ); - } - } - - /** - * Check if a specific REST endpoint is registered. - * - * @param string $namespace - The namespace of the endpoint. - * @param string $route - The route of the endpoint. - * @return bool True if the endpoint is registered, false otherwise. - */ - public static function is_rest_endpoint_registered( $namespace, $route ) { - $server = rest_get_server(); - $routes = $server->get_routes(); - $full_endpoint = '/' . trim( $namespace, '/' ) . $route; - return isset( $routes[ $full_endpoint ] ); - } - - /** - * Ask WPCOM for a JWT token to use for OpenAI completion. - */ - public static function get_openai_jwt() { - $blog_id = Jetpack_Options::get_option( 'id' ); - - $response = Client::wpcom_json_api_request_as_user( - "/sites/$blog_id/jetpack-openai-query/jwt", - '2', - array( - 'method' => 'POST', - 'headers' => array( 'Content-Type' => 'application/json; charset=utf-8' ), - ), - wp_json_encode( array() ), - 'wpcom' - ); - - if ( is_wp_error( $response ) ) { - return $response; - } - - $json = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( ! isset( $json->token ) ) { - return new WP_Error( 'no-token', 'No token returned from WPCOM' ); - } - - return array( - 'token' => $json->token, - 'blog_id' => $blog_id, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php deleted file mode 100644 index 18ee7975..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php +++ /dev/null @@ -1,362 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_products_api_data', - 'permission_callback' => __CLASS__ . '::view_products_permissions_callback', - 'args' => array( - 'products' => array( - 'description' => __( 'Comma seperated list of product slugs that should be retrieved.', 'jetpack-my-jetpack' ), - 'type' => 'string', - 'required' => false, - 'validate_callback' => __CLASS__ . '::check_products_string', - ), - ), - ), - 'schema' => array( $this, 'get_products_schema' ), - ) - ); - - $products_arg = array( - 'description' => __( 'Array of Product slugs', 'jetpack-my-jetpack' ), - 'type' => 'array', - 'items' => array( - 'enum' => Products::get_products_slugs(), - 'type' => 'string', - ), - 'required' => true, - 'validate_callback' => __CLASS__ . '::check_products_argument', - ); - - register_rest_route( - 'my-jetpack/v1', - 'site/products/install', - array( - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::install_plugins', - 'permission_callback' => __CLASS__ . '::edit_permissions_callback', - 'args' => array( - 'products' => $products_arg, - ), - ), - ) - ); - - register_rest_route( - 'my-jetpack/v1', - 'site/products/activate', - array( - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::activate_products', - 'permission_callback' => __CLASS__ . '::edit_permissions_callback', - 'args' => array( - 'products' => $products_arg, - ), - ), - ) - ); - - register_rest_route( - 'my-jetpack/v1', - 'site/products/deactivate', - array( - array( - 'methods' => \WP_REST_Server::DELETABLE, - 'callback' => __CLASS__ . '::deactivate_products', - 'permission_callback' => __CLASS__ . '::edit_permissions_callback', - 'args' => array( - 'products' => $products_arg, - ), - ), - ) - ); - - register_rest_route( - 'my-jetpack/v1', - 'site/products-ownership', - array( - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_products_by_ownership', - 'permission_callback' => __CLASS__ . '::view_products_permissions_callback', - ), - ) - ); - } - - /** - * Get the schema for the products endpoint - * - * @return array - */ - public function get_products_schema() { - return array( - '$schema' => 'http://json-schema.org/draft-04/schema#', - 'title' => 'products', - 'type' => 'object', - 'properties' => Products::get_product_data_schema(), - ); - } - - /** - * Check user capability to access the endpoint. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - return current_user_can( 'manage_options' ); - } - - /** - * Check if the user is permitted to view the product and product info - * - * @return bool - */ - public static function view_products_permissions_callback() { - return current_user_can( 'edit_posts' ); - } - - /** - * Check Products string (comma separated string). - * - * @access public - * @static - * - * @param mixed $value - Value of the 'product' argument. - * @return true|WP_Error True if the value is valid, WP_Error otherwise. - */ - public static function check_products_string( $value ) { - if ( ! is_string( $value ) ) { - return new WP_Error( - 'rest_invalid_param', - esc_html__( 'The product argument must be a string.', 'jetpack-my-jetpack' ), - array( 'status' => 400 ) - ); - } - - $products_array = explode( ',', $value ); - $all_products = Products::get_products_slugs(); - - foreach ( $products_array as $product_slug ) { - if ( ! in_array( $product_slug, $all_products, true ) ) { - return new WP_Error( - 'rest_invalid_param', - esc_html( - sprintf( - /* translators: %s is the product_slug, it should Not be translated. */ - __( 'The specified product argument %s is an invalid product.', 'jetpack-my-jetpack' ), - $product_slug - ) - ), - array( 'status' => 400 ) - ); - } - } - - return true; - } - - /** - * Check Products argument. - * - * @access public - * @static - * - * @param mixed $value - Value of the 'product' argument. - * @return true|WP_Error True if the value is valid, WP_Error otherwise. - */ - public static function check_products_argument( $value ) { - if ( ! is_array( $value ) ) { - return new WP_Error( - 'rest_invalid_param', - esc_html__( 'The product argument must be an array.', 'jetpack-my-jetpack' ), - array( 'status' => 400 ) - ); - } - - return true; - } - - /** - * Site products endpoint. - * - * @param \WP_REST_Request $request The request object. - * @return WP_Error|\WP_REST_Response - */ - public static function get_products( $request ) { - $slugs = $request->get_param( 'products' ); - $product_slugs = ! empty( $slugs ) ? array_map( 'trim', explode( ',', $slugs ) ) : array(); - - $response = Products::get_products( $product_slugs ); - return rest_ensure_response( $response ); - } - - /** - * Site API product data endpoint - * - * @param \WP_REST_Request $request The request object. - * - * @return WP_Error|\WP_REST_Response - */ - public static function get_products_api_data( $request ) { - $slugs = $request->get_param( 'products' ); - $product_slugs = ! empty( $slugs ) ? array_map( 'trim', explode( ',', $slugs ) ) : array(); - - $response = Products::get_products_api_data( $product_slugs ); - return rest_ensure_response( $response ); - } - - /** - * Site products endpoint. - * - * @return \WP_REST_Response of site products list. - */ - public static function get_products_by_ownership() { - $response = array( - 'unownedProducts' => Products::get_products_by_ownership( 'unowned' ), - 'ownedProducts' => Products::get_products_by_ownership( 'owned' ), - ); - return rest_ensure_response( $response ); - } - - /** - * Check permission to edit product - * - * @return bool - */ - public static function edit_permissions_callback() { - if ( ! current_user_can( 'activate_plugins' ) ) { - return false; - } - if ( is_multisite() && ! current_user_can( 'manage_network' ) ) { - return false; - } - return true; - } - - /** - * Callback for activating products - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response|\WP_Error - */ - public static function activate_products( $request ) { - $products_array = $request->get_param( 'products' ); - - foreach ( $products_array as $product_slug ) { - $product = Products::get_product( $product_slug ); - if ( ! isset( $product['class'] ) ) { - return new \WP_Error( - 'product_class_handler_not_found', - sprintf( - /* translators: %s is the product_slug */ - __( 'The product slug %s does not have an associated class handler.', 'jetpack-my-jetpack' ), - $product_slug - ), - array( 'status' => 501 ) - ); - } - - $activate_product_result = call_user_func( array( $product['class'], 'activate' ) ); - if ( is_wp_error( $activate_product_result ) ) { - $activate_product_result->add_data( array( 'status' => 400 ) ); - return $activate_product_result; - } - } - set_transient( 'my_jetpack_product_activated', implode( ',', $products_array ), 10 ); - - return rest_ensure_response( Products::get_products( $products_array ) ); - } - - /** - * Callback for deactivating products - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response|\WP_Error - */ - public static function deactivate_products( $request ) { - $products_array = $request->get_param( 'products' ); - - foreach ( $products_array as $product_slug ) { - $product = Products::get_product( $product_slug ); - if ( ! isset( $product['class'] ) ) { - return new \WP_Error( - 'product_class_handler_not_found', - sprintf( - /* translators: %s is the product_slug */ - __( 'The product slug %s does not have an associated class handler.', 'jetpack-my-jetpack' ), - $product_slug - ), - array( 'status' => 501 ) - ); - } - - $deactivate_product_result = call_user_func( array( $product['class'], 'deactivate' ) ); - if ( is_wp_error( $deactivate_product_result ) ) { - $deactivate_product_result->add_data( array( 'status' => 400 ) ); - return $deactivate_product_result; - } - } - - return rest_ensure_response( Products::get_products( $products_array ) ); - } - - /** - * Callback for installing (and activating) multiple product plugins. - * - * @param \WP_REST_Request $request The request object. - * @return \WP_REST_Response|\WP_Error - */ - public static function install_plugins( $request ) { - $products_array = $request->get_param( 'products' ); - - foreach ( $products_array as $product_slug ) { - $product = Products::get_product( $product_slug ); - if ( ! isset( $product['class'] ) ) { - return new \WP_Error( - 'product_class_handler_not_found', - sprintf( - /* translators: %s is the product_slug */ - __( 'The product slug %s does not have an associated class handler.', 'jetpack-my-jetpack' ), - $product_slug - ), - array( 'status' => 501 ) - ); - } - - $install_product_result = call_user_func( array( $product['class'], 'install_and_activate_standalone' ) ); - if ( is_wp_error( $install_product_result ) ) { - $install_product_result->add_data( array( 'status' => 400 ) ); - return $install_product_result; - } - } - - return rest_ensure_response( Products::get_products( $products_array ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php deleted file mode 100644 index aa1d146a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php +++ /dev/null @@ -1,77 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_site_current_purchases', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Check user capability to access the endpoint. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - $connection = new Connection_Manager(); - $is_site_connected = $connection->is_connected(); - - if ( ! $is_site_connected ) { - return new WP_Error( - 'not_connected', - __( 'Your site is not connected to Jetpack.', 'jetpack-my-jetpack' ), - array( - 'status' => 400, - ) - ); - } - - return current_user_can( 'edit_posts' ); - } - - /** - * Site purchases endpoint. - * - * @return array|WP_Error of site purchases. - */ - public static function get_site_current_purchases() { - $site_id = \Jetpack_Options::get_option( 'id' ); - $wpcom_endpoint = sprintf( '/sites/%1$d/purchases?locale=%2$s', $site_id, get_user_locale() ); - $wpcom_api_version = '1.1'; - $response = Client::wpcom_json_api_request_as_blog( $wpcom_endpoint, $wpcom_api_version ); - $response_code = wp_remote_retrieve_response_code( $response ); - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( is_wp_error( $response ) || empty( $response['body'] ) || 200 !== $response_code ) { - return new WP_Error( 'site_data_fetch_failed', 'Site data fetch failed', array( 'status' => $response_code ? $response_code : 400 ) ); - } - - return rest_ensure_response( $body ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-recommendations-evaluation.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-recommendations-evaluation.php deleted file mode 100644 index 66f09642..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-recommendations-evaluation.php +++ /dev/null @@ -1,150 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::evaluate_site_recommendations', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ), - ) - ); - - register_rest_route( - 'my-jetpack/v1', - '/site/recommendations/evaluation/result/', - array( - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::save_evaluation_recommendations', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ), - ) - ); - - register_rest_route( - 'my-jetpack/v1', - '/site/recommendations/evaluation/result/', - array( - array( - 'methods' => \WP_REST_Server::DELETABLE, - 'callback' => __CLASS__ . '::dismiss_evaluation_recommendations', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ), - ) - ); - } - - /** - * Check user capability to access the endpoint. - * - * @access public - * @static - * - * @return true|WP_Error - */ - public static function permissions_callback() { - $connection = new Connection_Manager(); - $is_site_connected = $connection->is_connected(); - - if ( ! $is_site_connected ) { - return new WP_Error( - 'not_connected', - __( 'Your site is not connected to Jetpack.', 'jetpack-my-jetpack' ), - array( - 'status' => 400, - ) - ); - } - - return true; // We require site to be connected. - } - - /** - * Recommendations Evaluation endpoint. - * - * @param \WP_REST_Request $request Query request. - * - * @return \WP_REST_Response|WP_Error of 3 product slugs (recommendations). - */ - public static function evaluate_site_recommendations( $request ) { - $goals = $request->get_param( 'goals' ); - - if ( ! isset( $goals ) ) { - return new WP_Error( 'missing_goals', 'Goals are required', array( 'status' => 400 ) ); - } - - $site_id = \Jetpack_Options::get_option( 'id' ); - $wpcom_endpoint = sprintf( '/sites/%1$d/jetpack-recommendations/evaluation?goals=%2$s', $site_id, implode( ',', $goals ) ); - $response = Client::wpcom_json_api_request_as_blog( $wpcom_endpoint, '2', array(), null, 'wpcom' ); - $response_code = wp_remote_retrieve_response_code( $response ); - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( is_wp_error( $response ) || empty( $body ) || 200 !== $response_code ) { - return new WP_Error( 'recommendations_evaluation_fetch_failed', 'Evaluation processing failed', array( 'status' => $response_code ? $response_code : 400 ) ); - } - - return rest_ensure_response( $body ); - } - - /** - * Endpoint to save recommendations results. - * - * @param \WP_REST_Request $request Query request. - * - * @return \WP_REST_Response|WP_Error success response. - */ - public static function save_evaluation_recommendations( $request ) { - $json = $request->get_json_params(); - - if ( ! isset( $json['recommendations'] ) ) { - return new WP_Error( 'missing_recommendations', 'Recommendations are required', array( 'status' => 400 ) ); - } - - \Jetpack_Options::update_option( 'recommendations_evaluation', $json['recommendations'] ); - \Jetpack_Options::delete_option( 'dismissed_recommendations' ); - - return rest_ensure_response( Initializer::get_recommended_modules() ); - } - - /** - * Endpoint to dismiss the recommendation section - * - * @param \WP_REST_Request $request Query request. - * - * @return \WP_REST_Response|WP_Error success response. - */ - public static function dismiss_evaluation_recommendations( $request ) { - $show_welcome_banner = $request->get_param( 'showWelcomeBanner' ); - - \Jetpack_Options::update_option( 'dismissed_recommendations', true ); - - if ( isset( $show_welcome_banner ) && $show_welcome_banner === 'true' ) { - \Jetpack_Options::update_option( 'recommendations_first_run', false ); - \Jetpack_Options::delete_option( 'dismissed_welcome_banner' ); - } - - return rest_ensure_response( array() ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-zendesk-chat.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-zendesk-chat.php deleted file mode 100644 index 91c58ece..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-zendesk-chat.php +++ /dev/null @@ -1,122 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_chat_availability', - 'permission_callback' => __CLASS__ . '::chat_authentication_permissions_callback', - ) - ); - - register_rest_route( - 'my-jetpack/v1', - 'chat/authentication', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_chat_authentication', - 'args' => array( - 'type' => array( - 'required' => false, - 'type' => 'string', - ), - 'test_mode' => array( - 'required' => false, - 'type' => 'boolean', - ), - ), - 'permission_callback' => __CLASS__ . '::chat_authentication_permissions_callback', - ) - ); - } - - /** - * Ensure user is logged in if making an authentication request - * - * @access public - * @static - * - * @return WP_Error|true - */ - public static function chat_authentication_permissions_callback() { - if ( ! get_current_user_id() ) { - return new WP_Error( 'unauthorized', 'You must be logged in to access this resource.', array( 'status' => 401 ) ); - } - - return true; - } - - /** - * Gets the chat authentication token. - * - * @return WP_Error|WP_REST_Response { token: string } - */ - public static function get_chat_authentication() { - $authentication = get_transient( self::ZENDESK_AUTH_TOKEN ); - if ( $authentication ) { - return rest_ensure_response( $authentication ); - } - - $proxied = function_exists( 'wpcom_is_proxied_request' ) ? wpcom_is_proxied_request() : false; - $wpcom_endpoint = 'help/authenticate/chat'; - $wpcom_api_version = '2'; - - $body = array( - 'type' => 'zendesk', - 'test_mode' => $proxied ? true : false, - ); - - $response = Client::wpcom_json_api_request_as_user( $wpcom_endpoint, $wpcom_api_version, array( 'method' => 'POST' ), $body ); - $response_code = wp_remote_retrieve_response_code( $response ); - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( is_wp_error( $response ) || empty( $response['body'] ) ) { - return new WP_Error( 'chat_authentication_failed', 'Chat authentication failed', array( 'status' => $response_code ) ); - } - - set_transient( self::ZENDESK_AUTH_TOKEN, $body, self::TRANSIENT_EXPIRY ); - return rest_ensure_response( $body ); - } - - /** - * Calls `wpcom/v2/presales/chat?group=jp_presales` endpoint. - * This endpoint returns whether or not the Jetpack presales chat group is available - * - * @return WP_Error|WP_REST_Response { is_available: bool } - */ - public static function get_chat_availability() { - $wpcom_endpoint = '/presales/chat?group=jp_presales'; - $wpcom_api_version = '2'; - $response = Client::wpcom_json_api_request_as_user( $wpcom_endpoint, $wpcom_api_version ); - $response_code = wp_remote_retrieve_response_code( $response ); - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( is_wp_error( $response ) || empty( $response['body'] ) ) { - return new WP_Error( 'chat_config_data_fetch_failed', 'Chat config data fetch failed', array( 'status' => $response_code ) ); - } - - return rest_ensure_response( $body ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php deleted file mode 100644 index 941a3659..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php +++ /dev/null @@ -1,405 +0,0 @@ -get_ip( true ); - $headers = array( - 'X-Forwarded-For' => $ip, - ); - - if ( $blog_id ) { - $request_label = 'get_products_from_wpcom_blog_' . $blog_id; - $request_failure = static::get_request_failure( $request_label ); - if ( null !== $request_failure ) { - return $request_failure; - } - - // If has a blog id, use connected endpoint. - $endpoint = sprintf( '/sites/%d/products/?_locale=%s&type=jetpack', $blog_id, get_user_locale() ); - - // If available in the user data, set the user's currency as one of the params - if ( $connection->is_user_connected() ) { - $user_details = $connection->get_connected_user_data(); - if ( ! empty( $user_details['user_currency'] ) && $user_details['user_currency'] !== 'USD' ) { - $endpoint .= sprintf( '¤cy=%s', $user_details['user_currency'] ); - } - } - - $wpcom_request = Client::wpcom_json_api_request_as_blog( - $endpoint, - '1.1', - array( - 'method' => 'GET', - 'headers' => $headers, - ) - ); - } else { - $request_label = 'get_products_from_wpcom'; - $request_failure = static::get_request_failure( $request_label ); - if ( null !== $request_failure ) { - return $request_failure; - } - - $endpoint = 'https://public-api.wordpress.com/rest/v1.1/products?locale=' . get_user_locale() . '&type=jetpack'; - - $wpcom_request = wp_remote_get( - esc_url_raw( $endpoint ), - array( - 'headers' => $headers, - ) - ); - } - - $response_code = wp_remote_retrieve_response_code( $wpcom_request ); - - if ( 200 === $response_code ) { - return json_decode( wp_remote_retrieve_body( $wpcom_request ) ); - } else { - $error = new WP_Error( - 'failed_to_fetch_wpcom_products', - esc_html__( 'Unable to fetch the products list from WordPress.com', 'jetpack-my-jetpack' ), - array( 'status' => $response_code ) - ); - static::set_request_failure( $request_label, $error ); - return $error; - } - } - - /** - * Super unintelligent hash string that can help us reset the cache after connection changes - * This is important because the currency can change after a user connects depending on what is set in their profile - * - * @return string - */ - private static function build_check_hash() { - static $has_user_data_fetch_error = false; - - $hash_string = 'check_hash_'; - $connection = new Connection_Manager(); - - if ( $connection->is_connected() ) { - $hash_string .= 'site_connected_'; - } - - if ( $connection->is_user_connected() ) { - $hash_string .= 'user_connected'; - // Add the user's currency - $user_details = $has_user_data_fetch_error ? false : $connection->get_connected_user_data(); - - if ( $user_details === false ) { - $has_user_data_fetch_error = true; - } elseif ( ! empty( $user_details['user_currency'] ) ) { - $hash_string .= '_' . $user_details['user_currency']; - } - } - - return md5( $hash_string ); - } - - /** - * Update the cache with new information retrieved from WPCOM - * - * We store one cache for each user, as the information is internationalized based on user preferences - * Also, the currency is based on the user IP address - * - * @param Object $products_list The products list as received from WPCOM. - * @return bool - */ - private static function update_cache( $products_list ) { - update_user_meta( get_current_user_id(), self::CACHE_DATE_META_NAME, time() ); - update_user_meta( get_current_user_id(), self::CACHE_CHECK_HASH_NAME, self::build_check_hash() ); - return update_user_meta( get_current_user_id(), self::CACHE_META_NAME, $products_list ); - } - - /** - * Checks if the cache is old, meaning we need to fetch new data from WPCOM - */ - private static function is_cache_old() { - if ( empty( self::get_products_from_cache() ) ) { - return true; - } - - // This allows the cache to reset after the site or user connects/ disconnects - $check_hash = get_user_meta( get_current_user_id(), self::CACHE_CHECK_HASH_NAME, true ); - if ( $check_hash !== self::build_check_hash() ) { - return true; - } - - $cache_date = get_user_meta( get_current_user_id(), self::CACHE_DATE_META_NAME, true ); - return time() - (int) $cache_date > DAY_IN_SECONDS; - } - - /** - * Gets the product list from the user cache - */ - private static function get_products_from_cache() { - return get_user_meta( get_current_user_id(), self::CACHE_META_NAME, true ); - } - - /** - * Gets the product list - * - * Attempts to retrieve the products list from the user cache if cache is not too old. - * If cache is old, it will attempt to fetch information from WPCOM. If it fails, we return what we have in cache, if anything, otherwise we return an error. - * - * @param bool $skip_cache If true it will ignore the cache and attempt to fetch fresh information from WPCOM. - * - * @return Object|WP_Error - */ - public static function get_products( $skip_cache = false ) { - // This is only available for logged in users. - if ( ! get_current_user_id() ) { - return null; - } - if ( ! self::is_cache_old() && ! $skip_cache ) { - return self::get_products_from_cache(); - } - - $products = self::get_products_from_wpcom(); - if ( is_wp_error( $products ) ) { - // Let's see if we have it cached. - $cached = self::get_products_from_cache(); - if ( ! empty( $cached ) ) { - return $cached; - } else { - return $products; - } - } - - self::update_cache( $products ); - return $products; - } - - /** - * Get one product - * - * @param string $product_slug The product slug. - * @param bool $renew_cache A flag to force the cache to be renewed. - * - * @return ?Object The product details if found - */ - public static function get_product( $product_slug, $renew_cache = false ) { - $products = self::get_products( $renew_cache ); - if ( ! empty( $products->$product_slug ) ) { - return $products->$product_slug; - } - } - - /** - * Get only the product currency code and price in an array - * - * @param string $product_slug The product slug. - * - * @return array An array with currency_code and full_price. Empty array if product not found. - */ - public static function get_product_pricing( $product_slug ) { - $product = self::get_product( $product_slug ); - if ( empty( $product ) ) { - return array(); - } - - $cost = $product->cost; - $discount_price = $cost; - $is_introductory_offer = false; - $introductory_offer = null; - - // Get/compute the discounted price. - if ( isset( $product->introductory_offer->cost_per_interval ) ) { - $discount_price = $product->introductory_offer->cost_per_interval; - $is_introductory_offer = true; - $introductory_offer = $product->introductory_offer; - } - - $pricing = array( - 'currency_code' => $product->currency_code, - 'full_price' => $cost, - 'discount_price' => $discount_price, - 'is_introductory_offer' => $is_introductory_offer, - 'introductory_offer' => $introductory_offer, - 'product_term' => $product->product_term, - ); - - return self::populate_with_discount( $product, $pricing, $discount_price ); - } - - /** - * Populate the pricing array with the discount information. - * - * @param object $product - The product object. - * @param array $pricing - The pricing array. - * @param float $price - The price to be discounted. - * @return array The pricing array with the discount information. - */ - public static function populate_with_discount( $product, $pricing, $price ) { - // Check whether the product has a coupon. - if ( ! isset( $product->sale_coupon ) ) { - return $pricing; - } - - // Check whether it is still valid. - $coupon = $product->sale_coupon; - $coupon_start_date = strtotime( $coupon->start_date ); - $coupon_expires = strtotime( $coupon->expires ); - if ( $coupon_start_date > time() || $coupon_expires < time() ) { - return $pricing; - } - - $coupon_discount = intval( $coupon->discount ); - - // Populate response with coupon discount. - $pricing['coupon_discount'] = $coupon_discount; - - // Apply coupon discount to the price. - $pricing['discount_price'] = $price * ( 100 - $coupon_discount ) / 100; - - return $pricing; - } - - /** - * Gets the site purchases from WPCOM. - * - * @return Object|WP_Error - */ - public static function get_site_current_purchases() { - static $purchases = null; - - if ( $purchases !== null ) { - return $purchases; - } - - // Check for a cached value before doing lookup - $stored_purchases = get_transient( self::MY_JETPACK_PURCHASES_TRANSIENT_KEY ); - if ( $stored_purchases !== false ) { - return $stored_purchases; - } - - $request_failure = static::get_request_failure( 'get_site_current_purchases' ); - if ( null !== $request_failure ) { - return $request_failure; - } - - $site_id = Jetpack_Options::get_option( 'id' ); - - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%d/purchases', $site_id ), - '1.1', - array( - 'method' => 'GET', - ) - ); - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $error = new WP_Error( 'purchases_state_fetch_failed' ); - static::set_request_failure( 'get_site_current_purchases', $error ); - return $error; - } - - $body = wp_remote_retrieve_body( $response ); - $purchases = json_decode( $body ); - // Set short transient to help with repeated lookups on the same page load - set_transient( self::MY_JETPACK_PURCHASES_TRANSIENT_KEY, $purchases, 5 ); - - return $purchases; - } - - /** - * Gets the site's currently active "plan" (bundle). - * - * @param bool $reload Whether to refresh data from wpcom or not. - * @return array - */ - public static function get_site_current_plan( $reload = false ) { - static $reloaded_already = false; - - if ( $reload && ! $reloaded_already ) { - Current_Plan::refresh_from_wpcom(); - $reloaded_already = true; - } - - return Current_Plan::get(); - } - - /** - * Reset the request failures to retry the API requests. - * - * @return void - */ - public static function reset_request_failures() { - static::$wpcom_request_failures = array(); - } - - /** - * Record the request failure to prevent repeated requests. - * - * @param string $request_label The request label. - * @param WP_Error $error The error. - * - * @return void - */ - private static function set_request_failure( $request_label, WP_Error $error ) { - static::$wpcom_request_failures[ $request_label ] = $error; - } - - /** - * Get the pre-saved request failure if exists. - * - * @param string $request_label The request label. - * - * @return null|WP_Error - */ - private static function get_request_failure( $request_label ) { - if ( array_key_exists( $request_label, static::$wpcom_request_failures ) ) { - return static::$wpcom_request_failures[ $request_label ]; - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-anti-spam.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-anti-spam.php deleted file mode 100644 index 1fa5b0a6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-anti-spam.php +++ /dev/null @@ -1,194 +0,0 @@ - true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_anti_spam'; - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'security', 'complete' ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=akismet-key-config' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php deleted file mode 100644 index 302d1246..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php +++ /dev/null @@ -1,455 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_site_backup_undo_event', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Get the product name - * - * @return string - */ - public static function get_name() { - return 'VaultPress Backup'; - } - - /** - * Get the product title - * - * @return string - */ - public static function get_title() { - return 'Jetpack VaultPress Backup'; - } - - /** - * Get the internationalized product description - * - * @return string - */ - public static function get_description() { - if ( static::is_active() ) { - return __( 'Save every change', 'jetpack-my-jetpack' ); - } - - return __( 'Secure your site with automatic backups and one-click restores', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized product long description - * - * @return string - */ - public static function get_long_description() { - return __( 'Never lose a word, image, page, or time worrying about your site with automated backups & one-click restores.', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized features list - * - * @return array Backup features list - */ - public static function get_features() { - return array( - _x( 'Real-time cloud backups', 'Backup Product Feature', 'jetpack-my-jetpack' ), - _x( '10GB of backup storage', 'Backup Product Feature', 'jetpack-my-jetpack' ), - _x( '30-day archive & activity log*', 'Backup Product Feature', 'jetpack-my-jetpack' ), - _x( 'One-click restores', 'Backup Product Feature', 'jetpack-my-jetpack' ), - ); - } - - /** - * Get disclaimers corresponding to a feature - * - * @return array Backup disclaimers list - */ - public static function get_disclaimers() { - return array( - array( - 'text' => _x( '* Subject to your usage and storage limit.', 'Backup Product Disclaimer', 'jetpack-my-jetpack' ), - 'link_text' => _x( 'Learn more', 'Backup Product Disclaimer', 'jetpack-my-jetpack' ), - 'url' => Redirect::get_url( 'jetpack-faq-backup-disclaimer' ), - ), - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_backup_t1_yearly'; - } - - /** - * Get the URL where the user should be redirected after checkout - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the product princing details - * - * @return array Pricing details - */ - public static function get_pricing_for_ui() { - return array_merge( - array( - 'available' => true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Checks if the user has the correct permissions - */ - public static function permissions_callback() { - return current_user_can( 'manage_options' ); - } - - /** - * This will fetch the last rewindable event from the Activity Log and - * the last rewind_id prior to that. - * - * @return array|WP_Error|null - */ - public static function get_site_backup_undo_event() { - $blog_id = \Jetpack_Options::get_option( 'id' ); - - $response = Client::wpcom_json_api_request_as_user( - '/sites/' . $blog_id . '/activity/rewindable?force=wpcom', - 'v2', - array(), - null, - 'wpcom' - ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - return null; - } - - $body = json_decode( $response['body'], true ); - - if ( ! isset( $body['current'] ) ) { - return null; - } - - // Preparing the response structure - $undo_event = array( - 'last_rewindable_event' => null, - 'undo_backup_id' => null, - ); - - // List of events that will not be considered to be undo. - // Basically we should not `undo` a full backup event, but we could - // use them to undo any other action like plugin updates. - $last_event_exceptions = array( - 'rewind__backup_only_complete_full', - 'rewind__backup_only_complete_initial', - 'rewind__backup_only_complete', - 'rewind__backup_complete_full', - 'rewind__backup_complete_initial', - 'rewind__backup_complete', - ); - - // Looping through the events to find the last rewindable event and the last backup_id. - // The idea is to find the last rewindable event and then the last rewind_id before that. - $found_last_event = false; - foreach ( $body['current']['orderedItems'] as $event ) { - if ( $event['is_rewindable'] ) { - if ( ! $found_last_event && ! in_array( $event['name'], $last_event_exceptions, true ) ) { - $undo_event['last_rewindable_event'] = $event; - $found_last_event = true; - } elseif ( $found_last_event ) { - $undo_event['undo_backup_id'] = $event['rewind_id']; - break; - } - } - } - - return rest_ensure_response( $undo_event ); - } - - /** - * Hits the wpcom api to check rewind status. - * - * @todo Maybe add caching. - * - * @return object|WP_Error - */ - private static function get_state_from_wpcom() { - static $status = null; - - if ( $status !== null ) { - return $status; - } - - $site_id = \Jetpack_Options::get_option( 'id' ); - - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%d/rewind', $site_id ) . '?force=wpcom', - '2', - array( 'timeout' => 2 ), - null, - 'wpcom' - ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $status = new WP_Error( 'rewind_state_fetch_failed' ); - return $status; - } - - $body = wp_remote_retrieve_body( $response ); - $status = json_decode( $body ); - return $status; - } - - /** - * Hits the wpcom api to retrieve the last 10 backup records. - * - * @return object|WP_Error - */ - public static function get_latest_backups() { - static $backups = null; - - if ( $backups !== null ) { - return $backups; - } - - $site_id = \Jetpack_Options::get_option( 'id' ); - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%d/rewind/backups', $site_id ) . '?force=wpcom', - '2', - array( 'timeout' => 2 ), - null, - 'wpcom' - ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $backups = new WP_Error( 'rewind_backups_fetch_failed' ); - return $backups; - } - - $body = wp_remote_retrieve_body( $response ); - $backups = json_decode( $body ); - return $backups; - } - - /** - * Determines whether the module/plugin/product needs the users attention. - * Typically due to some sort of error where user troubleshooting is needed. - * - * @return boolean|array - */ - public static function does_module_need_attention() { - $previous_backup_status = get_transient( self::BACKUP_STATUS_TRANSIENT_KEY ); - - // If we have a previous backup status, show it. - if ( ! empty( $previous_backup_status ) ) { - return $previous_backup_status === 'no_errors' ? false : $previous_backup_status; - } - - $backup_failed_status = false; - // First check the status of Rewind for failure. - $rewind_state = self::get_state_from_wpcom(); - if ( ! is_wp_error( $rewind_state ) ) { - if ( $rewind_state->state !== 'active' && $rewind_state->state !== 'provisioning' && $rewind_state->state !== 'awaiting_credentials' ) { - $backup_failed_status = array( - 'type' => 'error', - 'data' => array( - 'source' => 'rewind', - 'status' => isset( $rewind_state->reason ) && ! empty( $rewind_state->reason ) ? $rewind_state->reason : $rewind_state->state, - 'last_updated' => $rewind_state->last_updated, - ), - ); - } - } - // Next check for a failed last backup. - $latest_backups = self::get_latest_backups(); - if ( ! is_wp_error( $latest_backups ) ) { - // Get the last/latest backup record. - $last_backup = null; - foreach ( $latest_backups as $backup ) { - if ( $backup->is_backup ) { - $last_backup = $backup; - break; - } - } - - if ( $last_backup && isset( $last_backup->status ) ) { - if ( $last_backup->status !== 'started' && ! preg_match( '/-will-retry$/', $last_backup->status ) && $last_backup->status !== 'finished' ) { - $backup_failed_status = array( - 'type' => 'error', - 'data' => array( - 'source' => 'last_backup', - 'status' => $last_backup->status, - 'last_updated' => $last_backup->last_updated, - ), - ); - } - } - } - - if ( is_array( $backup_failed_status ) && $backup_failed_status['type'] === 'error' ) { - set_transient( self::BACKUP_STATUS_TRANSIENT_KEY, $backup_failed_status, 5 * MINUTE_IN_SECONDS ); - } else { - set_transient( self::BACKUP_STATUS_TRANSIENT_KEY, 'no_errors', HOUR_IN_SECONDS ); - } - - return $backup_failed_status; - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'security', 'complete' ); - } - - /** - * Get the URL the user is taken after activating the product - * - * @return ?string - */ - public static function get_post_activation_url() { - return ''; // stay in My Jetpack page or continue the purchase flow if needed. - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - // check standalone first - if ( static::is_standalone_plugin_active() ) { - return admin_url( 'admin.php?page=jetpack-backup' ); - // otherwise, check for the main Jetpack plugin - } elseif ( static::is_jetpack_plugin_active() ) { - return Redirect::get_url( 'my-jetpack-manage-backup' ); - } - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_backup_daily', - 'jetpack_backup_daily_monthly', - 'jetpack_backup_realtime', - 'jetpack_backup_realtime_monthly', - 'jetpack_backup_t1_yearly', - 'jetpack_backup_t1_monthly', - 'jetpack_backup_t1_bi_yearly', - 'jetpack_backup_t2_yearly', - 'jetpack_backup_t2_monthly', - 'jetpack_backup_t0_yearly', - 'jetpack_backup_t0_monthly', - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php deleted file mode 100644 index 1c2d5afb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php +++ /dev/null @@ -1,418 +0,0 @@ - __( 'Auto CSS Optimization', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Move important styling information to the start of the page, which helps pages display your content sooner, so your users don’t have to wait for the entire page to load. Commonly referred to as Critical CSS.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'included' => false, - 'description' => __( 'Manual', 'jetpack-my-jetpack' ), - 'info' => array( - 'title' => __( 'Manual Critical CSS regeneration', 'jetpack-my-jetpack' ), - 'content' => __( - '

            To enhance the speed of your site, with this plan you will need to optimize CSS by using the Manual Critical CSS generation feature whenever you:

            -
              -
            • Make theme changes.
            • -
            • Write a new post/page.
            • -
            • Edit a post/page.
            • -
            • Activate, deactivate, or update plugins that impact your site layout or HTML structure.
            • -
            • Change settings of plugins that impact your site layout or HTML structure.
            • -
            • Upgrade your WordPress version if the new release includes core CSS changes.
            • -
            ', - 'jetpack-my-jetpack' - ), - ), - ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => __( 'Included', 'jetpack-my-jetpack' ), - 'info' => array( - 'title' => __( 'Automatic Critical CSS regeneration', 'jetpack-my-jetpack' ), - 'content' => __( - '

            It’s essential to regenerate Critical CSS to optimize your site speed whenever your HTML or CSS structure changes. Being on top of this can be tedious and time-consuming.

            -

            Boost’s cloud service can automatically detect when your site needs the Critical CSS regenerated, and perform this function behind the scenes without requiring you to monitor it manually.

            ', - 'jetpack-my-jetpack' - ), - ), - ), - ), - ), - array( - 'name' => __( 'Automatic image size analysis', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Scan your site for images that aren’t properly sized for the device they’re being viewed on.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Historical performance scores', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Get access to your historical performance scores and see advanced Core Web Vitals data.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Dedicated email support', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - '

            Paid customers get dedicated email support from our world-class Happiness Engineers to help with any issue.

            -

            All other questions are handled by our team as quickly as we are able to go through the WordPress support forum.

            ', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Page Cache', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Page caching speeds up load times by storing a copy of each web page on the first visit, allowing subsequent visits to be served instantly. This reduces server load and improves user experience by delivering content faster, without waiting for the page to be generated again.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Image CDN Quality Settings', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Fine-tune image quality settings to your liking.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Image CDN Auto-Resize Lazy Images', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Optimizes lazy-loaded images by dynamically serving perfectly sized images for each device.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Image CDN', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Deliver images from Jetpack\'s Content Delivery Network. Automatically resizes your images to an appropriate size, converts them to modern efficient formats like WebP, and serves them from a worldwide network of servers.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Image guide', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Discover and fix images with a suboptimal resolution, aspect ratio, or file size, improving user experience and page speed.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Defer non-essential JavaScript', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Run non-essential JavaScript after the page has loaded so that styles and images can load more quickly.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Concatenate JS and CSS', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Boost your website performance by merging and compressing JavaScript and CSS files, reducing site loading time and number of requests.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - ); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the product princing details - * - * @return array Pricing details - */ - public static function get_pricing_for_ui() { - return array( - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'available' => true, - 'is_free' => true, - ), - self::UPGRADED_TIER_SLUG => array_merge( - array( - 'available' => true, - 'wpcom_product_slug' => self::UPGRADED_TIER_PRODUCT_SLUG, - ), - Wpcom_Products::get_product_pricing( self::UPGRADED_TIER_PRODUCT_SLUG ) - ), - ), - ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack-boost' ); - } - - /** - * Activates the product by installing and activating its plugin - * - * @param bool|WP_Error $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return boolean|WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - - $product_activation = parent::do_product_specific_activation( $current_result ); - - if ( is_wp_error( $product_activation ) && 'module_activation_failed' === $product_activation->get_error_code() ) { - // A bundle is not a module. There's nothing in the plugin to be activated, so it's ok to fail to activate the module. - $product_activation = true; - } - - // We just "got started" in My Jetpack, so skip the in-plugin experience. - update_option( 'jb_get_started', false ); - - return $product_activation; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_boost_yearly', - 'jetpack_boost_monthly', - 'jetpack_boost_bi_yearly', - ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'complete' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-complete.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-complete.php deleted file mode 100644 index 31be8bb4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-complete.php +++ /dev/null @@ -1,271 +0,0 @@ - true, - 'wpcom_product_slug' => $product_slug, - ), - Wpcom_Products::get_product_pricing( $product_slug ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_complete'; - } - - /** - * Checks whether the Jetpack module is active - * - * This is a bundle and not a product. We should not use this information for anything - * - * @return bool - */ - public static function is_module_active() { - return false; - } - - /** - * Activates the product by installing and activating its plugin - * - * @param WP_Error|bool $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return bool|\WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - $product_activation = parent::do_product_specific_activation( $current_result ); - - // A bundle is not a module. There's nothing in the plugin to be activated, so it's ok to fail to activate the module. - if ( is_wp_error( $product_activation ) && 'module_activation_failed' === $product_activation->get_error_code() ) { - return $product_activation; - } - - // At this point, Jetpack plugin is installed. Let's activate each individual product. - $activation = Social::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Stats::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Anti_Spam::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Backup::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Scan::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Boost::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = CRM::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Search::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = VideoPress::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - return $activation; - } - - /** - * Checks whether the Product is active - * - * Security is a bundle and not a module. Activation takes place on WPCOM. So lets consider it active if jetpack is active and has the plan. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active() && static::has_required_plan(); - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_required_plan() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( str_starts_with( $purchase->product_slug, 'jetpack_complete' ) ) { - return true; - } - } - } - return false; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_complete', - 'jetpack_complete_monthly', - 'jetpack_complete_bi_yearly', - ); - } - - /** - * Checks whether product is a bundle. - * - * @return boolean True - */ - public static function is_bundle_product() { - return true; - } - - /** - * Return all the products it contains. - * - * @return array Product slugs - */ - public static function get_supported_products() { - return array( - 'anti-spam', - 'backup', - 'boost', - 'crm', - 'scan', - 'search', - 'social', - 'stats', - 'videopress', - ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-creator.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-creator.php deleted file mode 100644 index 39be46c7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-creator.php +++ /dev/null @@ -1,356 +0,0 @@ - __( 'Import subscribers', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Import a CSV file of your existing subscribers to be sent your Newsletter.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'included' => true, - 'description' => __( '100 subscribers', 'jetpack-my-jetpack' ), - ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => __( 'Unlimited subscribers', 'jetpack-my-jetpack' ), - ), - ), - ), - array( - 'name' => __( 'Transaction fees', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - '

            Fees are only collected when you accept payments.

            -

            Fees are based on the Jetpack plan you have and are calculated as a percentage of your revenue from 10% on the Free plan to 2% on the Creator plan (plus Stripe fees).

            ', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'included' => true, - 'description' => __( '10%', 'jetpack-my-jetpack' ), - ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => __( '2%', 'jetpack-my-jetpack' ), - ), - ), - ), - array( - 'name' => __( 'Jetpack Blocks', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Jetpack has over 40 Gutenberg blocks to help you with your content creation, such as displaying your podcasts, showing different content to repeat visitors, creating contact forms and many more.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Paid content gating', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Lock your content behind a paid content block. To access the content, readers will need to pay a one-time fee or a recurring subscription.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Paywall access', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Add a Paywall to your content which lets your visitors read a section of your content before being asked to subscribe to continue reading.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Newsletter', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Start a Newsletter by sending your content as an email newsletter direct to your fans email inboxes.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Pay with PayPal', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - 'Accept payment with PayPal for simple payments like eBooks, courses and more.', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'WordAds', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - '

            WordAds adds advertisements to your website. Start earning from your website traffic.

            -

            Over 50 internet advertisers — including Google AdSense & Adx, AppNexus, Amazon A9, AOL Marketplace, Yahoo, Criteo, and more — bid to display ads in WordAds spots.

            ', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Dedicated email support', 'jetpack-my-jetpack' ), - 'info' => array( - 'content' => __( - '

            Paid customers get dedicated email support from our world-class Happiness Engineers to help with any issue.

            -

            All other questions are handled by our team as quickly as we are able to go through the WordPress support forum.

            ', - 'jetpack-my-jetpack' - ), - ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - ); - } - - /** - * Get the product princing details - * - * @return array Pricing details - */ - public static function get_pricing_for_ui() { - return array( - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'available' => true, - 'is_free' => true, - ), - self::UPGRADED_TIER_SLUG => array_merge( - array( - 'available' => true, - 'wpcom_product_slug' => self::UPGRADED_TIER_PRODUCT_SLUG, - ), - Wpcom_Products::get_product_pricing( self::UPGRADED_TIER_PRODUCT_SLUG ) - ), - ), - ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack#/settings?term=creator' ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_creator_yearly'; - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_biyearly_product_slug() { - return 'jetpack_creator_bi_yearly'; - } - - /** - * Get the WPCOM monthly product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_monthly_product_slug() { - return 'jetpack_creator_monthly'; - } - - /** - * Get the product-slugs of the paid bundles/plans that this product/module is included in - * - * @return array - */ - public static function get_paid_bundles_that_include_product() { - return array( - 'jetpack_complete', - 'jetpack_complete_monthly', - 'jetpack_complete_bi-yearly', - ); - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_creator_yearly', - 'jetpack_creator_monthly', - 'jetpack_creator_bi_yearly', - ); - } - - /** - * Checks whether the product can be upgraded - i.e. this shows the /#add-creator interstitial - * - * @return boolean - */ - public static function is_upgradable() { - return ! self::has_paid_plan_for_product(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php deleted file mode 100644 index 71aa29a8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php +++ /dev/null @@ -1,205 +0,0 @@ - true, - 'is_free' => false, - 'full_price' => 132, - 'discount_price' => 132, - 'is_introductory_offer' => false, - 'product_term' => 'year', - 'introductory_offer' => null, - // CRM is only sold in USD - 'currency_code' => 'USD', - ); - } - - /** - * Get the URL the user is taken after activating the product - * - * @return ?string - */ - public static function get_post_activation_url() { - return admin_url( 'admin.php?page=zerobscrm-plugin' ); // Welcome page. - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=zerobscrm-dash' ); - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * CRM is available as part of Jetpack Complete - * - * @return boolean - */ - public static function has_paid_plan_for_product() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - - // TODO: check if CRM has a separate plan - - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( str_starts_with( $purchase->product_slug, 'jetpack_complete' ) ) { - return true; - } - } - } - - return false; - } - - /** - * Get the product-slugs of the paid bundles/plans that this product/module is included in. - * - * @return array - */ - public static function get_paid_bundles_that_include_product() { - return array( - 'jetpack_complete', - 'jetpack_complete_monthly', - 'jetpack_complete_bi_yearly', - ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'complete' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php deleted file mode 100644 index 51f02232..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php +++ /dev/null @@ -1,140 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * Checks whether the Product is active. - * If Jetpack plugin is active, then Extras will be inactive. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active(); - } - - /** - * Checks whether the plugin is installed - * If Jetpack plugin is installed, then Extras will be inactive. - * - * @return boolean - */ - public static function is_plugin_installed() { - return static::is_jetpack_plugin_installed(); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack' ); - } - - /** - * Activates the Jetpack plugin - * - * @return null|WP_Error Null on success, WP_Error on invalid file. - */ - public static function activate_plugin() { - return activate_plugin( static::get_installed_plugin_filename( 'jetpack' ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-growth.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-growth.php deleted file mode 100644 index 1ec4351c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-growth.php +++ /dev/null @@ -1,223 +0,0 @@ - true, - 'wpcom_product_slug' => $product_slug, - ), - Wpcom_Products::get_product_pricing( $product_slug ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_growth_yearly'; - } - - /** - * Checks whether the Jetpack module is active - * - * This is a bundle and not a product. We should not use this information for anything - * - * @return bool - */ - public static function is_module_active() { - return false; - } - - /** - * Activates the product by installing and activating its plugin - * - * @param WP_Error|bool $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return bool|\WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - $product_activation = parent::do_product_specific_activation( $current_result ); - - // A bundle is not a module. There's nothing in the plugin to be activated, so it's ok to fail to activate the module. - if ( is_wp_error( $product_activation ) && 'module_activation_failed' === $product_activation->get_error_code() ) { - return $product_activation; - } - - // At this point, Jetpack plugin is installed. Let's activate each individual product. - $activation = Social::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Stats::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - return $activation; - } - - /** - * Checks whether the Product is active - * - * Growth is a bundle and not a module. Activation takes place on WPCOM. So lets consider it active if jetpack is active and has the plan. - * - * @return bool - */ - public static function is_active() { - return static::is_jetpack_plugin_active() && static::has_required_plan(); - } - - /** - * Checks whether the current plan (or purchase) of the site already supports the product - * - * @return bool - */ - public static function has_required_plan() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( - str_starts_with( $purchase->product_slug, 'jetpack_growth' ) || - str_starts_with( $purchase->product_slug, 'jetpack_complete' ) - ) { - return true; - } - } - } - return false; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_growth_yearly', - 'jetpack_growth_monthly', - 'jetpack_growth_bi_yearly', - ); - } - - /** - * Checks whether the product is a bundle - * - * @return bool - */ - public static function is_bundle_product() { - return true; - } - - /** - * Returns all products it contains. - * - * @return array Product slugs - */ - public static function get_supported_products() { - return array( 'social', 'stats' ); - } - - /** - * Get the URL where the user manages the product - * - * @return string - */ - public static function get_manage_url() { - return ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php deleted file mode 100644 index 0fb93d67..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php +++ /dev/null @@ -1,153 +0,0 @@ -get_error_code() ) { - $product_activation = Plugins_Installer::install_plugin( self::JETPACK_PLUGIN_SLUG ); - if ( ! is_wp_error( $product_activation ) ) { - $product_activation = static::activate_plugin(); - } - } - if ( is_wp_error( $product_activation ) ) { - return $product_activation; - } - } - - if ( ! empty( static::$module_name ) ) { - // Only activate the module if the plan supports it - // We don't want to throw an error for a missing plan here since we try activation before purchase - if ( static::$requires_plan && ! static::has_any_plan_for_product() ) { - return true; - } - - $module_activation = ( new Modules() )->activate( static::$module_name, false, false ); - - if ( ! $module_activation ) { - return new WP_Error( 'module_activation_failed', __( 'Error activating Jetpack module', 'jetpack-my-jetpack' ) ); - } - - return $module_activation; - } - - return true; - } - - /** - * Install and activate the standalone plugin in the case it's missing. - * - * @return boolean|WP_Error - */ - public static function install_and_activate_standalone() { - $result = parent::install_and_activate_standalone(); - - if ( is_wp_error( $result ) ) { - return $result; - } - - /** - * Activate the module as well, if the user has a plan - * or the product does not require a plan to work - */ - if ( static::has_any_plan_for_product() && isset( static::$module_name ) ) { - $module_activation = ( new Modules() )->activate( static::$module_name, false, false ); - - if ( ! $module_activation ) { - return new WP_Error( 'module_activation_failed', __( 'Error activating Jetpack module', 'jetpack-my-jetpack' ) ); - } - } - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-jetpack-ai.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-jetpack-ai.php deleted file mode 100644 index fd185631..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-jetpack-ai.php +++ /dev/null @@ -1,656 +0,0 @@ - __( 'Number of requests', 'jetpack-my-jetpack' ), - 'info' => array( - 'title' => __( 'Requests', 'jetpack-my-jetpack' ), - 'content' => __( 'Increase your monthly request limit. Upgrade now and have the option to further increase your requests with additional upgrades.', 'jetpack-my-jetpack' ), - ), - 'tiers' => array( - self::CURRENT_TIER_SLUG => array( - 'included' => true, - 'description' => $current_description, - ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => $next_description, - ), - ), - ), - array( - 'name' => __( 'Generate and edit content', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::CURRENT_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Build forms from prompts', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::CURRENT_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Get feedback on posts', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::CURRENT_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Generate featured images', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::CURRENT_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - ); - } - - /** - * Get the current usage tier - * - * @return int - */ - public static function get_current_usage_tier() { - if ( ! self::is_site_connected() ) { - return 0; - } - - $info = self::get_ai_assistant_feature(); - - // Bail early if it's not possible to fetch the feature data. - if ( is_wp_error( $info ) ) { - return 0; - } - - $current_tier = isset( $info['current-tier']['value'] ) ? $info['current-tier']['value'] : null; - - return $current_tier; - } - - /** - * Get the next usage tier - * - * @return int - */ - public static function get_next_usage_tier() { - if ( ! self::is_site_connected() || ! self::has_paid_plan_for_product() ) { - // without site connection we can't know if tiers are enabled or not, - // hence we can't know if the next tier is 100 or 1 (unlimited). - return 100; - } - - $info = self::get_ai_assistant_feature(); - - // Bail early if it's not possible to fetch the feature data or if it's included in a plan. - if ( is_wp_error( $info ) || empty( $info ) ) { - return null; - } - - // Trust the next tier provided by the feature data. - $next_tier = isset( $info['next-tier']['value'] ) ? $info['next-tier']['value'] : null; - - return $next_tier; - } - - /** - * Get the internationalized product description - * - * @return string - */ - public static function get_description() { - return __( 'Enhance your writing and productivity with our AI suite', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized usage tier long description by tier - * - * @param int $tier The usage tier. - * @return string - */ - public static function get_long_description_by_usage_tier( $tier ) { - $long_descriptions = array( - 1 => __( 'Jetpack AI Assistant brings the power of AI right into your WordPress editor, letting your content creation soar to new heights.', 'jetpack-my-jetpack' ), - 100 => __( 'The most advanced AI technology Jetpack has to offer.', 'jetpack-my-jetpack' ), - ); - $tiered_description = __( 'Upgrade and increase the amount of your available monthly requests to continue using the most advanced AI technology Jetpack has to offer.', 'jetpack-my-jetpack' ); - - return isset( $long_descriptions[ $tier ] ) ? $long_descriptions[ $tier ] : $tiered_description; - } - - /** - * Get the internationalized product long description - * - * @return string - */ - public static function get_long_description() { - $next_tier = self::get_next_usage_tier(); - - return self::get_long_description_by_usage_tier( $next_tier ); - } - - /** - * Get the internationalized usage tier features by tier - * - * @param int $tier The usage tier. - * @return string - */ - public static function get_features_by_usage_tier( $tier ) { - $is_tier_plan = $tier && intval( $tier ) > 1; - - if ( $tier === 100 && ( ! self::is_site_connected() || ! self::has_paid_plan_for_product() ) ) { - // in these cases, get_next_usage_tier() will return 100 - // 100 is fine as default when tiered plans are enabled, but not otherwise - $is_tier_plan = false; - } - - $features = array( - __( 'High request capacity *', 'jetpack-my-jetpack' ), - __( 'Generate text, tables, lists, and forms', 'jetpack-my-jetpack' ), - __( 'Easily refine content to your liking', 'jetpack-my-jetpack' ), - __( 'Make your content easier to read', 'jetpack-my-jetpack' ), - __( 'Generate images with one-click', 'jetpack-my-jetpack' ), - __( 'Optimize your titles for better performance', 'jetpack-my-jetpack' ), - __( 'Priority support', 'jetpack-my-jetpack' ), - ); - - $tiered_features = array( - __( 'Prompt based content generation', 'jetpack-my-jetpack' ), - __( 'Generate text, tables, and lists', 'jetpack-my-jetpack' ), - __( 'Adaptive tone adjustment', 'jetpack-my-jetpack' ), - __( 'Superior spelling and grammar correction', 'jetpack-my-jetpack' ), - __( 'Title & summary generation', 'jetpack-my-jetpack' ), - __( 'Priority support', 'jetpack-my-jetpack' ), - /* translators: %d is the number of requests. */ - sprintf( __( 'Up to %d requests per month', 'jetpack-my-jetpack' ), $tier ), - ); - - return $is_tier_plan ? $tiered_features : $features; - } - - /** - * Get the internationalized features list - * - * @return array Jetpack AI features list - */ - public static function get_features() { - $next_tier = self::get_next_usage_tier(); - - return self::get_features_by_usage_tier( $next_tier ); - } - - /** - * Get the product pricing details by tier - * - * @param int|null $tier The usage tier. - * @return array Pricing details - */ - public static function get_pricing_for_ui_by_usage_tier( $tier ) { - if ( $tier === null ) { - return array(); - } - - $product = Wpcom_Products::get_product( static::get_wpcom_product_slug() ); - - if ( empty( $product ) ) { - return array(); - } - - $tier_plans_enabled = self::are_tier_plans_enabled(); - - /* - * when tiers are enabled and the price tier list is empty, - * we may need to renew the cache for the product data so - * we get the new price tier list. - * - * if the list is still empty after the fresh data, we will - * default to empty pricing (by returning an empty array). - */ - if ( empty( $product->price_tier_list ) && $tier_plans_enabled ) { - $product = Wpcom_Products::get_product( static::get_wpcom_product_slug(), true ); - } - - // get the base pricing for the unlimited plan, for compatibility - $base_pricing = Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ); - - $price_tier_list = $product->price_tier_list; - $yearly_prices = array(); - - foreach ( $price_tier_list as $price_tier ) { - if ( isset( $price_tier->maximum_units ) && isset( $price_tier->maximum_price ) ) { - // The prices are in cents - $yearly_prices[ $price_tier->maximum_units ] = $price_tier->maximum_price / 100; - } - } - - // add the base pricing to the list - $prices = array( 1 => $base_pricing ); - - foreach ( $yearly_prices as $units => $price ) { - $prices[ $units ] = array_merge( - $base_pricing, - array( - 'full_price' => $price, - 'discount_price' => $price, - 'is_introductory_offer' => false, - 'introductory_offer' => null, - ) - ); - } - - return isset( $prices[ $tier ] ) ? $prices[ $tier ] : array(); - } - - /** - * Get the product pricing details - * - * @return array Pricing details - */ - public static function get_pricing_for_ui() { - // no tiers - if ( ! self::are_tier_plans_enabled() ) { - return array_merge( - array( - 'available' => true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - // hardcoding 1 as next tier if tiers are not enabled - self::get_pricing_for_ui_by_usage_tier( 1 ) - ); - } - - $next_tier = self::get_next_usage_tier(); - $current_tier = self::get_current_usage_tier(); - $current_call_to_action = $current_tier === 0 - ? __( 'Continue for free', 'jetpack-my-jetpack' ) - : __( 'I\'m fine with my plan, thanks', 'jetpack-my-jetpack' ); - $next_call_to_action = $next_tier === null - ? __( 'Contact Us', 'jetpack-my-jetpack' ) - : __( 'Upgrade', 'jetpack-my-jetpack' ); - - return array( - 'tiers' => array( - self::CURRENT_TIER_SLUG => array_merge( - self::get_pricing_for_ui_by_usage_tier( $current_tier ), - array( - 'available' => true, - 'is_free' => true, - 'call_to_action' => $current_call_to_action, - ) - ), - self::UPGRADED_TIER_SLUG => array_merge( - self::get_pricing_for_ui_by_usage_tier( $next_tier ), - array( - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - 'quantity' => $next_tier, - 'call_to_action' => $next_call_to_action, - ) - ), - ), - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_ai_yearly'; - } - - /** - * Get the WPCOM monthly product slug used to make the purchase - * - * @return string - */ - public static function get_wpcom_monthly_product_slug() { - return 'jetpack_ai_monthly'; - } - - /** - * Get the WPCOM bi-yearly product slug used to make the purchase - * - * @return string - */ - public static function get_wpcom_bi_yearly_product_slug() { - return 'jetpack_ai_bi_yearly'; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_ai_yearly', - 'jetpack_ai_monthly', - 'jetpack_ai_bi_yearly', - ); - } - - /** - * Checks whether the product can be upgraded to a different product. - * - * @return boolean - */ - public static function is_upgradable() { - $has_ai_feature = static::does_site_have_feature( 'ai-assistant' ); - $tier_plans_enabled = self::are_tier_plans_enabled(); - $current_tier = self::get_current_usage_tier(); - - if ( $has_ai_feature && ! $tier_plans_enabled && $current_tier >= 1 ) { - return false; - } - - $next_tier = self::get_next_usage_tier(); - - // The check below is debatable, not having the feature should not flag as not upgradable. - // If user is free (tier = 0), not unlimited (tier = 1) and has a next tier, then it's upgradable. - if ( $current_tier !== null && $current_tier !== 1 && $next_tier ) { - return true; - } - - // Mark as not upgradable if user is on unlimited tier or does not have any plan. - if ( ! $has_ai_feature || null === $current_tier || 1 === $current_tier ) { - return false; - } - - return true; - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the URL the user is taken after activating the product through the checkout - * - * @return ?string - */ - public static function get_post_activation_url() { - return self::get_manage_url(); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=my-jetpack#/jetpack-ai' ); - } - - /** - * Checks whether the plugin is installed - * - * @return boolean - */ - public static function is_plugin_installed() { - return self::is_jetpack_plugin_installed(); - } - - /** - * Checks whether the plugin is active - * - * @return boolean - */ - public static function is_plugin_active() { - return (bool) static::is_jetpack_plugin_active(); - } - - /** - * Get data about the AI Assistant feature - * - * @return array - */ - public static function get_ai_assistant_feature() { - // Bail early if the plugin is not active. - if ( ! self::is_jetpack_plugin_installed() ) { - return array(); - } - - // Check if the global constant is defined. - if ( ! defined( 'JETPACK__PLUGIN_DIR' ) ) { - return array(); - } - - // Bail early if the site is not connected. - if ( ! self::is_site_connected() ) { - return array(); - } - - // Check if class exists. If not, try to require it once. - if ( ! class_exists( 'Jetpack_AI_Helper' ) ) { - $class_file_path = JETPACK__PLUGIN_DIR . '_inc/lib/class-jetpack-ai-helper.php'; - - // Check whether the file exists - if ( ! file_exists( $class_file_path ) ) { - return array(); - } - - require_once $class_file_path; - } - - return \Jetpack_AI_Helper::get_ai_assistance_feature(); - } - - /** - * Get the AI Assistant tiered plans status - * - * @return boolean - */ - public static function are_tier_plans_enabled() { - $info = self::get_ai_assistant_feature(); - if ( is_wp_error( $info ) ) { - // this is another faulty default value, we'll assume disabled while - // production is enabled - return false; - } - - if ( ! empty( $info ) && isset( $info['tier-plans-enabled'] ) ) { - return boolval( $info['tier-plans-enabled'] ); - } - return false; - } - - /** - * Checks whether the site is connected to WordPress.com. - * - * @return boolean - */ - private static function is_site_connected() { - return ( new Connection_Manager() )->is_connected(); - } - - /** - * Get the URL where the user manages the product - * - * NOTE: this method is the only thing that resembles an initialization for the product. - * - * @return void - */ - public static function extend_plugin_action_links() { - add_action( 'myjetpack_enqueue_scripts', array( static::class, 'admin_enqueue_scripts' ) ); - add_filter( 'default_content', array( static::class, 'add_ai_block' ), 10, 2 ); - } - - /** - * Enqueue the AI Assistant script - * - * The script is just a global variable used for the nonce, needed for the create post link. - * - * @return void - */ - public static function admin_enqueue_scripts() { - wp_register_script( - 'my_jetpack_ai_app', - false, - array(), - Initializer::PACKAGE_VERSION, - array( 'in_footer' => true ) - ); - wp_localize_script( - 'my_jetpack_ai_app', - 'jetpackAi', - array( - 'nonce' => wp_create_nonce( 'ai-assistant-content-nonce' ), - ) - ); - wp_enqueue_script( 'my_jetpack_ai_app' ); - } - - /** - * Add AI block to the post content - * - * Used only from the link on the product page, the filter will insert an AI Assistant block in the post content. - * - * @param string $content The post content. - * @param WP_Post $post The post object. - * @return string - */ - public static function add_ai_block( $content, $post ) { - if ( isset( $_GET['use_ai_block'] ) && isset( $_GET['_wpnonce'] ) - && wp_verify_nonce( sanitize_text_field( wp_unslash( $_GET['_wpnonce'] ) ), 'ai-assistant-content-nonce' ) - && ! empty( $post ) - && ! is_wp_error( $post ) - && current_user_can( 'edit_post', $post->ID ) - && '' === $content - ) { - return ''; - } - return $content; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php deleted file mode 100644 index 40e4ef7f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php +++ /dev/null @@ -1,164 +0,0 @@ -has_connected_owner() ) { - return Products::STATUS_USER_CONNECTION_ERROR; - } - - if ( ! static::is_module_active() ) { - return Products::STATUS_MODULE_DISABLED; - } - - return Products::STATUS_ACTIVE; - } - - /** - * Gets the current status of the product - * - * @return string - */ - public static function get_status() { - if ( static::$is_feature ) { - return static::get_feature_status(); - } - - $status = parent::get_status(); - if ( Products::STATUS_INACTIVE === $status && ! static::is_module_active() ) { - $status = Products::STATUS_MODULE_DISABLED; - } - return $status; - } - - /** - * Activates the product by installing and activating its plugin - * - * @param bool|WP_Error $plugin_activation Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return boolean|\WP_Error - */ - public static function do_product_specific_activation( $plugin_activation ) { - self::check_for_module_name(); - - if ( is_wp_error( $plugin_activation ) ) { - return $plugin_activation; - } - - if ( ! class_exists( 'Jetpack' ) ) { - return new WP_Error( 'plugin_activation_failed', __( 'Error activating Jetpack plugin', 'jetpack-my-jetpack' ) ); - } - - $module_activation = Jetpack::activate_module( static::$module_name, false, false ); - - if ( ! $module_activation ) { - return new WP_Error( 'module_activation_failed', __( 'Error activating Jetpack module', 'jetpack-my-jetpack' ) ); - } - - return $module_activation; - } - - /** - * Deactivate the module - * - * @return boolean - */ - public static function deactivate() { - self::check_for_module_name(); - if ( ! class_exists( 'Jetpack' ) ) { - return true; - } - return Jetpack::deactivate_module( static::$module_name ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-newsletter.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-newsletter.php deleted file mode 100644 index cd24c843..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-newsletter.php +++ /dev/null @@ -1,186 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * Checks whether the Product is active. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active(); - } - - /** - * Checks whether the plugin is installed - * - * @return boolean - */ - public static function is_plugin_installed() { - return static::is_jetpack_plugin_installed(); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack#/settings?term=newsletter' ); - } - - /** - * Activates the Jetpack plugin - * - * @return null|WP_Error Null on success, WP_Error on invalid file. - */ - public static function activate_plugin(): ?WP_Error { - $plugin_filename = static::get_installed_plugin_filename( self::JETPACK_PLUGIN_SLUG ); - - if ( $plugin_filename ) { - return activate_plugin( $plugin_filename ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php deleted file mode 100644 index 88b66bec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php +++ /dev/null @@ -1,1094 +0,0 @@ - static::$slug, - 'plugin_slug' => static::get_plugin_slug(), - 'name' => static::get_name(), - 'title' => static::get_title(), - 'category' => static::$category, - /* Maintain legacy compatibility with the old product info structure. See: #42271 */ - 'description' => static::get_description(), - 'long_description' => static::get_long_description(), - 'tiers' => static::get_tiers(), - 'features' => static::get_features(), - 'features_by_tier' => static::get_features_by_tier(), - /* End of legacy compatibility fields. */ - 'disclaimers' => static::get_disclaimers(), - 'is_bundle' => static::is_bundle_product(), - 'is_plugin_active' => static::is_plugin_active(), - 'is_tiered_pricing' => static::$is_tiered_pricing, - 'is_upgradable_by_bundle' => static::is_upgradable_by_bundle(), - 'is_feature' => static::$is_feature, - 'supported_products' => static::get_supported_products(), - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - 'requires_user_connection' => static::$requires_user_connection, - 'feature_identifying_paid_plan' => static::$feature_identifying_paid_plan, - 'has_free_offering' => static::$has_free_offering, - 'manage_url' => static::get_manage_url(), - 'post_activation_url' => static::get_post_activation_url(), - 'post_activation_urls_by_feature' => static::get_manage_urls_by_feature(), - 'standalone_plugin_info' => static::get_standalone_info(), - 'class' => static::class, - 'post_checkout_url' => static::get_post_checkout_url(), - 'post_checkout_urls_by_feature' => static::get_post_checkout_urls_by_feature(), - ); - } - - /** - * Get the Product Info that requires http requests to get - * - * @throws \Exception If required attribute is not declared in the child class. - * @return array - */ - public static function get_wpcom_info() { - if ( static::$slug === null ) { - throw new \Exception( 'Product classes must declare the $slug attribute.' ); - } - - $product_data = array( - 'status' => static::get_status(), - 'pricing_for_ui' => static::get_pricing_for_ui(), - 'is_upgradable' => static::is_upgradable(), - 'description' => static::get_description(), - 'tiers' => static::get_tiers(), - 'features' => static::get_features(), - 'features_by_tier' => static::get_features_by_tier(), - 'long_description' => static::get_long_description(), - 'has_any_plan_for_product' => static::has_any_plan_for_product(), - 'has_free_plan_for_product' => static::has_free_plan_for_product(), - 'has_paid_plan_for_product' => static::has_paid_plan_for_product(), - 'purchase_url' => static::get_purchase_url(), - 'manage_paid_plan_purchase_url' => static::get_manage_paid_plan_purchase_url(), - 'renew_paid_plan_purchase_url' => static::get_renew_paid_plan_purchase_url(), - 'does_module_need_attention' => static::does_module_need_attention(), - ); - - if ( static::$slug === 'jetpack-ai' ) { - $product_data['ai-assistant-feature'] = static::get_ai_assistant_feature(); - } - - return $product_data; - } - - /** - * Collect the site's active features - * - * @return WP_Error|array - */ - public static function get_site_features_from_wpcom() { - static $features = null; - - if ( $features !== null ) { - return $features; - } - - // Check for a cached value before doing lookup - $stored_features = get_transient( self::MY_JETPACK_SITE_FEATURES_TRANSIENT_KEY ); - if ( $stored_features !== false ) { - return $stored_features; - } - - $site_id = Jetpack_Options::get_option( 'id' ); - $response = Client::wpcom_json_api_request_as_blog( sprintf( '/sites/%d/features', $site_id ), '1.1' ); - - if ( 200 !== wp_remote_retrieve_response_code( $response ) ) { - $features = new WP_Error( 'site_features_fetch_failed' ); - return $features; - } - - $body = wp_remote_retrieve_body( $response ); - $feature_return = json_decode( $body ); - - $features = array( - 'active' => $feature_return->active, - 'available' => $feature_return->available, - ); - // set a short transient to help with multiple lookups on the same page load. - set_transient( self::MY_JETPACK_SITE_FEATURES_TRANSIENT_KEY, $features, 15 ); - - return $features; - } - - /** - * Check to see if the site has a feature - * This will check the features provided by the site plans and products (including free ones) - * - * @param string $feature - the feature to check for. - * @return bool - */ - public static function does_site_have_feature( $feature ) { - if ( ! $feature ) { - return false; - } - - $features = self::get_site_features_from_wpcom(); - if ( is_wp_error( $features ) ) { - return false; - } - - return in_array( $feature, $features['active'], true ); - } - - /** - * Get the product name - * - * @return string - */ - abstract public static function get_name(); - - /** - * Get the product title - * - * @return string - */ - abstract public static function get_title(); - - /** - * Get the internationalized product description - * - * @return string - */ - abstract public static function get_description(); - - /** - * Get the internationalized product long description - * - * @return string - */ - abstract public static function get_long_description(); - - /** - * Get the tiers for the product - * - * @return boolean|string[] The slugs of the tiers (i.e. [ "free", "basic", "advanced" ]), or False if the product has no tiers. - */ - public static function get_tiers() { - return array(); - } - - /** - * Get the internationalized features list - * - * @return array - */ - abstract public static function get_features(); - - /** - * Get the internationalized comparison of features grouped by each tier - * - * @return array - */ - public static function get_features_by_tier() { - return array(); - } - - /** - * Get the product pricing - * - * @return array - */ - abstract public static function get_pricing_for_ui(); - - /** - * Get the URL where the user can purchase the product iff it doesn't have an interstitial page in My Jetpack. - * - * @return ?string - */ - public static function get_purchase_url() { - // Declare as concrete method as most Jetpack products use an interstitial page within My Jetpack. - return null; - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - abstract public static function get_manage_url(); - - /** - * Get the URL where the user manages the product for each product feature - * - * @return ?array - */ - public static function get_manage_urls_by_feature() { - return null; - } - - /** - * Get the URL the user is taken after activating the product - * - * @return ?string - */ - public static function get_post_activation_url() { - return static::get_manage_url(); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return null; - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout for each product feature - * - * @return ?array - */ - public static function get_post_checkout_urls_by_feature() { - return null; - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return null; - } - - /** - * Get the disclaimers corresponding to a feature - * - * @return ?array - */ - public static function get_disclaimers() { - return array(); - } - - /** - * Get the standalone plugin related info - * - * @return array - */ - public static function get_standalone_info() { - $is_standalone_installed = static::$has_standalone_plugin && self::is_plugin_installed(); - $is_standalone_active = static::$has_standalone_plugin && self::is_plugin_active(); - - return array( - 'has_standalone_plugin' => static::$has_standalone_plugin, - 'is_standalone_installed' => $is_standalone_installed, - 'is_standalone_active' => $is_standalone_active, - ); - } - - /** - * Checks whether the site has a paid plan for the product. - * - * This function relies on the product's `$feature_identifying_paid_plan` and `get_paid_plan_product_slugs()` function. - * If the product does not define a `$feature_identifying_paid_plan`, be sure the product includes functions for both - * `get_paid_plan_product_slugs()` and `get_paid_bundles_that_include_product()` which return all the product slugs and - * bundle slugs that include the product, respectively. - * - * @return boolean - */ - public static function has_paid_plan_for_product() { - // First check site features (if there's a feature that identifies the paid plan) - if ( static::$feature_identifying_paid_plan ) { - if ( static::does_site_have_feature( static::$feature_identifying_paid_plan ) ) { - return true; - } - } - // Otherwise check site purchases - $plans_with_product = array_merge( - static::get_paid_bundles_that_include_product(), - static::get_paid_plan_product_slugs() - ); - - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - foreach ( $plans_with_product as $plan ) { - if ( strpos( $purchase->product_slug, $plan ) !== false ) { - return true; - } - } - } - } - - return false; - } - - /** - * Checks whether the site has a free plan for the product - * Note, this should not return true if a product does not have a WPCOM plan (ex: search free, Akismet Free, stats free) - * - * @return false - */ - public static function has_free_plan_for_product() { - return false; - } - - /** - * Checks whether the site has any WPCOM plan for a product (paid or free) - * - * @return bool - */ - public static function has_any_plan_for_product() { - return static::has_paid_plan_for_product() || static::has_free_plan_for_product(); - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array(); - } - - /** - * Get the product-slugs of the paid bundles/plans that this product/module is included in. - * - * This function relies on the product's `$feature_identifying_paid_plan` - * If the product does not define a `$feature_identifying_paid_plan`, be sure to include this - * function in the product's class and have it return all the paid bundle slugs that include - * the product. - * - * @return array - */ - public static function get_paid_bundles_that_include_product() { - if ( static::is_bundle_product() ) { - return array(); - } - $features = static::get_site_features_from_wpcom(); - if ( is_wp_error( $features ) ) { - return array(); - } - $idendifying_feature = static::$feature_identifying_paid_plan; - if ( empty( $features['available'] ) ) { - return array(); - } - $paid_bundles = $features['available']->$idendifying_feature ?? array(); - $current_bundle = Wpcom_Products::get_site_current_plan( true ); - - if ( in_array( static::$feature_identifying_paid_plan, $current_bundle['features']['active'], true ) ) { - $paid_bundles[] = $current_bundle['product_slug']; - } - - return $paid_bundles; - } - - /** - * Gets the paid plan's purchase/subsciption info, or null if no paid plan purchases. - * - * @return object|null - */ - public static function get_paid_plan_purchase_for_product() { - $paid_plans = array_merge( - static::get_paid_plan_product_slugs(), - static::get_paid_bundles_that_include_product() - ); - - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return null; - } - - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - foreach ( $paid_plans as $plan ) { - if ( strpos( $purchase->product_slug, $plan ) !== false ) { - return $purchase; - } - } - } - } - - return null; - } - - /** - * Gets the paid plan's expiry date. - * - * @return string - */ - public static function get_paid_plan_expiration_date() { - $purchase = static::get_paid_plan_purchase_for_product(); - if ( ! $purchase ) { - return 'paid-plan-does-not-exist'; - } - - return $purchase->expiry_date; - } - - /** - * Gets the paid plan's expiry status. - * - * @return string - */ - public static function get_paid_plan_expiration_status() { - $purchase = static::get_paid_plan_purchase_for_product(); - if ( ! $purchase ) { - return 'paid-plan-does-not-exist'; - } - - return $purchase->expiry_status; - } - - /** - * Checks if the paid plan is expired or not. - * - * @param bool $not_expired_after_cutoff - whether to not return the plan as expired if the plan has been expired for some duration of time. - * @return bool - */ - public static function is_paid_plan_expired( $not_expired_after_cutoff = false ) { - $expiry_status = static::get_paid_plan_expiration_status(); - $expiry_date = static::get_paid_plan_expiration_date(); - $expiry_cutoff = strtotime( $expiry_date . ' ' . self::EXPIRATION_CUTOFF_TIME ); - - return $not_expired_after_cutoff - ? $expiry_status === Products::STATUS_EXPIRED && strtotime( 'now' ) < $expiry_cutoff - : $expiry_status === Products::STATUS_EXPIRED; - } - - /** - * Checks if the paid plan is expiring soon or not. - * - * @return bool - */ - public static function is_paid_plan_expiring() { - $expiry_status = static::get_paid_plan_expiration_status(); - - return $expiry_status === Products::STATUS_EXPIRING_SOON; - } - - /** - * Gets the url to manage the paid plan's purchased subscription (for plan renewal, canceling, removal, etc). - * - * @return string|null The url to the purchase management page. - */ - public static function get_manage_paid_plan_purchase_url() { - $purchase = static::get_paid_plan_purchase_for_product(); - $site_suffix = ( new Status() )->get_site_suffix(); - - if ( $purchase && $site_suffix ) { - return 'https://wordpress.com/me/purchases/' . $site_suffix . '/' . $purchase->ID; - } - - return null; - } - - /** - * Gets the url to renew the paid plan's purchased subscription. - * - * @return string|null The url to the checkout renewal page. - */ - public static function get_renew_paid_plan_purchase_url() { - $purchase = static::get_paid_plan_purchase_for_product(); - $site_suffix = ( new Status() )->get_site_suffix(); - - if ( $purchase && $site_suffix ) { - return 'https://wordpress.com/checkout/' . $purchase->product_slug . '/renew/' . $purchase->ID . '/' . $site_suffix; - } - - return null; - } - - /** - * Checks whether the product supports trial or not - * - * Returns true if it supports. Return false otherwise. - * - * Free products will always return false. - * - * @return boolean - */ - public static function has_trial_support() { - return false; - } - - /** - * Checks whether the product can be upgraded to a different product. - * - * @return boolean - */ - public static function is_upgradable() { - return ! static::has_paid_plan_for_product() && ! static::is_bundle_product(); - } - - /** - * Checks whether product is a bundle. - * - * @return boolean True if product is a bundle. Otherwise, False. - */ - public static function is_bundle_product() { - return false; - } - - /** - * Check whether the product is upgradable - * by a product bundle. - * - * @return boolean|array Bundles list or False if not upgradable by a bundle. - */ - public static function is_upgradable_by_bundle() { - return false; - } - - /** - * In case it's a bundle product, - * return all the products it contains. - * Empty array by default. - * - * @return array Product slugs - */ - public static function get_supported_products() { - return array(); - } - - /** - * Determine if the product is owned or not - * An owned product is defined as a product that is any of the following - * - Active - * - Has historically been active - * - The user has a plan that includes the product - * - The user has the standalone plugin for the product installed - * - * @return boolean - */ - public static function is_owned() { - $historically_active_modules = Jetpack_Options::get_option( 'historically_active_modules', array() ); - $standalone_info = static::get_standalone_info(); - if ( ( static::is_active() && Jetpack_Options::get_option( 'id' ) ) || - $standalone_info['is_standalone_installed'] || - in_array( static::$slug, $historically_active_modules, true ) || - static::has_any_plan_for_product() - ) { - return true; - } - - return false; - } - - /** - * Undocumented function - * - * @return string - */ - public static function get_status() { - if ( ! static::is_plugin_installed() ) { - $status = Products::STATUS_PLUGIN_ABSENT; - if ( static::has_paid_plan_for_product() ) { - $status = Products::STATUS_PLUGIN_ABSENT_WITH_PLAN; - } - } elseif ( static::is_active() ) { - $status = Products::STATUS_ACTIVE; - // We only consider missing site & user connection an error when the Product is active. - if ( static::$requires_site_connection && ! ( new Connection_Manager() )->is_connected() ) { - // Site has never been connected before - if ( ! Jetpack_Options::get_option( 'id' ) && ! static::is_owned() ) { - $status = Products::STATUS_NEEDS_FIRST_SITE_CONNECTION; - } else { - $status = Products::STATUS_SITE_CONNECTION_ERROR; - } - } elseif ( static::$requires_user_connection && ! ( new Connection_Manager() )->has_connected_owner() ) { - $status = Products::STATUS_USER_CONNECTION_ERROR; - } elseif ( static::has_paid_plan_for_product() ) { - $needs_attention = static::does_module_need_attention(); - if ( ! empty( $needs_attention ) && is_array( $needs_attention ) ) { - $status = Products::STATUS_NEEDS_ATTENTION__WARNING; - if ( isset( $needs_attention['type'] ) && 'error' === $needs_attention['type'] ) { - $status = Products::STATUS_NEEDS_ATTENTION__ERROR; - } - } - if ( static::is_paid_plan_expired() ) { - $status = Products::STATUS_EXPIRED; - } elseif ( static::is_paid_plan_expiring() ) { - $status = Products::STATUS_EXPIRING_SOON; - } - } elseif ( static::is_upgradable() ) { - $status = Products::STATUS_CAN_UPGRADE; - } - // Check specifically for inactive modules, which will prevent a product from being active - } elseif ( static::$module_name && ! static::is_module_active() ) { - $status = Products::STATUS_MODULE_DISABLED; - // If there is not a plan associated with the disabled module, encourage a plan first - // Getting a plan set up should help resolve any connection issues - // However if the standalone plugin for this product is active, then we will defer to showing errors that prevent the module from being active - // This is because if a standalone plugin is installed, we expect the product to not show as "inactive" on My Jetpack - if ( static::$requires_plan || ( ! static::has_any_plan_for_product() && static::$has_standalone_plugin && ! self::is_plugin_active() ) ) { - $status = static::is_owned() && static::$has_free_offering && ! static::$requires_plan ? Products::STATUS_NEEDS_ACTIVATION : Products::STATUS_NEEDS_PLAN; - } elseif ( static::$requires_site_connection && ! ( new Connection_Manager() )->is_connected() ) { - // Site has never been connected before and product is not owned - if ( ! Jetpack_Options::get_option( 'id' ) && ! static::is_owned() ) { - $status = Products::STATUS_NEEDS_FIRST_SITE_CONNECTION; - } else { - $status = Products::STATUS_SITE_CONNECTION_ERROR; - } - } elseif ( static::$requires_user_connection && ! ( new Connection_Manager() )->has_connected_owner() ) { - $status = Products::STATUS_USER_CONNECTION_ERROR; - } - } elseif ( ! static::has_any_plan_for_product() ) { - $status = static::is_owned() && static::$has_free_offering && ! static::$requires_plan ? Products::STATUS_NEEDS_ACTIVATION : Products::STATUS_NEEDS_PLAN; - } else { - $status = Products::STATUS_INACTIVE; - } - return $status; - } - - /** - * Checks whether the Product is active - * - * @return boolean - */ - public static function is_active() { - return static::is_plugin_active() && ( static::has_any_plan_for_product() || ( ! static::$requires_plan && static::$has_free_offering ) ); - } - - /** - * Checks whether the plugin is installed - * - * @return boolean - */ - public static function is_plugin_installed() { - return (bool) static::get_installed_plugin_filename(); - } - - /** - * Checks whether the plugin is active - * - * @return boolean - */ - public static function is_plugin_active() { - return Plugins_Installer::is_plugin_active( static::get_installed_plugin_filename() ); - } - - /** - * Checks whether the Jetpack plugin is installed - * - * @return boolean - */ - public static function is_jetpack_plugin_installed() { - return (bool) static::get_installed_plugin_filename( 'jetpack' ); - } - - /** - * Checks whether the Jetpack plugin is active - * - * @return boolean - */ - public static function is_jetpack_plugin_active() { - return Plugins_Installer::is_plugin_active( static::get_installed_plugin_filename( 'jetpack' ) ); - } - - /** - * Checks whether the Jetpack module is active only if a module_name is defined - * - * @return bool - */ - public static function is_module_active() { - if ( static::$module_name ) { - return ( new Modules() )->is_active( static::$module_name ); - } - return true; - } - - /** - * Activates the plugin - * - * @return null|WP_Error Null on success, WP_Error on invalid file. - */ - public static function activate_plugin() { - return activate_plugin( static::get_installed_plugin_filename() ); - } - - /** - * Perform the top level activation routines, which is installing and activating the required plugin - * - * @return bool|WP_Error - */ - private static function do_activation() { - if ( static::is_active() ) { - return true; - } - - // Default to installing the standalone plugin for the product - if ( ! self::is_plugin_installed() ) { - $installed = Plugins_Installer::install_plugin( static::get_plugin_slug() ); - if ( is_wp_error( $installed ) ) { - return $installed; - } - } - - if ( ! current_user_can( 'activate_plugins' ) ) { - return new WP_Error( 'not_allowed', __( 'You are not allowed to activate plugins on this site.', 'jetpack-my-jetpack' ) ); - } - - $result = static::activate_plugin(); - if ( is_wp_error( $result ) ) { - return $result; - } - - return true; - } - - /** - * Activates the product by installing and activating its plugin - * - * @return boolean|WP_Error - */ - final public static function activate() { - - $result = self::do_activation(); - - $result = static::do_product_specific_activation( $result ); - - $product_slug = static::$slug; - - /** - * Fires after My Jetpack activates a product and filters the result - * Use this filter to run additional routines for a product activation on stand-alone plugins - * - * @param bool|WP_Error $result The result of the previous steps of activation. - */ - $result = apply_filters( "my_jetpack_{$product_slug}_activation", $result ); - - return $result; - } - - /** - * Override this method to perform product specific activation routines. - * - * @param bool|WP_Error $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return bool|WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - return $current_result; - } - - /** - * Deactivate the product - * - * @return boolean - */ - public static function deactivate() { - deactivate_plugins( static::get_installed_plugin_filename() ); - return true; - } - - /** - * Returns filtered Jetpack plugin actions links. - * - * @param array $actions - Jetpack plugin action links. - * @return array Filtered Jetpack plugin actions links. - */ - public static function get_plugin_actions_links( $actions ) { - // My Jetpack action link. - $my_jetpack_home_link = array( - 'jetpack-home' => sprintf( - '%2$s', - admin_url( 'admin.php?page=my-jetpack' ), - __( 'My Jetpack', 'jetpack-my-jetpack' ), - __( 'My Jetpack dashboard', 'jetpack-my-jetpack' ) - ), - ); - - // Otherwise, add it to the beginning of the array. - return array_merge( $my_jetpack_home_link, $actions ); - } - - /** - * Filter the action links for the plugins specified. - * - * @param string|string[] $filenames The plugin filename(s) to filter the action links for. - */ - private static function filter_action_links( $filenames ) { - foreach ( $filenames as $filename ) { - $hook = 'plugin_action_links_' . $filename; - $callback = array( static::class, 'get_plugin_actions_links' ); - if ( ! has_filter( $hook, $callback ) ) { - add_filter( $hook, $callback, 20, 2 ); - } - } - } - - /** - * Extend the plugin action links. - */ - public static function extend_plugin_action_links() { - $filenames = static::get_plugin_filename(); - if ( ! is_array( $filenames ) ) { - $filenames = array( $filenames ); - } - - self::filter_action_links( $filenames ); - } - - /** - * Extend the Jetpack plugin action links. - */ - public static function extend_core_plugin_action_links() { - $filenames = self::JETPACK_PLUGIN_FILENAME; - - self::filter_action_links( $filenames ); - } - - /** - * Install and activate the standalone plugin in the case it's missing. - * - * @return boolean|WP_Error - */ - public static function install_and_activate_standalone() { - /** - * Check for the presence of the standalone plugin, ignoring Jetpack presence. - * - * If the standalone plugin is not installed and the user can install plugins, proceed with the installation. - */ - if ( ! static::is_plugin_installed() ) { - /** - * Check for permissions - */ - if ( ! current_user_can( 'install_plugins' ) ) { - return new WP_Error( 'not_allowed', __( 'You are not allowed to install plugins on this site.', 'jetpack-my-jetpack' ) ); - } - - /** - * Install the plugin - */ - $installed = Plugins_Installer::install_plugin( static::get_plugin_slug() ); - if ( is_wp_error( $installed ) ) { - return $installed; - } - } - - /** - * Activate the installed plugin - */ - $result = static::activate_plugin(); - - if ( is_wp_error( $result ) ) { - return $result; - } - - return true; - } - - /** - * Determines whether the module/plugin/product needs the users attention. - * Typically due to some sort of error where user troubleshooting is needed. - * - * @return boolean - */ - public static function does_module_need_attention() { - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php deleted file mode 100644 index e34b115f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php +++ /dev/null @@ -1,443 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_site_protect_data', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Checks if the user has the correct permissions - */ - public static function permissions_callback() { - return current_user_can( 'edit_posts' ); - } - - /** - * Get the product name - * - * @return string - */ - public static function get_name() { - return 'Protect'; - } - - /** - * Get the product title - * - * @return string - */ - public static function get_title() { - return 'Jetpack Protect'; - } - - /** - * Get the internationalized product description - * - * @return string - */ - public static function get_description() { - return __( 'Guard against malware and bad actors 24/7', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized product long description - * - * @return string - */ - public static function get_long_description() { - return __( 'Protect your site from bad actors and malware 24/7. Clean up security vulnerabilities with one click.', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized features list - * - * @return array Protect features list - */ - public static function get_features() { - return array( - __( 'Over 20,000 listed vulnerabilities', 'jetpack-my-jetpack' ), - __( 'Daily automatic scans', 'jetpack-my-jetpack' ), - __( 'Check plugin and theme version status', 'jetpack-my-jetpack' ), - __( 'Easy to navigate and use', 'jetpack-my-jetpack' ), - ); - } - - /** - * Get the product's available tiers - * - * @return string[] Slugs of the available tiers - */ - public static function get_tiers() { - return array( - self::UPGRADED_TIER_SLUG, - self::FREE_TIER_SLUG, - ); - } - - /** - * Get the internationalized comparison of free vs upgraded features - * - * @return array[] Protect features comparison - */ - public static function get_features_by_tier() { - return array( - array( - 'name' => __( 'Scan for threats and vulnerabilities', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'included' => true, - 'description' => __( 'Check items against database', 'jetpack-my-jetpack' ), - ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => __( 'Line by line malware scanning', 'jetpack-my-jetpack' ), - ), - ), - ), - array( - 'name' => __( 'Daily automated scans', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => __( 'Plus on-demand manual scans', 'jetpack-my-jetpack' ), - ), - ), - ), - array( - 'name' => __( 'Web Application Firewall', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'included' => false, - 'description' => __( 'Manual rules only', 'jetpack-my-jetpack' ), - ), - self::UPGRADED_TIER_SLUG => array( - 'included' => true, - 'description' => __( 'Automatic protection and rule updates', 'jetpack-my-jetpack' ), - ), - ), - ), - array( - 'name' => __( 'Brute force protection', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => true ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Access to scan on Cloud', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'One-click auto fixes', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Notifications', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - array( - 'name' => __( 'Severity labels', 'jetpack-my-jetpack' ), - 'tiers' => array( - self::FREE_TIER_SLUG => array( 'included' => false ), - self::UPGRADED_TIER_SLUG => array( 'included' => true ), - ), - ), - ); - } - - /** - * Get the product pricing details - * - * @return array Pricing details - */ - public static function get_pricing_for_ui() { - return array( - 'tiers' => array( - self::FREE_TIER_SLUG => array( - 'available' => true, - 'is_free' => true, - ), - self::UPGRADED_TIER_SLUG => array_merge( - array( - 'available' => true, - 'wpcom_product_slug' => self::UPGRADED_TIER_PRODUCT_SLUG, - ), - Wpcom_Products::get_product_pricing( self::UPGRADED_TIER_PRODUCT_SLUG ) - ), - ), - ); - } - - /** - * Determines whether the module/plugin/product needs the users attention. - * Typically due to some sort of error where user troubleshooting is needed. - * - * @return boolean|array - */ - public static function does_module_need_attention() { - $protect_threat_status = false; - $scan_data = Protect_Status::get_status(); - - // Check if there are scan threats. - $protect_data = $scan_data; - if ( is_wp_error( $protect_data ) ) { - return $protect_threat_status; // false - } - $critical_threat_count = false; - if ( ! empty( $protect_data->threats ) ) { - $critical_threat_count = array_reduce( - $protect_data->threats, - function ( $accum, $threat ) { - return $threat->severity >= 5 ? ++$accum : $accum; - }, - 0 - ); - - $protect_threat_status = array( - 'type' => $critical_threat_count ? 'error' : 'warning', - 'data' => array( - 'threat_count' => count( $protect_data->threats ), - 'critical_threat_count' => $critical_threat_count, - 'fixable_threat_ids' => $protect_data->fixable_threat_ids, - ), - ); - } - - return $protect_threat_status; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_scan', - 'jetpack_scan_monthly', - 'jetpack_scan_bi_yearly', - ); - } - - /** - * Checks whether the product can be upgraded - i.e. this shows the /#add-protect interstitial - * - * @return boolean - */ - public static function is_upgradable() { - return ! self::has_paid_plan_for_product(); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout for each product feature - * - * @return ?array - */ - public static function get_post_checkout_urls_by_feature() { - return array( - self::SCAN_FEATURE_SLUG => self::get_post_checkout_url(), - self::FIREWALL_FEATURE_SLUG => admin_url( 'admin.php?page=jetpack-protect#/firewall' ), - ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - // check standalone first - if ( static::is_standalone_plugin_active() ) { - return admin_url( 'admin.php?page=jetpack-protect' ); - // otherwise, check for the main Jetpack plugin - } elseif ( static::is_jetpack_plugin_active() ) { - return Redirect::get_url( 'my-jetpack-manage-scan' ); - } - } - - /** - * Get the URL where the user manages the product for each product feature - * - * @return ?array - */ - public static function get_manage_urls_by_feature() { - return array( - self::SCAN_FEATURE_SLUG => self::get_manage_url(), - self::FIREWALL_FEATURE_SLUG => admin_url( 'admin.php?page=jetpack-protect#/firewall' ), - ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'security', 'complete' ); - } - - /** - * Return site Jetpack Protect data for the REST API. - * - * @return WP_Rest_Response|WP_Error - */ - public static function get_site_protect_data() { - $scan_data = Protect_Status::get_status(); - - $waf_config = array(); - $waf_supported = false; - $is_waf_enabled = false; - - if ( class_exists( 'Automattic\Jetpack\Waf\Waf_Runner' ) ) { - // @phan-suppress-next-line PhanUndeclaredClassMethod - $waf_config = Waf_Runner::get_config(); - // @phan-suppress-next-line PhanUndeclaredClassMethod - $is_waf_enabled = Waf_Runner::is_enabled(); - // @phan-suppress-next-line PhanUndeclaredClassMethod - $waf_supported = Waf_Runner::is_supported_environment(); - } - - return rest_ensure_response( - array( - 'scanData' => $scan_data, - 'wafConfig' => array_merge( - $waf_config, - array( - 'waf_supported' => $waf_supported, - 'waf_enabled' => $is_waf_enabled, - ), - array( 'blocked_logins' => (int) get_site_option( 'jetpack_protect_blocked_attempts', 0 ) ) - ), - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-related-posts.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-related-posts.php deleted file mode 100644 index 2f1818bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-related-posts.php +++ /dev/null @@ -1,186 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * Checks whether the Product is active. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active(); - } - - /** - * Checks whether the plugin is installed - * - * @return boolean - */ - public static function is_plugin_installed() { - return static::is_jetpack_plugin_installed(); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack#/traffic?term=related%20posts' ); - } - - /** - * Activates the Jetpack plugin - * - * @return null|WP_Error Null on success, WP_Error on invalid file. - */ - public static function activate_plugin(): ?WP_Error { - $plugin_filename = static::get_installed_plugin_filename( self::JETPACK_PLUGIN_SLUG ); - - if ( $plugin_filename ) { - return activate_plugin( $plugin_filename ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php deleted file mode 100644 index 723efa6b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php +++ /dev/null @@ -1,217 +0,0 @@ - true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_scan'; - } - - /** - * Checks whether the Product is active - * - * Scan is not actually a module. Activation takes place on WPCOM. So lets consider it active if jetpack is active and has the plan. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active(); - } - - /** - * Activates the product by installing and activating its plugin - * - * @param bool|WP_Error $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return boolean|\WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - - $product_activation = parent::do_product_specific_activation( $current_result ); - - if ( is_wp_error( $product_activation ) && 'module_activation_failed' === $product_activation->get_error_code() ) { - // Scan is not a module. There's nothing in the plugin to be activated, so it's ok to fail to activate the module. - $product_activation = true; - } - - return $product_activation; - } - - /** - * Checks whether the Jetpack module is active - * - * Scan is not a module. Nothing needs to be active. Let's always consider it active. - * - * @return bool - */ - public static function is_module_active() { - return true; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_scan', - 'jetpack_scan_monthly', - 'jetpack_scan_bi_yearly', - ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'security', 'complete' ); - } - - /** - * Get the URL the user is taken after activating the product - * - * @return ?string - */ - public static function get_post_activation_url() { - return ''; // stay in My Jetpack page. - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return Redirect::get_url( 'my-jetpack-manage-scan' ); - } - - /** - * Get the URL where the user should be redirected after checkout - */ - public static function get_post_checkout_url() { - if ( static::is_jetpack_plugin_active() ) { - return 'admin.php?page=jetpack#/recommendations'; - } - - // If Jetpack is not active, it means that the user has another standalone plugin active - // and it follows the `Protect` plugin flow instead of `Scan` so for now it would be safe - // to return null and let the user go back to the My Jetpack page. - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search-stats.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search-stats.php deleted file mode 100644 index a6ea5436..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search-stats.php +++ /dev/null @@ -1,192 +0,0 @@ - true, - 'exclude_from_search' => false, - ) - ); - $indexable_status_array = get_post_stati( - array( - 'public' => true, - 'exclude_from_search' => false, - ) - ); - $raw_posts_counts = static::get_raw_post_type_breakdown(); - if ( ! $raw_posts_counts || is_wp_error( $raw_posts_counts ) ) { - return array(); - } - $posts_counts = static::get_post_type_breakdown_with( $raw_posts_counts, $indexable_post_types, $indexable_status_array ); - - return $posts_counts; - } - - /** - * Calculate breakdown of post types with passed in indexable post types and statuses. - * The function is going to be used from WPCOM as well for consistency. - * - * @param array $raw_posts_counts Array of post types with counts as value. - * @param array $indexable_post_types Array of indexable post types. - * @param array $indexable_status_array Array of indexable post statuses. - */ - public static function get_post_type_breakdown_with( $raw_posts_counts, $indexable_post_types, $indexable_status_array ) { - $posts_counts = array(); - foreach ( $raw_posts_counts as $row ) { - // ignore if status is not public. - if ( ! in_array( $row['post_status'], $indexable_status_array, true ) ) { - continue; - } - // ignore if post type is in excluded post types. - if ( in_array( $row['post_type'], self::EXCLUDED_POST_TYPES, true ) ) { - continue; - } - // ignore if post type is not public and is not explicitly included. - if ( ! in_array( $row['post_type'], $indexable_post_types, true ) && - ! in_array( $row['post_type'], self::DO_NOT_EXCLUDE_POST_TYPES, true ) - ) { - continue; - } - // add up post type counts of potentially multiple post_status. - if ( ! isset( $posts_counts[ $row['post_type'] ] ) ) { - $posts_counts[ $row['post_type'] ] = 0; - } - $posts_counts[ $row['post_type'] ] += intval( $row['num_posts'] ); - } - - arsort( $posts_counts, SORT_NUMERIC ); - return $posts_counts; - } - - /** - * Get raw post type breakdown from the database or a remote request if posts count is high. - */ - protected static function get_raw_post_type_breakdown() { - global $wpdb; - - $results = wp_cache_get( self::POST_TYPE_BREAKDOWN_CACHE_KEY, self::CACHE_GROUP ); - if ( false !== $results ) { - return $results; - } - - $total_posts_count = wp_cache_get( self::TOTAL_POSTS_COUNT_CACHE_KEY, self::CACHE_GROUP ); - if ( false === $total_posts_count ) { - // phpcs:ignore WordPress.DB.DirectDatabaseQuery */ - $total_posts_counts = $wpdb->get_var( "SELECT COUNT(*) FROM {$wpdb->posts}" ); - wp_cache_set( self::TOTAL_POSTS_COUNT_CACHE_KEY, $total_posts_counts, self::CACHE_GROUP, self::CACHE_EXPIRY ); - } - - // Get post type breakdown from a remote request if the post count is high - if ( $total_posts_count > self::POST_COUNT_QUERY_LIMIT ) { - $search_stats = new Search_Stats(); - $search_stats->queue_post_count_query_from_wpcom(); - $wpcom_stats = json_decode( wp_remote_retrieve_body( $search_stats->get_stats_from_wpcom() ), true ); - if ( ! empty( $wpcom_stats['raw_post_type_breakdown'] ) ) { - $results = $wpcom_stats['raw_post_type_breakdown']; - wp_cache_set( self::POST_TYPE_BREAKDOWN_CACHE_KEY, $results, self::CACHE_GROUP, self::CACHE_EXPIRY ); - return $results; - } else { - return array(); - } - } - - $query = "SELECT post_type, post_status, COUNT( * ) AS num_posts - FROM {$wpdb->posts} - WHERE post_password = '' - GROUP BY post_type, post_status"; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared, WordPress.DB.DirectDatabaseQuery.DirectQuery - $results = $wpdb->get_results( $query, ARRAY_A ); - wp_cache_set( self::POST_TYPE_BREAKDOWN_CACHE_KEY, $results, self::CACHE_GROUP, self::CACHE_EXPIRY ); - return $results; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php deleted file mode 100644 index 105c0491..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php +++ /dev/null @@ -1,374 +0,0 @@ - true, - 'trial_available' => static::has_trial_support(), - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - 'wpcom_free_product_slug' => static::get_wpcom_free_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - - $record_count = intval( Search_Stats::estimate_count() ); - $search_pricing = static::get_pricing_from_wpcom( $record_count ); - - if ( is_wp_error( $search_pricing ) ) { - return $pricing; - } - - $pricing['estimated_record_count'] = $record_count; - - return array_merge( $pricing, $search_pricing ); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_search'; - } - - /** - * Get the WPCOM free product slug - * - * @return ?string - */ - public static function get_wpcom_free_product_slug() { - return 'jetpack_search_free'; - } - - /** - * Returns true if the new_pricing_202208 is set to not empty in URL for testing purpose, or it's active. - */ - public static function is_new_pricing_202208() { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized, WordPress.Security.ValidatedSanitizedInput.MissingUnslash - if ( isset( $_GET['new_pricing_202208'] ) && $_GET['new_pricing_202208'] ) { - return true; - } - - $record_count = intval( Search_Stats::estimate_count() ); - $search_pricing = static::get_pricing_from_wpcom( $record_count ); - if ( is_wp_error( $search_pricing ) ) { - return false; - } - - return '202208' === $search_pricing['pricing_version']; - } - - /** - * Override status to `needs_activation` when status is `needs_plan`. - */ - public static function get_status() { - $status = parent::get_status(); - return $status; - } - - /** - * Use centralized Search pricing API. - * - * The function is also used by the search package, as a result it could be called before site connection - i.e. blog token might not be available. - * - * @param int $record_count Record count to estimate pricing. - * - * @return array|WP_Error - */ - public static function get_pricing_from_wpcom( $record_count ) { - static $pricings = array(); - $connection = new Connection_Manager(); - $blog_id = \Jetpack_Options::get_option( 'id' ); - - if ( isset( $pricings[ $record_count ] ) ) { - return $pricings[ $record_count ]; - } - - // If the site is connected, request pricing with the blog token - if ( $blog_id ) { - $endpoint = sprintf( '/jetpack-search/pricing?record_count=%1$d&locale=%2$s', $record_count, get_user_locale() ); - - // If available in the user data, set the user's currency as one of the params - if ( $connection->is_user_connected() ) { - $user_details = $connection->get_connected_user_data(); - if ( ! empty( $user_details['user_currency'] ) && $user_details['user_currency'] !== 'USD' ) { - $endpoint .= sprintf( '¤cy=%s', $user_details['user_currency'] ); - } - } - - $response = Client::wpcom_json_api_request_as_blog( - $endpoint, - '2', - array( 'timeout' => 5 ), - null, - 'wpcom' - ); - } else { - $response = wp_remote_get( - sprintf( Constants::get_constant( 'JETPACK__WPCOM_JSON_API_BASE' ) . '/wpcom/v2/jetpack-search/pricing?record_count=%1$d&locale=%2$s', $record_count, get_user_locale() ), - array( 'timeout' => 5 ) - ); - } - - if ( is_wp_error( $response ) || 200 !== wp_remote_retrieve_response_code( $response ) ) { - return new WP_Error( 'search_pricing_fetch_failed' ); - } - - $body = wp_remote_retrieve_body( $response ); - $pricings[ $record_count ] = json_decode( $body, true ); - return $pricings[ $record_count ]; - } - - /** - * Checks whether the product supports trial or not - * - * Returns true if it supports. Return false otherwise. - * - * Free products will always return false. - * - * @return boolean - */ - public static function has_trial_support() { - return static::is_new_pricing_202208(); - } - - /** - * Get the product-slugs of the paid plans for this product (not including bundles) - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_search', - 'jetpack_search_monthly', - 'jetpack_search_bi_yearly', - ); - } - - /** - * Checks if the site purchases contain a free search plan - * - * @return bool - */ - public static function has_free_plan_for_product() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( str_contains( $purchase->product_slug, 'jetpack_search_free' ) ) { - return true; - } - } - } - return false; - } - - /** - * Activates the product. Try to enable instant search after the Search module was enabled. - * - * @param bool|WP_Error $product_activation Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return bool|WP_Error - */ - public static function do_product_specific_activation( $product_activation ) { - $product_activation = parent::do_product_specific_activation( $product_activation ); - if ( is_wp_error( $product_activation ) ) { - return $product_activation; - } - - if ( class_exists( 'Automattic\Jetpack\Search\Module_Control' ) ) { - ( new Search_Module_Control() )->enable_instant_search(); - } - - // we don't want to change the success of the activation if we fail to activate instant search. That's not mandatory. - return $product_activation; - } - - /** - * Get the URL the user is taken after activating the product - * - * @return ?string - */ - public static function get_post_activation_url() { - return ''; // stay in My Jetpack page or continue the purchase flow if needed. - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack-search' ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'complete' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php deleted file mode 100644 index d226f64a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php +++ /dev/null @@ -1,229 +0,0 @@ - true, - 'wpcom_product_slug' => $product_slug, - ), - Wpcom_Products::get_product_pricing( $product_slug ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_security_t1_yearly'; - } - - /** - * Checks whether the Jetpack module is active - * - * This is a bundle and not a product. We should not use this information for anything - * - * @return bool - */ - public static function is_module_active() { - return false; - } - - /** - * Activates the product by installing and activating its plugin - * - * @param bool|WP_Error $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return boolean|\WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - - $product_activation = parent::do_product_specific_activation( $current_result ); - - if ( is_wp_error( $product_activation ) && 'module_activation_failed' === $product_activation->get_error_code() ) { - // A bundle is not a module. There's nothing in the plugin to be activated, so it's ok to fail to activate the module. - $product_activation = true; - } - - // At this point, Jetpack plugin is installed. Let's activate each individual product. - $activation = Anti_Spam::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Backup::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Scan::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - return $activation; - } - - /** - * Checks whether the Product is active - * - * Security is a bundle and not a module. Activation takes place on WPCOM. So lets consider it active if jetpack is active and has the plan. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active() && static::has_required_plan(); - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_security_t1_yearly', - 'jetpack_security_t1_monthly', - 'jetpack_security_t1_bi_yearly', - 'jetpack_security_t2_yearly', - 'jetpack_security_t2_monthly', - ); - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_required_plan() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( - str_starts_with( $purchase->product_slug, 'jetpack_security' ) || - str_starts_with( $purchase->product_slug, 'jetpack_complete' ) - ) { - return true; - } - } - } - return false; - } - - /** - * Checks whether product is a bundle. - * - * @return boolean True - */ - public static function is_bundle_product() { - return true; - } - - /** - * Return all the products it contains. - * - * @return array Product slugs - */ - public static function get_supported_products() { - return array( 'backup', 'scan', 'anti-spam' ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-site-accelerator.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-site-accelerator.php deleted file mode 100644 index 9e711a7f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-site-accelerator.php +++ /dev/null @@ -1,186 +0,0 @@ - true, - 'is_free' => true, - ); - } - - /** - * Checks whether the Product is active. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active(); - } - - /** - * Checks whether the plugin is installed - * - * @return boolean - */ - public static function is_plugin_installed() { - return static::is_jetpack_plugin_installed(); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack#/settings?term=site%20accelerator' ); - } - - /** - * Activates the Jetpack plugin - * - * @return null|WP_Error Null on success, WP_Error on invalid file. - */ - public static function activate_plugin(): ?WP_Error { - $plugin_filename = static::get_installed_plugin_filename( self::JETPACK_PLUGIN_SLUG ); - - if ( $plugin_filename ) { - return activate_plugin( $plugin_filename ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php deleted file mode 100644 index d8157500..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php +++ /dev/null @@ -1,235 +0,0 @@ - true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_social_v1_yearly'; - } - - /** - * Gets the 'status' of the Social product - * - * @return string - */ - public static function get_status() { - $status = parent::get_status(); - if ( Products::STATUS_NEEDS_PLAN === $status ) { - // If the status says that the site needs a plan, - // My Jetpack shows "Learn more" CTA, - // We want to instead show the "Activate" CTA. - $status = Products::STATUS_NEEDS_ACTIVATION; - } - return $status; - } - - /** - * Get the product-slugs of the paid plans for this product (not including bundles) - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_social_v1_yearly', - 'jetpack_social_v1_monthly', - 'jetpack_social_v1_bi_yearly', - 'jetpack_social_basic_yearly', - 'jetpack_social_monthly', - 'jetpack_social_basic_monthly', - 'jetpack_social_basic_bi_yearly', - 'jetpack_social_advanced_yearly', - 'jetpack_social_advanced_monthly', - 'jetpack_social_advanced_bi_yearly', - ); - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_paid_plan_for_product() { - if ( parent::has_paid_plan_for_product() ) { - return true; - } - - // For atomic sites, do a feature check to see if the republicize feature is available - // This feature is available by default on all Jetpack sites - if ( ( new Host() )->is_woa_site() && static::does_site_have_feature( 'republicize' ) ) { - return true; - } - - return false; - } - - /** - * Get the URL where the user manages the product. - * - * @return string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=jetpack-social' ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'growth', 'complete' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-starter.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-starter.php deleted file mode 100644 index be9852c9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-starter.php +++ /dev/null @@ -1,216 +0,0 @@ - true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_starter_yearly'; - } - - /** - * Checks whether the Jetpack module is active - * - * This is a bundle and not a product. We should not use this information for anything - * - * @return bool - */ - public static function is_module_active() { - return false; - } - - /** - * Activates the product by installing and activating its plugin - * - * @param bool|WP_Error $current_result Is the result of the top level activation actions. You probably won't do anything if it is an WP_Error. - * @return boolean|\WP_Error - */ - public static function do_product_specific_activation( $current_result ) { - - $product_activation = parent::do_product_specific_activation( $current_result ); - - if ( is_wp_error( $product_activation ) && 'module_activation_failed' === $product_activation->get_error_code() ) { - // A bundle is not a module. There's nothing in the plugin to be activated, so it's ok to fail to activate the module. - $product_activation = true; - } - - // At this point, Jetpack plugin is installed. Let's activate each individual product. - $activation = Anti_Spam::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - $activation = Backup::activate(); - if ( is_wp_error( $activation ) ) { - return $activation; - } - - return $activation; - } - - /** - * Checks whether the Product is active - * - * Jetpack Starter is a bundle and not a module. Activation takes place on WPCOM. So lets consider it active if jetpack is active and has the plan. - * - * @return boolean - */ - public static function is_active() { - return static::is_jetpack_plugin_active() && static::has_required_plan(); - } - - /** - * Checks whether the current plan (or purchases) of the site already supports the product - * - * @return boolean - */ - public static function has_required_plan() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( is_wp_error( $purchases_data ) ) { - return false; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( str_starts_with( $purchase->product_slug, 'jetpack_starter' ) ) { - return true; - } - } - } - return false; - } - - /** - * Get the product-slugs of the paid plans for this product. - * (Do not include bundle plans, unless it's a bundle plan itself). - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_starter_yearly', - 'jetpack_starter_monthly', - ); - } - - /** - * Checks whether product is a bundle. - * - * @return boolean True - */ - public static function is_bundle_product() { - return true; - } - - /** - * Return all the products it contains. - * - * @return Array Product slugs - */ - public static function get_supported_products() { - return array( 'backup', 'anti-spam' ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return ''; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-stats.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-stats.php deleted file mode 100644 index e838ecc6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-stats.php +++ /dev/null @@ -1,334 +0,0 @@ - true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_stats_yearly'; - } - - /** - * Get the WPCOM Pay Whatever You Want product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_pwyw_product_slug() { - return 'jetpack_stats_pwyw_yearly'; - } - - /** - * Get the WPCOM free product slug - * - * @return ?string - */ - public static function get_wpcom_free_product_slug() { - return 'jetpack_stats_free_yearly'; - } - - /** - * Gets the 'status' of the Stats product - * - * @return string - */ - public static function get_status() { - $status = parent::get_status(); - if ( Products::STATUS_MODULE_DISABLED === $status && ! Initializer::is_registered() ) { - // If the site has never been connected before, show the "Learn more" CTA, - // that points to the add Stats product interstitial. - $status = Products::STATUS_NEEDS_FIRST_SITE_CONNECTION; - } - return $status; - } - /** - * Checks whether the product can be upgraded to a different product. - * Stats Commercial plan (highest tier) & Jetpack Complete are not upgradable. - * Also we don't push PWYW users to upgrade. - * - * @return boolean - */ - public static function is_upgradable() { - // For now, atomic sites with stats are not in a position to upgrade - if ( ( new Host() )->is_woa_site() ) { - return false; - } - - $purchases_data = Wpcom_Products::get_site_current_purchases(); - if ( ! is_wp_error( $purchases_data ) && is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - // Jetpack complete includes Stats commercial & cannot be upgraded - if ( - str_starts_with( $purchase->product_slug, 'jetpack_complete' ) || - str_starts_with( $purchase->product_slug, 'jetpack_growth' ) - ) { - return false; - } elseif ( - // Stats commercial purchased with highest tier cannot be upgraded. - in_array( - $purchase->product_slug, - array( 'jetpack_stats_yearly', 'jetpack_stats_monthly', 'jetpack_stats_bi_yearly' ), - true - ) && $purchase->current_price_tier_slug === 'more_than_1m_views' - ) { - return false; - } elseif ( - // If user already has Stats PWYW, we won't push them to upgrade. - $purchase->product_slug === 'jetpack_stats_pwyw_yearly' - ) { - return false; - } - } - } - return true; - } - - /** - * Get the product-slugs of the paid plans for this product (not including bundles) - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_stats_yearly', - 'jetpack_stats_monthly', - 'jetpack_stats_bi_yearly', - 'jetpack_stats_pwyw_yearly', - ); - } - - /** - * Returns a productType parameter for an upgrade URL, determining whether - * to show the PWYW upgrade interstitial or commercial upgrade interstitial. - * - * @return string - */ - public static function get_url_product_type() { - $purchases_data = Wpcom_Products::get_site_current_purchases(); - $is_commercial_site = Initializer::is_commercial_site(); - if ( is_wp_error( $purchases_data ) ) { - return $is_commercial_site ? '&productType=commercial' : ''; - } - if ( $is_commercial_site ) { - return '&productType=commercial'; - } - if ( is_array( $purchases_data ) && ! empty( $purchases_data ) ) { - foreach ( $purchases_data as $purchase ) { - if ( - str_starts_with( $purchase->product_slug, static::get_wpcom_free_product_slug() ) - ) { - return '&productType=personal'; - } elseif ( - in_array( - $purchase->product_slug, - array( 'jetpack_stats_yearly', 'jetpack_stats_monthly', 'jetpack_stats_bi_yearly' ), - true - ) && - ! empty( $purchase->current_price_tier_slug ) - ) { - return '&productType=commercial'; - } - } - } - return ''; - } - - /** - * Checks whether the product supports trial or not. - * Since Jetpack Stats has been widely available as a free product in the past, it "supports" a trial. - * - * @return boolean - */ - public static function has_trial_support() { - return true; - } - - /** - * Get the WordPress.com URL for purchasing Jetpack Stats for the current site. - * - * @return ?string - */ - public static function get_purchase_url() { - $status = static::get_status(); - if ( $status === Products::STATUS_NEEDS_FIRST_SITE_CONNECTION ) { - return null; - } - // The returning URL could be customized by changing the `redirect_uri` param with relative path. - return sprintf( - '%s#!/stats/purchase/%d?from=jetpack-my-jetpack%s&redirect_uri=%s', - admin_url( 'admin.php?page=stats' ), - Jetpack_Options::get_option( 'id' ), - static::get_url_product_type(), - rawurlencode( 'admin.php?page=stats' ) - ); - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - return admin_url( 'admin.php?page=stats' ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'growth', 'complete' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php deleted file mode 100644 index 24f02273..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php +++ /dev/null @@ -1,315 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_site_videopress_data', - 'permission_callback' => __CLASS__ . '::permissions_callback', - ) - ); - } - - /** - * Checks if the user has the correct permissions - */ - public static function permissions_callback() { - return current_user_can( 'edit_posts' ); - } - - /** - * Get the product name - * - * @return string - */ - public static function get_name() { - return 'VideoPress'; - } - - /** - * Get the product title - * - * @return string - */ - public static function get_title() { - return 'Jetpack VideoPress'; - } - - /** - * Get the internationalized product description - * - * @return string - */ - public static function get_description() { - return __( 'Stunning-quality, ad-free video in the WordPress Editor', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized product long description - * - * @return string - */ - public static function get_long_description() { - return __( 'Stunning-quality, ad-free video in the WordPress Editor', 'jetpack-my-jetpack' ); - } - - /** - * Get the internationalized features list - * - * @return array Boost features list - */ - public static function get_features() { - return array( - _x( '1TB of storage', 'VideoPress Product Feature', 'jetpack-my-jetpack' ), - _x( 'Built into WordPress editor', 'VideoPress Product Feature', 'jetpack-my-jetpack' ), - _x( 'Ad-free and customizable player', 'VideoPress Product Feature', 'jetpack-my-jetpack' ), - _x( 'Unlimited users', 'VideoPress Product Feature', 'jetpack-my-jetpack' ), - ); - } - - /** - * Get the product princing details - * - * @return array Pricing details - */ - public static function get_pricing_for_ui() { - return array_merge( - array( - 'available' => true, - 'wpcom_product_slug' => static::get_wpcom_product_slug(), - ), - Wpcom_Products::get_product_pricing( static::get_wpcom_product_slug() ) - ); - } - - /** - * Get the URL the user is taken after purchasing the product through the checkout - * - * @return ?string - */ - public static function get_post_checkout_url() { - return self::get_manage_url(); - } - - /** - * Get the WPCOM product slug used to make the purchase - * - * @return ?string - */ - public static function get_wpcom_product_slug() { - return 'jetpack_videopress'; - } - - /** - * Get the URL the user is taken after activating the product - * - * @return ?string - */ - public static function get_post_activation_url() { - return ''; // stay in My Jetpack page. - } - - /** - * Get the URL where the user manages the product - * - * @return ?string - */ - public static function get_manage_url() { - if ( method_exists( 'Automattic\Jetpack\VideoPress\Initializer', 'should_initialize_admin_ui' ) && \Automattic\Jetpack\VideoPress\Initializer::should_initialize_admin_ui() ) { - return \Automattic\Jetpack\VideoPress\Admin_UI::get_admin_page_url(); - } else { - return admin_url( 'admin.php?page=jetpack#/settings?term=videopress' ); - } - } - - /** - * Get the product-slugs of the paid plans for this product (not including bundles) - * - * @return array - */ - public static function get_paid_plan_product_slugs() { - return array( - 'jetpack_videopress', - 'jetpack_videopress_monthly', - 'jetpack_videopress_bi_yearly', - ); - } - - /** - * Return product bundles list - * that supports the product. - * - * @return boolean|array Products bundle list. - */ - public static function is_upgradable_by_bundle() { - return array( 'complete' ); - } - - /** - * Get stats for VideoPress - * - * @return array|WP_Error - */ - private static function get_videopress_stats() { - $video_count = array_sum( (array) wp_count_attachments( 'video' ) ); - - if ( ! class_exists( 'Automattic\Jetpack\VideoPress\Stats' ) ) { - return array( - 'videoCount' => $video_count, - ); - } - - $featured_stats = get_transient( self::VIDEOPRESS_STATS_KEY ); - - if ( $featured_stats ) { - return array( - 'featuredStats' => $featured_stats, - 'videoCount' => $video_count, - ); - } - - $stats_period = get_transient( self::VIDEOPRESS_PERIOD_KEY ); - $videopress_stats = new VideoPress_Stats(); - - // If the stats period exists, retrieve that information without checking the view count. - // If it does not, check the view count of monthly stats and determine if we want to show yearly or monthly stats. - if ( $stats_period ) { - if ( $stats_period === 'day' ) { - $featured_stats = $videopress_stats->get_featured_stats( 60, 'day' ); - } else { - $featured_stats = $videopress_stats->get_featured_stats( 2, 'year' ); - } - } else { - $featured_stats = $videopress_stats->get_featured_stats( 60, 'day' ); - - if ( - ! is_wp_error( $featured_stats ) && - $featured_stats && - ( $featured_stats['data']['views']['current'] < 500 || $featured_stats['data']['views']['previous'] < 500 ) - ) { - $featured_stats = $videopress_stats->get_featured_stats( 2, 'year' ); - } - } - - if ( is_wp_error( $featured_stats ) || ! $featured_stats ) { - return array( - 'videoCount' => $video_count, - ); - } - - set_transient( self::VIDEOPRESS_PERIOD_KEY, $featured_stats['period'], WEEK_IN_SECONDS ); - set_transient( self::VIDEOPRESS_STATS_KEY, $featured_stats, DAY_IN_SECONDS ); - - return array( - 'featuredStats' => $featured_stats, - 'videoCount' => $video_count, - ); - } - - /** - * Get VideoPress data for the REST API - * - * @return WP_REST_Response|WP_Error - */ - public static function get_site_videopress_data() { - $videopress_stats = self::get_videopress_stats(); - - return rest_ensure_response( $videopress_stats ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/CHANGELOG.md deleted file mode 100644 index 29e4c4c8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/CHANGELOG.md +++ /dev/null @@ -1,193 +0,0 @@ -# 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). - -## [0.4.7] - 2025-03-21 -### Changed -- Internal updates. - -## [0.4.6] - 2025-03-17 -### Changed -- Internal updates. - -## [0.4.5] - 2025-03-12 -### Changed -- Internal updates. - -## [0.4.4] - 2025-03-05 -### Changed -- Internal updates. - -## [0.4.3] - 2025-02-24 -### Changed -- Update dependencies. - -## [0.4.2] - 2025-02-03 -### Changed -- Internal updates. - -## [0.4.1] - 2024-11-25 -### Changed -- Updated dependencies. [#40286] - -## [0.4.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.3.3] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [0.3.2] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [0.3.1] - 2024-03-14 -### Changed -- Internal updates. - -## [0.3.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [0.2.14] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [0.2.13] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.2.12] - 2023-03-20 -### Changed -- Updated package dependencies. [#29480] - -## [0.2.11] - 2023-02-20 -### Changed -- Minor internal updates. - -## [0.2.10] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [0.2.9] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [0.2.8] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [0.2.7] - 2022-09-20 -### Changed -- Updated package dependencies. - -## [0.2.6] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [0.2.5] - 2022-06-21 -### Changed -- Renaming master to trunk. [#24661] - -## [0.2.4] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [0.2.3] - 2022-03-29 -### Changed -- Microperformance: Use === null instead of is_null - -## [0.2.2] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [0.2.1] - 2022-01-18 -### Changed -- Updated package dependencies. - -## [0.2.0] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies -- Updated package textdomain from `jetpack` to `jetpack-password-checker`. - -## [0.1.8] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [0.1.7] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [0.1.6] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [0.1.5] - 2021-10-12 -### Changed -- Updated package dependencies - -## [0.1.4] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [0.1.3] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). - -## [0.1.2] - 2021-05-25 -### Fixed -- Avoid checking in vendor directory. - -## [0.1.1] - 2021-04-27 -### Changed -- Updated package dependencies. - -## 0.1.0 - 2021-03-30 -### Added -- Initial release. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -[0.4.7]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.6...v0.4.7 -[0.4.6]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.5...v0.4.6 -[0.4.5]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.4...v0.4.5 -[0.4.4]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.3...v0.4.4 -[0.4.3]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.2...v0.4.3 -[0.4.2]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.1...v0.4.2 -[0.4.1]: https://github.com/Automattic/jetpack-password-checker/compare/v0.4.0...v0.4.1 -[0.4.0]: https://github.com/Automattic/jetpack-password-checker/compare/v0.3.3...v0.4.0 -[0.3.3]: https://github.com/Automattic/jetpack-password-checker/compare/v0.3.2...v0.3.3 -[0.3.2]: https://github.com/Automattic/jetpack-password-checker/compare/v0.3.1...v0.3.2 -[0.3.1]: https://github.com/Automattic/jetpack-password-checker/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.14...v0.3.0 -[0.2.14]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.13...v0.2.14 -[0.2.13]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.12...v0.2.13 -[0.2.12]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.11...v0.2.12 -[0.2.11]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.10...v0.2.11 -[0.2.10]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.9...v0.2.10 -[0.2.9]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.8...v0.2.9 -[0.2.8]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.7...v0.2.8 -[0.2.7]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.6...v0.2.7 -[0.2.6]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.5...v0.2.6 -[0.2.5]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.4...v0.2.5 -[0.2.4]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.3...v0.2.4 -[0.2.3]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.2...v0.2.3 -[0.2.2]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.1...v0.2.2 -[0.2.1]: https://github.com/Automattic/jetpack-password-checker/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.8...v0.2.0 -[0.1.8]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.7...v0.1.8 -[0.1.7]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.6...v0.1.7 -[0.1.6]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.5...v0.1.6 -[0.1.5]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.4...v0.1.5 -[0.1.4]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.3...v0.1.4 -[0.1.3]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.2...v0.1.3 -[0.1.2]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.1...v0.1.2 -[0.1.1]: https://github.com/Automattic/jetpack-password-checker/compare/v0.1.0...v0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/composer.json deleted file mode 100644 index cddc48bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/composer.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "name": "automattic/jetpack-password-checker", - "description": "Password Checker.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-password-checker", - "textdomain": "jetpack-password-checker", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-password-checker/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "0.4.x-dev" - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php deleted file mode 100644 index 79c369c2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php +++ /dev/null @@ -1,1313 +0,0 @@ -user_id = get_current_user_id(); - } elseif ( is_object( $user ) && isset( $user->ID ) ) { - // Existing user, using their ID. - $this->user_id = $user->ID; - } elseif ( is_object( $user ) ) { - // Newly created user, using existing data. - $this->user = $user; - $this->user_id = 'new_user'; - } else { - $this->user_id = $user; - } - - /** - * Filters the password strength enforcement settings. - * - * You can supply your own passwords that should not be used for authenticating in addition to weak and easy - * to guess strings for each user. For example, you can add passwords from known password databases to avoid - * compromised password usage. - * - * @param array $common_passwords strings that are forbidden for use as passwords. - */ - $this->common_passwords = apply_filters( 'password_checker_common_passwords', $this->common_passwords ); - - /** - * Filters the password strength enforcement settings. - * - * You can modify the minimum password length using this filter. - * - * @param int $minimum_password_length minimum password length. - */ - $this->minimum_password_length = apply_filters( 'password_checker_minimum_password_length', $this->minimum_password_length ); - - /** - * Filters the password strength enforcement settings. - * - * You can modify the minimum entropy bits requirement using this filter. - * - * @param int $minimum_entropy_bits minimum entropy bits requirement. - */ - $this->minimum_entropy_bits = apply_filters( 'password_checker_minimum_entropy_bits', $this->minimum_entropy_bits ); - } - - /** - * Run tests against a password. - * - * @param string $password the password. - * @param bool $required_only only test against required conditions, defaults to false. - * - * @return array an array containing failed and passed test results. - */ - public function test( $password, $required_only = false ) { - // Run the tests. - $results = $this->run_tests( $password, $this->get_tests(), $required_only ); - - // If we've failed on the required tests, return now. - if ( ! empty( $results['failed'] ) ) { - return array( - 'passed' => false, - 'test_results' => $results, - ); - } - - $entropy_bits = $this->calculate_entropy_bits( $password ); - - // If we have failed the entropy bits test, run the regex tests so we can suggest improvements. - if ( $entropy_bits < $this->minimum_entropy_bits ) { - $results['failed']['entropy_bits'] = $entropy_bits; - // Run the tests. - $results = array_merge( $results, $this->run_tests( $password, $this->get_tests( 'preg_match' ) ) ); - } - - return ( array( - 'passed' => empty( $results['failed'] ), - 'test_results' => $results, - ) ); - } - - /** - * Run the tests using the currently set up object values. - * - * @param string $password the password. - * @param array $tests tests to run. - * @param bool $required_only whether to run only required tests. - * - * @return array test results. - */ - public function run_tests( $password, $tests, $required_only = false ) { - $results = array( - 'passed' => array(), - 'failed' => array(), - ); - - foreach ( $tests as $test_type => $section_tests ) { - foreach ( $section_tests as $test_name => $test_data ) { - // Skip non-required tests if required_only param is set. - if ( $required_only && ! $test_data['required'] ) { - continue; - } - - $result = call_user_func_array( array( $this, 'test_' . $test_type ), array( $password, $test_data ) ); - if ( $result ) { - $results['passed'][] = array( 'test_name' => $test_name ); - } else { - $results['failed'][] = array( - 'test_name' => $test_name, - 'explanation' => $test_data['error'], - ); - - if ( isset( $test_data['fail_immediately'] ) ) { - return $results; - } - } - } - } - - return $results; - } - - /** - * Returns an array of tests that need to be run on password strings. - * - * @param array $sections only return specific sections with the passed keys, defaults to all. - * - * @return array test descriptions. - */ - public function get_tests( $sections = false ) { - // Note: these should be in order of priority. - $tests = array( - 'preg_match' => array( - 'no_backslashes' => array( - 'pattern' => '/^[^\\\\]*$/u', - 'error' => __( 'Passwords may not contain the character "\".', 'jetpack-password-checker' ), - 'required' => true, - 'fail_immediately' => true, - ), - 'minimum_length' => array( - 'pattern' => '/^.{' . $this->minimum_password_length . ',}/u', - /* translators: %d is a number of characters in the password. */ - 'error' => sprintf( __( 'Password must be at least %d characters.', 'jetpack-password-checker' ), $this->minimum_password_length ), - 'required' => true, - 'fail_immediately' => true, - ), - 'has_mixed_case' => array( - 'pattern' => '/([a-z].*?[A-Z]|[A-Z].*?[a-z])/u', - 'error' => __( 'This password is too easy to guess: you can improve it by adding additional uppercase letters, lowercase letters, or numbers.', 'jetpack-password-checker' ), - 'required' => false, - ), - 'has_digit' => array( - 'pattern' => '/\d/u', - 'error' => __( 'This password is too easy to guess: you can improve it by mixing both letters and numbers.', 'jetpack-password-checker' ), - 'required' => false, - ), - 'has_special_char' => array( - 'pattern' => '/[^a-zA-Z\d]/u', - 'error' => __( 'This password is too easy to guess: you can improve it by including special characters such as !#=?*&.', 'jetpack-password-checker' ), - 'required' => false, - ), - ), - 'compare_to_list' => array( - 'not_a_common_password' => array( - 'list_callback' => 'get_common_passwords', - 'compare_callback' => 'negative_in_array', - 'error' => __( 'This is a very common password. Choose something that will be harder for others to guess.', 'jetpack-password-checker' ), - 'required' => true, - ), - 'not_same_as_other_user_data' => array( - 'list_callback' => 'get_other_user_data', - 'compare_callback' => 'test_not_same_as_other_user_data', - 'error' => __( 'Your password is too weak: Looks like you are including easy to guess information about yourself. Try something a little more unique.', 'jetpack-password-checker' ), - 'required' => true, - ), - ), - ); - - /** - * Filters the password strength enforcement settings. - * - * You can determine the tests run and their order based on whatever criteria you wish to specify. - * - * @param array $tests tests to run. - */ - $tests = apply_filters( 'password_checker_tests', $tests ); - - if ( ! $sections ) { - return $tests; - } - - $sections = (array) $sections; - - return array_intersect_key( $tests, array_flip( $sections ) ); - } - - /** - * Provides the regular expression tester functionality. - * - * @param string $password the password. - * @param array $test_data the current test data. - * - * @return bool does the test pass? - */ - protected function test_preg_match( $password, $test_data ) { - return preg_match( $test_data['pattern'], $password ); - } - - /** - * Provides the comparison tester functionality. - * - * @param string $password the password. - * @param array $test_data the current test data. - * - * @return bool does the test pass? - */ - protected function test_compare_to_list( $password, $test_data ) { - if ( - ! is_callable( array( $this, $test_data['list_callback'] ) ) - || ! is_callable( array( $this, $test_data['compare_callback'] ) ) - ) { - return false; - } - - return call_user_func( - array( - $this, - $test_data['compare_callback'], - ), - $password, - call_user_func( array( $this, $test_data['list_callback'] ) ) - ); - } - - /** - * Getter for the common password list. - * - * @return array common passwords. - */ - protected function get_common_passwords() { - return $this->common_passwords; - } - - /** - * Returns the widely known user data that can not be used in the password to avoid - * predictable strings. - * - * @return array user data. - */ - protected function get_other_user_data() { - if ( empty( $this->user_id ) ) { - return array(); - } - - $user_data = get_userdata( $this->user_id ); - if ( ! $user_data ) { - return array(); - } - - if ( isset( $user_data->ID ) ) { - $this->add_user_strings_to_test( get_user_meta( $user_data->ID, 'first_name', true ) ); - $this->add_user_strings_to_test( get_user_meta( $user_data->ID, 'last_name', true ) ); - $this->add_user_strings_to_test( get_user_meta( $user_data->ID, 'nickname', true ) ); - } - - if ( isset( $user_data->user_nicename ) ) { - $this->add_user_strings_to_test( $user_data->user_nicename ); - } - - if ( isset( $user_data->display_name ) ) { - $this->add_user_strings_to_test( $user_data->display_name ); - } - - if ( isset( $user_data->first_name ) ) { - $this->add_user_strings_to_test( $user_data->first_name ); - } - - if ( isset( $user_data->last_name ) ) { - $this->add_user_strings_to_test( $user_data->last_name ); - } - - if ( isset( $user_data->user_email ) ) { - $email_username = substr( $user_data->user_email, 0, strpos( $user_data->user_email, '@' ) ); - $this->add_user_strings_to_test( $email_username, '.' ); - $this->add_user_strings_to_test( $user_data->user_email ); - } - - return $this->get_user_strings_to_test(); - } - - /** - * Compare the password for matches with known user data. - * - * @param string $password the password. - * @param array $strings_to_test known user data. - * - * @return bool does the test pass? - */ - protected function test_not_same_as_other_user_data( $password, $strings_to_test ) { - if ( empty( $strings_to_test ) ) { - return false; - } - - $password_lowercase = strtolower( $password ); - - foreach ( $strings_to_test as $string ) { - $string = strtolower( $string ); - $string_reversed = strrev( $string ); - - if ( $password_lowercase === $string || $password_lowercase === $string_reversed ) { - return false; - } - - // Also check for the string or reversed string with any numbers just stuck to the end to catch things like bob123 as passwords. - if ( - preg_match( '/^' . preg_quote( $string, '/' ) . '\d+$/', $password_lowercase ) - || preg_match( '/^' . preg_quote( $string_reversed, '/' ) . '\d+$/', $password_lowercase ) - ) { - return false; - } - } - - return true; - } - - /** - * A shorthand for the not in array construct. - * - * @param mixed $needle the needle. - * @param array $haystack the haystack. - * - * @return bool is the needle not in the haystack? - */ - protected function negative_in_array( $needle, $haystack ) { - return ! in_array( $needle, $haystack, true ); - } - - /** - * A helper function used to break a single string into its constituents so - * that both the full string and its constituents and any variants thereof - * can be tested against the password. - * - * @param string $string the string to be broken down. - * @param string $explode_delimiter delimiter. - * - * @return bool - */ - protected function add_user_strings_to_test( $string, $explode_delimiter = ' ' ) { - // Don't check against empty strings. - if ( empty( $string ) ) { - return false; - } - - $strings = explode( $explode_delimiter, $string ); - - // Remove any non alpha numeric characters from the strings to check against. - foreach ( $strings as $key => $_string ) { - $_string = trim( preg_replace( '/[^a-zA-Z0-9]/', '', $_string ) ); - if ( empty( $_string ) ) { - continue; - } - - $strings[ $key ] = $_string; - } - - // Check the original too. - $strings[] = trim( $string ); - - // Check the original minus non alpha numeric characters. - $strings[] = trim( preg_replace( '/[^a-zA-Z0-9]/', '', $string ) ); - - // Remove any empty strings. - // Note: This will also filter out '0'. - $strings = array_filter( $strings ); - if ( empty( $strings ) ) { - return false; - } - - $this->user_strings_to_test = array_unique( array_merge( $this->user_strings_to_test, $strings ) ); - - return true; - } - - /** - * Getter for the user strings array. - * - * @return array user strings. - */ - protected function get_user_strings_to_test() { - return $this->user_strings_to_test; - } - - /** - * Return a character set size that is used in the string. - * - * @param string $password the password. - * - * @return int number of different character sets in use. - */ - protected function get_charset_size( $password ) { - $size = 0; - - // Lowercase a-z. - if ( preg_match( '/[a-z]/', $password ) ) { - $size += 26; - } - - // Uppercase A-Z. - if ( preg_match( '/[A-Z]/', substr( $password, 1, - 1 ) ) ) { - $size += 26; - } - - // Digits. - if ( preg_match( '/\d/', substr( $password, 1, - 1 ) ) ) { - $size += 10; - } - - // Over digits symbols. - if ( preg_match( '/[!|@|#|$|%|^|&|*|(|)]/', $password ) ) { - $size += 10; - } - - // Other symbols. - if ( preg_match( '#[`|~|-|_|=|+|\[|{|\]|}|\\|\|;:\'",<\.>/\?]#', $password ) ) { - $size += 20; - } - - // Spaces. - if ( strpos( $password, ' ' ) ) { - ++$size; - } - - return $size; - } - - /** - * Shorthand for getting a character index. - * - * @param string $char character. - * - * @return int the character code. - */ - protected function get_char_index( $char ) { - $char = strtolower( $char[0] ); - if ( $char < 'a' || $char > 'z' ) { - return 0; - } else { - return ord( $char[0] ) - ord( 'a' ) + 1; - } - } - - /** - * This is the password strength calculation algorithm, based on the formula H = L(logN/log2). - * - * H = Entropy - * L = String length (the for iterator) - * N = Our charset size, via get_charset_size() - * - * @see https://en.wikipedia.org/wiki/Password_strength#Random_passwords - * - * On top of the base formula, we're also multiplying the bits of entropy for every char - * by 1 - (the probabily of it following the previous char) - * i.e.: the probablity of U following Q is ~0.84. If our password contains this pair of characters, - * the u char will only add ( 0.16^2 * charset_score ) to our total of entropy bits. - * - * @param string $password the password. - * - * @return float|int - */ - protected function calculate_entropy_bits( $password ) { - $bits = 0; - // Calculate the score. - $charset_score = log( $this->get_charset_size( $password ) ) / log( 2 ); - - $aidx = $this->get_char_index( $password[0] ); - $length = strlen( $password ); - - for ( $b = 1; $b < $length; $b++ ) { - $bidx = $this->get_char_index( $password[ $b ] ); - - // 27 = number of chars in the index (a-z,' '). - $c = 1.0 - $this->frequency_table[ $aidx * 27 + $bidx ]; - - // Increment the bits. - $bits += $charset_score * $c * $c; - - // Move on to next pair. - $aidx = $bidx; - } - - return $bits; - } - - /** - * A frequency table of character pairs, starting with ' ' then ' a', ' b' [...] , 'a ', 'aa' etc. - * - * @see http://rumkin.com/tools/password/passchk.php - * - * @var array - */ - public $frequency_table = array( - 0.23653710453418866, - 0.04577693541332556, - 0.03449832337075375, - 0.042918209651552706, - 0.037390873305146524, - 0.028509112115468728, - 0.02350896632162123, - 0.022188657238664526, - 0.028429800262428927, - 0.04357019973757107, - 0.00913602565971716, - 0.03223093745443942, - 0.02235311269864412, - 0.04438081352966905, - 0.04512377897652719, - 0.020055401662049863, - 0.055903192885260244, - 0.0024388394809739026, - 0.035207464644991984, - 0.07355941099285611, - 0.036905671380667734, - 0.026134421927394666, - 0.023787724158040528, - 0.011352092141711621, - 0.0032354570637119114, - 0.005986878553725033, - 0.008861933226417843, - 0.11511532293337222, - 0.027556203528211108, - 0.024331243621519172, - 0.039266365359381834, - 0.031599941682461, - 0.014403265782183991, - 0.015480973902901297, - 0.027770812071730572, - 0.00942761335471643, - 0.039872867764980315, - 0.0078122175244204695, - 0.02808456043154979, - 0.08429100451960927, - 0.04688963405744277, - 0.13831170724595424, - 0.002540311998833649, - 0.025211838460416972, - 0.001543082081936142, - 0.09519638431258201, - 0.061845750109345385, - 0.08907071001603732, - 0.02137571074500656, - 0.027093162268552268, - 0.005521504592506197, - 0.003023181221752442, - 0.007086747339262283, - 0.010262720513194342, - 0.08785070710016038, - 0.14617757690625455, - 0.03417291150313457, - 0.0059635515381250915, - 0.006146668610584633, - 0.195202799241872, - 0.002774748505613063, - 0.004715556203528212, - 0.0044776206444088066, - 0.11205481848665985, - 0.005654468581425864, - 0.0028820527773727946, - 0.07383000437381543, - 0.005516839189386207, - 0.006496573844583759, - 0.09843067502551392, - 0.0027140982650532145, - 0.0006893133109782768, - 0.08425368129464937, - 0.021325557661466685, - 0.006493074792243767, - 0.07023414491908442, - 0.002077270739174807, - 0.0024633328473538415, - 0.0007744569179180639, - 0.015413325557661468, - 0.0011990086018370024, - 0.13162851727657093, - 0.10115993585070711, - 0.0026989357049132527, - 0.03319317684793702, - 0.002946202070272634, - 0.0783216212275842, - 0.0018358361277154103, - 0.00258813238081353, - 0.2141688292754046, - 0.09853681294649366, - 0.0032482869222918796, - 0.04359352675317102, - 0.01993526753171016, - 0.0036880011663507797, - 0.008011663507799971, - 0.12014696019827964, - 0.0029846916460125384, - 0.0017553579238956116, - 0.029470185158186325, - 0.010413179763813967, - 0.030699518880303252, - 0.03508499781309229, - 0.002021285901734947, - 0.0010613792097973467, - 0.0005295232541186761, - 0.009677212421635807, - 0.010585799679253535, - 0.17101734946785244, - 0.07968625164018078, - 0.007839043592360402, - 0.005438693687126403, - 0.0183606939787141, - 0.2732701559994168, - 0.004953491762647616, - 0.007259367254701851, - 0.008104971570199739, - 0.13274588132380813, - 0.004210526315789474, - 0.004997813092287506, - 0.017006560723137484, - 0.007442484327161393, - 0.016789619478058026, - 0.08477737279486806, - 0.005106283714827234, - 0.0005026971861787433, - 0.04040355736987899, - 0.037535500801866156, - 0.00885960052485785, - 0.0336410555474559, - 0.007066919376002332, - 0.005344219273946639, - 0.0006333284735384167, - 0.010684939495553289, - 0.0063064586674442345, - 0.15386849394955532, - 0.015049424114302375, - 0.012162705933809595, - 0.020425134859308938, - 0.037366379938766583, - 0.02157165767604607, - 0.009373961218836564, - 0.0173214754337367, - 0.009616562181075958, - 0.029522670943286193, - 0.010154249890654615, - 0.018600962239393497, - 0.06362210234728094, - 0.03157078291296107, - 0.151603440734801, - 0.0062329785683044175, - 0.014775331681003062, - 0.0020854351946347867, - 0.1826342032366234, - 0.0878017203674005, - 0.054190989940224525, - 0.010329202507654177, - 0.012763376585508092, - 0.0064872430383437815, - 0.006381105117364048, - 0.005388540603586529, - 0.0090800408222773, - 0.09611196967487973, - 0.09940691062837148, - 0.01033969966467415, - 0.004034407348009914, - 0.008826942703017933, - 0.11474675608689314, - 0.07132584924916169, - 0.012388977985129028, - 0.005435194634786413, - 0.1417174515235457, - 0.0037066627788307337, - 0.0045802595130485495, - 0.060800699810468, - 0.005341886572386646, - 0.005683627350925791, - 0.12434932205860913, - 0.004596588423968508, - 0.0007534626038781163, - 0.07107041842834232, - 0.022361277154104096, - 0.04784720804782038, - 0.06277533168100306, - 0.003441901151771395, - 0.005828254847645429, - 0.0009669047966175828, - 0.009470768333576322, - 0.002077270739174807, - 0.12797667298440007, - 0.08797783933518005, - 0.005388540603586529, - 0.0024913252660737715, - 0.007550954949701123, - 0.2786866890217233, - 0.002509986878553725, - 0.029002478495407494, - 0.0303204548768042, - 0.07576614666861058, - 0.00246799825047383, - 0.00592389561160519, - 0.039574281965301064, - 0.00706808572678233, - 0.03304505029887739, - 0.05474150750838315, - 0.0028633911648928414, - 0.0005073625892987316, - 0.07293541332555767, - 0.053528502697186175, - 0.022566554891383584, - 0.038151334013704616, - 0.002716430966613209, - 0.005049132526607377, - 0.0009902318122175246, - 0.008997229916897508, - 0.0011861787432570347, - 0.1666377022889634, - 0.14414462749671964, - 0.003374252806531564, - 0.005169266656947077, - 0.008468873013558828, - 0.16337541915731155, - 0.002873888321912815, - 0.004305000728969237, - 0.0031141565825922144, - 0.1241172182533897, - 0.0052800699810468, - 0.008969237498177577, - 0.024094474413179766, - 0.017029887738737422, - 0.01722700102055693, - 0.10618457501093455, - 0.006147834961364631, - 0.0008269427030179326, - 0.03303571949263741, - 0.024188948826359528, - 0.05213937891820965, - 0.04505846333284735, - 0.0035270447587111824, - 0.006799825047383001, - 0.0008199445983379502, - 0.02206735675754483, - 0.001010059775477475, - 0.11971191135734072, - 0.04656538854060359, - 0.011243621519171892, - 0.06513019390581717, - 0.032375564951159064, - 0.06347047674588133, - 0.013678961947805804, - 0.03309870243475726, - 0.006982942119842543, - 0.009726199154395685, - 0.010121592068814697, - 0.032514360693978714, - 0.04986032949409535, - 0.039734072022160664, - 0.15690683773144773, - 0.03949963551538125, - 0.014790494241143023, - 0.002722262720513194, - 0.02614375273363464, - 0.10753637556495116, - 0.06764834523983088, - 0.006221315060504448, - 0.021317393206006705, - 0.0030826651115322934, - 0.002399183554454002, - 0.0019069835252952323, - 0.015595276279341012, - 0.0925126111678087, - 0.18437906400349907, - 0.006538562472663654, - 0.008719638431258201, - 0.02116693395538708, - 0.18241376293920394, - 0.007290858725761773, - 0.005976381396705059, - 0.005629975215045925, - 0.09721300481119698, - 0.004810030616707975, - 0.024303251202799244, - 0.012954658113427612, - 0.011057005394372358, - 0.02733459688001166, - 0.10135121737862662, - 0.012016912086309959, - 0.001055547455897361, - 0.009027555037177431, - 0.07162326869806095, - 0.01007143898527482, - 0.07297623560285756, - 0.006741507508383147, - 0.0036891675171307776, - 0.0008409389123778977, - 0.011272780288671819, - 0.007020265344802449, - 0.1030389269572824, - 0.15350809155853623, - 0.004232686980609419, - 0.004353987461729115, - 0.0023385333138941536, - 0.14450386353695874, - 0.002546143752733635, - 0.0024470039364338824, - 0.01200758128006998, - 0.0981227584195947, - 0.003161976964572095, - 0.040695145064878264, - 0.03460446129173349, - 0.003908441463770229, - 0.01598483743986004, - 0.13107216795451232, - 0.003129319142732177, - 0.00032307916605919226, - 0.04050386353695874, - 0.05452689896486368, - 0.03589677795597026, - 0.07087097244496282, - 0.006143169558244642, - 0.008684647907858289, - 0.0004607085580988482, - 0.022010205569324977, - 0.0009097536083977258, - 0.07328765126111678, - 0.14751421490013122, - 0.008015162560139961, - 0.006601545414783497, - 0.025279486805656802, - 0.1682449336637994, - 0.008313748359819215, - 0.007010934538562473, - 0.005886572386645284, - 0.16889575739903775, - 0.004123050007289692, - 0.011925936725470185, - 0.10007289692374982, - 0.013380376148126549, - 0.009021723283277445, - 0.08650823735238372, - 0.007756232686980609, - 0.0007243038343781893, - 0.0026791077416533026, - 0.02797492345823006, - 0.032384895757399036, - 0.04187432570345531, - 0.00882461000145794, - 0.0032401224668318998, - 0.00033357632307916605, - 0.027878116343490307, - 0.0022277299897944304, - 0.14333518005540166, - 0.1725534334451086, - 0.02781629975215046, - 0.006909462020702727, - 0.005264907420906838, - 0.16661437527336345, - 0.004325995043009185, - 0.003334596880011664, - 0.005312727802886718, - 0.14024668318996938, - 0.0013261408368566844, - 0.003504884093891238, - 0.006375273363464061, - 0.04964922000291588, - 0.008290421344219274, - 0.09536783787724158, - 0.05394372357486515, - 0.005505175681586237, - 0.005339553870826651, - 0.01782067356757545, - 0.006710016037323225, - 0.05105933809593235, - 0.002983525295232541, - 0.002940370316372649, - 0.0004548768041988629, - 0.01208456043154979, - 0.000915585362297711, - 0.20146260387811635, - 0.067196967487972, - 0.006158332118384605, - 0.025438110511736407, - 0.07753783350342616, - 0.1273876658405015, - 0.009337804344656656, - 0.07683452398308792, - 0.0070412596588423975, - 0.08747164309666132, - 0.0038827817466102928, - 0.018116926665694706, - 0.005017641055547455, - 0.004567429654468581, - 0.028277008310249308, - 0.05271555620352821, - 0.004394809739029013, - 0.0013343052923166642, - 0.00411605190260971, - 0.059621519171890944, - 0.09073859163143316, - 0.01446858142586383, - 0.006770666277883074, - 0.003425572240851436, - 0.0004455459979588861, - 0.010401516256013998, - 0.005825922146085436, - 0.10833882490158916, - 0.007584779122321038, - 0.016903921854497742, - 0.02719580113719201, - 0.0304814112844438, - 0.02206385770520484, - 0.013064295086747339, - 0.02696369733197259, - 0.009581571657676046, - 0.026761918647033093, - 0.006510570053943724, - 0.021941390873305145, - 0.07042659279778393, - 0.05437410701268406, - 0.1425175681586237, - 0.027802303542790494, - 0.037690625455605774, - 0.0019606356611750987, - 0.1095623268698061, - 0.06157748942994606, - 0.044618749088788455, - 0.04955124653739612, - 0.03608689313310978, - 0.018381688292754043, - 0.003404577926811489, - 0.015036594255722409, - 0.009600233270156, - 0.10794693103951014, - 0.12447528794284882, - 0.0031981338387520046, - 0.0074716430966613205, - 0.003202799241871993, - 0.13437643971424407, - 0.006655197550663361, - 0.0036693395538708266, - 0.049338970695436656, - 0.09486863974340283, - 0.0015990669193760023, - 0.0026604461291733486, - 0.051775477474850555, - 0.0041347135150896636, - 0.005450357194926374, - 0.12030325120279925, - 0.04581309228750547, - 0.0004537104534188657, - 0.12425601399620935, - 0.025981629975215047, - 0.023926519900860182, - 0.04423385333138941, - 0.0017950138504155123, - 0.002661612479953346, - 0.0006333284735384167, - 0.008449045050298877, - 0.000653156436798367, - 0.04816678816153958, - 0.008625164018078437, - 0.0039037760606502403, - 0.005228750546726928, - 0.004531272780288672, - 0.0056672984400058316, - 0.00359585945473101, - 0.0032179618020119548, - 0.0038093016474704767, - 0.011452398308791368, - 0.002519317684793702, - 0.00280390727511299, - 0.005572824026826068, - 0.004554599795888614, - 0.004531272780288672, - 0.0035841959469310393, - 0.004400641492928998, - 0.0036670068523108326, - 0.004839189386207902, - 0.006258638285464354, - 0.004897506925207757, - 0.840776789619478, - 0.004968654322787578, - 0.002886718180492783, - 0.0019757982213150604, - 0.0018568304417553576, - 0.001691208630995772, - 0.09009243329931477, - 0.14030150167662925, - 0.013242746756086894, - 0.013746610293045632, - 0.027342761335471644, - 0.16938912377897652, - 0.006607377168683481, - 0.01661933226417845, - 0.008173786266219566, - 0.13297448607668758, - 0.0034675608689313307, - 0.016641492928998396, - 0.011722991689750693, - 0.021493512173786266, - 0.03430820819361423, - 0.10099548039072752, - 0.00873596734217816, - 0.0018323370753754193, - 0.020103222044029742, - 0.047197550663362, - 0.040833940807697915, - 0.03361189677795597, - 0.010844729552412887, - 0.005544831608106138, - 0.0007522962530981193, - 0.01525120279924187, - 0.00815512465373961, - 0.2109648636827526, - 0.058258055110074355, - 0.007181221752442048, - 0.043560868931331105, - 0.004058900714389853, - 0.10618107595859454, - 0.0062399766729844, - 0.004835690333867911, - 0.02679224376731302, - 0.08414637702288964, - 0.0030698352529523252, - 0.03637498177576906, - 0.01592885260242018, - 0.017413617145356466, - 0.008430383437818923, - 0.037231083248286924, - 0.03290275550371775, - 0.007538125091121154, - 0.004500947660008748, - 0.05932409972299169, - 0.16006764834523984, - 0.03309636973319726, - 0.007766729844000583, - 0.005225251494386936, - 0.0006321621227584196, - 0.012989648636827526, - 0.005274238227146815, - 0.1254503571949264, - 0.12852719055255868, - 0.0035433736696311416, - 0.005203090829566993, - 0.0019314768916751715, - 0.20520775623268697, - 0.002509986878553725, - 0.00343606939787141, - 0.027138649948972155, - 0.13926578218399185, - 0.004565096952908587, - 0.005614812654905963, - 0.00874413179763814, - 0.004109053797929727, - 0.008300918501239247, - 0.08270943286193323, - 0.002912377897652719, - 0.0037066627788307337, - 0.06909578655780726, - 0.03242805073625893, - 0.05237614812654906, - 0.04723487388832191, - 0.0038991106575302524, - 0.006299460562764251, - 0.00043388249015891526, - 0.020029741944889927, - 0.005311561452106721, - 0.09334072022160665, - 0.022940953491762648, - 0.024658988190698353, - 0.02901297565242747, - 0.03531593526753171, - 0.0758023035427905, - 0.013711619769645722, - 0.021597317393206007, - 0.009670214316955824, - 0.044728386062108175, - 0.010596296836273509, - 0.03264382563055839, - 0.0604822860475288, - 0.05489546581134276, - 0.11501851581863246, - 0.01837585653885406, - 0.026237060796034405, - 0.0011255285026971862, - 0.08704125965884241, - 0.10156349322058608, - 0.06660562764251349, - 0.023434319871701415, - 0.010777081207173057, - 0.005409534917626476, - 0.003123487388832191, - 0.0028762210234728096, - 0.0089995626184575, - 0.07518297127861205, - 0.2314868056568013, - 0.002226563639014434, - 0.003285610147251786, - 0.0027455897361131363, - 0.2724537104534189, - 0.0016655489138358362, - 0.0019209797346551977, - 0.0022137337804344656, - 0.17690392185449774, - 0.0014532730718763668, - 0.0024994897215337513, - 0.015302522233561744, - 0.003441901151771395, - 0.015303688584341741, - 0.09314593964134713, - 0.0017833503426155418, - 0.0005108616416387229, - 0.017828838023035427, - 0.010385187345094037, - 0.003168975069252078, - 0.01902901297565243, - 0.005525003644846187, - 0.0010088934246974776, - 0.0009272488700976819, - 0.036282840064149294, - 0.0022977110365942554, - 0.0766805656801283, - 0.22270418428342326, - 0.005283569033386791, - 0.007155562035282111, - 0.01173582154833066, - 0.1715620352821111, - 0.003925936725470185, - 0.004425134859308937, - 0.020040239101909902, - 0.14243242455168392, - 0.0016737133692958156, - 0.0066808572678232975, - 0.011980755212130047, - 0.012638577052048404, - 0.07206065024055984, - 0.08115701997375711, - 0.00710424260096224, - 0.0007278028867181805, - 0.02347630849978131, - 0.04595538708266512, - 0.01481965301064295, - 0.013925061962385188, - 0.0018125091121154687, - 0.00529173348884677, - 0.0016340574427759146, - 0.03072401224668319, - 0.0023746901880740633, - 0.25174165330223064, - 0.06673392622831317, - 0.00878378772415804, - 0.03956261845750109, - 0.010077270739174807, - 0.0844787869951888, - 0.00985216503863537, - 0.004973319725907567, - 0.01893220586091267, - 0.11200583175389998, - 0.0028715556203528212, - 0.004095057588569762, - 0.01202391019098994, - 0.01756757544831608, - 0.014825484764542934, - 0.05312961073042717, - 0.06746872721971132, - 0.003845458521650386, - 0.0210806239976673, - 0.019443067502551394, - 0.08017028721387957, - 0.01825572240851436, - 0.005365213587986587, - 0.01959702580551101, - 0.026184575010934536, - 0.02474879720075813, - 0.002171745152354571, - 0.25827321767021433, - 0.048050153083539875, - 0.01043184137629392, - 0.03930485493512174, - 0.027640180784370902, - 0.03294007872867765, - 0.006474413179763814, - 0.018314039947514214, - 0.015119405161102202, - 0.014706516984983233, - 0.005494678524566263, - 0.03309870243475726, - 0.043864120134130345, - 0.058996355153812505, - 0.06265986295378335, - 0.04633328473538417, - 0.03790756670068523, - 0.0004642076104388394, - 0.037849249161685375, - 0.08369966467415076, - 0.04999679253535501, - 0.02392768625164018, - 0.010998687855372504, - 0.009881323808135296, - 0.003867619186470331, - 0.012434465665548913, - 0.007253535500801866, - 0.11106225397288234, - 0.17624726636535937, - 0.008209943140399476, - 0.008390727511299025, - 0.012682898381688294, - 0.1825653885406036, - 0.001538416678816154, - 0.004590756670068524, - 0.008710307625018223, - 0.1299513048549351, - 0.002677941390873305, - 0.012309666132089225, - 0.014087184720804781, - 0.01199941682461, - 0.031246537396121883, - 0.07206648199445984, - 0.008254264470039366, - 0.0007033095203382417, - 0.007034261554162415, - 0.006599212713223502, - 0.013906400349905234, - 0.050098265053214755, - 0.007133401370462167, - 0.017750692520775622, - 0.0008257763522379356, - 0.03918821985712203, - 0.06015454147834961, - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/CHANGELOG.md deleted file mode 100644 index f90db216..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/CHANGELOG.md +++ /dev/null @@ -1,151 +0,0 @@ -# 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). - -## [0.5.4] - 2025-03-21 -### Changed -- Internal updates. - -## [0.5.3] - 2025-03-12 -### Changed -- Internal updates. - -## [0.5.2] - 2025-03-05 -### Changed -- Internal updates. - -## [0.5.1] - 2025-02-24 -### Changed -- Update dependencies. - -## [0.5.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.4.4] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [0.4.3] - 2024-09-05 -### Changed -- Update dependencies. - -## [0.4.2] - 2024-08-26 -### Changed -- Updated package dependencies. [#39004] - -## [0.4.1] - 2024-08-15 -### Fixed -- Fix incorrect next-version tokens in php `@since` and/or `@deprecated` docs. [#38869] - -## [0.4.0] - 2024-05-20 -### Deprecated -- Extract the 'is_current_request_activating_plugin_from_plugins_screen' method into Status package. [#37430] - -## [0.3.5] - 2024-05-06 -### Changed -- Internal updates. - -## [0.3.4] - 2024-04-08 -### Changed -- Internal updates. - -## [0.3.3] - 2024-03-25 -### Changed -- Internal updates. - -## [0.3.2] - 2024-03-14 -### Changed -- Internal updates. - -## [0.3.1] - 2024-01-02 -### Fixed -- Ensured that language packs are installed after installing a new plugin. [#34763] - -## [0.3.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [0.2.6] - 2023-11-14 - -## [0.2.5] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [0.2.4] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.2.3] - 2023-02-20 -### Changed -- Minor internal updates. - -## [0.2.2] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [0.2.1] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [0.2.0] - 2022-08-23 -### Added -- Add method to check plugin activation context. [#25422] - -## [0.1.4] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [0.1.3] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [0.1.2] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [0.1.1] - 2022-03-29 -### Added -- Set composer package type to "jetpack-library" so i18n will work. - -## 0.1.0 - 2022-02-02 -### Added -- First version -- New functions to safely check plugin statuses - -### Changed -- Build: add missing mirror repo details, so package can be deployed. - -### Fixed -- Fix method logic - -[0.5.4]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.5.3...v0.5.4 -[0.5.3]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.5.2...v0.5.3 -[0.5.2]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.5.1...v0.5.2 -[0.5.1]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.5.0...v0.5.1 -[0.5.0]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.4.4...v0.5.0 -[0.4.4]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.4.3...v0.4.4 -[0.4.3]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.4.2...v0.4.3 -[0.4.2]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.4.1...v0.4.2 -[0.4.1]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.4.0...v0.4.1 -[0.4.0]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.3.5...v0.4.0 -[0.3.5]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.3.4...v0.3.5 -[0.3.4]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.3.3...v0.3.4 -[0.3.3]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.3.2...v0.3.3 -[0.3.2]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.3.1...v0.3.2 -[0.3.1]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.6...v0.3.0 -[0.2.6]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.5...v0.2.6 -[0.2.5]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.4...v0.2.5 -[0.2.4]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.3...v0.2.4 -[0.2.3]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.2...v0.2.3 -[0.2.2]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.1...v0.2.2 -[0.2.1]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.1.4...v0.2.0 -[0.1.4]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.1.3...v0.1.4 -[0.1.3]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.1.2...v0.1.3 -[0.1.2]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.1.1...v0.1.2 -[0.1.1]: https://github.com/Automattic/jetpack-plugins-installer/compare/v0.1.0...v0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/composer.json deleted file mode 100644 index 535f0a17..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/composer.json +++ /dev/null @@ -1,48 +0,0 @@ -{ - "name": "automattic/jetpack-plugins-installer", - "description": "Handle installation of plugins from WP.org", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-a8c-mc-stats": "^3.0.4", - "automattic/jetpack-status": "^5.0.10" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "mirror-repo": "Automattic/jetpack-plugins-installer", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-plugins-installer/compare/v${old}...v${new}" - }, - "autotagger": true, - "textdomain": "jetpack-plugins-installer" - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php deleted file mode 100644 index f68a526e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php +++ /dev/null @@ -1,157 +0,0 @@ -fs_connect( array( WP_CONTENT_DIR, WP_PLUGIN_DIR ) ); - if ( ! $result ) { - // set the string here since they are not available just yet. - $upgrader->generic_strings(); - $this->feedback( 'fs_unavailable' ); - } - } - - /** - * Overwrites the error function - * - * @param WP_Error|mixed $error The error object. - */ - public function error( $error ) { - if ( is_wp_error( $error ) ) { - $this->feedback( $error ); - } - } - - /** - * Set the main error code. - * - * Don't set the process_failed as code since it is not that helpful unless we don't have one already set - * - * @param string $code The error code. - * @return void - */ - private function set_main_error_code( $code ) { - $this->main_error_code = ( 'process_failed' === $code && $this->main_error_code ? $this->main_error_code : $code ); - } - - /** - * Set the main error message. - * - * Don't set the process_failed as message since it is not that helpful unless we don't have one already set - * - * @param string $message The error message. - * @param string $code The error code. - * @return void - */ - private function set_main_error_message( $message, $code ) { - $this->main_error_message = ( 'process_failed' === $code && $this->main_error_message ? $this->main_error_message : $message ); - } - - /** - * Get the main error code - * - * @return string - */ - public function get_main_error_code() { - return $this->main_error_code; - } - - /** - * Get the main error message - * - * @return string - */ - public function get_main_error_message() { - return $this->main_error_message; - } - - /** - * Overwrites the feedback function - * - * @param string|array|WP_Error $data Data. - * @param mixed ...$args Optional text replacements. - */ - public function feedback( $data, ...$args ) { - - $current_error = null; - if ( is_wp_error( $data ) ) { - $this->set_main_error_code( $data->get_error_code() ); - $string = $data->get_error_message(); - } elseif ( is_array( $data ) ) { - return; - } else { - $string = $data; - } - - if ( ! empty( $this->upgrader->strings[ $string ] ) ) { - $this->set_main_error_code( $string ); - - $current_error = $string; - $string = $this->upgrader->strings[ $string ]; - } - - if ( strpos( $string, '%' ) !== false ) { - if ( ! empty( $args ) ) { - $string = vsprintf( $string, $args ); - } - } - - $string = trim( $string ); - $string = wp_kses( - $string, - array( - 'a' => array( - 'href' => true, - ), - 'br' => true, - 'em' => true, - 'strong' => true, - ) - ); - - $this->set_main_error_message( $string, $current_error ); - $this->messages[] = $string; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php deleted file mode 100644 index c86537aa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php +++ /dev/null @@ -1,255 +0,0 @@ -install( $zip_url ); - - if ( is_wp_error( $result ) ) { - $mc_stats->add( 'install-plugin', "fail-$slug" ); - return $result; - } - - $plugin = self::get_plugin_id_by_slug( $slug ); - $error_code = 'install_error'; - if ( ! $plugin ) { - $error = __( 'There was an error installing your plugin', 'jetpack-plugins-installer' ); - } - - if ( ! $result ) { - $error_code = $skin->get_main_error_code(); - $message = $skin->get_main_error_message(); - $error = $message ? $message : __( 'An unknown error occurred during installation', 'jetpack-plugins-installer' ); - } - - if ( ! empty( $error ) ) { - if ( 'download_failed' === $error_code ) { - // For backwards compatibility: versions prior to 3.9 would return no_package instead of download_failed. - $error_code = 'no_package'; - } - - $mc_stats->add( 'install-plugin', "fail-$slug" ); - return new WP_Error( $error_code, $error, 400 ); - } - - $mc_stats->add( 'install-plugin', "success-$slug" ); - return (array) $upgrader->skin->get_upgrade_messages(); - } - - /** - * Get WordPress.org zip download link from a plugin slug - * - * @param string $plugin_slug Plugin slug. - */ - protected static function generate_wordpress_org_plugin_download_link( $plugin_slug ) { - return "https://downloads.wordpress.org/plugin/$plugin_slug.latest-stable.zip"; - } - - /** - * Get the plugin ID (composed of the plugin slug and the name of the main plugin file) from a plugin slug. - * - * @param string $slug Plugin slug. - */ - public static function get_plugin_id_by_slug( $slug ) { - // Check if get_plugins() function exists. This is required on the front end of the - // site, since it is in a file that is normally only loaded in the admin. - if ( ! function_exists( 'get_plugins' ) ) { - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - - /** This filter is documented in wp-admin/includes/class-wp-plugins-list-table.php */ - $plugins = apply_filters( 'all_plugins', get_plugins() ); - if ( ! is_array( $plugins ) ) { - return false; - } - - foreach ( $plugins as $plugin_file => $plugin_data ) { - if ( self::get_slug_from_file_path( $plugin_file ) === $slug ) { - return $plugin_file; - } - } - - return false; - } - - /** - * Get the plugin slug from the plugin ID (composed of the plugin slug and the name of the main plugin file) - * - * @param string $plugin_file Plugin file (ID -- e.g. hello-dolly/hello.php). - */ - protected static function get_slug_from_file_path( $plugin_file ) { - // Similar to get_plugin_slug() method. - $slug = dirname( $plugin_file ); - if ( '.' === $slug ) { - $slug = preg_replace( '/(.+)\.php$/', '$1', $plugin_file ); - } - - return $slug; - } - - /** - * Get the activation status for a plugin. - * - * @since-jetpack 8.9.0 - * - * @param string $plugin_file The plugin file to check. - * @return string Either 'network-active', 'active' or 'inactive'. - */ - public static function get_plugin_status( $plugin_file ) { - if ( self::is_plugin_active_for_network( $plugin_file ) ) { - return 'network-active'; - } - - if ( self::is_plugin_active( $plugin_file ) ) { - return 'active'; - } - - return 'inactive'; - } - - /** - * Safely checks if the plugin is active - * - * @since 0.1.0 - * - * @param string $plugin_file The plugin file to check. - * @return bool - */ - public static function is_plugin_active( $plugin_file ) { - self::ensure_plugin_functions_are_loaded(); - return is_plugin_active( $plugin_file ); - } - - /** - * Safely checks if the plugin is active for network - * - * @since 0.1.0 - * - * @param string $plugin_file The plugin file to check. - * @return bool - */ - public static function is_plugin_active_for_network( $plugin_file ) { - self::ensure_plugin_functions_are_loaded(); - return is_plugin_active_for_network( $plugin_file ); - } - - /** - * Returns a list of all plugins in the site. - * - * @since-jetpack 8.9.0 - * @uses get_plugins() - * - * @return array - */ - public static function get_plugins() { - self::ensure_plugin_functions_are_loaded(); - /** This filter is documented in wp-admin/includes/class-wp-plugins-list-table.php */ - $plugins = apply_filters( 'all_plugins', get_plugins() ); - - if ( is_array( $plugins ) && ! empty( $plugins ) ) { - foreach ( $plugins as $plugin_slug => $plugin_data ) { - $plugins[ $plugin_slug ]['active'] = in_array( - self::get_plugin_status( $plugin_slug ), - array( 'active', 'network-active' ), - true - ); - } - return $plugins; - } - - return array(); - } - - /** - * Determine if the current request is activating a plugin from the plugins page. - * - * @deprecated 0.4.0 - * @see Paths::is_current_request_activating_plugin_from_plugins_screen() - * - * @param string $plugin Plugin file path to check. - * @return bool - */ - public static function is_current_request_activating_plugin_from_plugins_screen( $plugin ) { - _deprecated_function( __METHOD__, '0.4.0', 'Automattic\\Jetpack\\Paths::is_current_request_activating_plugin_from_plugins_screen()' ); - return ( new Paths() )->is_current_request_activating_plugin_from_plugins_screen( $plugin ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/CHANGELOG.md deleted file mode 100644 index 4b6c42cb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/CHANGELOG.md +++ /dev/null @@ -1,74 +0,0 @@ -# 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). - -## [0.5.4] - 2025-03-21 -### Changed -- Internal updates. - -## [0.5.3] - 2025-03-12 -### Changed -- Internal updates. - -## [0.5.2] - 2025-03-05 -### Changed -- Internal updates. - -## [0.5.1] - 2025-02-24 -### Changed -- Update dependencies. - -## [0.5.0] - 2025-02-10 -### Changed -- Combine vulnerabilities for the same extension into single vulnerable extension threats. [#40863] - -## [0.4.2] - 2025-02-03 -### Changed -- Internal updates. - -## [0.4.1] - 2024-11-25 -### Changed -- Updated dependencies. [#40286] - -## [0.4.0] - 2024-11-14 -### Added -- Added threats property to protect status. [#40097] - -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.3.1] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [0.3.0] - 2024-09-23 -### Changed -- Adds a fixable_threats status property [#39125] - -## [0.2.1] - 2024-08-26 -### Changed -- Updated package dependencies. [#39004] - -## [0.2.0] - 2024-08-09 -### Added -- Add Scan History model. [#38117] - -## 0.1.0 - 2024-07-15 -### Added -- Initial version. [#37864] - -[0.5.4]: https://github.com/Automattic/jetpack-protect-models/compare/v0.5.3...v0.5.4 -[0.5.3]: https://github.com/Automattic/jetpack-protect-models/compare/v0.5.2...v0.5.3 -[0.5.2]: https://github.com/Automattic/jetpack-protect-models/compare/v0.5.1...v0.5.2 -[0.5.1]: https://github.com/Automattic/jetpack-protect-models/compare/v0.5.0...v0.5.1 -[0.5.0]: https://github.com/Automattic/jetpack-protect-models/compare/v0.4.2...v0.5.0 -[0.4.2]: https://github.com/Automattic/jetpack-protect-models/compare/v0.4.1...v0.4.2 -[0.4.1]: https://github.com/Automattic/jetpack-protect-models/compare/v0.4.0...v0.4.1 -[0.4.0]: https://github.com/Automattic/jetpack-protect-models/compare/v0.3.1...v0.4.0 -[0.3.1]: https://github.com/Automattic/jetpack-protect-models/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-protect-models/compare/v0.2.1...v0.3.0 -[0.2.1]: https://github.com/Automattic/jetpack-protect-models/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-protect-models/compare/v0.1.0...v0.2.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/composer.json deleted file mode 100644 index 05f99105..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/composer.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "name": "automattic/jetpack-protect-models", - "description": "This package contains the models used in Protect. ", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-redirect": "^3.0.5" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "build-development": "echo 'Add your build step to composer.json, please!'", - "build-production": "echo 'Add your build step to composer.json, please!'", - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-protect-models/compare/v${old}...v${new}" - }, - "mirror-repo": "Automattic/jetpack-protect-models", - "textdomain": "jetpack-protect-models", - "version-constants": { - "::PACKAGE_VERSION": "src/class-protect-models.php" - } - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-extension-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-extension-model.php deleted file mode 100644 index 8934ecc2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-extension-model.php +++ /dev/null @@ -1,116 +0,0 @@ - - */ - public $threats = array(); - - /** - * Whether the extension has been checked for threats. - * - * @var null|bool - */ - public $checked; - - /** - * The type of extension ("plugins", "themes", or "core"). - * - * @var null|string - */ - public $type; - - /** - * Extension Model Constructor - * - * @param array|object $extension Extension data to load into the model instance. - */ - public function __construct( $extension = array() ) { - if ( is_object( $extension ) ) { - $extension = (array) $extension; - } - - foreach ( $extension as $property => $value ) { - if ( property_exists( $this, $property ) ) { - // use the property's setter method when possible - if ( method_exists( $this, "set_$property" ) ) { - $this->{ "set_$property" }( $value ); - continue; - } - - // otherwise, map the value directly into the class property - $this->$property = $value; - } - } - } - - /** - * Set Threats - * - * @deprecated 0.4.0 This method is deprecated. Use Threat_Model::$extension instead. - * - * @param array $threats An array of threat data to add to the extension. - */ - public function set_threats( $threats ) { - if ( ! is_array( $threats ) ) { - // @phan-suppress-next-line PhanDeprecatedProperty -- Maintaining backwards compatibility. - $this->threats = array(); - return; - } - - // convert each provided threat item into an instance of Threat_Model - $threats = array_map( - function ( $threat ) { - if ( is_a( $threat, 'Threat_Model' ) ) { - return $threat; - } - - if ( is_object( $threat ) ) { - $threat = (array) $threat; - } - - return new Threat_Model( $threat ); - }, - $threats - ); - - // @phan-suppress-next-line PhanDeprecatedProperty -- Maintaining backwards compatibility. - $this->threats = $threats; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-history-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-history-model.php deleted file mode 100644 index 46631b73..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-history-model.php +++ /dev/null @@ -1,144 +0,0 @@ - - */ - public $threats = array(); - - /** - * Whether there was an error loading the history. - * - * @var bool - */ - public $error = false; - - /** - * The error code thrown when loading the history. - * - * @var string - */ - public $error_code; - - /** - * The error message thrown when loading the history. - * - * @var string - */ - public $error_message; - - /** - * The number of threats. - * - * @deprecated 0.4.0 This property is deprecated. Count History_Model::$threats instead. - * - * @var int - */ - public $num_threats; - - /** - * The number of core threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and count History_Model::$threats instead. - * - * @var int - */ - public $num_core_threats; - - /** - * The number of plugin threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and count History_Model::$threats instead. - * - * @var int - */ - public $num_plugins_threats; - - /** - * The number of theme threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and count History_Model::$threats instead. - * - * @var int - */ - public $num_themes_threats; - - /** - * WordPress core. - * - * @deprecated 0.4.0 This property is deprecated. Use History_Model::$threats instead. - * - * @var array - */ - public $core = array(); - - /** - * Status themes. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use History_Model::$threats instead. - * - * @var array - */ - public $themes = array(); - - /** - * Status plugins. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use History_Model::$threats instead. - * - * @var array - */ - public $plugins = array(); - - /** - * File threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use History_Model::$threats instead. - * - * @var array - */ - public $files = array(); - - /** - * Database threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use History_Model::$threats instead. - * - * @var array - */ - public $database = array(); - - /** - * Status constructor. - * - * @param array $history The history data to load into the class instance. - */ - public function __construct( $history = array() ) { - foreach ( $history as $property => $value ) { - if ( property_exists( $this, $property ) ) { - $this->$property = $value; - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-protect-models.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-protect-models.php deleted file mode 100644 index 5e320725..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-protect-models.php +++ /dev/null @@ -1,16 +0,0 @@ - - */ - public $threats = array(); - - /** - * List of fixable threat IDs. - * - * @var string[] - */ - public $fixable_threat_ids = array(); - - /** - * Whether the site includes items that have not been checked. - * - * @var boolean - */ - public $has_unchecked_items; - - /** - * The estimated percentage of the current scan. - * - * @var int - */ - public $current_progress; - - /** - * Whether there was an error loading the status. - * - * @var bool - */ - public $error = false; - - /** - * The error code thrown when loading the status. - * - * @var string - */ - public $error_code; - - /** - * The error message thrown when loading the status. - * - * @var string - */ - public $error_message; - - /** - * The number of threats. - * - * @deprecated 0.4.0 This property is deprecated. Count Status_Model::$threats instead. - * - * @var int - */ - public $num_threats; - - /** - * The number of plugin threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and count Status_Model::$threats instead. - * - * @var int - */ - public $num_plugins_threats; - - /** - * The number of theme threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and count Status_Model::$threats instead. - * - * @var int - */ - public $num_themes_threats; - - /** - * WordPress core status. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use Status_Model::$threats instead. - * - * @var object - */ - public $core; - - /** - * Status themes. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use Status_Model::$threats instead. - * - * @var array - */ - public $themes = array(); - - /** - * Status plugins. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use Status_Model::$threats instead. - * - * @var array - */ - public $plugins = array(); - - /** - * File threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use Status_Model::$threats instead. - * - * @var array - */ - public $files = array(); - - /** - * Database threats. - * - * @deprecated 0.4.0 This property is deprecated. Filter and use Status_Model::$threats instead. - * - * @var array - */ - public $database = array(); - - /** - * Status constructor. - * - * @param array $status The status data to load into the class instance. - */ - public function __construct( $status = array() ) { - // set status defaults - // @phan-suppress-next-line PhanDeprecatedProperty -- Maintaining backwards compatibility. - $this->core = new \stdClass(); - - foreach ( $status as $property => $value ) { - if ( property_exists( $this, $property ) ) { - $this->$property = $value; - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-threat-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-threat-model.php deleted file mode 100644 index 01fa763f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-threat-model.php +++ /dev/null @@ -1,265 +0,0 @@ - $value ) { - if ( 'extension' === $property && ! empty( $value ) ) { - $this->extension = new Extension_Model( $value ); - continue; - } - if ( property_exists( $this, $property ) ) { - $this->$property = $value; - } - } - } - - /** - * Get the ID value of the threat based on its related extension and vulnerabilities. - * - * @since 0.5.0 - * - * @param Extension_Model $extension The extension to get the ID from. - * - * @return string - */ - private static function get_id_from_vulnerable_extension( Extension_Model $extension ) { - return "$extension->type-$extension->slug-$extension->version"; - } - - /** - * Get the title from a vulnerable extension. - * - * @since 0.5.0 - * - * @param Extension_Model $extension The extension to get the title from. - * - * @return string|null - */ - private static function get_title_from_vulnerable_extension( Extension_Model $extension ) { - $titles = array( - 'plugins' => sprintf( - /* translators: placeholders are the theme name and version number. Example: "Vulnerable theme: Jetpack (version 1.2.3)" */ - __( 'Vulnerable plugin: %1$s (version %2$s)', 'jetpack-protect-models' ), - $extension->name, - $extension->version - ), - 'themes' => sprintf( - /* translators: placeholders are the theme name and version number. Example: "Vulnerable theme: Jetpack (version 1.2.3)" */ - __( 'Vulnerable theme: %1$s (version %2$s)', 'jetpack-protect-models' ), - $extension->name, - $extension->version - ), - 'core' => sprintf( - /* translators: placeholder is the version number. Example: "Vulnerable WordPress (version 1.2.3)" */ - __( 'Vulnerable WordPress (version %s)', 'jetpack-protect-models' ), - $extension->version - ), - ); - - return $titles[ $extension->type ] ?? null; - } - - /** - * Get the description from a vulnerable extension. - * - * @since 0.5.0 - * - * @param Extension_Model $extension The extension to get the description from. - * @param array $vulnerabilities The vulnerabilities to get the description from. - * - * @return string - */ - private static function get_description_from_vulnerable_extension( Extension_Model $extension, array $vulnerabilities ) { - return sprintf( - /* translators: placeholders are the theme name and version number. Example: "The installed version of Jetpack (1.2.3) has a known security vulnerability." */ - _n( 'The installed version of %1$s (%2$s) has a known security vulnerability.', 'The installed version of %1$s (%2$s) has known security vulnerabilities.', count( $vulnerabilities ), 'jetpack-protect-models' ), - $extension->name, - $extension->version - ); - } - - /** - * Get the latest fixed_in version from a list of vulnerabilities. - * - * @since 0.5.0 - * - * @param array $vulnerabilities The vulnerabilities to get the fixed_in version from. - * - * @return string|bool|null The latest fixed_in version, or false if any of the vulnerabilities are not fixed. - */ - private static function get_fixed_in_from_vulnerabilities( array $vulnerabilities ) { - $fixed_in = null; - - foreach ( $vulnerabilities as $vulnerability ) { - // If any of the vulnerabilities are not fixed, the threat is not fixed. - if ( ! $vulnerability->fixed_in ) { - break; - } - - // Use the latest available fixed_in version. - if ( ! $fixed_in || ( $fixed_in && version_compare( $vulnerability->fixed_in, $fixed_in, '>' ) ) ) { - $fixed_in = $vulnerability->fixed_in; - } - } - - return $fixed_in; - } - - /** - * Generate a threat from extension vulnerabilities. - * - * @since 0.5.0 - * - * @param Extension_Model $extension The extension to generate the threat for. - * @param Vulnerability_Model[] $vulnerabilities The vulnerabilities to generate the threat from. - * - * @return Threat_Model - */ - public static function generate_from_extension_vulnerabilities( Extension_Model $extension, array $vulnerabilities ) { - return new Threat_Model( - array( - 'id' => self::get_id_from_vulnerable_extension( $extension ), - 'title' => self::get_title_from_vulnerable_extension( $extension ), - 'description' => self::get_description_from_vulnerable_extension( $extension, $vulnerabilities ), - 'fixed_in' => self::get_fixed_in_from_vulnerabilities( $vulnerabilities ), - 'vulnerabilities' => $vulnerabilities, - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-vulnerability-model.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-vulnerability-model.php deleted file mode 100644 index b0f27e97..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-models/src/class-vulnerability-model.php +++ /dev/null @@ -1,94 +0,0 @@ - $value ) { - if ( property_exists( $this, $property ) ) { - $this->$property = $value; - } - } - - // Ensure the source URL is set. - $this->get_source(); - } - - /** - * Get the source URL for the vulnerability. - * - * @return string - */ - public function get_source() { - if ( empty( $this->source ) && $this->id ) { - $this->source = Redirect::get_url( 'jetpack-protect-vul-info', array( 'path' => $this->id ) ); - } - - return $this->source; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/CHANGELOG.md deleted file mode 100644 index 89602425..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/CHANGELOG.md +++ /dev/null @@ -1,133 +0,0 @@ -# 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). - -## [0.5.8] - 2025-03-21 -### Changed -- Internal updates. - -## [0.5.7] - 2025-03-18 -### Changed -- Update dependencies. - -## [0.5.6] - 2025-03-17 -### Changed -- Internal updates. - -## [0.5.5] - 2025-03-12 -### Changed -- Internal updates. - -## [0.5.4] - 2025-03-05 -### Changed -- Internal updates. - -## [0.5.3] - 2025-03-03 -### Changed -- Internal updates. - -## [0.5.2] - 2025-02-24 -### Changed -- Update dependencies. - -## [0.5.1] - 2025-02-11 -### Fixed -- Protect Status: Ensure vulnerabilities property is always an array. [#41694] - -## [0.5.0] - 2025-02-10 -### Changed -- Combine multiple vulnerability results for the same extension into a single vulnerable extension threat result. [#40863] - -## [0.4.3] - 2025-02-03 -### Fixed -- Code: Remove extra params on function calls. [#41263] -- Fix a bug when core version data is not interpreted correctly from the report data response. [#41503] - -## [0.4.2] - 2025-01-20 -### Fixed -- Fix Current_Plan::supports() call from breaking cache on every call. [#41010] - -## [0.4.1] - 2024-12-23 -### Fixed -- Fix PHP warnings caused by uninstalled extensions. [#40622] - -## [0.4.0] - 2024-12-04 -### Added -- Add extension data to threats. [#40400] - -## [0.3.1] - 2024-11-25 -### Changed -- Updated dependencies. [#40286] - -## [0.3.0] - 2024-11-14 -### Added -- Added threats property to protect status. [#40097] - -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.2.2] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [0.2.1] - 2024-10-29 -### Changed -- Internal updates. - -## [0.2.0] - 2024-09-23 -### Changed -- Adds a fixable_threats status property [#39125] - -## [0.1.5] - 2024-09-05 -### Changed -- Update dependencies. - -## [0.1.4] - 2024-09-05 -### Changed -- Update dependencies. - -## [0.1.3] - 2024-08-26 -### Changed -- Updated package dependencies. [#39004] - -## [0.1.2] - 2024-08-19 -### Changed -- Internal updates. - -## [0.1.1] - 2024-08-09 -### Changed -- Update dependencies. - -## 0.1.0 - 2024-07-15 -### Added -- Initial version. [#37894] - -### Changed -- Updated package dependencies. [#37894] - -[0.5.8]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.7...v0.5.8 -[0.5.7]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.6...v0.5.7 -[0.5.6]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.5...v0.5.6 -[0.5.5]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.4...v0.5.5 -[0.5.4]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.3...v0.5.4 -[0.5.3]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.2...v0.5.3 -[0.5.2]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.1...v0.5.2 -[0.5.1]: https://github.com/Automattic/jetpack-protect-status/compare/v0.5.0...v0.5.1 -[0.5.0]: https://github.com/Automattic/jetpack-protect-status/compare/v0.4.3...v0.5.0 -[0.4.3]: https://github.com/Automattic/jetpack-protect-status/compare/v0.4.2...v0.4.3 -[0.4.2]: https://github.com/Automattic/jetpack-protect-status/compare/v0.4.1...v0.4.2 -[0.4.1]: https://github.com/Automattic/jetpack-protect-status/compare/v0.4.0...v0.4.1 -[0.4.0]: https://github.com/Automattic/jetpack-protect-status/compare/v0.3.1...v0.4.0 -[0.3.1]: https://github.com/Automattic/jetpack-protect-status/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-protect-status/compare/v0.2.2...v0.3.0 -[0.2.2]: https://github.com/Automattic/jetpack-protect-status/compare/v0.2.1...v0.2.2 -[0.2.1]: https://github.com/Automattic/jetpack-protect-status/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-protect-status/compare/v0.1.5...v0.2.0 -[0.1.5]: https://github.com/Automattic/jetpack-protect-status/compare/v0.1.4...v0.1.5 -[0.1.4]: https://github.com/Automattic/jetpack-protect-status/compare/v0.1.3...v0.1.4 -[0.1.3]: https://github.com/Automattic/jetpack-protect-status/compare/v0.1.2...v0.1.3 -[0.1.2]: https://github.com/Automattic/jetpack-protect-status/compare/v0.1.1...v0.1.2 -[0.1.1]: https://github.com/Automattic/jetpack-protect-status/compare/v0.1.0...v0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/composer.json deleted file mode 100644 index 192476b9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/composer.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "name": "automattic/jetpack-protect-status", - "description": "This package contains the Protect Status API functionality to retrieve a site's scan status (WordPress, Themes, and Plugins threats).", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-connection": "^6.7.7", - "automattic/jetpack-plugins-installer": "^0.5.4", - "automattic/jetpack-sync": "^4.9.2", - "automattic/jetpack-protect-models": "^0.5.4", - "automattic/jetpack-plans": "^0.6.1" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "build-development": "echo 'Add your build step to composer.json, please!'", - "build-production": "echo 'Add your build step to composer.json, please!'", - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - }, - "extra": { - "autotagger": true, - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-protect-status/compare/v${old}...v${new}" - }, - "mirror-repo": "Automattic/jetpack-protect-status", - "textdomain": "jetpack-protect-status", - "version-constants": { - "::PACKAGE_VERSION": "src/class-status.php" - } - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-plan.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-plan.php deleted file mode 100644 index 878101ea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-plan.php +++ /dev/null @@ -1,111 +0,0 @@ - ( self::CACHE_VALIDITY_PERIOD ); - } - - /** - * Gets the product list from the user cache - */ - private static function get_product_from_cache() { - return get_user_meta( get_current_user_id(), self::CACHE_META_NAME, true ); - } - - /** - * Gets the product data - * - * @param string $wpcom_product The product slug. - * @return array - */ - public static function get_product( $wpcom_product = 'jetpack_scan' ) { - if ( ! self::is_cache_old() ) { - return self::get_product_from_cache(); - } - - $request_url = 'https://public-api.wordpress.com/rest/v1.1/products?locale=' . get_user_locale() . '&type=jetpack'; - $wpcom_request = wp_remote_get( esc_url_raw( $request_url ) ); - $response_code = wp_remote_retrieve_response_code( $wpcom_request ); - - if ( 200 === $response_code ) { - $products = json_decode( wp_remote_retrieve_body( $wpcom_request ) ); - - // Pick the desired product... - $product = $products->{$wpcom_product}; - - // ... and store it into the cache. - update_user_meta( get_current_user_id(), self::CACHE_DATE_META_NAME, time() ); - update_user_meta( get_current_user_id(), self::CACHE_META_NAME, $product ); - - return $product; - } - - return new \WP_Error( - 'failed_to_fetch_data', - esc_html__( 'Unable to fetch the requested data.', 'jetpack-protect-status' ), - array( - 'status' => $response_code, - 'request' => $wpcom_request, - ) - ); - } - - /** - * Has Required Plan - * - * @param bool $force_refresh Refresh the local plan cache from wpcom. - * @return bool True when the site has a plan or product that supports the paid Protect tier. - */ - public static function has_required_plan( $force_refresh = false ) { - static $has_scan = null; - if ( null === $has_scan || $force_refresh ) { - $products = array_column( Current_Plan::get_products(), 'product_slug' ); - - // Check for a plan or product that enables scan. - $plan_supports_scan = Current_Plan::supports( 'scan', $force_refresh ); - $has_scan_product = count( array_intersect( array( 'jetpack_scan', 'jetpack_scan_monthly' ), $products ) ) > 0; - $has_scan = $plan_supports_scan || $has_scan_product; - } - - return $has_scan; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-protect-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-protect-status.php deleted file mode 100644 index 08a64541..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-protect-status.php +++ /dev/null @@ -1,340 +0,0 @@ - true, - 'error_code' => $status->get_error_code(), - 'error_message' => $status->get_error_message(), - ) - ); - } else { - $status = self::normalize_protect_report_data( $status ); - } - - self::$status = $status; - return $status; - } - - /** - * Gets the WPCOM API endpoint - * - * @return WP_Error|string - */ - public static function get_api_url() { - $blog_id = Jetpack_Options::get_option( 'id' ); - $is_connected = ( new Connection_Manager() )->is_connected(); - - if ( ! $blog_id || ! $is_connected ) { - return new WP_Error( 'site_not_connected' ); - } - - $api_url = sprintf( self::REST_API_BASE, $blog_id ); - - return $api_url; - } - - /** - * Fetches the status from WPCOM servers - * - * @return WP_Error|array - */ - public static function fetch_from_server() { - $api_url = self::get_api_url(); - if ( is_wp_error( $api_url ) ) { - return $api_url; - } - - $response = Client::wpcom_json_api_request_as_blog( - self::get_api_url(), - '2', - array( - 'method' => 'GET', - 'timeout' => 30, - ), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code || empty( $response['body'] ) ) { - return new WP_Error( 'failed_fetching_status', 'Failed to fetch Protect Status data from server', array( 'status' => $response_code ) ); - } - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - self::update_status_option( $body ); - return $body; - } - - /** - * Normalize data from the Protect Report data source. - * - * @phan-suppress PhanDeprecatedProperty -- Maintaining backwards compatibility. - * - * @param object $report_data Data from the Protect Report. - * @return Status_Model - */ - protected static function normalize_protect_report_data( $report_data ) { - $status = new Status_Model(); - $status->data_source = 'protect_report'; - - // map report data properties directly into the Status_Model - $status->status = isset( $report_data->status ) ? $report_data->status : null; - $status->last_checked = isset( $report_data->last_checked ) ? $report_data->last_checked : null; - $status->num_threats = isset( $report_data->num_vulnerabilities ) ? $report_data->num_vulnerabilities : null; - $status->num_themes_threats = isset( $report_data->num_themes_vulnerabilities ) ? $report_data->num_themes_vulnerabilities : null; - $status->num_plugins_threats = isset( $report_data->num_plugins_vulnerabilities ) ? $report_data->num_plugins_vulnerabilities : null; - $status->has_unchecked_items = false; - - // normalize extension information - self::normalize_extension_data( $status, $report_data, 'themes' ); - self::normalize_extension_data( $status, $report_data, 'plugins' ); - self::normalize_core_data( $status, $report_data ); - - // sort extensions by number of threats - $status->themes = self::sort_threats( $status->themes ); - $status->plugins = self::sort_threats( $status->plugins ); - - return $status; - } - - /** - * Normalize theme and plugin information from the Protect Report data source. - * - * @phan-suppress PhanDeprecatedProperty -- Maintaining backwards compatibility. - * - * @param object $status The status object to normalize. - * @param object $report_data Data from the Protect Report. - * @param string $extension_type The type of extension to normalize. Either 'themes' or 'plugins'. - * - * @return void - */ - protected static function normalize_extension_data( &$status, $report_data, $extension_type ) { - if ( ! in_array( $extension_type, array( 'plugins', 'themes' ), true ) ) { - return; - } - - $installed_extensions = 'plugins' === $extension_type ? Plugins_Installer::get_plugins() : Sync_Functions::get_themes(); - $checked_extensions = isset( $report_data->{ $extension_type } ) ? $report_data->{ $extension_type } : new \stdClass(); - - /** - * Extension slug <=> threats data map. - * - * @var Extension_Model[] $extension_threats Array of Extension_Model objects indexed by slug. - */ - $extension_threats = array(); - - // Initialize the extension threats map with all extensions currently installed on the site - foreach ( $installed_extensions as $slug => $installed_extension ) { - $extension_threats[ $slug ] = new Extension_Model( - array( - 'slug' => $slug, - 'name' => $installed_extension['Name'], - 'version' => $installed_extension['Version'], - 'type' => $extension_type, - 'checked' => isset( $checked_extensions->{ $slug } ), - ) - ); - } - - foreach ( $checked_extensions as $slug => $checked_extension ) { - $installed_extension = $installed_extensions[ $slug ] ?? null; - - // extension is no longer installed on the site - if ( ! $installed_extension ) { - continue; - } - - $extension = new Extension_Model( - array( - 'name' => $installed_extension['Name'], - 'version' => $installed_extension['Version'], - 'slug' => $slug, - 'checked' => false, - 'type' => $extension_type, - ) - ); - - // extension version has changed since the report - if ( $installed_extension['Version'] !== $checked_extension->version ) { - // maintain $status->{ themes|plugins } for backwards compatibility. - $extension_threats[ $slug ] = $extension; - continue; - } - - $extension->checked = true; - $extension_threats[ $slug ] = $extension; - - if ( is_array( $checked_extension->vulnerabilities ) && ! empty( $checked_extension->vulnerabilities ) ) { - // normalize the vulnerabilities data - $vulnerabilities = array_map( - function ( $vulnerability ) { - return new Vulnerability_Model( $vulnerability ); - }, - $checked_extension->vulnerabilities - ); - - // convert the detected vulnerabilities into a vulnerable extension threat - $threat = Threat_Model::generate_from_extension_vulnerabilities( $extension, $vulnerabilities ); - - $threat_extension = clone $extension; - $extension_threat = clone $threat; - - $extension_threat->extension = null; - $extension_threats[ $slug ]->threats[] = $extension_threat; - - $threat->extension = $threat_extension; - $status->threats[] = $threat; - } - } - - $status->{ $extension_type } = array_values( $extension_threats ); - } - - /** - * Normalize the core information from the Protect Report data source. - * - * @phan-suppress PhanDeprecatedProperty -- Maintaining backwards compatibility. - * - * @param object $status The status object to normalize. - * @param object $report_data Data from the Protect Report. - * - * @return void - */ - protected static function normalize_core_data( &$status, $report_data ) { - global $wp_version; - - // Ensure the report data has the core property. - if ( ! isset( $report_data->core ) || ! $report_data->core - || ! isset( $report_data->core->version ) || ! $report_data->core->version ) { - $report_data->core = new \stdClass(); - $report_data->core->version = new \stdClass(); - } - - $core = new Extension_Model( - array( - 'type' => 'core', - 'name' => 'WordPress', - 'slug' => 'wordpress', - 'version' => $wp_version, - 'checked' => false, - ) - ); - - // Core version has changed since the report. - if ( $report_data->core->version !== $wp_version ) { - // Maintain $status->core for backwards compatibility. - $status->core = $core; - return; - } - - // If we've made it this far, the core version has been checked. - $core->checked = true; - - // Generate a threat from core vulnerabilities. - if ( is_array( $report_data->core->vulnerabilities ) && ! empty( $report_data->core->vulnerabilities ) ) { - // normalize the vulnerabilities data - $vulnerabilities = array_map( - function ( $vulnerability ) { - return new Vulnerability_Model( $vulnerability ); - }, - $report_data->core->vulnerabilities - ); - - // convert the detected vulnerabilities into a vulnerable extension threat - $threat = Threat_Model::generate_from_extension_vulnerabilities( $core, $vulnerabilities ); - - $threat_extension = clone $core; - $extension_threat = clone $threat; - - $core->threats[] = $extension_threat; - $threat->extension = $threat_extension; - - $status->threats[] = $threat; - } - - $status->core = $core; - } - - /** - * Sort By Threats - * - * @param array $threats Array of threats to sort. - * - * @return array The sorted $threats array. - */ - protected static function sort_threats( $threats ) { - usort( - $threats, - function ( $a, $b ) { - return count( $a->threats ) - count( $b->threats ); - } - ); - - return $threats; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-rest-controller.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-rest-controller.php deleted file mode 100644 index 77ff6019..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-rest-controller.php +++ /dev/null @@ -1,112 +0,0 @@ - \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_check_plan', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'status', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_get_status', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'clear-scan-cache', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_clear_scan_cache', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - } - - /** - * Return site plan data for the API endpoint - * - * @return WP_REST_Response - */ - public static function api_check_plan() { - $has_required_plan = Plan::has_required_plan(); - - return rest_ensure_response( $has_required_plan ); - } - - /** - * Return Protect Status for the API endpoint - * - * @param WP_REST_Request $request The request object. - * - * @return WP_REST_Response - */ - public static function api_get_status( $request ) { - $status = Status::get_status( $request['hard_refresh'] ); - return rest_ensure_response( $status ); - } - - /** - * Clear the Scan_Status cache for the API endpoint - * - * @return WP_REST_Response - */ - public static function api_clear_scan_cache() { - $cache_cleared = Scan_Status::delete_option(); - - if ( ! $cache_cleared ) { - return new WP_REST_Response( 'An error occured while attempting to clear the Jetpack Scan cache.', 500 ); - } - - return new WP_REST_Response( 'Jetpack Scan cache cleared.' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-scan-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-scan-status.php deleted file mode 100644 index 580a3780..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-scan-status.php +++ /dev/null @@ -1,343 +0,0 @@ - true, - 'error_code' => $status->get_error_code(), - 'error_message' => $status->get_error_message(), - ) - ); - } else { - $status = self::normalize_api_data( $status ); - } - - self::$status = $status; - return $status; - } - - /** - * Gets the Scan API endpoint - * - * @return WP_Error|string - */ - public static function get_api_url() { - $blog_id = Jetpack_Options::get_option( 'id' ); - $is_connected = ( new Connection_Manager() )->is_connected(); - - if ( ! $blog_id || ! $is_connected ) { - return new WP_Error( 'site_not_connected' ); - } - - $api_url = sprintf( self::SCAN_API_BASE, $blog_id ); - - return $api_url; - } - - /** - * Fetches the status data from the Scan API - * - * @return WP_Error|array - */ - public static function fetch_from_api() { - $api_url = self::get_api_url(); - if ( is_wp_error( $api_url ) ) { - return $api_url; - } - - $response = Client::wpcom_json_api_request_as_blog( - self::get_api_url(), - '2', - array( - 'method' => 'GET', - 'timeout' => 30, - ), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code || empty( $response['body'] ) ) { - return new WP_Error( 'failed_fetching_status', 'Failed to fetch Scan data from the server', array( 'status' => $response_code ) ); - } - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - self::update_status_option( $body ); - return $body; - } - - /** - * Normalize API Data - * - * Formats the payload from the Scan API into an instance of Status_Model. - * - * @phan-suppress PhanDeprecatedProperty -- Maintaining backwards compatibility. - * - * @param object $scan_data The data returned by the scan API. - * - * @return Status_Model - */ - private static function normalize_api_data( $scan_data ) { - global $wp_version; - - $installed_plugins = Plugins_Installer::get_plugins(); - $installed_themes = Sync_Functions::get_themes(); - - $plugins = array(); - $themes = array(); - $core = new Extension_Model( - array( - 'name' => 'WordPress', - 'slug' => 'wordpress', - 'version' => $wp_version, - 'type' => 'core', - 'checked' => true, // to do: default to false once Scan API has manifest - ) - ); - $files = array(); - - $status = new Status_Model( - array( - 'data_source' => 'scan_api', - 'status' => isset( $scan_data->state ) ? $scan_data->state : null, - 'num_threats' => 0, - 'num_themes_threats' => 0, - 'num_plugins_threats' => 0, - 'has_unchecked_items' => false, - 'current_progress' => isset( $scan_data->current->progress ) ? $scan_data->current->progress : null, - ) - ); - - // Format the "last checked" timestamp. - if ( ! empty( $scan_data->most_recent->timestamp ) ) { - $date = new \DateTime( $scan_data->most_recent->timestamp ); - if ( $date ) { - $status->last_checked = $date->format( 'Y-m-d H:i:s' ); - } - } - - // Ensure all installed plugins and themes are represented in the status. - foreach ( $installed_plugins as $path => $installed_plugin ) { - $slug = str_replace( '.php', '', explode( '/', $path )[0] ); - $plugin = new Extension_Model( - array( - 'name' => $installed_plugin['Name'], - 'version' => $installed_plugin['Version'], - 'slug' => $slug, - 'type' => 'plugins', - 'checked' => true, // to do: default to false once Scan API has manifest - ) - ); - - $plugins[ $slug ] = $plugin; - } - foreach ( $installed_themes as $path => $installed_theme ) { - $slug = str_replace( '.php', '', explode( '/', $path )[0] ); - $theme = new Extension_Model( - array( - 'name' => $installed_theme['Name'], - 'version' => $installed_theme['Version'], - 'slug' => $slug, - 'type' => 'themes', - 'checked' => true, // to do: default to false once Scan API has manifest - ) - ); - - $themes[ $slug ] = $theme; - } - - // Merge the threats into the status model. - if ( isset( $scan_data->threats ) && is_array( $scan_data->threats ) ) { - foreach ( $scan_data->threats as $scan_threat ) { - if ( isset( $scan_threat->fixable ) && $scan_threat->fixable ) { - $status->fixable_threat_ids[] = $scan_threat->id; - } - - $threat = new Threat_Model( - array( - 'id' => isset( $scan_threat->id ) ? $scan_threat->id : null, - 'signature' => isset( $scan_threat->signature ) ? $scan_threat->signature : null, - 'title' => isset( $scan_threat->title ) ? $scan_threat->title : null, - 'description' => isset( $scan_threat->description ) ? $scan_threat->description : null, - 'vulnerability_description' => isset( $scan_threat->vulnerability_description ) ? $scan_threat->vulnerability_description : null, - 'fix_description' => isset( $scan_threat->fix_description ) ? $scan_threat->fix_description : null, - 'payload_subtitle' => isset( $scan_threat->payload_subtitle ) ? $scan_threat->payload_subtitle : null, - 'payload_description' => isset( $scan_threat->payload_description ) ? $scan_threat->payload_description : null, - 'first_detected' => isset( $scan_threat->first_detected ) ? $scan_threat->first_detected : null, - 'fixed_in' => isset( $scan_threat->fixer->fixer ) && 'update' === $scan_threat->fixer->fixer ? $scan_threat->fixer->target : null, - 'severity' => isset( $scan_threat->severity ) ? $scan_threat->severity : null, - 'fixable' => isset( $scan_threat->fixer ) ? $scan_threat->fixer : null, - 'status' => isset( $scan_threat->status ) ? $scan_threat->status : null, - 'filename' => isset( $scan_threat->filename ) ? $scan_threat->filename : null, - 'context' => isset( $scan_threat->context ) ? $scan_threat->context : null, - 'source' => isset( $scan_threat->source ) ? $scan_threat->source : null, - ) - ); - - // Theme and Plugin Threats - if ( ! empty( $scan_threat->extension ) && in_array( $scan_threat->extension->type, array( 'plugin', 'theme' ), true ) ) { - $installed_extension = 'plugin' === $scan_threat->extension->type ? ( $plugins[ $scan_threat->extension->slug ] ?? null ) : ( $themes[ $scan_threat->extension->slug ] ?? null ); - - // If the extension is no longer installed, skip this threat. - // todo: use version_compare() - if ( ! $installed_extension ) { - continue; - } - - // Push the threat to the appropriate extension. - switch ( $scan_threat->extension->type ) { - case 'plugin': - $plugins[ $scan_threat->extension->slug ]->threats[] = clone $threat; - ++$status->num_plugins_threats; - break; - case 'theme': - $themes[ $scan_threat->extension->slug ]->threats[] = clone $threat; - ++$status->num_themes_threats; - break; - default: - break; - } - - $threat->extension = new Extension_Model( - array( - 'name' => isset( $scan_threat->extension->name ) ? $scan_threat->extension->name : null, - 'slug' => isset( $scan_threat->extension->slug ) ? $scan_threat->extension->slug : null, - 'version' => isset( $scan_threat->extension->version ) ? $scan_threat->extension->version : null, - 'type' => $scan_threat->extension->type . 's', - 'checked' => $installed_extension->version === $scan_threat->extension->version, - ) - ); - } elseif ( isset( $threat->signature ) && 'Vulnerable.WP.Core' === $threat->signature ) { - // Vulnerable WordPress Core Version Threats - - // If the core version has changed, skip this threat. - // todo: use version_compare() - if ( $scan_threat->version !== $wp_version ) { - continue; - } - - $core->threats[] = $threat; - } elseif ( ! empty( $threat->filename ) ) { - // File Threats - $files[] = $threat; - } - - $status->threats[] = $threat; - ++$status->num_threats; - } - } - - $status->threats = static::sort_threats( $status->threats ); - - // maintain deprecated properties for backwards compatibility - $status->plugins = array_values( $plugins ); - $status->themes = array_values( $themes ); - $status->core = $core; - $status->files = $files; - - return $status; - } - - /** - * Sort By Threats - * - * @param array $threats Array of threats to sort. - * - * @return array The sorted $threats array. - */ - protected static function sort_threats( $threats ) { - usort( - $threats, - function ( $a, $b ) { - // Order by active status first... - if ( $a->status !== $b->status ) { - return 'active' === $a->status ? -1 : 1; - } - - // ...then by severity... - if ( $a->severity !== $b->severity ) { - return $a->severity > $b->severity ? -1 : 1; - } - - // ...then date added. - if ( $a->first_detected !== $b->first_detected ) { - return strtotime( $a->first_detected ) < strtotime( $b->first_detected ) ? -1 : 1; - } - - return 0; - } - ); - - return $threats; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-status.php deleted file mode 100644 index f5117e02..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-protect-status/src/class-status.php +++ /dev/null @@ -1,300 +0,0 @@ - (int) $option_timestamp; - } - - /** - * Checks if we should consider the stored cache or bypass it - * - * @return boolean - */ - public static function should_use_cache() { - return defined( 'JETPACK_PROTECT_DEV__BYPASS_CACHE' ) && JETPACK_PROTECT_DEV__BYPASS_CACHE ? false : true; - } - - /** - * Gets the current cached status - * - * @return bool|array False if value is not found. Array with values if cache is found. - */ - public static function get_from_options() { - return maybe_unserialize( get_option( static::OPTION_NAME ) ); - } - - /** - * Updated the cached status and its timestamp - * - * @param array $status The new status to be cached. - * @return void - */ - public static function update_status_option( $status ) { - // TODO: Sanitize $status. - update_option( static::OPTION_NAME, maybe_serialize( $status ) ); - $end_date = self::get_cache_end_date_by_status( $status ); - update_option( static::OPTION_TIMESTAMP_NAME, $end_date ); - } - - /** - * Returns the timestamp the cache should expire depending on the current status - * - * Initial empty status, which are returned before the first check was performed, should be cache for less time - * - * @param object $status The response from the server being cached. - * @return int The timestamp when the cache should expire. - */ - public static function get_cache_end_date_by_status( $status ) { - if ( ! is_object( $status ) || empty( $status->last_checked ) ) { - return time() + static::INITIAL_OPTION_EXPIRES_AFTER; - } - return time() + static::OPTION_EXPIRES_AFTER; - } - - /** - * Delete the cached status and its timestamp - * - * @return bool Whether all related status options were successfully deleted. - */ - public static function delete_option() { - $option_deleted = delete_option( static::OPTION_NAME ); - $option_timestamp_deleted = delete_option( static::OPTION_TIMESTAMP_NAME ); - - return $option_deleted && $option_timestamp_deleted; - } - - /** - * Checks the current status to see if there are any threats found - * - * @return boolean - */ - public static function has_threats() { - return 0 < self::get_total_threats(); - } - - /** - * Gets the total number of threats found - * - * @return integer - */ - public static function get_total_threats() { - $status = static::get_status(); - return count( $status->threats ); - } - - /** - * Get all threats combined - * - * @return array - */ - public static function get_all_threats() { - $status = static::get_status(); - return $status->threats; - } - - /** - * Get threats found for WordPress core - * - * @deprecated 0.3.0 - * - * @return array - */ - public static function get_wordpress_threats() { - return self::get_threats( 'core' ); - } - - /** - * Get threats found for themes - * - * @deprecated 0.3.0 - * - * @return array - */ - public static function get_themes_threats() { - return self::get_threats( 'themes' ); - } - - /** - * Get threats found for plugins - * - * @deprecated 0.3.0 - * - * @return array - */ - public static function get_plugins_threats() { - return self::get_threats( 'plugins' ); - } - - /** - * Get threats found for files - * - * @deprecated 0.3.0 - * - * @return array - */ - public static function get_files_threats() { - return self::get_threats( 'files' ); - } - - /** - * Get threats found for plugins - * - * @deprecated 0.3.0 - * - * @return array - */ - public static function get_database_threats() { - return self::get_threats( 'database' ); - } - - /** - * Get the threats for one type of extension or core - * - * @param string $type What threats you want to get. Possible values are 'core', 'themes' and 'plugins'. - * - * @return array - */ - public static function get_threats( $type ) { - $status = static::get_status(); - - if ( in_array( $type, array( 'plugin', 'theme', 'core' ), true ) ) { - return array_filter( - $status->threats, - function ( $threat ) use ( $type ) { - return isset( $threat->extension ) && $type === $threat->extension->type; - } - ); - } - - if ( 'files' === $type ) { - return array_filter( - $status->threats, - function ( $threat ) { - return ! empty( $threat->filename ); - } - ); - } - - if ( 'database' === $type ) { - return array_filter( - $status->threats, - function ( $threat ) { - return ! empty( $threat->table ); - } - ); - } - - return $status->threats; - } - - /** - * Sort By Threats - * - * @deprecated 0.3.0 - * - * @param array $threats Array of threats to sort. - * - * @return array The sorted $threats array. - */ - protected static function sort_threats( $threats ) { - usort( - $threats, - function ( $a, $b ) { - // sort primarily based on the presence of threats - $ret = empty( $a->threats ) <=> empty( $b->threats ); - - // sort secondarily on whether the item has been checked - if ( ! $ret ) { - $ret = $a->checked <=> $b->checked; - } - - return $ret; - } - ); - - return $threats; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/CHANGELOG.md deleted file mode 100644 index f96782f8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/CHANGELOG.md +++ /dev/null @@ -1,292 +0,0 @@ -# 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). - -## [3.0.5] - 2025-03-21 -### Changed -- Internal updates. - -## [3.0.4] - 2025-03-12 -### Changed -- Internal updates. - -## [3.0.3] - 2025-03-05 -### Changed -- Internal updates. - -## [3.0.2] - 2025-02-24 -### Changed -- Update dependencies. - -## [3.0.1] - 2024-11-25 -### Changed -- Updated package dependencies. [#40258] - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.0.5] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.0.4] - 2024-09-05 -### Changed -- Update dependencies. - -## [2.0.3] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [2.0.2] - 2024-04-25 -### Changed -- Update dependencies. - -## [2.0.1] - 2024-03-12 -### Changed -- Internal updates. - -## [2.0.0] - 2023-11-20 -### Changed -- Replaced usage of strpos() with str_starts_with(). [#34135] -- Updated required PHP version to >= 7.0. [#34192] - -## [1.7.27] - 2023-09-19 - -- Minor internal updates. - -## [1.7.26] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.7.25] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.7.24] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.7.23] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.7.22] - 2022-12-19 -### Changed -- Updated package dependencies. - -## [1.7.21] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.7.20] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.7.19] - 2022-11-07 -### Changed -- Updated package dependencies. [#27278] - -## [1.7.18] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.7.17] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.7.16] - 2022-06-14 -### Changed -- Updated package dependencies. [#24529] - -## [1.7.15] - 2022-05-10 - -## [1.7.14] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.7.13] - 2022-04-05 -### Changed -- Updated package dependencies. - -## [1.7.12] - 2022-03-02 -### Changed -- Updated package dependencies. - -## [1.7.11] - 2022-02-22 -### Changed -- Updated package dependencies. - -## [1.7.10] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.7.9] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.7.8] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.7.7] - 2021-11-22 -### Changed -- Updated package dependencies - -## [1.7.6] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.7.5] - 2021-10-26 -### Changed -- Updated package dependencies. - -## [1.7.4] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.7.3] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.7.2] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.7.1] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). - -## [1.7.0] - 2021-06-29 -### Changed -- Allow any argument to be passed. -- Improve documentation. - -## [1.6.1] - 2021-06-15 -### Changed -- Updated package dependencies. - -## [1.6.0] - 2021-05-25 -### Removed -- Removed filter from the final Redirect URL - -## [1.5.5] - 2021-04-27 -### Changed -- Updated package dependencies. - -## [1.5.4] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. -- Userless Connection: Redirect "userless" users to the "Plans" page - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.5.3] - 2021-02-23 - -- CI: Make tests more generic - -## [1.5.2] - 2021-01-26 - -- Update dependencies to latest stable - -## [1.5.1] - 2021-01-26 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.5.0] - 2021-01-05 - -- Update dependency brain/monkey to v2.6.0 -- Pin dependencies -- Packages: Update for PHP 8 testing -- Pin dependency brain/monkey to 2.5.0 - -## [1.4.1] - 2020-11-24 - -- Status: Introduce get_site_suffix method - -## [1.4.0] - 2020-10-27 - -- Masterbar: Add Admin Menu endpoint - -## [1.3.0] - 2020-08-14 - -- Packages: Update filenames after #16810 -- CI: Try collect js coverage -- Docker: Add package testing shortcut - -## [1.2.0] - 2020-06-16 - -- Add a trailing / to jetpack.com/redirect URLs. - -## [1.1.0] - 2020-05-22 - -- add filter to Redirect::get_url - -## 1.0.0 - 2020-04-24 - -- Create Jetpack Redirect package - -[3.0.5]: https://github.com/Automattic/jetpack-redirect/compare/v3.0.4...v3.0.5 -[3.0.4]: https://github.com/Automattic/jetpack-redirect/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-redirect/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-redirect/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-redirect/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-redirect/compare/v2.0.5...v3.0.0 -[2.0.5]: https://github.com/Automattic/jetpack-redirect/compare/v2.0.4...v2.0.5 -[2.0.4]: https://github.com/Automattic/jetpack-redirect/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-redirect/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-redirect/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-redirect/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.27...v2.0.0 -[1.7.27]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.26...v1.7.27 -[1.7.26]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.25...v1.7.26 -[1.7.25]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.24...v1.7.25 -[1.7.24]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.23...v1.7.24 -[1.7.23]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.22...v1.7.23 -[1.7.22]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.21...v1.7.22 -[1.7.21]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.20...v1.7.21 -[1.7.20]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.19...v1.7.20 -[1.7.19]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.18...v1.7.19 -[1.7.18]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.17...v1.7.18 -[1.7.17]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.16...v1.7.17 -[1.7.16]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.15...v1.7.16 -[1.7.15]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.14...v1.7.15 -[1.7.14]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.13...v1.7.14 -[1.7.13]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.12...v1.7.13 -[1.7.12]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.11...v1.7.12 -[1.7.11]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.10...v1.7.11 -[1.7.10]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.9...v1.7.10 -[1.7.9]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.8...v1.7.9 -[1.7.8]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.7...v1.7.8 -[1.7.7]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.6...v1.7.7 -[1.7.6]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.5...v1.7.6 -[1.7.5]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.4...v1.7.5 -[1.7.4]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.3...v1.7.4 -[1.7.3]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.2...v1.7.3 -[1.7.2]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.1...v1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-redirect/compare/v1.7.0...v1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.6.1...v1.7.0 -[1.6.1]: https://github.com/Automattic/jetpack-redirect/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.5.5...v1.6.0 -[1.5.5]: https://github.com/Automattic/jetpack-redirect/compare/v1.5.4...v1.5.5 -[1.5.4]: https://github.com/Automattic/jetpack-redirect/compare/v1.5.3...v1.5.4 -[1.5.3]: https://github.com/Automattic/jetpack-redirect/compare/v1.5.2...v1.5.3 -[1.5.2]: https://github.com/Automattic/jetpack-redirect/compare/v1.5.1...v1.5.2 -[1.5.1]: https://github.com/Automattic/jetpack-redirect/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.4.1...v1.5.0 -[1.4.1]: https://github.com/Automattic/jetpack-redirect/compare/v1.4.0...v1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.1.0...v1.2.0 -[1.1.0]: https://github.com/Automattic/jetpack-redirect/compare/v1.0.0...v1.1.0 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/composer.json deleted file mode 100644 index 0b6f8eae..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/composer.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "name": "automattic/jetpack-redirect", - "description": "Utilities to build URLs to the jetpack.com/redirect/ service", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-status": "^5.0.10" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-redirect", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-redirect/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php deleted file mode 100644 index 7e1ee79e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php +++ /dev/null @@ -1,79 +0,0 @@ -get_site_suffix(); - $args = wp_parse_args( $args, array( 'site' => $site_suffix ) ); - - $source_key = 'source'; - - if ( \str_starts_with( $source, 'https://' ) ) { - $source_key = 'url'; - $source_url = \wp_parse_url( $source ); - - // discard any query and fragments. - $source = 'https://' . $source_url['host'] . ( isset( $source_url['path'] ) ? $source_url['path'] : '' ); - } - - $to_be_added = array( - $source_key => rawurlencode( $source ), - ); - - foreach ( $args as $arg_name => $arg_value ) { - - if ( empty( $arg_value ) ) { - continue; - } - - $to_be_added[ $arg_name ] = rawurlencode( $arg_value ); - - } - - if ( ! empty( $to_be_added ) ) { - $url = add_query_arg( $to_be_added, $url ); - } - - return $url; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/CHANGELOG.md deleted file mode 100644 index 612076b2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/CHANGELOG.md +++ /dev/null @@ -1,245 +0,0 @@ -# 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). - -## [3.0.5] - 2025-03-21 -### Changed -- Internal updates. - -## [3.0.4] - 2025-03-12 -### Changed -- Internal updates. - -## [3.0.3] - 2025-03-05 -### Changed -- Internal updates. - -## [3.0.2] - 2025-02-24 -### Changed -- Update dependencies. - -## [3.0.1] - 2024-11-25 -### Changed -- Updated package dependencies. [#40258] - -## [3.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [2.0.4] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [2.0.3] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [2.0.2] - 2024-04-22 -### Changed -- Internal updates. - -## [2.0.1] - 2024-03-12 -### Changed -- Internal updates. - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.4.25] - 2023-09-19 - -- Minor internal updates. - -## [1.4.24] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.4.23] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.4.22] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.4.21] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.4.20] - 2022-12-19 -### Changed -- Updated package dependencies. - -## [1.4.19] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.4.18] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.4.17] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.4.16] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.4.15] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.4.14] - 2022-01-25 -### Changed -- Updated package dependencies. - -## [1.4.13] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.4.12] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.4.11] - 2021-11-22 -### Changed -- Updated package dependencies - -## [1.4.10] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.4.9] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.4.8] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.4.7] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.4.6] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). - -## [1.4.5] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.4.4] - 2021-04-08 -### Changed -- Packaging and build changes, no change to the package itself. - -## [1.4.3] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.4.2] - 2021-02-05 - -- CI: Make tests more generic - -## [1.4.1] - 2021-01-20 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.4.0] - 2020-12-14 - -- Update dependency brain/monkey to v2.6.0 -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.3.1] - 2020-10-28 - -- Updated PHPCS: Packages and Debugger - -## [1.3.0] - 2020-08-13 - -- CI: Try collect js coverage -- Docker: Add package testing shortcut - -## [1.2.0] - 2020-07-01 - -- Package Unit tests: update test file names to make sure they runs in Travis - -## [1.1.0] - 2020-06-22 - -- PHPCS: Clean up the packages -- PHPCS Updates after WPCS 2.3 - -## [1.0.4] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.0.2] - 2019-10-28 - -- Packages: Add gitattributes files to all packages that need th… - -## [1.0.1] - 2019-09-20 - -- Docs: Unify usage of @package phpdoc tags - -## 1.0.0 - 2019-09-14 - -- Jetpack DNA: Introduce a Roles package - -[3.0.5]: https://github.com/Automattic/jetpack-roles/compare/v3.0.4...v3.0.5 -[3.0.4]: https://github.com/Automattic/jetpack-roles/compare/v3.0.3...v3.0.4 -[3.0.3]: https://github.com/Automattic/jetpack-roles/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-roles/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-roles/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-roles/compare/v2.0.4...v3.0.0 -[2.0.4]: https://github.com/Automattic/jetpack-roles/compare/v2.0.3...v2.0.4 -[2.0.3]: https://github.com/Automattic/jetpack-roles/compare/v2.0.2...v2.0.3 -[2.0.2]: https://github.com/Automattic/jetpack-roles/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-roles/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-roles/compare/v1.4.25...v2.0.0 -[1.4.25]: https://github.com/Automattic/jetpack-roles/compare/v1.4.24...v1.4.25 -[1.4.24]: https://github.com/Automattic/jetpack-roles/compare/v1.4.23...v1.4.24 -[1.4.23]: https://github.com/Automattic/jetpack-roles/compare/v1.4.22...v1.4.23 -[1.4.22]: https://github.com/Automattic/jetpack-roles/compare/v1.4.21...v1.4.22 -[1.4.21]: https://github.com/Automattic/jetpack-roles/compare/v1.4.20...v1.4.21 -[1.4.20]: https://github.com/Automattic/jetpack-roles/compare/v1.4.19...v1.4.20 -[1.4.19]: https://github.com/Automattic/jetpack-roles/compare/v1.4.18...v1.4.19 -[1.4.18]: https://github.com/Automattic/jetpack-roles/compare/v1.4.17...v1.4.18 -[1.4.17]: https://github.com/Automattic/jetpack-roles/compare/v1.4.16...v1.4.17 -[1.4.16]: https://github.com/Automattic/jetpack-roles/compare/v1.4.15...v1.4.16 -[1.4.15]: https://github.com/Automattic/jetpack-roles/compare/v1.4.14...v1.4.15 -[1.4.14]: https://github.com/Automattic/jetpack-roles/compare/v1.4.13...v1.4.14 -[1.4.13]: https://github.com/Automattic/jetpack-roles/compare/v1.4.12...v1.4.13 -[1.4.12]: https://github.com/Automattic/jetpack-roles/compare/v1.4.11...v1.4.12 -[1.4.11]: https://github.com/Automattic/jetpack-roles/compare/v1.4.10...v1.4.11 -[1.4.10]: https://github.com/Automattic/jetpack-roles/compare/v1.4.9...v1.4.10 -[1.4.9]: https://github.com/Automattic/jetpack-roles/compare/v1.4.8...v1.4.9 -[1.4.8]: https://github.com/Automattic/jetpack-roles/compare/v1.4.7...v1.4.8 -[1.4.7]: https://github.com/Automattic/jetpack-roles/compare/v1.4.6...v1.4.7 -[1.4.6]: https://github.com/Automattic/jetpack-roles/compare/v1.4.5...v1.4.6 -[1.4.5]: https://github.com/Automattic/jetpack-roles/compare/v1.4.4...v1.4.5 -[1.4.4]: https://github.com/Automattic/jetpack-roles/compare/v1.4.3...v1.4.4 -[1.4.3]: https://github.com/Automattic/jetpack-roles/compare/v1.4.2...v1.4.3 -[1.4.2]: https://github.com/Automattic/jetpack-roles/compare/v1.4.1...v1.4.2 -[1.4.1]: https://github.com/Automattic/jetpack-roles/compare/v1.4.0...v1.4.1 -[1.4.0]: https://github.com/Automattic/jetpack-roles/compare/v1.3.1...v1.4.0 -[1.3.1]: https://github.com/Automattic/jetpack-roles/compare/v1.3.0...v1.3.1 -[1.3.0]: https://github.com/Automattic/jetpack-roles/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-roles/compare/v1.1.0...v1.2.0 -[1.1.0]: https://github.com/Automattic/jetpack-roles/compare/v1.0.4...v1.1.0 -[1.0.4]: https://github.com/Automattic/jetpack-roles/compare/v1.0.2...v1.0.4 -[1.0.2]: https://github.com/Automattic/jetpack-roles/compare/v1.0.1...v1.0.2 -[1.0.1]: https://github.com/Automattic/jetpack-roles/compare/v1.0.0...v1.0.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/composer.json deleted file mode 100644 index 7ec25616..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/composer.json +++ /dev/null @@ -1,46 +0,0 @@ -{ - "name": "automattic/jetpack-roles", - "description": "Utilities, related with user roles and capabilities.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-roles", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-roles/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "3.0.x-dev" - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php deleted file mode 100644 index 7bce3462..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php +++ /dev/null @@ -1,81 +0,0 @@ - 'manage_options', - 'editor' => 'edit_others_posts', - 'author' => 'publish_posts', - 'contributor' => 'edit_posts', - 'subscriber' => 'read', - ); - - /** - * Get the role of the current user. - * - * @access public - * - * @return string|boolean Current user's role, false if not enough capabilities for any of the roles. - */ - public function translate_current_user_to_role() { - foreach ( $this->capability_translations as $role => $cap ) { - if ( current_user_can( $role ) || current_user_can( $cap ) ) { - return $role; - } - } - - return false; - } - - /** - * Get the role of a particular user. - * - * @access public - * - * @param \WP_User $user User object. - * @return string|boolean User's role, false if not enough capabilities for any of the roles. - */ - public function translate_user_to_role( $user ) { - foreach ( $this->capability_translations as $role => $cap ) { - if ( user_can( $user, $role ) || user_can( $user, $cap ) ) { - return $role; - } - } - - return false; - } - - /** - * Get the minimum capability for a role. - * - * @access public - * - * @param string $role Role name. - * @return string|boolean Capability, false if role isn't mapped to any capabilities. - */ - public function translate_role_to_cap( $role ) { - if ( ! isset( $this->capability_translations[ $role ] ) ) { - return false; - } - - return $this->capability_translations[ $role ]; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/CHANGELOG.md deleted file mode 100644 index 6b3ef122..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/CHANGELOG.md +++ /dev/null @@ -1,555 +0,0 @@ -# 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). - -## [5.0.10] - 2025-03-21 -### Changed -- Internal updates. - -## [5.0.9] - 2025-03-18 -### Changed -- Internal updates. - -## [5.0.8] - 2025-03-17 -### Changed -- Internal updates. - -## [5.0.7] - 2025-03-12 -### Changed -- Internal updates. - -## [5.0.6] - 2025-03-05 -### Changed -- Internal updates. - -## [5.0.5] - 2025-03-03 -### Fixed -- Hosting provider checks: Avoid PHP warnings in local environments. [#41994] - -## [5.0.4] - 2025-02-24 -### Changed -- Host detection: Look for specific external hosting provider only when required. [#41890] - -## [5.0.3] - 2025-02-03 -### Fixed -- Code: Remove extra params on function calls. [#41263] - -## [5.0.2] - 2025-01-20 -### Changed -- Code: Use function-style exit() and die() with a default status code of 0. [#41167] - -## [5.0.1] - 2024-11-25 -### Changed -- Updated package dependencies. [#40258] - -## [5.0.0] - 2024-11-14 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [4.0.3] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [4.0.2] - 2024-09-23 -### Changed -- Update dependencies. - -## [4.0.1] - 2024-09-06 -### Removed -- Removed usage of _deprecated_function when deprecating Status::is_onboarding [#39272] - -## [4.0.0] - 2024-09-05 -### Deprecated -- Deprecated Jetpack Onboarding system. [#39229] - -## [3.3.4] - 2024-08-23 -### Changed -- Updated package dependencies. [#39004] - -## [3.3.3] - 2024-08-19 -### Changed -- Internal updates. - -## [3.3.2] - 2024-06-24 -### Changed -- Internal updates. - -## [3.3.1] - 2024-06-21 -### Added -- Check for active modules among the unavailable ones. [#37358] - -## [3.3.0] - 2024-06-10 -### Deprecated -- Deprecated is_staging_site [#37023] - -## [3.2.3] - 2024-06-03 -### Removed -- Remove the Identity Crisis dev dependency. [#37654] - -## [3.2.2] - 2024-05-29 -### Changed -- Phab baseline file update. [#36968] - -## [3.2.1] - 2024-05-28 -### Changed -- Internal updates. - -## [3.2.0] - 2024-05-22 -### Deprecated -- Jetpack: Deprecated Errors class. [#37451] - -## [3.1.0] - 2024-05-20 -### Added -- Add the 'is_current_request_activating_plugin_from_plugins_screen' method extracted from the Plugin Install package. [#37430] - -## [3.0.3] - 2024-05-08 -### Fixed -- Status: Added check for compatibility reasons [#37256] - -## [3.0.2] - 2024-05-06 -### Added -- Add new method used to track allowed domains for API access. [#36924] - -## [3.0.1] - 2024-04-30 -### Changed -- Internal updates. - -## [3.0.0] - 2024-04-25 -### Added -- Add is_automattician_feature_flags_only on Jetpack sites as an alternative to is_automattician present on simple sites. [#34798] - -### Removed -- Remove methods deprecated long ago. [#36985] - -## [2.2.2] - 2024-04-22 -### Changed -- Internal updates. - -## [2.2.1] - 2024-04-08 -### Changed -- Internal updates. - -## [2.2.0] - 2024-03-22 -### Added -- Add support for A8C for Agencies source parameter. [#36491] - -## [2.1.3] - 2024-03-20 -### Changed -- Internal updates. - -## [2.1.2] - 2024-03-12 -### Changed -- Internal updates. - -## [2.1.1] - 2024-03-01 -### Fixed -- Avoid issues when the dns_get_record function is not defined [#36019] - -## [2.1.0] - 2024-01-18 -### Added -- Add hosting provider check. [#34864] - -## [2.0.2] - 2023-12-03 -### Fixed -- Module active checks should always be true on WordPress.com simple sites. [#34248] - -## [2.0.1] - 2023-11-21 -### Changed -- Added a note of non-usage of PHP8+ functions yet. [#34137] -- Replaced usage of substr() with str_starts_with() and str_ends_with(). [#34207] - -## [2.0.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [1.19.0] - 2023-11-13 -### Added -- Added Host::get_source_query() to return the 'source' query param from the current URL. [#33984] - -## [1.18.5] - 2023-09-25 -### Changed -- Add 127.0.0.1 into the list of known local domains. [#32898] -- WP.com Compatibility: Abort out early checking if Protect is active. WP.com's protection is not site option based. [#33196] - -## [1.18.4] - 2023-09-19 - -- Minor internal updates. - -## [1.18.3] - 2023-09-11 -### Changed -- General: remove backwards-compatibility function checks now that the package supports WP 6.2. [#32772] - -## [1.18.2] - 2023-09-04 -### Fixed -- Exclude domains starting with live from known Pantheon staging domains [#32789] - -## [1.18.1] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.18.0] - 2023-07-18 -### Added -- Transferred 'get_calypso_env()' method from Jetpack plugin. [#31906] - -## [1.17.2] - 2023-06-19 -### Changed -- Use Plans package to detect feature support. [#31213] - -## [1.17.1] - 2023-05-11 -### Changed -- PHP 8.1 compatibility updates [#30517] - -## [1.17.0] - 2023-04-17 -### Changed -- When Jetpack is available, `Modules::get()` no longer translates `module_tags`. Use Jetpack's `jetpack_get_module_i18n_tag()` function if you need translations. [#30067] - -## [1.16.4] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.16.3] - 2023-03-28 -### Changed -- Move brute force protection into WAF package. [#28401] - -## [1.16.2] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.16.1] - 2023-01-23 -### Added -- Add new filters for the latest status methods [#28328] - -## [1.16.0] - 2023-01-16 -### Added -- Add 2 new methods to detect whether a site is private or not. [#28322] - -## [1.15.4] - 2023-01-11 -### Changed -- Modules: Allow for deactivating multiple plugins when activating a module. [#28181] - -## [1.15.3] - 2022-12-19 -### Changed -- Updated package dependencies. - -## [1.15.2] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.15.1] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.15.0] - 2022-11-07 -### Added -- WordPress.com: add checks for Simple or either Simple/WoA. [#27278] - -## [1.14.3] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [1.14.2] - 2022-07-19 -### Changed -- Update logic in `is_woa_site` function for host changes [#25067] - -## [1.14.1] - 2022-06-21 -### Changed -- Renaming master to trunk. - -## [1.14.0] - 2022-06-14 -### Fixed -- Moved the connection_url_redirect action handling to the connection package. [#24529] - -## [1.13.6] - 2022-05-24 -### Added -- Allow plugins to filter the list of available modules. Only activate and consider active modules that are available [#24454] - -## [1.13.5] - 2022-05-20 -### Changed -- Modules: Make activate() method Jetpack plugin agnostic. Allowing standalone plugins to use it without Jetpack. - -## [1.13.4] - 2022-05-19 -### Added -- PHPCS updates. [#24418] - -## [1.13.3] - 2022-05-10 - -## [1.13.2] - 2022-04-26 -### Changed -- Updated package dependencies. - -## [1.13.1] - 2022-04-19 -### Changed -- PHPCS: Fix `WordPress.Security.ValidatedSanitizedInput` - -## [1.13.0] - 2022-04-05 -### Added -- Created Modules and File modules for managing those resources - -## [1.12.0] - 2022-03-02 -### Added -- Cache return values (per blog) from various status methods. - -## [1.11.2] - 2022-02-28 -### Fixed -- Re-doing 1.11.1 to fixup a bad release. - -## [1.11.1] - 2022-02-28 -### Fixed -- Remove trailing semicolor form site suffix. - -## [1.11.0] - 2022-02-22 -### Added -- Add methods to distinguish Newspack and VIP sites. - -## [1.10.0] - 2022-01-25 -### Added -- Added Visitor class for status regarding the site visitor. - -## [1.9.5] - 2022-01-04 -### Changed -- Switch to pcov for code coverage. -- Updated package dependencies - -## [1.9.4] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.9.3] - 2021-11-22 -### Changed -- Updated package dependencies - -## [1.9.2] - 2021-11-16 -### Changed -- Add a function_exists check before calling wp_get_environment_type - -## [1.9.1] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.9.0] - 2021-10-26 -### Added -- Added Host class for reporting known hosting environment information. - -## [1.8.4] - 2021-10-13 -### Changed -- Updated package dependencies. - -## [1.8.3] - 2021-10-12 -### Changed -- Updated package dependencies - -## [1.8.2] - 2021-09-28 -### Changed -- Updated package dependencies. - -## [1.8.1] - 2021-08-30 -### Changed -- Run composer update on test-php command instead of phpunit -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). -- update annotations versions - -## [1.8.0] - 2021-06-15 -### Changed -- Update callback to Jetpack to new Identity_Crisis class. - -## [1.7.6] - 2021-05-25 -### Changed -- Updated package dependencies. - -## [1.7.5] - 2021-04-27 -### Deprecated -- Deprecates is_no_user_testing_mode - -## [1.7.4] - 2021-04-08 -### Changed -- Packaging and build changes, no change to the package itself. - -## [1.7.3] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies - -### Changed -- Update package dependencies. - -### Fixed -- Use `composer update` rather than `install` in scripts, as composer.lock isn't checked in. - -## [1.7.2] - 2021-02-05 - -- CI: Make tests more generic - -## [1.7.1] - 2021-01-20 - -- Add mirror-repo information to all current composer packages -- Monorepo: Reorganize all projects - -## [1.7.0] - 2020-12-14 - -- Update dependency brain/monkey to v2.6.0 -- Pin dependencies -- Packages: Update for PHP 8 testing - -## [1.6.0] - 2020-11-23 - -- Status: Introduce get_site_suffix method -- Status: Fix test failure -- Status: Improve the staging site detection -- General: update minimum required version to WordPress 5.5 -- Add the no_user_testing mode -- Status: Add a couple of test cases for staging site detection -- Update dependency brain/monkey to v2.5.0 -- Updated PHPCS: Packages and Debugger - -## [1.5.0] - 2020-10-13 - -- Also use Core `wp_get_environment_type` for local - -## [1.4.0] - 2020-08-13 - -- CI: Try collect js coverage - -## [1.3.0] - 2020-07-28 - -- Core Compat: Site Environment - -## [1.2.0] - 2020-06-22 - -- PHPCS: Clean up the packages -- Staging Sites: add newspack staging to the list of known providers - -## [1.1.1] - 2020-01-27 - -- Pin dependency brain/monkey to 2.4.0 - -## [1.1.0] - 2020-01-14 - -- Packages: Various improvements for wp.com or self-contained consumers - -## [1.0.4] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.0.3] - 2019-10-28 - -- Packages: Add gitattributes files to all packages that need th… - -## [1.0.2] - 2019-10-23 - -- Use spread operator instead of func_get_args - -## [1.0.1] - 2019-09-20 - -- Docs: Unify usage of @package phpdoc tags - -## 1.0.0 - 2019-09-14 - -- Packages: Introduce a status package - -[5.0.10]: https://github.com/Automattic/jetpack-status/compare/v5.0.9...v5.0.10 -[5.0.9]: https://github.com/Automattic/jetpack-status/compare/v5.0.8...v5.0.9 -[5.0.8]: https://github.com/Automattic/jetpack-status/compare/v5.0.7...v5.0.8 -[5.0.7]: https://github.com/Automattic/jetpack-status/compare/v5.0.6...v5.0.7 -[5.0.6]: https://github.com/Automattic/jetpack-status/compare/v5.0.5...v5.0.6 -[5.0.5]: https://github.com/Automattic/jetpack-status/compare/v5.0.4...v5.0.5 -[5.0.4]: https://github.com/Automattic/jetpack-status/compare/v5.0.3...v5.0.4 -[5.0.3]: https://github.com/Automattic/jetpack-status/compare/v5.0.2...v5.0.3 -[5.0.2]: https://github.com/Automattic/jetpack-status/compare/v5.0.1...v5.0.2 -[5.0.1]: https://github.com/Automattic/jetpack-status/compare/v5.0.0...v5.0.1 -[5.0.0]: https://github.com/Automattic/jetpack-status/compare/v4.0.3...v5.0.0 -[4.0.3]: https://github.com/Automattic/jetpack-status/compare/v4.0.2...v4.0.3 -[4.0.2]: https://github.com/Automattic/jetpack-status/compare/v4.0.1...v4.0.2 -[4.0.1]: https://github.com/Automattic/jetpack-status/compare/v4.0.0...v4.0.1 -[4.0.0]: https://github.com/Automattic/jetpack-status/compare/v3.3.4...v4.0.0 -[3.3.4]: https://github.com/Automattic/jetpack-status/compare/v3.3.3...v3.3.4 -[3.3.3]: https://github.com/Automattic/jetpack-status/compare/v3.3.2...v3.3.3 -[3.3.2]: https://github.com/Automattic/jetpack-status/compare/v3.3.1...v3.3.2 -[3.3.1]: https://github.com/Automattic/jetpack-status/compare/v3.3.0...v3.3.1 -[3.3.0]: https://github.com/Automattic/jetpack-status/compare/v3.2.3...v3.3.0 -[3.2.3]: https://github.com/Automattic/jetpack-status/compare/v3.2.2...v3.2.3 -[3.2.2]: https://github.com/Automattic/jetpack-status/compare/v3.2.1...v3.2.2 -[3.2.1]: https://github.com/Automattic/jetpack-status/compare/v3.2.0...v3.2.1 -[3.2.0]: https://github.com/Automattic/jetpack-status/compare/v3.1.0...v3.2.0 -[3.1.0]: https://github.com/Automattic/jetpack-status/compare/v3.0.3...v3.1.0 -[3.0.3]: https://github.com/Automattic/jetpack-status/compare/v3.0.2...v3.0.3 -[3.0.2]: https://github.com/Automattic/jetpack-status/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-status/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-status/compare/v2.2.2...v3.0.0 -[2.2.2]: https://github.com/Automattic/jetpack-status/compare/v2.2.1...v2.2.2 -[2.2.1]: https://github.com/Automattic/jetpack-status/compare/v2.2.0...v2.2.1 -[2.2.0]: https://github.com/Automattic/jetpack-status/compare/v2.1.3...v2.2.0 -[2.1.3]: https://github.com/Automattic/jetpack-status/compare/v2.1.2...v2.1.3 -[2.1.2]: https://github.com/Automattic/jetpack-status/compare/v2.1.1...v2.1.2 -[2.1.1]: https://github.com/Automattic/jetpack-status/compare/v2.1.0...v2.1.1 -[2.1.0]: https://github.com/Automattic/jetpack-status/compare/v2.0.2...v2.1.0 -[2.0.2]: https://github.com/Automattic/jetpack-status/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-status/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-status/compare/v1.19.0...v2.0.0 -[1.19.0]: https://github.com/Automattic/jetpack-status/compare/v1.18.5...v1.19.0 -[1.18.5]: https://github.com/Automattic/jetpack-status/compare/v1.18.4...v1.18.5 -[1.18.4]: https://github.com/Automattic/jetpack-status/compare/v1.18.3...v1.18.4 -[1.18.3]: https://github.com/Automattic/jetpack-status/compare/v1.18.2...v1.18.3 -[1.18.2]: https://github.com/Automattic/jetpack-status/compare/v1.18.1...v1.18.2 -[1.18.1]: https://github.com/Automattic/jetpack-status/compare/v1.18.0...v1.18.1 -[1.18.0]: https://github.com/Automattic/jetpack-status/compare/v1.17.2...v1.18.0 -[1.17.2]: https://github.com/Automattic/jetpack-status/compare/v1.17.1...v1.17.2 -[1.17.1]: https://github.com/Automattic/jetpack-status/compare/v1.17.0...v1.17.1 -[1.17.0]: https://github.com/Automattic/jetpack-status/compare/v1.16.4...v1.17.0 -[1.16.4]: https://github.com/Automattic/jetpack-status/compare/v1.16.3...v1.16.4 -[1.16.3]: https://github.com/Automattic/jetpack-status/compare/v1.16.2...v1.16.3 -[1.16.2]: https://github.com/Automattic/jetpack-status/compare/v1.16.1...v1.16.2 -[1.16.1]: https://github.com/Automattic/jetpack-status/compare/v1.16.0...v1.16.1 -[1.16.0]: https://github.com/Automattic/jetpack-status/compare/v1.15.4...v1.16.0 -[1.15.4]: https://github.com/Automattic/jetpack-status/compare/v1.15.3...v1.15.4 -[1.15.3]: https://github.com/Automattic/jetpack-status/compare/v1.15.2...v1.15.3 -[1.15.2]: https://github.com/Automattic/jetpack-status/compare/v1.15.1...v1.15.2 -[1.15.1]: https://github.com/Automattic/jetpack-status/compare/v1.15.0...v1.15.1 -[1.15.0]: https://github.com/Automattic/jetpack-status/compare/v1.14.3...v1.15.0 -[1.14.3]: https://github.com/Automattic/jetpack-status/compare/v1.14.2...v1.14.3 -[1.14.2]: https://github.com/Automattic/jetpack-status/compare/v1.14.1...v1.14.2 -[1.14.1]: https://github.com/Automattic/jetpack-status/compare/v1.14.0...v1.14.1 -[1.14.0]: https://github.com/Automattic/jetpack-status/compare/v1.13.6...v1.14.0 -[1.13.6]: https://github.com/Automattic/jetpack-status/compare/v1.13.5...v1.13.6 -[1.13.5]: https://github.com/Automattic/jetpack-status/compare/v1.13.4...v1.13.5 -[1.13.4]: https://github.com/Automattic/jetpack-status/compare/v1.13.3...v1.13.4 -[1.13.3]: https://github.com/Automattic/jetpack-status/compare/v1.13.2...v1.13.3 -[1.13.2]: https://github.com/Automattic/jetpack-status/compare/v1.13.1...v1.13.2 -[1.13.1]: https://github.com/Automattic/jetpack-status/compare/v1.13.0...v1.13.1 -[1.13.0]: https://github.com/Automattic/jetpack-status/compare/v1.12.0...v1.13.0 -[1.12.0]: https://github.com/Automattic/jetpack-status/compare/v1.11.2...v1.12.0 -[1.11.2]: https://github.com/Automattic/jetpack-status/compare/v1.11.1...v1.11.2 -[1.11.1]: https://github.com/Automattic/jetpack-status/compare/v1.11.0...v1.11.1 -[1.11.0]: https://github.com/Automattic/jetpack-status/compare/v1.10.0...v1.11.0 -[1.10.0]: https://github.com/Automattic/jetpack-status/compare/v1.9.5...v1.10.0 -[1.9.5]: https://github.com/Automattic/jetpack-status/compare/v1.9.4...v1.9.5 -[1.9.4]: https://github.com/Automattic/jetpack-status/compare/v1.9.3...v1.9.4 -[1.9.3]: https://github.com/Automattic/jetpack-status/compare/v1.9.2...v1.9.3 -[1.9.2]: https://github.com/Automattic/jetpack-status/compare/v1.9.1...v1.9.2 -[1.9.1]: https://github.com/Automattic/jetpack-status/compare/v1.9.0...v1.9.1 -[1.9.0]: https://github.com/Automattic/jetpack-status/compare/v1.8.4...v1.9.0 -[1.8.4]: https://github.com/Automattic/jetpack-status/compare/v1.8.3...v1.8.4 -[1.8.3]: https://github.com/Automattic/jetpack-status/compare/v1.8.2...v1.8.3 -[1.8.2]: https://github.com/Automattic/jetpack-status/compare/v1.8.1...v1.8.2 -[1.8.1]: https://github.com/Automattic/jetpack-status/compare/v1.8.0...v1.8.1 -[1.8.0]: https://github.com/Automattic/jetpack-status/compare/v1.7.6...v1.8.0 -[1.7.6]: https://github.com/Automattic/jetpack-status/compare/v1.7.5...v1.7.6 -[1.7.5]: https://github.com/Automattic/jetpack-status/compare/v1.7.4...v1.7.5 -[1.7.4]: https://github.com/Automattic/jetpack-status/compare/v1.7.3...v1.7.4 -[1.7.3]: https://github.com/Automattic/jetpack-status/compare/v1.7.2...v1.7.3 -[1.7.2]: https://github.com/Automattic/jetpack-status/compare/v1.7.1...v1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-status/compare/v1.7.0...v1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-status/compare/v1.6.0...v1.7.0 -[1.6.0]: https://github.com/Automattic/jetpack-status/compare/v1.5.0...v1.6.0 -[1.5.0]: https://github.com/Automattic/jetpack-status/compare/v1.4.0...v1.5.0 -[1.4.0]: https://github.com/Automattic/jetpack-status/compare/v1.3.0...v1.4.0 -[1.3.0]: https://github.com/Automattic/jetpack-status/compare/v1.2.0...v1.3.0 -[1.2.0]: https://github.com/Automattic/jetpack-status/compare/v1.1.1...v1.2.0 -[1.1.1]: https://github.com/Automattic/jetpack-status/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-status/compare/v1.0.4...v1.1.0 -[1.0.4]: https://github.com/Automattic/jetpack-status/compare/v1.0.3...v1.0.4 -[1.0.3]: https://github.com/Automattic/jetpack-status/compare/v1.0.2...v1.0.3 -[1.0.2]: https://github.com/Automattic/jetpack-status/compare/v1.0.1...v1.0.2 -[1.0.1]: https://github.com/Automattic/jetpack-status/compare/v1.0.0...v1.0.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/composer.json deleted file mode 100644 index 36689584..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/composer.json +++ /dev/null @@ -1,56 +0,0 @@ -{ - "name": "automattic/jetpack-status", - "description": "Used to retrieve information about the current status of Jetpack and the site overall.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-constants": "^3.0.5" - }, - "require-dev": { - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-connection": "@dev", - "automattic/jetpack-plans": "@dev", - "automattic/jetpack-ip": "^0.4.6", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-status", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-status/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "5.0.x-dev" - }, - "dependencies": { - "test-only": [ - "packages/connection", - "packages/plans" - ] - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-cache.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-cache.php deleted file mode 100644 index e28f69f5..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-cache.php +++ /dev/null @@ -1,54 +0,0 @@ -admin_url(); - $bits = wp_parse_url( $admin_url ); - - if ( is_array( $bits ) ) { - $path = ( isset( $bits['path'] ) ) ? dirname( $bits['path'] ) : null; - $domain = ( isset( $bits['host'] ) ) ? $bits['host'] : null; - } else { - $path = null; - $domain = null; - } - } - - // Extract state from cookies and delete cookies. - if ( isset( $_COOKIE['jetpackState'] ) && is_array( $_COOKIE['jetpackState'] ) ) { - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- User should sanitize if necessary. - $yum = wp_unslash( $_COOKIE['jetpackState'] ); - unset( $_COOKIE['jetpackState'] ); - foreach ( $yum as $k => $v ) { - if ( strlen( $v ) ) { - $state[ $k ] = $v; - } - setcookie( "jetpackState[$k]", false, 0, $path, $domain, is_ssl(), true ); - } - } - - if ( $restate ) { - foreach ( $state as $k => $v ) { - setcookie( "jetpackState[$k]", $v, 0, $path, $domain, is_ssl(), true ); - } - return; - } - - // Get a state variable. - if ( isset( $key ) && ! isset( $value ) ) { - if ( array_key_exists( $key, $state ) ) { - return $state[ $key ]; - } - return null; - } - - // Set a state variable. - if ( isset( $key ) && isset( $value ) ) { - if ( is_array( $value ) && isset( $value[0] ) ) { - $value = $value[0]; - } - $state[ $key ] = $value; - if ( ! headers_sent() ) { - if ( $this->should_set_cookie( $key ) ) { - setcookie( "jetpackState[$key]", $value, 0, $path, $domain, is_ssl(), true ); - } - } - } - } - - /** - * Determines whether the jetpackState[$key] value should be added to the - * cookie. - * - * @param string $key The state key. - * - * @return boolean Whether the value should be added to the cookie. - */ - public function should_set_cookie( $key ) { - global $current_screen; - $page = isset( $current_screen->base ) ? $current_screen->base : null; - - if ( 'toplevel_page_jetpack' === $page && 'display_update_modal' === $key ) { - return false; - } - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-errors.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-errors.php deleted file mode 100644 index d2208017..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-errors.php +++ /dev/null @@ -1,49 +0,0 @@ -is_atomic_platform() && Constants::is_true( 'WPCOMSH__PLUGIN_FILE' ); - Cache::set( 'is_woa_site', $ret ); - } - return $ret; - } - - /** - * Determine if the site is hosted on the Atomic hosting platform. - * - * @since 1.9.0 - * - * @return bool - */ - public function is_atomic_platform() { - return Constants::is_true( 'ATOMIC_SITE_ID' ) && Constants::is_true( 'ATOMIC_CLIENT_ID' ); - } - - /** - * Determine if this is a Newspack site. - * - * @return bool - */ - public function is_newspack_site() { - return Constants::is_defined( 'NEWSPACK_PLUGIN_FILE' ); - } - - /** - * Determine if this is a VIP-hosted site. - * - * @return bool - */ - public function is_vip_site() { - return Constants::is_defined( 'WPCOM_IS_VIP_ENV' ) && true === Constants::get_constant( 'WPCOM_IS_VIP_ENV' ); - } - - /** - * Determine if this is a Simple platform site. - * - * @return bool - */ - public function is_wpcom_simple() { - return Constants::is_defined( 'IS_WPCOM' ) && true === Constants::get_constant( 'IS_WPCOM' ); - } - - /** - * Determine if this is a WordPress.com site. - * - * Includes both Simple and WoA platforms. - * - * @return bool - */ - public function is_wpcom_platform() { - return $this->is_wpcom_simple() || $this->is_woa_site(); - } - - /** - * Add all wordpress.com environments to the safe redirect allowed list. - * - * To be used with a filter of allowed domains for a redirect. - * - * @param array $domains Allowed WP.com Environments. - */ - public static function allow_wpcom_environments( $domains ) { - $domains[] = 'wordpress.com'; - $domains[] = 'jetpack.wordpress.com'; - $domains[] = 'wpcalypso.wordpress.com'; - $domains[] = 'horizon.wordpress.com'; - $domains[] = 'calypso.localhost'; - return $domains; - } - - /** - * Return Calypso environment value; used for developing Jetpack and pairing - * it with different Calypso environments, such as localhost. - * - * @since 1.18.0 - * - * @return string Calypso environment - */ - public function get_calypso_env() { - // phpcs:disable WordPress.Security.NonceVerification.Recommended -- Nonce is not required; only used for changing environments. - if ( isset( $_GET['calypso_env'] ) ) { - return sanitize_key( $_GET['calypso_env'] ); - } - // phpcs:enable WordPress.Security.NonceVerification.Recommended - - if ( getenv( 'CALYPSO_ENV' ) ) { - return sanitize_key( getenv( 'CALYPSO_ENV' ) ); - } - - if ( defined( 'CALYPSO_ENV' ) && CALYPSO_ENV ) { - return sanitize_key( CALYPSO_ENV ); - } - - return ''; - } - - /** - * Return source query param value from the URL if exists in the allowed sources list. - * - * @return string "source" query param value - */ - public function get_source_query() { - // phpcs:disable WordPress.Security.NonceVerification.Recommended - $allowed_sources = array( 'jetpack-manage', 'a8c-for-agencies' ); - if ( isset( $_GET['source'] ) && in_array( $_GET['source'], $allowed_sources, true ) ) { - return sanitize_key( $_GET['source'] ); - } - - return ''; - } - - /** - * Returns an array of nameservers for the current site. - * - * @param string $domain The domain of the site to check. - * @return array - */ - public function get_nameserver_dns_records( $domain ) { - if ( ! function_exists( 'dns_get_record' ) ) { - return array(); - } - - $dns_records = dns_get_record( $domain, DNS_NS ); // Fetches the DNS records of type NS (Name Server) - if ( false === $dns_records ) { - return array(); - } - - $nameservers = array(); - foreach ( $dns_records as $record ) { - if ( isset( $record['target'] ) ) { - $nameservers[] = $record['target']; // Adds the nameserver to the array - } - } - - return $nameservers; // Returns an array of nameserver names - } - - /** - * Given a DNS entry, will return a hosting provider if one can be determined. Otherwise, will return 'unknown'. - * Sourced from: fbhepr%2Skers%2Sjcpbz%2Sjc%2Qpbagrag%2Syvo%2Subfgvat%2Qcebivqre%2Sanzrfreiref.cuc-og - * - * @param string $domain The domain of the site to check. - * @return string The hosting provider of 'unknown'. - */ - public function get_hosting_provider_by_nameserver( $domain ) { - $known_nameservers = array( - 'bluehost' => array( - '.bluehost.com', - ), - 'dreamhost' => array( - '.dreamhost.com', - ), - 'mediatemple' => array( - '.mediatemple.net', - ), - 'xserver' => array( - '.xserver.jp', - ), - 'namecheap' => array( - '.namecheaphosting.com', - ), - 'hostmonster' => array( - '.hostmonster.com', - ), - 'justhost' => array( - '.justhost.com', - ), - 'digitalocean' => array( - '.digitalocean.com', - ), - 'one' => array( - '.one.com', - ), - 'hostpapa' => array( - '.hostpapa.com', - ), - 'siteground' => array( - '.sgcloud.net', - '.sgedu.site', - '.sgsrv1.com', - '.sgvps.net', - '.siteground.biz', - '.siteground.net', - '.siteground.eu', - ), - 'inmotion' => array( - '.inmotionhosting.com', - ), - 'ionos' => array( - '.ui-dns.org', - '.ui-dns.de', - '.ui-dns.biz', - '.ui-dns.com', - ), - ); - - $dns_records = $this->get_nameserver_dns_records( $domain ); - $dns_records = array_map( 'strtolower', $dns_records ); - - foreach ( $known_nameservers as $host => $ns_patterns ) { - foreach ( $ns_patterns as $ns_pattern ) { - foreach ( $dns_records as $record ) { - if ( false !== strpos( $record, $ns_pattern ) ) { - return $host; - } - } - } - } - - return 'unknown'; - } - - /** - * Returns a guess of the hosting provider for the current site based on various checks. - * - * @since 5.0.4 Added $guess parameter. - * - * @param bool $guess Whether to guess the hosting provider. - * - * @return string - */ - public function get_known_host_guess( $guess = true ) { - $host = Cache::get( 'host_guess' ); - - if ( null !== $host ) { - return $host; - } - - // First, let's check if we can recognize provider manually: - switch ( true ) { - case $this->is_woa_site(): - $provider = 'woa'; - break; - case $this->is_atomic_platform(): - $provider = 'atomic'; - break; - case $this->is_newspack_site(): - $provider = 'newspack'; - break; - case $this->is_vip_site(): - $provider = 'vip'; - break; - case $this->is_wpcom_simple(): - case $this->is_wpcom_platform(): - $provider = 'wpcom'; - break; - default: - $provider = 'unknown'; - break; - } - - // Second, let's check if we can recognize provider by nameservers. - // Only do this if we're asked to guess. - $domain = isset( $_SERVER['SERVER_NAME'] ) ? sanitize_text_field( wp_unslash( $_SERVER['SERVER_NAME'] ) ) : ''; - if ( $provider === 'unknown' && ! empty( $domain ) && $guess ) { - $provider = $this->get_hosting_provider_by_nameserver( $domain ); - } - - Cache::set( 'host_guess', $provider ); - return $provider; - } - - /** - * Add public-api.wordpress.com to the safe redirect allowed list - only added when someone allows API access. - * - * @since 3.0.2 Ported from Jetpack to the Status package. - * - * To be used with a filter of allowed domains for a redirect. - * - * @param array $domains Allowed WP.com Environments. - * - * @return array - */ - public static function allow_wpcom_public_api_domain( $domains ) { - $domains[] = 'public-api.wordpress.com'; - return $domains; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-modules.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-modules.php deleted file mode 100644 index 80fb33b8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-modules.php +++ /dev/null @@ -1,609 +0,0 @@ -get_path( $this->get_slug( $module ) ); - - if ( isset( $modules_details[ $module ] ) ) { - $mod = $modules_details[ $module ]; - } else { - $mod = jetpack_get_module_info( $module ); - - if ( null === $mod ) { - // Try to get the module info from the file as a fallback. - $mod = $this->get_file_data( $file, jetpack_get_all_module_header_names() ); - - if ( empty( $mod['name'] ) ) { - // No info for this module. - return false; - } - } - - $mod['sort'] = empty( $mod['sort'] ) ? 10 : (int) $mod['sort']; - $mod['recommendation_order'] = empty( $mod['recommendation_order'] ) ? 20 : (int) $mod['recommendation_order']; - $mod['deactivate'] = empty( $mod['deactivate'] ); - $mod['free'] = empty( $mod['free'] ); - $mod['requires_connection'] = ( ! empty( $mod['requires_connection'] ) && 'No' === $mod['requires_connection'] ) ? false : true; - $mod['requires_user_connection'] = ( empty( $mod['requires_user_connection'] ) || 'No' === $mod['requires_user_connection'] ) ? false : true; - - if ( empty( $mod['auto_activate'] ) || ! in_array( strtolower( $mod['auto_activate'] ), array( 'yes', 'no', 'public' ), true ) ) { - $mod['auto_activate'] = 'No'; - } else { - $mod['auto_activate'] = (string) $mod['auto_activate']; - } - - if ( $mod['module_tags'] ) { - $mod['module_tags'] = explode( ',', $mod['module_tags'] ); - $mod['module_tags'] = array_map( 'trim', $mod['module_tags'] ); - } else { - $mod['module_tags'] = array( 'Other' ); - } - - if ( $mod['plan_classes'] ) { - $mod['plan_classes'] = explode( ',', $mod['plan_classes'] ); - $mod['plan_classes'] = array_map( 'strtolower', array_map( 'trim', $mod['plan_classes'] ) ); - } else { - $mod['plan_classes'] = array( 'free' ); - } - - if ( $mod['feature'] ) { - $mod['feature'] = explode( ',', $mod['feature'] ); - $mod['feature'] = array_map( 'trim', $mod['feature'] ); - } else { - $mod['feature'] = array( 'Other' ); - } - - $modules_details[ $module ] = $mod; - - } - - /** - * Filters the feature array on a module. - * - * This filter allows you to control where each module is filtered: Recommended, - * and the default "Other" listing. - * - * @since-jetpack 3.5.0 - * - * @param array $mod['feature'] The areas to feature this module: - * 'Recommended' shows on the main Jetpack admin screen. - * 'Other' should be the default if no other value is in the array. - * @param string $module The slug of the module, e.g. sharedaddy. - * @param array $mod All the currently assembled module data. - */ - $mod['feature'] = apply_filters( 'jetpack_module_feature', $mod['feature'], $module, $mod ); - - /** - * Filter the returned data about a module. - * - * This filter allows overriding any info about Jetpack modules. It is dangerous, - * so please be careful. - * - * @since-jetpack 3.6.0 - * - * @param array $mod The details of the requested module. - * @param string $module The slug of the module, e.g. sharedaddy - * @param string $file The path to the module source file. - */ - return apply_filters( 'jetpack_get_module', $mod, $module, $file ); - } - - /** - * Like core's get_file_data implementation, but caches the result. - * - * @param string $file Absolute path to the file. - * @param array $headers List of headers, in the format array( 'HeaderKey' => 'Header Name' ). - */ - public function get_file_data( $file, $headers ) { - // Get just the filename from $file (i.e. exclude full path) so that a consistent hash is generated. - $file_name = basename( $file ); - - if ( ! Constants::is_defined( 'JETPACK__VERSION' ) ) { - return get_file_data( $file, $headers ); - } - - $cache_key = 'jetpack_file_data_' . JETPACK__VERSION; - - $file_data_option = get_transient( $cache_key ); - - if ( ! is_array( $file_data_option ) ) { - delete_transient( $cache_key ); - $file_data_option = false; - } - - if ( false === $file_data_option ) { - $file_data_option = array(); - } - - $key = md5( $file_name . maybe_serialize( $headers ) ); - $refresh_cache = is_admin() && isset( $_GET['page'] ) && is_string( $_GET['page'] ) && str_starts_with( $_GET['page'], 'jetpack' ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended, WordPress.Security.ValidatedSanitizedInput - - // If we don't need to refresh the cache, and already have the value, short-circuit! - if ( ! $refresh_cache && isset( $file_data_option[ $key ] ) ) { - return $file_data_option[ $key ]; - } - - $data = get_file_data( $file, $headers ); - - $file_data_option[ $key ] = $data; - - set_transient( $cache_key, $file_data_option, 29 * DAY_IN_SECONDS ); - - return $data; - } - - /** - * Get a list of activated modules as an array of module slugs. - * - * @param bool $available_only Filter out the unavailable (deleted) modules. - * - * @return array - */ - public function get_active( $available_only = true ) { - $active = \Jetpack_Options::get_option( 'active_modules' ); - - if ( ! is_array( $active ) ) { - $active = array(); - } - - if ( class_exists( 'VaultPress' ) || function_exists( 'vaultpress_contact_service' ) ) { - $active[] = 'vaultpress'; - } else { - $active = array_diff( $active, array( 'vaultpress' ) ); - } - - // If protect is active on the main site of a multisite, it should be active on all sites. Doesn't apply to WP.com. - if ( ! in_array( 'protect', $active, true ) - && ! ( new Host() )->is_wpcom_simple() - && is_multisite() - && get_site_option( 'jetpack_protect_active' ) ) { - $active[] = 'protect'; - } - - if ( $available_only ) { - // If it's not available, it shouldn't be active. - // We don't delete it from the options though, as it will be active again when a plugin gets reactivated. - $active = array_intersect( $active, $this->get_available() ); - } - - /** - * Allow filtering of the active modules. - * - * Gives theme and plugin developers the power to alter the modules that - * are activated on the fly. - * - * @since-jetpack 5.8.0 - * - * @param array $active Array of active module slugs. - */ - $active = apply_filters( 'jetpack_active_modules', $active ); - - return array_unique( $active ); - } - - /** - * Extract a module's slug from its full path. - * - * @param string $file Full path to a file. - * - * @return string Module slug. - */ - public function get_slug( $file ) { - return str_replace( '.php', '', basename( $file ) ); - } - - /** - * List available Jetpack modules. Simply lists .php files in /modules/. - * Make sure to tuck away module "library" files in a sub-directory. - * - * @param bool|string $min_version Only return modules introduced in this version or later. Default is false, do not filter. - * @param bool|string $max_version Only return modules introduced before this version. Default is false, do not filter. - * @param bool|null $requires_connection Pass a boolean value to only return modules that require (or do not require) a connection. - * @param bool|null $requires_user_connection Pass a boolean value to only return modules that require (or do not require) a user connection. - * - * @return array $modules Array of module slugs - */ - public function get_available( $min_version = false, $max_version = false, $requires_connection = null, $requires_user_connection = null ) { - static $modules = null; - - if ( ! class_exists( 'Jetpack' ) || ! Constants::is_defined( 'JETPACK__VERSION' ) || ! Constants::is_defined( 'JETPACK__PLUGIN_DIR' ) ) { - return array_unique( - /** - * Stand alone plugins need to use this filter to register the modules they interact with. - * This will allow them to activate and deactivate these modules even when Jetpack is not present. - * Note: Standalone plugins can only interact with modules that also exist in the Jetpack plugin, otherwise they'll lose the ability to control it if Jetpack is activated. - * - * @since 1.13.6 - * - * @param array $modules The list of available modules as an array of slugs. - * @param bool $requires_connection Whether to list only modules that require a connection to work. - * @param bool $requires_user_connection Whether to list only modules that require a user connection to work. - */ - apply_filters( 'jetpack_get_available_standalone_modules', array(), $requires_connection, $requires_user_connection ) - ); - } - - if ( ! isset( $modules ) ) { - $available_modules_option = \Jetpack_Options::get_option( 'available_modules', array() ); - // Use the cache if we're on the front-end and it's available... - if ( ! is_admin() && ! empty( $available_modules_option[ JETPACK__VERSION ] ) ) { - $modules = $available_modules_option[ JETPACK__VERSION ]; - } else { - $files = ( new Files() )->glob_php( JETPACK__PLUGIN_DIR . 'modules' ); - - $modules = array(); - - foreach ( $files as $file ) { - $slug = $this->get_slug( $file ); - $headers = $this->get( $slug ); - - if ( ! $headers ) { - continue; - } - - $modules[ $slug ] = $headers['introduced']; - } - - \Jetpack_Options::update_option( - 'available_modules', - array( - JETPACK__VERSION => $modules, - ) - ); - } - } - - /** - * Filters the array of modules available to be activated. - * - * @since 2.4.0 - * - * @param array $modules Array of available modules. - * @param string $min_version Minimum version number required to use modules. - * @param string $max_version Maximum version number required to use modules. - * @param bool|null $requires_connection Value of the Requires Connection filter. - * @param bool|null $requires_user_connection Value of the Requires User Connection filter. - */ - $mods = apply_filters( 'jetpack_get_available_modules', $modules, $min_version, $max_version, $requires_connection, $requires_user_connection ); - - if ( ! $min_version && ! $max_version && $requires_connection === null && $requires_user_connection === null ) { - return array_keys( $mods ); - } - - $r = array(); - foreach ( $mods as $slug => $introduced ) { - if ( $min_version && version_compare( $min_version, $introduced, '>=' ) ) { - continue; - } - - if ( $max_version && version_compare( $max_version, $introduced, '<' ) ) { - continue; - } - - $mod_details = $this->get( $slug ); - - if ( null !== $requires_connection && (bool) $requires_connection !== $mod_details['requires_connection'] ) { - continue; - } - - if ( null !== $requires_user_connection && (bool) $requires_user_connection !== $mod_details['requires_user_connection'] ) { - continue; - } - - $r[] = $slug; - } - - return $r; - } - - /** - * Is slug a valid module. - * - * @param string $module Module slug. - * - * @return bool - */ - public function is_module( $module ) { - return ! empty( $module ) && ! validate_file( $module, $this->get_available() ); - } - - /** - * Update module status. - * - * @param string $module - module slug. - * @param boolean $active - true to activate, false to deactivate. - * @param bool $exit Should exit be called after deactivation. - * @param bool $redirect Should there be a redirection after activation. - */ - public function update_status( $module, $active, $exit = true, $redirect = true ) { - return $active ? $this->activate( $module, $exit, $redirect ) : $this->deactivate( $module ); - } - - /** - * Activate a module. - * - * @param string $module Module slug. - * @param bool $exit Should exit be called after deactivation. - * @param bool $redirect Should there be a redirection after activation. - * - * @return bool|void - */ - public function activate( $module, $exit = true, $redirect = true ) { - /** - * Fires before a module is activated. - * - * @since 2.6.0 - * - * @param string $module Module slug. - * @param bool $exit Should we exit after the module has been activated. Default to true. - * @param bool $redirect Should the user be redirected after module activation? Default to true. - */ - do_action( 'jetpack_pre_activate_module', $module, $exit, $redirect ); - - if ( ! strlen( $module ) ) { - return false; - } - - // If it's already active, then don't do it again. - $active = $this->get_active(); - foreach ( $active as $act ) { - if ( $act === $module ) { - return true; - } - } - - if ( ! $this->is_module( $module ) ) { - return false; - } - - // Jetpack plugin only - if ( class_exists( 'Jetpack' ) ) { - - $module_data = $this->get( $module ); - - $status = new Status(); - $state = new CookieState(); - - if ( ! \Jetpack::is_connection_ready() ) { - if ( ! $status->is_offline_mode() ) { - return false; - } - - // If we're not connected but in offline mode, make sure the module doesn't require a connection. - if ( $status->is_offline_mode() && $module_data['requires_connection'] ) { - return false; - } - } - - if ( class_exists( 'Jetpack_Client_Server' ) ) { - $jetpack = \Jetpack::init(); - - // Check and see if the old plugin is active. - if ( isset( $jetpack->plugins_to_deactivate[ $module ] ) ) { - // Deactivate the old plugins. - $deactivated = array(); - foreach ( $jetpack->plugins_to_deactivate[ $module ] as $idx => $deactivate_me ) { - if ( \Jetpack_Client_Server::deactivate_plugin( $deactivate_me[0], $deactivate_me[1] ) ) { - // If we deactivated the old plugin, remembere that with ::state() and redirect back to this page to activate the module - // We can't activate the module on this page load since the newly deactivated old plugin is still loaded on this page load. - $deactivated[] = "$module:$idx"; - } - } - if ( $deactivated ) { - $state->state( 'deactivated_plugins', implode( ',', $deactivated ) ); - wp_safe_redirect( add_query_arg( 'jetpack_restate', 1 ) ); - exit( 0 ); - } - } - } - - // Protect won't work with mis-configured IPs. - if ( 'protect' === $module ) { - if ( ! IP_Utils::get_ip() ) { - $state->state( 'message', 'protect_misconfigured_ip' ); - return false; - } - } - - if ( ! Jetpack_Plan::supports( $module ) ) { - return false; - } - - // Check the file for fatal errors, a la wp-admin/plugins.php::activate. - $state->state( 'module', $module ); - $state->state( 'error', 'module_activation_failed' ); // we'll override this later if the plugin can be included without fatal error. - - ob_start(); - $module_path = $this->get_path( $module ); - if ( file_exists( $module_path ) ) { - require $this->get_path( $module ); // phpcs:ignore WordPressVIPMinimum.Files.IncludingFile.NotAbsolutePath - } - - $active[] = $module; - $this->update_active( $active ); - - $state->state( 'error', false ); // the override. - ob_end_clean(); - } else { // Not a Jetpack plugin. - $active[] = $module; - $this->update_active( $active ); - } - - if ( $redirect ) { - wp_safe_redirect( ( new Paths() )->admin_url( 'page=jetpack' ) ); - } - if ( $exit ) { - exit( 0 ); - } - return true; - } - - /** - * Deactivate module. - * - * @param string $module Module slug. - * - * @return bool - */ - public function deactivate( $module ) { - /** - * Fires when a module is deactivated. - * - * @since 1.9.0 - * - * @param string $module Module slug. - */ - do_action( 'jetpack_pre_deactivate_module', $module ); - - $active = $this->get_active(); - $new = array_filter( array_diff( $active, (array) $module ) ); - - return $this->update_active( $new ); - } - - /** - * Generate a module's path from its slug. - * - * @param string $slug Module slug. - */ - public function get_path( $slug ) { - if ( ! Constants::is_defined( 'JETPACK__PLUGIN_DIR' ) ) { - return ''; - } - /** - * Filters the path of a modules. - * - * @since 7.4.0 - * - * @param array $return The absolute path to a module's root php file - * @param string $slug The module slug - */ - return apply_filters( 'jetpack_get_module_path', JETPACK__PLUGIN_DIR . "modules/$slug.php", $slug ); - } - - /** - * Saves all the currently active modules to options. - * Also fires Action hooks for each newly activated and deactivated module. - * - * @param array $modules Array of active modules to be saved in options. - * - * @return bool $success true for success, false for failure. - */ - public function update_active( $modules ) { - $current_modules = \Jetpack_Options::get_option( 'active_modules', array() ); - $active_modules = $this->get_active(); - $new_active_modules = array_diff( $modules, $current_modules ); - $new_inactive_modules = array_diff( $active_modules, $modules ); - $new_current_modules = array_diff( array_merge( $current_modules, $new_active_modules ), $new_inactive_modules ); - $reindexed_modules = array_values( $new_current_modules ); - $success = \Jetpack_Options::update_option( 'active_modules', array_unique( $reindexed_modules ) ); - // Let's take `pre_update_option_jetpack_active_modules` filter into account - // and actually decide for which modules we need to fire hooks by comparing - // the 'active_modules' option before and after the update. - $current_modules_post_update = \Jetpack_Options::get_option( 'active_modules', array() ); - - $new_inactive_modules = array_diff( $current_modules, $current_modules_post_update ); - $new_inactive_modules = array_unique( $new_inactive_modules ); - $new_inactive_modules = array_values( $new_inactive_modules ); - - $new_active_modules = array_diff( $current_modules_post_update, $current_modules ); - $new_active_modules = array_unique( $new_active_modules ); - $new_active_modules = array_values( $new_active_modules ); - - foreach ( $new_active_modules as $module ) { - /** - * Fires when a specific module is activated. - * - * @since 1.9.0 - * - * @param string $module Module slug. - * @param boolean $success whether the module was activated. @since 4.2 - */ - do_action( 'jetpack_activate_module', $module, $success ); - /** - * Fires when a module is activated. - * The dynamic part of the filter, $module, is the module slug. - * - * @since 1.9.0 - * - * @param string $module Module slug. - */ - do_action( "jetpack_activate_module_$module", $module ); - } - - foreach ( $new_inactive_modules as $module ) { - /** - * Fired after a module has been deactivated. - * - * @since 4.2.0 - * - * @param string $module Module slug. - * @param boolean $success whether the module was deactivated. - */ - do_action( 'jetpack_deactivate_module', $module, $success ); - /** - * Fires when a module is deactivated. - * The dynamic part of the filter, $module, is the module slug. - * - * @since 1.9.0 - * - * @param string $module Module slug. - */ - do_action( "jetpack_deactivate_module_$module", $module ); - } - - return $success; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-paths.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-paths.php deleted file mode 100644 index 7ef200b4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-paths.php +++ /dev/null @@ -1,81 +0,0 @@ - 'jetpack' ) ); - $url = add_query_arg( $args, admin_url( 'admin.php' ) ); - return $url; - } - - /** - * Determine if the current request is activating a plugin from the plugins page. - * - * @param string $plugin Plugin file path to check. - * @return bool - */ - public function is_current_request_activating_plugin_from_plugins_screen( $plugin ) { - // Filter out common async request contexts - if ( - wp_doing_ajax() || - ( defined( 'REST_REQUEST' ) && REST_REQUEST ) || - ( defined( 'REST_API_REQUEST' ) && REST_API_REQUEST ) || - ( defined( 'WP_CLI' ) && WP_CLI ) - ) { - return false; - } - - if ( isset( $_SERVER['SCRIPT_NAME'] ) ) { - $request_file = esc_url_raw( wp_unslash( $_SERVER['SCRIPT_NAME'] ) ); - } elseif ( isset( $_SERVER['REQUEST_URI'] ) ) { - list( $request_file ) = explode( '?', esc_url_raw( wp_unslash( $_SERVER['REQUEST_URI'] ) ) ); - } else { - return false; - } - - // Not the plugins page - if ( strpos( $request_file, 'wp-admin/plugins.php' ) === false ) { - return false; - } - - // Same method to get the action as used by plugins.php - $wp_list_table = _get_list_table( 'WP_Plugins_List_Table' ); - $action = $wp_list_table->current_action(); - - // Not a singular activation - // This also means that if the plugin is activated as part of a group ( bulk activation ), this function will return false here. - if ( 'activate' !== $action ) { - return false; - } - - // Check the nonce associated with the plugin activation - // We are not changing any data here, so this is not super necessary, it's just a best practice before using the form data from $_REQUEST. - check_admin_referer( 'activate-plugin_' . $plugin ); - - // Not the right plugin - $requested_plugin = isset( $_REQUEST['plugin'] ) ? sanitize_text_field( wp_unslash( $_REQUEST['plugin'] ) ) : null; - if ( $requested_plugin !== $plugin ) { - return false; - } - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-status.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-status.php deleted file mode 100644 index 83c5c22f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-status.php +++ /dev/null @@ -1,434 +0,0 @@ -is_local_site() ) { - $offline_mode = true; - } - - /** - * Filters Jetpack's offline mode. - * - * @see https://jetpack.com/support/offline-mode/ - * - * @since 1.3.0 - * - * @param bool $offline_mode Is Jetpack's offline mode active. - */ - $offline_mode = (bool) apply_filters( 'jetpack_offline_mode', $offline_mode ); - - Cache::set( 'is_offline_mode', $offline_mode ); - return $offline_mode; - } - - /** - * Whether this is a system with a multiple networks. - * Implemented since there is no core is_multi_network function. - * Right now there is no way to tell which network is the dominant network on the system. - * - * @return boolean - */ - public function is_multi_network() { - global $wpdb; - - $cached = Cache::get( 'is_multi_network' ); - if ( null !== $cached ) { - return $cached; - } - - // If we don't have a multi site setup no need to do any more. - if ( ! is_multisite() ) { - Cache::set( 'is_multi_network', false ); - return false; - } - - $num_sites = $wpdb->get_var( "SELECT COUNT(*) FROM {$wpdb->site}" ); - if ( $num_sites > 1 ) { - Cache::set( 'is_multi_network', true ); - return true; - } - - Cache::set( 'is_multi_network', false ); - return false; - } - - /** - * Whether the current site is single user site. - * - * @return bool - */ - public function is_single_user_site() { - global $wpdb; - - $ret = Cache::get( 'is_single_user_site' ); - if ( null === $ret ) { - $some_users = get_transient( 'jetpack_is_single_user' ); - if ( false === $some_users ) { - $some_users = $wpdb->get_var( "SELECT COUNT(*) FROM (SELECT user_id FROM $wpdb->usermeta WHERE meta_key = '{$wpdb->prefix}capabilities' LIMIT 2) AS someusers" ); - set_transient( 'jetpack_is_single_user', (int) $some_users, 12 * HOUR_IN_SECONDS ); - } - $ret = 1 === (int) $some_users; - Cache::set( 'is_single_user_site', $ret ); - } - return $ret; - } - - /** - * If the site is a local site. - * - * @since 1.3.0 - * - * @return bool - */ - public function is_local_site() { - $cached = Cache::get( 'is_local_site' ); - if ( null !== $cached ) { - return $cached; - } - - $site_url = site_url(); - - // Check for localhost and sites using an IP only first. - // Note: str_contains() is not used here, as wp-includes/compat.php is not loaded in this file. - $is_local = $site_url && false === strpos( $site_url, '.' ); - - // Use Core's environment check, if available. - if ( 'local' === wp_get_environment_type() ) { - $is_local = true; - } - - // Then check for usual usual domains used by local dev tools. - $known_local = array( - '#\.local$#i', - '#\.localhost$#i', - '#\.test$#i', - '#\.docksal$#i', // Docksal. - '#\.docksal\.site$#i', // Docksal. - '#\.dev\.cc$#i', // ServerPress. - '#\.lndo\.site$#i', // Lando. - '#^https?://127\.0\.0\.1$#', - ); - - if ( ! $is_local ) { - foreach ( $known_local as $url ) { - if ( preg_match( $url, $site_url ) ) { - $is_local = true; - break; - } - } - } - - /** - * Filters is_local_site check. - * - * @since 1.3.0 - * - * @param bool $is_local If the current site is a local site. - */ - $is_local = apply_filters( 'jetpack_is_local_site', $is_local ); - - Cache::set( 'is_local_site', $is_local ); - return $is_local; - } - - /** - * If is a staging site. - * - * @deprecated since 3.3.0 - * - * @return bool - */ - public function is_staging_site() { - _deprecated_function( __FUNCTION__, '3.3.0', 'in_safe_mode' ); - $cached = Cache::get( 'is_staging_site' ); - if ( null !== $cached ) { - return $cached; - } - - /* - * Core's wp_get_environment_type allows for a few specific options. - * We should default to bowing out gracefully for anything other than production or local. - */ - $is_staging = ! in_array( wp_get_environment_type(), array( 'production', 'local' ), true ); - - $known_staging = array( - 'urls' => array( - '#\.staging\.wpengine\.com$#i', // WP Engine. This is their legacy staging URL structure. Their new platform does not have a common URL. https://github.com/Automattic/jetpack/issues/21504 - '#\.staging\.kinsta\.com$#i', // Kinsta.com. - '#\.kinsta\.cloud$#i', // Kinsta.com. - '#\.stage\.site$#i', // DreamPress. - '#\.newspackstaging\.com$#i', // Newspack. - '#^(?!live-)([a-zA-Z0-9-]+)\.pantheonsite\.io$#i', // Pantheon. - '#\.flywheelsites\.com$#i', // Flywheel. - '#\.flywheelstaging\.com$#i', // Flywheel. - '#\.cloudwaysapps\.com$#i', // Cloudways. - '#\.azurewebsites\.net$#i', // Azure. - '#\.wpserveur\.net$#i', // WPServeur. - '#\-liquidwebsites\.com$#i', // Liquidweb. - ), - 'constants' => array( - 'IS_WPE_SNAPSHOT', // WP Engine. This is used on their legacy staging environment. Their new platform does not have a constant. https://github.com/Automattic/jetpack/issues/21504 - 'KINSTA_DEV_ENV', // Kinsta.com. - 'WPSTAGECOACH_STAGING', // WP Stagecoach. - 'JETPACK_STAGING_MODE', // Generic. - 'WP_LOCAL_DEV', // Generic. - ), - ); - /** - * Filters the flags of known staging sites. - * - * @since 1.1.1 - * @since-jetpack 3.9.0 - * - * @param array $known_staging { - * An array of arrays that each are used to check if the current site is staging. - * @type array $urls URLs of staging sites in regex to check against site_url. - * @type array $constants PHP constants of known staging/developement environments. - * } - */ - $known_staging = apply_filters( 'jetpack_known_staging', $known_staging ); - - if ( isset( $known_staging['urls'] ) ) { - $site_url = site_url(); - foreach ( $known_staging['urls'] as $url ) { - if ( preg_match( $url, wp_parse_url( $site_url, PHP_URL_HOST ) ) ) { - $is_staging = true; - break; - } - } - } - - if ( isset( $known_staging['constants'] ) ) { - foreach ( $known_staging['constants'] as $constant ) { - if ( defined( $constant ) && constant( $constant ) ) { - $is_staging = true; - } - } - } - - // Last, let's check if sync is erroring due to an IDC. If so, set the site to staging mode. - if ( ! $is_staging && method_exists( 'Automattic\\Jetpack\\Identity_Crisis', 'validate_sync_error_idc_option' ) && \Automattic\Jetpack\Identity_Crisis::validate_sync_error_idc_option() ) { - $is_staging = true; - } - - /** - * Filters is_staging_site check. - * - * @since 1.1.1 - * @since-jetpack 3.9.0 - * - * @param bool $is_staging If the current site is a staging site. - */ - $is_staging = apply_filters( 'jetpack_is_staging_site', $is_staging ); - - Cache::set( 'is_staging_site', $is_staging ); - return $is_staging; - } - - /** - * If the site is in safe mode. - * - * @since 3.3.0 - * - * @return bool - */ - public function in_safe_mode() { - $cached = Cache::get( 'in_safe_mode' ); - if ( null !== $cached ) { - return $cached; - } - $in_safe_mode = false; - if ( method_exists( 'Automattic\\Jetpack\\Identity_Crisis', 'validate_sync_error_idc_option' ) && \Automattic\Jetpack\Identity_Crisis::validate_sync_error_idc_option() ) { - $in_safe_mode = true; - } - /** - * Filters in_safe_mode check. - * - * @since 3.3.0 - * - * @param bool $in_safe_mode If the current site is in safe mode. - */ - $in_safe_mode = apply_filters( 'jetpack_is_in_safe_mode', $in_safe_mode ); - - Cache::set( 'in_safe_mode', $in_safe_mode ); - return $in_safe_mode; - } - - /** - * If the site is a development/staging site. - * This is a new version of is_staging_site added to separate safe mode from the legacy staging mode. - * This method checks for core WP_ENVIRONMENT_TYPE setting - * Using the jetpack_is_development_site filter. - * - * @since 3.3.0 - * - * @return bool - */ - public static function is_development_site() { - $cached = Cache::get( 'is_development_site' ); - if ( null !== $cached ) { - return $cached; - } - $is_dev_site = ! in_array( wp_get_environment_type(), array( 'production', 'local' ), true ); - /** - * Filters is_development_site check. - * - * @since 3.3.0 - * - * @param bool $is_dev_site If the current site is a staging or dev site. - */ - $is_dev_site = apply_filters( 'jetpack_is_development_site', $is_dev_site ); - - Cache::set( 'is_development_site', $is_dev_site ); - return $is_dev_site; - } - - /** - * Whether the site is currently onboarding or not. - * A site is considered as being onboarded if it currently has an onboarding token. - * - * @since-jetpack 5.8 - * - * @deprecated since 4.0.0 - * - * @access public - * @static - * - * @return bool True if the site is currently onboarding, false otherwise - */ - public function is_onboarding() { - return \Jetpack_Options::get_option( 'onboarding' ) !== false; - } - - /** - * Whether the site is currently private or not. - * On WordPress.com and WoA, sites can be marked as private - * - * @since 1.16.0 - * - * @return bool True if the site is private. - */ - public function is_private_site() { - $ret = Cache::get( 'is_private_site' ); - if ( null === $ret ) { - $is_private_site = '-1' === get_option( 'blog_public' ); - - /** - * Filters the is_private_site check. - * - * @since 1.16.1 - * - * @param bool $is_private_site True if the site is private. - */ - $is_private_site = apply_filters( 'jetpack_is_private_site', $is_private_site ); - - Cache::set( 'is_private_site', $is_private_site ); - return $is_private_site; - } - return $ret; - } - - /** - * Whether the site is currently unlaunched or not. - * On WordPress.com and WoA, sites can be marked as "coming soon", aka unlaunched - * - * @since 1.16.0 - * - * @return bool True if the site is not launched. - */ - public function is_coming_soon() { - $ret = Cache::get( 'is_coming_soon' ); - if ( null === $ret ) { - $is_coming_soon = (bool) ( function_exists( 'site_is_coming_soon' ) && \site_is_coming_soon() ) - || get_option( 'wpcom_public_coming_soon' ); - - /** - * Filters the is_coming_soon check. - * - * @since 1.16.1 - * - * @param bool $is_coming_soon True if the site is coming soon (i.e. unlaunched). - */ - $is_coming_soon = apply_filters( 'jetpack_is_coming_soon', $is_coming_soon ); - - Cache::set( 'is_coming_soon', $is_coming_soon ); - return $is_coming_soon; - } - return $ret; - } - - /** - * Returns the site slug suffix to be used as part of Calypso URLs. - * - * Strips http:// or https:// from a url, replaces forward slash with ::. - * - * @since 1.6.0 - * - * @param string $url Optional. URL to build the site suffix from. Default: Home URL. - * - * @return string - */ - public function get_site_suffix( $url = '' ) { - // On WordPress.com, site suffixes are a bit different. - if ( method_exists( 'WPCOM_Masterbar', 'get_calypso_site_slug' ) ) { - return WPCOM_Masterbar::get_calypso_site_slug( get_current_blog_id() ); - } - - // Grab the 'site_url' option for WoA sites to avoid plugins to interfere with the site - // identifier (e.g. i18n plugins may change the main url to '/', but we - // want to exclude the locale since it's not part of the site suffix). - if ( ( new Host() )->is_woa_site() ) { - $url = \site_url(); - } - - if ( empty( $url ) ) { - // WordPress can be installed in subdirectories (e.g. make.wordpress.org/plugins) - // where the 'site_url' option points to the root domain (e.g. make.wordpress.org) - // which could collide with another site in the same domain but with WordPress - // installed in a different subdirectory (e.g. make.wordpress.org/core). To avoid - // such collision, we identify the site with the 'home_url' option. - $url = \home_url(); - } - - $url = preg_replace( '#^.*?://#', '', $url ); - $url = str_replace( '/', '::', $url ); - - return rtrim( $url, ':' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php deleted file mode 100644 index fae08755..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php +++ /dev/null @@ -1,56 +0,0 @@ -= 7.0. [#34192] - -## [1.60.1] - 2023-10-31 - -## [1.60.0] - 2023-10-26 -### Removed -- Remove Jetpack option jetpack-memberships-connected-account-id. [#32354] - -## [1.59.2] - 2023-10-24 -### Changed -- Update sync version. - -## [1.59.1] - 2023-10-24 -### Added -- Sync: Add missing support for supplying additional columns to do checksum on. [#33440] - -## [1.59.0] - 2023-10-23 -### Changed -- Dedicated Sync: Update 'init' hook priority on Dedicated Sync requests to 0, in order to start sending Sync actions to WPCOM and exit as early as possible. [#33594] - -## [1.58.1] - 2023-10-18 -### Fixed -- Update dependencies. - -## [1.58.0] - 2023-10-16 -### Changed -- Migrated 'jetpack_sync_before_send*' actions for Sync queue to 'jetpack_sync_before_enqueue' instead. [#33384] - -## [1.57.4] - 2023-10-10 - -- Minor internal updates. - -## [1.57.3] - 2023-09-28 -### Removed -- Remove compatibility code for PHP <5.5. [#33288] - -## [1.57.2] - 2023-09-25 -### Added -- Site Settings Endpoint: Allow for updating and retrieving of the wpcom_newsletter_categories site option. [#33234] - -## [1.57.1] - 2023-09-20 -### Added -- Adds legacy contact and locked mode options for 100-year plan [#33081] - -## [1.57.0] - 2023-09-19 -### Added -- Added a definition of a WooCommerce HPOS table to Jetpack Sync. [#32774] -- Jetpack Sync: Drop Sync custom queue table when Jetpack is disconnected [#32940] -- Woo: add HPOS (custom order tables) events to sync module. [#32530] - -## [1.56.0] - 2023-09-04 -### Added -- Add wpcom_newsletter_categories_enabled site option [#32569] -- Whitelist the blog option for auto conversion settings. [#32693] - -## [1.55.2] - 2023-08-28 -### Fixed -- Re-adds the jetpack-memberships-connected-account-id option to whitelist. [#32632] - -## [1.55.1] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [1.55.0] - 2023-08-21 -### Removed -- Remove Jetpack option jetpack-memberships-connected-account-id [#32125] - -## [1.54.0] - 2023-08-15 -### Added -- Extract Sync Queue storage handling to an external class to prepare for Custom Table migration [#32275] - -## [1.53.0] - 2023-08-09 -### Added -- Jetpack Sync: Custom table initialization and migration functionality [#32135] -- Jetpack Sync: Drop custom table on sender uninstall [#32335] - -## [1.52.0] - 2023-08-01 -### Added -- Add support for a custom database table for Sync Queue. [#32111] -- Extract Sync Queue storage handling to an external class to prepare for Custom Table migration. [#32089] -- Sync: Add feature flag for enabling custom queue table. [#31681] - -## [1.51.0] - 2023-07-17 -### Added -- Jetpack & Jetpack Sync: Added cache check when trying to spawn dedicated sync or update JETPACK__VERSION to avoid additional requests to the DB if external cache is available. [#31645] -- Newsletters: Add option to enable subscribe modal. [#31393] -- Sync: Add support for additional guest and note meta fields [#31810] - -## [1.50.2] - 2023-07-05 -### Added -- Sync wpcom_site_setup site option [#31662] - -## [1.50.1] - 2023-07-04 -### Changed -- Revert dedicated hook endpoint to later in the 'init' hook, as it broke existing code that registers post statuses and such during 'init'. [#31685] - -## [1.50.0] - 2023-06-26 -### Added -- Added a new callable to the whitelist for get_loaded_extensions(). [#31333] -- CPT Exclusion: do not sync Jetpack Inspect Log entries. [#31535] - -### Fixed -- Initialize dedicated hook endpoint earlier in the 'init' hook to avoid cookie conflicts. [#31423] - -## [1.49.0] - 2023-05-29 -### Added -- Added `wpcom_reader_views_enabled` option to default sync list [#30800] - -### Changed -- FSE: remove usage of `gutenberg_is_fse_theme` for modern `wp_is_block_theme` [#30806] - -## [1.48.1] - 2023-05-15 -### Changed -- PHP 8 compatibility updates. [#30599] -- PHP 8.1 compatibility updates [#30523] - -## [1.48.0] - 2023-05-08 -### Changed -- Use Jetpack Constants to check the value of REST_API_REQUEST in Settings:is_syncing function so we're able to overwrite the value and render some jetpack blocks via the rest api endpoint [#30400] - -## [1.47.9] - 2023-05-02 -### Changed -- Internal updates. - -## [1.47.8] - 2023-05-01 -### Changed -- Internal updates. - -## [1.47.7] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [1.47.6] - 2023-04-04 -### Changed -- Sync: Lowered priority to sync so that the hook is run at the end. [#29804] - -## [1.47.5] - 2023-04-03 -### Changed -- Minor internal updates. - -## [1.47.4] - 2023-03-28 -### Changed -- Move brute force protection into WAF package. [#28401] - -## [1.47.3] - 2023-03-20 -### Changed -- Updated package dependencies. [#29480] - -## [1.47.2] - 2023-02-20 -### Changed -- Minor internal updates. - -## [1.47.1] - 2023-01-23 -### Added -- Close PHP Session if it's active when running a Dedicated Sync request. [#28515] - -### Fixed -- Jetpack Sync: prevent syncing user update when corresponding flags are not set. [#28385] - -## [1.47.0] - 2023-01-18 -### Removed -- Removed the deprecated option jetpack_blogging_prompts_enabled from defaults [#28387] - -## [1.46.1] - 2023-01-11 -### Changed -- Updated package dependencies. - -## [1.46.0] - 2022-12-27 -### Added -- Added woocommerce_cod_settings to the options whitelist. [#27988] - -## [1.45.0] - 2022-12-19 -### Added -- Adding new boolean site option of 'wpcom-subscription-emails-use-excerpt'. [#27908] -- Sync Launchpad-related options: `launchpad_screen` and `launchpad_checklist_tasks_statuses`. [#27843] - -### Changed -- Option: Update featured_image_email_enabled option name to wpcom_featured_image_in_email. [#27955] - -### Fixed -- Improve PHP 8.2 compatibility. [#27968] - -## [1.44.2] - 2022-12-06 -### Changed -- Updated package dependencies. - -## [1.44.1] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [1.44.0] - 2022-11-30 -### Added -- Added full response logging for failed Sync data requests. [#27644] - -### Fixed -- Make sure Dedicated Sync can revert back to Default Sync if it stops sending events for one reason or another. [#27632] - -## [1.43.2] - 2022-11-28 -### Changed -- Sync: Limit next_sync_time lock to be at most 1 hour in the future [#27606] - -## [1.43.1] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [1.43.0] - 2022-11-17 -### Added -- Added new sync option for launch-status [#27434] -- Jetpack Sync: Add new endpoint for resetting Sync locks. [#27446] - -## [1.42.0] - 2022-11-14 -### Changed -- Save attached media to post meta [#26930] - -## [1.41.0] - 2022-11-07 -### Changed -- Jetpack Sync: add Updates module in required Sync modules. [#27182] -- Updated package dependencies. [#27278] - -## [1.40.3] - 2022-11-01 -### Added -- Adds wpcom_gifting_subscription option for syncing [#27116] - -## [1.40.2] - 2022-10-27 -### Fixed -- Check $action_links is still array after plugin_action_links filter has been applied. [#27076] - -## [1.40.1] - 2022-10-25 -### Added -- Added featured_image_email_enabled option for syncing [#27009] - -### Changed -- Search Sync Settings :: Add Marketplace product extra fields meta to allow list [#26927] -- Updated package dependencies. [#26705] - -## [1.40.0] - 2022-10-17 -### Added -- Adding the `sl-insta-media` post type to the Sync blacklist as the post type data isn't relevant to Sync and takes up non-trivial resources. [#26826] - -## [1.39.0] - 2022-10-11 -### Added -- Added some taxonomies to be indexed by Search. [#26683] - -## [1.38.4] - 2022-09-20 -### Added -- Gutenberg Support: add additional theme_supports items to our synced allowlist. [#26239] - -### Changed -- Default Theme Support: Add support for new feature added in WP 6.1 [#26236] -- Theme Supports: updated allowed values list to align with a Core change r54159-core [#26220] - -## [1.38.3] - 2022-09-08 -### Changed -- Updated package dependencies. - -## [1.38.2] - 2022-08-29 -### Changed -- Updated package dependencies. - -## [1.38.1] - 2022-08-25 -### Changed -- Search Sync Settings :: Add Marketplace related meta fields and taxonomies to allow list [#25376] - -## [1.38.0] - 2022-08-23 -### Added -- Search: add product-brand to taxonomy sync list to support WooCommerce Brands plugin. [#25665] - -### Changed -- Updated package dependencies. [#25628] - -## [1.37.1] - 2022-08-03 -### Changed -- Updated package dependencies. [#25300, #25315] - -## [1.37.0] - 2022-07-26 -### Changed -- Jetpack Sync: Add Sync lock related info in Sync debug details. [#25140] -- Updated package dependencies. [#25158] - -### Fixed -- Dedicated Sync: Enable sending of callables outside of admin context, since Dedicated Sync requests always work outside of admin scope. [#25143] - -## [1.36.1] - 2022-07-06 -### Added -- Add new WordPress core `block-templates` theme feature to `Defaults::$default_theme_support_whitelist` [#24960] - -## [1.36.0] - 2022-06-28 -### Added -- Posts: added a Sync call to make sure post content is up to date before publishing. [#24827] - -### Changed -- Minimum Sync Config: Update required modules and options [#24831] - -### Fixed -- Sync Table Checksums: Table checksum should be enabled depending on corresponding Sync modulee [#24772] - -## [1.35.2] - 2022-06-21 -### Changed -- Renaming master to trunk. [#24661] - -## [1.35.1] - 2022-06-14 -### Added -- Add a request lock to prevent multiple requests being spawned at once [#24734] - -### Changed -- Updated package dependencies. [#24529] - -## [1.35.0] - 2022-05-30 -### Changed -- Sync: Add '_jetpack_blogging_prompt_key' to default post meta whitelist - -## [1.34.0] - 2022-05-24 -### Changed -- Dedicated Sync - Introduce custom endpoint for spawning Sync requests [#24468] -- Sync: Add 'active_modules' to default whitelisted callables. [#24453] - -## [1.33.1] - 2022-05-19 -### Removed -- Removed dedicated sync custom endpoints pending error investigation [#24419] - -## [1.33.0] - 2022-05-18 -### Changed -- Dedicated Sync: Introduce custom endpoint for spawning Sync requests [#24344] - -## [1.32.0] - 2022-05-10 -### Added -- Search: add search options to option whitelist [#24167] - -## [1.31.1] - 2022-05-04 -### Changed -- Updated package dependencies. [#24095] -- WordPress 6.1 Compatibilty [#24083] - -### Deprecated -- Moved the options class into Connection. [#24095] - -## [1.31.0] - 2022-04-26 -### Added -- Adds filter to get_themes callable - -### Deprecated -- Removed Heartbeat by hoisting it into Connection. - -## [1.30.8] - 2022-04-19 -### Added -- Added get_themes Callable to sync the list of installed themes on a site -- Added get_themes to Sync defaults - -### Changed -- PHPCS: Fix `WordPress.Security.ValidatedSanitizedInput` -- Updated package dependencies. - -## [1.30.7] - 2022-04-12 -### Added -- Adding new site option to be synced. - -## [1.30.6] - 2022-04-06 -### Changed -- Updated package dependencies. - -### Fixed -- Dedicated Sync: Only try to run the sender once if Dedicated Sync is enabled as it has its own requeueing mechanism. - -## [1.30.5] - 2022-03-29 -### Changed -- Microperformance: Use === null instead of is_null - -## [1.30.4] - 2022-03-23 -### Changed -- Enable syncing of dedicated_sync_enabled Sync setting - -### Fixed -- Dedicated Sync: Allow spawning request with expired Retry-After - -## [1.30.3] - 2022-03-15 -### Changed -- Search Sync Settings :: Add ETB taxonomy to allow list. - -## [1.30.2] - 2022-03-08 -### Changed -- Disallow syncing of _term_meta post_type - -## [1.30.1] - 2022-03-02 -### Added -- Dedicated Sync flow: Allow enabling or disabling via WPCOM response header - -## [1.30.0] - 2022-02-22 -### Added -- Add Sync dedicated request flow. - -### Changed -- Updated package dependencies. - -## [1.29.2] - 2022-02-09 -### Added -- Allow sync package consumers to provide custom data settings. - -### Fixed -- Fixed some new PHPCS warnings. - -## [1.29.1] - 2022-02-02 -### Changed -- Updated package dependencies. - -## [1.29.0] - 2022-01-25 -### Added -- Jetpack Search: update the allowed post meta when search is active to include all indexable meta. - -## [1.28.2] - 2022-01-18 -### Changed -- Updated package dependencies. - -## [1.28.1] - 2022-01-13 -### Changed -- Updated package dependencies. - -## [1.28.0] - 2022-01-04 -### Changed -- Listener: Do not enqueue actions when the site is disconnected -- Switch to pcov for code coverage. -- Theme deletions: rely on Core WP hook now that the package requires WP 5.8. -- Updated package dependencies -- Updated package textdomain from `jetpack` to `jetpack-sync`. - -## [1.27.6] - 2021-12-14 -### Changed -- Updated package dependencies. - -## [1.27.5] - 2021-11-30 -### Changed -- Updated package dependencies. - -## [1.27.4] - 2021-11-23 -### Changed -- Updated package dependencies. - -## [1.27.3] - 2021-11-16 -### Changed -- Actions: add the do_only_first_initial_sync method which starts an initial sync only when one hasn't already been done - -## [1.27.2] - 2021-11-09 -### Added -- Constants: Now syncing Atomic platform constant - -### Changed -- Full Sync : limit included users to contributors and above (based on wp_user_limit) -- Updated package dependencies. -- User Checksums - limit scope to users with wp_user_level > 0 - -### Fixed -- Fix PHP 8.1 deprecation warnings. - -## [1.27.1] - 2021-11-02 -### Changed -- Set `convertDeprecationsToExceptions` true in PHPUnit config. -- Update PHPUnit configs to include just what needs coverage rather than include everything then try to exclude stuff that doesn't. - -## [1.27.0] - 2021-10-26 -### Added -- Added the _wpas_feature_enabled meta key to the sync list -- Sync Error Log to capture failed sync requests. - -### Fixed -- Check the return value of get_comment() before to use it. -- Increase send timeout to 20 seconds allowing capture of WP.com 408 responses. - -## [1.26.4] - 2021-10-13 -### Changed -- Sync Checksums: Convert text fields to latin1 before generating checksum. -- Updated package dependencies. - -### Fixed -- Sync Checksums - Update distinct clause to use $wpdb-> table names to accouunt for differences in prefixes. - -## [1.26.3] - 2021-10-12 -### Changed -- Updated package dependencies - -### Removed -- Remove initialization of the identity-crisis package. That will be handled by the Config package. - -### Fixed -- Reduce transient expiration for how often we check the state of the queue. -- Sync Checksums - exclude locale from checksum if same as site setting -- Sync Checksums - use distinct query when calculating count of Term Relationships - -## [1.26.2] - 2021-09-28 -### Added -- Add support for checksumming user-related tabled: wp_users and wp_usermeta - -### Changed -- Update annotations versions. -- Updated package dependencies. - -### Fixed -- Resolve indirect modification notice. -- Sync Checksums: utilize distinct clause in term counts. -- Sync Queue: better handling of serialization issues and empty actions. - -## [1.26.1] - 2021-09-03 -### Fixed -- Add better checks if the WooCommerce tables should be enabled for checksum/fix. -- Prevent PHP notices on queue_pull if all args are not set. - -## [1.26.0] - 2021-08-30 -### Added -- Add support for WooCommerce table to the checksum/fix process. -- Enable support for utf8 conversion during checksum calculation. - -### Changed -- Don't run composer install on regular phpunit script -- Tests: update PHPUnit polyfills dependency (yoast/phpunit-polyfills). - -### Fixed -- Sync Checksums - ensure last object is included in histogram - -## [1.25.0] - 2021-08-12 -### Added -- Add package version tracking. -- Add `wpcom_is_fse_activated` to sync list -- Made /sync/object endpoint accessible over POST, not only GET, to allow fetching more items in a single request. - -## [1.24.2] - 2021-08-02 - -- Reverted: Sync option for the Carousel to display colorized slide background. - -## [1.24.1] - 2021-07-29 -### Changed -- Utilize an import for WP_Error in all instances. - -### Fixed -- Fixed unqualified WP_Error use in the Rest_Sender class. - -## [1.24.0] - 2021-07-27 -### Added -- Add a package version constant. -- Add Full Site Editing support to callback options. -- Sync option for the Carousel to display colorized slide background. - -### Fixed -- Update Sender so it adheres to max upload bytes when not encoding items. - -## [1.23.3] - 2021-07-16 -### Fixed -- Update Options module to return jetpack_sync_settings_* values from the Settings class vs direct option lookup. - -## [1.23.2] - 2021-07-13 -### Changed -- Updated package dependencies. - -### Fixed -- Performance of Sync checksums degraded with the update to correlated subquery. This restricts its usage to term_taxonomy joins only." - -## [1.23.1] - 2021-07-01 -### Changed -- Checksum parent_table joins need distinct selection to account for possibility of multiple rows. - -### Fixed -- Update term_taxonomy checksum query to an allowed list vs disallowed - -## [1.23.0] - 2021-06-29 -### Added -- Add jetpack_idc_disonnect action to clear Sync options on disconnect. -- Add support to callables to sync/object endpoint. -- Enable sync/object endpoint support for theme-info. -- Enhance updates module to support get_objects_by_id. -- Expand sync/object to support constants. -- Extend sync/object to support callables. -- Implement v4 REST endpoints. -- Initialize the IDC package in the Sync package. - -### Removed -- Remove product_cat from blocked taxonomies - -## [1.22.0] - 2021-06-15 -### Changed -- Sync: Adding the Identity_Crisis package. -- Updated package dependencies. - -### Deprecated -- Deprecated URL methods in `Automattic\Jetpack\Sync\Functions` in favor of `Automattic\Jetpack\Connection\Urls`. - -## [1.21.3] - 2021-05-25 -### Changed -- Performance: If no Full Sync is in process early return before we update options. - -### Fixed -- Janitorial: avoid PHP notices in some edge-cases -- Update Meta Module so get_object_by_id returns all meta values. - -## [1.21.2] - 2021-04-27 -### Added -- Added the password-checker package the the Sync package composer.json file. - -### Changed -- Updated package dependencies. - -### Fixed -- Sync: removed references to the JETPACK__PLUGIN_DIR constant. -- Sync Checksums : updated postmeta range query performance #19337. - -## [1.21.1] - 2021-03-30 -### Added -- Composer alias for dev-master, to improve dependencies -- Implement a 60 second back-off for non-200 respones, if no retry-after header is present in the response. -- Impose a max limit of 2MB on post meta values that are synced. -- Impose a max limit of 5MB on post_content that can be synced. - -### Changed -- Sync: Use the new Password_Checker package instead of Jetpack_Password_Checker. -- Update package dependencies. -- Use the Heartbeat package to generate the stats array - -### Fixed -- Migrate locks to update_option to avaoid memcache inconsistencies that can be introduced by delete_option usage. -- Update Sync Queue so that serialize is wrapped to catch errors - -## [1.21.0] - 2021-02-23 - -- General: update WordPress version requirements to WP 5.6 -- Update Checksums to support blacklisted taxonomies. -- Refactor Jetpack callables into the plugin using existing filter jetpack_sync_callable_whitelist -- Wrap call_user_func in is_callable so that we don't trigger warnings for callables that don't exist. -- Sync: Trigger initial sync on jetpack_site_registered -- Update Comments checksum field to comment_date_gmt. We cannot use comment_content directly due to charset/filters. -- Deprecate jetpack_json_wrap -- Remove Sync's usage of wp_startswith - -## [1.20.2] - 2021-02-08 - -- Update dependencies to latest stable - -## [1.20.1] - 2021-01-28 - -- Update dependencies to latest stable - -## [1.20.0] - 2021-01-26 - -- Sync Concurrency / Race Conditions -- Sync: Prevent an PHP warning -- Jetpack Sync: Checksums: Use a better way to fetch and validate fields against table -- Add mirror-repo information to all current composer packages -- Full Sync :: Reduce Concurrency. -- Monorepo: Reorganize all projects -- Various PHPCS and Cleanup - -## [1.19.4] - 2021-01-18 - -- Update dependencies to latest stable - -## [1.19.3] - 2021-01-18 - -- Full Sync :: Reduce Concurrency. - -## [1.19.2] - 2020-12-21 - -- Update the do_full_sync function to early return if we are in SYNC READ ONLY mode. -- Return an empty array if the specified range is empty. (It was returning the checksum for the WHOLE dataset). - -## [1.19.1] - 2020-12-17 - -## [1.19.0] - 2020-12-17 - -- sync: Improve sync checksum algorithm and endpoints -- wp_get_environment_type as callable. -- Disallow amp_validated_url as it is not site content but instead validation errors for amp mark-up. -- Whitelist (allow) jetpack_sync_settings_* options to be synced -- Re-order Sync default option whitelist (allowlist) - -## [1.18.1] - 2020-11-24 - -- Version packages for release - -## [1.18.0] - 2020-11-24 - -- Migrate jetpack_published_post to wp_after_insert_post hook -- Check value to determine if we should enable sync after an action enqueuement. -- General: update minimum required version to WordPress 5.5 -- Fix remaining phpcs warnings in most of requirelist -- Update access of comment_status_to_approval_value to allow extension. -- Update get_term Replicastore function to handle term_taxonomy_id option -- Update get_terms to utilize ensure_taxonomy so that the Taxonomy is registered. -- Addtion of note on explict return of null instead of false if option not found. -- Alignment of comment_status_to_approval_value function. Addition of post-trashed status and cleanup of cases. -- Alignment with implemenations. Call ensure_taxonomy to ensure Taxonomies have been initialized. -- Call ensure_taxonomy within get_object_terms so that the taxonomy is registered before action is performed. -- Updated PHPCS: Packages and Debugger - -## [1.17.2] - 2020-11-05 - -- Update dependencies to latest stable - -## [1.17.1] - 2020-10-29 - -- Update dependencies to latest stable - -## [1.17.0] - 2020-10-27 - -- WPCOM Block Editor: Update meta key name -- Resolve PHP Warning with array_filter usage in sync of action_links. -- Sync: Seperate theme data ( name, version, slug and uri) from theme support data -- Replaced intval() with (int) as part of issue #17432. -- Replaced strval() with type casting (string) as part of issue #17432. -- Replaced floatval() with type cast (float) as part of issue #17432. -- Make XMLRPC methods available for blog token - -## [1.16.4] - 2020-10-14 - -- Update dependencies to latest stable - -## [1.16.3] - 2020-10-09 - -- Update dependencies to latest stable - -## [1.16.2] - 2020-10-06 - -- Update dependencies to latest stable - -## [1.16.1] - 2020-10-01 - -- Update dependencies to latest stable - -## [1.16.0] - 2020-09-29 - -- Publicize: Allow publishing a post as a Twitter thread. -- props @jmdodd - filter out set_object_terms actions that don't perform any update. Includes unit tests. -- Sort Arrays by keys before generating callable checksums -- Packages: avoid PHPCS warnings -- Adding 'review' to whitelisted comment types -- Disable Sync sending on Backup API Requests -- Sync: stop trying to check for edit_comment capability -- Added options to sync wc whitelist -- Sync: Improve theme support syncing - -## [1.15.1] - 2020-09-09 - -- Update dependencies to latest stable - -## [1.15.0] - 2020-08-26 - -- Sync: add Creative Mail configuration option to synced options -- Extend sync_status endpoint with optional debug_details field -- REST API endpoints: expand management endpoints -- Sync: Fix nonce action string in theme edit sync -- WP 5.5 Compat: Align Jetpack and Core's plugin autoupdates -- use current user token to updateRole request -- Resolve Sync Errors from empty edge case and WP.com returning concurrent_request_error -- Rework Sender to properly return state during do_full_sync - -## [1.14.4] - 2020-08-10 - -- WP 5.5 Compat: Align Jetpack and Core's plugin autoupdates - -## [1.14.3] - 2020-08-10 - -- Update dependencies to latest stable - -## [1.14.2] - 2020-08-10 - -- Update dependencies to latest stable - -## [1.14.1] - 2020-08-10 - -- Resolve Sync Errors from empty edge case and WP.com returning concurrent_request_error - -## [1.14.0] - 2020-07-28 - -- Core Compat: Site Environment -- Unit Tests: fix tests according to changes in Core -- Utilize the blog token vs master user token to send sync actions. - -## [1.13.2] - 2020-07-06 - -- Update dependencies to latest stable - -## [1.13.1] - 2020-07-01 - -- Update dependencies to latest stable - -## [1.13.0] - 2020-06-30 - -- Block Flamingo Plugin post types in Jetpack Sync -- Explicit single execution of do_full_sync from cron -- Update to reference the property defined in the Jetpack Connection Manager class -- PHPCS: Clean up the packages -- WordAds: Add consent support for California Consumer Privacy Act (CCPA) -- Sync: Add additional support for theme_support_whitelist - -## [1.12.4] - 2020-06-02 - -- Revert "Fix `jetpack sync start` CLI command (#16010)" - -## [1.12.3] - 2020-06-01 - -- Update dependencies to latest stable - -## [1.12.2] - 2020-06-01 - -- Fix `jetpack sync start` CLI command - -## [1.12.1] - 2020-05-29 - -- Sync: Add additional support for theme_support_whitelist - -## [1.12.0] - 2020-05-26 - -- Update ReplicaStore to call clean_comment_cache when comments are upserted or a reset is perofrmed. -- Store the list of active plugins that uses connection in an option -- Jetpack Sync :: Alternate non-blocking flow -- Settings - Writing: add a toggle to Carousel so users can hide comment area -- Sender needs to load consistently utilizing logic -- Always delete items from the queue even if the buffer is no longer checked out. -- Update the hook of Sync's Comment module to not send meta actions when the comment_type is not whitelisted. -- Sync Comments apply whitelist to all actions - -## [1.11.0] - 2020-04-28 - -- Correct inline documentation "Array" type -- Filter out blacklisted post_types for deleted_post actions. -- Publicize: Add jetpack_publicize_options -- Blacklisting Post Types from Sync -- Comments: update default comment type -- Jetpack Sync: Split `jetpack_post_meta_batch_delete` in action to be called in chunks of 100 items, compared to all at once. -- Update Sync limits based on analysis of data loss events. - -## [1.10.0] - 2020-03-31 - -- Update dependencies to latest stable - -## [1.9.0] - 2020-03-31 - -- Debugger: Add sync health progress bar -- Add main network WPCOM blog ID to sync functions -- Masterbar: send wpcom user ID to wpcom when attempting to log… -- Sync: a better readme - -## [1.8.0] - 2020-02-25 - -- Minileven: add options back as they still exist on sites -- Sync: add queue size to actions -- Mobile Theme: remove feature - -## [1.7.6] - 2020-02-14 - -- get_sync_status does not properly account for unexpected states. - -## [1.7.5] - 2020-02-14 - -- Empty Helper function for checkin handler -- Sync Health: fix excessive data loss reports -- Initial Sync Health Status Class and Data Loss Handler -- Stop REST API Log entries from being synced - -## [1.7.4+vip] - 2020-02-14 - -- Empty Helper function for checkin handler - -## [1.7.4] - 2020-01-23 - -- Sync Chunk Keys need to be unique - -## [1.7.3] - 2020-01-20 - -- Sync: ensure we run the initial sync on new connections - -## [1.7.2] - 2020-01-17 - -- Sync Package: use Full_Sync_Immediately by default -- Adding new managed WordPress hosts to be identified in class-functions.php. - -## [1.7.1] - 2020-01-14 - -- Packages: Various improvements for wp.com or self-contained consumers - -## [1.7.0] - 2020-01-14 - -- Trying to add deterministic initialization. - -## [1.6.3] - 2020-01-07 - -- Fix git history. - -## [1.6.2] - 2019-12-31 - -- Sync: Remove DEFAULT_SYNC_MODULES legacy map -- Connection: Loose Comparison for Port Number in Signatures - -## [1.6.1] - 2019-12-13 - -- tweak default sync settings - -## [1.6.0] - 2019-12-02 - -- Sync: Full Sync: Send immediately. - -## [1.5.1] - 2019-11-26 - -- Marked the xmlrpc_api_url method as deprecated. - -## [1.5.0] - 2019-11-25 - -- Remove sync settings cache - -## [1.4.0] - 2019-11-19 - -- Full Sync: Don't allow more than one request to enqueue -- Sync: Update Max Int - -## [1.3.4] - 2019-11-08 - -- Packages: Use classmap instead of PSR-4 - -## [1.3.3] - 2019-11-08 - -- Deprecate Jetpack::is_development_mode() in favor of the packaged Status()->is_development_mode() - -## [1.3.2] - 2019-11-01 - -- Full Sync updates to allow full enqueuing of chunks. - -## [1.3.1] - 2019-10-29 - -- PHPCS: Rest of the packages - -## [1.3.0] - 2019-10-29 - -- Sync: Checkout Endpoint: Add `pop` argument 😱 - -## [1.2.1] - 2019-10-28 - -- Sync: Add Settings to enable/disable the sender for a particular queue - -## [1.2.0] - 2019-10-24 - -- Sync: Fix how we enqueue term_relationships on full sync 🏝 -- WP 5.3: Use modern wp_timezone -- Check for last_error when enqueuing IDs - -## [1.1.1] - 2019-10-23 - -- Use spread operator instead of func_get_args - -## [1.1.0] - 2019-10-07 - -- Sync: Ensure a post object is returned -- PHPCS: Sync Functions -- Sync: Bail initial sync if there is an ongoing full sync - -## [1.0.2] - 2019-09-25 - -- Sync: Only allow white listed comment types to be inserted. -- Sync: Move sync_object XML-RPC method from connection to sync -- Sync: do not sync comments made via Action Scheduler -- Docs: Unify usage of @package phpdoc tags - -## [1.0.1] - 2019-09-14 - -## 1.0.0 - 2019-09-14 - -- Packages: Move sync to a classmapped package - -[4.9.2]: https://github.com/Automattic/jetpack-sync/compare/v4.9.1...v4.9.2 -[4.9.1]: https://github.com/Automattic/jetpack-sync/compare/v4.9.0...v4.9.1 -[4.9.0]: https://github.com/Automattic/jetpack-sync/compare/v4.8.4...v4.9.0 -[4.8.4]: https://github.com/Automattic/jetpack-sync/compare/v4.8.3...v4.8.4 -[4.8.3]: https://github.com/Automattic/jetpack-sync/compare/v4.8.2...v4.8.3 -[4.8.2]: https://github.com/Automattic/jetpack-sync/compare/v4.8.1...v4.8.2 -[4.8.1]: https://github.com/Automattic/jetpack-sync/compare/v4.8.0...v4.8.1 -[4.8.0]: https://github.com/Automattic/jetpack-sync/compare/v4.7.0...v4.8.0 -[4.7.0]: https://github.com/Automattic/jetpack-sync/compare/v4.6.0...v4.7.0 -[4.6.0]: https://github.com/Automattic/jetpack-sync/compare/v4.5.0...v4.6.0 -[4.5.0]: https://github.com/Automattic/jetpack-sync/compare/v4.4.0...v4.5.0 -[4.4.0]: https://github.com/Automattic/jetpack-sync/compare/v4.3.0...v4.4.0 -[4.3.0]: https://github.com/Automattic/jetpack-sync/compare/v4.2.0...v4.3.0 -[4.2.0]: https://github.com/Automattic/jetpack-sync/compare/v4.1.1...v4.2.0 -[4.1.1]: https://github.com/Automattic/jetpack-sync/compare/v4.1.0...v4.1.1 -[4.1.0]: https://github.com/Automattic/jetpack-sync/compare/v4.0.2...v4.1.0 -[4.0.2]: https://github.com/Automattic/jetpack-sync/compare/v4.0.1...v4.0.2 -[4.0.1]: https://github.com/Automattic/jetpack-sync/compare/v4.0.0...v4.0.1 -[4.0.0]: https://github.com/Automattic/jetpack-sync/compare/v3.15.0...v4.0.0 -[3.15.0]: https://github.com/Automattic/jetpack-sync/compare/v3.14.4...v3.15.0 -[3.14.4]: https://github.com/Automattic/jetpack-sync/compare/v3.14.3...v3.14.4 -[3.14.3]: https://github.com/Automattic/jetpack-sync/compare/v3.14.2...v3.14.3 -[3.14.2]: https://github.com/Automattic/jetpack-sync/compare/v3.14.1...v3.14.2 -[3.14.1]: https://github.com/Automattic/jetpack-sync/compare/v3.14.0...v3.14.1 -[3.14.0]: https://github.com/Automattic/jetpack-sync/compare/v3.13.2...v3.14.0 -[3.13.2]: https://github.com/Automattic/jetpack-sync/compare/v3.13.1...v3.13.2 -[3.13.1]: https://github.com/Automattic/jetpack-sync/compare/v3.13.0...v3.13.1 -[3.13.0]: https://github.com/Automattic/jetpack-sync/compare/v3.12.0...v3.13.0 -[3.12.0]: https://github.com/Automattic/jetpack-sync/compare/v3.11.0...v3.12.0 -[3.11.0]: https://github.com/Automattic/jetpack-sync/compare/v3.10.0...v3.11.0 -[3.10.0]: https://github.com/Automattic/jetpack-sync/compare/v3.9.1...v3.10.0 -[3.9.1]: https://github.com/Automattic/jetpack-sync/compare/v3.9.0...v3.9.1 -[3.9.0]: https://github.com/Automattic/jetpack-sync/compare/v3.8.1...v3.9.0 -[3.8.1]: https://github.com/Automattic/jetpack-sync/compare/v3.8.0...v3.8.1 -[3.8.0]: https://github.com/Automattic/jetpack-sync/compare/v3.7.1...v3.8.0 -[3.7.1]: https://github.com/Automattic/jetpack-sync/compare/v3.7.0...v3.7.1 -[3.7.0]: https://github.com/Automattic/jetpack-sync/compare/v3.6.0...v3.7.0 -[3.6.0]: https://github.com/Automattic/jetpack-sync/compare/v3.5.1...v3.6.0 -[3.5.1]: https://github.com/Automattic/jetpack-sync/compare/v3.5.0...v3.5.1 -[3.5.0]: https://github.com/Automattic/jetpack-sync/compare/v3.4.1...v3.5.0 -[3.4.1]: https://github.com/Automattic/jetpack-sync/compare/v3.4.0...v3.4.1 -[3.4.0]: https://github.com/Automattic/jetpack-sync/compare/v3.3.1...v3.4.0 -[3.3.1]: https://github.com/Automattic/jetpack-sync/compare/v3.3.0...v3.3.1 -[3.3.0]: https://github.com/Automattic/jetpack-sync/compare/v3.2.1...v3.3.0 -[3.2.1]: https://github.com/Automattic/jetpack-sync/compare/v3.2.0...v3.2.1 -[3.2.0]: https://github.com/Automattic/jetpack-sync/compare/v3.1.4...v3.2.0 -[3.1.4]: https://github.com/Automattic/jetpack-sync/compare/v3.1.3...v3.1.4 -[3.1.3]: https://github.com/Automattic/jetpack-sync/compare/v3.1.2...v3.1.3 -[3.1.2]: https://github.com/Automattic/jetpack-sync/compare/v3.1.1...v3.1.2 -[3.1.1]: https://github.com/Automattic/jetpack-sync/compare/v3.1.0...v3.1.1 -[3.1.0]: https://github.com/Automattic/jetpack-sync/compare/v3.0.2...v3.1.0 -[3.0.2]: https://github.com/Automattic/jetpack-sync/compare/v3.0.1...v3.0.2 -[3.0.1]: https://github.com/Automattic/jetpack-sync/compare/v3.0.0...v3.0.1 -[3.0.0]: https://github.com/Automattic/jetpack-sync/compare/v2.16.6...v3.0.0 -[2.16.6]: https://github.com/Automattic/jetpack-sync/compare/v2.16.5...v2.16.6 -[2.16.5]: https://github.com/Automattic/jetpack-sync/compare/v2.16.4...v2.16.5 -[2.16.4]: https://github.com/Automattic/jetpack-sync/compare/v2.16.3...v2.16.4 -[2.16.3]: https://github.com/Automattic/jetpack-sync/compare/v2.16.2...v2.16.3 -[2.16.2]: https://github.com/Automattic/jetpack-sync/compare/v2.16.1...v2.16.2 -[2.16.1]: https://github.com/Automattic/jetpack-sync/compare/v2.16.0...v2.16.1 -[2.16.0]: https://github.com/Automattic/jetpack-sync/compare/v2.15.1...v2.16.0 -[2.15.1]: https://github.com/Automattic/jetpack-sync/compare/v2.15.0...v2.15.1 -[2.15.0]: https://github.com/Automattic/jetpack-sync/compare/v2.14.0...v2.15.0 -[2.14.0]: https://github.com/Automattic/jetpack-sync/compare/v2.13.1...v2.14.0 -[2.13.1]: https://github.com/Automattic/jetpack-sync/compare/v2.13.0...v2.13.1 -[2.13.0]: https://github.com/Automattic/jetpack-sync/compare/v2.12.0...v2.13.0 -[2.12.0]: https://github.com/Automattic/jetpack-sync/compare/v2.11.1...v2.12.0 -[2.11.1]: https://github.com/Automattic/jetpack-sync/compare/v2.11.0...v2.11.1 -[2.11.0]: https://github.com/Automattic/jetpack-sync/compare/v2.10.5...v2.11.0 -[2.10.5]: https://github.com/Automattic/jetpack-sync/compare/v2.10.4...v2.10.5 -[2.10.4]: https://github.com/Automattic/jetpack-sync/compare/v2.10.3...v2.10.4 -[2.10.3]: https://github.com/Automattic/jetpack-sync/compare/v2.10.2...v2.10.3 -[2.10.2]: https://github.com/Automattic/jetpack-sync/compare/v2.10.1...v2.10.2 -[2.10.1]: https://github.com/Automattic/jetpack-sync/compare/v2.10.0...v2.10.1 -[2.10.0]: https://github.com/Automattic/jetpack-sync/compare/v2.9.0...v2.10.0 -[2.9.0]: https://github.com/Automattic/jetpack-sync/compare/v2.8.1...v2.9.0 -[2.8.1]: https://github.com/Automattic/jetpack-sync/compare/v2.8.0...v2.8.1 -[2.8.0]: https://github.com/Automattic/jetpack-sync/compare/v2.7.0...v2.8.0 -[2.7.0]: https://github.com/Automattic/jetpack-sync/compare/v2.6.1...v2.7.0 -[2.6.1]: https://github.com/Automattic/jetpack-sync/compare/v2.6.0...v2.6.1 -[2.6.0]: https://github.com/Automattic/jetpack-sync/compare/v2.5.1...v2.6.0 -[2.5.1]: https://github.com/Automattic/jetpack-sync/compare/v2.5.0...v2.5.1 -[2.5.0]: https://github.com/Automattic/jetpack-sync/compare/v2.4.2...v2.5.0 -[2.4.2]: https://github.com/Automattic/jetpack-sync/compare/v2.4.1...v2.4.2 -[2.4.1]: https://github.com/Automattic/jetpack-sync/compare/v2.4.0...v2.4.1 -[2.4.0]: https://github.com/Automattic/jetpack-sync/compare/v2.3.0...v2.4.0 -[2.3.0]: https://github.com/Automattic/jetpack-sync/compare/v2.2.1...v2.3.0 -[2.2.1]: https://github.com/Automattic/jetpack-sync/compare/v2.2.0...v2.2.1 -[2.2.0]: https://github.com/Automattic/jetpack-sync/compare/v2.1.2...v2.2.0 -[2.1.2]: https://github.com/Automattic/jetpack-sync/compare/v2.1.1...v2.1.2 -[2.1.1]: https://github.com/Automattic/jetpack-sync/compare/v2.1.0...v2.1.1 -[2.1.0]: https://github.com/Automattic/jetpack-sync/compare/v2.0.2...v2.1.0 -[2.0.2]: https://github.com/Automattic/jetpack-sync/compare/v2.0.1...v2.0.2 -[2.0.1]: https://github.com/Automattic/jetpack-sync/compare/v2.0.0...v2.0.1 -[2.0.0]: https://github.com/Automattic/jetpack-sync/compare/v1.60.1...v2.0.0 -[1.60.1]: https://github.com/Automattic/jetpack-sync/compare/v1.60.0...v1.60.1 -[1.60.0]: https://github.com/Automattic/jetpack-sync/compare/v1.59.2...v1.60.0 -[1.59.2]: https://github.com/Automattic/jetpack-sync/compare/v1.59.1...v1.59.2 -[1.59.1]: https://github.com/Automattic/jetpack-sync/compare/v1.59.0...v1.59.1 -[1.59.0]: https://github.com/Automattic/jetpack-sync/compare/v1.58.1...v1.59.0 -[1.58.1]: https://github.com/Automattic/jetpack-sync/compare/v1.58.0...v1.58.1 -[1.58.0]: https://github.com/Automattic/jetpack-sync/compare/v1.57.4...v1.58.0 -[1.57.4]: https://github.com/Automattic/jetpack-sync/compare/v1.57.3...v1.57.4 -[1.57.3]: https://github.com/Automattic/jetpack-sync/compare/v1.57.2...v1.57.3 -[1.57.2]: https://github.com/Automattic/jetpack-sync/compare/v1.57.1...v1.57.2 -[1.57.1]: https://github.com/Automattic/jetpack-sync/compare/v1.57.0...v1.57.1 -[1.57.0]: https://github.com/Automattic/jetpack-sync/compare/v1.56.0...v1.57.0 -[1.56.0]: https://github.com/Automattic/jetpack-sync/compare/v1.55.2...v1.56.0 -[1.55.2]: https://github.com/Automattic/jetpack-sync/compare/v1.55.1...v1.55.2 -[1.55.1]: https://github.com/Automattic/jetpack-sync/compare/v1.55.0...v1.55.1 -[1.55.0]: https://github.com/Automattic/jetpack-sync/compare/v1.54.0...v1.55.0 -[1.54.0]: https://github.com/Automattic/jetpack-sync/compare/v1.53.0...v1.54.0 -[1.53.0]: https://github.com/Automattic/jetpack-sync/compare/v1.52.0...v1.53.0 -[1.52.0]: https://github.com/Automattic/jetpack-sync/compare/v1.51.0...v1.52.0 -[1.51.0]: https://github.com/Automattic/jetpack-sync/compare/v1.50.2...v1.51.0 -[1.50.2]: https://github.com/Automattic/jetpack-sync/compare/v1.50.1...v1.50.2 -[1.50.1]: https://github.com/Automattic/jetpack-sync/compare/v1.50.0...v1.50.1 -[1.50.0]: https://github.com/Automattic/jetpack-sync/compare/v1.49.0...v1.50.0 -[1.49.0]: https://github.com/Automattic/jetpack-sync/compare/v1.48.1...v1.49.0 -[1.48.1]: https://github.com/Automattic/jetpack-sync/compare/v1.48.0...v1.48.1 -[1.48.0]: https://github.com/Automattic/jetpack-sync/compare/v1.47.9...v1.48.0 -[1.47.9]: https://github.com/Automattic/jetpack-sync/compare/v1.47.8...v1.47.9 -[1.47.8]: https://github.com/Automattic/jetpack-sync/compare/v1.47.7...v1.47.8 -[1.47.7]: https://github.com/Automattic/jetpack-sync/compare/v1.47.6...v1.47.7 -[1.47.6]: https://github.com/Automattic/jetpack-sync/compare/v1.47.5...v1.47.6 -[1.47.5]: https://github.com/Automattic/jetpack-sync/compare/v1.47.4...v1.47.5 -[1.47.4]: https://github.com/Automattic/jetpack-sync/compare/v1.47.3...v1.47.4 -[1.47.3]: https://github.com/Automattic/jetpack-sync/compare/v1.47.2...v1.47.3 -[1.47.2]: https://github.com/Automattic/jetpack-sync/compare/v1.47.1...v1.47.2 -[1.47.1]: https://github.com/Automattic/jetpack-sync/compare/v1.47.0...v1.47.1 -[1.47.0]: https://github.com/Automattic/jetpack-sync/compare/v1.46.1...v1.47.0 -[1.46.1]: https://github.com/Automattic/jetpack-sync/compare/v1.46.0...v1.46.1 -[1.46.0]: https://github.com/Automattic/jetpack-sync/compare/v1.45.0...v1.46.0 -[1.45.0]: https://github.com/Automattic/jetpack-sync/compare/v1.44.2...v1.45.0 -[1.44.2]: https://github.com/Automattic/jetpack-sync/compare/v1.44.1...v1.44.2 -[1.44.1]: https://github.com/Automattic/jetpack-sync/compare/v1.44.0...v1.44.1 -[1.44.0]: https://github.com/Automattic/jetpack-sync/compare/v1.43.2...v1.44.0 -[1.43.2]: https://github.com/Automattic/jetpack-sync/compare/v1.43.1...v1.43.2 -[1.43.1]: https://github.com/Automattic/jetpack-sync/compare/v1.43.0...v1.43.1 -[1.43.0]: https://github.com/Automattic/jetpack-sync/compare/v1.42.0...v1.43.0 -[1.42.0]: https://github.com/Automattic/jetpack-sync/compare/v1.41.0...v1.42.0 -[1.41.0]: https://github.com/Automattic/jetpack-sync/compare/v1.40.3...v1.41.0 -[1.40.3]: https://github.com/Automattic/jetpack-sync/compare/v1.40.2...v1.40.3 -[1.40.2]: https://github.com/Automattic/jetpack-sync/compare/v1.40.1...v1.40.2 -[1.40.1]: https://github.com/Automattic/jetpack-sync/compare/v1.40.0...v1.40.1 -[1.40.0]: https://github.com/Automattic/jetpack-sync/compare/v1.39.0...v1.40.0 -[1.39.0]: https://github.com/Automattic/jetpack-sync/compare/v1.38.4...v1.39.0 -[1.38.4]: https://github.com/Automattic/jetpack-sync/compare/v1.38.3...v1.38.4 -[1.38.3]: https://github.com/Automattic/jetpack-sync/compare/v1.38.2...v1.38.3 -[1.38.2]: https://github.com/Automattic/jetpack-sync/compare/v1.38.1...v1.38.2 -[1.38.1]: https://github.com/Automattic/jetpack-sync/compare/v1.38.0...v1.38.1 -[1.38.0]: https://github.com/Automattic/jetpack-sync/compare/v1.37.1...v1.38.0 -[1.37.1]: https://github.com/Automattic/jetpack-sync/compare/v1.37.0...v1.37.1 -[1.37.0]: https://github.com/Automattic/jetpack-sync/compare/v1.36.1...v1.37.0 -[1.36.1]: https://github.com/Automattic/jetpack-sync/compare/v1.36.0...v1.36.1 -[1.36.0]: https://github.com/Automattic/jetpack-sync/compare/v1.35.2...v1.36.0 -[1.35.2]: https://github.com/Automattic/jetpack-sync/compare/v1.35.1...v1.35.2 -[1.35.1]: https://github.com/Automattic/jetpack-sync/compare/v1.35.0...v1.35.1 -[1.35.0]: https://github.com/Automattic/jetpack-sync/compare/v1.34.0...v1.35.0 -[1.34.0]: https://github.com/Automattic/jetpack-sync/compare/v1.33.1...v1.34.0 -[1.33.1]: https://github.com/Automattic/jetpack-sync/compare/v1.33.0...v1.33.1 -[1.33.0]: https://github.com/Automattic/jetpack-sync/compare/v1.32.0...v1.33.0 -[1.32.0]: https://github.com/Automattic/jetpack-sync/compare/v1.31.1...v1.32.0 -[1.31.1]: https://github.com/Automattic/jetpack-sync/compare/v1.31.0...v1.31.1 -[1.31.0]: https://github.com/Automattic/jetpack-sync/compare/v1.30.8...v1.31.0 -[1.30.8]: https://github.com/Automattic/jetpack-sync/compare/v1.30.7...v1.30.8 -[1.30.7]: https://github.com/Automattic/jetpack-sync/compare/v1.30.6...v1.30.7 -[1.30.6]: https://github.com/Automattic/jetpack-sync/compare/v1.30.5...v1.30.6 -[1.30.5]: https://github.com/Automattic/jetpack-sync/compare/v1.30.4...v1.30.5 -[1.30.4]: https://github.com/Automattic/jetpack-sync/compare/v1.30.3...v1.30.4 -[1.30.3]: https://github.com/Automattic/jetpack-sync/compare/v1.30.2...v1.30.3 -[1.30.2]: https://github.com/Automattic/jetpack-sync/compare/v1.30.1...v1.30.2 -[1.30.1]: https://github.com/Automattic/jetpack-sync/compare/v1.30.0...v1.30.1 -[1.30.0]: https://github.com/Automattic/jetpack-sync/compare/v1.29.2...v1.30.0 -[1.29.2]: https://github.com/Automattic/jetpack-sync/compare/v1.29.1...v1.29.2 -[1.29.1]: https://github.com/Automattic/jetpack-sync/compare/v1.29.0...v1.29.1 -[1.29.0]: https://github.com/Automattic/jetpack-sync/compare/v1.28.2...v1.29.0 -[1.28.2]: https://github.com/Automattic/jetpack-sync/compare/v1.28.1...v1.28.2 -[1.28.1]: https://github.com/Automattic/jetpack-sync/compare/v1.28.0...v1.28.1 -[1.28.0]: https://github.com/Automattic/jetpack-sync/compare/v1.27.6...v1.28.0 -[1.27.6]: https://github.com/Automattic/jetpack-sync/compare/v1.27.5...v1.27.6 -[1.27.5]: https://github.com/Automattic/jetpack-sync/compare/v1.27.4...v1.27.5 -[1.27.4]: https://github.com/Automattic/jetpack-sync/compare/v1.27.3...v1.27.4 -[1.27.3]: https://github.com/Automattic/jetpack-sync/compare/v1.27.2...v1.27.3 -[1.27.2]: https://github.com/Automattic/jetpack-sync/compare/v1.27.1...v1.27.2 -[1.27.1]: https://github.com/Automattic/jetpack-sync/compare/v1.27.0...v1.27.1 -[1.27.0]: https://github.com/Automattic/jetpack-sync/compare/v1.26.4...v1.27.0 -[1.26.4]: https://github.com/Automattic/jetpack-sync/compare/v1.26.3...v1.26.4 -[1.26.3]: https://github.com/Automattic/jetpack-sync/compare/v1.26.2...v1.26.3 -[1.26.2]: https://github.com/Automattic/jetpack-sync/compare/v1.26.1...v1.26.2 -[1.26.1]: https://github.com/Automattic/jetpack-sync/compare/v1.26.0...v1.26.1 -[1.26.0]: https://github.com/Automattic/jetpack-sync/compare/v1.25.0...v1.26.0 -[1.25.0]: https://github.com/Automattic/jetpack-sync/compare/v1.24.2...v1.25.0 -[1.24.2]: https://github.com/Automattic/jetpack-sync/compare/v1.24.1...v1.24.2 -[1.24.1]: https://github.com/Automattic/jetpack-sync/compare/v1.24.0...v1.24.1 -[1.24.0]: https://github.com/Automattic/jetpack-sync/compare/v1.23.3...v1.24.0 -[1.23.3]: https://github.com/Automattic/jetpack-sync/compare/v1.23.2...v1.23.3 -[1.23.2]: https://github.com/Automattic/jetpack-sync/compare/v1.23.1...v1.23.2 -[1.23.1]: https://github.com/Automattic/jetpack-sync/compare/v1.23.0...v1.23.1 -[1.23.0]: https://github.com/Automattic/jetpack-sync/compare/v1.22.0...v1.23.0 -[1.22.0]: https://github.com/Automattic/jetpack-sync/compare/v1.21.3...v1.22.0 -[1.21.3]: https://github.com/Automattic/jetpack-sync/compare/v1.21.2...v1.21.3 -[1.21.2]: https://github.com/Automattic/jetpack-sync/compare/v1.21.1...v1.21.2 -[1.21.1]: https://github.com/Automattic/jetpack-sync/compare/v1.21.0...v1.21.1 -[1.21.0]: https://github.com/Automattic/jetpack-sync/compare/v1.20.2...v1.21.0 -[1.20.2]: https://github.com/Automattic/jetpack-sync/compare/v1.20.1...v1.20.2 -[1.20.1]: https://github.com/Automattic/jetpack-sync/compare/v1.20.0...v1.20.1 -[1.20.0]: https://github.com/Automattic/jetpack-sync/compare/v1.19.4...v1.20.0 -[1.19.4]: https://github.com/Automattic/jetpack-sync/compare/v1.19.3...v1.19.4 -[1.19.3]: https://github.com/Automattic/jetpack-sync/compare/v1.19.2...v1.19.3 -[1.19.2]: https://github.com/Automattic/jetpack-sync/compare/v1.19.1...v1.19.2 -[1.19.1]: https://github.com/Automattic/jetpack-sync/compare/v1.19.0...v1.19.1 -[1.19.0]: https://github.com/Automattic/jetpack-sync/compare/v1.18.1...v1.19.0 -[1.18.1]: https://github.com/Automattic/jetpack-sync/compare/v1.18.0...v1.18.1 -[1.18.0]: https://github.com/Automattic/jetpack-sync/compare/v1.17.2...v1.18.0 -[1.17.2]: https://github.com/Automattic/jetpack-sync/compare/v1.17.1...v1.17.2 -[1.17.1]: https://github.com/Automattic/jetpack-sync/compare/v1.17.0...v1.17.1 -[1.17.0]: https://github.com/Automattic/jetpack-sync/compare/v1.16.4...v1.17.0 -[1.16.4]: https://github.com/Automattic/jetpack-sync/compare/v1.16.3...v1.16.4 -[1.16.3]: https://github.com/Automattic/jetpack-sync/compare/v1.16.2...v1.16.3 -[1.16.2]: https://github.com/Automattic/jetpack-sync/compare/v1.16.1...v1.16.2 -[1.16.1]: https://github.com/Automattic/jetpack-sync/compare/v1.16.0...v1.16.1 -[1.16.0]: https://github.com/Automattic/jetpack-sync/compare/v1.15.1...v1.16.0 -[1.15.1]: https://github.com/Automattic/jetpack-sync/compare/v1.15.0...v1.15.1 -[1.15.0]: https://github.com/Automattic/jetpack-sync/compare/v1.14.4...v1.15.0 -[1.14.4]: https://github.com/Automattic/jetpack-sync/compare/v1.14.3...v1.14.4 -[1.14.3]: https://github.com/Automattic/jetpack-sync/compare/v1.14.2...v1.14.3 -[1.14.2]: https://github.com/Automattic/jetpack-sync/compare/v1.14.1...v1.14.2 -[1.14.1]: https://github.com/Automattic/jetpack-sync/compare/v1.14.0...v1.14.1 -[1.14.0]: https://github.com/Automattic/jetpack-sync/compare/v1.13.2...v1.14.0 -[1.13.2]: https://github.com/Automattic/jetpack-sync/compare/v1.13.1...v1.13.2 -[1.13.1]: https://github.com/Automattic/jetpack-sync/compare/v1.13.0...v1.13.1 -[1.13.0]: https://github.com/Automattic/jetpack-sync/compare/v1.12.4...v1.13.0 -[1.12.4]: https://github.com/Automattic/jetpack-sync/compare/v1.12.3...v1.12.4 -[1.12.3]: https://github.com/Automattic/jetpack-sync/compare/v1.12.2...v1.12.3 -[1.12.2]: https://github.com/Automattic/jetpack-sync/compare/v1.12.1...v1.12.2 -[1.12.1]: https://github.com/Automattic/jetpack-sync/compare/v1.12.0...v1.12.1 -[1.12.0]: https://github.com/Automattic/jetpack-sync/compare/v1.11.0...v1.12.0 -[1.11.0]: https://github.com/Automattic/jetpack-sync/compare/v1.10.0...v1.11.0 -[1.10.0]: https://github.com/Automattic/jetpack-sync/compare/v1.9.0...v1.10.0 -[1.9.0]: https://github.com/Automattic/jetpack-sync/compare/v1.8.0...v1.9.0 -[1.8.0]: https://github.com/Automattic/jetpack-sync/compare/v1.7.6...v1.8.0 -[1.7.6]: https://github.com/Automattic/jetpack-sync/compare/v1.7.5...v1.7.6 -[1.7.5]: https://github.com/Automattic/jetpack-sync/compare/v1.7.4+vip...v1.7.5 -[1.7.4+vip]: https://github.com/Automattic/jetpack-sync/compare/v1.7.4...v1.7.4+vip -[1.7.4]: https://github.com/Automattic/jetpack-sync/compare/v1.7.3...v1.7.4 -[1.7.3]: https://github.com/Automattic/jetpack-sync/compare/v1.7.2...v1.7.3 -[1.7.2]: https://github.com/Automattic/jetpack-sync/compare/v1.7.1...v1.7.2 -[1.7.1]: https://github.com/Automattic/jetpack-sync/compare/v1.7.0...v1.7.1 -[1.7.0]: https://github.com/Automattic/jetpack-sync/compare/v1.6.3...v1.7.0 -[1.6.3]: https://github.com/Automattic/jetpack-sync/compare/v1.6.2...v1.6.3 -[1.6.2]: https://github.com/Automattic/jetpack-sync/compare/v1.6.1...v1.6.2 -[1.6.1]: https://github.com/Automattic/jetpack-sync/compare/v1.6.0...v1.6.1 -[1.6.0]: https://github.com/Automattic/jetpack-sync/compare/v1.5.1...v1.6.0 -[1.5.1]: https://github.com/Automattic/jetpack-sync/compare/v1.5.0...v1.5.1 -[1.5.0]: https://github.com/Automattic/jetpack-sync/compare/v1.4.0...v1.5.0 -[1.4.0]: https://github.com/Automattic/jetpack-sync/compare/v1.3.4...v1.4.0 -[1.3.4]: https://github.com/Automattic/jetpack-sync/compare/v1.3.3...v1.3.4 -[1.3.3]: https://github.com/Automattic/jetpack-sync/compare/v1.3.2...v1.3.3 -[1.3.2]: https://github.com/Automattic/jetpack-sync/compare/v1.3.1...v1.3.2 -[1.3.1]: https://github.com/Automattic/jetpack-sync/compare/v1.3.0...v1.3.1 -[1.3.0]: https://github.com/Automattic/jetpack-sync/compare/v1.2.1...v1.3.0 -[1.2.1]: https://github.com/Automattic/jetpack-sync/compare/v1.2.0...v1.2.1 -[1.2.0]: https://github.com/Automattic/jetpack-sync/compare/v1.1.1...v1.2.0 -[1.1.1]: https://github.com/Automattic/jetpack-sync/compare/v1.1.0...v1.1.1 -[1.1.0]: https://github.com/Automattic/jetpack-sync/compare/v1.0.2...v1.1.0 -[1.0.2]: https://github.com/Automattic/jetpack-sync/compare/v1.0.1...v1.0.2 -[1.0.1]: https://github.com/Automattic/jetpack-sync/compare/v1.0.0...v1.0.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/composer.json deleted file mode 100644 index 5e755590..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/composer.json +++ /dev/null @@ -1,69 +0,0 @@ -{ - "name": "automattic/jetpack-sync", - "description": "Everything needed to allow syncing to the WP.com infrastructure.", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-connection": "^6.7.7", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-password-checker": "^0.4.7", - "automattic/jetpack-ip": "^0.4.6", - "automattic/jetpack-roles": "^3.0.5", - "automattic/jetpack-status": "^5.0.10" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-search": "@dev", - "automattic/jetpack-waf": "@dev", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-sync", - "textdomain": "jetpack-sync", - "version-constants": { - "::PACKAGE_VERSION": "src/class-package-version.php" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "4.9.x-dev" - }, - "dependencies": { - "test-only": [ - "packages/search", - "packages/waf" - ] - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php deleted file mode 100644 index 380e066a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php +++ /dev/null @@ -1,1200 +0,0 @@ -do_dedicated_sync_and_exit(); - } - } - - /** - * Define JETPACK_SYNC_READ_ONLY constant if not defined. - * This notifies sync to not run in shutdown if it was initialized during init. - * - * @access public - * @static - */ - public static function mark_sync_read_only() { - Constants::set_constant( 'JETPACK_SYNC_READ_ONLY', true ); - } - - /** - * Decides if the sender should run on shutdown for this request. - * - * @access public - * @static - * - * @param bool $full_sync Whether the Full Sync sender should run on shutdown for this request. - * - * @return bool - */ - public static function should_initialize_sender( $full_sync = false ) { - - // Allow for explicit disable of Sync from request param jetpack_sync_read_only. - if ( isset( $_REQUEST['jetpack_sync_read_only'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification - self::mark_sync_read_only(); - return false; - } - - if ( Constants::is_true( 'DOING_CRON' ) ) { - return self::sync_via_cron_allowed(); - } - - /** - * For now, if dedicated Sync is enabled we will always initialize send, even for GET and unauthenticated requests - * but not for Full Sync, since it will still happen on shutdown. - */ - if ( false === $full_sync && Settings::is_dedicated_sync_enabled() ) { - return true; - } - - if ( isset( $_SERVER['REQUEST_METHOD'] ) && 'POST' === $_SERVER['REQUEST_METHOD'] ) { - return true; - } - - if ( current_user_can( 'manage_options' ) ) { - return true; - } - - if ( is_admin() ) { - return true; - } - - if ( defined( 'PHPUNIT_JETPACK_TESTSUITE' ) ) { - return true; - } - - if ( Constants::get_constant( 'WP_CLI' ) ) { - return true; - } - - return false; - } - - /** - * Decides if the sender should run on shutdown when actions are queued. - * - * @access public - * @static - * - * @param bool $enable Should we initilize sender. - * @return bool - */ - public static function should_initialize_sender_enqueue( $enable ) { - - // If $enabled is false don't modify it, only check cron if enabled. - if ( false === $enable ) { - return $enable; - } - - if ( Constants::is_true( 'DOING_CRON' ) ) { - return self::sync_via_cron_allowed(); - } - - return true; - } - - /** - * Decides if sync should run at all during this request. - * - * @access public - * @static - * - * @return bool - */ - public static function sync_allowed() { - if ( defined( 'IS_WPCOM' ) && IS_WPCOM ) { - return false; - } - - if ( defined( 'PHPUNIT_JETPACK_TESTSUITE' ) ) { - return true; - } - - if ( ! Settings::is_sync_enabled() ) { - return false; - } - - if ( ( new Status() )->is_offline_mode() ) { - return false; - } - - $connection = new Jetpack_Connection(); - if ( ! $connection->is_connected() ) { - if ( ! doing_action( 'jetpack_site_registered' ) ) { - return false; - } - } - - // By now, we know the site is connected, so we can return false if in safe mode. - if ( ( new Status() )->in_safe_mode() ) { - return false; - } - - return true; - } - - /** - * Helper function to get details as to why sync is not allowed, if it is not allowed. - * - * @return array - */ - public static function get_debug_details() { - $debug = array(); - $debug['debug_details']['sync_allowed'] = self::sync_allowed(); - $debug['debug_details']['sync_health'] = Health::get_status(); - if ( false === $debug['debug_details']['sync_allowed'] ) { - if ( defined( 'IS_WPCOM' ) && IS_WPCOM ) { - $debug['debug_details']['is_wpcom'] = true; - } - if ( defined( 'PHPUNIT_JETPACK_TESTSUITE' ) ) { - $debug['debug_details']['PHPUNIT_JETPACK_TESTSUITE'] = true; - } - if ( ! Settings::is_sync_enabled() ) { - $debug['debug_details']['is_sync_enabled'] = false; - $debug['debug_details']['jetpack_sync_disable'] = Settings::get_setting( 'disable' ); - $debug['debug_details']['jetpack_sync_network_disable'] = Settings::get_setting( 'network_disable' ); - } - if ( ( new Status() )->is_offline_mode() ) { - $debug['debug_details']['is_offline_mode'] = true; - } - if ( ( new Status() )->in_safe_mode() ) { - $debug['debug_details']['in_safe_mode'] = true; - } - $connection = new Jetpack_Connection(); - if ( ! $connection->is_connected() ) { - $debug['debug_details']['active_connection'] = false; - } - } - - // Sync locks. - $debug['debug_details']['dedicated_sync_enabled'] = Settings::is_dedicated_sync_enabled(); - - $queue = self::$sender->get_sync_queue(); - $full_queue = self::$sender->get_full_sync_queue(); - - $debug['debug_details']['sync_locks'] = array( - 'retry_time_sync' => get_option( self::RETRY_AFTER_PREFIX . 'sync' ), - 'retry_time_full_sync' => get_option( self::RETRY_AFTER_PREFIX . 'full_sync' ), - 'next_sync_time_sync' => self::$sender->get_next_sync_time( 'sync' ), - 'next_sync_time_full_sync' => self::$sender->get_next_sync_time( 'full_sync' ), - 'queue_locked_sync' => $queue->is_locked(), - 'queue_locked_full_sync' => $full_queue->is_locked(), - 'dedicated_sync_request_lock' => \Jetpack_Options::get_raw_option( Dedicated_Sender::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, null ), - 'dedicated_sync_temporary_disable_flag' => get_transient( Dedicated_Sender::DEDICATED_SYNC_TEMPORARY_DISABLE_FLAG ), - ); - - // Sync Logs. - $debug['debug_details']['last_succesful_sync'] = get_option( self::LAST_SUCCESS_PREFIX . 'sync', '' ); - $debug['debug_details']['sync_error_log'] = get_option( self::ERROR_LOG_PREFIX . 'sync', '' ); - - return $debug; - } - - /** - * Determines if syncing during a cron job is allowed. - * - * @access public - * @static - * - * @return bool|int - */ - public static function sync_via_cron_allowed() { - return ( Settings::get_setting( 'sync_via_cron' ) ); - } - - /** - * Decides if the given post should be Publicized based on its type. - * - * @access public - * @static - * - * @param bool $should_publicize Publicize status prior to this filter running. - * @param \WP_Post $post The post to test for Publicizability. - * @return bool - */ - public static function prevent_publicize_blacklisted_posts( $should_publicize, $post ) { - if ( in_array( $post->post_type, Settings::get_setting( 'post_types_blacklist' ), true ) ) { - return false; - } - - return $should_publicize; - } - - /** - * Set an importing flag to `true` in sync settings. - * - * @access public - * @static - */ - public static function set_is_importing_true() { - Settings::set_importing( true ); - } - - /** - * Sends data to WordPress.com via an XMLRPC or a REST API request based on the settings. - * - * @access public - * @static - * - * @param object $data Data relating to a sync action. - * @param string $codec_name The name of the codec that encodes the data. - * @param float $sent_timestamp Current server time so we can compensate for clock differences. - * @param string $queue_id The queue the action belongs to, sync or full_sync. - * @param float $checkout_duration Time spent retrieving queue items from the DB. - * @param float $preprocess_duration Time spent converting queue items into data to send. - * @param int $queue_size The size of the sync queue at the time of processing. - * @param string $buffer_id The ID of the Queue buffer checked out for processing. - * @return mixed|WP_Error The result of the sending request. - */ - public static function send_data( $data, $codec_name, $sent_timestamp, $queue_id, $checkout_duration, $preprocess_duration, $queue_size = null, $buffer_id = null ) { - - $query_args = array( - - 'sync' => '1', // Add an extra parameter to the URL so we can tell it's a sync action. - 'codec' => $codec_name, - 'timestamp' => $sent_timestamp, - 'queue' => $queue_id, - 'cd' => sprintf( '%.4f', $checkout_duration ), - 'pd' => sprintf( '%.4f', $preprocess_duration ), - 'queue_size' => $queue_size, - 'buffer_id' => $buffer_id, - // TODO this will be extended in the future. Might be good to extract in a separate method to support future entries too. - 'sync_flow_type' => Settings::is_dedicated_sync_enabled() ? 'dedicated' : 'default', - 'storage_type' => Settings::is_custom_queue_table_enabled() ? 'custom' : 'options', - ); - - $query_args['timeout'] = Settings::is_doing_cron() ? 30 : 20; - - if ( 'immediate-send' === $queue_id ) { - $query_args['timeout'] = 30; - } - - /** - * Filters query parameters appended to the Sync request URL sent to WordPress.com. - * - * @since 1.6.3 - * @since-jetpack 4.7.0 - * - * @param array $query_args associative array of query parameters. - */ - $query_args = apply_filters( 'jetpack_sync_send_data_query_args', $query_args ); - - $retry_after_header = false; - $dedicated_sync_header = false; - - // If REST API is enabled, use it. - if ( Settings::is_wpcom_rest_api_enabled() ) { - $jsonl_data = self::prepare_jsonl_data( $data ); - $url = '/sites/' . \Jetpack_Options::get_option( 'id' ) . '/jetpack-sync-actions'; - $url = add_query_arg( $query_args, $url ); - $args = array( - 'method' => 'POST', - 'format' => 'jsonl', - 'timeout' => $query_args['timeout'], - ); - - $response = Client::wpcom_json_api_request_as_blog( $url, '2', $args, $jsonl_data, 'wpcom' ); - $retry_after_header = wp_remote_retrieve_header( $response, 'Retry-After' ) ? wp_remote_retrieve_header( $response, 'Retry-After' ) : false; - $dedicated_sync_header = wp_remote_retrieve_header( $response, 'Jetpack-Dedicated-Sync' ) ? wp_remote_retrieve_header( $response, 'Jetpack-Dedicated-Sync' ) : false; - $response = self::process_rest_api_response( $response ); - } else { // Use XML-RPC. - $connection = new Jetpack_Connection(); - $url = add_query_arg( $query_args, $connection->xmlrpc_api_url() ); - - // If we're currently updating to Jetpack 7.7, the IXR client may be missing briefly - // because since 7.7 it's being autoloaded with Composer. - if ( ! class_exists( '\\Jetpack_IXR_Client' ) ) { - return new WP_Error( - 'ixr_client_missing', - esc_html__( 'Sync has been aborted because the IXR client is missing.', 'jetpack-sync' ) - ); - } - - $rpc = new \Jetpack_IXR_Client( - array( - 'url' => $url, - 'timeout' => $query_args['timeout'], - ) - ); - $result = $rpc->query( 'jetpack.syncActions', $data ); - $retry_after_header = $rpc->get_response_header( 'Retry-After' ); - $dedicated_sync_header = $rpc->get_response_header( 'Jetpack-Dedicated-Sync' ); - if ( $result ) { - $response = $rpc->getResponse(); - } else { - $response = $rpc->get_jetpack_error(); - } - } - - // Adhere to Retry-After headers. - if ( false !== $retry_after_header ) { - if ( (int) $retry_after_header > 0 ) { - update_option( self::RETRY_AFTER_PREFIX . $queue_id, microtime( true ) + (int) $retry_after_header, false ); - } else { - // if unexpected value default to 3 minutes. - update_option( self::RETRY_AFTER_PREFIX . $queue_id, microtime( true ) + 180, false ); - } - } - - // Enable/Disable Dedicated Sync flow via response headers. - if ( false !== $dedicated_sync_header ) { - Dedicated_Sender::maybe_change_dedicated_sync_status_from_wpcom_header( $dedicated_sync_header ); - } - - if ( is_wp_error( $response ) ) { - $error = $response; - if ( false === $retry_after_header ) { - // We received a non standard response from WP.com, lets backoff from sending requests for 1 minute. - update_option( self::RETRY_AFTER_PREFIX . $queue_id, microtime( true ) + 60, false ); - } - // Record Sync Errors. - $error_log = get_option( self::ERROR_LOG_PREFIX . $queue_id, array() ); - if ( ! is_array( $error_log ) ) { - $error_log = array(); - } - // Trim existing array to last 4 entries. - if ( 5 <= count( $error_log ) ) { - $error_log = array_slice( $error_log, -4, null, true ); - } - // Add new error indexed to time. - if ( isset( $rpc ) && ! empty( $rpc->get_last_response() ) ) { - $error_with_last_response = clone $error; - $error_with_last_response->add_data( $rpc->get_last_response() ); - $error_log[ (string) microtime( true ) ] = $error_with_last_response; - } else { - $error_log[ (string) microtime( true ) ] = $error; - } - - // Update the error log. - update_option( self::ERROR_LOG_PREFIX . $queue_id, $error_log ); - return $error; - } - - // Check if WordPress.com IDC mitigation blocked the sync request. - if ( Identity_Crisis::init()->check_response_for_idc( $response ) ) { - return new WP_Error( - 'sync_error_idc', - esc_html__( 'Sync has been blocked from WordPress.com because it would cause an identity crisis', 'jetpack-sync' ) - ); - } - - if ( isset( $response['processed_items'] ) ) { // Return only processed items. - $response = $response['processed_items']; - } - - // Record last successful sync. - update_option( self::LAST_SUCCESS_PREFIX . $queue_id, microtime( true ), false ); - - return $response; - } - - /** - * Kicks off the initial sync. - * - * @access public - * @static - * - * @return bool|null False if sync is not allowed. - */ - public static function do_initial_sync() { - // Let's not sync if we are not supposed to. - if ( ! self::sync_allowed() ) { - return false; - } - - // Don't start new sync if a full sync is in process. - $full_sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $full_sync_module'; - if ( $full_sync_module && $full_sync_module->is_started() && ! $full_sync_module->is_finished() ) { - return false; - } - - $initial_sync_config = array( - 'options' => true, - 'functions' => true, - 'constants' => true, - 'users' => array( get_current_user_id() ), - 'network_options' => true, - ); - - self::do_full_sync( $initial_sync_config, 'initial_sync' ); - } - - /** - * Do an initial full sync only if one has not already been started. - * - * @return bool|null False if the initial full sync was already started, otherwise null. - */ - public static function do_only_first_initial_sync() { - $full_sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $full_sync_module'; - if ( $full_sync_module && $full_sync_module->is_started() ) { - return false; - } - - static::do_initial_sync(); - } - - /** - * Kicks off a full sync. - * - * @access public - * @static - * - * @param array $modules The sync modules should be included in this full sync. All will be included if null. - * @param mixed $context The context where the full sync was initiated from. - * @return bool True if full sync was successfully started. - */ - public static function do_full_sync( $modules = null, $context = null ) { - if ( ! self::sync_allowed() ) { - return false; - } - - $full_sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $full_sync_module'; - - if ( ! $full_sync_module ) { - return false; - } - - self::initialize_listener(); - - $full_sync_module->start( $modules, $context ); - - return true; - } - - /** - * Adds a cron schedule for regular syncing via cron, unless the schedule already exists. - * - * @access public - * @static - * - * @param array $schedules The list of WordPress cron schedules prior to this filter. - * @return array A list of WordPress cron schedules with the Jetpack sync interval added. - */ - public static function jetpack_cron_schedule( $schedules ) { - if ( ! isset( $schedules[ self::DEFAULT_SYNC_CRON_INTERVAL_NAME ] ) ) { - $minutes = (int) ( self::DEFAULT_SYNC_CRON_INTERVAL_VALUE / 60 ); - $display = ( 1 === $minutes ) ? - __( 'Every minute', 'jetpack-sync' ) : - /* translators: %d is an integer indicating the number of minutes. */ - sprintf( __( 'Every %d minutes', 'jetpack-sync' ), $minutes ); - $schedules[ self::DEFAULT_SYNC_CRON_INTERVAL_NAME ] = array( - 'interval' => self::DEFAULT_SYNC_CRON_INTERVAL_VALUE, - 'display' => $display, - ); - } - return $schedules; - } - - /** - * Starts an incremental sync via cron. - * - * @access public - * @static - */ - public static function do_cron_sync() { - self::do_cron_sync_by_type( 'sync' ); - } - - /** - * Starts a full sync via cron. - * - * @access public - * @static - */ - public static function do_cron_full_sync() { - self::do_cron_sync_by_type( 'full_sync' ); - } - - /** - * Try to send actions until we run out of things to send, - * or have to wait more than 15s before sending again, - * or we hit a lock or some other sending issue - * - * @access public - * @static - * - * @param string $type Sync type. Can be `sync` or `full_sync`. - */ - public static function do_cron_sync_by_type( $type ) { - if ( ! self::sync_allowed() || ( 'sync' !== $type && 'full_sync' !== $type ) ) { - return; - } - - self::initialize_sender(); - - $time_limit = Settings::get_setting( 'cron_sync_time_limit' ); - $start_time = time(); - $executions = 0; - - do { - $next_sync_time = self::$sender->get_next_sync_time( $type ); - - if ( $next_sync_time ) { - $delay = $next_sync_time - time() + 1; - if ( $delay > 15 ) { - break; - } elseif ( $delay > 0 ) { - sleep( $delay ); - } - } - - // Explicitly only allow 1 do_full_sync call until issue with Immediate Full Sync is resolved. - // For more context see p1HpG7-9pe-p2. - if ( 'full_sync' === $type && $executions >= 1 ) { - break; - } - - /** - * Only try to sync once if Dedicated Sync is enabled. Dedicated Sync has its own requeueing mechanism - * that will re-run it if there are items in the queue at the end. - */ - if ( 'sync' === $type && $executions >= 1 && Settings::is_dedicated_sync_enabled() ) { - break; - } - - $result = 'full_sync' === $type ? self::$sender->do_full_sync() : self::$sender->do_sync(); - - // # of send actions performed. - ++$executions; - - } while ( $result && ! is_wp_error( $result ) && ( $start_time + $time_limit ) > time() ); - - return $executions; - } - - /** - * Initialize the sync listener. - * - * @access public - * @static - */ - public static function initialize_listener() { - self::$listener = Listener::get_instance(); - } - - /** - * Initializes the sync sender. - * - * @access public - * @static - */ - public static function initialize_sender() { - self::$sender = Sender::get_instance(); - add_filter( 'jetpack_sync_send_data', array( __CLASS__, 'send_data' ), 10, 8 ); - } - - /** - * Initializes sync for WooCommerce. - * - * @access public - * @static - */ - public static function initialize_woocommerce() { - if ( false === class_exists( 'WooCommerce' ) ) { - return; - } - add_filter( 'jetpack_sync_modules', array( __CLASS__, 'add_woocommerce_sync_module' ) ); - - if ( ! class_exists( CustomOrdersTableController::class ) ) { - return; - } - $cot_controller = wc_get_container()->get( CustomOrdersTableController::class ); - if ( $cot_controller->custom_orders_table_usage_is_enabled() ) { - add_filter( 'jetpack_sync_modules', array( __CLASS__, 'add_woocommerce_hpos_order_sync_module' ) ); - } - } - - /** - * Initializes sync for Instant Search. - * - * @access public - * @static - */ - public static function initialize_search() { - if ( false === class_exists( 'Automattic\\Jetpack\\Search\\Module_Control' ) ) { - return; - } - $search_module = new \Automattic\Jetpack\Search\Module_Control(); - if ( $search_module->is_instant_search_enabled() ) { - add_filter( 'jetpack_sync_modules', array( __CLASS__, 'add_search_sync_module' ) ); - } - } - - /** - * Add Search updates to Sync Filters. - * - * @access public - * @static - * - * @param array $sync_modules The list of sync modules declared prior to this filter. - * @return array A list of sync modules that now includes Search's modules. - */ - public static function add_search_sync_module( $sync_modules ) { - $sync_modules[] = 'Automattic\\Jetpack\\Sync\\Modules\\Search'; - return $sync_modules; - } - - /** - * Adds Woo's sync modules to existing modules for sending. - * - * @access public - * @static - * - * @param array $sync_modules The list of sync modules declared prior to this filter. - * @return array A list of sync modules that now includes Woo's modules. - */ - public static function add_woocommerce_sync_module( $sync_modules ) { - $sync_modules[] = 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce'; - return $sync_modules; - } - - /** - * Adds Woo's HPOS sync modules to existing modules for sending. - * - * @param array $sync_modules The list of sync modules declared prior to this filter. - * - * @access public - * @static - * - * @return array A list of sync modules that now includes Woo's HPOS modules. - */ - public static function add_woocommerce_hpos_order_sync_module( $sync_modules ) { - $sync_modules[] = WooCommerce_HPOS_Orders::class; - return $sync_modules; - } - - /** - * Initializes sync for WP Super Cache. - * - * @access public - * @static - */ - public static function initialize_wp_super_cache() { - if ( false === function_exists( 'wp_cache_is_enabled' ) ) { - return; - } - add_filter( 'jetpack_sync_modules', array( __CLASS__, 'add_wp_super_cache_sync_module' ) ); - } - - /** - * Adds WP Super Cache's sync modules to existing modules for sending. - * - * @access public - * @static - * - * @param array $sync_modules The list of sync modules declared prior to this filer. - * @return array A list of sync modules that now includes WP Super Cache's modules. - */ - public static function add_wp_super_cache_sync_module( $sync_modules ) { - $sync_modules[] = 'Automattic\\Jetpack\\Sync\\Modules\\WP_Super_Cache'; - return $sync_modules; - } - - /** - * Sanitizes the name of sync's cron schedule. - * - * @access public - * @static - * - * @param string $schedule The name of a WordPress cron schedule. - * @return string The sanitized name of sync's cron schedule. - */ - public static function sanitize_filtered_sync_cron_schedule( $schedule ) { - $schedule = sanitize_key( $schedule ); - $schedules = wp_get_schedules(); - - // Make sure that the schedule has actually been registered using the `cron_intervals` filter. - if ( isset( $schedules[ $schedule ] ) ) { - return $schedule; - } - - return self::DEFAULT_SYNC_CRON_INTERVAL_NAME; - } - - /** - * Allows offsetting of start times for sync cron jobs. - * - * @access public - * @static - * - * @param string $schedule The name of a cron schedule. - * @param string $hook The hook that this method is responding to. - * @return int The offset for the sync cron schedule. - */ - public static function get_start_time_offset( $schedule = '', $hook = '' ) { - $start_time_offset = is_multisite() - ? wp_rand( 0, ( 2 * self::DEFAULT_SYNC_CRON_INTERVAL_VALUE ) ) - : 0; - - /** - * Allows overriding the offset that the sync cron jobs will first run. This can be useful when scheduling - * cron jobs across multiple sites in a network. - * - * @since 1.6.3 - * @since-jetpack 4.5.0 - * - * @param int $start_time_offset - * @param string $hook - * @param string $schedule - */ - return (int) apply_filters( - 'jetpack_sync_cron_start_time_offset', - $start_time_offset, - $hook, - $schedule - ); - } - - /** - * Decides if a sync cron should be scheduled. - * - * @access public - * @static - * - * @param string $schedule The name of a cron schedule. - * @param string $hook The hook that this method is responding to. - */ - public static function maybe_schedule_sync_cron( $schedule, $hook ) { - if ( ! $hook ) { - return; - } - $schedule = self::sanitize_filtered_sync_cron_schedule( $schedule ); - - $start_time = time() + self::get_start_time_offset( $schedule, $hook ); - if ( ! wp_next_scheduled( $hook ) ) { - // Schedule a job to send pending queue items once a minute. - wp_schedule_event( $start_time, $schedule, $hook ); - } elseif ( wp_get_schedule( $hook ) !== $schedule ) { - // If the schedule has changed, update the schedule. - wp_clear_scheduled_hook( $hook ); - wp_schedule_event( $start_time, $schedule, $hook ); - } - } - - /** - * Clears Jetpack sync cron jobs. - * - * @access public - * @static - */ - public static function clear_sync_cron_jobs() { - wp_clear_scheduled_hook( 'jetpack_sync_cron' ); - wp_clear_scheduled_hook( 'jetpack_sync_full_cron' ); - } - - /** - * Initializes Jetpack sync cron jobs. - * - * @access public - * @static - */ - public static function init_sync_cron_jobs() { - add_filter( 'cron_schedules', array( __CLASS__, 'jetpack_cron_schedule' ) ); // phpcs:ignore WordPress.WP.CronInterval.ChangeDetected - - add_action( 'jetpack_sync_cron', array( __CLASS__, 'do_cron_sync' ) ); - add_action( 'jetpack_sync_full_cron', array( __CLASS__, 'do_cron_full_sync' ) ); - - /** - * Allows overriding of the default incremental sync cron schedule which defaults to once every 5 minutes. - * - * @since 1.6.3 - * @since-jetpack 4.3.2 - * - * @param string self::DEFAULT_SYNC_CRON_INTERVAL_NAME - */ - $incremental_sync_cron_schedule = apply_filters( 'jetpack_sync_incremental_sync_interval', self::DEFAULT_SYNC_CRON_INTERVAL_NAME ); - self::maybe_schedule_sync_cron( $incremental_sync_cron_schedule, 'jetpack_sync_cron' ); - - /** - * Allows overriding of the full sync cron schedule which defaults to once every 5 minutes. - * - * @since 1.6.3 - * @since-jetpack 4.3.2 - * - * @param string self::DEFAULT_SYNC_CRON_INTERVAL_NAME - */ - $full_sync_cron_schedule = apply_filters( 'jetpack_sync_full_sync_interval', self::DEFAULT_SYNC_CRON_INTERVAL_NAME ); - self::maybe_schedule_sync_cron( $full_sync_cron_schedule, 'jetpack_sync_full_cron' ); - } - - /** - * Perform maintenance when a plugin upgrade occurs. - * - * @access public - * @static - * - * @param string $new_version New version of the plugin. - * @param string $old_version Old version of the plugin. - */ - public static function cleanup_on_upgrade( $new_version = '', $old_version = '' ) { - if ( wp_next_scheduled( 'jetpack_sync_send_db_checksum' ) ) { - wp_clear_scheduled_hook( 'jetpack_sync_send_db_checksum' ); - } - - $is_new_sync_upgrade = version_compare( $old_version, '4.2', '>=' ); - if ( ! empty( $old_version ) && $is_new_sync_upgrade && version_compare( $old_version, '4.5', '<' ) ) { - self::clear_sync_cron_jobs(); - Settings::update_settings( - array( - 'render_filtered_content' => Defaults::$default_render_filtered_content, - ) - ); - } - - Health::on_jetpack_upgraded(); - } - - /** - * Get syncing status for the given fields. - * - * @access public - * @static - * - * @param string|null $fields A comma-separated string of the fields to include in the array from the JSON response. - * @return array An associative array with the status report. - */ - public static function get_sync_status( $fields = null ) { - self::initialize_sender(); - - $sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $sync_module'; - $queue = self::$sender->get_sync_queue(); - - // _get_cron_array can be false - $cron_timestamps = ( _get_cron_array() ) ? array_keys( _get_cron_array() ) : array(); - $next_cron = ( ! empty( $cron_timestamps ) ) ? $cron_timestamps[0] - time() : ''; - - $checksums = array(); - $debug = array(); - - if ( ! empty( $fields ) ) { - $store = new Replicastore(); - $fields_params = array_map( 'trim', explode( ',', $fields ) ); - - if ( in_array( 'posts_checksum', $fields_params, true ) ) { - $checksums['posts_checksum'] = $store->posts_checksum(); - } - if ( in_array( 'comments_checksum', $fields_params, true ) ) { - $checksums['comments_checksum'] = $store->comments_checksum(); - } - if ( in_array( 'post_meta_checksum', $fields_params, true ) ) { - $checksums['post_meta_checksum'] = $store->post_meta_checksum(); - } - if ( in_array( 'comment_meta_checksum', $fields_params, true ) ) { - $checksums['comment_meta_checksum'] = $store->comment_meta_checksum(); - } - - if ( in_array( 'debug_details', $fields_params, true ) ) { - $debug = self::get_debug_details(); - } - } - - $full_sync_status = ( $sync_module ) ? $sync_module->get_status() : array(); - - $full_queue = self::$sender->get_full_sync_queue(); - - $result = array_merge( - $full_sync_status, - $checksums, - $debug, - array( - 'cron_size' => count( $cron_timestamps ), - 'next_cron' => $next_cron, - 'queue_size' => $queue->size(), - 'queue_lag' => $queue->lag(), - 'queue_next_sync' => ( self::$sender->get_next_sync_time( 'sync' ) - microtime( true ) ), - 'full_queue_next_sync' => ( self::$sender->get_next_sync_time( 'full_sync' ) - microtime( true ) ), - ) - ); - - // Verify $sync_module is not false. - if ( $sync_module && ! $sync_module instanceof Modules\Full_Sync_Immediately ) { - $result['full_queue_size'] = $full_queue->size(); - $result['full_queue_lag'] = $full_queue->lag(); - } - return $result; - } - - /** - * Reset Sync locks. - * - * @access public - * @static - * @since 1.43.0 - * - * @param bool $unlock_queues Whether to unlock Sync queues. Defaults to true. - */ - public static function reset_sync_locks( $unlock_queues = true ) { - // Next sync locks. - delete_option( Sender::NEXT_SYNC_TIME_OPTION_NAME . '_sync' ); - delete_option( Sender::NEXT_SYNC_TIME_OPTION_NAME . '_full_sync' ); - delete_option( Sender::NEXT_SYNC_TIME_OPTION_NAME . '_full-sync-enqueue' ); - // Retry after locks. - delete_option( self::RETRY_AFTER_PREFIX . 'sync' ); - delete_option( self::RETRY_AFTER_PREFIX . 'full_sync' ); - // Dedicated sync locks. - \Jetpack_Options::delete_raw_option( Dedicated_Sender::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME ); - delete_transient( Dedicated_Sender::DEDICATED_SYNC_TEMPORARY_DISABLE_FLAG ); - // Lock for disabling Sync sending temporarily. - delete_transient( Sender::TEMP_SYNC_DISABLE_TRANSIENT_NAME ); - - // Queue locks. - // Note that we are just unlocking the queues here, not reseting them. - if ( $unlock_queues ) { - $sync_queue = new Queue( 'sync' ); - $sync_queue->unlock(); - - $full_sync_queue = new Queue( 'full_sync' ); - $full_sync_queue->unlock(); - } - } - - /** - * Prepare JSONL data. - * - * @param mixed $data The data to be prepared. - * - * @return string The prepared JSONL data. - */ - private static function prepare_jsonl_data( $data ) { - $jsonl_data = implode( - "\n", - array_map( - function ( $key, $value ) { - return wp_json_encode( array( $key => $value ) ); - }, - array_keys( (array) $data ), - array_values( (array) $data ) - ) - ); - return $jsonl_data; - } - - /** - * Helper method to process the API response. - * - * @param mixed $response The response from the API. - * @return array|Wp_Error Array for successful response or a WP_Error object. - */ - private static function process_rest_api_response( $response ) { - - $response_code = wp_remote_retrieve_response_code( $response ); - $response_body = wp_remote_retrieve_body( $response ); - if ( is_wp_error( $response ) ) { - return $response; - } - $decoded_response = json_decode( $response_body, true ); - - if ( false === is_array( $decoded_response ) ) { - return new WP_Error( 'sync_rest_api_response_decoding_failed', 'Sync REST API response decoding failed', $response_body ); - } - - if ( $response_code !== 200 || false === isset( $decoded_response['processed_items'] ) ) { - if ( is_array( $decoded_response ) && isset( $decoded_response['code'] ) && isset( $decoded_response['message'] ) ) { - return new WP_Error( - 'jetpack_sync_send_error_' . $decoded_response['code'], - $decoded_response['message'], - $decoded_response['data'] ?? null - ); - } else { - return new WP_Error( $response_code, 'Sync REST API request failed', $response_body ); - } - } else { - return $decoded_response; - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php deleted file mode 100644 index 9fb90681..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php +++ /dev/null @@ -1,421 +0,0 @@ - array( - 'Automattic\\Jetpack\\Sync\\Modules\\Callables', - 'Automattic\\Jetpack\\Sync\\Modules\\Constants', - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync_Immediately', // enable Initial Sync on Site Connection. - 'Automattic\\Jetpack\\Sync\\Modules\\Options', - 'Automattic\\Jetpack\\Sync\\Modules\\Updates', - 'Automattic\\Jetpack\\Sync\\Modules\\Stats', // Daily heartbeat data. - ), - 'jetpack_sync_callable_whitelist' => array( - 'site_url' => array( 'Automattic\\Jetpack\\Connection\\Urls', 'site_url' ), - 'home_url' => array( 'Automattic\\Jetpack\\Connection\\Urls', 'home_url' ), - 'get_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_plugins' ), - 'get_themes' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_themes' ), - 'jetpack_connection_active_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_jetpack_connection_active_plugins' ), - 'paused_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_paused_plugins' ), - 'paused_themes' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_paused_themes' ), - 'timezone' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_timezone' ), - 'wp_get_environment_type' => 'wp_get_environment_type', - 'wp_max_upload_size' => 'wp_max_upload_size', - 'wp_version' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'wp_version' ), - ), - 'jetpack_sync_constants_whitelist' => array( - 'ABSPATH', - 'ALTERNATE_WP_CRON', - 'ATOMIC_CLIENT_ID', - 'AUTOMATIC_UPDATER_DISABLED', - 'DISABLE_WP_CRON', - 'DISALLOW_FILE_EDIT', - 'DISALLOW_FILE_MODS', - 'EMPTY_TRASH_DAYS', - 'FS_METHOD', - 'IS_PRESSABLE', - 'PHP_VERSION', - 'WP_ACCESSIBLE_HOSTS', - 'WP_AUTO_UPDATE_CORE', - 'WP_CONTENT_DIR', - 'WP_CRON_LOCK_TIMEOUT', - 'WP_DEBUG', - 'WP_HTTP_BLOCK_EXTERNAL', - 'WP_MAX_MEMORY_LIMIT', - 'WP_MEMORY_LIMIT', - 'WP_POST_REVISIONS', - ), - 'jetpack_sync_options_whitelist' => array( - /** - * Sync related options - */ - 'jetpack_sync_non_blocking', - 'jetpack_sync_non_public_post_stati', - 'jetpack_sync_settings_comment_meta_whitelist', - 'jetpack_sync_settings_post_meta_whitelist', - 'jetpack_sync_settings_post_types_blacklist', - 'jetpack_sync_settings_taxonomies_blacklist', - 'jetpack_sync_settings_dedicated_sync_enabled', - 'jetpack_sync_settings_custom_queue_table_enabled', - 'jetpack_sync_settings_wpcom_rest_api_enabled', - /** - * Connection related options - */ - 'jetpack_package_versions', - /** - * Generic site options - */ - 'blog_charset', - 'blog_public', - 'blogdescription', - 'blogname', - 'permalink_structure', - 'stylesheet', - 'time_format', - 'timezone_string', - 'active_plugins', - ), - ); - - const MODULE_FILTER_MAPPING = array( - 'Automattic\\Jetpack\\Sync\\Modules\\Options' => array( - 'jetpack_sync_options_whitelist', - 'jetpack_sync_options_contentless', - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Constants' => array( - 'jetpack_sync_constants_whitelist', - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Callables' => array( - 'jetpack_sync_callable_whitelist', - 'jetpack_sync_multisite_callable_whitelist', - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Posts' => array( - 'jetpack_sync_post_meta_whitelist', - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Comments' => array( - 'jetpack_sync_comment_meta_whitelist', - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Users' => array( - 'jetpack_sync_capabilities_whitelist', - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Import' => array( - 'jetpack_sync_known_importers', - ), - ); - - const MODULES_FILTER_NAME = 'jetpack_sync_modules'; - - /** - * The static data settings array which contains the aggregated data settings for - * each sync filter. - * - * @var array - */ - private static $data_settings = array(); - - /** - * The static array which contains the list of filter hooks that have already been set up. - * - * @var array - */ - private static $set_filter_hooks = array(); - - /** - * Adds the data settings provided by a plugin to the Sync data settings. - * - * @param array $plugin_settings The array provided by the plugin. The array must use filters - * from the DATA_FILTER_DEFAULTS list as keys. - */ - public function add_settings_list( $plugin_settings = array() ) { - if ( empty( $plugin_settings ) || ! is_array( $plugin_settings ) ) { - /* - * No custom plugin settings, so use defaults for everything and bail early. - */ - $this->set_all_defaults(); - return; - } - - $this->add_filters_custom_settings_and_hooks( $plugin_settings ); - - if ( ! did_action( 'jetpack_sync_add_required_data_settings' ) ) { - $this->add_required_settings(); - /** - * Fires when the required settings have been adding to the static - * data_settings array. - * - * @since 1.29.2 - * - * @module sync - */ - do_action( 'jetpack_sync_add_required_data_settings' ); - } - } - - /** - * Sets the default values for sync modules and all sync data filters. - */ - private function set_all_defaults() { - $this->add_sync_filter_setting( self::MODULES_FILTER_NAME, Modules::DEFAULT_SYNC_MODULES ); - - foreach ( array_keys( Default_Filter_Settings::DATA_FILTER_DEFAULTS ) as $filter ) { - $this->add_sync_filter_setting( $filter, $this->get_default_setting_for_filter( $filter ) ); - } - } - - /** - * Returns the default settings for the given filter. - * - * @param string $filter The filter name. - * - * @return array The filter's default settings array. - */ - private function get_default_setting_for_filter( $filter ) { - if ( self::MODULES_FILTER_NAME === $filter ) { - return Modules::DEFAULT_SYNC_MODULES; - } - - return ( new Default_Filter_Settings() )->get_default_settings( $filter ); - } - - /** - * Adds the custom settings and sets up the necessary filter hooks. - * - * @param array $filters_settings The custom settings. - */ - private function add_filters_custom_settings_and_hooks( $filters_settings ) { - if ( isset( $filters_settings[ self::MODULES_FILTER_NAME ] ) && is_array( $filters_settings[ self::MODULES_FILTER_NAME ] ) ) { - $this->add_custom_filter_setting( self::MODULES_FILTER_NAME, $filters_settings[ self::MODULES_FILTER_NAME ] ); - $enabled_modules = $filters_settings[ self::MODULES_FILTER_NAME ]; - } else { - $this->add_sync_filter_setting( self::MODULES_FILTER_NAME, Modules::DEFAULT_SYNC_MODULES ); - $enabled_modules = Modules::DEFAULT_SYNC_MODULES; - } - - $all_modules = Modules::DEFAULT_SYNC_MODULES; - - foreach ( $all_modules as $module ) { - if ( in_array( $module, $enabled_modules, true ) || in_array( $module, self::MUST_SYNC_DATA_SETTINGS['jetpack_sync_modules'], true ) ) { - $this->add_filters_for_enabled_module( $module, $filters_settings ); - } else { - $this->add_filters_for_disabled_module( $module ); - } - } - } - - /** - * Adds the filters for the provided enabled module. If the settings provided custom filter settings - * for the module's filters, those are used. Otherwise, the filter's default settings are used. - * - * @param string $module The module name. - * @param array $filters_settings The settings for the filters. - */ - private function add_filters_for_enabled_module( $module, $filters_settings ) { - $module_mapping = self::MODULE_FILTER_MAPPING; - $filters_for_module = isset( $module_mapping[ $module ] ) ? $module_mapping[ $module ] : array(); - - foreach ( $filters_for_module as $filter ) { - if ( isset( $filters_settings[ $filter ] ) ) { - $this->add_custom_filter_setting( $filter, $filters_settings[ $filter ] ); - } else { - $this->add_sync_filter_setting( $filter, $this->get_default_setting_for_filter( $filter ) ); - } - } - } - - /** - * Adds the filters for the provided disabled module. The disabled module's associated filter settings are - * set to an empty array. - * - * @param string $module The module name. - */ - private function add_filters_for_disabled_module( $module ) { - $module_mapping = self::MODULE_FILTER_MAPPING; - $filters_for_module = isset( $module_mapping[ $module ] ) ? $module_mapping[ $module ] : array(); - - foreach ( $filters_for_module as $filter ) { - $this->add_custom_filter_setting( $filter, array() ); - } - } - - /** - * Adds the provided custom setting for a filter. If the filter setting isn't valid, the default - * value is used. - * - * If the filter's hook hasn't already been set up, it gets set up. - * - * @param string $filter The filter. - * @param array $setting The filter setting. - */ - private function add_custom_filter_setting( $filter, $setting ) { - if ( ! $this->is_valid_filter_setting( $filter, $setting ) ) { - /* - * The provided setting isn't valid, so use the default for this filter. - * We're using the default values so there's no need to set the filter hook. - */ - $this->add_sync_filter_setting( $filter, $this->get_default_setting_for_filter( $filter ) ); - return; - } - - if ( ! isset( static::$set_filter_hooks[ $filter ] ) ) { - // First time a custom modules setting is provided, so set the filter hook. - add_filter( $filter, array( $this, 'sync_data_filter_hook' ) ); - static::$set_filter_hooks[ $filter ] = 1; - } - - $this->add_sync_filter_setting( $filter, $setting ); - } - - /** - * Determines whether the filter setting is valid. The setting array is in the correct format (associative or indexed). - * - * @param string $filter The filter to check. - * @param array $filter_settings The filter settings. - * - * @return bool Whether the filter settings can be used. - */ - private function is_valid_filter_setting( $filter, $filter_settings ) { - if ( ! is_array( $filter_settings ) ) { - // The settings for each filter must be an array. - return false; - } - - if ( empty( $filter_settings ) ) { - // Empty settings are allowed. - return true; - } - - $indexed_array = isset( $filter_settings[0] ); - if ( in_array( $filter, Default_Filter_Settings::ASSOCIATIVE_FILTERS, true ) && ! $indexed_array ) { - return true; - } elseif ( ! in_array( $filter, Default_Filter_Settings::ASSOCIATIVE_FILTERS, true ) && $indexed_array ) { - return true; - } - - return false; - } - - /** - * Adds the data settings that are always required for every plugin that uses Sync. - */ - private function add_required_settings() { - foreach ( self::MUST_SYNC_DATA_SETTINGS as $filter => $setting ) { - // If the corresponding setting is already set and matches the default one, no need to proceed. - if ( isset( static::$data_settings[ $filter ] ) && static::$data_settings[ $filter ] === $this->get_default_setting_for_filter( $filter ) ) { - continue; - } - $this->add_custom_filter_setting( $filter, $setting ); - } - } - - /** - * Adds the provided data setting for the provided filter. - * - * @param string $filter The filter name. - * @param array $value The data setting. - */ - private function add_sync_filter_setting( $filter, $value ) { - if ( ! isset( static::$data_settings[ $filter ] ) ) { - static::$data_settings[ $filter ] = $value; - return; - } - - if ( in_array( $filter, Default_Filter_Settings::ASSOCIATIVE_FILTERS, true ) ) { - $this->add_associative_filter_setting( $filter, $value ); - } else { - $this->add_indexed_filter_setting( $filter, $value ); - } - } - - /** - * Adds the provided data setting for the provided filter. This method handles - * adding settings to data that is stored as an associative array. - * - * @param string $filter The filter name. - * @param array $settings The data settings. - */ - private function add_associative_filter_setting( $filter, $settings ) { - foreach ( $settings as $key => $item ) { - if ( ! array_key_exists( $key, static::$data_settings[ $filter ] ) ) { - static::$data_settings[ $filter ][ $key ] = $item; - } - } - } - - /** - * Adds the provided data setting for the provided filter. This method handles - * adding settings to data that is stored as an indexed array. - * - * @param string $filter The filter name. - * @param array $settings The data settings. - */ - private function add_indexed_filter_setting( $filter, $settings ) { - static::$data_settings[ $filter ] = array_unique( - array_merge( - static::$data_settings[ $filter ], - $settings - ) - ); - } - - /** - * The callback function added to the sync data filters. Combines the list in the $data_settings property - * with any non-default values from the received array. - * - * @param array $filtered_values The data revieved from the filter. - * - * @return array The data settings for the filter. - */ - public function sync_data_filter_hook( $filtered_values ) { - if ( ! is_array( $filtered_values ) ) { - // Something is wrong with the input, so set it to an empty array. - $filtered_values = array(); - } - - $current_filter = current_filter(); - - if ( ! isset( static::$data_settings[ $current_filter ] ) ) { - return $filtered_values; - } - - if ( in_array( $current_filter, Default_Filter_Settings::ASSOCIATIVE_FILTERS, true ) ) { - $extra_filters = array_diff_key( $filtered_values, $this->get_default_setting_for_filter( $current_filter ) ); - $this->add_associative_filter_setting( $current_filter, $extra_filters ); - return static::$data_settings[ $current_filter ]; - } - - $extra_filters = array_diff( $filtered_values, $this->get_default_setting_for_filter( $current_filter ) ); - $this->add_indexed_filter_setting( $current_filter, $extra_filters ); - return static::$data_settings[ $current_filter ]; - } - - /** - * Sets the $data_settings property to an empty array. This is useful for testing. - */ - public function empty_data_settings_and_hooks() { - static::$data_settings = array(); - static::$set_filter_hooks = array(); - } - - /** - * Returns the $data_settings property. - * - * @return array The data_settings property. - */ - public function get_data_settings() { - return static::$data_settings; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php deleted file mode 100644 index 02cf7739..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php +++ /dev/null @@ -1,408 +0,0 @@ -is_locked() ) { - return new WP_Error( 'locked_queue_' . $queue->id ); - } - - if ( $queue->size() === 0 ) { - return new WP_Error( 'empty_queue_' . $queue->id ); - } - - // Return early if we've gotten a retry-after header response that is not expired. - $retry_time = get_option( Actions::RETRY_AFTER_PREFIX . $queue->id ); - if ( $retry_time && $retry_time >= microtime( true ) ) { - return new WP_Error( 'retry_after_' . $queue->id ); - } - - // Don't sync if we are throttled. - $sync_next_time = Sender::get_instance()->get_next_sync_time( $queue->id ); - if ( $sync_next_time > microtime( true ) ) { - return new WP_Error( 'sync_throttled_' . $queue->id ); - } - /** - * How much time to wait before we start suspecting Dedicated Sync is in trouble. - */ - $queue_send_time_threshold = 30 * MINUTE_IN_SECONDS; - - $queue_lag = $queue->lag(); - - /** - * Try to acquire a request lock, so we don't spawn multiple requests at the same time. - * This should prevent cases where sites might have limits on the amount of simultaneous requests. - */ - $request_lock = self::try_lock_spawn_request(); - if ( ! $request_lock ) { - return new WP_Error( 'dedicated_request_lock', 'Unable to acquire request lock' ); - } - - /** - * If the queue lag is bigger than the threshold, we want to check if Dedicated Sync is working correctly. - * We will do by sending a test request and disabling Dedicated Sync if it's not working. We will also exit early - * in case we send the test request since it is a blocking request. - */ - if ( $queue_lag > $queue_send_time_threshold ) { - if ( false === get_transient( self::DEDICATED_SYNC_CHECK_TRANSIENT ) ) { - if ( ! self::can_spawn_dedicated_sync_request() ) { - self::on_dedicated_sync_lag_not_sending_threshold_reached(); - return new WP_Error( 'dedicated_sync_not_sending', 'Dedicated Sync is not successfully sending events' ); - } - return true; - } - } - - $url = rest_url( 'jetpack/v4/sync/spawn-sync' ); - $url = add_query_arg( 'time', time(), $url ); // Enforce Cache busting. - $url = add_query_arg( self::DEDICATED_SYNC_REQUEST_LOCK_QUERY_PARAM_NAME, $request_lock, $url ); - - $args = array( - 'cookies' => $_COOKIE, - 'blocking' => false, - 'timeout' => 0.01, - /** This filter is documented in wp-includes/class-wp-http-streams.php */ - 'sslverify' => apply_filters( 'https_local_ssl_verify', false ), - ); - - $result = wp_remote_get( $url, $args ); - if ( is_wp_error( $result ) ) { - return $result; - } - - return true; - } - - /** - * Attempt to acquire a request lock. - * - * To avoid spawning multiple requests at the same time, we need to have a quick lock that will - * allow only a single request to continue if we try to spawn multiple at the same time. - * - * @return false|mixed|string - */ - public static function try_lock_spawn_request() { - $current_microtime = (string) microtime( true ); - - if ( wp_using_ext_object_cache() ) { - if ( true !== wp_cache_add( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, $current_microtime, 'jetpack', self::DEDICATED_SYNC_REQUEST_LOCK_TIMEOUT ) ) { - // Cache lock has been claimed already. - return false; - } - } - - $current_lock_value = \Jetpack_Options::get_raw_option( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, null ); - - if ( ! empty( $current_lock_value ) ) { - // Check if time has passed to overwrite the lock - min 5s? - if ( is_numeric( $current_lock_value ) && ( ( $current_microtime - $current_lock_value ) < self::DEDICATED_SYNC_REQUEST_LOCK_TIMEOUT ) ) { - // Still in previous lock, quit - return false; - } - - // If the value is not numeric (float/current time), we want to just overwrite it and continue. - } - - // Update. We don't want it to autoload, as we want to fetch it right before the checks. - \Jetpack_Options::update_raw_option( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, $current_microtime, false ); - // Give some time for the update to happen - usleep( wp_rand( 1000, 3000 ) ); - - $updated_value = \Jetpack_Options::get_raw_option( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, null ); - - if ( $updated_value === $current_microtime ) { - return $current_microtime; - } - - return false; - } - - /** - * Attempt to release the request lock. - * - * @param string $lock_id The request lock that's currently being held. - * - * @return bool|WP_Error - */ - public static function try_release_lock_spawn_request( $lock_id = '' ) { - // Try to get the lock_id from the current request if it's not supplied. - if ( empty( $lock_id ) ) { - $lock_id = self::get_request_lock_id_from_request(); - } - - // If it's still not a valid lock_id, throw an error and let the lock process figure it out. - if ( empty( $lock_id ) || ! is_numeric( $lock_id ) ) { - return new WP_Error( 'dedicated_request_lock_invalid', 'Invalid lock_id supplied for unlock' ); - } - - if ( wp_using_ext_object_cache() ) { - if ( (string) $lock_id === wp_cache_get( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, 'jetpack', true ) ) { - wp_cache_delete( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, 'jetpack' ); - } - } - - // If this is the flow that has the lock, let's release it so we can spawn other requests afterwards - $current_lock_value = \Jetpack_Options::get_raw_option( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME, null ); - if ( (string) $lock_id === $current_lock_value ) { - \Jetpack_Options::delete_raw_option( self::DEDICATED_SYNC_REQUEST_LOCK_OPTION_NAME ); - return true; - } - - return false; - } - - /** - * Try to get the request lock id from the current request. - * - * @return array|string|string[]|null - */ - public static function get_request_lock_id_from_request() { - // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( ! isset( $_GET[ self::DEDICATED_SYNC_REQUEST_LOCK_QUERY_PARAM_NAME ] ) || ! is_numeric( $_GET[ self::DEDICATED_SYNC_REQUEST_LOCK_QUERY_PARAM_NAME ] ) ) { - return null; - } - - // phpcs:ignore WordPress.Security.NonceVerification.Recommended,WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - return wp_unslash( $_GET[ self::DEDICATED_SYNC_REQUEST_LOCK_QUERY_PARAM_NAME ] ); - } - - /** - * Test Sync spawning functionality by making a request to the - * Sync spawning endpoint and storing the result (status code) in a transient. - * - * @since 1.34.0 - * - * @return bool True if we got a successful response, false otherwise. - */ - public static function can_spawn_dedicated_sync_request() { - $dedicated_sync_check_transient = self::DEDICATED_SYNC_CHECK_TRANSIENT; - - $dedicated_sync_response_body = get_transient( $dedicated_sync_check_transient ); - - if ( false === $dedicated_sync_response_body ) { - $url = rest_url( 'jetpack/v4/sync/spawn-sync' ); - $url = add_query_arg( 'time', time(), $url ); // Enforce Cache busting. - $args = array( - 'cookies' => $_COOKIE, - 'timeout' => 30, - /** This filter is documented in wp-includes/class-wp-http-streams.php */ - 'sslverify' => apply_filters( 'https_local_ssl_verify', false ), - ); - - $response = wp_remote_get( $url, $args ); - $dedicated_sync_response_code = wp_remote_retrieve_response_code( $response ); - $dedicated_sync_response_body = trim( wp_remote_retrieve_body( $response ) ); - - /** - * Limit the size of the body that we save in the transient to avoid cases where an error - * occurs and a whole generated HTML page is returned. We don't need to store the whole thing. - * - * The regexp check is done to make sure we can detect the string even if the body returns some additional - * output, like some caching plugins do when they try to pad the request. - */ - $regexp = '!' . preg_quote( self::DEDICATED_SYNC_VALIDATION_STRING, '!' ) . '!uis'; - if ( preg_match( $regexp, $dedicated_sync_response_body ) ) { - $saved_response_body = self::DEDICATED_SYNC_VALIDATION_STRING; - } else { - $saved_response_body = time(); - } - - set_transient( $dedicated_sync_check_transient, $saved_response_body, HOUR_IN_SECONDS ); - - // Send a bit more information to WordPress.com to help debugging issues. - if ( $saved_response_body !== self::DEDICATED_SYNC_VALIDATION_STRING ) { - $data = array( - 'timestamp' => microtime( true ), - 'response_code' => $dedicated_sync_response_code, - 'response_body' => $dedicated_sync_response_body, - - // Send the flow type that was attempted. - 'sync_flow_type' => 'dedicated', - ); - - $sender = Sender::get_instance(); - - $sender->send_action( 'jetpack_sync_flow_error_enable', $data ); - } - } - return self::DEDICATED_SYNC_VALIDATION_STRING === $dedicated_sync_response_body; - } - - /** - * Disable dedicated sync and set a transient to prevent re-enabling it for some time. - * - * @return void - */ - public static function on_dedicated_sync_lag_not_sending_threshold_reached() { - set_transient( self::DEDICATED_SYNC_TEMPORARY_DISABLE_FLAG, true, 6 * HOUR_IN_SECONDS ); - - Settings::update_settings( - array( - 'dedicated_sync_enabled' => 0, - ) - ); - - // Inform that we had to temporarily disable Dedicated Sync - $data = array( - 'timestamp' => microtime( true ), - - // Send the flow type that was attempted. - 'sync_flow_type' => 'dedicated', - ); - - $sender = Sender::get_instance(); - - $sender->send_action( 'jetpack_sync_flow_error_temp_disable', $data ); - } - - /** - * Disable or enable Dedicated Sync sender based on the header value returned from WordPress.com - * - * @param string $dedicated_sync_header The Dedicated Sync header value - `on` or `off`. - * - * @return bool Whether Dedicated Sync is going to be enabled or not. - */ - public static function maybe_change_dedicated_sync_status_from_wpcom_header( $dedicated_sync_header ) { - $dedicated_sync_enabled = 'on' === $dedicated_sync_header ? 1 : 0; - - // Prevent enabling of Dedicated sync via header flag if we're in an autoheal timeout. - if ( $dedicated_sync_enabled ) { - $check_transient = get_transient( self::DEDICATED_SYNC_TEMPORARY_DISABLE_FLAG ); - - if ( $check_transient ) { - // Something happened and Dedicated Sync should not be automatically re-enabled. - return false; - } - } - - Settings::update_settings( - array( - 'dedicated_sync_enabled' => $dedicated_sync_enabled, - ) - ); - - return Settings::is_dedicated_sync_enabled(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php deleted file mode 100644 index 81946fe8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php +++ /dev/null @@ -1,80 +0,0 @@ - 'default_options_whitelist', - 'jetpack_sync_options_contentless' => 'default_options_contentless', - 'jetpack_sync_constants_whitelist' => 'default_constants_whitelist', - 'jetpack_sync_callable_whitelist' => 'default_callable_whitelist', - 'jetpack_sync_multisite_callable_whitelist' => 'default_multisite_callable_whitelist', - 'jetpack_sync_post_meta_whitelist' => 'post_meta_whitelist', - 'jetpack_sync_comment_meta_whitelist' => 'comment_meta_whitelist', - 'jetpack_sync_capabilities_whitelist' => 'default_capabilities_whitelist', - 'jetpack_sync_known_importers' => 'default_known_importers', - ); - - /** - * The data associated with these filters are stored as associative arrays. - * (All other filters store data as indexed arrays.) - */ - const ASSOCIATIVE_FILTERS = array( - 'jetpack_sync_callable_whitelist', - 'jetpack_sync_multisite_callable_whitelist', - 'jetpack_sync_known_importers', - ); - - /** - * Returns the default data settings list for the provided filter. - * - * @param string $filter The filter name. - * - * @return array|false The default list of data settings. Returns false if the provided - * filter doesn't not have an array of default settings. - */ - public function get_default_settings( $filter ) { - if ( ! is_string( $filter ) || ! array_key_exists( $filter, self::DATA_FILTER_DEFAULTS ) ) { - return false; - } - - $property = self::DATA_FILTER_DEFAULTS[ $filter ]; - $class = self::DEFAULT_FILTER_CLASS; - return $class::$$property; - } - - /** - * Returns an array containing the default values for all of the filters shown - * in DATA_FILTER_DEFAULTS. - * - * @return array The array containing all sync data filters and their default values. - */ - public function get_all_filters_default_settings() { - $defaults = array(); - - foreach ( self::DATA_FILTER_DEFAULTS as $filter => $default_location ) { - $defaults[ $filter ] = $this->get_default_settings( $filter ); - } - return $defaults; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php deleted file mode 100644 index 0010bb58..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php +++ /dev/null @@ -1,1377 +0,0 @@ - array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_loaded_extensions' ), - 'get_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_plugins' ), - 'get_themes' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_themes' ), - 'get_plugins_action_links' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_plugins_action_links' ), - 'has_file_system_write_access' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'file_system_write_access' ), - 'home_url' => array( 'Automattic\\Jetpack\\Connection\\Urls', 'home_url' ), - 'hosting_provider' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_hosting_provider' ), - 'is_fse_theme' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_is_fse_theme' ), - 'is_main_network' => array( __CLASS__, 'is_multi_network' ), - 'is_multi_site' => 'is_multisite', - 'is_version_controlled' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'is_version_controlled' ), - 'locale' => 'get_locale', - 'main_network_site' => array( 'Automattic\\Jetpack\\Connection\\Urls', 'main_network_site_url' ), - 'main_network_site_wpcom_id' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'main_network_site_wpcom_id' ), - 'paused_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_paused_plugins' ), - 'paused_themes' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_paused_themes' ), - 'post_type_features' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_post_type_features' ), - 'post_types' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_post_types' ), - 'rest_api_allowed_post_types' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'rest_api_allowed_post_types' ), - 'rest_api_allowed_public_metadata' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'rest_api_allowed_public_metadata' ), - 'roles' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'roles' ), - 'shortcodes' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_shortcodes' ), - 'site_icon_url' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'site_icon_url' ), - 'site_url' => array( 'Automattic\\Jetpack\\Connection\\Urls', 'site_url' ), - 'taxonomies' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_taxonomies' ), - 'theme_support' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_theme_support' ), - 'timezone' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_timezone' ), - 'wp_get_environment_type' => 'wp_get_environment_type', - 'wp_max_upload_size' => 'wp_max_upload_size', - 'wp_version' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'wp_version' ), - 'active_modules' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_active_modules' ), - 'jetpack_connection_active_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_jetpack_connection_active_plugins' ), - 'jetpack_sync_active_modules' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_jetpack_sync_active_modules' ), - ); - - /** - * Array of post type attributes synced. - * - * @var array Default post type attributes. - */ - public static $default_post_type_attributes = array( - '_builtin' => false, - '_edit_link' => 'post.php?post=%d', - 'can_export' => true, - 'cap' => array(), - 'capabilities' => array(), - 'capability_type' => 'post', - 'delete_with_user' => null, - 'description' => '', - 'exclude_from_search' => true, - 'has_archive' => false, - 'hierarchical' => false, - 'label' => '', - 'labels' => array(), - 'map_meta_cap' => true, - 'menu_icon' => null, - 'menu_position' => null, - 'name' => '', - 'public' => false, - 'publicly_queryable' => null, - 'query_var' => true, - 'rest_base' => false, - 'rewrite' => true, - 'show_in_admin_bar' => false, - 'show_in_menu' => null, - 'show_in_nav_menus' => null, - 'show_in_rest' => false, - 'show_ui' => false, - 'supports' => array(), - 'taxonomies' => array(), - ); - - /** - * Get the whitelist of callables allowed to be managed via the JSON API. - * - * @return array Whitelist of callables allowed to be managed via the JSON API. - */ - public static function get_callable_whitelist() { - /** - * Filter the list of callables that are manageable via the JSON API. - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 4.8.0 - * - * @param array The default list of callables. - */ - return apply_filters( 'jetpack_sync_callable_whitelist', self::$default_callable_whitelist ); - } - - /** - * Post types that will not be synced. - * - * These are usually automated post types (sitemaps, logs, etc). - * - * @var array Blacklisted post types. - */ - public static $blacklisted_post_types = array( - '_term_meta', - 'ai1ec_event', - 'ai_log', // Logger - https://github.com/alleyinteractive/logger. - 'amp_validated_url', // AMP Validation Errors. - 'bwg_album', - 'bwg_gallery', - 'customize_changeset', // WP built-in post type for Customizer changesets. - 'dn_wp_yt_log', - 'flamingo_contact', // https://wordpress.org/plugins/flamingo/. - 'flamingo_inbound', - 'flamingo_outbound', - 'http', - 'idx_page', - 'jetpack_inspect_log', // Jetpack Inspect dev tool. p1HpG7-nkd-p2 - 'jetpack_migration', - 'jp_img_sitemap', - 'jp_img_sitemap_index', - 'jp_sitemap', - 'jp_sitemap_index', - 'jp_sitemap_master', - 'jp_vid_sitemap', - 'jp_vid_sitemap_index', - 'msm_sitemap', // Metro Sitemap Plugin. - 'postman_sent_mail', - 'rssap-feed', - 'rssmi_feed_item', - 'scheduled-action', // Action Scheduler - Job Queue for WordPress https://github.com/woocommerce/woocommerce/tree/e7762627c37ec1f7590e6cac4218ba0c6a20024d/includes/libraries/action-scheduler . - 'secupress_log_action', - 'sg_optimizer_jobs', - 'sl-insta-media', - 'snitch', - 'vip-legacy-redirect', - 'wp-rest-api-log', // https://wordpress.org/plugins/wp-rest-api-log/. - 'wp_automatic', - 'wp_log', // WP Logging Plugin. - 'wpephpcompat_jobs', - 'wprss_feed_item', - 'tribe-ea-record', // The Events Calendar Plugin - Store Event Aggregator record information. - 'wphb_minify_group', // Hummingbird Plugin - Used internally to keep data about assets minification. - 'bigcommerce_task', // BigCommerce Plugin - Store import queue. - 'secupress_log_err404', // SecuPress Plugin - Log 404 pages - 'iw_omnibus_price_log', // Omnibus Plugin - Log price changes. - 'od_url_metrics', // Optimization Detective - Log URL metrics. - ); - - /** - * Taxonomies that we're not syncing by default. - * - * The list is compiled by auditing the dynamic filters and actions that contain taxonomy slugs - * and could conflict with other existing filters/actions in WP core, Jetpack and WooCommerce. - * - * @var array - */ - public static $blacklisted_taxonomies = array( - 'ancestors', - 'archives_link', - 'attached_file', - 'attached_media', - 'attached_media_args', - 'attachment', - 'available_languages', - 'avatar', - 'avatar_comment_types', - 'avatar_data', - 'avatar_url', - 'bloginfo_rss', - 'blogs_of_user', - 'bookmark_link', - 'bookmarks', - 'calendar', - 'canonical_url', - 'categories_per_page', - 'categories_taxonomy', - 'category_form', - 'category_form_fields', - 'category_form_pre', - 'comment', - 'comment_ID', - 'comment_author', - 'comment_author_IP', - 'comment_author_email', - 'comment_author_link', - 'comment_author_url', - 'comment_author_url_link', - 'comment_date', - 'comment_excerpt', - 'comment_link', - 'comment_misc_actions', - 'comment_text', - 'comment_time', - 'comment_type', - 'comments_link', - 'comments_number', - 'comments_pagenum_link', - 'custom_logo', - 'date_sql', - 'default_comment_status', - 'delete_post_link', - 'edit_bookmark_link', - 'edit_comment_link', - 'edit_post_link', - 'edit_tag_link', - 'edit_term_link', - 'edit_user_link', - 'enclosed', - 'feed_build_date', - 'form_advanced', - 'form_after_editor', - 'form_after_title', - 'form_before_permalink', - 'form_top', - 'handle_product_cat', - 'header_image_tag', - 'header_video_url', - 'image_tag', - 'image_tag_class', - 'lastpostdate', - 'lastpostmodified', - 'link', - 'link_category_form', - 'link_category_form_fields', - 'link_category_form_pre', - 'main_network_id', - 'media', - 'media_item_args', - 'ms_user', - 'network', - 'object_terms', - 'option', - 'page', - 'page_form', - 'page_of_comment', - 'page_uri', - 'pagenum_link', - 'pages', - 'plugin', - 'post', - 'post_galleries', - 'post_gallery', - 'post_link', - 'post_modified_time', - 'post_status', - 'post_time', - 'postmeta', - 'posts_per_page', - 'product_search_form', - 'profile_url', - 'pung', - 'role_list', - 'sample_permalink', - 'sample_permalink_html', - 'schedule', - 'search_form', - 'search_query', - 'shortlink', - 'site', - 'site_email_content', - 'site_icon_url', - 'site_option', - 'space_allowed', - 'tag', - 'tag_form', - 'tag_form_fields', - 'tag_form_pre', - 'tag_link', - 'tags', - 'tags_per_page', - 'term', - 'term_link', - 'term_relationships', - 'term_taxonomies', - 'term_taxonomy', - 'terms', - 'terms_args', - 'terms_defaults', - 'terms_fields', - 'terms_orderby', - 'the_archive_description', - 'the_archive_title', - 'the_categories', - 'the_date', - 'the_excerpt', - 'the_guid', - 'the_modified_date', - 'the_modified_time', - 'the_post_type_description', - 'the_tags', - 'the_terms', - 'the_time', - 'theme_starter_content', - 'to_ping', - 'user', - 'user_created_user', - 'user_form', - 'user_profile', - 'user_profile_update', - 'usermeta', - 'usernumposts', - 'users_drafts', - 'webhook', - 'widget', - 'woocommerce_archive', - 'wp_title_rss', - ); - - /** - * Default array of post table columns. - * - * @var array Post table columns. - */ - public static $default_post_checksum_columns = array( - 'ID', - 'post_modified', - ); - - /** - * Default array of post meta table columns. - * - * @var array Post meta table columns. - */ - public static $default_post_meta_checksum_columns = array( - 'meta_id', - 'meta_value', - ); - - /** - * Default array of comment table columns. - * - * @var array Default comment table columns. - */ - public static $default_comment_checksum_columns = array( - 'comment_ID', - 'comment_content', - ); - - /** - * Default array of comment meta columns. - * - * @var array Comment meta table columns. - */ - public static $default_comment_meta_checksum_columns = array( - 'meta_id', - 'meta_value', - ); - - /** - * Default array of option table columns. - * - * @var array Default array of option columns. - */ - public static $default_option_checksum_columns = array( - 'option_name', - 'option_value', - ); - - /** - * Default array of term columns. - * - * @var array array of term columns. - */ - public static $default_term_checksum_columns = array( - 'name', - 'slug', - 'term_id', - ); - - /** - * Default array of term taxonomy columns. - * - * @var array Array of term taxonomy columns. - */ - public static $default_term_taxonomy_checksum_columns = array( - 'count', - 'parent', - 'taxonomy', - 'term_id', - 'term_taxonomy_id', - ); - - /** - * Default term relationship columns. - * - * @var array Array of term relationship columns. - */ - public static $default_term_relationships_checksum_columns = array( - 'object_id', - 'term_order', - 'term_taxonomy_id', - ); - - /** - * Default multisite callables able to be managed via JSON API. - * - * @var array multsite callables whitelisted - */ - public static $default_multisite_callable_whitelist = array(); - - /** - * Get array of multisite callables whitelisted. - * - * @return array Multisite callables managable via JSON API. - */ - public static function get_multisite_callable_whitelist() { - /** - * Filter the list of multisite callables that are manageable via the JSON API. - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 4.8.0 - * - * @param array The default list of multisite callables. - */ - return apply_filters( 'jetpack_sync_multisite_callable_whitelist', self::$default_multisite_callable_whitelist ); - } - - /** - * Array of post meta keys whitelisted. - * - * @var array Post meta whitelist. - */ - public static $post_meta_whitelist = array( - '_feedback_akismet_values', - '_feedback_email', - '_feedback_extra_fields', - '_g_feedback_shortcode', - '_jetpack_post_thumbnail', - '_last_editor_used_jetpack', - '_menu_item_classes', - '_menu_item_menu_item_parent', - '_menu_item_object', - '_menu_item_object_id', - '_menu_item_orphaned', - '_menu_item_type', - '_menu_item_xfn', - '_publicize_facebook_user', - '_publicize_twitter_user', - '_thumbnail_id', - '_wp_attached_file', - '_wp_attachment_backup_sizes', - '_wp_attachment_context', - '_wp_attachment_image_alt', - '_wp_attachment_is_custom_background', - '_wp_attachment_is_custom_header', - '_wp_attachment_metadata', - '_wp_old_date', - '_wp_page_template', - '_wp_trash_meta_comments_status', - '_wpas_feature_enabled', - '_wpas_mess', - '_wpas_options', - 'advanced_seo_description', // Jetpack_SEO_Posts::DESCRIPTION_META_KEY. - 'content_width', - 'custom_css_add', - 'custom_css_preprocessor', - 'enclosure', - 'imagedata', - 'nova_price', - 'publicize_results', - 'sharing_disabled', - 'switch_like_status', - 'videopress_guid', - 'vimeo_poster_image', - '_jetpack_blogging_prompt_key', - 'footnotes', // Core footnotes block - ); - - /** - * Get the post meta key whitelist. - * - * @return array Post meta whitelist. - */ - public static function get_post_meta_whitelist() { - /** - * Filter the list of post meta data that are manageable via the JSON API. - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 4.8.0 - * - * @param array The default list of meta data keys. - */ - return apply_filters( 'jetpack_sync_post_meta_whitelist', self::$post_meta_whitelist ); - } - - /** - * Comment meta whitelist. - * - * @var array Comment meta whitelist. - */ - public static $comment_meta_whitelist = array( - 'hc_avatar', - 'hc_foreign_user_id', - 'hc_post_as', - 'hc_wpcom_id_sig', - ); - - /** - * Get the comment meta whitelist. - * - * @return array - */ - public static function get_comment_meta_whitelist() { - /** - * Filter the list of comment meta data that are manageable via the JSON API. - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 5.7.0 - * - * @param array The default list of comment meta data keys. - */ - return apply_filters( 'jetpack_sync_comment_meta_whitelist', self::$comment_meta_whitelist ); - } - - /** - * Default theme support whitelist. - * - * @todo move this to server? - these are theme support values - * that should be synced as jetpack_current_theme_supports_foo option values - * - * @var array Default theme support whitelist. - */ - public static $default_theme_support_whitelist = array( - 'align-wide', - 'appearance-tools', // In Gutenberg. - 'automatic-feed-links', - 'block-templates', - 'block-template-parts', // WP 6.1. Added via https://core.trac.wordpress.org/changeset/54176 - 'custom-background', - 'custom-header', - 'custom-logo', - 'customize-selective-refresh-widgets', - 'dark-editor-style', - 'default-color-palette', // In Gutenberg. - 'default-gradient-presets', // In Gutenberg. - 'disable-custom-colors', - 'disable-custom-font-sizes', - 'disable-custom-gradients', - 'disable-layout-styles', // WP 6.1. Added via https://core.trac.wordpress.org/changeset/54159 - 'editor-color-palette', - 'editor-font-sizes', - 'editor-gradient-presets', - 'editor-spacing-sizes', - 'editor-style', // deprecated. - 'editor-styles', - 'html5', - 'infinite-scroll', - 'jetpack-responsive-videos', - 'jetpack-social-menu', - 'menus', - 'post-formats', - 'post-thumbnails', - 'responsive-embeds', - 'site-logo', - 'title-tag', - 'widgets', - 'wp-block-styles', - ); - - /** - * Is an option whitelisted? - * - * @param string $option Option name. - * @return bool If option is on the whitelist. - */ - public static function is_whitelisted_option( $option ) { - $whitelisted_options = self::get_options_whitelist(); - foreach ( $whitelisted_options as $whitelisted_option ) { - if ( '/' === $whitelisted_option[0] && preg_match( $whitelisted_option, $option ) ) { - return true; - } elseif ( $whitelisted_option === $option ) { - return true; - } - } - - return false; - } - - /** - * Default whitelist of capabilities to sync. - * - * @var array Array of WordPress capabilities. - */ - public static $default_capabilities_whitelist = array( - 'activate_plugins', - 'add_users', - 'create_users', - 'customize', - 'delete_others_pages', - 'delete_others_posts', - 'delete_pages', - 'delete_plugins', - 'delete_posts', - 'delete_private_pages', - 'delete_private_posts', - 'delete_published_pages', - 'delete_published_posts', - 'delete_site', - 'delete_themes', - 'delete_users', - 'edit_dashboard', - 'edit_files', - 'edit_others_pages', - 'edit_others_posts', - 'edit_pages', - 'edit_plugins', - 'edit_posts', - 'edit_private_pages', - 'edit_private_posts', - 'edit_published_pages', - 'edit_published_posts', - 'edit_theme_options', - 'edit_themes', - 'edit_users', - 'export', - 'import', - 'install_plugins', - 'install_themes', - 'list_users', - 'manage_categories', - 'manage_links', - 'manage_options', - 'moderate_comments', - 'promote_users', - 'publish_pages', - 'publish_posts', - 'read', - 'read_private_pages', - 'read_private_posts', - 'remove_users', - 'switch_themes', - 'unfiltered_html', - 'unfiltered_upload', - 'update_core', - 'update_plugins', - 'update_themes', - 'upload_files', - 'upload_plugins', - 'upload_themes', - ); - - /** - * Get default capabilities whitelist. - * - * @return array - */ - public static function get_capabilities_whitelist() { - /** - * Filter the list of capabilities that we care about - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 5.5.0 - * - * @param array The default list of capabilities. - */ - return apply_filters( 'jetpack_sync_capabilities_whitelist', self::$default_capabilities_whitelist ); - } - - /** - * Get max execution sync time. - * - * @return float Number of seconds. - */ - public static function get_max_sync_execution_time() { - $max_exec_time = (int) ini_get( 'max_execution_time' ); - if ( 0 === $max_exec_time ) { - // 0 actually means "unlimited", but let's not treat it that way. - $max_exec_time = 60; - } - return floor( $max_exec_time / 3 ); - } - - /** - * Get default for a given setting. - * - * @param string $setting Setting to get. - * @return mixed Value will be a string, int, array, based on the particular setting requested. - */ - public static function get_default_setting( $setting ) { - $default_name = "default_$setting"; // e.g. default_dequeue_max_bytes. - return self::$$default_name; - } - - /** - * Default list of network options. - * - * @var array network options - */ - public static $default_network_options_whitelist = array( - 'active_sitewide_plugins', - 'auto_update_plugins', // WordPress 5.5+ auto-updates. - 'jetpack_protect_global_whitelist', - 'jetpack_protect_key', - 'site_name', - ); - - /** - * A mapping of known importers to friendly names. - * - * Keys are the class name of the known importer. - * Values are the friendly name. - * - * @since 1.6.3 - * @since-jetpack 7.3.0 - * - * @var array - */ - public static $default_known_importers = array( - 'Blogger_Importer' => 'blogger', - 'LJ_API_Import' => 'livejournal', - 'MT_Import' => 'mt', - 'RSS_Import' => 'rss', - 'WC_Tax_Rate_Importer' => 'woo-tax-rate', - 'WP_Import' => 'wordpress', - ); - - /** - * Returns a list of known importers. - * - * @since 1.6.3 - * @since-jetpack 7.3.0 - * - * @return array Known importers with importer class names as keys and friendly names as values. - */ - public static function get_known_importers() { - /** - * Filter the list of known importers. - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 7.3.0 - * - * @param array The default list of known importers. - */ - return apply_filters( 'jetpack_sync_known_importers', self::$default_known_importers ); - } - - /** - * Whether this is a system with a multiple networks. - * We currently need this static wrapper because we statically define our default list of callables. - * - * @since 1.6.3 - * @since-jetpack 7.6.0 - * - * @uses Automattic\Jetpack\Status::is_multi_network - * - * @return boolean - */ - public static function is_multi_network() { - $status = new Status(); - return $status->is_multi_network(); - } - - /** - * Default bytes to dequeue. - * - * @var int Bytes. - */ - public static $default_dequeue_max_bytes = 500000; // very conservative value, 1/2 MB. - - /** - * Default upload bytes. - * - * This value is a little bigger than the upload limit to account for serialization. - * - * @var int Bytes. - */ - public static $default_upload_max_bytes = 600000; - - /** - * Default number of rows uploaded. - * - * @var int Number of rows. - */ - public static $default_upload_max_rows = 500; - - /** - * Default sync wait time. - * - * @var int Number of seconds. - */ - public static $default_sync_wait_time = 10; // seconds, between syncs. - - /** - * Only wait before next send if the current send took more than this number of seconds. - * - * @var int Number of seconds. - */ - public static $default_sync_wait_threshold = 10; - - /** - * Default wait between attempting to continue a full sync via requests. - * - * @var int Number of seconds. - */ - public static $default_enqueue_wait_time = 1; - - /** - * Maximum queue size. - * - * Each item is represented with a new row in the wp_options table. - * - * @var int Number of queue items. - */ - public static $default_max_queue_size = 5000; - - /** - * Default maximum lag allowed in the queue. - * - * @var int Number of seconds - */ - public static $default_max_queue_lag = 7200; // 2 hours. - - /** - * Default for default writes per sec. - * - * @var int Rows per second. - */ - public static $default_queue_max_writes_sec = 100; // 100 rows a second. - - /** - * Default for post types blacklist. - * - * @var array Empty array. - */ - public static $default_post_types_blacklist = array(); - - /** - * Default for taxonomies blacklist. - * - * @var array Empty array. - */ - public static $default_taxonomies_blacklist = array(); - - /** - * Default for taxonomies whitelist. - * - * @var array Empty array. - */ - public static $default_taxonomy_whitelist = array(); - - /** - * Default for post meta whitelist. - * - * @var array Empty array. - */ - public static $default_post_meta_whitelist = array(); - - /** - * Default for comment meta whitelist. - * - * @var array Empty array. - */ - public static $default_comment_meta_whitelist = array(); - - /** - * Default for disabling sync across the site. - * - * @var int Bool-ish. Default to 0. - */ - public static $default_disable = 0; // completely disable sending data to wpcom. - - /** - * Default for disabling sync across the entire network on multisite. - * - * @var int Bool-ish. Default 0. - */ - public static $default_network_disable = 0; - - /** - * Default for disabling checksums. - * - * @var int Bool-ish. Default 0. - */ - public static $default_checksum_disable = 0; - - /** - * Should Sync use cron? - * - * @var int Bool-ish value. Default 1. - */ - public static $default_sync_via_cron = 1; - - /** - * Default if Sync should render content. - * - * @var int Bool-ish value. Default is 0. - */ - public static $default_render_filtered_content = 0; - - /** - * Default number of items to enqueue at a time when running full sync. - * - * @var int Number of items. - */ - public static $default_max_enqueue_full_sync = 100; - - /** - * Default for maximum queue size during a full sync. - * - * Each item will represent a value in the wp_options table. - * - * @var int Number of items. - */ - public static $default_max_queue_size_full_sync = 1000; // max number of total items in the full sync queue. - - /** - * Default max time for sending in immediate mode. - * - * @var float Number of Seconds - */ - public static $default_full_sync_send_duration = 9; - - /** - * Defaul for time between syncing callables. - * - * @var int Number of seconds. - */ - public static $default_sync_callables_wait_time = MINUTE_IN_SECONDS; // seconds before sending callables again. - - /** - * Default for time between syncing constants. - * - * @var int Number of seconds. - */ - public static $default_sync_constants_wait_time = HOUR_IN_SECONDS; // seconds before sending constants again. - /** - * Default for sync queue lock timeout time. - * - * @var int Number of seconds. - */ - public static $default_sync_queue_lock_timeout = 120; // 2 minutes. - - /** - * Default for cron sync time limit. - * - * @var int Number of seconds. - */ - public static $default_cron_sync_time_limit = 4 * MINUTE_IN_SECONDS; - - /** - * Default for number of term relationship items sent in an full sync item. - * - * @var int Number of items. - */ - public static $default_term_relationships_full_sync_item_size = 100; - - /** - * Default for enabling incremental sync. - * - * @var int 1 for true. - */ - public static $default_sync_sender_enabled = 1; // Should send incremental sync items. - - /** - * Default for enabling Full Sync. - * - * @var int 1 for true. - */ - public static $default_full_sync_sender_enabled = 1; // Should send full sync items. - - /** - * Default Full Sync config - * - * @var array list of module names. - */ - public static $default_full_sync_config = array( - 'constants' => 1, - 'functions' => 1, - 'options' => 1, - 'terms' => 1, - 'themes' => 1, - 'users' => 1, - 'posts' => 1, - 'comments' => 1, - 'updates' => 1, - 'term_relationships' => 1, - ); - - /** - * Default Full Sync limits for one module. - * - * @var array list of limits. - */ - public static $default_full_sync_limits_per_module = array( - 'chunk_size' => 100, - 'max_chunks' => 10, - ); - /** - * Default Full Sync max objects to send on a single request. - * - * @var array list of module => max. - */ - public static $default_full_sync_limits = array( - 'comments' => array( - 'chunk_size' => 100, - 'max_chunks' => 10, - ), - 'posts' => array( - 'chunk_size' => 100, - 'max_chunks' => 1, - ), - 'term_relationships' => array( - 'chunk_size' => 1000, - 'max_chunks' => 10, - ), - 'terms' => array( - 'chunk_size' => 1000, - 'max_chunks' => 10, - ), - 'users' => array( - 'chunk_size' => 100, - 'max_chunks' => 10, - ), - 'woocommerce' => array( - 'chunk_size' => 100, - 'max_chunks' => 10, - ), - 'woocommerce_hpos_orders' => array( - 'chunk_size' => 100, - 'max_chunks' => 10, - ), - ); - - /** - * Default for enabling dedicated Sync flow. - * - * @var int Bool-ish. Default 0. - */ - public static $default_dedicated_sync_enabled = 0; - - /** - * Default for enabling custom queue table for Sync. - * - * @var int Bool-ish. Default 0. - */ - public static $default_custom_queue_table_enabled = 0; - - /** - * Default for enabling wpcom rest api for Sync. - * - * @var int Bool-ish. Default 0. - */ - public static $default_wpcom_rest_api_enabled = 0; -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php deleted file mode 100644 index d6435a97..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php +++ /dev/null @@ -1,740 +0,0 @@ -get_modules(); - } - - return array(); - } - - /** - * Return array of taxonomies registered on the site. - * - * @return array - */ - public static function get_taxonomies() { - global $wp_taxonomies; - $wp_taxonomies_without_callbacks = array(); - foreach ( $wp_taxonomies as $taxonomy_name => $taxonomy ) { - $sanitized_taxonomy = self::sanitize_taxonomy( $taxonomy ); - if ( ! empty( $sanitized_taxonomy ) ) { - $wp_taxonomies_without_callbacks[ $taxonomy_name ] = $sanitized_taxonomy; - } - } - return $wp_taxonomies_without_callbacks; - } - - /** - * Return array of registered shortcodes. - * - * @return array - */ - public static function get_shortcodes() { - global $shortcode_tags; - return array_keys( $shortcode_tags ); - } - - /** - * Removes any callback data since we will not be able to process it on our side anyways. - * - * @param \WP_Taxonomy $taxonomy \WP_Taxonomy item. - * - * @return mixed|null - */ - public static function sanitize_taxonomy( $taxonomy ) { - - // Lets clone the taxonomy object instead of modifing the global one. - $cloned_taxonomy = json_decode( wp_json_encode( $taxonomy ) ); - - // recursive taxonomies are no fun. - if ( $cloned_taxonomy === null ) { - return null; - } - // Remove any meta_box_cb if they are not the default wp ones. - if ( isset( $cloned_taxonomy->meta_box_cb ) && - ! in_array( $cloned_taxonomy->meta_box_cb, array( 'post_tags_meta_box', 'post_categories_meta_box' ), true ) ) { - $cloned_taxonomy->meta_box_cb = null; - } - // Remove update call back. - if ( isset( $cloned_taxonomy->update_count_callback ) && - $cloned_taxonomy->update_count_callback !== null ) { - $cloned_taxonomy->update_count_callback = null; - } - // Remove rest_controller_class if it something other then the default. - if ( isset( $cloned_taxonomy->rest_controller_class ) && - 'WP_REST_Terms_Controller' !== $cloned_taxonomy->rest_controller_class ) { - $cloned_taxonomy->rest_controller_class = null; - } - return $cloned_taxonomy; - } - - /** - * Return array of registered post types. - * - * @return array - */ - public static function get_post_types() { - global $wp_post_types; - - $post_types_without_callbacks = array(); - foreach ( $wp_post_types as $post_type_name => $post_type ) { - $sanitized_post_type = self::sanitize_post_type( $post_type ); - if ( ! empty( $sanitized_post_type ) ) { - $post_types_without_callbacks[ $post_type_name ] = $sanitized_post_type; - } - } - return $post_types_without_callbacks; - } - - /** - * Sanitizes by cloning post type object. - * - * @param object $post_type \WP_Post_Type. - * - * @return object - */ - public static function sanitize_post_type( $post_type ) { - // Lets clone the post type object instead of modifing the global one. - $sanitized_post_type = array(); - foreach ( Defaults::$default_post_type_attributes as $attribute_key => $default_value ) { - if ( isset( $post_type->{ $attribute_key } ) ) { - $sanitized_post_type[ $attribute_key ] = $post_type->{ $attribute_key }; - } - } - return (object) $sanitized_post_type; - } - - /** - * Return information about a synced post type. - * - * @param array $sanitized_post_type Array of args used in constructing \WP_Post_Type. - * @param string $post_type Post type name. - * - * @return object \WP_Post_Type - */ - public static function expand_synced_post_type( $sanitized_post_type, $post_type ) { - $post_type = sanitize_key( $post_type ); - $post_type_object = new \WP_Post_Type( $post_type, $sanitized_post_type ); - $post_type_object->add_supports(); - $post_type_object->add_rewrite_rules(); - $post_type_object->add_hooks(); - $post_type_object->register_taxonomies(); - return (object) $post_type_object; - } - - /** - * Returns site's post_type_features. - * - * @return array - */ - public static function get_post_type_features() { - global $_wp_post_type_features; - - return $_wp_post_type_features; - } - - /** - * Return hosting provider. - * - * Uses a set of known constants, classes, or functions to help determine the hosting platform. - * - * @return string Hosting provider. - */ - public static function get_hosting_provider() { - $hosting_provider_detection_methods = array( - 'get_hosting_provider_by_known_constant', - 'get_hosting_provider_by_known_class', - 'get_hosting_provider_by_known_function', - ); - - $functions = new Functions(); - foreach ( $hosting_provider_detection_methods as $method ) { - $hosting_provider = call_user_func( array( $functions, $method ) ); - if ( false !== $hosting_provider ) { - return $hosting_provider; - } - } - - return 'unknown'; - } - - /** - * Return a hosting provider using a set of known constants. - * - * @return mixed A host identifier string or false. - */ - public function get_hosting_provider_by_known_constant() { - $hosting_provider_constants = array( - 'GD_SYSTEM_PLUGIN_DIR' => 'gd-managed-wp', - 'MM_BASE_DIR' => 'bh', - 'PAGELYBIN' => 'pagely', - 'KINSTAMU_VERSION' => 'kinsta', - 'FLYWHEEL_CONFIG_DIR' => 'flywheel', - 'IS_PRESSABLE' => 'pressable', - 'VIP_GO_ENV' => 'vip-go', - ); - - foreach ( $hosting_provider_constants as $constant => $constant_value ) { - if ( Constants::is_defined( $constant ) ) { - if ( 'VIP_GO_ENV' === $constant && false === Constants::get_constant( 'VIP_GO_ENV' ) ) { - continue; - } - return $constant_value; - } - } - - return false; - } - - /** - * Return a hosting provider using a set of known classes. - * - * @return mixed A host identifier string or false. - */ - public function get_hosting_provider_by_known_class() { - $hosting_provider = false; - - switch ( true ) { - case ( class_exists( '\\WPaaS\\Plugin' ) ): - $hosting_provider = 'gd-managed-wp'; - break; - } - - return $hosting_provider; - } - - /** - * Return a hosting provider using a set of known functions. - * - * @return mixed A host identifier string or false. - */ - public function get_hosting_provider_by_known_function() { - $hosting_provider = false; - - switch ( true ) { - case ( function_exists( 'is_wpe' ) || function_exists( 'is_wpe_snapshot' ) ): - $hosting_provider = 'wpe'; - break; - } - - return $hosting_provider; - } - - /** - * Return array of allowed REST API post types. - * - * @return array Array of allowed post types. - */ - public static function rest_api_allowed_post_types() { - /** This filter is already documented in class.json-api-endpoints.php */ - return apply_filters( 'rest_api_allowed_post_types', array( 'post', 'page', 'revision' ) ); - } - - /** - * Return array of allowed REST API public metadata. - * - * @return array Array of allowed metadata. - */ - public static function rest_api_allowed_public_metadata() { - /** - * Filters the meta keys accessible by the REST API. - * - * @see https://developer.wordpress.com/2013/04/26/custom-post-type-and-metadata-support-in-the-rest-api/ - * - * @module json-api - * - * @since 1.6.3 - * @since-jetpack 2.2.3 - * - * @param array $whitelisted_meta Array of metadata that is accessible by the REST API. - */ - return apply_filters( 'rest_api_allowed_public_metadata', array() ); - } - - /** - * Finds out if a site is using a version control system. - * - * @return bool - **/ - public static function is_version_controlled() { - - if ( ! class_exists( 'WP_Automatic_Updater' ) ) { - require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php'; - } - $updater = new \WP_Automatic_Updater(); - - return (bool) (string) $updater->is_vcs_checkout( ABSPATH ); - } - - /** - * Returns true if the site has file write access false otherwise. - * - * @return bool - **/ - public static function file_system_write_access() { - if ( ! function_exists( 'get_filesystem_method' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - require_once ABSPATH . 'wp-admin/includes/template.php'; - - $filesystem_method = get_filesystem_method(); - if ( 'direct' === $filesystem_method ) { - return true; - } - - ob_start(); - - if ( ! function_exists( 'request_filesystem_credentials' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - $filesystem_credentials_are_stored = request_filesystem_credentials( self_admin_url() ); - ob_end_clean(); - if ( $filesystem_credentials_are_stored ) { - return true; - } - - return false; - } - - /** - * Helper function that is used when getting home or siteurl values. Decides - * whether to get the raw or filtered value. - * - * @deprecated 1.23.1 - * - * @param string $url_type URL to get, home or siteurl. - * @return string - */ - public static function get_raw_or_filtered_url( $url_type ) { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::get_raw_or_filtered_url' ); - return Urls::get_raw_or_filtered_url( $url_type ); - } - - /** - * Return the escaped home_url. - * - * @deprecated 1.23.1 - * - * @return string - */ - public static function home_url() { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::home_url' ); - return Urls::home_url(); - } - - /** - * Return the escaped siteurl. - * - * @deprecated 1.23.1 - * - * @return string - */ - public static function site_url() { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::site_url' ); - return Urls::site_url(); - } - - /** - * Return main site URL with a normalized protocol. - * - * @deprecated 1.23.1 - * - * @return string - */ - public static function main_network_site_url() { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::main_network_site_url' ); - return Urls::main_network_site_url(); - } - - /** - * Return main site WordPress.com site ID. - * - * @return string - */ - public static function main_network_site_wpcom_id() { - /** - * Return the current site WPCOM ID for single site installs - */ - if ( ! is_multisite() ) { - return \Jetpack_Options::get_option( 'id' ); - } - - /** - * Return the main network site WPCOM ID for multi-site installs - */ - $current_network = get_network(); - switch_to_blog( $current_network->blog_id ); - $wpcom_blog_id = \Jetpack_Options::get_option( 'id' ); - restore_current_blog(); - return $wpcom_blog_id; - } - - /** - * Return URL with a normalized protocol. - * - * @deprecated 1.23.1 - * - * @param string $callable Function name that was used to retrieve URL option. - * @param string $new_value URL Protocol to set URLs to. - * @return string Normalized URL. - */ - public static function get_protocol_normalized_url( $callable, $new_value ) { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::get_protocol_normalized_url' ); - return Urls::get_protocol_normalized_url( $callable, $new_value ); - } - - /** - * Return URL from option or PHP constant. - * - * @deprecated 1.23.1 - * - * @param string $option_name (e.g. 'home'). - * - * @return mixed|null URL. - */ - public static function get_raw_url( $option_name ) { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::get_raw_url' ); - return Urls::get_raw_url( $option_name ); - } - - /** - * Normalize domains by removing www unless declared in the site's option. - * - * @deprecated 1.23.1 - * - * @param string $option Option value from the site. - * @param callable $url_function Function retrieving the URL to normalize. - * @return mixed|string URL. - */ - public static function normalize_www_in_url( $option, $url_function ) { - _deprecated_function( __METHOD__, '1.23.1', '\\Automattic\\Jetpack\\Connection\\Urls::normalize_www_in_url' ); - return Urls::normalize_www_in_url( $option, $url_function ); - } - - /** - * Return filtered value of get_plugins. - * - * @return mixed|void - */ - public static function get_plugins() { - if ( ! function_exists( 'get_plugins' ) ) { - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - - /** This filter is documented in wp-admin/includes/class-wp-plugins-list-table.php */ - return apply_filters( 'all_plugins', get_plugins() ); - } - - /** - * Get custom action link tags that the plugin is using - * Ref: https://codex.wordpress.org/Plugin_API/Filter_Reference/plugin_action_links_(plugin_file_name) - * - * @param string $plugin_file_singular Particular plugin. - * @return array of plugin action links (key: link name value: url) - */ - public static function get_plugins_action_links( $plugin_file_singular = null ) { - // Some sites may have DOM disabled in PHP fail early. - if ( ! class_exists( 'DOMDocument' ) ) { - return array(); - } - $plugins_action_links = get_option( 'jetpack_plugin_api_action_links', array() ); - if ( ! empty( $plugins_action_links ) ) { - if ( $plugin_file_singular === null ) { - return $plugins_action_links; - } - return ( isset( $plugins_action_links[ $plugin_file_singular ] ) ? $plugins_action_links[ $plugin_file_singular ] : null ); - } - return array(); - } - - /** - * Return the WP version as defined in the $wp_version global. - * - * @return string - */ - public static function wp_version() { - global $wp_version; - return $wp_version; - } - - /** - * Return site icon url used on the site. - * - * @param int $size Size of requested icon in pixels. - * @return mixed|string|void - */ - public static function site_icon_url( $size = 512 ) { - $site_icon = get_site_icon_url( $size ); - return $site_icon ? $site_icon : get_option( 'jetpack_site_icon_url' ); - } - - /** - * Return roles registered on the site. - * - * @return array - */ - public static function roles() { - $wp_roles = wp_roles(); - return $wp_roles->roles; - } - - /** - * Determine time zone from WordPress' options "timezone_string" - * and "gmt_offset". - * - * 1. Check if `timezone_string` is set and return it. - * 2. Check if `gmt_offset` is set, formats UTC-offset from it and return it. - * 3. Default to "UTC+0" if nothing is set. - * - * Note: This function is specifically not using wp_timezone() to keep consistency with - * the existing formatting of the timezone string. - * - * @return string - */ - public static function get_timezone() { - $timezone_string = get_option( 'timezone_string' ); - - if ( ! empty( $timezone_string ) ) { - return str_replace( '_', ' ', $timezone_string ); - } - - $gmt_offset = get_option( 'gmt_offset', 0 ); - - $formatted_gmt_offset = sprintf( '%+g', (float) $gmt_offset ); - - $formatted_gmt_offset = str_replace( - array( '.25', '.5', '.75' ), - array( ':15', ':30', ':45' ), - (string) $formatted_gmt_offset - ); - - /* translators: %s is UTC offset, e.g. "+1" */ - return sprintf( __( 'UTC%s', 'jetpack-sync' ), $formatted_gmt_offset ); - } - - /** - * Return list of paused themes. - * - * @return array|bool Array of paused themes or false if unsupported. - */ - public static function get_paused_themes() { - $paused_themes = wp_paused_themes(); - return $paused_themes->get_all(); - } - - /** - * Return list of paused plugins. - * - * @return array|bool Array of paused plugins or false if unsupported. - */ - public static function get_paused_plugins() { - $paused_plugins = wp_paused_plugins(); - return $paused_plugins->get_all(); - } - - /** - * Return the theme's supported features. - * Used for syncing the supported feature that we care about. - * - * @return array List of features that the theme supports. - */ - public static function get_theme_support() { - global $_wp_theme_features; - - $theme_support = array(); - foreach ( Defaults::$default_theme_support_whitelist as $theme_feature ) { - $has_support = current_theme_supports( $theme_feature ); - if ( $has_support ) { - $theme_support[ $theme_feature ] = $_wp_theme_features[ $theme_feature ]; - } - } - - return $theme_support; - } - - /** - * Returns if the current theme is a Full Site Editing theme. - * - * @since 1.49.0 Uses wp_is_block_theme() instead of deprecated gutenberg_is_fse_theme(). - * - * @return bool Theme is a Full Site Editing theme. - */ - public static function get_is_fse_theme() { - return wp_is_block_theme(); - } - - /** - * Wraps data in a way so that we can distinguish between objects and array and also prevent object recursion. - * - * @since 1.21.0 - * - * @param mixed $any Source data to be cleaned up. - * @param array $seen_nodes Built array of nodes. - * - * @return array - */ - public static function json_wrap( &$any, $seen_nodes = array() ) { - if ( is_object( $any ) ) { - $input = get_object_vars( $any ); - $input['__o'] = 1; - } else { - $input = &$any; - } - - if ( is_array( $input ) ) { - $seen_nodes[] = &$any; - - $return = array(); - - foreach ( $input as $k => &$v ) { - if ( ( is_array( $v ) || is_object( $v ) ) ) { - if ( in_array( $v, $seen_nodes, true ) ) { - continue; - } - $return[ $k ] = self::json_wrap( $v, $seen_nodes ); - } else { - $return[ $k ] = $v; - } - } - - return $return; - } - - return $any; - } - - /** - * Return the list of installed themes - * - * @since 1.31.0 - * - * @return array - */ - public static function get_themes() { - $current_stylesheet = get_stylesheet(); - $installed_themes = wp_get_themes(); - $synced_headers = array( 'Name', 'ThemeURI', 'Author', 'Version', 'Template', 'Status', 'TextDomain', 'RequiresWP', 'RequiresPHP' ); - $themes = array(); - foreach ( $installed_themes as $stylesheet => $theme ) { - $themes[ $stylesheet ] = array(); - foreach ( $synced_headers as $header ) { - $themes[ $stylesheet ][ $header ] = $theme->get( $header ); - } - $themes[ $stylesheet ]['active'] = $stylesheet === $current_stylesheet; - if ( method_exists( $theme, 'is_block_theme' ) ) { - $themes[ $stylesheet ]['is_block_theme'] = $theme->is_block_theme(); - } - } - /** - * Filters the output of Sync's get_theme callable - * - * @since 1.31.0 - * - * @param array $themes The list of installed themes formatted in an array with a collection of information extracted from the Theme's headers - */ - return apply_filters( 'jetpack_sync_get_themes_callable', $themes ); - } - - /** - * Return the list of active Jetpack modules. - * - * @since 1.34.0 - * - * @return array - */ - public static function get_active_modules() { - return ( new Jetpack_Modules() )->get_active(); - } - - /** - * Return a list of PHP modules that we want to track. - * - * @since 1.50.0 - * - * @return array - */ - public static function get_loaded_extensions() { - if ( function_exists( 'get_loaded_extensions' ) ) { - return get_loaded_extensions(); - } - - // If a hosting provider has blocked get_loaded_extensions for any reason, - // we check extensions manually. - - $extensions_to_check = array( - 'libxml' => array( 'class' => 'libXMLError' ), - 'xml' => array( 'function' => 'xml_parse' ), - 'dom' => array( 'class' => 'DOMDocument' ), - 'xdebug' => array( 'function' => 'xdebug_break' ), - ); - - $enabled_extensions = array(); - foreach ( $extensions_to_check as $extension_name => $extension ) { - if ( - ( isset( $extension['function'] ) - && function_exists( $extension['function'] ) ) - || class_exists( $extension['class'] ) - ) { - $enabled_extensions[] = $extension_name; - } - } - - return $enabled_extensions; - } - - /** - * Return the list of active connected Jetpack plugins. - * - * @since 3.2.0 - * - * @return array - */ - public static function get_jetpack_connection_active_plugins() { - return ( new Manager() )->get_connected_plugins(); - } - - /** - * Return the list of active sync modules. - * - * @since 3.6.0 - * - * @return array - */ - public static function get_jetpack_sync_active_modules() { - - /** This filter is documented in projects/packages/sync/src/class-modules.php */ - $modules = apply_filters( 'jetpack_sync_modules', Modules::DEFAULT_SYNC_MODULES ); - $modules = array_unique( $modules ); - $modules = array_map( 'wp_normalize_path', $modules ); - return $modules; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-health.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-health.php deleted file mode 100644 index 41d7f788..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-health.php +++ /dev/null @@ -1,188 +0,0 @@ - self::STATUS_UNKNOWN, - self::OPTION_TIMESTAMP_KEY => microtime( true ), - ); - - switch ( $status ) { - case self::STATUS_DISABLED: - case self::STATUS_OUT_OF_SYNC: - case self::STATUS_IN_SYNC: - $new_status[ self::OPTION_STATUS_KEY ] = $status; - break; - } - - \Jetpack_Options::update_option( self::STATUS_OPTION, $new_status ); - return true; - } - - /** - * Check if Status has been previously set. - * - * @return bool is a Status defined - */ - public static function is_status_defined() { - $status = \Jetpack_Options::get_option( self::STATUS_OPTION ); - - if ( false === $status || ! is_array( $status ) || empty( $status[ self::OPTION_STATUS_KEY ] ) ) { - return false; - } else { - return true; - } - } - - /** - * Update Sync Status if Full Sync ended of Posts - * - * @param string $checksum The checksum that's currently being processed. - * @param array $range The ranges of object types being processed. - */ - public static function full_sync_end_update_status( $checksum, $range ) { - if ( isset( $range['posts'] ) ) { - self::update_status( self::STATUS_IN_SYNC ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php deleted file mode 100644 index a2f443af..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php +++ /dev/null @@ -1,96 +0,0 @@ -json_serialize( $object ) ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode - } - - /** - * Decode compressed serialized value. - * - * @param string $input Item to decode. - * @return array|mixed|object - */ - public function decode( $input ) { - $decoded = base64_decode( $input ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - $inflated = @gzinflate( $decoded ); // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged - - return is_string( $inflated ) ? $this->json_unserialize( $inflated ) : null; - } - - /** - * Serialize JSON - * - * @see https://gist.github.com/muhqu/820694 - * - * @param mixed $any Value to serialize and wrap. - * - * @return false|string - */ - protected function json_serialize( $any ) { - return wp_json_encode( Functions::json_wrap( $any ) ); - } - - /** - * Unserialize JSON - * - * @param string $str JSON string. - * @return array|object Unwrapped JSON. - */ - protected function json_unserialize( $str ) { - return $this->json_unwrap( json_decode( $str, true ) ); - } - - /** - * Unwraps a json_decode return. - * - * @param array|object $any json_decode object. - * @return array|object - */ - private function json_unwrap( $any ) { - if ( is_array( $any ) ) { - foreach ( $any as $k => $v ) { - if ( '__o' === $k ) { - continue; - } - $any[ $k ] = $this->json_unwrap( $v ); - } - - if ( isset( $any['__o'] ) ) { - unset( $any['__o'] ); - $any = (object) $any; - } - } - - return $any; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php deleted file mode 100644 index c2789c17..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php +++ /dev/null @@ -1,485 +0,0 @@ -:( - */ - protected function __construct() { - $this->set_defaults(); - $this->init(); - } - - /** - * Sync Listener init. - */ - private function init() { - $handler = array( $this, 'action_handler' ); - $full_sync_handler = array( $this, 'full_sync_action_handler' ); - - foreach ( Modules::get_modules() as $module ) { - $module->init_listeners( $handler ); - $module->init_full_sync_listeners( $full_sync_handler ); - } - - // Module Activation. - add_action( 'jetpack_activate_module', $handler ); - add_action( 'jetpack_deactivate_module', $handler ); - - // Jetpack Upgrade. - add_action( 'updating_jetpack_version', $handler, 10, 2 ); - - // Send periodic checksum. - add_action( 'jetpack_sync_checksum', $handler ); - } - - /** - * Get incremental sync queue. - */ - public function get_sync_queue() { - return $this->sync_queue; - } - - /** - * Gets the full sync queue. - */ - public function get_full_sync_queue() { - return $this->full_sync_queue; - } - - /** - * Sets queue size limit. - * - * @param int $limit Queue size limit. - */ - public function set_queue_size_limit( $limit ) { - $this->sync_queue_size_limit = $limit; - } - - /** - * Get queue size limit. - */ - public function get_queue_size_limit() { - return $this->sync_queue_size_limit; - } - - /** - * Sets the queue lag limit. - * - * @param int $age Queue lag limit. - */ - public function set_queue_lag_limit( $age ) { - $this->sync_queue_lag_limit = $age; - } - - /** - * Return value of queue lag limit. - */ - public function get_queue_lag_limit() { - return $this->sync_queue_lag_limit; - } - - /** - * Force a recheck of the queue limit. - */ - public function force_recheck_queue_limit() { - delete_transient( self::QUEUE_STATE_CHECK_TRANSIENT . '_' . $this->sync_queue->id ); - delete_transient( self::QUEUE_STATE_CHECK_TRANSIENT . '_' . $this->full_sync_queue->id ); - } - - /** - * Determine if an item can be added to the queue. - * - * Prevent adding items to the queue if it hasn't sent an item for 15 mins - * AND the queue is over 1000 items long (by default). - * - * @param object $queue Sync queue. - * @return bool - */ - public function can_add_to_queue( $queue ) { - if ( ! Settings::is_sync_enabled() ) { - return false; - } - - $state_transient_name = self::QUEUE_STATE_CHECK_TRANSIENT . '_' . $queue->id; - - $queue_state = get_transient( $state_transient_name ); - - if ( false === $queue_state ) { - $queue_state = array( $queue->size(), $queue->lag() ); - set_transient( $state_transient_name, $queue_state, self::QUEUE_STATE_CHECK_TIMEOUT ); - } - - list( $queue_size, $queue_age ) = $queue_state; - - return ( $queue_age < $this->sync_queue_lag_limit ) - || - ( ( $queue_size + 1 ) < $this->sync_queue_size_limit ); - } - - /** - * Full sync action handler. - * - * @param mixed ...$args Args passed to the action. - */ - public function full_sync_action_handler( ...$args ) { - $this->enqueue_action( current_filter(), $args, $this->full_sync_queue ); - } - - /** - * Action handler. - * - * @param mixed ...$args Args passed to the action. - */ - public function action_handler( ...$args ) { - $this->enqueue_action( current_filter(), $args, $this->sync_queue ); - } - - // add many actions to the queue directly, without invoking them. - - /** - * Bulk add action to the queue. - * - * @param string $action_name The name the full sync action. - * @param array $args_array Array of chunked arguments. - */ - public function bulk_enqueue_full_sync_actions( $action_name, $args_array ) { - $queue = $this->get_full_sync_queue(); - - /* - * If we add any items to the queue, we should try to ensure that our script - * can't be killed before they are sent. - */ - // https://plugins.trac.wordpress.org/ticket/2041 - if ( function_exists( 'ignore_user_abort' ) ) { - ignore_user_abort( true ); - } - - $data_to_enqueue = array(); - $user_id = get_current_user_id(); - $currtime = microtime( true ); - $is_importing = Settings::is_importing(); - - foreach ( $args_array as $args ) { - $previous_end = isset( $args['previous_end'] ) ? $args['previous_end'] : null; - $args = isset( $args['ids'] ) ? $args['ids'] : $args; - - /** - * Modify or reject the data within an action before it is enqueued locally. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @module sync - * - * @param array The action parameters - */ - $args = apply_filters( "jetpack_sync_before_enqueue_$action_name", $args ); - $action_data = array( $args ); - if ( $previous_end !== null ) { - $action_data[] = $previous_end; - } - // allow listeners to abort. - if ( false === $args ) { - continue; - } - - $data_to_enqueue[] = array( - $action_name, - $action_data, - $user_id, - $currtime, - $is_importing, - ); - } - - $queue->add_all( $data_to_enqueue ); - } - - /** - * Enqueue the action. - * - * @param string $current_filter Current WordPress filter. - * @param object $args Sync args. - * @param string $queue Sync queue. - */ - public function enqueue_action( $current_filter, $args, $queue ) { - // don't enqueue an action during the outbound http request - this prevents recursion. - if ( Settings::is_sending() ) { - return; - } - - if ( ! ( new Connection_Manager() )->is_connected() ) { - // Don't enqueue an action if the site is disconnected. - return; - } - - /** - * Add an action hook to execute when anything on the whitelist gets sent to the queue to sync. - * - * @module sync - * - * @since 1.6.3 - * @since-jetpack 5.9.0 - */ - do_action( 'jetpack_sync_action_before_enqueue' ); - - /** - * Modify or reject the data within an action before it is enqueued locally. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param array The action parameters - */ - $args = apply_filters( "jetpack_sync_before_enqueue_$current_filter", $args ); - - // allow listeners to abort. - if ( false === $args ) { - return; - } - - /* - * Periodically check the size of the queue, and disable adding to it if - * it exceeds some limit AND the oldest item exceeds the age limit (i.e. sending has stopped). - */ - if ( ! $this->can_add_to_queue( $queue ) ) { - if ( 'sync' === $queue->id ) { - $this->sync_data_loss( $queue ); - } - return; - } - - /* - * If we add any items to the queue, we should try to ensure that our script - * can't be killed before they are sent. - */ - // https://plugins.trac.wordpress.org/ticket/2041 - if ( function_exists( 'ignore_user_abort' ) ) { - ignore_user_abort( true ); - } - - if ( - 'sync' === $queue->id || - in_array( - $current_filter, - array( - 'jetpack_full_sync_start', - 'jetpack_full_sync_end', - 'jetpack_full_sync_cancel', - ), - true - ) - ) { - $queue->add( - array( - $current_filter, - $args, - get_current_user_id(), - microtime( true ), - Settings::is_importing(), - $this->get_actor( $current_filter, $args ), - ) - ); - } else { - $queue->add( - array( - $current_filter, - $args, - get_current_user_id(), - microtime( true ), - Settings::is_importing(), - ) - ); - } - - // since we've added some items, let's try to load the sender so we can send them as quickly as possible. - if ( ! Actions::$sender ) { - add_filter( 'jetpack_sync_sender_should_load', __NAMESPACE__ . '\Actions::should_initialize_sender_enqueue', 10, 1 ); - if ( did_action( 'init' ) ) { - Actions::add_sender_shutdown(); - } - } - } - - /** - * Sync Data Loss Handler - * - * @param Queue $queue Sync queue. - * @return boolean was send successful - */ - public function sync_data_loss( $queue ) { - if ( ! Settings::is_sync_enabled() ) { - return; - } - $updated = Health::update_status( Health::STATUS_OUT_OF_SYNC ); - - if ( ! $updated ) { - return; - } - - $data = array( - 'timestamp' => microtime( true ), - 'queue_size' => $queue->size(), - 'queue_lag' => $queue->lag(), - ); - - $sender = Sender::get_instance(); - return $sender->send_action( 'jetpack_sync_data_loss', $data ); - } - - /** - * Get the event's actor. - * - * @param string $current_filter Current wp-admin page. - * @param object $args Sync event. - * @return array Actor information. - */ - public function get_actor( $current_filter, $args ) { - if ( 'wp_login' === $current_filter ) { - $user = get_user_by( 'ID', $args[1]->data->ID ); - } else { - $user = wp_get_current_user(); - } - - $roles = new Roles(); - $translated_role = $roles->translate_user_to_role( $user ); - - $actor = array( - 'wpcom_user_id' => null, - 'external_user_id' => isset( $user->ID ) ? $user->ID : null, - 'display_name' => isset( $user->display_name ) ? $user->display_name : null, - 'user_email' => isset( $user->user_email ) ? $user->user_email : null, - 'user_roles' => isset( $user->roles ) ? $user->roles : null, - 'translated_role' => $translated_role ? $translated_role : null, - 'is_cron' => defined( 'DOING_CRON' ) ? DOING_CRON : false, - 'is_rest' => defined( 'REST_API_REQUEST' ) ? REST_API_REQUEST : false, - 'is_xmlrpc' => defined( 'XMLRPC_REQUEST' ) ? XMLRPC_REQUEST : false, - 'is_wp_rest' => defined( 'REST_REQUEST' ) ? REST_REQUEST : false, - 'is_ajax' => defined( 'DOING_AJAX' ) ? DOING_AJAX : false, - 'is_wp_admin' => is_admin(), - 'is_cli' => defined( 'WP_CLI' ) ? WP_CLI : false, - 'from_url' => $this->get_request_url(), - ); - - if ( $this->should_send_user_data_with_actor( $current_filter ) ) { - $ip = IP_Utils::get_ip(); - - $actor['ip'] = $ip ? $ip : ''; - $actor['user_agent'] = isset( $_SERVER['HTTP_USER_AGENT'] ) ? filter_var( wp_unslash( $_SERVER['HTTP_USER_AGENT'] ) ) : 'unknown'; - } - - return $actor; - } - - /** - * Should user data be sent as the actor? - * - * @param string $current_filter The current WordPress filter being executed. - * @return bool - */ - public function should_send_user_data_with_actor( $current_filter ) { - $should_send = in_array( $current_filter, array( 'jetpack_wp_login', 'wp_logout', 'jetpack_valid_failed_login_attempt' ), true ); - /** - * Allow or deny sending actor's user data ( IP and UA ) during a sync event - * - * @since 1.6.3 - * @since-jetpack 5.8.0 - * - * @module sync - * - * @param bool True if we should send user data - * @param string The current filter that is performing the sync action - */ - return apply_filters( 'jetpack_sync_actor_user_data', $should_send, $current_filter ); - } - - /** - * Sets Listener defaults. - */ - public function set_defaults() { - $this->sync_queue = new Queue( 'sync' ); - $this->full_sync_queue = new Queue( 'full_sync' ); - $this->set_queue_size_limit( Settings::get_setting( 'max_queue_size' ) ); - $this->set_queue_lag_limit( Settings::get_setting( 'max_queue_lag' ) ); - } - - /** - * Get the request URL. - * - * @return string Request URL, if known. Otherwise, wp-admin or home_url. - */ - public function get_request_url() { - if ( isset( $_SERVER['HTTP_HOST'] ) && isset( $_SERVER['REQUEST_URI'] ) ) { - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- False positive, sniff misses the call to esc_url_raw. - return esc_url_raw( 'http' . ( isset( $_SERVER['HTTPS'] ) ? 's' : '' ) . '://' . wp_unslash( "{$_SERVER['HTTP_HOST']}{$_SERVER['REQUEST_URI']}" ) ); - } - return is_admin() ? get_admin_url( get_current_blog_id() ) : home_url(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php deleted file mode 100644 index 61b89a1c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php +++ /dev/null @@ -1,77 +0,0 @@ - $locked_time ) { - update_option( $lock_name, false, false ); - } - return false; - } - - $locked_time = microtime( true ) + $expiry; - update_option( $lock_name, $locked_time, false ); - return $locked_time; - } - - /** - * Remove the lock. - * - * @access public - * - * @param string $name lock name. - * @param bool|float $lock_expiration lock expiration. - */ - public function remove( $name, $lock_expiration = false ) { - $lock_name = self::LOCK_PREFIX . $name; - - // Only remove lock if current value matches our lock. - if ( true === $lock_expiration || (string) get_option( $lock_name ) === (string) $lock_expiration ) { - update_option( $lock_name, false, false ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-main.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-main.php deleted file mode 100644 index e2083b72..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-main.php +++ /dev/null @@ -1,159 +0,0 @@ -uninstall(); - } - - /** - * Sync cleanup on shutdown. - */ - public static function on_jetpack_site_disconnected() { - add_action( 'shutdown', array( __CLASS__, 'sync_cleanup' ), 10000 ); - } - - /** - * Delete all sync related data on Site disconnect / clean up custom table. - * Needs to happen on shutdown to prevent fatals. - */ - public static function sync_cleanup() { - Sender::get_instance()->uninstall(); - - $table_storage = new Queue_Storage_Table( 'test_queue' ); - $table_storage->drop_table(); - } - - /** - * Sets the Sync data settings. - * - * @param array $data_settings An array containing the Sync data options. An empty array indicates that the default - * values will be used for all Sync data. - */ - public static function set_sync_data_options( $data_settings = array() ) { - ( new Data_Settings() )->add_settings_list( $data_settings ); - } - - /** - * Initialize the main sync actions. - * - * @action plugins_loaded - */ - public static function on_plugins_loaded_early() { - /** - * Additional Sync modules can be carried out into their own packages and they - * will get their own config settings. - * - * For now additional modules are enabled based on whether the third party plugin - * class exists or not. - */ - Sync_Actions::initialize_search(); - Sync_Actions::initialize_woocommerce(); - Sync_Actions::initialize_wp_super_cache(); - - // We need to define this here so that it's hooked before `updating_jetpack_version` is called. - add_action( 'updating_jetpack_version', array( 'Automattic\\Jetpack\\Sync\\Actions', 'cleanup_on_upgrade' ), 10, 2 ); - } - - /** - * Runs after most of plugins_loaded hook functions have been run. - * - * @action plugins_loaded - */ - public static function on_plugins_loaded_late() { - /* - * Init after plugins loaded and before the `init` action. This helps with issues where plugins init - * with a high priority or sites that use alternate cron. - */ - Sync_Actions::init(); - - // Enable non-blocking Jetpack Sync flow. - $non_block_enabled = (bool) get_option( 'jetpack_sync_non_blocking', false ); - - /** - * Filters the option to enable non-blocking sync. - * - * Default value is false, filter to true to enable non-blocking mode which will have - * WP.com return early and use the sync/close endpoint to check-in processed items. - * - * @since 1.12.3 - * - * @param bool $enabled Should non-blocking flow be enabled. - */ - $filtered = (bool) apply_filters( 'jetpack_sync_non_blocking', $non_block_enabled ); - - if ( $non_block_enabled !== $filtered ) { - update_option( 'jetpack_sync_non_blocking', $filtered, false ); - } - - // Initialize health-related hooks after plugins have loaded. - Health::init(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php deleted file mode 100644 index 4f2481f4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php +++ /dev/null @@ -1,165 +0,0 @@ -set_defaults(); - } - } - - /** - * Gets the name of an initialized module. Returns false if given module has not been initialized. - * - * @access public - * @static - * - * @param string $module_name A module name. - * - * @return bool|\Automattic\Jetpack\Sync\Modules\Module - */ - public static function get_module( $module_name ) { - // @todo Better type hinting for Phan if https://github.com/phan/phan/issues/3842 gets fixed. Then clean up the `@phan-var` on all the callers. - - foreach ( self::get_modules() as $module ) { - if ( $module->name() === $module_name ) { - return $module; - } - } - - return false; - } - - /** - * Loads and sets defaults for all declared modules. - * - * @access public - * @static - * - * @return array - */ - public static function initialize_modules() { - - /** - * Filters the list of class names of sync modules. - * If you add to this list, make sure any classes implement the - * Jetpack_Sync_Module interface. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - $modules = apply_filters( 'jetpack_sync_modules', self::DEFAULT_SYNC_MODULES ); - - $modules = array_unique( $modules ); - - $modules = array_map( array( __CLASS__, 'load_module' ), $modules ); - return array_map( array( __CLASS__, 'set_module_defaults' ), $modules ); - } - - /** - * Returns an instance of the given module class. - * - * @access public - * @static - * - * @param string $module_class The classname of a Jetpack sync module. - * - * @return \Automattic\Jetpack\Sync\Modules\Module - */ - public static function load_module( $module_class ) { - return new $module_class(); - } - - /** - * Sets defaults for the given instance of a Jetpack sync module. - * - * @access public - * @static - * - * @param \Automattic\Jetpack\Sync\Modules\Module $module Instance of a Jetpack sync module. - * - * @return \Automattic\Jetpack\Sync\Modules\Module - */ - public static function set_module_defaults( $module ) { - $module->set_defaults(); - if ( method_exists( $module, 'set_late_default' ) ) { - // @phan-suppress-next-line PhanUndeclaredMethodInCallable -- https://github.com/phan/phan/issues/1204 - add_action( 'init', array( $module, 'set_late_default' ), 90 ); - } - return $module; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php deleted file mode 100644 index 5daeb111..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php +++ /dev/null @@ -1,30 +0,0 @@ -id = $id; - $this->items_with_ids = $items_with_ids; - } - - /** - * Retrieve the sync items in the buffer, in an ID => value form. - * - * @access public - * - * @return bool|array Sync items in the buffer. - */ - public function get_items() { - return array_combine( $this->get_item_ids(), $this->get_item_values() ); - } - - /** - * Retrieve the values of the sync items in the buffer. - * - * @access public - * - * @return array Sync items values. - */ - public function get_item_values() { - return Utils::get_item_values( $this->items_with_ids ); - } - - /** - * Retrieve the IDs of the sync items in the buffer. - * - * @access public - * - * @return array Sync items IDs. - */ - public function get_item_ids() { - return Utils::get_item_ids( $this->items_with_ids ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php deleted file mode 100644 index 094e72d1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php +++ /dev/null @@ -1,678 +0,0 @@ -id = str_replace( '-', '_', $id ); // Necessary to ensure we don't have ID collisions in the SQL. - $this->row_iterator = 0; - $this->random_int = wp_rand( 1, 1000000 ); - - /** - * If the Custom queue table is enabled - let's use it as a backend. Otherwise, fall back to the Options table. - */ - if ( Settings::is_custom_queue_table_enabled() ) { - $this->queue_storage = new Queue_Storage_Table( $this->id ); - } else { - // Initialize the storage with the Options table backend. To be changed in subsequent updates to include the logic to switch to Custom Table. - $this->queue_storage = new Queue_Storage_Options( $this->id ); - } - } - - /** - * Add a single item to the queue. - * - * @param object $item Event object to add to queue. - * - * @return bool|WP_Error - */ - public function add( $item ) { - $added = false; - - // If empty, don't add. - if ( empty( $item ) ) { - return false; - } - - // Attempt to serialize data, if an exception (closures) return early. - try { - $item = serialize( $item ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - } catch ( \Exception $ex ) { - return new WP_Error( 'queue_unable_to_serialize', 'Unable to serialize item' ); - } - - // This basically tries to add the option until enough time has elapsed that - // it has a unique (microtime-based) option key. - while ( ! $added ) { - $added = $this->queue_storage->insert_item( $this->get_next_data_row_option_name(), $item ); - } - - return $added; - } - - /** - * Insert all the items in a single SQL query. May be subject to query size limits! - * - * @param array $items Array of events to add to the queue. - * - * @return bool|\WP_Error - */ - public function add_all( $items ) { - // TODO check and figure out if it's used at all and if we can optimize it. - $base_option_name = $this->get_next_data_row_option_name(); - - $rows_added = $this->queue_storage->add_all( $items, $base_option_name ); - - if ( count( $items ) !== $rows_added ) { - return new WP_Error( 'row_count_mismatch', "The number of rows inserted didn't match the size of the input array" ); - } - - return true; - } - - /** - * Get the front-most item on the queue without checking it out. - * - * @param int $count Number of items to return when looking at the items. - * - * @return array - */ - public function peek( $count = 1 ) { - $items = $this->fetch_items( $count ); - if ( $items ) { - return Utils::get_item_values( $items ); - } - - return array(); - } - - /** - * Gets items with particular IDs. - * - * @param array $item_ids Array of item IDs to retrieve. - * - * @return array - */ - public function peek_by_id( $item_ids ) { - $items = $this->fetch_items_by_id( $item_ids ); - if ( $items ) { - return Utils::get_item_values( $items ); - } - - return array(); - } - - /** - * Gets the queue lag. - * Lag is the difference in time between the age of the oldest item - * (aka first or frontmost item) and the current time. - * - * @param float $now The current time in microtime. - * - * @return float - */ - public function lag( $now = null ) { - return (float) $this->queue_storage->get_lag( $now ); - } - - /** - * Resets the queue. - */ - public function reset() { - $this->delete_checkout_id(); - - $this->queue_storage->clear_queue(); - } - - /** - * Return the size of the queue. - * - * @return int - */ - public function size() { - return $this->queue_storage->get_item_count(); - } - - /** - * Lets you know if there is any items in the queue. - * - * We use this peculiar implementation because it's much faster than count(*). - * - * @return bool - */ - public function has_any_items() { - return $this->size() > 0; - } - - /** - * Used to checkout the queue. - * - * @param int $buffer_size Size of the buffer to checkout. - * - * @return \Automattic\Jetpack\Sync\Queue_Buffer|bool|int|\WP_Error - */ - public function checkout( $buffer_size ) { - if ( $this->get_checkout_id() ) { - return new WP_Error( 'unclosed_buffer', 'There is an unclosed buffer' ); - } - - // TODO check if adding a prefix is going to be a problem - $buffer_id = uniqid( '', true ); - - $result = $this->set_checkout_id( $buffer_id ); - - if ( ! $result || is_wp_error( $result ) ) { - return $result; - } - - $items = $this->fetch_items( $buffer_size ); - - if ( ! is_countable( $items ) ) { - return false; - } - - if ( count( $items ) === 0 ) { - return false; - } - - return new Queue_Buffer( $buffer_id, array_slice( $items, 0, $buffer_size ) ); - } - - /** - * Given a list of items return the items ids. - * - * @param array $items List of item objects. - * - * @return array Ids of the items. - */ - public function get_ids( $items ) { - return array_map( - function ( $item ) { - return $item->id; - }, - $items - ); - } - - /** - * Pop elements from the queue. - * - * @param int $limit Number of items to pop from the queue. - * - * @return array|object|null - */ - public function pop( $limit ) { - $items = $this->fetch_items( $limit ); - - $ids = $this->get_ids( $items ); - - $this->delete( $ids ); - - return $items; - } - - /** - * Get the items from the queue with a memory limit. - * - * This checks out rows until it either empties the queue or hits a certain memory limit - * it loads the sizes from the DB first so that it doesn't accidentally - * load more data into memory than it needs to. - * The only way it will load more items than $max_size is if a single queue item - * exceeds the memory limit, but in that case it will send that item by itself. - * - * @param int $max_memory (bytes) Maximum memory threshold. - * @param int $max_buffer_size Maximum buffer size (number of items). - * - * @return \Automattic\Jetpack\Sync\Queue_Buffer|bool|int|\WP_Error - */ - public function checkout_with_memory_limit( $max_memory, $max_buffer_size = 500 ) { - if ( $this->get_checkout_id() ) { - return new WP_Error( 'unclosed_buffer', 'There is an unclosed buffer' ); - } - - $buffer_id = uniqid( '', true ); - - $result = $this->set_checkout_id( $buffer_id ); - - if ( ! $result || is_wp_error( $result ) ) { - return $result; - } - - // How much memory is currently being used by the items. - $total_memory = 0; - - // Store the items to return - $items = array(); - - $current_items_ids = $this->queue_storage->get_items_ids_with_size( $max_buffer_size - count( $items ) ); - - // If no valid items are returned or no items are returned, continue. - if ( ! is_countable( $current_items_ids ) || count( $current_items_ids ) === 0 ) { - return false; - } - - $item_ids_to_fetch = array(); - - foreach ( $current_items_ids as $id => $item_with_size ) { - $total_memory += $item_with_size->value_size; - - // If this is the first item and it exceeds memory, allow loop to continue - // we will exit on the next iteration instead. - if ( $total_memory > $max_memory && $id > 0 ) { - break; - } - - $item_ids_to_fetch[] = $item_with_size->id; - } - - $current_items = $this->queue_storage->fetch_items_by_ids( $item_ids_to_fetch ); - - $items_count = is_countable( $current_items ) ? count( $current_items ) : 0; - - if ( $items_count > 0 ) { - /** - * Save some memory by moving things one by one to the array of items being returned, instead of - * unserializing all and then merging them with other items. - * - * PHPCS ignore is because this is the expected behavior - we're assigning a variable in the condition part of the loop. - */ - // phpcs:ignore Generic.CodeAnalysis.AssignmentInCondition.FoundInWhileCondition - while ( ( $current_item = array_shift( $current_items ) ) !== null ) { - // @codingStandardsIgnoreStart - $current_item->value = unserialize( $current_item->value ); - // @codingStandardsIgnoreEnd - - $items[] = $current_item; - } - } - - if ( count( $items ) === 0 ) { - $this->delete_checkout_id(); - - return false; - } - - return new Queue_Buffer( $buffer_id, $items ); - } - - /** - * Check in the queue. - * - * @param \Automattic\Jetpack\Sync\Queue_Buffer $buffer Queue_Buffer object. - * - * @return bool|\WP_Error - */ - public function checkin( $buffer ) { - $is_valid = $this->validate_checkout( $buffer ); - - if ( is_wp_error( $is_valid ) ) { - return $is_valid; - } - - $this->delete_checkout_id(); - - return true; - } - - /** - * Close the buffer. - * - * @param \Automattic\Jetpack\Sync\Queue_Buffer $buffer Queue_Buffer object. - * @param null|array $ids_to_remove Ids to remove from the queue. - * - * @return bool|\WP_Error - */ - public function close( $buffer, $ids_to_remove = null ) { - $is_valid = $this->validate_checkout( $buffer ); - - if ( is_wp_error( $is_valid ) ) { - // Always delete ids_to_remove even when buffer is no longer checked-out. - // They were processed by WP.com so safe to remove from queue. - if ( $ids_to_remove !== null ) { - $this->delete( $ids_to_remove ); - } - return $is_valid; - } - - $this->delete_checkout_id(); - - // By default clear all items in the buffer. - if ( $ids_to_remove === null ) { - $ids_to_remove = $buffer->get_item_ids(); - } - - $this->delete( $ids_to_remove ); - - return true; - } - - /** - * Delete elements from the queue. - * - * @param array $ids Ids to delete. - * - * @return bool|int - */ - private function delete( $ids ) { - if ( array() === $ids ) { - return 0; - } - - $this->queue_storage->delete_items_by_ids( $ids ); - - return true; - } - - /** - * Flushes all items from the queue. - * - * @return array - */ - public function flush_all() { - $items = Utils::get_item_values( $this->fetch_items() ); - $this->reset(); - - return $items; - } - - /** - * Get all the items from the queue. - * - * @return array|object|null - */ - public function get_all() { - return $this->fetch_items(); - } - - /** - * Forces Checkin of the queue. - * Use with caution, this could allow multiple processes to delete - * and send from the queue at the same time - */ - public function force_checkin() { - $this->delete_checkout_id(); - } - - /** - * Checks if the queue is locked. - * - * @return bool - */ - public function is_locked() { - return (bool) $this->get_checkout_id(); - } - - /** - * Locks checkouts from the queue - * tries to wait up to $timeout seconds for the queue to be empty. - * - * @param int $timeout The wait time in seconds for the queue to be empty. - * - * @return bool|int|\WP_Error - */ - public function lock( $timeout = 30 ) { - $tries = 0; - - while ( $this->has_any_items() && $tries < $timeout ) { - sleep( 1 ); - ++$tries; - } - - if ( 30 === $tries ) { - return new WP_Error( 'lock_timeout', 'Timeout waiting for sync queue to empty' ); - } - - if ( $this->get_checkout_id() ) { - return new WP_Error( 'unclosed_buffer', 'There is an unclosed buffer' ); - } - - // Hopefully this means we can acquire a checkout? - $result = $this->set_checkout_id( 'lock' ); - - if ( ! $result || is_wp_error( $result ) ) { - return $result; - } - - return true; - } - - /** - * Unlocks the queue. - * - * @return bool|int - */ - public function unlock() { - return $this->delete_checkout_id(); - } - - /** - * This option is specifically chosen to, as much as possible, preserve time order - * and minimise the possibility of collisions between multiple processes working - * at the same time. - * - * @return string - */ - protected function generate_option_name_timestamp() { - return sprintf( '%.6f', microtime( true ) ); - } - - /** - * Gets the checkout ID. - * - * @return bool|string - */ - private function get_checkout_id() { - global $wpdb; - $checkout_value = $wpdb->get_var( - $wpdb->prepare( - "SELECT option_value FROM $wpdb->options WHERE option_name = %s", - $this->get_lock_option_name() - ) - ); - - if ( $checkout_value ) { - list( $checkout_id, $timestamp ) = explode( ':', $checkout_value ); - if ( (int) $timestamp > time() ) { - return $checkout_id; - } - } - - return false; - } - - /** - * Sets the checkout id. - * - * @param string $checkout_id The ID of the checkout. - * - * @return bool|int - */ - private function set_checkout_id( $checkout_id ) { - global $wpdb; - - $expires = time() + Defaults::$default_sync_queue_lock_timeout; - $updated_num = $wpdb->query( - $wpdb->prepare( - "UPDATE $wpdb->options SET option_value = %s WHERE option_name = %s", - "$checkout_id:$expires", - $this->get_lock_option_name() - ) - ); - - if ( ! $updated_num ) { - $updated_num = $wpdb->query( - $wpdb->prepare( - "INSERT INTO $wpdb->options ( option_name, option_value, autoload ) VALUES ( %s, %s, 'no' )", - $this->get_lock_option_name(), - "$checkout_id:$expires" - ) - ); - } - - return $updated_num; - } - - /** - * Deletes the checkout ID. - * - * @return bool|int - */ - private function delete_checkout_id() { - global $wpdb; - // Rather than delete, which causes fragmentation, we update in place. - return $wpdb->query( - $wpdb->prepare( - "UPDATE $wpdb->options SET option_value = %s WHERE option_name = %s", - '0:0', - $this->get_lock_option_name() - ) - ); - } - - /** - * Return the lock option name. - * - * @return string - */ - private function get_lock_option_name() { - return "jpsq_{$this->id}_checkout"; - } - - /** - * Return the next data row option name. - * - * @return string - */ - private function get_next_data_row_option_name() { - $timestamp = $this->generate_option_name_timestamp(); - - // Row iterator is used to avoid collisions where we're writing data waaay fast in a single process. - if ( PHP_INT_MAX === $this->row_iterator ) { - $this->row_iterator = 0; - } else { - $this->row_iterator += 1; - } - - return 'jpsq_' . $this->id . '-' . $timestamp . '-' . $this->random_int . '-' . $this->row_iterator; - } - - /** - * Return the items in the queue. - * - * @param null|int $limit Limit to the number of items we fetch at once. - * - * @return array|object|null - */ - private function fetch_items( $limit = null ) { - $items = $this->queue_storage->fetch_items( $limit ); - - return $this->unserialize_values( $items ); - } - - /** - * Return items with specific ids. - * - * @param array $items_ids Array of event ids. - * - * @return array|object|null - */ - private function fetch_items_by_id( $items_ids ) { - return $this->unserialize_values( $this->queue_storage->fetch_items_by_ids( $items_ids ) ); - } - - /** - * Unserialize item values. - * - * @param array $items Events from the Queue to be unserialized. - * - * @return mixed - */ - private function unserialize_values( $items ) { - array_walk( - $items, - function ( $item ) { - // @codingStandardsIgnoreStart - $item->value = @unserialize( $item->value ); - // @codingStandardsIgnoreEnd - } - ); - - return $items; - } - - /** - * Return true if the buffer is still valid or an Error other wise. - * - * @param \Automattic\Jetpack\Sync\Queue_Buffer $buffer The Queue_Buffer. - * - * @return bool|WP_Error - */ - private function validate_checkout( $buffer ) { - if ( ! $buffer instanceof Queue_Buffer ) { - return new WP_Error( 'not_a_buffer', 'You must checkin an instance of Automattic\\Jetpack\\Sync\\Queue_Buffer' ); - } - - $checkout_id = $this->get_checkout_id(); - - if ( ! $checkout_id ) { - return new WP_Error( 'buffer_not_checked_out', 'There are no checked out buffers' ); - } - - // TODO: change to strict comparison. - if ( $checkout_id != $buffer->id ) { // phpcs:ignore Universal.Operators.StrictComparisons.LooseNotEqual - return new WP_Error( 'buffer_mismatch', 'The buffer you checked in was not checked out' ); - } - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php deleted file mode 100644 index dd1aeb7b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php +++ /dev/null @@ -1,1425 +0,0 @@ -query( "DELETE FROM $wpdb->posts" ); - - // Delete comments from cache. - $comment_ids = $wpdb->get_col( "SELECT comment_ID FROM $wpdb->comments" ); - if ( ! empty( $comment_ids ) ) { - clean_comment_cache( $comment_ids ); - } - $wpdb->query( "DELETE FROM $wpdb->comments" ); - - // Also need to delete terms from cache. - $term_ids = $wpdb->get_col( "SELECT term_id FROM $wpdb->terms" ); - foreach ( $term_ids as $term_id ) { - wp_cache_delete( $term_id, 'terms' ); - } - - $wpdb->query( "DELETE FROM $wpdb->terms" ); - - $wpdb->query( "DELETE FROM $wpdb->term_taxonomy" ); - $wpdb->query( "DELETE FROM $wpdb->term_relationships" ); - - // Callables and constants. - $wpdb->query( "DELETE FROM $wpdb->options WHERE option_name LIKE 'jetpack_%'" ); - $wpdb->query( "DELETE FROM $wpdb->postmeta WHERE meta_key NOT LIKE '\_%'" ); - } - - /** - * Ran when full sync has just started. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - */ - public function full_sync_start( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $this->reset(); - } - - /** - * Ran when full sync has just finished. - * - * @access public - * - * @param string $checksum Deprecated since 7.3.0. - */ - public function full_sync_end( $checksum ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // Noop right now. - } - - /** - * Retrieve the number of terms. - * - * @access public - * - * @return int Number of terms. - */ - public function term_count() { - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - return (int) $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->terms" ); - } - - /** - * Retrieve the number of rows in the `term_taxonomy` table. - * - * @access public - * - * @return int Number of terms. - */ - public function term_taxonomy_count() { - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - return (int) $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->term_taxonomy" ); - } - - /** - * Retrieve the number of term relationships. - * - * @access public - * - * @return int Number of rows in the term relationships table. - */ - public function term_relationship_count() { - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - return (int) $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->term_relationships" ); - } - - /** - * Retrieve the number of posts with a particular post status within a certain range. - * - * @access public - * - * @todo Prepare the SQL query before executing it. - * - * @param string $status Post status. - * @param int $min_id Minimum post ID. - * @param int $max_id Maximum post ID. - * @return int Number of posts. - */ - public function post_count( $status = null, $min_id = null, $max_id = null ) { - global $wpdb; - - $where = ''; - - if ( $status ) { - $where = "post_status = '" . esc_sql( $status ) . "'"; - } else { - $where = '1=1'; - } - - if ( ! empty( $min_id ) ) { - $where .= ' AND ID >= ' . (int) $min_id; - } - - if ( ! empty( $max_id ) ) { - $where .= ' AND ID <= ' . (int) $max_id; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - return (int) $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->posts WHERE $where" ); - } - - /** - * Retrieve the posts with a particular post status. - * - * @access public - * - * @todo Implement range and actually use max_id/min_id arguments. - * - * @param string $status Post status. - * @param int $min_id Minimum post ID. - * @param int $max_id Maximum post ID. - * @return array Array of posts. - */ - public function get_posts( $status = null, $min_id = null, $max_id = null ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $args = array( - 'orderby' => 'ID', - 'posts_per_page' => -1, - ); - - if ( $status ) { - $args['post_status'] = $status; - } else { - $args['post_status'] = 'any'; - } - - return get_posts( $args ); - } - - /** - * Retrieve a post object by the post ID. - * - * @access public - * - * @param int $id Post ID. - * @return \WP_Post Post object. - */ - public function get_post( $id ) { - return get_post( $id ); - } - - /** - * Update or insert a post. - * - * @access public - * - * @param \WP_Post $post Post object. - * @param bool $silent Whether to perform a silent action. Not used in this implementation. - */ - public function upsert_post( $post, $silent = false ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - global $wpdb; - - // Reject the post if it's not a \WP_Post. - if ( ! $post instanceof \WP_Post ) { - return; - } - - $post = $post->to_array(); - - // Reject posts without an ID. - if ( ! isset( $post['ID'] ) ) { - return; - } - - $now = current_time( 'mysql' ); - $now_gmt = get_gmt_from_date( $now ); - - $defaults = array( - 'ID' => 0, - 'post_author' => '0', - 'post_content' => '', - 'post_content_filtered' => '', - 'post_title' => '', - 'post_name' => '', - 'post_excerpt' => '', - 'post_status' => 'draft', - 'post_type' => 'post', - 'comment_status' => 'closed', - 'comment_count' => '0', - 'ping_status' => '', - 'post_password' => '', - 'to_ping' => '', - 'pinged' => '', - 'post_parent' => 0, - 'menu_order' => 0, - 'guid' => '', - 'post_date' => $now, - 'post_date_gmt' => $now_gmt, - 'post_modified' => $now, - 'post_modified_gmt' => $now_gmt, - ); - - $post = array_intersect_key( $post, $defaults ); - - $post = sanitize_post( $post, 'db' ); - - unset( $post['filter'] ); - - $exists = $wpdb->get_var( $wpdb->prepare( "SELECT EXISTS( SELECT 1 FROM $wpdb->posts WHERE ID = %d )", $post['ID'] ) ); - - if ( $exists ) { - $wpdb->update( $wpdb->posts, $post, array( 'ID' => $post['ID'] ) ); - } else { - $wpdb->insert( $wpdb->posts, $post ); - } - - clean_post_cache( $post['ID'] ); - } - - /** - * Delete a post by the post ID. - * - * @access public - * - * @param int $post_id Post ID. - */ - public function delete_post( $post_id ) { - wp_delete_post( $post_id, true ); - } - - /** - * Retrieve the checksum for posts within a range. - * - * @access public - * - * @param int $min_id Minimum post ID. - * @param int $max_id Maximum post ID. - * @return int The checksum. - */ - public function posts_checksum( $min_id = null, $max_id = null ) { - return $this->summarize_checksum_histogram( $this->checksum_histogram( 'posts', null, $min_id, $max_id ) ); - } - - /** - * Retrieve the checksum for post meta within a range. - * - * @access public - * - * @param int $min_id Minimum post meta ID. - * @param int $max_id Maximum post meta ID. - * @return int The checksum. - */ - public function post_meta_checksum( $min_id = null, $max_id = null ) { - return $this->summarize_checksum_histogram( $this->checksum_histogram( 'postmeta', null, $min_id, $max_id ) ); - } - - /** - * Retrieve the number of comments with a particular comment status within a certain range. - * - * @access public - * - * @todo Prepare the SQL query before executing it. - * - * @param string $status Comment status. - * @param int $min_id Minimum comment ID. - * @param int $max_id Maximum comment ID. - * @return int Number of comments. - */ - public function comment_count( $status = null, $min_id = null, $max_id = null ) { - global $wpdb; - - $comment_approved = $this->comment_status_to_approval_value( $status ); - - if ( false !== $comment_approved ) { - $where = "comment_approved = '" . esc_sql( $comment_approved ) . "'"; - } else { - $where = '1=1'; - } - - if ( ! empty( $min_id ) ) { - $where .= ' AND comment_ID >= ' . (int) $min_id; - } - - if ( ! empty( $max_id ) ) { - $where .= ' AND comment_ID <= ' . (int) $max_id; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - return (int) $wpdb->get_var( "SELECT COUNT(*) FROM $wpdb->comments WHERE $where" ); - } - - /** - * Translate a comment status to a value of the comment_approved field. - * - * @access protected - * - * @param string $status Comment status. - * @return string|bool New comment_approved value, false if the status doesn't affect it. - */ - protected function comment_status_to_approval_value( $status ) { - switch ( (string) $status ) { - case 'approve': - case '1': - return '1'; - case 'hold': - case '0': - return '0'; - case 'spam': - return 'spam'; - case 'trash': - return 'trash'; - case 'post-trashed': - return 'post-trashed'; - case 'any': - case 'all': - default: - return false; - } - } - - /** - * Retrieve the comments with a particular comment status. - * - * @access public - * - * @todo Implement range and actually use max_id/min_id arguments. - * - * @param string $status Comment status. - * @param int $min_id Minimum comment ID. - * @param int $max_id Maximum comment ID. - * @return array Array of comments. - */ - public function get_comments( $status = null, $min_id = null, $max_id = null ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $args = array( - 'orderby' => 'ID', - 'status' => 'all', - ); - - if ( $status ) { - $args['status'] = $status; - } - - return get_comments( $args ); - } - - /** - * Retrieve a comment object by the comment ID. - * - * @access public - * - * @param int $id Comment ID. - * @return \WP_Comment Comment object. - */ - public function get_comment( $id ) { - return \WP_Comment::get_instance( $id ); - } - - /** - * Update or insert a comment. - * - * @access public - * - * @param \WP_Comment $comment Comment object. - */ - public function upsert_comment( $comment ) { - global $wpdb; - - $comment = $comment->to_array(); - - // Filter by fields on comment table. - $comment_fields_whitelist = array( - 'comment_ID', - 'comment_post_ID', - 'comment_author', - 'comment_author_email', - 'comment_author_url', - 'comment_author_IP', - 'comment_date', - 'comment_date_gmt', - 'comment_content', - 'comment_karma', - 'comment_approved', - 'comment_agent', - 'comment_type', - 'comment_parent', - 'user_id', - ); - - foreach ( $comment as $key => $value ) { - if ( ! in_array( $key, $comment_fields_whitelist, true ) ) { - unset( $comment[ $key ] ); - } - } - - $exists = $wpdb->get_var( - $wpdb->prepare( - "SELECT EXISTS( SELECT 1 FROM $wpdb->comments WHERE comment_ID = %d )", - $comment['comment_ID'] - ) - ); - - if ( $exists ) { - $wpdb->update( $wpdb->comments, $comment, array( 'comment_ID' => $comment['comment_ID'] ) ); - } else { - $wpdb->insert( $wpdb->comments, $comment ); - } - // Remove comment from cache. - clean_comment_cache( $comment['comment_ID'] ); - - wp_update_comment_count( $comment['comment_post_ID'] ); - } - - /** - * Trash a comment by the comment ID. - * - * @access public - * - * @param int $comment_id Comment ID. - */ - public function trash_comment( $comment_id ) { - wp_delete_comment( $comment_id ); - } - - /** - * Delete a comment by the comment ID. - * - * @access public - * - * @param int $comment_id Comment ID. - */ - public function delete_comment( $comment_id ) { - wp_delete_comment( $comment_id, true ); - } - - /** - * Mark a comment by the comment ID as spam. - * - * @access public - * - * @param int $comment_id Comment ID. - */ - public function spam_comment( $comment_id ) { - wp_spam_comment( $comment_id ); - } - - /** - * Trash the comments of a post. - * - * @access public - * - * @param int $post_id Post ID. - * @param array $statuses Post statuses. Not used in this implementation. - */ - public function trashed_post_comments( $post_id, $statuses ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - wp_trash_post_comments( $post_id ); - } - - /** - * Untrash the comments of a post. - * - * @access public - * - * @param int $post_id Post ID. - */ - public function untrashed_post_comments( $post_id ) { - wp_untrash_post_comments( $post_id ); - } - - /** - * Retrieve the checksum for comments within a range. - * - * @access public - * - * @param int $min_id Minimum comment ID. - * @param int $max_id Maximum comment ID. - * @return int The checksum. - */ - public function comments_checksum( $min_id = null, $max_id = null ) { - return $this->summarize_checksum_histogram( $this->checksum_histogram( 'comments', null, $min_id, $max_id ) ); - } - - /** - * Retrieve the checksum for comment meta within a range. - * - * @access public - * - * @param int $min_id Minimum comment meta ID. - * @param int $max_id Maximum comment meta ID. - * @return int The checksum. - */ - public function comment_meta_checksum( $min_id = null, $max_id = null ) { - return $this->summarize_checksum_histogram( $this->checksum_histogram( 'commentmeta', null, $min_id, $max_id ) ); - } - - /** - * Update the value of an option. - * - * @access public - * - * @param string $option Option name. - * @param mixed $value Option value. - * @return bool False if value was not updated and true if value was updated. - */ - public function update_option( $option, $value ) { - return update_option( $option, $value ); - } - - /** - * Retrieve an option value based on an option name. - * - * @access public - * - * @param string $option Name of option to retrieve. - * @param mixed $default Optional. Default value to return if the option does not exist. - * @return mixed Value set for the option. - */ - public function get_option( $option, $default = false ) { - return get_option( $option, $default ); - } - - /** - * Remove an option by name. - * - * @access public - * - * @param string $option Name of option to remove. - * @return bool True, if option is successfully deleted. False on failure. - */ - public function delete_option( $option ) { - return delete_option( $option ); - } - - /** - * Change the info of the current theme. - * - * @access public - * - * @param array $theme_info Theme info array. - */ - public function set_theme_info( $theme_info ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // Noop. - } - - /** - * Whether the current theme supports a certain feature. - * - * @access public - * - * @param string $feature Name of the feature. - */ - public function current_theme_supports( $feature ) { - return current_theme_supports( $feature ); - } - - /** - * Retrieve metadata for the specified object. - * - * @access public - * - * @param string $type Meta type. - * @param int $object_id ID of the object. - * @param string $meta_key Meta key. - * @param bool $single If true, return only the first value of the specified meta_key. - * - * @return mixed Single metadata value, or array of values. - */ - public function get_metadata( $type, $object_id, $meta_key = '', $single = false ) { - return get_metadata( $type, $object_id, $meta_key, $single ); - } - - /** - * Stores remote meta key/values alongside an ID mapping key. - * - * @access public - * - * @todo Refactor to not use interpolated values when preparing the SQL query. - * - * @param string $type Meta type. - * @param int $object_id ID of the object. - * @param string $meta_key Meta key. - * @param mixed $meta_value Meta value. - * @param int $meta_id ID of the meta. - * - * @return bool False if meta table does not exist, true otherwise. - */ - public function upsert_metadata( $type, $object_id, $meta_key, $meta_value, $meta_id ) { - $table = _get_meta_table( $type ); - if ( ! $table ) { - return false; - } - - global $wpdb; - - $exists = $wpdb->get_var( - $wpdb->prepare( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT EXISTS( SELECT 1 FROM $table WHERE meta_id = %d )", - $meta_id - ) - ); - - if ( $exists ) { - $wpdb->update( - $table, - array( - 'meta_key' => $meta_key, - 'meta_value' => maybe_serialize( $meta_value ), - ), - array( 'meta_id' => $meta_id ) - ); - } else { - $object_id_field = $type . '_id'; - $wpdb->insert( - $table, - array( - 'meta_id' => $meta_id, - $object_id_field => $object_id, - 'meta_key' => $meta_key, - 'meta_value' => maybe_serialize( $meta_value ), - ) - ); - } - - wp_cache_delete( $object_id, $type . '_meta' ); - - return true; - } - - /** - * Delete metadata for the specified object. - * - * @access public - * - * @todo Refactor to not use interpolated values when preparing the SQL query. - * - * @param string $type Meta type. - * @param int $object_id ID of the object. - * @param array $meta_ids IDs of the meta objects to delete. - */ - public function delete_metadata( $type, $object_id, $meta_ids ) { - global $wpdb; - - $table = _get_meta_table( $type ); - if ( ! $table ) { - return false; - } - - foreach ( $meta_ids as $meta_id ) { - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $wpdb->query( $wpdb->prepare( "DELETE FROM $table WHERE meta_id = %d", $meta_id ) ); - } - - // If we don't have an object ID what do we do - invalidate ALL meta? - if ( $object_id ) { - wp_cache_delete( $object_id, $type . '_meta' ); - } - } - - /** - * Delete metadata with a certain key for the specified objects. - * - * @access public - * - * @todo Test this out to make sure it works as expected. - * @todo Refactor to not use interpolated values when preparing the SQL query. - * - * @param string $type Meta type. - * @param array $object_ids IDs of the objects. - * @param string $meta_key Meta key. - */ - public function delete_batch_metadata( $type, $object_ids, $meta_key ) { - global $wpdb; - - $table = _get_meta_table( $type ); - if ( ! $table ) { - return false; - } - $column = sanitize_key( $type . '_id' ); - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $wpdb->query( $wpdb->prepare( "DELETE FROM $table WHERE $column IN (%s) && meta_key = %s", implode( ',', $object_ids ), $meta_key ) ); - - // If we don't have an object ID what do we do - invalidate ALL meta? - foreach ( $object_ids as $object_id ) { - wp_cache_delete( $object_id, $type . '_meta' ); - } - } - - /** - * Retrieve value of a constant based on the constant name. - * - * We explicitly return null instead of false if the constant doesn't exist. - * - * @access public - * - * @param string $constant Name of constant to retrieve. - * @return mixed Value set for the constant. - */ - public function get_constant( $constant ) { - $value = get_option( 'jetpack_constant_' . $constant ); - - if ( $value ) { - return $value; - } - - return null; - } - - /** - * Set the value of a constant. - * - * @access public - * - * @param string $constant Name of constant to retrieve. - * @param mixed $value Value set for the constant. - */ - public function set_constant( $constant, $value ) { - update_option( 'jetpack_constant_' . $constant, $value ); - } - - /** - * Retrieve the number of the available updates of a certain type. - * Type is one of: `plugins`, `themes`, `wordpress`, `translations`, `total`, `wp_update_version`. - * - * @access public - * - * @param string $type Type of updates to retrieve. - * @return int|null Number of updates available, `null` if type is invalid or missing. - */ - public function get_updates( $type ) { - $all_updates = get_option( 'jetpack_updates', array() ); - - if ( isset( $all_updates[ $type ] ) ) { - return $all_updates[ $type ]; - } else { - return null; - } - } - - /** - * Set the available updates of a certain type. - * Type is one of: `plugins`, `themes`, `wordpress`, `translations`, `total`, `wp_update_version`. - * - * @access public - * - * @param string $type Type of updates to set. - * @param int $updates Total number of updates. - */ - public function set_updates( $type, $updates ) { - $all_updates = get_option( 'jetpack_updates', array() ); - $all_updates[ $type ] = $updates; - update_option( 'jetpack_updates', $all_updates ); - } - - /** - * Retrieve a callable value based on its name. - * - * @access public - * - * @param string $name Name of the callable to retrieve. - * @return mixed Value of the callable. - */ - public function get_callable( $name ) { - $value = get_option( 'jetpack_' . $name ); - - if ( $value ) { - return $value; - } - - return null; - } - - /** - * Update the value of a callable. - * - * @access public - * - * @param string $name Callable name. - * @param mixed $value Callable value. - */ - public function set_callable( $name, $value ) { - update_option( 'jetpack_' . $name, $value ); - } - - /** - * Retrieve a network option value based on a network option name. - * - * @access public - * - * @param string $option Name of network option to retrieve. - * @return mixed Value set for the network option. - */ - public function get_site_option( $option ) { - return get_option( 'jetpack_network_' . $option ); - } - - /** - * Update the value of a network option. - * - * @access public - * - * @param string $option Network option name. - * @param mixed $value Network option value. - * @return bool False if value was not updated and true if value was updated. - */ - public function update_site_option( $option, $value ) { - return update_option( 'jetpack_network_' . $option, $value ); - } - - /** - * Remove a network option by name. - * - * @access public - * - * @param string $option Name of option to remove. - * @return bool True, if option is successfully deleted. False on failure. - */ - public function delete_site_option( $option ) { - return delete_option( 'jetpack_network_' . $option ); - } - - /** - * Retrieve the terms from a particular taxonomy. - * - * @access public - * - * @param string $taxonomy Taxonomy slug. - * - * @return array|WP_Error Array of terms or WP_Error object on failure. - */ - public function get_terms( $taxonomy ) { - $t = $this->ensure_taxonomy( $taxonomy ); - if ( ! $t || is_wp_error( $t ) ) { - return $t; - } - return get_terms( $taxonomy ); - } - - /** - * Retrieve a particular term. - * - * @access public - * - * @param string|false $taxonomy Taxonomy slug. - * @param int $term_id ID of the term. - * @param string $term_key ID Field `term_id` or `term_taxonomy_id`. - * - * @return \WP_Term|WP_Error Term object on success, \WP_Error object on failure. - */ - public function get_term( $taxonomy, $term_id, $term_key = 'term_id' ) { - - // Full Sync will pass false for the $taxonomy so a check for term_taxonomy_id is needed before ensure_taxonomy. - if ( 'term_taxonomy_id' === $term_key ) { - return get_term_by( 'term_taxonomy_id', $term_id ); - } - - $t = $this->ensure_taxonomy( $taxonomy ); - if ( ! $t || is_wp_error( $t ) ) { - return $t; - } - - return get_term( $term_id, $taxonomy ); - } - - /** - * Verify a taxonomy is legitimate and register it if necessary. - * - * @access private - * - * @param string $taxonomy Taxonomy slug. - * - * @return bool|void|WP_Error True if already exists; void if it was registered; \WP_Error on error. - */ - private function ensure_taxonomy( $taxonomy ) { - if ( ! taxonomy_exists( $taxonomy ) ) { - // Try re-registering synced taxonomies. - $taxonomies = $this->get_callable( 'taxonomies' ); - if ( ! isset( $taxonomies[ $taxonomy ] ) ) { - // Doesn't exist, or somehow hasn't been synced. - return new WP_Error( 'invalid_taxonomy', "The taxonomy '$taxonomy' doesn't exist" ); - } - $t = $taxonomies[ $taxonomy ]; - - return register_taxonomy( - $taxonomy, - $t->object_type, - (array) $t - ); - } - - return true; - } - - /** - * Retrieve all terms from a taxonomy that are related to an object with a particular ID. - * - * @access public - * - * @param int $object_id Object ID. - * @param string $taxonomy Taxonomy slug. - * - * @return array|bool|WP_Error Array of terms on success, `false` if no terms or post doesn't exist, \WP_Error on failure. - */ - public function get_the_terms( $object_id, $taxonomy ) { - return get_the_terms( $object_id, $taxonomy ); - } - - /** - * Insert or update a term. - * - * @access public - * - * @param \WP_Term $term_object Term object. - * - * @return array|bool|WP_Error Array of term_id and term_taxonomy_id if updated, true if inserted, \WP_Error on failure. - */ - public function update_term( $term_object ) { - $taxonomy = $term_object->taxonomy; - global $wpdb; - $exists = $wpdb->get_var( - $wpdb->prepare( - "SELECT EXISTS( SELECT 1 FROM $wpdb->terms WHERE term_id = %d )", - $term_object->term_id - ) - ); - if ( ! $exists ) { - $term_object = sanitize_term( clone $term_object, $taxonomy, 'db' ); - $term = array( - 'term_id' => $term_object->term_id, - 'name' => $term_object->name, - 'slug' => $term_object->slug, - 'term_group' => $term_object->term_group, - ); - $term_taxonomy = array( - 'term_taxonomy_id' => $term_object->term_taxonomy_id, - 'term_id' => $term_object->term_id, - 'taxonomy' => $term_object->taxonomy, - 'description' => $term_object->description, - 'parent' => (int) $term_object->parent, - 'count' => (int) $term_object->count, - ); - $wpdb->insert( $wpdb->terms, $term ); - $wpdb->insert( $wpdb->term_taxonomy, $term_taxonomy ); - - return true; - } - - return wp_update_term( $term_object->term_id, $taxonomy, (array) $term_object ); - } - - /** - * Delete a term by the term ID and its corresponding taxonomy. - * - * @access public - * - * @param int $term_id Term ID. - * @param string $taxonomy Taxonomy slug. - * - * @return bool|int|WP_Error True on success, false if term doesn't exist. Zero if trying with default category. \WP_Error on invalid taxonomy. - */ - public function delete_term( $term_id, $taxonomy ) { - $this->ensure_taxonomy( $taxonomy ); - return wp_delete_term( $term_id, $taxonomy ); - } - - /** - * Add/update terms of a particular taxonomy of an object with the specified ID. - * - * @access public - * - * @param int $object_id The object to relate to. - * @param string $taxonomy The context in which to relate the term to the object. - * @param string|int|array $terms A single term slug, single term id, or array of either term slugs or ids. - * @param bool $append Optional. If false will delete difference of terms. Default false. - */ - public function update_object_terms( $object_id, $taxonomy, $terms, $append ) { - $this->ensure_taxonomy( $taxonomy ); - wp_set_object_terms( $object_id, $terms, $taxonomy, $append ); - } - - /** - * Remove certain term relationships from the specified object. - * - * @access public - * - * @todo Refactor to not use interpolated values when preparing the SQL query. - * - * @param int $object_id ID of the object. - * @param array $tt_ids Term taxonomy IDs. - * @return bool True on success, false on failure. - */ - public function delete_object_terms( $object_id, $tt_ids ) { - global $wpdb; - - if ( is_array( $tt_ids ) && ! empty( $tt_ids ) ) { - // Escape. - $tt_ids_sanitized = array_map( 'intval', $tt_ids ); - - $taxonomies = array(); - foreach ( $tt_ids_sanitized as $tt_id ) { - $term = get_term_by( 'term_taxonomy_id', $tt_id ); - $taxonomies[ $term->taxonomy ][] = $tt_id; - } - $in_tt_ids = implode( ', ', $tt_ids_sanitized ); - - /** - * Fires immediately before an object-term relationship is deleted. - * - * @since 1.6.3 - * @since-jetpack 2.9.0 - * - * @param int $object_id Object ID. - * @param array $tt_ids An array of term taxonomy IDs. - */ - do_action( 'delete_term_relationships', $object_id, $tt_ids_sanitized ); - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $deleted = $wpdb->query( $wpdb->prepare( "DELETE FROM $wpdb->term_relationships WHERE object_id = %d AND term_taxonomy_id IN ($in_tt_ids)", $object_id ) ); - foreach ( $taxonomies as $taxonomy => $taxonomy_tt_ids ) { - $this->ensure_taxonomy( $taxonomy ); - wp_cache_delete( $object_id, $taxonomy . '_relationships' ); - /** - * Fires immediately after an object-term relationship is deleted. - * - * @since 1.6.3 - * @since-jetpack 2.9.0 - * - * @param int $object_id Object ID. - * @param array $tt_ids An array of term taxonomy IDs. - */ - do_action( 'deleted_term_relationships', $object_id, $taxonomy_tt_ids ); - wp_update_term_count( $taxonomy_tt_ids, $taxonomy ); - } - - return (bool) $deleted; - } - - return false; - } - - /** - * Retrieve the number of users. - * Not supported in this replicastore. - * - * @access public - */ - public function user_count() { - // Noop. - } - - /** - * Retrieve a user object by the user ID. - * - * @access public - * - * @param int $user_id User ID. - * @return \WP_User|null User object, or `null` if user invalid/not found. - */ - public function get_user( $user_id ) { - $user = get_user_by( 'id', $user_id ); - return $user instanceof \WP_User ? $user : null; - } - - /** - * Insert or update a user. - * Not supported in this replicastore. - * - * @access public - * @throws Exception If this method is invoked. - * - * @param \WP_User $user User object. - */ - public function upsert_user( $user ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $this->invalid_call(); - } - - /** - * Delete a user. - * Not supported in this replicastore. - * - * @access public - * @throws Exception If this method is invoked. - * - * @param int $user_id User ID. - */ - public function delete_user( $user_id ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $this->invalid_call(); - } - - /** - * Update/insert user locale. - * Not supported in this replicastore. - * - * @access public - * @throws Exception If this method is invoked. - * - * @param int $user_id User ID. - * @param string $local The user locale. - */ - public function upsert_user_locale( $user_id, $local ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $this->invalid_call(); - } - - /** - * Delete user locale. - * Not supported in this replicastore. - * - * @access public - * @throws Exception If this method is invoked. - * - * @param int $user_id User ID. - */ - public function delete_user_locale( $user_id ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $this->invalid_call(); - } - - /** - * Retrieve the user locale. - * - * @access public - * - * @param int $user_id User ID. - * @return string The user locale. - */ - public function get_user_locale( $user_id ) { - return get_user_locale( $user_id ); - } - - /** - * Retrieve the allowed mime types for the user. - * Not supported in this replicastore. - * - * @access public - * - * @param int $user_id User ID. - */ - public function get_allowed_mime_types( $user_id ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // Noop. - } - - /** - * Retrieve all the checksums we are interested in. - * - * @access public - * - * @param boolean $perform_text_conversion If text fields should be latin1 converted. - * - * @return array Checksums. - */ - public function checksum_all( $perform_text_conversion = false ) { - $all_checksum_tables = Table_Checksum::get_allowed_tables(); - - unset( $all_checksum_tables['users'] ); // Handled separately - TODO. - unset( $all_checksum_tables['usermeta'] ); // Handled separately - TODO. - unset( $all_checksum_tables['termmeta'] ); // Handled separately - TODO. - unset( $all_checksum_tables['links'] ); // Not supported yet. Consider removing from default config. - unset( $all_checksum_tables['options'] ); // Not supported yet. Consider removing from default config. - - $all_checksum_tables = array_unique( array_keys( $all_checksum_tables ) ); - - $result = array(); - - foreach ( $all_checksum_tables as $table ) { - $result_key = in_array( $table, array( 'postmeta', 'commentmeta' ), true ) ? str_replace( 'meta', '_meta', $table ) : $table; - try { - $checksum = $this->checksum_histogram( $table, null, null, null, null, true, '', false, false, $perform_text_conversion ); - $result[ $result_key ] = $this->summarize_checksum_histogram( $checksum ); - } catch ( Exception $ex ) { - $result[ $result_key ] = null; - } - } - - return $result; - } - - /** - * Return the summarized checksum from buckets or the WP_Error. - * - * @param array $histogram checksum_histogram result. - * - * @return int|WP_Error checksum or Error. - */ - protected function summarize_checksum_histogram( $histogram ) { - if ( is_wp_error( $histogram ) ) { - return $histogram; - } else { - return array_sum( $histogram ); - } - } - - /** - * Grabs the minimum and maximum object ids for the given parameters. - * - * @access public - * - * @param string $id_field The id column in the table to query. - * @param string $object_table The table to query. - * @param string $where A sql where clause without 'WHERE'. - * @param int $bucket_size The maximum amount of objects to include in the query. - * For `term_relationships` table, the bucket size will refer to the amount - * of distinct object ids. This will likely include more database rows than - * the bucket size implies. - * - * @return object An object with min_id and max_id properties. - */ - public function get_min_max_object_id( $id_field, $object_table, $where, $bucket_size ) { - global $wpdb; - - // The term relationship table's unique key is a combination of 2 columns. `DISTINCT` helps us get a more acurate query. - $distinct_sql = ( $wpdb->term_relationships === $object_table ) ? 'DISTINCT' : ''; - $where_sql = $where ? "WHERE $where" : ''; - - // Since MIN() and MAX() do not work with LIMIT, we'll need to adjust the dataset we query if a limit is present. - // With a limit present, we'll look at a dataset consisting of object_ids that meet the constructs of the $where clause. - // Without a limit, we can use the actual table as a dataset. - $from = $bucket_size ? - "( SELECT $distinct_sql $id_field FROM $object_table $where_sql ORDER BY $id_field ASC LIMIT " . ( (int) $bucket_size ) . ' ) as ids' : - "$object_table $where_sql ORDER BY $id_field ASC"; - - return $wpdb->get_row( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT MIN($id_field) as min, MAX($id_field) as max FROM $from" - ); - } - - /** - * Retrieve the checksum histogram for a specific object type. - * - * @access public - * - * @param string $table Object type. - * @param null $buckets Number of buckets to split the objects to. - * @param null $start_id Minimum object ID. - * @param null $end_id Maximum object ID. - * @param null $columns Table columns to calculate the checksum from. - * @param bool $strip_non_ascii Whether to strip non-ASCII characters. - * @param string $salt Salt, used for $wpdb->prepare()'s args. - * @param bool $only_range_edges Only return the range edges and not the actual checksums. - * @param bool $detailed_drilldown If the call should return a detailed drilldown for the checksum or only the checksum. - * @param bool $perform_text_conversion If text fields should be converted to latin1 during the checksum calculation. - * - * @return array|WP_Error The checksum histogram. - */ - public function checksum_histogram( $table, $buckets = null, $start_id = null, $end_id = null, $columns = null, $strip_non_ascii = true, $salt = '', $only_range_edges = false, $detailed_drilldown = false, $perform_text_conversion = false ) { - global $wpdb; - - $wpdb->queries = array(); - try { - $checksum_table = $this->get_table_checksum_instance( $table, $salt, $perform_text_conversion, $columns ); - } catch ( Exception $ex ) { - return new WP_Error( 'checksum_disabled', $ex->getMessage() ); - } - - try { - $range_edges = $checksum_table->get_range_edges( $start_id, $end_id ); - } catch ( Exception $ex ) { - return new WP_Error( 'invalid_range_edges', '[' . $start_id . '-' . $end_id . ']: ' . $ex->getMessage() ); - } - - if ( $only_range_edges ) { - return $range_edges; - } - - $object_count = (int) $range_edges['item_count']; - - if ( 0 === $object_count ) { - return array(); - } - - // Validate / Determine Buckets. - if ( $buckets === null || $buckets < 1 ) { - $buckets = $this->calculate_buckets( $table, $object_count ); - } - - $bucket_size = (int) ceil( $object_count / $buckets ); - $previous_max_id = max( 0, $range_edges['min_range'] ); - $histogram = array(); - - do { - try { - $ids_range = $checksum_table->get_range_edges( $previous_max_id, null, $bucket_size ); - } catch ( Exception $ex ) { - return new WP_Error( 'invalid_range_edges', '[' . $previous_max_id . '- ]: ' . $ex->getMessage() ); - } - - if ( empty( $ids_range['min_range'] ) || empty( $ids_range['max_range'] ) ) { - // Nothing to checksum here... - break; - } - - // Get the checksum value. - $batch_checksum = $checksum_table->calculate_checksum( $ids_range['min_range'], $ids_range['max_range'], null, $detailed_drilldown ); - - if ( is_wp_error( $batch_checksum ) ) { - return $batch_checksum; - } - - if ( $ids_range['min_range'] === $ids_range['max_range'] ) { - $histogram[ $ids_range['min_range'] ] = $batch_checksum; - } else { - $histogram[ "{$ids_range[ 'min_range' ]}-{$ids_range[ 'max_range' ]}" ] = $batch_checksum; - } - // If ids_range['max_range'] is PHP_INT_MAX, we've reached the end of the table. Edge case causing the loop to never end. - if ( PHP_INT_MAX === (int) $ids_range['max_range'] ) { - break; - } - $previous_max_id = $ids_range['max_range'] + 1; - // If we've reached the max_range lets bail out. - if ( $previous_max_id > $range_edges['max_range'] ) { - break; - } - } while ( true ); - - return $histogram; - } - - /** - * Retrieve the type of the checksum. - * - * @access public - * - * @return string Type of the checksum. - */ - public function get_checksum_type() { - return 'sum'; - } - - /** - * Used in methods that are not implemented and shouldn't be invoked. - * - * @access private - * @return never - * @throws Exception If this method is invoked. - */ - private function invalid_call() { - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace - $backtrace = debug_backtrace(); - $caller = $backtrace[1]['function']; - throw new Exception( "This function $caller is not supported on the WP Replicastore" ); - } - - /** - * Determine number of buckets to use in full table checksum. - * - * @param string $table Object Type. - * @param int $object_count Object count. - * @return int Number of Buckets to use. - */ - private function calculate_buckets( $table, $object_count ) { - // Ensure no division by 0. - if ( 0 === (int) $object_count ) { - return 1; - } - - // Default Bucket sizes. - $bucket_size = 10000; // Default bucket size is 10,000 items. - switch ( $table ) { - case 'postmeta': - case 'commentmeta': - case 'order_itemmeta': - $bucket_size = 1000; // Meta bucket size is restricted to 1000 items. - } - - return (int) ceil( $object_count / $bucket_size ); - } - - /** - * Return an instance for `Table_Checksum`, depending on the table. - * - * Some tables require custom instances, due to different checksum logic. - * - * @param string $table The table that we want to get the instance for. - * @param string $salt Salt to be used when generating the checksums. - * @param bool $perform_text_conversion Should we perform text encoding conversion when calculating the checksum. - * @param array $additional_columns Additional columns to add to the checksum calculation. - * - * @return Table_Checksum|Table_Checksum_Usermeta - * @throws Exception Might throw an exception if any of the input parameters were invalid. - */ - public function get_table_checksum_instance( $table, $salt = null, $perform_text_conversion = false, $additional_columns = null ) { - if ( 'users' === $table ) { - return new Table_Checksum_Users( $table, $salt, $perform_text_conversion, $additional_columns ); - } - if ( 'usermeta' === $table ) { - return new Table_Checksum_Usermeta( $table, $salt, $perform_text_conversion, $additional_columns ); - } - - return new Table_Checksum( $table, $salt, $perform_text_conversion, $additional_columns ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php deleted file mode 100644 index 71a91bf7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php +++ /dev/null @@ -1,888 +0,0 @@ - WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::full_sync_start', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'modules' => array( - 'description' => __( 'Data Modules that should be included in Full Sync', 'jetpack-sync' ), - 'type' => 'array', - 'required' => false, - ), - 'users' => array( - 'description' => __( 'User IDs to include in Full Sync or "initial"', 'jetpack-sync' ), - 'required' => false, - ), - 'posts' => array( - 'description' => __( 'Post IDs to include in Full Sync', 'jetpack-sync' ), - 'type' => 'array', - 'required' => false, - ), - 'comments' => array( - 'description' => __( 'Comment IDs to include in Full Sync', 'jetpack-sync' ), - 'type' => 'array', - 'required' => false, - ), - 'context' => array( - 'description' => __( 'Context for the Full Sync', 'jetpack-sync' ), - 'type' => 'string', - 'required' => false, - ), - ), - ) - ); - - // Obtain Sync status. - register_rest_route( - 'jetpack/v4', - '/sync/status', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::sync_status', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'fields' => array( - 'description' => __( 'Comma seperated list of additional fields that should be included in status.', 'jetpack-sync' ), - 'type' => 'string', - 'required' => false, - ), - ), - ) - ); - - // Update Sync health status. - register_rest_route( - 'jetpack/v4', - '/sync/health', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::sync_health', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'status' => array( - 'description' => __( 'New Sync health status', 'jetpack-sync' ), - 'type' => 'string', - 'required' => true, - ), - ), - ) - ); - - // Obtain Sync settings. - register_rest_route( - 'jetpack/v4', - '/sync/settings', - array( - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_sync_settings', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - ), - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::update_sync_settings', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - ), - ) - ); - - // Retrieve Sync Object(s). - register_rest_route( - 'jetpack/v4', - '/sync/object', - array( - 'methods' => WP_REST_Server::ALLMETHODS, - 'callback' => __CLASS__ . '::get_sync_objects', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'module_name' => array( - 'description' => __( 'Name of Sync module', 'jetpack-sync' ), - 'type' => 'string', - 'required' => false, - ), - 'object_type' => array( - 'description' => __( 'Object Type', 'jetpack-sync' ), - 'type' => 'string', - 'required' => false, - ), - 'object_ids' => array( - 'description' => __( 'Objects Identifiers', 'jetpack-sync' ), - 'type' => 'array', - 'required' => false, - ), - ), - ) - ); - - // Retrieve Sync Object(s). - register_rest_route( - 'jetpack/v4', - '/sync/now', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::do_sync', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'queue' => array( - 'description' => __( 'Name of Sync queue.', 'jetpack-sync' ), - 'type' => 'string', - 'required' => true, - ), - ), - ) - ); - - // Checkout Sync Objects. - register_rest_route( - 'jetpack/v4', - '/sync/checkout', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::checkout', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - ) - ); - - // Checkin Sync Objects. - register_rest_route( - 'jetpack/v4', - '/sync/close', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::close', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - ) - ); - - // Unlock Sync Queue. - register_rest_route( - 'jetpack/v4', - '/sync/unlock', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::unlock_queue', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'queue' => array( - 'description' => __( 'Name of Sync queue.', 'jetpack-sync' ), - 'type' => 'string', - 'required' => true, - ), - ), - ) - ); - - // Retrieve range of Object Ids. - register_rest_route( - 'jetpack/v4', - '/sync/object-id-range', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::get_object_id_range', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'sync_module' => array( - 'description' => __( 'Name of Sync module.', 'jetpack-sync' ), - 'type' => 'string', - 'required' => true, - ), - 'batch_size' => array( - 'description' => __( 'Size of batches', 'jetpack-sync' ), - 'type' => 'int', - 'required' => true, - ), - ), - ) - ); - - // Obtain table checksums. - register_rest_route( - 'jetpack/v4', - '/sync/data-check', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::data_check', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'perform_text_conversion' => array( - 'description' => __( 'If text fields should be converted to latin1 in checksum calculation.', 'jetpack-sync' ), - 'type' => 'boolean', - 'required' => false, - ), - ), - ) - ); - - // Obtain histogram. - register_rest_route( - 'jetpack/v4', - '/sync/data-histogram', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::data_histogram', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - 'args' => array( - 'columns' => array( - 'description' => __( 'Column mappings', 'jetpack-sync' ), - 'type' => 'array', - 'required' => false, - ), - 'object_type' => array( - 'description' => __( 'Object Type', 'jetpack-sync' ), - 'type' => 'string', - 'required' => false, - ), - 'buckets' => array( - 'description' => __( 'Number of histogram buckets.', 'jetpack-sync' ), - 'type' => 'int', - 'required' => false, - ), - 'start_id' => array( - 'description' => __( 'Start ID for the histogram', 'jetpack-sync' ), - 'type' => 'int', - 'required' => false, - ), - 'end_id' => array( - 'description' => __( 'End ID for the histogram', 'jetpack-sync' ), - 'type' => 'int', - 'required' => false, - ), - 'strip_non_ascii' => array( - 'description' => __( 'Strip non-ascii characters?', 'jetpack-sync' ), - 'type' => 'boolean', - 'required' => false, - ), - 'shared_salt' => array( - 'description' => __( 'Shared Salt to use when generating checksum', 'jetpack-sync' ), - 'type' => 'string', - 'required' => false, - ), - 'only_range_edges' => array( - 'description' => __( 'Should only range edges be returned', 'jetpack-sync' ), - 'type' => 'boolean', - 'required' => false, - ), - 'detailed_drilldown' => array( - 'description' => __( 'Do we want the checksum or object ids.', 'jetpack-sync' ), - 'type' => 'boolean', - 'required' => false, - ), - 'perform_text_conversion' => array( - 'description' => __( 'If text fields should be converted to latin1 in checksum calculation.', 'jetpack-sync' ), - 'type' => 'boolean', - 'required' => false, - ), - ), - ) - ); - - // Trigger Dedicated Sync request. - register_rest_route( - 'jetpack/v4', - '/sync/spawn-sync', - array( - 'methods' => WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::spawn_sync', - 'permission_callback' => '__return_true', - ) - ); - - // Reset Sync locks. - register_rest_route( - 'jetpack/v4', - '/sync/locks', - array( - 'methods' => WP_REST_Server::DELETABLE, - 'callback' => __CLASS__ . '::reset_locks', - 'permission_callback' => __CLASS__ . '::verify_default_permissions', - ) - ); - } - - /** - * Trigger a Full Sync of specified modules. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response|WP_Error - */ - public static function full_sync_start( $request ) { - - $modules = $request->get_param( 'modules' ); - - // convert list of modules into array format of "$modulename => true". - if ( ! empty( $modules ) ) { - $modules = array_map( '__return_true', array_flip( $modules ) ); - } - - // Process additional options. - foreach ( array( 'posts', 'comments', 'users' ) as $module_name ) { - if ( 'users' === $module_name && 'initial' === $request->get_param( 'users' ) ) { - $modules['users'] = 'initial'; - } elseif ( is_array( $request->get_param( $module_name ) ) ) { - $ids = $request->get_param( $module_name ); - if ( array() !== $ids ) { - $modules[ $module_name ] = $ids; - } - } - } - - if ( empty( $modules ) ) { - $modules = null; - } - - $context = $request->get_param( 'context' ); - - return rest_ensure_response( - array( - 'scheduled' => Actions::do_full_sync( $modules, $context ), - ) - ); - } - - /** - * Return Sync's status. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function sync_status( $request ) { - $fields = $request->get_param( 'fields' ); - return rest_ensure_response( Actions::get_sync_status( $fields ) ); - } - - /** - * Return table checksums. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function data_check( $request ) { - // Disable Sync during this call, so we can resolve faster. - Actions::mark_sync_read_only(); - $store = new Replicastore(); - - $perform_text_conversion = false; - if ( true === $request->get_param( 'perform_text_conversion' ) ) { - $perform_text_conversion = true; - } - - return rest_ensure_response( $store->checksum_all( $perform_text_conversion ) ); - } - - /** - * Return Histogram. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function data_histogram( $request ) { - - // Disable Sync during this call, so we can resolve faster. - Actions::mark_sync_read_only(); - - $args = $request->get_params(); - - if ( empty( $args['columns'] ) ) { - $args['columns'] = null; // go with defaults. - } - - if ( false !== $args['strip_non_ascii'] ) { - $args['strip_non_ascii'] = true; - } - - if ( true !== $args['perform_text_conversion'] ) { - $args['perform_text_conversion'] = false; - } - - /** - * Hack: nullify the values of `start_id` and `end_id` if we're only requesting ranges. - * - * The endpoint doesn't support nullable values :( - */ - if ( true === $args['only_range_edges'] ) { - if ( 0 === $args['start_id'] ) { - $args['start_id'] = null; - } - - if ( 0 === $args['end_id'] ) { - $args['end_id'] = null; - } - } - - $store = new Replicastore(); - $histogram = $store->checksum_histogram( $args['object_type'], $args['buckets'], $args['start_id'], $args['end_id'], $args['columns'], $args['strip_non_ascii'], $args['shared_salt'], $args['only_range_edges'], $args['detailed_drilldown'], $args['perform_text_conversion'] ); - - return rest_ensure_response( - array( - 'histogram' => $histogram, - 'type' => $store->get_checksum_type(), - ) - ); - } - - /** - * Update Sync health. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function sync_health( $request ) { - - switch ( $request->get_param( 'status' ) ) { - case Health::STATUS_IN_SYNC: - case Health::STATUS_OUT_OF_SYNC: - Health::update_status( $request->get_param( 'status' ) ); - break; - default: - return new WP_Error( 'invalid_status', 'Invalid Sync Status Provided.' ); - } - - // re-fetch so we see what's really being stored. - return rest_ensure_response( - array( - 'success' => Health::get_status(), - ) - ); - } - - /** - * Obtain Sync settings. - * - * @since 1.23.1 - * - * @return \WP_REST_Response - */ - public static function get_sync_settings() { - return rest_ensure_response( Settings::get_settings() ); - } - - /** - * Update Sync settings. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function update_sync_settings( $request ) { - $args = $request->get_params(); - $sync_settings = Settings::get_settings(); - - foreach ( $args as $key => $value ) { - if ( false !== $value ) { - if ( is_numeric( $value ) ) { - $value = (int) $value; - } - - // special case for sending empty arrays - a string with value 'empty'. - if ( 'empty' === $value ) { - $value = array(); - } - - $sync_settings[ $key ] = $value; - } - } - - Settings::update_settings( $sync_settings ); - - // re-fetch so we see what's really being stored. - return rest_ensure_response( Settings::get_settings() ); - } - - /** - * Retrieve Sync Objects. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function get_sync_objects( $request ) { - $args = $request->get_params(); - - $module_name = $args['module_name']; - // Verify valid Sync Module. - $sync_module = Modules::get_module( $module_name ); - if ( ! $sync_module ) { - return new WP_Error( 'invalid_module', 'You specified an invalid sync module' ); - } - - Actions::mark_sync_read_only(); - - $codec = Sender::get_instance()->get_codec(); - Settings::set_is_syncing( true ); - $objects = $codec->encode( $sync_module->get_objects_by_id( $args['object_type'], $args['object_ids'] ) ); - Settings::set_is_syncing( false ); - - return rest_ensure_response( - array( - 'objects' => $objects, - 'codec' => $codec->name(), - ) - ); - } - - /** - * Request Sync processing. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function do_sync( $request ) { - - $queue_name = self::validate_queue( $request->get_param( 'queue' ) ); - if ( is_wp_error( $queue_name ) ) { - return $queue_name; - } - - $sender = Sender::get_instance(); - $response = $sender->do_sync_for_queue( new Queue( $queue_name ) ); - - return rest_ensure_response( - array( - 'response' => $response, - ) - ); - } - - /** - * Request sync data from specified queue. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function checkout( $request ) { - $args = $request->get_params(); - $queue_name = self::validate_queue( $args['queue'] ); - - if ( is_wp_error( $queue_name ) ) { - return $queue_name; - } - - $number_of_items = $args['number_of_items']; - if ( $number_of_items < 1 || $number_of_items > 100 ) { - return new WP_Error( 'invalid_number_of_items', 'Number of items needs to be an integer that is larger than 0 and less then 100', 400 ); - } - - // REST Sender. - $sender = new REST_Sender(); - - if ( 'immediate' === $queue_name ) { - return rest_ensure_response( $sender->immediate_full_sync_pull() ); - } - - $response = $sender->queue_pull( $queue_name, $number_of_items, $args ); - // Disable sending while pulling. - if ( ! is_wp_error( $response ) ) { - set_transient( Sender::TEMP_SYNC_DISABLE_TRANSIENT_NAME, time(), Sender::TEMP_SYNC_DISABLE_TRANSIENT_EXPIRY ); - } elseif ( 'queue_size' === $response->get_error_code() ) { - // Re-enable sending if the queue is empty. - delete_transient( Sender::TEMP_SYNC_DISABLE_TRANSIENT_NAME ); - } - - return rest_ensure_response( $response ); - } - - /** - * Unlock a Sync queue. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function unlock_queue( $request ) { - - $queue_name = $request->get_param( 'queue' ); - - if ( ! in_array( $queue_name, array( 'sync', 'full_sync' ), true ) ) { - return new WP_Error( 'invalid_queue', 'Queue name should be sync or full_sync', 400 ); - } - $queue = new Queue( $queue_name ); - - // False means that there was no lock to delete. - $response = $queue->unlock(); - return rest_ensure_response( - array( - 'success' => $response, - ) - ); - } - - /** - * Checkin Sync actions. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function close( $request ) { - - $request_body = $request->get_params(); - $queue_name = self::validate_queue( $request_body['queue'] ); - - if ( is_wp_error( $queue_name ) ) { - return $queue_name; - } - - if ( empty( $request_body['buffer_id'] ) ) { - return new WP_Error( 'missing_buffer_id', 'Please provide a buffer id', 400 ); - } - - if ( ! is_array( $request_body['item_ids'] ) ) { - return new WP_Error( 'missing_item_ids', 'Please provide a list of item ids in the item_ids argument', 400 ); - } - - // Limit to A-Z,a-z,0-9,_,- . - $request_body['buffer_id'] = preg_replace( '/[^A-Za-z0-9\-_\.]/', '', $request_body['buffer_id'] ); - $request_body['item_ids'] = array_filter( array_map( array( 'Automattic\Jetpack\Sync\REST_Endpoints', 'sanitize_item_ids' ), $request_body['item_ids'] ) ); - - $queue = new Queue( $queue_name ); - - $items = $queue->peek_by_id( $request_body['item_ids'] ); - - // Update Full Sync Status if queue is "full_sync". - if ( 'full_sync' === $queue_name ) { - $full_sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $full_sync_module'; - $full_sync_module->update_sent_progress_action( $items ); - } - - $buffer = new Queue_Buffer( $request_body['buffer_id'], $request_body['item_ids'] ); - $response = $queue->close( $buffer, $request_body['item_ids'] ); - - // Perform another checkout? - if ( isset( $request_body['continue'] ) && $request_body['continue'] ) { - if ( in_array( $queue_name, array( 'full_sync', 'immediate' ), true ) ) { - // Send Full Sync Actions. - Sender::get_instance()->do_full_sync(); - } elseif ( $queue->has_any_items() ) { - // Send Incremental Sync Actions. - Sender::get_instance()->do_sync(); - } - } - - if ( is_wp_error( $response ) ) { - return $response; - } - - return rest_ensure_response( - array( - 'success' => $response, - 'status' => Actions::get_sync_status(), - ) - ); - } - - /** - * Retrieve range of Object Ids for a specified Sync module. - * - * @since 1.23.1 - * - * @param \WP_REST_Request $request The request sent to the WP REST API. - * - * @return \WP_REST_Response - */ - public static function get_object_id_range( $request ) { - - $module_name = $request->get_param( 'sync_module' ); - $batch_size = $request->get_param( 'batch_size' ); - - if ( ! self::is_valid_sync_module( $module_name ) ) { - return new WP_Error( 'invalid_module', 'This sync module cannot be used to calculate a range.', 400 ); - } - $module = Modules::get_module( $module_name ); - - return rest_ensure_response( - array( - 'ranges' => $module->get_min_max_object_ids_for_batches( $batch_size ), - ) - ); - } - - /** - * This endpoint is used by Sync to spawn a - * dedicated Sync request which will trigger Sync to run. - * - * If Dedicated Sync is enabled, this callback should never run as - * processing of Sync actions will occur earlier and exit. - * - * @see Actions::init - * @see Sender::do_dedicated_sync_and_exit - * - * @since 1.34.0 - * - * @return \WP_REST_Response - */ - public static function spawn_sync() { - nocache_headers(); - - if ( ! Settings::is_dedicated_sync_enabled() ) { - return new WP_Error( - 'dedicated_sync_disabled', - 'Dedicated Sync flow is disabled.', - array( 'status' => 422 ) - ); - } - - return new WP_Error( - 'dedicated_sync_failed', - 'Failed to process Dedicated Sync request', - array( 'status' => 500 ) - ); - } - - /** - * Reset Sync locks. - * - * @since 1.43.0 - * - * @return \WP_REST_Response - */ - public static function reset_locks() { - Actions::reset_sync_locks(); - - return rest_ensure_response( - array( - 'success' => true, - ) - ); - } - - /** - * Verify that request has default permissions to perform sync actions. - * - * @since 1.23.1 - * - * @return bool Whether user has capability 'manage_options' or a blog token is used. - */ - public static function verify_default_permissions() { - if ( current_user_can( 'manage_options' ) || Rest_Authentication::is_signed_with_blog_token() ) { - return true; - } - - $error_msg = esc_html__( - 'You do not have the correct user permissions to perform this action. - Please contact your site admin if you think this is a mistake.', - 'jetpack-sync' - ); - - return new WP_Error( 'invalid_user_permission_sync', $error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Validate Queue name. - * - * @param string $value Queue Name. - * - * @return WP_Error - */ - protected static function validate_queue( $value ) { - if ( ! isset( $value ) ) { - return new WP_Error( 'invalid_queue', 'Queue name is required', 400 ); - } - - if ( ! in_array( $value, array( 'sync', 'full_sync', 'immediate' ), true ) ) { - return new WP_Error( 'invalid_queue', 'Queue name should be sync, full_sync or immediate', 400 ); - } - return $value; - } - - /** - * Validate name is a valid Sync module. - * - * @param string $module_name Name of Sync Module. - * - * @return bool - */ - protected static function is_valid_sync_module( $module_name ) { - return in_array( - $module_name, - array( - 'comments', - 'posts', - 'terms', - 'term_relationships', - 'users', - ), - true - ); - } - - /** - * Sanitize Item Ids. - * - * @param string $item Sync item identifier. - * - * @return string|string[]|null - */ - protected static function sanitize_item_ids( $item ) { - // lets not delete any options that don't start with jpsq_sync- . - if ( ! is_string( $item ) || ! str_starts_with( $item, 'jpsq_' ) ) { - return null; - } - // Limit to A-Z,a-z,0-9,_,-,. . - return preg_replace( '/[^A-Za-z0-9-_.]/', '', $item ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php deleted file mode 100644 index 2221b850..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php +++ /dev/null @@ -1,144 +0,0 @@ -size() ) { - return new WP_Error( 'queue_size', 'The queue is empty and there is nothing to send', 400 ); - } - - $sender = Sender::get_instance(); - - // try to give ourselves as much time as possible. - set_time_limit( 0 ); - - if ( ! empty( $args['pop'] ) ) { - $buffer = new Queue_Buffer( 'pop', $queue->pop( $number_of_items ) ); - } else { - // let's delete the checkin state. - if ( $args['force'] ) { - $queue->unlock(); - } - $buffer = $this->get_buffer( $queue, $number_of_items ); - } - // Check that the $buffer is not checkout out already. - if ( is_wp_error( $buffer ) ) { - return new WP_Error( 'buffer_open', "We couldn't get the buffer it is currently checked out", 400 ); - } - - if ( ! is_object( $buffer ) ) { - return new WP_Error( 'buffer_non-object', 'Buffer is not an object', 400 ); - } - - $encode = isset( $args['encode'] ) ? $args['encode'] : true; - - Settings::set_is_syncing( true ); - list( $items_to_send, $skipped_items_ids ) = $sender->get_items_to_send( $buffer, $encode ); - Settings::set_is_syncing( false ); - - return array( - 'buffer_id' => $buffer->id, - 'items' => $items_to_send, - 'skipped_items' => $skipped_items_ids, - 'codec' => $encode ? $sender->get_codec()->name() : null, - 'sent_timestamp' => time(), - 'queue_size' => $queue->size(), - ); - } - - /** - * Adds Sync items to local property. - */ - public function jetpack_sync_send_data_listener() { - foreach ( func_get_args()[0] as $key => $item ) { - $this->items[ $key ] = $item; - } - } - - /** - * Check out a buffer of full sync actions. - * - * @return array Sync Actions to be returned to requestor - */ - public function immediate_full_sync_pull() { - // try to give ourselves as much time as possible. - set_time_limit( 0 ); - - $original_send_data_cb = array( 'Automattic\Jetpack\Sync\Actions', 'send_data' ); - $temp_send_data_cb = array( $this, 'jetpack_sync_send_data_listener' ); - - Sender::get_instance()->set_enqueue_wait_time( 0 ); - remove_filter( 'jetpack_sync_send_data', $original_send_data_cb ); - add_filter( 'jetpack_sync_send_data', $temp_send_data_cb, 10, 6 ); - Sender::get_instance()->do_full_sync(); - remove_filter( 'jetpack_sync_send_data', $temp_send_data_cb ); - add_filter( 'jetpack_sync_send_data', $original_send_data_cb, 10, 6 ); - - return array( - 'items' => $this->items, - 'codec' => Sender::get_instance()->get_codec()->name(), - 'sent_timestamp' => time(), - 'status' => Actions::get_sync_status(), - ); - } - - /** - * Checkout items out of the sync queue. - * - * @param Queue $queue Sync Queue. - * @param int $number_of_items Number of items to checkout. - * - * @return WP_Error - */ - protected function get_buffer( $queue, $number_of_items ) { - $start = time(); - $max_duration = 5; // this will try to get the buffer. - - $buffer = $queue->checkout( $number_of_items ); - $duration = time() - $start; - - while ( is_wp_error( $buffer ) && $duration < $max_duration ) { - sleep( 2 ); - $duration = time() - $start; - $buffer = $queue->checkout( $number_of_items ); - } - - if ( false === $buffer ) { - return new WP_Error( 'queue_size', 'The queue is empty and there is nothing to send', 400 ); - } - - return $buffer; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php deleted file mode 100644 index c3924516..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php +++ /dev/null @@ -1,1034 +0,0 @@ -:( - * - * @access protected - * @static - */ - protected function __construct() { - $this->set_defaults(); - $this->init(); - } - - /** - * Initialize the sender. - * Prepares the current user and initializes all sync modules. - * - * @access private - */ - private function init() { - add_action( 'jetpack_sync_before_send_queue_sync', array( $this, 'maybe_set_user_from_token' ), 1 ); - add_action( 'jetpack_sync_before_send_queue_sync', array( $this, 'maybe_clear_user_from_token' ), 20 ); - add_filter( 'jetpack_xmlrpc_unauthenticated_methods', array( $this, 'register_jetpack_xmlrpc_methods' ) ); - foreach ( Modules::get_modules() as $module ) { - $module->init_before_send(); - } - } - - /** - * Detect if this is a XMLRPC request with a valid signature. - * If so, changes the user to the new one. - * - * @access public - */ - public function maybe_set_user_from_token() { - $connection = new Manager(); - $verified_user = $connection->verify_xml_rpc_signature(); - if ( Constants::is_true( 'XMLRPC_REQUEST' ) && - ! is_wp_error( $verified_user ) - && $verified_user - ) { - $old_user = wp_get_current_user(); - $this->old_user = isset( $old_user->ID ) ? $old_user->ID : 0; - wp_set_current_user( $verified_user['user_id'] ); - } - } - - /** - * If we used to have a previous current user, revert back to it. - * - * @access public - */ - public function maybe_clear_user_from_token() { - if ( isset( $this->old_user ) ) { - wp_set_current_user( $this->old_user ); - } - } - - /** - * Retrieve the next sync time. - * - * Update @since 1.43.2 - * Sometimes when we process Sync requests in Jetpack, the server clock can be a - * bit in the future and this can lock Sync to not send stuff for a while. - * We are introducing an extra check, to make sure to limit the next_sync_time - * to be at most one hour in the future from the current time. - * - * @access public - * - * @param string $queue_name Name of the queue. - * @return float Timestamp of the next sync. - */ - public function get_next_sync_time( $queue_name ) { - $option_name = self::NEXT_SYNC_TIME_OPTION_NAME . '_' . $queue_name; - $next_sync_time = (float) get_option( $option_name, 0 ); - - $is_more_than_one_hour = ( $next_sync_time - microtime( true ) ) >= HOUR_IN_SECONDS; - - if ( $is_more_than_one_hour ) { - delete_option( $option_name ); - $next_sync_time = 0; - } - - return $next_sync_time; - } - - /** - * Set the next sync time. - * - * @access public - * - * @param int $time Timestamp of the next sync. - * @param string $queue_name Name of the queue. - * @return boolean True if update was successful, false otherwise. - */ - public function set_next_sync_time( $time, $queue_name ) { - return update_option( self::NEXT_SYNC_TIME_OPTION_NAME . '_' . $queue_name, $time, true ); - } - - /** - * Trigger a full sync. - * - * @access public - * - * @return boolean|WP_Error True if this sync sending was successful, error object otherwise. - */ - public function do_full_sync() { - $sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $sync_module'; - if ( ! $sync_module ) { - return; - } - // Full Sync Disabled. - if ( ! Settings::get_setting( 'full_sync_sender_enabled' ) ) { - return; - } - - // Don't sync if request is marked as read only. - if ( Constants::is_true( 'JETPACK_SYNC_READ_ONLY' ) ) { - return new WP_Error( 'jetpack_sync_read_only' ); - } - - // Sync not started or Sync finished. - $status = $sync_module->get_status(); - if ( false === $status['started'] || ( ! empty( $status['started'] ) && ! empty( $status['finished'] ) ) ) { - return false; - } - - $this->continue_full_sync_enqueue(); - // immediate full sync sends data in continue_full_sync_enqueue. - if ( ! $sync_module instanceof Modules\Full_Sync_Immediately ) { - return $this->do_sync_and_set_delays( $this->full_sync_queue ); - } else { - $status = $sync_module->get_status(); - // Sync not started or Sync finished. - if ( false === $status['started'] || ( ! empty( $status['started'] ) && ! empty( $status['finished'] ) ) ) { - return false; - } else { - return true; - } - } - } - - /** - * Enqueue the next sync items for sending. - * Will not be done if the current request is a WP import one. - * Will be delayed until the next sync time comes. - * - * @access private - */ - private function continue_full_sync_enqueue() { - if ( defined( 'WP_IMPORTING' ) && WP_IMPORTING ) { - return false; - } - - if ( $this->get_next_sync_time( 'full-sync-enqueue' ) > microtime( true ) ) { - return false; - } - - $full_sync_module = Modules::get_module( 'full-sync' ); - '@phan-var Modules\Full_Sync_Immediately|Modules\Full_Sync $full_sync_module'; - $full_sync_module->continue_enqueuing(); - - $this->set_next_sync_time( time() + $this->get_enqueue_wait_time(), 'full-sync-enqueue' ); - } - - /** - * Trigger incremental sync. - * - * @access public - * - * @return boolean|WP_Error True if this sync sending was successful, error object otherwise. - */ - public function do_sync() { - if ( ! Settings::is_dedicated_sync_enabled() ) { - $result = $this->do_sync_and_set_delays( $this->sync_queue ); - } else { - $result = Dedicated_Sender::spawn_sync( $this->sync_queue ); - } - - return $result; - } - - /** - * Trigger incremental sync and early exit on Dedicated Sync request. - * - * @access public - * - * @param bool $do_real_exit If we should exit at the end of the request. We should by default. - * In the context of running this in the REST API, we actually want to return an error. - * - * @return void|WP_Error - */ - public function do_dedicated_sync_and_exit( $do_real_exit = true ) { - nocache_headers(); - - if ( ! Settings::is_dedicated_sync_enabled() ) { - return new WP_Error( 'dedicated_sync_disabled', 'Dedicated Sync flow is disabled.' ); - } - - if ( ! Dedicated_Sender::is_dedicated_sync_request() ) { - return new WP_Error( 'non_dedicated_sync_request', 'Not a Dedicated Sync request.' ); - } - - /** - * Output an `OK` to show that Dedicated Sync is enabled and we can process events. - * This is used to test the feature is working. - * - * @see \Automattic\Jetpack\Sync\Dedicated_Sender::can_spawn_dedicated_sync_request - */ - // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- This is just a constant string used for Validation. - echo Dedicated_Sender::DEDICATED_SYNC_VALIDATION_STRING; - - // Try to disconnect the request as quickly as possible and process things in the background. - $this->fastcgi_finish_request(); - - /** - * Close the PHP session to free up the server threads to handle other requests while we - * send sync data with Dedicated Sync. - * - * When we spawn Dedicated Sync, we send `$_COOKIES` with the request to help out with any - * firewall and/or caching functionality that might prevent us to ping the site directly. - * - * This will cause Dedicated Sync to reuse the visitor's PHP session and lock it until the - * request finishes, which can take anywhere from 1 to 30+ seconds, depending on the server - * `max_execution_time` configuration. - * - * By closing the session we're freeing up the session, so other requests can acquire the - * lock and proceed with their own tasks. - */ - if ( session_status() === PHP_SESSION_ACTIVE ) { - session_write_close(); - } - - // Output not used right now. Try to release dedicated sync lock - Dedicated_Sender::try_release_lock_spawn_request(); - - // Actually try to send Sync events. - $result = $this->do_sync_and_set_delays( $this->sync_queue ); - - // If no errors occurred, re-spawn a dedicated Sync request. - if ( true === $result ) { - Dedicated_Sender::spawn_sync( $this->sync_queue ); - } - - if ( $do_real_exit ) { - exit( 0 ); - } - } - - /** - * Trigger sync for a certain sync queue. - * Responsible for setting next sync time. - * Will not be delayed if the current request is a WP import one. - * Will be delayed until the next sync time comes. - * - * @access public - * - * @param \Automattic\Jetpack\Sync\Queue $queue Queue object. - * - * @return boolean|WP_Error True if this sync sending was successful, error object otherwise. - */ - public function do_sync_and_set_delays( $queue ) { - // Don't sync if importing. - if ( defined( 'WP_IMPORTING' ) && WP_IMPORTING ) { - return new WP_Error( 'is_importing' ); - } - - // Don't sync if request is marked as read only. - if ( Constants::is_true( 'JETPACK_SYNC_READ_ONLY' ) ) { - return new WP_Error( 'jetpack_sync_read_only' ); - } - - if ( ! Settings::is_sender_enabled( $queue->id ) ) { - return new WP_Error( 'sender_disabled_for_queue_' . $queue->id ); - } - - if ( get_transient( self::TEMP_SYNC_DISABLE_TRANSIENT_NAME ) ) { - return new WP_Error( 'sender_temporarily_disabled_while_pulling' ); - } - - // Return early if we've gotten a retry-after header response. - $retry_time = get_option( Actions::RETRY_AFTER_PREFIX . $queue->id ); - if ( $retry_time ) { - // If expired update to false but don't send. Send will occurr in new request to avoid race conditions. - if ( microtime( true ) > $retry_time ) { - update_option( Actions::RETRY_AFTER_PREFIX . $queue->id, false, false ); - } - return new WP_Error( 'retry_after' ); - } - - // Don't sync if we are throttled. - if ( $this->get_next_sync_time( $queue->id ) > microtime( true ) ) { - return new WP_Error( 'sync_throttled' ); - } - - $start_time = microtime( true ); - - Settings::set_is_syncing( true ); - - $sync_result = $this->do_sync_for_queue( $queue ); - - Settings::set_is_syncing( false ); - - $exceeded_sync_wait_threshold = ( microtime( true ) - $start_time ) > (float) $this->get_sync_wait_threshold(); - - if ( is_wp_error( $sync_result ) ) { - if ( 'unclosed_buffer' === $sync_result->get_error_code() ) { - $this->set_next_sync_time( time() + self::QUEUE_LOCKED_SYNC_DELAY, $queue->id ); - } - if ( 'wpcom_error' === $sync_result->get_error_code() ) { - $this->set_next_sync_time( time() + self::WPCOM_ERROR_SYNC_DELAY, $queue->id ); - } - } elseif ( $exceeded_sync_wait_threshold ) { - // If we actually sent data and it took a while, wait before sending again. - $this->set_next_sync_time( time() + $this->get_sync_wait_time(), $queue->id ); - } - - return $sync_result; - } - - /** - * Retrieve the next sync items to send. - * - * @access public - * - * @param (array|\Automattic\Jetpack\Sync\Queue_Buffer) $buffer_or_items Queue buffer or array of objects. - * @param boolean $encode Whether to encode the items. - * @return array Sync items to send. - */ - public function get_items_to_send( $buffer_or_items, $encode = true ) { - // Track how long we've been processing so we can avoid request timeouts. - $start_time = microtime( true ); - $upload_size = 0; - $items_to_send = array(); - $items = is_array( $buffer_or_items ) ? $buffer_or_items : $buffer_or_items->get_items(); - if ( ! is_array( $items ) ) { - $items = array(); - } - - // Set up current screen to avoid errors rendering content. - require_once ABSPATH . 'wp-admin/includes/class-wp-screen.php'; - require_once ABSPATH . 'wp-admin/includes/screen.php'; - set_current_screen( 'sync' ); - $skipped_items_ids = array(); - /** - * We estimate the total encoded size as we go by encoding each item individually. - * This is expensive, but the only way to really know :/ - */ - foreach ( $items as $key => $item ) { - if ( ! is_array( $item ) ) { - $skipped_items_ids[] = $key; - continue; - } - - // Suspending cache addition help prevent overloading in memory cache of large sites. - wp_suspend_cache_addition( true ); - /** - * Modify the data within an action before it is serialized and sent to the server - * For example, during full sync this expands Post ID's into full Post objects, - * so that we don't have to serialize the whole object into the queue. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param array The action parameters - * @param int The ID of the user who triggered the action - */ - $item[1] = apply_filters( 'jetpack_sync_before_send_' . $item[0], $item[1], $item[2] ); - wp_suspend_cache_addition( false ); - // Serialization usage can lead to empty, null or false action_name. Lets skip as there is no information to send. - if ( empty( $item[0] ) || false === $item[1] ) { - $skipped_items_ids[] = $key; - continue; - } - $encoded_item = $this->codec->encode( $item ); - $upload_size += strlen( $encoded_item ); - if ( $upload_size > $this->upload_max_bytes && array() !== $items_to_send ) { - break; - } - $items_to_send[ $key ] = $encode ? $encoded_item : $item; - if ( microtime( true ) - $start_time > $this->max_dequeue_time ) { - break; - } - } - - return array( $items_to_send, $skipped_items_ids, $items, microtime( true ) - $start_time ); - } - - /** - * If supported, flush all response data to the client and finish the request. - * This allows for time consuming tasks to be performed without leaving the connection open. - * - * @access private - */ - private function fastcgi_finish_request() { - if ( function_exists( 'fastcgi_finish_request' ) ) { - fastcgi_finish_request(); - } - } - - /** - * Perform sync for a certain sync queue. - * - * @access public - * - * @param \Automattic\Jetpack\Sync\Queue $queue Queue object. - * - * @return boolean|WP_Error True if this sync sending was successful, error object otherwise. - */ - public function do_sync_for_queue( $queue ) { - do_action( 'jetpack_sync_before_send_queue_' . $queue->id ); - if ( $queue->size() === 0 ) { - return new WP_Error( 'empty_queue_' . $queue->id ); - } - - /** - * Now that we're sure we are about to sync, try to ignore user abort - * so we can avoid getting into a bad state. - */ - // https://plugins.trac.wordpress.org/ticket/2041 - if ( function_exists( 'ignore_user_abort' ) ) { - ignore_user_abort( true ); - } - - /* Don't make the request block till we finish, if possible. */ - if ( Constants::is_true( 'REST_REQUEST' ) || Constants::is_true( 'XMLRPC_REQUEST' ) ) { - $this->fastcgi_finish_request(); - } - - $checkout_start_time = microtime( true ); - - $buffer = $queue->checkout_with_memory_limit( $this->dequeue_max_bytes, $this->upload_max_rows ); - - if ( ! $buffer ) { - // Buffer has no items. - return new WP_Error( 'empty_buffer' ); - } - - if ( is_wp_error( $buffer ) ) { - return $buffer; - } - - $checkout_duration = microtime( true ) - $checkout_start_time; - - list( $items_to_send, $skipped_items_ids, $items, $preprocess_duration ) = $this->get_items_to_send( $buffer, true ); - if ( ! empty( $items_to_send ) ) { - /** - * Fires when data is ready to send to the server. - * Return false or WP_Error to abort the sync (e.g. if there's an error) - * The items will be automatically re-sent later - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param array $data The action buffer - * @param string $codec The codec name used to encode the data - * @param double $time The current time - * @param string $queue The queue used to send ('sync' or 'full_sync') - * @param float $checkout_duration The duration of the checkout operation. - * @param float $preprocess_duration The duration of the pre-process operation. - * @param int $queue_size The size of the sync queue at the time of processing. - */ - Settings::set_is_sending( true ); - $processed_item_ids = apply_filters( 'jetpack_sync_send_data', $items_to_send, $this->codec->name(), microtime( true ), $queue->id, $checkout_duration, $preprocess_duration, $queue->size(), $buffer->id ); - Settings::set_is_sending( false ); - } else { - $processed_item_ids = $skipped_items_ids; - $skipped_items_ids = array(); - } - - if ( 'non-blocking' !== $processed_item_ids ) { - if ( ! $processed_item_ids || is_wp_error( $processed_item_ids ) ) { - $checked_in_item_ids = $queue->checkin( $buffer ); - if ( is_wp_error( $checked_in_item_ids ) ) { - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_error_log - error_log( 'Error checking in buffer: ' . $checked_in_item_ids->get_error_message() ); - $queue->force_checkin(); - } - if ( is_wp_error( $processed_item_ids ) ) { - return new WP_Error( 'wpcom_error', $processed_item_ids->get_error_code() ); - } - - // Returning a wpcom_error is a sign to the caller that we should wait a while before syncing again. - return new WP_Error( 'wpcom_error', 'jetpack_sync_send_data_false' ); - } else { - // Detect if the last item ID was an error. - $had_wp_error = is_wp_error( end( $processed_item_ids ) ); - $wp_error = $had_wp_error ? array_pop( $processed_item_ids ) : null; - // Also checkin any items that were skipped. - if ( array() !== $skipped_items_ids ) { - $processed_item_ids = array_merge( $processed_item_ids, $skipped_items_ids ); - } - $processed_items = array_intersect_key( $items, array_flip( $processed_item_ids ) ); - /** - * Allows us to keep track of all the actions that have been sent. - * Allows us to calculate the progress of specific actions. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param array $processed_actions The actions that we send successfully. - */ - do_action( 'jetpack_sync_processed_actions', $processed_items ); - $queue->close( $buffer, $processed_item_ids ); - // Returning a WP_Error is a sign to the caller that we should wait a while before syncing again. - if ( $had_wp_error ) { - return new WP_Error( 'wpcom_error', $wp_error->get_error_code() ); - } - } - } - - return true; - } - - /** - * Immediately sends a single item without firing or enqueuing it - * - * @param string $action_name The action. - * @param array $data The data associated with the action. - * @param string $key The key to use for the action. - * - * @return array Items processed. TODO: this doesn't make much sense anymore, it should probably be just a bool. - */ - public function send_action( $action_name, $data = null, $key = null ) { - if ( ! Settings::is_sender_enabled( 'full_sync' ) ) { - return array(); - } - - // Compose the data to be sent. - $action_to_send = $this->create_action_to_send( $action_name, $data, $key ); - - list( $items_to_send, $skipped_items_ids, $items, $preprocess_duration ) = $this->get_items_to_send( $action_to_send, true ); // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - Settings::set_is_sending( true ); - $processed_item_ids = apply_filters( 'jetpack_sync_send_data', $items_to_send, $this->get_codec()->name(), microtime( true ), 'immediate-send', 0, $preprocess_duration ); - Settings::set_is_sending( false ); - - /** - * Allows us to keep track of all the actions that have been sent. - * Allows us to calculate the progress of specific actions. - * - * @param array $processed_actions The actions that we send successfully. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_sync_processed_actions', $action_to_send ); - - return $processed_item_ids; - } - - /** - * Create an synthetic action for direct sending to WPCOM during full sync (for example) - * - * @access private - * - * @param string $action_name The action. - * @param array $data The data associated with the action. - * @param string $key The key to use for the action. - * @return array An array of synthetic sync actions keyed by current microtime(true) - */ - private function create_action_to_send( $action_name, $data, $key = null ) { - return array( - $key ?? (string) microtime( true ) => array( - $action_name, - $data, - get_current_user_id(), - microtime( true ), - Settings::is_importing(), - ), - ); - } - - /** - * Returns any object that is able to be synced. - * - * @access public - * - * @param array $args the synchronized object parameters. - * @return string Encoded sync object. - */ - public function sync_object( $args ) { - // For example: posts, post, 5. - list( $module_name, $object_type, $id ) = $args; - - $sync_module = Modules::get_module( $module_name ); - $codec = $this->get_codec(); - - return $codec->encode( $sync_module->get_object_by_id( $object_type, $id ) ); - } - - /** - * Register additional sync XML-RPC methods available to Jetpack for authenticated users. - * - * @access public - * @since 1.6.3 - * @since-jetpack 7.8.0 - * - * @param array $jetpack_methods XML-RPC methods available to the Jetpack Server. - * @return array Filtered XML-RPC methods. - */ - public function register_jetpack_xmlrpc_methods( $jetpack_methods ) { - $jetpack_methods['jetpack.syncObject'] = array( $this, 'sync_object' ); - return $jetpack_methods; - } - - /** - * Get the incremental sync queue object. - * - * @access public - * - * @return \Automattic\Jetpack\Sync\Queue Queue object. - */ - public function get_sync_queue() { - return $this->sync_queue; - } - - /** - * Get the full sync queue object. - * - * @access public - * - * @return \Automattic\Jetpack\Sync\Queue Queue object. - */ - public function get_full_sync_queue() { - return $this->full_sync_queue; - } - - /** - * Get the codec object. - * - * @access public - * - * @return \Automattic\Jetpack\Sync\Codec_Interface Codec object. - */ - public function get_codec() { - return $this->codec; - } - - /** - * Determine the codec object. - * Use gzip deflate if supported. - * - * @access public - */ - public function set_codec() { - if ( function_exists( 'gzinflate' ) ) { - $this->codec = new JSON_Deflate_Array_Codec(); - } else { - $this->codec = new Simple_Codec(); - } - } - - /** - * Compute and send all the checksums. - * - * @access public - */ - public function send_checksum() { - $store = new Replicastore(); - do_action( 'jetpack_sync_checksum', $store->checksum_all() ); - } - - /** - * Reset the incremental sync queue. - * - * @access public - */ - public function reset_sync_queue() { - $this->sync_queue->reset(); - } - - /** - * Reset the full sync queue. - * - * @access public - */ - public function reset_full_sync_queue() { - $this->full_sync_queue->reset(); - } - - /** - * Set the maximum bytes to checkout without exceeding the memory limit. - * - * @access public - * - * @param int $size Maximum bytes to checkout. - */ - public function set_dequeue_max_bytes( $size ) { - $this->dequeue_max_bytes = $size; - } - - /** - * Set the maximum bytes in a single encoded item. - * - * @access public - * - * @param int $max_bytes Maximum bytes in a single encoded item. - */ - public function set_upload_max_bytes( $max_bytes ) { - $this->upload_max_bytes = $max_bytes; - } - - /** - * Set the maximum number of sync items in a single action. - * - * @access public - * - * @param int $max_rows Maximum number of sync items. - */ - public function set_upload_max_rows( $max_rows ) { - $this->upload_max_rows = $max_rows; - } - - /** - * Set the sync wait time (in seconds). - * - * @access public - * - * @param int $seconds Sync wait time. - */ - public function set_sync_wait_time( $seconds ) { - $this->sync_wait_time = $seconds; - } - - /** - * Get current sync wait time (in seconds). - * - * @access public - * - * @return int Sync wait time. - */ - public function get_sync_wait_time() { - return $this->sync_wait_time; - } - - /** - * Set the enqueue wait time (in seconds). - * - * @access public - * - * @param int $seconds Enqueue wait time. - */ - public function set_enqueue_wait_time( $seconds ) { - $this->enqueue_wait_time = $seconds; - } - - /** - * Get current enqueue wait time (in seconds). - * - * @access public - * - * @return int Enqueue wait time. - */ - public function get_enqueue_wait_time() { - return $this->enqueue_wait_time; - } - - /** - * Set the sync wait threshold (in seconds). - * - * @access public - * - * @param int $seconds Sync wait threshold. - */ - public function set_sync_wait_threshold( $seconds ) { - $this->sync_wait_threshold = $seconds; - } - - /** - * Get current sync wait threshold (in seconds). - * - * @access public - * - * @return int Sync wait threshold. - */ - public function get_sync_wait_threshold() { - return $this->sync_wait_threshold; - } - - /** - * Set the maximum time for perfirming a checkout of items from the queue (in seconds). - * - * @access public - * - * @param int $seconds Maximum dequeue time. - */ - public function set_max_dequeue_time( $seconds ) { - $this->max_dequeue_time = $seconds; - } - - /** - * Initialize the sync queues, codec and set the default settings. - * - * @access public - */ - public function set_defaults() { - $this->sync_queue = new Queue( 'sync' ); - $this->full_sync_queue = new Queue( 'full_sync' ); - $this->set_codec(); - - // Saved settings. - Settings::set_importing( null ); - $settings = Settings::get_settings(); - $this->set_dequeue_max_bytes( $settings['dequeue_max_bytes'] ); - $this->set_upload_max_bytes( $settings['upload_max_bytes'] ); - $this->set_upload_max_rows( $settings['upload_max_rows'] ); - $this->set_sync_wait_time( $settings['sync_wait_time'] ); - $this->set_enqueue_wait_time( $settings['enqueue_wait_time'] ); - $this->set_sync_wait_threshold( $settings['sync_wait_threshold'] ); - $this->set_max_dequeue_time( Defaults::get_max_sync_execution_time() ); - } - - /** - * Reset sync queues, modules and settings. - * - * @access public - */ - public function reset_data() { - $this->reset_sync_queue(); - $this->reset_full_sync_queue(); - - foreach ( Modules::get_modules() as $module ) { - $module->reset_data(); - } - // Reset Sync locks without unlocking queues since we already reset those. - Actions::reset_sync_locks( false ); - - Settings::reset_data(); - } - - /** - * Perform cleanup at the event of plugin uninstallation. - * - * @access public - */ - public function uninstall() { - // Lets delete all the other fun stuff like transient and option and the sync queue. - $this->reset_data(); - - // Delete the full sync status. - delete_option( 'jetpack_full_sync_status' ); - - // Clear the sync cron. - wp_clear_scheduled_hook( 'jetpack_sync_cron' ); - wp_clear_scheduled_hook( 'jetpack_sync_full_cron' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-server.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-server.php deleted file mode 100644 index d0a0bb3a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-server.php +++ /dev/null @@ -1,195 +0,0 @@ -:( - * - * @access public - */ - public function __construct() { - $this->codec = new JSON_Deflate_Array_Codec(); - } - - /** - * Set the codec instance. - * - * @access public - * - * @param Automattic\Jetpack\Sync\Codec_Interface $codec Codec instance. - */ - public function set_codec( Codec_Interface $codec ) { - $this->codec = $codec; - } - - /** - * Attempt to lock the request when the server receives concurrent requests from the same blog. - * - * @access public - * - * @param int $blog_id ID of the blog. - * @param int $expiry Blog lock transient lifetime. - * @return boolean True if succeeded, false otherwise. - */ - public function attempt_request_lock( $blog_id, $expiry = self::BLOG_LOCK_TRANSIENT_EXPIRY ) { - $transient_name = $this->get_concurrent_request_transient_name( $blog_id ); - $locked_time = get_site_transient( $transient_name ); - if ( $locked_time ) { - return false; - } - set_site_transient( $transient_name, microtime( true ), $expiry ); - - return true; - } - - /** - * Retrieve the blog lock transient name for a particular blog. - * - * @access public - * - * @param int $blog_id ID of the blog. - * @return string Name of the blog lock transient. - */ - private function get_concurrent_request_transient_name( $blog_id ) { - return self::BLOG_LOCK_TRANSIENT_PREFIX . $blog_id; - } - - /** - * Remove the request lock from a particular blog ID. - * - * @access public - * - * @param int $blog_id ID of the blog. - */ - public function remove_request_lock( $blog_id ) { - delete_site_transient( $this->get_concurrent_request_transient_name( $blog_id ) ); - } - - /** - * Receive and process sync events. - * - * @access public - * - * @param array $data Sync events. - * @param object $token The auth token used to invoke the API. - * @param int $sent_timestamp Timestamp (in seconds) when the actions were transmitted. - * @param string $queue_id ID of the queue from which the event was sent (`sync` or `full_sync`). - * @return array Processed sync events. - */ - public function receive( $data, $token = null, $sent_timestamp = null, $queue_id = null ) { - $start_time = microtime( true ); - if ( ! is_array( $data ) ) { - return new WP_Error( 'action_decoder_error', 'Events must be an array' ); - } - - if ( $token && ! $this->attempt_request_lock( $token->blog_id ) ) { - /** - * Fires when the server receives two concurrent requests from the same blog - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param token The token object of the misbehaving site - */ - do_action( 'jetpack_sync_multi_request_fail', $token ); - - return new WP_Error( 'concurrent_request_error', 'There is another request running for the same blog ID' ); - } - - $events = wp_unslash( array_map( array( $this->codec, 'decode' ), $data ) ); - $events_processed = array(); - - /** - * Fires when an array of actions are received from a remote Jetpack site - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param array Array of actions received from the remote site - */ - do_action( 'jetpack_sync_remote_actions', $events, $token ); - - foreach ( $events as $key => $event ) { - list( $action_name, $args, $user_id, $timestamp, $silent ) = $event; - - /** - * Fires when an action is received from a remote Jetpack site - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param string $action_name The name of the action executed on the remote site - * @param array $args The arguments passed to the action - * @param int $user_id The external_user_id who did the action - * @param bool $silent Whether the item was created via import - * @param double $timestamp Timestamp (in seconds) when the action occurred - * @param double $sent_timestamp Timestamp (in seconds) when the action was transmitted - * @param string $queue_id ID of the queue from which the event was sent (sync or full_sync) - * @param array $token The auth token used to invoke the API - */ - do_action( 'jetpack_sync_remote_action', $action_name, $args, $user_id, $silent, $timestamp, $sent_timestamp, $queue_id, $token ); - - $events_processed[] = $key; - - if ( microtime( true ) - $start_time > self::MAX_TIME_PER_REQUEST_IN_SECONDS ) { - break; - } - } - - if ( $token ) { - $this->remove_request_lock( $token->blog_id ); - } - - return $events_processed; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php deleted file mode 100644 index f248cb8b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php +++ /dev/null @@ -1,735 +0,0 @@ - true, - 'upload_max_bytes' => true, - 'upload_max_rows' => true, - 'sync_wait_time' => true, - 'sync_wait_threshold' => true, - 'enqueue_wait_time' => true, - 'max_queue_size' => true, - 'max_queue_lag' => true, - 'queue_max_writes_sec' => true, - 'post_types_blacklist' => true, - 'taxonomies_blacklist' => true, - 'disable' => true, - 'network_disable' => true, - 'render_filtered_content' => true, - 'post_meta_whitelist' => true, - 'comment_meta_whitelist' => true, - 'max_enqueue_full_sync' => true, - 'max_queue_size_full_sync' => true, - 'sync_via_cron' => true, - 'cron_sync_time_limit' => true, - 'known_importers' => true, - 'term_relationships_full_sync_item_size' => true, - 'sync_sender_enabled' => true, - 'full_sync_sender_enabled' => true, - 'full_sync_send_duration' => true, - 'full_sync_limits' => true, - 'checksum_disable' => true, - 'dedicated_sync_enabled' => true, - 'custom_queue_table_enabled' => true, - 'wpcom_rest_api_enabled' => true, - ); - - /** - * Whether WordPress is currently running an import. - * - * @access public - * @static - * - * @var null|boolean - */ - public static $is_importing; - - /** - * Whether WordPress is currently running a WP cron request. - * - * @access public - * @static - * - * @var null|boolean - */ - public static $is_doing_cron; - - /** - * Whether we're currently syncing. - * - * @access public - * @static - * - * @var null|boolean - */ - public static $is_syncing; - - /** - * Whether we're currently sending sync items. - * - * @access public - * @static - * - * @var null|boolean - */ - public static $is_sending; - - /** - * Retrieve all settings with their current values. - * - * @access public - * @static - * - * @return array All current settings. - */ - public static function get_settings() { - $settings = array(); - foreach ( array_keys( self::$valid_settings ) as $setting ) { - $settings[ $setting ] = static::get_setting( $setting ); - } - - return $settings; - } - - /** - * Fetches the setting. It saves it if the setting doesn't exist, so that it gets - * autoloaded on page load rather than re-queried every time. - * - * @access public - * @static - * - * @param string $setting The setting name. - * @return mixed The setting value. - */ - public static function get_setting( $setting ) { - if ( ! isset( self::$valid_settings[ $setting ] ) ) { - return false; - } - - if ( self::is_network_setting( $setting ) ) { - if ( is_multisite() ) { - $value = get_site_option( self::SETTINGS_OPTION_PREFIX . $setting ); - } else { - // On single sites just return the default setting. - return Defaults::get_default_setting( $setting ); - } - } else { - $value = get_option( self::SETTINGS_OPTION_PREFIX . $setting ); - } - - if ( false === $value ) { // No default value is set. - $value = Defaults::get_default_setting( $setting ); - if ( self::is_network_setting( $setting ) ) { - update_site_option( self::SETTINGS_OPTION_PREFIX . $setting, $value ); - } else { - // We set one so that it gets autoloaded. - update_option( self::SETTINGS_OPTION_PREFIX . $setting, $value, true ); - } - } - - if ( is_numeric( $value ) ) { - $value = (int) $value; - } - $default_array_value = null; - switch ( $setting ) { - case 'post_types_blacklist': - $default_array_value = Defaults::$blacklisted_post_types; - break; - case 'taxonomies_blacklist': - $default_array_value = Defaults::$blacklisted_taxonomies; - break; - case 'post_meta_whitelist': - $default_array_value = Defaults::get_post_meta_whitelist(); - break; - case 'comment_meta_whitelist': - $default_array_value = Defaults::get_comment_meta_whitelist(); - break; - case 'known_importers': - $default_array_value = Defaults::get_known_importers(); - break; - } - - if ( $default_array_value ) { - if ( is_array( $value ) ) { - $value = array_unique( array_merge( $value, $default_array_value ) ); - } else { - $value = $default_array_value; - } - } - - return $value; - } - - /** - * Change multiple settings in the same time. - * - * @access public - * @static - * - * @param array $new_settings The new settings. - */ - public static function update_settings( $new_settings ) { - $validated_settings = array_intersect_key( $new_settings, self::$valid_settings ); - foreach ( $validated_settings as $setting => $value ) { - - /** - * Custom table migration logic. - * - * This needs to happen before the option is updated, to avoid race conditions where we update the option, - * but haven't yet created the table or can't create it. - * - * On high-traffic sites this can lead to Sync trying to write in a non-existent table. - * - * So to avoid this, we're going to first try to initialize everything and then update the option. - */ - if ( 'custom_queue_table_enabled' === $setting ) { - // Need to check the current value in the database to make sure we're not doing anything weird. - $old_value = get_option( self::SETTINGS_OPTION_PREFIX . $setting, null ); - - if ( ! $old_value && $value ) { - /** - * The custom table has been enabled. - * - * - Initialize the custom table - * - Migrate the data - * - * If something fails, migrate back to the options table and clean up everything about the custom table. - */ - $init_result = Queue_Storage_Table::initialize_custom_sync_table(); - - /** - * Check if there was a problem when initializing the table. - */ - if ( is_wp_error( $init_result ) ) { - /** - * Unable to initialize the table properly. Set the value to `false` as we can't enable it. - */ - $value = false; - - /** - * Send error to WPCOM, so we can track and take an appropriate action. - */ - $data = array( - 'timestamp' => microtime( true ), - 'error_code' => $init_result->get_error_code(), - 'response_body' => $init_result->get_error_message(), - ); - - $sender = Sender::get_instance(); - $sender->send_action( 'jetpack_sync_storage_error_custom_init', $data ); - - } elseif ( ! Queue_Storage_Table::migrate_from_options_table_to_custom_table() ) { - /** - * If the migration fails, do a reverse migration and set the value to `false` as we can't - * safely enable the table. - */ - Queue_Storage_Table::migrate_from_custom_table_to_options_table(); - - // Set $value to `false` as we couldn't do the migration, and we can't continue enabling the table. - $value = false; - - /** - * Send error to WPCOM, so we can track and take an appropriate action. - */ - $data = array( - 'timestamp' => microtime( true ), - // TODO: Maybe add more details here for the migration, i.e. how many items where in the queue? - ); - - $sender = Sender::get_instance(); - $sender->send_action( 'jetpack_sync_storage_error_custom_migrate', $data ); - } - } elseif ( $old_value && ! $value ) { - if ( ! get_transient( Queue_Storage_Table::CUSTOM_QUEUE_TABLE_DISABLE_WPDB_ERROR_NOT_EXIST_FLAG ) ) { - /** - * The custom table has been disabled, migrate what we can from the custom table to the options table unless - * the custom table doesn't exist in the DB. - */ - Queue_Storage_Table::migrate_from_custom_table_to_options_table(); - } - } - } - - /** - * Regular option update and handling - */ - if ( self::is_network_setting( $setting ) ) { - if ( is_multisite() && is_main_site() ) { - $updated = update_site_option( self::SETTINGS_OPTION_PREFIX . $setting, $value ); - } - } else { - $updated = update_option( self::SETTINGS_OPTION_PREFIX . $setting, $value, true ); - } - - // If we set the disabled option to true, clear the queues. - if ( ( 'disable' === $setting || 'network_disable' === $setting ) && (bool) $value ) { - $listener = Listener::get_instance(); - $listener->get_sync_queue()->reset(); - $listener->get_full_sync_queue()->reset(); - } - - // Do not enable Dedicated Sync if we cannot spawn a Dedicated Sync request. - if ( 'dedicated_sync_enabled' === $setting && $updated && (bool) $value ) { - if ( ! Dedicated_Sender::can_spawn_dedicated_sync_request() ) { - update_option( self::SETTINGS_OPTION_PREFIX . $setting, 0, true ); - } - } - - // Do not enable wpcom rest api if we cannot send a test request. - - if ( 'wpcom_rest_api_enabled' === $setting && $updated && (bool) $value ) { - $sender = Sender::get_instance(); - $data = array( - 'timestamp' => microtime( true ), - ); - $items = $sender->send_action( 'jetpack_sync_wpcom_rest_api_enable_test', $data ); - // If we can't send a test request, disable the setting and send action tolog the error. - if ( is_wp_error( $items ) ) { - update_option( self::SETTINGS_OPTION_PREFIX . $setting, 0, true ); - $data = array( - 'timestamp' => microtime( true ), - 'response_code' => $items->get_error_code(), - 'response_body' => $items->get_error_message() ?? '', - ); - $sender->send_action( 'jetpack_sync_wpcom_rest_api_enable_error', $data ); - } - } - } - } - - /** - * Whether the specified setting is a network setting. - * - * @access public - * @static - * - * @param string $setting Setting name. - * @return boolean Whether the setting is a network setting. - */ - public static function is_network_setting( $setting ) { - return str_starts_with( $setting, 'network_' ); - } - - /** - * Returns escaped SQL for blacklisted post types. - * Can be injected directly into a WHERE clause. - * - * @access public - * @static - * - * @return string SQL WHERE clause. - */ - public static function get_blacklisted_post_types_sql() { - return 'post_type NOT IN (\'' . implode( '\', \'', array_map( 'esc_sql', static::get_setting( 'post_types_blacklist' ) ) ) . '\')'; - } - - /** - * Returns escaped values for disallowed post types. - * - * @access public - * @static - * - * @return array Post type filter values - */ - public static function get_disallowed_post_types_structured() { - return array( - 'post_type' => array( - 'operator' => 'NOT IN', - 'values' => array_map( 'esc_sql', static::get_setting( 'post_types_blacklist' ) ), - ), - ); - } - - /** - * Returns escaped SQL for blacklisted taxonomies. - * Can be injected directly into a WHERE clause. - * - * @access public - * @static - * - * @return string SQL WHERE clause. - */ - public static function get_blacklisted_taxonomies_sql() { - return "taxonomy NOT IN ('" . implode( "', '", array_map( 'esc_sql', static::get_setting( 'taxonomies_blacklist' ) ) ) . "')"; - } - - /** - * Returns escaped SQL for whitelisted taxonomies. - * Can be injected directly into a WHERE clause. - * - * @access public - * @static - * - * @return string SQL WHERE clause. - */ - public static function get_whitelisted_taxonomies_sql() { - global $wp_taxonomies; - - $allowed_taxonomies = array_keys( $wp_taxonomies ); - $allowed_taxonomies = array_diff( $allowed_taxonomies, static::get_setting( 'taxonomies_blacklist' ) ); - - return "taxonomy IN ('" . implode( "', '", array_map( 'esc_sql', $allowed_taxonomies ) ) . "')"; - } - - /** - * Returns escaped SQL for blacklisted post meta. - * Can be injected directly into a WHERE clause. - * - * @access public - * @static - * - * @return string SQL WHERE clause. - */ - public static function get_whitelisted_post_meta_sql() { - return 'meta_key IN (\'' . implode( '\', \'', array_map( 'esc_sql', static::get_setting( 'post_meta_whitelist' ) ) ) . '\')'; - } - - /** - * Returns escaped SQL for allowed post meta keys. - * - * @access public - * @static - * - * @return array Meta keys filter values - */ - public static function get_allowed_post_meta_structured() { - return array( - 'meta_key' => array( - 'operator' => 'IN', - 'values' => array_map( 'esc_sql', static::get_setting( 'post_meta_whitelist' ) ), - ), - ); - } - - /** - * Returns structured SQL clause for blacklisted taxonomies. - * - * @access public - * @static - * - * @return array taxonomies filter values - */ - public static function get_blacklisted_taxonomies_structured() { - return array( - 'taxonomy' => array( - 'operator' => 'NOT IN', - 'values' => array_map( 'esc_sql', static::get_setting( 'taxonomies_blacklist' ) ), - ), - ); - } - - /** - * Returns structured SQL clause for allowed taxonomies. - * - * @access public - * @static - * - * @return array taxonomies filter values - */ - public static function get_allowed_taxonomies_structured() { - global $wp_taxonomies; - - $allowed_taxonomies = array_keys( $wp_taxonomies ); - $allowed_taxonomies = array_diff( $allowed_taxonomies, static::get_setting( 'taxonomies_blacklist' ) ); - return array( - 'taxonomy' => array( - 'operator' => 'IN', - 'values' => array_map( 'esc_sql', $allowed_taxonomies ), - ), - ); - } - - /** - * Returns escaped SQL for blacklisted comment meta. - * Can be injected directly into a WHERE clause. - * - * @access public - * @static - * - * @return string SQL WHERE clause. - */ - public static function get_whitelisted_comment_meta_sql() { - return 'meta_key IN (\'' . implode( '\', \'', array_map( 'esc_sql', static::get_setting( 'comment_meta_whitelist' ) ) ) . '\')'; - } - - /** - * Returns SQL-escaped values for allowed post meta keys. - * - * @access public - * @static - * - * @return array Meta keys filter values - */ - public static function get_allowed_comment_meta_structured() { - return array( - 'meta_key' => array( - 'operator' => 'IN', - 'values' => array_map( 'esc_sql', static::get_setting( 'comment_meta_whitelist' ) ), - ), - ); - } - - /** - * Returns SQL-escaped values for allowed order_item meta keys. - * - * @access public - * @static - * - * @return array Meta keys filter values - */ - public static function get_allowed_order_itemmeta_structured() { - // Make sure that we only try to add the properties when the class exists. - if ( ! class_exists( '\Automattic\Jetpack\Sync\Modules\WooCommerce' ) ) { - return array(); - } - - $values = \Automattic\Jetpack\Sync\Modules\WooCommerce::$order_item_meta_whitelist; - - return array( - 'meta_key' => array( - 'operator' => 'IN', - 'values' => array_map( 'esc_sql', $values ), - ), - ); - } - - /** - * Returns escaped SQL for comments, excluding any spam comments. - * Can be injected directly into a WHERE clause. - * - * @access public - * @static - * - * @return string SQL WHERE clause. - */ - public static function get_comments_filter_sql() { - return "comment_approved <> 'spam'"; - } - - /** - * Delete any settings options and clean up the current settings state. - * - * @access public - * @static - */ - public static function reset_data() { - $valid_settings = self::$valid_settings; - foreach ( $valid_settings as $option => $value ) { - delete_option( self::SETTINGS_OPTION_PREFIX . $option ); - } - self::set_importing( null ); - self::set_doing_cron( null ); - self::set_is_syncing( null ); - self::set_is_sending( null ); - } - - /** - * Set the importing state. - * - * @access public - * @static - * - * @param boolean $is_importing Whether WordPress is currently importing. - */ - public static function set_importing( $is_importing ) { - // Set to NULL to revert to WP_IMPORTING, the standard behavior. - self::$is_importing = $is_importing; - } - - /** - * Whether WordPress is currently importing. - * - * @access public - * @static - * - * @return boolean Whether WordPress is currently importing. - */ - public static function is_importing() { - if ( self::$is_importing !== null ) { - return self::$is_importing; - } - - return defined( 'WP_IMPORTING' ) && WP_IMPORTING; - } - - /** - * Whether sync is enabled. - * - * @access public - * @static - * - * @return boolean Whether sync is enabled. - */ - public static function is_sync_enabled() { - return ! ( static::get_setting( 'disable' ) || static::get_setting( 'network_disable' ) ); - } - - /** - * Set the WP cron state. - * - * @access public - * @static - * - * @param boolean $is_doing_cron Whether WordPress is currently doing WP cron. - */ - public static function set_doing_cron( $is_doing_cron ) { - // Set to NULL to revert to WP_IMPORTING, the standard behavior. - self::$is_doing_cron = $is_doing_cron; - } - - /** - * Whether WordPress is currently doing WP cron. - * - * @access public - * @static - * - * @return boolean Whether WordPress is currently doing WP cron. - */ - public static function is_doing_cron() { - if ( self::$is_doing_cron !== null ) { - return self::$is_doing_cron; - } - - return defined( 'DOING_CRON' ) && DOING_CRON; - } - - /** - * Whether we are currently syncing. - * - * @access public - * @static - * - * @return boolean Whether we are currently syncing. - */ - public static function is_syncing() { - return (bool) self::$is_syncing || Constants::is_true( 'REST_API_REQUEST' ); - } - - /** - * Set the syncing state. - * - * @access public - * @static - * - * @param boolean $is_syncing Whether we are currently syncing. - */ - public static function set_is_syncing( $is_syncing ) { - self::$is_syncing = $is_syncing; - } - - /** - * Whether we are currently sending sync items. - * - * @access public - * @static - * - * @return boolean Whether we are currently sending sync items. - */ - public static function is_sending() { - return (bool) self::$is_sending; - } - - /** - * Set the sending state. - * - * @access public - * @static - * - * @param boolean $is_sending Whether we are currently sending sync items. - */ - public static function set_is_sending( $is_sending ) { - self::$is_sending = $is_sending; - } - - /** - * Whether should send from the queue - * - * @access public - * @static - * - * @param string $queue_id The queue identifier. - * - * @return boolean Whether sync is enabled. - */ - public static function is_sender_enabled( $queue_id ) { - return (bool) static::get_setting( $queue_id . '_sender_enabled' ); - } - - /** - * Whether checksums are enabled. - * - * @access public - * @static - * - * @return boolean Whether sync is enabled. - */ - public static function is_checksum_enabled() { - return ! (bool) static::get_setting( 'checksum_disable' ); - } - - /** - * Whether dedicated Sync flow is enabled. - * - * @access public - * @static - * - * @return boolean Whether dedicated Sync flow is enabled. - */ - public static function is_dedicated_sync_enabled() { - return (bool) static::get_setting( 'dedicated_sync_enabled' ); - } - - /** - * Whether custom queue table is enabled. - * - * @access public - * @static - * - * @return boolean Whether custom queue table is enabled. - */ - public static function is_custom_queue_table_enabled() { - return (bool) static::get_setting( 'custom_queue_table_enabled' ); - } - - /** - * Whether wpcom rest api is enabled. - * - * @access public - * @static - * - * @return boolean Whether wpcom rest api is enabled. - */ - public static function is_wpcom_rest_api_enabled() { - return (bool) static::get_setting( 'wpcom_rest_api_enabled' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php deleted file mode 100644 index cd6f2c37..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php +++ /dev/null @@ -1,62 +0,0 @@ -json_serialize( $object ) ); - } - - /** - * Encode a sync object. - * - * @access public - * - * @param string $input Encoded sync object to decode. - * @return mixed Decoded sync object. - */ - public function decode( $input ) { - // This is intentionally using base64_decode(). - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - return $this->json_unserialize( base64_decode( $input ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-users.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-users.php deleted file mode 100644 index 316df9ce..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-users.php +++ /dev/null @@ -1,152 +0,0 @@ -has_connected_user() ) { - // Kick off synchronization of user role when it changes. - add_action( 'set_user_role', array( __CLASS__, 'user_role_change' ) ); - } - } - - /** - * Synchronize connected user role changes. - * - * @access public - * @static - * - * @param int $user_id ID of the user. - */ - public static function user_role_change( $user_id ) { - $connection = new Jetpack_Connection(); - if ( $connection->is_user_connected( $user_id ) ) { - self::update_role_on_com( $user_id ); - // Try to choose a new master if we're demoting the current one. - self::maybe_demote_master_user( $user_id ); - } - } - - /** - * Retrieve the role of a user by their ID. - * - * @access public - * @static - * - * @param int $user_id ID of the user. - * @return string Role of the user. - */ - public static function get_role( $user_id ) { - if ( isset( self::$user_roles[ $user_id ] ) ) { - return self::$user_roles[ $user_id ]; - } - - $current_user_id = get_current_user_id(); - wp_set_current_user( $user_id ); - $roles = new Roles(); - $role = $roles->translate_current_user_to_role(); - wp_set_current_user( $current_user_id ); - self::$user_roles[ $user_id ] = $role; - - return $role; - } - - /** - * Retrieve the signed role of a user by their ID. - * - * @access public - * @static - * - * @param int $user_id ID of the user. - * @return string Signed role of the user. - */ - public static function get_signed_role( $user_id ) { - $connection = new Jetpack_Connection(); - return $connection->sign_role( self::get_role( $user_id ), $user_id ); - } - - /** - * Retrieve the signed role and update it in WP.com for that user. - * - * @access public - * @static - * - * @param int $user_id ID of the user. - */ - public static function update_role_on_com( $user_id ) { - $signed_role = self::get_signed_role( $user_id ); - XMLRPC_Async_Call::add_call( 'jetpack.updateRole', get_current_user_id(), $user_id, $signed_role ); - } - - /** - * Choose a new master user if we're demoting the current one. - * - * @access public - * @static - * @todo Disconnect if there is no user with enough capabilities to be the master user. - * @uses \WP_User_Query - * - * @param int $user_id ID of the user. - */ - public static function maybe_demote_master_user( $user_id ) { - $master_user_id = (int) \Jetpack_Options::get_option( 'master_user' ); - $role = self::get_role( $user_id ); - if ( $user_id === $master_user_id && 'administrator' !== $role ) { - $query = new \WP_User_Query( - array( - 'fields' => array( 'ID' ), - 'role' => 'administrator', - 'orderby' => 'ID', - 'exclude' => array( $master_user_id ), - ) - ); - $new_master = false; - $connection = new Jetpack_Connection(); - foreach ( $query->results as $result ) { - $found_user_id = absint( $result->ID ); - if ( $found_user_id && $connection->is_user_connected( $found_user_id ) ) { - $new_master = $found_user_id; - break; - } - } - - if ( $new_master ) { - \Jetpack_Options::update_option( 'master_user', $new_master ); - } - // TODO: else disconnect..? - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php deleted file mode 100644 index 23f24e95..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php +++ /dev/null @@ -1,65 +0,0 @@ -value; - } - - /** - * Get the ID of a sync item. - * - * @access private - * @static - * - * @param array $item Sync item. - * @return int Sync item ID. - */ - private static function get_item_id( $item ) { - return $item->id; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php deleted file mode 100644 index 7653f26d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php +++ /dev/null @@ -1,44 +0,0 @@ -post_parent && 0 !== $attachment_after->post_parent ) { - /** - * Fires when an existing attachment is added to a post for the first time - * - * @since 1.6.3 - * @since-jetpack 6.6.0 - * - * @param int $attachment_id Attachment ID. - * @param \WP_Post $attachment_after Attachment post object after the update. - */ - do_action( 'jetpack_sync_save_attach_attachment', $attachment_id, $attachment_after ); - } else { - /** - * Fires when the client needs to sync an updated attachment - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param int $attachment_id Attachment ID. - * @param \WP_Post $attachment_after Attachment post object after the update. - * - * Previously this action was synced using jetpack_sync_save_add_attachment action. - */ - do_action( 'jetpack_sync_save_update_attachment', $attachment_id, $attachment_after ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php deleted file mode 100644 index a8465c35..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php +++ /dev/null @@ -1,666 +0,0 @@ - 'home_url', - 'siteurl' => 'site_url', - 'jetpack_active_modules' => 'active_modules', - ); - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'functions'; - } - - /** - * Set module defaults. - * Define the callable whitelist based on whether this is a single site or a multisite installation. - * - * @access public - */ - public function set_defaults() { - if ( is_multisite() ) { - $this->callable_whitelist = array_merge( Defaults::get_callable_whitelist(), Defaults::get_multisite_callable_whitelist() ); - } else { - $this->callable_whitelist = Defaults::get_callable_whitelist(); - } - $this->force_send_callables_on_next_tick = false; // Resets here as well mostly for tests. - } - - /** - * Set module defaults at a later time. - * Reset the callable whitelist if needed to account for plugins adding the 'jetpack_sync_callable_whitelist' - * and 'jetpack_sync_multisite_callable_whitelist' filters late. - * - * @see Automattic\Jetpack\Sync\Modules::set_module_defaults - * @access public - */ - public function set_late_default() { - if ( is_multisite() ) { - $late_callables = array_merge( - apply_filters( 'jetpack_sync_callable_whitelist', array() ), - apply_filters( 'jetpack_sync_multisite_callable_whitelist', array() ) - ); - } else { - $late_callables = apply_filters( 'jetpack_sync_callable_whitelist', array() ); - } - if ( ! empty( $late_callables ) && is_array( $late_callables ) ) { - $this->callable_whitelist = array_merge( $this->callable_whitelist, $late_callables ); - } - } - - /** - * Initialize callables action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - add_action( 'jetpack_sync_callable', $callable, 10, 2 ); - add_action( 'current_screen', array( $this, 'set_plugin_action_links' ), 9999 ); // Should happen very late. - - foreach ( self::ALWAYS_SEND_UPDATES_TO_THESE_OPTIONS as $option ) { - add_action( "update_option_{$option}", array( $this, 'unlock_sync_callable' ) ); - add_action( "delete_option_{$option}", array( $this, 'unlock_sync_callable' ) ); - } - - foreach ( self::ALWAYS_SEND_UPDATES_TO_THESE_OPTIONS_NEXT_TICK as $option ) { - add_action( "update_option_{$option}", array( $this, 'unlock_sync_callable_next_tick' ) ); - add_action( "delete_option_{$option}", array( $this, 'unlock_sync_callable_next_tick' ) ); - } - - // Provide a hook so that hosts can send changes to certain callables right away. - // Especially useful when a host uses constants to change home and siteurl. - add_action( 'jetpack_sync_unlock_sync_callable', array( $this, 'unlock_sync_callable' ) ); - - // get_plugins and wp_version - // gets fired when new code gets installed, updates etc. - add_action( 'upgrader_process_complete', array( $this, 'unlock_plugin_action_link_and_callables' ) ); - add_action( 'update_option_active_plugins', array( $this, 'unlock_plugin_action_link_and_callables' ) ); - } - - /** - * Initialize callables action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_callables', $callable ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - add_action( 'jetpack_sync_before_send_queue_sync', array( $this, 'maybe_sync_callables' ) ); - - // Full sync. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_callables', array( $this, 'expand_callables' ) ); - } - - /** - * Perform module cleanup. - * Deletes any transients and options that this module uses. - * Usually triggered when uninstalling the plugin. - * - * @access public - */ - public function reset_data() { - delete_option( self::CALLABLES_CHECKSUM_OPTION_NAME ); - delete_transient( self::CALLABLES_AWAIT_TRANSIENT_NAME ); - - $url_callables = array( 'home_url', 'site_url', 'main_network_site_url' ); - foreach ( $url_callables as $callable ) { - delete_option( Functions::HTTPS_CHECK_OPTION_PREFIX . $callable ); - } - } - - /** - * Set the callable whitelist. - * - * @access public - * - * @param array $callables The new callables whitelist. - */ - public function set_callable_whitelist( $callables ) { - $this->callable_whitelist = $callables; - } - - /** - * Get the callable whitelist. - * - * @access public - * - * @return array The callables whitelist. - */ - public function get_callable_whitelist() { - return $this->callable_whitelist; - } - - /** - * Retrieve all callables as per the current callables whitelist. - * - * @access public - * - * @return array All callables. - */ - public function get_all_callables() { - // get_all_callables should run as the master user always. - $current_user_id = get_current_user_id(); - wp_set_current_user( \Jetpack_Options::get_option( 'master_user' ) ); - $callables = array_combine( - array_keys( $this->get_callable_whitelist() ), - array_map( array( $this, 'get_callable' ), array_values( $this->get_callable_whitelist() ) ) - ); - wp_set_current_user( $current_user_id ); - return $callables; - } - - /** - * Invoke a particular callable. - * Used as a wrapper to standartize invocation. - * - * @access private - * - * @param callable $callable Callable to invoke. - * @return mixed Return value of the callable, null if not callable. - */ - private function get_callable( $callable ) { - if ( is_callable( $callable ) ) { - return call_user_func( $callable ); - } else { - return null; - } - } - - /** - * Enqueue the callable actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - /** - * Tells the client to sync all callables to the server - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean Whether to expand callables (should always be true) - */ - do_action( 'jetpack_full_sync_callables', true ); - - // The number of actions enqueued, and next module state (true == done). - return array( 1, true ); - } - - /** - * Send the callable actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $send_until The timestamp until the current request can send. - * @param array $status This Module Full Sync Status. - * - * @return array This Module Full Sync Status. - */ - public function send_full_sync_actions( $config, $send_until, $status ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // we call this instead of do_action when sending immediately. - $this->send_action( 'jetpack_full_sync_callables', array( true ) ); - - // The number of actions enqueued, and next module state (true == done). - return array( 'finished' => true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_callables' ); - } - - /** - * Unlock callables so they would be available for syncing again. - * - * @access public - */ - public function unlock_sync_callable() { - delete_transient( self::CALLABLES_AWAIT_TRANSIENT_NAME ); - } - - /** - * Unlock callables on the next tick. - * Sometime the true callable values are only present on the next tick. - * When switching themes for example. - * - * @access public - */ - public function unlock_sync_callable_next_tick() { - $this->force_send_callables_on_next_tick = true; - } - - /** - * Unlock callables and plugin action links. - * - * @access public - */ - public function unlock_plugin_action_link_and_callables() { - delete_transient( self::CALLABLES_AWAIT_TRANSIENT_NAME ); - delete_transient( 'jetpack_plugin_api_action_links_refresh' ); - add_filter( 'jetpack_check_and_send_callables', '__return_true' ); - } - - /** - * Parse and store the plugin action links if on the plugins page. - * - * @uses \DOMDocument - * @uses libxml_use_internal_errors - * @uses mb_convert_encoding - * - * @access public - */ - public function set_plugin_action_links() { - if ( - ! class_exists( '\DOMDocument' ) || - ! function_exists( 'mb_convert_encoding' ) - ) { - return; - } - - $current_screeen = get_current_screen(); - - $plugins_action_links = array(); - // Is the transient lock in place? - $plugins_lock = get_transient( 'jetpack_plugin_api_action_links_refresh' ); - if ( ! empty( $plugins_lock ) && ( isset( $current_screeen->id ) && 'plugins' !== $current_screeen->id ) ) { - return; - } - $plugins = Functions::get_plugins(); - foreach ( $plugins as $plugin_file => $plugin_data ) { - /** - * Plugins often like to unset things but things break if they are not able to. - */ - $action_links = array( - 'deactivate' => '', - 'activate' => '', - 'details' => '', - 'delete' => '', - 'edit' => '', - ); - /** This filter is documented in src/wp-admin/includes/class-wp-plugins-list-table.php */ - $action_links = apply_filters( 'plugin_action_links', $action_links, $plugin_file, $plugin_data, 'all' ); - // Verify $action_links is still an array. - if ( ! is_array( $action_links ) ) { - $action_links = array(); - } - /** This filter is documented in src/wp-admin/includes/class-wp-plugins-list-table.php */ - $action_links = apply_filters( "plugin_action_links_{$plugin_file}", $action_links, $plugin_file, $plugin_data, 'all' ); - // Verify $action_links is still an array to resolve warnings from filters not returning an array. - if ( is_array( $action_links ) ) { - $action_links = array_filter( $action_links ); - } else { - $action_links = array(); - } - $formatted_action_links = null; - if ( $action_links ) { - $dom_doc = new \DOMDocument(); - foreach ( $action_links as $action_link ) { - // The @ is not enough to suppress errors when dealing with libxml, - // we have to tell it directly how we want to handle errors. - libxml_use_internal_errors( true ); - $dom_doc->loadHTML( '' . $action_link ); - libxml_use_internal_errors( false ); - - $link_elements = $dom_doc->getElementsByTagName( 'a' ); - if ( 0 === $link_elements->length ) { - continue; - } - - $link_element = $link_elements->item( 0 ); - // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - if ( $link_element instanceof \DOMElement && $link_element->hasAttribute( 'href' ) && $link_element->nodeValue ) { - $link_url = trim( $link_element->getAttribute( 'href' ) ); - - // Add the full admin path to the url if the plugin did not provide it. - $link_url_scheme = wp_parse_url( $link_url, PHP_URL_SCHEME ); - if ( empty( $link_url_scheme ) ) { - $link_url = admin_url( $link_url ); - } - - // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - $formatted_action_links[ $link_element->nodeValue ] = $link_url; - } - } - } - if ( $formatted_action_links ) { - $plugins_action_links[ $plugin_file ] = $formatted_action_links; - } - } - // Cache things for a long time. - set_transient( 'jetpack_plugin_api_action_links_refresh', time(), DAY_IN_SECONDS ); - update_option( 'jetpack_plugin_api_action_links', $plugins_action_links ); - } - - /** - * Whether a certain callable should be sent. - * - * @access public - * - * @param array $callable_checksums Callable checksums. - * @param string $name Name of the callable. - * @param string $checksum A checksum of the callable. - * @return boolean Whether to send the callable. - */ - public function should_send_callable( $callable_checksums, $name, $checksum ) { - $idc_override_callables = array( - 'main_network_site', - 'home_url', - 'site_url', - ); - if ( in_array( $name, $idc_override_callables, true ) && \Jetpack_Options::get_option( 'migrate_for_idc' ) ) { - return true; - } - - return ! $this->still_valid_checksum( $callable_checksums, $name, $checksum ); - } - - /** - * Sync the callables if we're supposed to. - * - * @access public - */ - public function maybe_sync_callables() { - $callables = $this->get_all_callables(); - if ( ! apply_filters( 'jetpack_check_and_send_callables', false ) ) { - /** - * Treating Dedicated Sync requests a bit differently from normal. We want to send callables - * normally with all Sync actions, no matter if they were with admin action origin or not, - * since Dedicated Sync runs out of bound and the requests are never coming from an admin. - */ - if ( ! is_admin() && ! Dedicated_Sender::is_dedicated_sync_request() ) { - // If we're not an admin and we're not doing cron and this isn't WP_CLI, don't sync anything. - if ( ! Settings::is_doing_cron() && ! Jetpack_Constants::get_constant( 'WP_CLI' ) ) { - return; - } - // If we're not an admin and we are doing cron, sync the Callables that are always supposed to sync ( See https://github.com/Automattic/jetpack/issues/12924 ). - $callables = $this->get_always_sent_callables(); - } - if ( get_transient( self::CALLABLES_AWAIT_TRANSIENT_NAME ) ) { - if ( $this->force_send_callables_on_next_tick ) { - $this->unlock_sync_callable(); - } - return; - } - } - - if ( empty( $callables ) ) { - return; - } - // No need to set the transiant we are trying to remove it anyways. - if ( ! $this->force_send_callables_on_next_tick ) { - set_transient( self::CALLABLES_AWAIT_TRANSIENT_NAME, microtime( true ), Defaults::$default_sync_callables_wait_time ); - } - - $callable_checksums = (array) \Jetpack_Options::get_raw_option( self::CALLABLES_CHECKSUM_OPTION_NAME, array() ); - $has_changed = false; - // Only send the callables that have changed. - foreach ( $callables as $name => $value ) { - $checksum = $this->get_check_sum( $value ); - - // Explicitly not using Identical comparison as get_option returns a string. - if ( $value !== null && $this->should_send_callable( $callable_checksums, $name, $checksum ) ) { - - // Only send callable if the non sorted checksum also does not match. - if ( $this->should_send_callable( $callable_checksums, $name, $this->get_check_sum( $value, false ) ) ) { - - /** - * Tells the client to sync a callable (aka function) to the server - * - * @param string The name of the callable - * @param mixed The value of the callable - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_sync_callable', $name, $value ); - } - - $callable_checksums[ $name ] = $checksum; - $has_changed = true; - } else { - $callable_checksums[ $name ] = $checksum; - } - } - if ( $has_changed ) { - \Jetpack_Options::update_raw_option( self::CALLABLES_CHECKSUM_OPTION_NAME, $callable_checksums ); - } - - if ( $this->force_send_callables_on_next_tick ) { - $this->unlock_sync_callable(); - } - } - - /** - * Get the callables that should always be sent, e.g. on cron. - * - * @return array Callables that should always be sent - */ - protected function get_always_sent_callables() { - $callables = $this->get_all_callables(); - $cron_callables = array(); - foreach ( self::ALWAYS_SEND_UPDATES_TO_THESE_OPTIONS as $option_name ) { - if ( array_key_exists( $option_name, $callables ) ) { - $cron_callables[ $option_name ] = $callables[ $option_name ]; - continue; - } - - // Check for the Callable name/key for the option, if different from option name. - if ( array_key_exists( $option_name, self::OPTION_NAMES_TO_CALLABLE_NAMES ) ) { - $callable_name = self::OPTION_NAMES_TO_CALLABLE_NAMES[ $option_name ]; - if ( array_key_exists( $callable_name, $callables ) ) { - $cron_callables[ $callable_name ] = $callables[ $callable_name ]; - } - } - } - return $cron_callables; - } - - /** - * Expand the callables within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The hook parameters. - */ - public function expand_callables( $args ) { - if ( $args[0] ) { - $callables = $this->get_all_callables(); - $callables_checksums = array(); - foreach ( $callables as $name => $value ) { - $callables_checksums[ $name ] = $this->get_check_sum( $value ); - } - \Jetpack_Options::update_raw_option( self::CALLABLES_CHECKSUM_OPTION_NAME, $callables_checksums ); - return $callables; - } - - return $args; - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return count( $this->get_callable_whitelist() ); - } - - /** - * Retrieve a set of callables by their IDs. - * - * @access public - * - * @param string $object_type Object type. - * @param array $ids Object IDs. - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { - if ( empty( $ids ) || empty( $object_type ) || 'callable' !== $object_type ) { - return array(); - } - - $objects = array(); - foreach ( (array) $ids as $id ) { - $object = $this->get_object_by_id( $object_type, $id ); - - if ( 'CALLABLE-DOES-NOT-EXIST' !== $object ) { - if ( 'all' === $id ) { - // If all was requested it contains all options and can simply be returned. - return $object; - } - $objects[ $id ] = $object; - } - } - - return $objects; - } - - /** - * Retrieve a callable by its name. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param string $id ID of the sync object. - * @return mixed Value of Callable. - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'callable' === $object_type ) { - - // Only whitelisted options can be returned. - if ( array_key_exists( $id, $this->get_callable_whitelist() ) ) { - // requires master user to be in context. - $current_user_id = get_current_user_id(); - wp_set_current_user( \Jetpack_Options::get_option( 'master_user' ) ); - $callable = $this->get_callable( $this->callable_whitelist[ $id ] ); - wp_set_current_user( $current_user_id ); - return $callable; - } elseif ( 'all' === $id ) { - return $this->get_all_callables(); - } - } - - return 'CALLABLE-DOES-NOT-EXIST'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php deleted file mode 100644 index 9dc1d759..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php +++ /dev/null @@ -1,594 +0,0 @@ -table' ); - return 'comments'; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - global $wpdb; - return $wpdb->comments; - } - - /** - * Retrieve a comment by its ID. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param int $id ID of the sync object. - * @return \WP_Comment|bool Filtered \WP_Comment object, or false if the object is not a comment. - */ - public function get_object_by_id( $object_type, $id ) { - $comment_id = (int) $id; - if ( 'comment' === $object_type ) { - $comment = get_comment( $comment_id ); - if ( $comment ) { - return $this->filter_comment( $comment ); - } - } - - return false; - } - - /** - * Initialize comments action listeners. - * Also responsible for initializing comment meta listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - add_action( 'wp_insert_comment', $callable, 10, 2 ); - add_action( 'deleted_comment', $callable ); - add_action( 'trashed_comment', $callable ); - add_action( 'spammed_comment', $callable ); - add_action( 'trashed_post_comments', $callable, 10, 2 ); - add_action( 'untrash_post_comments', $callable ); - add_action( 'comment_approved_to_unapproved', $callable ); - add_action( 'comment_unapproved_to_approved', $callable ); - add_action( 'jetpack_modified_comment_contents', $callable, 10, 2 ); - add_action( 'untrashed_comment', $callable, 10, 2 ); - add_action( 'unspammed_comment', $callable, 10, 2 ); - add_filter( 'wp_update_comment_data', array( $this, 'handle_comment_contents_modification' ), 10, 3 ); - - // comment actions. - add_filter( 'jetpack_sync_before_enqueue_wp_insert_comment', array( $this, 'filter_jetpack_sync_before_enqueue_wp_insert_comment' ) ); - add_filter( 'jetpack_sync_before_enqueue_deleted_comment', array( $this, 'only_allow_white_listed_comment_types' ) ); - add_filter( 'jetpack_sync_before_enqueue_trashed_comment', array( $this, 'only_allow_white_listed_comment_types' ) ); - add_filter( 'jetpack_sync_before_enqueue_untrashed_comment', array( $this, 'only_allow_white_listed_comment_types' ) ); - add_filter( 'jetpack_sync_before_enqueue_spammed_comment', array( $this, 'only_allow_white_listed_comment_types' ) ); - add_filter( 'jetpack_sync_before_enqueue_unspammed_comment', array( $this, 'only_allow_white_listed_comment_types' ) ); - - // comment status transitions. - add_filter( 'jetpack_sync_before_enqueue_comment_approved_to_unapproved', array( $this, 'only_allow_white_listed_comment_type_transitions' ) ); - add_filter( 'jetpack_sync_before_enqueue_comment_unapproved_to_approved', array( $this, 'only_allow_white_listed_comment_type_transitions' ) ); - - // Post Actions. - add_filter( 'jetpack_sync_before_enqueue_trashed_post_comments', array( $this, 'filter_blacklisted_post_types' ) ); - add_filter( 'jetpack_sync_before_enqueue_untrash_post_comments', array( $this, 'filter_blacklisted_post_types' ) ); - - /** - * Even though it's messy, we implement these hooks because - * the edit_comment hook doesn't include the data - * so this saves us a DB read for every comment event. - */ - foreach ( $this->get_whitelisted_comment_types() as $comment_type ) { - foreach ( array( 'unapproved', 'approved' ) as $comment_status ) { - $comment_action_name = "comment_{$comment_status}_{$comment_type}"; - add_action( $comment_action_name, $callable, 10, 2 ); - add_filter( - 'jetpack_sync_before_enqueue_' . $comment_action_name, - array( - $this, - 'expand_wp_insert_comment', - ) - ); - } - } - - // Listen for meta changes. - $this->init_listeners_for_meta_type( 'comment', $callable ); - $this->init_meta_whitelist_handler( 'comment', array( $this, 'filter_meta' ) ); - } - - /** - * Handler for any comment content updates. - * - * @access public - * - * @param array $new_comment The new, processed comment data. - * @param array $old_comment The old, unslashed comment data. - * @param array $new_comment_with_slashes The new, raw comment data. - * @return array The new, processed comment data. - */ - public function handle_comment_contents_modification( $new_comment, $old_comment, $new_comment_with_slashes ) { - $changes = array(); - $content_fields = array( - 'comment_author', - 'comment_author_email', - 'comment_author_url', - 'comment_content', - ); - foreach ( $content_fields as $field ) { - if ( $new_comment_with_slashes[ $field ] !== $old_comment[ $field ] ) { - $changes[ $field ] = array( $new_comment[ $field ], $old_comment[ $field ] ); - } - } - - if ( ! empty( $changes ) ) { - /** - * Signals to the sync listener that this comment's contents were modified and a sync action - * reflecting the change(s) to the content should be sent - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param int $new_comment['comment_ID'] ID of comment whose content was modified - * @param mixed $changes Array of changed comment fields with before and after values - */ - do_action( 'jetpack_modified_comment_contents', $new_comment['comment_ID'], $changes ); - } - return $new_comment; - } - - /** - * Initialize comments action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_comments', $callable ); // Also send comments meta. - } - - /** - * Gets a filtered list of comment types that sync can hook into. - * - * @access public - * - * @return array Defaults to [ '', 'trackback', 'pingback' ]. - */ - public function get_whitelisted_comment_types() { - /** - * Comment types present in this list will sync their status changes to WordPress.com. - * - * @since 1.6.3 - * @since-jetpack 7.6.0 - * - * @param array A list of comment types. - */ - return apply_filters( - 'jetpack_sync_whitelisted_comment_types', - array( '', 'comment', 'trackback', 'pingback', 'review' ) - ); - } - - /** - * Prevents any comment types that are not in the whitelist from being enqueued and sent to WordPress.com. - * - * @param array $args Arguments passed to wp_insert_comment, deleted_comment, spammed_comment, etc. - * - * @return bool or array $args Arguments passed to wp_insert_comment, deleted_comment, spammed_comment, etc. - */ - public function only_allow_white_listed_comment_types( $args ) { - $comment = false; - - if ( isset( $args[1] ) ) { - // comment object is available. - $comment = $args[1]; - } elseif ( is_numeric( $args[0] ) ) { - // comment_id is available. - $comment = get_comment( $args[0] ); - } - - if ( - isset( $comment->comment_type ) - && ! in_array( $comment->comment_type, $this->get_whitelisted_comment_types(), true ) - ) { - return false; - } - - return $args; - } - - /** - * Filter all blacklisted post types. - * - * @param array $args Hook arguments. - * @return array|false Hook arguments, or false if the post type is a blacklisted one. - */ - public function filter_blacklisted_post_types( $args ) { - $post_id = $args[0]; - $posts_module = Modules::get_module( 'posts' ); - '@phan-var Posts $posts_module'; - - if ( false !== $posts_module && ! $posts_module->is_post_type_allowed( $post_id ) ) { - return false; - } - - return $args; - } - - /** - * Prevents any comment types that are not in the whitelist from being enqueued and sent to WordPress.com. - * - * @param array $args Arguments passed to wp_{old_status}_to_{new_status}. - * - * @return bool or array $args Arguments passed to wp_{old_status}_to_{new_status} - */ - public function only_allow_white_listed_comment_type_transitions( $args ) { - $comment = $args[0]; - - if ( ! in_array( $comment->comment_type, $this->get_whitelisted_comment_types(), true ) ) { - return false; - } - - return $args; - } - - /** - * Prevents any comment types that are not in the whitelist from being enqueued and sent to WordPress.com. - * Also expands comment data before being enqueued. - * - * @param array $args Arguments passed to wp_insert_comment. - * - * @return false or array $args Arguments passed to wp_insert_comment or false if the comment type is a blacklisted one. - */ - public function filter_jetpack_sync_before_enqueue_wp_insert_comment( $args ) { - if ( false === $this->only_allow_white_listed_comment_types( $args ) ) { - return false; - } - - return $this->expand_wp_insert_comment( $args ); - } - - /** - * Whether a comment type is allowed. - * A comment type is allowed if it's present in the comment type whitelist. - * - * @param int $comment_id ID of the comment. - * @return boolean Whether the comment type is allowed. - */ - public function is_comment_type_allowed( $comment_id ) { - $comment = get_comment( $comment_id ); - - if ( isset( $comment->comment_type ) ) { - return in_array( $comment->comment_type, $this->get_whitelisted_comment_types(), true ); - } - return false; - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - - // Full sync. - $sync_module = Modules::get_module( 'full-sync' ); - if ( $sync_module instanceof Full_Sync_Immediately ) { - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_comments', array( $this, 'extract_comments_and_meta' ) ); - } else { - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_comments', array( $this, 'expand_comment_ids' ) ); - } - } - - /** - * Enqueue the comments actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - global $wpdb; - return $this->enqueue_all_ids_as_action( 'jetpack_full_sync_comments', $wpdb->comments, 'comment_ID', $this->get_where_sql( $config ), $max_items_to_enqueue, $state ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return int Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { - global $wpdb; - - $query = "SELECT count(*) FROM $wpdb->comments"; - - $where_sql = $this->get_where_sql( $config ); - if ( $where_sql ) { - $query .= ' WHERE ' . $where_sql; - } - - // TODO: Call $wpdb->prepare on the following query. - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / self::ARRAY_CHUNK_SIZE ); - } - - /** - * Retrieve the WHERE SQL clause based on the module config. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return string WHERE SQL clause, or `null` if no comments are specified in the module config. - */ - public function get_where_sql( $config ) { - if ( is_array( $config ) ) { - return 'comment_ID IN (' . implode( ',', array_map( 'intval', $config ) ) . ')'; - } - - return '1=1'; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_comments' ); - } - - /** - * Count all the actions that are going to be sent. - * - * @access public - * - * @param array $action_names Names of all the actions that will be sent. - * @return int Number of actions. - */ - public function count_full_sync_actions( $action_names ) { - return $this->count_actions( $action_names, array( 'jetpack_full_sync_comments' ) ); - } - - /** - * Expand the comment status change before the data is serialized and sent to the server. - * - * @access public - * @todo This is not used currently - let's implement it. - * - * @param array $args The hook parameters. - * @return array The expanded hook parameters. - */ - public function expand_wp_comment_status_change( $args ) { - return array( $args[0], $this->filter_comment( $args[1] ) ); - } - - /** - * Expand the comment creation before the data is added to the Sync queue. - * - * @access public - * - * @param array $args The hook parameters. - * @return array The expanded hook parameters. - */ - public function expand_wp_insert_comment( $args ) { - return array( $args[0], $this->filter_comment( $args[1] ) ); - } - - /** - * Filter a comment object to the fields we need. - * - * @access public - * - * @param \WP_Comment $comment The unfiltered comment object. - * @return \WP_Comment Filtered comment object. - */ - public function filter_comment( $comment ) { - /** - * Filters whether to prevent sending comment data to .com - * - * Passing true to the filter will prevent the comment data from being sent - * to the WordPress.com. - * Instead we pass data that will still enable us to do a checksum against the - * Jetpacks data but will prevent us from displaying the data on in the API as well as - * other services. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean false prevent post data from bing synced to WordPress.com - * @param mixed $comment WP_COMMENT object - */ - if ( apply_filters( 'jetpack_sync_prevent_sending_comment_data', false, $comment ) ) { - $blocked_comment = new \stdClass(); - $blocked_comment->comment_ID = $comment->comment_ID; - $blocked_comment->comment_date = $comment->comment_date; - $blocked_comment->comment_date_gmt = $comment->comment_date_gmt; - $blocked_comment->comment_approved = 'jetpack_sync_blocked'; - return $blocked_comment; - } - - return $comment; - } - - /** - * Whether a certain comment meta key is whitelisted for sync. - * - * @access public - * - * @param string $meta_key Comment meta key. - * @return boolean Whether the meta key is whitelisted. - */ - public function is_whitelisted_comment_meta( $meta_key ) { - return in_array( $meta_key, Settings::get_setting( 'comment_meta_whitelist' ), true ); - } - - /** - * Handler for filtering out non-whitelisted comment meta. - * - * @access public - * - * @param array $args Hook args. - * @return array|boolean False if not whitelisted, the original hook args otherwise. - */ - public function filter_meta( $args ) { - if ( $this->is_comment_type_allowed( $args[1] ) && $this->is_whitelisted_comment_meta( $args[2] ) ) { - return $args; - } - - return false; - } - - /** - * Expand the comment IDs to comment objects and meta before being serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array The expanded hook parameters. - */ - public function expand_comment_ids( $args ) { - list( $comment_ids, $previous_interval_end ) = $args; - $comments = get_comments( - array( - 'include_unapproved' => true, - 'comment__in' => $comment_ids, - 'orderby' => 'comment_ID', - 'order' => 'DESC', - ) - ); - - return array( - $comments, - $this->get_metadata( $comment_ids, 'comment', Settings::get_setting( 'comment_meta_whitelist' ) ), - $previous_interval_end, - ); - } - - /** - * Expand the comment IDs to comment objects and meta before being serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array The expanded hook parameters. - */ - public function extract_comments_and_meta( $args ) { - list( $filtered_comments, $previous_end ) = $args; - return array( - $filtered_comments['objects'], - $filtered_comments['meta'], - $previous_end, - ); - } - - /** - * Given the Module Configuration and Status return the next chunk of items to send. - * This function also expands the posts and metadata and filters them based on the maximum size constraints. - * - * @param array $config This module Full Sync configuration. - * @param array $status This module Full Sync status. - * @param int $chunk_size Chunk size. - * - * @return array - */ - public function get_next_chunk( $config, $status, $chunk_size ) { - - $comment_ids = parent::get_next_chunk( $config, $status, $chunk_size ); - // If no comment IDs were fetched, return an empty array. - if ( empty( $comment_ids ) ) { - return array(); - } - $comments = get_comments( - array( - 'comment__in' => $comment_ids, - 'orderby' => 'comment_ID', - 'order' => 'DESC', - ) - ); - // If no comments were fetched, make sure to return the expected structure so that status is updated correctly. - if ( empty( $comments ) ) { - return array( - 'object_ids' => $comment_ids, - 'objects' => array(), - 'meta' => array(), - ); - } - // Get the comment IDs from the comments that were fetched. - $fetched_comment_ids = wp_list_pluck( $comments, 'comment_ID' ); - $metadata = $this->get_metadata( $fetched_comment_ids, 'comment', Settings::get_setting( 'comment_meta_whitelist' ) ); - - // Filter the comments and metadata based on the maximum size constraints. - list( $filtered_comment_ids, $filtered_comments, $filtered_comments_metadata ) = $this->filter_objects_and_metadata_by_size( - 'comment', - $comments, - $metadata, - self::MAX_META_LENGTH, // Replace with appropriate comment meta length constant. - self::MAX_SIZE_FULL_SYNC - ); - - return array( - 'object_ids' => $filtered_comment_ids, - 'objects' => $filtered_comments, - 'meta' => $filtered_comments_metadata, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php deleted file mode 100644 index 16b42a67..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php +++ /dev/null @@ -1,345 +0,0 @@ -constants_whitelist = $constants; - } - - /** - * Get the constants whitelist. - * - * @access public - * - * @return array The constants whitelist. - */ - public function get_constants_whitelist() { - return Defaults::get_constants_whitelist(); - } - - /** - * Enqueue the constants actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - /** - * Tells the client to sync all constants to the server - * - * @param boolean Whether to expand constants (should always be true) - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_full_sync_constants', true ); - - // The number of actions enqueued, and next module state (true == done). - return array( 1, true ); - } - - /** - * Send the constants actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $send_until The timestamp until the current request can send. - * @param array $state This module Full Sync status. - * - * @return array This module Full Sync status. - */ - public function send_full_sync_actions( $config, $send_until, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // we call this instead of do_action when sending immediately. - $this->send_action( 'jetpack_full_sync_constants', array( true ) ); - - // The number of actions enqueued, and next module state (true == done). - return array( 'finished' => true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_constants' ); - } - - /** - * Sync the constants if we're supposed to. - * - * @access public - */ - public function maybe_sync_constants() { - if ( get_transient( self::CONSTANTS_AWAIT_TRANSIENT_NAME ) ) { - return; - } - - set_transient( self::CONSTANTS_AWAIT_TRANSIENT_NAME, microtime( true ), Defaults::$default_sync_constants_wait_time ); - - $constants = $this->get_all_constants(); - if ( empty( $constants ) ) { - return; - } - - $constants_checksums = (array) get_option( self::CONSTANTS_CHECKSUM_OPTION_NAME, array() ); - - foreach ( $constants as $name => $value ) { - $checksum = $this->get_check_sum( $value ); - // Explicitly not using Identical comparison as get_option returns a string. - if ( ! $this->still_valid_checksum( $constants_checksums, $name, $checksum ) && $value !== null ) { - /** - * Tells the client to sync a constant to the server - * - * @param string The name of the constant - * @param mixed The value of the constant - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_sync_constant', $name, $value ); - $constants_checksums[ $name ] = $checksum; - } else { - $constants_checksums[ $name ] = $checksum; - } - } - update_option( self::CONSTANTS_CHECKSUM_OPTION_NAME, $constants_checksums ); - } - - /** - * Retrieve all constants as per the current constants whitelist. - * Public so that we don't have to store an option for each constant. - * - * @access public - * - * @return array All constants. - */ - public function get_all_constants() { - $constants_whitelist = $this->get_constants_whitelist(); - - return array_combine( - $constants_whitelist, - array_map( array( $this, 'get_constant' ), $constants_whitelist ) - ); - } - - /** - * Retrieve the value of a constant. - * Used as a wrapper to standartize access to constants. - * - * @access private - * - * @param string $constant Constant name. - * - * @return mixed Return value of the constant. - */ - private function get_constant( $constant ) { - return ( defined( $constant ) ) ? - constant( $constant ) - : null; - } - - /** - * Expand the constants within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * - * @return array $args The hook parameters. - */ - public function expand_constants( $args ) { - if ( $args[0] ) { - $constants = $this->get_all_constants(); - $constants_checksums = array(); - foreach ( $constants as $name => $value ) { - $constants_checksums[ $name ] = $this->get_check_sum( $value ); - } - update_option( self::CONSTANTS_CHECKSUM_OPTION_NAME, $constants_checksums ); - - return $constants; - } - - return $args; - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return count( $this->get_constants_whitelist() ); - } - - /** - * Retrieve a set of constants by their IDs. - * - * @access public - * - * @param string $object_type Object type. - * @param array $ids Object IDs. - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { - if ( empty( $ids ) || empty( $object_type ) || 'constant' !== $object_type ) { - return array(); - } - - $objects = array(); - foreach ( (array) $ids as $id ) { - $object = $this->get_object_by_id( $object_type, $id ); - - if ( 'all' === $id ) { - // If all was requested it contains all options and can simply be returned. - return $object; - } - $objects[ $id ] = $object; - } - - return $objects; - } - - /** - * Retrieve a constant by its name. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param string $id ID of the sync object. - * @return mixed Value of Constant. - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'constant' === $object_type ) { - - // Only whitelisted constants can be returned. - if ( in_array( $id, $this->get_constants_whitelist(), true ) ) { - return $this->get_constant( $id ); - } elseif ( 'all' === $id ) { - return $this->get_all_constants(); - } - } - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php deleted file mode 100644 index 8d95e498..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php +++ /dev/null @@ -1,477 +0,0 @@ -is_started() && ! $this->is_finished() ) { - /** - * Fires when a full sync is cancelled. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_full_sync_cancelled' ); - $this->send_action( 'jetpack_full_sync_cancelled' ); - } - - // Remove all evidence of previous full sync items and status. - $this->reset_data(); - - if ( ! is_array( $full_sync_config ) ) { - /* - * Filter default sync config to allow injecting custom configuration. - * - * @param array $full_sync_config Sync configuration for all sync modules. - * - * @since 3.10.0 - */ - $full_sync_config = apply_filters( 'jetpack_full_sync_config', Defaults::$default_full_sync_config ); - if ( is_multisite() ) { - $full_sync_config['network_options'] = 1; - } - } - - if ( isset( $full_sync_config['users'] ) && 'initial' === $full_sync_config['users'] ) { - $users_module = Modules::get_module( 'users' ); - '@phan-var Users $users_module'; - $full_sync_config['users'] = $users_module->get_initial_sync_user_config(); - } - - $this->update_status( - array( - 'started' => time(), - 'config' => $full_sync_config, - 'progress' => $this->get_initial_progress( $full_sync_config ), - ) - ); - - $range = $this->get_content_range(); - /** - * Fires when a full sync begins. This action is serialized - * and sent to the server so that it knows a full sync is coming. - * - * @param array $full_sync_config Sync configuration for all sync modules. - * @param array $range Range of the sync items, containing min and max IDs for some item types. - * @param mixed $context The context where the full sync was initiated from. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * @since-jetpack 7.3.0 Added $range arg. - * @since 4.4.0 Added $context arg. - */ - do_action( 'jetpack_full_sync_start', $full_sync_config, $range ); - $this->send_action( 'jetpack_full_sync_start', array( $full_sync_config, $range, $context ) ); - - return true; - } - - /** - * Whether full sync has started. - * - * @access public - * - * @return boolean - */ - public function is_started() { - return (bool) $this->get_status()['started']; - } - - /** - * Retrieve the status of the current full sync. - * - * @access public - * - * @return array Full sync status. - */ - public function get_status() { - $default = array( - 'started' => false, - 'finished' => false, - 'progress' => array(), - 'config' => array(), - ); - - return wp_parse_args( \Jetpack_Options::get_raw_option( self::STATUS_OPTION ), $default ); - } - - /** - * Returns the progress percentage of a full sync. - * - * @access public - * - * @return int|null - */ - public function get_sync_progress_percentage() { - if ( ! $this->is_started() || $this->is_finished() ) { - return null; - } - $status = $this->get_status(); - if ( empty( $status['progress'] ) ) { - return null; - } - $total_items = array_reduce( - array_values( $status['progress'] ), - function ( $sum, $sync_item ) { - return isset( $sync_item['total'] ) ? ( $sum + (int) $sync_item['total'] ) : $sum; - }, - 0 - ); - $total_sent = array_reduce( - array_values( $status['progress'] ), - function ( $sum, $sync_item ) { - return isset( $sync_item['sent'] ) ? ( $sum + (int) $sync_item['sent'] ) : $sum; - }, - 0 - ); - return floor( ( $total_sent / $total_items ) * 100 ); - } - - /** - * Whether full sync has finished. - * - * @access public - * - * @return boolean - */ - public function is_finished() { - return (bool) $this->get_status()['finished']; - } - - /** - * Clear all the full sync data. - * - * @access public - */ - public function reset_data() { - $this->clear_status(); - ( new Lock() )->remove( self::LOCK_NAME, true ); - } - - /** - * Clear all the full sync status options. - * - * @access public - */ - public function clear_status() { - \Jetpack_Options::delete_raw_option( self::STATUS_OPTION ); - } - - /** - * Updates the status of the current full sync. - * - * @access public - * - * @param array $values New values to set. - * - * @return bool True if success. - */ - public function update_status( $values ) { - return $this->set_status( wp_parse_args( $values, $this->get_status() ) ); - } - - /** - * Retrieve the status of the current full sync. - * - * @param array $values New values to set. - * - * @access public - * - * @return boolean Full sync status. - */ - public function set_status( $values ) { - return \Jetpack_Options::update_raw_option( self::STATUS_OPTION, $values ); - } - - /** - * Given an initial Full Sync configuration get the initial status. - * - * @param array $full_sync_config Full sync configuration. - * - * @return array Initial Sent status. - */ - public function get_initial_progress( $full_sync_config ) { - // Set default configuration, calculate totals, and save configuration if totals > 0. - $status = array(); - foreach ( $full_sync_config as $name => $config ) { - $module = Modules::get_module( $name ); - if ( ! $module ) { - continue; - } - $status[ $name ] = array( - 'total' => $module->total( $config ), - 'sent' => 0, - 'finished' => false, - ); - } - - return $status; - } - - /** - * Get the range for content (posts and comments) to sync. - * - * @access private - * - * @return array Array of range (min ID, max ID, total items) for all content types. - */ - private function get_content_range() { - $range = array(); - $config = $this->get_status()['config']; - // Add range only when syncing all objects. - if ( true === isset( $config['posts'] ) && $config['posts'] ) { - $range['posts'] = $this->get_range( 'posts' ); - } - - if ( true === isset( $config['comments'] ) && $config['comments'] ) { - $range['comments'] = $this->get_range( 'comments' ); - } - - return $range; - } - - /** - * Get the range (min ID, max ID and total items) of items to sync. - * - * @access public - * - * @param string $type Type of sync item to get the range for. - * - * @return array Array of min ID, max ID and total items in the range. - */ - public function get_range( $type ) { - global $wpdb; - if ( ! in_array( $type, array( 'comments', 'posts' ), true ) ) { - return array(); - } - - switch ( $type ) { - case 'posts': - $table = $wpdb->posts; - $id = 'ID'; - $where_sql = Settings::get_blacklisted_post_types_sql(); - - break; - case 'comments': - $table = $wpdb->comments; - $id = 'comment_ID'; - $where_sql = Settings::get_comments_filter_sql(); - break; - } - - // TODO: Call $wpdb->prepare on the following query. - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $results = $wpdb->get_results( "SELECT MAX({$id}) as max, MIN({$id}) as min, COUNT({$id}) as count FROM {$table} WHERE {$where_sql}" ); - if ( isset( $results[0] ) ) { - return $results[0]; - } - - return array(); - } - - /** - * Continue sending instead of enqueueing. - * - * @access public - */ - public function continue_enqueuing() { - $this->continue_sending(); - } - - /** - * Continue sending. - * - * @access public - */ - public function continue_sending() { - // Return early if Full Sync is not running. - if ( ! $this->is_started() || $this->get_status()['finished'] ) { - return; - } - - // Return early if we've gotten a retry-after header response. - $retry_time = get_option( Actions::RETRY_AFTER_PREFIX . 'immediate-send' ); - if ( $retry_time ) { - // If expired delete but don't send. Send will occurr in new request to avoid race conditions. - if ( microtime( true ) > $retry_time ) { - update_option( Actions::RETRY_AFTER_PREFIX . 'immediate-send', false, false ); - } - return false; - } - - // Obtain send Lock. - $lock = new Lock(); - $lock_expiration = $lock->attempt( self::LOCK_NAME ); - - // Return if unable to obtain lock. - if ( false === $lock_expiration ) { - return; - } - - // Send Full Sync actions. - $success = $this->send(); - - // Remove lock. - if ( $success ) { - $lock->remove( self::LOCK_NAME, $lock_expiration ); - } - } - - /** - * Immediately send the next items to full sync. - * - * @access public - */ - public function send() { - $config = $this->get_status()['config']; - - $max_duration = Settings::get_setting( 'full_sync_send_duration' ); - $send_until = microtime( true ) + $max_duration; - - $progress = $this->get_status()['progress']; - - $started = $this->get_status()['started']; - - foreach ( $this->get_remaining_modules_to_send() as $module ) { - $progress[ $module->name() ] = $module->send_full_sync_actions( $config[ $module->name() ], $progress[ $module->name() ], $send_until ); - if ( isset( $progress[ $module->name() ]['error'] ) ) { - unset( $progress[ $module->name() ]['error'] ); - $this->update_status( array( 'progress' => $progress ) ); - return false; - } elseif ( ! $progress[ $module->name() ]['finished'] ) { - $this->update_status( array( 'progress' => $progress ) ); - return true; - } - if ( $this->get_status()['started'] !== $started ) { - // Full sync was restarted, stop sending. - return false; - } - } - - $this->send_full_sync_end(); - $this->update_status( array( 'progress' => $progress ) ); - return true; - } - - /** - * Get Modules that are configured to Full Sync and haven't finished sending - * - * @return array - */ - public function get_remaining_modules_to_send() { - $status = $this->get_status(); - $remaining_modules = array(); - foreach ( array_keys( $status['config'] ) as $module_name ) { - $module = Modules::get_module( $module_name ); - if ( ! $module ) { - continue; - } - if ( isset( $status['progress'][ $module_name ]['finished'] ) && - true === $status['progress'][ $module_name ]['finished'] ) { - continue; - } - // Ensure that 'constants', 'options', and 'callables' are sent first. - if ( in_array( $module_name, array( 'network_options', 'options', 'functions', 'constants' ), true ) ) { - array_unshift( $remaining_modules, $module ); - } else { - $remaining_modules[] = $module; - } - } - return $remaining_modules; - } - - /** - * Send 'jetpack_full_sync_end' and update 'finished' status. - * - * @access public - */ - public function send_full_sync_end() { - $range = $this->get_content_range(); - - /** - * Fires when a full sync ends. This action is serialized - * and sent to the server. - * - * @param string $checksum Deprecated since 7.3.0 - @see https://github.com/Automattic/jetpack/pull/11945/ - * @param array $range Range of the sync items, containing min and max IDs for some item types. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * @since-jetpack 7.3.0 Added $range arg. - */ - do_action( 'jetpack_full_sync_end', '', $range ); - $this->send_action( 'jetpack_full_sync_end', array( '', $range ) ); - - // Setting autoload to true means that it's faster to check whether we should continue enqueuing. - $this->update_status( array( 'finished' => time() ) ); - } - - /** - * Empty Function as we don't close buffers on Immediate Full Sync. - * - * @param array $actions an array of actions, ignored for queueless sync. - */ - public function update_sent_progress_action( $actions ) { } // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php deleted file mode 100644 index 64ef388b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php +++ /dev/null @@ -1,731 +0,0 @@ -is_started() && ! $this->is_finished(); - - // Remove all evidence of previous full sync items and status. - $this->reset_data(); - - if ( $was_already_running ) { - /** - * Fires when a full sync is cancelled. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - */ - do_action( 'jetpack_full_sync_cancelled' ); - } - - $this->update_status_option( 'started', time() ); - $this->update_status_option( 'params', $module_configs ); - - $enqueue_status = array(); - $full_sync_config = array(); - $include_empty = false; - $empty = array(); - - // Default value is full sync. - if ( ! is_array( $module_configs ) ) { - $module_configs = array(); - $include_empty = true; - foreach ( Modules::get_modules() as $module ) { - $module_configs[ $module->name() ] = true; - } - } - - // Set default configuration, calculate totals, and save configuration if totals > 0. - foreach ( Modules::get_modules() as $module ) { - $module_name = $module->name(); - $module_config = isset( $module_configs[ $module_name ] ) ? $module_configs[ $module_name ] : false; - - if ( ! $module_config ) { - continue; - } - - if ( 'users' === $module_name && 'initial' === $module_config ) { - '@phan-var Users $module'; - $module_config = $module->get_initial_sync_user_config(); - } - - $enqueue_status[ $module_name ] = false; - - $total_items = $module->estimate_full_sync_actions( $module_config ); - - // If there's information to process, configure this module. - if ( $total_items !== null && $total_items > 0 ) { - $full_sync_config[ $module_name ] = $module_config; - $enqueue_status[ $module_name ] = array( - $total_items, // Total. - 0, // Queued. - false, // Current state. - ); - } elseif ( $include_empty && 0 === $total_items ) { - $empty[ $module_name ] = true; - } - } - - $this->set_config( $full_sync_config ); - $this->set_enqueue_status( $enqueue_status ); - - $range = $this->get_content_range( $full_sync_config ); - /** - * Fires when a full sync begins. This action is serialized - * and sent to the server so that it knows a full sync is coming. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * @since-jetpack 7.3.0 Added $range arg. - * @since-jetpack 7.4.0 Added $empty arg. - * - * @param array $full_sync_config Sync configuration for all sync modules. - * @param array $range Range of the sync items, containing min and max IDs for some item types. - * @param array $empty The modules with no items to sync during a full sync. - */ - do_action( 'jetpack_full_sync_start', $full_sync_config, $range, $empty ); - - $this->continue_enqueuing( $full_sync_config ); - - return true; - } - - /** - * Enqueue the next items to sync. - * - * @access public - * - * @param array $configs Full sync configuration for all sync modules. - */ - public function continue_enqueuing( $configs = null ) { - // Return early if not in progress. - if ( ! $this->get_status_option( 'started' ) || $this->get_status_option( 'queue_finished' ) ) { - return; - } - - // Attempt to obtain lock. - $lock = new Lock(); - $lock_expiration = $lock->attempt( self::ENQUEUE_LOCK_NAME ); - - // Return if unable to obtain lock. - if ( false === $lock_expiration ) { - return; - } - - // enqueue full sync actions. - $this->enqueue( $configs ); - - // Remove lock. - $lock->remove( self::ENQUEUE_LOCK_NAME, $lock_expiration ); - } - - /** - * Get Modules that are configured to Full Sync and haven't finished enqueuing - * - * @param array $configs Full sync configuration for all sync modules. - * - * @return array - */ - public function get_remaining_modules_to_enqueue( $configs ) { - $enqueue_status = $this->get_enqueue_status(); - return array_filter( - Modules::get_modules(), - /** - * Select configured and not finished modules. - * - * @param Module $module - * @return bool - */ - function ( $module ) use ( $configs, $enqueue_status ) { - // Skip module if not configured for this sync or module is done. - if ( ! isset( $configs[ $module->name() ] ) ) { - return false; - } - if ( ! $configs[ $module->name() ] ) { - return false; - } - if ( isset( $enqueue_status[ $module->name() ][2] ) ) { - if ( true === $enqueue_status[ $module->name() ][2] ) { - return false; - } - } - - return true; - } - ); - } - - /** - * Enqueue the next items to sync. - * - * @access public - * - * @param array $configs Full sync configuration for all sync modules. - */ - public function enqueue( $configs = null ) { - if ( ! $configs ) { - $configs = $this->get_config(); - } - - $enqueue_status = $this->get_enqueue_status(); - $full_sync_queue = new Queue( 'full_sync' ); - $available_queue_slots = Settings::get_setting( 'max_queue_size_full_sync' ) - $full_sync_queue->size(); - - if ( $available_queue_slots <= 0 ) { - return; - } - - $remaining_items_to_enqueue = min( Settings::get_setting( 'max_enqueue_full_sync' ), $available_queue_slots ); - - /** - * If a module exits early (e.g. because it ran out of full sync queue slots, or we ran out of request time) - * then it should exit early - */ - foreach ( $this->get_remaining_modules_to_enqueue( $configs ) as $module ) { - list( $items_enqueued, $next_enqueue_state ) = $module->enqueue_full_sync_actions( $configs[ $module->name() ], $remaining_items_to_enqueue, $enqueue_status[ $module->name() ][2] ); - - $enqueue_status[ $module->name() ][2] = $next_enqueue_state; - - // If items were processed, subtract them from the limit. - if ( $items_enqueued !== null && $items_enqueued > 0 ) { - $enqueue_status[ $module->name() ][1] += $items_enqueued; - $remaining_items_to_enqueue -= $items_enqueued; - } - - if ( 0 >= $remaining_items_to_enqueue || true !== $next_enqueue_state ) { - $this->set_enqueue_status( $enqueue_status ); - return; - } - } - - $this->queue_full_sync_end( $configs ); - $this->set_enqueue_status( $enqueue_status ); - } - - /** - * Enqueue 'jetpack_full_sync_end' and update 'queue_finished' status. - * - * @access public - * - * @param array $configs Full sync configuration for all sync modules. - */ - public function queue_full_sync_end( $configs ) { - $range = $this->get_content_range( $configs ); - - /** - * Fires when a full sync ends. This action is serialized - * and sent to the server. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * @since-jetpack 7.3.0 Added $range arg. - * - * @param string $checksum Deprecated since 7.3.0 - @see https://github.com/Automattic/jetpack/pull/11945/ - * @param array $range Range of the sync items, containing min and max IDs for some item types. - */ - do_action( 'jetpack_full_sync_end', '', $range ); - - // Setting autoload to true means that it's faster to check whether we should continue enqueuing. - $this->update_status_option( 'queue_finished', time(), true ); - } - - /** - * Get the range (min ID, max ID and total items) of items to sync. - * - * @access public - * - * @param string $type Type of sync item to get the range for. - * @return array Array of min ID, max ID and total items in the range. - */ - public function get_range( $type ) { - global $wpdb; - if ( ! in_array( $type, array( 'comments', 'posts' ), true ) ) { - return array(); - } - - switch ( $type ) { - case 'posts': - $table = $wpdb->posts; - $id = 'ID'; - $where_sql = Settings::get_blacklisted_post_types_sql(); - - break; - case 'comments': - $table = $wpdb->comments; - $id = 'comment_ID'; - $where_sql = Settings::get_comments_filter_sql(); - break; - } - - // TODO: Call $wpdb->prepare on the following query. - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $results = $wpdb->get_results( "SELECT MAX({$id}) as max, MIN({$id}) as min, COUNT({$id}) as count FROM {$table} WHERE {$where_sql}" ); - if ( isset( $results[0] ) ) { - return $results[0]; - } - - return array(); - } - - /** - * Get the range for content (posts and comments) to sync. - * - * @access private - * - * @param array $config Full sync configuration for this all sync modules. - * @return array Array of range (min ID, max ID, total items) for all content types. - */ - private function get_content_range( $config ) { - $range = array(); - // Only when we are sending the whole range do we want to send also the range. - if ( true === isset( $config['posts'] ) && $config['posts'] ) { - $range['posts'] = $this->get_range( 'posts' ); - } - - if ( true === isset( $config['comments'] ) && $config['comments'] ) { - $range['comments'] = $this->get_range( 'comments' ); - } - return $range; - } - - /** - * Update the progress after sync modules actions have been processed on the server. - * - * @access public - * - * @param array $actions Actions that have been processed on the server. - */ - public function update_sent_progress_action( $actions ) { - // Quick way to map to first items with an array of arrays. - $actions_with_counts = array_count_values( array_filter( array_map( array( $this, 'get_action_name' ), $actions ) ) ); - - // Total item counts for each action. - $actions_with_total_counts = $this->get_actions_totals( $actions ); - - if ( ! $this->is_started() || $this->is_finished() ) { - return; - } - - if ( isset( $actions_with_counts['jetpack_full_sync_start'] ) ) { - $this->update_status_option( 'send_started', time() ); - } - - foreach ( Modules::get_modules() as $module ) { - $module_actions = $module->get_full_sync_actions(); - $status_option_name = "{$module->name()}_sent"; - $total_option_name = "{$status_option_name}_total"; - $items_sent = $this->get_status_option( $status_option_name, 0 ); - $items_sent_total = $this->get_status_option( $total_option_name, 0 ); - - foreach ( $module_actions as $module_action ) { - if ( isset( $actions_with_counts[ $module_action ] ) ) { - $items_sent += $actions_with_counts[ $module_action ]; - } - - if ( ! empty( $actions_with_total_counts[ $module_action ] ) ) { - $items_sent_total += $actions_with_total_counts[ $module_action ]; - } - } - - if ( $items_sent > 0 ) { - $this->update_status_option( $status_option_name, $items_sent ); - } - - if ( 0 !== $items_sent_total ) { - $this->update_status_option( $total_option_name, $items_sent_total ); - } - } - - if ( isset( $actions_with_counts['jetpack_full_sync_end'] ) ) { - $this->update_status_option( 'finished', time() ); - } - } - - /** - * Returns the progress percentage of a full sync. - * - * @access public - * - * @return int|null - */ - public function get_sync_progress_percentage() { - if ( ! $this->is_started() || $this->is_finished() ) { - return null; - } - $status = $this->get_status(); - if ( ! $status['queue'] || ! $status['sent'] || ! $status['total'] ) { - return null; - } - $queued_multiplier = 0.1; - $sent_multiplier = 0.9; - $count_queued = array_reduce( - $status['queue'], - function ( $sum, $value ) { - return $sum + $value; - }, - 0 - ); - $count_sent = array_reduce( - $status['sent'], - function ( $sum, $value ) { - return $sum + $value; - }, - 0 - ); - $count_total = array_reduce( - $status['total'], - function ( $sum, $value ) { - return $sum + $value; - }, - 0 - ); - $percent_queued = ( $count_queued / $count_total ) * $queued_multiplier * 100; - $percent_sent = ( $count_sent / $count_total ) * $sent_multiplier * 100; - return ceil( $percent_queued + $percent_sent ); - } - - /** - * Get the name of the action for an item in the sync queue. - * - * @access public - * - * @param array $queue_item Item of the sync queue. - * @return string|boolean Name of the action, false if queue item is invalid. - */ - public function get_action_name( $queue_item ) { - if ( is_array( $queue_item ) && isset( $queue_item[0] ) ) { - return $queue_item[0]; - } - return false; - } - - /** - * Retrieve the total number of items we're syncing in a particular queue item (action). - * `$queue_item[1]` is expected to contain chunks of items, and `$queue_item[1][0]` - * represents the first (and only) chunk of items to sync in that action. - * - * @access public - * - * @param array $queue_item Item of the sync queue that corresponds to a particular action. - * @return int Total number of items in the action. - */ - public function get_action_totals( $queue_item ) { - if ( is_array( $queue_item ) && isset( $queue_item[1][0] ) ) { - if ( is_array( $queue_item[1][0] ) ) { - // Let's count the items we sync in this action. - return count( $queue_item[1][0] ); - } - // -1 indicates that this action syncs all items by design. - return -1; - } - return 0; - } - - /** - * Retrieve the total number of items for a set of actions, grouped by action name. - * - * @access public - * - * @param array $actions An array of actions. - * @return array An array, representing the total number of items, grouped per action. - */ - public function get_actions_totals( $actions ) { - $totals = array(); - - foreach ( $actions as $action ) { - $name = $this->get_action_name( $action ); - $action_totals = $this->get_action_totals( $action ); - if ( ! isset( $totals[ $name ] ) ) { - $totals[ $name ] = 0; - } - $totals[ $name ] += $action_totals; - } - - return $totals; - } - - /** - * Whether full sync has started. - * - * @access public - * - * @return boolean - */ - public function is_started() { - return (bool) $this->get_status_option( 'started' ); - } - - /** - * Whether full sync has finished. - * - * @access public - * - * @return boolean - */ - public function is_finished() { - return (bool) $this->get_status_option( 'finished' ); - } - - /** - * Retrieve the status of the current full sync. - * - * @access public - * - * @return array Full sync status. - */ - public function get_status() { - $status = array( - 'started' => $this->get_status_option( 'started' ), - 'queue_finished' => $this->get_status_option( 'queue_finished' ), - 'send_started' => $this->get_status_option( 'send_started' ), - 'finished' => $this->get_status_option( 'finished' ), - 'sent' => array(), - 'sent_total' => array(), - 'queue' => array(), - 'config' => $this->get_status_option( 'params' ), - 'total' => array(), - ); - - $enqueue_status = $this->get_enqueue_status(); - - foreach ( Modules::get_modules() as $module ) { - $name = $module->name(); - - if ( ! isset( $enqueue_status[ $name ] ) ) { - continue; - } - - list( $total, $queued ) = $enqueue_status[ $name ]; - - if ( $total ) { - $status['total'][ $name ] = $total; - } - - if ( $queued ) { - $status['queue'][ $name ] = $queued; - } - - $sent = $this->get_status_option( "{$name}_sent" ); - if ( $sent ) { - $status['sent'][ $name ] = $sent; - } - - $sent_total = $this->get_status_option( "{$name}_sent_total" ); - if ( $sent_total ) { - $status['sent_total'][ $name ] = $sent_total; - } - } - - return $status; - } - - /** - * Clear all the full sync status options. - * - * @access public - */ - public function clear_status() { - $prefix = self::STATUS_OPTION_PREFIX; - \Jetpack_Options::delete_raw_option( "{$prefix}_started" ); - \Jetpack_Options::delete_raw_option( "{$prefix}_params" ); - \Jetpack_Options::delete_raw_option( "{$prefix}_queue_finished" ); - \Jetpack_Options::delete_raw_option( "{$prefix}_send_started" ); - \Jetpack_Options::delete_raw_option( "{$prefix}_finished" ); - - $this->delete_enqueue_status(); - - foreach ( Modules::get_modules() as $module ) { - \Jetpack_Options::delete_raw_option( "{$prefix}_{$module->name()}_sent" ); - \Jetpack_Options::delete_raw_option( "{$prefix}_{$module->name()}_sent_total" ); - } - } - - /** - * Clear all the full sync data. - * - * @access public - */ - public function reset_data() { - $this->clear_status(); - $this->delete_config(); - ( new Lock() )->remove( self::ENQUEUE_LOCK_NAME, true ); - - $listener = Listener::get_instance(); - $listener->get_full_sync_queue()->reset(); - } - - /** - * Get the value of a full sync status option. - * - * @access private - * - * @param string $name Name of the option. - * @param mixed $default Default value of the option. - * @return mixed Option value. - */ - private function get_status_option( $name, $default = null ) { - $value = \Jetpack_Options::get_raw_option( self::STATUS_OPTION_PREFIX . "_$name", $default ); - - return is_numeric( $value ) ? (int) $value : $value; - } - - /** - * Update the value of a full sync status option. - * - * @access private - * - * @param string $name Name of the option. - * @param mixed $value Value of the option. - * @param boolean $autoload Whether the option should be autoloaded at the beginning of the request. - */ - private function update_status_option( $name, $value, $autoload = false ) { - \Jetpack_Options::update_raw_option( self::STATUS_OPTION_PREFIX . "_$name", $value, $autoload ); - } - - /** - * Set the full sync enqueue status. - * - * @access private - * - * @param array $new_status The new full sync enqueue status. - */ - private function set_enqueue_status( $new_status ) { - \Jetpack_Options::update_raw_option( 'jetpack_sync_full_enqueue_status', $new_status ); - } - - /** - * Delete full sync enqueue status. - * - * @access private - * - * @return boolean Whether the status was deleted. - */ - private function delete_enqueue_status() { - return \Jetpack_Options::delete_raw_option( 'jetpack_sync_full_enqueue_status' ); - } - - /** - * Retrieve the current full sync enqueue status. - * - * @access private - * - * @return array Full sync enqueue status. - */ - public function get_enqueue_status() { - return \Jetpack_Options::get_raw_option( 'jetpack_sync_full_enqueue_status' ); - } - - /** - * Set the full sync enqueue configuration. - * - * @access private - * - * @param array $config The new full sync enqueue configuration. - */ - private function set_config( $config ) { - \Jetpack_Options::update_raw_option( 'jetpack_sync_full_config', $config ); - } - - /** - * Delete full sync configuration. - * - * @access private - * - * @return boolean Whether the configuration was deleted. - */ - private function delete_config() { - return \Jetpack_Options::delete_raw_option( 'jetpack_sync_full_config' ); - } - - /** - * Retrieve the current full sync enqueue config. - * - * @access private - * - * @return array Full sync enqueue config. - */ - private function get_config() { - return \Jetpack_Options::get_raw_option( 'jetpack_sync_full_config' ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php deleted file mode 100644 index f5f8543a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php +++ /dev/null @@ -1,220 +0,0 @@ - 'jetpack_sync_import_start', - 'import_done' => 'jetpack_sync_import_end', - 'import_end' => 'jetpack_sync_import_end', - ); - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'import'; - } - - /** - * Initialize imports action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - add_action( 'export_wp', $callable ); - add_action( 'jetpack_sync_import_start', $callable, 10, 2 ); - add_action( 'jetpack_sync_import_end', $callable, 10, 2 ); - - // WordPress. - add_action( 'import_start', array( $this, 'sync_import_action' ) ); - - // Movable type, RSS, Livejournal. - add_action( 'import_done', array( $this, 'sync_import_action' ) ); - - // WordPress, Blogger, Livejournal, woo tax rate. - add_action( 'import_end', array( $this, 'sync_import_action' ) ); - } - - /** - * Set module defaults. - * Define an empty list of synced actions for us to fill later. - * - * @access public - */ - public function set_defaults() { - $this->synced_actions = array(); - } - - /** - * Generic handler for import actions. - * - * @access public - * - * @param string $importer Either a string reported by the importer, the class name of the importer, or 'unknown'. - */ - public function sync_import_action( $importer ) { - $import_action = current_filter(); - // Map action to event name. - $sync_action = self::$import_sync_action_map[ $import_action ]; - - // Only sync each action once per import. - if ( array_key_exists( $sync_action, $this->synced_actions ) && $this->synced_actions[ $sync_action ] ) { - return; - } - - // Mark this action as synced. - $this->synced_actions[ $sync_action ] = true; - - // Prefer self-reported $importer value. - if ( ! $importer ) { - // Fall back to inferring by calling class name. - $importer = self::get_calling_importer_class(); - } - - // Get $importer from known_importers. - $known_importers = Settings::get_setting( 'known_importers' ); - if ( is_string( $importer ) && isset( $known_importers[ $importer ] ) ) { - $importer = $known_importers[ $importer ]; - } - - $importer_name = $this->get_importer_name( $importer ); - - switch ( $sync_action ) { - case 'jetpack_sync_import_start': - /** - * Used for syncing the start of an import - * - * @since 1.6.3 - * @since-jetpack 7.3.0 - * - * @module sync - * - * @param string $importer Either a string reported by the importer, the class name of the importer, or 'unknown'. - * @param string $importer_name The name reported by the importer, or 'Unknown Importer'. - */ - do_action( 'jetpack_sync_import_start', $importer, $importer_name ); - break; - - case 'jetpack_sync_import_end': - /** - * Used for syncing the end of an import - * - * @since 1.6.3 - * @since-jetpack 7.3.0 - * - * @module sync - * - * @param string $importer Either a string reported by the importer, the class name of the importer, or 'unknown'. - * @param string $importer_name The name reported by the importer, or 'Unknown Importer'. - */ - do_action( 'jetpack_sync_import_end', $importer, $importer_name ); - break; - } - } - - /** - * Retrieve the name of the importer. - * - * @access private - * - * @param string $importer Either a string reported by the importer, the class name of the importer, or 'unknown'. - * @return string Name of the importer, or "Unknown Importer" if importer is unknown. - */ - private function get_importer_name( $importer ) { - $importers = get_importers(); - return isset( $importers[ $importer ] ) ? $importers[ $importer ][0] : 'Unknown Importer'; - } - - /** - * Determine the class that extends `WP_Importer` which is responsible for - * the current action. Designed to be used within an action handler. - * - * @access private - * @static - * - * @return string The name of the calling class, or 'unknown'. - */ - private static function get_calling_importer_class() { - // If WP_Importer doesn't exist, neither will any importer that extends it. - if ( ! class_exists( 'WP_Importer', false ) ) { - return 'unknown'; - } - - $action = current_filter(); - $backtrace = debug_backtrace( false ); //phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace - - $do_action_pos = -1; - $backtrace_len = count( $backtrace ); - for ( $i = 0; $i < $backtrace_len; $i++ ) { - // Find the location in the stack of the calling action. - if ( 'do_action' === $backtrace[ $i ]['function'] && $action === $backtrace[ $i ]['args'][0] ) { - $do_action_pos = $i; - break; - } - } - - // If the action wasn't called, the calling class is unknown. - if ( -1 === $do_action_pos ) { - return 'unknown'; - } - - // Continue iterating the stack looking for a caller that extends WP_Importer. - for ( $i = $do_action_pos + 1; $i < $backtrace_len; $i++ ) { - // If there is no class on the trace, continue. - if ( ! isset( $backtrace[ $i ]['class'] ) ) { - continue; - } - - $class_name = $backtrace[ $i ]['class']; - - // Check if the class extends WP_Importer. - if ( class_exists( $class_name, false ) ) { - $parents = class_parents( $class_name, false ); - if ( $parents && in_array( 'WP_Importer', $parents, true ) ) { - return $class_name; - } - } - } - - // If we've exhausted the stack without a match, the calling class is unknown. - return 'unknown'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php deleted file mode 100644 index bf6c5620..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php +++ /dev/null @@ -1,146 +0,0 @@ -nav_items_just_added[] = $nav_item_id; - /** - * Helps sync log that a new menu item was added. - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param int $menu_id ID of the menu. - * @param array $menu_data An array of menu data. - * @param int $nav_item_id ID of the new menu item. - * @param array $nav_item_args Arguments used to add the menu item. - */ - do_action( 'jetpack_sync_updated_nav_menu_add_item', $menu_id, $menu_data, $nav_item_id, $nav_item_args ); - } - - /** - * Nav menu item update handler. - * - * @access public - * - * @param int $menu_id ID of the menu. - * @param int $nav_item_id ID of the new menu item. - * @param array $nav_item_args Arguments used to update the menu item. - */ - public function update_nav_menu_update_item( $menu_id, $nav_item_id, $nav_item_args ) { - if ( in_array( $nav_item_id, $this->nav_items_just_added, true ) ) { - return; - } - $menu_data = wp_get_nav_menu_object( $menu_id ); - /** - * Helps sync log that an update to the menu item happened. - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param int $menu_id ID of the menu. - * @param array $menu_data An array of menu data. - * @param int $nav_item_id ID of the new menu item. - * @param array $nav_item_args Arguments used to update the menu item. - */ - do_action( 'jetpack_sync_updated_nav_menu_update_item', $menu_id, $menu_data, $nav_item_id, $nav_item_args ); - } - - /** - * Remove menu items that have already been saved from the "just added" list. - * - * @access public - * - * @param int $nav_item_id ID of the new menu item. - * @param \WP_Post $post_after Nav menu item post object after the update. - */ - public function remove_just_added_menu_item( $nav_item_id, $post_after ) { - if ( 'nav_menu_item' !== $post_after->post_type ) { - return; - } - $this->nav_items_just_added = array_diff( $this->nav_items_just_added, array( $nav_item_id ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php deleted file mode 100644 index 2360db3b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php +++ /dev/null @@ -1,192 +0,0 @@ -prepare call to use placeholders. - * - * @param string $object_type The type of object for which we retrieve meta. Either 'post' or 'comment'. - * @param array $config Must include 'meta_key' and 'ids' keys. - * - * @return array - */ - public function get_objects_by_id( $object_type, $config ) { - global $wpdb; - - $table = _get_meta_table( $object_type ); - - if ( ! $table ) { - return array(); - } - - if ( ! is_array( $config ) ) { - return array(); - } - - $object_id_column = $object_type . '_id'; - $object_key_pairs = array(); - - foreach ( $config as $item ) { - if ( isset( $item['id'] ) && isset( $item['meta_key'] ) ) { - $object_key_pairs[ (int) $item['id'] ][] = (string) $item['meta_key']; - } - } - - $meta_objects = array(); - $where_sql = ''; - $current_query_length = 0; - - foreach ( $object_key_pairs as $object_id => $keys ) { - $keys_placeholders = implode( ',', array_fill( 0, count( $keys ), '%s' ) ); - $where_condition = trim( - $wpdb->prepare( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "( `$object_id_column` = %d AND meta_key IN ( $keys_placeholders ) )", - array_merge( array( $object_id ), $keys ) - ) - ); - - $where_sql = empty( $where_sql ) ? $where_condition : $where_sql . ' OR ' . $where_condition; - - $current_query_length += strlen( $where_sql ); - - if ( $current_query_length > self::MAX_DB_QUERY_LENGTH ) { - $meta_objects = $this->fetch_prepared_meta_from_db( $object_type, $where_sql, $meta_objects ); - $where_sql = ''; - $current_query_length = 0; - } - } - - if ( ! empty( $where_sql ) ) { - $meta_objects = $this->fetch_prepared_meta_from_db( $object_type, $where_sql, $meta_objects ); - } - - return $meta_objects; - } - - /** - * Get a single Meta Result. - * - * @param string $object_type post, comment, term, user. - * @param int|null $id Object ID. - * @param string|null $meta_key Meta Key. - * - * @return mixed|null - */ - public function get_object_by_id( $object_type, $id = null, $meta_key = null ) { - global $wpdb; - - if ( ! is_int( $id ) || ! is_string( $meta_key ) ) { - return null; - } - - $table = _get_meta_table( $object_type ); - - if ( ! $table ) { - return null; - } - - $object_id_column = $object_type . '_id'; - - // Sanitize so that the array only has integer values. - $where_condition = $wpdb->prepare( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "{$object_id_column} = %d AND meta_key = %s", - $id, - $meta_key - ); - - $meta_objects = $this->fetch_prepared_meta_from_db( $object_type, $where_condition ); - - $key = $id . '-' . $meta_key; - - return $meta_objects[ $key ] ?? null; - } - - /** - * Fetch meta from DB and return them in a standard format. - * - * @param string $object_type The meta object type, eg 'post', 'user' etc. - * @param string $where Prepared SQL 'where' statement. - * @param array $meta_objects An existing array of meta to populate. Defaults to an empty array. - * @return array - */ - private function fetch_prepared_meta_from_db( $object_type, $where, $meta_objects = array() ) { - global $wpdb; - - $table = _get_meta_table( $object_type ); - $object_id_column = $object_type . '_id'; - - $meta = $wpdb->get_results( // phpcs:ignore WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT * FROM {$table} WHERE {$where}", - ARRAY_A - ); - - if ( ! is_wp_error( $meta ) && ! empty( $meta ) ) { - foreach ( $meta as $meta_entry ) { - $object_id = $meta_entry[ $object_id_column ]; - $meta_key = $meta_entry['meta_key']; - $key = $object_id . '-' . $meta_key; - - if ( ! isset( $meta_objects[ $key ] ) ) { - $meta_objects[ $key ] = array(); - } - - $meta_objects[ $key ][] = $this->get_prepared_meta_object( $object_type, $meta_entry ); - } - } - - return $meta_objects; - } - - /** - * Accepts a DB meta entry and returns it in a standard format. - * - * @param string $object_type The meta object type, eg 'post', 'user' etc. - * @param array $meta_entry A meta array. - * @return array - */ - private function get_prepared_meta_object( $object_type, $meta_entry ) { - $object_id_column = $object_type . '_id'; - - if ( 'post' === $object_type && strlen( $meta_entry['meta_value'] ) >= Posts::MAX_META_LENGTH ) { - $meta_entry['meta_value'] = ''; - } - - return array( - 'meta_type' => $object_type, - 'meta_id' => $meta_entry['meta_id'], - 'meta_key' => $meta_entry['meta_key'], - 'meta_value' => $meta_entry['meta_value'], - 'object_id' => $meta_entry[ $object_id_column ], - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php deleted file mode 100644 index 2d92f325..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php +++ /dev/null @@ -1,779 +0,0 @@ - length. - * Default Setting : 2MB. - * - * @access public - * - * @var int - */ - const MAX_META_LENGTH = 2000000; - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - abstract public function name(); - - /** - * The id field in the database. - * - * @access public - * - * @return string - */ - public function id_field() { - return 'ID'; - } - - /** - * The table name. - * - * @access public - * - * @return string|bool - * @deprecated since 3.11.0 Use table() instead. - */ - public function table_name() { - _deprecated_function( __METHOD__, '3.11.0', 'Automattic\\Jetpack\\Sync\\Module->table' ); - return false; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - return false; - } - - /** - * The full sync action name for this module. - * - * @access public - * - * @return string - */ - public function full_sync_action_name() { - return 'jetpack_full_sync_' . $this->name(); - } - - // phpcs:disable VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - - /** - * Retrieve a sync object by its ID. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param int $id ID of the sync object. - * @return mixed Object, or false if the object is invalid. - */ - public function get_object_by_id( $object_type, $id ) { - return false; - } - - /** - * Initialize callables action listeners. - * Override these to set up listeners and set/reset data/defaults. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - } - - /** - * Initialize module action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - } - - /** - * Set module defaults. - * - * @access public - */ - public function set_defaults() { - } - - /** - * Perform module cleanup. - * Usually triggered when uninstalling the plugin. - * - * @access public - */ - public function reset_data() { - } - - /** - * Enqueue the module actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - // In subclasses, return the number of actions enqueued, and next module state (true == done). - return array( null, true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { - // In subclasses, return the number of items yet to be enqueued. - return null; - } - - // phpcs:enable VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array(); - } - - /** - * Get the number of actions that we care about. - * - * @access protected - * - * @param array $action_names Action names we're interested in. - * @param array $actions_to_count Unfiltered list of actions we want to count. - * @return array Number of actions that we're interested in. - */ - protected function count_actions( $action_names, $actions_to_count ) { - return count( array_intersect( $action_names, $actions_to_count ) ); - } - - /** - * Calculate the checksum of one or more values. - * - * @access protected - * - * @param mixed $values Values to calculate checksum for. - * @param bool $sort If $values should have ksort called on it. - * @return int The checksum. - */ - protected function get_check_sum( $values, $sort = true ) { - // Associative array order changes the generated checksum value. - if ( $sort && is_array( $values ) ) { - $this->recursive_ksort( $values ); - } - return crc32( wp_json_encode( Functions::json_wrap( $values ) ) ); - } - - /** - * Recursively call ksort on an Array - * - * @param array $values Array. - */ - private function recursive_ksort( &$values ) { - ksort( $values ); - foreach ( $values as &$value ) { - if ( is_array( $value ) ) { - $this->recursive_ksort( $value ); - } - } - } - - /** - * Whether a particular checksum in a set of checksums is valid. - * - * @access protected - * - * @param array $sums_to_check Array of checksums. - * @param string $name Name of the checksum. - * @param int $new_sum Checksum to compare against. - * @return boolean Whether the checksum is valid. - */ - protected function still_valid_checksum( $sums_to_check, $name, $new_sum ) { - if ( isset( $sums_to_check[ $name ] ) && $sums_to_check[ $name ] === $new_sum ) { - return true; - } - - return false; - } - - /** - * Enqueue all items of a sync type as an action. - * - * @access protected - * - * @param string $action_name Name of the action. - * @param string $table_name Name of the database table. - * @param string $id_field Name of the ID field in the database. - * @param string $where_sql The SQL WHERE clause to filter to the desired items. - * @param int $max_items_to_enqueue Maximum number of items to enqueue in the same time. - * @param boolean $state Whether enqueueing has finished. - * @return array Array, containing the number of chunks and TRUE, indicating enqueueing has finished. - */ - protected function enqueue_all_ids_as_action( $action_name, $table_name, $id_field, $where_sql, $max_items_to_enqueue, $state ) { - global $wpdb; - - if ( ! $where_sql ) { - $where_sql = '1 = 1'; - } - - $items_per_page = 1000; - $page = 1; - $chunk_count = 0; - $previous_interval_end = $state ? $state : '~0'; - $listener = Listener::get_instance(); - - // Count down from max_id to min_id so we get newest posts/comments/etc first. - // phpcs:ignore Generic.CodeAnalysis.AssignmentInCondition.FoundInWhileCondition, WordPress.DB.PreparedSQL.InterpolatedNotPrepared - while ( $ids = $wpdb->get_col( "SELECT {$id_field} FROM {$table_name} WHERE {$where_sql} AND {$id_field} < {$previous_interval_end} ORDER BY {$id_field} DESC LIMIT {$items_per_page}" ) ) { - // Request posts in groups of N for efficiency. - $chunked_ids = array_chunk( $ids, self::ARRAY_CHUNK_SIZE ); - - // If we hit our row limit, process and return. - if ( $chunk_count + count( $chunked_ids ) >= $max_items_to_enqueue ) { - $remaining_items_count = $max_items_to_enqueue - $chunk_count; - $remaining_items = array_slice( $chunked_ids, 0, $remaining_items_count ); - $remaining_items_with_previous_interval_end = $this->get_chunks_with_preceding_end( $remaining_items, $previous_interval_end ); - $listener->bulk_enqueue_full_sync_actions( $action_name, $remaining_items_with_previous_interval_end ); - - $last_chunk = end( $remaining_items ); - return array( $remaining_items_count + $chunk_count, end( $last_chunk ) ); - } - $chunked_ids_with_previous_end = $this->get_chunks_with_preceding_end( $chunked_ids, $previous_interval_end ); - - $listener->bulk_enqueue_full_sync_actions( $action_name, $chunked_ids_with_previous_end ); - - $chunk_count += count( $chunked_ids ); - ++$page; - // The $ids are ordered in descending order. - $previous_interval_end = end( $ids ); - } - - if ( $wpdb->last_error ) { - // return the values that were passed in so all these chunks get retried. - return array( $max_items_to_enqueue, $state ); - } - - return array( $chunk_count, true ); - } - - /** - * Given the Module Full Sync Configuration and Status return the next chunk of items to send. - * - * @param array $config This module Full Sync configuration. - * @param array $status This module Full Sync status. - * @param int $chunk_size Chunk size. - * - * @return array|object|null - */ - public function get_next_chunk( $config, $status, $chunk_size ) { - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery - global $wpdb; - return $wpdb->get_col( - " - SELECT {$this->id_field()} - FROM {$this->table()} - WHERE {$this->get_where_sql( $config )} - AND {$this->id_field()} < {$status['last_sent']} - ORDER BY {$this->id_field()} - DESC LIMIT {$chunk_size} - " - ); - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery - } - - /** - * Return last_item to send for Module Full Sync Configuration. - * - * @param array $config This module Full Sync configuration. - * - * @return array|object|null - */ - public function get_last_item( $config ) { - global $wpdb; - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - return $wpdb->get_var( - " - SELECT {$this->id_field()} - FROM {$this->table()} - WHERE {$this->get_where_sql( $config )} - ORDER BY {$this->id_field()} - LIMIT 1 - " - ); - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - } - - /** - * Return the initial last sent object. - * - * @return string|array initial status. - */ - public function get_initial_last_sent() { - return '~0'; - } - - /** - * Immediately send all items of a sync type as an action. - * - * @access protected - * - * @param string $config Full sync configuration for this module. - * @param array $status the current module full sync status. - * @param float $send_until timestamp until we want this request to send full sync events. - * - * @return array Status, the module full sync status updated. - */ - public function send_full_sync_actions( $config, $status, $send_until ) { - global $wpdb; - - if ( empty( $status['last_sent'] ) ) { - $status['last_sent'] = $this->get_initial_last_sent(); - } - - $limits = Settings::get_setting( 'full_sync_limits' )[ $this->name() ] ?? - Defaults::get_default_setting( 'full_sync_limits' )[ $this->name() ] ?? - array( - 'max_chunks' => 10, - 'chunk_size' => 100, - ); - - $chunks_sent = 0; - - $last_item = $this->get_last_item( $config ); - - while ( $chunks_sent < $limits['max_chunks'] && microtime( true ) < $send_until ) { - $objects = $this->get_next_chunk( $config, $status, $limits['chunk_size'] ); - - if ( $wpdb->last_error ) { - $status['error'] = true; - return $status; - } - - if ( empty( $objects ) ) { - $status['finished'] = true; - return $status; - } - // If we have objects as a key it means get_next_chunk is being overridden, we need to check for it being an empty array. - // In case it is an empty array, we should not send the action or increase the chunks_sent, we just need to update the status. - if ( ! isset( $objects['objects'] ) || array() !== $objects['objects'] ) { - $key = $this->full_sync_action_name() . '_' . crc32( wp_json_encode( $status['last_sent'] ) ); - $result = $this->send_action( $this->full_sync_action_name(), array( $objects, $status['last_sent'] ), $key ); - if ( is_wp_error( $result ) || $wpdb->last_error ) { - $status['error'] = true; - return $status; - } - ++$chunks_sent; - } - - // Updated the sent and last_sent status. - $status = $this->set_send_full_sync_actions_status( $status, $objects ); - if ( $last_item === $status['last_sent'] ) { - $status['finished'] = true; - return $status; - } - } - - return $status; - } - - /** - * Set the status of the full sync action based on the objects that were sent. - * Used to update the status of the module after sending a chunk of objects. - * Since Full Sync logic chunking relies on order of items being processed in descending order, we need to sort - * due to some modules (e.g. WooCommerce) changing the order while getting the objects. - * - * @access protected - * - * @param array $status This module Full Sync status. - * @param array $objects This module Full Sync objects. - * - * @return array The updated status. - */ - protected function set_send_full_sync_actions_status( $status, $objects ) { - - $object_ids = $objects['object_ids'] ?? $objects; - $status['last_sent'] = end( $object_ids ); - $status['sent'] += count( $object_ids ); - return $status; - } - - /** - * Immediately sends a single item without firing or enqueuing it - * - * @param string $action_name The action. - * @param array $data The data associated with the action. - * @param string $key The key to use for the action. - */ - public function send_action( $action_name, $data = null, $key = null ) { - $sender = Sender::get_instance(); - return $sender->send_action( $action_name, $data, $key ); - } - - /** - * Retrieve chunk IDs with previous interval end. - * - * @access protected - * - * @param array $chunks All remaining items. - * @param int $previous_interval_end The last item from the previous interval. - * @return array Chunk IDs with the previous interval end. - */ - protected function get_chunks_with_preceding_end( $chunks, $previous_interval_end ) { - $chunks_with_ends = array(); - foreach ( $chunks as $chunk ) { - $chunks_with_ends[] = array( - 'ids' => $chunk, - 'previous_end' => $previous_interval_end, - ); - // Chunks are ordered in descending order. - $previous_interval_end = end( $chunk ); - } - return $chunks_with_ends; - } - - /** - * Get metadata of a particular object type within the designated meta key whitelist. - * - * @access protected - * - * @todo Refactor to use $wpdb->prepare() on the SQL query. - * - * @param array $ids Object IDs. - * @param string $meta_type Meta type. - * @param array $meta_key_whitelist Meta key whitelist. - * @return array Unserialized meta values. - */ - protected function get_metadata( $ids, $meta_type, $meta_key_whitelist ) { - global $wpdb; - $table = _get_meta_table( $meta_type ); - $id = $meta_type . '_id'; - if ( ! $table ) { - return array(); - } - - $private_meta_whitelist_sql = "'" . implode( "','", array_map( 'esc_sql', $meta_key_whitelist ) ) . "'"; - - return array_map( - array( $this, 'unserialize_meta' ), - $wpdb->get_results( - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared, WordPress.DB.PreparedSQL.NotPrepared - "SELECT $id, meta_key, meta_value, meta_id FROM $table WHERE $id IN ( " . implode( ',', wp_parse_id_list( $ids ) ) . ' )' . - " AND meta_key IN ( $private_meta_whitelist_sql ) ", - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared, WordPress.DB.PreparedSQL.NotPrepared - OBJECT - ) - ); - } - - /** - * Initialize listeners for the particular meta type. - * - * @access public - * - * @param string $meta_type Meta type. - * @param callable $callable Action handler callable. - */ - public function init_listeners_for_meta_type( $meta_type, $callable ) { - add_action( "added_{$meta_type}_meta", $callable, 10, 4 ); - add_action( "updated_{$meta_type}_meta", $callable, 10, 4 ); - add_action( "deleted_{$meta_type}_meta", $callable, 10, 4 ); - } - - /** - * Initialize meta whitelist handler for the particular meta type. - * - * @access public - * - * @param string $meta_type Meta type. - * @param callable $whitelist_handler Action handler callable. - */ - public function init_meta_whitelist_handler( $meta_type, $whitelist_handler ) { - add_filter( "jetpack_sync_before_enqueue_added_{$meta_type}_meta", $whitelist_handler ); - add_filter( "jetpack_sync_before_enqueue_updated_{$meta_type}_meta", $whitelist_handler ); - add_filter( "jetpack_sync_before_enqueue_deleted_{$meta_type}_meta", $whitelist_handler ); - } - - /** - * Retrieve the term relationships for the specified object IDs. - * - * @access protected - * - * @todo This feels too specific to be in the abstract sync Module class. Move it? - * - * @param array $ids Object IDs. - * @return array Term relationships - object ID and term taxonomy ID pairs. - */ - protected function get_term_relationships( $ids ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - return $wpdb->get_results( "SELECT object_id, term_taxonomy_id FROM $wpdb->term_relationships WHERE object_id IN ( " . implode( ',', wp_parse_id_list( $ids ) ) . ' )', OBJECT ); - } - - /** - * Unserialize the value of a meta object, if necessary. - * - * @access public - * - * @param object $meta Meta object. - * @return object Meta object with possibly unserialized value. - */ - public function unserialize_meta( $meta ) { - $meta->meta_value = maybe_unserialize( $meta->meta_value ); - return $meta; - } - - /** - * Retrieve a set of objects by their IDs. - * - * @access public - * - * @param string $object_type Object type. - * @param array $ids Object IDs. - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { - if ( empty( $ids ) || empty( $object_type ) ) { - return array(); - } - - $objects = array(); - foreach ( (array) $ids as $id ) { - $object = $this->get_object_by_id( $object_type, $id ); - - // Only add object if we have the object. - if ( $object ) { - $objects[ $id ] = $object; - } - } - - return $objects; - } - - /** - * Gets a list of minimum and maximum object ids for each batch based on the given batch size. - * - * @access public - * - * @param int $batch_size The batch size for objects. - * @param string|bool $where_sql The sql where clause minus 'WHERE', or false if no where clause is needed. - * - * @return array|bool An array of min and max ids for each batch. FALSE if no table can be found. - */ - public function get_min_max_object_ids_for_batches( $batch_size, $where_sql = false ) { - - if ( ! $this->table() ) { - return false; - } - - $results = array(); - $table = $this->table(); - $current_max = 0; - $current_min = 1; - $id_field = $this->id_field(); - $replicastore = new Replicastore(); - - $total = $replicastore->get_min_max_object_id( - $id_field, - $table, - $where_sql, - false - ); - - while ( $total->max > $current_max ) { - $where = $where_sql ? - $where_sql . " AND $id_field > $current_max" : - "$id_field > $current_max"; - $result = $replicastore->get_min_max_object_id( - $id_field, - $table, - $where, - $batch_size - ); - if ( empty( $result->min ) && empty( $result->max ) ) { - // Our query produced no min and max. We can assume the min from the previous query, - // and the total max we found in the initial query. - $current_max = (int) $total->max; - $result = (object) array( - 'min' => $current_min, - 'max' => $current_max, - ); - } else { - $current_min = (int) $result->min; - $current_max = (int) $result->max; - } - $results[] = $result; - } - - return $results; - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { - global $wpdb; - $table = $this->table(); - $where = $this->get_where_sql( $config ); - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - return (int) $wpdb->get_var( "SELECT COUNT(*) FROM $table WHERE $where" ); - } - - /** - * Retrieve the WHERE SQL clause based on the module config. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return string WHERE SQL clause, or `null` if no comments are specified in the module config. - */ - public function get_where_sql( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return '1=1'; - } - - /** - * Filters objects and metadata based on maximum size constraints. - * It always allows the first object with its metadata, even if they exceed the limit. - * - * @access public - * - * @param string $type The type of objects to filter (e.g., 'post' or 'comment'). - * @param array $objects The array of objects to filter (e.g., posts or comments). - * @param array $metadata The array of metadata to filter. - * @param int $max_meta_size Maximum size for individual objects. - * @param int $max_total_size Maximum combined size for objects and metadata. - * @return array An array containing the filtered object IDs, filtered objects, and filtered metadata. - */ - public function filter_objects_and_metadata_by_size( $type, $objects, $metadata, $max_meta_size, $max_total_size ) { - $filtered_objects = array(); - $filtered_metadata = array(); - $filtered_object_ids = array(); - $current_size = 0; - - foreach ( $objects as $object ) { - $object_size = strlen( maybe_serialize( $object ) ); - $current_metadata = array(); - $metadata_size = 0; - $id_field = $this->id_field(); - $object_id = (int) ( is_object( $object ) ? $object->{$id_field} : $object[ $id_field ] ); - - foreach ( $metadata as $key => $metadata_item ) { - if ( (int) $metadata_item->{$type . '_id'} === $object_id ) { - $metadata_item_size = strlen( maybe_serialize( $metadata_item->meta_value ) ); - if ( $metadata_item_size >= $max_meta_size ) { - $metadata_item->meta_value = ''; // Trim metadata if too large. - } - $current_metadata[] = $metadata_item; - $metadata_size += $metadata_item_size >= $max_meta_size ? 0 : $metadata_item_size; - - if ( ! empty( $filtered_object_ids ) && ( $current_size + $object_size + $metadata_size ) > $max_total_size ) { - break 2; // Exit both loops. - } - unset( $metadata[ $key ] ); - } - } - - // Always allow the first object with metadata. - if ( empty( $filtered_object_ids ) || ( $current_size + $object_size + $metadata_size ) <= $max_total_size ) { - $filtered_object_ids[] = strval( is_object( $object ) ? $object->{$id_field} : $object[ $id_field ] ); - $filtered_objects[] = $object; - $filtered_metadata = array_merge( $filtered_metadata, $current_metadata ); - $current_size += $object_size + $metadata_size; - } else { - break; - } - } - - return array( - $filtered_object_ids, - $filtered_objects, - $filtered_metadata, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php deleted file mode 100644 index 4fbfa3be..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php +++ /dev/null @@ -1,251 +0,0 @@ -network_options_whitelist = Defaults::$default_network_options_whitelist; - } - - /** - * Enqueue the network options actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - /** - * Tells the client to sync all options to the server - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean Whether to expand options (should always be true) - */ - do_action( 'jetpack_full_sync_network_options', true ); - - // The number of actions enqueued, and next module state (true == done). - return array( 1, true ); - } - - /** - * Send the network options actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $send_until The timestamp until the current request can send. - * @param array $state This module Full Sync status. - * - * @return array This module Full Sync status. - */ - public function send_full_sync_actions( $config, $send_until, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // we call this instead of do_action when sending immediately. - $this->send_action( 'jetpack_full_sync_network_options', array( true ) ); - - // The number of actions enqueued, and next module state (true == done). - return array( 'finished' => true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_network_options' ); - } - - /** - * Retrieve all network options as per the current network options whitelist. - * - * @access public - * - * @return array All network options. - */ - public function get_all_network_options() { - $options = array(); - foreach ( $this->network_options_whitelist as $option ) { - $options[ $option ] = get_site_option( $option ); - } - - return $options; - } - - /** - * Set the network options whitelist. - * - * @access public - * - * @param array $options The new network options whitelist. - */ - public function set_network_options_whitelist( $options ) { - $this->network_options_whitelist = $options; - } - - /** - * Get the network options whitelist. - * - * @access public - * - * @return array The network options whitelist. - */ - public function get_network_options_whitelist() { - return $this->network_options_whitelist; - } - - /** - * Reject non-whitelisted network options. - * - * @access public - * - * @param array $args The hook parameters. - * @return array|false $args The hook parameters, false if not a whitelisted network option. - */ - public function whitelist_network_options( $args ) { - if ( ! $this->is_whitelisted_network_option( $args[0] ) ) { - return false; - } - - return $args; - } - - /** - * Whether the option is a whitelisted network option. - * - * @access public - * - * @param string $option Option name. - * @return boolean True if this is a whitelisted network option. - */ - public function is_whitelisted_network_option( $option ) { - return in_array( $option, $this->network_options_whitelist, true ); - } - - /** - * Expand the network options within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The hook parameters. - */ - public function expand_network_options( $args ) { - if ( $args[0] ) { - return $this->get_all_network_options(); - } - - return $args; - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return count( (array) $this->network_options_whitelist ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php deleted file mode 100644 index d21dee9b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php +++ /dev/null @@ -1,480 +0,0 @@ -update_options_whitelist(); - $this->update_options_contentless(); - } - - /** - * Set module defaults at a later time. - * - * @access public - */ - public function set_late_default() { - /** This filter is already documented in json-endpoints/jetpack/class.wpcom-json-api-get-option-endpoint.php */ - $late_options = apply_filters( 'jetpack_options_whitelist', array() ); - if ( ! empty( $late_options ) && is_array( $late_options ) ) { - $this->options_whitelist = array_merge( $this->options_whitelist, $late_options ); - } - } - - /** - * Add old deprecated options to the list of options to keep in sync. - * - * @since 1.14.0 - * - * @access public - * - * @param array $options The default list of site options. - */ - public function add_deprecated_options( $options ) { - global $wp_version; - - $deprecated_options = array( - 'blacklist_keys' => '5.5-alpha', // Replaced by disallowed_keys. - 'comment_whitelist' => '5.5-alpha', // Replaced by comment_previously_approved. - ); - - foreach ( $deprecated_options as $option => $version ) { - if ( version_compare( $wp_version, $version, '<=' ) ) { - $options[] = $option; - } - } - - return $options; - } - - /** - * Enqueue the options actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - /** - * Tells the client to sync all options to the server - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean Whether to expand options (should always be true) - */ - do_action( 'jetpack_full_sync_options', true ); - - // The number of actions enqueued, and next module state (true == done). - return array( 1, true ); - } - - /** - * Send the options actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $send_until The timestamp until the current request can send. - * @param array $state This module Full Sync status. - * - * @return array This module Full Sync status. - */ - public function send_full_sync_actions( $config, $send_until, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // we call this instead of do_action when sending immediately. - $this->send_action( 'jetpack_full_sync_options', array( true ) ); - - // The number of actions enqueued, and next module state (true == done). - return array( 'finished' => true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return int Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_options' ); - } - - /** - * Retrieve all options as per the current options whitelist. - * Public so that we don't have to store so much data all the options twice. - * - * @access public - * - * @return array All options. - */ - public function get_all_options() { - $options = array(); - $random_string = wp_generate_password(); - foreach ( $this->options_whitelist as $option ) { - if ( str_starts_with( $option, Settings::SETTINGS_OPTION_PREFIX ) ) { - $option_value = Settings::get_setting( str_replace( Settings::SETTINGS_OPTION_PREFIX, '', $option ) ); - $options[ $option ] = $option_value; - } else { - $option_value = get_option( $option, $random_string ); - if ( $option_value !== $random_string ) { - $options[ $option ] = $option_value; - } - } - } - - // Add theme mods. - $theme_mods_option = 'theme_mods_' . get_option( 'stylesheet' ); - $theme_mods_value = get_option( $theme_mods_option, $random_string ); - if ( $theme_mods_value === $random_string ) { - return $options; - } - $this->filter_theme_mods( $theme_mods_value ); - $options[ $theme_mods_option ] = $theme_mods_value; - return $options; - } - - /** - * Update the options whitelist to the default one. - * - * @access public - */ - public function update_options_whitelist() { - $this->options_whitelist = Defaults::get_options_whitelist(); - } - - /** - * Set the options whitelist. - * - * @access public - * - * @param array $options The new options whitelist. - */ - public function set_options_whitelist( $options ) { - $this->options_whitelist = $options; - } - - /** - * Get the options whitelist. - * - * @access public - * - * @return array The options whitelist. - */ - public function get_options_whitelist() { - return $this->options_whitelist; - } - - /** - * Update the contentless options to the defaults. - * - * @access public - */ - public function update_options_contentless() { - $this->options_contentless = Defaults::get_options_contentless(); - } - - /** - * Get the contentless options. - * - * @access public - * - * @return array Array of the contentless options. - */ - public function get_options_contentless() { - return $this->options_contentless; - } - - /** - * Reject any options that aren't whitelisted or contentless. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The hook parameters. - */ - public function whitelist_options( $args ) { - // Reject non-whitelisted options. - if ( ! $this->is_whitelisted_option( $args[0] ) ) { - return false; - } - - // Filter our weird array( false ) value for theme_mods_*. - if ( str_starts_with( $args[0], 'theme_mods_' ) ) { - $this->filter_theme_mods( $args[1] ); - if ( isset( $args[2] ) ) { - $this->filter_theme_mods( $args[2] ); - } - } - - // Set value(s) of contentless option to empty string(s). - if ( $this->is_contentless_option( $args[0] ) ) { - // Create a new array matching length of $args, containing empty strings. - $empty = array_fill( 0, count( $args ), '' ); - $empty[0] = $args[0]; - return $empty; - } - - return $args; - } - - /** - * Whether a certain option is whitelisted for sync. - * - * @access public - * - * @param string $option Option name. - * @return boolean Whether the option is whitelisted. - */ - public function is_whitelisted_option( $option ) { - return in_array( $option, $this->options_whitelist, true ) || str_starts_with( $option, 'theme_mods_' ); - } - - /** - * Whether a certain option is a contentless one. - * - * @access private - * - * @param string $option Option name. - * @return boolean Whether the option is contentless. - */ - private function is_contentless_option( $option ) { - return in_array( $option, $this->options_contentless, true ); - } - - /** - * Filters out falsy values from theme mod options. - * - * @access private - * - * @param array $value Option value. - */ - private function filter_theme_mods( &$value ) { - if ( is_array( $value ) && isset( $value[0] ) ) { - unset( $value[0] ); - } - } - - /** - * Handle changes in the core site icon and sync them. - * - * @access public - */ - public function jetpack_sync_core_icon() { - $url = get_site_icon_url(); - - $jetpack_url = \Jetpack_Options::get_option( 'site_icon_url' ); - if ( defined( 'JETPACK__PLUGIN_DIR' ) ) { - if ( ! function_exists( 'jetpack_site_icon_url' ) ) { - require_once JETPACK__PLUGIN_DIR . 'modules/site-icon/site-icon-functions.php'; - } - $jetpack_url = jetpack_site_icon_url(); - } - - // If there's a core icon, maybe update the option. If not, fall back to Jetpack's. - if ( ! empty( $url ) && $jetpack_url !== $url ) { - // This is the option that is synced with dotcom. - \Jetpack_Options::update_option( 'site_icon_url', $url ); - } elseif ( empty( $url ) ) { - \Jetpack_Options::delete_option( 'site_icon_url' ); - } - } - - /** - * Expand all options within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The hook parameters. - */ - public function expand_options( $args ) { - if ( $args[0] ) { - return $this->get_all_options(); - } - - return $args; - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return count( Defaults::get_options_whitelist() ); - } - - /** - * Retrieve a set of options by their IDs. - * - * @access public - * - * @param string $object_type Object type. - * @param array $ids Object IDs. - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { - if ( empty( $ids ) || empty( $object_type ) || 'option' !== $object_type ) { - return array(); - } - - $objects = array(); - foreach ( (array) $ids as $id ) { - $object = $this->get_object_by_id( $object_type, $id ); - - // Only add object if we have the object. - if ( 'OPTION-DOES-NOT-EXIST' !== $object ) { - if ( 'all' === $id ) { - // If all was requested it contains all options and can simply be returned. - return $object; - } - $objects[ $id ] = $object; - } - } - - return $objects; - } - - /** - * Retrieve an option by its name. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param string $id ID of the sync object. - * @return mixed Value of Option or 'OPTION-DOES-NOT-EXIST' if not found. - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'option' === $object_type ) { - // Utilize Random string as default value to distinguish between false and not exist. - $random_string = wp_generate_password(); - // Only whitelisted options can be returned. - if ( in_array( $id, $this->options_whitelist, true ) ) { - if ( str_starts_with( $id, Settings::SETTINGS_OPTION_PREFIX ) ) { - $option_value = Settings::get_setting( str_replace( Settings::SETTINGS_OPTION_PREFIX, '', $id ) ); - return $option_value; - } else { - $option_value = get_option( $id, $random_string ); - if ( $option_value !== $random_string ) { - return $option_value; - } - } - } elseif ( 'all' === $id ) { - return $this->get_all_options(); - } - } - - return 'OPTION-DOES-NOT-EXIST'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php deleted file mode 100644 index 3274caf7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php +++ /dev/null @@ -1,407 +0,0 @@ -action_handler = $callable; - - add_action( 'deleted_plugin', array( $this, 'deleted_plugin' ), 10, 2 ); - add_action( 'activated_plugin', $callable, 10, 2 ); - add_action( 'deactivated_plugin', $callable, 10, 2 ); - add_action( 'delete_plugin', array( $this, 'delete_plugin' ) ); - add_filter( 'upgrader_pre_install', array( $this, 'populate_plugins' ), 10, 1 ); - add_action( 'upgrader_process_complete', array( $this, 'on_upgrader_completion' ), 10, 2 ); - add_action( 'jetpack_plugin_installed', $callable, 10, 1 ); - add_action( 'jetpack_plugin_update_failed', $callable, 10, 4 ); - add_action( 'jetpack_plugins_updated', $callable, 10, 2 ); - add_action( 'jetpack_edited_plugin', $callable, 10, 2 ); - add_action( 'wp_ajax_edit-theme-plugin-file', array( $this, 'plugin_edit_ajax' ), 0 ); - - // Note that we don't simply 'expand_plugin_data' on the 'delete_plugin' action here because the plugin file is deleted when that action finishes. - add_filter( 'jetpack_sync_before_enqueue_activated_plugin', array( $this, 'expand_plugin_data' ) ); - add_filter( 'jetpack_sync_before_enqueue_deactivated_plugin', array( $this, 'expand_plugin_data' ) ); - } - - /** - * Fetch and populate all current plugins before upgrader installation. - * - * @access public - * - * @param bool|WP_Error $response Install response, true if successful, WP_Error if not. - */ - public function populate_plugins( $response ) { - if ( ! function_exists( 'get_plugins' ) ) { - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - $this->plugins = get_plugins(); - return $response; - } - - /** - * Handler for the upgrader success finishes. - * - * @access public - * - * @param \WP_Upgrader $upgrader Upgrader instance. - * @param array $details Array of bulk item update data. - */ - public function on_upgrader_completion( $upgrader, $details ) { - if ( ! isset( $details['type'] ) ) { - return; - } - if ( 'plugin' !== $details['type'] ) { - return; - } - - if ( ! isset( $details['action'] ) ) { - return; - } - - $plugins = ( isset( $details['plugins'] ) ? $details['plugins'] : null ); - if ( empty( $plugins ) ) { - $plugins = ( isset( $details['plugin'] ) ? array( $details['plugin'] ) : null ); - } - - // For plugin installer. - if ( empty( $plugins ) && method_exists( $upgrader, 'plugin_info' ) ) { - // @phan-suppress-next-line PhanUndeclaredMethod -- Checked above. See also https://github.com/phan/phan/issues/1204. - $plugins = array( $upgrader->plugin_info() ); - } - - if ( empty( $plugins ) ) { - return; // We shouldn't be here. - } - - switch ( $details['action'] ) { - case 'update': - $this->state = array( - 'is_autoupdate' => Jetpack_Constants::is_true( 'JETPACK_PLUGIN_AUTOUPDATE' ), - ); - $errors = $this->get_errors( $upgrader->skin ); - if ( $errors ) { - foreach ( $plugins as $slug ) { - /** - * Sync that a plugin update failed - * - * @since 1.6.3 - * @since-jetpack 5.8.0 - * - * @module sync - * - * @param string $plugin , Plugin slug - * @param string Error code - * @param string Error message - */ - do_action( 'jetpack_plugin_update_failed', $this->get_plugin_info( $slug ), $errors['code'], $errors['message'], $this->state ); - } - - return; - } - - $this->plugins_updated = array_map( array( $this, 'get_plugin_info' ), $plugins ); - add_action( 'shutdown', array( $this, 'sync_plugins_updated' ), 9 ); - - break; - case 'install': - /** - * Signals to the sync listener that a plugin was installed and a sync action - * reflecting the installation and the plugin info should be sent - * - * @since 1.6.3 - * @since-jetpack 5.8.0 - * - * @module sync - * - * @param array () $plugin, Plugin Data - */ - do_action( 'jetpack_plugin_installed', array_map( array( $this, 'get_plugin_info' ), $plugins ) ); - } - } - - /** - * Retrieve the plugin information by a plugin slug. - * - * @access private - * - * @param string $slug Plugin slug. - * @return array Plugin information. - */ - private function get_plugin_info( $slug ) { - $plugins = get_plugins(); // Get the most up to date info. - if ( isset( $plugins[ $slug ] ) ) { - return array_merge( array( 'slug' => $slug ), $plugins[ $slug ] ); - } - // Try grabbing the info from before the update. - return isset( $this->plugins[ $slug ] ) ? array_merge( array( 'slug' => $slug ), $this->plugins[ $slug ] ) : array( 'slug' => $slug ); - } - - /** - * Retrieve upgrade errors. - * - * @access private - * - * @param \Automatic_Upgrader_Skin|\WP_Upgrader_Skin $skin The upgrader skin being used. - * @return array|boolean Error on error, false otherwise. - */ - private function get_errors( $skin ) { - // @phan-suppress-next-line PhanUndeclaredMethod -- Checked before being called. See also https://github.com/phan/phan/issues/1204. - $errors = method_exists( $skin, 'get_errors' ) ? $skin->get_errors() : null; - if ( is_wp_error( $errors ) ) { - $error_code = $errors->get_error_code(); - if ( ! empty( $error_code ) ) { - return array( - 'code' => $error_code, - 'message' => $errors->get_error_message(), - ); - } - } - - if ( isset( $skin->result ) ) { - $errors = $skin->result; - if ( is_wp_error( $errors ) ) { - return array( - 'code' => $errors->get_error_code(), - 'message' => $errors->get_error_message(), - ); - } - - if ( empty( $skin->result ) ) { - return array( - 'code' => 'unknown', - 'message' => __( 'Unknown Plugin Update Failure', 'jetpack-sync' ), - ); - } - } - return false; - } - - /** - * Handle plugin ajax edit in the administration. - * - * @access public - * - * @todo Update this method to use WP_Filesystem instead of fopen/fclose. - */ - public function plugin_edit_ajax() { - // This validation is based on wp_edit_theme_plugin_file(). - if ( empty( $_POST['file'] ) ) { - return; - } - - $file = wp_unslash( $_POST['file'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated manually just after. - if ( 0 !== validate_file( $file ) ) { - return; - } - - if ( ! isset( $_POST['newcontent'] ) ) { - return; - } - - if ( ! isset( $_POST['nonce'] ) ) { - return; - } - - if ( empty( $_POST['plugin'] ) ) { - return; - } - - $plugin = wp_unslash( $_POST['plugin'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated manually just after. - if ( ! current_user_can( 'edit_plugins' ) ) { - return; - } - - if ( ! wp_verify_nonce( $_POST['nonce'], 'edit-plugin_' . $file ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- WP core doesn't pre-sanitize nonces either. - return; - } - $plugins = get_plugins(); - if ( ! array_key_exists( $plugin, $plugins ) ) { - return; - } - - if ( 0 !== validate_file( $file, get_plugin_files( $plugin ) ) ) { - return; - } - - $real_file = WP_PLUGIN_DIR . '/' . $file; - - // phpcs:ignore WordPress.WP.AlternativeFunctions.file_system_operations_is_writable - if ( ! is_writable( $real_file ) ) { - return; - } - - // phpcs:ignore WordPress.WP.AlternativeFunctions.file_system_operations_fopen - $file_pointer = fopen( $real_file, 'w+' ); - if ( false === $file_pointer ) { - return; - } - // phpcs:ignore WordPress.WP.AlternativeFunctions.file_system_operations_fclose - fclose( $file_pointer ); - /** - * This action is documented already in this file - */ - do_action( 'jetpack_edited_plugin', $plugin, $plugins[ $plugin ] ); - } - - /** - * Handle plugin deletion. - * - * @access public - * - * @param string $plugin_path Path to the plugin main file. - */ - public function delete_plugin( $plugin_path ) { - $full_plugin_path = WP_PLUGIN_DIR . DIRECTORY_SEPARATOR . $plugin_path; - - // Checking for file existence because some sync plugin module tests simulate plugin installation and deletion without putting file on disk. - if ( file_exists( $full_plugin_path ) ) { - $all_plugin_data = get_plugin_data( $full_plugin_path ); - $data = array( - 'name' => $all_plugin_data['Name'], - 'version' => $all_plugin_data['Version'], - ); - } else { - $data = array( - 'name' => $plugin_path, - 'version' => 'unknown', - ); - } - - $this->plugin_info[ $plugin_path ] = $data; - } - - /** - * Invoked after plugin deletion. - * - * @access public - * - * @param string $plugin_path Path to the plugin main file. - * @param boolean $is_deleted Whether the plugin was deleted successfully. - */ - public function deleted_plugin( $plugin_path, $is_deleted ) { - call_user_func( $this->action_handler, $plugin_path, $is_deleted, $this->plugin_info[ $plugin_path ] ); - unset( $this->plugin_info[ $plugin_path ] ); - } - - /** - * Expand the plugins within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The expanded hook parameters. - */ - public function expand_plugin_data( $args ) { - $plugin_path = $args[0]; - $plugin_data = array(); - - if ( ! function_exists( 'get_plugins' ) ) { - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - $all_plugins = get_plugins(); - if ( isset( $all_plugins[ $plugin_path ] ) ) { - $all_plugin_data = $all_plugins[ $plugin_path ]; - $plugin_data['name'] = $all_plugin_data['Name']; - $plugin_data['version'] = $all_plugin_data['Version']; - } - - return array( - $args[0], - $args[1], - $plugin_data, - ); - } - - /** - * Helper method for firing the 'jetpack_plugins_updated' action on shutdown. - * - * @access public - */ - public function sync_plugins_updated() { - /** - * Sync that a plugin update - * - * @since 1.6.3 - * @since-jetpack 5.8.0 - * - * @module sync - * - * @param array () $plugin, Plugin Data - */ - do_action( 'jetpack_plugins_updated', $this->plugins_updated, $this->state ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php deleted file mode 100644 index cad3b5c3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php +++ /dev/null @@ -1,922 +0,0 @@ - length. - * Current Setting : 5MB. - * - * @access public - * - * @var int - */ - const MAX_POST_CONTENT_LENGTH = 5000000; - - /** - * Default previous post state. - * Used for default previous post status. - * - * @access public - * - * @var string - */ - const DEFAULT_PREVIOUS_STATE = 'new'; - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'posts'; - } - - /** - * The table name. - * - * @access public - * - * @return string - * @deprecated since 3.11.0 Use table() instead. - */ - public function table_name() { - _deprecated_function( __METHOD__, '3.11.0', 'Automattic\\Jetpack\\Sync\\Posts->table' ); - return 'posts'; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - global $wpdb; - return $wpdb->posts; - } - - /** - * Retrieve a post by its ID. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param int $id ID of the sync object. - * @return \WP_Post|bool Filtered \WP_Post object, or false if the object is not a post. - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'post' === $object_type ) { - $post = get_post( (int) $id ); - if ( $post ) { - return $this->filter_post_content_and_add_links( $post ); - } - } - - return false; - } - - /** - * Initialize posts action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - $this->action_handler = $callable; - - add_action( 'wp_insert_post', array( $this, 'wp_insert_post' ), 11, 3 ); - add_action( 'wp_after_insert_post', array( $this, 'wp_after_insert_post' ), 11, 2 ); - add_action( 'jetpack_sync_save_post', $callable, 10, 4 ); - - add_action( 'deleted_post', $callable, 10 ); - add_action( 'jetpack_published_post', $callable, 10, 3 ); - add_filter( 'jetpack_sync_before_enqueue_deleted_post', array( $this, 'filter_blacklisted_post_types_deleted' ) ); - - add_action( 'transition_post_status', array( $this, 'save_published' ), 10, 3 ); - - // Listen for meta changes. - $this->init_listeners_for_meta_type( 'post', $callable ); - $this->init_meta_whitelist_handler( 'post', array( $this, 'filter_meta' ) ); - - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_save_post', array( $this, 'filter_jetpack_sync_before_enqueue_jetpack_sync_save_post' ) ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_published_post', array( $this, 'filter_jetpack_sync_before_enqueue_jetpack_published_post' ) ); - - add_action( 'jetpack_daily_akismet_meta_cleanup_before', array( $this, 'daily_akismet_meta_cleanup_before' ) ); - add_action( 'jetpack_daily_akismet_meta_cleanup_after', array( $this, 'daily_akismet_meta_cleanup_after' ) ); - add_action( 'jetpack_post_meta_batch_delete', $callable, 10, 2 ); - } - - /** - * Before Akismet's daily cleanup of spam detection metadata. - * - * @access public - * - * @param array $feedback_ids IDs of feedback posts. - */ - public function daily_akismet_meta_cleanup_before( $feedback_ids ) { - remove_action( 'deleted_post_meta', $this->action_handler ); - - if ( ! is_array( $feedback_ids ) || count( $feedback_ids ) < 1 ) { - return; - } - - $ids_chunks = array_chunk( $feedback_ids, 100, false ); - foreach ( $ids_chunks as $chunk ) { - /** - * Used for syncing deletion of batch post meta - * - * @since 1.6.3 - * @since-jetpack 6.1.0 - * - * @module sync - * - * @param array $feedback_ids feedback post IDs - * @param string $meta_key to be deleted - */ - do_action( 'jetpack_post_meta_batch_delete', $chunk, '_feedback_akismet_values' ); - } - } - - /** - * After Akismet's daily cleanup of spam detection metadata. - * - * @access public - * - * @param array $feedback_ids IDs of feedback posts. - */ - public function daily_akismet_meta_cleanup_after( $feedback_ids ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - add_action( 'deleted_post_meta', $this->action_handler ); - } - - /** - * Initialize posts action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_posts', $callable ); // Also sends post meta. - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - // meta. - add_filter( 'jetpack_sync_before_send_added_post_meta', array( $this, 'trim_post_meta' ) ); - add_filter( 'jetpack_sync_before_send_updated_post_meta', array( $this, 'trim_post_meta' ) ); - add_filter( 'jetpack_sync_before_send_deleted_post_meta', array( $this, 'trim_post_meta' ) ); - // Full sync. - $sync_module = Modules::get_module( 'full-sync' ); - if ( $sync_module instanceof Full_Sync_Immediately ) { - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_posts', array( $this, 'build_full_sync_action_array' ) ); - } else { - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_posts', array( $this, 'expand_posts_with_metadata_and_terms' ) ); - } - } - - /** - * Enqueue the posts actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - global $wpdb; - - return $this->enqueue_all_ids_as_action( 'jetpack_full_sync_posts', $wpdb->posts, 'ID', $this->get_where_sql( $config ), $max_items_to_enqueue, $state ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @todo Use $wpdb->prepare for the SQL query. - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { - global $wpdb; - - $query = "SELECT count(*) FROM $wpdb->posts WHERE " . $this->get_where_sql( $config ); - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / self::ARRAY_CHUNK_SIZE ); - } - - /** - * Retrieve the WHERE SQL clause based on the module config. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return string WHERE SQL clause, or `null` if no comments are specified in the module config. - */ - public function get_where_sql( $config ) { - $where_sql = Settings::get_blacklisted_post_types_sql(); - - // Config is a list of post IDs to sync. - if ( is_array( $config ) ) { - $where_sql .= ' AND ID IN (' . implode( ',', array_map( 'intval', $config ) ) . ')'; - } - - return $where_sql; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_posts' ); - } - - /** - * Filter meta arguments so that we don't sync meta_values over MAX_META_LENGTH. - * - * @param array $args action arguments. - * - * @return array filtered action arguments. - */ - public function trim_post_meta( $args ) { - list( $meta_id, $object_id, $meta_key, $meta_value ) = $args; - // Explicitly truncate meta_value when it exceeds limit. - // Large content will cause OOM issues and break Sync. - $serialized_value = maybe_serialize( $meta_value ); - if ( strlen( $serialized_value ) >= self::MAX_META_LENGTH ) { - $meta_value = ''; - } - return array( $meta_id, $object_id, $meta_key, $meta_value ); - } - - /** - * Process content before send. - * - * @param array $args Arguments of the `wp_insert_post` hook. - * - * @return array - */ - public function expand_jetpack_sync_save_post( $args ) { - list( $post_id, $post, $update, $previous_state ) = $args; - return array( $post_id, $this->filter_post_content_and_add_links( $post ), $update, $previous_state ); - } - - /** - * Filter all blacklisted post types and add filtered post content. - * - * @param array $args Hook arguments. - * @return array|false Hook arguments, or false if the post type is a blacklisted one. - */ - public function filter_jetpack_sync_before_enqueue_jetpack_sync_save_post( $args ) { - list( $post_id, $post, $update, $previous_state ) = $args; - - if ( in_array( $post->post_type, Settings::get_setting( 'post_types_blacklist' ), true ) ) { - return false; - } - - return array( $post_id, $this->filter_post_content_and_add_links( $post ), $update, $previous_state ); - } - - /** - * Add filtered post content. - * - * @param array $args Hook arguments. - * @return array Hook arguments. - */ - public function filter_jetpack_sync_before_enqueue_jetpack_published_post( $args ) { - list( $post_id, $flags, $post ) = $args; - - return array( $post_id, $flags, $this->filter_post_content_and_add_links( $post ) ); - } - - /** - * Filter all blacklisted post types. - * - * @param array $args Hook arguments. - * @return array|false Hook arguments, or false if the post type is a blacklisted one. - */ - public function filter_blacklisted_post_types_deleted( $args ) { - - // deleted_post is called after the SQL delete but before cache cleanup. - // There is the potential we can't detect post_type at this point. - if ( ! $this->is_post_type_allowed( $args[0] ) ) { - return false; - } - - return $args; - } - - /** - * Filter all meta that is not blacklisted, or is stored for a disallowed post type. - * - * @param array $args Hook arguments. - * @return array|false Hook arguments, or false if meta was filtered. - */ - public function filter_meta( $args ) { - if ( $this->is_post_type_allowed( $args[1] ) && $this->is_whitelisted_post_meta( $args[2] ) ) { - return $args; - } - - return false; - } - - /** - * Whether a post meta key is whitelisted. - * - * @param string $meta_key Meta key. - * @return boolean Whether the post meta key is whitelisted. - */ - public function is_whitelisted_post_meta( $meta_key ) { - // The _wpas_skip_ meta key is used by Publicize. - return in_array( $meta_key, Settings::get_setting( 'post_meta_whitelist' ), true ) || str_starts_with( $meta_key, '_wpas_skip_' ); - } - - /** - * Whether a post type is allowed. - * A post type will be disallowed if it's present in the post type blacklist. - * - * @param int $post_id ID of the post. - * @return boolean Whether the post type is allowed. - */ - public function is_post_type_allowed( $post_id ) { - $post = get_post( (int) $post_id ); - - if ( isset( $post->post_type ) ) { - return ! in_array( $post->post_type, Settings::get_setting( 'post_types_blacklist' ), true ); - } - return false; - } - - /** - * Remove the embed shortcode. - * - * @global $wp_embed - */ - public function remove_embed() { - global $wp_embed; - remove_filter( 'the_content', array( $wp_embed, 'run_shortcode' ), 8 ); - // remove the embed shortcode since we would do the part later. - remove_shortcode( 'embed' ); - // Attempts to embed all URLs in a post. - remove_filter( 'the_content', array( $wp_embed, 'autoembed' ), 8 ); - } - - /** - * Add the embed shortcode. - * - * @global $wp_embed - */ - public function add_embed() { - global $wp_embed; - add_filter( 'the_content', array( $wp_embed, 'run_shortcode' ), 8 ); - // Shortcode placeholder for strip_shortcodes(). - add_shortcode( 'embed', '__return_false' ); - // Attempts to embed all URLs in a post. - add_filter( 'the_content', array( $wp_embed, 'autoembed' ), 8 ); - } - - /** - * Expands wp_insert_post to include filtered content - * - * @param \WP_Post $post_object Post object. - */ - public function filter_post_content_and_add_links( $post_object ) { - global $post; - - // Used to restore the post global. - $current_post = $post; - - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $post = $post_object; - - // Return non existant post. - $post_type = get_post_type_object( $post->post_type ); - if ( empty( $post_type ) || ! is_object( $post_type ) ) { - $non_existant_post = new \stdClass(); - $non_existant_post->ID = $post->ID; - $non_existant_post->post_modified = $post->post_modified; - $non_existant_post->post_modified_gmt = $post->post_modified_gmt; - $non_existant_post->post_status = 'jetpack_sync_non_registered_post_type'; - $non_existant_post->post_type = $post->post_type; - // Restore global post. - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $post = $current_post; - - return $non_existant_post; - } - /** - * Filters whether to prevent sending post data to .com - * - * Passing true to the filter will prevent the post data from being sent - * to the WordPress.com. - * Instead we pass data that will still enable us to do a checksum against the - * Jetpacks data but will prevent us from displaying the data on in the API as well as - * other services. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean false prevent post data from being synced to WordPress.com - * @param mixed $post \WP_Post object - */ - if ( apply_filters( 'jetpack_sync_prevent_sending_post_data', false, $post ) ) { - // We only send the bare necessary object to be able to create a checksum. - $blocked_post = new \stdClass(); - $blocked_post->ID = $post->ID; - $blocked_post->post_modified = $post->post_modified; - $blocked_post->post_modified_gmt = $post->post_modified_gmt; - $blocked_post->post_status = 'jetpack_sync_blocked'; - $blocked_post->post_type = $post->post_type; - - // Restore global post. - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $post = $current_post; - - return $blocked_post; - } - - // lets not do oembed just yet. - $this->remove_embed(); - - if ( 0 < strlen( $post->post_password ) ) { - $post->post_password = 'auto-' . wp_generate_password( 10, false ); - } - - // Explicitly omit post_content when it exceeds limit. - // Large content will cause OOM issues and break Sync. - if ( strlen( $post->post_content ) >= self::MAX_POST_CONTENT_LENGTH ) { - $post->post_content = ''; - } - - /** This filter is already documented in core. wp-includes/post-template.php */ - if ( Settings::get_setting( 'render_filtered_content' ) && $post_type->public ) { - global $shortcode_tags; - /** - * Filter prevents some shortcodes from expanding. - * - * Since we can can expand some type of shortcode better on the .com side and make the - * expansion more relevant to contexts. For example [galleries] and subscription emails - * - * @since 1.6.3 - * @since-jetpack 4.5.0 - * - * @param array of shortcode tags to remove. - */ - $shortcodes_to_remove = apply_filters( - 'jetpack_sync_do_not_expand_shortcodes', - array( - 'gallery', - 'slideshow', - ) - ); - $removed_shortcode_callbacks = array(); - foreach ( $shortcodes_to_remove as $shortcode ) { - if ( isset( $shortcode_tags[ $shortcode ] ) ) { - $removed_shortcode_callbacks[ $shortcode ] = $shortcode_tags[ $shortcode ]; - } - } - - array_map( 'remove_shortcode', array_keys( $removed_shortcode_callbacks ) ); - /** - * Certain modules such as Likes, Related Posts and Sharedaddy are using `Settings::is_syncing` - * in order to NOT get rendered in filtered post content. - * Since the current method runs now before enqueueing instead of before sending, - * we are setting `is_syncing` flag to true in order to preserve the existing functionality. - */ - - $is_syncing_current = Settings::is_syncing(); - Settings::set_is_syncing( true ); - $post->post_content_filtered = apply_filters( 'the_content', $post->post_content ); - $post->post_excerpt_filtered = apply_filters( 'the_excerpt', $post->post_excerpt ); - Settings::set_is_syncing( $is_syncing_current ); - - foreach ( $removed_shortcode_callbacks as $shortcode => $callback ) { - add_shortcode( $shortcode, $callback ); - } - } - - $this->add_embed(); - - if ( has_post_thumbnail( $post->ID ) ) { - $image_attributes = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'full' ); - if ( is_array( $image_attributes ) && isset( $image_attributes[0] ) ) { - $post->featured_image = $image_attributes[0]; - } - } - - $post->permalink = get_permalink( $post->ID ); - $post->shortlink = wp_get_shortlink( $post->ID ); - - if ( function_exists( 'amp_get_permalink' ) ) { - $post->amp_permalink = amp_get_permalink( $post->ID ); - } - - $filtered_post = $post; - - // Restore global post. - // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - $post = $current_post; - - return $filtered_post; - } - - /** - * Handle transition from another post status to a published one. - * - * @param string $new_status New post status. - * @param string $old_status Old post status. - * @param \WP_Post $post Post object. - */ - public function save_published( $new_status, $old_status, $post ) { - if ( 'publish' === $new_status && 'publish' !== $old_status ) { - $this->just_published[ $post->ID ] = true; - } - - $this->previous_status[ $post->ID ] = $old_status; - } - - /** - * When publishing or updating a post, the Gutenberg editor sends two requests: - * 1. sent to WP REST API endpoint `wp-json/wp/v2/posts/$id` - * 2. sent to wp-admin/post.php `?post=$id&action=edit&classic-editor=1&meta_box=1` - * - * The 2nd request is to update post meta, which is not supported on WP REST API. - * When syncing post data, we will include if this was a meta box update. - * - * @return boolean Whether this is a Gutenberg meta box update. - */ - private function is_gutenberg_meta_box_update() { - // phpcs:disable WordPress.Security.NonceVerification.Missing, WordPress.Security.NonceVerification.Recommended -- We only check the request to determine if this is a Gutenberg meta box update, and we only use the result to set a boolean logged in the sync event. If anyone anywhere else gets the flag and does something CSRF-able with it, they should ensure that a nonce has been checked. - return ( - isset( $_POST['action'], $_GET['classic-editor'], $_GET['meta_box'] ) && - 'editpost' === $_POST['action'] && - '1' === $_GET['classic-editor'] && - '1' === $_GET['meta_box'] - // phpcs:enable WordPress.Security.NonceVerification.Missing, WordPress.Security.NonceVerification.Recommended - ); - } - - /** - * Handler for the wp_insert_post hook. - * Called upon creation of a new post. - * - * @param int $post_ID Post ID. - * @param \WP_Post $post Post object. - * @param boolean $update Whether this is an existing post being updated or not. - */ - public function wp_insert_post( $post_ID, $post = null, $update = null ) { - if ( ! is_numeric( $post_ID ) || $post === null ) { - return; - } - - // Workaround for https://github.com/woocommerce/woocommerce/issues/18007. - if ( $post && 'shop_order' === $post->post_type ) { - $post = get_post( $post_ID ); - } - - $previous_status = isset( $this->previous_status[ $post_ID ] ) ? $this->previous_status[ $post_ID ] : self::DEFAULT_PREVIOUS_STATE; - - $just_published = isset( $this->just_published[ $post_ID ] ) ? $this->just_published[ $post_ID ] : false; - - $state = array( - 'is_auto_save' => (bool) Jetpack_Constants::get_constant( 'DOING_AUTOSAVE' ), - 'previous_status' => $previous_status, - 'just_published' => $just_published, - 'is_gutenberg_meta_box_update' => $this->is_gutenberg_meta_box_update(), - ); - /** - * Filter that is used to add to the post flags ( meta data ) when a post gets published - * - * @since 1.6.3 - * @since-jetpack 5.8.0 - * - * @param int $post_ID the post ID - * @param mixed $post \WP_Post object - * @param bool $update Whether this is an existing post being updated or not. - * @param mixed $state state - * - * @module sync - */ - do_action( 'jetpack_sync_save_post', $post_ID, $post, $update, $state ); - unset( $this->previous_status[ $post_ID ] ); - } - - /** - * Handler for the wp_after_insert_post hook. - * Called after creation/update of a new post. - * - * @param int $post_ID Post ID. - * @param \WP_Post $post Post object. - **/ - public function wp_after_insert_post( $post_ID, $post ) { - if ( ! is_numeric( $post_ID ) || $post === null ) { - return; - } - - // Workaround for https://github.com/woocommerce/woocommerce/issues/18007. - if ( $post && 'shop_order' === $post->post_type ) { - $post = get_post( $post_ID ); - } - - $this->send_published( $post_ID, $post ); - } - - /** - * Send a published post for sync. - * - * @param int $post_ID Post ID. - * @param \WP_Post $post Post object. - */ - public function send_published( $post_ID, $post ) { - if ( ! isset( $this->just_published[ $post_ID ] ) ) { - return; - } - - // Post revisions cause race conditions where this send_published add the action before the actual post gets synced. - if ( wp_is_post_autosave( $post ) || wp_is_post_revision( $post ) ) { - return; - } - - $post_flags = array( - 'post_type' => $post->post_type, - ); - - $author_user_object = get_user_by( 'id', $post->post_author ); - if ( $author_user_object ) { - $roles = new Roles(); - - $post_flags['author'] = array( - 'id' => $post->post_author, - 'wpcom_user_id' => get_user_meta( $post->post_author, 'wpcom_user_id', true ), - 'display_name' => $author_user_object->display_name, - 'email' => $author_user_object->user_email, - 'translated_role' => $roles->translate_user_to_role( $author_user_object ), - ); - } - - /** - * Filter that is used to add to the post flags ( meta data ) when a post gets published - * - * @since 1.6.3 - * @since-jetpack 4.4.0 - * - * @param mixed array post flags that are added to the post - * @param mixed $post \WP_Post object - */ - $flags = apply_filters( 'jetpack_published_post_flags', $post_flags, $post ); - - // Only Send Pulished Post event if post_type is not blacklisted. - if ( ! in_array( $post->post_type, Settings::get_setting( 'post_types_blacklist' ), true ) ) { - - /** - * Action that gets synced when a post type gets published. - * - * @since 1.6.3 - * @since-jetpack 4.4.0 - * - * @param int $post_ID - * @param mixed array $flags post flags that are added to the post - * @param WP_Post $post The post object - */ - do_action( 'jetpack_published_post', $post_ID, $flags, $post ); - } - unset( $this->just_published[ $post_ID ] ); - - /** - * Send additional sync action for Activity Log when post is a Customizer publish - */ - if ( 'customize_changeset' === $post->post_type ) { - $post_content = json_decode( $post->post_content, true ); - foreach ( $post_content as $key => $value ) { - // Skip if it isn't a widget. - if ( 'widget_' !== substr( $key, 0, strlen( 'widget_' ) ) ) { - continue; - } - // Change key from "widget_archives[2]" to "archives-2". - $key = str_replace( 'widget_', '', $key ); - $key = str_replace( '[', '-', $key ); - $key = str_replace( ']', '', $key ); - - global $wp_registered_widgets; - if ( isset( $wp_registered_widgets[ $key ] ) ) { - $widget_data = array( - 'name' => $wp_registered_widgets[ $key ]['name'], - 'id' => $key, - 'title' => $value['value']['title'], - ); - do_action( 'jetpack_widget_edited', $widget_data ); - } - } - } - } - - /** - * Build the full sync action object for Posts. - * - * @access public - * - * @param array $args An array with the posts and the previous end. - * - * @return array An array with the posts, postmeta and the previous end. - */ - public function build_full_sync_action_array( $args ) { - list( $filtered_posts, $previous_end ) = $args; - return array( - $filtered_posts['objects'], - $filtered_posts['meta'], - array(), // WPCOM does not process term relationships in full sync posts actions for a while now, let's skip them. - $previous_end, - ); - } - - /** - * Add term relationships to post objects within a hook before they are serialized and sent to the server. - * This is used in Full Sync Immediately - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The expanded hook parameters. - * @deprecated since 4.7.0 - */ - public function add_term_relationships( $args ) { - _deprecated_function( __METHOD__, '4.7.0' ); - list( $filtered_posts, $previous_interval_end ) = $args; - - return array( - $filtered_posts['objects'], - $filtered_posts['meta'], - $this->get_term_relationships( $filtered_posts['object_ids'] ), - $previous_interval_end, - ); - } - - /** - * Expand post IDs to post objects within a hook before they are serialized and sent to the server. - * This is used in Legacy Full Sync - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The expanded hook parameters. - */ - public function expand_posts_with_metadata_and_terms( $args ) { - list( $post_ids, $previous_interval_end ) = $args; - - $posts = $this->expand_posts( $post_ids ); - $posts_metadata = $this->get_metadata( $post_ids, 'post', Settings::get_setting( 'post_meta_whitelist' ) ); - $term_relationships = $this->get_term_relationships( $post_ids ); - - return array( - $posts, - $posts_metadata, - $term_relationships, - $previous_interval_end, - ); - } - - /** - * Gets a list of minimum and maximum object ids for each batch based on the given batch size. - * - * @access public - * - * @param int $batch_size The batch size for objects. - * @param string|bool $where_sql The sql where clause minus 'WHERE', or false if no where clause is needed. - * - * @return array|bool An array of min and max ids for each batch. FALSE if no table can be found. - */ - public function get_min_max_object_ids_for_batches( $batch_size, $where_sql = false ) { - return parent::get_min_max_object_ids_for_batches( $batch_size, $this->get_where_sql( $where_sql ) ); - } - - /** - * Given the Module Configuration and Status return the next chunk of items to send. - * This function also expands the posts and metadata and filters them based on the maximum size constraints. - * - * @param array $config This module Full Sync configuration. - * @param array $status This module Full Sync status. - * @param int $chunk_size Chunk size. - * - * @return array - */ - public function get_next_chunk( $config, $status, $chunk_size ) { - - $post_ids = parent::get_next_chunk( $config, $status, $chunk_size ); - - if ( empty( $post_ids ) ) { - return array(); - } - - $posts = $this->expand_posts( $post_ids ); - - // If no posts were fetched, make sure to return the expected structure so that status is updated correctly. - if ( empty( $posts ) ) { - return array( - 'object_ids' => $post_ids, - 'objects' => array(), - 'meta' => array(), - ); - } - // Get the post IDs from the posts that were fetched. - $fetched_post_ids = wp_list_pluck( $posts, 'ID' ); - $metadata = $this->get_metadata( $fetched_post_ids, 'post', Settings::get_setting( 'post_meta_whitelist' ) ); - - // Filter the posts and metadata based on the maximum size constraints. - list( $filtered_post_ids, $filtered_posts, $filtered_posts_metadata ) = $this->filter_objects_and_metadata_by_size( - 'post', - $posts, - $metadata, - self::MAX_META_LENGTH, - self::MAX_SIZE_FULL_SYNC - ); - - return array( - 'object_ids' => $filtered_post_ids, - 'objects' => $filtered_posts, - 'meta' => $filtered_posts_metadata, - ); - } - - /** - * Expand posts. - * - * @param array $post_ids Post IDs. - * - * @return array Expanded posts. - */ - private function expand_posts( $post_ids ) { - $posts = array_filter( array_map( array( 'WP_Post', 'get_instance' ), $post_ids ) ); - $posts = array_map( array( $this, 'filter_post_content_and_add_links' ), $posts ); - $posts = array_values( $posts ); // Reindex in case posts were deleted. - return $posts; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php deleted file mode 100644 index 95e1efb1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php +++ /dev/null @@ -1,83 +0,0 @@ -has_login_ability(); - } - - // If the login ability can not be determined, the feature is not active, - // or something is wrong, default to not syncing failed login attempts. - return false; - } - - /** - * Maybe log a failed login attempt. - * - * @access public - * - * @param array $failed_attempt Failed attempt data. - */ - public function maybe_log_failed_login_attempt( $failed_attempt ) { - /** - * Filter which provides Jetpack's decision as to whether the current requestor can attempt logging in. - * - * Example: When Jetpack's Brute Force Login Protection is active, this filter will return false if the user is currently locked out. - * - * @since 3.5.1 - * - * @package sync - * - * @return bool True if the user should be allowed to attempt logging in, false otherwise. - */ - $has_login_ability = apply_filters( 'jetpack_has_login_ability', $this->has_login_ability_fallback() ); - - if ( $has_login_ability && ! Jetpack_Constants::is_true( 'XMLRPC_REQUEST' ) ) { - do_action( 'jetpack_valid_failed_login_attempt', $failed_attempt ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php deleted file mode 100644 index f54a7977..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php +++ /dev/null @@ -1,1879 +0,0 @@ - [ 'searchable_in_all_content' => true ], - * Field will be included in the all_content fields - * - * 'metakey' => [ 'available' => false, 'alternatives' => [ 'metakey_processed' ] ], - * Field not in meta.* but has data in an alternative field(s) name that - * should work similarly. For instance, woocommerce total_sales does not go into - * the index, but the percentage of sales does. - * - * @static - * @access private - * @var array - */ - private static $postmeta_to_sync = array( - // jetpack. - 'jetpack-search-meta0' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta1' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta2' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta3' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta4' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta5' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta6' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta7' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta8' => array( 'searchable_in_all_content' => true ), - 'jetpack-search-meta9' => array( 'searchable_in_all_content' => true ), - - // woocommerce. - 'exclude_product_categories' => array(), - 'exclude_product_ids' => array(), - 'free_shipping' => array(), - 'id_field' => array(), - 'individual_use' => array(), - 'limit_usage_to_x_items' => array(), - 'maximum_amount' => array(), - 'minimum_amount' => array(), - 'post_id' => array(), - 'product_categories' => array( 'searchable_in_all_content' => true ), - 'product_ids' => array(), - 'total_sales' => array( - 'available' => false, - 'alternatives' => array( - 'wc.percent_of_sales', - ), - ), - 'usage_limit' => array(), - 'usage_limit_per_user' => array(), - '_crosssell_ids' => array(), - '_downloadable' => array(), - '_featured' => array(), - '_height' => array(), - '_length' => array(), - '_price' => array( - 'alternatives' => array( - 'wc.price', - 'wc.min_price', - 'wc.max_price', - ), - ), - '_prices_include_tax' => array(), - '_product_attributes' => array(), - '_product_version' => array(), - '_regular_price' => array( - 'alternatives' => array( - 'wc.regular_price', - ), - ), - '_sale_price' => array( - 'alternatives' => array( - 'wc.sale_price', - ), - ), - '_sale_price_dates_from' => array(), - '_sale_price_dates_to' => array(), - '_sku' => array( 'searchable_in_all_content' => true ), - '_stock_status' => array(), - '_wc_average_rating' => array( - 'alternatives' => array( - 'wc.ave_rating_score', - ), - ), - '_wc_rating_count' => array( - 'alternatives' => array( - 'wc.rating', // wc.rating.count_1, wc.rating.count_2, ... - ), - ), - '_wc_review_count' => array(), - '_weight' => array(), - '_width' => array(), - - // co-authors plus. - 'cap-description' => array( 'searchable_in_all_content' => true ), - 'cap-user_login' => array( 'searchable_in_all_content' => true ), - 'cap-user_email' => array(), - 'cap-last_name' => array( 'searchable_in_all_content' => true ), - 'cap-first_name' => array( 'searchable_in_all_content' => true ), - 'cap-display_name' => array( 'searchable_in_all_content' => true ), - 'cap-website' => array(), - 'cap-jabber' => array(), - 'cap-aim' => array(), - 'cap-twitter' => array(), - 'cap-facebook' => array(), - 'cap-google_plus' => array(), - 'cap-job_title' => array( 'searchable_in_all_content' => true ), - - // bbpress. - 'bbpl_like' => array(), - 'bbpress_discussion_comments_copied' => array(), - 'bbpress_discussion_tags_copied' => array(), - 'bbpress_discussion_topic_id' => array(), - 'bbpress_discussion_use_defaults' => array(), - 'bbpress_page_header_bg' => array(), - 'bbpress_title_bg' => array(), - 'use_bbpress_discussion_topic' => array(), - - // wpml. - 'tm_meta_wpml' => array(), - 'wpml_language' => array(), - 'wpml_media_lang' => array(), - 'wpml_media_processed' => array(), - - // blogger import. - 'blogger_author' => array( 'searchable_in_all_content' => true ), - 'blogger_blog' => array( 'searchable_in_all_content' => true ), - 'blogger_permalink' => array( 'searchable_in_all_content' => true ), - - // geo. - 'geo_address' => array( 'searchable_in_all_content' => true ), - 'geo_latitude' => array(), - 'geo_longitude' => array(), - 'geo_public' => array(), - 'geolocated' => array(), - 'geolocation_city' => array( 'searchable_in_all_content' => true ), - 'geolocation_country_long' => array( 'searchable_in_all_content' => true ), - 'geolocation_country_short' => array( 'searchable_in_all_content' => true ), - 'geolocation_formatted_address' => array( 'searchable_in_all_content' => true ), - 'geolocation_lat' => array(), - 'geolocation_long' => array(), - 'geolocation_postcode' => array( 'searchable_in_all_content' => true ), - 'geolocation_state_long' => array( 'searchable_in_all_content' => true ), - 'geolocation_state_short' => array( 'searchable_in_all_content' => true ), - - // wp-ultimate-recipe. - 'recipe_alternate_image' => array(), - 'recipe_cook_time' => array(), - 'recipe_cook_time_text' => array(), - 'recipe_description' => array( 'searchable_in_all_content' => true ), - 'recipe_ingredients' => array( 'searchable_in_all_content' => true ), - 'recipe_instructions' => array( 'searchable_in_all_content' => true ), - 'recipe_notes' => array( 'searchable_in_all_content' => true ), - 'recipe_nutritional' => array( 'searchable_in_all_content' => true ), - 'recipe_passive_time' => array(), - 'recipe_passive_time_text' => array(), - 'recipe_prep_time' => array(), - 'recipe_prep_time_text' => array(), - 'recipe_rating' => array(), - 'recipe_servings' => array(), - 'recipe_servings_normalized' => array(), - 'recipe_servings_type' => array(), - 'recipe_terms' => array( 'searchable_in_all_content' => true ), - 'recipe_terms_with_parents' => array(), - 'recipe_title' => array( 'searchable_in_all_content' => true ), - 'recipe_user_ratings' => array(), - 'recipe_user_ratings_rating' => array(), - - // generic fields. - // from advanced-custom-fields and metabox.io . - 'Link' => array(), - 'Location' => array(), - 'Title' => array( 'searchable_in_all_content' => true ), - 'ad_code' => array(), - 'address' => array(), - 'admin_mail' => array(), - 'admin_only' => array(), - 'advertisers' => array( 'searchable_in_all_content' => true ), - 'age' => array(), - 'aliases' => array(), - 'alternate_title' => array(), - 'ama_content' => array(), - 'amazon' => array(), - 'answer' => array( 'searchable_in_all_content' => true ), - 'area' => array(), - 'attention' => array(), - 'attr' => array(), - 'author' => array( 'searchable_in_all_content' => true ), - 'author_name' => array( 'searchable_in_all_content' => true ), - 'blog' => array(), - 'blog_id' => array(), - 'call_to_action' => array(), - 'campaign_preview' => array(), - 'canonical_url' => array(), - 'catch_text' => array(), - 'category' => array( 'searchable_in_all_content' => true ), - 'classificacao' => array(), - 'classification' => array(), - 'code' => array(), - 'codigo' => array(), - 'company' => array( 'searchable_in_all_content' => true ), - 'company_website' => array(), - 'config' => array(), - 'construction' => array(), - 'container_ids' => array(), - 'content' => array( 'searchable_in_all_content' => true ), - 'content_body-full_content' => array( 'searchable_in_all_content' => true ), - 'copyright' => array(), - 'custom_page_title' => array( 'searchable_in_all_content' => true ), - 'custom_permalink' => array(), - 'customize' => array(), - 'data' => array(), - 'date' => array(), - 'day' => array(), - 'descripcion' => array( 'searchable_in_all_content' => true ), - 'description' => array( 'searchable_in_all_content' => true ), - 'display_settings' => array(), - 'display_type' => array(), - 'duration' => array(), - 'embed' => array(), - 'entity_ids' => array(), - 'entity_types' => array(), - 'event_subtitle' => array( 'searchable_in_all_content' => true ), - 'excluded_container_ids' => array(), - 'exclusions' => array(), - 'experience' => array(), - 'external_url' => array(), - 'featured' => array(), - 'featured_image' => array(), - 'featured_post' => array(), - 'featured_story' => array(), - 'fee' => array(), - 'filter' => array(), - 'follow' => array(), - 'footer_text' => array(), - 'from_header' => array(), - 'fullscreen_view' => array(), - 'gallery' => array(), - 'genre' => array( 'searchable_in_all_content' => true ), - 'guest_bio' => array(), - 'guest_name' => array(), - 'guests' => array( 'searchable_in_all_content' => true ), - 'has_variations' => array(), - 'hashtag' => array(), - 'header_image' => array(), - 'hidden_from_ui' => array(), - 'hide_on_screen' => array(), - 'homepage_order' => array(), - 'hours' => array(), - 'i18n' => array(), - 'id' => array(), - 'image' => array(), - 'image_size' => array(), - 'image_source' => array(), - 'index' => array(), - 'intro_text' => array( 'searchable_in_all_content' => true ), - 'job_mention' => array( 'searchable_in_all_content' => true ), - 'keywords' => array( 'searchable_in_all_content' => true ), - 'latest_news' => array(), - 'layout' => array(), - 'link' => array(), - 'link_dump' => array( 'searchable_in_all_content' => true ), - 'link_url' => array(), - 'location' => array(), - 'logo' => array(), - 'main_title' => array( 'searchable_in_all_content' => true ), - 'maximum_entity_count' => array(), - 'media' => array(), - 'mentions' => array(), - 'messages' => array(), - 'meta_description' => array( 'searchable_in_all_content' => true ), - 'meta_id' => array(), - 'meta_index' => array(), - 'meta_key' => array(), - 'meta_value' => array(), - 'modal-dialog-id' => array(), - 'name' => array( 'searchable_in_all_content' => true ), - 'nombre' => array( 'searchable_in_all_content' => true ), - 'notes' => array( 'searchable_in_all_content' => true ), - 'options' => array(), - 'order_by' => array(), - 'order_direction' => array(), - 'original_cats' => array(), - 'original_headers' => array(), - 'original_link' => array(), - 'original_message' => array(), - 'original_subject' => array(), - 'original_title' => array(), - 'original_to' => array(), - 'other_setting' => array(), - 'page_canonical' => array(), - 'page_layout' => array(), - 'page_sidebar' => array(), - 'page_tags' => array(), - 'panels_data' => array(), - 'parking' => array(), - 'pdf_upload' => array(), - 'people_mentioned' => array(), - 'photo' => array(), - 'play_time' => array(), - 'position' => array(), - 'post-rating' => array(), - 'post_background' => array(), - 'post_color' => array(), - 'post_sidebar' => array(), - 'post_subtitle' => array( 'searchable_in_all_content' => true ), - 'price' => array(), - 'publication' => array(), - 'rating' => array(), - 'ratings_average' => array(), - 'ratings_score' => array(), - 'ratings_users' => array(), - 'relation' => array(), - 'reply_to_header' => array(), - 'required' => array(), - 'returns' => array(), - 'review_post' => array(), - 'rule' => array(), - 'section' => array( 'searchable_in_all_content' => true ), - 'selected_links' => array(), - 'session_transcript' => array(), - 'settings' => array(), - 'sex' => array(), - 'shares_count' => array(), - 'show_description' => array( 'searchable_in_all_content' => true ), - 'show_page_title' => array(), - 'show_notes' => array(), - 'show_notes_preview' => array(), - 'side' => array(), - 'sidebar' => array(), - 'site' => array(), - 'situation' => array(), - 'slide_template' => array(), - 'slug' => array(), - 'sortorder' => array(), - 'source' => array(), - 'start_date' => array(), - 'status' => array(), - 'styles' => array(), - 'subtitle' => array( 'searchable_in_all_content' => true ), - 'subtitulo' => array(), - 'success' => array(), - 'summary' => array( 'searchable_in_all_content' => true ), - 'synopsis' => array( 'searchable_in_all_content' => true ), - 'tel' => array(), - 'tema' => array(), - 'testimonial' => array(), - 'testimonial_author' => array(), - 'text_already_subscribed' => array(), - 'text_error' => array(), - 'text_invalid_email' => array(), - 'text_not_subscribed' => array(), - 'text_required_field_missing' => array(), - 'text_subscribed' => array(), - 'text_unsubscribed' => array(), - 'thumbnail' => array(), - 'time' => array(), - 'time_jump_list' => array( 'searchable_in_all_content' => true ), - 'title' => array( 'searchable_in_all_content' => true ), - 'title_view' => array(), - 'titre' => array( 'searchable_in_all_content' => true ), - 'titulo' => array( 'searchable_in_all_content' => true ), - 'to_header' => array(), - 'toc' => array(), - 'transcript' => array( 'searchable_in_all_content' => true ), - 'transport_uri' => array(), - 'type' => array(), - 'url' => array(), - 'validation' => array(), - 'value' => array(), - 'values' => array(), - 'variation' => array(), - 'video' => array(), - 'video_type' => array(), - 'video_url' => array(), - 'videopress_guid' => array(), - 'website' => array(), - 'weight' => array(), - 'year' => array(), - - // wp.com martketplace search - @see https://wp.me/pdh6GB-Ax#comment-2104 - '_app_icon' => array(), - '_featured_product_video' => array(), - 'wpcom_marketplace_org_slug' => array(), - '_wc_general_product_dependency_theme' => array(), - '_wc_general_product_dependency_plugin' => array(), - 'wpcom_marketplace_product_extra_fields' => array(), - - ); // end indexed post meta. - - /** - * Postmeta being considered for indexing - * but currently not in the index - * this list is really only for documentation. - * - * @static - * @access private - * @var array - */ - private static $unindexed_postmeta = array( - - // Core. - '_wp_attached_file' => array(), - '_wp_attachment_context' => array(), - '_wp_attachment_image_alt' => array(), - '_wp_attachment_is_custom_header' => array(), - '_wp_attachment_metadata' => array(), - '_wp_desired_post_slug' => array(), - '_wp_old_date' => array(), - '_wp_old_slug' => array(), - '_wp_page_template' => array(), - - // WooCommerce products. - // See https://github.com/woocommerce/woocommerce/blob/8ed6e7436ff87c2153ed30edd83c1ab8abbdd3e9/includes/data-stores/class-wc-product-data-store-cpt.php#L21 . - '_backorders' => array(), - '_default_attributes' => array(), - '_download_expiry' => array(), - '_download_limit' => array(), - '_download_permissions_granted' => array(), - '_downloadable_files' => array(), - '_file_paths' => array(), - '_manage_stock' => array(), - '_product_image_gallery' => array(), - '_purchase_note' => array(), - '_recorded_sales' => array(), - '_sold_individually' => array(), - '_stock' => array(), - '_tax_class' => array(), - '_tax_status' => array(), - '_thumbnail_id' => array(), - '_upsell_ids' => array(), - '_variation_description' => array(), - '_virtual' => array(), - '_visibility' => array(), - 'coupon_amount' => array(), - 'default_source' => array(), - 'discount_type' => array(), - 'exclude_sale_items' => array(), - 'expiry_date' => array(), - - // Woocommerce orders and refunds. - // See https://github.com/woocommerce/woocommerce/blob/8ed6e7436ff87c2153ed30edd83c1ab8abbdd3e9/includes/data-stores/class-wc-order-data-store-cpt.php#L27 . - // See https://github.com/woocommerce/woocommerce/blob/b8a2815ae546c836467008739e7ff5150cb08e93/includes/data-stores/class-wc-order-refund-data-store-cpt.php#L20 . - '_billing_address_1' => array(), - '_billing_address_2' => array(), - '_billing_address_index' => array(), - '_billing_city' => array(), - '_billing_company' => array(), - '_billing_country' => array(), - '_billing_email' => array(), - '_billing_first_name' => array(), - '_billing_last_name' => array(), - '_billing_phone' => array(), - '_billing_postcode' => array(), - '_billing_state' => array(), - '_cart_discount' => array(), - '_cart_discount_tax' => array(), - '_completed_date' => array(), - '_created_via' => array(), - '_customer_ip_address' => array(), - '_customer_user_agent' => array(), - '_date_completed' => array(), - '_date_paid' => array(), - '_order_currency' => array(), - '_order_key' => array(), - '_order_shipping' => array(), - '_order_shipping_tax' => array(), - '_order_stock_reduced' => array(), - '_order_tax' => array(), - '_order_total' => array(), - '_order_version' => array(), - '_paid_date' => array(), - '_payment_method' => array(), - '_payment_method_title' => array(), - '_payment_tokens' => array(), - '_recorded_coupon_usage_counts' => array(), - '_refund_amount' => array(), - '_refund_reason' => array(), - '_refunded_by' => array(), - '_shipping_address_1' => array(), - '_shipping_address_2' => array(), - '_shipping_address_index' => array(), - '_shipping_city' => array(), - '_shipping_company' => array(), - '_shipping_country' => array(), - '_shipping_first_name' => array(), - '_shipping_last_name' => array(), - '_shipping_postcode' => array(), - '_shipping_state' => array(), - '_transaction_id' => array(), - - // aioseop. - '_aioseop_description' => array(), - '_aioseop_keywords' => array(), - '_aioseop_title' => array(), - - // yoast. - '_yoast_wpseo_authorship' => array(), - '_yoast_wpseo_bctitle' => array(), - '_yoast_wpseo_canonical' => array(), - '_yoast_wpseo_content_score' => array(), - '_yoast_wpseo_focuskw' => array(), - '_yoast_wpseo_focuskw_text_input' => array(), - '_yoast_wpseo_google-plus-description' => array(), - '_yoast_wpseo_google-plus-image' => array(), - '_yoast_wpseo_linkdex' => array(), - '_yoast_wpseo_meta-robots-adv' => array(), - '_yoast_wpseo_meta-robots-nofollow' => array(), - '_yoast_wpseo_meta-robots-noindex' => array(), - '_yoast_wpseo_metadesc' => array(), - '_yoast_wpseo_metakeywords' => array(), - '_yoast_wpseo_opengraph-description' => array(), - '_yoast_wpseo_opengraph-image' => array(), - '_yoast_wpseo_opengraph-title' => array(), - '_yoast_wpseo_primary_byline' => array(), - '_yoast_wpseo_primary_category' => array(), - '_yoast_wpseo_primary_product_cat' => array(), - '_yoast_wpseo_primary_sponsor-type' => array(), - '_yoast_wpseo_primary_tema_category' => array(), - '_yoast_wpseo_primary_wpdmcategory' => array(), - '_yoast_wpseo_primary_wt_portfolio_category' => array(), - '_yoast_wpseo_redirect' => array(), - '_yoast_wpseo_sitemap-include' => array(), - '_yoast_wpseo_sitemap-prio' => array(), - '_yoast_wpseo_title' => array(), - '_yoast_wpseo_twitter-description' => array(), - '_yoast_wpseo_twitter-image' => array(), - - // bbpress. - 'bbppu_read_by' => array(), - '_bbp_activity_id' => array(), - '_bbp_attachment' => array(), - '_bbp_attachment_upload_error' => array(), - '_bbp_forum_id' => array(), - '_bbp_forum_parent_id' => array(), - '_bbp_forum_subforum_count' => array(), - '_bbp_forum_type' => array(), - '_bbp_group_ids' => array(), - '_bbp_last_active_id' => array(), - '_bbp_last_active_time' => array(), - '_bbp_last_reply_id' => array(), - '_bbp_last_topic_id' => array(), - '_bbp_old_forum_id' => array(), - '_bbp_old_sticky_status' => array(), - '_bbp_old_topic_id' => array(), - '_bbp_post_id' => array(), - '_bbp_reply_count' => array(), - '_bbp_reply_is_private' => array(), - '_bbp_reply_to' => array(), - '_bbp_revision_log' => array(), - '_bbp_status' => array(), - '_bbp_sticky_topics' => array(), - '_bbp_topic_count' => array(), - '_bbp_topic_id' => array(), - '_bbp_total_reply_count' => array(), - '_bbp_total_topic_count' => array(), - '_bbp_voice_count' => array(), - - // ??? - '_locale' => array(), - - // wp-job-manager. - '_job_title' => array(), - '_job_description' => array(), - - // wpml. - '_wpml_media_duplicate' => array(), - '_wpml_media_featured' => array(), - - // generic fields. - 'ad_clicks_count' => array(), - 'email' => array(), - 'usage_count' => array(), - 'user_mail' => array(), - 'views' => array(), - '_EventAllDay' => array(), - '_EventCost' => array(), - '_EventCurrencyPosition' => array(), - '_EventCurrencySymbol' => array(), - '_EventDuration' => array(), - '_EventEndDate' => array(), - '_EventEndDateUTC' => array(), - '_EventOrganizerID' => array(), - '_EventOrigin' => array(), - '_EventShowMap' => array(), - '_EventShowMapLink' => array(), - '_EventStartDate' => array(), - '_EventStartDateUTC' => array(), - '_EventTimezone' => array(), - '_EventTimezoneAbbr' => array(), - '_EventURL' => array(), - '_EventVenueID' => array(), - '_OrganizerEmail' => array(), - '_OrganizerOrganizer' => array(), - '_OrganizerOrigin' => array(), - '_OrganizerPhone' => array(), - '_OrganizerWebsite' => array(), - '_VenueAddress' => array(), - '_VenueCity' => array(), - '_VenueCountry' => array(), - '_VenueOrigin' => array(), - '_VenuePhone' => array(), - '_VenueProvince' => array(), - '_VenueShowMap' => array(), - '_VenueShowMapLink' => array(), - '_VenueState' => array(), - '_VenueStateProvince' => array(), - '_VenueURL' => array(), - '_VenueVenue' => array(), - '_VenueVenueID' => array(), - '_VenueZip' => array(), - '_description' => array(), - '_edit_last' => array(), - '_feedback_all_fields' => array(), - '_feedback_author' => array(), - '_feedback_author_email' => array(), - '_feedback_author_url' => array(), - '_feedback_contact_form_url' => array(), - '_feedback_ip' => array(), - '_feedback_subject' => array(), - '_layout' => array(), - '_links_to' => array(), - '_links_to_target' => array(), - '_mail' => array(), - '_mail_2' => array(), - '_messages' => array(), - '_numero' => array(), - '_post_restored_from' => array(), - '_video_url' => array(), - '_website' => array(), - - ); // end unindexed post meta. - - /** - * List of indexed taxonomy slugs - VARCHAR(32) - * - * @access private - * @static - * - * @var array - */ - private static $taxonomies_to_sync = array( - - // Core. - 'link_category', - 'nav_menu', - 'post_format', // Special, limited to certain values. - - // bbpress. - 'topic', - 'topic-tag', - 'topics', - - // buddypress. - 'bp-email-type', - 'bp-email-type', - 'bp_docs_access', - 'bp_docs_associated_item', - 'bp_docs_comment_access', - 'bp_docs_doc_in_folder', - 'bp_docs_folder_in_group', - 'bp_docs_tag', - 'bp_member_type', - - // co-authors plus. - 'author', - - // events calendar plus. - // the events calendar. - 'event-categories', - 'event-category', - 'event-tag', - 'event-tags', - 'event-type', - 'event-venue', - 'event_category', - 'event_location', - 'event_organizer', - 'event_tag', - 'event_type', - 'event_type_2', - 'event_users', - 'events_categories', - 'events_category', - 'events_feeds', - 'events_tags', - 'tribe_events_cat', - - // jetpack. - 'jetpack-portfolio-tag', - 'jetpack-portfolio-type', - 'jetpack-search-tag0', - 'jetpack-search-tag1', - 'jetpack-search-tag2', - 'jetpack-search-tag3', - 'jetpack-search-tag4', - 'jetpack-search-tag5', - 'jetpack-search-tag6', - 'jetpack-search-tag7', - 'jetpack-search-tag8', - 'jetpack-search-tag9', - - // nextgen gallery. - 'ngg_tag', - - // polylang. - // wpml. - 'language', - 'post_translations', - 'term_language', - 'term_translations', - 'translation_priority', - - // woocommerce. - 'pa_accessory-type', - 'pa_actor', - 'pa_age', - 'pa_ambulance', - 'pa_amount', - 'pa_arm-roll', - 'pa_aspectratio', - 'pa_audiencerating', - 'pa_author', - 'pa_axle', - 'pa_battery', - 'pa_belakang', - 'pa_binding', - 'pa_body-type', - 'pa_bore-x-stroke-mm', - 'pa_box-cargo', - 'pa_brakes', - 'pa_brand', - 'pa_brands', - 'pa_bus', - 'pa_c', - 'pa_cabin-to-end', - 'pa_capacity', - 'pa_catalognumberlist', - 'pa_ce-keurmerk', - 'pa_chassis-front', - 'pa_chassis-rear', - 'pa_chassis-weight-kg', - 'pa_chip-log', - 'pa_clothing-size', - 'pa_clutch', - 'pa_clutch-type', - 'pa_collection', - 'pa_color', - 'pa_colors', - 'pa_colour', - 'pa_compactor', - 'pa_condition', - 'pa_cor', - 'pa_couleur', - 'pa_country', - 'pa_countryregion-of-manufacture', - 'pa_crane', - 'pa_creator', - 'pa_culoare', - 'pa_customerpackagetype', - 'pa_depan', - 'pa_depan-belakang', - 'pa_department', - 'pa_design', - 'pa_diameter', - 'pa_diameter-cakram', - 'pa_dimension-mm', - 'pa_dimensions', - 'pa_director', - 'pa_disc-diameter', - 'pa_drive-system', - 'pa_dump', - 'pa_ean', - 'pa_eanlist', - 'pa_edition', - 'pa_electric-battery', - 'pa_engine-model', - 'pa_engine-size', - 'pa_ethnicity', - 'pa_exhaust-brake', - 'pa_fabric', - 'pa_farbe', - 'pa_farg', - 'pa_farge', - 'pa_features', - 'pa_final-gear-ratio', - 'pa_finish', - 'pa_fire-fighting', - 'pa_fits', - 'pa_flat-bed', - 'pa_flavour', - 'pa_format', - 'pa_fragrance', - 'pa_frame', - 'pa_front', - 'pa_front-overhang', - 'pa_front-rear', - 'pa_front-tread', - 'pa_fuel-tank', - 'pa_fuel-type', - 'pa_garantie', - 'pa_geadviseerd-accu-type', - 'pa_gear-ratio', - 'pa_gender', - 'pa_genre', - 'pa_gewicht-exclusief-accu', - 'pa_gift-card-amount', - 'pa_grade-ability-tan-o', - 'pa_groesse', - 'pa_gtin', - 'pa_gvwr-gcwr', - 'pa_hardwareplatform', - 'pa_hazardousmaterialtype', - 'pa_height', - 'pa_hekmotor-of-boegmotor', - 'pa_helmet-size', - 'pa_hersteller', - 'pa_high-blow-tank', - 'pa_hoehe', - 'pa_inhoud', - 'pa_isadultproduct', - 'pa_isbn', - 'pa_iseligiblefortradein', - 'pa_itemdimensions', - 'pa_itempartnumber', - 'pa_kemudi-tipe', - 'pa_kleur', - 'pa_kopling-tipe', - 'pa_label', - 'pa_languages', - 'pa_lbs', - 'pa_legaldisclaimer', - 'pa_lengte-aansluitkabel', - 'pa_length', - 'pa_liquid-tank', - 'pa_location', - 'pa_losse-motor-complete-set', - 'pa_maat', - 'pa_main-brake', - 'pa_make', - 'pa_manufacturer', - 'pa_manufacturer-part-number', - 'pa_manufacturermaximumage', - 'pa_manufacturerminimumage', - 'pa_manufacturerpartswarrantydesc', - 'pa_masseinheit', - 'pa_material', - 'pa_mau-sac', - 'pa_maximum-power-ps-rpm', - 'pa_maximum-speed', - 'pa_maximum-torque-kgm-rpm', - 'pa_mediatype', - 'pa_megethos', - 'pa_merk', - 'pa_metal-type', - 'pa_min-turning-circle', - 'pa_mixer', - 'pa_model', - 'pa_model-tipe', - 'pa_model-type', - 'pa_modelo', - 'pa_mount', - 'pa_mpn', - 'pa_nicotine-strength', - 'pa_nos-of-cylinder', - 'pa_nos-of-tire', - 'pa_numberofdiscs', - 'pa_numberofitems', - 'pa_numberofpages', - 'pa_offset', - 'pa_open-cargo', - 'pa_operatingsystem', - 'pa_options', - 'pa_other-part-number', - 'pa_overall-height', - 'pa_overall-length', - 'pa_overall-width', - 'pa_overview', - 'pa_packagedimensions', - 'pa_packagequantity', - 'pa_pages', - 'pa_parking-brake', - 'pa_part-number', - 'pa_partnumber', - 'pa_pattern', - 'pa_pattern2', - 'pa_performa', - 'pa_pictureformat', - 'pa_pin-size', - 'pa_piston-displacement-cc', - 'pa_ploshhad', - 'pa_plug-type', - 'pa_power', - 'pa_product', - 'pa_productgroup', - 'pa_producttypename', - 'pa_publicationdate', - 'pa_publisher', - 'pa_quantity', - 'pa_rear', - 'pa_rear-overhang', - 'pa_rear-tread', - 'pa_refrigerated-box', - 'pa_region', - 'pa_regioncode', - 'pa_releasedate', - 'pa_rem-parkir', - 'pa_rem-pelambat', - 'pa_rem-utama', - 'pa_reverse', - 'pa_runningtime', - 'pa_scent', - 'pa_schachtlengte', - 'pa_seeds', - 'pa_series', - 'pa_setting', - 'pa_sex', - 'pa_shape', - 'pa_shirt-size', - 'pa_size', - 'pa_sizes', - 'pa_sku', - 'pa_sky-lift', - 'pa_sleeve-length', - 'pa_snelheidsregeling', - 'pa_staart', - 'pa_steering', - 'pa_steering-type', - 'pa_storlek', - 'pa_studio', - 'pa_stuwkracht-lbs', - 'pa_style', - 'pa_suspensions', - 'pa_taille', - 'pa_talla', - 'pa_tamanho', - 'pa_tamano', - 'pa_taxi', - 'pa_ticket-type', - 'pa_tire-size', - 'pa_total-chassis-weight', - 'pa_towing-truck', - 'pa_tradeinvalue', - 'pa_trailer-t-head', - 'pa_transmisi-tipe', - 'pa_transmission', - 'pa_transmission-type', - 'pa_types', - 'pa_ukuran', - 'pa_upc', - 'pa_upclist', - 'pa_variation', - 'pa_vehicle-carrier', - 'pa_vergelijkbaar-stuwkracht', - 'pa_vermogen', - 'pa_voltage', - 'pa_volume', - 'pa_warranty', - 'pa_weight', - 'pa_wheel-base', - 'pa_wheel-configuration', - 'pa_wheel-disc-size', - 'pa_width', - 'pa_zout-water-geschikt', - 'product', - 'product-brand', - 'product_brand', - 'product-category', - 'product_cat', - 'product_delivery_time', - 'product_delivery_times', - 'product_price_label', - 'product_sale_labels', - 'product_shipping_class', - 'product_tag', - 'product_type', - 'product_unit', - 'product_visibility', - 'products', - - // wp-job-manager. - 'job-category', - 'job-location', - 'job-type', - 'job_cat', - 'job_category', - 'job_listing_category', - 'job_listing_label', - 'job_listing_region', - 'job_listing_tag', - 'job_listing_type', - 'job_salary', - 'job_tag', - 'job_type', - 'jobman_category', - 'jobpost_category', - 'jobpost_job_type', - 'jobpost_location', - 'resume_category', - 'resume_groups', - 'resume_job_type', - 'resume_job_type', - 'resume_languages', - 'resume_region', - 'resume_skill', - 'resume_specialities', - - // generic. - '_resource', - 'acadp_categories', - 'acadp_locations', - 'action-group', - 'activity', - 'actor', - 'actors', - 'ad-group', - 'adace-ad-group', - 'adace-sponsor', - 'additional_features', - 'adv_location', - 'advanced_ads_groups', - 'advert_category', - 'affcoups_coupon_category', - 'affcoups_coupon_type', - 'ai_log_context', - 'ai_log_level', - 'al_product-cat', - 'aol_ad_category', - 'aol_ad_location', - 'aol_ad_type', - 'aol_application_status', - 'area', - 'article-slug', - 'asgarosforum-category', - 'asgarosforum-usergroup', - 'attachment_category', - 'attachment_tag', - 'atum_location', - 'audience_type', - 'avhec_catgroup', - 'bartype', - 'baths', - 'beds', - 'bepro_listing_types', - 'blog_category', - 'booked_custom_calendars', - 'brand', - 'brands', - 'business', - 'business_cat', - 'business_category', - 'bwg_tag', - 'byline', - 'calendar_category', - 'calendar_feed', - 'calendar_type', - 'campaign_category', - 'campaign_tag', - 'carousel_cat', - 'carousels_category', - 'case27_job_listing_tags', - 'categories', - 'category_media', - 'category_portfolio', - 'celebrity_cat', - 'chapters', - 'chronosly_category', - 'city', - 'classified_listing_type', - 'client-types', - 'clients_groups', - 'cm-business-category', - 'cmdm_category', - 'cn_log_type', - 'coderevolution_post_source', - 'collection', - 'community', - 'companies', - 'company', - 'cont_category', - 'content_audit', - 'country', - 'course', - 'course-cat', - 'course-category', - 'course_cat', - 'course_category', - 'course_difficulty', - 'course_tag', - 'courses_type', - 'cp_campaign', - 'cp_recipe_category', - 'csco_post_featured', - 'ct_status', - 'ctl-stories', - 'cuisine', - 'dc_vendor_shop', - 'ddownload_category', - 'ddownload_tag', - 'dealstore', - 'department', - 'departments', - 'department-company', - 'developed-by', - 'dfads_group', - 'dgfw_gift_categories', - 'director', - 'district', - 'dlm_download_category', - 'dlm_download_tag', - 'doc_tag', - 'document-category', - 'document-type', - 'download_artist', - 'download_category', - 'download_tag', - 'downloads_filter', - 'dps_book', - 'dt_gallery_category', - 'dt_logos_category', - 'dt_portfolio_category', - 'dt_team_category', - 'dt_testimonials_category', - 'dtcast', - 'dtcreator', - 'dtdirector', - 'dtnetworks', - 'dtstudio', - 'dtyear', - 'dvteamtaxonomy', - 'dwqa-question_category', - 'dwqa-question_tag', - 'eafl_category', - 'easy-testimonial-category', - 'ecwd_event_category', - 'edd_log_type', - 'edition', - 'ef_editorial_meta', - 'ef_usergroup', - 'element_category', - 'elementor_library_type', - 'employees_category', - 'encyclopedia-tag', - 'envira-tag', - 'epkb_post_type_1_category', - 'espresso_event_categories', - 'espresso_event_type', - 'essential_grid_category', - 'et_post_format', - 'faq-group', - 'faq-tags', - 'faq-topic', - 'faq_cat', - 'faq_categories', - 'faq_category', - 'faqs-category', - 'fdm-menu-section', - 'feature', - 'featured_item_category', - 'featured_item_tag', - 'feedback_type', - 'feeds', - 'fl-builder-template-type', - 'flamingo_inbound_channel', - 'follow_up_email_campaign', - 'follow_up_email_type', - 'following_users', - 'football-team-taxo', - 'fpd_design_category', - 'gallery-category', - 'gallery_cat', - 'gallery_categories', - 'gallery_category', - 'gallery_entries', - 'gallerycat', - 'gd_event_tags', - 'gd_eventcategory', - 'gd_place_tags', - 'gd_placecategory', - 'genre', - 'genres', - 'gg_connect_hub', - 'give_log_type', - 'gn-genre', - 'gn-location-1', - 'gn-location-2', - 'gn-location-3', - 'gp_hubs', - 'gp_portfolios', - 'gp_videos', - 'group', - 'group-documents-category', - 'groups', - 'hashtags', - 'hotel_facility', - 'ia_invited_groups', - 'ia_invitees', - 'incsub_wiki_category', - 'industry', - 'ingredient', - 'insight-type', - 'issue', - 'issuem_issue', - 'issuem_issue_tags', - 'jbp_category', - 'karma-slider-category', - 'klaviyo_shop_cart_status', - 'kwlogos-carousel', - 'layout_category', - 'layout_type', - 'ld_course_category', - 'ld_course_tag', - 'ld_lesson_category', - 'ld_lesson_tag', - 'ld_topic_tag', - 'lesson-tag', - 'level', - 'lingotek_hash', - 'lingotek_profile', - 'link_library_category', - 'linkage', - 'list-tags', - 'listing-category', - 'listing_amenities', - 'listing_category', - 'liveblog', - 'llms_access_plan_visibility', - 'llms_product_visibility', - 'localisation', - 'location', - 'location-tag', - 'locations', - 'magazine', - 'map_location_categories', - 'masonry_gallery_category', - 'mc-event-category', - 'mec_category', - 'mec_location', - 'mec_organizer', - 'media-category', - 'media-tags', - 'media_category', - 'media_folder', - 'member_cat', - 'mentions', - 'mesh_template_types', - 'ml-slider', - 'module', - 'module-tag', - 'module_width', - 'movie_cat', - 'mpp-component', - 'mpp-status', - 'mpp-type', - 'muvicast', - 'muvicountry', - 'muvidirector', - 'muviindex', - 'muviquality', - 'muviyear', - 'news-category', - 'news-tag', - 'news-type', - 'news_type_cat', - 'news_category', - 'nova_menu', - 'nova_menu_item_label', - 'offer-types', - 'organization', - 'our_team_category', - 'page_category', - 'parisrestaurant', - 'parissauna', - 'partner_category', - 'partners', - 'paswdestinatari', - 'paypal_ipn_type', - 'pdf_lv_tag', - 'pec_events_category', - 'people', - 'people-department', - 'people-expertise', - 'people-location', - 'perfect_quotes_category', - 'performer', - 'person', - 'personnal-category', - 'pexcontentslider_category', - 'pexfullslider_category', - 'pexnivoslider_category', - 'pexpricing_category', - 'pexservice_category', - 'pextestimonial_category', - 'pf_feed_item_tag', - 'pg_sas_type', - 'photo_tag', - 'phototype', - 'pj-categs', - 'pj-tags', - 'pl-categs', - 'placement', - 'plan_status', - 'platform', - 'player', - 'plugins_categories', - 'podcast', - 'pojo_sidebars', - 'popup_category', - 'pornstars', - 'portada', - 'portcat', - 'portfolio-category', - 'portfolio-gallery', - 'portfolio-status', - 'portfolio-skills', - 'portfolio-tag', - 'portfolio-tags', - 'portfolio-type', - 'portfolio-types', - 'portfolio_cat', - 'portfolio_categories', - 'portfolio_category', - 'portfolio_cats', - 'portfolio_client', - 'portfolio_entries', - 'portfolio_filter', - 'portfolio_in', - 'portfolio_label', - 'portfolio_skills', - 'portfolio_tag', - 'portfolio_tags', - 'portfolio_type', - 'posicao', - 'post-type', - 'post_format', - 'post_series', - 'pp_editorial_meta', - 'pp_notify_role', - 'pp_usergroup', - 'pricingcats', - 'print_section', - 'print_status', - 'product_asset_class', - 'product_name', - 'programs', - 'project-attributes', - 'project-cat', - 'project-category', - 'project-type', - 'project_category', - 'project_tag', - 'projects_category', - 'projects_tag', - 'prominence', - 'promotion-categories', - 'property-city', - 'property-feature', - 'property-status', - 'property-type', - 'property-types', - 'property_action_category', - 'property_area', - 'property_category', - 'property_city', - 'property_feature', - 'property_status', - 'property_type', - 'province', - 'provinces', - 'publisher', - 'pwb-brand', - 'qmn_log_type', - 'qualification', - 'qualifications', - 'quality', - 'question-category', - 'question-tag', - 'question-type', - 'question_cat', - 'question_category', - 'question_tag', - 'quiz', - 'quiz-type', - 'quote_status', - 'rating', - 'reaction', - 'recipe-category', - 'recipe_category', - 'recipe_type', - 'region', - 'registrant-event', - 'related_keywords', - 'release-date', - 'resource-type', - 'resource_category', - 'resource_type', - 'resourcetype', - 'review-type', - 'review_category', - 'rodzaj', - 'role', - 'room_category', - 'room_tag', - 'roomtype', - 'rubriek_categorie', - 'savedreply', - 'schools', - 'scope', - 'scores_cat', - 'sdm_categories', - 'sdm_tags', - 'season', - 'secondary_html_features', - 'section', - 'sector', - 'series', - 'series_of_posts', - 'services_group', - 'serving', - 'shop_cart_status', - 'shop_cat', - 'shop_order_status', - 'shop_vendor', - 'shop_warranty_status', - 'shopp_category', - 'shopr_category', - 'show', - 'simple_link_category', - 'site-review-category', - 'sizes', - 'skill', - 'skill_level', - 'skills', - 'sld_cat', - 'slide-page', - 'slide-types', - 'slide_categories', - 'slide_type', - 'slider', - 'slider-locations', - 'slider_category', - 'slides_category', - 'slideshow', - 'sm-category', - 'snax_format', - 'sngg_media_tags', - 'solution_channel', - 'source_domain', - 'source_id', - 'sp_league', - 'sp_position', - 'sp_role', - 'sp_season', - 'sp_venue', - 'speaker', - 'speakers', - 'special-feature', - 'specialty', - 'spnl_log_type', - 'sponsor_categories', - 'sponsor_category', - 'sponsor_type', - 'spot_tag', - 'st_af_category', - 'st_af_tags', - 'staff', - 'staff-member-category', - 'staff-member-group', - 'staff_category', - 'staffgroups', - 'state', - 'status', - 'store', - 'stores', - 'studio', - 'study_level', - 'style', - 'style_category', - 'sub_transaction_action', - 'sub_transaction_result', - 'subcategory', - 'subject', - 'subscription_status', - 'swift-slider-category', - 'syn_sitegroup', - 'szbl-content-tag', - 'task-queue', - 'tax_feature', - 'tcb_symbols_tax', - 'tcp_product_category', - 'team', - 'team-category', - 'team_cat', - 'team_categories', - 'team_category', - 'team_cats', - 'team_department', - 'team_designation', - 'team_group', - 'team_member_position', - 'team_mfcategory', - 'teams', - 'tenant_categories', - 'tenant_location', - 'tender-category', - 'test-type', - 'testimonial-category', - 'testimonial-group', - 'testimonial-types', - 'testimonial_categories', - 'testimonial_category', - 'testimonials-category', - 'testimonials_category', - 'th_events_cat', - 'th_galleries_cat', - 'thegem_clients_sets', - 'thegem_news_sets', - 'thegem_portfolios', - 'thegem_quickfinders', - 'thegem_teams', - 'thegem_testimonials_sets', - 'theme', - 'themefusion_es_groups', - 'themes_categories', - 'themo_cpt_group', - 'themo_project_type', - 'themo_room_type', - 'thirstylink-category', - 'ticket_channel', - 'ticket_priority', - 'timeline_post_tag', - 'tipo', - 'tipologie', - 'tips', - 'tm-testimonials_category', - 'tm_testimonial_group', - 'tooltips_categories', - 'tour_category', - 'tour_destination', - 'tour_facility', - 'tour_phys', - 'tour_type', - 'tp_event_category', - 'transmission', - 'treatment-type', - 'tribe_events_cat', - 'truethemes-gallery-category', - 'tsas-category', - 'tshowcase-categories', - 'tsml_region', - 'ttshowcase_groups', - 'tvo_tags', - 'type', - 'types', - 'u_course_cat', - 'u_department', - 'u_event_cat', - 'ufaq-category', - 'ufaq-tag', - 'um_hashtag', - 'um_user_tag', - 'uncodeblock_category', - 'upg_cate', - 'urp-review-category', - 'us_portfolio_category', - 'us_testimonial_category', - 'user-group', - 'user_category', - 'user_status', - 'vendor', - 'venue', - 'video-category', - 'video-series', - 'video-tag', - 'video_category', - 'video_tag', - 'videos', - 'videos_categories', - 'voice_category', - 'vtmin_rule_category', - 'vtprd_rule_category', - 'w2dc-category', - 'w2dc-location', - 'w2dc-tag', - 'wcb_sponsor_level', - 'wcb_track', - 'wccf_checkout_field_field_type', - 'wccf_checkout_field_status', - 'wccf_order_field_field_type', - 'wccf_order_field_status', - 'wccf_product_field_field_type', - 'wccf_product_field_status', - 'wccf_product_prop_field_type', - 'wccf_product_prop_status', - 'wccf_user_field_field_type', - 'wccf_user_field_status', - 'wcfm_knowledgebase_category', - 'wcm_task_category', - 'wcpv_product_vendors', - 'wcs-instructor', - 'wcs-room', - 'wcs-type', - 'wdca_ad_categories', - 'webinar_type_cat', - 'where', - 'who', - 'wiki-category', - 'wiki_cats', - 'wl_entity_type', - 'workout_entries', - 'works-category', - 'wp-rest-api-log-method', - 'wp-rest-api-log-source', - 'wp-rest-api-log-status', - 'wp-type-activity-types', - 'wp-type-contacts-subtype', - 'wp-type-group', - 'wp_bannerize_tax', - 'wp_log_type', - 'wp_super_faq_category', - 'wpbdm-region', - 'wpbdp_category', - 'wpbdp_tag', - 'wpcm_make_model', - 'wpdmcategory', - 'wpfb_file_category', - 'wpfcas-category', - 'wpfd-category', - 'wplead_list_category', - 'wplss_logo_showcase_cat', - 'wpm-testimonial-category', - 'wpmf-category', - 'wpostahs-slider-category', - 'wprm_course', - 'wprm_cuisine', - 'wprm_ingredient', - 'wprm_keyword', - 'wprss_category', - 'wps_forum', - 'wpsc-variation', - 'wpsc_log_type', - 'wpsc_product_category', - 'wpseo_locations_category', - 'wpsisac_slider-category', - 'wpsl_store_category', - 'wpt_category', - 'wpt_result', - 'wpt_scale', - 'wpv_sermons_category', - 'wpvqgr_tag', - 'writer', - 'wyz_business_category', - 'wyz_business_rating_category', - 'wyz_business_tag', - 'wzkb_category', - 'year', - 'years', - 'yith_product_brand', - 'yith_shop_vendor', - 'yst_prominent_words', - 'zipcode', - 'zoninator_zones', - 'zrf_field_group', - - // End The Backlog @see https://wp.me/p9MPsk-X0. - 'bill-status', - 'etb-audience', - 'etb-state', - 'etb-target', - 'etb-topic', - 'etb-year', - 'foia-response-status', - 'target-type', - 'timeline-pillar', - 'timeline-type', - - // wp.com martketplace search - @see https://wp.me/pdh6GB-Ax#comment-2104 - 'wpcom_marketplace_categories', - - // wp.com a8c-support-theme taxonomies. - 'kb_category', - 'kb_tag', - - ); // end taxonomies. - - /** - * List of options to sync - * - * @access private - * @static - * - * @var array - */ - private static $options_to_sync = array( - 'jetpack_search_ai_prompt_override', - 'jetpack_search_color_theme', - 'jetpack_search_result_format', - 'jetpack_search_default_sort', - 'jetpack_search_overlay_trigger', - 'jetpack_search_excluded_post_types', - 'jetpack_search_highlight_color', - 'jetpack_search_enable_sort', - 'jetpack_search_inf_scroll', - 'jetpack_search_show_powered_by', - 'instant_search_enabled', - ); // end options. - - /* - * Taxonomies we know don't sync. - * See also sync/src/class-defaults.php - * - * 'network' - * 'post_status' - * 'product_cat' - * 'tags' - * - */ - - // - // Hooks into sync. - - /** - * Add Search post meta to the post meta whitelist. - * - * @param array $list Existing post meta whitelist. - * @return array Updated post meta whitelist. - */ - public function add_search_post_meta_whitelist( $list ) { - return array_merge( $list, static::get_all_postmeta_keys() ); - } - - /** - * Add Search options to the options whitelist. - * - * @param array $list Existing options whitelist. - * @return array Updated options whitelist. - */ - public function add_search_options_whitelist( $list ) { - return array_merge( $list, static::get_all_option_keys() ); - } - - // - // Indexing functions for wp.com. - - /** - * - * Check whether a postmeta or taxonomy 'key' is in the indexable - * list. This is called by the indexing code on wp.com to decide - * whether to include something in the index. - * - * @static - * @access public - * - * @param string $type Either 'postmeta' or 'taxonomy'. - * @param string $key The postmeta key or taxonomy name. - * @return boolean - */ - public static function is_indexable( $type, $key ) { - switch ( $type ) { - case 'postmeta': - return isset( self::$postmeta_to_sync[ $key ] ); - case 'taxonomy': - return in_array( $key, self::$taxonomies_to_sync, true ); - } - return false; - } - - /** - * - * Get the indexing spec for a postmeta key. - * - * @static - * @access public - * - * @param string $key The postmeta key. - * @return array The spec. - */ - public static function get_postmeta_spec( $key ) { - return self::$postmeta_to_sync[ $key ]; - } - - /** - * Get all post meta keys that get synced. - * - * @access public - * - * @return array List of post meta keys that get synced. - */ - public static function get_all_postmeta_keys() { - return array_keys( self::$postmeta_to_sync ); - } - - /** - * Get all option keys that get synced. - * - * @access public - * - * @return array List of option keys that get synced. - */ - public static function get_all_option_keys() { - return self::$options_to_sync; - } - - /** - * Get all unindexed postmeta. - * This is mostly for testing. - * - * @access public - * - * @return array List of postmeta that are not synced. - */ - public static function get_all_unindexed_postmeta_keys() { - return array_keys( self::$unindexed_postmeta ); - } - - /** - * Get all taxonomies that get synced. - * This is mostly for testing. - * - * @access public - * - * @return array List of taxonomies that get synced. - */ - public static function get_all_taxonomies() { - return self::$taxonomies_to_sync; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php deleted file mode 100644 index 83479d1d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php +++ /dev/null @@ -1,68 +0,0 @@ -table' ); - return 'term_relationships'; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - global $wpdb; - return $wpdb->term_relationships; - } - - /** - * Initialize term relationships action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_term_relationships', $callable, 10, 2 ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - // Full sync. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_term_relationships', array( $this, 'expand_term_relationships' ) ); - } - - /** - * Enqueue the term relationships actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param object $last_object_enqueued Last object enqueued. - * - * @return array Number of actions enqueued, and next module state. - * @todo This method has similarities with Automattic\Jetpack\Sync\Modules\Module::enqueue_all_ids_as_action. Refactor to keep DRY. - * @see Automattic\Jetpack\Sync\Modules\Module::enqueue_all_ids_as_action - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $last_object_enqueued ) { - global $wpdb; - $term_relationships_full_sync_item_size = Settings::get_setting( 'term_relationships_full_sync_item_size' ); - $limit = min( $max_items_to_enqueue * $term_relationships_full_sync_item_size, self::QUERY_LIMIT ); - $items_enqueued_count = 0; - $last_object_enqueued = $last_object_enqueued ? $last_object_enqueued : array( - 'object_id' => self::MAX_INT, - 'term_taxonomy_id' => self::MAX_INT, - ); - - while ( $limit > 0 ) { - /* - * SELECT object_id, term_taxonomy_id - * FROM $wpdb->term_relationships - * WHERE ( object_id = 11 AND term_taxonomy_id < 14 ) OR ( object_id < 11 ) - * ORDER BY object_id DESC, term_taxonomy_id DESC LIMIT 1000 - */ - $objects = $wpdb->get_results( $wpdb->prepare( "SELECT object_id, term_taxonomy_id FROM $wpdb->term_relationships WHERE ( object_id = %d AND term_taxonomy_id < %d ) OR ( object_id < %d ) ORDER BY object_id DESC, term_taxonomy_id DESC LIMIT %d", $last_object_enqueued['object_id'], $last_object_enqueued['term_taxonomy_id'], $last_object_enqueued['object_id'], $limit ), ARRAY_A ); - // Request term relationships in groups of N for efficiency. - if ( ! is_countable( $objects ) || count( $objects ) === 0 ) { - return array( $items_enqueued_count, true ); - } - $objects_count = count( $objects ); - $items = array_chunk( $objects, $term_relationships_full_sync_item_size ); - $last_object_enqueued = $this->bulk_enqueue_full_sync_term_relationships( $items, $last_object_enqueued ); - $items_enqueued_count += count( $items ); - $limit = min( $limit - $objects_count, self::QUERY_LIMIT ); - } - - // We need to do this extra check in case $max_items_to_enqueue * $term_relationships_full_sync_item_size == relationships objects left. - $count = $wpdb->get_var( $wpdb->prepare( "SELECT COUNT(*) FROM $wpdb->term_relationships WHERE ( object_id = %d AND term_taxonomy_id < %d ) OR ( object_id < %d ) ORDER BY object_id DESC, term_taxonomy_id DESC LIMIT %d", $last_object_enqueued['object_id'], $last_object_enqueued['term_taxonomy_id'], $last_object_enqueued['object_id'], 1 ) ); - if ( 0 === (int) $count ) { - return array( $items_enqueued_count, true ); - } - - return array( $items_enqueued_count, $last_object_enqueued ); - } - - /** - * Return the initial last sent object. - * - * @return string|array initial status. - */ - public function get_initial_last_sent() { - return array( - 'object_id' => self::MAX_INT, - 'term_taxonomy_id' => self::MAX_INT, - ); - } - - /** - * Given the Module Full Sync Configuration and Status return the next chunk of items to send. - * - * @param array $config This module Full Sync configuration. - * @param array $status This module Full Sync status. - * @param int $chunk_size Chunk size. - * - * @return array|object|null - */ - public function get_next_chunk( $config, $status, $chunk_size ) { - global $wpdb; - - return $wpdb->get_results( - $wpdb->prepare( - "SELECT tr.object_id, tr.term_taxonomy_id - FROM $wpdb->term_relationships tr INNER JOIN $wpdb->term_taxonomy tt - ON tr.term_taxonomy_id=tt.term_taxonomy_id - WHERE " . - Settings::get_whitelisted_taxonomies_sql() // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - . ' AND ( ( tr.object_id = %d AND tr.term_taxonomy_id < %d ) OR ( tr.object_id < %d ) ) - ORDER BY tr.object_id DESC, tr.term_taxonomy_id - DESC LIMIT %d', - $status['last_sent']['object_id'], - $status['last_sent']['term_taxonomy_id'], - $status['last_sent']['object_id'], - $chunk_size - ), - ARRAY_A - ); - } - - /** - * Return last_item to send for Module Full Sync Configuration. - * - * @param array $config This module Full Sync configuration. - * - * @return array|object|null - */ - public function get_last_item( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - global $wpdb; - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - return $wpdb->get_results( - "SELECT object_id, term_taxonomy_id - FROM $wpdb->term_relationships - ORDER BY object_id , term_taxonomy_id - LIMIT 1", - ARRAY_A - ); - } - - /** - * - * Enqueue all $items within `jetpack_full_sync_term_relationships` actions. - * - * @param array $items Groups of objects to sync. - * @param array $previous_interval_end Last item enqueued. - * - * @return array Last enqueued object. - */ - public function bulk_enqueue_full_sync_term_relationships( $items, $previous_interval_end ) { - $listener = Listener::get_instance(); - $items_with_previous_interval_end = $this->get_chunks_with_preceding_end( $items, $previous_interval_end ); - $listener->bulk_enqueue_full_sync_actions( 'jetpack_full_sync_term_relationships', $items_with_previous_interval_end ); - $last_item = end( $items ); - return end( $last_item ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return int Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - global $wpdb; - - $query = "SELECT COUNT(*) FROM $wpdb->term_relationships"; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / Settings::get_setting( 'term_relationships_full_sync_item_size' ) ); - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_term_relationships' ); - } - - /** - * Expand the term relationships within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The expanded hook parameters. - */ - public function expand_term_relationships( $args ) { - list( $term_relationships, $previous_end ) = $args; - - return array( - 'term_relationships' => $term_relationships, - 'previous_end' => $previous_end, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php deleted file mode 100644 index 1010daf0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php +++ /dev/null @@ -1,482 +0,0 @@ -table' ); - return 'term_taxonomy'; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - global $wpdb; - return $wpdb->term_taxonomy; - } - - /** - * Allows WordPress.com servers to retrieve term-related objects via the sync API. - * - * @param string $object_type The type of object. Accepts: 'term', 'term_taxonomy', 'term_relationships'. - * @param int $id The id of the object. - * - * @return false|object A term or term_taxonomy object, depending on object type. - */ - public function get_object_by_id( $object_type, $id ) { - $id = (int) $id; - - if ( empty( $id ) ) { - return false; - } - - $objects = $this->get_objects_by_id( $object_type, array( $id ) ); - - return $objects[ $id ] ?? false; - } - - /** - * Retrieve a set of objects by their IDs. - * - * @access public - * - * @param string $object_type Object type. Accepts: 'term', 'term_taxonomy', 'term_relationships'. - * @param array $ids Object IDs. - * - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { - global $wpdb; - - $objects = array(); - - if ( ! is_array( $ids ) || empty( $ids ) || empty( $object_type ) ) { - return $objects; - } - - // Sanitize. - $ids = array_map( 'intval', $ids ); - $ids_str = implode( ',', $ids ); - - $where_sql = Settings::get_whitelisted_taxonomies_sql(); - - switch ( $object_type ) { - case 'term': - $query = "SELECT * FROM $wpdb->terms t INNER JOIN $wpdb->term_taxonomy tt ON t.term_id=tt.term_id WHERE t.term_id IN ( $ids_str ) AND "; - $callback = 'expand_raw_terms'; - break; - case 'term_taxonomy': - $query = "SELECT * FROM $wpdb->term_taxonomy WHERE term_taxonomy_id IN ( $ids_str ) AND "; - $callback = 'expand_raw_term_taxonomies'; - break; - case 'term_relationships': - $query = "SELECT * FROM $wpdb->term_relationships tr INNER JOIN $wpdb->term_taxonomy tt ON tr.term_taxonomy_id=tt.term_taxonomy_id WHERE object_id IN ( $ids_str ) AND "; - $callback = 'expand_raw_term_relationships'; - break; - default: - return array(); - } - - $query .= $where_sql; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching -- Already sanitized above. - $results = $wpdb->get_results( $query ); - - if ( ! is_array( $results ) ) { - return array(); - } - - $objects = $this->$callback( $results ); - - return $objects ?? array(); - } - - /** - * Initialize terms action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - add_action( 'created_term', array( $this, 'save_term_handler' ), 10, 3 ); - add_action( 'edited_term', array( $this, 'save_term_handler' ), 10, 3 ); - add_action( 'jetpack_sync_save_term', $callable ); - add_action( 'jetpack_sync_add_term', $callable ); - add_action( 'delete_term', $callable, 10, 4 ); - add_action( 'set_object_terms', $callable, 10, 6 ); - add_action( 'deleted_term_relationships', $callable, 10, 2 ); - add_filter( 'jetpack_sync_before_enqueue_set_object_terms', array( $this, 'filter_set_object_terms_no_update' ) ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_save_term', array( $this, 'filter_blacklisted_taxonomies' ) ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_add_term', array( $this, 'filter_blacklisted_taxonomies' ) ); - } - - /** - * Initialize terms action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_terms', $callable, 10, 2 ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - // Full sync. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_terms', array( $this, 'expand_term_taxonomy_id' ) ); - } - - /** - * Enqueue the terms actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - global $wpdb; - return $this->enqueue_all_ids_as_action( 'jetpack_full_sync_terms', $wpdb->term_taxonomy, 'term_taxonomy_id', $this->get_where_sql( $config ), $max_items_to_enqueue, $state ); - } - - /** - * Retrieve the WHERE SQL clause based on the module config. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return string WHERE SQL clause, or `null` if no comments are specified in the module config. - */ - public function get_where_sql( $config ) { - $where_sql = Settings::get_blacklisted_taxonomies_sql(); - - if ( is_array( $config ) ) { - $where_sql .= ' AND term_taxonomy_id IN (' . implode( ',', array_map( 'intval', $config ) ) . ')'; - } - - return $where_sql; - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return int Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { - global $wpdb; - - $query = "SELECT count(*) FROM $wpdb->term_taxonomy"; - - $where_sql = $this->get_where_sql( $config ); - if ( $where_sql ) { - $query .= ' WHERE ' . $where_sql; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / self::ARRAY_CHUNK_SIZE ); - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_terms' ); - } - - /** - * Handler for creating and updating terms. - * - * @access public - * - * @param int $term_id Term ID. - * @param int $tt_id Term taxonomy ID. - * @param string $taxonomy Taxonomy slug. - */ - public function save_term_handler( $term_id, $tt_id, $taxonomy ) { - if ( class_exists( '\\WP_Term' ) ) { - $term_object = \WP_Term::get_instance( $term_id, $taxonomy ); - } else { - $term_object = get_term_by( 'id', $term_id, $taxonomy ); - } - - $current_filter = current_filter(); - - if ( 'created_term' === $current_filter ) { - /** - * Fires when the client needs to add a new term - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param object the Term object - */ - do_action( 'jetpack_sync_add_term', $term_object ); - return; - } - - /** - * Fires when the client needs to update a term - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param object the Term object - */ - do_action( 'jetpack_sync_save_term', $term_object ); - } - - /** - * Filter blacklisted taxonomies. - * - * @access public - * - * @param array $args Hook args. - * @return array|boolean False if not whitelisted, the original hook args otherwise. - */ - public function filter_blacklisted_taxonomies( $args ) { - $term = $args[0]; - - if ( in_array( $term->taxonomy, Settings::get_setting( 'taxonomies_blacklist' ), true ) ) { - return false; - } - - return $args; - } - - /** - * Filter out set_object_terms actions with blacklisted taxonomies or where the terms have not changed. - * - * @param array $args Hook args. - * @return array|boolean False if blacklisted taxonomy or no change in terms, the original hook args otherwise. - */ - public function filter_set_object_terms_no_update( $args ) { - // Check if the taxonomy is blacklisted. $args[3] is the taxonomy. - if ( isset( $args[3] ) && in_array( $args[3], Settings::get_setting( 'taxonomies_blacklist' ), true ) ) { - return false; - } - // There is potential for other plugins to modify args, therefore lets validate # of and types. - // $args[2] is $tt_ids, $args[5] is $old_tt_ids see wp-includes/taxonomy.php L2740. - if ( 6 === count( $args ) && is_array( $args[2] ) && is_array( $args[5] ) ) { - if ( empty( array_diff( $args[2], $args[5] ) ) && empty( array_diff( $args[5], $args[2] ) ) ) { - return false; - } - } - return $args; - } - - /** - * Expand the term taxonomy IDs to terms within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The expanded hook parameters. - */ - public function expand_term_taxonomy_id( $args ) { - list( $term_taxonomy_ids, $previous_end ) = $args; - - return array( - 'terms' => get_terms( - array( - 'hide_empty' => false, - 'term_taxonomy_id' => $term_taxonomy_ids, - 'orderby' => 'term_taxonomy_id', - 'order' => 'DESC', - ) - ), - 'previous_end' => $previous_end, - ); - } - - /** - * Gets a term object based on a given row from the term_relationships database table. - * - * @access public - * - * @deprecated since 4.8.1 - * - * @param object $relationship A row object from the term_relationships table. - * @return object|bool A term object, or false if term taxonomy doesn't exist. - */ - public function expand_terms_for_relationship( $relationship ) { - _deprecated_function( __METHOD__, '4.8.1' ); - - return get_term_by( 'term_taxonomy_id', $relationship->term_taxonomy_id ); - } - - /** - * Prepare raw terms and return them in a standard format. - * - * @param array $terms An array of raw term objects. - * @return array An array of term objects. - */ - private function expand_raw_terms( array $terms ) { - $objects = array(); - $columns = array( - 'term_id' => 'int', - 'name' => 'string', - 'slug' => 'string', - 'taxonomy' => 'string', - 'description' => 'string', - 'term_group' => 'int', - 'term_taxonomy_id' => 'int', - 'parent' => 'int', - 'count' => 'int', - ); - - foreach ( $terms as $term ) { - if ( ! array_key_exists( $term->term_id, $objects ) ) { - $t_array = array(); - - foreach ( $columns as $field => $type ) { - $value = $term->$field ?? ''; - $t_array[ $field ] = 'int' === $type ? (int) $value : $value; - } - // This will allow us to know on WPCOM that the term name is the raw one, coming from the DB. Useful with backwards compatibility in mind. - $t_array['raw_name'] = $t_array['name']; - - $objects[ $term->term_id ] = (object) $t_array; - } - } - - return $objects; - } - - /** - * Prepare raw term taxonomies and return them in a standard format. - * - * @param array $term_taxonomies An array of raw term_taxonomy objects. - * @return array An array of term_taxonomy objects. - */ - private function expand_raw_term_taxonomies( array $term_taxonomies ) { - $objects = array(); - $columns = array( - 'term_id' => 'int', - 'taxonomy' => 'string', - 'description' => 'string', - 'term_taxonomy_id' => 'int', - 'parent' => 'int', - 'count' => 'int', - ); - - foreach ( $term_taxonomies as $tt ) { - if ( ! array_key_exists( $tt->term_taxonomy_id, $objects ) ) { - $t_array = array(); - - foreach ( $columns as $field => $type ) { - $value = $tt->$field ?? ''; - $t_array[ $field ] = 'int' === $type ? (int) $value : $value; - } - - $objects[ $tt->term_taxonomy_id ] = (object) $t_array; - } - } - - return $objects; - } - - /** - * Prepare raw term taxonomies and return them in a standard format. - * - * @param array $term_relationships An array of raw term_taxonomy objects. - * @return array An array of term_taxonomy objects or false. - */ - private function expand_raw_term_relationships( array $term_relationships ) { - $objects = array(); - $columns = array( - 'object_id' => 'int', - 'term_id' => 'int', - 'taxonomy' => 'string', - 'term_taxonomy_id' => 'int', - 'term_order' => 'int', - 'parent' => 'int', - 'count' => 'int', - ); - - foreach ( $term_relationships as $tt ) { - $object_id = (int) $tt->object_id; - - $relationship = array(); - foreach ( $columns as $field => $type ) { - $value = $tt->$field ?? ''; - $relationship[ $field ] = 'int' === $type ? (int) $value : $value; - } - - $relationship = (object) $relationship; - - if ( ! array_key_exists( $object_id, $objects ) ) { - $objects[ $object_id ] = (object) array( - 'object_id' => $object_id, - 'relationships' => array( $relationship ), - ); - } else { - $objects[ $object_id ]->relationships[] = $relationship; - } - } - - return $objects; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php deleted file mode 100644 index 01b5ebf9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php +++ /dev/null @@ -1,874 +0,0 @@ - $widget_object->name, - 'id' => $widget_object->id, - 'title' => isset( $new_instance['title'] ) ? $new_instance['title'] : '', - ); - /** - * Trigger action to alert $callable sync listener that a widget was edited. - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param string $widget_name , Name of edited widget - */ - do_action( 'jetpack_widget_edited', $widget ); - - return $instance; - } - - /** - * Sync handler for network allowed themes change. - * - * @access public - * - * @param string $option Name of the network option. - * @param mixed $value Current value of the network option. - * @param mixed $old_value Old value of the network option. - * @param int $network_id ID of the network. - */ - public function sync_network_allowed_themes_change( $option, $value, $old_value, $network_id ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $all_enabled_theme_slugs = array_keys( $value ); - $old_value_count = is_countable( $old_value ) ? count( $old_value ) : 0; - $value_count = is_countable( $value ) ? count( $value ) : 0; - - if ( $old_value_count > $value_count ) { - // Suppress jetpack_network_disabled_themes sync action when theme is deleted. - $delete_theme_call = $this->get_delete_theme_call(); - if ( ! empty( $delete_theme_call ) ) { - return; - } - - $newly_disabled_theme_names = array_keys( array_diff_key( $old_value, $value ) ); - $newly_disabled_themes = $this->get_theme_details_for_slugs( $newly_disabled_theme_names ); - /** - * Trigger action to alert $callable sync listener that network themes were disabled. - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param mixed $newly_disabled_themes, Array of info about network disabled themes - * @param mixed $all_enabled_theme_slugs, Array of slugs of all enabled themes - */ - do_action( 'jetpack_network_disabled_themes', $newly_disabled_themes, $all_enabled_theme_slugs ); - return; - } - - $newly_enabled_theme_names = array_keys( array_diff_key( $value, $old_value ) ); - $newly_enabled_themes = $this->get_theme_details_for_slugs( $newly_enabled_theme_names ); - /** - * Trigger action to alert $callable sync listener that network themes were enabled - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param mixed $newly_enabled_themes , Array of info about network enabled themes - * @param mixed $all_enabled_theme_slugs, Array of slugs of all enabled themes - */ - do_action( 'jetpack_network_enabled_themes', $newly_enabled_themes, $all_enabled_theme_slugs ); - } - - /** - * Retrieve details for one or more themes by their slugs. - * - * @access private - * - * @param array $theme_slugs Theme slugs. - * @return array Details for the themes. - */ - private function get_theme_details_for_slugs( $theme_slugs ) { - $theme_data = array(); - foreach ( $theme_slugs as $slug ) { - $theme = wp_get_theme( $slug ); - $theme_data[ $slug ] = array( - 'name' => $theme->get( 'Name' ), - 'version' => $theme->get( 'Version' ), - 'uri' => $theme->get( 'ThemeURI' ), - 'slug' => $slug, - ); - } - return $theme_data; - } - - /** - * Detect a theme edit during a redirect. - * - * @access public - * - * @param string $redirect_url Redirect URL. - * @return string Redirect URL. - */ - public function detect_theme_edit( $redirect_url ) { - $url = wp_parse_url( admin_url( $redirect_url ) ); - $theme_editor_url = wp_parse_url( admin_url( 'theme-editor.php' ) ); - - if ( $theme_editor_url['path'] !== $url['path'] ) { - return $redirect_url; - } - - $query_params = array(); - wp_parse_str( $url['query'], $query_params ); - if ( - ! isset( $_POST['newcontent'] ) || // phpcs:ignore WordPress.Security.NonceVerification.Missing -- 'wp_redirect' gets fired for a lot of things. We're only using $_POST['newcontent'] to limit action to redirects from theme edits, we're not doing anything with or in response to the post itself. - ! isset( $query_params['file'] ) || - ! isset( $query_params['theme'] ) || - ! isset( $query_params['updated'] ) - ) { - return $redirect_url; - } - $theme = wp_get_theme( $query_params['theme'] ); - $theme_data = array( - 'name' => $theme->get( 'Name' ), - 'version' => $theme->get( 'Version' ), - 'uri' => $theme->get( 'ThemeURI' ), - ); - - /** - * Trigger action to alert $callable sync listener that a theme was edited. - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param string $query_params['theme'], Slug of edited theme - * @param string $theme_data, Information about edited them - */ - do_action( 'jetpack_edited_theme', $query_params['theme'], $theme_data ); - - return $redirect_url; - } - - /** - * Handler for AJAX theme editing. - * - * @todo Refactor to use WP_Filesystem instead of fopen()/fclose(). - */ - public function theme_edit_ajax() { - // This validation is based on wp_edit_theme_plugin_file(). - if ( empty( $_POST['theme'] ) ) { - return; - } - - if ( empty( $_POST['file'] ) ) { - return; - } - $file = wp_unslash( $_POST['file'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated manually just after. - if ( 0 !== validate_file( $file ) ) { - return; - } - - if ( ! isset( $_POST['newcontent'] ) ) { - return; - } - - if ( ! isset( $_POST['nonce'] ) ) { - return; - } - - $stylesheet = wp_unslash( $_POST['theme'] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated manually just after. - if ( 0 !== validate_file( $stylesheet ) ) { - return; - } - - if ( ! current_user_can( 'edit_themes' ) ) { - return; - } - - $theme = wp_get_theme( $stylesheet ); - if ( ! $theme->exists() ) { - return; - } - - if ( ! wp_verify_nonce( $_POST['nonce'], 'edit-theme_' . $stylesheet . '_' . $file ) ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- WP core doesn't pre-sanitize nonces either. - return; - } - - if ( $theme->errors() && 'theme_no_stylesheet' === $theme->errors()->get_error_code() ) { - return; - } - - $editable_extensions = wp_get_theme_file_editable_extensions( $theme ); - - $allowed_files = array(); - foreach ( $editable_extensions as $type ) { - switch ( $type ) { - case 'php': - $allowed_files = array_merge( $allowed_files, $theme->get_files( 'php', -1 ) ); - break; - case 'css': - $style_files = $theme->get_files( 'css', -1 ); - $allowed_files['style.css'] = $style_files['style.css']; - $allowed_files = array_merge( $allowed_files, $style_files ); - break; - default: - $allowed_files = array_merge( $allowed_files, $theme->get_files( $type, -1 ) ); - break; - } - } - - $real_file = $theme->get_stylesheet_directory() . '/' . $file; - if ( 0 !== validate_file( $real_file, $allowed_files ) ) { - return; - } - - // Ensure file is real. - if ( ! is_file( $real_file ) ) { - return; - } - - // Ensure file extension is allowed. - $extension = null; - if ( preg_match( '/\.([^.]+)$/', $real_file, $matches ) ) { - $extension = strtolower( $matches[1] ); - if ( ! in_array( $extension, $editable_extensions, true ) ) { - return; - } - } - - // phpcs:ignore WordPress.WP.AlternativeFunctions.file_system_operations_is_writable - if ( ! is_writable( $real_file ) ) { - return; - } - - // phpcs:ignore WordPress.WP.AlternativeFunctions.file_system_operations_fopen - $file_pointer = fopen( $real_file, 'w+' ); - if ( false === $file_pointer ) { - return; - } - // phpcs:ignore WordPress.WP.AlternativeFunctions.file_system_operations_fclose - fclose( $file_pointer ); - - $theme_data = array( - 'name' => $theme->get( 'Name' ), - 'version' => $theme->get( 'Version' ), - 'uri' => $theme->get( 'ThemeURI' ), - ); - - /** - * This action is documented already in this file. - */ - do_action( 'jetpack_edited_theme', $stylesheet, $theme_data ); - } - - /** - * Detect a theme deletion. - * - * @access public - * - * @param string $stylesheet Stylesheet of the theme to delete. - * @param bool $deleted Whether the theme deletion was successful. - */ - public function detect_theme_deletion( $stylesheet, $deleted ) { - $theme = wp_get_theme( $stylesheet ); - $theme_data = array( - 'name' => $theme->get( 'Name' ), - 'version' => $theme->get( 'Version' ), - 'uri' => $theme->get( 'ThemeURI' ), - 'slug' => $stylesheet, - ); - - if ( $deleted ) { - /** - * Signals to the sync listener that a theme was deleted and a sync action - * reflecting the deletion and theme slug should be sent - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param string $stylesheet Theme slug - * @param array $theme_data Theme info Since 5.3 - */ - do_action( 'jetpack_deleted_theme', $stylesheet, $theme_data ); - } - } - - /** - * Handle an upgrader completion action. - * - * @access public - * - * @param \WP_Upgrader $upgrader The upgrader instance. - * @param array $details Array of bulk item update data. - */ - public function check_upgrader( $upgrader, $details ) { - if ( ! isset( $details['type'] ) || - 'theme' !== $details['type'] || - is_wp_error( $upgrader->skin->result ) || - ! method_exists( $upgrader, 'theme_info' ) - ) { - return; - } - - if ( 'install' === $details['action'] ) { - // @phan-suppress-next-line PhanUndeclaredMethod -- Checked above. See also https://github.com/phan/phan/issues/1204. - $theme = $upgrader->theme_info(); - if ( ! $theme instanceof \WP_Theme ) { - return; - } - $theme_info = array( - 'name' => $theme->get( 'Name' ), - 'version' => $theme->get( 'Version' ), - 'uri' => $theme->get( 'ThemeURI' ), - ); - - /** - * Signals to the sync listener that a theme was installed and a sync action - * reflecting the installation and the theme info should be sent - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param string $theme->theme_root Text domain of the theme - * @param mixed $theme_info Array of abbreviated theme info - */ - do_action( 'jetpack_installed_theme', $theme->stylesheet, $theme_info ); - } - - if ( 'update' === $details['action'] ) { - $themes = array(); - - if ( empty( $details['themes'] ) && isset( $details['theme'] ) ) { - $details['themes'] = array( $details['theme'] ); - } - - foreach ( $details['themes'] as $theme_slug ) { - $theme = wp_get_theme( $theme_slug ); - - if ( ! $theme instanceof \WP_Theme ) { - continue; - } - - $themes[ $theme_slug ] = array( - 'name' => $theme->get( 'Name' ), - 'version' => $theme->get( 'Version' ), - 'uri' => $theme->get( 'ThemeURI' ), - 'stylesheet' => $theme->stylesheet, - ); - } - - if ( empty( $themes ) ) { - return; - } - - /** - * Signals to the sync listener that one or more themes was updated and a sync action - * reflecting the update and the theme info should be sent - * - * @since 1.6.3 - * @since-jetpack 6.2.0 - * - * @param mixed $themes Array of abbreviated theme info - */ - do_action( 'jetpack_updated_themes', $themes ); - } - } - - /** - * Initialize themes action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_theme_data', $callable ); - } - - /** - * Handle a theme switch. - * - * @access public - * - * @param string $new_name Name of the new theme. - * @param \WP_Theme $new_theme The new theme. - * @param \WP_Theme $old_theme The previous theme. - */ - public function sync_theme_support( $new_name, $new_theme = null, $old_theme = null ) { - $previous_theme = $this->get_theme_info( $old_theme ); - - /** - * Fires when the client needs to sync theme support info - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param array the theme support array - * @param array the previous theme since Jetpack 6.5.0 - */ - do_action( 'jetpack_sync_current_theme_support', $this->get_theme_info(), $previous_theme ); - } - - /** - * Enqueue the themes actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - /** - * Tells the client to sync all theme data to the server - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean Whether to expand theme data (should always be true) - */ - do_action( 'jetpack_full_sync_theme_data', true ); - - // The number of actions enqueued, and next module state (true == done). - return array( 1, true ); - } - - /** - * Send the themes actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $send_until The timestamp until the current request can send. - * @param array $state This module Full Sync status. - * - * @return array This module Full Sync status. - */ - public function send_full_sync_actions( $config, $send_until, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // we call this instead of do_action when sending immediately. - $this->send_action( 'jetpack_full_sync_theme_data', array( true ) ); - - // The number of actions enqueued, and next module state (true == done). - return array( 'finished' => true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_theme_data', array( $this, 'expand_theme_data' ) ); - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_theme_data' ); - } - - /** - * Expand the theme within a hook before it is serialized and sent to the server. - * - * @access public - * - * @return array Theme data. - */ - public function expand_theme_data() { - return array( $this->get_theme_info() ); - } - - /** - * Retrieve the name of the widget by the widget ID. - * - * @access public - * @global $wp_registered_widgets - * - * @param string $widget_id Widget ID. - * @return string Name of the widget, or null if not found. - */ - public function get_widget_name( $widget_id ) { - global $wp_registered_widgets; - return ( isset( $wp_registered_widgets[ $widget_id ] ) ? $wp_registered_widgets[ $widget_id ]['name'] : null ); - } - - /** - * Retrieve the name of the sidebar by the sidebar ID. - * - * @access public - * @global $wp_registered_sidebars - * - * @param string $sidebar_id Sidebar ID. - * @return string Name of the sidebar, or null if not found. - */ - public function get_sidebar_name( $sidebar_id ) { - global $wp_registered_sidebars; - return ( isset( $wp_registered_sidebars[ $sidebar_id ] ) ? $wp_registered_sidebars[ $sidebar_id ]['name'] : null ); - } - - /** - * Sync addition of widgets to a sidebar. - * - * @access public - * - * @param array $new_widgets New widgets. - * @param array $old_widgets Old widgets. - * @param string $sidebar Sidebar ID. - * @return array All widgets that have been moved to the sidebar. - */ - public function sync_add_widgets_to_sidebar( $new_widgets, $old_widgets, $sidebar ) { - $added_widgets = array_diff( $new_widgets, $old_widgets ); - if ( empty( $added_widgets ) ) { - return array(); - } - $moved_to_sidebar = array(); - $sidebar_name = $this->get_sidebar_name( $sidebar ); - - // Don't sync jetpack_widget_added if theme was switched. - if ( $this->is_theme_switch() ) { - return array(); - } - - foreach ( $added_widgets as $added_widget ) { - $moved_to_sidebar[] = $added_widget; - $added_widget_name = $this->get_widget_name( $added_widget ); - /** - * Helps Sync log that a widget got added - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param string $sidebar, Sidebar id got changed - * @param string $added_widget, Widget id got added - * @param string $sidebar_name, Sidebar id got changed Since 5.0.0 - * @param string $added_widget_name, Widget id got added Since 5.0.0 - */ - do_action( 'jetpack_widget_added', $sidebar, $added_widget, $sidebar_name, $added_widget_name ); - } - return $moved_to_sidebar; - } - - /** - * Sync removal of widgets from a sidebar. - * - * @access public - * - * @param array $new_widgets New widgets. - * @param array $old_widgets Old widgets. - * @param string $sidebar Sidebar ID. - * @param array $inactive_widgets Current inactive widgets. - * @return array All widgets that have been moved to inactive. - */ - public function sync_remove_widgets_from_sidebar( $new_widgets, $old_widgets, $sidebar, $inactive_widgets ) { - $removed_widgets = array_diff( $old_widgets, $new_widgets ); - - if ( empty( $removed_widgets ) ) { - return array(); - } - - $moved_to_inactive = array(); - $sidebar_name = $this->get_sidebar_name( $sidebar ); - - foreach ( $removed_widgets as $removed_widget ) { - // Lets check if we didn't move the widget to in_active_widgets. - if ( isset( $inactive_widgets ) && ! in_array( $removed_widget, $inactive_widgets, true ) ) { - $removed_widget_name = $this->get_widget_name( $removed_widget ); - /** - * Helps Sync log that a widgte got removed - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param string $sidebar, Sidebar id got changed - * @param string $removed_widget, Widget id got removed - * @param string $sidebar_name, Name of the sidebar that changed Since 5.0.0 - * @param string $removed_widget_name, Name of the widget that got removed Since 5.0.0 - */ - do_action( 'jetpack_widget_removed', $sidebar, $removed_widget, $sidebar_name, $removed_widget_name ); - } else { - $moved_to_inactive[] = $removed_widget; - } - } - return $moved_to_inactive; - } - - /** - * Sync a reorder of widgets within a sidebar. - * - * @access public - * - * @todo Refactor serialize() to a json_encode(). - * - * @param array $new_widgets New widgets. - * @param array $old_widgets Old widgets. - * @param string $sidebar Sidebar ID. - */ - public function sync_widgets_reordered( $new_widgets, $old_widgets, $sidebar ) { - $added_widgets = array_diff( $new_widgets, $old_widgets ); - if ( ! empty( $added_widgets ) ) { - return; - } - $removed_widgets = array_diff( $old_widgets, $new_widgets ); - if ( ! empty( $removed_widgets ) ) { - return; - } - - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - if ( serialize( $old_widgets ) !== serialize( $new_widgets ) ) { - $sidebar_name = $this->get_sidebar_name( $sidebar ); - /** - * Helps Sync log that a sidebar id got reordered - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param string $sidebar, Sidebar id got changed - * @param string $sidebar_name, Name of the sidebar that changed Since 5.0.0 - */ - do_action( 'jetpack_widget_reordered', $sidebar, $sidebar_name ); - } - } - - /** - * Handle the update of the sidebars and widgets mapping option. - * - * @access public - * - * @param mixed $old_value The old option value. - * @param mixed $new_value The new option value. - */ - public function sync_sidebar_widgets_actions( $old_value, $new_value ) { - // Don't really know how to deal with different array_values yet. - if ( - ( isset( $old_value['array_version'] ) && 3 !== $old_value['array_version'] ) || - ( isset( $new_value['array_version'] ) && 3 !== $new_value['array_version'] ) - ) { - return; - } - - $moved_to_inactive_ids = array(); - $moved_to_sidebar = array(); - - foreach ( $new_value as $sidebar => $new_widgets ) { - if ( in_array( $sidebar, array( 'array_version', 'wp_inactive_widgets' ), true ) ) { - continue; - } - $old_widgets = isset( $old_value[ $sidebar ] ) - ? $old_value[ $sidebar ] - : array(); - - if ( ! is_array( $new_widgets ) ) { - $new_widgets = array(); - } - - $moved_to_inactive_recently = $this->sync_remove_widgets_from_sidebar( $new_widgets, $old_widgets, $sidebar, $new_value['wp_inactive_widgets'] ); - $moved_to_inactive_ids = array_merge( $moved_to_inactive_ids, $moved_to_inactive_recently ); - - $moved_to_sidebar_recently = $this->sync_add_widgets_to_sidebar( $new_widgets, $old_widgets, $sidebar ); - $moved_to_sidebar = array_merge( $moved_to_sidebar, $moved_to_sidebar_recently ); - - $this->sync_widgets_reordered( $new_widgets, $old_widgets, $sidebar ); - - } - - // Don't sync either jetpack_widget_moved_to_inactive or jetpack_cleared_inactive_widgets if theme was switched. - if ( $this->is_theme_switch() ) { - return; - } - - // Treat inactive sidebar a bit differently. - if ( ! empty( $moved_to_inactive_ids ) ) { - $moved_to_inactive_name = array_map( array( $this, 'get_widget_name' ), $moved_to_inactive_ids ); - /** - * Helps Sync log that a widgets IDs got moved to in active - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param array $moved_to_inactive_ids, Array of widgets id that moved to inactive id got changed - * @param array $moved_to_inactive_names, Array of widgets names that moved to inactive id got changed Since 5.0.0 - */ - do_action( 'jetpack_widget_moved_to_inactive', $moved_to_inactive_ids, $moved_to_inactive_name ); - } elseif ( empty( $moved_to_sidebar ) && empty( $new_value['wp_inactive_widgets'] ) && ! empty( $old_value['wp_inactive_widgets'] ) ) { - /** - * Helps Sync log that a got cleared from inactive. - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - */ - do_action( 'jetpack_cleared_inactive_widgets' ); - } - } - - /** - * Retrieve the theme data for the current or a specific theme. - * - * @access private - * - * @param \WP_Theme $theme Theme object. Optional, will default to the current theme. - * - * @return array Theme data. - */ - private function get_theme_info( $theme = null ) { - $theme_support = array(); - - // We are trying to get the current theme info. - if ( null === $theme ) { - $theme = wp_get_theme(); - } - - $theme_support['name'] = $theme->get( 'Name' ); - $theme_support['version'] = $theme->get( 'Version' ); - $theme_support['slug'] = $theme->get_stylesheet(); - $theme_support['uri'] = $theme->get( 'ThemeURI' ); - - return $theme_support; - } - - /** - * Whether we've deleted a theme in the current request. - * - * @access private - * - * @return boolean True if this is a theme deletion request, false otherwise. - */ - private function get_delete_theme_call() { - // Intentional usage of `debug_backtrace()` for production needs. - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace - $backtrace = debug_backtrace(); - $delete_theme_call = null; - foreach ( $backtrace as $call ) { - if ( isset( $call['function'] ) && 'delete_theme' === $call['function'] ) { - $delete_theme_call = $call; - break; - } - } - return $delete_theme_call; - } - - /** - * Whether we've switched to another theme in the current request. - * - * @access private - * - * @return boolean True if this is a theme switch request, false otherwise. - */ - private function is_theme_switch() { - return did_action( 'after_switch_theme' ); - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Retrieve a set of constants by their IDs. - * - * @access public - * - * @param string $object_type Object type. - * @param array $ids Object IDs. - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - if ( 'theme-info' !== $object_type ) { - return array(); - } - - return array( $this->get_theme_info() ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php deleted file mode 100644 index 0c31f93a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php +++ /dev/null @@ -1,587 +0,0 @@ -updates = array(); - } - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'updates'; - } - - /** - * Initialize updates action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - global $wp_version; - $this->old_wp_version = $wp_version; - add_action( 'set_site_transient_update_plugins', array( $this, 'validate_update_change' ), 10, 3 ); - add_action( 'set_site_transient_update_themes', array( $this, 'validate_update_change' ), 10, 3 ); - add_action( 'set_site_transient_update_core', array( $this, 'validate_update_change' ), 10, 3 ); - - add_action( 'jetpack_update_plugins_change', $callable ); - add_action( 'jetpack_update_themes_change', $callable ); - add_action( 'jetpack_update_core_change', $callable ); - - add_filter( - 'jetpack_sync_before_enqueue_jetpack_update_themes_change', - array( - $this, - 'expand_themes', - ) - ); - - add_filter( - 'jetpack_sync_before_enqueue_jetpack_update_plugins_change', - array( - $this, - 'filter_update_keys', - ), - 10, - 2 - ); - add_filter( - 'jetpack_sync_before_enqueue_upgrader_process_complete', - array( - $this, - 'filter_upgrader_process_complete', - ), - 10, - 2 - ); - - if ( is_multisite() ) { - add_filter( 'pre_update_site_option_wpmu_upgrade_site', array( $this, 'update_core_network_event' ), 10, 2 ); - add_action( 'jetpack_sync_core_update_network', $callable, 10, 3 ); - } - - // Send data when update completes. - add_action( '_core_updated_successfully', array( $this, 'update_core' ) ); - add_action( 'jetpack_sync_core_reinstalled_successfully', $callable ); - add_action( 'jetpack_sync_core_autoupdated_successfully', $callable, 10, 2 ); - add_action( 'jetpack_sync_core_updated_successfully', $callable, 10, 2 ); - } - - /** - * Initialize updates action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_updates', $callable ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_updates', array( $this, 'expand_updates' ) ); - } - - /** - * Handle a core network update. - * - * @access public - * - * @param int $wp_db_version Current version of the WordPress database. - * @param int $old_wp_db_version Old version of the WordPress database. - * @return int Current version of the WordPress database. - */ - public function update_core_network_event( $wp_db_version, $old_wp_db_version ) { - global $wp_version; - /** - * Sync event for when core wp network updates to a new db version - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param int $wp_db_version the latest wp_db_version - * @param int $old_wp_db_version previous wp_db_version - * @param string $wp_version the latest wp_version - */ - do_action( 'jetpack_sync_core_update_network', $wp_db_version, $old_wp_db_version, $wp_version ); - return $wp_db_version; - } - - /** - * Handle a core update. - * - * @access public - * - * @todo Implement nonce or refactor to use `admin_post_{$action}` hooks instead. - * - * @param string $new_wp_version The new WP core version. - */ - public function update_core( $new_wp_version ) { - global $pagenow; - - // // phpcs:ignore WordPress.Security.NonceVerification.Recommended - if ( isset( $_GET['action'] ) && 'do-core-reinstall' === $_GET['action'] ) { - /** - * Sync event that fires when core reinstall was successful - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param string $new_wp_version the updated WordPress version - */ - do_action( 'jetpack_sync_core_reinstalled_successfully', $new_wp_version ); - return; - } - - // Core was autoupdated. - if ( - 'update-core.php' !== $pagenow && - ! Jetpack_Constants::is_true( 'REST_API_REQUEST' ) // WP.com rest api calls should never be marked as a core autoupdate. - ) { - /** - * Sync event that fires when core autoupdate was successful - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param string $new_wp_version the updated WordPress version - * @param string $old_wp_version the previous WordPress version - */ - do_action( 'jetpack_sync_core_autoupdated_successfully', $new_wp_version, $this->old_wp_version ); - return; - } - /** - * Sync event that fires when core update was successful - * - * @since 1.6.3 - * @since-jetpack 5.0.0 - * - * @param string $new_wp_version the updated WordPress version - * @param string $old_wp_version the previous WordPress version - */ - do_action( 'jetpack_sync_core_updated_successfully', $new_wp_version, $this->old_wp_version ); - } - - /** - * Retrieve the checksum for an update. - * - * @access public - * - * @param object $update The update object. - * @param string $transient The transient we're retrieving a checksum for. - * @return int The checksum. - */ - public function get_update_checksum( $update, $transient ) { - $updates = array(); - $no_updated = array(); - switch ( $transient ) { - case 'update_plugins': - if ( ! empty( $update->response ) && is_array( $update->response ) ) { - foreach ( $update->response as $plugin_slug => $response ) { - if ( ! empty( $plugin_slug ) && isset( $response->new_version ) ) { - $updates[] = array( $plugin_slug => $response->new_version ); - } - } - } - if ( ! empty( $update->no_update ) ) { - $no_updated = array_keys( $update->no_update ); - } - - if ( ! isset( $no_updated['jetpack/jetpack.php'] ) && isset( $updates['jetpack/jetpack.php'] ) ) { - return false; - } - - break; - case 'update_themes': - if ( ! empty( $update->response ) && is_array( $update->response ) ) { - foreach ( $update->response as $theme_slug => $response ) { - if ( ! empty( $theme_slug ) && isset( $response['new_version'] ) ) { - $updates[] = array( $theme_slug => $response['new_version'] ); - } - } - } - - if ( ! empty( $update->checked ) ) { - $no_updated = $update->checked; - } - - break; - case 'update_core': - if ( ! empty( $update->updates ) && is_array( $update->updates ) ) { - foreach ( $update->updates as $response ) { - if ( ! empty( $response->response ) && 'latest' === $response->response ) { - continue; - } - if ( ! empty( $response->response ) && isset( $response->packages->full ) ) { - $updates[] = array( $response->response => $response->packages->full ); - } - } - } - - if ( ! empty( $update->version_checked ) ) { - $no_updated = $update->version_checked; - } - - if ( empty( $updates ) ) { - return false; - } - break; - - } - if ( empty( $updates ) && empty( $no_updated ) ) { - return false; - } - return $this->get_check_sum( array( $no_updated, $updates ) ); - } - - /** - * Validate a change coming from an update before sending for sync. - * - * @access public - * - * @param mixed $value Site transient value. - * @param int $expiration Time until transient expiration in seconds. - * @param string $transient Transient name. - */ - public function validate_update_change( $value, $expiration, $transient ) { - $new_checksum = $this->get_update_checksum( $value, $transient ); - - if ( false === $new_checksum ) { - return; - } - - $checksums = get_option( self::UPDATES_CHECKSUM_OPTION_NAME, array() ); - - if ( isset( $checksums[ $transient ] ) && $checksums[ $transient ] === $new_checksum ) { - return; - } - - $checksums[ $transient ] = $new_checksum; - - update_option( self::UPDATES_CHECKSUM_OPTION_NAME, $checksums ); - if ( 'update_core' === $transient ) { - /** - * Trigger a change to core update that we want to sync. - * - * @since 1.6.3 - * @since-jetpack 5.1.0 - * - * @param array $value Contains info that tells us what needs updating. - */ - do_action( 'jetpack_update_core_change', $value ); - return; - } - if ( empty( $this->updates ) ) { - // Lets add the shutdown method once and only when the updates move from empty to filled with something. - add_action( 'shutdown', array( $this, 'sync_last_event' ), 9 ); - } - if ( ! isset( $this->updates[ $transient ] ) ) { - $this->updates[ $transient ] = array(); - } - $this->updates[ $transient ][] = $value; - } - - /** - * Sync the last update only. - * - * @access public - */ - public function sync_last_event() { - foreach ( $this->updates as $transient => $values ) { - $value = end( $values ); // Only send over the last value. - /** - * Trigger a change to a specific update that we want to sync. - * Triggers one of the following actions: - * - jetpack_{$transient}_change - * - jetpack_update_plugins_change - * - jetpack_update_themes_change - * - * @since 1.6.3 - * @since-jetpack 5.1.0 - * - * @param array $value Contains info that tells us what needs updating. - */ - do_action( "jetpack_{$transient}_change", $value ); - } - } - - /** - * Enqueue the updates actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - /** - * Tells the client to sync all updates to the server - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param boolean Whether to expand updates (should always be true) - */ - do_action( 'jetpack_full_sync_updates', true ); - - // The number of actions enqueued, and next module state (true == done). - return array( 1, true ); - } - - /** - * Send the updates actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $send_until The timestamp until the current request can send. - * @param array $state This module Full Sync status. - * - * @return array This module Full Sync status. - */ - public function send_full_sync_actions( $config, $send_until, $state ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // we call this instead of do_action when sending immediately. - $this->send_action( 'jetpack_full_sync_updates', array( true ) ); - - // The number of actions enqueued, and next module state (true == done). - return array( 'finished' => true ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 1; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_updates' ); - } - - /** - * Retrieve all updates that we're interested in. - * - * @access public - * - * @return array All updates. - */ - public function get_all_updates() { - return array( - 'core' => get_site_transient( 'update_core' ), - 'plugins' => get_site_transient( 'update_plugins' ), - 'themes' => get_site_transient( 'update_themes' ), - ); - } - - /** - * Remove unnecessary keys from synced updates data. - * - * @access public - * - * @param array $args Hook arguments. - * @return array $args Hook arguments. - */ - public function filter_update_keys( $args ) { - $updates = $args[0]; - - if ( isset( $updates->no_update ) ) { - unset( $updates->no_update ); - } - - return $args; - } - - /** - * Filter out upgrader object from the completed upgrader action args. - * - * @access public - * - * @param array $args Hook arguments. - * @return array $args Filtered hook arguments. - */ - public function filter_upgrader_process_complete( $args ) { - array_shift( $args ); - - return $args; - } - - /** - * Expand the updates within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The hook parameters. - */ - public function expand_updates( $args ) { - if ( $args[0] ) { - return $this->get_all_updates(); - } - - return $args; - } - - /** - * Expand the themes within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook parameters. - * @return array $args The hook parameters. - */ - public function expand_themes( $args ) { - if ( ! isset( $args[0]->response ) ) { - return $args; - } - if ( ! is_array( $args[0]->response ) ) { - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_trigger_error - trigger_error( 'Warning: Not an Array as expected but -> ' . wp_json_encode( $args[0]->response ) . ' instead', E_USER_WARNING ); - return $args; - } - foreach ( $args[0]->response as $stylesheet => &$theme_data ) { - $theme = wp_get_theme( $stylesheet ); - $theme_data['name'] = $theme->name; - } - return $args; - } - - /** - * Perform module cleanup. - * Deletes any transients and options that this module uses. - * Usually triggered when uninstalling the plugin. - * - * @access public - */ - public function reset_data() { - delete_option( self::UPDATES_CHECKSUM_OPTION_NAME ); - } - - /** - * Return Total number of objects. - * - * @param array $config Full Sync config. - * - * @return int total - */ - public function total( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return 3; - } - - /** - * Retrieve a set of updates by their IDs. - * - * @access public - * - * @param string $object_type Object type. - * @param array $ids Object IDs. - * @return array Array of objects. - */ - public function get_objects_by_id( $object_type, $ids ) { - if ( empty( $ids ) || empty( $object_type ) || 'update' !== $object_type ) { - return array(); - } - - $objects = array(); - foreach ( (array) $ids as $id ) { - $object = $this->get_object_by_id( $object_type, $id ); - - if ( 'all' === $id ) { - // If all was requested it contains all updates and can simply be returned. - return $object; - } - $objects[ $id ] = $object; - } - - return $objects; - } - - /** - * Retrieve a update by its id. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param string $id ID of the sync object. - * @return mixed Value of Update. - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'update' === $object_type ) { - - // Only whitelisted constants can be returned. - if ( in_array( $id, array( 'core', 'plugins', 'themes' ), true ) ) { - return get_site_transient( 'update_' . $id ); - } elseif ( 'all' === $id ) { - return $this->get_all_updates(); - } - } - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php deleted file mode 100644 index e043a119..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php +++ /dev/null @@ -1,948 +0,0 @@ - 'password_changed', - 'user_email' => 'email_changed', - 'user_nicename' => 'nicename_changed', - 'user_url' => 'url_changed', - 'user_registered' => 'registration_date_changed', - 'user_activation_key' => 'activation_key_changed', - 'display_name' => 'display_name_changed', - ); - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'users'; - } - - /** - * The table name. - * - * @access public - * - * @return string - * @deprecated since 3.11.0 Use table() instead. - */ - public function table_name() { - _deprecated_function( __METHOD__, '3.11.0', 'Automattic\\Jetpack\\Sync\\Users->table' ); - return 'usermeta'; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - global $wpdb; - return $wpdb->usermeta; - } - - /** - * The id field in the database. - * - * @access public - * - * @return string - */ - public function id_field() { - return 'user_id'; - } - - /** - * Retrieve a user by its ID. - * This is here to support the backfill API. - * - * @access public - * - * @param string $object_type Type of the sync object. - * @param int $id ID of the sync object. - * @return \WP_User|bool Filtered \WP_User object, or false if the object is not a user. - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'user' === $object_type ) { - $user = get_user_by( 'id', (int) $id ); - if ( $user ) { - return $this->sanitize_user_and_expand( $user ); - } - } - - return false; - } - - /** - * Initialize users action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - // Users. - add_action( 'user_register', array( $this, 'user_register_handler' ) ); - add_action( 'profile_update', array( $this, 'save_user_handler' ), 10, 2 ); - - add_action( 'add_user_to_blog', array( $this, 'add_user_to_blog_handler' ) ); - add_action( 'jetpack_sync_add_user', $callable, 10, 2 ); - - add_action( 'jetpack_sync_register_user', $callable, 10, 2 ); - add_action( 'jetpack_sync_save_user', $callable, 10, 2 ); - - add_action( 'jetpack_sync_user_locale', $callable, 10, 2 ); - add_action( 'jetpack_sync_user_locale_delete', $callable, 10, 1 ); - - add_action( 'deleted_user', array( $this, 'deleted_user_handler' ), 10, 2 ); - add_action( 'jetpack_deleted_user', $callable, 10, 3 ); - add_action( 'remove_user_from_blog', array( $this, 'remove_user_from_blog_handler' ), 10, 2 ); - add_action( 'jetpack_removed_user_from_blog', $callable, 10, 2 ); - - // User roles. - add_action( 'add_user_role', array( $this, 'add_user_role_handler' ), 10, 2 ); - add_action( 'set_user_role', array( $this, 'save_user_role_handler' ), 10, 3 ); - add_action( 'remove_user_role', array( $this, 'remove_user_role_handler' ), 10, 2 ); - - // User capabilities. - add_action( 'added_user_meta', array( $this, 'maybe_save_user_meta' ), 10, 4 ); - add_action( 'updated_user_meta', array( $this, 'maybe_save_user_meta' ), 10, 4 ); - add_action( 'deleted_user_meta', array( $this, 'maybe_save_user_meta' ), 10, 4 ); - - // User authentication. - add_filter( 'authenticate', array( $this, 'authenticate_handler' ), 1000, 3 ); - add_action( 'wp_login', array( $this, 'wp_login_handler' ), 10, 2 ); - - add_action( 'jetpack_wp_login', $callable, 10, 3 ); - - add_action( 'wp_logout', $callable, 10, 1 ); - add_action( 'wp_masterbar_logout', $callable, 10, 1 ); - - // Add on init. - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_add_user', array( $this, 'expand_action' ) ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_register_user', array( $this, 'expand_action' ) ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_sync_save_user', array( $this, 'expand_action' ) ); - add_filter( 'jetpack_sync_before_enqueue_jetpack_wp_login', array( $this, 'expand_login_username' ), 10, 1 ); - add_filter( 'jetpack_sync_before_enqueue_wp_logout', array( $this, 'expand_logout_username' ), 10, 1 ); - } - - /** - * Initialize users action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_users', $callable ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - // Full sync. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_users', array( $this, 'expand_users' ) ); - } - - /** - * Retrieve a user by a user ID or object. - * - * @access private - * - * @param mixed $user User object or ID. - * @return \WP_User|null User object, or `null` if user invalid/not found. - */ - private function get_user( $user ) { - if ( is_numeric( $user ) ) { - $user = get_user_by( 'id', $user ); - } - if ( $user instanceof \WP_User ) { - return $user; - } - return null; - } - - /** - * Sanitize a user object. - * Removes the password from the user object because we don't want to sync it. - * - * @access public - * - * @todo Refactor `serialize`/`unserialize` to `wp_json_encode`/`wp_json_decode`. - * - * @param \WP_User $user User object. - * @return \WP_User Sanitized user object. - */ - public function sanitize_user( $user ) { - $user = $this->get_user( $user ); - // This creates a new user object and stops the passing of the object by reference. - // // phpcs:disable WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize, WordPress.PHP.DiscouragedPHPFunctions.serialize_unserialize - $user = unserialize( serialize( $user ) ); - - if ( is_object( $user ) && is_object( $user->data ) ) { - unset( $user->data->user_pass ); - } - return $user; - } - - /** - * Expand a particular user. - * - * @access public - * - * @param \WP_User $user User object. - * @return \WP_User Expanded user object. - */ - public function expand_user( $user ) { - if ( ! is_object( $user ) ) { - return null; - } - $user->allowed_mime_types = get_allowed_mime_types( $user ); - $user->allcaps = $this->get_real_user_capabilities( $user ); - - // Only set the user locale if it is different from the site locale. - if ( get_locale() !== get_user_locale( $user->ID ) ) { - $user->locale = get_user_locale( $user->ID ); - } - - return $user; - } - - /** - * Retrieve capabilities we care about for a particular user. - * - * @access public - * - * @param \WP_User $user User object. - * @return array User capabilities. - */ - public function get_real_user_capabilities( $user ) { - $user_capabilities = array(); - if ( is_wp_error( $user ) ) { - return $user_capabilities; - } - foreach ( Defaults::get_capabilities_whitelist() as $capability ) { - if ( user_can( $user, $capability ) ) { - $user_capabilities[ $capability ] = true; - } - } - return $user_capabilities; - } - - /** - * Retrieve, expand and sanitize a user. - * Can be directly used in the sync user action handlers. - * - * @access public - * - * @param mixed $user User ID or user object. - * @return \WP_User Expanded and sanitized user object. - */ - public function sanitize_user_and_expand( $user ) { - $user = $this->get_user( $user ); - $user = $this->expand_user( $user ); - return $this->sanitize_user( $user ); - } - - /** - * Expand the user within a hook before it is serialized and sent to the server. - * - * @access public - * - * @param array $args The hook arguments. - * @return array $args The hook arguments. - */ - public function expand_action( $args ) { - // The first argument is always the user. - list( $user ) = $args; - if ( $user ) { - $args[0] = $this->sanitize_user_and_expand( $user ); - return $args; - } - - return false; - } - - /** - * Expand the user username at login before enqueuing. - * - * @access public - * - * @param array $args The hook arguments. - * @return array $args Expanded hook arguments. - */ - public function expand_login_username( $args ) { - list( $login, $user, $flags ) = $args; - $user = $this->sanitize_user( $user ); - - return array( $login, $user, $flags ); - } - - /** - * Expand the user username at logout before enqueuing. - * - * @access public - * - * @param array $args The hook arguments. - * @return false|array $args Expanded hook arguments or false if we don't have a user. - */ - public function expand_logout_username( $args ) { - list( $user_id ) = $args; - - $user = get_userdata( $user_id ); - $user = $this->sanitize_user( $user ); - - $login = ''; - if ( is_object( $user ) && is_object( $user->data ) ) { - $login = $user->data->user_login; - } - - // If we don't have a user here lets not enqueue anything. - if ( empty( $login ) ) { - return false; - } - - return array( $login, $user ); - } - - /** - * Additional processing is needed for wp_login so we introduce this wrapper handler. - * - * @access public - * - * @param string $user_login The user login. - * @param \WP_User $user The user object. - */ - public function wp_login_handler( $user_login, $user ) { - /** - * Fires when a user is logged into a site. - * - * @since 1.6.3 - * @since-jetpack 7.2.0 - * - * @param int $user_id The user ID. - * @param \WP_User $user The User Object of the user that currently logged in. - * @param array $params Any Flags that have been added during login. - */ - do_action( 'jetpack_wp_login', $user->ID, $user, $this->get_flags( $user->ID ) ); - $this->clear_flags( $user->ID ); - } - - /** - * A hook for the authenticate event that checks the password strength. - * - * @access public - * - * @param \WP_Error|\WP_User $user The user object, or an error. - * @param string $username The username. - * @param string $password The password used to authenticate. - * @return \WP_Error|\WP_User the same object that was passed into the function. - */ - public function authenticate_handler( $user, $username, $password ) { - // In case of cookie authentication we don't do anything here. - if ( empty( $password ) ) { - return $user; - } - - // We are only interested in successful authentication events. - if ( is_wp_error( $user ) || ! ( $user instanceof \WP_User ) ) { - return $user; - } - - $password_checker = new Password_Checker( $user->ID ); - - $test_results = $password_checker->test( $password, true ); - - // If the password passes tests, we don't do anything. - if ( empty( $test_results['test_results']['failed'] ) ) { - return $user; - } - - $this->add_flags( - $user->ID, - array( - 'warning' => 'The password failed at least one strength test.', - 'failures' => $test_results['test_results']['failed'], - ) - ); - - return $user; - } - - /** - * Handler for after the user is deleted. - * - * @access public - * - * @param int $deleted_user_id ID of the deleted user. - * @param int $reassigned_user_id ID of the user the deleted user's posts are reassigned to (if any). - */ - public function deleted_user_handler( $deleted_user_id, $reassigned_user_id = '' ) { - $is_multisite = is_multisite(); - /** - * Fires when a user is deleted on a site - * - * @since 1.6.3 - * @since-jetpack 5.4.0 - * - * @param int $deleted_user_id - ID of the deleted user. - * @param int $reassigned_user_id - ID of the user the deleted user's posts are reassigned to (if any). - * @param bool $is_multisite - Whether this site is a multisite installation. - */ - do_action( 'jetpack_deleted_user', $deleted_user_id, $reassigned_user_id, $is_multisite ); - } - - /** - * Handler for user registration. - * - * @access public - * - * @param int $user_id ID of the deleted user. - */ - public function user_register_handler( $user_id ) { - // Ensure we only sync users who are members of the current blog. - if ( ! is_user_member_of_blog( $user_id, get_current_blog_id() ) ) { - return; - } - - if ( Jetpack_Constants::is_true( 'JETPACK_INVITE_ACCEPTED' ) ) { - $this->add_flags( $user_id, array( 'invitation_accepted' => true ) ); - } - /** - * Fires when a new user is registered on a site - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param object The WP_User object - */ - do_action( 'jetpack_sync_register_user', $user_id, $this->get_flags( $user_id ) ); - $this->clear_flags( $user_id ); - } - - /** - * Handler for user addition to the current blog. - * - * @access public - * - * @param int $user_id ID of the user. - */ - public function add_user_to_blog_handler( $user_id ) { - // Ensure we only sync users who are members of the current blog. - if ( ! is_user_member_of_blog( $user_id, get_current_blog_id() ) ) { - return; - } - - if ( Jetpack_Constants::is_true( 'JETPACK_INVITE_ACCEPTED' ) ) { - $this->add_flags( $user_id, array( 'invitation_accepted' => true ) ); - } - - /** - * Fires when a user is added on a site - * - * @since 1.6.3 - * @since-jetpack 4.9.0 - * - * @param object The WP_User object - */ - do_action( 'jetpack_sync_add_user', $user_id, $this->get_flags( $user_id ) ); - $this->clear_flags( $user_id ); - } - - /** - * Handler for user save. - * - * @access public - * - * @param int $user_id ID of the user. - * @param \WP_User $old_user_data User object before the changes. - */ - public function save_user_handler( $user_id, $old_user_data = null ) { - // Ensure we only sync users who are members of the current blog. - if ( ! is_user_member_of_blog( $user_id, get_current_blog_id() ) ) { - return; - } - - $user = get_user_by( 'id', $user_id ); - - // Older versions of WP don't pass the old_user_data in ->data. - if ( isset( $old_user_data->data ) ) { - $old_user = $old_user_data->data; - } else { - $old_user = $old_user_data; - } - - if ( ! is_object( $old_user ) ) { - return; - } - - $old_user_array = get_object_vars( $old_user ); - - foreach ( $old_user_array as $user_field => $field_value ) { - if ( false === $user->has_prop( $user_field ) ) { - continue; - } - if ( 'ID' === $user_field ) { - continue; - } - if ( $user->$user_field !== $field_value ) { - if ( 'user_email' === $user_field ) { - /** - * The '_new_email' user meta is deleted right after the call to wp_update_user - * that got us to this point so if it's still set then this was a user confirming - * their new email address. - */ - if ( 1 === (int) get_user_meta( $user->ID, '_new_email', true ) ) { - $this->flags[ $user_id ]['email_changed'] = true; - } - continue; - } - - $flag = isset( $this->user_fields_to_flags_mapping[ $user_field ] ) ? $this->user_fields_to_flags_mapping[ $user_field ] : 'unknown_field_changed'; - - $this->flags[ $user_id ][ $flag ] = true; - } - } - - if ( isset( $this->flags[ $user_id ] ) ) { - - /** - * Fires when the client needs to sync an updated user. - * - * @since 1.6.3 - * @since-jetpack 4.2.0 - * - * @param \WP_User The WP_User object - * @param array State - New since 5.8.0 - */ - do_action( 'jetpack_sync_save_user', $user_id, $this->get_flags( $user_id ) ); - $this->clear_flags( $user_id ); - } - } - - /** - * Handler for add user role change. - * - * @access public - * - * @param int $user_id ID of the user. - * @param string $role New user role. - */ - public function add_user_role_handler( $user_id, $role ) { - $this->add_flags( - $user_id, - array( - 'role_added' => $role, - ) - ); - - $this->save_user_role_handler( $user_id, $role ); - } - - /** - * Handler for remove user role change. - * - * @access public - * - * @param int $user_id ID of the user. - * @param string $role Removed user role. - */ - public function remove_user_role_handler( $user_id, $role ) { - $this->add_flags( - $user_id, - array( - 'role_removed' => $role, - ) - ); - - $this->save_user_role_handler( $user_id, $role ); - } - - /** - * Handler for user role change. - * - * @access public - * - * @param int $user_id ID of the user. - * @param string $role New user role. - * @param array $old_roles Previous user roles. - */ - public function save_user_role_handler( $user_id, $role, $old_roles = null ) { - $this->add_flags( - $user_id, - array( - 'role_changed' => true, - 'previous_role' => $old_roles, - ) - ); - - // The jetpack_sync_register_user payload is identical to jetpack_sync_save_user, don't send both. - if ( $this->is_create_user() || $this->is_add_user_to_blog() ) { - return; - } - /** - * This action is documented already in this file - */ - do_action( 'jetpack_sync_save_user', $user_id, $this->get_flags( $user_id ) ); - $this->clear_flags( $user_id ); - } - - /** - * Retrieve current flags for a particular user. - * - * @access public - * - * @param int $user_id ID of the user. - * @return array Current flags of the user. - */ - public function get_flags( $user_id ) { - if ( isset( $this->flags[ $user_id ] ) ) { - return $this->flags[ $user_id ]; - } - return array(); - } - - /** - * Clear the flags of a particular user. - * - * @access public - * - * @param int $user_id ID of the user. - */ - public function clear_flags( $user_id ) { - if ( isset( $this->flags[ $user_id ] ) ) { - unset( $this->flags[ $user_id ] ); - } - } - - /** - * Add flags to a particular user. - * - * @access public - * - * @param int $user_id ID of the user. - * @param array $flags New flags to add for the user. - */ - public function add_flags( $user_id, $flags ) { - $this->flags[ $user_id ] = wp_parse_args( $flags, $this->get_flags( $user_id ) ); - } - - /** - * Save the user meta, if we're interested in it. - * Also uses the time to add flags for the user. - * - * @access public - * - * @param int $meta_id ID of the meta object. - * @param int $user_id ID of the user. - * @param string $meta_key Meta key. - * @param mixed $value Meta value. - */ - public function maybe_save_user_meta( $meta_id, $user_id, $meta_key, $value ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - if ( 'locale' === $meta_key ) { - $this->add_flags( $user_id, array( 'locale_changed' => true ) ); - } - - $user = get_user_by( 'id', $user_id ); - if ( isset( $user->cap_key ) && $meta_key === $user->cap_key ) { - $this->add_flags( $user_id, array( 'capabilities_changed' => true ) ); - } - - if ( $this->is_create_user() || $this->is_add_user_to_blog() || $this->is_delete_user() ) { - return; - } - - if ( isset( $this->flags[ $user_id ] ) ) { - /** - * This action is documented already in this file - */ - do_action( 'jetpack_sync_save_user', $user_id, $this->get_flags( $user_id ) ); - } - } - - /** - * Enqueue the users actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - global $wpdb; - - return $this->enqueue_all_ids_as_action( 'jetpack_full_sync_users', $wpdb->usermeta, 'user_id', $this->get_where_sql( $config ), $max_items_to_enqueue, $state ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @todo Refactor to prepare the SQL query before executing it. - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { - global $wpdb; - - $query = "SELECT count(*) FROM $wpdb->usermeta"; - - $where_sql = $this->get_where_sql( $config ); - if ( $where_sql ) { - $query .= ' WHERE ' . $where_sql; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / self::ARRAY_CHUNK_SIZE ); - } - - /** - * Retrieve the WHERE SQL clause based on the module config. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return string WHERE SQL clause, or `null` if no comments are specified in the module config. - */ - public function get_where_sql( $config ) { - global $wpdb; - - $query = "meta_key = '{$wpdb->prefix}user_level' AND meta_value > 0"; - - // The $config variable is a list of user IDs to sync. - if ( is_array( $config ) ) { - $query .= ' AND user_id IN (' . implode( ',', array_map( 'intval', $config ) ) . ')'; - } - - return $query; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_users' ); - } - - /** - * Retrieve initial sync user config. - * - * @access public - * - * @todo Refactor the SQL query to call $wpdb->prepare() before execution. - * - * @return array|boolean IDs of users to initially sync, or false if tbe number of users exceed the maximum. - */ - public function get_initial_sync_user_config() { - global $wpdb; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $user_ids = $wpdb->get_col( "SELECT user_id FROM $wpdb->usermeta WHERE meta_key = '{$wpdb->prefix}user_level' AND meta_value > 0 LIMIT " . ( self::MAX_INITIAL_SYNC_USERS + 1 ) ); - $user_ids_count = is_countable( $user_ids ) ? count( $user_ids ) : 0; - - if ( $user_ids_count <= self::MAX_INITIAL_SYNC_USERS ) { - return $user_ids; - } else { - return false; - } - } - - /** - * Expand the users within a hook before they are serialized and sent to the server. - * - * @access public - * - * @param array $args The hook arguments. - * @return array $args The hook arguments. - */ - public function expand_users( $args ) { - list( $user_ids, $previous_end ) = $args; - - return array( - 'users' => array_map( - array( $this, 'sanitize_user_and_expand' ), - get_users( - array( - 'include' => $user_ids, - 'orderby' => 'ID', - 'order' => 'DESC', - ) - ) - ), - 'previous_end' => $previous_end, - ); - } - - /** - * Handler for user removal from a particular blog. - * - * @access public - * - * @param int $user_id ID of the user. - * @param int $blog_id ID of the blog. - */ - public function remove_user_from_blog_handler( $user_id, $blog_id ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - // User is removed on add, see https://github.com/WordPress/WordPress/blob/0401cee8b36df3def8e807dd766adc02b359dfaf/wp-includes/ms-functions.php#L2114. - if ( $this->is_add_new_user_to_blog() ) { - return; - } - - $reassigned_user_id = $this->get_reassigned_network_user_id(); - - // Note that we are in the context of the blog the user is removed from, see https://github.com/WordPress/WordPress/blob/473e1ba73bc5c18c72d7f288447503713d518790/wp-includes/ms-functions.php#L233. - /** - * Fires when a user is removed from a blog on a multisite installation - * - * @since 1.6.3 - * @since-jetpack 5.4.0 - * - * @param int $user_id - ID of the removed user - * @param int $reassigned_user_id - ID of the user the removed user's posts are reassigned to (if any). - */ - do_action( 'jetpack_removed_user_from_blog', $user_id, $reassigned_user_id ); - } - - /** - * Whether we're adding a new user to a blog in this request. - * - * @access protected - * - * @return boolean - */ - protected function is_add_new_user_to_blog() { - return $this->is_function_in_backtrace( 'add_new_user_to_blog' ); - } - - /** - * Whether we're adding an existing user to a blog in this request. - * - * @access protected - * - * @return boolean - */ - protected function is_add_user_to_blog() { - return $this->is_function_in_backtrace( 'add_user_to_blog' ); - } - - /** - * Whether we're removing a user from a blog in this request. - * - * @access protected - * - * @return boolean - */ - protected function is_delete_user() { - return $this->is_function_in_backtrace( array( 'wp_delete_user', 'remove_user_from_blog' ) ); - } - - /** - * Whether we're creating a user or adding a new user to a blog. - * - * @access protected - * - * @return boolean - */ - protected function is_create_user() { - $functions = array( - 'add_new_user_to_blog', // Used to suppress jetpack_sync_save_user in save_user_cap_handler when user registered on multi site. - 'wp_create_user', // Used to suppress jetpack_sync_save_user in save_user_role_handler when user registered on multi site. - 'wp_insert_user', // Used to suppress jetpack_sync_save_user in save_user_cap_handler and save_user_role_handler when user registered on single site. - ); - - return $this->is_function_in_backtrace( $functions ); - } - - /** - * Retrieve the ID of the user the removed user's posts are reassigned to (if any). - * - * @return int ID of the user that got reassigned as the author of the posts. - */ - protected function get_reassigned_network_user_id() { - $backtrace = debug_backtrace( false ); // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace - foreach ( $backtrace as $call ) { - if ( - 'remove_user_from_blog' === $call['function'] && - 3 === count( $call['args'] ) - ) { - return $call['args'][2]; - } - } - - return false; - } - - /** - * Checks if one or more function names is in debug_backtrace. - * - * @access protected - * - * @param array|string $names Mixed string name of function or array of string names of functions. - * @return bool - */ - protected function is_function_in_backtrace( $names ) { - $backtrace = debug_backtrace( false ); // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_debug_backtrace - if ( ! is_array( $names ) ) { - $names = array( $names ); - } - $names_as_keys = array_flip( $names ); - - $backtrace_functions = array_column( $backtrace, 'function' ); - $backtrace_functions_as_keys = array_flip( $backtrace_functions ); - $intersection = array_intersect_key( $backtrace_functions_as_keys, $names_as_keys ); - return ! empty( $intersection ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce-hpos-orders.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce-hpos-orders.php deleted file mode 100644 index fb230342..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce-hpos-orders.php +++ /dev/null @@ -1,568 +0,0 @@ -table' ); - return $this->order_table_name; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - return $this->order_table_name; - } - - /** - * Initialize order table data store, returns if the class don't exist (pre WC 6.x) - * - * @access public - */ - public function __construct() { - if ( ! class_exists( OrdersTableDataStore::class ) ) { - return; - } - $this->order_table_name = OrdersTableDataStore::get_orders_table_name(); - } - - /** - * Get order types that we want to sync. Adding a new type here is not enough, we would also need to add its prop in filter_order_data method. - * - * @param bool $prefixed Whether to return prefixed types with shop_ or not. - * - * @return array Order types to sync. - */ - public static function get_order_types_to_sync( $prefixed = false ) { - $types = array( 'order', 'order_refund' ); - - // Ensure this is available. - if ( ! function_exists( 'is_plugin_active' ) ) { - require_once ABSPATH . 'wp-admin/includes/plugin.php'; - } - - if ( is_plugin_active( self::WOOCOMMERCE_SUBSCRIPTIONS_PATH ) ) { - $types[] = 'subscription'; - } - - if ( $prefixed ) { - $types = array_map( - function ( $type ) { - return "shop_{$type}"; - }, - $types - ); - } - return $types; - } - - /** - * Hooks sync listners on order modify events. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - foreach ( self::get_order_types_to_sync() as $type ) { - add_action( "woocommerce_after_{$type}_object_save", $callable ); - add_filter( "jetpack_sync_before_enqueue_woocommerce_after_{$type}_object_save", array( $this, 'expand_order_object' ) ); - } - add_action( 'woocommerce_delete_order', $callable ); - add_action( 'woocommerce_delete_subscription', $callable ); - add_filter( 'jetpack_sync_before_enqueue_woocommerce_delete_order', array( $this, 'on_before_enqueue_order_trash_delete' ) ); - add_filter( 'jetpack_sync_before_enqueue_woocommerce_delete_subscription', array( $this, 'on_before_enqueue_order_trash_delete' ) ); - add_action( 'woocommerce_trash_order', $callable ); - add_action( 'woocommerce_trash_subscription', $callable ); - add_filter( 'jetpack_sync_before_enqueue_woocommerce_trash_order', array( $this, 'on_before_enqueue_order_trash_delete' ) ); - add_filter( 'jetpack_sync_before_enqueue_woocommerce_trash_subscription', array( $this, 'on_before_enqueue_order_trash_delete' ) ); - } - - /** - * Hooks the full sync listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_orders', $callable ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - // Full sync. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_woocommerce_hpos_orders', array( $this, 'build_full_sync_action_array' ) ); - } - - /** - * Returns the ID field from wc_orders table. - * - * @access public - * - * @return string - */ - public function id_field() { - return 'id'; - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_orders' ); - } - - /** - * Retrieve order data by its ID. - * - * @access public - * - * @param string $object_type Type of object to retrieve. Should be `order`. - * @param int $id Order ID. - * - * @return array - */ - public function get_object_by_id( $object_type, $id ) { - if ( 'order' !== $object_type ) { - return $id; - } - $order_objects = $this->get_objects_by_id( $object_type, array( $id ) ); - return isset( $order_objects[ $id ] ) ? $order_objects[ $id ] : false; - } - - /** - * Retrieves multiple orders data by their ID. - * - * @access public - * - * @param string $object_type Type of object to retrieve. Should be `order`. - * @param array $ids List of order IDs. - * - * @return array - */ - public function get_objects_by_id( $object_type, $ids ) { - if ( 'order' !== $object_type || empty( $ids ) || ! is_array( $ids ) ) { - return array(); - } - - $orders = wc_get_orders( - array( - 'post__in' => $ids, - 'type' => self::get_order_types_to_sync( true ), - 'post_status' => self::get_all_possible_order_status_keys(), - 'limit' => -1, - ) - ); - - $orders_data = array(); - foreach ( $orders as $order ) { - $orders_data[ $order->get_id() ] = $this->filter_order_data( $order ); - } - - return $orders_data; - } - - /** - * Retrieves multiple orders data by their ID. - * - * @access public - * - * @param array $args List of order IDs. - * - * @return array - * @deprecated since 4.7.0 - */ - public function expand_order_objects( $args ) { - _deprecated_function( __METHOD__, '4.7.0' ); - list( $order_ids, $previous_end ) = $args; - return array( - 'orders' => $this->get_objects_by_id( 'order', $order_ids ), - 'previous_end' => $previous_end, - ); - } - - /** - * Build the full sync action object. - * - * @access public - * - * @param array $args An array with filtered objects and previous end. - * - * @return array An array with orders and previous end. - */ - public function build_full_sync_action_array( $args ) { - list( $filtered_orders, $previous_end ) = $args; - return array( - 'orders' => $filtered_orders['objects'], - 'previous_end' => $previous_end, - ); - } - - /** - * Retrieve order data by its ID. - * - * @access public - * - * @param array $args Order ID. - * - * @return array - */ - public function expand_order_object( $args ) { - if ( ! is_array( $args ) || ! isset( $args[0] ) ) { - return false; - } - $order_object = $args[0]; - - if ( is_int( $order_object ) ) { - $order_object = wc_get_order( $order_object ); - } - - if ( ! $order_object instanceof \WC_Abstract_Order ) { - return false; - } - - return $this->filter_order_data( $order_object ); - } - - /** - * Convert order ID to array. - * - * @access public - * - * @param array $args Order ID. - * - * @return array - */ - public function on_before_enqueue_order_trash_delete( $args ) { - if ( ! is_array( $args ) || ! isset( $args[0] ) ) { - return false; - } - $order_id = $args[0]; - - if ( ! is_int( $order_id ) ) { - return false; - } - - return array( 'id' => $order_id ); - } - - /** - * Filters only allowed keys from order data. No PII etc information is allowed to be synced. - * - * @access private - * - * @param \WC_Abstract_Order $order_object Order object. - * - * @return array Filtered order data. - */ - private function filter_order_data( $order_object ) { - // Filter with allowlist. - $allowed_data_keys = WooCommerce::$wc_post_meta_whitelist; - $core_table_keys = array( - 'id', - 'status', - 'date_created', - 'date_modified', - 'parent_id', - ); - $allowed_data_keys = array_merge( $allowed_data_keys, $core_table_keys ); - $filtered_order_data = array( 'type' => $order_object->get_type() ); - $order_data = $order_object->get_data(); - foreach ( $allowed_data_keys as $key ) { - $key = trim( $key, '_' ); - $key_parts = explode( '_', $key ); - - if ( in_array( $key_parts[0], array( 'order', 'refund' ), true ) ) { - if ( isset( $order_data[ $key_parts[1] ] ) && ! is_array( $order_data[ $key_parts[1] ] ) ) { - $filtered_order_data[ $key ] = $order_data[ $key_parts[1] ]; - continue; - } - } - - if ( in_array( $key_parts[0], array( 'billing', 'shipping' ), true ) && 2 === count( $key_parts ) ) { - if ( isset( $order_data[ $key_parts[0] ][ $key_parts[1] ] ) ) { - $filtered_order_data[ $key ] = $order_data[ $key_parts[0] ][ $key_parts[1] ]; - continue; - } - } - - /** - * We need to convert the WC_DateTime objects to stdClass objects to ensure they are properly encoded. - * - * @see Automattic\Jetpack\Sync\Functions::json_wrap as the return value of get_object_vars can vary depending on PHP version. - */ - if ( in_array( $key, array( 'date_created', 'date_modified', 'date_paid', 'date_completed' ), true ) && isset( $order_data[ $key ] ) ) { - if ( is_a( $order_data[ $key ], 'WC_DateTime' ) ) { - $filtered_order_data[ $key ] = (object) (array) $order_data[ $key ]; - continue; - } - } - - if ( isset( $order_data[ $key ] ) ) { - $filtered_order_data[ $key ] = $order_data[ $key ]; - continue; - } - - switch ( $key ) { - case 'cart_discount': - $filtered_order_data[ $key ] = isset( $order_data['discount_total'] ) ? $order_data['discount_total'] : ''; - break; - case 'cart_discount_tax': - $filtered_order_data[ $key ] = isset( $order_data['discount_tax'] ) ? $order_data['discount_tax'] : ''; - break; - case 'order_shipping': - $filtered_order_data[ $key ] = isset( $order_data['shipping_total'] ) ? $order_data['shipping_total'] : ''; - break; - case 'order_shipping_tax': - $filtered_order_data[ $key ] = isset( $order_data['shipping_tax'] ) ? $order_data['shipping_tax'] : ''; - break; - case 'order_tax': - $filtered_order_data[ $key ] = isset( $order_data['cart_tax'] ) ? $order_data['cart_tax'] : ''; - break; - case 'order_total': - $filtered_order_data[ $key ] = isset( $order_data['total'] ) ? $order_data['total'] : ''; - break; - } - } - if ( '' === $filtered_order_data['status'] ) { - $filtered_order_data['status'] = 'pending'; - } - $filtered_order_data['status'] = self::get_wc_order_status_with_prefix( $filtered_order_data['status'] ); - - /** - * Filter the order data before syncing. - * - * @since 3.7.0 - * - * @param array $filtered_order_data The Filtered order data. - * @param \WC_Abstract_Order $order_object The Order object. - */ - return apply_filters( 'jetpack_sync_filtered_hpos_order_data', $filtered_order_data, $order_object ); - } - - /** - * Returns all possible order status keys, including 'auto-draft' and 'trash'. - * - * @access public - * - * @return array An array of all possible status keys, including 'auto-draft' and 'trash'. - */ - public static function get_all_possible_order_status_keys() { - $order_statuses = array( 'auto-draft', 'trash' ); - $wc_order_statuses = self::wc_get_order_status_keys(); - - return array_unique( array_merge( $wc_order_statuses, $order_statuses ) ); - } - - /** - * Add the 'wc-' order status to WC related order statuses. - * - * @param string $status The WC order status without the 'wc-' prefix. - * - * @return string The WC order status with the 'wc-' prefix if it's a valid order status, initial $status otherwise. - */ - protected static function get_wc_order_status_with_prefix( string $status ) { - return in_array( 'wc-' . $status, self::wc_get_order_status_keys(), true ) ? 'wc-' . $status : $status; - } - - /** - * Returns order status keys using 'wc_get_order_statuses', if possible. - * - * @see wc_get_order_statuses - * - * @return array Filtered order metadata. - */ - private static function wc_get_order_status_keys() { - $wc_order_statuses = array(); - if ( function_exists( 'wc_get_order_statuses' ) ) { - $wc_order_statuses = array_keys( wc_get_order_statuses() ); - $wc_order_statuses[] = 'wc-checkout-draft'; // Temp till Woo fixes a bug where this order status is missing. - } else { - $wc_order_statuses = array( - 'wc-pending', - 'wc-processing', - 'wc-on-hold', - 'wc-completed', - 'wc-cancelled', - 'wc-refunded', - 'wc-failed', - 'wc-checkout-draft', - ); - } - - if ( function_exists( 'wcs_get_subscription_statuses' ) ) { - // @phan-suppress-next-line PhanUndeclaredFunction -- Checked above. See also https://github.com/phan/phan/issues/1204. - $wc_subscription_statuses = array_keys( wcs_get_subscription_statuses() ); - $wc_order_statuses = array_merge( $wc_order_statuses, $wc_subscription_statuses ); - } - - return array_unique( $wc_order_statuses ); - } - - /** - * Returns metadata for order object. - * - * @access protected - * - * @param array $ids List of order IDs. - * @param string $meta_type Meta type. - * @param array $meta_key_whitelist List of allowed meta keys. - * - * @return array Filtered order metadata. - */ - protected function get_metadata( $ids, $meta_type, $meta_key_whitelist ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable -- returning empty meta is intentional. - return array(); // don't sync metadata, all allow-listed core data is available in the order object. - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable -- We return all order count for full sync, so confit is not required. - global $wpdb; - - $query = "SELECT count(*) FROM {$this->table()} WHERE {$this->get_where_sql( $config ) }"; - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared, WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching -- Hardcoded query, no user variable - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / self::ARRAY_CHUNK_SIZE ); - } - - /** - * Enqueue the WooCommerce HPOS orders actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - return $this->enqueue_all_ids_as_action( 'full_sync_orders', $this->table(), 'id', $this->get_where_sql( $config ), $max_items_to_enqueue, $state ); - } - - /** - * Get where SQL for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * - * @return string WHERE SQL clause, or `null` if no comments are specified in the module config. - */ - public function get_where_sql( $config ) { - global $wpdb; - $parent_where = parent::get_where_sql( $config ); - $order_types = self::get_order_types_to_sync( true ); - $order_type_placeholder = implode( ', ', array_fill( 0, count( $order_types ), '%s' ) ); - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared, WordPress.DB.PreparedSQLPlaceholders.UnfinishedPrepare -- Query is prepared. - $where_sql = $wpdb->prepare( "type IN ( $order_type_placeholder )", $order_types ); - return "{$parent_where} AND {$where_sql}"; - } - - /** - * Given the Module Configuration and Status return the next chunk of items to send. - * This function also expands the posts and metadata and filters them based on the maximum size constraints. - * - * @param array $config This module Full Sync configuration. - * @param array $status This module Full Sync status. - * @param int $chunk_size Chunk size. - * - * @return array - */ - public function get_next_chunk( $config, $status, $chunk_size ) { - - $order_ids = parent::get_next_chunk( $config, $status, $chunk_size ); - - if ( empty( $order_ids ) ) { - return array(); - } - - $orders = $this->get_objects_by_id( 'order', $order_ids ); - - // If no orders were fetched, make sure to return the expected structure so that status is updated correctly. - if ( empty( $orders ) ) { - return array( - 'object_ids' => $order_ids, - 'objects' => array(), - ); - } - - // Filter the orders based on the maximum size constraints. We don't need to filter metadata here since we don't sync it for hpos. - list( $filtered_order_ids, $filtered_orders, ) = $this->filter_objects_and_metadata_by_size( - 'order', - $orders, - array(), - 0, - self::MAX_SIZE_FULL_SYNC - ); - - return array( - 'object_ids' => $filtered_order_ids, - 'objects' => $filtered_orders, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php deleted file mode 100644 index 9cef133d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php +++ /dev/null @@ -1,747 +0,0 @@ -table' ); - return $this->order_item_table_name; - } - - /** - * The table in the database with the prefix. - * - * @access public - * - * @return string|bool - */ - public function table() { - global $wpdb; - return $wpdb->prefix . 'woocommerce_order_items'; - } - - /** - * The id field in the database. - * - * @access public - * - * @return string - */ - public function id_field() { - return 'order_item_id'; - } - - /** - * The full sync action name for this module. - * - * @access public - * - * @return string - */ - public function full_sync_action_name() { - return 'jetpack_full_sync_woocommerce_order_items'; - } - - /** - * Constructor. - * - * @global $wpdb - * - * @todo Should we refactor this to use $this->set_defaults() instead? - */ - public function __construct() { - global $wpdb; - $this->order_item_table_name = $wpdb->prefix . 'woocommerce_order_items'; - - // Options, constants and post meta whitelists. - add_filter( 'jetpack_sync_options_whitelist', array( $this, 'add_woocommerce_options_whitelist' ), 10 ); - add_filter( 'jetpack_sync_constants_whitelist', array( $this, 'add_woocommerce_constants_whitelist' ), 10 ); - add_filter( 'jetpack_sync_post_meta_whitelist', array( $this, 'add_woocommerce_post_meta_whitelist' ), 10 ); - add_filter( 'jetpack_sync_comment_meta_whitelist', array( $this, 'add_woocommerce_comment_meta_whitelist' ), 10 ); - - add_filter( 'jetpack_sync_before_enqueue_woocommerce_new_order_item', array( $this, 'filter_order_item' ) ); - add_filter( 'jetpack_sync_before_enqueue_woocommerce_update_order_item', array( $this, 'filter_order_item' ) ); - add_filter( 'jetpack_sync_whitelisted_comment_types', array( $this, 'add_review_comment_types' ) ); - - // Blacklist Action Scheduler comment types. - add_filter( 'jetpack_sync_prevent_sending_comment_data', array( $this, 'filter_action_scheduler_comments' ), 10, 2 ); - - // Preprocess action to be sent by Jetpack sync. - add_action( 'woocommerce_remove_order_items', array( $this, 'action_woocommerce_remove_order_items' ), 10, 2 ); - } - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'woocommerce'; - } - - /** - * Initialize WooCommerce action listeners. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_listeners( $callable ) { - // Attributes. - add_action( 'woocommerce_attribute_added', $callable, 10, 2 ); - add_action( 'woocommerce_attribute_updated', $callable, 10, 3 ); - add_action( 'woocommerce_attribute_deleted', $callable, 10, 3 ); - - // Orders. - add_action( 'woocommerce_new_order', $callable, 10, 1 ); - add_action( 'woocommerce_order_status_changed', $callable, 10, 3 ); - add_action( 'woocommerce_payment_complete', $callable, 10, 1 ); - - // Order items. - add_action( 'woocommerce_new_order_item', $callable, 10, 4 ); - add_action( 'woocommerce_update_order_item', $callable, 10, 4 ); - add_action( 'woocommerce_delete_order_item', $callable, 10, 1 ); - add_action( 'woocommerce_remove_order_item_ids', $callable, 10, 1 ); - $this->init_listeners_for_meta_type( 'order_item', $callable ); - - // Payment tokens. - add_action( 'woocommerce_new_payment_token', $callable, 10, 1 ); - add_action( 'woocommerce_payment_token_deleted', $callable, 10, 2 ); - add_action( 'woocommerce_payment_token_updated', $callable, 10, 1 ); - $this->init_listeners_for_meta_type( 'payment_token', $callable ); - - // Product downloads. - add_action( 'woocommerce_downloadable_product_download_log_insert', $callable, 10, 1 ); - add_action( 'woocommerce_grant_product_download_access', $callable, 10, 1 ); - - // Tax rates. - add_action( 'woocommerce_tax_rate_added', $callable, 10, 2 ); - add_action( 'woocommerce_tax_rate_updated', $callable, 10, 2 ); - add_action( 'woocommerce_tax_rate_deleted', $callable, 10, 1 ); - - // Webhooks. - add_action( 'woocommerce_new_webhook', $callable, 10, 1 ); - add_action( 'woocommerce_webhook_deleted', $callable, 10, 2 ); - add_action( 'woocommerce_webhook_updated', $callable, 10, 1 ); - } - - /** - * Initialize WooCommerce action listeners for full sync. - * - * @access public - * - * @param callable $callable Action handler callable. - */ - public function init_full_sync_listeners( $callable ) { - add_action( 'jetpack_full_sync_woocommerce_order_items', $callable ); // Also sends post meta. - } - - /** - * Retrieve the actions that will be sent for this module during a full sync. - * - * @access public - * - * @return array Full sync actions of this module. - */ - public function get_full_sync_actions() { - return array( 'jetpack_full_sync_woocommerce_order_items' ); - } - - /** - * Initialize the module in the sender. - * - * @access public - */ - public function init_before_send() { - // Full sync. - add_filter( 'jetpack_sync_before_send_jetpack_full_sync_woocommerce_order_items', array( $this, 'build_full_sync_action_array' ) ); - } - - /** - * Expand the order items properly. - * - * @access public - * - * @param array $args The hook arguments. - * @return array $args The hook arguments. - */ - public function filter_order_item( $args ) { - // Make sure we always have all the data - prior to WooCommerce 3.0 we only have the user supplied data in the second argument and not the full details. - $args[1] = $this->build_order_item( $args[0] ); - return $args; - } - - /** - * Retrieve the order item ids to be removed and send them as one action - * - * @param WC_Order $order The order argument. - * @param string $type Order item type. - */ - public function action_woocommerce_remove_order_items( WC_Order $order, $type ) { - if ( $type ) { - $order_items = $order->get_items( $type ); - } else { - $order_items = $order->get_items(); - } - $order_item_ids = array_keys( $order_items ); - - if ( $order_item_ids ) { - do_action( 'woocommerce_remove_order_item_ids', $order_item_ids ); - } - } - - /** - * Expand order item IDs to order items and their meta. - * - * @access public - * - * @todo Refactor table name to use a $wpdb->prepare placeholder. - * - * @param array $args The hook arguments. - * @return array $args Expanded order items with meta. - * @deprecated since 4.7.0 - */ - public function expand_order_item_ids( $args ) { - _deprecated_function( __METHOD__, '4.7.0' ); - $order_item_ids = $args[0]; - - global $wpdb; - - $order_item_ids_sql = implode( ', ', array_map( 'intval', $order_item_ids ) ); - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $order_items = $wpdb->get_results( - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT * FROM $this->order_item_table_name WHERE order_item_id IN ( $order_item_ids_sql )" - ); - - return array( - $order_items, - $this->get_metadata( $order_item_ids, 'order_item', static::$order_item_meta_whitelist ), - ); - } - /** - * Extract the full order item from the database by its ID. - * - * @access public - * - * @todo Refactor table name to use a $wpdb->prepare placeholder. - * - * @param int $order_item_id Order item ID. - * @return object Order item. - */ - public function build_order_item( $order_item_id ) { - global $wpdb; - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - return $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $this->order_item_table_name WHERE order_item_id = %d", $order_item_id ) ); - } - - /** - * Enqueue the WooCommerce actions for full sync. - * - * @access public - * - * @param array $config Full sync configuration for this sync module. - * @param int $max_items_to_enqueue Maximum number of items to enqueue. - * @param boolean $state True if full sync has finished enqueueing this module, false otherwise. - * @return array Number of actions enqueued, and next module state. - */ - public function enqueue_full_sync_actions( $config, $max_items_to_enqueue, $state ) { - return $this->enqueue_all_ids_as_action( 'jetpack_full_sync_woocommerce_order_items', $this->order_item_table_name, 'order_item_id', $this->get_where_sql( $config ), $max_items_to_enqueue, $state ); - } - - /** - * Retrieve an estimated number of actions that will be enqueued. - * - * @access public - * - * @todo Refactor the SQL query to use $wpdb->prepare(). - * - * @param array $config Full sync configuration for this sync module. - * @return array Number of items yet to be enqueued. - */ - public function estimate_full_sync_actions( $config ) { - global $wpdb; - - $query = "SELECT count(*) FROM $this->order_item_table_name WHERE " . $this->get_where_sql( $config ); - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count = (int) $wpdb->get_var( $query ); - - return (int) ceil( $count / self::ARRAY_CHUNK_SIZE ); - } - - /** - * Retrieve the WHERE SQL clause based on the module config. - * - * @access private - * - * @param array $config Full sync configuration for this sync module. - * @return string WHERE SQL clause. - */ - public function get_where_sql( $config ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - return '1=1'; - } - - /** - * Add WooCommerce options to the options whitelist. - * - * @param array $list Existing options whitelist. - * @return array Updated options whitelist. - */ - public function add_woocommerce_options_whitelist( $list ) { - return array_merge( $list, self::$wc_options_whitelist ); - } - - /** - * Add WooCommerce constants to the constants whitelist. - * - * @param array $list Existing constants whitelist. - * @return array Updated constants whitelist. - */ - public function add_woocommerce_constants_whitelist( $list ) { - return array_merge( $list, self::$wc_constants_whitelist ); - } - - /** - * Add WooCommerce post meta to the post meta whitelist. - * - * @param array $list Existing post meta whitelist. - * @return array Updated post meta whitelist. - */ - public function add_woocommerce_post_meta_whitelist( $list ) { - return array_merge( $list, self::$wc_post_meta_whitelist ); - } - - /** - * Add WooCommerce comment meta to the comment meta whitelist. - * - * @param array $list Existing comment meta whitelist. - * @return array Updated comment meta whitelist. - */ - public function add_woocommerce_comment_meta_whitelist( $list ) { - return array_merge( $list, self::$wc_comment_meta_whitelist ); - } - - /** - * Adds 'revew' to the list of comment types so Sync will listen for status changes on 'reviews'. - * - * @access public - * - * @param array $comment_types The list of comment types prior to this filter. - * return array The list of comment types with 'review' added. - */ - public function add_review_comment_types( $comment_types ) { - if ( is_array( $comment_types ) ) { - $comment_types[] = 'review'; - } - return $comment_types; - } - - /** - * Stop comments from the Action Scheduler from being synced. - * https://github.com/woocommerce/woocommerce/tree/e7762627c37ec1f7590e6cac4218ba0c6a20024d/includes/libraries/action-scheduler - * - * @since 1.6.3 - * @since-jetpack 7.7.0 - * - * @param boolean $can_sync Should we prevent comment data from bing synced to WordPress.com. - * @param mixed $comment WP_COMMENT object. - * - * @return bool - */ - public function filter_action_scheduler_comments( $can_sync, $comment ) { - if ( isset( $comment->comment_agent ) && 'ActionScheduler' === $comment->comment_agent ) { - return true; - } - return $can_sync; - } - - /** - * Whitelist for options we are interested to sync. - * - * @access private - * @static - * - * @var array - */ - private static $wc_options_whitelist = array( - 'woocommerce_currency', - 'woocommerce_db_version', - 'woocommerce_weight_unit', - 'woocommerce_version', - 'woocommerce_unforce_ssl_checkout', - 'woocommerce_tax_total_display', - 'woocommerce_tax_round_at_subtotal', - 'woocommerce_tax_display_shop', - 'woocommerce_tax_display_cart', - 'woocommerce_prices_include_tax', - 'woocommerce_price_thousand_sep', - 'woocommerce_price_num_decimals', - 'woocommerce_price_decimal_sep', - 'woocommerce_notify_low_stock', - 'woocommerce_notify_low_stock_amount', - 'woocommerce_notify_no_stock', - 'woocommerce_notify_no_stock_amount', - 'woocommerce_manage_stock', - 'woocommerce_force_ssl_checkout', - 'woocommerce_hide_out_of_stock_items', - 'woocommerce_file_download_method', - 'woocommerce_enable_signup_and_login_from_checkout', - 'woocommerce_enable_shipping_calc', - 'woocommerce_enable_review_rating', - 'woocommerce_enable_guest_checkout', - 'woocommerce_enable_coupons', - 'woocommerce_enable_checkout_login_reminder', - 'woocommerce_enable_ajax_add_to_cart', - 'woocommerce_dimension_unit', - 'woocommerce_default_country', - 'woocommerce_default_customer_address', - 'woocommerce_currency_pos', - 'woocommerce_api_enabled', - 'woocommerce_allow_tracking', - 'woocommerce_task_list_hidden', - 'woocommerce_onboarding_profile', - 'woocommerce_cod_settings', - ); - - /** - * Whitelist for constants we are interested to sync. - * - * @access private - * @static - * - * @var array - */ - private static $wc_constants_whitelist = array( - // WooCommerce constants. - 'WC_PLUGIN_FILE', - 'WC_ABSPATH', - 'WC_PLUGIN_BASENAME', - 'WC_VERSION', - 'WOOCOMMERCE_VERSION', - 'WC_ROUNDING_PRECISION', - 'WC_DISCOUNT_ROUNDING_MODE', - 'WC_TAX_ROUNDING_MODE', - 'WC_DELIMITER', - 'WC_LOG_DIR', - 'WC_SESSION_CACHE_GROUP', - 'WC_TEMPLATE_DEBUG_MODE', - ); - - /** - * Whitelist for post meta we are interested to sync. - * - * @access private - * @static - * - * @var array - */ - public static $wc_post_meta_whitelist = array( - // WooCommerce products. - // See https://github.com/woocommerce/woocommerce/blob/8ed6e7436ff87c2153ed30edd83c1ab8abbdd3e9/includes/data-stores/class-wc-product-data-store-cpt.php#L21 . - '_visibility', - '_sku', - '_price', - '_regular_price', - '_sale_price', - '_sale_price_dates_from', - '_sale_price_dates_to', - 'total_sales', - '_tax_status', - '_tax_class', - '_manage_stock', - '_backorders', - '_sold_individually', - '_weight', - '_length', - '_width', - '_height', - '_upsell_ids', - '_crosssell_ids', - '_purchase_note', - '_default_attributes', - '_product_attributes', - '_virtual', - '_downloadable', - '_download_limit', - '_download_expiry', - '_featured', - '_downloadable_files', - '_wc_rating_count', - '_wc_average_rating', - '_wc_review_count', - '_variation_description', - '_thumbnail_id', - '_file_paths', - '_product_image_gallery', - '_product_version', - '_wp_old_slug', - - // Woocommerce orders. - // See https://github.com/woocommerce/woocommerce/blob/8ed6e7436ff87c2153ed30edd83c1ab8abbdd3e9/includes/data-stores/class-wc-order-data-store-cpt.php#L27 . - '_order_key', - '_order_currency', - // '_billing_first_name', do not sync these as they contain personal data - // '_billing_last_name', - // '_billing_company', - // '_billing_address_1', - // '_billing_address_2', - '_billing_city', - '_billing_state', - '_billing_postcode', - '_billing_country', - // '_billing_email', do not sync these as they contain personal data. - // '_billing_phone', - // '_shipping_first_name', - // '_shipping_last_name', - // '_shipping_company', - // '_shipping_address_1', - // '_shipping_address_2', - '_shipping_city', - '_shipping_state', - '_shipping_postcode', - '_shipping_country', - '_completed_date', - '_paid_date', - '_cart_discount', - '_cart_discount_tax', - '_order_shipping', - '_order_shipping_tax', - '_order_tax', - '_order_total', - '_payment_method', - '_payment_method_title', - // '_transaction_id', do not sync these as they contain personal data. - // '_customer_ip_address', - // '_customer_user_agent', - '_created_via', - '_order_version', - '_prices_include_tax', - '_date_completed', - '_date_paid', - '_payment_tokens', - // '_billing_address_index', do not sync these as they contain personal data. - // '_shipping_address_index', - '_recorded_sales', - '_recorded_coupon_usage_counts', - // See https://github.com/woocommerce/woocommerce/blob/8ed6e7436ff87c2153ed30edd83c1ab8abbdd3e9/includes/data-stores/class-wc-order-data-store-cpt.php#L539 . - '_download_permissions_granted', - // See https://github.com/woocommerce/woocommerce/blob/8ed6e7436ff87c2153ed30edd83c1ab8abbdd3e9/includes/data-stores/class-wc-order-data-store-cpt.php#L594 . - '_order_stock_reduced', - '_cart_hash', - - // Woocommerce order refunds. - // See https://github.com/woocommerce/woocommerce/blob/b8a2815ae546c836467008739e7ff5150cb08e93/includes/data-stores/class-wc-order-refund-data-store-cpt.php#L20 . - '_order_currency', - '_refund_amount', - '_refunded_by', - '_refund_reason', - '_order_shipping', - '_order_shipping_tax', - '_order_tax', - '_order_total', - '_order_version', - '_prices_include_tax', - '_payment_tokens', - ); - - /** - * Whitelist for comment meta we are interested to sync. - * - * @access private - * @static - * - * @var array - */ - private static $wc_comment_meta_whitelist = array( - 'rating', - ); - - /** - * Return a list of objects by their type and IDs - * - * @param string $object_type Object type. - * @param array $ids IDs of objects to return. - * - * @access public - * - * @return array|object|WP_Error|null - */ - public function get_objects_by_id( $object_type, $ids ) { - switch ( $object_type ) { - case 'order_item': - return $this->get_order_item_by_ids( $ids ); - } - - return new WP_Error( 'unsupported_object_type', 'Unsupported object type' ); - } - - /** - * Returns a list of order_item objects by their IDs. - * - * @param array $ids List of order_item IDs to fetch. - * @param string $order Either 'ASC' or 'DESC'. - * - * @access public - * - * @return array|object|null - */ - public function get_order_item_by_ids( $ids, $order = '' ) { - global $wpdb; - - if ( ! is_array( $ids ) ) { - return array(); - } - - // Make sure the IDs are numeric and are non-zero. - $ids = array_filter( array_map( 'intval', $ids ) ); - - if ( empty( $ids ) ) { - return array(); - } - - // Prepare the placeholders for the prepared query below. - $placeholders = implode( ',', array_fill( 0, count( $ids ), '%d' ) ); - - $query = "SELECT * FROM {$this->order_item_table_name} WHERE order_item_id IN ( $placeholders )"; - if ( ! empty( $order ) && in_array( $order, array( 'ASC', 'DESC' ), true ) ) { - $query .= " ORDER BY order_item_id $order"; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - return $wpdb->get_results( $wpdb->prepare( $query, $ids ), ARRAY_A ); - } - - /** - * Build the full sync action object for WooCommerce order items. - * - * @access public - * - * @param array $args An array with the order items and the previous end. - * - * @return array An array with the order items, order item meta and the previous end. - */ - public function build_full_sync_action_array( $args ) { - list( $filtered_order_items, $previous_end ) = $args; - return array( - 'order_items' => $filtered_order_items['objects'], - 'order_item_meta' => $filtered_order_items['meta'], - 'previous_end' => $previous_end, - ); - } - - /** - * Given the Module Configuration and Status return the next chunk of items to send. - * This function also expands the posts and metadata and filters them based on the maximum size constraints. - * - * @param array $config This module Full Sync configuration. - * @param array $status This module Full Sync status. - * @param int $chunk_size Chunk size. - * - * @return array - */ - public function get_next_chunk( $config, $status, $chunk_size ) { - - $order_item_ids = parent::get_next_chunk( $config, $status, $chunk_size ); - - if ( empty( $order_item_ids ) ) { - return array(); - } - // Fetch the order items in DESC order for the next chunk logic to work. - $order_items = $this->get_order_item_by_ids( $order_item_ids, 'DESC' ); - - // If no orders were fetched, make sure to return the expected structure so that status is updated correctly. - if ( empty( $order_items ) ) { - return array( - 'object_ids' => $order_item_ids, - 'objects' => array(), - ); - } - - // Get the order IDs from the orders that were fetched. - $fetched_order_item_ids = wp_list_pluck( $order_items, 'order_item_id' ); - $metadata = $this->get_metadata( $fetched_order_item_ids, 'order_item', static::$order_item_meta_whitelist ); - - // Filter the orders and metadata based on the maximum size constraints. - list( $filtered_order_item_ids, $filtered_order_items, $filtered_order_items_metadata ) = $this->filter_objects_and_metadata_by_size( - 'order_item', - $order_items, - $metadata, - self::MAX_META_LENGTH, - self::MAX_SIZE_FULL_SYNC - ); - - return array( - 'object_ids' => $filtered_order_item_ids, - 'objects' => $filtered_order_items, - 'meta' => $filtered_order_items_metadata, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php deleted file mode 100644 index af4aec41..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php +++ /dev/null @@ -1,156 +0,0 @@ -set_defaults() instead? - */ - public function __construct() { - add_filter( 'jetpack_sync_constants_whitelist', array( $this, 'add_wp_super_cache_constants_whitelist' ), 10 ); - add_filter( 'jetpack_sync_callable_whitelist', array( $this, 'add_wp_super_cache_callable_whitelist' ), 10 ); - } - - /** - * Whitelist for constants we are interested to sync. - * - * @access public - * @static - * - * @var array - */ - public static $wp_super_cache_constants = array( - 'WPLOCKDOWN', - 'WPSC_DISABLE_COMPRESSION', - 'WPSC_DISABLE_LOCKING', - 'WPSC_DISABLE_HTACCESS_UPDATE', - 'ADVANCEDCACHEPROBLEM', - ); - - /** - * Container for the whitelist for WP_Super_Cache callables we are interested to sync. - * - * @access public - * @static - * - * @var array - */ - public static $wp_super_cache_callables = array( - 'wp_super_cache_globals' => array( __CLASS__, 'get_wp_super_cache_globals' ), - ); - - /** - * Sync module name. - * - * @access public - * - * @return string - */ - public function name() { - return 'wp-super-cache'; - } - - /** - * Retrieve all WP_Super_Cache callables we are interested to sync. - * - * @access public - * - * @global $wp_cache_mod_rewrite; - * @global $cache_enabled; - * @global $super_cache_enabled; - * @global $ossdlcdn; - * @global $cache_rebuild_files; - * @global $wp_cache_mobile; - * @global $wp_super_cache_late_init; - * @global $wp_cache_anon_only; - * @global $wp_cache_not_logged_in; - * @global $wp_cache_clear_on_post_edit; - * @global $wp_cache_mobile_enabled; - * @global $wp_super_cache_debug; - * @global $cache_max_time; - * @global $wp_cache_refresh_single_only; - * @global $wp_cache_mfunc_enabled; - * @global $wp_supercache_304; - * @global $wp_cache_no_cache_for_get; - * @global $wp_cache_mutex_disabled; - * @global $cache_jetpack; - * @global $cache_domain_mapping; - * - * @return array All WP_Super_Cache callables. - */ - public static function get_wp_super_cache_globals() { - global $wp_cache_mod_rewrite; - global $cache_enabled; - global $super_cache_enabled; - global $ossdlcdn; - global $cache_rebuild_files; - global $wp_cache_mobile; - global $wp_super_cache_late_init; - global $wp_cache_anon_only; - global $wp_cache_not_logged_in; - global $wp_cache_clear_on_post_edit; - global $wp_cache_mobile_enabled; - global $wp_super_cache_debug; - global $cache_max_time; - global $wp_cache_refresh_single_only; - global $wp_cache_mfunc_enabled; - global $wp_supercache_304; - global $wp_cache_no_cache_for_get; - global $wp_cache_mutex_disabled; - global $cache_jetpack; - global $cache_domain_mapping; - - return array( - 'wp_cache_mod_rewrite' => $wp_cache_mod_rewrite, - 'cache_enabled' => $cache_enabled, - 'super_cache_enabled' => $super_cache_enabled, - 'ossdlcdn' => $ossdlcdn, - 'cache_rebuild_files' => $cache_rebuild_files, - 'wp_cache_mobile' => $wp_cache_mobile, - 'wp_super_cache_late_init' => $wp_super_cache_late_init, - 'wp_cache_anon_only' => $wp_cache_anon_only, - 'wp_cache_not_logged_in' => $wp_cache_not_logged_in, - 'wp_cache_clear_on_post_edit' => $wp_cache_clear_on_post_edit, - 'wp_cache_mobile_enabled' => $wp_cache_mobile_enabled, - 'wp_super_cache_debug' => $wp_super_cache_debug, - 'cache_max_time' => $cache_max_time, - 'wp_cache_refresh_single_only' => $wp_cache_refresh_single_only, - 'wp_cache_mfunc_enabled' => $wp_cache_mfunc_enabled, - 'wp_supercache_304' => $wp_supercache_304, - 'wp_cache_no_cache_for_get' => $wp_cache_no_cache_for_get, - 'wp_cache_mutex_disabled' => $wp_cache_mutex_disabled, - 'cache_jetpack' => $cache_jetpack, - 'cache_domain_mapping' => $cache_domain_mapping, - ); - } - - /** - * Add WP_Super_Cache constants to the constants whitelist. - * - * @param array $list Existing constants whitelist. - * @return array Updated constants whitelist. - */ - public function add_wp_super_cache_constants_whitelist( $list ) { - return array_merge( $list, self::$wp_super_cache_constants ); - } - - /** - * Add WP_Super_Cache callables to the callables whitelist. - * - * @param array $list Existing callables whitelist. - * @return array Updated callables whitelist. - */ - public function add_wp_super_cache_callable_whitelist( $list ) { - return array_merge( $list, self::$wp_super_cache_callables ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php deleted file mode 100644 index c880a4ee..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php +++ /dev/null @@ -1,209 +0,0 @@ -build_filter_statement( $range_from, $range_to ); - - $query = " - SELECT - DISTINCT {$this->table}.{$this->range_field} - FROM - {$this->table} - JOIN {$wpdb->usermeta} as um_table ON um_table.user_id = {$this->table}.ID - WHERE - {$range_filter_statement} - AND um_table.meta_key = '{$wpdb->prefix}user_level' - AND um_table.meta_value > 0 - "; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $user_ids = $wpdb->get_col( $query ); - - // Chunk the array down to make sure we don't overload the database with queries that are too large. - $chunked_user_ids = array_chunk( $user_ids, 500 ); - - $checksum_entries = array(); - - foreach ( $chunked_user_ids as $user_ids_chunk ) { - $user_objects = $this->get_user_objects_by_ids( $user_ids_chunk ); - - foreach ( $user_objects as $user_object ) { - // expand and sanitize desired meta based on WP.com logic. - $user_object = $this->expand_and_sanitize_user_meta( $user_object ); - - // Generate checksum entry based on the serialized value if not empty. - $checksum_entry = 0; - if ( ! empty( $user_object->roles ) ) { - $checksum_entry = crc32( implode( '#', array( $this->salt, 'roles', maybe_serialize( $user_object->roles ) ) ) ); - } - - // Meta only persisted if user is connected to WP.com. - if ( ( new Manager( 'jetpack' ) )->is_user_connected( $user_object->ID ) ) { - if ( ! empty( $user_object->allcaps ) ) { - $checksum_entry += crc32( - implode( - '#', - array( - $this->salt, - 'capabilities', - maybe_serialize( $user_object->allcaps ), - ) - ) - ); - } - // Explicitly check that locale is not same as site locale. - if ( ! empty( $user_object->locale ) && get_locale() !== $user_object->locale ) { - $checksum_entry += crc32( - implode( - '#', - array( - $this->salt, - 'locale', - maybe_serialize( $user_object->locale ), - ) - ) - ); - } - if ( ! empty( $user_object->allowed_mime_types ) ) { - $checksum_entry += crc32( - implode( - '#', - array( - $this->salt, - 'allowed_mime_types', - maybe_serialize( $user_object->allowed_mime_types ), - ) - ) - ); - } - } - - $checksum_entries[ $user_object->ID ] = '' . $checksum_entry; - } - } - - // Non-granular results need only to sum the different entries. - if ( ! $granular_result ) { - $checksum_sum = 0; - foreach ( $checksum_entries as $entry ) { - $checksum_sum += intval( $entry ); - } - - if ( $simple_return_value ) { - return '' . $checksum_sum; - } - - return array( - 'range' => $range_from . '-' . $range_to, - 'checksum' => '' . $checksum_sum, - ); - - } - - // Granular results. - $response = $checksum_entries; - - // Sort the return value for easier comparisons and code flows further down the line. - ksort( $response ); - - return $response; - } - - /** - * Expand the User Object with additional meta santized by WP.com logic. - * - * @param mixed $user_object User Object from WP_User_Query. - * - * @return mixed $user_object expanded User Object. - */ - protected function expand_and_sanitize_user_meta( $user_object ) { - $user_module = Modules::get_module( 'users' ); - '@phan-var \Automattic\Jetpack\Sync\Modules\Users $user_module'; - // Expand User Objects based on Sync logic. - $user_object = $user_module->expand_user( $user_object ); - - // Sanitize location. - if ( ! empty( $user_object->locale ) ) { - $user_object->locale = wp_strip_all_tags( $user_object->locale, true ); - } - - // Sanitize allcaps. - if ( ! empty( $user_object->allcaps ) ) { - $user_object->allcaps = array_map( - function ( $cap ) { - return (bool) $cap; - }, - $user_object->allcaps - ); - } - - // Sanitize allowed_mime_types. - $allowed_mime_types = $user_object->allowed_mime_types; - foreach ( $allowed_mime_types as $allowed_mime_type_short => $allowed_mime_type_long ) { - $allowed_mime_type_short = wp_strip_all_tags( (string) $allowed_mime_type_short, true ); - $allowed_mime_type_long = wp_strip_all_tags( (string) $allowed_mime_type_long, true ); - $allowed_mime_types[ $allowed_mime_type_short ] = $allowed_mime_type_long; - } - $user_object->allowed_mime_types = $allowed_mime_types; - - // Sanitize roles. - if ( is_array( $user_object->roles ) ) { - $user_object->roles = array_map( 'sanitize_text_field', $user_object->roles ); - } - return $user_object; - } - - /** - * Gets a list of `WP_User` objects by their IDs - * - * @param array $ids List of IDs to fetch. - * - * @return array - */ - protected function get_user_objects_by_ids( $ids ) { - $user_query = new WP_User_Query( array( 'include' => $ids ) ); - - return $user_query->get_results(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php deleted file mode 100644 index c36b0e3d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php +++ /dev/null @@ -1,185 +0,0 @@ -prepare( '%s', $this->salt ); - - // Prepare the compound key. - $key_fields = array(); - - // Prefix the fields with the table name, to avoid clashes in queries with sub-queries (e.g. meta tables). - foreach ( $this->key_fields as $field ) { - $key_fields[] = $this->table . '.' . $field; - } - - $key_fields = implode( ',', $key_fields ); - - // Prepare the checksum fields. - $checksum_fields = array(); - // Prefix the fields with the table name, to avoid clashes in queries with sub-queries (e.g. meta tables). - foreach ( $this->checksum_fields as $field ) { - $checksum_fields[] = $this->table . '.' . $field; - } - // Apply latin1 conversion if enabled. - if ( $this->perform_text_conversion ) { - // Convert text fields to allow for encoding discrepancies as WP.com is latin1. - foreach ( $this->checksum_text_fields as $field ) { - $checksum_fields[] = 'CONVERT(' . $this->table . '.' . $field . ' using latin1 )'; - } - } else { - // Conversion disabled, default to table prefixing. - foreach ( $this->checksum_text_fields as $field ) { - $checksum_fields[] = $this->table . '.' . $field; - } - } - - $checksum_fields_string = implode( ',', array_merge( $checksum_fields, array( $salt ) ) ); - - $additional_fields = ''; - if ( $granular_result ) { - // TODO uniq the fields as sometimes(most) range_index is the key and there's no need to select the same field twice. - $additional_fields = " - {$this->table}.{$this->range_field} as range_index, - {$key_fields}, - "; - } - - $filter_stamenet = $this->build_filter_statement( $range_from, $range_to, $filter_values ); - - // usermeta join to limit on user_level. - $join_statement = "JOIN {$wpdb->usermeta} as um_table ON um_table.user_id = {$this->table}.ID"; - - $query = " - SELECT - {$additional_fields} - SUM( - CRC32( - CONCAT_WS( '#', {$salt}, {$checksum_fields_string} ) - ) - ) AS checksum - FROM - {$this->table} - {$join_statement} - WHERE - {$filter_stamenet} - AND um_table.meta_key = '{$wpdb->prefix}user_level' - AND um_table.meta_value > 0 - "; - - /** - * We need the GROUP BY only for compound keys. - */ - if ( $granular_result ) { - $query .= " - GROUP BY {$key_fields} - LIMIT 9999999 - "; - } - - return $query; - } - - /** - * Obtain the min-max values (edges) of the range. - * - * @param int|null $range_from The start of the range. - * @param int|null $range_to The end of the range. - * @param int|null $limit How many values to return. - * - * @return array|object|void - * @throws Exception Throws an exception if validation fails on the internal function calls. - */ - public function get_range_edges( $range_from = null, $range_to = null, $limit = null ) { - global $wpdb; - - $this->validate_fields( array( $this->range_field ) ); - - // `trim()` to make sure we don't add the statement if it's empty. - $filters = trim( $this->build_filter_statement( $range_from, $range_to ) ); - - $filter_statement = ''; - if ( ! empty( $filters ) ) { - $filter_statement = " - JOIN {$wpdb->usermeta} as um_table ON um_table.user_id = {$this->table}.ID - WHERE - {$filters} - AND um_table.meta_key = '{$wpdb->prefix}user_level' - AND um_table.meta_value > 0 - "; - } - - $query = " - SELECT - MIN({$this->range_field}) as min_range, - MAX({$this->range_field}) as max_range, - COUNT( {$this->range_field} ) as item_count - FROM - "; - - /** - * If `$limit` is not specified, we can directly use the table. - */ - if ( ! $limit ) { - $query .= " - {$this->table} - {$filter_statement} - "; - } else { - /** - * If there is `$limit` specified, we can't directly use `MIN/MAX()` as they don't work with `LIMIT`. - * That's why we will alter the query for this case. - */ - $limit = intval( $limit ); - - $query .= " - ( - SELECT - {$this->range_field} - FROM - {$this->table} - {$filter_statement} - ORDER BY - {$this->range_field} ASC - LIMIT {$limit} - ) as ids_query - "; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $result = $wpdb->get_row( $query, ARRAY_A ); - - if ( ! $result || ! is_array( $result ) ) { - throw new Exception( 'Unable to get range edges' ); - } - - return $result; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php deleted file mode 100644 index 3118c6a2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php +++ /dev/null @@ -1,979 +0,0 @@ -salt = $salt; - - $this->default_tables = static::get_default_tables(); - - $this->perform_text_conversion = $perform_text_conversion; - - // TODO change filters to allow the array format. - // TODO add get_fields or similar method to get things out of the table. - // TODO extract this configuration in a better way, still make it work with `$wpdb` names. - // TODO take over the replicastore functions and move them over to this class. - // TODO make the API work. - - $this->allowed_tables = apply_filters( 'jetpack_sync_checksum_allowed_tables', $this->default_tables ); - - $this->table = $this->validate_table_name( $table ); - $this->table_configuration = $this->allowed_tables[ $table ]; - - $this->prepare_fields( $this->table_configuration ); - - $this->prepare_additional_columns( $additional_columns ); - - // Run any callbacks to check if a table is enabled or not. - if ( - is_callable( $this->is_table_enabled_callback ) - && ! call_user_func( $this->is_table_enabled_callback, $table ) - ) { - throw new Exception( "Unable to use table name: $table" ); - } - } - - /** - * Get Default Table configurations. - * - * @return array - */ - protected static function get_default_tables() { - global $wpdb; - - return array( - 'posts' => array( - 'table' => $wpdb->posts, - 'range_field' => 'ID', - 'key_fields' => array( 'ID' ), - 'checksum_fields' => array( 'post_modified_gmt' ), - 'filter_values' => Sync\Settings::get_disallowed_post_types_structured(), - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'posts' ); - }, - ), - 'postmeta' => array( - 'table' => $wpdb->postmeta, - 'range_field' => 'post_id', - 'key_fields' => array( 'post_id', 'meta_key' ), - 'checksum_text_fields' => array( 'meta_key', 'meta_value' ), - 'filter_values' => Sync\Settings::get_allowed_post_meta_structured(), - 'parent_table' => 'posts', - 'parent_join_field' => 'ID', - 'table_join_field' => 'post_id', - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'posts' ); - }, - ), - 'comments' => array( - 'table' => $wpdb->comments, - 'range_field' => 'comment_ID', - 'key_fields' => array( 'comment_ID' ), - 'checksum_fields' => array( 'comment_date_gmt' ), - 'filter_values' => array( - 'comment_type' => array( - 'operator' => 'IN', - 'values' => apply_filters( - 'jetpack_sync_whitelisted_comment_types', - array( '', 'comment', 'trackback', 'pingback', 'review' ) - ), - ), - 'comment_approved' => array( - 'operator' => 'NOT IN', - 'values' => array( 'spam' ), - ), - ), - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'comments' ); - }, - ), - 'commentmeta' => array( - 'table' => $wpdb->commentmeta, - 'range_field' => 'comment_id', - 'key_fields' => array( 'comment_id', 'meta_key' ), - 'checksum_text_fields' => array( 'meta_key', 'meta_value' ), - 'filter_values' => Sync\Settings::get_allowed_comment_meta_structured(), - 'parent_table' => 'comments', - 'parent_join_field' => 'comment_ID', - 'table_join_field' => 'comment_id', - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'comments' ); - }, - ), - 'terms' => array( - 'table' => $wpdb->terms, - 'range_field' => 'term_id', - 'key_fields' => array( 'term_id' ), - 'checksum_fields' => array( 'term_id' ), - 'checksum_text_fields' => array( 'name', 'slug' ), - 'parent_table' => 'term_taxonomy', - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'terms' ); - }, - ), - 'termmeta' => array( - 'table' => $wpdb->termmeta, - 'range_field' => 'term_id', - 'key_fields' => array( 'term_id', 'meta_key' ), - 'checksum_text_fields' => array( 'meta_key', 'meta_value' ), - 'parent_table' => 'term_taxonomy', - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'terms' ); - }, - ), - 'term_relationships' => array( - 'table' => $wpdb->term_relationships, - 'range_field' => 'object_id', - 'key_fields' => array( 'object_id' ), - 'checksum_fields' => array( 'object_id', 'term_taxonomy_id' ), - 'parent_table' => 'term_taxonomy', - 'parent_join_field' => 'term_taxonomy_id', - 'table_join_field' => 'term_taxonomy_id', - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'terms' ); - }, - ), - 'term_taxonomy' => array( - 'table' => $wpdb->term_taxonomy, - 'range_field' => 'term_taxonomy_id', - 'key_fields' => array( 'term_taxonomy_id' ), - 'checksum_fields' => array( 'term_taxonomy_id', 'term_id', 'parent' ), - 'checksum_text_fields' => array( 'taxonomy', 'description' ), - 'filter_values' => Sync\Settings::get_allowed_taxonomies_structured(), - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'terms' ); - }, - ), - 'links' => $wpdb->links, // TODO describe in the array format or add exceptions. - 'options' => $wpdb->options, // TODO describe in the array format or add exceptions. - 'woocommerce_order_items' => array( - 'table' => "{$wpdb->prefix}woocommerce_order_items", - 'range_field' => 'order_item_id', - 'key_fields' => array( 'order_item_id' ), - 'checksum_fields' => array( 'order_id' ), - 'checksum_text_fields' => array( 'order_item_name', 'order_item_type' ), - 'is_table_enabled_callback' => 'Automattic\Jetpack\Sync\Replicastore\Table_Checksum::enable_woocommerce_tables', - ), - 'woocommerce_order_itemmeta' => array( - 'table' => "{$wpdb->prefix}woocommerce_order_itemmeta", - 'range_field' => 'order_item_id', - 'key_fields' => array( 'order_item_id', 'meta_key' ), - 'checksum_text_fields' => array( 'meta_key', 'meta_value' ), - 'filter_values' => Sync\Settings::get_allowed_order_itemmeta_structured(), - 'parent_table' => 'woocommerce_order_items', - 'parent_join_field' => 'order_item_id', - 'table_join_field' => 'order_item_id', - 'is_table_enabled_callback' => 'Automattic\Jetpack\Sync\Replicastore\Table_Checksum::enable_woocommerce_tables', - ), - 'wc_orders' => array( - 'table' => "{$wpdb->prefix}wc_orders", - 'range_field' => 'id', - 'key_fields' => array( 'id' ), - 'checksum_fields' => array( 'date_updated_gmt', 'total_amount' ), - 'checksum_text_fields' => array( 'type', 'status' ), - 'filter_values' => array( - 'type' => array( - 'operator' => 'IN', - 'values' => WooCommerce_HPOS_Orders::get_order_types_to_sync( true ), - ), - 'status' => array( - 'operator' => 'IN', - 'values' => WooCommerce_HPOS_Orders::get_all_possible_order_status_keys(), - ), - ), - 'is_table_enabled_callback' => 'Automattic\Jetpack\Sync\Replicastore\Table_Checksum::enable_woocommerce_hpos_tables', - ), - 'wc_order_addresses' => array( - 'table' => "{$wpdb->prefix}wc_order_addresses", - 'range_field' => 'order_id', - 'key_fields' => array( 'order_id', 'address_type' ), - 'checksum_text_fields' => array( 'address_type' ), - 'parent_table' => 'wc_orders', - 'parent_join_field' => 'id', - 'table_join_field' => 'order_id', - 'filter_values' => array(), - 'is_table_enabled_callback' => 'Automattic\Jetpack\Sync\Replicastore\Table_Checksum::enable_woocommerce_hpos_tables', - ), - 'wc_order_operational_data' => array( - 'table' => "{$wpdb->prefix}wc_order_operational_data", - 'range_field' => 'order_id', - 'key_fields' => array( 'order_id' ), - 'checksum_fields' => array( 'date_paid_gmt', 'date_completed_gmt' ), - 'checksum_text_fields' => array( 'order_key' ), - 'parent_table' => 'wc_orders', - 'parent_join_field' => 'id', - 'table_join_field' => 'order_id', - 'filter_values' => array(), - 'is_table_enabled_callback' => 'Automattic\Jetpack\Sync\Replicastore\Table_Checksum::enable_woocommerce_hpos_tables', - ), - 'users' => array( - 'table' => $wpdb->users, - 'range_field' => 'ID', - 'key_fields' => array( 'ID' ), - 'checksum_text_fields' => array( 'user_login', 'user_nicename', 'user_email', 'user_url', 'user_registered', 'user_status', 'display_name' ), - 'filter_values' => array(), - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'users' ); - }, - ), - - /** - * Usermeta is a special table, as it needs to use a custom override flow, - * as the user roles, capabilities, locale, mime types can be filtered by plugins. - * This prevents us from doing a direct comparison in the database. - */ - 'usermeta' => array( - 'table' => $wpdb->users, - /** - * Range field points to ID, which in this case is the `WP_User` ID, - * since we're querying the whole WP_User objects, instead of meta entries in the DB. - */ - 'range_field' => 'ID', - 'key_fields' => array(), - 'checksum_fields' => array(), - 'is_table_enabled_callback' => function () { - return false !== Sync\Modules::get_module( 'users' ); - }, - ), - ); - } - - /** - * Get allowed table configurations. - * - * @return array - */ - public static function get_allowed_tables() { - return apply_filters( 'jetpack_sync_checksum_allowed_tables', static::get_default_tables() ); - } - - /** - * Prepare field params based off provided configuration. - * - * @param array $table_configuration The table configuration array. - */ - protected function prepare_fields( $table_configuration ) { - $this->key_fields = $table_configuration['key_fields']; - $this->range_field = $table_configuration['range_field']; - $this->checksum_fields = isset( $table_configuration['checksum_fields'] ) ? $table_configuration['checksum_fields'] : array(); - $this->checksum_text_fields = isset( $table_configuration['checksum_text_fields'] ) ? $table_configuration['checksum_text_fields'] : array(); - $this->filter_values = isset( $table_configuration['filter_values'] ) ? $table_configuration['filter_values'] : null; - $this->additional_filter_sql = ! empty( $table_configuration['filter_sql'] ) ? $table_configuration['filter_sql'] : ''; - $this->parent_table = isset( $table_configuration['parent_table'] ) ? $table_configuration['parent_table'] : null; - $this->parent_join_field = isset( $table_configuration['parent_join_field'] ) ? $table_configuration['parent_join_field'] : $table_configuration['range_field']; - $this->table_join_field = isset( $table_configuration['table_join_field'] ) ? $table_configuration['table_join_field'] : $table_configuration['range_field']; - $this->is_table_enabled_callback = isset( $table_configuration['is_table_enabled_callback'] ) ? $table_configuration['is_table_enabled_callback'] : false; - } - - /** - * Verify provided table name is valid for checksum processing. - * - * @param string $table Table name to validate. - * - * @return mixed|string - * @throws Exception Throw an exception on validation failure. - */ - protected function validate_table_name( $table ) { - if ( empty( $table ) ) { - throw new Exception( 'Invalid table name: empty' ); - } - - if ( ! array_key_exists( $table, $this->allowed_tables ) ) { - throw new Exception( "Invalid table name: $table not allowed" ); - } - - return $this->allowed_tables[ $table ]['table']; - } - - /** - * Verify provided fields are proper names. - * - * @param array $fields Array of field names to validate. - * - * @throws Exception Throw an exception on failure to validate. - */ - protected function validate_fields( $fields ) { - foreach ( $fields as $field ) { - if ( ! preg_match( '/^[0-9,a-z,A-Z$_]+$/i', $field ) ) { - throw new Exception( "Invalid field name: $field is not allowed" ); - } - - // TODO other verifications of the field names. - } - } - - /** - * Verify the fields exist in the table. - * - * @param array $fields Array of fields to validate. - * - * @return bool - * @throws Exception Throw an exception on failure to validate. - */ - protected function validate_fields_against_table( $fields ) { - global $wpdb; - - $valid_fields = array(); - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $result = $wpdb->get_results( "SHOW COLUMNS FROM {$this->table}", ARRAY_A ); - - foreach ( $result as $result_row ) { - $valid_fields[] = $result_row['Field']; - } - - // Check if the fields are actually contained in the table. - foreach ( $fields as $field_to_check ) { - if ( ! in_array( $field_to_check, $valid_fields, true ) ) { - throw new Exception( "Invalid field name: field '{$field_to_check}' doesn't exist in table {$this->table}" ); - } - } - - return true; - } - - /** - * Verify the configured fields. - * - * @throws Exception Throw an exception on failure to validate in the internal functions. - */ - protected function validate_input() { - $fields = array_merge( array( $this->range_field ), $this->key_fields, $this->checksum_fields, $this->checksum_text_fields ); - - $this->validate_fields( $fields ); - $this->validate_fields_against_table( $fields ); - } - - /** - * Prepare filter values as SQL statements to be added to the other filters. - * - * @param array $filter_values The filter values array. - * @param string $table_prefix If the values are going to be used in a sub-query, add a prefix with the table alias. - * - * @return array|null - */ - protected function prepare_filter_values_as_sql( $filter_values = array(), $table_prefix = '' ) { - global $wpdb; - - if ( ! is_array( $filter_values ) ) { - return null; - } - - $result = array(); - - foreach ( $filter_values as $field => $filter ) { - $key = ( ! empty( $table_prefix ) ? $table_prefix : $this->table ) . '.' . $field; - - switch ( $filter['operator'] ) { - case 'IN': - case 'NOT IN': - $filter_values_count = is_countable( $filter['values'] ) ? count( $filter['values'] ) : 0; - $values_placeholders = implode( ',', array_fill( 0, $filter_values_count, '%s' ) ); - $statement = "{$key} {$filter['operator']} ( $values_placeholders )"; - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $prepared_statement = $wpdb->prepare( $statement, $filter['values'] ); - - $result[] = $prepared_statement; - break; - } - } - - return $result; - } - - /** - * Build the filter query baased off range fields and values and the additional sql. - * - * @param int|null $range_from Start of the range. - * @param int|null $range_to End of the range. - * @param array|null $filter_values Additional filter values. Not used at the moment. - * @param string $table_prefix Table name to be prefixed to the columns. Used in sub-queries where columns can clash. - * - * @return string - */ - public function build_filter_statement( $range_from = null, $range_to = null, $filter_values = null, $table_prefix = '' ) { - global $wpdb; - - // If there is a field prefix that we want to use with table aliases. - $parent_prefix = ( ! empty( $table_prefix ) ? $table_prefix : $this->table ) . '.'; - - /** - * Prepare the ranges. - */ - - $filter_array = array( '1 = 1' ); - if ( null !== $range_from ) { - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $filter_array[] = $wpdb->prepare( "{$parent_prefix}{$this->range_field} >= %d", array( intval( $range_from ) ) ); - } - if ( null !== $range_to ) { - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $filter_array[] = $wpdb->prepare( "{$parent_prefix}{$this->range_field} <= %d", array( intval( $range_to ) ) ); - } - - /** - * End prepare the ranges. - */ - - /** - * Prepare data filters. - */ - - // Default filters. - if ( $this->filter_values ) { - $prepared_values_statements = $this->prepare_filter_values_as_sql( $this->filter_values, $table_prefix ); - if ( $prepared_values_statements ) { - $filter_array = array_merge( $filter_array, $prepared_values_statements ); - } - } - - // Additional filters. - if ( ! empty( $filter_values ) ) { - // Prepare filtering. - $prepared_values_statements = $this->prepare_filter_values_as_sql( $filter_values, $table_prefix ); - if ( $prepared_values_statements ) { - $filter_array = array_merge( $filter_array, $prepared_values_statements ); - } - } - - // Add any additional filters via direct SQL statement. - // Currently used only because we haven't converted all filtering to happen via `filter_values`. - // This SQL is NOT prefixed and column clashes can occur when used in sub-queries. - if ( $this->additional_filter_sql ) { - $filter_array[] = $this->additional_filter_sql; - } - - /** - * End prepare data filters. - */ - return implode( ' AND ', $filter_array ); - } - - /** - * Returns the checksum query. All validation of fields and configurations are expected to occur prior to usage. - * - * @param int|null $range_from The start of the range. - * @param int|null $range_to The end of the range. - * @param array|null $filter_values Additional filter values. Not used at the moment. - * @param bool $granular_result If the function should return a granular result. - * - * @return string - * - * @throws Exception Throws an exception if validation fails in the internal function calls. - */ - protected function build_checksum_query( $range_from = null, $range_to = null, $filter_values = null, $granular_result = false ) { - global $wpdb; - - // Escape the salt. - $salt = $wpdb->prepare( '%s', $this->salt ); - - // Prepare the compound key. - $key_fields = array(); - - // Prefix the fields with the table name, to avoid clashes in queries with sub-queries (e.g. meta tables). - foreach ( $this->key_fields as $field ) { - $key_fields[] = $this->table . '.' . $field; - } - - $key_fields = implode( ',', $key_fields ); - - // Prepare the checksum fields. - $checksum_fields = array(); - // Prefix the fields with the table name, to avoid clashes in queries with sub-queries (e.g. meta tables). - foreach ( $this->checksum_fields as $field ) { - $checksum_fields[] = $this->table . '.' . $field; - } - // Apply latin1 conversion if enabled. - if ( $this->perform_text_conversion ) { - // Convert text fields to allow for encoding discrepancies as WP.com is latin1. - foreach ( $this->checksum_text_fields as $field ) { - $checksum_fields[] = 'CONVERT(' . $this->table . '.' . $field . ' using latin1 )'; - } - } else { - // Conversion disabled, default to table prefixing. - foreach ( $this->checksum_text_fields as $field ) { - $checksum_fields[] = $this->table . '.' . $field; - } - } - - $checksum_fields_string = implode( ',', array_merge( $checksum_fields, array( $salt ) ) ); - - $additional_fields = ''; - if ( $granular_result ) { - // TODO uniq the fields as sometimes(most) range_index is the key and there's no need to select the same field twice. - $additional_fields = " - {$this->table}.{$this->range_field} as range_index, - {$key_fields}, - "; - } - - $filter_stamenet = $this->build_filter_statement( $range_from, $range_to, $filter_values ); - - $join_statement = ''; - if ( $this->parent_table ) { - $parent_table_obj = new Table_Checksum( $this->parent_table ); - $parent_filter_query = $parent_table_obj->build_filter_statement( null, null, null, 'parent_table' ); - - // It is possible to have the GROUP By cause multiple rows to be returned for the same row for term_taxonomy. - // To get distinct entries we use a correlatd subquery back on the parent table using the primary key. - $additional_unique_clause = ''; - if ( 'term_taxonomy' === $this->parent_table ) { - $additional_unique_clause = " - AND parent_table.{$parent_table_obj->range_field} = ( - SELECT min( parent_table_cs.{$parent_table_obj->range_field} ) - FROM {$parent_table_obj->table} as parent_table_cs - WHERE parent_table_cs.{$this->parent_join_field} = {$this->table}.{$this->table_join_field} - ) - "; - } - - $join_statement = " - INNER JOIN {$parent_table_obj->table} as parent_table - ON ( - {$this->table}.{$this->table_join_field} = parent_table.{$this->parent_join_field} - AND {$parent_filter_query} - $additional_unique_clause - ) - "; - } - - $query = " - SELECT - {$additional_fields} - SUM( - CRC32( - CONCAT_WS( '#', {$salt}, {$checksum_fields_string} ) - ) - ) AS checksum - FROM - {$this->table} - {$join_statement} - WHERE - {$filter_stamenet} - "; - - /** - * We need the GROUP BY only for compound keys. - */ - if ( $granular_result ) { - $query .= " - GROUP BY {$key_fields} - LIMIT 9999999 - "; - } - - return $query; - } - - /** - * Obtain the min-max values (edges) of the range. - * - * @param int|null $range_from The start of the range. - * @param int|null $range_to The end of the range. - * @param int|null $limit How many values to return. - * - * @return array|object|void - * @throws Exception Throws an exception if validation fails on the internal function calls. - */ - public function get_range_edges( $range_from = null, $range_to = null, $limit = null ) { - global $wpdb; - - $this->validate_fields( array( $this->range_field ) ); - - // Performance :: When getting the postmeta range we do not want to filter by the whitelist. - // The reason for this is that it leads to a non-performant query that can timeout. - // Instead lets get the range based on posts regardless of meta. - $filter_values = $this->filter_values; - if ( $wpdb->postmeta === $this->table ) { - $this->filter_values = null; - } - - // `trim()` to make sure we don't add the statement if it's empty. - $filters = trim( $this->build_filter_statement( $range_from, $range_to ) ); - - // Reset Post meta filter. - if ( $wpdb->postmeta === $this->table ) { - $this->filter_values = $filter_values; - } - - $filter_statement = ''; - if ( ! empty( $filters ) ) { - $filter_statement = " - WHERE - {$filters} - "; - } - - // Only make the distinct count when we know there can be multiple entries for the range column. - $distinct_count = ''; - if ( count( $this->key_fields ) > 1 || $wpdb->terms === $this->table || $wpdb->term_relationships === $this->table ) { - $distinct_count = 'DISTINCT'; - } - - $query = " - SELECT - MIN({$this->range_field}) as min_range, - MAX({$this->range_field}) as max_range, - COUNT( {$distinct_count} {$this->range_field}) as item_count - FROM - "; - - /** - * If `$limit` is not specified, we can directly use the table. - */ - if ( ! $limit ) { - $query .= " - {$this->table} - {$filter_statement} - "; - } else { - /** - * If there is `$limit` specified, we can't directly use `MIN/MAX()` as they don't work with `LIMIT`. - * That's why we will alter the query for this case. - */ - $limit = intval( $limit ); - - $query .= " - ( - SELECT - {$distinct_count} {$this->range_field} - FROM - {$this->table} - {$filter_statement} - ORDER BY - {$this->range_field} ASC - LIMIT {$limit} - ) as ids_query - "; - } - - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $result = $wpdb->get_row( $query, ARRAY_A ); - - if ( ! $result || ! is_array( $result ) ) { - throw new Exception( 'Unable to get range edges' ); - } - - return $result; - } - - /** - * Update the results to have key/checksum format. - * - * @param array $results Prepare the results for output of granular results. - */ - protected function prepare_results_for_output( &$results ) { - // get the compound key. - // only return range and compound key for granular results. - - $return_value = array(); - - foreach ( $results as &$result ) { - // Working on reference to save memory here. - - $key = array(); - foreach ( $this->key_fields as $field ) { - $key[] = $result[ $field ]; - } - - $return_value[ implode( '-', $key ) ] = $result['checksum']; - } - - return $return_value; - } - - /** - * Calculate the checksum based on provided range and filters. - * - * @param int|null $range_from The start of the range. - * @param int|null $range_to The end of the range. - * @param array|null $filter_values Additional filter values. Not used at the moment. - * @param bool $granular_result If the returned result should be granular or only the checksum. - * @param bool $simple_return_value If we want to use a simple return value for non-granular results (return only the checksum, without wrappers). - * - * @return array|mixed|object|WP_Error|null - */ - public function calculate_checksum( $range_from = null, $range_to = null, $filter_values = null, $granular_result = false, $simple_return_value = true ) { - - if ( ! Sync\Settings::is_checksum_enabled() ) { - return new WP_Error( 'checksum_disabled', 'Checksums are currently disabled.' ); - } - - try { - $this->validate_input(); - } catch ( Exception $ex ) { - return new WP_Error( 'invalid_input', $ex->getMessage() ); - } - - $query = $this->build_checksum_query( $range_from, $range_to, $filter_values, $granular_result ); - - global $wpdb; - - if ( ! $granular_result ) { - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $result = $wpdb->get_row( $query, ARRAY_A ); - - if ( ! is_array( $result ) ) { - return new WP_Error( 'invalid_query', "Result wasn't an array" ); - } - - if ( $simple_return_value ) { - return $result['checksum']; - } - - return array( - 'range' => $range_from . '-' . $range_to, - 'checksum' => $result['checksum'], - ); - } else { - // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $result = $wpdb->get_results( $query, ARRAY_A ); - return $this->prepare_results_for_output( $result ); - } - } - - /** - * Make sure the WooCommerce tables should be enabled for Checksum/Fix. - * - * @return bool - */ - public static function enable_woocommerce_tables() { - /** - * On WordPress.com, we can't directly check if the site has support for WooCommerce. - * Having the option to override the functionality here helps with syncing WooCommerce tables. - * - * @since 10.1 - * - * @param bool If we should we force-enable WooCommerce tables support. - */ - $force_woocommerce_support = apply_filters( 'jetpack_table_checksum_force_enable_woocommerce', false ); - - // If we're forcing WooCommerce tables support, there's no need to check further. - // This is used on WordPress.com. - if ( $force_woocommerce_support ) { - return true; - } - - // If the 'woocommerce' module is enabled, this means that WooCommerce class exists. - return false !== Sync\Modules::get_module( 'woocommerce' ); - } - - /** - * Make sure the WooCommerce HPOS tables should be enabled for Checksum/Fix. - * - * @see Automattic\Jetpack\SyncActions::initialize_woocommerce - * - * @since 3.3.0 - * - * @return bool - */ - public static function enable_woocommerce_hpos_tables() { - /** - * On WordPress.com, we can't directly check if the site has support for WooCommerce HPOS tables. - * Having the option to override the functionality here helps with syncing WooCommerce HPOS tables. - * - * @since 3.3.0 - * - * @param bool If we should we force-enable WooCommerce HPOS tables support. - */ - $force_woocommerce_hpos_support = apply_filters( 'jetpack_table_checksum_force_enable_woocommerce_hpos', false ); - - // If we're forcing WooCommerce HPOS tables support, there's no need to check further. - // This is used on WordPress.com. - if ( $force_woocommerce_hpos_support ) { - return true; - } - - // If the 'woocommerce_hpos_orders' module is enabled, this means that WooCommerce class exists - // and HPOS is enabled too. - return false !== Sync\Modules::get_module( 'woocommerce_hpos_orders' ); - } - - /** - * Prepare and append custom columns to the list of columns that we run the checksum on. - * - * @param string|array $additional_columns List of additional columns. - * - * @return void - * @throws Exception When field validation fails. - */ - protected function prepare_additional_columns( $additional_columns ) { - /** - * No need to do anything if the parameter is not provided or empty. - */ - if ( empty( $additional_columns ) ) { - return; - } - - if ( ! is_array( $additional_columns ) ) { - if ( ! is_string( $additional_columns ) ) { - throw new Exception( 'Invalid value for additional fields' ); - } - - $additional_columns = explode( ',', $additional_columns ); - } - - /** - * Validate the fields. If any don't conform to the required norms, we will throw an exception and - * halt code here. - */ - $this->validate_fields( $additional_columns ); - - /** - * Assign the fields to the checksum_fields to be used in the checksum later. - * - * We're adding the fields to the rest of the `checksum_fields`, so we don't need - * to implement extra logic just for the additional fields. - */ - $this->checksum_fields = array_unique( - array_merge( - $this->checksum_fields, - $additional_columns - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-options.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-options.php deleted file mode 100644 index 865d6b3b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-options.php +++ /dev/null @@ -1,291 +0,0 @@ -queue_id = $queue_id; - } - - /** - * Insert an item in the queue. - * - * @param string $item_id The item ID. - * @param string $item Serialized item data. - * - * @return bool If the item was added. - */ - public function insert_item( $item_id, $item ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - $rows_added = $wpdb->query( - $wpdb->prepare( - "INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES (%s, %s,%s)", - $item_id, - $item, - 'no' - ) - ); - - return ( 0 !== $rows_added ); - } - - /** - * Fetch items from the queue. - * - * @param int|null $item_count How many items to fetch from the queue. - * The parameter is null-able, if no limit on the amount of items. - * - * @return array|object|\stdClass[]|null - */ - public function fetch_items( $item_count ) { - global $wpdb; - - // TODO make it more simple for the $item_count - if ( $item_count ) { - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - $items = $wpdb->get_results( - $wpdb->prepare( - "SELECT option_name AS id, option_value AS value FROM $wpdb->options WHERE option_name LIKE %s ORDER BY option_name ASC LIMIT %d", - "jpsq_{$this->queue_id}-%", - $item_count - ), - OBJECT - ); - } else { - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - $items = $wpdb->get_results( - $wpdb->prepare( - "SELECT option_name AS id, option_value AS value FROM $wpdb->options WHERE option_name LIKE %s ORDER BY option_name ASC", - "jpsq_{$this->queue_id}-%" - ), - OBJECT - ); - } - - return $items; - } - - /** - * Fetches items with specific IDs from the Queue. - * - * @param array $items_ids Items IDs to fetch from the queue. - * - * @return \stdClass[]|null - */ - public function fetch_items_by_ids( $items_ids ) { - global $wpdb; - - // return early if $items_ids is empty or not an array. - if ( empty( $items_ids ) || ! is_array( $items_ids ) ) { - return array(); - } - - $ids_placeholders = implode( ', ', array_fill( 0, count( $items_ids ), '%s' ) ); - - $query_with_placeholders = "SELECT option_name AS id, option_value AS value - FROM $wpdb->options - WHERE option_name IN ( $ids_placeholders )"; - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - $items = $wpdb->get_results( - $wpdb->prepare( - $query_with_placeholders, // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $items_ids - ), - OBJECT - ); - - return $items; - } - - /** - * Clear out the queue. - * - * @return bool|int|\mysqli_result|resource|null - */ - public function clear_queue() { - global $wpdb; - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - return $wpdb->query( - $wpdb->prepare( - "DELETE FROM $wpdb->options WHERE option_name LIKE %s", - "jpsq_{$this->queue_id}-%" - ) - ); - } - - /** - * Check how many items are in the queue. - * - * @return int - */ - public function get_item_count() { - global $wpdb; - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - return (int) $wpdb->get_var( - $wpdb->prepare( - "SELECT count(*) FROM $wpdb->options WHERE option_name LIKE %s", - "jpsq_{$this->queue_id}-%" - ) - ); - } - - /** - * Return the lag amount for the queue. - * - * @param float|int|null $now A timestamp to use as starting point when calculating the lag. - * - * @return float|int The lag amount. - */ - public function get_lag( $now = null ) { - global $wpdb; - - // TODO replace with peek and a flag to fetch only the name. - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - $first_item_name = $wpdb->get_var( - $wpdb->prepare( - "SELECT option_name FROM $wpdb->options WHERE option_name LIKE %s ORDER BY option_name ASC LIMIT 1", - "jpsq_{$this->queue_id}-%" - ) - ); - - if ( ! $first_item_name ) { - return 0; - } - - if ( null === $now ) { - $now = microtime( true ); - } - - // Break apart the item name to get the timestamp. - $matches = null; - if ( preg_match( '/^jpsq_' . $this->queue_id . '-(\d+\.\d+)-/', $first_item_name, $matches ) ) { - return $now - (float) $matches[1]; - } else { - return 0; - } - } - - /** - * Add multiple items to the queue at once. - * - * @param array $items Array of items to add. - * @param string $id_prefix Prefix to use for all the items. - * - * @return bool|int|\mysqli_result|resource|null - */ - public function add_all( $items, $id_prefix ) { - global $wpdb; - - $query = "INSERT INTO $wpdb->options (option_name, option_value, autoload) VALUES "; - - $rows = array(); - $count_items = count( $items ); - for ( $i = 0; $i < $count_items; ++$i ) { - // skip empty items. - if ( empty( $items[ $i ] ) ) { - continue; - } - try { - $option_name = esc_sql( $id_prefix . '-' . $i ); - $option_value = esc_sql( serialize( $items[ $i ] ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - $rows[] = "('$option_name', '$option_value', 'no')"; - } catch ( \Exception $e ) { - // Item cannot be serialized so skip. - continue; - } - } - - $rows_added = $wpdb->query( $query . implode( ',', $rows ) ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared, WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching - - return $rows_added; - } - - /** - * Return $max_count items from the queue, including their value string length. - * - * @param int $max_count How many items to fetch from the queue. - * - * @return object[]|null - */ - public function get_items_ids_with_size( $max_count ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - return $wpdb->get_results( - $wpdb->prepare( - "SELECT option_name AS id, LENGTH(option_value) AS value_size FROM $wpdb->options WHERE option_name LIKE %s ORDER BY option_name ASC LIMIT %d", - "jpsq_{$this->queue_id}-%", - $max_count - ), - OBJECT - ); - } - - /** - * Delete items with specific IDs from the queue. - * - * @param array $ids IDs of the items to remove from the queue. - * - * @return bool|int|\mysqli_result|resource|null - */ - public function delete_items_by_ids( $ids ) { - global $wpdb; - - if ( ! is_array( $ids ) || empty( $ids ) ) { - return false; - } - - // TODO check if it's working properly - no need to delete all options in the table if the params are not right - $ids_placeholders = implode( ', ', array_fill( 0, count( $ids ), '%s' ) ); - - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery - return $wpdb->query( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$ids_placeholders`, as we're preparing them above and are a dynamic count. - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.PreparedSQLPlaceholders.UnfinishedPrepare - "DELETE FROM {$wpdb->options} WHERE option_name IN ( $ids_placeholders )", - $ids - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-table.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-table.php deleted file mode 100644 index 7fd459b9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-table.php +++ /dev/null @@ -1,691 +0,0 @@ -queue_id = $queue_id; - - // Initialize the `table_name` property with the correct prefix for easier usage in the class. - $this->table_name = $wpdb->prefix . $this->table_name_no_prefix; - } - - /** - * Creates the new table and updates the options to work with - * the new table if it was created successfully. - * - * @return void - */ - protected function create_table() { - global $wpdb; - - require_once ABSPATH . '/wp-admin/includes/upgrade.php'; - - $charset_collate = $wpdb->get_charset_collate(); - - $table_definition = "CREATE TABLE {$this->table_name} ( - `ID` bigint(20) NOT NULL AUTO_INCREMENT, - `queue_id` varchar(50) NOT NULL, - `event_id` varchar(100) NOT NULL, - `event_payload` longtext NOT NULL, - `timestamp` timestamp NOT NULL DEFAULT current_timestamp(), - PRIMARY KEY (`ID`), - KEY `event_id` (`event_id`), - KEY `queue_id` (`queue_id`), - KEY `queue_id_event_id` (queue_id, event_id), - KEY `timestamp` (`timestamp`) - ) $charset_collate;"; - - /** - * The function dbDelta will only return the differences. If the table exists, the result will be empty, - * so let's run a check afterward to see if the table exists and is healthy. - */ - \dbDelta( $table_definition ); - } - - /** - * Check if the Custom table actually exists. - * - * @return bool - */ - protected function custom_table_exists() { - global $wpdb; - - // Check if the table exists - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $result = $wpdb->get_row( - $wpdb->prepare( 'SHOW TABLES LIKE %s', $this->table_name ), - ARRAY_N - ); - - if ( empty( $result ) || count( $result ) !== 1 || $result[0] !== $this->table_name ) { - return false; - } - - return true; - } - /** - * Check if the table is healthy, and we can read and write from/to it. - * - * @return true|\WP_Error If the custom table is available, and we can read and write from/to it. - */ - protected function is_custom_table_healthy() { - global $wpdb; - - if ( ! $this->custom_table_exists() ) { - return new \WP_Error( 'custom_table_not_exist', 'Jetpack Sync Custom table: Table does not exist' ); - } - - // Try to read from the table - - // Ignore the interpolated table name - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $query = $wpdb->query( "SELECT count(`ID`) FROM {$this->table_name}" ); - - if ( $query === false ) { - // The query failed to select anything from the table, so there must be an issue reading from it. - return new \WP_Error( 'custom_table_unable_to_read', 'Jetpack Sync Custom table: Unable to read from table' ); - } - - if ( $wpdb->last_error ) { - // There was an error reading, that's not necessarily failing the query. - // TODO check if we need this error check. - // TODO add more information about the erorr in the return value. - return new \WP_Error( 'custom_table_unable_to_read_sql_error', 'Jetpack Sync Custom table: Unable to read from table - SQL error' ); - } - - // Check if we can write in the table - if ( ! $this->insert_item( 'test', 'test' ) ) { - return new \WP_Error( 'custom_table_unable_to_writeread', 'Jetpack Sync Custom table: Unable to write into table' ); - } - - // See if we can read the item back - $items = $this->fetch_items_by_ids( array( 'test' ) ); - if ( empty( $items ) || ! is_object( $items[0] ) || $items[0]->value !== 'test' ) { - return new \WP_Error( 'custom_table_unable_to_writeread', 'Jetpack Sync Custom table: Unable to read item after writing' ); - } - - // Try to insert an item, read it back and then delete it. - $this->delete_items_by_ids( array( 'test' ) ); - - // Try to fetch the item back. It should not exist. - $items = $this->fetch_items_by_ids( array( 'test' ) ); - if ( ! empty( $items ) ) { - return new \WP_Error( 'custom_table_unable_to_writeread', 'Jetpack Sync Custom table: Unable to delete from table' ); - } - - return true; - } - - /** - * Drop the custom table as part of cleanup. - * - * @return bool If the table is cleared. - */ - public function drop_table() { - global $wpdb; - - if ( $this->custom_table_exists() ) { - // Ignoring the linting warning, as there's still no placeholder replacement for DB field name. - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.DirectDatabaseQuery.SchemaChange - return (bool) $wpdb->query( "DROP TABLE {$this->table_name}" ); - } - } - - /** - * Queue API implementation - */ - - /** - * Insert an item in the queue. - * - * @param string $item_id The item ID. - * @param string $item Serialized item data. - * - * @return bool If the item was added. - */ - public function insert_item( $item_id, $item ) { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $rows_added = $wpdb->query( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "INSERT INTO {$this->table_name} (queue_id, event_id, event_payload) VALUES (%s, %s,%s)", - $this->queue_id, - $item_id, - $item - ) - ); - - return ( 0 !== $rows_added ); - } - - /** - * Fetch items from the queue. - * - * @param int|null $item_count How many items to fetch from the queue. - * The parameter is null-able, if no limit on the amount of items. - * - * @return object[]|null - */ - public function fetch_items( $item_count ) { - global $wpdb; - - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:disable WordPress.DB.PreparedSQL.InterpolatedNotPrepared - - // TODO make it more simple for the $item_count - if ( $item_count ) { - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $items = $wpdb->get_results( - $wpdb->prepare( - " - SELECT - event_id AS id, - event_payload AS value - FROM {$this->table_name} - WHERE queue_id LIKE %s - ORDER BY event_id ASC - LIMIT %d - ", - $this->queue_id, - $item_count - ) - ); - } else { - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $items = $wpdb->get_results( - $wpdb->prepare( - " - SELECT - event_id AS id, - event_payload AS value - FROM {$this->table_name} - WHERE queue_id LIKE %s - ORDER BY event_id ASC - ", - $this->queue_id - ) - ); - } - - // phpcs:enable WordPress.DB.PreparedSQL.InterpolatedNotPrepared - - return $items; - } - - /** - * Fetches items with specific IDs from the Queue. - * - * @param array $items_ids Items IDs to fetch from the queue. - * - * @return object[]|null - */ - public function fetch_items_by_ids( $items_ids ) { - global $wpdb; - - // return early if $items_ids is empty or not an array. - if ( empty( $items_ids ) || ! is_array( $items_ids ) ) { - return array(); - } - - $ids_placeholders = implode( ', ', array_fill( 0, count( $items_ids ), '%s' ) ); - $query_with_placeholders = "SELECT event_id AS id, event_payload AS value - FROM {$this->table_name} - WHERE queue_id = %s AND event_id IN ( $ids_placeholders )"; - - $replacement_values = array_merge( array( $this->queue_id ), $items_ids ); - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $items = $wpdb->get_results( - $wpdb->prepare( - $query_with_placeholders, // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - $replacement_values - ), - OBJECT - ); - - return $items; - } - - /** - * Check how many items are in the queue. - * - * @return int - */ - public function get_item_count() { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $items_count = (int) $wpdb->get_var( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT COUNT(*) FROM {$this->table_name} WHERE queue_id = %s", - $this->queue_id - ) - ); - // If the table does not exist, disable the custom queue table and send an error. - if ( ! empty( $wpdb->last_error ) - && str_contains( $wpdb->last_error, $this->table_name_no_prefix . "' doesn't exist" ) - && ! get_transient( self::CUSTOM_QUEUE_TABLE_DISABLE_WPDB_ERROR_NOT_EXIST_FLAG ) - ) { - set_transient( self::CUSTOM_QUEUE_TABLE_DISABLE_WPDB_ERROR_NOT_EXIST_FLAG, true, 6 * HOUR_IN_SECONDS ); - Settings::update_settings( array( 'custom_queue_table_enabled' => 0 ) ); - $data = array( - 'timestamp' => microtime( true ), - 'error' => $wpdb->last_error, - ); - $sender = Sender::get_instance(); - $sender->send_action( 'jetpack_sync_storage_error_custom_table_not_exist', $data ); - } - - return $items_count; - } - - /** - * Clear out the queue. - * - * @return bool|int|\mysqli_result|resource|null - */ - public function clear_queue() { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - return $wpdb->query( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "DELETE FROM {$this->table_name} WHERE queue_id = %s", - $this->queue_id - ) - ); - } - - /** - * Return the lag amount for the queue. - * - * @param float|int|null $now A timestamp to use as starting point when calculating the lag. - * - * @return float|int The lag amount. - */ - public function get_lag( $now = null ) { - global $wpdb; - - // TODO replace with peek and a flag to fetch only the name. - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $first_item_name = $wpdb->get_var( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT event_id FROM {$this->table_name} WHERE queue_id = %s ORDER BY event_id ASC LIMIT 1", - $this->queue_id - ) - ); - - if ( ! $first_item_name ) { - return 0; - } - - if ( null === $now ) { - $now = microtime( true ); - } - - // Break apart the item name to get the timestamp. - $matches = null; - if ( preg_match( '/^jpsq_' . $this->queue_id . '-(\d+\.\d+)-/', $first_item_name, $matches ) ) { - return $now - (float) $matches[1]; - } else { - return 0; - } - } - - /** - * Add multiple items to the queue at once. - * - * @param array $items Array of items to add. - * @param string $id_prefix Prefix to use for all the items. - * - * @return bool|int|\mysqli_result|resource|null - */ - public function add_all( $items, $id_prefix ) { - global $wpdb; - - $query = "INSERT INTO {$this->table_name} (queue_id, event_id, event_payload ) VALUES "; - - $rows = array(); - $count_items = count( $items ); - for ( $i = 0; $i < $count_items; ++$i ) { - // skip empty items. - if ( empty( $items[ $i ] ) ) { - continue; - } - try { - $event_id = esc_sql( $id_prefix . '-' . $i ); - $event_payload = esc_sql( serialize( $items[ $i ] ) ); // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.serialize_serialize - $rows[] = "('{$this->queue_id}', '$event_id','$event_payload')"; - } catch ( \Exception $e ) { - // Item cannot be serialized so skip. - continue; - } - } - - $rows_added = $wpdb->query( $query . implode( ',', $rows ) ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared, WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching - - return $rows_added; - } - - /** - * Return $max_count items from the queue, including their value string length. - * - * @param int $max_count How many items to fetch from the queue. - * - * @return object[]|null - */ - public function get_items_ids_with_size( $max_count ) { - global $wpdb; - - // TODO optimize the fetch to happen by queue name not by the IDs as it can be issue cross-queues. - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - return $wpdb->get_results( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "SELECT event_id AS id, LENGTH( event_payload ) AS value_size FROM {$this->table_name} WHERE queue_id = %s ORDER BY event_id ASC LIMIT %d", - $this->queue_id, - $max_count - ), - OBJECT - ); - } - - /** - * Delete items with specific IDs from the queue. - * - * @param array $ids IDs of the items to remove from the queue. - * - * @return bool|int|\mysqli_result|resource|null - */ - public function delete_items_by_ids( $ids ) { - global $wpdb; - $ids_placeholders = implode( ', ', array_fill( 0, count( $ids ), '%s' ) ); - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - return $wpdb->query( - $wpdb->prepare( - /** - * Ignoring the linting warning, as there's still no placeholder replacement for DB field name, - * in this case this is `$this->table_name` - */ - // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared - "DELETE FROM {$this->table_name} WHERE queue_id = %s AND event_id IN ( $ids_placeholders )", - array_merge( array( $this->queue_id ), $ids ) - ) - ); - } - - /** - * Table initialization - */ - public static function initialize_custom_sync_table() { - /** - * Initialize an instance of the class with a test name, so we can use table prefix and then test if the table is healthy. - */ - $custom_table_instance = new Queue_Storage_Table( 'test_queue' ); - - // Check if the table exists - if ( ! $custom_table_instance->custom_table_exists() ) { - $custom_table_instance->create_table(); - } - - return $custom_table_instance->is_custom_table_healthy(); - } - - /** - * Migrates the existing Sync events from the options table to the Custom table - * - * @return bool - */ - public static function migrate_from_options_table_to_custom_table() { - global $wpdb; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching - $count_result = $wpdb->get_row( - " - SELECT - COUNT(*) as item_count - FROM - {$wpdb->options} - WHERE - option_name LIKE 'jpsq_%' - " - ); - - $item_count = $count_result->item_count; - - $limit = 100; - $offset = 0; - - do { - // get all the records from the options table - $query = " - SELECT - option_name as event_id, - option_value as event_payload - FROM - {$wpdb->options} - WHERE - option_name LIKE 'jpsq_%' - ORDER BY - option_name ASC - LIMIT $offset, $limit - "; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.NotPrepared - $rows = $wpdb->get_results( $query ); - - $insert_rows = array(); - - foreach ( $rows as $event ) { - $event_id = $event->event_id; - - // Parse the event - if ( - preg_match( - '!jpsq_(?P[^-]+)-(?P[^-]+)-.+!', - $event_id, - $events_matches - ) - ) { - $queue_id = $events_matches['queue_id']; - $timestamp = $events_matches['timestamp']; - - $insert_rows[] = $wpdb->prepare( - '(%s, %s, %s, %s)', - array( - $queue_id, - $event_id, - $event->event_payload, - (int) $timestamp, - ) - ); - } - } - - // Instantiate table storage, so we can get the table name. Queue ID is just a placeholder here. - $queue_table_storage = new Queue_Storage_Table( 'test_queue' ); - - if ( ! empty( $insert_rows ) ) { - $insert_query = 'INSERT INTO ' . $queue_table_storage->table_name . ' (queue_id, event_id, event_payload, timestamp) VALUES '; - - $insert_query .= implode( ',', $insert_rows ); - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.NotPrepared - $wpdb->query( $insert_query ); - } - - $offset += $limit; - } while ( $offset < $item_count ); - - // Clear out the options queue - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.NotPrepared - $wpdb->query( - $wpdb->prepare( - "DELETE FROM $wpdb->options WHERE option_name LIKE %s", - 'jpsq_%-%' - ) - ); - - return true; - } - - /** - * Migrates the existing Sync events from the Custom table to the Options table - * - * @return void - */ - public static function migrate_from_custom_table_to_options_table() { - global $wpdb; - - // Instantiate table storage, so we can get the table name. Queue ID is just a placeholder here. - $queue_table_storage = new Queue_Storage_Table( 'test_queue' ); - $custom_table_name = $queue_table_storage->table_name; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $count_result = $wpdb->get_row( "SELECT COUNT(*) as item_count FROM {$custom_table_name}" ); - - if ( $wpdb->last_error ) { - return; - } - - $item_count = $count_result->item_count; - - $limit = 100; - $offset = 0; - - do { - // get all the records from the options table - $query = " - SELECT - event_id, - event_payload - FROM - {$custom_table_name} - ORDER BY - event_id ASC - LIMIT $offset, $limit - "; - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.NotPrepared - $rows = $wpdb->get_results( $query ); - - $insert_rows = array(); - - foreach ( $rows as $event ) { - $insert_rows[] = $wpdb->prepare( - '(%s, %s, "no")', - array( - $event->event_id, - $event->event_payload, - ) - ); - } - - if ( ! empty( $insert_rows ) ) { - $insert_query = "INSERT INTO {$wpdb->options} (option_name, option_value, autoload) VALUES "; - - $insert_query .= implode( ',', $insert_rows ); - - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.NotPrepared - $wpdb->query( $insert_query ); - } - - $offset += $limit; - } while ( $offset < $item_count ); - - // Clear the custom table - // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery,WordPress.DB.DirectDatabaseQuery.NoCaching,WordPress.DB.PreparedSQL.InterpolatedNotPrepared - $wpdb->query( "DELETE FROM {$custom_table_name}" ); - - // TODO should we drop the table here instead? - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/CHANGELOG.md deleted file mode 100644 index e9fe5525..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/CHANGELOG.md +++ /dev/null @@ -1,107 +0,0 @@ -# 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). - -## [0.3.1] - 2025-03-24 -### Changed -- Internal updates. - -## [0.3.0] - 2025-01-09 -### Added -- Enable test coverage. [#39961] - -### Changed -- Backup: Added next daily backup schedule time on admin page. [#39914] -- Updated dependencies. [#40286] - -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.2.6] - 2024-10-29 -### Changed -- Internal updates. [#39781] - -## [0.2.5] - 2024-10-15 -### Changed -- Update dependencies. [#39497] - -## [0.2.4] - 2024-09-06 -### Changed -- Updated package dependencies. [#39004] - -## [0.2.3] - 2024-05-24 -### Fixed -- Backup: Change error messages to not trigger security scanners. [#36496] - -## [0.2.2] - 2024-03-19 -### Fixed -- Handle upgrades from plugins embedding version 0.2.0 of the package. [#36440] - -## [0.2.1] - 2024-03-14 -### Added -- Increasing backup version for new endpoint [#35649] - -### Fixed -- Write helper script to ABSPATH by default, just like we did before [#35508] - -## [0.2.0] - 2024-01-18 -### Changed -- The package now requires PHP >= 7.0. [#34192] - -### Fixed -- Backup: Add namespace versioning to Helper_Script_Manager and other classes. [#34739] -- Backup: Bug fixes in helper script installation class. [#34297] - -## [0.1.6] - 2023-10-19 -### Changed -- Updated package dependencies. [#32605] - -### Fixed -- Fix helper script upload for sites without direct file system access. [#32102] - -## [0.1.5] - 2023-07-06 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.1.4] - 2023-03-29 -### Changed -- Minor internal updates. - -## [0.1.3] - 2023-01-25 -### Changed -- Use `WP_Filesystem` more consistently in `Helper_Script_Manager`. [#28198] - -## [0.1.2] - 2022-12-05 -### Changed -- Updated package dependencies. [#27688] - -## [0.1.1] - 2022-11-30 -### Changed -- Updated package dependencies. [#27043] - -## 0.1.0 - 2022-11-01 -### Added -- Adding the initial empty package -- Duplicate helper script code to a dedicated package - -### Changed -- Updated package dependencies. - -[0.3.1]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.6...v0.3.0 -[0.2.6]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.5...v0.2.6 -[0.2.5]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.4...v0.2.5 -[0.2.4]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.3...v0.2.4 -[0.2.3]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.2...v0.2.3 -[0.2.2]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.1...v0.2.2 -[0.2.1]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.6...v0.2.0 -[0.1.6]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.5...v0.1.6 -[0.1.5]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.4...v0.1.5 -[0.1.4]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.3...v0.1.4 -[0.1.3]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.2...v0.1.3 -[0.1.2]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.1...v0.1.2 -[0.1.1]: https://github.com/Automattic/jetpack-transport-helper/compare/v0.1.0...v0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/actions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/actions.php deleted file mode 100644 index c3d7e01b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/actions.php +++ /dev/null @@ -1,32 +0,0 @@ - $accepted_args, - 'function' => $cb, - ); - }; - $add_action = $add_filter; -} - -// Clean up expired Jetpack Helper Scripts from a scheduled event. -$add_action( 'jetpack_cleanup_helper_scripts', array( 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager', 'cleanup_expired_helper_scripts' ) ); - -// Register REST routes. -$add_action( 'rest_api_init', array( 'Automattic\Jetpack\Transport_Helper\V0005\\REST_Controller', 'register_rest_routes' ) ); - -// Set up package version hook. -$add_filter( 'jetpack_package_versions', 'Automattic\\Jetpack\\Transport_Helper\\Package_Version::send_package_version_to_tracker' ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/composer.json deleted file mode 100644 index c1915cbe..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/composer.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "name": "automattic/jetpack-transport-helper", - "description": "Package to help transport server communication", - "type": "jetpack-library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-backup-helper-script-manager": "^0.3.6", - "automattic/jetpack-connection": "^6.8.1" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ], - "build-production": "echo 'Add your build step to composer.json, please!'", - "build-development": "echo 'Add your build step to composer.json, please!'" - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "mirror-repo": "Automattic/jetpack-transport-helper", - "version-constants": { - "::PACKAGE_VERSION": "src/class-package-version.php" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-transport-helper/compare/v${old}...v${new}" - }, - "autotagger": true, - "branch-alias": { - "dev-trunk": "0.3.x-dev" - }, - "textdomain": "jetpack-transport-helper" - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version-compat.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version-compat.php deleted file mode 100644 index c14ec470..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version-compat.php +++ /dev/null @@ -1,25 +0,0 @@ - WP_REST_Server::CREATABLE, - 'callback' => __CLASS__ . '::install_helper_script', - 'permission_callback' => __CLASS__ . '::helper_script_permissions_callback', - 'args' => array( - 'helper' => array( - 'description' => __( 'base64 encoded Helper Script body.', 'jetpack-transport-helper' ), - 'type' => 'string', - 'required' => true, - ), - ), - ) - ); - - // Delete a Helper Script. - register_rest_route( - 'jetpack/v4', - // This route can be generalized once we no longer depend on the backup package - '/backup-helper-script', - array( - 'methods' => WP_REST_Server::DELETABLE, - 'callback' => __CLASS__ . '::delete_helper_script', - 'permission_callback' => __CLASS__ . '::helper_script_permissions_callback', - 'args' => array( - 'path' => array( - 'description' => __( 'Path to Helper Script', 'jetpack-transport-helper' ), - 'type' => 'string', - 'required' => true, - ), - ), - ) - ); - } - - /** - * The Jetpack endpoints should only be available via site-level authentication. - * This means that the corresponding endpoints can only be accessible from WPCOM. - * - * @access public - * @static - * - * @return bool|WP_Error True if a blog token was used to sign the request, WP_Error otherwise. - */ - public static function helper_script_permissions_callback() { - if ( Rest_Authentication::is_signed_with_blog_token() ) { - return true; - } - - $error_msg = esc_html__( - 'You are not allowed to perform this action.', - 'jetpack-transport-helper' - ); - - return new WP_Error( 'rest_forbidden', $error_msg, array( 'status' => rest_authorization_required_code() ) ); - } - - /** - * Install the Helper Script. - * - * @access public - * @static - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return array|WP_Error An array with installation info on success: - * - * 'path' (string) Helper script installation path on the filesystem. - * 'url' (string) URL to the helper script. - * 'abspath' (string) WordPress root. - * - * or an instance of WP_Error on failure. - */ - public static function install_helper_script( $request ) { - $helper_script = $request->get_param( 'helper' ); - - // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_decode - $helper_script = base64_decode( $helper_script ); - if ( ! $helper_script ) { - return new WP_Error( 'invalid_args', __( 'Helper Script body must be base64 encoded', 'jetpack-transport-helper' ), 400 ); - } - - $installation_info = Helper_Script_Manager::install_helper_script( $helper_script ); - Helper_Script_Manager::cleanup_expired_helper_scripts(); - - return rest_ensure_response( $installation_info ); - } - - /** - * Delete a Helper Script. - * - * @access public - * @static - * - * @param WP_REST_Request $request The request sent to the WP REST API. - * - * @return array|WP_Error An array with 'success' key indicating the result of the delete operation. - */ - public static function delete_helper_script( $request ) { - $path_to_helper_script = $request->get_param( 'path' ); - - $delete_result = Helper_Script_Manager::delete_helper_script( $path_to_helper_script ); - Helper_Script_Manager::cleanup_expired_helper_scripts(); - - if ( is_wp_error( $delete_result ) ) { - return $delete_result; - } - - return rest_ensure_response( array( 'success' => true ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/CHANGELOG.md deleted file mode 100644 index 196f90c0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/CHANGELOG.md +++ /dev/null @@ -1,534 +0,0 @@ -# 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). - -## [0.23.8] - 2025-03-24 -### Changed -- Internal updates. - -## [0.23.7] - 2025-03-17 -### Changed -- Internal updates. - -## [0.23.6] - 2025-03-12 -### Changed -- Internal updates. - -## [0.23.5] - 2025-03-10 -### Changed -- Ensure check_valid_blocked_user handles error outcomes. [#42036] - -## [0.23.4] - 2025-02-24 -### Changed -- Update dependencies. [#39263] - -## [0.23.3] - 2025-02-03 -### Fixed -- Code: Remove extra params on function calls. [#41263] - -## [0.23.2] - 2025-01-20 -### Changed -- Code: Use function-style exit() and die() with a default status code of 0. [#41167] - -## [0.23.1] - 2024-11-25 -### Changed -- Updated dependencies. [#40286] - -## [0.23.0] - 2024-11-18 -### Removed -- General: Update minimum PHP version to 7.2. [#40147] - -## [0.22.3] - 2024-11-04 -### Added -- Enable test coverage. [#39961] - -## [0.22.2] - 2024-10-29 -### Changed -- Internal updates. [#39263] - -## [0.22.1] - 2024-10-17 -### Fixed -- WAF: Improve backwards compatibility for sites running outdated bootstrap scripts via standalone mode. [#39812] - -## [0.22.0] - 2024-10-14 -### Added -- WAF: Add new properties to the WAF feature's REST API endpoint. [#39511] - -### Fixed -- Improve backwards compatibility for sites running in standalone mode. [#39652] -- WAF: Reduce amount of classes autoloaded during standalone mode execution. [#38944] - -## [0.21.0] - 2024-10-07 -### Added -- Firewall Runtime: Added support for rule files to specify body parser type. [#39516] - -## [0.20.1] - 2024-10-01 -### Deprecated -- Added back public API as deprecated. [#39606] - -## [0.20.0] - 2024-09-30 -### Added -- Added Waf_Blocklog_Manager class [#35739] - -## [0.19.0] - 2024-09-23 -### Added -- Firewall: add support for CIDR ranges in IP lists. [#39425] - -## [0.18.5] - 2024-09-06 -### Changed -- Updated package dependencies. [#39253] - -### Fixed -- Ensure that request body is parsed correctly [#39262] - -## [0.18.4] - 2024-08-26 -### Changed -- Updated package dependencies. [#39004] - -## [0.18.3] - 2024-08-19 -### Changed -- Internal updates. - -## [0.18.2] - 2024-08-15 -### Fixed -- Fix incorrect next-version tokens in php `@since` and/or `@deprecated` docs. [#38869] - -## [0.18.1] - 2024-08-08 -### Security -- Parse request body when method used is not POST [#38621] - -### Added -- Brute Force Protection: Add `jetpack_has_login_ability` hook. [#38518] - -## [0.18.0] - 2024-08-01 -### Added -- Adds global statistics [#38388] - -### Fixed -- Fix global stats type check [#38634] - -## [0.17.0] - 2024-07-22 -### Added -- Added the ability to toggle IP block and allow lists individually. [#38184] - -## [0.16.10] - 2024-06-26 -### Changed -- Internal updates. - -## [0.16.9] - 2024-06-03 -### Changed -- Phab baseline file update. [#36968] - -## [0.16.8] - 2024-05-20 -### Changed -- Internal updates. - -## [0.16.7] - 2024-05-06 -### Changed -- Internal updates. - -## [0.16.6] - 2024-04-29 -### Changed -- Internal updates. - -## [0.16.5] - 2024-04-25 -### Changed -- Internal updates. - -## [0.16.4] - 2024-04-22 -### Changed -- Internal updates. - -## [0.16.3] - 2024-04-15 -### Security -- Improves handling of REQUEST_URI. [#36833] - -## [0.16.2] - 2024-04-08 -### Changed -- Internal updates. - -## [0.16.1] - 2024-03-25 -### Changed -- Internal updates. - -## [0.16.0] - 2024-03-22 -### Added -- Add data to WAF logs and add toggle for users to opt-in to share more data with us if needed. [#36377] - -## [0.15.2] - 2024-03-18 -### Changed -- Internal updates. - -## [0.15.1] - 2024-03-14 -### Changed -- Internal updates. - -## [0.15.0] - 2024-03-12 -### Added -- Add JSON parameter support to the Web Application Firewall. [#36169] - -## [0.14.2] - 2024-03-04 -### Fixed -- Fixed base64 transforms to better conform with the modsecurity runtime [#35693] - -## [0.14.1] - 2024-02-27 -### Changed -- Internal updates. - -## [0.14.0] - 2024-02-12 -### Added -- Add standalone mode status to WAF config [#34840] - -## [0.13.0] - 2024-02-05 -### Added -- Run the WAF on JN environments [#35341] - -## [0.12.4] - 2024-01-18 -### Fixed -- Optimize how the web application firewall checks for updates on admin screens. [#34820] - -## [0.12.3] - 2024-01-02 -### Changed -- Internal updates. - -## [0.12.2] - 2023-12-25 -### Changed -- Improve top-level WP-CLI command description [#34745] - -## [0.12.1] - 2023-11-21 - -## [0.12.0] - 2023-11-20 -### Changed -- Updated required PHP version to >= 7.0. [#34192] - -## [0.11.15] - 2023-11-14 - -## [0.11.14] - 2023-10-30 - -## [0.11.13] - 2023-10-10 -### Fixed -- Escape email address when output in HTML. [#33536] - -## [0.11.12] - 2023-09-28 -### Changed -- Minor internal updates. - -## [0.11.11] - 2023-09-19 - -- Minor internal updates. - -## [0.11.10] - 2023-09-11 -### Changed -- General: remove backwards-compatible functions now that package relies on WordPress 6.2. [#32772] - -## [0.11.9] - 2023-08-28 -### Changed -- Updated package dependencies. [#32605] - -## [0.11.8] - 2023-07-18 -### Changed -- Add support for running brute force protection in environments that otherwise do not support the WAF. [#31761] -- Minor performance improvements. [#31684] - -## [0.11.7] - 2023-07-17 -### Changed -- Add support for non-empty server https values. [#31688] - -## [0.11.6] - 2023-05-22 -### Added -- Add integration tests for unsupported environments [#30544] - -### Fixed -- Fix Brute force protection activation when WAF unset [#30544] -- Fix unavailable endpoint when WAF module is disabled [#30487] -- Multisite: avoid errors when the package is used in the Protect plugin instead of the Jetpack plugin. [#30767] - -## [0.11.5] - 2023-05-15 -### Changed -- Internal updates. - -## [0.11.4] - 2023-04-27 -### Added -- Fix hardblock issue if user only has Protect installed [#30278] - -## [0.11.3] - 2023-04-17 -### Fixed -- Fix brute force protection not initializing on atomic. [#30113] - -## [0.11.2] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.11.1] - 2023-04-03 -### Fixed -- Return early if we detect the older BFP implementation from the main plugin [#29794] - -## [0.11.0] - 2023-03-28 -### Added -- Added brute force protection to the WAF configuration REST API endpoints [#28401] -- Move the brute force protection module into the package. [#28401] - -### Changed -- Change "whitelist" to "allow list". [#28401] -- Move the brute force protection transient cleanup and shared functions to dedicated namespaced classes. [#28401] -- Use WAF IP allow list option in brute force protection feature. [#28401] - -## [0.10.2] - 2023-03-20 -### Changed -- Updated package dependencies. [#29480] - -## [0.10.1] - 2023-03-08 -### Changed -- Minor internal updates. - -## [0.10.0] - 2023-02-28 -### Added -- Added support for IP ranges in allow and block lists. [#29131] - -## [0.9.3] - 2023-02-20 -### Changed -- Minor internal updates. - -## [0.9.2] - 2023-02-15 -### Changed -- Minor internal updates. - -## [0.9.1] - 2023-02-13 -### Fixed -- Fix an update error that impacted sites using the WAF in standalone mode. [#28844] - -## [0.9.0] - 2023-01-25 -### Changed -- Change the web application firewall to run automatic and manual rules independently. [#27726] - -## [0.8.3] - 2023-01-11 -### Fixed -- Fixed the WAF package's PHP tests and Composer requirements [#28185] - -## [0.8.2] - 2023-01-09 -### Fixed -- Fix firewall activation hooks on first option updates. [#28234] - -## [0.8.1] - 2023-01-07 -### Changed -- Change directory location that stores firewall rules. [#28049] - -## [0.8.0] - 2022-12-27 -### Added -- Add file existance checks before requiring rule files in the WAF. [#28050] -- Disable Jetpack Firewall on unsupported environments. [#27939] - -## [0.7.2] - 2022-12-19 -### Fixed -- Fix the initialization of the firewall. [#27846] - -## [0.7.1] - 2022-12-06 -### Changed -- html_entity_decode filter now decodes single-quotes too, and uses a Unicode Replacement Character instead of returning empty string on invalid characters. [#27753] - -## [0.7.0] - 2022-12-05 -### Added -- Prepare package for use in the Jetpack Protect standalone plugin. [#27528] - -### Changed -- Updated package dependencies. [#27688] - -### Removed -- Remove has_rules_access plan check in favor of external alternatives [#27600] - -## [0.6.10] - 2022-11-28 -### Changed -- Updated package dependencies. [#27043] - -## [0.6.9] - 2022-11-01 -### Fixed -- Fix bug for cron event not generating IP rules. [#27215] - -## [0.6.8] - 2022-10-27 -### Fixed -- Fixes several invalid action callbacks. [#27106] - -## [0.6.7] - 2022-09-20 -### Changed -- Changing how we load and run the package to avoid actions.php [#24730] - -## [0.6.6] - 2022-09-08 -### Fixed -- Fixed exception namespace. [#25663] - -## [0.6.5] - 2022-07-26 -### Changed -- Updated package dependencies. [#25158] - -## [0.6.4] - 2022-07-12 -### Fixed -- Correct namespacing error. [#24993] - -## [0.6.3] - 2022-06-21 -### Changed -- Renaming master to trunk. [#24661] - -## [0.6.2] - 2022-06-06 -### Fixed -- Fix the hook we're using for run.php. - -## [0.6.1] - 2022-06-02 -### Removed -- Disable the WAF module on Atomic - -## [0.6.0] - 2022-05-18 -### Added -- Add checks for a killswitch define [#24247] -- Added endpoint to update rules on demand [#24327] -- handle share data option to decide if we should write to log file [#24218] - -### Fixed -- Allow the rules API to return 401 responses without throwing an exception. [#24153] -- fix bootstrap generation in cases file.php is not required yet [#24153] - -## [0.5.1] - 2022-05-04 -### Added -- Added a check to only run the firewall when the Jetpack module is enabled, a method to provide the bootstrap.php path, and a REST API endpoint to provide the firewall settings. [#23769] -- Connected the WAF UI to actually updating the IP block and allow lists when saving the settings. [#24124] - -### Fixed -- Fixed database logging [#24070] -- Fixed issue where code for the waf package was executed if the module was disabled [#24217] -- Fixed writing rules php files if the API request for getting up-to-date rules failes so that the internal functionality is kept in tact. [#24181] -- We now sanitize the output generated by blocked requests, and only report the rule ID in the header response. [#24058] - -## [0.5.0] - 2022-04-26 -### Added -- added cron to update rules -- Added WAF IP allow list and block list functionality. - -### Changed -- Added comment to ignore failing phpcs check -- PHPCS: Fix `WordPress.Security.ValidatedSanitizedInput` -- Updated package dependencies. - -## [0.4.0] - 2022-04-19 -### Added -- added logs when a request is blocked -- Generating rules now fetches them from the API. Also adds a few CLI commands. - -## [0.3.0] - 2022-04-12 -### Added -- Added hooks for generating the rules.php file, and improved functionality and class names. - -## [0.2.0] - 2022-04-06 -### Added -- Added Jetpack WAF standalone mode. - -### Fixed -- Fix normalizing nested array targets, like with query strings. - -## [0.1.1] - 2022-03-29 -### Fixed -- Fixed instance of normalizeHeaderName that wasn't renamed; fixed header parsing; removed unused compiler file. - -## 0.1.0 - 2022-02-16 -### Added -- Added executing the WAF as part of the Jetpack plugin. -- Added Initial version - -### Changed -- Core: do not ship .phpcs.dir.xml in production builds. - -[0.23.8]: https://github.com/Automattic/jetpack-waf/compare/v0.23.7...v0.23.8 -[0.23.7]: https://github.com/Automattic/jetpack-waf/compare/v0.23.6...v0.23.7 -[0.23.6]: https://github.com/Automattic/jetpack-waf/compare/v0.23.5...v0.23.6 -[0.23.5]: https://github.com/Automattic/jetpack-waf/compare/v0.23.4...v0.23.5 -[0.23.4]: https://github.com/Automattic/jetpack-waf/compare/v0.23.3...v0.23.4 -[0.23.3]: https://github.com/Automattic/jetpack-waf/compare/v0.23.2...v0.23.3 -[0.23.2]: https://github.com/Automattic/jetpack-waf/compare/v0.23.1...v0.23.2 -[0.23.1]: https://github.com/Automattic/jetpack-waf/compare/v0.23.0...v0.23.1 -[0.23.0]: https://github.com/Automattic/jetpack-waf/compare/v0.22.3...v0.23.0 -[0.22.3]: https://github.com/Automattic/jetpack-waf/compare/v0.22.2...v0.22.3 -[0.22.2]: https://github.com/Automattic/jetpack-waf/compare/v0.22.1...v0.22.2 -[0.22.1]: https://github.com/Automattic/jetpack-waf/compare/v0.22.0...v0.22.1 -[0.22.0]: https://github.com/Automattic/jetpack-waf/compare/v0.21.0...v0.22.0 -[0.21.0]: https://github.com/Automattic/jetpack-waf/compare/v0.20.1...v0.21.0 -[0.20.1]: https://github.com/Automattic/jetpack-waf/compare/v0.20.0...v0.20.1 -[0.20.0]: https://github.com/Automattic/jetpack-waf/compare/v0.19.0...v0.20.0 -[0.19.0]: https://github.com/Automattic/jetpack-waf/compare/v0.18.5...v0.19.0 -[0.18.5]: https://github.com/Automattic/jetpack-waf/compare/v0.18.4...v0.18.5 -[0.18.4]: https://github.com/Automattic/jetpack-waf/compare/v0.18.3...v0.18.4 -[0.18.3]: https://github.com/Automattic/jetpack-waf/compare/v0.18.2...v0.18.3 -[0.18.2]: https://github.com/Automattic/jetpack-waf/compare/v0.18.1...v0.18.2 -[0.18.1]: https://github.com/Automattic/jetpack-waf/compare/v0.18.0...v0.18.1 -[0.18.0]: https://github.com/Automattic/jetpack-waf/compare/v0.17.0...v0.18.0 -[0.17.0]: https://github.com/Automattic/jetpack-waf/compare/v0.16.10...v0.17.0 -[0.16.10]: https://github.com/Automattic/jetpack-waf/compare/v0.16.9...v0.16.10 -[0.16.9]: https://github.com/Automattic/jetpack-waf/compare/v0.16.8...v0.16.9 -[0.16.8]: https://github.com/Automattic/jetpack-waf/compare/v0.16.7...v0.16.8 -[0.16.7]: https://github.com/Automattic/jetpack-waf/compare/v0.16.6...v0.16.7 -[0.16.6]: https://github.com/Automattic/jetpack-waf/compare/v0.16.5...v0.16.6 -[0.16.5]: https://github.com/Automattic/jetpack-waf/compare/v0.16.4...v0.16.5 -[0.16.4]: https://github.com/Automattic/jetpack-waf/compare/v0.16.3...v0.16.4 -[0.16.3]: https://github.com/Automattic/jetpack-waf/compare/v0.16.2...v0.16.3 -[0.16.2]: https://github.com/Automattic/jetpack-waf/compare/v0.16.1...v0.16.2 -[0.16.1]: https://github.com/Automattic/jetpack-waf/compare/v0.16.0...v0.16.1 -[0.16.0]: https://github.com/Automattic/jetpack-waf/compare/v0.15.1...v0.16.0 -[0.15.2]: https://github.com/Automattic/jetpack-waf/compare/v0.15.1...v0.15.2 -[0.15.1]: https://github.com/Automattic/jetpack-waf/compare/v0.15.0...v0.15.1 -[0.15.0]: https://github.com/Automattic/jetpack-waf/compare/v0.14.2...v0.15.0 -[0.14.2]: https://github.com/Automattic/jetpack-waf/compare/v0.14.1...v0.14.2 -[0.14.1]: https://github.com/Automattic/jetpack-waf/compare/v0.14.0...v0.14.1 -[0.14.0]: https://github.com/Automattic/jetpack-waf/compare/v0.13.0...v0.14.0 -[0.13.0]: https://github.com/Automattic/jetpack-waf/compare/v0.12.4...v0.13.0 -[0.12.4]: https://github.com/Automattic/jetpack-waf/compare/v0.12.3...v0.12.4 -[0.12.3]: https://github.com/Automattic/jetpack-waf/compare/v0.12.2...v0.12.3 -[0.12.2]: https://github.com/Automattic/jetpack-waf/compare/v0.12.1...v0.12.2 -[0.12.1]: https://github.com/Automattic/jetpack-waf/compare/v0.12.0...v0.12.1 -[0.12.0]: https://github.com/Automattic/jetpack-waf/compare/v0.11.15...v0.12.0 -[0.11.15]: https://github.com/Automattic/jetpack-waf/compare/v0.11.14...v0.11.15 -[0.11.14]: https://github.com/Automattic/jetpack-waf/compare/v0.11.13...v0.11.14 -[0.11.13]: https://github.com/Automattic/jetpack-waf/compare/v0.11.12...v0.11.13 -[0.11.12]: https://github.com/Automattic/jetpack-waf/compare/v0.11.11...v0.11.12 -[0.11.11]: https://github.com/Automattic/jetpack-waf/compare/v0.11.10...v0.11.11 -[0.11.10]: https://github.com/Automattic/jetpack-waf/compare/v0.11.9...v0.11.10 -[0.11.9]: https://github.com/Automattic/jetpack-waf/compare/v0.11.8...v0.11.9 -[0.11.8]: https://github.com/Automattic/jetpack-waf/compare/v0.11.7...v0.11.8 -[0.11.7]: https://github.com/Automattic/jetpack-waf/compare/v0.11.6...v0.11.7 -[0.11.6]: https://github.com/Automattic/jetpack-waf/compare/v0.11.5...v0.11.6 -[0.11.5]: https://github.com/Automattic/jetpack-waf/compare/v0.11.4...v0.11.5 -[0.11.4]: https://github.com/Automattic/jetpack-waf/compare/v0.11.3...v0.11.4 -[0.11.3]: https://github.com/Automattic/jetpack-waf/compare/v0.11.2...v0.11.3 -[0.11.2]: https://github.com/Automattic/jetpack-waf/compare/v0.11.1...v0.11.2 -[0.11.1]: https://github.com/Automattic/jetpack-waf/compare/v0.11.0...v0.11.1 -[0.11.0]: https://github.com/Automattic/jetpack-waf/compare/v0.10.2...v0.11.0 -[0.10.2]: https://github.com/Automattic/jetpack-waf/compare/v0.10.1...v0.10.2 -[0.10.1]: https://github.com/Automattic/jetpack-waf/compare/v0.10.0...v0.10.1 -[0.10.0]: https://github.com/Automattic/jetpack-waf/compare/v0.9.3...v0.10.0 -[0.9.3]: https://github.com/Automattic/jetpack-waf/compare/v0.9.2...v0.9.3 -[0.9.2]: https://github.com/Automattic/jetpack-waf/compare/v0.9.1...v0.9.2 -[0.9.1]: https://github.com/Automattic/jetpack-waf/compare/v0.9.0...v0.9.1 -[0.9.0]: https://github.com/Automattic/jetpack-waf/compare/v0.8.3...v0.9.0 -[0.8.3]: https://github.com/Automattic/jetpack-waf/compare/v0.8.2...v0.8.3 -[0.8.2]: https://github.com/Automattic/jetpack-waf/compare/v0.8.1...v0.8.2 -[0.8.1]: https://github.com/Automattic/jetpack-waf/compare/v0.8.0...v0.8.1 -[0.8.0]: https://github.com/Automattic/jetpack-waf/compare/v0.7.2...v0.8.0 -[0.7.2]: https://github.com/Automattic/jetpack-waf/compare/v0.7.1...v0.7.2 -[0.7.1]: https://github.com/Automattic/jetpack-waf/compare/v0.7.0...v0.7.1 -[0.7.0]: https://github.com/Automattic/jetpack-waf/compare/v0.6.10...v0.7.0 -[0.6.10]: https://github.com/Automattic/jetpack-waf/compare/v0.6.9...v0.6.10 -[0.6.9]: https://github.com/Automattic/jetpack-waf/compare/v0.6.8...v0.6.9 -[0.6.8]: https://github.com/Automattic/jetpack-waf/compare/v0.6.7...v0.6.8 -[0.6.7]: https://github.com/Automattic/jetpack-waf/compare/v0.6.6...v0.6.7 -[0.6.6]: https://github.com/Automattic/jetpack-waf/compare/v0.6.5...v0.6.6 -[0.6.5]: https://github.com/Automattic/jetpack-waf/compare/v0.6.4...v0.6.5 -[0.6.4]: https://github.com/Automattic/jetpack-waf/compare/v0.6.3...v0.6.4 -[0.6.3]: https://github.com/Automattic/jetpack-waf/compare/v0.6.2...v0.6.3 -[0.6.2]: https://github.com/Automattic/jetpack-waf/compare/v0.6.1...v0.6.2 -[0.6.1]: https://github.com/Automattic/jetpack-waf/compare/v0.6.0...v0.6.1 -[0.6.0]: https://github.com/Automattic/jetpack-waf/compare/v0.5.1...v0.6.0 -[0.5.1]: https://github.com/Automattic/jetpack-waf/compare/v0.5.0...v0.5.1 -[0.5.0]: https://github.com/Automattic/jetpack-waf/compare/v0.4.0...v0.5.0 -[0.4.0]: https://github.com/Automattic/jetpack-waf/compare/v0.3.0...v0.4.0 -[0.3.0]: https://github.com/Automattic/jetpack-waf/compare/v0.2.0...v0.3.0 -[0.2.0]: https://github.com/Automattic/jetpack-waf/compare/v0.1.1...v0.2.0 -[0.1.1]: https://github.com/Automattic/jetpack-waf/compare/v0.1.0...v0.1.1 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/cli.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/cli.php deleted file mode 100644 index 54b71688..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/cli.php +++ /dev/null @@ -1,13 +0,0 @@ -=7.2", - "automattic/jetpack-connection": "^6.8.0", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-ip": "^0.4.6", - "automattic/jetpack-status": "^5.0.10", - "wikimedia/aho-corasick": "^1.0" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "files": [ - "cli.php" - ], - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config tests/php/integration/phpunit.#.xml.dist --colors=always", - "phpunit-select-config tests/php/unit/phpunit.#.xml.dist --colors=always" - ], - "test-coverage": "tests/action-test-coverage.sh", - "test-coverage-html": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config tests/php/integration/phpunit.#.xml.dist --coverage-html ./coverage", - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config tests/php/unit/phpunit.#.xml.dist --coverage-html ./coverage" - ], - "test-php": [ - "@composer phpunit" - ] - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-waf", - "textdomain": "jetpack-waf", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-waf/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "0.23.x-dev" - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-blocked-login-page.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-blocked-login-page.php deleted file mode 100644 index 6931a2f6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-blocked-login-page.php +++ /dev/null @@ -1,779 +0,0 @@ -can_send_recovery_emails = apply_filters( 'jetpack_protect_can_send_recovery_emails', true ); - $this->ip_address = $ip_address; - - add_filter( 'wp_authenticate_user', array( $this, 'check_valid_blocked_user' ), 10, 1 ); - add_filter( 'site_url', array( $this, 'add_args_to_login_post_url' ), 10, 3 ); - add_filter( 'network_site_url', array( $this, 'add_args_to_login_post_url' ), 10, 3 ); - add_filter( 'lostpassword_url', array( $this, 'add_args_to_lostpassword_url' ), 10, 2 ); - add_filter( 'login_url', array( $this, 'add_args_to_login_url' ), 10, 3 ); - add_filter( 'lostpassword_redirect', array( $this, 'add_args_to_lostpassword_redirect_url' ), 10, 1 ); - } - - /** - * Gets the URL that redirects to the support page on unblocking - * - * @since 8.5.0 - * - * @return string - */ - public static function get_help_url() { - return Redirect::get_url( 'jetpack-support-protect', array( 'anchor' => 'troubleshooting' ) ); - } - - /** - * Add arguments to lost password redirect url. - * - * @param string $url - the URL. - */ - public function add_args_to_lostpassword_redirect_url( $url ) { - if ( $this->valid_blocked_user_id ) { - $url = empty( $url ) ? wp_login_url() : $url; - $url = add_query_arg( - array( - 'validate_jetpack_protect_recovery' => isset( $_GET['validate_jetpack_protect_recovery'] ) ? filter_var( wp_unslash( $_GET['validate_jetpack_protect_recovery'] ) ) : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - 'user_id' => isset( $_GET['user_id'] ) ? (int) $_GET['user_id'] : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - 'checkemail' => 'confirm', - ), - $url - ); - } - - return $url; - } - - /** - * Add arguments to lost password redirect url. - * - * @param string $url - the URL. - * @param string $redirect - where to redirect to. - */ - public function add_args_to_lostpassword_url( $url, $redirect ) { - if ( $this->valid_blocked_user_id ) { - $args = array( - 'validate_jetpack_protect_recovery' => isset( $_GET['validate_jetpack_protect_recovery'] ) ? filter_var( wp_unslash( $_GET['validate_jetpack_protect_recovery'] ) ) : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - 'user_id' => isset( $_GET['user_id'] ) ? (int) $_GET['user_id'] : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - 'action' => 'lostpassword', - ); - if ( ! empty( $redirect ) ) { - $args['redirect_to'] = $redirect; - } - $url = add_query_arg( $args, $url ); - } - - return $url; - } - - /** - * Add arguments to login post url. - * - * @param string $url - the URL. - * @param string $path - the path. - * @param string $scheme -the scheme(?). - */ - public function add_args_to_login_post_url( $url, $path, $scheme ) { - if ( $this->valid_blocked_user_id && ( 'login_post' === $scheme || 'login' === $scheme ) ) { - $url = add_query_arg( - array( - 'validate_jetpack_protect_recovery' => isset( $_GET['validate_jetpack_protect_recovery'] ) ? filter_var( wp_unslash( $_GET['validate_jetpack_protect_recovery'] ) ) : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - 'user_id' => isset( $_GET['user_id'] ) ? (int) $_GET['user_id'] : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - ), - $url - ); - - } - - return $url; - } - - /** - * Add arguments to login post url. - * - * @param string $url - the URL. - * @param string $redirect - where we want to redirect to. - * @param string $force_reauth -if we're forcing reauthorization. - */ - public function add_args_to_login_url( $url, $redirect, $force_reauth ) { - if ( $this->valid_blocked_user_id ) { - $args = array( - 'validate_jetpack_protect_recovery' => isset( $_GET['validate_jetpack_protect_recovery'] ) ? filter_var( wp_unslash( $_GET['validate_jetpack_protect_recovery'] ) ) : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - 'user_id' => isset( $_GET['user_id'] ) ? (int) $_GET['user_id'] : null, // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - ); - - if ( ! empty( $redirect ) ) { - $args['redirect_to'] = $redirect; - } - - if ( ! empty( $force_reauth ) ) { - $args['reauth'] = '1'; - } - $url = add_query_arg( $args, $url ); - } - - return $url; - } - - /** - * Check if user is blocked. - * - * @param WP_User|WP_Error $user - The user or error object if prior callback failed auth. - */ - public function check_valid_blocked_user( $user ) { - if ( is_wp_error( $user ) ) { - return $user; - } - - if ( $this->valid_blocked_user_id && $this->valid_blocked_user_id != $user->ID ) { // phpcs:ignore Universal.Operators.StrictComparisons.LooseNotEqual - return new WP_Error( 'invalid_recovery_token', __( 'The recovery token is not valid for this user.', 'jetpack-waf' ) ); - } - - return $user; - } - - /** - * Check if user is valid. - */ - public function is_blocked_user_valid() { - if ( ! $this->can_send_recovery_emails ) { - return false; - } - - if ( $this->valid_blocked_user_id ) { - return true; - } - - if ( ! isset( $_GET['validate_jetpack_protect_recovery'] ) || ! isset( $_GET['user_id'] ) ) { // phpcs:ignore: WordPress.Security.NonceVerification.Recommended -- no changes made if this isn't set. - return false; - } - - if ( ! $this->is_valid_protect_recovery_key( filter_var( wp_unslash( $_GET['validate_jetpack_protect_recovery'] ) ), (int) $_GET['user_id'] ) ) { // phpcs:ignore: WordPress.Security.NonceVerification.Recommended -- no changes made if this isn't set. - return false; - } - - $this->valid_blocked_user_id = (int) $_GET['user_id']; // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- Nothing on the site is changed in response to this request. - - return true; - } - - /** - * Checks if recovery key is valid. - * - * @param string $key - they recovery key. - * @param string $user_id - the User ID. - */ - public function is_valid_protect_recovery_key( $key, $user_id ) { - - $path = sprintf( '/sites/%d/protect/recovery/confirm', Jetpack_Options::get_option( 'id' ) ); - $response = Client::wpcom_json_api_request_as_blog( - $path, - '1.1', - array( - 'method' => 'post', - ), - array( - 'token' => $key, - 'user_id' => $user_id, - 'ip' => $this->ip_address, - ) - ); - - $result = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( is_wp_error( $result ) || empty( $result ) || isset( $result->error ) ) { - return false; - } - - return true; - } - - /** - * Check if we should render the recovery form. - */ - public function render_and_die() { - if ( ! $this->can_send_recovery_emails ) { - $this->render_blocked_login_message(); - - return; - } - - if ( isset( $_GET['validate_jetpack_protect_recovery'] ) && ! empty( $_GET['user_id'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- no site changes, just throws invalid token error. - $error = new WP_Error( 'invalid_token', __( "Oops, we couldn't validate the recovery token.", 'jetpack-waf' ) ); - $this->protect_die( $error ); - - return; - } - - if ( - isset( $_GET['jetpack-protect-recovery'] ) && - isset( $_POST['_wpnonce'] ) && - wp_verify_nonce( $_POST['_wpnonce'], 'bypass-protect' ) // phpcs:ignore WordPress.Security.ValidatedSanitizedInput -- WP Core doesn't unstrip or sanitize nonces either. - ) { - $this->process_recovery_email(); - - return; - } - - if ( isset( $_GET['loggedout'] ) && 'true' === $_GET['loggedout'] ) { - $this->protect_die( __( 'You successfully logged out.', 'jetpack-waf' ) ); - } - - $this->render_recovery_form(); - } - - /** - * Render the blocked login message. - */ - public function render_blocked_login_message() { - $this->protect_die( $this->get_html_blocked_login_message() ); - } - - /** - * Process sending a recovery email. - */ - public function process_recovery_email() { - $sent = $this->send_recovery_email(); - $show_recovery_form = true; - if ( is_wp_error( $sent ) ) { - if ( 'email_already_sent' === $sent->get_error_code() ) { - $show_recovery_form = false; - } - $this->protect_die( $sent, null, true, $show_recovery_form ); - } else { - $this->render_recovery_success(); - } - } - - /** - * Send the recovery form. - */ - public function send_recovery_email() { - $email = isset( $_POST['email'] ) ? wp_unslash( $_POST['email'] ) : ''; // phpcs:ignore WordPress.Security.NonceVerification.Missing, WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- only triggered after bypass-protect nonce check is done, and sanitization is checked on the next line. - if ( sanitize_email( $email ) !== $email || ! is_email( $email ) ) { - return new WP_Error( 'invalid_email', __( "Oops, looks like that's not the right email address. Please try again!", 'jetpack-waf' ) ); - } - $user = get_user_by( 'email', trim( $email ) ); - - if ( ! $user ) { - return new WP_Error( 'invalid_user', __( "Oops, we couldn't find a user with that email. Please try again!", 'jetpack-waf' ) ); - } - $this->email_address = $email; - $path = sprintf( '/sites/%d/protect/recovery/request', Jetpack_Options::get_option( 'id' ) ); - - $response = Client::wpcom_json_api_request_as_blog( - $path, - '1.1', - array( - 'method' => 'post', - ), - array( - 'user_id' => $user->ID, - 'ip' => $this->ip_address, - ) - ); - - $code = wp_remote_retrieve_response_code( $response ); - $result = json_decode( wp_remote_retrieve_body( $response ) ); - - if ( self::HTTP_STATUS_CODE_TOO_MANY_REQUESTS === $code ) { - // translators: email address the recovery instructions were sent to. - return new WP_Error( 'email_already_sent', sprintf( __( 'Recovery instructions were sent to %s. Check your inbox!', 'jetpack-waf' ), esc_html( $this->email_address ) ) ); - } elseif ( is_wp_error( $result ) || empty( $result ) || isset( $result->error ) ) { - return new WP_Error( 'email_send_error', __( 'Oops, we were unable to send a recovery email. Try again.', 'jetpack-waf' ) ); - } - - return true; - } - - /** - * Prevent login by locking the login page. - * - * @param string $content - the content of the page. - * @param string $title - the page title. - * @param string $back_link - the back link. - * @param string $recovery_form - the recovery form. - */ - public function protect_die( $content, $title = null, $back_link = false, $recovery_form = false ) { - if ( empty( $title ) ) { - $title = __( 'Jetpack has locked your site\'s login page.', 'jetpack-waf' ); - } - if ( is_wp_error( $content ) ) { - $svg = ''; - $content = ' ' . $svg . $content->get_error_message() . ''; - } - $content = '

            ' . $content . '

            '; - - // If for some reason the login pop up box show up in the wp-admin. - if ( isset( $_GET['interim-login'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- no changes to the site itself, just rendering an error message. - $content = '' . $content; - } - $this->display_page( $title, $content, $back_link, $recovery_form ); - } - - /** - * Render the recovery form. - */ - public function render_recovery_form() { - $content = $this->get_html_blocked_login_message(); - $this->protect_die( $content, null, null, true ); - } - - /** - * Render the recovery instructions. - */ - public function render_recovery_success() { - // translators: the email address the recovery email was sent to. - $this->protect_die( sprintf( __( 'Recovery instructions were sent to %s. Check your inbox!', 'jetpack-waf' ), $this->email_address ) ); - } - - /** - * Get the HTML for the blocked login message. - */ - public function get_html_blocked_login_message() { - $icon = ''; - $ip = str_replace( 'http://', '', esc_url( 'http://' . $this->ip_address ) ); - return sprintf( - // translators: the IP address that was flagged. - __( '

            Your IP address %2$s has been flagged for potential security violations. You can unlock your login by sending yourself a special link via email. Learn More

            ', 'jetpack-waf' ), // phpcs:ignore WordPress.WP.I18n.NoHtmlWrappedStrings - $icon, - $ip, - esc_url( self::get_help_url() ) - ); - } - - /** - * Get the HTML recovery form. - */ - public function get_html_recovery_form() { - ob_start(); ?> -
            -
            - -

            - - -

            -
            -
            - - - - - > - - - - \n"; - } else { - echo "\n"; - } - ?> - <?php echo esc_html( $title ); ?> - - - > -

            -
            - - - - - - - - - - - - - - - - - - - - - - - - - - - get_html_recovery_form(); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- content is escaped in the function. - } - ?> -
            - - - - get_transient( 'jpp_math_pass_' . sanitize_key( $_COOKIE['jpp_math_pass'] ) ); - - if ( ! $transient || $transient < 1 ) { - self::generate_math_page(); - } - return true; - } - - $ans = isset( $_POST['jetpack_protect_num'] ) ? (int) $_POST['jetpack_protect_num'] : ''; // phpcs:ignore WordPress.Security.NonceVerification.Missing -- answers are salted. - $correct_ans = isset( $_POST['jetpack_protect_answer'] ) ? sanitize_key( $_POST['jetpack_protect_answer'] ) : ''; // phpcs:ignore WordPress.Security.NonceVerification.Missing - - $time_window = self::time_window(); - $salt = get_site_option( 'jetpack_protect_key' ) . '|' . get_site_option( 'admin_email' ) . '|'; - $salted_ans_1 = hash_hmac( 'sha1', $ans, $salt . $time_window ); - $salted_ans_2 = hash_hmac( 'sha1', $ans, $salt . ( $time_window - 1 ) ); - - if ( ! $correct_ans || ! $ans ) { - self::generate_math_page(); - } elseif ( ! hash_equals( $salted_ans_1, $correct_ans ) && ! hash_equals( $salted_ans_2, $correct_ans ) ) { - wp_die( - wp_kses( - __( - 'You failed to correctly answer the math problem. This is used to combat spam when Jetpack’s Brute Force Attack Protection API is unavailable. Please use your browser’s back button to return to the login form, press the "refresh" button to generate a new math problem, and try to log in again.', - 'jetpack-waf' - ), - array( 'strong' => array() ) - ), - '', - array( 'response' => 401 ) - ); - } else { - return true; - } - } - - /** - * Creates an interim page to collect answers to a math captcha - * - * @param string $error - the error message. - * @return never - */ - public static function generate_math_page( $error = false ) { - ob_start(); - ?> -

            - -

            - - -
            - - -

            -
            - 401 ) - ); - } - - /** - * Generates the math page. - */ - public function process_generate_math_page() { - $ans = isset( $_POST['jetpack_protect_num'] ) ? (int) $_POST['jetpack_protect_num'] : ''; // phpcs:ignore WordPress.Security.NonceVerification.Missing -- answers are salted. - $correct_ans = isset( $_POST['jetpack_protect_answer'] ) ? sanitize_key( $_POST['jetpack_protect_answer'] ) : ''; // phpcs:ignore WordPress.Security.NonceVerification.Missing - - $time_window = self::time_window(); - $salt = get_site_option( 'jetpack_protect_key' ) . '|' . get_site_option( 'admin_email' ) . '|'; - $salted_ans_1 = hash_hmac( 'sha1', $ans, $salt . $time_window ); - $salted_ans_2 = hash_hmac( 'sha1', $ans, $salt . ( $time_window - 1 ) ); - - if ( ! hash_equals( $salted_ans_1, $correct_ans ) && ! hash_equals( $salted_ans_2, $correct_ans ) ) { - self::generate_math_page( true ); - } else { - $temp_pass = substr( hash_hmac( 'sha1', wp_rand( 1, 100000000 ), get_site_option( 'jetpack_protect_key' ) ), 5, 25 ); - - $brute_force_protection = Brute_Force_Protection::instance(); - $brute_force_protection->set_transient( 'jpp_math_pass_' . $temp_pass, 3, DAY_IN_SECONDS ); - setcookie( 'jpp_math_pass', $temp_pass, time() + DAY_IN_SECONDS, COOKIEPATH, COOKIE_DOMAIN, false, true ); - remove_action( 'login_form', array( $this, 'math_form' ) ); - return true; - } - } - - /** - * Requires a user to solve a simple equation. Added to any WordPress login form. - * - * @return VOID outputs html - */ - public static function math_form() { - // Check if jpp_math_pass cookie is set and it matches valid transient. - if ( isset( $_COOKIE['jpp_math_pass'] ) ) { - $brute_force_protection = Brute_Force_Protection::instance(); - $transient = $brute_force_protection->get_transient( 'jpp_math_pass_' . sanitize_key( $_COOKIE['jpp_math_pass'] ) ); - - if ( $transient && $transient > 0 ) { - return ''; - } - } - - $num1 = wp_rand( 0, 10 ); - $num2 = wp_rand( 1, 10 ); - $ans = $num1 + $num2; - - $time_window = self::time_window(); - $salt = get_site_option( 'jetpack_protect_key' ) . '|' . get_site_option( 'admin_email' ) . '|'; - $salted_ans = hash_hmac( 'sha1', $ans, $salt . $time_window ); - ?> -
            -

            - -

            -
            - - - -
            - array(), - ); - foreach ( $local_allow_list as $item ) { - if ( $item->range ) { - $formatted['local'][] = $item->range_low . ' - ' . $item->range_high; - } else { - $formatted['local'][] = $item->ip_address; - } - } - if ( is_multisite() && current_user_can( 'manage_network' ) ) { - $formatted['global'] = array(); - $global_allow_list = self::get_global_allow_list(); - if ( false === $global_allow_list ) { - // If the global allow list has never been set, check for a legacy option set prior to 3.6. - $global_allow_list = get_site_option( 'jetpack_protect_whitelist', array() ); - } - foreach ( $global_allow_list as $item ) { - if ( $item->range ) { - $formatted['global'][] = $item->range_low . ' - ' . $item->range_high; - } else { - $formatted['global'][] = $item->ip_address; - } - } - } - return $formatted; - } - - /** - * Gets the local Brute force protection allow list. - * - * @deprecated 0.11.0 Use get_local_allow_list() - */ - public static function get_local_whitelist() { - _deprecated_function( __METHOD__, 'waf-0.11.0', __CLASS__ . '::get_local_allow_list' ); - return self::get_local_allow_list(); - } - - /** - * Gets the local Brute force protection allow list. - * - * The 'local' part of the allow list only really applies to multisite installs, - * which can have a network wide allow list, as well as a local list that applies - * only to the current site. On single site installs, there will only be a local - * allow list. - * - * @return array A list of IP Address objects or an empty array - */ - public static function get_local_allow_list() { - $allow_list = get_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ); - if ( false === $allow_list ) { - // The local allow list has never been set. - if ( is_multisite() ) { - // On a multisite, we can check for a legacy site_option that existed prior to v 3.6, or default to an empty array. - $allow_list = get_site_option( 'jetpack_protect_whitelist', array() ); - } else { - // On a single site, we can just use an empty array. - $allow_list = array(); - } - } else { - $allow_list = IP_Utils::get_ip_addresses_from_string( $allow_list ); - $allow_list = array_map( - function ( $ip_address ) { - return self::create_ip_object( $ip_address ); - }, - $allow_list - ); - } - return $allow_list; - } - - /** - * Get the global, network-wide allow list. - * - * @deprecated 0.11.0 Use get_global_allow_list() - */ - public static function get_global_whitelist() { - _deprecated_function( __METHOD__, 'waf-0.11.0', __CLASS__ . '::get_global_allow_list' ); - return self::get_global_allow_list(); - } - - /** - * Get the global, network-wide allow list. - * - * It will revert to the legacy site_option if jetpack_protect_global_whitelist has never been set. - * - * @return array - */ - public static function get_global_allow_list() { - $allow_list = get_site_option( 'jetpack_protect_global_whitelist' ); - if ( false === $allow_list ) { - // The global allow list has never been set. Check for legacy site_option, or default to an empty array. - $allow_list = get_site_option( 'jetpack_protect_whitelist', array() ); - } - return $allow_list; - } - - /** - * Convert a string into an IP Address object. - * - * @param string $ip_address The IP Address to convert. - * @return object An IP Address object. - */ - private static function create_ip_object( $ip_address ) { - // Hyphenated range notation. - if ( strpos( $ip_address, '-' ) ) { - $ip_range_parts = explode( '-', $ip_address ); - return (object) array( - 'range' => true, - 'range_low' => trim( $ip_range_parts[0] ), - 'range_high' => trim( $ip_range_parts[1] ), - ); - } - - // CIDR notation. - if ( strpos( $ip_address, '/' ) !== false ) { - return (object) array( - 'range' => true, - 'range_low' => $ip_address, - 'range_high' => null, - ); - } - - // Single IP Address. - return (object) array( - 'range' => false, - 'ip_address' => $ip_address, - ); - } - - /** - * Save IP allow list. - * - * @deprecated 0.11.0 Use save_allow_list() - * - * @param mixed $allow_list IP allow list. - * @param bool $global (default: false) Global. - */ - public static function save_whitelist( $allow_list, $global = false ) { - _deprecated_function( __METHOD__, 'waf-0.11.0', __CLASS__ . '::save_allow_list' ); - return self::save_allow_list( $allow_list, $global ); - } - - /** - * Save IP allow list. - * - * @access public - * @param mixed $allow_list IP allow list. - * @param bool $global (default: false) Global. - * @return bool - */ - public static function save_allow_list( $allow_list, $global = false ) { - $allow_list_error = false; - $new_items = array(); - if ( ! is_array( $allow_list ) ) { - return new WP_Error( 'invalid_parameters', __( 'Expecting an array', 'jetpack-waf' ) ); - } - if ( $global && ! is_multisite() ) { - return new WP_Error( 'invalid_parameters', __( 'Cannot use global flag on non-multisites', 'jetpack-waf' ) ); - } - if ( $global && ! current_user_can( 'manage_network' ) ) { - return new WP_Error( 'permission_denied', __( 'Only super admins can edit the global allow list', 'jetpack-waf' ) ); - } - // Validate each item. - foreach ( $allow_list as $item ) { - $item = trim( $item ); - if ( empty( $item ) ) { - continue; - } - $new_item = self::create_ip_object( $item ); - if ( $new_item->range ) { - if ( ! filter_var( $new_item->range_low, FILTER_VALIDATE_IP ) || ! filter_var( $new_item->range_high, FILTER_VALIDATE_IP ) ) { - $allow_list_error = true; - break; - } - if ( ! IP_Utils::convert_ip_address( $new_item->range_low ) || ! IP_Utils::convert_ip_address( $new_item->range_high ) ) { - $allow_list_error = true; - break; - } - } else { - if ( ! filter_var( $new_item->ip_address, FILTER_VALIDATE_IP ) ) { - $allow_list_error = true; - break; - } - if ( ! IP_Utils::convert_ip_address( $new_item->ip_address ) ) { - $allow_list_error = true; - break; - } - } - $new_items[] = $new_item; - } // End item loop. - if ( ! empty( $allow_list_error ) ) { - return new WP_Error( 'invalid_ip', __( 'One of your IP addresses was not valid.', 'jetpack-waf' ) ); - } - if ( $global ) { - update_site_option( 'jetpack_protect_global_whitelist', $new_items ); - // Once a user has saved their global allow list, we can permanently remove the legacy option. - delete_site_option( 'jetpack_protect_whitelist' ); - } else { - $new_items = array_map( - function ( $item ) { - if ( $item->range ) { - return $item->range_low . '-' . $item->range_high; - } - return $item->ip_address; - }, - $new_items - ); - update_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME, implode( ' ', $new_items ) ); - } - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php deleted file mode 100644 index ebd79e03..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php +++ /dev/null @@ -1,63 +0,0 @@ - time() || $older_than_time < 1 ) { - return false; - } - $sql = $wpdb->prepare( - // phpcs:ignore WordPress.DB.PreparedSQLPlaceholders.LikeWildcardsInQuery - "SELECT REPLACE(option_name, '_transient_timeout_jpp_', '') AS transient_name FROM {$wpdb->options} WHERE option_name LIKE '\_transient\_timeout\_jpp\__%%' AND option_value < %d", - $older_than_time - ); - $transients = $wpdb->get_col( $sql ); // phpcs:ignore WordPress.DB -- $sql is prepared above. - $options_names = array(); - foreach ( $transients as $transient ) { - $options_names[] = '_transient_jpp_' . $transient; - $options_names[] = '_transient_timeout_jpp_' . $transient; - } - if ( $options_names ) { - $option_names_string = implode( ', ', array_fill( 0, count( $options_names ), '%s' ) ); - $result = $wpdb->query( // phpcs:ignore WordPress.DB.DirectDatabaseQuery - $wpdb->prepare( - "DELETE FROM {$wpdb->options} WHERE option_name IN ($option_names_string)", // phpcs:ignore WordPress.DB.PreparedSQL.InterpolatedNotPrepared,WordPress.DB.PreparedSQLPlaceholders.UnfinishedPrepare -- the placeholders are set above. - $options_names - ) - ); - if ( ! $result ) { - return false; - } - } - } - - /** - * Jetpack Purge Transients Activation. - * - * @access public - * @return void - */ - public static function jp_purge_transients_activation() { - if ( ! wp_next_scheduled( 'jp_purge_transients_cron' ) ) { - wp_schedule_event( time(), 'daily', 'jp_purge_transients_cron' ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php deleted file mode 100644 index b91161d3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php +++ /dev/null @@ -1,1175 +0,0 @@ -is_connected() ) { - global $pagenow; - $brute_force_protection = self::instance(); - - if ( isset( $pagenow ) && 'wp-login.php' === $pagenow ) { - $brute_force_protection->check_login_ability(); - } - } - } - - /** - * On module activation, try to get an api key - */ - public function on_activation() { - if ( is_multisite() && is_main_site() && get_site_option( 'jetpack_protect_active', 0 ) == 0 ) { // phpcs:ignore Universal.Operators.StrictComparisons.LooseEqual - update_site_option( 'jetpack_protect_active', 1 ); - } - - update_site_option( 'jetpack_protect_activating', 'activating' ); - - // Get BruteProtect's counter number. - $this->protect_call( 'check_key' ); - } - - /** - * On module deactivation, unset protect_active - */ - public function on_deactivation() { - if ( is_multisite() && is_main_site() ) { - update_site_option( 'jetpack_protect_active', 0 ); - } - } - - /** - * Determines if the brute force protection module is enabled on the site. - * - * @return bool - */ - public static function is_enabled() { - return ( new Modules() )->is_active( 'protect' ); - } - - /** - * Enables the brute force protection module. - * - * @return bool - */ - public static function enable() { - // Return true if already enabled. - if ( self::is_enabled() ) { - return true; - } - return ( new Modules() )->activate( 'protect', false, false ); - } - - /** - * Disables the brute force protection module. - * - * @return bool - */ - public static function disable() { - // Return true if already disabled. - if ( ! self::is_enabled() ) { - return true; - } - return ( new Modules() )->deactivate( 'protect' ); - } - - /** - * Get the protect key, - */ - public function maybe_get_protect_key() { - if ( get_site_option( 'jetpack_protect_activating', false ) && ! get_site_option( 'jetpack_protect_key', false ) ) { - $key = $this->get_protect_key(); - delete_site_option( 'jetpack_protect_activating' ); - return $key; - } - - return get_site_option( 'jetpack_protect_key' ); - } - - /** - * Sends a "check_key" API call once a day. This call allows us to track IP-related - * headers for this server via the Protect API, in order to better identify the source - * IP for login attempts - * - * @param bool $force - if we're forcing the request. - */ - public function maybe_update_headers( $force = false ) { - $updated_recently = $this->get_transient( 'jpp_headers_updated_recently' ); - - if ( ! $force ) { - if ( isset( $_GET['protect_update_headers'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Recommended -- this doesn't change anything, just forces the once-a-day check to run via force if set. - $force = true; - } - } - - // check that current user is admin so we prevent a lower level user from adding - // a trusted header, allowing them to brute force an admin account. - if ( ( $updated_recently && ! $force ) || ! current_user_can( 'update_plugins' ) ) { - return; - } - - $response = self::protect_call( 'check_key' ); - $this->set_transient( 'jpp_headers_updated_recently', 1, DAY_IN_SECONDS ); - - if ( isset( $response['msg'] ) && $response['msg'] ) { - update_site_option( 'trusted_ip_header', json_decode( $response['msg'] ) ); - } - } - - /** - * Handle displaying a security warning. - */ - public function maybe_display_security_warning() { - if ( is_multisite() && current_user_can( 'manage_network' ) ) { - if ( ! function_exists( 'is_plugin_active_for_network' ) ) { - require_once ABSPATH . '/wp-admin/includes/plugin.php'; - } - - // This warning is only relevant if either Jetpack or Jetpack Protect is active. - if ( defined( 'JETPACK__PLUGIN_FILE' ) ) { - $plugin_root_file = JETPACK__PLUGIN_FILE; - } elseif ( defined( 'JETPACK_PROTECT_ROOT_FILE' ) ) { - $plugin_root_file = JETPACK_PROTECT_ROOT_FILE; - } else { - return; - } - - if ( ! is_plugin_active_for_network( plugin_basename( $plugin_root_file ) ) ) { - add_action( 'load-index.php', array( $this, 'prepare_jetpack_protect_multisite_notice' ) ); - add_action( 'wp_ajax_jetpack-protect-dismiss-multisite-banner', array( $this, 'ajax_dismiss_handler' ) ); - } - } - } - - /** - * Handles preparing the multisite notice. - */ - public function prepare_jetpack_protect_multisite_notice() { - $dismissed = get_site_option( 'jetpack_dismissed_protect_multisite_banner' ); - if ( $dismissed ) { - return; - } - - add_action( 'admin_notices', array( $this, 'admin_jetpack_manage_notice' ) ); - } - - /** - * Handle dismissing the multisite banner. - */ - public function ajax_dismiss_handler() { - check_ajax_referer( 'jetpack_protect_multisite_banner_opt_out' ); - - if ( ! current_user_can( 'manage_network' ) ) { - wp_send_json_error( new WP_Error( 'insufficient_permissions' ) ); - } - - update_site_option( 'jetpack_dismissed_protect_multisite_banner', true ); - - wp_send_json_success(); - } - - /** - * Displays a warning about Brute Force Protection's network activation requirement. - * Attaches some custom JS to Core's `is-dismissible` UI to save the dismissed state. - */ - public function admin_jetpack_manage_notice() { - ?> -
            -

            - -

            - -

            - -

            - - - - - - -

            -
            - - api_key_error = __( 'Your main blog is not connected to WordPress.com. Please connect to get an API key.', 'jetpack-waf' ); - - return false; - } - - $request = array( - 'jetpack_blog_id' => $protect_blog_id, - 'bruteprotect_api_key' => get_site_option( 'bruteprotect_api_key' ), - 'multisite' => '0', - ); - - // Send the number of blogs on the network if we are on multisite. - if ( is_multisite() ) { - $request['multisite'] = get_blog_count(); - if ( ! $request['multisite'] ) { - global $wpdb; - $request['multisite'] = $wpdb->get_var( "SELECT COUNT(blog_id) as c FROM $wpdb->blogs WHERE spam = '0' AND deleted = '0' and archived = '0'" ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery - } - } - - // Request the key. - $xml = new Jetpack_IXR_Client(); - $xml->query( 'jetpack.protect.requestKey', $request ); - - // Hmm, can't talk to wordpress.com. - if ( $xml->isError() ) { - $code = $xml->getErrorCode(); - $message = $xml->getErrorMessage(); - // Translators: The xml error code, and the xml error message. - $this->api_key_error = sprintf( __( 'Error connecting to WordPress.com. Code: %1$s, %2$s', 'jetpack-waf' ), $code, $message ); - - return false; - } - - $response = $xml->getResponse(); - - // Hmm, can't talk to the protect servers ( api.bruteprotect.com ). - if ( ! isset( $response['data'] ) ) { - $this->api_key_error = __( 'No reply from Jetpack servers', 'jetpack-waf' ); - - return false; - } - - // There was an issue generating the key. - if ( empty( $response['success'] ) ) { - $this->api_key_error = $response['data']; - - return false; - } - - // Key generation successful! - $active_plugins = self::get_active_plugins(); - - // We only want to deactivate BruteProtect if we successfully get a key. - if ( in_array( 'bruteprotect/bruteprotect.php', $active_plugins, true ) ) { - self::deactivate_plugin( 'bruteprotect/bruteprotect.php', 'BruteProtect' ); - } - - $key = $response['data']; - update_site_option( 'jetpack_protect_key', $key ); - - return $key; - } - - /** - * Called via WP action wp_login_failed to log failed attempt with the api - * - * Fires custom, plugable action jpp_log_failed_attempt with the IP - * - * @param string $login_user - the user attempting to log in. - * @return void - */ - public function log_failed_attempt( $login_user = null ) { - - /** - * Fires before every failed login attempt. - * - * @module protect - * - * @since 3.4.0 - * - * @param array Information about failed login attempt - * [ - * 'login' => (string) Username or email used in failed login attempt - * ] - */ - do_action( 'jpp_log_failed_attempt', array( 'login' => $login_user ) ); - - if ( isset( $_COOKIE['jpp_math_pass'] ) ) { - - $transient = $this->get_transient( 'jpp_math_pass_' . sanitize_key( $_COOKIE['jpp_math_pass'] ) ); - --$transient; - - if ( ! $transient || $transient < 1 ) { - $this->delete_transient( 'jpp_math_pass_' . sanitize_key( $_COOKIE['jpp_math_pass'] ) ); - setcookie( 'jpp_math_pass', 0, time() - DAY_IN_SECONDS, COOKIEPATH, COOKIE_DOMAIN, false, true ); - } else { - $this->set_transient( 'jpp_math_pass_' . sanitize_key( $_COOKIE['jpp_math_pass'] ), $transient, DAY_IN_SECONDS ); - } - } - $this->protect_call( 'failed_attempt' ); - } - - /** - * Set up the Brute Force Protection configuration page - */ - public function modules_loaded() { - add_filter( 'jetpack_module_configurable_protect', '__return_true' ); - } - - /** - * Logs a successful login back to our servers, this allows us to make sure we're not blocking - * a busy IP that has a lot of good logins along with some forgotten passwords. Also saves current user's ip - * to the ip address allow list - * - * @param string $user_login - the user loggign in. - * @param string $user - the user. - */ - public function log_successful_login( $user_login, $user = null ) { - if ( ! $user ) { // For do_action( 'wp_login' ) calls that lacked passing the 2nd arg. - $user = get_user_by( 'login', $user_login ); - } - - $this->protect_call( 'successful_login', array( 'roles' => $user->roles ) ); - } - - /** - * Checks for loginability BEFORE authentication so that bots don't get to go around the log in form. - * - * If we are using our math fallback, authenticate via math-fallback.php - * - * @param string $user - the user. - * @param string $username - the username. - * @param string $password - the password. - * - * @return string $user - */ - public function check_preauth( $user = 'Not Used By Protect', $username = 'Not Used By Protect', $password = 'Not Used By Protect' ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - $allow_login = $this->check_login_ability( true ); - $use_math = $this->get_transient( 'brute_use_math' ); - - if ( ! $allow_login ) { - $this->block_with_math(); - } - - if ( ( 1 == $use_math || 1 == $this->block_login_with_math ) && isset( $_POST['log'] ) ) { // phpcs:ignore Universal.Operators.StrictComparisons.LooseEqual, WordPress.Security.NonceVerification.Missing -- POST request just determines if we use math authentication. - - Brute_Force_Protection_Math_Authenticate::math_authenticate(); - } - - return $user; - } - - /** - * Get all IP headers so that we can process on our server... - * - * @return array - */ - public function get_headers() { - $output = array(); - $ip_related_headers = array( - 'GD_PHP_HANDLER', - 'HTTP_AKAMAI_ORIGIN_HOP', - 'HTTP_CF_CONNECTING_IP', - 'HTTP_CLIENT_IP', - 'HTTP_FASTLY_CLIENT_IP', - 'HTTP_FORWARDED', - 'HTTP_FORWARDED_FOR', - 'HTTP_INCAP_CLIENT_IP', - 'HTTP_TRUE_CLIENT_IP', - 'HTTP_X_CLIENTIP', - 'HTTP_X_CLUSTER_CLIENT_IP', - 'HTTP_X_FORWARDED', - 'HTTP_X_FORWARDED_FOR', - 'HTTP_X_IP_TRAIL', - 'HTTP_X_REAL_IP', - 'HTTP_X_VARNISH', - 'REMOTE_ADDR', - ); - - foreach ( $ip_related_headers as $header ) { - if ( ! empty( $_SERVER[ $header ] ) ) { - $output[ $header ] = wp_unslash( $_SERVER[ $header ] ); // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - } - } - - return $output; - } - - /** - * Whether or not the IP allow list is enabled. - * - * @return bool - */ - public static function ip_allow_list_enabled() { - return get_option( Waf_Rules_Manager::IP_ALLOW_LIST_ENABLED_OPTION_NAME, true ); - } - - /** - * Checks if the IP address is in the allow list. - * - * @deprecated 0.11.0 Use ip_is_allowed() - * - * @param string $ip - the IP address. - */ - public static function ip_is_whitelisted( $ip ) { - _deprecated_function( __METHOD__, 'waf-0.11.0', __CLASS__ . '::ip_is_allowed' ); - return self::ip_is_allowed( $ip ); - } - - /** - * Checks if the IP address is in the allow list. - * - * @param string $ip - the IP address. - * - * @return bool - */ - public function ip_is_allowed( $ip ) { - // If we found an exact match in wp-config. - if ( defined( 'JETPACK_IP_ADDRESS_OK' ) && JETPACK_IP_ADDRESS_OK === $ip ) { - return true; - } - - // Allow list must be enabled. - if ( ! $this->ip_allow_list_enabled() ) { - return false; - } - - $allow_list = Brute_Force_Protection_Shared_Functions::get_local_allow_list(); - - if ( is_multisite() ) { - $allow_list = array_merge( $allow_list, get_site_option( 'jetpack_protect_global_whitelist', array() ) ); - } - - if ( ! empty( $allow_list ) ) : - foreach ( $allow_list as $item ) : - // If the IPs are an exact match. - if ( ! $item->range && isset( $item->ip_address ) && $item->ip_address === $ip ) { - return true; - } - - if ( $item->range && isset( $item->range_low ) && isset( $item->range_high ) ) { - if ( IP_Utils::ip_address_is_in_range( $ip, $item->range_low, $item->range_high ) ) { - return true; - } - } - endforeach; - endif; - - return false; - } - - /** - * Checks the status for a given IP. API results are cached as transients - * - * @param bool $preauth - Whether or not we are checking prior to authorization. - * - * @return bool Either returns true, fires $this->kill_login, or includes a math fallback and returns false - */ - public function check_login_ability( $preauth = false ) { // phpcs:ignore VariableAnalysis.CodeAnalysis.VariableAnalysis.UnusedVariable - - /** - * JETPACK_ALWAYS_PROTECT_LOGIN will always disable the login page, and use a page provided by Jetpack. - */ - if ( Constants::is_true( 'JETPACK_ALWAYS_PROTECT_LOGIN' ) ) { - $this->kill_login(); - } - - if ( $this->is_current_ip_allowed() ) { - return true; - } - - $status = $this->get_cached_status(); - - if ( empty( $status ) ) { - // If we've reached this point, this means that the IP isn't cached. - // Now we check with the Protect API to see if we should allow login. - $response = $this->protect_call( $action = 'check_ip' ); // phpcs:ignore Squiz.PHP.DisallowMultipleAssignments.Found - - if ( isset( $response['math'] ) && ! function_exists( 'brute_math_authenticate' ) ) { - new Brute_Force_Protection_Math_Authenticate(); - - return false; - } - - $status = $response['status']; - } - - if ( 'blocked' === $status ) { - $this->block_with_math(); - } - - if ( 'blocked-hard' === $status ) { - $this->kill_login(); - } - - return true; - } - - /** - * Check if the user's IP is in the allow list. - * - * @deprecated 0.11.0 Use is_current_ip_allowed() - */ - public static function is_current_ip_whitelisted() { - _deprecated_function( __METHOD__, 'waf-0.11.0', __CLASS__ . '::is_current_ip_allowed' ); - return self::is_current_ip_allowed(); - } - - /** - * Check if the user's IP is in the allow list. - */ - public function is_current_ip_allowed() { - $ip = IP_Utils::get_ip(); - - // Server is misconfigured and we can't get an IP. - if ( ! $ip ) { - self::disable(); - ob_start(); - ( new CookieState() )->state( 'message', 'protect_misconfigured_ip' ); - ob_end_clean(); - return true; - } - - /** - * Short-circuit check_login_ability. - * - * If there is an alternate way to validate the current IP such as - * a hard-coded list of IP addresses, we can short-circuit the rest - * of the login ability checks and return true here. - * - * @module protect - * - * @since 4.4.0 - * - * @param bool false Should we allow all logins for the current ip? Default: false - */ - if ( apply_filters( 'jpp_allow_login', false, $ip ) ) { - return true; - } - - if ( IP_Utils::ip_is_private( $ip ) ) { - return true; - } - - if ( $this->ip_is_allowed( $ip ) ) { - return true; - } - } - - /** - * Check if someone is able to login based on IP. - */ - public function has_login_ability() { - if ( $this->is_current_ip_allowed() ) { - return true; - } - $status = $this->get_cached_status(); - if ( empty( $status ) || 'ok' === $status ) { - return true; - } - return false; - } - - /** - * Check the status of the cached transient. - */ - public function get_cached_status() { - $transient_name = $this->get_transient_name(); - $value = $this->get_transient( $transient_name ); - if ( isset( $value['status'] ) ) { - return $value['status']; - } - return ''; - } - - /** - * Check if we need to block with a math question to continue logging in. - */ - public function block_with_math() { - /** - * By default, Protect will allow a user who has been blocked for too - * many failed logins to start answering math questions to continue logging in - * - * For added security, you can disable this. - * - * @module protect - * - * @since 3.6.0 - * - * @param bool Whether to allow math for blocked users or not. - */ - - $this->block_login_with_math = 1; - /** - * Allow Math fallback for blocked IPs. - * - * @module protect - * - * @since 3.6.0 - * - * @param bool true Should we fallback to the Math questions when an IP is blocked. Default to true. - */ - $allow_math_fallback_on_fail = apply_filters( 'jpp_use_captcha_when_blocked', true ); - if ( ! $allow_math_fallback_on_fail ) { - $this->kill_login(); - } - - new Brute_Force_Protection_Math_Authenticate(); - - return false; - } - - /** - * Kill a login attempt - */ - public function kill_login() { - if ( - isset( $_GET['action'] ) && isset( $_GET['_wpnonce'] ) && - 'logout' === $_GET['action'] && - wp_verify_nonce( $_GET['_wpnonce'], 'log-out' ) && // phpcs:ignore WordPress.Security.ValidatedSanitizedInput - wp_get_current_user() - - ) { - // Allow users to logout. - return; - } - - $ip = IP_Utils::get_ip(); - /** - * Fires before every killed login. - * - * @module protect - * - * @since 3.4.0 - * - * @param string $ip IP flagged by Protect. - */ - do_action( 'jpp_kill_login', $ip ); - - if ( defined( 'XMLRPC_REQUEST' ) && XMLRPC_REQUEST ) { - // translators: variable is the IP address that was flagged. - $die_string = sprintf( __( 'Your IP (%1$s) has been flagged for potential security violations.', 'jetpack-waf' ), str_replace( 'http://', '', esc_url( 'http://' . $ip ) ) ); - wp_die( - $die_string, // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- esc_url used when forming string. - esc_html__( 'Login Blocked by Jetpack', 'jetpack-waf' ), - array( 'response' => 403 ) - ); - } - - $blocked_login_page = Brute_Force_Protection_Blocked_Login_Page::instance( $ip ); - - if ( $blocked_login_page->is_blocked_user_valid() ) { - return; - } - - $blocked_login_page->render_and_die(); - } - - /** - * Checks if the protect API call has failed, and if so initiates the math captcha fallback. - */ - public function check_use_math() { - $use_math = $this->get_transient( 'brute_use_math' ); - if ( $use_math ) { - new Brute_Force_Protection_Math_Authenticate(); - } - } - - /** - * If we're in a multisite network, return the blog ID of the primary blog - * - * @return int - */ - public function get_main_blog_id() { - if ( ! is_multisite() ) { - return false; - } - - global $current_site; - $primary_blog_id = $current_site->blog_id; - - return $primary_blog_id; - } - - /** - * Get jetpack blog id, or the jetpack blog id of the main blog in the main network - * - * @return int - */ - public function get_main_blog_jetpack_id() { - if ( ! is_main_site() ) { - switch_to_blog( $this->get_main_blog_id() ); - $id = Jetpack_Options::get_option( 'id', false ); - restore_current_blog(); - } else { - $id = Jetpack_Options::get_option( 'id' ); - } - - return $id; - } - - /** - * Checks the API key. - */ - public function check_api_key() { - $response = $this->protect_call( 'check_key' ); - - if ( isset( $response['ckval'] ) ) { - return true; - } - - if ( isset( $response['error'] ) ) { - - if ( 'Invalid API Key' === $response['error'] ) { - $this->api_key_error = __( 'Your API key is invalid', 'jetpack-waf' ); - } - - if ( 'API Key Required' === $response['error'] ) { - $this->api_key_error = __( 'No API key', 'jetpack-waf' ); - } - } - - $this->api_key_error = __( 'There was an error contacting Jetpack servers.', 'jetpack-waf' ); - - return false; - } - - /** - * Calls over to the api using wp_remote_post - * - * @param string $action - 'check_ip', 'check_key', or 'failed_attempt'. - * @param array $request - Any custom data to post to the api. - * - * @return array - */ - public function protect_call( $action = 'check_ip', $request = array() ) { - global $wp_version; - - $api_key = $this->maybe_get_protect_key(); - - $user_agent = "WordPress/{$wp_version}"; - - $request['action'] = $action; - $request['ip'] = IP_Utils::get_ip(); - $request['host'] = $this->get_local_host(); - $request['headers'] = wp_json_encode( $this->get_headers() ); - $request['jetpack_version'] = null; - $request['wordpress_version'] = (string) $wp_version; - $request['api_key'] = $api_key; - $request['multisite'] = '0'; - - if ( defined( 'JETPACK__VERSION' ) ) { - $request['jetpack_version'] = constant( 'JETPACK__VERSION' ); - $user_agent .= ' | Jetpack/' . constant( 'JETPACK__VERSION' ); - } - - if ( defined( 'JETPACK_PROTECT_VERSION' ) && ! defined( 'JETPACK__VERSION' ) ) { - $request['jetpack_version'] = '12.1'; - $user_agent .= ' | JetpackProtect/' . constant( 'JETPACK_PROTECT_VERSION' ); - } - - if ( is_multisite() ) { - $request['multisite'] = get_blog_count(); - } - - /** - * Filter controls maximum timeout in waiting for reponse from Protect servers. - * - * @module protect - * - * @since 4.0.4 - * - * @param int $timeout Max time (in seconds) to wait for a response. - */ - $timeout = apply_filters( 'jetpack_protect_connect_timeout', 30 ); - - $args = array( - 'body' => $request, - 'user-agent' => $user_agent, - 'httpversion' => '1.0', - 'timeout' => absint( $timeout ), - ); - - Waf_Constants::define_brute_force_api_host(); - - $response_json = wp_remote_post( JETPACK_PROTECT__API_HOST, $args ); - $this->last_response_raw = $response_json; - - $transient_name = $this->get_transient_name(); - $this->delete_transient( $transient_name ); - - if ( is_array( $response_json ) ) { - $response = json_decode( $response_json['body'], true ); - } - - if ( isset( $response['blocked_attempts'] ) && $response['blocked_attempts'] ) { - update_site_option( 'jetpack_protect_blocked_attempts', $response['blocked_attempts'] ); - } - - if ( isset( $response['status'] ) && ! isset( $response['error'] ) ) { - $response['expire'] = time() + $response['seconds_remaining']; - $this->set_transient( $transient_name, $response, $response['seconds_remaining'] ); - $this->delete_transient( 'brute_use_math' ); - } else { // Fallback to Math Captcha if no response from API host. - $this->set_transient( 'brute_use_math', 1, 600 ); - $response['status'] = 'ok'; - $response['math'] = true; - } - - if ( isset( $response['error'] ) ) { - update_site_option( 'jetpack_protect_error', $response['error'] ); - } else { - delete_site_option( 'jetpack_protect_error' ); - } - - return $response; - } - - /** - * Gets the transient name. - */ - public function get_transient_name() { - $headers = $this->get_headers(); - $header_hash = md5( wp_json_encode( $headers ) ); - - return 'jpp_li_' . $header_hash; - } - - /** - * Wrapper for WordPress set_transient function, our version sets - * the transient on the main site in the network if this is a multisite network - * - * We do it this way (instead of set_site_transient) because of an issue where - * sitewide transients are always autoloaded - * https://core.trac.wordpress.org/ticket/22846 - * - * @param string $transient Transient name. Expected to not be SQL-escaped. Must be - * 45 characters or fewer in length. - * @param mixed $value Transient value. Must be serializable if non-scalar. - * Expected to not be SQL-escaped. - * @param int $expiration Optional. Time until expiration in seconds. Default 0. - * - * @return bool False if value was not set and true if value was set. - */ - public function set_transient( $transient, $value, $expiration ) { - if ( is_multisite() && ! is_main_site() ) { - switch_to_blog( $this->get_main_blog_id() ); - $return = set_transient( $transient, $value, $expiration ); - restore_current_blog(); - - return $return; - } - - return set_transient( $transient, $value, $expiration ); - } - - /** - * Wrapper for WordPress delete_transient function, our version deletes - * the transient on the main site in the network if this is a multisite network - * - * @param string $transient Transient name. Expected to not be SQL-escaped. - * - * @return bool true if successful, false otherwise - */ - public function delete_transient( $transient ) { - if ( is_multisite() && ! is_main_site() ) { - switch_to_blog( $this->get_main_blog_id() ); - $return = delete_transient( $transient ); - restore_current_blog(); - - return $return; - } - - return delete_transient( $transient ); - } - - /** - * Wrapper for WordPress get_transient function, our version gets - * the transient on the main site in the network if this is a multisite network - * - * @param string $transient Transient name. Expected to not be SQL-escaped. - * - * @return mixed Value of transient. - */ - public function get_transient( $transient ) { - if ( is_multisite() && ! is_main_site() ) { - switch_to_blog( $this->get_main_blog_id() ); - $return = get_transient( $transient ); - restore_current_blog(); - - return $return; - } - - return get_transient( $transient ); - } - - /** - * Returns the local host. - */ - public function get_local_host() { - if ( isset( $this->local_host ) ) { - return $this->local_host; - } - - $uri = 'http://' . strtolower( isset( $_SERVER['HTTP_HOST'] ) ? filter_var( wp_unslash( $_SERVER['HTTP_HOST'] ) ) : '' ); - - if ( is_multisite() ) { - $uri = network_home_url(); - } - - $uridata = wp_parse_url( $uri ); - - $domain = $uridata['host']; - - // If we still don't have the site_url, get it. - if ( ! $domain ) { - $uri = get_site_url( 1 ); - $uridata = wp_parse_url( $uri ); - $domain = $uridata['host']; - } - - $this->local_host = $domain; - - return $this->local_host; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php deleted file mode 100644 index 495f71f9..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php +++ /dev/null @@ -1,328 +0,0 @@ -range ) ) { - return $ip_object->range_low . '-' . $ip_object->range_high; - } - - return $ip_object->ip_address; - }, - $brute_force_allow_list - ); - - $brute_force_allow_list_string = implode( "\n", $brute_force_allow_list ); - - if ( empty( $waf_allow_list ) ) { - return $brute_force_allow_list_string; - } - - // Return the lists merged into a single string. - return "$waf_allow_list\n$brute_force_allow_list_string"; - } - - /** - * Migrate the brute force protection IP allow list option to the WAF option. - * - * @since 0.11.0 - * - * @return void - */ - public static function migrate_brute_force_protection_ip_allow_list() { - // Get the allow list values directly from the database to avoid filters. - $brute_force_allow_list = Jetpack_Options::get_raw_option( 'jetpack_protect_whitelist' ); - $waf_allow_list = Jetpack_Options::get_raw_option( 'jetpack_waf_ip_allow_list' ); - - if ( ! empty( $brute_force_allow_list ) ) { - - if ( empty( $waf_allow_list ) ) { - $waf_allow_list = ''; - } - - // Merge the two allow lists. - $merged_allow_list = self::merge_ip_allow_lists( $waf_allow_list, $brute_force_allow_list ); - - // Update the WAF IP allow list with the merged list. - Jetpack_Options::update_raw_option( 'jetpack_waf_ip_allow_list', $merged_allow_list ); - - // Delete the old option if the update was successful. - // Check the values directly as `update_raw_option()` returns false if the value hasn't changed. - if ( Jetpack_Options::get_raw_option( 'jetpack_waf_ip_allow_list' ) === $merged_allow_list ) { - delete_option( 'jetpack_protect_whitelist' ); - } - } - } - - /** - * Filter for Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME's option value. - * Merges the deprecated IP allow list from the brute force protection module - * with the existing option value, and flags that the WAF needs to be updated. - * - * @since 0.11.0 - * - * @param array $waf_allow_list The current value of the option. - * - * @return array The merged IP allow list. - */ - public static function filter_option_waf_ip_allow_list( $waf_allow_list ) { - $brute_force_allow_list = Jetpack_Options::get_raw_option( 'jetpack_protect_whitelist', false ); - if ( false !== $brute_force_allow_list ) { - $waf_allow_list = self::merge_ip_allow_lists( $waf_allow_list, $brute_force_allow_list ); - update_option( Waf_Initializer::NEEDS_UPDATE_OPTION_NAME, true ); - } - - return $waf_allow_list; - } - - /** - * Default option for when the Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME option is not set. - * - * @param mixed $default The default value to return if the option does not exist in the database. - * @param string $option Option name. - * @param bool $passed_default Was get_option() passed a default value. - * - * @return mixed The default value to return if the option does not exist in the database. - */ - public static function default_option_waf_ip_allow_list( $default, $option, $passed_default ) { - // Allow get_option() to override this default value - if ( $passed_default ) { - return $default; - } - - $waf_allow_list = ''; - - // If the brute force option exists, use that and flag that the WAF needs to be updated. - $brute_force_allow_list = Jetpack_Options::get_raw_option( 'jetpack_protect_whitelist', false ); - if ( false !== $brute_force_allow_list ) { - $waf_allow_list = self::merge_ip_allow_lists( $waf_allow_list, $brute_force_allow_list ); - update_option( Waf_Initializer::NEEDS_UPDATE_OPTION_NAME, true ); - } - - return $waf_allow_list; - } - - /** - * Check if the brute force protection code is being run by an older version of Jetpack (< 12.0). - * - * @since 0.11.1 - * - * @return bool - */ - public static function is_brute_force_running_in_jetpack() { - return defined( 'JETPACK__VERSION' ) && version_compare( JETPACK__VERSION, '12', '<' ); - } - - /** - * Default the allow list enabled option to the value of the generic IP lists enabled option it replaced. - * - * @since 0.17.0 - * - * @param mixed $default The default value to return if the option does not exist in the database. - * @param string $option Option name. - * @param bool $passed_default Was get_option() passed a default value. - * - * @return mixed The default value to return if the option does not exist in the database. - */ - public static function default_option_waf_ip_allow_list_enabled( $default, $option, $passed_default ) { - // Allow get_option() to override this default value - if ( $passed_default ) { - return $default; - } - - // If the deprecated IP lists option was set to false, disable the allow list. - // @phan-suppress-next-line PhanDeprecatedClassConstant -- Needed for backwards compatibility. - $deprecated_option = Jetpack_Options::get_raw_option( Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME, true ); - if ( ! $deprecated_option ) { - return false; - } - - // If the allow list is empty, disable the allow list. - if ( ! Jetpack_Options::get_raw_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ) ) { - return false; - } - - // Default to enabling the allow list. - return true; - } - - /** - * Default the block list enabled option to the value of the generic IP lists enabled option it replaced. - * - * @since 0.17.0 - * - * @param mixed $default The default value to return if the option does not exist in the database. - * @param string $option Option name. - * @param bool $passed_default Was get_option() passed a default value. - * - * @return mixed The default value to return if the option does not exist in the database. - */ - public static function default_option_waf_ip_block_list_enabled( $default, $option, $passed_default ) { - // Allow get_option() to override this default value - if ( $passed_default ) { - return $default; - } - - // @phan-suppress-next-line PhanDeprecatedClassConstant -- Needed for backwards compatibility. - return Jetpack_Options::get_raw_option( Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME, false ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php deleted file mode 100644 index 6e7747e3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php +++ /dev/null @@ -1,212 +0,0 @@ - WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::waf', - 'permission_callback' => __CLASS__ . '::waf_permissions_callback', - ) - ); - - register_rest_route( - 'jetpack/v4', - '/waf', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::update_waf', - 'permission_callback' => __CLASS__ . '::waf_permissions_callback', - ) - ); - - register_rest_route( - 'jetpack/v4', - '/waf/update-rules', - array( - 'methods' => WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::update_rules', - 'permission_callback' => __CLASS__ . '::waf_permissions_callback', - ) - ); - - $routes_registered = true; - } - - /** - * Update rules endpoint - * - * @return WP_REST_Response|WP_Error - */ - public static function update_rules() { - try { - Waf_Rules_Manager::generate_automatic_rules(); - Waf_Rules_Manager::generate_rules(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - - return rest_ensure_response( - array( - 'success' => true, - 'message' => __( 'Rules updated succesfully', 'jetpack-waf' ), - ) - ); - } - - /** - * WAF Endpoint - * - * @return WP_REST_Response - */ - public static function waf() { - return rest_ensure_response( - array_merge( - Waf_Runner::get_config(), - array( - 'waf_supported' => Waf_Runner::is_supported_environment(), - 'automatic_rules_last_updated' => Waf_Stats::get_automatic_rules_last_updated(), - ) - ) - ); - } - - /** - * Update WAF Endpoint - * - * @param WP_REST_Request $request The API request. - * - * @return WP_REST_Response|WP_Error - */ - public static function update_waf( $request ) { - // Automatic Rules Enabled - if ( isset( $request[ Waf_Rules_Manager::AUTOMATIC_RULES_ENABLED_OPTION_NAME ] ) ) { - update_option( Waf_Rules_Manager::AUTOMATIC_RULES_ENABLED_OPTION_NAME, $request->get_param( Waf_Rules_Manager::AUTOMATIC_RULES_ENABLED_OPTION_NAME ) ? '1' : '' ); - } - - /** - * IP Lists Enabled - * - * @deprecated 0.17.0 This is a legacy option maintained here for backwards compatibility. - */ - if ( isset( $request['jetpack_waf_ip_list'] ) ) { - update_option( Waf_Rules_Manager::IP_BLOCK_LIST_ENABLED_OPTION_NAME, $request['jetpack_waf_ip_list'] ? '1' : '' ); - update_option( Waf_Rules_Manager::IP_ALLOW_LIST_ENABLED_OPTION_NAME, $request['jetpack_waf_ip_list'] ? '1' : '' ); - } - - // IP Block List - if ( isset( $request[ Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME ] ) ) { - update_option( Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME, $request[ Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME ] ); - } - if ( isset( $request[ Waf_Rules_Manager::IP_BLOCK_LIST_ENABLED_OPTION_NAME ] ) ) { - update_option( Waf_Rules_Manager::IP_BLOCK_LIST_ENABLED_OPTION_NAME, $request[ Waf_Rules_Manager::IP_BLOCK_LIST_ENABLED_OPTION_NAME ] ? '1' : '' ); - } - - // IP Allow List - if ( isset( $request[ Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ] ) ) { - update_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME, $request[ Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ] ); - } - if ( isset( $request[ Waf_Rules_Manager::IP_ALLOW_LIST_ENABLED_OPTION_NAME ] ) ) { - update_option( Waf_Rules_Manager::IP_ALLOW_LIST_ENABLED_OPTION_NAME, $request[ Waf_Rules_Manager::IP_ALLOW_LIST_ENABLED_OPTION_NAME ] ? '1' : '' ); - } - - // Share Data - if ( isset( $request[ Waf_Runner::SHARE_DATA_OPTION_NAME ] ) ) { - // If a user disabled the regular share we should disable the debug share data option. - if ( ! $request[ Waf_Runner::SHARE_DATA_OPTION_NAME ] ) { - update_option( Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME, '' ); - } - - update_option( Waf_Runner::SHARE_DATA_OPTION_NAME, $request[ Waf_Runner::SHARE_DATA_OPTION_NAME ] ? '1' : '' ); - } - - // Share Debug Data - if ( isset( $request[ Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME ] ) ) { - // If a user toggles the debug share we should enable the regular share data option. - if ( $request[ Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME ] ) { - update_option( Waf_Runner::SHARE_DATA_OPTION_NAME, 1 ); - } - - update_option( Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME, $request[ Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME ] ? '1' : '' ); - } - - // Brute Force Protection - if ( isset( $request['brute_force_protection'] ) ) { - $enable_brute_force = (bool) $request['brute_force_protection']; - $brute_force_protection_toggled = - $enable_brute_force - ? Brute_Force_Protection::enable() - : Brute_Force_Protection::disable(); - - if ( ! $brute_force_protection_toggled ) { - return new WP_Error( - $enable_brute_force - ? 'brute_force_protection_activation_failed' - : 'brute_force_protection_deactivation_failed', - $enable_brute_force - ? __( 'Brute force protection could not be activated.', 'jetpack-waf' ) - : __( 'Brute force protection could not be deactivated.', 'jetpack-waf' ), - array( 'status' => 500 ) - ); - } - } - - // Only attempt to update the WAF if the module is supported - if ( Waf_Runner::is_supported_environment() ) { - try { - Waf_Runner::update_waf(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - } - - return self::waf(); - } - - /** - * WAF Endpoint Permissions Callback - * - * @return bool|WP_Error True if user can view the Jetpack admin page. - */ - public static function waf_permissions_callback() { - if ( current_user_can( 'manage_options' ) ) { - return true; - } - - return new WP_Error( - 'invalid_user_permission_manage_options', - REST_Connector::get_user_permissions_error_msg(), - array( 'status' => rest_authorization_required_code() ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-blocklog-manager.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-blocklog-manager.php deleted file mode 100644 index 031c71ff..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-blocklog-manager.php +++ /dev/null @@ -1,441 +0,0 @@ -connect_error ) { - error_log( 'Could not connect to the database:' . $conn->connect_error ); - return null; - } - - self::$db_connection = $conn; - return self::$db_connection; - } - - /** - * Close the database connection. - * - * @return void - */ - private static function close_db_connection() { - if ( self::$db_connection ) { - self::$db_connection->close(); - self::$db_connection = null; - } - } - - /** - * Serialize a value for storage in a WordPress option. - * - * @param mixed $value The value to serialize. - * @return string The serialized value. - */ - private static function serialize_option_value( $value ) { - return serialize( $value ); - } - - /** - * Unserialize a value from a WordPress option. - * - * @param string $value The serialized value. - * @return mixed The unserialized value. - */ - private static function unserialize_option_value( string $value ) { - return unserialize( $value ); - } - - /** - * Create the log table when plugin is activated. - * - * @return void - */ - public static function create_blocklog_table() { - global $wpdb; - - require_once ABSPATH . 'wp-admin/includes/upgrade.php'; - - $sql = " - CREATE TABLE {$wpdb->prefix}jetpack_waf_blocklog ( - log_id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT, - timestamp datetime NOT NULL, - rule_id BIGINT NOT NULL, - reason longtext NOT NULL, - PRIMARY KEY (log_id), - KEY timestamp (timestamp) - ) - "; - - dbDelta( $sql ); - } - - /** - * Write block logs to database. - * - * @param array $log_data Log data. - * - * @return void - */ - private static function write_blocklog_row( $log_data ) { - $conn = self::connect_to_wordpress_db(); - - if ( ! $conn ) { - return; - } - - global $table_prefix; - - $statement = $conn->prepare( "INSERT INTO {$table_prefix}jetpack_waf_blocklog(reason,rule_id, timestamp) VALUES (?, ?, ?)" ); - if ( false !== $statement ) { - $statement->bind_param( 'sis', $log_data['reason'], $log_data['rule_id'], $log_data['timestamp'] ); - $statement->execute(); - - if ( $conn->insert_id > 100 ) { - $conn->query( "DELETE FROM {$table_prefix}jetpack_waf_blocklog ORDER BY log_id LIMIT 1" ); - } - } - } - - /** - * Get the daily summary stats from the database. - * - * @return array The daily summary stats. - */ - private static function get_daily_summary() { - global $table_prefix; - $db_connection = self::connect_to_wordpress_db(); - if ( ! $db_connection ) { - return array(); - } - - $result = $db_connection->query( "SELECT option_value FROM {$table_prefix}options WHERE option_name = '" . self::BLOCKLOG_OPTION_NAME_DAILY_SUMMARY . "'" ); - if ( ! $result ) { - return array(); - } - - $row = $result->fetch_assoc(); - if ( ! $row ) { - return array(); - } - - $daily_summary = self::unserialize_option_value( $row['option_value'] ); - $result->free(); - - return is_array( $daily_summary ) ? $daily_summary : array(); - } - - /** - * Increments the current date's daily summary stat. - * - * @param array $current_value The current value of the daily summary. - * - * @return array The updated daily summary. - */ - public static function increment_daily_summary( array $current_value ) { - $date = gmdate( 'Y-m-d' ); - $value = intval( $current_value[ $date ] ?? 0 ); - $current_value[ $date ] = $value + 1; - - return $current_value; - } - - /** - * Update the daily summary option in the database. - * - * @param array $value The value to update. - * - * @return void - */ - private static function write_daily_summary_row( array $value ) { - global $table_prefix; - $option_name = self::BLOCKLOG_OPTION_NAME_DAILY_SUMMARY; - - $db_connection = self::connect_to_wordpress_db(); - if ( ! $db_connection ) { - return; - } - - $updated_value = self::serialize_option_value( $value ); - - $statement = $db_connection->prepare( "INSERT INTO {$table_prefix}options (option_name, option_value) VALUES (?, ?) ON DUPLICATE KEY UPDATE option_value = ?" ); - if ( false !== $statement ) { - $statement->bind_param( 'sss', $option_name, $updated_value, $updated_value ); - $statement->execute(); - } - } - - /** - * Update the daily summary stats for the current date. - * - * @return void - */ - private static function write_daily_summary() { - $stats = self::get_daily_summary(); - $stats = self::increment_daily_summary( $stats ); - $stats = self::filter_last_30_days( $stats ); - - self::write_daily_summary_row( $stats ); - } - - /** - * Get the all-time block count value from the database. - * - * @return int The all-time block count. - */ - private static function get_all_time_block_count_value() { - global $table_prefix; - $db_connection = self::connect_to_wordpress_db(); - if ( ! $db_connection ) { - return 0; - } - - $result = $db_connection->query( "SELECT option_value FROM {$table_prefix}options WHERE option_name = '" . self::BLOCKLOG_OPTION_NAME_ALL_TIME_BLOCK_COUNT . "'" ); - if ( ! $result ) { - return 0; - } - - $row = $result->fetch_assoc(); - if ( ! $row ) { - return 0; - } - - $all_time_block_count = intval( $row['option_value'] ); - $result->free(); - - return $all_time_block_count; - } - - /** - * Update the all-time block count value in the database. - * - * @param int $value The value to update. - * @return void - */ - private static function write_all_time_block_count_row( int $value ) { - global $table_prefix; - $option_name = self::BLOCKLOG_OPTION_NAME_ALL_TIME_BLOCK_COUNT; - - $db_connection = self::connect_to_wordpress_db(); - if ( ! $db_connection ) { - return; - } - - $statement = $db_connection->prepare( "INSERT INTO {$table_prefix}options (option_name, option_value) VALUES (?, ?) ON DUPLICATE KEY UPDATE option_value = ?" ); - if ( false !== $statement ) { - $statement->bind_param( 'sii', $option_name, $value, $value ); - $statement->execute(); - } - } - - /** - * Increment the all-time stats. - * - * @return void - */ - private static function write_all_time_block_count() { - $block_count = self::get_all_time_block_count_value(); - if ( ! $block_count ) { - $block_count = self::get_default_all_time_stat_value(); - } - - self::write_all_time_block_count_row( $block_count + 1 ); - } - - /** - * Filters the stats to retain only data for the last 30 days. - * - * @param array $stats The array of stats to prune. - * - * @return array Pruned stats array. - */ - public static function filter_last_30_days( array $stats ) { - $today = gmdate( 'Y-m-d' ); - $one_month_ago = gmdate( 'Y-m-d', strtotime( '-30 days' ) ); - - return array_filter( - $stats, - function ( $date ) use ( $one_month_ago, $today ) { - return $date >= $one_month_ago && $date <= $today; - }, - ARRAY_FILTER_USE_KEY - ); - } - - /** - * Get the total number of blocked requests for today. - * - * @return int - */ - public static function get_current_day_block_count() { - $stats = get_option( self::BLOCKLOG_OPTION_NAME_DAILY_SUMMARY, array() ); - $today = gmdate( 'Y-m-d' ); - - return $stats[ $today ] ?? 0; - } - - /** - * Get the total number of blocked requests for last thirty days. - * - * @return int - */ - public static function get_thirty_days_block_counts() { - $stats = get_option( self::BLOCKLOG_OPTION_NAME_DAILY_SUMMARY, array() ); - $total_blocks = 0; - - foreach ( $stats as $count ) { - $total_blocks += intval( $count ); - } - - return $total_blocks; - } - - /** - * Get the total number of blocked requests for all time. - * - * @return int - */ - public static function get_all_time_block_count() { - $all_time_block_count = get_option( self::BLOCKLOG_OPTION_NAME_ALL_TIME_BLOCK_COUNT, false ); - - if ( false !== $all_time_block_count ) { - return intval( $all_time_block_count ); - } - - return self::get_default_all_time_stat_value(); - } - - /** - * Compute the initial all-time stats value. - * - * @return int The initial all-time stats value. - */ - private static function get_default_all_time_stat_value() { - $conn = self::connect_to_wordpress_db(); - if ( ! $conn ) { - return 0; - } - - global $table_prefix; - - $last_log_id_result = $conn->query( "SELECT log_id FROM {$table_prefix}jetpack_waf_blocklog ORDER BY log_id DESC LIMIT 1" ); - - $all_time_block_count = 0; - - if ( $last_log_id_result && $last_log_id_result->num_rows > 0 ) { - $row = $last_log_id_result->fetch_assoc(); - if ( $row !== null && isset( $row['log_id'] ) ) { - $all_time_block_count = $row['log_id']; - } - } - - return intval( $all_time_block_count ); - } - - /** - * Get the headers for logging purposes. - * - * @return array The headers. - */ - public static function get_request_headers() { - $all_headers = getallheaders(); - $exclude_headers = array( 'Authorization', 'Cookie', 'Proxy-Authorization', 'Set-Cookie' ); - - foreach ( $exclude_headers as $header ) { - unset( $all_headers[ $header ] ); - } - - return $all_headers; - } - - /** - * Write block logs. We won't write to the file if it exceeds 100 mb. - * - * @param string $rule_id The rule ID that triggered the block. - * @param string $reason The reason for the block. - * - * @return void - */ - public static function write_blocklog( $rule_id, $reason ) { - $log_data = array(); - $log_data['rule_id'] = $rule_id; - $log_data['reason'] = $reason; - $log_data['timestamp'] = gmdate( 'Y-m-d H:i:s' ); - $log_data['request_uri'] = isset( $_SERVER['REQUEST_URI'] ) ? \stripslashes( $_SERVER['REQUEST_URI'] ) : ''; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized, WordPress.Security.ValidatedSanitizedInput.MissingUnslash - $log_data['user_agent'] = isset( $_SERVER['HTTP_USER_AGENT'] ) ? \stripslashes( $_SERVER['HTTP_USER_AGENT'] ) : ''; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized, WordPress.Security.ValidatedSanitizedInput.MissingUnslash - $log_data['referer'] = isset( $_SERVER['HTTP_REFERER'] ) ? \stripslashes( $_SERVER['HTTP_REFERER'] ) : ''; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized, WordPress.Security.ValidatedSanitizedInput.MissingUnslash - $log_data['content_type'] = isset( $_SERVER['CONTENT_TYPE'] ) ? \stripslashes( $_SERVER['CONTENT_TYPE'] ) : ''; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized, WordPress.Security.ValidatedSanitizedInput.MissingUnslash - $log_data['get_params'] = json_encode( $_GET ); - - if ( defined( 'JETPACK_WAF_SHARE_DEBUG_DATA' ) && JETPACK_WAF_SHARE_DEBUG_DATA ) { - $log_data['post_params'] = json_encode( $_POST ); - $log_data['headers'] = self::get_request_headers(); - } - - if ( defined( 'JETPACK_WAF_SHARE_DATA' ) && JETPACK_WAF_SHARE_DATA ) { - $file_path = JETPACK_WAF_DIR . '/waf-blocklog'; - $file_exists = file_exists( $file_path ); - - if ( ! $file_exists || filesize( $file_path ) < ( 100 * 1024 * 1024 ) ) { - $fp = fopen( $file_path, 'a+' ); - - if ( $fp ) { - try { - fwrite( $fp, json_encode( $log_data ) . "\n" ); - } finally { - fclose( $fp ); - } - } - } - } - - self::write_daily_summary(); - self::write_all_time_block_count(); - self::write_blocklog_row( $log_data ); - self::close_db_connection(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php deleted file mode 100644 index 1292302e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php +++ /dev/null @@ -1,167 +0,0 @@ -] - * : The new mode to be set. - * --- - * options: - * - silent - * - normal - * --- - * - * @param array $args Arguments passed to CLI. - * @return void|null - * @throws WP_CLI\ExitException If there is an error switching the mode. - */ - public function mode( $args ) { - if ( count( $args ) > 1 ) { - - return WP_CLI::error( __( 'Only one mode may be specified.', 'jetpack-waf' ) ); - } - if ( count( $args ) === 1 ) { - if ( ! Waf_Runner::is_allowed_mode( $args[0] ) ) { - - return WP_CLI::error( - sprintf( - /* translators: %1$s is the mode that was actually found. Also note that the expected "silent" and "normal" are hard-coded strings and must therefore stay the same in any translation. */ - __( 'Invalid mode: %1$s. Expected "silent" or "normal".', 'jetpack-waf' ), - $args[0] - ) - ); - } - - update_option( Waf_Runner::MODE_OPTION_NAME, $args[0] ); - - try { - ( new Waf_Standalone_Bootstrap() )->generate(); - } catch ( \Exception $e ) { - WP_CLI::warning( - sprintf( - /* translators: %1$s is the unexpected error message. */ - __( 'Unable to generate waf bootstrap - standalone mode may not work properly: %1$s', 'jetpack-waf' ), - $e->getMessage() - ) - ); - } - - return WP_CLI::success( - sprintf( - /* translators: %1$s is the name of the mode that was just switched to. */ - __( 'Jetpack WAF mode switched to "%1$s".', 'jetpack-waf' ), - get_option( Waf_Runner::MODE_OPTION_NAME ) - ) - ); - } - WP_CLI::line( - sprintf( - /* translators: %1$s is the name of the mode that the waf is currently running in. */ - __( 'Jetpack WAF is running in "%1$s" mode.', 'jetpack-waf' ), - get_option( Waf_Runner::MODE_OPTION_NAME ) - ) - ); - } - - /** - * Setup the WAF to run. - * ## OPTIONS - * - * [] - * : The new mode to be set. - * --- - * options: - * - silent - * - normal - * --- - * - * @param array $args Arguments passed to CLI. - * @return void|null - * @throws WP_CLI\ExitException If there is an error switching the mode. - */ - public function setup( $args ) { - // Let is_allowed_mode know we are running from the CLI - define( 'WAF_CLI_MODE', $args[0] ); - - // Set the mode and generate the bootstrap - $this->mode( array( $args[0] ) ); - - try { - // Add relevant options and generate the rules.php file - Waf_Runner::activate(); - } catch ( \Exception $e ) { - - return WP_CLI::error( - sprintf( - /* translators: %1$s is the unexpected error message. */ - __( 'Jetpack WAF rules file failed to generate: %1$s', 'jetpack-waf' ), - $e->getMessage() - ) - ); - } - - return WP_CLI::success( __( 'Jetpack WAF has successfully been setup.', 'jetpack-waf' ) ); - } - - /** - * Delete the WAF options. - * - * @return void|null - * @throws WP_CLI\ExitException If deactivating has failures. - */ - public function teardown() { - try { - Waf_Runner::deactivate(); - } catch ( \Exception $e ) { - WP_CLI::error( __( 'Jetpack WAF failed to fully deactivate.', 'jetpack-waf' ) ); - } - - return WP_CLI::success( __( 'Jetpack WAF has been deactivated.', 'jetpack-waf' ) ); - } - - /** - * Generate the rules.php file with latest rules for the WAF. - * - * @return void|null - * @throws WP_CLI\ExitException If there is an error switching the mode. - */ - public function generate_rules() { - try { - Waf_Constants::define_entrypoint(); - Waf_Rules_Manager::generate_automatic_rules(); - Waf_Rules_Manager::generate_rules(); - } catch ( \Exception $e ) { - - return WP_CLI::error( - sprintf( - /* translators: %1$s is the unexpected error message. */ - __( 'Jetpack WAF rules file failed to generate: %1$s', 'jetpack-waf' ), - $e->getMessage() - ) - ); - } - - return WP_CLI::success( - sprintf( - /* translators: %1$s is the name of the mode that was just switched to. */ - __( 'Jetpack WAF rules successfully created to: "%1$s".', 'jetpack-waf' ), - Waf_Runner::get_waf_file_path( JETPACK_WAF_ENTRYPOINT ) - ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php deleted file mode 100644 index bc0b04a3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php +++ /dev/null @@ -1,127 +0,0 @@ -is_atomic_platform(); - $is_atomic_on_jn = defined( 'IS_ATOMIC_JN' ) ?? IS_ATOMIC_JN; - define( 'DISABLE_JETPACK_WAF', $is_wpcom || ( $is_atomic && ! $is_atomic_on_jn ) ); - } - } - - /** - * Set the mode definition if it has not been set. - * - * @return void - */ - public static function define_mode() { - if ( ! defined( 'JETPACK_WAF_MODE' ) ) { - $mode_option = get_option( Waf_Runner::MODE_OPTION_NAME ); - define( 'JETPACK_WAF_MODE', $mode_option ); - } - } - - /** - * Set the entrypoint definition if it has not been set. - */ - public static function define_entrypoint() { - if ( ! defined( 'JETPACK_WAF_ENTRYPOINT' ) ) { - define( 'JETPACK_WAF_ENTRYPOINT', 'rules/rules.php' ); - } - } - - /** - * Set the share data definition if it has not been set. - * - * @return void - */ - public static function define_share_data() { - if ( ! defined( 'JETPACK_WAF_SHARE_DATA' ) ) { - $share_data_option = false; - if ( function_exists( 'get_option' ) ) { - $share_data_option = get_option( Waf_Runner::SHARE_DATA_OPTION_NAME, false ); - } - - define( 'JETPACK_WAF_SHARE_DATA', $share_data_option ); - } - if ( ! defined( 'JETPACK_WAF_SHARE_DEBUG_DATA' ) ) { - $share_debug_data_option = false; - if ( function_exists( 'get_option' ) ) { - $share_debug_data_option = get_option( Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME, false ); - } - - define( 'JETPACK_WAF_SHARE_DEBUG_DATA', $share_debug_data_option ); - } - } - - /** - * Set the brute force protection's API host definition if it has not been set. - * - * @return void - */ - public static function define_brute_force_api_host() { - if ( ! defined( 'JETPACK_PROTECT__API_HOST' ) ) { - define( 'JETPACK_PROTECT__API_HOST', 'https://api.bruteprotect.com/' ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php deleted file mode 100644 index c2720f83..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php +++ /dev/null @@ -1,240 +0,0 @@ -generate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - - return true; - } - - /** - * Activate the Brute force protection on module activation. - * - * @return bool True if the Brute force protection activation is successful - */ - public static function on_brute_force_protection_activation() { - $brute_force_protection = Brute_Force_Protection::instance(); - $brute_force_protection->on_activation(); - - return true; - } - - /** - * Deactivate the WAF on module deactivation. - * - * @return bool|WP_Error True if the WAF deactivation is successful, WP_Error otherwise. - */ - public static function on_waf_deactivation() { - try { - Waf_Runner::deactivate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - - return true; - } - - /** - * Deactivate the Brute force protection on module deactivation. - * - * @return bool True if the Brute force protection deactivation is successful. - */ - public static function on_brute_force_protection_deactivation() { - $brute_force_protection = Brute_Force_Protection::instance(); - $brute_force_protection->on_deactivation(); - - return true; - } - - /** - * Updates the WAF after upgrader process is complete. - * - * @param WP_Upgrader $upgrader WP_Upgrader instance. In other contexts this might be a Theme_Upgrader, Plugin_Upgrader, Core_Upgrade, or Language_Pack_Upgrader instance. - * @param array $hook_extra Array of bulk item update data. - * - * @return void - */ - public static function update_waf_after_plugin_upgrade( $upgrader, $hook_extra ) { - $jetpack_text_domains_with_waf = array( 'jetpack', 'jetpack-protect' ); - $jetpack_plugins_with_waf = array( 'jetpack/jetpack.php', 'jetpack-protect/jetpack-protect.php' ); - - // Only run on upgrades affecting plugins - if ( 'plugin' !== $hook_extra['type'] ) { - return; - } - - // Only run on updates and installations - if ( 'update' !== $hook_extra['action'] && 'install' !== $hook_extra['action'] ) { - return; - } - - // Only run when Jetpack plugins were affected - if ( 'update' === $hook_extra['action'] && - ! empty( $hook_extra['plugins'] ) && - empty( array_intersect( $jetpack_plugins_with_waf, $hook_extra['plugins'] ) ) - ) { - return; - } - if ( 'install' === $hook_extra['action'] && - ! empty( $upgrader->new_plugin_data['TextDomain'] ) && - empty( in_array( $upgrader->new_plugin_data['TextDomain'], $jetpack_text_domains_with_waf, true ) ) - ) { - return; - } - - update_option( self::NEEDS_UPDATE_OPTION_NAME, true ); - } - - /** - * Check for WAF update - * - * Updates the WAF when the "needs update" option is enabled. - * - * @return bool|WP_Error True if the WAF is up-to-date or was sucessfully updated, WP_Error if the update failed. - */ - public static function check_for_updates() { - if ( get_option( self::NEEDS_UPDATE_OPTION_NAME ) ) { - if ( Waf_Runner::is_supported_environment() ) { - // Compatiblity patch for cases where an outdated WAF_Constants class has been - // autoloaded by the standalone bootstrap execution at the beginning of the current request. - if ( ! method_exists( Waf_Constants::class, 'define_mode' ) ) { - try { - ( new Waf_Standalone_Bootstrap() )->generate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - } - - Waf_Compatibility::run_compatibility_migrations(); - - try { - Waf_Rules_Manager::generate_ip_rules(); - Waf_Rules_Manager::generate_rules(); - ( new Waf_Standalone_Bootstrap() )->generate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - } else { - // If the site doesn't support the request firewall, - // just migrate the IP allow list used by brute force protection. - Waf_Compatibility::migrate_brute_force_protection_ip_allow_list(); - } - - update_option( self::NEEDS_UPDATE_OPTION_NAME, false ); - } - - return true; - } - - /** - * Disables the WAF module when on an unsupported platform in Jetpack. - * - * @param array $modules Filterable value for `jetpack_get_available_modules`. - * - * @return array Array of module slugs. - */ - public static function remove_module_on_unsupported_environments( $modules ) { - if ( ! Waf_Runner::is_supported_environment() ) { - // WAF should never be available on unsupported platforms. - unset( $modules['waf'] ); - } - - return $modules; - } - - /** - * Disables the WAF module when on an unsupported platform in a standalone plugin. - * - * @param array $modules Filterable value for `jetpack_get_available_standalone_modules`. - * - * @return array Array of module slugs. - */ - public static function remove_standalone_module_on_unsupported_environments( $modules ) { - if ( ! Waf_Runner::is_supported_environment() ) { - // WAF should never be available on unsupported platforms. - $modules = array_filter( - $modules, - function ( $module ) { - return $module !== 'waf'; - } - ); - - } - - return $modules; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php deleted file mode 100644 index 6e2bdceb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php +++ /dev/null @@ -1,286 +0,0 @@ -= intval( $test ) - ? $input - : false; - } - - /** - * Returns true if the input value is greater than the test value. - * If either value cannot be converted to an int it will be treated as 0. - * - * @param mixed $input Input. - * @param mixed $test Test. - * @return int|false - */ - public function gt( $input, $test ) { - return intval( $input ) > intval( $test ) - ? $input - : false; - } - - /** - * Returns true if the input value is less than or equal to the test value. - * If either value cannot be converted to an int it will be treated as 0. - * - * @param mixed $input Input. - * @param mixed $test Test. - * @return int|false - */ - public function le( $input, $test ) { - return intval( $input ) <= intval( $test ) - ? $input - : false; - } - - /** - * Returns true if the input value is less than the test value. - * If either value cannot be converted to an int it will be treated as 0. - * - * @param mixed $input Input. - * @param mixed $test Test. - * @return int|false - */ - public function lt( $input, $test ) { - return intval( $input ) < intval( $test ) - ? $input - : false; - } - - /** - * Returns false. - * - * @return false - */ - public function no_match() { - return false; - } - - /** - * Uses a multi-string matching algorithm to search through $input for a number of given $words. - * - * @param string $input Input. - * @param string[] $words \AhoCorasick\MultiStringMatcher $matcher. - * @return string[]|false Returns the words that were found in $input, or FALSE if no words were found. - */ - public function pm( $input, $words ) { - $results = $this->get_multi_string_matcher( $words )->searchIn( $input ); - - return isset( $results[0] ) - ? array_map( - function ( $r ) { - return $r[1]; }, - $results - ) - : false; - } - - /** - * The last-used pattern-matching algorithm. - * - * @var array - */ - private $last_multi_string_matcher = array( null, null ); - - /** - * Creates a matcher that uses the Aho-Corasick algorithm to efficiently find a number of words in an input string. - * Caches the last-used matcher so that the same word list doesn't have to be compiled multiple times. - * - * @param string[] $words Words. - * @return \AhoCorasick\MultiStringMatcher - */ - private function get_multi_string_matcher( $words ) { - // only create a new matcher entity if we don't have one already for this word list. - if ( $this->last_multi_string_matcher[0] !== $words ) { - $this->last_multi_string_matcher = array( $words, new \AhoCorasick\MultiStringMatcher( $words ) ); - } - - return $this->last_multi_string_matcher[1]; - } - - /** - * Performs a regular expression match on the input subject using the given pattern. - * Returns false if the pattern does not match, or the substring(s) of the input - * that were matched by the pattern. - * - * @param string $subject Subject. - * @param string $pattern Pattern. - * @return string[]|false - */ - public function rx( $subject, $pattern ) { - $matched = preg_match( $pattern, $subject, $matches ); - return 1 === $matched - ? $matches - : false; - } - - /** - * Returns true if the given input string matches the test string. - * - * @param string $input Input. - * @param string $test Test. - * @return string|false - */ - public function streq( $input, $test ) { - return $input === $test - ? $test - : false; - } - - /** - * Returns true. - * - * @param string $input Input. - * @return bool - */ - public function unconditional_match( $input ) { - return $input; - } - - /** - * Checks to see if the input string only contains characters within the given byte range - * - * @param string $input Input. - * @param array $valid_range Valid range. - * @return string - */ - public function validate_byte_range( $input, $valid_range ) { - if ( '' === $input ) { - // an empty string is considered "valid". - return false; - } - $i = 0; - while ( isset( $input[ $i ] ) ) { - $n = ord( $input[ $i ] ); - if ( $n < $valid_range['min'] || $n > $valid_range['max'] ) { - return $input[ $i ]; - } - $valid = false; - foreach ( $valid_range['range'] as $b ) { - if ( $n === $b || is_array( $b ) && $n >= $b[0] && $n <= $b[1] ) { - $valid = true; - break; - } - } - if ( ! $valid ) { - return $input[ $i ]; - } - ++$i; - } - - // if there weren't any invalid bytes, return false. - return false; - } - - /** - * Returns true if the input value is found anywhere inside the test value - * (i.e. the inverse of @contains) - * - * @param mixed $input Input. - * @param mixed $test Test. - * @return string|false - */ - public function within( $input, $test ) { - if ( '' === $input || '' === $test ) { - return false; - } - - return strpos( $test, $input ) !== false - ? $input - : false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php deleted file mode 100644 index bbb8bcf3..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php +++ /dev/null @@ -1,413 +0,0 @@ -url = [ 'https://wordpress.com', '/index.php', '?myvar=red' ] - * @var array{0: string, 1: string, 2: string}|null - */ - protected $url = null; - - /** - * Trusted proxies. - * - * @var array List of trusted proxy IP addresses. - */ - private $trusted_proxies = array(); - - /** - * Trusted headers. - * - * @var array List of headers to trust from the trusted proxies. - */ - private $trusted_headers = array(); - - /** - * Sets the list of IP addresses for the proxies to trust. Trusted headers will only be accepted as the - * user IP address from these IP adresses. - * - * Popular choices include: - * - 192.168.0.1 - * - 10.0.0.1 - * - * @param array $proxies List of proxy IP addresses. - * @return void - */ - public function set_trusted_proxies( $proxies ) { - $this->trusted_proxies = (array) $proxies; - } - - /** - * Sets the list of headers to be trusted from the proxies. These headers will only be taken into account - * if the request comes from a trusted proxy as configured with set_trusted_proxies(). - * - * Popular choices include: - * - HTTP_CLIENT_IP - * - HTTP_X_FORWARDED_FOR - * - HTTP_X_FORWARDED - * - HTTP_X_CLUSTER_CLIENT_IP - * - HTTP_FORWARDED_FOR - * - HTTP_FORWARDED - * - * @param array $headers List of HTTP header strings. - * @return void - */ - public function set_trusted_headers( $headers ) { - $this->trusted_headers = (array) $headers; - } - - /** - * Determines the users real IP address based on the settings passed to set_trusted_proxies() and - * set_trusted_headers() before. On CLI, this will be null. - * - * @return string|null - */ - public function get_real_user_ip_address() { - $remote_addr = ! empty( $_SERVER['REMOTE_ADDR'] ) ? wp_unslash( $_SERVER['REMOTE_ADDR'] ) : null; // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized - - if ( in_array( $remote_addr, $this->trusted_proxies, true ) ) { - $ip_by_header = $this->get_ip_by_header( array_merge( $this->trusted_headers, array( 'REMOTE_ADDR' ) ) ); - if ( ! empty( $ip_by_header ) ) { - return $ip_by_header; - } - } - - return $remote_addr; - } - - /** - * Iterates through a given list of HTTP headers and attempts to get the IP address from the header that - * a proxy sends along. Make sure you trust the IP address before calling this method. - * - * @param array $headers The list of headers to check. - * @return string|null - */ - private function get_ip_by_header( $headers ) { - foreach ( $headers as $key ) { - if ( isset( $_SERVER[ $key ] ) ) { - foreach ( explode( ',', wp_unslash( $_SERVER[ $key ] ) ) as $ip ) { // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- filter_var is applied below. - $ip = trim( $ip ); - - if ( filter_var( $ip, FILTER_VALIDATE_IP ) !== false ) { - return $ip; - } - } - } - } - - return null; - } - - /** - * Returns the headers that were sent with this request - * - * @return array{0: string, 1: scalar}[] - */ - public function get_headers() { - $value = array(); - $has_content_type = false; - $has_content_length = false; - foreach ( $_SERVER as $k => $v ) { - $k = strtolower( $k ); - if ( 'http_' === substr( $k, 0, 5 ) ) { - $value[] = array( $this->normalize_header_name( substr( $k, 5 ) ), $v ); - } elseif ( 'content_type' === $k && '' !== $v ) { - $has_content_type = true; - $value[] = array( 'content-type', $v ); - } elseif ( 'content_length' === $k && '' !== $v ) { - $has_content_length = true; - $value[] = array( 'content-length', $v ); - } - } - if ( ! $has_content_type ) { - // default Content-Type per RFC 7231 section 3.1.5.5. - $value[] = array( 'content-type', 'application/octet-stream' ); - } - if ( ! $has_content_length ) { - $value[] = array( 'content-length', '0' ); - } - - return $value; - } - - /** - * Returns the value of a specific header that was sent with this request - * - * @param string $name The name of the header to retrieve. - * @return string - */ - public function get_header( $name ) { - $name = $this->normalize_header_name( $name ); - foreach ( $this->get_headers() as list( $header_name, $header_value ) ) { - if ( $header_name === $name ) { - return $header_value; - } - } - return ''; - } - - /** - * Change a header name to all-lowercase and replace spaces and underscores with dashes. - * - * @param string $name The header name to normalize. - * @return string - */ - public function normalize_header_name( $name ) { - return str_replace( array( ' ', '_' ), '-', strtolower( $name ) ); - } - - /** - * Get the method for this request (GET, POST, etc). - * - * @return string - */ - public function get_method() { - return isset( $_SERVER['REQUEST_METHOD'] ) - ? filter_var( wp_unslash( $_SERVER['REQUEST_METHOD'] ), FILTER_DEFAULT ) - : ''; - } - - /** - * Get the protocol for this request (HTTP, HTTPS, etc) - * - * @return string - */ - public function get_protocol() { - return isset( $_SERVER['SERVER_PROTOCOL'] ) - ? filter_var( wp_unslash( $_SERVER['SERVER_PROTOCOL'] ), FILTER_DEFAULT ) - : ''; - } - - /** - * Returns the URL parts for this request. - * - * @see $this->url - * @return array{0: string, 1: string, 2: string} - */ - protected function get_url() { - if ( null !== $this->url ) { - return $this->url; - } - - $uri = isset( $_SERVER['REQUEST_URI'] ) ? filter_var( wp_unslash( $_SERVER['REQUEST_URI'] ), FILTER_DEFAULT ) : '/'; - if ( false !== strpos( $uri, '?' ) ) { - // remove the query string (we'll pull it from elsewhere later) - $uri = urldecode( substr( $uri, 0, strpos( $uri, '?' ) ) ); - } else { - $uri = urldecode( $uri ); - } - $query_string = isset( $_SERVER['QUERY_STRING'] ) ? '?' . filter_var( wp_unslash( $_SERVER['QUERY_STRING'] ), FILTER_DEFAULT ) : ''; - if ( 1 === preg_match( '/^https?:\/\//', $uri ) ) { - // sometimes $_SERVER[REQUEST_URI] already includes the full domain name - $uri_host = substr( $uri, 0, strpos( $uri, '/', 8 ) ); - $uri_path = substr( $uri, strlen( $uri_host ) ); - $this->url = array( $uri_host, $uri_path, $query_string ); - } else { - // otherwise build the URI manually - $uri_scheme = ( ! empty( $_SERVER['HTTPS'] ) && 'off' !== $_SERVER['HTTPS'] ) - ? 'https' - : 'http'; - $uri_host = isset( $_SERVER['HTTP_HOST'] ) - ? filter_var( wp_unslash( $_SERVER['HTTP_HOST'] ), FILTER_DEFAULT ) - : ( - isset( $_SERVER['SERVER_NAME'] ) - ? filter_var( wp_unslash( $_SERVER['SERVER_NAME'] ), FILTER_DEFAULT ) - : '' - ); - $uri_port = isset( $_SERVER['SERVER_PORT'] ) - ? filter_var( wp_unslash( $_SERVER['SERVER_PORT'] ), FILTER_SANITIZE_NUMBER_INT ) - : ''; - // we only need to include the port if it's non-standard - if ( $uri_port && ( 'http' === $uri_scheme && '80' !== $uri_port || 'https' === $uri_scheme && '443' !== $uri_port ) ) { - $uri_port = ':' . $uri_port; - } else { - $uri_port = ''; - } - $this->url = array( - $uri_scheme . '://' . $uri_host . $uri_port, - $uri, - $query_string, - ); - } - return $this->url; - } - - /** - * Get the requested URI - * - * @param boolean $include_host If true, the scheme and domain will be included in the returned string (i.e. 'https://wordpress.com/index.php). - * If false, only the requested URI path will be returned (i.e. '/index.php'). - * @return string - */ - public function get_uri( $include_host = false ) { - list( $host, $file, $query ) = $this->get_url(); - - return ( $include_host ? $host : '' ) . $file . $query; - } - - /** - * Return the filename part of the request - * - * @example for 'https://wordpress.com/some/page?id=5', return '/some/page' - * @return string - */ - public function get_filename() { - return $this->get_url()[1]; - } - - /** - * Return the basename part of the request - * - * @example for 'https://wordpress.com/some/page.php?id=5', return 'page.php' - * @return string - */ - public function get_basename() { - // Get the filename part of the request - $filename = $this->get_filename(); - // Normalize slashes - $filename = str_replace( '\\', '/', $filename ); - // Remove trailing slashes - $filename = rtrim( $filename, '/' ); - // Return the basename - $offset = strrpos( $filename, '/' ); - return $offset !== false ? substr( $filename, $offset + 1 ) : $filename; - } - - /** - * Return the query string. If present, it will be prefixed with '?'. Otherwise, it will be an empty string. - * - * @return string - */ - public function get_query_string() { - return $this->get_url()[2]; - } - - /** - * Returns the request body. - * - * @return string - */ - public function get_body() { - $body = file_get_contents( 'php://input' ); - return false === $body ? '' : $body; - } - - /** - * Returns the cookies - * - * @return array{string, scalar}[] - */ - public function get_cookies() { - return flatten_array( $_COOKIE ); - } - - /** - * Returns the GET variables - * - * @return array{string, scalar}[] - */ - public function get_get_vars() { - return flatten_array( $_GET ); - } - - /** - * Returns the POST variables from a JSON body - * - * @return array{string, scalar}[] - */ - private function get_json_post_vars() { - $decoded_json = json_decode( $this->get_body(), true ) ?? array(); - return flatten_array( $decoded_json, 'json', true ); - } - - /** - * Returns the POST variables from a urlencoded body - * - * @return array{string, scalar}[] - */ - private function get_urlencoded_post_vars() { - parse_str( $this->get_body(), $params ); - return flatten_array( $params ); - } - - /** - * Returns the POST variables - * - * @param string $body_processor Manually specifiy the method to use to process the body. Options are 'URLENCODED' and 'JSON'. - * - * @return array{string, scalar}[] - */ - public function get_post_vars( string $body_processor = '' ) { - $content_type = $this->get_header( 'content-type' ); - - // If the body processor is specified by the rules file, trust it. - if ( 'URLENCODED' === $body_processor ) { - return $this->get_urlencoded_post_vars(); - } - if ( 'JSON' === $body_processor ) { - return $this->get_json_post_vars(); - } - - // Otherwise, use $_POST if it's not empty. - if ( ! empty( $_POST ) ) { - return flatten_array( $_POST ); - } - - // Lastly, try to parse the body based on the content type. - if ( strpos( $content_type, 'application/json' ) !== false ) { - return $this->get_json_post_vars(); - } - if ( strpos( $content_type, 'application/x-www-form-urlencoded' ) !== false ) { - return $this->get_urlencoded_post_vars(); - } - - // Don't try to parse any other content types. - return array(); - } - - /** - * Returns the files that were uploaded with this request (i.e. what's in the $_FILES superglobal) - * - * @return RequestFile[] - */ - public function get_files() { - $files = array(); - foreach ( $_FILES as $field_name => $arr ) { - // flatten the values in case we were given inputs with brackets - foreach ( flatten_array( $arr ) as list( $arr_key, $arr_value ) ) { - if ( $arr_key === 'name' ) { - // if this file was a simple (non-nested) name and unique, then just add it. - $files[] = array( - 'name' => $field_name, - 'filename' => $arr_value, - ); - } elseif ( 'name[' === substr( $arr_key, 0, 5 ) ) { - // otherwise this was a file with a nested name and/or multiple files with the same name - $files[] = array( - 'name' => $field_name . substr( $arr_key, 4 ), - 'filename' => $arr_value, - ); - } - } - } - return $files; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php deleted file mode 100644 index 5303ff35..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php +++ /dev/null @@ -1,362 +0,0 @@ -get_wp_error(); - } - - update_option( self::RULE_LAST_UPDATED_OPTION_NAME, time() ); - return true; - } - - /** - * Re-activate the WAF any time an option is added or updated. - * - * @return bool|WP_Error True if re-activation is successful, WP_Error on failure. - */ - public static function reactivate_on_rules_option_change() { - try { - Waf_Runner::activate(); - } catch ( Waf_Exception $e ) { - return $e->get_wp_error(); - } - - return true; - } - - /** - * Updates the rule set if rules version has changed - * - * @throws Waf_Exception If the firewall mode is invalid. - * @throws Waf_Exception If the rules update fails. - * - * @return void - */ - public static function update_rules_if_changed() { - $version = get_option( self::VERSION_OPTION_NAME ); - if ( self::RULES_VERSION !== $version ) { - self::generate_automatic_rules(); - self::generate_ip_rules(); - self::generate_rules(); - - update_option( self::VERSION_OPTION_NAME, self::RULES_VERSION ); - } - } - - /** - * Retrieve rules from the API - * - * @throws Waf_Exception If site is not registered. - * @throws Rules_API_Exception If API did not respond 200. - * @throws Rules_API_Exception If data is missing from response. - * - * @return array - */ - public static function get_rules_from_api() { - $blog_id = Jetpack_Options::get_option( 'id' ); - if ( ! $blog_id ) { - throw new Waf_Exception( 'Site is not registered' ); - } - - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%s/waf-rules', $blog_id ), - '2', - array(), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( 200 !== $response_code ) { - throw new Rules_API_Exception( 'API connection failed.', (int) $response_code ); - } - - $rules_json = wp_remote_retrieve_body( $response ); - $rules = json_decode( $rules_json, true ); - - if ( empty( $rules['data'] ) ) { - throw new Rules_API_Exception( 'Data missing from response.' ); - } - - return $rules['data']; - } - - /** - * Wraps a require statement in a file_exists check. - * - * @param string $required_file The file to check if exists and require. - * @param string $return_code The PHP code to execute if the file require returns true. Defaults to 'return;'. - * - * @return string The wrapped require statement. - */ - private static function wrap_require( $required_file, $return_code = 'return;' ) { - return "if ( file_exists( '$required_file' ) ) { if ( require( '$required_file' ) ) { $return_code } }"; - } - - /** - * Generates the rules.php script - * - * @global \WP_Filesystem_Base $wp_filesystem WordPress filesystem abstraction. - * - * @throws File_System_Exception If file writing fails initializing rule files. - * @throws File_System_Exception If file writing fails writing to the rules entrypoint file. - * - * @return void - */ - public static function generate_rules() { - global $wp_filesystem; - Waf_Runner::initialize_filesystem(); - Waf_Constants::define_entrypoint(); - - $rules = "is_dir( dirname( $entrypoint_file_path ) ) ) { - $wp_filesystem->mkdir( dirname( $entrypoint_file_path ) ); - } - - // Ensure all potentially required rule files exist - $rule_files = array( JETPACK_WAF_ENTRYPOINT, self::AUTOMATIC_RULES_FILE, self::IP_ALLOW_RULES_FILE, self::IP_BLOCK_RULES_FILE ); - foreach ( $rule_files as $rule_file ) { - $rule_file = Waf_Runner::get_waf_file_path( $rule_file ); - if ( ! $wp_filesystem->is_file( $rule_file ) ) { - if ( ! $wp_filesystem->put_contents( $rule_file, "block( 'block', -1, 'ip block list' );" ) . "\n"; - } - - // Add automatic rules - if ( self::automatic_rules_enabled() ) { - $rules .= self::wrap_require( Waf_Runner::get_waf_file_path( self::AUTOMATIC_RULES_FILE ) ) . "\n"; - } - - // Update the rules file - if ( ! $wp_filesystem->put_contents( $entrypoint_file_path, $rules ) ) { - throw new File_System_Exception( 'Failed writing rules file to: ' . $entrypoint_file_path ); - } - } - - /** - * Generates the automatic-rules.php script - * - * @global \WP_Filesystem_Base $wp_filesystem WordPress filesystem abstraction. - * - * @throws Waf_Exception If rules cannot be fetched from the API. - * @throws File_System_Exception If file writing fails. - * - * @return void - */ - public static function generate_automatic_rules() { - global $wp_filesystem; - Waf_Runner::initialize_filesystem(); - - $automatic_rules_file_path = Waf_Runner::get_waf_file_path( self::AUTOMATIC_RULES_FILE ); - - // Ensure that the folder exists. - if ( ! $wp_filesystem->is_dir( dirname( $automatic_rules_file_path ) ) ) { - $wp_filesystem->mkdir( dirname( $automatic_rules_file_path ) ); - } - - try { - $rules = self::get_rules_from_api(); - } catch ( Waf_Exception $e ) { - // Do not throw API exceptions for users who do not have access - if ( 401 !== $e->getCode() ) { - throw $e; - } - } - - // If there are no rules available, don't overwrite the existing file. - if ( empty( $rules ) ) { - return; - } - - if ( ! $wp_filesystem->put_contents( $automatic_rules_file_path, $rules ) ) { - throw new File_System_Exception( 'Failed writing automatic rules file to: ' . $automatic_rules_file_path ); - } - - update_option( self::AUTOMATIC_RULES_LAST_UPDATED_OPTION_NAME, time() ); - } - - /** - * Generates the rules.php script - * - * @global \WP_Filesystem_Base $wp_filesystem WordPress filesystem abstraction. - * - * @throws File_System_Exception If writing to IP allow list file fails. - * @throws File_System_Exception If writing to IP block list file fails. - * - * @return void - */ - public static function generate_ip_rules() { - global $wp_filesystem; - Waf_Runner::initialize_filesystem(); - - $allow_ip_file_path = Waf_Runner::get_waf_file_path( self::IP_ALLOW_RULES_FILE ); - $block_ip_file_path = Waf_Runner::get_waf_file_path( self::IP_BLOCK_RULES_FILE ); - - // Ensure that the folders exists. - if ( ! $wp_filesystem->is_dir( dirname( $allow_ip_file_path ) ) ) { - $wp_filesystem->mkdir( dirname( $allow_ip_file_path ) ); - } - if ( ! $wp_filesystem->is_dir( dirname( $block_ip_file_path ) ) ) { - $wp_filesystem->mkdir( dirname( $block_ip_file_path ) ); - } - - $allow_list = IP_Utils::get_ip_addresses_from_string( get_option( self::IP_ALLOW_LIST_OPTION_NAME ) ); - $block_list = IP_Utils::get_ip_addresses_from_string( get_option( self::IP_BLOCK_LIST_OPTION_NAME ) ); - - $allow_rules_content = ''; - // phpcs:disable WordPress.PHP.DevelopmentFunctions - $allow_rules_content .= '$waf_allow_list = ' . var_export( $allow_list, true ) . ";\n"; - // phpcs:enable - $allow_rules_content .= 'return $waf->is_ip_in_array( $waf_allow_list );' . "\n"; - - if ( ! $wp_filesystem->put_contents( $allow_ip_file_path, "is_ip_in_array( $waf_block_list );' . "\n"; - - if ( ! $wp_filesystem->put_contents( $block_ip_file_path, "is_wpcom_simple() ) { - return false; - } - - // Do not run on the Atomic platform - if ( ( new Host() )->is_atomic_platform() ) { - return false; - } - - // Do not run on the VIP platform - if ( ( new Host() )->is_vip_site() ) { - return false; - } - - return true; - } - - /** - * Determines if the WAF module is enabled on the site. - * - * @return bool - */ - public static function is_enabled() { - // if ABSPATH is defined, then WordPress has already been instantiated, - // so we can check to see if the waf module is activated. - if ( defined( 'ABSPATH' ) ) { - return ( new Modules() )->is_active( self::WAF_MODULE_NAME ); - } - - return true; - } - - /** - * Enables the WAF module on the site. - * - * @return bool - */ - public static function enable() { - return ( new Modules() )->activate( self::WAF_MODULE_NAME, false, false ); - } - - /** - * Disabled the WAF module on the site. - * - * @return bool - */ - public static function disable() { - return ( new Modules() )->deactivate( self::WAF_MODULE_NAME ); - } - - /** - * Get Config - * - * @return array The WAF settings and current configuration data. - */ - public static function get_config() { - return array( - Waf_Rules_Manager::AUTOMATIC_RULES_ENABLED_OPTION_NAME => Waf_Rules_Manager::automatic_rules_enabled(), - Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME => get_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ), - Waf_Rules_Manager::IP_ALLOW_LIST_ENABLED_OPTION_NAME => Waf_Rules_Manager::ip_allow_list_enabled(), - Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME => get_option( Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME ), - Waf_Rules_Manager::IP_BLOCK_LIST_ENABLED_OPTION_NAME => Waf_Rules_Manager::ip_block_list_enabled(), - self::SHARE_DATA_OPTION_NAME => get_option( self::SHARE_DATA_OPTION_NAME ), - self::SHARE_DEBUG_DATA_OPTION_NAME => get_option( self::SHARE_DEBUG_DATA_OPTION_NAME ), - 'bootstrap_path' => self::get_bootstrap_file_path(), - 'standalone_mode' => self::get_standalone_mode_status(), - 'automatic_rules_available' => (bool) self::automatic_rules_available(), - 'brute_force_protection' => (bool) Brute_Force_Protection::is_enabled(), - - /** - * Provide the deprecated IP lists options for backwards compatibility with older versions of the Jetpack and Protect plugins. - * i.e. If one plugin is updated and the other is not, the latest version of this package will be used by both plugins. - * - * @deprecated 0.17.0 - */ - // @phan-suppress-next-line PhanDeprecatedClassConstant -- Needed for backwards compatibility. - Waf_Rules_Manager::IP_LISTS_ENABLED_OPTION_NAME => Waf_Rules_Manager::ip_allow_list_enabled() || Waf_Rules_Manager::ip_block_list_enabled(), - ); - } - - /** - * Get Bootstrap File Path - * - * @return string The path to the Jetpack Firewall's bootstrap.php file. - */ - private static function get_bootstrap_file_path() { - $bootstrap = new Waf_Standalone_Bootstrap(); - return $bootstrap->get_bootstrap_file_path(); - } - - /** - * Get WAF standalone mode status - * - * @return bool|array True if WAF standalone mode is enabled, false otherwise. - */ - public static function get_standalone_mode_status() { - return defined( 'JETPACK_WAF_RUN' ) && JETPACK_WAF_RUN === 'preload'; - } - - /** - * Get WAF File Path - * - * @param string $file The file path starting in the WAF directory. - * @return string The full file path to the provided file in the WAF directory. - */ - public static function get_waf_file_path( $file ) { - Waf_Constants::define_waf_directory(); - - // Ensure the file path starts with a slash. - if ( '/' !== substr( $file, 0, 1 ) ) { - $file = "/$file"; - } - - return JETPACK_WAF_DIR . $file; - } - - /** - * Runs the WAF and potentially stops the request if a problem is found. - * - * @return void - */ - public static function run() { - // Make double-sure we are only running once. - if ( self::did_run() ) { - return; - } - - Waf_Constants::initialize_constants(); - - // if ABSPATH is defined, then WordPress has already been instantiated, - // and we're running as a plugin (meh). Otherwise, we're running via something - // like PHP's prepend_file setting (yay!). - define( 'JETPACK_WAF_RUN', defined( 'ABSPATH' ) ? 'plugin' : 'preload' ); - - // if the WAF is being run before a command line script, don't try to execute rules (there's no request). - if ( PHP_SAPI === 'cli' ) { - return; - } - - // if something terrible happens during the WAF running, we don't want to interfere with the rest of the site, - // so we intercept errors ONLY while the WAF is running, then we remove our handler after the WAF finishes. - $display_errors = ini_get( 'display_errors' ); - - ini_set( 'display_errors', 'Off' ); // phpcs:ignore WordPress.PHP.IniSet.display_errors_Disallowed -- We only customize error reporting while the WAF is running, and remove our handler afterwards. - - set_error_handler( array( self::class, 'errorHandler' ) ); // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_set_error_handler -- We only customize error reporting while the WAF is running, and remove our handler afterwards. - - try { - - // phpcs:ignore - $waf = new Waf_Runtime( new Waf_Transforms(), new Waf_Operators() ); - - // execute waf rules. - $rules_file_path = self::get_waf_file_path( JETPACK_WAF_ENTRYPOINT ); - if ( file_exists( $rules_file_path ) ) { - // phpcs:ignore - include $rules_file_path; - } - } catch ( \Exception $err ) { // phpcs:ignore - // Intentionally doing nothing. - } - - // remove the custom error handler, so we don't interfere with the site. - restore_error_handler(); - - // Restore the original value. - ini_set( 'display_errors', $display_errors ); // phpcs:ignore WordPress.PHP.IniSet.display_errors_Disallowed -- We only customize error reporting while the WAF is running, and remove our handler afterwards. - } - - /** - * Error handler to be used while the WAF is being executed. - * - * @param int $code The error code. - * @param string $message The error message. - * @param string $file File with the error. - * @param string $line Line of the error. - * @return void - */ - public static function errorHandler( $code, $message, $file, $line ) { // phpcs:ignore - // Intentionally doing nothing for now. - } - - /** - * Initializes the WP filesystem and WAF directory structure. - * - * @throws File_System_Exception If filesystem is unavailable. - * - * @return void - */ - public static function initialize_filesystem() { - if ( ! function_exists( '\\WP_Filesystem' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - if ( ! \WP_Filesystem() ) { - throw new File_System_Exception( 'No filesystem available.' ); - } - - self::initialize_waf_directory(); - } - - /** - * Activates the WAF by generating the rules script and setting the version - * - * @throws Waf_Exception If the firewall mode is invalid. - * @throws Waf_Exception If the activation fails. - * - * @return void - */ - public static function activate() { - $version = get_option( Waf_Rules_Manager::VERSION_OPTION_NAME ); - if ( ! $version ) { - add_option( Waf_Rules_Manager::VERSION_OPTION_NAME, Waf_Rules_Manager::RULES_VERSION ); - } - - add_option( self::SHARE_DATA_OPTION_NAME, true ); - - self::initialize_filesystem(); - - Waf_Rules_Manager::generate_automatic_rules(); - Waf_Rules_Manager::generate_ip_rules(); - Waf_Rules_Manager::generate_rules(); - - Waf_Blocklog_Manager::create_blocklog_table(); - } - - /** - * Ensures that the waf directory is created. - * - * @throws File_System_Exception If filesystem is unavailable. - * @throws File_System_Exception If creating the directory fails. - * - * @return void - */ - public static function initialize_waf_directory() { - WP_Filesystem(); - Waf_Constants::define_waf_directory(); - - global $wp_filesystem; - if ( ! $wp_filesystem ) { - throw new File_System_Exception( 'Can not work without the file system being initialized.' ); - } - - if ( ! $wp_filesystem->is_dir( JETPACK_WAF_DIR ) ) { - if ( ! $wp_filesystem->mkdir( JETPACK_WAF_DIR ) ) { - throw new File_System_Exception( 'Failed creating WAF file directory: ' . JETPACK_WAF_DIR ); - } - } - } - - /** - * Deactivates the WAF by deleting the relevant options and emptying rules file. - * - * @throws File_System_Exception If file writing fails. - * - * @return void - */ - public static function deactivate() { - delete_option( self::MODE_OPTION_NAME ); - delete_option( Waf_Rules_Manager::VERSION_OPTION_NAME ); - - global $wp_filesystem; - self::initialize_filesystem(); - Waf_Constants::define_entrypoint(); - - // If the rules file doesn't exist, there's nothing else to do. - if ( ! $wp_filesystem->exists( self::get_waf_file_path( JETPACK_WAF_ENTRYPOINT ) ) ) { - return; - } - - // Empty the rules entrypoint file. - if ( ! $wp_filesystem->put_contents( self::get_waf_file_path( JETPACK_WAF_ENTRYPOINT ), "generate(); - } - - /** - * Check if an automatic rules file is available - * - * @return bool False if an automatic rules file is not available, true otherwise - */ - public static function automatic_rules_available() { - $automatic_rules_last_updated = get_option( Waf_Rules_Manager::AUTOMATIC_RULES_LAST_UPDATED_OPTION_NAME ); - - // If we do not have a automatic rules last updated timestamp cached, return false. - if ( ! $automatic_rules_last_updated ) { - return false; - } - - // Validate that the automatic rules file exists and is not empty. - global $wp_filesystem; - - try { - self::initialize_filesystem(); - } catch ( Waf_Exception $e ) { - return false; - } - - $automatic_rules_file_contents = $wp_filesystem->get_contents( self::get_waf_file_path( Waf_Rules_Manager::AUTOMATIC_RULES_FILE ) ); - - // If the automatic rules file was removed or is now empty, return false. - if ( ! $automatic_rules_file_contents || " -PHAN; - -/** - * Waf_Runtime class - */ -class Waf_Runtime { - /** - * If used, normalize_array_targets() will just return the number of matching values, instead of the values themselves. - */ - const NORMALIZE_ARRAY_COUNT = 1; - /** - * If used, normalize_array_targets() will apply "only" and "except" filters to the values of the source array, instead of the keys. - */ - const NORMALIZE_ARRAY_MATCH_VALUES = 2; - - /** - * The version of this runtime class. Used by rule files to ensure compatibility. - * - * @since 0.21.0 - * - * @var int - */ - public $version = 1; - /** - * Last rule. - * - * @var string - */ - public $last_rule = ''; - /** - * Matched vars. - * - * @var array - */ - public $matched_vars = array(); - /** - * Matched var. - * - * @var string - */ - public $matched_var = ''; - /** - * Matched var names. - * - * @var array - */ - public $matched_var_names = array(); - /** - * Matched var name. - * - * @var string - */ - public $matched_var_name = ''; - /** - * Body Processor. - * - * @var string 'URLENCODED' | 'JSON' | '' - */ - private $body_processor = ''; - - /** - * State. - * - * @var array - */ - private $state = array(); - /** - * Metadata. - * - * @var array - */ - private $metadata = array(); - - /** - * Transforms. - * - * @var Waf_Transforms - */ - private $transforms; - /** - * Operators. - * - * @var Waf_Operators - */ - private $operators; - - /** - * The request - * - * @var Waf_Request - */ - private $request; - - /** - * Rules to remove. - * - * @var array[] - */ - private $rules_to_remove = array( - 'id' => array(), - 'tag' => array(), - ); - - /** - * Targets to remove. - * - * @var array[] - */ - private $targets_to_remove = array( - 'id' => array(), - 'tag' => array(), - ); - - /** - * Constructor method. - * - * @param Waf_Transforms $transforms Transforms. - * @param Waf_Operators $operators Operators. - * @param ?Waf_Request $request Information about the request. - */ - public function __construct( $transforms, $operators, $request = null ) { - $this->transforms = $transforms; - $this->operators = $operators; - $this->request = null === $request - ? new Waf_Request() - : $request; - } - - /** - * Rule removed method. - * - * @param string $id Ids. - * @param string[] $tags Tags. - */ - public function rule_removed( $id, $tags ) { - if ( isset( $this->rules_to_remove['id'][ $id ] ) ) { - return true; - } - foreach ( $tags as $tag ) { - if ( isset( $this->rules_to_remove['tag'][ $tag ] ) ) { - return true; - } - } - return false; - } - - /** - * Update Targets. - * - * @param array $targets Targets. - * @param string $rule_id Rule id. - * @param string[] $rule_tags Rule tags. - */ - public function update_targets( $targets, $rule_id, $rule_tags ) { - $updates = array(); - // look for target updates based on the rule's ID. - if ( isset( $this->targets_to_remove['id'][ $rule_id ] ) ) { - foreach ( $this->targets_to_remove['id'][ $rule_id ] as $name => $props ) { - $updates[] = array( $name, $props ); - } - } - // look for target updates based on the rule's tags. - foreach ( $rule_tags as $tag ) { - if ( isset( $this->targets_to_remove['tag'][ $tag ] ) ) { - foreach ( $this->targets_to_remove['tag'][ $tag ] as $name => $props ) { - $updates[] = array( $name, $props ); - } - } - } - // apply any found target updates. - - foreach ( $updates as list( $name, $props ) ) { - if ( isset( $targets[ $name ] ) ) { - // we only need to remove targets that exist. - if ( true === $props ) { - // if the entire target is being removed, remove it. - unset( $targets[ $name ] ); - } else { - // otherwise just mark single props to ignore. - $targets[ $name ]['except'] = array_merge( - isset( $targets[ $name ]['except'] ) ? $targets[ $name ]['except'] : array(), - $props - ); - } - } - } - return $targets; - } - - /** - * Return TRUE if at least one of the targets matches the rule. - * - * @param string[] $transforms One of the transform methods defined in the Jetpack Waf_Transforms class. - * @param TargetBag $targets Targets. - * @param string $match_operator Match operator. - * @param mixed $match_value Match value. - * @param bool $match_not Match not. - * @param bool $capture Capture. - * @return bool - */ - public function match_targets( $transforms, $targets, $match_operator, $match_value, $match_not, $capture = false ) { - $this->matched_vars = array(); - $this->matched_var_names = array(); - $this->matched_var = ''; - $this->matched_var_name = ''; - $match_found = false; - - // get values. - $values = $this->normalize_targets( $targets ); - - // apply transforms. - foreach ( $transforms as $t ) { - foreach ( $values as &$v ) { - $v['value'] = $this->transforms->$t( $v['value'] ); - } - } - unset( $v ); - // pass each target value to the operator to find any that match. - $matched = array(); - $captures = array(); - foreach ( $values as $v ) { - $match = $this->operators->{$match_operator}( $v['value'], $match_value ); - $did_match = false !== $match; - if ( $match_not !== $did_match ) { - // If either: - // - rule is negated ("not" flag set) and the target was not matched - // - rule not negated and the target was matched - // then this is considered a match. - $match_found = true; - $this->matched_var_names[] = $v['source']; - $this->matched_vars[] = $v['value']; - $this->matched_var_name = end( $this->matched_var_names ); - $this->matched_var = end( $this->matched_vars ); - $matched[] = array( $v, $match ); - // Set any captured matches into state if the rule has the "capture" flag. - if ( $capture ) { - $captures = is_array( $match ) ? $match : array( $match ); - foreach ( array_slice( $captures, 0, 10 ) as $i => $c ) { - $this->set_var( "tx.$i", $c ); - } - } - } - } - - return $match_found; - } - - /** - * Block. - * - * @param string $action Action. - * @param string $rule_id Rule id. - * @param string $reason Block reason. - * @param int $status_code Http status code. - */ - public function block( $action, $rule_id, $reason, $status_code = 403 ) { - if ( ! $reason ) { - $reason = "rule $rule_id"; - } else { - $reason = $this->sanitize_output( $reason ); - } - - Waf_Blocklog_Manager::write_blocklog( $rule_id, $reason ); - error_log( "Jetpack WAF Blocked Request\t$action\t$rule_id\t$status_code\t$reason" ); - header( "X-JetpackWAF-Blocked: $status_code - rule $rule_id" ); - if ( defined( 'JETPACK_WAF_MODE' ) && 'normal' === JETPACK_WAF_MODE ) { - $protocol = isset( $_SERVER['SERVER_PROTOCOL'] ) ? wp_unslash( $_SERVER['SERVER_PROTOCOL'] ) : 'HTTP'; - header( $protocol . ' 403 Forbidden', true, $status_code ); - die( "rule $rule_id - reason $reason" ); - } - } - - /** - * Redirect. - * - * @param string $rule_id Rule id. - * @param string $url Url. - * @return never - */ - public function redirect( $rule_id, $url ) { - error_log( "Jetpack WAF Redirected Request.\tRule:$rule_id\t$url" ); - header( "Location: $url" ); - exit( 0 ); - } - - /** - * Flag rule for removal. - * - * @param string $prop Prop. - * @param string $value Value. - */ - public function flag_rule_for_removal( $prop, $value ) { - if ( 'id' === $prop ) { - $this->rules_to_remove['id'][ $value ] = true; - } else { - $this->rules_to_remove['tag'][ $value ] = true; - } - } - - /** - * Flag target for removal. - * - * @param string $id_or_tag Id or tag. - * @param string $id_or_tag_value Id or tag value. - * @param string $name Name. - * @param string $prop Prop. - */ - public function flag_target_for_removal( $id_or_tag, $id_or_tag_value, $name, $prop = null ) { - if ( null === $prop ) { - $this->targets_to_remove[ $id_or_tag ][ $id_or_tag_value ][ $name ] = true; - } elseif ( - ! isset( $this->targets_to_remove[ $id_or_tag ][ $id_or_tag_value ][ $name ] ) - // if the entire target is already being removed then it would be redundant to remove a single property. - || true !== $this->targets_to_remove[ $id_or_tag ][ $id_or_tag_value ][ $name ] - ) { - $this->targets_to_remove[ $id_or_tag ][ $id_or_tag_value ][ $name ][] = $prop; - } - } - - /** - * Get variable value. - * - * @param string $key Key. - */ - public function get_var( $key ) { - return isset( $this->state[ $key ] ) - ? $this->state[ $key ] - : ''; - } - - /** - * Set variable value. - * - * @param string $key Key. - * @param string $value Value. - */ - public function set_var( $key, $value ) { - $this->state[ $key ] = $value; - } - - /** - * Increment variable. - * - * @param string $key Key. - * @param mixed $value Value. - */ - public function inc_var( $key, $value ) { - if ( ! isset( $this->state[ $key ] ) ) { - $this->state[ $key ] = 0; - } - $this->state[ $key ] += floatval( $value ); - } - - /** - * Decrement variable. - * - * @param string $key Key. - * @param mixed $value Value. - */ - public function dec_var( $key, $value ) { - if ( ! isset( $this->state[ $key ] ) ) { - $this->state[ $key ] = 0; - } - $this->state[ $key ] -= floatval( $value ); - } - - /** - * Unset variable. - * - * @param string $key Key. - */ - public function unset_var( $key ) { - unset( $this->state[ $key ] ); - } - - /** - * A cache of metadata about the incoming request. - * - * @param string $key The type of metadata to request ('headers', 'request_method', etc.). - */ - public function meta( $key ) { - if ( ! isset( $this->metadata[ $key ] ) ) { - $value = null; - switch ( $key ) { - case 'headers': - $value = $this->request->get_headers(); - break; - case 'headers_names': - $value = $this->args_names( $this->meta( 'headers' ) ); - break; - case 'request_method': - $value = $this->request->get_method(); - break; - case 'request_protocol': - $value = $this->request->get_protocol(); - break; - case 'request_uri': - $value = $this->request->get_uri( false ); - break; - case 'request_uri_raw': - $value = $this->request->get_uri( true ); - break; - case 'request_filename': - $value = $this->request->get_filename(); - break; - case 'request_line': - $value = sprintf( - '%s %s %s', - $this->request->get_method(), - $this->request->get_uri( false ), - $this->request->get_protocol() - ); - break; - case 'request_basename': - $value = $this->request->get_basename(); - break; - case 'request_body': - $value = $this->request->get_body(); - break; - case 'query_string': - $value = $this->request->get_query_string(); - break; - case 'args_get': - $value = $this->request->get_get_vars(); - break; - case 'args_get_names': - $value = $this->args_names( $this->meta( 'args_get' ) ); - break; - case 'args_post': - $value = $this->request->get_post_vars( $this->get_body_processor() ); - break; - case 'args_post_names': - $value = $this->args_names( $this->meta( 'args_post' ) ); - break; - case 'args': - $value = array_merge( $this->meta( 'args_get' ), $this->meta( 'args_post' ) ); - break; - case 'args_names': - $value = $this->args_names( $this->meta( 'args' ) ); - break; - case 'request_cookies': - $value = $this->request->get_cookies(); - break; - case 'request_cookies_names': - $value = $this->args_names( $this->meta( 'request_cookies' ) ); - break; - case 'files': - $value = array(); - foreach ( $this->request->get_files() as $f ) { - $value[] = array( $f['name'], $f['filename'] ); - } - break; - case 'files_names': - $value = $this->args_names( $this->meta( 'files' ) ); - break; - } - $this->metadata[ $key ] = $value; - } - - return $this->metadata[ $key ]; - } - - /** - * State values. - * - * @param string $prefix Prefix. - */ - private function state_values( $prefix ) { - $output = array(); - $len = strlen( $prefix ); - foreach ( $this->state as $k => $v ) { - if ( 0 === stripos( $k, $prefix ) ) { - $output[ substr( $k, $len ) ] = $v; - } - } - - return $output; - } - - /** - * Get the body processor. - * - * @return string - */ - private function get_body_processor() { - return $this->body_processor; - } - - /** - * Set the body processor. - * - * @param string $processor Processor to set. Either 'URLENCODED' or 'JSON'. - * - * @return void - */ - public function set_body_processor( $processor ) { - if ( $processor === 'URLENCODED' || $processor === 'JSON' ) { - $this->body_processor = $processor; - } - } - - /** - * Change a string to all lowercase and replace spaces and underscores with dashes. - * - * @param string $name Name. - * @return string - */ - public function normalize_header_name( $name ) { - return str_replace( array( ' ', '_' ), '-', strtolower( $name ) ); - } - - /** - * Get match-able values from a collection of targets. - * - * This function expects an associative array of target items, and returns an array of possible values from those targets that can be used to match against. - * The key is the lowercase target name (i.e. `args`, `request_headers`, etc) - see https://github.com/SpiderLabs/ModSecurity/wiki/Reference-Manual-(v3.x)#Variables - * The value is an associative array of options that define how to narrow down the returned values for that target if it's an array (ARGS, for example). The possible options are: - * count: If `true`, then the returned value will a count of how many matched targets were found, rather then the actual values of those targets. - * For example, &ARGS_GET will return the number of keys the query string. - * only: If specified, then only values in that target that match the given key will be returned. - * For example, ARGS_GET:id|ARGS_GET:/^name/ will only return the values for `$_GET['id']` and any key in `$_GET` that starts with `name` - * except: If specified, then values in that target will be left out from the returned values (even if they were included in an `only` option) - * For example, ARGS_GET|!ARGS_GET:z will return every value from `$_GET` except for `$_GET['z']`. - * - * This function will return an array of associative arrays. Each with: - * name: The target name that this value came from (i.e. the key in the input `$targets` argument ) - * source: For targets that are associative arrays (like ARGS), this will be the target name AND the key in that target (i.e. "args:z" for ARGS:z) - * value: The value that was found in the associated target. - * - * @param TargetBag $targets An assoc. array with keys that are target name(s) and values are options for how to process that target (include/exclude rules, whether to return values or counts). - * @return array{name: string, source: string, value: mixed}[] - */ - public function normalize_targets( $targets ) { - $return = array(); - foreach ( $targets as $k => $v ) { - $count_only = isset( $v['count'] ) ? self::NORMALIZE_ARRAY_COUNT : 0; - $only = isset( $v['only'] ) ? $v['only'] : array(); - $except = isset( $v['except'] ) ? $v['except'] : array(); - $_k = strtolower( $k ); - switch ( $_k ) { - case 'request_headers': - $this->normalize_array_target( - // get the headers that came in with this request - $this->meta( 'headers' ), - // ensure only and exclude filters are normalized - array_map( array( $this->request, 'normalize_header_name' ), $only ), - array_map( array( $this->request, 'normalize_header_name' ), $except ), - $k, - $return, - // flags - $count_only - ); - continue 2; - case 'request_headers_names': - $this->normalize_array_target( $this->meta( 'headers_names' ), $only, $except, $k, $return, $count_only | self::NORMALIZE_ARRAY_MATCH_VALUES ); - continue 2; - case 'request_method': - case 'request_protocol': - case 'request_uri': - case 'request_uri_raw': - case 'request_filename': - case 'request_basename': - case 'request_body': - case 'query_string': - case 'request_line': - $v = $this->meta( $_k ); - break; - case 'tx': - case 'ip': - $this->normalize_array_target( $this->state_values( "$k." ), $only, $except, $k, $return, $count_only ); - continue 2; - case 'request_cookies': - case 'args': - case 'args_get': - case 'args_post': - case 'files': - $this->normalize_array_target( $this->meta( $_k ), $only, $except, $k, $return, $count_only ); - continue 2; - case 'request_cookies_names': - case 'args_names': - case 'args_get_names': - case 'args_post_names': - case 'files_names': - // get the "full" data (for 'args_names' get data for 'args') and stripe it down to just the key names - $data = array_map( - function ( $item ) { - return $item[0]; }, - $this->meta( substr( $_k, 0, -6 ) ) - ); - $this->normalize_array_target( $data, $only, $except, $k, $return, $count_only | self::NORMALIZE_ARRAY_MATCH_VALUES ); - continue 2; - default: - var_dump( 'Unknown target', $k, $v ); - exit( 0 ); - } - $return[] = array( - 'name' => $k, - 'value' => $v, - 'source' => $k, - ); - } - - return $return; - } - - /** - * Verifies if the IP from the current request is in an array. - * - * @param array $array Array of IP addresses to verify the request IP against. - * @return bool - */ - public function is_ip_in_array( $array ) { - $real_ip = $this->request->get_real_user_ip_address(); - $array_length = count( $array ); - - for ( $i = 0; $i < $array_length; $i++ ) { - // Check if the IP matches a provided range or CIDR notation. - $range = strpos( $array[ $i ], '/' ) !== false ? array( $array[ $i ], null ) : explode( '-', $array[ $i ] ); - if ( count( $range ) === 2 ) { - if ( IP_Utils::ip_address_is_in_range( $real_ip, $range[0], $range[1] ) ) { - return true; - } - continue; - } - - // Check if the IP is an exact match. - if ( $real_ip === $array[ $i ] ) { - return true; - } - } - - return false; - } - - /** - * Extract values from an associative array, potentially applying filters and/or counting results. - * - * @param array{0: string, 1: scalar}|scalar[] $source The source assoc. array of values (i.e. $_GET, $_SERVER, etc.). - * @param string[] $only Only include the values for these keys in the output. - * @param string[] $excl Never include the values for these keys in the output. - * @param string $name The name of this target (see https://github.com/SpiderLabs/ModSecurity/wiki/Reference-Manual-(v3.x)#Variables). - * @param array $results Array to add output values to, will be modified by this method. - * @param int $flags Any of the NORMALIZE_ARRAY_* constants defined at the top of the class. - */ - private function normalize_array_target( $source, $only, $excl, $name, &$results, $flags = 0 ) { - $output = array(); - $has_only = isset( $only[0] ); - $has_excl = isset( $excl[0] ); - - foreach ( $source as $source_key => $source_val ) { - if ( is_array( $source_val ) ) { - // if $source_val looks like a tuple from flatten_array(), then use the tuple as the key and value - $source_key = $source_val[0]; - $source_val = $source_val[1]; - } - $filter_match = ( $flags & self::NORMALIZE_ARRAY_MATCH_VALUES ) > 0 ? $source_val : $source_key; - // if this key is on the "exclude" list, skip it - if ( $has_excl && $this->key_matches( $filter_match, $excl ) ) { - continue; - } - // if this key isn't in our "only" list, then skip it - if ( $has_only && ! $this->key_matches( $filter_match, $only ) ) { - continue; - } - // otherwise add this key/value to our output - $output[] = array( $source_key, $source_val ); - } - - if ( ( $flags & self::NORMALIZE_ARRAY_COUNT ) > 0 ) { - // If we've been told to just count the values, then just count them. - $results[] = array( - 'name' => (string) $name, - 'value' => count( $output ), - 'source' => '&' . $name, - ); - } else { - foreach ( $output as list( $item_name, $item_value ) ) { - $results[] = array( - 'name' => (string) $item_name, - 'value' => $item_value, - 'source' => "$name:$item_name", - ); - } - } - - return $results; - } - - /** - * Given an array of tuples - probably from flatten_array() - return a new array - * consisting of only the first value (the key name) from each tuple. - * - * @param array{0:string, 1:scalar}[] $flat_array An array of tuples. - * @return string[] - */ - private function args_names( $flat_array ) { - $names = array_map( - function ( $tuple ) { - return $tuple[0]; - }, - $flat_array - ); - return array_unique( $names ); - } - - /** - * Return whether or not a given $input key matches one of the given $patterns. - * - * @param string $input Key name to test against patterns. - * @param string[] $patterns Patterns to test key name with. - * @return bool - */ - private function key_matches( $input, $patterns ) { - foreach ( $patterns as $p ) { - if ( '/' === $p[0] ) { - if ( 1 === preg_match( $p, $input ) ) { - return true; - } - } elseif ( 0 === strcasecmp( $p, $input ) ) { - return true; - } - } - - return false; - } - - /** - * Sanitize output generated from the request that was blocked. - * - * @param string $output Output to sanitize. - */ - public function sanitize_output( $output ) { - $url_decoded_output = rawurldecode( $output ); - $html_entities_output = htmlentities( $url_decoded_output, ENT_QUOTES, 'UTF-8' ); - // @phpcs:disable Squiz.Strings.DoubleQuoteUsage.NotRequired - $escapers = array( "\\", "/", "\"", "\n", "\r", "\t", "\x08", "\x0c" ); - $replacements = array( "\\\\", "\\/", "\\\"", "\\n", "\\r", "\\t", "\\f", "\\b" ); - // @phpcs:enable Squiz.Strings.DoubleQuoteUsage.NotRequired - - return( str_replace( $escapers, $replacements, $html_entities_output ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php deleted file mode 100644 index 61a930b2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php +++ /dev/null @@ -1,184 +0,0 @@ -guard_against_missing_abspath(); - $this->initialize_constants(); - } - - /** - * Ensures that this class is not used unless we are in the right context. - * - * @throws Waf_Exception If we are outside of WordPress. - * - * @return void - */ - private function guard_against_missing_abspath() { - - if ( ! defined( 'ABSPATH' ) ) { - throw new Waf_Exception( 'Cannot generate the WAF bootstrap if we are not running in WordPress context.' ); - } - } - - /** - * Initializes the constants required for generating the bootstrap, if they have not been initialized yet. - * - * @return void - */ - private function initialize_constants() { - Waf_Constants::initialize_constants(); - } - - /** - * Initialized the WP filesystem and serves as a mocking hook for tests. - * - * Should only be implemented after the wp_loaded action hook: - * - * @link https://developer.wordpress.org/reference/functions/wp_filesystem/#more-information - * - * @return void - */ - protected function initialize_filesystem() { - if ( ! function_exists( '\\WP_Filesystem' ) ) { - require_once ABSPATH . 'wp-admin/includes/file.php'; - } - - WP_Filesystem(); - } - - /** - * Finds the path to the autoloader, which can then be used to require the autoloader in the generated boostrap file. - * - * @throws Waf_Exception In case the autoloader file can not be found. - * - * @return string|null - */ - private function locate_autoloader_file() { - global $jetpack_autoloader_loader; - - $autoload_file = null; - - // Try the Jetpack autoloader. - if ( isset( $jetpack_autoloader_loader ) ) { - $class_file = $jetpack_autoloader_loader->find_class_file( Waf_Runner::class ); - if ( $class_file ) { - $autoload_file = dirname( $class_file, 5 ) . '/vendor/autoload.php'; - } - } - - // Try Composer's autoloader. - if ( null === $autoload_file - && is_callable( array( InstalledVersions::class, 'getInstallPath' ) ) - && InstalledVersions::isInstalled( 'automattic/jetpack-waf' ) - ) { - $package_file = InstalledVersions::getInstallPath( 'automattic/jetpack-waf' ); - if ( substr( $package_file, -23 ) === '/automattic/jetpack-waf' ) { - $autoload_file = dirname( $package_file, 3 ) . '/vendor/autoload.php'; - } - } - - // Guess. First look for being in a `vendor/automattic/jetpack-waf/src/', then see if we're standalone with our own vendor dir. - if ( null === $autoload_file ) { - $autoload_file = dirname( __DIR__, 4 ) . '/vendor/autoload.php'; - if ( ! file_exists( $autoload_file ) ) { - $autoload_file = dirname( __DIR__ ) . '/vendor/autoload.php'; - } - } - - // Check that the determined file actually exists. - if ( ! file_exists( $autoload_file ) ) { - throw new Waf_Exception( 'Can not find autoloader, and the WAF standalone boostrap will not work without it.' ); - } - - return $autoload_file; - } - - /** - * Gets the path to the bootstrap.php file. - * - * @return string The bootstrap.php file path. - */ - public function get_bootstrap_file_path() { - return trailingslashit( JETPACK_WAF_DIR ) . 'bootstrap.php'; - } - - /** - * Gets the entrypoint file. - * - * @return string The entrypoint file. - */ - private function get_entrypoint() { - return defined( 'JETPACK_WAF_ENTRYPOINT' ) ? JETPACK_WAF_ENTRYPOINT : 'rules/rules.php'; - } - - /** - * Generates the bootstrap file. - * - * @throws File_System_Exception If the filesystem is not available. - * @throws File_System_Exception If the WAF directory can not be created. - * @throws File_System_Exception If the bootstrap file can not be created. - * - * @return string Absolute path to the bootstrap file. - */ - public function generate() { - - $this->initialize_filesystem(); - - global $wp_filesystem; - if ( ! $wp_filesystem ) { - throw new File_System_Exception( 'Can not work without the file system being initialized.' ); - } - - $autoloader_file = $this->locate_autoloader_file(); - - $bootstrap_file = $this->get_bootstrap_file_path(); - $entrypoint = $this->get_entrypoint(); - $mode_option = get_option( Waf_Runner::MODE_OPTION_NAME, false ); - $share_data_option = get_option( Waf_Runner::SHARE_DATA_OPTION_NAME, false ); - $share_debug_data_option = get_option( Waf_Runner::SHARE_DEBUG_DATA_OPTION_NAME, false ); - - // phpcs:disable WordPress.PHP.DevelopmentFunctions - $code = "is_dir( JETPACK_WAF_DIR ) ) { - if ( ! $wp_filesystem->mkdir( JETPACK_WAF_DIR ) ) { - throw new File_System_Exception( 'Failed creating WAF standalone bootstrap file directory: ' . JETPACK_WAF_DIR ); - } - } - - if ( ! $wp_filesystem->put_contents( $bootstrap_file, $code ) ) { - throw new File_System_Exception( 'Failed writing WAF standalone bootstrap file to: ' . $bootstrap_file ); - } - - return $bootstrap_file; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php deleted file mode 100644 index 71494971..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php +++ /dev/null @@ -1,180 +0,0 @@ - Waf_Blocklog_Manager::get_current_day_block_count(), - 'thirty_days' => Waf_Blocklog_Manager::get_thirty_days_block_counts(), - 'all_time' => Waf_Blocklog_Manager::get_all_time_block_count(), - ); - } - - /** - * Get IP allow list count - * - * @return int The number of valid IP addresses in the allow list - * - * @deprecated 0.20.1 Use Automattic\Jetpack\Waf\Waf_Blocklog_Manager API instead. - */ - public static function get_ip_allow_list_count() { - _deprecated_function( __METHOD__, 'waf-0.20.1', 'Automattic\Jetpack\Waf\Waf_Blocklog_Manager' ); - - $ip_allow_list = get_option( Waf_Rules_Manager::IP_ALLOW_LIST_OPTION_NAME ); - - if ( ! $ip_allow_list ) { - return 0; - } - - $results = IP_Utils::get_ip_addresses_from_string( $ip_allow_list ); - - return count( $results ); - } - - /** - * Get IP block list count - * - * @return int The number of valid IP addresses in the block list - * - * @deprecated 0.20.1 Use Automattic\Jetpack\Waf\Waf_Blocklog_Manager API instead. - */ - public static function get_ip_block_list_count() { - _deprecated_function( __METHOD__, 'waf-0.20.1', 'Automattic\Jetpack\Waf\Waf_Blocklog_Manager' ); - - $ip_block_list = get_option( Waf_Rules_Manager::IP_BLOCK_LIST_OPTION_NAME ); - - if ( ! $ip_block_list ) { - return 0; - } - - $results = IP_Utils::get_ip_addresses_from_string( $ip_block_list ); - - return count( $results ); - } - - /** The global stats cache - * - * @var array|null - */ - public static $global_stats = null; - - /** - * Get Rules version - * - * @return bool|string False if value is not found. The current stored rules version if cache is found. - * - * @deprecated 0.12.3 Use Automattic\Jetpack\Waf\Waf_Stats::get_automatic_rules_last_updated() to version the rules instead. - */ - public static function get_rules_version() { - _deprecated_function( __METHOD__, 'waf-0.12.3', 'Automattic\Jetpack\Waf\Waf_Stats::get_automatic_rules_last_updated' ); - - return get_option( Waf_Rules_Manager::VERSION_OPTION_NAME ); - } - - /** - * Get Automatic Rules last updated timestamp - * - * @return bool|string False if value is not found. The timestamp the current stored rules was last updated if cache is found. - */ - public static function get_automatic_rules_last_updated() { - return get_option( Waf_Rules_Manager::AUTOMATIC_RULES_LAST_UPDATED_OPTION_NAME ); - } - - /** - * Checks if the current cached global stats is expired and should be renewed - * - * @return boolean - */ - public static function is_global_stats_cache_expired() { - $option_timestamp = get_option( 'jetpack_protect_global_stats_timestamp' ); - - if ( ! $option_timestamp ) { - return true; - } - - return time() > (int) $option_timestamp; - } - - /** - * Checks if we should consider the stored cache or bypass it - * - * @return boolean - */ - public static function should_use_global_stats_cache() { - return ! ( defined( 'JETPACK_PROTECT_DEV__BYPASS_CACHE' ) && JETPACK_PROTECT_DEV__BYPASS_CACHE ); - } - - /** - * Get the global stats from the API endpoint - */ - public static function fetch_global_stats_from_api() { - $url = esc_url_raw( 'https://public-api.wordpress.com/wpcom/v2/jetpack-protect-global-stats' ); - $response = wp_remote_get( $url ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code || empty( $response['body'] ) ) { - return new \WP_Error( 'failed_fetching_global_stats', 'Failed to fetch global stats data from the server', array( 'status' => $response_code ) ); - } - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - - update_option( 'jetpack_protect_global_stats', maybe_serialize( $body ) ); - update_option( 'jetpack_protect_global_stats_timestamp', time() + 86400 ); // Caches expires after 24 hours. - - return $body; - } - - /** - * Gets the current cached global stats - * - * @return bool|array False if value is not found. Array with values if cache is found. - */ - public static function get_global_stats_from_options() { - return maybe_unserialize( get_option( 'jetpack_protect_global_stats' ) ); - } - - /** - * Get the global stats - * If the cache is expired, it will fetch the data from the API - * If the cache is not expired, it will return the cached data - * - * @param bool $refresh_from_wpcom Whether to refresh the data from the API. - * @return array|\WP_Error - */ - public static function get_global_stats( $refresh_from_wpcom = false ) { - if ( self::$global_stats !== null ) { - return self::$global_stats; - } - - if ( $refresh_from_wpcom || ! self::should_use_global_stats_cache() || self::is_global_stats_cache_expired() ) { - $global_stats = self::fetch_global_stats_from_api(); - } else { - $global_stats = self::get_global_stats_from_options(); - } - - // Ensure that $global_stats is of the correct type - if ( ( ! is_object( $global_stats ) && ! ( $global_stats instanceof \WP_Error ) ) ) { - return new \WP_Error( 'unexpected_type', 'Unexpected type or null returned for global stats' ); - } - - return $global_stats; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php deleted file mode 100644 index e2160997..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php +++ /dev/null @@ -1,403 +0,0 @@ -normalize_path( str_replace( '\\', '/', $value ) ); - } - - /** - * Removes all NUL bytes from input. - * - * @param string $value value to be filtered. - * @return string - */ - public function remove_nulls( $value ) { - return str_replace( "\x0", '', $value ); - } - - /** - * Remove all whitespace characters from input. - * - * @param string $value value to be filtered. - * @return string - */ - public function remove_whitespace( $value ) { - return preg_replace( '/\s/', '', $value ); - } - - /** - * Replaces each occurrence of a C-style comment (/ * ... * /) with a single space. - * Unterminated comments will also be replaced with a space. However, a standalone termination of a comment (* /) will not be acted upon. - * - * @param string $value value to be filtered. - * @return string - */ - public function replace_comments( $value ) { - $value = preg_replace( '~/\*.*?\*/|/\*.*?$~Ds', ' ', $value ); - return explode( '/*', $value, 2 )[0]; - } - - /** - * Removes common comments chars (/ *, * /, --, #). - * - * @param string $value value to be filtered. - * @return string - */ - public function remove_comments_char( $value ) { - return preg_replace( '~/*|*/|--|#|//~', '', $value ); - } - - /** - * Replaces each NUL byte in input with a space. - * - * @param string $value value to be filtered. - * @return string - */ - public function replace_nulls( $value ) { - return str_replace( "\x0", ' ', $value ); - } - - /** - * Decode a URL-encoded input string. - * - * @param string $value value to be decoded. - * @return string - */ - public function url_decode( $value ) { - return urldecode( $value ); - } - - /** - * Decode a URL-encoded input string. - * - * @param string $value value to be decoded. - * @return string - */ - public function url_decode_uni( $value ) { - error_log( 'JETPACKWAF TRANSFORM NOT IMPLEMENTED: urlDecodeUni' ); - return $value; - } - - /** - * Decode a json encoded input string. - * - * @param string $value value to be decoded. - * @return string - */ - public function js_decode( $value ) { - error_log( 'JETPACKWAF TRANSFORM NOT IMPLEMENTED: jsDecode' ); - return $value; - } - - /** - * Convert all characters to uppercase. - * - * @param string $value value to be encoded. - * @return string - */ - public function uppercase( $value ) { - return strtoupper( $value ); - } - - /** - * Calculate a SHA1 hash from the input string. - * - * @param mixed $value value to be hashed. - * @return string - */ - public function sha1( $value ) { - return sha1( $value, true ); - } - - /** - * Remove whitespace from the left side of the input string. - * - * @param string $value value to be trimmed. - * @return string - */ - public function trim_left( $value ) { - return ltrim( $value, self::TRIM_CHARS ); - } - - /** - * Remove whitespace from the right side of the input string. - * - * @param string $value value to be trimmed. - * @return string - */ - public function trim_right( $value ) { - return rtrim( $value, self::TRIM_CHARS ); - } - - /** - * Remove whitespace from both sides of the input string. - * - * @param string $value value to be trimmed. - * @return string - */ - public function trim( $value ) { - return trim( $value, self::TRIM_CHARS ); - } - - /** - * Convert UTF-8 characters to Unicode characters. - * - * This function iterates through each character of the input string, checks the ASCII value, - * and converts it to its corresponding Unicode representation. It handles characters that are - * represented with 1 to 4 bytes in UTF-8. - * - * @param string $str The string value to be encoded from UTF-8 to Unicode. - * @return string The converted string with Unicode representation. - */ - public function utf8_to_unicode( $str ) { - $unicodeStr = ''; - $strLen = strlen( $str ); - $i = 0; - - // Iterate through each character of the input string. - while ( $i < $strLen ) { - // Get the ASCII value of the current character. - $value = ord( $str[ $i ] ); - - if ( $value < 128 ) { - // If the character is in the ASCII range (0-127), directly add it to the Unicode string. - $unicodeStr .= chr( $value ); - ++$i; - } else { - // For characters outside the ASCII range, determine the number of bytes in the UTF-8 representation. - $unicodeValue = ''; - if ( $value >= 192 && $value <= 223 ) { - // For characters represented with 2 bytes in UTF-8. - $unicodeValue = ( ord( $str[ $i ] ) & 0x1F ) << 6 | ( ord( $str[ $i + 1 ] ) & 0x3F ); - $i += 2; - } elseif ( $value >= 224 && $value <= 239 ) { - // For characters represented with 3 bytes in UTF-8. - $unicodeValue = ( ord( $str[ $i ] ) & 0x0F ) << 12 | ( ord( $str[ $i + 1 ] ) & 0x3F ) << 6 | ( ord( $str[ $i + 2 ] ) & 0x3F ); - $i += 3; - } elseif ( $value >= 240 && $value <= 247 ) { - // For characters represented with 4 bytes in UTF-8. - $unicodeValue = ( ord( $str[ $i ] ) & 0x07 ) << 18 | ( ord( $str[ $i + 1 ] ) & 0x3F ) << 12 | ( ord( $str[ $i + 2 ] ) & 0x3F ) << 6 | ( ord( $str[ $i + 3 ] ) & 0x3F ); - $i += 4; - } else { - // If the sequence does not match any known UTF-8 pattern, skip to the next character. - ++$i; - continue; - } - // Convert the Unicode value to a formatted string and append it to the Unicode string. - $unicodeStr .= sprintf( '%%u%04X', $unicodeValue ); - } - } - - return strtolower( $unicodeStr ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php deleted file mode 100644 index 59631e8c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php +++ /dev/null @@ -1,23 +0,0 @@ -getMessage() ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/functions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/functions.php deleted file mode 100644 index e7391c62..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/automattic/jetpack-waf/src/functions.php +++ /dev/null @@ -1,120 +0,0 @@ - [ "x" => [ "y" => "..." ] ] ] - * However, modsecurity (and thus our WAF rules) expect the original (non-nested) names. - * - * Therefore, this method takes an array of any depth and returns a single-depth array with nested - * keys translated back to a single string with brackets. - * - * Because there might be multiple items with the same name, this function will return an array of tuples, - * with the first item in the tuple the re-created original field name, and the second item the value. - * - * @example - * flatten_array( [ "field1" => "abc", "field2" => [ "d", "e", "f" ] ] ) - * => [ - * [ "field1", "abc" ], - * [ "field2[0]", "d" ], - * [ "field2[1]", "e" ], - * [ "field2[2]", "f" ], - * ] - * - * @param array $array An array that resembles one of the PHP superglobals like $_GET or $_POST. - * @param string $key_prefix String that should be prepended to the keys output by this function. - * Usually only used internally as part of recursion when flattening a nested array. - * @param bool|null $dot_notation Whether to use dot notation instead of bracket notation. - * - * @return array{0: string, 1: scalar}[] $key_prefix An array of key/value tuples, one for each distinct value in the input array. - */ -function flatten_array( $array, $key_prefix = '', $dot_notation = null ) { - $return = array(); - foreach ( $array as $source_key => $source_value ) { - $key = $source_key; - if ( ! empty( $key_prefix ) ) { - $key = $dot_notation ? "$key_prefix.$source_key" : $key_prefix . "[$source_key]"; - } - - if ( ! is_array( $source_value ) ) { - $return[] = array( $key, $source_value ); - } else { - $return = array_merge( $return, flatten_array( $source_value, $key, $dot_notation ) ); - } - } - return $return; -} - -/** - * Polyfill for getallheaders, which is not available in all PHP environments. - * - * @link https://github.com/ralouphie/getallheaders - */ -if ( ! function_exists( 'getallheaders' ) ) { - /** - * Get all HTTP header key/values as an associative array for the current request. - * - * @return array The HTTP header key/value pairs. - */ - function getallheaders() { - // phpcs:disable WordPress.Security.ValidatedSanitizedInput - $headers = array(); - - $copy_server = array( - 'CONTENT_TYPE' => 'Content-Type', - 'CONTENT_LENGTH' => 'Content-Length', - 'CONTENT_MD5' => 'Content-Md5', - ); - - foreach ( $_SERVER as $key => $value ) { - if ( substr( $key, 0, 5 ) === 'HTTP_' ) { - $key = substr( $key, 5 ); - if ( ! isset( $copy_server[ $key ] ) || ! isset( $_SERVER[ $key ] ) ) { - $key = str_replace( ' ', '-', ucwords( strtolower( str_replace( '_', ' ', $key ) ) ) ); - $headers[ $key ] = $value; - } - } elseif ( isset( $copy_server[ $key ] ) ) { - $headers[ $copy_server[ $key ] ] = $value; - } - } - - if ( ! isset( $headers['Authorization'] ) ) { - if ( isset( $_SERVER['REDIRECT_HTTP_AUTHORIZATION'] ) ) { - $headers['Authorization'] = $_SERVER['REDIRECT_HTTP_AUTHORIZATION']; - } elseif ( isset( $_SERVER['PHP_AUTH_USER'] ) ) { - $basic_pass = $_SERVER['PHP_AUTH_PW'] ?? ''; - $headers['Authorization'] = 'Basic ' . base64_encode( $_SERVER['PHP_AUTH_USER'] . ':' . $basic_pass ); - } elseif ( isset( $_SERVER['PHP_AUTH_DIGEST'] ) ) { - $headers['Authorization'] = $_SERVER['PHP_AUTH_DIGEST']; - } - } - - return $headers; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/i18n-map.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/i18n-map.php deleted file mode 100644 index a35c898a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/jetpack_vendor/i18n-map.php +++ /dev/null @@ -1,80 +0,0 @@ - 'jetpack-protect', - 'type' => 'plugins', - 'packages' => array( - 'jetpack-admin-ui' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-admin-ui', - 'ver' => '0.5.7', - ), - 'jetpack-assets' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-assets', - 'ver' => '4.0.14', - ), - 'jetpack-boost-core' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-boost-core', - 'ver' => '0.3.9', - ), - 'jetpack-boost-speed-score' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-boost-speed-score', - 'ver' => '0.4.6', - ), - 'jetpack-config' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-config', - 'ver' => '3.0.1', - ), - 'jetpack-connection' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-connection', - 'ver' => '6.8.1', - ), - 'jetpack-explat' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-explat', - 'ver' => '0.2.13', - ), - 'jetpack-ip' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-ip', - 'ver' => '0.4.6', - ), - 'jetpack-jitm' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-jitm', - 'ver' => '4.2.7', - ), - 'jetpack-licensing' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-licensing', - 'ver' => '3.0.8', - ), - 'jetpack-my-jetpack' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-my-jetpack', - 'ver' => '5.9.1', - ), - 'jetpack-password-checker' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-password-checker', - 'ver' => '0.4.7', - ), - 'jetpack-plugins-installer' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-plugins-installer', - 'ver' => '0.5.4', - ), - 'jetpack-protect-models' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-protect-models', - 'ver' => '0.5.4', - ), - 'jetpack-protect-status' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-protect-status', - 'ver' => '0.5.8', - ), - 'jetpack-sync' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-sync', - 'ver' => '4.9.2', - ), - 'jetpack-transport-helper' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-transport-helper', - 'ver' => '0.3.1', - ), - 'jetpack-waf' => array( - 'path' => 'jetpack_vendor/automattic/jetpack-waf', - 'ver' => '0.23.8', - ), - ), -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/readme.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/readme.txt deleted file mode 100644 index 1b2795af..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/readme.txt +++ /dev/null @@ -1,193 +0,0 @@ -=== Jetpack Protect === -Contributors: automattic, retrofox, leogermani, renatoagds, bjorsch, ebinnion, fgiannar, zinigor, miguelxavierpenha, dsmart, jeherve, manzoorwanijk, njweller, oskosk, samiff, siddarthan, wpkaren, arsihasi, kraftbj, kev, sermitr, kangzj, pabline, dkmyta -Tags: jetpack, protect, security, malware, scan -Requires at least: 6.6 -Requires PHP: 7.2 -Tested up to: 6.7 -Stable tag: 4.0.0 -License: GPLv2 or later -License URI: http://www.gnu.org/licenses/gpl-2.0.html - -Free daily malware scanning and WordPress site security. Jetpack Protect leverages the extensive database of WPScan, an Automattic brand, that has over 25,000 registered malware and vulnerabilities. No configuration required! - -== Description == - -== TOTAL SITE SECURITY FROM WORDPRESS EXPERTS == - -Jetpack Protect is a free and essential WordPress security plugin that scans your site and warns you about vulnerabilities, keeping your site one step ahead of security threats. It’s easy to use; setup requires just a few clicks! - -By upgrading Protect, you also unlock malware scanning with one-click fixes for most issues and instant notifications when threats are detected. Our automated Web Application Firewall (WAF) also protects your site from bad actors around the clock. - -Jetpack Protect is created by WordPress experts; our parent company Automattic is behind Jetpack, WordPress.com, WooCommerce, WPScan, and much more. There is no better company to understand the security needs of WordPress sites. - -== WHAT DOES JETPACK PROTECT (FREE) CHECK FOR? == - -Jetpack Protect scans your site on a daily basis and warns you about: -- The version of WordPress installed, and any associated vulnerabilities -- What plugins are installed, and any related vulnerabilities -- What themes are installed, and any associated vulnerabilities - -= What are vulnerabilities? Why do I need to scan my site regularly? = -Site vulnerabilities are flaws in a website's code that weaken the site's overall security. These can be introduced to a site in various ways, in most cases unintentionally. - -Some of the ways vulnerabilities can be introduced to a site are: -- Poorly written site code -- Plugin and theme bugs -- WordPress version bugs -- System misconfigurations - -If a bad actor detects a vulnerability on your site, they can exploit it to access sensitive information, update your site, and more to damage your business or brand. - -That’s why it’s essential to use a reputable and reliable vulnerability & malware site scanner like Jetpack Protect to safeguard your site. - -= Can I use Jetpack Scan to fix a site that is already infected? = - -Jetpack Protect (Scan) detects and prevents attacks, but is not designed to fully clean up sites infected before it was active. If your site has malware, take immediate action to clean it up and remove the malicious code. - -To clean up your site, we suggest using a malware removal tool, or if possible restore from a backup taken before the infection. We recommend using Jetpack VaultPress Backup in conjunction with Jetpack Scan to secure your website. - -[Learn more about cleaning your site](https://jetpack.com/support/scan/how-to-clean-your-hacked-wordpress-site/) - -== BRUTE FORCE ATTACK PROTECTION == - -Jetpack Protect blocks unwanted login attempts from malicious botnets and distributed attacks. - -= Is my site under attack? = -Brute force attacks are the most common form of hacking — and hackers don’t discriminate. As the most commonly used Content Management System on the web, WordPress sites make an attractive target for hackers looking to exploit code vulnerabilities unique to WordPress. - -Using large networks of computers known as botnets, hackers can try to gain access to your site by using thousands of different combinations of usernames and passwords until they find the right one. - -Recently, attackers have found a way to “amplify” these attacks against the WordPress XML-RPC file – making it easier for attackers to try and break into your site. - -WordPress brute force attacks can: -- Slow down your site (or cause it to stop responding) because of repeated server requests. -- Allow unauthorized access to your site for hackers to modify your code or insert spammy links. -- Put your site content and data at risk. - -That’s where Jetpack Protect comes in. Our state-of-the-art security tools automatically block these attacks, protecting your WordPress site from unauthorized access. - -On average, Jetpack blocks 5,193 WordPress brute force attacks over a site’s lifetime. It allows you to protect yourself against both traditional brute force attacks and distributed brute force attacks that use many servers against your site. - -== UPGRADE PROTECT TO REMOVE MALWARE IN ONE CLICK AND BE PROTECTED BY OUR WAF == -By upgrading Protect, you unlock total site security from WordPress experts: -- Automated daily malware scanning in addition to vulnerability checks -- One-click fixes for most issues -- Web Application Firewall (WAF) with automatic rule updates -- Instant email notifications when threats are detected -- Priority support from WordPress experts - -= What is malware? Why do I need to protect against it? = -Malware is malicious code or software that has been created by bad actors to disrupt, damage, or gain access to your site. There are many ways that malware can get onto your WordPress site. The most common method is through attackers using vulnerable plugins or themes to install malware. - -Similar to the vulnerabilities listed above, bad actors can use malware to capture sensitive information, damage your site, and harm your business or brand. - -Jetpack Protect instantly notifies you of any threats detected, with one-click fixes for most issues. - -= What is a Web Application Firewall (WAF)? = -A web application firewall blocks traffic and malicious requests to your site from known bad actors. - -As threats are detected, new rules are added to Jetpack Protect’s firewall, which provides around-the-clock protection for your WordPress site. - -== OVER 53,500 REGISTERED VULNERABILITIES IN OUR DATABASE == - -WordPress security is something that evolves over time. Jetpack Protect leverages the extensive database of WPScan, an Automattic brand. All vulnerabilities are entered into our database by dedicated WordPress security professionals and updated constantly as new information becomes available. - -== JETPACK PROTECT IS EASY TO SETUP AND USE == - -There’s nothing to configure – the setup process is as easy as: -1. Install and activate the plugin -2. Set up it with one click. - -After you activate the plugin, Jetpack Protect will run daily automatic malware scans on your WordPress site and update you on vulnerabilities associated with your installed plugins, themes, and WordPress core. - -== WITH 💚 BY JETPACK == - -This is just the start! - -We are working hard to bring more features and improvements to Jetpack Protect. Let us know your thoughts and ideas! - -== FURTHER READING == - -- [Jetpack: Security, performance, and growth tools made for WordPress sites by the WordPress experts.](https://jetpack.com/) -- You can follow the [Jetpack Twitter](https://twitter.com/jetpack?lang=en) account to catch up on our latest WordPress security recommendations and updates. -- [WordPress Security: How to Protect Your Site From Hackers](https://jetpack.com/blog/category/security/page/3/) -- [Should You Use Jetpack for WordPress Security?](https://jetpack.com/blog/should-you-use-jetpack-for-wordpress-security/) -- [Jetpack Acquires WordPress Vulnerability Database WPScan](https://jetpack.com/blog/jetpack-acquires-wordpress-vulnerability-database-wpscan/#more-139339) - -== FAQ == - -= How does Jetpack Protect help your WordPress Site security? = - -Protect is a free WordPress security and malware scanner plugin that scans your site and lets you know possible malware and security threats on your installed plugins, themes, and core files. - -The free plan scans your site for WordPress version, plugin, and theme vulnerabilities from our extensive vulnerability database (53,500) that is powered by WPScan. - -By upgrading Protect, you gain access to WordPress malware scanning with one-click fixes, instant threat notifications, and our Web application Firewall (WAF) that protects your site around the clock. - -= Does this plugin require the Jetpack plugin to work? = - -Jetpack Protect does not require the Jetpack plugin to run and secure your site. - -= What are the differences between Jetpack Protect, Jetpack Scan, and WPScan plugins? = - -Jetpack Protect is a new WordPress security plugin from Jetpack containing our security features only. You can start with Jetpack Protect’s free vulnerability scanning features and upgrade Jetpack Protect to access automated malware scanning and our web application firewall. By upgrading Protect, you are enabling Jetpack Scan to the plugin. - -Jetpack Scan is a product that can be purchased for use in conjunction with the main Jetpack plugin or Jetpack Protect. Jetpack Scan includes automated malware scanning and our web application firewall but does not contain the vulnerability scanning feature from the Protect plugin. If you purchase Jetpack Security or Jetpack Complete, Jetpack Scan is also included in those bundles. - -If you are already a Jetpack Scan, Jetpack Security, or Jetpack Complete customer, you can also take advantage of Jetpack Protect’s vulnerability scanning feature by installing the Jetpack Protect plugin. - -WPScan is an enterprise vulnerability scanning solution. It is not recommended for small to medium-sized businesses. If you are an enterprise company looking for custom WordPress site protection solutions, please visit: https://wpscan.com/ - -For small to medium-sized businesses, you can access our vulnerability scanning solution in the Jetpack Protect plugin. - -= Will Jetpack Protect work on my local site? - -Jetpack Protect requires a publicly accessible site to perform the vulnerability scan. - -= How will I know if Jetpack Protect has found WordPress security vulnerabilities and malware? = - -You can visit Jetpack Protect dashboard in your WordPress admin panel to see the security threats and malware found by the integrated malware scanner. - -= What do I do if Jetpack Protect finds a security threat? = - -When the vulnerability scanner finds a security threat, you can view the recommended actions on the Jetpack Protect dashboard to secure your sites. - -If you have upgraded Protect, your site will also be automatically scanned for malware each day, and you will be notified instantly via email if any threats are detected. You will be able to fix most issues in one click. - -= Can I set the time of the daily security scan? = - -It is not possible to set a time for the automated daily scans run by the integrated malware scanner. - -= Why do I need WordPress security and malware scan? = - -A hacked WordPress site can cause serious damage to your business revenue and reputation. Jetpack Protect scans your site and lets you know possible malware and security threats on your installed plugins, themes, and core files. - -= Where can I learn more about WordPress security and malware threats? = - -To learn how to achieve better WordPress security, [see this guide](https://jetpack.com/blog/guide-to-wordpress-security/). On the [Jetpack Blog](https://jetpack.com/blog/category/security/), you can find many more articles written by the top WordPress security experts. - -= Is Jetpack Protect the same thing as the Protect feature in the Jetpack plugin? - -The new Jetpack Protect plugin is different from the Jetpack feature formerly known as [Protect](https://jetpack.com/support/protect/) (now renamed [Brute Force Attack Protection](https://jetpack.com/support/protect/)). - -== Screenshots == - -1. Focus on running your business while Jetpack Protect automatically scans your site. -2. Keep your site one step ahead of security threats and malware. -3. View all the found vulnerabilities in your site and learn how to fix them. -4. The Jetpack Firewall is a web application firewall (known as WAF) designed to protect your WordPress site from malicious requests. - -== Changelog == -### 4.0.0 - 2025-03-24 - -#### Changed -- Scanner: add threat count to tab -- Scanner: animated the "scan in progress" placeholder image -- General: indicate compatibility with the upcoming version of WordPress - 6.7. -- General: Update package dependencies. - -#### Removed -- Firewall: removed "new" badge from tab. -- General: Update minimum PHP version to 7.2. -- General: Update minimum WordPress version to 6.6. - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-credentials.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-credentials.php deleted file mode 100644 index 1e72b467..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-credentials.php +++ /dev/null @@ -1,55 +0,0 @@ -is_connected(); - - if ( ! $blog_id || ! $is_connected ) { - return false; - } - - $api_url = sprintf( '/sites/%d/scan', $blog_id ); - - $response = Client::wpcom_json_api_request_as_blog( - $api_url, - '2', - array( 'method' => 'GET' ), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code ) { - return false; - } - - $parsed_response = json_decode( $response['body'] ); - - if ( ! $parsed_response ) { - return false; - } - - return isset( $parsed_response->credentials ) ? $parsed_response->credentials : array(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-jetpack-protect.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-jetpack-protect.php deleted file mode 100644 index 886db4b0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-jetpack-protect.php +++ /dev/null @@ -1,447 +0,0 @@ -ensure( - 'connection', - array( - 'slug' => JETPACK_PROTECT_SLUG, - 'name' => JETPACK_PROTECT_NAME, - 'url_info' => JETPACK_PROTECT_URI, - ) - ); - // Sync package. - $config->ensure( - 'sync', - array( - 'jetpack_sync_modules' => array( - 'Automattic\\Jetpack\\Sync\\Modules\\Options', - 'Automattic\\Jetpack\\Sync\\Modules\\Callables', - 'Automattic\\Jetpack\\Sync\\Modules\\Users', - ), - 'jetpack_sync_callable_whitelist' => array( - 'main_network_site' => array( 'Automattic\\Jetpack\\Connection\\Urls', 'main_network_site_url' ), - 'get_plugins' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_plugins' ), - 'get_themes' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'get_themes' ), - 'wp_version' => array( 'Automattic\\Jetpack\\Sync\\Functions', 'wp_version' ), - ), - 'jetpack_sync_options_contentless' => array(), - 'jetpack_sync_options_whitelist' => array( - 'active_plugins', - 'stylesheet', - ), - ) - ); - - // Identity crisis package. - $config->ensure( 'identity_crisis' ); - - // Web application firewall package. - $config->ensure( 'waf' ); - }, - 1 - ); - - add_filter( 'jetpack_connection_user_has_license', array( $this, 'jetpack_check_user_licenses' ), 10, 3 ); - - add_filter( 'jetpack_get_available_standalone_modules', array( $this, 'protect_filter_available_modules' ), 10, 1 ); - } - - /** - * Initialize the plugin - * - * @return void - */ - public function init() { - add_action( 'admin_bar_menu', array( $this, 'admin_bar' ), 65 ); - add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_admin_styles' ) ); - - REST_Controller::init(); - My_Jetpack_Initializer::init(); - Site_Health::init(); - - // Sets up JITMS. - JITM::configure(); - } - - /** - * Initialize the admin page resources. - */ - public function admin_page_init() { - $total_threats = Status::get_total_threats(); - $menu_label = _x( 'Protect', 'The Jetpack Protect product name, without the Jetpack prefix', 'jetpack-protect' ); - if ( $total_threats ) { - $menu_label .= sprintf( ' %d', $total_threats ); - } - - $page_suffix = Admin_Menu::add_menu( - __( 'Jetpack Protect', 'jetpack-protect' ), - $menu_label, - 'manage_options', - 'jetpack-protect', - array( $this, 'plugin_settings_page' ), - 5 - ); - - add_action( 'load-' . $page_suffix, array( $this, 'enqueue_admin_scripts' ) ); - } - - /** - * Enqueues the wp-admin styles (used outside the React app) - */ - public function enqueue_admin_styles() { - wp_enqueue_style( 'jetpack-protect-wpadmin', JETPACK_PROTECT_BASE_PLUGIN_URL . '/assets/jetpack-protect.css', array(), JETPACK_PROTECT_VERSION ); - } - - /** - * Enqueue plugin admin scripts and styles. - */ - public function enqueue_admin_scripts() { - - Assets::register_script( - 'jetpack-protect', - 'build/index.js', - JETPACK_PROTECT_ROOT_FILE, - array( - 'in_footer' => true, - 'textdomain' => 'jetpack-protect', - ) - ); - Assets::enqueue_script( 'jetpack-protect' ); - // Required for Analytics. - wp_enqueue_script( 'jp-tracks', '//stats.wp.com/w.js', array(), gmdate( 'YW' ), true ); - // Initial JS state including JP Connection data. - Connection_Initial_State::render_script( 'jetpack-protect' ); - wp_add_inline_script( 'jetpack-protect', $this->render_initial_state(), 'before' ); - } - - /** - * Render the initial state into a JavaScript variable. - * - * @return string - */ - public function render_initial_state() { - return 'var jetpackProtectInitialState=JSON.parse(decodeURIComponent("' . rawurlencode( wp_json_encode( $this->initial_state() ) ) . '"));'; - } - - /** - * Get the initial state data for hydrating the React UI. - * - * @return array - */ - public function initial_state() { - global $wp_version; - - // Always fetch the latest plan status from WPCOM. - $has_plan = Plan::has_required_plan( true ); - - $status = Status::get_status(); - - $initial_state = array( - 'apiRoot' => esc_url_raw( rest_url() ), - 'apiNonce' => wp_create_nonce( 'wp_rest' ), - 'registrationNonce' => wp_create_nonce( 'jetpack-registration-nonce' ), - 'credentials' => Credentials::get_credential_array(), - 'status' => $status, - 'fixerStatus' => Threats::fix_threats_status( $status->fixable_threat_ids ), - 'scanHistory' => Scan_History::get_scan_history(), - 'installedPlugins' => Plugins_Installer::get_plugins(), - 'installedThemes' => Sync_Functions::get_themes(), - 'wpVersion' => $wp_version, - 'adminUrl' => 'admin.php?page=jetpack-protect', - 'siteSuffix' => ( new Jetpack_Status() )->get_site_suffix(), - 'blogID' => Connection_Manager::get_site_id( true ), - 'jetpackScan' => My_Jetpack_Products::get_product( 'scan' ), - 'hasPlan' => $has_plan, - 'onboardingProgress' => Onboarding::get_current_user_progress(), - 'waf' => array( - 'wafSupported' => Waf_Runner::is_supported_environment(), - 'currentIp' => IP_Utils::get_ip(), - 'upgradeIsSeen' => self::get_waf_upgrade_seen_status(), - 'displayUpgradeBadge' => self::get_waf_upgrade_badge_display_status(), - 'isEnabled' => Waf_Runner::is_enabled(), - 'config' => Waf_Runner::get_config(), - 'stats' => self::get_waf_stats(), - 'globalStats' => Waf_Stats::get_global_stats(), - ), - ); - - $initial_state['jetpackScan']['pricingForUi'] = Plan::get_product( 'jetpack_scan' ); - - return $initial_state; - } - /** - * Main plugin settings page. - */ - public function plugin_settings_page() { - ?> -
            - is_connected() ) { - self::activate_modules(); - } - } - - /** - * Activates the waf and brute force protection modules and disables the activation option - */ - public static function activate_modules() { - delete_option( self::JETPACK_PROTECT_ACTIVATION_OPTION ); - ( new Modules() )->activate( self::JETPACK_WAF_MODULE_SLUG, false, false ); - ( new Modules() )->activate( self::JETPACK_BRUTE_FORCE_PROTECTION_MODULE_SLUG, false, false ); - } - - /** - * Removes plugin from the connection manager - * If it's the last plugin using the connection, the site will be disconnected. - * - * @access public - * @static - */ - public static function plugin_deactivation() { - - // Clear Sync data. - Sender::get_instance()->uninstall(); - - $manager = new Connection_Manager( 'jetpack-protect' ); - $manager->remove_connection(); - - Protect_Status::delete_option(); - Scan_Status::delete_option(); - Scan_History::delete_option(); - } - - /** - * Create a shortcut on Admin Bar to show the total of threats found. - * - * @param object $wp_admin_bar The Admin Bar object. - * @return void - */ - public function admin_bar( $wp_admin_bar ) { - if ( ! current_user_can( 'manage_options' ) ) { - return; - } - - $total = Status::get_total_threats(); - - if ( $total > 0 ) { - $args = array( - 'id' => 'jetpack-protect', - 'title' => '' . $total . '', - 'href' => admin_url( 'admin.php?page=jetpack-protect' ), - 'meta' => array( - // translators: %d is the number of threats found. - 'title' => sprintf( _n( '%d threat found by Jetpack Protect', '%d threats found by Jetpack Protect', $total, 'jetpack-protect' ), $total ), - ), - ); - - $wp_admin_bar->add_node( $args ); - } - } - - /** - * Adds modules to the list of available modules - * - * @param array $modules The available modules. - * @return array - */ - public function protect_filter_available_modules( $modules ) { - return array_merge( array( self::JETPACK_WAF_MODULE_SLUG, self::JETPACK_BRUTE_FORCE_PROTECTION_MODULE_SLUG ), $modules ); - } - - /** - * Check if the user has an available license that includes Jetpack Scan. - * - * @param boolean $has_license Whether a license was already found. - * @param object[] $licenses Unattached licenses belonging to the user. - * @param string $plugin_slug Slug of the plugin that initiated the flow. - * - * @return boolean - */ - public static function jetpack_check_user_licenses( $has_license, $licenses, $plugin_slug ) { - if ( $plugin_slug !== JETPACK_PROTECT_SLUG || $has_license ) { - return $has_license; - } - - $license_found = false; - - foreach ( $licenses as $license ) { - if ( $license->attached_at || $license->revoked_at ) { - continue; - } - - if ( in_array( $license->product_id, self::JETPACK_SCAN_PRODUCT_IDS, true ) ) { - $license_found = true; - break; - } - } - - return $license_found; - } - - /** - * Get WAF Upgrade "Seen" Status - * - * @return bool Whether the current user has dismissed the upgrade popover or enabled the automatic rules feature. - */ - public static function get_waf_upgrade_seen_status() { - return (bool) get_user_meta( get_current_user_id(), 'jetpack_protect_waf_upgrade_seen', true ); - } - - /** - * Set WAF Upgrade "Seen" Status - * - * @return bool True if upgrade seen status updated to true, false on failure. - */ - public static function set_waf_upgrade_seen_status() { - self::set_waf_upgrade_badge_timestamp(); - return (bool) update_user_meta( get_current_user_id(), 'jetpack_protect_waf_upgrade_seen', true ); - } - - /** - * Get WAF Upgrade Badge Timestamp - * - * @return integer The timestamp for the when the upgrade seen status was first set to true. - */ - public static function get_waf_upgrade_badge_timestamp() { - return (int) get_user_meta( get_current_user_id(), 'jetpack_protect_waf_upgrade_badge_timestamp', true ); - } - - /** - * Set WAF Upgrade Badge Timestamp - * - * @return bool True if upgrade badge timestamp to set to the current time, false on failure. - */ - public static function set_waf_upgrade_badge_timestamp() { - return (bool) update_user_meta( get_current_user_id(), 'jetpack_protect_waf_upgrade_badge_timestamp', time() ); - } - - /** - * Get WAF Upgrade Badge Display Status - * - * @return bool True if upgrade badge timestamp is set and less than 7 days ago, otherwise false. - */ - public static function get_waf_upgrade_badge_display_status() { - $badge_timestamp_exists = metadata_exists( 'user', get_current_user_id(), 'jetpack_protect_waf_upgrade_badge_timestamp' ); - if ( ! $badge_timestamp_exists ) { - return true; - } - - $badge_timestamp = self::get_waf_upgrade_badge_timestamp(); - $seven_days = strtotime( '-7 days' ); - if ( $badge_timestamp > $seven_days ) { - return true; - } - - return false; - } - - /** - * Get WAF stats - * - * @return bool|array False if WAF is not enabled, otherwise an array of stats. - */ - public static function get_waf_stats() { - if ( ! Waf_Runner::is_enabled() ) { - return false; - } - - return array( - 'blockedRequests' => Plan::has_required_plan() ? Waf_Stats::get_blocked_requests() : false, - 'automaticRulesLastUpdated' => Waf_Stats::get_automatic_rules_last_updated(), - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-onboarding.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-onboarding.php deleted file mode 100644 index cacd4768..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-onboarding.php +++ /dev/null @@ -1,80 +0,0 @@ - - */ - private static $current_user_progress; - - /** - * Onboarding Init - * - * @return void - */ - private static function init() { - self::$user_id = get_current_user_id(); - - $current_user_progress = get_user_meta( self::$user_id, self::OPTION_NAME, true ); - self::$current_user_progress = $current_user_progress ? $current_user_progress : array(); - } - - /** - * Set Onboarding Items As Completed - * - * @param array $step_ids The IDs of the steps to complete. - * @return bool True if the update was successful, false otherwise. - */ - public static function complete_steps( $step_ids ) { - self::init(); - - if ( empty( self::$current_user_progress ) ) { - self::$current_user_progress = $step_ids; - } else { - // Find step IDs that are not already in the current user progress - $new_steps = array_diff( $step_ids, self::$current_user_progress ); - - // Merge new steps with current progress - self::$current_user_progress = array_merge( self::$current_user_progress, $new_steps ); - } - - // Update the user meta only once - return (bool) update_user_meta( - self::$user_id, - self::OPTION_NAME, - self::$current_user_progress - ); - } - - /** - * Get Current User's Onboarding Progress - * - * @return array - */ - public static function get_current_user_progress() { - self::init(); - - return self::$current_user_progress; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-rest-controller.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-rest-controller.php deleted file mode 100644 index 4cfa117c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-rest-controller.php +++ /dev/null @@ -1,431 +0,0 @@ - \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_ignore_threat', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'unignore-threat', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_unignore_threat', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'fix-threats', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_fix_threats', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'fix-threats-status', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_fix_threats_status', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'check-credentials', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_check_credentials', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'scan', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_scan', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'toggle-waf', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_toggle_waf', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'waf', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_get_waf', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'waf-upgrade-seen', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_get_waf_upgrade_seen_status', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'waf-upgrade-seen', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_set_waf_upgrade_seen_status', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'onboarding-progress', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_get_onboarding_progress', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'onboarding-progress', - array( - 'methods' => \WP_REST_Server::EDITABLE, - 'callback' => __CLASS__ . '::api_complete_onboarding_steps', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - - register_rest_route( - 'jetpack-protect/v1', - 'scan-history', - array( - 'methods' => \WP_REST_Server::READABLE, - 'callback' => __CLASS__ . '::api_get_scan_history', - 'permission_callback' => function () { - return current_user_can( 'manage_options' ); - }, - ) - ); - } - - /** - * Ignores a threat for the API endpoint - * - * @param WP_REST_Request $request The request object. - * - * @return WP_REST_Response - */ - public static function api_ignore_threat( $request ) { - if ( ! $request['threat_id'] ) { - return new WP_REST_Response( 'Missing threat ID.', 400 ); - } - - $threat_ignored = Threats::ignore_threat( $request['threat_id'] ); - - if ( ! $threat_ignored ) { - return new WP_REST_Response( 'An error occurred while attempting to ignore the threat.', 500 ); - } - - return new WP_REST_Response( 'Threat ignored.' ); - } - - /** - * Unignores a threat for the API endpoint - * - * @param WP_REST_Request $request The request object. - * - * @return WP_REST_Response - */ - public static function api_unignore_threat( $request ) { - if ( ! $request['threat_id'] ) { - return new WP_REST_Response( 'Missing threat ID.', 400 ); - } - - $threat_ignored = Threats::unignore_threat( $request['threat_id'] ); - - if ( ! $threat_ignored ) { - return new WP_REST_Response( 'An error occurred while attempting to unignore the threat.', 500 ); - } - - return new WP_REST_Response( 'Threat unignored.' ); - } - - /** - * Fixes threats for the API endpoint - * - * @param WP_REST_Request $request The request object. - * - * @return WP_REST_Response - */ - public static function api_fix_threats( $request ) { - if ( empty( $request['threat_ids'] ) ) { - return new WP_REST_Response( 'Missing threat IDs.', 400 ); - } - - $threats_fixed = Threats::fix_threats( $request['threat_ids'] ); - - if ( ! $threats_fixed ) { - return new WP_REST_Response( 'An error occurred while attempting to fix the threat.', 500 ); - } - - return new WP_REST_Response( $threats_fixed ); - } - - /** - * Fixes threats for the API endpoint - * - * @param WP_REST_Request $request The request object. - * - * @return WP_REST_Response - */ - public static function api_fix_threats_status( $request ) { - if ( empty( $request['threat_ids'] ) ) { - return new WP_REST_Response( 'Missing threat IDs.', 400 ); - } - - $threats_fixed = Threats::fix_threats_status( $request['threat_ids'] ); - - if ( ! $threats_fixed ) { - return new WP_REST_Response( 'An error occurred while attempting to get the fixer status of the threats.', 500 ); - } - - return new WP_REST_Response( $threats_fixed ); - } - - /** - * Checks if the site has credentials configured - * - * @return WP_REST_Response - */ - public static function api_check_credentials() { - $credential_array = Credentials::get_credential_array(); - - if ( ! isset( $credential_array ) ) { - return new WP_REST_Response( 'An error occurred while attempting to fetch the credentials array', 500 ); - } - - return new WP_REST_Response( $credential_array ); - } - - /** - * Enqueues a scan for the API endpoint - * - * @return WP_REST_Response - */ - public static function api_scan() { - $scan_enqueued = Threats::scan(); - - if ( ! $scan_enqueued ) { - return new WP_REST_Response( 'An error occurred while attempting to enqueue the scan.', 500 ); - } - - return new WP_REST_Response( 'Scan enqueued.' ); - } - - /** - * Toggles the WAF module on or off for the API endpoint - * - * @return WP_REST_Response|WP_Error - */ - public static function api_toggle_waf() { - if ( Waf_Runner::is_enabled() ) { - $disabled = Waf_Runner::disable(); - if ( ! $disabled ) { - return new WP_Error( - 'waf_disable_failed', - __( 'An error occurred disabling the firewall.', 'jetpack-protect' ), - array( 'status' => 500 ) - ); - } - - return rest_ensure_response( true ); - } - - $enabled = Waf_Runner::enable(); - if ( ! $enabled ) { - return new WP_Error( - 'waf_enable_failed', - __( 'An error occurred enabling the firewall.', 'jetpack-protect' ), - array( 'status' => 500 ) - ); - } - - return rest_ensure_response( true ); - } - - /** - * Get WAF data for the API endpoint - * - * @return WP_Rest_Response - */ - public static function api_get_waf() { - // Ensure plugin activation has been performed so WAF module is available. - Jetpack_Protect::do_plugin_activation_activities(); - - return new WP_REST_Response( - array( - 'wafSupported' => Waf_Runner::is_supported_environment(), - 'currentIp' => IP_Utils::get_ip(), - 'upgradeIsSeen' => Jetpack_Protect::get_waf_upgrade_seen_status(), - 'displayUpgradeBadge' => Jetpack_Protect::get_waf_upgrade_badge_display_status(), - 'isEnabled' => Waf_Runner::is_enabled(), - 'config' => Waf_Runner::get_config(), - 'stats' => Jetpack_Protect::get_waf_stats(), - 'globalStats' => Waf_Stats::get_global_stats(), - ) - ); - } - - /** - * Get WAF Upgrade "Seen" Status for the API endpoint - * - * @return bool Whether the current user has dismissed the upgrade popover or enabled the automatic rules feature. - */ - public static function api_get_waf_upgrade_seen_status() { - return Jetpack_Protect::get_waf_upgrade_seen_status(); - } - - /** - * Set WAF Upgrade "Seen" Status for the API endpoint - * - * @return bool True if upgrade seen status updated to true, false on failure. - */ - public static function api_set_waf_upgrade_seen_status() { - return Jetpack_Protect::set_waf_upgrade_seen_status(); - } - - /** - * Gets the current user's onboarding progress for the API endpoint - * - * @return WP_REST_Response - */ - public static function api_get_onboarding_progress() { - $progress = Onboarding::get_current_user_progress(); - return rest_ensure_response( $progress ); - } - - /** - * Set an onboarding step as completed for the API endpoint - * - * @param WP_REST_Request $request The request object. - * - * @return WP_REST_Response - */ - public static function api_complete_onboarding_steps( $request ) { - if ( empty( $request['step_ids'] ) || ! is_array( $request['step_ids'] ) ) { - return new WP_REST_Response( 'Missing or invalid onboarding step IDs.', 400 ); - } - - $completed = Onboarding::complete_steps( $request['step_ids'] ); - - if ( ! $completed ) { - return new WP_REST_Response( 'An error occurred completing the onboarding step(s).', 500 ); - } - - return new WP_REST_Response( 'Onboarding step(s) completed.' ); - } - - /** - * Return Scan History for the API endpoint - * - * @return WP_REST_Response - */ - public static function api_get_scan_history() { - $scan_history = Scan_History::get_scan_history( false ); - return rest_ensure_response( $scan_history ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-scan-history.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-scan-history.php deleted file mode 100644 index bd034c37..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-scan-history.php +++ /dev/null @@ -1,358 +0,0 @@ - (int) $option_timestamp; - } - - /** - * Checks if we should consider the stored cache or bypass it - * - * @return boolean - */ - public static function should_use_cache() { - return ! ( ( defined( 'JETPACK_PROTECT_DEV__BYPASS_CACHE' ) && JETPACK_PROTECT_DEV__BYPASS_CACHE ) ); - } - - /** - * Gets the current cached history - * - * @return bool|array False if value is not found. Array with values if cache is found. - */ - public static function get_from_options() { - return maybe_unserialize( get_option( static::OPTION_NAME ) ); - } - - /** - * Updated the cached history and its timestamp - * - * @param array $history The new history to be cached. - * @return void - */ - public static function update_history_option( $history ) { - // TODO: Sanitize $history. - update_option( static::OPTION_NAME, maybe_serialize( $history ) ); - update_option( static::OPTION_TIMESTAMP_NAME, time() + static::OPTION_EXPIRES_AFTER ); - } - - /** - * Delete the cached history and its timestamp - * - * @return bool Whether all related history options were successfully deleted. - */ - public static function delete_option() { - $option_deleted = delete_option( static::OPTION_NAME ); - $option_timestamp_deleted = delete_option( static::OPTION_TIMESTAMP_NAME ); - - return $option_deleted && $option_timestamp_deleted; - } - - /** - * Gets the current history of the Jetpack Protect checks - * - * @param bool $refresh_from_wpcom Refresh the local plan and history cache from wpcom. - * @return History_Model|bool - */ - public static function get_scan_history( $refresh_from_wpcom = false ) { - $has_required_plan = Plan::has_required_plan(); - if ( ! $has_required_plan ) { - return false; - } - - if ( self::$history !== null ) { - return self::$history; - } - - if ( $refresh_from_wpcom || ! self::should_use_cache() || self::is_cache_expired() ) { - $history = self::fetch_from_api(); - } else { - $history = self::get_from_options(); - } - - if ( is_wp_error( $history ) ) { - $history = new History_Model( - array( - 'error' => true, - 'error_code' => $history->get_error_code(), - 'error_message' => $history->get_error_message(), - ) - ); - } else { - $history = self::normalize_api_data( $history ); - } - - self::$history = $history; - return $history; - } - - /** - * Gets the Scan API endpoint - * - * @return WP_Error|string - */ - public static function get_api_url() { - $blog_id = Jetpack_Options::get_option( 'id' ); - $is_connected = ( new Connection_Manager() )->is_connected(); - - if ( ! $blog_id || ! $is_connected ) { - return new WP_Error( 'site_not_connected' ); - } - - $api_url = sprintf( self::SCAN_HISTORY_API_BASE, $blog_id ); - - return $api_url; - } - - /** - * Fetches the history data from the Scan API - * - * @return WP_Error|array - */ - public static function fetch_from_api() { - $api_url = self::get_api_url(); - if ( is_wp_error( $api_url ) ) { - return $api_url; - } - - $response = Client::wpcom_json_api_request_as_blog( - $api_url, - '2', - array( - 'method' => 'GET', - 'timeout' => 30, - ), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code || empty( $response['body'] ) ) { - return new WP_Error( 'failed_fetching_status', 'Failed to fetch Scan history from the server', array( 'status' => $response_code ) ); - } - - $body = json_decode( wp_remote_retrieve_body( $response ) ); - $body->last_checked = ( new \DateTime() )->format( 'Y-m-d H:i:s' ); - self::update_history_option( $body ); - - return $body; - } - - /** - * Normalize API Data - * Formats the payload from the Scan API into an instance of History_Model. - * - * @phan-suppress PhanDeprecatedProperty -- Maintaining backwards compatibility. - * - * @param object $scan_data The data returned by the scan API. - * @return History_Model - */ - private static function normalize_api_data( $scan_data ) { - $history = new History_Model(); - $history->num_threats = 0; - $history->num_core_threats = 0; - $history->num_plugins_threats = 0; - $history->num_themes_threats = 0; - - $history->last_checked = $scan_data->last_checked; - - if ( empty( $scan_data->threats ) || ! is_array( $scan_data->threats ) ) { - return $history; - } - - foreach ( $scan_data->threats as $threat ) { - if ( isset( $threat->extension->type ) ) { - if ( 'plugin' === $threat->extension->type ) { - self::handle_extension_threats( $threat, $history, 'plugin' ); - continue; - } - - if ( 'theme' === $threat->extension->type ) { - self::handle_extension_threats( $threat, $history, 'theme' ); - continue; - } - } - - if ( 'Vulnerable.WP.Core' === $threat->signature ) { - self::handle_core_threats( $threat, $history ); - continue; - } - - self::handle_additional_threats( $threat, $history ); - } - - return $history; - } - - /** - * Handles threats for extensions such as plugins or themes. - * - * @phan-suppress PhanDeprecatedProperty -- Maintaining backwards compatibility. - * - * @param object $threat The threat object. - * @param object $history The history object. - * @param string $type The type of extension ('plugin' or 'theme'). - * @return void - */ - private static function handle_extension_threats( $threat, $history, $type ) { - $extension_list = $type === 'plugin' ? 'plugins' : 'themes'; - $extensions = &$history->{ $extension_list}; - $found_index = null; - - // Check if the extension does not exist in the array - foreach ( $extensions as $index => $extension ) { - if ( $extension->slug === $threat->extension->slug ) { - $found_index = $index; - break; - } - } - - // Add the extension if it does not yet exist in the history - if ( $found_index === null ) { - $new_extension = new Extension_Model( - array( - 'name' => $threat->extension->name ?? null, - 'slug' => $threat->extension->slug ?? null, - 'version' => $threat->extension->version ?? null, - 'type' => $type, - 'checked' => true, - 'threats' => array(), - ) - ); - $extensions[] = $new_extension; - $found_index = array_key_last( $extensions ); - } - - // Add the threat to the found extension - $extensions[ $found_index ]->threats[] = new Threat_Model( $threat ); - - // Increment the threat counts - ++$history->num_threats; - if ( $type === 'plugin' ) { - ++$history->num_plugins_threats; - } elseif ( $type === 'theme' ) { - ++$history->num_themes_threats; - } - } - - /** - * Handles core threats - * - * @param object $threat The threat object. - * @param object $history The history object. - * @return void - */ - private static function handle_core_threats( $threat, $history ) { - // Check if the core version does not exist in the array - $found_index = null; - foreach ( $history->core as $index => $core ) { - if ( $core->version === $threat->version ) { - $found_index = $index; - break; - } - } - - // Add the extension if it does not yet exist in the history - if ( null === $found_index ) { - $new_core = new Extension_Model( - array( - 'name' => 'WordPress', - 'version' => $threat->version, - 'type' => 'core', - 'checked' => true, - 'threats' => array(), - ) - ); - $history->core[] = $new_core; - $found_index = array_key_last( $history->core ); - } - - // Add the threat to the found core - $history->core[ $found_index ]->threats[] = new Threat_Model( $threat ); - - ++$history->num_threats; - ++$history->num_core_threats; - } - - /** - * Handles additional threats that are not core, plugin or theme - * - * @param object $threat The threat object. - * @param object $history The history object. - * @return void - */ - private static function handle_additional_threats( $threat, $history ) { - if ( ! empty( $threat->filename ) ) { - $history->files[] = new Threat_Model( $threat ); - ++$history->num_threats; - } elseif ( ! empty( $threat->table ) ) { - $history->database[] = new Threat_Model( $threat ); - ++$history->num_threats; - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-site-health.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-site-health.php deleted file mode 100644 index 840aeafb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-site-health.php +++ /dev/null @@ -1,113 +0,0 @@ - __( 'Jetpack Protect checks', 'jetpack-protect' ), - 'test' => array( __CLASS__, 'do_checks' ), - ); - - return $checks; - } - - /** - * Do site-health page checks - * - * @access public - * @return array - */ - public static function do_checks() { - $total_threats = Status::get_total_threats(); - $threats = Status::get_all_threats(); - $threats = array_map( - function ( $v ) { - return $v->title; - }, - $threats - ); - - /** - * Default, no threats found - */ - $result = array( - 'label' => __( 'No known threats found', 'jetpack-protect' ), - 'status' => 'good', - 'badge' => array( - 'label' => __( 'Security', 'jetpack-protect' ), - 'color' => 'gray', - ), - 'description' => sprintf( - '

            %s

            ', - __( 'Jetpack Protect did not find any known threats in your site. Threats can be exploited by hackers and cause harm to your website.', 'jetpack-protect' ) - ), - 'actions' => '', - 'test' => 'jetpack_protect_checks', - ); - - /** - * If threats found. - */ - if ( $total_threats ) { - $result['status'] = 'critical'; - /* translators: $d is the number of threats found. */ - $result['label'] = sprintf( _n( 'Your site is affected by %d security threat', 'Your site is affected by %d security threats', $total_threats, 'jetpack-protect' ), $total_threats ); - $result['description'] = __( 'Jetpack Protect detected the following security threats in your site:', 'jetpack-protect' ); - - foreach ( $threats as $threat ) { - $result['description'] .= '

            '; - $result['description'] .= "  "; - $result['description'] .= wp_kses( $threat, array( 'a' => array( 'href' => array() ) ) ); // Only allow a href HTML tags. - $result['description'] .= '

            '; - } - $result['description'] .= '

            '; - $result['description'] .= sprintf( - wp_kses( - /* translators: Link to Jetpack Protect. */ - __( 'See Protect overview page for more information.', 'jetpack-protect' ), - array( - 'a' => array( 'href' => array() ), - ) - ), - esc_url( admin_url( 'admin.php?page=jetpack-protect' ) ) - ); - $result['description'] .= '

            '; - } - - return $result; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-threats.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-threats.php deleted file mode 100644 index 11030a4c..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/src/class-threats.php +++ /dev/null @@ -1,222 +0,0 @@ -is_connected(); - - if ( ! $blog_id || ! $is_connected ) { - return new WP_Error( 'site_not_connected' ); - } - - $api_url = sprintf( '/sites/%d/alerts', $blog_id ); - - return $api_url; - } - - /** - * Update Threat - * - * @param string $threat_id The threat ID. - * @param array $updates The keys/values to update. - * - * @return bool - */ - public static function update_threat( $threat_id, $updates ) { - $api_base = self::get_api_base(); - if ( is_wp_error( $api_base ) ) { - return false; - } - - $response = Client::wpcom_json_api_request_as_user( - "$api_base/$threat_id", - '2', - array( 'method' => 'POST' ), - wp_json_encode( $updates ), - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code ) { - return false; - } - - // clear the now out-of-date cache - Scan_Status::delete_option(); - Scan_History::delete_option(); - - return true; - } - - /** - * Ignore Threat - * - * @param string $threat_id The threat ID. - * - * @return bool - */ - public static function ignore_threat( $threat_id ) { - return self::update_threat( $threat_id, array( 'ignore' => true ) ); - } - - /** - * Unignore Threat - * - * @param string $threat_id The threat ID. - * - * @return bool - */ - public static function unignore_threat( $threat_id ) { - return self::update_threat( $threat_id, array( 'unignore' => true ) ); - } - - /** - * Fix Threats - * - * @param array $threat_ids Threat IDs. - * - * @return bool|array - */ - public static function fix_threats( $threat_ids ) { - $api_base = self::get_api_base(); - if ( is_wp_error( $api_base ) ) { - return false; - } - - $response = Client::wpcom_json_api_request_as_user( - "$api_base/fix", - '2', - array( 'method' => 'POST' ), - wp_json_encode( - array( - 'threat_ids' => $threat_ids, - ) - ), - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code ) { - return false; - } - - // clear the now out-of-date cache - Scan_Status::delete_option(); - Scan_History::delete_option(); - - $parsed_response = json_decode( $response['body'] ); - - if ( ! $parsed_response ) { - return false; - } - - return $parsed_response; - } - - /** - * Fix Threats Status - * - * @param array $threat_ids Threat IDs. - * - * @return bool|array - */ - public static function fix_threats_status( $threat_ids ) { - if ( empty( $threat_ids ) ) { - return false; - } - - $api_base = self::get_api_base(); - if ( is_wp_error( $api_base ) ) { - return false; - } - - $response = Client::wpcom_json_api_request_as_user( - add_query_arg( 'threat_ids', $threat_ids, "$api_base/fix" ), - '2', - array( 'method' => 'GET' ), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code ) { - return false; - } - - $parsed_response = json_decode( $response['body'] ); - - if ( ! $parsed_response ) { - return false; - } - - // clear the potentially out-of-date cache - Scan_Status::delete_option(); - Scan_History::delete_option(); - - return $parsed_response; - } - - /** - * Scan enqueue - * - * @return bool - */ - public static function scan() { - $blog_id = Jetpack_Options::get_option( 'id' ); - $is_connected = ( new Connection_Manager() )->is_connected(); - - if ( ! $blog_id || ! $is_connected ) { - return false; - } - - $api_base = sprintf( '/sites/%d/scan', $blog_id ); - - if ( is_wp_error( $api_base ) ) { - return false; - } - - $response = Client::wpcom_json_api_request_as_blog( - "$api_base/enqueue", - '2', - array( 'method' => 'POST' ), - null, - 'wpcom' - ); - - $response_code = wp_remote_retrieve_response_code( $response ); - - if ( is_wp_error( $response ) || 200 !== $response_code ) { - return false; - } - - // clear the now out-of-date cache - Scan_Status::delete_option(); - Scan_History::delete_option(); - - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/autoload.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/autoload.php deleted file mode 100644 index d34dbd4e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/autoload.php +++ /dev/null @@ -1,25 +0,0 @@ -= 7.0. [#34192] - -## [0.3.5] - 2023-10-24 - -- Updated package dependencies. - -## [0.3.4] - 2023-08-23 -### Changed -- Updated package dependencies. [#32605] - -## [0.3.3] - 2023-06-19 -### Added -- Add the Advanced SEO feature to the list of free features. [#31213] - -## [0.3.2] - 2023-06-12 -### Changed -- Remove Jetpack-the-plugin dependencies from Current Plan class. [#31207] - -## [0.3.1] - 2023-06-05 -### Fixed -- Revert gating removal for simple payments [#31067] - -## [0.3.0] - 2023-05-11 -### Changed -- Make Earn products free for all Jetpack plans [#30432] - -## [0.2.12] - 2023-05-08 -### Changed -- Make Premium Content accessible on Free plans. [#30398] - -## [0.2.11] - 2023-04-10 -### Added -- Add Jetpack Autoloader package suggestion. [#29988] - -## [0.2.10] - 2023-02-20 -### Changed -- Minor internal updates. - -## [0.2.9] - 2023-01-25 -### Changed -- Minor internal updates. - -## [0.2.8] - 2022-12-02 -### Changed -- Updated package dependencies. [#27688] - -## [0.2.7] - 2022-11-22 -### Changed -- Updated package dependencies. [#27043] - -## [0.2.6] - 2022-11-07 -### Changed -- Updated package dependencies. [#27278] - -## [0.2.5] - 2022-10-25 -### Changed -- Updated package dependencies. [#26705] - -## [0.2.4] - 2022-09-20 -### Changed -- Updated package dependencies. - -## [0.2.3] - 2022-09-08 -### Changed -- Updated package dependencies. - -## [0.2.2] - 2022-08-30 -### Changed -- Updated package dependencies. [#25694] - -## [0.2.1] - 2022-08-23 -### Changed -- Updated package dependencies. [#25628] - -## [0.2.0] - 2022-08-16 -### Added -- Tweaked the supports method of the plans package to refresh the plan data. [#25347] - -## [0.1.3] - 2022-08-03 -### Changed -- Updated package dependencies. [#25300, #25315] - -## [0.1.2] - 2022-07-26 -### Changed -- Add mirror repository information to package info. [#25142] -- Updated package dependencies. [#25158] - -## 0.1.1 - 2022-07-19 -### Changed -- Updated package dependencies. - -## 0.1.0 - 2022-07-06 -### Added -- Add support for WordPress.com Starter plan. [#24496] -- Package created. [#23503] - -### Changed -- Renaming master to trunk. [#24661] -- Updated package dependencies. - -### Deprecated -- Moved the options class into Connection. [#24095] - -[0.6.1]: https://github.com/Automattic/jetpack-plans/compare/v0.6.0...v0.6.1 -[0.6.0]: https://github.com/Automattic/jetpack-plans/compare/v0.5.6...v0.6.0 -[0.5.6]: https://github.com/Automattic/jetpack-plans/compare/v0.5.5...v0.5.6 -[0.5.5]: https://github.com/Automattic/jetpack-plans/compare/v0.5.4...v0.5.5 -[0.5.4]: https://github.com/Automattic/jetpack-plans/compare/v0.5.3...v0.5.4 -[0.5.3]: https://github.com/Automattic/jetpack-plans/compare/v0.5.2...v0.5.3 -[0.5.2]: https://github.com/Automattic/jetpack-plans/compare/v0.5.1...v0.5.2 -[0.5.1]: https://github.com/Automattic/jetpack-plans/compare/v0.5.0...v0.5.1 -[0.5.0]: https://github.com/Automattic/jetpack-plans/compare/v0.4.13...v0.5.0 -[0.4.13]: https://github.com/Automattic/jetpack-plans/compare/v0.4.12...v0.4.13 -[0.4.12]: https://github.com/Automattic/jetpack-plans/compare/v0.4.11...v0.4.12 -[0.4.11]: https://github.com/Automattic/jetpack-plans/compare/v0.4.10...v0.4.11 -[0.4.10]: https://github.com/Automattic/jetpack-plans/compare/v0.4.9...v0.4.10 -[0.4.9]: https://github.com/Automattic/jetpack-plans/compare/v0.4.8...v0.4.9 -[0.4.8]: https://github.com/Automattic/jetpack-plans/compare/v0.4.7...v0.4.8 -[0.4.7]: https://github.com/Automattic/jetpack-plans/compare/v0.4.6...v0.4.7 -[0.4.6]: https://github.com/Automattic/jetpack-plans/compare/v0.4.5...v0.4.6 -[0.4.5]: https://github.com/Automattic/jetpack-plans/compare/v0.4.4...v0.4.5 -[0.4.4]: https://github.com/Automattic/jetpack-plans/compare/v0.4.3...v0.4.4 -[0.4.3]: https://github.com/Automattic/jetpack-plans/compare/v0.4.2...v0.4.3 -[0.4.2]: https://github.com/Automattic/jetpack-plans/compare/v0.4.1...v0.4.2 -[0.4.1]: https://github.com/Automattic/jetpack-plans/compare/v0.4.0...v0.4.1 -[0.4.0]: https://github.com/Automattic/jetpack-plans/compare/v0.3.5...v0.4.0 -[0.3.5]: https://github.com/Automattic/jetpack-plans/compare/v0.3.4...v0.3.5 -[0.3.4]: https://github.com/Automattic/jetpack-plans/compare/v0.3.3...v0.3.4 -[0.3.3]: https://github.com/Automattic/jetpack-plans/compare/v0.3.2...v0.3.3 -[0.3.2]: https://github.com/Automattic/jetpack-plans/compare/v0.3.1...v0.3.2 -[0.3.1]: https://github.com/Automattic/jetpack-plans/compare/v0.3.0...v0.3.1 -[0.3.0]: https://github.com/Automattic/jetpack-plans/compare/v0.2.12...v0.3.0 -[0.2.12]: https://github.com/Automattic/jetpack-plans/compare/v0.2.11...v0.2.12 -[0.2.11]: https://github.com/Automattic/jetpack-plans/compare/v0.2.10...v0.2.11 -[0.2.10]: https://github.com/Automattic/jetpack-plans/compare/v0.2.9...v0.2.10 -[0.2.9]: https://github.com/Automattic/jetpack-plans/compare/v0.2.8...v0.2.9 -[0.2.8]: https://github.com/Automattic/jetpack-plans/compare/v0.2.7...v0.2.8 -[0.2.7]: https://github.com/Automattic/jetpack-plans/compare/v0.2.6...v0.2.7 -[0.2.6]: https://github.com/Automattic/jetpack-plans/compare/v0.2.5...v0.2.6 -[0.2.5]: https://github.com/Automattic/jetpack-plans/compare/v0.2.4...v0.2.5 -[0.2.4]: https://github.com/Automattic/jetpack-plans/compare/v0.2.3...v0.2.4 -[0.2.3]: https://github.com/Automattic/jetpack-plans/compare/v0.2.2...v0.2.3 -[0.2.2]: https://github.com/Automattic/jetpack-plans/compare/v0.2.1...v0.2.2 -[0.2.1]: https://github.com/Automattic/jetpack-plans/compare/v0.2.0...v0.2.1 -[0.2.0]: https://github.com/Automattic/jetpack-plans/compare/v0.1.3...v0.2.0 -[0.1.3]: https://github.com/Automattic/jetpack-plans/compare/v0.1.2...v0.1.3 -[0.1.2]: https://github.com/Automattic/jetpack-plans/compare/v0.1.1...v0.1.2 diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/LICENSE.txt deleted file mode 100644 index e82774c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/LICENSE.txt +++ /dev/null @@ -1,357 +0,0 @@ -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - -=================================== - - -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - -Copyright (C) 1989, 1991 Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -Everyone is permitted to copy and distribute verbatim copies -of this license document, but changing it is not allowed. - - Preamble - -The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - -When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - -To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - -For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - -We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - -Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - -Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - -The precise terms and conditions for copying, distribution and -modification follow. - -GNU GENERAL PUBLIC LICENSE -TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - -0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - -1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - -2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - -a) You must cause the modified files to carry prominent notices -stating that you changed the files and the date of any change. - -b) You must cause any work that you distribute or publish, that in -whole or in part contains or is derived from the Program or any -part thereof, to be licensed as a whole at no charge to all third -parties under the terms of this License. - -c) If the modified program normally reads commands interactively -when run, you must cause it, when started running for such -interactive use in the most ordinary way, to print or display an -announcement including an appropriate copyright notice and a -notice that there is no warranty (or else, saying that you provide -a warranty) and that users may redistribute the program under -these conditions, and telling the user how to view a copy of this -License. (Exception: if the Program itself is interactive but -does not normally print such an announcement, your work based on -the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - -3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - -a) Accompany it with the complete corresponding machine-readable -source code, which must be distributed under the terms of Sections -1 and 2 above on a medium customarily used for software interchange; or, - -b) Accompany it with a written offer, valid for at least three -years, to give any third party, for a charge no more than your -cost of physically performing source distribution, a complete -machine-readable copy of the corresponding source code, to be -distributed under the terms of Sections 1 and 2 above on a medium -customarily used for software interchange; or, - -c) Accompany it with the information you received as to the offer -to distribute corresponding source code. (This alternative is -allowed only for noncommercial distribution and only if you -received the program in object code or executable form with such -an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - -4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - -5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - -6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - -7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - -8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - -9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - -10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - -11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - -12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - -How to Apply These Terms to Your New Programs - -If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - -To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - -Copyright (C) - -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License along -with this program; if not, write to the Free Software Foundation, Inc., -51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - -Gnomovision version 69, Copyright (C) year name of author -Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. -This is free software, and you are welcome to redistribute it -under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - -Yoyodyne, Inc., hereby disclaims all copyright interest in the program -`Gnomovision' (which makes passes at compilers) written by James Hacker. - -, 1 April 1989 -Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/SECURITY.md b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/SECURITY.md deleted file mode 100644 index 98f48dd1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/SECURITY.md +++ /dev/null @@ -1,47 +0,0 @@ -# Security Policy - -Full details of the Automattic Security Policy can be found on [automattic.com](https://automattic.com/security/). - -## Supported Versions - -Generally, only the latest version of Jetpack and its associated plugins have continued support. If a critical vulnerability is found in the current version of a plugin, we may opt to backport any patches to previous versions. - -## Reporting a Vulnerability - -Our HackerOne program covers the below plugin software, as well as a variety of related projects and infrastructure: - -* [Jetpack](https://jetpack.com/) -* Jetpack Backup -* Jetpack Boost -* Jetpack CRM -* Jetpack Protect -* Jetpack Search -* Jetpack Social -* Jetpack VideoPress - -**For responsible disclosure of security issues and to be eligible for our bug bounty program, please submit your report via the [HackerOne](https://hackerone.com/automattic) portal.** - -Our most critical targets are: - -* Jetpack and the Jetpack composer packages (all within this repo) -* Jetpack.com -- the primary marketing site. -* cloud.jetpack.com -- a management site. -* wordpress.com -- the shared management site for both Jetpack and WordPress.com sites. - -For more targets, see the `In Scope` section on [HackerOne](https://hackerone.com/automattic). - -_Please note that the **WordPress software is a separate entity** from Automattic. Please report vulnerabilities for WordPress through [the WordPress Foundation's HackerOne page](https://hackerone.com/wordpress)._ - -## Guidelines - -We're committed to working with security researchers to resolve the vulnerabilities they discover. You can help us by following these guidelines: - -* Follow [HackerOne's disclosure guidelines](https://www.hackerone.com/disclosure-guidelines). -* Pen-testing Production: - * Please **setup a local environment** instead whenever possible. Most of our code is open source (see above). - * If that's not possible, **limit any data access/modification** to the bare minimum necessary to reproduce a PoC. - * **_Don't_ automate form submissions!** That's very annoying for us, because it adds extra work for the volunteers who manage those systems, and reduces the signal/noise ratio in our communication channels. - * To be eligible for a bounty, all of these guidelines must be followed. -* Be Patient - Give us a reasonable time to correct the issue before you disclose the vulnerability. - -We also expect you to comply with all applicable laws. You're responsible to pay any taxes associated with your bounties. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/composer.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/composer.json deleted file mode 100644 index 029bc41d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/composer.json +++ /dev/null @@ -1,55 +0,0 @@ -{ - "name": "automattic/jetpack-plans", - "description": "Fetch information about Jetpack Plans from wpcom", - "type": "library", - "license": "GPL-2.0-or-later", - "require": { - "php": ">=7.2", - "automattic/jetpack-connection": "^6.7.7" - }, - "require-dev": { - "yoast/phpunit-polyfills": "^3.0.0", - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-status": "^5.0.10", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "autoload": { - "classmap": [ - "src/" - ] - }, - "scripts": { - "phpunit": [ - "phpunit-select-config phpunit.#.xml.dist --colors=always" - ], - "test-coverage": [ - "php -dpcov.directory=. ./vendor/bin/phpunit-select-config phpunit.#.xml.dist --coverage-php \"$COVERAGE_DIR/php.cov\"" - ], - "test-php": [ - "@composer phpunit" - ], - "build-production": "echo 'Add your build step to composer.json, please!'", - "build-development": "echo 'Add your build step to composer.json, please!'" - }, - "minimum-stability": "dev", - "prefer-stable": true, - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-plans", - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-plans/compare/v${old}...v${new}" - }, - "branch-alias": { - "dev-trunk": "0.6.x-dev" - } - }, - "config": { - "allow-plugins": { - "roots/wordpress-core-installer": true - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-current-plan.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-current-plan.php deleted file mode 100644 index cef57d52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-current-plan.php +++ /dev/null @@ -1,436 +0,0 @@ - array( - 'plans' => array( - 'jetpack_free', - ), - 'supports' => array( - 'advanced-seo', - 'opentable', - 'calendly', - 'send-a-message', - 'sharing-block', - 'whatsapp-button', - 'social-previews', - 'videopress', - 'videopress/video', - 'v6-video-frame-poster', - - 'core/video', - 'core/cover', - 'core/audio', - ), - ), - 'personal' => array( - 'plans' => array( - 'jetpack_personal', - 'jetpack_personal_monthly', - 'personal-bundle', - 'personal-bundle-monthly', - 'personal-bundle-2y', - 'personal-bundle-3y', - 'starter-plan', - ), - 'supports' => array( - 'akismet', - 'payments', - 'videopress', - ), - ), - 'premium' => array( - 'plans' => array( - 'jetpack_premium', - 'jetpack_premium_monthly', - 'value_bundle', - 'value_bundle-monthly', - 'value_bundle-2y', - 'value_bundle-3y', - 'jetpack_creator_yearly', - 'jetpack_creator_bi_yearly', - 'jetpack_creator_monthly', - ), - 'supports' => array( - 'simple-payments', - 'vaultpress', - 'videopress', - 'republicize', - ), - ), - 'security' => array( - 'plans' => array( - 'jetpack_security_daily', - 'jetpack_security_daily_monthly', - 'jetpack_security_realtime', - 'jetpack_security_realtime_monthly', - 'jetpack_security_t1_yearly', - 'jetpack_security_t1_monthly', - 'jetpack_security_t2_yearly', - 'jetpack_security_t2_monthly', - ), - 'supports' => array(), - ), - 'business' => array( - 'plans' => array( - 'jetpack_business', - 'jetpack_business_monthly', - 'business-bundle', - 'business-bundle-monthly', - 'business-bundle-2y', - 'business-bundle-3y', - 'ecommerce-bundle', - 'ecommerce-bundle-monthly', - 'ecommerce-bundle-2y', - 'ecommerce-bundle-3y', - 'pro-plan', - 'wp_bundle_migration_trial_monthly', - 'wp_bundle_hosting_trial_monthly', - 'ecommerce-trial-bundle-monthly', - 'wooexpress-small-bundle-yearly', - 'wooexpress-small-bundle-monthly', - 'wooexpress-medium-bundle-yearly', - 'wooexpress-medium-bundle-monthly', - 'wp_com_hundred_year_bundle_centennially', - ), - 'supports' => array(), - ), - - 'complete' => array( - 'plans' => array( - 'jetpack_complete', - 'jetpack_complete_monthly', - 'vip', - ), - 'supports' => array(), - ), - ); - - /** - * Given a response to the `/sites/%d` endpoint, will parse the response and attempt to set the - * site's plan and products from the response. - * - * @param array $response The response from `/sites/%d`. - * @return bool Was the plan successfully updated? - */ - public static function update_from_sites_response( $response ) { - // Bail if there was an error or malformed response. - if ( is_wp_error( $response ) || ! is_array( $response ) || ! isset( $response['body'] ) ) { - return false; - } - - $body = wp_remote_retrieve_body( $response ); - if ( is_wp_error( $body ) ) { - return false; - } - - // Decode the results. - $results = json_decode( $body, true ); - - if ( ! is_array( $results ) ) { - return false; - } - - if ( isset( $results['products'] ) ) { - // Store the site's products in an option and return true if updated. - self::store_data_in_option( self::SITE_PRODUCTS_OPTION, $results['products'] ); - } - - if ( ! isset( $results['plan'] ) ) { - return false; - } - - $current_plan = get_option( self::PLAN_OPTION, array() ); - - if ( ! empty( $current_plan ) && $current_plan === $results['plan'] ) { - // Bail if the plans array hasn't changed. - return false; - } - - // Store the new plan in an option and return true if updated. - $result = self::store_data_in_option( self::PLAN_OPTION, $results['plan'] ); - - if ( $result ) { - // Reset the cache since we've just updated the plan. - self::$active_plan_cache = null; - } - - return $result; - } - - /** - * Store data in an option. - * - * @param string $option The name of the option that will store the data. - * @param array $data Data to be store in an option. - * @return bool Were the subscriptions successfully updated? - */ - private static function store_data_in_option( $option, $data ) { - $result = update_option( $option, $data, true ); - - // If something goes wrong with the update, so delete the current option and then update it. - if ( ! $result ) { - delete_option( $option ); - $result = update_option( $option, $data, true ); - } - - return $result; - } - - /** - * Make an API call to WordPress.com for plan status - * - * @uses Jetpack_Options::get_option() - * @uses Client::wpcom_json_api_request_as_blog() - * @uses update_option() - * - * @access public - * @static - * - * @return bool True if plan is updated, false if no update - */ - public static function refresh_from_wpcom() { - $site_id = Manager::get_site_id(); - if ( is_wp_error( $site_id ) ) { - return false; - } - - // Make the API request. - - $response = Client::wpcom_json_api_request_as_blog( - sprintf( '/sites/%d?force=wpcom', $site_id ), - '1.1' - ); - - return self::update_from_sites_response( $response ); - } - - /** - * Get the plan that this Jetpack site is currently using. - * - * @uses get_option() - * - * @access public - * @static - * - * @return array Active Jetpack plan details - */ - public static function get() { - // this can be expensive to compute so we cache for the duration of a request. - if ( is_array( self::$active_plan_cache ) && ! empty( self::$active_plan_cache ) ) { - return self::$active_plan_cache; - } - - $plan = get_option( self::PLAN_OPTION, array() ); - - // Set the default options. - $plan = wp_parse_args( - $plan, - array( - 'product_slug' => 'jetpack_free', - 'class' => 'free', - 'features' => array( - 'active' => array(), - ), - ) - ); - - list( $plan['class'], $supports ) = self::get_class_and_features( $plan['product_slug'] ); - - $modules = new Modules(); - foreach ( $modules->get_available() as $module_slug ) { - $module = $modules->get( $module_slug ); - if ( ! isset( $module ) || ! is_array( $module ) ) { - continue; - } - if ( in_array( 'free', $module['plan_classes'], true ) || in_array( $plan['class'], $module['plan_classes'], true ) ) { - $supports[] = $module_slug; - } - } - - $plan['supports'] = $supports; - - self::$active_plan_cache = $plan; - - return $plan; - } - - /** - * Get the site's products. - * - * @uses get_option() - * - * @access public - * @static - * - * @return array Active Jetpack products - */ - public static function get_products() { - return get_option( self::SITE_PRODUCTS_OPTION, array() ); - } - - /** - * Get the class of plan and a list of features it supports - * - * @param string $plan_slug The plan that we're interested in. - * @return array Two item array, the plan class and the an array of features. - */ - private static function get_class_and_features( $plan_slug ) { - $features = array(); - foreach ( self::PLAN_DATA as $class => $details ) { - $features = array_merge( $features, $details['supports'] ); - if ( in_array( $plan_slug, $details['plans'], true ) ) { - return array( $class, $features ); - } - } - return array( 'free', self::PLAN_DATA['free']['supports'] ); - } - - /** - * Gets the minimum plan slug that supports the given feature - * - * @param string $feature The name of the feature. - * @return string|bool The slug for the minimum plan that supports. - * the feature or false if not found - */ - public static function get_minimum_plan_for_feature( $feature ) { - foreach ( self::PLAN_DATA as $details ) { - if ( in_array( $feature, $details['supports'], true ) ) { - return $details['plans'][0]; - } - } - return false; - } - - /** - * Determine whether the active plan supports a particular feature - * - * @uses self::get() - * - * @access public - * @static - * - * @param string $feature The module or feature to check. - * @param bool $refresh_from_wpcom Refresh the local plan cache from wpcom. - * - * @return bool True if plan supports feature, false if not - */ - public static function supports( $feature, $refresh_from_wpcom = false ) { - if ( $refresh_from_wpcom ) { - self::refresh_from_wpcom(); - } - - // Hijack the feature eligibility check on WordPress.com sites since they are gated differently. - $should_wpcom_gate_feature = ( - function_exists( 'wpcom_site_has_feature' ) && - function_exists( 'wpcom_feature_exists' ) && - wpcom_feature_exists( $feature ) - ); - if ( $should_wpcom_gate_feature ) { - return wpcom_site_has_feature( $feature ); - } - - // Search product bypasses plan feature check. - if ( 'search' === $feature && (bool) get_option( 'has_jetpack_search_product' ) ) { - return true; - } - - // As of Q3 2021 - a videopress free tier is available to all plans. - if ( 'videopress' === $feature ) { - return true; - } - - // As of 05 2023 - all plans support Earn features (minus 'simple-payments'). - if ( in_array( $feature, array( 'donations', 'recurring-payments', 'premium-content/container' ), true ) ) { - return true; - } - - $plan = self::get(); - - if ( - in_array( $feature, $plan['supports'], true ) - || in_array( $feature, $plan['features']['active'], true ) - ) { - return true; - } - - return false; - } - - /** - * Retrieve site-specific features for Simple sites. - * - * See Jetpack_Gutenberg::get_site_specific_features() - * - * @return array - */ - public static function get_simple_site_specific_features() { - $is_simple_site = defined( 'IS_WPCOM' ) && constant( 'IS_WPCOM' ); - - if ( ! $is_simple_site ) { - return array( - 'active' => array(), - 'available' => array(), - ); - } - - $current_blog_id = get_current_blog_id(); - - // Return the cached value if it exists. - if ( isset( self::$simple_site_specific_features[ $current_blog_id ] ) ) { - return self::$simple_site_specific_features[ $current_blog_id ]; - } - - if ( ! class_exists( '\Store_Product_List' ) ) { - require WP_CONTENT_DIR . '/admin-plugins/wpcom-billing/store-product-list.php'; - } - - $simple_site_specific_features = \Store_Product_List::get_site_specific_features_data( $current_blog_id ); - - self::$simple_site_specific_features[ $current_blog_id ] = $simple_site_specific_features; - - return $simple_site_specific_features; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-plans.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-plans.php deleted file mode 100644 index 589593bf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/automattic/jetpack-plans/src/class-plans.php +++ /dev/null @@ -1,111 +0,0 @@ - 'GET', - 'headers' => array( - 'X-Forwarded-For' => ( new \Automattic\Jetpack\Status\Visitor() )->get_ip( true ), - ), - ), - null, - 'rest' - ); - - $body = wp_remote_retrieve_body( $request ); - if ( 200 === wp_remote_retrieve_response_code( $request ) ) { - return json_decode( $body ); - } else { - return $body; - } - } - - /** - * Get plan information for a plan given its slug - * - * @since-jetpack 7.7.0 - * - * @param string $plan_slug Plan slug. - * - * @return object The plan object - */ - public static function get_plan( $plan_slug ) { - $plans = self::get_plans(); - if ( ! is_array( $plans ) ) { - return; - } - - foreach ( $plans as $plan ) { - if ( $plan_slug === $plan->product_slug ) { - return $plan; - } - } - } - - /** - * Efficiently get the short name of a plan from a slug. - * - * @param string $plan_slug Plan slug. - * @return string|null Short product name or null if not round. - */ - public static function get_plan_short_name( $plan_slug ) { - if ( defined( 'IS_WPCOM' ) && IS_WPCOM ) { - if ( ! class_exists( 'Store_Product_List' ) ) { - require WP_CONTENT_DIR . '/admin-plugins/wpcom-billing/store-product-list.php'; - } - - // Skip additional work like processing of coupons, since we only need the plan's short name. - $products = Store_Product_List::get(); - - foreach ( $products as $product ) { - if ( isset( $product['product_slug'] ) && $product['product_slug'] === $plan_slug ) { - return $product['product_name_short'] ?? null; - } - } - - return null; - } - - // Fallback to less efficient method for Jetpack environments. - $plan = self::get_plan( $plan_slug ); - return $plan->product_name_short ?? null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/ClassLoader.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/ClassLoader.php deleted file mode 100644 index 7824d8f7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/ClassLoader.php +++ /dev/null @@ -1,579 +0,0 @@ - - * Jordi Boggiano - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Composer\Autoload; - -/** - * ClassLoader implements a PSR-0, PSR-4 and classmap class loader. - * - * $loader = new \Composer\Autoload\ClassLoader(); - * - * // register classes with namespaces - * $loader->add('Symfony\Component', __DIR__.'/component'); - * $loader->add('Symfony', __DIR__.'/framework'); - * - * // activate the autoloader - * $loader->register(); - * - * // to enable searching the include path (eg. for PEAR packages) - * $loader->setUseIncludePath(true); - * - * In this example, if you try to use a class in the Symfony\Component - * namespace or one of its children (Symfony\Component\Console for instance), - * the autoloader will first look for the class under the component/ - * directory, and it will then fallback to the framework/ directory if not - * found before giving up. - * - * This class is loosely based on the Symfony UniversalClassLoader. - * - * @author Fabien Potencier - * @author Jordi Boggiano - * @see https://www.php-fig.org/psr/psr-0/ - * @see https://www.php-fig.org/psr/psr-4/ - */ -class ClassLoader -{ - /** @var \Closure(string):void */ - private static $includeFile; - - /** @var string|null */ - private $vendorDir; - - // PSR-4 - /** - * @var array> - */ - private $prefixLengthsPsr4 = array(); - /** - * @var array> - */ - private $prefixDirsPsr4 = array(); - /** - * @var list - */ - private $fallbackDirsPsr4 = array(); - - // PSR-0 - /** - * List of PSR-0 prefixes - * - * Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2'))) - * - * @var array>> - */ - private $prefixesPsr0 = array(); - /** - * @var list - */ - private $fallbackDirsPsr0 = array(); - - /** @var bool */ - private $useIncludePath = false; - - /** - * @var array - */ - private $classMap = array(); - - /** @var bool */ - private $classMapAuthoritative = false; - - /** - * @var array - */ - private $missingClasses = array(); - - /** @var string|null */ - private $apcuPrefix; - - /** - * @var array - */ - private static $registeredLoaders = array(); - - /** - * @param string|null $vendorDir - */ - public function __construct($vendorDir = null) - { - $this->vendorDir = $vendorDir; - self::initializeIncludeClosure(); - } - - /** - * @return array> - */ - public function getPrefixes() - { - if (!empty($this->prefixesPsr0)) { - return call_user_func_array('array_merge', array_values($this->prefixesPsr0)); - } - - return array(); - } - - /** - * @return array> - */ - public function getPrefixesPsr4() - { - return $this->prefixDirsPsr4; - } - - /** - * @return list - */ - public function getFallbackDirs() - { - return $this->fallbackDirsPsr0; - } - - /** - * @return list - */ - public function getFallbackDirsPsr4() - { - return $this->fallbackDirsPsr4; - } - - /** - * @return array Array of classname => path - */ - public function getClassMap() - { - return $this->classMap; - } - - /** - * @param array $classMap Class to filename map - * - * @return void - */ - public function addClassMap(array $classMap) - { - if ($this->classMap) { - $this->classMap = array_merge($this->classMap, $classMap); - } else { - $this->classMap = $classMap; - } - } - - /** - * Registers a set of PSR-0 directories for a given prefix, either - * appending or prepending to the ones previously set for this prefix. - * - * @param string $prefix The prefix - * @param list|string $paths The PSR-0 root directories - * @param bool $prepend Whether to prepend the directories - * - * @return void - */ - public function add($prefix, $paths, $prepend = false) - { - $paths = (array) $paths; - if (!$prefix) { - if ($prepend) { - $this->fallbackDirsPsr0 = array_merge( - $paths, - $this->fallbackDirsPsr0 - ); - } else { - $this->fallbackDirsPsr0 = array_merge( - $this->fallbackDirsPsr0, - $paths - ); - } - - return; - } - - $first = $prefix[0]; - if (!isset($this->prefixesPsr0[$first][$prefix])) { - $this->prefixesPsr0[$first][$prefix] = $paths; - - return; - } - if ($prepend) { - $this->prefixesPsr0[$first][$prefix] = array_merge( - $paths, - $this->prefixesPsr0[$first][$prefix] - ); - } else { - $this->prefixesPsr0[$first][$prefix] = array_merge( - $this->prefixesPsr0[$first][$prefix], - $paths - ); - } - } - - /** - * Registers a set of PSR-4 directories for a given namespace, either - * appending or prepending to the ones previously set for this namespace. - * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param list|string $paths The PSR-4 base directories - * @param bool $prepend Whether to prepend the directories - * - * @throws \InvalidArgumentException - * - * @return void - */ - public function addPsr4($prefix, $paths, $prepend = false) - { - $paths = (array) $paths; - if (!$prefix) { - // Register directories for the root namespace. - if ($prepend) { - $this->fallbackDirsPsr4 = array_merge( - $paths, - $this->fallbackDirsPsr4 - ); - } else { - $this->fallbackDirsPsr4 = array_merge( - $this->fallbackDirsPsr4, - $paths - ); - } - } elseif (!isset($this->prefixDirsPsr4[$prefix])) { - // Register directories for a new namespace. - $length = strlen($prefix); - if ('\\' !== $prefix[$length - 1]) { - throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); - } - $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = $paths; - } elseif ($prepend) { - // Prepend directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - $paths, - $this->prefixDirsPsr4[$prefix] - ); - } else { - // Append directories for an already registered namespace. - $this->prefixDirsPsr4[$prefix] = array_merge( - $this->prefixDirsPsr4[$prefix], - $paths - ); - } - } - - /** - * Registers a set of PSR-0 directories for a given prefix, - * replacing any others previously set for this prefix. - * - * @param string $prefix The prefix - * @param list|string $paths The PSR-0 base directories - * - * @return void - */ - public function set($prefix, $paths) - { - if (!$prefix) { - $this->fallbackDirsPsr0 = (array) $paths; - } else { - $this->prefixesPsr0[$prefix[0]][$prefix] = (array) $paths; - } - } - - /** - * Registers a set of PSR-4 directories for a given namespace, - * replacing any others previously set for this namespace. - * - * @param string $prefix The prefix/namespace, with trailing '\\' - * @param list|string $paths The PSR-4 base directories - * - * @throws \InvalidArgumentException - * - * @return void - */ - public function setPsr4($prefix, $paths) - { - if (!$prefix) { - $this->fallbackDirsPsr4 = (array) $paths; - } else { - $length = strlen($prefix); - if ('\\' !== $prefix[$length - 1]) { - throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator."); - } - $this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length; - $this->prefixDirsPsr4[$prefix] = (array) $paths; - } - } - - /** - * Turns on searching the include path for class files. - * - * @param bool $useIncludePath - * - * @return void - */ - public function setUseIncludePath($useIncludePath) - { - $this->useIncludePath = $useIncludePath; - } - - /** - * Can be used to check if the autoloader uses the include path to check - * for classes. - * - * @return bool - */ - public function getUseIncludePath() - { - return $this->useIncludePath; - } - - /** - * Turns off searching the prefix and fallback directories for classes - * that have not been registered with the class map. - * - * @param bool $classMapAuthoritative - * - * @return void - */ - public function setClassMapAuthoritative($classMapAuthoritative) - { - $this->classMapAuthoritative = $classMapAuthoritative; - } - - /** - * Should class lookup fail if not found in the current class map? - * - * @return bool - */ - public function isClassMapAuthoritative() - { - return $this->classMapAuthoritative; - } - - /** - * APCu prefix to use to cache found/not-found classes, if the extension is enabled. - * - * @param string|null $apcuPrefix - * - * @return void - */ - public function setApcuPrefix($apcuPrefix) - { - $this->apcuPrefix = function_exists('apcu_fetch') && filter_var(ini_get('apc.enabled'), FILTER_VALIDATE_BOOLEAN) ? $apcuPrefix : null; - } - - /** - * The APCu prefix in use, or null if APCu caching is not enabled. - * - * @return string|null - */ - public function getApcuPrefix() - { - return $this->apcuPrefix; - } - - /** - * Registers this instance as an autoloader. - * - * @param bool $prepend Whether to prepend the autoloader or not - * - * @return void - */ - public function register($prepend = false) - { - spl_autoload_register(array($this, 'loadClass'), true, $prepend); - - if (null === $this->vendorDir) { - return; - } - - if ($prepend) { - self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders; - } else { - unset(self::$registeredLoaders[$this->vendorDir]); - self::$registeredLoaders[$this->vendorDir] = $this; - } - } - - /** - * Unregisters this instance as an autoloader. - * - * @return void - */ - public function unregister() - { - spl_autoload_unregister(array($this, 'loadClass')); - - if (null !== $this->vendorDir) { - unset(self::$registeredLoaders[$this->vendorDir]); - } - } - - /** - * Loads the given class or interface. - * - * @param string $class The name of the class - * @return true|null True if loaded, null otherwise - */ - public function loadClass($class) - { - if ($file = $this->findFile($class)) { - $includeFile = self::$includeFile; - $includeFile($file); - - return true; - } - - return null; - } - - /** - * Finds the path to the file where the class is defined. - * - * @param string $class The name of the class - * - * @return string|false The path if found, false otherwise - */ - public function findFile($class) - { - // class map lookup - if (isset($this->classMap[$class])) { - return $this->classMap[$class]; - } - if ($this->classMapAuthoritative || isset($this->missingClasses[$class])) { - return false; - } - if (null !== $this->apcuPrefix) { - $file = apcu_fetch($this->apcuPrefix.$class, $hit); - if ($hit) { - return $file; - } - } - - $file = $this->findFileWithExtension($class, '.php'); - - // Search for Hack files if we are running on HHVM - if (false === $file && defined('HHVM_VERSION')) { - $file = $this->findFileWithExtension($class, '.hh'); - } - - if (null !== $this->apcuPrefix) { - apcu_add($this->apcuPrefix.$class, $file); - } - - if (false === $file) { - // Remember that this class does not exist. - $this->missingClasses[$class] = true; - } - - return $file; - } - - /** - * Returns the currently registered loaders keyed by their corresponding vendor directories. - * - * @return array - */ - public static function getRegisteredLoaders() - { - return self::$registeredLoaders; - } - - /** - * @param string $class - * @param string $ext - * @return string|false - */ - private function findFileWithExtension($class, $ext) - { - // PSR-4 lookup - $logicalPathPsr4 = strtr($class, '\\', DIRECTORY_SEPARATOR) . $ext; - - $first = $class[0]; - if (isset($this->prefixLengthsPsr4[$first])) { - $subPath = $class; - while (false !== $lastPos = strrpos($subPath, '\\')) { - $subPath = substr($subPath, 0, $lastPos); - $search = $subPath . '\\'; - if (isset($this->prefixDirsPsr4[$search])) { - $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1); - foreach ($this->prefixDirsPsr4[$search] as $dir) { - if (file_exists($file = $dir . $pathEnd)) { - return $file; - } - } - } - } - } - - // PSR-4 fallback dirs - foreach ($this->fallbackDirsPsr4 as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr4)) { - return $file; - } - } - - // PSR-0 lookup - if (false !== $pos = strrpos($class, '\\')) { - // namespaced class name - $logicalPathPsr0 = substr($logicalPathPsr4, 0, $pos + 1) - . strtr(substr($logicalPathPsr4, $pos + 1), '_', DIRECTORY_SEPARATOR); - } else { - // PEAR-like class name - $logicalPathPsr0 = strtr($class, '_', DIRECTORY_SEPARATOR) . $ext; - } - - if (isset($this->prefixesPsr0[$first])) { - foreach ($this->prefixesPsr0[$first] as $prefix => $dirs) { - if (0 === strpos($class, $prefix)) { - foreach ($dirs as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { - return $file; - } - } - } - } - } - - // PSR-0 fallback dirs - foreach ($this->fallbackDirsPsr0 as $dir) { - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . $logicalPathPsr0)) { - return $file; - } - } - - // PSR-0 include paths. - if ($this->useIncludePath && $file = stream_resolve_include_path($logicalPathPsr0)) { - return $file; - } - - return false; - } - - /** - * @return void - */ - private static function initializeIncludeClosure() - { - if (self::$includeFile !== null) { - return; - } - - /** - * Scope isolated include. - * - * Prevents access to $this/self from included files. - * - * @param string $file - * @return void - */ - self::$includeFile = \Closure::bind(static function($file) { - include $file; - }, null, null); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/InstalledVersions.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/InstalledVersions.php deleted file mode 100644 index 51e734a7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/InstalledVersions.php +++ /dev/null @@ -1,359 +0,0 @@ - - * Jordi Boggiano - * - * For the full copyright and license information, please view the LICENSE - * file that was distributed with this source code. - */ - -namespace Composer; - -use Composer\Autoload\ClassLoader; -use Composer\Semver\VersionParser; - -/** - * This class is copied in every Composer installed project and available to all - * - * See also https://getcomposer.org/doc/07-runtime.md#installed-versions - * - * To require its presence, you can require `composer-runtime-api ^2.0` - * - * @final - */ -class InstalledVersions -{ - /** - * @var mixed[]|null - * @psalm-var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array}|array{}|null - */ - private static $installed; - - /** - * @var bool|null - */ - private static $canGetVendors; - - /** - * @var array[] - * @psalm-var array}> - */ - private static $installedByVendor = array(); - - /** - * Returns a list of all package names which are present, either by being installed, replaced or provided - * - * @return string[] - * @psalm-return list - */ - public static function getInstalledPackages() - { - $packages = array(); - foreach (self::getInstalled() as $installed) { - $packages[] = array_keys($installed['versions']); - } - - if (1 === \count($packages)) { - return $packages[0]; - } - - return array_keys(array_flip(\call_user_func_array('array_merge', $packages))); - } - - /** - * Returns a list of all package names with a specific type e.g. 'library' - * - * @param string $type - * @return string[] - * @psalm-return list - */ - public static function getInstalledPackagesByType($type) - { - $packagesByType = array(); - - foreach (self::getInstalled() as $installed) { - foreach ($installed['versions'] as $name => $package) { - if (isset($package['type']) && $package['type'] === $type) { - $packagesByType[] = $name; - } - } - } - - return $packagesByType; - } - - /** - * Checks whether the given package is installed - * - * This also returns true if the package name is provided or replaced by another package - * - * @param string $packageName - * @param bool $includeDevRequirements - * @return bool - */ - public static function isInstalled($packageName, $includeDevRequirements = true) - { - foreach (self::getInstalled() as $installed) { - if (isset($installed['versions'][$packageName])) { - return $includeDevRequirements || !isset($installed['versions'][$packageName]['dev_requirement']) || $installed['versions'][$packageName]['dev_requirement'] === false; - } - } - - return false; - } - - /** - * Checks whether the given package satisfies a version constraint - * - * e.g. If you want to know whether version 2.3+ of package foo/bar is installed, you would call: - * - * Composer\InstalledVersions::satisfies(new VersionParser, 'foo/bar', '^2.3') - * - * @param VersionParser $parser Install composer/semver to have access to this class and functionality - * @param string $packageName - * @param string|null $constraint A version constraint to check for, if you pass one you have to make sure composer/semver is required by your package - * @return bool - */ - public static function satisfies(VersionParser $parser, $packageName, $constraint) - { - $constraint = $parser->parseConstraints((string) $constraint); - $provided = $parser->parseConstraints(self::getVersionRanges($packageName)); - - return $provided->matches($constraint); - } - - /** - * Returns a version constraint representing all the range(s) which are installed for a given package - * - * It is easier to use this via isInstalled() with the $constraint argument if you need to check - * whether a given version of a package is installed, and not just whether it exists - * - * @param string $packageName - * @return string Version constraint usable with composer/semver - */ - public static function getVersionRanges($packageName) - { - foreach (self::getInstalled() as $installed) { - if (!isset($installed['versions'][$packageName])) { - continue; - } - - $ranges = array(); - if (isset($installed['versions'][$packageName]['pretty_version'])) { - $ranges[] = $installed['versions'][$packageName]['pretty_version']; - } - if (array_key_exists('aliases', $installed['versions'][$packageName])) { - $ranges = array_merge($ranges, $installed['versions'][$packageName]['aliases']); - } - if (array_key_exists('replaced', $installed['versions'][$packageName])) { - $ranges = array_merge($ranges, $installed['versions'][$packageName]['replaced']); - } - if (array_key_exists('provided', $installed['versions'][$packageName])) { - $ranges = array_merge($ranges, $installed['versions'][$packageName]['provided']); - } - - return implode(' || ', $ranges); - } - - throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); - } - - /** - * @param string $packageName - * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present - */ - public static function getVersion($packageName) - { - foreach (self::getInstalled() as $installed) { - if (!isset($installed['versions'][$packageName])) { - continue; - } - - if (!isset($installed['versions'][$packageName]['version'])) { - return null; - } - - return $installed['versions'][$packageName]['version']; - } - - throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); - } - - /** - * @param string $packageName - * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present - */ - public static function getPrettyVersion($packageName) - { - foreach (self::getInstalled() as $installed) { - if (!isset($installed['versions'][$packageName])) { - continue; - } - - if (!isset($installed['versions'][$packageName]['pretty_version'])) { - return null; - } - - return $installed['versions'][$packageName]['pretty_version']; - } - - throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); - } - - /** - * @param string $packageName - * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as reference - */ - public static function getReference($packageName) - { - foreach (self::getInstalled() as $installed) { - if (!isset($installed['versions'][$packageName])) { - continue; - } - - if (!isset($installed['versions'][$packageName]['reference'])) { - return null; - } - - return $installed['versions'][$packageName]['reference']; - } - - throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); - } - - /** - * @param string $packageName - * @return string|null If the package is being replaced or provided but is not really installed, null will be returned as install path. Packages of type metapackages also have a null install path. - */ - public static function getInstallPath($packageName) - { - foreach (self::getInstalled() as $installed) { - if (!isset($installed['versions'][$packageName])) { - continue; - } - - return isset($installed['versions'][$packageName]['install_path']) ? $installed['versions'][$packageName]['install_path'] : null; - } - - throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed'); - } - - /** - * @return array - * @psalm-return array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool} - */ - public static function getRootPackage() - { - $installed = self::getInstalled(); - - return $installed[0]['root']; - } - - /** - * Returns the raw installed.php data for custom implementations - * - * @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect. - * @return array[] - * @psalm-return array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array} - */ - public static function getRawData() - { - @trigger_error('getRawData only returns the first dataset loaded, which may not be what you expect. Use getAllRawData() instead which returns all datasets for all autoloaders present in the process.', E_USER_DEPRECATED); - - if (null === self::$installed) { - // only require the installed.php file if this file is loaded from its dumped location, - // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937 - if (substr(__DIR__, -8, 1) !== 'C') { - self::$installed = include __DIR__ . '/installed.php'; - } else { - self::$installed = array(); - } - } - - return self::$installed; - } - - /** - * Returns the raw data of all installed.php which are currently loaded for custom implementations - * - * @return array[] - * @psalm-return list}> - */ - public static function getAllRawData() - { - return self::getInstalled(); - } - - /** - * Lets you reload the static array from another file - * - * This is only useful for complex integrations in which a project needs to use - * this class but then also needs to execute another project's autoloader in process, - * and wants to ensure both projects have access to their version of installed.php. - * - * A typical case would be PHPUnit, where it would need to make sure it reads all - * the data it needs from this class, then call reload() with - * `require $CWD/vendor/composer/installed.php` (or similar) as input to make sure - * the project in which it runs can then also use this class safely, without - * interference between PHPUnit's dependencies and the project's dependencies. - * - * @param array[] $data A vendor/composer/installed.php data set - * @return void - * - * @psalm-param array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array} $data - */ - public static function reload($data) - { - self::$installed = $data; - self::$installedByVendor = array(); - } - - /** - * @return array[] - * @psalm-return list}> - */ - private static function getInstalled() - { - if (null === self::$canGetVendors) { - self::$canGetVendors = method_exists('Composer\Autoload\ClassLoader', 'getRegisteredLoaders'); - } - - $installed = array(); - - if (self::$canGetVendors) { - foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) { - if (isset(self::$installedByVendor[$vendorDir])) { - $installed[] = self::$installedByVendor[$vendorDir]; - } elseif (is_file($vendorDir.'/composer/installed.php')) { - /** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array} $required */ - $required = require $vendorDir.'/composer/installed.php'; - $installed[] = self::$installedByVendor[$vendorDir] = $required; - if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) { - self::$installed = $installed[count($installed) - 1]; - } - } - } - } - - if (null === self::$installed) { - // only require the installed.php file if this file is loaded from its dumped location, - // and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937 - if (substr(__DIR__, -8, 1) !== 'C') { - /** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array} $required */ - $required = require __DIR__ . '/installed.php'; - self::$installed = $required; - } else { - self::$installed = array(); - } - } - - if (self::$installed !== array()) { - $installed[] = self::$installed; - } - - return $installed; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/LICENSE b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/LICENSE deleted file mode 100644 index f27399a0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ - -Copyright (c) Nils Adermann, Jordi Boggiano - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is furnished -to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. - diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_classmap.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_classmap.php deleted file mode 100644 index 48bdd83f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_classmap.php +++ /dev/null @@ -1,253 +0,0 @@ - $vendorDir . '/wikimedia/aho-corasick/src/MultiStringMatcher.php', - 'AhoCorasick\\MultiStringReplacer' => $vendorDir . '/wikimedia/aho-corasick/src/MultiStringReplacer.php', - 'Automattic\\Jetpack\\A8c_Mc_Stats' => $baseDir . '/jetpack_vendor/automattic/jetpack-a8c-mc-stats/src/class-a8c-mc-stats.php', - 'Automattic\\Jetpack\\Admin_UI\\Admin_Menu' => $baseDir . '/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php', - 'Automattic\\Jetpack\\Assets' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php', - 'Automattic\\Jetpack\\Assets\\Logo' => $baseDir . '/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php', - 'Automattic\\Jetpack\\Assets\\Script_Data' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-script-data.php', - 'Automattic\\Jetpack\\Assets\\Semver' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-semver.php', - 'Automattic\\Jetpack\\Autoloader\\AutoloadFileWriter' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadFileWriter.php', - 'Automattic\\Jetpack\\Autoloader\\AutoloadGenerator' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadGenerator.php', - 'Automattic\\Jetpack\\Autoloader\\AutoloadProcessor' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadProcessor.php', - 'Automattic\\Jetpack\\Autoloader\\CustomAutoloaderPlugin' => $vendorDir . '/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php', - 'Automattic\\Jetpack\\Autoloader\\ManifestGenerator' => $vendorDir . '/automattic/jetpack-autoloader/src/ManifestGenerator.php', - 'Automattic\\Jetpack\\Automatic_Install_Skin' => $baseDir . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php', - 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager' => $baseDir . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-helper-script-manager.php', - 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager_Impl' => $baseDir . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-helper-script-manager-impl.php', - 'Automattic\\Jetpack\\Backup\\V0005\\Throw_On_Errors' => $baseDir . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-throw-on-errors.php', - 'Automattic\\Jetpack\\Boost_Core\\Contracts\\Boost_API_Client' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/contracts/boost-api-client.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Boost_API' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-boost-api.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Cacheable' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-cacheable.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Transient' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-transient.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Url' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-url.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Utils' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-utils.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\WPCOM_Boost_API_Client' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-wpcom-boost-api-client.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Jetpack_Boost_Modules' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-jetpack-boost-modules.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_Graph_History_Request' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-graph-history-request.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_History' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-history.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_Request' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-request.php', - 'Automattic\\Jetpack\\Composer\\Manager' => $vendorDir . '/automattic/jetpack-composer-plugin/src/class-manager.php', - 'Automattic\\Jetpack\\Composer\\Plugin' => $vendorDir . '/automattic/jetpack-composer-plugin/src/class-plugin.php', - 'Automattic\\Jetpack\\Config' => $baseDir . '/jetpack_vendor/automattic/jetpack-config/src/class-config.php', - 'Automattic\\Jetpack\\Connection\\Authorize_Json_Api' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-authorize-json-api.php', - 'Automattic\\Jetpack\\Connection\\Client' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-client.php', - 'Automattic\\Jetpack\\Connection\\Connection_Assets' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-assets.php', - 'Automattic\\Jetpack\\Connection\\Connection_Notice' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-notice.php', - 'Automattic\\Jetpack\\Connection\\Error_Handler' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php', - 'Automattic\\Jetpack\\Connection\\Initial_State' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php', - 'Automattic\\Jetpack\\Connection\\Manager' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php', - 'Automattic\\Jetpack\\Connection\\Manager_Interface' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php', - 'Automattic\\Jetpack\\Connection\\Nonce_Handler' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php', - 'Automattic\\Jetpack\\Connection\\Package_Version' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php', - 'Automattic\\Jetpack\\Connection\\Package_Version_Tracker' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php', - 'Automattic\\Jetpack\\Connection\\Plugin' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php', - 'Automattic\\Jetpack\\Connection\\Plugin_Storage' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php', - 'Automattic\\Jetpack\\Connection\\REST_Connector' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php', - 'Automattic\\Jetpack\\Connection\\Rest_Authentication' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php', - 'Automattic\\Jetpack\\Connection\\SSO' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-sso.php', - 'Automattic\\Jetpack\\Connection\\SSO\\Force_2FA' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-force-2fa.php', - 'Automattic\\Jetpack\\Connection\\SSO\\Helpers' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-helpers.php', - 'Automattic\\Jetpack\\Connection\\SSO\\Notices' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-notices.php', - 'Automattic\\Jetpack\\Connection\\SSO\\User_Admin' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-user-admin.php', - 'Automattic\\Jetpack\\Connection\\Secrets' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php', - 'Automattic\\Jetpack\\Connection\\Server_Sandbox' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php', - 'Automattic\\Jetpack\\Connection\\Tokens' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php', - 'Automattic\\Jetpack\\Connection\\Tokens_Locks' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens-locks.php', - 'Automattic\\Jetpack\\Connection\\Traits\\WPCOM_REST_API_Proxy_Request' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/traits/trait-wpcom-rest-api-proxy-request.php', - 'Automattic\\Jetpack\\Connection\\Urls' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php', - 'Automattic\\Jetpack\\Connection\\Users_Connection_Admin' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-users-connection-admin.php', - 'Automattic\\Jetpack\\Connection\\Utils' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-utils.php', - 'Automattic\\Jetpack\\Connection\\Webhooks' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php', - 'Automattic\\Jetpack\\Connection\\Webhooks\\Authorize_Redirect' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php', - 'Automattic\\Jetpack\\Connection\\XMLRPC_Async_Call' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php', - 'Automattic\\Jetpack\\Connection\\XMLRPC_Connector' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php', - 'Automattic\\Jetpack\\Constants' => $baseDir . '/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php', - 'Automattic\\Jetpack\\CookieState' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-cookiestate.php', - 'Automattic\\Jetpack\\Current_Plan' => $vendorDir . '/automattic/jetpack-plans/src/class-current-plan.php', - 'Automattic\\Jetpack\\Device_Detection' => $baseDir . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php', - 'Automattic\\Jetpack\\Device_Detection\\User_Agent_Info' => $baseDir . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php', - 'Automattic\\Jetpack\\Errors' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-errors.php', - 'Automattic\\Jetpack\\ExPlat' => $baseDir . '/jetpack_vendor/automattic/jetpack-explat/src/class-explat.php', - 'Automattic\\Jetpack\\ExPlat\\REST_Controller' => $baseDir . '/jetpack_vendor/automattic/jetpack-explat/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Files' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-files.php', - 'Automattic\\Jetpack\\Heartbeat' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php', - 'Automattic\\Jetpack\\IP\\Utils' => $baseDir . '/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php', - 'Automattic\\Jetpack\\IdentityCrisis\\Exception' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-exception.php', - 'Automattic\\Jetpack\\IdentityCrisis\\REST_Endpoints' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-rest-endpoints.php', - 'Automattic\\Jetpack\\IdentityCrisis\\UI' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-ui.php', - 'Automattic\\Jetpack\\IdentityCrisis\\URL_Secret' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-url-secret.php', - 'Automattic\\Jetpack\\Identity_Crisis' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-identity-crisis.php', - 'Automattic\\Jetpack\\JITMS\\JITM' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php', - 'Automattic\\Jetpack\\JITMS\\Post_Connection_JITM' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php', - 'Automattic\\Jetpack\\JITMS\\Pre_Connection_JITM' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php', - 'Automattic\\Jetpack\\JITMS\\Rest_Api_Endpoints' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php', - 'Automattic\\Jetpack\\Licensing' => $baseDir . '/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php', - 'Automattic\\Jetpack\\Licensing\\Endpoints' => $baseDir . '/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php', - 'Automattic\\Jetpack\\Modules' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-modules.php', - 'Automattic\\Jetpack\\My_Jetpack\\Activitylog' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-activitylog.php', - 'Automattic\\Jetpack\\My_Jetpack\\Historically_Active_Modules' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-historically-active-modules.php', - 'Automattic\\Jetpack\\My_Jetpack\\Hybrid_Product' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php', - 'Automattic\\Jetpack\\My_Jetpack\\Initializer' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php', - 'Automattic\\Jetpack\\My_Jetpack\\Jetpack_Manage' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-jetpack-manage.php', - 'Automattic\\Jetpack\\My_Jetpack\\Module_Product' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php', - 'Automattic\\Jetpack\\My_Jetpack\\Product' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Anti_Spam' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-anti-spam.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Backup' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Boost' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Complete' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-complete.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Creator' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-creator.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Crm' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Extras' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Growth' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-growth.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Jetpack_Ai' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-jetpack-ai.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Newsletter' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-newsletter.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Protect' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Related_Posts' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-related-posts.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Scan' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search_Stats' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search-stats.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Security' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Site_Accelerator' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-site-accelerator.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Social' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Starter' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-starter.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Stats' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-stats.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Videopress' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_AI' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-ai.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Products' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Purchases' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Recommendations_Evaluation' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-recommendations-evaluation.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Zendesk_Chat' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-zendesk-chat.php', - 'Automattic\\Jetpack\\My_Jetpack\\Red_Bubble_Notifications' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-red-bubble-notifications.php', - 'Automattic\\Jetpack\\My_Jetpack\\Wpcom_Products' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php', - 'Automattic\\Jetpack\\Partner' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-partner.php', - 'Automattic\\Jetpack\\Partner_Coupon' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-partner-coupon.php', - 'Automattic\\Jetpack\\Password_Checker' => $baseDir . '/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php', - 'Automattic\\Jetpack\\Paths' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-paths.php', - 'Automattic\\Jetpack\\Plans' => $vendorDir . '/automattic/jetpack-plans/src/class-plans.php', - 'Automattic\\Jetpack\\Plugins_Installer' => $baseDir . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php', - 'Automattic\\Jetpack\\Protect\\Credentials' => $baseDir . '/src/class-credentials.php', - 'Automattic\\Jetpack\\Protect\\Onboarding' => $baseDir . '/src/class-onboarding.php', - 'Automattic\\Jetpack\\Protect\\REST_Controller' => $baseDir . '/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Protect\\Scan_History' => $baseDir . '/src/class-scan-history.php', - 'Automattic\\Jetpack\\Protect\\Site_Health' => $baseDir . '/src/class-site-health.php', - 'Automattic\\Jetpack\\Protect\\Threats' => $baseDir . '/src/class-threats.php', - 'Automattic\\Jetpack\\Protect_Models' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-protect-models.php', - 'Automattic\\Jetpack\\Protect_Models\\Extension_Model' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-extension-model.php', - 'Automattic\\Jetpack\\Protect_Models\\History_Model' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-history-model.php', - 'Automattic\\Jetpack\\Protect_Models\\Status_Model' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-status-model.php', - 'Automattic\\Jetpack\\Protect_Models\\Threat_Model' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-threat-model.php', - 'Automattic\\Jetpack\\Protect_Models\\Vulnerability_Model' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-vulnerability-model.php', - 'Automattic\\Jetpack\\Protect_Status\\Plan' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-plan.php', - 'Automattic\\Jetpack\\Protect_Status\\Protect_Status' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-protect-status.php', - 'Automattic\\Jetpack\\Protect_Status\\REST_Controller' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Protect_Status\\Scan_Status' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-scan-status.php', - 'Automattic\\Jetpack\\Protect_Status\\Status' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-status.php', - 'Automattic\\Jetpack\\Redirect' => $baseDir . '/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php', - 'Automattic\\Jetpack\\Roles' => $baseDir . '/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php', - 'Automattic\\Jetpack\\Status' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-status.php', - 'Automattic\\Jetpack\\Status\\Cache' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-cache.php', - 'Automattic\\Jetpack\\Status\\Host' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-host.php', - 'Automattic\\Jetpack\\Status\\Visitor' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php', - 'Automattic\\Jetpack\\Sync\\Actions' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php', - 'Automattic\\Jetpack\\Sync\\Codec_Interface' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php', - 'Automattic\\Jetpack\\Sync\\Data_Settings' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php', - 'Automattic\\Jetpack\\Sync\\Dedicated_Sender' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php', - 'Automattic\\Jetpack\\Sync\\Default_Filter_Settings' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php', - 'Automattic\\Jetpack\\Sync\\Defaults' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php', - 'Automattic\\Jetpack\\Sync\\Functions' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php', - 'Automattic\\Jetpack\\Sync\\Health' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-health.php', - 'Automattic\\Jetpack\\Sync\\JSON_Deflate_Array_Codec' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php', - 'Automattic\\Jetpack\\Sync\\Listener' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php', - 'Automattic\\Jetpack\\Sync\\Lock' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php', - 'Automattic\\Jetpack\\Sync\\Main' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-main.php', - 'Automattic\\Jetpack\\Sync\\Modules' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Attachments' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-attachments.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Callables' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Comments' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Constants' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync_Immediately' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Import' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Menus' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Meta' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Module' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Network_Options' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Options' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Plugins' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Posts' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Protect' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Search' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Stats' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Term_Relationships' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-term-relationships.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Terms' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Themes' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Updates' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Users' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php', - 'Automattic\\Jetpack\\Sync\\Modules\\WP_Super_Cache' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php', - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php', - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce_HPOS_Orders' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce-hpos-orders.php', - 'Automattic\\Jetpack\\Sync\\Package_Version' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php', - 'Automattic\\Jetpack\\Sync\\Queue' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php', - 'Automattic\\Jetpack\\Sync\\Queue\\Queue_Storage_Options' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-options.php', - 'Automattic\\Jetpack\\Sync\\Queue\\Queue_Storage_Table' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-table.php', - 'Automattic\\Jetpack\\Sync\\Queue_Buffer' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue-buffer.php', - 'Automattic\\Jetpack\\Sync\\REST_Endpoints' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php', - 'Automattic\\Jetpack\\Sync\\REST_Sender' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php', - 'Automattic\\Jetpack\\Sync\\Replicastore' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php', - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php', - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Usermeta' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php', - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Users' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php', - 'Automattic\\Jetpack\\Sync\\Replicastore_Interface' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/interface-replicastore.php', - 'Automattic\\Jetpack\\Sync\\Sender' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php', - 'Automattic\\Jetpack\\Sync\\Server' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-server.php', - 'Automattic\\Jetpack\\Sync\\Settings' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php', - 'Automattic\\Jetpack\\Sync\\Simple_Codec' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php', - 'Automattic\\Jetpack\\Sync\\Users' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-users.php', - 'Automattic\\Jetpack\\Sync\\Utils' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php', - 'Automattic\\Jetpack\\Terms_Of_Service' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php', - 'Automattic\\Jetpack\\Tracking' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php', - 'Automattic\\Jetpack\\Transport_Helper\\Package_Version' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php', - 'Automattic\\Jetpack\\Transport_Helper\\V0001\\Package_Version' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version-compat.php', - 'Automattic\\Jetpack\\Transport_Helper\\V0005\\REST_Controller' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Blocked_Login_Page' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-blocked-login-page.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Math_Authenticate' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-math-fallback.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Shared_Functions' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-shared-functions.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Transient_Cleanup' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php', - 'Automattic\\Jetpack\\Waf\\CLI' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php', - 'Automattic\\Jetpack\\Waf\\File_System_Exception' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php', - 'Automattic\\Jetpack\\Waf\\REST_Controller' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Waf\\Rules_API_Exception' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-rules-api-exception.php', - 'Automattic\\Jetpack\\Waf\\Waf_Blocklog_Manager' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-blocklog-manager.php', - 'Automattic\\Jetpack\\Waf\\Waf_Compatibility' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php', - 'Automattic\\Jetpack\\Waf\\Waf_Constants' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php', - 'Automattic\\Jetpack\\Waf\\Waf_Exception' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-waf-exception.php', - 'Automattic\\Jetpack\\Waf\\Waf_Initializer' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php', - 'Automattic\\Jetpack\\Waf\\Waf_Operators' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php', - 'Automattic\\Jetpack\\Waf\\Waf_Request' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php', - 'Automattic\\Jetpack\\Waf\\Waf_Rules_Manager' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php', - 'Automattic\\Jetpack\\Waf\\Waf_Runner' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runner.php', - 'Automattic\\Jetpack\\Waf\\Waf_Runtime' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runtime.php', - 'Automattic\\Jetpack\\Waf\\Waf_Standalone_Bootstrap' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php', - 'Automattic\\Jetpack\\Waf\\Waf_Stats' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php', - 'Automattic\\Jetpack\\Waf\\Waf_Transforms' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php', - 'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php', - 'Jetpack_IXR_Client' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-client.php', - 'Jetpack_IXR_ClientMulticall' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-clientmulticall.php', - 'Jetpack_Options' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-options.php', - 'Jetpack_Protect' => $baseDir . '/src/class-jetpack-protect.php', - 'Jetpack_Signature' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-signature.php', - 'Jetpack_Tracks_Client' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-client.php', - 'Jetpack_Tracks_Event' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-event.php', - 'Jetpack_XMLRPC_Server' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-xmlrpc-server.php', -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_files.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_files.php deleted file mode 100644 index cc9498e8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_files.php +++ /dev/null @@ -1,13 +0,0 @@ - $baseDir . '/jetpack_vendor/automattic/jetpack-assets/actions.php', - '7372b7fb88a9723cf5b76d456eb0b738' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/actions.php', - '590147edb63acb03b2852d5c4db13ce8' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/actions.php', - '3d45c7e6a7f0e71849e33afe4b3b3ede' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/cli.php', -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_namespaces.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_namespaces.php deleted file mode 100644 index 15a2ff3a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_namespaces.php +++ /dev/null @@ -1,9 +0,0 @@ - array($vendorDir . '/automattic/jetpack-autoloader/src'), -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_real.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_real.php deleted file mode 100644 index 0b047c3e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_real.php +++ /dev/null @@ -1,51 +0,0 @@ -setClassMapAuthoritative(true); - $loader->register(true); - - $filesToLoad = \Composer\Autoload\ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ4_0_0::$files; - $requireFile = \Closure::bind(static function ($fileIdentifier, $file) { - if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { - $GLOBALS['__composer_autoload_files'][$fileIdentifier] = true; - - require $file; - } - }, null, null); - foreach ($filesToLoad as $fileIdentifier => $file) { - $requireFile($fileIdentifier, $file); - } - - return $loader; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_static.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_static.php deleted file mode 100644 index 287f8fac..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/autoload_static.php +++ /dev/null @@ -1,286 +0,0 @@ - __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-assets/actions.php', - '7372b7fb88a9723cf5b76d456eb0b738' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/actions.php', - '590147edb63acb03b2852d5c4db13ce8' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-transport-helper/actions.php', - '3d45c7e6a7f0e71849e33afe4b3b3ede' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/cli.php', - ); - - public static $prefixLengthsPsr4 = array ( - 'A' => - array ( - 'Automattic\\Jetpack\\Autoloader\\' => 30, - ), - ); - - public static $prefixDirsPsr4 = array ( - 'Automattic\\Jetpack\\Autoloader\\' => - array ( - 0 => __DIR__ . '/..' . '/automattic/jetpack-autoloader/src', - ), - ); - - public static $classMap = array ( - 'AhoCorasick\\MultiStringMatcher' => __DIR__ . '/..' . '/wikimedia/aho-corasick/src/MultiStringMatcher.php', - 'AhoCorasick\\MultiStringReplacer' => __DIR__ . '/..' . '/wikimedia/aho-corasick/src/MultiStringReplacer.php', - 'Automattic\\Jetpack\\A8c_Mc_Stats' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-a8c-mc-stats/src/class-a8c-mc-stats.php', - 'Automattic\\Jetpack\\Admin_UI\\Admin_Menu' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php', - 'Automattic\\Jetpack\\Assets' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php', - 'Automattic\\Jetpack\\Assets\\Logo' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php', - 'Automattic\\Jetpack\\Assets\\Script_Data' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-assets/src/class-script-data.php', - 'Automattic\\Jetpack\\Assets\\Semver' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-assets/src/class-semver.php', - 'Automattic\\Jetpack\\Autoloader\\AutoloadFileWriter' => __DIR__ . '/..' . '/automattic/jetpack-autoloader/src/AutoloadFileWriter.php', - 'Automattic\\Jetpack\\Autoloader\\AutoloadGenerator' => __DIR__ . '/..' . '/automattic/jetpack-autoloader/src/AutoloadGenerator.php', - 'Automattic\\Jetpack\\Autoloader\\AutoloadProcessor' => __DIR__ . '/..' . '/automattic/jetpack-autoloader/src/AutoloadProcessor.php', - 'Automattic\\Jetpack\\Autoloader\\CustomAutoloaderPlugin' => __DIR__ . '/..' . '/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php', - 'Automattic\\Jetpack\\Autoloader\\ManifestGenerator' => __DIR__ . '/..' . '/automattic/jetpack-autoloader/src/ManifestGenerator.php', - 'Automattic\\Jetpack\\Automatic_Install_Skin' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php', - 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-helper-script-manager.php', - 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager_Impl' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-helper-script-manager-impl.php', - 'Automattic\\Jetpack\\Backup\\V0005\\Throw_On_Errors' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-throw-on-errors.php', - 'Automattic\\Jetpack\\Boost_Core\\Contracts\\Boost_API_Client' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/contracts/boost-api-client.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Boost_API' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-boost-api.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Cacheable' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-cacheable.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Transient' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-transient.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Url' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-url.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Utils' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-utils.php', - 'Automattic\\Jetpack\\Boost_Core\\Lib\\WPCOM_Boost_API_Client' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-wpcom-boost-api-client.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Jetpack_Boost_Modules' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-jetpack-boost-modules.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_Graph_History_Request' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-graph-history-request.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_History' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-history.php', - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_Request' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-request.php', - 'Automattic\\Jetpack\\Composer\\Manager' => __DIR__ . '/..' . '/automattic/jetpack-composer-plugin/src/class-manager.php', - 'Automattic\\Jetpack\\Composer\\Plugin' => __DIR__ . '/..' . '/automattic/jetpack-composer-plugin/src/class-plugin.php', - 'Automattic\\Jetpack\\Config' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-config/src/class-config.php', - 'Automattic\\Jetpack\\Connection\\Authorize_Json_Api' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-authorize-json-api.php', - 'Automattic\\Jetpack\\Connection\\Client' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-client.php', - 'Automattic\\Jetpack\\Connection\\Connection_Assets' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-assets.php', - 'Automattic\\Jetpack\\Connection\\Connection_Notice' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-notice.php', - 'Automattic\\Jetpack\\Connection\\Error_Handler' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php', - 'Automattic\\Jetpack\\Connection\\Initial_State' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php', - 'Automattic\\Jetpack\\Connection\\Manager' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php', - 'Automattic\\Jetpack\\Connection\\Manager_Interface' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php', - 'Automattic\\Jetpack\\Connection\\Nonce_Handler' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php', - 'Automattic\\Jetpack\\Connection\\Package_Version' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php', - 'Automattic\\Jetpack\\Connection\\Package_Version_Tracker' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php', - 'Automattic\\Jetpack\\Connection\\Plugin' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php', - 'Automattic\\Jetpack\\Connection\\Plugin_Storage' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php', - 'Automattic\\Jetpack\\Connection\\REST_Connector' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php', - 'Automattic\\Jetpack\\Connection\\Rest_Authentication' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php', - 'Automattic\\Jetpack\\Connection\\SSO' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-sso.php', - 'Automattic\\Jetpack\\Connection\\SSO\\Force_2FA' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-force-2fa.php', - 'Automattic\\Jetpack\\Connection\\SSO\\Helpers' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-helpers.php', - 'Automattic\\Jetpack\\Connection\\SSO\\Notices' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-notices.php', - 'Automattic\\Jetpack\\Connection\\SSO\\User_Admin' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-user-admin.php', - 'Automattic\\Jetpack\\Connection\\Secrets' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php', - 'Automattic\\Jetpack\\Connection\\Server_Sandbox' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php', - 'Automattic\\Jetpack\\Connection\\Tokens' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php', - 'Automattic\\Jetpack\\Connection\\Tokens_Locks' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens-locks.php', - 'Automattic\\Jetpack\\Connection\\Traits\\WPCOM_REST_API_Proxy_Request' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/traits/trait-wpcom-rest-api-proxy-request.php', - 'Automattic\\Jetpack\\Connection\\Urls' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php', - 'Automattic\\Jetpack\\Connection\\Users_Connection_Admin' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-users-connection-admin.php', - 'Automattic\\Jetpack\\Connection\\Utils' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-utils.php', - 'Automattic\\Jetpack\\Connection\\Webhooks' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php', - 'Automattic\\Jetpack\\Connection\\Webhooks\\Authorize_Redirect' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php', - 'Automattic\\Jetpack\\Connection\\XMLRPC_Async_Call' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php', - 'Automattic\\Jetpack\\Connection\\XMLRPC_Connector' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php', - 'Automattic\\Jetpack\\Constants' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php', - 'Automattic\\Jetpack\\CookieState' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-cookiestate.php', - 'Automattic\\Jetpack\\Current_Plan' => __DIR__ . '/..' . '/automattic/jetpack-plans/src/class-current-plan.php', - 'Automattic\\Jetpack\\Device_Detection' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php', - 'Automattic\\Jetpack\\Device_Detection\\User_Agent_Info' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php', - 'Automattic\\Jetpack\\Errors' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-errors.php', - 'Automattic\\Jetpack\\ExPlat' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-explat/src/class-explat.php', - 'Automattic\\Jetpack\\ExPlat\\REST_Controller' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-explat/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Files' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-files.php', - 'Automattic\\Jetpack\\Heartbeat' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php', - 'Automattic\\Jetpack\\IP\\Utils' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php', - 'Automattic\\Jetpack\\IdentityCrisis\\Exception' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-exception.php', - 'Automattic\\Jetpack\\IdentityCrisis\\REST_Endpoints' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-rest-endpoints.php', - 'Automattic\\Jetpack\\IdentityCrisis\\UI' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-ui.php', - 'Automattic\\Jetpack\\IdentityCrisis\\URL_Secret' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-url-secret.php', - 'Automattic\\Jetpack\\Identity_Crisis' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-identity-crisis.php', - 'Automattic\\Jetpack\\JITMS\\JITM' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php', - 'Automattic\\Jetpack\\JITMS\\Post_Connection_JITM' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php', - 'Automattic\\Jetpack\\JITMS\\Pre_Connection_JITM' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php', - 'Automattic\\Jetpack\\JITMS\\Rest_Api_Endpoints' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php', - 'Automattic\\Jetpack\\Licensing' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php', - 'Automattic\\Jetpack\\Licensing\\Endpoints' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php', - 'Automattic\\Jetpack\\Modules' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-modules.php', - 'Automattic\\Jetpack\\My_Jetpack\\Activitylog' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-activitylog.php', - 'Automattic\\Jetpack\\My_Jetpack\\Historically_Active_Modules' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-historically-active-modules.php', - 'Automattic\\Jetpack\\My_Jetpack\\Hybrid_Product' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php', - 'Automattic\\Jetpack\\My_Jetpack\\Initializer' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php', - 'Automattic\\Jetpack\\My_Jetpack\\Jetpack_Manage' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-jetpack-manage.php', - 'Automattic\\Jetpack\\My_Jetpack\\Module_Product' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php', - 'Automattic\\Jetpack\\My_Jetpack\\Product' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Anti_Spam' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-anti-spam.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Backup' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Boost' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Complete' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-complete.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Creator' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-creator.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Crm' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Extras' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Growth' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-growth.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Jetpack_Ai' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-jetpack-ai.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Newsletter' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-newsletter.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Protect' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Related_Posts' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-related-posts.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Scan' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search_Stats' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search-stats.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Security' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Site_Accelerator' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-site-accelerator.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Social' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Starter' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-starter.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Stats' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-stats.php', - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Videopress' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_AI' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-ai.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Products' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Purchases' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Recommendations_Evaluation' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-recommendations-evaluation.php', - 'Automattic\\Jetpack\\My_Jetpack\\REST_Zendesk_Chat' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-zendesk-chat.php', - 'Automattic\\Jetpack\\My_Jetpack\\Red_Bubble_Notifications' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-red-bubble-notifications.php', - 'Automattic\\Jetpack\\My_Jetpack\\Wpcom_Products' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php', - 'Automattic\\Jetpack\\Partner' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-partner.php', - 'Automattic\\Jetpack\\Partner_Coupon' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-partner-coupon.php', - 'Automattic\\Jetpack\\Password_Checker' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php', - 'Automattic\\Jetpack\\Paths' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-paths.php', - 'Automattic\\Jetpack\\Plans' => __DIR__ . '/..' . '/automattic/jetpack-plans/src/class-plans.php', - 'Automattic\\Jetpack\\Plugins_Installer' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php', - 'Automattic\\Jetpack\\Protect\\Credentials' => __DIR__ . '/../..' . '/src/class-credentials.php', - 'Automattic\\Jetpack\\Protect\\Onboarding' => __DIR__ . '/../..' . '/src/class-onboarding.php', - 'Automattic\\Jetpack\\Protect\\REST_Controller' => __DIR__ . '/../..' . '/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Protect\\Scan_History' => __DIR__ . '/../..' . '/src/class-scan-history.php', - 'Automattic\\Jetpack\\Protect\\Site_Health' => __DIR__ . '/../..' . '/src/class-site-health.php', - 'Automattic\\Jetpack\\Protect\\Threats' => __DIR__ . '/../..' . '/src/class-threats.php', - 'Automattic\\Jetpack\\Protect_Models' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-protect-models.php', - 'Automattic\\Jetpack\\Protect_Models\\Extension_Model' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-extension-model.php', - 'Automattic\\Jetpack\\Protect_Models\\History_Model' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-history-model.php', - 'Automattic\\Jetpack\\Protect_Models\\Status_Model' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-status-model.php', - 'Automattic\\Jetpack\\Protect_Models\\Threat_Model' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-threat-model.php', - 'Automattic\\Jetpack\\Protect_Models\\Vulnerability_Model' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-vulnerability-model.php', - 'Automattic\\Jetpack\\Protect_Status\\Plan' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-plan.php', - 'Automattic\\Jetpack\\Protect_Status\\Protect_Status' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-protect-status.php', - 'Automattic\\Jetpack\\Protect_Status\\REST_Controller' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Protect_Status\\Scan_Status' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-scan-status.php', - 'Automattic\\Jetpack\\Protect_Status\\Status' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-status.php', - 'Automattic\\Jetpack\\Redirect' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php', - 'Automattic\\Jetpack\\Roles' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php', - 'Automattic\\Jetpack\\Status' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-status.php', - 'Automattic\\Jetpack\\Status\\Cache' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-cache.php', - 'Automattic\\Jetpack\\Status\\Host' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-host.php', - 'Automattic\\Jetpack\\Status\\Visitor' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php', - 'Automattic\\Jetpack\\Sync\\Actions' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php', - 'Automattic\\Jetpack\\Sync\\Codec_Interface' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php', - 'Automattic\\Jetpack\\Sync\\Data_Settings' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php', - 'Automattic\\Jetpack\\Sync\\Dedicated_Sender' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php', - 'Automattic\\Jetpack\\Sync\\Default_Filter_Settings' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php', - 'Automattic\\Jetpack\\Sync\\Defaults' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php', - 'Automattic\\Jetpack\\Sync\\Functions' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php', - 'Automattic\\Jetpack\\Sync\\Health' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-health.php', - 'Automattic\\Jetpack\\Sync\\JSON_Deflate_Array_Codec' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php', - 'Automattic\\Jetpack\\Sync\\Listener' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php', - 'Automattic\\Jetpack\\Sync\\Lock' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php', - 'Automattic\\Jetpack\\Sync\\Main' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-main.php', - 'Automattic\\Jetpack\\Sync\\Modules' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Attachments' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-attachments.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Callables' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Comments' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Constants' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync_Immediately' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Import' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Menus' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Meta' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Module' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Network_Options' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Options' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Plugins' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Posts' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Protect' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Search' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Stats' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Term_Relationships' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-term-relationships.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Terms' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Themes' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Updates' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php', - 'Automattic\\Jetpack\\Sync\\Modules\\Users' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php', - 'Automattic\\Jetpack\\Sync\\Modules\\WP_Super_Cache' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php', - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php', - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce_HPOS_Orders' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce-hpos-orders.php', - 'Automattic\\Jetpack\\Sync\\Package_Version' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php', - 'Automattic\\Jetpack\\Sync\\Queue' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php', - 'Automattic\\Jetpack\\Sync\\Queue\\Queue_Storage_Options' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-options.php', - 'Automattic\\Jetpack\\Sync\\Queue\\Queue_Storage_Table' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-table.php', - 'Automattic\\Jetpack\\Sync\\Queue_Buffer' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue-buffer.php', - 'Automattic\\Jetpack\\Sync\\REST_Endpoints' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php', - 'Automattic\\Jetpack\\Sync\\REST_Sender' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php', - 'Automattic\\Jetpack\\Sync\\Replicastore' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php', - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php', - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Usermeta' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php', - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Users' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php', - 'Automattic\\Jetpack\\Sync\\Replicastore_Interface' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/interface-replicastore.php', - 'Automattic\\Jetpack\\Sync\\Sender' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php', - 'Automattic\\Jetpack\\Sync\\Server' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-server.php', - 'Automattic\\Jetpack\\Sync\\Settings' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php', - 'Automattic\\Jetpack\\Sync\\Simple_Codec' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php', - 'Automattic\\Jetpack\\Sync\\Users' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-users.php', - 'Automattic\\Jetpack\\Sync\\Utils' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php', - 'Automattic\\Jetpack\\Terms_Of_Service' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php', - 'Automattic\\Jetpack\\Tracking' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php', - 'Automattic\\Jetpack\\Transport_Helper\\Package_Version' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php', - 'Automattic\\Jetpack\\Transport_Helper\\V0001\\Package_Version' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version-compat.php', - 'Automattic\\Jetpack\\Transport_Helper\\V0005\\REST_Controller' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Blocked_Login_Page' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-blocked-login-page.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Math_Authenticate' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-math-fallback.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Shared_Functions' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-shared-functions.php', - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Transient_Cleanup' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php', - 'Automattic\\Jetpack\\Waf\\CLI' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php', - 'Automattic\\Jetpack\\Waf\\File_System_Exception' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php', - 'Automattic\\Jetpack\\Waf\\REST_Controller' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php', - 'Automattic\\Jetpack\\Waf\\Rules_API_Exception' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-rules-api-exception.php', - 'Automattic\\Jetpack\\Waf\\Waf_Blocklog_Manager' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-blocklog-manager.php', - 'Automattic\\Jetpack\\Waf\\Waf_Compatibility' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php', - 'Automattic\\Jetpack\\Waf\\Waf_Constants' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php', - 'Automattic\\Jetpack\\Waf\\Waf_Exception' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-waf-exception.php', - 'Automattic\\Jetpack\\Waf\\Waf_Initializer' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php', - 'Automattic\\Jetpack\\Waf\\Waf_Operators' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php', - 'Automattic\\Jetpack\\Waf\\Waf_Request' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php', - 'Automattic\\Jetpack\\Waf\\Waf_Rules_Manager' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php', - 'Automattic\\Jetpack\\Waf\\Waf_Runner' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runner.php', - 'Automattic\\Jetpack\\Waf\\Waf_Runtime' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runtime.php', - 'Automattic\\Jetpack\\Waf\\Waf_Standalone_Bootstrap' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php', - 'Automattic\\Jetpack\\Waf\\Waf_Stats' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php', - 'Automattic\\Jetpack\\Waf\\Waf_Transforms' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php', - 'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php', - 'Jetpack_IXR_Client' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-client.php', - 'Jetpack_IXR_ClientMulticall' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-clientmulticall.php', - 'Jetpack_Options' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-options.php', - 'Jetpack_Protect' => __DIR__ . '/../..' . '/src/class-jetpack-protect.php', - 'Jetpack_Signature' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-signature.php', - 'Jetpack_Tracks_Client' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-client.php', - 'Jetpack_Tracks_Event' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-event.php', - 'Jetpack_XMLRPC_Server' => __DIR__ . '/../..' . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-xmlrpc-server.php', - ); - - public static function getInitializer(ClassLoader $loader) - { - return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ4_0_0::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ4_0_0::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInitc4802e05bbcf59fd3b6350e8d3e5482c_protectⓥ4_0_0::$classMap; - - }, null, ClassLoader::class); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.json b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.json deleted file mode 100644 index 5ce5d674..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.json +++ /dev/null @@ -1,1852 +0,0 @@ -{ - "packages": [ - { - "name": "automattic/jetpack-a8c-mc-stats", - "version": "v3.0.4", - "version_normalized": "3.0.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-a8c-mc-stats.git", - "reference": "b1f7e2b9032ad203b6bd4cad1519613cc56f8ed0" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-a8c-mc-stats/zipball/b1f7e2b9032ad203b6bd4cad1519613cc56f8ed0", - "reference": "b1f7e2b9032ad203b6bd4cad1519613cc56f8ed0", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:28+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-a8c-mc-stats", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-a8c-mc-stats/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Used to record internal usage stats for Automattic. Not visible to site owners.", - "support": { - "source": "https://github.com/Automattic/jetpack-a8c-mc-stats/tree/v3.0.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-a8c-mc-stats" - }, - { - "name": "automattic/jetpack-admin-ui", - "version": "v0.5.7", - "version_normalized": "0.5.7.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-admin-ui.git", - "reference": "c82d2417a8aa65e646c40a81011ad76f355a742f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-admin-ui/zipball/c82d2417a8aa65e646c40a81011ad76f355a742f", - "reference": "c82d2417a8aa65e646c40a81011ad76f355a742f", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-logo": "^3.0.4", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:52+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-admin-ui", - "mirror-repo": "Automattic/jetpack-admin-ui", - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-admin-ui/compare/${old}...${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-admin-menu.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Generic Jetpack wp-admin UI elements", - "support": { - "source": "https://github.com/Automattic/jetpack-admin-ui/tree/v0.5.7" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-admin-ui" - }, - { - "name": "automattic/jetpack-assets", - "version": "v4.0.14", - "version_normalized": "4.0.14.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-assets.git", - "reference": "2219c71f19c34ea9a393e48498188f1aa9f9031b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-assets/zipball/2219c71f19c34ea9a393e48498188f1aa9f9031b", - "reference": "2219c71f19c34ea9a393e48498188f1aa9f9031b", - "shasum": "" - }, - "require": { - "automattic/jetpack-constants": "^3.0.5", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "wikimedia/testing-access-wrapper": "^1.0 || ^2.0 || ^3.0", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:27+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-assets", - "mirror-repo": "Automattic/jetpack-assets", - "branch-alias": { - "dev-trunk": "4.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-assets/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Asset management utilities for Jetpack ecosystem packages", - "support": { - "source": "https://github.com/Automattic/jetpack-assets/tree/v4.0.14" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-assets" - }, - { - "name": "automattic/jetpack-autoloader", - "version": "v5.0.5", - "version_normalized": "5.0.5.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-autoloader.git", - "reference": "7bf3172e73c27c72d01d6de4796a41c7abc06d5a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-autoloader/zipball/7bf3172e73c27c72d01d6de4796a41c7abc06d5a", - "reference": "7bf3172e73c27c72d01d6de4796a41c7abc06d5a", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^2.2", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "composer/composer": "^2.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "time": "2025-03-21T09:05:50+00:00", - "type": "composer-plugin", - "extra": { - "class": "Automattic\\Jetpack\\Autoloader\\CustomAutoloaderPlugin", - "autotagger": true, - "mirror-repo": "Automattic/jetpack-autoloader", - "branch-alias": { - "dev-trunk": "5.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-autoloader/compare/v${old}...v${new}" - }, - "version-constants": { - "::VERSION": "src/AutoloadGenerator.php" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "Automattic\\Jetpack\\Autoloader\\": "src" - }, - "classmap": [ - "src/AutoloadGenerator.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Creates a custom autoloader for a plugin or theme.", - "keywords": [ - "autoload", - "autoloader", - "composer", - "jetpack", - "plugin", - "wordpress" - ], - "support": { - "source": "https://github.com/Automattic/jetpack-autoloader/tree/v5.0.5" - }, - "install-path": "../automattic/jetpack-autoloader" - }, - { - "name": "automattic/jetpack-backup-helper-script-manager", - "version": "v0.3.6", - "version_normalized": "0.3.6.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-backup-helper-script-manager.git", - "reference": "859d8df5637c61f9c29b46e038f425bd238eb6f4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-backup-helper-script-manager/zipball/859d8df5637c61f9c29b46e038f425bd238eb6f4", - "reference": "859d8df5637c61f9c29b46e038f425bd238eb6f4", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-24T14:40:39+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-backup-helper-script-manager", - "branch-alias": { - "dev-trunk": "0.3.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-backup-helper-script-manager/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Install / delete helper script for backup and transport server. Not visible to site owners.", - "support": { - "source": "https://github.com/Automattic/jetpack-backup-helper-script-manager/tree/v0.3.6" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-backup-helper-script-manager" - }, - { - "name": "automattic/jetpack-boost-core", - "version": "v0.3.9", - "version_normalized": "0.3.9.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-boost-core.git", - "reference": "83c2081731fe46fc43d938abf1f0818a67c0e61e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-boost-core/zipball/83c2081731fe46fc43d938abf1f0818a67c0e61e", - "reference": "83c2081731fe46fc43d938abf1f0818a67c0e61e", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.7.7", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:48+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-boost-core", - "mirror-repo": "Automattic/jetpack-boost-core", - "branch-alias": { - "dev-trunk": "0.3.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-boost-core/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Core functionality for boost and relevant packages to depend on", - "support": { - "source": "https://github.com/Automattic/jetpack-boost-core/tree/v0.3.9" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-boost-core" - }, - { - "name": "automattic/jetpack-boost-speed-score", - "version": "v0.4.6", - "version_normalized": "0.4.6.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-boost-speed-score.git", - "reference": "42d2a24559b5a007096d3a500be058fd92ab1f19" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-boost-speed-score/zipball/42d2a24559b5a007096d3a500be058fd92ab1f19", - "reference": "42d2a24559b5a007096d3a500be058fd92ab1f19", - "shasum": "" - }, - "require": { - "automattic/jetpack-boost-core": "^0.3.9", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:49+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-boost-speed-score", - "mirror-repo": "Automattic/jetpack-boost-speed-score", - "branch-alias": { - "dev-trunk": "0.4.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-boost-speed-score/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-speed-score.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "A package that handles the API to generate the speed score.", - "support": { - "source": "https://github.com/Automattic/jetpack-boost-speed-score/tree/v0.4.6" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-boost-speed-score" - }, - { - "name": "automattic/jetpack-composer-plugin", - "version": "v4.0.4", - "version_normalized": "4.0.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-composer-plugin.git", - "reference": "0c32be22d4e2ff6468ed688780d14bcd70e260da" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-composer-plugin/zipball/0c32be22d4e2ff6468ed688780d14bcd70e260da", - "reference": "0c32be22d4e2ff6468ed688780d14bcd70e260da", - "shasum": "" - }, - "require": { - "composer-plugin-api": "^2.2", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "composer/composer": "^2.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "time": "2025-03-21T09:05:32+00:00", - "type": "composer-plugin", - "extra": { - "class": "Automattic\\Jetpack\\Composer\\Plugin", - "autotagger": true, - "mirror-repo": "Automattic/jetpack-composer-plugin", - "branch-alias": { - "dev-trunk": "4.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-composer-plugin/compare/v${old}...v${new}" - }, - "plugin-modifies-install-path": true - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "A custom installer plugin for Composer to move Jetpack packages out of `vendor/` so WordPress's translation infrastructure will find their strings.", - "keywords": [ - "composer", - "i18n", - "jetpack", - "plugin" - ], - "support": { - "source": "https://github.com/Automattic/jetpack-composer-plugin/tree/v4.0.4" - }, - "install-path": "../automattic/jetpack-composer-plugin" - }, - { - "name": "automattic/jetpack-config", - "version": "v3.0.1", - "version_normalized": "3.0.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-config.git", - "reference": "13f26ed2830d9043d351e49c5ab4e2b6ec21e9d2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-config/zipball/13f26ed2830d9043d351e49c5ab4e2b6ec21e9d2", - "reference": "13f26ed2830d9043d351e49c5ab4e2b6ec21e9d2", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.0", - "automattic/jetpack-connection": "@dev", - "automattic/jetpack-import": "@dev", - "automattic/jetpack-jitm": "@dev", - "automattic/jetpack-post-list": "@dev", - "automattic/jetpack-publicize": "@dev", - "automattic/jetpack-search": "@dev", - "automattic/jetpack-stats": "@dev", - "automattic/jetpack-stats-admin": "@dev", - "automattic/jetpack-sync": "@dev", - "automattic/jetpack-videopress": "@dev", - "automattic/jetpack-waf": "@dev", - "automattic/jetpack-wordads": "@dev", - "automattic/jetpack-yoast-promo": "@dev" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-02-24T17:05:29+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-config", - "mirror-repo": "Automattic/jetpack-config", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-config/compare/v${old}...v${new}" - }, - "dependencies": { - "test-only": [ - "packages/connection", - "packages/import", - "packages/jitm", - "packages/post-list", - "packages/publicize", - "packages/search", - "packages/stats", - "packages/stats-admin", - "packages/sync", - "packages/videopress", - "packages/waf", - "packages/wordads", - "packages/yoast-promo" - ] - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Jetpack configuration package that initializes other packages and configures Jetpack's functionality. Can be used as a base for all variants of Jetpack package usage.", - "support": { - "source": "https://github.com/Automattic/jetpack-config/tree/v3.0.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-config" - }, - { - "name": "automattic/jetpack-connection", - "version": "v6.8.1", - "version_normalized": "6.8.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-connection.git", - "reference": "473c52b3ad8ea7b51066a243d2b1d87ba8835fca" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-connection/zipball/473c52b3ad8ea7b51066a243d2b1d87ba8835fca", - "reference": "473c52b3ad8ea7b51066a243d2b1d87ba8835fca", - "shasum": "" - }, - "require": { - "automattic/jetpack-a8c-mc-stats": "^3.0.4", - "automattic/jetpack-admin-ui": "^0.5.7", - "automattic/jetpack-assets": "^4.0.14", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-redirect": "^3.0.5", - "automattic/jetpack-roles": "^3.0.5", - "automattic/jetpack-status": "^5.0.10", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-24T17:30:51+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-connection", - "mirror-repo": "Automattic/jetpack-connection", - "branch-alias": { - "dev-trunk": "6.8.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-connection/compare/v${old}...v${new}" - }, - "dependencies": { - "test-only": [ - "packages/licensing", - "packages/sync" - ] - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-package-version.php" - } - }, - "installation-source": "dist", - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "legacy", - "src/", - "src/webhooks", - "src/identity-crisis" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Everything needed to connect to the Jetpack infrastructure", - "support": { - "source": "https://github.com/Automattic/jetpack-connection/tree/v6.8.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-connection" - }, - { - "name": "automattic/jetpack-constants", - "version": "v3.0.5", - "version_normalized": "3.0.5.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-constants.git", - "reference": "12446dd21985e3765d8b8b903091c273d22e4e9e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-constants/zipball/12446dd21985e3765d8b8b903091c273d22e4e9e", - "reference": "12446dd21985e3765d8b8b903091c273d22e4e9e", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:24+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-constants", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-constants/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "A wrapper for defining constants in a more testable way.", - "support": { - "source": "https://github.com/Automattic/jetpack-constants/tree/v3.0.5" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-constants" - }, - { - "name": "automattic/jetpack-device-detection", - "version": "v3.0.5", - "version_normalized": "3.0.5.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-device-detection.git", - "reference": "dd237dd9b92532aba103b71bf43a2a3c87117a7f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-device-detection/zipball/dd237dd9b92532aba103b71bf43a2a3c87117a7f", - "reference": "dd237dd9b92532aba103b71bf43a2a3c87117a7f", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:34+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-device-detection", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-device-detection/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "A way to detect device types based on User-Agent header.", - "support": { - "source": "https://github.com/Automattic/jetpack-device-detection/tree/v3.0.5" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-device-detection" - }, - { - "name": "automattic/jetpack-explat", - "version": "v0.2.13", - "version_normalized": "0.2.13.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-explat.git", - "reference": "ba4a9fa045deb9c6bf58a394521dbf6458b34d30" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-explat/zipball/ba4a9fa045deb9c6bf58a394521dbf6458b34d30", - "reference": "ba4a9fa045deb9c6bf58a394521dbf6458b34d30", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.7.7", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:59+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-explat", - "mirror-repo": "Automattic/jetpack-explat", - "branch-alias": { - "dev-trunk": "0.2.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-explat/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-explat.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "A package for running A/B tests on the Experimentation Platform (ExPlat) in the plugin.", - "support": { - "source": "https://github.com/Automattic/jetpack-explat/tree/v0.2.13" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-explat" - }, - { - "name": "automattic/jetpack-ip", - "version": "v0.4.6", - "version_normalized": "0.4.6.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-ip.git", - "reference": "0248018c22240817a2a463fd0e1aa05f55091c6c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-ip/zipball/0248018c22240817a2a463fd0e1aa05f55091c6c", - "reference": "0248018c22240817a2a463fd0e1aa05f55091c6c", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:27+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-ip", - "mirror-repo": "Automattic/jetpack-ip", - "branch-alias": { - "dev-trunk": "0.4.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/automattic/jetpack-ip/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-utils.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Utilities for working with IP addresses.", - "support": { - "source": "https://github.com/Automattic/jetpack-ip/tree/v0.4.6" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-ip" - }, - { - "name": "automattic/jetpack-jitm", - "version": "v4.2.7", - "version_normalized": "4.2.7.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-jitm.git", - "reference": "8ee55bdf627a004ee736921e34160545a917ab44" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-jitm/zipball/8ee55bdf627a004ee736921e34160545a917ab44", - "reference": "8ee55bdf627a004ee736921e34160545a917ab44", - "shasum": "" - }, - "require": { - "automattic/jetpack-a8c-mc-stats": "^3.0.4", - "automattic/jetpack-assets": "^4.0.14", - "automattic/jetpack-connection": "^6.8.0", - "automattic/jetpack-device-detection": "^3.0.5", - "automattic/jetpack-logo": "^3.0.4", - "automattic/jetpack-redirect": "^3.0.5", - "automattic/jetpack-status": "^5.0.10", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-24T14:41:35+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-jitm", - "mirror-repo": "Automattic/jetpack-jitm", - "branch-alias": { - "dev-trunk": "4.2.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-jitm/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-jitm.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Just in time messages for Jetpack", - "support": { - "source": "https://github.com/Automattic/jetpack-jitm/tree/v4.2.7" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-jitm" - }, - { - "name": "automattic/jetpack-licensing", - "version": "v3.0.8", - "version_normalized": "3.0.8.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-licensing.git", - "reference": "85e45bf51f729c76535a026edf806e5e800ca409" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-licensing/zipball/85e45bf51f729c76535a026edf806e5e800ca409", - "reference": "85e45bf51f729c76535a026edf806e5e800ca409", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.7.7", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:45+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-licensing", - "mirror-repo": "Automattic/jetpack-licensing", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-licensing/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Everything needed to manage Jetpack licenses client-side.", - "support": { - "source": "https://github.com/Automattic/jetpack-licensing/tree/v3.0.8" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-licensing" - }, - { - "name": "automattic/jetpack-logo", - "version": "v3.0.4", - "version_normalized": "3.0.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-logo.git", - "reference": "e13c7917f1bfeb014c923d6763db2ee1d60eb1aa" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-logo/zipball/e13c7917f1bfeb014c923d6763db2ee1d60eb1aa", - "reference": "e13c7917f1bfeb014c923d6763db2ee1d60eb1aa", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:31+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-logo", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-logo/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "A logo for Jetpack", - "support": { - "source": "https://github.com/Automattic/jetpack-logo/tree/v3.0.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-logo" - }, - { - "name": "automattic/jetpack-my-jetpack", - "version": "v5.9.1", - "version_normalized": "5.9.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-my-jetpack.git", - "reference": "c75f826f5900506be1b28120946c1b319e23dac6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-my-jetpack/zipball/c75f826f5900506be1b28120946c1b319e23dac6", - "reference": "c75f826f5900506be1b28120946c1b319e23dac6", - "shasum": "" - }, - "require": { - "automattic/jetpack-admin-ui": "^0.5.7", - "automattic/jetpack-assets": "^4.0.14", - "automattic/jetpack-boost-speed-score": "^0.4.6", - "automattic/jetpack-connection": "^6.8.1", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-explat": "^0.2.13", - "automattic/jetpack-jitm": "^4.2.7", - "automattic/jetpack-licensing": "^3.0.8", - "automattic/jetpack-plans": "^0.6.1", - "automattic/jetpack-plugins-installer": "^0.5.4", - "automattic/jetpack-protect-status": "^0.5.8", - "automattic/jetpack-redirect": "^3.0.5", - "automattic/jetpack-status": "^5.0.10", - "automattic/jetpack-sync": "^4.9.2", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-24T17:31:35+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-my-jetpack", - "mirror-repo": "Automattic/jetpack-my-jetpack", - "branch-alias": { - "dev-trunk": "5.9.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-my-jetpack/compare/${old}...${new}" - }, - "dependencies": { - "test-only": [ - "packages/search", - "packages/videopress" - ] - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-initializer.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/", - "src/products" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "WP Admin page with information and configuration shared among all Jetpack stand-alone plugins", - "support": { - "source": "https://github.com/Automattic/jetpack-my-jetpack/tree/v5.9.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-my-jetpack" - }, - { - "name": "automattic/jetpack-password-checker", - "version": "v0.4.7", - "version_normalized": "0.4.7.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-password-checker.git", - "reference": "25900f1b5bf8718915c607a4fc1d1e0bc290e20a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-password-checker/zipball/25900f1b5bf8718915c607a4fc1d1e0bc290e20a", - "reference": "25900f1b5bf8718915c607a4fc1d1e0bc290e20a", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:35+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-password-checker", - "mirror-repo": "Automattic/jetpack-password-checker", - "branch-alias": { - "dev-trunk": "0.4.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-password-checker/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Password Checker.", - "support": { - "source": "https://github.com/Automattic/jetpack-password-checker/tree/v0.4.7" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-password-checker" - }, - { - "name": "automattic/jetpack-plans", - "version": "v0.6.1", - "version_normalized": "0.6.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-plans.git", - "reference": "66a8169d4a22af983aa6c11c57bc385d7c5747cc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-plans/zipball/66a8169d4a22af983aa6c11c57bc385d7c5747cc", - "reference": "66a8169d4a22af983aa6c11c57bc385d7c5747cc", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.7.7", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-status": "^5.0.10", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:46+00:00", - "type": "library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-plans", - "branch-alias": { - "dev-trunk": "0.6.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-plans/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Fetch information about Jetpack Plans from wpcom", - "support": { - "source": "https://github.com/Automattic/jetpack-plans/tree/v0.6.1" - }, - "install-path": "../automattic/jetpack-plans" - }, - { - "name": "automattic/jetpack-plugins-installer", - "version": "v0.5.4", - "version_normalized": "0.5.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-plugins-installer.git", - "reference": "2fbd9cf402e0514f680b8bef9f787633f2bb29ed" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-plugins-installer/zipball/2fbd9cf402e0514f680b8bef9f787633f2bb29ed", - "reference": "2fbd9cf402e0514f680b8bef9f787633f2bb29ed", - "shasum": "" - }, - "require": { - "automattic/jetpack-a8c-mc-stats": "^3.0.4", - "automattic/jetpack-status": "^5.0.10", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:59+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-plugins-installer", - "mirror-repo": "Automattic/jetpack-plugins-installer", - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-plugins-installer/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Handle installation of plugins from WP.org", - "support": { - "source": "https://github.com/Automattic/jetpack-plugins-installer/tree/v0.5.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-plugins-installer" - }, - { - "name": "automattic/jetpack-protect-models", - "version": "v0.5.4", - "version_normalized": "0.5.4.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-protect-models.git", - "reference": "99180919a0756cfd3272388eebc99c5795894b18" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-protect-models/zipball/99180919a0756cfd3272388eebc99c5795894b18", - "reference": "99180919a0756cfd3272388eebc99c5795894b18", - "shasum": "" - }, - "require": { - "automattic/jetpack-redirect": "^3.0.5", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:01+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-protect-models", - "mirror-repo": "Automattic/jetpack-protect-models", - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-protect-models/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-protect-models.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "This package contains the models used in Protect. ", - "support": { - "source": "https://github.com/Automattic/jetpack-protect-models/tree/v0.5.4" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-protect-models" - }, - { - "name": "automattic/jetpack-protect-status", - "version": "v0.5.8", - "version_normalized": "0.5.8.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-protect-status.git", - "reference": "34cd7a21d211ec00709660486b6ee9e0928593a6" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-protect-status/zipball/34cd7a21d211ec00709660486b6ee9e0928593a6", - "reference": "34cd7a21d211ec00709660486b6ee9e0928593a6", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.7.7", - "automattic/jetpack-plans": "^0.6.1", - "automattic/jetpack-plugins-installer": "^0.5.4", - "automattic/jetpack-protect-models": "^0.5.4", - "automattic/jetpack-sync": "^4.9.2", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:51+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-protect-status", - "mirror-repo": "Automattic/jetpack-protect-status", - "branch-alias": { - "dev-trunk": "0.5.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-protect-status/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-status.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "This package contains the Protect Status API functionality to retrieve a site's scan status (WordPress, Themes, and Plugins threats).", - "support": { - "source": "https://github.com/Automattic/jetpack-protect-status/tree/v0.5.8" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-protect-status" - }, - { - "name": "automattic/jetpack-redirect", - "version": "v3.0.5", - "version_normalized": "3.0.5.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-redirect.git", - "reference": "806c695a0fb82bb9e96a6e406df27724f5821180" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-redirect/zipball/806c695a0fb82bb9e96a6e406df27724f5821180", - "reference": "806c695a0fb82bb9e96a6e406df27724f5821180", - "shasum": "" - }, - "require": { - "automattic/jetpack-status": "^5.0.10", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:58+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-redirect", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-redirect/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Utilities to build URLs to the jetpack.com/redirect/ service", - "support": { - "source": "https://github.com/Automattic/jetpack-redirect/tree/v3.0.5" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-redirect" - }, - { - "name": "automattic/jetpack-roles", - "version": "v3.0.5", - "version_normalized": "3.0.5.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-roles.git", - "reference": "22e0b19517221fca3113c3ed823a3e8e22cd5762" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-roles/zipball/22e0b19517221fca3113c3ed823a3e8e22cd5762", - "reference": "22e0b19517221fca3113c3ed823a3e8e22cd5762", - "shasum": "" - }, - "require": { - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:30+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-roles", - "branch-alias": { - "dev-trunk": "3.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-roles/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Utilities, related with user roles and capabilities.", - "support": { - "source": "https://github.com/Automattic/jetpack-roles/tree/v3.0.5" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-roles" - }, - { - "name": "automattic/jetpack-status", - "version": "v5.0.10", - "version_normalized": "5.0.10.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-status.git", - "reference": "239152e50e7f5492b78bceff51ec4d1ca7a1b427" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-status/zipball/239152e50e7f5492b78bceff51ec4d1ca7a1b427", - "reference": "239152e50e7f5492b78bceff51ec4d1ca7a1b427", - "shasum": "" - }, - "require": { - "automattic/jetpack-constants": "^3.0.5", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-connection": "@dev", - "automattic/jetpack-ip": "^0.4.6", - "automattic/jetpack-plans": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "brain/monkey": "^2.6.2", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:05:54+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "mirror-repo": "Automattic/jetpack-status", - "branch-alias": { - "dev-trunk": "5.0.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-status/compare/v${old}...v${new}" - }, - "dependencies": { - "test-only": [ - "packages/connection", - "packages/plans" - ] - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Used to retrieve information about the current status of Jetpack and the site overall.", - "support": { - "source": "https://github.com/Automattic/jetpack-status/tree/v5.0.10" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-status" - }, - { - "name": "automattic/jetpack-sync", - "version": "v4.9.2", - "version_normalized": "4.9.2.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-sync.git", - "reference": "d24cf1d05b5f700e4d92f2275dd7d414d2191e32" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-sync/zipball/d24cf1d05b5f700e4d92f2275dd7d414d2191e32", - "reference": "d24cf1d05b5f700e4d92f2275dd7d414d2191e32", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.7.7", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-ip": "^0.4.6", - "automattic/jetpack-password-checker": "^0.4.7", - "automattic/jetpack-roles": "^3.0.5", - "automattic/jetpack-status": "^5.0.10", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-search": "@dev", - "automattic/jetpack-test-environment": "@dev", - "automattic/jetpack-waf": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-21T09:06:50+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-sync", - "mirror-repo": "Automattic/jetpack-sync", - "branch-alias": { - "dev-trunk": "4.9.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-sync/compare/v${old}...v${new}" - }, - "dependencies": { - "test-only": [ - "packages/search", - "packages/waf" - ] - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-package-version.php" - } - }, - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Everything needed to allow syncing to the WP.com infrastructure.", - "support": { - "source": "https://github.com/Automattic/jetpack-sync/tree/v4.9.2" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-sync" - }, - { - "name": "automattic/jetpack-transport-helper", - "version": "v0.3.1", - "version_normalized": "0.3.1.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-transport-helper.git", - "reference": "6c7cf972ff16b3d229e96781f9c9106f94677afe" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-transport-helper/zipball/6c7cf972ff16b3d229e96781f9c9106f94677afe", - "reference": "6c7cf972ff16b3d229e96781f9c9106f94677afe", - "shasum": "" - }, - "require": { - "automattic/jetpack-backup-helper-script-manager": "^0.3.6", - "automattic/jetpack-connection": "^6.8.1", - "php": ">=7.2" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-24T17:30:58+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-transport-helper", - "mirror-repo": "Automattic/jetpack-transport-helper", - "branch-alias": { - "dev-trunk": "0.3.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-transport-helper/compare/v${old}...v${new}" - }, - "version-constants": { - "::PACKAGE_VERSION": "src/class-package-version.php" - } - }, - "installation-source": "dist", - "autoload": { - "files": [ - "actions.php" - ], - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Package to help transport server communication", - "support": { - "source": "https://github.com/Automattic/jetpack-transport-helper/tree/v0.3.1" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-transport-helper" - }, - { - "name": "automattic/jetpack-waf", - "version": "v0.23.8", - "version_normalized": "0.23.8.0", - "source": { - "type": "git", - "url": "https://github.com/Automattic/jetpack-waf.git", - "reference": "9cfafab1c0e0986b5bd8970c013f780208e4a84f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/Automattic/jetpack-waf/zipball/9cfafab1c0e0986b5bd8970c013f780208e4a84f", - "reference": "9cfafab1c0e0986b5bd8970c013f780208e4a84f", - "shasum": "" - }, - "require": { - "automattic/jetpack-connection": "^6.8.0", - "automattic/jetpack-constants": "^3.0.5", - "automattic/jetpack-ip": "^0.4.6", - "automattic/jetpack-status": "^5.0.10", - "php": ">=7.2", - "wikimedia/aho-corasick": "^1.0" - }, - "require-dev": { - "automattic/jetpack-changelogger": "^6.0.2", - "automattic/jetpack-test-environment": "@dev", - "automattic/phpunit-select-config": "^1.0.1", - "yoast/phpunit-polyfills": "^3.0.0" - }, - "suggest": { - "automattic/jetpack-autoloader": "Allow for better interoperability with other plugins that use this package." - }, - "time": "2025-03-24T14:41:22+00:00", - "type": "jetpack-library", - "extra": { - "autotagger": true, - "textdomain": "jetpack-waf", - "mirror-repo": "Automattic/jetpack-waf", - "branch-alias": { - "dev-trunk": "0.23.x-dev" - }, - "changelogger": { - "link-template": "https://github.com/Automattic/jetpack-waf/compare/v${old}...v${new}" - } - }, - "installation-source": "dist", - "autoload": { - "files": [ - "cli.php" - ], - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0-or-later" - ], - "description": "Tools to assist with the Jetpack Web Application Firewall", - "support": { - "source": "https://github.com/Automattic/jetpack-waf/tree/v0.23.8" - }, - "install-path": "../../jetpack_vendor/automattic/jetpack-waf" - }, - { - "name": "wikimedia/aho-corasick", - "version": "v1.0.1", - "version_normalized": "1.0.1.0", - "source": { - "type": "git", - "url": "https://github.com/wikimedia/AhoCorasick.git", - "reference": "2f3a1bd765913637a66eade658d11d82f0e551be" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/wikimedia/AhoCorasick/zipball/2f3a1bd765913637a66eade658d11d82f0e551be", - "reference": "2f3a1bd765913637a66eade658d11d82f0e551be", - "shasum": "" - }, - "require": { - "php": ">=5.5.9" - }, - "require-dev": { - "jakub-onderka/php-console-highlighter": "0.3.2", - "jakub-onderka/php-parallel-lint": "1.0.0", - "mediawiki/mediawiki-codesniffer": "18.0.0", - "mediawiki/minus-x": "0.3.1", - "phpunit/phpunit": "4.8.36 || ^6.5" - }, - "time": "2018-05-01T18:13:32+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "classmap": [ - "src/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "Apache-2.0" - ], - "authors": [ - { - "name": "Ori Livneh", - "email": "ori@wikimedia.org" - } - ], - "description": "An implementation of the Aho-Corasick string matching algorithm.", - "homepage": "https://gerrit.wikimedia.org/g/AhoCorasick", - "keywords": [ - "ahocorasick", - "matcher" - ], - "support": { - "source": "https://github.com/wikimedia/AhoCorasick/tree/v1.0.1" - }, - "install-path": "../wikimedia/aho-corasick" - } - ], - "dev": false, - "dev-package-names": [] -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.php deleted file mode 100644 index 5ce16f0f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/installed.php +++ /dev/null @@ -1,293 +0,0 @@ - array( - 'name' => 'automattic/jetpack-protect', - 'pretty_version' => 'dev-trunk', - 'version' => 'dev-trunk', - 'reference' => null, - 'type' => 'wordpress-plugin', - 'install_path' => __DIR__ . '/../../', - 'aliases' => array(), - 'dev' => false, - ), - 'versions' => array( - 'automattic/jetpack-a8c-mc-stats' => array( - 'pretty_version' => 'v3.0.4', - 'version' => '3.0.4.0', - 'reference' => 'b1f7e2b9032ad203b6bd4cad1519613cc56f8ed0', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-a8c-mc-stats', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-admin-ui' => array( - 'pretty_version' => 'v0.5.7', - 'version' => '0.5.7.0', - 'reference' => 'c82d2417a8aa65e646c40a81011ad76f355a742f', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-admin-ui', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-assets' => array( - 'pretty_version' => 'v4.0.14', - 'version' => '4.0.14.0', - 'reference' => '2219c71f19c34ea9a393e48498188f1aa9f9031b', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-assets', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-autoloader' => array( - 'pretty_version' => 'v5.0.5', - 'version' => '5.0.5.0', - 'reference' => '7bf3172e73c27c72d01d6de4796a41c7abc06d5a', - 'type' => 'composer-plugin', - 'install_path' => __DIR__ . '/../automattic/jetpack-autoloader', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-backup-helper-script-manager' => array( - 'pretty_version' => 'v0.3.6', - 'version' => '0.3.6.0', - 'reference' => '859d8df5637c61f9c29b46e038f425bd238eb6f4', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-backup-helper-script-manager', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-boost-core' => array( - 'pretty_version' => 'v0.3.9', - 'version' => '0.3.9.0', - 'reference' => '83c2081731fe46fc43d938abf1f0818a67c0e61e', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-boost-core', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-boost-speed-score' => array( - 'pretty_version' => 'v0.4.6', - 'version' => '0.4.6.0', - 'reference' => '42d2a24559b5a007096d3a500be058fd92ab1f19', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-boost-speed-score', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-composer-plugin' => array( - 'pretty_version' => 'v4.0.4', - 'version' => '4.0.4.0', - 'reference' => '0c32be22d4e2ff6468ed688780d14bcd70e260da', - 'type' => 'composer-plugin', - 'install_path' => __DIR__ . '/../automattic/jetpack-composer-plugin', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-config' => array( - 'pretty_version' => 'v3.0.1', - 'version' => '3.0.1.0', - 'reference' => '13f26ed2830d9043d351e49c5ab4e2b6ec21e9d2', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-config', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-connection' => array( - 'pretty_version' => 'v6.8.1', - 'version' => '6.8.1.0', - 'reference' => '473c52b3ad8ea7b51066a243d2b1d87ba8835fca', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-connection', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-constants' => array( - 'pretty_version' => 'v3.0.5', - 'version' => '3.0.5.0', - 'reference' => '12446dd21985e3765d8b8b903091c273d22e4e9e', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-constants', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-device-detection' => array( - 'pretty_version' => 'v3.0.5', - 'version' => '3.0.5.0', - 'reference' => 'dd237dd9b92532aba103b71bf43a2a3c87117a7f', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-device-detection', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-explat' => array( - 'pretty_version' => 'v0.2.13', - 'version' => '0.2.13.0', - 'reference' => 'ba4a9fa045deb9c6bf58a394521dbf6458b34d30', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-explat', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-ip' => array( - 'pretty_version' => 'v0.4.6', - 'version' => '0.4.6.0', - 'reference' => '0248018c22240817a2a463fd0e1aa05f55091c6c', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-ip', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-jitm' => array( - 'pretty_version' => 'v4.2.7', - 'version' => '4.2.7.0', - 'reference' => '8ee55bdf627a004ee736921e34160545a917ab44', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-jitm', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-licensing' => array( - 'pretty_version' => 'v3.0.8', - 'version' => '3.0.8.0', - 'reference' => '85e45bf51f729c76535a026edf806e5e800ca409', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-licensing', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-logo' => array( - 'pretty_version' => 'v3.0.4', - 'version' => '3.0.4.0', - 'reference' => 'e13c7917f1bfeb014c923d6763db2ee1d60eb1aa', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-logo', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-my-jetpack' => array( - 'pretty_version' => 'v5.9.1', - 'version' => '5.9.1.0', - 'reference' => 'c75f826f5900506be1b28120946c1b319e23dac6', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-my-jetpack', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-password-checker' => array( - 'pretty_version' => 'v0.4.7', - 'version' => '0.4.7.0', - 'reference' => '25900f1b5bf8718915c607a4fc1d1e0bc290e20a', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-password-checker', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-plans' => array( - 'pretty_version' => 'v0.6.1', - 'version' => '0.6.1.0', - 'reference' => '66a8169d4a22af983aa6c11c57bc385d7c5747cc', - 'type' => 'library', - 'install_path' => __DIR__ . '/../automattic/jetpack-plans', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-plugins-installer' => array( - 'pretty_version' => 'v0.5.4', - 'version' => '0.5.4.0', - 'reference' => '2fbd9cf402e0514f680b8bef9f787633f2bb29ed', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-plugins-installer', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-protect' => array( - 'pretty_version' => 'dev-trunk', - 'version' => 'dev-trunk', - 'reference' => null, - 'type' => 'wordpress-plugin', - 'install_path' => __DIR__ . '/../../', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-protect-models' => array( - 'pretty_version' => 'v0.5.4', - 'version' => '0.5.4.0', - 'reference' => '99180919a0756cfd3272388eebc99c5795894b18', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-protect-models', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-protect-status' => array( - 'pretty_version' => 'v0.5.8', - 'version' => '0.5.8.0', - 'reference' => '34cd7a21d211ec00709660486b6ee9e0928593a6', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-protect-status', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-redirect' => array( - 'pretty_version' => 'v3.0.5', - 'version' => '3.0.5.0', - 'reference' => '806c695a0fb82bb9e96a6e406df27724f5821180', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-redirect', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-roles' => array( - 'pretty_version' => 'v3.0.5', - 'version' => '3.0.5.0', - 'reference' => '22e0b19517221fca3113c3ed823a3e8e22cd5762', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-roles', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-status' => array( - 'pretty_version' => 'v5.0.10', - 'version' => '5.0.10.0', - 'reference' => '239152e50e7f5492b78bceff51ec4d1ca7a1b427', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-status', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-sync' => array( - 'pretty_version' => 'v4.9.2', - 'version' => '4.9.2.0', - 'reference' => 'd24cf1d05b5f700e4d92f2275dd7d414d2191e32', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-sync', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-transport-helper' => array( - 'pretty_version' => 'v0.3.1', - 'version' => '0.3.1.0', - 'reference' => '6c7cf972ff16b3d229e96781f9c9106f94677afe', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-transport-helper', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'automattic/jetpack-waf' => array( - 'pretty_version' => 'v0.23.8', - 'version' => '0.23.8.0', - 'reference' => '9cfafab1c0e0986b5bd8970c013f780208e4a84f', - 'type' => 'jetpack-library', - 'install_path' => __DIR__ . '/../../jetpack_vendor/automattic/jetpack-waf', - 'aliases' => array(), - 'dev_requirement' => false, - ), - 'wikimedia/aho-corasick' => array( - 'pretty_version' => 'v1.0.1', - 'version' => '1.0.1.0', - 'reference' => '2f3a1bd765913637a66eade658d11d82f0e551be', - 'type' => 'library', - 'install_path' => __DIR__ . '/../wikimedia/aho-corasick', - 'aliases' => array(), - 'dev_requirement' => false, - ), - ), -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_classmap.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_classmap.php deleted file mode 100644 index b68b45bb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_classmap.php +++ /dev/null @@ -1,1037 +0,0 @@ - array( - 'version' => '1.0.1.0', - 'path' => $vendorDir . '/wikimedia/aho-corasick/src/MultiStringMatcher.php' - ), - 'AhoCorasick\\MultiStringReplacer' => array( - 'version' => '1.0.1.0', - 'path' => $vendorDir . '/wikimedia/aho-corasick/src/MultiStringReplacer.php' - ), - 'Autoloader' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-autoloader.php' - ), - 'Autoloader_Handler' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-autoloader-handler.php' - ), - 'Autoloader_Locator' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-autoloader-locator.php' - ), - 'Automattic\\Jetpack\\A8c_Mc_Stats' => array( - 'version' => '3.0.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-a8c-mc-stats/src/class-a8c-mc-stats.php' - ), - 'Automattic\\Jetpack\\Admin_UI\\Admin_Menu' => array( - 'version' => '0.5.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-admin-ui/src/class-admin-menu.php' - ), - 'Automattic\\Jetpack\\Assets' => array( - 'version' => '4.0.14.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-assets.php' - ), - 'Automattic\\Jetpack\\Assets\\Logo' => array( - 'version' => '3.0.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-logo/src/class-logo.php' - ), - 'Automattic\\Jetpack\\Assets\\Script_Data' => array( - 'version' => '4.0.14.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-script-data.php' - ), - 'Automattic\\Jetpack\\Assets\\Semver' => array( - 'version' => '4.0.14.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/src/class-semver.php' - ), - 'Automattic\\Jetpack\\Autoloader\\AutoloadFileWriter' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadFileWriter.php' - ), - 'Automattic\\Jetpack\\Autoloader\\AutoloadGenerator' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadGenerator.php' - ), - 'Automattic\\Jetpack\\Autoloader\\AutoloadProcessor' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/AutoloadProcessor.php' - ), - 'Automattic\\Jetpack\\Autoloader\\CustomAutoloaderPlugin' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php' - ), - 'Automattic\\Jetpack\\Autoloader\\ManifestGenerator' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/ManifestGenerator.php' - ), - 'Automattic\\Jetpack\\Automatic_Install_Skin' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-automatic-install-skin.php' - ), - 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager' => array( - 'version' => '0.3.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-helper-script-manager.php' - ), - 'Automattic\\Jetpack\\Backup\\V0005\\Helper_Script_Manager_Impl' => array( - 'version' => '0.3.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-helper-script-manager-impl.php' - ), - 'Automattic\\Jetpack\\Backup\\V0005\\Throw_On_Errors' => array( - 'version' => '0.3.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-backup-helper-script-manager/src/class-throw-on-errors.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Contracts\\Boost_API_Client' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/contracts/boost-api-client.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Boost_API' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-boost-api.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Cacheable' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-cacheable.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Transient' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-transient.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Url' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-url.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Lib\\Utils' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-utils.php' - ), - 'Automattic\\Jetpack\\Boost_Core\\Lib\\WPCOM_Boost_API_Client' => array( - 'version' => '0.3.9.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-core/src/lib/class-wpcom-boost-api-client.php' - ), - 'Automattic\\Jetpack\\Boost_Speed_Score\\Jetpack_Boost_Modules' => array( - 'version' => '0.4.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-jetpack-boost-modules.php' - ), - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score' => array( - 'version' => '0.4.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score.php' - ), - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_Graph_History_Request' => array( - 'version' => '0.4.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-graph-history-request.php' - ), - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_History' => array( - 'version' => '0.4.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-history.php' - ), - 'Automattic\\Jetpack\\Boost_Speed_Score\\Speed_Score_Request' => array( - 'version' => '0.4.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-boost-speed-score/src/class-speed-score-request.php' - ), - 'Automattic\\Jetpack\\Composer\\Manager' => array( - 'version' => '4.0.4.0', - 'path' => $vendorDir . '/automattic/jetpack-composer-plugin/src/class-manager.php' - ), - 'Automattic\\Jetpack\\Composer\\Plugin' => array( - 'version' => '4.0.4.0', - 'path' => $vendorDir . '/automattic/jetpack-composer-plugin/src/class-plugin.php' - ), - 'Automattic\\Jetpack\\Config' => array( - 'version' => '3.0.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-config/src/class-config.php' - ), - 'Automattic\\Jetpack\\Connection\\Authorize_Json_Api' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-authorize-json-api.php' - ), - 'Automattic\\Jetpack\\Connection\\Client' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-client.php' - ), - 'Automattic\\Jetpack\\Connection\\Connection_Assets' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-assets.php' - ), - 'Automattic\\Jetpack\\Connection\\Connection_Notice' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-connection-notice.php' - ), - 'Automattic\\Jetpack\\Connection\\Error_Handler' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-error-handler.php' - ), - 'Automattic\\Jetpack\\Connection\\Initial_State' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-initial-state.php' - ), - 'Automattic\\Jetpack\\Connection\\Manager' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-manager.php' - ), - 'Automattic\\Jetpack\\Connection\\Manager_Interface' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/interface-manager.php' - ), - 'Automattic\\Jetpack\\Connection\\Nonce_Handler' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-nonce-handler.php' - ), - 'Automattic\\Jetpack\\Connection\\Package_Version' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version.php' - ), - 'Automattic\\Jetpack\\Connection\\Package_Version_Tracker' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-package-version-tracker.php' - ), - 'Automattic\\Jetpack\\Connection\\Plugin' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin.php' - ), - 'Automattic\\Jetpack\\Connection\\Plugin_Storage' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-plugin-storage.php' - ), - 'Automattic\\Jetpack\\Connection\\REST_Connector' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-connector.php' - ), - 'Automattic\\Jetpack\\Connection\\Rest_Authentication' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-rest-authentication.php' - ), - 'Automattic\\Jetpack\\Connection\\SSO' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-sso.php' - ), - 'Automattic\\Jetpack\\Connection\\SSO\\Force_2FA' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-force-2fa.php' - ), - 'Automattic\\Jetpack\\Connection\\SSO\\Helpers' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-helpers.php' - ), - 'Automattic\\Jetpack\\Connection\\SSO\\Notices' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-notices.php' - ), - 'Automattic\\Jetpack\\Connection\\SSO\\User_Admin' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/sso/class-user-admin.php' - ), - 'Automattic\\Jetpack\\Connection\\Secrets' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-secrets.php' - ), - 'Automattic\\Jetpack\\Connection\\Server_Sandbox' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-server-sandbox.php' - ), - 'Automattic\\Jetpack\\Connection\\Tokens' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens.php' - ), - 'Automattic\\Jetpack\\Connection\\Tokens_Locks' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tokens-locks.php' - ), - 'Automattic\\Jetpack\\Connection\\Traits\\WPCOM_REST_API_Proxy_Request' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/traits/trait-wpcom-rest-api-proxy-request.php' - ), - 'Automattic\\Jetpack\\Connection\\Urls' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-urls.php' - ), - 'Automattic\\Jetpack\\Connection\\Users_Connection_Admin' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-users-connection-admin.php' - ), - 'Automattic\\Jetpack\\Connection\\Utils' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-utils.php' - ), - 'Automattic\\Jetpack\\Connection\\Webhooks' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-webhooks.php' - ), - 'Automattic\\Jetpack\\Connection\\Webhooks\\Authorize_Redirect' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/webhooks/class-authorize-redirect.php' - ), - 'Automattic\\Jetpack\\Connection\\XMLRPC_Async_Call' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-async-call.php' - ), - 'Automattic\\Jetpack\\Connection\\XMLRPC_Connector' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-xmlrpc-connector.php' - ), - 'Automattic\\Jetpack\\Constants' => array( - 'version' => '3.0.5.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-constants/src/class-constants.php' - ), - 'Automattic\\Jetpack\\CookieState' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-cookiestate.php' - ), - 'Automattic\\Jetpack\\Current_Plan' => array( - 'version' => '0.6.1.0', - 'path' => $vendorDir . '/automattic/jetpack-plans/src/class-current-plan.php' - ), - 'Automattic\\Jetpack\\Device_Detection' => array( - 'version' => '3.0.5.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-device-detection.php' - ), - 'Automattic\\Jetpack\\Device_Detection\\User_Agent_Info' => array( - 'version' => '3.0.5.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-device-detection/src/class-user-agent-info.php' - ), - 'Automattic\\Jetpack\\Errors' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-errors.php' - ), - 'Automattic\\Jetpack\\ExPlat' => array( - 'version' => '0.2.13.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-explat/src/class-explat.php' - ), - 'Automattic\\Jetpack\\ExPlat\\REST_Controller' => array( - 'version' => '0.2.13.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-explat/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Files' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-files.php' - ), - 'Automattic\\Jetpack\\Heartbeat' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-heartbeat.php' - ), - 'Automattic\\Jetpack\\IP\\Utils' => array( - 'version' => '0.4.6.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-ip/src/class-utils.php' - ), - 'Automattic\\Jetpack\\IdentityCrisis\\Exception' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-exception.php' - ), - 'Automattic\\Jetpack\\IdentityCrisis\\REST_Endpoints' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-rest-endpoints.php' - ), - 'Automattic\\Jetpack\\IdentityCrisis\\UI' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-ui.php' - ), - 'Automattic\\Jetpack\\IdentityCrisis\\URL_Secret' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-url-secret.php' - ), - 'Automattic\\Jetpack\\Identity_Crisis' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/identity-crisis/class-identity-crisis.php' - ), - 'Automattic\\Jetpack\\JITMS\\JITM' => array( - 'version' => '4.2.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-jitm.php' - ), - 'Automattic\\Jetpack\\JITMS\\Post_Connection_JITM' => array( - 'version' => '4.2.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-post-connection-jitm.php' - ), - 'Automattic\\Jetpack\\JITMS\\Pre_Connection_JITM' => array( - 'version' => '4.2.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-pre-connection-jitm.php' - ), - 'Automattic\\Jetpack\\JITMS\\Rest_Api_Endpoints' => array( - 'version' => '4.2.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-jitm/src/class-rest-api-endpoints.php' - ), - 'Automattic\\Jetpack\\Licensing' => array( - 'version' => '3.0.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-licensing/src/class-licensing.php' - ), - 'Automattic\\Jetpack\\Licensing\\Endpoints' => array( - 'version' => '3.0.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-licensing/src/class-endpoints.php' - ), - 'Automattic\\Jetpack\\Modules' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-modules.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Activitylog' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-activitylog.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Historically_Active_Modules' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-historically-active-modules.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Hybrid_Product' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-hybrid-product.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Initializer' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-initializer.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Jetpack_Manage' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-jetpack-manage.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Module_Product' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-module-product.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Product' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-product.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-products.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Anti_Spam' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-anti-spam.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Backup' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-backup.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Boost' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-boost.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Complete' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-complete.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Creator' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-creator.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Crm' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-crm.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Extras' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-extras.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Growth' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-growth.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Jetpack_Ai' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-jetpack-ai.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Newsletter' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-newsletter.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Protect' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-protect.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Related_Posts' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-related-posts.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Scan' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-scan.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Search_Stats' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-search-stats.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Security' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-security.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Site_Accelerator' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-site-accelerator.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Social' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-social.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Starter' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-starter.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Stats' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-stats.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Products\\Videopress' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/products/class-videopress.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_AI' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-ai.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_Products' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-products.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_Purchases' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-purchases.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_Recommendations_Evaluation' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-recommendations-evaluation.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\REST_Zendesk_Chat' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-rest-zendesk-chat.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Red_Bubble_Notifications' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-red-bubble-notifications.php' - ), - 'Automattic\\Jetpack\\My_Jetpack\\Wpcom_Products' => array( - 'version' => '5.9.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-my-jetpack/src/class-wpcom-products.php' - ), - 'Automattic\\Jetpack\\Partner' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-partner.php' - ), - 'Automattic\\Jetpack\\Partner_Coupon' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-partner-coupon.php' - ), - 'Automattic\\Jetpack\\Password_Checker' => array( - 'version' => '0.4.7.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-password-checker/src/class-password-checker.php' - ), - 'Automattic\\Jetpack\\Paths' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-paths.php' - ), - 'Automattic\\Jetpack\\Plans' => array( - 'version' => '0.6.1.0', - 'path' => $vendorDir . '/automattic/jetpack-plans/src/class-plans.php' - ), - 'Automattic\\Jetpack\\Plugins_Installer' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-plugins-installer/src/class-plugins-installer.php' - ), - 'Automattic\\Jetpack\\Protect\\Credentials' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-credentials.php' - ), - 'Automattic\\Jetpack\\Protect\\Onboarding' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-onboarding.php' - ), - 'Automattic\\Jetpack\\Protect\\REST_Controller' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Protect\\Scan_History' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-scan-history.php' - ), - 'Automattic\\Jetpack\\Protect\\Site_Health' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-site-health.php' - ), - 'Automattic\\Jetpack\\Protect\\Threats' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-threats.php' - ), - 'Automattic\\Jetpack\\Protect_Models' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-protect-models.php' - ), - 'Automattic\\Jetpack\\Protect_Models\\Extension_Model' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-extension-model.php' - ), - 'Automattic\\Jetpack\\Protect_Models\\History_Model' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-history-model.php' - ), - 'Automattic\\Jetpack\\Protect_Models\\Status_Model' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-status-model.php' - ), - 'Automattic\\Jetpack\\Protect_Models\\Threat_Model' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-threat-model.php' - ), - 'Automattic\\Jetpack\\Protect_Models\\Vulnerability_Model' => array( - 'version' => '0.5.4.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-models/src/class-vulnerability-model.php' - ), - 'Automattic\\Jetpack\\Protect_Status\\Plan' => array( - 'version' => '0.5.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-plan.php' - ), - 'Automattic\\Jetpack\\Protect_Status\\Protect_Status' => array( - 'version' => '0.5.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-protect-status.php' - ), - 'Automattic\\Jetpack\\Protect_Status\\REST_Controller' => array( - 'version' => '0.5.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Protect_Status\\Scan_Status' => array( - 'version' => '0.5.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-scan-status.php' - ), - 'Automattic\\Jetpack\\Protect_Status\\Status' => array( - 'version' => '0.5.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-protect-status/src/class-status.php' - ), - 'Automattic\\Jetpack\\Redirect' => array( - 'version' => '3.0.5.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-redirect/src/class-redirect.php' - ), - 'Automattic\\Jetpack\\Roles' => array( - 'version' => '3.0.5.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-roles/src/class-roles.php' - ), - 'Automattic\\Jetpack\\Status' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-status.php' - ), - 'Automattic\\Jetpack\\Status\\Cache' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-cache.php' - ), - 'Automattic\\Jetpack\\Status\\Host' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-host.php' - ), - 'Automattic\\Jetpack\\Status\\Visitor' => array( - 'version' => '5.0.10.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-status/src/class-visitor.php' - ), - 'Automattic\\Jetpack\\Sync\\Actions' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-actions.php' - ), - 'Automattic\\Jetpack\\Sync\\Codec_Interface' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/interface-codec.php' - ), - 'Automattic\\Jetpack\\Sync\\Data_Settings' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-data-settings.php' - ), - 'Automattic\\Jetpack\\Sync\\Dedicated_Sender' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-dedicated-sender.php' - ), - 'Automattic\\Jetpack\\Sync\\Default_Filter_Settings' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-default-filter-settings.php' - ), - 'Automattic\\Jetpack\\Sync\\Defaults' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-defaults.php' - ), - 'Automattic\\Jetpack\\Sync\\Functions' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-functions.php' - ), - 'Automattic\\Jetpack\\Sync\\Health' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-health.php' - ), - 'Automattic\\Jetpack\\Sync\\JSON_Deflate_Array_Codec' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-json-deflate-array-codec.php' - ), - 'Automattic\\Jetpack\\Sync\\Listener' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-listener.php' - ), - 'Automattic\\Jetpack\\Sync\\Lock' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-lock.php' - ), - 'Automattic\\Jetpack\\Sync\\Main' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-main.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-modules.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Attachments' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-attachments.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Callables' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-callables.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Comments' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-comments.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Constants' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-constants.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Full_Sync_Immediately' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-full-sync-immediately.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Import' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-import.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Menus' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-menus.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Meta' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-meta.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Module' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-module.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Network_Options' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-network-options.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Options' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-options.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Plugins' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-plugins.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Posts' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-posts.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Protect' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-protect.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Search' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-search.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Stats' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-stats.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Term_Relationships' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-term-relationships.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Terms' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-terms.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Themes' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-themes.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Updates' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-updates.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\Users' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-users.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\WP_Super_Cache' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-wp-super-cache.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce.php' - ), - 'Automattic\\Jetpack\\Sync\\Modules\\WooCommerce_HPOS_Orders' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/modules/class-woocommerce-hpos-orders.php' - ), - 'Automattic\\Jetpack\\Sync\\Package_Version' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-package-version.php' - ), - 'Automattic\\Jetpack\\Sync\\Queue' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue.php' - ), - 'Automattic\\Jetpack\\Sync\\Queue\\Queue_Storage_Options' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-options.php' - ), - 'Automattic\\Jetpack\\Sync\\Queue\\Queue_Storage_Table' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/sync-queue/class-queue-storage-table.php' - ), - 'Automattic\\Jetpack\\Sync\\Queue_Buffer' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-queue-buffer.php' - ), - 'Automattic\\Jetpack\\Sync\\REST_Endpoints' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-endpoints.php' - ), - 'Automattic\\Jetpack\\Sync\\REST_Sender' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-rest-sender.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-replicastore.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Usermeta' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-usermeta.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore\\Table_Checksum_Users' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/replicastore/class-table-checksum-users.php' - ), - 'Automattic\\Jetpack\\Sync\\Replicastore_Interface' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/interface-replicastore.php' - ), - 'Automattic\\Jetpack\\Sync\\Sender' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-sender.php' - ), - 'Automattic\\Jetpack\\Sync\\Server' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-server.php' - ), - 'Automattic\\Jetpack\\Sync\\Settings' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-settings.php' - ), - 'Automattic\\Jetpack\\Sync\\Simple_Codec' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-simple-codec.php' - ), - 'Automattic\\Jetpack\\Sync\\Users' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-users.php' - ), - 'Automattic\\Jetpack\\Sync\\Utils' => array( - 'version' => '4.9.2.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-sync/src/class-utils.php' - ), - 'Automattic\\Jetpack\\Terms_Of_Service' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-terms-of-service.php' - ), - 'Automattic\\Jetpack\\Tracking' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/src/class-tracking.php' - ), - 'Automattic\\Jetpack\\Transport_Helper\\Package_Version' => array( - 'version' => '0.3.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version.php' - ), - 'Automattic\\Jetpack\\Transport_Helper\\V0001\\Package_Version' => array( - 'version' => '0.3.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-package-version-compat.php' - ), - 'Automattic\\Jetpack\\Transport_Helper\\V0005\\REST_Controller' => array( - 'version' => '0.3.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-brute-force-protection.php' - ), - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Blocked_Login_Page' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-blocked-login-page.php' - ), - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Math_Authenticate' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-math-fallback.php' - ), - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Shared_Functions' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-shared-functions.php' - ), - 'Automattic\\Jetpack\\Waf\\Brute_Force_Protection\\Brute_Force_Protection_Transient_Cleanup' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/brute-force-protection/class-transient-cleanup.php' - ), - 'Automattic\\Jetpack\\Waf\\CLI' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-cli.php' - ), - 'Automattic\\Jetpack\\Waf\\File_System_Exception' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-file-system-exception.php' - ), - 'Automattic\\Jetpack\\Waf\\REST_Controller' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-rest-controller.php' - ), - 'Automattic\\Jetpack\\Waf\\Rules_API_Exception' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-rules-api-exception.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Blocklog_Manager' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-blocklog-manager.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Compatibility' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-compatibility.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Constants' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-constants.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Exception' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/exceptions/class-waf-exception.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Initializer' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-initializer.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Operators' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-operators.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Request' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-request.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Rules_Manager' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-rules-manager.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Runner' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runner.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Runtime' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-runtime.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Standalone_Bootstrap' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-standalone-bootstrap.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Stats' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-stats.php' - ), - 'Automattic\\Jetpack\\Waf\\Waf_Transforms' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/src/class-waf-transforms.php' - ), - 'Container' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-container.php' - ), - 'Hook_Manager' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-hook-manager.php' - ), - 'Jetpack_IXR_Client' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-client.php' - ), - 'Jetpack_IXR_ClientMulticall' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-ixr-clientmulticall.php' - ), - 'Jetpack_Options' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-options.php' - ), - 'Jetpack_Protect' => array( - 'version' => 'dev-trunk', - 'path' => $baseDir . '/src/class-jetpack-protect.php' - ), - 'Jetpack_Signature' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-signature.php' - ), - 'Jetpack_Tracks_Client' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-client.php' - ), - 'Jetpack_Tracks_Event' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-tracks-event.php' - ), - 'Jetpack_XMLRPC_Server' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/legacy/class-jetpack-xmlrpc-server.php' - ), - 'Latest_Autoloader_Guard' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-latest-autoloader-guard.php' - ), - 'Manifest_Reader' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-manifest-reader.php' - ), - 'PHP_Autoloader' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-php-autoloader.php' - ), - 'Path_Processor' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-path-processor.php' - ), - 'Plugin_Locator' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-plugin-locator.php' - ), - 'Plugins_Handler' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-plugins-handler.php' - ), - 'Shutdown_Handler' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-shutdown-handler.php' - ), - 'Version_Loader' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-version-loader.php' - ), - 'Version_Selector' => array( - 'version' => '5.0.5', - 'path' => $vendorDir . '/automattic/jetpack-autoloader/src/class-version-selector.php' - ), -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_filemap.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_filemap.php deleted file mode 100644 index 610fce20..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/jetpack_autoload_filemap.php +++ /dev/null @@ -1,25 +0,0 @@ - array( - 'version' => '4.0.14.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-assets/actions.php' - ), - '7372b7fb88a9723cf5b76d456eb0b738' => array( - 'version' => '6.8.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-connection/actions.php' - ), - '590147edb63acb03b2852d5c4db13ce8' => array( - 'version' => '0.3.1.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-transport-helper/actions.php' - ), - '3d45c7e6a7f0e71849e33afe4b3b3ede' => array( - 'version' => '0.23.8.0', - 'path' => $baseDir . '/jetpack_vendor/automattic/jetpack-waf/cli.php' - ), -); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/platform_check.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/platform_check.php deleted file mode 100644 index 589e9e77..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/composer/platform_check.php +++ /dev/null @@ -1,26 +0,0 @@ -= 70200)) { - $issues[] = 'Your Composer dependencies require a PHP version ">= 7.2.0". You are running ' . PHP_VERSION . '.'; -} - -if ($issues) { - if (!headers_sent()) { - header('HTTP/1.1 500 Internal Server Error'); - } - if (!ini_get('display_errors')) { - if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') { - fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL); - } elseif (!headers_sent()) { - echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL; - } - } - trigger_error( - 'Composer detected issues in your platform: ' . implode(' ', $issues), - E_USER_ERROR - ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader-handler.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader-handler.php deleted file mode 100644 index 61d8a139..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader-handler.php +++ /dev/null @@ -1,147 +0,0 @@ -php_autoloader = $php_autoloader; - $this->hook_manager = $hook_manager; - $this->manifest_reader = $manifest_reader; - $this->version_selector = $version_selector; - } - - /** - * Checks to see whether or not an autoloader is currently in the process of initializing. - * - * @return bool - */ - public function is_initializing() { - // If no version has been set it means that no autoloader has started initializing yet. - global $jetpack_autoloader_latest_version; - if ( ! isset( $jetpack_autoloader_latest_version ) ) { - return false; - } - - // When the version is set but the classmap is not it ALWAYS means that this is the - // latest autoloader and is being included by an older one. - global $jetpack_packages_classmap; - if ( empty( $jetpack_packages_classmap ) ) { - return true; - } - - // Version 2.4.0 added a new global and altered the reset semantics. We need to check - // the other global as well since it may also point at initialization. - // Note: We don't need to check for the class first because every autoloader that - // will set the latest version global requires this class in the classmap. - $replacing_version = $jetpack_packages_classmap[ AutoloadGenerator::class ]['version']; - if ( $this->version_selector->is_dev_version( $replacing_version ) || version_compare( $replacing_version, '2.4.0.0', '>=' ) ) { - global $jetpack_autoloader_loader; - if ( ! isset( $jetpack_autoloader_loader ) ) { - return true; - } - } - - return false; - } - - /** - * Activates an autoloader using the given plugins and activates it. - * - * @param string[] $plugins The plugins to initialize the autoloader for. - */ - public function activate_autoloader( $plugins ) { - global $jetpack_packages_psr4; - $jetpack_packages_psr4 = array(); - $this->manifest_reader->read_manifests( $plugins, 'vendor/composer/jetpack_autoload_psr4.php', $jetpack_packages_psr4 ); - - global $jetpack_packages_classmap; - $jetpack_packages_classmap = array(); - $this->manifest_reader->read_manifests( $plugins, 'vendor/composer/jetpack_autoload_classmap.php', $jetpack_packages_classmap ); - - global $jetpack_packages_filemap; - $jetpack_packages_filemap = array(); - $this->manifest_reader->read_manifests( $plugins, 'vendor/composer/jetpack_autoload_filemap.php', $jetpack_packages_filemap ); - - $loader = new Version_Loader( - $this->version_selector, - $jetpack_packages_classmap, - $jetpack_packages_psr4, - $jetpack_packages_filemap - ); - - $this->php_autoloader->register_autoloader( $loader ); - - // Now that the autoloader is active we can load the filemap. - $loader->load_filemap(); - } - - /** - * Resets the active autoloader and all related global state. - */ - public function reset_autoloader() { - $this->php_autoloader->unregister_autoloader(); - $this->hook_manager->reset(); - - // Clear all of the autoloader globals so that older autoloaders don't do anything strange. - global $jetpack_autoloader_latest_version; - $jetpack_autoloader_latest_version = null; - - global $jetpack_packages_classmap; - $jetpack_packages_classmap = array(); // Must be array to avoid exceptions in old autoloaders! - - global $jetpack_packages_psr4; - $jetpack_packages_psr4 = array(); // Must be array to avoid exceptions in old autoloaders! - - global $jetpack_packages_filemap; - $jetpack_packages_filemap = array(); // Must be array to avoid exceptions in old autoloaders! - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader-locator.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader-locator.php deleted file mode 100644 index ed6ae603..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader-locator.php +++ /dev/null @@ -1,90 +0,0 @@ -version_selector = $version_selector; - } - - /** - * Finds the path to the plugin with the latest autoloader. - * - * @param array $plugin_paths An array of plugin paths. - * @param string $latest_version The latest version reference. @phan-output-reference. - * - * @return string|null - */ - public function find_latest_autoloader( $plugin_paths, &$latest_version ) { - $latest_plugin = null; - - foreach ( $plugin_paths as $plugin_path ) { - $version = $this->get_autoloader_version( $plugin_path ); - if ( ! $version || ! $this->version_selector->is_version_update_required( $latest_version, $version ) ) { - continue; - } - - $latest_version = $version; - $latest_plugin = $plugin_path; - } - - return $latest_plugin; - } - - /** - * Gets the path to the autoloader. - * - * @param string $plugin_path The path to the plugin. - * - * @return string - */ - public function get_autoloader_path( $plugin_path ) { - return trailingslashit( $plugin_path ) . 'vendor/autoload_packages.php'; - } - - /** - * Gets the version for the autoloader. - * - * @param string $plugin_path The path to the plugin. - * - * @return string|null - */ - public function get_autoloader_version( $plugin_path ) { - $classmap = trailingslashit( $plugin_path ) . 'vendor/composer/jetpack_autoload_classmap.php'; - if ( ! file_exists( $classmap ) ) { - return null; - } - - $classmap = require $classmap; - if ( isset( $classmap[ AutoloadGenerator::class ] ) ) { - return $classmap[ AutoloadGenerator::class ]['version']; - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader.php deleted file mode 100644 index 94508e41..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-autoloader.php +++ /dev/null @@ -1,93 +0,0 @@ -get( Autoloader_Handler::class ); - - // If the autoloader is already initializing it means that it has included us as the latest. - $was_included_by_autoloader = $autoloader_handler->is_initializing(); - - /** @var Plugin_Locator $plugin_locator */ - $plugin_locator = $container->get( Plugin_Locator::class ); - - /** @var Plugins_Handler $plugins_handler */ - $plugins_handler = $container->get( Plugins_Handler::class ); - - // The current plugin is the one that we are attempting to initialize here. - $current_plugin = $plugin_locator->find_current_plugin(); - - // The active plugins are those that we were able to discover on the site. This list will not - // include mu-plugins, those activated by code, or those who are hidden by filtering. We also - // want to take care to not consider the current plugin unknown if it was included by an - // autoloader. This avoids the case where a plugin will be marked "active" while deactivated - // due to it having the latest autoloader. - $active_plugins = $plugins_handler->get_active_plugins( true, ! $was_included_by_autoloader ); - - // The cached plugins are all of those that were active or discovered by the autoloader during a previous request. - // Note that it's possible this list will include plugins that have since been deactivated, but after a request - // the cache should be updated and the deactivated plugins will be removed. - $cached_plugins = $plugins_handler->get_cached_plugins(); - - // We combine the active list and cached list to preemptively load classes for plugins that are - // presently unknown but will be loaded during the request. While this may result in us considering packages in - // deactivated plugins there shouldn't be any problems as a result and the eventual consistency is sufficient. - $all_plugins = array_merge( $active_plugins, $cached_plugins ); - - // In particular we also include the current plugin to address the case where it is the latest autoloader - // but also unknown (and not cached). We don't want it in the active list because we don't know that it - // is active but we need it in the all plugins list so that it is considered by the autoloader. - $all_plugins[] = $current_plugin; - - // We require uniqueness in the array to avoid processing the same plugin more than once. - $all_plugins = array_values( array_unique( $all_plugins ) ); - - /** @var Latest_Autoloader_Guard $guard */ - $guard = $container->get( Latest_Autoloader_Guard::class ); - if ( $guard->should_stop_init( $current_plugin, $all_plugins, $was_included_by_autoloader ) ) { - return; - } - - // Initialize the autoloader using the handler now that we're ready. - $autoloader_handler->activate_autoloader( $all_plugins ); - - /** @var Hook_Manager $hook_manager */ - $hook_manager = $container->get( Hook_Manager::class ); - - // Register a shutdown handler to clean up the autoloader. - $hook_manager->add_action( 'shutdown', new Shutdown_Handler( $plugins_handler, $cached_plugins, $was_included_by_autoloader ) ); - - // Register a plugins_loaded handler to check for conflicting autoloaders. - $hook_manager->add_action( 'plugins_loaded', array( $guard, 'check_for_conflicting_autoloaders' ), 1 ); - - // phpcs:enable Generic.Commenting.DocComment.MissingShort - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-container.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-container.php deleted file mode 100644 index 54bc9214..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-container.php +++ /dev/null @@ -1,150 +0,0 @@ - 'Hook_Manager', - ); - - /** - * A map of all the dependencies we've registered with the container and created. - * - * @var array - */ - protected $dependencies; - - /** - * The constructor. - */ - public function __construct() { - $this->dependencies = array(); - - $this->register_shared_dependencies(); - $this->register_dependencies(); - $this->initialize_globals(); - } - - /** - * Gets a dependency out of the container. - * - * @param string $class The class to fetch. - * - * @return mixed - * @throws \InvalidArgumentException When a class that isn't registered with the container is fetched. - */ - public function get( $class ) { - if ( ! isset( $this->dependencies[ $class ] ) ) { - throw new \InvalidArgumentException( "Class '$class' is not registered with the container." ); - } - - return $this->dependencies[ $class ]; - } - - /** - * Registers all of the dependencies that are shared between all instances of the autoloader. - */ - private function register_shared_dependencies() { - global $jetpack_autoloader_container_shared; - if ( ! isset( $jetpack_autoloader_container_shared ) ) { - $jetpack_autoloader_container_shared = array(); - } - - $key = self::SHARED_DEPENDENCY_KEYS[ Hook_Manager::class ]; - if ( ! isset( $jetpack_autoloader_container_shared[ $key ] ) ) { - require_once __DIR__ . '/class-hook-manager.php'; - $jetpack_autoloader_container_shared[ $key ] = new Hook_Manager(); - } - $this->dependencies[ Hook_Manager::class ] = &$jetpack_autoloader_container_shared[ $key ]; - } - - /** - * Registers all of the dependencies with the container. - */ - private function register_dependencies() { - require_once __DIR__ . '/class-path-processor.php'; - $this->dependencies[ Path_Processor::class ] = new Path_Processor(); - - require_once __DIR__ . '/class-plugin-locator.php'; - $this->dependencies[ Plugin_Locator::class ] = new Plugin_Locator( - $this->get( Path_Processor::class ) - ); - - require_once __DIR__ . '/class-version-selector.php'; - $this->dependencies[ Version_Selector::class ] = new Version_Selector(); - - require_once __DIR__ . '/class-autoloader-locator.php'; - $this->dependencies[ Autoloader_Locator::class ] = new Autoloader_Locator( - $this->get( Version_Selector::class ) - ); - - require_once __DIR__ . '/class-php-autoloader.php'; - $this->dependencies[ PHP_Autoloader::class ] = new PHP_Autoloader(); - - require_once __DIR__ . '/class-manifest-reader.php'; - $this->dependencies[ Manifest_Reader::class ] = new Manifest_Reader( - $this->get( Version_Selector::class ) - ); - - require_once __DIR__ . '/class-plugins-handler.php'; - $this->dependencies[ Plugins_Handler::class ] = new Plugins_Handler( - $this->get( Plugin_Locator::class ), - $this->get( Path_Processor::class ) - ); - - require_once __DIR__ . '/class-autoloader-handler.php'; - $this->dependencies[ Autoloader_Handler::class ] = new Autoloader_Handler( - $this->get( PHP_Autoloader::class ), - $this->get( Hook_Manager::class ), - $this->get( Manifest_Reader::class ), - $this->get( Version_Selector::class ) - ); - - require_once __DIR__ . '/class-latest-autoloader-guard.php'; - $this->dependencies[ Latest_Autoloader_Guard::class ] = new Latest_Autoloader_Guard( - $this->get( Plugins_Handler::class ), - $this->get( Autoloader_Handler::class ), - $this->get( Autoloader_Locator::class ) - ); - - // Register any classes that we will use elsewhere. - require_once __DIR__ . '/class-version-loader.php'; - require_once __DIR__ . '/class-shutdown-handler.php'; - } - - /** - * Initializes any of the globals needed by the autoloader. - */ - private function initialize_globals() { - /* - * This global was retired in version 2.9. The value is set to 'false' to maintain - * compatibility with older versions of the autoloader. - */ - global $jetpack_autoloader_including_latest; - $jetpack_autoloader_including_latest = false; - - // Not all plugins can be found using the locator. In cases where a plugin loads the autoloader - // but was not discoverable, we will record them in this array to track them as "active". - global $jetpack_autoloader_activating_plugins_paths; - if ( ! isset( $jetpack_autoloader_activating_plugins_paths ) ) { - $jetpack_autoloader_activating_plugins_paths = array(); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-hook-manager.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-hook-manager.php deleted file mode 100644 index 7e72d956..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-hook-manager.php +++ /dev/null @@ -1,76 +0,0 @@ -registered_hooks = array(); - } - - /** - * Adds an action to WordPress and registers it internally. - * - * @param string $tag The name of the action which is hooked. - * @param callable $callable The function to call. - * @param int $priority Used to specify the priority of the action. - * @param int $accepted_args Used to specify the number of arguments the callable accepts. - */ - public function add_action( $tag, $callable, $priority = 10, $accepted_args = 1 ) { - $this->registered_hooks[ $tag ][] = array( - 'priority' => $priority, - 'callable' => $callable, - ); - - add_action( $tag, $callable, $priority, $accepted_args ); - } - - /** - * Adds a filter to WordPress and registers it internally. - * - * @param string $tag The name of the filter which is hooked. - * @param callable $callable The function to call. - * @param int $priority Used to specify the priority of the filter. - * @param int $accepted_args Used to specify the number of arguments the callable accepts. - */ - public function add_filter( $tag, $callable, $priority = 10, $accepted_args = 1 ) { - $this->registered_hooks[ $tag ][] = array( - 'priority' => $priority, - 'callable' => $callable, - ); - - add_filter( $tag, $callable, $priority, $accepted_args ); - } - - /** - * Removes all of the registered hooks. - */ - public function reset() { - foreach ( $this->registered_hooks as $tag => $hooks ) { - foreach ( $hooks as $hook ) { - remove_filter( $tag, $hook['callable'], $hook['priority'] ); - } - } - $this->registered_hooks = array(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-latest-autoloader-guard.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-latest-autoloader-guard.php deleted file mode 100644 index ff4166cf..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-latest-autoloader-guard.php +++ /dev/null @@ -1,165 +0,0 @@ -plugins_handler = $plugins_handler; - $this->autoloader_handler = $autoloader_handler; - $this->autoloader_locator = $autoloader_locator; - } - - /** - * Indicates whether or not the autoloader should be initialized. Note that this function - * has the side-effect of actually loading the latest autoloader in the event that this - * is not it. - * - * @param string $current_plugin The current plugin we're checking. - * @param string[] $plugins The active plugins to check for autoloaders in. - * @param bool $was_included_by_autoloader Indicates whether or not this autoloader was included by another. - * - * @return bool True if we should stop initialization, otherwise false. - */ - public function should_stop_init( $current_plugin, $plugins, $was_included_by_autoloader ) { - global $jetpack_autoloader_latest_version; - - // We need to reset the autoloader when the plugins change because - // that means the autoloader was generated with a different list. - if ( $this->plugins_handler->have_plugins_changed( $plugins ) ) { - $this->autoloader_handler->reset_autoloader(); - } - - // When the latest autoloader has already been found we don't need to search for it again. - // We should take care however because this will also trigger if the autoloader has been - // included by an older one. - if ( isset( $jetpack_autoloader_latest_version ) && ! $was_included_by_autoloader ) { - return true; - } - - $latest_plugin = $this->autoloader_locator->find_latest_autoloader( $plugins, $jetpack_autoloader_latest_version ); - if ( isset( $latest_plugin ) && $latest_plugin !== $current_plugin ) { - require $this->autoloader_locator->get_autoloader_path( $latest_plugin ); - return true; - } - - return false; - } - - /** - * Check for conflicting autoloaders. - * - * A common source of strange and confusing problems is when another plugin - * registers a Composer autoloader at a higher priority that us. If enabled, - * check for this problem and warn about it. - * - * Called from the plugins_loaded hook. - * - * @since 3.1.0 - * @return void - */ - public function check_for_conflicting_autoloaders() { - if ( ! defined( 'JETPACK_AUTOLOAD_DEBUG_CONFLICTING_LOADERS' ) || ! JETPACK_AUTOLOAD_DEBUG_CONFLICTING_LOADERS ) { - return; - } - - global $jetpack_autoloader_loader; - if ( ! isset( $jetpack_autoloader_loader ) ) { - return; - } - $prefixes = array(); - foreach ( ( $jetpack_autoloader_loader->get_class_map() ?? array() ) as $classname => $data ) { - $parts = explode( '\\', trim( $classname, '\\' ) ); - array_pop( $parts ); - while ( $parts ) { - $prefixes[ implode( '\\', $parts ) . '\\' ] = true; - array_pop( $parts ); - } - } - foreach ( ( $jetpack_autoloader_loader->get_psr4_map() ?? array() ) as $prefix => $data ) { - $parts = explode( '\\', trim( $prefix, '\\' ) ); - while ( $parts ) { - $prefixes[ implode( '\\', $parts ) . '\\' ] = true; - array_pop( $parts ); - } - } - - $autoload_chain = spl_autoload_functions(); - if ( ! $autoload_chain ) { - return; - } - - foreach ( $autoload_chain as $autoloader ) { - // No need to check anything after us. - if ( is_array( $autoloader ) && is_string( $autoloader[0] ) && substr( $autoloader[0], 0, strlen( __NAMESPACE__ ) + 1 ) === __NAMESPACE__ . '\\' ) { - break; - } - - // We can check Composer autoloaders easily enough. - if ( is_array( $autoloader ) && $autoloader[0] instanceof \Composer\Autoload\ClassLoader && is_callable( array( $autoloader[0], 'getPrefixesPsr4' ) ) ) { - $composer_autoloader = $autoloader[0]; - foreach ( $composer_autoloader->getClassMap() as $classname => $path ) { - if ( $jetpack_autoloader_loader->find_class_file( $classname ) ) { - $msg = "A Composer autoloader is registered with a higher priority than the Jetpack Autoloader and would also handle some of the classes we handle (e.g. $classname => $path). This may cause strange and confusing problems."; - wp_trigger_error( '', $msg ); - continue 2; - } - } - foreach ( $composer_autoloader->getPrefixesPsr4() as $prefix => $paths ) { - if ( isset( $prefixes[ $prefix ] ) ) { - $path = array_pop( $paths ); - $msg = "A Composer autoloader is registered with a higher priority than the Jetpack Autoloader and would also handle some of the namespaces we handle (e.g. $prefix => $path). This may cause strange and confusing problems."; - wp_trigger_error( '', $msg ); - continue 2; - } - } - foreach ( $composer_autoloader->getPrefixes() as $prefix => $paths ) { - if ( isset( $prefixes[ $prefix ] ) ) { - $path = array_pop( $paths ); - $msg = "A Composer autoloader is registered with a higher priority than the Jetpack Autoloader and would also handle some of the namespaces we handle (e.g. $prefix => $path). This may cause strange and confusing problems."; - wp_trigger_error( '', $msg ); - continue 2; - } - } - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-manifest-reader.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-manifest-reader.php deleted file mode 100644 index e42d1509..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-manifest-reader.php +++ /dev/null @@ -1,99 +0,0 @@ -version_selector = $version_selector; - } - - /** - * Reads all of the manifests in the given plugin paths. - * - * @param array $plugin_paths The paths to the plugins we're loading the manifest in. - * @param string $manifest_path The path that we're loading the manifest from in each plugin. - * @param array $path_map The path map to add the contents of the manifests to. - * - * @return array $path_map The path map we've built using the manifests in each plugin. - */ - public function read_manifests( $plugin_paths, $manifest_path, &$path_map ) { - $file_paths = array_map( - function ( $path ) use ( $manifest_path ) { - return trailingslashit( $path ) . $manifest_path; - }, - $plugin_paths - ); - - foreach ( $file_paths as $path ) { - $this->register_manifest( $path, $path_map ); - } - - return $path_map; - } - - /** - * Registers a plugin's manifest file with the path map. - * - * @param string $manifest_path The absolute path to the manifest that we're loading. - * @param array $path_map The path map to add the contents of the manifest to. - */ - protected function register_manifest( $manifest_path, &$path_map ) { - if ( ! is_readable( $manifest_path ) ) { - return; - } - - $manifest = require $manifest_path; - if ( ! is_array( $manifest ) ) { - return; - } - - foreach ( $manifest as $key => $data ) { - $this->register_record( $key, $data, $path_map ); - } - } - - /** - * Registers an entry from the manifest in the path map. - * - * @param string $key The identifier for the entry we're registering. - * @param array $data The data for the entry we're registering. - * @param array $path_map The path map to add the contents of the manifest to. - */ - protected function register_record( $key, $data, &$path_map ) { - if ( isset( $path_map[ $key ]['version'] ) ) { - $selected_version = $path_map[ $key ]['version']; - } else { - $selected_version = null; - } - - if ( $this->version_selector->is_version_update_required( $selected_version, $data['version'] ) ) { - $path_map[ $key ] = array( - 'version' => $data['version'], - 'path' => $data['path'], - ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-path-processor.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-path-processor.php deleted file mode 100644 index 2fa5014f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-path-processor.php +++ /dev/null @@ -1,194 +0,0 @@ -get_normalized_constants(); - foreach ( $constants as $constant => $constant_path ) { - $len = strlen( $constant_path ); - if ( substr( $path, 0, $len ) !== $constant_path ) { - continue; - } - - return substr_replace( $path, '{{' . $constant . '}}', 0, $len ); - } - - return $path; - } - - /** - * Given a path this will replace any of the path constant tokens with the expanded path. - * - * @param string $tokenized_path The path we want to process. - * - * @return string The expanded path. - */ - public function untokenize_path_constants( $tokenized_path ) { - $tokenized_path = wp_normalize_path( $tokenized_path ); - - $constants = $this->get_normalized_constants(); - foreach ( $constants as $constant => $constant_path ) { - $constant = '{{' . $constant . '}}'; - - $len = strlen( $constant ); - if ( substr( $tokenized_path, 0, $len ) !== $constant ) { - continue; - } - - return $this->get_real_path( substr_replace( $tokenized_path, $constant_path, 0, $len ) ); - } - - return $tokenized_path; - } - - /** - * Given a file and an array of places it might be, this will find the absolute path and return it. - * - * @param string $file The plugin or theme file to resolve. - * @param array $directories_to_check The directories we should check for the file if it isn't an absolute path. - * - * @return string|false Returns the absolute path to the directory, otherwise false. - */ - public function find_directory_with_autoloader( $file, $directories_to_check ) { - $file = wp_normalize_path( $file ); - - if ( ! $this->is_absolute_path( $file ) ) { - $file = $this->find_absolute_plugin_path( $file, $directories_to_check ); - if ( ! isset( $file ) ) { - return false; - } - } - - // We need the real path for consistency with __DIR__ paths. - $file = $this->get_real_path( $file ); - - // phpcs:disable WordPress.PHP.NoSilencedErrors.Discouraged - $directory = @is_file( $file ) ? dirname( $file ) : $file; - if ( ! @is_file( $directory . '/vendor/composer/jetpack_autoload_classmap.php' ) ) { - return false; - } - // phpcs:enable WordPress.PHP.NoSilencedErrors.Discouraged - - return $directory; - } - - /** - * Fetches an array of normalized paths keyed by the constant they came from. - * - * @return string[] The normalized paths keyed by the constant. - */ - private function get_normalized_constants() { - $raw_constants = array( - // Order the constants from most-specific to least-specific. - 'WP_PLUGIN_DIR', - 'WPMU_PLUGIN_DIR', - 'WP_CONTENT_DIR', - 'ABSPATH', - ); - - $constants = array(); - foreach ( $raw_constants as $raw ) { - if ( ! defined( $raw ) ) { - continue; - } - - $path = wp_normalize_path( constant( $raw ) ); - if ( isset( $path ) ) { - $constants[ $raw ] = $path; - } - } - - return $constants; - } - - /** - * Indicates whether or not a path is absolute. - * - * @param string $path The path to check. - * - * @return bool True if the path is absolute, otherwise false. - */ - private function is_absolute_path( $path ) { - if ( empty( $path ) || 0 === strlen( $path ) || '.' === $path[0] ) { - return false; - } - - // Absolute paths on Windows may begin with a drive letter. - if ( preg_match( '/^[a-zA-Z]:[\/\\\\]/', $path ) ) { - return true; - } - - // A path starting with / or \ is absolute; anything else is relative. - return ( '/' === $path[0] || '\\' === $path[0] ); - } - - /** - * Given a file and a list of directories to check, this method will try to figure out - * the absolute path to the file in question. - * - * @param string $normalized_path The normalized path to the plugin or theme file to resolve. - * @param array $directories_to_check The directories we should check for the file if it isn't an absolute path. - * - * @return string|null The absolute path to the plugin file, otherwise null. - */ - private function find_absolute_plugin_path( $normalized_path, $directories_to_check ) { - // We're only able to find the absolute path for plugin/theme PHP files. - if ( ! is_string( $normalized_path ) || '.php' !== substr( $normalized_path, -4 ) ) { - return null; - } - - foreach ( $directories_to_check as $directory ) { - $normalized_check = wp_normalize_path( trailingslashit( $directory ) ) . $normalized_path; - // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged - if ( @is_file( $normalized_check ) ) { - return $normalized_check; - } - } - - return null; - } - - /** - * Given a path this will figure out the real path that we should be using. - * - * @param string $path The path to resolve. - * - * @return string The resolved path. - */ - private function get_real_path( $path ) { - // We want to resolve symbolic links for consistency with __DIR__ paths. - // phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged - $real_path = @realpath( $path ); - if ( false === $real_path ) { - // Let the autoloader deal with paths that don't exist. - $real_path = $path; - } - - // Using realpath will make it platform-specific so we must normalize it after. - if ( $path !== $real_path ) { - $real_path = wp_normalize_path( $real_path ); - } - - return $real_path; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-php-autoloader.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-php-autoloader.php deleted file mode 100644 index 22de29a4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-php-autoloader.php +++ /dev/null @@ -1,105 +0,0 @@ -unregister_autoloader(); - - // Set the global so that it can be used to load classes. - global $jetpack_autoloader_loader; - $jetpack_autoloader_loader = $version_loader; - - // Ensure that the autoloader is first to avoid contention with others. - spl_autoload_register( array( self::class, 'load_class' ), true, true ); - } - - /** - * Unregisters the active autoloader so that it will no longer autoload classes. - */ - public function unregister_autoloader() { - // Remove any v2 autoloader that we've already registered. - $autoload_chain = spl_autoload_functions(); - if ( ! $autoload_chain ) { - return; - } - foreach ( $autoload_chain as $autoloader ) { - // We can identify a v2 autoloader using the namespace. - $namespace_check = null; - - // Functions are recorded as strings. - if ( is_string( $autoloader ) ) { - $namespace_check = $autoloader; - } elseif ( is_array( $autoloader ) && is_string( $autoloader[0] ) ) { - // Static method calls have the class as the first array element. - $namespace_check = $autoloader[0]; - } else { - // Since the autoloader has only ever been a function or a static method we don't currently need to check anything else. - continue; - } - - // Check for the namespace without the generated suffix. - if ( 'Automattic\\Jetpack\\Autoloader\\jp' === substr( $namespace_check, 0, 32 ) ) { - spl_autoload_unregister( $autoloader ); - } - } - - // Clear the global now that the autoloader has been unregistered. - global $jetpack_autoloader_loader; - $jetpack_autoloader_loader = null; - } - - /** - * Loads a class file if one could be found. - * - * Note: This function is static so that the autoloader can be easily unregistered. If - * it was a class method we would have to unwrap the object to check the namespace. - * - * @param string $class_name The name of the class to autoload. - * - * @return bool Indicates whether or not a class file was loaded. - */ - public static function load_class( $class_name ) { - global $jetpack_autoloader_loader; - if ( ! isset( $jetpack_autoloader_loader ) ) { - return false; - } - - $file = $jetpack_autoloader_loader->find_class_file( $class_name ); - if ( ! isset( $file ) ) { - return false; - } - - // A common source of strange and confusing problems is when a vendor - // file is autoloaded before all plugins have had a chance to register - // with the autoloader. Detect that, if a development constant is set. - if ( defined( 'JETPACK_AUTOLOAD_DEBUG_EARLY_LOADS' ) && JETPACK_AUTOLOAD_DEBUG_EARLY_LOADS && - ( strpos( $file, '/vendor/' ) !== false || strpos( $file, '/jetpack_vendor/' ) !== false ) && - is_callable( 'did_action' ) && ! did_action( 'plugins_loaded' ) - ) { - // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_wp_debug_backtrace_summary -- This is a debug log message. - $msg = "Jetpack Autoloader: Autoloading `$class_name` before the plugins_loaded hook may cause strange and confusing problems. " . wp_debug_backtrace_summary( '', 1 ); - wp_trigger_error( '', $msg ); - } - - require $file; - return true; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugin-locator.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugin-locator.php deleted file mode 100644 index a72d0a01..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugin-locator.php +++ /dev/null @@ -1,153 +0,0 @@ -path_processor = $path_processor; - } - - /** - * Finds the path to the current plugin. - * - * @return string $path The path to the current plugin. - * - * @throws \RuntimeException If the current plugin does not have an autoloader. - */ - public function find_current_plugin() { - // Escape from `vendor/__DIR__` to root plugin directory. - $plugin_directory = dirname( __DIR__, 2 ); - - // Use the path processor to ensure that this is an autoloader we're referencing. - $path = $this->path_processor->find_directory_with_autoloader( $plugin_directory, array() ); - if ( false === $path ) { - throw new \RuntimeException( 'Failed to locate plugin ' . $plugin_directory ); - } - - return $path; - } - - /** - * Checks a given option for plugin paths. - * - * @param string $option_name The option that we want to check for plugin information. - * @param bool $site_option Indicates whether or not we want to check the site option. - * - * @return array $plugin_paths The list of absolute paths we've found. - */ - public function find_using_option( $option_name, $site_option = false ) { - $raw = $site_option ? get_site_option( $option_name ) : get_option( $option_name ); - if ( false === $raw ) { - return array(); - } - - return $this->convert_plugins_to_paths( $raw ); - } - - /** - * Checks for plugins in the `action` request parameter. - * - * @param string[] $allowed_actions The actions that we're allowed to return plugins for. - * - * @return array $plugin_paths The list of absolute paths we've found. - */ - public function find_using_request_action( $allowed_actions ) { - /** - * Note: we're not actually checking the nonce here because it's too early - * in the execution. The pluggable functions are not yet loaded to give - * plugins a chance to plug their versions. Therefore we're doing the bare - * minimum: checking whether the nonce exists and it's in the right place. - * The request will fail later if the nonce doesn't pass the check. - */ - if ( empty( $_REQUEST['_wpnonce'] ) ) { - return array(); - } - - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated just below. - $action = isset( $_REQUEST['action'] ) ? wp_unslash( $_REQUEST['action'] ) : false; - if ( ! in_array( $action, $allowed_actions, true ) ) { - return array(); - } - - $plugin_slugs = array(); - switch ( $action ) { - case 'activate': - case 'deactivate': - if ( empty( $_REQUEST['plugin'] ) ) { - break; - } - - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated by convert_plugins_to_paths. - $plugin_slugs[] = wp_unslash( $_REQUEST['plugin'] ); - break; - - case 'activate-selected': - case 'deactivate-selected': - if ( empty( $_REQUEST['checked'] ) ) { - break; - } - - // phpcs:ignore WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Validated by convert_plugins_to_paths. - $plugin_slugs = wp_unslash( $_REQUEST['checked'] ); - break; - } - - return $this->convert_plugins_to_paths( $plugin_slugs ); - } - - /** - * Given an array of plugin slugs or paths, this will convert them to absolute paths and filter - * out the plugins that are not directory plugins. Note that array keys will also be included - * if they are plugin paths! - * - * @param string[] $plugins Plugin paths or slugs to filter. - * - * @return string[] - */ - private function convert_plugins_to_paths( $plugins ) { - if ( ! is_array( $plugins ) || empty( $plugins ) ) { - return array(); - } - - // We're going to look for plugins in the standard directories. - $path_constants = array( WP_PLUGIN_DIR, WPMU_PLUGIN_DIR ); - - $plugin_paths = array(); - foreach ( $plugins as $key => $value ) { - $path = $this->path_processor->find_directory_with_autoloader( $key, $path_constants ); - if ( $path ) { - $plugin_paths[] = $path; - } - - $path = $this->path_processor->find_directory_with_autoloader( $value, $path_constants ); - if ( $path ) { - $plugin_paths[] = $path; - } - } - - return $plugin_paths; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugins-handler.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugins-handler.php deleted file mode 100644 index e6e03871..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-plugins-handler.php +++ /dev/null @@ -1,164 +0,0 @@ -plugin_locator = $plugin_locator; - $this->path_processor = $path_processor; - } - - /** - * Gets all of the active plugins we can find. - * - * @param bool $include_deactivating When true, plugins deactivating this request will be considered active. - * @param bool $record_unknown When true, the current plugin will be marked as active and recorded when unknown. - * - * @return string[] - */ - public function get_active_plugins( $include_deactivating, $record_unknown ) { - global $jetpack_autoloader_activating_plugins_paths; - - // We're going to build a unique list of plugins from a few different sources - // to find all of our "active" plugins. While we need to return an integer - // array, we're going to use an associative array internally to reduce - // the amount of time that we're going to spend checking uniqueness - // and merging different arrays together to form the output. - $active_plugins = array(); - - // Make sure that plugins which have activated this request are considered as "active" even though - // they probably won't be present in any option. - if ( is_array( $jetpack_autoloader_activating_plugins_paths ) ) { - foreach ( $jetpack_autoloader_activating_plugins_paths as $path ) { - $active_plugins[ $path ] = $path; - } - } - - // This option contains all of the plugins that have been activated. - $plugins = $this->plugin_locator->find_using_option( 'active_plugins' ); - foreach ( $plugins as $path ) { - $active_plugins[ $path ] = $path; - } - - // This option contains all of the multisite plugins that have been activated. - if ( is_multisite() ) { - $plugins = $this->plugin_locator->find_using_option( 'active_sitewide_plugins', true ); - foreach ( $plugins as $path ) { - $active_plugins[ $path ] = $path; - } - } - - // These actions contain plugins that are being activated/deactivated during this request. - $plugins = $this->plugin_locator->find_using_request_action( array( 'activate', 'activate-selected', 'deactivate', 'deactivate-selected' ) ); - foreach ( $plugins as $path ) { - $active_plugins[ $path ] = $path; - } - - // When the current plugin isn't considered "active" there's a problem. - // Since we're here, the plugin is active and currently being loaded. - // We can support this case (mu-plugins and non-standard activation) - // by adding the current plugin to the active list and marking it - // as an unknown (activating) plugin. This also has the benefit - // of causing a reset because the active plugins list has - // been changed since it was saved in the global. - $current_plugin = $this->plugin_locator->find_current_plugin(); - if ( $record_unknown && ! in_array( $current_plugin, $active_plugins, true ) ) { - $active_plugins[ $current_plugin ] = $current_plugin; - $jetpack_autoloader_activating_plugins_paths[] = $current_plugin; - } - - // When deactivating plugins aren't desired we should entirely remove them from the active list. - if ( ! $include_deactivating ) { - // These actions contain plugins that are being deactivated during this request. - $plugins = $this->plugin_locator->find_using_request_action( array( 'deactivate', 'deactivate-selected' ) ); - foreach ( $plugins as $path ) { - unset( $active_plugins[ $path ] ); - } - } - - // Transform the array so that we don't have to worry about the keys interacting with other array types later. - return array_values( $active_plugins ); - } - - /** - * Gets all of the cached plugins if there are any. - * - * @return string[] - */ - public function get_cached_plugins() { - $cached = get_transient( self::TRANSIENT_KEY ); - if ( ! is_array( $cached ) || empty( $cached ) ) { - return array(); - } - - // We need to expand the tokens to an absolute path for this webserver. - return array_map( array( $this->path_processor, 'untokenize_path_constants' ), $cached ); - } - - /** - * Saves the plugin list to the cache. - * - * @param array $plugins The plugin list to save to the cache. - */ - public function cache_plugins( $plugins ) { - // We store the paths in a tokenized form so that that webservers with different absolute paths don't break. - $plugins = array_map( array( $this->path_processor, 'tokenize_path_constants' ), $plugins ); - - set_transient( self::TRANSIENT_KEY, $plugins ); - } - - /** - * Checks to see whether or not the plugin list given has changed when compared to the - * shared `$jetpack_autoloader_cached_plugin_paths` global. This allows us to deal - * with cases where the active list may change due to filtering.. - * - * @param string[] $plugins The plugins list to check against the global cache. - * - * @return bool True if the plugins have changed, otherwise false. - */ - public function have_plugins_changed( $plugins ) { - global $jetpack_autoloader_cached_plugin_paths; - - if ( $jetpack_autoloader_cached_plugin_paths !== $plugins ) { - $jetpack_autoloader_cached_plugin_paths = $plugins; - return true; - } - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-shutdown-handler.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-shutdown-handler.php deleted file mode 100644 index 3d9c7e9f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-shutdown-handler.php +++ /dev/null @@ -1,92 +0,0 @@ -plugins_handler = $plugins_handler; - $this->cached_plugins = $cached_plugins; - $this->was_included_by_autoloader = $was_included_by_autoloader; - } - - /** - * Handles the shutdown of the autoloader. - */ - public function __invoke() { - // Don't save a broken cache if an error happens during some plugin's initialization. - if ( ! did_action( 'plugins_loaded' ) ) { - // Ensure that the cache is emptied to prevent consecutive failures if the cache is to blame. - if ( ! empty( $this->cached_plugins ) ) { - $this->plugins_handler->cache_plugins( array() ); - } - - return; - } - - // Load the active plugins fresh since the list we pulled earlier might not contain - // plugins that were activated but did not reset the autoloader. This happens - // when a plugin is in the cache but not "active" when the autoloader loads. - // We also want to make sure that plugins which are deactivating are not - // considered "active" so that they will be removed from the cache now. - try { - $active_plugins = $this->plugins_handler->get_active_plugins( false, ! $this->was_included_by_autoloader ); - } catch ( \Exception $ex ) { - // When the package is deleted before shutdown it will throw an exception. - // In the event this happens we should erase the cache. - if ( ! empty( $this->cached_plugins ) ) { - $this->plugins_handler->cache_plugins( array() ); - } - return; - } - - // The paths should be sorted for easy comparisons with those loaded from the cache. - // Note we don't need to sort the cached entries because they're already sorted. - sort( $active_plugins ); - - // We don't want to waste time saving a cache that hasn't changed. - if ( $this->cached_plugins === $active_plugins ) { - return; - } - - $this->plugins_handler->cache_plugins( $active_plugins ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-loader.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-loader.php deleted file mode 100644 index b508506a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-loader.php +++ /dev/null @@ -1,184 +0,0 @@ -version_selector = $version_selector; - $this->classmap = $classmap; - $this->psr4_map = $psr4_map; - $this->filemap = $filemap; - } - - /** - * Fetch the classmap. - * - * @since 3.1.0 - * @return array - */ - public function get_class_map() { - return $this->classmap; - } - - /** - * Fetch the psr-4 mappings. - * - * @since 3.1.0 - * @return array - */ - public function get_psr4_map() { - return $this->psr4_map; - } - - /** - * Finds the file path for the given class. - * - * @param string $class_name The class to find. - * - * @return string|null $file_path The path to the file if found, null if no class was found. - */ - public function find_class_file( $class_name ) { - $data = $this->select_newest_file( - $this->classmap[ $class_name ] ?? null, - $this->find_psr4_file( $class_name ) - ); - if ( ! isset( $data ) ) { - return null; - } - - return $data['path']; - } - - /** - * Load all of the files in the filemap. - */ - public function load_filemap() { - if ( empty( $this->filemap ) ) { - return; - } - - foreach ( $this->filemap as $file_identifier => $file_data ) { - if ( empty( $GLOBALS['__composer_autoload_files'][ $file_identifier ] ) ) { - require_once $file_data['path']; - - $GLOBALS['__composer_autoload_files'][ $file_identifier ] = true; - } - } - } - - /** - * Compares different class sources and returns the newest. - * - * @param array|null $classmap_data The classmap class data. - * @param array|null $psr4_data The PSR-4 class data. - * - * @return array|null $data - */ - private function select_newest_file( $classmap_data, $psr4_data ) { - if ( ! isset( $classmap_data ) ) { - return $psr4_data; - } elseif ( ! isset( $psr4_data ) ) { - return $classmap_data; - } - - if ( $this->version_selector->is_version_update_required( $classmap_data['version'], $psr4_data['version'] ) ) { - return $psr4_data; - } - - return $classmap_data; - } - - /** - * Finds the file for a given class in a PSR-4 namespace. - * - * @param string $class_name The class to find. - * - * @return array|null $data The version and path path to the file if found, null otherwise. - */ - private function find_psr4_file( $class_name ) { - if ( empty( $this->psr4_map ) ) { - return null; - } - - // Don't bother with classes that have no namespace. - $class_index = strrpos( $class_name, '\\' ); - if ( ! $class_index ) { - return null; - } - $class_for_path = str_replace( '\\', '/', $class_name ); - - // Search for the namespace by iteratively cutting off the last segment until - // we find a match. This allows us to check the most-specific namespaces - // first as well as minimize the amount of time spent looking. - for ( - $class_namespace = substr( $class_name, 0, $class_index ); - ! empty( $class_namespace ); - $class_namespace = substr( $class_namespace, 0, strrpos( $class_namespace, '\\' ) ) - ) { - $namespace = $class_namespace . '\\'; - if ( ! isset( $this->psr4_map[ $namespace ] ) ) { - continue; - } - $data = $this->psr4_map[ $namespace ]; - - foreach ( $data['path'] as $path ) { - $path .= '/' . substr( $class_for_path, strlen( $namespace ) ) . '.php'; - if ( file_exists( $path ) ) { - return array( - 'version' => $data['version'], - 'path' => $path, - ); - } - } - } - - return null; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-selector.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-selector.php deleted file mode 100644 index 0e57258a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/jetpack-autoloader/class-version-selector.php +++ /dev/null @@ -1,69 +0,0 @@ -is_dev_version( $selected_version ) ) { - return false; - } - - if ( $this->is_dev_version( $compare_version ) ) { - if ( $use_dev_versions ) { - return true; - } else { - return false; - } - } - - if ( version_compare( $selected_version, $compare_version, '<' ) ) { - return true; - } - - return false; - } - - /** - * Checks whether the given package version is a development version. - * - * @param String $version The package version. - * - * @return bool True if the version is a dev version, else false. - */ - public function is_dev_version( $version ) { - if ( 'dev-' === substr( $version, 0, 4 ) || '9999999-dev' === $version ) { - return true; - } - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/LICENSE b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/LICENSE deleted file mode 100644 index d6456956..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/LICENSE +++ /dev/null @@ -1,202 +0,0 @@ - - Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "[]" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright [yyyy] [name of copyright owner] - - Licensed under the Apache License, Version 2.0 (the "License"); - you may not use this file except in compliance with the License. - You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/NOTICE b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/NOTICE deleted file mode 100644 index 344d6275..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/NOTICE +++ /dev/null @@ -1,2 +0,0 @@ -AhoCorasick PHP Library -Copyright 2015 Ori Livneh diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/bench/bench.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/bench/bench.php deleted file mode 100644 index 499899a8..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/bench/bench.php +++ /dev/null @@ -1,75 +0,0 @@ -searchAndReplace( $text ); - } - $endTime = microtime( true ); - $wallTime = 1000 * ( ( $endTime - $startTime ) / $loops ); - printf( "%-'.40s %.2fms\n", 'MultiStringRepeater::searchAndReplace(): ', $wallTime ); - if ( $profile ) { - $profile = xhprof_disable(); - foreach ( $profile as $func => $data ) { - printf( "%s: %.2f\n", $func, $data['cpu'] / $data['ct'] ); - } - } -} - -if ( function_exists( 'fss_prep_replace' ) && isset( $options['fss'] ) ) { - $fss = fss_prep_replace( $zh2Hant ); - $startTime = microtime( true ); - for ( $i = 0; $i < $loops; $i++ ) { - fss_exec_replace( $fss, $text ); - } - $endTime = microtime( true ); - $wallTime = 1000 * ( ( $endTime - $startTime ) / $loops ); - printf( "%-'.40s %.2fms\n", 'fss_exec_replace(): ', $wallTime ); -} - -if ( isset( $options['strtr'] ) ) { - $startTime = microtime( true ); - for ( $i = 0; $i < $loops; $i++ ) { - strtr( $text, $zh2Hant ); - } - $endTime = microtime( true ); - $wallTime = 1000 * ( ( $endTime - $startTime ) / $loops ); - printf( "%-'.40s %.2fms\n", 'strtr(): ', $wallTime ); -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/bench/check.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/bench/check.php deleted file mode 100644 index 1cb6384e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/bench/check.php +++ /dev/null @@ -1,42 +0,0 @@ -searchAndReplace( $text ) !== $expected ) { - echo "ERROR\n"; - $status = 1; -} else { - echo "OK\n"; -} - -if ( function_exists( 'fss_exec_replace' ) ) { - echo "fss_exec_replace(): "; - $fss = fss_prep_replace( $zh2Hant ); - if ( fss_exec_replace( $fss, $text ) !== $expected ) { - echo "ERROR\n"; - $status = 1; - } else { - echo "OK\n"; - } -} - -exit( $status ); diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/src/MultiStringMatcher.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/src/MultiStringMatcher.php deleted file mode 100644 index b2953c4d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/src/MultiStringMatcher.php +++ /dev/null @@ -1,230 +0,0 @@ - - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * @file - * @author Ori Livneh - */ - -namespace AhoCorasick; - -/** - * Represents a finite state machine that can find all occurrences - * of a set of search keywords in a body of text. - * - * The time it takes to construct the finite state machine is - * proportional to the sum of the lengths of the search keywords. - * Once constructed, the machine can locate all occurences of all - * search keywords in a body of text in a single pass, making exactly - * one state transition per input character. - * - * This is an implementation of the Aho-Corasick string matching - * algorithm. - * - * Alfred V. Aho and Margaret J. Corasick, "Efficient string matching: - * an aid to bibliographic search", CACM, 18(6):333-340, June 1975. - * - * @link http://xlinux.nist.gov/dads//HTML/ahoCorasick.html - */ -class MultiStringMatcher { - - /** @var string[] The set of keywords to be searched for. **/ - protected $searchKeywords = []; - - /** @var int The number of possible states of the string-matching finite state machine. **/ - protected $numStates = 1; - - /** @var array Mapping of states to outputs. **/ - protected $outputs = []; - - /** @var array Mapping of failure transitions. **/ - protected $noTransitions = []; - - /** @var array Mapping of success transitions. **/ - protected $yesTransitions = []; - - /** - * Constructor. - * - * @param string[] $searchKeywords The set of keywords to be matched. - */ - public function __construct( array $searchKeywords ) { - foreach ( $searchKeywords as $keyword ) { - if ( $keyword !== '' ) { - $this->searchKeywords[$keyword] = strlen( $keyword ); - } - } - - if ( !$this->searchKeywords ) { - trigger_error( __METHOD__ . ': The set of search keywords is empty.', E_USER_WARNING ); - // Unreachable 'return' when PHPUnit detects trigger_error - return; // @codeCoverageIgnore - } - - $this->computeYesTransitions(); - $this->computeNoTransitions(); - } - - /** - * Accessor for the search keywords. - * - * @return string[] Search keywords. - */ - public function getKeywords() { - return array_keys( $this->searchKeywords ); - } - - /** - * Map the current state and input character to the next state. - * - * @param int $currentState The current state of the string-matching - * automaton. - * @param string $inputChar The character the string-matching - * automaton is currently processing. - * @return int The state the automaton should transition to. - */ - public function nextState( $currentState, $inputChar ) { - $initialState = $currentState; - while ( true ) { - $transitions =& $this->yesTransitions[$currentState]; - if ( isset( $transitions[$inputChar] ) ) { - $nextState = $transitions[$inputChar]; - // Avoid failure transitions next time. - if ( $currentState !== $initialState ) { - $this->yesTransitions[$initialState][$inputChar] = $nextState; - } - return $nextState; - } - if ( $currentState === 0 ) { - return 0; - } - $currentState = $this->noTransitions[$currentState]; - } - // Unreachable outside 'while' - } // @codeCoverageIgnore - - /** - * Locate the search keywords in some text. - * - * @param string $text The string to search in. - * @return array[] An array of matches. Each match is a vector - * containing an integer offset and the matched keyword. - * - * @par Example: - * @code - * $keywords = new MultiStringMatcher( array( 'ore', 'hell' ) ); - * $keywords->searchIn( 'She sells sea shells by the sea shore.' ); - * // result: array( array( 15, 'hell' ), array( 34, 'ore' ) ) - * @endcode - */ - public function searchIn( $text ) { - if ( !$this->searchKeywords || $text === '' ) { - return []; // fast path - } - - $state = 0; - $results = []; - $length = strlen( $text ); - - for ( $i = 0; $i < $length; $i++ ) { - $ch = $text[$i]; - $state = $this->nextState( $state, $ch ); - foreach ( $this->outputs[$state] as $match ) { - $offset = $i - $this->searchKeywords[$match] + 1; - $results[] = [ $offset, $match ]; - } - } - - return $results; - } - - /** - * Get the state transitions which the string-matching automaton - * shall make as it advances through input text. - * - * Constructs a directed tree with a root node which represents the - * initial state of the string-matching automaton and from which a - * path exists which spells out each search keyword. - */ - protected function computeYesTransitions() { - $this->yesTransitions = [ [] ]; - $this->outputs = [ [] ]; - foreach ( $this->searchKeywords as $keyword => $length ) { - $state = 0; - for ( $i = 0; $i < $length; $i++ ) { - $ch = $keyword[$i]; - if ( !empty( $this->yesTransitions[$state][$ch] ) ) { - $state = $this->yesTransitions[$state][$ch]; - } else { - $this->yesTransitions[$state][$ch] = $this->numStates; - $this->yesTransitions[] = []; - $this->outputs[] = []; - $state = $this->numStates++; - } - } - - $this->outputs[$state][] = $keyword; - } - } - - /** - * Get the state transitions which the string-matching automaton - * shall make when a partial match proves false. - */ - protected function computeNoTransitions() { - $queue = []; - $this->noTransitions = []; - - foreach ( $this->yesTransitions[0] as $ch => $toState ) { - $queue[] = $toState; - $this->noTransitions[$toState] = 0; - } - - while ( true ) { - $fromState = array_shift( $queue ); - if ( $fromState === null ) { - break; - } - foreach ( $this->yesTransitions[$fromState] as $ch => $toState ) { - $queue[] = $toState; - $state = $this->noTransitions[$fromState]; - - while ( $state !== 0 && empty( $this->yesTransitions[$state][$ch] ) ) { - $state = $this->noTransitions[$state]; - } - - if ( isset( $this->yesTransitions[$state][$ch] ) ) { - $noState = $this->yesTransitions[$state][$ch]; - } else { - $noState = 0; - } - - $this->noTransitions[$toState] = $noState; - $this->outputs[$toState] = array_merge( - $this->outputs[$toState], $this->outputs[$noState] ); - } - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/src/MultiStringReplacer.php b/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/src/MultiStringReplacer.php deleted file mode 100644 index 6b7891f6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/jetpack-protect/vendor/wikimedia/aho-corasick/src/MultiStringReplacer.php +++ /dev/null @@ -1,96 +0,0 @@ - - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * - * @file - * @author Ori Livneh - */ - -namespace AhoCorasick; - -/** - * This class extends MultiStringMatcher, adding search and replace - * functionality. - */ -class MultiStringReplacer extends MultiStringMatcher { - - /** @var array Mapping of states to outputs. **/ - protected $replacePairs = []; - - /** - * Constructor. - * - * @param array $replacePairs array of ( 'from' => 'to' ) replacement pairs. - */ - public function __construct( array $replacePairs ) { - foreach ( $replacePairs as $keyword => $replacement ) { - if ( $keyword !== '' ) { - $this->replacePairs[$keyword] = $replacement; - } - } - parent::__construct( array_keys( $this->replacePairs ) ); - } - - /** - * Search and replace a set of keywords in some text. - * - * @param string $text The string to search in. - * @return string The input text with replacements. - * - * @par Example: - * @code - * $replacer = new MultiStringReplacer( array( 'csh' => 'sea shells' ) ); - * $replacer->searchAndReplace( 'She sells csh by the sea shore.' ); - * // result: 'She sells sea shells by the sea shore.' - * @endcode - */ - public function searchAndReplace( $text ) { - $state = 0; - $length = strlen( $text ); - $matches = []; - for ( $i = 0; $i < $length; $i++ ) { - $ch = $text[$i]; - $state = $this->nextState( $state, $ch ); - foreach ( $this->outputs[$state] as $match ) { - $offset = $i - $this->searchKeywords[$match] + 1; - $matches[$offset] = $match; - } - } - ksort( $matches ); - - $buf = ''; - $lastInsert = 0; - foreach ( $matches as $offset => $match ) { - if ( $offset >= $lastInsert ) { - $buf .= substr( $text, $lastInsert, $offset - $lastInsert ); - $buf .= $this->replacePairs[$match]; - $lastInsert = $offset + $this->searchKeywords[$match]; - } - } - $buf .= substr( $text, $lastInsert ); - - return $buf; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/CHANGELOG.md b/wp-content/upgrade-temp-backup/plugins/menu-icons/CHANGELOG.md deleted file mode 100644 index 20d17f01..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/CHANGELOG.md +++ /dev/null @@ -1,167 +0,0 @@ -##### [Version 0.13.17](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.16...v0.13.17) (2025-04-17) - -- Updated dependencies - -##### [Version 0.13.16](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.15...v0.13.16) (2024-11-07) - -- Updated dependencies - -##### [Version 0.13.15](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.14...v0.13.15) (2024-07-10) - -- Removed recommendations of unsupported plugins -- Fixed conditions for theme recommendation - -##### [Version 0.13.14](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.13...v0.13.14) (2024-05-14) - -- Enhanced security - -##### [Version 0.13.13](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.12...v0.13.13) (2024-04-18) - -### Improvements -​- **Updated internal dependencies:​​** Enhanced performance and security. - -##### [Version 0.13.12](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.11...v0.13.12) (2024-04-01) - -### Improvements -- **Updated internal dependencies** - -##### [Version 0.13.11](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.10...v0.13.11) (2024-03-29) - -### Fixes -- Updated internal dependencies -- Enhanced security - -##### [Version 0.13.10](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.9...v0.13.10) (2024-03-26) - -### Improvements -- Updated internal dependencies -- Improved readme to link to the public source files -- Filter promotions - -##### [Version 0.13.9](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.8...v0.13.9) (2024-02-23) - -### Fixes -- Updated dependencies -- Harden security - -##### [Version 0.13.8](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.7...v0.13.8) (2023-12-19) - -- SDK Updates -- Fixed global hide label issue - -##### [Version 0.13.7](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.6...v0.13.7) (2023-08-17) - -- Updated dependencies -- Fixed broken button layout issues in other languages - -##### [Version 0.13.6](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.5...v0.13.6) (2023-07-07) - -- Updated composer dependencies to address warning in the widgets section - -##### [Version 0.13.5](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.4...v0.13.5) (2023-03-30) - -- Updated Dependencies and WordPress core tested up to version 6.2 - -##### [Version 0.13.4](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.3...v0.13.4) (2023-03-01) - -Update dependencies - -##### [Version 0.13.3](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.2...v0.13.3) (2023-02-25) - -- Fix img width/height value, props @Htbaa -- Update dependencies - -##### [Version 0.13.2](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.1...v0.13.2) (2022-11-24) - -* Fix - update dependencies - -##### [Version 0.13.1](https://github.com/codeinwp/wp-menu-icons/compare/v0.13.0...v0.13.1) (2022-11-04) - -Tested with the WordPress 6.1 version - -#### [Version 0.13.0](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.12...v0.13.0) (2022-08-23) - -* Fix Neve upsells showing up inconsistently on edge cases -* Fix inconsistency with Font Awesome 5 and adds compatibility with 6th version -* Fix compatibility with JupiterX -* Update dependencies - -##### [Version 0.12.12](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.11...v0.12.12) (2022-05-27) - -- Fix the style handler conflict issue which breaks the arrow icon of the submenus on some themes -- Fix dismiss dashboard notice issue on some edge cases -- Fix compatibility with the Max Mega Menu plugin - -##### [Version 0.12.11](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.10...v0.12.11) (2022-03-16) - -Add font awesome 5 support -Enhance compatibility with Otter/Neve - -##### [Version 0.12.10](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.9...v0.12.10) (2022-02-07) - -- [Fix] Add support for alt attribute for SVG icons -- Tested up with WordPress 5.9 - -##### [Version 0.12.9](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.8...v0.12.9) (2021-08-04) - -* Tested compatibility with WordPress 5.8 - -##### [Version 0.12.8](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.7...v0.12.8) (2021-05-12) - -* Fix issue when the image is not accessible to fetch the width/height metadata. - -##### [Version 0.12.7](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.6...v0.12.7) (2021-05-07) - -Fix PHP fatal error when uploading SVG with the image uploader - -##### [Version 0.12.6](https://github.com/codeinwp/wp-menu-icons/compare/v0.12.5...v0.12.6) (2021-05-05) - -* Adds explicit width/height to icons to prevent layout shifts issues - -### v0.12.5 - 2020-08-18 - **Changes:** - - ### v0.12.4 - 2020-07-13 - **Changes:** - * Fix Font Awesome not loading - - ### v0.12.3 - 2020-07-13 - **Changes:** - * Fixed Menu Icons in Block Editor not working -* Fixed CWP links. - - ### v0.12.2 - 2019-11-15 - **Changes:** - - ### v0.12.1 - 2019-11-15 - **Changes:** - * Improve legacy compatibility - - ### v0.12.0 - 2019-11-15 - **Changes:** - * Fix issues with WordPress 5.3. - - ### v0.11.5 - 2019-05-23 - **Changes:** - * Sync composer dependencies with the latest version - - ### v0.11.4 - 2018-12-10 - **Changes:** - * fix issue with composer libraries. - - ### v0.11.3 - 2018-12-10 - **Changes:** - * Tested with WP 5.0 - - ### v0.11.2 - 2018-03-05 - **Changes:** - * Improve popup sidebar layout. - - ### v0.11.1 - 2018-02-24 - **Changes:** - * Add recommendation boxes in the menu icon popup. - - ### v0.11.0 - 2018-01-05 - **Changes:** - * Change ownership to ThemeIsle. -* Improves compatibility with various ThemeIsle products. diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/LICENSE b/wp-content/upgrade-temp-backup/plugins/menu-icons/LICENSE deleted file mode 100644 index d7f10513..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/LICENSE +++ /dev/null @@ -1,339 +0,0 @@ -GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -convey the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - {description} - Copyright (C) {year} {fullname} - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License along - with this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. - -Also add information on how to contact you by electronic and paper mail. - -If the program is interactive, make it output a short notice like this -when it starts in an interactive mode: - - Gnomovision version 69, Copyright (C) year name of author - Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, the commands you use may -be called something other than `show w' and `show c'; they could even be -mouse-clicks or menu items--whatever suits your program. - -You should also get your employer (if you work as a programmer) or your -school, if any, to sign a "copyright disclaimer" for the program, if -necessary. Here is a sample; alter the names: - - Yoyodyne, Inc., hereby disclaims all copyright interest in the program - `Gnomovision' (which makes passes at compilers) written by James Hacker. - - {signature of Ty Coon}, 1 April 1989 - Ty Coon, President of Vice - -This General Public License does not permit incorporating your program into -proprietary programs. If your program is a subroutine library, you may -consider it more useful to permit linking proprietary applications with the -library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/admin.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/admin.css deleted file mode 100644 index 288acd71..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/admin.css +++ /dev/null @@ -1,246 +0,0 @@ -.menu-icons-wrap { - margin-top: 5px; - margin-bottom: 5px; -} - -.menu-icons-wrap p { - min-height: 2.2em; - margin-bottom: 0; -} - -.menu-icons-wrap p a, -.menu-icons-wrap p label { - display: inline-block; - height: 100%; - line-height: 2.2em; - vertical-align: middle; -} - -.menu-icons-wrap a { - text-decoration: none; - cursor: pointer; -} - -.menu-icons-wrap .submitdelete { - display: inline-block; - float: none; - height: 100%; - margin: 0; - padding: 0; - line-height: 2.2em; -} - -.menu-icons-wrap .hidden { - display: none; -} - -.menu-icons-wrap ._icon { - width: auto; - height: auto; - margin: -0.1em 0.2em 0 0.2em; - color: #666; - font-size: 1.9em; - vertical-align: middle; -} - -.menu-icons-wrap img._icon { - max-width: 24px; -} - -.menu-icons-wrap a._select:focus ._icon, -.menu-icons-wrap a._select:hover ._icon { - color: #101010; -} - -.mi-preview.menu-item { - min-height: 0; - font-size: 1.2em; -} - -.mi-preview.menu-item a { - text-decoration: none; -} - -.mi-preview.menu-item a > * { - display: inline-block; - height: 100%; - line-height: 100%; - vertical-align: middle; -} - -.mi-preview.menu-item ._icon { - margin-right: 0.25em; -} - -.rtl .mi-preview.menu-item ._icon { - margin-right: 0; -} - -.media-sidebar .mi-settings .setting input[type="number"], -.menu-icons-settings input[type="number"] { - float: none; - width: auto; - max-width: 5em; -} - -.media-sidebar .mi-settings .setting input, -.media-sidebar .mi-settings span.description { - float: none; -} - -/** Settings Meta Box **/ -.menu-icons-settings ._field { - padding: 0.5em 0; -} - -.menu-icons-settings ._field ._main { - display: block; - margin-bottom: 0.25em; - font-weight: bold; -} - -#menu-settings-column .menu-icons-settings .inside { - margin-top: 0; -} - -.menu-icons-settings .taxonomydiv .tabs-panel { - max-height: none; - margin-bottom: 0.75em; - padding-top: 0.3em; - padding-bottom: 0.4em; -} - -.js .menu-icons-settings .taxonomydiv .tabs-panel { - margin-bottom: 0; -} - -.menu-icons-settings h4 { - margin: 0; -} - -.menu-icons-settings ._menu span.description { - margin-left: 0.5em; -} - -.menu-icons-settings ._extensions ul { - margin-top: 0.75em; - padding-left: 1.5em; - list-style: disc; -} - -.menu-icons-settings ._extensions ul a { - text-decoration: none; -} - -.menu-icons-settings .spinner { - float: none; - margin: 0 5px 0 0; - vertical-align: middle; -} - -.attachment .svg-icon img { - max-width: 100%; -} - -.nv-upgrade-notice { - width: 90%; - margin-top: 0; - padding: 15px; -} - -#menu-icons-sidebar div.new-card { - width: auto; - min-width: initial; - max-width: initial; - margin: 10px auto; -} - -.menu-icons-subscribe { - padding: 15px; -} - -.menu-icons-submit-mail { - width: auto; -} - -#success { - display: none; -} - -#failure { - display: none; -} - -.attachments-browser.iconpicker-fonts-browser .media-toolbar { - width: 62%; -} - -.attachments-browser.iconpicker-fonts-browser .attachments.iconpicker-items { - width: 64%; -} - -.attachments-browser.iconpicker-fonts-browser .media-sidebar { - width: 32%; -} - -.nv-upgrade-notice { - background: #FFFFFF; - border: 1px solid #E1E1E1; - box-sizing: border-box; - padding: 20px; - display: flex; - flex-wrap: wrap; -} - -.nv-upgrade-notice .menu-icon-notice-popup-img { - width: 115px; - height: 100px; - background-color: #f1f1f1; - margin-right: 20px; - margin-bottom: 20px; -} - -.nv-upgrade-notice .menu-icon-notice-popup-img img{ - width: 100%; - height: 100%; - object-fit: cover; -} - -.nv-upgrade-notice .menu-icon-notice-popup { - flex: 1; -} - -.nv-upgrade-notice .menu-icon-notice-popup h4{ - padding: 0; - margin: 0 0 8px; - font-weight: 590; - font-size: 14px; - line-height: 1.2; - color: #000000; - display: block; - width: 100%; -} - -.nv-upgrade-notice .menu-icon-notice-popup p { - font-size: 13px; - line-height: 1.2; - color: #000000; - margin: 0 0 16px; - display: block; - padding: 0; -} - -.nv-upgrade-notice .menu-icon-notice-popup .button { - width: auto; - height: 30px; - background: #0071AE; - border-radius: 4px; - padding: 5px 12px; - font-size: 13px; - line-height: 1.5; - color: #fff; -} - -.nv-upgrade-notice .menu-icon-notice-popup .button:hover { - color: #fff; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/admin.min.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/admin.min.css deleted file mode 100644 index 2d4fd049..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/admin.min.css +++ /dev/null @@ -1 +0,0 @@ -.menu-icons-wrap{margin-top:5px;margin-bottom:5px}.menu-icons-wrap p{min-height:2.2em;margin-bottom:0}.menu-icons-wrap p a,.menu-icons-wrap p label{display:inline-block;height:100%;line-height:2.2em;vertical-align:middle}.menu-icons-wrap a{text-decoration:none;cursor:pointer}.menu-icons-wrap .submitdelete{display:inline-block;float:none;height:100%;margin:0;padding:0;line-height:2.2em}.menu-icons-wrap .hidden{display:none}.menu-icons-wrap ._icon{width:auto;height:auto;margin:-.1em .2em 0 .2em;color:#666;font-size:1.9em;vertical-align:middle}.menu-icons-wrap img._icon{max-width:24px}.menu-icons-wrap a._select:focus ._icon,.menu-icons-wrap a._select:hover ._icon{color:#101010}.mi-preview.menu-item{min-height:0;font-size:1.2em}.mi-preview.menu-item a{text-decoration:none}.mi-preview.menu-item a>*{display:inline-block;height:100%;line-height:100%;vertical-align:middle}.mi-preview.menu-item ._icon{margin-right:.25em}.rtl .mi-preview.menu-item ._icon{margin-right:0}.media-sidebar .mi-settings .setting input[type=number],.menu-icons-settings input[type=number]{float:none;width:auto;max-width:5em}.media-sidebar .mi-settings .setting input,.media-sidebar .mi-settings span.description{float:none}.menu-icons-settings ._field{padding:.5em 0}.menu-icons-settings ._field ._main{display:block;margin-bottom:.25em;font-weight:700}#menu-settings-column .menu-icons-settings .inside{margin-top:0}.menu-icons-settings .taxonomydiv .tabs-panel{max-height:none;margin-bottom:.75em;padding-top:.3em;padding-bottom:.4em}.js .menu-icons-settings .taxonomydiv .tabs-panel{margin-bottom:0}.menu-icons-settings h4{margin:0}.menu-icons-settings ._menu span.description{margin-left:.5em}.menu-icons-settings ._extensions ul{margin-top:.75em;padding-left:1.5em;list-style:disc}.menu-icons-settings ._extensions ul a{text-decoration:none}.menu-icons-settings .spinner{float:none;margin:0 5px 0 0;vertical-align:middle}.attachment .svg-icon img{max-width:100%}.nv-upgrade-notice{width:90%;margin-top:0;padding:15px}#menu-icons-sidebar div.new-card{width:auto;min-width:initial;max-width:initial;margin:10px auto}.menu-icons-subscribe{padding:15px}.menu-icons-submit-mail{width:auto}#success{display:none}#failure{display:none}.attachments-browser.iconpicker-fonts-browser .media-toolbar{width:62%}.attachments-browser.iconpicker-fonts-browser .attachments.iconpicker-items{width:64%}.attachments-browser.iconpicker-fonts-browser .media-sidebar{width:32%}.nv-upgrade-notice{background:#fff;border:1px solid #e1e1e1;box-sizing:border-box;padding:20px;display:flex;flex-wrap:wrap}.nv-upgrade-notice .menu-icon-notice-popup-img{width:115px;height:100px;background-color:#f1f1f1;margin-right:20px;margin-bottom:20px}.nv-upgrade-notice .menu-icon-notice-popup-img img{width:100%;height:100%;object-fit:cover}.nv-upgrade-notice .menu-icon-notice-popup{flex:1}.nv-upgrade-notice .menu-icon-notice-popup h4{padding:0;margin:0 0 8px;font-weight:590;font-size:14px;line-height:1.2;color:#000;display:block;width:100%}.nv-upgrade-notice .menu-icon-notice-popup p{font-size:13px;line-height:1.2;color:#000;margin:0 0 16px;display:block;padding:0}.nv-upgrade-notice .menu-icon-notice-popup .button{width:auto;height:30px;background:#0071ae;border-radius:4px;padding:5px 12px;font-size:13px;line-height:1.5;color:#fff}.nv-upgrade-notice .menu-icon-notice-popup .button:hover{color:#fff} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.css deleted file mode 100644 index 7a937595..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.css +++ /dev/null @@ -1,45 +0,0 @@ -.menu-icon-dashboard-notice { - position: relative; - background: #FFFFFF; - border: 1px solid #E1E1E1; - box-sizing: border-box; - padding: 24px; - border-left: 4px solid #72AEE6; - margin: 0 0 30px; -} - -.menu-icon-dashboard-notice h2 { - padding: 0; - margin: 0 0 8px; - font-weight: bold; - font-size: 18px; - line-height: 1.2; - color: #000000; -} - -.menu-icon-dashboard-notice p { - font-size: 12px; - line-height: 1.2; - color: #000000; - display: block; - margin-bottom: 16px; -} - -.menu-icon-dashboard-notice .button { - display: flex; - flex-direction: row; - justify-content: center; - align-items: center; - padding: 5px 12px; - background: #0071AE; - border-radius: 4px; - display: inline-block; - width: auto; - height: 30px; - color: #FFFFFF; - font-size: 13px; - line-height: 1.5; -} -.menu-icon-dashboard-notice .notice-dismiss { - text-decoration: none; -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.min.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.min.css deleted file mode 100644 index 65ed114b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/dashboard-notice.min.css +++ /dev/null @@ -1 +0,0 @@ -.menu-icon-dashboard-notice{position:relative;background:#fff;border:1px solid #e1e1e1;box-sizing:border-box;padding:24px;border-left:4px solid #72aee6;margin:0 0 30px}.menu-icon-dashboard-notice h2{padding:0;margin:0 0 8px;font-weight:700;font-size:18px;line-height:1.2;color:#000}.menu-icon-dashboard-notice p{font-size:12px;line-height:1.2;color:#000;display:block;margin-bottom:16px}.menu-icon-dashboard-notice .button{display:flex;flex-direction:row;justify-content:center;align-items:center;padding:5px 12px;background:#0071ae;border-radius:4px;display:inline-block;width:auto;height:30px;color:#fff;font-size:13px;line-height:1.5}.menu-icon-dashboard-notice .notice-dismiss{text-decoration:none} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/extra.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/extra.css deleted file mode 100644 index ec8b2a60..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/extra.css +++ /dev/null @@ -1,74 +0,0 @@ -.menu-item i._mi, -.menu-item img._mi { - display: inline-block; - vertical-align: middle; -} - -.menu-item i._mi { - width: auto; - height: auto; - margin-top: -0.265em; - font-size: 1.2em; - line-height: 1; -} - -.menu-item i._before, -.rtl .menu-item i._after { - margin-right: 0.25em; -} - -.menu-item i._after, -.rtl .menu-item i._before { - margin-left: 0.25em; -} - -.menu-item img._before, -.rtl .menu-item img._after { - margin-right: 0.5em; -} - -.menu-item img._after, -.rtl .menu-item img._before { - margin-left: 0.5em; -} - -.menu-item ._svg { - width: 1em; -} - -.rtl .menu-item i._before { - margin-right: 0; -} - -.rtl .menu-item i._after { - margin-left: 0; -} - -.visuallyhidden { - overflow: hidden; - clip: rect(0 0 0 0); - position: absolute; - width: 1px; - height: 1px; - margin: -1px; - padding: 0; - border: 0; -} - -.menu-item i.elusive { - margin-top: -0.3em; -} - -/** - * Force the icons' styles - * - * Some themes -- notably 2014 -- has nasty rules that - * could override the icons' styles so we need to force them here. - */ -.dashicons-admin-site:before { - content: "\f319" !important; -} - -.dashicons-welcome-view-site:before { - content: "\f115" !important; -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/extra.min.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/extra.min.css deleted file mode 100644 index 7ff02d86..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/extra.min.css +++ /dev/null @@ -1 +0,0 @@ -.menu-item i._mi,.menu-item img._mi{display:inline-block;vertical-align:middle}.menu-item i._mi{width:auto;height:auto;margin-top:-.265em;font-size:1.2em;line-height:1}.menu-item i._before,.rtl .menu-item i._after{margin-right:.25em}.menu-item i._after,.rtl .menu-item i._before{margin-left:.25em}.menu-item img._before,.rtl .menu-item img._after{margin-right:.5em}.menu-item img._after,.rtl .menu-item img._before{margin-left:.5em}.menu-item ._svg{width:1em}.rtl .menu-item i._before{margin-right:0}.rtl .menu-item i._after{margin-left:0}.visuallyhidden{overflow:hidden;clip:rect(0 0 0 0);position:absolute;width:1px;height:1px;margin:-1px;padding:0;border:0}.menu-item i.elusive{margin-top:-.3em}.dashicons-admin-site:before{content:"\f319"!important}.dashicons-welcome-view-site:before{content:"\f115"!important} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/LICENSE.txt b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/LICENSE.txt deleted file mode 100644 index f31bef92..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/LICENSE.txt +++ /dev/null @@ -1,34 +0,0 @@ -Font Awesome Free License -------------------------- - -Font Awesome Free is free, open source, and GPL friendly. You can use it for -commercial projects, open source projects, or really almost whatever you want. -Full Font Awesome Free license: https://fontawesome.com/license/free. - -# Icons: CC BY 4.0 License (https://creativecommons.org/licenses/by/4.0/) -In the Font Awesome Free download, the CC BY 4.0 license applies to all icons -packaged as SVG and JS file types. - -# Fonts: SIL OFL 1.1 License (https://scripts.sil.org/OFL) -In the Font Awesome Free download, the SIL OFL license applies to all icons -packaged as web and desktop font files. - -# Code: MIT License (https://opensource.org/licenses/MIT) -In the Font Awesome Free download, the MIT license applies to all non-font and -non-icon files. - -# Attribution -Attribution is required by MIT, SIL OFL, and CC BY licenses. Downloaded Font -Awesome Free files already contain embedded comments with sufficient -attribution, so you shouldn't need to do anything additional when using these -files normally. - -We've kept attribution comments terse, so we ask that you do not actively work -to remove them from files, especially code. They're a great way for folks to -learn about Font Awesome. - -# Brand Icons -All brand icons are trademarks of their respective owners. The use of these -trademarks does not indicate endorsement of the trademark holder by Font -Awesome, nor vice versa. **Please do not use brand logos for any purpose except -to represent the company, product, or service to which they refer.** diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/css/all.min.css b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/css/all.min.css deleted file mode 100644 index b9a01fbb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/css/all.min.css +++ /dev/null @@ -1,6 +0,0 @@ -/*! - * Font Awesome Free 6.1.2 by @fontawesome - https://fontawesome.com - * License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) - * Copyright 2022 Fonticons, Inc. - */ -.fa{font-family:var(--fa-style-family,"Font Awesome 6 Free");font-weight:var(--fa-style,900)}.fa,.fa-brands,.fa-duotone,.fa-light,.fa-regular,.fa-solid,.fa-thin,.fab,.fad,.fal,.far,.fas,.fat{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;display:var(--fa-display,inline-block);font-style:normal;font-variant:normal;line-height:1;text-rendering:auto}.fa-1x{font-size:1em}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-6x{font-size:6em}.fa-7x{font-size:7em}.fa-8x{font-size:8em}.fa-9x{font-size:9em}.fa-10x{font-size:10em}.fa-2xs{font-size:.625em;line-height:.1em;vertical-align:.225em}.fa-xs{font-size:.75em;line-height:.08333em;vertical-align:.125em}.fa-sm{font-size:.875em;line-height:.07143em;vertical-align:.05357em}.fa-lg{font-size:1.25em;line-height:.05em;vertical-align:-.075em}.fa-xl{font-size:1.5em;line-height:.04167em;vertical-align:-.125em}.fa-2xl{font-size:2em;line-height:.03125em;vertical-align:-.1875em}.fa-fw{text-align:center;width:1.25em}.fa-ul{list-style-type:none;margin-left:var(--fa-li-margin,2.5em);padding-left:0}.fa-ul>li{position:relative}.fa-li{left:calc(var(--fa-li-width, 2em)*-1);position:absolute;text-align:center;width:var(--fa-li-width,2em);line-height:inherit}.fa-border{border-radius:var(--fa-border-radius,.1em);border:var(--fa-border-width,.08em) var(--fa-border-style,solid) var(--fa-border-color,#eee);padding:var(--fa-border-padding,.2em .25em .15em)}.fa-pull-left{float:left;margin-right:var(--fa-pull-margin,.3em)}.fa-pull-right{float:right;margin-left:var(--fa-pull-margin,.3em)}.fa-beat{-webkit-animation-name:fa-beat;animation-name:fa-beat;-webkit-animation-delay:var(--fa-animation-delay,0);animation-delay:var(--fa-animation-delay,0);-webkit-animation-direction:var(--fa-animation-direction,normal);animation-direction:var(--fa-animation-direction,normal);-webkit-animation-duration:var(--fa-animation-duration,1s);animation-duration:var(--fa-animation-duration,1s);-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,ease-in-out);animation-timing-function:var(--fa-animation-timing,ease-in-out)}.fa-bounce{-webkit-animation-name:fa-bounce;animation-name:fa-bounce;-webkit-animation-delay:var(--fa-animation-delay,0);animation-delay:var(--fa-animation-delay,0);-webkit-animation-direction:var(--fa-animation-direction,normal);animation-direction:var(--fa-animation-direction,normal);-webkit-animation-duration:var(--fa-animation-duration,1s);animation-duration:var(--fa-animation-duration,1s);-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,cubic-bezier(.28,.84,.42,1));animation-timing-function:var(--fa-animation-timing,cubic-bezier(.28,.84,.42,1))}.fa-fade{-webkit-animation-name:fa-fade;animation-name:fa-fade;-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,cubic-bezier(.4,0,.6,1));animation-timing-function:var(--fa-animation-timing,cubic-bezier(.4,0,.6,1))}.fa-beat-fade,.fa-fade{-webkit-animation-delay:var(--fa-animation-delay,0);animation-delay:var(--fa-animation-delay,0);-webkit-animation-direction:var(--fa-animation-direction,normal);animation-direction:var(--fa-animation-direction,normal);-webkit-animation-duration:var(--fa-animation-duration,1s);animation-duration:var(--fa-animation-duration,1s)}.fa-beat-fade{-webkit-animation-name:fa-beat-fade;animation-name:fa-beat-fade;-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,cubic-bezier(.4,0,.6,1));animation-timing-function:var(--fa-animation-timing,cubic-bezier(.4,0,.6,1))}.fa-flip{-webkit-animation-name:fa-flip;animation-name:fa-flip;-webkit-animation-delay:var(--fa-animation-delay,0);animation-delay:var(--fa-animation-delay,0);-webkit-animation-direction:var(--fa-animation-direction,normal);animation-direction:var(--fa-animation-direction,normal);-webkit-animation-duration:var(--fa-animation-duration,1s);animation-duration:var(--fa-animation-duration,1s);-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,ease-in-out);animation-timing-function:var(--fa-animation-timing,ease-in-out)}.fa-shake{-webkit-animation-name:fa-shake;animation-name:fa-shake;-webkit-animation-duration:var(--fa-animation-duration,1s);animation-duration:var(--fa-animation-duration,1s);-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,linear);animation-timing-function:var(--fa-animation-timing,linear)}.fa-shake,.fa-spin{-webkit-animation-delay:var(--fa-animation-delay,0);animation-delay:var(--fa-animation-delay,0);-webkit-animation-direction:var(--fa-animation-direction,normal);animation-direction:var(--fa-animation-direction,normal)}.fa-spin{-webkit-animation-name:fa-spin;animation-name:fa-spin;-webkit-animation-duration:var(--fa-animation-duration,2s);animation-duration:var(--fa-animation-duration,2s);-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,linear);animation-timing-function:var(--fa-animation-timing,linear)}.fa-spin-reverse{--fa-animation-direction:reverse}.fa-pulse,.fa-spin-pulse{-webkit-animation-name:fa-spin;animation-name:fa-spin;-webkit-animation-direction:var(--fa-animation-direction,normal);animation-direction:var(--fa-animation-direction,normal);-webkit-animation-duration:var(--fa-animation-duration,1s);animation-duration:var(--fa-animation-duration,1s);-webkit-animation-iteration-count:var(--fa-animation-iteration-count,infinite);animation-iteration-count:var(--fa-animation-iteration-count,infinite);-webkit-animation-timing-function:var(--fa-animation-timing,steps(8));animation-timing-function:var(--fa-animation-timing,steps(8))}@media (prefers-reduced-motion:reduce){.fa-beat,.fa-beat-fade,.fa-bounce,.fa-fade,.fa-flip,.fa-pulse,.fa-shake,.fa-spin,.fa-spin-pulse{-webkit-animation-delay:-1ms;animation-delay:-1ms;-webkit-animation-duration:1ms;animation-duration:1ms;-webkit-animation-iteration-count:1;animation-iteration-count:1;transition-delay:0s;transition-duration:0s}}@-webkit-keyframes fa-beat{0%,90%{-webkit-transform:scale(1);transform:scale(1)}45%{-webkit-transform:scale(var(--fa-beat-scale,1.25));transform:scale(var(--fa-beat-scale,1.25))}}@keyframes fa-beat{0%,90%{-webkit-transform:scale(1);transform:scale(1)}45%{-webkit-transform:scale(var(--fa-beat-scale,1.25));transform:scale(var(--fa-beat-scale,1.25))}}@-webkit-keyframes fa-bounce{0%{-webkit-transform:scale(1) translateY(0);transform:scale(1) translateY(0)}10%{-webkit-transform:scale(var(--fa-bounce-start-scale-x,1.1),var(--fa-bounce-start-scale-y,.9)) translateY(0);transform:scale(var(--fa-bounce-start-scale-x,1.1),var(--fa-bounce-start-scale-y,.9)) translateY(0)}30%{-webkit-transform:scale(var(--fa-bounce-jump-scale-x,.9),var(--fa-bounce-jump-scale-y,1.1)) translateY(var(--fa-bounce-height,-.5em));transform:scale(var(--fa-bounce-jump-scale-x,.9),var(--fa-bounce-jump-scale-y,1.1)) translateY(var(--fa-bounce-height,-.5em))}50%{-webkit-transform:scale(var(--fa-bounce-land-scale-x,1.05),var(--fa-bounce-land-scale-y,.95)) translateY(0);transform:scale(var(--fa-bounce-land-scale-x,1.05),var(--fa-bounce-land-scale-y,.95)) translateY(0)}57%{-webkit-transform:scale(1) translateY(var(--fa-bounce-rebound,-.125em));transform:scale(1) translateY(var(--fa-bounce-rebound,-.125em))}64%{-webkit-transform:scale(1) translateY(0);transform:scale(1) translateY(0)}to{-webkit-transform:scale(1) translateY(0);transform:scale(1) translateY(0)}}@keyframes fa-bounce{0%{-webkit-transform:scale(1) translateY(0);transform:scale(1) translateY(0)}10%{-webkit-transform:scale(var(--fa-bounce-start-scale-x,1.1),var(--fa-bounce-start-scale-y,.9)) translateY(0);transform:scale(var(--fa-bounce-start-scale-x,1.1),var(--fa-bounce-start-scale-y,.9)) translateY(0)}30%{-webkit-transform:scale(var(--fa-bounce-jump-scale-x,.9),var(--fa-bounce-jump-scale-y,1.1)) translateY(var(--fa-bounce-height,-.5em));transform:scale(var(--fa-bounce-jump-scale-x,.9),var(--fa-bounce-jump-scale-y,1.1)) translateY(var(--fa-bounce-height,-.5em))}50%{-webkit-transform:scale(var(--fa-bounce-land-scale-x,1.05),var(--fa-bounce-land-scale-y,.95)) translateY(0);transform:scale(var(--fa-bounce-land-scale-x,1.05),var(--fa-bounce-land-scale-y,.95)) translateY(0)}57%{-webkit-transform:scale(1) translateY(var(--fa-bounce-rebound,-.125em));transform:scale(1) translateY(var(--fa-bounce-rebound,-.125em))}64%{-webkit-transform:scale(1) translateY(0);transform:scale(1) translateY(0)}to{-webkit-transform:scale(1) translateY(0);transform:scale(1) translateY(0)}}@-webkit-keyframes fa-fade{50%{opacity:var(--fa-fade-opacity,.4)}}@keyframes fa-fade{50%{opacity:var(--fa-fade-opacity,.4)}}@-webkit-keyframes fa-beat-fade{0%,to{opacity:var(--fa-beat-fade-opacity,.4);-webkit-transform:scale(1);transform:scale(1)}50%{opacity:1;-webkit-transform:scale(var(--fa-beat-fade-scale,1.125));transform:scale(var(--fa-beat-fade-scale,1.125))}}@keyframes fa-beat-fade{0%,to{opacity:var(--fa-beat-fade-opacity,.4);-webkit-transform:scale(1);transform:scale(1)}50%{opacity:1;-webkit-transform:scale(var(--fa-beat-fade-scale,1.125));transform:scale(var(--fa-beat-fade-scale,1.125))}}@-webkit-keyframes fa-flip{50%{-webkit-transform:rotate3d(var(--fa-flip-x,0),var(--fa-flip-y,1),var(--fa-flip-z,0),var(--fa-flip-angle,-180deg));transform:rotate3d(var(--fa-flip-x,0),var(--fa-flip-y,1),var(--fa-flip-z,0),var(--fa-flip-angle,-180deg))}}@keyframes fa-flip{50%{-webkit-transform:rotate3d(var(--fa-flip-x,0),var(--fa-flip-y,1),var(--fa-flip-z,0),var(--fa-flip-angle,-180deg));transform:rotate3d(var(--fa-flip-x,0),var(--fa-flip-y,1),var(--fa-flip-z,0),var(--fa-flip-angle,-180deg))}}@-webkit-keyframes fa-shake{0%{-webkit-transform:rotate(-15deg);transform:rotate(-15deg)}4%{-webkit-transform:rotate(15deg);transform:rotate(15deg)}8%,24%{-webkit-transform:rotate(-18deg);transform:rotate(-18deg)}12%,28%{-webkit-transform:rotate(18deg);transform:rotate(18deg)}16%{-webkit-transform:rotate(-22deg);transform:rotate(-22deg)}20%{-webkit-transform:rotate(22deg);transform:rotate(22deg)}32%{-webkit-transform:rotate(-12deg);transform:rotate(-12deg)}36%{-webkit-transform:rotate(12deg);transform:rotate(12deg)}40%,to{-webkit-transform:rotate(0deg);transform:rotate(0deg)}}@keyframes fa-shake{0%{-webkit-transform:rotate(-15deg);transform:rotate(-15deg)}4%{-webkit-transform:rotate(15deg);transform:rotate(15deg)}8%,24%{-webkit-transform:rotate(-18deg);transform:rotate(-18deg)}12%,28%{-webkit-transform:rotate(18deg);transform:rotate(18deg)}16%{-webkit-transform:rotate(-22deg);transform:rotate(-22deg)}20%{-webkit-transform:rotate(22deg);transform:rotate(22deg)}32%{-webkit-transform:rotate(-12deg);transform:rotate(-12deg)}36%{-webkit-transform:rotate(12deg);transform:rotate(12deg)}40%,to{-webkit-transform:rotate(0deg);transform:rotate(0deg)}}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.fa-rotate-90{-webkit-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-webkit-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-webkit-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-webkit-transform:scaleX(-1);transform:scaleX(-1)}.fa-flip-vertical{-webkit-transform:scaleY(-1);transform:scaleY(-1)}.fa-flip-both,.fa-flip-horizontal.fa-flip-vertical{-webkit-transform:scale(-1);transform:scale(-1)}.fa-rotate-by{-webkit-transform:rotate(var(--fa-rotate-angle,none));transform:rotate(var(--fa-rotate-angle,none))}.fa-stack{display:inline-block;height:2em;line-height:2em;position:relative;vertical-align:middle;width:2.5em}.fa-stack-1x,.fa-stack-2x{left:0;position:absolute;text-align:center;width:100%;z-index:var(--fa-stack-z-index,auto)}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:var(--fa-inverse,#fff)}.fa-0:before{content:"\30"}.fa-1:before{content:"\31"}.fa-2:before{content:"\32"}.fa-3:before{content:"\33"}.fa-4:before{content:"\34"}.fa-5:before{content:"\35"}.fa-6:before{content:"\36"}.fa-7:before{content:"\37"}.fa-8:before{content:"\38"}.fa-9:before{content:"\39"}.fa-a:before{content:"\41"}.fa-address-book:before,.fa-contact-book:before{content:"\f2b9"}.fa-address-card:before,.fa-contact-card:before,.fa-vcard:before{content:"\f2bb"}.fa-align-center:before{content:"\f037"}.fa-align-justify:before{content:"\f039"}.fa-align-left:before{content:"\f036"}.fa-align-right:before{content:"\f038"}.fa-anchor:before{content:"\f13d"}.fa-anchor-circle-check:before{content:"\e4aa"}.fa-anchor-circle-exclamation:before{content:"\e4ab"}.fa-anchor-circle-xmark:before{content:"\e4ac"}.fa-anchor-lock:before{content:"\e4ad"}.fa-angle-down:before{content:"\f107"}.fa-angle-left:before{content:"\f104"}.fa-angle-right:before{content:"\f105"}.fa-angle-up:before{content:"\f106"}.fa-angle-double-down:before,.fa-angles-down:before{content:"\f103"}.fa-angle-double-left:before,.fa-angles-left:before{content:"\f100"}.fa-angle-double-right:before,.fa-angles-right:before{content:"\f101"}.fa-angle-double-up:before,.fa-angles-up:before{content:"\f102"}.fa-ankh:before{content:"\f644"}.fa-apple-alt:before,.fa-apple-whole:before{content:"\f5d1"}.fa-archway:before{content:"\f557"}.fa-arrow-down:before{content:"\f063"}.fa-arrow-down-1-9:before,.fa-sort-numeric-asc:before,.fa-sort-numeric-down:before{content:"\f162"}.fa-arrow-down-9-1:before,.fa-sort-numeric-desc:before,.fa-sort-numeric-down-alt:before{content:"\f886"}.fa-arrow-down-a-z:before,.fa-sort-alpha-asc:before,.fa-sort-alpha-down:before{content:"\f15d"}.fa-arrow-down-long:before,.fa-long-arrow-down:before{content:"\f175"}.fa-arrow-down-short-wide:before,.fa-sort-amount-desc:before,.fa-sort-amount-down-alt:before{content:"\f884"}.fa-arrow-down-up-across-line:before{content:"\e4af"}.fa-arrow-down-up-lock:before{content:"\e4b0"}.fa-arrow-down-wide-short:before,.fa-sort-amount-asc:before,.fa-sort-amount-down:before{content:"\f160"}.fa-arrow-down-z-a:before,.fa-sort-alpha-desc:before,.fa-sort-alpha-down-alt:before{content:"\f881"}.fa-arrow-left:before{content:"\f060"}.fa-arrow-left-long:before,.fa-long-arrow-left:before{content:"\f177"}.fa-arrow-pointer:before,.fa-mouse-pointer:before{content:"\f245"}.fa-arrow-right:before{content:"\f061"}.fa-arrow-right-arrow-left:before,.fa-exchange:before{content:"\f0ec"}.fa-arrow-right-from-bracket:before,.fa-sign-out:before{content:"\f08b"}.fa-arrow-right-long:before,.fa-long-arrow-right:before{content:"\f178"}.fa-arrow-right-to-bracket:before,.fa-sign-in:before{content:"\f090"}.fa-arrow-right-to-city:before{content:"\e4b3"}.fa-arrow-left-rotate:before,.fa-arrow-rotate-back:before,.fa-arrow-rotate-backward:before,.fa-arrow-rotate-left:before,.fa-undo:before{content:"\f0e2"}.fa-arrow-right-rotate:before,.fa-arrow-rotate-forward:before,.fa-arrow-rotate-right:before,.fa-redo:before{content:"\f01e"}.fa-arrow-trend-down:before{content:"\e097"}.fa-arrow-trend-up:before{content:"\e098"}.fa-arrow-turn-down:before,.fa-level-down:before{content:"\f149"}.fa-arrow-turn-up:before,.fa-level-up:before{content:"\f148"}.fa-arrow-up:before{content:"\f062"}.fa-arrow-up-1-9:before,.fa-sort-numeric-up:before{content:"\f163"}.fa-arrow-up-9-1:before,.fa-sort-numeric-up-alt:before{content:"\f887"}.fa-arrow-up-a-z:before,.fa-sort-alpha-up:before{content:"\f15e"}.fa-arrow-up-from-bracket:before{content:"\e09a"}.fa-arrow-up-from-ground-water:before{content:"\e4b5"}.fa-arrow-up-from-water-pump:before{content:"\e4b6"}.fa-arrow-up-long:before,.fa-long-arrow-up:before{content:"\f176"}.fa-arrow-up-right-dots:before{content:"\e4b7"}.fa-arrow-up-right-from-square:before,.fa-external-link:before{content:"\f08e"}.fa-arrow-up-short-wide:before,.fa-sort-amount-up-alt:before{content:"\f885"}.fa-arrow-up-wide-short:before,.fa-sort-amount-up:before{content:"\f161"}.fa-arrow-up-z-a:before,.fa-sort-alpha-up-alt:before{content:"\f882"}.fa-arrows-down-to-line:before{content:"\e4b8"}.fa-arrows-down-to-people:before{content:"\e4b9"}.fa-arrows-h:before,.fa-arrows-left-right:before{content:"\f07e"}.fa-arrows-left-right-to-line:before{content:"\e4ba"}.fa-arrows-rotate:before,.fa-refresh:before,.fa-sync:before{content:"\f021"}.fa-arrows-spin:before{content:"\e4bb"}.fa-arrows-split-up-and-left:before{content:"\e4bc"}.fa-arrows-to-circle:before{content:"\e4bd"}.fa-arrows-to-dot:before{content:"\e4be"}.fa-arrows-to-eye:before{content:"\e4bf"}.fa-arrows-turn-right:before{content:"\e4c0"}.fa-arrows-turn-to-dots:before{content:"\e4c1"}.fa-arrows-up-down:before,.fa-arrows-v:before{content:"\f07d"}.fa-arrows-up-down-left-right:before,.fa-arrows:before{content:"\f047"}.fa-arrows-up-to-line:before{content:"\e4c2"}.fa-asterisk:before{content:"\2a"}.fa-at:before{content:"\40"}.fa-atom:before{content:"\f5d2"}.fa-audio-description:before{content:"\f29e"}.fa-austral-sign:before{content:"\e0a9"}.fa-award:before{content:"\f559"}.fa-b:before{content:"\42"}.fa-baby:before{content:"\f77c"}.fa-baby-carriage:before,.fa-carriage-baby:before{content:"\f77d"}.fa-backward:before{content:"\f04a"}.fa-backward-fast:before,.fa-fast-backward:before{content:"\f049"}.fa-backward-step:before,.fa-step-backward:before{content:"\f048"}.fa-bacon:before{content:"\f7e5"}.fa-bacteria:before{content:"\e059"}.fa-bacterium:before{content:"\e05a"}.fa-bag-shopping:before,.fa-shopping-bag:before{content:"\f290"}.fa-bahai:before,.fa-haykal:before{content:"\f666"}.fa-baht-sign:before{content:"\e0ac"}.fa-ban:before,.fa-cancel:before{content:"\f05e"}.fa-ban-smoking:before,.fa-smoking-ban:before{content:"\f54d"}.fa-band-aid:before,.fa-bandage:before{content:"\f462"}.fa-barcode:before{content:"\f02a"}.fa-bars:before,.fa-navicon:before{content:"\f0c9"}.fa-bars-progress:before,.fa-tasks-alt:before{content:"\f828"}.fa-bars-staggered:before,.fa-reorder:before,.fa-stream:before{content:"\f550"}.fa-baseball-ball:before,.fa-baseball:before{content:"\f433"}.fa-baseball-bat-ball:before{content:"\f432"}.fa-basket-shopping:before,.fa-shopping-basket:before{content:"\f291"}.fa-basketball-ball:before,.fa-basketball:before{content:"\f434"}.fa-bath:before,.fa-bathtub:before{content:"\f2cd"}.fa-battery-0:before,.fa-battery-empty:before{content:"\f244"}.fa-battery-5:before,.fa-battery-full:before,.fa-battery:before{content:"\f240"}.fa-battery-3:before,.fa-battery-half:before{content:"\f242"}.fa-battery-2:before,.fa-battery-quarter:before{content:"\f243"}.fa-battery-4:before,.fa-battery-three-quarters:before{content:"\f241"}.fa-bed:before{content:"\f236"}.fa-bed-pulse:before,.fa-procedures:before{content:"\f487"}.fa-beer-mug-empty:before,.fa-beer:before{content:"\f0fc"}.fa-bell:before{content:"\f0f3"}.fa-bell-concierge:before,.fa-concierge-bell:before{content:"\f562"}.fa-bell-slash:before{content:"\f1f6"}.fa-bezier-curve:before{content:"\f55b"}.fa-bicycle:before{content:"\f206"}.fa-binoculars:before{content:"\f1e5"}.fa-biohazard:before{content:"\f780"}.fa-bitcoin-sign:before{content:"\e0b4"}.fa-blender:before{content:"\f517"}.fa-blender-phone:before{content:"\f6b6"}.fa-blog:before{content:"\f781"}.fa-bold:before{content:"\f032"}.fa-bolt:before,.fa-zap:before{content:"\f0e7"}.fa-bolt-lightning:before{content:"\e0b7"}.fa-bomb:before{content:"\f1e2"}.fa-bone:before{content:"\f5d7"}.fa-bong:before{content:"\f55c"}.fa-book:before{content:"\f02d"}.fa-atlas:before,.fa-book-atlas:before{content:"\f558"}.fa-bible:before,.fa-book-bible:before{content:"\f647"}.fa-book-bookmark:before{content:"\e0bb"}.fa-book-journal-whills:before,.fa-journal-whills:before{content:"\f66a"}.fa-book-medical:before{content:"\f7e6"}.fa-book-open:before{content:"\f518"}.fa-book-open-reader:before,.fa-book-reader:before{content:"\f5da"}.fa-book-quran:before,.fa-quran:before{content:"\f687"}.fa-book-dead:before,.fa-book-skull:before{content:"\f6b7"}.fa-book-tanakh:before,.fa-tanakh:before{content:"\f827"}.fa-bookmark:before{content:"\f02e"}.fa-border-all:before{content:"\f84c"}.fa-border-none:before{content:"\f850"}.fa-border-style:before,.fa-border-top-left:before{content:"\f853"}.fa-bore-hole:before{content:"\e4c3"}.fa-bottle-droplet:before{content:"\e4c4"}.fa-bottle-water:before{content:"\e4c5"}.fa-bowl-food:before{content:"\e4c6"}.fa-bowl-rice:before{content:"\e2eb"}.fa-bowling-ball:before{content:"\f436"}.fa-box:before{content:"\f466"}.fa-archive:before,.fa-box-archive:before{content:"\f187"}.fa-box-open:before{content:"\f49e"}.fa-box-tissue:before{content:"\e05b"}.fa-boxes-packing:before{content:"\e4c7"}.fa-boxes-alt:before,.fa-boxes-stacked:before,.fa-boxes:before{content:"\f468"}.fa-braille:before{content:"\f2a1"}.fa-brain:before{content:"\f5dc"}.fa-brazilian-real-sign:before{content:"\e46c"}.fa-bread-slice:before{content:"\f7ec"}.fa-bridge:before{content:"\e4c8"}.fa-bridge-circle-check:before{content:"\e4c9"}.fa-bridge-circle-exclamation:before{content:"\e4ca"}.fa-bridge-circle-xmark:before{content:"\e4cb"}.fa-bridge-lock:before{content:"\e4cc"}.fa-bridge-water:before{content:"\e4ce"}.fa-briefcase:before{content:"\f0b1"}.fa-briefcase-medical:before{content:"\f469"}.fa-broom:before{content:"\f51a"}.fa-broom-ball:before,.fa-quidditch-broom-ball:before,.fa-quidditch:before{content:"\f458"}.fa-brush:before{content:"\f55d"}.fa-bucket:before{content:"\e4cf"}.fa-bug:before{content:"\f188"}.fa-bug-slash:before{content:"\e490"}.fa-bugs:before{content:"\e4d0"}.fa-building:before{content:"\f1ad"}.fa-building-circle-arrow-right:before{content:"\e4d1"}.fa-building-circle-check:before{content:"\e4d2"}.fa-building-circle-exclamation:before{content:"\e4d3"}.fa-building-circle-xmark:before{content:"\e4d4"}.fa-bank:before,.fa-building-columns:before,.fa-institution:before,.fa-museum:before,.fa-university:before{content:"\f19c"}.fa-building-flag:before{content:"\e4d5"}.fa-building-lock:before{content:"\e4d6"}.fa-building-ngo:before{content:"\e4d7"}.fa-building-shield:before{content:"\e4d8"}.fa-building-un:before{content:"\e4d9"}.fa-building-user:before{content:"\e4da"}.fa-building-wheat:before{content:"\e4db"}.fa-bullhorn:before{content:"\f0a1"}.fa-bullseye:before{content:"\f140"}.fa-burger:before,.fa-hamburger:before{content:"\f805"}.fa-burst:before{content:"\e4dc"}.fa-bus:before{content:"\f207"}.fa-bus-alt:before,.fa-bus-simple:before{content:"\f55e"}.fa-briefcase-clock:before,.fa-business-time:before{content:"\f64a"}.fa-c:before{content:"\43"}.fa-cable-car:before,.fa-tram:before{content:"\f7da"}.fa-birthday-cake:before,.fa-cake-candles:before,.fa-cake:before{content:"\f1fd"}.fa-calculator:before{content:"\f1ec"}.fa-calendar:before{content:"\f133"}.fa-calendar-check:before{content:"\f274"}.fa-calendar-day:before{content:"\f783"}.fa-calendar-alt:before,.fa-calendar-days:before{content:"\f073"}.fa-calendar-minus:before{content:"\f272"}.fa-calendar-plus:before{content:"\f271"}.fa-calendar-week:before{content:"\f784"}.fa-calendar-times:before,.fa-calendar-xmark:before{content:"\f273"}.fa-camera-alt:before,.fa-camera:before{content:"\f030"}.fa-camera-retro:before{content:"\f083"}.fa-camera-rotate:before{content:"\e0d8"}.fa-campground:before{content:"\f6bb"}.fa-candy-cane:before{content:"\f786"}.fa-cannabis:before{content:"\f55f"}.fa-capsules:before{content:"\f46b"}.fa-automobile:before,.fa-car:before{content:"\f1b9"}.fa-battery-car:before,.fa-car-battery:before{content:"\f5df"}.fa-car-burst:before,.fa-car-crash:before{content:"\f5e1"}.fa-car-on:before{content:"\e4dd"}.fa-car-alt:before,.fa-car-rear:before{content:"\f5de"}.fa-car-side:before{content:"\f5e4"}.fa-car-tunnel:before{content:"\e4de"}.fa-caravan:before{content:"\f8ff"}.fa-caret-down:before{content:"\f0d7"}.fa-caret-left:before{content:"\f0d9"}.fa-caret-right:before{content:"\f0da"}.fa-caret-up:before{content:"\f0d8"}.fa-carrot:before{content:"\f787"}.fa-cart-arrow-down:before{content:"\f218"}.fa-cart-flatbed:before,.fa-dolly-flatbed:before{content:"\f474"}.fa-cart-flatbed-suitcase:before,.fa-luggage-cart:before{content:"\f59d"}.fa-cart-plus:before{content:"\f217"}.fa-cart-shopping:before,.fa-shopping-cart:before{content:"\f07a"}.fa-cash-register:before{content:"\f788"}.fa-cat:before{content:"\f6be"}.fa-cedi-sign:before{content:"\e0df"}.fa-cent-sign:before{content:"\e3f5"}.fa-certificate:before{content:"\f0a3"}.fa-chair:before{content:"\f6c0"}.fa-blackboard:before,.fa-chalkboard:before{content:"\f51b"}.fa-chalkboard-teacher:before,.fa-chalkboard-user:before{content:"\f51c"}.fa-champagne-glasses:before,.fa-glass-cheers:before{content:"\f79f"}.fa-charging-station:before{content:"\f5e7"}.fa-area-chart:before,.fa-chart-area:before{content:"\f1fe"}.fa-bar-chart:before,.fa-chart-bar:before{content:"\f080"}.fa-chart-column:before{content:"\e0e3"}.fa-chart-gantt:before{content:"\e0e4"}.fa-chart-line:before,.fa-line-chart:before{content:"\f201"}.fa-chart-pie:before,.fa-pie-chart:before{content:"\f200"}.fa-chart-simple:before{content:"\e473"}.fa-check:before{content:"\f00c"}.fa-check-double:before{content:"\f560"}.fa-check-to-slot:before,.fa-vote-yea:before{content:"\f772"}.fa-cheese:before{content:"\f7ef"}.fa-chess:before{content:"\f439"}.fa-chess-bishop:before{content:"\f43a"}.fa-chess-board:before{content:"\f43c"}.fa-chess-king:before{content:"\f43f"}.fa-chess-knight:before{content:"\f441"}.fa-chess-pawn:before{content:"\f443"}.fa-chess-queen:before{content:"\f445"}.fa-chess-rook:before{content:"\f447"}.fa-chevron-down:before{content:"\f078"}.fa-chevron-left:before{content:"\f053"}.fa-chevron-right:before{content:"\f054"}.fa-chevron-up:before{content:"\f077"}.fa-child:before{content:"\f1ae"}.fa-child-dress:before{content:"\e59c"}.fa-child-reaching:before{content:"\e59d"}.fa-child-rifle:before{content:"\e4e0"}.fa-children:before{content:"\e4e1"}.fa-church:before{content:"\f51d"}.fa-circle:before{content:"\f111"}.fa-arrow-circle-down:before,.fa-circle-arrow-down:before{content:"\f0ab"}.fa-arrow-circle-left:before,.fa-circle-arrow-left:before{content:"\f0a8"}.fa-arrow-circle-right:before,.fa-circle-arrow-right:before{content:"\f0a9"}.fa-arrow-circle-up:before,.fa-circle-arrow-up:before{content:"\f0aa"}.fa-check-circle:before,.fa-circle-check:before{content:"\f058"}.fa-chevron-circle-down:before,.fa-circle-chevron-down:before{content:"\f13a"}.fa-chevron-circle-left:before,.fa-circle-chevron-left:before{content:"\f137"}.fa-chevron-circle-right:before,.fa-circle-chevron-right:before{content:"\f138"}.fa-chevron-circle-up:before,.fa-circle-chevron-up:before{content:"\f139"}.fa-circle-dollar-to-slot:before,.fa-donate:before{content:"\f4b9"}.fa-circle-dot:before,.fa-dot-circle:before{content:"\f192"}.fa-arrow-alt-circle-down:before,.fa-circle-down:before{content:"\f358"}.fa-circle-exclamation:before,.fa-exclamation-circle:before{content:"\f06a"}.fa-circle-h:before,.fa-hospital-symbol:before{content:"\f47e"}.fa-adjust:before,.fa-circle-half-stroke:before{content:"\f042"}.fa-circle-info:before,.fa-info-circle:before{content:"\f05a"}.fa-arrow-alt-circle-left:before,.fa-circle-left:before{content:"\f359"}.fa-circle-minus:before,.fa-minus-circle:before{content:"\f056"}.fa-circle-nodes:before{content:"\e4e2"}.fa-circle-notch:before{content:"\f1ce"}.fa-circle-pause:before,.fa-pause-circle:before{content:"\f28b"}.fa-circle-play:before,.fa-play-circle:before{content:"\f144"}.fa-circle-plus:before,.fa-plus-circle:before{content:"\f055"}.fa-circle-question:before,.fa-question-circle:before{content:"\f059"}.fa-circle-radiation:before,.fa-radiation-alt:before{content:"\f7ba"}.fa-arrow-alt-circle-right:before,.fa-circle-right:before{content:"\f35a"}.fa-circle-stop:before,.fa-stop-circle:before{content:"\f28d"}.fa-arrow-alt-circle-up:before,.fa-circle-up:before{content:"\f35b"}.fa-circle-user:before,.fa-user-circle:before{content:"\f2bd"}.fa-circle-xmark:before,.fa-times-circle:before,.fa-xmark-circle:before{content:"\f057"}.fa-city:before{content:"\f64f"}.fa-clapperboard:before{content:"\e131"}.fa-clipboard:before{content:"\f328"}.fa-clipboard-check:before{content:"\f46c"}.fa-clipboard-list:before{content:"\f46d"}.fa-clipboard-question:before{content:"\e4e3"}.fa-clipboard-user:before{content:"\f7f3"}.fa-clock-four:before,.fa-clock:before{content:"\f017"}.fa-clock-rotate-left:before,.fa-history:before{content:"\f1da"}.fa-clone:before{content:"\f24d"}.fa-closed-captioning:before{content:"\f20a"}.fa-cloud:before{content:"\f0c2"}.fa-cloud-arrow-down:before,.fa-cloud-download-alt:before,.fa-cloud-download:before{content:"\f0ed"}.fa-cloud-arrow-up:before,.fa-cloud-upload-alt:before,.fa-cloud-upload:before{content:"\f0ee"}.fa-cloud-bolt:before,.fa-thunderstorm:before{content:"\f76c"}.fa-cloud-meatball:before{content:"\f73b"}.fa-cloud-moon:before{content:"\f6c3"}.fa-cloud-moon-rain:before{content:"\f73c"}.fa-cloud-rain:before{content:"\f73d"}.fa-cloud-showers-heavy:before{content:"\f740"}.fa-cloud-showers-water:before{content:"\e4e4"}.fa-cloud-sun:before{content:"\f6c4"}.fa-cloud-sun-rain:before{content:"\f743"}.fa-clover:before{content:"\e139"}.fa-code:before{content:"\f121"}.fa-code-branch:before{content:"\f126"}.fa-code-commit:before{content:"\f386"}.fa-code-compare:before{content:"\e13a"}.fa-code-fork:before{content:"\e13b"}.fa-code-merge:before{content:"\f387"}.fa-code-pull-request:before{content:"\e13c"}.fa-coins:before{content:"\f51e"}.fa-colon-sign:before{content:"\e140"}.fa-comment:before{content:"\f075"}.fa-comment-dollar:before{content:"\f651"}.fa-comment-dots:before,.fa-commenting:before{content:"\f4ad"}.fa-comment-medical:before{content:"\f7f5"}.fa-comment-slash:before{content:"\f4b3"}.fa-comment-sms:before,.fa-sms:before{content:"\f7cd"}.fa-comments:before{content:"\f086"}.fa-comments-dollar:before{content:"\f653"}.fa-compact-disc:before{content:"\f51f"}.fa-compass:before{content:"\f14e"}.fa-compass-drafting:before,.fa-drafting-compass:before{content:"\f568"}.fa-compress:before{content:"\f066"}.fa-computer:before{content:"\e4e5"}.fa-computer-mouse:before,.fa-mouse:before{content:"\f8cc"}.fa-cookie:before{content:"\f563"}.fa-cookie-bite:before{content:"\f564"}.fa-copy:before{content:"\f0c5"}.fa-copyright:before{content:"\f1f9"}.fa-couch:before{content:"\f4b8"}.fa-cow:before{content:"\f6c8"}.fa-credit-card-alt:before,.fa-credit-card:before{content:"\f09d"}.fa-crop:before{content:"\f125"}.fa-crop-alt:before,.fa-crop-simple:before{content:"\f565"}.fa-cross:before{content:"\f654"}.fa-crosshairs:before{content:"\f05b"}.fa-crow:before{content:"\f520"}.fa-crown:before{content:"\f521"}.fa-crutch:before{content:"\f7f7"}.fa-cruzeiro-sign:before{content:"\e152"}.fa-cube:before{content:"\f1b2"}.fa-cubes:before{content:"\f1b3"}.fa-cubes-stacked:before{content:"\e4e6"}.fa-d:before{content:"\44"}.fa-database:before{content:"\f1c0"}.fa-backspace:before,.fa-delete-left:before{content:"\f55a"}.fa-democrat:before{content:"\f747"}.fa-desktop-alt:before,.fa-desktop:before{content:"\f390"}.fa-dharmachakra:before{content:"\f655"}.fa-diagram-next:before{content:"\e476"}.fa-diagram-predecessor:before{content:"\e477"}.fa-diagram-project:before,.fa-project-diagram:before{content:"\f542"}.fa-diagram-successor:before{content:"\e47a"}.fa-diamond:before{content:"\f219"}.fa-diamond-turn-right:before,.fa-directions:before{content:"\f5eb"}.fa-dice:before{content:"\f522"}.fa-dice-d20:before{content:"\f6cf"}.fa-dice-d6:before{content:"\f6d1"}.fa-dice-five:before{content:"\f523"}.fa-dice-four:before{content:"\f524"}.fa-dice-one:before{content:"\f525"}.fa-dice-six:before{content:"\f526"}.fa-dice-three:before{content:"\f527"}.fa-dice-two:before{content:"\f528"}.fa-disease:before{content:"\f7fa"}.fa-display:before{content:"\e163"}.fa-divide:before{content:"\f529"}.fa-dna:before{content:"\f471"}.fa-dog:before{content:"\f6d3"}.fa-dollar-sign:before,.fa-dollar:before,.fa-usd:before{content:"\24"}.fa-dolly-box:before,.fa-dolly:before{content:"\f472"}.fa-dong-sign:before{content:"\e169"}.fa-door-closed:before{content:"\f52a"}.fa-door-open:before{content:"\f52b"}.fa-dove:before{content:"\f4ba"}.fa-compress-alt:before,.fa-down-left-and-up-right-to-center:before{content:"\f422"}.fa-down-long:before,.fa-long-arrow-alt-down:before{content:"\f309"}.fa-download:before{content:"\f019"}.fa-dragon:before{content:"\f6d5"}.fa-draw-polygon:before{content:"\f5ee"}.fa-droplet:before,.fa-tint:before{content:"\f043"}.fa-droplet-slash:before,.fa-tint-slash:before{content:"\f5c7"}.fa-drum:before{content:"\f569"}.fa-drum-steelpan:before{content:"\f56a"}.fa-drumstick-bite:before{content:"\f6d7"}.fa-dumbbell:before{content:"\f44b"}.fa-dumpster:before{content:"\f793"}.fa-dumpster-fire:before{content:"\f794"}.fa-dungeon:before{content:"\f6d9"}.fa-e:before{content:"\45"}.fa-deaf:before,.fa-deafness:before,.fa-ear-deaf:before,.fa-hard-of-hearing:before{content:"\f2a4"}.fa-assistive-listening-systems:before,.fa-ear-listen:before{content:"\f2a2"}.fa-earth-africa:before,.fa-globe-africa:before{content:"\f57c"}.fa-earth-america:before,.fa-earth-americas:before,.fa-earth:before,.fa-globe-americas:before{content:"\f57d"}.fa-earth-asia:before,.fa-globe-asia:before{content:"\f57e"}.fa-earth-europe:before,.fa-globe-europe:before{content:"\f7a2"}.fa-earth-oceania:before,.fa-globe-oceania:before{content:"\e47b"}.fa-egg:before{content:"\f7fb"}.fa-eject:before{content:"\f052"}.fa-elevator:before{content:"\e16d"}.fa-ellipsis-h:before,.fa-ellipsis:before{content:"\f141"}.fa-ellipsis-v:before,.fa-ellipsis-vertical:before{content:"\f142"}.fa-envelope:before{content:"\f0e0"}.fa-envelope-circle-check:before{content:"\e4e8"}.fa-envelope-open:before{content:"\f2b6"}.fa-envelope-open-text:before{content:"\f658"}.fa-envelopes-bulk:before,.fa-mail-bulk:before{content:"\f674"}.fa-equals:before{content:"\3d"}.fa-eraser:before{content:"\f12d"}.fa-ethernet:before{content:"\f796"}.fa-eur:before,.fa-euro-sign:before,.fa-euro:before{content:"\f153"}.fa-exclamation:before{content:"\21"}.fa-expand:before{content:"\f065"}.fa-explosion:before{content:"\e4e9"}.fa-eye:before{content:"\f06e"}.fa-eye-dropper-empty:before,.fa-eye-dropper:before,.fa-eyedropper:before{content:"\f1fb"}.fa-eye-low-vision:before,.fa-low-vision:before{content:"\f2a8"}.fa-eye-slash:before{content:"\f070"}.fa-f:before{content:"\46"}.fa-angry:before,.fa-face-angry:before{content:"\f556"}.fa-dizzy:before,.fa-face-dizzy:before{content:"\f567"}.fa-face-flushed:before,.fa-flushed:before{content:"\f579"}.fa-face-frown:before,.fa-frown:before{content:"\f119"}.fa-face-frown-open:before,.fa-frown-open:before{content:"\f57a"}.fa-face-grimace:before,.fa-grimace:before{content:"\f57f"}.fa-face-grin:before,.fa-grin:before{content:"\f580"}.fa-face-grin-beam:before,.fa-grin-beam:before{content:"\f582"}.fa-face-grin-beam-sweat:before,.fa-grin-beam-sweat:before{content:"\f583"}.fa-face-grin-hearts:before,.fa-grin-hearts:before{content:"\f584"}.fa-face-grin-squint:before,.fa-grin-squint:before{content:"\f585"}.fa-face-grin-squint-tears:before,.fa-grin-squint-tears:before{content:"\f586"}.fa-face-grin-stars:before,.fa-grin-stars:before{content:"\f587"}.fa-face-grin-tears:before,.fa-grin-tears:before{content:"\f588"}.fa-face-grin-tongue:before,.fa-grin-tongue:before{content:"\f589"}.fa-face-grin-tongue-squint:before,.fa-grin-tongue-squint:before{content:"\f58a"}.fa-face-grin-tongue-wink:before,.fa-grin-tongue-wink:before{content:"\f58b"}.fa-face-grin-wide:before,.fa-grin-alt:before{content:"\f581"}.fa-face-grin-wink:before,.fa-grin-wink:before{content:"\f58c"}.fa-face-kiss:before,.fa-kiss:before{content:"\f596"}.fa-face-kiss-beam:before,.fa-kiss-beam:before{content:"\f597"}.fa-face-kiss-wink-heart:before,.fa-kiss-wink-heart:before{content:"\f598"}.fa-face-laugh:before,.fa-laugh:before{content:"\f599"}.fa-face-laugh-beam:before,.fa-laugh-beam:before{content:"\f59a"}.fa-face-laugh-squint:before,.fa-laugh-squint:before{content:"\f59b"}.fa-face-laugh-wink:before,.fa-laugh-wink:before{content:"\f59c"}.fa-face-meh:before,.fa-meh:before{content:"\f11a"}.fa-face-meh-blank:before,.fa-meh-blank:before{content:"\f5a4"}.fa-face-rolling-eyes:before,.fa-meh-rolling-eyes:before{content:"\f5a5"}.fa-face-sad-cry:before,.fa-sad-cry:before{content:"\f5b3"}.fa-face-sad-tear:before,.fa-sad-tear:before{content:"\f5b4"}.fa-face-smile:before,.fa-smile:before{content:"\f118"}.fa-face-smile-beam:before,.fa-smile-beam:before{content:"\f5b8"}.fa-face-smile-wink:before,.fa-smile-wink:before{content:"\f4da"}.fa-face-surprise:before,.fa-surprise:before{content:"\f5c2"}.fa-face-tired:before,.fa-tired:before{content:"\f5c8"}.fa-fan:before{content:"\f863"}.fa-faucet:before{content:"\e005"}.fa-faucet-drip:before{content:"\e006"}.fa-fax:before{content:"\f1ac"}.fa-feather:before{content:"\f52d"}.fa-feather-alt:before,.fa-feather-pointed:before{content:"\f56b"}.fa-ferry:before{content:"\e4ea"}.fa-file:before{content:"\f15b"}.fa-file-arrow-down:before,.fa-file-download:before{content:"\f56d"}.fa-file-arrow-up:before,.fa-file-upload:before{content:"\f574"}.fa-file-audio:before{content:"\f1c7"}.fa-file-circle-check:before{content:"\e5a0"}.fa-file-circle-exclamation:before{content:"\e4eb"}.fa-file-circle-minus:before{content:"\e4ed"}.fa-file-circle-plus:before{content:"\e494"}.fa-file-circle-question:before{content:"\e4ef"}.fa-file-circle-xmark:before{content:"\e5a1"}.fa-file-code:before{content:"\f1c9"}.fa-file-contract:before{content:"\f56c"}.fa-file-csv:before{content:"\f6dd"}.fa-file-excel:before{content:"\f1c3"}.fa-arrow-right-from-file:before,.fa-file-export:before{content:"\f56e"}.fa-file-image:before{content:"\f1c5"}.fa-arrow-right-to-file:before,.fa-file-import:before{content:"\f56f"}.fa-file-invoice:before{content:"\f570"}.fa-file-invoice-dollar:before{content:"\f571"}.fa-file-alt:before,.fa-file-lines:before,.fa-file-text:before{content:"\f15c"}.fa-file-medical:before{content:"\f477"}.fa-file-pdf:before{content:"\f1c1"}.fa-file-edit:before,.fa-file-pen:before{content:"\f31c"}.fa-file-powerpoint:before{content:"\f1c4"}.fa-file-prescription:before{content:"\f572"}.fa-file-shield:before{content:"\e4f0"}.fa-file-signature:before{content:"\f573"}.fa-file-video:before{content:"\f1c8"}.fa-file-medical-alt:before,.fa-file-waveform:before{content:"\f478"}.fa-file-word:before{content:"\f1c2"}.fa-file-archive:before,.fa-file-zipper:before{content:"\f1c6"}.fa-fill:before{content:"\f575"}.fa-fill-drip:before{content:"\f576"}.fa-film:before{content:"\f008"}.fa-filter:before{content:"\f0b0"}.fa-filter-circle-dollar:before,.fa-funnel-dollar:before{content:"\f662"}.fa-filter-circle-xmark:before{content:"\e17b"}.fa-fingerprint:before{content:"\f577"}.fa-fire:before{content:"\f06d"}.fa-fire-burner:before{content:"\e4f1"}.fa-fire-extinguisher:before{content:"\f134"}.fa-fire-alt:before,.fa-fire-flame-curved:before{content:"\f7e4"}.fa-burn:before,.fa-fire-flame-simple:before{content:"\f46a"}.fa-fish:before{content:"\f578"}.fa-fish-fins:before{content:"\e4f2"}.fa-flag:before{content:"\f024"}.fa-flag-checkered:before{content:"\f11e"}.fa-flag-usa:before{content:"\f74d"}.fa-flask:before{content:"\f0c3"}.fa-flask-vial:before{content:"\e4f3"}.fa-floppy-disk:before,.fa-save:before{content:"\f0c7"}.fa-florin-sign:before{content:"\e184"}.fa-folder-blank:before,.fa-folder:before{content:"\f07b"}.fa-folder-closed:before{content:"\e185"}.fa-folder-minus:before{content:"\f65d"}.fa-folder-open:before{content:"\f07c"}.fa-folder-plus:before{content:"\f65e"}.fa-folder-tree:before{content:"\f802"}.fa-font:before{content:"\f031"}.fa-football-ball:before,.fa-football:before{content:"\f44e"}.fa-forward:before{content:"\f04e"}.fa-fast-forward:before,.fa-forward-fast:before{content:"\f050"}.fa-forward-step:before,.fa-step-forward:before{content:"\f051"}.fa-franc-sign:before{content:"\e18f"}.fa-frog:before{content:"\f52e"}.fa-futbol-ball:before,.fa-futbol:before,.fa-soccer-ball:before{content:"\f1e3"}.fa-g:before{content:"\47"}.fa-gamepad:before{content:"\f11b"}.fa-gas-pump:before{content:"\f52f"}.fa-dashboard:before,.fa-gauge-med:before,.fa-gauge:before,.fa-tachometer-alt-average:before{content:"\f624"}.fa-gauge-high:before,.fa-tachometer-alt-fast:before,.fa-tachometer-alt:before{content:"\f625"}.fa-gauge-simple-med:before,.fa-gauge-simple:before,.fa-tachometer-average:before{content:"\f629"}.fa-gauge-simple-high:before,.fa-tachometer-fast:before,.fa-tachometer:before{content:"\f62a"}.fa-gavel:before,.fa-legal:before{content:"\f0e3"}.fa-cog:before,.fa-gear:before{content:"\f013"}.fa-cogs:before,.fa-gears:before{content:"\f085"}.fa-gem:before{content:"\f3a5"}.fa-genderless:before{content:"\f22d"}.fa-ghost:before{content:"\f6e2"}.fa-gift:before{content:"\f06b"}.fa-gifts:before{content:"\f79c"}.fa-glass-water:before{content:"\e4f4"}.fa-glass-water-droplet:before{content:"\e4f5"}.fa-glasses:before{content:"\f530"}.fa-globe:before{content:"\f0ac"}.fa-golf-ball-tee:before,.fa-golf-ball:before{content:"\f450"}.fa-gopuram:before{content:"\f664"}.fa-graduation-cap:before,.fa-mortar-board:before{content:"\f19d"}.fa-greater-than:before{content:"\3e"}.fa-greater-than-equal:before{content:"\f532"}.fa-grip-horizontal:before,.fa-grip:before{content:"\f58d"}.fa-grip-lines:before{content:"\f7a4"}.fa-grip-lines-vertical:before{content:"\f7a5"}.fa-grip-vertical:before{content:"\f58e"}.fa-group-arrows-rotate:before{content:"\e4f6"}.fa-guarani-sign:before{content:"\e19a"}.fa-guitar:before{content:"\f7a6"}.fa-gun:before{content:"\e19b"}.fa-h:before{content:"\48"}.fa-hammer:before{content:"\f6e3"}.fa-hamsa:before{content:"\f665"}.fa-hand-paper:before,.fa-hand:before{content:"\f256"}.fa-hand-back-fist:before,.fa-hand-rock:before{content:"\f255"}.fa-allergies:before,.fa-hand-dots:before{content:"\f461"}.fa-fist-raised:before,.fa-hand-fist:before{content:"\f6de"}.fa-hand-holding:before{content:"\f4bd"}.fa-hand-holding-dollar:before,.fa-hand-holding-usd:before{content:"\f4c0"}.fa-hand-holding-droplet:before,.fa-hand-holding-water:before{content:"\f4c1"}.fa-hand-holding-hand:before{content:"\e4f7"}.fa-hand-holding-heart:before{content:"\f4be"}.fa-hand-holding-medical:before{content:"\e05c"}.fa-hand-lizard:before{content:"\f258"}.fa-hand-middle-finger:before{content:"\f806"}.fa-hand-peace:before{content:"\f25b"}.fa-hand-point-down:before{content:"\f0a7"}.fa-hand-point-left:before{content:"\f0a5"}.fa-hand-point-right:before{content:"\f0a4"}.fa-hand-point-up:before{content:"\f0a6"}.fa-hand-pointer:before{content:"\f25a"}.fa-hand-scissors:before{content:"\f257"}.fa-hand-sparkles:before{content:"\e05d"}.fa-hand-spock:before{content:"\f259"}.fa-handcuffs:before{content:"\e4f8"}.fa-hands:before,.fa-sign-language:before,.fa-signing:before{content:"\f2a7"}.fa-american-sign-language-interpreting:before,.fa-asl-interpreting:before,.fa-hands-american-sign-language-interpreting:before,.fa-hands-asl-interpreting:before{content:"\f2a3"}.fa-hands-bound:before{content:"\e4f9"}.fa-hands-bubbles:before,.fa-hands-wash:before{content:"\e05e"}.fa-hands-clapping:before{content:"\e1a8"}.fa-hands-holding:before{content:"\f4c2"}.fa-hands-holding-child:before{content:"\e4fa"}.fa-hands-holding-circle:before{content:"\e4fb"}.fa-hands-praying:before,.fa-praying-hands:before{content:"\f684"}.fa-handshake:before{content:"\f2b5"}.fa-hands-helping:before,.fa-handshake-angle:before{content:"\f4c4"}.fa-handshake-alt:before,.fa-handshake-simple:before{content:"\f4c6"}.fa-handshake-alt-slash:before,.fa-handshake-simple-slash:before{content:"\e05f"}.fa-handshake-slash:before{content:"\e060"}.fa-hanukiah:before{content:"\f6e6"}.fa-hard-drive:before,.fa-hdd:before{content:"\f0a0"}.fa-hashtag:before{content:"\23"}.fa-hat-cowboy:before{content:"\f8c0"}.fa-hat-cowboy-side:before{content:"\f8c1"}.fa-hat-wizard:before{content:"\f6e8"}.fa-head-side-cough:before{content:"\e061"}.fa-head-side-cough-slash:before{content:"\e062"}.fa-head-side-mask:before{content:"\e063"}.fa-head-side-virus:before{content:"\e064"}.fa-header:before,.fa-heading:before{content:"\f1dc"}.fa-headphones:before{content:"\f025"}.fa-headphones-alt:before,.fa-headphones-simple:before{content:"\f58f"}.fa-headset:before{content:"\f590"}.fa-heart:before{content:"\f004"}.fa-heart-circle-bolt:before{content:"\e4fc"}.fa-heart-circle-check:before{content:"\e4fd"}.fa-heart-circle-exclamation:before{content:"\e4fe"}.fa-heart-circle-minus:before{content:"\e4ff"}.fa-heart-circle-plus:before{content:"\e500"}.fa-heart-circle-xmark:before{content:"\e501"}.fa-heart-broken:before,.fa-heart-crack:before{content:"\f7a9"}.fa-heart-pulse:before,.fa-heartbeat:before{content:"\f21e"}.fa-helicopter:before{content:"\f533"}.fa-helicopter-symbol:before{content:"\e502"}.fa-hard-hat:before,.fa-hat-hard:before,.fa-helmet-safety:before{content:"\f807"}.fa-helmet-un:before{content:"\e503"}.fa-highlighter:before{content:"\f591"}.fa-hill-avalanche:before{content:"\e507"}.fa-hill-rockslide:before{content:"\e508"}.fa-hippo:before{content:"\f6ed"}.fa-hockey-puck:before{content:"\f453"}.fa-holly-berry:before{content:"\f7aa"}.fa-horse:before{content:"\f6f0"}.fa-horse-head:before{content:"\f7ab"}.fa-hospital-alt:before,.fa-hospital-wide:before,.fa-hospital:before{content:"\f0f8"}.fa-hospital-user:before{content:"\f80d"}.fa-hot-tub-person:before,.fa-hot-tub:before{content:"\f593"}.fa-hotdog:before{content:"\f80f"}.fa-hotel:before{content:"\f594"}.fa-hourglass-empty:before,.fa-hourglass:before{content:"\f254"}.fa-hourglass-3:before,.fa-hourglass-end:before{content:"\f253"}.fa-hourglass-2:before,.fa-hourglass-half:before{content:"\f252"}.fa-hourglass-1:before,.fa-hourglass-start:before{content:"\f251"}.fa-home-alt:before,.fa-home-lg-alt:before,.fa-home:before,.fa-house:before{content:"\f015"}.fa-home-lg:before,.fa-house-chimney:before{content:"\e3af"}.fa-house-chimney-crack:before,.fa-house-damage:before{content:"\f6f1"}.fa-clinic-medical:before,.fa-house-chimney-medical:before{content:"\f7f2"}.fa-house-chimney-user:before{content:"\e065"}.fa-house-chimney-window:before{content:"\e00d"}.fa-house-circle-check:before{content:"\e509"}.fa-house-circle-exclamation:before{content:"\e50a"}.fa-house-circle-xmark:before{content:"\e50b"}.fa-house-crack:before{content:"\e3b1"}.fa-house-fire:before{content:"\e50c"}.fa-house-flag:before{content:"\e50d"}.fa-house-flood-water:before{content:"\e50e"}.fa-house-flood-water-circle-arrow-right:before{content:"\e50f"}.fa-house-laptop:before,.fa-laptop-house:before{content:"\e066"}.fa-house-lock:before{content:"\e510"}.fa-house-medical:before{content:"\e3b2"}.fa-house-medical-circle-check:before{content:"\e511"}.fa-house-medical-circle-exclamation:before{content:"\e512"}.fa-house-medical-circle-xmark:before{content:"\e513"}.fa-house-medical-flag:before{content:"\e514"}.fa-house-signal:before{content:"\e012"}.fa-house-tsunami:before{content:"\e515"}.fa-home-user:before,.fa-house-user:before{content:"\e1b0"}.fa-hryvnia-sign:before,.fa-hryvnia:before{content:"\f6f2"}.fa-hurricane:before{content:"\f751"}.fa-i:before{content:"\49"}.fa-i-cursor:before{content:"\f246"}.fa-ice-cream:before{content:"\f810"}.fa-icicles:before{content:"\f7ad"}.fa-heart-music-camera-bolt:before,.fa-icons:before{content:"\f86d"}.fa-id-badge:before{content:"\f2c1"}.fa-drivers-license:before,.fa-id-card:before{content:"\f2c2"}.fa-id-card-alt:before,.fa-id-card-clip:before{content:"\f47f"}.fa-igloo:before{content:"\f7ae"}.fa-image:before{content:"\f03e"}.fa-image-portrait:before,.fa-portrait:before{content:"\f3e0"}.fa-images:before{content:"\f302"}.fa-inbox:before{content:"\f01c"}.fa-indent:before{content:"\f03c"}.fa-indian-rupee-sign:before,.fa-indian-rupee:before,.fa-inr:before{content:"\e1bc"}.fa-industry:before{content:"\f275"}.fa-infinity:before{content:"\f534"}.fa-info:before{content:"\f129"}.fa-italic:before{content:"\f033"}.fa-j:before{content:"\4a"}.fa-jar:before{content:"\e516"}.fa-jar-wheat:before{content:"\e517"}.fa-jedi:before{content:"\f669"}.fa-fighter-jet:before,.fa-jet-fighter:before{content:"\f0fb"}.fa-jet-fighter-up:before{content:"\e518"}.fa-joint:before{content:"\f595"}.fa-jug-detergent:before{content:"\e519"}.fa-k:before{content:"\4b"}.fa-kaaba:before{content:"\f66b"}.fa-key:before{content:"\f084"}.fa-keyboard:before{content:"\f11c"}.fa-khanda:before{content:"\f66d"}.fa-kip-sign:before{content:"\e1c4"}.fa-first-aid:before,.fa-kit-medical:before{content:"\f479"}.fa-kitchen-set:before{content:"\e51a"}.fa-kiwi-bird:before{content:"\f535"}.fa-l:before{content:"\4c"}.fa-land-mine-on:before{content:"\e51b"}.fa-landmark:before{content:"\f66f"}.fa-landmark-alt:before,.fa-landmark-dome:before{content:"\f752"}.fa-landmark-flag:before{content:"\e51c"}.fa-language:before{content:"\f1ab"}.fa-laptop:before{content:"\f109"}.fa-laptop-code:before{content:"\f5fc"}.fa-laptop-file:before{content:"\e51d"}.fa-laptop-medical:before{content:"\f812"}.fa-lari-sign:before{content:"\e1c8"}.fa-layer-group:before{content:"\f5fd"}.fa-leaf:before{content:"\f06c"}.fa-left-long:before,.fa-long-arrow-alt-left:before{content:"\f30a"}.fa-arrows-alt-h:before,.fa-left-right:before{content:"\f337"}.fa-lemon:before{content:"\f094"}.fa-less-than:before{content:"\3c"}.fa-less-than-equal:before{content:"\f537"}.fa-life-ring:before{content:"\f1cd"}.fa-lightbulb:before{content:"\f0eb"}.fa-lines-leaning:before{content:"\e51e"}.fa-chain:before,.fa-link:before{content:"\f0c1"}.fa-chain-broken:before,.fa-chain-slash:before,.fa-link-slash:before,.fa-unlink:before{content:"\f127"}.fa-lira-sign:before{content:"\f195"}.fa-list-squares:before,.fa-list:before{content:"\f03a"}.fa-list-check:before,.fa-tasks:before{content:"\f0ae"}.fa-list-1-2:before,.fa-list-numeric:before,.fa-list-ol:before{content:"\f0cb"}.fa-list-dots:before,.fa-list-ul:before{content:"\f0ca"}.fa-litecoin-sign:before{content:"\e1d3"}.fa-location-arrow:before{content:"\f124"}.fa-location-crosshairs:before,.fa-location:before{content:"\f601"}.fa-location-dot:before,.fa-map-marker-alt:before{content:"\f3c5"}.fa-location-pin:before,.fa-map-marker:before{content:"\f041"}.fa-location-pin-lock:before{content:"\e51f"}.fa-lock:before{content:"\f023"}.fa-lock-open:before{content:"\f3c1"}.fa-locust:before{content:"\e520"}.fa-lungs:before{content:"\f604"}.fa-lungs-virus:before{content:"\e067"}.fa-m:before{content:"\4d"}.fa-magnet:before{content:"\f076"}.fa-magnifying-glass:before,.fa-search:before{content:"\f002"}.fa-magnifying-glass-arrow-right:before{content:"\e521"}.fa-magnifying-glass-chart:before{content:"\e522"}.fa-magnifying-glass-dollar:before,.fa-search-dollar:before{content:"\f688"}.fa-magnifying-glass-location:before,.fa-search-location:before{content:"\f689"}.fa-magnifying-glass-minus:before,.fa-search-minus:before{content:"\f010"}.fa-magnifying-glass-plus:before,.fa-search-plus:before{content:"\f00e"}.fa-manat-sign:before{content:"\e1d5"}.fa-map:before{content:"\f279"}.fa-map-location:before,.fa-map-marked:before{content:"\f59f"}.fa-map-location-dot:before,.fa-map-marked-alt:before{content:"\f5a0"}.fa-map-pin:before{content:"\f276"}.fa-marker:before{content:"\f5a1"}.fa-mars:before{content:"\f222"}.fa-mars-and-venus:before{content:"\f224"}.fa-mars-and-venus-burst:before{content:"\e523"}.fa-mars-double:before{content:"\f227"}.fa-mars-stroke:before{content:"\f229"}.fa-mars-stroke-h:before,.fa-mars-stroke-right:before{content:"\f22b"}.fa-mars-stroke-up:before,.fa-mars-stroke-v:before{content:"\f22a"}.fa-glass-martini-alt:before,.fa-martini-glass:before{content:"\f57b"}.fa-cocktail:before,.fa-martini-glass-citrus:before{content:"\f561"}.fa-glass-martini:before,.fa-martini-glass-empty:before{content:"\f000"}.fa-mask:before{content:"\f6fa"}.fa-mask-face:before{content:"\e1d7"}.fa-mask-ventilator:before{content:"\e524"}.fa-masks-theater:before,.fa-theater-masks:before{content:"\f630"}.fa-mattress-pillow:before{content:"\e525"}.fa-expand-arrows-alt:before,.fa-maximize:before{content:"\f31e"}.fa-medal:before{content:"\f5a2"}.fa-memory:before{content:"\f538"}.fa-menorah:before{content:"\f676"}.fa-mercury:before{content:"\f223"}.fa-comment-alt:before,.fa-message:before{content:"\f27a"}.fa-meteor:before{content:"\f753"}.fa-microchip:before{content:"\f2db"}.fa-microphone:before{content:"\f130"}.fa-microphone-alt:before,.fa-microphone-lines:before{content:"\f3c9"}.fa-microphone-alt-slash:before,.fa-microphone-lines-slash:before{content:"\f539"}.fa-microphone-slash:before{content:"\f131"}.fa-microscope:before{content:"\f610"}.fa-mill-sign:before{content:"\e1ed"}.fa-compress-arrows-alt:before,.fa-minimize:before{content:"\f78c"}.fa-minus:before,.fa-subtract:before{content:"\f068"}.fa-mitten:before{content:"\f7b5"}.fa-mobile-android:before,.fa-mobile-phone:before,.fa-mobile:before{content:"\f3ce"}.fa-mobile-button:before{content:"\f10b"}.fa-mobile-retro:before{content:"\e527"}.fa-mobile-android-alt:before,.fa-mobile-screen:before{content:"\f3cf"}.fa-mobile-alt:before,.fa-mobile-screen-button:before{content:"\f3cd"}.fa-money-bill:before{content:"\f0d6"}.fa-money-bill-1:before,.fa-money-bill-alt:before{content:"\f3d1"}.fa-money-bill-1-wave:before,.fa-money-bill-wave-alt:before{content:"\f53b"}.fa-money-bill-transfer:before{content:"\e528"}.fa-money-bill-trend-up:before{content:"\e529"}.fa-money-bill-wave:before{content:"\f53a"}.fa-money-bill-wheat:before{content:"\e52a"}.fa-money-bills:before{content:"\e1f3"}.fa-money-check:before{content:"\f53c"}.fa-money-check-alt:before,.fa-money-check-dollar:before{content:"\f53d"}.fa-monument:before{content:"\f5a6"}.fa-moon:before{content:"\f186"}.fa-mortar-pestle:before{content:"\f5a7"}.fa-mosque:before{content:"\f678"}.fa-mosquito:before{content:"\e52b"}.fa-mosquito-net:before{content:"\e52c"}.fa-motorcycle:before{content:"\f21c"}.fa-mound:before{content:"\e52d"}.fa-mountain:before{content:"\f6fc"}.fa-mountain-city:before{content:"\e52e"}.fa-mountain-sun:before{content:"\e52f"}.fa-mug-hot:before{content:"\f7b6"}.fa-coffee:before,.fa-mug-saucer:before{content:"\f0f4"}.fa-music:before{content:"\f001"}.fa-n:before{content:"\4e"}.fa-naira-sign:before{content:"\e1f6"}.fa-network-wired:before{content:"\f6ff"}.fa-neuter:before{content:"\f22c"}.fa-newspaper:before{content:"\f1ea"}.fa-not-equal:before{content:"\f53e"}.fa-notdef:before{content:"\e1fe"}.fa-note-sticky:before,.fa-sticky-note:before{content:"\f249"}.fa-notes-medical:before{content:"\f481"}.fa-o:before{content:"\4f"}.fa-object-group:before{content:"\f247"}.fa-object-ungroup:before{content:"\f248"}.fa-oil-can:before{content:"\f613"}.fa-oil-well:before{content:"\e532"}.fa-om:before{content:"\f679"}.fa-otter:before{content:"\f700"}.fa-dedent:before,.fa-outdent:before{content:"\f03b"}.fa-p:before{content:"\50"}.fa-pager:before{content:"\f815"}.fa-paint-roller:before{content:"\f5aa"}.fa-paint-brush:before,.fa-paintbrush:before{content:"\f1fc"}.fa-palette:before{content:"\f53f"}.fa-pallet:before{content:"\f482"}.fa-panorama:before{content:"\e209"}.fa-paper-plane:before{content:"\f1d8"}.fa-paperclip:before{content:"\f0c6"}.fa-parachute-box:before{content:"\f4cd"}.fa-paragraph:before{content:"\f1dd"}.fa-passport:before{content:"\f5ab"}.fa-file-clipboard:before,.fa-paste:before{content:"\f0ea"}.fa-pause:before{content:"\f04c"}.fa-paw:before{content:"\f1b0"}.fa-peace:before{content:"\f67c"}.fa-pen:before{content:"\f304"}.fa-pen-alt:before,.fa-pen-clip:before{content:"\f305"}.fa-pen-fancy:before{content:"\f5ac"}.fa-pen-nib:before{content:"\f5ad"}.fa-pen-ruler:before,.fa-pencil-ruler:before{content:"\f5ae"}.fa-edit:before,.fa-pen-to-square:before{content:"\f044"}.fa-pencil-alt:before,.fa-pencil:before{content:"\f303"}.fa-people-arrows-left-right:before,.fa-people-arrows:before{content:"\e068"}.fa-people-carry-box:before,.fa-people-carry:before{content:"\f4ce"}.fa-people-group:before{content:"\e533"}.fa-people-line:before{content:"\e534"}.fa-people-pulling:before{content:"\e535"}.fa-people-robbery:before{content:"\e536"}.fa-people-roof:before{content:"\e537"}.fa-pepper-hot:before{content:"\f816"}.fa-percent:before,.fa-percentage:before{content:"\25"}.fa-male:before,.fa-person:before{content:"\f183"}.fa-person-arrow-down-to-line:before{content:"\e538"}.fa-person-arrow-up-from-line:before{content:"\e539"}.fa-biking:before,.fa-person-biking:before{content:"\f84a"}.fa-person-booth:before{content:"\f756"}.fa-person-breastfeeding:before{content:"\e53a"}.fa-person-burst:before{content:"\e53b"}.fa-person-cane:before{content:"\e53c"}.fa-person-chalkboard:before{content:"\e53d"}.fa-person-circle-check:before{content:"\e53e"}.fa-person-circle-exclamation:before{content:"\e53f"}.fa-person-circle-minus:before{content:"\e540"}.fa-person-circle-plus:before{content:"\e541"}.fa-person-circle-question:before{content:"\e542"}.fa-person-circle-xmark:before{content:"\e543"}.fa-digging:before,.fa-person-digging:before{content:"\f85e"}.fa-diagnoses:before,.fa-person-dots-from-line:before{content:"\f470"}.fa-female:before,.fa-person-dress:before{content:"\f182"}.fa-person-dress-burst:before{content:"\e544"}.fa-person-drowning:before{content:"\e545"}.fa-person-falling:before{content:"\e546"}.fa-person-falling-burst:before{content:"\e547"}.fa-person-half-dress:before{content:"\e548"}.fa-person-harassing:before{content:"\e549"}.fa-hiking:before,.fa-person-hiking:before{content:"\f6ec"}.fa-person-military-pointing:before{content:"\e54a"}.fa-person-military-rifle:before{content:"\e54b"}.fa-person-military-to-person:before{content:"\e54c"}.fa-person-praying:before,.fa-pray:before{content:"\f683"}.fa-person-pregnant:before{content:"\e31e"}.fa-person-rays:before{content:"\e54d"}.fa-person-rifle:before{content:"\e54e"}.fa-person-running:before,.fa-running:before{content:"\f70c"}.fa-person-shelter:before{content:"\e54f"}.fa-person-skating:before,.fa-skating:before{content:"\f7c5"}.fa-person-skiing:before,.fa-skiing:before{content:"\f7c9"}.fa-person-skiing-nordic:before,.fa-skiing-nordic:before{content:"\f7ca"}.fa-person-snowboarding:before,.fa-snowboarding:before{content:"\f7ce"}.fa-person-swimming:before,.fa-swimmer:before{content:"\f5c4"}.fa-person-through-window:before{content:"\e5a9"}.fa-person-walking:before,.fa-walking:before{content:"\f554"}.fa-person-walking-arrow-loop-left:before{content:"\e551"}.fa-person-walking-arrow-right:before{content:"\e552"}.fa-person-walking-dashed-line-arrow-right:before{content:"\e553"}.fa-person-walking-luggage:before{content:"\e554"}.fa-blind:before,.fa-person-walking-with-cane:before{content:"\f29d"}.fa-peseta-sign:before{content:"\e221"}.fa-peso-sign:before{content:"\e222"}.fa-phone:before{content:"\f095"}.fa-phone-alt:before,.fa-phone-flip:before{content:"\f879"}.fa-phone-slash:before{content:"\f3dd"}.fa-phone-volume:before,.fa-volume-control-phone:before{content:"\f2a0"}.fa-photo-film:before,.fa-photo-video:before{content:"\f87c"}.fa-piggy-bank:before{content:"\f4d3"}.fa-pills:before{content:"\f484"}.fa-pizza-slice:before{content:"\f818"}.fa-place-of-worship:before{content:"\f67f"}.fa-plane:before{content:"\f072"}.fa-plane-arrival:before{content:"\f5af"}.fa-plane-circle-check:before{content:"\e555"}.fa-plane-circle-exclamation:before{content:"\e556"}.fa-plane-circle-xmark:before{content:"\e557"}.fa-plane-departure:before{content:"\f5b0"}.fa-plane-lock:before{content:"\e558"}.fa-plane-slash:before{content:"\e069"}.fa-plane-up:before{content:"\e22d"}.fa-plant-wilt:before{content:"\e5aa"}.fa-plate-wheat:before{content:"\e55a"}.fa-play:before{content:"\f04b"}.fa-plug:before{content:"\f1e6"}.fa-plug-circle-bolt:before{content:"\e55b"}.fa-plug-circle-check:before{content:"\e55c"}.fa-plug-circle-exclamation:before{content:"\e55d"}.fa-plug-circle-minus:before{content:"\e55e"}.fa-plug-circle-plus:before{content:"\e55f"}.fa-plug-circle-xmark:before{content:"\e560"}.fa-add:before,.fa-plus:before{content:"\2b"}.fa-plus-minus:before{content:"\e43c"}.fa-podcast:before{content:"\f2ce"}.fa-poo:before{content:"\f2fe"}.fa-poo-bolt:before,.fa-poo-storm:before{content:"\f75a"}.fa-poop:before{content:"\f619"}.fa-power-off:before{content:"\f011"}.fa-prescription:before{content:"\f5b1"}.fa-prescription-bottle:before{content:"\f485"}.fa-prescription-bottle-alt:before,.fa-prescription-bottle-medical:before{content:"\f486"}.fa-print:before{content:"\f02f"}.fa-pump-medical:before{content:"\e06a"}.fa-pump-soap:before{content:"\e06b"}.fa-puzzle-piece:before{content:"\f12e"}.fa-q:before{content:"\51"}.fa-qrcode:before{content:"\f029"}.fa-question:before{content:"\3f"}.fa-quote-left-alt:before,.fa-quote-left:before{content:"\f10d"}.fa-quote-right-alt:before,.fa-quote-right:before{content:"\f10e"}.fa-r:before{content:"\52"}.fa-radiation:before{content:"\f7b9"}.fa-radio:before{content:"\f8d7"}.fa-rainbow:before{content:"\f75b"}.fa-ranking-star:before{content:"\e561"}.fa-receipt:before{content:"\f543"}.fa-record-vinyl:before{content:"\f8d9"}.fa-ad:before,.fa-rectangle-ad:before{content:"\f641"}.fa-list-alt:before,.fa-rectangle-list:before{content:"\f022"}.fa-rectangle-times:before,.fa-rectangle-xmark:before,.fa-times-rectangle:before,.fa-window-close:before{content:"\f410"}.fa-recycle:before{content:"\f1b8"}.fa-registered:before{content:"\f25d"}.fa-repeat:before{content:"\f363"}.fa-mail-reply:before,.fa-reply:before{content:"\f3e5"}.fa-mail-reply-all:before,.fa-reply-all:before{content:"\f122"}.fa-republican:before{content:"\f75e"}.fa-restroom:before{content:"\f7bd"}.fa-retweet:before{content:"\f079"}.fa-ribbon:before{content:"\f4d6"}.fa-right-from-bracket:before,.fa-sign-out-alt:before{content:"\f2f5"}.fa-exchange-alt:before,.fa-right-left:before{content:"\f362"}.fa-long-arrow-alt-right:before,.fa-right-long:before{content:"\f30b"}.fa-right-to-bracket:before,.fa-sign-in-alt:before{content:"\f2f6"}.fa-ring:before{content:"\f70b"}.fa-road:before{content:"\f018"}.fa-road-barrier:before{content:"\e562"}.fa-road-bridge:before{content:"\e563"}.fa-road-circle-check:before{content:"\e564"}.fa-road-circle-exclamation:before{content:"\e565"}.fa-road-circle-xmark:before{content:"\e566"}.fa-road-lock:before{content:"\e567"}.fa-road-spikes:before{content:"\e568"}.fa-robot:before{content:"\f544"}.fa-rocket:before{content:"\f135"}.fa-rotate:before,.fa-sync-alt:before{content:"\f2f1"}.fa-rotate-back:before,.fa-rotate-backward:before,.fa-rotate-left:before,.fa-undo-alt:before{content:"\f2ea"}.fa-redo-alt:before,.fa-rotate-forward:before,.fa-rotate-right:before{content:"\f2f9"}.fa-route:before{content:"\f4d7"}.fa-feed:before,.fa-rss:before{content:"\f09e"}.fa-rouble:before,.fa-rub:before,.fa-ruble-sign:before,.fa-ruble:before{content:"\f158"}.fa-rug:before{content:"\e569"}.fa-ruler:before{content:"\f545"}.fa-ruler-combined:before{content:"\f546"}.fa-ruler-horizontal:before{content:"\f547"}.fa-ruler-vertical:before{content:"\f548"}.fa-rupee-sign:before,.fa-rupee:before{content:"\f156"}.fa-rupiah-sign:before{content:"\e23d"}.fa-s:before{content:"\53"}.fa-sack-dollar:before{content:"\f81d"}.fa-sack-xmark:before{content:"\e56a"}.fa-sailboat:before{content:"\e445"}.fa-satellite:before{content:"\f7bf"}.fa-satellite-dish:before{content:"\f7c0"}.fa-balance-scale:before,.fa-scale-balanced:before{content:"\f24e"}.fa-balance-scale-left:before,.fa-scale-unbalanced:before{content:"\f515"}.fa-balance-scale-right:before,.fa-scale-unbalanced-flip:before{content:"\f516"}.fa-school:before{content:"\f549"}.fa-school-circle-check:before{content:"\e56b"}.fa-school-circle-exclamation:before{content:"\e56c"}.fa-school-circle-xmark:before{content:"\e56d"}.fa-school-flag:before{content:"\e56e"}.fa-school-lock:before{content:"\e56f"}.fa-cut:before,.fa-scissors:before{content:"\f0c4"}.fa-screwdriver:before{content:"\f54a"}.fa-screwdriver-wrench:before,.fa-tools:before{content:"\f7d9"}.fa-scroll:before{content:"\f70e"}.fa-scroll-torah:before,.fa-torah:before{content:"\f6a0"}.fa-sd-card:before{content:"\f7c2"}.fa-section:before{content:"\e447"}.fa-seedling:before,.fa-sprout:before{content:"\f4d8"}.fa-server:before{content:"\f233"}.fa-shapes:before,.fa-triangle-circle-square:before{content:"\f61f"}.fa-arrow-turn-right:before,.fa-mail-forward:before,.fa-share:before{content:"\f064"}.fa-share-from-square:before,.fa-share-square:before{content:"\f14d"}.fa-share-alt:before,.fa-share-nodes:before{content:"\f1e0"}.fa-sheet-plastic:before{content:"\e571"}.fa-ils:before,.fa-shekel-sign:before,.fa-shekel:before,.fa-sheqel-sign:before,.fa-sheqel:before{content:"\f20b"}.fa-shield-blank:before,.fa-shield:before{content:"\f132"}.fa-shield-cat:before{content:"\e572"}.fa-shield-dog:before{content:"\e573"}.fa-shield-alt:before,.fa-shield-halved:before{content:"\f3ed"}.fa-shield-heart:before{content:"\e574"}.fa-shield-virus:before{content:"\e06c"}.fa-ship:before{content:"\f21a"}.fa-shirt:before,.fa-t-shirt:before,.fa-tshirt:before{content:"\f553"}.fa-shoe-prints:before{content:"\f54b"}.fa-shop:before,.fa-store-alt:before{content:"\f54f"}.fa-shop-lock:before{content:"\e4a5"}.fa-shop-slash:before,.fa-store-alt-slash:before{content:"\e070"}.fa-shower:before{content:"\f2cc"}.fa-shrimp:before{content:"\e448"}.fa-random:before,.fa-shuffle:before{content:"\f074"}.fa-shuttle-space:before,.fa-space-shuttle:before{content:"\f197"}.fa-sign-hanging:before,.fa-sign:before{content:"\f4d9"}.fa-signal-5:before,.fa-signal-perfect:before,.fa-signal:before{content:"\f012"}.fa-signature:before{content:"\f5b7"}.fa-map-signs:before,.fa-signs-post:before{content:"\f277"}.fa-sim-card:before{content:"\f7c4"}.fa-sink:before{content:"\e06d"}.fa-sitemap:before{content:"\f0e8"}.fa-skull:before{content:"\f54c"}.fa-skull-crossbones:before{content:"\f714"}.fa-slash:before{content:"\f715"}.fa-sleigh:before{content:"\f7cc"}.fa-sliders-h:before,.fa-sliders:before{content:"\f1de"}.fa-smog:before{content:"\f75f"}.fa-smoking:before{content:"\f48d"}.fa-snowflake:before{content:"\f2dc"}.fa-snowman:before{content:"\f7d0"}.fa-snowplow:before{content:"\f7d2"}.fa-soap:before{content:"\e06e"}.fa-socks:before{content:"\f696"}.fa-solar-panel:before{content:"\f5ba"}.fa-sort:before,.fa-unsorted:before{content:"\f0dc"}.fa-sort-desc:before,.fa-sort-down:before{content:"\f0dd"}.fa-sort-asc:before,.fa-sort-up:before{content:"\f0de"}.fa-spa:before{content:"\f5bb"}.fa-pastafarianism:before,.fa-spaghetti-monster-flying:before{content:"\f67b"}.fa-spell-check:before{content:"\f891"}.fa-spider:before{content:"\f717"}.fa-spinner:before{content:"\f110"}.fa-splotch:before{content:"\f5bc"}.fa-spoon:before,.fa-utensil-spoon:before{content:"\f2e5"}.fa-spray-can:before{content:"\f5bd"}.fa-air-freshener:before,.fa-spray-can-sparkles:before{content:"\f5d0"}.fa-square:before{content:"\f0c8"}.fa-external-link-square:before,.fa-square-arrow-up-right:before{content:"\f14c"}.fa-caret-square-down:before,.fa-square-caret-down:before{content:"\f150"}.fa-caret-square-left:before,.fa-square-caret-left:before{content:"\f191"}.fa-caret-square-right:before,.fa-square-caret-right:before{content:"\f152"}.fa-caret-square-up:before,.fa-square-caret-up:before{content:"\f151"}.fa-check-square:before,.fa-square-check:before{content:"\f14a"}.fa-envelope-square:before,.fa-square-envelope:before{content:"\f199"}.fa-square-full:before{content:"\f45c"}.fa-h-square:before,.fa-square-h:before{content:"\f0fd"}.fa-minus-square:before,.fa-square-minus:before{content:"\f146"}.fa-square-nfi:before{content:"\e576"}.fa-parking:before,.fa-square-parking:before{content:"\f540"}.fa-pen-square:before,.fa-pencil-square:before,.fa-square-pen:before{content:"\f14b"}.fa-square-person-confined:before{content:"\e577"}.fa-phone-square:before,.fa-square-phone:before{content:"\f098"}.fa-phone-square-alt:before,.fa-square-phone-flip:before{content:"\f87b"}.fa-plus-square:before,.fa-square-plus:before{content:"\f0fe"}.fa-poll-h:before,.fa-square-poll-horizontal:before{content:"\f682"}.fa-poll:before,.fa-square-poll-vertical:before{content:"\f681"}.fa-square-root-alt:before,.fa-square-root-variable:before{content:"\f698"}.fa-rss-square:before,.fa-square-rss:before{content:"\f143"}.fa-share-alt-square:before,.fa-square-share-nodes:before{content:"\f1e1"}.fa-external-link-square-alt:before,.fa-square-up-right:before{content:"\f360"}.fa-square-virus:before{content:"\e578"}.fa-square-xmark:before,.fa-times-square:before,.fa-xmark-square:before{content:"\f2d3"}.fa-rod-asclepius:before,.fa-rod-snake:before,.fa-staff-aesculapius:before,.fa-staff-snake:before{content:"\e579"}.fa-stairs:before{content:"\e289"}.fa-stamp:before{content:"\f5bf"}.fa-stapler:before{content:"\e5af"}.fa-star:before{content:"\f005"}.fa-star-and-crescent:before{content:"\f699"}.fa-star-half:before{content:"\f089"}.fa-star-half-alt:before,.fa-star-half-stroke:before{content:"\f5c0"}.fa-star-of-david:before{content:"\f69a"}.fa-star-of-life:before{content:"\f621"}.fa-gbp:before,.fa-pound-sign:before,.fa-sterling-sign:before{content:"\f154"}.fa-stethoscope:before{content:"\f0f1"}.fa-stop:before{content:"\f04d"}.fa-stopwatch:before{content:"\f2f2"}.fa-stopwatch-20:before{content:"\e06f"}.fa-store:before{content:"\f54e"}.fa-store-slash:before{content:"\e071"}.fa-street-view:before{content:"\f21d"}.fa-strikethrough:before{content:"\f0cc"}.fa-stroopwafel:before{content:"\f551"}.fa-subscript:before{content:"\f12c"}.fa-suitcase:before{content:"\f0f2"}.fa-medkit:before,.fa-suitcase-medical:before{content:"\f0fa"}.fa-suitcase-rolling:before{content:"\f5c1"}.fa-sun:before{content:"\f185"}.fa-sun-plant-wilt:before{content:"\e57a"}.fa-superscript:before{content:"\f12b"}.fa-swatchbook:before{content:"\f5c3"}.fa-synagogue:before{content:"\f69b"}.fa-syringe:before{content:"\f48e"}.fa-t:before{content:"\54"}.fa-table:before{content:"\f0ce"}.fa-table-cells:before,.fa-th:before{content:"\f00a"}.fa-table-cells-large:before,.fa-th-large:before{content:"\f009"}.fa-columns:before,.fa-table-columns:before{content:"\f0db"}.fa-table-list:before,.fa-th-list:before{content:"\f00b"}.fa-ping-pong-paddle-ball:before,.fa-table-tennis-paddle-ball:before,.fa-table-tennis:before{content:"\f45d"}.fa-tablet-android:before,.fa-tablet:before{content:"\f3fb"}.fa-tablet-button:before{content:"\f10a"}.fa-tablet-alt:before,.fa-tablet-screen-button:before{content:"\f3fa"}.fa-tablets:before{content:"\f490"}.fa-digital-tachograph:before,.fa-tachograph-digital:before{content:"\f566"}.fa-tag:before{content:"\f02b"}.fa-tags:before{content:"\f02c"}.fa-tape:before{content:"\f4db"}.fa-tarp:before{content:"\e57b"}.fa-tarp-droplet:before{content:"\e57c"}.fa-cab:before,.fa-taxi:before{content:"\f1ba"}.fa-teeth:before{content:"\f62e"}.fa-teeth-open:before{content:"\f62f"}.fa-temperature-arrow-down:before,.fa-temperature-down:before{content:"\e03f"}.fa-temperature-arrow-up:before,.fa-temperature-up:before{content:"\e040"}.fa-temperature-0:before,.fa-temperature-empty:before,.fa-thermometer-0:before,.fa-thermometer-empty:before{content:"\f2cb"}.fa-temperature-4:before,.fa-temperature-full:before,.fa-thermometer-4:before,.fa-thermometer-full:before{content:"\f2c7"}.fa-temperature-2:before,.fa-temperature-half:before,.fa-thermometer-2:before,.fa-thermometer-half:before{content:"\f2c9"}.fa-temperature-high:before{content:"\f769"}.fa-temperature-low:before{content:"\f76b"}.fa-temperature-1:before,.fa-temperature-quarter:before,.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:"\f2ca"}.fa-temperature-3:before,.fa-temperature-three-quarters:before,.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:"\f2c8"}.fa-tenge-sign:before,.fa-tenge:before{content:"\f7d7"}.fa-tent:before{content:"\e57d"}.fa-tent-arrow-down-to-line:before{content:"\e57e"}.fa-tent-arrow-left-right:before{content:"\e57f"}.fa-tent-arrow-turn-left:before{content:"\e580"}.fa-tent-arrows-down:before{content:"\e581"}.fa-tents:before{content:"\e582"}.fa-terminal:before{content:"\f120"}.fa-text-height:before{content:"\f034"}.fa-remove-format:before,.fa-text-slash:before{content:"\f87d"}.fa-text-width:before{content:"\f035"}.fa-thermometer:before{content:"\f491"}.fa-thumbs-down:before{content:"\f165"}.fa-thumbs-up:before{content:"\f164"}.fa-thumb-tack:before,.fa-thumbtack:before{content:"\f08d"}.fa-ticket:before{content:"\f145"}.fa-ticket-alt:before,.fa-ticket-simple:before{content:"\f3ff"}.fa-timeline:before{content:"\e29c"}.fa-toggle-off:before{content:"\f204"}.fa-toggle-on:before{content:"\f205"}.fa-toilet:before{content:"\f7d8"}.fa-toilet-paper:before{content:"\f71e"}.fa-toilet-paper-slash:before{content:"\e072"}.fa-toilet-portable:before{content:"\e583"}.fa-toilets-portable:before{content:"\e584"}.fa-toolbox:before{content:"\f552"}.fa-tooth:before{content:"\f5c9"}.fa-torii-gate:before{content:"\f6a1"}.fa-tornado:before{content:"\f76f"}.fa-broadcast-tower:before,.fa-tower-broadcast:before{content:"\f519"}.fa-tower-cell:before{content:"\e585"}.fa-tower-observation:before{content:"\e586"}.fa-tractor:before{content:"\f722"}.fa-trademark:before{content:"\f25c"}.fa-traffic-light:before{content:"\f637"}.fa-trailer:before{content:"\e041"}.fa-train:before{content:"\f238"}.fa-subway:before,.fa-train-subway:before{content:"\f239"}.fa-train-tram:before{content:"\e5b4"}.fa-transgender-alt:before,.fa-transgender:before{content:"\f225"}.fa-trash:before{content:"\f1f8"}.fa-trash-arrow-up:before,.fa-trash-restore:before{content:"\f829"}.fa-trash-alt:before,.fa-trash-can:before{content:"\f2ed"}.fa-trash-can-arrow-up:before,.fa-trash-restore-alt:before{content:"\f82a"}.fa-tree:before{content:"\f1bb"}.fa-tree-city:before{content:"\e587"}.fa-exclamation-triangle:before,.fa-triangle-exclamation:before,.fa-warning:before{content:"\f071"}.fa-trophy:before{content:"\f091"}.fa-trowel:before{content:"\e589"}.fa-trowel-bricks:before{content:"\e58a"}.fa-truck:before{content:"\f0d1"}.fa-truck-arrow-right:before{content:"\e58b"}.fa-truck-droplet:before{content:"\e58c"}.fa-shipping-fast:before,.fa-truck-fast:before{content:"\f48b"}.fa-truck-field:before{content:"\e58d"}.fa-truck-field-un:before{content:"\e58e"}.fa-truck-front:before{content:"\e2b7"}.fa-ambulance:before,.fa-truck-medical:before{content:"\f0f9"}.fa-truck-monster:before{content:"\f63b"}.fa-truck-moving:before{content:"\f4df"}.fa-truck-pickup:before{content:"\f63c"}.fa-truck-plane:before{content:"\e58f"}.fa-truck-loading:before,.fa-truck-ramp-box:before{content:"\f4de"}.fa-teletype:before,.fa-tty:before{content:"\f1e4"}.fa-try:before,.fa-turkish-lira-sign:before,.fa-turkish-lira:before{content:"\e2bb"}.fa-level-down-alt:before,.fa-turn-down:before{content:"\f3be"}.fa-level-up-alt:before,.fa-turn-up:before{content:"\f3bf"}.fa-television:before,.fa-tv-alt:before,.fa-tv:before{content:"\f26c"}.fa-u:before{content:"\55"}.fa-umbrella:before{content:"\f0e9"}.fa-umbrella-beach:before{content:"\f5ca"}.fa-underline:before{content:"\f0cd"}.fa-universal-access:before{content:"\f29a"}.fa-unlock:before{content:"\f09c"}.fa-unlock-alt:before,.fa-unlock-keyhole:before{content:"\f13e"}.fa-arrows-alt-v:before,.fa-up-down:before{content:"\f338"}.fa-arrows-alt:before,.fa-up-down-left-right:before{content:"\f0b2"}.fa-long-arrow-alt-up:before,.fa-up-long:before{content:"\f30c"}.fa-expand-alt:before,.fa-up-right-and-down-left-from-center:before{content:"\f424"}.fa-external-link-alt:before,.fa-up-right-from-square:before{content:"\f35d"}.fa-upload:before{content:"\f093"}.fa-user:before{content:"\f007"}.fa-user-astronaut:before{content:"\f4fb"}.fa-user-check:before{content:"\f4fc"}.fa-user-clock:before{content:"\f4fd"}.fa-user-doctor:before,.fa-user-md:before{content:"\f0f0"}.fa-user-cog:before,.fa-user-gear:before{content:"\f4fe"}.fa-user-graduate:before{content:"\f501"}.fa-user-friends:before,.fa-user-group:before{content:"\f500"}.fa-user-injured:before{content:"\f728"}.fa-user-alt:before,.fa-user-large:before{content:"\f406"}.fa-user-alt-slash:before,.fa-user-large-slash:before{content:"\f4fa"}.fa-user-lock:before{content:"\f502"}.fa-user-minus:before{content:"\f503"}.fa-user-ninja:before{content:"\f504"}.fa-user-nurse:before{content:"\f82f"}.fa-user-edit:before,.fa-user-pen:before{content:"\f4ff"}.fa-user-plus:before{content:"\f234"}.fa-user-secret:before{content:"\f21b"}.fa-user-shield:before{content:"\f505"}.fa-user-slash:before{content:"\f506"}.fa-user-tag:before{content:"\f507"}.fa-user-tie:before{content:"\f508"}.fa-user-times:before,.fa-user-xmark:before{content:"\f235"}.fa-users:before{content:"\f0c0"}.fa-users-between-lines:before{content:"\e591"}.fa-users-cog:before,.fa-users-gear:before{content:"\f509"}.fa-users-line:before{content:"\e592"}.fa-users-rays:before{content:"\e593"}.fa-users-rectangle:before{content:"\e594"}.fa-users-slash:before{content:"\e073"}.fa-users-viewfinder:before{content:"\e595"}.fa-cutlery:before,.fa-utensils:before{content:"\f2e7"}.fa-v:before{content:"\56"}.fa-shuttle-van:before,.fa-van-shuttle:before{content:"\f5b6"}.fa-vault:before{content:"\e2c5"}.fa-vector-square:before{content:"\f5cb"}.fa-venus:before{content:"\f221"}.fa-venus-double:before{content:"\f226"}.fa-venus-mars:before{content:"\f228"}.fa-vest:before{content:"\e085"}.fa-vest-patches:before{content:"\e086"}.fa-vial:before{content:"\f492"}.fa-vial-circle-check:before{content:"\e596"}.fa-vial-virus:before{content:"\e597"}.fa-vials:before{content:"\f493"}.fa-video-camera:before,.fa-video:before{content:"\f03d"}.fa-video-slash:before{content:"\f4e2"}.fa-vihara:before{content:"\f6a7"}.fa-virus:before{content:"\e074"}.fa-virus-covid:before{content:"\e4a8"}.fa-virus-covid-slash:before{content:"\e4a9"}.fa-virus-slash:before{content:"\e075"}.fa-viruses:before{content:"\e076"}.fa-voicemail:before{content:"\f897"}.fa-volcano:before{content:"\f770"}.fa-volleyball-ball:before,.fa-volleyball:before{content:"\f45f"}.fa-volume-high:before,.fa-volume-up:before{content:"\f028"}.fa-volume-down:before,.fa-volume-low:before{content:"\f027"}.fa-volume-off:before{content:"\f026"}.fa-volume-mute:before,.fa-volume-times:before,.fa-volume-xmark:before{content:"\f6a9"}.fa-vr-cardboard:before{content:"\f729"}.fa-w:before{content:"\57"}.fa-walkie-talkie:before{content:"\f8ef"}.fa-wallet:before{content:"\f555"}.fa-magic:before,.fa-wand-magic:before{content:"\f0d0"}.fa-magic-wand-sparkles:before,.fa-wand-magic-sparkles:before{content:"\e2ca"}.fa-wand-sparkles:before{content:"\f72b"}.fa-warehouse:before{content:"\f494"}.fa-water:before{content:"\f773"}.fa-ladder-water:before,.fa-swimming-pool:before,.fa-water-ladder:before{content:"\f5c5"}.fa-wave-square:before{content:"\f83e"}.fa-weight-hanging:before{content:"\f5cd"}.fa-weight-scale:before,.fa-weight:before{content:"\f496"}.fa-wheat-alt:before,.fa-wheat-awn:before{content:"\e2cd"}.fa-wheat-awn-circle-exclamation:before{content:"\e598"}.fa-wheelchair:before{content:"\f193"}.fa-wheelchair-alt:before,.fa-wheelchair-move:before{content:"\e2ce"}.fa-glass-whiskey:before,.fa-whiskey-glass:before{content:"\f7a0"}.fa-wifi-3:before,.fa-wifi-strong:before,.fa-wifi:before{content:"\f1eb"}.fa-wind:before{content:"\f72e"}.fa-window-maximize:before{content:"\f2d0"}.fa-window-minimize:before{content:"\f2d1"}.fa-window-restore:before{content:"\f2d2"}.fa-wine-bottle:before{content:"\f72f"}.fa-wine-glass:before{content:"\f4e3"}.fa-wine-glass-alt:before,.fa-wine-glass-empty:before{content:"\f5ce"}.fa-krw:before,.fa-won-sign:before,.fa-won:before{content:"\f159"}.fa-worm:before{content:"\e599"}.fa-wrench:before{content:"\f0ad"}.fa-x:before{content:"\58"}.fa-x-ray:before{content:"\f497"}.fa-close:before,.fa-multiply:before,.fa-remove:before,.fa-times:before,.fa-xmark:before{content:"\f00d"}.fa-xmarks-lines:before{content:"\e59a"}.fa-y:before{content:"\59"}.fa-cny:before,.fa-jpy:before,.fa-rmb:before,.fa-yen-sign:before,.fa-yen:before{content:"\f157"}.fa-yin-yang:before{content:"\f6ad"}.fa-z:before{content:"\5a"}.fa-sr-only,.fa-sr-only-focusable:not(:focus),.sr-only,.sr-only-focusable:not(:focus){position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}:host,:root{--fa-font-brands:normal 400 1em/1 "Font Awesome 6 Brands"}@font-face{font-family:"Font Awesome 6 Brands";font-style:normal;font-weight:400;font-display:block;src:url(../webfonts/fa-brands-400.woff2) format("woff2"),url(../webfonts/fa-brands-400.ttf) format("truetype")}.fa-brands,.fab{font-family:"Font Awesome 6 Brands";font-weight:400}.fa-42-group:before,.fa-innosoft:before{content:"\e080"}.fa-500px:before{content:"\f26e"}.fa-accessible-icon:before{content:"\f368"}.fa-accusoft:before{content:"\f369"}.fa-adn:before{content:"\f170"}.fa-adversal:before{content:"\f36a"}.fa-affiliatetheme:before{content:"\f36b"}.fa-airbnb:before{content:"\f834"}.fa-algolia:before{content:"\f36c"}.fa-alipay:before{content:"\f642"}.fa-amazon:before{content:"\f270"}.fa-amazon-pay:before{content:"\f42c"}.fa-amilia:before{content:"\f36d"}.fa-android:before{content:"\f17b"}.fa-angellist:before{content:"\f209"}.fa-angrycreative:before{content:"\f36e"}.fa-angular:before{content:"\f420"}.fa-app-store:before{content:"\f36f"}.fa-app-store-ios:before{content:"\f370"}.fa-apper:before{content:"\f371"}.fa-apple:before{content:"\f179"}.fa-apple-pay:before{content:"\f415"}.fa-artstation:before{content:"\f77a"}.fa-asymmetrik:before{content:"\f372"}.fa-atlassian:before{content:"\f77b"}.fa-audible:before{content:"\f373"}.fa-autoprefixer:before{content:"\f41c"}.fa-avianex:before{content:"\f374"}.fa-aviato:before{content:"\f421"}.fa-aws:before{content:"\f375"}.fa-bandcamp:before{content:"\f2d5"}.fa-battle-net:before{content:"\f835"}.fa-behance:before{content:"\f1b4"}.fa-bilibili:before{content:"\e3d9"}.fa-bimobject:before{content:"\f378"}.fa-bitbucket:before{content:"\f171"}.fa-bitcoin:before{content:"\f379"}.fa-bity:before{content:"\f37a"}.fa-black-tie:before{content:"\f27e"}.fa-blackberry:before{content:"\f37b"}.fa-blogger:before{content:"\f37c"}.fa-blogger-b:before{content:"\f37d"}.fa-bluetooth:before{content:"\f293"}.fa-bluetooth-b:before{content:"\f294"}.fa-bootstrap:before{content:"\f836"}.fa-bots:before{content:"\e340"}.fa-btc:before{content:"\f15a"}.fa-buffer:before{content:"\f837"}.fa-buromobelexperte:before{content:"\f37f"}.fa-buy-n-large:before{content:"\f8a6"}.fa-buysellads:before{content:"\f20d"}.fa-canadian-maple-leaf:before{content:"\f785"}.fa-cc-amazon-pay:before{content:"\f42d"}.fa-cc-amex:before{content:"\f1f3"}.fa-cc-apple-pay:before{content:"\f416"}.fa-cc-diners-club:before{content:"\f24c"}.fa-cc-discover:before{content:"\f1f2"}.fa-cc-jcb:before{content:"\f24b"}.fa-cc-mastercard:before{content:"\f1f1"}.fa-cc-paypal:before{content:"\f1f4"}.fa-cc-stripe:before{content:"\f1f5"}.fa-cc-visa:before{content:"\f1f0"}.fa-centercode:before{content:"\f380"}.fa-centos:before{content:"\f789"}.fa-chrome:before{content:"\f268"}.fa-chromecast:before{content:"\f838"}.fa-cloudflare:before{content:"\e07d"}.fa-cloudscale:before{content:"\f383"}.fa-cloudsmith:before{content:"\f384"}.fa-cloudversify:before{content:"\f385"}.fa-cmplid:before{content:"\e360"}.fa-codepen:before{content:"\f1cb"}.fa-codiepie:before{content:"\f284"}.fa-confluence:before{content:"\f78d"}.fa-connectdevelop:before{content:"\f20e"}.fa-contao:before{content:"\f26d"}.fa-cotton-bureau:before{content:"\f89e"}.fa-cpanel:before{content:"\f388"}.fa-creative-commons:before{content:"\f25e"}.fa-creative-commons-by:before{content:"\f4e7"}.fa-creative-commons-nc:before{content:"\f4e8"}.fa-creative-commons-nc-eu:before{content:"\f4e9"}.fa-creative-commons-nc-jp:before{content:"\f4ea"}.fa-creative-commons-nd:before{content:"\f4eb"}.fa-creative-commons-pd:before{content:"\f4ec"}.fa-creative-commons-pd-alt:before{content:"\f4ed"}.fa-creative-commons-remix:before{content:"\f4ee"}.fa-creative-commons-sa:before{content:"\f4ef"}.fa-creative-commons-sampling:before{content:"\f4f0"}.fa-creative-commons-sampling-plus:before{content:"\f4f1"}.fa-creative-commons-share:before{content:"\f4f2"}.fa-creative-commons-zero:before{content:"\f4f3"}.fa-critical-role:before{content:"\f6c9"}.fa-css3:before{content:"\f13c"}.fa-css3-alt:before{content:"\f38b"}.fa-cuttlefish:before{content:"\f38c"}.fa-d-and-d:before{content:"\f38d"}.fa-d-and-d-beyond:before{content:"\f6ca"}.fa-dailymotion:before{content:"\e052"}.fa-dashcube:before{content:"\f210"}.fa-deezer:before{content:"\e077"}.fa-delicious:before{content:"\f1a5"}.fa-deploydog:before{content:"\f38e"}.fa-deskpro:before{content:"\f38f"}.fa-dev:before{content:"\f6cc"}.fa-deviantart:before{content:"\f1bd"}.fa-dhl:before{content:"\f790"}.fa-diaspora:before{content:"\f791"}.fa-digg:before{content:"\f1a6"}.fa-digital-ocean:before{content:"\f391"}.fa-discord:before{content:"\f392"}.fa-discourse:before{content:"\f393"}.fa-dochub:before{content:"\f394"}.fa-docker:before{content:"\f395"}.fa-draft2digital:before{content:"\f396"}.fa-dribbble:before{content:"\f17d"}.fa-dropbox:before{content:"\f16b"}.fa-drupal:before{content:"\f1a9"}.fa-dyalog:before{content:"\f399"}.fa-earlybirds:before{content:"\f39a"}.fa-ebay:before{content:"\f4f4"}.fa-edge:before{content:"\f282"}.fa-edge-legacy:before{content:"\e078"}.fa-elementor:before{content:"\f430"}.fa-ello:before{content:"\f5f1"}.fa-ember:before{content:"\f423"}.fa-empire:before{content:"\f1d1"}.fa-envira:before{content:"\f299"}.fa-erlang:before{content:"\f39d"}.fa-ethereum:before{content:"\f42e"}.fa-etsy:before{content:"\f2d7"}.fa-evernote:before{content:"\f839"}.fa-expeditedssl:before{content:"\f23e"}.fa-facebook:before{content:"\f09a"}.fa-facebook-f:before{content:"\f39e"}.fa-facebook-messenger:before{content:"\f39f"}.fa-fantasy-flight-games:before{content:"\f6dc"}.fa-fedex:before{content:"\f797"}.fa-fedora:before{content:"\f798"}.fa-figma:before{content:"\f799"}.fa-firefox:before{content:"\f269"}.fa-firefox-browser:before{content:"\e007"}.fa-first-order:before{content:"\f2b0"}.fa-first-order-alt:before{content:"\f50a"}.fa-firstdraft:before{content:"\f3a1"}.fa-flickr:before{content:"\f16e"}.fa-flipboard:before{content:"\f44d"}.fa-fly:before{content:"\f417"}.fa-font-awesome-flag:before,.fa-font-awesome-logo-full:before,.fa-font-awesome:before{content:"\f2b4"}.fa-fonticons:before{content:"\f280"}.fa-fonticons-fi:before{content:"\f3a2"}.fa-fort-awesome:before{content:"\f286"}.fa-fort-awesome-alt:before{content:"\f3a3"}.fa-forumbee:before{content:"\f211"}.fa-foursquare:before{content:"\f180"}.fa-free-code-camp:before{content:"\f2c5"}.fa-freebsd:before{content:"\f3a4"}.fa-fulcrum:before{content:"\f50b"}.fa-galactic-republic:before{content:"\f50c"}.fa-galactic-senate:before{content:"\f50d"}.fa-get-pocket:before{content:"\f265"}.fa-gg:before{content:"\f260"}.fa-gg-circle:before{content:"\f261"}.fa-git:before{content:"\f1d3"}.fa-git-alt:before{content:"\f841"}.fa-github:before{content:"\f09b"}.fa-github-alt:before{content:"\f113"}.fa-gitkraken:before{content:"\f3a6"}.fa-gitlab:before{content:"\f296"}.fa-gitter:before{content:"\f426"}.fa-glide:before{content:"\f2a5"}.fa-glide-g:before{content:"\f2a6"}.fa-gofore:before{content:"\f3a7"}.fa-golang:before{content:"\e40f"}.fa-goodreads:before{content:"\f3a8"}.fa-goodreads-g:before{content:"\f3a9"}.fa-google:before{content:"\f1a0"}.fa-google-drive:before{content:"\f3aa"}.fa-google-pay:before{content:"\e079"}.fa-google-play:before{content:"\f3ab"}.fa-google-plus:before{content:"\f2b3"}.fa-google-plus-g:before{content:"\f0d5"}.fa-google-wallet:before{content:"\f1ee"}.fa-gratipay:before{content:"\f184"}.fa-grav:before{content:"\f2d6"}.fa-gripfire:before{content:"\f3ac"}.fa-grunt:before{content:"\f3ad"}.fa-guilded:before{content:"\e07e"}.fa-gulp:before{content:"\f3ae"}.fa-hacker-news:before{content:"\f1d4"}.fa-hackerrank:before{content:"\f5f7"}.fa-hashnode:before{content:"\e499"}.fa-hips:before{content:"\f452"}.fa-hire-a-helper:before{content:"\f3b0"}.fa-hive:before{content:"\e07f"}.fa-hooli:before{content:"\f427"}.fa-hornbill:before{content:"\f592"}.fa-hotjar:before{content:"\f3b1"}.fa-houzz:before{content:"\f27c"}.fa-html5:before{content:"\f13b"}.fa-hubspot:before{content:"\f3b2"}.fa-ideal:before{content:"\e013"}.fa-imdb:before{content:"\f2d8"}.fa-instagram:before{content:"\f16d"}.fa-instalod:before{content:"\e081"}.fa-intercom:before{content:"\f7af"}.fa-internet-explorer:before{content:"\f26b"}.fa-invision:before{content:"\f7b0"}.fa-ioxhost:before{content:"\f208"}.fa-itch-io:before{content:"\f83a"}.fa-itunes:before{content:"\f3b4"}.fa-itunes-note:before{content:"\f3b5"}.fa-java:before{content:"\f4e4"}.fa-jedi-order:before{content:"\f50e"}.fa-jenkins:before{content:"\f3b6"}.fa-jira:before{content:"\f7b1"}.fa-joget:before{content:"\f3b7"}.fa-joomla:before{content:"\f1aa"}.fa-js:before{content:"\f3b8"}.fa-jsfiddle:before{content:"\f1cc"}.fa-kaggle:before{content:"\f5fa"}.fa-keybase:before{content:"\f4f5"}.fa-keycdn:before{content:"\f3ba"}.fa-kickstarter:before{content:"\f3bb"}.fa-kickstarter-k:before{content:"\f3bc"}.fa-korvue:before{content:"\f42f"}.fa-laravel:before{content:"\f3bd"}.fa-lastfm:before{content:"\f202"}.fa-leanpub:before{content:"\f212"}.fa-less:before{content:"\f41d"}.fa-line:before{content:"\f3c0"}.fa-linkedin:before{content:"\f08c"}.fa-linkedin-in:before{content:"\f0e1"}.fa-linode:before{content:"\f2b8"}.fa-linux:before{content:"\f17c"}.fa-lyft:before{content:"\f3c3"}.fa-magento:before{content:"\f3c4"}.fa-mailchimp:before{content:"\f59e"}.fa-mandalorian:before{content:"\f50f"}.fa-markdown:before{content:"\f60f"}.fa-mastodon:before{content:"\f4f6"}.fa-maxcdn:before{content:"\f136"}.fa-mdb:before{content:"\f8ca"}.fa-medapps:before{content:"\f3c6"}.fa-medium-m:before,.fa-medium:before{content:"\f23a"}.fa-medrt:before{content:"\f3c8"}.fa-meetup:before{content:"\f2e0"}.fa-megaport:before{content:"\f5a3"}.fa-mendeley:before{content:"\f7b3"}.fa-meta:before{content:"\e49b"}.fa-microblog:before{content:"\e01a"}.fa-microsoft:before{content:"\f3ca"}.fa-mix:before{content:"\f3cb"}.fa-mixcloud:before{content:"\f289"}.fa-mixer:before{content:"\e056"}.fa-mizuni:before{content:"\f3cc"}.fa-modx:before{content:"\f285"}.fa-monero:before{content:"\f3d0"}.fa-napster:before{content:"\f3d2"}.fa-neos:before{content:"\f612"}.fa-nfc-directional:before{content:"\e530"}.fa-nfc-symbol:before{content:"\e531"}.fa-nimblr:before{content:"\f5a8"}.fa-node:before{content:"\f419"}.fa-node-js:before{content:"\f3d3"}.fa-npm:before{content:"\f3d4"}.fa-ns8:before{content:"\f3d5"}.fa-nutritionix:before{content:"\f3d6"}.fa-octopus-deploy:before{content:"\e082"}.fa-odnoklassniki:before{content:"\f263"}.fa-old-republic:before{content:"\f510"}.fa-opencart:before{content:"\f23d"}.fa-openid:before{content:"\f19b"}.fa-opera:before{content:"\f26a"}.fa-optin-monster:before{content:"\f23c"}.fa-orcid:before{content:"\f8d2"}.fa-osi:before{content:"\f41a"}.fa-padlet:before{content:"\e4a0"}.fa-page4:before{content:"\f3d7"}.fa-pagelines:before{content:"\f18c"}.fa-palfed:before{content:"\f3d8"}.fa-patreon:before{content:"\f3d9"}.fa-paypal:before{content:"\f1ed"}.fa-perbyte:before{content:"\e083"}.fa-periscope:before{content:"\f3da"}.fa-phabricator:before{content:"\f3db"}.fa-phoenix-framework:before{content:"\f3dc"}.fa-phoenix-squadron:before{content:"\f511"}.fa-php:before{content:"\f457"}.fa-pied-piper:before{content:"\f2ae"}.fa-pied-piper-alt:before{content:"\f1a8"}.fa-pied-piper-hat:before{content:"\f4e5"}.fa-pied-piper-pp:before{content:"\f1a7"}.fa-pinterest:before{content:"\f0d2"}.fa-pinterest-p:before{content:"\f231"}.fa-pix:before{content:"\e43a"}.fa-playstation:before{content:"\f3df"}.fa-product-hunt:before{content:"\f288"}.fa-pushed:before{content:"\f3e1"}.fa-python:before{content:"\f3e2"}.fa-qq:before{content:"\f1d6"}.fa-quinscape:before{content:"\f459"}.fa-quora:before{content:"\f2c4"}.fa-r-project:before{content:"\f4f7"}.fa-raspberry-pi:before{content:"\f7bb"}.fa-ravelry:before{content:"\f2d9"}.fa-react:before{content:"\f41b"}.fa-reacteurope:before{content:"\f75d"}.fa-readme:before{content:"\f4d5"}.fa-rebel:before{content:"\f1d0"}.fa-red-river:before{content:"\f3e3"}.fa-reddit:before{content:"\f1a1"}.fa-reddit-alien:before{content:"\f281"}.fa-redhat:before{content:"\f7bc"}.fa-renren:before{content:"\f18b"}.fa-replyd:before{content:"\f3e6"}.fa-researchgate:before{content:"\f4f8"}.fa-resolving:before{content:"\f3e7"}.fa-rev:before{content:"\f5b2"}.fa-rocketchat:before{content:"\f3e8"}.fa-rockrms:before{content:"\f3e9"}.fa-rust:before{content:"\e07a"}.fa-safari:before{content:"\f267"}.fa-salesforce:before{content:"\f83b"}.fa-sass:before{content:"\f41e"}.fa-schlix:before{content:"\f3ea"}.fa-screenpal:before{content:"\e570"}.fa-scribd:before{content:"\f28a"}.fa-searchengin:before{content:"\f3eb"}.fa-sellcast:before{content:"\f2da"}.fa-sellsy:before{content:"\f213"}.fa-servicestack:before{content:"\f3ec"}.fa-shirtsinbulk:before{content:"\f214"}.fa-shopify:before{content:"\e057"}.fa-shopware:before{content:"\f5b5"}.fa-simplybuilt:before{content:"\f215"}.fa-sistrix:before{content:"\f3ee"}.fa-sith:before{content:"\f512"}.fa-sitrox:before{content:"\e44a"}.fa-sketch:before{content:"\f7c6"}.fa-skyatlas:before{content:"\f216"}.fa-skype:before{content:"\f17e"}.fa-slack-hash:before,.fa-slack:before{content:"\f198"}.fa-slideshare:before{content:"\f1e7"}.fa-snapchat-ghost:before,.fa-snapchat:before{content:"\f2ab"}.fa-soundcloud:before{content:"\f1be"}.fa-sourcetree:before{content:"\f7d3"}.fa-space-awesome:before{content:"\e5ac"}.fa-speakap:before{content:"\f3f3"}.fa-speaker-deck:before{content:"\f83c"}.fa-spotify:before{content:"\f1bc"}.fa-behance-square:before,.fa-square-behance:before{content:"\f1b5"}.fa-dribbble-square:before,.fa-square-dribbble:before{content:"\f397"}.fa-facebook-square:before,.fa-square-facebook:before{content:"\f082"}.fa-square-font-awesome:before{content:"\e5ad"}.fa-font-awesome-alt:before,.fa-square-font-awesome-stroke:before{content:"\f35c"}.fa-git-square:before,.fa-square-git:before{content:"\f1d2"}.fa-github-square:before,.fa-square-github:before{content:"\f092"}.fa-gitlab-square:before,.fa-square-gitlab:before{content:"\e5ae"}.fa-google-plus-square:before,.fa-square-google-plus:before{content:"\f0d4"}.fa-hacker-news-square:before,.fa-square-hacker-news:before{content:"\f3af"}.fa-instagram-square:before,.fa-square-instagram:before{content:"\e055"}.fa-js-square:before,.fa-square-js:before{content:"\f3b9"}.fa-lastfm-square:before,.fa-square-lastfm:before{content:"\f203"}.fa-odnoklassniki-square:before,.fa-square-odnoklassniki:before{content:"\f264"}.fa-pied-piper-square:before,.fa-square-pied-piper:before{content:"\e01e"}.fa-pinterest-square:before,.fa-square-pinterest:before{content:"\f0d3"}.fa-reddit-square:before,.fa-square-reddit:before{content:"\f1a2"}.fa-snapchat-square:before,.fa-square-snapchat:before{content:"\f2ad"}.fa-square-steam:before,.fa-steam-square:before{content:"\f1b7"}.fa-square-tumblr:before,.fa-tumblr-square:before{content:"\f174"}.fa-square-twitter:before,.fa-twitter-square:before{content:"\f081"}.fa-square-viadeo:before,.fa-viadeo-square:before{content:"\f2aa"}.fa-square-vimeo:before,.fa-vimeo-square:before{content:"\f194"}.fa-square-whatsapp:before,.fa-whatsapp-square:before{content:"\f40c"}.fa-square-xing:before,.fa-xing-square:before{content:"\f169"}.fa-square-youtube:before,.fa-youtube-square:before{content:"\f431"}.fa-squarespace:before{content:"\f5be"}.fa-stack-exchange:before{content:"\f18d"}.fa-stack-overflow:before{content:"\f16c"}.fa-stackpath:before{content:"\f842"}.fa-staylinked:before{content:"\f3f5"}.fa-steam:before{content:"\f1b6"}.fa-steam-symbol:before{content:"\f3f6"}.fa-sticker-mule:before{content:"\f3f7"}.fa-strava:before{content:"\f428"}.fa-stripe:before{content:"\f429"}.fa-stripe-s:before{content:"\f42a"}.fa-studiovinari:before{content:"\f3f8"}.fa-stumbleupon:before{content:"\f1a4"}.fa-stumbleupon-circle:before{content:"\f1a3"}.fa-superpowers:before{content:"\f2dd"}.fa-supple:before{content:"\f3f9"}.fa-suse:before{content:"\f7d6"}.fa-swift:before{content:"\f8e1"}.fa-symfony:before{content:"\f83d"}.fa-teamspeak:before{content:"\f4f9"}.fa-telegram-plane:before,.fa-telegram:before{content:"\f2c6"}.fa-tencent-weibo:before{content:"\f1d5"}.fa-the-red-yeti:before{content:"\f69d"}.fa-themeco:before{content:"\f5c6"}.fa-themeisle:before{content:"\f2b2"}.fa-think-peaks:before{content:"\f731"}.fa-tiktok:before{content:"\e07b"}.fa-trade-federation:before{content:"\f513"}.fa-trello:before{content:"\f181"}.fa-tumblr:before{content:"\f173"}.fa-twitch:before{content:"\f1e8"}.fa-twitter:before{content:"\f099"}.fa-typo3:before{content:"\f42b"}.fa-uber:before{content:"\f402"}.fa-ubuntu:before{content:"\f7df"}.fa-uikit:before{content:"\f403"}.fa-umbraco:before{content:"\f8e8"}.fa-uncharted:before{content:"\e084"}.fa-uniregistry:before{content:"\f404"}.fa-unity:before{content:"\e049"}.fa-unsplash:before{content:"\e07c"}.fa-untappd:before{content:"\f405"}.fa-ups:before{content:"\f7e0"}.fa-usb:before{content:"\f287"}.fa-usps:before{content:"\f7e1"}.fa-ussunnah:before{content:"\f407"}.fa-vaadin:before{content:"\f408"}.fa-viacoin:before{content:"\f237"}.fa-viadeo:before{content:"\f2a9"}.fa-viber:before{content:"\f409"}.fa-vimeo:before{content:"\f40a"}.fa-vimeo-v:before{content:"\f27d"}.fa-vine:before{content:"\f1ca"}.fa-vk:before{content:"\f189"}.fa-vnv:before{content:"\f40b"}.fa-vuejs:before{content:"\f41f"}.fa-watchman-monitoring:before{content:"\e087"}.fa-waze:before{content:"\f83f"}.fa-weebly:before{content:"\f5cc"}.fa-weibo:before{content:"\f18a"}.fa-weixin:before{content:"\f1d7"}.fa-whatsapp:before{content:"\f232"}.fa-whmcs:before{content:"\f40d"}.fa-wikipedia-w:before{content:"\f266"}.fa-windows:before{content:"\f17a"}.fa-wirsindhandwerk:before,.fa-wsh:before{content:"\e2d0"}.fa-wix:before{content:"\f5cf"}.fa-wizards-of-the-coast:before{content:"\f730"}.fa-wodu:before{content:"\e088"}.fa-wolf-pack-battalion:before{content:"\f514"}.fa-wordpress:before{content:"\f19a"}.fa-wordpress-simple:before{content:"\f411"}.fa-wpbeginner:before{content:"\f297"}.fa-wpexplorer:before{content:"\f2de"}.fa-wpforms:before{content:"\f298"}.fa-rendact:before,.fa-wpressr:before{content:"\f3e4"}.fa-xbox:before{content:"\f412"}.fa-xing:before{content:"\f168"}.fa-y-combinator:before{content:"\f23b"}.fa-yahoo:before{content:"\f19e"}.fa-yammer:before{content:"\f840"}.fa-yandex:before{content:"\f413"}.fa-yandex-international:before{content:"\f414"}.fa-yarn:before{content:"\f7e3"}.fa-yelp:before{content:"\f1e9"}.fa-yoast:before{content:"\f2b1"}.fa-youtube:before{content:"\f167"}.fa-zhihu:before{content:"\f63f"}:host,:root{--fa-font-regular:normal 400 1em/1 "Font Awesome 6 Free"}@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:400;font-display:block;src:url(../webfonts/fa-regular-400.woff2) format("woff2"),url(../webfonts/fa-regular-400.ttf) format("truetype")}.fa-regular,.far{font-family:"Font Awesome 6 Free";font-weight:400}:host,:root{--fa-font-solid:normal 900 1em/1 "Font Awesome 6 Free"}@font-face{font-family:"Font Awesome 6 Free";font-style:normal;font-weight:900;font-display:block;src:url(../webfonts/fa-solid-900.woff2) format("woff2"),url(../webfonts/fa-solid-900.ttf) format("truetype")}.fa-solid,.fas{font-family:"Font Awesome 6 Free";font-weight:900}@font-face{font-family:"Font Awesome 5 Brands";font-display:block;font-weight:400;src:url(../webfonts/fa-brands-400.woff2) format("woff2"),url(../webfonts/fa-brands-400.ttf) format("truetype")}@font-face{font-family:"Font Awesome 5 Free";font-display:block;font-weight:900;src:url(../webfonts/fa-solid-900.woff2) format("woff2"),url(../webfonts/fa-solid-900.ttf) format("truetype")}@font-face{font-family:"Font Awesome 5 Free";font-display:block;font-weight:400;src:url(../webfonts/fa-regular-400.woff2) format("woff2"),url(../webfonts/fa-regular-400.ttf) format("truetype")}@font-face{font-family:"FontAwesome";font-display:block;src:url(../webfonts/fa-solid-900.woff2) format("woff2"),url(../webfonts/fa-solid-900.ttf) format("truetype")}@font-face{font-family:"FontAwesome";font-display:block;src:url(../webfonts/fa-brands-400.woff2) format("woff2"),url(../webfonts/fa-brands-400.ttf) format("truetype")}@font-face{font-family:"FontAwesome";font-display:block;src:url(../webfonts/fa-regular-400.woff2) format("woff2"),url(../webfonts/fa-regular-400.ttf) format("truetype");unicode-range:u+f003,u+f006,u+f014,u+f016-f017,u+f01a-f01b,u+f01d,u+f022,u+f03e,u+f044,u+f046,u+f05c-f05d,u+f06e,u+f070,u+f087-f088,u+f08a,u+f094,u+f096-f097,u+f09d,u+f0a0,u+f0a2,u+f0a4-f0a7,u+f0c5,u+f0c7,u+f0e5-f0e6,u+f0eb,u+f0f6-f0f8,u+f10c,u+f114-f115,u+f118-f11a,u+f11c-f11d,u+f133,u+f147,u+f14e,u+f150-f152,u+f185-f186,u+f18e,u+f190-f192,u+f196,u+f1c1-f1c9,u+f1d9,u+f1db,u+f1e3,u+f1ea,u+f1f7,u+f1f9,u+f20a,u+f247-f248,u+f24a,u+f24d,u+f255-f25b,u+f25d,u+f271-f274,u+f278,u+f27b,u+f28c,u+f28e,u+f29c,u+f2b5,u+f2b7,u+f2ba,u+f2bc,u+f2be,u+f2c0-f2c1,u+f2c3,u+f2d0,u+f2d2,u+f2d4,u+f2dc}@font-face{font-family:"FontAwesome";font-display:block;src:url(../webfonts/fa-v4compatibility.woff2) format("woff2"),url(../webfonts/fa-v4compatibility.ttf) format("truetype");unicode-range:u+f041,u+f047,u+f065-f066,u+f07d-f07e,u+f080,u+f08b,u+f08e,u+f090,u+f09a,u+f0ac,u+f0ae,u+f0b2,u+f0d0,u+f0d6,u+f0e4,u+f0ec,u+f10a-f10b,u+f123,u+f13e,u+f148-f149,u+f14c,u+f156,u+f15e,u+f160-f161,u+f163,u+f175-f178,u+f195,u+f1f8,u+f219,u+f27a} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-brands-400.ttf b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-brands-400.ttf deleted file mode 100644 index 24ca8b17..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-brands-400.ttf and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-brands-400.woff2 b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-brands-400.woff2 deleted file mode 100644 index e67e5cd5..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-brands-400.woff2 and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-regular-400.ttf b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-regular-400.ttf deleted file mode 100644 index c5ac0095..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-regular-400.ttf and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-regular-400.woff2 b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-regular-400.woff2 deleted file mode 100644 index 7dca1d90..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-regular-400.woff2 and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-solid-900.ttf b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-solid-900.ttf deleted file mode 100644 index 43ba1cc7..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-solid-900.ttf and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-solid-900.woff2 b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-solid-900.woff2 deleted file mode 100644 index 4a7f9665..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-solid-900.woff2 and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-v4compatibility.ttf b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-v4compatibility.ttf deleted file mode 100644 index 243bc25b..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-v4compatibility.ttf and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-v4compatibility.woff2 b/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-v4compatibility.woff2 deleted file mode 100644 index e18a16d5..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/css/fontawesome/webfonts/fa-v4compatibility.woff2 and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/images/neve-theme.jpg b/wp-content/upgrade-temp-backup/plugins/menu-icons/images/neve-theme.jpg deleted file mode 100644 index 2e1c1c56..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/images/neve-theme.jpg and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/images/otter-block.png b/wp-content/upgrade-temp-backup/plugins/menu-icons/images/otter-block.png deleted file mode 100644 index dec4b8cd..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/menu-icons/images/otter-block.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/front.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/front.php deleted file mode 100644 index a411d97e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/front.php +++ /dev/null @@ -1,516 +0,0 @@ - - */ -final class Menu_Icons_Front_End { - - /** - * Icon types - * - * @since 0.9.0 - * @access protected - * @var array - */ - protected static $icon_types = array(); - - /** - * Default icon style - * - * @since 0.9.0 - * @access protected - * @var array - */ - protected static $default_style = array( - 'font_size' => array( - 'property' => 'font-size', - 'value' => '1.2', - 'unit' => 'em', - ), - 'vertical_align' => array( - 'property' => 'vertical-align', - 'value' => 'middle', - 'unit' => null, - ), - 'svg_width' => array( - 'property' => 'width', - 'value' => '1', - 'unit' => 'em', - ), - ); - - /** - * Hidden label class - * - * @since 0.9.0 - * @access protected - * @var string - */ - protected static $hidden_label_class = 'visuallyhidden'; - - - /** - * Add hooks for front-end functionalities - * - * @since 0.9.0 - */ - public static function init() { - $active_types = Menu_Icons_Settings::get( 'global', 'icon_types' ); - - if ( empty( $active_types ) ) { - return; - } - - foreach ( Menu_Icons::get( 'types' ) as $type ) { - if ( in_array( $type->id, $active_types, true ) ) { - self::$icon_types[ $type->id ] = $type; - } - } - - /** - * Allow themes/plugins to override the hidden label class - * - * @since 0.8.0 - * @param string $hidden_label_class Hidden label class. - * @return string - */ - self::$hidden_label_class = apply_filters( 'menu_icons_hidden_label_class', self::$hidden_label_class ); - - /** - * Allow themes/plugins to override default inline style - * - * @since 0.9.0 - * @param array $default_style Default inline style. - * @return array - */ - self::$default_style = apply_filters( 'menu_icons_default_style', self::$default_style ); - - add_action( 'wp_enqueue_scripts', array( __CLASS__, '_enqueue_styles' ), 4 ); - add_filter( 'wp_nav_menu_args', array( __CLASS__, '_add_menu_item_title_filter' ) ); - add_filter( 'wp_nav_menu', array( __CLASS__, '_remove_menu_item_title_filter' ) ); - } - - - /** - * Get nav menu ID based on arguments passed to wp_nav_menu() - * - * @since 0.3.0 - * @param array $args wp_nav_menu() Arguments - * @return mixed Nav menu ID or FALSE on failure - */ - public static function get_nav_menu_id( $args ) { - $args = (object) $args; - $menu = wp_get_nav_menu_object( $args->menu ); - - // Get the nav menu based on the theme_location - if ( ! $menu - && $args->theme_location - && ( $locations = get_nav_menu_locations() ) - && isset( $locations[ $args->theme_location ] ) - ) { - $menu = wp_get_nav_menu_object( $locations[ $args->theme_location ] ); - } - - // get the first menu that has items if we still can't find a menu - if ( ! $menu && ! $args->theme_location ) { - $menus = wp_get_nav_menus(); - foreach ( $menus as $menu_maybe ) { - if ( $menu_items = wp_get_nav_menu_items( $menu_maybe->term_id, array( 'update_post_term_cache' => false ) ) ) { - $menu = $menu_maybe; - break; - } - } - } - - if ( is_object( $menu ) && ! is_wp_error( $menu ) ) { - return $menu->term_id; - } else { - return false; - } - } - - - /** - * Enqueue stylesheets - * - * @since 0.1.0 - * @wp_hook action wp_enqueue_scripts - * @link http://codex.wordpress.org/Plugin_API/Action_Reference/wp_enqueue_scripts - */ - public static function _enqueue_styles() { - // Deregister icon picker plugin font-awesome style and re-register with the new handler to avoid other plugin/theme style handler conflict. - $wp_styles = wp_styles(); - if ( $wp_styles && isset( $wp_styles->registered['font-awesome'] ) ) { - $registered = $wp_styles->registered['font-awesome']; - if ( strpos( $registered->src, Menu_Icons::get( 'url' ) ) !== false ) { - $wp_styles->remove( 'font-awesome' ); - $registered->ver = Menu_Icons_Font_Awesome::$version; - $wp_styles->add( 'menu-icon-' . $registered->handle, $registered->src, $registered->deps, $registered->ver, $registered->args ); - } - } - - foreach ( self::$icon_types as $type ) { - $stylesheet_id = $type->stylesheet_id; - if ( 'font-awesome' === $stylesheet_id ) { - $stylesheet_id = 'menu-icon-' . $stylesheet_id; - } - if ( wp_style_is( $stylesheet_id, 'registered' ) ) { - wp_enqueue_style( $stylesheet_id ); - } - } - - /** - * Allow plugins/themes to override the extra stylesheet location - * - * @since 0.9.0 - * @param string $extra_stylesheet_uri Extra stylesheet URI. - */ - $extra_stylesheet_uri = apply_filters( - 'menu_icons_extra_stylesheet_uri', - sprintf( '%scss/extra%s.css', Menu_Icons::get( 'url' ), kucrut_get_script_suffix() ) - ); - - wp_enqueue_style( - 'menu-icons-extra', - $extra_stylesheet_uri, - false, - Menu_Icons::VERSION - ); - } - - - /** - * Add filter to 'the_title' hook - * - * We need to filter the menu item title but **not** regular post titles. - * Thus, we're adding the filter when `wp_nav_menu()` is called. - * - * @since 0.1.0 - * @wp_hook filter wp_nav_menu_args - * @param array $args Not used. - * - * @return array - */ - public static function _add_menu_item_title_filter( $args ) { - add_filter( 'the_title', array( __CLASS__, '_add_icon' ), 999, 2 ); - add_filter( 'megamenu_the_title', array( __CLASS__, '_add_icon' ), 999, 2 ); - add_filter( 'megamenu_nav_menu_css_class', array( __CLASS__, '_add_menu_item_class' ), 10, 3 ); - - return $args; - } - - - /** - * Remove filter from 'the_title' hook - * - * Because we don't want to filter post titles, we need to remove our - * filter when `wp_nav_menu()` exits. - * - * @since 0.1.0 - * @wp_hook filter wp_nav_menu - * @param array $nav_menu Not used. - * @return array - */ - public static function _remove_menu_item_title_filter( $nav_menu ) { - remove_filter( 'the_title', array( __CLASS__, '_add_icon' ), 999, 2 ); - remove_filter( 'megamenu_the_title', array( __CLASS__, '_add_icon' ), 999, 2 ); - remove_filter( 'megamenu_nav_menu_css_class', array( __CLASS__, '_add_menu_item_class' ), 10, 3 ); - return $nav_menu; - } - - - /** - * Add icon to menu item title - * - * @since 0.1.0 - * @since 0.9.0 Renamed the method to `add_icon()`. - * @wp_hook filter the_title - * @param string $title Menu item title. - * @param int $id Menu item ID. - * - * @return string - */ - public static function _add_icon( $title, $id ) { - $meta = Menu_Icons_Meta::get( $id ); - $icon = self::get_icon( $meta ); - - if ( empty( $icon ) ) { - return $title; - } - $menu_id = Menu_Icons_Settings::get_current_menu_id(); - $menu_key = sprintf( 'menu_%d', $menu_id ); - $global_hide_label = Menu_Icons_Settings::get( $menu_key, 'hide_label' ); - $title_class = ! empty( $global_hide_label ) || ! empty( $meta['hide_label'] ) ? self::$hidden_label_class : ''; - $title_wrapped = sprintf( - '%s', - ( ! empty( $title_class ) ) ? sprintf( ' class="%s"', esc_attr( $title_class ) ) : '', - $title - ); - - if ( 'after' === $meta['position'] ) { - $title_with_icon = "{$title_wrapped}{$icon}"; - } else { - $title_with_icon = "{$icon}{$title_wrapped}"; - } - - /** - * Allow plugins/themes to override menu item markup - * - * @since 0.8.0 - * - * @param string $title_with_icon Menu item markup after the icon is added. - * @param integer $id Menu item ID. - * @param array $meta Menu item metadata values. - * @param string $title Original menu item title. - * - * @return string - */ - $title_with_icon = apply_filters( 'menu_icons_item_title', $title_with_icon, $id, $meta, $title ); - - return $title_with_icon; - } - - - /** - * Get icon - * - * @since 0.9.0 - * @param array $meta Menu item meta value. - * @return string - */ - public static function get_icon( $meta ) { - $icon = ''; - - // Icon type is not set. - if ( empty( $meta['type'] ) ) { - return $icon; - } - - // Icon is not set. - if ( empty( $meta['icon'] ) ) { - return $icon; - } - - // Icon type is not registered/enabled. - if ( ! isset( self::$icon_types[ $meta['type'] ] ) ) { - return $icon; - } - - $type = self::$icon_types[ $meta['type'] ]; - - $callbacks = array( - array( $type, 'get_icon' ), - array( __CLASS__, "get_{$type->id}_icon" ), - array( __CLASS__, "get_{$type->template_id}_icon" ), - ); - - foreach ( $callbacks as $callback ) { - if ( is_callable( $callback ) ) { - $icon = call_user_func( $callback, $meta ); - break; - } - } - - return $icon; - } - - - /** - * Get icon style - * - * @since 0.9.0 - * @param array $meta Menu item meta value. - * @param array $keys Style properties. - * @param bool $as_attribute Optional. Whether to output the style as HTML attribute or value only. - * Defaults to TRUE. - * @return string - */ - public static function get_icon_style( $meta, $keys, $as_attribute = true ) { - $style_a = array(); - $style_s = ''; - - foreach ( $keys as $key ) { - if ( ! isset( self::$default_style[ $key ] ) ) { - continue; - } - - $rule = self::$default_style[ $key ]; - - if ( ! isset( $meta[ $key ] ) || $meta[ $key ] === $rule['value'] ) { - continue; - } - - $value = $meta[ $key ]; - if ( ! empty( $rule['unit'] ) ) { - $value .= $rule['unit']; - } - - $style_a[ $rule['property'] ] = $value; - } - - if ( empty( $style_a ) ) { - return $style_s; - } - - foreach ( $style_a as $key => $value ) { - $style_s .= "{$key}:{$value};"; - } - - $style_s = esc_attr( $style_s ); - - if ( $as_attribute ) { - $style_s = sprintf( ' style="%s"', $style_s ); - } - - return $style_s; - } - - - /** - * Get icon classes - * - * @since 0.9.0 - * @param array $meta Menu item meta value. - * @param string $output Whether to output the classes as string or array. Defaults to string. - * @return string|array - */ - public static function get_icon_classes( $meta, $output = 'string' ) { - $classes = array( '_mi' ); - - if ( empty( $meta['hide_label'] ) ) { - $classes[] = "_{$meta['position']}"; - } - - if ( 'string' === $output ) { - $classes = implode( ' ', $classes ); - } - - return $classes; - } - - - /** - * Get font icon - * - * @since 0.9.0 - * @param array $meta Menu item meta value. - * @return string - */ - public static function get_font_icon( $meta ) { - $type = $meta['type']; - $icon = $meta['icon']; - - $font_awesome5 = font_awesome_backward_compatible(); - if ( ! empty( $type ) && 'fa' === $type ) { - $icon = explode( ' ', $icon ); - $type = reset( $icon ); - $icon = end( $icon ); - $fa_icon = sprintf( '%s-%s', $type, $icon ); - if ( array_key_exists( $fa_icon, $font_awesome5 ) ) { - $fa5_icon = $font_awesome5[ $fa_icon ]; - $fa5_class = explode( ' ', $fa5_icon ); - $type = reset( $fa5_class ); - $icon = end( $fa5_class ); - } - } - $classes = sprintf( '%s %s %s', self::get_icon_classes( $meta ), $type, $icon ); - $style = self::get_icon_style( $meta, array( 'font_size', 'vertical_align' ) ); - return sprintf( '', esc_attr( $classes ), $style ); - } - - - /** - * Get image icon - * - * @since 0.9.0 - * @param array $meta Menu item meta value. - * @return string - */ - public static function get_image_icon( $meta ) { - $args = array( - 'class' => sprintf( '%s _image', self::get_icon_classes( $meta ) ), - 'aria-hidden' => 'true', - ); - - $style = self::get_icon_style( $meta, array( 'vertical_align' ), false ); - if ( ! empty( $style ) ) { - $args['style'] = $style; - } - - return wp_get_attachment_image( $meta['icon'], $meta['image_size'], false, $args ); - } - - - /** - * Get SVG icon - * - * @since 0.9.0 - * @param array $meta Menu item meta value. - * @return string - */ - public static function get_svg_icon( $meta ) { - $classes = sprintf( '%s _svg', self::get_icon_classes( $meta ) ); - $style = self::get_icon_style( $meta, array( 'svg_width', 'vertical_align' ) ); - - $svg_icon = esc_url( wp_get_attachment_url( $meta['icon'] ) ); - $width = ''; - $height = ''; - if ( 'image/svg+xml' === get_post_mime_type( $meta['icon'] ) ) { - - // Check `WP_Filesystem` function exists OR not. - require_once ABSPATH . '/wp-admin/includes/file.php'; - \WP_Filesystem(); - global $wp_filesystem; - - $svg_icon = get_attached_file( $meta['icon'] ); - $svg_icon_content = $wp_filesystem->get_contents( $svg_icon ); - if ( $svg_icon_content ) { - $xmlget = simplexml_load_string( $svg_icon_content ); - $xmlattributes = $xmlget->attributes(); - $width = (string) $xmlattributes->width; - $width = (int) filter_var( $xmlattributes->width, FILTER_SANITIZE_NUMBER_INT ); - $height = (string) $xmlattributes->height; - $height = (int) filter_var( $xmlattributes->height, FILTER_SANITIZE_NUMBER_INT ); - } - } else { - $attachment_meta = wp_get_attachment_metadata( $meta['icon'] ); - if ( $attachment_meta ) { - $width = isset( $attachment_meta['width'] ) ? $attachment_meta['width'] : $width; - $height = isset( $attachment_meta['height'] ) ? $attachment_meta['height'] : $height; - } - } - if ( ! empty( $width ) ) { - $width = sprintf( ' width="%d"', $width ); - } - if ( ! empty( $height ) ) { - $height = sprintf( ' height="%d"', $height ); - } - $image_alt = get_post_meta( $meta['icon'], '_wp_attachment_image_alt', true ); - $image_alt = $image_alt ? wp_strip_all_tags( $image_alt ) : ''; - return sprintf( - '', - esc_url( wp_get_attachment_url( $meta['icon'] ) ), - esc_attr( $classes ), - $image_alt, - $width, - $height, - $style - ); - } - - /** - * Add menu item class in `Max Mega Menu` item. - * - * @param array $classes Item classes. - * @param array $item WP menu item. - * @param object $args Menu object. - * @return array - */ - public static function _add_menu_item_class( $classes, $item, $args ) { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore - $classes[] = 'menu-item'; - return $classes; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/compat.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/compat.php deleted file mode 100644 index cf7ca6b0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/compat.php +++ /dev/null @@ -1,23 +0,0 @@ - 'fab fa-500px', - 'fa-fa-address-book-o' => 'far fa-address-book', - 'fa-fa-address-card-o' => 'far fa-address-card', - 'fa-fa-adn' => 'fab fa-adn', - 'fa-fa-amazon' => 'fab fa-amazon', - 'fa-fa-android' => 'fab fa-android', - 'fa-fa-angellist' => 'fab fa-angellist', - 'fa-fa-apple' => 'fab fa-apple', - 'fa-fa-area-chart' => 'fas fa-chart-area', - 'fa-fa-arrow-circle-o-down' => 'far fa-arrow-alt-circle-down', - 'fa-fa-arrow-circle-o-left' => 'far fa-arrow-alt-circle-left', - 'fa-fa-arrow-circle-o-right' => 'far fa-arrow-alt-circle-right', - 'fa-fa-arrow-circle-o-up' => 'far fa-arrow-alt-circle-up', - 'fa-fa-arrows-alt' => 'fas fa-expand-arrows-alt', - 'fa-fa-arrows-h' => 'fas fa-arrows-alt-h', - 'fa-fa-arrows-v' => 'fas fa-arrows-alt-v', - 'fa-fa-arrows' => 'fas fa-arrows-alt', - 'fa-fa-asl-interpreting' => 'fas fa-american-sign-language-interpreting', - 'fa-fa-automobile' => 'fas fa-car', - 'fa-fa-bandcamp' => 'fab fa-bandcamp', - 'fa-fa-bank' => 'fas fa-university', - 'fa-fa-bar-chart-o' => 'far fa-chart-bar', - 'fa-fa-bar-chart' => 'far fa-chart-bar', - 'fa-fa-bathtub' => 'fas fa-bath', - 'fa-fa-battery-0' => 'fas fa-battery-empty', - 'fa-fa-battery-1' => 'fas fa-battery-quarter', - 'fa-fa-battery-2' => 'fas fa-battery-half', - 'fa-fa-battery-3' => 'fas fa-battery-three-quarters', - 'fa-fa-battery-4' => 'fas fa-battery-full', - 'fa-fa-battery' => 'fas fa-battery-full', - 'fa-fa-behance' => 'fab fa-behance', - 'fa-fa-behance-square' => 'fab fa-behance-square', - 'fa-fa-bell-o' => 'far fa-bell', - 'fa-fa-bell-slash-o' => 'far fa-bell-slash', - 'fa-fa-bitbucket-square' => 'fab fa-bitbucket', - 'fa-fa-bitbucket' => 'fab fa-bitbucket', - 'fa-fa-bitcoin' => 'fab fa-btc', - 'fa-fa-black-tie' => 'fab fa-black-tie', - 'fa-fa-bluetooth-b' => 'fab fa-bluetooth-b', - 'fa-fa-bluetooth' => 'fab fa-bluetooth', - 'fa-fa-bookmark-o' => 'far fa-bookmark', - 'fa-fa-btc' => 'fab fa-btc', - 'fa-fa-building-o' => 'far fa-building', - 'fa-fa-buysellads' => 'fab fa-buysellads', - 'fa-fa-cab' => 'fas fa-taxi', - 'fa-fa-calendar-check-o' => 'far fa-calendar-check', - 'fa-fa-calendar-minus-o' => 'far fa-calendar-minus', - 'fa-fa-calendar-o' => 'far fa-calendar', - 'fa-fa-calendar-plus-o' => 'far fa-calendar-plus', - 'fa-fa-calendar-times-o' => 'far fa-calendar-times', - 'fa-fa-calendar' => 'fas fa-calendar-alt', - 'fa-fa-caret-square-o-down' => 'far fa-caret-square-down', - 'fa-fa-caret-square-o-left' => 'far fa-caret-square-left', - 'fa-fa-caret-square-o-right' => 'far fa-caret-square-right', - 'fa-fa-caret-square-o-up' => 'far fa-caret-square-up', - 'fa-fa-cc-amex' => 'fab fa-cc-amex', - 'fa-fa-cc-diners-club' => 'fab fa-cc-diners-club', - 'fa-fa-cc-discover' => 'fab fa-cc-discover', - 'fa-fa-cc-jcb' => 'fab fa-cc-jcb', - 'fa-fa-cc-mastercard' => 'fab fa-cc-mastercard', - 'fa-fa-cc-paypal' => 'fab fa-cc-paypal', - 'fa-fa-cc-stripe' => 'fab fa-cc-stripe', - 'fa-fa-cc-visa' => 'fab fa-cc-visa', - 'fa-fa-cc' => 'far fa-closed-captioning', - 'fa-fa-chain-broken' => 'fas fa-unlink', - 'fa-fa-chain' => 'fas fa-link', - 'fa-fa-check-circle-o' => 'far fa-check-circle', - 'fa-fa-check-square-o' => 'far fa-check-square', - 'fa-fa-chrome' => 'fab fa-chrome', - 'fa-fa-circle-o-notch' => 'fas fa-circle-notch', - 'fa-fa-circle-o' => 'far fa-circle', - 'fa-fa-circle-thin' => 'far fa-circle', - 'fa-fa-clipboard' => 'far fa-clipboard', - 'fa-fa-clock-o' => 'far fa-clock', - 'fa-fa-clone' => 'far fa-clone', - 'fa-fa-close' => 'fas fa-times', - 'fa-fa-cloud-download' => 'fas fa-cloud-download-alt', - 'fa-fa-cloud-upload' => 'fas fa-cloud-upload-alt', - 'fa-fa-cny' => 'fas fa-yen-sign', - 'fa-fa-code-fork' => 'fas fa-code-branch', - 'fa-fa-codepen' => 'fab fa-codepen', - 'fa-fa-codiepie' => 'fab fa-codiepie', - 'fa-fa-comment-o' => 'far fa-comment', - 'fa-fa-commenting-o' => 'far fa-comment-dots', - 'fa-fa-commenting' => 'fas fa-comment-dots', - 'fa-fa-comments-o' => 'far fa-comments', - 'fa-fa-compass' => 'far fa-compass', - 'fa-fa-connectdevelop' => 'fab fa-connectdevelop', - 'fa-fa-contao' => 'fab fa-contao', - 'fa-fa-copyright' => 'far fa-copyright', - 'fa-fa-creative-commons' => 'fab fa-creative-commons', - 'fa-fa-credit-card-alt' => 'fas fa-credit-card', - 'fa-fa-credit-card' => 'far fa-credit-card', - 'fa-fa-css3' => 'fab fa-css3', - 'fa-fa-cutlery' => 'fas fa-utensils', - 'fa-fa-dashboard' => 'fas fa-tachometer-alt', - 'fa-fa-dashcube' => 'fab fa-dashcube', - 'fa-fa-deafness' => 'fas fa-deaf', - 'fa-fa-dedent' => 'fas fa-outdent', - 'fa-fa-delicious' => 'fab fa-delicious', - 'fa-fa-deviantart' => 'fab fa-deviantart', - 'fa-fa-diamond' => 'far fa-gem', - 'fa-fa-digg' => 'fab fa-digg', - 'fa-fa-dollar' => 'fas fa-dollar-sign', - 'fa-fa-dot-circle-o' => 'far fa-dot-circle', - 'fa-fa-dribbble' => 'fab fa-dribbble', - 'fa-fa-drivers-license-o' => 'far fa-id-card', - 'fa-fa-drivers-license' => 'fas fa-id-card', - 'fa-fa-dropbox' => 'fab fa-dropbox', - 'fa-fa-drupal' => 'fab fa-drupal', - 'fa-fa-edge' => 'fab fa-edge', - 'fa-fa-eercast' => 'fab fa-sellcast', - 'fa-fa-empire' => 'fab fa-empire', - 'fa-fa-envelope-open-o' => 'far fa-envelope-open', - 'fa-fa-envelope-o' => 'far fa-envelope', - 'fa-fa-envira' => 'fab fa-envira', - 'fa-fa-etsy' => 'fab fa-etsy', - 'fa-fa-euro' => 'fas fa-euro-sign', - 'fa-fa-eur' => 'fas fa-euro-sign', - 'fa-fa-exchange' => 'fas fa-exchange-alt', - 'fa-fa-expeditedssl' => 'fab fa-expeditedssl', - 'fa-fa-external-link-square' => 'fas fa-external-link-square-alt', - 'fa-fa-external-link' => 'fas fa-external-link-alt', - 'fa-fa-eye-slash' => 'far fa-eye-slash', - 'fa-fa-eyedropper' => 'fas fa-eye-dropper', - 'fa-fa-eye' => 'far fa-eye', - 'fa-fa-facebook-f' => 'fab fa-facebook-f', - 'fa-fa-facebook-official' => 'fab fa-facebook', - 'fa-fa-facebook-square' => 'fab fa-facebook-square', - 'fa-fa-facebook' => 'fab fa-facebook-f', - 'fa-fa-feed' => 'fas fa-rss', - 'fa-fa-file-archive-o' => 'far fa-file-archive', - 'fa-fa-file-audio-o' => 'far fa-file-audio', - 'fa-fa-file-code-o' => 'far fa-file-code', - 'fa-fa-file-excel-o' => 'far fa-file-excel', - 'fa-fa-file-image-o' => 'far fa-file-image', - 'fa-fa-file-movie-o' => 'far fa-file-video', - 'fa-fa-file-o' => 'far fa-file', - 'fa-fa-file-pdf-o' => 'far fa-file-pdf', - 'fa-fa-file-photo-o' => 'far fa-file-image', - 'fa-fa-file-picture-o' => 'far fa-file-image', - 'fa-fa-file-powerpoint-o' => 'far fa-file-powerpoint', - 'fa-fa-file-sound-o' => 'far fa-file-audio', - 'fa-fa-file-text-o' => 'far fa-file-alt', - 'fa-fa-file-text' => 'fas fa-file-alt', - 'fa-fa-file-video-o' => 'far fa-file-video', - 'fa-fa-file-word-o' => 'far fa-file-word', - 'fa-fa-file-zip-o' => 'far fa-file-archive', - 'fa-fa-files-o' => 'far fa-copy', - 'fa-fa-firefox' => 'fab fa-firefox', - 'fa-fa-first-order' => 'fab fa-first-order', - 'fa-fa-flag-o' => 'far fa-flag', - 'fa-fa-flash' => 'fas fa-bolt', - 'fa-fa-flickr' => 'fab fa-flickr', - 'fa-fa-floppy-o' => 'far fa-save', - 'fa-fa-folder-o' => 'far fa-folder', - 'fa-fa-folder-open-o' => 'far fa-folder-open', - 'fa-fa-font-awesome' => 'fab fa-font-awesome', - 'fa-fa-fonticons' => 'fab fa-fonticons', - 'fa-fa-fort-awesome' => 'fab fa-fort-awesome', - 'fa-fa-forumbee' => 'fab fa-forumbee', - 'fa-fa-foursquare' => 'fab fa-foursquare', - 'fa-fa-free-code-camp' => 'fab fa-free-code-camp', - 'fa-fa-frown-o' => 'far fa-frown', - 'fa-fa-futbol-o' => 'far fa-futbol', - 'fa-fa-gbp' => 'fas fa-pound-sign', - 'fa-fa-gears' => 'fas fa-cogs', - 'fa-fa-gear' => 'fas fa-cog', - 'fa-fa-get-pocket' => 'fab fa-get-pocket', - 'fa-fa-ge' => 'fab fa-empire', - 'fa-fa-gg-circle' => 'fab fa-gg-circle', - 'fa-fa-gg' => 'fab fa-gg', - 'fa-fa-git-square' => 'fab fa-git-square', - 'fa-fa-github-alt' => 'fab fa-github-alt', - 'fa-fa-github-square' => 'fab fa-github-square', - 'fa-fa-github' => 'fab fa-github', - 'fa-fa-gitlab' => 'fab fa-gitlab', - 'fa-fa-gittip' => 'fab fa-gratipay', - 'fa-fa-git' => 'fab fa-git', - 'fa-fa-glass' => 'fas fa-glass-martini', - 'fa-fa-glide-g' => 'fab fa-glide-g', - 'fa-fa-glide' => 'fab fa-glide', - 'fa-fa-google-plus-circle' => 'fab fa-google-plus', - 'fa-fa-google-plus-official' => 'fab fa-google-plus', - 'fa-fa-google-plus-square' => 'fab fa-google-plus-square', - 'fa-fa-google-plus' => 'fab fa-google-plus-g', - 'fa-fa-google-wallet' => 'fab fa-google-wallet', - 'fa-fa-google' => 'fab fa-google', - 'fa-fa-gratipay' => 'fab fa-gratipay', - 'fa-fa-grav' => 'fab fa-grav', - 'fa-fa-group' => 'fas fa-users', - 'fa-fa-hacker-news' => 'fab fa-hacker-news', - 'fa-fa-hand-grab-o' => 'far fa-hand-rock', - 'fa-fa-hand-lizard-o' => 'far fa-hand-lizard', - 'fa-fa-hand-o-down' => 'far fa-hand-point-down', - 'fa-fa-hand-o-left' => 'far fa-hand-point-left', - 'fa-fa-hand-o-right' => 'far fa-hand-point-right', - 'fa-fa-hand-o-up' => 'far fa-hand-point-up', - 'fa-fa-hand-paper-o' => 'far fa-hand-paper', - 'fa-fa-hand-peace-o' => 'far fa-hand-peace', - 'fa-fa-hand-pointer-o' => 'far fa-hand-pointer', - 'fa-fa-hand-rock-o' => 'far fa-hand-rock', - 'fa-fa-hand-scissors-o' => 'far fa-hand-scissors', - 'fa-fa-hand-spock-o' => 'far fa-hand-spock', - 'fa-fa-hand-stop-o' => 'far fa-hand-paper', - 'fa-fa-handshake-o' => 'far fa-handshake', - 'fa-fa-hard-of-hearing' => 'fas fa-deaf', - 'fa-fa-hdd-o' => 'far fa-hdd', - 'fa-fa-header' => 'fas fa-heading', - 'fa-fa-heart-o' => 'far fa-heart', - 'fa-fa-hospital-o' => 'far fa-hospital', - 'fa-fa-hotel' => 'fas fa-bed', - 'fa-fa-hourglass-1' => 'fas fa-hourglass-start', - 'fa-fa-hourglass-2' => 'fas fa-hourglass-half', - 'fa-fa-hourglass-3' => 'fas fa-hourglass-end', - 'fa-fa-hourglass-o' => 'far fa-hourglass', - 'fa-fa-houzz' => 'fab fa-houzz', - 'fa-fa-html5' => 'fab fa-html5', - 'fa-fa-id-badge' => 'far fa-id-badge', - 'fa-fa-id-card-o' => 'far fa-id-card', - 'fa-fa-ils' => 'fas fa-shekel-sign', - 'fa-fa-image' => 'far fa-image', - 'fa-fa-imdb' => 'fab fa-imdb', - 'fa-fa-inr' => 'fas fa-rupee-sign', - 'fa-fa-instagram' => 'fab fa-instagram', - 'fa-fa-institution' => 'fas fa-university', - 'fa-fa-internet-explorer' => 'fab fa-internet-explorer', - 'fa-fa-intersex' => 'fas fa-transgender', - 'fa-fa-ioxhost' => 'fab fa-ioxhost', - 'fa-fa-joomla' => 'fab fa-joomla', - 'fa-fa-jpy' => 'fas fa-yen-sign', - 'fa-fa-jsfiddle' => 'fab fa-jsfiddle', - 'fa-fa-keyboard-o' => 'far fa-keyboard', - 'fa-fa-krw' => 'fas fa-won-sign', - 'fa-fa-lastfm-square' => 'fab fa-lastfm-square', - 'fa-fa-lastfm' => 'fab fa-lastfm', - 'fa-fa-leanpub' => 'fab fa-leanpub', - 'fa-fa-legal' => 'fas fa-gavel', - 'fa-fa-lemon-o' => 'far fa-lemon', - 'fa-fa-level-down' => 'fas fa-level-down-alt', - 'fa-fa-level-up' => 'fas fa-level-up-alt', - 'fa-fa-life-bouy' => 'far fa-life-ring', - 'fa-fa-life-buoy' => 'far fa-life-ring', - 'fa-fa-life-ring' => 'far fa-life-ring', - 'fa-fa-life-saver' => 'far fa-life-ring', - 'fa-fa-lightbulb-o' => 'far fa-lightbulb', - 'fa-fa-line-chart' => 'fas fa-chart-line', - 'fa-fa-linkedin-square' => 'fab fa-linkedin', - 'fa-fa-linkedin' => 'fab fa-linkedin-in', - 'fa-fa-linode' => 'fab fa-linode', - 'fa-fa-linux' => 'fab fa-linux', - 'fa-fa-list-alt' => 'far fa-list-alt', - 'fa-fa-long-arrow-down' => 'fas fa-long-arrow-alt-down', - 'fa-fa-long-arrow-left' => 'fas fa-long-arrow-alt-left', - 'fa-fa-long-arrow-right' => 'fas fa-long-arrow-alt-right', - 'fa-fa-long-arrow-up' => 'fas fa-long-arrow-alt-up', - 'fa-fa-mail-forward' => 'fas fa-share', - 'fa-fa-mail-reply-all' => 'fas fa-reply-all', - 'fa-fa-mail-reply' => 'fas fa-reply', - 'fa-fa-map-marker' => 'fas fa-map-marker-alt', - 'fa-fa-map-o' => 'far fa-map', - 'fa-fa-maxcdn' => 'fab fa-maxcdn', - 'fa-fa-meanpath' => 'fab fa-font-awesome', - 'fa-fa-medium' => 'fab fa-medium', - 'fa-fa-meetup' => 'fab fa-meetup', - 'fa-fa-meh-o' => 'far fa-meh', - 'fa-fa-minus-square-o' => 'far fa-minus-square', - 'fa-fa-mixcloud' => 'fab fa-mixcloud', - 'fa-fa-mobile-phone' => 'fas fa-mobile-alt', - 'fa-fa-mobile' => 'fas fa-mobile-alt', - 'fa-fa-modx' => 'fab fa-modx', - 'fa-fa-moon-o' => 'far fa-moon', - 'fa-fa-money' => 'far fa-money-bill-alt', - 'fa-fa-mortar-board' => 'fas fa-graduation-cap', - 'fa-fa-navicon' => 'fas fa-bars', - 'fa-fa-newspaper-o' => 'far fa-newspaper', - 'fa-fa-object-group' => 'far fa-object-group', - 'fa-fa-object-ungroup' => 'far fa-object-ungroup', - 'fa-fa-odnoklassniki-square' => 'fab fa-odnoklassniki-square', - 'fa-fa-odnoklassniki' => 'fab fa-odnoklassniki', - 'fa-fa-opencart' => 'fab fa-opencart', - 'fa-fa-openid' => 'fab fa-openid', - 'fa-fa-opera' => 'fab fa-opera', - 'fa-fa-optin-monster' => 'fab fa-optin-monster', - 'fa-fa-pagelines' => 'fab fa-pagelines', - 'fa-fa-paper-plane-o' => 'far fa-paper-plane', - 'fa-fa-paste' => 'far fa-clipboard', - 'fa-fa-pause-circle-o' => 'far fa-pause-circle', - 'fa-fa-paypal' => 'fab fa-paypal', - 'fa-fa-pencil-square' => 'fas fa-pen-square', - 'fa-fa-pencil-square-o' => 'far fa-edit', - 'fa-fa-pencil' => 'fas fa-pencil-alt', - 'fa-fa-photo' => 'far fa-image', - 'fa-fa-picture-o' => 'far fa-image', - 'fa-fa-pie-chart' => 'fas fa-chart-pie', - 'fa-fa-pied-piper-alt' => 'fab fa-pied-piper-alt', - 'fa-fa-pied-piper-pp' => 'fab fa-pied-piper-pp', - 'fa-fa-pied-piper' => 'fab fa-pied-piper', - 'fa-fa-pinterest-p' => 'fab fa-pinterest-p', - 'fa-fa-pinterest-square' => 'fab fa-pinterest-square', - 'fa-fa-pinterest' => 'fab fa-pinterest', - 'fa-fa-play-circle-o' => 'far fa-play-circle', - 'fa-fa-plus-square-o' => 'far fa-plus-square', - 'fa-fa-product-hunt' => 'fab fa-product-hunt', - 'fa-fa-qq' => 'fab fa-qq', - 'fa-fa-question-circle-o' => 'far fa-question-circle', - 'fa-fa-quora' => 'fab fa-quora', - 'fa-fa-ravelry' => 'fab fa-ravelry', - 'fa-fa-ra' => 'fab fa-rebel', - 'fa-fa-rebel' => 'fab fa-rebel', - 'fa-fa-reddit-alien' => 'fab fa-reddit-alien', - 'fa-fa-reddit-square' => 'fab fa-reddit-square', - 'fa-fa-reddit' => 'fab fa-reddit', - 'fa-fa-refresh' => 'fas fa-sync', - 'fa-fa-registered' => 'far fa-registered', - 'fa-fa-remove' => 'fas fa-times', - 'fa-fa-renren' => 'fab fa-renren', - 'fa-fa-reorder' => 'fas fa-bars', - 'fa-fa-repeat' => 'fas fa-redo', - 'fa-fa-resistance' => 'fab fa-rebel', - 'fa-fa-rmb' => 'fas fa-yen-sign', - 'fa-fa-rotate-left' => 'fas fa-undo', - 'fa-fa-rotate-right' => 'fas fa-redo', - 'fa-fa-rouble' => 'fas fa-ruble-sign', - 'fa-fa-ruble' => 'fas fa-ruble-sign', - 'fa-fa-rub' => 'fas fa-ruble-sign', - 'fa-fa-rupee' => 'fas fa-rupee-sign', - 'fa-fa-s15' => 'fas fa-bath', - 'fa-fa-safari' => 'fab fa-safari', - 'fa-fa-scissors' => 'fas fa-cut', - 'fa-fa-scribd' => 'fab fa-scribd', - 'fa-fa-sellsy' => 'fab fa-sellsy', - 'fa-fa-send-o' => 'far fa-paper-plane', - 'fa-fa-send' => 'fas fa-paper-plane', - 'fa-fa-share-square-o' => 'far fa-share-square', - 'fa-fa-shekel' => 'fas fa-shekel-sign', - 'fa-fa-sheqel' => 'fas fa-shekel-sign', - 'fa-fa-shield' => 'fas fa-shield-alt', - 'fa-fa-shirtsinbulk' => 'fab fa-shirtsinbulk', - 'fa-fa-sign-in' => 'fas fa-sign-in-alt', - 'fa-fa-sign-out' => 'fas fa-sign-out-alt', - 'fa-fa-signing' => 'fas fa-sign-language', - 'fa-fa-simplybuilt' => 'fab fa-simplybuilt', - 'fa-fa-skyatlas' => 'fab fa-skyatlas', - 'fa-fa-skype' => 'fab fa-skype', - 'fa-fa-slack' => 'fab fa-slack', - 'fa-fa-sliders' => 'fas fa-sliders-h', - 'fa-fa-slideshare' => 'fab fa-slideshare', - 'fa-fa-smile-o' => 'far fa-smile', - 'fa-fa-snapchat-ghost' => 'fab fa-snapchat-ghost', - 'fa-fa-snapchat-square' => 'fab fa-snapchat-square', - 'fa-fa-snapchat' => 'fab fa-snapchat', - 'fa-fa-snowflake-o' => 'far fa-snowflake', - 'fa-fa-soccer-ball-o' => 'far fa-futbol', - 'fa-fa-sort-alpha-asc' => 'fas fa-sort-alpha-down', - 'fa-fa-sort-alpha-desc' => 'fas fa-sort-alpha-up', - 'fa-fa-sort-amount-asc' => 'fas fa-sort-amount-down', - 'fa-fa-sort-amount-desc' => 'fas fa-sort-amount-up', - 'fa-fa-sort-asc' => 'fas fa-sort-up', - 'fa-fa-sort-desc' => 'fas fa-sort-down', - 'fa-fa-sort-numeric-asc' => 'fas fa-sort-numeric-down', - 'fa-fa-sort-numeric-desc' => 'fas fa-sort-numeric-up', - 'fa-fa-soundcloud' => 'fab fa-soundcloud', - 'fa-fa-spoon' => 'fas fa-utensil-spoon', - 'fa-fa-spotify' => 'fab fa-spotify', - 'fa-fa-square-o' => 'far fa-square', - 'fa-fa-stack-exchange' => 'fab fa-stack-exchange', - 'fa-fa-stack-overflow' => 'fab fa-stack-overflow', - 'fa-fa-star-half-empty' => 'far fa-star-half', - 'fa-fa-star-half-full' => 'far fa-star-half', - 'fa-fa-star-half-o' => 'far fa-star-half', - 'fa-fa-star-o' => 'far fa-star', - 'fa-fa-steam-square' => 'fab fa-steam-square', - 'fa-fa-steam' => 'fab fa-steam', - 'fa-fa-sticky-note-o' => 'far fa-sticky-note', - 'fa-fa-stop-circle-o' => 'far fa-stop-circle', - 'fa-fa-stumbleupon-circle' => 'fab fa-stumbleupon-circle', - 'fa-fa-stumbleupon' => 'fab fa-stumbleupon', - 'fa-fa-sun-o' => 'far fa-sun', - 'fa-fa-superpowers' => 'fab fa-superpowers', - 'fa-fa-support' => 'far fa-life-ring', - 'fa-fa-tablet' => 'fas fa-tablet-alt', - 'fa-fa-tachometer' => 'fas fa-tachometer-alt', - 'fa-fa-telegram' => 'fab fa-telegram', - 'fa-fa-television' => 'fas fa-tv', - 'fa-fa-tencent-weibo' => 'fab fa-tencent-weibo', - 'fa-fa-themeisle' => 'fab fa-themeisle', - 'fa-fa-thermometer-0' => 'fas fa-thermometer-empty', - 'fa-fa-thermometer-1' => 'fas fa-thermometer-quarter', - 'fa-fa-thermometer-2' => 'fas fa-thermometer-half', - 'fa-fa-thermometer-3' => 'fas fa-thermometer-three-quarters', - 'fa-fa-thermometer-4' => 'fas fa-thermometer-full', - 'fa-fa-thermometer' => 'fas fa-thermometer-full', - 'fa-fa-thumb-tack' => 'fas fa-thumbtack', - 'fa-fa-thumbs-o-down' => 'far fa-thumbs-down', - 'fa-fa-thumbs-o-up' => 'far fa-thumbs-up', - 'fa-fa-ticket' => 'fas fa-ticket-alt', - 'fa-fa-times-circle-o' => 'far fa-times-circle', - 'fa-fa-times-rectangle-o' => 'far fa-window-close', - 'fa-fa-times-rectangle' => 'fas fa-window-close', - 'fa-fa-toggle-down' => 'far fa-caret-square-down', - 'fa-fa-toggle-left' => 'far fa-caret-square-left', - 'fa-fa-toggle-right' => 'far fa-caret-square-right', - 'fa-fa-toggle-up' => 'far fa-caret-square-up', - 'fa-fa-trash-o' => 'far fa-trash-alt', - 'fa-fa-trash' => 'fas fa-trash-alt', - 'fa-fa-trello' => 'fab fa-trello', - 'fa-fa-tripadvisor' => 'fab fa-tripadvisor', - 'fa-fa-try' => 'fas fa-lira-sign', - 'fa-fa-tumblr-square' => 'fab fa-tumblr-square', - 'fa-fa-tumblr' => 'fab fa-tumblr', - 'fa-fa-turkish-lira' => 'fas fa-lira-sign', - 'fa-fa-twitch' => 'fab fa-twitch', - 'fa-fa-twitter-square' => 'fab fa-twitter-square', - 'fa-fa-twitter' => 'fab fa-twitter', - 'fa-fa-unsorted' => 'fas fa-sort', - 'fa-fa-usb' => 'fab fa-usb', - 'fa-fa-usd' => 'fas fa-dollar-sign', - 'fa-fa-user-circle-o' => 'far fa-user-circle', - 'fa-fa-user-o' => 'far fa-user', - 'fa-fa-vcard-o' => 'far fa-address-card', - 'fa-fa-vcard' => 'fas fa-address-card', - 'fa-fa-viacoin' => 'fab fa-viacoin', - 'fa-fa-viadeo-square' => 'fab fa-viadeo-square', - 'fa-fa-viadeo' => 'fab fa-viadeo', - 'fa-fa-video-camera' => 'fas fa-video', - 'fa-fa-vimeo-square' => 'fab fa-vimeo-square', - 'fa-fa-vimeo' => 'fab fa-vimeo-v', - 'fa-fa-vine' => 'fab fa-vine', - 'fa-fa-vk' => 'fab fa-vk', - 'fa-fa-volume-control-phone' => 'fas fa-phone-volume', - 'fa-fa-warning' => 'fas fa-exclamation-triangle', - 'fa-fa-wechat' => 'fab fa-weixin', - 'fa-fa-weibo' => 'fab fa-weibo', - 'fa-fa-weixin' => 'fab fa-weixin', - 'fa-fa-whatsapp' => 'fab fa-whatsapp', - 'fa-fa-wheelchair-alt' => 'fab fa-accessible-icon', - 'fa-fa-wikipedia-w' => 'fab fa-wikipedia-w', - 'fa-fa-window-close-o' => 'far fa-window-close', - 'fa-fa-window-maximize' => 'far fa-window-maximize', - 'fa-fa-window-restore' => 'far fa-window-restore', - 'fa-fa-windows' => 'fab fa-windows', - 'fa-fa-won' => 'fas fa-won-sign', - 'fa-fa-wordpress' => 'fab fa-wordpress', - 'fa-fa-wpbeginner' => 'fab fa-wpbeginner', - 'fa-fa-wpexplorer' => 'fab fa-wpexplorer', - 'fa-fa-wpforms' => 'fab fa-wpforms', - 'fa-fa-xing-square' => 'fab fa-xing-square', - 'fa-fa-xing' => 'fab fa-xing', - 'fa-fa-y-combinator-square' => 'fab fa-hacker-news', - 'fa-fa-y-combinator' => 'fab fa-y-combinator', - 'fa-fa-yahoo' => 'fab fa-yahoo', - 'fa-fa-yc' => 'fab fa-y-combinator', - 'fa-fa-yc-square' => 'fab fa-hacker-news', - 'fa-fa-yelp' => 'fab fa-yelp', - 'fa-fa-yen' => 'fas fa-yen-sign', - 'fa-fa-yoast' => 'fab fa-yoast', - 'fa-fa-youtube-play' => 'fab fa-youtube', - 'fa-fa-youtube-square' => 'fab fa-youtube-square', - 'fa-fa-youtube' => 'fab fa-youtube', - 'fa-fa-fa' => 'fab fa-font-awesome', - ); - $font_awesome_icon = apply_filters( 'menu_icons_backward_compatibility_icons', $font_awesome_icon ); - - return $font_awesome_icon; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/font-awesome/font-awesome.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/font-awesome/font-awesome.php deleted file mode 100644 index 3f674bf4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/font-awesome/font-awesome.php +++ /dev/null @@ -1,122 +0,0 @@ -version - ); - } - - return $stylesheet_uri; - } - - - /** - * Icon picker fontawesome items. - * - * @param array $icons Icons. - * @return array Icons. - */ - public static function _icon_picker_fa_items( $icons ) { - if ( empty( $icons ) ) { - return $icons; - } - - $deprecated_icons = array_search( 'fa-tripadvisor', array_column( $icons, 'id' ), true ); - if ( false !== $deprecated_icons ) { - unset( $icons[ $deprecated_icons ] ); - $icons = array_values( $icons ); - } - - $font_awesome = font_awesome_backward_compatible(); - foreach ( $icons as $key => $icon ) { - $old_fa_icon = sprintf( 'fa-%s', $icons[ $key ]['id'] ); - if ( array_key_exists( $old_fa_icon, $font_awesome ) ) { - $icons[ $key ]['id'] = trim( $font_awesome[ $old_fa_icon ] ); - } else { - $icons[ $key ]['id'] = sprintf( 'fa %s', trim( $icons[ $key ]['id'] ) ); - } - } - - // Fa5 extra icons support. - $global_settins = get_option( 'menu-icons', false ); - if ( ! empty( $global_settins['global']['fa5_extra_icons'] ) ) { - $fa5_extra_icons = $global_settins['global']['fa5_extra_icons']; - $fa5_extra_icons = explode( ',', $fa5_extra_icons ); - $fa5_extra_icons = array_map( 'trim', $fa5_extra_icons ); - if ( ! empty( $fa5_extra_icons ) ) { - foreach ( $fa5_extra_icons as $fa5_icon ) { - $icon_name = explode( '-', $fa5_icon ); - $icon_name = end( $icon_name ); - $icons[] = array( - 'group' => 'all', - 'id' => $fa5_icon, - 'name' => $icon_name, - ); - } - } - } - - return $icons; - } - - - /** - * Icon picker font media template. - * - * @param string $template Media template. - * @return string Media template. - */ - public static function _icon_picker_font_media_templates( $template ) { - $templates = array( - 'icon' => '', - 'item' => sprintf( - '
            -
            - -
            {{ data.name }}
            -
            -
            -
            ', - esc_attr__( 'Deselect', 'icon-picker' ) - ), - ); - - return $templates; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/form-fields.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/form-fields.php deleted file mode 100644 index a63962ce..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/form-fields.php +++ /dev/null @@ -1,575 +0,0 @@ - - */ - -/** - * Form Fields - */ -abstract class Kucrut_Form_Field { - - /** - * Holds field & argument defaults - * - * @since 0.1.0 - * @var array - * @access protected - */ - protected static $defaults = array( - 'field' => array( - 'id' => '', - 'type' => 'text', - 'value' => null, - 'default' => null, - 'attributes' => array(), - 'description' => '', - 'choices' => array(), - ), - 'args' => array( - 'keys' => array(), - 'inline_description' => false, - ), - ); - - /** - * Holds field attributes - * - * @since 0.1.0 - * @var array - * @access protected - */ - protected static $types = array( - 'text' => 'Kucrut_Form_Field_Text', - 'number' => 'Kucrut_Form_Field_Text', - 'url' => 'Kucrut_Form_Field_Text', - 'color' => 'Kucrut_Form_Field_Text', - 'date' => 'Kucrut_Form_Field_Text', - 'hidden' => 'Kucrut_Form_Field_Text', - 'checkbox' => 'Kucrut_Form_Field_Checkbox', - 'radio' => 'Kucrut_Form_Field_Radio', - 'textarea' => 'Kucrut_Form_Field_Textarea', - 'select' => 'Kucrut_Form_Field_Select', - 'select_multiple' => 'Kucrut_Form_Field_Select_Multiple', - 'select_pages' => 'Kucrut_Form_Field_Select_Pages', - 'special' => 'Kucrut_Form_Field_Special', - ); - - /** - * Holds forbidden attributes - * - * @since 0.1.0 - * @var array - * @access protected - */ - protected static $forbidden_attributes = array( - 'id', - 'name', - 'value', - 'checked', - 'multiple', - ); - - /** - * Holds allowed html tags - * - * @since 0.1.0 - * @var array - * @access protected - */ - protected $allowed_html = array( - 'a' => array( - 'href' => true, - 'target' => true, - 'title' => true, - ), - 'code' => true, - 'em' => true, - 'p' => array( 'class' => true ), - 'span' => array( 'class' => true ), - 'strong' => true, - ); - - /** - * Holds constructed field - * - * @since 0.1.0 - * @var array - * @access protected - */ - protected $field; - - - /** - * Holds field attributes - * - * @since 0.1.0 - * @var array - * @access protected - */ - protected $attributes = array(); - - - /** - * Loader - * - * @param string URL path to this directory - */ - final public static function load( $url_path = null ) { - // Set URL path for assets - if ( ! is_null( $url_path ) ) { - self::$url_path = $url_path; - } else { - self::$url_path = plugin_dir_url( __FILE__ ); - } - - // Supported field types - self::$types = apply_filters( - 'form_field_types', - self::$types - ); - } - - - /** - * Create field - * - * @param array $field Field array - * @param array $args Extra field arguments - */ - final public static function create( array $field, $args = array() ) { - $field = wp_parse_args( $field, self::$defaults['field'] ); - if ( ! isset( self::$types[ $field['type'] ] ) - || ! is_subclass_of( self::$types[ $field['type'] ], __CLASS__ ) - ) { - trigger_error( - sprintf( - esc_html__( '%1$s: Type %2$s is not supported, reverting to text.', 'menu-icons' ), - __CLASS__, - esc_html( $field['type'] ) - ), - E_USER_WARNING - ); - $field['type'] = 'text'; - } - - if ( is_null( $field['value'] ) && ! is_null( $field['default'] ) ) { - $field['value'] = $field['default']; - } - - foreach ( self::$forbidden_attributes as $key ) { - unset( $field['attributes'][ $key ] ); - } - - $args = (object) wp_parse_args( $args, self::$defaults['args'] ); - $class = self::$types[ $field['type'] ]; - - return new $class( $field, $args ); - } - - - /** - * Constructor - * - * @since 0.1.0 - * @param array $field Field array - * @param object $args Extra field arguments - */ - public function __construct( $field, $args ) { - $this->field = $field; - $this->args = $args; - - if ( ! is_array( $this->args->keys ) ) { - $this->args->keys = array(); - } - $this->args->keys[] = $field['id']; - - $this->attributes['id'] = $this->create_id(); - $this->attributes['name'] = $this->create_name(); - - $this->attributes = wp_parse_args( - $this->attributes, - (array) $field['attributes'] - ); - - $this->set_properties(); - } - - - /** - * Attribute - * - * @since 0.1.0 - * @param string $key Attribute key - * @return mixed NULL if attribute doesn't exist - */ - public function __get( $key ) { - foreach ( array( 'attributes', 'field' ) as $group ) { - if ( isset( $this->{$group}[ $key ] ) ) { - return $this->{$group}[ $key ]; - } - } - - return null; - } - - - /** - * Create id/name attribute - * - * @since 0.1.0 - * @param string $format Attribute format - */ - protected function create_id_name( $format ) { - return call_user_func_array( - 'sprintf', - array_merge( - array( $format ), - $this->args->keys - ) - ); - } - - - /** - * Create id attribute - * - * @since 0.1.0 - * @access protected - * @return string - */ - protected function create_id() { - $format = implode( '-', $this->args->keys ); - - return $this->create_id_name( $format ); - } - - - /** - * Create name attribute - * - * @since 0.1.0 - * @access protected - * @return string - */ - protected function create_name() { - $format = '%s'; - $format .= str_repeat( '[%s]', ( count( $this->args->keys ) - 1 ) ); - - return $this->create_id_name( $format ); - } - - - /** - * Set field properties - * - * @since 0.1.0 - */ - protected function set_properties() {} - - - /** - * Build field attributes - * - * @since 0.1.0 - * @param array $excludes Attributes to be excluded - * @return string - */ - protected function build_attributes( $excludes = array() ) { - $excludes = array_filter( (array) $excludes ); - $attributes = ''; - - foreach ( $this->attributes as $key => $value ) { - if ( in_array( $key, $excludes, true ) ) { - continue; - } - - if ( 'class' === $key ) { - $value = implode( ' ', (array) $value ); - } - - $attributes .= sprintf( - ' %s="%s"', - esc_attr( $key ), - esc_attr( $value ) - ); - } - - return $attributes; - } - - - /** - * Print field - * - * @since 0.1.0 - */ - abstract public function render(); - - - /** - * Print field description - * - * @since 0.1.0 - */ - public function description() { - if ( ! empty( $this->field['description'] ) ) { - $tag = ( ! empty( $this->args->inline_description ) ) ? 'span' : 'p'; - - printf( // WPCS: XSS ok. - '<%1$s class="description">%2$s', - $tag, - wp_kses( $this->field['description'], $this->allowed_html ) - ); - } - } -} - - -/** - * Field: text - */ -class Kucrut_Form_Field_Text extends Kucrut_Form_Field { - - protected $template = ''; - - - protected function set_properties() { - if ( ! is_string( $this->field['value'] ) ) { - $this->field['value'] = ''; - } - - if ( in_array( $this->field['type'], array( 'text', 'url' ), true ) ) { - if ( ! isset( $this->attributes['class'] ) ) { - $this->attributes['class'] = array(); - } - $this->attributes['class'] = array_unique( - array_merge( - array( 'regular-text' ), - $this->attributes['class'] - ) - ); - } - } - - - public function render() { - printf( // WPCS: xss ok - $this->template, - esc_attr( $this->field['type'] ), - esc_attr( $this->field['value'] ), - $this->build_attributes() - ); - $this->description(); - } -} - - -/** - * Field: Textarea - */ -class Kucrut_Form_Field_Textarea extends Kucrut_Form_Field { - - protected $template = '%s'; - - protected $attributes = array( - 'class' => 'widefat', - 'cols' => 50, - 'rows' => 5, - ); - - - public function render() { - printf( // WPCS: XSS ok. - $this->template, - $this->build_attributes(), - esc_textarea( $this->field['value'] ) - ); - } -} - - -/** - * Field: Checkbox - */ -class Kucrut_Form_Field_Checkbox extends Kucrut_Form_Field { - - protected $template = '
            '; - - - protected function set_properties() { - $this->field['value'] = array_filter( (array) $this->field['value'] ); - $this->attributes['name'] .= '[]'; - } - - - protected function checked( $value ) { - return checked( in_array( $value, $this->field['value'], true ), true, false ); - } - - - public function render() { - foreach ( $this->field['choices'] as $value => $label ) { - printf( // WPCS: XSS ok. - $this->template, - $this->field['type'], - esc_attr( $value ), - $this->checked( $value ), - $this->build_attributes( 'id' ), - esc_html( $label ) - ); - } - } -} - - -/** - * Field: Radio - */ -class Kucrut_Form_Field_Radio extends Kucrut_Form_Field_Checkbox { - - protected function set_properties() { - if ( ! is_string( $this->field['value'] ) ) { - $this->field['value'] = ''; - } - } - - - protected function checked( $value ) { - return checked( $value, $this->field['value'], false ); - } -} - - -/** - * Field: Select - */ -class Kucrut_Form_Field_Select extends Kucrut_Form_Field { - - protected $template = ''; - - - protected function set_properties() { - if ( ! is_string( $this->field['value'] ) ) { - $this->field['value'] = ''; - } - } - - - protected function selected( $value ) { - return selected( ( $value === $this->field['value'] ), true, false ); - } - - - public function render() { - ?> - build_attributes() // xss ok ?>> - field['choices'] as $index => $choice ) : ?> - - template, - esc_attr( $value ), - $this->selected( $value ), - esc_html( $label ) - ); - ?> - - - field['value'] = array_filter( (array) $this->field['value'] ); - $this->attributes['name'] .= '[]'; - $this->attributes['multiple'] = 'multiple'; - } - - - protected function selected( $value ) { - return selected( in_array( $value, $this->field['value'], true ), true, false ); - } -} - - -/** - * Field: Select Pages - */ -class Kucrut_Form_Field_Select_Pages extends Kucrut_Form_Field_Select { - - protected $wp_dropdown_pages_args = array( - 'depth' => 0, - 'child_of' => 0, - 'option_none_value' => '', - ); - - - public function __construct( $field, $args ) { - $this->wp_dropdown_pages_args['show_option_none'] = __( '— Select —', 'menu-icons' ); - parent::__construct( $field, $args ); - } - - - public function set_properties() { - parent::set_properties(); - - if ( empty( $this->args->wp_dropdown_pages_args ) ) { - $this->args->wp_dropdown_pages_args = array(); - } - - // Apply defeaults - $this->args->wp_dropdown_pages_args = wp_parse_args( - $this->args->wp_dropdown_pages_args, - $this->wp_dropdown_pages_args - ); - - // Force some args - $this->args->wp_dropdown_pages_args = array_merge( - $this->args->wp_dropdown_pages_args, - array( - 'echo' => true, - 'name' => $this->attributes['name'], - 'id' => $this->attributes['id'], - 'selected' => $this->field['value'], - ) - ); - } - - - public function render() { - wp_dropdown_pages( $this->args->wp_dropdown_pages_args ); // WPCS: XSS ok. - } -} - - -/** - * Field: Special (Callback) - */ -class Kucrut_Form_Field_Special extends Kucrut_Form_Field { - public function render() { - call_user_func_array( - $this->field['render_cb'], - array( $this ) - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/functions.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/functions.php deleted file mode 100644 index 7985369a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/library/functions.php +++ /dev/null @@ -1,111 +0,0 @@ - - */ - - -if ( ! function_exists( 'kucrut_get_array_value_deep' ) ) { - /** - * Get value of a multidimensional array - * - * @since 0.1.0 - * @param array $array Haystack - * @param array $keys Needles - * @return mixed - */ - function kucrut_get_array_value_deep( array $array, array $keys ) { - if ( empty( $array ) || empty( $keys ) ) { - return $array; - } - - foreach ( $keys as $idx => $key ) { - unset( $keys[ $idx ] ); - - if ( ! isset( $array[ $key ] ) ) { - return null; - } - - if ( ! empty( $keys ) ) { - $array = $array[ $key ]; - } - } - - if ( ! isset( $array[ $key ] ) ) { - return null; - } - - return $array[ $key ]; - } -} - - -if ( ! function_exists( 'kucrut_validate' ) ) { - /** - * Validate settings values - * - * @param array $values Settings values - * @return array - */ - function kucrut_validate( $values, $sanitize_cb = 'wp_kses_data' ) { - foreach ( $values as $key => $value ) { - if ( is_array( $value ) ) { - $values[ $key ] = kucrut_validate( $value ); - } else { - $values[ $key ] = call_user_func_array( - $sanitize_cb, - array( $value ) - ); - } - } - - return $values; - } -} - - -if ( ! function_exists( 'kucrut_get_image_sizes' ) ) { - /** - * Get image sizes - * - * @since 0.9.0 - * @access protected - * @return array - */ - function kucrut_get_image_sizes() { - $_sizes = array( - 'thumbnail' => __( 'Thumbnail', 'menu-icons' ), - 'medium' => __( 'Medium', 'menu-icons' ), - 'large' => __( 'Large', 'menu-icons' ), - 'full' => __( 'Full Size', 'menu-icons' ), - ); - - $_sizes = apply_filters( 'image_size_names_choose', $_sizes ); - - $sizes = array(); - foreach ( $_sizes as $value => $label ) { - $sizes[] = array( - 'value' => $value, - 'label' => $label, - ); - } - - return $sizes; - } -} - - -if ( ! function_exists( 'kucrut_get_script_suffix' ) ) { - /** - * Get script & style suffix - * - * When SCRIPT_DEBUG is defined true, this will return '.min'. - * - * @return string - */ - function kucrut_get_script_suffix() { - return ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min'; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/media-template.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/media-template.php deleted file mode 100644 index 4749e150..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/media-template.php +++ /dev/null @@ -1,127 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */ -final class Menu_Icons_Meta { - - const KEY = 'menu-icons'; - - /** - * Default meta value - * - * @since 0.9.0 - * @access protected - * @var array - */ - protected static $defaults = array( - 'type' => '', - 'icon' => '', - 'url' => '', - ); - - - /** - * Initialize metadata functionalities - * - * @since 0.9.0 - */ - public static function init() { - add_filter( 'is_protected_meta', array( __CLASS__, '_protect_meta_key' ), 10, 3 ); - } - - - /** - * Protect meta key - * - * This prevents our meta key from showing up on Custom Fields meta box. - * - * @since 0.3.0 - * @wp_hook filter is_protected_meta - * @param bool $protected Protection status. - * @param string $meta_key Meta key. - * @param string $meta_type Meta type. - * @return bool Protection status. - */ - public static function _protect_meta_key( $protected, $meta_key, $meta_type ) { - if ( self::KEY === $meta_key ) { - $protected = true; - } - - return $protected; - } - - - /** - * Get menu item meta value - * - * @since 0.3.0 - * @since 0.9.0 Add $defaults parameter. - * @param int $id Menu item ID. - * @param array $defaults Optional. Default value. - * @return array - */ - public static function get( $id, $defaults = array() ) { - $defaults = wp_parse_args( $defaults, self::$defaults ); - $value = get_post_meta( $id, self::KEY, true ); - $value = wp_parse_args( (array) $value, $defaults ); - - if ( ! empty( $value['type'] ) && 'fa' === $value['type'] ) { - if ( ! empty( $value['icon'] ) && count( explode( ' ', $value['icon'] ) ) <= 1 ) { - $value['icon'] = sprintf( 'fa %s', $value['icon'] ); - } - } - - $font_awesome5 = font_awesome_backward_compatible(); - $icon = ! empty( $value['icon'] ) ? $value['icon'] : ''; - $icon = explode( ' ', $icon ); - $icon = sprintf( '%s-%s', reset( $icon ), end( $icon ) ); - - if ( ! empty( $font_awesome5[ $icon ] ) ) { - $value['icon'] = $font_awesome5[ $icon ]; - } - - // Backward-compatibility. - if ( empty( $value['icon'] ) && - ! empty( $value['type'] ) && - ! empty( $value[ "{$value['type']}-icon" ] ) - ) { - $value['icon'] = $value[ "{$value['type']}-icon" ]; - } - - if ( ! empty( $value['width'] ) ) { - $value['svg_width'] = $value['width']; - } - unset( $value['width'] ); - - if ( isset( $value['position'] ) && - ! in_array( $value['position'], array( 'before', 'after' ), true ) - ) { - $value['position'] = $defaults['position']; - } - - if ( isset( $value['size'] ) && ! isset( $value['font_size'] ) ) { - $value['font_size'] = $value['size']; - unset( $value['size'] ); - } - - // The values below will NOT be saved - if ( ! empty( $value['icon'] ) && - in_array( $value['type'], array( 'image', 'svg' ), true ) - ) { - $value['url'] = wp_get_attachment_image_url( $value['icon'], 'thumbnail', false ); - } - - return $value; - } - - - /** - * Update menu item metadata - * - * @since 0.9.0 - * - * @param int $id Menu item ID. - * @param mixed $value Metadata value. - * - * @return void - */ - public static function update( $id, $value ) { - /** - * Allow plugins/themes to filter the values - * - * Deprecated. - * - * @since 0.1.0 - * @param array $value Metadata value. - * @param int $id Menu item ID. - */ - $_value = apply_filters( 'menu_icons_values', $value, $id ); - - if ( $_value !== $value && WP_DEBUG ) { - _deprecated_function( 'menu_icons_values', '0.8.0', 'menu_icons_item_meta_values' ); - } - - /** - * Allow plugins/themes to filter the values - * - * @since 0.8.0 - * @param array $value Metadata value. - * @param int $id Menu item ID. - */ - $value = apply_filters( 'menu_icons_item_meta_values', $_value, $id ); - - // Don't bother saving if `type` or `icon` is not set. - if ( empty( $value['type'] ) || empty( $value['icon'] ) ) { - $value = false; - } - - // Update - if ( ! empty( $value ) ) { - update_post_meta( $id, self::KEY, $value ); - } else { - delete_post_meta( $id, self::KEY ); - } - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/picker.php b/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/picker.php deleted file mode 100644 index f653abe6..00000000 --- a/wp-content/upgrade-temp-backup/plugins/menu-icons/includes/picker.php +++ /dev/null @@ -1,305 +0,0 @@ - - */ - - -/** - * Nav menu admin - */ -final class Menu_Icons_Picker { - - /** - * Initialize class - * - * @since 0.1.0 - */ - public static function init() { - add_action( 'load-nav-menus.php', array( __CLASS__, '_load_nav_menus' ) ); - add_filter( 'wp_nav_menu_item_custom_fields', array( __CLASS__, '_fields' ), 10, 4 ); - add_filter( 'manage_nav-menus_columns', array( __CLASS__, '_columns' ), 99 ); - add_action( 'wp_update_nav_menu_item', array( __CLASS__, '_save' ), 10, 3 ); - add_filter( 'icon_picker_type_props', array( __CLASS__, '_add_extra_type_props_data' ), 10, 3 ); - - if ( ! version_compare( get_bloginfo( 'version' ), '5.4', '>=' ) ) { - add_filter( - 'wp_edit_nav_menu_walker', function() { - return 'Menu_Item_Custom_Fields_Walker'; - }, 99 - ); - } - } - - - /** - * Load Icon Picker - * - * @since 0.9.0 - * @wp_hook action load-nav-menus.php - */ - public static function _load_nav_menus() { - Icon_Picker::instance()->load(); - - add_action( 'print_media_templates', array( __CLASS__, '_media_templates' ) ); - } - - - /** - * Get menu item setting fields - * - * @since 0.9.0 - * @access protected - * @param array $meta Menu item meta value. - * @return array - */ - protected static function _get_menu_item_fields( $meta ) { - $fa_icon = sprintf( '%s-%s', $meta['type'], $meta['icon'] ); - $font_awesome5 = font_awesome_backward_compatible(); - - if ( array_key_exists( $fa_icon, $font_awesome5 ) ) { - $fa5_icon = $font_awesome5[ $fa_icon ]; - $fa5_class = explode( ' ', $fa5_icon ); - $type = reset( $fa5_class ); - $icon = end( $fa5_class ); - $meta['icon'] = sprintf( '%s %s', $type, $icon ); - } - - $fields = array_merge( - array( - array( - 'id' => 'type', - 'label' => __( 'Type', 'menu-icons' ), - 'value' => $meta['type'], - ), - array( - 'id' => 'icon', - 'label' => __( 'Icon', 'menu-icons' ), - 'value' => $meta['icon'], - ), - ), - Menu_Icons_Settings::get_settings_fields( $meta ) - ); - - return $fields; - } - - - /** - * Print fields - * - * @since 0.1.0 - * @access protected - * @uses add_action() Calls 'menu_icons_before_fields' hook - * @uses add_action() Calls 'menu_icons_after_fields' hook - * @wp_hook action menu_item_custom_fields - * - * @param object $item Menu item data object. - * @param int $depth Nav menu depth. - * @param array $args Menu item args. - * @param int $id Nav menu ID. - * - * @return string Form fields - */ - public static function _fields( $id, $item, $depth, $args ) { - $input_id = sprintf( 'menu-icons-%d', $item->ID ); - $input_name = sprintf( 'menu-icons[%d]', $item->ID ); - $menu_settings = Menu_Icons_Settings::get_menu_settings( Menu_Icons_Settings::get_current_menu_id() ); - $meta = Menu_Icons_Meta::get( $item->ID, $menu_settings ); - $fields = self::_get_menu_item_fields( $meta ); - ?> - - id ) { - return; - } - - check_admin_referer( 'update-nav_menu', 'update-nav-menu-nonce' ); - - // Sanitize - if ( ! empty( $_POST['menu-icons'][ $menu_item_db_id ] ) ) { - $value = array_map( - 'sanitize_text_field', - wp_unslash( (array) $_POST['menu-icons'][ $menu_item_db_id ] ) - ); - } else { - $value = array(); - } - - Menu_Icons_Meta::update( $menu_item_db_id, $value ); - } - - - /** - * Get and print media templates from all types - * - * @since 0.2.0 - * @since 0.9.0 Deprecate menu_icons_media_templates filter. - * @wp_hook action print_media_templates - */ - public static function _media_templates() { - $id_prefix = 'tmpl-menu-icons'; - - // Deprecated. - $templates = apply_filters( 'menu_icons_media_templates', array() ); - - if ( ! empty( $templates ) ) { - if ( WP_DEBUG ) { - _deprecated_function( 'menu_icons_media_templates', '0.9.0', 'menu_icons_js_templates' ); - } - - foreach ( $templates as $key => $template ) { - $id = sprintf( '%s-%s', $id_prefix, $key ); - self::_print_tempate( $id, $template ); - } - } - - require_once dirname( __FILE__ ) . '/media-template.php'; - } - - - /** - * Print media template - * - * @since 0.2.0 - * @param string $id Template ID. - * @param string $template Media template HTML. - */ - protected static function _print_tempate( $id, $template ) { - ?> - - - */ - -/** - * Menu Icons Settings module - */ -final class Menu_Icons_Settings { - - const UPDATE_KEY = 'menu-icons-settings-update'; - - const RESET_KEY = 'menu-icons-settings-reset'; - - const TRANSIENT_KEY = 'menu_icons_message'; - - /** - * Default setting values - * - * @since 0.3.0 - * @var array - * @access protected - */ - protected static $defaults = array( - 'global' => array( - 'icon_types' => array( 'dashicons' ), - ), - ); - - /** - * Setting values - * - * @since 0.3.0 - * @var array - * @access protected - */ - protected static $settings = array(); - - /** - * Script dependencies - * - * @since 0.9.0 - * @access protected - * @var array - */ - protected static $script_deps = array( 'jquery' ); - - /** - * Settings init - * - * @since 0.3.0 - */ - public static function init() { - // Include Menu Icons for Block Editor - if ( class_exists( '\ThemeIsle\GutenbergMenuIcons' ) ) { - \ThemeIsle\GutenbergMenuIcons::instance(); - add_action( 'enqueue_block_assets', array( __CLASS__, '_enqueue_font_awesome' ) ); - } - - /** - * Allow themes/plugins to override the default settings - * - * @since 0.9.0 - * - * @param array $default_settings Default settings. - */ - self::$defaults = apply_filters( 'menu_icons_settings_defaults', self::$defaults ); - - self::$settings = get_option( 'menu-icons', self::$defaults ); - - foreach ( self::$settings as $key => &$value ) { - if ( 'global' === $key ) { - // Remove unregistered icon types. - $value['icon_types'] = array_values( - array_intersect( - array_keys( Menu_Icons::get( 'types' ) ), - array_filter( (array) $value['icon_types'] ) - ) - ); - } else { - // Backward-compatibility. - if ( isset( $value['width'] ) && ! isset( $value['svg_width'] ) ) { - $value['svg_width'] = $value['width']; - } - - unset( $value['width'] ); - } - } - - unset( $value ); - - /** - * Allow themes/plugins to override the settings - * - * @since 0.9.0 - * - * @param array $settings Menu Icons settings. - */ - self::$settings = apply_filters( 'menu_icons_settings', self::$settings ); - - if ( self::is_menu_icons_disabled_for_menu() ) { - return; - } - - if ( ! empty( self::$settings['global']['icon_types'] ) ) { - require_once Menu_Icons::get( 'dir' ) . 'includes/picker.php'; - Menu_Icons_Picker::init(); - self::$script_deps[] = 'icon-picker'; - } - - add_action( 'load-nav-menus.php', array( __CLASS__, '_load_nav_menus' ), 1 ); - add_action( 'wp_ajax_menu_icons_update_settings', array( __CLASS__, '_ajax_menu_icons_update_settings' ) ); - } - - /** - * Check if menu icons is disabled for a menu - * - * @since 0.8.0 - * - * @param int $menu_id Menu ID. Defaults to current menu being edited. - * - * @return bool - */ - public static function is_menu_icons_disabled_for_menu( $menu_id = 0 ) { - if ( empty( $menu_id ) ) { - $menu_id = self::get_current_menu_id(); - } - - // When we're creating a new menu or the recently edited menu - // could not be found. - if ( empty( $menu_id ) ) { - return true; - } - - $menu_settings = self::get_menu_settings( $menu_id ); - $is_disabled = ! empty( $menu_settings['disabled'] ); - - return $is_disabled; - } - - /** - * Get ID of menu being edited - * - * @since 0.7.0 - * @since 0.8.0 Get the recently edited menu from user option. - * - * @return int - */ - public static function get_current_menu_id() { - global $nav_menu_selected_id; - - if ( ! empty( $nav_menu_selected_id ) ) { - return $nav_menu_selected_id; - } - - if ( is_admin() && isset( $_REQUEST['menu'] ) ) { - $menu_id = absint( $_REQUEST['menu'] ); - } else { - $menu_id = absint( get_user_option( 'nav_menu_recently_edited' ) ); - } - - return $menu_id; - } - - /** - * Get menu settings - * - * @since 0.3.0 - * - * @param int $menu_id - * - * @return array - */ - public static function get_menu_settings( $menu_id ) { - $menu_settings = self::get( sprintf( 'menu_%d', $menu_id ) ); - $menu_settings = apply_filters( 'menu_icons_menu_settings', $menu_settings, $menu_id ); - - if ( ! is_array( $menu_settings ) ) { - $menu_settings = array(); - } - - return $menu_settings; - } - - /** - * Get setting value - * - * @since 0.3.0 - * @return mixed - */ - public static function get() { - $args = func_get_args(); - - return kucrut_get_array_value_deep( self::$settings, $args ); - } - - /** - * Prepare wp-admin/nav-menus.php page - * - * @since 0.3.0 - * @wp_hook action load-nav-menus.php - */ - public static function _load_nav_menus() { - add_action( 'admin_enqueue_scripts', array( __CLASS__, '_enqueue_assets' ), 99 ); - - /** - * Allow settings meta box to be disabled. - * - * @since 0.4.0 - * - * @param bool $disabled Defaults to FALSE. - */ - $settings_disabled = apply_filters( 'menu_icons_disable_settings', false ); - if ( true === $settings_disabled ) { - return; - } - - self::_maybe_update_settings(); - self::_add_settings_meta_box(); - - add_action( 'admin_notices', array( __CLASS__, '_admin_notices' ) ); - } - - /** - * Update settings - * - * @since 0.3.0 - */ - public static function _maybe_update_settings() { - if ( ! empty( $_POST['menu-icons']['settings'] ) ) { - check_admin_referer( self::UPDATE_KEY, self::UPDATE_KEY ); - - $redirect_url = self::_update_settings( $_POST['menu-icons']['settings'] ); // Input var okay. - wp_redirect( $redirect_url ); - } elseif ( ! empty( $_REQUEST[ self::RESET_KEY ] ) ) { - check_admin_referer( self::RESET_KEY, self::RESET_KEY ); - wp_redirect( self::_reset_settings() ); - } - } - - /** - * Update settings - * - * @since 0.7.0 - * @access protected - * - * @param array $values Settings values. - * - * @return string Redirect URL. - */ - protected static function _update_settings( $values ) { - update_option( - 'menu-icons', - wp_parse_args( - kucrut_validate( $values ), - self::$settings - ) - ); - set_transient( self::TRANSIENT_KEY, 'updated', 30 ); - - $redirect_url = remove_query_arg( - array( 'menu-icons-reset' ), - wp_get_referer() - ); - - return $redirect_url; - } - - /** - * Reset settings - * - * @since 0.7.0 - * @access protected - * @return string Redirect URL. - */ - protected static function _reset_settings() { - delete_option( 'menu-icons' ); - set_transient( self::TRANSIENT_KEY, 'reset', 30 ); - - $redirect_url = remove_query_arg( - array( self::RESET_KEY, 'menu-icons-updated' ), - wp_get_referer() - ); - - return $redirect_url; - } - - /** - * Settings meta box - * - * @since 0.3.0 - * @access private - */ - private static function _add_settings_meta_box() { - add_meta_box( - 'menu-icons-settings', - __( 'Menu Icons Settings', 'menu-icons' ), - array( __CLASS__, '_meta_box' ), - 'nav-menus', - 'side', - 'low', - array() - ); - } - - /** - * Update settings via ajax - * - * @since 0.7.0 - * @wp_hook action wp_ajax_menu_icons_update_settings - */ - public static function _ajax_menu_icons_update_settings() { - check_ajax_referer( self::UPDATE_KEY, self::UPDATE_KEY ); - - if ( empty( $_POST['menu-icons']['settings'] ) ) { - wp_send_json_error(); - } - - $redirect_url = self::_update_settings( $_POST['menu-icons']['settings'] ); // Input var okay. - wp_send_json_success( array( 'redirectUrl' => $redirect_url ) ); - } - - /** - * Print admin notices - * - * @since 0.3.0 - * @wp_hook action admin_notices - */ - public static function _admin_notices() { - $messages = array( - 'updated' => __( 'Menu Icons Settings have been successfully updated.', 'menu-icons' ), - 'reset' => __( 'Menu Icons Settings have been successfully reset.', 'menu-icons' ), - ); - - $message_type = get_transient( self::TRANSIENT_KEY ); - - if ( ! empty( $message_type ) && ! empty( $messages[ $message_type ] ) ) { - printf( - '

            %s

            ', - wp_kses( $messages[ $message_type ], array( 'strong' => true ) ) - ); - } - - delete_transient( self::TRANSIENT_KEY ); - } - - /** - * Settings meta box - * - * @since 0.3.0 - */ - public static function _meta_box() { - ?> -
            - - $section ) : ?> - - -
            -

            - - - %s', - esc_url( - wp_nonce_url( - admin_url( '/nav-menus.php' ), - self::RESET_KEY, - self::RESET_KEY - ) - ), - esc_attr__( 'Discard all changes and reset to default state', 'menu-icons' ), - esc_html__( 'Reset', 'menu-icons' ) - ); - ?> - - - - - - -

            - array( - 'id' => 'global', - 'title' => __( 'Global', 'menu-icons' ), - 'description' => __( 'Global settings', 'menu-icons' ), - 'fields' => array( - array( - 'id' => 'icon_types', - 'type' => 'checkbox', - 'label' => __( 'Icon Types', 'menu-icons' ), - 'choices' => $icon_types, - 'value' => self::get( 'global', 'icon_types' ), - ), - array( - 'id' => 'fa5_extra_icons', - 'type' => 'textarea', - 'label' => __( 'FA Custom Icon Classes', 'menu-icons' ), - 'value' => self::get( 'global', 'fa5_extra_icons' ), - 'help_text' => '( comma separated icons )', - ), - ), - 'args' => array(), - ), - ); - - if ( ! empty( $menu_id ) ) { - $menu_term = get_term( $menu_id, 'nav_menu' ); - $menu_key = sprintf( 'menu_%d', $menu_id ); - $menu_settings = self::get_menu_settings( $menu_id ); - - $sections['menu'] = array( - 'id' => $menu_key, - 'title' => __( 'Current Menu', 'menu-icons' ), - 'description' => sprintf( - __( '"%s" menu settings', 'menu-icons' ), - apply_filters( 'single_term_title', $menu_term->name ) - ), - 'fields' => self::get_settings_fields( $menu_settings ), - 'args' => array( 'inline_description' => true ), - ); - } - - return apply_filters( 'menu_icons_settings_sections', $sections, $menu_id ); - } - - /** - * Get settings fields - * - * @since 0.4.0 - * - * @param array $values Values to be applied to each field. - * - * @uses apply_filters() Calls 'menu_icons_settings_fields'. - * @return array - */ - public static function get_settings_fields( array $values = array() ) { - $fields = array( - 'hide_label' => array( - 'id' => 'hide_label', - 'type' => 'select', - 'label' => __( 'Hide Label', 'menu-icons' ), - 'default' => '', - 'choices' => array( - array( - 'value' => '', - 'label' => __( 'No', 'menu-icons' ), - ), - array( - 'value' => '1', - 'label' => __( 'Yes', 'menu-icons' ), - ), - ), - ), - 'position' => array( - 'id' => 'position', - 'type' => 'select', - 'label' => __( 'Position', 'menu-icons' ), - 'default' => 'before', - 'choices' => array( - array( - 'value' => 'before', - 'label' => __( 'Before', 'menu-icons' ), - ), - array( - 'value' => 'after', - 'label' => __( 'After', 'menu-icons' ), - ), - ), - ), - 'vertical_align' => array( - 'id' => 'vertical_align', - 'type' => 'select', - 'label' => __( 'Vertical Align', 'menu-icons' ), - 'default' => 'middle', - 'choices' => array( - array( - 'value' => 'super', - 'label' => __( 'Super', 'menu-icons' ), - ), - array( - 'value' => 'top', - 'label' => __( 'Top', 'menu-icons' ), - ), - array( - 'value' => 'text-top', - 'label' => __( 'Text Top', 'menu-icons' ), - ), - array( - 'value' => 'middle', - 'label' => __( 'Middle', 'menu-icons' ), - ), - array( - 'value' => 'baseline', - 'label' => __( 'Baseline', 'menu-icons' ), - ), - array( - 'value' => 'text-bottom', - 'label' => __( 'Text Bottom', 'menu-icons' ), - ), - array( - 'value' => 'bottom', - 'label' => __( 'Bottom', 'menu-icons' ), - ), - array( - 'value' => 'sub', - 'label' => __( 'Sub', 'menu-icons' ), - ), - ), - ), - 'font_size' => array( - 'id' => 'font_size', - 'type' => 'number', - 'label' => __( 'Font Size', 'menu-icons' ), - 'default' => '1.2', - 'description' => 'em', - 'attributes' => array( - 'min' => '0.1', - 'step' => '0.1', - ), - ), - 'svg_width' => array( - 'id' => 'svg_width', - 'type' => 'number', - 'label' => __( 'SVG Width', 'menu-icons' ), - 'default' => '1', - 'description' => 'em', - 'attributes' => array( - 'min' => '.5', - 'step' => '.1', - ), - ), - 'image_size' => array( - 'id' => 'image_size', - 'type' => 'select', - 'label' => __( 'Image Size', 'menu-icons' ), - 'default' => 'thumbnail', - 'choices' => kucrut_get_image_sizes(), - ), - ); - - $fields = apply_filters( 'menu_icons_settings_fields', $fields ); - - foreach ( $fields as &$field ) { - if ( isset( $values[ $field['id'] ] ) ) { - $field['value'] = $values[ $field['id'] ]; - } - - if ( ! isset( $field['value'] ) && isset( $field['default'] ) ) { - $field['value'] = $field['default']; - } - } - - unset( $field ); - - return $fields; - } - - /** - * Get processed settings fields - * - * @since 0.3.0 - * @access private - * @return array - */ - private static function _get_fields() { - if ( ! class_exists( 'Kucrut_Form_Field' ) ) { - require_once Menu_Icons::get( 'dir' ) . 'includes/library/form-fields.php'; - } - - $keys = array( 'menu-icons', 'settings' ); - $sections = self::get_fields(); - - foreach ( $sections as &$section ) { - $_keys = array_merge( $keys, array( $section['id'] ) ); - $_args = array_merge( array( 'keys' => $_keys ), $section['args'] ); - - foreach ( $section['fields'] as &$field ) { - $field = Kucrut_Form_Field::create( $field, $_args ); - } - - unset( $field ); - } - - unset( $section ); - - return $sections; - } - - /** - * Enqueue scripts & styles for Block Icons - * - * @since 0.3.0 - * @wp_hook action enqueue_block_assets - */ - public static function _enqueue_font_awesome() { - $url = Menu_Icons::get( 'url' ); - - wp_register_style( - 'font-awesome-5', - "{$url}css/fontawesome/css/all.min.css" - ); - } - - /** - * Enqueue scripts & styles for Appearance > Menus page - * - * @since 0.3.0 - * @wp_hook action admin_enqueue_scripts - */ - public static function _enqueue_assets() { - $url = Menu_Icons::get( 'url' ); - $suffix = kucrut_get_script_suffix(); - - if ( defined( 'MENU_ICONS_SCRIPT_DEBUG' ) && MENU_ICONS_SCRIPT_DEBUG ) { - $script_url = '//localhost:8081/'; - } else { - $script_url = $url; - } - - wp_enqueue_style( - 'menu-icons', - "{$url}css/admin{$suffix}.css", - false, - Menu_Icons::VERSION - ); - - wp_enqueue_script( - 'menu-icons', - "{$script_url}js/admin{$suffix}.js", - self::$script_deps, - Menu_Icons::VERSION, - true - ); - - $customizer_url = add_query_arg( - array( - 'autofocus[section]' => 'custom_css', - 'return' => admin_url( 'nav-menus.php' ), - ), - admin_url( 'customize.php' ) - ); - - /** - * Allow plugins/themes to filter the settings' JS data - * - * @since 0.9.0 - * - * @param array $js_data JS Data. - */ - $menu_current_theme = ''; - $theme = wp_get_theme(); - if ( ! empty( $theme ) ) { - if ( is_child_theme() && $theme->parent() ) { - $menu_current_theme = $theme->parent()->get( 'Name' ); - } else { - $menu_current_theme = $theme->get( 'Name' ); - } - } - $upsell_notices = array(); - $box_data = ''; - } - $settings_fields = ''; - $settings_fields = apply_filters('smtp_mailer_advanced_settings_fields', $settings_fields); - if(empty($settings_fields)){ - return; - } - ?> -
            - - - - - - - -
            - -

            -
            - -
            -

            -
            - 0 ) { - $from_name = substr( $content, 0, $bracket_pos ); - $from_name = str_replace( '"', '', $from_name ); - $from_name = trim( $from_name ); - } - - $from_email = substr( $content, $bracket_pos + 1 ); - $from_email = str_replace( '>', '', $from_email ); - $from_email = trim( $from_email ); - - // Avoid setting an empty $from_email. - } elseif ( '' !== trim( $content ) ) { - $from_email = trim( $content ); - } - break; - case 'content-type': - if ( str_contains( $content, ';' ) ) { - list( $type, $charset_content ) = explode( ';', $content ); - $content_type = trim( $type ); - if ( false !== stripos( $charset_content, 'charset=' ) ) { - $charset = trim( str_replace( array( 'charset=', '"' ), '', $charset_content ) ); - } elseif ( false !== stripos( $charset_content, 'boundary=' ) ) { - $boundary = trim( str_replace( array( 'BOUNDARY=', 'boundary=', '"' ), '', $charset_content ) ); - $charset = ''; - } - - // Avoid setting an empty $content_type. - } elseif ( '' !== trim( $content ) ) { - $content_type = trim( $content ); - } - break; - case 'cc': - $cc = array_merge( (array) $cc, explode( ',', $content ) ); - break; - case 'bcc': - $bcc = array_merge( (array) $bcc, explode( ',', $content ) ); - break; - case 'reply-to': - $reply_to = array_merge( (array) $reply_to, explode( ',', $content ) ); - break; - default: - // Add it to our grand headers array. - $headers[ trim( $name ) ] = trim( $content ); - break; - } - } - } - } - - // Empty out the values that may be set. - $phpmailer->clearAllRecipients(); - $phpmailer->clearAttachments(); - $phpmailer->clearCustomHeaders(); - $phpmailer->clearReplyTos(); - $phpmailer->Body = ''; - $phpmailer->AltBody = ''; - - // Set "From" name and email. - - // If we don't have a name from the input headers. - if ( ! isset( $from_name ) ) { - $from_name = $options['from_name'];//'WordPress'; - } - - /* - * If we don't have an email from the input headers, default to wordpress@$sitename - * Some hosts will block outgoing mail from this address if it doesn't exist, - * but there's no easy alternative. Defaulting to admin_email might appear to be - * another option, but some hosts may refuse to relay mail from an unknown domain. - * See https://core.trac.wordpress.org/ticket/5007. - */ - if ( ! isset( $from_email ) ) { - // Get the site domain and get rid of www. - $sitename = wp_parse_url( network_home_url(), PHP_URL_HOST ); - $from_email = 'wordpress@'; - - if ( null !== $sitename ) { - if ( str_starts_with( $sitename, 'www.' ) ) { - $sitename = substr( $sitename, 4 ); - } - - $from_email .= $sitename; - } - $from_email = $options['from_email'];//'wordpress@' . $sitename; - } - - /** - * Filters the email address to send from. - * - * @since 2.2.0 - * - * @param string $from_email Email address to send from. - */ - $from_email = apply_filters( 'wp_mail_from', $from_email ); - - /** - * Filters the name to associate with the "from" email address. - * - * @since 2.3.0 - * - * @param string $from_name Name associated with the "from" email address. - */ - $from_name = apply_filters( 'wp_mail_from_name', $from_name ); - //force from address if checked - if(isset($options['force_from_address']) && !empty($options['force_from_address'])){ - $from_name = $options['from_name']; - $from_email = $options['from_email']; - } - try { - $phpmailer->setFrom( $from_email, $from_name, false ); - } catch ( PHPMailer\PHPMailer\Exception $e ) { - $mail_error_data = compact( 'to', 'subject', 'message', 'headers', 'attachments' ); - $mail_error_data['phpmailer_exception_code'] = $e->getCode(); - - /** This filter is documented in wp-includes/pluggable.php */ - do_action( 'wp_mail_failed', new WP_Error( 'wp_mail_failed', $e->getMessage(), $mail_error_data ) ); - - return false; - } - /*reply_to code */ - $smtpmailer_reply_to = ''; - $smtpmailer_reply_to = apply_filters('smtpmailer_reply_to', $smtpmailer_reply_to); - if(isset($smtpmailer_reply_to) && !empty($smtpmailer_reply_to)){ - $temp_reply_to_addresses = explode(",", $smtpmailer_reply_to); - $reply_to = array(); - foreach($temp_reply_to_addresses as $temp_reply_to_address){ - $reply_to_address = trim($temp_reply_to_address); - $reply_to[] = $reply_to_address; - } - } - /*end of reply_to code */ - // Set mail's subject and body. - $phpmailer->Subject = $subject; - $phpmailer->Body = $message; - - // Set destination addresses, using appropriate methods for handling addresses. - $address_headers = compact( 'to', 'cc', 'bcc', 'reply_to' ); - - foreach ( $address_headers as $address_header => $addresses ) { - if ( empty( $addresses ) ) { - continue; - } - - foreach ( (array) $addresses as $address ) { - try { - // Break $recipient into name and address parts if in the format "Foo ". - $recipient_name = ''; - - if ( preg_match( '/(.*)<(.+)>/', $address, $matches ) ) { - if ( count( $matches ) === 3 ) { - $recipient_name = $matches[1]; - $address = $matches[2]; - } - } - - switch ( $address_header ) { - case 'to': - $phpmailer->addAddress( $address, $recipient_name ); - break; - case 'cc': - $phpmailer->addCc( $address, $recipient_name ); - break; - case 'bcc': - $phpmailer->addBcc( $address, $recipient_name ); - break; - case 'reply_to': - $phpmailer->addReplyTo( $address, $recipient_name ); - break; - } - } catch ( PHPMailer\PHPMailer\Exception $e ) { - continue; - } - } - } - - // Tell PHPMailer to use SMTP - $phpmailer->isSMTP(); //$phpmailer->isMail(); - // Set the hostname of the mail server - $phpmailer->Host = $options['smtp_host']; - // Whether to use SMTP authentication - if(isset($options['smtp_auth']) && $options['smtp_auth'] == "true"){ - $phpmailer->SMTPAuth = true; - // SMTP username - $phpmailer->Username = $options['smtp_username']; - // SMTP password - $phpmailer->Password = base64_decode($options['smtp_password']); - } - // Whether to use encryption - $type_of_encryption = $options['type_of_encryption']; - if($type_of_encryption=="none"){ - $type_of_encryption = ''; - } - $phpmailer->SMTPSecure = $type_of_encryption; - // SMTP port - $phpmailer->Port = $options['smtp_port']; - - // Whether to enable TLS encryption automatically if a server supports it - $phpmailer->SMTPAutoTLS = false; - //enable debug when sending a test mail - if(isset($_POST['smtp_mailer_send_test_email'])){ - $phpmailer->SMTPDebug = 4; - // Ask for HTML-friendly debug output - $phpmailer->Debugoutput = 'html'; - } - - //disable ssl certificate verification if checked - if(isset($options['disable_ssl_verification']) && !empty($options['disable_ssl_verification'])){ - $phpmailer->SMTPOptions = array( - 'ssl' => array( - 'verify_peer' => false, - 'verify_peer_name' => false, - 'allow_self_signed' => true - ) - ); - } - // Set Content-Type and charset. - - // If we don't have a Content-Type from the input headers. - if ( ! isset( $content_type ) ) { - $content_type = 'text/plain'; - } - - /** - * Filters the wp_mail() content type. - * - * @since 2.3.0 - * - * @param string $content_type Default wp_mail() content type. - */ - $content_type = apply_filters( 'wp_mail_content_type', $content_type ); - - $phpmailer->ContentType = $content_type; - - // Set whether it's plaintext, depending on $content_type. - if ( 'text/html' === $content_type ) { - $phpmailer->isHTML( true ); - } - - // If we don't have a charset from the input headers. - if ( ! isset( $charset ) ) { - $charset = get_bloginfo( 'charset' ); - } - - /** - * Filters the default wp_mail() charset. - * - * @since 2.3.0 - * - * @param string $charset Default email charset. - */ - $phpmailer->CharSet = apply_filters( 'wp_mail_charset', $charset ); - - // Set custom headers. - if ( ! empty( $headers ) ) { - foreach ( (array) $headers as $name => $content ) { - // Only add custom headers not added automatically by PHPMailer. - if ( ! in_array( $name, array( 'MIME-Version', 'X-Mailer' ), true ) ) { - try { - $phpmailer->addCustomHeader( sprintf( '%1$s: %2$s', $name, $content ) ); - } catch ( PHPMailer\PHPMailer\Exception $e ) { - continue; - } - } - } - - if ( false !== stripos( $content_type, 'multipart' ) && ! empty( $boundary ) ) { - $phpmailer->addCustomHeader( sprintf( 'Content-Type: %s; boundary="%s"', $content_type, $boundary ) ); - } - } - - if ( isset( $attachments ) && ! empty( $attachments ) ) { - foreach ( $attachments as $filename => $attachment ) { - $filename = is_string( $filename ) ? $filename : ''; - - try { - $phpmailer->addAttachment( $attachment, $filename ); - } catch ( PHPMailer\PHPMailer\Exception $e ) { - continue; - } - } - } - - /** - * Fires after PHPMailer is initialized. - * - * @since 2.2.0 - * - * @param PHPMailer $phpmailer The PHPMailer instance (passed by reference). - */ - do_action_ref_array( 'phpmailer_init', array( &$phpmailer ) ); - - $mail_data = compact( 'to', 'subject', 'message', 'headers', 'attachments' ); - - // Send! - try { - $send = $phpmailer->send(); - - /** - * Fires after PHPMailer has successfully sent an email. - * - * The firing of this action does not necessarily mean that the recipient(s) received the - * email successfully. It only means that the `send` method above was able to - * process the request without any errors. - * - * @since 5.9.0 - * - * @param array $mail_data { - * An array containing the email recipient(s), subject, message, headers, and attachments. - * - * @type string[] $to Email addresses to send message. - * @type string $subject Email subject. - * @type string $message Message contents. - * @type string[] $headers Additional headers. - * @type string[] $attachments Paths to files to attach. - * } - */ - do_action( 'wp_mail_succeeded', $mail_data ); - - return $send; - } catch ( PHPMailer\PHPMailer\Exception $e ) { - $mail_data['phpmailer_exception_code'] = $e->getCode(); - - /** - * Fires after a PHPMailer\PHPMailer\Exception is caught. - * - * @since 4.4.0 - * - * @param WP_Error $error A WP_Error object with the PHPMailer\PHPMailer\Exception message, and an array - * containing the mail recipient, subject, message, headers, and attachments. - */ - do_action( 'wp_mail_failed', new WP_Error( 'wp_mail_failed', $e->getMessage(), $mail_data ) ); - - return false; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/smtp-mailer/readme.txt b/wp-content/upgrade-temp-backup/plugins/smtp-mailer/readme.txt deleted file mode 100644 index b507150a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/smtp-mailer/readme.txt +++ /dev/null @@ -1,160 +0,0 @@ -=== SMTP Mailer === -Contributors: naa986 -Donate link: https://wphowto.net/ -Tags: email, mail, smtp, phpmailer -Requires at least: 6.8 -Tested up to: 6.8 -Stable tag: 1.1.18 -License: GPLv2 or later -License URI: https://www.gnu.org/licenses/gpl-2.0.html - -Configure a SMTP server to send email from your WordPress site. Configure the wp_mail() function to use SMTP instead of the PHP mail() function. - -== Description == - -[SMTP Mailer](https://wphowto.net/smtp-mailer-plugin-for-wordpress-1482) plugin allows you to configure a mail server which handles all outgoing email from your website. It takes control of the wp_mail function and use SMTP instead. - -https://www.youtube.com/watch?v=7O_jgtykcEk&rel=0 - -=== SMTP Mailer Add-ons === - -* [Reply-To](https://wphowto.net/how-to-add-a-reply-to-address-in-the-smtp-mailer-wordpress-plugin-6997) -* [Email Logger](https://wphowto.net/smtp-mailer-email-logger-7066) - -=== SMTP Mailer Settings === - -* **SMTP Host**: Your outgoing mail server (e.g. smtp.gmail.com). -* **SMTP Authentication**: Whether to use SMTP authentication when sending an email (True/False). If you choose to authenticate you will also need to provide your username and password. -* **SMTP Username**: The username to connect to your SMTP server. -* **SMTP Password**: The password to connect to your SMTP server. -* **Type of Encryption**: The encryption to be used when sending an email (TLS/SSL/No Encryption. TLS is recommended). -* **SMTP Port**: The port to be used when sending an email (587/465/25). If you choose TLS the port should be set to 587. For SSL use port 465 instead. -* **From Email Address**: The email address to be used as the From Address when sending an email. -* **From Name**: The name to be used as the From Name when sending an email. - -=== SMTP Mailer Test Email === - -Once you have configured the settings you can send a test email to check the functionality of the plugin. - -* **To**: Email address of the recipient. -* **Subject**: Subject of the email. -* **Message**: Email body. - -=== Known Compatibility === - -SMTP Mailer should work with any plugin that uses the WordPress Mail function. However, It has been tested with the following form and contact form plugins: - -* Contact Form 7 -* Jetpack Contact Form -* Visual Form Builder -* Fast Secure Contact Form -* Formidable Forms -* Contact Form by BestWebSoft - -For detailed setup instructions please visit the [SMTP Mailer](https://wphowto.net/smtp-mailer-plugin-for-wordpress-1482) plugin page. - -== Installation == - -1. Go to the Add New plugins screen in your WordPress Dashboard -1. Click the upload tab -1. Browse for the plugin file (smtp-mailer.zip) on your computer -1. Click "Install Now" and then hit the activate button - -== Frequently Asked Questions == -none - -== Screenshots == - -1. SMTP Mailer Settings -2. SMTP Mailer Test Email Tab - -== Upgrade Notice == -none - -== Changelog == - -= 1.1.18 = -* WordPress 6.8 compatibility update. - -= 1.1.17 = -* WordPress 6.7 compatibility update. - -= 1.1.16 = -* Removed php_uname from server info. - -= 1.1.15 = -* Updated the code for sanitizing password. - -= 1.1.14 = -* Added support for the email logger add-on. - -= 1.1.13 = -* WordPress 6.5 compatibility update. - -= 1.1.12 = -* Added support for the reply-to add-on. - -= 1.1.11 = -* WordPress 6.4 compatibility update. - -= 1.1.10 = -* Added an option to set the configured from address for all outgoing email messages. - -= 1.1.9 = -* Additional check for the settings link. - -= 1.1.8 = -* Removed admin notices to avoid confusion since configurations can vary on different servers. - -= 1.1.7 = -* WordPress 6.3 compatibility update. - -= 1.1.6 = -* WordPress 6.2 compatibility update. - -= 1.1.5 = -* Compatibility update for WordPress 6.1. - -= 1.1.4 = -* Updated the mail function for WordPress 6.0. - -= 1.1.3 = -* Updated the mail function for WordPress 5.9. - -= 1.1.2 = -* Fixed an issue that could cause an Undefined variable error if $attachments was not set. - -= 1.1.1 = -* WordPress 5.7 compatibility update. - -= 1.1.0 = -* The password field can be left empty when updating the settings. - -= 1.0.9 = -* Updated the code to be compatible with WordPress 5.5. - -= 1.0.8 = -* SMTP Mailer is compatible with WordPress 5.3. - -= 1.0.7 = -* SMTP Mailer now checks for a valid nonce when sending a test email. - -= 1.0.6 = -* SMTP Mailer no longer shows the saved password in the settings. - -= 1.0.5 = -* SMTP Mailer is now compatible with WordPress 4.9. - -= 1.0.4 = -* Updated the mail() function by setting its minimum requirements to WordPress 4.8. -* "phpmailer_init" action hook is now enabled so it can be used by other plugins. - -= 1.0.3 = -* Fixed a bug where an apostrophe in the password would cause SMTP authentication failure. - -= 1.0.2 = -* SMTP Mailer now supports the "wp_mail_failed" hook which fires after a phpmailerException is caught. -* Added a new option to bypass this error on some servers where the SSL certificate is not properly configured - Warning: stream_socket_enable_crypto(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed. - -= 1.0.1 = -* First commit diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/LICENSE.md b/wp-content/upgrade-temp-backup/plugins/two-factor/LICENSE.md deleted file mode 100644 index d8cf7d46..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/LICENSE.md +++ /dev/null @@ -1,280 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 2, June 1991 - - Copyright (C) 1989, 1991 Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The licenses for most software are designed to take away your -freedom to share and change it. By contrast, the GNU General Public -License is intended to guarantee your freedom to share and change free -software--to make sure the software is free for all its users. This -General Public License applies to most of the Free Software -Foundation's software and to any other program whose authors commit to -using it. (Some other Free Software Foundation software is covered by -the GNU Lesser General Public License instead.) You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -this service if you wish), that you receive source code or can get it -if you want it, that you can change the software or use pieces of it -in new free programs; and that you know you can do these things. - - To protect your rights, we need to make restrictions that forbid -anyone to deny you these rights or to ask you to surrender the rights. -These restrictions translate to certain responsibilities for you if you -distribute copies of the software, or if you modify it. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must give the recipients all the rights that -you have. You must make sure that they, too, receive or can get the -source code. And you must show them these terms so they know their -rights. - - We protect your rights with two steps: (1) copyright the software, and -(2) offer you this license which gives you legal permission to copy, -distribute and/or modify the software. - - Also, for each author's protection and ours, we want to make certain -that everyone understands that there is no warranty for this free -software. If the software is modified by someone else and passed on, we -want its recipients to know that what they have is not the original, so -that any problems introduced by others will not reflect on the original -authors' reputations. - - Finally, any free program is threatened constantly by software -patents. We wish to avoid the danger that redistributors of a free -program will individually obtain patent licenses, in effect making the -program proprietary. To prevent this, we have made it clear that any -patent must be licensed for everyone's free use or not licensed at all. - - The precise terms and conditions for copying, distribution and -modification follow. - - GNU GENERAL PUBLIC LICENSE - TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION - - 0. This License applies to any program or other work which contains -a notice placed by the copyright holder saying it may be distributed -under the terms of this General Public License. The "Program", below, -refers to any such program or work, and a "work based on the Program" -means either the Program or any derivative work under copyright law: -that is to say, a work containing the Program or a portion of it, -either verbatim or with modifications and/or translated into another -language. (Hereinafter, translation is included without limitation in -the term "modification".) Each licensee is addressed as "you". - -Activities other than copying, distribution and modification are not -covered by this License; they are outside its scope. The act of -running the Program is not restricted, and the output from the Program -is covered only if its contents constitute a work based on the -Program (independent of having been made by running the Program). -Whether that is true depends on what the Program does. - - 1. You may copy and distribute verbatim copies of the Program's -source code as you receive it, in any medium, provided that you -conspicuously and appropriately publish on each copy an appropriate -copyright notice and disclaimer of warranty; keep intact all the -notices that refer to this License and to the absence of any warranty; -and give any other recipients of the Program a copy of this License -along with the Program. - -You may charge a fee for the physical act of transferring a copy, and -you may at your option offer warranty protection in exchange for a fee. - - 2. You may modify your copy or copies of the Program or any portion -of it, thus forming a work based on the Program, and copy and -distribute such modifications or work under the terms of Section 1 -above, provided that you also meet all of these conditions: - - a) You must cause the modified files to carry prominent notices - stating that you changed the files and the date of any change. - - b) You must cause any work that you distribute or publish, that in - whole or in part contains or is derived from the Program or any - part thereof, to be licensed as a whole at no charge to all third - parties under the terms of this License. - - c) If the modified program normally reads commands interactively - when run, you must cause it, when started running for such - interactive use in the most ordinary way, to print or display an - announcement including an appropriate copyright notice and a - notice that there is no warranty (or else, saying that you provide - a warranty) and that users may redistribute the program under - these conditions, and telling the user how to view a copy of this - License. (Exception: if the Program itself is interactive but - does not normally print such an announcement, your work based on - the Program is not required to print an announcement.) - -These requirements apply to the modified work as a whole. If -identifiable sections of that work are not derived from the Program, -and can be reasonably considered independent and separate works in -themselves, then this License, and its terms, do not apply to those -sections when you distribute them as separate works. But when you -distribute the same sections as part of a whole which is a work based -on the Program, the distribution of the whole must be on the terms of -this License, whose permissions for other licensees extend to the -entire whole, and thus to each and every part regardless of who wrote it. - -Thus, it is not the intent of this section to claim rights or contest -your rights to work written entirely by you; rather, the intent is to -exercise the right to control the distribution of derivative or -collective works based on the Program. - -In addition, mere aggregation of another work not based on the Program -with the Program (or with a work based on the Program) on a volume of -a storage or distribution medium does not bring the other work under -the scope of this License. - - 3. You may copy and distribute the Program (or a work based on it, -under Section 2) in object code or executable form under the terms of -Sections 1 and 2 above provided that you also do one of the following: - - a) Accompany it with the complete corresponding machine-readable - source code, which must be distributed under the terms of Sections - 1 and 2 above on a medium customarily used for software interchange; or, - - b) Accompany it with a written offer, valid for at least three - years, to give any third party, for a charge no more than your - cost of physically performing source distribution, a complete - machine-readable copy of the corresponding source code, to be - distributed under the terms of Sections 1 and 2 above on a medium - customarily used for software interchange; or, - - c) Accompany it with the information you received as to the offer - to distribute corresponding source code. (This alternative is - allowed only for noncommercial distribution and only if you - received the program in object code or executable form with such - an offer, in accord with Subsection b above.) - -The source code for a work means the preferred form of the work for -making modifications to it. For an executable work, complete source -code means all the source code for all modules it contains, plus any -associated interface definition files, plus the scripts used to -control compilation and installation of the executable. However, as a -special exception, the source code distributed need not include -anything that is normally distributed (in either source or binary -form) with the major components (compiler, kernel, and so on) of the -operating system on which the executable runs, unless that component -itself accompanies the executable. - -If distribution of executable or object code is made by offering -access to copy from a designated place, then offering equivalent -access to copy the source code from the same place counts as -distribution of the source code, even though third parties are not -compelled to copy the source along with the object code. - - 4. You may not copy, modify, sublicense, or distribute the Program -except as expressly provided under this License. Any attempt -otherwise to copy, modify, sublicense or distribute the Program is -void, and will automatically terminate your rights under this License. -However, parties who have received copies, or rights, from you under -this License will not have their licenses terminated so long as such -parties remain in full compliance. - - 5. You are not required to accept this License, since you have not -signed it. However, nothing else grants you permission to modify or -distribute the Program or its derivative works. These actions are -prohibited by law if you do not accept this License. Therefore, by -modifying or distributing the Program (or any work based on the -Program), you indicate your acceptance of this License to do so, and -all its terms and conditions for copying, distributing or modifying -the Program or works based on it. - - 6. Each time you redistribute the Program (or any work based on the -Program), the recipient automatically receives a license from the -original licensor to copy, distribute or modify the Program subject to -these terms and conditions. You may not impose any further -restrictions on the recipients' exercise of the rights granted herein. -You are not responsible for enforcing compliance by third parties to -this License. - - 7. If, as a consequence of a court judgment or allegation of patent -infringement or for any other reason (not limited to patent issues), -conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot -distribute so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you -may not distribute the Program at all. For example, if a patent -license would not permit royalty-free redistribution of the Program by -all those who receive copies directly or indirectly through you, then -the only way you could satisfy both it and this License would be to -refrain entirely from distribution of the Program. - -If any portion of this section is held invalid or unenforceable under -any particular circumstance, the balance of the section is intended to -apply and the section as a whole is intended to apply in other -circumstances. - -It is not the purpose of this section to induce you to infringe any -patents or other property right claims or to contest validity of any -such claims; this section has the sole purpose of protecting the -integrity of the free software distribution system, which is -implemented by public license practices. Many people have made -generous contributions to the wide range of software distributed -through that system in reliance on consistent application of that -system; it is up to the author/donor to decide if he or she is willing -to distribute software through any other system and a licensee cannot -impose that choice. - -This section is intended to make thoroughly clear what is believed to -be a consequence of the rest of this License. - - 8. If the distribution and/or use of the Program is restricted in -certain countries either by patents or by copyrighted interfaces, the -original copyright holder who places the Program under this License -may add an explicit geographical distribution limitation excluding -those countries, so that distribution is permitted only in or among -countries not thus excluded. In such case, this License incorporates -the limitation as if written in the body of this License. - - 9. The Free Software Foundation may publish revised and/or new versions -of the General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - -Each version is given a distinguishing version number. If the Program -specifies a version number of this License which applies to it and "any -later version", you have the option of following the terms and conditions -either of that version or of any later version published by the Free -Software Foundation. If the Program does not specify a version number of -this License, you may choose any version ever published by the Free Software -Foundation. - - 10. If you wish to incorporate parts of the Program into other free -programs whose distribution conditions are different, write to the author -to ask for permission. For software which is copyrighted by the Free -Software Foundation, write to the Free Software Foundation; we sometimes -make exceptions for this. Our decision will be guided by the two goals -of preserving the free status of all derivatives of our free software and -of promoting the sharing and reuse of software generally. - - NO WARRANTY - - 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY -FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN -OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES -PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED -OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF -MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS -TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE -PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, -REPAIR OR CORRECTION. - - 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR -REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, -INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING -OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED -TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY -YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER -PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE -POSSIBILITY OF SUCH DAMAGES. - - END OF TERMS AND CONDITIONS diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/banner-1544x500.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/banner-1544x500.png deleted file mode 100644 index 5b6e2081..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/banner-1544x500.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/banner-772x250.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/banner-772x250.png deleted file mode 100644 index b955eeeb..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/banner-772x250.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon-128x128.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon-128x128.png deleted file mode 100644 index 1f3a3c31..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon-128x128.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon-256x256.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon-256x256.png deleted file mode 100644 index 3240b832..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon-256x256.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon.svg b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon.svg deleted file mode 100644 index cc15690b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/icon.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-1.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-1.png deleted file mode 100644 index 001fb2ae..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-1.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-2.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-2.png deleted file mode 100644 index 9fb4f742..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-2.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-3.png b/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-3.png deleted file mode 100644 index b866bbb0..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/two-factor/assets/screenshot-3.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/class-two-factor-compat.php b/wp-content/upgrade-temp-backup/plugins/two-factor/class-two-factor-compat.php deleted file mode 100644 index d7b4f46a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/class-two-factor-compat.php +++ /dev/null @@ -1,55 +0,0 @@ - 'sanitize_key' ) ); - - if ( 'jetpack-sso' === $action && $this->jetpack_is_sso_active() ) { - return true; - } - - return $rememberme; - } - - /** - * Helper to detect the presence of the active SSO module. - * - * @return boolean - */ - public function jetpack_is_sso_active() { - return ( class_exists( 'Jetpack' ) && method_exists( 'Jetpack', 'is_module_active' ) && Jetpack::is_module_active( 'sso' ) ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/class-two-factor-core.php b/wp-content/upgrade-temp-backup/plugins/two-factor/class-two-factor-core.php deleted file mode 100644 index 5eaa765a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/class-two-factor-core.php +++ /dev/null @@ -1,2193 +0,0 @@ -init(); - } - - /** - * Delete all plugin data on uninstall. - * - * @return void - */ - public static function uninstall() { - // Keep this updated as user meta keys are added or removed. - $user_meta_keys = array( - self::PROVIDER_USER_META_KEY, - self::ENABLED_PROVIDERS_USER_META_KEY, - self::USER_META_NONCE_KEY, - self::USER_RATE_LIMIT_KEY, - self::USER_FAILED_LOGIN_ATTEMPTS_KEY, - self::USER_PASSWORD_WAS_RESET_KEY, - ); - - $option_keys = array(); - - $providers = self::get_default_providers(); - - /** This filter is documented in the get_providers() method */ - $additional_providers = apply_filters( 'two_factor_providers', $providers ); - - // Merge them with the default providers. - if ( ! empty( $additional_providers ) ) { - $providers = array_merge( $providers, $additional_providers ); - } - - foreach ( self::get_providers_classes( $providers ) as $provider_class ) { - // Merge with provider-specific user meta keys. - if ( method_exists( $provider_class, 'uninstall_user_meta_keys' ) ) { - try { - $user_meta_keys = array_merge( - $user_meta_keys, - call_user_func( array( $provider_class, 'uninstall_user_meta_keys' ) ) - ); - } catch ( Exception $e ) { - // Do nothing. - } - } - - // Merge with provider-specific option keys. - if ( method_exists( $provider_class, 'uninstall_options' ) ) { - try { - $option_keys = array_merge( - $option_keys, - call_user_func( array( $provider_class, 'uninstall_options' ) ) - ); - } catch ( Exception $e ) { - // Do nothing. - } - } - } - - // Delete options first since that is faster. - if ( ! empty( $option_keys ) ) { - foreach ( $option_keys as $option_key ) { - delete_option( $option_key ); - } - } - - foreach ( $user_meta_keys as $meta_key ) { - delete_metadata( 'user', null, $meta_key, null, true ); - } - } - - /** - * Get the registered providers of which some might not be enabled. - * - * @return array List of provider keys and paths to class files. - */ - private static function get_default_providers() { - return array( - 'Two_Factor_Email' => TWO_FACTOR_DIR . 'providers/class-two-factor-email.php', - 'Two_Factor_Totp' => TWO_FACTOR_DIR . 'providers/class-two-factor-totp.php', - 'Two_Factor_FIDO_U2F' => TWO_FACTOR_DIR . 'providers/class-two-factor-fido-u2f.php', - 'Two_Factor_Backup_Codes' => TWO_FACTOR_DIR . 'providers/class-two-factor-backup-codes.php', - 'Two_Factor_Dummy' => TWO_FACTOR_DIR . 'providers/class-two-factor-dummy.php', - ); - } - - /** - * Get the classnames for specific providers. - * - * @param array $providers List of paths to provider class files indexed by class names. - * - * @return array List of provider keys and classnames. - */ - private static function get_providers_classes( $providers ) { - foreach ( $providers as $provider_key => $path ) { - if ( ! empty( $path ) && is_readable( $path ) ) { - require_once $path; - } - - $class = $provider_key; - - /** - * Filters the classname for a provider. The dynamic portion of the filter is the defined providers key. - * - * @param string $class The PHP Classname of the provider. - * @param string $path The provided provider path to be included. - */ - $class = apply_filters( "two_factor_provider_classname_{$provider_key}", $class, $path ); - - /** - * Confirm that it's been successfully included. - */ - if ( class_exists( $class ) ) { - $providers[ $provider_key ] = $class; - } else { - unset( $providers[ $provider_key ] ); - } - } - - return $providers; - } - - /** - * Get all registered two-factor providers with keys as the original - * provider class names and the values as the provider class instances. - * - * @see Two_Factor_Core::get_enabled_providers_for_user() - * @see Two_Factor_Core::get_supported_providers_for_user() - * - * @since 0.1-dev - * - * @return array - */ - public static function get_providers() { - $providers = self::get_default_providers(); - - /** - * Filter the supplied providers. - * - * This lets third-parties either remove providers (such as Email), or - * add their own providers (such as text message or Clef). - * - * @param array $providers A key-value array where the key is the class name, and - * the value is the path to the file containing the class. - */ - $providers = apply_filters( 'two_factor_providers', $providers ); - - // FIDO U2F is PHP 5.3+ only. - if ( isset( $providers['Two_Factor_FIDO_U2F'] ) && version_compare( PHP_VERSION, '5.3.0', '<' ) ) { - unset( $providers['Two_Factor_FIDO_U2F'] ); - trigger_error( // phpcs:ignore WordPress.PHP.DevelopmentFunctions.error_log_trigger_error - sprintf( - /* translators: %s: version number */ - __( 'FIDO U2F is not available because you are using PHP %s. (Requires 5.3 or greater)', 'two-factor' ), // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped - PHP_VERSION - ) - ); - } - - // Map provider keys to classes so that we can instantiate them. - $providers = self::get_providers_classes( $providers ); - - // TODO: Refactor this to avoid instantiating the provider instances every time this method is called. - foreach ( $providers as $provider_key => $provider_class ) { - try { - $providers[ $provider_key ] = call_user_func( array( $provider_class, 'get_instance' ) ); - } catch ( Exception $e ) { - unset( $providers[ $provider_key ] ); - } - } - - return $providers; - } - - /** - * Get providers available for user which may not be enabled or configured. - * - * @see Two_Factor_Core::get_enabled_providers_for_user() - * @see Two_Factor_Core::get_available_providers_for_user() - * - * @param WP_User|int|null $user User ID. - * @return array List of provider instances indexed by provider key. - */ - public static function get_supported_providers_for_user( $user = null ) { - $user = self::fetch_user( $user ); - $providers = self::get_providers(); - - /** - * List of providers available to user which may not be enabled or configured. - * - * @param array $providers List of available provider instances indexed by provider key. - * @param int|WP_User $user User ID. - */ - return apply_filters( 'two_factor_providers_for_user', $providers, $user ); - } - - /** - * Enable the dummy method only during debugging. - * - * @param array $methods List of enabled methods. - * - * @return array - */ - public static function enable_dummy_method_for_debug( $methods ) { - if ( ! self::is_wp_debug() ) { - unset( $methods['Two_Factor_Dummy'] ); - } - - return $methods; - } - - /** - * Check if the debug mode is enabled. - * - * @return boolean - */ - protected static function is_wp_debug() { - return ( defined( 'WP_DEBUG' ) && WP_DEBUG ); - } - - /** - * Get the user settings page URL. - * - * Fetch this from the plugin core after we introduce proper dependency injection - * and get away from the singletons at the provider level (should be handled by core). - * - * @param integer $user_id User ID. - * - * @return string - */ - protected static function get_user_settings_page_url( $user_id ) { - if ( defined( 'IS_PROFILE_PAGE' ) && IS_PROFILE_PAGE ) { - return self_admin_url( 'profile.php' ); - } - - return add_query_arg( - array( - 'user_id' => intval( $user_id ), - ), - self_admin_url( 'user-edit.php' ) - ); - } - - /** - * Get the URL for resetting the secret token. - * - * @param integer $user_id User ID. - * @param string $action Custom two factor action key. - * - * @return string - */ - public static function get_user_update_action_url( $user_id, $action ) { - return wp_nonce_url( - add_query_arg( - array( - self::USER_SETTINGS_ACTION_QUERY_VAR => $action, - ), - self::get_user_settings_page_url( $user_id ) - ), - sprintf( '%d-%s', $user_id, $action ), - self::USER_SETTINGS_ACTION_NONCE_QUERY_ARG - ); - } - - /** - * Get the two-factor revalidate URL. - * - * @param bool $interim If the URL should load the interim login iframe modal. - * @return string - */ - public static function get_user_two_factor_revalidate_url( $interim = false ) { - $args = array( - 'action' => 'revalidate_2fa', - ); - if ( $interim ) { - $args['interim-login'] = 1; - } - - return self::login_url( $args ); - } - - /** - * Check if a user action is valid. - * - * @param integer $user_id User ID. - * @param string $action User action ID. - * - * @return boolean - */ - public static function is_valid_user_action( $user_id, $action ) { - $request_nonce = isset( $_REQUEST[ self::USER_SETTINGS_ACTION_NONCE_QUERY_ARG ] ) ? wp_unslash( $_REQUEST[ self::USER_SETTINGS_ACTION_NONCE_QUERY_ARG ] ) : ''; - - if ( ! $user_id || ! $action || ! $request_nonce ) { - return false; - } - - return wp_verify_nonce( - $request_nonce, - sprintf( '%d-%s', $user_id, $action ) - ); - } - - /** - * Get the ID of the user being edited. - * - * @return integer - */ - public static function current_user_being_edited() { - // Try to resolve the user ID from the request first. - if ( ! empty( $_REQUEST['user_id'] ) ) { - $user_id = intval( $_REQUEST['user_id'] ); - - if ( current_user_can( 'edit_user', $user_id ) ) { - return $user_id; - } - } - - return get_current_user_id(); - } - - /** - * Trigger our custom update action if a valid - * action request is detected and passes the nonce check. - * - * @return void - */ - public static function trigger_user_settings_action() { - $action = isset( $_REQUEST[ self::USER_SETTINGS_ACTION_QUERY_VAR ] ) ? wp_unslash( $_REQUEST[ self::USER_SETTINGS_ACTION_QUERY_VAR ] ) : ''; - $user_id = self::current_user_being_edited(); - - if ( self::is_valid_user_action( $user_id, $action ) ) { - /** - * This action is triggered when a valid Two Factor settings - * action is detected and it passes the nonce validation. - * - * @param integer $user_id User ID. - * @param string $action Settings action. - */ - do_action( 'two_factor_user_settings_action', $user_id, $action ); - } - } - - /** - * Keep track of all the authentication cookies that need to be - * invalidated before the second factor authentication. - * - * @param string $cookie Cookie string. - * - * @return void - */ - public static function collect_auth_cookie_tokens( $cookie ) { - $parsed = wp_parse_auth_cookie( $cookie ); - - if ( ! empty( $parsed['token'] ) ) { - self::$password_auth_tokens[] = $parsed['token']; - } - } - - /** - * Fetch the WP_User object for a provided input. - * - * @since 0.8.0 - * - * @param int|WP_User $user Optional. The WP_User or user ID. Defaults to current user. - * - * @return false|WP_User WP_User on success, false on failure. - */ - public static function fetch_user( $user = null ) { - if ( null === $user ) { - $user = wp_get_current_user(); - } elseif ( ! ( $user instanceof WP_User ) ) { - $user = get_user_by( 'id', $user ); - } - - if ( ! $user || ! $user->exists() ) { - return false; - } - - return $user; - } - - /** - * Get two-factor providers that are enabled for the specified (or current) user - * but might not be configured, yet. - * - * @see Two_Factor_Core::get_supported_providers_for_user() - * @see Two_Factor_Core::get_available_providers_for_user() - * - * @param int|WP_User $user Optional. User ID, or WP_User object of the the user. Defaults to current user. - * @return array - */ - public static function get_enabled_providers_for_user( $user = null ) { - $user = self::fetch_user( $user ); - if ( ! $user ) { - return array(); - } - - $providers = self::get_supported_providers_for_user( $user ); - $enabled_providers = get_user_meta( $user->ID, self::ENABLED_PROVIDERS_USER_META_KEY, true ); - if ( empty( $enabled_providers ) ) { - $enabled_providers = array(); - } - $enabled_providers = array_intersect( $enabled_providers, array_keys( $providers ) ); - - /** - * Filter the enabled two-factor authentication providers for this user. - * - * @param array $enabled_providers The enabled providers. - * @param int $user_id The user ID. - */ - return apply_filters( 'two_factor_enabled_providers_for_user', $enabled_providers, $user->ID ); - } - - /** - * Get all two-factor providers that are both enabled and configured - * for the specified (or current) user. - * - * @see Two_Factor_Core::get_supported_providers_for_user() - * @see Two_Factor_Core::get_enabled_providers_for_user() - * - * @param int|WP_User $user Optional. User ID, or WP_User object of the the user. Defaults to current user. - * @return array List of provider instances. - */ - public static function get_available_providers_for_user( $user = null ) { - $user = self::fetch_user( $user ); - if ( ! $user ) { - return array(); - } - - $providers = self::get_supported_providers_for_user( $user ); // Returns full objects. - $enabled_providers = self::get_enabled_providers_for_user( $user ); // Returns just the keys. - $configured_providers = array(); - - foreach ( $providers as $provider_key => $provider ) { - if ( in_array( $provider_key, $enabled_providers, true ) && $provider->is_available_for_user( $user ) ) { - $configured_providers[ $provider_key ] = $provider; - } - } - - return $configured_providers; - } - - /** - * Fetch the provider for the request based on the user preferences. - * - * @param int|WP_User $user Optional. User ID, or WP_User object of the the user. Defaults to current user. - * @param null|string|object $preferred_provider Optional. The name of the provider, the provider, or empty. - * @return null|object The provider - */ - public static function get_provider_for_user( $user = null, $preferred_provider = null ) { - $user = self::fetch_user( $user ); - if ( ! $user ) { - return null; - } - - // If a specific provider instance is passed, process it just as the key. - if ( $preferred_provider && $preferred_provider instanceof Two_Factor_Provider ) { - $preferred_provider = $preferred_provider->get_key(); - } - - // Default to the currently logged in provider. - if ( ! $preferred_provider && get_current_user_id() === $user->ID ) { - $session = self::get_current_user_session(); - if ( ! empty( $session['two-factor-provider'] ) ) { - $preferred_provider = $session['two-factor-provider']; - } - } - - if ( is_string( $preferred_provider ) ) { - $providers = self::get_available_providers_for_user( $user ); - if ( isset( $providers[ $preferred_provider ] ) ) { - return $providers[ $preferred_provider ]; - } - } - - return self::get_primary_provider_for_user( $user ); - } - - /** - * Get the name of the primary provider selected by the user - * and enabled for the user. - * - * @param WP_User|int $user User ID or instance. - * - * @return string|null - */ - private static function get_primary_provider_key_selected_for_user( $user ) { - $primary_provider = get_user_meta( $user->ID, self::PROVIDER_USER_META_KEY, true ); - $available_providers = self::get_available_providers_for_user( $user ); - - if ( ! empty( $primary_provider ) && ! empty( $available_providers[ $primary_provider ] ) ) { - return $primary_provider; - } - - return null; - } - - /** - * Gets the Two-Factor Auth provider for the specified|current user. - * - * @since 0.1-dev - * - * @param int|WP_User $user Optional. User ID, or WP_User object of the the user. Defaults to current user. - * @return object|null - */ - public static function get_primary_provider_for_user( $user = null ) { - $user = self::fetch_user( $user ); - if ( ! $user ) { - return null; - } - - $providers = self::get_supported_providers_for_user( $user ); - $available_providers = self::get_available_providers_for_user( $user ); - - // If there's only one available provider, force that to be the primary. - if ( empty( $available_providers ) ) { - return null; - } elseif ( 1 === count( $available_providers ) ) { - $provider = key( $available_providers ); - } else { - $provider = self::get_primary_provider_key_selected_for_user( $user ); - - // If the provider specified isn't enabled, just grab the first one that is. - if ( ! isset( $available_providers[ $provider ] ) ) { - $provider = key( $available_providers ); - } - } - - /** - * Filter the two-factor authentication provider used for this user. - * - * @param string $provider The provider currently being used. - * @param int $user_id The user ID. - */ - $provider = apply_filters( 'two_factor_primary_provider_for_user', $provider, $user->ID ); - - if ( isset( $providers[ $provider ] ) ) { - return $providers[ $provider ]; - } - - return null; - } - - /** - * Quick boolean check for whether a given user is using two-step. - * - * @since 0.1-dev - * - * @param int|WP_User $user Optional. User ID, or WP_User object of the the user. Defaults to current user. - * @return bool - */ - public static function is_user_using_two_factor( $user = null ) { - $provider = self::get_primary_provider_for_user( $user ); - return ! empty( $provider ); - } - - /** - * Handle the browser-based login. - * - * @since 0.1-dev - * - * @param string $user_login Username. - * @param WP_User $user WP_User object of the logged-in user. - */ - public static function wp_login( $user_login, $user ) { - if ( ! self::is_user_using_two_factor( $user->ID ) ) { - return; - } - - // Invalidate the current login session to prevent from being re-used. - self::destroy_current_session_for_user( $user ); - - // Also clear the cookies which are no longer valid. - wp_clear_auth_cookie(); - - self::show_two_factor_login( $user ); - exit; - } - - /** - * Destroy the known password-based authentication sessions for the current user. - * - * Is there a better way of finding the current session token without - * having access to the authentication cookies which are just being set - * on the first password-based authentication request. - * - * @param \WP_User $user User object. - * - * @return void - */ - public static function destroy_current_session_for_user( $user ) { - $session_manager = WP_Session_Tokens::get_instance( $user->ID ); - - foreach ( self::$password_auth_tokens as $auth_token ) { - $session_manager->destroy( $auth_token ); - } - } - - /** - * Prevent login through XML-RPC and REST API for users with at least one - * two-factor method enabled. - * - * @param WP_User|WP_Error $user Valid WP_User only if the previous filters - * have verified and confirmed the - * authentication credentials. - * - * @return WP_User|WP_Error - */ - public static function filter_authenticate( $user ) { - if ( $user instanceof WP_User && self::is_api_request() && self::is_user_using_two_factor( $user->ID ) && ! self::is_user_api_login_enabled( $user->ID ) ) { - return new WP_Error( - 'invalid_application_credentials', - __( 'Error: API login for user disabled.', 'two-factor' ) - ); - } - - return $user; - } - - /** - * Prevent login cookies being set on login for Two Factor users. - * - * This makes it so that Core never sends the auth cookies. `login_form_validate_2fa()` will send them manually once the 2nd factor has been verified. - * - * @param WP_User|WP_Error $user Valid WP_User only if the previous filters - * have verified and confirmed the - * authentication credentials. - * - * @return WP_User|WP_Error - */ - public static function filter_authenticate_block_cookies( $user ) { - /* - * NOTE: The `login_init` action is checked for here to ensure we're within the regular login flow, - * rather than through an unsupported 3rd-party login process which this plugin doesn't support. - */ - if ( $user instanceof WP_User && self::is_user_using_two_factor( $user->ID ) && did_action( 'login_init' ) ) { - add_filter( 'send_auth_cookies', '__return_false', PHP_INT_MAX ); - } - - return $user; - } - - /** - * If the current user can login via API requests such as XML-RPC and REST. - * - * @param integer $user_id User ID. - * - * @return boolean - */ - public static function is_user_api_login_enabled( $user_id ) { - return (bool) apply_filters( 'two_factor_user_api_login_enable', false, $user_id ); - } - - /** - * Is the current request an XML-RPC or REST request. - * - * @return boolean - */ - public static function is_api_request() { - if ( defined( 'XMLRPC_REQUEST' ) && XMLRPC_REQUEST ) { - return true; - } - - if ( defined( 'REST_REQUEST' ) && REST_REQUEST ) { - return true; - } - - return false; - } - - /** - * Display the login form. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public static function show_two_factor_login( $user ) { - if ( ! $user ) { - $user = wp_get_current_user(); - } - - $login_nonce = self::create_login_nonce( $user->ID ); - if ( ! $login_nonce ) { - wp_die( esc_html__( 'Failed to create a login nonce.', 'two-factor' ) ); - } - - $redirect_to = isset( $_REQUEST['redirect_to'] ) ? $_REQUEST['redirect_to'] : admin_url(); - - self::login_html( $user, $login_nonce['key'], $redirect_to ); - } - - /** - * Displays a message informing the user that their account has had failed login attempts. - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public static function maybe_show_last_login_failure_notice( $user ) { - $last_failed_two_factor_login = (int) get_user_meta( $user->ID, self::USER_RATE_LIMIT_KEY, true ); - $failed_login_count = (int) get_user_meta( $user->ID, self::USER_FAILED_LOGIN_ATTEMPTS_KEY, true ); - - if ( $last_failed_two_factor_login ) { - echo '
            '; - printf( - _n( - 'WARNING: Your account has attempted to login without providing a valid two factor token. The last failed login occurred %2$s ago. If this wasn\'t you, you should reset your password.', - 'WARNING: Your account has attempted to login %1$s times without providing a valid two factor token. The last failed login occurred %2$s ago. If this wasn\'t you, you should reset your password.', - $failed_login_count, - 'two-factor' - ), - number_format_i18n( $failed_login_count ), - human_time_diff( $last_failed_two_factor_login, time() ) - ); - echo '
            '; - } - } - - /** - * Show the password reset notice if the user's password was reset. - * - * They were also sent an email notification in `send_password_reset_email()`, but email sent from a typical - * web server is not reliable enough to trust completely. - * - * @param WP_Error $errors - */ - public static function maybe_show_reset_password_notice( $errors ) { - if ( 'incorrect_password' !== $errors->get_error_code() ) { - return $errors; - } - - if ( ! isset( $_POST['log'] ) ) { - return $errors; - } - - $user_name = sanitize_user( wp_unslash( $_POST['log'] ) ); - $attempted_user = get_user_by( 'login', $user_name ); - if ( ! $attempted_user && str_contains( $user_name, '@' ) ) { - $attempted_user = get_user_by( 'email', $user_name ); - } - - if ( ! $attempted_user ) { - return $errors; - } - - $password_was_reset = get_user_meta( $attempted_user->ID, self::USER_PASSWORD_WAS_RESET_KEY, true ); - - if ( ! $password_was_reset ) { - return $errors; - } - - $errors->remove( 'incorrect_password' ); - $errors->add( - 'two_factor_password_reset', - sprintf( - __( 'Your password was reset because of too many failed Two Factor attempts. You will need to create a new password to regain access. Please check your email for more information.', 'two-factor' ), - esc_url( add_query_arg( 'action', 'lostpassword', wp_login_url() ) ) - ) - ); - - return $errors; - } - - /** - * Clear the password reset notice after the user resets their password. - * - * @param WP_User $user - */ - public static function clear_password_reset_notice( $user ) { - delete_user_meta( $user->ID, self::USER_PASSWORD_WAS_RESET_KEY ); - } - - /** - * Generates the html form for the second step of the authentication process. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @param string $login_nonce A string nonce stored in usermeta. - * @param string $redirect_to The URL to which the user would like to be redirected. - * @param string $error_msg Optional. Login error message. - * @param string|object $provider An override to the provider. - */ - public static function login_html( $user, $login_nonce, $redirect_to, $error_msg = '', $provider = null, $action = 'validate_2fa' ) { - $provider = self::get_provider_for_user( $user, $provider ); - if ( ! $provider ) { - wp_die( __( 'Cheatin’ uh?', 'two-factor' ) ); - } - - $provider_key = $provider->get_key(); - $available_providers = self::get_available_providers_for_user( $user ); - $backup_providers = array_diff_key( $available_providers, array( $provider_key => null ) ); - $interim_login = isset( $_REQUEST['interim-login'] ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended - - $rememberme = intval( self::rememberme() ); - - if ( ! function_exists( 'login_header' ) ) { - // We really should migrate login_header() out of `wp-login.php` so it can be called from an includes file. - require_once TWO_FACTOR_DIR . 'includes/function.login-header.php'; - } - - // Disable the language switcher. - add_filter( 'login_display_language_dropdown', '__return_false' ); - - login_header(); - - if ( ! empty( $error_msg ) ) { - echo '
            ' . esc_html( $error_msg ) . '
            '; - } elseif ( 'validate_2fa' === $action ) { - self::maybe_show_last_login_failure_notice( $user ); - } - ?> - -
            - - - - - - - - - - - authentication_page( $user ); ?> -
            - - $action, - 'wp-auth-id' => $user->ID, - 'wp-auth-nonce' => $login_nonce, - ); - if ( $rememberme ) { - $backup_link_args['rememberme'] = $rememberme; - } - if ( $redirect_to ) { - $backup_link_args['redirect_to'] = $redirect_to; - } - if ( $interim_login ) { - $backup_link_args['interim-login'] = 1; - } - ?> -
            -

            - -

            - -
            - - - - - - $user_id, - 'expiration' => time() + ( 10 * MINUTE_IN_SECONDS ), - ); - - try { - $login_nonce['key'] = bin2hex( random_bytes( 32 ) ); - } catch ( Exception $ex ) { - $login_nonce['key'] = wp_hash( $user_id . wp_rand() . microtime(), 'nonce' ); - } - - // Store the nonce hashed to avoid leaking it via database access. - $hashed_key = self::hash_login_nonce( $login_nonce ); - - if ( $hashed_key ) { - $login_nonce_stored = array( - 'expiration' => $login_nonce['expiration'], - 'key' => $hashed_key, - ); - - if ( update_user_meta( $user_id, self::USER_META_NONCE_KEY, $login_nonce_stored ) ) { - return $login_nonce; - } - } - - return false; - } - - /** - * Delete the login nonce. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - * @return bool - */ - public static function delete_login_nonce( $user_id ) { - return delete_user_meta( $user_id, self::USER_META_NONCE_KEY ); - } - - /** - * Verify the login nonce. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - * @param string $nonce Login nonce. - * @return bool - */ - public static function verify_login_nonce( $user_id, $nonce ) { - $login_nonce = get_user_meta( $user_id, self::USER_META_NONCE_KEY, true ); - - if ( ! $login_nonce || empty( $login_nonce['key'] ) || empty( $login_nonce['expiration'] ) ) { - return false; - } - - $unverified_nonce = array( - 'user_id' => $user_id, - 'expiration' => $login_nonce['expiration'], - 'key' => $nonce, - ); - - $unverified_hash = self::hash_login_nonce( $unverified_nonce ); - $hashes_match = $unverified_hash && hash_equals( $login_nonce['key'], $unverified_hash ); - - if ( $hashes_match && time() < $login_nonce['expiration'] ) { - return true; - } - - // Require a fresh nonce if verification fails. - self::delete_login_nonce( $user_id ); - - return false; - } - - /** - * Determine the minimum wait between two factor attempts for a user. - * - * This implements an increasing backoff, requiring an attacker to wait longer - * each time to attempt to brute-force the login. - * - * @param WP_User $user The user being operated upon. - * @return int Time delay in seconds between login attempts. - */ - public static function get_user_time_delay( $user ) { - /** - * Filter the minimum time duration between two factor attempts. - * - * @param int $rate_limit The number of seconds between two factor attempts. - */ - $rate_limit = apply_filters( 'two_factor_rate_limit', 1 ); - - $user_failed_logins = get_user_meta( $user->ID, self::USER_FAILED_LOGIN_ATTEMPTS_KEY, true ); - if ( $user_failed_logins ) { - $rate_limit = pow( 2, $user_failed_logins ) * $rate_limit; - - /** - * Filter the maximum time duration a user may be locked out from retrying two factor authentications. - * - * @param int $max_rate_limit The maximum number of seconds a user might be locked out for. Default 15 minutes. - */ - $max_rate_limit = apply_filters( 'two_factor_max_rate_limit', 15 * MINUTE_IN_SECONDS ); - - $rate_limit = min( $max_rate_limit, $rate_limit ); - } - - /** - * Filters the per-user time duration between two factor login attempts. - * - * @param int $rate_limit The number of seconds between two factor attempts. - * @param WP_User $user The user attempting to login. - */ - return apply_filters( 'two_factor_user_rate_limit', $rate_limit, $user ); - } - - /** - * Determine if a time delay between user two factor login attempts should be triggered. - * - * @since 0.8.0 - * - * @param WP_User $user The User. - * @return bool True if rate limit is okay, false if not. - */ - public static function is_user_rate_limited( $user ) { - $rate_limit = self::get_user_time_delay( $user ); - $last_failed = get_user_meta( $user->ID, self::USER_RATE_LIMIT_KEY, true ); - - $rate_limited = false; - if ( $last_failed && $last_failed + $rate_limit > time() ) { - $rate_limited = true; - } - - /** - * Filter whether this login attempt is rate limited or not. - * - * This allows for dedicated plugins to rate limit two factor login attempts - * based on their own rules. - * - * @param bool $rate_limited Whether the user login is rate limited. - * @param WP_User $user The user attempting to login. - */ - return apply_filters( 'two_factor_is_user_rate_limited', $rate_limited, $user ); - } - - /** - * Determine if the current user session is logged in with 2FA. - * - * @since 0.9.0 - * - * @return int|false The last time the two-factor was validated on success, false if not currently using a 2FA session. - */ - public static function is_current_user_session_two_factor() { - $session = self::get_current_user_session(); - - if ( empty( $session['two-factor-login'] ) ) { - return false; - } - - return (int) $session['two-factor-login']; - } - - /** - * Determine if the current user session can update Two-Factor settings. - * - * @param string $context The context in use, 'display' or 'save'. Save has twice the grace time. - * - * @return bool - */ - public static function current_user_can_update_two_factor_options( $context = 'display' ) { - $user_id = get_current_user_id(); - $is_two_factor_session = self::is_current_user_session_two_factor(); - - // If the user isn't logged in, bail. - if ( ! $user_id ) { - return false; - } - - // If the current user is not using two-factor, they can adjust the settings. - if ( ! self::is_user_using_two_factor( $user_id ) ) { - return true; - } - - // Else, if the session is not two-factor, the user should not be able to update settings. - if ( ! $is_two_factor_session ) { - return false; - } - - /** - * Filter the grace time for two factor revalidation. - * - * Return a falsey value (false, 0) if you wish to never require revalidation. - * - * @param int $two_factor_revalidate_time The grace time between last validation time and when it'll be accepted. Default 10 minutes (in seconds). - * @param int $user_id The user ID. - * @param string $context The context in use, 'display' or 'save'. Save has twice the grace time. - */ - $two_factor_revalidate_time = apply_filters( 'two_factor_revalidate_time', 10 * MINUTE_IN_SECONDS, $user_id, $context ); - - if ( $context === 'save' ) { - $two_factor_revalidate_time *= 2; - } - - // If the revalidate time is falsey, don't enable revalidation. - if ( ! $two_factor_revalidate_time ) { - return true; - } - - // If the user last-2fa'd within the last 10 (or 20) minutes, allow. - $seconds_ago = time() - $is_two_factor_session; - if ( $seconds_ago <= $two_factor_revalidate_time ) { - return true; - } - - // Otherwise the user cannot update the options. - return false; - } - - /** - * Validate that the current user can edit the specified user. If two-factor is required by the account, also verify that it's within the revalidation grace period. - * - * @param int $user_id The user ID being updated. - * - * @return bool|\WP_Error - */ - public static function rest_api_can_edit_user_and_update_two_factor_options( $user_id ) { - if ( ! current_user_can( 'edit_user', $user_id ) ) { - return false; - } - - if ( ! self::current_user_can_update_two_factor_options( 'save' ) ) { - return new WP_Error( 'revalidation_required', __( 'Two Factor Revalidation required.', 'two-factor' ) ); - } - - return true; - } - - /** - * Login form validation handler. - * - * @since 0.1-dev - */ - public static function login_form_validate_2fa() { - $wp_auth_id = ! empty( $_REQUEST['wp-auth-id'] ) ? absint( $_REQUEST['wp-auth-id'] ) : 0; - $nonce = ! empty( $_REQUEST['wp-auth-nonce'] ) ? wp_unslash( $_REQUEST['wp-auth-nonce'] ) : ''; - $provider = ! empty( $_REQUEST['provider'] ) ? wp_unslash( $_REQUEST['provider'] ) : ''; - $redirect_to = ! empty( $_REQUEST['redirect_to'] ) ? wp_unslash( $_REQUEST['redirect_to'] ) : ''; - $is_post_request = ( 'POST' === strtoupper( $_SERVER['REQUEST_METHOD'] ) ); - $user = get_user_by( 'id', $wp_auth_id ); - - if ( ! $wp_auth_id || ! $nonce || ! $user ) { - return; - } - - self::_login_form_validate_2fa( $user, $nonce, $provider, $redirect_to, $is_post_request ); - exit; - } - - /** - * Login form validation. - * - * This function exists for unit testing, as `exit` prevents testing. - * This function expects the caller exiting after calling. - * - * @since 0.9.0 - * - * @param WP_User $user The WP_User instance. - * @param string $nonce The nonce provided. - * @param string $provider The provider to use, if known. - * @param string $redirect_to The redirection location. - * @param bool $is_post_request Whether the incoming request was a POST request or not. - * @return void - */ - public static function _login_form_validate_2fa( $user, $nonce = '', $provider = '', $redirect_to = '', $is_post_request = false ) { - // Validate the request. - if ( true !== self::verify_login_nonce( $user->ID, $nonce ) ) { - wp_safe_redirect( home_url() ); - return; - } - - $provider = self::get_provider_for_user( $user, $provider ); - if ( ! $provider ) { - wp_die( __( 'Cheatin’ uh?', 'two-factor' ) ); - } - - // Run the provider processing. - $result = self::process_provider( $provider, $user, $is_post_request ); - if ( true !== $result ) { - $error = ''; - if ( is_wp_error( $result ) ) { - do_action( 'wp_login_failed', $user->user_login, $result ); - - $error = $result->get_error_message(); - } - - $login_nonce = self::create_login_nonce( $user->ID ); - if ( ! $login_nonce ) { - wp_die( esc_html__( 'Failed to create a login nonce.', 'two-factor' ) ); - } - - self::login_html( $user, $login_nonce['key'], $redirect_to, $error, $provider ); - return; - } - - self::delete_login_nonce( $user->ID ); - delete_user_meta( $user->ID, self::USER_RATE_LIMIT_KEY ); - delete_user_meta( $user->ID, self::USER_FAILED_LOGIN_ATTEMPTS_KEY ); - - $rememberme = false; - if ( isset( $_REQUEST['rememberme'] ) && $_REQUEST['rememberme'] ) { - $rememberme = true; - } - - $session_information_callback = static function( $session, $user_id ) use( $provider, $user ) { - if ( $user->ID === $user_id ) { - $session['two-factor-login'] = time(); - $session['two-factor-provider'] = $provider->get_key(); - } - - return $session; - }; - - add_filter( 'attach_session_information', $session_information_callback, 10, 2 ); - - /* - * NOTE: This filter removal is not normally required, this is included for protection against - * a plugin/two factor provider which runs the `authenticate` filter during it's validation. - * Such a plugin would cause self::filter_authenticate_block_cookies() to run and add this filter. - */ - remove_filter( 'send_auth_cookies', '__return_false', PHP_INT_MAX ); - - wp_set_auth_cookie( $user->ID, $rememberme ); - - do_action( 'two_factor_user_authenticated', $user, $provider ); - - remove_filter( 'attach_session_information', $session_information_callback ); - - // Must be global because that's how login_header() uses it. - global $interim_login; - $interim_login = isset( $_REQUEST['interim-login'] ); // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited,WordPress.Security.NonceVerification.Recommended - - if ( $interim_login ) { - $customize_login = isset( $_REQUEST['customize-login'] ); - if ( $customize_login ) { - wp_enqueue_script( 'customize-base' ); - } - $message = '

            ' . __( 'You have logged in successfully.', 'two-factor' ) . '

            '; - $interim_login = 'success'; // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - login_header( '', $message ); - ?> - - - - - - - ID ) ) { - wp_safe_redirect( home_url() ); - return; - } - - $provider = self::get_provider_for_user( $user, $provider ); - if ( ! $provider ) { - wp_die( __( 'Cheatin’ uh?', 'two-factor' ) ); - } - - // Run the provider processing. - $result = self::process_provider( $provider, $user, $is_post_request ); - if ( true !== $result ) { - $error = ''; - if ( is_wp_error( $result ) ) { - do_action( 'wp_login_failed', $user->user_login, $result ); - - $error = $result->get_error_message(); - } - - $nonce = wp_create_nonce( 'two_factor_revalidate_' . $user->ID ); - - self::login_html( $user, $nonce, $redirect_to, $error, $provider, 'revalidate_2fa' ); - return; - } - - // Update the session metadata with the revalidation details. - self::update_current_user_session( - array( - 'two-factor-provider' => $provider->get_key(), - 'two-factor-login' => time(), - ) - ); - - do_action( 'two_factor_user_revalidated', $user, $provider ); - - // Must be global because that's how login_header() uses it. - global $interim_login; - $interim_login = isset( $_REQUEST['interim-login'] ); // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited,WordPress.Security.NonceVerification.Recommended - - if ( $interim_login ) { - $message = '

            ' . __( 'You have revalidated successfully.', 'two-factor' ) . '

            '; - $interim_login = 'success'; // phpcs:ignore WordPress.WP.GlobalVariablesOverride.Prohibited - login_header( '', $message ); - ?> - - - - pre_process_authentication( $user ) ) { - return false; - } - - // If it's not a POST request, there's no processing to perform. - if ( ! $is_post_request ) { - return false; - } - - // Rate limit two factor authentication attempts. - if ( true === self::is_user_rate_limited( $user ) ) { - $time_delay = self::get_user_time_delay( $user ); - $last_login = get_user_meta( $user->ID, self::USER_RATE_LIMIT_KEY, true ); - - return new WP_Error( - 'two_factor_too_fast', - sprintf( - __( 'ERROR: Too many invalid verification codes, you can try again in %s. This limit protects your account against automated attacks.', 'two-factor' ), - human_time_diff( $last_login + $time_delay ) - ) - ); - } - - // Ask the provider to verify the second factor. - if ( true !== $provider->validate_authentication( $user ) ) { - // Store the last time a failed login occurred. - update_user_meta( $user->ID, self::USER_RATE_LIMIT_KEY, time() ); - - // Store the number of failed login attempts. - update_user_meta( $user->ID, self::USER_FAILED_LOGIN_ATTEMPTS_KEY, 1 + (int) get_user_meta( $user->ID, self::USER_FAILED_LOGIN_ATTEMPTS_KEY, true ) ); - - if ( ! is_user_logged_in() && self::should_reset_password( $user->ID ) ) { - self::reset_compromised_password( $user ); - self::send_password_reset_emails( $user ); - self::show_password_reset_error(); - exit; - } - - return new WP_Error( - 'two_factor_invalid', - __( 'ERROR: Invalid verification code.', 'two-factor' ) - ); - } - - return true; - } - - /** - * Determine if the user's password should be reset. - * - * @param int $user_id - * - * @return bool - */ - public static function should_reset_password( $user_id ) { - $failed_attempts = (int) get_user_meta( $user_id, self::USER_FAILED_LOGIN_ATTEMPTS_KEY, true ); - - /** - * Filters the maximum number of failed attempts on a 2nd factor before the user's - * password will be reset. After a reasonable number of attempts, it's safe to assume - * that the password has been compromised and an attacker is trying to brute force the 2nd - * factor. - * - * ⚠️ `get_user_time_delay()` mitigates brute force attempts, but many 2nd factors -- - * like TOTP and backup codes -- are very weak on their own, so it's not safe to give - * attackers unlimited attempts. Setting this to a very large number is strongly - * discouraged. - * - * @param int $limit The number of attempts before the password is reset. - */ - $failed_attempt_limit = apply_filters( 'two_factor_failed_attempt_limit', 30 ); - - return $failed_attempts >= $failed_attempt_limit; - } - - /** - * Reset a compromised password. - * - * If we know that the the password is compromised, we have the responsibility to reset it and inform the - * user. `get_user_time_delay()` mitigates brute force attempts, but this acts as an extra layer of defense - * which guarantees that attackers can't brute force it (unless they compromise the new password). - * - * @param WP_User $user The user who failed to login - */ - public static function reset_compromised_password( $user ) { - // Unhook because `wp_password_change_notification()` wouldn't notify the site admin when - // their password is compromised. - remove_action( 'after_password_reset', 'wp_password_change_notification' ); - reset_password( $user, wp_generate_password( 25 ) ); - update_user_meta( $user->ID, self::USER_PASSWORD_WAS_RESET_KEY, true ); - add_action( 'after_password_reset', 'wp_password_change_notification' ); - - self::delete_login_nonce( $user->ID ); - delete_user_meta( $user->ID, self::USER_RATE_LIMIT_KEY ); - delete_user_meta( $user->ID, self::USER_FAILED_LOGIN_ATTEMPTS_KEY ); - } - - /** - * Notify the user and admin that a password was reset for being compromised. - * - * @param WP_User $user The user whose password should be reset - */ - public static function send_password_reset_emails( $user ) { - self::notify_user_password_reset( $user ); - - /** - * Filters whether or not to email the site admin when a user's password has been - * compromised and reset. - * - * @param bool $reset `true` to notify the admin, `false` to not notify them. - */ - $notify_admin = apply_filters( 'two_factor_notify_admin_user_password_reset', true ); - $admin_email = get_option( 'admin_email' ); - - if ( $notify_admin && $admin_email !== $user->user_email ) { - self::notify_admin_user_password_reset( $user ); - } - } - - /** - * Notify the user that their password has been compromised and reset. - * - * @param WP_User $user The user to notify - * - * @return bool `true` if the email was sent, `false` if it failed. - */ - public static function notify_user_password_reset( $user ) { - $user_message = sprintf( - 'Hello %1$s, an unusually high number of failed login attempts have been detected on your account at %2$s. - - These attempts successfully entered your password, and were only blocked because they failed to enter your second authentication factor. Despite not being able to access your account, this behavior indicates that the attackers have compromised your password. The most common reasons for this are that your password was easy to guess, or was reused on another site which has been compromised. - - To protect your account, your password has been reset, and you will need to create a new one. For advice on setting a strong password, please read %3$s - - To pick a new password, please visit %4$s - - This is an automated notification. If you would like to speak to a site administrator, please contact them directly.', - esc_html( $user->user_login ), - home_url(), - 'https://wordpress.org/documentation/article/password-best-practices/', - esc_url( add_query_arg( 'action', 'lostpassword', wp_login_url() ) ) - ); - $user_message = str_replace( "\t", '', $user_message ); - - return wp_mail( $user->user_email, 'Your password was compromised and has been reset', $user_message ); - } - - /** - * Notify the admin that a user's password was compromised and reset. - * - * @param WP_User $user The user whose password was reset. - * - * @return bool `true` if the email was sent, `false` if it failed. - */ - public static function notify_admin_user_password_reset( $user ) { - $admin_email = get_option( 'admin_email' ); - $subject = sprintf( 'Compromised password for %s has been reset', esc_html( $user->user_login ) ); - - $message = sprintf( - 'Hello, this is a notice from the Two Factor plugin to inform you that an unusually high number of failed login attempts have been detected on the %1$s account (ID %2$d). - - Those attempts successfully entered the user\'s password, and were only blocked because they entered invalid second authentication factors. - - To protect their account, the password has automatically been reset, and they have been notified that they will need to create a new one. - - If you do not wish to receive these notifications, you can disable them with the `two_factor_notify_admin_user_password_reset` filter. See %3$s for more information. - - Thank you', - esc_html( $user->user_login ), - $user->ID, - 'https://developer.wordpress.org/plugins/hooks/' - ); - $message = str_replace( "\t", '', $message ); - - return wp_mail( $admin_email, $subject, $message ); - } - - /** - * Show the password reset error when on the login screen. - */ - public static function show_password_reset_error() { - $error = new WP_Error( - 'too_many_attempts', - sprintf( - '

            %s

            -

            %s

            ', - __( 'There have been too many failed two-factor authentication attempts, which often indicates that the password has been compromised. The password has been reset in order to protect the account.', 'two-factor' ), - __( 'If you are the owner of this account, please check your email for instructions on regaining access.', 'two-factor' ) - ) - ); - - login_header( __( 'Password Reset', 'two-factor' ), '', $error ); - login_footer(); - } - - /** - * Filter the columns on the Users admin screen. - * - * @param array $columns Available columns. - * @return array Updated array of columns. - */ - public static function filter_manage_users_columns( array $columns ) { - $columns['two-factor'] = __( 'Two-Factor', 'two-factor' ); - return $columns; - } - - /** - * Output the 2FA column data on the Users screen. - * - * @param string $output The column output. - * @param string $column_name The column ID. - * @param int $user_id The user ID. - * @return string The column output. - */ - public static function manage_users_custom_column( $output, $column_name, $user_id ) { - - if ( 'two-factor' !== $column_name ) { - return $output; - } - - if ( ! self::is_user_using_two_factor( $user_id ) ) { - return sprintf( '%s', esc_html__( 'Disabled', 'two-factor' ) ); - } else { - $provider = self::get_primary_provider_for_user( $user_id ); - return esc_html( $provider->get_label() ); - } - - } - - /** - * Add user profile fields. - * - * This executes during the `show_user_profile` & `edit_user_profile` actions. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public static function user_two_factor_options( $user ) { - $notices = []; - - $providers = self::get_supported_providers_for_user( $user ); - - wp_enqueue_style( 'user-edit-2fa', plugins_url( 'user-edit.css', __FILE__ ), array(), TWO_FACTOR_VERSION ); - - $enabled_providers = array_keys( self::get_available_providers_for_user( $user ) ); - - // This is specific to the current session, not the displayed user. - $show_2fa_options = self::current_user_can_update_two_factor_options(); - - if ( ! $show_2fa_options ) { - $url = add_query_arg( - 'redirect_to', - urlencode( self::get_user_settings_page_url( $user->ID ) . '#two-factor-options' ), - self::get_user_two_factor_revalidate_url() - ); - - $notices['warning two-factor-warning-revalidate-session'] = sprintf( - esc_html__( 'To update your Two-Factor options, you must first revalidate your session.', 'two-factor' ) . - ' ' . esc_html__( 'Revalidate now', 'two-factor' ) . '', - esc_url( $url ) - ); - } - - if ( empty( $providers ) ) { - $notices['notice two-factor-notice-no-providers-supported'] = esc_html__( 'No providers are available for your account.', 'two-factor' ); - } - - // Suggest enabling a backup method if only one method is enabled and there are more available. - if ( count( $providers ) > 1 && 1 === count( $enabled_providers ) ) { - $notices['warning two-factor-warning-suggest-backup'] = esc_html__( 'To prevent being locked out of your account, consider enabling a backup method like Recovery Codes in case you lose access to your primary authentication method.', 'two-factor' ); - } - ?> -

            - - $notice ) : ?> -
            -

            -
            - - -
            > - -
            - - -

            - -

            - - - - - - - $object ) : ?> - - - - - - - -
            - - - - - - - - - get_key() === $provider_to_delete ) { - delete_user_meta( $user_id, self::PROVIDER_USER_META_KEY ); - } - - return (bool) update_user_meta( $user_id, self::ENABLED_PROVIDERS_USER_META_KEY, $enabled_providers ); - } - - /** - * Update the user meta value. - * - * This executes during the `personal_options_update` & `edit_user_profile_update` actions. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - */ - public static function user_two_factor_options_update( $user_id ) { - if ( isset( $_POST['_nonce_user_two_factor_options'] ) ) { - check_admin_referer( 'user_two_factor_options', '_nonce_user_two_factor_options' ); - - if ( ! isset( $_POST[ self::ENABLED_PROVIDERS_USER_META_KEY ] ) || - ! is_array( $_POST[ self::ENABLED_PROVIDERS_USER_META_KEY ] ) ) { - return; - } - - if ( ! self::current_user_can_update_two_factor_options( 'save' ) ) { - return; - } - - $providers = self::get_supported_providers_for_user( $user_id ); - $enabled_providers = $_POST[ self::ENABLED_PROVIDERS_USER_META_KEY ]; - $existing_providers = self::get_enabled_providers_for_user( $user_id ); - - // Enable only the available providers. - $enabled_providers = array_intersect( $enabled_providers, array_keys( $providers ) ); - update_user_meta( $user_id, self::ENABLED_PROVIDERS_USER_META_KEY, $enabled_providers ); - - // Primary provider must be enabled. - $new_provider = isset( $_POST[ self::PROVIDER_USER_META_KEY ] ) ? $_POST[ self::PROVIDER_USER_META_KEY ] : ''; - if ( ! empty( $new_provider ) && in_array( $new_provider, $enabled_providers, true ) ) { - update_user_meta( $user_id, self::PROVIDER_USER_META_KEY, $new_provider ); - } else { - delete_user_meta( $user_id, self::PROVIDER_USER_META_KEY ); - } - - // Have we changed the two-factor settings for the current user? Alter their session metadata. - if ( $user_id === get_current_user_id() ) { - - if ( $enabled_providers && ! $existing_providers && ! self::is_current_user_session_two_factor() ) { - // We've enabled two-factor from a non-two-factor session, set the key but not the provider, as no provider has been used yet. - self::update_current_user_session( array( - 'two-factor-provider' => '', - 'two-factor-login' => time(), - ) ); - } elseif ( $existing_providers && ! $enabled_providers ) { - // We've disabled two-factor, remove session metadata. - self::update_current_user_session( array( - 'two-factor-provider' => null, - 'two-factor-login' => null, - ) ); - } - } - - // Destroy other sessions if setup 2FA for the first time, or deactivated a provider - if ( - // No providers, enabling one (or more) - ( ! $existing_providers && $enabled_providers ) || - // Has providers, and is disabling one (or more), but remaining with 2FA. - ( $existing_providers && $enabled_providers && array_diff( $existing_providers, $enabled_providers ) ) - ) { - if ( $user_id === get_current_user_id() ) { - // Keep the current session, destroy others sessions for this user. - wp_destroy_other_sessions(); - } else { - // Destroy all sessions for the user. - WP_Session_Tokens::get_instance( $user_id )->destroy_all(); - } - } - } - } - - /** - * Update the current user session metadata. - * - * Any values set in $data that are null will be removed from the user session metadata. - * - * @param array $data The data to append/remove from the current session. - * @return bool - */ - public static function update_current_user_session( $data = array() ) { - $user_id = get_current_user_id(); - $token = wp_get_session_token(); - if ( ! $user_id || ! $token ) { - return false; - } - - $manager = WP_Session_Tokens::get_instance( $user_id ); - $session = $manager->get( $token ); - - // Add any session data. - $session = array_merge( $session, $data ); - - // Remove any set null fields. - foreach ( array_filter( $data, 'is_null' ) as $key => $null ) { - unset( $session[ $key ] ); - } - - return $manager->update( $token, $session ); - } - - /** - * Fetch the current user session metadata. - * - * @return false|array The session array, false on error. - */ - public static function get_current_user_session() { - $user_id = get_current_user_id(); - $token = wp_get_session_token(); - if ( ! $user_id || ! $token ) { - return false; - } - - $manager = WP_Session_Tokens::get_instance( $user_id ); - - return $manager->get( $token ); - } - - /** - * Should the login session persist between sessions. - * - * @return boolean - */ - public static function rememberme() { - $rememberme = false; - - if ( ! empty( $_REQUEST['rememberme'] ) ) { - $rememberme = true; - } - - return (bool) apply_filters( 'two_factor_rememberme', $rememberme ); - } - - /** - * Sync the Two-Factor session data from the current session to newly created sessions. - * - * This is required as WordPress creates a new session when the user password is changed. - * - * @see https://core.trac.wordpress.org/ticket/58427 - * - * @param array $session The Session information. - * @param int $user_id The User ID for the session. - * @return array - */ - public static function filter_session_information( $session, $user_id ) { - if ( $user_id !== get_current_user_id() ) { - return $session; - } - - $current_session = self::get_current_user_session(); - if ( $current_session ) { - foreach ( $current_session as $key => $value ) { - if ( str_starts_with( $key, 'two-factor-' ) ) { - $session[ $key ] = $value; - } - } - } - - return $session; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/includes/Google/u2f-api.js b/wp-content/upgrade-temp-backup/plugins/two-factor/includes/Google/u2f-api.js deleted file mode 100644 index 1036b920..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/includes/Google/u2f-api.js +++ /dev/null @@ -1,748 +0,0 @@ -//Copyright 2014-2015 Google Inc. All rights reserved. - -//Use of this source code is governed by a BSD-style -//license that can be found in the LICENSE file or at -//https://developers.google.com/open-source/licenses/bsd - -/** - * @fileoverview The U2F api. - */ -'use strict'; - - -/** - * Namespace for the U2F api. - * @type {Object} - */ -var u2f = u2f || {}; - -/** - * FIDO U2F Javascript API Version - * @number - */ -var js_api_version; - -/** - * The U2F extension id - * @const {string} - */ -// The Chrome packaged app extension ID. -// Uncomment this if you want to deploy a server instance that uses -// the package Chrome app and does not require installing the U2F Chrome extension. - u2f.EXTENSION_ID = 'kmendfapggjehodndflmmgagdbamhnfd'; -// The U2F Chrome extension ID. -// Uncomment this if you want to deploy a server instance that uses -// the U2F Chrome extension to authenticate. -// u2f.EXTENSION_ID = 'pfboblefjcgdjicmnffhdgionmgcdmne'; - - -/** - * Message types for messages to/from the extension - * @const - * @enum {string} - */ -u2f.MessageTypes = { - 'U2F_REGISTER_REQUEST': 'u2f_register_request', - 'U2F_REGISTER_RESPONSE': 'u2f_register_response', - 'U2F_SIGN_REQUEST': 'u2f_sign_request', - 'U2F_SIGN_RESPONSE': 'u2f_sign_response', - 'U2F_GET_API_VERSION_REQUEST': 'u2f_get_api_version_request', - 'U2F_GET_API_VERSION_RESPONSE': 'u2f_get_api_version_response' -}; - - -/** - * Response status codes - * @const - * @enum {number} - */ -u2f.ErrorCodes = { - 'OK': 0, - 'OTHER_ERROR': 1, - 'BAD_REQUEST': 2, - 'CONFIGURATION_UNSUPPORTED': 3, - 'DEVICE_INELIGIBLE': 4, - 'TIMEOUT': 5 -}; - - -/** - * A message for registration requests - * @typedef {{ - * type: u2f.MessageTypes, - * appId: ?string, - * timeoutSeconds: ?number, - * requestId: ?number - * }} - */ -u2f.U2fRequest; - - -/** - * A message for registration responses - * @typedef {{ - * type: u2f.MessageTypes, - * responseData: (u2f.Error | u2f.RegisterResponse | u2f.SignResponse), - * requestId: ?number - * }} - */ -u2f.U2fResponse; - - -/** - * An error object for responses - * @typedef {{ - * errorCode: u2f.ErrorCodes, - * errorMessage: ?string - * }} - */ -u2f.Error; - -/** - * Data object for a single sign request. - * @typedef {enum {BLUETOOTH_RADIO, BLUETOOTH_LOW_ENERGY, USB, NFC}} - */ -u2f.Transport; - - -/** - * Data object for a single sign request. - * @typedef {Array} - */ -u2f.Transports; - -/** - * Data object for a single sign request. - * @typedef {{ - * version: string, - * challenge: string, - * keyHandle: string, - * appId: string - * }} - */ -u2f.SignRequest; - - -/** - * Data object for a sign response. - * @typedef {{ - * keyHandle: string, - * signatureData: string, - * clientData: string - * }} - */ -u2f.SignResponse; - - -/** - * Data object for a registration request. - * @typedef {{ - * version: string, - * challenge: string - * }} - */ -u2f.RegisterRequest; - - -/** - * Data object for a registration response. - * @typedef {{ - * version: string, - * keyHandle: string, - * transports: Transports, - * appId: string - * }} - */ -u2f.RegisterResponse; - - -/** - * Data object for a registered key. - * @typedef {{ - * version: string, - * keyHandle: string, - * transports: ?Transports, - * appId: ?string - * }} - */ -u2f.RegisteredKey; - - -/** - * Data object for a get API register response. - * @typedef {{ - * js_api_version: number - * }} - */ -u2f.GetJsApiVersionResponse; - - -//Low level MessagePort API support - -/** - * Sets up a MessagePort to the U2F extension using the - * available mechanisms. - * @param {function((MessagePort|u2f.WrappedChromeRuntimePort_))} callback - */ -u2f.getMessagePort = function(callback) { - if (typeof chrome != 'undefined' && chrome.runtime) { - // The actual message here does not matter, but we need to get a reply - // for the callback to run. Thus, send an empty signature request - // in order to get a failure response. - var msg = { - type: u2f.MessageTypes.U2F_SIGN_REQUEST, - signRequests: [] - }; - chrome.runtime.sendMessage(u2f.EXTENSION_ID, msg, function() { - if (!chrome.runtime.lastError) { - // We are on a whitelisted origin and can talk directly - // with the extension. - u2f.getChromeRuntimePort_(callback); - } else { - // chrome.runtime was available, but we couldn't message - // the extension directly, use iframe - u2f.getIframePort_(callback); - } - }); - } else if (u2f.isAndroidChrome_()) { - u2f.getAuthenticatorPort_(callback); - } else if (u2f.isIosChrome_()) { - u2f.getIosPort_(callback); - } else { - // chrome.runtime was not available at all, which is normal - // when this origin doesn't have access to any extensions. - u2f.getIframePort_(callback); - } -}; - -/** - * Detect chrome running on android based on the browser's useragent. - * @private - */ -u2f.isAndroidChrome_ = function() { - var userAgent = navigator.userAgent; - return userAgent.indexOf('Chrome') != -1 && - userAgent.indexOf('Android') != -1; -}; - -/** - * Detect chrome running on iOS based on the browser's platform. - * @private - */ -u2f.isIosChrome_ = function() { - return ["iPhone", "iPad", "iPod"].indexOf(navigator.platform) > -1; -}; - -/** - * Connects directly to the extension via chrome.runtime.connect. - * @param {function(u2f.WrappedChromeRuntimePort_)} callback - * @private - */ -u2f.getChromeRuntimePort_ = function(callback) { - var port = chrome.runtime.connect(u2f.EXTENSION_ID, - {'includeTlsChannelId': true}); - setTimeout(function() { - callback(new u2f.WrappedChromeRuntimePort_(port)); - }, 0); -}; - -/** - * Return a 'port' abstraction to the Authenticator app. - * @param {function(u2f.WrappedAuthenticatorPort_)} callback - * @private - */ -u2f.getAuthenticatorPort_ = function(callback) { - setTimeout(function() { - callback(new u2f.WrappedAuthenticatorPort_()); - }, 0); -}; - -/** - * Return a 'port' abstraction to the iOS client app. - * @param {function(u2f.WrappedIosPort_)} callback - * @private - */ -u2f.getIosPort_ = function(callback) { - setTimeout(function() { - callback(new u2f.WrappedIosPort_()); - }, 0); -}; - -/** - * A wrapper for chrome.runtime.Port that is compatible with MessagePort. - * @param {Port} port - * @constructor - * @private - */ -u2f.WrappedChromeRuntimePort_ = function(port) { - this.port_ = port; -}; - -/** - * Format and return a sign request compliant with the JS API version supported by the extension. - * @param {Array} signRequests - * @param {number} timeoutSeconds - * @param {number} reqId - * @return {Object} - */ -u2f.formatSignRequest_ = - function(appId, challenge, registeredKeys, timeoutSeconds, reqId) { - if (js_api_version === undefined || js_api_version < 1.1) { - // Adapt request to the 1.0 JS API. - var signRequests = []; - for (var i = 0; i < registeredKeys.length; i++) { - signRequests[i] = { - version: registeredKeys[i].version, - challenge: challenge, - keyHandle: registeredKeys[i].keyHandle, - appId: appId - }; - } - return { - type: u2f.MessageTypes.U2F_SIGN_REQUEST, - signRequests: signRequests, - timeoutSeconds: timeoutSeconds, - requestId: reqId - }; - } - // JS 1.1 API. - return { - type: u2f.MessageTypes.U2F_SIGN_REQUEST, - appId: appId, - challenge: challenge, - registeredKeys: registeredKeys, - timeoutSeconds: timeoutSeconds, - requestId: reqId - }; -}; - -/** - * Format and return a register request compliant with the JS API version supported by the extension.. - * @param {Array} signRequests - * @param {Array} signRequests - * @param {number} timeoutSeconds - * @param {number} reqId - * @return {Object} - */ -u2f.formatRegisterRequest_ = - function(appId, registeredKeys, registerRequests, timeoutSeconds, reqId) { - if (js_api_version === undefined || js_api_version < 1.1) { - // Adapt request to the 1.0 JS API. - for (var i = 0; i < registerRequests.length; i++) { - registerRequests[i].appId = appId; - } - var signRequests = []; - for (var i = 0; i < registeredKeys.length; i++) { - signRequests[i] = { - version: registeredKeys[i].version, - challenge: registerRequests[0], - keyHandle: registeredKeys[i].keyHandle, - appId: appId - }; - } - return { - type: u2f.MessageTypes.U2F_REGISTER_REQUEST, - signRequests: signRequests, - registerRequests: registerRequests, - timeoutSeconds: timeoutSeconds, - requestId: reqId - }; - } - // JS 1.1 API. - return { - type: u2f.MessageTypes.U2F_REGISTER_REQUEST, - appId: appId, - registerRequests: registerRequests, - registeredKeys: registeredKeys, - timeoutSeconds: timeoutSeconds, - requestId: reqId - }; -}; - - -/** - * Posts a message on the underlying channel. - * @param {Object} message - */ -u2f.WrappedChromeRuntimePort_.prototype.postMessage = function(message) { - this.port_.postMessage(message); -}; - - -/** - * Emulates the HTML 5 addEventListener interface. Works only for the - * onmessage event, which is hooked up to the chrome.runtime.Port.onMessage. - * @param {string} eventName - * @param {function({data: Object})} handler - */ -u2f.WrappedChromeRuntimePort_.prototype.addEventListener = - function(eventName, handler) { - var name = eventName.toLowerCase(); - if (name == 'message' || name == 'onmessage') { - this.port_.onMessage.addListener(function(message) { - // Emulate a minimal MessageEvent object. - handler({'data': message}); - }); - } else { - console.error('WrappedChromeRuntimePort only supports onMessage'); - } -}; - -/** - * Wrap the Authenticator app with a MessagePort interface. - * @constructor - * @private - */ -u2f.WrappedAuthenticatorPort_ = function() { - this.requestId_ = -1; - this.requestObject_ = null; -} - -/** - * Launch the Authenticator intent. - * @param {Object} message - */ -u2f.WrappedAuthenticatorPort_.prototype.postMessage = function(message) { - var intentUrl = - u2f.WrappedAuthenticatorPort_.INTENT_URL_BASE_ + - ';S.request=' + encodeURIComponent(JSON.stringify(message)) + - ';end'; - document.location = intentUrl; -}; - -/** - * Tells what type of port this is. - * @return {String} port type - */ -u2f.WrappedAuthenticatorPort_.prototype.getPortType = function() { - return "WrappedAuthenticatorPort_"; -}; - - -/** - * Emulates the HTML 5 addEventListener interface. - * @param {string} eventName - * @param {function({data: Object})} handler - */ -u2f.WrappedAuthenticatorPort_.prototype.addEventListener = function(eventName, handler) { - var name = eventName.toLowerCase(); - if (name == 'message') { - var self = this; - /* Register a callback to that executes when - * chrome injects the response. */ - window.addEventListener( - 'message', self.onRequestUpdate_.bind(self, handler), false); - } else { - console.error('WrappedAuthenticatorPort only supports message'); - } -}; - -/** - * Callback invoked when a response is received from the Authenticator. - * @param function({data: Object}) callback - * @param {Object} message message Object - */ -u2f.WrappedAuthenticatorPort_.prototype.onRequestUpdate_ = - function(callback, message) { - var messageObject = JSON.parse(message.data); - var intentUrl = messageObject['intentURL']; - - var errorCode = messageObject['errorCode']; - var responseObject = null; - if (messageObject.hasOwnProperty('data')) { - responseObject = /** @type {Object} */ ( - JSON.parse(messageObject['data'])); - } - - callback({'data': responseObject}); -}; - -/** - * Base URL for intents to Authenticator. - * @const - * @private - */ -u2f.WrappedAuthenticatorPort_.INTENT_URL_BASE_ = - 'intent:#Intent;action=com.google.android.apps.authenticator.AUTHENTICATE'; - -/** - * Wrap the iOS client app with a MessagePort interface. - * @constructor - * @private - */ -u2f.WrappedIosPort_ = function() {}; - -/** - * Launch the iOS client app request - * @param {Object} message - */ -u2f.WrappedIosPort_.prototype.postMessage = function(message) { - var str = JSON.stringify(message); - var url = "u2f://auth?" + encodeURI(str); - location.replace(url); -}; - -/** - * Tells what type of port this is. - * @return {String} port type - */ -u2f.WrappedIosPort_.prototype.getPortType = function() { - return "WrappedIosPort_"; -}; - -/** - * Emulates the HTML 5 addEventListener interface. - * @param {string} eventName - * @param {function({data: Object})} handler - */ -u2f.WrappedIosPort_.prototype.addEventListener = function(eventName, handler) { - var name = eventName.toLowerCase(); - if (name !== 'message') { - console.error('WrappedIosPort only supports message'); - } -}; - -/** - * Sets up an embedded trampoline iframe, sourced from the extension. - * @param {function(MessagePort)} callback - * @private - */ -u2f.getIframePort_ = function(callback) { - // Create the iframe - var iframeOrigin = 'chrome-extension://' + u2f.EXTENSION_ID; - var iframe = document.createElement('iframe'); - iframe.src = iframeOrigin + '/u2f-comms.html'; - iframe.setAttribute('style', 'display:none'); - document.body.appendChild(iframe); - - var channel = new MessageChannel(); - var ready = function(message) { - if (message.data == 'ready') { - channel.port1.removeEventListener('message', ready); - callback(channel.port1); - } else { - console.error('First event on iframe port was not "ready"'); - } - }; - channel.port1.addEventListener('message', ready); - channel.port1.start(); - - iframe.addEventListener('load', function() { - // Deliver the port to the iframe and initialize - iframe.contentWindow.postMessage('init', iframeOrigin, [channel.port2]); - }); -}; - - -//High-level JS API - -/** - * Default extension response timeout in seconds. - * @const - */ -u2f.EXTENSION_TIMEOUT_SEC = 30; - -/** - * A singleton instance for a MessagePort to the extension. - * @type {MessagePort|u2f.WrappedChromeRuntimePort_} - * @private - */ -u2f.port_ = null; - -/** - * Callbacks waiting for a port - * @type {Array} - * @private - */ -u2f.waitingForPort_ = []; - -/** - * A counter for requestIds. - * @type {number} - * @private - */ -u2f.reqCounter_ = 0; - -/** - * A map from requestIds to client callbacks - * @type {Object.} - * @private - */ -u2f.callbackMap_ = {}; - -/** - * Creates or retrieves the MessagePort singleton to use. - * @param {function((MessagePort|u2f.WrappedChromeRuntimePort_))} callback - * @private - */ -u2f.getPortSingleton_ = function(callback) { - if (u2f.port_) { - callback(u2f.port_); - } else { - if (u2f.waitingForPort_.length == 0) { - u2f.getMessagePort(function(port) { - u2f.port_ = port; - u2f.port_.addEventListener('message', - /** @type {function(Event)} */ (u2f.responseHandler_)); - - // Careful, here be async callbacks. Maybe. - while (u2f.waitingForPort_.length) - u2f.waitingForPort_.shift()(u2f.port_); - }); - } - u2f.waitingForPort_.push(callback); - } -}; - -/** - * Handles response messages from the extension. - * @param {MessageEvent.} message - * @private - */ -u2f.responseHandler_ = function(message) { - var response = message.data; - var reqId = response['requestId']; - if (!reqId || !u2f.callbackMap_[reqId]) { - console.error('Unknown or missing requestId in response.'); - return; - } - var cb = u2f.callbackMap_[reqId]; - delete u2f.callbackMap_[reqId]; - cb(response['responseData']); -}; - -/** - * Dispatches an array of sign requests to available U2F tokens. - * If the JS API version supported by the extension is unknown, it first sends a - * message to the extension to find out the supported API version and then it sends - * the sign request. - * @param {string=} appId - * @param {string=} challenge - * @param {Array} registeredKeys - * @param {function((u2f.Error|u2f.SignResponse))} callback - * @param {number=} opt_timeoutSeconds - */ -u2f.sign = function(appId, challenge, registeredKeys, callback, opt_timeoutSeconds) { - if (js_api_version === undefined) { - // Send a message to get the extension to JS API version, then send the actual sign request. - u2f.getApiVersion( - function (response) { - js_api_version = response['js_api_version'] === undefined ? 0 : response['js_api_version']; - console.log("Extension JS API Version: ", js_api_version); - u2f.sendSignRequest(appId, challenge, registeredKeys, callback, opt_timeoutSeconds); - }); - } else { - // We know the JS API version. Send the actual sign request in the supported API version. - u2f.sendSignRequest(appId, challenge, registeredKeys, callback, opt_timeoutSeconds); - } -}; - -/** - * Dispatches an array of sign requests to available U2F tokens. - * @param {string=} appId - * @param {string=} challenge - * @param {Array} registeredKeys - * @param {function((u2f.Error|u2f.SignResponse))} callback - * @param {number=} opt_timeoutSeconds - */ -u2f.sendSignRequest = function(appId, challenge, registeredKeys, callback, opt_timeoutSeconds) { - u2f.getPortSingleton_(function(port) { - var reqId = ++u2f.reqCounter_; - u2f.callbackMap_[reqId] = callback; - var timeoutSeconds = (typeof opt_timeoutSeconds !== 'undefined' ? - opt_timeoutSeconds : u2f.EXTENSION_TIMEOUT_SEC); - var req = u2f.formatSignRequest_(appId, challenge, registeredKeys, timeoutSeconds, reqId); - port.postMessage(req); - }); -}; - -/** - * Dispatches register requests to available U2F tokens. An array of sign - * requests identifies already registered tokens. - * If the JS API version supported by the extension is unknown, it first sends a - * message to the extension to find out the supported API version and then it sends - * the register request. - * @param {string=} appId - * @param {Array} registerRequests - * @param {Array} registeredKeys - * @param {function((u2f.Error|u2f.RegisterResponse))} callback - * @param {number=} opt_timeoutSeconds - */ -u2f.register = function(appId, registerRequests, registeredKeys, callback, opt_timeoutSeconds) { - if (js_api_version === undefined) { - // Send a message to get the extension to JS API version, then send the actual register request. - u2f.getApiVersion( - function (response) { - js_api_version = response['js_api_version'] === undefined ? 0: response['js_api_version']; - console.log("Extension JS API Version: ", js_api_version); - u2f.sendRegisterRequest(appId, registerRequests, registeredKeys, - callback, opt_timeoutSeconds); - }); - } else { - // We know the JS API version. Send the actual register request in the supported API version. - u2f.sendRegisterRequest(appId, registerRequests, registeredKeys, - callback, opt_timeoutSeconds); - } -}; - -/** - * Dispatches register requests to available U2F tokens. An array of sign - * requests identifies already registered tokens. - * @param {string=} appId - * @param {Array} registerRequests - * @param {Array} registeredKeys - * @param {function((u2f.Error|u2f.RegisterResponse))} callback - * @param {number=} opt_timeoutSeconds - */ -u2f.sendRegisterRequest = function(appId, registerRequests, registeredKeys, callback, opt_timeoutSeconds) { - u2f.getPortSingleton_(function(port) { - var reqId = ++u2f.reqCounter_; - u2f.callbackMap_[reqId] = callback; - var timeoutSeconds = (typeof opt_timeoutSeconds !== 'undefined' ? - opt_timeoutSeconds : u2f.EXTENSION_TIMEOUT_SEC); - var req = u2f.formatRegisterRequest_( - appId, registeredKeys, registerRequests, timeoutSeconds, reqId); - port.postMessage(req); - }); -}; - - -/** - * Dispatches a message to the extension to find out the supported - * JS API version. - * If the user is on a mobile phone and is thus using Google Authenticator instead - * of the Chrome extension, don't send the request and simply return 0. - * @param {function((u2f.Error|u2f.GetJsApiVersionResponse))} callback - * @param {number=} opt_timeoutSeconds - */ -u2f.getApiVersion = function(callback, opt_timeoutSeconds) { - u2f.getPortSingleton_(function(port) { - // If we are using Android Google Authenticator or iOS client app, - // do not fire an intent to ask which JS API version to use. - if (port.getPortType) { - var apiVersion; - switch (port.getPortType()) { - case 'WrappedIosPort_': - case 'WrappedAuthenticatorPort_': - apiVersion = 1.1; - break; - - default: - apiVersion = 0; - break; - } - callback({ 'js_api_version': apiVersion }); - return; - } - var reqId = ++u2f.reqCounter_; - u2f.callbackMap_[reqId] = callback; - var req = { - type: u2f.MessageTypes.U2F_GET_API_VERSION_REQUEST, - timeoutSeconds: (typeof opt_timeoutSeconds !== 'undefined' ? - opt_timeoutSeconds : u2f.EXTENSION_TIMEOUT_SEC), - requestId: reqId - }; - port.postMessage(req); - }); -}; diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/includes/Yubico/U2F.php b/wp-content/upgrade-temp-backup/plugins/two-factor/includes/Yubico/U2F.php deleted file mode 100644 index bbb6e9a0..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/includes/Yubico/U2F.php +++ /dev/null @@ -1,507 +0,0 @@ -appId = $appId; - $this->attestDir = $attestDir; - } - - /** - * Called to get a registration request to send to a user. - * Returns an array of one registration request and a array of sign requests. - * - * @param array $registrations List of current registrations for this - * user, to prevent the user from registering the same authenticator several - * times. - * @return array An array of two elements, the first containing a - * RegisterRequest the second being an array of SignRequest - * @throws Error - */ - public function getRegisterData(array $registrations = array()) - { - $challenge = $this->createChallenge(); - $request = new RegisterRequest($challenge, $this->appId); - $signs = $this->getAuthenticateData($registrations); - return array($request, $signs); - } - - /** - * Called to verify and unpack a registration message. - * - * @param RegisterRequest $request this is a reply to - * @param object $response response from a user - * @param bool $includeCert set to true if the attestation certificate should be - * included in the returned Registration object - * @return Registration - * @throws Error - */ - public function doRegister($request, $response, $includeCert = true) - { - if( !is_object( $request ) ) { - throw new \InvalidArgumentException('$request of doRegister() method only accepts object.'); - } - - if( !is_object( $response ) ) { - throw new \InvalidArgumentException('$response of doRegister() method only accepts object.'); - } - - if( property_exists( $response, 'errorCode') && $response->errorCode !== 0 ) { - throw new Error('User-agent returned error. Error code: ' . $response->errorCode, ERR_BAD_UA_RETURNING ); - } - - if( !is_bool( $includeCert ) ) { - throw new \InvalidArgumentException('$include_cert of doRegister() method only accepts boolean.'); - } - - $rawReg = $this->base64u_decode($response->registrationData); - $regData = array_values(unpack('C*', $rawReg)); - $clientData = $this->base64u_decode($response->clientData); - $cli = json_decode($clientData); - - if($cli->challenge !== $request->challenge) { - throw new Error('Registration challenge does not match', ERR_UNMATCHED_CHALLENGE ); - } - - $registration = new Registration(); - $offs = 1; - $pubKey = substr($rawReg, $offs, PUBKEY_LEN); - $offs += PUBKEY_LEN; - // Decode the pubKey to make sure it's good. - $tmpKey = $this->pubkey_to_pem($pubKey); - if($tmpKey === null) { - throw new Error('Decoding of public key failed', ERR_PUBKEY_DECODE ); - } - $registration->publicKey = base64_encode($pubKey); - $khLen = $regData[$offs++]; - $kh = substr($rawReg, $offs, $khLen); - $offs += $khLen; - $registration->keyHandle = $this->base64u_encode($kh); - - // length of certificate is stored in byte 3 and 4 (excluding the first 4 bytes). - $certLen = 4; - $certLen += ($regData[$offs + 2] << 8); - $certLen += $regData[$offs + 3]; - - $rawCert = $this->fixSignatureUnusedBits(substr($rawReg, $offs, $certLen)); - $offs += $certLen; - $pemCert = "-----BEGIN CERTIFICATE-----\r\n"; - $pemCert .= chunk_split(base64_encode($rawCert), 64); - $pemCert .= "-----END CERTIFICATE-----"; - if($includeCert) { - $registration->certificate = base64_encode($rawCert); - } - if($this->attestDir) { - if(openssl_x509_checkpurpose($pemCert, -1, $this->get_certs()) !== true) { - throw new Error('Attestation certificate can not be validated', ERR_ATTESTATION_VERIFICATION ); - } - } - - if(!openssl_pkey_get_public($pemCert)) { - throw new Error('Decoding of public key failed', ERR_PUBKEY_DECODE ); - } - $signature = substr($rawReg, $offs); - - $dataToVerify = chr(0); - $dataToVerify .= hash('sha256', $request->appId, true); - $dataToVerify .= hash('sha256', $clientData, true); - $dataToVerify .= $kh; - $dataToVerify .= $pubKey; - - if(openssl_verify($dataToVerify, $signature, $pemCert, 'sha256') === 1) { - return $registration; - } else { - throw new Error('Attestation signature does not match', ERR_ATTESTATION_SIGNATURE ); - } - } - - /** - * Called to get an authentication request. - * - * @param array $registrations An array of the registrations to create authentication requests for. - * @return array An array of SignRequest - * @throws Error - */ - public function getAuthenticateData(array $registrations) - { - $sigs = array(); - $challenge = $this->createChallenge(); - foreach ($registrations as $reg) { - if( !is_object( $reg ) ) { - throw new \InvalidArgumentException('$registrations of getAuthenticateData() method only accepts array of object.'); - } - - $sig = new SignRequest(); - $sig->appId = $this->appId; - $sig->keyHandle = $reg->keyHandle; - $sig->challenge = $challenge; - $sigs[] = $sig; - } - return $sigs; - } - - /** - * Called to verify an authentication response - * - * @param array $requests An array of outstanding authentication requests - * @param array $registrations An array of current registrations - * @param object $response A response from the authenticator - * @return Registration - * @throws Error - * - * The Registration object returned on success contains an updated counter - * that should be saved for future authentications. - * If the Error returned is ERR_COUNTER_TOO_LOW this is an indication of - * token cloning or similar and appropriate action should be taken. - */ - public function doAuthenticate(array $requests, array $registrations, $response) - { - if( !is_object( $response ) ) { - throw new \InvalidArgumentException('$response of doAuthenticate() method only accepts object.'); - } - - if( property_exists( $response, 'errorCode') && $response->errorCode !== 0 ) { - throw new Error('User-agent returned error. Error code: ' . $response->errorCode, ERR_BAD_UA_RETURNING ); - } - - /** @var object|null $req */ - $req = null; - - /** @var object|null $reg */ - $reg = null; - - $clientData = $this->base64u_decode($response->clientData); - $decodedClient = json_decode($clientData); - foreach ($requests as $req) { - if( !is_object( $req ) ) { - throw new \InvalidArgumentException('$requests of doAuthenticate() method only accepts array of object.'); - } - - if($req->keyHandle === $response->keyHandle && $req->challenge === $decodedClient->challenge) { - break; - } - - $req = null; - } - if($req === null) { - throw new Error('No matching request found', ERR_NO_MATCHING_REQUEST ); - } - foreach ($registrations as $reg) { - if( !is_object( $reg ) ) { - throw new \InvalidArgumentException('$registrations of doAuthenticate() method only accepts array of object.'); - } - - if($reg->keyHandle === $response->keyHandle) { - break; - } - $reg = null; - } - if($reg === null) { - throw new Error('No matching registration found', ERR_NO_MATCHING_REGISTRATION ); - } - $pemKey = $this->pubkey_to_pem($this->base64u_decode($reg->publicKey)); - if($pemKey === null) { - throw new Error('Decoding of public key failed', ERR_PUBKEY_DECODE ); - } - - $signData = $this->base64u_decode($response->signatureData); - $dataToVerify = hash('sha256', $req->appId, true); - $dataToVerify .= substr($signData, 0, 5); - $dataToVerify .= hash('sha256', $clientData, true); - $signature = substr($signData, 5); - - if(openssl_verify($dataToVerify, $signature, $pemKey, 'sha256') === 1) { - $ctr = unpack("Nctr", substr($signData, 1, 4)); - $counter = $ctr['ctr']; - /* TODO: wrap-around should be handled somehow.. */ - if($counter > $reg->counter) { - $reg->counter = $counter; - return $reg; - } else { - throw new Error('Counter too low.', ERR_COUNTER_TOO_LOW ); - } - } else { - throw new Error('Authentication failed', ERR_AUTHENTICATION_FAILURE ); - } - } - - /** - * @return array - */ - private function get_certs() - { - $files = array(); - $dir = $this->attestDir; - if($dir && $handle = opendir($dir)) { - while(false !== ($entry = readdir($handle))) { - if(is_file("$dir/$entry")) { - $files[] = "$dir/$entry"; - } - } - closedir($handle); - } - return $files; - } - - /** - * @param string $data - * @return string - */ - private function base64u_encode($data) - { - return trim(strtr(base64_encode($data), '+/', '-_'), '='); - } - - /** - * @param string $data - * @return string - */ - private function base64u_decode($data) - { - return base64_decode(strtr($data, '-_', '+/')); - } - - /** - * @param string $key - * @return null|string - */ - private function pubkey_to_pem($key) - { - if(strlen($key) !== PUBKEY_LEN || $key[0] !== "\x04") { - return null; - } - - /* - * Convert the public key to binary DER format first - * Using the ECC SubjectPublicKeyInfo OIDs from RFC 5480 - * - * SEQUENCE(2 elem) 30 59 - * SEQUENCE(2 elem) 30 13 - * OID1.2.840.10045.2.1 (id-ecPublicKey) 06 07 2a 86 48 ce 3d 02 01 - * OID1.2.840.10045.3.1.7 (secp256r1) 06 08 2a 86 48 ce 3d 03 01 07 - * BIT STRING(520 bit) 03 42 ..key.. - */ - $der = "\x30\x59\x30\x13\x06\x07\x2a\x86\x48\xce\x3d\x02\x01"; - $der .= "\x06\x08\x2a\x86\x48\xce\x3d\x03\x01\x07\x03\x42"; - $der .= "\0".$key; - - $pem = "-----BEGIN PUBLIC KEY-----\r\n"; - $pem .= chunk_split(base64_encode($der), 64); - $pem .= "-----END PUBLIC KEY-----"; - - return $pem; - } - - /** - * @return string - * @throws Error - */ - private function createChallenge() - { - $challenge = openssl_random_pseudo_bytes(32, $crypto_strong ); - if( $crypto_strong !== true ) { - throw new Error('Unable to obtain a good source of randomness', ERR_BAD_RANDOM); - } - - $challenge = $this->base64u_encode( $challenge ); - - return $challenge; - } - - /** - * Fixes a certificate where the signature contains unused bits. - * - * @param string $cert - * @return mixed - */ - private function fixSignatureUnusedBits($cert) - { - if(in_array(hash('sha256', $cert), $this->FIXCERTS)) { - $cert[strlen($cert) - 257] = "\0"; - } - return $cert; - } -} - -/** - * Class for building a registration request - * - * @package u2flib_server - */ -class RegisterRequest -{ - /** Protocol version */ - public $version = U2F_VERSION; - - /** Registration challenge */ - public $challenge; - - /** Application id */ - public $appId; - - /** - * @param string $challenge - * @param string $appId - * @internal - */ - public function __construct($challenge, $appId) - { - $this->challenge = $challenge; - $this->appId = $appId; - } -} - -/** - * Class for building up an authentication request - * - * @package u2flib_server - */ -class SignRequest -{ - /** Protocol version */ - public $version = U2F_VERSION; - - /** Authentication challenge */ - public $challenge; - - /** Key handle of a registered authenticator */ - public $keyHandle; - - /** Application id */ - public $appId; -} - -/** - * Class returned for successful registrations - * - * @package u2flib_server - */ -class Registration -{ - /** The key handle of the registered authenticator */ - public $keyHandle; - - /** The public key of the registered authenticator */ - public $publicKey; - - /** The attestation certificate of the registered authenticator */ - public $certificate; - - /** The counter associated with this registration */ - public $counter = -1; -} - -/** - * Error class, returned on errors - * - * @package u2flib_server - */ -class Error extends \Exception -{ - /** - * Override constructor and make message and code mandatory - * @param string $message - * @param int $code - * @param \Exception|null $previous - */ - public function __construct($message, $code, ?\Exception $previous = null) { - parent::__construct($message, $code, $previous); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/includes/function.login-footer.php b/wp-content/upgrade-temp-backup/plugins/two-factor/includes/function.login-footer.php deleted file mode 100644 index a2876b02..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/includes/function.login-footer.php +++ /dev/null @@ -1,87 +0,0 @@ - -

            - %s', - esc_url( home_url( '/' ) ), - sprintf( - /* translators: %s: Site title. */ - _x( '← Go to %s', 'site' ), - get_bloginfo( 'title', 'display' ) - ) - ); - /** - * Filter the "Go to site" link displayed in the login page footer. - * - * @since 5.7.0 - * - * @param string $link HTML link to the home URL of the current site. - */ - echo apply_filters( 'login_site_html_link', $html_link ); - ?> -

            - ', '' ); - } - - ?> - . ?> - - - - -
            - - - - - ` element. - * Default 'Log In'. - * @param string $message Optional. Message to display in header. Default empty. - * @param WP_Error $wp_error Optional. The error to pass. Default is a WP_Error instance. - */ -function login_header( $title = 'Log In', $message = '', $wp_error = null ) { - global $error, $interim_login, $action; - - // Don't index any of these forms. - add_filter( 'wp_robots', 'wp_robots_sensitive_page' ); - add_action( 'login_head', 'wp_strict_cross_origin_referrer' ); - - add_action( 'login_head', 'wp_login_viewport_meta' ); - - if ( ! is_wp_error( $wp_error ) ) { - $wp_error = new WP_Error(); - } - - // Shake it! - $shake_error_codes = array( 'empty_password', 'empty_email', 'invalid_email', 'invalidcombo', 'empty_username', 'invalid_username', 'incorrect_password', 'retrieve_password_email_failure' ); - /** - * Filters the error codes array for shaking the login form. - * - * @since 3.0.0 - * - * @param array $shake_error_codes Error codes that shake the login form. - */ - $shake_error_codes = apply_filters( 'shake_error_codes', $shake_error_codes ); - - if ( $shake_error_codes && $wp_error->has_errors() && in_array( $wp_error->get_error_code(), $shake_error_codes, true ) ) { - add_action( 'login_footer', 'wp_shake_js', 12 ); - } - - $login_title = get_bloginfo( 'name', 'display' ); - - /* translators: Login screen title. 1: Login screen name, 2: Network or site name. */ - $login_title = sprintf( __( '%1$s ‹ %2$s — WordPress' ), $title, $login_title ); - - if ( wp_is_recovery_mode() ) { - /* translators: %s: Login screen title. */ - $login_title = sprintf( __( 'Recovery Mode — %s' ), $login_title ); - } - - /** - * Filters the title tag content for login page. - * - * @since 4.9.0 - * - * @param string $login_title The page title, with extra context added. - * @param string $title The original page title. - */ - $login_title = apply_filters( 'login_title', $login_title, $title ); - - ?> - > - - - <?php echo $login_title; ?> - get_error_code() ) { - ?> - - - - - - - - -
            -

            - add( 'error', $error ); - unset( $error ); - } - - if ( $wp_error->has_errors() ) { - $errors = ''; - $messages = ''; - - foreach ( $wp_error->get_error_codes() as $code ) { - $severity = $wp_error->get_error_data( $code ); - foreach ( $wp_error->get_error_messages( $code ) as $error_message ) { - if ( 'message' === $severity ) { - $messages .= ' ' . $error_message . "
            \n"; - } else { - $errors .= ' ' . $error_message . "
            \n"; - } - } - } - - if ( ! empty( $errors ) ) { - /** - * Filters the error messages displayed above the login form. - * - * @since 2.1.0 - * - * @param string $errors Login error message. - */ - echo '
            ' . apply_filters( 'login_errors', $errors ) . "
            \n"; - } - - if ( ! empty( $messages ) ) { - /** - * Filters instructional messages displayed above the login form. - * - * @since 2.5.0 - * - * @param string $messages Login messages. - */ - echo '

            ' . apply_filters( 'login_messages', $messages ) . "

            \n"; - } - } -} // End of login_header(). - -/** - * Outputs the viewport meta tag for the login page. - * - * @since 3.7.0 - */ -function wp_login_viewport_meta() { - ?> - - = 7) { - setupTypeNumber(test); - } - - if (_dataCache == null) { - _dataCache = createData(_typeNumber, _errorCorrectionLevel, _dataList); - } - - mapData(_dataCache, maskPattern); - }; - - var setupPositionProbePattern = function(row, col) { - - for (var r = -1; r <= 7; r += 1) { - - if (row + r <= -1 || _moduleCount <= row + r) continue; - - for (var c = -1; c <= 7; c += 1) { - - if (col + c <= -1 || _moduleCount <= col + c) continue; - - if ( (0 <= r && r <= 6 && (c == 0 || c == 6) ) - || (0 <= c && c <= 6 && (r == 0 || r == 6) ) - || (2 <= r && r <= 4 && 2 <= c && c <= 4) ) { - _modules[row + r][col + c] = true; - } else { - _modules[row + r][col + c] = false; - } - } - } - }; - - var getBestMaskPattern = function() { - - var minLostPoint = 0; - var pattern = 0; - - for (var i = 0; i < 8; i += 1) { - - makeImpl(true, i); - - var lostPoint = QRUtil.getLostPoint(_this); - - if (i == 0 || minLostPoint > lostPoint) { - minLostPoint = lostPoint; - pattern = i; - } - } - - return pattern; - }; - - var setupTimingPattern = function() { - - for (var r = 8; r < _moduleCount - 8; r += 1) { - if (_modules[r][6] != null) { - continue; - } - _modules[r][6] = (r % 2 == 0); - } - - for (var c = 8; c < _moduleCount - 8; c += 1) { - if (_modules[6][c] != null) { - continue; - } - _modules[6][c] = (c % 2 == 0); - } - }; - - var setupPositionAdjustPattern = function() { - - var pos = QRUtil.getPatternPosition(_typeNumber); - - for (var i = 0; i < pos.length; i += 1) { - - for (var j = 0; j < pos.length; j += 1) { - - var row = pos[i]; - var col = pos[j]; - - if (_modules[row][col] != null) { - continue; - } - - for (var r = -2; r <= 2; r += 1) { - - for (var c = -2; c <= 2; c += 1) { - - if (r == -2 || r == 2 || c == -2 || c == 2 - || (r == 0 && c == 0) ) { - _modules[row + r][col + c] = true; - } else { - _modules[row + r][col + c] = false; - } - } - } - } - } - }; - - var setupTypeNumber = function(test) { - - var bits = QRUtil.getBCHTypeNumber(_typeNumber); - - for (var i = 0; i < 18; i += 1) { - var mod = (!test && ( (bits >> i) & 1) == 1); - _modules[Math.floor(i / 3)][i % 3 + _moduleCount - 8 - 3] = mod; - } - - for (var i = 0; i < 18; i += 1) { - var mod = (!test && ( (bits >> i) & 1) == 1); - _modules[i % 3 + _moduleCount - 8 - 3][Math.floor(i / 3)] = mod; - } - }; - - var setupTypeInfo = function(test, maskPattern) { - - var data = (_errorCorrectionLevel << 3) | maskPattern; - var bits = QRUtil.getBCHTypeInfo(data); - - // vertical - for (var i = 0; i < 15; i += 1) { - - var mod = (!test && ( (bits >> i) & 1) == 1); - - if (i < 6) { - _modules[i][8] = mod; - } else if (i < 8) { - _modules[i + 1][8] = mod; - } else { - _modules[_moduleCount - 15 + i][8] = mod; - } - } - - // horizontal - for (var i = 0; i < 15; i += 1) { - - var mod = (!test && ( (bits >> i) & 1) == 1); - - if (i < 8) { - _modules[8][_moduleCount - i - 1] = mod; - } else if (i < 9) { - _modules[8][15 - i - 1 + 1] = mod; - } else { - _modules[8][15 - i - 1] = mod; - } - } - - // fixed module - _modules[_moduleCount - 8][8] = (!test); - }; - - var mapData = function(data, maskPattern) { - - var inc = -1; - var row = _moduleCount - 1; - var bitIndex = 7; - var byteIndex = 0; - var maskFunc = QRUtil.getMaskFunction(maskPattern); - - for (var col = _moduleCount - 1; col > 0; col -= 2) { - - if (col == 6) col -= 1; - - while (true) { - - for (var c = 0; c < 2; c += 1) { - - if (_modules[row][col - c] == null) { - - var dark = false; - - if (byteIndex < data.length) { - dark = ( ( (data[byteIndex] >>> bitIndex) & 1) == 1); - } - - var mask = maskFunc(row, col - c); - - if (mask) { - dark = !dark; - } - - _modules[row][col - c] = dark; - bitIndex -= 1; - - if (bitIndex == -1) { - byteIndex += 1; - bitIndex = 7; - } - } - } - - row += inc; - - if (row < 0 || _moduleCount <= row) { - row -= inc; - inc = -inc; - break; - } - } - } - }; - - var createBytes = function(buffer, rsBlocks) { - - var offset = 0; - - var maxDcCount = 0; - var maxEcCount = 0; - - var dcdata = new Array(rsBlocks.length); - var ecdata = new Array(rsBlocks.length); - - for (var r = 0; r < rsBlocks.length; r += 1) { - - var dcCount = rsBlocks[r].dataCount; - var ecCount = rsBlocks[r].totalCount - dcCount; - - maxDcCount = Math.max(maxDcCount, dcCount); - maxEcCount = Math.max(maxEcCount, ecCount); - - dcdata[r] = new Array(dcCount); - - for (var i = 0; i < dcdata[r].length; i += 1) { - dcdata[r][i] = 0xff & buffer.getBuffer()[i + offset]; - } - offset += dcCount; - - var rsPoly = QRUtil.getErrorCorrectPolynomial(ecCount); - var rawPoly = qrPolynomial(dcdata[r], rsPoly.getLength() - 1); - - var modPoly = rawPoly.mod(rsPoly); - ecdata[r] = new Array(rsPoly.getLength() - 1); - for (var i = 0; i < ecdata[r].length; i += 1) { - var modIndex = i + modPoly.getLength() - ecdata[r].length; - ecdata[r][i] = (modIndex >= 0)? modPoly.getAt(modIndex) : 0; - } - } - - var totalCodeCount = 0; - for (var i = 0; i < rsBlocks.length; i += 1) { - totalCodeCount += rsBlocks[i].totalCount; - } - - var data = new Array(totalCodeCount); - var index = 0; - - for (var i = 0; i < maxDcCount; i += 1) { - for (var r = 0; r < rsBlocks.length; r += 1) { - if (i < dcdata[r].length) { - data[index] = dcdata[r][i]; - index += 1; - } - } - } - - for (var i = 0; i < maxEcCount; i += 1) { - for (var r = 0; r < rsBlocks.length; r += 1) { - if (i < ecdata[r].length) { - data[index] = ecdata[r][i]; - index += 1; - } - } - } - - return data; - }; - - var createData = function(typeNumber, errorCorrectionLevel, dataList) { - - var rsBlocks = QRRSBlock.getRSBlocks(typeNumber, errorCorrectionLevel); - - var buffer = qrBitBuffer(); - - for (var i = 0; i < dataList.length; i += 1) { - var data = dataList[i]; - buffer.put(data.getMode(), 4); - buffer.put(data.getLength(), QRUtil.getLengthInBits(data.getMode(), typeNumber) ); - data.write(buffer); - } - - // calc num max data. - var totalDataCount = 0; - for (var i = 0; i < rsBlocks.length; i += 1) { - totalDataCount += rsBlocks[i].dataCount; - } - - if (buffer.getLengthInBits() > totalDataCount * 8) { - throw 'code length overflow. (' - + buffer.getLengthInBits() - + '>' - + totalDataCount * 8 - + ')'; - } - - // end code - if (buffer.getLengthInBits() + 4 <= totalDataCount * 8) { - buffer.put(0, 4); - } - - // padding - while (buffer.getLengthInBits() % 8 != 0) { - buffer.putBit(false); - } - - // padding - while (true) { - - if (buffer.getLengthInBits() >= totalDataCount * 8) { - break; - } - buffer.put(PAD0, 8); - - if (buffer.getLengthInBits() >= totalDataCount * 8) { - break; - } - buffer.put(PAD1, 8); - } - - return createBytes(buffer, rsBlocks); - }; - - _this.addData = function(data, mode) { - - mode = mode || 'Byte'; - - var newData = null; - - switch(mode) { - case 'Numeric' : - newData = qrNumber(data); - break; - case 'Alphanumeric' : - newData = qrAlphaNum(data); - break; - case 'Byte' : - newData = qr8BitByte(data); - break; - case 'Kanji' : - newData = qrKanji(data); - break; - default : - throw 'mode:' + mode; - } - - _dataList.push(newData); - _dataCache = null; - }; - - _this.isDark = function(row, col) { - if (row < 0 || _moduleCount <= row || col < 0 || _moduleCount <= col) { - throw row + ',' + col; - } - return _modules[row][col]; - }; - - _this.getModuleCount = function() { - return _moduleCount; - }; - - _this.make = function() { - if (_typeNumber < 1) { - var typeNumber = 1; - - for (; typeNumber < 40; typeNumber++) { - var rsBlocks = QRRSBlock.getRSBlocks(typeNumber, _errorCorrectionLevel); - var buffer = qrBitBuffer(); - - for (var i = 0; i < _dataList.length; i++) { - var data = _dataList[i]; - buffer.put(data.getMode(), 4); - buffer.put(data.getLength(), QRUtil.getLengthInBits(data.getMode(), typeNumber) ); - data.write(buffer); - } - - var totalDataCount = 0; - for (var i = 0; i < rsBlocks.length; i++) { - totalDataCount += rsBlocks[i].dataCount; - } - - if (buffer.getLengthInBits() <= totalDataCount * 8) { - break; - } - } - - _typeNumber = typeNumber; - } - - makeImpl(false, getBestMaskPattern() ); - }; - - _this.createTableTag = function(cellSize, margin) { - - cellSize = cellSize || 2; - margin = (typeof margin == 'undefined')? cellSize * 4 : margin; - - var qrHtml = ''; - - qrHtml += ''; - qrHtml += ''; - - for (var r = 0; r < _this.getModuleCount(); r += 1) { - - qrHtml += ''; - - for (var c = 0; c < _this.getModuleCount(); c += 1) { - qrHtml += ''; - } - - qrHtml += ''; - qrHtml += '
            '; - } - - qrHtml += '
            '; - - return qrHtml; - }; - - _this.createSvgTag = function(cellSize, margin, alt, title) { - - var opts = {}; - if (typeof arguments[0] == 'object') { - // Called by options. - opts = arguments[0]; - // overwrite cellSize and margin. - cellSize = opts.cellSize; - margin = opts.margin; - alt = opts.alt; - title = opts.title; - } - - cellSize = cellSize || 2; - margin = (typeof margin == 'undefined')? cellSize * 4 : margin; - - // Compose alt property surrogate - alt = (typeof alt === 'string') ? {text: alt} : alt || {}; - alt.text = alt.text || null; - alt.id = (alt.text) ? alt.id || 'qrcode-description' : null; - - // Compose title property surrogate - title = (typeof title === 'string') ? {text: title} : title || {}; - title.text = title.text || null; - title.id = (title.text) ? title.id || 'qrcode-title' : null; - - var size = _this.getModuleCount() * cellSize + margin * 2; - var c, mc, r, mr, qrSvg='', rect; - - rect = 'l' + cellSize + ',0 0,' + cellSize + - ' -' + cellSize + ',0 0,-' + cellSize + 'z '; - - qrSvg += '' + - escapeXml(title.text) + '' : ''; - qrSvg += (alt.text) ? '' + - escapeXml(alt.text) + '' : ''; - qrSvg += ''; - qrSvg += ''; - qrSvg += ''; - - return qrSvg; - }; - - _this.createDataURL = function(cellSize, margin) { - - cellSize = cellSize || 2; - margin = (typeof margin == 'undefined')? cellSize * 4 : margin; - - var size = _this.getModuleCount() * cellSize + margin * 2; - var min = margin; - var max = size - margin; - - return createDataURL(size, size, function(x, y) { - if (min <= x && x < max && min <= y && y < max) { - var c = Math.floor( (x - min) / cellSize); - var r = Math.floor( (y - min) / cellSize); - return _this.isDark(r, c)? 0 : 1; - } else { - return 1; - } - } ); - }; - - _this.createImgTag = function(cellSize, margin, alt) { - - cellSize = cellSize || 2; - margin = (typeof margin == 'undefined')? cellSize * 4 : margin; - - var size = _this.getModuleCount() * cellSize + margin * 2; - - var img = ''; - img += '': escaped += '>'; break; - case '&': escaped += '&'; break; - case '"': escaped += '"'; break; - default : escaped += c; break; - } - } - return escaped; - }; - - var _createHalfASCII = function(margin) { - var cellSize = 1; - margin = (typeof margin == 'undefined')? cellSize * 2 : margin; - - var size = _this.getModuleCount() * cellSize + margin * 2; - var min = margin; - var max = size - margin; - - var y, x, r1, r2, p; - - var blocks = { - '██': '█', - '█ ': '▀', - ' █': '▄', - ' ': ' ' - }; - - var blocksLastLineNoMargin = { - '██': '▀', - '█ ': '▀', - ' █': ' ', - ' ': ' ' - }; - - var ascii = ''; - for (y = 0; y < size; y += 2) { - r1 = Math.floor((y - min) / cellSize); - r2 = Math.floor((y + 1 - min) / cellSize); - for (x = 0; x < size; x += 1) { - p = '█'; - - if (min <= x && x < max && min <= y && y < max && _this.isDark(r1, Math.floor((x - min) / cellSize))) { - p = ' '; - } - - if (min <= x && x < max && min <= y+1 && y+1 < max && _this.isDark(r2, Math.floor((x - min) / cellSize))) { - p += ' '; - } - else { - p += '█'; - } - - // Output 2 characters per pixel, to create full square. 1 character per pixels gives only half width of square. - ascii += (margin < 1 && y+1 >= max) ? blocksLastLineNoMargin[p] : blocks[p]; - } - - ascii += '\n'; - } - - if (size % 2 && margin > 0) { - return ascii.substring(0, ascii.length - size - 1) + Array(size+1).join('▀'); - } - - return ascii.substring(0, ascii.length-1); - }; - - _this.createASCII = function(cellSize, margin) { - cellSize = cellSize || 1; - - if (cellSize < 2) { - return _createHalfASCII(margin); - } - - cellSize -= 1; - margin = (typeof margin == 'undefined')? cellSize * 2 : margin; - - var size = _this.getModuleCount() * cellSize + margin * 2; - var min = margin; - var max = size - margin; - - var y, x, r, p; - - var white = Array(cellSize+1).join('██'); - var black = Array(cellSize+1).join(' '); - - var ascii = ''; - var line = ''; - for (y = 0; y < size; y += 1) { - r = Math.floor( (y - min) / cellSize); - line = ''; - for (x = 0; x < size; x += 1) { - p = 1; - - if (min <= x && x < max && min <= y && y < max && _this.isDark(r, Math.floor((x - min) / cellSize))) { - p = 0; - } - - // Output 2 characters per pixel, to create full square. 1 character per pixels gives only half width of square. - line += p ? white : black; - } - - for (r = 0; r < cellSize; r += 1) { - ascii += line + '\n'; - } - } - - return ascii.substring(0, ascii.length-1); - }; - - _this.renderTo2dContext = function(context, cellSize) { - cellSize = cellSize || 2; - var length = _this.getModuleCount(); - for (var row = 0; row < length; row++) { - for (var col = 0; col < length; col++) { - context.fillStyle = _this.isDark(row, col) ? 'black' : 'white'; - context.fillRect(row * cellSize, col * cellSize, cellSize, cellSize); - } - } - } - - return _this; - }; - - //--------------------------------------------------------------------- - // qrcode.stringToBytes - //--------------------------------------------------------------------- - - qrcode.stringToBytesFuncs = { - 'default' : function(s) { - var bytes = []; - for (var i = 0; i < s.length; i += 1) { - var c = s.charCodeAt(i); - bytes.push(c & 0xff); - } - return bytes; - } - }; - - qrcode.stringToBytes = qrcode.stringToBytesFuncs['default']; - - //--------------------------------------------------------------------- - // qrcode.createStringToBytes - //--------------------------------------------------------------------- - - /** - * @param unicodeData base64 string of byte array. - * [16bit Unicode],[16bit Bytes], ... - * @param numChars - */ - qrcode.createStringToBytes = function(unicodeData, numChars) { - - // create conversion map. - - var unicodeMap = function() { - - var bin = base64DecodeInputStream(unicodeData); - var read = function() { - var b = bin.read(); - if (b == -1) throw 'eof'; - return b; - }; - - var count = 0; - var unicodeMap = {}; - while (true) { - var b0 = bin.read(); - if (b0 == -1) break; - var b1 = read(); - var b2 = read(); - var b3 = read(); - var k = String.fromCharCode( (b0 << 8) | b1); - var v = (b2 << 8) | b3; - unicodeMap[k] = v; - count += 1; - } - if (count != numChars) { - throw count + ' != ' + numChars; - } - - return unicodeMap; - }(); - - var unknownChar = '?'.charCodeAt(0); - - return function(s) { - var bytes = []; - for (var i = 0; i < s.length; i += 1) { - var c = s.charCodeAt(i); - if (c < 128) { - bytes.push(c); - } else { - var b = unicodeMap[s.charAt(i)]; - if (typeof b == 'number') { - if ( (b & 0xff) == b) { - // 1byte - bytes.push(b); - } else { - // 2bytes - bytes.push(b >>> 8); - bytes.push(b & 0xff); - } - } else { - bytes.push(unknownChar); - } - } - } - return bytes; - }; - }; - - //--------------------------------------------------------------------- - // QRMode - //--------------------------------------------------------------------- - - var QRMode = { - MODE_NUMBER : 1 << 0, - MODE_ALPHA_NUM : 1 << 1, - MODE_8BIT_BYTE : 1 << 2, - MODE_KANJI : 1 << 3 - }; - - //--------------------------------------------------------------------- - // QRErrorCorrectionLevel - //--------------------------------------------------------------------- - - var QRErrorCorrectionLevel = { - L : 1, - M : 0, - Q : 3, - H : 2 - }; - - //--------------------------------------------------------------------- - // QRMaskPattern - //--------------------------------------------------------------------- - - var QRMaskPattern = { - PATTERN000 : 0, - PATTERN001 : 1, - PATTERN010 : 2, - PATTERN011 : 3, - PATTERN100 : 4, - PATTERN101 : 5, - PATTERN110 : 6, - PATTERN111 : 7 - }; - - //--------------------------------------------------------------------- - // QRUtil - //--------------------------------------------------------------------- - - var QRUtil = function() { - - var PATTERN_POSITION_TABLE = [ - [], - [6, 18], - [6, 22], - [6, 26], - [6, 30], - [6, 34], - [6, 22, 38], - [6, 24, 42], - [6, 26, 46], - [6, 28, 50], - [6, 30, 54], - [6, 32, 58], - [6, 34, 62], - [6, 26, 46, 66], - [6, 26, 48, 70], - [6, 26, 50, 74], - [6, 30, 54, 78], - [6, 30, 56, 82], - [6, 30, 58, 86], - [6, 34, 62, 90], - [6, 28, 50, 72, 94], - [6, 26, 50, 74, 98], - [6, 30, 54, 78, 102], - [6, 28, 54, 80, 106], - [6, 32, 58, 84, 110], - [6, 30, 58, 86, 114], - [6, 34, 62, 90, 118], - [6, 26, 50, 74, 98, 122], - [6, 30, 54, 78, 102, 126], - [6, 26, 52, 78, 104, 130], - [6, 30, 56, 82, 108, 134], - [6, 34, 60, 86, 112, 138], - [6, 30, 58, 86, 114, 142], - [6, 34, 62, 90, 118, 146], - [6, 30, 54, 78, 102, 126, 150], - [6, 24, 50, 76, 102, 128, 154], - [6, 28, 54, 80, 106, 132, 158], - [6, 32, 58, 84, 110, 136, 162], - [6, 26, 54, 82, 110, 138, 166], - [6, 30, 58, 86, 114, 142, 170] - ]; - var G15 = (1 << 10) | (1 << 8) | (1 << 5) | (1 << 4) | (1 << 2) | (1 << 1) | (1 << 0); - var G18 = (1 << 12) | (1 << 11) | (1 << 10) | (1 << 9) | (1 << 8) | (1 << 5) | (1 << 2) | (1 << 0); - var G15_MASK = (1 << 14) | (1 << 12) | (1 << 10) | (1 << 4) | (1 << 1); - - var _this = {}; - - var getBCHDigit = function(data) { - var digit = 0; - while (data != 0) { - digit += 1; - data >>>= 1; - } - return digit; - }; - - _this.getBCHTypeInfo = function(data) { - var d = data << 10; - while (getBCHDigit(d) - getBCHDigit(G15) >= 0) { - d ^= (G15 << (getBCHDigit(d) - getBCHDigit(G15) ) ); - } - return ( (data << 10) | d) ^ G15_MASK; - }; - - _this.getBCHTypeNumber = function(data) { - var d = data << 12; - while (getBCHDigit(d) - getBCHDigit(G18) >= 0) { - d ^= (G18 << (getBCHDigit(d) - getBCHDigit(G18) ) ); - } - return (data << 12) | d; - }; - - _this.getPatternPosition = function(typeNumber) { - return PATTERN_POSITION_TABLE[typeNumber - 1]; - }; - - _this.getMaskFunction = function(maskPattern) { - - switch (maskPattern) { - - case QRMaskPattern.PATTERN000 : - return function(i, j) { return (i + j) % 2 == 0; }; - case QRMaskPattern.PATTERN001 : - return function(i, j) { return i % 2 == 0; }; - case QRMaskPattern.PATTERN010 : - return function(i, j) { return j % 3 == 0; }; - case QRMaskPattern.PATTERN011 : - return function(i, j) { return (i + j) % 3 == 0; }; - case QRMaskPattern.PATTERN100 : - return function(i, j) { return (Math.floor(i / 2) + Math.floor(j / 3) ) % 2 == 0; }; - case QRMaskPattern.PATTERN101 : - return function(i, j) { return (i * j) % 2 + (i * j) % 3 == 0; }; - case QRMaskPattern.PATTERN110 : - return function(i, j) { return ( (i * j) % 2 + (i * j) % 3) % 2 == 0; }; - case QRMaskPattern.PATTERN111 : - return function(i, j) { return ( (i * j) % 3 + (i + j) % 2) % 2 == 0; }; - - default : - throw 'bad maskPattern:' + maskPattern; - } - }; - - _this.getErrorCorrectPolynomial = function(errorCorrectLength) { - var a = qrPolynomial([1], 0); - for (var i = 0; i < errorCorrectLength; i += 1) { - a = a.multiply(qrPolynomial([1, QRMath.gexp(i)], 0) ); - } - return a; - }; - - _this.getLengthInBits = function(mode, type) { - - if (1 <= type && type < 10) { - - // 1 - 9 - - switch(mode) { - case QRMode.MODE_NUMBER : return 10; - case QRMode.MODE_ALPHA_NUM : return 9; - case QRMode.MODE_8BIT_BYTE : return 8; - case QRMode.MODE_KANJI : return 8; - default : - throw 'mode:' + mode; - } - - } else if (type < 27) { - - // 10 - 26 - - switch(mode) { - case QRMode.MODE_NUMBER : return 12; - case QRMode.MODE_ALPHA_NUM : return 11; - case QRMode.MODE_8BIT_BYTE : return 16; - case QRMode.MODE_KANJI : return 10; - default : - throw 'mode:' + mode; - } - - } else if (type < 41) { - - // 27 - 40 - - switch(mode) { - case QRMode.MODE_NUMBER : return 14; - case QRMode.MODE_ALPHA_NUM : return 13; - case QRMode.MODE_8BIT_BYTE : return 16; - case QRMode.MODE_KANJI : return 12; - default : - throw 'mode:' + mode; - } - - } else { - throw 'type:' + type; - } - }; - - _this.getLostPoint = function(qrcode) { - - var moduleCount = qrcode.getModuleCount(); - - var lostPoint = 0; - - // LEVEL1 - - for (var row = 0; row < moduleCount; row += 1) { - for (var col = 0; col < moduleCount; col += 1) { - - var sameCount = 0; - var dark = qrcode.isDark(row, col); - - for (var r = -1; r <= 1; r += 1) { - - if (row + r < 0 || moduleCount <= row + r) { - continue; - } - - for (var c = -1; c <= 1; c += 1) { - - if (col + c < 0 || moduleCount <= col + c) { - continue; - } - - if (r == 0 && c == 0) { - continue; - } - - if (dark == qrcode.isDark(row + r, col + c) ) { - sameCount += 1; - } - } - } - - if (sameCount > 5) { - lostPoint += (3 + sameCount - 5); - } - } - }; - - // LEVEL2 - - for (var row = 0; row < moduleCount - 1; row += 1) { - for (var col = 0; col < moduleCount - 1; col += 1) { - var count = 0; - if (qrcode.isDark(row, col) ) count += 1; - if (qrcode.isDark(row + 1, col) ) count += 1; - if (qrcode.isDark(row, col + 1) ) count += 1; - if (qrcode.isDark(row + 1, col + 1) ) count += 1; - if (count == 0 || count == 4) { - lostPoint += 3; - } - } - } - - // LEVEL3 - - for (var row = 0; row < moduleCount; row += 1) { - for (var col = 0; col < moduleCount - 6; col += 1) { - if (qrcode.isDark(row, col) - && !qrcode.isDark(row, col + 1) - && qrcode.isDark(row, col + 2) - && qrcode.isDark(row, col + 3) - && qrcode.isDark(row, col + 4) - && !qrcode.isDark(row, col + 5) - && qrcode.isDark(row, col + 6) ) { - lostPoint += 40; - } - } - } - - for (var col = 0; col < moduleCount; col += 1) { - for (var row = 0; row < moduleCount - 6; row += 1) { - if (qrcode.isDark(row, col) - && !qrcode.isDark(row + 1, col) - && qrcode.isDark(row + 2, col) - && qrcode.isDark(row + 3, col) - && qrcode.isDark(row + 4, col) - && !qrcode.isDark(row + 5, col) - && qrcode.isDark(row + 6, col) ) { - lostPoint += 40; - } - } - } - - // LEVEL4 - - var darkCount = 0; - - for (var col = 0; col < moduleCount; col += 1) { - for (var row = 0; row < moduleCount; row += 1) { - if (qrcode.isDark(row, col) ) { - darkCount += 1; - } - } - } - - var ratio = Math.abs(100 * darkCount / moduleCount / moduleCount - 50) / 5; - lostPoint += ratio * 10; - - return lostPoint; - }; - - return _this; - }(); - - //--------------------------------------------------------------------- - // QRMath - //--------------------------------------------------------------------- - - var QRMath = function() { - - var EXP_TABLE = new Array(256); - var LOG_TABLE = new Array(256); - - // initialize tables - for (var i = 0; i < 8; i += 1) { - EXP_TABLE[i] = 1 << i; - } - for (var i = 8; i < 256; i += 1) { - EXP_TABLE[i] = EXP_TABLE[i - 4] - ^ EXP_TABLE[i - 5] - ^ EXP_TABLE[i - 6] - ^ EXP_TABLE[i - 8]; - } - for (var i = 0; i < 255; i += 1) { - LOG_TABLE[EXP_TABLE[i] ] = i; - } - - var _this = {}; - - _this.glog = function(n) { - - if (n < 1) { - throw 'glog(' + n + ')'; - } - - return LOG_TABLE[n]; - }; - - _this.gexp = function(n) { - - while (n < 0) { - n += 255; - } - - while (n >= 256) { - n -= 255; - } - - return EXP_TABLE[n]; - }; - - return _this; - }(); - - //--------------------------------------------------------------------- - // qrPolynomial - //--------------------------------------------------------------------- - - function qrPolynomial(num, shift) { - - if (typeof num.length == 'undefined') { - throw num.length + '/' + shift; - } - - var _num = function() { - var offset = 0; - while (offset < num.length && num[offset] == 0) { - offset += 1; - } - var _num = new Array(num.length - offset + shift); - for (var i = 0; i < num.length - offset; i += 1) { - _num[i] = num[i + offset]; - } - return _num; - }(); - - var _this = {}; - - _this.getAt = function(index) { - return _num[index]; - }; - - _this.getLength = function() { - return _num.length; - }; - - _this.multiply = function(e) { - - var num = new Array(_this.getLength() + e.getLength() - 1); - - for (var i = 0; i < _this.getLength(); i += 1) { - for (var j = 0; j < e.getLength(); j += 1) { - num[i + j] ^= QRMath.gexp(QRMath.glog(_this.getAt(i) ) + QRMath.glog(e.getAt(j) ) ); - } - } - - return qrPolynomial(num, 0); - }; - - _this.mod = function(e) { - - if (_this.getLength() - e.getLength() < 0) { - return _this; - } - - var ratio = QRMath.glog(_this.getAt(0) ) - QRMath.glog(e.getAt(0) ); - - var num = new Array(_this.getLength() ); - for (var i = 0; i < _this.getLength(); i += 1) { - num[i] = _this.getAt(i); - } - - for (var i = 0; i < e.getLength(); i += 1) { - num[i] ^= QRMath.gexp(QRMath.glog(e.getAt(i) ) + ratio); - } - - // recursive call - return qrPolynomial(num, 0).mod(e); - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // QRRSBlock - //--------------------------------------------------------------------- - - var QRRSBlock = function() { - - var RS_BLOCK_TABLE = [ - - // L - // M - // Q - // H - - // 1 - [1, 26, 19], - [1, 26, 16], - [1, 26, 13], - [1, 26, 9], - - // 2 - [1, 44, 34], - [1, 44, 28], - [1, 44, 22], - [1, 44, 16], - - // 3 - [1, 70, 55], - [1, 70, 44], - [2, 35, 17], - [2, 35, 13], - - // 4 - [1, 100, 80], - [2, 50, 32], - [2, 50, 24], - [4, 25, 9], - - // 5 - [1, 134, 108], - [2, 67, 43], - [2, 33, 15, 2, 34, 16], - [2, 33, 11, 2, 34, 12], - - // 6 - [2, 86, 68], - [4, 43, 27], - [4, 43, 19], - [4, 43, 15], - - // 7 - [2, 98, 78], - [4, 49, 31], - [2, 32, 14, 4, 33, 15], - [4, 39, 13, 1, 40, 14], - - // 8 - [2, 121, 97], - [2, 60, 38, 2, 61, 39], - [4, 40, 18, 2, 41, 19], - [4, 40, 14, 2, 41, 15], - - // 9 - [2, 146, 116], - [3, 58, 36, 2, 59, 37], - [4, 36, 16, 4, 37, 17], - [4, 36, 12, 4, 37, 13], - - // 10 - [2, 86, 68, 2, 87, 69], - [4, 69, 43, 1, 70, 44], - [6, 43, 19, 2, 44, 20], - [6, 43, 15, 2, 44, 16], - - // 11 - [4, 101, 81], - [1, 80, 50, 4, 81, 51], - [4, 50, 22, 4, 51, 23], - [3, 36, 12, 8, 37, 13], - - // 12 - [2, 116, 92, 2, 117, 93], - [6, 58, 36, 2, 59, 37], - [4, 46, 20, 6, 47, 21], - [7, 42, 14, 4, 43, 15], - - // 13 - [4, 133, 107], - [8, 59, 37, 1, 60, 38], - [8, 44, 20, 4, 45, 21], - [12, 33, 11, 4, 34, 12], - - // 14 - [3, 145, 115, 1, 146, 116], - [4, 64, 40, 5, 65, 41], - [11, 36, 16, 5, 37, 17], - [11, 36, 12, 5, 37, 13], - - // 15 - [5, 109, 87, 1, 110, 88], - [5, 65, 41, 5, 66, 42], - [5, 54, 24, 7, 55, 25], - [11, 36, 12, 7, 37, 13], - - // 16 - [5, 122, 98, 1, 123, 99], - [7, 73, 45, 3, 74, 46], - [15, 43, 19, 2, 44, 20], - [3, 45, 15, 13, 46, 16], - - // 17 - [1, 135, 107, 5, 136, 108], - [10, 74, 46, 1, 75, 47], - [1, 50, 22, 15, 51, 23], - [2, 42, 14, 17, 43, 15], - - // 18 - [5, 150, 120, 1, 151, 121], - [9, 69, 43, 4, 70, 44], - [17, 50, 22, 1, 51, 23], - [2, 42, 14, 19, 43, 15], - - // 19 - [3, 141, 113, 4, 142, 114], - [3, 70, 44, 11, 71, 45], - [17, 47, 21, 4, 48, 22], - [9, 39, 13, 16, 40, 14], - - // 20 - [3, 135, 107, 5, 136, 108], - [3, 67, 41, 13, 68, 42], - [15, 54, 24, 5, 55, 25], - [15, 43, 15, 10, 44, 16], - - // 21 - [4, 144, 116, 4, 145, 117], - [17, 68, 42], - [17, 50, 22, 6, 51, 23], - [19, 46, 16, 6, 47, 17], - - // 22 - [2, 139, 111, 7, 140, 112], - [17, 74, 46], - [7, 54, 24, 16, 55, 25], - [34, 37, 13], - - // 23 - [4, 151, 121, 5, 152, 122], - [4, 75, 47, 14, 76, 48], - [11, 54, 24, 14, 55, 25], - [16, 45, 15, 14, 46, 16], - - // 24 - [6, 147, 117, 4, 148, 118], - [6, 73, 45, 14, 74, 46], - [11, 54, 24, 16, 55, 25], - [30, 46, 16, 2, 47, 17], - - // 25 - [8, 132, 106, 4, 133, 107], - [8, 75, 47, 13, 76, 48], - [7, 54, 24, 22, 55, 25], - [22, 45, 15, 13, 46, 16], - - // 26 - [10, 142, 114, 2, 143, 115], - [19, 74, 46, 4, 75, 47], - [28, 50, 22, 6, 51, 23], - [33, 46, 16, 4, 47, 17], - - // 27 - [8, 152, 122, 4, 153, 123], - [22, 73, 45, 3, 74, 46], - [8, 53, 23, 26, 54, 24], - [12, 45, 15, 28, 46, 16], - - // 28 - [3, 147, 117, 10, 148, 118], - [3, 73, 45, 23, 74, 46], - [4, 54, 24, 31, 55, 25], - [11, 45, 15, 31, 46, 16], - - // 29 - [7, 146, 116, 7, 147, 117], - [21, 73, 45, 7, 74, 46], - [1, 53, 23, 37, 54, 24], - [19, 45, 15, 26, 46, 16], - - // 30 - [5, 145, 115, 10, 146, 116], - [19, 75, 47, 10, 76, 48], - [15, 54, 24, 25, 55, 25], - [23, 45, 15, 25, 46, 16], - - // 31 - [13, 145, 115, 3, 146, 116], - [2, 74, 46, 29, 75, 47], - [42, 54, 24, 1, 55, 25], - [23, 45, 15, 28, 46, 16], - - // 32 - [17, 145, 115], - [10, 74, 46, 23, 75, 47], - [10, 54, 24, 35, 55, 25], - [19, 45, 15, 35, 46, 16], - - // 33 - [17, 145, 115, 1, 146, 116], - [14, 74, 46, 21, 75, 47], - [29, 54, 24, 19, 55, 25], - [11, 45, 15, 46, 46, 16], - - // 34 - [13, 145, 115, 6, 146, 116], - [14, 74, 46, 23, 75, 47], - [44, 54, 24, 7, 55, 25], - [59, 46, 16, 1, 47, 17], - - // 35 - [12, 151, 121, 7, 152, 122], - [12, 75, 47, 26, 76, 48], - [39, 54, 24, 14, 55, 25], - [22, 45, 15, 41, 46, 16], - - // 36 - [6, 151, 121, 14, 152, 122], - [6, 75, 47, 34, 76, 48], - [46, 54, 24, 10, 55, 25], - [2, 45, 15, 64, 46, 16], - - // 37 - [17, 152, 122, 4, 153, 123], - [29, 74, 46, 14, 75, 47], - [49, 54, 24, 10, 55, 25], - [24, 45, 15, 46, 46, 16], - - // 38 - [4, 152, 122, 18, 153, 123], - [13, 74, 46, 32, 75, 47], - [48, 54, 24, 14, 55, 25], - [42, 45, 15, 32, 46, 16], - - // 39 - [20, 147, 117, 4, 148, 118], - [40, 75, 47, 7, 76, 48], - [43, 54, 24, 22, 55, 25], - [10, 45, 15, 67, 46, 16], - - // 40 - [19, 148, 118, 6, 149, 119], - [18, 75, 47, 31, 76, 48], - [34, 54, 24, 34, 55, 25], - [20, 45, 15, 61, 46, 16] - ]; - - var qrRSBlock = function(totalCount, dataCount) { - var _this = {}; - _this.totalCount = totalCount; - _this.dataCount = dataCount; - return _this; - }; - - var _this = {}; - - var getRsBlockTable = function(typeNumber, errorCorrectionLevel) { - - switch(errorCorrectionLevel) { - case QRErrorCorrectionLevel.L : - return RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 0]; - case QRErrorCorrectionLevel.M : - return RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 1]; - case QRErrorCorrectionLevel.Q : - return RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 2]; - case QRErrorCorrectionLevel.H : - return RS_BLOCK_TABLE[(typeNumber - 1) * 4 + 3]; - default : - return undefined; - } - }; - - _this.getRSBlocks = function(typeNumber, errorCorrectionLevel) { - - var rsBlock = getRsBlockTable(typeNumber, errorCorrectionLevel); - - if (typeof rsBlock == 'undefined') { - throw 'bad rs block @ typeNumber:' + typeNumber + - '/errorCorrectionLevel:' + errorCorrectionLevel; - } - - var length = rsBlock.length / 3; - - var list = []; - - for (var i = 0; i < length; i += 1) { - - var count = rsBlock[i * 3 + 0]; - var totalCount = rsBlock[i * 3 + 1]; - var dataCount = rsBlock[i * 3 + 2]; - - for (var j = 0; j < count; j += 1) { - list.push(qrRSBlock(totalCount, dataCount) ); - } - } - - return list; - }; - - return _this; - }(); - - //--------------------------------------------------------------------- - // qrBitBuffer - //--------------------------------------------------------------------- - - var qrBitBuffer = function() { - - var _buffer = []; - var _length = 0; - - var _this = {}; - - _this.getBuffer = function() { - return _buffer; - }; - - _this.getAt = function(index) { - var bufIndex = Math.floor(index / 8); - return ( (_buffer[bufIndex] >>> (7 - index % 8) ) & 1) == 1; - }; - - _this.put = function(num, length) { - for (var i = 0; i < length; i += 1) { - _this.putBit( ( (num >>> (length - i - 1) ) & 1) == 1); - } - }; - - _this.getLengthInBits = function() { - return _length; - }; - - _this.putBit = function(bit) { - - var bufIndex = Math.floor(_length / 8); - if (_buffer.length <= bufIndex) { - _buffer.push(0); - } - - if (bit) { - _buffer[bufIndex] |= (0x80 >>> (_length % 8) ); - } - - _length += 1; - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // qrNumber - //--------------------------------------------------------------------- - - var qrNumber = function(data) { - - var _mode = QRMode.MODE_NUMBER; - var _data = data; - - var _this = {}; - - _this.getMode = function() { - return _mode; - }; - - _this.getLength = function(buffer) { - return _data.length; - }; - - _this.write = function(buffer) { - - var data = _data; - - var i = 0; - - while (i + 2 < data.length) { - buffer.put(strToNum(data.substring(i, i + 3) ), 10); - i += 3; - } - - if (i < data.length) { - if (data.length - i == 1) { - buffer.put(strToNum(data.substring(i, i + 1) ), 4); - } else if (data.length - i == 2) { - buffer.put(strToNum(data.substring(i, i + 2) ), 7); - } - } - }; - - var strToNum = function(s) { - var num = 0; - for (var i = 0; i < s.length; i += 1) { - num = num * 10 + chatToNum(s.charAt(i) ); - } - return num; - }; - - var chatToNum = function(c) { - if ('0' <= c && c <= '9') { - return c.charCodeAt(0) - '0'.charCodeAt(0); - } - throw 'illegal char :' + c; - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // qrAlphaNum - //--------------------------------------------------------------------- - - var qrAlphaNum = function(data) { - - var _mode = QRMode.MODE_ALPHA_NUM; - var _data = data; - - var _this = {}; - - _this.getMode = function() { - return _mode; - }; - - _this.getLength = function(buffer) { - return _data.length; - }; - - _this.write = function(buffer) { - - var s = _data; - - var i = 0; - - while (i + 1 < s.length) { - buffer.put( - getCode(s.charAt(i) ) * 45 + - getCode(s.charAt(i + 1) ), 11); - i += 2; - } - - if (i < s.length) { - buffer.put(getCode(s.charAt(i) ), 6); - } - }; - - var getCode = function(c) { - - if ('0' <= c && c <= '9') { - return c.charCodeAt(0) - '0'.charCodeAt(0); - } else if ('A' <= c && c <= 'Z') { - return c.charCodeAt(0) - 'A'.charCodeAt(0) + 10; - } else { - switch (c) { - case ' ' : return 36; - case '$' : return 37; - case '%' : return 38; - case '*' : return 39; - case '+' : return 40; - case '-' : return 41; - case '.' : return 42; - case '/' : return 43; - case ':' : return 44; - default : - throw 'illegal char :' + c; - } - } - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // qr8BitByte - //--------------------------------------------------------------------- - - var qr8BitByte = function(data) { - - var _mode = QRMode.MODE_8BIT_BYTE; - var _data = data; - var _bytes = qrcode.stringToBytes(data); - - var _this = {}; - - _this.getMode = function() { - return _mode; - }; - - _this.getLength = function(buffer) { - return _bytes.length; - }; - - _this.write = function(buffer) { - for (var i = 0; i < _bytes.length; i += 1) { - buffer.put(_bytes[i], 8); - } - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // qrKanji - //--------------------------------------------------------------------- - - var qrKanji = function(data) { - - var _mode = QRMode.MODE_KANJI; - var _data = data; - - var stringToBytes = qrcode.stringToBytesFuncs['SJIS']; - if (!stringToBytes) { - throw 'sjis not supported.'; - } - !function(c, code) { - // self test for sjis support. - var test = stringToBytes(c); - if (test.length != 2 || ( (test[0] << 8) | test[1]) != code) { - throw 'sjis not supported.'; - } - }('\u53cb', 0x9746); - - var _bytes = stringToBytes(data); - - var _this = {}; - - _this.getMode = function() { - return _mode; - }; - - _this.getLength = function(buffer) { - return ~~(_bytes.length / 2); - }; - - _this.write = function(buffer) { - - var data = _bytes; - - var i = 0; - - while (i + 1 < data.length) { - - var c = ( (0xff & data[i]) << 8) | (0xff & data[i + 1]); - - if (0x8140 <= c && c <= 0x9FFC) { - c -= 0x8140; - } else if (0xE040 <= c && c <= 0xEBBF) { - c -= 0xC140; - } else { - throw 'illegal char at ' + (i + 1) + '/' + c; - } - - c = ( (c >>> 8) & 0xff) * 0xC0 + (c & 0xff); - - buffer.put(c, 13); - - i += 2; - } - - if (i < data.length) { - throw 'illegal char at ' + (i + 1); - } - }; - - return _this; - }; - - //===================================================================== - // GIF Support etc. - // - - //--------------------------------------------------------------------- - // byteArrayOutputStream - //--------------------------------------------------------------------- - - var byteArrayOutputStream = function() { - - var _bytes = []; - - var _this = {}; - - _this.writeByte = function(b) { - _bytes.push(b & 0xff); - }; - - _this.writeShort = function(i) { - _this.writeByte(i); - _this.writeByte(i >>> 8); - }; - - _this.writeBytes = function(b, off, len) { - off = off || 0; - len = len || b.length; - for (var i = 0; i < len; i += 1) { - _this.writeByte(b[i + off]); - } - }; - - _this.writeString = function(s) { - for (var i = 0; i < s.length; i += 1) { - _this.writeByte(s.charCodeAt(i) ); - } - }; - - _this.toByteArray = function() { - return _bytes; - }; - - _this.toString = function() { - var s = ''; - s += '['; - for (var i = 0; i < _bytes.length; i += 1) { - if (i > 0) { - s += ','; - } - s += _bytes[i]; - } - s += ']'; - return s; - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // base64EncodeOutputStream - //--------------------------------------------------------------------- - - var base64EncodeOutputStream = function() { - - var _buffer = 0; - var _buflen = 0; - var _length = 0; - var _base64 = ''; - - var _this = {}; - - var writeEncoded = function(b) { - _base64 += String.fromCharCode(encode(b & 0x3f) ); - }; - - var encode = function(n) { - if (n < 0) { - // error. - } else if (n < 26) { - return 0x41 + n; - } else if (n < 52) { - return 0x61 + (n - 26); - } else if (n < 62) { - return 0x30 + (n - 52); - } else if (n == 62) { - return 0x2b; - } else if (n == 63) { - return 0x2f; - } - throw 'n:' + n; - }; - - _this.writeByte = function(n) { - - _buffer = (_buffer << 8) | (n & 0xff); - _buflen += 8; - _length += 1; - - while (_buflen >= 6) { - writeEncoded(_buffer >>> (_buflen - 6) ); - _buflen -= 6; - } - }; - - _this.flush = function() { - - if (_buflen > 0) { - writeEncoded(_buffer << (6 - _buflen) ); - _buffer = 0; - _buflen = 0; - } - - if (_length % 3 != 0) { - // padding - var padlen = 3 - _length % 3; - for (var i = 0; i < padlen; i += 1) { - _base64 += '='; - } - } - }; - - _this.toString = function() { - return _base64; - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // base64DecodeInputStream - //--------------------------------------------------------------------- - - var base64DecodeInputStream = function(str) { - - var _str = str; - var _pos = 0; - var _buffer = 0; - var _buflen = 0; - - var _this = {}; - - _this.read = function() { - - while (_buflen < 8) { - - if (_pos >= _str.length) { - if (_buflen == 0) { - return -1; - } - throw 'unexpected end of file./' + _buflen; - } - - var c = _str.charAt(_pos); - _pos += 1; - - if (c == '=') { - _buflen = 0; - return -1; - } else if (c.match(/^\s$/) ) { - // ignore if whitespace. - continue; - } - - _buffer = (_buffer << 6) | decode(c.charCodeAt(0) ); - _buflen += 6; - } - - var n = (_buffer >>> (_buflen - 8) ) & 0xff; - _buflen -= 8; - return n; - }; - - var decode = function(c) { - if (0x41 <= c && c <= 0x5a) { - return c - 0x41; - } else if (0x61 <= c && c <= 0x7a) { - return c - 0x61 + 26; - } else if (0x30 <= c && c <= 0x39) { - return c - 0x30 + 52; - } else if (c == 0x2b) { - return 62; - } else if (c == 0x2f) { - return 63; - } else { - throw 'c:' + c; - } - }; - - return _this; - }; - - //--------------------------------------------------------------------- - // gifImage (B/W) - //--------------------------------------------------------------------- - - var gifImage = function(width, height) { - - var _width = width; - var _height = height; - var _data = new Array(width * height); - - var _this = {}; - - _this.setPixel = function(x, y, pixel) { - _data[y * _width + x] = pixel; - }; - - _this.write = function(out) { - - //--------------------------------- - // GIF Signature - - out.writeString('GIF87a'); - - //--------------------------------- - // Screen Descriptor - - out.writeShort(_width); - out.writeShort(_height); - - out.writeByte(0x80); // 2bit - out.writeByte(0); - out.writeByte(0); - - //--------------------------------- - // Global Color Map - - // black - out.writeByte(0x00); - out.writeByte(0x00); - out.writeByte(0x00); - - // white - out.writeByte(0xff); - out.writeByte(0xff); - out.writeByte(0xff); - - //--------------------------------- - // Image Descriptor - - out.writeString(','); - out.writeShort(0); - out.writeShort(0); - out.writeShort(_width); - out.writeShort(_height); - out.writeByte(0); - - //--------------------------------- - // Local Color Map - - //--------------------------------- - // Raster Data - - var lzwMinCodeSize = 2; - var raster = getLZWRaster(lzwMinCodeSize); - - out.writeByte(lzwMinCodeSize); - - var offset = 0; - - while (raster.length - offset > 255) { - out.writeByte(255); - out.writeBytes(raster, offset, 255); - offset += 255; - } - - out.writeByte(raster.length - offset); - out.writeBytes(raster, offset, raster.length - offset); - out.writeByte(0x00); - - //--------------------------------- - // GIF Terminator - out.writeString(';'); - }; - - var bitOutputStream = function(out) { - - var _out = out; - var _bitLength = 0; - var _bitBuffer = 0; - - var _this = {}; - - _this.write = function(data, length) { - - if ( (data >>> length) != 0) { - throw 'length over'; - } - - while (_bitLength + length >= 8) { - _out.writeByte(0xff & ( (data << _bitLength) | _bitBuffer) ); - length -= (8 - _bitLength); - data >>>= (8 - _bitLength); - _bitBuffer = 0; - _bitLength = 0; - } - - _bitBuffer = (data << _bitLength) | _bitBuffer; - _bitLength = _bitLength + length; - }; - - _this.flush = function() { - if (_bitLength > 0) { - _out.writeByte(_bitBuffer); - } - }; - - return _this; - }; - - var getLZWRaster = function(lzwMinCodeSize) { - - var clearCode = 1 << lzwMinCodeSize; - var endCode = (1 << lzwMinCodeSize) + 1; - var bitLength = lzwMinCodeSize + 1; - - // Setup LZWTable - var table = lzwTable(); - - for (var i = 0; i < clearCode; i += 1) { - table.add(String.fromCharCode(i) ); - } - table.add(String.fromCharCode(clearCode) ); - table.add(String.fromCharCode(endCode) ); - - var byteOut = byteArrayOutputStream(); - var bitOut = bitOutputStream(byteOut); - - // clear code - bitOut.write(clearCode, bitLength); - - var dataIndex = 0; - - var s = String.fromCharCode(_data[dataIndex]); - dataIndex += 1; - - while (dataIndex < _data.length) { - - var c = String.fromCharCode(_data[dataIndex]); - dataIndex += 1; - - if (table.contains(s + c) ) { - - s = s + c; - - } else { - - bitOut.write(table.indexOf(s), bitLength); - - if (table.size() < 0xfff) { - - if (table.size() == (1 << bitLength) ) { - bitLength += 1; - } - - table.add(s + c); - } - - s = c; - } - } - - bitOut.write(table.indexOf(s), bitLength); - - // end code - bitOut.write(endCode, bitLength); - - bitOut.flush(); - - return byteOut.toByteArray(); - }; - - var lzwTable = function() { - - var _map = {}; - var _size = 0; - - var _this = {}; - - _this.add = function(key) { - if (_this.contains(key) ) { - throw 'dup key:' + key; - } - _map[key] = _size; - _size += 1; - }; - - _this.size = function() { - return _size; - }; - - _this.indexOf = function(key) { - return _map[key]; - }; - - _this.contains = function(key) { - return typeof _map[key] != 'undefined'; - }; - - return _this; - }; - - return _this; - }; - - var createDataURL = function(width, height, getPixel) { - var gif = gifImage(width, height); - for (var y = 0; y < height; y += 1) { - for (var x = 0; x < width; x += 1) { - gif.setPixel(x, y, getPixel(x, y) ); - } - } - - var b = byteArrayOutputStream(); - gif.write(b); - - var base64 = base64EncodeOutputStream(); - var bytes = b.toByteArray(); - for (var i = 0; i < bytes.length; i += 1) { - base64.writeByte(bytes[i]); - } - base64.flush(); - - return 'data:image/gif;base64,' + base64; - }; - - //--------------------------------------------------------------------- - // returns qrcode function. - - return qrcode; -}(); - -// multibyte support -!function() { - - qrcode.stringToBytesFuncs['UTF-8'] = function(s) { - // http://stackoverflow.com/questions/18729405/how-to-convert-utf8-string-to-byte-array - function toUTF8Array(str) { - var utf8 = []; - for (var i=0; i < str.length; i++) { - var charcode = str.charCodeAt(i); - if (charcode < 0x80) utf8.push(charcode); - else if (charcode < 0x800) { - utf8.push(0xc0 | (charcode >> 6), - 0x80 | (charcode & 0x3f)); - } - else if (charcode < 0xd800 || charcode >= 0xe000) { - utf8.push(0xe0 | (charcode >> 12), - 0x80 | ((charcode>>6) & 0x3f), - 0x80 | (charcode & 0x3f)); - } - // surrogate pair - else { - i++; - // UTF-16 encodes 0x10000-0x10FFFF by - // subtracting 0x10000 and splitting the - // 20 bits of 0x0-0xFFFFF into two halves - charcode = 0x10000 + (((charcode & 0x3ff)<<10) - | (str.charCodeAt(i) & 0x3ff)); - utf8.push(0xf0 | (charcode >>18), - 0x80 | ((charcode>>12) & 0x3f), - 0x80 | ((charcode>>6) & 0x3f), - 0x80 | (charcode & 0x3f)); - } - } - return utf8; - } - return toUTF8Array(s); - }; - -}(); - -(function (factory) { - if (typeof define === 'function' && define.amd) { - define([], factory); - } else if (typeof exports === 'object') { - module.exports = factory(); - } -}(function () { - return qrcode; -})); diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-backup-codes.php b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-backup-codes.php deleted file mode 100644 index 2a3345b4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-backup-codes.php +++ /dev/null @@ -1,438 +0,0 @@ - WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'rest_generate_codes' ), - 'permission_callback' => function( $request ) { - return Two_Factor_Core::rest_api_can_edit_user_and_update_two_factor_options( $request['user_id'] ); - }, - 'args' => array( - 'user_id' => array( - 'required' => true, - 'type' => 'integer', - ), - 'enable_provider' => array( - 'required' => false, - 'type' => 'boolean', - 'default' => false, - ), - ), - ) - ); - } - - /** - * Displays an admin notice when backup codes have run out. - * - * @since 0.1-dev - * - * @codeCoverageIgnore - */ - public function admin_notices() { - $user = wp_get_current_user(); - - // Return if the provider is not enabled. - if ( ! in_array( __CLASS__, Two_Factor_Core::get_enabled_providers_for_user( $user->ID ), true ) ) { - return; - } - - // Return if we are not out of codes. - if ( $this->is_available_for_user( $user ) ) { - return; - } - ?> -
            -

            - - regenerate!', 'two-factor' ), - esc_url( get_edit_user_link( $user->ID ) . '#two-factor-backup-codes' ) - ), - array( 'a' => array( 'href' => true ) ) - ); - ?> - -

            -
            - -

            -

            - -

            -

            - -

            -

            - - - ID, self::BACKUP_CODES_META_KEY, true ); - } - - $code_length = $this->get_backup_code_length( $user ); - - for ( $i = 0; $i < $num_codes; $i++ ) { - $code = $this->get_code( $code_length ); - $codes_hashed[] = wp_hash_password( $code ); - $codes[] = $code; - unset( $code ); - } - - update_user_meta( $user->ID, self::BACKUP_CODES_META_KEY, $codes_hashed ); - - // Unhashed. - return $codes; - } - - /** - * Generates Backup Codes for returning through the WordPress Rest API. - * - * @since 0.8.0 - */ - public function rest_generate_codes( $request ) { - $user_id = $request['user_id']; - $user = get_user_by( 'id', $user_id ); - - // Hardcode these, the user shouldn't be able to choose them. - $args = array( - 'number' => self::NUMBER_OF_CODES, - 'method' => 'replace', - ); - - // Setup the return data. - $codes = $this->generate_codes( $user, $args ); - $count = self::codes_remaining_for_user( $user ); - $title = sprintf( - /* translators: %s: the site's domain */ - __( 'Two-Factor Recovery Codes for %s', 'two-factor' ), - home_url( '/' ) - ); - - // Generate download content. - $download_link = 'data:application/text;charset=utf-8,'; - $download_link .= rawurlencode( "{$title}\r\n\r\n" ); - - $i = 1; - foreach ( $codes as $code ) { - $download_link .= rawurlencode( "{$i}. {$code}\r\n" ); - $i++; - } - - $i18n = array( - /* translators: %s: count */ - 'count' => esc_html( sprintf( _n( '%s unused code remaining, each recovery code can only be used once.', '%s unused codes remaining, each recovery code can only be used once.', $count, 'two-factor' ), $count ) ), - ); - - if ( $request->get_param( 'enable_provider' ) && ! Two_Factor_Core::enable_provider_for_user( $user_id, 'Two_Factor_Backup_Codes' ) ) { - return new WP_Error( 'db_error', __( 'Unable to enable recovery codes for this user.', 'two-factor' ), array( 'status' => 500 ) ); - } - - return array( - 'codes' => $codes, - 'download_link' => $download_link, - 'remaining' => $count, - 'i18n' => $i18n, - ); - } - - /** - * Returns the number of unused codes for the specified user - * - * @param WP_User $user WP_User object of the logged-in user. - * @return int $int The number of unused codes remaining - */ - public static function codes_remaining_for_user( $user ) { - $backup_codes = get_user_meta( $user->ID, self::BACKUP_CODES_META_KEY, true ); - if ( is_array( $backup_codes ) && ! empty( $backup_codes ) ) { - return count( $backup_codes ); - } - return 0; - } - - /** - * Prints the form that prompts the user to authenticate. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public function authentication_page( $user ) { - require_once ABSPATH . '/wp-admin/includes/template.php'; - - $code_length = $this->get_backup_code_length( $user ); - $code_placeholder = str_repeat( 'X', $code_length ); - - ?> -

            -

            - - -

            - sanitize_code_from_request( 'two-factor-backup-code' ); - if ( ! $backup_code ) { - return false; - } - - return $this->validate_code( $user, $backup_code ); - } - - /** - * Validates a backup code. - * - * Backup Codes are single use and are deleted upon a successful validation. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @param int $code The backup code. - * @return boolean - */ - public function validate_code( $user, $code ) { - $backup_codes = get_user_meta( $user->ID, self::BACKUP_CODES_META_KEY, true ); - - if ( is_array( $backup_codes ) && ! empty( $backup_codes ) ) { - foreach ( $backup_codes as $code_index => $code_hashed ) { - if ( wp_check_password( $code, $code_hashed, $user->ID ) ) { - $this->delete_code( $user, $code_hashed ); - return true; - } - } - } - return false; - } - - /** - * Deletes a backup code. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @param string $code_hashed The hashed the backup code. - */ - public function delete_code( $user, $code_hashed ) { - $backup_codes = get_user_meta( $user->ID, self::BACKUP_CODES_META_KEY, true ); - - // Delete the current code from the list since it's been used. - $backup_codes = array_flip( $backup_codes ); - unset( $backup_codes[ $code_hashed ] ); - $backup_codes = array_values( array_flip( $backup_codes ) ); - - // Update the backup code master list. - update_user_meta( $user->ID, self::BACKUP_CODES_META_KEY, $backup_codes ); - } - - /** - * Return user meta keys to delete during plugin uninstall. - * - * @return array - */ - public static function uninstall_user_meta_keys() { - return array( - self::BACKUP_CODES_META_KEY, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-dummy.php b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-dummy.php deleted file mode 100644 index cc9a6119..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-dummy.php +++ /dev/null @@ -1,85 +0,0 @@ - -

            - get_code( $this->get_token_length() ); - - update_user_meta( $user_id, self::TOKEN_META_KEY_TIMESTAMP, time() ); - update_user_meta( $user_id, self::TOKEN_META_KEY, wp_hash( $token ) ); - - return $token; - } - - /** - * Check if user has a valid token already. - * - * @param int $user_id User ID. - * @return boolean If user has a valid email token. - */ - public function user_has_token( $user_id ) { - $hashed_token = $this->get_user_token( $user_id ); - - if ( ! empty( $hashed_token ) ) { - return true; - } - - return false; - } - - /** - * Has the user token validity timestamp expired. - * - * @param integer $user_id User ID. - * - * @return boolean - */ - public function user_token_has_expired( $user_id ) { - $token_lifetime = $this->user_token_lifetime( $user_id ); - $token_ttl = $this->user_token_ttl( $user_id ); - - // Invalid token lifetime is considered an expired token. - if ( is_int( $token_lifetime ) && $token_lifetime <= $token_ttl ) { - return false; - } - - return true; - } - - /** - * Get the lifetime of a user token in seconds. - * - * @param integer $user_id User ID. - * - * @return integer|null Return `null` if the lifetime can't be measured. - */ - public function user_token_lifetime( $user_id ) { - $timestamp = intval( get_user_meta( $user_id, self::TOKEN_META_KEY_TIMESTAMP, true ) ); - - if ( ! empty( $timestamp ) ) { - return time() - $timestamp; - } - - return null; - } - - /** - * Return the token time-to-live for a user. - * - * @param integer $user_id User ID. - * - * @return integer - */ - public function user_token_ttl( $user_id ) { - $token_ttl = 15 * MINUTE_IN_SECONDS; - - /** - * Number of seconds the token is considered valid - * after the generation. - * - * @deprecated 0.11.0 Use {@see 'two_factor_email_token_ttl'} instead. - * - * @param integer $token_ttl Token time-to-live in seconds. - * @param integer $user_id User ID. - */ - $token_ttl = (int) apply_filters_deprecated( 'two_factor_token_ttl', array( $token_ttl, $user_id ), '0.11.0', 'two_factor_email_token_ttl' ); - - /** - * Number of seconds the token is considered valid - * after the generation. - * - * @param integer $token_ttl Token time-to-live in seconds. - * @param integer $user_id User ID. - */ - return (int) apply_filters( 'two_factor_email_token_ttl', $token_ttl, $user_id ); - } - - /** - * Get the authentication token for the user. - * - * @param int $user_id User ID. - * - * @return string|boolean User token or `false` if no token found. - */ - public function get_user_token( $user_id ) { - $hashed_token = get_user_meta( $user_id, self::TOKEN_META_KEY, true ); - - if ( ! empty( $hashed_token ) && is_string( $hashed_token ) ) { - return $hashed_token; - } - - return false; - } - - /** - * Validate the user token. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - * @param string $token User token. - * @return boolean - */ - public function validate_token( $user_id, $token ) { - $hashed_token = $this->get_user_token( $user_id ); - - // Bail if token is empty or it doesn't match. - if ( empty( $hashed_token ) || ! hash_equals( wp_hash( $token ), $hashed_token ) ) { - return false; - } - - if ( $this->user_token_has_expired( $user_id ) ) { - return false; - } - - // Ensure the token can be used only once. - $this->delete_token( $user_id ); - - return true; - } - - /** - * Delete the user token. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - */ - public function delete_token( $user_id ) { - delete_user_meta( $user_id, self::TOKEN_META_KEY ); - } - - /** - * Generate and email the user token. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @return bool Whether the email contents were sent successfully. - */ - public function generate_and_email_token( $user ) { - $token = $this->generate_token( $user->ID ); - - /* translators: %s: site name */ - $subject = wp_strip_all_tags( sprintf( __( 'Your login confirmation code for %s', 'two-factor' ), wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) ) ); - /* translators: %s: token */ - $message = wp_strip_all_tags( sprintf( __( 'Enter %s to log in.', 'two-factor' ), $token ) ); - - /** - * Filter the token email subject. - * - * @param string $subject The email subject line. - * @param int $user_id The ID of the user. - */ - $subject = apply_filters( 'two_factor_token_email_subject', $subject, $user->ID ); - - /** - * Filter the token email message. - * - * @param string $message The email message. - * @param string $token The token. - * @param int $user_id The ID of the user. - */ - $message = apply_filters( 'two_factor_token_email_message', $message, $token, $user->ID ); - - return wp_mail( $user->user_email, $subject, $message ); // phpcs:ignore WordPressVIPMinimum.Functions.RestrictedFunctions.wp_mail_wp_mail - } - - /** - * Prints the form that prompts the user to authenticate. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public function authentication_page( $user ) { - if ( ! $user ) { - return; - } - - if ( ! $this->user_has_token( $user->ID ) || $this->user_token_has_expired( $user->ID ) ) { - $this->generate_and_email_token( $user ); - } - - $token_length = $this->get_token_length(); - $token_placeholder = str_repeat( 'X', $token_length ); - - require_once ABSPATH . '/wp-admin/includes/template.php'; - ?> -

            -

            - - - -

            -

            - -

            - - ID ) && isset( $_REQUEST[ self::INPUT_NAME_RESEND_CODE ] ) ) { - $this->generate_and_email_token( $user ); - return true; - } - - return false; - } - - /** - * Validates the users input token. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @return boolean - */ - public function validate_authentication( $user ) { - $code = $this->sanitize_code_from_request( 'two-factor-email-code' ); - if ( ! isset( $user->ID ) || ! $code ) { - return false; - } - - return $this->validate_token( $user->ID, $code ); - } - - /** - * Whether this Two Factor provider is configured and available for the user specified. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @return boolean - */ - public function is_available_for_user( $user ) { - return true; - } - - /** - * Inserts markup at the end of the user profile field for this provider. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public function user_options( $user ) { - $email = $user->user_email; - ?> -
            - -
            - wp_strip_all_tags( __( 'Name', 'two-factor' ) ), - 'added' => wp_strip_all_tags( __( 'Added', 'two-factor' ) ), - 'last_used' => wp_strip_all_tags( __( 'Last Used', 'two-factor' ) ), - ); - } - - /** - * Prepares the list of items for displaying. - * - * @since 0.1-dev - */ - public function prepare_items() { - $columns = $this->get_columns(); - $hidden = array(); - $sortable = array(); - $primary = 'name'; - $this->_column_headers = array( $columns, $hidden, $sortable, $primary ); - } - - /** - * Generates content for a single row of the table - * - * @since 0.1-dev - * @access protected - * - * @param object $item The current item. - * @param string $column_name The current column name. - * @return string - */ - protected function column_default( $item, $column_name ) { - switch ( $column_name ) { - case 'name': - $out = ''; - - $actions = array( - 'rename hide-if-no-js' => Two_Factor_FIDO_U2F_Admin::rename_link( $item ), - 'delete' => Two_Factor_FIDO_U2F_Admin::delete_link( $item ), - ); - - return esc_html( $item->name ) . $out . self::row_actions( $actions ); - case 'added': - return gmdate( get_option( 'date_format', 'r' ), $item->added ); - case 'last_used': - return gmdate( get_option( 'date_format', 'r' ), $item->last_used ); - default: - return 'WTF^^?'; - } - } - - /** - * Generates custom table navigation to prevent conflicting nonces. - * - * @since 0.1-dev - * @access protected - * - * @param string $which The location of the bulk actions: 'top' or 'bottom'. - */ - protected function display_tablenav( $which ) { - // Not used for the Security key list. - } - - /** - * Generates content for a single row of the table - * - * @since 0.1-dev - * @access public - * - * @param object $item The current item. - */ - public function single_row( $item ) { - ?> - - single_row_columns( $item ); ?> - - - - - - - - -
            - getRegisterData( $security_keys ); - list( $req,$sigs ) = $data; - - update_user_meta( $user_id, self::REGISTER_DATA_USER_META_KEY, $req ); - } catch ( Exception $e ) { - return false; - } - - wp_enqueue_style( - 'fido-u2f-admin', - plugins_url( 'css/fido-u2f-admin.css', __FILE__ ), - null, - self::asset_version() - ); - - wp_enqueue_script( - 'fido-u2f-admin', - plugins_url( 'js/fido-u2f-admin.js', __FILE__ ), - array( 'jquery', 'fido-u2f-api' ), - self::asset_version(), - true - ); - - /** - * Pass a U2F challenge and user data to our scripts - */ - - $translation_array = array( - 'user_id' => $user_id, - 'register' => array( - 'request' => $req, - 'sigs' => $sigs, - ), - 'text' => array( - 'insert' => esc_html__( 'Now insert (and tap) your Security Key.', 'two-factor' ), - 'error' => esc_html__( 'U2F request failed.', 'two-factor' ), - 'error_codes' => array( - // Map u2f.ErrorCodes to error messages. - 0 => esc_html__( 'Request OK.', 'two-factor' ), - 1 => esc_html__( 'Other U2F error.', 'two-factor' ), - 2 => esc_html__( 'Bad U2F request.', 'two-factor' ), - 3 => esc_html__( 'Unsupported U2F configuration.', 'two-factor' ), - 4 => esc_html__( 'U2F device ineligible.', 'two-factor' ), - 5 => esc_html__( 'U2F request timeout reached.', 'two-factor' ), - ), - 'u2f_not_supported' => esc_html__( 'FIDO U2F appears to be not supported by your web browser. Try using Google Chrome or Firefox.', 'two-factor' ), - ), - ); - - wp_localize_script( - 'fido-u2f-admin', - 'u2fL10n', - $translation_array - ); - - /** - * Script for admin UI - */ - - wp_enqueue_script( - 'inline-edit-key', - plugins_url( 'js/fido-u2f-admin-inline-edit.js', __FILE__ ), - array( 'jquery' ), - self::asset_version(), - true - ); - - wp_localize_script( - 'inline-edit-key', - 'inlineEditL10n', - array( - 'error' => esc_html__( 'Error while saving the changes.', 'two-factor' ), - ) - ); - } - - /** - * Return the current asset version number. - * - * Added as own helper to allow swapping the implementation once we inject - * it as a dependency. - * - * @return string - */ - protected static function asset_version() { - return Two_Factor_FIDO_U2F::asset_version(); - } - - /** - * Display the security key section in a users profile. - * - * This executes during the `show_user_security_settings` action. - * - * @since 0.1-dev - * - * @access public - * @static - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public static function show_user_profile( $user ) { - if ( ! Two_Factor_FIDO_U2F::is_supported_for_user( $user ) ) { - return; - } - - wp_nonce_field( "user_security_keys-{$user->ID}", '_nonce_user_security_keys' ); - $new_key = false; - - $security_keys = Two_Factor_FIDO_U2F::get_security_keys( $user->ID ); - if ( $security_keys ) { - foreach ( $security_keys as &$security_key ) { - if ( property_exists( $security_key, 'new' ) ) { - $new_key = true; - unset( $security_key->new ); - - // If we've got a new one, update the db record to not save it there any longer. - Two_Factor_FIDO_U2F::update_security_key( $user->ID, $security_key ); - } - } - unset( $security_key ); - } - - ?> -
            -

            - - -

            - -

            - - -
            - - - - - -
            - - -
            -

            -
            - - -

            - - items = $security_keys; - $u2f_list_table->prepare_items(); - $u2f_list_table->display(); - $u2f_list_table->inline_edit(); - ?> -
            - doRegister( get_user_meta( $user_id, self::REGISTER_DATA_USER_META_KEY, true ), $response ); - $reg->new = true; - - Two_Factor_FIDO_U2F::add_security_key( $user_id, $reg ); - } catch ( Exception $e ) { - return; - } - - delete_user_meta( $user_id, self::REGISTER_DATA_USER_META_KEY ); - - wp_safe_redirect( - add_query_arg( - array( - 'new_app_pass' => 1, - ), - wp_get_referer() - ) . '#security-keys-section' - ); - exit; - } - } - - /** - * Catch the delete security key request. - * - * This executes during the `load-profile.php` & `load-user-edit.php` actions. - * - * @since 0.1-dev - * - * @access public - * @static - */ - public static function catch_delete_security_key() { - $user_id = Two_Factor_Core::current_user_being_edited(); - - if ( ! empty( $user_id ) && ! empty( $_REQUEST['delete_security_key'] ) ) { - $slug = $_REQUEST['delete_security_key']; - - check_admin_referer( "delete_security_key-{$slug}", '_nonce_delete_security_key' ); - - Two_Factor_FIDO_U2F::delete_security_key( $user_id, $slug ); - - wp_safe_redirect( remove_query_arg( 'new_app_pass', wp_get_referer() ) . '#security-keys-section' ); - exit; - } - } - - /** - * Generate a link to rename a specified security key. - * - * @since 0.1-dev - * - * @access public - * @static - * - * @param array $item The current item. - * @return string - */ - public static function rename_link( $item ) { - return sprintf( '%s', esc_html__( 'Rename', 'two-factor' ) ); - } - - /** - * Generate a link to delete a specified security key. - * - * @since 0.1-dev - * - * @access public - * @static - * - * @param array $item The current item. - * @return string - */ - public static function delete_link( $item ) { - $delete_link = add_query_arg( 'delete_security_key', $item->keyHandle ); // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - $delete_link = wp_nonce_url( $delete_link, "delete_security_key-{$item->keyHandle}", '_nonce_delete_security_key' ); - return sprintf( '%2$s', esc_url( $delete_link ), esc_html__( 'Delete', 'two-factor' ) ); - } - - /** - * Ajax handler for quick edit saving for a security key. - * - * @since 0.1-dev - * - * @access public - * @static - */ - public static function wp_ajax_inline_save() { - check_ajax_referer( 'keyinlineeditnonce', '_inline_edit' ); - - require_once TWO_FACTOR_DIR . 'providers/class-two-factor-fido-u2f-admin-list-table.php'; - $wp_list_table = new Two_Factor_FIDO_U2F_Admin_List_Table(); - - if ( ! isset( $_POST['keyHandle'] ) ) { - wp_die(); - } - - $user_id = Two_Factor_Core::current_user_being_edited(); - $security_keys = Two_Factor_FIDO_U2F::get_security_keys( $user_id ); - if ( ! $security_keys ) { - wp_die(); - } - - foreach ( $security_keys as &$key ) { - if ( $key->keyHandle === $_POST['keyHandle'] ) { // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - break; - } - } - - $key->name = $_POST['name']; - - $updated = Two_Factor_FIDO_U2F::update_security_key( $user_id, $key ); - if ( ! $updated ) { - wp_die( esc_html__( 'Item not updated.', 'two-factor' ) ); - } - $wp_list_table->single_row( $key ); - wp_die(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-fido-u2f.php b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-fido-u2f.php deleted file mode 100644 index cd569997..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-fido-u2f.php +++ /dev/null @@ -1,404 +0,0 @@ - -

            - ID ); - $data = self::$u2f->getAuthenticateData( $keys ); - update_user_meta( $user->ID, self::AUTH_DATA_USER_META_KEY, $data ); - } catch ( Exception $e ) { - ?> -

            - $data, - ) - ); - - wp_enqueue_script( 'fido-u2f-login' ); - - ?> -

            - - ID, self::AUTH_DATA_USER_META_KEY, true ); - - $response = json_decode( stripslashes( $_REQUEST['u2f_response'] ) ); - - $keys = self::get_security_keys( $user->ID ); - - try { - $reg = self::$u2f->doAuthenticate( $requests, $keys, $response ); - - $reg->last_used = time(); - - self::update_security_key( $user->ID, $reg ); - - return true; - } catch ( Exception $e ) { - return false; - } - } - - /** - * Whether this Two Factor provider is configured and available for the user specified. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @return boolean - */ - public function is_available_for_user( $user ) { - return (bool) self::get_security_keys( $user->ID ); - } - - /** - * Inserts markup at the end of the user profile field for this provider. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - public function user_options( $user ) { - ?> -

            - -

            - keyHandle ) // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - || ! property_exists( $register, 'publicKey' ) || empty( $register->publicKey ) // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - || ! property_exists( $register, 'certificate' ) || empty( $register->certificate ) - || ! property_exists( $register, 'counter' ) || ( -1 > $register->counter ) - ) { - return false; - } - - $register = array( - 'keyHandle' => $register->keyHandle, // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - 'publicKey' => $register->publicKey, // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - 'certificate' => $register->certificate, - 'counter' => $register->counter, - ); - - $register['name'] = __( 'New Security Key', 'two-factor' ); - $register['added'] = time(); - $register['last_used'] = $register['added']; - - return add_user_meta( $user_id, self::REGISTERED_KEY_USER_META_KEY, $register ); - } - - /** - * Retrieve registered security keys for a user. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - * @return array|bool Array of keys on success, false on failure. - */ - public static function get_security_keys( $user_id ) { - if ( ! is_numeric( $user_id ) ) { - return false; - } - - $keys = get_user_meta( $user_id, self::REGISTERED_KEY_USER_META_KEY ); - if ( $keys ) { - foreach ( $keys as &$key ) { - $key = (object) $key; - } - unset( $key ); - } - - return $keys; - } - - /** - * Update registered security key. - * - * Use the $prev_value parameter to differentiate between meta fields with the - * same key and user ID. - * - * If the meta field for the user does not exist, it will be added. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - * @param object $data The data of registered security key. - * @return int|bool Meta ID if the key didn't exist, true on successful update, false on failure. - */ - public static function update_security_key( $user_id, $data ) { - if ( ! is_numeric( $user_id ) ) { - return false; - } - - if ( - ! is_object( $data ) - || ! property_exists( $data, 'keyHandle' ) || empty( $data->keyHandle ) // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - || ! property_exists( $data, 'publicKey' ) || empty( $data->publicKey ) // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - || ! property_exists( $data, 'certificate' ) || empty( $data->certificate ) - || ! property_exists( $data, 'counter' ) || ( -1 > $data->counter ) - ) { - return false; - } - - $keys = self::get_security_keys( $user_id ); - if ( $keys ) { - foreach ( $keys as $key ) { - if ( $key->keyHandle === $data->keyHandle ) { // phpcs:ignore WordPress.NamingConventions.ValidVariableName.UsedPropertyNotSnakeCase - return update_user_meta( $user_id, self::REGISTERED_KEY_USER_META_KEY, (array) $data, (array) $key ); - } - } - } - - return self::add_security_key( $user_id, $data ); - } - - /** - * Remove registered security key matching criteria from a user. - * - * @since 0.1-dev - * - * @param int $user_id User ID. - * @param string $keyHandle Optional. Key handle. - * @return bool True on success, false on failure. - */ - public static function delete_security_key( $user_id, $keyHandle = null ) { // phpcs:ignore WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase - global $wpdb; - - if ( ! is_numeric( $user_id ) ) { - return false; - } - - $user_id = absint( $user_id ); - if ( ! $user_id ) { - return false; - } - - $keyHandle = wp_unslash( $keyHandle ); // phpcs:ignore WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase - $keyHandle = maybe_serialize( $keyHandle ); // phpcs:ignore WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase - - $query = $wpdb->prepare( "SELECT umeta_id FROM {$wpdb->usermeta} WHERE meta_key = %s AND user_id = %d", self::REGISTERED_KEY_USER_META_KEY, $user_id ); - - if ( $keyHandle ) { // phpcs:ignore WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase - $key_handle_lookup = sprintf( ':"%s";s:', $keyHandle ); // phpcs:ignore WordPress.NamingConventions.ValidVariableName.VariableNotSnakeCase - - $query .= $wpdb->prepare( - ' AND meta_value LIKE %s', - '%' . $wpdb->esc_like( $key_handle_lookup ) . '%' - ); - } - - $meta_ids = $wpdb->get_col( $query ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared - if ( ! count( $meta_ids ) ) { - return false; - } - - foreach ( $meta_ids as $meta_id ) { - delete_metadata_by_mid( 'user', $meta_id ); - } - - return true; - } - - /** - * Return user meta keys to delete during plugin uninstall. - * - * @return array - */ - public static function uninstall_user_meta_keys() { - return array( - self::REGISTERED_KEY_USER_META_KEY, - self::AUTH_DATA_USER_META_KEY, - '_two_factor_fido_u2f_register_request', // From Two_Factor_FIDO_U2F_Admin which is not loaded during uninstall. - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-provider.php b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-provider.php deleted file mode 100644 index b780c4a7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-provider.php +++ /dev/null @@ -1,201 +0,0 @@ -get_label() - ); - } - - /** - * Prints the name of the provider. - * - * @since 0.1-dev - */ - public function print_label() { - echo esc_html( $this->get_label() ); - } - - /** - * Retrieves the provider key / slug. - * - * @since 0.9.0 - * - * @return string - */ - public function get_key() { - return get_class( $this ); - } - - /** - * Prints the form that prompts the user to authenticate. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - */ - abstract public function authentication_page( $user ); - - /** - * Allow providers to do extra processing before the authentication. - * Return `true` to prevent the authentication and render the - * authentication page. - * - * @param WP_User $user WP_User object of the logged-in user. - * @return boolean - */ - public function pre_process_authentication( $user ) { - return false; - } - - /** - * Validates the users input token. - * - * @since 0.1-dev - * - * @param WP_User $user WP_User object of the logged-in user. - * @return boolean - */ - abstract public function validate_authentication( $user ); - - /** - * Whether this Two Factor provider is configured and available for the user specified. - * - * @param WP_User $user WP_User object of the logged-in user. - * @return boolean - */ - abstract public function is_available_for_user( $user ); - - /** - * If this provider should be available for the user. - * - * @param WP_User|int $user WP_User object, user ID or null to resolve the current user. - * - * @return bool - */ - public static function is_supported_for_user( $user = null ) { - $providers = Two_Factor_Core::get_supported_providers_for_user( $user ); - - return isset( $providers[ static::class ] ); - } - - /** - * Generate a random eight-digit string to send out as an auth code. - * - * @since 0.1-dev - * - * @param int $length The code length. - * @param string|array $chars Valid auth code characters. - * @return string - */ - public static function get_code( $length = 8, $chars = '1234567890' ) { - $code = ''; - if ( is_array( $chars ) ) { - $chars = implode( '', $chars ); - } - for ( $i = 0; $i < $length; $i++ ) { - $code .= substr( $chars, wp_rand( 0, strlen( $chars ) - 1 ), 1 ); - } - return $code; - } - - /** - * Sanitizes a numeric code to be used as an auth code. - * - * @param string $field The _REQUEST field to check for the code. - * @param int $length The valid expected length of the field. - * @return false|string Auth code on success, false if the field is not set or not expected length. - */ - public static function sanitize_code_from_request( $field, $length = 0 ) { - if ( empty( $_REQUEST[ $field ] ) ) { - return false; - } - - $code = wp_unslash( $_REQUEST[ $field ] ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended, handled by the core method already. - $code = preg_replace( '/\s+/', '', $code ); - - // Maybe validate the length. - if ( $length && strlen( $code ) !== $length ) { - return false; - } - - return (string) $code; - } - - /** - * Return the user meta keys that need to be deletated on plugin uninstall. - * - * @return array - */ - public static function uninstall_user_meta_keys() { - return array(); - } - - /** - * Return the option keys that need to be deleted on plugin uninstall. - * - * Note: this method doesn't have access to the instantiated provider object. - * - * @return array - */ - public static function uninstall_options() { - return array(); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-totp.php b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-totp.php deleted file mode 100644 index 9b3dd084..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/class-two-factor-totp.php +++ /dev/null @@ -1,801 +0,0 @@ - WP_REST_Server::DELETABLE, - 'callback' => array( $this, 'rest_delete_totp' ), - 'permission_callback' => function( $request ) { - return Two_Factor_Core::rest_api_can_edit_user_and_update_two_factor_options( $request['user_id'] ); - }, - 'args' => array( - 'user_id' => array( - 'required' => true, - 'type' => 'integer', - ), - ), - ), - array( - 'methods' => WP_REST_Server::CREATABLE, - 'callback' => array( $this, 'rest_setup_totp' ), - 'permission_callback' => function( $request ) { - return Two_Factor_Core::rest_api_can_edit_user_and_update_two_factor_options( $request['user_id'] ); - }, - 'args' => array( - 'user_id' => array( - 'required' => true, - 'type' => 'integer', - ), - 'key' => array( - 'type' => 'string', - 'default' => '', - 'validate_callback' => null, // Note: validation handled in ::rest_setup_totp(). - ), - 'code' => array( - 'type' => 'string', - 'default' => '', - 'validate_callback' => null, // Note: validation handled in ::rest_setup_totp(). - ), - 'enable_provider' => array( - 'required' => false, - 'type' => 'boolean', - 'default' => false, - ), - ), - ), - ) - ); - } - - /** - * Returns the name of the provider. - */ - public function get_label() { - return _x( 'Authenticator App', 'Provider Label', 'two-factor' ); - } - - /** - * Returns the "continue with" text provider for the login screen. - * - * @since 0.9.0 - */ - public function get_alternative_provider_label() { - return __( 'Use your authenticator app for time-based one-time passwords (TOTP)', 'two-factor' ); - } - - /** - * Enqueue scripts - * - * @codeCoverageIgnore - */ - public function enqueue_assets( $hook_suffix ) { - $environment_prefix = file_exists( TWO_FACTOR_DIR . '/dist' ) ? '/dist' : ''; - - wp_register_script( - 'two-factor-qr-code-generator', - plugins_url( $environment_prefix . '/includes/qrcode-generator/qrcode.js', __DIR__ ), - array(), - TWO_FACTOR_VERSION, - true - ); - } - - /** - * Rest API endpoint for handling deactivation of TOTP. - * - * @param WP_REST_Request $request The Rest Request object. - * @return array Success array. - */ - public function rest_delete_totp( $request ) { - $user_id = $request['user_id']; - $user = get_user_by( 'id', $user_id ); - - $this->delete_user_totp_key( $user_id ); - - if ( ! Two_Factor_Core::disable_provider_for_user( $user_id, 'Two_Factor_Totp' ) ) { - return new WP_Error( 'db_error', __( 'Unable to disable TOTP provider for this user.', 'two-factor' ), array( 'status' => 500 ) ); - } - - ob_start(); - $this->user_two_factor_options( $user ); - $html = ob_get_clean(); - - return [ - 'success' => true, - 'html' => $html, - ]; - } - - /** - * REST API endpoint for setting up TOTP. - * - * @param WP_REST_Request $request The Rest Request object. - * @return WP_Error|array Array of data on success, WP_Error on error. - */ - public function rest_setup_totp( $request ) { - $user_id = $request['user_id']; - $user = get_user_by( 'id', $user_id ); - - $key = $request['key']; - $code = preg_replace( '/\s+/', '', $request['code'] ); - - if ( ! $this->is_valid_key( $key ) ) { - return new WP_Error( 'invalid_key', __( 'Invalid Two Factor Authentication secret key.', 'two-factor' ), array( 'status' => 400 ) ); - } - - if ( ! $this->is_valid_authcode( $key, $code ) ) { - return new WP_Error( 'invalid_key_code', __( 'Invalid Two Factor Authentication code.', 'two-factor' ), array( 'status' => 400 ) ); - } - - if ( ! $this->set_user_totp_key( $user_id, $key ) ) { - return new WP_Error( 'db_error', __( 'Unable to save Two Factor Authentication code. Please re-scan the QR code and enter the code provided by your application.', 'two-factor' ), array( 'status' => 500 ) ); - } - - if ( $request->get_param( 'enable_provider' ) && ! Two_Factor_Core::enable_provider_for_user( $user_id, 'Two_Factor_Totp' ) ) { - return new WP_Error( 'db_error', __( 'Unable to enable TOTP provider for this user.', 'two-factor' ), array( 'status' => 500 ) ); - } - - ob_start(); - $this->user_two_factor_options( $user ); - $html = ob_get_clean(); - - return [ - 'success' => true, - 'html' => $html, - ]; - } - - /** - * Generates a URL that can be used to create a QR code. - * - * @param WP_User $user The user to generate a URL for. - * @param string $secret_key The secret key. - * - * @return string - */ - public static function generate_qr_code_url( $user, $secret_key ) { - $issuer = get_bloginfo( 'name', 'display' ); - - /** - * Filter the Issuer for the TOTP. - * - * Must follow the TOTP format for a "issuer". Do not URL Encode. - * - * @see https://github.com/google/google-authenticator/wiki/Key-Uri-Format#issuer - * @param string $issuer The issuer for TOTP. - */ - $issuer = apply_filters( 'two_factor_totp_issuer', $issuer ); - - /** - * Filter the Label for the TOTP. - * - * Must follow the TOTP format for a "label". Do not URL Encode. - * - * @see https://github.com/google/google-authenticator/wiki/Key-Uri-Format#label - * @param string $totp_title The label for the TOTP. - * @param WP_User $user The User object. - * @param string $issuer The issuer of the TOTP. This should be the prefix of the result. - */ - $totp_title = apply_filters( 'two_factor_totp_title', $issuer . ':' . $user->user_login, $user, $issuer ); - - $totp_url = add_query_arg( - array( - 'secret' => rawurlencode( $secret_key ), - 'issuer' => rawurlencode( $issuer ), - ), - 'otpauth://totp/' . rawurlencode( $totp_title ) - ); - - /** - * Filter the TOTP generated URL. - * - * Must follow the TOTP format. Do not URL Encode. - * - * @see https://github.com/google/google-authenticator/wiki/Key-Uri-Format - * @param string $totp_url The TOTP URL. - * @param WP_User $user The user object. - */ - $totp_url = apply_filters( 'two_factor_totp_url', $totp_url, $user ); - $totp_url = esc_url( $totp_url, array( 'otpauth' ) ); - - return $totp_url; - } - - /** - * Display TOTP options on the user settings page. - * - * @param WP_User $user The current user being edited. - * @return void - * - * @codeCoverageIgnore - */ - public function user_two_factor_options( $user ) { - if ( ! isset( $user->ID ) ) { - return; - } - - $key = $this->get_user_totp_key( $user->ID ); - - wp_enqueue_script( 'two-factor-qr-code-generator' ); - wp_enqueue_script( 'wp-api-request' ); - wp_enqueue_script( 'jquery' ); - - ?> -
            - generate_key(); - $totp_url = $this->generate_qr_code_url( $user, $key ); - - ?> - -

            - -

            -

            - - Loading... - - -

            - - - - - -

            - -

            -

            - - - -

            - - - - -

            - -

            -

            - - -

            - -
            - sanitize_code_from_request( 'authcode', self::DEFAULT_DIGIT_COUNT ); - if ( ! $code ) { - return false; - } - - return $this->validate_code_for_user( $user, $code ); - } - - /** - * Validates an authentication code for a given user, preventing re-use and older TOTP keys. - * - * @param WP_User $user WP_User object of the logged-in user. - * @param int $code The TOTP token to validate. - * - * @return bool Whether the code is valid for the user and a newer code has not been used. - */ - public function validate_code_for_user( $user, $code ) { - $valid_timestamp = $this->get_authcode_valid_ticktime( - $this->get_user_totp_key( $user->ID ), - $code - ); - - if ( ! $valid_timestamp ) { - return false; - } - - $last_totp_login = (int) get_user_meta( $user->ID, self::LAST_SUCCESSFUL_LOGIN_META_KEY, true ); - - // The TOTP authentication is not valid, if we've seen the same or newer code. - if ( $last_totp_login && $last_totp_login >= $valid_timestamp ) { - return false; - } - - update_user_meta( $user->ID, self::LAST_SUCCESSFUL_LOGIN_META_KEY, $valid_timestamp ); - - return true; - } - - - /** - * Checks if a given code is valid for a given key, allowing for a certain amount of time drift. - * - * @param string $key The share secret key to use. - * @param string $authcode The code to test. - * - * @return bool Whether the code is valid within the time frame. - */ - public static function is_valid_authcode( $key, $authcode ) { - return (bool) self::get_authcode_valid_ticktime( $key, $authcode ); - } - - /** - * Checks if a given code is valid for a given key, allowing for a certain amount of time drift. - * - * @param string $key The share secret key to use. - * @param string $authcode The code to test. - * - * @return false|int Returns the timestamp of the authcode on success, False otherwise. - */ - public static function get_authcode_valid_ticktime( $key, $authcode ) { - /** - * Filter the maximum ticks to allow when checking valid codes. - * - * Ticks are the allowed offset from the correct time in 30 second increments, - * so the default of 4 allows codes that are two minutes to either side of server time - * - * @deprecated 0.7.0 Use {@see 'two_factor_totp_time_step_allowance'} instead. - * @param int $max_ticks Max ticks of time correction to allow. Default 4. - */ - $max_ticks = apply_filters_deprecated( 'two-factor-totp-time-step-allowance', array( self::DEFAULT_TIME_STEP_ALLOWANCE ), '0.7.0', 'two_factor_totp_time_step_allowance' ); - - $max_ticks = apply_filters( 'two_factor_totp_time_step_allowance', self::DEFAULT_TIME_STEP_ALLOWANCE ); - - // Array of all ticks to allow, sorted using absolute value to test closest match first. - $ticks = range( - $max_ticks, $max_ticks ); - usort( $ticks, array( __CLASS__, 'abssort' ) ); - - $time = floor( time() / self::DEFAULT_TIME_STEP_SEC ); - - foreach ( $ticks as $offset ) { - $log_time = $time + $offset; - if ( hash_equals( self::calc_totp( $key, $log_time ), $authcode ) ) { - // Return the tick timestamp. - return $log_time * self::DEFAULT_TIME_STEP_SEC; - } - } - - return false; - } - - /** - * Generates key - * - * @param int $bitsize Nume of bits to use for key. - * - * @return string $bitsize long string composed of available base32 chars. - */ - public static function generate_key( $bitsize = self::DEFAULT_KEY_BIT_SIZE ) { - $bytes = ceil( $bitsize / 8 ); - $secret = wp_generate_password( $bytes, true, true ); - - return self::base32_encode( $secret ); - } - - /** - * Pack stuff - * - * @param string $value The value to be packed. - * - * @return string Binary packed string. - */ - public static function pack64( $value ) { - // 64bit mode (PHP_INT_SIZE == 8). - if ( PHP_INT_SIZE >= 8 ) { - // If we're on PHP 5.6.3+ we can use the new 64bit pack functionality. - if ( version_compare( PHP_VERSION, '5.6.3', '>=' ) && PHP_INT_SIZE >= 8 ) { - return pack( 'J', $value ); // phpcs:ignore PHPCompatibility.ParameterValues.NewPackFormat.NewFormatFound - } - $highmap = 0xffffffff << 32; - $higher = ( $value & $highmap ) >> 32; - } else { - /* - * 32bit PHP can't shift 32 bits like that, so we have to assume 0 for the higher - * and not pack anything beyond it's limits. - */ - $higher = 0; - } - - $lowmap = 0xffffffff; - $lower = $value & $lowmap; - - return pack( 'NN', $higher, $lower ); - } - - /** - * Calculate a valid code given the shared secret key - * - * @param string $key The shared secret key to use for calculating code. - * @param mixed $step_count The time step used to calculate the code, which is the floor of time() divided by step size. - * @param int $digits The number of digits in the returned code. - * @param string $hash The hash used to calculate the code. - * @param int $time_step The size of the time step. - * - * @return string The totp code - */ - public static function calc_totp( $key, $step_count = false, $digits = self::DEFAULT_DIGIT_COUNT, $hash = self::DEFAULT_CRYPTO, $time_step = self::DEFAULT_TIME_STEP_SEC ) { - $secret = self::base32_decode( $key ); - - if ( false === $step_count ) { - $step_count = floor( time() / $time_step ); - } - - $timestamp = self::pack64( $step_count ); - - $hash = hash_hmac( $hash, $timestamp, $secret, true ); - - $offset = ord( $hash[19] ) & 0xf; - - $code = ( - ( ( ord( $hash[ $offset + 0 ] ) & 0x7f ) << 24 ) | - ( ( ord( $hash[ $offset + 1 ] ) & 0xff ) << 16 ) | - ( ( ord( $hash[ $offset + 2 ] ) & 0xff ) << 8 ) | - ( ord( $hash[ $offset + 3 ] ) & 0xff ) - ) % pow( 10, $digits ); - - return str_pad( $code, $digits, '0', STR_PAD_LEFT ); - } - - /** - * Whether this Two Factor provider is configured and available for the user specified. - * - * @param WP_User $user WP_User object of the logged-in user. - * - * @return boolean - */ - public function is_available_for_user( $user ) { - // Only available if the secret key has been saved for the user. - $key = $this->get_user_totp_key( $user->ID ); - - return ! empty( $key ); - } - - /** - * Prints the form that prompts the user to authenticate. - * - * @param WP_User $user WP_User object of the logged-in user. - * - * @codeCoverageIgnore - */ - public function authentication_page( $user ) { - require_once ABSPATH . '/wp-admin/includes/template.php'; - ?> -

            - -

            -

            - - -

            - - = 8 ) { - $j -= 8; - $binary .= chr( ( $n & ( 0xFF << $j ) ) >> $j ); - } - } - - return $binary; - } - - /** - * Used with usort to sort an array by distance from 0 - * - * @param int $a First array element. - * @param int $b Second array element. - * - * @return int -1, 0, or 1 as needed by usort - */ - private static function abssort( $a, $b ) { - $a = abs( $a ); - $b = abs( $b ); - if ( $a === $b ) { - return 0; - } - return ( $a < $b ) ? -1 : 1; - } - - /** - * Return user meta keys to delete during plugin uninstall. - * - * @return array - */ - public static function uninstall_user_meta_keys() { - return array( - self::SECRET_META_KEY, - self::LAST_SUCCESSFUL_LOGIN_META_KEY, - ); - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/css/fido-u2f-admin.css b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/css/fido-u2f-admin.css deleted file mode 100644 index 96ca78aa..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/css/fido-u2f-admin.css +++ /dev/null @@ -1,12 +0,0 @@ -#security-keys-section .wp-list-table { - margin-bottom: 2em; -} - -#security-keys-section .register-security-key .spinner { - float: none; -} - -#security-keys-section .security-key-status { - vertical-align: middle; - font-style: italic; -} diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/js/fido-u2f-admin-inline-edit.js b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/js/fido-u2f-admin-inline-edit.js deleted file mode 100644 index b7b0123e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/js/fido-u2f-admin-inline-edit.js +++ /dev/null @@ -1,150 +0,0 @@ -/* global window, document, jQuery, inlineEditL10n, ajaxurl */ -var inlineEditKey; - -( function( $ ) { - inlineEditKey = { - - init: function() { - var t = this, - row = $( '#security-keys-section #inline-edit' ); - - t.what = '#key-'; - - $( '#security-keys-section #the-list' ).on( 'click', 'a.editinline', function() { - inlineEditKey.edit( this ); - return false; - } ); - - // Prepare the edit row. - row.keyup( function( event ) { - if ( 27 === event.which ) { - return inlineEditKey.revert(); - } - } ); - - $( 'a.cancel', row ).click( function() { - return inlineEditKey.revert(); - } ); - - $( 'a.save', row ).click( function() { - return inlineEditKey.save( this ); - } ); - - $( 'input, select', row ).keydown( function( event ) { - if ( 13 === event.which ) { - return inlineEditKey.save( this ); - } - } ); - }, - - toggle: function( el ) { - var t = this; - - if ( 'none' === $( t.what + t.getId( el ) ).css( 'display' ) ) { - t.revert(); - } else { - t.edit( el ); - } - }, - - edit: function( id ) { - var editRow, rowData, val, - t = this; - t.revert(); - - if ( 'object' === typeof id ) { - id = t.getId( id ); - } - - editRow = $( '#inline-edit' ).clone( true ); - rowData = $( '#inline_' + id ); - - $( 'td', editRow ).attr( 'colspan', $( 'th:visible, td:visible', '#security-keys-section .widefat thead' ).length ); - - $( t.what + id ).hide().after( editRow ).after( '' ); - - val = $( '.name', rowData ); - val.find( 'img' ).replaceWith( function() { - return this.alt; - } ); - val = val.text(); - $( ':input[name="name"]', editRow ).val( val ); - - $( editRow ).attr( 'id', 'edit-' + id ).addClass( 'inline-editor' ).show(); - $( '.ptitle', editRow ).eq( 0 ).focus(); - - return false; - }, - - save: function( id ) { - var params, fields; - - if ( 'object' === typeof id ) { - id = this.getId( id ); - } - - $( '#security-keys-section table.widefat .spinner' ).addClass( 'is-active' ); - - params = { - action: 'inline-save-key', - keyHandle: id, - user_id: window.u2fL10n.user_id - }; - - fields = $( '#edit-' + id ).find( ':input' ).serialize(); - params = fields + '&' + $.param( params ); - - // Make ajax request. - $.post( ajaxurl, params, - function( r ) { - var row, newID; - $( '#security-keys-section table.widefat .spinner' ).removeClass( 'is-active' ); - - if ( r ) { - if ( -1 !== r.indexOf( '' )[0].submit.call( $( '#your-profile' )[0] ); - } ); - } ); -}( jQuery ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/js/fido-u2f-login.js b/wp-content/upgrade-temp-backup/plugins/two-factor/providers/js/fido-u2f-login.js deleted file mode 100644 index 28295307..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/providers/js/fido-u2f-login.js +++ /dev/null @@ -1,16 +0,0 @@ -/* global window, u2f, u2fL10n, jQuery */ -( function( $ ) { - if ( ! window.u2fL10n ) { - window.console.error( 'u2fL10n is not defined' ); - return; - } - - u2f.sign( u2fL10n.request[0].appId, u2fL10n.request[0].challenge, u2fL10n.request, function( data ) { - if ( data.errorCode ) { - window.console.error( 'Registration Failed', data.errorCode ); - } else { - $( '#u2f_response' ).val( JSON.stringify( data ) ); - $( '#loginform' ).submit(); - } - } ); -}( jQuery ) ); diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/readme.txt b/wp-content/upgrade-temp-backup/plugins/two-factor/readme.txt deleted file mode 100644 index 8143c1c4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/readme.txt +++ /dev/null @@ -1,55 +0,0 @@ -=== Two-Factor === -Contributors: georgestephanis, valendesigns, stevenkword, extendwings, sgrant, aaroncampbell, johnbillion, stevegrunwell, netweb, kasparsd, alihusnainarshad, passoniate -Tags: 2fa, mfa, totp, authentication, security -Tested up to: 6.7 -Stable tag: 0.13.0 -License: GPL-2.0-or-later -License URI: https://spdx.org/licenses/GPL-2.0-or-later.html - -Enable Two-Factor Authentication (2FA) using time-based one-time passwords (TOTP), Universal 2nd Factor (U2F), email, and backup verification codes. - -== Description == - -Use the "Two-Factor Options" section under "Users" → "Your Profile" to enable and configure one or multiple two-factor authentication providers for your account: - -- Email codes -- Time Based One-Time Passwords (TOTP) -- FIDO Universal 2nd Factor (U2F) -- Backup Codes -- Dummy Method (only for testing purposes) - -For more history, see [this post](https://georgestephanis.wordpress.com/2013/08/14/two-cents-on-two-factor/). - -= Actions & Filters = - -Here is a list of action and filter hooks provided by the plugin: - -- `two_factor_providers` filter overrides the available two-factor providers such as email and time-based one-time passwords. Array values are PHP classnames of the two-factor providers. -- `two_factor_providers_for_user` filter overrides the available two-factor providers for a specific user. Array values are instances of provider classes and the user object `WP_User` is available as the second argument. -- `two_factor_enabled_providers_for_user` filter overrides the list of two-factor providers enabled for a user. First argument is an array of enabled provider classnames as values, the second argument is the user ID. -- `two_factor_user_authenticated` action which receives the logged in `WP_User` object as the first argument for determining the logged in user right after the authentication workflow. -- `two_factor_email_token_ttl` filter overrides the time interval in seconds that an email token is considered after generation. Accepts the time in seconds as the first argument and the ID of the `WP_User` object being authenticated. -- `two_factor_email_token_length` filter overrides the default 8 character count for email tokens. -- `two_factor_backup_code_length` filter overrides the default 8 character count for backup codes. Providers the `WP_User` of the associated user as the second argument. - -== Frequently Asked Questions == - -= How can I send feedback or get help with a bug? = - -The best place to report bugs, feature suggestions, or any other (non-security) feedback is at the Two Factor GitHub issues page. Before submitting a new issue, please search the existing issues to check if someone else has reported the same feedback. - -= Where can I report security bugs? = - -The plugin contributors and WordPress community take security bugs seriously. We appreciate your efforts to responsibly disclose your findings, and will make every effort to acknowledge your contributions. - -To report a security issue, please visit the [WordPress HackerOne](https://hackerone.com/wordpress) program. - -== Screenshots == - -1. Two-factor options under User Profile. -2. U2F Security Keys section under User Profile. -3. Email Code Authentication during WordPress Login. - -== Changelog == - -See the [release history](https://github.com/wordpress/two-factor/releases). diff --git a/wp-content/upgrade-temp-backup/plugins/two-factor/two-factor.php b/wp-content/upgrade-temp-backup/plugins/two-factor/two-factor.php deleted file mode 100644 index 2221a75d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/two-factor/two-factor.php +++ /dev/null @@ -1,55 +0,0 @@ - - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - {one line to give the program's name and a brief idea of what it does.} - Copyright (C) {year} {name of author} - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - {project} Copyright (C) {year} {fullname} - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. - diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/README.md b/wp-content/upgrade-temp-backup/plugins/wp-piwik/README.md deleted file mode 100644 index 51ab1815..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/README.md +++ /dev/null @@ -1,9 +0,0 @@ -# Connect Matomo (former WP-Matomo, WP-Piwik) - -This [WordPress](https://wordpress.org) plugin adds a [Matomo](http://matomo.org) stats site to your blog's dashboard. It's also able to add the Matomo tracking code to your blog. - -## How to use this plugin - -To use this plugin you will need your own Matomo instance. If you do not already have a Matomo setup, you have two simple options: use either [self-hosted](http://matomo.org/) or [cloud-hosted](http://matomo.org/hosting/). - -This repository was created to develop and maintain Connect Matomo (WP-Matomo, WP-Piwik). Please see the WordPress plugin directory if you like to use this plugin: https://wordpress.org/plugins/wp-piwik/ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/bitcoin.png b/wp-content/upgrade-temp-backup/plugins/wp-piwik/bitcoin.png deleted file mode 100644 index e565fabb..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/bitcoin.png and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik.php deleted file mode 100644 index fc01f7ab..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik.php +++ /dev/null @@ -1,1360 +0,0 @@ - - * @package WP_Piwik - */ -class WP_Piwik { - - private static $revisionId = 2023092201, $version = '1.0.30', $blog_id, $pluginBasename = NULL, $logger, $settings, $request, $optionsPageId; - public $statsPageId; - - /** - * Constructor class to configure and register all WP-Piwik components - */ - public function __construct() { - global $blog_id; - self::$blog_id = (isset ( $blog_id ) ? $blog_id : 'n/a'); - $this->openLogger (); - $this->openSettings (); - $this->setup (); - $this->addFilters (); - $this->addActions (); - $this->addShortcodes (); - } - - /** - * Destructor class to finish logging - */ - public function __destruct() { - $this->closeLogger (); - } - - /** - * Setup class to prepare settings and check for installation and update - */ - private function setup() { - self::$pluginBasename = plugin_basename ( __FILE__ ); - if (! $this->isInstalled ()) - $this->installPlugin (); - elseif ($this->isUpdated ()) - $this->updatePlugin (); - if ($this->isConfigSubmitted ()) - $this->applySettings (); - self::$settings->save (); - } - - /** - * Register WordPress actions - */ - private function addActions() { - if ( is_admin () ) { - add_action ( 'admin_menu', array ( - $this, - 'buildAdminMenu' - ) ); - add_action ( 'admin_post_save_wp-piwik_stats', array ( - $this, - 'onStatsPageSaveChanges' - ) ); - add_action ( 'load-post.php', array ( - $this, - 'addPostMetaboxes' - ) ); - add_action ( 'load-post-new.php', array ( - $this, - 'addPostMetaboxes' - ) ); - if ($this->isNetworkMode ()) { - add_action ( 'network_admin_notices', array ( - $this, - 'showNotices' - ) ); - add_action ( 'network_admin_menu', array ( - $this, - 'buildNetworkAdminMenu' - ) ); - add_action ( 'update_site_option_blogname', array ( - $this, - 'onBlogNameChange' - ) ); - add_action ( 'update_site_option_siteurl', array ( - $this, - 'onSiteUrlChange' - ) ); - } else { - add_action ( 'admin_notices', array ( - $this, - 'showNotices' - ) ); - add_action ( 'update_option_blogname', array ( - $this, - 'onBlogNameChange' - ) ); - add_action ( 'update_option_siteurl', array ( - $this, - 'onSiteUrlChange' - ) ); - } - if ($this->isDashboardActive ()) - add_action ( 'wp_dashboard_setup', array ( - $this, - 'extendWordPressDashboard' - ) ); - } - if ($this->isToolbarActive ()) { - add_action ( is_admin () ? 'admin_head' : 'wp_head', array ( - $this, - 'loadToolbarRequirements' - ) ); - add_action ( 'admin_bar_menu', array ( - $this, - 'extendWordPressToolbar' - ), 1000 ); - } - if ($this->isTrackingActive ()) { - if ( !is_admin () || $this->isAdminTrackingActive ()) { - $prefix = is_admin ()?'admin':'wp'; - add_action ( self::$settings->getGlobalOption ( 'track_codeposition' ) == 'footer' ? $prefix.'_footer' : $prefix.'_head', array ( - $this, - 'addJavascriptCode' - ) ); - if (self::$settings->getGlobalOption ( 'dnsprefetch' )) - add_action ( $prefix.'_head', array ( - $this, - 'addDNSPrefetchTag' - ) ); - if ($this->isAddNoScriptCode ()) - add_action ( $prefix.'_footer', array ( - $this, - 'addNoscriptCode' - ) ); - } - if (self::$settings->getGlobalOption ( 'add_post_annotations' )) - add_action ( 'transition_post_status', array ( - $this, - 'addPiwikAnnotation' - ), 10, 3 ); - } - - } - - /** - * Register WordPress filters - */ - private function addFilters() { - if (is_admin()) { - add_filter ( 'plugin_row_meta', array ( - $this, - 'setPluginMeta' - ), 10, 2 ); - add_filter ( 'screen_layout_columns', array ( - $this, - 'onScreenLayoutColumns' - ), 10, 2 ); - } elseif ($this->isTrackingActive ()) { - if ($this->isTrackFeed ()) { - add_filter ( 'the_excerpt_rss', array ( - $this, - 'addFeedTracking' - ) ); - add_filter ( 'the_content', array ( - $this, - 'addFeedTracking' - ) ); - } - if ($this->isAddFeedCampaign ()) { - add_filter ( 'post_link', array ( - $this, - 'addFeedCampaign' - ) ); - } - if ($this->isCrossDomainLinkingEnabled ()) { - add_filter ( 'wp_redirect', array ( - $this, - 'forwardCrossDomainVisitorId' - ) ); - } - } - } - - /** - * Register WordPress shortcodes - */ - private function addShortcodes() { - if ($this->isAddShortcode ()) - add_shortcode ( 'wp-piwik', array ( - $this, - 'shortcode' - ) ); - } - - /** - * Install WP-Piwik for the first time - */ - private function installPlugin($isUpdate = false) { - self::$logger->log ( 'Running Connect Matomo installation' ); - if (! $isUpdate) - $this->addNotice ( 'install', sprintf ( __ ( '%s %s installed.', 'wp-piwik' ), self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), self::$version ), __ ( 'Next you should connect to Matomo', 'wp-piwik' ) ); - self::$settings->setGlobalOption ( 'revision', self::$revisionId ); - self::$settings->setGlobalOption ( 'last_settings_update', time () ); - } - - /** - * Uninstall WP-Piwik - */ - public function uninstallPlugin() { - self::$logger->log ( 'Running Connect Matomo uninstallation' ); - if (! defined ( 'WP_UNINSTALL_PLUGIN' )) - exit (); - self::deleteWordPressOption ( 'wp-piwik-notices' ); - self::$settings->resetSettings ( true ); - } - - /** - * Update WP-Piwik - */ - private function updatePlugin() { - self::$logger->log ( 'Upgrade Connect Matomo to ' . self::$version ); - $patches = glob ( dirname ( __FILE__ ) . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR . 'update' . DIRECTORY_SEPARATOR . '*.php' ); - $isPatched = false; - if (is_array ( $patches )) { - sort ( $patches ); - foreach ( $patches as $patch ) { - $patchVersion = ( int ) pathinfo ( $patch, PATHINFO_FILENAME ); - if ($patchVersion && self::$settings->getGlobalOption ( 'revision' ) < $patchVersion) { - self::includeFile ( 'update' . DIRECTORY_SEPARATOR . $patchVersion ); - $isPatched = true; - } - } - } - if ((self::$settings->getGlobalOption('update_notice') == 'enabled') || ((self::$settings->getGlobalOption('update_notice') == 'script') && $isPatched)) - $this->addNotice ( 'update', sprintf ( __ ( '%s updated to %s.', 'wp-piwik' ), self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), self::$version ), __ ( 'Please validate your configuration', 'wp-piwik' ) ); - $this->installPlugin ( true ); - } - - /** - * Define a notice - * - * @param string $type - * identifier - * @param string $subject - * notice headline - * @param string $text - * notice content - * @param boolean $stay - * set to true if the message should persist (default: false) - */ - private function addNotice($type, $subject, $text, $stay = false) { - $notices = $this->getWordPressOption ( 'wp-piwik-notices', array () ); - $notices [$type] = array ( - 'subject' => $subject, - 'text' => $text, - 'stay' => $stay - ); - $this->updateWordPressOption ( 'wp-piwik-notices', $notices ); - } - - /** - * Show all notices defined previously - * - * @see addNotice() - */ - public function showNotices() { - $link = sprintf ( '%s', __ ( 'Settings', 'wp-piwik' ) ); - if ($notices = $this->getWordPressOption ( 'wp-piwik-notices' )) { - foreach ( $notices as $type => $notice ) { - printf ( '

            %s %s: %s: %s

            ', $notice ['subject'], __ ( 'Important', 'wp-piwik' ), $notice ['text'], $link ); - if (! $notice ['stay']) - unset ( $notices [$type] ); - } - } - $this->updateWordPressOption ( 'wp-piwik-notices', $notices ); - } - - /** - * Get the settings page URL - * - * @return string settings page URL - */ - private function getSettingsURL() { - return (self::$settings->checkNetworkActivation () ? 'settings' : 'options-general') . '.php?page=' . self::$pluginBasename; - } - - /** - * Echo javascript tracking code - */ - public function addJavascriptCode() { - if ($this->isHiddenUser ()) { - self::$logger->log ( 'Do not add tracking code to site (user should not be tracked) Blog ID: ' . self::$blog_id . ' Site ID: ' . self::$settings->getOption ( 'site_id' ) ); - return; - } - $trackingCode = new WP_Piwik\TrackingCode ( $this ); - $trackingCode->is404 = (is_404 () && self::$settings->getGlobalOption ( 'track_404' )); - $trackingCode->isUsertracking = self::$settings->getGlobalOption ( 'track_user_id' ) != 'disabled'; - $trackingCode->isSearch = (is_search () && self::$settings->getGlobalOption ( 'track_search' )); - self::$logger->log ( 'Add tracking code. Blog ID: ' . self::$blog_id . ' Site ID: ' . self::$settings->getOption ( 'site_id' ) ); - if ($this->isNetworkMode () && self::$settings->getGlobalOption ( 'track_mode' ) == 'manually') { - $siteId = $this->getPiwikSiteId (); - if ($siteId != 'n/a') - echo str_replace ( '{ID}', $siteId, $trackingCode->getTrackingCode () ); - else - echo ''; - } else - echo $trackingCode->getTrackingCode (); - } - - /** - * Echo DNS prefetch tag - */ - public function addDNSPrefetchTag() { - echo ''; - } - - /** - * Get Piwik Domain - */ - public function getPiwikDomain() { - switch (self::$settings->getGlobalOption ( 'piwik_mode' )) { - case 'php' : - return '//' . parse_url(self::$settings->getGlobalOption ( 'proxy_url' ), PHP_URL_HOST); - case 'cloud' : - return '//' . self::$settings->getGlobalOption ( 'piwik_user' ) . '.innocraft.cloud'; - case 'cloud-matomo' : - return '//' . self::$settings->getGlobalOption ( 'matomo_user' ) . '.matomo.cloud'; - default : - return '//' . parse_url(self::$settings->getGlobalOption ( 'piwik_url' ), PHP_URL_HOST); - } - } - - /** - * Echo noscript tracking code - */ - public function addNoscriptCode() { - if (self::$settings->getGlobalOption ( 'track_mode' ) == 'proxy') - return; - if ($this->isHiddenUser ()) { - self::$logger->log ( 'Do not add noscript code to site (user should not be tracked) Blog ID: ' . self::$blog_id . ' Site ID: ' . self::$settings->getOption ( 'site_id' ) ); - return; - } - self::$logger->log ( 'Add noscript code. Blog ID: ' . self::$blog_id . ' Site ID: ' . self::$settings->getOption ( 'site_id' ) ); - echo self::$settings->getOption ( 'noscript_code' ) . "\n"; - } - - /** - * Register post view meta boxes - */ - public function addPostMetaboxes() { - if (self::$settings->getGlobalOption ( 'add_customvars_box' )) { - add_action ( 'add_meta_boxes', array ( - new WP_Piwik\Template\MetaBoxCustomVars ( $this, self::$settings ), - 'addMetabox' - ) ); - add_action ( 'save_post', array ( - new WP_Piwik\Template\MetaBoxCustomVars ( $this, self::$settings ), - 'saveCustomVars' - ), 10, 2 ); - } - if (self::$settings->getGlobalOption ( 'perpost_stats' ) != "disabled") { - add_action ( 'add_meta_boxes', array ( - $this, - 'onloadPostPage' - ) ); - } - } - - /** - * Register admin menu components - */ - public function buildAdminMenu() { - if (self::isConfigured ()) { - $cap = 'wp-piwik_read_stats'; - if (self::$settings->checkNetworkActivation ()) { - global $current_user; - $userRoles = $current_user->roles; - $allowed = self::$settings->getGlobalOption ( 'capability_read_stats' ); - if (is_array($userRoles) && is_array($allowed)) - foreach ($userRoles as $userRole) - if (isset( $allowed[$userRole] ) && $allowed[$userRole]) { - $cap = 'read'; - break; - } - } - $statsPage = new WP_Piwik\Admin\Statistics ( $this, self::$settings ); - $this->statsPageId = add_dashboard_page ( __ ( 'Matomo Statistics', 'wp-piwik' ), self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), $cap, 'wp-piwik_stats', array ( - $statsPage, - 'show' - ) ); - $this->loadAdminStatsHeader ( $this->statsPageId, $statsPage ); - } - if (! self::$settings->checkNetworkActivation ()) { - $optionsPage = new WP_Piwik\Admin\Settings ( $this, self::$settings ); - self::$optionsPageId = add_options_page ( self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), 'activate_plugins', __FILE__, array ( - $optionsPage, - 'show' - ) ); - $this->loadAdminSettingsHeader ( self::$optionsPageId, $optionsPage ); - } - } - - /** - * Register network admin menu components - */ - public function buildNetworkAdminMenu() { - if (self::isConfigured ()) { - $statsPage = new WP_Piwik\Admin\Network ( $this, self::$settings ); - $this->statsPageId = add_dashboard_page ( __ ( 'Matomo Statistics', 'wp-piwik' ), self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), 'manage_sites', 'wp-piwik_stats', array ( - $statsPage, - 'show' - ) ); - $this->loadAdminStatsHeader ( $this->statsPageId, $statsPage ); - } - $optionsPage = new WP_Piwik\Admin\Settings ( $this, self::$settings ); - self::$optionsPageId = add_submenu_page ( 'settings.php', self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ), 'manage_sites', __FILE__, array ( - $optionsPage, - 'show' - ) ); - $this->loadAdminSettingsHeader ( self::$optionsPageId, $optionsPage ); - } - - /** - * Register admin header extensions for stats page - * - * @param $optionsPageId options - * page id - * @param $optionsPage options - * page object - */ - public function loadAdminStatsHeader($statsPageId, $statsPage) { - add_action ( 'admin_print_scripts-' . $statsPageId, array ( - $statsPage, - 'printAdminScripts' - ) ); - add_action ( 'admin_print_styles-' . $statsPageId, array ( - $statsPage, - 'printAdminStyles' - ) ); - add_action ( 'load-' . $statsPageId, array ( - $this, - 'onloadStatsPage' - ) ); - } - - /** - * Register admin header extensions for settings page - * - * @param $optionsPageId options - * page id - * @param $optionsPage options - * page object - */ - public function loadAdminSettingsHeader($optionsPageId, $optionsPage) { - add_action ( 'admin_head-' . $optionsPageId, array ( - $optionsPage, - 'extendAdminHeader' - ) ); - add_action ( 'admin_print_styles-' . $optionsPageId, array ( - $optionsPage, - 'printAdminStyles' - ) ); - } - - /** - * Register WordPress dashboard widgets - */ - public function extendWordPressDashboard() { - if (current_user_can ( 'wp-piwik_read_stats' )) { - if (self::$settings->getGlobalOption ( 'dashboard_widget' ) != 'disabled') - new WP_Piwik\Widget\Overview ( $this, self::$settings, 'dashboard', 'side', 'default', array ( - 'date' => self::$settings->getGlobalOption ( 'dashboard_widget' ), - 'period' => 'day' - ) ); - if (self::$settings->getGlobalOption ( 'dashboard_chart' )) - new WP_Piwik\Widget\Chart ( $this, self::$settings ); - if (self::$settings->getGlobalOption ( 'dashboard_ecommerce' )) - new WP_Piwik\Widget\Ecommerce ( $this, self::$settings ); - if (self::$settings->getGlobalOption ( 'dashboard_seo' )) - new WP_Piwik\Widget\Seo ( $this, self::$settings ); - } - } - - /** - * Register WordPress toolbar components - */ - public function extendWordPressToolbar($toolbar) { - if (current_user_can ( 'wp-piwik_read_stats' ) && is_admin_bar_showing ()) { - $id = WP_Piwik\Request::register ( 'VisitsSummary.getUniqueVisitors', array ( - 'period' => 'day', - 'date' => 'last30' - ) ); - $unique = $this->request ( $id ); - $url = is_network_admin () ? $this->getSettingsURL () : false; - $content = is_network_admin () ? __('Configure WP-Matomo', 'wp-piwik') : ''; - // Leave if result array does contain a message instead of valid data - if (isset($unique['result'])) - $content .= ''; - elseif (is_array ( $unique ) ) { - $labels = ""; - for ($i = 0; $i < count($unique); $i++) { - $labels .= $i.","; - } - ob_start(); - ?> -
            - -
            - - getStatsURL (); - } - $toolbar->add_menu ( array ( - 'id' => 'wp-piwik_stats', - 'title' => $content, - 'href' => $url - ) ); - } - } - - /** - * Add plugin meta data - * - * @param array $links - * list of already defined plugin meta data - * @param string $file - * handled file - * @return array complete list of plugin meta data - */ - public function setPluginMeta($links, $file) { - if ($file == 'wp-piwik/wp-piwik.php' && (!$this->isNetworkMode () || is_network_admin()) ) - return array_merge ( $links, array ( - sprintf ( '%s', self::getSettingsURL (), __ ( 'Settings', 'wp-piwik' ) ) - ) ); - return $links; - } - - /** - * Prepare toolbar widget requirements - */ - public function loadToolbarRequirements() { - if (is_admin_bar_showing ()) { - wp_enqueue_script ( 'wp-piwik-chartjs', $this->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - } - } - - /** - * Add tracking pixels to feed content - * - * @param string $content - * post content - * @return string post content extended by tracking pixel - */ - public function addFeedTracking($content) { - global $post; - if (is_feed ()) { - self::$logger->log ( 'Add tracking image to feed entry.' ); - if (! self::$settings->getOption ( 'site_id' )) { - $siteId = $this->requestPiwikSiteId (); - if ($siteId != 'n/a') - self::$settings->setOption ( 'site_id', $siteId ); - else - return false; - } - $title = the_title ( null, null, false ); - $posturl = get_permalink ( $post->ID ); - $urlref = get_bloginfo ( 'rss2_url' ); - if (self::$settings->getGlobalOption ( 'track_mode' ) == 'proxy') - $url = plugins_url ( 'wp-piwik' ) . '/proxy/matomo.php'; - else { - $url = self::$settings->getGlobalOption ( 'piwik_url' ); - if (substr($url, -10, 10) == '/index.php') - $url = str_replace('/index.php', '/matomo.php', $url); - else - $url .= 'piwik.php'; - } - $trackingImage = $url . '?idsite=' . self::$settings->getOption ( 'site_id' ) . '&rec=1&url=' . urlencode ( $posturl ) . '&action_name=' . urlencode ( $title ) . '&urlref=' . urlencode ( $urlref ); - $content .= ''; - } - return $content; - } - - /** - * Add a campaign parameter to feed permalink - * - * @param string $permalink - * permalink - * @return string permalink extended by campaign parameter - */ - public function addFeedCampaign($permalink) { - global $post; - if (is_feed ()) { - self::$logger->log ( 'Add campaign to feed permalink.' ); - $sep = (strpos ( $permalink, '?' ) === false ? '?' : '&'); - $permalink .= $sep . 'pk_campaign=' . urlencode ( self::$settings->getGlobalOption ( 'track_feed_campaign' ) ) . '&pk_kwd=' . urlencode ( $post->post_name ); - } - return $permalink; - } - - /** - * Forwards the cross domain parameter pk_vid if the URL parameter is set and a user is about to be redirected. - * When another website links to WooCommerce with a pk_vid parameter, and WooCommerce redirects the user to another - * URL, the pk_vid parameter would get lost and the visitorId would later not be applied by the tracking code - * due to the lost pk_vid URL parameter. If the URL parameter is set, we make sure to forward this parameter. - * - * @param string $location - * - * @return string location extended by pk_vid URL parameter if the URL parameter is set - */ - public function forwardCrossDomainVisitorId($location) { - - if (!empty($_GET['pk_vid']) - && preg_match('/^[a-zA-Z0-9]{24,48}$/', $_GET['pk_vid'])) { - // currently, the pk_vid parameter is 32 characters long, but it may vary over time. - $location = add_query_arg( 'pk_vid', $_GET['pk_vid'], $location ); - } - - return $location; - } - - /** - * Apply settings update - * - * @return boolean settings update applied - */ - private function applySettings() { - self::$settings->applyChanges ( $_POST ['wp-piwik'] ); - self::$settings->setGlobalOption ( 'revision', self::$revisionId ); - self::$settings->setGlobalOption ( 'last_settings_update', time () ); - return true; - } - - /** - * Check if WP-Piwik is configured - * - * @return boolean Is WP-Piwik configured? - */ - public static function isConfigured() { - return (self::$settings->getGlobalOption ( 'piwik_token' ) && (self::$settings->getGlobalOption ( 'piwik_mode' ) != 'disabled') && (((self::$settings->getGlobalOption ( 'piwik_mode' ) == 'http') && (self::$settings->getGlobalOption ( 'piwik_url' ))) || ((self::$settings->getGlobalOption ( 'piwik_mode' ) == 'php') && (self::$settings->getGlobalOption ( 'piwik_path' ))) || ((self::$settings->getGlobalOption ( 'piwik_mode' ) == 'cloud') && (self::$settings->getGlobalOption ( 'piwik_user' ))) || ((self::$settings->getGlobalOption ( 'piwik_mode' ) == 'cloud-matomo') && (self::$settings->getGlobalOption ( 'matomo_user' ))))); - } - - /** - * Check if WP-Piwik was updated - * - * @return boolean Was WP-Piwik updated? - */ - private function isUpdated() { - return self::$settings->getGlobalOption ( 'revision' ) && self::$settings->getGlobalOption ( 'revision' ) < self::$revisionId; - } - - /** - * Check if WP-Piwik is already installed - * - * @return boolean Is WP-Piwik installed? - */ - private function isInstalled() { - $oldSettings = $this->getWordPressOption ( 'wp-piwik_global-settings', false ); - if ($oldSettings && isset( $oldSettings['revision'] )) { - self::log('Save old settings'); - self::$settings->setGlobalOption ( 'revision', $oldSettings['revision'] ); - } else self::log( 'Current revision '.self::$settings->getGlobalOption ( 'revision' ) ); - return self::$settings->getGlobalOption ( 'revision' ) > 0; - } - - /** - * Check if new settings were submitted - * - * @return boolean Are new settings submitted? - */ - public static function isConfigSubmitted() { - return isset ( $_POST ) && isset ( $_POST ['wp-piwik'] ) && self::isValidOptionsPost(); - } - - /** - * Check if PHP mode is chosen - * - * @return Is PHP mode chosen? - */ - public function isPHPMode() { - return self::$settings->getGlobalOption ( 'piwik_mode' ) && self::$settings->getGlobalOption ( 'piwik_mode' ) == 'php'; - } - - /** - * Check if WordPress is running in network mode - * - * @return boolean Is WordPress running in network mode? - */ - public function isNetworkMode() { - return self::$settings->checkNetworkActivation (); - } - - /** - * Check if a WP-Piwik dashboard widget is enabled - * - * @return boolean Is a dashboard widget enabled? - */ - private function isDashboardActive() { - return self::$settings->getGlobalOption ( 'dashboard_widget' ) || self::$settings->getGlobalOption ( 'dashboard_chart' ) || self::$settings->getGlobalOption ( 'dashboard_seo' ); - } - - /** - * Check if a WP-Piwik toolbar widget is enabled - * - * @return boolean Is a toolbar widget enabled? - */ - private function isToolbarActive() { - return self::$settings->getGlobalOption ( 'toolbar' ); - } - - /** - * Check if WP-Piwik tracking code insertion is enabled - * - * @return boolean Insert tracking code? - */ - private function isTrackingActive() { - return self::$settings->getGlobalOption ( 'track_mode' ) != 'disabled'; - } - - /** - * Check if admin tracking is enabled - * - * @return boolean Is admin tracking enabled? - */ - private function isAdminTrackingActive() { - return self::$settings->getGlobalOption ( 'track_admin' ) && is_admin (); - } - - /** - * Check if WP-Piwik noscript code insertion is enabled - * - * @return boolean Insert noscript code? - */ - private function isAddNoScriptCode() { - return self::$settings->getGlobalOption ( 'track_noscript' ); - } - - /** - * Check if feed tracking is enabled - * - * @return boolean Is feed tracking enabled? - */ - private function isTrackFeed() { - return self::$settings->getGlobalOption ( 'track_feed' ); - } - - /** - * Check if feed permalinks get a campaign parameter - * - * @return boolean Add campaign parameter to feed permalinks? - */ - private function isAddFeedCampaign() { - return self::$settings->getGlobalOption ( 'track_feed_addcampaign' ); - } - - /** - * Check if feed permalinks get a campaign parameter - * - * @return boolean Add campaign parameter to feed permalinks? - */ - private function isCrossDomainLinkingEnabled() { - return self::$settings->getGlobalOption ( 'track_crossdomain_linking' ); - } - - /** - * Check if WP-Piwik shortcodes are enabled - * - * @return boolean Are shortcodes enabled? - */ - private function isAddShortcode() { - return self::$settings->getGlobalOption ( 'shortcodes' ); - } - - /** - * Define Piwik constants for PHP reporting API - */ - public static function definePiwikConstants() { - if (! defined ( 'PIWIK_INCLUDE_PATH' )) { - //@header('Content-type: text/html'); - define ( 'PIWIK_INCLUDE_PATH', self::$settings->getGlobalOption ( 'piwik_path' ) ); - define ( 'PIWIK_USER_PATH', self::$settings->getGlobalOption ( 'piwik_path' ) ); - define ( 'PIWIK_ENABLE_DISPATCH', false ); - define ( 'PIWIK_ENABLE_ERROR_HANDLER', false ); - define ( 'PIWIK_ENABLE_SESSION_START', false ); - } - } - - /** - * Start chosen logging method - */ - private function openLogger() { - switch (WP_PIWIK_ACTIVATE_LOGGER) { - case 1 : - self::$logger = new WP_Piwik\Logger\Screen ( __CLASS__ ); - break; - case 2 : - self::$logger = new WP_Piwik\Logger\File ( __CLASS__ ); - break; - default : - self::$logger = new WP_Piwik\Logger\Dummy ( __CLASS__ ); - } - } - - /** - * Log a message - * - * @param string $message - * logger message - */ - public static function log($message) { - self::$logger->log ( $message ); - } - - /** - * End logging - */ - private function closeLogger() { - self::$logger = null; - } - - /** - * Load WP-Piwik settings - */ - private function openSettings() { - self::$settings = new WP_Piwik\Settings ( $this, self::$logger ); - if (! $this->isConfigSubmitted () && $this->isPHPMode () && ! defined ( 'PIWIK_INCLUDE_PATH' )) - self::definePiwikConstants (); - } - - /** - * Include a WP-Piwik file - */ - private function includeFile($strFile) { - self::$logger->log ( 'Include ' . $strFile . '.php' ); - if (WP_PIWIK_PATH . $strFile . '.php') - include (WP_PIWIK_PATH . $strFile . '.php'); - } - - /** - * Check if user should not be tracked - * - * @return boolean Do not track user? - */ - private function isHiddenUser() { - if (is_multisite ()) - foreach ( self::$settings->getGlobalOption ( 'capability_stealth' ) as $key => $val ) - if ($val && current_user_can ( $key )) - return true; - return current_user_can ( 'wp-piwik_stealth' ); - } - - /** - * Check if tracking code is up to date - * - * @return boolean Is tracking code up to date? - */ - public function isCurrentTrackingCode() { - return (self::$settings->getOption ( 'last_tracking_code_update' ) && self::$settings->getOption ( 'last_tracking_code_update' ) > self::$settings->getGlobalOption ( 'last_settings_update' )); - } - - /** - * DEPRECTAED Add javascript code to site header - * - * @deprecated - * - */ - public function site_header() { - self::$logger->log ( 'Using deprecated function site_header' ); - $this->addJavascriptCode (); - } - - /** - * DEPRECTAED Add javascript code to site footer - * - * @deprecated - * - */ - public function site_footer() { - self::$logger->log ( 'Using deprecated function site_footer' ); - $this->addNoscriptCode (); - } - - /** - * Identify new posts if an annotation is required - * and create Piwik annotation - * - * @param string $newStatus - * new post status - * @param strint $oldStatus - * new post status - * @param object $post - * current post object - */ - public function addPiwikAnnotation($newStatus, $oldStatus, $post) { - $enabledPostTypes = self::$settings->getGlobalOption ( 'add_post_annotations' ); - if (isset($enabledPostTypes[$post->post_type]) && $enabledPostTypes[$post->post_type] && $newStatus == 'publish' && $oldStatus != 'publish') { - $note = 'Published: ' . $post->post_title . ' - URL: ' . get_permalink ( $post->ID ); - $id = WP_Piwik\Request::register ( 'Annotations.add', array ( - 'idSite' => $this->getPiwikSiteId (), - 'date' => date ( 'Y-m-d' ), - 'note' => $note - ) ); - $result = $this->request ( $id ); - self::$logger->log ( 'Add post annotation. ' . $note . ' - ' . serialize ( $result ) ); - } - } - - /** - * Get WP-Piwik's URL - */ - public function getPluginURL() { - return trailingslashit ( plugin_dir_url( dirname( __FILE__ ) ) ); - } - - /** - * Get WP-Piwik's version - */ - public function getPluginVersion() { - return self::$version; - } - - /** - * Enable three columns for WP-Piwik stats screen - * - * @param - * array full list of column settings - * @param - * mixed current screen id - * @return array updated list of column settings - */ - public function onScreenLayoutColumns($columns, $screen) { - if (isset( $this->statsPageId ) && $screen == $this->statsPageId) - $columns [$this->statsPageId] = 3; - return $columns; - } - - /** - * Add tracking code to admin header - */ - function addAdminHeaderTracking() { - $this->addJavascriptCode (); - } - - /** - * Get option value - * - * @param string $key - * option key - * @return mixed option value - */ - public function getOption($key) { - return self::$settings->getOption ( $key ); - } - - /** - * Get global option value - * - * @param string $key - * global option key - * @return mixed global option value - */ - public function getGlobalOption($key) { - return self::$settings->getGlobalOption ( $key ); - } - - /** - * Get stats page URL - * - * @return string stats page URL - */ - public function getStatsURL() { - return admin_url () . '?page=wp-piwik_stats'; - } - - /** - * Execute WP-Piwik test script - */ - private function loadTestscript() { - $this->includeFile ( 'debug' . DIRECTORY_SEPARATOR . 'testscript' ); - } - - /** - * Echo an error message - * - * @param string $message - * message content - */ - private static function showErrorMessage($message) { - echo '' . __ ( 'An error occured', 'wp-piwik' ) . ': ' . $message . ' [' . __ ( 'Support', 'wp-piwik' ) . ']'; - } - - /** - * Perform a Piwik request - * - * @param string $id - * request ID - * @return mixed request result - */ - public function request($id, $debug = false) { - if ( self::$settings->getGlobalOption ( 'piwik_mode' ) == 'disabled' ) - return 'n/a'; - if (! isset ( self::$request ) || empty ( self::$request )) - self::$request = (self::$settings->getGlobalOption ( 'piwik_mode' ) == 'http' || self::$settings->getGlobalOption ( 'piwik_mode' ) == 'cloud' || self::$settings->getGlobalOption ( 'piwik_mode' ) == 'cloud-matomo' ? new WP_Piwik\Request\Rest ( $this, self::$settings ) : new WP_Piwik\Request\Php ( $this, self::$settings )); - if ($debug) - return self::$request->getDebug ( $id ); - return self::$request->perform ( $id ); - } - - /** - * Reset request object - */ - public function resetRequest() { - if (is_object(self::$request)) - self::$request->reset(); - self::$request = NULL; - } - - /** - * Execute WP-Piwik shortcode - * - * @param array $attributes - * attribute list - */ - public function shortcode($attributes) { - shortcode_atts ( array ( - 'title' => '', - 'module' => 'overview', - 'period' => 'day', - 'date' => 'yesterday', - 'limit' => 10, - 'width' => '100%', - 'height' => '200px', - 'idsite' => '', - 'language' => 'en', - 'range' => false, - 'key' => 'sum_daily_nb_uniq_visitors' - ), $attributes ); - $shortcodeObject = new \WP_Piwik\Shortcode ( $attributes, $this, self::$settings ); - return $shortcodeObject->get(); - } - - /** - * Get Piwik site ID by blog ID - * - * @param int $blogId - * which blog's Piwik site ID to get, default is the current blog - * @return mixed Piwik site ID or n/a - */ - public function getPiwikSiteId($blogId = null, $forceFetch = false) { - if (! $blogId && $this->isNetworkMode ()) - $blogId = get_current_blog_id (); - $result = self::$settings->getOption ( 'site_id' ); - self::$logger->log ( 'Database result: ' . $result ); - return (! empty ( $result ) && ! $forceFetch ? $result : $this->requestPiwikSiteId ( $blogId )); - } - - /** - * Get a detailed list of all Piwik sites - * - * @return array Piwik sites - */ - public function getPiwikSiteDetails() { - $id = WP_Piwik\Request::register ( 'SitesManager.getSitesWithAtLeastViewAccess', array () ); - $piwikSiteDetails = $this->request ( $id ); - return $piwikSiteDetails; - } - - /** - * Estimate a Piwik site ID by blog ID - * - * @param int $blogId - * which blog's Piwik site ID to estimate, default is the current blog - * @return mixed Piwik site ID or n/a - */ - private function requestPiwikSiteId($blogId = null) { - $isCurrent = ! self::$settings->checkNetworkActivation () || empty ( $blogId ); - if (self::$settings->getGlobalOption ( 'auto_site_config' )) { - $id = WP_Piwik\Request::register ( 'SitesManager.getSitesIdFromSiteUrl', array ( - 'url' => $isCurrent ? get_bloginfo ( 'url' ) : get_blog_details ( $blogId )->siteurl - ) ); - $result = $this->request ( $id ); - $this->log ( 'Tried to identify current site, result: ' . serialize ( $result ) ); - if (is_array( $result ) && empty( $result )) - $result = $this->addPiwikSite ( $blogId ); - elseif ( $result != 'n/a' && isset($result [0]) ) - $result = $result [0] ['idsite']; - else $result = null; - } else $result = null; - self::$logger->log ( 'Get Matomo ID: WordPress site ' . ($isCurrent ? get_bloginfo ( 'url' ) : get_blog_details ( $blogId )->siteurl) . ' = Matomo ID ' . $result ); - if ($result !== null) { - self::$settings->setOption ( 'site_id', $result, $blogId ); - if (self::$settings->getGlobalOption ( 'track_mode' ) != 'disabled' && self::$settings->getGlobalOption ( 'track_mode' ) != 'manually') { - $code = $this->updateTrackingCode ( $result, $blogId ); - } - $this::$settings->save (); - return $result; - } - return 'n/a'; - } - - /** - * Add a new Piwik - * - * @param int $blogId - * which blog's Piwik site to create, default is the current blog - * @return int Piwik site ID - */ - public function addPiwikSite($blogId = null) { - $isCurrent = ! self::$settings->checkNetworkActivation () || empty ( $blogId ); - // Do not add site if Piwik connection is unreliable - if (! $this->request ( 'global.getPiwikVersion' )) - return null; - $id = WP_Piwik\Request::register ( 'SitesManager.addSite', array ( - 'urls' => $isCurrent ? get_bloginfo ( 'url' ) : get_blog_details ( $blogId )->siteurl, - 'siteName' => urlencode( $isCurrent ? get_bloginfo ( 'name' ) : get_blog_details ( $blogId )->blogname ) - ) ); - $result = $this->request ( $id ); - if ( is_array( $result ) && isset( $result['value'] ) ) { - $result = (int) $result['value']; - } else { - $result = (int) $result; - } - self::$logger->log ( 'Create Matomo ID: WordPress site ' . ($isCurrent ? get_bloginfo ( 'url' ) : get_blog_details ( $blogId )->siteurl) . ' = Matomo ID ' . $result ); - if (empty ( $result )) - return null; - else { - do_action('wp-piwik_site_created', $result); - return $result; - } - } - - /** - * Update a Piwik site's detail information - * - * @param int $siteId - * which Piwik site to updated - * @param int $blogId - * which blog's Piwik site ID to get, default is the current blog - */ - private function updatePiwikSite($siteId, $blogId = null) { - $isCurrent = ! self::$settings->checkNetworkActivation () || empty ( $blogId ); - $id = WP_Piwik\Request::register ( 'SitesManager.updateSite', array ( - 'idSite' => $siteId, - 'urls' => $isCurrent ? get_bloginfo ( 'url' ) : get_blog_details ( $blogId )->siteurl, - 'siteName' => $isCurrent ? get_bloginfo ( 'name' ) : get_blog_details ( $blogId )->blogname - ) ); - $this->request ( $id ); - self::$logger->log ( 'Update Matomo site: WordPress site ' . ($isCurrent ? get_bloginfo ( 'url' ) : get_blog_details ( $blogId )->siteurl) ); - } - - /** - * Update a site's tracking code - * - * @param int $siteId - * which Piwik site to updated - * @param int $blogId - * which blog's Piwik site ID to get, default is the current blog - * @return string tracking code - */ - public function updateTrackingCode($siteId = false, $blogId = null) { - if (!$siteId) - $siteId = $this->getPiwikSiteId (); - if (self::$settings->getGlobalOption ( 'track_mode' ) == 'disabled' || self::$settings->getGlobalOption ( 'track_mode' ) == 'manually') - return false; - $id = WP_Piwik\Request::register ( 'SitesManager.getJavascriptTag', array ( - 'idSite' => $siteId, - 'mergeSubdomains' => self::$settings->getGlobalOption ( 'track_across' ) ? 1 : 0, - 'mergeAliasUrls' => self::$settings->getGlobalOption ( 'track_across_alias' ) ? 1 : 0, - 'disableCookies' => self::$settings->getGlobalOption ( 'disable_cookies' ) ? 1 : 0, - 'crossDomain' => self::$settings->getGlobalOption ( 'track_crossdomain_linking' ) ? 1 : 0, - 'trackNoScript' => 1 - ) ); - $code = $this->request ( $id ); - if (is_array($code) && isset($code['value'])) - $code = $code['value']; - $result = !is_array ( $code ) ? html_entity_decode ( $code ) : ''; - self::$logger->log ( 'Delivered tracking code: ' . $result ); - $result = WP_Piwik\TrackingCode::prepareTrackingCode ( $result, self::$settings, self::$logger, true ); - if (isset ( $result ['script'] ) && ! empty ( $result ['script'] )) { - self::$settings->setOption ( 'tracking_code', $result ['script'], $blogId ); - self::$settings->setOption ( 'noscript_code', $result ['noscript'], $blogId ); - self::$settings->setGlobalOption ( 'proxy_url', $result ['proxy'] ); - } - return $result; - } - - /** - * Update Piwik site if blog name changes - * - * @param string $oldValue - * old blog name - * @param string $newValue - * new blog name - */ - public function onBlogNameChange($oldValue, $newValue = null) { - $this->updatePiwikSite ( self::$settings->getOption ( 'site_id' ) ); - } - - /** - * Update Piwik site if blog URL changes - * - * @param string $oldValue - * old blog URL - * @param string $newValue - * new blog URL - */ - public function onSiteUrlChange($oldValue, $newValue = null) { - $this->updatePiwikSite ( self::$settings->getOption ( 'site_id' ) ); - } - - /** - * Register stats page meta boxes - * - * @param mixed $statsPageId - * WordPress stats page ID - */ - public function onloadStatsPage($statsPageId) { - if (self::$settings->getGlobalOption ( 'disable_timelimit' )) - set_time_limit ( 0 ); - wp_enqueue_script ( 'common' ); - wp_enqueue_script ( 'wp-lists' ); - wp_enqueue_script ( 'postbox' ); - wp_enqueue_script ( 'wp-piwik', $this->getPluginURL () . 'js/wp-piwik.js', array (), self::$version, true ); - wp_enqueue_script ( 'wp-piwik-chartjs', $this->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - new \WP_Piwik\Widget\Chart ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Visitors ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Overview ( $this, self::$settings, $this->statsPageId ); - if (self::$settings->getGlobalOption ( 'stats_ecommerce' )) { - new \WP_Piwik\Widget\Ecommerce ($this, self::$settings, $this->statsPageId); - new \WP_Piwik\Widget\Items ($this, self::$settings, $this->statsPageId); - new \WP_Piwik\Widget\ItemsCategory ($this, self::$settings, $this->statsPageId); - } - if (self::$settings->getGlobalOption ( 'stats_seo' )) - new \WP_Piwik\Widget\Seo ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Pages ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Keywords ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Referrers ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Plugins ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Search ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Noresult ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Browsers ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\BrowserDetails ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Screens ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Types ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Models ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Systems ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\SystemDetails ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\City ( $this, self::$settings, $this->statsPageId ); - new \WP_Piwik\Widget\Country ( $this, self::$settings, $this->statsPageId ); - } - - /** - * Add per post statistics to a post's page - * - * @param mixed $postPageId - * WordPress post page ID - */ - public function onloadPostPage($postPageId) { - global $post; - $postUrl = get_permalink ( $post->ID ); - $this->log ( 'Load per post statistics: ' . $postUrl ); - $locations = apply_filters( 'wp-piwik_meta_boxes_locations', get_post_types( array( 'public' => true ), 'names' ) ); - array ( - new Post ( $this, self::$settings, $locations, 'side', 'default', array ( - 'date' => self::$settings->getGlobalOption ( 'perpost_stats' ), - 'period' => 'day', - 'url' => $postUrl - ) ), - 'show' - ); - } - - /** - * Stats page changes by POST submit - * - * @see http://tinyurl.com/5r5vnzs - */ - function onStatsPageSaveChanges() { - if (! current_user_can ( 'manage_options' )) - wp_die ( __ ( 'Cheatin’ uh?' ) ); - check_admin_referer ( 'wp-piwik_stats' ); - wp_redirect ( $_POST ['_wp_http_referer'] ); - } - - /** - * Get option value, choose method depending on network mode - * - * @param string $option option key - * @return string|array option value - */ - private function getWordPressOption($option, $default = null) { - return ($this->isNetworkMode () ? get_site_option ( $option, $default ) : get_option ( $option, $default )); - } - - /** - * Delete option, choose method depending on network mode - * - * @param string $option option key - */ - private function deleteWordPressOption($option) { - if ( $this->isNetworkMode () ) - delete_site_option ( $option ); - else - delete_option ( $option ); - } - - /** - * Set option value, choose method depending on network mode - * - * @param string $option option key - * @param mixed $value option value - */ - private function updateWordPressOption($option, $value) { - if ( $this->isNetworkMode () ) - update_site_option ( $option, $value ); - else - update_option ( $option, $value ); - } - - /** - * Check if WP-Piwik options page - * - * @return boolean True if current page is WP-Piwik's option page - */ - public static function isValidOptionsPost() { - return is_admin() && check_admin_referer( 'wp-piwik_settings' ) && current_user_can( 'manage_options' ) ; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin.php deleted file mode 100644 index ed07dd42..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin.php +++ /dev/null @@ -1,24 +0,0 @@ -getPluginURL().'css/wp-piwik.css', array(), self::$wpPiwik->getPluginVersion()); - } - - public function onLoad() {} - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Network.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Network.php deleted file mode 100644 index df3835db..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Network.php +++ /dev/null @@ -1,19 +0,0 @@ -getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL() . 'js/chartjs/chart.min.js', "3.4.1" ); - } - - public function onLoad() { - self::$wpPiwik->onloadStatsPage(self::$pageID); - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Settings.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Settings.php deleted file mode 100644 index 504a665d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Admin/Settings.php +++ /dev/null @@ -1,816 +0,0 @@ - - */ -class Settings extends \WP_Piwik\Admin { - - /** - * Builds and displays the settings page - */ - public function show() { - if (isset($_GET['sitebrowser']) && $_GET['sitebrowser']) { - new \WP_Piwik\Admin\Sitebrowser(self::$wpPiwik); - return; - } - if (isset($_GET['clear']) && $_GET['clear'] && check_admin_referer()) { - $this->clear($_GET['clear'] == 2); - self::$wpPiwik->resetRequest(); - echo '
            '; - return; - } elseif (self::$wpPiwik->isConfigSubmitted()) { - $this->showBox ( 'updated', 'yes', __ ( 'Changes saved.' ) ); - self::$wpPiwik->resetRequest(); - if (self::$settings->getGlobalOption('piwik_mode') == 'php') { - self::$wpPiwik->definePiwikConstants(); - } - if (self::$settings->getGlobalOption ( 'auto_site_config' ) && self::$wpPiwik->isConfigured ()) { - $siteId = self::$wpPiwik->getPiwikSiteId (null, true); - self::$wpPiwik->updateTrackingCode ( $siteId ); - self::$settings->setOption ( 'site_id', $siteId ); - } else { - self::$wpPiwik->updateTrackingCode(); - } - } - global $wp_roles; - ?> -
            - getHeadline ( 1, 'admin-generic', 'Settings', true ); - if (isset($_GET['testscript']) && $_GET['testscript']) - $this->runTestscript(); - ?> - isConfigured ()) { - $piwikVersion = self::$wpPiwik->request ( 'global.getPiwikVersion' ); - if (is_array ( $piwikVersion ) && isset( $piwikVersion['value'] )) - $piwikVersion = $piwikVersion['value']; - if (! empty ( $piwikVersion ) && !is_array( $piwikVersion )) - $this->showDonation(); - } - ?> -
            - - - - - '; - printf ( '', __ ( 'Thanks for using WP-Matomo!', 'wp-piwik' ) ); - if (self::$wpPiwik->isConfigured ()) { - if (! empty ( $piwikVersion ) && !is_array( $piwikVersion )) { - $this->showText ( sprintf ( __ ( 'WP-Matomo %s is successfully connected to Matomo %s.', 'wp-piwik' ), self::$wpPiwik->getPluginVersion (), $piwikVersion ) . ' ' . (! self::$wpPiwik->isNetworkMode () ? sprintf ( __ ( 'You are running WordPress %s.', 'wp-piwik' ), get_bloginfo ( 'version' ) ) : sprintf ( __ ( 'You are running a WordPress %s blog network (WPMU). WP-Matomo will handle your sites as different websites.', 'wp-piwik' ), get_bloginfo ( 'version' ) )) ); - } else { - $errorMessage = \WP_Piwik\Request::getLastError(); - if ( empty( $errorMessage ) ) - $this->showBox ( 'error', 'no', sprintf ( __ ( 'WP-Matomo %s was not able to connect to Matomo using your configuration. Check the »Connect to Matomo« section below.', 'wp-piwik' ), self::$wpPiwik->getPluginVersion () ) ); - else - $this->showBox ( 'error', 'no', sprintf ( __ ( 'WP-Matomo %s was not able to connect to Matomo using your configuration. During connection the following error occured:
            %s', 'wp-piwik' ), self::$wpPiwik->getPluginVersion (), $errorMessage ) ); - } - } else - $this->showBox ( 'error', 'no', sprintf ( __ ( 'WP-Matomo %s has to be connected to Matomo first. Check the »Connect to Matomo« section below.', 'wp-piwik' ), self::$wpPiwik->getPluginVersion () ) ); - - $tabs ['connect'] = array ( - 'icon' => 'admin-plugins', - 'name' => __('Connect to Matomo', 'wp-piwik') - ); - if (self::$wpPiwik->isConfigured ()) { - $tabs ['statistics'] = array ( - 'icon' => 'chart-pie', - 'name' => __('Show Statistics', 'wp-piwik') - ); - $tabs ['tracking'] = array ( - 'icon' => 'location-alt', - 'name' => __('Enable Tracking', 'wp-piwik') - ); - } - $tabs ['expert'] = array ( - 'icon' => 'shield', - 'name' => __('Expert Settings', 'wp-piwik') - ); - $tabs ['support'] = array ( - 'icon' => 'lightbulb', - 'name' => __('Support', 'wp-piwik') - ); - $tabs ['credits'] = array ( - 'icon' => 'groups', - 'name' => __('Credits', 'wp-piwik') - ); - - echo '

            %s
            '; - - if (! self::$wpPiwik->isConfigured ()) - $this->showBox ( 'updated', 'info', __ ( 'Before you can complete the setup, make sure you have a Matomo instance running. If you don\'t have one, you can', 'wp-piwik' ) .' ' . __ ('create a free account', 'wp-piwik' ) .' ' . __ ('or ', 'wp-piwik' ) .'' . __ ('install the "Matomo for WordPress" plugin', 'wp-piwik' ) .' ' . __ ('instead.', 'wp-piwik' ) ); - - if (! function_exists ( 'curl_init' ) && ! ini_get ( 'allow_url_fopen' )) - $this->showBox ( 'error', 'no', __ ( 'Neither cURL nor fopen are available. So WP-Matomo can not use the HTTP API and not connect to InnoCraft Cloud.' ) . ' ' . sprintf ( '%s.', 'https://wordpress.org/plugins/wp-piwik/faq/', __ ( 'More information', 'wp-piwik' ) ) ); - - $description = sprintf ( '%s
            %s: %s
            %s: %s
            %s: %s', __ ( 'You can choose between three connection methods:', 'wp-piwik' ), __ ( 'Self-hosted (HTTP API, default)', 'wp-piwik' ), __ ( 'This is the default option for a self-hosted Matomo and should work for most configurations. WP-Matomo will connect to Matomo using http(s).', 'wp-piwik' ), __ ( 'Self-hosted (PHP API)', 'wp-piwik' ), __ ( 'Choose this, if your self-hosted Matomo and WordPress are running on the same machine and you know the full server path to your Matomo instance.', 'wp-piwik' ), __ ( 'Cloud-hosted', 'wp-piwik' ), __ ( 'If you are using a cloud-hosted Matomo by InnoCraft, you can simply use this option. Be carefull to choose the option which fits to your cloud domain (matomo.cloud or innocraft.cloud).', 'wp-piwik' ) ); - $this->showSelect ( 'piwik_mode', __ ( 'Matomo Mode', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled (WP-Matomo will not connect to Matomo)', 'wp-piwik' ), - 'http' => __ ( 'Self-hosted (HTTP API, default)', 'wp-piwik' ), - 'php' => __ ( 'Self-hosted (PHP API)', 'wp-piwik' ), - 'cloud-matomo' => __('Cloud-hosted (Innocraft Cloud, *.matomo.cloud)', 'wp-piwik'), - 'cloud' => __ ( 'Cloud-hosted (InnoCraft Cloud, *.innocraft.cloud)', 'wp-piwik' ) - ), $description, 'jQuery(\'tr.wp-piwik-mode-option\').addClass(\'hidden\'); jQuery(\'.wp-piwik-mode-option-\' + jQuery(\'#piwik_mode\').val()).removeClass(\'hidden\');', false, '', self::$wpPiwik->isConfigured () ); - - $this->showInput ( 'piwik_url', __ ( 'Matomo URL', 'wp-piwik' ), __( 'Enter your Matomo URL. This is the same URL you use to access your Matomo instance, e.g. http://www.example.com/matomo/.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'piwik_mode' ) != 'http', 'wp-piwik-mode-option', 'http', self::$wpPiwik->isConfigured (), true ); - $this->showInput ( 'piwik_path', __ ( 'Matomo path', 'wp-piwik' ), __( 'Enter the file path to your Matomo instance, e.g. /var/www/matomo/.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'piwik_mode' ) != 'php', 'wp-piwik-mode-option', 'php', self::$wpPiwik->isConfigured (), true ); - $this->showInput ( 'piwik_user', __ ( 'Innocraft subdomain', 'wp-piwik' ), __( 'Enter your InnoCraft Cloud subdomain. It is also part of your URL: https://SUBDOMAIN.innocraft.cloud.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'piwik_mode' ) != 'cloud', 'wp-piwik-mode-option', 'cloud', self::$wpPiwik->isConfigured () ); - $this->showInput ( 'matomo_user', __ ( 'Matomo subdomain', 'wp-piwik' ), __( 'Enter your Matomo Cloud subdomain. It is also part of your URL: https://SUBDOMAIN.matomo.cloud.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'piwik_mode' ) != 'cloud-matomo', 'wp-piwik-mode-option', 'cloud-matomo', self::$wpPiwik->isConfigured () ); - $this->showInput ( 'piwik_token', __ ( 'Auth token', 'wp-piwik' ), __( 'Enter your Matomo auth token here. It is an alphanumerical code like 0a1b2c34d56e78901fa2bc3d45678efa.', 'wp-piwik' ).' '.sprintf ( __ ( 'See %sWP-Matomo FAQ%s.', 'wp-piwik' ), '', '' ), false, '', '', self::$wpPiwik->isConfigured (), true ); - - // Site configuration - $piwikSiteId = self::$wpPiwik->isConfigured () ? self::$wpPiwik->getPiwikSiteId () : false; - if (! self::$wpPiwik->isNetworkMode() ) { - $this->showCheckbox ( - 'auto_site_config', - __ ( 'Auto config', 'wp-piwik' ), - __ ( 'Check this to automatically choose your blog from your Matomo sites by URL. If your blog is not added to Matomo yet, WP-Matomo will add a new site.', 'wp-piwik' ), - false, - '', - '', - 'jQuery(\'tr.wp-piwik-auto-option\').toggle(\'hidden\');' . ($piwikSiteId ? 'jQuery(\'#site_id\').val(' . $piwikSiteId . ');' : '') - ); - if (self::$wpPiwik->isConfigured ()) { - $piwikSiteList = self::$wpPiwik->getPiwikSiteDetails (); - if (isset($piwikSiteList['result']) && $piwikSiteList['result'] == 'error') { - $this->showBox ( 'error', 'no', sprintf ( __ ( 'WP-Matomo %s was not able to get sites with at least view access:
            %s', 'wp-piwik' ), self::$wpPiwik->getPluginVersion (), $errorMessage ) ); - } else { - if (is_array($piwikSiteList)) - foreach ($piwikSiteList as $details) - $piwikSiteDetails[$details['idsite']] = $details; - unset($piwikSiteList); - if ($piwikSiteId != 'n/a' && isset($piwikSiteDetails) && is_array($piwikSiteDetails)) - $piwikSiteDescription = $piwikSiteDetails [$piwikSiteId] ['name'] . ' (' . $piwikSiteDetails [$piwikSiteId] ['main_url'] . ')'; - else - $piwikSiteDescription = 'n/a'; - echo ''; - if (isset ($piwikSiteDetails) && is_array($piwikSiteDetails)) - foreach ($piwikSiteDetails as $key => $siteData) - $siteList [$siteData['idsite']] = $siteData ['name'] . ' (' . $siteData ['main_url'] . ')'; - if (isset($siteList)) - $this->showSelect('site_id', __('Select site', 'wp-piwik'), $siteList, 'Choose the Matomo site corresponding to this blog.', '', self::$settings->getGlobalOption('auto_site_config'), 'wp-piwik-auto-option', true, false); - } - } - } else echo ''; - - echo $submitButton; - - echo '
            ' . __('Determined site', 'wp-piwik') . ':' . $piwikSiteDescription . '
            '; - // Stats configuration - $this->showSelect ( 'default_date', __ ( 'Matomo default date', 'wp-piwik' ), array ( - 'today' => __ ( 'Today', 'wp-piwik' ), - 'yesterday' => __ ( 'Yesterday', 'wp-piwik' ), - 'current_month' => __ ( 'Current month', 'wp-piwik' ), - 'last_month' => __ ( 'Last month', 'wp-piwik' ), - 'current_week' => __ ( 'Current week', 'wp-piwik' ), - 'last_week' => __ ( 'Last week', 'wp-piwik' ) - ), __ ( 'Default date shown on statistics page.', 'wp-piwik' ) ); - - $this->showCheckbox ( 'stats_seo', __ ( 'Show SEO data', 'wp-piwik' ), __ ( 'Display SEO ranking data on statistics page.', 'wp-piwik' ) . ' (' . __ ( 'Slow!', 'wp-piwik' ) . ')' ); - $this->showCheckbox ( 'stats_ecommerce', __ ( 'Show e-commerce data', 'wp-piwik' ), __ ( 'Display e-commerce data on statistics page.', 'wp-piwik' ) ); - - $this->showSelect ( 'dashboard_widget', __ ( 'Dashboard overview', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled', 'wp-piwik' ), - 'yesterday' => __ ( 'Yesterday', 'wp-piwik' ), - 'today' => __ ( 'Today', 'wp-piwik' ), - 'last30' => __ ( 'Last 30 days', 'wp-piwik' ), - 'last60' => __ ( 'Last 60 days', 'wp-piwik' ), - 'last90' => __ ( 'Last 90 days', 'wp-piwik' ) - ), __ ( 'Enable WP-Matomo dashboard widget "Overview".', 'wp-piwik' ) ); - - $this->showCheckbox ( 'dashboard_chart', __ ( 'Dashboard graph', 'wp-piwik' ), __ ( 'Enable WP-Matomo dashboard widget "Graph".', 'wp-piwik' ) ); - - $this->showCheckbox ( 'dashboard_seo', __ ( 'Dashboard SEO', 'wp-piwik' ), __ ( 'Enable WP-Matomo dashboard widget "SEO".', 'wp-piwik' ) . ' (' . __ ( 'Slow!', 'wp-piwik' ) . ')' ); - - $this->showCheckbox ( 'dashboard_ecommerce', __ ( 'Dashboard e-commerce', 'wp-piwik' ), __ ( 'Enable WP-Matomo dashboard widget "E-commerce".', 'wp-piwik' ) ); - - $this->showCheckbox ( 'toolbar', __ ( 'Show graph on WordPress Toolbar', 'wp-piwik' ), __ ( 'Display a last 30 days visitor graph on WordPress\' toolbar.', 'wp-piwik' ) ); - - echo ''; - - $this->showSelect ( 'perpost_stats', __ ( 'Show per post stats', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled', 'wp-piwik' ), - 'yesterday' => __ ( 'Yesterday', 'wp-piwik' ), - 'today' => __ ( 'Today', 'wp-piwik' ), - 'last30' => __ ( 'Last 30 days', 'wp-piwik' ), - 'last60' => __ ( 'Last 60 days', 'wp-piwik' ), - 'last90' => __ ( 'Last 90 days', 'wp-piwik' ) - ), __ ( 'Show stats about single posts at the post edit admin page.', 'wp-piwik' ) ); - - - $this->showCheckbox ( 'piwik_shortcut', __ ( 'Matomo shortcut', 'wp-piwik' ), __ ( 'Display a shortcut to Matomo itself.', 'wp-piwik' ) ); - - $this->showInput ( 'plugin_display_name', __ ( 'WP-Matomo display name', 'wp-piwik' ), __ ( 'Plugin name shown in WordPress.', 'wp-piwik' ) ); - - $this->showCheckbox ( 'shortcodes', __ ( 'Enable shortcodes', 'wp-piwik' ), __ ( 'Enable shortcodes in post or page content.', 'wp-piwik' ) ); - - echo $submitButton; - - echo ''; - - // Tracking Configuration - $isNotTracking = self::$settings->getGlobalOption ( 'track_mode' ) == 'disabled'; - $isNotGeneratedTracking = $isNotTracking || self::$settings->getGlobalOption ( 'track_mode' ) == 'manually'; - $fullGeneratedTrackingGroup = 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-proxy'; - - $description = sprintf ( '%s
            %s: %s
            %s: %s
            %s: %s
            %s: %s
            %s: %s', __ ( 'You can choose between four tracking code modes:', 'wp-piwik' ), __ ( 'Disabled', 'wp-piwik' ), __ ( 'WP-Matomo will not add the tracking code. Use this, if you want to add the tracking code to your template files or you use another plugin to add the tracking code.', 'wp-piwik' ), __ ( 'Default tracking', 'wp-piwik' ), __ ( 'WP-Matomo will use Matomo\'s standard tracking code.', 'wp-piwik' ), __ ( 'Use js/index.php', 'wp-piwik' ), __ ( 'You can choose this tracking code, to deliver a minified proxy code and to avoid using the files called piwik.js or piwik.php.', 'wp-piwik' ).' '.sprintf( __( 'See %sreadme file%s.', 'wp-piwik' ), '', ''), __ ( 'Use proxy script', 'wp-piwik' ), __ ( 'Use this tracking code to not reveal the Matomo server URL.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo FAQ%s.', 'wp-piwik' ), '', '' ) , __ ( 'Enter manually', 'wp-piwik' ), __ ( 'Enter your own tracking code manually. You can choose one of the prior options, pre-configure your tracking code and switch to manually editing at last.', 'wp-piwik' ).( self::$wpPiwik->isNetworkMode() ? ' '.__ ( 'Use the placeholder {ID} to add the Matomo site ID.', 'wp-piwik' ) : '' ) ); - $this->showSelect ( 'track_mode', __ ( 'Add tracking code', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled', 'wp-piwik' ), - 'default' => __ ( 'Default tracking', 'wp-piwik' ), - 'js' => __ ( 'Use js/index.php', 'wp-piwik' ), - 'proxy' => __ ( 'Use proxy script', 'wp-piwik' ), - 'manually' => __ ( 'Enter manually', 'wp-piwik' ) - ), $description, 'jQuery(\'tr.wp-piwik-track-option\').addClass(\'hidden\'); jQuery(\'tr.wp-piwik-track-option-\' + jQuery(\'#track_mode\').val()).removeClass(\'hidden\'); jQuery(\'#tracking_code, #noscript_code\').prop(\'readonly\', jQuery(\'#track_mode\').val() != \'manually\');' ); - - $this->showTextarea ( 'tracking_code', __ ( 'Tracking code', 'wp-piwik' ), 15, 'This is a preview of your current tracking code. If you choose to enter your tracking code manually, you can change it here.', $isNotTracking, 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-proxy wp-piwik-track-option-manually', true, '', (self::$settings->getGlobalOption ( 'track_mode' ) != 'manually'), false ); - - $this->showSelect ( 'track_codeposition', __ ( 'JavaScript code position', 'wp-piwik' ), array ( - 'footer' => __ ( 'Footer', 'wp-piwik' ), - 'header' => __ ( 'Header', 'wp-piwik' ) - ), __ ( 'Choose whether the JavaScript code is added to the footer or the header.', 'wp-piwik' ), '', $isNotTracking, 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-proxy wp-piwik-track-option-manually' ); - - $this->showTextarea ( 'noscript_code', __ ( 'Noscript code', 'wp-piwik' ), 2, 'This is a preview of your <noscript> code which is part of your tracking code.', self::$settings->getGlobalOption ( 'track_mode' ) == 'proxy', 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-manually', true, '', (self::$settings->getGlobalOption ( 'track_mode' ) != 'manually'), false ); - - $this->showCheckbox ( 'track_noscript', __ ( 'Add <noscript>', 'wp-piwik' ), __ ( 'Adds the <noscript> code to your footer.', 'wp-piwik' ) . ' ' . __ ( 'Disabled in proxy mode.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'track_mode' ) == 'proxy', 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-manually' ); - - $this->showCheckbox ( 'track_nojavascript', __ ( 'Add rec parameter to noscript code', 'wp-piwik' ), __ ( 'Enable tracking for visitors without JavaScript (not recommended).', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo FAQ%s.', 'wp-piwik' ), '', '' ) . ' ' . __ ( 'Disabled in proxy mode.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'track_mode' ) == 'proxy', 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-manually' ); - - $this->showSelect ( 'track_content', __ ( 'Enable content tracking', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled', 'wp-piwik' ), - 'all' => __ ( 'Track all content blocks', 'wp-piwik' ), - 'visible' => __ ( 'Track only visible content blocks', 'wp-piwik' ) - ), __ ( 'Content tracking allows you to track interaction with the content of a web page or application.' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), '', $isNotTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually' ); - - $this->showCheckbox ( 'track_search', __ ( 'Track search', 'wp-piwik' ), __ ( 'Use Matomo\'s advanced Site Search Analytics feature.' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), $isNotTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually' ); - - $this->showCheckbox ( 'track_404', __ ( 'Track 404', 'wp-piwik' ), __ ( 'WP-Matomo can automatically add a 404-category to track 404-page-visits.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo FAQ%s.', 'wp-piwik' ), '', '' ), $isNotTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually' ); - - echo ''; - echo ''; - - $this->showCheckbox ( 'add_customvars_box', __ ( 'Show custom variables box', 'wp-piwik' ), __ ( ' Show a "custom variables" edit box on post edit page.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually' ); - - $this->showInput ( 'add_download_extensions', __ ( 'Add new file types for download tracking', 'wp-piwik' ), __ ( 'Add file extensions for download tracking, divided by a vertical bar (|).', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup ); - - $this->showSelect ( 'require_consent', __ ( 'Tracking or cookie consent', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled', 'wp-piwik' ), - 'consent' => __ ( 'Require consent', 'wp-piwik' ), - 'cookieconsent' => __ ( 'Require cookie consent', 'wp-piwik' ) - ), __ ( 'Enable support for consent managers.' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), '', $isNotGeneratedTracking, $fullGeneratedTrackingGroup ); - - $this->showCheckbox ( 'disable_cookies', __ ( 'Disable cookies', 'wp-piwik' ), __ ( 'Disable all tracking cookies for a visitor.', 'wp-piwik' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup ); - - $this->showCheckbox ( 'limit_cookies', __ ( 'Limit cookie lifetime', 'wp-piwik' ), __ ( 'You can limit the cookie lifetime to avoid tracking your users over a longer period as necessary.', 'wp-piwik' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup, true, 'jQuery(\'tr.wp-piwik-cookielifetime-option\').toggleClass(\'wp-piwik-hidden\');' ); - - $this->showInput ( 'limit_cookies_visitor', __ ( 'Visitor timeout (seconds)', 'wp-piwik' ), false, $isNotGeneratedTracking || ! self::$settings->getGlobalOption ( 'limit_cookies' ), $fullGeneratedTrackingGroup.' wp-piwik-cookielifetime-option'. (self::$settings->getGlobalOption ( 'limit_cookies' )? '': ' wp-piwik-hidden') ); - - $this->showInput ( 'limit_cookies_session', __ ( 'Session timeout (seconds)', 'wp-piwik' ), false, $isNotGeneratedTracking || ! self::$settings->getGlobalOption ( 'limit_cookies' ), $fullGeneratedTrackingGroup .' wp-piwik-cookielifetime-option'. (self::$settings->getGlobalOption ( 'limit_cookies' )? '': ' wp-piwik-hidden') ); - - $this->showInput ( 'limit_cookies_referral', __ ( 'Referral timeout (seconds)', 'wp-piwik' ), false, $isNotGeneratedTracking || ! self::$settings->getGlobalOption ( 'limit_cookies' ), $fullGeneratedTrackingGroup .' wp-piwik-cookielifetime-option'. (self::$settings->getGlobalOption ( 'limit_cookies' )? '': ' wp-piwik-hidden') ); - - $this->showCheckbox ( 'track_admin', __ ( 'Track admin pages', 'wp-piwik' ), __ ( 'Enable to track users on admin pages (remember to configure the tracking filter appropriately).', 'wp-piwik' ), $isNotTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually' ); - - echo ''; - echo ''; - - $this->showCheckbox ( 'track_across', __ ( 'Track subdomains in the same website', 'wp-piwik' ), __ ( 'Adds *.-prefix to cookie domain.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup ); - - $this->showCheckbox ( 'track_across_alias', __ ( 'Do not count subdomains as outlink', 'wp-piwik' ), __ ( 'Adds *.-prefix to tracked domain.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup ); - - $this->showCheckbox ( 'track_crossdomain_linking', __ ( 'Enable cross domain linking', 'wp-piwik' ), __ ( 'When enabled, it will make sure to use the same visitor ID for the same visitor across several domains. This works only when this feature is enabled because the visitor ID is stored in a cookie and cannot be read on the other domain by default. When this feature is enabled, it will append a URL parameter "pk_vid" that contains the visitor ID when a user clicks on a URL that belongs to one of your domains. For this feature to work, you also have to configure which domains should be treated as local in your Matomo website settings. This feature requires Matomo 3.0.2.', 'wp-piwik' ), self::$settings->getGlobalOption ( 'track_mode' ) == 'proxy', 'wp-piwik-track-option wp-piwik-track-option-default wp-piwik-track-option-js wp-piwik-track-option-manually'); - - $this->showCheckbox ( 'track_feed', __ ( 'Track RSS feeds', 'wp-piwik' ), __ ( 'Enable to track posts in feeds via tracking pixel.', 'wp-piwik' ), $isNotTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually' ); - - $this->showCheckbox ( 'track_feed_addcampaign', __ ( 'Track RSS feed links as campaign', 'wp-piwik' ), __ ( 'This will add Matomo campaign parameters to the RSS feed links.' . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ), 'wp-piwik' ), $isNotTracking, $fullGeneratedTrackingGroup . ' wp-piwik-track-option-manually', true, 'jQuery(\'tr.wp-piwik-feed_campaign-option\').toggle(\'hidden\');' ); - - $this->showInput ( 'track_feed_campaign', __ ( 'RSS feed campaign', 'wp-piwik' ), __ ( 'Keyword: post name.', 'wp-piwik' ), $isNotGeneratedTracking || ! self::$settings->getGlobalOption ( 'track_feed_addcampaign' ), $fullGeneratedTrackingGroup . ' wp-piwik-feed_campaign-option' ); - - $this->showInput ( 'track_heartbeat', __ ( 'Enable heartbeat timer', 'wp-piwik' ), __ ( 'Enable a heartbeat timer to get more accurate visit lengths by sending periodical HTTP ping requests as long as the site is opened. Enter the time between the pings in seconds (Matomo default: 15) to enable or 0 to disable this feature. Note: This will cause a lot of additional HTTP requests on your site.', 'wp-piwik' ), $isNotGeneratedTracking, $fullGeneratedTrackingGroup ); - - $this->showSelect ( 'track_user_id', __ ( 'User ID Tracking', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled', 'wp-piwik' ), - 'uid' => __ ( 'WP User ID', 'wp-piwik' ), - 'email' => __ ( 'Email Address', 'wp-piwik' ), - 'username' => __ ( 'Username', 'wp-piwik' ), - 'displayname' => __ ( 'Display Name (Not Recommended!)', 'wp-piwik' ) - ), __ ( 'When a user is logged in to WordPress, track their "User ID". You can select which field from the User\'s profile is tracked as the "User ID". When enabled, Tracking based on Email Address is recommended.', 'wp-piwik' ), '', $isNotTracking, $fullGeneratedTrackingGroup ); - - echo $submitButton; - echo ''; - - $this->showText ( __ ( 'Usually, you do not need to change these settings. If you want to do so, you should know what you do or you got an expert\'s advice.', 'wp-piwik' ) ); - - $this->showCheckbox ( 'cache', __ ( 'Enable cache', 'wp-piwik' ), __ ( 'Cache API calls, which not contain today\'s values, for a week.', 'wp-piwik' ) ); - - if (function_exists('curl_init') && ini_get('allow_url_fopen')) - $this->showSelect ( 'http_connection', __ ( 'HTTP connection via', 'wp-piwik' ), array ( - 'curl' => __ ( 'cURL', 'wp-piwik' ), - 'fopen' => __ ( 'fopen', 'wp-piwik' ) - ), __('Choose whether WP-Matomo should use cURL or fopen to connect to Matomo in HTTP or Cloud mode.', 'wp-piwik' ) ); - - $this->showSelect ( 'http_method', __ ( 'HTTP method', 'wp-piwik' ), array ( - 'post' => __ ( 'POST', 'wp-piwik' ), - 'get' => __ ( 'GET', 'wp-piwik' ) - ), __('Choose whether WP-Matomo should use POST or GET in HTTP or Cloud mode.', 'wp-piwik' ) ); - - $this->showCheckbox ( 'disable_timelimit', __ ( 'Disable time limit', 'wp-piwik' ), __ ( 'Use set_time_limit(0) if stats page causes a time out.', 'wp-piwik' ) ); - - $this->showInput ( 'filter_limit', __ ( 'Filter limit', 'wp-piwik' ), __ ( 'Use filter_limit if you need to get more than 100 results per page.', 'wp-piwik' ) ); - - $this->showInput ( 'connection_timeout', __ ( 'Connection timeout', 'wp-piwik' ), 'Define a connection timeout for all HTTP requests done by WP-Matomo in seconds.' ); - - $this->showCheckbox ( 'disable_ssl_verify', __ ( 'Disable SSL peer verification', 'wp-piwik' ), '(' . __ ( 'not recommended', 'wp-piwik' ) . ')' ); - $this->showCheckbox ( 'disable_ssl_verify_host', __ ( 'Disable SSL host verification', 'wp-piwik' ), '(' . __ ( 'not recommended', 'wp-piwik' ) . ')' ); - - $this->showSelect ( 'piwik_useragent', __ ( 'User agent', 'wp-piwik' ), array ( - 'php' => __ ( 'Use the PHP default user agent', 'wp-piwik' ) . (ini_get ( 'user_agent' ) ? '(' . ini_get ( 'user_agent' ) . ')' : ' (' . __ ( 'empty', 'wp-piwik' ) . ')'), - 'own' => __ ( 'Define a specific user agent', 'wp-piwik' ) - ), 'WP-Matomo can send the default user agent defined by your PHP settings or use a specific user agent below. The user agent is send by WP-Matomo if HTTP requests are performed.', 'jQuery(\'tr.wp-piwik-useragent-option\').toggleClass(\'hidden\');' ); - $this->showInput ( 'piwik_useragent_string', __ ( 'Specific user agent', 'wp-piwik' ), 'Define a user agent description which is send by WP-Matomo if HTTP requests are performed.', self::$settings->getGlobalOption ( 'piwik_useragent' ) != 'own', 'wp-piwik-useragent-option' ); - - $this->showCheckbox ( 'dnsprefetch', __ ( 'Enable DNS prefetch', 'wp-piwik' ), __ ( 'Add a DNS prefetch tag.' . ' ' . sprintf ( __ ( 'See %sMatomo Blog%s.', 'wp-piwik' ), '', '' ), 'wp-piwik' ) ); - - $this->showCheckbox ( 'track_datacfasync', __ ( 'Add data-cfasync=false', 'wp-piwik' ), __ ( 'Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to ignore the script.' . ' ' . sprintf ( __ ( 'See %sCloudFlare Knowledge Base%s.', 'wp-piwik' ), '', '' ), 'wp-piwik' ) ); - - $this->showInput ( 'track_cdnurl', __ ( 'CDN URL', 'wp-piwik' ).' http://', 'Enter URL if you want to load the tracking code via CDN.' ); - - $this->showInput ( 'track_cdnurlssl', __ ( 'CDN URL (SSL)', 'wp-piwik' ).' https://', 'Enter URL if you want to load the tracking code via a separate SSL CDN.' ); - - $this->showSelect ( 'force_protocol', __ ( 'Force Matomo to use a specific protocol', 'wp-piwik' ), array ( - 'disabled' => __ ( 'Disabled (default)', 'wp-piwik' ), - 'http' => __ ( 'http', 'wp-piwik' ), - 'https' => __ ( 'https (SSL)', 'wp-piwik' ) - ), __ ( 'Choose if you want to explicitly force Matomo to use HTTP or HTTPS. Does not work with a CDN URL.', 'wp-piwik' ) ); - - $this->showCheckbox ( 'remove_type_attribute', __ ( 'Remove type attribute', 'wp-piwik' ), __ ( 'Removes the type attribute from Matomo\'s tracking code script tag.', 'wp-piwik') ); - - $this->showSelect ( 'update_notice', __ ( 'Update notice', 'wp-piwik' ), array ( - 'enabled' => __ ( 'Show always if WP-Matomo is updated', 'wp-piwik' ), - 'script' => __ ( 'Show only if WP-Matomo is updated and settings were changed', 'wp-piwik' ), - 'disabled' => __ ( 'Disabled', 'wp-piwik' ) - ), __ ( 'Choose if you want to get an update notice if WP-Matomo is updated.', 'wp-piwik' ) ); - - $this->showInput ( 'set_download_extensions', __ ( 'Define all file types for download tracking', 'wp-piwik' ), __ ( 'Replace Matomo\'s default file extensions for download tracking, divided by a vertical bar (|). Leave blank to keep Matomo\'s default settings.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo documentation%s.', 'wp-piwik' ), '', '' ) ); - - $this->showInput ( 'set_download_classes', __ ( 'Set classes to be treated as downloads', 'wp-piwik' ), __ ( 'Set classes to be treated as downloads (in addition to piwik_download), divided by a vertical bar (|). Leave blank to keep Matomo\'s default settings.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo JavaScript Tracking Client reference%s.', 'wp-piwik' ), '', '' ) ); - - $this->showInput ( 'set_link_classes', __ ( 'Set classes to be treated as outlinks', 'wp-piwik' ), __ ( 'Set classes to be treated as outlinks (in addition to piwik_link), divided by a vertical bar (|). Leave blank to keep Matomo\'s default settings.', 'wp-piwik' ) . ' ' . sprintf ( __ ( 'See %sMatomo JavaScript Tracking Client reference%s.', 'wp-piwik' ), '', '' ) ); - - echo $submitButton; - ?> - - - - - - - - - - - - - -
            -
            -showInputWrapper($id, $name, $description, $isHidden, $groupName, $hideDescription, function() use ($id, $onChange) { - ?> - getGlobalOption ( $id ) ? ' checked="checked"' : '')?> onchange="jQuery('#').val(this.checked?1:0); " /> - - - - - - - - -

            - -

            - - - - showInputWrapper($id, $name, $description, $isHidden, $groupName, $hideDescription, function() use ($id, $onChange, $rows, $isReadonly, $global) { - ?> - -

            %s

            ', $text ); - } - - /** - * Show an input option - * - * @param string $id option id - * @param string $name descriptive option name - * @param string $description option description - * @param boolean $isHidden set to true to initially hide the option (default: false) - * @param string $groupName define a class name to access a group of option rows by javascript (default: empty) - * @param string $rowName define a class name to access the specific option row by javascript (default: empty) - * @param boolean $hideDescription $hideDescription set to false to show description initially (default: true) - * @param boolean $wide Create a wide box (default: false) - */ - private function showInput($id, $name, $description, $isHidden = false, $groupName = '', $rowName = false, $hideDescription = true, $wide = false) { - $this->showInputWrapper($id, $name, $description, $isHidden, $groupName, $hideDescription, function() use ($id) { - ?> - - descriptive name) - * @param string $description option description - * @param string $onChange javascript for onchange event (default: empty) - * @param boolean $isHidden set to true to initially hide the option (default: false) - * @param string $groupName define a class name to access a group of option rows by javascript (default: empty) - * @param boolean $hideDescription $hideDescription set to false to show description initially (default: true) - * @param boolean $global set to false if the textarea shows a site-specific option (default: true) - */ - private function showSelect($id, $name, $options = array(), $description = '', $onChange = '', $isHidden = false, $groupName = '', $hideDescription = true, $global = true) { - $default = $global ? self::$settings->getGlobalOption ( $id ) : self::$settings->getOption ( $id ); - - $this->showInputWrapper($id, $name, $description, $isHidden, $groupName, $hideDescription, function() use ($id, $onChange, $options, $default) { - ?> - -

            %s

            ', $type, $icon, $content ); - } - - /** - * Show headline - * @param int $order headline order (h?-tag), set to 0 to avoid headline-tagging - * @param string $icon headline icon, see https://developer.wordpress.org/resource/dashicons/ - * @param string $headline headline text - * @param string $addPluginName set to true to add the plugin name to the headline (default: false) - */ - private function showHeadline($order, $icon, $headline, $addPluginName = false) { - echo $this->getHeadline ( $order, $icon, $headline, $addPluginName = false ); - } - - /** - * Get headline HTML - * - * @param int $order headline order (h?-tag), set to 0 to avoid headline-tagging - * @param string $icon headline icon, see https://developer.wordpress.org/resource/dashicons/ - * @param string $headline headline text - * @param string $addPluginName set to true to add the plugin name to the headline (default: false) - */ - private function getHeadline($order, $icon, $headline, $addPluginName = false) { - echo ($order > 0 ? "" : '') . sprintf ( ' %s%s', $icon, ($addPluginName ? self::$settings->getNotEmptyGlobalOption ( 'plugin_display_name' ) . ' ' : ''), __ ( $headline, 'wp-piwik' ) ) . ($order > 0 ? "" : ''); - } - - /** - * Show donation info - */ - private function showDonation() { - ?> -
            -

            - -

            -

            - -

            -
            - Paypal -
            - - - - -
            -
            - -
            - -
            -
            -

            -

            Chart.js (MIT License).','wp-piwik'); ?>

            -

            , !

            -

            -

            you for using my plugin. It is the best commendation if my piece of code is really used!','wp-piwik'); ?>

            - -

            - -
            - -
            -
              -
            • - -
            • -
            • - -
            • -
            • - -
            • -
            • - -
            • -
            • - -
            • -
            • - -
            • -
            • - -
            • -
            - - -

            -

            or cURL has to be available:', 'wp-piwik'); ?>

            -
              -
            1. '.(function_exists('curl_init')?'':__('not','wp-piwik')).' '; - _e('available','wp-piwik'); - ?>.
            2. -
            3. '.(ini_get('allow_url_fopen')?'':__('not','wp-piwik')).' '; - _e('enabled','wp-piwik'); - ?>.
            4. -
            5. getGlobalOption('http_connection') == 'curl') || (function_exists('curl_init') && !ini_get('allow_url_fopen')))?__('cURL', 'wp-piwik'):__('fopen', 'wp-piwik')).' ('.(self::$settings->getGlobalOption('http_method')=='post'?__('POST','wp-piwik'):__('GET','wp-piwik')).') '.__('is used.', 'wp-piwik'); ?>
            6. - getGlobalOption('piwik_mode') == 'php') { ?>
            7. '.(self::$settings->getGlobalOption('proxy_url')).''; - ?>
            8. -
            -

            :

            -
              -
            1. -
            2. -
            3. -
            4. -
            -

            readRSSFeed('http://wordpress.org/support/rss/plugin/wp-piwik'); - if (!empty($supportThreads)) { - echo '
              '; - foreach ($supportThreads as $supportThread) - echo '
            1. '.$supportThread['title'].'
            2. '; - echo '
            '; - } - } - - /** - * Read RSS feed - * - * @param string $feed - * feed URL - * @param int $cnt - * item limit - * @return array feed items array[](title, url) - * - */ - private function readRSSFeed($feed, $cnt = 5) { - $result = array (); - if (function_exists ( 'simplexml_load_file' ) && ! empty ( $feed )) { - $xml = @simplexml_load_file ( $feed ); - if (! $xml || ! isset ( $xml->channel [0]->item )) - return array ( - array ( - 'title' => 'Can\'t read RSS feed.', - 'url' => $xml - ) - ); - foreach ( $xml->channel [0]->item as $item ) { - if ($cnt -- == 0) - break; - $result [] = array ( - 'title' => $item->title [0], - 'url' => $item->link [0] - ); - } - } - return $result; - } - - /** - * Clear cache and reset settings - * - * @param boolean $clearSettings set to true to reset settings (default: false) - */ - private function clear($clearSettings = false) { - if ($clearSettings) { - self::$settings->resetSettings(); - $this->showBox ( 'updated', 'yes', __ ( 'Settings cleared (except connection settings).' ) ); - } - global $wpdb; - if (self::$settings->checkNetworkActivation()) { - $aryBlogs = \WP_Piwik\Settings::getBlogList(); - if (is_array($aryBlogs)) - foreach ($aryBlogs as $aryBlog) { - switch_to_blog($aryBlog['blog_id']); - $wpdb->query("DELETE FROM $wpdb->options WHERE option_name LIKE '_transient_wp-piwik_%'"); - $wpdb->query("DELETE FROM $wpdb->options WHERE option_name LIKE '_transient_timeout_wp-piwik_%'"); - restore_current_blog(); - } - } else { - $wpdb->query("DELETE FROM $wpdb->options WHERE option_name LIKE '_transient_wp-piwik_%'"); - $wpdb->query("DELETE FROM $wpdb->options WHERE option_name LIKE '_transient_timeout_wp-piwik_%'"); - } - $this->showBox ( 'updated', 'yes', __ ( 'Cache cleared.' ) ); - } - - /** - * Execute test script and display results - */ - private function runTestscript() { ?> -
            -

            Testscript Result

            - isConfigured()) { - if (isset($_GET['testscript_id']) && $_GET['testscript_id']) - switch_to_blog((int) $_GET['testscript_id']); - ?> - - Please configure WP-Matomo first.

            '; - ?> -
            - wpPiwik = $wpPiwik; - if( isset($_POST['s']) ){ - $cnt = $this->prepare_items ($_POST['s']); - } else { - $cnt = $this->prepare_items (); - } - global $status, $page; - $this->showSearchForm(); - parent::__construct ( array ( - 'singular' => __ ( 'site', 'wp-piwik' ), - 'plural' => __ ( 'sites', 'wp-piwik' ), - 'ajax' => false - ) ); - if ($cnt > 0) - $this->display (); - else - echo '

            ' . __ ( 'No site configured yet.', 'wp-piwik' ) . '

            '; - } - - public function get_columns() { - $columns = array ( - 'id' => __ ( 'Blog ID', 'wp-piwik' ), - 'name' => __ ( 'Title', 'wp-piwik' ), - 'siteurl' => __ ( 'URL', 'wp-piwik' ), - 'piwikid' => __ ( 'Site ID (Piwik)', 'wp-piwik' ) - ); - return $columns; - } - - public function prepare_items($search = '') { - $current_page = $this->get_pagenum (); - $per_page = 10; - global $blog_id; - global $wpdb; - global $pagenow; - if (is_plugin_active_for_network ( 'wp-piwik/wp-piwik.php' )) { - $total_items = $wpdb->get_var ( $wpdb->prepare('SELECT COUNT(*) FROM ' . $wpdb->blogs . ' WHERE CONCAT(domain, path) LIKE "%%%s%%" AND spam = 0 AND deleted = 0', $search)); - $blogs = \WP_Piwik\Settings::getBlogList($per_page, $current_page, $search); - foreach ( $blogs as $blog ) { - $blogDetails = get_blog_details ( $blog['blog_id'], true ); - $this->data [] = array ( - 'name' => $blogDetails->blogname, - 'id' => $blogDetails->blog_id, - 'siteurl' => $blogDetails->siteurl, - 'piwikid' => $this->wpPiwik->getPiwikSiteId ( $blogDetails->blog_id ) - ); - } - } else { - $blogDetails = get_bloginfo (); - $this->data [] = array ( - 'name' => get_bloginfo ( 'name' ), - 'id' => '-', - 'siteurl' => get_bloginfo ( 'url' ), - 'piwikid' => $this->wpPiwik->getPiwikSiteId () - ); - $total_items = 1; - } - $columns = $this->get_columns (); - $hidden = array (); - $sortable = array (); - $this->_column_headers = array ( - $columns, - $hidden, - $sortable - ); - $this->set_pagination_args ( array ( - 'total_items' => $total_items, - 'per_page' => $per_page - ) ); - foreach ( $this->data as $key => $dataset ) { - if (empty ( $dataset ['piwikid'] ) || $dataset ['piwikid'] == 'n/a') - $this->data [$key] ['piwikid'] = __ ( 'Site not created yet.', 'wp-piwik' ); - if ($this->wpPiwik->isNetworkMode ()) - $this->data [$key] ['name'] = '' . $dataset ['name'] . ''; - } - $this->items = $this->data; - return count ( $this->items ); - } - - public function column_default($item, $column_name) { - switch ($column_name) { - case 'id' : - case 'name' : - case 'siteurl' : - case 'piwikid' : - return $item [$column_name]; - default : - return print_r ( $item, true ); - } - } - - private function showSearchForm() { - ?> -
            - - search_box('Search domain and path', 'wpPiwikSiteSearch'); ?> -
            - getGlobalOption('disable_timelimit')) set_time_limit(0); - echo '
            '; - echo '

            '.(self::$settings->getGlobalOption('plugin_display_name') == 'WP-Piwik'?'Piwik '.__('Statistics', 'wp-piwik'):self::$settings->getGlobalOption('plugin_display_name')).'

            '; - if (self::$settings->checkNetworkActivation() && function_exists('is_super_admin') && is_super_admin()) { - - if (isset($_GET['wpmu_show_stats'])) { - switch_to_blog((int) $_GET['wpmu_show_stats']); - } elseif ((isset($_GET['overview']) && $_GET['overview']) || (function_exists('is_network_admin') && is_network_admin())) { - new \WP_Piwik\Admin\Sitebrowser(self::$wpPiwik); - return; - } - echo '

            '.__('Currently shown stats:').' '.get_bloginfo('name').'.'.' Show site overview.

            '; - } - echo '
            '; - wp_nonce_field('wp-piwik_stats-general'); - wp_nonce_field('closedpostboxes', 'closedpostboxesnonce', false); - wp_nonce_field('meta-box-order', 'meta-box-order-nonce', false); - $columns = array('normal', 'side', 'column3'); - for ($i = 0; $i < 3; $i++) { - echo '
            '; - do_meta_boxes(self::$wpPiwik->statsPageId, $columns[$i], null); - echo '
            '; - } - echo '
            '; - echo ''."\n"; - if (self::$settings->checkNetworkActivation() && function_exists('is_super_admin') && is_super_admin()) { - restore_current_blog(); - } - } - - public function printAdminScripts() { - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger.php deleted file mode 100644 index d016661f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger.php +++ /dev/null @@ -1,47 +0,0 @@ -setName($loggerName); - $this->setStartMicrotime(microtime(true)); - $this->log('Logging started -------------------------------'); - } - - public function __destruct() { - $this->log('Logging finished ------------------------------'); - } - - public function log($loggerMessage) { - $this->loggerOutput($this->getElapsedMicrotime(), $loggerMessage); - } - - private function setName($loggerName) { - $this->loggerName = $loggerName; - } - - public function getName() { - return $this->loggerName; - } - - private function setStartMicrotime($startMicrotime) { - $this->startMicrotime = $startMicrotime; - } - - public function getStartMicrotime() { - return $this->startMicrotime; - } - - public function getElapsedMicrotime() { - return microtime(true) - $this->getStartMicrotime(); - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger/Dummy.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger/Dummy.php deleted file mode 100644 index 211c871d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger/Dummy.php +++ /dev/null @@ -1,9 +0,0 @@ -loggerFile = WP_PIWIK_PATH.'logs'.DIRECTORY_SEPARATOR. - date('Ymd').'_'.$this->encodeFilename($this->getName()).'.log'; - } - - private function getFilename() { - return $this->loggerFile; - } - - private function openFile() { - if (!$this->loggerFile) - $this->setFilename(); - return fopen($this->getFilename(), 'a'); - } - - private function closeFile($fileHandle) { - fclose($fileHandle); - } - - private function writeFile($fileHandle, $fileContent) { - fwrite($fileHandle, $fileContent."\n"); - } - - private function formatMicrotime($loggerTime) { - return sprintf('[%6s sec]',number_format($loggerTime,3)); - } - - public function loggerOutput($loggerTime, $loggerMessage) { - if ($fileHandle = $this->openFile()) { - $this->writeFile($fileHandle, $this->formatMicrotime($loggerTime).' '.$loggerMessage); - $this->closeFile($fileHandle); - } - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger/Screen.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger/Screen.php deleted file mode 100644 index 88afa23d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Logger/Screen.php +++ /dev/null @@ -1,27 +0,0 @@ -logs[] = $this->formatMicrotime($loggerTime).' '.$loggerMessage; - } - - public function echoResults() { - echo '
            ';
            -			print_r($this->logs);
            -			echo '
            '; - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request.php deleted file mode 100644 index c26e2291..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request.php +++ /dev/null @@ -1,95 +0,0 @@ - $method, 'parameter' => $parameter); - return $id; - } - - private static function parameterToString($parameter) { - $return = ''; - if (is_array($parameter)) - foreach ($parameter as $key => $value) - $return .= '&'.$key.'='.$value; - return $return; - } - - public function perform($id) { - if ( self::$settings->getGlobalOption('cache') && false !== ( $cached = get_transient( 'wp-piwik_c_'.md5(self::$isCacheable[$id] ) ) ) ) { - if (!empty ( $cached ) && !(! empty ( $cached['result'] ) && $cached['result'] == 'error') ) { - self::$wpPiwik->log("Deliver cached data: ".$id); - return $cached; - } - } - self::$wpPiwik->log("Perform request: ".$id); - if (!isset(self::$requests[$id])) - return array('result' => 'error', 'message' => 'Request '.$id.' was not registered.'); - elseif (!isset(self::$results[$id])) { - $this->request($id); - } - if ( isset ( self::$results[$id] ) ) { - if ( self::$settings->getGlobalOption('cache') && self::$isCacheable[$id] ) { - set_transient( 'wp-piwik_c_'.md5(self::$isCacheable[$id]) , self::$results[$id], WEEK_IN_SECONDS ); - } - return self::$results[$id]; - } else return false; - } - - public function getDebug($id) { - return isset( self::$debug[$id] )? self::$debug[$id] : false; - } - - protected function buildURL($config, $urlDecode = false) { - $url = 'method='.($config['method']).'&idSite='.self::$settings->getOption('site_id'); - foreach ($config['parameter'] as $key => $value) - $url .= '&'.$key.'='.($urlDecode?urldecode($value):$value); - return $url; - } - - protected function unserialize($str) { - self::$wpPiwik->log("Result string: ".$str); - return ($str == json_decode(false, true) || @json_decode($str, true) !== false)?json_decode($str, true):array(); - } - - public static function getLastError() { - return self::$lastError; - } - - abstract protected function request($id); - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Php.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Php.php deleted file mode 100644 index 02856557..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Php.php +++ /dev/null @@ -1,64 +0,0 @@ -getGlobalOption('piwik_url'); - foreach (self::$requests as $requestID => $config) { - if (!isset(self::$results[$requestID])) { - if (self::$settings->getGlobalOption('filter_limit') != "" && self::$settings->getGlobalOption('filter_limit') == (int) self::$settings->getGlobalOption('filter_limit')) - $config['parameter']['filter_limit'] = self::$settings->getGlobalOption('filter_limit'); - $params = 'module=API&format=json&'.$this->buildURL($config, true); - $map[$count] = $requestID; - $result = $this->call($id, $url, $params); - self::$results[$map[$count]] = $result; - $count++; - } - } - } - - private function call($id, $url, $params) { - if (!defined('PIWIK_INCLUDE_PATH')) - return false; - if (PIWIK_INCLUDE_PATH === FALSE) - return array('result' => 'error', 'message' => __('Could not resolve','wp-piwik').' "'.htmlentities(self::$settings->getGlobalOption('piwik_path')).'": '.__('realpath() returns false','wp-piwik').'.'); - if (file_exists(PIWIK_INCLUDE_PATH . "/index.php")) - require_once PIWIK_INCLUDE_PATH . "/index.php"; - if (file_exists(PIWIK_INCLUDE_PATH . "/core/API/Request.php")) - require_once PIWIK_INCLUDE_PATH . "/core/API/Request.php"; - if (class_exists('\Piwik\Application\Environment') && !self::$piwikEnvironment) { - // Piwik 2.14.* compatibility fix - self::$piwikEnvironment = new \Piwik\Application\Environment(null); - self::$piwikEnvironment->init(); - } - if (class_exists('Piwik\FrontController')) - \Piwik\FrontController::getInstance()->init(); - else return array('result' => 'error', 'message' => __('Class Piwik\FrontController does not exists.','wp-piwik')); - if (class_exists('Piwik\API\Request')) - $request = new \Piwik\API\Request($params.'&token_auth='.self::$settings->getGlobalOption('piwik_token')); - else return array('result' => 'error', 'message' => __('Class Piwik\API\Request does not exists.','wp-piwik')); - if (isset($request)) - $result = $request->process(); - else $result = null; - if (!headers_sent()) - header("Content-Type: text/html", true); - $result = $this->unserialize($result); - if ($GLOBALS ['wp-piwik_debug']) - self::$debug[$id] = array ( $params.'&token_auth=...' ); - return $result; - } - - public function reset() { - if (class_exists('\Piwik\Application\Environment') && !self::$piwikEnvironment) { - self::$piwikEnvironment->destroy(); - } - if (class_exists('Piwik\FrontController')) - \Piwik\FrontController::unsetInstance(); - parent::reset(); - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Rest.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Rest.php deleted file mode 100644 index 198ad844..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Request/Rest.php +++ /dev/null @@ -1,81 +0,0 @@ -getGlobalOption('piwik_mode') == 'http') - $url = self::$settings->getGlobalOption('piwik_url'); - else if (self::$settings->getGlobalOption('piwik_mode') == 'cloud') - $url = 'https://'.self::$settings->getGlobalOption('piwik_user').'.innocraft.cloud/'; - else $url = 'https://'.self::$settings->getGlobalOption('matomo_user').'.matomo.cloud/'; - $params = 'module=API&method=API.getBulkRequest&format=json'; - if (self::$settings->getGlobalOption('filter_limit') != "" && self::$settings->getGlobalOption('filter_limit') == (int) self::$settings->getGlobalOption('filter_limit')) - $params .= '&filter_limit='.self::$settings->getGlobalOption('filter_limit'); - foreach (self::$requests as $requestID => $config) { - if (!isset(self::$results[$requestID])) { - $params .= '&urls['.$count.']='.urlencode($this->buildURL($config)); - $map[$count] = $requestID; - $count++; - } - } - $results = ((function_exists('curl_init') && ini_get('allow_url_fopen') && self::$settings->getGlobalOption('http_connection') == 'curl') || (function_exists('curl_init') && !ini_get('allow_url_fopen')))?$this->curl($id, $url, $params):$this->fopen($id, $url, $params); - if (is_array($results)) - foreach ($results as $num => $result) - if (isset($map[$num])) - self::$results[$map[$num]] = $result; - } - - private function curl($id, $url, $params) { - if (self::$settings->getGlobalOption('http_method')=='post') { - $c = curl_init($url); - curl_setopt($c, CURLOPT_POST, 1); - curl_setopt($c, CURLOPT_POSTFIELDS, $params.'&token_auth='.self::$settings->getGlobalOption('piwik_token')); - } else $c = curl_init($url.'?'.$params.'&token_auth='.self::$settings->getGlobalOption('piwik_token')); - curl_setopt($c, CURLOPT_SSL_VERIFYPEER, !self::$settings->getGlobalOption('disable_ssl_verify')); - curl_setopt($c, CURLOPT_SSL_VERIFYHOST, !self::$settings->getGlobalOption('disable_ssl_verify_host')?2:0); - curl_setopt($c, CURLOPT_USERAGENT, self::$settings->getGlobalOption('piwik_useragent')=='php'?ini_get('user_agent'):self::$settings->getGlobalOption('piwik_useragent_string')); - curl_setopt($c, CURLOPT_RETURNTRANSFER, 1); - curl_setopt($c, CURLOPT_HEADER, $GLOBALS ['wp-piwik_debug'] ); - curl_setopt($c, CURLOPT_TIMEOUT, self::$settings->getGlobalOption('connection_timeout')); - $httpProxyClass = new \WP_HTTP_Proxy(); - if ($httpProxyClass->is_enabled() && $httpProxyClass->send_through_proxy($url)) { - curl_setopt($c, CURLOPT_PROXY, $httpProxyClass->host()); - curl_setopt($c, CURLOPT_PROXYPORT, $httpProxyClass->port()); - if ($httpProxyClass->use_authentication()) - curl_setopt($c, CURLOPT_PROXYUSERPWD, $httpProxyClass->username().':'.$httpProxyClass->password()); - } - $result = curl_exec($c); - self::$lastError = curl_error($c); - if ($GLOBALS ['wp-piwik_debug']) { - $header_size = curl_getinfo($c, CURLINFO_HEADER_SIZE); - $header = substr($result, 0, $header_size); - $body = substr($result, $header_size); - $result = $this->unserialize($body); - self::$debug[$id] = array ( $header, $url.'?'.$params.'&token_auth=...' ); - } else $result = $this->unserialize($result); - curl_close($c); - return $result; - } - - private function fopen($id, $url, $params) { - $contextDefinition = array('http'=>array('timeout' => self::$settings->getGlobalOption('connection_timeout'), 'header' => "Content-type: application/x-www-form-urlencoded\r\n") ); - $contextDefinition['ssl'] = array(); - if (self::$settings->getGlobalOption('disable_ssl_verify')) - $contextDefinition['ssl'] = array('allow_self_signed' => true, 'verify_peer' => false ); - if (self::$settings->getGlobalOption('disable_ssl_verify_host')) - $contextDefinition['ssl']['verify_peer_name'] = false; - if (self::$settings->getGlobalOption('http_method')=='post') { - $fullUrl = $url; - $contextDefinition['http']['method'] = 'POST'; - $contextDefinition['http']['content'] = $params.'&token_auth='.self::$settings->getGlobalOption('piwik_token'); - } else $fullUrl = $url.'?'.$params.'&token_auth='.self::$settings->getGlobalOption('piwik_token'); - $context = stream_context_create($contextDefinition); - $result = $this->unserialize(@file_get_contents($fullUrl, false, $context)); - if ($GLOBALS ['wp-piwik_debug']) - self::$debug[$id] = array ( get_headers($fullUrl, 1), $url.'?'.$params.'&token_auth=...' ); - return $result; - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Settings.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Settings.php deleted file mode 100644 index 04356e58..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Settings.php +++ /dev/null @@ -1,427 +0,0 @@ - 'checkPiwikUrl', - 'piwik_token' => 'checkPiwikToken', - 'site_id' => 'requestPiwikSiteID', - 'tracking_code' => 'prepareTrackingCode', - 'noscript_code' => 'prepareNocscriptCode' - ); - - /** - * - * @var Register default configuration set - */ - private $globalSettings = array ( - // Plugin settings - 'revision' => 0, - 'last_settings_update' => 0, - // User settings: Piwik configuration - 'piwik_mode' => 'http', - 'piwik_url' => '', - 'piwik_path' => '', - 'piwik_user' => '', - 'matomo_user' => '', - 'piwik_token' => '', - 'auto_site_config' => true, - // User settings: Stats configuration - 'default_date' => 'yesterday', - 'stats_seo' => false, - 'stats_ecommerce' => false, - 'dashboard_widget' => false, - 'dashboard_ecommerce' => false, - 'dashboard_chart' => false, - 'dashboard_seo' => false, - 'toolbar' => false, - 'capability_read_stats' => array ( - 'administrator' => true - ), - 'perpost_stats' => "disabled", - 'plugin_display_name' => 'Connect Matomo', - 'piwik_shortcut' => false, - 'shortcodes' => false, - // User settings: Tracking configuration - 'track_mode' => 'disabled', - 'track_codeposition' => 'footer', - 'track_noscript' => false, - 'track_nojavascript' => false, - 'proxy_url' => '', - 'track_content' => 'disabled', - 'track_search' => false, - 'track_404' => false, - 'add_post_annotations' => array(), - 'add_customvars_box' => false, - 'add_download_extensions' => '', - 'set_download_extensions' => '', - 'set_link_classes' => '', - 'set_download_classes' => '', - 'require_consent' => 'disabled', - 'disable_cookies' => false, - 'limit_cookies' => false, - 'limit_cookies_visitor' => 34186669, // Piwik default 13 months - 'limit_cookies_session' => 1800, // Piwik default 30 minutes - 'limit_cookies_referral' => 15778463, // Piwik default 6 months - 'track_admin' => false, - 'capability_stealth' => array (), - 'track_across' => false, - 'track_across_alias' => false, - 'track_crossdomain_linking' => false, - 'track_feed' => false, - 'track_feed_addcampaign' => false, - 'track_feed_campaign' => 'feed', - 'track_heartbeat' => 0, - 'track_user_id' => 'disabled', - // User settings: Expert configuration - 'cache' => true, - 'http_connection' => 'curl', - 'http_method' => 'post', - 'disable_timelimit' => false, - 'filter_limit' => '', - 'connection_timeout' => 5, - 'disable_ssl_verify' => false, - 'disable_ssl_verify_host' => false, - 'piwik_useragent' => 'php', - 'piwik_useragent_string' => 'WP-Piwik', - 'dnsprefetch' => false, - 'track_datacfasync' => false, - 'track_cdnurl' => '', - 'track_cdnurlssl' => '', - 'force_protocol' => 'disabled', - 'remove_type_attribute' => false, - 'update_notice' => 'enabled' - ), $settings = array ( - 'name' => '', - 'site_id' => NULL, - 'noscript_code' => '', - 'tracking_code' => '', - 'last_tracking_code_update' => 0, - 'dashboard_revision' => 0 - ), $settingsChanged = false; - - /** - * Constructor class to prepare settings manager - * - * @param WP_Piwik $wpPiwik - * active WP-Piwik instance - */ - public function __construct($wpPiwik) { - self::$wpPiwik = $wpPiwik; - self::$wpPiwik->log ( 'Store default settings' ); - self::$defaultSettings = array ( - 'globalSettings' => $this->globalSettings, - 'settings' => $this->settings - ); - self::$wpPiwik->log ( 'Load settings' ); - foreach ( $this->globalSettings as $key => $default ) { - $this->globalSettings [$key] = ($this->checkNetworkActivation () ? get_site_option ( 'wp-piwik_global-' . $key, $default ) : get_option ( 'wp-piwik_global-' . $key, $default )); - } - foreach ( $this->settings as $key => $default ) - $this->settings [$key] = get_option ( 'wp-piwik-' . $key, $default ); - } - - /** - * Save all settings as WordPress options - */ - public function save() { - if (! $this->settingsChanged) { - self::$wpPiwik->log ( 'No settings changed yet' ); - return; - } - self::$wpPiwik->log ( 'Save settings' ); - $this->globalSettings['plugin_display_name'] = htmlspecialchars($this->globalSettings['plugin_display_name'], ENT_QUOTES, 'utf-8'); - foreach ( $this->globalSettings as $key => $value ) { - if ( $this->checkNetworkActivation() ) - update_site_option ( 'wp-piwik_global-' . $key, $value ); - else - update_option ( 'wp-piwik_global-' . $key, $value ); - } - foreach ( $this->settings as $key => $value ) { - update_option ( 'wp-piwik-' . $key, $value ); - } - global $wp_roles; - if (! is_object ( $wp_roles )) - $wp_roles = new \WP_Roles (); - if (! is_object ( $wp_roles )) - die ( "STILL NO OBJECT" ); - foreach ( $wp_roles->role_names as $strKey => $strName ) { - $objRole = get_role ( $strKey ); - foreach ( array ( - 'stealth', - 'read_stats' - ) as $strCap ) { - $aryCaps = $this->getGlobalOption ( 'capability_' . $strCap ); - if (isset ( $aryCaps [$strKey] ) && $aryCaps [$strKey]) - $wp_roles->add_cap ( $strKey, 'wp-piwik_' . $strCap ); - else $wp_roles->remove_cap ( $strKey, 'wp-piwik_' . $strCap ); - } - } - $this->settingsChanged = false; - } - - /** - * Get a global option's value which should not be empty - * - * @param string $key - * option key - * @return string option value - */ - public function getNotEmptyGlobalOption($key) { - return isset ( $this->globalSettings [$key] ) && !empty($this->globalSettings [$key]) ? $this->globalSettings [$key] : self::$defaultSettings ['globalSettings'] [$key]; - } - - /** - * Get a global option's value - * - * @param string $key - * option key - * @return string option value - */ - public function getGlobalOption($key) { - return isset ( $this->globalSettings [$key] ) ? $this->globalSettings [$key] : self::$defaultSettings ['globalSettings'] [$key]; - } - - /** - * Get an option's value related to a specific blog - * - * @param string $key - * option key - * @param int $blogID - * blog ID (default: current blog) - * @return \WP_Piwik\Register - */ - public function getOption($key, $blogID = null) { - if ($this->checkNetworkActivation () && ! empty ( $blogID )) { - return get_blog_option ( $blogID, 'wp-piwik-'.$key ); - } - return isset ( $this->settings [$key] ) ? $this->settings [$key] : self::$defaultSettings ['settings'] [$key]; - } - - /** - * Set a global option's value - * - * @param string $key - * option key - * @param string $value - * new option value - */ - public function setGlobalOption($key, $value) { - $this->settingsChanged = true; - self::$wpPiwik->log ( 'Changed global option ' . $key . ': ' . (is_array ( $value ) ? serialize ( $value ) : $value) ); - $this->globalSettings [$key] = $value; - } - - /** - * Set an option's value related to a specific blog - * - * @param string $key - * option key - * @param string $value - * new option value - * @param int $blogID - * blog ID (default: current blog) - */ - public function setOption($key, $value, $blogID = null) { - if (empty( $blogID )) { - $blogID = get_current_blog_id(); - } - $this->settingsChanged = true; - self::$wpPiwik->log ( 'Changed option ' . $key . ': ' . $value ); - if ($this->checkNetworkActivation ()) { - update_blog_option ( $blogID, 'wp-piwik-'.$key, $value ); - } - if ($blogID == get_current_blog_id()) { - $this->settings [$key] = $value; - } - } - - /** - * Reset settings to default - */ - public function resetSettings() { - self::$wpPiwik->log ( 'Reset WP-Piwik settings' ); - global $wpdb; - if ( $this->checkNetworkActivation() ) { - $aryBlogs = self::getBlogList(); - if (is_array($aryBlogs)) - foreach ($aryBlogs as $aryBlog) { - switch_to_blog($aryBlog['blog_id']); - $wpdb->query("DELETE FROM $wpdb->options WHERE option_name LIKE 'wp-piwik-%'"); - restore_current_blog(); - } - $wpdb->query("DELETE FROM $wpdb->sitemeta WHERE meta_key LIKE 'wp-piwik_global-%'"); - } - else $wpdb->query("DELETE FROM $wpdb->options WHERE option_name LIKE 'wp-piwik_global-%'"); - } - - /** - * Get blog list - */ - public static function getBlogList($limit = null, $page = null, $search = '') { - if ($limit && $page) - $queryLimit = ' LIMIT '.(int) (($page - 1) * $limit).','.(int) $limit; - global $wpdb; - return $wpdb->get_results($wpdb->prepare('SELECT blog_id FROM '.$wpdb->blogs.' WHERE CONCAT(domain, path) LIKE "%%%s%%" AND spam = 0 AND deleted = 0 ORDER BY blog_id'.$queryLimit, $search), ARRAY_A); - } - - /** - * Check if plugin is network activated - * - * @return boolean Is network activated? - */ - public function checkNetworkActivation() { - if (! function_exists ( "is_plugin_active_for_network" )) - require_once (ABSPATH . 'wp-admin/includes/plugin.php'); - return is_plugin_active_for_network ( 'wp-piwik/wp-piwik.php' ); - } - - /** - * Apply new configuration - * - * @param array $in - * new configuration set - */ - public function applyChanges($in) { - if (!self::$wpPiwik->isValidOptionsPost()) - die("Invalid config changes."); - $in = $this->checkSettings ( $in ); - self::$wpPiwik->log ( 'Apply changed settings:' ); - foreach ( self::$defaultSettings ['globalSettings'] as $key => $val ) - $this->setGlobalOption ( $key, isset ( $in [$key] ) ? $in [$key] : $val ); - foreach ( self::$defaultSettings ['settings'] as $key => $val ) - $this->setOption ( $key, isset ( $in [$key] ) ? $in [$key] : $val ); - $this->setGlobalOption ( 'last_settings_update', time () ); - $this->save (); - } - - /** - * Apply callback function on new settings - * - * @param array $in - * new configuration set - * @return array configuration set after callback functions were applied - */ - private function checkSettings($in) { - foreach ( $this->checkSettings as $key => $value ) - if (isset ( $in [$key] )) - $in [$key] = call_user_func_array ( array ( - $this, - $value - ), array ( - $in [$key], - $in - ) ); - return $in; - } - - /** - * Add slash to Piwik URL if necessary - * - * @param string $value - * Piwik URL - * @param array $in - * configuration set - * @return string Piwik URL - */ - private function checkPiwikUrl($value, $in) { - return substr ( $value, - 1, 1 ) != '/' ? $value . '/' : $value; - } - - /** - * Remove &token_auth= from auth token - * - * @param string $value - * Piwik auth token - * @param array $in - * configuration set - * @return string Piwik auth token - */ - private function checkPiwikToken($value, $in) { - return str_replace ( '&token_auth=', '', $value ); - } - - /** - * Request the site ID (if not set before) - * - * @param string $value - * tracking code - * @param array $in - * configuration set - * @return int Piwik site ID - */ - private function requestPiwikSiteID($value, $in) { - if ($in ['auto_site_config'] && ! $value) - return self::$wpPiwik->getPiwikSiteId(); - return $value; - } - - /** - * Prepare the tracking code - * - * @param string $value - * tracking code - * @param array $in - * configuration set - * @return string tracking code - */ - private function prepareTrackingCode($value, $in) { - if ($in ['track_mode'] == 'manually' || $in ['track_mode'] == 'disabled') { - $value = stripslashes ( $value ); - if ($this->checkNetworkActivation ()) - update_site_option ( 'wp-piwik-manually', $value ); - return $value; - } - /*$result = self::$wpPiwik->updateTrackingCode (); - echo '
            '; print_r($result); echo '
            '; - $this->setOption ( 'noscript_code', $result ['noscript'] );*/ - return; // $result ['script']; - } - - /** - * Prepare the nocscript code - * - * @param string $value - * noscript code - * @param array $in - * configuration set - * @return string noscript code - */ - private function prepareNocscriptCode($value, $in) { - if ($in ['track_mode'] == 'manually') - return stripslashes ( $value ); - return $this->getOption ( 'noscript_code' ); - } - - /** - * Get debug data - * - * @return array WP-Piwik settings for debug output - */ - public function getDebugData() { - $debug = array( - 'global_settings' => $this->globalSettings, - 'settings' => $this->settings - ); - $debug['global_settings']['piwik_token'] = !empty($debug['global_settings']['piwik_token'])?'set':'not set'; - return $debug; - } -} diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Shortcode.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Shortcode.php deleted file mode 100644 index c2c9ee52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Shortcode.php +++ /dev/null @@ -1,28 +0,0 @@ - 'OptOut', - 'post' => 'Post', - 'overview' => 'Overview' - ), $content; - - public function __construct($attributes, $wpPiwik, $settings) { - $wpPiwik->log('Check requested shortcode widget '.$attributes['module']); - if (isset($attributes['module']) && isset($this->available[$attributes['module']])) { - $wpPiwik->log('Add shortcode widget '.$this->available[$attributes['module']]); - $class = '\\WP_Piwik\\Widget\\'.$this->available[$attributes['module']]; - $widget = new $class($wpPiwik, $settings, null, null, null, $attributes, true); - $widget->show(); - $this->content = $widget->get(); - } - } - - public function get() { - return $this->content; - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Template.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Template.php deleted file mode 100644 index 8342a108..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Template.php +++ /dev/null @@ -1,31 +0,0 @@ -'.$name.''.$value.''; - } - - public function getRangeLast30() { - $diff = (self::$settings->getGlobalOption('default_date') == 'yesterday') ? -86400 : 0; - $end = time() + $diff; - $start = time() - 2592000 + $diff; - return date('Y-m-d', $start).','.date('Y-m-d', $end); - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Template/MetaBoxCustomVars.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Template/MetaBoxCustomVars.php deleted file mode 100644 index 9f8b5cea..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Template/MetaBoxCustomVars.php +++ /dev/null @@ -1,63 +0,0 @@ - - - - - - - - - - -
            -

            . (.)

            - post_type); - // Check if the current user has permission to edit the post. - if (!current_user_can($objPostType->cap->edit_post, $intID)) - return $intID; - $aryNames = array('cat', 'val'); - for ($i = 1; $i <= 5; $i++) - for ($j = 0; $j <= 1; $j++) { - // Get data - $strMetaVal = (isset($_POST['wp-piwik_custom_'.$aryNames[$j].$i])?htmlentities($_POST['wp-piwik_custom_'.$aryNames[$j].$i]):''); - // Create key - $strMetaKey = 'wp-piwik_custom_'.$aryNames[$j].$i; - // Get the meta value of the custom field key - $strCurVal = get_post_meta($intID, $strMetaKey, true); - // Add meta val: - if ($strMetaVal && '' == $strCurVal) - add_post_meta($intID, $strMetaKey, $strMetaVal, true); - // Update meta val: - elseif ($strMetaVal && $strMetaVal != $strCurVal) - update_post_meta($intID, $strMetaKey, $strMetaVal); - // Delete meta val: - elseif (''==$strMetaVal && $strCurVal) - delete_post_meta($intID, $strMetaKey, $strCurVal); - } - } - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/TrackingCode.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/TrackingCode.php deleted file mode 100644 index 94efcc7e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/TrackingCode.php +++ /dev/null @@ -1,167 +0,0 @@ -isCurrentTrackingCode () || ! self::$wpPiwik->getOption ( 'tracking_code' ) || strpos( self::$wpPiwik->getOption ( 'tracking_code' ), '{"result":"error",' ) !== false ) - self::$wpPiwik->updateTrackingCode (); - $this->trackingCode = (self::$wpPiwik->isNetworkMode () && self::$wpPiwik->getGlobalOption ( 'track_mode' ) == 'manually') ? get_site_option ( 'wp-piwik-manually' ) : self::$wpPiwik->getOption ( 'tracking_code' ); - } - - public function getTrackingCode() { - if ($this->isUsertracking) - $this->applyUserTracking (); - if ($this->is404) - $this->apply404Changes (); - if ($this->isSearch) - $this->applySearchChanges (); - if (is_single () || is_page()) - $this->addCustomValues (); - $this->trackingCode = apply_filters('wp-piwik_tracking_code', $this->trackingCode); - return $this->trackingCode; - } - - public static function prepareTrackingCode($code, $settings, $logger) { - global $current_user; - $logger->log ( 'Apply tracking code changes:' ); - $settings->setOption ( 'last_tracking_code_update', time () ); - if (preg_match ( '/var u="([^"]*)";/', $code, $hits )) { - $fetchedProxyUrl = $hits [1]; - } else $fetchedProxyUrl = ''; - if ($settings->getGlobalOption ( 'remove_type_attribute')) { - $code = str_replace ( - array( ' type="text/javascript"', " type='text/javascript'" ), - '', - $code - ); - } - if ($settings->getGlobalOption ( 'track_mode' ) == 'js') - $code = str_replace ( array ( - 'piwik.js', - 'piwik.php', - 'matomo.js', - 'matomo.php' - ), 'js/index.php', $code ); - elseif ($settings->getGlobalOption ( 'track_mode' ) == 'proxy') { - $code = str_replace ( 'piwik.js', 'matomo.php', $code ); - $code = str_replace ( 'matomo.js', 'matomo.php', $code ); - $code = str_replace ( 'piwik.php', 'matomo.php', $code ); - $proxy = str_replace ( array ( - 'https://', - 'http://' - ), '//', plugins_url ( 'wp-piwik' ) . '/proxy' ) . '/'; - $code = preg_replace ( '/var u="([^"]*)";/', 'var u="' . $proxy . '"', $code ); - $code = preg_replace ( '/img src="([^"]*)piwik.php/', 'img src="' . $proxy . 'matomo.php', $code ); - $code = preg_replace ( '/img src="([^"]*)matomo.php/', 'img src="' . $proxy . 'matomo.php', $code ); - } - if ($settings->getGlobalOption ( 'track_cdnurl' ) || $settings->getGlobalOption ( 'track_cdnurlssl' )) - $code = str_replace ( array ( - "var d=doc", - "g.src=u+" - ), array ( - "var ucdn=(('https:' == document.location.protocol) ? 'https://" . ($settings->getGlobalOption ( 'track_cdnurlssl' ) ? $settings->getGlobalOption ( 'track_cdnurlssl' ) : $settings->getGlobalOption ( 'track_cdnurl' )) . "/' : 'http://" . ($settings->getGlobalOption ( 'track_cdnurl' ) ? $settings->getGlobalOption ( 'track_cdnurl' ) : $settings->getGlobalOption ( 'track_cdnurlssl' )) . "/');\nvar d=doc", - "g.src=ucdn+" - ), $code ); - - if ($settings->getGlobalOption ( 'track_datacfasync' )) - $code = str_replace ( ' - getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Browser Details', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'DevicesDetection.getBrowserVersions'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Browser', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Browsers.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Browsers.php deleted file mode 100644 index 46f8f832..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Browsers.php +++ /dev/null @@ -1,73 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Browsers', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'DevicesDetection.getBrowsers'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Browser', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - elseif ($count == $this->limit) { - $class['Others'] = $js['Others'] = ''; - } - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Chart.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Chart.php deleted file mode 100644 index 946ba4de..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Chart.php +++ /dev/null @@ -1,88 +0,0 @@ -requestData(); - $response = $result["response"]; - if (!$result["success"]) { - echo '' . __('Piwik error', 'wp-piwik') . ': ' . htmlentities($response[$method]['message'], ENT_QUOTES, 'utf-8'); - } else { - $values = $labels = $bounced = $unique = ''; - $count = $uniqueSum = 0; - if (is_array($response['VisitsSummary.getVisits'])) - foreach ($response['VisitsSummary.getVisits'] as $date => $value) { - $count++; - $values .= $value . ','; - $unique .= $response['VisitsSummary.getUniqueVisitors'][$date] . ','; - $bounced .= $response['VisitsSummary.getBounceCount'][$date] . ','; - if ($this->parameter['period'] == 'week') { - preg_match("/[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/", $date, $dateList); - $textKey = $this->dateFormat($dateList[0], 'short_week'); - } else $textKey = substr($date, -2); - $labels .= '["' . $textKey . '"],'; - $uniqueSum += $response['VisitsSummary.getActions'][$date]; - } - else { - $values = '0,'; - $labels = '[0,"-"],'; - $unique = '0,'; - $bounced = '0,'; - } - $average = round($uniqueSum / 30, 0); - $values = substr($values, 0, -1); - $unique = substr($unique, 0, -1); - $labels = substr($labels, 0, -1); - $bounced = substr($bounced, 0, -1); - ?> -
            - -
            - - getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Cities', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'UserCountry.getCity'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('City', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - elseif ($count == $this->limit) { - $class['Others'] = $js['Others'] = ''; - } - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Country.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Country.php deleted file mode 100644 index 19d65288..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Country.php +++ /dev/null @@ -1,73 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Countries', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'UserCountry.getCountry '; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Country', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - elseif ($count == $this->limit) { - $class['Others'] = $js['Others'] = ''; - } - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Ecommerce.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Ecommerce.php deleted file mode 100644 index 2251315b..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Ecommerce.php +++ /dev/null @@ -1,51 +0,0 @@ -getTimeSettings(); - $this->title = $prefix . __('E-Commerce', 'wp-piwik'); - $this->method = 'Goals.get'; - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - } - - public function show() - { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] = 'error') - echo '' . __('Piwik error', 'wp-piwik') . ': ' . htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = null; - $revenue = is_float($this->value($response, 'revenue')) ? number_format($this->value($response, 'revenue'), 2) : ""; - $revenue_new = is_float($this->value($response, 'revenue_new_visit')) ? number_format($this->value($response, 'revenue_new_visit'), 2) : ""; - $revenue_return = is_float($this->value($response, 'revenue_returning_visit')) ? number_format($this->value($response, 'revenue_returning_visit'), 2) : ""; - $tableBody = array( - array(__('Conversions', 'wp-piwik') . ':', $this->value($response, 'nb_conversions')), - array(__('Visits converted', 'wp-piwik') . ':', $this->value($response, 'nb_visits_converted')), - array(__('Revenue', 'wp-piwik') . ':', $revenue), - array(__('Conversion rate', 'wp-piwik') . ':', $this->value($response, 'conversion_rate')), - array(__('Conversions (new visitor)', 'wp-piwik') . ':', $this->value($response, 'nb_conversions_new_visit')), - array(__('Visits converted (new visitor)', 'wp-piwik') . ':', $this->value($response, 'nb_visits_converted_new_visit')), - array(__('Revenue (new visitor)', 'wp-piwik') . ':', $revenue_new), - array(__('Conversion rate (new visitor)', 'wp-piwik') . ':', $this->value($response, 'conversion_rate_new_visit')), - array(__('Conversions (returning visitor)', 'wp-piwik') . ':', $this->value($response, 'nb_conversions_returning_visit')), - array(__('Visits converted (returning visitor)', 'wp-piwik') . ':', $this->value($response, 'nb_visits_converted_returning_visit')), - array(__('Revenue (returning visitor)', 'wp-piwik') . ':', $revenue_return), - array(__('Conversion rate (returning visitor)', 'wp-piwik') . ':', $this->value($response, 'conversion_rate_returning_visit')), - ); - $tableFoot = (self::$settings->getGlobalOption('piwik_shortcut') ? array(__('Shortcut', 'wp-piwik') . ':', 'Piwik' . (isset($aryConf['inline']) && $aryConf['inline'] ? ' - WP-Piwik' : '')) : null); - $this->table($tableHead, $tableBody, $tableFoot); - } - } - -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Items.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Items.php deleted file mode 100644 index e339cacc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Items.php +++ /dev/null @@ -1,52 +0,0 @@ -getTimeSettings(); - $this->title = $prefix.__('E-Commerce Items', 'wp-piwik'); - $this->method = 'Goals.getItemsName'; - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array( - __('Label', 'wp-piwik'), - __('Revenue', 'wp-piwik'), - __('Quantity', 'wp-piwik'), - __('Orders', 'wp-piwik'), - __('Avg. price', 'wp-piwik'), - __('Avg. quantity', 'wp-piwik'), - __('Conversion rate', 'wp-piwik'), - ); - $tableBody = array(); - if (is_array($response)) - foreach ($response as $data) { - array_push($tableBody, array( - $data['label'], - number_format($data['revenue'],2), - $data['quantity'], - $data['orders'], - number_format($data['avg_price'],2), - $data['avg_quantity'], - $data['conversion_rate'] - )); - } - $tableFoot = array(); - $this->table($tableHead, $tableBody, $tableFoot); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/ItemsCategory.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/ItemsCategory.php deleted file mode 100644 index 2ed58ae4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/ItemsCategory.php +++ /dev/null @@ -1,52 +0,0 @@ -getTimeSettings(); - $this->title = $prefix.__('E-Commerce Item Categories', 'wp-piwik'); - $this->method = 'Goals.getItemsCategory'; - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array( - __('Label', 'wp-piwik'), - __('Revenue', 'wp-piwik'), - __('Quantity', 'wp-piwik'), - __('Orders', 'wp-piwik'), - __('Avg. price', 'wp-piwik'), - __('Avg. quantity', 'wp-piwik'), - __('Conversion rate', 'wp-piwik'), - ); - $tableBody = array(); - if (is_array($response)) - foreach ($response as $data) { - array_push($tableBody, array( - $data['label'], - isset($data['revenue'])?number_format($data['revenue'],2):"-.--", - isset($data['quantity'])?$data['quantity']:'-', - isset($data['orders'])?$data['orders']:'-', - number_format($data['avg_price'],2), - $data['avg_quantity'], - $data['conversion_rate'] - )); - } - $tableFoot = array(); - $this->table($tableHead, $tableBody, $tableFoot); - } - } - -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Keywords.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Keywords.php deleted file mode 100644 index bb50c0c1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Keywords.php +++ /dev/null @@ -1,21 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Keywords', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'Referrers.getKeywords'; - $this->name = 'Keyword'; - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Models.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Models.php deleted file mode 100644 index 1b9d988f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Models.php +++ /dev/null @@ -1,73 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Models', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'DevicesDetection.getModel'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Model', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array(htmlentities($row['label']), $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - elseif ($count == $this->limit) { - $class['Others'] = $js['Others'] = ''; - } - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Noresult.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Noresult.php deleted file mode 100644 index 11b7c31d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Noresult.php +++ /dev/null @@ -1,38 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Site Search', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'Actions.getSiteSearchNoResultKeywords'; - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Keyword', 'wp-piwik'), __('Requests', 'wp-piwik'), __('Bounced', 'wp-piwik')); - $tableBody = array(); - $count = 0; - if (is_array($response)) - foreach ($response as $row) { - $count++; - $tableBody[] = array($row['label'], $row['nb_visits'], $row['bounce_rate']); - if ($count == 10) break; - } - $this->table($tableHead, $tableBody, null); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/OptOut.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/OptOut.php deleted file mode 100644 index c67b1cbe..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/OptOut.php +++ /dev/null @@ -1,38 +0,0 @@ -parameter = $params; - } - - public function show() - { - $protocol = (isset ($_SERVER ['HTTPS']) && $_SERVER ['HTTPS'] != 'off') ? 'https' : 'http'; - switch (self::$settings->getGlobalOption('piwik_mode')) { - case 'php' : - $PIWIK_URL = $protocol . ':' . self::$settings->getGlobalOption('proxy_url'); - break; - case 'cloud' : - $PIWIK_URL = 'https://' . self::$settings->getGlobalOption('piwik_user') . '.innocraft.cloud/'; - break; - case 'cloud-matomo': - $PIWIK_URL = 'https://' . self::$settings->getGlobalOption('matomo_user') . '.matomo.cloud/'; - break; - default : - $PIWIK_URL = self::$settings->getGlobalOption('piwik_url'); - } - $width = (isset($this->parameter['width']) ? esc_attr($this->parameter['width']) : ''); - $height = (isset($this->parameter['height']) ? esc_attr($this->parameter['height']) : ''); - $idSite = (isset($this->parameter['idsite']) ? 'idsite=' . (int)$this->parameter['idsite'] . '&' : ''); - $language = (isset($this->parameter['language']) ? esc_attr($this->parameter['language']) : 'en'); - $this->out(''); - } - -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Overview.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Overview.php deleted file mode 100644 index 115bdd0a..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Overview.php +++ /dev/null @@ -1,66 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => isset($params['period']) ? $params['period'] : $timeSettings['period'], - 'date' => isset($params['date']) ? $params['date'] : $timeSettings['date'], - 'description' => $timeSettings['description'] - ); - $this->title = !$this->isShortcode ? $prefix . __('Overview', 'wp-piwik') . ' (' . __($this->pageId == 'dashboard' ? $this->rangeName() : $timeSettings['description'], 'wp-piwik') . ')' : ($params['title'] ? $params['title'] : ''); - $this->method = 'VisitsSummary.get'; - } - - public function show() - { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] = 'error') - echo '' . __('Piwik error', 'wp-piwik') . ': ' . htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - if (in_array($this->parameter['date'], array('last30', 'last60', 'last90'))) { - $result = array(); - if (is_array($response)) { - foreach ($response as $data) - foreach ($data as $key => $value) - if (isset($result[$key]) && is_numeric($value)) - $result[$key] += $value; - elseif (is_numeric($value)) - $result[$key] = $value; - else - $result[$key] = 0; - if (isset($result['nb_visits']) && $result['nb_visits'] > 0) { - $result['nb_actions_per_visit'] = round($result['nb_actions'] / $result['nb_visits'], 1); - $result['bounce_rate'] = round($result['bounce_count'] / $result['nb_visits'] * 100, 1) . '%'; - $result['avg_time_on_site'] = round($result['sum_visit_length'] / $result['nb_visits'], 0); - } else $result['nb_actions_per_visit'] = $result['bounce_rate'] = $result['avg_time_on_site'] = 0; - } - $response = $result; - } - $time = isset($response['sum_visit_length']) ? $this->timeFormat($response['sum_visit_length']) : '-'; - $avgTime = isset($response['avg_time_on_site']) ? $this->timeFormat($response['avg_time_on_site']) : '-'; - $tableHead = null; - $tableBody = array(array(__('Visitors', 'wp-piwik') . ':', $this->value($response, 'nb_visits'))); - if ($this->value($response, 'nb_uniq_visitors') != '-') - array_push($tableBody, array(__('Unique visitors', 'wp-piwik') . ':', $this->value($response, 'nb_uniq_visitors'))); - array_push($tableBody, - array(__('Page views', 'wp-piwik') . ':', $this->value($response, 'nb_actions') . ' (Ø ' . $this->value($response, 'nb_actions_per_visit') . ')'), - array(__('Total time spent', 'wp-piwik') . ':', $time . ' (Ø ' . $avgTime . ')'), - array(__('Bounce count', 'wp-piwik') . ':', $this->value($response, 'bounce_count') . ' (' . $this->value($response, 'bounce_rate') . ')') - ); - if (!in_array($this->parameter['date'], array('last30', 'last60', 'last90'))) - array_push($tableBody, array(__('Time/visit', 'wp-piwik') . ':', $avgTime), array(__('Max. page views in one visit', 'wp-piwik') . ':', $this->value($response, 'max_actions'))); - $tableFoot = (self::$settings->getGlobalOption('piwik_shortcut') ? array(__('Shortcut', 'wp-piwik') . ':', 'Matomo' . (isset($aryConf['inline']) && $aryConf['inline'] ? ' - WP-Piwik' : '')) : null); - $this->table($tableHead, $tableBody, $tableFoot); - } - } - -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Pages.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Pages.php deleted file mode 100644 index 0b16ea5f..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Pages.php +++ /dev/null @@ -1,21 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Pages', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'Actions.getPageTitles'; - $this->name = __('Page', 'wp-piwik' ); - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Plugins.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Plugins.php deleted file mode 100644 index a5c7b92e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Plugins.php +++ /dev/null @@ -1,38 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Plugins', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'DevicePlugins.getPlugin'; - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Plugin', 'wp-piwik'), __('Visits', 'wp-piwik'), __('Percent', 'wp-piwik')); - $tableBody = array(); - $count = 0; - if (is_array($response)) - foreach ($response as $row) { - $count++; - $tableBody[] = array($row['label'], $row['nb_visits'], $row['nb_visits_percentage']); - if ($count == 10) break; - } - $this->table($tableHead, $tableBody, null); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Post.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Post.php deleted file mode 100644 index 82238101..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Post.php +++ /dev/null @@ -1,82 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => isset($params['period']) ? $params['period'] : $timeSettings['period'], - 'date' => isset($params['date']) ? $params['date'] : $timeSettings['date'], - 'key' => isset($params['key'])?$params['key']:null, - 'pageUrl' => isset($params['url'])?$params['url']:urlencode(get_permalink($post->ID)), - 'description' => $timeSettings['description'] - ); - $this->title = $prefix.__('Overview', 'wp-piwik').' ('.__($this->parameter['date'],'wp-piwik').')'; - $this->method = 'Actions.getPageUrl'; - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] = 'error') - echo '' . __('Piwik error', 'wp-piwik') . ': ' . htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - if (in_array($this->parameter['date'], array('last30', 'last60', 'last90'))) { - $result = array(); - if (is_array($response)) { - foreach ($response as $data) { - if (isset($data[0])) { - foreach ($data[0] as $key => $value) - if (isset($result[$key]) && is_numeric($value)) - $result[$key] += $value; - elseif (is_numeric($value)) - $result[$key] = $value; - else - $result[$key] = 0; - } - } - if (isset($result['nb_visits']) && $result['nb_visits'] > 0) { - $result['nb_actions_per_visit'] = round((isset( $result['nb_actions'] ) ? $result['nb_actions'] : 0) / $result['nb_visits'], 1); - $result['bounce_rate'] = round((isset($result['bounce_count']) ? $result['bounce_count'] : 0) / $result['nb_visits'] * 100, 1) . '%'; - $result['avg_time_on_site'] = round((isset($result['sum_visit_length']) ? $result['sum_visit_length'] : 0) / $result['nb_visits'], 0); - } else $result['nb_actions_per_visit'] = $result['bounce_rate'] = $result['avg_time_on_site'] = 0; - } - $response = $result; - } else { - if (isset($response[0])) - $response = $response[0]; - if ($this->parameter['key']) { - $this->out(isset($response[$this->parameter['key']])?$response[$this->parameter['key']]:'not defined'); - return; - } - } - $time = isset($response['sum_visit_length']) ? $this->timeFormat($response['sum_visit_length']) : '-'; - $avgTime = isset($response['avg_time_on_site']) ? $this->timeFormat($response['avg_time_on_site']) : '-'; - $tableHead = null; - $tableBody = array(array(__('Visitors', 'wp-piwik') . ':', $this->value($response, 'nb_visits'))); - if ($this->value($response, 'nb_uniq_visitors') != '-') - array_push($tableBody, array(__('Unique visitors', 'wp-piwik') . ':', $this->value($response, 'nb_uniq_visitors'))); - elseif ($this->value($response, 'sum_daily_nb_uniq_visitors') != '-') { - array_push($tableBody, __('Unique visitors', 'wp-piwik') . ':', $this->value($response, 'sum_daily_nb_uniq_visitors')); - } - array_push($tableBody, - array(__('Page views', 'wp-piwik').':', $this->value($response, 'nb_hits').' (Ø '.$this->value($response, 'entry_nb_actions').')'), - array(__('Total time spent', 'wp-piwik').':', $time), - array(__('Bounce count', 'wp-piwik').':', $this->value($response, 'entry_bounce_count').' ('.$this->value($response, 'bounce_rate').')'), - array(__('Time/visit', 'wp-piwik').':', $avgTime), - array(__('Min. generation time', 'wp-piwik').':', $this->value($response, 'min_time_generation')), - array(__('Max. generation time', 'wp-piwik').':', $this->value($response, 'max_time_generation')) - ); - if (!in_array($this->parameter['date'], array('last30', 'last60', 'last90'))) - array_push($tableBody, array(__('Time/visit', 'wp-piwik') . ':', $avgTime), array(__('Max. page views in one visit', 'wp-piwik') . ':', $this->value($response, 'max_actions'))); - $tableFoot = (self::$settings->getGlobalOption('piwik_shortcut') ? array(__('Shortcut', 'wp-piwik') . ':', 'Piwik' . (isset($aryConf['inline']) && $aryConf['inline'] ? ' - WP-Piwik' : '')) : null); - $this->table($tableHead, $tableBody, $tableFoot); - } - } - - } diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Referrers.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Referrers.php deleted file mode 100644 index 51c88824..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Referrers.php +++ /dev/null @@ -1,21 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Referrers', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'Referrers.getWebsites'; - $this->name = 'Referrer'; - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Screens.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Screens.php deleted file mode 100644 index 3aae02eb..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Screens.php +++ /dev/null @@ -1,68 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Resolutions', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'Resolution.getResolution'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Resolution', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Search.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Search.php deleted file mode 100644 index 2cddf7ee..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Search.php +++ /dev/null @@ -1,38 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Site Search', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'Actions.getSiteSearchKeywords'; - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Keyword', 'wp-piwik'), __('Requests', 'wp-piwik'), __('Bounced', 'wp-piwik')); - $tableBody = array(); - $count = 0; - if (is_array($response)) - foreach ($response as $row) { - $count++; - $tableBody[] = array(htmlentities($row['label']), $row['nb_visits'], $row['bounce_rate']); - if ($count == 10) break; - } - $this->table($tableHead, $tableBody, null); - } - } - - } diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Seo.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Seo.php deleted file mode 100644 index a5522253..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Seo.php +++ /dev/null @@ -1,31 +0,0 @@ -parameter = array( - 'url' => get_bloginfo('url') - ); - $this->title = $prefix.__('SEO', 'wp-piwik'); - $this->method = 'SEO.getRank'; - } - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - echo '
            '; - if (is_array($response)) - foreach ($response as $val) - echo ''; - else echo ''; - echo '
            '.(isset($val['logo_link']) && !empty($val['logo_link'])?''.$val['label'].'':$val['label']).''.$val['rank'].'
            SEO module currently not available.
            '; - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/SystemDetails.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/SystemDetails.php deleted file mode 100644 index 7403bf68..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/SystemDetails.php +++ /dev/null @@ -1,66 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Operation System Details', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'DevicesDetection.getOsVersions'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Operation System', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Systems.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Systems.php deleted file mode 100644 index 5b952a90..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Systems.php +++ /dev/null @@ -1,66 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix.__('Operation Systems', 'wp-piwik').' ('.__($timeSettings['description'],'wp-piwik').')'; - $this->method = 'DevicesDetection.getOsFamilies'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL().'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script ( 'wp-piwik-chartjs', self::$wpPiwik->getPluginURL () . 'js/chartjs/chart.min.js', "3.4.1" ); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL().'css/wp-piwik.css',array(),self::$wpPiwik->getPluginVersion()); -} - - public function show() { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] ='error') - echo ''.__('Piwik error', 'wp-piwik').': '.htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Operation System', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) $unique = 'nb_uniq_visitors'; - else $unique = 'sum_daily_nb_uniq_visitors'; - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $count++; - $sum += isset($row[$unique])?$row[$unique]:0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$unique], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$unique]; - $tableBody[$row['label']] = array($row['label'], $row[$unique], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j'."( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1]/$sum*100, 2).'%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - - } \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Types.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Types.php deleted file mode 100644 index 9a16f0ba..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Types.php +++ /dev/null @@ -1,80 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => $timeSettings['period'], - 'date' => $timeSettings['date'] - ); - $this->title = $prefix . __('Types', 'wp-piwik') . ' (' . __($timeSettings['description'], 'wp-piwik') . ')'; - $this->method = 'DevicesDetection.getType'; - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL() . 'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script('wp-piwik-chartjs', self::$wpPiwik->getPluginURL() . 'js/chartjs/chart.min.js', "3.4.1"); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL() . 'css/wp-piwik.css', array(), self::$wpPiwik->getPluginVersion()); - } - - public function show() - { - $response = self::$wpPiwik->request($this->apiID[$this->method]); - $tableBody = array(); - if (!empty($response['result']) && $response['result'] = 'error') - echo '' . __('Piwik error', 'wp-piwik') . ': ' . htmlentities($response['message'], ENT_QUOTES, 'utf-8'); - else { - $tableHead = array(__('Type', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Percent', 'wp-piwik')); - if (isset($response[0]['nb_uniq_visitors'])) { - $unique = 'nb_uniq_visitors'; - } else { - $unique = 'sum_daily_nb_uniq_visitors'; - } - $count = 0; - $sum = 0; - $js = array(); - $class = array(); - if (is_array($response)) - foreach ($response as $row) { - $key = isset($row[$unique]) ? $unique : "nb_visits"; - $count++; - $sum += isset($row[$key]) ? $row[$key] : 0; - if ($count < $this->limit) - $tableBody[$row['label']] = array($row['label'], $row[$key], 0); - elseif (!isset($tableBody['Others'])) { - $tableBody['Others'] = array($row['label'], $row[$key], 0); - $class['Others'] = 'wp-piwik-hideDetails'; - $js['Others'] = '$j' . "( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - $tableBody[$row['label']] = array($row['label'], $row[$key], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j' . "( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } else { - $tableBody['Others'][1] += $row[$key]; - $tableBody[$row['label']] = array($row['label'], $row[$key], 0); - $class[$row['label']] = 'wp-piwik-hideDetails hidden'; - $js[$row['label']] = '$j' . "( '.wp-piwik-hideDetails' ).toggle( 'hidden' );"; - } - } - if ($count > $this->limit) { - $tableBody['Others'][0] = __('Others', 'wp-piwik'); - } elseif ($count == $this->limit) { - $class['Others'] = $js['Others'] = ''; - } - - foreach ($tableBody as $key => $row) - $tableBody[$key][2] = number_format($row[1] / $sum * 100, 2) . '%'; - - if (!empty($tableBody)) $this->pieChart($tableBody); - $this->table($tableHead, $tableBody, null, false, $js, $class); - } - } - -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Visitors.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Visitors.php deleted file mode 100644 index 26cbd117..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/classes/WP_Piwik/Widget/Visitors.php +++ /dev/null @@ -1,79 +0,0 @@ -getTimeSettings(); - $this->parameter = array( - 'idSite' => self::$wpPiwik->getPiwikSiteId($this->blogId), - 'period' => isset($params['period']) ? $params['period'] : $timeSettings['period'], - 'date' => 'last' . ($timeSettings['period'] == 'day' ? '30' : '12'), - 'limit' => null - ); - $this->title = $prefix . __('Visitors', 'wp-piwik') . ' (' . __($this->rangeName(), 'wp-piwik') . ')'; - $this->method = array('VisitsSummary.getVisits', 'VisitsSummary.getUniqueVisitors', 'VisitsSummary.getBounceCount', 'VisitsSummary.getActions'); - $this->context = 'normal'; - wp_enqueue_script('wp-piwik', self::$wpPiwik->getPluginURL() . 'js/wp-piwik.js', array(), self::$wpPiwik->getPluginVersion(), true); - wp_enqueue_script('wp-piwik-chartjs', self::$wpPiwik->getPluginURL() . 'js/chartjs/chart.min.js', "3.4.1"); - wp_enqueue_style('wp-piwik', self::$wpPiwik->getPluginURL() . 'css/wp-piwik.css', array(), self::$wpPiwik->getPluginVersion()); - } - - public function requestData() - { - $response = array(); - $success = true; - foreach ($this->method as $method) { - $response[$method] = self::$wpPiwik->request($this->apiID[$method]); - if (!empty($response[$method]['result']) && $response[$method]['result'] = 'error') - $success = false; - } - return array("response" => $response, "success" => $success); - } - - public function show() - { - $result = $this->requestData(); - $response = $result["response"]; - if (!$result["success"]) { - echo '' . __('Piwik error', 'wp-piwik') . ': ' . htmlentities($response[$method]['message'], ENT_QUOTES, 'utf-8'); - } else { - $data = array(); - if (is_array($response) && is_array($response['VisitsSummary.getVisits'])) - foreach ($response['VisitsSummary.getVisits'] as $key => $value) { - if ($this->parameter['period'] == 'week') { - preg_match("/[0-9]{4}-(0[1-9]|1[0-2])-(0[1-9]|[1-2][0-9]|3[0-1])/", $key, $dateList); - $jsKey = $dateList[0]; - $textKey = $this->dateFormat($jsKey, 'week'); - } elseif ($this->parameter['period'] == 'month') { - $jsKey = $key . '-01'; - $textKey = $key; - } else $jsKey = $textKey = $key; - $data[] = array( - $textKey, - $value, - $response['VisitsSummary.getUniqueVisitors'][$key] ? $response['VisitsSummary.getUniqueVisitors'][$key] : '-', - $response['VisitsSummary.getBounceCount'][$key] ? $response['VisitsSummary.getBounceCount'][$key] : '-', - $response['VisitsSummary.getActions'][$key] ? $response['VisitsSummary.getActions'][$key] : '-' - ); - $javaScript[] = 'javascript:wp_piwik_datelink(\'' . urlencode('wp-piwik_stats') . '\',\'' . str_replace('-', '', $jsKey) . '\',\'' . (isset($_GET['wpmu_show_stats']) ? (int)$_GET['wpmu_show_stats'] : '') . '\');'; - } - $this->table( - array(__('Date', 'wp-piwik'), __('Visits', 'wp-piwik'), __('Unique', 'wp-piwik'), __('Bounced', 'wp-piwik'), __('Page Views', 'wp-piwik')), - array_reverse($data), - array(), - 'clickable', - array_reverse(isset($javaScript) ? $javaScript : []) - ); - } - - } - -} \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/config.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/config.php deleted file mode 100644 index 7e460314..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/config.php +++ /dev/null @@ -1,9 +0,0 @@ - - - - - - GNU General Public License - GNU Project - Free Software Foundation (FSF) - -

            GNU GENERAL PUBLIC LICENSE

            -

            Version 3, 29 June 2007

            - -

            Copyright © 2007 Free Software Foundation, Inc. <http://fsf.org/>

            - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed.

            - -

            Preamble

            - -

            The GNU General Public License is a free, copyleft license for -software and other kinds of works.

            - -

            The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too.

            - -

            When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things.

            - -

            To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others.

            - -

            For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights.

            - -

            Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it.

            - -

            For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions.

            - -

            Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users.

            - -

            Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free.

            - -

            The precise terms and conditions for copying, distribution and -modification follow.

            - -

            TERMS AND CONDITIONS

            - -

            0. Definitions.

            - -

            “This License” refers to version 3 of the GNU General Public License.

            - -

            “Copyright” also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks.

            - -

            “The Program” refers to any copyrightable work licensed under this -License. Each licensee is addressed as “you”. “Licensees” and -“recipients” may be individuals or organizations.

            - -

            To “modify” a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a “modified version” of the -earlier work or a work “based on” the earlier work.

            - -

            A “covered work” means either the unmodified Program or a work based -on the Program.

            - -

            To “propagate” a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well.

            - -

            To “convey” a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying.

            - -

            An interactive user interface displays “Appropriate Legal Notices” -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion.

            - -

            1. Source Code.

            - -

            The “source code” for a work means the preferred form of the work -for making modifications to it. “Object code” means any non-source -form of a work.

            - -

            A “Standard Interface” means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language.

            - -

            The “System Libraries” of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -“Major Component”, in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it.

            - -

            The “Corresponding Source” for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work.

            - -

            The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source.

            - -

            The Corresponding Source for a work in source code form is that -same work.

            - -

            2. Basic Permissions.

            - -

            All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law.

            - -

            You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you.

            - -

            Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary.

            - -

            3. Protecting Users' Legal Rights From Anti-Circumvention Law.

            - -

            No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures.

            - -

            When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures.

            - -

            4. Conveying Verbatim Copies.

            - -

            You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program.

            - -

            You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee.

            - -

            5. Conveying Modified Source Versions.

            - -

            You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions:

            - -
              -
            • a) The work must carry prominent notices stating that you modified - it, and giving a relevant date.
            • - -
            • b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - “keep intact all notices”.
            • - -
            • c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it.
            • - -
            • d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so.
            • -
            - -

            A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -“aggregate” if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate.

            - -

            6. Conveying Non-Source Forms.

            - -

            You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways:

            - -
              -
            • a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange.
            • - -
            • b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge.
            • - -
            • c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b.
            • - -
            • d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements.
            • - -
            • e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d.
            • -
            - -

            A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work.

            - -

            A “User Product” is either (1) a “consumer product”, which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, “normally used” refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product.

            - -

            “Installation Information” for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made.

            - -

            If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM).

            - -

            The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network.

            - -

            Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying.

            - -

            7. Additional Terms.

            - -

            “Additional permissions” are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions.

            - -

            When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission.

            - -

            Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms:

            - -
              -
            • a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or
            • - -
            • b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or
            • - -
            • c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or
            • - -
            • d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or
            • - -
            • e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or
            • - -
            • f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors.
            • -
            - -

            All other non-permissive additional terms are considered “further -restrictions” within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying.

            - -

            If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms.

            - -

            Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way.

            - -

            8. Termination.

            - -

            You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11).

            - -

            However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation.

            - -

            Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice.

            - -

            Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10.

            - -

            9. Acceptance Not Required for Having Copies.

            - -

            You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so.

            - -

            10. Automatic Licensing of Downstream Recipients.

            - -

            Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License.

            - -

            An “entity transaction” is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts.

            - -

            You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it.

            - -

            11. Patents.

            - -

            A “contributor” is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's “contributor version”.

            - -

            A contributor's “essential patent claims” are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, “control” includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License.

            - -

            Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version.

            - -

            In the following three paragraphs, a “patent license” is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To “grant” such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party.

            - -

            If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. “Knowingly relying” means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid.

            - -

            If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it.

            - -

            A patent license is “discriminatory” if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007.

            - -

            Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law.

            - -

            12. No Surrender of Others' Freedom.

            - -

            If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program.

            - -

            13. Use with the GNU Affero General Public License.

            - -

            Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such.

            - -

            14. Revised Versions of this License.

            - -

            The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns.

            - -

            Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License “or any later version” applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation.

            - -

            If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program.

            - -

            Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version.

            - -

            15. Disclaimer of Warranty.

            - -

            THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM “AS IS” WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION.

            - -

            16. Limitation of Liability.

            - -

            IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES.

            - -

            17. Interpretation of Sections 15 and 16.

            - -

            If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee.

            - -

            END OF TERMS AND CONDITIONS

            - -

            How to Apply These Terms to Your New Programs

            - -

            If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms.

            - -

            To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the “copyright” line and a pointer to where the full notice is found.

            - -
                <one line to give the program's name and a brief idea of what it does.>
            -    Copyright (C) <year>  <name of author>
            -
            -    This program is free software: you can redistribute it and/or modify
            -    it under the terms of the GNU General Public License as published by
            -    the Free Software Foundation, either version 3 of the License, or
            -    (at your option) any later version.
            -
            -    This program is distributed in the hope that it will be useful,
            -    but WITHOUT ANY WARRANTY; without even the implied warranty of
            -    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
            -    GNU General Public License for more details.
            -
            -    You should have received a copy of the GNU General Public License
            -    along with this program.  If not, see <http://www.gnu.org/licenses/>.
            -
            - -

            Also add information on how to contact you by electronic and paper mail.

            - -

            If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode:

            - -
                <program>  Copyright (C) <year>  <name of author>
            -    This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
            -    This is free software, and you are welcome to redistribute it
            -    under certain conditions; type `show c' for details.
            -
            - -

            The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an “about box”.

            - -

            You should also get your employer (if you work as a programmer) or school, -if any, to sign a “copyright disclaimer” for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -<http://www.gnu.org/licenses/>.

            - -

            The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -<http://www.gnu.org/philosophy/why-not-lgpl.html>.

            - - - \ No newline at end of file diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/index.php b/wp-content/upgrade-temp-backup/plugins/wp-piwik/index.php deleted file mode 100644 index 9b3347dc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/index.php +++ /dev/null @@ -1,2 +0,0 @@ - -
            - Simple yet flexible JavaScript charting for designers & developers -

            - -

            - Downloads - GitHub Workflow Status - Coverage - Awesome - Slack -

            - -## Documentation - -All the links point to the new version 3 of the lib. - -* [Introduction](https://www.chartjs.org/docs/latest/) -* [Getting Started](https://www.chartjs.org/docs/latest/getting-started/index) -* [General](https://www.chartjs.org/docs/latest/general/data-structures) -* [Configuration](https://www.chartjs.org/docs/latest/configuration/index) -* [Charts](https://www.chartjs.org/docs/latest/charts/line) -* [Axes](https://www.chartjs.org/docs/latest/axes/index) -* [Developers](https://www.chartjs.org/docs/latest/developers/index) -* [Popular Extensions](https://github.com/chartjs/awesome) -* [Samples](https://www.chartjs.org/samples/) - -In case you are looking for the docs of version 2, you will have to specify the specific version in the url like this: [https://www.chartjs.org/docs/2.9.4/](https://www.chartjs.org/docs/2.9.4/) - -## Contributing - -Instructions on building and testing Chart.js can be found in [the documentation](https://www.chartjs.org/docs/master/developers/contributing.html#building-and-testing). Before submitting an issue or a pull request, please take a moment to look over the [contributing guidelines](https://www.chartjs.org/docs/master/developers/contributing) first. For support, please post questions on [Stack Overflow](https://stackoverflow.com/questions/tagged/chartjs) with the `chartjs` tag. - -## License - -Chart.js is available under the [MIT license](https://opensource.org/licenses/MIT). diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/js/chartjs/chart.min.js b/wp-content/upgrade-temp-backup/plugins/wp-piwik/js/chartjs/chart.min.js deleted file mode 100644 index b982f045..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/js/chartjs/chart.min.js +++ /dev/null @@ -1,13 +0,0 @@ -/*! - * Chart.js v3.4.1 - * https://www.chartjs.org - * (c) 2021 Chart.js Contributors - * Released under the MIT License - */ -!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).Chart=e()}(this,(function(){"use strict";const t="undefined"==typeof window?function(t){return t()}:window.requestAnimationFrame;function e(e,i,n){const o=n||(t=>Array.prototype.slice.call(t));let s=!1,a=[];return function(...n){a=o(n),s||(s=!0,t.call(window,(()=>{s=!1,e.apply(i,a)})))}}function i(t,e){let i;return function(){return e?(clearTimeout(i),i=setTimeout(t,e)):t(),e}}const n=t=>"start"===t?"left":"end"===t?"right":"center",o=(t,e,i)=>"start"===t?e:"end"===t?i:(e+i)/2,s=(t,e,i,n)=>t===(n?"left":"right")?i:"center"===t?(e+i)/2:e;var a=new class{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,e,i,n){const o=e.listeners[n],s=e.duration;o.forEach((n=>n({chart:t,initial:e.initial,numSteps:s,currentStep:Math.min(i-e.start,s)})))}_refresh(){const e=this;e._request||(e._running=!0,e._request=t.call(window,(()=>{e._update(),e._request=null,e._running&&e._refresh()})))}_update(t=Date.now()){const e=this;let i=0;e._charts.forEach(((n,o)=>{if(!n.running||!n.items.length)return;const s=n.items;let a,r=s.length-1,l=!1;for(;r>=0;--r)a=s[r],a._active?(a._total>n.duration&&(n.duration=a._total),a.tick(t),l=!0):(s[r]=s[s.length-1],s.pop());l&&(o.draw(),e._notify(o,n,t,"progress")),s.length||(n.running=!1,e._notify(o,n,t,"complete"),n.initial=!1),i+=s.length})),e._lastDate=t,0===i&&(e._running=!1)}_getAnims(t){const e=this._charts;let i=e.get(t);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},e.set(t,i)),i}listen(t,e,i){this._getAnims(t).listeners[e].push(i)}add(t,e){e&&e.length&&this._getAnims(t).items.push(...e)}has(t){return this._getAnims(t).items.length>0}start(t){const e=this._charts.get(t);e&&(e.running=!0,e.start=Date.now(),e.duration=e.items.reduce(((t,e)=>Math.max(t,e._duration)),0),this._refresh())}running(t){if(!this._running)return!1;const e=this._charts.get(t);return!!(e&&e.running&&e.items.length)}stop(t){const e=this._charts.get(t);if(!e||!e.items.length)return;const i=e.items;let n=i.length-1;for(;n>=0;--n)i[n].cancel();e.items=[],this._notify(t,e,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}; -/*! - * @kurkle/color v0.1.9 - * https://github.com/kurkle/color#readme - * (c) 2020 Jukka Kurkela - * Released under the MIT License - */const r={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},l="0123456789ABCDEF",c=t=>l[15&t],h=t=>l[(240&t)>>4]+l[15&t],d=t=>(240&t)>>4==(15&t);function u(t){var e=function(t){return d(t.r)&&d(t.g)&&d(t.b)&&d(t.a)}(t)?c:h;return t?"#"+e(t.r)+e(t.g)+e(t.b)+(t.a<255?e(t.a):""):t}function f(t){return t+.5|0}const g=(t,e,i)=>Math.max(Math.min(t,i),e);function p(t){return g(f(2.55*t),0,255)}function m(t){return g(f(255*t),0,255)}function x(t){return g(f(t/2.55)/100,0,1)}function b(t){return g(f(100*t),0,100)}const _=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/;const y=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function v(t,e,i){const n=e*Math.min(i,1-i),o=(e,o=(e+t/30)%12)=>i-n*Math.max(Math.min(o-3,9-o,1),-1);return[o(0),o(8),o(4)]}function w(t,e,i){const n=(n,o=(n+t/60)%6)=>i-i*e*Math.max(Math.min(o,4-o,1),0);return[n(5),n(3),n(1)]}function M(t,e,i){const n=v(t,1,.5);let o;for(e+i>1&&(o=1/(e+i),e*=o,i*=o),o=0;o<3;o++)n[o]*=1-e-i,n[o]+=e;return n}function k(t){const e=t.r/255,i=t.g/255,n=t.b/255,o=Math.max(e,i,n),s=Math.min(e,i,n),a=(o+s)/2;let r,l,c;return o!==s&&(c=o-s,l=a>.5?c/(2-o-s):c/(o+s),r=o===e?(i-n)/c+(i>16&255,s>>8&255,255&s]}return t}(),A.transparent=[0,0,0,0]);const e=A[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:4===e.length?e[3]:255}}function R(t,e,i){if(t){let n=k(t);n[e]=Math.max(0,Math.min(n[e]+n[e]*i,0===e?360:1)),n=P(n),t.r=n[0],t.g=n[1],t.b=n[2]}}function E(t,e){return t?Object.assign(e||{},t):t}function z(t){var e={r:0,g:0,b:0,a:255};return Array.isArray(t)?t.length>=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=m(t[3]))):(e=E(t,{r:0,g:0,b:0,a:1})).a=m(e.a),e}function I(t){return"r"===t.charAt(0)?function(t){const e=_.exec(t);let i,n,o,s=255;if(e){if(e[7]!==i){const t=+e[7];s=255&(e[8]?p(t):255*t)}return i=+e[1],n=+e[3],o=+e[5],i=255&(e[2]?p(i):i),n=255&(e[4]?p(n):n),o=255&(e[6]?p(o):o),{r:i,g:n,b:o,a:s}}}(t):C(t)}class F{constructor(t){if(t instanceof F)return t;const e=typeof t;let i;var n,o,s;"object"===e?i=z(t):"string"===e&&(s=(n=t).length,"#"===n[0]&&(4===s||5===s?o={r:255&17*r[n[1]],g:255&17*r[n[2]],b:255&17*r[n[3]],a:5===s?17*r[n[4]]:255}:7!==s&&9!==s||(o={r:r[n[1]]<<4|r[n[2]],g:r[n[3]]<<4|r[n[4]],b:r[n[5]]<<4|r[n[6]],a:9===s?r[n[7]]<<4|r[n[8]]:255})),i=o||L(t)||I(t)),this._rgb=i,this._valid=!!i}get valid(){return this._valid}get rgb(){var t=E(this._rgb);return t&&(t.a=x(t.a)),t}set rgb(t){this._rgb=z(t)}rgbString(){return this._valid?(t=this._rgb)&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${x(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`):this._rgb;var t}hexString(){return this._valid?u(this._rgb):this._rgb}hslString(){return this._valid?function(t){if(!t)return;const e=k(t),i=e[0],n=b(e[1]),o=b(e[2]);return t.a<255?`hsla(${i}, ${n}%, ${o}%, ${x(t.a)})`:`hsl(${i}, ${n}%, ${o}%)`}(this._rgb):this._rgb}mix(t,e){const i=this;if(t){const n=i.rgb,o=t.rgb;let s;const a=e===s?.5:e,r=2*a-1,l=n.a-o.a,c=((r*l==-1?r:(r+l)/(1+r*l))+1)/2;s=1-c,n.r=255&c*n.r+s*o.r+.5,n.g=255&c*n.g+s*o.g+.5,n.b=255&c*n.b+s*o.b+.5,n.a=a*n.a+(1-a)*o.a,i.rgb=n}return i}clone(){return new F(this.rgb)}alpha(t){return this._rgb.a=m(t),this}clearer(t){return this._rgb.a*=1-t,this}greyscale(){const t=this._rgb,e=f(.3*t.r+.59*t.g+.11*t.b);return t.r=t.g=t.b=e,this}opaquer(t){return this._rgb.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return R(this._rgb,2,t),this}darken(t){return R(this._rgb,2,-t),this}saturate(t){return R(this._rgb,1,t),this}desaturate(t){return R(this._rgb,1,-t),this}rotate(t){return function(t,e){var i=k(t);i[0]=D(i[0]+e),i=P(i),t.r=i[0],t.g=i[1],t.b=i[2]}(this._rgb,t),this}}function B(t){return new F(t)}const V=t=>t instanceof CanvasGradient||t instanceof CanvasPattern;function W(t){return V(t)?t:B(t)}function N(t){return V(t)?t:B(t).saturate(.5).darken(.1).hexString()}function H(){}const j=function(){let t=0;return function(){return t++}}();function $(t){return null==t}function Y(t){if(Array.isArray&&Array.isArray(t))return!0;const e=Object.prototype.toString.call(t);return"[object"===e.substr(0,7)&&"Array]"===e.substr(-6)}function U(t){return null!==t&&"[object Object]"===Object.prototype.toString.call(t)}const X=t=>("number"==typeof t||t instanceof Number)&&isFinite(+t);function q(t,e){return X(t)?t:e}function K(t,e){return void 0===t?e:t}const G=(t,e)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100:t/e,Z=(t,e)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100*e:+t;function Q(t,e,i){if(t&&"function"==typeof t.call)return t.apply(i,e)}function J(t,e,i,n){let o,s,a;if(Y(t))if(s=t.length,n)for(o=s-1;o>=0;o--)e.call(i,t[o],o);else for(o=0;oi;)t=t[e.substr(i,n-i)],i=n+1,n=rt(e,i);return t}function ct(t){return t.charAt(0).toUpperCase()+t.slice(1)}const ht=t=>void 0!==t,dt=t=>"function"==typeof t,ut=(t,e)=>{if(t.size!==e.size)return!1;for(const i of t)if(!e.has(i))return!1;return!0},ft=Object.create(null),gt=Object.create(null);function pt(t,e){if(!e)return t;const i=e.split(".");for(let e=0,n=i.length;et.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(t,e)=>N(e.backgroundColor),this.hoverBorderColor=(t,e)=>N(e.borderColor),this.hoverColor=(t,e)=>N(e.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.describe(t)}set(t,e){return mt(this,t,e)}get(t){return pt(this,t)}describe(t,e){return mt(gt,t,e)}override(t,e){return mt(ft,t,e)}route(t,e,i,n){const o=pt(this,t),s=pt(this,i),a="_"+e;Object.defineProperties(o,{[a]:{value:o[e],writable:!0},[e]:{enumerable:!0,get(){const t=this[a],e=s[n];return U(t)?Object.assign({},e,t):K(t,e)},set(t){this[a]=t}}})}}({_scriptable:t=>!t.startsWith("on"),_indexable:t=>"events"!==t,hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}});const bt=Math.PI,_t=2*bt,yt=_t+bt,vt=Number.POSITIVE_INFINITY,wt=bt/180,Mt=bt/2,kt=bt/4,St=2*bt/3,Pt=Math.log10,Dt=Math.sign;function Ct(t){const e=Math.round(t);t=At(t,e,t/1e3)?e:t;const i=Math.pow(10,Math.floor(Pt(t))),n=t/i;return(n<=1?1:n<=2?2:n<=5?5:10)*i}function Ot(t){const e=[],i=Math.sqrt(t);let n;for(n=1;nt-e)).pop(),e}function Tt(t){return!isNaN(parseFloat(t))&&isFinite(t)}function At(t,e,i){return Math.abs(t-e)=t}function Rt(t,e,i){let n,o,s;for(n=0,o=t.length;nl&&cn&&(n=s),n}function Ut(t,e,i,n){let o=(n=n||{}).data=n.data||{},s=n.garbageCollect=n.garbageCollect||[];n.font!==e&&(o=n.data={},s=n.garbageCollect=[],n.font=e),t.save(),t.font=e;let a=0;const r=i.length;let l,c,h,d,u;for(l=0;li.length){for(l=0;l0&&t.stroke()}}function Gt(t,e,i){return i=i||.5,t&&t.x>e.left-i&&t.xe.top-i&&t.y0&&""!==s.strokeColor;let l,c;for(t.save(),t.font=o.string,function(t,e){e.translation&&t.translate(e.translation[0],e.translation[1]);$(e.rotation)||t.rotate(e.rotation);e.color&&(t.fillStyle=e.color);e.textAlign&&(t.textAlign=e.textAlign);e.textBaseline&&(t.textBaseline=e.textBaseline)}(t,s),l=0;lt[i]1;)n=s+o>>1,i(n)?s=n:o=n;return{lo:s,hi:o}}const se=(t,e,i)=>oe(t,i,(n=>t[n][e]oe(t,i,(n=>t[n][e]>=i));function re(t,e,i){let n=0,o=t.length;for(;nn&&t[o-1]>i;)o--;return n>0||o{const i="_onData"+ct(e),n=t[e];Object.defineProperty(t,e,{configurable:!0,enumerable:!1,value(...e){const o=n.apply(this,e);return t._chartjs.listeners.forEach((t=>{"function"==typeof t[i]&&t[i](...e)})),o}})})))}function he(t,e){const i=t._chartjs;if(!i)return;const n=i.listeners,o=n.indexOf(e);-1!==o&&n.splice(o,1),n.length>0||(le.forEach((e=>{delete t[e]})),delete t._chartjs)}function de(t){const e=new Set;let i,n;for(i=0,n=t.length;iwindow.getComputedStyle(t,null);function pe(t,e){return ge(t).getPropertyValue(e)}const me=["top","right","bottom","left"];function xe(t,e,i){const n={};i=i?"-"+i:"";for(let o=0;o<4;o++){const s=me[o];n[s]=parseFloat(t[e+"-"+s+i])||0}return n.width=n.left+n.right,n.height=n.top+n.bottom,n}function be(t,e){const{canvas:i,currentDevicePixelRatio:n}=e,o=ge(i),s="border-box"===o.boxSizing,a=xe(o,"padding"),r=xe(o,"border","width"),{x:l,y:c,box:h}=function(t,e){const i=t.native||t,n=i.touches,o=n&&n.length?n[0]:i,{offsetX:s,offsetY:a}=o;let r,l,c=!1;if(((t,e,i)=>(t>0||e>0)&&(!i||!i.shadowRoot))(s,a,i.target))r=s,l=a;else{const t=e.getBoundingClientRect();r=o.clientX-t.left,l=o.clientY-t.top,c=!0}return{x:r,y:l,box:c}}(t,i),d=a.left+(h&&r.left),u=a.top+(h&&r.top);let{width:f,height:g}=e;return s&&(f-=a.width+r.width,g-=a.height+r.height),{x:Math.round((l-d)/f*i.width/n),y:Math.round((c-u)/g*i.height/n)}}const _e=t=>Math.round(10*t)/10;function ye(t,e,i,n){const o=ge(t),s=xe(o,"margin"),a=fe(o.maxWidth,t,"clientWidth")||vt,r=fe(o.maxHeight,t,"clientHeight")||vt,l=function(t,e,i){let n,o;if(void 0===e||void 0===i){const s=ue(t);if(s){const t=s.getBoundingClientRect(),a=ge(s),r=xe(a,"border","width"),l=xe(a,"padding");e=t.width-l.width-r.width,i=t.height-l.height-r.height,n=fe(a.maxWidth,s,"clientWidth"),o=fe(a.maxHeight,s,"clientHeight")}else e=t.clientWidth,i=t.clientHeight}return{width:e,height:i,maxWidth:n||vt,maxHeight:o||vt}}(t,e,i);let{width:c,height:h}=l;if("content-box"===o.boxSizing){const t=xe(o,"border","width"),e=xe(o,"padding");c-=e.width+t.width,h-=e.height+t.height}return c=Math.max(0,c-s.width),h=Math.max(0,n?Math.floor(c/n):h-s.height),c=_e(Math.min(c,a,l.maxWidth)),h=_e(Math.min(h,r,l.maxHeight)),c&&!h&&(h=_e(c/2)),{width:c,height:h}}function ve(t,e,i){const n=e||1,o=Math.floor(t.height*n),s=Math.floor(t.width*n);t.height=o/n,t.width=s/n;const a=t.canvas;return a.style&&(i||!a.style.height&&!a.style.width)&&(a.style.height=`${t.height}px`,a.style.width=`${t.width}px`),(t.currentDevicePixelRatio!==n||a.height!==o||a.width!==s)&&(t.currentDevicePixelRatio=n,a.height=o,a.width=s,t.ctx.setTransform(n,0,0,n,0,0),!0)}const we=function(){let t=!1;try{const e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch(t){}return t}();function Me(t,e){const i=pe(t,e),n=i&&i.match(/^(\d+)(\.\d+)?px$/);return n?+n[1]:void 0}function ke(t,e){return"native"in t?{x:t.x,y:t.y}:be(t,e)}function Se(t,e,i,n){const{controller:o,data:s,_sorted:a}=t,r=o._cachedMeta.iScale;if(r&&e===r.axis&&a&&s.length){const t=r._reversePixels?ae:se;if(!n)return t(s,e,i);if(o._sharedOptions){const n=s[0],o="function"==typeof n.getRange&&n.getRange(e);if(o){const n=t(s,e,i-o),a=t(s,e,i+o);return{lo:n.lo,hi:a.hi}}}}return{lo:0,hi:s.length-1}}function Pe(t,e,i,n,o){const s=t.getSortedVisibleDatasetMetas(),a=i[e];for(let t=0,i=s.length;t{t[r](o[a],n)&&s.push({element:t,datasetIndex:e,index:i}),t.inRange(o.x,o.y,n)&&(l=!0)})),i.intersect&&!l?[]:s}var Te={modes:{index(t,e,i,n){const o=ke(e,t),s=i.axis||"x",a=i.intersect?De(t,o,s,n):Ce(t,o,s,!1,n),r=[];return a.length?(t.getSortedVisibleDatasetMetas().forEach((t=>{const e=a[0].index,i=t.data[e];i&&!i.skip&&r.push({element:i,datasetIndex:t.index,index:e})})),r):[]},dataset(t,e,i,n){const o=ke(e,t),s=i.axis||"xy";let a=i.intersect?De(t,o,s,n):Ce(t,o,s,!1,n);if(a.length>0){const e=a[0].datasetIndex,i=t.getDatasetMeta(e).data;a=[];for(let t=0;tDe(t,ke(e,t),i.axis||"xy",n),nearest:(t,e,i,n)=>Ce(t,ke(e,t),i.axis||"xy",i.intersect,n),x:(t,e,i,n)=>(i.axis="x",Oe(t,e,i,n)),y:(t,e,i,n)=>(i.axis="y",Oe(t,e,i,n))}};const Ae=new RegExp(/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/),Le=new RegExp(/^(normal|italic|initial|inherit|unset|(oblique( -?[0-9]?[0-9]deg)?))$/);function Re(t,e){const i=(""+t).match(Ae);if(!i||"normal"===i[1])return 1.2*e;switch(t=+i[2],i[3]){case"px":return t;case"%":t/=100}return e*t}function Ee(t,e){const i={},n=U(e),o=n?Object.keys(e):e,s=U(t)?n?i=>K(t[i],t[e[i]]):e=>t[e]:()=>t;for(const t of o)i[t]=+s(t)||0;return i}function ze(t){return Ee(t,{top:"y",right:"x",bottom:"y",left:"x"})}function Ie(t){return Ee(t,["topLeft","topRight","bottomLeft","bottomRight"])}function Fe(t){const e=ze(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function Be(t,e){t=t||{},e=e||xt.font;let i=K(t.size,e.size);"string"==typeof i&&(i=parseInt(i,10));let n=K(t.style,e.style);n&&!(""+n).match(Le)&&(console.warn('Invalid font style specified: "'+n+'"'),n="");const o={family:K(t.family,e.family),lineHeight:Re(K(t.lineHeight,e.lineHeight),i),size:i,style:n,weight:K(t.weight,e.weight),string:""};return o.string=$t(o),o}function Ve(t,e,i,n){let o,s,a,r=!0;for(o=0,s=t.length;ot.pos===e))}function je(t,e){return t.filter((t=>-1===Ne.indexOf(t.pos)&&t.box.axis===e))}function $e(t,e){return t.sort(((t,i)=>{const n=e?i:t,o=e?t:i;return n.weight===o.weight?n.index-o.index:n.weight-o.weight}))}function Ye(t,e,i,n){return Math.max(t[i],e[i])+Math.max(t[n],e[n])}function Ue(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right)}function Xe(t,e,i){const n=i.box,o=t.maxPadding;U(i.pos)||(i.size&&(t[i.pos]-=i.size),i.size=i.horizontal?n.height:n.width,t[i.pos]+=i.size),n.getPadding&&Ue(o,n.getPadding());const s=Math.max(0,e.outerWidth-Ye(o,t,"left","right")),a=Math.max(0,e.outerHeight-Ye(o,t,"top","bottom")),r=s!==t.w,l=a!==t.h;return t.w=s,t.h=a,i.horizontal?{same:r,other:l}:{same:l,other:r}}function qe(t,e){const i=e.maxPadding;function n(t){const n={left:0,top:0,right:0,bottom:0};return t.forEach((t=>{n[t]=Math.max(e[t],i[t])})),n}return n(t?["left","right"]:["top","bottom"])}function Ke(t,e,i){const n=[];let o,s,a,r,l,c;for(o=0,s=t.length,l=0;ot.box.fullSize)),!0),n=$e(He(e,"left"),!0),o=$e(He(e,"right")),s=$e(He(e,"top"),!0),a=$e(He(e,"bottom")),r=je(e,"x"),l=je(e,"y");return{fullSize:i,leftAndTop:n.concat(s),rightAndBottom:o.concat(l).concat(a).concat(r),chartArea:He(e,"chartArea"),vertical:n.concat(o).concat(l),horizontal:s.concat(a).concat(r)}}(t.boxes),l=r.vertical,c=r.horizontal;J(t.boxes,(t=>{"function"==typeof t.beforeLayout&&t.beforeLayout()}));const h=l.reduce(((t,e)=>e.box.options&&!1===e.box.options.display?t:t+1),0)||1,d=Object.freeze({outerWidth:e,outerHeight:i,padding:o,availableWidth:s,availableHeight:a,vBoxMaxWidth:s/2/h,hBoxMaxHeight:a/2}),u=Object.assign({},o);Ue(u,Fe(n));const f=Object.assign({maxPadding:u,w:s,h:a,x:o.left,y:o.top},o);!function(t,e){let i,n,o;for(i=0,n=t.length;i{const i=e.box;Object.assign(i,t.chartArea),i.update(f.w,f.h)}))}};class Qe{acquireContext(t,e){}releaseContext(t){return!1}addEventListener(t,e,i){}removeEventListener(t,e,i){}getDevicePixelRatio(){return 1}getMaximumSize(t,e,i,n){return e=Math.max(0,e||t.width),i=i||t.height,{width:e,height:Math.max(0,n?Math.floor(e/n):i)}}isAttached(t){return!0}}class Je extends Qe{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}}const ti={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},ei=t=>null===t||""===t;const ii=!!we&&{passive:!0};function ni(t,e,i){t.canvas.removeEventListener(e,i,ii)}function oi(t,e,i){const n=t.canvas,o=n&&ue(n)||n,s=new MutationObserver((t=>{const e=ue(o);t.forEach((t=>{for(let n=0;n{t.forEach((t=>{for(let e=0;e{i.currentDevicePixelRatio!==t&&e()})))}function ci(t,i,n){const o=t.canvas,s=o&&ue(o);if(!s)return;const a=e(((t,e)=>{const i=s.clientWidth;n(t,e),i{const e=t[0],i=e.contentRect.width,n=e.contentRect.height;0===i&&0===n||a(i,n)}));return r.observe(s),function(t,e){ai.size||window.addEventListener("resize",li),ai.set(t,e)}(t,a),r}function hi(t,e,i){i&&i.disconnect(),"resize"===e&&function(t){ai.delete(t),ai.size||window.removeEventListener("resize",li)}(t)}function di(t,i,n){const o=t.canvas,s=e((e=>{null!==t.ctx&&n(function(t,e){const i=ti[t.type]||t.type,{x:n,y:o}=be(t,e);return{type:i,chart:e,native:t,x:void 0!==n?n:null,y:void 0!==o?o:null}}(e,t))}),t,(t=>{const e=t[0];return[e,e.offsetX,e.offsetY]}));return function(t,e,i){t.addEventListener(e,i,ii)}(o,i,s),s}class ui extends Qe{acquireContext(t,e){const i=t&&t.getContext&&t.getContext("2d");return i&&i.canvas===t?(function(t,e){const i=t.style,n=t.getAttribute("height"),o=t.getAttribute("width");if(t.$chartjs={initial:{height:n,width:o,style:{display:i.display,height:i.height,width:i.width}}},i.display=i.display||"block",i.boxSizing=i.boxSizing||"border-box",ei(o)){const e=Me(t,"width");void 0!==e&&(t.width=e)}if(ei(n))if(""===t.style.height)t.height=t.width/(e||2);else{const e=Me(t,"height");void 0!==e&&(t.height=e)}}(t,e),i):null}releaseContext(t){const e=t.canvas;if(!e.$chartjs)return!1;const i=e.$chartjs.initial;["height","width"].forEach((t=>{const n=i[t];$(n)?e.removeAttribute(t):e.setAttribute(t,n)}));const n=i.style||{};return Object.keys(n).forEach((t=>{e.style[t]=n[t]})),e.width=e.width,delete e.$chartjs,!0}addEventListener(t,e,i){this.removeEventListener(t,e);const n=t.$proxies||(t.$proxies={}),o={attach:oi,detach:si,resize:ci}[e]||di;n[e]=o(t,e,i)}removeEventListener(t,e){const i=t.$proxies||(t.$proxies={}),n=i[e];if(!n)return;({attach:hi,detach:hi,resize:hi}[e]||ni)(t,e,n),i[e]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,e,i,n){return ye(t,e,i,n)}isAttached(t){const e=ue(t);return!(!e||!ue(e))}}var fi=Object.freeze({__proto__:null,BasePlatform:Qe,BasicPlatform:Je,DomPlatform:ui});const gi=t=>0===t||1===t,pi=(t,e,i)=>-Math.pow(2,10*(t-=1))*Math.sin((t-e)*_t/i),mi=(t,e,i)=>Math.pow(2,-10*t)*Math.sin((t-e)*_t/i)+1,xi={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>1-Math.cos(t*Mt),easeOutSine:t=>Math.sin(t*Mt),easeInOutSine:t=>-.5*(Math.cos(bt*t)-1),easeInExpo:t=>0===t?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>gi(t)?t:t<.5?.5*Math.pow(2,10*(2*t-1)):.5*(2-Math.pow(2,-10*(2*t-1))),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>gi(t)?t:pi(t,.075,.3),easeOutElastic:t=>gi(t)?t:mi(t,.075,.3),easeInOutElastic(t){const e=.1125;return gi(t)?t:t<.5?.5*pi(2*t,e,.45):.5+.5*mi(2*t-1,e,.45)},easeInBack(t){const e=1.70158;return t*t*((e+1)*t-e)},easeOutBack(t){const e=1.70158;return(t-=1)*t*((e+1)*t+e)+1},easeInOutBack(t){let e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},easeInBounce:t=>1-xi.easeOutBounce(1-t),easeOutBounce(t){const e=7.5625,i=2.75;return t<1/i?e*t*t:t<2/i?e*(t-=1.5/i)*t+.75:t<2.5/i?e*(t-=2.25/i)*t+.9375:e*(t-=2.625/i)*t+.984375},easeInOutBounce:t=>t<.5?.5*xi.easeInBounce(2*t):.5*xi.easeOutBounce(2*t-1)+.5},bi="transparent",_i={boolean:(t,e,i)=>i>.5?e:t,color(t,e,i){const n=W(t||bi),o=n.valid&&W(e||bi);return o&&o.valid?o.mix(n,i).hexString():e},number:(t,e,i)=>t+(e-t)*i};class yi{constructor(t,e,i,n){const o=e[i];n=Ve([t.to,n,o,t.from]);const s=Ve([t.from,o,n]);this._active=!0,this._fn=t.fn||_i[t.type||typeof s],this._easing=xi[t.easing]||xi.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=e,this._prop=i,this._from=s,this._to=n,this._promises=void 0}active(){return this._active}update(t,e,i){const n=this;if(n._active){n._notify(!1);const o=n._target[n._prop],s=i-n._start,a=n._duration-s;n._start=i,n._duration=Math.floor(Math.max(a,t.duration)),n._total+=s,n._loop=!!t.loop,n._to=Ve([t.to,e,o,t.from]),n._from=Ve([t.from,o,e])}}cancel(){const t=this;t._active&&(t.tick(Date.now()),t._active=!1,t._notify(!1))}tick(t){const e=this,i=t-e._start,n=e._duration,o=e._prop,s=e._from,a=e._loop,r=e._to;let l;if(e._active=s!==r&&(a||i1?2-l:l,l=e._easing(Math.min(1,Math.max(0,l))),e._target[o]=e._fn(s,r,l))}wait(){const t=this._promises||(this._promises=[]);return new Promise(((e,i)=>{t.push({res:e,rej:i})}))}_notify(t){const e=t?"res":"rej",i=this._promises||[];for(let t=0;t"onProgress"!==t&&"onComplete"!==t&&"fn"!==t}),xt.set("animations",{colors:{type:"color",properties:["color","borderColor","backgroundColor"]},numbers:{type:"number",properties:["x","y","borderWidth","radius","tension"]}}),xt.describe("animations",{_fallback:"animation"}),xt.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>0|t}}}});class wi{constructor(t,e){this._chart=t,this._properties=new Map,this.configure(e)}configure(t){if(!U(t))return;const e=this._properties;Object.getOwnPropertyNames(t).forEach((i=>{const n=t[i];if(!U(n))return;const o={};for(const t of vi)o[t]=n[t];(Y(n.properties)&&n.properties||[i]).forEach((t=>{t!==i&&e.has(t)||e.set(t,o)}))}))}_animateOptions(t,e){const i=e.options,n=function(t,e){if(!e)return;let i=t.options;if(!i)return void(t.options=e);i.$shared&&(t.options=i=Object.assign({},i,{$shared:!1,$animations:{}}));return i}(t,i);if(!n)return[];const o=this._createAnimations(n,i);return i.$shared&&function(t,e){const i=[],n=Object.keys(e);for(let e=0;e{t.options=i}),(()=>{})),o}_createAnimations(t,e){const i=this._properties,n=[],o=t.$animations||(t.$animations={}),s=Object.keys(e),a=Date.now();let r;for(r=s.length-1;r>=0;--r){const l=s[r];if("$"===l.charAt(0))continue;if("options"===l){n.push(...this._animateOptions(t,e));continue}const c=e[l];let h=o[l];const d=i.get(l);if(h){if(d&&h.active()){h.update(d,c,a);continue}h.cancel()}d&&d.duration?(o[l]=h=new yi(d,t,l,c),n.push(h)):t[l]=c}return n}update(t,e){if(0===this._properties.size)return void Object.assign(t,e);const i=this._createAnimations(t,e);return i.length?(a.add(this._chart,i),!0):void 0}}function Mi(t,e){const i=t&&t.options||{},n=i.reverse,o=void 0===i.min?e:0,s=void 0===i.max?e:0;return{start:n?s:o,end:n?o:s}}function ki(t,e){const i=[],n=t._getSortedDatasetMetas(e);let o,s;for(o=0,s=n.length;o0||!i&&e<0)return n.index}return null}function Oi(t,e){const{chart:i,_cachedMeta:n}=t,o=i._stacks||(i._stacks={}),{iScale:s,vScale:a,index:r}=n,l=s.axis,c=a.axis,h=function(t,e,i){return`${t.id}.${e.id}.${i.stack||i.type}`}(s,a,n),d=e.length;let u;for(let t=0;ti[t].axis===e)).shift()}function Ai(t,e){const i=t.vScale&&t.vScale.axis;if(i){e=e||t._parsed;for(const n of e){const e=n._stacks;if(!e||void 0===e[i]||void 0===e[i][t.index])return;delete e[i][t.index]}}}const Li=t=>"reset"===t||"none"===t,Ri=(t,e)=>e?t:Object.assign({},t);class Ei{constructor(t,e){this.chart=t,this._ctx=t.ctx,this.index=e,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.$context=void 0,this._syncList=[],this.initialize()}initialize(){const t=this,e=t._cachedMeta;t.configure(),t.linkScales(),e._stacked=Pi(e.vScale,e),t.addElements()}updateIndex(t){this.index!==t&&Ai(this._cachedMeta),this.index=t}linkScales(){const t=this,e=t.chart,i=t._cachedMeta,n=t.getDataset(),o=(t,e,i,n)=>"x"===t?e:"r"===t?n:i,s=i.xAxisID=K(n.xAxisID,Ti(e,"x")),a=i.yAxisID=K(n.yAxisID,Ti(e,"y")),r=i.rAxisID=K(n.rAxisID,Ti(e,"r")),l=i.indexAxis,c=i.iAxisID=o(l,s,a,r),h=i.vAxisID=o(l,a,s,r);i.xScale=t.getScaleForId(s),i.yScale=t.getScaleForId(a),i.rScale=t.getScaleForId(r),i.iScale=t.getScaleForId(c),i.vScale=t.getScaleForId(h)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const e=this._cachedMeta;return t===e.iScale?e.vScale:e.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&he(this._data,this),t._stacked&&Ai(t)}_dataCheck(){const t=this,e=t.getDataset(),i=e.data||(e.data=[]),n=t._data;if(U(i))t._data=function(t){const e=Object.keys(t),i=new Array(e.length);let n,o,s;for(n=0,o=e.length;n0&&n._parsed[t-1];if(!1===i._parsing)n._parsed=o,n._sorted=!0,h=o;else{h=Y(o[t])?i.parseArrayData(n,o,t,e):U(o[t])?i.parseObjectData(n,o,t,e):i.parsePrimitiveData(n,o,t,e);const s=()=>null===c[r]||u&&c[r]p||d=0;--u)if(!m()){i.updateRangeFromParsed(c,t,g,l);break}return c}getAllParsedValues(t){const e=this._cachedMeta._parsed,i=[];let n,o,s;for(n=0,o=e.length;n=0&&tn.getContext(i,o)),d);return g.$shared&&(g.$shared=l,s[a]=Object.freeze(Ri(g,l))),g}_resolveAnimations(t,e,i){const n=this,o=n.chart,s=n._cachedDataOpts,a=`animation-${e}`,r=s[a];if(r)return r;let l;if(!1!==o.options.animation){const o=n.chart.config,s=o.datasetAnimationScopeKeys(n._type,e),a=o.getOptionScopes(n.getDataset(),s);l=o.createResolver(a,n.getContext(t,i,e))}const c=new wi(o,l&&l.animations);return l&&l._cacheable&&(s[a]=Object.freeze(c)),c}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,e){return!e||Li(t)||this.chart._animationsDisabled}updateElement(t,e,i,n){Li(n)?Object.assign(t,i):this._resolveAnimations(e,n).update(t,i)}updateSharedOptions(t,e,i){t&&!Li(e)&&this._resolveAnimations(void 0,e).update(t,i)}_setStyle(t,e,i,n){t.active=n;const o=this.getStyle(e,n);this._resolveAnimations(e,i,n).update(t,{options:!n&&this.getSharedOptions(o)||o})}removeHoverStyle(t,e,i){this._setStyle(t,i,"active",!1)}setHoverStyle(t,e,i){this._setStyle(t,i,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const e=this,i=e._data,n=e._cachedMeta.data;for(const[t,i,n]of e._syncList)e[t](i,n);e._syncList=[];const o=n.length,s=i.length,a=Math.min(s,o);a&&e.parse(0,a),s>o?e._insertElements(o,s-o,t):s{for(t.length+=e,r=t.length-1;r>=a;r--)t[r]=t[r-e]};for(l(s),r=t;r{o[t]=n[t]&&n[t].active()?n[t]._to:i[t]})),o}}zi.defaults={},zi.defaultRoutes=void 0;const Ii=new Map;function Fi(t,e,i){return function(t,e){e=e||{};const i=t+JSON.stringify(e);let n=Ii.get(i);return n||(n=new Intl.NumberFormat(t,e),Ii.set(i,n)),n}(e,i).format(t)}const Bi={values:t=>Y(t)?t:""+t,numeric(t,e,i){if(0===t)return"0";const n=this.chart.options.locale;let o,s=t;if(i.length>1){const e=Math.max(Math.abs(i[0].value),Math.abs(i[i.length-1].value));(e<1e-4||e>1e15)&&(o="scientific"),s=function(t,e){let i=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;Math.abs(i)>=1&&t!==Math.floor(t)&&(i=t-Math.floor(t));return i}(t,i)}const a=Pt(Math.abs(s)),r=Math.max(Math.min(-1*Math.floor(a),20),0),l={notation:o,minimumFractionDigits:r,maximumFractionDigits:r};return Object.assign(l,this.options.ticks.format),Fi(t,n,l)},logarithmic(t,e,i){if(0===t)return"0";const n=t/Math.pow(10,Math.floor(Pt(t)));return 1===n||2===n||5===n?Bi.numeric.call(this,t,e,i):""}};var Vi={formatters:Bi};function Wi(t,e){const i=t.options.ticks,n=i.maxTicksLimit||function(t){const e=t.options.offset,i=t._tickSize(),n=t._length/i+(e?0:1),o=t._maxLength/i;return Math.floor(Math.min(n,o))}(t),o=i.major.enabled?function(t){const e=[];let i,n;for(i=0,n=t.length;in)return function(t,e,i,n){let o,s=0,a=i[0];for(n=Math.ceil(n),o=0;oo)return e}return Math.max(o,1)}(o,e,n);if(s>0){let t,i;const n=s>1?Math.round((r-a)/(s-1)):null;for(Ni(e,l,c,$(n)?0:a-n,a),t=0,i=s-1;te.lineWidth,tickColor:(t,e)=>e.color,offset:!1,borderDash:[],borderDashOffset:0,borderWidth:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:Vi.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),xt.route("scale.ticks","color","","color"),xt.route("scale.grid","color","","borderColor"),xt.route("scale.grid","borderColor","","borderColor"),xt.route("scale.title","color","","color"),xt.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&"callback"!==t&&"parser"!==t,_indexable:t=>"borderDash"!==t&&"tickBorderDash"!==t}),xt.describe("scales",{_fallback:"scale"}),xt.describe("scale.ticks",{_scriptable:t=>"backdropPadding"!==t&&"callback"!==t,_indexable:t=>"backdropPadding"!==t});const Hi=(t,e,i)=>"top"===e||"left"===e?t[e]+i:t[e]-i;function ji(t,e){const i=[],n=t.length/e,o=t.length;let s=0;for(;sa+r)))return c}function Yi(t){return t.drawTicks?t.tickLength:0}function Ui(t,e){if(!t.display)return 0;const i=Be(t.font,e),n=Fe(t.padding);return(Y(t.text)?t.text.length:1)*i.lineHeight+n.height}function Xi(t,e,i){let o=n(t);return(i&&"right"!==e||!i&&"right"===e)&&(o=(t=>"left"===t?"right":"right"===t?"left":t)(o)),o}class qi extends zi{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){const e=this;e.options=t.setContext(e.getContext()),e.axis=t.axis,e._userMin=e.parse(t.min),e._userMax=e.parse(t.max),e._suggestedMin=e.parse(t.suggestedMin),e._suggestedMax=e.parse(t.suggestedMax)}parse(t,e){return t}getUserBounds(){let{_userMin:t,_userMax:e,_suggestedMin:i,_suggestedMax:n}=this;return t=q(t,Number.POSITIVE_INFINITY),e=q(e,Number.NEGATIVE_INFINITY),i=q(i,Number.POSITIVE_INFINITY),n=q(n,Number.NEGATIVE_INFINITY),{min:q(t,i),max:q(e,n),minDefined:X(t),maxDefined:X(e)}}getMinMax(t){const e=this;let i,{min:n,max:o,minDefined:s,maxDefined:a}=e.getUserBounds();if(s&&a)return{min:n,max:o};const r=e.getMatchingVisibleMetas();for(let l=0,c=r.length;l=s||n<=1||!t.isHorizontal())return void(t.labelRotation=o);const h=t._getLabelSizes(),d=h.widest.width,u=h.highest.height,f=Ht(t.chart.width-d,0,t.maxWidth);a=e.offset?t.maxWidth/n:f/(n-1),d+6>a&&(a=f/(n-(e.offset?.5:1)),r=t.maxHeight-Yi(e.grid)-i.padding-Ui(e.title,t.chart.options.font),l=Math.sqrt(d*d+u*u),c=zt(Math.min(Math.asin(Math.min((h.highest.height+6)/a,1)),Math.asin(Math.min(r/l,1))-Math.asin(u/l))),c=Math.max(o,Math.min(s,c))),t.labelRotation=c}afterCalculateLabelRotation(){Q(this.options.afterCalculateLabelRotation,[this])}beforeFit(){Q(this.options.beforeFit,[this])}fit(){const t=this,e={width:0,height:0},{chart:i,options:{ticks:n,title:o,grid:s}}=t,a=t._isVisible(),r=t.isHorizontal();if(a){const a=Ui(o,i.options.font);if(r?(e.width=t.maxWidth,e.height=Yi(s)+a):(e.height=t.maxHeight,e.width=Yi(s)+a),n.display&&t.ticks.length){const{first:i,last:o,widest:s,highest:a}=t._getLabelSizes(),l=2*n.padding,c=Et(t.labelRotation),h=Math.cos(c),d=Math.sin(c);if(r){const i=n.mirror?0:d*s.width+h*a.height;e.height=Math.min(t.maxHeight,e.height+i+l)}else{const i=n.mirror?0:h*s.width+d*a.height;e.width=Math.min(t.maxWidth,e.width+i+l)}t._calculatePadding(i,o,d,h)}}t._handleMargins(),r?(t.width=t._length=i.width-t._margins.left-t._margins.right,t.height=e.height):(t.width=e.width,t.height=t._length=i.height-t._margins.top-t._margins.bottom)}_calculatePadding(t,e,i,n){const o=this,{ticks:{align:s,padding:a},position:r}=o.options,l=0!==o.labelRotation,c="top"!==r&&"x"===o.axis;if(o.isHorizontal()){const r=o.getPixelForTick(0)-o.left,h=o.right-o.getPixelForTick(o.ticks.length-1);let d=0,u=0;l?c?(d=n*t.width,u=i*e.height):(d=i*t.height,u=n*e.width):"start"===s?u=e.width:"end"===s?d=t.width:(d=t.width/2,u=e.width/2),o.paddingLeft=Math.max((d-r+a)*o.width/(o.width-r),0),o.paddingRight=Math.max((u-h+a)*o.width/(o.width-h),0)}else{let i=e.height/2,n=t.height/2;"start"===s?(i=0,n=t.height):"end"===s&&(i=e.height,n=0),o.paddingTop=i+a,o.paddingBottom=n+a}}_handleMargins(){const t=this;t._margins&&(t._margins.left=Math.max(t.paddingLeft,t._margins.left),t._margins.top=Math.max(t.paddingTop,t._margins.top),t._margins.right=Math.max(t.paddingRight,t._margins.right),t._margins.bottom=Math.max(t.paddingBottom,t._margins.bottom))}afterFit(){Q(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:e}=this.options;return"top"===e||"bottom"===e||"x"===t}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){const e=this;let i,n;for(e.beforeTickToLabelConversion(),e.generateTickLabels(t),i=0,n=t.length;i{const i=t.gc,n=i.length/2;let o;if(n>e){for(o=0;o({width:o[t]||0,height:s[t]||0});return{first:v(0),last:v(e-1),widest:v(_),highest:v(y),widths:o,heights:s}}getLabelForValue(t){return t}getPixelForValue(t,e){return NaN}getValueForPixel(t){}getPixelForTick(t){const e=this.ticks;return t<0||t>e.length-1?null:this.getPixelForValue(e[t].value)}getPixelForDecimal(t){const e=this;e._reversePixels&&(t=1-t);const i=e._startPixel+t*e._length;return jt(e._alignToPixels?Xt(e.chart,i,0):i)}getDecimalForPixel(t){const e=(t-this._startPixel)/this._length;return this._reversePixels?1-e:e}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:e}=this;return t<0&&e<0?e:t>0&&e>0?t:0}getContext(t){const e=this,i=e.ticks||[];if(t>=0&&tr*o?r/n:l/o:l*o0}_computeGridLineItems(t){const e=this,i=e.axis,n=e.chart,o=e.options,{grid:s,position:a}=o,r=s.offset,l=e.isHorizontal(),c=e.ticks.length+(r?1:0),h=Yi(s),d=[],u=s.setContext(e.getContext()),f=u.drawBorder?u.borderWidth:0,g=f/2,p=function(t){return Xt(n,t,f)};let m,x,b,_,y,v,w,M,k,S,P,D;if("top"===a)m=p(e.bottom),v=e.bottom-h,M=m-g,S=p(t.top)+g,D=t.bottom;else if("bottom"===a)m=p(e.top),S=t.top,D=p(t.bottom)-g,v=m+g,M=e.top+h;else if("left"===a)m=p(e.right),y=e.right-h,w=m-g,k=p(t.left)+g,P=t.right;else if("right"===a)m=p(e.left),k=t.left,P=p(t.right)-g,y=m+g,w=e.left+h;else if("x"===i){if("center"===a)m=p((t.top+t.bottom)/2+.5);else if(U(a)){const t=Object.keys(a)[0],i=a[t];m=p(e.chart.scales[t].getPixelForValue(i))}S=t.top,D=t.bottom,v=m+g,M=v+h}else if("y"===i){if("center"===a)m=p((t.left+t.right)/2);else if(U(a)){const t=Object.keys(a)[0],i=a[t];m=p(e.chart.scales[t].getPixelForValue(i))}y=m-g,w=y-h,k=t.left,P=t.right}const C=K(o.ticks.maxTicksLimit,c),O=Math.max(1,Math.ceil(c/C));for(x=0;xe.value===t));if(n>=0){return i.setContext(e.getContext(n)).lineWidth}return 0}drawGrid(t){const e=this,i=e.options.grid,n=e.ctx,o=e._gridLineItems||(e._gridLineItems=e._computeGridLineItems(t));let s,a;const r=(t,e,i)=>{i.width&&i.color&&(n.save(),n.lineWidth=i.width,n.strokeStyle=i.color,n.setLineDash(i.borderDash||[]),n.lineDashOffset=i.borderDashOffset,n.beginPath(),n.moveTo(t.x,t.y),n.lineTo(e.x,e.y),n.stroke(),n.restore())};if(i.display)for(s=0,a=o.length;st[0])){ht(n)||(n=rn("_fallback",t));const s={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:i,_fallback:n,_getTarget:o,override:o=>Ki([o,...t],e,i,n)};return new Proxy(s,{deleteProperty:(e,i)=>(delete e[i],delete e._keys,delete t[0][i],!0),get:(i,n)=>tn(i,n,(()=>function(t,e,i,n){let o;for(const s of e)if(o=rn(Qi(s,t),i),ht(o))return Ji(t,o)?sn(i,n,t,o):o}(n,e,t,i))),getOwnPropertyDescriptor:(t,e)=>Reflect.getOwnPropertyDescriptor(t._scopes[0],e),getPrototypeOf:()=>Reflect.getPrototypeOf(t[0]),has:(t,e)=>ln(t).includes(e),ownKeys:t=>ln(t),set:(t,e,i)=>((t._storage||(t._storage=o()))[e]=i,delete t[e],delete t._keys,!0)})}function Gi(t,e,i,n){const o={_cacheable:!1,_proxy:t,_context:e,_subProxy:i,_stack:new Set,_descriptors:Zi(t,n),setContext:e=>Gi(t,e,i,n),override:o=>Gi(t.override(o),e,i,n)};return new Proxy(o,{deleteProperty:(e,i)=>(delete e[i],delete t[i],!0),get:(t,e,i)=>tn(t,e,(()=>function(t,e,i){const{_proxy:n,_context:o,_subProxy:s,_descriptors:a}=t;let r=n[e];dt(r)&&a.isScriptable(e)&&(r=function(t,e,i,n){const{_proxy:o,_context:s,_subProxy:a,_stack:r}=i;if(r.has(t))throw new Error("Recursion detected: "+Array.from(r).join("->")+"->"+t);r.add(t),e=e(s,a||n),r.delete(t),U(e)&&(e=sn(o._scopes,o,t,e));return e}(e,r,t,i));Y(r)&&r.length&&(r=function(t,e,i,n){const{_proxy:o,_context:s,_subProxy:a,_descriptors:r}=i;if(ht(s.index)&&n(t))e=e[s.index%e.length];else if(U(e[0])){const i=e,n=o._scopes.filter((t=>t!==i));e=[];for(const l of i){const i=sn(n,o,t,l);e.push(Gi(i,s,a&&a[t],r))}}return e}(e,r,t,a.isIndexable));Ji(e,r)&&(r=Gi(r,o,s&&s[e],a));return r}(t,e,i))),getOwnPropertyDescriptor:(e,i)=>e._descriptors.allKeys?Reflect.has(t,i)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,i),getPrototypeOf:()=>Reflect.getPrototypeOf(t),has:(e,i)=>Reflect.has(t,i),ownKeys:()=>Reflect.ownKeys(t),set:(e,i,n)=>(t[i]=n,delete e[i],!0)})}function Zi(t,e={scriptable:!0,indexable:!0}){const{_scriptable:i=e.scriptable,_indexable:n=e.indexable,_allKeys:o=e.allKeys}=t;return{allKeys:o,scriptable:i,indexable:n,isScriptable:dt(i)?i:()=>i,isIndexable:dt(n)?n:()=>n}}const Qi=(t,e)=>t?t+ct(e):e,Ji=(t,e)=>U(e)&&"adapters"!==t;function tn(t,e,i){let n=t[e];return ht(n)||(n=i(),ht(n)&&(t[e]=n)),n}function en(t,e,i){return dt(t)?t(e,i):t}const nn=(t,e)=>!0===t?e:"string"==typeof t?lt(e,t):void 0;function on(t,e,i,n){for(const o of e){const e=nn(i,o);if(e){t.add(e);const o=en(e._fallback,i,e);if(ht(o)&&o!==i&&o!==n)return o}else if(!1===e&&ht(n)&&i!==n)return null}return!1}function sn(t,e,i,n){const o=e._rootScopes,s=en(e._fallback,i,n),a=[...t,...o],r=new Set;r.add(n);let l=an(r,a,i,s||i);return null!==l&&((!ht(s)||s===i||(l=an(r,a,s,l),null!==l))&&Ki(Array.from(r),[""],o,s,(()=>function(t,e,i){const n=t._getTarget();e in n||(n[e]={});const o=n[e];if(Y(o)&&U(i))return i;return o}(e,i,n))))}function an(t,e,i,n){for(;i;)i=on(t,e,i,n);return i}function rn(t,e){for(const i of e){if(!i)continue;const e=i[t];if(ht(e))return e}}function ln(t){let e=t._keys;return e||(e=t._keys=function(t){const e=new Set;for(const i of t)for(const t of Object.keys(i).filter((t=>!t.startsWith("_"))))e.add(t);return Array.from(e)}(t._scopes)),e}const cn=Number.EPSILON||1e-14,hn=(t,e)=>e"x"===t?"y":"x";function un(t,e,i,n){const o=t.skip?e:t,s=e,a=i.skip?e:i,r=Bt(s,o),l=Bt(a,s);let c=r/(r+l),h=l/(r+l);c=isNaN(c)?0:c,h=isNaN(h)?0:h;const d=n*c,u=n*h;return{previous:{x:s.x-d*(a.x-o.x),y:s.y-d*(a.y-o.y)},next:{x:s.x+u*(a.x-o.x),y:s.y+u*(a.y-o.y)}}}function fn(t,e="x"){const i=dn(e),n=t.length,o=Array(n).fill(0),s=Array(n);let a,r,l,c=hn(t,0);for(a=0;a!t.skip))),"monotone"===e.cubicInterpolationMode)fn(t,o);else{let i=n?t[t.length-1]:t[0];for(s=0,a=t.length;s0?e.y:t.y}}function bn(t,e,i,n){const o={x:t.cp2x,y:t.cp2y},s={x:e.cp1x,y:e.cp1y},a=mn(t,o,i),r=mn(o,s,i),l=mn(s,e,i),c=mn(a,r,i),h=mn(r,l,i);return mn(c,h,i)}function _n(t,e,i){return t?function(t,e){return{x:i=>t+t+e-i,setWidth(t){e=t},textAlign:t=>"center"===t?t:"right"===t?"left":"right",xPlus:(t,e)=>t-e,leftForLtr:(t,e)=>t-e}}(e,i):{x:t=>t,setWidth(t){},textAlign:t=>t,xPlus:(t,e)=>t+e,leftForLtr:(t,e)=>t}}function yn(t,e){let i,n;"ltr"!==e&&"rtl"!==e||(i=t.canvas.style,n=[i.getPropertyValue("direction"),i.getPropertyPriority("direction")],i.setProperty("direction",e,"important"),t.prevTextDirection=n)}function vn(t,e){void 0!==e&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}function wn(t){return"angle"===t?{between:Nt,compare:Vt,normalize:Wt}:{between:(t,e,i)=>t>=Math.min(e,i)&&t<=Math.max(i,e),compare:(t,e)=>t-e,normalize:t=>t}}function Mn({start:t,end:e,count:i,loop:n,style:o}){return{start:t%i,end:e%i,loop:n&&(e-t+1)%i==0,style:o}}function kn(t,e,i){if(!i)return[t];const{property:n,start:o,end:s}=i,a=e.length,{compare:r,between:l,normalize:c}=wn(n),{start:h,end:d,loop:u,style:f}=function(t,e,i){const{property:n,start:o,end:s}=i,{between:a,normalize:r}=wn(n),l=e.length;let c,h,{start:d,end:u,loop:f}=t;if(f){for(d+=l,u+=l,c=0,h=l;cb||l(o,x,p)&&0!==r(o,x),v=()=>!b||0===r(s,p)||l(s,x,p);for(let t=h,i=h;t<=d;++t)m=e[t%a],m.skip||(p=c(m[n]),p!==x&&(b=l(p,o,s),null===_&&y()&&(_=0===r(p,o)?t:i),null!==_&&v()&&(g.push(Mn({start:_,end:t,loop:u,count:a,style:f})),_=null),i=t,x=p));return null!==_&&g.push(Mn({start:_,end:d,loop:u,count:a,style:f})),g}function Sn(t,e){const i=[],n=t.segments;for(let o=0;oo&&t[s%e].skip;)s--;return s%=e,{start:o,end:s}}(i,o,s,n);if(!0===n)return Dn([{start:a,end:r,loop:s}],i,e);return Dn(function(t,e,i,n){const o=t.length,s=[];let a,r=e,l=t[e];for(a=e+1;a<=i;++a){const i=t[a%o];i.skip||i.stop?l.skip||(n=!1,s.push({start:e%o,end:(a-1)%o,loop:n}),e=r=i.stop?a:null):(r=a,l.skip&&(e=a)),l=i}return null!==r&&s.push({start:e%o,end:r%o,loop:n}),s}(i,a,r{const n=i.split("."),o=n.pop(),s=[t].concat(n).join("."),a=e[i].split("."),r=a.pop(),l=a.join(".");xt.route(s,o,l,r)}))}(e,t.defaultRoutes);t.descriptors&&xt.describe(e,t.descriptors)}(t,a,n),e.override&&xt.override(t.id,t.overrides)),a}get(t){return this.items[t]}unregister(t){const e=this.items,i=t.id,n=this.scope;i in e&&delete e[i],n&&i in xt[n]&&(delete xt[n][i],this.override&&delete ft[i])}}var Ln=new class{constructor(){this.controllers=new An(Ei,"datasets",!0),this.elements=new An(zi,"elements"),this.plugins=new An(Object,"plugins"),this.scales=new An(qi,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,e,i){const n=this;[...e].forEach((e=>{const o=i||n._getRegistryForType(e);i||o.isForType(e)||o===n.plugins&&e.id?n._exec(t,o,e):J(e,(e=>{const o=i||n._getRegistryForType(e);n._exec(t,o,e)}))}))}_exec(t,e,i){const n=ct(t);Q(i["before"+n],[],i),e[t](i),Q(i["after"+n],[],i)}_getRegistryForType(t){for(let e=0;et.filter((t=>!e.some((e=>t.plugin.id===e.plugin.id))));this._notify(n(e,i),t,"stop"),this._notify(n(i,e),t,"start")}}function En(t,e){return e||!1!==t?!0===t?{}:t:null}function zn(t,e,i,n){const o=t.pluginScopeKeys(e),s=t.getOptionScopes(i,o);return t.createResolver(s,n,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function In(t,e){const i=xt.datasets[t]||{};return((e.datasets||{})[t]||{}).indexAxis||e.indexAxis||i.indexAxis||"x"}function Fn(t,e){return"x"===t||"y"===t?t:e.axis||("top"===(i=e.position)||"bottom"===i?"x":"left"===i||"right"===i?"y":void 0)||t.charAt(0).toLowerCase();var i}function Bn(t){const e=t.options||(t.options={});e.plugins=K(e.plugins,{}),e.scales=function(t,e){const i=ft[t.type]||{scales:{}},n=e.scales||{},o=In(t.type,e),s=Object.create(null),a=Object.create(null);return Object.keys(n).forEach((t=>{const e=n[t],r=Fn(t,e),l=function(t,e){return t===e?"_index_":"_value_"}(r,o),c=i.scales||{};s[r]=s[r]||t,a[t]=st(Object.create(null),[{axis:r},e,c[r],c[l]])})),t.data.datasets.forEach((i=>{const o=i.type||t.type,r=i.indexAxis||In(o,e),l=(ft[o]||{}).scales||{};Object.keys(l).forEach((t=>{const e=function(t,e){let i=t;return"_index_"===t?i=e:"_value_"===t&&(i="x"===e?"y":"x"),i}(t,r),o=i[e+"AxisID"]||s[e]||e;a[o]=a[o]||Object.create(null),st(a[o],[{axis:e},n[o],l[t]])}))})),Object.keys(a).forEach((t=>{const e=a[t];st(e,[xt.scales[e.type],xt.scale])})),a}(t,e)}function Vn(t){return(t=t||{}).datasets=t.datasets||[],t.labels=t.labels||[],t}const Wn=new Map,Nn=new Set;function Hn(t,e){let i=Wn.get(t);return i||(i=e(),Wn.set(t,i),Nn.add(i)),i}const jn=(t,e,i)=>{const n=lt(e,i);void 0!==n&&t.add(n)};class $n{constructor(t){this._config=function(t){return(t=t||{}).data=Vn(t.data),Bn(t),t}(t),this._scopeCache=new Map,this._resolverCache=new Map}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=Vn(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),Bn(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return Hn(t,(()=>[[`datasets.${t}`,""]]))}datasetAnimationScopeKeys(t,e){return Hn(`${t}.transition.${e}`,(()=>[[`datasets.${t}.transitions.${e}`,`transitions.${e}`],[`datasets.${t}`,""]]))}datasetElementScopeKeys(t,e){return Hn(`${t}-${e}`,(()=>[[`datasets.${t}.elements.${e}`,`datasets.${t}`,`elements.${e}`,""]]))}pluginScopeKeys(t){const e=t.id;return Hn(`${this.type}-plugin-${e}`,(()=>[[`plugins.${e}`,...t.additionalOptionScopes||[]]]))}_cachedScopes(t,e){const i=this._scopeCache;let n=i.get(t);return n&&!e||(n=new Map,i.set(t,n)),n}getOptionScopes(t,e,i){const{options:n,type:o}=this,s=this._cachedScopes(t,i),a=s.get(e);if(a)return a;const r=new Set;e.forEach((e=>{t&&(r.add(t),e.forEach((e=>jn(r,t,e)))),e.forEach((t=>jn(r,n,t))),e.forEach((t=>jn(r,ft[o]||{},t))),e.forEach((t=>jn(r,xt,t))),e.forEach((t=>jn(r,gt,t)))}));const l=Array.from(r);return Nn.has(e)&&s.set(e,l),l}chartOptionScopes(){const{options:t,type:e}=this;return[t,ft[e]||{},xt.datasets[e]||{},{type:e},xt,gt]}resolveNamedOptions(t,e,i,n=[""]){const o={$shared:!0},{resolver:s,subPrefixes:a}=Yn(this._resolverCache,t,n);let r=s;if(function(t,e){const{isScriptable:i,isIndexable:n}=Zi(t);for(const o of e)if(i(o)&&dt(t[o])||n(o)&&Y(t[o]))return!0;return!1}(s,e)){o.$shared=!1;r=Gi(s,i=dt(i)?i():i,this.createResolver(t,i,a))}for(const t of e)o[t]=r[t];return o}createResolver(t,e,i=[""],n){const{resolver:o}=Yn(this._resolverCache,t,i);return U(e)?Gi(o,e,void 0,n):o}}function Yn(t,e,i){let n=t.get(e);n||(n=new Map,t.set(e,n));const o=i.join();let s=n.get(o);if(!s){s={resolver:Ki(e,i),subPrefixes:i.filter((t=>!t.toLowerCase().includes("hover")))},n.set(o,s)}return s}const Un=["top","bottom","left","right","chartArea"];function Xn(t,e){return"top"===t||"bottom"===t||-1===Un.indexOf(t)&&"x"===e}function qn(t,e){return function(i,n){return i[t]===n[t]?i[e]-n[e]:i[t]-n[t]}}function Kn(t){const e=t.chart,i=e.options.animation;e.notifyPlugins("afterRender"),Q(i&&i.onComplete,[t],e)}function Gn(t){const e=t.chart,i=e.options.animation;Q(i&&i.onProgress,[t],e)}function Zn(){return"undefined"!=typeof window&&"undefined"!=typeof document}function Qn(t){return Zn()&&"string"==typeof t?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}const Jn={},to=t=>{const e=Qn(t);return Object.values(Jn).filter((t=>t.canvas===e)).pop()};class eo{constructor(t,e){const n=this;this.config=e=new $n(e);const o=Qn(t),s=to(o);if(s)throw new Error("Canvas is already in use. Chart with ID '"+s.id+"' must be destroyed before the canvas can be reused.");const r=e.createResolver(e.chartOptionScopes(),n.getContext());this.platform=n._initializePlatform(o,e);const l=n.platform.acquireContext(o,r.aspectRatio),c=l&&l.canvas,h=c&&c.height,d=c&&c.width;this.id=j(),this.ctx=l,this.canvas=c,this.width=d,this.height=h,this._options=r,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this.scale=void 0,this._plugins=new Rn,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=i((()=>this.update("resize")),r.resizeDelay||0),Jn[n.id]=n,l&&c?(a.listen(n,"complete",Kn),a.listen(n,"progress",Gn),n._initialize(),n.attached&&n.update()):console.error("Failed to create chart: can't acquire context from the given item")}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:e},width:i,height:n,_aspectRatio:o}=this;return $(t)?e&&o?o:n?i/n:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}_initialize(){const t=this;return t.notifyPlugins("beforeInit"),t.options.responsive?t.resize():ve(t,t.options.devicePixelRatio),t.bindEvents(),t.notifyPlugins("afterInit"),t}_initializePlatform(t,e){return e.platform?new e.platform:!Zn()||"undefined"!=typeof OffscreenCanvas&&t instanceof OffscreenCanvas?new Je:new ui}clear(){return qt(this.canvas,this.ctx),this}stop(){return a.stop(this),this}resize(t,e){a.running(this)?this._resizeBeforeDraw={width:t,height:e}:this._resize(t,e)}_resize(t,e){const i=this,n=i.options,o=i.canvas,s=n.maintainAspectRatio&&i.aspectRatio,a=i.platform.getMaximumSize(o,t,e,s),r=n.devicePixelRatio||i.platform.getDevicePixelRatio();i.width=a.width,i.height=a.height,i._aspectRatio=i.aspectRatio,ve(i,r,!0)&&(i.notifyPlugins("resize",{size:a}),Q(n.onResize,[i,a],i),i.attached&&i._doResize()&&i.render())}ensureScalesHaveIDs(){J(this.options.scales||{},((t,e)=>{t.id=e}))}buildOrUpdateScales(){const t=this,e=t.options,i=e.scales,n=t.scales,o=Object.keys(n).reduce(((t,e)=>(t[e]=!1,t)),{});let s=[];i&&(s=s.concat(Object.keys(i).map((t=>{const e=i[t],n=Fn(t,e),o="r"===n,s="x"===n;return{options:e,dposition:o?"chartArea":s?"bottom":"left",dtype:o?"radialLinear":s?"category":"linear"}})))),J(s,(i=>{const s=i.options,a=s.id,r=Fn(a,s),l=K(s.type,i.dtype);void 0!==s.position&&Xn(s.position,r)===Xn(i.dposition)||(s.position=i.dposition),o[a]=!0;let c=null;if(a in n&&n[a].type===l)c=n[a];else{c=new(Ln.getScale(l))({id:a,type:l,ctx:t.ctx,chart:t}),n[c.id]=c}c.init(s,e)})),J(o,((t,e)=>{t||delete n[e]})),J(n,(e=>{Ze.configure(t,e,e.options),Ze.addBox(t,e)}))}_updateMetasets(){const t=this,e=t._metasets,i=t.data.datasets.length,n=e.length;if(e.sort(((t,e)=>t.index-e.index)),n>i){for(let e=i;ei.length&&delete t._stacks,e.forEach(((e,n)=>{0===i.filter((t=>t===e._dataset)).length&&t._destroyDatasetMeta(n)}))}buildOrUpdateControllers(){const t=this,e=[],i=t.data.datasets;let n,o;for(t._removeUnreferencedMetasets(),n=0,o=i.length;n{t.getDatasetMeta(i).controller.reset()}),t)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const e=this,i=e.config;i.update(),e._options=i.createResolver(i.chartOptionScopes(),e.getContext()),J(e.scales,(t=>{Ze.removeBox(e,t)}));const n=e._animationsDisabled=!e.options.animation;e.ensureScalesHaveIDs(),e.buildOrUpdateScales();const o=new Set(Object.keys(e._listeners)),s=new Set(e.options.events);if(ut(o,s)&&!!this._responsiveListeners===e.options.responsive||(e.unbindEvents(),e.bindEvents()),e._plugins.invalidate(),!1===e.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0}))return;const a=e.buildOrUpdateControllers();e.notifyPlugins("beforeElementsUpdate");let r=0;for(let t=0,i=e.data.datasets.length;t{t.reset()})),e._updateDatasets(t),e.notifyPlugins("afterUpdate",{mode:t}),e._layers.sort(qn("z","_idx")),e._lastEvent&&e._eventHandler(e._lastEvent,!0),e.render()}_updateLayout(t){const e=this;if(!1===e.notifyPlugins("beforeLayout",{cancelable:!0}))return;Ze.update(e,e.width,e.height,t);const i=e.chartArea,n=i.width<=0||i.height<=0;e._layers=[],J(e.boxes,(t=>{n&&"chartArea"===t.position||(t.configure&&t.configure(),e._layers.push(...t._layers()))}),e),e._layers.forEach(((t,e)=>{t._idx=e})),e.notifyPlugins("afterLayout")}_updateDatasets(t){const e=this,i="function"==typeof t;if(!1!==e.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})){for(let n=0,o=e.data.datasets.length;n=0;--i)t._drawDataset(e[i]);t.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const e=this,i=e.ctx,n=t._clip,o=!n.disabled,s=e.chartArea,a={meta:t,index:t.index,cancelable:!0};!1!==e.notifyPlugins("beforeDatasetDraw",a)&&(o&&Zt(i,{left:!1===n.left?0:s.left-n.left,right:!1===n.right?e.width:s.right+n.right,top:!1===n.top?0:s.top-n.top,bottom:!1===n.bottom?e.height:s.bottom+n.bottom}),t.controller.draw(),o&&Qt(i),a.cancelable=!1,e.notifyPlugins("afterDatasetDraw",a))}getElementsAtEventForMode(t,e,i,n){const o=Te.modes[e];return"function"==typeof o?o(this,t,i,n):[]}getDatasetMeta(t){const e=this.data.datasets[t],i=this._metasets;let n=i.filter((t=>t&&t._dataset===e)).pop();return n||(n={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:e&&e.order||0,index:t,_dataset:e,_parsed:[],_sorted:!1},i.push(n)),n}getContext(){return this.$context||(this.$context={chart:this,type:"chart"})}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const e=this.data.datasets[t];if(!e)return!1;const i=this.getDatasetMeta(t);return"boolean"==typeof i.hidden?!i.hidden:!e.hidden}setDatasetVisibility(t,e){this.getDatasetMeta(t).hidden=!e}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateDatasetVisibility(t,e){const i=this,n=e?"show":"hide",o=i.getDatasetMeta(t),s=o.controller._resolveAnimations(void 0,n);i.setDatasetVisibility(t,e),s.update(o,{visible:e}),i.update((e=>e.datasetIndex===t?n:void 0))}hide(t){this._updateDatasetVisibility(t,!1)}show(t){this._updateDatasetVisibility(t,!0)}_destroyDatasetMeta(t){const e=this,i=e._metasets&&e._metasets[t];i&&i.controller&&(i.controller._destroy(),delete e._metasets[t])}destroy(){const t=this,{canvas:e,ctx:i}=t;let n,o;for(t.stop(),a.remove(t),n=0,o=t.data.datasets.length;n((n,o)=>{i.addEventListener(t,n,o),e[n]=o})(o,n)))}bindResponsiveEvents(){const t=this;t._responsiveListeners||(t._responsiveListeners={});const e=t._responsiveListeners,i=t.platform,n=(n,o)=>{i.addEventListener(t,n,o),e[n]=o},o=(n,o)=>{e[n]&&(i.removeEventListener(t,n,o),delete e[n])},s=(e,i)=>{t.canvas&&t.resize(e,i)};let a;const r=()=>{o("attach",r),t.attached=!0,t.resize(),n("resize",s),n("detach",a)};a=()=>{t.attached=!1,o("resize",s),n("attach",r)},i.isAttached(t.canvas)?r():a()}unbindEvents(){const t=this;J(t._listeners,((e,i)=>{t.platform.removeEventListener(t,i,e)})),t._listeners={},J(t._responsiveListeners,((e,i)=>{t.platform.removeEventListener(t,i,e)})),t._responsiveListeners=void 0}updateHoverStyle(t,e,i){const n=i?"set":"remove";let o,s,a,r;for("dataset"===e&&(o=this.getDatasetMeta(t[0].datasetIndex),o.controller["_"+n+"DatasetHoverStyle"]()),a=0,r=t.length;a{const n=e.getDatasetMeta(t);if(!n)throw new Error("No dataset found at index "+t);return{datasetIndex:t,element:n.data[i],index:i}}));!tt(n,i)&&(e._active=n,e._updateHoverStyles(n,i))}notifyPlugins(t,e,i){return this._plugins.notify(this,t,e,i)}_updateHoverStyles(t,e,i){const n=this,o=n.options.hover,s=(t,e)=>t.filter((t=>!e.some((e=>t.datasetIndex===e.datasetIndex&&t.index===e.index)))),a=s(e,t),r=i?t:s(t,e);a.length&&n.updateHoverStyle(a,o.mode,!1),r.length&&o.mode&&n.updateHoverStyle(r,o.mode,!0)}_eventHandler(t,e){const i=this,n={event:t,replay:e,cancelable:!0},o=e=>(e.options.events||this.options.events).includes(t.type);if(!1===i.notifyPlugins("beforeEvent",n,o))return;const s=i._handleEvent(t,e);return n.cancelable=!1,i.notifyPlugins("afterEvent",n,o),(s||n.changed)&&i.render(),i}_handleEvent(t,e){const i=this,{_active:n=[],options:o}=i,s=o.hover,a=e;let r=[],l=!1,c=null;return"mouseout"!==t.type&&(r=i.getElementsAtEventForMode(t,s.mode,s,a),c="click"===t.type?i._lastEvent:t),i._lastEvent=null,Gt(t,i.chartArea,i._minPadding)&&(Q(o.onHover,[t,r,i],i),"mouseup"!==t.type&&"click"!==t.type&&"contextmenu"!==t.type||Q(o.onClick,[t,r,i],i)),l=!tt(r,n),(l||e)&&(i._active=r,i._updateHoverStyles(r,n,e)),i._lastEvent=c,l}}const io=()=>J(eo.instances,(t=>t._plugins.invalidate())),no=!0;function oo(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}Object.defineProperties(eo,{defaults:{enumerable:no,value:xt},instances:{enumerable:no,value:Jn},overrides:{enumerable:no,value:ft},registry:{enumerable:no,value:Ln},version:{enumerable:no,value:"3.4.1"},getChart:{enumerable:no,value:to},register:{enumerable:no,value:(...t)=>{Ln.add(...t),io()}},unregister:{enumerable:no,value:(...t)=>{Ln.remove(...t),io()}}});class so{constructor(t){this.options=t||{}}formats(){return oo()}parse(t,e){return oo()}format(t,e){return oo()}add(t,e,i){return oo()}diff(t,e,i){return oo()}startOf(t,e,i){return oo()}endOf(t,e){return oo()}}so.override=function(t){Object.assign(so.prototype,t)};var ao={_date:so};function ro(t){const e=function(t){if(!t._cache.$bar){const e=t.getMatchingVisibleMetas("bar");let i=[];for(let n=0,o=e.length;nt-e)))}return t._cache.$bar}(t);let i,n,o,s,a=t._length;const r=()=>{32767!==o&&-32768!==o&&(ht(s)&&(a=Math.min(a,Math.abs(o-s)||a)),s=o)};for(i=0,n=e.length;iMath.abs(r)&&(l=r,c=a),e[i.axis]=c,e._custom={barStart:l,barEnd:c,start:o,end:s,min:a,max:r}}(t,e,i,n):e[i.axis]=i.parse(t,n),e}function co(t,e,i,n){const o=t.iScale,s=t.vScale,a=o.getLabels(),r=o===s,l=[];let c,h,d,u;for(c=i,h=i+n;c0?(p+=t,h-=t):h<0&&(p-=t,h+=t)}return{size:h,base:p,head:c,center:c+h/2}}_calculateBarIndexPixels(t,e){const i=this,n=e.scale,o=i.options,s=o.skipNull,a=K(o.maxBarThickness,1/0);let r,l;if(e.grouped){const n=s?i._getStackCount(t):e.stackCount,c="flex"===o.barThickness?function(t,e,i,n){const o=e.pixels,s=o[t];let a=t>0?o[t-1]:null,r=t=0;--n)i=Math.max(i,t[n].size()/2,e[n]._custom);return i>0&&i}getLabelAndValue(t){const e=this._cachedMeta,{xScale:i,yScale:n}=e,o=this.getParsed(t),s=i.getLabelForValue(o.x),a=n.getLabelForValue(o.y),r=o._custom;return{label:e.label,value:"("+s+", "+a+(r?", "+r:"")+")"}}update(t){const e=this._cachedMeta.data;this.updateElements(e,0,e.length,t)}updateElements(t,e,i,n){const o=this,s="reset"===n,{iScale:a,vScale:r}=o._cachedMeta,l=o.resolveDataElementOptions(e,n),c=o.getSharedOptions(l),h=o.includeOptions(n,c),d=a.axis,u=r.axis;for(let l=e;l""}}}};class go extends Ei{constructor(t,e){super(t,e),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,e){const i=this.getDataset().data,n=this._cachedMeta;let o,s;for(o=t,s=t+e;oNt(t,r,l,!0)?1:Math.max(e,e*i,n,n*i),g=(t,e,n)=>Nt(t,r,l,!0)?-1:Math.min(e,e*i,n,n*i),p=f(0,c,d),m=f(Mt,h,u),x=g(bt,c,d),b=g(bt+Mt,h,u);n=(p-x)/2,o=(m-b)/2,s=-(p+x)/2,a=-(m+b)/2}return{ratioX:n,ratioY:o,offsetX:s,offsetY:a}}(d,h,l),m=(n.width-a)/u,x=(n.height-a)/f,b=Math.max(Math.min(m,x)/2,0),_=Z(e.options.radius,b),y=(_-Math.max(_*l,0))/e._getVisibleDatasetWeightTotal();e.offsetX=g*_,e.offsetY=p*_,o.total=e.calculateTotal(),e.outerRadius=_-y*e._getRingWeightOffset(e.index),e.innerRadius=Math.max(e.outerRadius-y*c,0),e.updateElements(s,0,s.length,t)}_circumference(t,e){const i=this,n=i.options,o=i._cachedMeta,s=i._getCircumference();return e&&n.animation.animateRotate||!this.chart.getDataVisibility(t)||null===o._parsed[t]?0:i.calculateCircumference(o._parsed[t]*s/_t)}updateElements(t,e,i,n){const o=this,s="reset"===n,a=o.chart,r=a.chartArea,l=a.options.animation,c=(r.left+r.right)/2,h=(r.top+r.bottom)/2,d=s&&l.animateScale,u=d?0:o.innerRadius,f=d?0:o.outerRadius,g=o.resolveDataElementOptions(e,n),p=o.getSharedOptions(g),m=o.includeOptions(n,p);let x,b=o._getRotation();for(x=0;x0&&!isNaN(t)?_t*(Math.abs(t)/e):0}getLabelAndValue(t){const e=this._cachedMeta,i=this.chart,n=i.data.labels||[],o=Fi(e._parsed[t],i.options.locale);return{label:n[t]||"",value:o}}getMaxBorderWidth(t){const e=this;let i=0;const n=e.chart;let o,s,a,r,l;if(!t)for(o=0,s=n.data.datasets.length;o"spacing"!==t,_indexable:t=>"spacing"!==t},go.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const e=t.data;if(e.labels.length&&e.datasets.length){const{labels:{pointStyle:i}}=t.legend.options;return e.labels.map(((e,n)=>{const o=t.getDatasetMeta(0).controller.getStyle(n);return{text:e,fillStyle:o.backgroundColor,strokeStyle:o.borderColor,lineWidth:o.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(n),index:n}}))}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}},tooltip:{callbacks:{title:()=>"",label(t){let e=t.label;const i=": "+t.formattedValue;return Y(e)?(e=e.slice(),e[0]+=i):e+=i,e}}}}};class po extends Ei{initialize(){this.enableOptionSharing=!0,super.initialize()}update(t){const e=this,i=e._cachedMeta,{dataset:n,data:o=[],_dataset:s}=i,a=e.chart._animationsDisabled;let{start:r,count:l}=function(t,e,i){const n=e.length;let o=0,s=n;if(t._sorted){const{iScale:a,_parsed:r}=t,l=a.axis,{min:c,max:h,minDefined:d,maxDefined:u}=a.getUserBounds();d&&(o=Ht(Math.min(se(r,a.axis,c).lo,i?n:se(e,l,a.getPixelForValue(c)).lo),0,n-1)),s=u?Ht(Math.max(se(r,a.axis,h).hi+1,i?0:se(e,l,a.getPixelForValue(h)).hi+1),o,n)-o:n-o}return{start:o,count:s}}(i,o,a);e._drawStart=r,e._drawCount=l,function(t){const{xScale:e,yScale:i,_scaleRanges:n}=t,o={xmin:e.min,xmax:e.max,ymin:i.min,ymax:i.max};if(!n)return t._scaleRanges=o,!0;const s=n.xmin!==e.min||n.xmax!==e.max||n.ymin!==i.min||n.ymax!==i.max;return Object.assign(n,o),s}(i)&&(r=0,l=o.length),n._decimated=!!s._decimated,n.points=o;const c=e.resolveDatasetElementOptions(t);e.options.showLine||(c.borderWidth=0),c.segment=e.options.segment,e.updateElement(n,void 0,{animated:!a,options:c},t),e.updateElements(o,r,l,t)}updateElements(t,e,i,n){const o=this,s="reset"===n,{iScale:a,vScale:r,_stacked:l}=o._cachedMeta,c=o.resolveDataElementOptions(e,n),h=o.getSharedOptions(c),d=o.includeOptions(n,h),u=a.axis,f=r.axis,g=o.options.spanGaps,p=Tt(g)?g:Number.POSITIVE_INFINITY,m=o.chart._animationsDisabled||s||"none"===n;let x=e>0&&o.getParsed(e-1);for(let c=e;c0&&i[u]-x[u]>p,g.parsed=i,d&&(g.options=h||o.resolveDataElementOptions(c,e.active?"active":n)),m||o.updateElement(e,c,g,n),x=i}o.updateSharedOptions(h,n,c)}getMaxOverflow(){const t=this,e=t._cachedMeta,i=e.dataset,n=i.options&&i.options.borderWidth||0,o=e.data||[];if(!o.length)return n;const s=o[0].size(t.resolveDataElementOptions(0)),a=o[o.length-1].size(t.resolveDataElementOptions(o.length-1));return Math.max(n,s,a)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}po.id="line",po.defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1},po.overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};class mo extends Ei{constructor(t,e){super(t,e),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const e=this._cachedMeta,i=this.chart,n=i.data.labels||[],o=Fi(e._parsed[t].r,i.options.locale);return{label:n[t]||"",value:o}}update(t){const e=this._cachedMeta.data;this._updateRadius(),this.updateElements(e,0,e.length,t)}_updateRadius(){const t=this,e=t.chart,i=e.chartArea,n=e.options,o=Math.min(i.right-i.left,i.bottom-i.top),s=Math.max(o/2,0),a=(s-Math.max(n.cutoutPercentage?s/100*n.cutoutPercentage:1,0))/e.getVisibleDatasetCount();t.outerRadius=s-a*t.index,t.innerRadius=t.outerRadius-a}updateElements(t,e,i,n){const o=this,s="reset"===n,a=o.chart,r=o.getDataset(),l=a.options.animation,c=o._cachedMeta.rScale,h=c.xCenter,d=c.yCenter,u=c.getIndexAngle(0)-.5*bt;let f,g=u;const p=360/o.countVisibleElements();for(f=0;f{!isNaN(t.data[n])&&this.chart.getDataVisibility(n)&&i++})),i}_computeAngle(t,e,i){return this.chart.getDataVisibility(t)?Et(this.resolveDataElementOptions(t,e).angle||i):0}}mo.id="polarArea",mo.defaults={dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0},mo.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const e=t.data;if(e.labels.length&&e.datasets.length){const{labels:{pointStyle:i}}=t.legend.options;return e.labels.map(((e,n)=>{const o=t.getDatasetMeta(0).controller.getStyle(n);return{text:e,fillStyle:o.backgroundColor,strokeStyle:o.borderColor,lineWidth:o.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(n),index:n}}))}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}},tooltip:{callbacks:{title:()=>"",label:t=>t.chart.data.labels[t.dataIndex]+": "+t.formattedValue}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}};class xo extends go{}xo.id="pie",xo.defaults={cutout:0,rotation:0,circumference:360,radius:"100%"};class bo extends Ei{getLabelAndValue(t){const e=this._cachedMeta.vScale,i=this.getParsed(t);return{label:e.getLabels()[t],value:""+e.getLabelForValue(i[e.axis])}}update(t){const e=this,i=e._cachedMeta,n=i.dataset,o=i.data||[],s=i.iScale.getLabels();if(n.points=o,"resize"!==t){const i=e.resolveDatasetElementOptions(t);e.options.showLine||(i.borderWidth=0);const a={_loop:!0,_fullLoop:s.length===o.length,options:i};e.updateElement(n,void 0,a,t)}e.updateElements(o,0,o.length,t)}updateElements(t,e,i,n){const o=this,s=o.getDataset(),a=o._cachedMeta.rScale,r="reset"===n;for(let l=e;l"",label:t=>"("+t.label+", "+t.formattedValue+")"}}},scales:{x:{type:"linear"},y:{type:"linear"}}};var yo=Object.freeze({__proto__:null,BarController:uo,BubbleController:fo,DoughnutController:go,LineController:po,PolarAreaController:mo,PieController:xo,RadarController:bo,ScatterController:_o});function vo(t,e,i){const{startAngle:n,pixelMargin:o,x:s,y:a,outerRadius:r,innerRadius:l}=e;let c=o/r;t.beginPath(),t.arc(s,a,r,n-c,i+c),l>o?(c=o/l,t.arc(s,a,l,i+c,n-c,!0)):t.arc(s,a,o,i+Mt,n-Mt),t.closePath(),t.clip()}function wo(t,e,i,n){const o=Ee(t.options.borderRadius,["outerStart","outerEnd","innerStart","innerEnd"]);const s=(i-e)/2,a=Math.min(s,n*e/2),r=t=>{const e=(i-Math.min(s,t))*n/2;return Ht(t,0,Math.min(s,e))};return{outerStart:r(o.outerStart),outerEnd:r(o.outerEnd),innerStart:Ht(o.innerStart,0,a),innerEnd:Ht(o.innerEnd,0,a)}}function Mo(t,e,i,n){return{x:i+t*Math.cos(e),y:n+t*Math.sin(e)}}function ko(t,e,i,n,o){const{x:s,y:a,startAngle:r,pixelMargin:l,innerRadius:c}=e,h=Math.max(e.outerRadius+n+i-l,0),d=c>0?c+n+i+l:0;let u=0;const f=o-r;if(n){const t=((c>0?c-n:0)+(h>0?h-n:0))/2;u=(f-(0!==t?f*t/(t+n):f))/2}const g=(f-Math.max(.001,f*h-i/bt)/h)/2,p=r+g+u,m=o-g-u,{outerStart:x,outerEnd:b,innerStart:_,innerEnd:y}=wo(e,d,h,m-p),v=h-x,w=h-b,M=p+x/v,k=m-b/w,S=d+_,P=d+y,D=p+_/S,C=m-y/P;if(t.beginPath(),t.arc(s,a,h,M,k),b>0){const e=Mo(w,k,s,a);t.arc(e.x,e.y,b,k,m+Mt)}const O=Mo(P,m,s,a);if(t.lineTo(O.x,O.y),y>0){const e=Mo(P,C,s,a);t.arc(e.x,e.y,y,m+Mt,C+Math.PI)}if(t.arc(s,a,d,m-y/d,p+_/d,!0),_>0){const e=Mo(S,D,s,a);t.arc(e.x,e.y,_,D+Math.PI,p-Mt)}const T=Mo(v,p,s,a);if(t.lineTo(T.x,T.y),x>0){const e=Mo(v,M,s,a);t.arc(e.x,e.y,x,p-Mt,M)}t.closePath()}function So(t,e,i,n,o){const{options:s}=e,a="inner"===s.borderAlign;s.borderWidth&&(a?(t.lineWidth=2*s.borderWidth,t.lineJoin="round"):(t.lineWidth=s.borderWidth,t.lineJoin="bevel"),e.fullCircles&&function(t,e,i){const{x:n,y:o,startAngle:s,pixelMargin:a,fullCircles:r}=e,l=Math.max(e.outerRadius-a,0),c=e.innerRadius+a;let h;for(i&&vo(t,e,s+_t),t.beginPath(),t.arc(n,o,c,s+_t,s,!0),h=0;h=_t||Nt(o,a,r))&&(s>=l+d&&s<=c+d)}getCenterPoint(t){const{x:e,y:i,startAngle:n,endAngle:o,innerRadius:s,outerRadius:a}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius","circumference"],t),{offset:r,spacing:l}=this.options,c=(n+o)/2,h=(s+a+l+r)/2;return{x:e+Math.cos(c)*h,y:i+Math.sin(c)*h}}tooltipPosition(t){return this.getCenterPoint(t)}draw(t){const e=this,{options:i,circumference:n}=e,o=(i.offset||0)/2,s=(i.spacing||0)/2;if(e.pixelMargin="inner"===i.borderAlign?.33:0,e.fullCircles=n>_t?Math.floor(n/_t):0,0===n||e.innerRadius<0||e.outerRadius<0)return;t.save();let a=0;if(o){a=o/2;const i=(e.startAngle+e.endAngle)/2;t.translate(Math.cos(i)*a,Math.sin(i)*a),e.circumference>=bt&&(a=o)}t.fillStyle=i.backgroundColor,t.strokeStyle=i.borderColor;const r=function(t,e,i,n){const{fullCircles:o,startAngle:s,circumference:a}=e;let r=e.endAngle;if(o){ko(t,e,i,n,s+_t);for(let e=0;er&&s>r;return{count:n,start:l,loop:e.loop,ilen:c(a+(c?r-t:t))%s,_=()=>{f!==g&&(t.lineTo(m,g),t.lineTo(m,f),t.lineTo(m,p))};for(l&&(d=o[b(0)],t.moveTo(d.x,d.y)),h=0;h<=r;++h){if(d=o[b(h)],d.skip)continue;const e=d.x,i=d.y,n=0|e;n===u?(ig&&(g=i),m=(x*m+e)/++x):(_(),t.lineTo(e,i),u=n,x=0,f=g=i),p=i}_()}function Lo(t){const e=t.options,i=e.borderDash&&e.borderDash.length;return!(t._decimated||t._loop||e.tension||"monotone"===e.cubicInterpolationMode||e.stepped||i)?Ao:To}Po.id="arc",Po.defaults={borderAlign:"center",borderColor:"#fff",borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0},Po.defaultRoutes={backgroundColor:"backgroundColor"};const Ro="function"==typeof Path2D;function Eo(t,e,i,n){Ro&&1===e.segments.length?function(t,e,i,n){let o=e._path;o||(o=e._path=new Path2D,e.path(o,i,n)&&o.closePath()),Do(t,e.options),t.stroke(o)}(t,e,i,n):function(t,e,i,n){const{segments:o,options:s}=e,a=Lo(e);for(const r of o)Do(t,s,r.style),t.beginPath(),a(t,e,r,{start:i,end:i+n-1})&&t.closePath(),t.stroke()}(t,e,i,n)}class zo extends zi{constructor(t){super(),this.animated=!0,this.options=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,t&&Object.assign(this,t)}updateControlPoints(t,e){const i=this,n=i.options;if((n.tension||"monotone"===n.cubicInterpolationMode)&&!n.stepped&&!i._pointsUpdated){const o=n.spanGaps?i._loop:i._fullLoop;pn(i._points,n,t,o,e),i._pointsUpdated=!0}}set points(t){const e=this;e._points=t,delete e._segments,delete e._path,e._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=Pn(this,this.options.segment))}first(){const t=this.segments,e=this.points;return t.length&&e[t[0].start]}last(){const t=this.segments,e=this.points,i=t.length;return i&&e[t[i-1].end]}interpolate(t,e){const i=this,n=i.options,o=t[e],s=i.points,a=Sn(i,{property:e,start:o,end:o});if(!a.length)return;const r=[],l=function(t){return t.stepped?xn:t.tension||"monotone"===t.cubicInterpolationMode?bn:mn}(n);let c,h;for(c=0,h=a.length;c"borderDash"!==t&&"fill"!==t};class Fo extends zi{constructor(t){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,e,i){const n=this.options,{x:o,y:s}=this.getProps(["x","y"],i);return Math.pow(t-o,2)+Math.pow(e-s,2)t.x):Wo(e,"bottom","top",t.base=a.left&&e<=a.right)&&(s||i>=a.top&&i<=a.bottom)}function Yo(t,e){t.rect(e.x,e.y,e.w,e.h)}Fo.id="point",Fo.defaults={borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0},Fo.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};class Uo extends zi{constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,t&&Object.assign(this,t)}draw(t){const e=this.options,{inner:i,outer:n}=jo(this),o=(s=n.radius).topLeft||s.topRight||s.bottomLeft||s.bottomRight?ne:Yo;var s;t.save(),n.w===i.w&&n.h===i.h||(t.beginPath(),o(t,n),t.clip(),o(t,i),t.fillStyle=e.borderColor,t.fill("evenodd")),t.beginPath(),o(t,i),t.fillStyle=e.backgroundColor,t.fill(),t.restore()}inRange(t,e,i){return $o(this,t,e,i)}inXRange(t,e){return $o(this,t,null,e)}inYRange(t,e){return $o(this,null,t,e)}getCenterPoint(t){const{x:e,y:i,base:n,horizontal:o}=this.getProps(["x","y","base","horizontal"],t);return{x:o?(e+n)/2:e,y:o?i:(i+n)/2}}getRange(t){return"x"===t?this.width/2:this.height/2}}Uo.id="bar",Uo.defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,enableBorderRadius:!0,pointStyle:void 0},Uo.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};var Xo=Object.freeze({__proto__:null,ArcElement:Po,LineElement:zo,PointElement:Fo,BarElement:Uo});function qo(t){if(t._decimated){const e=t._data;delete t._decimated,delete t._data,Object.defineProperty(t,"data",{value:e})}}function Ko(t){t.data.datasets.forEach((t=>{qo(t)}))}var Go={id:"decimation",defaults:{algorithm:"min-max",enabled:!1},beforeElementsUpdate:(t,e,i)=>{if(!i.enabled)return void Ko(t);const n=t.width;t.data.datasets.forEach(((e,o)=>{const{_data:s,indexAxis:a}=e,r=t.getDatasetMeta(o),l=s||e.data;if("y"===Ve([a,t.options.indexAxis]))return;if("line"!==r.type)return;const c=t.scales[r.xAxisID];if("linear"!==c.type&&"time"!==c.type)return;if(t.options.parsing)return;let h,{start:d,count:u}=function(t,e){const i=e.length;let n,o=0;const{iScale:s}=t,{min:a,max:r,minDefined:l,maxDefined:c}=s.getUserBounds();return l&&(o=Ht(se(e,s.axis,a).lo,0,i-1)),n=c?Ht(se(e,s.axis,r).hi+1,o,i)-o:i-o,{start:o,count:n}}(r,l);if(u<=4*n)qo(e);else{switch($(s)&&(e._data=l,delete e.data,Object.defineProperty(e,"data",{configurable:!0,enumerable:!0,get:function(){return this._decimated},set:function(t){this._data=t}})),i.algorithm){case"lttb":h=function(t,e,i,n,o){const s=o.samples||n;if(s>=i)return t.slice(e,e+i);const a=[],r=(i-2)/(s-2);let l=0;const c=e+i-1;let h,d,u,f,g,p=e;for(a[l++]=t[p],h=0;hu&&(u=f,d=t[n],g=n);a[l++]=d,p=g}return a[l++]=t[c],a}(l,d,u,n,i);break;case"min-max":h=function(t,e,i,n){let o,s,a,r,l,c,h,d,u,f,g=0,p=0;const m=[],x=e+i-1,b=t[e].x,_=t[x].x-b;for(o=e;of&&(f=r,h=o),g=(p*g+s.x)/++p;else{const i=o-1;if(!$(c)&&!$(h)){const e=Math.min(c,h),n=Math.max(c,h);e!==d&&e!==i&&m.push({...t[e],x:g}),n!==d&&n!==i&&m.push({...t[n],x:g})}o>0&&i!==d&&m.push(t[i]),m.push(s),l=e,p=0,u=f=r,c=h=d=o}}return m}(l,d,u,n);break;default:throw new Error(`Unsupported decimation algorithm '${i.algorithm}'`)}e._decimated=h}}))},destroy(t){Ko(t)}};function Zo(t,e,i){const n=function(t){const e=t.options,i=e.fill;let n=K(i&&i.target,i);return void 0===n&&(n=!!e.backgroundColor),!1!==n&&null!==n&&(!0===n?"origin":n)}(t);if(U(n))return!isNaN(n.value)&&n;let o=parseFloat(n);return X(o)&&Math.floor(o)===o?("-"!==n[0]&&"+"!==n[0]||(o=e+o),!(o===e||o<0||o>=i)&&o):["origin","start","end","stack"].indexOf(n)>=0&&n}class Qo{constructor(t){this.x=t.x,this.y=t.y,this.radius=t.radius}pathSegment(t,e,i){const{x:n,y:o,radius:s}=this;return e=e||{start:0,end:_t},t.arc(n,o,s,e.end,e.start,!0),!i.bounds}interpolate(t){const{x:e,y:i,radius:n}=this,o=t.angle;return{x:e+Math.cos(o)*n,y:i+Math.sin(o)*n,angle:o}}}function Jo(t){return(t.scale||{}).getPointPositionForValue?function(t){const{scale:e,fill:i}=t,n=e.options,o=e.getLabels().length,s=[],a=n.reverse?e.max:e.min,r=n.reverse?e.min:e.max;let l,c,h;if(h="start"===i?a:"end"===i?r:U(i)?i.value:e.getBaseValue(),n.grid.circular)return c=e.getPointPositionForValue(0,a),new Qo({x:c.x,y:c.y,radius:e.getDistanceFromCenterForValue(h)});for(l=0;lt;e--){const t=i[e];if(!isNaN(t.x)&&!isNaN(t.y))break}return e}function es(t){const{chart:e,scale:i,index:n,line:o}=t,s=[],a=o.segments,r=o.points,l=function(t,e){const i=[],n=t.getSortedVisibleDatasetMetas();for(let t=0;t"line"===t.type&&!t.hidden;function ns(t,e,i){const n=[];for(let o=0;o=n&&o<=c){r=o===n,l=o===c;break}}return{first:r,last:l,point:n}}function ss(t,e){let i=[],n=!1;return Y(t)?(n=!0,i=t):i=function(t,e){const{x:i=null,y:n=null}=t||{},o=e.points,s=[];return e.segments.forEach((({start:t,end:e})=>{e=ts(t,e,o);const a=o[t],r=o[e];null!==n?(s.push({x:a.x,y:n}),s.push({x:r.x,y:n})):null!==i&&(s.push({x:i,y:a.y}),s.push({x:i,y:r.y}))})),s}(t,e),i.length?new zo({points:i,options:{tension:0},_loop:n,_fullLoop:n}):null}function as(t,e,i){let n=t[e].fill;const o=[e];let s;if(!i)return n;for(;!1!==n&&-1===o.indexOf(n);){if(!X(n))return n;if(s=t[n],!s)return!1;if(s.visible)return n;o.push(n),n=s.fill}return!1}function rs(t,e,i){t.beginPath(),e.path(t),t.lineTo(e.last().x,i),t.lineTo(e.first().x,i),t.closePath(),t.clip()}function ls(t,e,i,n){if(n)return;let o=e[t],s=i[t];return"angle"===t&&(o=Wt(o),s=Wt(s)),{property:t,start:o,end:s}}function cs(t,e,i,n){return t&&e?n(t[i],e[i]):t?t[i]:e?e[i]:0}function hs(t,e,i){const{top:n,bottom:o}=e.chart.chartArea,{property:s,start:a,end:r}=i||{};"x"===s&&(t.beginPath(),t.rect(a,n,r-a,o-n),t.clip())}function ds(t,e,i,n){const o=e.interpolate(i,n);o&&t.lineTo(o.x,o.y)}function us(t,e){const{line:i,target:n,property:o,color:s,scale:a}=e,r=function(t,e,i){const n=t.segments,o=t.points,s=e.points,a=[];for(const t of n){let{start:n,end:r}=t;r=ts(n,r,o);const l=ls(i,o[n],o[r],t.loop);if(!e.segments){a.push({source:t,target:l,start:o[n],end:o[r]});continue}const c=Sn(e,l);for(const e of c){const n=ls(i,s[e.start],s[e.end],e.loop),r=kn(t,o,n);for(const t of r)a.push({source:t,target:e,start:{[i]:cs(l,n,"start",Math.max)},end:{[i]:cs(l,n,"end",Math.min)}})}}return a}(i,n,o);for(const{source:e,target:l,start:c,end:h}of r){const{style:{backgroundColor:r=s}={}}=e;t.save(),t.fillStyle=r,hs(t,a,ls(o,c,h)),t.beginPath();const d=!!i.pathSegment(t,e);d?t.closePath():ds(t,n,h,o);const u=!!n.pathSegment(t,l,{move:d,reverse:!0}),f=d&&u;f||ds(t,n,c,o),t.closePath(),t.fill(f?"evenodd":"nonzero"),t.restore()}}function fs(t,e,i){const n=function(t){const{chart:e,fill:i,line:n}=t;if(X(i))return function(t,e){const i=t.getDatasetMeta(e);return i&&t.isDatasetVisible(e)?i.dataset:null}(e,i);if("stack"===i)return es(t);const o=Jo(t);return o instanceof Qo?o:ss(o,n)}(e),{line:o,scale:s,axis:a}=e,r=o.options,l=r.fill,c=r.backgroundColor,{above:h=c,below:d=c}=l||{};n&&o.points.length&&(Zt(t,i),function(t,e){const{line:i,target:n,above:o,below:s,area:a,scale:r}=e,l=i._loop?"angle":e.axis;t.save(),"x"===l&&s!==o&&(rs(t,n,a.top),us(t,{line:i,target:n,color:o,scale:r,property:l}),t.restore(),t.save(),rs(t,n,a.bottom)),us(t,{line:i,target:n,color:s,scale:r,property:l}),t.restore()}(t,{line:o,target:n,above:h,below:d,area:i,scale:s,axis:a}),Qt(t))}var gs={id:"filler",afterDatasetsUpdate(t,e,i){const n=(t.data.datasets||[]).length,o=[];let s,a,r,l;for(a=0;a=0;--e){const i=o[e].$filler;i&&(i.line.updateControlPoints(s,i.axis),n&&fs(t.ctx,i,s))}},beforeDatasetsDraw(t,e,i){if("beforeDatasetsDraw"!==i.drawTime)return;const n=t.getSortedVisibleDatasetMetas();for(let e=n.length-1;e>=0;--e){const i=n[e].$filler;i&&fs(t.ctx,i,t.chartArea)}},beforeDatasetDraw(t,e,i){const n=e.meta.$filler;n&&!1!==n.fill&&"beforeDatasetDraw"===i.drawTime&&fs(t.ctx,n,t.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}};const ps=(t,e)=>{let{boxHeight:i=e,boxWidth:n=e}=t;return t.usePointStyle&&(i=Math.min(i,e),n=Math.min(n,e)),{boxWidth:n,boxHeight:i,itemHeight:Math.max(e,i)}};class ms extends zi{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,e,i){const n=this;n.maxWidth=t,n.maxHeight=e,n._margins=i,n.setDimensions(),n.buildLabels(),n.fit()}setDimensions(){const t=this;t.isHorizontal()?(t.width=t.maxWidth,t.left=t._margins.left,t.right=t.width):(t.height=t.maxHeight,t.top=t._margins.top,t.bottom=t.height)}buildLabels(){const t=this,e=t.options.labels||{};let i=Q(e.generateLabels,[t.chart],t)||[];e.filter&&(i=i.filter((i=>e.filter(i,t.chart.data)))),e.sort&&(i=i.sort(((i,n)=>e.sort(i,n,t.chart.data)))),t.options.reverse&&i.reverse(),t.legendItems=i}fit(){const t=this,{options:e,ctx:i}=t;if(!e.display)return void(t.width=t.height=0);const n=e.labels,o=Be(n.font),s=o.size,a=t._computeTitleHeight(),{boxWidth:r,itemHeight:l}=ps(n,s);let c,h;i.font=o.string,t.isHorizontal()?(c=t.maxWidth,h=t._fitRows(a,s,r,l)+10):(h=t.maxHeight,c=t._fitCols(a,s,r,l)+10),t.width=Math.min(c,e.maxWidth||t.maxWidth),t.height=Math.min(h,e.maxHeight||t.maxHeight)}_fitRows(t,e,i,n){const o=this,{ctx:s,maxWidth:a,options:{labels:{padding:r}}}=o,l=o.legendHitBoxes=[],c=o.lineWidths=[0],h=n+r;let d=t;s.textAlign="left",s.textBaseline="middle";let u=-1,f=-h;return o.legendItems.forEach(((t,o)=>{const g=i+e/2+s.measureText(t.text).width;(0===o||c[c.length-1]+g+2*r>a)&&(d+=h,c[c.length-(o>0?0:1)]=0,f+=h,u++),l[o]={left:0,top:f,row:u,width:g,height:n},c[c.length-1]+=g+r})),d}_fitCols(t,e,i,n){const o=this,{ctx:s,maxHeight:a,options:{labels:{padding:r}}}=o,l=o.legendHitBoxes=[],c=o.columnSizes=[],h=a-t;let d=r,u=0,f=0,g=0,p=0;return o.legendItems.forEach(((t,o)=>{const a=i+e/2+s.measureText(t.text).width;o>0&&f+n+2*r>h&&(d+=u+r,c.push({width:u,height:f}),g+=u+r,p++,u=f=0),l[o]={left:g,top:f,col:p,width:a,height:n},u=Math.max(u,a),f+=n+r})),d+=u,c.push({width:u,height:f}),d}adjustHitBoxes(){const t=this;if(!t.options.display)return;const e=t._computeTitleHeight(),{legendHitBoxes:i,options:{align:n,labels:{padding:s},rtl:a}}=t;if(this.isHorizontal()){let r=0,l=o(n,t.left+s,t.right-t.lineWidths[r]);for(const a of i)r!==a.row&&(r=a.row,l=o(n,t.left+s,t.right-t.lineWidths[r])),a.top+=t.top+e+s,a.left=l,l+=a.width+s;if(a){const e=i.reduce(((t,e)=>(t[e.row]=t[e.row]||[],t[e.row].push(e),t)),{}),n=[];Object.keys(e).forEach((t=>{e[t].reverse(),n.push(...e[t])})),t.legendHitBoxes=n}}else{let a=0,r=o(n,t.top+e+s,t.bottom-t.columnSizes[a].height);for(const l of i)l.col!==a&&(a=l.col,r=o(n,t.top+e+s,t.bottom-t.columnSizes[a].height)),l.top=r,l.left+=t.left+s,r+=l.height+s}}isHorizontal(){return"top"===this.options.position||"bottom"===this.options.position}draw(){const t=this;if(t.options.display){const e=t.ctx;Zt(e,t),t._draw(),Qt(e)}}_draw(){const t=this,{options:e,columnSizes:i,lineWidths:n,ctx:a}=t,{align:r,labels:l}=e,c=xt.color,h=_n(e.rtl,t.left,t.width),d=Be(l.font),{color:u,padding:f}=l,g=d.size,p=g/2;let m;t.drawTitle(),a.textAlign=h.textAlign("left"),a.textBaseline="middle",a.lineWidth=.5,a.font=d.string;const{boxWidth:x,boxHeight:b,itemHeight:_}=ps(l,g),y=t.isHorizontal(),v=this._computeTitleHeight();m=y?{x:o(r,t.left+f,t.right-n[0]),y:t.top+f+v,line:0}:{x:t.left+f,y:o(r,t.top+v+f,t.bottom-i[0].height),line:0},yn(t.ctx,e.textDirection);const w=_+f;t.legendItems.forEach(((M,k)=>{a.strokeStyle=M.fontColor||u,a.fillStyle=M.fontColor||u;const S=a.measureText(M.text).width,P=h.textAlign(M.textAlign||(M.textAlign=l.textAlign)),D=x+p+S;let C=m.x,O=m.y;h.setWidth(t.width),y?k>0&&C+D+f>t.right&&(O=m.y+=w,m.line++,C=m.x=o(r,t.left+f,t.right-n[m.line])):k>0&&O+w>t.bottom&&(C=m.x=C+i[m.line].width+f,m.line++,O=m.y=o(r,t.top+v+f,t.bottom-i[m.line].height));!function(t,e,i){if(isNaN(x)||x<=0||isNaN(b)||b<0)return;a.save();const n=K(i.lineWidth,1);if(a.fillStyle=K(i.fillStyle,c),a.lineCap=K(i.lineCap,"butt"),a.lineDashOffset=K(i.lineDashOffset,0),a.lineJoin=K(i.lineJoin,"miter"),a.lineWidth=n,a.strokeStyle=K(i.strokeStyle,c),a.setLineDash(K(i.lineDash,[])),l.usePointStyle){const o={radius:x*Math.SQRT2/2,pointStyle:i.pointStyle,rotation:i.rotation,borderWidth:n},s=h.xPlus(t,x/2);Kt(a,o,s,e+p)}else{const o=e+Math.max((g-b)/2,0),s=h.leftForLtr(t,x),r=Ie(i.borderRadius);a.beginPath(),Object.values(r).some((t=>0!==t))?ne(a,{x:s,y:o,w:x,h:b,radius:r}):a.rect(s,o,x,b),a.fill(),0!==n&&a.stroke()}a.restore()}(h.x(C),O,M),C=s(P,C+x+p,y?C+D:t.right,e.rtl),function(t,e,i){ee(a,i.text,t,e+_/2,d,{strikethrough:i.hidden,textAlign:h.textAlign(i.textAlign)})}(h.x(C),O,M),y?m.x+=D+f:m.y+=w})),vn(t.ctx,e.textDirection)}drawTitle(){const t=this,e=t.options,i=e.title,s=Be(i.font),a=Fe(i.padding);if(!i.display)return;const r=_n(e.rtl,t.left,t.width),l=t.ctx,c=i.position,h=s.size/2,d=a.top+h;let u,f=t.left,g=t.width;if(this.isHorizontal())g=Math.max(...t.lineWidths),u=t.top+d,f=o(e.align,f,t.right-g);else{const i=t.columnSizes.reduce(((t,e)=>Math.max(t,e.height)),0);u=d+o(e.align,t.top,t.bottom-i-e.labels.padding-t._computeTitleHeight())}const p=o(c,f,f+g);l.textAlign=r.textAlign(n(c)),l.textBaseline="middle",l.strokeStyle=i.color,l.fillStyle=i.color,l.font=s.string,ee(l,i.text,p,u,s)}_computeTitleHeight(){const t=this.options.title,e=Be(t.font),i=Fe(t.padding);return t.display?e.lineHeight+i.height:0}_getLegendItemAt(t,e){const i=this;let n,o,s;if(t>=i.left&&t<=i.right&&e>=i.top&&e<=i.bottom)for(s=i.legendHitBoxes,n=0;n=o.left&&t<=o.left+o.width&&e>=o.top&&e<=o.top+o.height)return i.legendItems[n];return null}handleEvent(t){const e=this,i=e.options;if(!function(t,e){if("mousemove"===t&&(e.onHover||e.onLeave))return!0;if(e.onClick&&("click"===t||"mouseup"===t))return!0;return!1}(t.type,i))return;const n=e._getLegendItemAt(t.x,t.y);if("mousemove"===t.type){const a=e._hoveredItem,r=(s=n,null!==(o=a)&&null!==s&&o.datasetIndex===s.datasetIndex&&o.index===s.index);a&&!r&&Q(i.onLeave,[t,a,e],e),e._hoveredItem=n,n&&!r&&Q(i.onHover,[t,n,e],e)}else n&&Q(i.onClick,[t,n,e],e);var o,s}}var xs={id:"legend",_element:ms,start(t,e,i){const n=t.legend=new ms({ctx:t.ctx,options:i,chart:t});Ze.configure(t,n,i),Ze.addBox(t,n)},stop(t){Ze.removeBox(t,t.legend),delete t.legend},beforeUpdate(t,e,i){const n=t.legend;Ze.configure(t,n,i),n.options=i},afterUpdate(t){const e=t.legend;e.buildLabels(),e.adjustHitBoxes()},afterEvent(t,e){e.replay||t.legend.handleEvent(e.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(t,e,i){const n=e.datasetIndex,o=i.chart;o.isDatasetVisible(n)?(o.hide(n),e.hidden=!0):(o.show(n),e.hidden=!1)},onHover:null,onLeave:null,labels:{color:t=>t.chart.options.color,boxWidth:40,padding:10,generateLabels(t){const e=t.data.datasets,{labels:{usePointStyle:i,pointStyle:n,textAlign:o,color:s}}=t.legend.options;return t._getSortedDatasetMetas().map((t=>{const a=t.controller.getStyle(i?0:void 0),r=Fe(a.borderWidth);return{text:e[t.index].label,fillStyle:a.backgroundColor,fontColor:s,hidden:!t.visible,lineCap:a.borderCapStyle,lineDash:a.borderDash,lineDashOffset:a.borderDashOffset,lineJoin:a.borderJoinStyle,lineWidth:(r.width+r.height)/4,strokeStyle:a.borderColor,pointStyle:n||a.pointStyle,rotation:a.rotation,textAlign:o||a.textAlign,borderRadius:0,datasetIndex:t.index}}),this)}},title:{color:t=>t.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:t=>!t.startsWith("on"),labels:{_scriptable:t=>!["generateLabels","filter","sort"].includes(t)}}};class bs extends zi{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,e){const i=this,n=i.options;if(i.left=0,i.top=0,!n.display)return void(i.width=i.height=i.right=i.bottom=0);i.width=i.right=t,i.height=i.bottom=e;const o=Y(n.text)?n.text.length:1;i._padding=Fe(n.padding);const s=o*Be(n.font).lineHeight+i._padding.height;i.isHorizontal()?i.height=s:i.width=s}isHorizontal(){const t=this.options.position;return"top"===t||"bottom"===t}_drawArgs(t){const{top:e,left:i,bottom:n,right:s,options:a}=this,r=a.align;let l,c,h,d=0;return this.isHorizontal()?(c=o(r,i,s),h=e+t,l=s-i):("left"===a.position?(c=i+t,h=o(r,n,e),d=-.5*bt):(c=s-t,h=o(r,e,n),d=.5*bt),l=n-e),{titleX:c,titleY:h,maxWidth:l,rotation:d}}draw(){const t=this,e=t.ctx,i=t.options;if(!i.display)return;const o=Be(i.font),s=o.lineHeight/2+t._padding.top,{titleX:a,titleY:r,maxWidth:l,rotation:c}=t._drawArgs(s);ee(e,i.text,0,0,o,{color:i.color,maxWidth:l,rotation:c,textAlign:n(i.align),textBaseline:"middle",translation:[a,r]})}}var _s={id:"title",_element:bs,start(t,e,i){!function(t,e){const i=new bs({ctx:t.ctx,options:e,chart:t});Ze.configure(t,i,e),Ze.addBox(t,i),t.titleBlock=i}(t,i)},stop(t){const e=t.titleBlock;Ze.removeBox(t,e),delete t.titleBlock},beforeUpdate(t,e,i){const n=t.titleBlock;Ze.configure(t,n,i),n.options=i},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const ys=new WeakMap;var vs={id:"subtitle",start(t,e,i){const n=new bs({ctx:t.ctx,options:i,chart:t});Ze.configure(t,n,i),Ze.addBox(t,n),ys.set(t,n)},stop(t){Ze.removeBox(t,ys.get(t)),ys.delete(t)},beforeUpdate(t,e,i){const n=ys.get(t);Ze.configure(t,n,i),n.options=i},defaults:{align:"center",display:!1,font:{weight:"normal"},fullSize:!0,padding:0,position:"top",text:"",weight:1500},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const ws={average(t){if(!t.length)return!1;let e,i,n=0,o=0,s=0;for(e=0,i=t.length;e-1?t.split("\n"):t}function Ss(t,e){const{element:i,datasetIndex:n,index:o}=e,s=t.getDatasetMeta(n).controller,{label:a,value:r}=s.getLabelAndValue(o);return{chart:t,label:a,parsed:s.getParsed(o),raw:t.data.datasets[n].data[o],formattedValue:r,dataset:s.getDataset(),dataIndex:o,datasetIndex:n,element:i}}function Ps(t,e){const i=t._chart.ctx,{body:n,footer:o,title:s}=t,{boxWidth:a,boxHeight:r}=e,l=Be(e.bodyFont),c=Be(e.titleFont),h=Be(e.footerFont),d=s.length,u=o.length,f=n.length,g=Fe(e.padding);let p=g.height,m=0,x=n.reduce(((t,e)=>t+e.before.length+e.lines.length+e.after.length),0);if(x+=t.beforeBody.length+t.afterBody.length,d&&(p+=d*c.lineHeight+(d-1)*e.titleSpacing+e.titleMarginBottom),x){p+=f*(e.displayColors?Math.max(r,l.lineHeight):l.lineHeight)+(x-f)*l.lineHeight+(x-1)*e.bodySpacing}u&&(p+=e.footerMarginTop+u*h.lineHeight+(u-1)*e.footerSpacing);let b=0;const _=function(t){m=Math.max(m,i.measureText(t).width+b)};return i.save(),i.font=c.string,J(t.title,_),i.font=l.string,J(t.beforeBody.concat(t.afterBody),_),b=e.displayColors?a+2:0,J(n,(t=>{J(t.before,_),J(t.lines,_),J(t.after,_)})),b=0,i.font=h.string,J(t.footer,_),i.restore(),m+=g.width,{width:m,height:p}}function Ds(t,e,i,n){const{x:o,width:s}=i,{width:a,chartArea:{left:r,right:l}}=t;let c="center";return"center"===n?c=o<=(r+l)/2?"left":"right":o<=s/2?c="left":o>=a-s/2&&(c="right"),function(t,e,i,n){const{x:o,width:s}=n,a=i.caretSize+i.caretPadding;return"left"===t&&o+s+a>e.width||"right"===t&&o-s-a<0||void 0}(c,t,e,i)&&(c="center"),c}function Cs(t,e,i){const n=e.yAlign||function(t,e){const{y:i,height:n}=e;return it.height-n/2?"bottom":"center"}(t,i);return{xAlign:e.xAlign||Ds(t,e,i,n),yAlign:n}}function Os(t,e,i,n){const{caretSize:o,caretPadding:s,cornerRadius:a}=t,{xAlign:r,yAlign:l}=i,c=o+s,h=a+s;let d=function(t,e){let{x:i,width:n}=t;return"right"===e?i-=n:"center"===e&&(i-=n/2),i}(e,r);const u=function(t,e,i){let{y:n,height:o}=t;return"top"===e?n+=i:n-="bottom"===e?o+i:o/2,n}(e,l,c);return"center"===l?"left"===r?d+=c:"right"===r&&(d-=c):"left"===r?d-=h:"right"===r&&(d+=h),{x:Ht(d,0,n.width-e.width),y:Ht(u,0,n.height-e.height)}}function Ts(t,e,i){const n=Fe(i.padding);return"center"===e?t.x+t.width/2:"right"===e?t.x+t.width-n.right:t.x+n.left}function As(t){return Ms([],ks(t))}function Ls(t,e){const i=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return i?t.override(i):t}class Rs extends zi{constructor(t){super(),this.opacity=0,this._active=[],this._chart=t._chart,this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this,e=t._cachedAnimations;if(e)return e;const i=t._chart,n=t.options.setContext(t.getContext()),o=n.enabled&&i.options.animation&&n.animations,s=new wi(t._chart,o);return o._cacheable&&(t._cachedAnimations=Object.freeze(s)),s}getContext(){const t=this;return t.$context||(t.$context=(e=t._chart.getContext(),i=t,n=t._tooltipItems,Object.assign(Object.create(e),{tooltip:i,tooltipItems:n,type:"tooltip"})));var e,i,n}getTitle(t,e){const i=this,{callbacks:n}=e,o=n.beforeTitle.apply(i,[t]),s=n.title.apply(i,[t]),a=n.afterTitle.apply(i,[t]);let r=[];return r=Ms(r,ks(o)),r=Ms(r,ks(s)),r=Ms(r,ks(a)),r}getBeforeBody(t,e){return As(e.callbacks.beforeBody.apply(this,[t]))}getBody(t,e){const i=this,{callbacks:n}=e,o=[];return J(t,(t=>{const e={before:[],lines:[],after:[]},s=Ls(n,t);Ms(e.before,ks(s.beforeLabel.call(i,t))),Ms(e.lines,s.label.call(i,t)),Ms(e.after,ks(s.afterLabel.call(i,t))),o.push(e)})),o}getAfterBody(t,e){return As(e.callbacks.afterBody.apply(this,[t]))}getFooter(t,e){const i=this,{callbacks:n}=e,o=n.beforeFooter.apply(i,[t]),s=n.footer.apply(i,[t]),a=n.afterFooter.apply(i,[t]);let r=[];return r=Ms(r,ks(o)),r=Ms(r,ks(s)),r=Ms(r,ks(a)),r}_createItems(t){const e=this,i=e._active,n=e._chart.data,o=[],s=[],a=[];let r,l,c=[];for(r=0,l=i.length;rt.filter(e,i,o,n)))),t.itemSort&&(c=c.sort(((e,i)=>t.itemSort(e,i,n)))),J(c,(i=>{const n=Ls(t.callbacks,i);o.push(n.labelColor.call(e,i)),s.push(n.labelPointStyle.call(e,i)),a.push(n.labelTextColor.call(e,i))})),e.labelColors=o,e.labelPointStyles=s,e.labelTextColors=a,e.dataPoints=c,c}update(t,e){const i=this,n=i.options.setContext(i.getContext()),o=i._active;let s,a=[];if(o.length){const t=ws[n.position].call(i,o,i._eventPosition);a=i._createItems(n),i.title=i.getTitle(a,n),i.beforeBody=i.getBeforeBody(a,n),i.body=i.getBody(a,n),i.afterBody=i.getAfterBody(a,n),i.footer=i.getFooter(a,n);const e=i._size=Ps(i,n),r=Object.assign({},t,e),l=Cs(i._chart,n,r),c=Os(n,r,l,i._chart);i.xAlign=l.xAlign,i.yAlign=l.yAlign,s={opacity:1,x:c.x,y:c.y,width:e.width,height:e.height,caretX:t.x,caretY:t.y}}else 0!==i.opacity&&(s={opacity:0});i._tooltipItems=a,i.$context=void 0,s&&i._resolveAnimations().update(i,s),t&&n.external&&n.external.call(i,{chart:i._chart,tooltip:i,replay:e})}drawCaret(t,e,i,n){const o=this.getCaretPosition(t,i,n);e.lineTo(o.x1,o.y1),e.lineTo(o.x2,o.y2),e.lineTo(o.x3,o.y3)}getCaretPosition(t,e,i){const{xAlign:n,yAlign:o}=this,{cornerRadius:s,caretSize:a}=i,{x:r,y:l}=t,{width:c,height:h}=e;let d,u,f,g,p,m;return"center"===o?(p=l+h/2,"left"===n?(d=r,u=d-a,g=p+a,m=p-a):(d=r+c,u=d+a,g=p-a,m=p+a),f=d):(u="left"===n?r+s+a:"right"===n?r+c-s-a:this.caretX,"top"===o?(g=l,p=g-a,d=u-a,f=u+a):(g=l+h,p=g+a,d=u+a,f=u-a),m=g),{x1:d,x2:u,x3:f,y1:g,y2:p,y3:m}}drawTitle(t,e,i){const n=this,o=n.title,s=o.length;let a,r,l;if(s){const c=_n(i.rtl,n.x,n.width);for(t.x=Ts(n,i.titleAlign,i),e.textAlign=c.textAlign(i.titleAlign),e.textBaseline="middle",a=Be(i.titleFont),r=i.titleSpacing,e.fillStyle=i.titleColor,e.font=a.string,l=0;l0!==t))?(t.beginPath(),t.fillStyle=o.multiKeyBackground,ne(t,{x:e,y:g,w:c,h:l,radius:s}),t.fill(),t.stroke(),t.fillStyle=a.backgroundColor,t.beginPath(),ne(t,{x:i,y:g+1,w:c-2,h:l-2,radius:s}),t.fill()):(t.fillStyle=o.multiKeyBackground,t.fillRect(e,g,c,l),t.strokeRect(e,g,c,l),t.fillStyle=a.backgroundColor,t.fillRect(i,g+1,c-2,l-2))}t.fillStyle=s.labelTextColors[i]}drawBody(t,e,i){const n=this,{body:o}=n,{bodySpacing:s,bodyAlign:a,displayColors:r,boxHeight:l,boxWidth:c}=i,h=Be(i.bodyFont);let d=h.lineHeight,u=0;const f=_n(i.rtl,n.x,n.width),g=function(i){e.fillText(i,f.x(t.x+u),t.y+d/2),t.y+=d+s},p=f.textAlign(a);let m,x,b,_,y,v,w;for(e.textAlign=a,e.textBaseline="middle",e.font=h.string,t.x=Ts(n,p,i),e.fillStyle=i.bodyColor,J(n.beforeBody,g),u=r&&"right"!==p?"center"===a?c/2+1:c+2:0,_=0,v=o.length;_0&&e.stroke()}_updateAnimationTarget(t){const e=this,i=e._chart,n=e.$animations,o=n&&n.x,s=n&&n.y;if(o||s){const n=ws[t.position].call(e,e._active,e._eventPosition);if(!n)return;const a=e._size=Ps(e,t),r=Object.assign({},n,e._size),l=Cs(i,t,r),c=Os(t,r,l,i);o._to===c.x&&s._to===c.y||(e.xAlign=l.xAlign,e.yAlign=l.yAlign,e.width=a.width,e.height=a.height,e.caretX=n.x,e.caretY=n.y,e._resolveAnimations().update(e,c))}}draw(t){const e=this,i=e.options.setContext(e.getContext());let n=e.opacity;if(!n)return;e._updateAnimationTarget(i);const o={width:e.width,height:e.height},s={x:e.x,y:e.y};n=Math.abs(n)<.001?0:n;const a=Fe(i.padding),r=e.title.length||e.beforeBody.length||e.body.length||e.afterBody.length||e.footer.length;i.enabled&&r&&(t.save(),t.globalAlpha=n,e.drawBackground(s,t,o,i),yn(t,i.textDirection),s.y+=a.top,e.drawTitle(s,t,i),e.drawBody(s,t,i),e.drawFooter(s,t,i),vn(t,i.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,e){const i=this,n=i._active,o=t.map((({datasetIndex:t,index:e})=>{const n=i._chart.getDatasetMeta(t);if(!n)throw new Error("Cannot find a dataset at index "+t);return{datasetIndex:t,element:n.data[e],index:e}})),s=!tt(n,o),a=i._positionChanged(o,e);(s||a)&&(i._active=o,i._eventPosition=e,i.update(!0))}handleEvent(t,e){const i=this,n=i.options,o=i._active||[];let s=!1,a=[];"mouseout"!==t.type&&(a=i._chart.getElementsAtEventForMode(t,n.mode,n,e),n.reverse&&a.reverse());const r=i._positionChanged(a,t);return s=e||!tt(a,o)||r,s&&(i._active=a,(n.enabled||n.external)&&(i._eventPosition={x:t.x,y:t.y},i.update(!0,e))),s}_positionChanged(t,e){const{caretX:i,caretY:n,options:o}=this,s=ws[o.position].call(this,t,e);return!1!==s&&(i!==s.x||n!==s.y)}}Rs.positioners=ws;var Es={id:"tooltip",_element:Rs,positioners:ws,afterInit(t,e,i){i&&(t.tooltip=new Rs({_chart:t,options:i}))},beforeUpdate(t,e,i){t.tooltip&&t.tooltip.initialize(i)},reset(t,e,i){t.tooltip&&t.tooltip.initialize(i)},afterDraw(t){const e=t.tooltip,i={tooltip:e};!1!==t.notifyPlugins("beforeTooltipDraw",i)&&(e&&e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",i))},afterEvent(t,e){if(t.tooltip){const i=e.replay;t.tooltip.handleEvent(e.event,i)&&(e.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:{beforeTitle:H,title(t){if(t.length>0){const e=t[0],i=e.chart.data.labels,n=i?i.length:0;if(this&&this.options&&"dataset"===this.options.mode)return e.dataset.label||"";if(e.label)return e.label;if(n>0&&e.dataIndex"filter"!==t&&"itemSort"!==t&&"external"!==t,_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]},zs=Object.freeze({__proto__:null,Decimation:Go,Filler:gs,Legend:xs,SubTitle:vs,Title:_s,Tooltip:Es});function Is(t,e,i){const n=t.indexOf(e);if(-1===n)return((t,e,i)=>"string"==typeof e?t.push(e)-1:isNaN(e)?null:i)(t,e,i);return n!==t.lastIndexOf(e)?i:n}class Fs extends qi{constructor(t){super(t),this._startValue=void 0,this._valueRange=0}parse(t,e){if($(t))return null;const i=this.getLabels();return((t,e)=>null===t?null:Ht(Math.round(t),0,e))(e=isFinite(e)&&i[e]===t?e:Is(i,t,K(e,t)),i.length-1)}determineDataLimits(){const t=this,{minDefined:e,maxDefined:i}=t.getUserBounds();let{min:n,max:o}=t.getMinMax(!0);"ticks"===t.options.bounds&&(e||(n=0),i||(o=t.getLabels().length-1)),t.min=n,t.max=o}buildTicks(){const t=this,e=t.min,i=t.max,n=t.options.offset,o=[];let s=t.getLabels();s=0===e&&i===s.length-1?s:s.slice(e,i+1),t._valueRange=Math.max(s.length-(n?0:1),1),t._startValue=t.min-(n?.5:0);for(let t=e;t<=i;t++)o.push({value:t});return o}getLabelForValue(t){const e=this.getLabels();return t>=0&&te.length-1?null:this.getPixelForValue(e[t].value)}getValueForPixel(t){const e=this;return Math.round(e._startValue+e.getDecimalForPixel(t)*e._valueRange)}getBasePixel(){return this.bottom}}function Bs(t,e,{horizontal:i,minRotation:n}){const o=Et(n),s=(i?Math.sin(o):Math.cos(o))||.001,a=.75*e*(""+t).length;return Math.min(e/s,a)}Fs.id="category",Fs.defaults={ticks:{callback:Fs.prototype.getLabelForValue}};class Vs extends qi{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,e){return $(t)||("number"==typeof t||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const t=this,{beginAtZero:e}=t.options,{minDefined:i,maxDefined:n}=t.getUserBounds();let{min:o,max:s}=t;const a=t=>o=i?o:t,r=t=>s=n?s:t;if(e){const t=Dt(o),e=Dt(s);t<0&&e<0?r(0):t>0&&e>0&&a(0)}o===s&&(r(s+1),e||a(o-1)),t.min=o,t.max=s}getTickLimit(){const t=this,e=t.options.ticks;let i,{maxTicksLimit:n,stepSize:o}=e;return o?i=Math.ceil(t.max/o)-Math.floor(t.min/o)+1:(i=t.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this,e=t.options,i=e.ticks;let n=t.getTickLimit();n=Math.max(2,n);const o=function(t,e){const i=[],{bounds:n,step:o,min:s,max:a,precision:r,count:l,maxTicks:c,maxDigits:h,includeBounds:d}=t,u=o||1,f=c-1,{min:g,max:p}=e,m=!$(s),x=!$(a),b=!$(l),_=(p-g)/(h+1);let y,v,w,M,k=Ct((p-g)/f/u)*u;if(k<1e-14&&!m&&!x)return[{value:g},{value:p}];M=Math.ceil(p/k)-Math.floor(g/k),M>f&&(k=Ct(M*k/f/u)*u),$(r)||(y=Math.pow(10,r),k=Math.ceil(k*y)/y),"ticks"===n?(v=Math.floor(g/k)*k,w=Math.ceil(p/k)*k):(v=g,w=p),m&&x&&o&&Lt((a-s)/o,k/1e3)?(M=Math.round(Math.min((a-s)/k,c)),k=(a-s)/M,v=s,w=a):b?(v=m?s:v,w=x?a:w,M=l-1,k=(w-v)/M):(M=(w-v)/k,M=At(M,Math.round(M),k/1e3)?Math.round(M):Math.ceil(M));const S=Math.max(It(k),It(v));y=Math.pow(10,$(r)?S:r),v=Math.round(v*y)/y,w=Math.round(w*y)/y;let P=0;for(m&&(d&&v!==s?(i.push({value:s}),v0?i:null;this._zero=!0}determineDataLimits(){const t=this,{min:e,max:i}=t.getMinMax(!0);t.min=X(e)?Math.max(0,e):null,t.max=X(i)?Math.max(0,i):null,t.options.beginAtZero&&(t._zero=!0),t.handleTickRangeOptions()}handleTickRangeOptions(){const t=this,{minDefined:e,maxDefined:i}=t.getUserBounds();let n=t.min,o=t.max;const s=t=>n=e?n:t,a=t=>o=i?o:t,r=(t,e)=>Math.pow(10,Math.floor(Pt(t))+e);n===o&&(n<=0?(s(1),a(10)):(s(r(n,-1)),a(r(o,1)))),n<=0&&s(r(o,-1)),o<=0&&a(r(n,1)),t._zero&&t.min!==t._suggestedMin&&n===r(t.min,0)&&s(r(n,-1)),t.min=n,t.max=o}buildTicks(){const t=this,e=t.options,i=function(t,e){const i=Math.floor(Pt(e.max)),n=Math.ceil(e.max/Math.pow(10,i)),o=[];let s=q(t.min,Math.pow(10,Math.floor(Pt(e.min)))),a=Math.floor(Pt(s)),r=Math.floor(s/Math.pow(10,a)),l=a<0?Math.pow(10,Math.abs(a)):1;do{o.push({value:s,major:Ns(s)}),++r,10===r&&(r=1,++a,l=a>=0?1:l),s=Math.round(r*Math.pow(10,a)*l)/l}while(ao?{start:e-i,end:e}:{start:e,end:e+i}}function Ys(t){const e={l:0,r:t.width,t:0,b:t.height-t.paddingTop},i={},n=[],o=[],s=t.getLabels().length;for(let c=0;ce.r&&(e.r=p.end,i.r=f),m.starte.b&&(e.b=m.end,i.b=f)}var a,r,l;t._setReductions(t.drawingArea,e,i),t._pointLabelItems=function(t,e,i){const n=[],o=t.getLabels().length,s=t.options,a=js(s),r=t.getDistanceFromCenterForValue(s.ticks.reverse?t.min:t.max);for(let s=0;s270||i<90)&&(t-=e),t}function Ks(t,e,i,n){const{ctx:o}=t;if(i)o.arc(t.xCenter,t.yCenter,e,0,_t);else{let i=t.getPointPosition(0,e);o.moveTo(i.x,i.y);for(let s=1;s{const n=Q(e.options.pointLabels.callback,[t,i],e);return n||0===n?n:""}))}fit(){const t=this,e=t.options;e.display&&e.pointLabels.display?Ys(t):t.setCenterPoint(0,0,0,0)}_setReductions(t,e,i){const n=this;let o=e.l/Math.sin(i.l),s=Math.max(e.r-n.width,0)/Math.sin(i.r),a=-e.t/Math.cos(i.t),r=-Math.max(e.b-(n.height-n.paddingTop),0)/Math.cos(i.b);o=Gs(o),s=Gs(s),a=Gs(a),r=Gs(r),n.drawingArea=Math.max(t/2,Math.min(Math.floor(t-(o+s)/2),Math.floor(t-(a+r)/2))),n.setCenterPoint(o,s,a,r)}setCenterPoint(t,e,i,n){const o=this,s=o.width-e-o.drawingArea,a=t+o.drawingArea,r=i+o.drawingArea,l=o.height-o.paddingTop-n-o.drawingArea;o.xCenter=Math.floor((a+s)/2+o.left),o.yCenter=Math.floor((r+l)/2+o.top+o.paddingTop)}getIndexAngle(t){return Wt(t*(_t/this.getLabels().length)+Et(this.options.startAngle||0))}getDistanceFromCenterForValue(t){const e=this;if($(t))return NaN;const i=e.drawingArea/(e.max-e.min);return e.options.reverse?(e.max-t)*i:(t-e.min)*i}getValueForDistanceFromCenter(t){if($(t))return NaN;const e=this,i=t/(e.drawingArea/(e.max-e.min));return e.options.reverse?e.max-i:e.min+i}getPointPosition(t,e){const i=this,n=i.getIndexAngle(t)-Mt;return{x:Math.cos(n)*e+i.xCenter,y:Math.sin(n)*e+i.yCenter,angle:n}}getPointPositionForValue(t,e){return this.getPointPosition(t,this.getDistanceFromCenterForValue(e))}getBasePosition(t){return this.getPointPositionForValue(t||0,this.getBaseValue())}getPointLabelPosition(t){const{left:e,top:i,right:n,bottom:o}=this._pointLabelItems[t];return{left:e,top:i,right:n,bottom:o}}drawBackground(){const t=this,{backgroundColor:e,grid:{circular:i}}=t.options;if(e){const n=t.ctx;n.save(),n.beginPath(),Ks(t,t.getDistanceFromCenterForValue(t._endValue),i,t.getLabels().length),n.closePath(),n.fillStyle=e,n.fill(),n.restore()}}drawGrid(){const t=this,e=t.ctx,i=t.options,{angleLines:n,grid:o}=i,s=t.getLabels().length;let a,r,l;if(i.pointLabels.display&&function(t,e){const{ctx:i,options:{pointLabels:n}}=t;for(let o=e-1;o>=0;o--){const e=n.setContext(t.getContext(o)),s=Be(e.font),{x:a,y:r,textAlign:l,left:c,top:h,right:d,bottom:u}=t._pointLabelItems[o],{backdropColor:f}=e;if(!$(f)){const t=Fe(e.backdropPadding);i.fillStyle=f,i.fillRect(c-t.left,h-t.top,d-c+t.width,u-h+t.height)}ee(i,t._pointLabels[o],a,r+s.lineHeight/2,s,{color:e.color,textAlign:l,textBaseline:"middle"})}}(t,s),o.display&&t.ticks.forEach(((e,i)=>{if(0!==i){r=t.getDistanceFromCenterForValue(e.value);const n=o.setContext(t.getContext(i-1));!function(t,e,i,n){const o=t.ctx,s=e.circular,{color:a,lineWidth:r}=e;!s&&!n||!a||!r||i<0||(o.save(),o.strokeStyle=a,o.lineWidth=r,o.setLineDash(e.borderDash),o.lineDashOffset=e.borderDashOffset,o.beginPath(),Ks(t,i,s,n),o.closePath(),o.stroke(),o.restore())}(t,n,r,s)}})),n.display){for(e.save(),a=t.getLabels().length-1;a>=0;a--){const o=n.setContext(t.getContext(a)),{color:s,lineWidth:c}=o;c&&s&&(e.lineWidth=c,e.strokeStyle=s,e.setLineDash(o.borderDash),e.lineDashOffset=o.borderDashOffset,r=t.getDistanceFromCenterForValue(i.ticks.reverse?t.min:t.max),l=t.getPointPosition(a,r),e.beginPath(),e.moveTo(t.xCenter,t.yCenter),e.lineTo(l.x,l.y),e.stroke())}e.restore()}}drawBorder(){}drawLabels(){const t=this,e=t.ctx,i=t.options,n=i.ticks;if(!n.display)return;const o=t.getIndexAngle(0);let s,a;e.save(),e.translate(t.xCenter,t.yCenter),e.rotate(o),e.textAlign="center",e.textBaseline="middle",t.ticks.forEach(((o,r)=>{if(0===r&&!i.reverse)return;const l=n.setContext(t.getContext(r)),c=Be(l.font);if(s=t.getDistanceFromCenterForValue(t.ticks[r].value),l.showLabelBackdrop){e.font=c.string,a=e.measureText(o.label).width,e.fillStyle=l.backdropColor;const t=Fe(l.backdropPadding);e.fillRect(-a/2-t.left,-s-c.size/2-t.top,a+t.width,c.size+t.height)}ee(e,o.label,0,-s,c,{color:l.color})})),e.restore()}drawTitle(){}}Zs.id="radialLinear",Zs.defaults={display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:Vi.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback:t=>t,padding:5}},Zs.defaultRoutes={"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"},Zs.descriptors={angleLines:{_fallback:"grid"}};const Qs={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Js=Object.keys(Qs);function ta(t,e){return t-e}function ea(t,e){if($(e))return null;const i=t._adapter,{parser:n,round:o,isoWeekday:s}=t._parseOpts;let a=e;return"function"==typeof n&&(a=n(a)),X(a)||(a="string"==typeof n?i.parse(a,n):i.parse(a)),null===a?null:(o&&(a="week"!==o||!Tt(s)&&!0!==s?i.startOf(a,o):i.startOf(a,"isoWeek",s)),+a)}function ia(t,e,i,n){const o=Js.length;for(let s=Js.indexOf(t);s=e?i[n]:i[o]]=!0}}else t[e]=!0}function oa(t,e,i){const n=[],o={},s=e.length;let a,r;for(a=0;a=0&&(e[l].major=!0);return e}(t,n,o,i):n}class sa extends qi{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,e){const i=t.time||(t.time={}),n=this._adapter=new ao._date(t.adapters.date);st(i.displayFormats,n.formats()),this._parseOpts={parser:i.parser,round:i.round,isoWeekday:i.isoWeekday},super.init(t),this._normalized=e.normalized}parse(t,e){return void 0===t?null:ea(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this,e=t.options,i=t._adapter,n=e.time.unit||"day";let{min:o,max:s,minDefined:a,maxDefined:r}=t.getUserBounds();function l(t){a||isNaN(t.min)||(o=Math.min(o,t.min)),r||isNaN(t.max)||(s=Math.max(s,t.max))}a&&r||(l(t._getLabelBounds()),"ticks"===e.bounds&&"labels"===e.ticks.source||l(t.getMinMax(!1))),o=X(o)&&!isNaN(o)?o:+i.startOf(Date.now(),n),s=X(s)&&!isNaN(s)?s:+i.endOf(Date.now(),n)+1,t.min=Math.min(o,s-1),t.max=Math.max(o+1,s)}_getLabelBounds(){const t=this.getLabelTimestamps();let e=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY;return t.length&&(e=t[0],i=t[t.length-1]),{min:e,max:i}}buildTicks(){const t=this,e=t.options,i=e.time,n=e.ticks,o="labels"===n.source?t.getLabelTimestamps():t._generate();"ticks"===e.bounds&&o.length&&(t.min=t._userMin||o[0],t.max=t._userMax||o[o.length-1]);const s=t.min,a=re(o,s,t.max);return t._unit=i.unit||(n.autoSkip?ia(i.minUnit,t.min,t.max,t._getLabelCapacity(s)):function(t,e,i,n,o){for(let s=Js.length-1;s>=Js.indexOf(i);s--){const i=Js[s];if(Qs[i].common&&t._adapter.diff(o,n,i)>=e-1)return i}return Js[i?Js.indexOf(i):0]}(t,a.length,i.minUnit,t.min,t.max)),t._majorUnit=n.major.enabled&&"year"!==t._unit?function(t){for(let e=Js.indexOf(t)+1,i=Js.length;e1e5*r)throw new Error(i+" and "+n+" are too far apart with stepSize of "+r+" "+a);const g="data"===o.ticks.source&&t.getDataTimestamps();for(d=f,u=0;dt-e)).map((t=>+t))}getLabelForValue(t){const e=this._adapter,i=this.options.time;return i.tooltipFormat?e.format(t,i.tooltipFormat):e.format(t,i.displayFormats.datetime)}_tickFormatFunction(t,e,i,n){const o=this,s=o.options,a=s.time.displayFormats,r=o._unit,l=o._majorUnit,c=r&&a[r],h=l&&a[l],d=i[e],u=l&&h&&d&&d.major,f=o._adapter.format(t,n||(u?h:c)),g=s.ticks.callback;return g?Q(g,[f,e,i],o):f}generateTickLabels(t){let e,i,n;for(e=0,i=t.length;e0?r:1}getDataTimestamps(){const t=this;let e,i,n=t._cache.data||[];if(n.length)return n;const o=t.getMatchingVisibleMetas();if(t._normalized&&o.length)return t._cache.data=o[0].controller.getAllParsedValues(t);for(e=0,i=o.length;e=t[r].pos&&e<=t[l].pos&&({lo:r,hi:l}=se(t,"pos",e)),({pos:n,time:s}=t[r]),({pos:o,time:a}=t[l])):(e>=t[r].time&&e<=t[l].time&&({lo:r,hi:l}=se(t,"time",e)),({time:n,pos:s}=t[r]),({time:o,pos:a}=t[l]));const c=o-n;return c?s+(a-s)*(e-n)/c:s}sa.id="time",sa.defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",major:{enabled:!1}}};class ra extends sa{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this,e=t._getTimestampsForTable(),i=t._table=t.buildLookupTable(e);t._minPos=aa(i,t.min),t._tableRange=aa(i,t.max)-t._minPos,super.initOffsets(e)}buildLookupTable(t){const{min:e,max:i}=this,n=[],o=[];let s,a,r,l,c;for(s=0,a=t.length;s=e&&l<=i&&n.push(l);if(n.length<2)return[{time:e,pos:0},{time:i,pos:1}];for(s=0,a=n.length;snot want to track." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Unikal" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Gəlişlər" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Brauzer" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Faiz" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Qonaqlar" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Əsas sözlər" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Əsas söz" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Rədd etmələr" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Təsviri" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Unikal gonaqlar" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Səhifəyə baxışlar" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Rədd cavabının miqdarı" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Bir gəlişə maksimal baxılan səhifə" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Həlli" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Tarix" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-be_BY.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-be_BY.mo deleted file mode 100644 index 4c1a7d7c..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-be_BY.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-be_BY.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-be_BY.po deleted file mode 100644 index 7392dccc..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-be_BY.po +++ /dev/null @@ -1,1530 +0,0 @@ -# -# Translators: -# Andre Braekling , 2009 -# FatCow http://www.fatcow.com, 2009 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Belarusian (Belarus) (http://www.transifex.com/piwik/wp-piwik/language/be_BY/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: be_BY\n" -"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "" - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Настройки" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Piwik статистика" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "Произошла ошибка" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik URL" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Авто token" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Следящий фильтр" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Уникальность" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Визитов" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Браузер" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Процентов" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Посетителей" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Ключевые слова" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Ключевое слово" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Отказов" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Описание" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Уникальных посетителей" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Просмотров страницы" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Количество отказов" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Макс. страниц просмтрено за один визит" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Разрешение" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Дата" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-cs_CZ.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-cs_CZ.mo deleted file mode 100644 index fa381ab7..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-cs_CZ.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-cs_CZ.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-cs_CZ.po deleted file mode 100644 index 6a9f8505..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-cs_CZ.po +++ /dev/null @@ -1,1528 +0,0 @@ -# -# Translators: -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Czech (Czech Republic) (http://www.transifex.com/piwik/wp-piwik/language/cs_CZ/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: cs_CZ\n" -"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "" - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_CH.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_CH.mo deleted file mode 100644 index c52e903e..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_CH.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_CH.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_CH.po deleted file mode 100644 index 157f58b7..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_CH.po +++ /dev/null @@ -1,1528 +0,0 @@ -# -# Translators: -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: German (Switzerland) (http://www.transifex.com/piwik/wp-piwik/language/de_CH/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: de_CH\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "" - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_DE.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_DE.mo deleted file mode 100644 index ccb2017c..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_DE.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_DE.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_DE.po deleted file mode 100644 index 294c4db4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-de_DE.po +++ /dev/null @@ -1,1530 +0,0 @@ -# -# Translators: -# André Bräkling , 2011 -# André Bräkling, 2015-2017 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:51+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: German (Germany) (http://www.transifex.com/piwik/wp-piwik/language/de_DE/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: de_DE\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s installiert." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "Als nächstes solltest Du eine Verbindung zu Piwik herstellen" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "%s aktualisiert auf %s." - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "Bitte überprüfe Deine Konfiguration" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Einstellungen" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Wichtig" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Piwik Statistiken" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "Konfiguriere WP-Piwik" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "Ein Fehler ist aufgetreten" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Support" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "Schummelst wohl?" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Neu laden" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Änderungen gespeichert" - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Vielen Dank für die Verwendung von WP-Piwik!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s wurde erfolgreich mit Piwik %s verbunden." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "Du verwendest WordPress %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "Du verwendest ein WordPress %s Blog Netzwerk (WPMU). WP-Piwik wird Deine Seiten als unterschiedliche Webseiten behandeln." - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "WP-Piwik %s konnte sich mit Deiner Konfiguration nicht mit Piwik verbinden. Bitte überprüfe die »Mit Piwik verbinden«-Sektion unten." - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "WP-Piwik %s konnte mit der vorliegenden Konfiguration keine Verbindung zu Piwik aufbauen. Beim Verbindungsaufbau ist folgender Fehler aufgetreten:
            %s" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "WP-Piwik %s muss zunächst mit Piwik verbunden werden. Bitte überprüfe die »Mit Piwik verbinden«-Sektion unten." - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Mit Piwik verbinden" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Zeige Statistiken" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "Aktiviere Tracking" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "Expertenkonfiguration" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "Danksagungen" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "WP-Piwik ist ein WordPress Plugin, um eine Auswahl von Piwik-Statistiken in Deinem WordPress Admin-Dashboard anzuzeigen, und um Deinen Piwik-Tracking-Code hinzuzufügen und zu konfigurieren. Um es zu verwenden, musst Du zunächst eine Piwik-Installation haben. Es gibt zwei Möglichkeiten: Betreibe Piwik entweder " - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "ein selbst-gehostetes Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "oder" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "ein cloud-gehostetes Piwik von InnoCraft" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "Weder cURL noch dopen sind verfügbar. Daher kann WP-Piwik sich weder mit der HTTP noch mit der InnoCraft Cloud verbinden." - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "Weitere Informationen" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "Du kannst zwischen drei Verbindungsmöglichkeiten wählen:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "Selbst-gehostet (HTTP API, Standard)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "Dies ist die Standard-Einstellung für ein selbst-gehostetes Piwik und sollte in den meisten Konfigurationen funktionieren. WP-Piwik verbindet sich mit Piwik über http(s)." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "Selbst-gehostet (PHP API)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "Wähle diese Option, wenn Dein selbst-gehostetes Piwik und WordPress auf dem gleichen Server laufen und Du den vollen Serverpfad zu Deiner Piwik-Installation kennst." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "Cloud-hosted (InnoCraft Cloud)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "Wenn Du ein cloud-hosted Piwik von InnoCraft verwendet, kannst Du einfach diese Option wählen." - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Piwik-Modus" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "Deaktiviert (WP-Piwik wird sich nicht mit Piwik verbinden)" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik URL" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "Gebe Deine Piwik-URL ein. Es handelt sich um die gleiche URL, die Du auch verwendest, um Dein Piwik zu öffnen, z.B. http://www.example.com/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "Piwik Pfad" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "Gib den Dateipfad zu Deiner Piwik-Installation an, z.B. /var/www/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "Piwik-Subdomain" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "Gib Deine InnoCraft Cloud Subdomain an. Sie ist Teil der URL: https://SUBDOMAIN.innocraft.cloud." - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Auth Token" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "Gib hier Dein Piwik Auth Token an. Es ist ein alphanumerische Code wie 0a1b2c34d56e78901fa2bc3d45678efa." - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "Siehe %sdie WP-Piwik FAQ%s" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Auto-Konfiguration" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "Aktiviere diesen Haken, um Dein Blog über seine URL automatisch aus Deinen Piwik-Seiten auszuwählen. Wenn Dein Blog bisher nicht zu Piwik hinzugefügt wurde, wird WP-Piwik eine neue Seite hinzufügen." - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "WP-Piwik %s konnte keine Seiten finden, für die zumindest View-Zugriff eingerichtet ist:
            %s" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "Ermittelte Seite" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "Wähle die Seite" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "Piwik Standard-Datum" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Heute" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Gestern" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Aktueller Monat" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Letzter Monat" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Aktuelle Woche" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Letzte Woche" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "Default-Datum, das auf der Statistik-Seite gezeigt wird." - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "Zeige SEO-Daten" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "Zeige SEO-Ranking-Daten auf der Statistiken-Seite." - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "Langsam!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "E-Commerce Daten anzeigen" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "Zeige E-Commerce Daten auf der Statistik-Seite an." - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "Dashboard Übersicht" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "Deaktiviert" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "Letzte 30 Tage" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "Aktiviere das WP-Piwik Dashboard Widget "Übersicht"." - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "Dashboard-Graph" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "Aktiviere das WP-Piwik Dashboard Widget "Graph"." - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "Dashboard SEO" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "Aktiviere das WP-Piwik Dashboard Widget "SEO"." - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "Dashboard E-Commerce" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "Aktiviere das WP-Piwik Dashboard Widget "E-Commerce"." - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "Zeige einen Graphen in der WordPress Toolbar" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "Zeige einen Besuchergraph der letzten 30 Tage in der WordPress' Toolbar." - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "Zeige Statistiken für" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Wähle diejenigen Nutzerrollen, die sich die Statistiken ansehen dürfen." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "Zeige Beitrags-Statistiken" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "Zeige Statistiken zu einzelnen Beiträgen auf der Bearbeiten-Seite." - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "Piwik-Verlinkung" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "Zeigt einen Shortcut zu Piwik an." - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "Anzeigename für WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "Der Name, mit dem das Plugin in WordPress angezeigt wird." - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "Aktiviere Shortcodes" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "Aktiviere Shortcodes innerhalb von Artikeln und Seiten." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "Du kannst zwischen vier Tracking-Code-Varianten wählen:" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "WP-Piwik wird den Tracking-Code nicht hinzufügen. Benutze dies, wenn Du den Tracking-Code direkt in Deinem Template oder über ein anderes Plugin einfügen willst." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "Standard-Tracking" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "WP-Piwik verwendet den Standard Tracking-Code von Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "Nutze js/index.php" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "Du kannst diesen Tracking-Code wählen, um einen minimierten Proxy-Code auszuliefern und dabei zu vermeiden, dass die Dateien mit dem Namen piwik.js oder piwik.php verwendet werden." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "Siehe %sReadme-Datei%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "Verwende Proxy-Skript" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "Verwende diesen Tracking-Code, um die URL zu Deinem Piwik-Sever nicht offenzulegen." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "Siehe %sPiwik FAQ%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "Manuelle Eingabe" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "Gebe manuell Deinen eigenen Tracking-Code ein. Du kannst eine der vorhergehenden Optionen nutzen, Deinen Tracking-Code vorkonfigurieren und abschließend auf die manuelle Bearbeitung wechseln." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "Verwende den Platzhalter {ID}, um Piwiks Site-ID einzufügen." - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "Tracking-Code einfügen" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "Tracking-Code" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "Position des JavaScript-Codes" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "Fußbereich" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "Kopfbereich" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "Wähle, ob der JavaScript-Code im Footer oder im Header eingefügt werden soll." - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "Noscript-Code" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "Füge <noscript> hinzu" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "Fügt den <noscript>-Code im Footer ein." - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "Im Proxy-Modus deaktiviert." - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "Füge rec-Parameter zum noscript Code hinzu" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "Aktiviere das Tracking für Besucher ohne JavaScript (nicht empfohlen)." - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "Aktiviere Content-Tracking" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "Tracke alle Content-Bereiche" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "Tracke nur sichtbare Content-Bereiche" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "Das Content-Tracking erlaubt es Dir, Interaktionen mit dem Inhalt einer Webseite oder -anwendung zu tracken." - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "Siehe %sPiwik-Dokumentation%s." - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "Tracke Suchanfragen" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "Nutze Piwiks Site Search Funktion, um interne Suchen zu tracken." - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "404-Tracking" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "WP-Piwik kann automatisch eine eigene Kategorie für 404-Seiten hinzufügen." - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "Notiz bei neuen Posts von folgenden Typen" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "Zeige Custom-Variables-Box" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "Zeige eine Eingabebox für "custom variables" auf der Seite zum Bearbeiten von Posts." - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "Füge weitere Dateiendungen für das Download-Tracking hinzu" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "Füge Dateiendungen zum Download-Tracking hinzu. Trenne mehrere Erweiterung durch einen senkrechten Strich (|)." - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "Cookies deaktivieren" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "Schalte alle Tracking-Cookies für Besucher ab." - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "Cookie-Lebensdauer beschränken" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "Du kannst die Cookie-Lebenszeit begrenzen, um Deine Besucher nicht länger als notwendig zu tracken." - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "Besucher-Timeout (Sekunden)" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "Session-Timeout (Sekunden)" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "Referral-Timeout (Sekunden)" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "Admin-Seiten tracken" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "Aktivieren, um Nutzer auf Admin-Seiten zu zählen (bitte den Tracking Filter entsprechend konfigurieren)." - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Tracking-Filter" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "Wähle diejenigen Nutzerrollen, die Du nicht erfassen willst." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "Tracke Subdomains innerhalb der gleichen Webseite" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "Fügt ein *.-Präfix zur Cookie Domain hinzu." - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "Werte Subdomains nicht als ausgehenden Link" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "Fügt ein *.-Präfix zur getrackten Domain hinzu." - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "Aktiviere Cross-Domain-Verlinkung" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "Wenn aktiviert, stellt die Funktion sicher, dass die gleiche Besucher-ID für den gleichen Besucher über mehrere Domains hinweg benutzt wird. Dies funktioniert nur, wenn die Funktion aktiviert ist, da die Besucher-ID in einem Cookie gespeichert wird und somit nicht auf einer anderen Domain gelesen werden kann. Über diese Funktion wird der URL der Parameter \"pk_vid\" hinzugefügt, der die Besucher-ID enthält, sobald ein Nutzer auf eine URL klickt, die zu Deinen Domains gehört. Damit es funktioniert, müssen die als lokal zu betrachtenden Domains auch in den Piwik Webseiten-Einstellungen konfiguriert sein. Die Funktion erfordert zumindest Piwik 3.0.2." - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "Tracke RSS-Feeds" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "Aktivieren, um Beiräge im Feed via Tracking-Pixel zu zählen." - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "Links in RSS-Feeds als Kampagne tracken" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "Dies fügt einen Piwik-Kampagnen-Parameter zu den RSS-Feed-Links hinzu." - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "RSS-Feed Kampagne" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "Schlüsselwort: Name des Beitrags." - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "Aktiviere Heartbeat-Timer" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "Aktiviere den Heratbeat-Timer, um genauere Besuchszeiten zu erhalten, indem HTTP-Ping-Anfragen gesendet werden, solange die Seite geöffnet ist. Gib den Zeitabstand zwischen den Ping-Anfragen in Sekunden (Piwik-Default: 15) an oder trage 0 zum deaktivieren ein. Hinweis: Dadurch entsteht eine Vielzahl zusätzlicher HTTP-Anfragen an Deine Seite." - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "Nutzer-ID Tracking" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "WP User ID" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "E-Mail-Adresse" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Benutzername" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "Anzeigename (nicht empfohlen)" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "Wenn Nutzer in WordPress eingeloggt ist, tracked WP-Piwik deren "User ID". Du kannst wählen, welches Feld des Nutzerprofils dabei als "User ID" verwendet wird. Wenn die Funktion aktiviert wird, empfiehlt sich das Tracking auf Basis der E-Mail-Adresse." - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "Normalerweise solltest Du diese Einstellungen nicht ändern müssen. Solltest Du hier doch etwas ändern wollen, solltest Du wissen was Du tust oder dies auf Anleitung eines Experten tun." - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "Cache einschalten" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "Cache API-Anfragen, die keine heutigen Werte enthalten, für eine Woche." - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "HTTP-Verbindung über" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "fopen" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "Wähle, ob WP-Piwik cURL oder dopen verwenden soll, um im HTTP oder Cloud Modus mit Piwik zu verbinden." - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "HTTP-Methode" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "POST" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "GET" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "Wähle, ob WP-Piwik POST oder GET im HTTP oder Cloud Modus verwenden soll." - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "Zeitlimit deaktivieren" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "Verwende set_time_limit(0) falls die Statistik-Seite einen Timeout erzeugt." - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "Verbindungs-Timeout" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "SSL Peer-Verifikation deaktivieren" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "Nicht empfohlen" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "SSL-Host-Verifizierung deaktivieren" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "User Agent" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "Verwende den PHP-Standard User-Agent" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "leer" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "Lege einen spezifischen User-Agent fest" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "Spezifischer User-Agent" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "Aktiviere DNS-Prefetch" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "Siehe %sPiwik Blog%s." - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "Fügt einen DNS-Prefetch-Tag hinzu." - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "data-cfasync=false einfügen" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "Siehe %sdie CloudFlare Knowledge Base%s." - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "Füge data-cfasync=false zum Script-Tag hinzu. Damit wird z.B. Rocket Loader aufgefordert, das Skript zu ignorieren." - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "CDN URL" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "CDN URL (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "Zwinge Piwik, ein bestimmtes Protokoll zu verwenden" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "Deaktiviert (Standard)" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "http" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "https (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "Wähle aus, ob Du Piwik ausdrücklich zwingen willst, HTTP oder HTTPS zu verwenden. Funktioniert nicht mit einer CDN URL." - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "Update-Hinweis" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "Immer anzeigen, wenn WP-Piwik aktualisiert wurde" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "Immer anzeigen, wenn WP-Piwik aktualisiert und dabei die Konfiguration geändert wurde" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "Wähole aus, ob Du einen Hinweis erhalten möchtest, wenn WP-Piwik aktualisiert wurde." - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "Lege alle Dateiendungen für das Download-Tracking fest" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "Ersetze Piwiks Standard-Dateiendungen für das Download-Tracking, getrennt durch einen senkrechten Strich (|). Lasse dieses Feld frei, um die Standard-Einstellungen von Piwik zu erhalten." - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "Lege die Klassen fest, die als Download behandelt werden sollen." - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "Lege die Klassen fest, die (zusätzlich zu piwik_download) als Download behandelt werden sollen. Trenne mehrere Klassen durch einen senkrechten Strich (|). Lasse dieses Feld frei, um die Standard-Einstellungen von Piwik zu erhalten." - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "Siehe %sPiwik JavaScript Tracking Client Referenz%s." - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "Lege die Klassen fest, die als ausgehender Link behandelt werden sollen" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "Lege die Klassen fest, die (zusätzlich zu piwik_link) als ausgehender Link behandelt werden sollen. Trenne mehrere Klassen durch einen senkrechten Strich (|). Lasse dieses Feld frei, um die Standard-Einstellungen von Piwik zu erhalten." - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "Spenden" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Wenn Dir WP-Piwik gefällt, kannst Du die weitere Entwicklung mit einer Spende fördern:" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "Meine Wunschliste bei Amazon.de" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "Bitte denke daran, eine Kompatibilitätsbewertung abzugeben:" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "Vielen Dank für eure Spenden" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "das Piwik-Team selbst" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr " und allen, die WP-Piwik flattrn" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "Graphen erstellt mit jqPlot (Lizenz: GPL 2.0 and MIT) und jQuery Sparklines (Lizenz: New BSD License)." - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "Vielen Dank" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "für eure Übersetzungsarbeit" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "Vielen Dank an alle Nutzer, die mir Mails mit Kritik, Lob, Featurewünsche und Bugmeldungen senden. Ihr helft mir dabei, WP-Piwik viel besser zu machen." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "Vielen Dank an Dich für die Nutzung meines Plugins. Es ist das größte Lob, wenn mein Code tatsächlich benutzt wird!" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "Der beste Platz, um Hilfe zu bekommen:" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "WP-Piwik Support-Forum" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "Fehlersuche" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "Entweder allow_url_fopen muss aktiviert oder cURL muss verfügbar sein:" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "cURL ist" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "nicht" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "verfügbar" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "allow_url_fopen ist" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "aktiviert" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "wird verwendet." - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "Die ermittelte Piwik-Basis-URL ist" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "Tools" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "Testskript ausführen" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "Sitebrowser" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "Cache leeren" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "Bist Du Dir sicher, dass Du alle Einstellungen löschen willst?" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "WP-Piwik zurücksetzen" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "Die letzten Support-Beiträge auf WordPress.org" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "Einstellungen gelöscht (außer Verbindungsdaten)" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "Cache geleert." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "Seite" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "Seiten" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "Noch keine Seite konfiguriert." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "Blog ID" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Titel" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "URL" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "Seiten-ID (Piwik)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "Seite noch nicht erstellt." - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "Statistiken" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "Derzeit gezeigte Statistiken:" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "Keine Verbindung zu" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "realpath() gibt false zurück" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "Die Klasse Piwik\\FrontController existiert nicht." - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "Die Klasse Piwik\\API\\Request existiert nicht." - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "Piwik Custom Variables" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "Name" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "Wert" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "Definiere custom variables für einen Seitenaufruf." - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Piwik-Fehler" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Unique" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Besuche" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "Aufrufe" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "Aktionen" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "Keine Daten vorhanden." - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "heute" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "aktueller Monat" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "letzter Monat" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "aktuelle Woche" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "letzte Woche" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "gestern" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "Woche" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "letzte 30 Tage" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "letzte 12" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "Browser-Details" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Browser" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Prozent" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "Andere" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "Browser" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Besucher" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "Der Graph zeigt die Werte aus der Besucher-Tabelle (Besucher / Unique / Absprünge). Die rote Linie zeigt eine lineare Trendlinie (Unique)." - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Länder" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "Land" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "E-Commerce" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "Conversions" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "Besucher Conversions" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "Umsatz" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "Konversionsrate" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "Conversions (neue Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "Conversions (neue Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "Umsatz (neue Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "Konversionsrate (neue Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "Conversions (wiederkehrende Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "Conversions (wiederkehrende Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "Umsatz (wiederkehrende Besucher)" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "Konversionsrate (wiederkehrende Besucher))" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "Shortcut" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "E-Commerce Artikel" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "Bezeichnung" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "Anzahl" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "Bestellungen" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "Ø Preis" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "Ø Anzahl" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "E-Commerce Artikel-Kategorien" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Keywords" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "Seitensuche" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Keyword" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "Anfragen" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Absprünge" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Übersicht" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "Dashboard" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Eindeutige Besucher" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Page Views" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "Verbrachte Zeit" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Absprungrate" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "Zeit/Besuch" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Max. Seiten/Besuch" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "Seiten" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "Seite" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "Plugins" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "Plugin" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "Min. Zeit zur Generierung" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "Max. Zeit zur Generierung" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "Referrer" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "Auflösungen" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Auflösung" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "Betriebssystem-Details" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "Betriebssystem" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "Betriebssysteme" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Datum" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "Seitenansichten" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "WP-Piwik benötigt zumindest PHP 5.3. Du verwendest die veraltete Version %s. Bitte aktualisiere PHP um WP-Piwik zu nutzen." diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el.mo deleted file mode 100644 index d672b202..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el.po deleted file mode 100644 index cfef717d..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el.po +++ /dev/null @@ -1,1531 +0,0 @@ -# -# Translators: -# André Bräkling , 2011 -# Vasilis Lourdas, 2016-2017 -# Vasilis Lourdas, 2015 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-15 18:39+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Greek (http://www.transifex.com/piwik/wp-piwik/language/el/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: el\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "Το %s %s εγκαταστάθηκε." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "Στη συνέχεια συνδεθείτε με Piwik" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "Το %s ενημερώθηκε σε %s." - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "Παρακαλώ επαληθεύστε τη διαμόρφωση" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Ρυθμίσεις" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Σημαντικό" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Piwik Στατιστικά" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "Παραμετροποίηση του WP-Piwik" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "Παρουσιάστηκε σφάλμα" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Υποστήριξη" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "Κλέβεις, έτσι;" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Επαναφόρτωση" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Οι αλλαγές αποθηκεύθηκαν." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Ευχαριστούμε που χρησιμοποιείτε το WP-Piwik!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "Το WP-Piwik %s συνδέθηκε με επιτυχία στο Piwik %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "Τρέχετε το WordPress %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "Τρέχετε ένα δίκτυο ιστολογίων (WPMU) WordPress %s. Το WP-Piwik θα χειρίζεται όλους τους ιστοτόπους σας ως διαφορετικούς." - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "Το WP-Piwik %s δεν μπόρεσε να συνδεθεί με το Piwik χρησιμοποιώντας τις ρυθμίσεις σας. Δείτε την παρακάτω παράγραφο %raquo;Σύνδεση με το Piwik«." - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "Το WP-Piwik δεν ήταν δυνατό να συνδεθεί με το Piwik χρησιμοποιώντας την παραμετροποίησή σας. Κατά την σύνδεση, συνέβη το εξής σφάλμα:
            %s" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "Το WP-Piwik %s πρέπει να συνδεθεί πρώτα με το Piwik. Ελέγξτε το τμήμα »Σύνδεση με το Piwik« παρακάτω." - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Σύνδεση με το Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Εμφάνιση στατιστικών" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "Ενεργοποίηση παρακολούθησης" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "Ρυθμίσεις για προχωρημένους" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "Συντελεστές" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "Το WP-Piwik είναι ένα πρόσθετο για το WordPress για να εμφανίζει μια επιλογή από στατιστικά του Piwik στον πίνακα διαχείρισης του WordPress και για να προσθέτετε και παραμετροποιείτε τον κώδικα παρακολούθησης του Piwik. Αν δεν έχετε ήδη κάποια εγκατάσταση του Piwik, έχετε δύο απλές επιλογές: να χρησιμοποιήσετε είτε" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "ένα Piwik στημένο τοπικά" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "ή" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "ένα Piwik στημένο στο σύννεφο από την InnoCraft" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "Ούτε το cURL ούτε η fopen είναι διαθέσιμα. Έτσι, το WP-Piwik δεν μπορεί να χρησιμοποιήσει το HTTP API και να συνδεθεί με το σύννεφο InnoCraft." - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "Περισσότερες πληροφορίες" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "Μπορείτε να επιλέξετε μεταξύ των τριών τρόπων σύνδεσης:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "Φιλοξενία σε εσάς (HTTP API, εξ' ορισμού)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "Αυτή είναι η προκαθορισμένη επιλογή για Piwik που φιλοξενείται σε εσάς και αναμένεται να δουλέψει για τις περισσότερες εγκαταστάσεις. Το WP-Piwik θα συνδεθεί με το Piwik με χρήση http(s)." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "Φιλοξενία σε εσάς (PHP API)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "Επιλέξτε αυτή την επιλογή, αν το Piwik που φιλοξενείται σε εσάς και το WordPress εκτελούνται στον ίδιο διακομιστή και γνωρίζετε την πλήρη διαδρομή για το στιγμιότυπο του Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "Στημένο στο σύννεφο (Σύννεφο InnoCraft)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Κατάσταση του Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "Ανενεργό (το WP-Piwik δεν συνδέεται με το Piwik)" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik URL" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "Εισάγετε τη διεύθυνση URL του Piwik. Αυτή είναι η ίδια διεύθυνση URL που χρησιμοποιείτε για να προσπελάσετε το στιγμιότυπο Piwik σας, πχ. http://www.example.com/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "Διαδρομή του Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "Εισάγετε την πλήρη διαδρομή για το στιγμιότυπο του Piwik σας, πχ. /var/www/piwik." - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "Υποόνομα χώρου Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Σύμβολο γνησιότητας" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "Εισάγετε εδώ τον κωδικό πιστοποίησης του Piwik. Είναι ένας αλφαριθμητικός κωδικός σαν το 0a1b2c34d56e78901fa2bc3d45678efa." - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "Δείτε τις %sΣυχνές ερωταπαντήσεις του WP-Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Αυτόματη ρύθμιση" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "Επιλέξτε αυτό για να γίνεται αυτόματη επιλογή του ιστολογίου σας από τους ιστοτόπους σας του Piwik με τη διεύθυνση URL. Αν το ιστολόγιό σας δεν έχει προστεθεί ακόμη, το WP-Piwik θα προσθέσει αυτόματα ένα νέο ιστοτόπο." - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "Ιστοτόπος που εντοπίστηκε" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "Επιλέξτε ιστοτόπο" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "Προκαθορισμένη ημερομηνία Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Σήμερα" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Εχθές" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Τρέχων μήνας" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Προηγούμενος μήνας" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Τρέχουσα εβδομάδα" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Προηγούμενη εβδομάδα" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "Προεπιλεγμένη ημερομηνία που αναγράφεται στη σελίδα των στατιστικών." - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "Εμφάνιση των δεδομένων SEO" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "Εμφάνιση των δεδομένων κατάταξης SEO στη σελίδα στατιστικών." - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "Αργό!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "Σύνοψη πίνακα" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "Ανενεργό" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "Προηγούμενες 30 ημέρες" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "Ενεργοποίηση της "Σύνοψης" του πίνακα του γραφικού συστατικού WP-Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "Γράφημα πίνακα" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "Ενεργοποίηση του "γραφικού" συστατικού πίνακα του WP-Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "SEO πίνακα" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "Ενεργοποίηση του γραφικού συστατικού "SEO" του πίνακα ελέγχου του WP-Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "Εμφάνιση γραφήματος στην μπάρα εργαλείων του WordPress" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "Εμφάνιση του γραφήματος επισκέψεων για τις τελευταίες 30 ημέρες στην μπάρα εργαλείων του WordPress." - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "Εμφάνιση στατιστικών σε" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Επιλέξτε τους ρόλους χρηστών, οι οποίοι επιτρέπεται να βλέπουν τα στατιστικά." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "Εμφάνιση στατιστικών ανά καταχώρηση" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "Εμφάνιση στατιστικών για μεμονωμένες καταχωρήσεις στη σελίδα διαχείρισης της καταχώρησης." - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "Συντόμευση Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "Εμφάνιση μιας συντόμευσης προς Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "Εμφανιζόμενο όνομα WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "Το όνομα του πρόσθετου που θα εμφανίζεται στο WordPress." - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "Ενεργοποίηση σύντομων κωδικών" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "Ενεργοποίηση σύντομων κωδικών στο περιεχόμενο καταχωρήσεων ή σελίδων." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "Μπορείτε να επιλέξετε μεταξύ τεσσάρων καταστάσεων κωδικών παρακολούθησης:" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "Το WP-Piwik δεν θα προσθέσει τον κώδικα παρακολούθησης. Χρησιμοποιήστε το αυτό, αν θέλετε να προσθέτετε τον κώδικα παρακολούθησης στα αρχεία προτύπων ή χρησιμοποιείτε κάποιο άλλο πρόσθετο για την προσθήκη του κώδικα." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "Προκαθορισμένη παρακολούθηση" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "Το WP-Piwik θα χρησιμοποιήσει τον προκαθορισμένο κώδικα παρακολούθησης του Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "Χρήση του js/index.php" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "Μπορείτε να επιλέξετε αυτό τον κώδικα παρακολούθησης, για να παρέχετε ένα ελαχιστοποιημένο σε μέγεθος κώδικα μεσολαβητή και να αποφύγετε την χρήση των αρχείων piwik.js ή piwik.php." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "Δείτε το %sαρχείο readme%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "Χρήση σεναρίου διαμεσολαβητή" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "Χρησιμοποιήστε αυτό τον κώδικα παρακολούθησης για να μην αποκαλύπτετε τη διεύθυνση URL του Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "Δείτε τις %sσυχνές ερωταπαντήσεις του Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "Εισάγετε χειροκίνητα" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "Εισάγετε μόνοι σας τον κώδικα παρακολούθησης. Μπορείτε να επιλέξετε μία από τις προηγούμενες επιλογές, να προρυθμίσετε τον κώδικά σας και τέλος να μεταβείτε σε κατάσταση επεξεργασίας." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "Χρήση του κωδικού (ID) για την προσθήκη του αναγνωριστικού ιστοτόπου του Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "Προσθήκη κώδικα παρακολούθησης" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "Κώδικας παρακολούθησης" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "Θέση του κώδικα JavaScript" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "Υποσέλιδο" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "Κεφαλίδα" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "Επιλέξτε αν ο κώδικας JavaScript θα προστίθεται στο υποσέλιδο ή την κεφαλίδα." - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "Κώδικας noscript" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "Προσθήκη του <noscript>" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "Προσθέτει τον κώδικα <noscript> στο υποσέλιδο." - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "Απενεργοποιημένο σε κατάσταση διαμεσολαβητή." - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "Προσθήκη παραμέτρου rec στον κώδικα noscript" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "Να ενεργοποιηθεί η παρακολούθηση για επισκέπτες χωρίς JavaScript (δεν προτείνεται)." - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "Ενεργοποίηση παρακολούθησης περιεχομένου" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "Να παρακολουθούνται όλα τα μπλοκ περιεχομένου" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "Να παρακολουθούνται μόνο τα ορατά μπλοκ" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "Η παρακολούθηση περιεχομένου σας επιτρέπει να παρακολουθείτε την αλληλεπίδραση με το περιεχόμενο μιας ιστοσελίδας ή εφαρμογής." - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "Δείτε την %sτεκμηρίωση του Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "Παρακολούθηση της αναζήτησης" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "Να γίνεται χρήση του χαρακτηριστικού των προχωρημένων Αναλυτικών Αναζήτησης Ιστοτόπου." - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "Παρακολούθηση 404" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "Το WP-Piwik μπορεί να προσθέτει αυτόματα μια 404-κατηγορία για να παρακολουθούνται οι επισκέψεις 404." - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "Εμφάνιση του κουτιού προσαρμοσμένων μεταβλητών" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "Να εμφανίζεται ένα κουτί επεξεργασίας "προσαρμοσμένων μεταβλητών" στη σελίδα επεξεργασίας της καταχώρησης." - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "Προσθήκη νέων τύπων αρχείων για την παρακολούθηση των κατεβασμάτων" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "Προσθήκη επεκτάσεων αρχείων για την παρακολούθηση των κατεβασμάτων, χωρισμένα με τον χαρακτήρας της κάθετης μπάρας (|)." - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "Απενεργοποίηση των cookies" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "Απενεργοποίηση όλων των cookies παρακολούθησης για ένα επισκέπτη." - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "Περιορισμός του χρόνου ζωής των cookies" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "Μπορείτε να περιορίσετε το χρονικό όριο ισχύος των cookies για να μην παρακολουθείτετους χρήστες σας για ένα συγκεκριμένο χρονικό διάστημα όπως απαιτείται." - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "Χρόνος λήξης επισκεπτών (δευτερόλεπτα)" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "Χρόνος λήξης συνόδου (δευτερόλεπτα)" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "Χρονικό όριο αναφορέα (δευτερόλεπτα)" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "Παρακολούθηση των σελίδων διαχείρισης" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "Ενεργοποιήστε για να παρακολουθείτε τους χρήστες στις σελίδες διαχείρισης (θυμηθείτε να ρυθμίσετε ανάλογα το φίλτρο παρακολούθησης)." - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Φίλτρο Παρακολούθησης" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "Επιλέξτε το ρόλο χρήστη, τον οποίο δε θέλετε να παρακολουθήσετε." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "Να παρακολουθούνται τα υπο-ονόματα χώρου στον ίδιο ιστοτόπο" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "Προσθέτει την κατάληξη *.-prefix στα cookies ονομάτων χώρου." - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "Να μην μετρώνται τα υπο-ονόματα χώρου ως εξωτερικοί σύνδεσμοι" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "Προσθέτει το πρόθεμα *.-prefix στον ιστοτόπο που παρακολουθείται." - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "Παρακολούθηση των δεδομένων ροών RSS" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "Ενεργοποίηση της παρακολούθησης των καταχωρήσεων στις ροές μέσω ενός pixel παρακολούθησης." - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "Παρακολούθηση των συνδέσμων ροών RSS ως καμπάνια" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "Καμπάνια ροών RSS" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "Λέξη κλειδί: όνομα καταχώρησης." - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "Εμφάνιση χρονομετρητή παλμού" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "Ενεργοποίηση ενός μετρητή παλμού για την λήψη ακριβέστερων μετρήσεων επισκέψεων με την αποστολή περιοδικών αιτήσεων HTTP ping όσο ο ιστοτόπος είναι σε λειτουργία. Εισάγετε το χρόνο μεταξύ των ping σε δευτερόλεπτα (προκαθορισμένο για το Piwik: 15 δευτερόλεπτα) για να το ενεργοποιήσετε ή 0 για απενεργοποίηση του χαρακτηριστικού αυτού. Σημείωση: Το χαρακτηριστικό αυτό θα προκαλεί αρκετές πρόσθετες αιτήσεις HTTP στον ιστοτόπο σας." - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "Αναγνωριστικό ανίχνευσης χρήστη" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "Αναγνωριστικό χρήστη WP" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "Διεύθυνση ηλ. ταχυδρομείου" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Όνομα χρήστη" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "Εμφανιζόμενο όνομα (δεν προτείνεται!)" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "Όταν ένας χρήστης κάνει είσοδο στο WordPress, παρακολουθήστε το "Αναγνωριστικό Χρήστη" του. Μπορείτε να επιλέξετε ποιο πεδίο από το προφίλ χρήστη θα χρησιμοποιείται ως το "Αναγνωριστικό χρήστη". Όταν είναι ενεργό, προτείνεται η παρακολούθηση βάσει της διεύθυνσης ηλ. ταχυδρομείου." - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "Συνήθως, δε χρειάζεται να αλλάξετε αυτές τις ρυθμίσεις. Αν επιθυμείτε να το κάνετε, θα πρέπει να γνωρίζετε τι κάνετε ή να πάρετε τη γνώμη ενός ειδικού." - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "Ενεργοποίηση λανθάνουσας μνήμης" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "Οι κλήσεις API, που δεν περιέχουν τις σημερινές τιμές, να μπαίνουν στη λανθάνουσα μνήμη για μια εβδομάδα." - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "Σύνδεση HTTP μέσω" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "fopen" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "Μέθοδος HTTP" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "POST" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "GET" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "Απενεργοποίηση χρονικού ορίου" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "Χρήση της set_time_limit(0) αν η σελίδα στατιστικών προκαλέσει υπέρβαση χρονικού ορίου." - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "Χρονικό όριο" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "Απενεργοποίηση της ομότιμης επαλήθευσης SSL" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "δε συνίσταται" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "Απενεργοποίηση της επαλήθευσης του διακομιστή SSL" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "Πρόγραμμα πελάτης" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "Χρήση του προκαθορισμένου πράκτορα χρήστη της PHP" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "κενό" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "Ορισμός συγκεκριμένου πράκτορα χρήστη" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "Συγκεκριμένος πράκτορας χρήστη" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "Προσθήκη του data-cfasync=false" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "Διεύθυνση URL του CDN" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "Διεύθυνση URL του CDN (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "Να χρησιμοποιεί το Piwik συγκεκριμένο πρωτόκολλο" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "Απενεργοποιημένο (εξ' ορισμού)" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "http" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "https (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "Επιλέξτε αν θέλετε να υποχρεώσετε το Piwik να χρησιμοποιεί HTTP ή HTTPS. Δεν δουλεύει με διεύθυνση URL για CDN." - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "Σημείωση αναβάθμισης" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "Εμφάνιση πάντα αν το WP-Piwik ενημερώνεται" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "Εμφάνιση μόνο αν το WP-Piwik ενημερώνεται και οι ρυθμίσεις του έχουν αλλάξει" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "Επιλέξτε αν επιθυμείτε να λαμβάνετε ενημέρωση για το αν το WP-Piwik ενημερώνεται." - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "Ορίστε όλους τους τύπους αρχείων για την παρακολούθηση των μεταφορτώσεων" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "Αντικαταστήστε τους προκαθορισμένους τύπους αρχείων για την παρακολούθηση μεταφορτώσεων, χωρισμένους με μια κάθετη μπάρα (|). Αφήστε το κενό για να κρατηθούν οι προκαθορισμένες ρυθμίσεις του Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "Δωρήστε" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Αν σας αρέσει το WP-Piwik, μπορείτε να στηρίξετε την ανάπτυξή του με μια δωρεά:" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "Η λίστα επιθυμίας μου στο Amazon.de" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "Παρακαλούμε μην ξεχάσετε να ψηφίσετε για την συμβατότητα στο" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "Ευχαριστώ για τις δωρεές" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "η ομάδα του Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr " και όλοι οι άνθρωποι που το επαινούν" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "Ευχαριστώ πολύ" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "για τη μετάφραση" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "Σας ευχαριστώ πολύ, όλους τους χρήστες που μου στείλατε μηνύματα που περιέχουν κριτική, επιδοκιμασία, αιτήματα για νέες λειτουργίες και αναφορές σφαλμάτων! Βοηθάτε να γίνει το WP-piwik πολύ καλύτερο." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "Σας ευχαριστώ για τη χρήση του plugin μου. Είναι ο καλύτερος έπαινος, αν ο κώδικάς μου χρησιμοποιείται πραγματικά!" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "Το καλύτερο μέρος για βοήθεια:" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "Φόρουμ υποστήριξης για το WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "Αποσφαλμάτωση" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "Είτε το allow_url_fopen πρέπει να είναι ενεργοποιημένο είτε το cURL να είναι διαθέσιμο:" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "Το cURL είναι" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "μη" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "διαθέσιμο" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "Το allow_url_fopen είναι" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "ενεργοποιημένο" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "χρησιμοποιείται." - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "Η βασική διεύθυνση URL για το Piwik καθορίστηκε σε" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "Εργαλεία" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "Εκτέλεση του σεναρίου δοκιμής" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "Περιηγητής ιστοτόπου" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "Καθαρισμός της λανθάνουσας μνήμης" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "Είστε σίγουροι για τον καθαρισμό όλων των ρυθμίσεων;" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "Αρχικοποίηση του WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "Τα τελευταία θέματα για υποστήριξη στο WordPress.org" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "Οι ρυθμίσεις καθαρίστηκαν (εκτός από τις ρυθμίσεις σύνδεσης)." - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "Η λανθάνουσα μνήμη διαγράφηκε." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "ιστοτόπος" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "ιστοτόποι" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "Δεν έχει παραμετροποιηθεί ακόμη ιστοτόπος." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "Αναγνωριστικό ιστολογήματος" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Τίτλος" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "Διεύθυνση URL" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "Αναγνωριστικό ιστοτόπου (Piwik)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "Ο ιστοτόπος δεν έχει ακόμη δημιουργηθεί." - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "Στατιστικά" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "Τρέχουσα προβολή στατιστικών:" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "Δεν ήταν δυνατή η επίλυση" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "Το realpath() επιστρέφει ψευδές" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "Δεν υπάρχει η κλάση Piwik\\FrontController." - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "Δεν υπάρχει η κλάση Piwik\\API\\Request." - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "Προσαρμοσμένες Μεταβλητές του Piwik" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "Όνομα" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "Τιμή" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "Ορισμός προσαρμοσμένων μεταβλητών για εμφάνιση σελίδας" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Σφάλμα του Piwik" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Μοναδικοί" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Επισκέψεις" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "Επισκέψεις" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "Ενέργειες" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "Δεν υπάρχουν διαθέσιμα στοιχεία." - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "σήμερα" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "τρέχων μήνας" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "προηγούμενος μήνας" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "τρέχουσα εβδομάδα" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "προηγούμενη εβδομάδα" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "χθες" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "εβδομάδα" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "τελευταίες 30 ημέρες" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "τελευταία 12" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "Λεπτομέρειες προγράμματος πλοήγησης" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Browser" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Τοις εκατό" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "Άλλοι" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "Προγράμματα πλοήγησης" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Επισκέπτες" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "Το γράφημα περιέχει τις τιμές που εμφανίζονται στον πίνακα παρακάτω (επισκέπτες / μοναδικοί /αναπηδήσεις). Η κόκκινη γραμμή δείχνει μια γραμμική τάση (μοναδική)." - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Χώρες" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "Χώρα" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "Μετατροπές" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "Πρόσοδος" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "Συντόμευση" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "Ετικέτα" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "Ποσότητα" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "Παραγγελίες" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Λέξεις κλειδιά" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "Αναζήτηση ιστοτόπου" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Λέξη κλειδί" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "Αιτήσεις" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Εγκατέλειψαν" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Επισκόπηση" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "κεντρικός πίνακας" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Μοναδικοί επισκέπτες" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Προβολές σελίδων" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "Συνολικός χρόνος" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Αριθμός που εγκατέλειψαν" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "Χρόνος/Επίσκεψη" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Ανώτατο όριο προβολών σελίδων σε μια επίσκεψη" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "Σελίδες" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "Σελίδα" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "Plugins" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "Πρόσθετο" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "Ελάχιστος χρόνος δημιουργίας" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "Μέγιστος χρόνος δημιουργίας" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "Αναφορείς" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "Αναλύσεις" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Ανάλυση" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "Λεπτομέρειες Συστήματος Ενεργειών" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "Σύστημα ενέργειας" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "Συστήματα ενεργειών" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Ημερομηνία" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "Εμφανίσεις σελίδας" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "Το WP-Piwik απαιτεί τουλάχιστον PHP 5.3. Χρησιμοποιείτε την παρωχημένη έκδοση %s. Παρακαλώ αναβαθμίστε την PHP για να εκτελείται το WP-Piwik." diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el_GR.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el_GR.mo deleted file mode 100644 index 802a4883..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el_GR.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el_GR.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el_GR.po deleted file mode 100644 index be908a52..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-el_GR.po +++ /dev/null @@ -1,407 +0,0 @@ -# Translation of the WordPress plugin WP-Piwik 0.8.0 by André Bräkling. -# Copyright (C) 2010 André Bräkling -# This file is distributed under the same license as the WP-Piwik package. -# André Bräkling , 2011. -# -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik 0.8.6\n" -"Report-Msgid-Bugs-To: http://wordpress.org/tag/wp-piwik\n" -"POT-Creation-Date: 2010-07-19 18:06+0000\n" -"PO-Revision-Date: 2011-04-29 20:30+0200\n" -"Last-Translator: Harry \n" -"Language-Team: AggelioPolis.gr\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=utf-8\n" -"Content-Transfer-Encoding: 8bit\n" -"X-Poedit-Language: Greek\n" -"X-Poedit-Country: GREECE\n" - -#: dashboard/browsers.php:12 -#: dashboard/browsers.php:33 -msgid "Browser" -msgstr "Browser" - -#: dashboard/browsers.php:22 -#: dashboard/pages.php:43 -#: dashboard/screens.php:22 -#: dashboard/systems.php:22 -msgid "Others" -msgstr "Άλλοι" - -#: dashboard/browsers.php:34 -#: dashboard/keywords.php:17 -#: dashboard/pages.php:22 -#: dashboard/screens.php:33 -#: dashboard/systems.php:35 -#: dashboard/visitors.php:53 -#: dashboard/websites.php:19 -#: wp-piwik.php:305 -msgid "Unique" -msgstr "Μοναδικοί" - -#: dashboard/browsers.php:35 -#: dashboard/plugins.php:33 -#: dashboard/screens.php:34 -#: dashboard/systems.php:36 -msgid "Percent" -msgstr "Τοις εκατό" - -#: dashboard/keywords.php:12 -msgid "Keywords" -msgstr "Λέξεις κλειδιά" - -#: dashboard/keywords.php:17 -msgid "Keyword" -msgstr "Λέξη κλειδί" - -#: dashboard/overview.php:12 -msgid "Overview" -msgstr "Επισκόπηση" - -#: dashboard/overview.php:42 -#: dashboard/visitors.php:24 -msgid "Visitors" -msgstr "Επισκέπτες" - -#: dashboard/overview.php:43 -msgid "Unique visitors" -msgstr "Μοναδικοί επισκέπτες" - -#: dashboard/overview.php:44 -msgid "Page views" -msgstr "Προβολές σελίδων" - -#: dashboard/overview.php:45 -msgid "Max. page views in one visit" -msgstr "Ανώτατο όριο προβολών σελίδων σε μια επίσκεψη" - -#: dashboard/overview.php:46 -msgid "Total time spent" -msgstr "Συνολικός χρόνος" - -msgid "Time/visit" -msgstr "Χρόνος/Επίσκεψη" - -#: dashboard/overview.php:47 -msgid "Bounce count" -msgstr "Αριθμός που εγκατέλειψαν" - -#: dashboard/overview.php:49 -#: wp-piwik.php:563 -msgid "Shortcut" -msgstr "Συντόμευση" - -#: dashboard/pages.php:13 -msgid "Pages" -msgstr "Σελίδες" - -#: dashboard/pages.php:21 -msgid "Page" -msgstr "Σελίδα" - -#: dashboard/pages.php:23 -#: dashboard/plugins.php:32 -#: dashboard/visitors.php:52 -msgid "Visits" -msgstr "Επισκέψεις" - -#: dashboard/plugins.php:12 -#: dashboard/plugins.php:31 -msgid "Plugins" -msgstr "Plugins" - -#: dashboard/screens.php:12 -#: dashboard/screens.php:32 -msgid "Resolution" -msgstr "Ανάλυση" - -#: dashboard/systems.php:12 -#: dashboard/systems.php:34 -msgid "Operating System" -msgstr "Λειτουργικό Σύστημα" - -#: dashboard/visitors.php:51 -msgid "Date" -msgstr "Ημερομηνία" - -#: dashboard/visitors.php:54 -msgid "Bounced" -msgstr "Εγκατέλειψαν" - -#: dashboard/visitors.php:67 -msgid "Unique TOTAL" -msgstr "Unique ΆΘΡΟΙΣΜΑ" - -#: dashboard/visitors.php:67 -msgid "Sum" -msgstr "Άθροισμα" - -#: dashboard/visitors.php:67 -msgid "Avg" -msgstr "Μέσος Όρος" - -#: dashboard/websites.php:12 -msgid "Websites" -msgstr "Ιστοσελίδες" - -#: dashboard/websites.php:18 -msgid "Website" -msgstr "Ιστοσελίδα" - -#: wp-piwik.php:110 -#: wp-piwik.php:365 -msgid "Piwik Statistics" -msgstr "Piwik Στατιστικά" - -#. #-#-#-#-# plugin.pot (WP-Piwik 0.8.0) #-#-#-#-# -#. Plugin Name of the plugin/theme -#: wp-piwik.php:111 -#: wp-piwik.php:122 -#: wp-piwik.php:123 -#: wp-piwik.php:146 -msgid "WP-Piwik" -msgstr "WP-Piwik" - -#: wp-piwik.php:130 -#: wp-piwik.php:131 -msgid "WPMU-Piwik" -msgstr "WPMU-Piwik" - -#: wp-piwik.php:142 -#: wp-piwik.php:557 -msgid "yesterday" -msgstr "χθες" - -#: wp-piwik.php:143 -#: wp-piwik.php:558 -msgid "today" -msgstr "σήμερα" - -#: wp-piwik.php:144 -#: wp-piwik.php:559 -msgid "last 30 days" -msgstr "τελευταίες 30 ημέρες" - -#: wp-piwik.php:179 -msgid "Settings" -msgstr "Ρυθμίσεις" - -#: wp-piwik.php:381 -msgid "Change" -msgstr "Αλλαγή" - -#: wp-piwik.php:382 -msgid "Currently shown stats:" -msgstr "Τρέχουσα προβολή στατιστικών:" - -#: wp-piwik.php:383 -msgid "Current shown stats: Overall" -msgstr "Τρέχουσα προβολή στατιστικών: Συνολικά" - -#: wp-piwik.php:448 -msgid "WP-Piwik Settings" -msgstr "WP-Piwik Ρυθμίσεις" - -#: wp-piwik.php:455 -#: wp-piwik.php:617 -msgid "Account settings" -msgstr "Ρυθμίσεις Λογαριασμού" - -#: wp-piwik.php:457 -#: wp-piwik.php:619 -msgid "Piwik URL" -msgstr "Piwik URL" - -#: wp-piwik.php:461 -#: wp-piwik.php:623 -msgid "Auth token" -msgstr "Σύμβολο γνησιότητας" - -#: wp-piwik.php:467 -#: wp-piwik.php:628 -msgid "To enable Piwik statistics, please enter your Piwik base URL (like http://mydomain.com/piwik) and your personal authentification token. You can get the token on the API page inside your Piwik interface. It looks like "1234a5cd6789e0a12345b678cd9012ef"." -msgstr "Για να ενεργοποιήσετε τα Piwik στατιστικά, παρακαλώ εισάγετε τη βασική Piwik URL σας (π.χ. http://mydomain.com/piwik) και τo προσωπικό σύμβολο (token) γνησιότητας. Μπορείτε να το βρείτε στη σελίδα API μέσα στη διεπαφή του Piwik. Μοιάζει με: "1234a5cd6789e0a12345b678cd9012ef"." - -#: wp-piwik.php:477 -msgid "Important note: If you do not host this blog on your own, your site admin is able to get your auth token from the database. So he is able to access your statistics. You should never use an auth token with more than simple view access!" -msgstr "Σημαντική Σημείωση: Εάν δεν φιλοξενείται το ιστολόγιο από εσάς, τότε ο διαχειριστής θα μπορεί να έχει πρόσβαση στο σύμβολο γνησιότητας (auth token) σας από τη βάση δεδομένων. Έτσι θα έχει πρόσβαση στα στατιστικά σας. Γι'αυτό το λόγο το σύμβολο γνησιότητας (auth token) δεν θα πρέπει να έχει περισσότερα δικαιώματα, παρά μόνο δικαίωμα προβολής." - -#: wp-piwik.php:485 -#: wp-piwik.php:489 -msgid "An error occured" -msgstr "Παρουσιάστηκε σφάλμα" - -#: wp-piwik.php:486 -msgid "Please check URL and auth token. You need at least view access to one site." -msgstr "Παρακαλώ ελέγξτε URL και σύμβολο γνησιότητας (auth token). Απαιτείται τουλάχιστον να έχετε δικαίωμα προβολής ενός site ." - -#: wp-piwik.php:492 -msgid "Choose site" -msgstr "Επιλέξτε site" - -#: wp-piwik.php:511 -#: wp-piwik.php:547 -#: wp-piwik.php:584 -#: wp-piwik.php:658 -msgid "Save settings" -msgstr "Αποθήκευση ρυθμίσεων" - -#: wp-piwik.php:515 -#: wp-piwik.php:643 -msgid "Tracking settings" -msgstr "Ρυθμίσεις παρακολούθησης" - -#: wp-piwik.php:521 -msgid "Add script" -msgstr "Προσθήκη script" - -#: wp-piwik.php:525 -msgid "If your template uses wp_footer(), WP-Piwik can automatically add the Piwik javascript code to your blog." -msgstr "Αν το πρότυπό σας χρησιμοποιεί wp_footer (), το WP-Piwik μπορεί αυτόματα να προσθέσει τον Piwik javascript κώδικα στο ιστολόγιο σας." - -#: wp-piwik.php:528 -msgid "Track 404" -msgstr "Παρακολούθηση 404" - -#: wp-piwik.php:532 -msgid "If you add the Piwik javascript code by wp_footer(), WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "Αν προσθέσατε το Piwik javascript κώδικα μέσω wp_footer (), το WP-Piwik μπορεί αυτόματα να προσθέσει μια κατηγορία 404 για την παρακολούθηση 404 επισκέψεων." - -#: wp-piwik.php:536 -#: wp-piwik.php:644 -msgid "Tracking filter" -msgstr "Φίλτρο Παρακολούθησης" - -msgid "Choose users by user role you do not want to track." -msgstr "Επιλέξτε το ρόλο χρήστη, τον οποίο δε θέλετε να παρακολουθήσετε." - -msgid "Choose users by user role you do not want to track. Requires enabled "Add script"-functionality." -msgstr "Επιλέξτε τους ρόλους χρηστών, τους οποίους δε θέλετε να παρακολουθήσετε. Γι'αυτό θα πρέπει να είναι ενεργοποιημένη η λειτουργία "Προσθήκη script"." - -#: wp-piwik.php:551 -msgid "Statistic view settings" -msgstr "Ρυθμίσεις Στατιστικών" - -#: wp-piwik.php:554 -msgid "Dashboard" -msgstr "Dashboard" - -#: wp-piwik.php:556 -msgid "No" -msgstr "Όχι" - -#: wp-piwik.php:557 -#: wp-piwik.php:558 -#: wp-piwik.php:559 -msgid "Yes" -msgstr "Ναι" - -#: wp-piwik.php:562 -msgid "Display a dashboard widget to your WordPress dashboard." -msgstr "Εμφάνιση ενός widget στο WordPress dashboard." - -#: wp-piwik.php:567 -msgid "Display a shortcut to Piwik itself." -msgstr "Εμφάνιση μιας συντόμευσης προς Piwik." - -#: wp-piwik.php:568 -msgid "Display to" -msgstr "Εμφάνιση για " - -#: wp-piwik.php:579 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Επιλέξτε τους ρόλους χρηστών, οι οποίοι επιτρέπεται να βλέπουν τα στατιστικά." - -#: wp-piwik.php:612 -msgid "WPMU-Piwik Settings" -msgstr "WPMU-Piwik Ρυθμίσεις" - -#: wp-piwik.php:636 -msgid "Important note: You have to choose a token which provides administration access. WPMU-Piwik will create new Piwik sites for each blog if it is shown the first time and it is not added yet. All users can access their own statistics only, while site admins can access all statistics. To avoid conflicts, you should use a clean Piwik installation without other sites added. The provided themes should use wp_footer, because it adds the Piwik javascript code to each page." -msgstr "Σημαντική Σημείωση: Θα πρέπει να επιλέξετε ένα σύμβολο γνησιότητας (auth token), το οποίο θα έχει διαχειριστική πρόσβαση. Το WPMU-Piwik θα δημιουργήσει νέα Piwik sites για κάθε ιστολόγιο, εάν προβληθεί για πρώτη φορά και δεν έχει προστεθεί ακόμη. Όλοι οι χρήστες μπορούν να έχουν πρόσβαση στα δικά τους στατιστικά, ενώ οι διαχειριστές της ιστοσελίδας μπορούν να έχουν πρόσβαση σε όλες τις στατιστικές. Για την αποφυγή συγκρούσεων, θα πρέπει να χρησιμοποιήσετε μια καθαρή εγκατάσταση Piwik, χωρίς να έχετε πρoσθέσει άλλα sites. Τα παρεχόμενα πρότυπα θα πρέπει να χρησιμοποιούν wp_footer, διότι προσθέτει τον Piwik javascript κώδικα σε κάθε σελίδα." - -#: wp-piwik.php:671 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Αν σας αρέσει το WP-Piwik, μπορείτε να στηρίξετε την ανάπτυξή του με μια δωρεά:" - -#: wp-piwik.php:687 -msgid "My Amazon.de wishlist (German)" -msgstr "Η λίστα επιθυμιών μου στο Amazon.de (Γερμανικά)" - -#. Plugin URI of the plugin/theme -msgid "http://www.braekling.de/wp-piwik-wpmu-piwik-wordpress/" -msgstr "http://www.braekling.de/wp-piwik-wpmu-piwik-wordpress/" - -#. Description of the plugin/theme -msgid "Adds Piwik stats to your dashboard menu and Piwik code to your wordpress footer." -msgstr "Προσθέτει τα στατιστικά Piwik στο dashboard μενού και τον κώδικα Piwik στο wordpress footer." - -#. Author of the plugin/theme -msgid "André Bräkling" -msgstr "André Bräkling" - -#. Author URI of the plugin/theme -msgid "http://www.braekling.de" -msgstr "http://www.braekling.de" - -msgid "Credits" -msgstr "Συντελεστές" - -msgid "Thank you very much for your donation" -msgstr "Ευχαριστώ για τις δωρεές" - -msgid "and all people flattering this" -msgstr "και σε όλους τους χρήστες που μιλούν με κολακευτικά λόγια" - -msgid "Graphs powered by jqPlot, an open source project by Chris Leonello. Give it a try! (License: GPL 2.0 and MIT)" -msgstr "Τα γραφήματα δημιουργούνται με τη βοήθεια του jqPlot, ενός προγράμματος ανοιχτού κώδικα του Chris Leonello. Δοκίμασέ το! (Άδεια χρήσης: GPL 2.0 και MIT)" - -msgid "Thank you very much" -msgstr "Ευχαριστώ πολύ" - -msgid ", and" -msgstr " και" - -msgid "for your translation work" -msgstr "για τη μετάφραση" - -msgid "Thank you very much, all users who send me mails containing criticism, commendation, feature requests and bug reports! You help me to make WP-Piwik much better." -msgstr "Σας ευχαριστώ πολύ, όλους τους χρήστες που μου στείλατε μηνύματα που περιέχουν κριτική, επιδοκιμασία, αιτήματα για νέες λειτουργίες και αναφορές σφαλμάτων! Βοηθάτε να γίνει το WP-piwik πολύ καλύτερο." - -msgid "Thank you for using my plugin. It is the best commendation if my piece of code is really used!" -msgstr "Σας ευχαριστώ για τη χρήση του plugin μου. Είναι ο καλύτερος έπαινος, αν ο κώδικάς μου χρησιμοποιείται πραγματικά!" - -msgid "Changes saved" -msgstr "Αλλαγές αποθηκεύτηκαν" - -msgid "installed" -msgstr "εγκαταστάθηκε" - -msgid "Next you should connect to Piwik" -msgstr "Στη συνέχεια συνδεθείτε με Piwik" - -msgid "Please validate your configuration" -msgstr "Παρακαλώ επαληθεύστε τη διαμόρφωση" - -msgid "Default date" -msgstr "Προεπιλεγμένη ημερομηνία" - -msgid "Default date shown on statistics page." -msgstr "Προεπιλεγμένη ημερομηνία που αναγράφεται στη σελίδα των στατιστικών." - -msgid "Dashboard data" -msgstr "Δεδομένα Dashboard" - -msgid "Display an overview widget to your WordPress dashboard." -msgstr "Προβολή ενός widget προεπισκόπησης στο WordPress dashboard." - -msgid "Boad chart" -msgstr "Board γράφημα" - -msgid "Display a visitor graph widget to your WordPress dashboard." -msgstr "Προβολή ενός widget με γράφημα επισκεπτών στο WordPress dashboard." - -msgid "No data available." -msgstr "Δεν υπάρχουν διαθέσιμα στοιχεία." - diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-es_ES.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-es_ES.mo deleted file mode 100644 index 8bf50ce1..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-es_ES.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-es_ES.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-es_ES.po deleted file mode 100644 index aadfdf89..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-es_ES.po +++ /dev/null @@ -1,1530 +0,0 @@ -# -# Translators: -# André Bräkling , 2011 -# Andres Sanchez , 2015 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:44+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Spanish (Spain) (http://www.transifex.com/piwik/wp-piwik/language/es_ES/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: es_ES\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s instalado." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "A continuación, debe conectarse a Piwik" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "%s actualizado a %s." - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "Por favor valida tu configuración" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Ajustes" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Importante" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Estadísticas de Piwik" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "Configurar WP-Piwik" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "Ocurrió un error" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Asistencia" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Recargar" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Cambios guardados." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Gracias por usar WP-Piwik!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s se conectó satisfactoriamente a Piwik %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "Está usando WordPress %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Conectar a Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Mostrar Estadísticas" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "Habilitar Seguimiento" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "Créditos" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "ó" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "Más información" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "Puede escoger entre tres métodos de conexión:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Modo de Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Dirección de Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "Ingrese la URL de Piwik. Ésta es la misma URL que usa para acceder a su instancia de Piwik, e.g. http://www.example.com/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "Ruta a Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Auth token" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "Ver %sWP-Piwik FAQ%s." - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Auto-configuración" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "Selecciona esto para elegir automáticamente tu blog desde el listado de sitios de Piwik por la dirección. Si tu blog no está todavía añadido en Piwik, WP-Piwik añadirá un sitio nuevo." - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "Sitio determinado" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "Seleccionar sitio" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Hoy" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Ayer" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Mes actual" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Último mes" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Semana actual" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Última semana" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "Fecha por defecto mostrada en la página de estadísticas" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "Deshabilitado" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "Últimos 30 días" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Selecciona los roles de usuario que pueden acceder a las estadísticas." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "Mostar un enlace directo al propio Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "Utilizar js/index.php" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "Agregar código de seguimiento" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "Código de seguimiento" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "Seguimiento de errores 404" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "WP-Piwik puede añadir automáticamente una categoría-404 para hacer el seguimiento de los errores 404" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Filtro de seguimiento" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "Selecciona, por el rol de usuario, los usuarios sobre los cuales no quieres hacer seguimiento." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Nombre de usuario" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "Donar" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Si te gusta WP-Piwik, puedes añadir a su desarrollo con una donación:" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "Mi lista en Amazon.de" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "Por favor no te olvides de votar la compatibilidad en " - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "Muchas gracias por vuestra donación" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "El equipo de Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "Muchas gracias" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "por vuestro trabajo de traducción" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "Muchísimas gracias a todos los usuarios que me habéis enviado emails con críticas, recomendaciones, sugerencias de mejoras y reportes de errores. Me ayudais a hacer WP-Piwik mucho mejor." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "Gracias a tipor utilizar mi plugin. Es el mayor elogio que mi plugin sea realmente utilizado." - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Título" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "URL" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "Estadísticas" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "Estaísticas mostradas actualmente:" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "Nombre" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "Valor" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Error de Piwik" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Único" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Visitas" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "Acciones" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "No hay datos disponibles." - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "semana" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Navegador" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Porcentaje" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "Otros" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "Navegadores" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Visitantes" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Países" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "País" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "Conversiones" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "Ingresos" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "Enlace directo" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "Etiqueta" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "Cantidad" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Palabras Clave" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Palabra Clave" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Rebotado" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Información General" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Visitantes Únicos" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Páginas vistas" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "Tiempo total empleado" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Número de rebotes" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "Tiempo/Visita" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Máximo de páginas vistas durante una visita" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "Páginas" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "Plugins" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "Plugin" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "Referencias" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "Resoluciones" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Resolución" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "Detalles del Sistema Operativo" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "Sistema Operativo" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "Sistemas Operativos" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Fecha" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "Páginas Vistas" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fa_IR.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fa_IR.mo deleted file mode 100644 index ccb73f25..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fa_IR.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fa_IR.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fa_IR.po deleted file mode 100644 index 641d291e..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fa_IR.po +++ /dev/null @@ -1,1532 +0,0 @@ -# -# Translators: -# Amin Yazdi , 2015 -# André Bräkling , 2011 -# André Bräkling, 2015 -# WebNashr , 2015 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Persian (Iran) (http://www.transifex.com/piwik/wp-piwik/language/fa_IR/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: fa_IR\n" -"Plural-Forms: nplurals=1; plural=0;\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr " نصب شده" - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "سپس باید به پیویک متصل شوید" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "%s. به روز رسانی به %s" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "لطفاً صحت تنظیمات خود را بررسی کنید" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "تنظیمات" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "مهم" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "آمار" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "خطائی رخ داده است" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "پشتیبانی" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "کلک میزنی،‌ها؟" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "بارگذاری مجدد" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "تغییرات ذخیره شد." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "بابت استفاده از WP-Piwik از شما ممنونیم!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s با موفقیت به Piwik %s متصل شد." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "شما از وردپرس %s استفاده می کنید." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "اتصال به پیویک" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "آمار" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "فعال کردن ردگیری" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "تنظیمات حرفه ای" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "دست‌اندرکاران" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "یا" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "اطلاعات بیشتر" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "شما می توانید بین سه روش اتصال را انتخاب کنید:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "میزبانی خود (اچ تی تی پی API، به طور پیش فرض)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "میزبانی خود (API PHP)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "حالت پیویک" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "غیر فعال کردن پیویک( پلاگاین به پیویک وصل نمیشود)" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "آدرس پیویک" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "مسیر پیویک" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "مسیر فایل را وارد کنید به عنوان مثال e.g. /var/www/piwik" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "نشانه اعتبارسنجی" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "تنظیم خودکار" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "انتخاب سایت" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "تاریخ پیش‌گزیده پیویک" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "امروز" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "دیروز" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "ماه جاری" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "ماه گذشته" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "هفته جاری" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "هفته‌ی گذشته" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "داده‌های پیش‌گزیده نمایش داده شده در صفحه آمار" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "کند!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "غیرفعال" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "30 روز گذشته" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "انتخاب کاربرانی که مجازند صفحه آمار ر اببینند." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "نمایش یک میان‌بر به پیویک اصلی." - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "پابرگ" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "تیتر" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "ره‌گیری 404 (صفحه یافت نشد)" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "غیرفعال‌سازی کوکی ها" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "پالایه ره‌گیری" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "کاربرانی را که نمی‌خواهید رهگیری شوند با توجه به وظیفه انتخاب کنید." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "نوشته" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "دریافت" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "غیرفعال‌سازی محدودیت زمان" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "تماس برقرار نشد" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "توصیه نشده" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "واژه خالی" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "غیرفعال(پیش فرض)" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "اهداء کردن" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "اگر افزونه پیویک برای وردپرس را دوست دارید، با کمک مالی از آن حمایت کنید:" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "لیست علاقه مندی های من در Amazon.de" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "از شما به خاطر هدایایتان تشکر می‌کنم" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "تیم پیویک" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "از شما بسیار متشکریم" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "برای فعالیت شما در ترجمه" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "از شما بسیار متشکریم، تمام کاربرانی که به من ایمیل زدند، تشکر کردند، و درخواست ویژگی یا گزارش باگ انجام دادند. ش ما کمک کردید که پیویک وردپرس بسیار بهتر شود." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "از شما به خاطر استفاده از این افزونه متشکریم. بهترین تقدیر این است که کدی که من نوشتم واقعاً استفاده شود." - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "اشکال زدایی" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "نیست" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "در دسترس" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "فعال" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "استفاده شده" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "ابزارها" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "اجرای اسکریپت" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "پاکسازی کش" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "کش پاک شد" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "سایت‌" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "سایت‌ها" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "سایت هنوز پیکربندی نشده" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "شناسه وبلاگ" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "عنوان" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "نشانی وب" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "شناسه سایت (پیویک)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "وب سایت هنوزایجاد نشده است." - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "آمار" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "آمار در حال نمایش:" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "عملیات ناموفق" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "متغیر های سفارشی Piwik" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "نام" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "مقدار" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "خطای پیویک" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "یکتا" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "بازدیدها" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "تعداد بازدید ها" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "کارها" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "داده‌ای در دسترس نیست" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "هفته" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "جزئیات مرورگرها" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "مرورگر" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "درصد" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "غیره" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "مرورگر" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "بازدیدکنندگان" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "میان‌بر" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "کلیدواژه‌ها" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "جستجو در سایت" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "کلیدواژه" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "تعداد" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "بازگشت" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "نمای کلی" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "بازدیدکنندگان یکتا" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "نمایش‌های صفحه" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "کل زمان سپری شده" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "تعداد بازگشت" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "زمان/بازدید" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "حداکثر تعداد نمایش‌های صفحه در یک بازدید" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "برگه‌ها " - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "افزونه‌ها" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "افزونه" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "حداقل زمان ایجاد " - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "حداکثر زمان ایجاد ." - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "ارجاع‌دهنده‌ها" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "وضوح تصویر" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "وضوح تصویر" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "جزئیات سیستم عامل" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "سیستم عامل" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "سیستم عامل‌ها" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "تاریخ" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "تعداد نمایش صفحه" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fr_FR.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fr_FR.mo deleted file mode 100644 index 044b0fae..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fr_FR.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fr_FR.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fr_FR.po deleted file mode 100644 index 672d43ce..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-fr_FR.po +++ /dev/null @@ -1,1532 +0,0 @@ -# -# Translators: -# Andre Braekling , 2009 -# André Bräkling, 2015 -# Franck, 2015-2016 -# Vincent Biret , 2015 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: French (France) (http://www.transifex.com/piwik/wp-piwik/language/fr_FR/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: fr_FR\n" -"Plural-Forms: nplurals=2; plural=(n > 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s installé." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "Ensuite, vous devez vous connecter à Piwik" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "%s mis à jour vers %s." - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "Merci de valider votre configuration" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Paramètres" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Important" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Statistiques Piwik" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "Paramétrer WP-Piwik" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "Une erreur s'est produite" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Support" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "Alors, on triche ?" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Recharger" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Modifications enregistrées." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Merci d'utiliser WP-Piwik !" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s est connecté avec succès à Piwik %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "Vous utilisez WordPress %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "Vous utilisez le réseau de blogs (WPMU) d'un WordPress %s . WP-Piwik va gérer vos sites comme des sites distincts." - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "WP-Piwik %s n'a pas pu se connecter à Piwik à partir de votre configuration. Vérifiez la section ci-dessous »Connecter à Piwik«." - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "WP-Piwik %s n'a pas pu se connecter à Piwik à partir de votre configuration. L'erreur suivante est apparue au cours de la connexion :
            %s" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "WP-Piwik %s doit en premier être connecté à Piwik. Vérifiez la section ci-dessous » Connecter à Piwik « à Piwik«." - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Connecter à Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Afficher les statistiques" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "Activer le suivi" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "Réglages expert" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "Crédits" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "WP-Piwik est une extension WordPress pour afficher une sélection de stats Piwik dans votre tableau de bord d'admin WordPress et pour ajouter et configurer votre code de suivi Piwik. Pour utiliser cela, vous aurez besoin de votre propre instance Piwik. Si vous ne possédez pas encore de configuration Piwik, vous avez deux options simples : utilisez au choix" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "ou" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "Plus d'informations" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "Vous pouvez choisir entre trois méthodes de connexion :" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "Auto-hébergé (API HTTP par défaut)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "C'est l'option par défaut pour un Piwik auto-hébergé et devrait fonctionner pour la plupart des configurations. WP-Piwik va se connecter à Piwik en utilisant http(s)." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "Auto-hébergé (API PHP)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "Choisissez cela, si votre Piwik auto-hébergé et WordPress fonctionnent sur la même machine et que vous connaissez le chemin complet du serveur de votre instance Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Mode Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "Désactivé (WP-Piwik ne se connectera pas à Piwik)" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik URL" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "Entrez votre URL Piwik. C'est la même URL que vous utilisez pour accéder à votre instance de Piwik, par exemple, http://www.example.com/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "Chemin Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "Entrez le chemin de votre instance Piwik, par exemple /var/www/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Clef partagée (token_auth)" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "Entrez votre clef partagée (token_auth) Piwik ici. C'est un code alphanumérique du genre 0a1b2c34d56e78901fa2bc3d45678efa." - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "Voir la %sFAQ WP-Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Auto config" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "Cochez cette case pour choisir automatiquement votre blog à partir de vos sites Piwik par URL. Si votre blog est pas encore ajouté à Piwik, WP-Piwik ajoutera un nouveau site." - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "Site déterminé" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "Sélectionner le site" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "Date par défaut Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Aujourd'hui" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Hier" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Mois en cours" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Mois précédent" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Semaine en cours" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Semaine précédente" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "Date affichée par défaut sur la page de statistiques." - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "Afficher les données SEO" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "Afficher les données de classement SEO sur la page de statistiques." - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "Doucement !" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "Tableau de bord vue d'ensemble" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "Désactivé" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "30 derniers jours" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "Activer le widget du tableau de bord WP-Piwik "Vue d'ensemble"." - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "Tableau de bord graphique" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "Activer le widget du tableau de bord WP-Piwik "Graphique"." - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "Tableau de bord SEO" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "Activer le widget du tableau de bord WP-Piwik "SEO"." - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "Afficher le graphique dans la barre d'outils WordPress" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "Afficher un graphique des visiteurs des 30 derniers jours dans la barre d'outils WordPress" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "Afficher les stats pour le(s)" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Choisissez les rôles utilisateurs autorisés à voir la page de statistiques." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "Afficher les stats par article" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "Afficher les stats de l'article sur la page admin de modification des articles." - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "Raccourci Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "Affiche un raccourci vers Piwik lui-même." - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "Nom d'affichage WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "Nom d'extension affichée dans WordPress." - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "Activer les codes courts" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "Active les codes courts dans le contenu des articles ou des pages" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "Vous pouvez choisir entre quatre modes de code de suivi :" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "WP-Piwik n'ajoutera pas le code de suivi. Utilisez cela si vous souhaitez ajouter le code de suivi dans les fichiers de votre thème, ou que vous utilisez une autre extension pour ajouter le code de suivi." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "Suivi par défaut" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "WP-Piwik utilisera le code de suivi standard de Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "Utiliser js/index.php" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "Vous pouvez choisir ce code de suivi, pour délivrer un code proxy minifié et d'éviter d'utiliser les fichiers appelés piwik.js ou piwik.php." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "Voir le %sfichier lisez-moi%s" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "Utiliser une code proxy" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "Utilisez ce code de suivi pour ne pas révéler l'URL du serveur Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "Voir la %sFAQ Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "Entrer manuellement" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "Entrer manuellement votre propre code de suivi. Vous pouvez choisir l'une des options préalables, pré-configurer votre code de suivi et le modifier manuellement à la fin." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "Utilisez l'espace réservé {ID} pour ajouter l'identifiant de site Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "Ajouter le code de suivi" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "Code de suivi" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "Emplacement du code JavaScript" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "Pied de page" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "En-tête" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "Choisissez si le code JavaScript est ajouté dans le pied de page ou l'en-tête." - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "Code noscript" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "Ajouter <noscript>" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "Ajoute le code <noscript> à votre pied de page." - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "Désactivé en mode proxy." - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "Ajouter le paramètre rec au code noscript" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "Activer le suivi des visiteurs sans JavaScript (non recommandé)." - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "Activer le suivi de contenu" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "Suivre tous les blocs de contenu" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "Suivre uniquement les blocs de contenu visibles" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "Le suivi de contenu vous autorise à suivre l'interaction avec le contenu d'une page web ou d'une application." - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "Voir la %sdocumentation Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "Suivre la recherche" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "Utiliser la fonctionnalité avancée Piwik d'analyse de recherche du site" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "Suivre les 404" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "WP-Piwik peut ajouter automatiquement une catégorie 404 pour suivre les visites de page 404." - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "Afficher la boîte de variables personnalisées" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "Afficher une boîte de modification des "variables personnalisées" sur la page de modification des articles;" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "Ajouter de nouveaux types de fichier pour le suivi de téléchargement" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "Ajouter des extensions de fichier pour le suivi de téléchargement, séparées par une barre verticale (|)." - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "Désactiver les cookies" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "Désactiver tous les cookies de suivi pour un visiteur" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "Limiter la durée de vie des cookies" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "Vous pouvez limiter la durée de vie des cookies pour éviter le suivi de vos utilisateurs sur une période plus longue que nécessaire." - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "Expiration du délai d'attente visiteur (en secondes)" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "Expiration du délai d'attente session (en secondes)" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "Expiration du délai d'attente référant" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "Suivre les pages d'admin" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "Activer le suivi des utilisateurs sur les pages d'admin (n'oubliez pas de configurer le filtre de suivi adéquat)" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Filtre de suivi" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "Choisissez, pour chaque rôle, ceux que vous ne souhaitez pas inclure dans le suivi." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "Suivre les sous-domaines dans le même site web" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "Ajoute *.-préfixe au cookie de domaine." - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "Ne pas comptabiliser les sous-domaines en tant que lien sortant" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "Ajoute *.-préfixe au domaine suivi." - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "Suivre les flux RSS" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "Activer le suivi des articles dans les flux via un pixel de suivi." - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "Suivre les liens du flux RSS comme une campagne" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "Ceci ajoutera des paramètres de campagne Piwik aux liens du flux RSS." - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "Campagne flux RSS" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "Mot-clef : nom d'article." - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "Activer une minuterie par pulsation" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "Activer une minuterie par pulsation pour obtenir des durées de visite plus précises en envoyant des requêtes ping HTTP périodiques tant que le site est ouvert. Entrez le temps entre les pings en secondes (par défaut dans Piwik : 15) pour l'activer ou 0 pour désactiver cette fonctionnalité. Remarque : Cela causera beaucoup de requêtes HTTP supplémentaires sur votre site." - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "Identifiant de suivi utilisateur" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "Identifiant d'utilisateur WP" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "Courriel" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Nom d'utilisateur" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "Nom à afficher publiquement (Non Recommendé !)" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "Lorsqu'un utilisateur est connecté à WordPress, suivre son "Identifiant". Vous pouvez sélectionner quel champ du profil utilisateur à suivre comme "Identifiant". Lorsque c'est activé, le suivi est basé sur le courriel est recommandé." - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "Habituellement, vous n'avez pas besoin de pas modifier ces réglages. Si vous voulez faire, vous devez savoir ce que vous faites ou avoir obtenu le conseil d'un expert." - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "Activer le cache" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "Appels API de cache, qui ne contiennent pas les valeurs d'aujourd'hui, pour une semaine." - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "Connexion HTTP via" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "fopen" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "Méthode HTTP" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "POST" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "GET" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "Désactiver la limite de temps" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "Utilisez set_time_limit(0) si la pages de statistiques provoque une expiration du délai d'attente." - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "Expiration du délai d'attente de la connexion" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "Désactiver la vérification par les pairs SSL" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "non recommandé" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "Désactiver la vérification SSL par l'hôte" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "Agent utilisateur (User agent)" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "Utiliser l'agent utilisateur (user-agent) par défaut de PHP" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "vide" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "Définir un agent utilisateur (user-agent) spécifique" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "Agent utilisateur (user-agent) spécifique" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "Ajouter data-cfasync=false" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "Voir la %sBase de connaissances CloudFlare%s." - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "Ajoute data-cfasync=false à la balise du script, pour demander par exemple, au chargeur Rocket d'ignorer le script. " - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "URL CDN" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "URL CDN (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "Forcer Piwik à utiliser un protocole spécifique" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "Désactivé (par défaut)" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "http" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "https (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "Choisissez si vous voulez forcer explicitement Piwik à utiliser le protocole HTTP ou HTTPS. Ne fonctionne pas avec une URL CDN." - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "Avis de mise à jour" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "Toujours afficher si WP-Piwik est mis à jour" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "Afficher uniquement si WP-Piwik est mis à jour et que les paramètres ont change." - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "Choisissez si vous souhaitez obtenir un avis de mise à jour si WP-Piwik est mis à jour." - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "Définir tous les types de fichier pour le suivi de téléchargement" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "Remplacer les extensions de fichier par défaut de Piwik pour le suivi de téléchargement, séparées par une barre verticale (|). Laisser vide pour conserver les réglages par défaut de Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "Faire un don" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Si vous aimez WP-Piwik, vous pouvez soutenir son développement par un don :" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "Ma liste de souhaits Amazon.de" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "Merci de ne pas oublier de voter la compatibilité avec" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "Merci beaucoup pour votre don" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "l'équipe Piwik elle-même" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr ", et toutes les personnes flatteuses à ce sujet." - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "Merci beaucoup" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "pour votre travail de traduction" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "Merci beaucoup, à tous les utilisateurs qui envoient des mails contenant critique, éloge, demandes de fonctionnalités et rapports de bogues ! Vous m'avez aidé a rendre WP-Piwik encore meilleur." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "Je vous remercie d'utiliser mon extension. C'est la meilleur éloge si mon morceau de code est vraiment utilisé !" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "Le meilleur endroit pour obtenir de l'aide :" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "Forum de support WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "Débogage" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "allow_url_fopen doit être activé ou cURL doit être disponible :" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "cURL est" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "non" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "disponible" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "allow_url_fopen est" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "activé" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "est utilisé." - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "L'URL Piwik de base identifée est" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "Outils" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "Lancer le script de test" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "Navigateur de site" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "Nettoyer le cache" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "Êtes-vous sûr de vouloir effacer tous les réglages ?" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "Réinitialiser WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "Les derniers messages de support sur WordPress.org" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "Les réglages ont été effacés (sauf les paramètres de connexion)" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "Le cache a été effacé." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "site" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "sites" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "Pas de site configuré actuellement." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "Identifiant du blog" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Titre" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "URL" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "Identifiant du site (Piwik)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "Le site n'a pas encore été créé." - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "Statistiques" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "Stats affichées actuellement : " - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "Impossible de résoudre" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "realpath() retourne faux (false)" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "La classe Piwik\\FrontController n'existe pas." - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "La class Piwik\\API\\Request n'existe pas." - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "Variables personnalisées Piwik" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "Nom" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "Valeur" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "Définir des variables personnalisées pour une page vue" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Erreur Piwik" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Unique" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Visites" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "Entrées" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "Actions" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "Pas de données disponibles" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "aujourd'hui" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "mois en cours" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "mois précédent" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "semaine en cours" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "semaine précédente" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "hier" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "semaine" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "30 derniers jours" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "Détails navigateur" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Navigateur" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Pourcentage" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "Autres" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "Navigateurs" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Visiteurs" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "Le graphique contient les valeurs indiquées dans le tableau ci-dessous (visiteurs / unique / rebonds). La ligne rouge montre une courbe de tendance linéaire (unique)." - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Pays" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "Pays" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "Raccourci" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Mots Clés" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "Recherche du site" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Mots clés" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "Requêtes" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Rebonds" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Vue d'ensemble" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "Tableau de bord" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Visiteurs uniques" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Pages vues" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "Temps passé total" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Nombre de sauts" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "Temps / visite" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Pages vues max.par visite" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "Pages" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "Page" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "Extensions" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "Extension" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "Temps min. de génération" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "Temps max. de génération" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "Référants" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "Résolutions" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Résolution" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "Détails du système d'exploitation" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "Système d'exploitation" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "Systèmes d'exploitation" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Date" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "Pages vues" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "WP-Piwik requiert au moins PHP 5.3. Vous utilisez la version obsolète %s. Merci de mettre à jour PHP pour utiliser WP-Piwik." diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hi.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hi.mo deleted file mode 100644 index 0583aeb8..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hi.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hi.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hi.po deleted file mode 100644 index 2d5681ec..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hi.po +++ /dev/null @@ -1,1529 +0,0 @@ -# -# Translators: -# AnandVivek, 2015 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:43+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Hindi (http://www.transifex.com/piwik/wp-piwik/language/hi/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: hi\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s स्थापित।" - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "महत्वपूर्ण" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Piwik आँकड़ा" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "सहयोग" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "धोका’ उह?" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "पुन: लोड" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "बदलाव सहेजा गया।" - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "WP-Piwik का उपयोग करने हेतु धन्यवाद!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s सफलतापूर्वक Piwik %s से जुड़ गया है।" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "आप वर्डप्रैस %s चला रहे हैं।" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "आप अभी वर्डप्रैस %s ब्लॉग (डबल्यूपीएमयू) चला रहे हैं। WP-Piwik आपके साइट को एक अलग वैबसाइट की तरह चलाएगा।" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Piwik से जोड़ें" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "आँकड़ा दिखाएँ" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "ट्रैकिंग सक्षम" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "विशेषज्ञ सेटिंग्स" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "श्रेय" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "WP-Piwik वर्डप्रैस का एक प्लगइन है जो Piwik के आँकड़ों को वर्डप्रैस के प्रबंधक डैशबोर्ड में दिखाता है। इसके उपयोग के लिए आपको अपना Piwik की आवश्यकता होगी। यदि आपके पास Piwik का सेटअप नहीं है तो आप इसे दो साधारण तरीके से प्राप्त कर सकते हैं।" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "या" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "और जानकारी" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "आप इनमें से तीन जोड़ने की विधि चुन सकते हैं:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Piwik मोड" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik यूआरएल" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "साइट चुनें" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "Piwik मूल दिनांक" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "आज" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "कल" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "इस माह" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "पिछले माह" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "इस सप्ताह" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "पिछले सप्ताह" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "SEO आँकड़ा दिखाएँ" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "SEO पायदान डाटा को आँकड़ा पृष्ठ पर दिखाएँ।" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "धीमा!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "डैशबोर्ड अवलोकन" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "अक्षम" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "अंतिम 30 दिवस" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "डैशबोर्ड SEO" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "WP-Piwik दृश्य नाम" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "प्लगइन नाम जो वर्डप्रैस में दिखता है।" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "js/index.php का उपयोग" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "प्रॉक्सि स्क्रिप्ट का उपयोग" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "अपने से डालें" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "ट्रैक 404" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "कुकी अक्षम करें" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "उपयोगकर्ता नाम" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "fopen" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "POST" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "GET" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "रिक्त" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "CDN URL" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "CDN URL (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "http" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "https (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "सूचना अद्यतन" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "दान" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "आपके दान के लिए धन्यवाद" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "बहुत बहुत धन्यवाद" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "आपके अनुवाद कार्य हेतु" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "सबसे अच्छा जगह सहायता के लिए:" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "WP-Piwik सहायता मंच" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "allow_url_fopen है" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "औज़ार" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "यूआरएल" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "साइट आईडी (Piwik)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "आँकड़ा" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "नाम" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "मूल्य" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Piwik त्रुटि" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "डाटा अनुपलब्ध" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "सप्ताह" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "ब्राउज़र जानकारी" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "ब्राउज़र" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "प्रतिशत" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "अन्य" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "देश" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "देश" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "रूपांतरण" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "राजस्व" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "लेबल" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "मात्रा" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "अवलोकन" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "नए दृश्यक" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "संचालन प्रणाली की जानकारी" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "संचालन प्रणाली" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "संचालन प्रणालियाँ" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "दिनांक" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hu_HU.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hu_HU.mo deleted file mode 100644 index ff29d1ce..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hu_HU.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hu_HU.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hu_HU.po deleted file mode 100644 index 5c4ca558..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-hu_HU.po +++ /dev/null @@ -1,1530 +0,0 @@ -# -# Translators: -# Márk Kökény , 2015-2016 -# Márk Kökény , 2016 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Hungarian (Hungary) (http://www.transifex.com/piwik/wp-piwik/language/hu_HU/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: hu_HU\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s telepítve." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "Most kapcsolódnod kell a Piwik-hez" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "%s frissítve erre: %s." - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "Kérlek ellenőrizd a konfigurációd" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Beállítások" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Fontos" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Piwik statisztikák" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "WP-Piwik beállításai" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "Egy hiba adódott" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Támogatás" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "Csalsz ’e, mi?" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Újratöltés" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Módosítások elmentve." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Köszönjük, hogy a WP-Piwik-et használod!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s sikeresen kapcsolódott a Piwik %s-hez." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "WordPress %s verzióját használod." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "WordPress %s bloghálózatot (WPMU) használsz. WP-Piwik külön oldalként kezeli minden oldalad." - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "WP-Piwik %s nem tud kapcsolatot létesíteni a Piwik-el a megadott kapcsolati adatok alapján. Ellenőrizd a »Kapcsolódás Piwikhez« szekciót lentebb." - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "WP-Piwik %s nem tud kapcsolatot létesíteni a Piwik-el a megadott kapcsolati adatok alapján. Kapcsolódás közben az alábbi hiba lépett fel:
            %s" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "WP-Piwik-nek mindenekelőtt kapcsolatban kell lennie a Piwik-el. Ellenőrizd a »Kapcsolódás Piwikhez« szekciót lentebb." - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Kapcsolódás Piwik-hez" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Statisztikák megjelenítése" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "Követés engedélyezése" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "Haladó beállítások" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "Stáblista" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "A WP-Piwik egy WordPress kiegészítő, amely a Piwik statisztikáit megjeleníti a te WordPress admin vezérlőpultodon, illetve Piwik követőkódot helyezhetsz el vele a blogodon. Használatához szükséged lesz egy saját működőképes Piwik rendszerre. Amennyiben nincs Piwik-ed, két egyszerű lehetőség közül választhatsz: választhatod bármelyiket" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "vagy" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "További információk" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "Válassz a három kapcsolódási metódus közül:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "Általad-üzemeltetettt (HTTP API, alapértelmezett)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "Ez az alapértelmezett beállítás az általad-üzemeltetett Piwik-hez, ennek a legtöbb esetben működnie kell. WP-Piwik http(s)-en keresztül fog csatlakozni Piwik-edhez." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "Általad-üzemeltetett (PHP API)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "Válaszd ezt, ha az általad-üzemeltetett Piwik és a WordPress ugyanazon a szervergépen fut és tudod a teljes elérési útvonalat Piwik rendszeredhez." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Piwik üzemmód" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "Letiltva (WP-Piwik nem csatlakozik a Piwikhez)" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik URL" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "Add meg Piwik-ed URL címét. Ugyan az a cím, amelyen te is eléred Piwik-ed webböngészőn keresztül. Pl.: http://www.example.com/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "Piwik útvonal" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "Add meg az elérési útvonalat a Piwik telepítésedhez, pl.: /var/www/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Authorizációs token" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "Írd be Piwik authorizációs tokened ide. Ez egy alfanumerikus karaktersor, pl.: 0a1b2c34d56e78901fa2bc3d45678efa." - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "Bővebb infó %sWP-Piwik GYIK%s" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Automata konfiguráció" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "Pipáld be ezt, hogy automatikusan kiválasszam a blogod a Piwik oldalaid közül URL alapján. Amennyiben még nem adtad hozzá az oldalad Piwik-hez, a WP-Piwik megteszi ezt helyetted." - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "Meghatározott oldal" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "Válassz oldalt" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "Piwik alapértelmezett dátum" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Ma" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Tegnap" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Jelen hónap" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Előző hónap" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Jelen hét" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Múlthét" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "Alapértelmezett dátum látható a statisztikák oldalon." - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "SEO adat mejelenítése" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "SEO rangsor adat megjelenítése a statisztikák oldalon." - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "Lassú!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "Vezérlőpult összesítés" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "Letiltva" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "Utolsó 30 nap" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "WP-Piwik vezérlőpulti widget "Összegzés" engedélyezése." - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "Vezélőpult grafikon" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "WP-Piwik vezérlőpulti widget "Grafikon" engedélyezése." - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "Vezélőpult grafikon" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "WP-Piwik vezérlőpulti widget "SEO" engedélyezése." - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "Grafikon megjelenítése a WordPress eszköztáron" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "Utolsó 30 nap látogatói adatainak megjelenítése a WordPress eszköztáron." - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "Statisztikák megjelenítése ehhez:" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Válaszd ki, melyik felhasználói csoport tagjai láthatják a statisztikák oldalt." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "Megjelenítendő bejegyzés statisztikák száma" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "Az egyszeri bejegyzések statisztikáit jeleníti meg az admin oldalon." - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "Piwik parancsikon" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "Piwik prancsikon megejlenítése." - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "WP-Piwik megjelenítendő neve" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "Ez a név fog megjelenni a WordPressben." - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "Shortcode engedélyezése" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "Shortkódok engedélyezése a bejegyzésben, vagy az oldal tartalmában" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "Négy követési módszer közül választhatsz:" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "WP-Piwik nem állít be követőkódot. Használd ezt, ha manuálisan akarod beágyazni a követőkódod a sablonfájlokba, vagy másik kiegészítőt használsz erre a célra." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "Alapértelmezett követés" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "WP-Piwik a Piwik sztenderd követőkódját alkalmazza." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "Használja a js/index.php-t" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "Választhatod ezt a követőkódot, amely kicsinyített proxy kódot tartalmaz, ezzel elkerülve a piwik.js illetve piwik.php fájlok használatát." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "Továbbiak az %solvass el fájlban%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "Használjon proxy szkriptet" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "Használd ezt a követőkódot, és nem feded fel a Piwik szerver URL címét." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "Bővebb infó %sWP-Piwik GYIK%s" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "Megadás manuálisan" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "Írd be saját követőkódod manuálisan. Választhatsz egyet az előbbi opciók közül, elő-konfigurálod a követőkódot, majd a végén váltasz manuális szerkesztésre." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "Használj placeholder-t {ID} hogy hozzáadd a Piwik oldal ID-t." - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "Követőkód hozzáadása" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "Követőkód" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "JavaScript kód pozíció" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "Lábléc" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "Fejléc" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "Válaszd ki, hogy a fejlécbe vagy a láblécbe kerüljön a JavaScript kód." - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "Noscript kód" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "<noscript> Hozzáadása" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "<noscript> kódot helyez a láblécbe." - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "Proxy mód letiltva." - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "Rec paraméter hozzárendelése a noscript kódhoz" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "JavaScript mentes látogatókövetés engedélyezése (nem ajánlott)." - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "Tartalom követés engedélyezése" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "Minden tartalmi blokk követése" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "Csak a látható tartalmi blokk követése" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "A tartalom követés engedélyezi számodra, hogy interakciókat kövess az oldal tartalmán belül, vagy egy applikációban." - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "Bővebb infó a %sPiwik dokumentációban%s." - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "Keresés követése" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "Piwik haladó oldal keresési analitika funkció használata." - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "404 követése" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "WP-Piwik képes automatikusan 404-kategóriát létrehozni, hogy nyomonkövesse a 404-oldal-látogatásokat." - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "Egyedi változók doboz megjelenítése" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "Megjeleníti az "egyedi változók" szerkesztése dobozt a bejegyzés szerkesztés oldalon." - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "Új fájltípusok hozzáadása a letöltés követéshez" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "Új fájltípusok hozzáadása a letöltés követéshez, függőleges vonallal elválasztva (|)." - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "Sütik letiltása" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "Minden követési süti letiltása egy látogatónak." - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "Süti élettartamának limitálása" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "Limitálhatod a sütik élettartamát, hogy elkerülhesd a felhasználók a szükségesnél hosszabb benntartását." - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "Látogatói időkorlát (másodpercben)" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "Munkamenet időkorlát (másodpercben)" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "Hivatkozás időkorlát (másodpercben)" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "Admin oldalak követése" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "Felhasználók követésének engedélyezése az admin oldalakon (ne felejts el megfelelő követési szűrőt alkalmazni)." - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Követési szűrő" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "Válaszd ki azokat a felhasználói szinteket amelyeket nem akarsz követni." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "Aldomainek követése ugyanazon weboldalon" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "Hozzáad egy *.-prefixumot a domain sütiébe." - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "Ne számolja az aldomaineket a kilépési linkeknél" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "Hozzáad egy *.-prefixumot a követett domainhez." - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "RSS csatornák követése" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "Bejegyzések követése a csatornában követő pixel segítségével." - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "RSS csatorna linkek kampánykénti követése" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "RSS csatorna kampány" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "Kulcsszó: hivatkozás neve." - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "Heartbeat időzítő engedélyezése" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "A heartbeat időzítő engedélyezésével pontosabb látogatási hosszakat kaphatsz, periodikusan kiküldött HTTP ping kérések kiküldésének segítségével, rögtön miután az oldalt megnyitották. Add meg az időt a pingek között másodpercben(Piwik alapértelmezett: 15), hogy engedélyezd, vagy 0-t hogy letiltsd ezt a funkciót. Megjegyzés: Ez a funkció sok HTTP kérést okozhat az oldaladon." - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "Felhasználó ID követés" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "WP felhasználó ID" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "E-mailcím" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Felhasználóinév" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "Megjelenítési név (Nem ajánlott!)" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "Mikor egy felhasználó bejelentkezik a WordPress-be, követi az ő "User ID-át". Ki tudod választani, melyik mezőt tekintse a rendszer "User ID-nak". Mikor engedélyezve van, ajánlott az email címet kiválasztani." - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "Általában nincs szükség ezen beállítások módosítására. Azonban ha akarod akkor megteheted, feltéve ha tudod, hogy mit csinálsz, vagy kaptál tanácsot hozzáértő személytől." - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "Gyorsítótár engedélyezése" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "API hívások gyorsítótárazása egy hétig, amelyek nem tartalmazzák a mai napi értékeket." - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "HTTP kapcsolódás ezzel" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "fopen" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "HTTP metódus" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "POST" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "GET" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "Időlimit letiltása" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "set_time_limit(0) használata, ha a statisztikák oldal betöltésekor időtúllépés lép fel." - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "Kapcsolódási időkorlát" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "SSL peer ellenőrzés letiltása" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "nem ajánlott" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "SSL hoszt ellenőrzésének letiltása" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "User agent" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "Használja a PHP alapértlmezett user agent-jét" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "üres" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "Specifikus user agent meghatározása" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "Specifikus user agent" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "data-cfasync=false hozzáadása" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "CDN URL" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "CDN URL (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "Erőltesse a Piwik-et, hogy használja a specifikus protokollt" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "Letiltva (alapértelmezett)" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "http" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "https (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "Válaszd ezt, ha explicit módon akarod rábírni a Piwik-et, hogy használjon HTTP-t vagy HTTPS-t. Nem fog működni CDN URL-el." - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "Frissítési értesítés" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "Mutassa mindíg, ha a WP-Piwik frissítve van" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "Mutassa csak akkor, ha a WP-Piwik frissítésre került és beállításai módosultak" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "Válaszd ezt, ha értesítést kívánsz kapni a WP-Piwik frissítéséről." - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "Add meg a követni kívánt fájltípusokat" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "Piwik alapértelmezett fájlkiterjesztések lecserélése letöltés követéskor, függőleges vonallal elválasztva (|). Hagyd üresen, hogy megtartsd a Piwik alapértelmezett beállításait." - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "Támogatás" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Ha tetszik a WP-Piwik, támogasd fejlesztésünket egy kis adománnyal:" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "Amazon.de kívánságlistám" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "Kérlek ne felejts el szavazni a kompatibilitásról a" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "Köszönjük, hogy támogattad munkánkat" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "a Piwik csapat maga" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "és minden személy aki megtisztelte ezt" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "Köszönettel tartozunk" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "a fordítási munkádért" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "Köszönettel tartozunk minden felhasználónak, aki kritikájával, dícséretével, új funkciók ajánlásával és hibabejelentésekkel segítette munkánkat! Általatok lesz a WP-Piwik kiegészítő jobb és jobb." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "Köszönjük neked, hogy használod ezt a kiegészítőt. A legnagyobb dícséret az, hogy hasznos számotokra az amit csinálunk." - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "Legjobb hely, ahol segítséget kaphatsz:" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "WP-Piwik támogatási fórum" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "Hibakeresés" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "Az allow_url_fopen-nek kell engedélyezve vagy a cURL-nek elérhetőnek kell lennie:" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "nem" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "elérhető" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "allow_url_fopen" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "engedélyezve" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "használatban." - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "A meghatározott Piwik gyökér URL:" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "Eszközök" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "Tesztszktipt futtatása" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "Oldalböngésző" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "Gyorsítótár ürítése" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "Biztos, hogy törölnél minden beállítást?" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "WP-Piwik visszaállítása" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "Legfrissebb támogatási fórumok a WordPress.org-on" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "Beállítások törölve (kivéve a csatlakozási beállításokat)" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "Gyorsítótár kiürítve" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "oldal" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "oldalak" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "Nincs konfigurált oldal." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "Blog ID" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Cím" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "URL" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "Oldal ID (Piwik)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "Oldal még nem készült el." - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "Statisztikák" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "Jelenleg mutatott statok:" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "Nem sikerül feloldani" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "realpath() false értékkel tér vissza" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "Piwik\\FrontController osztály nem létezik." - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "Piwik\\API\\Request osztály nem létezk." - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "Piwik egyedi változók" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "Név" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "Érték" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "Egyedi változók beállítása az oldalnézethez" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Piwik hiba" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Egyedi" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Látogatások" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "Kattintások" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "Akciók" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "Nincs elérhető adat." - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "ma" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "jelen hónap" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "előző hónap" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "jelen hét" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "előző hét" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "tegnap" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "hét" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "utolsó 30 nap" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "Böngésző adatai" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Böngésző" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Százalék" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "Egyebek" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "Böngészők" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Látogatók" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "A grafikon tartalmazza az értékeket, melyek láthatóak a lentebbi táblázatban (látogatók / egyedi / visszapattanások). A vörös vonal mutatja a lineáris trendvonalat (egyedi)." - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Országok" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "Ország" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "Parancsikon" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Kulcsszavak" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "Oldal keresés" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Kulcsszó" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "Kérések" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Visszapattant" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Áttekintés" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Egyedi látogatók" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Oldal megtekintések" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "Eltöltött idő" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Visszapattanások száma" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "Idő/látogatás" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Max. oldal megtekintések egy látogatás alatt" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "Oldalak" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "Oldal" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "Kiegészítők" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "Kiegészítő" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "Min. oldalgenerációs idő" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "Max. oldalgenerációs idő" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "Hivatkozások" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "Felbontások" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Felbontás" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "Operációs rendszer adatok" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "Operációs rendszer" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "Operációs rendszerek" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Dátum" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "Oldal megtekintések" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "A WP-Piwik megkívánja legalább a PHP 5.3-at. Te egy korábbi %s verziót használsz. Kérlek frissítsd a PHP-t, hogy használni tudd a WP-Piwik-et." diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-id.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-id.mo deleted file mode 100644 index 9ac9bde3..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-id.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-id.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-id.po deleted file mode 100644 index b161f4a2..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-id.po +++ /dev/null @@ -1,1528 +0,0 @@ -# -# Translators: -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-15 18:39+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Indonesian (http://www.transifex.com/piwik/wp-piwik/language/id/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: id\n" -"Plural-Forms: nplurals=1; plural=0;\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "" - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "atau" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Nama-Id" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "tidak direkomendasikan" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Judul" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "" - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "" - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "" - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "" - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Negara" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "Negara" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "Konversi" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "Pendapatan" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "Label" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "Kuantitas" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Katakunci" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "Halaman" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "" diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-it_IT.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-it_IT.mo deleted file mode 100644 index d693c790..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-it_IT.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-it_IT.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-it_IT.po deleted file mode 100644 index 8e8159e1..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-it_IT.po +++ /dev/null @@ -1,1532 +0,0 @@ -# -# Translators: -# André Bräkling , 2011 -# André Bräkling, 2015 -# Enzo Ferrara, 2015-2016 -# Stef Binde , 2013 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Italian (Italy) (http://www.transifex.com/piwik/wp-piwik/language/it_IT/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: it_IT\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s installato." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "Adesso crea una connessione a Piwik" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "%s aggiornato a %s." - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "Per favore controlla la tua configurazione" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Impostazioni" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Wichtig" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Statistiche Piwik" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "Configura WP-Piwik" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "E' successo un errore" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Assistenza" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "Stai ’barando’, vero?" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Ricarica" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Cambiamenti salvati." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Grazie per usare WP-Piwik!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s si è collegato con successo a Piwik %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "Stai eseguendo WordPress %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "Stai eseguendo una rete di blog (WPMU) WordPress %s. WP-Piwik gestirà i tuoi siti come differenti." - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "WP-Piwik %s non ha potuto collegarsi a Piwik utilizzando la tua configurazione. Controlla la sezione qui sotto »Collegati a Piwik«." - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "WP-Piwik non ha potuto collegarsi a Piwik utilizzando la tua conigurazione. Durante la connessione si è verificato il seguente errore:
            %s" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "WP-Piwik %s deve prima essere collegato a Piwik. Controlla la sezione qui sotto »Collegati a Piwik«." - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Collegati a Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Mostra Statistiche" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "Abilita il Tracking" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "Impostazioni per esperti" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "Ringraziamenti" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "WP-Piwik è un plugin di WordPress per mostrare una selezione di statistiche nella tua dashboard amministrativa di WordPress e per aggiungere e configurare il tuo codice di tracking di Piwik. Per utilizzarlo hai bisogno di una tua istanza di Piwik. Se ancora non hai un'installazione di Piwik, hai due semplici opzioni: utilizzane una" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "o" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "Maggiori informazioni" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "Puoi scegliere tra tre metodi di connessione:" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "Installazione autonoma (HTTP API, predefinito)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "Questa è l'opzione predefinita per un'installazione autonoma di Piwik e dovrebbe funzionare per la maggior parte delle configurazioni. WP-Piwik si connette a Piwik utilizzando il protocollo http(s)." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "Intallazione autonoma (PHP API)" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "Scegli questo se le tue installazioni autonome di Piwik e WordPress girano sullo stesso server e conosci il percorso completo alla tua istanza di Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Modalità Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "Disabilitato (WP-Piwik non è collegato a Piwik)" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "URL di Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "Inserisci l'URL del tuo Piwik. È lo stesso URL che utilizzi per accedere alla tua istanza di Piwik, es. http://www.example.com/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "Percorso di Piwik " - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "Inserisci il percorso alla tua istanza di Piwik, es. /var/www/piwik/." - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "Auth Token" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "Inserisci qui il tuo token auth di Piwik. Esso è un codice alfanumerico come 0a1b2c34d56e78901fa2bc3d45678efa." - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "Vedi le %sFAQ di WP-Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Configurazione automatica" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "Spunta questo per selezionare automaticamente il tuo blog tra i siti Piwik tramite l'URL. Se il tuo blog non è inserito in Piwik Wp-Piwik lo aggiungerà." - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "Sito rilevato" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "Seleziona sito" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "Data predefinita di Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Oggi" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Ieri" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Mese corrente" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Mese scorso" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Settimana corrente" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Settimana scorsa" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "Il giorno che verrà mostrato sulla pagina delle statistiche." - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "Mostra dati SEO" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "Mostra i dati del ranking SEO nella pagina delle statistiche." - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "Lento!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "Panoramica Dashboard" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "Disabilitato" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "Ultimi 30 giorni" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "Abilita un widget della dashboard di WP-Piwik "Panoramica"." - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "Grafico dashboard" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "Abilita un widget della dashboard di WP-Piwik "Grafico"." - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "Dashboard SEO" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "Abilita un widget della dashboard di WP-Piwik "SEO"." - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "Visualizza un grafico nella barra degli strumenti di Wordpress" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "Mostra un grafico dei visitatori degli ultimi 30 giorni nella barra degli strumenti di WordPress." - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "Mostra statistiche per" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "Seleziona il ruolo per poter accedere alla pagina di statistiche." - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "Mostra statistiche per post" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "Mostra statistiche sui singoli post nella pagina amministrativa di modifica post." - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "Scorciatoia di Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "Visualizzare una scorciatoia per il Piwik principale." - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "Nome visualizzato in WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "Nome del plugin mostrato in WordPress." - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "Abilita gli shortcode" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "Attiva scorciatoie nel contenuto di articoli e pagine. " - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "Puoi scegliere tra quattro modalità per il codice di tracking:" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "WP-Piwik non aggiunge il codice di tracciamento. Usa questo se vuoi aggiungere il codice alla tua template o usa un altro plugin per aggiungerlo." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "Tracking predefinito" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "WP-Piwik utilizzerà il tracking standard di Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "Usa js/index.php" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "Puoi scegliere questo codice di traking per fornire un codice proxy leggero e per evitare l'utilizzo dei files piwik.js e piwik.php." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "Vedi %sil file readme%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "Utilizza script proxy" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "Usa questo codice di tracking per non rivelare l'URL del server di Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "Vedi %sPiwik FAQ%s." - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "Inserisci manualmente" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "Inserisci manualmente un tuo codice tracking. Puoi scegliere una delle opzioni precedenti, preconfigurare il tuo codice e alla fine passare alla modifica manuale." - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "Usa il segnaposto {ID} per aggiungere l'ID sito di Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "Inserisci codice tracciamento" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "Codice tracking" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "Posizione codice JavaScript" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "Footer" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "Header" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "Scegli se il codice JavaScript è nel footer o nell'header." - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "Codice noscript" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Add <noscript>" -msgstr "Aggiungi <noscript>" - -#: classes/WP_Piwik/Admin/Settings.php:226 -msgid "Adds the <noscript> code to your footer." -msgstr "Aggiunge il codice <noscript> al footer." - -#: classes/WP_Piwik/Admin/Settings.php:226 -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Disabled in proxy mode." -msgstr "Disabilitato in modalità proxy." - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Add rec parameter to noscript code" -msgstr "Aggiungi il parametro rec al codice noscript" - -#: classes/WP_Piwik/Admin/Settings.php:228 -msgid "Enable tracking for visitors without JavaScript (not recommended)." -msgstr "Abilita il tracciamento dei visitatori senza JavaScript (non raccomandato)." - -#: classes/WP_Piwik/Admin/Settings.php:230 -msgid "Enable content tracking" -msgstr "Abilita il content tracking" - -#: classes/WP_Piwik/Admin/Settings.php:232 -msgid "Track all content blocks" -msgstr "Traccia tutti i blocchi di contenuto" - -#: classes/WP_Piwik/Admin/Settings.php:233 -msgid "Track only visible content blocks" -msgstr "Traccia solo i blocchi di contenuto visibili" - -#: classes/WP_Piwik/Admin/Settings.php:234 -msgid "" -"Content tracking allows you to track interaction with the content of a web " -"page or application." -msgstr "Il content tracking ti permette di tracciare le interazioni con il contenuto di una pagina web o di un'applicazione." - -#: classes/WP_Piwik/Admin/Settings.php:234 -#: classes/WP_Piwik/Admin/Settings.php:236 -#: classes/WP_Piwik/Admin/Settings.php:245 -#: classes/WP_Piwik/Admin/Settings.php:247 -#: classes/WP_Piwik/Admin/Settings.php:249 -#: classes/WP_Piwik/Admin/Settings.php:270 -#: classes/WP_Piwik/Admin/Settings.php:272 -#: classes/WP_Piwik/Admin/Settings.php:278 -#: classes/WP_Piwik/Admin/Settings.php:343 -#, php-format -msgid "See %sPiwik documentation%s." -msgstr "Leggi la %sDocumentazione di Piwik%s." - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Track search" -msgstr "Traccia le ricerche" - -#: classes/WP_Piwik/Admin/Settings.php:236 -msgid "Use Piwik's advanced Site Search Analytics feature." -msgstr "Utilizza la funzionalità avanzata di Piwik Statistiche Ricerche nel Sito." - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "Track 404" -msgstr "Tracciamento 404" - -#: classes/WP_Piwik/Admin/Settings.php:238 -msgid "" -"WP-Piwik can automatically add a 404-category to track 404-page-visits." -msgstr "WP-Piwik può aggiungere in automatico una categoria per tracciare visite 404." - -#: classes/WP_Piwik/Admin/Settings.php:241 -msgid "Add annotation on new post of type" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid "Show custom variables box" -msgstr "Mostra la casella variabili personalizzate" - -#: classes/WP_Piwik/Admin/Settings.php:247 -msgid " Show a "custom variables" edit box on post edit page." -msgstr "Mostra il box di modifica "variabili personalizzate" nella pagina di modifica post." - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "Add new file types for download tracking" -msgstr "Aggiungi nuovi tipi di file per il tracciamento dei download" - -#: classes/WP_Piwik/Admin/Settings.php:249 -msgid "" -"Add file extensions for download tracking, divided by a vertical bar " -"(|)." -msgstr "Aggiungi delle estensioni di file per il tracciamento dei download divisi da una barra verticale (|)." - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable cookies" -msgstr "Disattivare cookies" - -#: classes/WP_Piwik/Admin/Settings.php:251 -msgid "Disable all tracking cookies for a visitor." -msgstr "Disattiva tutti cookie per i visitatori." - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "Limit cookie lifetime" -msgstr "Limita la durata del cookie" - -#: classes/WP_Piwik/Admin/Settings.php:253 -msgid "" -"You can limit the cookie lifetime to avoid tracking your users over a longer" -" period as necessary." -msgstr "È possibile limitare la durata del cookie per evitare di monitorare i tuoi utenti per un periodo più lungo, se necessario." - -#: classes/WP_Piwik/Admin/Settings.php:255 -msgid "Visitor timeout (seconds)" -msgstr "Timeout visitatori (secondi)" - -#: classes/WP_Piwik/Admin/Settings.php:257 -msgid "Session timeout (seconds)" -msgstr "Timeout sessione (secondi)" - -#: classes/WP_Piwik/Admin/Settings.php:259 -msgid "Referral timeout (seconds)" -msgstr "Timeout referral (secondi)" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "Track admin pages" -msgstr "Traccia le pagine di amministrazione" - -#: classes/WP_Piwik/Admin/Settings.php:261 -msgid "" -"Enable to track users on admin pages (remember to configure the tracking " -"filter appropriately)." -msgstr "Abilita il tracciamento degli utenti sulle pagine di amministrazione (ricorda di configurare in modo opportuno il filtro di tracciamento)." - -#: classes/WP_Piwik/Admin/Settings.php:264 -msgid "Tracking filter" -msgstr "Filtro tracciamento" - -#: classes/WP_Piwik/Admin/Settings.php:268 -msgid "Choose users by user role you do not want to track." -msgstr "Seleziona utenti per ruolo che non vuoi tracciare." - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Track subdomains in the same website" -msgstr "Traccia i sotto-domini nello stesso sito web" - -#: classes/WP_Piwik/Admin/Settings.php:270 -msgid "Adds *.-prefix to cookie domain." -msgstr "Aggiunge il prefisso *.- al cookie di dominio." - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Do not count subdomains as outlink" -msgstr "Non contare i sotto-domini come link di uscita" - -#: classes/WP_Piwik/Admin/Settings.php:272 -msgid "Adds *.-prefix to tracked domain." -msgstr "Aggiunge il prefisso *.- al dominio tracciato." - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "Enable cross domain linking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:274 -msgid "" -"When enabled, it will make sure to use the same visitor ID for the same " -"visitor across several domains. This works only when this feature is enabled" -" because the visitor ID is stored in a cookie and cannot be read on the " -"other domain by default. When this feature is enabled, it will append a URL " -"parameter \"pk_vid\" that contains the visitor ID when a user clicks on a " -"URL that belongs to one of your domains. For this feature to work, you also " -"have to configure which domains should be treated as local in your Piwik " -"website settings. This feature requires Piwik 3.0.2." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Track RSS feeds" -msgstr "Traccia i feed RSS" - -#: classes/WP_Piwik/Admin/Settings.php:276 -msgid "Enable to track posts in feeds via tracking pixel." -msgstr "Abilita la possibilità di tracciare i post nei feed tramite un tracking pixel." - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "Track RSS feed links as campaign" -msgstr "Traccia i link dei feed RSS come campagna" - -#: classes/WP_Piwik/Admin/Settings.php:278 -msgid "This will add Piwik campaign parameters to the RSS feed links. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "RSS feed campaign" -msgstr "Campagna RSS feed" - -#: classes/WP_Piwik/Admin/Settings.php:280 -msgid "Keyword: post name." -msgstr "Keyword: nome post." - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "Enable heartbeat timer" -msgstr "Abilita un timer heartbeat" - -#: classes/WP_Piwik/Admin/Settings.php:282 -msgid "" -"Enable a heartbeat timer to get more accurate visit lengths by sending " -"periodical HTTP ping requests as long as the site is opened. Enter the time " -"between the pings in seconds (Piwik default: 15) to enable or 0 to disable " -"this feature. Note: This will cause a lot of additional " -"HTTP requests on your site." -msgstr "Abilita un timer heartbeat per ottenere durate delle visite più precise inviando un ping HTTP periodico per tutto il tempo in cui il sito resta aperto. Inserisci il tempo, in secondi, tra i ping (predefinito: 15) per abilitare, oppure 0 per disabilitare questa funzione. Nota: Questo provocherà molte richieste HTTP supplementari al tuo sito." - -#: classes/WP_Piwik/Admin/Settings.php:284 -msgid "User ID Tracking" -msgstr "Tracciamento ID Utente" - -#: classes/WP_Piwik/Admin/Settings.php:286 -msgid "WP User ID" -msgstr "ID Utente WP" - -#: classes/WP_Piwik/Admin/Settings.php:287 -msgid "Email Address" -msgstr "Indirizzo Email" - -#: classes/WP_Piwik/Admin/Settings.php:288 -msgid "Username" -msgstr "Nome utente" - -#: classes/WP_Piwik/Admin/Settings.php:289 -msgid "Display Name (Not Recommended!)" -msgstr "Mostra Nome (Non Raccomandato!)" - -#: classes/WP_Piwik/Admin/Settings.php:290 -msgid "" -"When a user is logged in to WordPress, track their "User ID". You " -"can select which field from the User's profile is tracked as the "User " -"ID". When enabled, Tracking based on Email Address is recommended." -msgstr "Quando un utente ha effettuato l'accesso a WordPress, traccia il suo "ID Utente". Puoi selezionare quale campo del profilo utente verrà tracciato come "ID Utente". Quando abilitato, si raccomanda il tracciamento basato sull'Indirizzo Email." - -#: classes/WP_Piwik/Admin/Settings.php:295 -msgid "" -"Usually, you do not need to change these settings. If you want to do so, you" -" should know what you do or you got an expert's advice." -msgstr "Di solito non hai la necessità di cambiare queste impostazioni. Se desideri farlo, devi sapere cosa fai o avere l'aiuto di un esperto." - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Enable cache" -msgstr "Abilita cache" - -#: classes/WP_Piwik/Admin/Settings.php:297 -msgid "Cache API calls, which not contain today's values, for a week." -msgstr "Cache settimanale delle chiamate API che non contiene i dati di oggi." - -#: classes/WP_Piwik/Admin/Settings.php:300 -msgid "HTTP connection via" -msgstr "Connessione HTTP tramite" - -#: classes/WP_Piwik/Admin/Settings.php:301 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "cURL" -msgstr "cURL" - -#: classes/WP_Piwik/Admin/Settings.php:302 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "fopen" -msgstr "fopen" - -#: classes/WP_Piwik/Admin/Settings.php:303 -msgid "" -"Choose whether WP-Piwik should use cURL or fopen to connect to Piwik in HTTP" -" or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:305 -msgid "HTTP method" -msgstr "Metodo HTTP" - -#: classes/WP_Piwik/Admin/Settings.php:306 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "POST" -msgstr "POST" - -#: classes/WP_Piwik/Admin/Settings.php:307 -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "GET" -msgstr "GET" - -#: classes/WP_Piwik/Admin/Settings.php:308 -msgid "Choose whether WP-Piwik should use POST or GET in HTTP or Cloud mode." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Disable time limit" -msgstr "Disattivare limite del tempo" - -#: classes/WP_Piwik/Admin/Settings.php:310 -msgid "Use set_time_limit(0) if stats page causes a time out." -msgstr "Usa set_time_limit(0) nel caso che la pagina delle statistiche genera un timeout." - -#: classes/WP_Piwik/Admin/Settings.php:312 -msgid "Connection timeout" -msgstr "Timeout connessione" - -#: classes/WP_Piwik/Admin/Settings.php:314 -msgid "Disable SSL peer verification" -msgstr "Disattivare verificazione Peer SSL" - -#: classes/WP_Piwik/Admin/Settings.php:314 -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "not recommended" -msgstr "sconsigliato" - -#: classes/WP_Piwik/Admin/Settings.php:315 -msgid "Disable SSL host verification" -msgstr "Disabilita la verifica host SSl" - -#: classes/WP_Piwik/Admin/Settings.php:317 -msgid "User agent" -msgstr "User agent" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "Use the PHP default user agent" -msgstr "Utilizza user agent PHP predefinito" - -#: classes/WP_Piwik/Admin/Settings.php:318 -msgid "empty" -msgstr "vuoto" - -#: classes/WP_Piwik/Admin/Settings.php:319 -msgid "Define a specific user agent" -msgstr "Definisci uno specifico user agent" - -#: classes/WP_Piwik/Admin/Settings.php:321 -msgid "Specific user agent" -msgstr "User agent specifico" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Enable DNS prefetch" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -#, php-format -msgid "See %sPiwik Blog%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:323 -msgid "Add a DNS prefetch tag. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "Add data-cfasync=false" -msgstr "Aggiungi attributo data-cfasync=false" - -#: classes/WP_Piwik/Admin/Settings.php:325 -#, php-format -msgid "See %sCloudFlare Knowledge Base%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:325 -msgid "" -"Adds data-cfasync=false to the script tag, e.g., to ask Rocket Loader to " -"ignore the script. " -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:327 -msgid "CDN URL" -msgstr "URL CDN" - -#: classes/WP_Piwik/Admin/Settings.php:329 -msgid "CDN URL (SSL)" -msgstr "URL CDN (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:331 -msgid "Force Piwik to use a specific protocol" -msgstr "Forza Piwik a utilizzare un protocollo specifico" - -#: classes/WP_Piwik/Admin/Settings.php:332 -msgid "Disabled (default)" -msgstr "Disabilitato (default)" - -#: classes/WP_Piwik/Admin/Settings.php:333 -msgid "http" -msgstr "http" - -#: classes/WP_Piwik/Admin/Settings.php:334 -msgid "https (SSL)" -msgstr "https (SSL)" - -#: classes/WP_Piwik/Admin/Settings.php:335 -msgid "" -"Choose if you want to explicitly force Piwik to use HTTP or HTTPS. Does not " -"work with a CDN URL." -msgstr "Scegli se vuoi esplicitamente forzare Piwik a utilizzare HTTP o HTTPS. Non funziona con URL CDN." - -#: classes/WP_Piwik/Admin/Settings.php:337 -msgid "Update notice" -msgstr "Notifica aggiornamento" - -#: classes/WP_Piwik/Admin/Settings.php:338 -msgid "Show always if WP-Piwik is updated" -msgstr "Mostra sempre se WP-Piwik è aggiornato" - -#: classes/WP_Piwik/Admin/Settings.php:339 -msgid "Show only if WP-Piwik is updated and settings were changed" -msgstr "Mostra solo se WP-Piwik è aggiornato e le impostazioni sono state cambiate" - -#: classes/WP_Piwik/Admin/Settings.php:341 -msgid "Choose if you want to get an update notice if WP-Piwik is updated." -msgstr "Scegli se vuoi ricevere una notifica di aggiornamento se WP-Piwik è aggiornato." - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "Define all file types for download tracking" -msgstr "Definisci tutti i tipi di file per il tracciamento dei download" - -#: classes/WP_Piwik/Admin/Settings.php:343 -msgid "" -"Replace Piwik's default file extensions for download tracking, divided by a " -"vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "Sostituisci le estensione predefinite dei file per il tracciamento dei download, divise da una barra verticale (|). Lascia vuoto per mantenere le impostazioni predefinite di Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "Set classes to be treated as downloads" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -msgid "" -"Set classes to be treated as downloads (in addition to piwik_download), " -"divided by a vertical bar (|). Leave blank to keep Piwik's default " -"settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:345 -#: classes/WP_Piwik/Admin/Settings.php:347 -#, php-format -msgid "See %sPiwik JavaScript Tracking Client reference%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "Set classes to be treated as outlinks" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:347 -msgid "" -"Set classes to be treated as outlinks (in addition to piwik_link), divided " -"by a vertical bar (|). Leave blank to keep Piwik's default settings." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:508 -msgid "Donate" -msgstr "Donazioni" - -#: classes/WP_Piwik/Admin/Settings.php:511 -msgid "If you like WP-Piwik, you can support its development by a donation:" -msgstr "Se ti piace WP-Piwik e vuoi contribuire al suo sviluppo, considera una donazione." - -#: classes/WP_Piwik/Admin/Settings.php:530 -msgid "My Amazon.de wishlist" -msgstr "Mia lista di desideri pressom Amazon.de" - -#: classes/WP_Piwik/Admin/Settings.php:533 -#: classes/WP_Piwik/Admin/Settings.php:575 -msgid "Please don't forget to vote the compatibility at the" -msgstr "Non scordarti di dare una valutazione di compatibilità nella " - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "Thank you very much for your donation" -msgstr "Grazie per le vostre donazioni" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid "the Piwik team itself" -msgstr "il team di Piwik stesso" - -#: classes/WP_Piwik/Admin/Settings.php:561 -msgid ", and all people flattering this" -msgstr ", è tutti che usano Flattr per donazioni a WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:562 -msgid "" -"Graphs powered by jqPlot (License: GPL 2.0 and MIT) and jQuery " -"Sparklines (License: New BSD License)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "Thank you very much" -msgstr "Mille grazie" - -#: classes/WP_Piwik/Admin/Settings.php:563 -msgid "for your translation work" -msgstr "per il vostro lavoro di traduzione" - -#: classes/WP_Piwik/Admin/Settings.php:564 -msgid "" -"Thank you very much, all users who send me mails containing criticism, " -"commendation, feature requests and bug reports! You help me to make WP-Piwik" -" much better." -msgstr "Un ringraziamento sentito per tutti gli utenti che mi inviano critiche, proposte e bug reports! Mi aiutate di migliorare WP-Piwik." - -#: classes/WP_Piwik/Admin/Settings.php:565 -msgid "" -"Thank you for using my plugin. It is the best commendation " -"if my piece of code is really used!" -msgstr "Grazie a te per usare il mio plugin. E' la più grande soddisfazione se il mio codice viene usato realmente!" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "The best place to get help:" -msgstr "Il posto migliore dove trovare aiuto:" - -#: classes/WP_Piwik/Admin/Settings.php:574 -msgid "WP-Piwik support forum" -msgstr "Forum di assistenza WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:577 -msgid "Debugging" -msgstr "Debugging" - -#: classes/WP_Piwik/Admin/Settings.php:578 -msgid "" -"Either allow_url_fopen has to be enabled or cURL has to be " -"available:" -msgstr "O allow_url_fopen deve essere attivato o cURL deve essere disponibile:" - -#: classes/WP_Piwik/Admin/Settings.php:581 -msgid "cURL is" -msgstr "cURL è" - -#: classes/WP_Piwik/Admin/Settings.php:582 -#: classes/WP_Piwik/Admin/Settings.php:587 -msgid "not" -msgstr "non" - -#: classes/WP_Piwik/Admin/Settings.php:583 -msgid "available" -msgstr "disponibile" - -#: classes/WP_Piwik/Admin/Settings.php:586 -msgid "allow_url_fopen is" -msgstr "allow_url_fopen è" - -#: classes/WP_Piwik/Admin/Settings.php:588 -msgid "enabled" -msgstr "attivato" - -#: classes/WP_Piwik/Admin/Settings.php:590 -msgid "is used." -msgstr "è utilizzato." - -#: classes/WP_Piwik/Admin/Settings.php:592 -msgid "Determined Piwik base URL is" -msgstr "L'URL base di Piwik è stata individuata in" - -#: classes/WP_Piwik/Admin/Settings.php:596 -msgid "Tools" -msgstr "Strumenti" - -#: classes/WP_Piwik/Admin/Settings.php:598 -msgid "Run testscript" -msgstr "Esegui script di prova" - -#: classes/WP_Piwik/Admin/Settings.php:599 -msgid "Sitebrowser" -msgstr "Sitebrowser" - -#: classes/WP_Piwik/Admin/Settings.php:600 -msgid "Clear cache" -msgstr "Svuota cache" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Are you sure you want to clear all settings?" -msgstr "Sei sicuro di voler azzerare tutte le impostazioni?" - -#: classes/WP_Piwik/Admin/Settings.php:601 -msgid "Reset WP-Piwik" -msgstr "Reimposta WP-Piwik" - -#: classes/WP_Piwik/Admin/Settings.php:603 -msgid "Latest support threads on WordPress.org" -msgstr "Gli ultimi thread di supporto su WordPress.org" - -#: classes/WP_Piwik/Admin/Settings.php:654 -msgid "Settings cleared (except connection settings)." -msgstr "Impostazioni azzerate (eccetto le impostazioni di connessione)" - -#: classes/WP_Piwik/Admin/Settings.php:670 -msgid "Cache cleared." -msgstr "Cache svuotata." - -#: classes/WP_Piwik/Admin/Sitebrowser.php:22 -msgid "site" -msgstr "sito" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:23 -msgid "sites" -msgstr "siti" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:29 -msgid "No site configured yet." -msgstr "Non è ancora stato configurato alcun sito" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:34 -msgid "Blog ID" -msgstr "ID blog" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:35 -msgid "Title" -msgstr "Titolo" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:36 -msgid "URL" -msgstr "URL" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:37 -msgid "Site ID (Piwik)" -msgstr "ID Pagina (Piwik)" - -#: classes/WP_Piwik/Admin/Sitebrowser.php:84 -msgid "Site not created yet." -msgstr "Non è ancora stato creato alcun sito" - -#: classes/WP_Piwik/Admin/Statistics.php:12 -msgid "Statistics" -msgstr "Statistiche" - -#: classes/WP_Piwik/Admin/Statistics.php:21 -msgid "Currently shown stats:" -msgstr "Statistiche mostrate attualmente:" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "Could not resolve" -msgstr "Impossibile risolvere" - -#: classes/WP_Piwik/Request/Php.php:27 -msgid "realpath() returns false" -msgstr "realpath() restituisce false" - -#: classes/WP_Piwik/Request/Php.php:39 -msgid "Class Piwik\\FrontController does not exists." -msgstr "La classe Piwik\\FrontController non esiste." - -#: classes/WP_Piwik/Request/Php.php:42 -msgid "Class Piwik\\API\\Request does not exists." -msgstr "La classe Piwik\\API\\Request non esiste." - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:10 -msgid "Piwik Custom Variables" -msgstr "Variabili Personalizzate di Piwik" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Name" -msgstr "Nome" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:21 -msgid "Value" -msgstr "Valore" - -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "Set custom variables for a page view" -msgstr "Imposta le variabili personalizzate per una visualizzazione di pagina" - -#: classes/WP_Piwik/Widget.php:91 -#: classes/WP_Piwik/Widget/BrowserDetails.php:37 -#: classes/WP_Piwik/Widget/Browsers.php:37 -#: classes/WP_Piwik/Widget/Chart.php:43 classes/WP_Piwik/Widget/Country.php:37 -#: classes/WP_Piwik/Widget/Ecommerce.php:23 -#: classes/WP_Piwik/Widget/Items.php:23 -#: classes/WP_Piwik/Widget/ItemsCategory.php:23 -#: classes/WP_Piwik/Widget/Noresult.php:23 -#: classes/WP_Piwik/Widget/Overview.php:24 -#: classes/WP_Piwik/Widget/Plugins.php:23 classes/WP_Piwik/Widget/Post.php:25 -#: classes/WP_Piwik/Widget/Screens.php:35 -#: classes/WP_Piwik/Widget/Search.php:23 classes/WP_Piwik/Widget/Seo.php:20 -#: classes/WP_Piwik/Widget/SystemDetails.php:33 -#: classes/WP_Piwik/Widget/Systems.php:33 -#: classes/WP_Piwik/Widget/Visitors.php:35 -msgid "Piwik error" -msgstr "Errore di Piwik" - -#: classes/WP_Piwik/Widget.php:100 -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Unique" -msgstr "Unici" - -#: classes/WP_Piwik/Widget.php:102 classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Visits" -msgstr "Visite" - -#: classes/WP_Piwik/Widget.php:104 -msgid "Hits" -msgstr "Clicks" - -#: classes/WP_Piwik/Widget.php:106 -msgid "Actions" -msgstr "Azioni" - -#: classes/WP_Piwik/Widget.php:162 -msgid "No data available." -msgstr "Nessun dato disponibile." - -#: classes/WP_Piwik/Widget.php:243 -msgid "today" -msgstr "oggi" - -#: classes/WP_Piwik/Widget.php:248 -msgid "current month" -msgstr "mese corrente" - -#: classes/WP_Piwik/Widget.php:253 -msgid "last month" -msgstr "mese scorso" - -#: classes/WP_Piwik/Widget.php:258 -msgid "current week" -msgstr "settimana corrente" - -#: classes/WP_Piwik/Widget.php:263 -msgid "last week" -msgstr "settimana scorsa" - -#: classes/WP_Piwik/Widget.php:268 -msgid "yesterday" -msgstr "ieri" - -#: classes/WP_Piwik/Widget.php:293 -msgid "week" -msgstr "settimana" - -#: classes/WP_Piwik/Widget.php:328 -msgid "last 30 days" -msgstr "gli ultimi 30 giorni" - -#: classes/WP_Piwik/Widget.php:330 -msgid "last 12 " -msgstr "" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:18 -msgid "Browser Details" -msgstr "Dettagli browser" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -msgid "Browser" -msgstr "Browser" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:39 -#: classes/WP_Piwik/Widget/Browsers.php:39 -#: classes/WP_Piwik/Widget/Country.php:39 -#: classes/WP_Piwik/Widget/Plugins.php:25 -#: classes/WP_Piwik/Widget/Screens.php:37 -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Percent" -msgstr "Percentuale" - -#: classes/WP_Piwik/Widget/BrowserDetails.php:66 -#: classes/WP_Piwik/Widget/Browsers.php:66 -#: classes/WP_Piwik/Widget/Country.php:66 -#: classes/WP_Piwik/Widget/Screens.php:64 -#: classes/WP_Piwik/Widget/SystemDetails.php:62 -#: classes/WP_Piwik/Widget/Systems.php:62 -msgid "Others" -msgstr "Altri " - -#: classes/WP_Piwik/Widget/Browsers.php:18 -msgid "Browsers" -msgstr "Browser" - -#: classes/WP_Piwik/Widget/Chart.php:19 -#: classes/WP_Piwik/Widget/Overview.php:48 classes/WP_Piwik/Widget/Post.php:37 -#: classes/WP_Piwik/Widget/Visitors.php:17 -msgid "Visitors" -msgstr "Visitatori" - -#: classes/WP_Piwik/Widget/Chart.php:71 -msgid "" -"The graph contains the values shown in the table below (visitors / unique / " -"bounces). The red line shows a linear trendline (unique)." -msgstr "Il grafico contiene i valori mostrati nella tabella qui sotto (visitatori / unici / rimbalzi). La riga rossa mostra una linea di tendenza lineare (visitatori unici)." - -#: classes/WP_Piwik/Widget/Country.php:18 -msgid "Countries" -msgstr "Nazioni" - -#: classes/WP_Piwik/Widget/Country.php:39 -msgid "Country" -msgstr "Nazione" - -#: classes/WP_Piwik/Widget/Ecommerce.php:11 -msgid "E-Commerce" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:27 -msgid "Conversions" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:28 -msgid "Visits converted" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:29 -#: classes/WP_Piwik/Widget/Items.php:27 -#: classes/WP_Piwik/Widget/ItemsCategory.php:27 -msgid "Revenue" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:30 -#: classes/WP_Piwik/Widget/Items.php:32 -#: classes/WP_Piwik/Widget/ItemsCategory.php:32 -msgid "Conversion rate" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:31 -msgid "Conversions (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:32 -msgid "Visits converted (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:33 -msgid "Revenue (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:34 -msgid "Conversion rate (new visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:35 -msgid "Conversions (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:36 -msgid "Visits converted (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:37 -msgid "Revenue (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:38 -msgid "Conversion rate (returning visitor)" -msgstr "" - -#: classes/WP_Piwik/Widget/Ecommerce.php:40 -#: classes/WP_Piwik/Widget/Overview.php:58 classes/WP_Piwik/Widget/Post.php:46 -msgid "Shortcut" -msgstr "Scorciatoia" - -#: classes/WP_Piwik/Widget/Items.php:11 -msgid "E-Commerce Items" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:26 -#: classes/WP_Piwik/Widget/ItemsCategory.php:26 -msgid "Label" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:28 -#: classes/WP_Piwik/Widget/ItemsCategory.php:28 -msgid "Quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:29 -#: classes/WP_Piwik/Widget/ItemsCategory.php:29 -msgid "Orders" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:30 -#: classes/WP_Piwik/Widget/ItemsCategory.php:30 -msgid "Avg. price" -msgstr "" - -#: classes/WP_Piwik/Widget/Items.php:31 -#: classes/WP_Piwik/Widget/ItemsCategory.php:31 -msgid "Avg. quantity" -msgstr "" - -#: classes/WP_Piwik/Widget/ItemsCategory.php:11 -msgid "E-Commerce Item Categories" -msgstr "" - -#: classes/WP_Piwik/Widget/Keywords.php:16 -msgid "Keywords" -msgstr "Parole chiave" - -#: classes/WP_Piwik/Widget/Noresult.php:16 -#: classes/WP_Piwik/Widget/Search.php:16 -msgid "Site Search" -msgstr "Ricerca Sito" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Keyword" -msgstr "Parole chiavi" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -msgid "Requests" -msgstr "Richieste" - -#: classes/WP_Piwik/Widget/Noresult.php:25 -#: classes/WP_Piwik/Widget/Search.php:25 -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Bounced" -msgstr "Uscite" - -#: classes/WP_Piwik/Widget/Overview.php:17 classes/WP_Piwik/Widget/Post.php:18 -msgid "Overview" -msgstr "Resoconto" - -#: classes/WP_Piwik/Widget/Overview.php:17 -msgid "dashboard" -msgstr "" - -#: classes/WP_Piwik/Widget/Overview.php:50 classes/WP_Piwik/Widget/Post.php:38 -msgid "Unique visitors" -msgstr "Visitatori unici" - -#: classes/WP_Piwik/Widget/Overview.php:52 classes/WP_Piwik/Widget/Post.php:39 -msgid "Page views" -msgstr "Pagine viste" - -#: classes/WP_Piwik/Widget/Overview.php:53 classes/WP_Piwik/Widget/Post.php:40 -msgid "Total time spent" -msgstr "Tempo di rimanenza" - -#: classes/WP_Piwik/Widget/Overview.php:54 classes/WP_Piwik/Widget/Post.php:42 -msgid "Bounce count" -msgstr "Rimbalzi " - -#: classes/WP_Piwik/Widget/Overview.php:57 classes/WP_Piwik/Widget/Post.php:41 -msgid "Time/visit" -msgstr "Media durata per visita" - -#: classes/WP_Piwik/Widget/Overview.php:57 -msgid "Max. page views in one visit" -msgstr "Massimo di pagine viste in una visita" - -#: classes/WP_Piwik/Widget/Pages.php:16 -msgid "Pages" -msgstr "Pagine" - -#: classes/WP_Piwik/Widget/Pages.php:18 -msgid "Page" -msgstr "Pagina" - -#: classes/WP_Piwik/Widget/Plugins.php:16 -msgid "Plugins" -msgstr "Plugins" - -#: classes/WP_Piwik/Widget/Plugins.php:25 -msgid "Plugin" -msgstr "Plugin" - -#: classes/WP_Piwik/Widget/Post.php:43 -msgid "Min. generation time" -msgstr "Minimo tempo di generazione" - -#: classes/WP_Piwik/Widget/Post.php:44 -msgid "Max. generation time" -msgstr "Massimo tempo di generazione" - -#: classes/WP_Piwik/Widget/Referrers.php:16 -msgid "Referrers" -msgstr "Referrers" - -#: classes/WP_Piwik/Widget/Screens.php:16 -msgid "Resolutions" -msgstr "Risoluzioni" - -#: classes/WP_Piwik/Widget/Screens.php:37 -msgid "Resolution" -msgstr "Risoluzione" - -#: classes/WP_Piwik/Widget/Seo.php:13 -msgid "SEO" -msgstr "SEO" - -#: classes/WP_Piwik/Widget/SystemDetails.php:14 -msgid "Operation System Details" -msgstr "Dettagli Sistema Operativo" - -#: classes/WP_Piwik/Widget/SystemDetails.php:35 -#: classes/WP_Piwik/Widget/Systems.php:35 -msgid "Operation System" -msgstr "Sistema Operativo" - -#: classes/WP_Piwik/Widget/Systems.php:14 -msgid "Operation Systems" -msgstr "Sistemi Operativi" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Date" -msgstr "Data" - -#: classes/WP_Piwik/Widget/Visitors.php:57 -msgid "Page Views" -msgstr "Pagine Viste" - -#: wp-piwik.php:60 -#, php-format -msgid "" -"WP-Piwik requires at least PHP 5.3. You are using the deprecated version %s." -" Please update PHP to use WP-Piwik." -msgstr "WP-Piwik richiede almeno PHP 5.3. Tu stai utilizzando la versione deprecata %s. Aggiorna PHP per utilizzare WP-Piwik." diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-lb.mo b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-lb.mo deleted file mode 100644 index 332acad3..00000000 Binary files a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-lb.mo and /dev/null differ diff --git a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-lb.po b/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-lb.po deleted file mode 100644 index c4a45bf4..00000000 --- a/wp-content/upgrade-temp-backup/plugins/wp-piwik/languages/wp-piwik-lb.po +++ /dev/null @@ -1,1529 +0,0 @@ -# -# Translators: -# Michel Weimerskirch , 2015 -msgid "" -msgstr "" -"Project-Id-Version: WP-Piwik\n" -"POT-Creation-Date: 2017-10-09 20:37+0200\n" -"PO-Revision-Date: 2017-10-09 20:41+0000\n" -"Last-Translator: André Bräkling\n" -"Language-Team: Luxembourgish (http://www.transifex.com/piwik/wp-piwik/language/lb/)\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: 8bit\n" -"Language: lb\n" -"Plural-Forms: nplurals=2; plural=(n != 1);\n" - -#: classes/WP_Piwik.php:203 -#, php-format -msgid "%s %s installed." -msgstr "%s %s installéiert." - -#: classes/WP_Piwik.php:203 -msgid "Next you should connect to Piwik" -msgstr "" - -#: classes/WP_Piwik.php:237 -#, php-format -msgid "%s updated to %s." -msgstr "" - -#: classes/WP_Piwik.php:237 -msgid "Please validate your configuration" -msgstr "" - -#: classes/WP_Piwik.php:269 classes/WP_Piwik.php:527 -msgid "Settings" -msgstr "Astellungen" - -#: classes/WP_Piwik.php:272 -msgid "Important" -msgstr "Wichteg" - -#: classes/WP_Piwik.php:387 classes/WP_Piwik.php:409 -msgid "Piwik Statistics" -msgstr "Piwik-Statistiken" - -#: classes/WP_Piwik.php:499 -msgid "Configure WP-Piwik" -msgstr "WP-Piwik konfiguréieren" - -#: classes/WP_Piwik.php:992 -msgid "An error occured" -msgstr "E Feeler ass opgetrueden" - -#: classes/WP_Piwik.php:992 classes/WP_Piwik/Admin/Settings.php:89 -msgid "Support" -msgstr "Ënnerstëtzung" - -#: classes/WP_Piwik.php:1275 -msgid "Cheatin’ uh?" -msgstr "Du fuddels, hë?" - -#: classes/WP_Piwik/Admin/Settings.php:24 -msgid "Reload" -msgstr "Nei lueden" - -#: classes/WP_Piwik/Admin/Settings.php:27 -msgid "Changes saved." -msgstr "Ännerunge gespäichert." - -#: classes/WP_Piwik/Admin/Settings.php:55 -msgid "Thanks for using WP-Piwik!" -msgstr "Merci dass du WP-Piwik benotz!" - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "WP-Piwik %s is successfully connected to Piwik %s." -msgstr "WP-Piwik %s ass erfollegräich mat Piwik %s verbonnen." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "You are running WordPress %s." -msgstr "Du benotz WordPress %s." - -#: classes/WP_Piwik/Admin/Settings.php:58 -#, php-format -msgid "" -"You are running a WordPress %s blog network (WPMU). WP-Piwik will handle " -"your sites as different websites." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:62 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. Check" -" the »Connect to Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:64 -#, php-format -msgid "" -"WP-Piwik %s was not able to connect to Piwik using your configuration. " -"During connection the following error occured:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:67 -#, php-format -msgid "" -"WP-Piwik %s has to be connected to Piwik first. Check the »Connect to " -"Piwik« section below." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:71 -msgid "Connect to Piwik" -msgstr "Mat Piwik verbannen" - -#: classes/WP_Piwik/Admin/Settings.php:76 -msgid "Show Statistics" -msgstr "Statistiken uweisen" - -#: classes/WP_Piwik/Admin/Settings.php:80 -msgid "Enable Tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:85 -msgid "Expert Settings" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:93 -msgid "Credits" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "" -"WP-Piwik is a WordPress plugin to show a selection of Piwik stats in your " -"WordPress admin dashboard and to add and configure your Piwik tracking code." -" To use this you will need your own Piwik instance. If you do not already " -"have a Piwik setup, you have two simple options: use either" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a self-hosted Piwik" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "or" -msgstr "oder" - -#: classes/WP_Piwik/Admin/Settings.php:106 -msgid "a cloud-hosted Piwik by InnoCraft" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -msgid "" -"Neither cURL nor fopen are available. So WP-Piwik can not use the HTTP API " -"and not connect to InnoCraft Cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:109 -#: classes/WP_Piwik/Template/MetaBoxCustomVars.php:30 -msgid "More information" -msgstr "Méi Informatiounen" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "You can choose between three connection methods:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:114 -msgid "Self-hosted (HTTP API, default)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"This is the default option for a self-hosted Piwik and should work for most " -"configurations. WP-Piwik will connect to Piwik using http(s)." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:115 -msgid "Self-hosted (PHP API)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"Choose this, if your self-hosted Piwik and WordPress are running on the same" -" machine and you know the full server path to your Piwik instance." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -#: classes/WP_Piwik/Admin/Settings.php:116 -msgid "Cloud-hosted (InnoCraft Cloud)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:111 -msgid "" -"If you are using a cloud-hosted Piwik by InnoCraft, you can simply use this " -"option." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:112 -msgid "Piwik Mode" -msgstr "Piwik-Modus" - -#: classes/WP_Piwik/Admin/Settings.php:113 -msgid "Disabled (WP-Piwik will not connect to Piwik)" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "Piwik URL" -msgstr "Piwik-Adress" - -#: classes/WP_Piwik/Admin/Settings.php:119 -msgid "" -"Enter your Piwik URL. This is the same URL you use to access your Piwik " -"instance, e.g. http://www.example.com/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Piwik path" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:120 -msgid "Enter the file path to your Piwik instance, e.g. /var/www/piwik/." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "Piwik subdomain" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:121 -msgid "" -"Enter your InnoCraft Cloud subdomain. It is also part of your URL: " -"https://SUBDOMAIN.innocraft.cloud." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "Auth token" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -msgid "" -"Enter your Piwik auth token here. It is an alphanumerical code like " -"0a1b2c34d56e78901fa2bc3d45678efa." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:122 -#, php-format -msgid "See %sWP-Piwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "Auto config" -msgstr "Automatesch konfiguréieren" - -#: classes/WP_Piwik/Admin/Settings.php:127 -msgid "" -"Check this to automatically choose your blog from your Piwik sites by URL. " -"If your blog is not added to Piwik yet, WP-Piwik will add a new site." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:131 -#, php-format -msgid "" -"WP-Piwik %s was not able to get sites with at least view access:
            %s" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:141 -msgid "Determined site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:146 -msgid "Select site" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:155 -msgid "Piwik default date" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:156 -#: classes/WP_Piwik/Admin/Settings.php:170 -msgid "Today" -msgstr "Haut" - -#: classes/WP_Piwik/Admin/Settings.php:157 -#: classes/WP_Piwik/Admin/Settings.php:169 -msgid "Yesterday" -msgstr "Gëschter" - -#: classes/WP_Piwik/Admin/Settings.php:158 -msgid "Current month" -msgstr "Aktuelle Mount" - -#: classes/WP_Piwik/Admin/Settings.php:159 -msgid "Last month" -msgstr "Leschte Mount" - -#: classes/WP_Piwik/Admin/Settings.php:160 -msgid "Current week" -msgstr "Aktuell Woch" - -#: classes/WP_Piwik/Admin/Settings.php:161 -msgid "Last week" -msgstr "Lescht Woch" - -#: classes/WP_Piwik/Admin/Settings.php:162 -msgid "Default date shown on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Show SEO data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -msgid "Display SEO ranking data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:164 -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Slow!" -msgstr "Lues!" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Show e-commerce data" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:165 -msgid "Display e-commerce data on statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:167 -msgid "Dashboard overview" -msgstr "Iwwersiicht um Tableau de Bord" - -#: classes/WP_Piwik/Admin/Settings.php:168 -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:210 -#: classes/WP_Piwik/Admin/Settings.php:231 -#: classes/WP_Piwik/Admin/Settings.php:285 -#: classes/WP_Piwik/Admin/Settings.php:340 -msgid "Disabled" -msgstr "DeaktivéIert" - -#: classes/WP_Piwik/Admin/Settings.php:171 -msgid "Last 30 days" -msgstr "Lescht 30 Deeg" - -#: classes/WP_Piwik/Admin/Settings.php:172 -msgid "Enable WP-Piwik dashboard widget "Overview"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Dashboard graph" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:174 -msgid "Enable WP-Piwik dashboard widget "Graph"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Dashboard SEO" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:176 -msgid "Enable WP-Piwik dashboard widget "SEO"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Dashboard e-commerce" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:178 -msgid "Enable WP-Piwik dashboard widget "E-commerce"." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Show graph on WordPress Toolbar" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:180 -msgid "Display a last 30 days visitor graph on WordPress' toolbar." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:182 -msgid "Display stats to" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:189 -msgid "Choose user roles allowed to see the statistics page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show per post stats" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:191 -msgid "Show stats about single posts at the post edit admin page." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Piwik shortcut" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:193 -msgid "Display a shortcut to Piwik itself." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "WP-Piwik display name" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:195 -msgid "Plugin name shown in WordPress." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:197 -msgid "Enable shortcodes in post or page content." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "You can choose between four tracking code modes:" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"WP-Piwik will not add the tracking code. Use this, if you want to add the " -"tracking code to your template files or you use another plugin to add the " -"tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:211 -msgid "Default tracking" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "WP-Piwik will use Piwik's standard tracking code." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:212 -msgid "Use js/index.php" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"You can choose this tracking code, to deliver a minified proxy code and to " -"avoid using the files called piwik.js or piwik.php." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#, php-format -msgid "See %sreadme file%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:213 -msgid "Use proxy script" -msgstr "Proxy-Skript benotzen" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use this tracking code to not reveal the Piwik server URL." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:228 -#: classes/WP_Piwik/Admin/Settings.php:238 -#, php-format -msgid "See %sPiwik FAQ%s." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -#: classes/WP_Piwik/Admin/Settings.php:214 -msgid "Enter manually" -msgstr "Manuell aginn" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "" -"Enter your own tracking code manually. You can choose one of the prior " -"options, pre-configure your tracking code and switch to manually editing at " -"last." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:208 -msgid "Use the placeholder {ID} to add the Piwik site ID." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:209 -msgid "Add tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:217 -msgid "Tracking code" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:219 -msgid "JavaScript code position" -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:220 -msgid "Footer" -msgstr "Säitefouss" - -#: classes/WP_Piwik/Admin/Settings.php:221 -msgid "Header" -msgstr "Säitekapp" - -#: classes/WP_Piwik/Admin/Settings.php:222 -msgid "" -"Choose whether the JavaScript code is added to the footer or the header." -msgstr "" - -#: classes/WP_Piwik/Admin/Settings.php:224 -msgid "Noscript code" -msgstr "\"